required-doc 0.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js ADDED
@@ -0,0 +1,1758 @@
1
+ import { Fragment as e, computed as t, createApp as n, createBlock as r, createCommentVNode as i, createElementBlock as a, createElementVNode as o, createTextVNode as s, createVNode as c, defineComponent as l, nextTick as u, normalizeClass as d, normalizeStyle as f, onBeforeUnmount as p, onMounted as ee, openBlock as m, ref as h, renderList as g, renderSlot as _, resolveDynamicComponent as te, toDisplayString as v, unref as y, watch as ne, withCtx as b } from "vue";
2
+ import { RouterLink as x, RouterView as re, createRouter as ie, createWebHistory as S, useRouter as C } from "vue-router";
3
+ //#endregion
4
+ //#region src/App.vue
5
+ var w = /* @__PURE__ */ l({
6
+ __name: "App",
7
+ setup(e) {
8
+ return (e, t) => (m(), r(y(re)));
9
+ }
10
+ }), T = [{
11
+ id: "pc",
12
+ label: "PC",
13
+ frame: "pc",
14
+ width: 1024
15
+ }, {
16
+ id: "phone",
17
+ label: "Phone",
18
+ frame: "phone",
19
+ width: 360
20
+ }], E = {
21
+ light: {
22
+ bg: "#f5f6f8",
23
+ font: "#1f2937"
24
+ },
25
+ dark: {
26
+ bg: "#131313",
27
+ font: "#f3f3f3"
28
+ }
29
+ }, D = [], O = [], k = [], A = !0, j = T, M = E;
30
+ function N(e) {
31
+ D = e.components, O = e.pages, k = e.colors, A = e.options?.showThemeToggle ?? !0, j = e.options?.devices && e.options.devices.length > 0 ? e.options.devices : T, M = e.options?.baseColors ?? E;
32
+ }
33
+ function ae() {
34
+ return A;
35
+ }
36
+ function oe() {
37
+ return j;
38
+ }
39
+ function se() {
40
+ return M;
41
+ }
42
+ function ce() {
43
+ return D;
44
+ }
45
+ function P() {
46
+ return O;
47
+ }
48
+ function F() {
49
+ return k;
50
+ }
51
+ function le(e, t) {
52
+ return [...D, ...O].find((n) => n.kind === e && n.name === t);
53
+ }
54
+ //#endregion
55
+ //#region src/lib/theme.ts
56
+ var I = h(!1);
57
+ ne(I, (e) => {
58
+ document.documentElement.classList.toggle("dark", e);
59
+ }, { immediate: !0 });
60
+ function ue() {
61
+ return {
62
+ isDark: I,
63
+ toggle: () => {
64
+ I.value = !I.value;
65
+ }
66
+ };
67
+ }
68
+ //#endregion
69
+ //#region src/catalog/CatalogView.vue?vue&type=script&setup=true&lang.ts
70
+ var de = { class: "mx-auto min-h-screen max-w-3xl p-8" }, fe = { class: "mb-8 flex items-center" }, pe = { class: "mb-10" }, me = { class: "space-y-2" }, he = { class: "font-bold dark:text-gray-100" }, ge = { class: "ml-1 text-xs text-gray-400" }, _e = { class: "text-sm text-gray-500 dark:text-gray-400" }, ve = { class: "mb-10" }, ye = { class: "space-y-2" }, be = { class: "font-bold dark:text-gray-100" }, xe = { class: "ml-1 text-xs text-gray-400" }, Se = { class: "text-sm text-gray-500 dark:text-gray-400" }, Ce = { class: "mb-2 rounded-lg border border-gray-300 bg-white p-4 dark:border-gray-700 dark:bg-gray-800" }, we = { class: "space-y-2 text-sm" }, Te = { class: "flex gap-3" }, Ee = { class: "font-bold dark:text-gray-100" }, De = { class: "flex gap-3" }, Oe = { class: "flex-1" }, ke = { class: "space-y-1" }, Ae = { class: "space-y-2" }, je = "block rounded-lg border border-gray-300 bg-white p-4 transition hover:border-blue-500 dark:border-gray-700 dark:bg-gray-800 dark:hover:border-blue-400", Me = /* @__PURE__ */ l({
71
+ __name: "CatalogView",
72
+ setup(t) {
73
+ let { isDark: n, toggle: r } = ue(), l = ae(), u = oe(), f = ce(), p = P();
74
+ function ee(e) {
75
+ return `${e.width}px`;
76
+ }
77
+ return (t, h) => (m(), a("div", de, [
78
+ o("div", fe, [h[1] ||= o("h1", { class: "text-2xl font-bold dark:text-gray-100" }, "要件書カタログ", -1), y(l) ? (m(), a("button", {
79
+ key: 0,
80
+ type: "button",
81
+ class: "ml-auto rounded-md border border-gray-300 px-3 py-1 text-xs font-bold text-gray-600 transition hover:bg-gray-100 dark:border-gray-600 dark:text-gray-300 dark:hover:bg-gray-800",
82
+ onClick: h[0] ||= (...e) => y(r) && y(r)(...e)
83
+ }, v(y(n) ? "ライトモード" : "ダークモード"), 1)) : i("", !0)]),
84
+ o("section", pe, [h[2] ||= o("h2", { class: "mb-3 text-lg font-bold text-gray-700 dark:text-gray-300" }, "ページ", -1), o("ul", me, [(m(!0), a(e, null, g(y(p), (e) => (m(), a("li", { key: e.name }, [c(y(x), {
85
+ to: `/pages/${e.name}`,
86
+ class: d(je)
87
+ }, {
88
+ default: b(() => [o("div", he, [s(v(e.title) + " ", 1), o("span", ge, "(" + v(e.latest) + ")", 1)]), o("div", _e, v(e.desc), 1)]),
89
+ _: 2
90
+ }, 1032, ["to"])]))), 128))])]),
91
+ o("section", ve, [h[3] ||= o("h2", { class: "mb-3 text-lg font-bold text-gray-700 dark:text-gray-300" }, "コンポーネント", -1), o("ul", ye, [(m(!0), a(e, null, g(y(f), (e) => (m(), a("li", { key: e.name }, [c(y(x), {
92
+ to: `/components/${e.name}`,
93
+ class: d(je)
94
+ }, {
95
+ default: b(() => [o("div", be, [s(v(e.title) + " ", 1), o("span", xe, "(" + v(e.latest) + ")", 1)]), o("div", Se, v(e.desc), 1)]),
96
+ _: 2
97
+ }, 1032, ["to"])]))), 128))])]),
98
+ o("section", null, [
99
+ h[8] ||= o("h2", { class: "mb-3 text-lg font-bold text-gray-700 dark:text-gray-300" }, "デザイン", -1),
100
+ o("div", Ce, [h[6] ||= o("div", { class: "mb-2 text-xs font-bold uppercase tracking-wide text-gray-400" }, "表示設定", -1), o("dl", we, [o("div", Te, [h[4] ||= o("dt", { class: "w-28 shrink-0 text-gray-500 dark:text-gray-400" }, "ダークモード切替", -1), o("dd", Ee, v(y(l) ? "表示" : "非表示"), 1)]), o("div", De, [h[5] ||= o("dt", { class: "w-28 shrink-0 text-gray-500 dark:text-gray-400" }, "端末", -1), o("dd", Oe, [o("ul", ke, [(m(!0), a(e, null, g(y(u), (e) => (m(), a("li", {
101
+ key: e.id,
102
+ class: "font-mono text-xs text-gray-700 dark:text-gray-200"
103
+ }, v(e.label) + "(" + v(e.frame) + ") / 幅: " + v(ee(e)), 1))), 128))])])])])]),
104
+ o("ul", Ae, [o("li", null, [c(y(x), {
105
+ to: "/colors",
106
+ class: d(je)
107
+ }, {
108
+ default: b(() => [...h[7] ||= [o("div", { class: "font-bold dark:text-gray-100" }, "カラー", -1), o("div", { class: "text-sm text-gray-500 dark:text-gray-400" }, "accentColor 等の色定義一覧", -1)]]),
109
+ _: 1
110
+ })])])
111
+ ])
112
+ ]));
113
+ }
114
+ });
115
+ //#endregion
116
+ //#region node_modules/marked/lib/marked.esm.js
117
+ function Ne() {
118
+ return {
119
+ async: !1,
120
+ breaks: !1,
121
+ extensions: null,
122
+ gfm: !0,
123
+ hooks: null,
124
+ pedantic: !1,
125
+ renderer: null,
126
+ silent: !1,
127
+ tokenizer: null,
128
+ walkTokens: null
129
+ };
130
+ }
131
+ var L = Ne();
132
+ function Pe(e) {
133
+ L = e;
134
+ }
135
+ var R = { exec: () => null };
136
+ function z(e, t = "") {
137
+ let n = typeof e == "string" ? e : e.source, r = {
138
+ replace: (e, t) => {
139
+ let i = typeof t == "string" ? t : t.source;
140
+ return i = i.replace(B.caret, "$1"), n = n.replace(e, i), r;
141
+ },
142
+ getRegex: () => new RegExp(n, t)
143
+ };
144
+ return r;
145
+ }
146
+ var B = {
147
+ codeRemoveIndent: /^(?: {1,4}| {0,3}\t)/gm,
148
+ outputLinkReplace: /\\([\[\]])/g,
149
+ indentCodeCompensation: /^(\s+)(?:```)/,
150
+ beginningSpace: /^\s+/,
151
+ endingHash: /#$/,
152
+ startingSpaceChar: /^ /,
153
+ endingSpaceChar: / $/,
154
+ nonSpaceChar: /[^ ]/,
155
+ newLineCharGlobal: /\n/g,
156
+ tabCharGlobal: /\t/g,
157
+ multipleSpaceGlobal: /\s+/g,
158
+ blankLine: /^[ \t]*$/,
159
+ doubleBlankLine: /\n[ \t]*\n[ \t]*$/,
160
+ blockquoteStart: /^ {0,3}>/,
161
+ blockquoteSetextReplace: /\n {0,3}((?:=+|-+) *)(?=\n|$)/g,
162
+ blockquoteSetextReplace2: /^ {0,3}>[ \t]?/gm,
163
+ listReplaceTabs: /^\t+/,
164
+ listReplaceNesting: /^ {1,4}(?=( {4})*[^ ])/g,
165
+ listIsTask: /^\[[ xX]\] /,
166
+ listReplaceTask: /^\[[ xX]\] +/,
167
+ anyLine: /\n.*\n/,
168
+ hrefBrackets: /^<(.*)>$/,
169
+ tableDelimiter: /[:|]/,
170
+ tableAlignChars: /^\||\| *$/g,
171
+ tableRowBlankLine: /\n[ \t]*$/,
172
+ tableAlignRight: /^ *-+: *$/,
173
+ tableAlignCenter: /^ *:-+: *$/,
174
+ tableAlignLeft: /^ *:-+ *$/,
175
+ startATag: /^<a /i,
176
+ endATag: /^<\/a>/i,
177
+ startPreScriptTag: /^<(pre|code|kbd|script)(\s|>)/i,
178
+ endPreScriptTag: /^<\/(pre|code|kbd|script)(\s|>)/i,
179
+ startAngleBracket: /^</,
180
+ endAngleBracket: />$/,
181
+ pedanticHrefTitle: /^([^'"]*[^\s])\s+(['"])(.*)\2/,
182
+ unicodeAlphaNumeric: /[\p{L}\p{N}]/u,
183
+ escapeTest: /[&<>"']/,
184
+ escapeReplace: /[&<>"']/g,
185
+ escapeTestNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,
186
+ escapeReplaceNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,
187
+ unescapeTest: /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,
188
+ caret: /(^|[^\[])\^/g,
189
+ percentDecode: /%25/g,
190
+ findPipe: /\|/g,
191
+ splitPipe: / \|/,
192
+ slashPipe: /\\\|/g,
193
+ carriageReturn: /\r\n|\r/g,
194
+ spaceLine: /^ +$/gm,
195
+ notSpaceStart: /^\S*/,
196
+ endingNewline: /\n$/,
197
+ listItemRegex: (e) => RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),
198
+ nextBulletRegex: (e) => RegExp(`^ {0,${Math.min(3, e - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),
199
+ hrRegex: (e) => RegExp(`^ {0,${Math.min(3, e - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),
200
+ fencesBeginRegex: (e) => RegExp(`^ {0,${Math.min(3, e - 1)}}(?:\`\`\`|~~~)`),
201
+ headingBeginRegex: (e) => RegExp(`^ {0,${Math.min(3, e - 1)}}#`),
202
+ htmlBeginRegex: (e) => RegExp(`^ {0,${Math.min(3, e - 1)}}<(?:[a-z].*>|!--)`, "i")
203
+ }, Fe = /^(?:[ \t]*(?:\n|$))+/, Ie = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/, Le = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, V = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, Re = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, ze = /(?:[*+-]|\d{1,9}[.)])/, Be = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, Ve = z(Be).replace(/bull/g, ze).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/\|table/g, "").getRegex(), He = z(Be).replace(/bull/g, ze).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/table/g, / {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(), Ue = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, We = /^[^\n]+/, Ge = /(?!\s*\])(?:\\.|[^\[\]\\])+/, Ke = z(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", Ge).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), qe = z(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, ze).getRegex(), H = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", Je = /<!--(?:-?>|[\s\S]*?(?:-->|$))/, Ye = z("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))", "i").replace("comment", Je).replace("tag", H).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), Xe = z(Ue).replace("hr", V).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", H).getRegex(), Ze = {
204
+ blockquote: z(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", Xe).getRegex(),
205
+ code: Ie,
206
+ def: Ke,
207
+ fences: Le,
208
+ heading: Re,
209
+ hr: V,
210
+ html: Ye,
211
+ lheading: Ve,
212
+ list: qe,
213
+ newline: Fe,
214
+ paragraph: Xe,
215
+ table: R,
216
+ text: We
217
+ }, Qe = z("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", V).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", H).getRegex(), $e = {
218
+ ...Ze,
219
+ lheading: He,
220
+ table: Qe,
221
+ paragraph: z(Ue).replace("hr", V).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", Qe).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", H).getRegex()
222
+ }, et = {
223
+ ...Ze,
224
+ html: z("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment", Je).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
225
+ def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
226
+ heading: /^(#{1,6})(.*)(?:\n+|$)/,
227
+ fences: R,
228
+ lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
229
+ paragraph: z(Ue).replace("hr", V).replace("heading", " *#{1,6} *[^\n]").replace("lheading", Ve).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
230
+ }, tt = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, nt = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, rt = /^( {2,}|\\)\n(?!\s*$)/, it = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, U = /[\p{P}\p{S}]/u, at = /[\s\p{P}\p{S}]/u, ot = /[^\s\p{P}\p{S}]/u, st = z(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, at).getRegex(), ct = /(?!~)[\p{P}\p{S}]/u, lt = /(?!~)[\s\p{P}\p{S}]/u, ut = /(?:[^\s\p{P}\p{S}]|~)/u, dt = /\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<[^<>]*?>/g, ft = /^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/, pt = z(ft, "u").replace(/punct/g, U).getRegex(), mt = z(ft, "u").replace(/punct/g, ct).getRegex(), ht = "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)", gt = z(ht, "gu").replace(/notPunctSpace/g, ot).replace(/punctSpace/g, at).replace(/punct/g, U).getRegex(), _t = z(ht, "gu").replace(/notPunctSpace/g, ut).replace(/punctSpace/g, lt).replace(/punct/g, ct).getRegex(), vt = z("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, ot).replace(/punctSpace/g, at).replace(/punct/g, U).getRegex(), yt = z(/\\(punct)/, "gu").replace(/punct/g, U).getRegex(), bt = z(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme", /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email", /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(), xt = z(Je).replace("(?:-->|$)", "-->").getRegex(), St = z("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment", xt).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), W = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/, Ct = z(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label", W).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), wt = z(/^!?\[(label)\]\[(ref)\]/).replace("label", W).replace("ref", Ge).getRegex(), Tt = z(/^!?\[(ref)\](?:\[\])?/).replace("ref", Ge).getRegex(), Et = {
231
+ _backpedal: R,
232
+ anyPunctuation: yt,
233
+ autolink: bt,
234
+ blockSkip: dt,
235
+ br: rt,
236
+ code: nt,
237
+ del: R,
238
+ emStrongLDelim: pt,
239
+ emStrongRDelimAst: gt,
240
+ emStrongRDelimUnd: vt,
241
+ escape: tt,
242
+ link: Ct,
243
+ nolink: Tt,
244
+ punctuation: st,
245
+ reflink: wt,
246
+ reflinkSearch: z("reflink|nolink(?!\\()", "g").replace("reflink", wt).replace("nolink", Tt).getRegex(),
247
+ tag: St,
248
+ text: it,
249
+ url: R
250
+ }, Dt = {
251
+ ...Et,
252
+ link: z(/^!?\[(label)\]\((.*?)\)/).replace("label", W).getRegex(),
253
+ reflink: z(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", W).getRegex()
254
+ }, Ot = {
255
+ ...Et,
256
+ emStrongRDelimAst: _t,
257
+ emStrongLDelim: mt,
258
+ url: z(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/, "i").replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),
259
+ _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
260
+ del: /^(~~?)(?=[^\s~])((?:\\.|[^\\])*?(?:\\.|[^\s~\\]))\1(?=[^~]|$)/,
261
+ text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/
262
+ }, kt = {
263
+ ...Ot,
264
+ br: z(rt).replace("{2,}", "*").getRegex(),
265
+ text: z(Ot.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
266
+ }, G = {
267
+ normal: Ze,
268
+ gfm: $e,
269
+ pedantic: et
270
+ }, K = {
271
+ normal: Et,
272
+ gfm: Ot,
273
+ breaks: kt,
274
+ pedantic: Dt
275
+ }, At = {
276
+ "&": "&amp;",
277
+ "<": "&lt;",
278
+ ">": "&gt;",
279
+ "\"": "&quot;",
280
+ "'": "&#39;"
281
+ }, jt = (e) => At[e];
282
+ function q(e, t) {
283
+ if (t) {
284
+ if (B.escapeTest.test(e)) return e.replace(B.escapeReplace, jt);
285
+ } else if (B.escapeTestNoEncode.test(e)) return e.replace(B.escapeReplaceNoEncode, jt);
286
+ return e;
287
+ }
288
+ function Mt(e) {
289
+ try {
290
+ e = encodeURI(e).replace(B.percentDecode, "%");
291
+ } catch {
292
+ return null;
293
+ }
294
+ return e;
295
+ }
296
+ function Nt(e, t) {
297
+ let n = e.replace(B.findPipe, (e, t, n) => {
298
+ let r = !1, i = t;
299
+ for (; --i >= 0 && n[i] === "\\";) r = !r;
300
+ return r ? "|" : " |";
301
+ }).split(B.splitPipe), r = 0;
302
+ if (n[0].trim() || n.shift(), n.length > 0 && !n.at(-1)?.trim() && n.pop(), t) if (n.length > t) n.splice(t);
303
+ else for (; n.length < t;) n.push("");
304
+ for (; r < n.length; r++) n[r] = n[r].trim().replace(B.slashPipe, "|");
305
+ return n;
306
+ }
307
+ function J(e, t, n) {
308
+ let r = e.length;
309
+ if (r === 0) return "";
310
+ let i = 0;
311
+ for (; i < r;) {
312
+ let a = e.charAt(r - i - 1);
313
+ if (a === t && !n) i++;
314
+ else if (a !== t && n) i++;
315
+ else break;
316
+ }
317
+ return e.slice(0, r - i);
318
+ }
319
+ function Pt(e, t) {
320
+ if (e.indexOf(t[1]) === -1) return -1;
321
+ let n = 0;
322
+ for (let r = 0; r < e.length; r++) if (e[r] === "\\") r++;
323
+ else if (e[r] === t[0]) n++;
324
+ else if (e[r] === t[1] && (n--, n < 0)) return r;
325
+ return n > 0 ? -2 : -1;
326
+ }
327
+ function Ft(e, t, n, r, i) {
328
+ let a = t.href, o = t.title || null, s = e[1].replace(i.other.outputLinkReplace, "$1");
329
+ r.state.inLink = !0;
330
+ let c = {
331
+ type: e[0].charAt(0) === "!" ? "image" : "link",
332
+ raw: n,
333
+ href: a,
334
+ title: o,
335
+ text: s,
336
+ tokens: r.inlineTokens(s)
337
+ };
338
+ return r.state.inLink = !1, c;
339
+ }
340
+ function It(e, t, n) {
341
+ let r = e.match(n.other.indentCodeCompensation);
342
+ if (r === null) return t;
343
+ let i = r[1];
344
+ return t.split("\n").map((e) => {
345
+ let t = e.match(n.other.beginningSpace);
346
+ if (t === null) return e;
347
+ let [r] = t;
348
+ return r.length >= i.length ? e.slice(i.length) : e;
349
+ }).join("\n");
350
+ }
351
+ var Y = class {
352
+ options;
353
+ rules;
354
+ lexer;
355
+ constructor(e) {
356
+ this.options = e || L;
357
+ }
358
+ space(e) {
359
+ let t = this.rules.block.newline.exec(e);
360
+ if (t && t[0].length > 0) return {
361
+ type: "space",
362
+ raw: t[0]
363
+ };
364
+ }
365
+ code(e) {
366
+ let t = this.rules.block.code.exec(e);
367
+ if (t) {
368
+ let e = t[0].replace(this.rules.other.codeRemoveIndent, "");
369
+ return {
370
+ type: "code",
371
+ raw: t[0],
372
+ codeBlockStyle: "indented",
373
+ text: this.options.pedantic ? e : J(e, "\n")
374
+ };
375
+ }
376
+ }
377
+ fences(e) {
378
+ let t = this.rules.block.fences.exec(e);
379
+ if (t) {
380
+ let e = t[0], n = It(e, t[3] || "", this.rules);
381
+ return {
382
+ type: "code",
383
+ raw: e,
384
+ lang: t[2] ? t[2].trim().replace(this.rules.inline.anyPunctuation, "$1") : t[2],
385
+ text: n
386
+ };
387
+ }
388
+ }
389
+ heading(e) {
390
+ let t = this.rules.block.heading.exec(e);
391
+ if (t) {
392
+ let e = t[2].trim();
393
+ if (this.rules.other.endingHash.test(e)) {
394
+ let t = J(e, "#");
395
+ (this.options.pedantic || !t || this.rules.other.endingSpaceChar.test(t)) && (e = t.trim());
396
+ }
397
+ return {
398
+ type: "heading",
399
+ raw: t[0],
400
+ depth: t[1].length,
401
+ text: e,
402
+ tokens: this.lexer.inline(e)
403
+ };
404
+ }
405
+ }
406
+ hr(e) {
407
+ let t = this.rules.block.hr.exec(e);
408
+ if (t) return {
409
+ type: "hr",
410
+ raw: J(t[0], "\n")
411
+ };
412
+ }
413
+ blockquote(e) {
414
+ let t = this.rules.block.blockquote.exec(e);
415
+ if (t) {
416
+ let e = J(t[0], "\n").split("\n"), n = "", r = "", i = [];
417
+ for (; e.length > 0;) {
418
+ let t = !1, a = [], o;
419
+ for (o = 0; o < e.length; o++) if (this.rules.other.blockquoteStart.test(e[o])) a.push(e[o]), t = !0;
420
+ else if (!t) a.push(e[o]);
421
+ else break;
422
+ e = e.slice(o);
423
+ let s = a.join("\n"), c = s.replace(this.rules.other.blockquoteSetextReplace, "\n $1").replace(this.rules.other.blockquoteSetextReplace2, "");
424
+ n = n ? `${n}
425
+ ${s}` : s, r = r ? `${r}
426
+ ${c}` : c;
427
+ let l = this.lexer.state.top;
428
+ if (this.lexer.state.top = !0, this.lexer.blockTokens(c, i, !0), this.lexer.state.top = l, e.length === 0) break;
429
+ let u = i.at(-1);
430
+ if (u?.type === "code") break;
431
+ if (u?.type === "blockquote") {
432
+ let t = u, a = t.raw + "\n" + e.join("\n"), o = this.blockquote(a);
433
+ i[i.length - 1] = o, n = n.substring(0, n.length - t.raw.length) + o.raw, r = r.substring(0, r.length - t.text.length) + o.text;
434
+ break;
435
+ } else if (u?.type === "list") {
436
+ let t = u, a = t.raw + "\n" + e.join("\n"), o = this.list(a);
437
+ i[i.length - 1] = o, n = n.substring(0, n.length - u.raw.length) + o.raw, r = r.substring(0, r.length - t.raw.length) + o.raw, e = a.substring(i.at(-1).raw.length).split("\n");
438
+ continue;
439
+ }
440
+ }
441
+ return {
442
+ type: "blockquote",
443
+ raw: n,
444
+ tokens: i,
445
+ text: r
446
+ };
447
+ }
448
+ }
449
+ list(e) {
450
+ let t = this.rules.block.list.exec(e);
451
+ if (t) {
452
+ let n = t[1].trim(), r = n.length > 1, i = {
453
+ type: "list",
454
+ raw: "",
455
+ ordered: r,
456
+ start: r ? +n.slice(0, -1) : "",
457
+ loose: !1,
458
+ items: []
459
+ };
460
+ n = r ? `\\d{1,9}\\${n.slice(-1)}` : `\\${n}`, this.options.pedantic && (n = r ? n : "[*+-]");
461
+ let a = this.rules.other.listItemRegex(n), o = !1;
462
+ for (; e;) {
463
+ let n = !1, r = "", s = "";
464
+ if (!(t = a.exec(e)) || this.rules.block.hr.test(e)) break;
465
+ r = t[0], e = e.substring(r.length);
466
+ let c = t[2].split("\n", 1)[0].replace(this.rules.other.listReplaceTabs, (e) => " ".repeat(3 * e.length)), l = e.split("\n", 1)[0], u = !c.trim(), d = 0;
467
+ if (this.options.pedantic ? (d = 2, s = c.trimStart()) : u ? d = t[1].length + 1 : (d = t[2].search(this.rules.other.nonSpaceChar), d = d > 4 ? 1 : d, s = c.slice(d), d += t[1].length), u && this.rules.other.blankLine.test(l) && (r += l + "\n", e = e.substring(l.length + 1), n = !0), !n) {
468
+ let t = this.rules.other.nextBulletRegex(d), n = this.rules.other.hrRegex(d), i = this.rules.other.fencesBeginRegex(d), a = this.rules.other.headingBeginRegex(d), o = this.rules.other.htmlBeginRegex(d);
469
+ for (; e;) {
470
+ let f = e.split("\n", 1)[0], p;
471
+ if (l = f, this.options.pedantic ? (l = l.replace(this.rules.other.listReplaceNesting, " "), p = l) : p = l.replace(this.rules.other.tabCharGlobal, " "), i.test(l) || a.test(l) || o.test(l) || t.test(l) || n.test(l)) break;
472
+ if (p.search(this.rules.other.nonSpaceChar) >= d || !l.trim()) s += "\n" + p.slice(d);
473
+ else {
474
+ if (u || c.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || i.test(c) || a.test(c) || n.test(c)) break;
475
+ s += "\n" + l;
476
+ }
477
+ !u && !l.trim() && (u = !0), r += f + "\n", e = e.substring(f.length + 1), c = p.slice(d);
478
+ }
479
+ }
480
+ i.loose || (o ? i.loose = !0 : this.rules.other.doubleBlankLine.test(r) && (o = !0));
481
+ let f = null, p;
482
+ this.options.gfm && (f = this.rules.other.listIsTask.exec(s), f && (p = f[0] !== "[ ] ", s = s.replace(this.rules.other.listReplaceTask, ""))), i.items.push({
483
+ type: "list_item",
484
+ raw: r,
485
+ task: !!f,
486
+ checked: p,
487
+ loose: !1,
488
+ text: s,
489
+ tokens: []
490
+ }), i.raw += r;
491
+ }
492
+ let s = i.items.at(-1);
493
+ if (s) s.raw = s.raw.trimEnd(), s.text = s.text.trimEnd();
494
+ else return;
495
+ i.raw = i.raw.trimEnd();
496
+ for (let e = 0; e < i.items.length; e++) if (this.lexer.state.top = !1, i.items[e].tokens = this.lexer.blockTokens(i.items[e].text, []), !i.loose) {
497
+ let t = i.items[e].tokens.filter((e) => e.type === "space");
498
+ i.loose = t.length > 0 && t.some((e) => this.rules.other.anyLine.test(e.raw));
499
+ }
500
+ if (i.loose) for (let e = 0; e < i.items.length; e++) i.items[e].loose = !0;
501
+ return i;
502
+ }
503
+ }
504
+ html(e) {
505
+ let t = this.rules.block.html.exec(e);
506
+ if (t) return {
507
+ type: "html",
508
+ block: !0,
509
+ raw: t[0],
510
+ pre: t[1] === "pre" || t[1] === "script" || t[1] === "style",
511
+ text: t[0]
512
+ };
513
+ }
514
+ def(e) {
515
+ let t = this.rules.block.def.exec(e);
516
+ if (t) {
517
+ let e = t[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal, " "), n = t[2] ? t[2].replace(this.rules.other.hrefBrackets, "$1").replace(this.rules.inline.anyPunctuation, "$1") : "", r = t[3] ? t[3].substring(1, t[3].length - 1).replace(this.rules.inline.anyPunctuation, "$1") : t[3];
518
+ return {
519
+ type: "def",
520
+ tag: e,
521
+ raw: t[0],
522
+ href: n,
523
+ title: r
524
+ };
525
+ }
526
+ }
527
+ table(e) {
528
+ let t = this.rules.block.table.exec(e);
529
+ if (!t || !this.rules.other.tableDelimiter.test(t[2])) return;
530
+ let n = Nt(t[1]), r = t[2].replace(this.rules.other.tableAlignChars, "").split("|"), i = t[3]?.trim() ? t[3].replace(this.rules.other.tableRowBlankLine, "").split("\n") : [], a = {
531
+ type: "table",
532
+ raw: t[0],
533
+ header: [],
534
+ align: [],
535
+ rows: []
536
+ };
537
+ if (n.length === r.length) {
538
+ for (let e of r) this.rules.other.tableAlignRight.test(e) ? a.align.push("right") : this.rules.other.tableAlignCenter.test(e) ? a.align.push("center") : this.rules.other.tableAlignLeft.test(e) ? a.align.push("left") : a.align.push(null);
539
+ for (let e = 0; e < n.length; e++) a.header.push({
540
+ text: n[e],
541
+ tokens: this.lexer.inline(n[e]),
542
+ header: !0,
543
+ align: a.align[e]
544
+ });
545
+ for (let e of i) a.rows.push(Nt(e, a.header.length).map((e, t) => ({
546
+ text: e,
547
+ tokens: this.lexer.inline(e),
548
+ header: !1,
549
+ align: a.align[t]
550
+ })));
551
+ return a;
552
+ }
553
+ }
554
+ lheading(e) {
555
+ let t = this.rules.block.lheading.exec(e);
556
+ if (t) return {
557
+ type: "heading",
558
+ raw: t[0],
559
+ depth: t[2].charAt(0) === "=" ? 1 : 2,
560
+ text: t[1],
561
+ tokens: this.lexer.inline(t[1])
562
+ };
563
+ }
564
+ paragraph(e) {
565
+ let t = this.rules.block.paragraph.exec(e);
566
+ if (t) {
567
+ let e = t[1].charAt(t[1].length - 1) === "\n" ? t[1].slice(0, -1) : t[1];
568
+ return {
569
+ type: "paragraph",
570
+ raw: t[0],
571
+ text: e,
572
+ tokens: this.lexer.inline(e)
573
+ };
574
+ }
575
+ }
576
+ text(e) {
577
+ let t = this.rules.block.text.exec(e);
578
+ if (t) return {
579
+ type: "text",
580
+ raw: t[0],
581
+ text: t[0],
582
+ tokens: this.lexer.inline(t[0])
583
+ };
584
+ }
585
+ escape(e) {
586
+ let t = this.rules.inline.escape.exec(e);
587
+ if (t) return {
588
+ type: "escape",
589
+ raw: t[0],
590
+ text: t[1]
591
+ };
592
+ }
593
+ tag(e) {
594
+ let t = this.rules.inline.tag.exec(e);
595
+ if (t) return !this.lexer.state.inLink && this.rules.other.startATag.test(t[0]) ? this.lexer.state.inLink = !0 : this.lexer.state.inLink && this.rules.other.endATag.test(t[0]) && (this.lexer.state.inLink = !1), !this.lexer.state.inRawBlock && this.rules.other.startPreScriptTag.test(t[0]) ? this.lexer.state.inRawBlock = !0 : this.lexer.state.inRawBlock && this.rules.other.endPreScriptTag.test(t[0]) && (this.lexer.state.inRawBlock = !1), {
596
+ type: "html",
597
+ raw: t[0],
598
+ inLink: this.lexer.state.inLink,
599
+ inRawBlock: this.lexer.state.inRawBlock,
600
+ block: !1,
601
+ text: t[0]
602
+ };
603
+ }
604
+ link(e) {
605
+ let t = this.rules.inline.link.exec(e);
606
+ if (t) {
607
+ let e = t[2].trim();
608
+ if (!this.options.pedantic && this.rules.other.startAngleBracket.test(e)) {
609
+ if (!this.rules.other.endAngleBracket.test(e)) return;
610
+ let t = J(e.slice(0, -1), "\\");
611
+ if ((e.length - t.length) % 2 == 0) return;
612
+ } else {
613
+ let e = Pt(t[2], "()");
614
+ if (e === -2) return;
615
+ if (e > -1) {
616
+ let n = (t[0].indexOf("!") === 0 ? 5 : 4) + t[1].length + e;
617
+ t[2] = t[2].substring(0, e), t[0] = t[0].substring(0, n).trim(), t[3] = "";
618
+ }
619
+ }
620
+ let n = t[2], r = "";
621
+ if (this.options.pedantic) {
622
+ let e = this.rules.other.pedanticHrefTitle.exec(n);
623
+ e && (n = e[1], r = e[3]);
624
+ } else r = t[3] ? t[3].slice(1, -1) : "";
625
+ return n = n.trim(), this.rules.other.startAngleBracket.test(n) && (n = this.options.pedantic && !this.rules.other.endAngleBracket.test(e) ? n.slice(1) : n.slice(1, -1)), Ft(t, {
626
+ href: n && n.replace(this.rules.inline.anyPunctuation, "$1"),
627
+ title: r && r.replace(this.rules.inline.anyPunctuation, "$1")
628
+ }, t[0], this.lexer, this.rules);
629
+ }
630
+ }
631
+ reflink(e, t) {
632
+ let n;
633
+ if ((n = this.rules.inline.reflink.exec(e)) || (n = this.rules.inline.nolink.exec(e))) {
634
+ let e = t[(n[2] || n[1]).replace(this.rules.other.multipleSpaceGlobal, " ").toLowerCase()];
635
+ if (!e) {
636
+ let e = n[0].charAt(0);
637
+ return {
638
+ type: "text",
639
+ raw: e,
640
+ text: e
641
+ };
642
+ }
643
+ return Ft(n, e, n[0], this.lexer, this.rules);
644
+ }
645
+ }
646
+ emStrong(e, t, n = "") {
647
+ let r = this.rules.inline.emStrongLDelim.exec(e);
648
+ if (r && !(r[3] && n.match(this.rules.other.unicodeAlphaNumeric)) && (!(r[1] || r[2]) || !n || this.rules.inline.punctuation.exec(n))) {
649
+ let n = [...r[0]].length - 1, i, a, o = n, s = 0, c = r[0][0] === "*" ? this.rules.inline.emStrongRDelimAst : this.rules.inline.emStrongRDelimUnd;
650
+ for (c.lastIndex = 0, t = t.slice(-1 * e.length + n); (r = c.exec(t)) != null;) {
651
+ if (i = r[1] || r[2] || r[3] || r[4] || r[5] || r[6], !i) continue;
652
+ if (a = [...i].length, r[3] || r[4]) {
653
+ o += a;
654
+ continue;
655
+ } else if ((r[5] || r[6]) && n % 3 && !((n + a) % 3)) {
656
+ s += a;
657
+ continue;
658
+ }
659
+ if (o -= a, o > 0) continue;
660
+ a = Math.min(a, a + o + s);
661
+ let t = [...r[0]][0].length, c = e.slice(0, n + r.index + t + a);
662
+ if (Math.min(n, a) % 2) {
663
+ let e = c.slice(1, -1);
664
+ return {
665
+ type: "em",
666
+ raw: c,
667
+ text: e,
668
+ tokens: this.lexer.inlineTokens(e)
669
+ };
670
+ }
671
+ let l = c.slice(2, -2);
672
+ return {
673
+ type: "strong",
674
+ raw: c,
675
+ text: l,
676
+ tokens: this.lexer.inlineTokens(l)
677
+ };
678
+ }
679
+ }
680
+ }
681
+ codespan(e) {
682
+ let t = this.rules.inline.code.exec(e);
683
+ if (t) {
684
+ let e = t[2].replace(this.rules.other.newLineCharGlobal, " "), n = this.rules.other.nonSpaceChar.test(e), r = this.rules.other.startingSpaceChar.test(e) && this.rules.other.endingSpaceChar.test(e);
685
+ return n && r && (e = e.substring(1, e.length - 1)), {
686
+ type: "codespan",
687
+ raw: t[0],
688
+ text: e
689
+ };
690
+ }
691
+ }
692
+ br(e) {
693
+ let t = this.rules.inline.br.exec(e);
694
+ if (t) return {
695
+ type: "br",
696
+ raw: t[0]
697
+ };
698
+ }
699
+ del(e) {
700
+ let t = this.rules.inline.del.exec(e);
701
+ if (t) return {
702
+ type: "del",
703
+ raw: t[0],
704
+ text: t[2],
705
+ tokens: this.lexer.inlineTokens(t[2])
706
+ };
707
+ }
708
+ autolink(e) {
709
+ let t = this.rules.inline.autolink.exec(e);
710
+ if (t) {
711
+ let e, n;
712
+ return t[2] === "@" ? (e = t[1], n = "mailto:" + e) : (e = t[1], n = e), {
713
+ type: "link",
714
+ raw: t[0],
715
+ text: e,
716
+ href: n,
717
+ tokens: [{
718
+ type: "text",
719
+ raw: e,
720
+ text: e
721
+ }]
722
+ };
723
+ }
724
+ }
725
+ url(e) {
726
+ let t;
727
+ if (t = this.rules.inline.url.exec(e)) {
728
+ let e, n;
729
+ if (t[2] === "@") e = t[0], n = "mailto:" + e;
730
+ else {
731
+ let r;
732
+ do
733
+ r = t[0], t[0] = this.rules.inline._backpedal.exec(t[0])?.[0] ?? "";
734
+ while (r !== t[0]);
735
+ e = t[0], n = t[1] === "www." ? "http://" + t[0] : t[0];
736
+ }
737
+ return {
738
+ type: "link",
739
+ raw: t[0],
740
+ text: e,
741
+ href: n,
742
+ tokens: [{
743
+ type: "text",
744
+ raw: e,
745
+ text: e
746
+ }]
747
+ };
748
+ }
749
+ }
750
+ inlineText(e) {
751
+ let t = this.rules.inline.text.exec(e);
752
+ if (t) {
753
+ let e = this.lexer.state.inRawBlock;
754
+ return {
755
+ type: "text",
756
+ raw: t[0],
757
+ text: t[0],
758
+ escaped: e
759
+ };
760
+ }
761
+ }
762
+ }, X = class e {
763
+ tokens;
764
+ options;
765
+ state;
766
+ tokenizer;
767
+ inlineQueue;
768
+ constructor(e) {
769
+ this.tokens = [], this.tokens.links = /* @__PURE__ */ Object.create(null), this.options = e || L, this.options.tokenizer = this.options.tokenizer || new Y(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = {
770
+ inLink: !1,
771
+ inRawBlock: !1,
772
+ top: !0
773
+ };
774
+ let t = {
775
+ other: B,
776
+ block: G.normal,
777
+ inline: K.normal
778
+ };
779
+ this.options.pedantic ? (t.block = G.pedantic, t.inline = K.pedantic) : this.options.gfm && (t.block = G.gfm, this.options.breaks ? t.inline = K.breaks : t.inline = K.gfm), this.tokenizer.rules = t;
780
+ }
781
+ static get rules() {
782
+ return {
783
+ block: G,
784
+ inline: K
785
+ };
786
+ }
787
+ static lex(t, n) {
788
+ return new e(n).lex(t);
789
+ }
790
+ static lexInline(t, n) {
791
+ return new e(n).inlineTokens(t);
792
+ }
793
+ lex(e) {
794
+ e = e.replace(B.carriageReturn, "\n"), this.blockTokens(e, this.tokens);
795
+ for (let e = 0; e < this.inlineQueue.length; e++) {
796
+ let t = this.inlineQueue[e];
797
+ this.inlineTokens(t.src, t.tokens);
798
+ }
799
+ return this.inlineQueue = [], this.tokens;
800
+ }
801
+ blockTokens(e, t = [], n = !1) {
802
+ for (this.options.pedantic && (e = e.replace(B.tabCharGlobal, " ").replace(B.spaceLine, "")); e;) {
803
+ let r;
804
+ if (this.options.extensions?.block?.some((n) => (r = n.call({ lexer: this }, e, t)) ? (e = e.substring(r.raw.length), t.push(r), !0) : !1)) continue;
805
+ if (r = this.tokenizer.space(e)) {
806
+ e = e.substring(r.raw.length);
807
+ let n = t.at(-1);
808
+ r.raw.length === 1 && n !== void 0 ? n.raw += "\n" : t.push(r);
809
+ continue;
810
+ }
811
+ if (r = this.tokenizer.code(e)) {
812
+ e = e.substring(r.raw.length);
813
+ let n = t.at(-1);
814
+ n?.type === "paragraph" || n?.type === "text" ? (n.raw += "\n" + r.raw, n.text += "\n" + r.text, this.inlineQueue.at(-1).src = n.text) : t.push(r);
815
+ continue;
816
+ }
817
+ if (r = this.tokenizer.fences(e)) {
818
+ e = e.substring(r.raw.length), t.push(r);
819
+ continue;
820
+ }
821
+ if (r = this.tokenizer.heading(e)) {
822
+ e = e.substring(r.raw.length), t.push(r);
823
+ continue;
824
+ }
825
+ if (r = this.tokenizer.hr(e)) {
826
+ e = e.substring(r.raw.length), t.push(r);
827
+ continue;
828
+ }
829
+ if (r = this.tokenizer.blockquote(e)) {
830
+ e = e.substring(r.raw.length), t.push(r);
831
+ continue;
832
+ }
833
+ if (r = this.tokenizer.list(e)) {
834
+ e = e.substring(r.raw.length), t.push(r);
835
+ continue;
836
+ }
837
+ if (r = this.tokenizer.html(e)) {
838
+ e = e.substring(r.raw.length), t.push(r);
839
+ continue;
840
+ }
841
+ if (r = this.tokenizer.def(e)) {
842
+ e = e.substring(r.raw.length);
843
+ let n = t.at(-1);
844
+ n?.type === "paragraph" || n?.type === "text" ? (n.raw += "\n" + r.raw, n.text += "\n" + r.raw, this.inlineQueue.at(-1).src = n.text) : this.tokens.links[r.tag] || (this.tokens.links[r.tag] = {
845
+ href: r.href,
846
+ title: r.title
847
+ });
848
+ continue;
849
+ }
850
+ if (r = this.tokenizer.table(e)) {
851
+ e = e.substring(r.raw.length), t.push(r);
852
+ continue;
853
+ }
854
+ if (r = this.tokenizer.lheading(e)) {
855
+ e = e.substring(r.raw.length), t.push(r);
856
+ continue;
857
+ }
858
+ let i = e;
859
+ if (this.options.extensions?.startBlock) {
860
+ let t = Infinity, n = e.slice(1), r;
861
+ this.options.extensions.startBlock.forEach((e) => {
862
+ r = e.call({ lexer: this }, n), typeof r == "number" && r >= 0 && (t = Math.min(t, r));
863
+ }), t < Infinity && t >= 0 && (i = e.substring(0, t + 1));
864
+ }
865
+ if (this.state.top && (r = this.tokenizer.paragraph(i))) {
866
+ let a = t.at(-1);
867
+ n && a?.type === "paragraph" ? (a.raw += "\n" + r.raw, a.text += "\n" + r.text, this.inlineQueue.pop(), this.inlineQueue.at(-1).src = a.text) : t.push(r), n = i.length !== e.length, e = e.substring(r.raw.length);
868
+ continue;
869
+ }
870
+ if (r = this.tokenizer.text(e)) {
871
+ e = e.substring(r.raw.length);
872
+ let n = t.at(-1);
873
+ n?.type === "text" ? (n.raw += "\n" + r.raw, n.text += "\n" + r.text, this.inlineQueue.pop(), this.inlineQueue.at(-1).src = n.text) : t.push(r);
874
+ continue;
875
+ }
876
+ if (e) {
877
+ let t = "Infinite loop on byte: " + e.charCodeAt(0);
878
+ if (this.options.silent) {
879
+ console.error(t);
880
+ break;
881
+ } else throw Error(t);
882
+ }
883
+ }
884
+ return this.state.top = !0, t;
885
+ }
886
+ inline(e, t = []) {
887
+ return this.inlineQueue.push({
888
+ src: e,
889
+ tokens: t
890
+ }), t;
891
+ }
892
+ inlineTokens(e, t = []) {
893
+ let n = e, r = null;
894
+ if (this.tokens.links) {
895
+ let e = Object.keys(this.tokens.links);
896
+ if (e.length > 0) for (; (r = this.tokenizer.rules.inline.reflinkSearch.exec(n)) != null;) e.includes(r[0].slice(r[0].lastIndexOf("[") + 1, -1)) && (n = n.slice(0, r.index) + "[" + "a".repeat(r[0].length - 2) + "]" + n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex));
897
+ }
898
+ for (; (r = this.tokenizer.rules.inline.anyPunctuation.exec(n)) != null;) n = n.slice(0, r.index) + "++" + n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);
899
+ for (; (r = this.tokenizer.rules.inline.blockSkip.exec(n)) != null;) n = n.slice(0, r.index) + "[" + "a".repeat(r[0].length - 2) + "]" + n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
900
+ let i = !1, a = "";
901
+ for (; e;) {
902
+ i || (a = ""), i = !1;
903
+ let r;
904
+ if (this.options.extensions?.inline?.some((n) => (r = n.call({ lexer: this }, e, t)) ? (e = e.substring(r.raw.length), t.push(r), !0) : !1)) continue;
905
+ if (r = this.tokenizer.escape(e)) {
906
+ e = e.substring(r.raw.length), t.push(r);
907
+ continue;
908
+ }
909
+ if (r = this.tokenizer.tag(e)) {
910
+ e = e.substring(r.raw.length), t.push(r);
911
+ continue;
912
+ }
913
+ if (r = this.tokenizer.link(e)) {
914
+ e = e.substring(r.raw.length), t.push(r);
915
+ continue;
916
+ }
917
+ if (r = this.tokenizer.reflink(e, this.tokens.links)) {
918
+ e = e.substring(r.raw.length);
919
+ let n = t.at(-1);
920
+ r.type === "text" && n?.type === "text" ? (n.raw += r.raw, n.text += r.text) : t.push(r);
921
+ continue;
922
+ }
923
+ if (r = this.tokenizer.emStrong(e, n, a)) {
924
+ e = e.substring(r.raw.length), t.push(r);
925
+ continue;
926
+ }
927
+ if (r = this.tokenizer.codespan(e)) {
928
+ e = e.substring(r.raw.length), t.push(r);
929
+ continue;
930
+ }
931
+ if (r = this.tokenizer.br(e)) {
932
+ e = e.substring(r.raw.length), t.push(r);
933
+ continue;
934
+ }
935
+ if (r = this.tokenizer.del(e)) {
936
+ e = e.substring(r.raw.length), t.push(r);
937
+ continue;
938
+ }
939
+ if (r = this.tokenizer.autolink(e)) {
940
+ e = e.substring(r.raw.length), t.push(r);
941
+ continue;
942
+ }
943
+ if (!this.state.inLink && (r = this.tokenizer.url(e))) {
944
+ e = e.substring(r.raw.length), t.push(r);
945
+ continue;
946
+ }
947
+ let o = e;
948
+ if (this.options.extensions?.startInline) {
949
+ let t = Infinity, n = e.slice(1), r;
950
+ this.options.extensions.startInline.forEach((e) => {
951
+ r = e.call({ lexer: this }, n), typeof r == "number" && r >= 0 && (t = Math.min(t, r));
952
+ }), t < Infinity && t >= 0 && (o = e.substring(0, t + 1));
953
+ }
954
+ if (r = this.tokenizer.inlineText(o)) {
955
+ e = e.substring(r.raw.length), r.raw.slice(-1) !== "_" && (a = r.raw.slice(-1)), i = !0;
956
+ let n = t.at(-1);
957
+ n?.type === "text" ? (n.raw += r.raw, n.text += r.text) : t.push(r);
958
+ continue;
959
+ }
960
+ if (e) {
961
+ let t = "Infinite loop on byte: " + e.charCodeAt(0);
962
+ if (this.options.silent) {
963
+ console.error(t);
964
+ break;
965
+ } else throw Error(t);
966
+ }
967
+ }
968
+ return t;
969
+ }
970
+ }, Lt = class {
971
+ options;
972
+ parser;
973
+ constructor(e) {
974
+ this.options = e || L;
975
+ }
976
+ space(e) {
977
+ return "";
978
+ }
979
+ code({ text: e, lang: t, escaped: n }) {
980
+ let r = (t || "").match(B.notSpaceStart)?.[0], i = e.replace(B.endingNewline, "") + "\n";
981
+ return r ? "<pre><code class=\"language-" + q(r) + "\">" + (n ? i : q(i, !0)) + "</code></pre>\n" : "<pre><code>" + (n ? i : q(i, !0)) + "</code></pre>\n";
982
+ }
983
+ blockquote({ tokens: e }) {
984
+ return `<blockquote>
985
+ ${this.parser.parse(e)}</blockquote>
986
+ `;
987
+ }
988
+ html({ text: e }) {
989
+ return e;
990
+ }
991
+ heading({ tokens: e, depth: t }) {
992
+ return `<h${t}>${this.parser.parseInline(e)}</h${t}>
993
+ `;
994
+ }
995
+ hr(e) {
996
+ return "<hr>\n";
997
+ }
998
+ list(e) {
999
+ let t = e.ordered, n = e.start, r = "";
1000
+ for (let t = 0; t < e.items.length; t++) {
1001
+ let n = e.items[t];
1002
+ r += this.listitem(n);
1003
+ }
1004
+ let i = t ? "ol" : "ul", a = t && n !== 1 ? " start=\"" + n + "\"" : "";
1005
+ return "<" + i + a + ">\n" + r + "</" + i + ">\n";
1006
+ }
1007
+ listitem(e) {
1008
+ let t = "";
1009
+ if (e.task) {
1010
+ let n = this.checkbox({ checked: !!e.checked });
1011
+ e.loose ? e.tokens[0]?.type === "paragraph" ? (e.tokens[0].text = n + " " + e.tokens[0].text, e.tokens[0].tokens && e.tokens[0].tokens.length > 0 && e.tokens[0].tokens[0].type === "text" && (e.tokens[0].tokens[0].text = n + " " + q(e.tokens[0].tokens[0].text), e.tokens[0].tokens[0].escaped = !0)) : e.tokens.unshift({
1012
+ type: "text",
1013
+ raw: n + " ",
1014
+ text: n + " ",
1015
+ escaped: !0
1016
+ }) : t += n + " ";
1017
+ }
1018
+ return t += this.parser.parse(e.tokens, !!e.loose), `<li>${t}</li>
1019
+ `;
1020
+ }
1021
+ checkbox({ checked: e }) {
1022
+ return "<input " + (e ? "checked=\"\" " : "") + "disabled=\"\" type=\"checkbox\">";
1023
+ }
1024
+ paragraph({ tokens: e }) {
1025
+ return `<p>${this.parser.parseInline(e)}</p>
1026
+ `;
1027
+ }
1028
+ table(e) {
1029
+ let t = "", n = "";
1030
+ for (let t = 0; t < e.header.length; t++) n += this.tablecell(e.header[t]);
1031
+ t += this.tablerow({ text: n });
1032
+ let r = "";
1033
+ for (let t = 0; t < e.rows.length; t++) {
1034
+ let i = e.rows[t];
1035
+ n = "";
1036
+ for (let e = 0; e < i.length; e++) n += this.tablecell(i[e]);
1037
+ r += this.tablerow({ text: n });
1038
+ }
1039
+ return r &&= `<tbody>${r}</tbody>`, "<table>\n<thead>\n" + t + "</thead>\n" + r + "</table>\n";
1040
+ }
1041
+ tablerow({ text: e }) {
1042
+ return `<tr>
1043
+ ${e}</tr>
1044
+ `;
1045
+ }
1046
+ tablecell(e) {
1047
+ let t = this.parser.parseInline(e.tokens), n = e.header ? "th" : "td";
1048
+ return (e.align ? `<${n} align="${e.align}">` : `<${n}>`) + t + `</${n}>
1049
+ `;
1050
+ }
1051
+ strong({ tokens: e }) {
1052
+ return `<strong>${this.parser.parseInline(e)}</strong>`;
1053
+ }
1054
+ em({ tokens: e }) {
1055
+ return `<em>${this.parser.parseInline(e)}</em>`;
1056
+ }
1057
+ codespan({ text: e }) {
1058
+ return `<code>${q(e, !0)}</code>`;
1059
+ }
1060
+ br(e) {
1061
+ return "<br>";
1062
+ }
1063
+ del({ tokens: e }) {
1064
+ return `<del>${this.parser.parseInline(e)}</del>`;
1065
+ }
1066
+ link({ href: e, title: t, tokens: n }) {
1067
+ let r = this.parser.parseInline(n), i = Mt(e);
1068
+ if (i === null) return r;
1069
+ e = i;
1070
+ let a = "<a href=\"" + e + "\"";
1071
+ return t && (a += " title=\"" + q(t) + "\""), a += ">" + r + "</a>", a;
1072
+ }
1073
+ image({ href: e, title: t, text: n, tokens: r }) {
1074
+ r && (n = this.parser.parseInline(r, this.parser.textRenderer));
1075
+ let i = Mt(e);
1076
+ if (i === null) return q(n);
1077
+ e = i;
1078
+ let a = `<img src="${e}" alt="${n}"`;
1079
+ return t && (a += ` title="${q(t)}"`), a += ">", a;
1080
+ }
1081
+ text(e) {
1082
+ return "tokens" in e && e.tokens ? this.parser.parseInline(e.tokens) : "escaped" in e && e.escaped ? e.text : q(e.text);
1083
+ }
1084
+ }, Rt = class {
1085
+ strong({ text: e }) {
1086
+ return e;
1087
+ }
1088
+ em({ text: e }) {
1089
+ return e;
1090
+ }
1091
+ codespan({ text: e }) {
1092
+ return e;
1093
+ }
1094
+ del({ text: e }) {
1095
+ return e;
1096
+ }
1097
+ html({ text: e }) {
1098
+ return e;
1099
+ }
1100
+ text({ text: e }) {
1101
+ return e;
1102
+ }
1103
+ link({ text: e }) {
1104
+ return "" + e;
1105
+ }
1106
+ image({ text: e }) {
1107
+ return "" + e;
1108
+ }
1109
+ br() {
1110
+ return "";
1111
+ }
1112
+ }, Z = class e {
1113
+ options;
1114
+ renderer;
1115
+ textRenderer;
1116
+ constructor(e) {
1117
+ this.options = e || L, this.options.renderer = this.options.renderer || new Lt(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.renderer.parser = this, this.textRenderer = new Rt();
1118
+ }
1119
+ static parse(t, n) {
1120
+ return new e(n).parse(t);
1121
+ }
1122
+ static parseInline(t, n) {
1123
+ return new e(n).parseInline(t);
1124
+ }
1125
+ parse(e, t = !0) {
1126
+ let n = "";
1127
+ for (let r = 0; r < e.length; r++) {
1128
+ let i = e[r];
1129
+ if (this.options.extensions?.renderers?.[i.type]) {
1130
+ let e = i, t = this.options.extensions.renderers[e.type].call({ parser: this }, e);
1131
+ if (t !== !1 || ![
1132
+ "space",
1133
+ "hr",
1134
+ "heading",
1135
+ "code",
1136
+ "table",
1137
+ "blockquote",
1138
+ "list",
1139
+ "html",
1140
+ "paragraph",
1141
+ "text"
1142
+ ].includes(e.type)) {
1143
+ n += t || "";
1144
+ continue;
1145
+ }
1146
+ }
1147
+ let a = i;
1148
+ switch (a.type) {
1149
+ case "space":
1150
+ n += this.renderer.space(a);
1151
+ continue;
1152
+ case "hr":
1153
+ n += this.renderer.hr(a);
1154
+ continue;
1155
+ case "heading":
1156
+ n += this.renderer.heading(a);
1157
+ continue;
1158
+ case "code":
1159
+ n += this.renderer.code(a);
1160
+ continue;
1161
+ case "table":
1162
+ n += this.renderer.table(a);
1163
+ continue;
1164
+ case "blockquote":
1165
+ n += this.renderer.blockquote(a);
1166
+ continue;
1167
+ case "list":
1168
+ n += this.renderer.list(a);
1169
+ continue;
1170
+ case "html":
1171
+ n += this.renderer.html(a);
1172
+ continue;
1173
+ case "paragraph":
1174
+ n += this.renderer.paragraph(a);
1175
+ continue;
1176
+ case "text": {
1177
+ let i = a, o = this.renderer.text(i);
1178
+ for (; r + 1 < e.length && e[r + 1].type === "text";) i = e[++r], o += "\n" + this.renderer.text(i);
1179
+ t ? n += this.renderer.paragraph({
1180
+ type: "paragraph",
1181
+ raw: o,
1182
+ text: o,
1183
+ tokens: [{
1184
+ type: "text",
1185
+ raw: o,
1186
+ text: o,
1187
+ escaped: !0
1188
+ }]
1189
+ }) : n += o;
1190
+ continue;
1191
+ }
1192
+ default: {
1193
+ let e = "Token with \"" + a.type + "\" type was not found.";
1194
+ if (this.options.silent) return console.error(e), "";
1195
+ throw Error(e);
1196
+ }
1197
+ }
1198
+ }
1199
+ return n;
1200
+ }
1201
+ parseInline(e, t = this.renderer) {
1202
+ let n = "";
1203
+ for (let r = 0; r < e.length; r++) {
1204
+ let i = e[r];
1205
+ if (this.options.extensions?.renderers?.[i.type]) {
1206
+ let e = this.options.extensions.renderers[i.type].call({ parser: this }, i);
1207
+ if (e !== !1 || ![
1208
+ "escape",
1209
+ "html",
1210
+ "link",
1211
+ "image",
1212
+ "strong",
1213
+ "em",
1214
+ "codespan",
1215
+ "br",
1216
+ "del",
1217
+ "text"
1218
+ ].includes(i.type)) {
1219
+ n += e || "";
1220
+ continue;
1221
+ }
1222
+ }
1223
+ let a = i;
1224
+ switch (a.type) {
1225
+ case "escape":
1226
+ n += t.text(a);
1227
+ break;
1228
+ case "html":
1229
+ n += t.html(a);
1230
+ break;
1231
+ case "link":
1232
+ n += t.link(a);
1233
+ break;
1234
+ case "image":
1235
+ n += t.image(a);
1236
+ break;
1237
+ case "strong":
1238
+ n += t.strong(a);
1239
+ break;
1240
+ case "em":
1241
+ n += t.em(a);
1242
+ break;
1243
+ case "codespan":
1244
+ n += t.codespan(a);
1245
+ break;
1246
+ case "br":
1247
+ n += t.br(a);
1248
+ break;
1249
+ case "del":
1250
+ n += t.del(a);
1251
+ break;
1252
+ case "text":
1253
+ n += t.text(a);
1254
+ break;
1255
+ default: {
1256
+ let e = "Token with \"" + a.type + "\" type was not found.";
1257
+ if (this.options.silent) return console.error(e), "";
1258
+ throw Error(e);
1259
+ }
1260
+ }
1261
+ }
1262
+ return n;
1263
+ }
1264
+ }, zt = class {
1265
+ options;
1266
+ block;
1267
+ constructor(e) {
1268
+ this.options = e || L;
1269
+ }
1270
+ static passThroughHooks = /* @__PURE__ */ new Set([
1271
+ "preprocess",
1272
+ "postprocess",
1273
+ "processAllTokens"
1274
+ ]);
1275
+ preprocess(e) {
1276
+ return e;
1277
+ }
1278
+ postprocess(e) {
1279
+ return e;
1280
+ }
1281
+ processAllTokens(e) {
1282
+ return e;
1283
+ }
1284
+ provideLexer() {
1285
+ return this.block ? X.lex : X.lexInline;
1286
+ }
1287
+ provideParser() {
1288
+ return this.block ? Z.parse : Z.parseInline;
1289
+ }
1290
+ }, Q = new class {
1291
+ defaults = Ne();
1292
+ options = this.setOptions;
1293
+ parse = this.parseMarkdown(!0);
1294
+ parseInline = this.parseMarkdown(!1);
1295
+ Parser = Z;
1296
+ Renderer = Lt;
1297
+ TextRenderer = Rt;
1298
+ Lexer = X;
1299
+ Tokenizer = Y;
1300
+ Hooks = zt;
1301
+ constructor(...e) {
1302
+ this.use(...e);
1303
+ }
1304
+ walkTokens(e, t) {
1305
+ let n = [];
1306
+ for (let r of e) switch (n = n.concat(t.call(this, r)), r.type) {
1307
+ case "table": {
1308
+ let e = r;
1309
+ for (let r of e.header) n = n.concat(this.walkTokens(r.tokens, t));
1310
+ for (let r of e.rows) for (let e of r) n = n.concat(this.walkTokens(e.tokens, t));
1311
+ break;
1312
+ }
1313
+ case "list": {
1314
+ let e = r;
1315
+ n = n.concat(this.walkTokens(e.items, t));
1316
+ break;
1317
+ }
1318
+ default: {
1319
+ let e = r;
1320
+ this.defaults.extensions?.childTokens?.[e.type] ? this.defaults.extensions.childTokens[e.type].forEach((r) => {
1321
+ let i = e[r].flat(Infinity);
1322
+ n = n.concat(this.walkTokens(i, t));
1323
+ }) : e.tokens && (n = n.concat(this.walkTokens(e.tokens, t)));
1324
+ }
1325
+ }
1326
+ return n;
1327
+ }
1328
+ use(...e) {
1329
+ let t = this.defaults.extensions || {
1330
+ renderers: {},
1331
+ childTokens: {}
1332
+ };
1333
+ return e.forEach((e) => {
1334
+ let n = { ...e };
1335
+ if (n.async = this.defaults.async || n.async || !1, e.extensions && (e.extensions.forEach((e) => {
1336
+ if (!e.name) throw Error("extension name required");
1337
+ if ("renderer" in e) {
1338
+ let n = t.renderers[e.name];
1339
+ n ? t.renderers[e.name] = function(...t) {
1340
+ let r = e.renderer.apply(this, t);
1341
+ return r === !1 && (r = n.apply(this, t)), r;
1342
+ } : t.renderers[e.name] = e.renderer;
1343
+ }
1344
+ if ("tokenizer" in e) {
1345
+ if (!e.level || e.level !== "block" && e.level !== "inline") throw Error("extension level must be 'block' or 'inline'");
1346
+ let n = t[e.level];
1347
+ n ? n.unshift(e.tokenizer) : t[e.level] = [e.tokenizer], e.start && (e.level === "block" ? t.startBlock ? t.startBlock.push(e.start) : t.startBlock = [e.start] : e.level === "inline" && (t.startInline ? t.startInline.push(e.start) : t.startInline = [e.start]));
1348
+ }
1349
+ "childTokens" in e && e.childTokens && (t.childTokens[e.name] = e.childTokens);
1350
+ }), n.extensions = t), e.renderer) {
1351
+ let t = this.defaults.renderer || new Lt(this.defaults);
1352
+ for (let n in e.renderer) {
1353
+ if (!(n in t)) throw Error(`renderer '${n}' does not exist`);
1354
+ if (["options", "parser"].includes(n)) continue;
1355
+ let r = n, i = e.renderer[r], a = t[r];
1356
+ t[r] = (...e) => {
1357
+ let n = i.apply(t, e);
1358
+ return n === !1 && (n = a.apply(t, e)), n || "";
1359
+ };
1360
+ }
1361
+ n.renderer = t;
1362
+ }
1363
+ if (e.tokenizer) {
1364
+ let t = this.defaults.tokenizer || new Y(this.defaults);
1365
+ for (let n in e.tokenizer) {
1366
+ if (!(n in t)) throw Error(`tokenizer '${n}' does not exist`);
1367
+ if ([
1368
+ "options",
1369
+ "rules",
1370
+ "lexer"
1371
+ ].includes(n)) continue;
1372
+ let r = n, i = e.tokenizer[r], a = t[r];
1373
+ t[r] = (...e) => {
1374
+ let n = i.apply(t, e);
1375
+ return n === !1 && (n = a.apply(t, e)), n;
1376
+ };
1377
+ }
1378
+ n.tokenizer = t;
1379
+ }
1380
+ if (e.hooks) {
1381
+ let t = this.defaults.hooks || new zt();
1382
+ for (let n in e.hooks) {
1383
+ if (!(n in t)) throw Error(`hook '${n}' does not exist`);
1384
+ if (["options", "block"].includes(n)) continue;
1385
+ let r = n, i = e.hooks[r], a = t[r];
1386
+ zt.passThroughHooks.has(n) ? t[r] = (e) => {
1387
+ if (this.defaults.async) return Promise.resolve(i.call(t, e)).then((e) => a.call(t, e));
1388
+ let n = i.call(t, e);
1389
+ return a.call(t, n);
1390
+ } : t[r] = (...e) => {
1391
+ let n = i.apply(t, e);
1392
+ return n === !1 && (n = a.apply(t, e)), n;
1393
+ };
1394
+ }
1395
+ n.hooks = t;
1396
+ }
1397
+ if (e.walkTokens) {
1398
+ let t = this.defaults.walkTokens, r = e.walkTokens;
1399
+ n.walkTokens = function(e) {
1400
+ let n = [];
1401
+ return n.push(r.call(this, e)), t && (n = n.concat(t.call(this, e))), n;
1402
+ };
1403
+ }
1404
+ this.defaults = {
1405
+ ...this.defaults,
1406
+ ...n
1407
+ };
1408
+ }), this;
1409
+ }
1410
+ setOptions(e) {
1411
+ return this.defaults = {
1412
+ ...this.defaults,
1413
+ ...e
1414
+ }, this;
1415
+ }
1416
+ lexer(e, t) {
1417
+ return X.lex(e, t ?? this.defaults);
1418
+ }
1419
+ parser(e, t) {
1420
+ return Z.parse(e, t ?? this.defaults);
1421
+ }
1422
+ parseMarkdown(e) {
1423
+ return (t, n) => {
1424
+ let r = { ...n }, i = {
1425
+ ...this.defaults,
1426
+ ...r
1427
+ }, a = this.onError(!!i.silent, !!i.async);
1428
+ if (this.defaults.async === !0 && r.async === !1) return a(/* @__PURE__ */ Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));
1429
+ if (t == null) return a(/* @__PURE__ */ Error("marked(): input parameter is undefined or null"));
1430
+ if (typeof t != "string") return a(/* @__PURE__ */ Error("marked(): input parameter is of type " + Object.prototype.toString.call(t) + ", string expected"));
1431
+ i.hooks && (i.hooks.options = i, i.hooks.block = e);
1432
+ let o = i.hooks ? i.hooks.provideLexer() : e ? X.lex : X.lexInline, s = i.hooks ? i.hooks.provideParser() : e ? Z.parse : Z.parseInline;
1433
+ if (i.async) return Promise.resolve(i.hooks ? i.hooks.preprocess(t) : t).then((e) => o(e, i)).then((e) => i.hooks ? i.hooks.processAllTokens(e) : e).then((e) => i.walkTokens ? Promise.all(this.walkTokens(e, i.walkTokens)).then(() => e) : e).then((e) => s(e, i)).then((e) => i.hooks ? i.hooks.postprocess(e) : e).catch(a);
1434
+ try {
1435
+ i.hooks && (t = i.hooks.preprocess(t));
1436
+ let e = o(t, i);
1437
+ i.hooks && (e = i.hooks.processAllTokens(e)), i.walkTokens && this.walkTokens(e, i.walkTokens);
1438
+ let n = s(e, i);
1439
+ return i.hooks && (n = i.hooks.postprocess(n)), n;
1440
+ } catch (e) {
1441
+ return a(e);
1442
+ }
1443
+ };
1444
+ }
1445
+ onError(e, t) {
1446
+ return (n) => {
1447
+ if (n.message += "\nPlease report this to https://github.com/markedjs/marked.", e) {
1448
+ let e = "<p>An error occurred:</p><pre>" + q(n.message + "", !0) + "</pre>";
1449
+ return t ? Promise.resolve(e) : e;
1450
+ }
1451
+ if (t) return Promise.reject(n);
1452
+ throw n;
1453
+ };
1454
+ }
1455
+ }();
1456
+ function $(e, t) {
1457
+ return Q.parse(e, t);
1458
+ }
1459
+ //#endregion
1460
+ //#region src/lib/markdown.ts
1461
+ $.options = $.setOptions = function(e) {
1462
+ return Q.setOptions(e), $.defaults = Q.defaults, Pe($.defaults), $;
1463
+ }, $.getDefaults = Ne, $.defaults = L, $.use = function(...e) {
1464
+ return Q.use(...e), $.defaults = Q.defaults, Pe($.defaults), $;
1465
+ }, $.walkTokens = function(e, t) {
1466
+ return Q.walkTokens(e, t);
1467
+ }, $.parseInline = Q.parseInline, $.Parser = Z, $.parser = Z.parse, $.Renderer = Lt, $.TextRenderer = Rt, $.Lexer = X, $.lexer = X.lex, $.Tokenizer = Y, $.Hooks = zt, $.parse = $, $.options, $.setOptions, $.use, $.walkTokens, $.parseInline, Z.parse, X.lex, $.setOptions({
1468
+ gfm: !0,
1469
+ breaks: !1
1470
+ });
1471
+ function Bt(e) {
1472
+ return $.parse(e, { async: !1 });
1473
+ }
1474
+ //#endregion
1475
+ //#region src/ReqScreen.vue?vue&type=script&setup=true&lang.ts
1476
+ var Vt = {
1477
+ key: 0,
1478
+ class: "min-h-screen p-6"
1479
+ }, Ht = { class: "mb-5 flex items-center gap-4 rounded-lg border border-gray-200 bg-white px-5 py-3 text-gray-800 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-100" }, Ut = { class: "text-lg font-bold" }, Wt = { class: "ml-auto flex items-center gap-3" }, Gt = { class: "grid grid-cols-[minmax(0,1fr)_minmax(0,1fr)] gap-6" }, Kt = { class: "rounded-lg border border-gray-300 bg-white p-6 dark:border-gray-700 dark:bg-gray-800" }, qt = { class: "mb-3 flex items-center justify-between" }, Jt = {
1480
+ key: 0,
1481
+ class: "inline-flex overflow-hidden rounded-md border border-gray-300 text-xs font-bold dark:border-gray-600"
1482
+ }, Yt = ["onClick"], Xt = { class: "rounded-md bg-white p-4 transition-colors dark:bg-gray-800" }, Zt = {
1483
+ key: 0,
1484
+ class: "w-full"
1485
+ }, Qt = { class: "rounded-[2.5rem] bg-black p-3 shadow-xl" }, $t = { class: "relative overflow-hidden rounded-[1.8rem]" }, en = {
1486
+ key: 0,
1487
+ class: "pointer-events-none absolute left-1/2 top-0 z-10 h-6 w-28 -translate-x-1/2 rounded-b-2xl bg-black"
1488
+ }, tn = {
1489
+ key: 1,
1490
+ class: "w-full overflow-hidden rounded-xl border-2 border-gray-300 shadow-sm dark:border-gray-700"
1491
+ }, nn = { class: "rounded-lg border border-gray-300 bg-white p-6 dark:border-gray-700 dark:bg-gray-800" }, rn = ["innerHTML"], an = /* @__PURE__ */ l({
1492
+ __name: "ReqScreen",
1493
+ props: {
1494
+ title: {},
1495
+ doc: {}
1496
+ },
1497
+ setup(n) {
1498
+ let r = n, l = t(() => Bt(r.doc)), { isDark: te, toggle: re } = ue(), ie = ae(), S = oe(), C = h(S[0]?.id ?? ""), w = t(() => S.find((e) => e.id === C.value) ?? S[0]);
1499
+ function T(e) {
1500
+ return `${e}px`;
1501
+ }
1502
+ let E = se(), D = t(() => {
1503
+ let e = te.value ? E.dark : E.light;
1504
+ return {
1505
+ background: e.bg,
1506
+ color: e.font
1507
+ };
1508
+ }), O = h(null), k = h(null), A = h(0), j = h(0), M = t(() => {
1509
+ let e = w.value?.width ?? 0;
1510
+ return !e || A.value === 0 ? 1 : Math.min(1, A.value / e);
1511
+ }), N = t(() => w.value ? w.value.width * M.value : 0), ce = t(() => j.value * M.value), P = null;
1512
+ function F() {
1513
+ O.value && (A.value = O.value.clientWidth), k.value && (j.value = k.value.offsetHeight);
1514
+ }
1515
+ function le() {
1516
+ P?.disconnect(), O.value && P?.observe(O.value), k.value && P?.observe(k.value);
1517
+ }
1518
+ let I = h(!1);
1519
+ function de(e) {
1520
+ e.key === "Escape" && (I.value = !1);
1521
+ }
1522
+ return ee(() => {
1523
+ P = new ResizeObserver(() => F()), le(), F(), window.addEventListener("keydown", de);
1524
+ }), p(() => {
1525
+ P?.disconnect(), window.removeEventListener("keydown", de);
1526
+ }), ne([C, I], () => u(() => {
1527
+ le(), F();
1528
+ })), (t, r) => I.value ? (m(), a("div", {
1529
+ key: 1,
1530
+ class: "fixed inset-0 z-50 overflow-auto",
1531
+ style: f(D.value)
1532
+ }, [o("button", {
1533
+ type: "button",
1534
+ class: "fixed right-4 top-4 z-10 rounded-md border border-gray-300 bg-white px-3 py-1 text-xs font-bold text-gray-700 shadow-sm transition hover:bg-gray-100 dark:border-gray-600 dark:bg-gray-800 dark:text-gray-100 dark:hover:bg-gray-700",
1535
+ onClick: r[2] ||= (e) => I.value = !1
1536
+ }, " 閉じる(Esc) "), o("div", {
1537
+ ref_key: "areaRef",
1538
+ ref: O,
1539
+ class: "min-h-full"
1540
+ }, [w.value ? (m(), a("div", {
1541
+ key: 0,
1542
+ class: "mx-auto overflow-hidden",
1543
+ style: f({
1544
+ width: N.value ? `${N.value}px` : "",
1545
+ height: j.value ? `${ce.value}px` : "auto"
1546
+ })
1547
+ }, [o("div", {
1548
+ ref_key: "contentRef",
1549
+ ref: k,
1550
+ class: "origin-top-left",
1551
+ style: f({
1552
+ width: T(w.value.width),
1553
+ transform: `scale(${M.value})`
1554
+ })
1555
+ }, [_(t.$slots, "mock")], 4)], 4)) : i("", !0)], 512)], 4)) : (m(), a("div", Vt, [o("header", Ht, [
1556
+ c(y(x), {
1557
+ to: "/catalog",
1558
+ class: "text-sm text-gray-500 underline hover:text-gray-800 dark:text-gray-400 dark:hover:text-gray-100"
1559
+ }, {
1560
+ default: b(() => [...r[3] ||= [s(" ← 一覧 ", -1)]]),
1561
+ _: 1
1562
+ }),
1563
+ o("h1", Ut, v(n.title), 1),
1564
+ o("div", Wt, [
1565
+ _(t.$slots, "toolbar"),
1566
+ o("button", {
1567
+ type: "button",
1568
+ class: "rounded-md border border-gray-300 px-3 py-1 text-xs font-bold text-gray-600 transition hover:bg-gray-100 dark:border-gray-600 dark:text-gray-300 dark:hover:bg-gray-700",
1569
+ onClick: r[0] ||= (e) => I.value = !I.value
1570
+ }, v(I.value ? "要件を表示" : "プレビュー"), 1),
1571
+ y(ie) ? (m(), a("button", {
1572
+ key: 0,
1573
+ type: "button",
1574
+ class: "rounded-md border border-gray-300 px-3 py-1 text-xs font-bold text-gray-600 transition hover:bg-gray-100 dark:border-gray-600 dark:text-gray-300 dark:hover:bg-gray-700",
1575
+ onClick: r[1] ||= (...e) => y(re) && y(re)(...e)
1576
+ }, v(y(te) ? "ライトモード" : "ダークモード"), 1)) : i("", !0)
1577
+ ])
1578
+ ]), o("div", Gt, [o("section", Kt, [o("div", qt, [r[4] ||= o("span", { class: "text-xs font-bold uppercase tracking-wide text-gray-400" }, " 画面 mock ", -1), y(S).length > 1 ? (m(), a("div", Jt, [(m(!0), a(e, null, g(y(S), (e) => (m(), a("button", {
1579
+ key: e.id,
1580
+ type: "button",
1581
+ class: d(["px-3 py-1 transition", C.value === e.id ? "bg-gray-800 text-white dark:bg-gray-200 dark:text-gray-900" : "text-gray-600 hover:bg-gray-100 dark:text-gray-300 dark:hover:bg-gray-700"]),
1582
+ onClick: (t) => C.value = e.id
1583
+ }, v(e.label), 11, Yt))), 128))])) : i("", !0)]), o("div", Xt, [o("div", {
1584
+ ref_key: "areaRef",
1585
+ ref: O
1586
+ }, [w.value ? (m(), a("div", {
1587
+ key: 0,
1588
+ class: "mx-auto overflow-hidden",
1589
+ style: f({
1590
+ width: N.value ? `${N.value}px` : "",
1591
+ height: j.value ? `${ce.value}px` : "auto"
1592
+ })
1593
+ }, [o("div", {
1594
+ ref_key: "contentRef",
1595
+ ref: k,
1596
+ class: "origin-top-left",
1597
+ style: f({
1598
+ width: T(w.value.width),
1599
+ transform: `scale(${M.value})`
1600
+ })
1601
+ }, [w.value.frame === "phone" || w.value.frame === "tablet" ? (m(), a("div", Zt, [o("div", Qt, [o("div", $t, [w.value.frame === "phone" ? (m(), a("div", en)) : i("", !0), o("div", {
1602
+ class: d(["px-4 pb-6", w.value.frame === "phone" ? "pt-9" : "pt-6"]),
1603
+ style: f(D.value)
1604
+ }, [_(t.$slots, "mock"), r[5] ||= o("div", { class: "mx-auto mt-6 h-1 w-24 rounded-full bg-gray-300 dark:bg-gray-600" }, null, -1)], 6)])])])) : (m(), a("div", tn, [r[6] ||= o("div", { class: "flex items-center gap-2 border-b border-gray-300 bg-gray-800 px-3 py-2 dark:border-gray-700" }, [
1605
+ o("span", { class: "h-3 w-3 rounded-full bg-red-400" }),
1606
+ o("span", { class: "h-3 w-3 rounded-full bg-yellow-400" }),
1607
+ o("span", { class: "h-3 w-3 rounded-full bg-green-400" })
1608
+ ], -1), o("div", {
1609
+ class: "p-4",
1610
+ style: f(D.value)
1611
+ }, [_(t.$slots, "mock")], 4)]))], 4)], 4)) : i("", !0)], 512)])]), o("section", nn, [r[7] ||= o("div", { class: "mb-3 text-xs font-bold uppercase tracking-wide text-gray-400" }, " 要件 ", -1), o("div", {
1612
+ class: "req-md",
1613
+ innerHTML: l.value
1614
+ }, null, 8, rn)])])]));
1615
+ }
1616
+ }), on = { class: "flex items-center gap-2 text-sm" }, sn = ["value"], cn = ["value"], ln = ["innerHTML"], un = {
1617
+ key: 1,
1618
+ class: "p-8"
1619
+ }, dn = { class: "text-gray-600" }, fn = /* @__PURE__ */ l({
1620
+ __name: "ReqPageView",
1621
+ props: {
1622
+ kind: {},
1623
+ name: {},
1624
+ ver: {}
1625
+ },
1626
+ setup(n) {
1627
+ let i = n, l = C(), u = t(() => le(i.kind, i.name)), d = t(() => i.ver || u.value?.latest || ""), f = t(() => u.value?.versions[d.value]), p = t(() => u.value ? Object.keys(u.value.versions) : []);
1628
+ function ee(e) {
1629
+ let t = e.target.value;
1630
+ l.push(`/${i.kind}s/${i.name}/${t}`);
1631
+ }
1632
+ return (t, i) => u.value && f.value ? (m(), r(an, {
1633
+ key: 0,
1634
+ title: u.value.title,
1635
+ doc: f.value.req
1636
+ }, {
1637
+ toolbar: b(() => [o("label", on, [i[0] ||= o("span", { class: "text-gray-500 dark:text-gray-400" }, "バージョン", -1), o("select", {
1638
+ value: d.value,
1639
+ class: "rounded border border-gray-300 bg-white px-2 py-1 text-gray-800 dark:border-gray-600 dark:bg-gray-700 dark:text-gray-100",
1640
+ onChange: ee
1641
+ }, [(m(!0), a(e, null, g(p.value, (e) => (m(), a("option", {
1642
+ key: e,
1643
+ value: e
1644
+ }, v(e), 9, cn))), 128))], 40, sn)])]),
1645
+ mock: b(() => [typeof f.value.view == "string" ? (m(), a("div", {
1646
+ key: 0,
1647
+ innerHTML: f.value.view
1648
+ }, null, 8, ln)) : (m(), r(te(f.value.view), { key: 1 }))]),
1649
+ _: 1
1650
+ }, 8, ["title", "doc"])) : (m(), a("div", un, [o("p", dn, "該当するアイテムが見つかりません: " + v(n.kind) + " / " + v(n.name), 1), c(y(x), {
1651
+ to: "/catalog",
1652
+ class: "text-blue-600 underline"
1653
+ }, {
1654
+ default: b(() => [...i[1] ||= [s("← 一覧へ戻る", -1)]]),
1655
+ _: 1
1656
+ })]));
1657
+ }
1658
+ }), pn = { class: "min-h-screen p-6" }, mn = { class: "mb-5 flex items-center gap-4 rounded-lg border border-gray-200 bg-white px-5 py-3 text-gray-800 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-100" }, hn = { class: "rounded-lg bg-gray-50 p-5 transition-colors dark:bg-gray-900" }, gn = { class: "grid grid-cols-2 gap-4 sm:grid-cols-3 lg:grid-cols-4" }, _n = { class: "p-3" }, vn = { class: "font-mono text-sm font-bold dark:text-gray-100" }, yn = { class: "mt-1 space-y-0.5 font-mono text-xs" }, bn = {
1659
+ key: 0,
1660
+ class: "mt-1 text-xs text-gray-600 dark:text-gray-400"
1661
+ }, xn = /* @__PURE__ */ l({
1662
+ __name: "ColorsView",
1663
+ setup(t) {
1664
+ let { isDark: n, toggle: r } = ue(), l = ae(), u = se(), p = [
1665
+ {
1666
+ name: "baseBg",
1667
+ light: u.light.bg,
1668
+ dark: u.dark.bg,
1669
+ desc: "モック画面の背景"
1670
+ },
1671
+ {
1672
+ name: "baseFont",
1673
+ light: u.light.font,
1674
+ dark: u.dark.font,
1675
+ desc: "モックの基本文字色"
1676
+ },
1677
+ ...F()
1678
+ ];
1679
+ return (t, u) => (m(), a("div", pn, [o("header", mn, [
1680
+ c(y(x), {
1681
+ to: "/catalog",
1682
+ class: "text-sm text-gray-500 underline hover:text-gray-800 dark:text-gray-400 dark:hover:text-gray-100"
1683
+ }, {
1684
+ default: b(() => [...u[1] ||= [s(" ← 一覧 ", -1)]]),
1685
+ _: 1
1686
+ }),
1687
+ u[2] ||= o("h1", { class: "text-lg font-bold" }, "カラー", -1),
1688
+ y(l) ? (m(), a("button", {
1689
+ key: 0,
1690
+ type: "button",
1691
+ class: "ml-auto rounded-md border border-gray-300 px-3 py-1 text-xs font-bold text-gray-600 transition hover:bg-gray-100 dark:border-gray-600 dark:text-gray-300 dark:hover:bg-gray-700",
1692
+ onClick: u[0] ||= (...e) => y(r) && y(r)(...e)
1693
+ }, v(y(n) ? "ライトモード" : "ダークモード"), 1)) : i("", !0)
1694
+ ]), o("div", hn, [o("div", gn, [(m(), a(e, null, g(p, (e) => o("div", {
1695
+ key: e.name,
1696
+ class: "overflow-hidden rounded-lg border border-gray-300 bg-white dark:border-gray-700 dark:bg-gray-800"
1697
+ }, [o("div", {
1698
+ class: "h-24 w-full border-b border-gray-200 dark:border-gray-700",
1699
+ style: f({ background: y(n) ? e.dark : e.light })
1700
+ }, null, 4), o("div", _n, [
1701
+ o("div", vn, v(e.name), 1),
1702
+ o("div", yn, [o("div", { class: d(y(n) ? "text-gray-500" : "font-bold text-gray-700") }, " light: " + v(e.light), 3), o("div", { class: d(y(n) ? "font-bold text-gray-200" : "text-gray-500") }, " dark: " + v(e.dark), 3)]),
1703
+ e.desc ? (m(), a("div", bn, v(e.desc), 1)) : i("", !0)
1704
+ ])])), 64))])])]));
1705
+ }
1706
+ });
1707
+ //#endregion
1708
+ //#region src/router.ts
1709
+ function Sn() {
1710
+ return ie({
1711
+ history: S(),
1712
+ routes: [
1713
+ {
1714
+ path: "/",
1715
+ redirect: "/catalog"
1716
+ },
1717
+ {
1718
+ path: "/catalog",
1719
+ name: "catalog",
1720
+ component: Me
1721
+ },
1722
+ {
1723
+ path: "/colors",
1724
+ name: "colors",
1725
+ component: xn
1726
+ },
1727
+ {
1728
+ path: "/components/:name/:ver?",
1729
+ name: "component",
1730
+ component: fn,
1731
+ props: (e) => ({
1732
+ kind: "component",
1733
+ name: e.params.name,
1734
+ ver: e.params.ver
1735
+ })
1736
+ },
1737
+ {
1738
+ path: "/pages/:name/:ver?",
1739
+ name: "page",
1740
+ component: fn,
1741
+ props: (e) => ({
1742
+ kind: "page",
1743
+ name: e.params.name,
1744
+ ver: e.params.ver
1745
+ })
1746
+ }
1747
+ ]
1748
+ });
1749
+ }
1750
+ //#endregion
1751
+ //#region src/createSpecViewer.ts
1752
+ function Cn(e) {
1753
+ N(e);
1754
+ let t = n(w);
1755
+ return t.use(Sn()), t;
1756
+ }
1757
+ //#endregion
1758
+ export { Cn as createSpecViewer };