@matechat/core 1.10.0 → 1.11.0-alpha.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.
Files changed (120) hide show
  1. package/Attachment/Attachment.vue.d.ts +121 -0
  2. package/Attachment/attachment-types.d.ts +103 -0
  3. package/Attachment/drop-area.vue.d.ts +13 -0
  4. package/Attachment/index.css +1 -1
  5. package/Attachment/index.d.ts +2 -0
  6. package/Attachment/index.js +211 -311
  7. package/Attachment/uploader.d.ts +11 -0
  8. package/Attachment/use-upload.d.ts +8 -0
  9. package/Bubble/Bubble.vue.d.ts +75 -0
  10. package/Bubble/BubbleLoading.vue.d.ts +3 -0
  11. package/Bubble/bubble-constants.d.ts +4 -0
  12. package/Bubble/bubble-types.d.ts +38 -0
  13. package/Bubble/components/Avatar.vue.d.ts +57 -0
  14. package/Bubble/components/AvatarBodyIcon.vue.d.ts +24 -0
  15. package/Bubble/components/AvatarNoBodyIcon.vue.d.ts +24 -0
  16. package/Bubble/components/avatar-types.d.ts +25 -0
  17. package/Bubble/index.css +1 -1
  18. package/Bubble/index.d.ts +2 -0
  19. package/Bubble/index.js +142 -148
  20. package/FileList/FileIcon/CodeFile.vue.d.ts +10 -0
  21. package/FileList/FileIcon/CompressedFile.vue.d.ts +10 -0
  22. package/FileList/FileIcon/DefaultFileIcon.vue.d.ts +10 -0
  23. package/FileList/FileIcon/Document.vue.d.ts +10 -0
  24. package/FileList/FileIcon/DrawingBoard.vue.d.ts +10 -0
  25. package/FileList/FileIcon/EmailFile.vue.d.ts +10 -0
  26. package/FileList/FileIcon/Excel.vue.d.ts +10 -0
  27. package/FileList/FileIcon/FlowChart.vue.d.ts +10 -0
  28. package/FileList/FileIcon/FolderClosed.vue.d.ts +10 -0
  29. package/FileList/FileIcon/FolderOpen.vue.d.ts +10 -0
  30. package/FileList/FileIcon/Image.vue.d.ts +10 -0
  31. package/FileList/FileIcon/Markdown.vue.d.ts +10 -0
  32. package/FileList/FileIcon/Mind.vue.d.ts +10 -0
  33. package/FileList/FileIcon/Mp4.vue.d.ts +10 -0
  34. package/FileList/FileIcon/MultidimentionalTable.vue.d.ts +10 -0
  35. package/FileList/FileIcon/Page.vue.d.ts +10 -0
  36. package/FileList/FileIcon/Pdf.vue.d.ts +10 -0
  37. package/FileList/FileIcon/Ppt.vue.d.ts +10 -0
  38. package/FileList/FileIcon/Unknown.vue.d.ts +10 -0
  39. package/FileList/FileIcon/Wrong.vue.d.ts +10 -0
  40. package/FileList/FileList.vue.d.ts +36 -0
  41. package/FileList/fileList-types.d.ts +21 -0
  42. package/FileList/index.d.ts +2 -0
  43. package/FileList/index.js +220 -228
  44. package/Header/Header.vue.d.ts +47 -0
  45. package/Header/header-types.d.ts +14 -0
  46. package/Header/index.d.ts +2 -0
  47. package/Header/index.js +0 -1
  48. package/Input/Input.vue.d.ts +165 -0
  49. package/Input/components/EditableBlock.vue.d.ts +101 -0
  50. package/Input/components/InputTag.vue.d.ts +30 -0
  51. package/Input/components/LoadingIcon.vue.d.ts +3 -0
  52. package/Input/components/SendIcon.vue.d.ts +3 -0
  53. package/Input/components/button.vue.d.ts +3 -0
  54. package/Input/components/textarea-utils.d.ts +17 -0
  55. package/Input/components/textarea.vue.d.ts +3 -0
  56. package/Input/components/use-textarea-autosize.d.ts +12 -0
  57. package/Input/components/util.d.ts +3 -0
  58. package/Input/index.css +1 -1
  59. package/Input/index.d.ts +2 -0
  60. package/Input/index.js +114 -252
  61. package/Input/input-types.d.ts +118 -0
  62. package/Introduction/Introduction.vue.d.ts +88 -0
  63. package/Introduction/index.css +1 -1
  64. package/Introduction/index.d.ts +2 -0
  65. package/Introduction/index.js +8 -9
  66. package/Introduction/introduction-types.d.ts +37 -0
  67. package/Layout/Aside.vue.d.ts +13 -0
  68. package/Layout/Content.vue.d.ts +13 -0
  69. package/Layout/Header.vue.d.ts +13 -0
  70. package/Layout/Layout.vue.d.ts +13 -0
  71. package/Layout/Sender.vue.d.ts +13 -0
  72. package/Layout/index.d.ts +6 -0
  73. package/Layout/index.js +0 -1
  74. package/List/List.vue.d.ts +98 -0
  75. package/List/const.d.ts +5 -0
  76. package/List/index.css +1 -1
  77. package/List/index.d.ts +3 -0
  78. package/List/index.js +51 -54
  79. package/List/list-types.d.ts +52 -0
  80. package/List/use-list.d.ts +13 -0
  81. package/Locale/i18n.d.ts +21 -0
  82. package/Locale/index.d.ts +7 -0
  83. package/Locale/index.js +35 -103
  84. package/Locale/lang/en-us.d.ts +34 -0
  85. package/Locale/lang/zh-cn.d.ts +34 -0
  86. package/MarkdownCard/CodeBlock.vue.d.ts +76 -0
  87. package/MarkdownCard/MDCardParser.d.ts +12 -0
  88. package/MarkdownCard/MDCardService.d.ts +14 -0
  89. package/MarkdownCard/MermaidService.d.ts +22 -0
  90. package/MarkdownCard/index.css +1 -1
  91. package/MarkdownCard/index.d.ts +2 -0
  92. package/MarkdownCard/index.js +205 -559
  93. package/MarkdownCard/mdCard.types.d.ts +88 -0
  94. package/MarkdownCard/mdCard.vue.d.ts +29 -0
  95. package/Mention/Mention.vue.d.ts +51 -0
  96. package/Mention/const.d.ts +4 -0
  97. package/Mention/index.d.ts +2 -0
  98. package/Mention/index.js +0 -1
  99. package/Mention/mention-types.d.ts +24 -0
  100. package/Mention/use-mention.d.ts +10 -0
  101. package/Prompt/Prompt.vue.d.ts +38 -0
  102. package/Prompt/PromptItem.vue.d.ts +11 -0
  103. package/Prompt/components/Icon.vue.d.ts +42 -0
  104. package/Prompt/components/icon-types.d.ts +18 -0
  105. package/Prompt/index.d.ts +2 -0
  106. package/Prompt/prompt-types.d.ts +33 -0
  107. package/README.md +12 -8
  108. package/Toolbar/Toolbar.vue.d.ts +68 -0
  109. package/Toolbar/icon/CopyIcon.vue.d.ts +42 -0
  110. package/Toolbar/icon/DeleteIcon.vue.d.ts +42 -0
  111. package/Toolbar/icon/DislikeIcon.vue.d.ts +46 -0
  112. package/Toolbar/icon/LikeIcon.vue.d.ts +46 -0
  113. package/Toolbar/icon/RefreshIcon.vue.d.ts +42 -0
  114. package/Toolbar/icon/ShareIcon.vue.d.ts +42 -0
  115. package/Toolbar/index.css +1 -0
  116. package/Toolbar/index.d.ts +8 -0
  117. package/Toolbar/index.js +519 -0
  118. package/Toolbar/toolbar.types.d.ts +60 -0
  119. package/mate-chat.js +0 -6
  120. package/package.json +4 -1
