decord/alpha/source/modules/markup/MarkupSubtextRule.tsx

49 lines
1.2 KiB
TypeScript
Raw Permalink Normal View History

2026-10-12 06:59:38 +00:00
// Module ID: 8132
// Function ID: 8133
// Name: MarkupSubtextRule
2026-10-09 10:00:15 +00:00
// Dependencies: [1949, 2]
2026-08-24 06:08:38 +00:00
2026-10-12 06:59:38 +00:00
// Module 8132 (MarkupSubtextRule)
2026-10-09 10:00:15 +00:00
import _mod1949 from "module_1949" /* 1949 */;
import size from "module_2" /* 2 */;
2026-10-09 10:00:15 +00:00
const _modDef1949 = _mod1949;
2026-07-20 16:05:17 +00:00
2026-07-23 10:11:24 +00:00
const re2 = /\n$/;
2026-08-11 06:20:06 +00:00
const re3 = /^ *-# +((?!-#)[^\n]+)(?:\n|$)/;
2026-10-03 08:58:59 +00:00
let obj = {
2026-10-09 10:00:15 +00:00
order: _modDef1949.defaultRules.heading.order,
2026-07-23 10:11:24 +00:00
requiredFirstCharacters: ["-"],
2026-08-11 06:20:06 +00:00
match(arg0, allowSubtext, str) {
let tmp = null;
if (false !== allowSubtext.allowSubtext) {
if (null != str) {
2026-10-03 08:58:59 +00:00
let tmp4;
2026-08-11 06:20:06 +00:00
if ("" !== str) {
2026-10-03 08:58:59 +00:00
tmp4 = null;
2026-08-11 06:20:06 +00:00
}
tmp = tmp4;
2026-07-20 16:05:17 +00:00
}
2026-10-09 10:00:15 +00:00
const obj = _mod1949;
2026-10-03 08:58:59 +00:00
tmp4 = obj.anyScopeRegex(re3)(arg0, allowSubtext, str);
2026-07-20 16:05:17 +00:00
}
2026-08-11 06:20:06 +00:00
return tmp;
2026-07-20 16:05:17 +00:00
},
parse(arg0, fn, arg2) {
2026-10-03 08:58:59 +00:00
let obj2;
let parseInline;
let trimmed;
const obj = { content: parseInline(fn, trimmed, obj2) };
2026-10-09 10:00:15 +00:00
parseInline = _mod1949.parseInline;
2026-10-03 08:58:59 +00:00
obj2 = { allowSubtext: false };
const str = arg0[1];
2026-10-09 10:00:15 +00:00
_mod1949;
2026-10-03 08:58:59 +00:00
trimmed = str.trim();
2026-08-11 06:20:06 +00:00
const merged = Object.assign(arg2);
2026-07-20 16:05:17 +00:00
return obj;
}
};
2026-10-03 08:58:59 +00:00
const result = size.fileFinishedImporting("modules/markup/MarkupSubtextRule.tsx");
export default obj;