@opentiny/tiny-robot 0.3.1-alpha.5 → 0.3.1-alpha.7

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/index.d.ts CHANGED
@@ -15,15 +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 { Editor } from '@tiptap/vue-3';
19
- import { Editor as Editor_2 } from '@tiptap/core';
20
- import { Extension } from '@tiptap/core';
18
+ import { ExtractPropTypes } from 'vue';
21
19
  import { GlobalComponents } from 'vue';
22
20
  import { GlobalDirectives } from 'vue';
21
+ import { MaybeComputedElementRef } from '@vueuse/core';
22
+ import { MaybeRefOrGetter } from 'vue';
23
23
  import { nextTick } from 'vue';
24
- import { Node as Node_2 } from '@tiptap/core';
25
24
  import { OnCleanup } from '@vue/reactivity';
26
25
  import { Options } from 'markdown-it';
26
+ import { PropType } from 'vue';
27
27
  import { PublicProps } from 'vue';
28
28
  import { Ref } from 'vue';
29
29
  import { RendererElement } from 'vue';
@@ -31,7 +31,6 @@ import { RendererNode } from 'vue';
31
31
  import { ShallowUnwrapRef } from 'vue';
32
32
  import { Slot } from 'vue';
33
33
  import { TransitionProps } from 'vue';
34
- import { UseFileDialogOptions } from '@vueuse/core';
35
34
  import { VNode } from 'vue';
36
35
  import { VNodeProps } from 'vue';
37
36
  import { WatchOptions } from 'vue';
@@ -195,32 +194,55 @@ declare const __VLS_component_12: DefineComponent<WelcomeProps, {}, {}, {}, {},
195
194
  align: "left" | "center" | "right" | string;
196
195
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
197
196
 
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;
197
+ declare const __VLS_component_13: DefineComponent<__VLS_PublicProps_6, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
198
+ "update:visible": (value: boolean) => any;
199
+ } & {
200
+ refresh: (tab: "installed" | "market") => any;
201
+ "update:visible": (visible: boolean) => any;
202
+ "market-category-change": (category: string) => any;
203
+ "tab-change": (activeTab: "installed" | "market") => any;
204
+ "plugin-toggle": (plugin: PluginInfo, enabled: boolean) => any;
205
+ "plugin-delete": (plugin: PluginInfo) => any;
206
+ "plugin-add": (plugin: PluginInfo) => any;
207
+ "plugin-create": (type: "code" | "form", data: PluginCreationData) => any;
208
+ "tool-toggle": (plugin: PluginInfo, toolId: string, enabled: boolean) => any;
209
+ "update:activeCount": (count: number) => any;
210
+ }, string, PublicProps, Readonly<__VLS_PublicProps_6> & Readonly<{
211
+ onRefresh?: ((tab: "installed" | "market") => any) | undefined;
212
+ "onUpdate:visible"?: ((value: boolean) => any) | undefined;
213
+ "onMarket-category-change"?: ((category: string) => any) | undefined;
214
+ "onTab-change"?: ((activeTab: "installed" | "market") => any) | undefined;
215
+ "onPlugin-toggle"?: ((plugin: PluginInfo, enabled: boolean) => any) | undefined;
216
+ "onPlugin-delete"?: ((plugin: PluginInfo) => any) | undefined;
217
+ "onPlugin-add"?: ((plugin: PluginInfo) => any) | undefined;
218
+ "onPlugin-create"?: ((type: "code" | "form", data: PluginCreationData) => any) | undefined;
219
+ "onTool-toggle"?: ((plugin: PluginInfo, toolId: string, enabled: boolean) => any) | undefined;
220
+ "onUpdate:activeCount"?: ((count: number) => any) | undefined;
221
221
  }>, {
222
- tooltipPlacement: TooltipPlacement;
223
- autoInsert: boolean;
222
+ title: string;
223
+ loading: boolean;
224
+ installedPlugins: PluginInfo[];
225
+ marketPlugins: PluginInfo[];
226
+ searchPlaceholder: string;
227
+ enableSearch: boolean;
228
+ installedSearchFn: (query: string, item: PluginInfo) => boolean;
229
+ marketSearchFn: (query: string, item: PluginInfo) => boolean;
230
+ marketCategoryOptions: MarketCategoryOption[];
231
+ marketCategoryPlaceholder: string;
232
+ enableMarketCategoryFilter: boolean;
233
+ defaultActiveTab: "installed" | "market";
234
+ showInstalledTab: boolean;
235
+ showMarketTab: boolean;
236
+ popupConfig: PopupConfig;
237
+ installedTabTitle: string;
238
+ marketTabTitle: string;
239
+ showCustomAddButton: boolean;
240
+ customAddButtonText: string;
241
+ allowPluginToggle: boolean;
242
+ allowToolToggle: boolean;
243
+ allowPluginDelete: boolean;
244
+ allowPluginAdd: boolean;
245
+ marketLoading: boolean;
224
246
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
225
247
 
226
248
  declare const __VLS_component_2: DefineComponent<__VLS_Props, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
@@ -356,14 +378,14 @@ declare const __VLS_component_6: DefineComponent<PromptsProps, {}, {}, {}, {}, C
356
378
  "onItem-click"?: ((ev: MouseEvent, item: PromptProps) => any) | undefined;
357
379
  }>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
358
380
 
