@duskmoon-dev/el-markdown-input 0.11.0 → 0.11.1
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/cjs/index.js +999 -556
- package/dist/cjs/index.js.map +12 -9
- package/dist/cjs/register.js +989 -545
- package/dist/cjs/register.js.map +11 -8
- package/dist/esm/index.js +995 -547
- package/dist/esm/index.js.map +12 -9
- package/dist/esm/register.js +994 -543
- package/dist/esm/register.js.map +11 -8
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/autocomplete.d.ts.map +1 -1
- package/dist/types/css.d.ts.map +1 -1
- package/dist/types/element.d.ts +30 -1
- package/dist/types/element.d.ts.map +1 -1
- package/dist/types/highlight.d.ts +1 -0
- package/dist/types/highlight.d.ts.map +1 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/pairs.d.ts +48 -0
- package/dist/types/pairs.d.ts.map +1 -0
- package/dist/types/render.d.ts +22 -0
- package/dist/types/render.d.ts.map +1 -0
- package/dist/types/sanitize-schema.d.ts +3 -0
- package/dist/types/sanitize-schema.d.ts.map +1 -0
- package/dist/types/upload.d.ts +12 -2
- package/dist/types/upload.d.ts.map +1 -1
- package/package.json +19 -6
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"autocomplete.d.ts","sourceRoot":"","sources":["../../src/autocomplete.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAE7C;;;;;;;;;;GAUG;AACH,wBAAgB,aAAa,CAC3B,KAAK,EAAE,MAAM,EACb,SAAS,EAAE,MAAM,GAChB;IAAE,OAAO,EAAE,GAAG,GAAG,GAAG,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAA;CAAE,GAAG,IAAI,CA4BlE;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,MAAM,EACb,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,GAAG,GAAG,GAAG,EAClB,WAAW,EAAE,MAAM,GAClB;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,YAAY,EAAE,MAAM,CAAA;CAAE,
|
|
1
|
+
{"version":3,"file":"autocomplete.d.ts","sourceRoot":"","sources":["../../src/autocomplete.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAE7C;;;;;;;;;;GAUG;AACH,wBAAgB,aAAa,CAC3B,KAAK,EAAE,MAAM,EACb,SAAS,EAAE,MAAM,GAChB;IAAE,OAAO,EAAE,GAAG,GAAG,GAAG,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAA;CAAE,GAAG,IAAI,CA4BlE;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,MAAM,EACb,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,GAAG,GAAG,GAAG,EAClB,WAAW,EAAE,MAAM,GAClB;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,YAAY,EAAE,MAAM,CAAA;CAAE,CAW5C;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,WAAW,EAAE,UAAU,EAAE,EAAE,aAAa,EAAE,MAAM,GAAG,MAAM,CAgBvF"}
|
package/dist/types/css.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"css.d.ts","sourceRoot":"","sources":["../../src/css.ts"],"names":[],"mappings":"AAEA;;;;;;;GAOG;AACH,eAAO,MAAM,aAAa,
|
|
1
|
+
{"version":3,"file":"css.d.ts","sourceRoot":"","sources":["../../src/css.ts"],"names":[],"mappings":"AAEA;;;;;;;GAOG;AACH,eAAO,MAAM,aAAa,eAwczB,CAAC"}
|
package/dist/types/element.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* DuskMoon Markdown Input Element
|
|
3
3
|
*
|
|
4
4
|
* A form-associated custom element providing a markdown editor with:
|
|
5
|
-
* - Write tab with syntax-highlighted
|
|
5
|
+
* - Write tab with syntax-highlighted render layer (Prism.js CDN)
|
|
6
6
|
* - Preview tab with rendered HTML (.markdown-body from @duskmoon-dev/core)
|
|
7
7
|
* - File upload via drag-and-drop, clipboard paste, or file picker
|
|
8
8
|
* - @mention / #reference autocomplete dropdown
|
|
@@ -55,6 +55,10 @@ export declare class ElDmMarkdownInput extends BaseElement {
|
|
|
55
55
|
type: BooleanConstructor;
|
|
56
56
|
reflect: boolean;
|
|
57
57
|
};
|
|
58
|
+
required: {
|
|
59
|
+
type: BooleanConstructor;
|
|
60
|
+
reflect: boolean;
|
|
61
|
+
};
|
|
58
62
|
uploadUrl: {
|
|
59
63
|
type: StringConstructor;
|
|
60
64
|
reflect: boolean;
|
|
@@ -69,15 +73,40 @@ export declare class ElDmMarkdownInput extends BaseElement {
|
|
|
69
73
|
type: BooleanConstructor;
|
|
70
74
|
reflect: boolean;
|
|
71
75
|
};
|
|
76
|
+
livePreview: {
|
|
77
|
+
type: BooleanConstructor;
|
|
78
|
+
reflect: boolean;
|
|
79
|
+
attribute: string;
|
|
80
|
+
};
|
|
81
|
+
debounce: {
|
|
82
|
+
type: NumberConstructor;
|
|
83
|
+
reflect: boolean;
|
|
84
|
+
default: number;
|
|
85
|
+
};
|
|
86
|
+
katexCssUrl: {
|
|
87
|
+
type: StringConstructor;
|
|
88
|
+
reflect: boolean;
|
|
89
|
+
attribute: string;
|
|
90
|
+
};
|
|
91
|
+
mermaidSrc: {
|
|
92
|
+
type: StringConstructor;
|
|
93
|
+
reflect: boolean;
|
|
94
|
+
attribute: string;
|
|
95
|
+
};
|
|
72
96
|
};
|
|
73
97
|
name: string;
|
|
74
98
|
value: string;
|
|
75
99
|
placeholder: string;
|
|
76
100
|
disabled: boolean;
|
|
77
101
|
readonly: boolean;
|
|
102
|
+
required: boolean;
|
|
78
103
|
uploadUrl: string | undefined;
|
|
79
104
|
maxWords: number | undefined;
|
|
80
105
|
dark: boolean;
|
|
106
|
+
livePreview: boolean;
|
|
107
|
+
debounce: number;
|
|
108
|
+
katexCssUrl: string | undefined;
|
|
109
|
+
mermaidSrc: string | undefined;
|
|
81
110
|
constructor();
|
|
82
111
|
connectedCallback(): void;
|
|
83
112
|
disconnectedCallback(): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"element.d.ts","sourceRoot":"","sources":["../../src/element.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"element.d.ts","sourceRoot":"","sources":["../../src/element.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AASpD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAgB7C,qBAAa,iBAAkB,SAAQ,WAAW;;IAChD,MAAM,CAAC,cAAc,EAAG,IAAI,CAAU;IAEtC,MAAM,CAAC,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAcf;IAEM,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;IAClB,SAAS,EAAE,MAAM,GAAG,SAAS,CAAC;IAC9B,QAAQ,EAAE,MAAM,GAAG,SAAS,CAAC;IAC7B,IAAI,EAAE,OAAO,CAAC;IACd,WAAW,EAAE,OAAO,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,GAAG,SAAS,CAAC;IAChC,UAAU,EAAE,MAAM,GAAG,SAAS,CAAC;;IA2DvC,iBAAiB,IAAI,IAAI;IAIzB,oBAAoB,IAAI,IAAI;cAUT,MAAM,IAAI,IAAI;cA6Ed,MAAM,IAAI,MAAM;IAsqBnC,4CAA4C;IAC5C,QAAQ,IAAI,MAAM;IAIlB;;;OAGG;IACH,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI;IAgB3B;;;OAGG;IACH,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI;IAgB7B;;;OAGG;IACH,cAAc,CAAC,IAAI,EAAE,UAAU,EAAE,GAAG,IAAI;CAKzC"}
|
|
@@ -14,6 +14,7 @@ declare global {
|
|
|
14
14
|
/**
|
|
15
15
|
* Ensure Prism is loaded and ready. Returns a cached Promise after the first call.
|
|
16
16
|
* Safe to call multiple times — only one network request is ever made.
|
|
17
|
+
* If loading fails (e.g. network error), the cache is cleared so the next call retries.
|
|
17
18
|
*/
|
|
18
19
|
export declare function ensurePrism(): Promise<void>;
|
|
19
20
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"highlight.d.ts","sourceRoot":"","sources":["../../src/highlight.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,MAAM;QAEd,KAAK,CAAC,EAAE,GAAG,CAAC;KACb;CACF;
|
|
1
|
+
{"version":3,"file":"highlight.d.ts","sourceRoot":"","sources":["../../src/highlight.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,MAAM;QAEd,KAAK,CAAC,EAAE,GAAG,CAAC;KACb;CACF;AAqCD;;;;GAIG;AACH,wBAAgB,WAAW,IAAI,OAAO,CAAC,IAAI,CAAC,CA8B3C;AAeD;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CActD;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,UAAU,EAAE,UAAU,EAAE,IAAI,EAAE,OAAO,GAAG,IAAI,CAuC3E"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACjD,YAAY,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACjD,YAAY,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAI7C;;;GAGG;AACH,wBAAgB,QAAQ,IAAI,IAAI,CAI/B;AAID,KAAK,eAAe,GAAG,WAAW,GAAG;IACnC,QAAQ,IAAI,MAAM,CAAC;IACnB,QAAQ,CAAC,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,OAAO,EAAE,YAAY,CAAC;CACvB,CAAC;AAEF,UAAU,YAAY;IACpB,EAAE,EAAE,eAAe,CAAC;IACpB,SAAS,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,CAAC;IACjE,OAAO,IAAI,IAAI,CAAC;IAChB,OAAO,IAAI,IAAI,CAAC;CACjB;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,eAAO,MAAM,iBAAiB,EAAE,IAAI,CAAC,YAAY,EAAE,SAAS,GAAG,SAAS,CAyBvE,CAAC"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Smart pair insertion and list/heading continuation for the markdown editor.
|
|
3
|
+
*
|
|
4
|
+
* Two behaviors:
|
|
5
|
+
* 1. Backtick pairing — ` → `|` or wraps selection; ``` → fenced block
|
|
6
|
+
* 2. Enter continuation — carries list bullets (*) or breaks out of headings
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Handle a keypress that may trigger smart pair insertion.
|
|
10
|
+
* Currently only `` ` `` is paired; returns false for all other keys.
|
|
11
|
+
*
|
|
12
|
+
* @returns true if the event was handled (caller should preventDefault)
|
|
13
|
+
*/
|
|
14
|
+
export declare function handlePairKey(ta: HTMLTextAreaElement, key: string): boolean;
|
|
15
|
+
/**
|
|
16
|
+
* Handle the Enter key with smart list/heading continuation.
|
|
17
|
+
*
|
|
18
|
+
* @returns true if the event was handled (caller should preventDefault)
|
|
19
|
+
*/
|
|
20
|
+
export declare function handleEnterKey(ta: HTMLTextAreaElement, e: KeyboardEvent): boolean;
|
|
21
|
+
type ContinuationResult = {
|
|
22
|
+
prefix: string;
|
|
23
|
+
eraseCurrentLine: false;
|
|
24
|
+
} | {
|
|
25
|
+
eraseCurrentLine: true;
|
|
26
|
+
};
|
|
27
|
+
/**
|
|
28
|
+
* Given the text of the current line (from line-start to cursor), decide what
|
|
29
|
+
* to insert when the user presses Enter.
|
|
30
|
+
*
|
|
31
|
+
* Return value:
|
|
32
|
+
* - null → do nothing (fall through to native Enter)
|
|
33
|
+
* - { prefix, eraseCurrentLine: false } → insert "\n" + prefix
|
|
34
|
+
* - { eraseCurrentLine: true } → erase the current line's bullet prefix (no "\n" inserted)
|
|
35
|
+
*
|
|
36
|
+
* Rules to implement:
|
|
37
|
+
* - `* text` → continue with `* ` on the next line
|
|
38
|
+
* - `* ` → empty bullet: erase the `* ` and break out of the list
|
|
39
|
+
* - `# text`, `## text`, `### text` (heading with content) → plain newline (no heading prefix)
|
|
40
|
+
* - anything else → null (native Enter)
|
|
41
|
+
*
|
|
42
|
+
* Constraints:
|
|
43
|
+
* - Ordered lists (`1. `, `2. `) are out of scope for now.
|
|
44
|
+
* - Blockquote (`> `) continuation is a bonus if you want it.
|
|
45
|
+
*/
|
|
46
|
+
export declare function getLineContinuation(line: string): ContinuationResult | null;
|
|
47
|
+
export {};
|
|
48
|
+
//# sourceMappingURL=pairs.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pairs.d.ts","sourceRoot":"","sources":["../../src/pairs.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,EAAE,EAAE,mBAAmB,EAAE,GAAG,EAAE,MAAM,GAAG,OAAO,CA2B3E;AAID;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,EAAE,EAAE,mBAAmB,EAAE,CAAC,EAAE,aAAa,GAAG,OAAO,CAiCjF;AAID,KAAK,kBAAkB,GAAG;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,gBAAgB,EAAE,KAAK,CAAA;CAAE,GAAG;IAAE,gBAAgB,EAAE,IAAI,CAAA;CAAE,CAAC;AAEnG;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,MAAM,GAAG,kBAAkB,GAAG,IAAI,CAW3E"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Render pipeline for the preview tab.
|
|
3
|
+
*
|
|
4
|
+
* Uses unified (remark → rehype) to transform raw markdown into sanitized HTML.
|
|
5
|
+
* All dependencies are lazy-loaded on first preview activation for tree-shaking.
|
|
6
|
+
*
|
|
7
|
+
* Mermaid diagrams are handled as a post-render step (not part of the unified pipeline).
|
|
8
|
+
*/
|
|
9
|
+
/**
|
|
10
|
+
* Transform raw markdown into sanitized HTML using the unified pipeline.
|
|
11
|
+
* The processor is lazy-loaded on first call and cached for subsequent renders.
|
|
12
|
+
*/
|
|
13
|
+
export declare function renderMarkdown(source: string): Promise<string>;
|
|
14
|
+
/**
|
|
15
|
+
* Post-render step: find all `pre > code.language-mermaid` blocks in the container,
|
|
16
|
+
* lazy-load mermaid, and replace each `<pre>` with the rendered SVG.
|
|
17
|
+
*
|
|
18
|
+
* @param container The preview container element (inside shadow DOM)
|
|
19
|
+
* @param mermaidSrc Optional override URL for the mermaid ESM bundle
|
|
20
|
+
*/
|
|
21
|
+
export declare function renderMermaidBlocks(container: HTMLElement, mermaidSrc?: string): Promise<void>;
|
|
22
|
+
//# sourceMappingURL=render.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"render.d.ts","sourceRoot":"","sources":["../../src/render.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AA0DH;;;GAGG;AACH,wBAAsB,cAAc,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAIpE;AAcD;;;;;;GAMG;AACH,wBAAsB,mBAAmB,CACvC,SAAS,EAAE,WAAW,EACtB,UAAU,CAAC,EAAE,MAAM,GAClB,OAAO,CAAC,IAAI,CAAC,CAiEf"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sanitize-schema.d.ts","sourceRoot":"","sources":["../../src/sanitize-schema.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAwBjD,eAAO,MAAM,cAAc,EAAE,MAkD3B,CAAC"}
|
package/dist/types/upload.d.ts
CHANGED
|
@@ -11,16 +11,26 @@ export declare function isAcceptedType(file: File): boolean;
|
|
|
11
11
|
/**
|
|
12
12
|
* Generate the markdown insertion string for an uploaded file.
|
|
13
13
|
* Images use ``, all other files use `[name](url)`.
|
|
14
|
+
*
|
|
15
|
+
* Filenames and URLs are escaped to prevent markdown syntax injection:
|
|
16
|
+
* - `[` and `]` in filenames are backslash-escaped
|
|
17
|
+
* - `(` and `)` in URLs are percent-encoded
|
|
18
|
+
*
|
|
19
|
+
* Only `https:` and relative URLs are accepted. Dangerous schemes like
|
|
20
|
+
* `javascript:` or `data:` from a compromised upload endpoint are rejected
|
|
21
|
+
* and replaced with `#unsafe-url` so the markdown is never persisted with
|
|
22
|
+
* an executable URL.
|
|
14
23
|
*/
|
|
15
24
|
export declare function fileToMarkdown(file: File, url: string): string;
|
|
16
25
|
/**
|
|
17
26
|
* Upload a single file to the given URL via XHR POST multipart/form-data.
|
|
18
27
|
*
|
|
19
28
|
* @param file The file to upload
|
|
20
|
-
* @param uploadUrl POST endpoint — must
|
|
29
|
+
* @param uploadUrl POST endpoint — must be an https: or relative URL.
|
|
30
|
+
* Must return `{ url: string }` on 2xx.
|
|
21
31
|
* @param onProgress Callback fired with progress 0–100 during upload
|
|
22
32
|
* @returns Resolves with the URL from the server response
|
|
23
|
-
* @throws Rejects with an
|
|
33
|
+
* @throws Rejects with an Error on failure or invalid URL
|
|
24
34
|
*/
|
|
25
35
|
export declare function uploadFile(file: File, uploadUrl: string, onProgress: (pct: number) => void): Promise<string>;
|
|
26
36
|
//# sourceMappingURL=upload.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"upload.d.ts","sourceRoot":"","sources":["../../src/upload.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAOH;;GAEG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAOlD;AAED
|
|
1
|
+
{"version":3,"file":"upload.d.ts","sourceRoot":"","sources":["../../src/upload.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAOH;;GAEG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAOlD;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,IAAI,EAAE,GAAG,EAAE,MAAM,GAAG,MAAM,CAU9D;AAED;;;;;;;;;GASG;AACH,wBAAgB,UAAU,CACxB,IAAI,EAAE,IAAI,EACV,SAAS,EAAE,MAAM,EACjB,UAAU,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,GAChC,OAAO,CAAC,MAAM,CAAC,CA+CjB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@duskmoon-dev/el-markdown-input",
|
|
3
|
-
"version": "0.11.
|
|
3
|
+
"version": "0.11.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/cjs/index.js",
|
|
6
6
|
"module": "./dist/esm/index.js",
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
"scripts": {
|
|
24
24
|
"prebuild": "bun run clean",
|
|
25
25
|
"build": "bun run build:esm && bun run build:cjs && bun run build:types",
|
|
26
|
-
"build:esm": "bun build ./src/index.ts ./src/register.ts --outdir ./dist/esm --format esm --sourcemap --external @duskmoon-dev/el-base --external @duskmoon-dev/core",
|
|
27
|
-
"build:cjs": "bun build ./src/index.ts ./src/register.ts --outdir ./dist/cjs --format cjs --sourcemap --external @duskmoon-dev/el-base --external @duskmoon-dev/core",
|
|
26
|
+
"build:esm": "bun build ./src/index.ts ./src/register.ts --outdir ./dist/esm --format esm --sourcemap --external @duskmoon-dev/el-base --external @duskmoon-dev/core --external unified --external remark-parse --external remark-gfm --external remark-math --external remark-rehype --external rehype-katex --external rehype-prism-plus --external rehype-sanitize --external rehype-stringify --external hast-util-sanitize --external mermaid",
|
|
27
|
+
"build:cjs": "bun build ./src/index.ts ./src/register.ts --outdir ./dist/cjs --format cjs --sourcemap --external @duskmoon-dev/el-base --external @duskmoon-dev/core --external unified --external remark-parse --external remark-gfm --external remark-math --external remark-rehype --external rehype-katex --external rehype-prism-plus --external rehype-sanitize --external rehype-stringify --external hast-util-sanitize --external mermaid",
|
|
28
28
|
"build:types": "tsc --emitDeclarationOnly --outDir ./dist/types",
|
|
29
29
|
"dev": "bun build ./src/index.ts --outdir ./dist/esm --format esm --sourcemap --external @duskmoon-dev/el-base --watch",
|
|
30
30
|
"clean": "del-cli dist",
|
|
@@ -39,8 +39,18 @@
|
|
|
39
39
|
"release:dry-run": "bun publish --dry-run"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"@duskmoon-dev/
|
|
43
|
-
"@duskmoon-dev/
|
|
42
|
+
"@duskmoon-dev/core": "^1.14.1",
|
|
43
|
+
"@duskmoon-dev/el-base": "0.11.0",
|
|
44
|
+
"hast-util-sanitize": "5.0.2",
|
|
45
|
+
"rehype-katex": "7.0.1",
|
|
46
|
+
"rehype-prism-plus": "2.0.2",
|
|
47
|
+
"rehype-sanitize": "6.0.0",
|
|
48
|
+
"rehype-stringify": "10.0.1",
|
|
49
|
+
"remark-gfm": "4.0.1",
|
|
50
|
+
"remark-math": "6.0.0",
|
|
51
|
+
"remark-parse": "11.0.0",
|
|
52
|
+
"remark-rehype": "11.1.2",
|
|
53
|
+
"unified": "11.0.5"
|
|
44
54
|
},
|
|
45
55
|
"devDependencies": {
|
|
46
56
|
"typescript": "^5.7.2"
|
|
@@ -60,5 +70,8 @@
|
|
|
60
70
|
"markdown",
|
|
61
71
|
"editor",
|
|
62
72
|
"markdown-editor"
|
|
63
|
-
]
|
|
73
|
+
],
|
|
74
|
+
"optionalDependencies": {
|
|
75
|
+
"mermaid": "11.13.0"
|
|
76
|
+
}
|
|
64
77
|
}
|