@morlay/dsh-session-mode 0.0.13 → 0.0.14-alpha.2
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/{catalog-K5cESbqA.cjs → catalog-C_6kb1aC.cjs} +2 -3
- package/dist/{catalog-DWxIg3qw.mjs → catalog-D-n_RctY.mjs} +2 -3
- package/dist/{catalog-remote-KXJjDaN6.mjs → catalog-remote-Cz8L_Zrl.mjs} +1 -2
- package/dist/{catalog-remote-B7ZgYqun.cjs → catalog-remote-DWV4E4Vo.cjs} +1 -2
- package/dist/client.cjs +1228 -520
- package/dist/client.d.cts +0 -14
- package/dist/client.d.mts +0 -14
- package/dist/client.mjs +11 -22
- package/dist/index.cjs +62 -42
- package/dist/index.d.mts +9 -7
- package/dist/index.mjs +62 -42
- package/dist/rows.cjs +8 -6
- package/dist/rows.d.mts +1 -3
- package/dist/rows.mjs +8 -6
- package/dist/{shared-BusmswG5.cjs → shared-DO1nZbJ0.cjs} +2 -4
- package/dist/{shared-DX2Giyh3.mjs → shared-vjlwxiMt.mjs} +1 -2
- package/dist/testing.cjs +2 -2
- package/dist/testing.d.mts +0 -4
- package/dist/testing.mjs +2 -2
- package/package.json +56 -56
- package/src/index.ts +62 -21
- package/src/mode-sources.ts +6 -3
- package/src/scope.ts +53 -36
package/dist/client.cjs
CHANGED
|
@@ -4,7 +4,7 @@ window.__ModuleLoader__.load({
|
|
|
4
4
|
var module = { exports: {} };
|
|
5
5
|
var exports = module.exports;
|
|
6
6
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
7
|
-
|
|
7
|
+
// \0rolldown/runtime.js
|
|
8
8
|
var __defProp = Object.defineProperty;
|
|
9
9
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
10
10
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
@@ -29,13 +29,12 @@ window.__ModuleLoader__.load({
|
|
|
29
29
|
return to;
|
|
30
30
|
};
|
|
31
31
|
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
32
|
-
//#endregion
|
|
33
32
|
let _deepseek_ai_dsh_client_store = require("@deepseek-ai/dsh-client-store");
|
|
34
33
|
let _deepseek_ai_cordis = require("@deepseek-ai/cordis");
|
|
35
34
|
let react = require("react");
|
|
36
35
|
let _deepseek_ai_dsh_client_ui_primitives = require("@deepseek-ai/dsh-client-ui-primitives");
|
|
37
36
|
let react_jsx_runtime = require("react/jsx-runtime");
|
|
38
|
-
|
|
37
|
+
// src/catalog-remote.ts
|
|
39
38
|
const CATALOG_NS = "sessionModeCatalog";
|
|
40
39
|
const SESSION_MODE_CATALOG_REMOTE = {
|
|
41
40
|
package: "@morlay/dsh-session-mode",
|
|
@@ -50,8 +49,7 @@ window.__ModuleLoader__.load({
|
|
|
50
49
|
result: { mode: "src-json" }
|
|
51
50
|
}]
|
|
52
51
|
};
|
|
53
|
-
|
|
54
|
-
//#region src/shared.ts
|
|
52
|
+
// src/shared.ts
|
|
55
53
|
const SESSION_MODE_PATH = "/session-mode";
|
|
56
54
|
const POLICY_NAMES = ["fs/write-intent", "fs/edit-intent"];
|
|
57
55
|
function emptyMeta() {
|
|
@@ -547,8 +545,7 @@ window.__ModuleLoader__.load({
|
|
|
547
545
|
}
|
|
548
546
|
return node.variants[0];
|
|
549
547
|
}
|
|
550
|
-
|
|
551
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/draft.ts
|
|
548
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/draft.ts
|
|
552
549
|
function failureOf(error) {
|
|
553
550
|
const raw = error instanceof Error ? error.message : String(error);
|
|
554
551
|
const path = (error.options?.path ?? []).filter((segment) => typeof segment === "string" || typeof segment === "number").map(String);
|
|
@@ -835,8 +832,7 @@ window.__ModuleLoader__.load({
|
|
|
835
832
|
}
|
|
836
833
|
return next;
|
|
837
834
|
}
|
|
838
|
-
|
|
839
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/controller.ts
|
|
835
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/controller.ts
|
|
840
836
|
function declaredSource(node) {
|
|
841
837
|
const extra = node?.meta.extra;
|
|
842
838
|
if (typeof extra !== "object" || extra === null) return void 0;
|
|
@@ -1039,8 +1035,7 @@ window.__ModuleLoader__.load({
|
|
|
1039
1035
|
};
|
|
1040
1036
|
}
|
|
1041
1037
|
};
|
|
1042
|
-
|
|
1043
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/hints.ts
|
|
1038
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/hints.ts
|
|
1044
1039
|
var SchemaFormHints = class extends _deepseek_ai_cordis.Service {
|
|
1045
1040
|
readers = /* @__PURE__ */ new Map();
|
|
1046
1041
|
texts = /* @__PURE__ */ new Map();
|
|
@@ -1129,8 +1124,7 @@ window.__ModuleLoader__.load({
|
|
|
1129
1124
|
const wildcardable = Math.max(0, path.length - 1);
|
|
1130
1125
|
for (let bits = (1 << wildcardable) - 1; bits > 0; bits--) yield path.map((segment, index) => index > 0 && (bits & 1 << index - 1) !== 0 ? "*" : segment);
|
|
1131
1126
|
}
|
|
1132
|
-
|
|
1133
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/locales.ts
|
|
1127
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/locales.ts
|
|
1134
1128
|
const zh$1 = {
|
|
1135
1129
|
unavailable: "该插件当前未加载,暂时无法配置。",
|
|
1136
1130
|
readOnly: "本部署的设置为只读。",
|
|
@@ -1239,8 +1233,7 @@ window.__ModuleLoader__.load({
|
|
|
1239
1233
|
duplicateItem: "Duplicate {key}: {value}",
|
|
1240
1234
|
missingItem: "Every item needs a {key}"
|
|
1241
1235
|
};
|
|
1242
|
-
|
|
1243
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/rows.ts
|
|
1236
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/rows.ts
|
|
1244
1237
|
function rowRegistrations(namespaces, bundles) {
|
|
1245
1238
|
const owners = /* @__PURE__ */ new Map();
|
|
1246
1239
|
for (const bundle of bundles) for (const row of bundle.rows) owners.set(row.rowId, bundle.name);
|
|
@@ -1312,16 +1305,14 @@ window.__ModuleLoader__.load({
|
|
|
1312
1305
|
}
|
|
1313
1306
|
}
|
|
1314
1307
|
};
|
|
1315
|
-
|
|
1316
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/labels.ts
|
|
1308
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/labels.ts
|
|
1317
1309
|
function fieldHint(node, resolveText) {
|
|
1318
1310
|
const parts = [];
|
|
1319
1311
|
if (node.meta.description !== void 0) parts.push(resolveText(node.meta.description));
|
|
1320
1312
|
if (node.meta.comment !== void 0) parts.push(node.meta.comment);
|
|
1321
1313
|
return parts.length === 0 ? void 0 : parts.join(" ");
|
|
1322
1314
|
}
|
|
1323
|
-
|
|
1324
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/lines.ts
|
|
1315
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/lines.ts
|
|
1325
1316
|
function containerShape(node, value) {
|
|
1326
1317
|
switch (variantOf(node, value).type) {
|
|
1327
1318
|
case "object":
|
|
@@ -1490,9 +1481,8 @@ window.__ModuleLoader__.load({
|
|
|
1490
1481
|
if (prefix.length > path.length) return false;
|
|
1491
1482
|
return prefix.every((segment, index) => path[index] === segment);
|
|
1492
1483
|
}
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
const css$14 = ".N3kx7G_editorRoot{width:100%;color:var(--dsw-alias-label-primary);flex-direction:column;font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,monospace;font-size:14px;line-height:22px;display:flex}.N3kx7G_lineRow{white-space:nowrap;align-items:flex-start;gap:6px;min-height:22px;padding-right:8px;display:flex}.N3kx7G_lineRow:hover{background:var(--dsw-alias-bg-layer-2)}.N3kx7G_lineRow[data-selected=true]{background:var(--dsw-alias-bg-layer-3)}.N3kx7G_lineRow[data-dirty=true]{box-shadow:inset 2px 0 0 var(--dsw-alias-brand-primary)}.N3kx7G_lineRow[data-overridden=true]{box-shadow:inset 2px 0 0 var(--dsw-elevation-stroke-color)}.N3kx7G_lineRow[data-dirty=true] [data-role=key],.N3kx7G_lineRow[data-overridden=true] [data-role=key]{color:var(--dsw-alias-brand-primary)}.N3kx7G_lineRow[data-invalid=true]{background:color-mix(in srgb, var(--dsw-alias-state-error-secondary) 12%, transparent);box-shadow:inset 2px 0 0 var(--dsw-alias-state-error-primary)}.N3kx7G_lineRow[data-invalid=true] [data-role=key]{color:var(--dsw-alias-state-error-primary)}.N3kx7G_lineRow:hover [data-role=actions]{opacity:1}.N3kx7G_lineBody{flex:1;align-items:center;gap:6px;min-width:0;min-height:22px;display:flex}.N3kx7G_lineNumber{text-align:right;width:32px;color:var(--dsw-alias-label-caption);user-select:none;cursor:pointer;flex:none;line-height:22px}.N3kx7G_lineFold{width:14px;height:22px;color:var(--dsw-alias-label-caption);cursor:pointer;background:0 0;border:0;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.N3kx7G_lineFold:hover{color:var(--dsw-alias-label-secondary)}.N3kx7G_lineFoldSpacer{flex:none;width:14px}.N3kx7G_lineKey{color:var(--dsw-alias-label-primary);flex:none}.N3kx7G_lineKey[data-index=true]{color:var(--dsw-alias-label-caption)}.N3kx7G_lineToken{color:var(--dsw-alias-label-caption);flex:none}.N3kx7G_lineValue{text-overflow:ellipsis;cursor:text;min-width:0;color:var(--dsw-alias-state-business-primary);display:block;overflow:hidden}.N3kx7G_lineValue[data-tone=number]{color:var(--dsw-alias-state-warn-primary)}.N3kx7G_lineValue[data-tone=boolean]{color:var(--dsw-alias-state-success-primary)}.N3kx7G_lineValue[data-tone=empty]{color:var(--dsw-alias-label-caption)}.N3kx7G_valueSlot{flex:0 auto;min-width:0;display:block;overflow:hidden}.N3kx7G_valueTrigger{min-width:0;font:inherit;text-align:left;cursor:pointer;color:var(--dsw-alias-label-caption);background:0 0;border:0;align-items:center;gap:2px;padding:0;display:inline-flex}.N3kx7G_valueTrigger:disabled{cursor:default}.N3kx7G_valueTrigger:focus-visible{outline:none}.N3kx7G_compactInput{flex:auto;min-width:0;display:inline-flex}.N3kx7G_compactInput>span{border-radius:4px;width:100%;height:22px;padding:0 6px}.N3kx7G_compactInput input{font-size:14px;line-height:22px}.N3kx7G_compactTextField{background:var(--dsw-alias-bg-layer-1);min-width:0;box-shadow:0 0 0 .5px var(--dsw-elevation-stroke-color);border:0;border-radius:4px;flex:auto;padding:0 6px;display:inline-flex}.N3kx7G_compactTextField:focus-within{--dsw-elevation-stroke-color:var(--dsw-alias-brand-primary)}.N3kx7G_compactTextField>textarea{resize:none;field-sizing:content;width:100%;min-height:20px;max-height:240px;color:var(--dsw-alias-label-primary);background:0 0;border:0;outline:none;flex:1;padding:0;font-family:inherit;font-size:14px;line-height:22px}.N3kx7G_lineComment{text-overflow:ellipsis;min-width:0;color:var(--dsw-alias-label-tertiary);flex:auto;font-family:inherit;font-size:12px;overflow:hidden}.N3kx7G_lineInvalid{text-overflow:ellipsis;min-width:0;color:var(--dsw-alias-state-error-primary);flex:0 auto;font-family:inherit;font-size:12px;overflow:hidden}.N3kx7G_lineActions{opacity:0;flex:none;align-items:center;gap:4px;display:inline-flex}.N3kx7G_lineActions>button{width:20px;height:20px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;border-radius:4px;justify-content:center;align-items:center;padding:0;display:inline-flex}.N3kx7G_lineActions>button:hover{background:var(--dsw-alias-bg-layer-3);color:var(--dsw-alias-label-primary)}.N3kx7G_lineActions>button:disabled{cursor:not-allowed;color:var(--dsw-alias-label-dimmed)}.N3kx7G_hoverActions[data-editing=true]{opacity:1;gap:6px}.N3kx7G_hoverActions[data-editing=true]>button{box-shadow:0 0 0 .5px var(--dsw-elevation-stroke-color);background:var(--dsw-alias-bg-layer-1);color:var(--dsw-alias-label-primary)}.N3kx7G_hoverActions[data-editing=true]>button:first-of-type{color:var(--dsw-alias-state-success-primary)}.N3kx7G_addWrap{flex:auto;align-items:center;gap:6px;min-width:0;margin-left:6px;display:inline-flex;position:relative}.N3kx7G_addWrap[data-invalid=true] input{border-color:var(--dsw-alias-state-error-primary)}.N3kx7G_hint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}";
|
|
1484
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/schema-form/schema-form.module.css.mjs
|
|
1485
|
+
const css$14 = ".oZhWGq_editorRoot{width:100%;color:var(--dsw-alias-label-primary);flex-direction:column;font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,monospace;font-size:14px;line-height:22px;display:flex}.oZhWGq_lineRow{white-space:nowrap;align-items:flex-start;gap:6px;min-height:22px;padding-right:8px;display:flex}.oZhWGq_lineRow:hover{background:var(--dsw-alias-bg-layer-2)}.oZhWGq_lineRow[data-selected=true]{background:var(--dsw-alias-bg-layer-3)}.oZhWGq_lineRow[data-dirty=true]{box-shadow:inset 2px 0 0 var(--dsw-alias-brand-primary)}.oZhWGq_lineRow[data-overridden=true]{box-shadow:inset 2px 0 0 var(--dsw-elevation-stroke-color)}.oZhWGq_lineRow[data-dirty=true] [data-role=key],.oZhWGq_lineRow[data-overridden=true] [data-role=key]{color:var(--dsw-alias-brand-primary)}.oZhWGq_lineRow[data-invalid=true]{background:color-mix(in srgb, var(--dsw-alias-state-error-secondary) 12%, transparent);box-shadow:inset 2px 0 0 var(--dsw-alias-state-error-primary)}.oZhWGq_lineRow[data-invalid=true] [data-role=key]{color:var(--dsw-alias-state-error-primary)}.oZhWGq_lineRow:hover [data-role=actions]{opacity:1}.oZhWGq_lineBody{flex:1;align-items:center;gap:6px;min-width:0;min-height:22px;display:flex}.oZhWGq_lineNumber{text-align:right;width:32px;color:var(--dsw-alias-label-caption);user-select:none;cursor:pointer;flex:none;line-height:22px}.oZhWGq_lineFold{width:14px;height:22px;color:var(--dsw-alias-label-caption);cursor:pointer;background:0 0;border:0;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.oZhWGq_lineFold:hover{color:var(--dsw-alias-label-secondary)}.oZhWGq_lineFoldSpacer{flex:none;width:14px}.oZhWGq_lineKey{color:var(--dsw-alias-label-primary);flex:none}.oZhWGq_lineKey[data-index=true]{color:var(--dsw-alias-label-caption)}.oZhWGq_lineToken{color:var(--dsw-alias-label-caption);flex:none}.oZhWGq_lineValue{text-overflow:ellipsis;cursor:text;min-width:0;color:var(--dsw-alias-state-business-primary);display:block;overflow:hidden}.oZhWGq_lineValue[data-tone=number]{color:var(--dsw-alias-state-warn-primary)}.oZhWGq_lineValue[data-tone=boolean]{color:var(--dsw-alias-state-success-primary)}.oZhWGq_lineValue[data-tone=empty]{color:var(--dsw-alias-label-caption)}.oZhWGq_valueSlot{flex:0 auto;min-width:0;display:block;overflow:hidden}.oZhWGq_valueTrigger{min-width:0;font:inherit;text-align:left;cursor:pointer;color:var(--dsw-alias-label-caption);background:0 0;border:0;align-items:center;gap:2px;padding:0;display:inline-flex}.oZhWGq_valueTrigger:disabled{cursor:default}.oZhWGq_valueTrigger:focus-visible{outline:none}.oZhWGq_compactInput{flex:auto;min-width:0;display:inline-flex}.oZhWGq_compactInput>span{border-radius:4px;width:100%;height:22px;padding:0 6px}.oZhWGq_compactInput input{font-size:14px;line-height:22px}.oZhWGq_compactTextField{background:var(--dsw-alias-bg-layer-1);min-width:0;box-shadow:0 0 0 .5px var(--dsw-elevation-stroke-color);border:0;border-radius:4px;flex:auto;padding:0 6px;display:inline-flex}.oZhWGq_compactTextField:focus-within{--dsw-elevation-stroke-color:var(--dsw-alias-brand-primary)}.oZhWGq_compactTextField>textarea{resize:none;field-sizing:content;width:100%;min-height:20px;max-height:240px;color:var(--dsw-alias-label-primary);background:0 0;border:0;outline:none;flex:1;padding:0;font-family:inherit;font-size:14px;line-height:22px}.oZhWGq_lineComment{text-overflow:ellipsis;min-width:0;color:var(--dsw-alias-label-tertiary);flex:auto;font-family:inherit;font-size:12px;overflow:hidden}.oZhWGq_lineInvalid{text-overflow:ellipsis;min-width:0;color:var(--dsw-alias-state-error-primary);flex:0 auto;font-family:inherit;font-size:12px;overflow:hidden}.oZhWGq_lineActions{opacity:0;flex:none;align-items:center;gap:4px;display:inline-flex}.oZhWGq_lineActions>button{width:20px;height:20px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;border-radius:4px;justify-content:center;align-items:center;padding:0;display:inline-flex}.oZhWGq_lineActions>button:hover{background:var(--dsw-alias-bg-layer-3);color:var(--dsw-alias-label-primary)}.oZhWGq_lineActions>button:disabled{cursor:not-allowed;color:var(--dsw-alias-label-dimmed)}.oZhWGq_hoverActions[data-editing=true]{opacity:1;gap:6px}.oZhWGq_hoverActions[data-editing=true]>button{box-shadow:0 0 0 .5px var(--dsw-elevation-stroke-color);background:var(--dsw-alias-bg-layer-1);color:var(--dsw-alias-label-primary)}.oZhWGq_hoverActions[data-editing=true]>button:first-of-type{color:var(--dsw-alias-state-success-primary)}.oZhWGq_addWrap{flex:auto;align-items:center;gap:6px;min-width:0;margin-left:6px;display:inline-flex;position:relative}.oZhWGq_addWrap[data-invalid=true] input{border-color:var(--dsw-alias-state-error-primary)}.oZhWGq_hint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}";
|
|
1496
1486
|
const tagId$14 = "@morlay/dsh-session-mode/schema-form.module.css";
|
|
1497
1487
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/schema-form.module.css\"]") === null) {
|
|
1498
1488
|
const tag = document.createElement("style");
|
|
@@ -1502,28 +1492,27 @@ window.__ModuleLoader__.load({
|
|
|
1502
1492
|
document.head.appendChild(tag);
|
|
1503
1493
|
}
|
|
1504
1494
|
var schema_form_module_css_default = {
|
|
1505
|
-
"
|
|
1506
|
-
"
|
|
1507
|
-
"
|
|
1508
|
-
"
|
|
1509
|
-
"
|
|
1510
|
-
"
|
|
1511
|
-
"
|
|
1512
|
-
"
|
|
1513
|
-
"
|
|
1514
|
-
"
|
|
1515
|
-
"
|
|
1516
|
-
"
|
|
1517
|
-
"
|
|
1518
|
-
"
|
|
1519
|
-
"
|
|
1520
|
-
"
|
|
1521
|
-
"
|
|
1522
|
-
"
|
|
1523
|
-
"
|
|
1495
|
+
"editorRoot": "oZhWGq_editorRoot",
|
|
1496
|
+
"lineActions": "oZhWGq_lineActions",
|
|
1497
|
+
"lineNumber": "oZhWGq_lineNumber",
|
|
1498
|
+
"compactInput": "oZhWGq_compactInput",
|
|
1499
|
+
"valueTrigger": "oZhWGq_valueTrigger",
|
|
1500
|
+
"lineKey": "oZhWGq_lineKey",
|
|
1501
|
+
"compactTextField": "oZhWGq_compactTextField",
|
|
1502
|
+
"hoverActions": "oZhWGq_hoverActions",
|
|
1503
|
+
"lineToken": "oZhWGq_lineToken",
|
|
1504
|
+
"lineInvalid": "oZhWGq_lineInvalid",
|
|
1505
|
+
"lineRow": "oZhWGq_lineRow",
|
|
1506
|
+
"lineValue": "oZhWGq_lineValue",
|
|
1507
|
+
"lineComment": "oZhWGq_lineComment",
|
|
1508
|
+
"addWrap": "oZhWGq_addWrap",
|
|
1509
|
+
"valueSlot": "oZhWGq_valueSlot",
|
|
1510
|
+
"hint": "oZhWGq_hint",
|
|
1511
|
+
"lineFold": "oZhWGq_lineFold",
|
|
1512
|
+
"lineBody": "oZhWGq_lineBody",
|
|
1513
|
+
"lineFoldSpacer": "oZhWGq_lineFoldSpacer"
|
|
1524
1514
|
};
|
|
1525
|
-
|
|
1526
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/TruncatedTooltip.tsx
|
|
1515
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/TruncatedTooltip.tsx
|
|
1527
1516
|
function TruncatedTooltip({ label, children }) {
|
|
1528
1517
|
const node = (0, react.useRef)(null);
|
|
1529
1518
|
const watch = (0, react.useRef)(null);
|
|
@@ -1551,8 +1540,7 @@ window.__ModuleLoader__.load({
|
|
|
1551
1540
|
children: (0, react.cloneElement)(children, { ref: anchor })
|
|
1552
1541
|
});
|
|
1553
1542
|
}
|
|
1554
|
-
|
|
1555
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/value.tsx
|
|
1543
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/value.tsx
|
|
1556
1544
|
function valueText(value) {
|
|
1557
1545
|
if (value === void 0 || value === null) return "";
|
|
1558
1546
|
if (typeof value === "string") return value;
|
|
@@ -1643,8 +1631,7 @@ window.__ModuleLoader__.load({
|
|
|
1643
1631
|
function SchemaFieldDefault({ owner }) {
|
|
1644
1632
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(InlineValue, { owner });
|
|
1645
1633
|
}
|
|
1646
|
-
|
|
1647
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/fields.tsx
|
|
1634
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/fields.tsx
|
|
1648
1635
|
function parseFor(node, t) {
|
|
1649
1636
|
switch (node.type) {
|
|
1650
1637
|
case "number": return (text) => {
|
|
@@ -1756,13 +1743,11 @@ window.__ModuleLoader__.load({
|
|
|
1756
1743
|
});
|
|
1757
1744
|
}
|
|
1758
1745
|
}
|
|
1759
|
-
|
|
1760
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/classes.ts
|
|
1746
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/classes.ts
|
|
1761
1747
|
function classes(...names) {
|
|
1762
1748
|
return names.filter((name) => typeof name === "string" && name !== "").join(" ");
|
|
1763
1749
|
}
|
|
1764
|
-
|
|
1765
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/Editor.tsx
|
|
1750
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/Editor.tsx
|
|
1766
1751
|
function Editor(props) {
|
|
1767
1752
|
const { ns, state, face, t, resolveText, renderField } = props;
|
|
1768
1753
|
const [toggled, setToggled] = (0, react.useState)(() => /* @__PURE__ */ new Set());
|
|
@@ -2301,8 +2286,7 @@ window.__ModuleLoader__.load({
|
|
|
2301
2286
|
]
|
|
2302
2287
|
});
|
|
2303
2288
|
}
|
|
2304
|
-
|
|
2305
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/SchemaForm.tsx
|
|
2289
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/SchemaForm.tsx
|
|
2306
2290
|
function SchemaForm(props) {
|
|
2307
2291
|
const { ns, face, t, resolveText, renderSlotChain } = props;
|
|
2308
2292
|
const store = face.hooks.schemaForm;
|
|
@@ -2351,8 +2335,7 @@ window.__ModuleLoader__.load({
|
|
|
2351
2335
|
owner.onEditText(text, parse ?? parseFor(owner.node, t));
|
|
2352
2336
|
};
|
|
2353
2337
|
}
|
|
2354
|
-
|
|
2355
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/schema-form/index.ts
|
|
2338
|
+
// ../../client/dsh-client-ui-primitives/src/client/schema-form/index.ts
|
|
2356
2339
|
var schema_form_exports = /* @__PURE__ */ __exportAll({
|
|
2357
2340
|
InlineValue: () => InlineValue,
|
|
2358
2341
|
NS: () => NS$1,
|
|
@@ -2490,8 +2473,7 @@ window.__ModuleLoader__.load({
|
|
|
2490
2473
|
};
|
|
2491
2474
|
}, "ui-schema-form: row registrations");
|
|
2492
2475
|
}
|
|
2493
|
-
|
|
2494
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/markdown-labels.ts
|
|
2476
|
+
// ../../client/dsh-client-ui-primitives/src/client/markdown-labels.ts
|
|
2495
2477
|
function markdownLabels(t) {
|
|
2496
2478
|
return {
|
|
2497
2479
|
code: {
|
|
@@ -2501,9 +2483,8 @@ window.__ModuleLoader__.load({
|
|
|
2501
2483
|
footnotes: t("markdown.footnotes")
|
|
2502
2484
|
};
|
|
2503
2485
|
}
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
const css$13 = "._7Ar2dq_stack{flex-direction:column;min-width:0;display:flex}._7Ar2dq_row{flex-direction:row;align-items:center;min-width:0;display:flex}._7Ar2dq_gap0{gap:0}._7Ar2dq_gap2{gap:2px}._7Ar2dq_gap4{gap:4px}._7Ar2dq_gap6{gap:6px}._7Ar2dq_gap8{gap:8px}._7Ar2dq_gap10{gap:10px}._7Ar2dq_gap12{gap:12px}._7Ar2dq_gap14{gap:14px}._7Ar2dq_gap16{gap:16px}._7Ar2dq_alignStart{align-items:flex-start}._7Ar2dq_alignCenter{align-items:center}._7Ar2dq_alignEnd{align-items:flex-end}._7Ar2dq_justifyBetween{justify-content:space-between}._7Ar2dq_justifyEnd{justify-content:flex-end}._7Ar2dq_justifyCenter{justify-content:center}._7Ar2dq_wrap{flex-wrap:wrap}._7Ar2dq_grow{flex:auto;min-width:0}._7Ar2dq_push{margin-left:auto}._7Ar2dq_fill{box-sizing:border-box;width:100%;height:100%;overflow:hidden}._7Ar2dq_scroll{flex:auto;min-height:0;overflow-y:auto}._7Ar2dq_plain{margin:0;padding:0;list-style:none}._7Ar2dq_padNone{padding:0}._7Ar2dq_padCard{padding:8px 12px}._7Ar2dq_padBody{padding:8px 0}._7Ar2dq_padPage{padding:24px 28px}._7Ar2dq_padRow{padding:10px 12px}._7Ar2dq_padBlocking{padding:32px 40px}._7Ar2dq_text{margin:0}._7Ar2dq_sizeXs{font-size:11px;line-height:1.5}._7Ar2dq_sizeSm{font-size:12px;line-height:18px}._7Ar2dq_sizeMd{font-size:13px;line-height:20px}._7Ar2dq_sizeBase{font-size:14px;line-height:24px}._7Ar2dq_sizeLg{font-size:16px;line-height:24px}._7Ar2dq_tonePrimary{color:var(--dsw-alias-label-primary)}._7Ar2dq_toneSecondary{color:var(--dsw-alias-label-secondary)}._7Ar2dq_toneTertiary{color:var(--dsw-alias-label-tertiary)}._7Ar2dq_toneDanger{color:var(--dsw-alias-label-error,var(--dsw-alias-label-primary))}._7Ar2dq_weightMedium{font-weight:500}._7Ar2dq_strong{font-weight:600}._7Ar2dq_mono{word-break:break-all;font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,monospace}._7Ar2dq_truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}._7Ar2dq_tabular{font-variant-numeric:tabular-nums}._7Ar2dq_boxed{border:1px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-bg-base);border-radius:10px}._7Ar2dq_fixed{flex:none}._7Ar2dq_gapWide{gap:6px 20px}._7Ar2dq_narrow{min-width:0;max-width:min(calc(var(--dsh-chat-content-width,748px) * .702), 82%)}._7Ar2dq_wSearch{flex:none;width:360px;max-width:100%}";
|
|
2486
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/layout/layout.module.css.mjs
|
|
2487
|
+
const css$13 = ".uxI0LG_stack{flex-direction:column;min-width:0;display:flex}.uxI0LG_row{flex-direction:row;align-items:center;min-width:0;display:flex}.uxI0LG_gap0{gap:0}.uxI0LG_gap2{gap:2px}.uxI0LG_gap4{gap:4px}.uxI0LG_gap6{gap:6px}.uxI0LG_gap8{gap:8px}.uxI0LG_gap10{gap:10px}.uxI0LG_gap12{gap:12px}.uxI0LG_gap14{gap:14px}.uxI0LG_gap16{gap:16px}.uxI0LG_alignStart{align-items:flex-start}.uxI0LG_alignCenter{align-items:center}.uxI0LG_alignEnd{align-items:flex-end}.uxI0LG_justifyBetween{justify-content:space-between}.uxI0LG_justifyEnd{justify-content:flex-end}.uxI0LG_justifyCenter{justify-content:center}.uxI0LG_wrap{flex-wrap:wrap}.uxI0LG_grow{flex:auto;min-width:0}.uxI0LG_push{margin-left:auto}.uxI0LG_fill{box-sizing:border-box;width:100%;height:100%;overflow:hidden}.uxI0LG_scroll{flex:auto;min-height:0;overflow-y:auto}.uxI0LG_plain{margin:0;padding:0;list-style:none}.uxI0LG_padNone{padding:0}.uxI0LG_padCard{padding:8px 12px}.uxI0LG_padBody{padding:8px 0}.uxI0LG_padPage{padding:24px 28px}.uxI0LG_padRow{padding:10px 12px}.uxI0LG_padBlocking{padding:32px 40px}.uxI0LG_text{margin:0}.uxI0LG_sizeXs{font-size:11px;line-height:1.5}.uxI0LG_sizeSm{font-size:12px;line-height:18px}.uxI0LG_sizeMd{font-size:13px;line-height:20px}.uxI0LG_sizeBase{font-size:14px;line-height:24px}.uxI0LG_sizeLg{font-size:16px;line-height:24px}.uxI0LG_tonePrimary{color:var(--dsw-alias-label-primary)}.uxI0LG_toneSecondary{color:var(--dsw-alias-label-secondary)}.uxI0LG_toneTertiary{color:var(--dsw-alias-label-tertiary)}.uxI0LG_toneDanger{color:var(--dsw-alias-label-error,var(--dsw-alias-label-primary))}.uxI0LG_weightMedium{font-weight:500}.uxI0LG_strong{font-weight:600}.uxI0LG_mono{word-break:break-all;font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,monospace}.uxI0LG_truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.uxI0LG_tabular{font-variant-numeric:tabular-nums}.uxI0LG_boxed{border:1px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-bg-base);border-radius:10px}.uxI0LG_fixed{flex:none}.uxI0LG_gapWide{gap:6px 20px}.uxI0LG_narrow{min-width:0;max-width:min(calc(var(--dsh-chat-content-width,748px) * .702), 82%)}.uxI0LG_wSearch{flex:none;width:360px;max-width:100%}";
|
|
2507
2488
|
const tagId$13 = "@morlay/dsh-session-mode/layout.module.css";
|
|
2508
2489
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/layout.module.css\"]") === null) {
|
|
2509
2490
|
const tag = document.createElement("style");
|
|
@@ -2513,58 +2494,57 @@ window.__ModuleLoader__.load({
|
|
|
2513
2494
|
document.head.appendChild(tag);
|
|
2514
2495
|
}
|
|
2515
2496
|
var layout_module_css_default = {
|
|
2516
|
-
"
|
|
2517
|
-
"
|
|
2518
|
-
"
|
|
2519
|
-
"
|
|
2520
|
-
"
|
|
2521
|
-
"
|
|
2522
|
-
"
|
|
2523
|
-
"sizeLg": "
|
|
2524
|
-
"
|
|
2525
|
-
"
|
|
2526
|
-
"
|
|
2527
|
-
"
|
|
2528
|
-
"
|
|
2529
|
-
"
|
|
2530
|
-
"
|
|
2531
|
-
"
|
|
2532
|
-
"
|
|
2533
|
-
"
|
|
2534
|
-
"
|
|
2535
|
-
"
|
|
2536
|
-
"
|
|
2537
|
-
"
|
|
2538
|
-
"
|
|
2539
|
-
"
|
|
2540
|
-
"
|
|
2541
|
-
"
|
|
2542
|
-
"
|
|
2543
|
-
"
|
|
2544
|
-
"
|
|
2545
|
-
"
|
|
2546
|
-
"
|
|
2547
|
-
"
|
|
2548
|
-
"
|
|
2549
|
-
"
|
|
2550
|
-
"
|
|
2551
|
-
"
|
|
2552
|
-
"
|
|
2553
|
-
"
|
|
2554
|
-
"
|
|
2555
|
-
"
|
|
2556
|
-
"
|
|
2557
|
-
"
|
|
2558
|
-
"
|
|
2559
|
-
"justifyBetween": "
|
|
2560
|
-
"
|
|
2561
|
-
"
|
|
2562
|
-
"
|
|
2563
|
-
"
|
|
2564
|
-
"
|
|
2497
|
+
"gap4": "uxI0LG_gap4",
|
|
2498
|
+
"gap6": "uxI0LG_gap6",
|
|
2499
|
+
"tabular": "uxI0LG_tabular",
|
|
2500
|
+
"truncate": "uxI0LG_truncate",
|
|
2501
|
+
"gapWide": "uxI0LG_gapWide",
|
|
2502
|
+
"narrow": "uxI0LG_narrow",
|
|
2503
|
+
"justifyCenter": "uxI0LG_justifyCenter",
|
|
2504
|
+
"sizeLg": "uxI0LG_sizeLg",
|
|
2505
|
+
"padNone": "uxI0LG_padNone",
|
|
2506
|
+
"plain": "uxI0LG_plain",
|
|
2507
|
+
"sizeXs": "uxI0LG_sizeXs",
|
|
2508
|
+
"gap14": "uxI0LG_gap14",
|
|
2509
|
+
"alignStart": "uxI0LG_alignStart",
|
|
2510
|
+
"gap10": "uxI0LG_gap10",
|
|
2511
|
+
"gap8": "uxI0LG_gap8",
|
|
2512
|
+
"padRow": "uxI0LG_padRow",
|
|
2513
|
+
"sizeSm": "uxI0LG_sizeSm",
|
|
2514
|
+
"strong": "uxI0LG_strong",
|
|
2515
|
+
"mono": "uxI0LG_mono",
|
|
2516
|
+
"push": "uxI0LG_push",
|
|
2517
|
+
"wrap": "uxI0LG_wrap",
|
|
2518
|
+
"padPage": "uxI0LG_padPage",
|
|
2519
|
+
"fixed": "uxI0LG_fixed",
|
|
2520
|
+
"gap12": "uxI0LG_gap12",
|
|
2521
|
+
"fill": "uxI0LG_fill",
|
|
2522
|
+
"scroll": "uxI0LG_scroll",
|
|
2523
|
+
"text": "uxI0LG_text",
|
|
2524
|
+
"sizeBase": "uxI0LG_sizeBase",
|
|
2525
|
+
"sizeMd": "uxI0LG_sizeMd",
|
|
2526
|
+
"grow": "uxI0LG_grow",
|
|
2527
|
+
"toneDanger": "uxI0LG_toneDanger",
|
|
2528
|
+
"wSearch": "uxI0LG_wSearch",
|
|
2529
|
+
"row": "uxI0LG_row",
|
|
2530
|
+
"tonePrimary": "uxI0LG_tonePrimary",
|
|
2531
|
+
"padBody": "uxI0LG_padBody",
|
|
2532
|
+
"gap16": "uxI0LG_gap16",
|
|
2533
|
+
"alignCenter": "uxI0LG_alignCenter",
|
|
2534
|
+
"stack": "uxI0LG_stack",
|
|
2535
|
+
"justifyEnd": "uxI0LG_justifyEnd",
|
|
2536
|
+
"padBlocking": "uxI0LG_padBlocking",
|
|
2537
|
+
"alignEnd": "uxI0LG_alignEnd",
|
|
2538
|
+
"toneSecondary": "uxI0LG_toneSecondary",
|
|
2539
|
+
"toneTertiary": "uxI0LG_toneTertiary",
|
|
2540
|
+
"justifyBetween": "uxI0LG_justifyBetween",
|
|
2541
|
+
"boxed": "uxI0LG_boxed",
|
|
2542
|
+
"padCard": "uxI0LG_padCard",
|
|
2543
|
+
"gap0": "uxI0LG_gap0",
|
|
2544
|
+
"weightMedium": "uxI0LG_weightMedium",
|
|
2545
|
+
"gap2": "uxI0LG_gap2"
|
|
2565
2546
|
};
|
|
2566
|
-
|
|
2567
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/layout/scales.ts
|
|
2547
|
+
// ../../client/dsh-client-ui-primitives/src/client/layout/scales.ts
|
|
2568
2548
|
function gapClass(css, gap) {
|
|
2569
2549
|
if (gap === void 0) return void 0;
|
|
2570
2550
|
return gap === "wide" ? css.gapWide : css[`gap${gap}`];
|
|
@@ -2604,8 +2584,7 @@ window.__ModuleLoader__.load({
|
|
|
2604
2584
|
if (weight === void 0) return void 0;
|
|
2605
2585
|
return weight === "medium" ? css.weightMedium : css.strong;
|
|
2606
2586
|
}
|
|
2607
|
-
|
|
2608
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/layout/Row.tsx
|
|
2587
|
+
// ../../client/dsh-client-ui-primitives/src/client/layout/Row.tsx
|
|
2609
2588
|
const Row = (0, react.forwardRef)(function Row({ as: Element = "div", gap, align, justify, wrap = false, grow = false, boxed = false, fixed = false, narrow = false, push = false, plain = false, pad, className, children, ...rest }, ref) {
|
|
2610
2589
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Element, {
|
|
2611
2590
|
ref,
|
|
@@ -2614,8 +2593,7 @@ window.__ModuleLoader__.load({
|
|
|
2614
2593
|
children
|
|
2615
2594
|
});
|
|
2616
2595
|
});
|
|
2617
|
-
|
|
2618
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/layout/Stack.tsx
|
|
2596
|
+
// ../../client/dsh-client-ui-primitives/src/client/layout/Stack.tsx
|
|
2619
2597
|
const Stack = (0, react.forwardRef)(function Stack({ as: Element = "div", gap, align, pad, grow = false, boxed = false, fixed = false, narrow = false, fill = false, scroll = false, plain = false, className, children, ...rest }, ref) {
|
|
2620
2598
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Element, {
|
|
2621
2599
|
ref,
|
|
@@ -2624,17 +2602,15 @@ window.__ModuleLoader__.load({
|
|
|
2624
2602
|
children
|
|
2625
2603
|
});
|
|
2626
2604
|
});
|
|
2627
|
-
|
|
2628
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/layout/Text.tsx
|
|
2605
|
+
// ../../client/dsh-client-ui-primitives/src/client/layout/Text.tsx
|
|
2629
2606
|
function Text({ as: Element = "span", size, tone, weight, mono = false, truncate = false, tabular = false, className, children }) {
|
|
2630
2607
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Element, {
|
|
2631
2608
|
className: classes(layout_module_css_default.text, sizeClass(layout_module_css_default, size), toneClass(layout_module_css_default, tone), weightClass(layout_module_css_default, weight), mono ? layout_module_css_default.mono : void 0, truncate ? layout_module_css_default.truncate : void 0, tabular ? layout_module_css_default.tabular : void 0, className),
|
|
2632
2609
|
children
|
|
2633
2610
|
});
|
|
2634
2611
|
}
|
|
2635
|
-
|
|
2636
|
-
|
|
2637
|
-
const css$12 = ".Il1Dtq_row{flex-direction:column;display:flex}.Il1Dtq_row[data-divider=true]{border-top:.5px solid var(--dsw-alias-border-l2)}.Il1Dtq_body{flex-direction:column;gap:6px;padding:12px 0;display:flex}.Il1Dtq_inline{flex-direction:row;justify-content:space-between;align-items:center;gap:16px;padding:12px 0;display:flex}.Il1Dtq_text{flex-direction:column;gap:2px;min-width:0;display:flex}.Il1Dtq_label{color:var(--dsw-alias-label-primary);align-items:center;gap:8px;font-size:13px;font-weight:500;line-height:1.5;display:flex}.Il1Dtq_badge{corner-shape:round;color:var(--dsw-alias-label-secondary);background:var(--dsw-alias-bg-module-platform);border-radius:999px;align-items:center;padding:1px 8px;font-size:11px;font-weight:500;line-height:17px;display:inline-flex}.Il1Dtq_reset{font:inherit;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;padding:0;font-size:12px;line-height:1.5}.Il1Dtq_reset:hover:not(:disabled){color:var(--dsw-alias-label-primary)}.Il1Dtq_reset:disabled{cursor:default}.Il1Dtq_hint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}.Il1Dtq_invalid{color:var(--dsw-alias-state-error-primary);margin:0;font-size:12px;line-height:1.5}";
|
|
2612
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/settings-form/SettingsFieldRow.module.css.mjs
|
|
2613
|
+
const css$12 = "._0Kpzea_row{flex-direction:column;display:flex}._0Kpzea_row[data-divider=true]{border-top:.5px solid var(--dsw-alias-border-l2)}._0Kpzea_body{flex-direction:column;gap:6px;padding:12px 0;display:flex}._0Kpzea_inline{flex-direction:row;justify-content:space-between;align-items:center;gap:16px;padding:12px 0;display:flex}._0Kpzea_text{flex-direction:column;gap:2px;min-width:0;display:flex}._0Kpzea_label{color:var(--dsw-alias-label-primary);align-items:center;gap:8px;font-size:13px;font-weight:500;line-height:1.5;display:flex}._0Kpzea_badge{corner-shape:round;color:var(--dsw-alias-label-secondary);background:var(--dsw-alias-bg-module-platform);border-radius:999px;align-items:center;padding:1px 8px;font-size:11px;font-weight:500;line-height:17px;display:inline-flex}._0Kpzea_reset{font:inherit;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;padding:0;font-size:12px;line-height:1.5}._0Kpzea_reset:hover:not(:disabled){color:var(--dsw-alias-label-primary)}._0Kpzea_reset:disabled{cursor:default}._0Kpzea_hint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}._0Kpzea_invalid{color:var(--dsw-alias-state-error-primary);margin:0;font-size:12px;line-height:1.5}";
|
|
2638
2614
|
const tagId$12 = "@morlay/dsh-session-mode/SettingsFieldRow.module.css";
|
|
2639
2615
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/SettingsFieldRow.module.css\"]") === null) {
|
|
2640
2616
|
const tag = document.createElement("style");
|
|
@@ -2644,18 +2620,17 @@ window.__ModuleLoader__.load({
|
|
|
2644
2620
|
document.head.appendChild(tag);
|
|
2645
2621
|
}
|
|
2646
2622
|
var SettingsFieldRow_module_css_default = {
|
|
2647
|
-
"
|
|
2648
|
-
"
|
|
2649
|
-
"
|
|
2650
|
-
"
|
|
2651
|
-
"
|
|
2652
|
-
"
|
|
2653
|
-
"
|
|
2654
|
-
"
|
|
2655
|
-
"
|
|
2623
|
+
"hint": "_0Kpzea_hint",
|
|
2624
|
+
"inline": "_0Kpzea_inline",
|
|
2625
|
+
"body": "_0Kpzea_body",
|
|
2626
|
+
"text": "_0Kpzea_text",
|
|
2627
|
+
"label": "_0Kpzea_label",
|
|
2628
|
+
"reset": "_0Kpzea_reset",
|
|
2629
|
+
"row": "_0Kpzea_row",
|
|
2630
|
+
"invalid": "_0Kpzea_invalid",
|
|
2631
|
+
"badge": "_0Kpzea_badge"
|
|
2656
2632
|
};
|
|
2657
|
-
|
|
2658
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/settings-form/SettingsFieldRow.tsx
|
|
2633
|
+
// ../../client/dsh-client-ui-primitives/src/client/settings-form/SettingsFieldRow.tsx
|
|
2659
2634
|
function SettingsFieldRow({ label, hint, layout = "stack", divider = false, overriddenLabel, resetLabel, onReset, invalid, children, className, ...rest }) {
|
|
2660
2635
|
const labelNode = /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
|
|
2661
2636
|
className: SettingsFieldRow_module_css_default.label,
|
|
@@ -2710,9 +2685,8 @@ window.__ModuleLoader__.load({
|
|
|
2710
2685
|
}), invalidNode]
|
|
2711
2686
|
});
|
|
2712
2687
|
}
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
const css$11 = ".Iy2DYG_bubble{background:var(--dsw-specific-bubble);border-radius:var(--dsw-radius-xl);max-width:100%;font-size:var(--dsh-content-font-size,14px);line-height:calc(22px + var(--dsh-content-font-delta,0px));color:var(--dsw-alias-label-primary);white-space:pre-wrap;word-break:break-word;padding:10px 16px}";
|
|
2688
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/Bubble.module.css.mjs
|
|
2689
|
+
const css$11 = ".LQ5bkq_bubble{background:var(--dsw-specific-bubble);border-radius:var(--dsw-radius-xl);max-width:100%;font-size:var(--dsh-content-font-size,14px);line-height:calc(22px + var(--dsh-content-font-delta,0px));color:var(--dsw-alias-label-primary);white-space:pre-wrap;word-break:break-word;padding:10px 16px}";
|
|
2716
2690
|
const tagId$11 = "@morlay/dsh-session-mode/Bubble.module.css";
|
|
2717
2691
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/Bubble.module.css\"]") === null) {
|
|
2718
2692
|
const tag = document.createElement("style");
|
|
@@ -2721,9 +2695,8 @@ window.__ModuleLoader__.load({
|
|
|
2721
2695
|
tag.textContent = css$11;
|
|
2722
2696
|
document.head.appendChild(tag);
|
|
2723
2697
|
}
|
|
2724
|
-
var Bubble_module_css_default = { "bubble": "
|
|
2725
|
-
|
|
2726
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/Bubble.tsx
|
|
2698
|
+
var Bubble_module_css_default = { "bubble": "LQ5bkq_bubble" };
|
|
2699
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/Bubble.tsx
|
|
2727
2700
|
function Bubble({ className, children, ...rest }) {
|
|
2728
2701
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
2729
2702
|
className: classes(Bubble_module_css_default.bubble, className),
|
|
@@ -2731,9 +2704,8 @@ window.__ModuleLoader__.load({
|
|
|
2731
2704
|
children
|
|
2732
2705
|
});
|
|
2733
2706
|
}
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
const css$10 = ".LWgVXW_label{white-space:nowrap}.LWgVXW_danger{--dsw-alias-button-primary-fill:var(--dsw-alias-state-error-primary)}";
|
|
2707
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/Button.module.css.mjs
|
|
2708
|
+
const css$10 = ".SBA8ka_label{white-space:nowrap}.SBA8ka_danger{--dsw-alias-button-primary-fill:var(--dsw-alias-state-error-primary)}";
|
|
2737
2709
|
const tagId$10 = "@morlay/dsh-session-mode/Button.module.css";
|
|
2738
2710
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/Button.module.css\"]") === null) {
|
|
2739
2711
|
const tag = document.createElement("style");
|
|
@@ -2743,11 +2715,10 @@ window.__ModuleLoader__.load({
|
|
|
2743
2715
|
document.head.appendChild(tag);
|
|
2744
2716
|
}
|
|
2745
2717
|
var Button_module_css_default = {
|
|
2746
|
-
"label": "
|
|
2747
|
-
"danger": "
|
|
2718
|
+
"label": "SBA8ka_label",
|
|
2719
|
+
"danger": "SBA8ka_danger"
|
|
2748
2720
|
};
|
|
2749
|
-
|
|
2750
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/Button.tsx
|
|
2721
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/Button.tsx
|
|
2751
2722
|
const Button$1 = (0, react.forwardRef)(function Button({ className, tone, ...rest }, ref) {
|
|
2752
2723
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
2753
2724
|
ref,
|
|
@@ -2756,9 +2727,8 @@ window.__ModuleLoader__.load({
|
|
|
2756
2727
|
...rest
|
|
2757
2728
|
});
|
|
2758
2729
|
});
|
|
2759
|
-
|
|
2760
|
-
|
|
2761
|
-
const css$9 = "._2HN-kW_content{flex:auto;min-width:0}._2HN-kW_contentLayout{align-items:center;gap:8px;width:100%;min-width:0;display:flex}";
|
|
2730
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/DisclosureRow.module.css.mjs
|
|
2731
|
+
const css$9 = ".BDL1HG_content{flex:auto;min-width:0}.BDL1HG_contentLayout{align-items:center;gap:8px;width:100%;min-width:0;display:flex}";
|
|
2762
2732
|
const tagId$9 = "@morlay/dsh-session-mode/DisclosureRow.module.css";
|
|
2763
2733
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/DisclosureRow.module.css\"]") === null) {
|
|
2764
2734
|
const tag = document.createElement("style");
|
|
@@ -2768,11 +2738,10 @@ window.__ModuleLoader__.load({
|
|
|
2768
2738
|
document.head.appendChild(tag);
|
|
2769
2739
|
}
|
|
2770
2740
|
var DisclosureRow_module_css_default = {
|
|
2771
|
-
"content": "
|
|
2772
|
-
"contentLayout": "
|
|
2741
|
+
"content": "BDL1HG_content",
|
|
2742
|
+
"contentLayout": "BDL1HG_contentLayout"
|
|
2773
2743
|
};
|
|
2774
|
-
|
|
2775
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/DisclosureRow.tsx
|
|
2744
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/DisclosureRow.tsx
|
|
2776
2745
|
function DisclosureRow(props) {
|
|
2777
2746
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.DisclosureRow, {
|
|
2778
2747
|
contentClassName: DisclosureRow_module_css_default.content,
|
|
@@ -2780,9 +2749,8 @@ window.__ModuleLoader__.load({
|
|
|
2780
2749
|
...props
|
|
2781
2750
|
});
|
|
2782
2751
|
}
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
const css$8 = ".JqQ4qG_seat{border-radius:var(--dsw-radius-sm);min-width:0;max-width:min(100%,240px);min-height:28px;color:var(--dsw-alias-label-primary);white-space:nowrap;cursor:pointer;background:0 0;border:none;align-items:center;gap:4px;padding:0 8px;font-size:13px;font-weight:500;line-height:20px;display:inline-flex}.JqQ4qG_seat:not(:disabled):hover,.JqQ4qG_seat[aria-expanded=true],.JqQ4qG_expanded{background:var(--dsw-alias-interactive-bg-hover)}.JqQ4qG_seat:disabled{cursor:default;color:var(--dsw-alias-label-quaternary)}.JqQ4qG_icon{color:var(--dsw-alias-label-primary);flex:none;align-items:center;display:inline-flex}.JqQ4qG_label{text-overflow:ellipsis;white-space:nowrap;min-width:0;overflow:hidden}.JqQ4qG_chevron{color:var(--dsw-alias-label-caption);flex:none;display:inline-flex}";
|
|
2752
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/SeatButton.module.css.mjs
|
|
2753
|
+
const css$8 = ".io5HbW_seat{border-radius:var(--dsw-radius-sm);min-width:0;max-width:min(100%,240px);min-height:28px;color:var(--dsw-alias-label-primary);white-space:nowrap;cursor:pointer;background:0 0;border:none;align-items:center;gap:4px;padding:0 8px;font-size:13px;font-weight:500;line-height:20px;display:inline-flex}.io5HbW_seat:not(:disabled):hover,.io5HbW_seat[aria-expanded=true],.io5HbW_expanded{background:var(--dsw-alias-interactive-bg-hover)}.io5HbW_seat:disabled{cursor:default;color:var(--dsw-alias-label-quaternary)}.io5HbW_icon{color:var(--dsw-alias-label-primary);flex:none;align-items:center;display:inline-flex}.io5HbW_label{text-overflow:ellipsis;white-space:nowrap;min-width:0;overflow:hidden}.io5HbW_chevron{color:var(--dsw-alias-label-caption);flex:none;display:inline-flex}";
|
|
2786
2754
|
const tagId$8 = "@morlay/dsh-session-mode/SeatButton.module.css";
|
|
2787
2755
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/SeatButton.module.css\"]") === null) {
|
|
2788
2756
|
const tag = document.createElement("style");
|
|
@@ -2792,14 +2760,13 @@ window.__ModuleLoader__.load({
|
|
|
2792
2760
|
document.head.appendChild(tag);
|
|
2793
2761
|
}
|
|
2794
2762
|
var SeatButton_module_css_default = {
|
|
2795
|
-
"
|
|
2796
|
-
"
|
|
2797
|
-
"
|
|
2798
|
-
"
|
|
2799
|
-
"
|
|
2763
|
+
"chevron": "io5HbW_chevron",
|
|
2764
|
+
"seat": "io5HbW_seat",
|
|
2765
|
+
"expanded": "io5HbW_expanded",
|
|
2766
|
+
"icon": "io5HbW_icon",
|
|
2767
|
+
"label": "io5HbW_label"
|
|
2800
2768
|
};
|
|
2801
|
-
|
|
2802
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/SeatButton.tsx
|
|
2769
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/SeatButton.tsx
|
|
2803
2770
|
function SeatButton({ icon, label, expanded = false, chevron, type = "button", className, ...rest }) {
|
|
2804
2771
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
|
|
2805
2772
|
type,
|
|
@@ -2821,9 +2788,8 @@ window.__ModuleLoader__.load({
|
|
|
2821
2788
|
]
|
|
2822
2789
|
});
|
|
2823
2790
|
}
|
|
2824
|
-
|
|
2825
|
-
|
|
2826
|
-
const css$7 = "._1uNobG_spinner{border:2px solid var(--dsw-alias-border-l2);border-top-color:var(--dsw-alias-label-primary);border-radius:50%;width:28px;height:28px;animation:.9s linear infinite _1uNobG_spin}@keyframes _1uNobG_spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}";
|
|
2791
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/Spinner.module.css.mjs
|
|
2792
|
+
const css$7 = ".If7fBq_spinner{border:2px solid var(--dsw-alias-border-l2);border-top-color:var(--dsw-alias-label-primary);border-radius:50%;width:28px;height:28px;animation:.9s linear infinite If7fBq_spin}@keyframes If7fBq_spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}";
|
|
2827
2793
|
const tagId$7 = "@morlay/dsh-session-mode/Spinner.module.css";
|
|
2828
2794
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/Spinner.module.css\"]") === null) {
|
|
2829
2795
|
const tag = document.createElement("style");
|
|
@@ -2833,11 +2799,10 @@ window.__ModuleLoader__.load({
|
|
|
2833
2799
|
document.head.appendChild(tag);
|
|
2834
2800
|
}
|
|
2835
2801
|
var Spinner_module_css_default = {
|
|
2836
|
-
"spinner": "
|
|
2837
|
-
"spin": "
|
|
2802
|
+
"spinner": "If7fBq_spinner",
|
|
2803
|
+
"spin": "If7fBq_spin"
|
|
2838
2804
|
};
|
|
2839
|
-
|
|
2840
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/Spinner.tsx
|
|
2805
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/Spinner.tsx
|
|
2841
2806
|
function Spinner({ label }) {
|
|
2842
2807
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
2843
2808
|
className: Spinner_module_css_default.spinner,
|
|
@@ -2845,9 +2810,8 @@ window.__ModuleLoader__.load({
|
|
|
2845
2810
|
"aria-label": label
|
|
2846
2811
|
});
|
|
2847
2812
|
}
|
|
2848
|
-
|
|
2849
|
-
|
|
2850
|
-
const css$6 = ".P8Yiia_label{color:var(--dsw-alias-label-tertiary);white-space:nowrap;opacity:0;padding:0;font-size:14px;line-height:24px;transition:opacity 80ms}[data-time-hover-root]:hover .P8Yiia_label,[data-time-hover-root]:focus-within .P8Yiia_label{opacity:1}";
|
|
2813
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/TimeLabel.module.css.mjs
|
|
2814
|
+
const css$6 = ".rbYIyq_label{color:var(--dsw-alias-label-tertiary);white-space:nowrap;opacity:0;padding:0;font-size:14px;line-height:24px;transition:opacity 80ms}[data-time-hover-root]:hover .rbYIyq_label,[data-time-hover-root]:focus-within .rbYIyq_label{opacity:1}";
|
|
2851
2815
|
const tagId$6 = "@morlay/dsh-session-mode/TimeLabel.module.css";
|
|
2852
2816
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/TimeLabel.module.css\"]") === null) {
|
|
2853
2817
|
const tag = document.createElement("style");
|
|
@@ -2856,9 +2820,8 @@ window.__ModuleLoader__.load({
|
|
|
2856
2820
|
tag.textContent = css$6;
|
|
2857
2821
|
document.head.appendChild(tag);
|
|
2858
2822
|
}
|
|
2859
|
-
var TimeLabel_module_css_default = { "label": "
|
|
2860
|
-
|
|
2861
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/TimeLabel.tsx
|
|
2823
|
+
var TimeLabel_module_css_default = { "label": "rbYIyq_label" };
|
|
2824
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/TimeLabel.tsx
|
|
2862
2825
|
function TimeLabel({ className, children, ...rest }) {
|
|
2863
2826
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
2864
2827
|
className: classes(TimeLabel_module_css_default.label, className),
|
|
@@ -2866,9 +2829,8 @@ window.__ModuleLoader__.load({
|
|
|
2866
2829
|
children
|
|
2867
2830
|
});
|
|
2868
2831
|
}
|
|
2869
|
-
|
|
2870
|
-
|
|
2871
|
-
const css$5 = ".d5ueOG_hidden{clip-path:inset(50%);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}";
|
|
2832
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/VisuallyHidden.module.css.mjs
|
|
2833
|
+
const css$5 = ".UjjB8a_hidden{clip-path:inset(50%);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}";
|
|
2872
2834
|
const tagId$5 = "@morlay/dsh-session-mode/VisuallyHidden.module.css";
|
|
2873
2835
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/VisuallyHidden.module.css\"]") === null) {
|
|
2874
2836
|
const tag = document.createElement("style");
|
|
@@ -2877,9 +2839,8 @@ window.__ModuleLoader__.load({
|
|
|
2877
2839
|
tag.textContent = css$5;
|
|
2878
2840
|
document.head.appendChild(tag);
|
|
2879
2841
|
}
|
|
2880
|
-
var VisuallyHidden_module_css_default = { "hidden": "
|
|
2881
|
-
|
|
2882
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/VisuallyHidden.tsx
|
|
2842
|
+
var VisuallyHidden_module_css_default = { "hidden": "UjjB8a_hidden" };
|
|
2843
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/VisuallyHidden.tsx
|
|
2883
2844
|
function VisuallyHidden({ children, ...rest }) {
|
|
2884
2845
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
2885
2846
|
className: VisuallyHidden_module_css_default.hidden,
|
|
@@ -2887,9 +2848,8 @@ window.__ModuleLoader__.load({
|
|
|
2887
2848
|
children
|
|
2888
2849
|
});
|
|
2889
2850
|
}
|
|
2890
|
-
|
|
2891
|
-
|
|
2892
|
-
const css$4 = ".AibFna_iconButton{box-sizing:border-box;width:28px;height:28px;color:var(--dsw-alias-label-secondary);border-radius:var(--dsw-radius-sm);cursor:pointer;background:0 0;border:none;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.AibFna_iconButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover)}.AibFna_iconButton:disabled{cursor:not-allowed;opacity:.4}.AibFna_iconButton:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:-2px}.AibFna_sm{width:20px;height:20px;padding:0}.AibFna_circle{color:var(--dsw-alias-label-tertiary);border-radius:28px;padding:6px}.AibFna_circle:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-secondary)}";
|
|
2851
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/IconButton.module.css.mjs
|
|
2852
|
+
const css$4 = ".G842ma_iconButton{box-sizing:border-box;width:28px;height:28px;color:var(--dsw-alias-label-secondary);border-radius:var(--dsw-radius-sm);cursor:pointer;background:0 0;border:none;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.G842ma_iconButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover)}.G842ma_iconButton:disabled{cursor:not-allowed;opacity:.4}.G842ma_iconButton:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:-2px}.G842ma_sm{width:20px;height:20px;padding:0}.G842ma_circle{color:var(--dsw-alias-label-tertiary);border-radius:28px;padding:6px}.G842ma_circle:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-secondary)}";
|
|
2893
2853
|
const tagId$4 = "@morlay/dsh-session-mode/IconButton.module.css";
|
|
2894
2854
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/IconButton.module.css\"]") === null) {
|
|
2895
2855
|
const tag = document.createElement("style");
|
|
@@ -2899,12 +2859,11 @@ window.__ModuleLoader__.load({
|
|
|
2899
2859
|
document.head.appendChild(tag);
|
|
2900
2860
|
}
|
|
2901
2861
|
var IconButton_module_css_default = {
|
|
2902
|
-
"iconButton": "
|
|
2903
|
-
"sm": "
|
|
2904
|
-
"circle": "
|
|
2862
|
+
"iconButton": "G842ma_iconButton",
|
|
2863
|
+
"sm": "G842ma_sm",
|
|
2864
|
+
"circle": "G842ma_circle"
|
|
2905
2865
|
};
|
|
2906
|
-
|
|
2907
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/IconButton.tsx
|
|
2866
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/IconButton.tsx
|
|
2908
2867
|
function IconButton({ label, children, type = "button", shape = "square", size = "md", className, ...rest }) {
|
|
2909
2868
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
|
|
2910
2869
|
type,
|
|
@@ -2915,9 +2874,8 @@ window.__ModuleLoader__.load({
|
|
|
2915
2874
|
children
|
|
2916
2875
|
});
|
|
2917
2876
|
}
|
|
2918
|
-
|
|
2919
|
-
|
|
2920
|
-
const css$3 = "._1vK46q_list{border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-lg);gap:6px;min-width:0;max-height:280px;margin:0;padding:10px;display:grid;overflow:auto}._1vK46q_group{gap:6px;display:grid}._1vK46q_group+._1vK46q_group{border-top:.5px solid var(--dsw-alias-border-l3);margin-top:4px;padding-top:10px}._1vK46q_provider{color:var(--dsw-alias-label-tertiary);padding:0 6px;font-size:11px;font-weight:500}._1vK46q_item{border-radius:var(--dsw-radius-md);cursor:pointer;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:8px;min-width:0;padding:6px;display:grid}._1vK46q_item:hover{background:var(--dsw-alias-bg-layer-4)}._1vK46q_item:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:-2px}._1vK46q_item[aria-disabled=true]{cursor:not-allowed;opacity:.4}._1vK46q_picked{background:var(--dsw-alias-interactive-bg-hover)}._1vK46q_text{min-width:0}._1vK46q_name{text-overflow:ellipsis;white-space:nowrap;color:var(--dsw-alias-label-primary);font-size:13px;display:block;overflow:hidden}._1vK46q_id{text-overflow:ellipsis;white-space:nowrap;color:var(--dsw-alias-label-tertiary);margin-top:2px;font-size:11px;display:block;overflow:hidden}._1vK46q_notice{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}._1vK46q_error{color:var(--dsw-alias-state-error-primary);margin:0;font-size:12px;line-height:1.5}";
|
|
2877
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/ModelRouteList.module.css.mjs
|
|
2878
|
+
const css$3 = ".aGmQkW_list{border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-lg);gap:6px;min-width:0;max-height:280px;margin:0;padding:10px;display:grid;overflow:auto}.aGmQkW_group{gap:6px;display:grid}.aGmQkW_group+.aGmQkW_group{border-top:.5px solid var(--dsw-alias-border-l3);margin-top:4px;padding-top:10px}.aGmQkW_provider{color:var(--dsw-alias-label-tertiary);padding:0 6px;font-size:11px;font-weight:500}.aGmQkW_item{border-radius:var(--dsw-radius-md);cursor:pointer;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:8px;min-width:0;padding:6px;display:grid}.aGmQkW_item:hover{background:var(--dsw-alias-bg-layer-4)}.aGmQkW_item:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:-2px}.aGmQkW_item[aria-disabled=true]{cursor:not-allowed;opacity:.4}.aGmQkW_picked{background:var(--dsw-alias-interactive-bg-hover)}.aGmQkW_text{min-width:0}.aGmQkW_name{text-overflow:ellipsis;white-space:nowrap;color:var(--dsw-alias-label-primary);font-size:13px;display:block;overflow:hidden}.aGmQkW_id{text-overflow:ellipsis;white-space:nowrap;color:var(--dsw-alias-label-tertiary);margin-top:2px;font-size:11px;display:block;overflow:hidden}.aGmQkW_notice{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}.aGmQkW_error{color:var(--dsw-alias-state-error-primary);margin:0;font-size:12px;line-height:1.5}";
|
|
2921
2879
|
const tagId$3 = "@morlay/dsh-session-mode/ModelRouteList.module.css";
|
|
2922
2880
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/ModelRouteList.module.css\"]") === null) {
|
|
2923
2881
|
const tag = document.createElement("style");
|
|
@@ -2927,19 +2885,18 @@ window.__ModuleLoader__.load({
|
|
|
2927
2885
|
document.head.appendChild(tag);
|
|
2928
2886
|
}
|
|
2929
2887
|
var ModelRouteList_module_css_default = {
|
|
2930
|
-
"
|
|
2931
|
-
"
|
|
2932
|
-
"
|
|
2933
|
-
"
|
|
2934
|
-
"
|
|
2935
|
-
"
|
|
2936
|
-
"
|
|
2937
|
-
"
|
|
2938
|
-
"
|
|
2939
|
-
"
|
|
2888
|
+
"notice": "aGmQkW_notice",
|
|
2889
|
+
"id": "aGmQkW_id",
|
|
2890
|
+
"provider": "aGmQkW_provider",
|
|
2891
|
+
"picked": "aGmQkW_picked",
|
|
2892
|
+
"error": "aGmQkW_error",
|
|
2893
|
+
"list": "aGmQkW_list",
|
|
2894
|
+
"text": "aGmQkW_text",
|
|
2895
|
+
"group": "aGmQkW_group",
|
|
2896
|
+
"name": "aGmQkW_name",
|
|
2897
|
+
"item": "aGmQkW_item"
|
|
2940
2898
|
};
|
|
2941
|
-
|
|
2942
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/ModelRouteList.tsx
|
|
2899
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/ModelRouteList.tsx
|
|
2943
2900
|
function ModelRouteList({ label, candidates, selectedKey, disabled = false, status, loadingLabel, errorLabel, emptyLabel, onSelect }) {
|
|
2944
2901
|
if (status === "loading") return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
2945
2902
|
className: ModelRouteList_module_css_default.notice,
|
|
@@ -3009,9 +2966,8 @@ window.__ModuleLoader__.load({
|
|
|
3009
2966
|
}, provider))
|
|
3010
2967
|
});
|
|
3011
2968
|
}
|
|
3012
|
-
|
|
3013
|
-
|
|
3014
|
-
const css$2 = ".V0rRdq_multiline{box-sizing:border-box;width:100%;min-height:64px;color:var(--dsw-alias-label-primary);background:var(--dsw-alias-bg-layer-3);border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-md);resize:vertical;padding:6px 12px;font-family:inherit;font-size:13px;line-height:1.5}.V0rRdq_multiline:disabled{cursor:not-allowed;opacity:.4}.V0rRdq_multiline:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:-2px}";
|
|
2969
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/MultilineField.module.css.mjs
|
|
2970
|
+
const css$2 = ".tafk7W_multiline{box-sizing:border-box;width:100%;min-height:64px;color:var(--dsw-alias-label-primary);background:var(--dsw-alias-bg-layer-3);border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-md);resize:vertical;padding:6px 12px;font-family:inherit;font-size:13px;line-height:1.5}.tafk7W_multiline:disabled{cursor:not-allowed;opacity:.4}.tafk7W_multiline:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:-2px}";
|
|
3015
2971
|
const tagId$2 = "@morlay/dsh-session-mode/MultilineField.module.css";
|
|
3016
2972
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/MultilineField.module.css\"]") === null) {
|
|
3017
2973
|
const tag = document.createElement("style");
|
|
@@ -3020,9 +2976,8 @@ window.__ModuleLoader__.load({
|
|
|
3020
2976
|
tag.textContent = css$2;
|
|
3021
2977
|
document.head.appendChild(tag);
|
|
3022
2978
|
}
|
|
3023
|
-
var MultilineField_module_css_default = { "multiline": "
|
|
3024
|
-
|
|
3025
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/MultilineField.tsx
|
|
2979
|
+
var MultilineField_module_css_default = { "multiline": "tafk7W_multiline" };
|
|
2980
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/MultilineField.tsx
|
|
3026
2981
|
function MultilineField({ rows = 3, className, ...rest }) {
|
|
3027
2982
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("textarea", {
|
|
3028
2983
|
rows,
|
|
@@ -3031,9 +2986,8 @@ window.__ModuleLoader__.load({
|
|
|
3031
2986
|
...rest
|
|
3032
2987
|
});
|
|
3033
2988
|
}
|
|
3034
|
-
|
|
3035
|
-
|
|
3036
|
-
const css$1 = ".kEYv4q_trigger{white-space:nowrap;height:32px}.kEYv4q_searchRow{border-bottom:.5px solid var(--dsw-alias-border-l2);align-items:center;padding:4px 8px 8px;display:flex}.kEYv4q_searchInput{width:100%;color:var(--dsw-alias-label-primary);background:0 0;border:none;outline:none;padding:2px 0;font-family:inherit;font-size:13px;line-height:1.5}.kEYv4q_empty{color:var(--dsw-alias-label-tertiary);margin:0;padding:8px;font-size:12px;line-height:1.5}";
|
|
2989
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/SearchSelect.module.css.mjs
|
|
2990
|
+
const css$1 = ".pNIIcq_trigger{white-space:nowrap;height:32px}.pNIIcq_searchRow{border-bottom:.5px solid var(--dsw-alias-border-l2);align-items:center;padding:4px 8px 8px;display:flex}.pNIIcq_searchInput{width:100%;color:var(--dsw-alias-label-primary);background:0 0;border:none;outline:none;padding:2px 0;font-family:inherit;font-size:13px;line-height:1.5}.pNIIcq_empty{color:var(--dsw-alias-label-tertiary);margin:0;padding:8px;font-size:12px;line-height:1.5}";
|
|
3037
2991
|
const tagId$1 = "@morlay/dsh-session-mode/SearchSelect.module.css";
|
|
3038
2992
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/SearchSelect.module.css\"]") === null) {
|
|
3039
2993
|
const tag = document.createElement("style");
|
|
@@ -3043,13 +2997,12 @@ window.__ModuleLoader__.load({
|
|
|
3043
2997
|
document.head.appendChild(tag);
|
|
3044
2998
|
}
|
|
3045
2999
|
var SearchSelect_module_css_default = {
|
|
3046
|
-
"
|
|
3047
|
-
"
|
|
3048
|
-
"searchInput": "
|
|
3049
|
-
"
|
|
3000
|
+
"trigger": "pNIIcq_trigger",
|
|
3001
|
+
"empty": "pNIIcq_empty",
|
|
3002
|
+
"searchInput": "pNIIcq_searchInput",
|
|
3003
|
+
"searchRow": "pNIIcq_searchRow"
|
|
3050
3004
|
};
|
|
3051
|
-
|
|
3052
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/SearchSelect.tsx
|
|
3005
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/SearchSelect.tsx
|
|
3053
3006
|
function SearchSelect({ label, value, emptyLabel, options, disabled = false, searchLabel, noMatchLabel, onSelect }) {
|
|
3054
3007
|
const [open, setOpen] = (0, react.useState)(false);
|
|
3055
3008
|
const [query, setQuery] = (0, react.useState)("");
|
|
@@ -3126,8 +3079,7 @@ window.__ModuleLoader__.load({
|
|
|
3126
3079
|
]
|
|
3127
3080
|
});
|
|
3128
3081
|
}
|
|
3129
|
-
|
|
3130
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/tags.ts
|
|
3082
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/tags.ts
|
|
3131
3083
|
function parseTagList(text) {
|
|
3132
3084
|
const seen = /* @__PURE__ */ new Set();
|
|
3133
3085
|
const names = [];
|
|
@@ -3147,9 +3099,8 @@ window.__ModuleLoader__.load({
|
|
|
3147
3099
|
}
|
|
3148
3100
|
return merged;
|
|
3149
3101
|
}
|
|
3150
|
-
|
|
3151
|
-
|
|
3152
|
-
const css = ".Qg7I9G_row{align-items:flex-start;gap:8px;width:100%;display:flex}.Qg7I9G_anchor{flex:auto;width:100%;min-width:0;display:flex}.Qg7I9G_box{box-sizing:border-box;background:var(--dsw-alias-bg-layer-3);border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-md);flex-flow:wrap;align-items:center;gap:4px 6px;width:100%;min-height:32px;padding:4px 8px;display:flex}.Qg7I9G_input{min-width:120px;color:var(--dsw-alias-label-primary);background:0 0;border:none;outline:none;flex:120px;padding:2px 0;font-family:inherit;font-size:13px;line-height:1.5}.Qg7I9G_chip{corner-shape:round;white-space:nowrap;color:var(--dsw-alias-label-secondary);background:var(--dsw-alias-bg-module-platform);border-radius:999px;align-items:center;gap:2px;padding:1px 4px 1px 8px;font-size:11px;font-weight:500;line-height:17px;display:inline-flex}.Qg7I9G_chipRemove{box-sizing:border-box;width:14px;height:14px;color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:none;border-radius:999px;flex:none;justify-content:center;align-items:center;padding:0;line-height:1;display:inline-flex}.Qg7I9G_chipRemove:hover:not(:disabled){color:var(--dsw-alias-label-primary);background:var(--dsw-alias-interactive-bg-hover)}.Qg7I9G_chipRemove:disabled{cursor:not-allowed;opacity:.4}.Qg7I9G_chipRemove:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:0}.Qg7I9G_empty{color:var(--dsw-alias-label-tertiary);margin:0;padding:8px;font-size:12px;line-height:1.5}";
|
|
3102
|
+
// \0dsh-css-modules:/Users/morlay/src/github.com/morlay/dsh-plugin-main/packages/client/dsh-client-ui-primitives/src/client/controls/TagInput.module.css.mjs
|
|
3103
|
+
const css = "._0uSpIq_row{align-items:flex-start;gap:8px;width:100%;display:flex}._0uSpIq_anchor{flex:auto;width:100%;min-width:0;display:flex}._0uSpIq_box{box-sizing:border-box;background:var(--dsw-alias-bg-layer-3);border:.5px solid var(--dsw-alias-border-l4);border-radius:var(--dsw-radius-md);flex-flow:wrap;align-items:center;gap:4px 6px;width:100%;min-height:32px;padding:4px 8px;display:flex}._0uSpIq_input{min-width:120px;color:var(--dsw-alias-label-primary);background:0 0;border:none;outline:none;flex:120px;padding:2px 0;font-family:inherit;font-size:13px;line-height:1.5}._0uSpIq_chip{corner-shape:round;white-space:nowrap;color:var(--dsw-alias-label-secondary);background:var(--dsw-alias-bg-module-platform);border-radius:999px;align-items:center;gap:2px;padding:1px 4px 1px 8px;font-size:11px;font-weight:500;line-height:17px;display:inline-flex}._0uSpIq_chipRemove{box-sizing:border-box;width:14px;height:14px;color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:none;border-radius:999px;flex:none;justify-content:center;align-items:center;padding:0;line-height:1;display:inline-flex}._0uSpIq_chipRemove:hover:not(:disabled){color:var(--dsw-alias-label-primary);background:var(--dsw-alias-interactive-bg-hover)}._0uSpIq_chipRemove:disabled{cursor:not-allowed;opacity:.4}._0uSpIq_chipRemove:focus-visible{outline:var(--dsw-focus-ring-width) solid var(--dsw-focus-ring-color,var(--dsw-alias-state-business-primary));outline-offset:0}._0uSpIq_empty{color:var(--dsw-alias-label-tertiary);margin:0;padding:8px;font-size:12px;line-height:1.5}";
|
|
3153
3104
|
const tagId = "@morlay/dsh-session-mode/TagInput.module.css";
|
|
3154
3105
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=\"@morlay/dsh-session-mode/TagInput.module.css\"]") === null) {
|
|
3155
3106
|
const tag = document.createElement("style");
|
|
@@ -3159,16 +3110,15 @@ window.__ModuleLoader__.load({
|
|
|
3159
3110
|
document.head.appendChild(tag);
|
|
3160
3111
|
}
|
|
3161
3112
|
var TagInput_module_css_default = {
|
|
3162
|
-
"
|
|
3163
|
-
"
|
|
3164
|
-
"
|
|
3165
|
-
"input": "
|
|
3166
|
-
"
|
|
3167
|
-
"empty": "
|
|
3168
|
-
"
|
|
3113
|
+
"chipRemove": "_0uSpIq_chipRemove",
|
|
3114
|
+
"row": "_0uSpIq_row",
|
|
3115
|
+
"box": "_0uSpIq_box",
|
|
3116
|
+
"input": "_0uSpIq_input",
|
|
3117
|
+
"chip": "_0uSpIq_chip",
|
|
3118
|
+
"empty": "_0uSpIq_empty",
|
|
3119
|
+
"anchor": "_0uSpIq_anchor"
|
|
3169
3120
|
};
|
|
3170
|
-
|
|
3171
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/controls/TagInput.tsx
|
|
3121
|
+
// ../../client/dsh-client-ui-primitives/src/client/controls/TagInput.tsx
|
|
3172
3122
|
function TagInput({ value, onChange, options, placeholder, label, disabled = false, noMatchLabel = "", removeLabel }) {
|
|
3173
3123
|
const [draft, setDraft] = (0, react.useState)("");
|
|
3174
3124
|
const [open, setOpen] = (0, react.useState)(false);
|
|
@@ -3256,8 +3206,7 @@ window.__ModuleLoader__.load({
|
|
|
3256
3206
|
})
|
|
3257
3207
|
});
|
|
3258
3208
|
}
|
|
3259
|
-
|
|
3260
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-string@4.0.0/node_modules/mdast-util-to-string/lib/index.js
|
|
3209
|
+
// ../../../node_modules/.pnpm/mdast-util-to-string@4.0.0/node_modules/mdast-util-to-string/lib/index.js
|
|
3261
3210
|
/**
|
|
3262
3211
|
* @typedef {import('mdast').Nodes} Nodes
|
|
3263
3212
|
*
|
|
@@ -3338,8 +3287,7 @@ window.__ModuleLoader__.load({
|
|
|
3338
3287
|
function node(value) {
|
|
3339
3288
|
return Boolean(value && typeof value === "object");
|
|
3340
3289
|
}
|
|
3341
|
-
|
|
3342
|
-
//#region ../../../node_modules/.pnpm/decode-named-character-reference@1.3.0/node_modules/decode-named-character-reference/index.dom.js
|
|
3290
|
+
// ../../../node_modules/.pnpm/decode-named-character-reference@1.3.0/node_modules/decode-named-character-reference/index.dom.js
|
|
3343
3291
|
const element = document.createElement("i");
|
|
3344
3292
|
/**
|
|
3345
3293
|
* @param {string} value
|
|
@@ -3352,8 +3300,7 @@ window.__ModuleLoader__.load({
|
|
|
3352
3300
|
if (character.charCodeAt(character.length - 1) === 59 && value !== "semi") return false;
|
|
3353
3301
|
return character === characterReference ? false : character;
|
|
3354
3302
|
}
|
|
3355
|
-
|
|
3356
|
-
//#region ../../../node_modules/.pnpm/micromark-util-chunked@2.0.1/node_modules/micromark-util-chunked/index.js
|
|
3303
|
+
// ../../../node_modules/.pnpm/micromark-util-chunked@2.0.1/node_modules/micromark-util-chunked/index.js
|
|
3357
3304
|
/**
|
|
3358
3305
|
* Like `Array#splice`, but smarter for giant arrays.
|
|
3359
3306
|
*
|
|
@@ -3422,8 +3369,7 @@ window.__ModuleLoader__.load({
|
|
|
3422
3369
|
}
|
|
3423
3370
|
return items;
|
|
3424
3371
|
}
|
|
3425
|
-
|
|
3426
|
-
//#region ../../../node_modules/.pnpm/micromark-util-combine-extensions@2.0.1/node_modules/micromark-util-combine-extensions/index.js
|
|
3372
|
+
// ../../../node_modules/.pnpm/micromark-util-combine-extensions@2.0.1/node_modules/micromark-util-combine-extensions/index.js
|
|
3427
3373
|
/**
|
|
3428
3374
|
* @import {
|
|
3429
3375
|
* Extension,
|
|
@@ -3493,8 +3439,7 @@ window.__ModuleLoader__.load({
|
|
|
3493
3439
|
while (++index < list.length) (list[index].add === "after" ? existing : before).push(list[index]);
|
|
3494
3440
|
splice(existing, 0, 0, before);
|
|
3495
3441
|
}
|
|
3496
|
-
|
|
3497
|
-
//#region ../../../node_modules/.pnpm/micromark-util-decode-numeric-character-reference@2.0.2/node_modules/micromark-util-decode-numeric-character-reference/index.js
|
|
3442
|
+
// ../../../node_modules/.pnpm/micromark-util-decode-numeric-character-reference@2.0.2/node_modules/micromark-util-decode-numeric-character-reference/index.js
|
|
3498
3443
|
/**
|
|
3499
3444
|
* Turn the number (in string form as either hexa- or plain decimal) coming from
|
|
3500
3445
|
* a numeric character reference into a character.
|
|
@@ -3514,8 +3459,7 @@ window.__ModuleLoader__.load({
|
|
|
3514
3459
|
if (code < 9 || code === 11 || code > 13 && code < 32 || code > 126 && code < 160 || code > 55295 && code < 57344 || code > 64975 && code < 65008 || (code & 65535) === 65535 || (code & 65535) === 65534 || code > 1114111) return "�";
|
|
3515
3460
|
return String.fromCodePoint(code);
|
|
3516
3461
|
}
|
|
3517
|
-
|
|
3518
|
-
//#region ../../../node_modules/.pnpm/micromark-util-normalize-identifier@2.0.1/node_modules/micromark-util-normalize-identifier/index.js
|
|
3462
|
+
// ../../../node_modules/.pnpm/micromark-util-normalize-identifier@2.0.1/node_modules/micromark-util-normalize-identifier/index.js
|
|
3519
3463
|
/**
|
|
3520
3464
|
* Normalize an identifier (as found in references, definitions).
|
|
3521
3465
|
*
|
|
@@ -3538,8 +3482,7 @@ window.__ModuleLoader__.load({
|
|
|
3538
3482
|
function normalizeIdentifier(value) {
|
|
3539
3483
|
return value.replace(/[\t\n\r ]+/g, " ").replace(/^ | $/g, "").toLowerCase().toUpperCase();
|
|
3540
3484
|
}
|
|
3541
|
-
|
|
3542
|
-
//#region ../../../node_modules/.pnpm/micromark-util-character@2.1.1/node_modules/micromark-util-character/index.js
|
|
3485
|
+
// ../../../node_modules/.pnpm/micromark-util-character@2.1.1/node_modules/micromark-util-character/index.js
|
|
3543
3486
|
/**
|
|
3544
3487
|
* @import {Code} from 'micromark-util-types'
|
|
3545
3488
|
*/
|
|
@@ -3767,8 +3710,7 @@ window.__ModuleLoader__.load({
|
|
|
3767
3710
|
}
|
|
3768
3711
|
}
|
|
3769
3712
|
({}).hasOwnProperty;
|
|
3770
|
-
|
|
3771
|
-
//#region ../../../node_modules/.pnpm/micromark-factory-space@2.1.0/node_modules/micromark-factory-space/index.js
|
|
3713
|
+
// ../../../node_modules/.pnpm/micromark-factory-space@2.1.0/node_modules/micromark-factory-space/index.js
|
|
3772
3714
|
/**
|
|
3773
3715
|
* @import {Effects, State, TokenType} from 'micromark-util-types'
|
|
3774
3716
|
*/
|
|
@@ -3874,8 +3816,7 @@ window.__ModuleLoader__.load({
|
|
|
3874
3816
|
return size >= min ? ok(code) : nok(code);
|
|
3875
3817
|
}
|
|
3876
3818
|
}
|
|
3877
|
-
|
|
3878
|
-
//#region ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/initialize/content.js
|
|
3819
|
+
// ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/initialize/content.js
|
|
3879
3820
|
/**
|
|
3880
3821
|
* @import {
|
|
3881
3822
|
* InitialConstruct,
|
|
@@ -3941,8 +3882,7 @@ window.__ModuleLoader__.load({
|
|
|
3941
3882
|
return data;
|
|
3942
3883
|
}
|
|
3943
3884
|
}
|
|
3944
|
-
|
|
3945
|
-
//#region ../../../node_modules/.pnpm/micromark-util-edit-map@1.0.0/node_modules/micromark-util-edit-map/index.js
|
|
3885
|
+
// ../../../node_modules/.pnpm/micromark-util-edit-map@1.0.0/node_modules/micromark-util-edit-map/index.js
|
|
3946
3886
|
/**
|
|
3947
3887
|
* @import {Event} from 'micromark-util-types'
|
|
3948
3888
|
*/
|
|
@@ -4087,8 +4027,7 @@ window.__ModuleLoader__.load({
|
|
|
4087
4027
|
editMap.map.push(change);
|
|
4088
4028
|
editMap.index.set(at, change);
|
|
4089
4029
|
}
|
|
4090
|
-
|
|
4091
|
-
//#region ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/initialize/document.js
|
|
4030
|
+
// ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/initialize/document.js
|
|
4092
4031
|
/**
|
|
4093
4032
|
* @import {
|
|
4094
4033
|
* Construct,
|
|
@@ -4307,8 +4246,7 @@ window.__ModuleLoader__.load({
|
|
|
4307
4246
|
function tokenizeContainer(effects, ok, nok) {
|
|
4308
4247
|
return factorySpace(effects, effects.attempt(this.parser.constructs.document, ok, nok), "linePrefix", this.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4);
|
|
4309
4248
|
}
|
|
4310
|
-
|
|
4311
|
-
//#region ../../../node_modules/.pnpm/micromark-util-classify-character@2.0.1/node_modules/micromark-util-classify-character/index.js
|
|
4249
|
+
// ../../../node_modules/.pnpm/micromark-util-classify-character@2.0.1/node_modules/micromark-util-classify-character/index.js
|
|
4312
4250
|
/**
|
|
4313
4251
|
* @import {Code} from 'micromark-util-types'
|
|
4314
4252
|
*/
|
|
@@ -4330,8 +4268,7 @@ window.__ModuleLoader__.load({
|
|
|
4330
4268
|
if (code === null || markdownLineEndingOrSpace(code) || unicodeWhitespace(code)) return 1;
|
|
4331
4269
|
if (unicodePunctuation(code)) return 2;
|
|
4332
4270
|
}
|
|
4333
|
-
|
|
4334
|
-
//#region ../../../node_modules/.pnpm/micromark-util-resolve-all@2.0.1/node_modules/micromark-util-resolve-all/index.js
|
|
4271
|
+
// ../../../node_modules/.pnpm/micromark-util-resolve-all@2.0.1/node_modules/micromark-util-resolve-all/index.js
|
|
4335
4272
|
/**
|
|
4336
4273
|
* @import {Event, Resolver, TokenizeContext} from 'micromark-util-types'
|
|
4337
4274
|
*/
|
|
@@ -4360,8 +4297,7 @@ window.__ModuleLoader__.load({
|
|
|
4360
4297
|
}
|
|
4361
4298
|
return events;
|
|
4362
4299
|
}
|
|
4363
|
-
|
|
4364
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/attention.js
|
|
4300
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/attention.js
|
|
4365
4301
|
/**
|
|
4366
4302
|
* @import {
|
|
4367
4303
|
* Code,
|
|
@@ -4568,8 +4504,7 @@ window.__ModuleLoader__.load({
|
|
|
4568
4504
|
point.offset += offset;
|
|
4569
4505
|
point._bufferIndex += offset;
|
|
4570
4506
|
}
|
|
4571
|
-
|
|
4572
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/autolink.js
|
|
4507
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/autolink.js
|
|
4573
4508
|
/**
|
|
4574
4509
|
* @import {
|
|
4575
4510
|
* Construct,
|
|
@@ -4779,8 +4714,7 @@ window.__ModuleLoader__.load({
|
|
|
4779
4714
|
return nok(code);
|
|
4780
4715
|
}
|
|
4781
4716
|
}
|
|
4782
|
-
|
|
4783
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/blank-line.js
|
|
4717
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/blank-line.js
|
|
4784
4718
|
/**
|
|
4785
4719
|
* @import {
|
|
4786
4720
|
* Construct,
|
|
@@ -4836,8 +4770,7 @@ window.__ModuleLoader__.load({
|
|
|
4836
4770
|
return code === null || markdownLineEnding(code) ? ok(code) : nok(code);
|
|
4837
4771
|
}
|
|
4838
4772
|
}
|
|
4839
|
-
|
|
4840
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/block-quote.js
|
|
4773
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/block-quote.js
|
|
4841
4774
|
/**
|
|
4842
4775
|
* @import {
|
|
4843
4776
|
* Construct,
|
|
@@ -4963,8 +4896,7 @@ window.__ModuleLoader__.load({
|
|
|
4963
4896
|
function exit$1(effects) {
|
|
4964
4897
|
effects.exit("blockQuote");
|
|
4965
4898
|
}
|
|
4966
|
-
|
|
4967
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/character-escape.js
|
|
4899
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/character-escape.js
|
|
4968
4900
|
/**
|
|
4969
4901
|
* @import {
|
|
4970
4902
|
* Construct,
|
|
@@ -5023,8 +4955,7 @@ window.__ModuleLoader__.load({
|
|
|
5023
4955
|
return nok(code);
|
|
5024
4956
|
}
|
|
5025
4957
|
}
|
|
5026
|
-
|
|
5027
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/character-reference.js
|
|
4958
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/character-reference.js
|
|
5028
4959
|
/**
|
|
5029
4960
|
* @import {
|
|
5030
4961
|
* Code,
|
|
@@ -5161,8 +5092,7 @@ window.__ModuleLoader__.load({
|
|
|
5161
5092
|
return nok(code);
|
|
5162
5093
|
}
|
|
5163
5094
|
}
|
|
5164
|
-
|
|
5165
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/partial-non-lazy-continuation.js
|
|
5095
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/partial-non-lazy-continuation.js
|
|
5166
5096
|
/** @type {Construct} */
|
|
5167
5097
|
const nonLazyContinuation = {
|
|
5168
5098
|
partial: true,
|
|
@@ -5209,8 +5139,7 @@ window.__ModuleLoader__.load({
|
|
|
5209
5139
|
return self.parser.lazy[self.now().line] ? nok(code) : ok(code);
|
|
5210
5140
|
}
|
|
5211
5141
|
}
|
|
5212
|
-
|
|
5213
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/code-fenced.js
|
|
5142
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/code-fenced.js
|
|
5214
5143
|
/**
|
|
5215
5144
|
* @import {
|
|
5216
5145
|
* Code,
|
|
@@ -5590,8 +5519,7 @@ window.__ModuleLoader__.load({
|
|
|
5590
5519
|
}
|
|
5591
5520
|
}
|
|
5592
5521
|
}
|
|
5593
|
-
|
|
5594
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/code-indented.js
|
|
5522
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/code-indented.js
|
|
5595
5523
|
/**
|
|
5596
5524
|
* @import {
|
|
5597
5525
|
* Construct,
|
|
@@ -5722,8 +5650,7 @@ window.__ModuleLoader__.load({
|
|
|
5722
5650
|
return markdownLineEnding(code) ? furtherStart(code) : nok(code);
|
|
5723
5651
|
}
|
|
5724
5652
|
}
|
|
5725
|
-
|
|
5726
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/code-text.js
|
|
5653
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/code-text.js
|
|
5727
5654
|
/**
|
|
5728
5655
|
* @import {
|
|
5729
5656
|
* Construct,
|
|
@@ -5907,8 +5834,7 @@ window.__ModuleLoader__.load({
|
|
|
5907
5834
|
return data(code);
|
|
5908
5835
|
}
|
|
5909
5836
|
}
|
|
5910
|
-
|
|
5911
|
-
//#region ../../../node_modules/.pnpm/micromark-util-subtokenize@2.1.0/node_modules/micromark-util-subtokenize/lib/splice-buffer.js
|
|
5837
|
+
// ../../../node_modules/.pnpm/micromark-util-subtokenize@2.1.0/node_modules/micromark-util-subtokenize/lib/splice-buffer.js
|
|
5912
5838
|
/**
|
|
5913
5839
|
* Some of the internal operations of micromark do lots of editing
|
|
5914
5840
|
* operations on very large arrays. This runs into problems with two
|
|
@@ -6137,8 +6063,7 @@ window.__ModuleLoader__.load({
|
|
|
6137
6063
|
chunkStart += 1e4;
|
|
6138
6064
|
}
|
|
6139
6065
|
}
|
|
6140
|
-
|
|
6141
|
-
//#region ../../../node_modules/.pnpm/micromark-util-subtokenize@2.1.0/node_modules/micromark-util-subtokenize/index.js
|
|
6066
|
+
// ../../../node_modules/.pnpm/micromark-util-subtokenize@2.1.0/node_modules/micromark-util-subtokenize/index.js
|
|
6142
6067
|
/**
|
|
6143
6068
|
* @import {Chunk, Event, Token} from 'micromark-util-types'
|
|
6144
6069
|
*/
|
|
@@ -6292,8 +6217,7 @@ window.__ModuleLoader__.load({
|
|
|
6292
6217
|
}
|
|
6293
6218
|
return gaps;
|
|
6294
6219
|
}
|
|
6295
|
-
|
|
6296
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/content.js
|
|
6220
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/content.js
|
|
6297
6221
|
/**
|
|
6298
6222
|
* @import {
|
|
6299
6223
|
* Construct,
|
|
@@ -6425,8 +6349,7 @@ window.__ModuleLoader__.load({
|
|
|
6425
6349
|
return effects.interrupt(self.parser.constructs.flow, nok, ok)(code);
|
|
6426
6350
|
}
|
|
6427
6351
|
}
|
|
6428
|
-
|
|
6429
|
-
//#region ../../../node_modules/.pnpm/micromark-factory-destination@2.0.1/node_modules/micromark-factory-destination/index.js
|
|
6352
|
+
// ../../../node_modules/.pnpm/micromark-factory-destination@2.0.1/node_modules/micromark-factory-destination/index.js
|
|
6430
6353
|
/**
|
|
6431
6354
|
* @import {Effects, State, TokenType} from 'micromark-util-types'
|
|
6432
6355
|
*/
|
|
@@ -6609,8 +6532,7 @@ window.__ModuleLoader__.load({
|
|
|
6609
6532
|
return raw(code);
|
|
6610
6533
|
}
|
|
6611
6534
|
}
|
|
6612
|
-
|
|
6613
|
-
//#region ../../../node_modules/.pnpm/micromark-factory-label@2.0.1/node_modules/micromark-factory-label/index.js
|
|
6535
|
+
// ../../../node_modules/.pnpm/micromark-factory-label@2.0.1/node_modules/micromark-factory-label/index.js
|
|
6614
6536
|
/**
|
|
6615
6537
|
* @import {
|
|
6616
6538
|
* Effects,
|
|
@@ -6743,8 +6665,7 @@ window.__ModuleLoader__.load({
|
|
|
6743
6665
|
return labelInside(code);
|
|
6744
6666
|
}
|
|
6745
6667
|
}
|
|
6746
|
-
|
|
6747
|
-
//#region ../../../node_modules/.pnpm/micromark-factory-title@2.0.1/node_modules/micromark-factory-title/index.js
|
|
6668
|
+
// ../../../node_modules/.pnpm/micromark-factory-title@2.0.1/node_modules/micromark-factory-title/index.js
|
|
6748
6669
|
/**
|
|
6749
6670
|
* @import {
|
|
6750
6671
|
* Code,
|
|
@@ -6888,8 +6809,7 @@ window.__ModuleLoader__.load({
|
|
|
6888
6809
|
return inside(code);
|
|
6889
6810
|
}
|
|
6890
6811
|
}
|
|
6891
|
-
|
|
6892
|
-
//#region ../../../node_modules/.pnpm/micromark-factory-whitespace@2.0.1/node_modules/micromark-factory-whitespace/index.js
|
|
6812
|
+
// ../../../node_modules/.pnpm/micromark-factory-whitespace@2.0.1/node_modules/micromark-factory-whitespace/index.js
|
|
6893
6813
|
/**
|
|
6894
6814
|
* @import {Effects, State} from 'micromark-util-types'
|
|
6895
6815
|
*/
|
|
@@ -6928,8 +6848,7 @@ window.__ModuleLoader__.load({
|
|
|
6928
6848
|
return ok(code);
|
|
6929
6849
|
}
|
|
6930
6850
|
}
|
|
6931
|
-
|
|
6932
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/definition.js
|
|
6851
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/definition.js
|
|
6933
6852
|
/**
|
|
6934
6853
|
* @import {
|
|
6935
6854
|
* Construct,
|
|
@@ -7143,8 +7062,7 @@ window.__ModuleLoader__.load({
|
|
|
7143
7062
|
return code === null || markdownLineEnding(code) ? ok(code) : nok(code);
|
|
7144
7063
|
}
|
|
7145
7064
|
}
|
|
7146
|
-
|
|
7147
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/hard-break-escape.js
|
|
7065
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/hard-break-escape.js
|
|
7148
7066
|
/**
|
|
7149
7067
|
* @import {
|
|
7150
7068
|
* Construct,
|
|
@@ -7200,8 +7118,7 @@ window.__ModuleLoader__.load({
|
|
|
7200
7118
|
return nok(code);
|
|
7201
7119
|
}
|
|
7202
7120
|
}
|
|
7203
|
-
|
|
7204
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/heading-atx.js
|
|
7121
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/heading-atx.js
|
|
7205
7122
|
/**
|
|
7206
7123
|
* @import {
|
|
7207
7124
|
* Construct,
|
|
@@ -7381,8 +7298,7 @@ window.__ModuleLoader__.load({
|
|
|
7381
7298
|
return data;
|
|
7382
7299
|
}
|
|
7383
7300
|
}
|
|
7384
|
-
|
|
7385
|
-
//#region ../../../node_modules/.pnpm/micromark-util-html-tag-name@2.0.1/node_modules/micromark-util-html-tag-name/index.js
|
|
7301
|
+
// ../../../node_modules/.pnpm/micromark-util-html-tag-name@2.0.1/node_modules/micromark-util-html-tag-name/index.js
|
|
7386
7302
|
/**
|
|
7387
7303
|
* List of lowercase HTML “block” tag names.
|
|
7388
7304
|
*
|
|
@@ -7480,8 +7396,7 @@ window.__ModuleLoader__.load({
|
|
|
7480
7396
|
"style",
|
|
7481
7397
|
"textarea"
|
|
7482
7398
|
];
|
|
7483
|
-
|
|
7484
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/html-flow.js
|
|
7399
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/html-flow.js
|
|
7485
7400
|
/**
|
|
7486
7401
|
* @import {
|
|
7487
7402
|
* Code,
|
|
@@ -8206,8 +8121,7 @@ window.__ModuleLoader__.load({
|
|
|
8206
8121
|
return effects.attempt(blankLine, ok, nok);
|
|
8207
8122
|
}
|
|
8208
8123
|
}
|
|
8209
|
-
|
|
8210
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/html-text.js
|
|
8124
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/html-text.js
|
|
8211
8125
|
/**
|
|
8212
8126
|
* @import {
|
|
8213
8127
|
* Code,
|
|
@@ -8820,8 +8734,7 @@ window.__ModuleLoader__.load({
|
|
|
8820
8734
|
return returnState(code);
|
|
8821
8735
|
}
|
|
8822
8736
|
}
|
|
8823
|
-
|
|
8824
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/label-end.js
|
|
8737
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/label-end.js
|
|
8825
8738
|
/**
|
|
8826
8739
|
* @import {
|
|
8827
8740
|
* Construct,
|
|
@@ -9289,8 +9202,7 @@ window.__ModuleLoader__.load({
|
|
|
9289
9202
|
return nok(code);
|
|
9290
9203
|
}
|
|
9291
9204
|
}
|
|
9292
|
-
|
|
9293
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/label-start-image.js
|
|
9205
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/label-start-image.js
|
|
9294
9206
|
/**
|
|
9295
9207
|
* @import {
|
|
9296
9208
|
* Construct,
|
|
@@ -9388,8 +9300,7 @@ window.__ModuleLoader__.load({
|
|
|
9388
9300
|
return ok(code);
|
|
9389
9301
|
}
|
|
9390
9302
|
}
|
|
9391
|
-
|
|
9392
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/label-start-link.js
|
|
9303
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/label-start-link.js
|
|
9393
9304
|
/**
|
|
9394
9305
|
* @import {
|
|
9395
9306
|
* Construct,
|
|
@@ -9442,8 +9353,7 @@ window.__ModuleLoader__.load({
|
|
|
9442
9353
|
return ok(code);
|
|
9443
9354
|
}
|
|
9444
9355
|
}
|
|
9445
|
-
|
|
9446
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/line-ending.js
|
|
9356
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/line-ending.js
|
|
9447
9357
|
/**
|
|
9448
9358
|
* @import {
|
|
9449
9359
|
* Construct,
|
|
@@ -9472,8 +9382,7 @@ window.__ModuleLoader__.load({
|
|
|
9472
9382
|
return factorySpace(effects, ok, "linePrefix");
|
|
9473
9383
|
}
|
|
9474
9384
|
}
|
|
9475
|
-
|
|
9476
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/thematic-break.js
|
|
9385
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/thematic-break.js
|
|
9477
9386
|
/**
|
|
9478
9387
|
* @import {
|
|
9479
9388
|
* Code,
|
|
@@ -9567,8 +9476,7 @@ window.__ModuleLoader__.load({
|
|
|
9567
9476
|
return markdownSpace(code) ? factorySpace(effects, atBreak, "whitespace")(code) : atBreak(code);
|
|
9568
9477
|
}
|
|
9569
9478
|
}
|
|
9570
|
-
|
|
9571
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/list.js
|
|
9479
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/list.js
|
|
9572
9480
|
/**
|
|
9573
9481
|
* @import {
|
|
9574
9482
|
* Code,
|
|
@@ -9739,8 +9647,7 @@ window.__ModuleLoader__.load({
|
|
|
9739
9647
|
return !markdownSpace(code) && tail && tail[1].type === "listItemPrefixWhitespace" ? ok(code) : nok(code);
|
|
9740
9648
|
}
|
|
9741
9649
|
}
|
|
9742
|
-
|
|
9743
|
-
//#region ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/setext-underline.js
|
|
9650
|
+
// ../../../node_modules/.pnpm/micromark-core-commonmark@2.0.4/node_modules/micromark-core-commonmark/lib/setext-underline.js
|
|
9744
9651
|
/**
|
|
9745
9652
|
* @import {
|
|
9746
9653
|
* Code,
|
|
@@ -9893,8 +9800,7 @@ window.__ModuleLoader__.load({
|
|
|
9893
9800
|
return nok(code);
|
|
9894
9801
|
}
|
|
9895
9802
|
}
|
|
9896
|
-
|
|
9897
|
-
//#region ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/initialize/flow.js
|
|
9803
|
+
// ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/initialize/flow.js
|
|
9898
9804
|
/**
|
|
9899
9805
|
* @import {
|
|
9900
9806
|
* InitialConstruct,
|
|
@@ -9940,8 +9846,7 @@ window.__ModuleLoader__.load({
|
|
|
9940
9846
|
return initial;
|
|
9941
9847
|
}
|
|
9942
9848
|
}
|
|
9943
|
-
|
|
9944
|
-
//#region ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/initialize/text.js
|
|
9849
|
+
// ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/initialize/text.js
|
|
9945
9850
|
/**
|
|
9946
9851
|
* @import {
|
|
9947
9852
|
* Code,
|
|
@@ -10116,8 +10021,7 @@ window.__ModuleLoader__.load({
|
|
|
10116
10021
|
editMap.consume(events);
|
|
10117
10022
|
return events;
|
|
10118
10023
|
}
|
|
10119
|
-
|
|
10120
|
-
//#region ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/constructs.js
|
|
10024
|
+
// ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/constructs.js
|
|
10121
10025
|
/**
|
|
10122
10026
|
* @import {Extension} from 'micromark-util-types'
|
|
10123
10027
|
*/
|
|
@@ -10194,8 +10098,7 @@ window.__ModuleLoader__.load({
|
|
|
10194
10098
|
const attentionMarkers = { null: [42, 95] };
|
|
10195
10099
|
/** @satisfies {Extension['disable']} */
|
|
10196
10100
|
const disable = { null: [] };
|
|
10197
|
-
|
|
10198
|
-
//#region ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/create-tokenizer.js
|
|
10101
|
+
// ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/create-tokenizer.js
|
|
10199
10102
|
/**
|
|
10200
10103
|
* @import {
|
|
10201
10104
|
* Chunk,
|
|
@@ -10661,8 +10564,7 @@ window.__ModuleLoader__.load({
|
|
|
10661
10564
|
}
|
|
10662
10565
|
return result.join("");
|
|
10663
10566
|
}
|
|
10664
|
-
|
|
10665
|
-
//#region ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/parse.js
|
|
10567
|
+
// ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/parse.js
|
|
10666
10568
|
/**
|
|
10667
10569
|
* @import {
|
|
10668
10570
|
* Create,
|
|
@@ -10705,8 +10607,7 @@ window.__ModuleLoader__.load({
|
|
|
10705
10607
|
}
|
|
10706
10608
|
}
|
|
10707
10609
|
}
|
|
10708
|
-
|
|
10709
|
-
//#region ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/postprocess.js
|
|
10610
|
+
// ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/postprocess.js
|
|
10710
10611
|
/**
|
|
10711
10612
|
* @import {Event} from 'micromark-util-types'
|
|
10712
10613
|
*/
|
|
@@ -10720,8 +10621,7 @@ window.__ModuleLoader__.load({
|
|
|
10720
10621
|
while (!subtokenize(events));
|
|
10721
10622
|
return events;
|
|
10722
10623
|
}
|
|
10723
|
-
|
|
10724
|
-
//#region ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/preprocess.js
|
|
10624
|
+
// ../../../node_modules/.pnpm/micromark@4.0.3_supports-color@9.4.0/node_modules/micromark/lib/preprocess.js
|
|
10725
10625
|
/**
|
|
10726
10626
|
* @import {Chunk, Code, Encoding, Value} from 'micromark-util-types'
|
|
10727
10627
|
*/
|
|
@@ -10812,8 +10712,7 @@ window.__ModuleLoader__.load({
|
|
|
10812
10712
|
return chunks;
|
|
10813
10713
|
}
|
|
10814
10714
|
}
|
|
10815
|
-
|
|
10816
|
-
//#region ../../../node_modules/.pnpm/micromark-util-decode-string@2.0.1/node_modules/micromark-util-decode-string/index.js
|
|
10715
|
+
// ../../../node_modules/.pnpm/micromark-util-decode-string@2.0.1/node_modules/micromark-util-decode-string/index.js
|
|
10817
10716
|
const characterEscapeOrReference = /\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;
|
|
10818
10717
|
/**
|
|
10819
10718
|
* Decode markdown strings (which occur in places such as fenced code info
|
|
@@ -10849,8 +10748,7 @@ window.__ModuleLoader__.load({
|
|
|
10849
10748
|
}
|
|
10850
10749
|
return decodeNamedCharacterReference($2) || $0;
|
|
10851
10750
|
}
|
|
10852
|
-
|
|
10853
|
-
//#region ../../../node_modules/.pnpm/unist-util-stringify-position@4.0.0/node_modules/unist-util-stringify-position/lib/index.js
|
|
10751
|
+
// ../../../node_modules/.pnpm/unist-util-stringify-position@4.0.0/node_modules/unist-util-stringify-position/lib/index.js
|
|
10854
10752
|
/**
|
|
10855
10753
|
* @typedef {import('unist').Node} Node
|
|
10856
10754
|
* @typedef {import('unist').Point} Point
|
|
@@ -10913,8 +10811,7 @@ window.__ModuleLoader__.load({
|
|
|
10913
10811
|
function index(value) {
|
|
10914
10812
|
return value && typeof value === "number" ? value : 1;
|
|
10915
10813
|
}
|
|
10916
|
-
|
|
10917
|
-
//#region ../../../node_modules/.pnpm/mdast-util-from-markdown@2.1.0_supports-color@9.4.0/node_modules/mdast-util-from-markdown/lib/index.js
|
|
10814
|
+
// ../../../node_modules/.pnpm/mdast-util-from-markdown@2.1.0_supports-color@9.4.0/node_modules/mdast-util-from-markdown/lib/index.js
|
|
10918
10815
|
/**
|
|
10919
10816
|
* @import {
|
|
10920
10817
|
* Break,
|
|
@@ -11960,8 +11857,7 @@ window.__ModuleLoader__.load({
|
|
|
11960
11857
|
end: right.end
|
|
11961
11858
|
}) + ") is still open");
|
|
11962
11859
|
}
|
|
11963
|
-
|
|
11964
|
-
//#region ../../../node_modules/.pnpm/ccount@2.0.1/node_modules/ccount/index.js
|
|
11860
|
+
// ../../../node_modules/.pnpm/ccount@2.0.1/node_modules/ccount/index.js
|
|
11965
11861
|
/**
|
|
11966
11862
|
* Count how often a character (or substring) is used in a string.
|
|
11967
11863
|
*
|
|
@@ -11983,14 +11879,12 @@ window.__ModuleLoader__.load({
|
|
|
11983
11879
|
}
|
|
11984
11880
|
return count;
|
|
11985
11881
|
}
|
|
11986
|
-
|
|
11987
|
-
//#region ../../../node_modules/.pnpm/escape-string-regexp@5.0.0/node_modules/escape-string-regexp/index.js
|
|
11882
|
+
// ../../../node_modules/.pnpm/escape-string-regexp@5.0.0/node_modules/escape-string-regexp/index.js
|
|
11988
11883
|
function escapeStringRegexp(string) {
|
|
11989
11884
|
if (typeof string !== "string") throw new TypeError("Expected a string");
|
|
11990
11885
|
return string.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
|
|
11991
11886
|
}
|
|
11992
|
-
|
|
11993
|
-
//#region ../../../node_modules/.pnpm/unist-util-is@6.0.1/node_modules/unist-util-is/lib/index.js
|
|
11887
|
+
// ../../../node_modules/.pnpm/unist-util-is@6.0.1/node_modules/unist-util-is/lib/index.js
|
|
11994
11888
|
/**
|
|
11995
11889
|
* Generate an assertion from a test.
|
|
11996
11890
|
*
|
|
@@ -12103,17 +11997,19 @@ window.__ModuleLoader__.load({
|
|
|
12103
11997
|
function looksLikeANode(value) {
|
|
12104
11998
|
return value !== null && typeof value === "object" && "type" in value;
|
|
12105
11999
|
}
|
|
12106
|
-
|
|
12107
|
-
//#region ../../../node_modules/.pnpm/unist-util-visit-parents@6.0.2/node_modules/unist-util-visit-parents/lib/color.js
|
|
12000
|
+
// ../../../node_modules/.pnpm/unist-util-visit-parents@6.1.0/node_modules/unist-util-visit-parents/lib/color.js
|
|
12108
12001
|
/**
|
|
12002
|
+
* Color a string.
|
|
12003
|
+
*
|
|
12109
12004
|
* @param {string} d
|
|
12005
|
+
* Value.
|
|
12110
12006
|
* @returns {string}
|
|
12007
|
+
* Colored value.
|
|
12111
12008
|
*/
|
|
12112
12009
|
function color(d) {
|
|
12113
12010
|
return d;
|
|
12114
12011
|
}
|
|
12115
|
-
|
|
12116
|
-
//#region ../../../node_modules/.pnpm/unist-util-visit-parents@6.0.2/node_modules/unist-util-visit-parents/lib/index.js
|
|
12012
|
+
// ../../../node_modules/.pnpm/unist-util-visit-parents@6.1.0/node_modules/unist-util-visit-parents/lib/index.js
|
|
12117
12013
|
/**
|
|
12118
12014
|
* @import {Node as UnistNode, Parent as UnistParent} from 'unist'
|
|
12119
12015
|
*/
|
|
@@ -12271,43 +12167,93 @@ window.__ModuleLoader__.load({
|
|
|
12271
12167
|
* List with one or two values, the first an action, the second an index.
|
|
12272
12168
|
*
|
|
12273
12169
|
* @typedef {Action | ActionTuple | Index | null | undefined | void} VisitorResult
|
|
12274
|
-
* Any value that can be returned from
|
|
12170
|
+
* Any value that can be returned from an enter visitor.
|
|
12171
|
+
*
|
|
12172
|
+
* Like `VisitorResultExit`,
|
|
12173
|
+
* but `SKIP` can also be returned,
|
|
12174
|
+
* to not walk the children of the node,
|
|
12175
|
+
* and `ActionTuple` can be used to combine an action with an index.
|
|
12176
|
+
*
|
|
12177
|
+
* @typedef {Index | boolean | null | undefined | void} VisitorResultExit
|
|
12178
|
+
* Any value that can be returned from an exit visitor.
|
|
12275
12179
|
*/
|
|
12276
12180
|
/**
|
|
12277
12181
|
* @callback Visitor
|
|
12278
|
-
* Handle a node (matching `test`, if given).
|
|
12279
|
-
*
|
|
12280
|
-
* Visitors are free to transform `node`.
|
|
12281
|
-
* They can also transform the parent of node (the last of `ancestors`).
|
|
12182
|
+
* Handle a node (matching `test`, if given) before its children.
|
|
12282
12183
|
*
|
|
12283
|
-
*
|
|
12284
|
-
*
|
|
12285
|
-
*
|
|
12286
|
-
*
|
|
12287
|
-
*
|
|
12288
|
-
*
|
|
12289
|
-
*
|
|
12290
|
-
*
|
|
12291
|
-
*
|
|
12292
|
-
* Removing the children property of an ancestor still results in them being
|
|
12293
|
-
* traversed.
|
|
12184
|
+
* Changes inside `node` are walked next.
|
|
12185
|
+
* Replacing or removing it is easier in `exit`.
|
|
12186
|
+
* When replacing or removing it here,
|
|
12187
|
+
* return `SKIP` (as otherwise its old children are walked),
|
|
12188
|
+
* or `[SKIP, index]` to continue with the node now at `index`.
|
|
12189
|
+
* Changing next siblings (in walk order) is fine;
|
|
12190
|
+
* changing previous siblings needs a new `Index`.
|
|
12191
|
+
* Removing an ancestor or changing its previous siblings is not supported.
|
|
12294
12192
|
* @param {Visited} node
|
|
12295
12193
|
* Found node.
|
|
12296
12194
|
* @param {Array<VisitedParents>} ancestors
|
|
12297
12195
|
* Ancestors of `node`.
|
|
12196
|
+
* @param {number | undefined} index
|
|
12197
|
+
* Index of `node` in its parent (the last of `ancestors`),
|
|
12198
|
+
* or `undefined` for the tree itself.
|
|
12298
12199
|
* @returns {VisitorResult}
|
|
12299
12200
|
* What to do next.
|
|
12300
12201
|
*
|
|
12301
|
-
*
|
|
12302
|
-
*
|
|
12202
|
+
* Like `VisitorExit`,
|
|
12203
|
+
* but `SKIP` can also be returned,
|
|
12204
|
+
* to not walk the children of `node`.
|
|
12205
|
+
* Passing a tuple back (`ActionTuple`) only makes sense as `[SKIP, Index]`.
|
|
12206
|
+
* @template {UnistNode} [Visited=UnistNode]
|
|
12207
|
+
* Visited node type.
|
|
12208
|
+
* @template {UnistParent} [VisitedParents=UnistParent]
|
|
12209
|
+
* Ancestor type.
|
|
12210
|
+
*/
|
|
12211
|
+
/**
|
|
12212
|
+
* @callback VisitorExit
|
|
12213
|
+
* Handle a node (matching `test`, if given) after its children.
|
|
12303
12214
|
*
|
|
12304
|
-
*
|
|
12305
|
-
*
|
|
12306
|
-
*
|
|
12215
|
+
* Changes inside `node` are not walked,
|
|
12216
|
+
* which makes this a good place to change `node` based on its children,
|
|
12217
|
+
* or to replace or remove it.
|
|
12218
|
+
* When removing `node` or changing previous siblings (in walk order),
|
|
12219
|
+
* return a new `Index`.
|
|
12220
|
+
* Removing an ancestor or changing its previous siblings is not supported.
|
|
12221
|
+
* @param {Visited} node
|
|
12222
|
+
* Found node.
|
|
12223
|
+
* @param {Array<VisitedParents>} ancestors
|
|
12224
|
+
* Ancestors of `node`.
|
|
12225
|
+
* @param {number | undefined} index
|
|
12226
|
+
* Index of `node` in its parent (the last of `ancestors`),
|
|
12227
|
+
* or `undefined` for the tree itself.
|
|
12228
|
+
* @returns {VisitorResultExit}
|
|
12229
|
+
* What to do next.
|
|
12230
|
+
*
|
|
12231
|
+
* `CONTINUE` (`true`, nothing) continues as normal,
|
|
12232
|
+
* `EXIT` (`false`) stops traversing,
|
|
12233
|
+
* and `Index` continues at that sibling.
|
|
12234
|
+
* @template {UnistNode} [Visited=UnistNode]
|
|
12235
|
+
* Visited node type.
|
|
12236
|
+
* @template {UnistParent} [VisitedParents=UnistParent]
|
|
12237
|
+
* Ancestor type.
|
|
12238
|
+
*/
|
|
12239
|
+
/**
|
|
12307
12240
|
* @template {UnistNode} [Visited=UnistNode]
|
|
12308
12241
|
* Visited node type.
|
|
12309
12242
|
* @template {UnistParent} [VisitedParents=UnistParent]
|
|
12310
12243
|
* Ancestor type.
|
|
12244
|
+
* @typedef Visitors
|
|
12245
|
+
* Handle nodes when entering and exiting them.
|
|
12246
|
+
* The `enter` visitor is optional while `exit` is required.
|
|
12247
|
+
*
|
|
12248
|
+
* Pass an `enter` visitor directly to only handle nodes when entering them.
|
|
12249
|
+
*
|
|
12250
|
+
* `enter` is called before children (if any) are walked and `exit` after that.
|
|
12251
|
+
* `exit` is still called when `enter` returns `SKIP`.
|
|
12252
|
+
* Both `enter` and `exit` are only called for nodes that match an optional `test`.
|
|
12253
|
+
* @property {Visitor<Visited, VisitedParents> | null | undefined} [enter]
|
|
12254
|
+
* Handle a node before its children (optional).
|
|
12255
|
+
* @property {VisitorExit<Visited, VisitedParents>} exit
|
|
12256
|
+
* Handle a node after its children.
|
|
12311
12257
|
*/
|
|
12312
12258
|
/**
|
|
12313
12259
|
* @typedef {Visitor<Matches<InclusiveDescendant<Tree>, Check>, Ancestor<Tree, Matches<InclusiveDescendant<Tree>, Check>>>} BuildVisitor
|
|
@@ -12319,16 +12265,34 @@ window.__ModuleLoader__.load({
|
|
|
12319
12265
|
* @template {Test} [Check=Test]
|
|
12320
12266
|
* Test type.
|
|
12321
12267
|
*/
|
|
12268
|
+
/**
|
|
12269
|
+
* @typedef {Visitors<Matches<InclusiveDescendant<Tree>, Check>, Ancestor<Tree, Matches<InclusiveDescendant<Tree>, Check>>>} BuildVisitors
|
|
12270
|
+
* Build typed `Visitors` from a tree and a test.
|
|
12271
|
+
*
|
|
12272
|
+
* It will infer which values are passed as `node` and which as `parents`.
|
|
12273
|
+
* @template {UnistNode} [Tree=UnistNode]
|
|
12274
|
+
* Tree type.
|
|
12275
|
+
* @template {Test} [Check=Test]
|
|
12276
|
+
* Test type.
|
|
12277
|
+
*/
|
|
12322
12278
|
/** @type {Readonly<ActionTuple>} */
|
|
12323
12279
|
const empty = [];
|
|
12324
12280
|
/**
|
|
12281
|
+
* Do not traverse this node’s children.
|
|
12282
|
+
* Only works when entering a node.
|
|
12283
|
+
*/
|
|
12284
|
+
const SKIP = "skip";
|
|
12285
|
+
/**
|
|
12325
12286
|
* Visit nodes, with ancestral information.
|
|
12326
12287
|
*
|
|
12327
12288
|
* This algorithm performs *depth-first* *tree traversal* in *preorder*
|
|
12328
|
-
* (**NLR**) or if `reverse` is given,
|
|
12289
|
+
* (**NLR**) or if `reverse` is given,
|
|
12290
|
+
* in *reverse preorder* (**NRL**).
|
|
12291
|
+
* An `exit` visitor is called in *postorder* (**LRN**)
|
|
12292
|
+
* or if `reverse` is given, in *reverse postorder* (**RLN**).
|
|
12329
12293
|
*
|
|
12330
|
-
* You can choose
|
|
12331
|
-
* For complex tests, you should test yourself in
|
|
12294
|
+
* You can choose which nodes are visited by passing a `test`.
|
|
12295
|
+
* For complex tests, you should test yourself in a visitor, as it will be
|
|
12332
12296
|
* faster and will have improved type information.
|
|
12333
12297
|
*
|
|
12334
12298
|
* Walking the tree is an intensive task.
|
|
@@ -12337,29 +12301,72 @@ window.__ModuleLoader__.load({
|
|
|
12337
12301
|
* to check if a node matches, and then perform different operations.
|
|
12338
12302
|
*
|
|
12339
12303
|
* You can change the tree.
|
|
12340
|
-
*
|
|
12304
|
+
* Changes inside a node made when entering it are walked,
|
|
12305
|
+
* changes made when exiting it are not.
|
|
12306
|
+
* See `Visitor` and `VisitorExit` for more info.
|
|
12341
12307
|
*
|
|
12342
12308
|
* @overload
|
|
12343
12309
|
* @param {Tree} tree
|
|
12310
|
+
* Tree to traverse.
|
|
12344
12311
|
* @param {Check} check
|
|
12345
|
-
*
|
|
12312
|
+
* `unist-util-is`-compatible test.
|
|
12313
|
+
* @param {BuildVisitor<Tree, Check>} enter
|
|
12314
|
+
* Handle each node when entering it.
|
|
12346
12315
|
* @param {boolean | null | undefined} [reverse]
|
|
12316
|
+
* Walk children from last to first;
|
|
12317
|
+
* for `enter`, reverse preorder (NRL) instead of preorder (NLR);
|
|
12318
|
+
* for `exit`, reverse postorder (RLN) instead of postorder (LRN).
|
|
12347
12319
|
* @returns {undefined}
|
|
12320
|
+
* Nothing.
|
|
12348
12321
|
*
|
|
12349
12322
|
* @overload
|
|
12350
12323
|
* @param {Tree} tree
|
|
12351
|
-
*
|
|
12324
|
+
* Tree to traverse.
|
|
12325
|
+
* @param {Check} check
|
|
12326
|
+
* `unist-util-is`-compatible test.
|
|
12327
|
+
* @param {BuildVisitors<Tree, Check>} visitors
|
|
12328
|
+
* Handle each node when exiting it, and optionally when entering it.
|
|
12352
12329
|
* @param {boolean | null | undefined} [reverse]
|
|
12330
|
+
* Walk children from last to first;
|
|
12331
|
+
* for `enter`, reverse preorder (NRL) instead of preorder (NLR);
|
|
12332
|
+
* for `exit`, reverse postorder (RLN) instead of postorder (LRN).
|
|
12353
12333
|
* @returns {undefined}
|
|
12334
|
+
* Nothing.
|
|
12335
|
+
*
|
|
12336
|
+
* @overload
|
|
12337
|
+
* @param {Tree} tree
|
|
12338
|
+
* Tree to traverse.
|
|
12339
|
+
* @param {BuildVisitor<Tree>} enter
|
|
12340
|
+
* Handle each node when entering it.
|
|
12341
|
+
* @param {boolean | null | undefined} [reverse]
|
|
12342
|
+
* Walk children from last to first;
|
|
12343
|
+
* for `enter`, reverse preorder (NRL) instead of preorder (NLR);
|
|
12344
|
+
* for `exit`, reverse postorder (RLN) instead of postorder (LRN).
|
|
12345
|
+
* @returns {undefined}
|
|
12346
|
+
* Nothing.
|
|
12347
|
+
*
|
|
12348
|
+
* @overload
|
|
12349
|
+
* @param {Tree} tree
|
|
12350
|
+
* Tree to traverse.
|
|
12351
|
+
* @param {BuildVisitors<Tree>} visitors
|
|
12352
|
+
* Handle each node when exiting it, and optionally when entering it.
|
|
12353
|
+
* @param {boolean | null | undefined} [reverse]
|
|
12354
|
+
* Walk children from last to first;
|
|
12355
|
+
* for `enter`, reverse preorder (NRL) instead of preorder (NLR);
|
|
12356
|
+
* for `exit`, reverse postorder (RLN) instead of postorder (LRN).
|
|
12357
|
+
* @returns {undefined}
|
|
12358
|
+
* Nothing.
|
|
12354
12359
|
*
|
|
12355
12360
|
* @param {UnistNode} tree
|
|
12356
12361
|
* Tree to traverse.
|
|
12357
|
-
* @param {Visitor | Test}
|
|
12358
|
-
* `unist-util-is`-compatible test
|
|
12359
|
-
* @param {Visitor | boolean | null | undefined} [
|
|
12360
|
-
*
|
|
12362
|
+
* @param {Visitor | Visitors | Test} testOrEnterOrVisitors
|
|
12363
|
+
* `unist-util-is`-compatible test, `enter`, or `visitors`.
|
|
12364
|
+
* @param {Visitor | Visitors | boolean | null | undefined} [enterOrVisitorsOrReverse]
|
|
12365
|
+
* `enter`, `visitors`, or `reverse` after a test.
|
|
12361
12366
|
* @param {boolean | null | undefined} [reverse]
|
|
12362
|
-
*
|
|
12367
|
+
* Walk children from last to first;
|
|
12368
|
+
* for `enter`, reverse preorder (NRL) instead of preorder (NLR);
|
|
12369
|
+
* for `exit`, reverse postorder (RLN) instead of postorder (LRN).
|
|
12363
12370
|
* @returns {undefined}
|
|
12364
12371
|
* Nothing.
|
|
12365
12372
|
*
|
|
@@ -12368,20 +12375,46 @@ window.__ModuleLoader__.load({
|
|
|
12368
12375
|
* @template {Test} Check
|
|
12369
12376
|
* `unist-util-is`-compatible test.
|
|
12370
12377
|
*/
|
|
12371
|
-
function visitParents(tree,
|
|
12378
|
+
function visitParents(tree, testOrEnterOrVisitors, enterOrVisitorsOrReverse, reverse) {
|
|
12379
|
+
if (!tree || typeof tree !== "object") throw new Error("Unexpected value `" + tree + "` for `tree`, expected node");
|
|
12380
|
+
let preorder = true;
|
|
12372
12381
|
/** @type {Test} */
|
|
12373
12382
|
let check;
|
|
12374
|
-
|
|
12375
|
-
|
|
12376
|
-
|
|
12377
|
-
|
|
12383
|
+
/** @type {Visitors | Visitor} */
|
|
12384
|
+
let visitors;
|
|
12385
|
+
/** @type {Visitor | null | undefined} */
|
|
12386
|
+
let enter;
|
|
12387
|
+
/** @type {VisitorExit | null | undefined} */
|
|
12388
|
+
let exit;
|
|
12389
|
+
if (typeof enterOrVisitorsOrReverse === "function" || enterOrVisitorsOrReverse && typeof enterOrVisitorsOrReverse === "object") {
|
|
12390
|
+
check = testOrEnterOrVisitors;
|
|
12391
|
+
visitors = enterOrVisitorsOrReverse;
|
|
12392
|
+
if (reverse) preorder = false;
|
|
12393
|
+
} else {
|
|
12394
|
+
visitors = testOrEnterOrVisitors;
|
|
12395
|
+
if (enterOrVisitorsOrReverse) preorder = false;
|
|
12396
|
+
}
|
|
12397
|
+
if (typeof visitors === "function") enter = visitors;
|
|
12398
|
+
else if (visitors && typeof visitors === "object") {
|
|
12399
|
+
if (visitors.enter === null || visitors.enter === void 0) {} else if (typeof visitors.enter === "function") enter = visitors.enter;
|
|
12400
|
+
else throw new Error("Unexpected value `" + visitors.enter + "` for `visitors.enter`, expected optional visitor");
|
|
12401
|
+
if (typeof visitors.exit === "function") exit = visitors.exit;
|
|
12402
|
+
else throw new Error("Unexpected value `" + visitors.exit + "` for `visitors.exit`, expected visitor (pass a visitor directly if you only want an enter visitor)");
|
|
12403
|
+
} else throw new Error("Unexpected value `" + visitors + "` for `enter` or `visitors`, expected visitor or object with visitors");
|
|
12378
12404
|
const is = convert(check);
|
|
12379
|
-
const step =
|
|
12405
|
+
const step = preorder ? 1 : -1;
|
|
12380
12406
|
factory(tree, void 0, [])();
|
|
12381
12407
|
/**
|
|
12408
|
+
* Create a function to visit a node.
|
|
12409
|
+
*
|
|
12382
12410
|
* @param {UnistNode} node
|
|
12411
|
+
* Node to visit.
|
|
12383
12412
|
* @param {number | undefined} index
|
|
12413
|
+
* Index of `node` in its parent.
|
|
12384
12414
|
* @param {Array<UnistParent>} parents
|
|
12415
|
+
* Ancestors of `node`.
|
|
12416
|
+
* @returns {() => Readonly<ActionTuple>}
|
|
12417
|
+
* Visit `node`.
|
|
12385
12418
|
*/
|
|
12386
12419
|
function factory(node, index, parents) {
|
|
12387
12420
|
const value = node && typeof node === "object" ? node : {};
|
|
@@ -12391,31 +12424,31 @@ window.__ModuleLoader__.load({
|
|
|
12391
12424
|
}
|
|
12392
12425
|
return visit;
|
|
12393
12426
|
function visit() {
|
|
12427
|
+
const matches = !check || is(node, index, parents[parents.length - 1] || void 0);
|
|
12394
12428
|
/** @type {Readonly<ActionTuple>} */
|
|
12395
12429
|
let result = empty;
|
|
12396
|
-
|
|
12397
|
-
|
|
12398
|
-
/** @type {number} */
|
|
12399
|
-
let offset;
|
|
12400
|
-
/** @type {Array<UnistParent>} */
|
|
12401
|
-
let grandparents;
|
|
12402
|
-
if (!test || is(node, index, parents[parents.length - 1] || void 0)) {
|
|
12403
|
-
result = toResult(visitor(node, parents));
|
|
12430
|
+
if (enter && matches) {
|
|
12431
|
+
result = toResult(enter(node, parents, index));
|
|
12404
12432
|
if (result[0] === false) return result;
|
|
12405
12433
|
}
|
|
12406
12434
|
if ("children" in node && node.children) {
|
|
12407
12435
|
const nodeAsParent = node;
|
|
12408
12436
|
if (nodeAsParent.children && result[0] !== "skip") {
|
|
12409
|
-
offset = (
|
|
12410
|
-
grandparents = parents
|
|
12437
|
+
let offset = (preorder ? -1 : nodeAsParent.children.length) + step;
|
|
12438
|
+
const grandparents = [...parents, nodeAsParent];
|
|
12411
12439
|
while (offset > -1 && offset < nodeAsParent.children.length) {
|
|
12412
12440
|
const child = nodeAsParent.children[offset];
|
|
12413
|
-
subresult = factory(child, offset, grandparents)();
|
|
12441
|
+
const subresult = factory(child, offset, grandparents)();
|
|
12414
12442
|
if (subresult[0] === false) return subresult;
|
|
12415
12443
|
offset = typeof subresult[1] === "number" ? subresult[1] : offset + step;
|
|
12416
12444
|
}
|
|
12417
12445
|
}
|
|
12418
12446
|
}
|
|
12447
|
+
if (exit && matches) {
|
|
12448
|
+
const exitResult = toResult(exit(node, parents, index));
|
|
12449
|
+
if (exitResult[0] === "skip") throw new Error("Unexpected value `" + exitResult[0] + "` from `exit`, expected `CONTINUE`, `EXIT`, index, or nothing");
|
|
12450
|
+
if (exitResult[0] === false || typeof exitResult[1] === "number") return exitResult;
|
|
12451
|
+
}
|
|
12419
12452
|
return result;
|
|
12420
12453
|
}
|
|
12421
12454
|
}
|
|
@@ -12433,8 +12466,7 @@ window.__ModuleLoader__.load({
|
|
|
12433
12466
|
if (typeof value === "number") return [true, value];
|
|
12434
12467
|
return value === null || value === void 0 ? empty : [value];
|
|
12435
12468
|
}
|
|
12436
|
-
|
|
12437
|
-
//#region ../../../node_modules/.pnpm/mdast-util-find-and-replace@3.0.3/node_modules/mdast-util-find-and-replace/lib/index.js
|
|
12469
|
+
// ../../../node_modules/.pnpm/mdast-util-find-and-replace@3.0.4/node_modules/mdast-util-find-and-replace/lib/index.js
|
|
12438
12470
|
/**
|
|
12439
12471
|
* @import {Nodes, Parents, PhrasingContent, Root, Text} from 'mdast'
|
|
12440
12472
|
* @import {BuildVisitor, Test, VisitorResult} from 'unist-util-visit-parents'
|
|
@@ -12502,7 +12534,7 @@ window.__ModuleLoader__.load({
|
|
|
12502
12534
|
* @param {FindAndReplaceList | FindAndReplaceTuple} list
|
|
12503
12535
|
* Patterns to find.
|
|
12504
12536
|
* @param {Options | null | undefined} [options]
|
|
12505
|
-
* Configuration (
|
|
12537
|
+
* Configuration (optional).
|
|
12506
12538
|
* @returns {undefined}
|
|
12507
12539
|
* Nothing.
|
|
12508
12540
|
*/
|
|
@@ -12510,24 +12542,15 @@ window.__ModuleLoader__.load({
|
|
|
12510
12542
|
const ignored = convert((options || {}).ignore || []);
|
|
12511
12543
|
const pairs = toPairs(list);
|
|
12512
12544
|
let pairIndex = -1;
|
|
12513
|
-
while (++pairIndex < pairs.length) visitParents(tree,
|
|
12545
|
+
while (++pairIndex < pairs.length) visitParents(tree, visitor);
|
|
12514
12546
|
/**
|
|
12515
|
-
*
|
|
12547
|
+
* Handle text nodes and skip ignored nodes.
|
|
12516
12548
|
*
|
|
12517
|
-
* @type {BuildVisitor<Root
|
|
12549
|
+
* @type {BuildVisitor<Root>}
|
|
12518
12550
|
*/
|
|
12519
|
-
function visitor(node, parents) {
|
|
12520
|
-
|
|
12521
|
-
|
|
12522
|
-
let grandparent;
|
|
12523
|
-
while (++index < parents.length) {
|
|
12524
|
-
const parent = parents[index];
|
|
12525
|
-
/** @type {Array<Nodes> | undefined} */
|
|
12526
|
-
const siblings = grandparent ? grandparent.children : void 0;
|
|
12527
|
-
if (ignored(parent, siblings ? siblings.indexOf(parent) : void 0, grandparent)) return;
|
|
12528
|
-
grandparent = parent;
|
|
12529
|
-
}
|
|
12530
|
-
if (grandparent) return handler(node, parents);
|
|
12551
|
+
function visitor(node, parents, index) {
|
|
12552
|
+
if (node.type === "text" && typeof index === "number") return handler(node, parents, index);
|
|
12553
|
+
if (ignored(node, index, parents[parents.length - 1])) return SKIP;
|
|
12531
12554
|
}
|
|
12532
12555
|
/**
|
|
12533
12556
|
* Handle a text node which is not in an ignored parent.
|
|
@@ -12536,15 +12559,16 @@ window.__ModuleLoader__.load({
|
|
|
12536
12559
|
* Text node to search in.
|
|
12537
12560
|
* @param {Array<Parents>} parents
|
|
12538
12561
|
* Ancestors of `node`.
|
|
12562
|
+
* @param {number} index
|
|
12563
|
+
* Index of `node` in its parent.
|
|
12539
12564
|
* @returns {VisitorResult}
|
|
12540
12565
|
* Where to continue visiting.
|
|
12541
12566
|
*/
|
|
12542
|
-
function handler(node, parents) {
|
|
12567
|
+
function handler(node, parents, index) {
|
|
12543
12568
|
const parent = parents[parents.length - 1];
|
|
12544
12569
|
const find = pairs[pairIndex][0];
|
|
12545
12570
|
const replace = pairs[pairIndex][1];
|
|
12546
12571
|
let start = 0;
|
|
12547
|
-
const index = parent.children.indexOf(node);
|
|
12548
12572
|
let change = false;
|
|
12549
12573
|
/** @type {Array<PhrasingContent>} */
|
|
12550
12574
|
let nodes = [];
|
|
@@ -12612,7 +12636,6 @@ window.__ModuleLoader__.load({
|
|
|
12612
12636
|
if (!Array.isArray(tupleOrList)) throw new TypeError("Expected find and replace tuple or list of tuples");
|
|
12613
12637
|
/** @type {Pairs} */
|
|
12614
12638
|
const result = [];
|
|
12615
|
-
/** @type {FindAndReplaceList} */
|
|
12616
12639
|
const list = !tupleOrList[0] || Array.isArray(tupleOrList[0]) ? tupleOrList : [tupleOrList];
|
|
12617
12640
|
let index = -1;
|
|
12618
12641
|
while (++index < list.length) {
|
|
@@ -12645,8 +12668,7 @@ window.__ModuleLoader__.load({
|
|
|
12645
12668
|
return replace;
|
|
12646
12669
|
};
|
|
12647
12670
|
}
|
|
12648
|
-
|
|
12649
|
-
//#region ../../../node_modules/.pnpm/mdast-util-gfm-autolink-literal@2.0.1/node_modules/mdast-util-gfm-autolink-literal/lib/index.js
|
|
12671
|
+
// ../../../node_modules/.pnpm/mdast-util-gfm-autolink-literal@2.0.1_patch_hash=7fa6fc7927128a45c3f148d31faf388806895e2de39c14a144200edbc1e7aaa0/node_modules/mdast-util-gfm-autolink-literal/lib/index.js
|
|
12650
12672
|
/**
|
|
12651
12673
|
* @import {RegExpMatchObject, ReplaceFunction} from 'mdast-util-find-and-replace'
|
|
12652
12674
|
* @import {CompileContext, Extension as FromMarkdownExtension, Handle as FromMarkdownHandle, Transform as FromMarkdownTransform} from 'mdast-util-from-markdown'
|
|
@@ -12729,7 +12751,7 @@ window.__ModuleLoader__.load({
|
|
|
12729
12751
|
}
|
|
12730
12752
|
/** @type {FromMarkdownTransform} */
|
|
12731
12753
|
function transformGfmAutolinkLiterals(tree) {
|
|
12732
|
-
findAndReplace(tree, [[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/
|
|
12754
|
+
findAndReplace(tree, [[/(https?:\/\/|www(?=\.))([-.\w]+)((?:[!-~]|(?![\p{P}\p{S}\s])[^ \t\r\n])*)/giu, findUrl], [/(?<=^|\s|\p{P}|\p{S})([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/gu, findEmail]], { ignore: ["link", "linkReference"] });
|
|
12733
12755
|
}
|
|
12734
12756
|
/**
|
|
12735
12757
|
* @type {ReplaceFunction}
|
|
@@ -12825,8 +12847,7 @@ window.__ModuleLoader__.load({
|
|
|
12825
12847
|
const code = match.input.charCodeAt(match.index - 1);
|
|
12826
12848
|
return (match.index === 0 || unicodeWhitespace(code) || unicodePunctuation(code)) && (!email || code !== 47);
|
|
12827
12849
|
}
|
|
12828
|
-
|
|
12829
|
-
//#region ../../../node_modules/.pnpm/mdast-util-gfm-footnote@2.1.0_supports-color@9.4.0/node_modules/mdast-util-gfm-footnote/lib/index.js
|
|
12850
|
+
// ../../../node_modules/.pnpm/mdast-util-gfm-footnote@2.1.0_supports-color@9.4.0/node_modules/mdast-util-gfm-footnote/lib/index.js
|
|
12830
12851
|
/**
|
|
12831
12852
|
* @import {
|
|
12832
12853
|
* CompileContext,
|
|
@@ -12960,8 +12981,7 @@ window.__ModuleLoader__.load({
|
|
|
12960
12981
|
}
|
|
12961
12982
|
};
|
|
12962
12983
|
}
|
|
12963
|
-
|
|
12964
|
-
//#region ../../../node_modules/.pnpm/mdast-util-gfm-strikethrough@2.0.1_supports-color@9.4.0/node_modules/mdast-util-gfm-strikethrough/lib/index.js
|
|
12984
|
+
// ../../../node_modules/.pnpm/mdast-util-gfm-strikethrough@2.0.1_supports-color@9.4.0/node_modules/mdast-util-gfm-strikethrough/lib/index.js
|
|
12965
12985
|
handleDelete.attention = attentionDelete;
|
|
12966
12986
|
handleDelete.peek = peekDelete;
|
|
12967
12987
|
/**
|
|
@@ -13061,8 +13081,7 @@ window.__ModuleLoader__.load({
|
|
|
13061
13081
|
]);
|
|
13062
13082
|
({}).hasOwnProperty;
|
|
13063
13083
|
({}).hasOwnProperty;
|
|
13064
|
-
|
|
13065
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/util/check-quote.js
|
|
13084
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/util/check-quote.js
|
|
13066
13085
|
/**
|
|
13067
13086
|
* @import {Options, State} from 'mdast-util-to-markdown'
|
|
13068
13087
|
*/
|
|
@@ -13079,8 +13098,7 @@ window.__ModuleLoader__.load({
|
|
|
13079
13098
|
if (marker !== "\"" && marker !== "'") throw new Error("Cannot serialize title with `" + marker + "` for `options.quote`, expected `\"`, or `'`");
|
|
13080
13099
|
return marker;
|
|
13081
13100
|
}
|
|
13082
|
-
|
|
13083
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/util/check-emphasis.js
|
|
13101
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/util/check-emphasis.js
|
|
13084
13102
|
/**
|
|
13085
13103
|
* @import {Options, State} from 'mdast-util-to-markdown'
|
|
13086
13104
|
*/
|
|
@@ -13097,8 +13115,674 @@ window.__ModuleLoader__.load({
|
|
|
13097
13115
|
if (marker !== "*" && marker !== "_") throw new Error("Cannot serialize emphasis with `" + marker + "` for `options.emphasis`, expected `*`, or `_`");
|
|
13098
13116
|
return marker;
|
|
13099
13117
|
}
|
|
13100
|
-
|
|
13101
|
-
|
|
13118
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/util/character.js
|
|
13119
|
+
/**
|
|
13120
|
+
* Get the first character of a value.
|
|
13121
|
+
*
|
|
13122
|
+
* Is aware of astral characters (such as emoji).
|
|
13123
|
+
*
|
|
13124
|
+
* @param {string} value
|
|
13125
|
+
* Value.
|
|
13126
|
+
* @returns {string}
|
|
13127
|
+
* First character; empty if `value` is empty.
|
|
13128
|
+
*/
|
|
13129
|
+
function firstCharacter(value) {
|
|
13130
|
+
const code = value.codePointAt(0);
|
|
13131
|
+
return code === void 0 ? "" : String.fromCodePoint(code);
|
|
13132
|
+
}
|
|
13133
|
+
/**
|
|
13134
|
+
* Get the last character of a value.
|
|
13135
|
+
*
|
|
13136
|
+
* Is aware of astral characters (such as emoji).
|
|
13137
|
+
*
|
|
13138
|
+
* @param {string} value
|
|
13139
|
+
* Value.
|
|
13140
|
+
* @returns {string}
|
|
13141
|
+
* Last character; empty if `value` is empty.
|
|
13142
|
+
*/
|
|
13143
|
+
function lastCharacter(value) {
|
|
13144
|
+
const code = value.codePointAt(value.length - 2);
|
|
13145
|
+
return code !== void 0 && code > 65535 ? value.slice(-2) : value.slice(-1);
|
|
13146
|
+
}
|
|
13147
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/util/encode-character-reference.js
|
|
13148
|
+
/**
|
|
13149
|
+
* Encode a code point as a character reference.
|
|
13150
|
+
*
|
|
13151
|
+
* @param {number} code
|
|
13152
|
+
* Code point to encode.
|
|
13153
|
+
* @returns {string}
|
|
13154
|
+
* Encoded character reference.
|
|
13155
|
+
*/
|
|
13156
|
+
function encodeCharacterReference(code) {
|
|
13157
|
+
return "&#x" + code.toString(16).toUpperCase() + ";";
|
|
13158
|
+
}
|
|
13159
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/util/encode-info.js
|
|
13160
|
+
/**
|
|
13161
|
+
* @import {EncodeSides} from '../types.js'
|
|
13162
|
+
*/
|
|
13163
|
+
/**
|
|
13164
|
+
* Check whether to encode (as a character reference) the characters
|
|
13165
|
+
* surrounding an attention run.
|
|
13166
|
+
*
|
|
13167
|
+
* Which characters are around an attention run influence whether it works or
|
|
13168
|
+
* not.
|
|
13169
|
+
*
|
|
13170
|
+
* See <https://github.com/orgs/syntax-tree/discussions/60> for more info.
|
|
13171
|
+
* See this markdown in a particular renderer to see what works:
|
|
13172
|
+
*
|
|
13173
|
+
* ```markdown
|
|
13174
|
+
* | | A (letter inside) | B (punctuation inside) | C (whitespace inside) | D (nothing inside) |
|
|
13175
|
+
* | ----------------------- | ----------------- | ---------------------- | --------------------- | ------------------ |
|
|
13176
|
+
* | 1 (letter outside) | x*y*z | x*.*z | x* *z | x**z |
|
|
13177
|
+
* | 2 (punctuation outside) | .*y*. | .*.*. | .* *. | .**. |
|
|
13178
|
+
* | 3 (whitespace outside) | x *y* z | x *.* z | x * * z | x ** z |
|
|
13179
|
+
* | 4 (nothing outside) | *x* | *.* | * * | ** |
|
|
13180
|
+
* ```
|
|
13181
|
+
*
|
|
13182
|
+
* @param {number} outside
|
|
13183
|
+
* Code point on the outer side of the run.
|
|
13184
|
+
* @param {number} inside
|
|
13185
|
+
* Code point on the inner side of the run.
|
|
13186
|
+
* @param {string} marker
|
|
13187
|
+
* Marker of the run.
|
|
13188
|
+
* Underscores are handled more strictly (they form less often) than
|
|
13189
|
+
* asterisks.
|
|
13190
|
+
* @returns {EncodeSides}
|
|
13191
|
+
* Whether to encode characters.
|
|
13192
|
+
*/
|
|
13193
|
+
function encodeInfo(outside, inside, marker) {
|
|
13194
|
+
const outsideKind = classifyCharacter(outside);
|
|
13195
|
+
const insideKind = classifyCharacter(inside);
|
|
13196
|
+
if (outsideKind === void 0) return insideKind === void 0 ? marker === "_" ? {
|
|
13197
|
+
inside: true,
|
|
13198
|
+
outside: true
|
|
13199
|
+
} : {
|
|
13200
|
+
inside: false,
|
|
13201
|
+
outside: false
|
|
13202
|
+
} : insideKind === 1 ? {
|
|
13203
|
+
inside: true,
|
|
13204
|
+
outside: true
|
|
13205
|
+
} : {
|
|
13206
|
+
inside: false,
|
|
13207
|
+
outside: true
|
|
13208
|
+
};
|
|
13209
|
+
if (outsideKind === 1) return insideKind === void 0 ? {
|
|
13210
|
+
inside: false,
|
|
13211
|
+
outside: false
|
|
13212
|
+
} : insideKind === 1 ? {
|
|
13213
|
+
inside: true,
|
|
13214
|
+
outside: true
|
|
13215
|
+
} : {
|
|
13216
|
+
inside: false,
|
|
13217
|
+
outside: false
|
|
13218
|
+
};
|
|
13219
|
+
return insideKind === void 0 ? {
|
|
13220
|
+
inside: false,
|
|
13221
|
+
outside: false
|
|
13222
|
+
} : insideKind === 1 ? {
|
|
13223
|
+
inside: true,
|
|
13224
|
+
outside: false
|
|
13225
|
+
} : {
|
|
13226
|
+
inside: false,
|
|
13227
|
+
outside: false
|
|
13228
|
+
};
|
|
13229
|
+
}
|
|
13230
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/util/html-kind.js
|
|
13231
|
+
/**
|
|
13232
|
+
* @typedef {1 | 2 | 3 | 4 | 5 | 6 | 7} Kind
|
|
13233
|
+
* Kind of HTML (flow) element.
|
|
13234
|
+
*/
|
|
13235
|
+
/**
|
|
13236
|
+
* Infer the kind of HTML that `value` is.
|
|
13237
|
+
*
|
|
13238
|
+
* This works on valid trees as produced by `micromark`.
|
|
13239
|
+
* Kinds:
|
|
13240
|
+
*
|
|
13241
|
+
* 1. raw
|
|
13242
|
+
* 2. comment
|
|
13243
|
+
* 3. instruction
|
|
13244
|
+
* 4. declaration
|
|
13245
|
+
* 5. cdata
|
|
13246
|
+
* 6. block
|
|
13247
|
+
* 7. other
|
|
13248
|
+
*
|
|
13249
|
+
* See: <https://spec.commonmark.org/0.31.2/#html-blocks>.
|
|
13250
|
+
*
|
|
13251
|
+
* @param {string} value
|
|
13252
|
+
* HTML.
|
|
13253
|
+
* @returns {Kind | undefined}
|
|
13254
|
+
* Kind; `undefined` if unknown.
|
|
13255
|
+
*/
|
|
13256
|
+
function htmlKind(value) {
|
|
13257
|
+
if (value.charCodeAt(0) !== 60) return;
|
|
13258
|
+
const next = value.charCodeAt(1);
|
|
13259
|
+
if (next === 33) {
|
|
13260
|
+
const code = value.charCodeAt(2);
|
|
13261
|
+
if (code === 45) return 2;
|
|
13262
|
+
if (code === 91) return 5;
|
|
13263
|
+
if (asciiAlpha(code)) return 4;
|
|
13264
|
+
return;
|
|
13265
|
+
}
|
|
13266
|
+
if (next === 63) return 3;
|
|
13267
|
+
const closing = next === 47;
|
|
13268
|
+
const start = closing ? 2 : 1;
|
|
13269
|
+
let end = start;
|
|
13270
|
+
let code = value.charCodeAt(end);
|
|
13271
|
+
if (!asciiAlpha(code)) return;
|
|
13272
|
+
while (code === 45 || asciiAlphanumeric(code)) code = value.charCodeAt(++end);
|
|
13273
|
+
const name = value.slice(start, end).toLowerCase();
|
|
13274
|
+
if (!closing && code !== 47 && htmlRawNames.includes(name)) return 1;
|
|
13275
|
+
return htmlBlockNames.includes(name) ? 6 : 7;
|
|
13276
|
+
}
|
|
13277
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/util/container-phrasing.js
|
|
13278
|
+
/**
|
|
13279
|
+
* @import {Attention, Handle, Info, State, Tracker} from 'mdast-util-to-markdown'
|
|
13280
|
+
* @import {PhrasingParents} from '../types.js'
|
|
13281
|
+
*/
|
|
13282
|
+
/**
|
|
13283
|
+
* Markers for builtin attention (emphasis, strong) to whether they are stricter:
|
|
13284
|
+
* whether they cannot open and close inside words.
|
|
13285
|
+
*
|
|
13286
|
+
* Builtin runs pair following CommonMark rules for emphasis and strong:
|
|
13287
|
+
* they are split,
|
|
13288
|
+
* using one or two markers at a time,
|
|
13289
|
+
* with the rule of 3.
|
|
13290
|
+
* Other markers pair like GFM strikethrough:
|
|
13291
|
+
* whole runs pair with a run of the same size.
|
|
13292
|
+
*
|
|
13293
|
+
* @type {Map<string, boolean>}
|
|
13294
|
+
*/
|
|
13295
|
+
const builtins = /* @__PURE__ */ new Map([["*", false], ["_", true]]);
|
|
13296
|
+
/**
|
|
13297
|
+
* @typedef AttentionResult
|
|
13298
|
+
* Attention, of which the sequence is chosen later.
|
|
13299
|
+
* @property {Array<Item>} children
|
|
13300
|
+
* Serialized children.
|
|
13301
|
+
* @property {Array<string>} sequences
|
|
13302
|
+
* Sequences that can be used, in order of preference.
|
|
13303
|
+
*/
|
|
13304
|
+
/**
|
|
13305
|
+
* @typedef Improvement
|
|
13306
|
+
* Improvement of attention sequences.
|
|
13307
|
+
* @property {Map<AttentionResult, string>} chosen
|
|
13308
|
+
* Chosen sequences for each attention.
|
|
13309
|
+
* @property {Array<Token>} tokens
|
|
13310
|
+
* Tokens involved in the improvement.
|
|
13311
|
+
* @property {Mistake | undefined} mistake
|
|
13312
|
+
* Mistake that led to this improvement, if any.
|
|
13313
|
+
*/
|
|
13314
|
+
/**
|
|
13315
|
+
* @typedef {AttentionResult | string} Item
|
|
13316
|
+
* Serialized phrasing.
|
|
13317
|
+
*/
|
|
13318
|
+
/**
|
|
13319
|
+
* @typedef Mistake
|
|
13320
|
+
* Sequence that does not form its attention.
|
|
13321
|
+
* @property {Array<AttentionResult>} attention
|
|
13322
|
+
* Attention to try other sequences for.
|
|
13323
|
+
* @property {number} index
|
|
13324
|
+
* Index of the token.
|
|
13325
|
+
*/
|
|
13326
|
+
/**
|
|
13327
|
+
* @typedef Run
|
|
13328
|
+
* Sequences next to each other with the same marker.
|
|
13329
|
+
* @property {boolean} close
|
|
13330
|
+
* Whether it can close.
|
|
13331
|
+
* @property {number} end
|
|
13332
|
+
* Index after the last marker not used (to open).
|
|
13333
|
+
* @property {Array<Token>} markers
|
|
13334
|
+
* Sequence of each marker.
|
|
13335
|
+
* @property {boolean} open
|
|
13336
|
+
* Whether it can open.
|
|
13337
|
+
* @property {boolean} split
|
|
13338
|
+
* Whether it can be split (built-in attention).
|
|
13339
|
+
* @property {number} start
|
|
13340
|
+
* Index of the first marker not used (to close).
|
|
13341
|
+
* @property {Array<Token>} tokens
|
|
13342
|
+
* Sequences.
|
|
13343
|
+
*/
|
|
13344
|
+
/**
|
|
13345
|
+
* @typedef Token
|
|
13346
|
+
* Rendered phrasing.
|
|
13347
|
+
* @property {AttentionResult | undefined} attention
|
|
13348
|
+
* Attention, if this is one of its sequences.
|
|
13349
|
+
* @property {string} value
|
|
13350
|
+
* Value.
|
|
13351
|
+
*/
|
|
13352
|
+
/**
|
|
13353
|
+
* Get candidates for a mistake:
|
|
13354
|
+
* attention to try other sequences for,
|
|
13355
|
+
* later first.
|
|
13356
|
+
*
|
|
13357
|
+
* @param {Array<Token>} tokens
|
|
13358
|
+
* Tokens.
|
|
13359
|
+
* @param {Array<Token>} involved
|
|
13360
|
+
* Sequences involved in the mistake.
|
|
13361
|
+
* @param {Map<Token, Run>} runOf
|
|
13362
|
+
* Run of each sequence.
|
|
13363
|
+
* @returns {Array<AttentionResult>}
|
|
13364
|
+
* Candidates.
|
|
13365
|
+
*/
|
|
13366
|
+
function candidates(tokens, involved, runOf) {
|
|
13367
|
+
/** @type {Set<AttentionResult | undefined>} */
|
|
13368
|
+
const related = /* @__PURE__ */ new Set();
|
|
13369
|
+
for (const token of tokens) {
|
|
13370
|
+
const siblings = runOf.get(token);
|
|
13371
|
+
if (siblings && token.attention && involved.some((d) => d.attention === token.attention)) for (const sibling of siblings.tokens) related.add(sibling.attention);
|
|
13372
|
+
}
|
|
13373
|
+
/** @type {Array<AttentionResult>} */
|
|
13374
|
+
const ordered = [];
|
|
13375
|
+
for (const token of tokens) if (token.attention && related.delete(token.attention)) ordered.push(token.attention);
|
|
13376
|
+
ordered.reverse();
|
|
13377
|
+
return ordered;
|
|
13378
|
+
}
|
|
13379
|
+
/**
|
|
13380
|
+
* Check whether sequences form their attention, like `micromark`.
|
|
13381
|
+
*
|
|
13382
|
+
* Sequences of `*` and `_` pair like emphasis and strong in CommonMark,
|
|
13383
|
+
* others like strikethrough in GFM.
|
|
13384
|
+
*
|
|
13385
|
+
* @param {Array<Token>} tokens
|
|
13386
|
+
* Tokens.
|
|
13387
|
+
* @param {string} before
|
|
13388
|
+
* Characters before.
|
|
13389
|
+
* @param {string} after
|
|
13390
|
+
* Characters after.
|
|
13391
|
+
* @returns {Mistake | undefined}
|
|
13392
|
+
* First mistake, if any.
|
|
13393
|
+
*/
|
|
13394
|
+
function check(tokens, before, after) {
|
|
13395
|
+
/** @type {Array<Run>} */
|
|
13396
|
+
const runs = [];
|
|
13397
|
+
/** @type {Map<Token, Array<Token>>} */
|
|
13398
|
+
const wrong = /* @__PURE__ */ new Map();
|
|
13399
|
+
/** @type {Map<Token, Run>} */
|
|
13400
|
+
const runOf = /* @__PURE__ */ new Map();
|
|
13401
|
+
let index = 0;
|
|
13402
|
+
while (index < tokens.length) {
|
|
13403
|
+
if (!tokens[index].attention) {
|
|
13404
|
+
index++;
|
|
13405
|
+
continue;
|
|
13406
|
+
}
|
|
13407
|
+
const marker = tokens[index].value.charAt(0);
|
|
13408
|
+
const strict = builtins.get(marker);
|
|
13409
|
+
let end = index + 1;
|
|
13410
|
+
while (end < tokens.length && tokens[end].attention && tokens[end].value.charAt(0) === marker) end++;
|
|
13411
|
+
const head = index ? tokens[index - 1].value : before;
|
|
13412
|
+
const previous = classifyCharacter(head.charCodeAt(head.length - 1));
|
|
13413
|
+
const next = classifyCharacter((end < tokens.length ? tokens[end].value : after).charCodeAt(0));
|
|
13414
|
+
const open = !next || next === 2 && Boolean(previous);
|
|
13415
|
+
const close = !previous || previous === 2 && Boolean(next);
|
|
13416
|
+
/** @type {Run} */
|
|
13417
|
+
const run = {
|
|
13418
|
+
tokens: tokens.slice(index, end),
|
|
13419
|
+
markers: [],
|
|
13420
|
+
start: 0,
|
|
13421
|
+
end: 0,
|
|
13422
|
+
open: strict ? open && (Boolean(previous) || !close) : open,
|
|
13423
|
+
close: strict ? close && (Boolean(next) || !open) : close,
|
|
13424
|
+
split: strict !== void 0
|
|
13425
|
+
};
|
|
13426
|
+
for (const token of run.tokens) {
|
|
13427
|
+
wrong.set(token, [...run.tokens]);
|
|
13428
|
+
runOf.set(token, run);
|
|
13429
|
+
let size = token.value.length;
|
|
13430
|
+
while (size--) run.markers.push(token);
|
|
13431
|
+
}
|
|
13432
|
+
run.end = run.markers.length;
|
|
13433
|
+
runs.push(run);
|
|
13434
|
+
index = end;
|
|
13435
|
+
}
|
|
13436
|
+
pair(runs, wrong);
|
|
13437
|
+
index = -1;
|
|
13438
|
+
while (++index < tokens.length) {
|
|
13439
|
+
const involved = wrong.get(tokens[index]);
|
|
13440
|
+
if (involved) return {
|
|
13441
|
+
attention: candidates(tokens, involved, runOf),
|
|
13442
|
+
index
|
|
13443
|
+
};
|
|
13444
|
+
}
|
|
13445
|
+
}
|
|
13446
|
+
/**
|
|
13447
|
+
* Encode the first or last character of tokens as a character reference,
|
|
13448
|
+
* if it is text.
|
|
13449
|
+
*
|
|
13450
|
+
* @param {Array<Token>} tokens
|
|
13451
|
+
* Tokens.
|
|
13452
|
+
* @param {boolean} start
|
|
13453
|
+
* Whether to encode the first or last character.
|
|
13454
|
+
* @returns {undefined}
|
|
13455
|
+
* Nothing.
|
|
13456
|
+
*/
|
|
13457
|
+
function encode(tokens, start) {
|
|
13458
|
+
const token = tokens[start ? 0 : tokens.length - 1];
|
|
13459
|
+
if (!token || token.attention) return;
|
|
13460
|
+
const character = start ? firstCharacter(token.value) : lastCharacter(token.value);
|
|
13461
|
+
const reference = encodeCharacterReference(character.codePointAt(0));
|
|
13462
|
+
if (start) token.value = reference + token.value.slice(character.length);
|
|
13463
|
+
else {
|
|
13464
|
+
let value = token.value.slice(0, token.value.length - character.length);
|
|
13465
|
+
let escapes = 0;
|
|
13466
|
+
while (value.charCodeAt(value.length - 1 - escapes) === 92) escapes++;
|
|
13467
|
+
if (escapes % 2) value += "\\";
|
|
13468
|
+
token.value = value + reference;
|
|
13469
|
+
}
|
|
13470
|
+
}
|
|
13471
|
+
/**
|
|
13472
|
+
* Try other sequences for the candidates of a mistake and use the first that
|
|
13473
|
+
* moves the mistake further.
|
|
13474
|
+
*
|
|
13475
|
+
* @param {Array<Item>} items
|
|
13476
|
+
* Items.
|
|
13477
|
+
* @param {Map<AttentionResult, string>} chosen
|
|
13478
|
+
* Sequences to use instead of preferred sequences.
|
|
13479
|
+
* @param {Mistake} mistake
|
|
13480
|
+
* Mistake.
|
|
13481
|
+
* @param {string} before
|
|
13482
|
+
* Characters before.
|
|
13483
|
+
* @param {string} after
|
|
13484
|
+
* Characters after.
|
|
13485
|
+
* @returns {Improvement | undefined}
|
|
13486
|
+
* Result if better.
|
|
13487
|
+
*/
|
|
13488
|
+
function improve(items, chosen, mistake, before, after) {
|
|
13489
|
+
for (const attention of mistake.attention) {
|
|
13490
|
+
const current = chosen.get(attention) || attention.sequences[0];
|
|
13491
|
+
for (const sequence of attention.sequences) {
|
|
13492
|
+
if (sequence === current) continue;
|
|
13493
|
+
const trial = new Map(chosen);
|
|
13494
|
+
trial.set(attention, sequence);
|
|
13495
|
+
const tokens = render(items, trial, before, after);
|
|
13496
|
+
const next = check(tokens, before, after);
|
|
13497
|
+
if (!next || next.index > mistake.index) return {
|
|
13498
|
+
chosen: trial,
|
|
13499
|
+
mistake: next,
|
|
13500
|
+
tokens
|
|
13501
|
+
};
|
|
13502
|
+
}
|
|
13503
|
+
}
|
|
13504
|
+
}
|
|
13505
|
+
/**
|
|
13506
|
+
* Pair runs like `micromark` and mark sequences that do form their attention
|
|
13507
|
+
* as fine.
|
|
13508
|
+
*
|
|
13509
|
+
* Each pair uses markers from the end of an opener and the start of a closer.
|
|
13510
|
+
* It forms the intended attention if those markers are exactly the whole
|
|
13511
|
+
* opening and closing sequence of one attention.
|
|
13512
|
+
* Otherwise attention is mixed up:
|
|
13513
|
+
* either sequences of different attention pair,
|
|
13514
|
+
* part of a sequence is used (such as `**` of strong as `*`),
|
|
13515
|
+
* or several sequences are used together (such as `*` and `*` as `**`).
|
|
13516
|
+
* Then the sequences involved are recorded with each other.
|
|
13517
|
+
*
|
|
13518
|
+
* @param {Array<Run>} runs
|
|
13519
|
+
* Runs.
|
|
13520
|
+
* @param {Map<Token, Array<Token>>} wrong
|
|
13521
|
+
* Sequences that are wrong, with the sequences involved.
|
|
13522
|
+
* @returns {undefined}
|
|
13523
|
+
* Nothing, `wrong` is changed.
|
|
13524
|
+
*/
|
|
13525
|
+
function pair(runs, wrong) {
|
|
13526
|
+
/** @type {Map<string, Array<Run>>} */
|
|
13527
|
+
const openersByMarker = /* @__PURE__ */ new Map();
|
|
13528
|
+
for (const closer of runs) {
|
|
13529
|
+
const marker = closer.tokens[0].value.charAt(0);
|
|
13530
|
+
let openers = openersByMarker.get(marker);
|
|
13531
|
+
if (!openers) {
|
|
13532
|
+
openers = [];
|
|
13533
|
+
openersByMarker.set(marker, openers);
|
|
13534
|
+
}
|
|
13535
|
+
let open = closer.close ? openers.length : 0;
|
|
13536
|
+
while (open-- && closer.start < closer.end) {
|
|
13537
|
+
const opener = openers[open];
|
|
13538
|
+
const openerSize = opener.end - opener.start;
|
|
13539
|
+
const closerSize = closer.end - closer.start;
|
|
13540
|
+
if (closer.split ? (opener.close || closer.open) && closerSize % 3 && !((openerSize + closerSize) % 3) : openerSize !== opener.markers.length || openerSize !== closerSize) continue;
|
|
13541
|
+
const size = closer.split ? openerSize > 1 && closerSize > 1 ? 2 : 1 : closerSize;
|
|
13542
|
+
const opening = opener.markers.slice(opener.end - size, opener.end);
|
|
13543
|
+
const closing = closer.markers.slice(closer.start, closer.start + size);
|
|
13544
|
+
const openToken = opening[0];
|
|
13545
|
+
const closeToken = closing[0];
|
|
13546
|
+
if (openToken === opening[size - 1] && openToken.value.length === size && closeToken === closing[size - 1] && closeToken.value.length === size && openToken.attention === closeToken.attention) {
|
|
13547
|
+
wrong.delete(openToken);
|
|
13548
|
+
wrong.delete(closeToken);
|
|
13549
|
+
} else {
|
|
13550
|
+
const involved = [.../* @__PURE__ */ new Set([...opening, ...closing])];
|
|
13551
|
+
for (const token of involved) {
|
|
13552
|
+
const list = wrong.get(token);
|
|
13553
|
+
if (list) list.push(...involved);
|
|
13554
|
+
}
|
|
13555
|
+
}
|
|
13556
|
+
opener.end -= size;
|
|
13557
|
+
closer.start += size;
|
|
13558
|
+
if (opener.start === opener.end) openers.splice(open, 1);
|
|
13559
|
+
open = openers.length;
|
|
13560
|
+
}
|
|
13561
|
+
if (closer.open && closer.start < closer.end) openers.push(closer);
|
|
13562
|
+
}
|
|
13563
|
+
}
|
|
13564
|
+
/**
|
|
13565
|
+
* Get the sequences that can be used for attention, in order of preference.
|
|
13566
|
+
*
|
|
13567
|
+
* @param {string} type
|
|
13568
|
+
* Node type.
|
|
13569
|
+
* @param {Array<string>} markers
|
|
13570
|
+
* Markers.
|
|
13571
|
+
* @param {Array<number>} sizes
|
|
13572
|
+
* Sizes.
|
|
13573
|
+
* @returns {Array<string>}
|
|
13574
|
+
* Sequences.
|
|
13575
|
+
*/
|
|
13576
|
+
function attentionSequences(type, markers, sizes) {
|
|
13577
|
+
if (markers.length === 0) throw new Error("Cannot serialize `" + type + "` as attention without markers, expected one or more markers");
|
|
13578
|
+
if (sizes.length === 0) throw new Error("Cannot serialize `" + type + "` as attention without sizes, expected one or more sizes");
|
|
13579
|
+
for (const size of sizes) if (!Number.isSafeInteger(size) || size < 1) throw new Error("Cannot serialize `" + type + "` as attention with `" + size + "` as size, expected positive integer");
|
|
13580
|
+
/** @type {Array<string>} */
|
|
13581
|
+
const sequences = [];
|
|
13582
|
+
for (const marker of markers) {
|
|
13583
|
+
if (marker.length !== 1) throw new Error("Cannot serialize `" + type + "` as attention with `" + marker + "` as marker, expected a single ascii character");
|
|
13584
|
+
if (!asciiPunctuation(marker.charCodeAt(0))) throw new Error("Cannot serialize `" + type + "` as attention with `" + marker + "` as marker, expected ascii punctuation");
|
|
13585
|
+
for (const size of sizes) sequences.push(marker.repeat(size));
|
|
13586
|
+
}
|
|
13587
|
+
return sequences;
|
|
13588
|
+
}
|
|
13589
|
+
/**
|
|
13590
|
+
* Serialize the children of a parent that contains phrasing children,
|
|
13591
|
+
* keeping attention separate,
|
|
13592
|
+
* so that its markers can be chosen later.
|
|
13593
|
+
*
|
|
13594
|
+
* @param {PhrasingParents} parent
|
|
13595
|
+
* Parent of phrasing nodes.
|
|
13596
|
+
* @param {State} state
|
|
13597
|
+
* Info passed around about the current state.
|
|
13598
|
+
* @param {Info} info
|
|
13599
|
+
* Info on where we are in the document we are generating.
|
|
13600
|
+
* @returns {Array<Item>}
|
|
13601
|
+
* Items.
|
|
13602
|
+
*/
|
|
13603
|
+
function phrasing(parent, state, info) {
|
|
13604
|
+
const indexStack = state.indexStack;
|
|
13605
|
+
const children = parent.children || [];
|
|
13606
|
+
/** @type {Array<Item>} */
|
|
13607
|
+
const results = [];
|
|
13608
|
+
let index = -1;
|
|
13609
|
+
let before = info.before;
|
|
13610
|
+
indexStack.push(-1);
|
|
13611
|
+
let tracker = state.createTracker(info);
|
|
13612
|
+
while (++index < children.length) {
|
|
13613
|
+
const child = children[index];
|
|
13614
|
+
/** @type {string} */
|
|
13615
|
+
let after;
|
|
13616
|
+
indexStack[indexStack.length - 1] = index;
|
|
13617
|
+
if (index + 1 < children.length) {
|
|
13618
|
+
/** @type {Handle} */
|
|
13619
|
+
let handle = state.handle.handlers[children[index + 1].type];
|
|
13620
|
+
if (handle && handle.peek) handle = handle.peek;
|
|
13621
|
+
after = handle ? firstCharacter(handle(children[index + 1], parent, state, {
|
|
13622
|
+
before: "",
|
|
13623
|
+
after: "",
|
|
13624
|
+
...tracker.current()
|
|
13625
|
+
})) : "";
|
|
13626
|
+
} else after = info.after;
|
|
13627
|
+
const previous = results[results.length - 1];
|
|
13628
|
+
if (typeof previous === "string" && (before === "\r" || before === "\n") && child.type === "html" && htmlKind(child.value) !== 7) {
|
|
13629
|
+
results[results.length - 1] = previous.replace(/(\r?\n|\r)$/, " ");
|
|
13630
|
+
before = " ";
|
|
13631
|
+
tracker = state.createTracker(info);
|
|
13632
|
+
tracker.move(serialize(results, info.before, info.after));
|
|
13633
|
+
}
|
|
13634
|
+
/** @type {(Handle & {attention?: Attention | undefined}) | undefined} */
|
|
13635
|
+
const handle = state.handle.handlers[child.type];
|
|
13636
|
+
if (handle && handle.attention) {
|
|
13637
|
+
const item = attentionItem(child, handle.attention, state, tracker);
|
|
13638
|
+
results.push(item);
|
|
13639
|
+
before = lastCharacter(item.sequences[0]);
|
|
13640
|
+
} else {
|
|
13641
|
+
const value = state.handle(child, parent, state, {
|
|
13642
|
+
...tracker.current(),
|
|
13643
|
+
after,
|
|
13644
|
+
before
|
|
13645
|
+
});
|
|
13646
|
+
if (!value) continue;
|
|
13647
|
+
tracker.move(value);
|
|
13648
|
+
results.push(value);
|
|
13649
|
+
before = lastCharacter(value);
|
|
13650
|
+
}
|
|
13651
|
+
}
|
|
13652
|
+
indexStack.pop();
|
|
13653
|
+
return results;
|
|
13654
|
+
}
|
|
13655
|
+
/**
|
|
13656
|
+
* Serialize a node as attention,
|
|
13657
|
+
* with its sequence chosen later.
|
|
13658
|
+
*
|
|
13659
|
+
* @param {PhrasingParents} node
|
|
13660
|
+
* Node.
|
|
13661
|
+
* @param {Attention} attention
|
|
13662
|
+
* Attention of the node.
|
|
13663
|
+
* @param {State} state
|
|
13664
|
+
* Info passed around about the current state.
|
|
13665
|
+
* @param {Tracker} tracker
|
|
13666
|
+
* Tracker.
|
|
13667
|
+
* @returns {AttentionResult}
|
|
13668
|
+
* Attention.
|
|
13669
|
+
*/
|
|
13670
|
+
function attentionItem(node, attention, state, tracker) {
|
|
13671
|
+
const { construct, markers, sizes } = attention(node, state);
|
|
13672
|
+
const sequences = attentionSequences(node.type, markers, sizes);
|
|
13673
|
+
const sequence = sequences[0];
|
|
13674
|
+
const exit = state.enter(construct);
|
|
13675
|
+
tracker.move(sequence);
|
|
13676
|
+
const children = phrasing(node, state, {
|
|
13677
|
+
...tracker.current(),
|
|
13678
|
+
before: sequence,
|
|
13679
|
+
after: sequence
|
|
13680
|
+
});
|
|
13681
|
+
tracker.move(serialize(children, sequence, sequence));
|
|
13682
|
+
tracker.move(sequence);
|
|
13683
|
+
exit();
|
|
13684
|
+
return {
|
|
13685
|
+
children,
|
|
13686
|
+
sequences
|
|
13687
|
+
};
|
|
13688
|
+
}
|
|
13689
|
+
/**
|
|
13690
|
+
* Render items with sequences;
|
|
13691
|
+
* encoding characters around attention where needed.
|
|
13692
|
+
*
|
|
13693
|
+
* @param {Array<Item>} items
|
|
13694
|
+
* Serialized phrasing.
|
|
13695
|
+
* @param {Map<AttentionResult, string>} chosen
|
|
13696
|
+
* Sequences to use instead of preferred sequences.
|
|
13697
|
+
* @param {string} before
|
|
13698
|
+
* Characters before.
|
|
13699
|
+
* @param {string} after
|
|
13700
|
+
* Characters after.
|
|
13701
|
+
* @returns {Array<Token>}
|
|
13702
|
+
* Tokens.
|
|
13703
|
+
*/
|
|
13704
|
+
function render(items, chosen, before, after) {
|
|
13705
|
+
/** @type {Array<Token>} */
|
|
13706
|
+
const tokens = [];
|
|
13707
|
+
/** @type {string | undefined} */
|
|
13708
|
+
let encodeAfter;
|
|
13709
|
+
let previous = lastCharacter(before);
|
|
13710
|
+
let index = -1;
|
|
13711
|
+
while (++index < items.length) {
|
|
13712
|
+
const item = items[index];
|
|
13713
|
+
if (typeof item === "string") {
|
|
13714
|
+
/** @type {Token} */
|
|
13715
|
+
const token = {
|
|
13716
|
+
value: item,
|
|
13717
|
+
attention: void 0
|
|
13718
|
+
};
|
|
13719
|
+
if (encodeAfter && encodeAfter === firstCharacter(item)) encode([token], true);
|
|
13720
|
+
encodeAfter = void 0;
|
|
13721
|
+
tokens.push(token);
|
|
13722
|
+
if (token.value) previous = lastCharacter(token.value);
|
|
13723
|
+
continue;
|
|
13724
|
+
}
|
|
13725
|
+
const sequence = chosen.get(item) || item.sequences[0];
|
|
13726
|
+
const marker = sequence.charAt(0);
|
|
13727
|
+
const next = items[index + 1];
|
|
13728
|
+
const outsideBefore = previous;
|
|
13729
|
+
const outsideAfter = firstCharacter(next === void 0 ? after : typeof next === "string" ? next : chosen.get(next) || next.sequences[0]);
|
|
13730
|
+
const inside = render(item.children, chosen, sequence, sequence);
|
|
13731
|
+
const head = inside.length > 0 ? inside[0].value : "";
|
|
13732
|
+
const open = encodeInfo(outsideBefore.charCodeAt(outsideBefore.length - 1), head.charCodeAt(0), marker);
|
|
13733
|
+
if (open.inside) encode(inside, true);
|
|
13734
|
+
const tail = inside.length > 0 ? lastCharacter(inside[inside.length - 1].value) : "";
|
|
13735
|
+
const close = encodeInfo(outsideAfter.charCodeAt(0), tail.charCodeAt(tail.length - 1), marker);
|
|
13736
|
+
if (close.inside) encode(inside, false);
|
|
13737
|
+
if (open.outside && outsideBefore !== "\n" && outsideBefore !== "\r") encode(tokens, false);
|
|
13738
|
+
if (close.outside) encodeAfter = outsideAfter;
|
|
13739
|
+
tokens.push({
|
|
13740
|
+
value: sequence,
|
|
13741
|
+
attention: item
|
|
13742
|
+
}, ...inside, {
|
|
13743
|
+
value: sequence,
|
|
13744
|
+
attention: item
|
|
13745
|
+
});
|
|
13746
|
+
previous = sequence.charAt(sequence.length - 1);
|
|
13747
|
+
}
|
|
13748
|
+
return tokens;
|
|
13749
|
+
}
|
|
13750
|
+
/**
|
|
13751
|
+
* Serialize phrasing with attention.
|
|
13752
|
+
*
|
|
13753
|
+
* Whether attention forms depends on everything around it.
|
|
13754
|
+
* This checks that it does and tries other sequences if not.
|
|
13755
|
+
*
|
|
13756
|
+
* @param {Array<Item>} items
|
|
13757
|
+
* Phrasing items.
|
|
13758
|
+
* @param {string} before
|
|
13759
|
+
* Characters before.
|
|
13760
|
+
* @param {string} after
|
|
13761
|
+
* Characters after.
|
|
13762
|
+
* @returns {string}
|
|
13763
|
+
* Serialized markdown.
|
|
13764
|
+
*/
|
|
13765
|
+
function serialize(items, before, after) {
|
|
13766
|
+
/** @type {Map<AttentionResult, string>} */
|
|
13767
|
+
let chosen = /* @__PURE__ */ new Map();
|
|
13768
|
+
const initial = render(items, chosen, before, after);
|
|
13769
|
+
let tokens = initial;
|
|
13770
|
+
let mistake = check(tokens, before, after);
|
|
13771
|
+
while (mistake) {
|
|
13772
|
+
const next = improve(items, chosen, mistake, before, after);
|
|
13773
|
+
if (!next) {
|
|
13774
|
+
tokens = initial;
|
|
13775
|
+
break;
|
|
13776
|
+
}
|
|
13777
|
+
chosen = next.chosen;
|
|
13778
|
+
tokens = next.tokens;
|
|
13779
|
+
mistake = next.mistake;
|
|
13780
|
+
}
|
|
13781
|
+
let result = "";
|
|
13782
|
+
for (const token of tokens) result += token.value;
|
|
13783
|
+
return result;
|
|
13784
|
+
}
|
|
13785
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/handle/emphasis.js
|
|
13102
13786
|
/**
|
|
13103
13787
|
* @import {AttentionInfo, Info, State} from 'mdast-util-to-markdown'
|
|
13104
13788
|
* @import {Emphasis, Parents} from 'mdast'
|
|
@@ -13123,10 +13807,7 @@ window.__ModuleLoader__.load({
|
|
|
13123
13807
|
*/
|
|
13124
13808
|
function emphasis(node, _, state, info) {
|
|
13125
13809
|
const exit = state.enter("phrasing");
|
|
13126
|
-
const value = state.
|
|
13127
|
-
type: "root",
|
|
13128
|
-
children: [node]
|
|
13129
|
-
}, info);
|
|
13810
|
+
const value = serialize([attentionItem(node, attention$1, state, state.createTracker(info))], info.before, info.after);
|
|
13130
13811
|
exit();
|
|
13131
13812
|
return value;
|
|
13132
13813
|
}
|
|
@@ -13162,8 +13843,7 @@ window.__ModuleLoader__.load({
|
|
|
13162
13843
|
function peek$1(_, _1, state) {
|
|
13163
13844
|
return state.options.emphasis || "*";
|
|
13164
13845
|
}
|
|
13165
|
-
|
|
13166
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/handle/html.js
|
|
13846
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/handle/html.js
|
|
13167
13847
|
/**
|
|
13168
13848
|
* @import {Html} from 'mdast'
|
|
13169
13849
|
*/
|
|
@@ -13188,8 +13868,7 @@ window.__ModuleLoader__.load({
|
|
|
13188
13868
|
function htmlPeek() {
|
|
13189
13869
|
return "<";
|
|
13190
13870
|
}
|
|
13191
|
-
|
|
13192
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/handle/image.js
|
|
13871
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/handle/image.js
|
|
13193
13872
|
/**
|
|
13194
13873
|
* @import {Info, State} from 'mdast-util-to-markdown'
|
|
13195
13874
|
* @import {Image, Parents} from 'mdast'
|
|
@@ -13265,8 +13944,7 @@ window.__ModuleLoader__.load({
|
|
|
13265
13944
|
function imagePeek() {
|
|
13266
13945
|
return "!";
|
|
13267
13946
|
}
|
|
13268
|
-
|
|
13269
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/handle/image-reference.js
|
|
13947
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/handle/image-reference.js
|
|
13270
13948
|
/**
|
|
13271
13949
|
* @import {Info, State} from 'mdast-util-to-markdown'
|
|
13272
13950
|
* @import {ImageReference, Parents} from 'mdast'
|
|
@@ -13326,8 +14004,7 @@ window.__ModuleLoader__.load({
|
|
|
13326
14004
|
function imageReferencePeek() {
|
|
13327
14005
|
return "!";
|
|
13328
14006
|
}
|
|
13329
|
-
|
|
13330
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/handle/inline-code.js
|
|
14007
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/handle/inline-code.js
|
|
13331
14008
|
/**
|
|
13332
14009
|
* @import {State} from 'mdast-util-to-markdown'
|
|
13333
14010
|
* @import {InlineCode, Parents} from 'mdast'
|
|
@@ -13374,8 +14051,7 @@ window.__ModuleLoader__.load({
|
|
|
13374
14051
|
function inlineCodePeek() {
|
|
13375
14052
|
return "`";
|
|
13376
14053
|
}
|
|
13377
|
-
|
|
13378
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/util/format-link-as-autolink.js
|
|
14054
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/util/format-link-as-autolink.js
|
|
13379
14055
|
/**
|
|
13380
14056
|
* @import {State} from 'mdast-util-to-markdown'
|
|
13381
14057
|
* @import {Link} from 'mdast'
|
|
@@ -13394,8 +14070,7 @@ window.__ModuleLoader__.load({
|
|
|
13394
14070
|
const raw = toString(node);
|
|
13395
14071
|
return Boolean(!state.options.resourceLink && node.url && !node.title && node.children && node.children.length === 1 && node.children[0].type === "text" && (raw === node.url || "mailto:" + raw === node.url) && /^[a-z][+\-.a-z]+:/i.test(node.url) && !/[\0- <>\u007F]/.test(node.url));
|
|
13396
14072
|
}
|
|
13397
|
-
|
|
13398
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/handle/link.js
|
|
14073
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/handle/link.js
|
|
13399
14074
|
/**
|
|
13400
14075
|
* @import {Info, State} from 'mdast-util-to-markdown'
|
|
13401
14076
|
* @import {Link, Parents} from 'mdast'
|
|
@@ -13440,14 +14115,23 @@ window.__ModuleLoader__.load({
|
|
|
13440
14115
|
const exit = state.enter("link");
|
|
13441
14116
|
let subexit = state.enter("label");
|
|
13442
14117
|
let value = tracker.move("[");
|
|
13443
|
-
|
|
14118
|
+
const text = state.containerPhrasing(node, {
|
|
13444
14119
|
before: value,
|
|
13445
14120
|
after: "](",
|
|
13446
14121
|
...tracker.current()
|
|
13447
|
-
})
|
|
13448
|
-
value += tracker.move(
|
|
14122
|
+
});
|
|
14123
|
+
value += tracker.move(text);
|
|
13449
14124
|
subexit();
|
|
13450
|
-
|
|
14125
|
+
value += tracker.move("](");
|
|
14126
|
+
const enclose = /[\0- \u007F]/.test(node.url);
|
|
14127
|
+
const last = info.before.charAt(info.before.length - 1);
|
|
14128
|
+
let title = node.title || void 0;
|
|
14129
|
+
if (!title && !enclose && (last === "\n" || last === "\r")) {
|
|
14130
|
+
let index = 0;
|
|
14131
|
+
while (index < text.length && text.charCodeAt(index) !== 93) index += text.charCodeAt(index) === 92 ? 2 : 1;
|
|
14132
|
+
if (text.charCodeAt(index + 1) === 58) title = "";
|
|
14133
|
+
}
|
|
14134
|
+
if (!node.url && typeof title === "string" || enclose) {
|
|
13451
14135
|
subexit = state.enter("destinationLiteral");
|
|
13452
14136
|
value += tracker.move("<");
|
|
13453
14137
|
value += tracker.move(state.safe(node.url, {
|
|
@@ -13460,15 +14144,15 @@ window.__ModuleLoader__.load({
|
|
|
13460
14144
|
subexit = state.enter("destinationRaw");
|
|
13461
14145
|
value += tracker.move(state.safe(node.url, {
|
|
13462
14146
|
before: value,
|
|
13463
|
-
after:
|
|
14147
|
+
after: typeof title === "string" ? " " : ")",
|
|
13464
14148
|
...tracker.current()
|
|
13465
14149
|
}));
|
|
13466
14150
|
}
|
|
13467
14151
|
subexit();
|
|
13468
|
-
if (
|
|
14152
|
+
if (typeof title === "string") {
|
|
13469
14153
|
subexit = state.enter(`title${suffix}`);
|
|
13470
14154
|
value += tracker.move(" " + quote);
|
|
13471
|
-
value += tracker.move(state.safe(
|
|
14155
|
+
value += tracker.move(state.safe(title, {
|
|
13472
14156
|
before: value,
|
|
13473
14157
|
after: quote,
|
|
13474
14158
|
...tracker.current()
|
|
@@ -13495,8 +14179,7 @@ window.__ModuleLoader__.load({
|
|
|
13495
14179
|
function linkPeek(node, _, state) {
|
|
13496
14180
|
return formatLinkAsAutolink(node, state) ? "<" : "[";
|
|
13497
14181
|
}
|
|
13498
|
-
|
|
13499
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/handle/link-reference.js
|
|
14182
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/handle/link-reference.js
|
|
13500
14183
|
/**
|
|
13501
14184
|
* @import {Info, State} from 'mdast-util-to-markdown'
|
|
13502
14185
|
* @import {LinkReference, Parents} from 'mdast'
|
|
@@ -13556,8 +14239,7 @@ window.__ModuleLoader__.load({
|
|
|
13556
14239
|
function linkReferencePeek() {
|
|
13557
14240
|
return "[";
|
|
13558
14241
|
}
|
|
13559
|
-
|
|
13560
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/util/check-strong.js
|
|
14242
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/util/check-strong.js
|
|
13561
14243
|
/**
|
|
13562
14244
|
* @import {Options, State} from 'mdast-util-to-markdown'
|
|
13563
14245
|
*/
|
|
@@ -13574,8 +14256,7 @@ window.__ModuleLoader__.load({
|
|
|
13574
14256
|
if (marker !== "*" && marker !== "_") throw new Error("Cannot serialize strong with `" + marker + "` for `options.strong`, expected `*`, or `_`");
|
|
13575
14257
|
return marker;
|
|
13576
14258
|
}
|
|
13577
|
-
|
|
13578
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/handle/strong.js
|
|
14259
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/handle/strong.js
|
|
13579
14260
|
/**
|
|
13580
14261
|
* @import {AttentionInfo, Info, State} from 'mdast-util-to-markdown'
|
|
13581
14262
|
* @import {Parents, Strong} from 'mdast'
|
|
@@ -13600,10 +14281,7 @@ window.__ModuleLoader__.load({
|
|
|
13600
14281
|
*/
|
|
13601
14282
|
function strong(node, _, state, info) {
|
|
13602
14283
|
const exit = state.enter("phrasing");
|
|
13603
|
-
const value = state.
|
|
13604
|
-
type: "root",
|
|
13605
|
-
children: [node]
|
|
13606
|
-
}, info);
|
|
14284
|
+
const value = serialize([attentionItem(node, attention, state, state.createTracker(info))], info.before, info.after);
|
|
13607
14285
|
exit();
|
|
13608
14286
|
return value;
|
|
13609
14287
|
}
|
|
@@ -13639,8 +14317,7 @@ window.__ModuleLoader__.load({
|
|
|
13639
14317
|
function peek(_, _1, state) {
|
|
13640
14318
|
return state.options.strong || "*";
|
|
13641
14319
|
}
|
|
13642
|
-
|
|
13643
|
-
//#region ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.0/node_modules/mdast-util-to-markdown/lib/unsafe.js
|
|
14320
|
+
// ../../../node_modules/.pnpm/mdast-util-to-markdown@2.2.1/node_modules/mdast-util-to-markdown/lib/unsafe.js
|
|
13644
14321
|
/**
|
|
13645
14322
|
* @import {ConstructName, Unsafe} from 'mdast-util-to-markdown'
|
|
13646
14323
|
*/
|
|
@@ -13754,7 +14431,17 @@ window.__ModuleLoader__.load({
|
|
|
13754
14431
|
{
|
|
13755
14432
|
character: "&",
|
|
13756
14433
|
after: "[#A-Za-z]",
|
|
13757
|
-
inConstruct:
|
|
14434
|
+
inConstruct: [
|
|
14435
|
+
"codeFencedLangGraveAccent",
|
|
14436
|
+
"codeFencedLangTilde",
|
|
14437
|
+
"codeFencedMetaGraveAccent",
|
|
14438
|
+
"codeFencedMetaTilde",
|
|
14439
|
+
"destinationLiteral",
|
|
14440
|
+
"destinationRaw",
|
|
14441
|
+
"phrasing",
|
|
14442
|
+
"titleApostrophe",
|
|
14443
|
+
"titleQuote"
|
|
14444
|
+
]
|
|
13758
14445
|
},
|
|
13759
14446
|
{
|
|
13760
14447
|
character: "'",
|
|
@@ -13899,8 +14586,7 @@ window.__ModuleLoader__.load({
|
|
|
13899
14586
|
inConstruct: "autolink"
|
|
13900
14587
|
});
|
|
13901
14588
|
({}).hasOwnProperty;
|
|
13902
|
-
|
|
13903
|
-
//#region ../../../node_modules/.pnpm/mdast-util-gfm-table@2.0.0_supports-color@9.4.0/node_modules/mdast-util-gfm-table/lib/index.js
|
|
14589
|
+
// ../../../node_modules/.pnpm/mdast-util-gfm-table@2.0.0_supports-color@9.4.0/node_modules/mdast-util-gfm-table/lib/index.js
|
|
13904
14590
|
/**
|
|
13905
14591
|
* @typedef {import('mdast').InlineCode} InlineCode
|
|
13906
14592
|
* @typedef {import('mdast').Table} Table
|
|
@@ -14024,8 +14710,7 @@ window.__ModuleLoader__.load({
|
|
|
14024
14710
|
function replace($0, $1) {
|
|
14025
14711
|
return $1 === "|" ? $1 : $0;
|
|
14026
14712
|
}
|
|
14027
|
-
|
|
14028
|
-
//#region ../../../node_modules/.pnpm/mdast-util-gfm-task-list-item@2.0.0_supports-color@9.4.0/node_modules/mdast-util-gfm-task-list-item/lib/index.js
|
|
14713
|
+
// ../../../node_modules/.pnpm/mdast-util-gfm-task-list-item@2.0.0_supports-color@9.4.0/node_modules/mdast-util-gfm-task-list-item/lib/index.js
|
|
14029
14714
|
/**
|
|
14030
14715
|
* @typedef {import('mdast').ListItem} ListItem
|
|
14031
14716
|
* @typedef {import('mdast').Paragraph} Paragraph
|
|
@@ -14093,8 +14778,7 @@ window.__ModuleLoader__.load({
|
|
|
14093
14778
|
}
|
|
14094
14779
|
this.exit(token);
|
|
14095
14780
|
}
|
|
14096
|
-
|
|
14097
|
-
//#region ../../../node_modules/.pnpm/mdast-util-gfm@3.1.0_supports-color@9.4.0/node_modules/mdast-util-gfm/lib/index.js
|
|
14781
|
+
// ../../../node_modules/.pnpm/mdast-util-gfm@3.1.0_supports-color@9.4.0/node_modules/mdast-util-gfm/lib/index.js
|
|
14098
14782
|
/**
|
|
14099
14783
|
* @import {Extension as FromMarkdownExtension} from 'mdast-util-from-markdown'
|
|
14100
14784
|
* @import {Options} from 'mdast-util-gfm'
|
|
@@ -14117,8 +14801,7 @@ window.__ModuleLoader__.load({
|
|
|
14117
14801
|
gfmTaskListItemFromMarkdown()
|
|
14118
14802
|
];
|
|
14119
14803
|
}
|
|
14120
|
-
|
|
14121
|
-
//#region ../../../node_modules/.pnpm/micromark-extension-gfm-autolink-literal@2.1.0/node_modules/micromark-extension-gfm-autolink-literal/lib/syntax.js
|
|
14804
|
+
// ../../../node_modules/.pnpm/micromark-extension-gfm-autolink-literal@2.1.0_patch_hash=906ae7c0cd1f69e7ee308a41bc054_3cbe234c53027bed16ba7d28e78f0ec4/node_modules/micromark-extension-gfm-autolink-literal/lib/syntax.js
|
|
14122
14805
|
/**
|
|
14123
14806
|
* @import {Code, ConstructRecord, Event, Extension, Previous, State, TokenizeContext, Tokenizer} from 'micromark-util-types'
|
|
14124
14807
|
*/
|
|
@@ -14138,6 +14821,10 @@ window.__ModuleLoader__.load({
|
|
|
14138
14821
|
tokenize: tokenizeTrail,
|
|
14139
14822
|
partial: true
|
|
14140
14823
|
};
|
|
14824
|
+
const astralPunctuation = {
|
|
14825
|
+
tokenize: tokenizeAstralPunctuation,
|
|
14826
|
+
partial: true
|
|
14827
|
+
};
|
|
14141
14828
|
const emailDomainDotTrail = {
|
|
14142
14829
|
tokenize: tokenizeEmailDomainDotTrail,
|
|
14143
14830
|
partial: true
|
|
@@ -14605,7 +15292,8 @@ window.__ModuleLoader__.load({
|
|
|
14605
15292
|
}
|
|
14606
15293
|
if (code === 41 && sizeClose < sizeOpen) return pathAtPunctuation(code);
|
|
14607
15294
|
if (code === 33 || code === 34 || code === 38 || code === 39 || code === 41 || code === 42 || code === 44 || code === 46 || code === 58 || code === 59 || code === 60 || code === 63 || code === 93 || code === 95 || code === 126) return effects.check(trail, ok, pathAtPunctuation)(code);
|
|
14608
|
-
if (
|
|
15295
|
+
if (highSurrogate(code)) return effects.check(astralPunctuation, ok, pathAtPunctuation)(code);
|
|
15296
|
+
if (code === null || markdownLineEndingOrSpace(code) || unicodeWhitespace(code) || nonAsciiPunctuation(code)) return ok(code);
|
|
14609
15297
|
effects.consume(code);
|
|
14610
15298
|
return pathInside;
|
|
14611
15299
|
}
|
|
@@ -14665,7 +15353,8 @@ window.__ModuleLoader__.load({
|
|
|
14665
15353
|
effects.consume(code);
|
|
14666
15354
|
return trailBracketAfter;
|
|
14667
15355
|
}
|
|
14668
|
-
if (code === 60 || code === null || markdownLineEndingOrSpace(code) || unicodeWhitespace(code)) return ok(code);
|
|
15356
|
+
if (code === 60 || code === null || markdownLineEndingOrSpace(code) || unicodeWhitespace(code) || nonAsciiPunctuation(code)) return ok(code);
|
|
15357
|
+
if (highSurrogate(code)) return effects.check(astralPunctuation, ok, nok)(code);
|
|
14669
15358
|
return nok(code);
|
|
14670
15359
|
}
|
|
14671
15360
|
/**
|
|
@@ -14791,6 +15480,47 @@ window.__ModuleLoader__.load({
|
|
|
14791
15480
|
return !(code === 47 || gfmAtext(code));
|
|
14792
15481
|
}
|
|
14793
15482
|
/**
|
|
15483
|
+
* Non-ASCII punctuation or symbol, such as `。` or `,`, which ends a literal
|
|
15484
|
+
* in CJK prose.
|
|
15485
|
+
*
|
|
15486
|
+
* @param {Code} code
|
|
15487
|
+
* @returns {boolean}
|
|
15488
|
+
*/
|
|
15489
|
+
function nonAsciiPunctuation(code) {
|
|
15490
|
+
return code !== null && code > 127 && unicodePunctuation(code);
|
|
15491
|
+
}
|
|
15492
|
+
/**
|
|
15493
|
+
* Whether `code` is a UTF-16 high surrogate, which starts a character outside
|
|
15494
|
+
* the BMP such as `😀`.
|
|
15495
|
+
*
|
|
15496
|
+
* @param {Code} code
|
|
15497
|
+
* @returns {boolean}
|
|
15498
|
+
*/
|
|
15499
|
+
function highSurrogate(code) {
|
|
15500
|
+
return code !== null && code >= 55296 && code <= 56319;
|
|
15501
|
+
}
|
|
15502
|
+
/**
|
|
15503
|
+
* Check whether a surrogate pair is punctuation or a symbol.
|
|
15504
|
+
*
|
|
15505
|
+
* @this {TokenizeContext}
|
|
15506
|
+
* @type {Tokenizer}
|
|
15507
|
+
*/
|
|
15508
|
+
function tokenizeAstralPunctuation(effects, ok, nok) {
|
|
15509
|
+
/** @type {number} */
|
|
15510
|
+
let high;
|
|
15511
|
+
return start;
|
|
15512
|
+
/** @type {State} */
|
|
15513
|
+
function start(code) {
|
|
15514
|
+
high = code;
|
|
15515
|
+
effects.consume(code);
|
|
15516
|
+
return low;
|
|
15517
|
+
}
|
|
15518
|
+
/** @type {State} */
|
|
15519
|
+
function low(code) {
|
|
15520
|
+
return code !== null && code >= 56320 && code <= 57343 && /[\p{P}\p{S}]/u.test(String.fromCharCode(high, code)) ? ok(code) : nok(code);
|
|
15521
|
+
}
|
|
15522
|
+
}
|
|
15523
|
+
/**
|
|
14794
15524
|
* @param {Code} code
|
|
14795
15525
|
* @returns {boolean}
|
|
14796
15526
|
*/
|
|
@@ -14818,8 +15548,7 @@ window.__ModuleLoader__.load({
|
|
|
14818
15548
|
if (events.length > 0 && !result) events[events.length - 1][1]._gfmAutolinkLiteralWalkedInto = true;
|
|
14819
15549
|
return result;
|
|
14820
15550
|
}
|
|
14821
|
-
|
|
14822
|
-
//#region ../../../node_modules/.pnpm/micromark-extension-gfm-footnote@2.1.0/node_modules/micromark-extension-gfm-footnote/lib/syntax.js
|
|
15551
|
+
// ../../../node_modules/.pnpm/micromark-extension-gfm-footnote@2.1.0/node_modules/micromark-extension-gfm-footnote/lib/syntax.js
|
|
14823
15552
|
/**
|
|
14824
15553
|
* @import {Event, Exiter, Extension, Resolver, State, Token, TokenizeContext, Tokenizer} from 'micromark-util-types'
|
|
14825
15554
|
*/
|
|
@@ -15238,8 +15967,7 @@ window.__ModuleLoader__.load({
|
|
|
15238
15967
|
}
|
|
15239
15968
|
}
|
|
15240
15969
|
({}).hasOwnProperty;
|
|
15241
|
-
|
|
15242
|
-
//#region ../../../node_modules/.pnpm/micromark-extension-gfm-strikethrough@2.1.0/node_modules/micromark-extension-gfm-strikethrough/lib/syntax.js
|
|
15970
|
+
// ../../../node_modules/.pnpm/micromark-extension-gfm-strikethrough@2.1.0/node_modules/micromark-extension-gfm-strikethrough/lib/syntax.js
|
|
15243
15971
|
/**
|
|
15244
15972
|
* @import {Options} from 'micromark-extension-gfm-strikethrough'
|
|
15245
15973
|
* @import {Event, Extension, Resolver, State, Token, TokenizeContext, Tokenizer} from 'micromark-util-types'
|
|
@@ -15379,8 +16107,7 @@ window.__ModuleLoader__.load({
|
|
|
15379
16107
|
}
|
|
15380
16108
|
}
|
|
15381
16109
|
}
|
|
15382
|
-
|
|
15383
|
-
//#region ../../../node_modules/.pnpm/micromark-extension-gfm-table@2.1.2/node_modules/micromark-extension-gfm-table/lib/edit-map.js
|
|
16110
|
+
// ../../../node_modules/.pnpm/micromark-extension-gfm-table@2.1.2/node_modules/micromark-extension-gfm-table/lib/edit-map.js
|
|
15384
16111
|
/**
|
|
15385
16112
|
* @import {Event} from 'micromark-util-types'
|
|
15386
16113
|
*/
|
|
@@ -15490,8 +16217,7 @@ window.__ModuleLoader__.load({
|
|
|
15490
16217
|
editMap.map.push(change);
|
|
15491
16218
|
editMap.index.set(at, change);
|
|
15492
16219
|
}
|
|
15493
|
-
|
|
15494
|
-
//#region ../../../node_modules/.pnpm/micromark-extension-gfm-table@2.1.2/node_modules/micromark-extension-gfm-table/lib/infer.js
|
|
16220
|
+
// ../../../node_modules/.pnpm/micromark-extension-gfm-table@2.1.2/node_modules/micromark-extension-gfm-table/lib/infer.js
|
|
15495
16221
|
/**
|
|
15496
16222
|
* @import {Event} from 'micromark-util-types'
|
|
15497
16223
|
*/
|
|
@@ -15528,8 +16254,7 @@ window.__ModuleLoader__.load({
|
|
|
15528
16254
|
}
|
|
15529
16255
|
return align;
|
|
15530
16256
|
}
|
|
15531
|
-
|
|
15532
|
-
//#region ../../../node_modules/.pnpm/micromark-extension-gfm-table@2.1.2/node_modules/micromark-extension-gfm-table/lib/syntax.js
|
|
16257
|
+
// ../../../node_modules/.pnpm/micromark-extension-gfm-table@2.1.2/node_modules/micromark-extension-gfm-table/lib/syntax.js
|
|
15533
16258
|
/**
|
|
15534
16259
|
* @import {Event, Extension, Point, Resolver, State, Token, TokenizeContext, Tokenizer} from 'micromark-util-types'
|
|
15535
16260
|
*/
|
|
@@ -16246,8 +16971,7 @@ window.__ModuleLoader__.load({
|
|
|
16246
16971
|
return event[1][side];
|
|
16247
16972
|
}
|
|
16248
16973
|
new RegExp("^" + /<(\/?)(iframe|noembed|noframes|plaintext|script|style|title|textarea|xmp)(?=[\t\n\f\r />])/gi.source, "i");
|
|
16249
|
-
|
|
16250
|
-
//#region ../../../node_modules/.pnpm/micromark-extension-gfm-task-list-item@2.1.0/node_modules/micromark-extension-gfm-task-list-item/lib/syntax.js
|
|
16974
|
+
// ../../../node_modules/.pnpm/micromark-extension-gfm-task-list-item@2.1.0/node_modules/micromark-extension-gfm-task-list-item/lib/syntax.js
|
|
16251
16975
|
/**
|
|
16252
16976
|
* @import {Extension, State, TokenizeContext, Tokenizer} from 'micromark-util-types'
|
|
16253
16977
|
*/
|
|
@@ -16365,8 +17089,7 @@ window.__ModuleLoader__.load({
|
|
|
16365
17089
|
return code === null ? nok(code) : ok(code);
|
|
16366
17090
|
}
|
|
16367
17091
|
}
|
|
16368
|
-
|
|
16369
|
-
//#region ../../../node_modules/.pnpm/micromark-extension-gfm@3.0.0/node_modules/micromark-extension-gfm/index.js
|
|
17092
|
+
// ../../../node_modules/.pnpm/micromark-extension-gfm@3.0.0/node_modules/micromark-extension-gfm/index.js
|
|
16370
17093
|
/**
|
|
16371
17094
|
* @typedef {import('micromark-extension-gfm-footnote').HtmlOptions} HtmlOptions
|
|
16372
17095
|
* @typedef {import('micromark-extension-gfm-strikethrough').Options} Options
|
|
@@ -16393,8 +17116,7 @@ window.__ModuleLoader__.load({
|
|
|
16393
17116
|
gfmTaskListItem()
|
|
16394
17117
|
]);
|
|
16395
17118
|
}
|
|
16396
|
-
|
|
16397
|
-
//#region ../../../node_modules/.pnpm/micromark-util-symbol@2.0.1/node_modules/micromark-util-symbol/lib/codes.js
|
|
17119
|
+
// ../../../node_modules/.pnpm/micromark-util-symbol@2.0.1/node_modules/micromark-util-symbol/lib/codes.js
|
|
16398
17120
|
/**
|
|
16399
17121
|
* Character codes.
|
|
16400
17122
|
*
|
|
@@ -16551,8 +17273,7 @@ window.__ModuleLoader__.load({
|
|
|
16551
17273
|
byteOrderMarker: 65279,
|
|
16552
17274
|
replacementCharacter: 65533
|
|
16553
17275
|
};
|
|
16554
|
-
|
|
16555
|
-
//#region ../../../node_modules/.pnpm/micromark-util-symbol@2.0.1/node_modules/micromark-util-symbol/lib/types.js
|
|
17276
|
+
// ../../../node_modules/.pnpm/micromark-util-symbol@2.0.1/node_modules/micromark-util-symbol/lib/types.js
|
|
16556
17277
|
/**
|
|
16557
17278
|
* This module is compiled away!
|
|
16558
17279
|
*
|
|
@@ -16668,8 +17389,7 @@ window.__ModuleLoader__.load({
|
|
|
16668
17389
|
chunkText: "chunkText",
|
|
16669
17390
|
chunkString: "chunkString"
|
|
16670
17391
|
};
|
|
16671
|
-
|
|
16672
|
-
//#region ../../client/dsh-client-ui-primitives/src/reference.ts
|
|
17392
|
+
// ../../client/dsh-client-ui-primitives/src/reference.ts
|
|
16673
17393
|
const DEFAULT_PROTOCOL = "file";
|
|
16674
17394
|
const EXTERNAL_PROTOCOLS = [
|
|
16675
17395
|
"http",
|
|
@@ -17109,8 +17829,7 @@ window.__ModuleLoader__.load({
|
|
|
17109
17829
|
return;
|
|
17110
17830
|
}
|
|
17111
17831
|
}
|
|
17112
|
-
|
|
17113
|
-
//#region ../../client/dsh-client-ui-primitives/src/reference-markdown.tsx
|
|
17832
|
+
// ../../client/dsh-client-ui-primitives/src/reference-markdown.tsx
|
|
17114
17833
|
function referenceMentions(actions, tokens) {
|
|
17115
17834
|
return { resolve: (value) => {
|
|
17116
17835
|
const reference = tokens?.get(value) ?? parseReferenceToken(value);
|
|
@@ -17168,8 +17887,7 @@ window.__ModuleLoader__.load({
|
|
|
17168
17887
|
}
|
|
17169
17888
|
if (reference.protocol === "file") actions.openFile(path);
|
|
17170
17889
|
}
|
|
17171
|
-
|
|
17172
|
-
//#region ../../client/dsh-client-ui-primitives/src/client/index.ts
|
|
17890
|
+
// ../../client/dsh-client-ui-primitives/src/client/index.ts
|
|
17173
17891
|
var client_exports = /* @__PURE__ */ __exportAll({
|
|
17174
17892
|
Bubble: () => Bubble,
|
|
17175
17893
|
Button: () => Button$1,
|
|
@@ -17214,8 +17932,7 @@ window.__ModuleLoader__.load({
|
|
|
17214
17932
|
function apply$1(ctx) {
|
|
17215
17933
|
apply$2(ctx);
|
|
17216
17934
|
}
|
|
17217
|
-
|
|
17218
|
-
//#region src/client/llm-directory.ts
|
|
17935
|
+
// src/client/llm-directory.ts
|
|
17219
17936
|
function routeKey(provider, model) {
|
|
17220
17937
|
return `${provider}\u0000${model}`;
|
|
17221
17938
|
}
|
|
@@ -17283,8 +18000,7 @@ window.__ModuleLoader__.load({
|
|
|
17283
18000
|
modelName: model.label
|
|
17284
18001
|
})));
|
|
17285
18002
|
}
|
|
17286
|
-
|
|
17287
|
-
//#region src/client/bundle-config.ts
|
|
18003
|
+
// src/client/bundle-config.ts
|
|
17288
18004
|
const SESSION_MODE_NS = "session-mode";
|
|
17289
18005
|
const BUNDLE_CONFIG_KEY = "@morlay/session-mode-profile";
|
|
17290
18006
|
const PROTECTED_MODE_IDS = ["noop"];
|
|
@@ -17791,8 +18507,7 @@ window.__ModuleLoader__.load({
|
|
|
17791
18507
|
return Array.isArray(value) ? value.map((item) => String(item)) : [];
|
|
17792
18508
|
}
|
|
17793
18509
|
const ROLES = ROLE_VALUES;
|
|
17794
|
-
|
|
17795
|
-
//#region src/client/BundleConfigPage.tsx
|
|
18510
|
+
// src/client/BundleConfigPage.tsx
|
|
17796
18511
|
function BundleConfigPage(props) {
|
|
17797
18512
|
const { t, view } = props;
|
|
17798
18513
|
const face = {
|
|
@@ -18282,8 +18997,7 @@ window.__ModuleLoader__.load({
|
|
|
18282
18997
|
function triValue(field) {
|
|
18283
18998
|
return field.value === "unset" || field.value === "on" || field.value === "off" ? field.value : "unset";
|
|
18284
18999
|
}
|
|
18285
|
-
|
|
18286
|
-
//#region src/client/bundle-locales.ts
|
|
19000
|
+
// src/client/bundle-locales.ts
|
|
18287
19001
|
const BUNDLE_NS = "session-mode-bundle";
|
|
18288
19002
|
const bundleZh = {
|
|
18289
19003
|
"default.label": "新会话的默认模式",
|
|
@@ -18475,8 +19189,7 @@ window.__ModuleLoader__.load({
|
|
|
18475
19189
|
"summary.denyTools": "{n} denied",
|
|
18476
19190
|
"summary.globalModel": "global model"
|
|
18477
19191
|
};
|
|
18478
|
-
|
|
18479
|
-
//#region src/client/api.ts
|
|
19192
|
+
// src/client/api.ts
|
|
18480
19193
|
async function fetchRoster() {
|
|
18481
19194
|
const response = await fetch(SESSION_MODE_PATH, {
|
|
18482
19195
|
method: "GET",
|
|
@@ -18504,8 +19217,7 @@ window.__ModuleLoader__.load({
|
|
|
18504
19217
|
}
|
|
18505
19218
|
return value?.mode ?? mode;
|
|
18506
19219
|
}
|
|
18507
|
-
|
|
18508
|
-
//#region src/client/use-roster.ts
|
|
19220
|
+
// src/client/use-roster.ts
|
|
18509
19221
|
let pending;
|
|
18510
19222
|
function useRoster() {
|
|
18511
19223
|
const [roster, setRoster] = (0, react.useState)(void 0);
|
|
@@ -18523,8 +19235,7 @@ window.__ModuleLoader__.load({
|
|
|
18523
19235
|
}, []);
|
|
18524
19236
|
return roster;
|
|
18525
19237
|
}
|
|
18526
|
-
|
|
18527
|
-
//#region src/client/SessionModeSeat.tsx
|
|
19238
|
+
// src/client/SessionModeSeat.tsx
|
|
18528
19239
|
function SessionModeSeat({ sessionId, useSessions, t }) {
|
|
18529
19240
|
const roster = useRoster();
|
|
18530
19241
|
const selected = useSessions((state) => {
|
|
@@ -18594,8 +19305,7 @@ window.__ModuleLoader__.load({
|
|
|
18594
19305
|
})
|
|
18595
19306
|
});
|
|
18596
19307
|
}
|
|
18597
|
-
|
|
18598
|
-
//#region src/client/locales.ts
|
|
19308
|
+
// src/client/locales.ts
|
|
18599
19309
|
const zh = {
|
|
18600
19310
|
seatHint: "选择这个会话的模式",
|
|
18601
19311
|
lockedHint: "这个会话已经开始:换模式请新开一个会话",
|
|
@@ -18618,8 +19328,7 @@ window.__ModuleLoader__.load({
|
|
|
18618
19328
|
reasoningEffort: "Reasoning effort",
|
|
18619
19329
|
reasoningEffortHint: "Default keeps the provider's own default."
|
|
18620
19330
|
};
|
|
18621
|
-
|
|
18622
|
-
//#region src/client/index.ts
|
|
19331
|
+
// src/client/index.ts
|
|
18623
19332
|
const NS = "session-mode";
|
|
18624
19333
|
const FIELDS = [
|
|
18625
19334
|
"provider",
|
|
@@ -18801,7 +19510,6 @@ window.__ModuleLoader__.load({
|
|
|
18801
19510
|
}, "session-mode: bundle configuration page");
|
|
18802
19511
|
});
|
|
18803
19512
|
}
|
|
18804
|
-
//#endregion
|
|
18805
19513
|
exports.SESSION_MODE_NS = SESSION_MODE_NS;
|
|
18806
19514
|
exports.apply = apply;
|
|
18807
19515
|
exports.inject = inject;
|