359
- declare const __VLS_component_7: DefineComponent<SenderProps_2, {
381
+ declare const __VLS_component_7: DefineComponent<SenderProps, {
360
382
  focus: () => void;
361
383
  blur: () => void;
362
384
  clear: () => void;
363
385
  submit: () => void;
364
- setTemplateData: (templateData: UserTemplateItem[]) => void;
365
386
  startSpeech: () => void;
366
387
  stopSpeech: () => void;
388
+ activateTemplateFirstField: () => void;
367
389
  }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
368
390
  clear: () => any;
369
391
  blur: (event: FocusEvent) => any;
@@ -371,263 +393,544 @@ cancel: () => any;
371
393
  focus: (event: FocusEvent) => any;
372
394
  submit: (value: string) => any;
373
395
  "update:modelValue": (value: string) => any;
396
+ "update:templateData": (value: UserItem[]) => any;
374
397
  "speech-start": () => any;
375
- "speech-interim": (transcript: string) => any;
376
398
  "speech-end": (transcript?: string | undefined) => any;
399
+ "speech-interim": (transcript: string) => any;
377
400
  "speech-error": (error: Error) => any;
378
- "update:templateData": (value: UserItem[]) => any;
379
401
  "suggestion-select": (value: string) => any;
380
402
  "escape-press": () => any;
381
403
  "reset-template": () => any;
382
404
  "files-selected": (files: File[]) => any;
383
- }, string, PublicProps, Readonly<SenderProps_2> & Readonly<{
405
+ }, string, PublicProps, Readonly<SenderProps> & Readonly<{
384
406
  onClear?: (() => any) | undefined;
385
407
  onBlur?: ((event: FocusEvent) => any) | undefined;
386
408
  onCancel?: (() => any) | undefined;
387
409
  onFocus?: ((event: FocusEvent) => any) | undefined;
388
410
  onSubmit?: ((value: string) => any) | undefined;
389
411
  "onUpdate:modelValue"?: ((value: string) => any) | undefined;
412
+ "onUpdate:templateData"?: ((value: UserItem[]) => any) | undefined;
390
413
  "onSpeech-start"?: (() => any) | undefined;
391
- "onSpeech-interim"?: ((transcript: string) => any) | undefined;
392
414
  "onSpeech-end"?: ((transcript?: string | undefined) => any) | undefined;
415
+ "onSpeech-interim"?: ((transcript: string) => any) | undefined;
393
416
  "onSpeech-error"?: ((error: Error) => any) | undefined;
394
- "onUpdate:templateData"?: ((value: UserItem[]) => any) | undefined;
395
417
  "onSuggestion-select"?: ((value: string) => any) | undefined;
396
418
  "onEscape-press"?: (() => any) | undefined;
397
419
  "onReset-template"?: (() => any) | undefined;
398
420
  "onFiles-selected"?: ((files: File[]) => any) | undefined;
399
421
  }>, {
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";
422
+ disabled: boolean;
423
+ modelValue: string;
473
424
  placeholder: string;
474
425
  mode: InputMode;
475
- autoSize: AutoSize;
476
- extensions: Extension[] | any[];
426
+ loading: boolean;
427
+ autofocus: boolean;
428
+ allowSpeech: boolean;
429
+ allowFiles: boolean;
477
430
  submitType: SubmitTrigger;
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;
431
+ stopText: string;
502
432
  autoSize: AutoSize;
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;
537
- };
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;
433
+ suggestions: ISuggestionItem[];
434
+ clearable: boolean;
435
+ maxLength: number;
436
+ showWordLimit: boolean;
437
+ suggestionPopupWidth: string | number;
438
+ theme: ThemeType;
439
+ templateData: UserItem[];
440
+ }, {}, {}, {}, string, ComponentProvideOptions, false, {
441
+ senderRef: HTMLDivElement;
442
+ inputWrapperRef: HTMLDivElement;
443
+ templateEditorRef: CreateComponentPublicInstanceWithMixins<Readonly<{
444
+ modelValue?: UserItem[];
445
+ } & {
446
+ autoSize: boolean | {
447
+ minRows: number;
448
+ maxRows: number;
562
449
  };
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;
450
+ }> & Readonly<{
451
+ onSubmit?: (() => any) | undefined;
452
+ "onUpdate:modelValue"?: ((value: UserItem[]) => any) | undefined;
577
453
  }>, {
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;
454
+ clearHistory: () => void;
455
+ activateFirstField: () => void;
456
+ }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
457
+ "update:modelValue": (value: UserItem[]) => any;
458
+ } & {
459
+ submit: () => any;
460
+ }, PublicProps, {}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {
461
+ editorRef: HTMLDivElement;
462
+ }, HTMLDivElement, ComponentProvideOptions, {
463
+ P: {};
464
+ B: {};
465
+ D: {};
466
+ C: {};
467
+ M: {};
468
+ Defaults: {};
469
+ }, Readonly<{
470
+ modelValue?: UserItem[];
471
+ } & {
472
+ autoSize: boolean | {
473
+ minRows: number;
474
+ maxRows: number;
629
475
  };
630
- }) | null;
476
+ }> & Readonly<{
477
+ onSubmit?: (() => any) | undefined;
478
+ "onUpdate:modelValue"?: ((value: UserItem[]) => any) | undefined;
479
+ }>, {
480
+ clearHistory: () => void;
481
+ activateFirstField: () => void;
482
+ }, {}, {}, {}, {}> | null;
483
+ inputRef: CreateComponentPublicInstanceWithMixins<Readonly<ExtractPropTypes< {
484
+ _constants: {
485
+ type: ObjectConstructor;
486
+ default: () => {
487
+ INPUT_PC: string;
488
+ INPUTGROUP_PC: string;
489
+ INPUT_MOBILE: string;
490
+ INPUTGROUP_MOBILE: string;
491
+ Mode: string;
492
+ inputMode(mode: any): string;
493
+ inputGroupMode(mode: any): string;
494
+ VALIDATE_ICON: {
495
+ Validating: string;
496
+ Success: string;
497
+ Error: string;
498
+ };
499
+ COMPONENT_NAME: {
500
+ FormItem: string;
501
+ };
502
+ MASKSYMBOL: string;
503
+ TEXTAREA_HEIGHT_MOBILE: number;
504
+ };
505
+ };
506
+ name: StringConstructor;
507
+ size: StringConstructor;
508
+ form: StringConstructor;
509
+ label: StringConstructor;
510
+ height: NumberConstructor;
511
+ resize: StringConstructor;
512
+ tabindex: {
513
+ type: StringConstructor;
514
+ default: string;
515
+ };
516
+ disabled: BooleanConstructor;
517
+ readonly: BooleanConstructor;
518
+ hoverExpand: BooleanConstructor;
519
+ mask: BooleanConstructor;
520
+ suffixIcon: (StringConstructor | ObjectConstructor)[];
521
+ prefixIcon: (StringConstructor | ObjectConstructor)[];
522
+ modelValue: PropType<string | number | null>;
523
+ type: {
524
+ type: StringConstructor;
525
+ default: string;
526
+ };
527
+ memorySpace: {
528
+ type: NumberConstructor;
529
+ default: number;
530
+ };
531
+ vertical: {
532
+ type: BooleanConstructor;
533
+ default: boolean;
534
+ };
535
+ selectMenu: {
536
+ type: {
537
+ (arrayLength: number): {
538
+ id: string;
539
+ label: string;
540
+ }[];
541
+ (...items: {
542
+ id: string;
543
+ label: string;
544
+ }[]): {
545
+ id: string;
546
+ label: string;
547
+ }[];
548
+ new (arrayLength: number): {
549
+ id: string;
550
+ label: string;
551
+ }[];
552
+ new (...items: {
553
+ id: string;
554
+ label: string;
555
+ }[]): {
556
+ id: string;
557
+ label: string;
558
+ }[];
559
+ isArray(arg: any): arg is any[];
560
+ readonly prototype: any[];
561
+ from<T>(arrayLike: ArrayLike<T>): T[];
562
+ from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
563
+ from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
564
+ from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
565
+ of<T_4>(...items: T_4[]): T_4[];
566
+ readonly [Symbol.species]: ArrayConstructor;
567
+ };
568
+ default: () => never[];
569
+ };
570
+ ellipsis: {
571
+ type: BooleanConstructor;
572
+ default: boolean;
573
+ };
574
+ contentStyle: {
575
+ type: ObjectConstructor;
576
+ default: () => {};
577
+ };
578
+ isSelect: {
579
+ type: BooleanConstructor;
580
+ default: boolean;
581
+ };
582
+ tips: StringConstructor;
583
+ counter: {
584
+ type: BooleanConstructor;
585
+ default: boolean;
586
+ };
587
+ autosize: {
588
+ type: (BooleanConstructor | ObjectConstructor)[];
589
+ default: boolean;
590
+ };
591
+ clearable: {
592
+ type: BooleanConstructor;
593
+ default: boolean;
594
+ };
595
+ autocomplete: {
596
+ type: StringConstructor;
597
+ default: string;
598
+ };
599
+ showPassword: {
600
+ type: BooleanConstructor;
601
+ default: boolean;
602
+ };
603
+ showWordLimit: {
604
+ type: BooleanConstructor;
605
+ default: boolean;
606
+ };
607
+ showTitle: {
608
+ type: BooleanConstructor;
609
+ default: boolean;
610
+ };
611
+ validateEvent: {
612
+ type: BooleanConstructor;
613
+ default: boolean;
614
+ };
615
+ popupMore: {
616
+ type: BooleanConstructor;
617
+ default: boolean;
618
+ };
619
+ textareaTitle: {
620
+ type: StringConstructor;
621
+ default: string;
622
+ };
623
+ displayOnly: {
624
+ type: BooleanConstructor;
625
+ default: boolean;
626
+ };
627
+ displayOnlyContent: {
628
+ type: StringConstructor;
629
+ default: string;
630
+ };
631
+ customClass: {
632
+ type: StringConstructor;
633
+ default: string;
634
+ };
635
+ frontClearIcon: {
636
+ type: BooleanConstructor;
637
+ default: boolean;
638
+ };
639
+ showEmptyValue: {
640
+ type: BooleanConstructor;
641
+ default: undefined;
642
+ };
643
+ textAlign: {
644
+ type: StringConstructor;
645
+ default: string;
646
+ };
647
+ width: {
648
+ type: PropType<string | number | null>;
649
+ };
650
+ showTooltip: {
651
+ type: BooleanConstructor;
652
+ default: boolean;
653
+ };
654
+ inputBoxType: {
655
+ type: StringConstructor;
656
+ default: string;
657
+ validator: (value: string) => boolean;
658
+ };
659
+ tiny_mode: StringConstructor;
660
+ tiny_mode_root: BooleanConstructor;
661
+ tiny_template: (ObjectConstructor | FunctionConstructor)[];
662
+ tiny_renderless: FunctionConstructor;
663
+ tiny_theme: StringConstructor;
664
+ tiny_mcp_config: ObjectConstructor;
665
+ tiny_chart_theme: ObjectConstructor;
666
+ }>>, () => VNode<RendererNode, RendererElement, {
667
+ [key: string]: any;
668
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {
669
+ disabled: boolean;
670
+ type: string;
671
+ ellipsis: boolean;
672
+ mask: boolean;
673
+ vertical: boolean;
674
+ customClass: string;
675
+ tiny_mode_root: boolean;
676
+ _constants: Record<string, any>;
677
+ tabindex: string;
678
+ showTitle: boolean;
679
+ readonly: boolean;
680
+ hoverExpand: boolean;
681
+ memorySpace: number;
682
+ selectMenu: {
683
+ id: string;
684
+ label: string;
685
+ }[];
686
+ contentStyle: Record<string, any>;
687
+ isSelect: boolean;
688
+ counter: boolean;
689
+ autosize: boolean | Record<string, any>;
690
+ clearable: boolean;
691
+ autocomplete: string;
692
+ showPassword: boolean;
693
+ showWordLimit: boolean;
694
+ validateEvent: boolean;
695
+ popupMore: boolean;
696
+ textareaTitle: string;
697
+ displayOnly: boolean;
698
+ displayOnlyContent: string;
699
+ frontClearIcon: boolean;
700
+ showEmptyValue: boolean;
701
+ textAlign: string;
702
+ showTooltip: boolean;
703
+ inputBoxType: string;
704
+ }, true, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
705
+ P: {};
706
+ B: {};
707
+ D: {};
708
+ C: {};
709
+ M: {};
710
+ Defaults: {};
711
+ }, Readonly<ExtractPropTypes< {
712
+ _constants: {
713
+ type: ObjectConstructor;
714
+ default: () => {
715
+ INPUT_PC: string;
716
+ INPUTGROUP_PC: string;
717
+ INPUT_MOBILE: string;
718
+ INPUTGROUP_MOBILE: string;
719
+ Mode: string;
720
+ inputMode(mode: any): string;
721
+ inputGroupMode(mode: any): string;
722
+ VALIDATE_ICON: {
723
+ Validating: string;
724
+ Success: string;
725
+ Error: string;
726
+ };
727
+ COMPONENT_NAME: {
728
+ FormItem: string;
729
+ };
730
+ MASKSYMBOL: string;
731
+ TEXTAREA_HEIGHT_MOBILE: number;
732
+ };
733
+ };
734
+ name: StringConstructor;
735
+ size: StringConstructor;
736
+ form: StringConstructor;
737
+ label: StringConstructor;
738
+ height: NumberConstructor;
739
+ resize: StringConstructor;
740
+ tabindex: {
741
+ type: StringConstructor;
742
+ default: string;
743
+ };
744
+ disabled: BooleanConstructor;
745
+ readonly: BooleanConstructor;
746
+ hoverExpand: BooleanConstructor;
747
+ mask: BooleanConstructor;
748
+ suffixIcon: (StringConstructor | ObjectConstructor)[];
749
+ prefixIcon: (StringConstructor | ObjectConstructor)[];
750
+ modelValue: PropType<string | number | null>;
751
+ type: {
752
+ type: StringConstructor;
753
+ default: string;
754
+ };
755
+ memorySpace: {
756
+ type: NumberConstructor;
757
+ default: number;
758
+ };
759
+ vertical: {
760
+ type: BooleanConstructor;
761
+ default: boolean;
762
+ };
763
+ selectMenu: {
764
+ type: {
765
+ (arrayLength: number): {
766
+ id: string;
767
+ label: string;
768
+ }[];
769
+ (...items: {
770
+ id: string;
771
+ label: string;
772
+ }[]): {
773
+ id: string;
774
+ label: string;
775
+ }[];
776
+ new (arrayLength: number): {
777
+ id: string;
778
+ label: string;
779
+ }[];
780
+ new (...items: {
781
+ id: string;
782
+ label: string;
783
+ }[]): {
784
+ id: string;
785
+ label: string;
786
+ }[];
787
+ isArray(arg: any): arg is any[];
788
+ readonly prototype: any[];
789
+ from<T>(arrayLike: ArrayLike<T>): T[];
790
+ from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
791
+ from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
792
+ from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
793
+ of<T_4>(...items: T_4[]): T_4[];
794
+ readonly [Symbol.species]: ArrayConstructor;
795
+ };
796
+ default: () => never[];
797
+ };
798
+ ellipsis: {
799
+ type: BooleanConstructor;
800
+ default: boolean;
801
+ };
802
+ contentStyle: {
803
+ type: ObjectConstructor;
804
+ default: () => {};
805
+ };
806
+ isSelect: {
807
+ type: BooleanConstructor;
808
+ default: boolean;
809
+ };
810
+ tips: StringConstructor;
811
+ counter: {
812
+ type: BooleanConstructor;
813
+ default: boolean;
814
+ };
815
+ autosize: {
816
+ type: (BooleanConstructor | ObjectConstructor)[];
817
+ default: boolean;
818
+ };
819
+ clearable: {
820
+ type: BooleanConstructor;
821
+ default: boolean;
822
+ };
823
+ autocomplete: {
824
+ type: StringConstructor;
825
+ default: string;
826
+ };
827
+ showPassword: {
828
+ type: BooleanConstructor;
829
+ default: boolean;
830
+ };
831
+ showWordLimit: {
832
+ type: BooleanConstructor;
833
+ default: boolean;
834
+ };
835
+ showTitle: {
836
+ type: BooleanConstructor;
837
+ default: boolean;
838
+ };
839
+ validateEvent: {
840
+ type: BooleanConstructor;
841
+ default: boolean;
842
+ };
843
+ popupMore: {
844
+ type: BooleanConstructor;
845
+ default: boolean;
846
+ };
847
+ textareaTitle: {
848
+ type: StringConstructor;
849
+ default: string;
850
+ };
851
+ displayOnly: {
852
+ type: BooleanConstructor;
853
+ default: boolean;
854
+ };
855
+ displayOnlyContent: {
856
+ type: StringConstructor;
857
+ default: string;
858
+ };
859
+ customClass: {
860
+ type: StringConstructor;
861
+ default: string;
862
+ };
863
+ frontClearIcon: {
864
+ type: BooleanConstructor;
865
+ default: boolean;
866
+ };
867
+ showEmptyValue: {
868
+ type: BooleanConstructor;
869
+ default: undefined;
870
+ };
871
+ textAlign: {
872
+ type: StringConstructor;
873
+ default: string;
874
+ };
875
+ width: {
876
+ type: PropType<string | number | null>;
877
+ };
878
+ showTooltip: {
879
+ type: BooleanConstructor;
880
+ default: boolean;
881
+ };
882
+ inputBoxType: {
883
+ type: StringConstructor;
884
+ default: string;
885
+ validator: (value: string) => boolean;
886
+ };
887
+ tiny_mode: StringConstructor;
888
+ tiny_mode_root: BooleanConstructor;
889
+ tiny_template: (ObjectConstructor | FunctionConstructor)[];
890
+ tiny_renderless: FunctionConstructor;
891
+ tiny_theme: StringConstructor;
892
+ tiny_mcp_config: ObjectConstructor;
893
+ tiny_chart_theme: ObjectConstructor;
894
+ }>>, () => VNode<RendererNode, RendererElement, {
895
+ [key: string]: any;
896
+ }>, {}, {}, {}, {
897
+ disabled: boolean;
898
+ type: string;
899
+ ellipsis: boolean;
900
+ mask: boolean;
901
+ vertical: boolean;
902
+ customClass: string;
903
+ tiny_mode_root: boolean;
904
+ _constants: Record<string, any>;
905
+ tabindex: string;
906
+ showTitle: boolean;
907
+ readonly: boolean;
908
+ hoverExpand: boolean;
909
+ memorySpace: number;
910
+ selectMenu: {
911
+ id: string;
912
+ label: string;
913
+ }[];
914
+ contentStyle: Record<string, any>;
915
+ isSelect: boolean;
916
+ counter: boolean;
917
+ autosize: boolean | Record<string, any>;
918
+ clearable: boolean;
919
+ autocomplete: string;
920
+ showPassword: boolean;
921
+ showWordLimit: boolean;
922
+ validateEvent: boolean;
923
+ popupMore: boolean;
924
+ textareaTitle: string;
925
+ displayOnly: boolean;
926
+ displayOnlyContent: string;
927
+ frontClearIcon: boolean;
928
+ showEmptyValue: boolean;
929
+ textAlign: string;
930
+ showTooltip: boolean;
931
+ inputBoxType: string;
932
+ }> | null;
933
+ buttonsContainerRef: HTMLDivElement;
631
934
  }, HTMLDivElement>;
