@linker-design-plus/tiny-peony 1.4.13 → 1.4.16

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.
Files changed (42) hide show
  1. package/dist/foundation/contentManager/contentManager.d.ts +0 -5
  2. package/dist/index.d.ts +27 -78
  3. package/dist/index.js +34 -42
  4. package/dist/index.mjs +3065 -4577
  5. package/dist/intersection/components/editor/context.d.ts +2 -128
  6. package/dist/intersection/components/editor/editor.d.ts +13 -53
  7. package/dist/intersection/components/editor/index.d.ts +27 -78
  8. package/dist/intersection/hooks/use-editor.d.ts +2 -3
  9. package/dist/plugins/AnchorTagPlugin/plugin.d.ts +0 -4
  10. package/dist/plugins/HomophonesTagPlugin/homophoner.vue.d.ts +2 -2
  11. package/dist/plugins/PronunciationTagPlugin/pronunciationor.vue.d.ts +2 -2
  12. package/dist/tiny-peony.css +1 -1
  13. package/dist/typings/actions/i-anchor.d.ts +0 -8
  14. package/dist/typings/intersection/editor.d.ts +3 -12
  15. package/dist/utils/dom.d.ts +1 -19
  16. package/dist/utils/shared.d.ts +0 -11
  17. package/package.json +1 -1
  18. package/dist/index.js.map +0 -1
  19. package/dist/index.mjs.map +0 -1
  20. package/dist/intersection/components/modals/Refine/RefineContent.d.ts +0 -20
  21. package/dist/intersection/components/modals/Refine/RefineGenerator.d.ts +0 -19
  22. package/dist/intersection/components/modals/Refine/RefineInput.d.ts +0 -18
  23. package/dist/intersection/components/modals/Refine/RefineShortcut.d.ts +0 -2
  24. package/dist/intersection/components/modals/Refine/RefineToolbar.d.ts +0 -2
  25. package/dist/intersection/components/modals/Refine/context.d.ts +0 -128
  26. package/dist/intersection/components/modals/Refine/icons/abort.vue.d.ts +0 -2
  27. package/dist/intersection/components/modals/Refine/icons/copy.vue.d.ts +0 -2
  28. package/dist/intersection/components/modals/Refine/icons/delete.vue.d.ts +0 -2
  29. package/dist/intersection/components/modals/Refine/icons/expand.vue.d.ts +0 -2
  30. package/dist/intersection/components/modals/Refine/icons/inexpand.vue.d.ts +0 -2
  31. package/dist/intersection/components/modals/Refine/icons/insert.vue.d.ts +0 -2
  32. package/dist/intersection/components/modals/Refine/icons/moreShortcut.vue.d.ts +0 -2
  33. package/dist/intersection/components/modals/Refine/icons/optimism.vue.d.ts +0 -2
  34. package/dist/intersection/components/modals/Refine/icons/prefix.vue.d.ts +0 -2
  35. package/dist/intersection/components/modals/Refine/icons/refresh.vue.d.ts +0 -2
  36. package/dist/intersection/components/modals/Refine/icons/replace.vue.d.ts +0 -2
  37. package/dist/intersection/components/modals/Refine/icons/send.vue.d.ts +0 -2
  38. package/dist/intersection/components/modals/Refine/index.d.ts +0 -3
  39. package/dist/intersection/components/modals/Refine/use-modal-pos.d.ts +0 -10
  40. package/dist/intersection/components/modals/Refine/use-range-highlight.d.ts +0 -6
  41. package/dist/intersection/hooks/use-copy.d.ts +0 -4
  42. package/dist/intersection/hooks/use-state.d.ts +0 -4
