@linker-design-plus/tiny-peony 1.4.30 → 1.4.33

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.
@@ -93,7 +93,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
93
93
  innerAddExtraAnchors: (data: IAnchor[]) => void;
94
94
  innerUpdateAnchor: (newAnchor: IAnchor) => void;
95
95
  innerClearContent: () => void;
96
- innerInsertContentAtCursor: (_content: string | string[]) => void;
96
+ innerInsertContentAtCursor: (_content: string | string[], func?: (canInsert: boolean) => void) => void;
97
97
  innerRenderHightlight: (matchingContent: string) => void;
98
98
  innerUnrenderHightlight: () => void;
99
99
  }, {}, {}, {
@@ -117,7 +117,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
117
117
  addExtraAnchors(data: IAnchor[]): void;
118
118
  updateAnchor(anchor: IAnchor): void;
119
119
  clearContent(): void;
120
- insertContentAtCursor(_content: string | string[]): void;
120
+ insertContentAtCursor(_content: string | string[], callback?: (canInsert: boolean) => void): void;
121
121
  clear(): Promise<void>;
122
122
  renderHighlight(matchingContent: string): void;
123
123
  unrenderHighlight(): void;
@@ -94,7 +94,7 @@ declare const EditorContainer: {
94
94
  innerAddExtraAnchors: (data: import("../../..").IAnchor[]) => void;
95
95
  innerUpdateAnchor: (newAnchor: import("../../..").IAnchor) => void;
96
96
  innerClearContent: () => void;
97
- innerInsertContentAtCursor: (_content: string | string[]) => void;
97
+ innerInsertContentAtCursor: (_content: string | string[], func?: (canInsert: boolean) => void) => void;
98
98
  innerRenderHightlight: (matchingContent: string) => void;
99
99
  innerUnrenderHightlight: () => void;
100
100
  }, {}, {}, {
@@ -118,7 +118,7 @@ declare const EditorContainer: {
118
118
  addExtraAnchors(data: import("../../..").IAnchor[]): void;
119
119
  updateAnchor(anchor: import("../../..").IAnchor): void;
120
120
  clearContent(): void;
121
- insertContentAtCursor(_content: string | string[]): void;
121
+ insertContentAtCursor(_content: string | string[], callback?: (canInsert: boolean) => void): void;
122
122
  clear(): Promise<void>;
123
123
  renderHighlight(matchingContent: string): void;
124
124
  unrenderHighlight(): void;
@@ -244,7 +244,7 @@ declare const EditorContainer: {
244
244
  innerAddExtraAnchors: (data: import("../../..").IAnchor[]) => void;
245
245
  innerUpdateAnchor: (newAnchor: import("../../..").IAnchor) => void;
246
246
  innerClearContent: () => void;
247
- innerInsertContentAtCursor: (_content: string | string[]) => void;
247
+ innerInsertContentAtCursor: (_content: string | string[], func?: (canInsert: boolean) => void) => void;
248
248
  innerRenderHightlight: (matchingContent: string) => void;
249
249
  innerUnrenderHightlight: () => void;
250
250
  }, {}, {}, {
@@ -268,7 +268,7 @@ declare const EditorContainer: {
268
268
  addExtraAnchors(data: import("../../..").IAnchor[]): void;
269
269
  updateAnchor(anchor: import("../../..").IAnchor): void;
270
270
  clearContent(): void;
271
- insertContentAtCursor(_content: string | string[]): void;
271
+ insertContentAtCursor(_content: string | string[], callback?: (canInsert: boolean) => void): void;
272
272
  clear(): Promise<void>;
273
273
  renderHighlight(matchingContent: string): void;
274
274
  unrenderHighlight(): void;
@@ -384,7 +384,7 @@ declare const EditorContainer: {
384
384
  innerAddExtraAnchors: (data: import("../../..").IAnchor[]) => void;
385
385
  innerUpdateAnchor: (newAnchor: import("../../..").IAnchor) => void;
386
386
  innerClearContent: () => void;
387
- innerInsertContentAtCursor: (_content: string | string[]) => void;
387
+ innerInsertContentAtCursor: (_content: string | string[], func?: (canInsert: boolean) => void) => void;
388
388
  innerRenderHightlight: (matchingContent: string) => void;
389
389
  innerUnrenderHightlight: () => void;
390
390
  }, {}, {}, {
@@ -408,7 +408,7 @@ declare const EditorContainer: {
408
408
  addExtraAnchors(data: import("../../..").IAnchor[]): void;
409
409
  updateAnchor(anchor: import("../../..").IAnchor): void;
410
410
  clearContent(): void;
411
- insertContentAtCursor(_content: string | string[]): void;
411
+ insertContentAtCursor(_content: string | string[], callback?: (canInsert: boolean) => void): void;
412
412
  clear(): Promise<void>;
413
413
  renderHighlight(matchingContent: string): void;
414
414
  unrenderHighlight(): void;
@@ -50,7 +50,7 @@ export declare const useEditor: (editor: Ref<HTMLDivElement | undefined>, props:
50
50
  isAllMarkedByAnchor: () => boolean;
51
51
  addExtraAnchors: (data: IAnchor[]) => void;
52
52
  clearContent: () => void;
53
- insertContentAtCursor: (_content: string | string[]) => void;
53
+ insertContentAtCursor: (_content: string | string[], func?: (canInsert: boolean) => void) => void;
54
54
  renderHighlight: (matchingContent: string) => void;
55
55
  unrenderHighlight: () => void;
56
56
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@linker-design-plus/tiny-peony",
3
- "version": "1.4.30",
3
+ "version": "1.4.33",
4
4
  "description": "a simple editor",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -8,6 +8,11 @@
8
8
  "registry": "https://registry.npmjs.org/",
9
9
  "access": "public"
10
10
  },
11
+ "scripts": {
12
+ "startup": "pnpm build",
13
+ "build": "pnpm clean && vue-tsc --noEmit && vite build && vue-tsc --declaration --emitDeclarationOnly --outDir dist",
14
+ "clean": "rm -rf dist"
15
+ },
11
16
  "files": [
12
17
  "dist"
13
18
  ],
@@ -35,10 +40,5 @@
35
40
  "typescript": "^5.7.2",
36
41
  "vite": "^6.0.7",
37
42
  "vue-tsc": "^2.2.0"
38
- },
39
- "scripts": {
40
- "startup": "pnpm build",
41
- "build": "pnpm clean && vue-tsc --noEmit && vite build && vue-tsc --declaration --emitDeclarationOnly --outDir dist",
42
- "clean": "rm -rf dist"
43
43
  }
44
44
  }