@kernelift/markdown 1.1.3 → 1.1.4

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/README.md CHANGED
@@ -242,21 +242,6 @@ const isDark = ref(true);
242
242
  </template>
243
243
  ```
244
244
 
245
- ### 使用简化版组件
246
-
247
- ```vue
248
- <script setup lang="ts">
249
- import { ref } from 'vue';
250
- import { MdRenderSimple } from '@kernelift/markdown';
251
-
252
- const content = ref('# Hello World');
253
- </script>
254
-
255
- <template>
256
- <MdRenderSimple v-model="content" />
257
- </template>
258
- ```
259
-
260
245
  ## Props
261
246
 
262
247
  | 参数 | 说明 | 类型 | 默认值 |
@@ -295,20 +280,6 @@ const content = ref('# Hello World');
295
280
  | renderInstance | MarkdownIt 实例 | `ShallowRef<MarkdownIt \| undefined>` |
296
281
  | execMethods | 执行 MarkdownIt 实例方法 | `(fn: (renderInstance: MarkdownIt) => void) => void` |
297
282
 
298
- ## 组件对比
299
-
300
- | 特性 | MdRender | MdRenderSimple |
301
- | ---------- | -------- | -------------- |
302
- | 完整样式 | ✅ | ❌ |
303
- | 暗黑模式 | ✅ | ❌ |
304
- | 表格美化 | ✅ | ✅ |
305
- | 代码高亮 | ✅ | ✅ |
306
- | 代码块折叠 | ✅ | ✅ |
307
- | 代码块复制 | ✅ | ✅ |
308
- | 行号显示 | ✅ | ✅ |
309
- | 滚动同步 | ✅ | ✅ |
310
- | 体积 | 较大 | 较小 |
311
-
312
283
  ## 样式说明
313
284
 
314
285
  ### 内置样式
package/dist/index.d.ts CHANGED
@@ -15,27 +15,13 @@ declare type __VLS_Props = {
15
15
  collapseText?: string;
16
16
  codeMaxHeight?: number;
17
17
  afterRender?: (md: default_2) => void;
18
- };
19
-
20
- declare type __VLS_Props_2 = {
21
- modelValue: string;
22
- plugins?: Array<any>;
23
- options?: MarkdownItOptions;
24
- onCopy?: (code: string) => void;
25
- copyText?: string;
26
- expandText?: string;
27
- collapseText?: string;
28
- codeMaxHeight?: number;
18
+ themeMode?: 'light' | 'dark';
29
19
  };
30
20
 
31
21
  declare type __VLS_PublicProps = {
32
22
  modelValue?: string;
33
23
  } & __VLS_Props;
34
24
 
35
- declare type __VLS_PublicProps_2 = {
36
- modelValue?: string;
37
- } & __VLS_Props_2;
38
-
39
25
  export { MarkdownItOptions }
40
26
 
41
27
  export declare const MdRender: DefineComponent<__VLS_PublicProps, {
@@ -52,24 +38,7 @@ copyText: string;
52
38
  expandText: string;
53
39
  collapseText: string;
54
40
  codeMaxHeight: number;
55
- }, {}, {}, {}, string, ComponentProvideOptions, false, {
56
- containerRef: HTMLDivElement;
57
- }, HTMLElement>;
58
-
59
- export declare const MdRenderSimple: DefineComponent<__VLS_PublicProps_2, {
60
- renderInstance: ShallowRef<default_2 | undefined, default_2 | undefined>;
61
- execMethods: (fn: (renderInstance: default_2) => void) => void;
62
- }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
63
- "update:modelValue": (value: string) => any;
64
- }, string, PublicProps, Readonly<__VLS_PublicProps_2> & Readonly<{
65
- "onUpdate:modelValue"?: ((value: string) => any) | undefined;
66
- }>, {
67
- plugins: Array<any>;
68
- options: MarkdownItOptions;
69
- copyText: string;
70
- expandText: string;
71
- collapseText: string;
72
- codeMaxHeight: number;
41
+ themeMode: "light" | "dark";
73
42
  }, {}, {}, {}, string, ComponentProvideOptions, false, {
74
43
  containerRef: HTMLDivElement;
75
44
  }, HTMLElement>;