632
935
 
633
936
  declare const __VLS_component_8: DefineComponent<SuggestionPillButtonProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<SuggestionPillButtonProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLButtonElement>;
@@ -843,20 +1146,7 @@ declare function __VLS_template_12(): {
843
1146
  declare function __VLS_template_13(): {
844
1147
  attrs: Partial<{}>;
845
1148
  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;
1149
+ 'header-actions'?(_: {}): any;
860
1150
  };
861
1151
  refs: {};
862
1152
  rootEl: any;
@@ -1003,242 +1293,507 @@ declare function __VLS_template_7(): {
1003
1293
  slots: {
1004
1294
  header?(_: {}): any;
1005
1295
  prefix?(_: {}): any;
1006
- content?(_: {
1007
- editor: Ref<Editor | undefined, Editor | undefined>;
1008
- }): any;
1296
+ content?(_: {}): any;
1297
+ decorativeContent?(_: {}): any;
1009
1298
  actions?(_: {}): any;
1010
1299
  'footer-left'?(_: {}): any;
1011
- footer?(_: {}): any;
1012
1300
  'footer-right'?(_: {}): any;
1301
+ footer?(_: {}): any;
1013
1302
  };
1014
1303
  refs: {
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;
1304
+ senderRef: HTMLDivElement;
1305
+ inputWrapperRef: HTMLDivElement;
1306
+ templateEditorRef: CreateComponentPublicInstanceWithMixins<Readonly<{
1307
+ modelValue?: UserItem[];
1308
+ } & {
1309
+ autoSize: boolean | {
1310
+ minRows: number;
1311
+ maxRows: number;
1312
+ };
1313
+ }> & Readonly<{
1314
+ onSubmit?: (() => any) | undefined;
1315
+ "onUpdate:modelValue"?: ((value: UserItem[]) => any) | undefined;
1316
+ }>, {
1317
+ clearHistory: () => void;
1318
+ activateFirstField: () => void;
1319
+ }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
1320
+ "update:modelValue": (value: UserItem[]) => any;
1321
+ } & {
1322
+ submit: () => any;
1323
+ }, PublicProps, {}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {
1324
+ editorRef: HTMLDivElement;
1325
+ }, HTMLDivElement, ComponentProvideOptions, {
1326
+ P: {};
1327
+ B: {};
1328
+ D: {};
1329
+ C: {};
1330
+ M: {};
1331
+ Defaults: {};
1332
+ }, Readonly<{
1333
+ modelValue?: UserItem[];
1334
+ } & {
1335
+ autoSize: boolean | {
1336
+ minRows: number;
1337
+ maxRows: number;
1338
+ };
1339
+ }> & Readonly<{
1340
+ onSubmit?: (() => any) | undefined;
1341
+ "onUpdate:modelValue"?: ((value: UserItem[]) => any) | undefined;
1342
+ }>, {
1343
+ clearHistory: () => void;
1344
+ activateFirstField: () => void;
1345
+ }, {}, {}, {}, {}> | null;
1346
+ inputRef: CreateComponentPublicInstanceWithMixins<Readonly<ExtractPropTypes< {
1347
+ _constants: {
1348
+ type: ObjectConstructor;
1349
+ default: () => {
1350
+ INPUT_PC: string;
1351
+ INPUTGROUP_PC: string;
1352
+ INPUT_MOBILE: string;
1353
+ INPUTGROUP_MOBILE: string;
1354
+ Mode: string;
1355
+ inputMode(mode: any): string;
1356
+ inputGroupMode(mode: any): string;
1357
+ VALIDATE_ICON: {
1358
+ Validating: string;
1359
+ Success: string;
1360
+ Error: string;
1361
+ };
1362
+ COMPONENT_NAME: {
1363
+ FormItem: string;
1364
+ };
1365
+ MASKSYMBOL: string;
1366
+ TEXTAREA_HEIGHT_MOBILE: number;
1367
+ };
1368
+ };
1369
+ name: StringConstructor;
1370
+ size: StringConstructor;
1371
+ form: StringConstructor;
1372
+ label: StringConstructor;
1373
+ height: NumberConstructor;
1374
+ resize: StringConstructor;
1375
+ tabindex: {
1376
+ type: StringConstructor;
1377
+ default: string;
1378
+ };
1379
+ disabled: BooleanConstructor;
1380
+ readonly: BooleanConstructor;
1381
+ hoverExpand: BooleanConstructor;
1382
+ mask: BooleanConstructor;
1383
+ suffixIcon: (StringConstructor | ObjectConstructor)[];
1384
+ prefixIcon: (StringConstructor | ObjectConstructor)[];
1385
+ modelValue: PropType<string | number | null>;
1386
+ type: {
1387
+ type: StringConstructor;
1388
+ default: string;
1389
+ };
1390
+ memorySpace: {
1391
+ type: NumberConstructor;
1392
+ default: number;
1393
+ };
1394
+ vertical: {
1395
+ type: BooleanConstructor;
1396
+ default: boolean;
1397
+ };
1398
+ selectMenu: {
1399
+ type: {
1400
+ (arrayLength: number): {
1401
+ id: string;
1402
+ label: string;
1403
+ }[];
1404
+ (...items: {
1405
+ id: string;
1406
+ label: string;
1407
+ }[]): {
1408
+ id: string;
1409
+ label: string;
1410
+ }[];
1411
+ new (arrayLength: number): {
1412
+ id: string;
1413
+ label: string;
1414
+ }[];
1415
+ new (...items: {
1416
+ id: string;
1417
+ label: string;
1418
+ }[]): {
1419
+ id: string;
1420
+ label: string;
1421
+ }[];
1422
+ isArray(arg: any): arg is any[];
1423
+ readonly prototype: any[];
1424
+ from<T>(arrayLike: ArrayLike<T>): T[];
1425
+ from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
1426
+ from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
1427
+ from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
1428
+ of<T_4>(...items: T_4[]): T_4[];
1429
+ readonly [Symbol.species]: ArrayConstructor;
1430
+ };
1431
+ default: () => never[];
1432
+ };
1433
+ ellipsis: {
1434
+ type: BooleanConstructor;
1435
+ default: boolean;
1436
+ };
1437
+ contentStyle: {
1438
+ type: ObjectConstructor;
1439
+ default: () => {};
1440
+ };
1441
+ isSelect: {
1442
+ type: BooleanConstructor;
1443
+ default: boolean;
1444
+ };
1445
+ tips: StringConstructor;
1446
+ counter: {
1447
+ type: BooleanConstructor;
1448
+ default: boolean;
1449
+ };
1450
+ autosize: {
1451
+ type: (BooleanConstructor | ObjectConstructor)[];
1452
+ default: boolean;
1453
+ };
1454
+ clearable: {
1455
+ type: BooleanConstructor;
1456
+ default: boolean;
1457
+ };
1458
+ autocomplete: {
1459
+ type: StringConstructor;
1460
+ default: string;
1461
+ };
1462
+ showPassword: {
1463
+ type: BooleanConstructor;
1464
+ default: boolean;
1465
+ };
1466
+ showWordLimit: {
1467
+ type: BooleanConstructor;
1468
+ default: boolean;
1469
+ };
1470
+ showTitle: {
1471
+ type: BooleanConstructor;
1472
+ default: boolean;
1473
+ };
1474
+ validateEvent: {
1475
+ type: BooleanConstructor;
1476
+ default: boolean;
1477
+ };
1478
+ popupMore: {
1479
+ type: BooleanConstructor;
1480
+ default: boolean;
1481
+ };
1482
+ textareaTitle: {
1483
+ type: StringConstructor;
1484
+ default: string;
1485
+ };
1486
+ displayOnly: {
1487
+ type: BooleanConstructor;
1488
+ default: boolean;
1489
+ };
1490
+ displayOnlyContent: {
1491
+ type: StringConstructor;
1492
+ default: string;
1493
+ };
1494
+ customClass: {
1495
+ type: StringConstructor;
1496
+ default: string;
1497
+ };
1498
+ frontClearIcon: {
1499
+ type: BooleanConstructor;
1500
+ default: boolean;
1501
+ };
1502
+ showEmptyValue: {
1503
+ type: BooleanConstructor;
1504
+ default: undefined;
1505
+ };
1506
+ textAlign: {
1507
+ type: StringConstructor;
1508
+ default: string;
1509
+ };
1510
+ width: {
1511
+ type: PropType<string | number | null>;
1512
+ };
1513
+ showTooltip: {
1514
+ type: BooleanConstructor;
1515
+ default: boolean;
1516
+ };
1517
+ inputBoxType: {
1518
+ type: StringConstructor;
1519
+ default: string;
1520
+ validator: (value: string) => boolean;
1521
+ };
1522
+ tiny_mode: StringConstructor;
1523
+ tiny_mode_root: BooleanConstructor;
1524
+ tiny_template: (ObjectConstructor | FunctionConstructor)[];
1525
+ tiny_renderless: FunctionConstructor;
1526
+ tiny_theme: StringConstructor;
1527
+ tiny_mcp_config: ObjectConstructor;
1528
+ tiny_chart_theme: ObjectConstructor;
1529
+ }>>, () => VNode<RendererNode, RendererElement, {
1530
+ [key: string]: any;
1531
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {
1532
+ disabled: boolean;
1533
+ type: string;
1534
+ ellipsis: boolean;
1535
+ mask: boolean;
1536
+ vertical: boolean;
1537
+ customClass: string;
1538
+ tiny_mode_root: boolean;
1539
+ _constants: Record<string, any>;
1540
+ tabindex: string;
1541
+ showTitle: boolean;
1542
+ readonly: boolean;
1543
+ hoverExpand: boolean;
1544
+ memorySpace: number;
1545
+ selectMenu: {
1546
+ id: string;
1547
+ label: string;
1548
+ }[];
1549
+ contentStyle: Record<string, any>;
1550
+ isSelect: boolean;
1551
+ counter: boolean;
1552
+ autosize: boolean | Record<string, any>;
1553
+ clearable: boolean;
1554
+ autocomplete: string;
1555
+ showPassword: boolean;
1556
+ showWordLimit: boolean;
1557
+ validateEvent: boolean;
1558
+ popupMore: boolean;
1559
+ textareaTitle: string;
1560
+ displayOnly: boolean;
1561
+ displayOnlyContent: string;
1562
+ frontClearIcon: boolean;
1563
+ showEmptyValue: boolean;
1564
+ textAlign: string;
1565
+ showTooltip: boolean;
1566
+ inputBoxType: string;
1567
+ }, true, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
1568
+ P: {};
1569
+ B: {};
1570
+ D: {};
1571
+ C: {};
1572
+ M: {};
1573
+ Defaults: {};
1574
+ }, Readonly<ExtractPropTypes< {
1575
+ _constants: {
1576
+ type: ObjectConstructor;
1577
+ default: () => {
1578
+ INPUT_PC: string;
1579
+ INPUTGROUP_PC: string;
1580
+ INPUT_MOBILE: string;
1581
+ INPUTGROUP_MOBILE: string;
1582
+ Mode: string;
1583
+ inputMode(mode: any): string;
1584
+ inputGroupMode(mode: any): string;
1585
+ VALIDATE_ICON: {
1586
+ Validating: string;
1587
+ Success: string;
1588
+ Error: string;
1589
+ };
1590
+ COMPONENT_NAME: {
1591
+ FormItem: string;
1592
+ };
1593
+ MASKSYMBOL: string;
1594
+ TEXTAREA_HEIGHT_MOBILE: number;
1595
+ };
1596
+ };
1597
+ name: StringConstructor;
1598
+ size: StringConstructor;
1599
+ form: StringConstructor;
1600
+ label: StringConstructor;
1601
+ height: NumberConstructor;
1602
+ resize: StringConstructor;
1603
+ tabindex: {
1604
+ type: StringConstructor;
1605
+ default: string;
1606
+ };
1607
+ disabled: BooleanConstructor;
1608
+ readonly: BooleanConstructor;
1609
+ hoverExpand: BooleanConstructor;
1610
+ mask: BooleanConstructor;
1611
+ suffixIcon: (StringConstructor | ObjectConstructor)[];
1612
+ prefixIcon: (StringConstructor | ObjectConstructor)[];
1613
+ modelValue: PropType<string | number | null>;
1614
+ type: {
1615
+ type: StringConstructor;
1616
+ default: string;
1617
+ };
1618
+ memorySpace: {
1619
+ type: NumberConstructor;
1620
+ default: number;
1621
+ };
1622
+ vertical: {
1623
+ type: BooleanConstructor;
1624
+ default: boolean;
1625
+ };
1626
+ selectMenu: {
1627
+ type: {
1628
+ (arrayLength: number): {
1629
+ id: string;
1630
+ label: string;
1631
+ }[];
1632
+ (...items: {
1633
+ id: string;
1634
+ label: string;
1635
+ }[]): {
1636
+ id: string;
1637
+ label: string;
1638
+ }[];
1639
+ new (arrayLength: number): {
1640
+ id: string;
1641
+ label: string;
1642
+ }[];
1643
+ new (...items: {
1644
+ id: string;
1645
+ label: string;
1646
+ }[]): {
1647
+ id: string;
1648
+ label: string;
1649
+ }[];
1650
+ isArray(arg: any): arg is any[];
1651
+ readonly prototype: any[];
1652
+ from<T>(arrayLike: ArrayLike<T>): T[];
1653
+ from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
1654
+ from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
1655
+ from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
1656
+ of<T_4>(...items: T_4[]): T_4[];
1657
+ readonly [Symbol.species]: ArrayConstructor;
1658
+ };
1659
+ default: () => never[];
1660
+ };
1661
+ ellipsis: {
1662
+ type: BooleanConstructor;
1663
+ default: boolean;
1664
+ };
1665
+ contentStyle: {
1666
+ type: ObjectConstructor;
1667
+ default: () => {};
1668
+ };
1669
+ isSelect: {
1670
+ type: BooleanConstructor;
1671
+ default: boolean;
1672
+ };
1673
+ tips: StringConstructor;
1674
+ counter: {
1675
+ type: BooleanConstructor;
1676
+ default: boolean;
1677
+ };
1678
+ autosize: {
1679
+ type: (BooleanConstructor | ObjectConstructor)[];
1680
+ default: boolean;
1681
+ };
1682
+ clearable: {
1683
+ type: BooleanConstructor;
1684
+ default: boolean;
1685
+ };
1686
+ autocomplete: {
1687
+ type: StringConstructor;
1688
+ default: string;
1689
+ };
1690
+ showPassword: {
1691
+ type: BooleanConstructor;
1692
+ default: boolean;
1693
+ };
1694
+ showWordLimit: {
1695
+ type: BooleanConstructor;
1696
+ default: boolean;
1697
+ };
1698
+ showTitle: {
1699
+ type: BooleanConstructor;
1700
+ default: boolean;
1701
+ };
1702
+ validateEvent: {
1703
+ type: BooleanConstructor;
1704
+ default: boolean;
1705
+ };
1706
+ popupMore: {
1707
+ type: BooleanConstructor;
1708
+ default: boolean;
1709
+ };
1710
+ textareaTitle: {
1711
+ type: StringConstructor;
1712
+ default: string;
1713
+ };
1714
+ displayOnly: {
1715
+ type: BooleanConstructor;
1716
+ default: boolean;
1717
+ };
1718
+ displayOnlyContent: {
1719
+ type: StringConstructor;
1720
+ default: string;
1721
+ };
1722
+ customClass: {
1723
+ type: StringConstructor;
1724
+ default: string;
1725
+ };
1726
+ frontClearIcon: {
1727
+ type: BooleanConstructor;
1728
+ default: boolean;
1729
+ };
1730
+ showEmptyValue: {
1731
+ type: BooleanConstructor;
1732
+ default: undefined;
1733
+ };
1734
+ textAlign: {
1735
+ type: StringConstructor;
1736
+ default: string;
1737
+ };
1738
+ width: {
1739
+ type: PropType<string | number | null>;
1740
+ };
1741
+ showTooltip: {
1742
+ type: BooleanConstructor;
1743
+ default: boolean;
1744
+ };
1745
+ inputBoxType: {
1746
+ type: StringConstructor;
1747
+ default: string;
1748
+ validator: (value: string) => boolean;
1749
+ };
1750
+ tiny_mode: StringConstructor;
1751
+ tiny_mode_root: BooleanConstructor;
1752
+ tiny_template: (ObjectConstructor | FunctionConstructor)[];
1753
+ tiny_renderless: FunctionConstructor;
1754
+ tiny_theme: StringConstructor;
1755
+ tiny_mcp_config: ObjectConstructor;
1756
+ tiny_chart_theme: ObjectConstructor;
1757
+ }>>, () => VNode<RendererNode, RendererElement, {
1758
+ [key: string]: any;
1759
+ }>, {}, {}, {}, {
1760
+ disabled: boolean;
1761
+ type: string;
1762
+ ellipsis: boolean;
1763
+ mask: boolean;
1764
+ vertical: boolean;
1765
+ customClass: string;
1766
+ tiny_mode_root: boolean;
1767
+ _constants: Record<string, any>;
1768
+ tabindex: string;
1769
+ showTitle: boolean;
1770
+ readonly: boolean;
1771
+ hoverExpand: boolean;
1772
+ memorySpace: number;
1773
+ selectMenu: {
1774
+ id: string;
1775
+ label: string;
1776
+ }[];
1777
+ contentStyle: Record<string, any>;
1778
+ isSelect: boolean;
1779
+ counter: boolean;
1780
+ autosize: boolean | Record<string, any>;
1781
+ clearable: boolean;
1782
+ autocomplete: string;
1783
+ showPassword: boolean;
1784
+ showWordLimit: boolean;
1785
+ validateEvent: boolean;
1786
+ popupMore: boolean;
1787
+ textareaTitle: string;
1788
+ displayOnly: boolean;
1789
+ displayOnlyContent: string;
1790
+ frontClearIcon: boolean;
1791
+ showEmptyValue: boolean;
1792
+ textAlign: string;
1793
+ showTooltip: boolean;
1794
+ inputBoxType: string;
1795
+ }> | null;
1796
+ buttonsContainerRef: HTMLDivElement;
1242
1797
  };
1243
1798
  rootEl: HTMLDivElement;
1244
1799
  };