@@ -0,0 +1,47 @@
1
+ declare var __VLS_1: {};
2
+ type __VLS_Slots = {} & {
3
+ operationArea?: (props: typeof __VLS_1) => any;
4
+ };
5
+ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
6
+ logoImg: {
7
+ type: StringConstructor;
8
+ default: string;
9
+ };
10
+ title: {
11
+ type: StringConstructor;
12
+ default: string;
13
+ };
14
+ logoClickable: {
15
+ type: BooleanConstructor;
16
+ default: boolean;
17
+ };
18
+ }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
19
+ logoClicked: (...args: any[]) => void;
20
+ }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
21
+ logoImg: {
22
+ type: StringConstructor;
23
+ default: string;
24
+ };
25
+ title: {
26
+ type: StringConstructor;
27
+ default: string;
28
+ };
29
+ logoClickable: {
30
+ type: BooleanConstructor;
31
+ default: boolean;
32
+ };
33
+ }>> & Readonly<{
34
+ onLogoClicked?: ((...args: any[]) => any) | undefined;
35
+ }>, {
36
+ title: string;
37
+ logoImg: string;
38
+ logoClickable: boolean;
39
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
40
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
41
+ declare const _default: typeof __VLS_export;
42
+ export default _default;
43
+ type __VLS_WithSlots<T, S> = T & {
44
+ new (): {
45
+ $slots: S;
46
+ };
47
+ };
@@ -0,0 +1,14 @@
1
+ export declare const props: {
2
+ logoImg: {
3
+ type: StringConstructor;
4
+ default: string;
5
+ };
6
+ title: {
7
+ type: StringConstructor;
8
+ default: string;
9
+ };
10
+ logoClickable: {
11
+ type: BooleanConstructor;
12
+ default: boolean;
13
+ };
14
+ };
@@ -0,0 +1,2 @@
1
+ import McHeader from './Header.vue.ts';
2
+ export { McHeader };
package/Header/index.js CHANGED
@@ -1,4 +1,3 @@
1
- import "./index.css";
2
1
  import { defineComponent as d, createElementBlock as n, openBlock as r, createElementVNode as a, normalizeClass as m, createCommentVNode as g, toDisplayString as p, renderSlot as _ } from "vue";
3
2
  const k = {
4
3
  logoImg: {
@@ -0,0 +1,165 @@
1
+ import { DisplayType, InputVariant, FormatContentItem } from "./input-types";
2
+ declare var __VLS_1: {}, __VLS_3: {}, __VLS_18: {
3
+ themeTag: {
4
+ type: "themeTag";
5
+ themeTagKey?: string | undefined;
6
+ themeTagText: string;
7
+ clearInput?: boolean | undefined;
8
+ popoverContent: string;
9
+ };
10
+ }, __VLS_24: {}, __VLS_26: {}, __VLS_32: {}, __VLS_34: {};
11
+ type __VLS_Slots = {} & {
12
+ head?: (props: typeof __VLS_1) => any;
13
+ } & {
14
+ prefix?: (props: typeof __VLS_3) => any;
15
+ } & {
16
+ themeTag?: (props: typeof __VLS_18) => any;
17
+ } & {
18
+ suffix?: (props: typeof __VLS_24) => any;
19
+ } & {
20
+ button?: (props: typeof __VLS_26) => any;
21
+ } & {
22
+ extra?: (props: typeof __VLS_32) => any;
23
+ } & {
24
+ button?: (props: typeof __VLS_34) => any;
25
+ };
26
+ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
27
+ value: {
28
+ type: StringConstructor;
29
+ default: string;
30
+ };
31
+ formatContentOptions: {
32
+ type: import("vue").PropType<import("./input-types").FormatContentOptions>;
33
+ default: () => void;
34
+ };
35
+ placeholder: {
36
+ type: StringConstructor;
37
+ };
38
+ disabled: {
39
+ type: BooleanConstructor;
40
+ default: boolean;
41
+ };
42
+ displayType: {
43
+ type: import("vue").PropType<DisplayType>;
44
+ default: DisplayType;
45
+ };
46
+ variant: {
47
+ type: import("vue").PropType<InputVariant>;
48
+ default: InputVariant;
49
+ };
50
+ sendBtnVariant: {
51
+ type: import("vue").PropType<import("./input-types").SendBtnVariant>;
52
+ default: import("./input-types").SendBtnVariant;
53
+ };
54
+ loading: {
55
+ type: BooleanConstructor;
56
+ default: boolean;
57
+ };
58
+ showCount: {
59
+ type: BooleanConstructor;
60
+ default: boolean;
61
+ };
62
+ maxLength: {
63
+ type: NumberConstructor;
64
+ };
65
+ submitShortKey: {
66
+ type: import("vue").PropType<import("./input-types").SubmitShortKey | null>;
67
+ default: import("./input-types").SubmitShortKey;
68
+ };
69
+ autofocus: {
70
+ type: BooleanConstructor;
71
+ default: boolean;
72
+ };
73
+ autosize: {
74
+ type: import("vue").PropType<import("./input-types").TextareaAutoSize>;
75
+ default: boolean;
76
+ };
77
+ autoClear: {
78
+ type: BooleanConstructor;
79
+ default: boolean;
80
+ };
81
+ }>, {
82
+ clearInput: () => void;
83
+ getInput: () => any;
84
+ setInputTag: (key: string, placeholder: string, defaultValue?: string) => void;
85
+ setText: (text: string) => void;
86
+ setMixTags: (mixTagConfig: FormatContentItem[]) => void;
87
+ openTipTag: (themeTagText: string, popoverContent: string, clearInput?: boolean) => void;
88
+ closeTipTag: () => void;
89
+ }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
90
+ value: {
91
+ type: StringConstructor;
92
+ default: string;
93
+ };
94
+ formatContentOptions: {
95
+ type: import("vue").PropType<import("./input-types").FormatContentOptions>;
96
+ default: () => void;
97
+ };
98
+ placeholder: {
99
+ type: StringConstructor;
100
+ };
101
+ disabled: {
102
+ type: BooleanConstructor;
103
+ default: boolean;
104
+ };
105
+ displayType: {
106
+ type: import("vue").PropType<DisplayType>;
107
+ default: DisplayType;
108
+ };
109
+ variant: {
110
+ type: import("vue").PropType<InputVariant>;
111
+ default: InputVariant;
112
+ };
113
+ sendBtnVariant: {
114
+ type: import("vue").PropType<import("./input-types").SendBtnVariant>;
115
+ default: import("./input-types").SendBtnVariant;
116
+ };
117
+ loading: {
118
+ type: BooleanConstructor;
119
+ default: boolean;
120
+ };
121
+ showCount: {
122
+ type: BooleanConstructor;
123
+ default: boolean;
124
+ };
125
+ maxLength: {
126
+ type: NumberConstructor;
127
+ };
128
+ submitShortKey: {
129
+ type: import("vue").PropType<import("./input-types").SubmitShortKey | null>;
130
+ default: import("./input-types").SubmitShortKey;
131
+ };
132
+ autofocus: {
133
+ type: BooleanConstructor;
134
+ default: boolean;
135
+ };
136
+ autosize: {
137
+ type: import("vue").PropType<import("./input-types").TextareaAutoSize>;
138
+ default: boolean;
139
+ };
140
+ autoClear: {
141
+ type: BooleanConstructor;
142
+ default: boolean;
143
+ };
144
+ }>> & Readonly<{}>, {
145
+ variant: InputVariant;
146
+ value: string;
147
+ loading: boolean;
148
+ autofocus: boolean;
149
+ disabled: boolean;
150
+ autosize: import("./input-types").TextareaAutoSize;
151
+ formatContentOptions: import("./input-types").FormatContentOptions;
152
+ displayType: DisplayType;
153
+ sendBtnVariant: import("./input-types").SendBtnVariant;
154
+ showCount: boolean;
155
+ submitShortKey: import("./input-types").SubmitShortKey | null;
156
+ autoClear: boolean;
157
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
158
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
159
+ declare const _default: typeof __VLS_export;
160
+ export default _default;
161
+ type __VLS_WithSlots<T, S> = T & {
162
+ new (): {
163
+ $slots: S;
164
+ };
165
+ };
@@ -0,0 +1,101 @@
1
+ import { PropType } from "vue";
2
+ import { FormatContentItem, SubmitShortKey } from "../input-types";
3
+ declare var __VLS_6: {
4
+ themeTag: {
5
+ type: "themeTag";
6
+ themeTagKey?: string | undefined;
7
+ themeTagText: string;
8
+ clearInput?: boolean | undefined;
9
+ popoverContent: string;
10
+ };
11
+ };
12
+ type __VLS_Slots = {} & {
13
+ themeTag?: (props: typeof __VLS_6) => any;
14
+ };
15
+ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
16
+ templateParts: {
17
+ type: ArrayConstructor;
18
+ default: () => never[];
19
+ };
20
+ placeholder: {
21
+ type: StringConstructor;
22
+ default: string;
23
+ };
24
+ maxLength: {
25
+ type: NumberConstructor;
26
+ default: number;
27
+ };
28
+ disabled: {
29
+ type: BooleanConstructor;
30
+ default: boolean;
31
+ };
32
+ submitShortKey: {
33
+ type: PropType<SubmitShortKey | null>;
34
+ default: SubmitShortKey;
35
+ };
36
+ autofocus: {
37
+ type: BooleanConstructor;
38
+ default: boolean;
39
+ };
40
+ }>, {
41
+ clearInput: () => void;
42
+ getInput: () => any;
43
+ focusInput: () => void;
44
+ setMixTags: (mixTagConfig: FormatContentItem[]) => void;
45
+ setText: (text: string) => void;
46
+ setInputTag: (key: string, placeholder: string, defaultValue?: string) => void;
47
+ openTipTag: (themeTagText: string, popoverContent: string, clearInput?: boolean) => void;
48
+ closeTipTag: () => void;
49
+ }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
50
+ input: (...args: any[]) => void;
51
+ blur: (...args: any[]) => void;
52
+ focus: (...args: any[]) => void;
53
+ send: (...args: any[]) => void;
54
+ onBlockKeyArrowUp: (...args: any[]) => void;
55
+ }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
56
+ templateParts: {
57
+ type: ArrayConstructor;
58
+ default: () => never[];
59
+ };
60
+ placeholder: {
61
+ type: StringConstructor;
62
+ default: string;
63
+ };
64
+ maxLength: {
65
+ type: NumberConstructor;
66
+ default: number;
67
+ };
68
+ disabled: {
69
+ type: BooleanConstructor;
70
+ default: boolean;
71
+ };
72
+ submitShortKey: {
73
+ type: PropType<SubmitShortKey | null>;
74
+ default: SubmitShortKey;
75
+ };
76
+ autofocus: {
77
+ type: BooleanConstructor;
78
+ default: boolean;
79
+ };
80
+ }>> & Readonly<{
81
+ onInput?: ((...args: any[]) => any) | undefined;
82
+ onBlur?: ((...args: any[]) => any) | undefined;
83
+ onFocus?: ((...args: any[]) => any) | undefined;
84
+ onSend?: ((...args: any[]) => any) | undefined;
85
+ onOnBlockKeyArrowUp?: ((...args: any[]) => any) | undefined;
86
+ }>, {
87
+ autofocus: boolean;
88
+ disabled: boolean;
89
+ placeholder: string;
90
+ maxLength: number;
91
+ submitShortKey: SubmitShortKey | null;
92
+ templateParts: unknown[];
93
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
94
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
95
+ declare const _default: typeof __VLS_export;
96
+ export default _default;
97
+ type __VLS_WithSlots<T, S> = T & {
98
+ new (): {
99
+ $slots: S;
100
+ };
101
+ };
@@ -0,0 +1,30 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
2
+ content: StringConstructor;
3
+ placeholder: {
4
+ type: StringConstructor;
5
+ default: string;
6
+ };
7
+ disabled: {
8
+ type: BooleanConstructor;
9
+ default: boolean;
10
+ };
11
+ }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
12
+ change: (...args: any[]) => void;
13
+ }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
14
+ content: StringConstructor;
15
+ placeholder: {
16
+ type: StringConstructor;
17
+ default: string;
18
+ };
19
+ disabled: {
20
+ type: BooleanConstructor;
21
+ default: boolean;
22
+ };
23
+ }>> & Readonly<{
24
+ onChange?: ((...args: any[]) => any) | undefined;
25
+ }>, {
26
+ disabled: boolean;
27
+ placeholder: string;
28
+ }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
29
+ declare const _default: typeof __VLS_export;
30
+ export default _default;
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Textarea height calculation utilities
3
+ * Based on DevUI Vue and react-component
4
+ */
5
+ interface TextareaHeight {
6
+ height: string;
7
+ minHeight?: string;
8
+ overflowY?: string;
9
+ }
10
+ /**
11
+ * 计算 textarea 的高度
12
+ * @param targetElement - 目标 textarea 元素
13
+ * @param minRows - 最小行数
14
+ * @param maxRows - 最大行数
15
+ */
16
+ export declare function computeTextareaHeight(targetElement: HTMLTextAreaElement, minRows?: number, maxRows?: number): TextareaHeight;
17
+ export {};
@@ -0,0 +1,3 @@
1
+ declare const __VLS_export: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
@@ -0,0 +1,12 @@
1
+ import { type Ref } from 'vue';
2
+ import type { TextareaAutoSize } from '../input-types';
3
+ interface UseTextareaAutosizeOptions {
4
+ textareaRef: Ref<HTMLTextAreaElement | null>;
5
+ autosize: TextareaAutoSize;
6
+ }
7
+ interface UseTextareaAutosizeReturn {
8
+ textareaStyle: Ref<Record<string, string>>;
9
+ updateTextareaStyle: () => void;
10
+ }
11
+ export declare function useMcTextareaAutosize(options: UseTextareaAutosizeOptions): UseTextareaAutosizeReturn;
12
+ export {};
@@ -0,0 +1,3 @@
1
+ export declare function insertText(text: string): void;
2
+ export declare const handlePaste: (e: any) => void;
3
+ export declare const moveCursorToTextEnd: (inputWarp: HTMLElement) => void;
package/Input/index.css CHANGED
@@ -1 +1 @@
1
- @charset "UTF-8";.mc-textarea{width:100%;height:64px;padding:4px 0;color:var(--devui-text, #252b3a);font-size:var(--devui-font-size, 14px);background-color:var(--devui-form-control-bg, #ffffff);vertical-align:middle;outline:none;box-sizing:border-box;resize:none;border:none}.mc-textarea.mc-textarea-simple{height:32px}.mc-textarea.mc-textarea-disabled{color:var(--devui-disabled-text, #cfd0d3);background-color:var(--devui-disabled-bg, #f5f5f5);cursor:not-allowed}.mc-textarea::placeholder{color:var(--devui-placeholder, #babbc0)}.mc-button[data-v-dbbf3b38]{position:relative;display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;height:32px;line-height:1.5;color:var(--devui-light-text, #ffffff);font-size:var(--devui-font-size, 14px);padding:0 12px;border-radius:20px;background-color:var(--devui-primary, #5e7ce0);overflow:hidden;border:none;cursor:pointer;transition:background-color var(--devui-animation-duration-slow, .3s) var(--devui-animation-ease-in-out-smooth, cubic-bezier(.645, .045, .355, 1)),border-color var(--devui-animation-duration-slow, .3s) var(--devui-animation-ease-in-out-smooth, cubic-bezier(.645, .045, .355, 1)),color var(--devui-animation-duration-slow, .3s) var(--devui-animation-ease-in-out-smooth, cubic-bezier(.645, .045, .355, 1))}.mc-button.mc-button-loading svg[data-v-dbbf3b38]{animation:rotating-dbbf3b38 1s linear infinite}.mc-button.mousedown[data-v-dbbf3b38]:not(:disabled){transform:scale(.95)}.mc-button.mc-button-simple[data-v-dbbf3b38]{width:32px;padding:6px;flex-shrink:0;border-radius:100%}.mc-button.mc-button-simple svg[data-v-dbbf3b38]{margin-right:0}.mc-button[data-v-dbbf3b38]:hover{background-color:var(--devui-primary-hover, #7693f5)}.mc-button[data-v-dbbf3b38]:active{background-color:var(--devui-primary-active, #344899)}.mc-button[data-v-dbbf3b38]:disabled{color:var(--devui-light-text, #ffffff);background-color:var(--devui-primary-disabled, #beccfa);cursor:not-allowed}.mc-button .mc-button-content[data-v-dbbf3b38]{display:inline-flex;align-items:center;font-size:var(--devui-font-size, 14px)}.mc-button .mc-button-water-wave[data-v-dbbf3b38]{position:absolute;background-color:var(--devui-base-bg, #ffffff);border-radius:50%;opacity:0;width:20px;height:20px;transform:translate(-50%,-50%);animation:waterWave-dbbf3b38 var(--devui-animation-duration-slow, .3s) var(--devui-animation-linear, cubic-bezier(0, 0, 1, 1))}.mc-button svg[data-v-dbbf3b38]{margin-right:4px}.mc-button svg[data-v-dbbf3b38] path{fill:var(--devui-light-text, #ffffff)}@keyframes rotating-dbbf3b38{0%{transform:rotate(0)}to{transform:rotate(180deg)}}@keyframes waterWave-dbbf3b38{0%{opacity:.2;width:30px;height:30px}to{opacity:0;width:200px;height:200px}}body[ui-theme=infinity-theme]{--mc-text: #aeaeae;--mc-box-shadow: rgba(25, 25, 25, .06)}body[ui-theme=galaxy-theme]{--mc-text: #4e5057;--mc-box-shadow: rgba(206, 209, 219, .06)}.mc-input{display:flex;flex-direction:column;width:100%;padding:12px 0;border:1px solid var(--devui-form-control-line, #d7d8da);border-radius:16px;box-sizing:border-box;background-color:var(--devui-base-bg, #ffffff)}.mc-input.mc-input-simple{border-radius:24px}.mc-input.mc-input-simple .mc-input-content{padding:0 20px}.mc-input.mc-input-borderless{border:none;box-shadow:0 1px 8px 0 var(--mc-box-shadow, rgba(25, 25, 25, .06))}.mc-input.mc-input-disabled{background-color:var(--devui-disabled-bg, #f5f5f5);cursor:not-allowed}.mc-input .mc-input-content{display:flex;align-items:flex-end;padding:0 16px}.mc-input .mc-input-foot{display:flex;justify-content:space-between;align-items:center;height:32px;padding:0 16px}.mc-input .mc-input-foot .mc-input-foot-left{flex:1;height:100%;display:flex;align-items:center}.mc-input .mc-input-foot .mc-input-foot-left .mc-input-foot-count{color:var(--mc-text, #aeaeae);font-size:var(--devui-font-size-sm, 12px)}
1
+ .mc-textarea{width:100%;height:64px;padding:4px 0;color:var(--devui-text, #252b3a);background-color:var(--devui-form-control-bg, #ffffff);vertical-align:middle;outline:none;box-sizing:border-box;resize:none;border:none}.mc-textarea.mc-textarea-simple{height:32px}.mc-textarea.mc-textarea-disabled{color:var(--devui-disabled-text, #cfd0d3);background-color:var(--devui-disabled-bg, #f5f5f5);cursor:not-allowed}.mc-textarea::placeholder{color:var(--devui-placeholder, #babbc0)}.mc-button[data-v-8051c2d3]{position:relative;display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;min-width:64px;height:32px;line-height:1.5;color:var(--devui-light-text, #ffffff);font-size:var(--devui-font-size-md, 12px);padding:0 16px;border-radius:20px;background-color:var(--devui-primary, #5e7ce0);overflow:hidden;border:none;cursor:pointer;transition:background-color var(--devui-animation-duration-slow, .3s) var(--devui-animation-ease-in-out-smooth, cubic-bezier(.645, .045, .355, 1)),border-color var(--devui-animation-duration-slow, .3s) var(--devui-animation-ease-in-out-smooth, cubic-bezier(.645, .045, .355, 1)),color var(--devui-animation-duration-slow, .3s) var(--devui-animation-ease-in-out-smooth, cubic-bezier(.645, .045, .355, 1))}.mc-button.mc-button-loading svg[data-v-8051c2d3]{animation:rotating-8051c2d3 1s linear infinite}.mc-button.mousedown[data-v-8051c2d3]:not(:disabled){transform:scale(.95)}.mc-button[data-v-8051c2d3]:hover{background-color:var(--devui-primary-hover, #7693f5)}.mc-button[data-v-8051c2d3]:active{background-color:var(--devui-primary-active, #344899)}.mc-button[data-v-8051c2d3]:disabled{color:var(--devui-light-text, #ffffff);background-color:var(--devui-primary-disabled, #beccfa);cursor:not-allowed}.mc-button .mc-button-content[data-v-8051c2d3]{display:inline-flex;align-items:center}.mc-button .mc-button-water-wave[data-v-8051c2d3]{position:absolute;background-color:var(--devui-base-bg, #ffffff);border-radius:50%;opacity:0;width:20px;height:20px;transform:translate(-50%,-50%);animation:waterWave-8051c2d3 var(--devui-animation-duration-slow, .3s) var(--devui-animation-linear, cubic-bezier(0, 0, 1, 1))}.mc-button svg[data-v-8051c2d3]{margin-right:4px}.mc-button svg[data-v-8051c2d3] path{fill:var(--devui-light-text, #ffffff)}@keyframes rotating-8051c2d3{0%{transform:rotate(0)}to{transform:rotate(180deg)}}@keyframes waterWave-8051c2d3{0%{opacity:.2;width:30px;height:30px}to{opacity:0;width:200px;height:200px}}.mc-input{display:flex;flex-direction:column;width:100%;padding:4px 0;border:1px solid var(--devui-form-control-line, #d7d8da);border-radius:14px;box-sizing:border-box}.mc-input.mc-input-disabled{background-color:var(--devui-disabled-bg, #f5f5f5);cursor:not-allowed}.mc-input .mc-input-content{display:flex;align-items:flex-end;padding:0 8px}.mc-input .mc-input-foot{display:flex;justify-content:space-between;align-items:center;height:32px;padding:0 8px}.mc-input .mc-input-foot .mc-input-foot-left{flex:1;height:100%;display:flex;align-items:center}.mc-input .mc-input-foot .mc-input-foot-left .mc-input-foot-count{color:var(--devui-text, #252b3a);font-size:var(--devui-font-size, 12px)}
@@ -0,0 +1,2 @@
1
+ import McInput from './Input.vue.ts';
2
+ export { McInput };