@@ -1,20 +0,0 @@
1
- import type { PropType } from 'vue';
2
- import { type RefineSingleContentContext } from './context';
3
- declare const RefineContent: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
4
- modelValue: {
5
- type: PropType<RefineSingleContentContext[]>;
6
- default: () => never[];
7
- };
8
- }>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
9
- 'update:modelValue': (val: string) => true;
10
- }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
11
- modelValue: {
12
- type: PropType<RefineSingleContentContext[]>;
13
- default: () => never[];
14
- };
15
- }>> & Readonly<{
16
- "onUpdate:modelValue"?: ((val: string) => any) | undefined;
17
- }>, {
18
- modelValue: RefineSingleContentContext[];
19
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
20
- export default RefineContent;
@@ -1,19 +0,0 @@
1
- declare const RefineGenerator: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
2
- width: {
3
- type: (StringConstructor | NumberConstructor)[];
4
- default: string;
5
- };
6
- }>, {
7
- innerRender: () => import("vue/jsx-runtime").JSX.Element;
8
- innerSetVisible: import("../../../hooks/use-state").SetStateAction<boolean>;
9
- }, {}, {}, {
10
- setVisible(visible: boolean): void;
11
- }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
12
- width: {
13
- type: (StringConstructor | NumberConstructor)[];
14
- default: string;
15
- };
16
- }>> & Readonly<{}>, {
17
- width: string | number;
18
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
19
- export default RefineGenerator;
@@ -1,18 +0,0 @@
1
- declare const RefineInput: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
2
- modelValue: {
3
- type: StringConstructor;
4
- default: undefined;
5
- };
6
- }>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
7
- 'update:modelValue': (val: string | undefined) => true;
8
- }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
9
- modelValue: {
10
- type: StringConstructor;
11
- default: undefined;
12
- };
13
- }>> & Readonly<{
14
- "onUpdate:modelValue"?: ((val: string | undefined) => any) | undefined;
15
- }>, {
16
- modelValue: string;
17
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
18
- export default RefineInput;
@@ -1,2 +0,0 @@
1
- declare const RefineShortcut: import("vue").DefineComponent<{}, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
- export default RefineShortcut;
@@ -1,2 +0,0 @@
1
- declare const RefineToolbar: import("vue").DefineComponent<{}, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
- export default RefineToolbar;
@@ -1,128 +0,0 @@
1
- import type { InjectionKey, Ref } from 'vue';
2
- import type { Action, Func, Predicate } from '@om-design/util';
3
- export interface RefineGeneratorContext {
4
- name: 'RefineGenerator';
5
- refineGeneratorRef: Ref<HTMLDivElement | undefined>;
6
- visible: Ref<boolean>;
7
- width: string;
8
- generating: Ref<boolean>;
9
- prompt: Ref<string | undefined>;
10
- shortcutVisible: Ref<boolean>;
11
- content: Ref<RefineSingleContentContext[]>;
12
- activedContent: Ref<RefineSingleContentContext | undefined>;
13
- contentVisible: Ref<boolean>;
14
- contentPage: Ref<number>;
15
- contentState: Ref<RefineContentState>;
16
- setVisible: Action<boolean>;
17
- setRefineGenerating: Predicate<boolean | undefined>;
18
- setRefinePrompt: Action<string | undefined>;
19
- setShortVisible: Func<boolean | undefined, boolean>;
20
- setRefineContent: Action<RefineSingleContentContext[]>;
21
- setActivedRefineContent: Action<RefineSingleContentContext>;
22
- genRefineContent: (data?: GenContentParams) => void;
23
- setContentVisible: Func<boolean | undefined, boolean>;
24
- setContentPage: Action<number>;
25
- setContentState: Action<RefineContentState>;
26
- showRefineGenerator: Action<void>;
27
- abortSession: () => Promise<any>;
28
- /** highlight */
29
- scrollElm: Ref<HTMLElement | undefined>;
30
- highlightRange: Action<void>;
31
- unhighlightRange: Action<void>;
32
- revertRange: Action<void>;
33
- /** modal position */
34
- generatorPosition: Ref<GeneratorPosEnum>;
35
- shortcutPosition: Ref<ShortcutPosEnum>;
36
- subShortcutPosition: Ref<SubShortcutPosEnum>;
37
- setGeneratorPosition: Action<GeneratorPosEnum>;
38
- setShortcutPosition: Action<ShortcutPosEnum>;
39
- setSubShortcutPosition: Action<SubShortcutPosEnum>;
40
- calcModalPosition: Action<void>;
41
- }
42
- export declare const refineGeneratorKey: InjectionKey<RefineGeneratorContext>;
43
- export declare enum RefineContentState {
44
- 未生成 = -1,
45
- 等待生成 = 0,
46
- 正在生成 = 1,
47
- 生成结束 = 2
48
- }
49
- export declare enum RefineGenerateType {
50
- 重置 = 0,
51
- 刷新 = 1
52
- }
53
- export declare enum RefineShortcutEunm {
54
- 润色 = "\u6DA6\u8272",
55
- 扩写 = "\u6269\u5199",
56
- 缩写 = "\u7F29\u5199",
57
- 更改语气 = "\u66F4\u6539\u8BED\u6C14",
58
- 更专业 = "\u66F4\u4E13\u4E1A",
59
- 更口语化 = "\u66F4\u53E3\u8BED\u5316",
60
- 更易读 = "\u66F4\u6613\u8BFB",
61
- 更含蓄 = "\u66F4\u542B\u84C4",
62
- 更学术 = "\u66F4\u5B66\u672F",
63
- 更有文采 = "\u66F4\u6709\u6587\u91C7",
64
- 更有网感 = "\u66F4\u6709\u7F51\u611F"
65
- }
66
- export declare const refineShortcutOptions: ({
67
- label: string;
68
- value: RefineShortcutEunm;
69
- icon: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
70
- children?: undefined;
71
- } | {
72
- label: string;
73
- value: RefineShortcutEunm;
74
- icon: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
75
- children: {
76
- label: string;
77
- icon: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
78
- value: RefineShortcutEunm;
79
- }[];
80
- })[];
81
- export interface GenContentParams {
82
- /**
83
- * 调优提示词
84
- */
85
- prompt?: string;
86
- /**
87
- * 调优快捷指令
88
- */
89
- shortcutType?: RefineShortcutEunm;
90
- /**
91
- * 调优类型
92
- */
93
- generateType?: RefineGenerateType;
94
- }
95
- export interface RefineSingleContentContext {
96
- /**
97
- * 是否是手动调优
98
- */
99
- isManualPrompt?: boolean;
100
- /**
101
- * 调优关键词
102
- */
103
- prompt?: string;
104
- /**
105
- * 调优快捷指令
106
- */
107
- shortcutType?: RefineShortcutEunm;
108
- /**
109
- * 调优生成内容
110
- */
111
- content?: string;
112
- }
113
- export declare enum ShortcutPosEnum {
114
- 底部 = 0,
115
- 顶部 = 1
116
- }
117
- export declare enum GeneratorPosEnum {
118
- 底部 = 0,
119
- 顶部 = 1
120
- }
121
- export declare enum SubShortcutPosEnum {
122
- 顶部对齐 = 0,
123
- 底部对齐 = 1
124
- }
125
- /**
126
- * 段落分隔符
127
- */
128
- export declare const SEPARATOR = "<br><br>";
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,2 +0,0 @@
1
- declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, SVGSVGElement>;
2
- export default _default;
@@ -1,3 +0,0 @@
1
- import RefineGenerator from './RefineGenerator';
2
- import './refine.less';
3
- export default RefineGenerator;
@@ -1,10 +0,0 @@
1
- import { GeneratorPosEnum, RefineGeneratorContext, ShortcutPosEnum, SubShortcutPosEnum } from './context';
2
- export declare const useModalPos: (ctx: Omit<RefineGeneratorContext, "generatorPosition" | "shortcutPosition" | "subShortcutPosition" | "setGeneratorPosition" | "setShortcutPosition" | "setSubShortcutPosition" | "calcModalPosition">) => {
3
- generatorPosition: import("vue").Ref<GeneratorPosEnum, GeneratorPosEnum>;
4
- shortcutPosition: import("vue").Ref<ShortcutPosEnum, ShortcutPosEnum>;
5
- subShortcutPosition: import("vue").Ref<SubShortcutPosEnum, SubShortcutPosEnum>;
6
- setGeneratorPosition: import("../../../hooks/use-state").SetStateAction<GeneratorPosEnum>;
7
- setShortcutPosition: import("../../../hooks/use-state").SetStateAction<ShortcutPosEnum>;
8
- setSubShortcutPosition: import("../../../hooks/use-state").SetStateAction<SubShortcutPosEnum>;
9
- calcModalPosition: () => void;
10
- };
@@ -1,6 +0,0 @@
1
- export declare const CLASS_RANGE_HIGHLIGHT = "tag-range-highlight";
2
- export declare const useRangeHighlight: () => {
3
- highlightRange: () => void;
4
- unhighlightRange: () => void;
5
- revertRange: () => void;
6
- };
@@ -1,4 +0,0 @@
1
- declare const useCopy: () => {
2
- textCopyFun: (key: string, showMessage?: boolean) => void;
3
- };
4
- export default useCopy;
@@ -1,4 +0,0 @@
1
- import type { Ref, UnwrapRef } from 'vue';
2
- export type SetStateAction<T> = (newValue: T) => void;
3
- export type SetStateCallback<T, K = void> = (_newValue: T) => K;
4
- export declare const useState: <T>(initialValue: T, callback?: SetStateCallback<T>, formatter?: SetStateCallback<T, T>) => [Ref<UnwrapRef<T>>, SetStateAction<T>];