@@ -1273,8 +1828,6 @@ declare type __VLS_TemplateResult_12 = ReturnType<typeof __VLS_template_12>;
1273
1828
 
1274
1829
  declare type __VLS_TemplateResult_13 = ReturnType<typeof __VLS_template_13>;
1275
1830
 
1276
- declare type __VLS_TemplateResult_14 = ReturnType<typeof __VLS_template_14>;
1277
-
1278
1831
  declare type __VLS_TemplateResult_2 = ReturnType<typeof __VLS_template_2>;
1279
1832
 
1280
1833
  declare type __VLS_TemplateResult_3 = ReturnType<typeof __VLS_template_3>;
@@ -1321,12 +1874,6 @@ declare type __VLS_WithTemplateSlots_13<T, S> = T & {
1321
1874
  };
1322
1875
  };
1323
1876
 
1324
- declare type __VLS_WithTemplateSlots_14<T, S> = T & {
1325
- new (): {
1326
- $slots: S;
1327
- };
1328
- };
1329
-
1330
1877
  declare type __VLS_WithTemplateSlots_2<T, S> = T & {
1331
1878
  new (): {
1332
1879
  $slots: S;
@@ -1375,42 +1922,28 @@ declare type __VLS_WithTemplateSlots_9<T, S> = T & {
1375
1922
  };
1376
1923
  };
1377
1924
 
1378
- declare interface ActionButton_2 {
1925
+ export declare interface ActionButton {
1379
1926
  type: string;
1380
1927
  label: string;
1381
1928
  handler?: (file: Attachment) => void;
1382
1929
  }
1383
1930
 
1384
- /**
1385
- * ActionButton Props
1386
- *
1387
- * 基础操作按钮的 Props
1388
- */
1389
- export declare interface ActionButtonProps {
1390
- /**
1391
- * 按钮图标
1392
- */
1393
- icon: VNode | Component;
1394
- /**
1395
- * 是否禁用
1396
- */
1931
+ export declare interface ActionButtonsProps {
1932
+ loading?: boolean;
1397
1933
  disabled?: boolean;
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;
1934
+ showClear?: boolean;
1935
+ hasContent?: boolean;
1936
+ buttonGroup?: ButtonGroupConfig;
1937
+ allowSpeech?: boolean;
1938
+ speechStatus?: {
1939
+ isRecording: boolean;
1940
+ isSupported: boolean;
1941
+ };
1942
+ allowFiles?: boolean;
1943
+ submitType?: SubmitTrigger;
1944
+ showShortcuts?: boolean;
1945
+ isOverLimit?: boolean;
1946
+ stopText?: string;
1414
1947
  }
1415
1948
 
1416
1949
  export declare type AddType = 'form' | 'code';
@@ -1424,7 +1957,7 @@ export declare interface AttachmentListEmits {
1424
1957
  (e: 'retry', file: Attachment): void;
1425
1958
  (e: 'preview', event: MouseEvent, file: Attachment): void;
1426
1959
  (e: 'action', payload: {
1427
- action: ActionButton_2;
1960
+ action: ActionButton;
1428
1961
  file: Attachment;
1429
1962
  }): void;
1430
1963
  }
@@ -1434,24 +1967,16 @@ export declare interface AttachmentListProps {
1434
1967
  disabled?: boolean;
1435
1968
  wrap?: boolean;
1436
1969
  fileIcons?: Record<string, Component>;
1437
- actions?: ActionButton_2[];
1970
+ actions?: ActionButton[];
1438
1971
  variant?: DisplayVariant;
1439
1972
  fileMatchers?: FileTypeMatcher[];
1440
1973
  }
1441
1974
 
1442
- /**
1443
- * 自动高度配置
1444
- */
1445
1975
  export declare type AutoSize = boolean | {
1446
1976
  minRows: number;
1447
1977
  maxRows: number;
1448
1978
  };
1449
1979
 
1450
- declare type AutoSize_2 = boolean | {
1451
- minRows: number;
1452
- maxRows: number;
1453
- };
1454
-
1455
1980
  export declare interface BaseAttachment {
1456
1981
  id?: string;
1457
1982
  name?: string;
@@ -1464,7 +1989,13 @@ declare type BaseCardProps = Pick<AttachmentListProps, 'fileIcons' | 'disabled'
1464
1989
 
1465
1990
  export declare type BaseFileType = 'image' | 'pdf' | 'word' | 'excel' | 'ppt' | 'folder' | 'other';
1466
1991
 
1467
- declare const Bubble: typeof _default_25 & {
1992
+ declare interface BaseTextItem {
1993
+ id: string;
1994
+ type: string;
1995
+ content: string;
1996
+ }
1997
+
1998
+ declare const Bubble: typeof _default_18 & {
1468
1999
  install: typeof bubbleInstall;
1469
2000
  };
1470
2001
  export { Bubble }
@@ -1524,7 +2055,7 @@ export declare type BubbleContentRenderer = BubbleContentFunctionRenderer | Bubb
1524
2055
 
1525
2056
  declare const bubbleInstall: (app: App) => void;
1526
2057
 
1527
- declare const BubbleList: typeof _default_26 & {
2058
+ declare const BubbleList: typeof _default_19 & {
1528
2059
  install: typeof bubbleListInstall;
1529
2060
  };
1530
2061
  export { BubbleList }
@@ -1584,7 +2115,7 @@ export declare interface BubbleProps extends BubbleCommonProps {
1584
2115
  aborted?: boolean;
1585
2116
  }
1586
2117
 
1587
- declare const BubbleProvider: typeof _default_27 & {
2118
+ declare const BubbleProvider: typeof _default_20 & {
1588
2119
  install: typeof bubbleProviderInstall;
1589
2120
  };
1590
2121
  export { BubbleProvider }
@@ -1616,205 +2147,12 @@ export declare interface BubbleSlots {
1616
2147
  }) => unknown;
1617
2148
  }
1618
2149
 
1619
- declare interface ButtonGroupConfig {
2150
+ export declare interface ButtonGroupConfig {
1620
2151
  file?: ControlState & fileUploadConfig;
1621
2152
  submit?: ControlState;
1622
2153
  voice?: VoiceButtonConfig;
1623
2154
  }
1624
2155
 
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
-
1818
2156
  export declare type ColorMode = 'light' | 'dark' | 'auto';
1819
2157
 
1820
2158
  export declare interface ContainerEmits {
@@ -1840,7 +2178,7 @@ export declare interface ContainerSlots {
1840
2178
  footer: () => unknown;
1841
2179
  }
1842
2180
 
1843
- declare interface ControlState {
2181
+ export declare interface ControlState {
1844
2182
  tooltips?: string | TooltipRender;
1845
2183
  disabled?: boolean;
1846
2184
  tooltipPlacement?: 'top' | 'top-start' | 'top-end' | 'bottom' | 'bottom-start' | 'bottom-end' | 'left' | 'left-start' | 'left-end' | 'right' | 'right-start' | 'right-end';
@@ -1851,103 +2189,56 @@ declare const _default: {
1851
2189
  };
1852
2190
  export default _default;
1853
2191
 
1854
- declare const _default_10: typeof _default_37 & {
2192
+ declare const _default_10: typeof _default_30 & {
1855
2193
  install: typeof install_9;
1856
2194
  };
1857
- export { _default_10 as SenderCompat }
1858
- export { _default_10 as TrSenderCompat }
2195
+ export { _default_10 as Sender }
2196
+ export { _default_10 as TrSender }
1859
2197
 
1860
- declare const _default_11: typeof _default_39 & {
2198
+ declare const _default_11: typeof _default_32 & {
1861
2199
  install: typeof install_10;
1862
2200
  };
1863
2201
  export { _default_11 as SuggestionPills }
1864
2202
  export { _default_11 as TrSuggestionPills }
1865
2203
 
1866
- declare const _default_12: typeof _default_40 & {
2204
+ declare const _default_12: typeof _default_33 & {
1867
2205
  install: typeof install_11;
1868
2206
  };
1869
2207
  export { _default_12 as SuggestionPopover }
1870
2208
  export { _default_12 as TrSuggestionPopover }
1871
2209
 
1872
- declare const _default_13: typeof _default_41 & {
2210
+ declare const _default_13: typeof _default_34 & {
1873
2211
  install: typeof install_12;
1874
2212
  };
1875
2213
  export { _default_13 as ThemeProvider }
1876
2214
  export { _default_13 as TrThemeProvider }
1877
2215
 
1878
- declare const _default_14: typeof _default_42 & {
2216
+ declare const _default_14: typeof _default_35 & {
1879
2217
  install: typeof install_13;
1880
2218
  };
1881
2219
  export { _default_14 as TrWelcome }
1882
2220
  export { _default_14 as Welcome }
1883
2221
 
1884
- declare const _default_15: typeof _default_43 & {
2222
+ declare const _default_15: typeof _default_36 & {
1885
2223
  install: typeof install_14;
1886
2224
  };
1887
2225
  export { _default_15 as McpServerPicker }
1888
2226
  export { _default_15 as TrMcpServerPicker }
1889
2227
 
1890
- declare const _default_16: typeof _default_44 & {
2228
+ declare const _default_16: typeof _default_37 & {
1891
2229
  install: typeof install_15;
1892
2230
  };
1893
2231
  export { _default_16 as McpAddForm }
1894
2232
  export { _default_16 as TrMcpAddForm }
1895
2233
 
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, {} & {
2234
+ declare const _default_17: DefineComponent<AttachmentListProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
1944
2235
  "update:items": (items: Attachment[]) => any;
1945
2236
  remove: (file: Attachment) => any;
1946
2237
  download: (event: MouseEvent, file: Attachment) => any;
1947
2238
  retry: (file: Attachment) => any;
1948
2239
  preview: (event: MouseEvent, file: Attachment) => any;
1949
2240
  action: (payload: {
1950
- action: ActionButton_2;
2241
+ action: ActionButton;
1951
2242
  file: Attachment;
1952
2243
  }) => any;
1953
2244
  }, string, PublicProps, Readonly<AttachmentListProps> & Readonly<{
@@ -1957,38 +2248,40 @@ onDownload?: ((event: MouseEvent, file: Attachment) => any) | undefined;
1957
2248
  onRetry?: ((file: Attachment) => any) | undefined;
1958
2249
  onPreview?: ((event: MouseEvent, file: Attachment) => any) | undefined;
1959
2250
  onAction?: ((payload: {
1960
- action: ActionButton_2;
2251
+ action: ActionButton;
1961
2252
  file: Attachment;
1962
2253
  }) => any) | undefined;
1963
2254
  }>, {
1964
- actions: ActionButton_2[];
2255
+ actions: ActionButton[];
1965
2256
  fileMatchers: FileTypeMatcher[];
1966
2257
  variant: DisplayVariant;
1967
2258
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
1968
2259
 
1969
- declare const _default_25: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
2260
+ declare const _default_18: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
1970
2261
 
1971
- declare const _default_26: DefineComponent<BubbleListProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<BubbleListProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {
2262
+ declare const _default_19: DefineComponent<BubbleListProps, {
2263
+ scrollToBottom: (behavior?: ScrollBehavior) => Promise<void>;
2264
+ }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<BubbleListProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {
1972
2265
  scrollContainerRef: HTMLDivElement;
1973
2266
  }, HTMLDivElement>;
1974
2267
 
1975
- declare const _default_27: __VLS_WithTemplateSlots_2<typeof __VLS_component_2, __VLS_TemplateResult_2["slots"]>;
2268
+ declare const _default_2: typeof _default_17 & {
2269
+ install: typeof install;
2270
+ };
2271
+ export { _default_2 as Attachments }
2272
+ export { _default_2 as TrAttachments }
1976
2273
 
1977
- declare const _default_28: __VLS_WithTemplateSlots_3<typeof __VLS_component_3, __VLS_TemplateResult_3["slots"]>;
2274
+ declare const _default_20: __VLS_WithTemplateSlots_2<typeof __VLS_component_2, __VLS_TemplateResult_2["slots"]>;
1978
2275
 
1979
- declare const _default_29: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
2276
+ declare const _default_21: __VLS_WithTemplateSlots_3<typeof __VLS_component_3, __VLS_TemplateResult_3["slots"]>;
1980
2277
 
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 }
2278
+ declare const _default_22: DefineComponent< {}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
1986
2279
 
1987
- declare const _default_30: __VLS_WithTemplateSlots_4<typeof __VLS_component_4, __VLS_TemplateResult_4["slots"]>;
2280
+ declare const _default_23: __VLS_WithTemplateSlots_4<typeof __VLS_component_4, __VLS_TemplateResult_4["slots"]>;
1988
2281
 
1989
- declare const _default_31: __VLS_WithTemplateSlots_5<typeof __VLS_component_5, __VLS_TemplateResult_5["slots"]>;
2282
+ declare const _default_24: __VLS_WithTemplateSlots_5<typeof __VLS_component_5, __VLS_TemplateResult_5["slots"]>;
1990
2283
 
1991
- declare const _default_32: DefineComponent<FeedbackProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
2284
+ declare const _default_25: DefineComponent<FeedbackProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
1992
2285
  action: (name: string) => any;
1993
2286
  operation: (name: string) => any;
1994
2287
  }, string, PublicProps, Readonly<FeedbackProps> & Readonly<{
@@ -2000,7 +2293,7 @@ actionsLimit: number;
2000
2293
  sourcesLinesLimit: number;
2001
2294
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
2002
2295
 
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<{
2296
+ declare const _default_26: <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<{
2004
2297
  props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
2005
2298
  readonly "onItem-click"?: ((item: T) => any) | undefined;
2006
2299
  readonly "onItem-title-change"?: ((newTitle: string, item: T) => any) | undefined;
@@ -2014,87 +2307,38 @@ declare const _default_33: <T extends HistoryItem>(__VLS_props: NonNullable<Awai
2014
2307
  __ctx?: Awaited<typeof __VLS_setup>;
2015
2308
  };
2016
2309
 
2017
- declare const _default_34: DefineComponent<IconButtonProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<IconButtonProps> & Readonly<{}>, {
2310
+ declare const _default_27: DefineComponent<IconButtonProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<IconButtonProps> & Readonly<{}>, {
2018
2311
  size: string | number;
2019
2312
  svgSize: string | number;
2020
2313
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLButtonElement>;
2021
2314
 
2022
- declare const _default_35: DefineComponent<PromptProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<PromptProps> & Readonly<{}>, {
2315
+ declare const _default_28: DefineComponent<PromptProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<PromptProps> & Readonly<{}>, {
2023
2316
  size: "small" | "medium" | "large";
2024
2317
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
2025
2318
 
2026
- declare const _default_36: __VLS_WithTemplateSlots_6<typeof __VLS_component_6, __VLS_TemplateResult_6["slots"]>;
2319
+ declare const _default_29: __VLS_WithTemplateSlots_6<typeof __VLS_component_6, __VLS_TemplateResult_6["slots"]>;
2027
2320
 
2028
- declare const _default_37: __VLS_WithTemplateSlots_7<typeof __VLS_component_7, __VLS_TemplateResult_7["slots"]>;
2321
+ declare const _default_3: typeof _default_21 & {
2322
+ install: typeof install_2;
2323
+ };
2324
+ export { _default_3 as Container }
2325
+ export { _default_3 as TrContainer }
2029
2326
 
2030
- declare const _default_38: __VLS_WithTemplateSlots_8<typeof __VLS_component_8, __VLS_TemplateResult_8["slots"]>;
2327
+ declare const _default_30: __VLS_WithTemplateSlots_7<typeof __VLS_component_7, __VLS_TemplateResult_7["slots"]>;
2031
2328
 
2032
- declare const _default_39: __VLS_WithTemplateSlots_9<typeof __VLS_component_9, __VLS_TemplateResult_9["slots"]>;
2329
+ declare const _default_31: __VLS_WithTemplateSlots_8<typeof __VLS_component_8, __VLS_TemplateResult_8["slots"]>;
2033
2330
 
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 }
2331
+ declare const _default_32: __VLS_WithTemplateSlots_9<typeof __VLS_component_9, __VLS_TemplateResult_9["slots"]>;
2039
2332
 
2040
- declare const _default_40: __VLS_WithTemplateSlots_10<typeof __VLS_component_10, __VLS_TemplateResult_10["slots"]>;
2333
+ declare const _default_33: __VLS_WithTemplateSlots_10<typeof __VLS_component_10, __VLS_TemplateResult_10["slots"]>;
2041
2334
 
2042
- declare const _default_41: __VLS_WithTemplateSlots_11<typeof __VLS_component_11, __VLS_TemplateResult_11["slots"]>;
2335
+ declare const _default_34: __VLS_WithTemplateSlots_11<typeof __VLS_component_11, __VLS_TemplateResult_11["slots"]>;
2043
2336
 
2044
- declare const _default_42: __VLS_WithTemplateSlots_12<typeof __VLS_component_12, __VLS_TemplateResult_12["slots"]>;
2337
+ declare const _default_35: __VLS_WithTemplateSlots_12<typeof __VLS_component_12, __VLS_TemplateResult_12["slots"]>;
2045
2338
 
2046
- declare const _default_43: DefineComponent<__VLS_PublicProps_6, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
2047
- "update:visible": (value: boolean) => any;
2048
- } & {
2049
- refresh: (tab: "installed" | "market") => any;
2050
- "update:visible": (visible: boolean) => any;
2051
- "market-category-change": (category: string) => any;
2052
- "tab-change": (activeTab: "installed" | "market") => any;
2053
- "plugin-toggle": (plugin: PluginInfo, enabled: boolean) => any;
2054
- "plugin-delete": (plugin: PluginInfo) => any;
2055
- "plugin-add": (plugin: PluginInfo) => any;
2056
- "plugin-create": (type: "code" | "form", data: PluginCreationData) => any;
2057
- "tool-toggle": (plugin: PluginInfo, toolId: string, enabled: boolean) => any;
2058
- "update:activeCount": (count: number) => any;
2059
- }, string, PublicProps, Readonly<__VLS_PublicProps_6> & Readonly<{
2060
- onRefresh?: ((tab: "installed" | "market") => any) | undefined;
2061
- "onUpdate:visible"?: ((value: boolean) => any) | undefined;
2062
- "onMarket-category-change"?: ((category: string) => any) | undefined;
2063
- "onTab-change"?: ((activeTab: "installed" | "market") => any) | undefined;
2064
- "onPlugin-toggle"?: ((plugin: PluginInfo, enabled: boolean) => any) | undefined;
2065
- "onPlugin-delete"?: ((plugin: PluginInfo) => any) | undefined;
2066
- "onPlugin-add"?: ((plugin: PluginInfo) => any) | undefined;
2067
- "onPlugin-create"?: ((type: "code" | "form", data: PluginCreationData) => any) | undefined;
2068
- "onTool-toggle"?: ((plugin: PluginInfo, toolId: string, enabled: boolean) => any) | undefined;
2069
- "onUpdate:activeCount"?: ((count: number) => any) | undefined;
2070
- }>, {
2071
- title: string;
2072
- loading: boolean;
2073
- installedPlugins: PluginInfo[];
2074
- marketPlugins: PluginInfo[];
2075
- searchPlaceholder: string;
2076
- enableSearch: boolean;
2077
- installedSearchFn: (query: string, item: PluginInfo) => boolean;
2078
- marketSearchFn: (query: string, item: PluginInfo) => boolean;
2079
- marketCategoryOptions: MarketCategoryOption[];
2080
- marketCategoryPlaceholder: string;
2081
- enableMarketCategoryFilter: boolean;
2082
- defaultActiveTab: "installed" | "market";
2083
- showInstalledTab: boolean;
2084
- showMarketTab: boolean;
2085
- popupConfig: PopupConfig;
2086
- installedTabTitle: string;
2087
- marketTabTitle: string;
2088
- showCustomAddButton: boolean;
2089
- customAddButtonText: string;
2090
- allowPluginToggle: boolean;
2091
- allowToolToggle: boolean;
2092
- allowPluginDelete: boolean;
2093
- allowPluginAdd: boolean;
2094
- marketLoading: boolean;
2095
- }, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
2339
+ declare const _default_36: __VLS_WithTemplateSlots_13<typeof __VLS_component_13, __VLS_TemplateResult_13["slots"]>;
2096
2340
 
2097
- declare const _default_44: DefineComponent<McpAddFormProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
2341
+ declare const _default_37: DefineComponent<McpAddFormProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
2098
2342
  cancel: () => any;
2099
2343
  confirm: (type: AddType, data: string | McpAddFormData) => any;
2100
2344
  "update:addType": (value: AddType) => any;
@@ -2106,90 +2350,42 @@ onConfirm?: ((type: AddType, data: string | McpAddFormData) => any) | undefined;
2106
2350
  addType: AddType;
2107
2351
  }, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
2108
2352
 
2109
- declare const _default_5: typeof _default_30 & {
2110
- install: typeof install_4;
2353
+ declare const _default_4: typeof _default_22 & {
2354
+ install: typeof install_3;
2355
+ };
2356
+ export { _default_4 as Conversations }
2357
+ export { _default_4 as TrConversations }
2358
+
2359
+ declare const _default_5: typeof _default_23 & {
2360
+ install: typeof install_4;
2111
2361
  };
2112
2362
  export { _default_5 as DragOverlay }
2113
2363
  export { _default_5 as TrDragOverlay }
2114
2364
 
2115
- declare const _default_6: typeof _default_31 & {
2365
+ declare const _default_6: typeof _default_24 & {
2116
2366
  install: typeof install_5;
2117
2367
  };
2118
2368
  export { _default_6 as DropdownMenu }
2119
2369
  export { _default_6 as TrDropdownMenu }
2120
2370
 
2121
- declare const _default_7: typeof _default_32 & {
2371
+ declare const _default_7: typeof _default_25 & {
2122
2372
  install: typeof install_6;
2123
2373
  };
2124
2374
  export { _default_7 as Feedback }
2125
2375
  export { _default_7 as TrFeedback }
2126
2376
 
2127
- declare const _default_8: typeof _default_33 & {
2377
+ declare const _default_8: typeof _default_26 & {
2128
2378
  install: typeof install_7;
2129
2379
  };
2130
2380
  export { _default_8 as History }
2131
2381
  export { _default_8 as TrHistory }
2132
2382
 
2133
- declare const _default_9: typeof _default_34 & {
2383
+ declare const _default_9: typeof _default_27 & {
2134
2384
  install: typeof install_8;
2135
2385
  };
2136
2386
  export { _default_9 as IconButton }
2137
2387
  export { _default_9 as TrIconButton }
2138
2388
 
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
-
2193
2389
  export declare type DisplayVariant = 'picture' | 'card' | 'auto';
2194
2390
 
2195
2391
  declare interface DragAwareElement extends HTMLElement {
@@ -2384,7 +2580,7 @@ export declare interface FileCardEmits {
2384
2580
  (e: 'download', event: MouseEvent, file: Attachment): void;
2385
2581
  (e: 'retry', file: Attachment): void;
2386
2582
  (e: 'action', payload: {
2387
- action: ActionButton_2;
2583
+ action: ActionButton;
2388
2584
  file: Attachment;
2389
2585
  }): void;
2390
2586
  }
@@ -2425,16 +2621,7 @@ export declare interface Handlers {
2425
2621
  handleDrop: (e: DragEvent) => void;
2426
2622
  }
2427
2623
 
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[];
2624
+ declare type HighlightFunction = (suggestionText: string, inputText: string) => SuggestionTextPart[];
2438
2625
 
2439
2626
  export declare type HistoryData<T extends HistoryItem> = T[] | HistoryGroup<T>[];
2440
2627
 
@@ -2481,14 +2668,13 @@ export declare interface IconButtonProps {
2481
2668
  rounded?: boolean;
2482
2669
  }
2483
2670
 
2484
- /**
2485
- * 输入模式
2486
- * - single: 单行模式,适用于简短输入
2487
- * - multiple: 多行模式,适用于长文本输入
2488
- */
2489
- export declare type InputMode = 'single' | 'multiple';
2671
+ export declare interface InputHandler {
2672
+ inputValue: Ref<string>;
2673
+ isComposing: Ref<boolean>;
2674
+ clearInput: () => void;
2675
+ }
2490
2676
 
2491
- declare type InputMode_2 = 'single' | 'multiple';
2677
+ export declare type InputMode = 'single' | 'multiple';
2492
2678
 
2493
2679
  declare const install: <T>(app: App<T>) => void;
2494
2680
 
@@ -2526,9 +2712,14 @@ declare const installPrompt: <T>(app: App<T>) => void;
2526
2712
 
2527
2713
  declare const installPrompts: <T>(app: App<T>) => void;
2528
2714
 
2529
- declare interface ISuggestionItem {
2715
+ export declare interface ISuggestionItem {
2530
2716
  content: string;
2531
- highlights?: string[] | HighlightFunction_2;
2717
+ highlights?: string[] | HighlightFunction;
2718
+ }
2719
+
2720
+ export declare interface KeyboardHandler {
2721
+ handleKeyPress: (e: KeyboardEvent) => void;
2722
+ triggerSubmit: () => void;
2532
2723
  }
2533
2724
 
2534
2725
  export declare interface MarketCategoryOption {
@@ -2599,106 +2790,6 @@ export declare interface McpServerPickerProps {
2599
2790
  marketLoading?: boolean;
2600
2791
  }
2601
2792
 
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
-
2702
2793
  export declare type PluginAddState = 'idle' | 'loading' | 'added';
2703
2794
 
2704
2795
  export declare interface PluginCardEmits {
@@ -2764,7 +2855,7 @@ export declare interface PopupConfig {
2764
2855
  };
2765
2856
  }
2766
2857
 
2767
- declare const Prompt: typeof _default_35 & {
2858
+ declare const Prompt: typeof _default_28 & {
2768
2859
  install: typeof installPrompt;
2769
2860
  };
2770
2861
  export { Prompt }
@@ -2801,7 +2892,7 @@ export declare interface PromptProps {
2801
2892
  size?: 'small' | 'medium' | 'large';
2802
2893
  }
2803
2894
 
2804
- declare const Prompts: typeof _default_36 & {
2895
+ declare const Prompts: typeof _default_29 & {
2805
2896
  install: typeof installPrompts;
2806
2897
  };
2807
2898
  export { Prompts }
@@ -2852,411 +2943,27 @@ export declare interface RejectionReason {
2852
2943
  message: string;
2853
2944
  }
2854
2945
 
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
- */
2946
+ export declare type SenderEmits = {
3025
2947
  (e: 'update:modelValue', value: string): void;
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
- */
2948
+ (e: 'update:templateData', value: UserItem[]): void;
2949
+ (e: 'submit', value: string): void;
2950
+ (e: 'clear'): void;
2951
+ (e: 'speech-start'): void;
2952
+ (e: 'speech-end', transcript?: string): void;
2953
+ (e: 'speech-interim', transcript: string): void;
2954
+ (e: 'speech-error', error: Error): void;
2955
+ (e: 'suggestion-select', value: string): void;
3057
2956
  (e: 'focus', event: FocusEvent): void;
3058
- /**
3059
- * 失焦事件
3060
- *
3061
- * @param e - 事件名
3062
- * @param event - 原生事件
3063
- */
3064
2957
  (e: 'blur', event: FocusEvent): void;
3065
- /**
3066
- * 清空事件
3067
- *
3068
- * @param e - 事件名
3069
- */
3070
- (e: 'clear'): void;
3071
- /**
3072
- * 取消事件
3073
- *
3074
- * 在 loading 状态下点击停止按钮时触发
3075
- * 用于取消正在进行的操作(如 AI 响应)
3076
- *
3077
- * @param e - 事件名
3078
- */
2958
+ (e: 'escape-press'): void;
3079
2959
  (e: 'cancel'): void;
3080
- /**
3081
- * 输入事件
3082
- *
3083
- * @param e - 事件名
3084
- * @param value - 当前内容
3085
- */
3086
- (e: 'input', value: string): void;
3087
- }
2960
+ (e: 'reset-template'): void;
2961
+ (e: 'files-selected', files: File[]): void;
2962
+ };
3088
2963
 
3089
- /**
3090
- * Chat-Input 组件 Props
3091
- */
3092
2964
  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
- */
3130
2965
  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
- */
3151
2966
  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;
3260
2967
  allowSpeech?: boolean;
3261
2968
  allowFiles?: boolean;
3262
2969
  clearable?: boolean;
@@ -3264,11 +2971,11 @@ declare interface SenderProps_2 {
3264
2971
  defaultValue?: string | null;
3265
2972
  loading?: boolean;
3266
2973
  modelValue?: string;
3267
- mode?: InputMode_2;
2974
+ mode?: InputMode;
3268
2975
  maxLength?: number;
3269
2976
  buttonGroup?: ButtonGroupConfig;
3270
- submitType?: SubmitTrigger_2;
3271
- speech?: boolean | SpeechConfig_2;
2977
+ submitType?: SubmitTrigger;
2978
+ speech?: boolean | SpeechConfig;
3272
2979
  placeholder?: string;
3273
2980
  showWordLimit?: boolean;
3274
2981
  suggestions?: ISuggestionItem[];
@@ -3279,105 +2986,6 @@ declare interface SenderProps_2 {
3279
2986
  stopText?: string;
3280
2987
  }
3281
2988
 
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
- */
3381
2989
  export declare interface SpeechCallbacks {
3382
2990
  onStart: () => void;
3383
2991
  onInterim: (transcript: string) => void;
@@ -3386,14 +2994,6 @@ export declare interface SpeechCallbacks {
3386
2994
  onError: (error: Error) => void;
3387
2995
  }
3388
2996
 
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
-
3397
2997
  export declare interface SpeechConfig {
3398
2998
  customHandler?: SpeechHandler;
3399
2999
  lang?: string;
@@ -3403,27 +3003,12 @@ export declare interface SpeechConfig {
3403
3003
  onVoiceButtonClick?: (isRecording: boolean, preventDefault: () => void) => void | Promise<void>;
3404
3004
  }
3405
3005
 
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
-
3415
3006
  export declare interface SpeechHandler {
3416
3007
  start: (callbacks: SpeechCallbacks) => Promise<void> | void;
3417
3008
  stop: () => Promise<void> | void;
3418
3009
  isSupported: () => boolean;
3419
3010
  }
3420
3011
 
3421
- declare interface SpeechHandler_2 {
3422
- start: (callbacks: SpeechCallbacks_2) => Promise<void> | void;
3423
- stop: () => Promise<void> | void;
3424
- isSupported: () => boolean;
3425
- }
3426
-
3427
3012
  export declare interface SpeechHandlerResult {
3428
3013
  speechState: SpeechState;
3429
3014
  start: () => void;
@@ -3444,85 +3029,8 @@ export declare interface SpeechState {
3444
3029
  error?: Error;
3445
3030
  }
3446
3031
 
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
- */
3508
3032
  export declare type SubmitTrigger = 'enter' | 'ctrlEnter' | 'shiftEnter';
3509
3033
 
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
-
3526
3034
  export declare interface SuggestionBaseItem {
3527
3035
  id: string;
3528
3036
  text: string;
@@ -3539,121 +3047,7 @@ export declare interface SuggestionGroup<T = Record<string, unknown>> {
3539
3047
 
3540
3048
  export declare type SuggestionItem<T = Record<string, unknown>> = SuggestionBaseItem & T;
3541
3049
 
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 & {
3050
+ declare const SuggestionPillButton: typeof _default_31 & {
3657
3051
  install: typeof installPillButton;
3658
3052
  };
3659
3053
  export { SuggestionPillButton }
@@ -3781,232 +3175,19 @@ export declare interface SuggestionPopoverSlots {
3781
3175
  body?: () => VNode | VNode[];
3782
3176
  }
3783
3177
 
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
- */
3841
3178
  export declare interface SuggestionTextPart {
3842
3179
  text: string;
3843
3180
  isMatch: boolean;
3844
3181
  }
3845
3182
 
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;
3183
+ declare interface TemplateItem extends BaseTextItem {
3184
+ type: 'template';
3185
+ prefix: string;
3186
+ suffix: string;
3877
3187
  }
3878
3188
 
3879
- /**
3880
- * 模板项(用户侧)
3881
- *
3882
- * 用户传入的模板数据格式
3883
- * 组件内部会转换为 Tiptap 节点格式
3884
- */
3885
- export declare type TemplateItem = {
3886
- /**
3887
- * 模板 ID,可选
3888
- * 如果不提供,组件会自动生成
3889
- */
3890
- id?: string;
3891
- /**
3892
- * 类型:普通文本
3893
- */
3189
+ declare interface TextItem extends BaseTextItem {
3894
3190
  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;
4004
- }
4005
-
4006
- declare interface TextItem {
4007
- id: string;
4008
- type: 'text';
4009
- content: string;
4010
3191
  }
4011
3192
 
4012
3193
  export declare interface ThemeProviderProps {
@@ -4028,14 +3209,10 @@ export declare interface ThemeProviderProps {
4028
3209
 
4029
3210
  export declare type ThemeStorage = Pick<Storage, 'getItem' | 'setItem'>;
4030
3211
 
4031
- declare type ThemeType = 'light' | 'dark';
4032
-
4033
3212
  /**
4034
- * Tooltip 内容类型
4035
- * - string: 简单文本
4036
- * - () => string | VNode: 渲染函数,支持复杂内容
3213
+ * 组件核心类型定义
4037
3214
  */
4038
- export declare type TooltipContent = string | (() => string | VNode);
3215
+ export declare type ThemeType = 'light' | 'dark';
4039
3216
 
4040
3217
  declare interface TooltipContentProps {
4041
3218
  show?: boolean;
@@ -4047,71 +3224,7 @@ declare interface TooltipContentProps {
4047
3224
  delayClose?: number;
4048
3225
  }
4049
3226
 
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
- }
3227
+ export declare type TooltipRender = () => VNode | string;
4115
3228
 
4116
3229
  export declare interface UrlAttachment extends BaseAttachment {
4117
3230
  url: string;
@@ -4119,31 +3232,33 @@ export declare interface UrlAttachment extends BaseAttachment {
4119
3232
  rawFile?: File;
4120
3233
  }
4121
3234
 
4122
- declare type UserItem = UserTextItem | UserTemplateItem;
3235
+ /**
3236
+ * 当目标滚动容器 `target` 接近底部时,且源数据 `source` 变化,自动滚动到底部
3237
+ * @param target 目标滚动容器的元素引用
3238
+ * @param source 监听的源数据,当该数据变化时会触发自动滚动
3239
+ * @param options 配置选项
3240
+ * @param options.scrollOnMount 是否在组件挂载时滚动到底部,默认为 true
3241
+ * @param options.bottomThreshold 判断接近底部的阈值(像素),默认为 20
3242
+ * @returns scrollToBottom 手动滚动到底部的方法
3243
+ */
3244
+ export declare function useAutoScroll(target: MaybeComputedElementRef, source: MaybeRefOrGetter<any>, options?: {
3245
+ scrollOnMount?: boolean;
3246
+ scrollThrottle?: number;
3247
+ bottomThreshold?: number;
3248
+ }): {
3249
+ scrollToBottom: (behavior?: ScrollBehavior) => Promise<void>;
3250
+ };
3251
+
3252
+ export declare type UserItem = UserTextItem | UserTemplateItem;
4123
3253
 
4124
- declare type UserTemplateItem = Omit<Pick<TemplateItem_2, 'type' | 'content'>, 'id'> & {
4125
- id?: TemplateItem_2['id'];
3254
+ export declare type UserTemplateItem = Omit<Pick<TemplateItem, 'type' | 'content'>, 'id'> & {
3255
+ id?: TemplateItem['id'];
4126
3256
  };
4127
3257
 
4128
- declare type UserTextItem = Omit<TextItem, 'id'> & {
3258
+ export declare type UserTextItem = Omit<TextItem, 'id'> & {
4129
3259
  id?: TextItem['id'];
4130
3260
  };
4131
3261
 
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
-
4147
3262
  export declare const useTheme: () => {
4148
3263
  theme: Ref<string, string> | undefined;
4149
3264
  colorMode: Ref<ColorMode, ColorMode> | undefined;
@@ -4169,96 +3284,6 @@ declare interface VoiceButtonConfig {
4169
3284
  icon?: VNode | Component;
4170
3285
  }
4171
3286
 
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
-
4262
3287
  export declare interface WelcomeProps {
4263
3288
  title: string;
4264
3289
  description: string;
@@ -4271,53 +3296,3 @@ export declare interface WelcomeSlots {
4271
3296
  }
4272
3297
 
4273
3298
  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
- }