@xlxz/markdown-editor 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +1806 -0
- package/dist/index.d.ts +23 -0
- package/dist/index.js +1774 -0
- package/dist/plugins/attachment.d.ts +7 -0
- package/dist/plugins/base-extensions.d.ts +8 -0
- package/dist/plugins/close-brackets.d.ts +8 -0
- package/dist/plugins/expand-text.d.ts +11 -0
- package/dist/plugins/fold.d.ts +8 -0
- package/dist/plugins/hanging-indent.d.ts +7 -0
- package/dist/plugins/indent-guide.d.ts +7 -0
- package/dist/plugins/index.d.ts +22 -0
- package/dist/plugins/keymap.d.ts +8 -0
- package/dist/plugins/line-numbers.d.ts +7 -0
- package/dist/plugins/link-handler.d.ts +8 -0
- package/dist/plugins/list-continuation.d.ts +8 -0
- package/dist/plugins/live-preview.d.ts +8 -0
- package/dist/plugins/markdown-language.d.ts +8 -0
- package/dist/plugins/on-change.d.ts +7 -0
- package/dist/plugins/suggest.d.ts +16 -0
- package/dist/plugins/table-continuation.d.ts +9 -0
- package/dist/plugins/table.d.ts +7 -0
- package/dist/plugins/theme.d.ts +8 -0
- package/dist/plugins/types.d.ts +29 -0
- package/dist/table/copy-widget.d.ts +17 -0
- package/dist/table/detect.d.ts +15 -0
- package/dist/table/format.d.ts +15 -0
- package/dist/table/index.d.ts +6 -0
- package/dist/table/theme.d.ts +8 -0
- package/package.json +57 -0
- package/vendor/app.css +15715 -0
- package/vendor/enhance.js +641 -0
- package/vendor/i18n/en.json +2144 -0
- package/vendor/i18n/zh.json +2144 -0
- package/vendor/lib/codemirror.js +14806 -0
- package/vendor/lib/i18next.min.js +2654 -0
- package/vendor/lib/markdown.js +1717 -0
- package/vendor/lib/mathjax/output/chtml/fonts/tex.js +1 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_AMS-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Calligraphic-Bold.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Calligraphic-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Fraktur-Bold.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Fraktur-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Main-Bold.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Main-Italic.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Main-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Math-BoldItalic.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Math-Italic.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Math-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_SansSerif-Bold.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_SansSerif-Italic.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_SansSerif-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Script-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Size1-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Size2-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Size3-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Size4-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Typewriter-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Vector-Bold.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Vector-Regular.woff +0 -0
- package/vendor/lib/mathjax/output/chtml/fonts/woff-v2/MathJax_Zero.woff +0 -0
- package/vendor/lib/mathjax/tex-chtml-full.js +36 -0
- package/vendor/lib/meta.min.js +1 -0
- package/vendor/lib/modes.min.js +236 -0
- package/vendor/lib/turndown.js +679 -0
- package/vendor/mock.js +28 -0
- package/vendor/obsidian-app.patched.js +161786 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* xlxz-markdown-editor — 公开 API 入口
|
|
3
|
+
*
|
|
4
|
+
* @example
|
|
5
|
+
* import { createEditor } from 'xlxz-markdown-editor';
|
|
6
|
+
* const editor = createEditor(container, { doc: '# Hello' });
|
|
7
|
+
*
|
|
8
|
+
* @example 自定义插件组合
|
|
9
|
+
* import { createEditor, suggestPlugin, tablePlugin } from 'xlxz-markdown-editor';
|
|
10
|
+
* const editor = createEditor(container, { doc: '' });
|
|
11
|
+
* editor.use(tablePlugin);
|
|
12
|
+
*
|
|
13
|
+
* @example 注册补全 provider
|
|
14
|
+
* editor.registerSuggest({
|
|
15
|
+
* trigger: /\[\[(.*)$/,
|
|
16
|
+
* getSuggestions: (query) => backend.listLinkTargets().then(items => items.filter(...)),
|
|
17
|
+
* suffix: ']]',
|
|
18
|
+
* });
|
|
19
|
+
*/
|
|
20
|
+
export { createEditor, autoLoad } from './kernel.js';
|
|
21
|
+
export type { EditorBackend, EditorOptions, EditorInstance, EditorPlugin, PluginContext, LinkTarget, SuggestConfig, SuggestItem, I18nProvider, AssetLoader, AutoLoadOptions, } from './types.js';
|
|
22
|
+
export { livePreviewPlugin, markdownLanguagePlugin, hangingIndentPlugin, listContinuationPlugin, closeBracketsPlugin, expandTextPlugin, foldPlugin, lineNumbersPlugin, indentGuidePlugin, suggestPlugin, linkHandlerPlugin, attachmentPlugin, tablePlugin, tableContinuationPlugin, themePlugin, baseExtensionsPlugin, keymapPlugin, onChangePlugin, } from './plugins/index.js';
|
|
23
|
+
export type { CompletionProvider } from './plugins/types.js';
|