@opentiny/tiny-robot 0.3.1-alpha.4 → 0.3.1-alpha.5
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/action-group/index.js +1 -1
- package/dist/base-popper/index.js +1 -1
- package/dist/bubble/index.js +317 -317
- package/dist/chat-input/index.js +3151 -0
- package/dist/chat-input-actions/index.js +13 -0
- package/dist/drag-overlay/index.js +5 -5
- package/dist/dropdown-menu/index.js +5 -5
- package/dist/flow-layout-buttons/index.js +1 -1
- package/dist/history/index.js +1 -1
- package/dist/index.d.ts +2244 -1179
- package/dist/index.js +133 -101
- package/dist/index2.js +183 -285
- package/dist/index3.js +250 -683
- package/dist/index4.js +729 -147
- package/dist/index5.js +301 -0
- package/dist/index6.js +161 -0
- package/dist/mcp-add-form/index.js +1 -1
- package/dist/mcp-server-picker/index.js +1 -1
- package/dist/sender/index.js +6 -1481
- package/dist/sender-compat/index.js +233 -0
- package/dist/style.css +1 -1
- package/dist/suggestion-pills/index.js +1 -1
- package/dist/suggestion-popover/index.js +2 -2
- package/dist/useSlotRefs.js +3 -3
- package/dist/utils.js +1 -1
- package/package.json +13 -3
package/dist/index.d.ts
CHANGED
|
@@ -15,13 +15,15 @@ import { CSSProperties } from 'vue';
|
|
|
15
15
|
import { DebuggerEvent } from 'vue';
|
|
16
16
|
import { DefineComponent } from 'vue';
|
|
17
17
|
import { Directive } from 'vue';
|
|
18
|
-
import {
|
|
18
|
+
import { Editor } from '@tiptap/vue-3';
|
|
19
|
+
import { Editor as Editor_2 } from '@tiptap/core';
|
|
20
|
+
import { Extension } from '@tiptap/core';
|
|
19
21
|
import { GlobalComponents } from 'vue';
|
|
20
22
|
import { GlobalDirectives } from 'vue';
|
|
21
23
|
import { nextTick } from 'vue';
|
|
24
|
+
import { Node as Node_2 } from '@tiptap/core';
|
|
22
25
|
import { OnCleanup } from '@vue/reactivity';
|
|
23
26
|
import { Options } from 'markdown-it';
|
|
24
|
-
import { PropType } from 'vue';
|
|
25
27
|
import { PublicProps } from 'vue';
|
|
26
28
|
import { Ref } from 'vue';
|
|
27
29
|
import { RendererElement } from 'vue';
|
|
@@ -29,6 +31,7 @@ import { RendererNode } from 'vue';
|
|
|
29
31
|
import { ShallowUnwrapRef } from 'vue';
|
|
30
32
|
import { Slot } from 'vue';
|
|
31
33
|
import { TransitionProps } from 'vue';
|
|
34
|
+
import { UseFileDialogOptions } from '@vueuse/core';
|
|
32
35
|
import { VNode } from 'vue';
|
|
33
36
|
import { VNodeProps } from 'vue';
|
|
34
37
|
import { WatchOptions } from 'vue';
|
|
@@ -192,6 +195,34 @@ declare const __VLS_component_12: DefineComponent<WelcomeProps, {}, {}, {}, {},
|
|
|
192
195
|
align: "left" | "center" | "right" | string;
|
|
193
196
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
194
197
|
|
|
198
|
+
declare const __VLS_component_13: DefineComponent<ActionButtonProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<ActionButtonProps> & Readonly<{}>, {
|
|
199
|
+
size: string | number;
|
|
200
|
+
disabled: boolean;
|
|
201
|
+
active: boolean;
|
|
202
|
+
tooltipPlacement: TooltipPlacement;
|
|
203
|
+
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
204
|
+
|
|
205
|
+
declare const __VLS_component_14: DefineComponent<VoiceButtonProps, {
|
|
206
|
+
start: () => void;
|
|
207
|
+
stop: () => void;
|
|
208
|
+
speechState: SpeechState;
|
|
209
|
+
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
210
|
+
"speech-start": () => any;
|
|
211
|
+
"speech-interim": (transcript: string) => any;
|
|
212
|
+
"speech-final": (transcript: string) => any;
|
|
213
|
+
"speech-end": (transcript?: string | undefined) => any;
|
|
214
|
+
"speech-error": (error: Error) => any;
|
|
215
|
+
}, string, PublicProps, Readonly<VoiceButtonProps> & Readonly<{
|
|
216
|
+
"onSpeech-start"?: (() => any) | undefined;
|
|
217
|
+
"onSpeech-interim"?: ((transcript: string) => any) | undefined;
|
|
218
|
+
"onSpeech-final"?: ((transcript: string) => any) | undefined;
|
|
219
|
+
"onSpeech-end"?: ((transcript?: string | undefined) => any) | undefined;
|
|
220
|
+
"onSpeech-error"?: ((error: Error) => any) | undefined;
|
|
221
|
+
}>, {
|
|
222
|
+
tooltipPlacement: TooltipPlacement;
|
|
223
|
+
autoInsert: boolean;
|
|
224
|
+
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
225
|
+
|
|
195
226
|
declare const __VLS_component_2: DefineComponent<__VLS_Props, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
196
227
|
contentRenderers: Record<string, BubbleContentRenderer>;
|
|
197
228
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
@@ -325,14 +356,14 @@ declare const __VLS_component_6: DefineComponent<PromptsProps, {}, {}, {}, {}, C
|
|
|
325
356
|
"onItem-click"?: ((ev: MouseEvent, item: PromptProps) => any) | undefined;
|
|
326
357
|
}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
327
358
|
|
|
328
|
-
declare const __VLS_component_7: DefineComponent<
|
|
359
|
+
declare const __VLS_component_7: DefineComponent<SenderProps_2, {
|
|
329
360
|
focus: () => void;
|
|
330
361
|
blur: () => void;
|
|
331
362
|
clear: () => void;
|
|
332
363
|
submit: () => void;
|
|
364
|
+
setTemplateData: (templateData: UserTemplateItem[]) => void;
|
|
333
365
|
startSpeech: () => void;
|
|
334
366
|
stopSpeech: () => void;
|
|
335
|
-
activateTemplateFirstField: () => void;
|
|
336
367
|
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
337
368
|
clear: () => any;
|
|
338
369
|
blur: (event: FocusEvent) => any;
|
|
@@ -340,544 +371,263 @@ cancel: () => any;
|
|
|
340
371
|
focus: (event: FocusEvent) => any;
|
|
341
372
|
submit: (value: string) => any;
|
|
342
373
|
"update:modelValue": (value: string) => any;
|
|
343
|
-
"update:templateData": (value: UserItem[]) => any;
|
|
344
374
|
"speech-start": () => any;
|
|
345
|
-
"speech-end": (transcript?: string | undefined) => any;
|
|
346
375
|
"speech-interim": (transcript: string) => any;
|
|
376
|
+
"speech-end": (transcript?: string | undefined) => any;
|
|
347
377
|
"speech-error": (error: Error) => any;
|
|
378
|
+
"update:templateData": (value: UserItem[]) => any;
|
|
348
379
|
"suggestion-select": (value: string) => any;
|
|
349
380
|
"escape-press": () => any;
|
|
350
381
|
"reset-template": () => any;
|
|
351
382
|
"files-selected": (files: File[]) => any;
|
|
352
|
-
}, string, PublicProps, Readonly<
|
|
383
|
+
}, string, PublicProps, Readonly<SenderProps_2> & Readonly<{
|
|
353
384
|
onClear?: (() => any) | undefined;
|
|
354
385
|
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
355
386
|
onCancel?: (() => any) | undefined;
|
|
356
387
|
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
357
388
|
onSubmit?: ((value: string) => any) | undefined;
|
|
358
389
|
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
359
|
-
"onUpdate:templateData"?: ((value: UserItem[]) => any) | undefined;
|
|
360
390
|
"onSpeech-start"?: (() => any) | undefined;
|
|
361
|
-
"onSpeech-end"?: ((transcript?: string | undefined) => any) | undefined;
|
|
362
391
|
"onSpeech-interim"?: ((transcript: string) => any) | undefined;
|
|
392
|
+
"onSpeech-end"?: ((transcript?: string | undefined) => any) | undefined;
|
|
363
393
|
"onSpeech-error"?: ((error: Error) => any) | undefined;
|
|
394
|
+
"onUpdate:templateData"?: ((value: UserItem[]) => any) | undefined;
|
|
364
395
|
"onSuggestion-select"?: ((value: string) => any) | undefined;
|
|
365
396
|
"onEscape-press"?: (() => any) | undefined;
|
|
366
397
|
"onReset-template"?: (() => any) | undefined;
|
|
367
398
|
"onFiles-selected"?: ((files: File[]) => any) | undefined;
|
|
368
399
|
}>, {
|
|
369
|
-
|
|
370
|
-
|
|
400
|
+
placeholder: string;
|
|
401
|
+
mode: InputMode_2;
|
|
402
|
+
submitType: SubmitTrigger_2;
|
|
403
|
+
}, {}, {}, {}, string, ComponentProvideOptions, false, {
|
|
404
|
+
chatInputRef: ({
|
|
405
|
+
$: ComponentInternalInstance;
|
|
406
|
+
$data: {};
|
|
407
|
+
$props: {
|
|
408
|
+
readonly modelValue?: string | undefined;
|
|
409
|
+
readonly defaultValue?: string | undefined;
|
|
410
|
+
readonly placeholder?: string | undefined;
|
|
411
|
+
readonly disabled?: boolean | undefined;
|
|
412
|
+
readonly loading?: boolean | undefined;
|
|
413
|
+
readonly autofocus?: boolean | undefined;
|
|
414
|
+
readonly mode?: InputMode | undefined;
|
|
415
|
+
readonly autoSize?: AutoSize | undefined;
|
|
416
|
+
readonly maxLength?: number | undefined;
|
|
417
|
+
readonly showWordLimit?: boolean | undefined;
|
|
418
|
+
readonly clearable?: boolean | undefined;
|
|
419
|
+
readonly extensions?: Extension[] | any[] | undefined;
|
|
420
|
+
readonly size?: "normal" | "small" | undefined;
|
|
421
|
+
readonly stopText?: string | undefined;
|
|
422
|
+
readonly defaultActions?: DefaultActions | undefined;
|
|
423
|
+
readonly submitType?: SubmitTrigger | undefined;
|
|
424
|
+
readonly onClear?: (() => any) | undefined;
|
|
425
|
+
readonly onInput?: ((value: string) => any) | undefined;
|
|
426
|
+
readonly onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
427
|
+
readonly onCancel?: (() => any) | undefined;
|
|
428
|
+
readonly onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
429
|
+
readonly onSubmit?: ((textContent: string, structuredData?: StructuredData | undefined) => any) | undefined;
|
|
430
|
+
readonly "onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
431
|
+
} & VNodeProps & AllowedComponentProps & ComponentCustomProps;
|
|
432
|
+
$attrs: {
|
|
433
|
+
[x: string]: unknown;
|
|
434
|
+
};
|
|
435
|
+
$refs: {
|
|
436
|
+
[x: string]: unknown;
|
|
437
|
+
};
|
|
438
|
+
$slots: Readonly<{
|
|
439
|
+
[name: string]: Slot<any> | undefined;
|
|
440
|
+
}>;
|
|
441
|
+
$root: ComponentPublicInstance | null;
|
|
442
|
+
$parent: ComponentPublicInstance | null;
|
|
443
|
+
$host: Element | null;
|
|
444
|
+
$emit: ((event: "clear") => void) & ((event: "input", value: string) => void) & ((event: "blur", event: FocusEvent) => void) & ((event: "cancel") => void) & ((event: "focus", event: FocusEvent) => void) & ((event: "submit", textContent: string, structuredData?: StructuredData | undefined) => void) & ((event: "update:modelValue", value: string) => void);
|
|
445
|
+
$el: HTMLDivElement;
|
|
446
|
+
$options: ComponentOptionsBase<Readonly<SenderProps> & Readonly<{
|
|
447
|
+
onClear?: (() => any) | undefined;
|
|
448
|
+
onInput?: ((value: string) => any) | undefined;
|
|
449
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
450
|
+
onCancel?: (() => any) | undefined;
|
|
451
|
+
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
452
|
+
onSubmit?: ((textContent: string, structuredData?: StructuredData | undefined) => any) | undefined;
|
|
453
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
454
|
+
}>, {
|
|
455
|
+
submit: () => void;
|
|
456
|
+
clear: () => void;
|
|
457
|
+
cancel: () => void;
|
|
458
|
+
focus: () => void;
|
|
459
|
+
blur: () => void;
|
|
460
|
+
setContent: (content: string) => void;
|
|
461
|
+
getContent: () => string;
|
|
462
|
+
editor: SenderContext["editor"];
|
|
463
|
+
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
464
|
+
clear: () => any;
|
|
465
|
+
input: (value: string) => any;
|
|
466
|
+
blur: (event: FocusEvent) => any;
|
|
467
|
+
cancel: () => any;
|
|
468
|
+
focus: (event: FocusEvent) => any;
|
|
469
|
+
submit: (textContent: string, structuredData?: StructuredData | undefined) => any;
|
|
470
|
+
"update:modelValue": (value: string) => any;
|
|
471
|
+
}, string, {
|
|
472
|
+
size: "normal" | "small";
|
|
371
473
|
placeholder: string;
|
|
372
474
|
mode: InputMode;
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
allowSpeech: boolean;
|
|
376
|
-
allowFiles: boolean;
|
|
475
|
+
autoSize: AutoSize;
|
|
476
|
+
extensions: Extension[] | any[];
|
|
377
477
|
submitType: SubmitTrigger;
|
|
378
|
-
|
|
478
|
+
}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & {
|
|
479
|
+
beforeCreate?: (() => void) | (() => void)[];
|
|
480
|
+
created?: (() => void) | (() => void)[];
|
|
481
|
+
beforeMount?: (() => void) | (() => void)[];
|
|
482
|
+
mounted?: (() => void) | (() => void)[];
|
|
483
|
+
beforeUpdate?: (() => void) | (() => void)[];
|
|
484
|
+
updated?: (() => void) | (() => void)[];
|
|
485
|
+
activated?: (() => void) | (() => void)[];
|
|
486
|
+
deactivated?: (() => void) | (() => void)[];
|
|
487
|
+
beforeDestroy?: (() => void) | (() => void)[];
|
|
488
|
+
beforeUnmount?: (() => void) | (() => void)[];
|
|
489
|
+
destroyed?: (() => void) | (() => void)[];
|
|
490
|
+
unmounted?: (() => void) | (() => void)[];
|
|
491
|
+
renderTracked?: ((e: DebuggerEvent) => void) | ((e: DebuggerEvent) => void)[];
|
|
492
|
+
renderTriggered?: ((e: DebuggerEvent) => void) | ((e: DebuggerEvent) => void)[];
|
|
493
|
+
errorCaptured?: ((err: unknown, instance: ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: ComponentPublicInstance | null, info: string) => boolean | void)[];
|
|
494
|
+
};
|
|
495
|
+
$forceUpdate: () => void;
|
|
496
|
+
$nextTick: nextTick;
|
|
497
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, OnCleanup]) => any : (...args: [any, any, OnCleanup]) => any, options?: WatchOptions): WatchStopHandle;
|
|
498
|
+
} & Readonly<{
|
|
499
|
+
size: "normal" | "small";
|
|
500
|
+
placeholder: string;
|
|
501
|
+
mode: InputMode;
|
|
379
502
|
autoSize: AutoSize;
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
503
|
+
extensions: Extension[] | any[];
|
|
504
|
+
submitType: SubmitTrigger;
|
|
505
|
+
}> & Omit<Readonly<SenderProps> & Readonly<{
|
|
506
|
+
onClear?: (() => any) | undefined;
|
|
507
|
+
onInput?: ((value: string) => any) | undefined;
|
|
508
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
509
|
+
onCancel?: (() => any) | undefined;
|
|
510
|
+
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
511
|
+
onSubmit?: ((textContent: string, structuredData?: StructuredData | undefined) => any) | undefined;
|
|
512
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
513
|
+
}>, "clear" | "blur" | "cancel" | "focus" | "submit" | "editor" | "setContent" | ("size" | "placeholder" | "mode" | "autoSize" | "extensions" | "submitType") | "getContent"> & ShallowUnwrapRef< {
|
|
514
|
+
submit: () => void;
|
|
515
|
+
clear: () => void;
|
|
516
|
+
cancel: () => void;
|
|
517
|
+
focus: () => void;
|
|
518
|
+
blur: () => void;
|
|
519
|
+
setContent: (content: string) => void;
|
|
520
|
+
getContent: () => string;
|
|
521
|
+
editor: SenderContext["editor"];
|
|
522
|
+
}> & {} & ComponentCustomProperties & {} & {
|
|
523
|
+
$slots: {
|
|
524
|
+
header?(_: {}): any;
|
|
525
|
+
header?(_: {}): any;
|
|
526
|
+
prefix?(_: {}): any;
|
|
527
|
+
prefix?(_: {}): any;
|
|
528
|
+
content?(_: {
|
|
529
|
+
editor: Ref<Editor | undefined, Editor | undefined>;
|
|
530
|
+
}): any;
|
|
531
|
+
content?(_: {
|
|
532
|
+
editor: Ref<Editor | undefined, Editor | undefined>;
|
|
533
|
+
}): any;
|
|
534
|
+
'actions-inline'?(_: {}): any;
|
|
535
|
+
footer?(_: {}): any;
|
|
536
|
+
'footer-right'?(_: {}): any;
|
|
396
537
|
};
|
|
397
|
-
}
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
"
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
}
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
maxRows: number;
|
|
538
|
+
}) | null;
|
|
539
|
+
voiceRef: ({
|
|
540
|
+
$: ComponentInternalInstance;
|
|
541
|
+
$data: {};
|
|
542
|
+
$props: {
|
|
543
|
+
readonly icon?: (VNode | Component) | undefined;
|
|
544
|
+
readonly disabled?: boolean | undefined;
|
|
545
|
+
readonly size?: "small" | "normal" | undefined;
|
|
546
|
+
readonly tooltip?: TooltipContent | undefined;
|
|
547
|
+
readonly tooltipPlacement?: TooltipPlacement | undefined;
|
|
548
|
+
readonly speechConfig?: SpeechConfig | undefined;
|
|
549
|
+
readonly autoInsert?: boolean | undefined;
|
|
550
|
+
readonly onButtonClick?: ((isRecording: boolean, preventDefault: () => void) => void | Promise<void>) | undefined;
|
|
551
|
+
readonly "onSpeech-start"?: (() => any) | undefined;
|
|
552
|
+
readonly "onSpeech-interim"?: ((transcript: string) => any) | undefined;
|
|
553
|
+
readonly "onSpeech-final"?: ((transcript: string) => any) | undefined;
|
|
554
|
+
readonly "onSpeech-end"?: ((transcript?: string | undefined) => any) | undefined;
|
|
555
|
+
readonly "onSpeech-error"?: ((error: Error) => any) | undefined;
|
|
556
|
+
} & VNodeProps & AllowedComponentProps & ComponentCustomProps;
|
|
557
|
+
$attrs: {
|
|
558
|
+
[x: string]: unknown;
|
|
559
|
+
};
|
|
560
|
+
$refs: {
|
|
561
|
+
[x: string]: unknown;
|
|
422
562
|
};
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
563
|
+
$slots: Readonly<{
|
|
564
|
+
[name: string]: Slot<any> | undefined;
|
|
565
|
+
}>;
|
|
566
|
+
$root: ComponentPublicInstance | null;
|
|
567
|
+
$parent: ComponentPublicInstance | null;
|
|
568
|
+
$host: Element | null;
|
|
569
|
+
$emit: ((event: "speech-start") => void) & ((event: "speech-interim", transcript: string) => void) & ((event: "speech-final", transcript: string) => void) & ((event: "speech-end", transcript?: string | undefined) => void) & ((event: "speech-error", error: Error) => void);
|
|
570
|
+
$el: any;
|
|
571
|
+
$options: ComponentOptionsBase<Readonly<VoiceButtonProps> & Readonly<{
|
|
572
|
+
"onSpeech-start"?: (() => any) | undefined;
|
|
573
|
+
"onSpeech-interim"?: ((transcript: string) => any) | undefined;
|
|
574
|
+
"onSpeech-final"?: ((transcript: string) => any) | undefined;
|
|
575
|
+
"onSpeech-end"?: ((transcript?: string | undefined) => any) | undefined;
|
|
576
|
+
"onSpeech-error"?: ((error: Error) => any) | undefined;
|
|
426
577
|
}>, {
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
}
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
};
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
default: boolean;
|
|
481
|
-
};
|
|
482
|
-
selectMenu: {
|
|
483
|
-
type: {
|
|
484
|
-
(arrayLength: number): {
|
|
485
|
-
id: string;
|
|
486
|
-
label: string;
|
|
487
|
-
}[];
|
|
488
|
-
(...items: {
|
|
489
|
-
id: string;
|
|
490
|
-
label: string;
|
|
491
|
-
}[]): {
|
|
492
|
-
id: string;
|
|
493
|
-
label: string;
|
|
494
|
-
}[];
|
|
495
|
-
new (arrayLength: number): {
|
|
496
|
-
id: string;
|
|
497
|
-
label: string;
|
|
498
|
-
}[];
|
|
499
|
-
new (...items: {
|
|
500
|
-
id: string;
|
|
501
|
-
label: string;
|
|
502
|
-
}[]): {
|
|
503
|
-
id: string;
|
|
504
|
-
label: string;
|
|
505
|
-
}[];
|
|
506
|
-
isArray(arg: any): arg is any[];
|
|
507
|
-
readonly prototype: any[];
|
|
508
|
-
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
509
|
-
from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
|
|
510
|
-
from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
|
|
511
|
-
from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
|
|
512
|
-
of<T_4>(...items: T_4[]): T_4[];
|
|
513
|
-
readonly [Symbol.species]: ArrayConstructor;
|
|
514
|
-
};
|
|
515
|
-
default: () => never[];
|
|
516
|
-
};
|
|
517
|
-
ellipsis: {
|
|
518
|
-
type: BooleanConstructor;
|
|
519
|
-
default: boolean;
|
|
520
|
-
};
|
|
521
|
-
contentStyle: {
|
|
522
|
-
type: ObjectConstructor;
|
|
523
|
-
default: () => {};
|
|
524
|
-
};
|
|
525
|
-
isSelect: {
|
|
526
|
-
type: BooleanConstructor;
|
|
527
|
-
default: boolean;
|
|
528
|
-
};
|
|
529
|
-
tips: StringConstructor;
|
|
530
|
-
counter: {
|
|
531
|
-
type: BooleanConstructor;
|
|
532
|
-
default: boolean;
|
|
533
|
-
};
|
|
534
|
-
autosize: {
|
|
535
|
-
type: (BooleanConstructor | ObjectConstructor)[];
|
|
536
|
-
default: boolean;
|
|
537
|
-
};
|
|
538
|
-
clearable: {
|
|
539
|
-
type: BooleanConstructor;
|
|
540
|
-
default: boolean;
|
|
541
|
-
};
|
|
542
|
-
autocomplete: {
|
|
543
|
-
type: StringConstructor;
|
|
544
|
-
default: string;
|
|
545
|
-
};
|
|
546
|
-
showPassword: {
|
|
547
|
-
type: BooleanConstructor;
|
|
548
|
-
default: boolean;
|
|
549
|
-
};
|
|
550
|
-
showWordLimit: {
|
|
551
|
-
type: BooleanConstructor;
|
|
552
|
-
default: boolean;
|
|
553
|
-
};
|
|
554
|
-
showTitle: {
|
|
555
|
-
type: BooleanConstructor;
|
|
556
|
-
default: boolean;
|
|
557
|
-
};
|
|
558
|
-
validateEvent: {
|
|
559
|
-
type: BooleanConstructor;
|
|
560
|
-
default: boolean;
|
|
561
|
-
};
|
|
562
|
-
popupMore: {
|
|
563
|
-
type: BooleanConstructor;
|
|
564
|
-
default: boolean;
|
|
565
|
-
};
|
|
566
|
-
textareaTitle: {
|
|
567
|
-
type: StringConstructor;
|
|
568
|
-
default: string;
|
|
569
|
-
};
|
|
570
|
-
displayOnly: {
|
|
571
|
-
type: BooleanConstructor;
|
|
572
|
-
default: boolean;
|
|
573
|
-
};
|
|
574
|
-
displayOnlyContent: {
|
|
575
|
-
type: StringConstructor;
|
|
576
|
-
default: string;
|
|
577
|
-
};
|
|
578
|
-
customClass: {
|
|
579
|
-
type: StringConstructor;
|
|
580
|
-
default: string;
|
|
581
|
-
};
|
|
582
|
-
frontClearIcon: {
|
|
583
|
-
type: BooleanConstructor;
|
|
584
|
-
default: boolean;
|
|
585
|
-
};
|
|
586
|
-
showEmptyValue: {
|
|
587
|
-
type: BooleanConstructor;
|
|
588
|
-
default: undefined;
|
|
589
|
-
};
|
|
590
|
-
textAlign: {
|
|
591
|
-
type: StringConstructor;
|
|
592
|
-
default: string;
|
|
593
|
-
};
|
|
594
|
-
width: {
|
|
595
|
-
type: PropType<string | number | null>;
|
|
596
|
-
};
|
|
597
|
-
showTooltip: {
|
|
598
|
-
type: BooleanConstructor;
|
|
599
|
-
default: boolean;
|
|
600
|
-
};
|
|
601
|
-
inputBoxType: {
|
|
602
|
-
type: StringConstructor;
|
|
603
|
-
default: string;
|
|
604
|
-
validator: (value: string) => boolean;
|
|
605
|
-
};
|
|
606
|
-
tiny_mode: StringConstructor;
|
|
607
|
-
tiny_mode_root: BooleanConstructor;
|
|
608
|
-
tiny_template: (ObjectConstructor | FunctionConstructor)[];
|
|
609
|
-
tiny_renderless: FunctionConstructor;
|
|
610
|
-
tiny_theme: StringConstructor;
|
|
611
|
-
tiny_mcp_config: ObjectConstructor;
|
|
612
|
-
tiny_chart_theme: ObjectConstructor;
|
|
613
|
-
}>>, () => VNode<RendererNode, RendererElement, {
|
|
614
|
-
[key: string]: any;
|
|
615
|
-
}>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {
|
|
616
|
-
disabled: boolean;
|
|
617
|
-
type: string;
|
|
618
|
-
ellipsis: boolean;
|
|
619
|
-
mask: boolean;
|
|
620
|
-
vertical: boolean;
|
|
621
|
-
customClass: string;
|
|
622
|
-
tiny_mode_root: boolean;
|
|
623
|
-
_constants: Record<string, any>;
|
|
624
|
-
tabindex: string;
|
|
625
|
-
showTitle: boolean;
|
|
626
|
-
readonly: boolean;
|
|
627
|
-
hoverExpand: boolean;
|
|
628
|
-
memorySpace: number;
|
|
629
|
-
selectMenu: {
|
|
630
|
-
id: string;
|
|
631
|
-
label: string;
|
|
632
|
-
}[];
|
|
633
|
-
contentStyle: Record<string, any>;
|
|
634
|
-
isSelect: boolean;
|
|
635
|
-
counter: boolean;
|
|
636
|
-
autosize: boolean | Record<string, any>;
|
|
637
|
-
clearable: boolean;
|
|
638
|
-
autocomplete: string;
|
|
639
|
-
showPassword: boolean;
|
|
640
|
-
showWordLimit: boolean;
|
|
641
|
-
validateEvent: boolean;
|
|
642
|
-
popupMore: boolean;
|
|
643
|
-
textareaTitle: string;
|
|
644
|
-
displayOnly: boolean;
|
|
645
|
-
displayOnlyContent: string;
|
|
646
|
-
frontClearIcon: boolean;
|
|
647
|
-
showEmptyValue: boolean;
|
|
648
|
-
textAlign: string;
|
|
649
|
-
showTooltip: boolean;
|
|
650
|
-
inputBoxType: string;
|
|
651
|
-
}, true, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
652
|
-
P: {};
|
|
653
|
-
B: {};
|
|
654
|
-
D: {};
|
|
655
|
-
C: {};
|
|
656
|
-
M: {};
|
|
657
|
-
Defaults: {};
|
|
658
|
-
}, Readonly<ExtractPropTypes< {
|
|
659
|
-
_constants: {
|
|
660
|
-
type: ObjectConstructor;
|
|
661
|
-
default: () => {
|
|
662
|
-
INPUT_PC: string;
|
|
663
|
-
INPUTGROUP_PC: string;
|
|
664
|
-
INPUT_MOBILE: string;
|
|
665
|
-
INPUTGROUP_MOBILE: string;
|
|
666
|
-
Mode: string;
|
|
667
|
-
inputMode(mode: any): string;
|
|
668
|
-
inputGroupMode(mode: any): string;
|
|
669
|
-
VALIDATE_ICON: {
|
|
670
|
-
Validating: string;
|
|
671
|
-
Success: string;
|
|
672
|
-
Error: string;
|
|
673
|
-
};
|
|
674
|
-
COMPONENT_NAME: {
|
|
675
|
-
FormItem: string;
|
|
676
|
-
};
|
|
677
|
-
MASKSYMBOL: string;
|
|
678
|
-
TEXTAREA_HEIGHT_MOBILE: number;
|
|
679
|
-
};
|
|
680
|
-
};
|
|
681
|
-
name: StringConstructor;
|
|
682
|
-
size: StringConstructor;
|
|
683
|
-
form: StringConstructor;
|
|
684
|
-
label: StringConstructor;
|
|
685
|
-
height: NumberConstructor;
|
|
686
|
-
resize: StringConstructor;
|
|
687
|
-
tabindex: {
|
|
688
|
-
type: StringConstructor;
|
|
689
|
-
default: string;
|
|
690
|
-
};
|
|
691
|
-
disabled: BooleanConstructor;
|
|
692
|
-
readonly: BooleanConstructor;
|
|
693
|
-
hoverExpand: BooleanConstructor;
|
|
694
|
-
mask: BooleanConstructor;
|
|
695
|
-
suffixIcon: (StringConstructor | ObjectConstructor)[];
|
|
696
|
-
prefixIcon: (StringConstructor | ObjectConstructor)[];
|
|
697
|
-
modelValue: PropType<string | number | null>;
|
|
698
|
-
type: {
|
|
699
|
-
type: StringConstructor;
|
|
700
|
-
default: string;
|
|
701
|
-
};
|
|
702
|
-
memorySpace: {
|
|
703
|
-
type: NumberConstructor;
|
|
704
|
-
default: number;
|
|
705
|
-
};
|
|
706
|
-
vertical: {
|
|
707
|
-
type: BooleanConstructor;
|
|
708
|
-
default: boolean;
|
|
709
|
-
};
|
|
710
|
-
selectMenu: {
|
|
711
|
-
type: {
|
|
712
|
-
(arrayLength: number): {
|
|
713
|
-
id: string;
|
|
714
|
-
label: string;
|
|
715
|
-
}[];
|
|
716
|
-
(...items: {
|
|
717
|
-
id: string;
|
|
718
|
-
label: string;
|
|
719
|
-
}[]): {
|
|
720
|
-
id: string;
|
|
721
|
-
label: string;
|
|
722
|
-
}[];
|
|
723
|
-
new (arrayLength: number): {
|
|
724
|
-
id: string;
|
|
725
|
-
label: string;
|
|
726
|
-
}[];
|
|
727
|
-
new (...items: {
|
|
728
|
-
id: string;
|
|
729
|
-
label: string;
|
|
730
|
-
}[]): {
|
|
731
|
-
id: string;
|
|
732
|
-
label: string;
|
|
733
|
-
}[];
|
|
734
|
-
isArray(arg: any): arg is any[];
|
|
735
|
-
readonly prototype: any[];
|
|
736
|
-
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
737
|
-
from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
|
|
738
|
-
from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
|
|
739
|
-
from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
|
|
740
|
-
of<T_4>(...items: T_4[]): T_4[];
|
|
741
|
-
readonly [Symbol.species]: ArrayConstructor;
|
|
742
|
-
};
|
|
743
|
-
default: () => never[];
|
|
744
|
-
};
|
|
745
|
-
ellipsis: {
|
|
746
|
-
type: BooleanConstructor;
|
|
747
|
-
default: boolean;
|
|
748
|
-
};
|
|
749
|
-
contentStyle: {
|
|
750
|
-
type: ObjectConstructor;
|
|
751
|
-
default: () => {};
|
|
752
|
-
};
|
|
753
|
-
isSelect: {
|
|
754
|
-
type: BooleanConstructor;
|
|
755
|
-
default: boolean;
|
|
756
|
-
};
|
|
757
|
-
tips: StringConstructor;
|
|
758
|
-
counter: {
|
|
759
|
-
type: BooleanConstructor;
|
|
760
|
-
default: boolean;
|
|
761
|
-
};
|
|
762
|
-
autosize: {
|
|
763
|
-
type: (BooleanConstructor | ObjectConstructor)[];
|
|
764
|
-
default: boolean;
|
|
765
|
-
};
|
|
766
|
-
clearable: {
|
|
767
|
-
type: BooleanConstructor;
|
|
768
|
-
default: boolean;
|
|
769
|
-
};
|
|
770
|
-
autocomplete: {
|
|
771
|
-
type: StringConstructor;
|
|
772
|
-
default: string;
|
|
773
|
-
};
|
|
774
|
-
showPassword: {
|
|
775
|
-
type: BooleanConstructor;
|
|
776
|
-
default: boolean;
|
|
777
|
-
};
|
|
778
|
-
showWordLimit: {
|
|
779
|
-
type: BooleanConstructor;
|
|
780
|
-
default: boolean;
|
|
781
|
-
};
|
|
782
|
-
showTitle: {
|
|
783
|
-
type: BooleanConstructor;
|
|
784
|
-
default: boolean;
|
|
785
|
-
};
|
|
786
|
-
validateEvent: {
|
|
787
|
-
type: BooleanConstructor;
|
|
788
|
-
default: boolean;
|
|
789
|
-
};
|
|
790
|
-
popupMore: {
|
|
791
|
-
type: BooleanConstructor;
|
|
792
|
-
default: boolean;
|
|
793
|
-
};
|
|
794
|
-
textareaTitle: {
|
|
795
|
-
type: StringConstructor;
|
|
796
|
-
default: string;
|
|
797
|
-
};
|
|
798
|
-
displayOnly: {
|
|
799
|
-
type: BooleanConstructor;
|
|
800
|
-
default: boolean;
|
|
801
|
-
};
|
|
802
|
-
displayOnlyContent: {
|
|
803
|
-
type: StringConstructor;
|
|
804
|
-
default: string;
|
|
805
|
-
};
|
|
806
|
-
customClass: {
|
|
807
|
-
type: StringConstructor;
|
|
808
|
-
default: string;
|
|
809
|
-
};
|
|
810
|
-
frontClearIcon: {
|
|
811
|
-
type: BooleanConstructor;
|
|
812
|
-
default: boolean;
|
|
813
|
-
};
|
|
814
|
-
showEmptyValue: {
|
|
815
|
-
type: BooleanConstructor;
|
|
816
|
-
default: undefined;
|
|
817
|
-
};
|
|
818
|
-
textAlign: {
|
|
819
|
-
type: StringConstructor;
|
|
820
|
-
default: string;
|
|
821
|
-
};
|
|
822
|
-
width: {
|
|
823
|
-
type: PropType<string | number | null>;
|
|
824
|
-
};
|
|
825
|
-
showTooltip: {
|
|
826
|
-
type: BooleanConstructor;
|
|
827
|
-
default: boolean;
|
|
828
|
-
};
|
|
829
|
-
inputBoxType: {
|
|
830
|
-
type: StringConstructor;
|
|
831
|
-
default: string;
|
|
832
|
-
validator: (value: string) => boolean;
|
|
833
|
-
};
|
|
834
|
-
tiny_mode: StringConstructor;
|
|
835
|
-
tiny_mode_root: BooleanConstructor;
|
|
836
|
-
tiny_template: (ObjectConstructor | FunctionConstructor)[];
|
|
837
|
-
tiny_renderless: FunctionConstructor;
|
|
838
|
-
tiny_theme: StringConstructor;
|
|
839
|
-
tiny_mcp_config: ObjectConstructor;
|
|
840
|
-
tiny_chart_theme: ObjectConstructor;
|
|
841
|
-
}>>, () => VNode<RendererNode, RendererElement, {
|
|
842
|
-
[key: string]: any;
|
|
843
|
-
}>, {}, {}, {}, {
|
|
844
|
-
disabled: boolean;
|
|
845
|
-
type: string;
|
|
846
|
-
ellipsis: boolean;
|
|
847
|
-
mask: boolean;
|
|
848
|
-
vertical: boolean;
|
|
849
|
-
customClass: string;
|
|
850
|
-
tiny_mode_root: boolean;
|
|
851
|
-
_constants: Record<string, any>;
|
|
852
|
-
tabindex: string;
|
|
853
|
-
showTitle: boolean;
|
|
854
|
-
readonly: boolean;
|
|
855
|
-
hoverExpand: boolean;
|
|
856
|
-
memorySpace: number;
|
|
857
|
-
selectMenu: {
|
|
858
|
-
id: string;
|
|
859
|
-
label: string;
|
|
860
|
-
}[];
|
|
861
|
-
contentStyle: Record<string, any>;
|
|
862
|
-
isSelect: boolean;
|
|
863
|
-
counter: boolean;
|
|
864
|
-
autosize: boolean | Record<string, any>;
|
|
865
|
-
clearable: boolean;
|
|
866
|
-
autocomplete: string;
|
|
867
|
-
showPassword: boolean;
|
|
868
|
-
showWordLimit: boolean;
|
|
869
|
-
validateEvent: boolean;
|
|
870
|
-
popupMore: boolean;
|
|
871
|
-
textareaTitle: string;
|
|
872
|
-
displayOnly: boolean;
|
|
873
|
-
displayOnlyContent: string;
|
|
874
|
-
frontClearIcon: boolean;
|
|
875
|
-
showEmptyValue: boolean;
|
|
876
|
-
textAlign: string;
|
|
877
|
-
showTooltip: boolean;
|
|
878
|
-
inputBoxType: string;
|
|
879
|
-
}> | null;
|
|
880
|
-
buttonsContainerRef: HTMLDivElement;
|
|
578
|
+
start: () => void;
|
|
579
|
+
stop: () => void;
|
|
580
|
+
speechState: SpeechState;
|
|
581
|
+
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
582
|
+
"speech-start": () => any;
|
|
583
|
+
"speech-interim": (transcript: string) => any;
|
|
584
|
+
"speech-final": (transcript: string) => any;
|
|
585
|
+
"speech-end": (transcript?: string | undefined) => any;
|
|
586
|
+
"speech-error": (error: Error) => any;
|
|
587
|
+
}, string, {
|
|
588
|
+
tooltipPlacement: TooltipPlacement;
|
|
589
|
+
autoInsert: boolean;
|
|
590
|
+
}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & {
|
|
591
|
+
beforeCreate?: (() => void) | (() => void)[];
|
|
592
|
+
created?: (() => void) | (() => void)[];
|
|
593
|
+
beforeMount?: (() => void) | (() => void)[];
|
|
594
|
+
mounted?: (() => void) | (() => void)[];
|
|
595
|
+
beforeUpdate?: (() => void) | (() => void)[];
|
|
596
|
+
updated?: (() => void) | (() => void)[];
|
|
597
|
+
activated?: (() => void) | (() => void)[];
|
|
598
|
+
deactivated?: (() => void) | (() => void)[];
|
|
599
|
+
beforeDestroy?: (() => void) | (() => void)[];
|
|
600
|
+
beforeUnmount?: (() => void) | (() => void)[];
|
|
601
|
+
destroyed?: (() => void) | (() => void)[];
|
|
602
|
+
unmounted?: (() => void) | (() => void)[];
|
|
603
|
+
renderTracked?: ((e: DebuggerEvent) => void) | ((e: DebuggerEvent) => void)[];
|
|
604
|
+
renderTriggered?: ((e: DebuggerEvent) => void) | ((e: DebuggerEvent) => void)[];
|
|
605
|
+
errorCaptured?: ((err: unknown, instance: ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: ComponentPublicInstance | null, info: string) => boolean | void)[];
|
|
606
|
+
};
|
|
607
|
+
$forceUpdate: () => void;
|
|
608
|
+
$nextTick: nextTick;
|
|
609
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, OnCleanup]) => any : (...args: [any, any, OnCleanup]) => any, options?: WatchOptions): WatchStopHandle;
|
|
610
|
+
} & Readonly<{
|
|
611
|
+
tooltipPlacement: TooltipPlacement;
|
|
612
|
+
autoInsert: boolean;
|
|
613
|
+
}> & Omit<Readonly<VoiceButtonProps> & Readonly<{
|
|
614
|
+
"onSpeech-start"?: (() => any) | undefined;
|
|
615
|
+
"onSpeech-interim"?: ((transcript: string) => any) | undefined;
|
|
616
|
+
"onSpeech-final"?: ((transcript: string) => any) | undefined;
|
|
617
|
+
"onSpeech-end"?: ((transcript?: string | undefined) => any) | undefined;
|
|
618
|
+
"onSpeech-error"?: ((error: Error) => any) | undefined;
|
|
619
|
+
}>, "stop" | "start" | "speechState" | ("tooltipPlacement" | "autoInsert")> & ShallowUnwrapRef< {
|
|
620
|
+
start: () => void;
|
|
621
|
+
stop: () => void;
|
|
622
|
+
speechState: SpeechState;
|
|
623
|
+
}> & {} & ComponentCustomProperties & {} & {
|
|
624
|
+
$slots: {
|
|
625
|
+
'recording-overlay'?(_: {
|
|
626
|
+
isRecording: boolean;
|
|
627
|
+
stop: () => void;
|
|
628
|
+
}): any;
|
|
629
|
+
};
|
|
630
|
+
}) | null;
|
|
881
631
|
}, HTMLDivElement>;
|
|
882
632
|
|
|
883
633
|
declare const __VLS_component_8: DefineComponent<SuggestionPillButtonProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<SuggestionPillButtonProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLButtonElement>;
|
|
@@ -1090,6 +840,28 @@ declare function __VLS_template_12(): {
|
|
|
1090
840
|
rootEl: HTMLDivElement;
|
|
1091
841
|
};
|
|
1092
842
|
|
|
843
|
+
declare function __VLS_template_13(): {
|
|
844
|
+
attrs: Partial<{}>;
|
|
845
|
+
slots: {
|
|
846
|
+
icon?(_: {}): any;
|
|
847
|
+
icon?(_: {}): any;
|
|
848
|
+
};
|
|
849
|
+
refs: {};
|
|
850
|
+
rootEl: any;
|
|
851
|
+
};
|
|
852
|
+
|
|
853
|
+
declare function __VLS_template_14(): {
|
|
854
|
+
attrs: Partial<{}>;
|
|
855
|
+
slots: {
|
|
856
|
+
'recording-overlay'?(_: {
|
|
857
|
+
isRecording: boolean;
|
|
858
|
+
stop: () => void;
|
|
859
|
+
}): any;
|
|
860
|
+
};
|
|
861
|
+
refs: {};
|
|
862
|
+
rootEl: any;
|
|
863
|
+
};
|
|
864
|
+
|
|
1093
865
|
declare function __VLS_template_2(): {
|
|
1094
866
|
attrs: Partial<{}>;
|
|
1095
867
|
slots: {
|
|
@@ -1231,546 +1003,285 @@ declare function __VLS_template_7(): {
|
|
|
1231
1003
|
slots: {
|
|
1232
1004
|
header?(_: {}): any;
|
|
1233
1005
|
prefix?(_: {}): any;
|
|
1234
|
-
content?(_: {
|
|
1235
|
-
|
|
1006
|
+
content?(_: {
|
|
1007
|
+
editor: Ref<Editor | undefined, Editor | undefined>;
|
|
1008
|
+
}): any;
|
|
1236
1009
|
actions?(_: {}): any;
|
|
1237
1010
|
'footer-left'?(_: {}): any;
|
|
1238
|
-
'footer-right'?(_: {}): any;
|
|
1239
1011
|
footer?(_: {}): any;
|
|
1012
|
+
'footer-right'?(_: {}): any;
|
|
1240
1013
|
};
|
|
1241
1014
|
refs: {
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1422
|
-
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
}, Readonly<ExtractPropTypes< {
|
|
1513
|
-
_constants: {
|
|
1514
|
-
type: ObjectConstructor;
|
|
1515
|
-
default: () => {
|
|
1516
|
-
INPUT_PC: string;
|
|
1517
|
-
INPUTGROUP_PC: string;
|
|
1518
|
-
INPUT_MOBILE: string;
|
|
1519
|
-
INPUTGROUP_MOBILE: string;
|
|
1520
|
-
Mode: string;
|
|
1521
|
-
inputMode(mode: any): string;
|
|
1522
|
-
inputGroupMode(mode: any): string;
|
|
1523
|
-
VALIDATE_ICON: {
|
|
1524
|
-
Validating: string;
|
|
1525
|
-
Success: string;
|
|
1526
|
-
Error: string;
|
|
1527
|
-
};
|
|
1528
|
-
COMPONENT_NAME: {
|
|
1529
|
-
FormItem: string;
|
|
1530
|
-
};
|
|
1531
|
-
MASKSYMBOL: string;
|
|
1532
|
-
TEXTAREA_HEIGHT_MOBILE: number;
|
|
1533
|
-
};
|
|
1534
|
-
};
|
|
1535
|
-
name: StringConstructor;
|
|
1536
|
-
size: StringConstructor;
|
|
1537
|
-
form: StringConstructor;
|
|
1538
|
-
label: StringConstructor;
|
|
1539
|
-
height: NumberConstructor;
|
|
1540
|
-
resize: StringConstructor;
|
|
1541
|
-
tabindex: {
|
|
1542
|
-
type: StringConstructor;
|
|
1543
|
-
default: string;
|
|
1544
|
-
};
|
|
1545
|
-
disabled: BooleanConstructor;
|
|
1546
|
-
readonly: BooleanConstructor;
|
|
1547
|
-
hoverExpand: BooleanConstructor;
|
|
1548
|
-
mask: BooleanConstructor;
|
|
1549
|
-
suffixIcon: (StringConstructor | ObjectConstructor)[];
|
|
1550
|
-
prefixIcon: (StringConstructor | ObjectConstructor)[];
|
|
1551
|
-
modelValue: PropType<string | number | null>;
|
|
1552
|
-
type: {
|
|
1553
|
-
type: StringConstructor;
|
|
1554
|
-
default: string;
|
|
1555
|
-
};
|
|
1556
|
-
memorySpace: {
|
|
1557
|
-
type: NumberConstructor;
|
|
1558
|
-
default: number;
|
|
1559
|
-
};
|
|
1560
|
-
vertical: {
|
|
1561
|
-
type: BooleanConstructor;
|
|
1562
|
-
default: boolean;
|
|
1563
|
-
};
|
|
1564
|
-
selectMenu: {
|
|
1565
|
-
type: {
|
|
1566
|
-
(arrayLength: number): {
|
|
1567
|
-
id: string;
|
|
1568
|
-
label: string;
|
|
1569
|
-
}[];
|
|
1570
|
-
(...items: {
|
|
1571
|
-
id: string;
|
|
1572
|
-
label: string;
|
|
1573
|
-
}[]): {
|
|
1574
|
-
id: string;
|
|
1575
|
-
label: string;
|
|
1576
|
-
}[];
|
|
1577
|
-
new (arrayLength: number): {
|
|
1578
|
-
id: string;
|
|
1579
|
-
label: string;
|
|
1580
|
-
}[];
|
|
1581
|
-
new (...items: {
|
|
1582
|
-
id: string;
|
|
1583
|
-
label: string;
|
|
1584
|
-
}[]): {
|
|
1585
|
-
id: string;
|
|
1586
|
-
label: string;
|
|
1587
|
-
}[];
|
|
1588
|
-
isArray(arg: any): arg is any[];
|
|
1589
|
-
readonly prototype: any[];
|
|
1590
|
-
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
1591
|
-
from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
|
|
1592
|
-
from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
|
|
1593
|
-
from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
|
|
1594
|
-
of<T_4>(...items: T_4[]): T_4[];
|
|
1595
|
-
readonly [Symbol.species]: ArrayConstructor;
|
|
1596
|
-
};
|
|
1597
|
-
default: () => never[];
|
|
1598
|
-
};
|
|
1599
|
-
ellipsis: {
|
|
1600
|
-
type: BooleanConstructor;
|
|
1601
|
-
default: boolean;
|
|
1602
|
-
};
|
|
1603
|
-
contentStyle: {
|
|
1604
|
-
type: ObjectConstructor;
|
|
1605
|
-
default: () => {};
|
|
1606
|
-
};
|
|
1607
|
-
isSelect: {
|
|
1608
|
-
type: BooleanConstructor;
|
|
1609
|
-
default: boolean;
|
|
1610
|
-
};
|
|
1611
|
-
tips: StringConstructor;
|
|
1612
|
-
counter: {
|
|
1613
|
-
type: BooleanConstructor;
|
|
1614
|
-
default: boolean;
|
|
1615
|
-
};
|
|
1616
|
-
autosize: {
|
|
1617
|
-
type: (BooleanConstructor | ObjectConstructor)[];
|
|
1618
|
-
default: boolean;
|
|
1619
|
-
};
|
|
1620
|
-
clearable: {
|
|
1621
|
-
type: BooleanConstructor;
|
|
1622
|
-
default: boolean;
|
|
1623
|
-
};
|
|
1624
|
-
autocomplete: {
|
|
1625
|
-
type: StringConstructor;
|
|
1626
|
-
default: string;
|
|
1627
|
-
};
|
|
1628
|
-
showPassword: {
|
|
1629
|
-
type: BooleanConstructor;
|
|
1630
|
-
default: boolean;
|
|
1631
|
-
};
|
|
1632
|
-
showWordLimit: {
|
|
1633
|
-
type: BooleanConstructor;
|
|
1634
|
-
default: boolean;
|
|
1635
|
-
};
|
|
1636
|
-
showTitle: {
|
|
1637
|
-
type: BooleanConstructor;
|
|
1638
|
-
default: boolean;
|
|
1639
|
-
};
|
|
1640
|
-
validateEvent: {
|
|
1641
|
-
type: BooleanConstructor;
|
|
1642
|
-
default: boolean;
|
|
1643
|
-
};
|
|
1644
|
-
popupMore: {
|
|
1645
|
-
type: BooleanConstructor;
|
|
1646
|
-
default: boolean;
|
|
1647
|
-
};
|
|
1648
|
-
textareaTitle: {
|
|
1649
|
-
type: StringConstructor;
|
|
1650
|
-
default: string;
|
|
1651
|
-
};
|
|
1652
|
-
displayOnly: {
|
|
1653
|
-
type: BooleanConstructor;
|
|
1654
|
-
default: boolean;
|
|
1655
|
-
};
|
|
1656
|
-
displayOnlyContent: {
|
|
1657
|
-
type: StringConstructor;
|
|
1658
|
-
default: string;
|
|
1659
|
-
};
|
|
1660
|
-
customClass: {
|
|
1661
|
-
type: StringConstructor;
|
|
1662
|
-
default: string;
|
|
1663
|
-
};
|
|
1664
|
-
frontClearIcon: {
|
|
1665
|
-
type: BooleanConstructor;
|
|
1666
|
-
default: boolean;
|
|
1667
|
-
};
|
|
1668
|
-
showEmptyValue: {
|
|
1669
|
-
type: BooleanConstructor;
|
|
1670
|
-
default: undefined;
|
|
1671
|
-
};
|
|
1672
|
-
textAlign: {
|
|
1673
|
-
type: StringConstructor;
|
|
1674
|
-
default: string;
|
|
1675
|
-
};
|
|
1676
|
-
width: {
|
|
1677
|
-
type: PropType<string | number | null>;
|
|
1678
|
-
};
|
|
1679
|
-
showTooltip: {
|
|
1680
|
-
type: BooleanConstructor;
|
|
1681
|
-
default: boolean;
|
|
1682
|
-
};
|
|
1683
|
-
inputBoxType: {
|
|
1684
|
-
type: StringConstructor;
|
|
1685
|
-
default: string;
|
|
1686
|
-
validator: (value: string) => boolean;
|
|
1687
|
-
};
|
|
1688
|
-
tiny_mode: StringConstructor;
|
|
1689
|
-
tiny_mode_root: BooleanConstructor;
|
|
1690
|
-
tiny_template: (ObjectConstructor | FunctionConstructor)[];
|
|
1691
|
-
tiny_renderless: FunctionConstructor;
|
|
1692
|
-
tiny_theme: StringConstructor;
|
|
1693
|
-
tiny_mcp_config: ObjectConstructor;
|
|
1694
|
-
tiny_chart_theme: ObjectConstructor;
|
|
1695
|
-
}>>, () => VNode<RendererNode, RendererElement, {
|
|
1696
|
-
[key: string]: any;
|
|
1697
|
-
}>, {}, {}, {}, {
|
|
1698
|
-
disabled: boolean;
|
|
1699
|
-
type: string;
|
|
1700
|
-
ellipsis: boolean;
|
|
1701
|
-
mask: boolean;
|
|
1702
|
-
vertical: boolean;
|
|
1703
|
-
customClass: string;
|
|
1704
|
-
tiny_mode_root: boolean;
|
|
1705
|
-
_constants: Record<string, any>;
|
|
1706
|
-
tabindex: string;
|
|
1707
|
-
showTitle: boolean;
|
|
1708
|
-
readonly: boolean;
|
|
1709
|
-
hoverExpand: boolean;
|
|
1710
|
-
memorySpace: number;
|
|
1711
|
-
selectMenu: {
|
|
1712
|
-
id: string;
|
|
1713
|
-
label: string;
|
|
1714
|
-
}[];
|
|
1715
|
-
contentStyle: Record<string, any>;
|
|
1716
|
-
isSelect: boolean;
|
|
1717
|
-
counter: boolean;
|
|
1718
|
-
autosize: boolean | Record<string, any>;
|
|
1719
|
-
clearable: boolean;
|
|
1720
|
-
autocomplete: string;
|
|
1721
|
-
showPassword: boolean;
|
|
1722
|
-
showWordLimit: boolean;
|
|
1723
|
-
validateEvent: boolean;
|
|
1724
|
-
popupMore: boolean;
|
|
1725
|
-
textareaTitle: string;
|
|
1726
|
-
displayOnly: boolean;
|
|
1727
|
-
displayOnlyContent: string;
|
|
1728
|
-
frontClearIcon: boolean;
|
|
1729
|
-
showEmptyValue: boolean;
|
|
1730
|
-
textAlign: string;
|
|
1731
|
-
showTooltip: boolean;
|
|
1732
|
-
inputBoxType: string;
|
|
1733
|
-
}> | null;
|
|
1734
|
-
buttonsContainerRef: HTMLDivElement;
|
|
1735
|
-
};
|
|
1736
|
-
rootEl: HTMLDivElement;
|
|
1737
|
-
};
|
|
1738
|
-
|
|
1739
|
-
declare function __VLS_template_8(): {
|
|
1740
|
-
attrs: Partial<{}>;
|
|
1741
|
-
slots: Readonly<SuggestionPillButtonSlots> & SuggestionPillButtonSlots;
|
|
1742
|
-
refs: {};
|
|
1743
|
-
rootEl: HTMLButtonElement;
|
|
1744
|
-
};
|
|
1745
|
-
|
|
1746
|
-
declare function __VLS_template_9(): {
|
|
1747
|
-
attrs: Partial<{}>;
|
|
1748
|
-
slots: Readonly<SuggestionPillsSlots> & SuggestionPillsSlots;
|
|
1749
|
-
refs: {
|
|
1750
|
-
containerWrapperRef: HTMLDivElement;
|
|
1751
|
-
containerRef: HTMLDivElement;
|
|
1752
|
-
staticMaybeItemRefs: unknown[];
|
|
1753
|
-
floatingItemsRef: HTMLDivElement;
|
|
1754
|
-
floatingMaybeItemRefs: unknown[];
|
|
1755
|
-
};
|
|
1756
|
-
rootEl: HTMLDivElement;
|
|
1757
|
-
};
|
|
1758
|
-
|
|
1759
|
-
declare type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
1760
|
-
|
|
1761
|
-
declare type __VLS_TemplateResult_10 = ReturnType<typeof __VLS_template_10>;
|
|
1762
|
-
|
|
1763
|
-
declare type __VLS_TemplateResult_11 = ReturnType<typeof __VLS_template_11>;
|
|
1764
|
-
|
|
1765
|
-
declare type __VLS_TemplateResult_12 = ReturnType<typeof __VLS_template_12>;
|
|
1766
|
-
|
|
1767
|
-
declare type __VLS_TemplateResult_2 = ReturnType<typeof __VLS_template_2>;
|
|
1768
|
-
|
|
1769
|
-
declare type __VLS_TemplateResult_3 = ReturnType<typeof __VLS_template_3>;
|
|
1770
|
-
|
|
1771
|
-
declare type __VLS_TemplateResult_4 = ReturnType<typeof __VLS_template_4>;
|
|
1772
|
-
|
|
1773
|
-
declare type __VLS_TemplateResult_5 = ReturnType<typeof __VLS_template_5>;
|
|
1015
|
+
chatInputRef: ({
|
|
1016
|
+
$: ComponentInternalInstance;
|
|
1017
|
+
$data: {};
|
|
1018
|
+
$props: {
|
|
1019
|
+
readonly modelValue?: string | undefined;
|
|
1020
|
+
readonly defaultValue?: string | undefined;
|
|
1021
|
+
readonly placeholder?: string | undefined;
|
|
1022
|
+
readonly disabled?: boolean | undefined;
|
|
1023
|
+
readonly loading?: boolean | undefined;
|
|
1024
|
+
readonly autofocus?: boolean | undefined;
|
|
1025
|
+
readonly mode?: InputMode | undefined;
|
|
1026
|
+
readonly autoSize?: AutoSize | undefined;
|
|
1027
|
+
readonly maxLength?: number | undefined;
|
|
1028
|
+
readonly showWordLimit?: boolean | undefined;
|
|
1029
|
+
readonly clearable?: boolean | undefined;
|
|
1030
|
+
readonly extensions?: Extension[] | any[] | undefined;
|
|
1031
|
+
readonly size?: "normal" | "small" | undefined;
|
|
1032
|
+
readonly stopText?: string | undefined;
|
|
1033
|
+
readonly defaultActions?: DefaultActions | undefined;
|
|
1034
|
+
readonly submitType?: SubmitTrigger | undefined;
|
|
1035
|
+
readonly onClear?: (() => any) | undefined;
|
|
1036
|
+
readonly onInput?: ((value: string) => any) | undefined;
|
|
1037
|
+
readonly onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
1038
|
+
readonly onCancel?: (() => any) | undefined;
|
|
1039
|
+
readonly onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
1040
|
+
readonly onSubmit?: ((textContent: string, structuredData?: StructuredData | undefined) => any) | undefined;
|
|
1041
|
+
readonly "onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
1042
|
+
} & VNodeProps & AllowedComponentProps & ComponentCustomProps;
|
|
1043
|
+
$attrs: {
|
|
1044
|
+
[x: string]: unknown;
|
|
1045
|
+
};
|
|
1046
|
+
$refs: {
|
|
1047
|
+
[x: string]: unknown;
|
|
1048
|
+
};
|
|
1049
|
+
$slots: Readonly<{
|
|
1050
|
+
[name: string]: Slot<any> | undefined;
|
|
1051
|
+
}>;
|
|
1052
|
+
$root: ComponentPublicInstance | null;
|
|
1053
|
+
$parent: ComponentPublicInstance | null;
|
|
1054
|
+
$host: Element | null;
|
|
1055
|
+
$emit: ((event: "clear") => void) & ((event: "input", value: string) => void) & ((event: "blur", event: FocusEvent) => void) & ((event: "cancel") => void) & ((event: "focus", event: FocusEvent) => void) & ((event: "submit", textContent: string, structuredData?: StructuredData | undefined) => void) & ((event: "update:modelValue", value: string) => void);
|
|
1056
|
+
$el: HTMLDivElement;
|
|
1057
|
+
$options: ComponentOptionsBase<Readonly<SenderProps> & Readonly<{
|
|
1058
|
+
onClear?: (() => any) | undefined;
|
|
1059
|
+
onInput?: ((value: string) => any) | undefined;
|
|
1060
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
1061
|
+
onCancel?: (() => any) | undefined;
|
|
1062
|
+
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
1063
|
+
onSubmit?: ((textContent: string, structuredData?: StructuredData | undefined) => any) | undefined;
|
|
1064
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
1065
|
+
}>, {
|
|
1066
|
+
submit: () => void;
|
|
1067
|
+
clear: () => void;
|
|
1068
|
+
cancel: () => void;
|
|
1069
|
+
focus: () => void;
|
|
1070
|
+
blur: () => void;
|
|
1071
|
+
setContent: (content: string) => void;
|
|
1072
|
+
getContent: () => string;
|
|
1073
|
+
editor: SenderContext["editor"];
|
|
1074
|
+
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
1075
|
+
clear: () => any;
|
|
1076
|
+
input: (value: string) => any;
|
|
1077
|
+
blur: (event: FocusEvent) => any;
|
|
1078
|
+
cancel: () => any;
|
|
1079
|
+
focus: (event: FocusEvent) => any;
|
|
1080
|
+
submit: (textContent: string, structuredData?: StructuredData | undefined) => any;
|
|
1081
|
+
"update:modelValue": (value: string) => any;
|
|
1082
|
+
}, string, {
|
|
1083
|
+
size: "normal" | "small";
|
|
1084
|
+
placeholder: string;
|
|
1085
|
+
mode: InputMode;
|
|
1086
|
+
autoSize: AutoSize;
|
|
1087
|
+
extensions: Extension[] | any[];
|
|
1088
|
+
submitType: SubmitTrigger;
|
|
1089
|
+
}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & {
|
|
1090
|
+
beforeCreate?: (() => void) | (() => void)[];
|
|
1091
|
+
created?: (() => void) | (() => void)[];
|
|
1092
|
+
beforeMount?: (() => void) | (() => void)[];
|
|
1093
|
+
mounted?: (() => void) | (() => void)[];
|
|
1094
|
+
beforeUpdate?: (() => void) | (() => void)[];
|
|
1095
|
+
updated?: (() => void) | (() => void)[];
|
|
1096
|
+
activated?: (() => void) | (() => void)[];
|
|
1097
|
+
deactivated?: (() => void) | (() => void)[];
|
|
1098
|
+
beforeDestroy?: (() => void) | (() => void)[];
|
|
1099
|
+
beforeUnmount?: (() => void) | (() => void)[];
|
|
1100
|
+
destroyed?: (() => void) | (() => void)[];
|
|
1101
|
+
unmounted?: (() => void) | (() => void)[];
|
|
1102
|
+
renderTracked?: ((e: DebuggerEvent) => void) | ((e: DebuggerEvent) => void)[];
|
|
1103
|
+
renderTriggered?: ((e: DebuggerEvent) => void) | ((e: DebuggerEvent) => void)[];
|
|
1104
|
+
errorCaptured?: ((err: unknown, instance: ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: ComponentPublicInstance | null, info: string) => boolean | void)[];
|
|
1105
|
+
};
|
|
1106
|
+
$forceUpdate: () => void;
|
|
1107
|
+
$nextTick: nextTick;
|
|
1108
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, OnCleanup]) => any : (...args: [any, any, OnCleanup]) => any, options?: WatchOptions): WatchStopHandle;
|
|
1109
|
+
} & Readonly<{
|
|
1110
|
+
size: "normal" | "small";
|
|
1111
|
+
placeholder: string;
|
|
1112
|
+
mode: InputMode;
|
|
1113
|
+
autoSize: AutoSize;
|
|
1114
|
+
extensions: Extension[] | any[];
|
|
1115
|
+
submitType: SubmitTrigger;
|
|
1116
|
+
}> & Omit<Readonly<SenderProps> & Readonly<{
|
|
1117
|
+
onClear?: (() => any) | undefined;
|
|
1118
|
+
onInput?: ((value: string) => any) | undefined;
|
|
1119
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
1120
|
+
onCancel?: (() => any) | undefined;
|
|
1121
|
+
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
1122
|
+
onSubmit?: ((textContent: string, structuredData?: StructuredData | undefined) => any) | undefined;
|
|
1123
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
1124
|
+
}>, "clear" | "blur" | "cancel" | "focus" | "submit" | "editor" | "setContent" | ("size" | "placeholder" | "mode" | "autoSize" | "extensions" | "submitType") | "getContent"> & ShallowUnwrapRef< {
|
|
1125
|
+
submit: () => void;
|
|
1126
|
+
clear: () => void;
|
|
1127
|
+
cancel: () => void;
|
|
1128
|
+
focus: () => void;
|
|
1129
|
+
blur: () => void;
|
|
1130
|
+
setContent: (content: string) => void;
|
|
1131
|
+
getContent: () => string;
|
|
1132
|
+
editor: SenderContext["editor"];
|
|
1133
|
+
}> & {} & ComponentCustomProperties & {} & {
|
|
1134
|
+
$slots: {
|
|
1135
|
+
header?(_: {}): any;
|
|
1136
|
+
header?(_: {}): any;
|
|
1137
|
+
prefix?(_: {}): any;
|
|
1138
|
+
prefix?(_: {}): any;
|
|
1139
|
+
content?(_: {
|
|
1140
|
+
editor: Ref<Editor | undefined, Editor | undefined>;
|
|
1141
|
+
}): any;
|
|
1142
|
+
content?(_: {
|
|
1143
|
+
editor: Ref<Editor | undefined, Editor | undefined>;
|
|
1144
|
+
}): any;
|
|
1145
|
+
'actions-inline'?(_: {}): any;
|
|
1146
|
+
footer?(_: {}): any;
|
|
1147
|
+
'footer-right'?(_: {}): any;
|
|
1148
|
+
};
|
|
1149
|
+
}) | null;
|
|
1150
|
+
voiceRef: ({
|
|
1151
|
+
$: ComponentInternalInstance;
|
|
1152
|
+
$data: {};
|
|
1153
|
+
$props: {
|
|
1154
|
+
readonly icon?: (VNode | Component) | undefined;
|
|
1155
|
+
readonly disabled?: boolean | undefined;
|
|
1156
|
+
readonly size?: "small" | "normal" | undefined;
|
|
1157
|
+
readonly tooltip?: TooltipContent | undefined;
|
|
1158
|
+
readonly tooltipPlacement?: TooltipPlacement | undefined;
|
|
1159
|
+
readonly speechConfig?: SpeechConfig | undefined;
|
|
1160
|
+
readonly autoInsert?: boolean | undefined;
|
|
1161
|
+
readonly onButtonClick?: ((isRecording: boolean, preventDefault: () => void) => void | Promise<void>) | undefined;
|
|
1162
|
+
readonly "onSpeech-start"?: (() => any) | undefined;
|
|
1163
|
+
readonly "onSpeech-interim"?: ((transcript: string) => any) | undefined;
|
|
1164
|
+
readonly "onSpeech-final"?: ((transcript: string) => any) | undefined;
|
|
1165
|
+
readonly "onSpeech-end"?: ((transcript?: string | undefined) => any) | undefined;
|
|
1166
|
+
readonly "onSpeech-error"?: ((error: Error) => any) | undefined;
|
|
1167
|
+
} & VNodeProps & AllowedComponentProps & ComponentCustomProps;
|
|
1168
|
+
$attrs: {
|
|
1169
|
+
[x: string]: unknown;
|
|
1170
|
+
};
|
|
1171
|
+
$refs: {
|
|
1172
|
+
[x: string]: unknown;
|
|
1173
|
+
};
|
|
1174
|
+
$slots: Readonly<{
|
|
1175
|
+
[name: string]: Slot<any> | undefined;
|
|
1176
|
+
}>;
|
|
1177
|
+
$root: ComponentPublicInstance | null;
|
|
1178
|
+
$parent: ComponentPublicInstance | null;
|
|
1179
|
+
$host: Element | null;
|
|
1180
|
+
$emit: ((event: "speech-start") => void) & ((event: "speech-interim", transcript: string) => void) & ((event: "speech-final", transcript: string) => void) & ((event: "speech-end", transcript?: string | undefined) => void) & ((event: "speech-error", error: Error) => void);
|
|
1181
|
+
$el: any;
|
|
1182
|
+
$options: ComponentOptionsBase<Readonly<VoiceButtonProps> & Readonly<{
|
|
1183
|
+
"onSpeech-start"?: (() => any) | undefined;
|
|
1184
|
+
"onSpeech-interim"?: ((transcript: string) => any) | undefined;
|
|
1185
|
+
"onSpeech-final"?: ((transcript: string) => any) | undefined;
|
|
1186
|
+
"onSpeech-end"?: ((transcript?: string | undefined) => any) | undefined;
|
|
1187
|
+
"onSpeech-error"?: ((error: Error) => any) | undefined;
|
|
1188
|
+
}>, {
|
|
1189
|
+
start: () => void;
|
|
1190
|
+
stop: () => void;
|
|
1191
|
+
speechState: SpeechState;
|
|
1192
|
+
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
1193
|
+
"speech-start": () => any;
|
|
1194
|
+
"speech-interim": (transcript: string) => any;
|
|
1195
|
+
"speech-final": (transcript: string) => any;
|
|
1196
|
+
"speech-end": (transcript?: string | undefined) => any;
|
|
1197
|
+
"speech-error": (error: Error) => any;
|
|
1198
|
+
}, string, {
|
|
1199
|
+
tooltipPlacement: TooltipPlacement;
|
|
1200
|
+
autoInsert: boolean;
|
|
1201
|
+
}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & {
|
|
1202
|
+
beforeCreate?: (() => void) | (() => void)[];
|
|
1203
|
+
created?: (() => void) | (() => void)[];
|
|
1204
|
+
beforeMount?: (() => void) | (() => void)[];
|
|
1205
|
+
mounted?: (() => void) | (() => void)[];
|
|
1206
|
+
beforeUpdate?: (() => void) | (() => void)[];
|
|
1207
|
+
updated?: (() => void) | (() => void)[];
|
|
1208
|
+
activated?: (() => void) | (() => void)[];
|
|
1209
|
+
deactivated?: (() => void) | (() => void)[];
|
|
1210
|
+
beforeDestroy?: (() => void) | (() => void)[];
|
|
1211
|
+
beforeUnmount?: (() => void) | (() => void)[];
|
|
1212
|
+
destroyed?: (() => void) | (() => void)[];
|
|
1213
|
+
unmounted?: (() => void) | (() => void)[];
|
|
1214
|
+
renderTracked?: ((e: DebuggerEvent) => void) | ((e: DebuggerEvent) => void)[];
|
|
1215
|
+
renderTriggered?: ((e: DebuggerEvent) => void) | ((e: DebuggerEvent) => void)[];
|
|
1216
|
+
errorCaptured?: ((err: unknown, instance: ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: ComponentPublicInstance | null, info: string) => boolean | void)[];
|
|
1217
|
+
};
|
|
1218
|
+
$forceUpdate: () => void;
|
|
1219
|
+
$nextTick: nextTick;
|
|
1220
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, OnCleanup]) => any : (...args: [any, any, OnCleanup]) => any, options?: WatchOptions): WatchStopHandle;
|
|
1221
|
+
} & Readonly<{
|
|
1222
|
+
tooltipPlacement: TooltipPlacement;
|
|
1223
|
+
autoInsert: boolean;
|
|
1224
|
+
}> & Omit<Readonly<VoiceButtonProps> & Readonly<{
|
|
1225
|
+
"onSpeech-start"?: (() => any) | undefined;
|
|
1226
|
+
"onSpeech-interim"?: ((transcript: string) => any) | undefined;
|
|
1227
|
+
"onSpeech-final"?: ((transcript: string) => any) | undefined;
|
|
1228
|
+
"onSpeech-end"?: ((transcript?: string | undefined) => any) | undefined;
|
|
1229
|
+
"onSpeech-error"?: ((error: Error) => any) | undefined;
|
|
1230
|
+
}>, "stop" | "start" | "speechState" | ("tooltipPlacement" | "autoInsert")> & ShallowUnwrapRef< {
|
|
1231
|
+
start: () => void;
|
|
1232
|
+
stop: () => void;
|
|
1233
|
+
speechState: SpeechState;
|
|
1234
|
+
}> & {} & ComponentCustomProperties & {} & {
|
|
1235
|
+
$slots: {
|
|
1236
|
+
'recording-overlay'?(_: {
|
|
1237
|
+
isRecording: boolean;
|
|
1238
|
+
stop: () => void;
|
|
1239
|
+
}): any;
|
|
1240
|
+
};
|
|
1241
|
+
}) | null;
|
|
1242
|
+
};
|
|
1243
|
+
rootEl: HTMLDivElement;
|
|
1244
|
+
};
|
|
1245
|
+
|
|
1246
|
+
declare function __VLS_template_8(): {
|
|
1247
|
+
attrs: Partial<{}>;
|
|
1248
|
+
slots: Readonly<SuggestionPillButtonSlots> & SuggestionPillButtonSlots;
|
|
1249
|
+
refs: {};
|
|
1250
|
+
rootEl: HTMLButtonElement;
|
|
1251
|
+
};
|
|
1252
|
+
|
|
1253
|
+
declare function __VLS_template_9(): {
|
|
1254
|
+
attrs: Partial<{}>;
|
|
1255
|
+
slots: Readonly<SuggestionPillsSlots> & SuggestionPillsSlots;
|
|
1256
|
+
refs: {
|
|
1257
|
+
containerWrapperRef: HTMLDivElement;
|
|
1258
|
+
containerRef: HTMLDivElement;
|
|
1259
|
+
staticMaybeItemRefs: unknown[];
|
|
1260
|
+
floatingItemsRef: HTMLDivElement;
|
|
1261
|
+
floatingMaybeItemRefs: unknown[];
|
|
1262
|
+
};
|
|
1263
|
+
rootEl: HTMLDivElement;
|
|
1264
|
+
};
|
|
1265
|
+
|
|
1266
|
+
declare type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
1267
|
+
|
|
1268
|
+
declare type __VLS_TemplateResult_10 = ReturnType<typeof __VLS_template_10>;
|
|
1269
|
+
|
|
1270
|
+
declare type __VLS_TemplateResult_11 = ReturnType<typeof __VLS_template_11>;
|
|
1271
|
+
|
|
1272
|
+
declare type __VLS_TemplateResult_12 = ReturnType<typeof __VLS_template_12>;
|
|
1273
|
+
|
|
1274
|
+
declare type __VLS_TemplateResult_13 = ReturnType<typeof __VLS_template_13>;
|
|
1275
|
+
|
|
1276
|
+
declare type __VLS_TemplateResult_14 = ReturnType<typeof __VLS_template_14>;
|
|
1277
|
+
|
|
1278
|
+
declare type __VLS_TemplateResult_2 = ReturnType<typeof __VLS_template_2>;
|
|
1279
|
+
|
|
1280
|
+
declare type __VLS_TemplateResult_3 = ReturnType<typeof __VLS_template_3>;
|
|
1281
|
+
|
|
1282
|
+
declare type __VLS_TemplateResult_4 = ReturnType<typeof __VLS_template_4>;
|
|
1283
|
+
|
|
1284
|
+
declare type __VLS_TemplateResult_5 = ReturnType<typeof __VLS_template_5>;
|
|
1774
1285
|
|
|
1775
1286
|
declare type __VLS_TemplateResult_6 = ReturnType<typeof __VLS_template_6>;
|
|
1776
1287
|
|
|
@@ -1804,6 +1315,18 @@ declare type __VLS_WithTemplateSlots_12<T, S> = T & {
|
|
|
1804
1315
|
};
|
|
1805
1316
|
};
|
|
1806
1317
|
|
|
1318
|
+
declare type __VLS_WithTemplateSlots_13<T, S> = T & {
|
|
1319
|
+
new (): {
|
|
1320
|
+
$slots: S;
|
|
1321
|
+
};
|
|
1322
|
+
};
|
|
1323
|
+
|
|
1324
|
+
declare type __VLS_WithTemplateSlots_14<T, S> = T & {
|
|
1325
|
+
new (): {
|
|
1326
|
+
$slots: S;
|
|
1327
|
+
};
|
|
1328
|
+
};
|
|
1329
|
+
|
|
1807
1330
|
declare type __VLS_WithTemplateSlots_2<T, S> = T & {
|
|
1808
1331
|
new (): {
|
|
1809
1332
|
$slots: S;
|
|
@@ -1852,28 +1375,42 @@ declare type __VLS_WithTemplateSlots_9<T, S> = T & {
|
|
|
1852
1375
|
};
|
|
1853
1376
|
};
|
|
1854
1377
|
|
|
1855
|
-
|
|
1378
|
+
declare interface ActionButton_2 {
|
|
1856
1379
|
type: string;
|
|
1857
1380
|
label: string;
|
|
1858
1381
|
handler?: (file: Attachment) => void;
|
|
1859
1382
|
}
|
|
1860
1383
|
|
|
1861
|
-
|
|
1862
|
-
|
|
1384
|
+
/**
|
|
1385
|
+
* ActionButton Props
|
|
1386
|
+
*
|
|
1387
|
+
* 基础操作按钮的 Props
|
|
1388
|
+
*/
|
|
1389
|
+
export declare interface ActionButtonProps {
|
|
1390
|
+
/**
|
|
1391
|
+
* 按钮图标
|
|
1392
|
+
*/
|
|
1393
|
+
icon: VNode | Component;
|
|
1394
|
+
/**
|
|
1395
|
+
* 是否禁用
|
|
1396
|
+
*/
|
|
1863
1397
|
disabled?: boolean;
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1398
|
+
/**
|
|
1399
|
+
* 是否激活状态
|
|
1400
|
+
*/
|
|
1401
|
+
active?: boolean;
|
|
1402
|
+
/**
|
|
1403
|
+
* 工具提示
|
|
1404
|
+
*/
|
|
1405
|
+
tooltip?: TooltipContent;
|
|
1406
|
+
/**
|
|
1407
|
+
* Tooltip 位置
|
|
1408
|
+
*/
|
|
1409
|
+
tooltipPlacement?: TooltipPlacement;
|
|
1410
|
+
/**
|
|
1411
|
+
* 按钮大小
|
|
1412
|
+
*/
|
|
1413
|
+
size?: string | number;
|
|
1877
1414
|
}
|
|
1878
1415
|
|
|
1879
1416
|
export declare type AddType = 'form' | 'code';
|
|
@@ -1887,7 +1424,7 @@ export declare interface AttachmentListEmits {
|
|
|
1887
1424
|
(e: 'retry', file: Attachment): void;
|
|
1888
1425
|
(e: 'preview', event: MouseEvent, file: Attachment): void;
|
|
1889
1426
|
(e: 'action', payload: {
|
|
1890
|
-
action:
|
|
1427
|
+
action: ActionButton_2;
|
|
1891
1428
|
file: Attachment;
|
|
1892
1429
|
}): void;
|
|
1893
1430
|
}
|
|
@@ -1897,16 +1434,24 @@ export declare interface AttachmentListProps {
|
|
|
1897
1434
|
disabled?: boolean;
|
|
1898
1435
|
wrap?: boolean;
|
|
1899
1436
|
fileIcons?: Record<string, Component>;
|
|
1900
|
-
actions?:
|
|
1437
|
+
actions?: ActionButton_2[];
|
|
1901
1438
|
variant?: DisplayVariant;
|
|
1902
1439
|
fileMatchers?: FileTypeMatcher[];
|
|
1903
1440
|
}
|
|
1904
1441
|
|
|
1442
|
+
/**
|
|
1443
|
+
* 自动高度配置
|
|
1444
|
+
*/
|
|
1905
1445
|
export declare type AutoSize = boolean | {
|
|
1906
1446
|
minRows: number;
|
|
1907
1447
|
maxRows: number;
|
|
1908
1448
|
};
|
|
1909
1449
|
|
|
1450
|
+
declare type AutoSize_2 = boolean | {
|
|
1451
|
+
minRows: number;
|
|
1452
|
+
maxRows: number;
|
|
1453
|
+
};
|
|
1454
|
+
|
|
1910
1455
|
export declare interface BaseAttachment {
|
|
1911
1456
|
id?: string;
|
|
1912
1457
|
name?: string;
|
|
@@ -1919,13 +1464,7 @@ declare type BaseCardProps = Pick<AttachmentListProps, 'fileIcons' | 'disabled'
|
|
|
1919
1464
|
|
|
1920
1465
|
export declare type BaseFileType = 'image' | 'pdf' | 'word' | 'excel' | 'ppt' | 'folder' | 'other';
|
|
1921
1466
|
|
|
1922
|
-
declare
|
|
1923
|
-
id: string;
|
|
1924
|
-
type: string;
|
|
1925
|
-
content: string;
|
|
1926
|
-
}
|
|
1927
|
-
|
|
1928
|
-
declare const Bubble: typeof _default_18 & {
|
|
1467
|
+
declare const Bubble: typeof _default_25 & {
|
|
1929
1468
|
install: typeof bubbleInstall;
|
|
1930
1469
|
};
|
|
1931
1470
|
export { Bubble }
|
|
@@ -1985,7 +1524,7 @@ export declare type BubbleContentRenderer = BubbleContentFunctionRenderer | Bubb
|
|
|
1985
1524
|
|
|
1986
1525
|
declare const bubbleInstall: (app: App) => void;
|
|
1987
1526
|
|
|
1988
|
-
declare const BubbleList: typeof
|
|
1527
|
+
declare const BubbleList: typeof _default_26 & {
|
|
1989
1528
|
install: typeof bubbleListInstall;
|
|
1990
1529
|
};
|
|
1991
1530
|
export { BubbleList }
|
|
@@ -2045,7 +1584,7 @@ export declare interface BubbleProps extends BubbleCommonProps {
|
|
|
2045
1584
|
aborted?: boolean;
|
|
2046
1585
|
}
|
|
2047
1586
|
|
|
2048
|
-
declare const BubbleProvider: typeof
|
|
1587
|
+
declare const BubbleProvider: typeof _default_27 & {
|
|
2049
1588
|
install: typeof bubbleProviderInstall;
|
|
2050
1589
|
};
|
|
2051
1590
|
export { BubbleProvider }
|
|
@@ -2077,12 +1616,205 @@ export declare interface BubbleSlots {
|
|
|
2077
1616
|
}) => unknown;
|
|
2078
1617
|
}
|
|
2079
1618
|
|
|
2080
|
-
|
|
1619
|
+
declare interface ButtonGroupConfig {
|
|
2081
1620
|
file?: ControlState & fileUploadConfig;
|
|
2082
1621
|
submit?: ControlState;
|
|
2083
1622
|
voice?: VoiceButtonConfig;
|
|
2084
1623
|
}
|
|
2085
1624
|
|
|
1625
|
+
declare const ChatInput: {
|
|
1626
|
+
new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly<SenderProps> & Readonly<{
|
|
1627
|
+
onClear?: (() => any) | undefined;
|
|
1628
|
+
onInput?: ((value: string) => any) | undefined;
|
|
1629
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
1630
|
+
onCancel?: (() => any) | undefined;
|
|
1631
|
+
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
1632
|
+
onSubmit?: ((textContent: string, structuredData?: StructuredData | undefined) => any) | undefined;
|
|
1633
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
1634
|
+
}>, {
|
|
1635
|
+
submit: () => void;
|
|
1636
|
+
clear: () => void;
|
|
1637
|
+
cancel: () => void;
|
|
1638
|
+
focus: () => void;
|
|
1639
|
+
blur: () => void;
|
|
1640
|
+
setContent: (content: string) => void;
|
|
1641
|
+
getContent: () => string;
|
|
1642
|
+
editor: SenderContext["editor"];
|
|
1643
|
+
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
1644
|
+
clear: () => any;
|
|
1645
|
+
input: (value: string) => any;
|
|
1646
|
+
blur: (event: FocusEvent) => any;
|
|
1647
|
+
cancel: () => any;
|
|
1648
|
+
focus: (event: FocusEvent) => any;
|
|
1649
|
+
submit: (textContent: string, structuredData?: StructuredData | undefined) => any;
|
|
1650
|
+
"update:modelValue": (value: string) => any;
|
|
1651
|
+
}, PublicProps, {
|
|
1652
|
+
size: "normal" | "small";
|
|
1653
|
+
placeholder: string;
|
|
1654
|
+
mode: InputMode;
|
|
1655
|
+
autoSize: AutoSize;
|
|
1656
|
+
extensions: Extension[] | any[];
|
|
1657
|
+
submitType: SubmitTrigger;
|
|
1658
|
+
}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {}, HTMLDivElement, ComponentProvideOptions, {
|
|
1659
|
+
P: {};
|
|
1660
|
+
B: {};
|
|
1661
|
+
D: {};
|
|
1662
|
+
C: {};
|
|
1663
|
+
M: {};
|
|
1664
|
+
Defaults: {};
|
|
1665
|
+
}, Readonly<SenderProps> & Readonly<{
|
|
1666
|
+
onClear?: (() => any) | undefined;
|
|
1667
|
+
onInput?: ((value: string) => any) | undefined;
|
|
1668
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
1669
|
+
onCancel?: (() => any) | undefined;
|
|
1670
|
+
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
1671
|
+
onSubmit?: ((textContent: string, structuredData?: StructuredData | undefined) => any) | undefined;
|
|
1672
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
1673
|
+
}>, {
|
|
1674
|
+
submit: () => void;
|
|
1675
|
+
clear: () => void;
|
|
1676
|
+
cancel: () => void;
|
|
1677
|
+
focus: () => void;
|
|
1678
|
+
blur: () => void;
|
|
1679
|
+
setContent: (content: string) => void;
|
|
1680
|
+
getContent: () => string;
|
|
1681
|
+
editor: SenderContext["editor"];
|
|
1682
|
+
}, {}, {}, {}, {
|
|
1683
|
+
size: "normal" | "small";
|
|
1684
|
+
placeholder: string;
|
|
1685
|
+
mode: InputMode;
|
|
1686
|
+
autoSize: AutoSize;
|
|
1687
|
+
extensions: Extension[] | any[];
|
|
1688
|
+
submitType: SubmitTrigger;
|
|
1689
|
+
}>;
|
|
1690
|
+
__isFragment?: never;
|
|
1691
|
+
__isTeleport?: never;
|
|
1692
|
+
__isSuspense?: never;
|
|
1693
|
+
} & ComponentOptionsBase<Readonly<SenderProps> & Readonly<{
|
|
1694
|
+
onClear?: (() => any) | undefined;
|
|
1695
|
+
onInput?: ((value: string) => any) | undefined;
|
|
1696
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
1697
|
+
onCancel?: (() => any) | undefined;
|
|
1698
|
+
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
1699
|
+
onSubmit?: ((textContent: string, structuredData?: StructuredData | undefined) => any) | undefined;
|
|
1700
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
1701
|
+
}>, {
|
|
1702
|
+
submit: () => void;
|
|
1703
|
+
clear: () => void;
|
|
1704
|
+
cancel: () => void;
|
|
1705
|
+
focus: () => void;
|
|
1706
|
+
blur: () => void;
|
|
1707
|
+
setContent: (content: string) => void;
|
|
1708
|
+
getContent: () => string;
|
|
1709
|
+
editor: SenderContext["editor"];
|
|
1710
|
+
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
1711
|
+
clear: () => any;
|
|
1712
|
+
input: (value: string) => any;
|
|
1713
|
+
blur: (event: FocusEvent) => any;
|
|
1714
|
+
cancel: () => any;
|
|
1715
|
+
focus: (event: FocusEvent) => any;
|
|
1716
|
+
submit: (textContent: string, structuredData?: StructuredData | undefined) => any;
|
|
1717
|
+
"update:modelValue": (value: string) => any;
|
|
1718
|
+
}, string, {
|
|
1719
|
+
size: "normal" | "small";
|
|
1720
|
+
placeholder: string;
|
|
1721
|
+
mode: InputMode;
|
|
1722
|
+
autoSize: AutoSize;
|
|
1723
|
+
extensions: Extension[] | any[];
|
|
1724
|
+
submitType: SubmitTrigger;
|
|
1725
|
+
}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & VNodeProps & AllowedComponentProps & ComponentCustomProps & (new () => {
|
|
1726
|
+
$slots: {
|
|
1727
|
+
header?(_: {}): any;
|
|
1728
|
+
header?(_: {}): any;
|
|
1729
|
+
prefix?(_: {}): any;
|
|
1730
|
+
prefix?(_: {}): any;
|
|
1731
|
+
content?(_: {
|
|
1732
|
+
editor: Ref<Editor | undefined, Editor | undefined>;
|
|
1733
|
+
}): any;
|
|
1734
|
+
content?(_: {
|
|
1735
|
+
editor: Ref<Editor | undefined, Editor | undefined>;
|
|
1736
|
+
}): any;
|
|
1737
|
+
'actions-inline'?(_: {}): any;
|
|
1738
|
+
footer?(_: {}): any;
|
|
1739
|
+
'footer-right'?(_: {}): any;
|
|
1740
|
+
};
|
|
1741
|
+
}) & {
|
|
1742
|
+
install: <T>(app: App<T>) => void;
|
|
1743
|
+
Mention: Node_2<MentionOptions, any>;
|
|
1744
|
+
Suggestion: Extension<SuggestionOptions, any>;
|
|
1745
|
+
Template: Extension<TemplateOptions, any>;
|
|
1746
|
+
mention: typeof mention;
|
|
1747
|
+
suggestion: typeof suggestion;
|
|
1748
|
+
template: typeof template;
|
|
1749
|
+
};
|
|
1750
|
+
|
|
1751
|
+
/**
|
|
1752
|
+
* ChatInput 插槽作用域
|
|
1753
|
+
*
|
|
1754
|
+
* 通过插槽作用域暴露给外部组件的状态和方法
|
|
1755
|
+
* 主要为增强按钮(Upload、Voice 等)提供便捷的操作方法
|
|
1756
|
+
*/
|
|
1757
|
+
declare interface ChatInputSlotScope {
|
|
1758
|
+
/**
|
|
1759
|
+
* Tiptap 编辑器实例
|
|
1760
|
+
* 用于高级操作
|
|
1761
|
+
*/
|
|
1762
|
+
editor: Editor_2 | undefined;
|
|
1763
|
+
/**
|
|
1764
|
+
* 聚焦编辑器
|
|
1765
|
+
*/
|
|
1766
|
+
focus: () => void;
|
|
1767
|
+
/**
|
|
1768
|
+
* 失焦编辑器
|
|
1769
|
+
*/
|
|
1770
|
+
blur: () => void;
|
|
1771
|
+
/**
|
|
1772
|
+
* 插入内容到当前光标位置
|
|
1773
|
+
*
|
|
1774
|
+
* 适用场景:语音输入、快捷短语插入
|
|
1775
|
+
*
|
|
1776
|
+
* @param content - 要插入的内容
|
|
1777
|
+
* @example
|
|
1778
|
+
* ```vue
|
|
1779
|
+
* <template #actions-inline="{ insert }">
|
|
1780
|
+
* <VoiceButton @speech-final="insert" />
|
|
1781
|
+
* </template>
|
|
1782
|
+
* ```
|
|
1783
|
+
*/
|
|
1784
|
+
insert: (content: string) => void;
|
|
1785
|
+
/**
|
|
1786
|
+
* 追加内容到编辑器末尾
|
|
1787
|
+
*
|
|
1788
|
+
* 适用场景:连续语音输入、批量添加内容
|
|
1789
|
+
*
|
|
1790
|
+
* @param content - 要追加的内容
|
|
1791
|
+
*/
|
|
1792
|
+
append: (content: string) => void;
|
|
1793
|
+
/**
|
|
1794
|
+
* 替换编辑器全部内容
|
|
1795
|
+
*
|
|
1796
|
+
* 适用场景:模板填充、内容重置
|
|
1797
|
+
*
|
|
1798
|
+
* @param content - 新内容
|
|
1799
|
+
*/
|
|
1800
|
+
replace: (content: string) => void;
|
|
1801
|
+
/**
|
|
1802
|
+
* 是否禁用
|
|
1803
|
+
* 用于控制自定义按钮状态
|
|
1804
|
+
*/
|
|
1805
|
+
disabled: boolean;
|
|
1806
|
+
/**
|
|
1807
|
+
* 是否加载中
|
|
1808
|
+
* 用于控制按钮加载状态和禁用
|
|
1809
|
+
*/
|
|
1810
|
+
loading: boolean;
|
|
1811
|
+
/**
|
|
1812
|
+
* 是否有内容
|
|
1813
|
+
* 用于控制按钮显示/隐藏
|
|
1814
|
+
*/
|
|
1815
|
+
hasContent: boolean;
|
|
1816
|
+
}
|
|
1817
|
+
|
|
2086
1818
|
export declare type ColorMode = 'light' | 'dark' | 'auto';
|
|
2087
1819
|
|
|
2088
1820
|
export declare interface ContainerEmits {
|
|
@@ -2108,7 +1840,7 @@ export declare interface ContainerSlots {
|
|
|
2108
1840
|
footer: () => unknown;
|
|
2109
1841
|
}
|
|
2110
1842
|
|
|
2111
|
-
|
|
1843
|
+
declare interface ControlState {
|
|
2112
1844
|
tooltips?: string | TooltipRender;
|
|
2113
1845
|
disabled?: boolean;
|
|
2114
1846
|
tooltipPlacement?: 'top' | 'top-start' | 'top-end' | 'bottom' | 'bottom-start' | 'bottom-end' | 'left' | 'left-start' | 'left-end' | 'right' | 'right-start' | 'right-end';
|
|
@@ -2119,56 +1851,103 @@ declare const _default: {
|
|
|
2119
1851
|
};
|
|
2120
1852
|
export default _default;
|
|
2121
1853
|
|
|
2122
|
-
declare const _default_10: typeof
|
|
1854
|
+
declare const _default_10: typeof _default_37 & {
|
|
2123
1855
|
install: typeof install_9;
|
|
2124
1856
|
};
|
|
2125
|
-
export { _default_10 as
|
|
2126
|
-
export { _default_10 as
|
|
1857
|
+
export { _default_10 as SenderCompat }
|
|
1858
|
+
export { _default_10 as TrSenderCompat }
|
|
2127
1859
|
|
|
2128
|
-
declare const _default_11: typeof
|
|
1860
|
+
declare const _default_11: typeof _default_39 & {
|
|
2129
1861
|
install: typeof install_10;
|
|
2130
1862
|
};
|
|
2131
1863
|
export { _default_11 as SuggestionPills }
|
|
2132
1864
|
export { _default_11 as TrSuggestionPills }
|
|
2133
1865
|
|
|
2134
|
-
declare const _default_12: typeof
|
|
1866
|
+
declare const _default_12: typeof _default_40 & {
|
|
2135
1867
|
install: typeof install_11;
|
|
2136
1868
|
};
|
|
2137
1869
|
export { _default_12 as SuggestionPopover }
|
|
2138
1870
|
export { _default_12 as TrSuggestionPopover }
|
|
2139
1871
|
|
|
2140
|
-
declare const _default_13: typeof
|
|
1872
|
+
declare const _default_13: typeof _default_41 & {
|
|
2141
1873
|
install: typeof install_12;
|
|
2142
1874
|
};
|
|
2143
1875
|
export { _default_13 as ThemeProvider }
|
|
2144
1876
|
export { _default_13 as TrThemeProvider }
|
|
2145
1877
|
|
|
2146
|
-
declare const _default_14: typeof
|
|
1878
|
+
declare const _default_14: typeof _default_42 & {
|
|
2147
1879
|
install: typeof install_13;
|
|
2148
1880
|
};
|
|
2149
1881
|
export { _default_14 as TrWelcome }
|
|
2150
1882
|
export { _default_14 as Welcome }
|
|
2151
1883
|
|
|
2152
|
-
declare const _default_15: typeof
|
|
1884
|
+
declare const _default_15: typeof _default_43 & {
|
|
2153
1885
|
install: typeof install_14;
|
|
2154
1886
|
};
|
|
2155
1887
|
export { _default_15 as McpServerPicker }
|
|
2156
1888
|
export { _default_15 as TrMcpServerPicker }
|
|
2157
1889
|
|
|
2158
|
-
declare const _default_16: typeof
|
|
1890
|
+
declare const _default_16: typeof _default_44 & {
|
|
2159
1891
|
install: typeof install_15;
|
|
2160
1892
|
};
|
|
2161
1893
|
export { _default_16 as McpAddForm }
|
|
2162
1894
|
export { _default_16 as TrMcpAddForm }
|
|
2163
1895
|
|
|
2164
|
-
declare const _default_17:
|
|
1896
|
+
declare const _default_17: __VLS_WithTemplateSlots_13<typeof __VLS_component_13, __VLS_TemplateResult_13["slots"]>;
|
|
1897
|
+
export { _default_17 as ActionButton }
|
|
1898
|
+
export { _default_17 as TrActionButton }
|
|
1899
|
+
|
|
1900
|
+
declare const _default_18: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
|
1901
|
+
export { _default_18 as SubmitButton }
|
|
1902
|
+
export { _default_18 as TrSubmitButton }
|
|
1903
|
+
|
|
1904
|
+
declare const _default_19: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
|
1905
|
+
export { _default_19 as ClearButton }
|
|
1906
|
+
export { _default_19 as TrClearButton }
|
|
1907
|
+
|
|
1908
|
+
declare const _default_2: typeof _default_24 & {
|
|
1909
|
+
install: typeof install;
|
|
1910
|
+
};
|
|
1911
|
+
export { _default_2 as Attachments }
|
|
1912
|
+
export { _default_2 as TrAttachments }
|
|
1913
|
+
|
|
1914
|
+
declare const _default_20: DefineComponent<UploadButtonProps, {
|
|
1915
|
+
open: (localOptions?: Partial<UseFileDialogOptions>) => void;
|
|
1916
|
+
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
1917
|
+
error: (error: Error, file?: File | undefined) => any;
|
|
1918
|
+
select: (files: File[]) => any;
|
|
1919
|
+
}, string, PublicProps, Readonly<UploadButtonProps> & Readonly<{
|
|
1920
|
+
onError?: ((error: Error, file?: File | undefined) => any) | undefined;
|
|
1921
|
+
onSelect?: ((files: File[]) => any) | undefined;
|
|
1922
|
+
}>, {
|
|
1923
|
+
reset: boolean;
|
|
1924
|
+
multiple: boolean;
|
|
1925
|
+
tooltipPlacement: TooltipPlacement;
|
|
1926
|
+
accept: string;
|
|
1927
|
+
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
1928
|
+
export { _default_20 as TrUploadButton }
|
|
1929
|
+
export { _default_20 as UploadButton }
|
|
1930
|
+
|
|
1931
|
+
declare const _default_21: __VLS_WithTemplateSlots_14<typeof __VLS_component_14, __VLS_TemplateResult_14["slots"]>;
|
|
1932
|
+
export { _default_21 as TrVoiceButton }
|
|
1933
|
+
export { _default_21 as VoiceButton }
|
|
1934
|
+
|
|
1935
|
+
declare const _default_22: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
|
1936
|
+
export { _default_22 as TrWordCounter }
|
|
1937
|
+
export { _default_22 as WordCounter }
|
|
1938
|
+
|
|
1939
|
+
declare const _default_23: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, HTMLDivElement>;
|
|
1940
|
+
export { _default_23 as DefaultActionButtons }
|
|
1941
|
+
export { _default_23 as TrDefaultActionButtons }
|
|
1942
|
+
|
|
1943
|
+
declare const _default_24: DefineComponent<AttachmentListProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
2165
1944
|
"update:items": (items: Attachment[]) => any;
|
|
2166
1945
|
remove: (file: Attachment) => any;
|
|
2167
1946
|
download: (event: MouseEvent, file: Attachment) => any;
|
|
2168
1947
|
retry: (file: Attachment) => any;
|
|
2169
1948
|
preview: (event: MouseEvent, file: Attachment) => any;
|
|
2170
1949
|
action: (payload: {
|
|
2171
|
-
action:
|
|
1950
|
+
action: ActionButton_2;
|
|
2172
1951
|
file: Attachment;
|
|
2173
1952
|
}) => any;
|
|
2174
1953
|
}, string, PublicProps, Readonly<AttachmentListProps> & Readonly<{
|
|
@@ -2178,38 +1957,38 @@ onDownload?: ((event: MouseEvent, file: Attachment) => any) | undefined;
|
|
|
2178
1957
|
onRetry?: ((file: Attachment) => any) | undefined;
|
|
2179
1958
|
onPreview?: ((event: MouseEvent, file: Attachment) => any) | undefined;
|
|
2180
1959
|
onAction?: ((payload: {
|
|
2181
|
-
action:
|
|
1960
|
+
action: ActionButton_2;
|
|
2182
1961
|
file: Attachment;
|
|
2183
1962
|
}) => any) | undefined;
|
|
2184
1963
|
}>, {
|
|
2185
|
-
actions:
|
|
1964
|
+
actions: ActionButton_2[];
|
|
2186
1965
|
fileMatchers: FileTypeMatcher[];
|
|
2187
1966
|
variant: DisplayVariant;
|
|
2188
1967
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
2189
1968
|
|
|
2190
|
-
declare const
|
|
1969
|
+
declare const _default_25: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
2191
1970
|
|
|
2192
|
-
declare const
|
|
1971
|
+
declare const _default_26: DefineComponent<BubbleListProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<BubbleListProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {
|
|
2193
1972
|
scrollContainerRef: HTMLDivElement;
|
|
2194
1973
|
}, HTMLDivElement>;
|
|
2195
1974
|
|
|
2196
|
-
declare const
|
|
2197
|
-
install: typeof install;
|
|
2198
|
-
};
|
|
2199
|
-
export { _default_2 as Attachments }
|
|
2200
|
-
export { _default_2 as TrAttachments }
|
|
1975
|
+
declare const _default_27: __VLS_WithTemplateSlots_2<typeof __VLS_component_2, __VLS_TemplateResult_2["slots"]>;
|
|
2201
1976
|
|
|
2202
|
-
declare const
|
|
1977
|
+
declare const _default_28: __VLS_WithTemplateSlots_3<typeof __VLS_component_3, __VLS_TemplateResult_3["slots"]>;
|
|
2203
1978
|
|
|
2204
|
-
declare const
|
|
1979
|
+
declare const _default_29: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
|
2205
1980
|
|
|
2206
|
-
declare const
|
|
1981
|
+
declare const _default_3: typeof _default_28 & {
|
|
1982
|
+
install: typeof install_2;
|
|
1983
|
+
};
|
|
1984
|
+
export { _default_3 as Container }
|
|
1985
|
+
export { _default_3 as TrContainer }
|
|
2207
1986
|
|
|
2208
|
-
declare const
|
|
1987
|
+
declare const _default_30: __VLS_WithTemplateSlots_4<typeof __VLS_component_4, __VLS_TemplateResult_4["slots"]>;
|
|
2209
1988
|
|
|
2210
|
-
declare const
|
|
1989
|
+
declare const _default_31: __VLS_WithTemplateSlots_5<typeof __VLS_component_5, __VLS_TemplateResult_5["slots"]>;
|
|
2211
1990
|
|
|
2212
|
-
declare const
|
|
1991
|
+
declare const _default_32: DefineComponent<FeedbackProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
2213
1992
|
action: (name: string) => any;
|
|
2214
1993
|
operation: (name: string) => any;
|
|
2215
1994
|
}, string, PublicProps, Readonly<FeedbackProps> & Readonly<{
|
|
@@ -2221,7 +2000,7 @@ actionsLimit: number;
|
|
|
2221
2000
|
sourcesLinesLimit: number;
|
|
2222
2001
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
2223
2002
|
|
|
2224
|
-
declare const
|
|
2003
|
+
declare const _default_33: <T extends HistoryItem>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
2225
2004
|
props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
|
|
2226
2005
|
readonly "onItem-click"?: ((item: T) => any) | undefined;
|
|
2227
2006
|
readonly "onItem-title-change"?: ((newTitle: string, item: T) => any) | undefined;
|
|
@@ -2235,36 +2014,36 @@ declare const _default_26: <T extends HistoryItem>(__VLS_props: NonNullable<Awai
|
|
|
2235
2014
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
2236
2015
|
};
|
|
2237
2016
|
|
|
2238
|
-
declare const
|
|
2017
|
+
declare const _default_34: DefineComponent<IconButtonProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<IconButtonProps> & Readonly<{}>, {
|
|
2239
2018
|
size: string | number;
|
|
2240
2019
|
svgSize: string | number;
|
|
2241
2020
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLButtonElement>;
|
|
2242
2021
|
|
|
2243
|
-
declare const
|
|
2022
|
+
declare const _default_35: DefineComponent<PromptProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<PromptProps> & Readonly<{}>, {
|
|
2244
2023
|
size: "small" | "medium" | "large";
|
|
2245
2024
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
2246
2025
|
|
|
2247
|
-
declare const
|
|
2026
|
+
declare const _default_36: __VLS_WithTemplateSlots_6<typeof __VLS_component_6, __VLS_TemplateResult_6["slots"]>;
|
|
2248
2027
|
|
|
2249
|
-
declare const
|
|
2250
|
-
install: typeof install_2;
|
|
2251
|
-
};
|
|
2252
|
-
export { _default_3 as Container }
|
|
2253
|
-
export { _default_3 as TrContainer }
|
|
2028
|
+
declare const _default_37: __VLS_WithTemplateSlots_7<typeof __VLS_component_7, __VLS_TemplateResult_7["slots"]>;
|
|
2254
2029
|
|
|
2255
|
-
declare const
|
|
2030
|
+
declare const _default_38: __VLS_WithTemplateSlots_8<typeof __VLS_component_8, __VLS_TemplateResult_8["slots"]>;
|
|
2256
2031
|
|
|
2257
|
-
declare const
|
|
2032
|
+
declare const _default_39: __VLS_WithTemplateSlots_9<typeof __VLS_component_9, __VLS_TemplateResult_9["slots"]>;
|
|
2258
2033
|
|
|
2259
|
-
declare const
|
|
2034
|
+
declare const _default_4: typeof _default_29 & {
|
|
2035
|
+
install: typeof install_3;
|
|
2036
|
+
};
|
|
2037
|
+
export { _default_4 as Conversations }
|
|
2038
|
+
export { _default_4 as TrConversations }
|
|
2260
2039
|
|
|
2261
|
-
declare const
|
|
2040
|
+
declare const _default_40: __VLS_WithTemplateSlots_10<typeof __VLS_component_10, __VLS_TemplateResult_10["slots"]>;
|
|
2262
2041
|
|
|
2263
|
-
declare const
|
|
2042
|
+
declare const _default_41: __VLS_WithTemplateSlots_11<typeof __VLS_component_11, __VLS_TemplateResult_11["slots"]>;
|
|
2264
2043
|
|
|
2265
|
-
declare const
|
|
2044
|
+
declare const _default_42: __VLS_WithTemplateSlots_12<typeof __VLS_component_12, __VLS_TemplateResult_12["slots"]>;
|
|
2266
2045
|
|
|
2267
|
-
declare const
|
|
2046
|
+
declare const _default_43: DefineComponent<__VLS_PublicProps_6, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
|
|
2268
2047
|
"update:visible": (value: boolean) => any;
|
|
2269
2048
|
} & {
|
|
2270
2049
|
refresh: (tab: "installed" | "market") => any;
|
|
@@ -2315,7 +2094,7 @@ allowPluginAdd: boolean;
|
|
|
2315
2094
|
marketLoading: boolean;
|
|
2316
2095
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
2317
2096
|
|
|
2318
|
-
declare const
|
|
2097
|
+
declare const _default_44: DefineComponent<McpAddFormProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
2319
2098
|
cancel: () => any;
|
|
2320
2099
|
confirm: (type: AddType, data: string | McpAddFormData) => any;
|
|
2321
2100
|
"update:addType": (value: AddType) => any;
|
|
@@ -2327,42 +2106,90 @@ onConfirm?: ((type: AddType, data: string | McpAddFormData) => any) | undefined;
|
|
|
2327
2106
|
addType: AddType;
|
|
2328
2107
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
2329
2108
|
|
|
2330
|
-
declare const
|
|
2331
|
-
install: typeof
|
|
2332
|
-
};
|
|
2333
|
-
export { _default_4 as Conversations }
|
|
2334
|
-
export { _default_4 as TrConversations }
|
|
2335
|
-
|
|
2336
|
-
declare const _default_5: typeof _default_23 & {
|
|
2337
|
-
install: typeof install_4;
|
|
2109
|
+
declare const _default_5: typeof _default_30 & {
|
|
2110
|
+
install: typeof install_4;
|
|
2338
2111
|
};
|
|
2339
2112
|
export { _default_5 as DragOverlay }
|
|
2340
2113
|
export { _default_5 as TrDragOverlay }
|
|
2341
2114
|
|
|
2342
|
-
declare const _default_6: typeof
|
|
2115
|
+
declare const _default_6: typeof _default_31 & {
|
|
2343
2116
|
install: typeof install_5;
|
|
2344
2117
|
};
|
|
2345
2118
|
export { _default_6 as DropdownMenu }
|
|
2346
2119
|
export { _default_6 as TrDropdownMenu }
|
|
2347
2120
|
|
|
2348
|
-
declare const _default_7: typeof
|
|
2121
|
+
declare const _default_7: typeof _default_32 & {
|
|
2349
2122
|
install: typeof install_6;
|
|
2350
2123
|
};
|
|
2351
2124
|
export { _default_7 as Feedback }
|
|
2352
2125
|
export { _default_7 as TrFeedback }
|
|
2353
2126
|
|
|
2354
|
-
declare const _default_8: typeof
|
|
2127
|
+
declare const _default_8: typeof _default_33 & {
|
|
2355
2128
|
install: typeof install_7;
|
|
2356
2129
|
};
|
|
2357
2130
|
export { _default_8 as History }
|
|
2358
2131
|
export { _default_8 as TrHistory }
|
|
2359
2132
|
|
|
2360
|
-
declare const _default_9: typeof
|
|
2133
|
+
declare const _default_9: typeof _default_34 & {
|
|
2361
2134
|
install: typeof install_8;
|
|
2362
2135
|
};
|
|
2363
2136
|
export { _default_9 as IconButton }
|
|
2364
2137
|
export { _default_9 as TrIconButton }
|
|
2365
2138
|
|
|
2139
|
+
/**
|
|
2140
|
+
* 默认操作按钮配置
|
|
2141
|
+
*
|
|
2142
|
+
* 用于统一配置 ChatInput 的默认按钮(Clear、Submit)
|
|
2143
|
+
*
|
|
2144
|
+
* @example
|
|
2145
|
+
* ```typescript
|
|
2146
|
+
* const defaultActions = {
|
|
2147
|
+
* submit: { disabled: !isValid, tooltip: '请完善表单' },
|
|
2148
|
+
* clear: { tooltip: '清空内容' }
|
|
2149
|
+
* }
|
|
2150
|
+
* ```
|
|
2151
|
+
*/
|
|
2152
|
+
export declare interface DefaultActions {
|
|
2153
|
+
/**
|
|
2154
|
+
* 提交按钮配置
|
|
2155
|
+
*/
|
|
2156
|
+
submit?: {
|
|
2157
|
+
/**
|
|
2158
|
+
* 是否禁用
|
|
2159
|
+
*/
|
|
2160
|
+
disabled?: boolean;
|
|
2161
|
+
/**
|
|
2162
|
+
* 工具提示
|
|
2163
|
+
* - string: 简单文本
|
|
2164
|
+
* - () => string | VNode: 渲染函数,支持复杂内容
|
|
2165
|
+
*/
|
|
2166
|
+
tooltip?: TooltipContent;
|
|
2167
|
+
/**
|
|
2168
|
+
* Tooltip 位置
|
|
2169
|
+
*/
|
|
2170
|
+
tooltipPlacement?: TooltipPlacement;
|
|
2171
|
+
};
|
|
2172
|
+
/**
|
|
2173
|
+
* 清空按钮配置
|
|
2174
|
+
*/
|
|
2175
|
+
clear?: {
|
|
2176
|
+
/**
|
|
2177
|
+
* 是否禁用
|
|
2178
|
+
*/
|
|
2179
|
+
disabled?: boolean;
|
|
2180
|
+
/**
|
|
2181
|
+
* 工具提示
|
|
2182
|
+
* - string: 简单文本
|
|
2183
|
+
* - () => string | VNode: 渲染函数,支持复杂内容
|
|
2184
|
+
*/
|
|
2185
|
+
tooltip?: TooltipContent;
|
|
2186
|
+
/**
|
|
2187
|
+
* Tooltip 位置
|
|
2188
|
+
*/
|
|
2189
|
+
tooltipPlacement?: TooltipPlacement;
|
|
2190
|
+
};
|
|
2191
|
+
}
|
|
2192
|
+
|
|
2366
2193
|
export declare type DisplayVariant = 'picture' | 'card' | 'auto';
|
|
2367
2194
|
|
|
2368
2195
|
declare interface DragAwareElement extends HTMLElement {
|
|
@@ -2557,7 +2384,7 @@ export declare interface FileCardEmits {
|
|
|
2557
2384
|
(e: 'download', event: MouseEvent, file: Attachment): void;
|
|
2558
2385
|
(e: 'retry', file: Attachment): void;
|
|
2559
2386
|
(e: 'action', payload: {
|
|
2560
|
-
action:
|
|
2387
|
+
action: ActionButton_2;
|
|
2561
2388
|
file: Attachment;
|
|
2562
2389
|
}): void;
|
|
2563
2390
|
}
|
|
@@ -2598,7 +2425,16 @@ export declare interface Handlers {
|
|
|
2598
2425
|
handleDrop: (e: DragEvent) => void;
|
|
2599
2426
|
}
|
|
2600
2427
|
|
|
2601
|
-
|
|
2428
|
+
/**
|
|
2429
|
+
* 高亮函数类型
|
|
2430
|
+
*
|
|
2431
|
+
* @param suggestionText - 建议项文本
|
|
2432
|
+
* @param inputText - 用户输入文本
|
|
2433
|
+
* @returns 包含文本片段和匹配状态的数组
|
|
2434
|
+
*/
|
|
2435
|
+
export declare type HighlightFunction = (suggestionText: string, inputText: string) => SuggestionTextPart[];
|
|
2436
|
+
|
|
2437
|
+
declare type HighlightFunction_2 = (suggestionText: string, inputText: string) => SuggestionTextPart_2[];
|
|
2602
2438
|
|
|
2603
2439
|
export declare type HistoryData<T extends HistoryItem> = T[] | HistoryGroup<T>[];
|
|
2604
2440
|
|
|
@@ -2645,14 +2481,15 @@ export declare interface IconButtonProps {
|
|
|
2645
2481
|
rounded?: boolean;
|
|
2646
2482
|
}
|
|
2647
2483
|
|
|
2648
|
-
|
|
2649
|
-
|
|
2650
|
-
|
|
2651
|
-
|
|
2652
|
-
|
|
2653
|
-
|
|
2484
|
+
/**
|
|
2485
|
+
* 输入模式
|
|
2486
|
+
* - single: 单行模式,适用于简短输入
|
|
2487
|
+
* - multiple: 多行模式,适用于长文本输入
|
|
2488
|
+
*/
|
|
2654
2489
|
export declare type InputMode = 'single' | 'multiple';
|
|
2655
2490
|
|
|
2491
|
+
declare type InputMode_2 = 'single' | 'multiple';
|
|
2492
|
+
|
|
2656
2493
|
declare const install: <T>(app: App<T>) => void;
|
|
2657
2494
|
|
|
2658
2495
|
declare const install_10: <T>(app: App<T>) => void;
|
|
@@ -2689,14 +2526,9 @@ declare const installPrompt: <T>(app: App<T>) => void;
|
|
|
2689
2526
|
|
|
2690
2527
|
declare const installPrompts: <T>(app: App<T>) => void;
|
|
2691
2528
|
|
|
2692
|
-
|
|
2529
|
+
declare interface ISuggestionItem {
|
|
2693
2530
|
content: string;
|
|
2694
|
-
highlights?: string[] |
|
|
2695
|
-
}
|
|
2696
|
-
|
|
2697
|
-
export declare interface KeyboardHandler {
|
|
2698
|
-
handleKeyPress: (e: KeyboardEvent) => void;
|
|
2699
|
-
triggerSubmit: () => void;
|
|
2531
|
+
highlights?: string[] | HighlightFunction_2;
|
|
2700
2532
|
}
|
|
2701
2533
|
|
|
2702
2534
|
export declare interface MarketCategoryOption {
|
|
@@ -2767,6 +2599,106 @@ export declare interface McpServerPickerProps {
|
|
|
2767
2599
|
marketLoading?: boolean;
|
|
2768
2600
|
}
|
|
2769
2601
|
|
|
2602
|
+
/**
|
|
2603
|
+
* 创建 Mention 扩展的便捷函数
|
|
2604
|
+
*
|
|
2605
|
+
* @param items - 提及项列表
|
|
2606
|
+
* @param char - 触发字符,默认 '@'
|
|
2607
|
+
* @param options - 其他配置项
|
|
2608
|
+
*
|
|
2609
|
+
* @example
|
|
2610
|
+
* ```typescript
|
|
2611
|
+
* const extensions = [mention(items)]
|
|
2612
|
+
* const extensions = [mention(items, '#')]
|
|
2613
|
+
* const extensions = [mention(items, '@', { allowSpaces: true })]
|
|
2614
|
+
* ```
|
|
2615
|
+
*/
|
|
2616
|
+
declare function mention(items: MentionItem[] | Ref<MentionItem[]>, char?: string, options?: Partial<Omit<MentionOptions, 'items' | 'char'>>): Node_2<MentionOptions, any>;
|
|
2617
|
+
|
|
2618
|
+
/**
|
|
2619
|
+
* Mention 节点属性(内部使用)
|
|
2620
|
+
*
|
|
2621
|
+
* ProseMirror 节点的属性,id 必填(由插件保证)
|
|
2622
|
+
*/
|
|
2623
|
+
export declare interface MentionAttrs {
|
|
2624
|
+
/**
|
|
2625
|
+
* 唯一标识(必填)
|
|
2626
|
+
*
|
|
2627
|
+
* 由插件自动生成或使用用户提供的值
|
|
2628
|
+
*/
|
|
2629
|
+
id: string;
|
|
2630
|
+
/**
|
|
2631
|
+
* 显示名称
|
|
2632
|
+
*/
|
|
2633
|
+
label: string;
|
|
2634
|
+
/**
|
|
2635
|
+
* 预设内容(可选)
|
|
2636
|
+
*/
|
|
2637
|
+
preset?: string;
|
|
2638
|
+
}
|
|
2639
|
+
|
|
2640
|
+
/**
|
|
2641
|
+
* 提及项数据结构(用户侧)
|
|
2642
|
+
*
|
|
2643
|
+
* 用户传入的数据格式,id 可选,插件会自动生成
|
|
2644
|
+
*/
|
|
2645
|
+
export declare interface MentionItem {
|
|
2646
|
+
/**
|
|
2647
|
+
* 唯一标识(可选)
|
|
2648
|
+
*
|
|
2649
|
+
* 如果不提供,插件会自动生成
|
|
2650
|
+
*/
|
|
2651
|
+
id?: string;
|
|
2652
|
+
/**
|
|
2653
|
+
* 显示名称,如 "小小画家"(必传)
|
|
2654
|
+
*/
|
|
2655
|
+
label: string;
|
|
2656
|
+
/**
|
|
2657
|
+
* 预设内容(必传)
|
|
2658
|
+
*/
|
|
2659
|
+
preset: string;
|
|
2660
|
+
/**
|
|
2661
|
+
* 图标(可选)
|
|
2662
|
+
*/
|
|
2663
|
+
icon?: string;
|
|
2664
|
+
}
|
|
2665
|
+
|
|
2666
|
+
/**
|
|
2667
|
+
* Mention 配置选项
|
|
2668
|
+
*/
|
|
2669
|
+
export declare interface MentionOptions {
|
|
2670
|
+
/**
|
|
2671
|
+
* 提及项列表
|
|
2672
|
+
*/
|
|
2673
|
+
items: MentionItem[] | Ref<MentionItem[]>;
|
|
2674
|
+
/**
|
|
2675
|
+
* 触发字符,默认 '@'
|
|
2676
|
+
*/
|
|
2677
|
+
char: string;
|
|
2678
|
+
/**
|
|
2679
|
+
* 是否允许空格,默认 false
|
|
2680
|
+
*/
|
|
2681
|
+
allowSpaces?: boolean;
|
|
2682
|
+
/**
|
|
2683
|
+
* HTML 属性
|
|
2684
|
+
*/
|
|
2685
|
+
HTMLAttributes?: Record<string, unknown>;
|
|
2686
|
+
}
|
|
2687
|
+
|
|
2688
|
+
/**
|
|
2689
|
+
* 结构化数据项(提交时返回)
|
|
2690
|
+
*
|
|
2691
|
+
* 用于表示文本和 mention 的混合结构
|
|
2692
|
+
*/
|
|
2693
|
+
export declare type MentionStructuredItem = {
|
|
2694
|
+
type: 'text';
|
|
2695
|
+
content: string;
|
|
2696
|
+
} | {
|
|
2697
|
+
type: 'mention';
|
|
2698
|
+
content: string;
|
|
2699
|
+
preset: string;
|
|
2700
|
+
};
|
|
2701
|
+
|
|
2770
2702
|
export declare type PluginAddState = 'idle' | 'loading' | 'added';
|
|
2771
2703
|
|
|
2772
2704
|
export declare interface PluginCardEmits {
|
|
@@ -2832,7 +2764,7 @@ export declare interface PopupConfig {
|
|
|
2832
2764
|
};
|
|
2833
2765
|
}
|
|
2834
2766
|
|
|
2835
|
-
declare const Prompt: typeof
|
|
2767
|
+
declare const Prompt: typeof _default_35 & {
|
|
2836
2768
|
install: typeof installPrompt;
|
|
2837
2769
|
};
|
|
2838
2770
|
export { Prompt }
|
|
@@ -2869,7 +2801,7 @@ export declare interface PromptProps {
|
|
|
2869
2801
|
size?: 'small' | 'medium' | 'large';
|
|
2870
2802
|
}
|
|
2871
2803
|
|
|
2872
|
-
declare const Prompts: typeof
|
|
2804
|
+
declare const Prompts: typeof _default_36 & {
|
|
2873
2805
|
install: typeof installPrompts;
|
|
2874
2806
|
};
|
|
2875
2807
|
export { Prompts }
|
|
@@ -2920,27 +2852,411 @@ export declare interface RejectionReason {
|
|
|
2920
2852
|
message: string;
|
|
2921
2853
|
}
|
|
2922
2854
|
|
|
2923
|
-
|
|
2855
|
+
/**
|
|
2856
|
+
* 选择器选项
|
|
2857
|
+
*/
|
|
2858
|
+
export declare interface SelectOption {
|
|
2859
|
+
/**
|
|
2860
|
+
* 显示文本
|
|
2861
|
+
*/
|
|
2862
|
+
label: string;
|
|
2863
|
+
/**
|
|
2864
|
+
* 选择后的值
|
|
2865
|
+
*/
|
|
2866
|
+
value: string;
|
|
2867
|
+
/**
|
|
2868
|
+
* 自定义数据(可选)
|
|
2869
|
+
*/
|
|
2870
|
+
data?: string;
|
|
2871
|
+
}
|
|
2872
|
+
|
|
2873
|
+
/**
|
|
2874
|
+
* 选择器选项
|
|
2875
|
+
*/
|
|
2876
|
+
declare interface SelectOption_2 {
|
|
2877
|
+
/**
|
|
2878
|
+
* 显示文本
|
|
2879
|
+
*/
|
|
2880
|
+
label: string;
|
|
2881
|
+
/**
|
|
2882
|
+
* 选择后的值
|
|
2883
|
+
*/
|
|
2884
|
+
value: string;
|
|
2885
|
+
/**
|
|
2886
|
+
* 自定义数据(可选)
|
|
2887
|
+
*/
|
|
2888
|
+
data?: string;
|
|
2889
|
+
}
|
|
2890
|
+
|
|
2891
|
+
declare const Sender: typeof ChatInput;
|
|
2892
|
+
export { Sender }
|
|
2893
|
+
export { Sender as TrSender }
|
|
2894
|
+
|
|
2895
|
+
/**
|
|
2896
|
+
* Chat-Input Context
|
|
2897
|
+
*
|
|
2898
|
+
* 通过 provide/inject 在组件树中共享的状态和方法
|
|
2899
|
+
* 所有子组件都可以通过 inject 获取
|
|
2900
|
+
*/
|
|
2901
|
+
export declare interface SenderContext {
|
|
2902
|
+
/**
|
|
2903
|
+
* Tiptap 编辑器实例
|
|
2904
|
+
* 注意:Tiptap 的 useEditor 返回 ShallowRef<Editor | undefined>
|
|
2905
|
+
*/
|
|
2906
|
+
editor: Ref<Editor | undefined>;
|
|
2907
|
+
/**
|
|
2908
|
+
* 编辑器 DOM 引用
|
|
2909
|
+
*/
|
|
2910
|
+
editorRef: Ref<HTMLElement | null>;
|
|
2911
|
+
/**
|
|
2912
|
+
* 当前输入模式
|
|
2913
|
+
*/
|
|
2914
|
+
mode: Ref<InputMode>;
|
|
2915
|
+
/**
|
|
2916
|
+
* 是否正在自动切换模式
|
|
2917
|
+
* 用于控制切换时的过渡动画
|
|
2918
|
+
*/
|
|
2919
|
+
isAutoSwitching: Ref<boolean>;
|
|
2920
|
+
/**
|
|
2921
|
+
* 是否加载中
|
|
2922
|
+
*/
|
|
2923
|
+
loading: Ref<boolean>;
|
|
2924
|
+
/**
|
|
2925
|
+
* 是否禁用
|
|
2926
|
+
*/
|
|
2927
|
+
disabled: Ref<boolean>;
|
|
2928
|
+
/**
|
|
2929
|
+
* 是否有内容
|
|
2930
|
+
*/
|
|
2931
|
+
hasContent: Ref<boolean>;
|
|
2932
|
+
/**
|
|
2933
|
+
* 是否可以提交
|
|
2934
|
+
*
|
|
2935
|
+
* 综合判断:
|
|
2936
|
+
* - !disabled
|
|
2937
|
+
* - !loading
|
|
2938
|
+
* - hasContent
|
|
2939
|
+
* - !isOverLimit
|
|
2940
|
+
* - !defaultActions.submit?.disabled
|
|
2941
|
+
*/
|
|
2942
|
+
canSubmit: Ref<boolean>;
|
|
2943
|
+
/**
|
|
2944
|
+
* 是否超出字数限制
|
|
2945
|
+
*/
|
|
2946
|
+
isOverLimit: Ref<boolean>;
|
|
2947
|
+
/**
|
|
2948
|
+
* 当前字符数
|
|
2949
|
+
*/
|
|
2950
|
+
characterCount: Ref<number>;
|
|
2951
|
+
/**
|
|
2952
|
+
* 最大字符数限制
|
|
2953
|
+
*/
|
|
2954
|
+
maxLength: Ref<number | undefined>;
|
|
2955
|
+
/**
|
|
2956
|
+
* 组件的尺寸
|
|
2957
|
+
*/
|
|
2958
|
+
size: Ref<'small' | 'normal'>;
|
|
2959
|
+
/**
|
|
2960
|
+
* 是否显示字数限制
|
|
2961
|
+
*/
|
|
2962
|
+
showWordLimit: Ref<boolean>;
|
|
2963
|
+
/**
|
|
2964
|
+
* 是否显示清空按钮
|
|
2965
|
+
*/
|
|
2966
|
+
clearable: Ref<boolean>;
|
|
2967
|
+
/**
|
|
2968
|
+
* 默认操作按钮配置
|
|
2969
|
+
*/
|
|
2970
|
+
defaultActions: Ref<DefaultActions | undefined>;
|
|
2971
|
+
/**
|
|
2972
|
+
* 提交触发方式
|
|
2973
|
+
*/
|
|
2974
|
+
submitType: Ref<SubmitTrigger>;
|
|
2975
|
+
/**
|
|
2976
|
+
* 停止按钮文字
|
|
2977
|
+
*/
|
|
2978
|
+
stopText: Ref<string | undefined>;
|
|
2979
|
+
/**
|
|
2980
|
+
* 提交内容
|
|
2981
|
+
*/
|
|
2982
|
+
submit: () => void;
|
|
2983
|
+
/**
|
|
2984
|
+
* 清空内容
|
|
2985
|
+
*/
|
|
2986
|
+
clear: () => void;
|
|
2987
|
+
/**
|
|
2988
|
+
* 取消操作
|
|
2989
|
+
*
|
|
2990
|
+
* 在 loading 状态下触发,用于取消正在进行的操作
|
|
2991
|
+
*/
|
|
2992
|
+
cancel: () => void;
|
|
2993
|
+
/**
|
|
2994
|
+
* 聚焦编辑器
|
|
2995
|
+
*/
|
|
2996
|
+
focus: () => void;
|
|
2997
|
+
/**
|
|
2998
|
+
* 失焦编辑器
|
|
2999
|
+
*/
|
|
3000
|
+
blur: () => void;
|
|
3001
|
+
/**
|
|
3002
|
+
* 设置编辑器内容
|
|
3003
|
+
*
|
|
3004
|
+
* @param content - 内容(HTML 或 JSON)
|
|
3005
|
+
*/
|
|
3006
|
+
setContent: (content: string) => void;
|
|
3007
|
+
/**
|
|
3008
|
+
* 获取编辑器内容
|
|
3009
|
+
*
|
|
3010
|
+
* @returns 内容(HTML)
|
|
3011
|
+
*/
|
|
3012
|
+
getContent: () => string;
|
|
3013
|
+
}
|
|
3014
|
+
|
|
3015
|
+
/**
|
|
3016
|
+
* Chat-Input 组件 Emits
|
|
3017
|
+
*/
|
|
3018
|
+
export declare interface SenderEmits {
|
|
3019
|
+
/**
|
|
3020
|
+
* 更新输入内容
|
|
3021
|
+
*
|
|
3022
|
+
* @param e - 事件名
|
|
3023
|
+
* @param value - 新内容
|
|
3024
|
+
*/
|
|
2924
3025
|
(e: 'update:modelValue', value: string): void;
|
|
2925
|
-
|
|
2926
|
-
|
|
2927
|
-
|
|
2928
|
-
|
|
2929
|
-
|
|
2930
|
-
|
|
2931
|
-
|
|
2932
|
-
|
|
3026
|
+
/**
|
|
3027
|
+
* 提交内容(增强版)
|
|
3028
|
+
*
|
|
3029
|
+
* @param e - 事件名
|
|
3030
|
+
* @param textContent - 提交的内容(纯文本,如 "帮我分析 @张三 的周报")
|
|
3031
|
+
* @param structuredData - 结构化数据(可选)
|
|
3032
|
+
*
|
|
3033
|
+
* @example
|
|
3034
|
+
* ```typescript
|
|
3035
|
+
* function handleSubmit(text: string, data?: StructuredData) {
|
|
3036
|
+
* console.log('纯文本:', text)
|
|
3037
|
+
*
|
|
3038
|
+
* if (data?.template) {
|
|
3039
|
+
* // Template 场景
|
|
3040
|
+
* console.log('模板数据:', data.template)
|
|
3041
|
+
* }
|
|
3042
|
+
*
|
|
3043
|
+
* if (data?.mentions) {
|
|
3044
|
+
* // Mention 场景
|
|
3045
|
+
* console.log('提及的人:', data.mentions)
|
|
3046
|
+
* }
|
|
3047
|
+
* }
|
|
3048
|
+
* ```
|
|
3049
|
+
*/
|
|
3050
|
+
(e: 'submit', textContent: string, structuredData?: StructuredData): void;
|
|
3051
|
+
/**
|
|
3052
|
+
* 聚焦事件
|
|
3053
|
+
*
|
|
3054
|
+
* @param e - 事件名
|
|
3055
|
+
* @param event - 原生事件
|
|
3056
|
+
*/
|
|
2933
3057
|
(e: 'focus', event: FocusEvent): void;
|
|
3058
|
+
/**
|
|
3059
|
+
* 失焦事件
|
|
3060
|
+
*
|
|
3061
|
+
* @param e - 事件名
|
|
3062
|
+
* @param event - 原生事件
|
|
3063
|
+
*/
|
|
2934
3064
|
(e: 'blur', event: FocusEvent): void;
|
|
2935
|
-
|
|
3065
|
+
/**
|
|
3066
|
+
* 清空事件
|
|
3067
|
+
*
|
|
3068
|
+
* @param e - 事件名
|
|
3069
|
+
*/
|
|
3070
|
+
(e: 'clear'): void;
|
|
3071
|
+
/**
|
|
3072
|
+
* 取消事件
|
|
3073
|
+
*
|
|
3074
|
+
* 在 loading 状态下点击停止按钮时触发
|
|
3075
|
+
* 用于取消正在进行的操作(如 AI 响应)
|
|
3076
|
+
*
|
|
3077
|
+
* @param e - 事件名
|
|
3078
|
+
*/
|
|
2936
3079
|
(e: 'cancel'): void;
|
|
2937
|
-
|
|
2938
|
-
|
|
2939
|
-
|
|
3080
|
+
/**
|
|
3081
|
+
* 输入事件
|
|
3082
|
+
*
|
|
3083
|
+
* @param e - 事件名
|
|
3084
|
+
* @param value - 当前内容
|
|
3085
|
+
*/
|
|
3086
|
+
(e: 'input', value: string): void;
|
|
3087
|
+
}
|
|
2940
3088
|
|
|
3089
|
+
/**
|
|
3090
|
+
* Chat-Input 组件 Props
|
|
3091
|
+
*/
|
|
2941
3092
|
export declare interface SenderProps {
|
|
3093
|
+
/**
|
|
3094
|
+
* 输入内容(双向绑定)
|
|
3095
|
+
*
|
|
3096
|
+
* 支持 v-model
|
|
3097
|
+
*/
|
|
3098
|
+
modelValue?: string;
|
|
3099
|
+
/**
|
|
3100
|
+
* 默认值
|
|
3101
|
+
*
|
|
3102
|
+
* 仅在初始化时使用
|
|
3103
|
+
*/
|
|
3104
|
+
defaultValue?: string;
|
|
3105
|
+
/**
|
|
3106
|
+
* 占位符文本
|
|
3107
|
+
*
|
|
3108
|
+
* @default '请输入内容...'
|
|
3109
|
+
*/
|
|
3110
|
+
placeholder?: string;
|
|
3111
|
+
/**
|
|
3112
|
+
* 是否禁用
|
|
3113
|
+
*
|
|
3114
|
+
* @default false
|
|
3115
|
+
*/
|
|
3116
|
+
disabled?: boolean;
|
|
3117
|
+
/**
|
|
3118
|
+
* 是否加载中
|
|
3119
|
+
*
|
|
3120
|
+
* 加载状态下显示停止按钮
|
|
3121
|
+
*
|
|
3122
|
+
* @default false
|
|
3123
|
+
*/
|
|
3124
|
+
loading?: boolean;
|
|
3125
|
+
/**
|
|
3126
|
+
* 是否自动聚焦
|
|
3127
|
+
*
|
|
3128
|
+
* @default false
|
|
3129
|
+
*/
|
|
2942
3130
|
autofocus?: boolean;
|
|
3131
|
+
/**
|
|
3132
|
+
* 输入模式
|
|
3133
|
+
*
|
|
3134
|
+
* - single: 单行模式
|
|
3135
|
+
* - multiple: 多行模式
|
|
3136
|
+
*
|
|
3137
|
+
* @default 'single'
|
|
3138
|
+
*/
|
|
3139
|
+
mode?: InputMode;
|
|
3140
|
+
/**
|
|
3141
|
+
* 自动调整高度
|
|
3142
|
+
*
|
|
3143
|
+
* - false: 不自动调整
|
|
3144
|
+
* - true: 自动调整(默认 1-3 行)
|
|
3145
|
+
* - { minRows, maxRows }: 自定义行数范围
|
|
3146
|
+
*
|
|
3147
|
+
* 仅在 mode === 'multiple' 时有效
|
|
3148
|
+
*
|
|
3149
|
+
* @default { minRows: 1, maxRows: 3 }
|
|
3150
|
+
*/
|
|
2943
3151
|
autoSize?: AutoSize;
|
|
3152
|
+
/**
|
|
3153
|
+
* 最大字符数
|
|
3154
|
+
*
|
|
3155
|
+
* @default Infinity
|
|
3156
|
+
*/
|
|
3157
|
+
maxLength?: number;
|
|
3158
|
+
/**
|
|
3159
|
+
* 是否显示字数限制
|
|
3160
|
+
*
|
|
3161
|
+
* 仅在 maxLength 有值时有效
|
|
3162
|
+
*
|
|
3163
|
+
* @default false
|
|
3164
|
+
*/
|
|
3165
|
+
showWordLimit?: boolean;
|
|
3166
|
+
/**
|
|
3167
|
+
* 是否显示清空按钮
|
|
3168
|
+
*
|
|
3169
|
+
* @default false
|
|
3170
|
+
*/
|
|
3171
|
+
clearable?: boolean;
|
|
3172
|
+
/**
|
|
3173
|
+
* Tiptap 扩展配置
|
|
3174
|
+
*
|
|
3175
|
+
* 用于添加增强输入能力,如 Template、Mention、Suggestion 等
|
|
3176
|
+
*
|
|
3177
|
+
* @example 基础使用
|
|
3178
|
+
* ```typescript
|
|
3179
|
+
* import { Template } from '@tiny-robot/components/chat-input/extensions'
|
|
3180
|
+
*
|
|
3181
|
+
* <ChatInput :extensions="[Template]" />
|
|
3182
|
+
* ```
|
|
3183
|
+
*
|
|
3184
|
+
* @example 带配置的扩展(响应式推荐)
|
|
3185
|
+
* ```typescript
|
|
3186
|
+
* import { Mention, Suggestion } from '@tiny-robot/components/chat-input/extensions'
|
|
3187
|
+
*
|
|
3188
|
+
* const mentions = ref([...])
|
|
3189
|
+
* const suggestions = ref([...])
|
|
3190
|
+
*
|
|
3191
|
+
* const extensions = [
|
|
3192
|
+
* Mention.configure({ items: mentions }),
|
|
3193
|
+
* Suggestion.configure({ items: suggestions })
|
|
3194
|
+
* ]
|
|
3195
|
+
*
|
|
3196
|
+
* <ChatInput :extensions="extensions" />
|
|
3197
|
+
* ```
|
|
3198
|
+
*/
|
|
3199
|
+
extensions?: Extension[] | any[];
|
|
3200
|
+
/**
|
|
3201
|
+
* 组件尺寸
|
|
3202
|
+
*
|
|
3203
|
+
* - normal: 正常尺寸(默认)
|
|
3204
|
+
* - small: 紧凑模式,更小的字体、间距和图标
|
|
3205
|
+
*
|
|
3206
|
+
* @default 'normal'
|
|
3207
|
+
*/
|
|
3208
|
+
size?: 'normal' | 'small';
|
|
3209
|
+
/**
|
|
3210
|
+
* 停止按钮文字
|
|
3211
|
+
*
|
|
3212
|
+
* @default '停止响应'
|
|
3213
|
+
*/
|
|
3214
|
+
stopText?: string;
|
|
3215
|
+
/**
|
|
3216
|
+
* 默认操作按钮配置
|
|
3217
|
+
*
|
|
3218
|
+
* 用于统一配置默认按钮(Clear、Submit)的状态和提示
|
|
3219
|
+
*
|
|
3220
|
+
* @example 基础使用
|
|
3221
|
+
* ```vue
|
|
3222
|
+
* <ChatInput
|
|
3223
|
+
* :actions-config="{
|
|
3224
|
+
* submit: { disabled: !isValid, tooltip: '请完善表单' }
|
|
3225
|
+
* }"
|
|
3226
|
+
* />
|
|
3227
|
+
* ```
|
|
3228
|
+
*
|
|
3229
|
+
* @example 动态配置
|
|
3230
|
+
* ```vue
|
|
3231
|
+
* <script setup>
|
|
3232
|
+
* const defaultActions = computed(() => ({
|
|
3233
|
+
* submit: {
|
|
3234
|
+
* disabled: !canSubmit.value,
|
|
3235
|
+
* tooltip: canSubmit.value ? '发送' : '请输入内容'
|
|
3236
|
+
* },
|
|
3237
|
+
* clear: { tooltip: '清空输入' }
|
|
3238
|
+
* }))
|
|
3239
|
+
* </script>
|
|
3240
|
+
*
|
|
3241
|
+
* <template>
|
|
3242
|
+
* <ChatInput :actions-config="defaultActions" />
|
|
3243
|
+
* </template>
|
|
3244
|
+
* ```
|
|
3245
|
+
*
|
|
3246
|
+
* @default undefined
|
|
3247
|
+
*/
|
|
3248
|
+
defaultActions?: DefaultActions;
|
|
3249
|
+
/**
|
|
3250
|
+
* 提交触发方式
|
|
3251
|
+
*
|
|
3252
|
+
* @default 'enter'
|
|
3253
|
+
*/
|
|
3254
|
+
submitType?: SubmitTrigger;
|
|
3255
|
+
}
|
|
3256
|
+
|
|
3257
|
+
declare interface SenderProps_2 {
|
|
3258
|
+
autofocus?: boolean;
|
|
3259
|
+
autoSize?: AutoSize_2;
|
|
2944
3260
|
allowSpeech?: boolean;
|
|
2945
3261
|
allowFiles?: boolean;
|
|
2946
3262
|
clearable?: boolean;
|
|
@@ -2948,11 +3264,11 @@ export declare interface SenderProps {
|
|
|
2948
3264
|
defaultValue?: string | null;
|
|
2949
3265
|
loading?: boolean;
|
|
2950
3266
|
modelValue?: string;
|
|
2951
|
-
mode?:
|
|
3267
|
+
mode?: InputMode_2;
|
|
2952
3268
|
maxLength?: number;
|
|
2953
3269
|
buttonGroup?: ButtonGroupConfig;
|
|
2954
|
-
submitType?:
|
|
2955
|
-
speech?: boolean |
|
|
3270
|
+
submitType?: SubmitTrigger_2;
|
|
3271
|
+
speech?: boolean | SpeechConfig_2;
|
|
2956
3272
|
placeholder?: string;
|
|
2957
3273
|
showWordLimit?: boolean;
|
|
2958
3274
|
suggestions?: ISuggestionItem[];
|
|
@@ -2963,6 +3279,105 @@ export declare interface SenderProps {
|
|
|
2963
3279
|
stopText?: string;
|
|
2964
3280
|
}
|
|
2965
3281
|
|
|
3282
|
+
/**
|
|
3283
|
+
* Chat-Input 组件 Slots
|
|
3284
|
+
*/
|
|
3285
|
+
export declare interface SenderSlots {
|
|
3286
|
+
/**
|
|
3287
|
+
* 头部插槽
|
|
3288
|
+
*/
|
|
3289
|
+
header?: () => unknown;
|
|
3290
|
+
/**
|
|
3291
|
+
* 前缀插槽
|
|
3292
|
+
*/
|
|
3293
|
+
prefix?: () => unknown;
|
|
3294
|
+
/**
|
|
3295
|
+
* 内容插槽
|
|
3296
|
+
*
|
|
3297
|
+
* @param props - 插槽属性
|
|
3298
|
+
* @param props.editor - 编辑器实例
|
|
3299
|
+
*/
|
|
3300
|
+
content?: (props: {
|
|
3301
|
+
editor: unknown;
|
|
3302
|
+
}) => unknown;
|
|
3303
|
+
/**
|
|
3304
|
+
* 单行模式内联操作按钮插槽
|
|
3305
|
+
*
|
|
3306
|
+
* @example
|
|
3307
|
+
* ```vue
|
|
3308
|
+
* <chat-input>
|
|
3309
|
+
* <template #actions-inline="{ insert, focus, disabled }">
|
|
3310
|
+
* <voice-input @result="insert" :disabled="disabled" />
|
|
3311
|
+
* <file-upload @select="handleFiles" />
|
|
3312
|
+
* </template>
|
|
3313
|
+
* </chat-input>
|
|
3314
|
+
* ```
|
|
3315
|
+
*/
|
|
3316
|
+
'actions-inline'?: (scope: ChatInputSlotScope) => unknown;
|
|
3317
|
+
/**
|
|
3318
|
+
* 底部插槽(多行模式)
|
|
3319
|
+
*/
|
|
3320
|
+
footer?: (scope: ChatInputSlotScope) => unknown;
|
|
3321
|
+
/**
|
|
3322
|
+
* 底部右侧插槽(多行模式)
|
|
3323
|
+
*/
|
|
3324
|
+
'footer-right'?: (scope: ChatInputSlotScope) => unknown;
|
|
3325
|
+
}
|
|
3326
|
+
|
|
3327
|
+
/**
|
|
3328
|
+
* 建议项类型
|
|
3329
|
+
*
|
|
3330
|
+
* @example
|
|
3331
|
+
* ```typescript
|
|
3332
|
+
* // 自动匹配
|
|
3333
|
+
* { content: 'ECS-云服务器' }
|
|
3334
|
+
*
|
|
3335
|
+
* // 精确指定高亮
|
|
3336
|
+
* {
|
|
3337
|
+
* content: 'ECS-云服务器',
|
|
3338
|
+
* highlights: ['ECS', '云服务器']
|
|
3339
|
+
* }
|
|
3340
|
+
*
|
|
3341
|
+
* // 自定义高亮函数
|
|
3342
|
+
* {
|
|
3343
|
+
* content: 'ECS-云服务器',
|
|
3344
|
+
* highlights: (text, query) => [
|
|
3345
|
+
* { text: 'ECS', isMatch: true },
|
|
3346
|
+
* { text: '-云服务器', isMatch: false }
|
|
3347
|
+
* ]
|
|
3348
|
+
* }
|
|
3349
|
+
* ```
|
|
3350
|
+
*/
|
|
3351
|
+
export declare interface SenderSuggestionItem {
|
|
3352
|
+
/**
|
|
3353
|
+
* 建议项内容(必填)
|
|
3354
|
+
*/
|
|
3355
|
+
content: string;
|
|
3356
|
+
/**
|
|
3357
|
+
* 显示标签(可选)
|
|
3358
|
+
*
|
|
3359
|
+
* 默认使用 content
|
|
3360
|
+
*/
|
|
3361
|
+
label?: string;
|
|
3362
|
+
/**
|
|
3363
|
+
* 高亮方式(可选)
|
|
3364
|
+
*
|
|
3365
|
+
* - undefined: 自动匹配(默认)
|
|
3366
|
+
* - string[]: 精确指定高亮片段
|
|
3367
|
+
* - function: 自定义高亮逻辑
|
|
3368
|
+
*/
|
|
3369
|
+
highlights?: string[] | HighlightFunction;
|
|
3370
|
+
/**
|
|
3371
|
+
* 自定义数据(可选)
|
|
3372
|
+
*
|
|
3373
|
+
* 用于扩展功能
|
|
3374
|
+
*/
|
|
3375
|
+
data?: Record<string, unknown>;
|
|
3376
|
+
}
|
|
3377
|
+
|
|
3378
|
+
/**
|
|
3379
|
+
* 语音识别相关类型定义
|
|
3380
|
+
*/
|
|
2966
3381
|
export declare interface SpeechCallbacks {
|
|
2967
3382
|
onStart: () => void;
|
|
2968
3383
|
onInterim: (transcript: string) => void;
|
|
@@ -2971,6 +3386,14 @@ export declare interface SpeechCallbacks {
|
|
|
2971
3386
|
onError: (error: Error) => void;
|
|
2972
3387
|
}
|
|
2973
3388
|
|
|
3389
|
+
declare interface SpeechCallbacks_2 {
|
|
3390
|
+
onStart: () => void;
|
|
3391
|
+
onInterim: (transcript: string) => void;
|
|
3392
|
+
onFinal: (transcript: string) => void;
|
|
3393
|
+
onEnd: (transcript?: string) => void;
|
|
3394
|
+
onError: (error: Error) => void;
|
|
3395
|
+
}
|
|
3396
|
+
|
|
2974
3397
|
export declare interface SpeechConfig {
|
|
2975
3398
|
customHandler?: SpeechHandler;
|
|
2976
3399
|
lang?: string;
|
|
@@ -2980,12 +3403,27 @@ export declare interface SpeechConfig {
|
|
|
2980
3403
|
onVoiceButtonClick?: (isRecording: boolean, preventDefault: () => void) => void | Promise<void>;
|
|
2981
3404
|
}
|
|
2982
3405
|
|
|
3406
|
+
declare interface SpeechConfig_2 {
|
|
3407
|
+
customHandler?: SpeechHandler_2;
|
|
3408
|
+
lang?: string;
|
|
3409
|
+
continuous?: boolean;
|
|
3410
|
+
interimResults?: boolean;
|
|
3411
|
+
autoReplace?: boolean;
|
|
3412
|
+
onVoiceButtonClick?: (isRecording: boolean, preventDefault: () => void) => void | Promise<void>;
|
|
3413
|
+
}
|
|
3414
|
+
|
|
2983
3415
|
export declare interface SpeechHandler {
|
|
2984
3416
|
start: (callbacks: SpeechCallbacks) => Promise<void> | void;
|
|
2985
3417
|
stop: () => Promise<void> | void;
|
|
2986
3418
|
isSupported: () => boolean;
|
|
2987
3419
|
}
|
|
2988
3420
|
|
|
3421
|
+
declare interface SpeechHandler_2 {
|
|
3422
|
+
start: (callbacks: SpeechCallbacks_2) => Promise<void> | void;
|
|
3423
|
+
stop: () => Promise<void> | void;
|
|
3424
|
+
isSupported: () => boolean;
|
|
3425
|
+
}
|
|
3426
|
+
|
|
2989
3427
|
export declare interface SpeechHandlerResult {
|
|
2990
3428
|
speechState: SpeechState;
|
|
2991
3429
|
start: () => void;
|
|
@@ -3006,8 +3444,85 @@ export declare interface SpeechState {
|
|
|
3006
3444
|
error?: Error;
|
|
3007
3445
|
}
|
|
3008
3446
|
|
|
3447
|
+
/**
|
|
3448
|
+
* 结构化数据(联合类型)
|
|
3449
|
+
*
|
|
3450
|
+
* Submit 事件的第二个参数,根据使用的扩展直接返回对应的数据数组
|
|
3451
|
+
*
|
|
3452
|
+
* **设计理念**:
|
|
3453
|
+
* - 第一个参数 `text`:纯文本内容,适用于简单场景
|
|
3454
|
+
* - 第二个参数 `data`:结构化数据数组,直接使用无需解包
|
|
3455
|
+
*
|
|
3456
|
+
* **类型说明**:
|
|
3457
|
+
* - `TemplateItem[]`: 使用 Template 扩展时返回(混合结构)
|
|
3458
|
+
* - `MentionStructuredItem[]`: 使用 Mention 扩展时返回(混合结构)
|
|
3459
|
+
*
|
|
3460
|
+
* @example Template 场景
|
|
3461
|
+
* ```typescript
|
|
3462
|
+
* function handleSubmit(text: string, data?: StructuredData) {
|
|
3463
|
+
* // text: "帮我分析 的周报"
|
|
3464
|
+
* // data: [
|
|
3465
|
+
* // { type: 'text', content: '帮我分析 ' },
|
|
3466
|
+
* // { type: 'template', content: '张三' },
|
|
3467
|
+
* // { type: 'text', content: ' 的周报' }
|
|
3468
|
+
* // ]
|
|
3469
|
+
*
|
|
3470
|
+
* if (data && data[0]?.type === 'template') {
|
|
3471
|
+
* const templates = data.filter(item => item.type === 'template')
|
|
3472
|
+
* console.log('模板变量:', templates)
|
|
3473
|
+
* }
|
|
3474
|
+
* }
|
|
3475
|
+
* ```
|
|
3476
|
+
*
|
|
3477
|
+
* @example Mention 场景
|
|
3478
|
+
* ```typescript
|
|
3479
|
+
* function handleSubmit(text: string, data?: StructuredData) {
|
|
3480
|
+
* // text: "帮我分析 @张三 的周报"
|
|
3481
|
+
* // data: [
|
|
3482
|
+
* // { type: 'text', content: '帮我分析 ' },
|
|
3483
|
+
* // { type: 'mention', content: '张三', preset: '...' },
|
|
3484
|
+
* // { type: 'text', content: ' 的周报' }
|
|
3485
|
+
* // ]
|
|
3486
|
+
*
|
|
3487
|
+
* // 统一使用 content 属性
|
|
3488
|
+
* const allContent = data?.map(item => item.content).join('')
|
|
3489
|
+
* console.log('完整内容:', allContent)
|
|
3490
|
+
*
|
|
3491
|
+
* // 提取 mention
|
|
3492
|
+
* if (data && data[0]?.type === 'mention') {
|
|
3493
|
+
* const mentions = data.filter(item => item.type === 'mention')
|
|
3494
|
+
* console.log('提及的人:', mentions.map(m => m.content))
|
|
3495
|
+
* console.log('预设内容:', mentions.map(m => m.preset))
|
|
3496
|
+
* }
|
|
3497
|
+
* }
|
|
3498
|
+
* ```
|
|
3499
|
+
*/
|
|
3500
|
+
export declare type StructuredData = TemplateItem[] | MentionStructuredItem[];
|
|
3501
|
+
|
|
3502
|
+
/**
|
|
3503
|
+
* 提交触发方式
|
|
3504
|
+
* - enter: Enter 键提交
|
|
3505
|
+
* - ctrlEnter: Ctrl+Enter 提交
|
|
3506
|
+
* - shiftEnter: Shift+Enter 提交
|
|
3507
|
+
*/
|
|
3009
3508
|
export declare type SubmitTrigger = 'enter' | 'ctrlEnter' | 'shiftEnter';
|
|
3010
3509
|
|
|
3510
|
+
declare type SubmitTrigger_2 = 'enter' | 'ctrlEnter' | 'shiftEnter';
|
|
3511
|
+
|
|
3512
|
+
/**
|
|
3513
|
+
* 创建 Suggestion 扩展的便捷函数
|
|
3514
|
+
*
|
|
3515
|
+
* @param items - 建议项列表
|
|
3516
|
+
* @param options - 其他配置项
|
|
3517
|
+
*
|
|
3518
|
+
* @example
|
|
3519
|
+
* ```typescript
|
|
3520
|
+
* const extensions = [suggestion(suggestions)]
|
|
3521
|
+
* const extensions = [suggestion(suggestions, { popupWidth: 500 })]
|
|
3522
|
+
* ```
|
|
3523
|
+
*/
|
|
3524
|
+
declare function suggestion(items: SenderSuggestionItem[] | Ref<SenderSuggestionItem[]>, options?: Partial<Omit<SuggestionOptions, 'items'>>): Extension<SuggestionOptions, any>;
|
|
3525
|
+
|
|
3011
3526
|
export declare interface SuggestionBaseItem {
|
|
3012
3527
|
id: string;
|
|
3013
3528
|
text: string;
|
|
@@ -3024,7 +3539,121 @@ export declare interface SuggestionGroup<T = Record<string, unknown>> {
|
|
|
3024
3539
|
|
|
3025
3540
|
export declare type SuggestionItem<T = Record<string, unknown>> = SuggestionBaseItem & T;
|
|
3026
3541
|
|
|
3027
|
-
|
|
3542
|
+
/**
|
|
3543
|
+
* 插件配置选项
|
|
3544
|
+
*/
|
|
3545
|
+
export declare interface SuggestionOptions {
|
|
3546
|
+
/**
|
|
3547
|
+
* 建议项列表(必填)
|
|
3548
|
+
*
|
|
3549
|
+
* @example
|
|
3550
|
+
* ```typescript
|
|
3551
|
+
* const items = ref([
|
|
3552
|
+
* { content: 'ECS-云服务器' },
|
|
3553
|
+
* { content: 'RDS-数据库' }
|
|
3554
|
+
* ])
|
|
3555
|
+
* ```
|
|
3556
|
+
*/
|
|
3557
|
+
items?: SenderSuggestionItem[] | Ref<SenderSuggestionItem[]>;
|
|
3558
|
+
/**
|
|
3559
|
+
* 自定义过滤函数(可选)
|
|
3560
|
+
*
|
|
3561
|
+
* - 不传:不过滤,直接显示所有项
|
|
3562
|
+
* - 传入:使用自定义过滤逻辑
|
|
3563
|
+
*
|
|
3564
|
+
* @default undefined(不过滤)
|
|
3565
|
+
*
|
|
3566
|
+
* @example 模糊匹配过滤
|
|
3567
|
+
* ```typescript
|
|
3568
|
+
* filterFn: (items, query) => {
|
|
3569
|
+
* return items.filter(item =>
|
|
3570
|
+
* item.content.toLowerCase().includes(query.toLowerCase())
|
|
3571
|
+
* )
|
|
3572
|
+
* }
|
|
3573
|
+
* ```
|
|
3574
|
+
*
|
|
3575
|
+
* @example 前缀匹配过滤
|
|
3576
|
+
* ```typescript
|
|
3577
|
+
* filterFn: (items, query) => {
|
|
3578
|
+
* return items.filter(item =>
|
|
3579
|
+
* item.content.toLowerCase().startsWith(query.toLowerCase())
|
|
3580
|
+
* )
|
|
3581
|
+
* }
|
|
3582
|
+
* ```
|
|
3583
|
+
*/
|
|
3584
|
+
filterFn?: (suggestions: SenderSuggestionItem[], query: string) => SenderSuggestionItem[];
|
|
3585
|
+
/**
|
|
3586
|
+
* 选中建议项的按键
|
|
3587
|
+
*
|
|
3588
|
+
* 注意:Tab 键用于自动补全,不受此配置控制
|
|
3589
|
+
*
|
|
3590
|
+
* @default ['Enter']
|
|
3591
|
+
*
|
|
3592
|
+
* @example 只允许 Enter 选中
|
|
3593
|
+
* ```typescript
|
|
3594
|
+
* activeSuggestionKeys: ['Enter']
|
|
3595
|
+
* ```
|
|
3596
|
+
*
|
|
3597
|
+
* @example 允许 Enter 和 Space 选中
|
|
3598
|
+
* ```typescript
|
|
3599
|
+
* activeSuggestionKeys: ['Enter', ' '] // 注意:空格键是 ' '
|
|
3600
|
+
* ```
|
|
3601
|
+
*
|
|
3602
|
+
* @example 禁用所有选中按键(只能点击)
|
|
3603
|
+
* ```typescript
|
|
3604
|
+
* activeSuggestionKeys: []
|
|
3605
|
+
* ```
|
|
3606
|
+
*/
|
|
3607
|
+
activeSuggestionKeys?: string[];
|
|
3608
|
+
/**
|
|
3609
|
+
* 弹窗宽度
|
|
3610
|
+
*
|
|
3611
|
+
* @default 400
|
|
3612
|
+
*/
|
|
3613
|
+
popupWidth?: number | string;
|
|
3614
|
+
/**
|
|
3615
|
+
* 是否显示自动补全提示
|
|
3616
|
+
*
|
|
3617
|
+
* @default true
|
|
3618
|
+
*/
|
|
3619
|
+
showAutoComplete?: boolean;
|
|
3620
|
+
/**
|
|
3621
|
+
* 选中建议项的回调
|
|
3622
|
+
*
|
|
3623
|
+
* @param item - 选中的建议项(包含完整的 SuggestionItem 信息)
|
|
3624
|
+
* @returns 返回 false 可阻止默认回填行为
|
|
3625
|
+
*
|
|
3626
|
+
* @example 默认行为(自动回填)
|
|
3627
|
+
* ```typescript
|
|
3628
|
+
* onSelect: (item) => {
|
|
3629
|
+
* console.log('Selected:', item)
|
|
3630
|
+
* // 不返回 false,内容会自动回填
|
|
3631
|
+
* }
|
|
3632
|
+
* ```
|
|
3633
|
+
*
|
|
3634
|
+
* @example 阻止默认行为并自定义回填
|
|
3635
|
+
* ```typescript
|
|
3636
|
+
* onSelect: (item) => {
|
|
3637
|
+
* editor.commands.setContent(`前缀-${item.content}-后缀`)
|
|
3638
|
+
* return false // 阻止默认回填
|
|
3639
|
+
* }
|
|
3640
|
+
* ```
|
|
3641
|
+
*
|
|
3642
|
+
* @example 条件性阻止
|
|
3643
|
+
* ```typescript
|
|
3644
|
+
* onSelect: (item) => {
|
|
3645
|
+
* if (item.data?.needsValidation) {
|
|
3646
|
+
* validateAndFill(item)
|
|
3647
|
+
* return false
|
|
3648
|
+
* }
|
|
3649
|
+
* // 否则使用默认回填
|
|
3650
|
+
* }
|
|
3651
|
+
* ```
|
|
3652
|
+
*/
|
|
3653
|
+
onSelect?: (item: SenderSuggestionItem) => void | false;
|
|
3654
|
+
}
|
|
3655
|
+
|
|
3656
|
+
declare const SuggestionPillButton: typeof _default_38 & {
|
|
3028
3657
|
install: typeof installPillButton;
|
|
3029
3658
|
};
|
|
3030
3659
|
export { SuggestionPillButton }
|
|
@@ -3152,19 +3781,232 @@ export declare interface SuggestionPopoverSlots {
|
|
|
3152
3781
|
body?: () => VNode | VNode[];
|
|
3153
3782
|
}
|
|
3154
3783
|
|
|
3784
|
+
/**
|
|
3785
|
+
* 插件状态
|
|
3786
|
+
*
|
|
3787
|
+
* 管理建议列表的显示、过滤、选中等状态
|
|
3788
|
+
*/
|
|
3789
|
+
export declare interface SuggestionState {
|
|
3790
|
+
/**
|
|
3791
|
+
* 是否激活(有匹配的建议项)
|
|
3792
|
+
*/
|
|
3793
|
+
active: boolean;
|
|
3794
|
+
/**
|
|
3795
|
+
* 匹配范围
|
|
3796
|
+
*
|
|
3797
|
+
* 全局模式:整个文档范围
|
|
3798
|
+
* 字符模式:触发字符到光标的范围
|
|
3799
|
+
*/
|
|
3800
|
+
range: {
|
|
3801
|
+
from: number;
|
|
3802
|
+
to: number;
|
|
3803
|
+
} | null;
|
|
3804
|
+
/**
|
|
3805
|
+
* 查询文本
|
|
3806
|
+
*
|
|
3807
|
+
* 全局模式:整个输入内容
|
|
3808
|
+
* 字符模式:触发字符后的文本
|
|
3809
|
+
*/
|
|
3810
|
+
query: string;
|
|
3811
|
+
/**
|
|
3812
|
+
* 过滤后的建议项
|
|
3813
|
+
*/
|
|
3814
|
+
filteredSuggestions: SenderSuggestionItem[];
|
|
3815
|
+
/**
|
|
3816
|
+
* 当前选中的建议项索引
|
|
3817
|
+
*
|
|
3818
|
+
* -1 表示未选中
|
|
3819
|
+
*/
|
|
3820
|
+
selectedIndex: number;
|
|
3821
|
+
/**
|
|
3822
|
+
* 自动补全文本
|
|
3823
|
+
*
|
|
3824
|
+
* 选中项的剩余部分
|
|
3825
|
+
*/
|
|
3826
|
+
autoCompleteText: string;
|
|
3827
|
+
/**
|
|
3828
|
+
* 是否显示 Tab 提示
|
|
3829
|
+
*/
|
|
3830
|
+
showTabIndicator: boolean;
|
|
3831
|
+
}
|
|
3832
|
+
|
|
3833
|
+
/**
|
|
3834
|
+
* Suggestion 插件类型定义
|
|
3835
|
+
*
|
|
3836
|
+
* 包含建议项、高亮、插件配置和状态等类型定义
|
|
3837
|
+
*/
|
|
3838
|
+
/**
|
|
3839
|
+
* 高亮文本片段
|
|
3840
|
+
*/
|
|
3155
3841
|
export declare interface SuggestionTextPart {
|
|
3156
3842
|
text: string;
|
|
3157
3843
|
isMatch: boolean;
|
|
3158
3844
|
}
|
|
3159
3845
|
|
|
3160
|
-
declare interface
|
|
3161
|
-
|
|
3162
|
-
|
|
3163
|
-
|
|
3846
|
+
declare interface SuggestionTextPart_2 {
|
|
3847
|
+
text: string;
|
|
3848
|
+
isMatch: boolean;
|
|
3849
|
+
}
|
|
3850
|
+
|
|
3851
|
+
/**
|
|
3852
|
+
* 创建 Template 扩展的便捷函数
|
|
3853
|
+
*
|
|
3854
|
+
* @param items - 模板项列表
|
|
3855
|
+
* @param options - 其他配置项
|
|
3856
|
+
*
|
|
3857
|
+
* @example
|
|
3858
|
+
* ```typescript
|
|
3859
|
+
* const extensions = [template(templates)]
|
|
3860
|
+
* const extensions = [template(templates, { HTMLAttributes: { class: 'custom' } })]
|
|
3861
|
+
* ```
|
|
3862
|
+
*/
|
|
3863
|
+
declare function template(items: TemplateItem[] | Ref<TemplateItem[]>, options?: Partial<Omit<TemplateOptions, 'items'>>): Extension<TemplateOptions, any>;
|
|
3864
|
+
|
|
3865
|
+
/**
|
|
3866
|
+
* Template 节点属性
|
|
3867
|
+
*/
|
|
3868
|
+
export declare interface TemplateAttrs {
|
|
3869
|
+
/**
|
|
3870
|
+
* 模板块 ID
|
|
3871
|
+
*/
|
|
3872
|
+
id: string;
|
|
3873
|
+
/**
|
|
3874
|
+
* 模板块内容
|
|
3875
|
+
*/
|
|
3876
|
+
content: string;
|
|
3877
|
+
}
|
|
3878
|
+
|
|
3879
|
+
/**
|
|
3880
|
+
* 模板项(用户侧)
|
|
3881
|
+
*
|
|
3882
|
+
* 用户传入的模板数据格式
|
|
3883
|
+
* 组件内部会转换为 Tiptap 节点格式
|
|
3884
|
+
*/
|
|
3885
|
+
export declare type TemplateItem = {
|
|
3886
|
+
/**
|
|
3887
|
+
* 模板 ID,可选
|
|
3888
|
+
* 如果不提供,组件会自动生成
|
|
3889
|
+
*/
|
|
3890
|
+
id?: string;
|
|
3891
|
+
/**
|
|
3892
|
+
* 类型:普通文本
|
|
3893
|
+
*/
|
|
3894
|
+
type: 'text';
|
|
3895
|
+
/**
|
|
3896
|
+
* 内容
|
|
3897
|
+
*/
|
|
3898
|
+
content: string;
|
|
3899
|
+
} | {
|
|
3900
|
+
/**
|
|
3901
|
+
* 模板 ID,可选
|
|
3902
|
+
* 如果不提供,组件会自动生成
|
|
3903
|
+
*/
|
|
3904
|
+
id?: string;
|
|
3905
|
+
/**
|
|
3906
|
+
* 类型:模板块(可编辑)
|
|
3907
|
+
*/
|
|
3908
|
+
type: 'block';
|
|
3909
|
+
/**
|
|
3910
|
+
* 内容
|
|
3911
|
+
*/
|
|
3912
|
+
content: string;
|
|
3913
|
+
} | {
|
|
3914
|
+
/**
|
|
3915
|
+
* 模板 ID,可选
|
|
3916
|
+
* 如果不提供,组件会自动生成
|
|
3917
|
+
*/
|
|
3918
|
+
id?: string;
|
|
3919
|
+
/**
|
|
3920
|
+
* 类型:选择器
|
|
3921
|
+
*/
|
|
3922
|
+
type: 'select';
|
|
3923
|
+
/**
|
|
3924
|
+
* 内容(选中的值)
|
|
3925
|
+
*/
|
|
3926
|
+
content: string;
|
|
3927
|
+
/**
|
|
3928
|
+
* 占位文字(未选择时显示)
|
|
3929
|
+
*/
|
|
3930
|
+
placeholder?: string;
|
|
3931
|
+
/**
|
|
3932
|
+
* 选项列表
|
|
3933
|
+
*/
|
|
3934
|
+
options?: SelectOption[];
|
|
3935
|
+
/**
|
|
3936
|
+
* 当前选中的值
|
|
3937
|
+
*/
|
|
3938
|
+
value?: string;
|
|
3939
|
+
};
|
|
3940
|
+
|
|
3941
|
+
declare interface TemplateItem_2 {
|
|
3942
|
+
id: string;
|
|
3943
|
+
type: 'template' | 'block';
|
|
3944
|
+
content: string;
|
|
3945
|
+
}
|
|
3946
|
+
|
|
3947
|
+
/**
|
|
3948
|
+
* Template 配置选项
|
|
3949
|
+
*/
|
|
3950
|
+
export declare interface TemplateOptions {
|
|
3951
|
+
/**
|
|
3952
|
+
* 模板数据列表(推荐使用 ref 实现响应式)
|
|
3953
|
+
*
|
|
3954
|
+
* 支持两种配置方式:
|
|
3955
|
+
* 1. 传入 ref(推荐):自动双向绑定,解决时序问题
|
|
3956
|
+
* 2. 传入数组:仅用于静态初始化
|
|
3957
|
+
*
|
|
3958
|
+
* @example 响应式配置(推荐)
|
|
3959
|
+
* ```typescript
|
|
3960
|
+
* const items = ref<TemplateItem[]>([
|
|
3961
|
+
* { type: 'text', content: '帮我分析' },
|
|
3962
|
+
* { type: 'template', content: '' }
|
|
3963
|
+
* ])
|
|
3964
|
+
* Template.configure({ items }) // 传入 ref,自动双向绑定
|
|
3965
|
+
* ```
|
|
3966
|
+
*
|
|
3967
|
+
* @example 静态配置
|
|
3968
|
+
* ```typescript
|
|
3969
|
+
* Template.configure({
|
|
3970
|
+
* items: [
|
|
3971
|
+
* { type: 'text', content: '帮我分析' },
|
|
3972
|
+
* { type: 'template', content: '' }
|
|
3973
|
+
* ]
|
|
3974
|
+
* })
|
|
3975
|
+
* ```
|
|
3976
|
+
*/
|
|
3977
|
+
items?: TemplateItem[] | Ref<TemplateItem[], TemplateItem[]>;
|
|
3978
|
+
/**
|
|
3979
|
+
* HTML 属性
|
|
3980
|
+
*/
|
|
3981
|
+
HTMLAttributes?: Record<string, unknown>;
|
|
3982
|
+
}
|
|
3983
|
+
|
|
3984
|
+
/**
|
|
3985
|
+
* TemplateSelect 节点属性
|
|
3986
|
+
*/
|
|
3987
|
+
export declare interface TemplateSelectAttrs {
|
|
3988
|
+
/**
|
|
3989
|
+
* 唯一标识
|
|
3990
|
+
*/
|
|
3991
|
+
id: string;
|
|
3992
|
+
/**
|
|
3993
|
+
* 占位文字(未选择时显示)
|
|
3994
|
+
*/
|
|
3995
|
+
placeholder: string;
|
|
3996
|
+
/**
|
|
3997
|
+
* 选项列表
|
|
3998
|
+
*/
|
|
3999
|
+
options: SelectOption_2[];
|
|
4000
|
+
/**
|
|
4001
|
+
* 当前选中的值(可选)
|
|
4002
|
+
*/
|
|
4003
|
+
value?: string;
|
|
3164
4004
|
}
|
|
3165
4005
|
|
|
3166
|
-
declare interface TextItem
|
|
4006
|
+
declare interface TextItem {
|
|
4007
|
+
id: string;
|
|
3167
4008
|
type: 'text';
|
|
4009
|
+
content: string;
|
|
3168
4010
|
}
|
|
3169
4011
|
|
|
3170
4012
|
export declare interface ThemeProviderProps {
|
|
@@ -3186,10 +4028,14 @@ export declare interface ThemeProviderProps {
|
|
|
3186
4028
|
|
|
3187
4029
|
export declare type ThemeStorage = Pick<Storage, 'getItem' | 'setItem'>;
|
|
3188
4030
|
|
|
4031
|
+
declare type ThemeType = 'light' | 'dark';
|
|
4032
|
+
|
|
3189
4033
|
/**
|
|
3190
|
-
*
|
|
4034
|
+
* Tooltip 内容类型
|
|
4035
|
+
* - string: 简单文本
|
|
4036
|
+
* - () => string | VNode: 渲染函数,支持复杂内容
|
|
3191
4037
|
*/
|
|
3192
|
-
export declare type
|
|
4038
|
+
export declare type TooltipContent = string | (() => string | VNode);
|
|
3193
4039
|
|
|
3194
4040
|
declare interface TooltipContentProps {
|
|
3195
4041
|
show?: boolean;
|
|
@@ -3201,7 +4047,71 @@ declare interface TooltipContentProps {
|
|
|
3201
4047
|
delayClose?: number;
|
|
3202
4048
|
}
|
|
3203
4049
|
|
|
3204
|
-
|
|
4050
|
+
/**
|
|
4051
|
+
* Tooltip 位置
|
|
4052
|
+
*
|
|
4053
|
+
* 支持 TinyTooltip 的所有位置选项
|
|
4054
|
+
*/
|
|
4055
|
+
export declare type TooltipPlacement = 'top' | 'top-start' | 'top-end' | 'bottom' | 'bottom-start' | 'bottom-end' | 'left' | 'left-start' | 'left-end' | 'right' | 'right-start' | 'right-end';
|
|
4056
|
+
|
|
4057
|
+
declare type TooltipRender = () => VNode | string;
|
|
4058
|
+
|
|
4059
|
+
export declare interface UploadButtonEmits {
|
|
4060
|
+
/**
|
|
4061
|
+
* 文件选择
|
|
4062
|
+
*/
|
|
4063
|
+
(e: 'select', files: File[]): void;
|
|
4064
|
+
/**
|
|
4065
|
+
* 文件验证失败
|
|
4066
|
+
*/
|
|
4067
|
+
(e: 'error', error: Error, file?: File): void;
|
|
4068
|
+
}
|
|
4069
|
+
|
|
4070
|
+
export declare interface UploadButtonProps {
|
|
4071
|
+
/**
|
|
4072
|
+
* 是否禁用
|
|
4073
|
+
*/
|
|
4074
|
+
disabled?: boolean;
|
|
4075
|
+
/**
|
|
4076
|
+
* 接受的文件类型
|
|
4077
|
+
* @default '*'
|
|
4078
|
+
*/
|
|
4079
|
+
accept?: string;
|
|
4080
|
+
/**
|
|
4081
|
+
* 是否支持多选
|
|
4082
|
+
* @default false
|
|
4083
|
+
*/
|
|
4084
|
+
multiple?: boolean;
|
|
4085
|
+
/**
|
|
4086
|
+
* 是否在选择文件后重置 input
|
|
4087
|
+
* @default true
|
|
4088
|
+
*/
|
|
4089
|
+
reset?: boolean;
|
|
4090
|
+
/**
|
|
4091
|
+
* 文件大小限制(MB)
|
|
4092
|
+
*/
|
|
4093
|
+
maxSize?: number;
|
|
4094
|
+
/**
|
|
4095
|
+
* 最大文件数量
|
|
4096
|
+
*/
|
|
4097
|
+
maxCount?: number;
|
|
4098
|
+
/**
|
|
4099
|
+
* 按钮提示文本
|
|
4100
|
+
*/
|
|
4101
|
+
tooltip?: TooltipContent;
|
|
4102
|
+
/**
|
|
4103
|
+
* 按钮尺寸
|
|
4104
|
+
*/
|
|
4105
|
+
size?: number | string;
|
|
4106
|
+
/**
|
|
4107
|
+
* 自定义图标
|
|
4108
|
+
*/
|
|
4109
|
+
icon?: Component;
|
|
4110
|
+
/**
|
|
4111
|
+
* Tooltip 位置
|
|
4112
|
+
*/
|
|
4113
|
+
tooltipPlacement?: TooltipPlacement;
|
|
4114
|
+
}
|
|
3205
4115
|
|
|
3206
4116
|
export declare interface UrlAttachment extends BaseAttachment {
|
|
3207
4117
|
url: string;
|
|
@@ -3209,16 +4119,31 @@ export declare interface UrlAttachment extends BaseAttachment {
|
|
|
3209
4119
|
rawFile?: File;
|
|
3210
4120
|
}
|
|
3211
4121
|
|
|
3212
|
-
|
|
4122
|
+
declare type UserItem = UserTextItem | UserTemplateItem;
|
|
3213
4123
|
|
|
3214
|
-
|
|
3215
|
-
id?:
|
|
4124
|
+
declare type UserTemplateItem = Omit<Pick<TemplateItem_2, 'type' | 'content'>, 'id'> & {
|
|
4125
|
+
id?: TemplateItem_2['id'];
|
|
3216
4126
|
};
|
|
3217
4127
|
|
|
3218
|
-
|
|
4128
|
+
declare type UserTextItem = Omit<TextItem, 'id'> & {
|
|
3219
4129
|
id?: TextItem['id'];
|
|
3220
4130
|
};
|
|
3221
4131
|
|
|
4132
|
+
/**
|
|
4133
|
+
* 获取 ChatInput Context
|
|
4134
|
+
*/
|
|
4135
|
+
export declare function useSenderContext(): SenderContext;
|
|
4136
|
+
|
|
4137
|
+
/**
|
|
4138
|
+
* 语音识别处理 Hook
|
|
4139
|
+
* 支持内置 Web Speech API 和自定义语音处理器
|
|
4140
|
+
* 通过 customHandler 参数切换实现,默认使用内置的 Web Speech API
|
|
4141
|
+
*
|
|
4142
|
+
* @param options 语音识别配置
|
|
4143
|
+
* @returns 语音识别控制器
|
|
4144
|
+
*/
|
|
4145
|
+
export declare function useSpeechHandler(options: SpeechHookOptions): SpeechHandlerResult;
|
|
4146
|
+
|
|
3222
4147
|
export declare const useTheme: () => {
|
|
3223
4148
|
theme: Ref<string, string> | undefined;
|
|
3224
4149
|
colorMode: Ref<ColorMode, ColorMode> | undefined;
|
|
@@ -3244,6 +4169,96 @@ declare interface VoiceButtonConfig {
|
|
|
3244
4169
|
icon?: VNode | Component;
|
|
3245
4170
|
}
|
|
3246
4171
|
|
|
4172
|
+
/**
|
|
4173
|
+
* VoiceButton 组件 Emits
|
|
4174
|
+
*/
|
|
4175
|
+
export declare interface VoiceButtonEmits {
|
|
4176
|
+
(e: 'speech-start'): void;
|
|
4177
|
+
(e: 'speech-interim', transcript: string): void;
|
|
4178
|
+
(e: 'speech-final', transcript: string): void;
|
|
4179
|
+
(e: 'speech-end', transcript?: string): void;
|
|
4180
|
+
(e: 'speech-error', error: Error): void;
|
|
4181
|
+
}
|
|
4182
|
+
|
|
4183
|
+
/**
|
|
4184
|
+
* VoiceButton 组件 Props
|
|
4185
|
+
*/
|
|
4186
|
+
export declare interface VoiceButtonProps {
|
|
4187
|
+
/**
|
|
4188
|
+
* 自定义图标
|
|
4189
|
+
*/
|
|
4190
|
+
icon?: VNode | Component;
|
|
4191
|
+
/**
|
|
4192
|
+
* 是否禁用(会与 Context 的 disabled 合并)
|
|
4193
|
+
*/
|
|
4194
|
+
disabled?: boolean;
|
|
4195
|
+
/**
|
|
4196
|
+
* 按钮尺寸
|
|
4197
|
+
*/
|
|
4198
|
+
size?: 'small' | 'normal';
|
|
4199
|
+
/**
|
|
4200
|
+
* Tooltip 文本
|
|
4201
|
+
*/
|
|
4202
|
+
tooltip?: TooltipContent;
|
|
4203
|
+
/**
|
|
4204
|
+
* Tooltip 位置
|
|
4205
|
+
*/
|
|
4206
|
+
tooltipPlacement?: TooltipPlacement;
|
|
4207
|
+
/**
|
|
4208
|
+
* 语音配置
|
|
4209
|
+
*/
|
|
4210
|
+
speechConfig?: SpeechConfig;
|
|
4211
|
+
/**
|
|
4212
|
+
* 是否自动插入识别结果到编辑器
|
|
4213
|
+
* @default true
|
|
4214
|
+
*/
|
|
4215
|
+
autoInsert?: boolean;
|
|
4216
|
+
/**
|
|
4217
|
+
* 按钮点击拦截器(用于自定义 UI)
|
|
4218
|
+
*/
|
|
4219
|
+
onButtonClick?: (isRecording: boolean, preventDefault: () => void) => void | Promise<void>;
|
|
4220
|
+
}
|
|
4221
|
+
|
|
4222
|
+
/**
|
|
4223
|
+
* 内置 Web Speech API 处理器
|
|
4224
|
+
* 基于浏览器原生 Web Speech API 实现的语音识别
|
|
4225
|
+
*/
|
|
4226
|
+
export declare class WebSpeechHandler implements SpeechHandler {
|
|
4227
|
+
private recognition?;
|
|
4228
|
+
private options;
|
|
4229
|
+
/**
|
|
4230
|
+
* 初始化语音识别实例
|
|
4231
|
+
*/
|
|
4232
|
+
private initialize;
|
|
4233
|
+
constructor(options: SpeechConfig);
|
|
4234
|
+
/**
|
|
4235
|
+
* 检查浏览器是否支持 Web Speech API
|
|
4236
|
+
*/
|
|
4237
|
+
static isSupported(): boolean;
|
|
4238
|
+
/**
|
|
4239
|
+
* 检查浏览器是否支持 Web Speech API(实例方法)
|
|
4240
|
+
*/
|
|
4241
|
+
isSupported(): boolean;
|
|
4242
|
+
/**
|
|
4243
|
+
* 设置语音识别事件处理器
|
|
4244
|
+
* @param callbacks 语音识别回调函数集合
|
|
4245
|
+
*/
|
|
4246
|
+
private setupEventHandlers;
|
|
4247
|
+
/**
|
|
4248
|
+
* 清理事件监听器
|
|
4249
|
+
*/
|
|
4250
|
+
private cleanup;
|
|
4251
|
+
/**
|
|
4252
|
+
* 开始语音识别
|
|
4253
|
+
* @param callbacks 语音识别回调函数集合
|
|
4254
|
+
*/
|
|
4255
|
+
start(callbacks: SpeechCallbacks): void;
|
|
4256
|
+
/**
|
|
4257
|
+
* 停止语音识别并清理资源
|
|
4258
|
+
*/
|
|
4259
|
+
stop(): void;
|
|
4260
|
+
}
|
|
4261
|
+
|
|
3247
4262
|
export declare interface WelcomeProps {
|
|
3248
4263
|
title: string;
|
|
3249
4264
|
description: string;
|
|
@@ -3256,3 +4271,53 @@ export declare interface WelcomeSlots {
|
|
|
3256
4271
|
}
|
|
3257
4272
|
|
|
3258
4273
|
export { }
|
|
4274
|
+
|
|
4275
|
+
|
|
4276
|
+
/**
|
|
4277
|
+
* 扩展 Tiptap Commands 接口
|
|
4278
|
+
*
|
|
4279
|
+
* 使 TypeScript 能够识别自定义命令
|
|
4280
|
+
*/
|
|
4281
|
+
declare module '@tiptap/core' {
|
|
4282
|
+
interface Commands<ReturnType> {
|
|
4283
|
+
mention: {
|
|
4284
|
+
/**
|
|
4285
|
+
* 插入 mention 节点
|
|
4286
|
+
*/
|
|
4287
|
+
insertMention: (attrs: Partial<MentionAttrs>) => ReturnType;
|
|
4288
|
+
/**
|
|
4289
|
+
* 删除 mention 节点
|
|
4290
|
+
*/
|
|
4291
|
+
deleteMention: (id: string) => ReturnType;
|
|
4292
|
+
};
|
|
4293
|
+
}
|
|
4294
|
+
}
|
|
4295
|
+
|
|
4296
|
+
|
|
4297
|
+
/**
|
|
4298
|
+
* 扩展 Tiptap Commands 接口
|
|
4299
|
+
*
|
|
4300
|
+
* 使 TypeScript 能够识别自定义命令
|
|
4301
|
+
*/
|
|
4302
|
+
declare module '@tiptap/core' {
|
|
4303
|
+
interface Commands<ReturnType> {
|
|
4304
|
+
template: {
|
|
4305
|
+
/**
|
|
4306
|
+
* 设置模板数据(批量)
|
|
4307
|
+
*/
|
|
4308
|
+
setTemplateData: (items: TemplateItem[]) => ReturnType;
|
|
4309
|
+
/**
|
|
4310
|
+
* 插入模板块
|
|
4311
|
+
*/
|
|
4312
|
+
insertTemplate: (attrs: Partial<TemplateAttrs>) => ReturnType;
|
|
4313
|
+
/**
|
|
4314
|
+
* 聚焦到第一个模板块
|
|
4315
|
+
*/
|
|
4316
|
+
focusFirstTemplate: () => ReturnType;
|
|
4317
|
+
/**
|
|
4318
|
+
* 插入选择器
|
|
4319
|
+
*/
|
|
4320
|
+
insertTemplateSelect: (attrs: Partial<TemplateSelectAttrs>) => ReturnType;
|
|
4321
|
+
};
|
|
4322
|
+
}
|
|
4323
|
+
}
|