@matechat/ng 20.2.0 → 20.2.1-alpha.2
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/fesm2022/matechat-ng.mjs +2653 -141
- package/fesm2022/matechat-ng.mjs.map +1 -1
- package/index.d.ts +701 -43
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -1,11 +1,129 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { TemplateRef,
|
|
2
|
+
import { EventEmitter, TemplateRef, ElementRef, AfterViewInit, OnDestroy, SimpleChanges, QueryList, OnInit, OnChanges, ModuleWithProviders, PipeTransform, ChangeDetectorRef, ViewContainerRef, Renderer2, AfterContentInit } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/common';
|
|
4
4
|
import * as rxjs from 'rxjs';
|
|
5
5
|
import * as i2 from '@angular/forms';
|
|
6
|
-
import
|
|
6
|
+
import { ControlValueAccessor } from '@angular/forms';
|
|
7
|
+
import markdownit, { PluginSimple, PluginWithOptions, PluginWithParams, Token, Options } from 'markdown-it';
|
|
7
8
|
import { IWhiteList } from 'xss';
|
|
8
9
|
|
|
10
|
+
interface UploadOptions {
|
|
11
|
+
uri: string | URL;
|
|
12
|
+
method?: 'POST' | 'PUT' | 'PATCH';
|
|
13
|
+
headers?: {
|
|
14
|
+
[key: string]: string;
|
|
15
|
+
};
|
|
16
|
+
authToken?: string;
|
|
17
|
+
authTokenHeader?: string;
|
|
18
|
+
additionalParameter?: {
|
|
19
|
+
[key: string]: string | Blob;
|
|
20
|
+
};
|
|
21
|
+
fileFieldName?: string;
|
|
22
|
+
withCredentials?: boolean;
|
|
23
|
+
responseType?: 'arraybuffer' | 'blob' | 'json' | 'text';
|
|
24
|
+
}
|
|
25
|
+
type FileStatus = 'uploading' | 'downloading' | 'success' | 'uploadError' | 'downloadError';
|
|
26
|
+
interface FileItem<T = unknown, E = unknown> {
|
|
27
|
+
uid: number;
|
|
28
|
+
name: string;
|
|
29
|
+
size: number;
|
|
30
|
+
type?: string;
|
|
31
|
+
status?: FileStatus;
|
|
32
|
+
percentage?: number;
|
|
33
|
+
id?: string | number;
|
|
34
|
+
response?: T;
|
|
35
|
+
error?: E;
|
|
36
|
+
thumbUrl?: string;
|
|
37
|
+
url?: string;
|
|
38
|
+
}
|
|
39
|
+
type BeforeUpload = (file: File) => boolean | Promise<boolean>;
|
|
40
|
+
type ValidResultType = 'exceedCount' | 'unsupportedFileType' | 'exceedSizeLimit' | 'beforeUploadRejected';
|
|
41
|
+
interface IValidResult {
|
|
42
|
+
type: ValidResultType;
|
|
43
|
+
file?: File;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
interface ChangeEventArg {
|
|
47
|
+
file: File;
|
|
48
|
+
fileList: FileItem[];
|
|
49
|
+
}
|
|
50
|
+
interface SuccessEventArg {
|
|
51
|
+
file: File;
|
|
52
|
+
response: FileItem['response'];
|
|
53
|
+
fileList: FileItem[];
|
|
54
|
+
}
|
|
55
|
+
interface ErrorEventArg {
|
|
56
|
+
file: File;
|
|
57
|
+
error: FileItem['error'];
|
|
58
|
+
fileList: FileItem[];
|
|
59
|
+
}
|
|
60
|
+
interface ProgressEventArg {
|
|
61
|
+
file: File;
|
|
62
|
+
fileList: FileItem[];
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
declare class AttachmentComponent {
|
|
66
|
+
uploadOptions: UploadOptions;
|
|
67
|
+
disabled: boolean;
|
|
68
|
+
accept: string;
|
|
69
|
+
dropPlaceholder: string | undefined;
|
|
70
|
+
maxCount: number;
|
|
71
|
+
maxSize: number;
|
|
72
|
+
multiple: boolean;
|
|
73
|
+
draggable: boolean;
|
|
74
|
+
beforeUpload: BeforeUpload;
|
|
75
|
+
getDropContainer: () => HTMLElement;
|
|
76
|
+
change: EventEmitter<ChangeEventArg>;
|
|
77
|
+
success: EventEmitter<SuccessEventArg>;
|
|
78
|
+
error: EventEmitter<ErrorEventArg>;
|
|
79
|
+
progress: EventEmitter<ProgressEventArg>;
|
|
80
|
+
drop: EventEmitter<File[]>;
|
|
81
|
+
validChange: EventEmitter<IValidResult[]>;
|
|
82
|
+
dropPlaceholderTemplate: TemplateRef<any> | null;
|
|
83
|
+
inputEl: ElementRef<HTMLInputElement>;
|
|
84
|
+
fileList: FileItem[];
|
|
85
|
+
uid: number;
|
|
86
|
+
get isDisabled(): boolean;
|
|
87
|
+
onDrop(e: File[]): void;
|
|
88
|
+
getFileItem: (file: File) => FileItem;
|
|
89
|
+
uploadFiles: (files: File[]) => Promise<void>;
|
|
90
|
+
performUpload: (file: File, fileItem: FileItem) => void;
|
|
91
|
+
handleFileChange: (e: Event) => void;
|
|
92
|
+
handleClick(): void;
|
|
93
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AttachmentComponent, never>;
|
|
94
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AttachmentComponent, "mc-attachment", never, { "uploadOptions": { "alias": "uploadOptions"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "accept": { "alias": "accept"; "required": false; }; "dropPlaceholder": { "alias": "dropPlaceholder"; "required": false; }; "maxCount": { "alias": "maxCount"; "required": false; }; "maxSize": { "alias": "maxSize"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "draggable": { "alias": "draggable"; "required": false; }; "beforeUpload": { "alias": "beforeUpload"; "required": false; }; "getDropContainer": { "alias": "getDropContainer"; "required": false; }; }, { "change": "change"; "success": "success"; "error": "error"; "progress": "progress"; "drop": "drop"; "validChange": "validChange"; }, ["dropPlaceholderTemplate"], ["*"], true, never>;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
declare class DropAreaComponent implements AfterViewInit, OnDestroy {
|
|
98
|
+
getDropContainer: () => HTMLElement;
|
|
99
|
+
isDisabled: boolean;
|
|
100
|
+
drop: EventEmitter<File[]>;
|
|
101
|
+
dropAreaEl: ElementRef<HTMLDivElement>;
|
|
102
|
+
container: HTMLElement;
|
|
103
|
+
isDragging: boolean;
|
|
104
|
+
dragCounter: number;
|
|
105
|
+
get dropAreaClasses(): {
|
|
106
|
+
'mc-attachment-drop-area': boolean;
|
|
107
|
+
'hide-drop-area': boolean;
|
|
108
|
+
};
|
|
109
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
110
|
+
handleDragEnter: (e: DragEvent) => void;
|
|
111
|
+
handleDragOver: (e: DragEvent) => void;
|
|
112
|
+
handleDragLeave: (e: DragEvent) => void;
|
|
113
|
+
handleDrop: (e: DragEvent) => void;
|
|
114
|
+
onBodyDrop: (e: DragEvent) => void;
|
|
115
|
+
ngAfterViewInit(): void;
|
|
116
|
+
ngOnDestroy(): void;
|
|
117
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DropAreaComponent, never>;
|
|
118
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<DropAreaComponent, "mc-drop-area", never, { "getDropContainer": { "alias": "getDropContainer"; "required": false; }; "isDisabled": { "alias": "isDisabled"; "required": false; }; }, { "drop": "drop"; }, never, ["*"], true, never>;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
declare class AttachmentModule {
|
|
122
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AttachmentModule, never>;
|
|
123
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AttachmentModule, never, [typeof i1.CommonModule, typeof DropAreaComponent, typeof AttachmentComponent], [typeof AttachmentComponent]>;
|
|
124
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<AttachmentModule>;
|
|
125
|
+
}
|
|
126
|
+
|
|
9
127
|
type BubbleVariant = 'filled' | 'none' | 'bordered';
|
|
10
128
|
type AvatarPosition = 'top' | 'side';
|
|
11
129
|
type BubbleAlign = 'left' | 'right';
|
|
@@ -150,6 +268,22 @@ declare class AvatarNoBodyIconComponent {
|
|
|
150
268
|
static ɵcmp: i0.ɵɵComponentDeclaration<AvatarNoBodyIconComponent, "mc-avatar-no-body-icon", never, { "width": { "alias": "width"; "required": false; }; "height": { "alias": "height"; "required": false; }; }, {}, never, never, true, never>;
|
|
151
269
|
}
|
|
152
270
|
|
|
271
|
+
declare class HeaderComponent {
|
|
272
|
+
logoImg: string;
|
|
273
|
+
title: string;
|
|
274
|
+
logoClickable: boolean;
|
|
275
|
+
logoClicked: EventEmitter<void>;
|
|
276
|
+
onLogoClicked(): void;
|
|
277
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<HeaderComponent, never>;
|
|
278
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<HeaderComponent, "mc-header", never, { "logoImg": { "alias": "logoImg"; "required": false; }; "title": { "alias": "title"; "required": false; }; "logoClickable": { "alias": "logoClickable"; "required": false; }; }, { "logoClicked": "logoClicked"; }, never, ["[operationArea]"], true, never>;
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
declare class HeaderModule {
|
|
282
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<HeaderModule, never>;
|
|
283
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<HeaderModule, never, [typeof i1.CommonModule, typeof HeaderComponent], [typeof HeaderComponent]>;
|
|
284
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<HeaderModule>;
|
|
285
|
+
}
|
|
286
|
+
|
|
153
287
|
declare enum DisplayType {
|
|
154
288
|
Simple = "simple",
|
|
155
289
|
Full = "full"
|
|
@@ -166,6 +300,28 @@ declare enum SubmitShortKey {
|
|
|
166
300
|
Enter = "enter",
|
|
167
301
|
ShiftEnter = "shiftEnter"
|
|
168
302
|
}
|
|
303
|
+
interface ThemeTagItem {
|
|
304
|
+
type: 'themeTag';
|
|
305
|
+
themeTagKey?: string;
|
|
306
|
+
themeTagText: string;
|
|
307
|
+
clearInput?: boolean;
|
|
308
|
+
popoverContent: string;
|
|
309
|
+
}
|
|
310
|
+
interface FormatTextItem {
|
|
311
|
+
type: 'text';
|
|
312
|
+
key: string;
|
|
313
|
+
content: string;
|
|
314
|
+
}
|
|
315
|
+
interface FormatInputItem {
|
|
316
|
+
type: 'input';
|
|
317
|
+
key: string;
|
|
318
|
+
placeholder?: string;
|
|
319
|
+
content?: string;
|
|
320
|
+
}
|
|
321
|
+
type FormatContentItem = FormatTextItem | FormatInputItem | ThemeTagItem;
|
|
322
|
+
interface FormatContentOptions {
|
|
323
|
+
formatContent: FormatContentItem[];
|
|
324
|
+
}
|
|
169
325
|
|
|
170
326
|
interface InputAdapter extends DefaultAdapter {
|
|
171
327
|
locale(key: string, params?: Record<string, string>): string;
|
|
@@ -237,6 +393,96 @@ declare class LocaleService {
|
|
|
237
393
|
static ɵprov: i0.ɵɵInjectableDeclaration<LocaleService>;
|
|
238
394
|
}
|
|
239
395
|
|
|
396
|
+
declare class LocaleModule {
|
|
397
|
+
/**
|
|
398
|
+
* 静态方法,用于配置模块并提供服务
|
|
399
|
+
* 可以在AppModule中使用LocaleModule.forRoot()来初始化
|
|
400
|
+
*/
|
|
401
|
+
static forRoot(): ModuleWithProviders<LocaleModule>;
|
|
402
|
+
/**
|
|
403
|
+
* 普通导入方法,用于特性模块中导入
|
|
404
|
+
* 避免服务被多次实例化
|
|
405
|
+
*/
|
|
406
|
+
static forChild(): ModuleWithProviders<LocaleModule>;
|
|
407
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LocaleModule, never>;
|
|
408
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<LocaleModule, never, never, never>;
|
|
409
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<LocaleModule>;
|
|
410
|
+
}
|
|
411
|
+
|
|
412
|
+
/**
|
|
413
|
+
* 翻译管道,用于在Angular模板中直接使用翻译功能
|
|
414
|
+
* 用法:{{ 'Input.send' | translate }}
|
|
415
|
+
* 带参数:{{ 'Input.pleaseEnterPlaceholder' | translate:{ enterKey: 'Enter', shiftEnterKey: 'Shift + Enter' } }}
|
|
416
|
+
*/
|
|
417
|
+
declare class TranslatePipe implements PipeTransform {
|
|
418
|
+
private localeService;
|
|
419
|
+
constructor(localeService: LocaleService);
|
|
420
|
+
/**
|
|
421
|
+
* 转换方法,实现PipeTransform接口
|
|
422
|
+
* @param key 翻译键
|
|
423
|
+
* @param params 替换参数
|
|
424
|
+
*/
|
|
425
|
+
transform(key: string, params?: {
|
|
426
|
+
[key: string]: string | number;
|
|
427
|
+
}): string;
|
|
428
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TranslatePipe, never>;
|
|
429
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<TranslatePipe, "translate", true>;
|
|
430
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<TranslatePipe>;
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
interface InputTagAdapter extends DefaultAdapter {
|
|
434
|
+
}
|
|
435
|
+
declare class InputTagFoundation extends BaseFoundation<InputTagAdapter> {
|
|
436
|
+
constructor(adapter: InputTagAdapter);
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
declare class EditableBlockComponent extends BaseComponent<InputTagFoundation> {
|
|
440
|
+
private localeService;
|
|
441
|
+
themeTag: ThemeTagItem;
|
|
442
|
+
disabled: boolean;
|
|
443
|
+
displayType: DisplayType;
|
|
444
|
+
placeholder: string;
|
|
445
|
+
templateParts: any[];
|
|
446
|
+
maxLength: number | null;
|
|
447
|
+
submitShortKey: SubmitShortKey | null | string;
|
|
448
|
+
autofocus: boolean;
|
|
449
|
+
send: EventEmitter<string>;
|
|
450
|
+
input: EventEmitter<string>;
|
|
451
|
+
blur: EventEmitter<FocusEvent>;
|
|
452
|
+
focus: EventEmitter<FocusEvent>;
|
|
453
|
+
onBlockKeyArrowUp: EventEmitter<KeyboardEvent>;
|
|
454
|
+
editableDivRef: ElementRef<HTMLDivElement>;
|
|
455
|
+
themeTagTemplate: TemplateRef<any> | null;
|
|
456
|
+
localTemplateParts: any;
|
|
457
|
+
constructor(localeService: LocaleService);
|
|
458
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
459
|
+
ngOnInit(): void;
|
|
460
|
+
clearInput(): void;
|
|
461
|
+
getInput(): any;
|
|
462
|
+
handleSend(): void;
|
|
463
|
+
focusInput(): void;
|
|
464
|
+
onFocus($event: FocusEvent): void;
|
|
465
|
+
onBlur($event: FocusEvent): void;
|
|
466
|
+
isComposing: boolean;
|
|
467
|
+
handleCompositionEnd($event: CompositionEvent): void;
|
|
468
|
+
handleCompositionStart($event: CompositionEvent): void;
|
|
469
|
+
handleDivPaste(e: any): void;
|
|
470
|
+
handleDivKeydown(e: KeyboardEvent): void;
|
|
471
|
+
isCursorAtStart(): boolean;
|
|
472
|
+
findSiblingNode(node: any, startOffset: number, direction: 'previous' | 'next'): null;
|
|
473
|
+
handleDivInput(): void;
|
|
474
|
+
getCurrentInputValue(): any;
|
|
475
|
+
processInput(): void;
|
|
476
|
+
setInputTag(key: string, placeholder: string, defaultValue?: string): void;
|
|
477
|
+
setMixTags(mixTagConfig: FormatContentItem[]): void;
|
|
478
|
+
setText(text: string): void;
|
|
479
|
+
openTipTag(themeTagText: string, popoverContent: string, clearInput?: boolean): void;
|
|
480
|
+
closeTipTag(): void;
|
|
481
|
+
onFocusInput(): void;
|
|
482
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<EditableBlockComponent, never>;
|
|
483
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<EditableBlockComponent, "mc-editable-block", never, { "disabled": { "alias": "disabled"; "required": false; }; "displayType": { "alias": "displayType"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "templateParts": { "alias": "templateParts"; "required": false; }; "maxLength": { "alias": "maxLength"; "required": false; }; "submitShortKey": { "alias": "submitShortKey"; "required": false; }; "autofocus": { "alias": "autofocus"; "required": false; }; }, { "send": "send"; "input": "input"; "blur": "blur"; "focus": "focus"; "onBlockKeyArrowUp": "onBlockKeyArrowUp"; }, ["themeTagTemplate"], never, true, never>;
|
|
484
|
+
}
|
|
485
|
+
|
|
240
486
|
type TextareaAutoSize = {
|
|
241
487
|
minRows?: number;
|
|
242
488
|
maxRows?: number;
|
|
@@ -256,6 +502,7 @@ declare class InputComponent extends BaseComponent<InputFoundation> implements O
|
|
|
256
502
|
submitShortKey: SubmitShortKey | null | string;
|
|
257
503
|
autofocus: boolean;
|
|
258
504
|
autosize: TextareaAutoSize;
|
|
505
|
+
formatContentOptions: FormatContentOptions;
|
|
259
506
|
textareaStyle: Record<string, string>;
|
|
260
507
|
change: EventEmitter<string>;
|
|
261
508
|
submit: EventEmitter<string>;
|
|
@@ -263,13 +510,16 @@ declare class InputComponent extends BaseComponent<InputFoundation> implements O
|
|
|
263
510
|
focus: EventEmitter<FocusEvent>;
|
|
264
511
|
blur: EventEmitter<FocusEvent>;
|
|
265
512
|
textareaElement: ElementRef<HTMLTextAreaElement>;
|
|
513
|
+
editableBlockRef: EditableBlockComponent;
|
|
266
514
|
headTemplate: TemplateRef<any> | null;
|
|
267
515
|
prefixTemplate: TemplateRef<any> | null;
|
|
268
516
|
suffixTemplate: TemplateRef<any> | null;
|
|
269
517
|
buttonTemplate: TemplateRef<any> | null;
|
|
270
518
|
extraTemplate: TemplateRef<any> | null;
|
|
519
|
+
themeTagTemplate: TemplateRef<any> | null;
|
|
271
520
|
inputValue: string;
|
|
272
521
|
lock: boolean;
|
|
522
|
+
showEditableBlock: boolean;
|
|
273
523
|
constructor(localeService: LocaleService);
|
|
274
524
|
ngOnInit(): void;
|
|
275
525
|
get adapter(): InputAdapter;
|
|
@@ -283,6 +533,13 @@ declare class InputComponent extends BaseComponent<InputFoundation> implements O
|
|
|
283
533
|
onKeydown(event: KeyboardEvent): void;
|
|
284
534
|
clearInput(): void;
|
|
285
535
|
getInput(): string;
|
|
536
|
+
setMixTags(mixTagConfig: FormatContentItem[]): void;
|
|
537
|
+
openTipTag(themeTagText: string, popoverContent: string, clearInput?: boolean): void;
|
|
538
|
+
closeTipTag(): void;
|
|
539
|
+
handleDivInput(value: string): void;
|
|
540
|
+
handleDivSubmit(value: string): void;
|
|
541
|
+
onDivBlur(e: FocusEvent): void;
|
|
542
|
+
onDivFocus(e: FocusEvent): void;
|
|
286
543
|
onButtonSubmit(value: string): void;
|
|
287
544
|
onButtonCancel(): void;
|
|
288
545
|
onButtonChange(value: string): void;
|
|
@@ -294,44 +551,7 @@ declare class InputComponent extends BaseComponent<InputFoundation> implements O
|
|
|
294
551
|
onFocus(event: FocusEvent): void;
|
|
295
552
|
onBlur(event: FocusEvent): void;
|
|
296
553
|
static ɵfac: i0.ɵɵFactoryDeclaration<InputComponent, never>;
|
|
297
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<InputComponent, "mc-input", never, { "value": { "alias": "value"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "displayType": { "alias": "displayType"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "sendBtnVariant": { "alias": "sendBtnVariant"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "showCount": { "alias": "showCount"; "required": false; }; "maxLength": { "alias": "maxLength"; "required": false; }; "submitShortKey": { "alias": "submitShortKey"; "required": false; }; "autofocus": { "alias": "autofocus"; "required": false; }; "autosize": { "alias": "autosize"; "required": false; }; }, { "change": "change"; "submit": "submit"; "cancel": "cancel"; "focus": "focus"; "blur": "blur"; }, ["headTemplate", "prefixTemplate", "suffixTemplate", "buttonTemplate", "extraTemplate"], never, true, never>;
|
|
298
|
-
}
|
|
299
|
-
|
|
300
|
-
declare class LocaleModule {
|
|
301
|
-
/**
|
|
302
|
-
* 静态方法,用于配置模块并提供服务
|
|
303
|
-
* 可以在AppModule中使用LocaleModule.forRoot()来初始化
|
|
304
|
-
*/
|
|
305
|
-
static forRoot(): ModuleWithProviders<LocaleModule>;
|
|
306
|
-
/**
|
|
307
|
-
* 普通导入方法,用于特性模块中导入
|
|
308
|
-
* 避免服务被多次实例化
|
|
309
|
-
*/
|
|
310
|
-
static forChild(): ModuleWithProviders<LocaleModule>;
|
|
311
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<LocaleModule, never>;
|
|
312
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<LocaleModule, never, never, never>;
|
|
313
|
-
static ɵinj: i0.ɵɵInjectorDeclaration<LocaleModule>;
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
/**
|
|
317
|
-
* 翻译管道,用于在Angular模板中直接使用翻译功能
|
|
318
|
-
* 用法:{{ 'Input.send' | translate }}
|
|
319
|
-
* 带参数:{{ 'Input.pleaseEnterPlaceholder' | translate:{ enterKey: 'Enter', shiftEnterKey: 'Shift + Enter' } }}
|
|
320
|
-
*/
|
|
321
|
-
declare class TranslatePipe implements PipeTransform {
|
|
322
|
-
private localeService;
|
|
323
|
-
constructor(localeService: LocaleService);
|
|
324
|
-
/**
|
|
325
|
-
* 转换方法,实现PipeTransform接口
|
|
326
|
-
* @param key 翻译键
|
|
327
|
-
* @param params 替换参数
|
|
328
|
-
*/
|
|
329
|
-
transform(key: string, params?: {
|
|
330
|
-
[key: string]: string | number;
|
|
331
|
-
}): string;
|
|
332
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<TranslatePipe, never>;
|
|
333
|
-
static ɵpipe: i0.ɵɵPipeDeclaration<TranslatePipe, "translate", true>;
|
|
334
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<TranslatePipe>;
|
|
554
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<InputComponent, "mc-input", never, { "value": { "alias": "value"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "displayType": { "alias": "displayType"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "sendBtnVariant": { "alias": "sendBtnVariant"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "showCount": { "alias": "showCount"; "required": false; }; "maxLength": { "alias": "maxLength"; "required": false; }; "submitShortKey": { "alias": "submitShortKey"; "required": false; }; "autofocus": { "alias": "autofocus"; "required": false; }; "autosize": { "alias": "autosize"; "required": false; }; "formatContentOptions": { "alias": "formatContentOptions"; "required": false; }; }, { "change": "change"; "submit": "submit"; "cancel": "cancel"; "focus": "focus"; "blur": "blur"; }, ["headTemplate", "prefixTemplate", "suffixTemplate", "buttonTemplate", "extraTemplate", "themeTagTemplate"], never, true, never>;
|
|
335
555
|
}
|
|
336
556
|
|
|
337
557
|
interface InputButtonAdapter extends DefaultAdapter {
|
|
@@ -381,12 +601,127 @@ declare class SendIconComponent {
|
|
|
381
601
|
static ɵcmp: i0.ɵɵComponentDeclaration<SendIconComponent, "mc-send-icon", never, {}, {}, never, never, true, never>;
|
|
382
602
|
}
|
|
383
603
|
|
|
604
|
+
declare class InputTagComponent extends BaseComponent<InputTagFoundation> {
|
|
605
|
+
private localeService;
|
|
606
|
+
disabled: boolean;
|
|
607
|
+
content: string;
|
|
608
|
+
placeholder: string;
|
|
609
|
+
change: EventEmitter<string>;
|
|
610
|
+
editableSpanRef: ElementRef<HTMLSpanElement>;
|
|
611
|
+
isEditable: boolean;
|
|
612
|
+
localValue: string;
|
|
613
|
+
constructor(localeService: LocaleService);
|
|
614
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
615
|
+
handleFocus(): void;
|
|
616
|
+
handleBlur(): void;
|
|
617
|
+
handleInput(e: any): void;
|
|
618
|
+
handleInputPaste(e: any): void;
|
|
619
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<InputTagComponent, never>;
|
|
620
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<InputTagComponent, "mc-input-tag", never, { "disabled": { "alias": "disabled"; "required": false; }; "content": { "alias": "content"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; }, { "change": "change"; }, never, never, true, never>;
|
|
621
|
+
}
|
|
622
|
+
|
|
384
623
|
declare class InputModule {
|
|
385
624
|
static ɵfac: i0.ɵɵFactoryDeclaration<InputModule, never>;
|
|
386
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<InputModule, never, [typeof i1.CommonModule, typeof i2.FormsModule, typeof ButtonComponent, typeof SendIconComponent, typeof InputComponent], [typeof InputComponent]>;
|
|
625
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<InputModule, never, [typeof i1.CommonModule, typeof i2.FormsModule, typeof ButtonComponent, typeof SendIconComponent, typeof InputComponent, typeof InputTagComponent, typeof EditableBlockComponent], [typeof InputComponent]>;
|
|
387
626
|
static ɵinj: i0.ɵɵInjectorDeclaration<InputModule>;
|
|
388
627
|
}
|
|
389
628
|
|
|
629
|
+
type IntroductionBackground = 'filled' | 'transparent';
|
|
630
|
+
type IntroductionAlign = 'left' | 'center' | 'right';
|
|
631
|
+
|
|
632
|
+
interface IntroductionAdapter extends DefaultAdapter {
|
|
633
|
+
}
|
|
634
|
+
declare class IntroductionFoundation extends BaseFoundation<IntroductionAdapter> {
|
|
635
|
+
constructor(adapter: IntroductionAdapter);
|
|
636
|
+
getIntroductionClasses(): string;
|
|
637
|
+
getLogoStyle(): Record<string, string>;
|
|
638
|
+
}
|
|
639
|
+
|
|
640
|
+
declare class IntroductionComponent extends BaseComponent<IntroductionFoundation> {
|
|
641
|
+
logoImg?: string;
|
|
642
|
+
title?: string;
|
|
643
|
+
subTitle?: string;
|
|
644
|
+
description: string[];
|
|
645
|
+
logoWidth?: number | string;
|
|
646
|
+
logoHeight?: number | string;
|
|
647
|
+
background: IntroductionBackground;
|
|
648
|
+
align: IntroductionAlign;
|
|
649
|
+
constructor();
|
|
650
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<IntroductionComponent, never>;
|
|
651
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<IntroductionComponent, "mc-introduction", never, { "logoImg": { "alias": "logoImg"; "required": false; }; "title": { "alias": "title"; "required": false; }; "subTitle": { "alias": "subTitle"; "required": false; }; "description": { "alias": "description"; "required": false; }; "logoWidth": { "alias": "logoWidth"; "required": false; }; "logoHeight": { "alias": "logoHeight"; "required": false; }; "background": { "alias": "background"; "required": false; }; "align": { "alias": "align"; "required": false; }; }, {}, never, ["*"], true, never>;
|
|
652
|
+
}
|
|
653
|
+
|
|
654
|
+
declare class IntroductionModule {
|
|
655
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<IntroductionModule, never>;
|
|
656
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<IntroductionModule, never, [typeof i1.CommonModule, typeof IntroductionComponent], [typeof IntroductionComponent]>;
|
|
657
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<IntroductionModule>;
|
|
658
|
+
}
|
|
659
|
+
|
|
660
|
+
declare enum ListDirection {
|
|
661
|
+
Horizontal = "horizontal",
|
|
662
|
+
Vertical = "vertical"
|
|
663
|
+
}
|
|
664
|
+
declare enum ListVariant {
|
|
665
|
+
Transparent = "transparent",
|
|
666
|
+
Filled = "filled",
|
|
667
|
+
Bordered = "bordered",
|
|
668
|
+
None = "none"
|
|
669
|
+
}
|
|
670
|
+
interface ListItemData {
|
|
671
|
+
label: string;
|
|
672
|
+
value: string | number;
|
|
673
|
+
disabled?: boolean;
|
|
674
|
+
active?: boolean;
|
|
675
|
+
[key: string]: any;
|
|
676
|
+
}
|
|
677
|
+
|
|
678
|
+
interface ListAdapter extends DefaultAdapter {
|
|
679
|
+
}
|
|
680
|
+
declare class ListFoundation extends BaseFoundation<ListAdapter> {
|
|
681
|
+
constructor(adapter: ListAdapter);
|
|
682
|
+
getListClasses(): {
|
|
683
|
+
'mc-list': boolean;
|
|
684
|
+
'mc-list-horizontal': boolean;
|
|
685
|
+
'mc-list-nowrap': boolean;
|
|
686
|
+
};
|
|
687
|
+
}
|
|
688
|
+
|
|
689
|
+
declare class ListComponent extends BaseComponent<ListFoundation> {
|
|
690
|
+
direction: ListDirection;
|
|
691
|
+
autoWrap: boolean;
|
|
692
|
+
variant: ListVariant;
|
|
693
|
+
enableLazyLoad: boolean;
|
|
694
|
+
enableShortKey: boolean;
|
|
695
|
+
data: Array<ListItemData>;
|
|
696
|
+
inputEl: HTMLElement;
|
|
697
|
+
selectable: boolean;
|
|
698
|
+
preSelectIndex: number;
|
|
699
|
+
loadMore: EventEmitter<Event>;
|
|
700
|
+
select: EventEmitter<ListItemData>;
|
|
701
|
+
itemTemplate: TemplateRef<any> | null;
|
|
702
|
+
protected readonly ListVariant: typeof ListVariant;
|
|
703
|
+
private listenDom;
|
|
704
|
+
constructor();
|
|
705
|
+
ngOnInit(): void;
|
|
706
|
+
ngOnDestroy(): void;
|
|
707
|
+
get adapter(): ListAdapter;
|
|
708
|
+
get listClasses(): Record<string, any>;
|
|
709
|
+
initListenDom(): void;
|
|
710
|
+
initListener(): void;
|
|
711
|
+
removeListener(): void;
|
|
712
|
+
onListScroll(e: Event): void;
|
|
713
|
+
onItemClick(clickedItem: ListItemData): void;
|
|
714
|
+
onKeyDown(e: KeyboardEvent): void;
|
|
715
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ListComponent, never>;
|
|
716
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ListComponent, "mc-list", never, { "direction": { "alias": "direction"; "required": false; }; "autoWrap": { "alias": "autoWrap"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "enableLazyLoad": { "alias": "enableLazyLoad"; "required": false; }; "enableShortKey": { "alias": "enableShortKey"; "required": false; }; "data": { "alias": "data"; "required": false; }; "inputEl": { "alias": "inputEl"; "required": false; }; "selectable": { "alias": "selectable"; "required": false; }; "preSelectIndex": { "alias": "preSelectIndex"; "required": false; }; }, { "loadMore": "loadMore"; "select": "select"; }, ["itemTemplate"], never, true, never>;
|
|
717
|
+
}
|
|
718
|
+
|
|
719
|
+
declare class ListModule {
|
|
720
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ListModule, never>;
|
|
721
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<ListModule, never, [typeof i1.CommonModule, typeof ListComponent], [typeof ListComponent]>;
|
|
722
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<ListModule>;
|
|
723
|
+
}
|
|
724
|
+
|
|
390
725
|
interface MermaidConfig {
|
|
391
726
|
theme?: string;
|
|
392
727
|
}
|
|
@@ -626,5 +961,328 @@ declare class MarkdownCardModule {
|
|
|
626
961
|
static ɵinj: i0.ɵɵInjectorDeclaration<MarkdownCardModule>;
|
|
627
962
|
}
|
|
628
963
|
|
|
629
|
-
|
|
630
|
-
|
|
964
|
+
interface Trigger {
|
|
965
|
+
key: string;
|
|
966
|
+
onlyInputStart?: boolean;
|
|
967
|
+
}
|
|
968
|
+
interface MentionProps {
|
|
969
|
+
modelValue: boolean;
|
|
970
|
+
prefix: Array<string | Trigger>;
|
|
971
|
+
fitHostWidth: boolean;
|
|
972
|
+
optionsCount: number;
|
|
973
|
+
}
|
|
974
|
+
interface SearchChangeEvent {
|
|
975
|
+
value: string;
|
|
976
|
+
trigger: string;
|
|
977
|
+
triggerIndex: number;
|
|
978
|
+
cursorIndex: number;
|
|
979
|
+
}
|
|
980
|
+
|
|
981
|
+
interface MentionAdapter extends DefaultAdapter {
|
|
982
|
+
updateModelValue: (val: boolean) => void;
|
|
983
|
+
searchChange: (event: SearchChangeEvent) => void;
|
|
984
|
+
activeIndexChange: (index: number) => void;
|
|
985
|
+
toggleChange: (val: boolean) => void;
|
|
986
|
+
}
|
|
987
|
+
declare class MentionFoundation extends BaseFoundation<MentionAdapter> {
|
|
988
|
+
private props;
|
|
989
|
+
private inputEl;
|
|
990
|
+
private originEl;
|
|
991
|
+
private overlayEl;
|
|
992
|
+
private currentTrigger;
|
|
993
|
+
private currentSearchValue;
|
|
994
|
+
private currentTriggerIndex;
|
|
995
|
+
private currentCursorIndex;
|
|
996
|
+
private autoUpdateCleanup;
|
|
997
|
+
constructor(adapter: MentionAdapter);
|
|
998
|
+
updateOptions(options: Partial<MentionProps>): void;
|
|
999
|
+
setInputEl(el: HTMLInputElement | HTMLTextAreaElement | null): void;
|
|
1000
|
+
setOriginEl(el: HTMLElement | null): void;
|
|
1001
|
+
setOverlayEl(el: HTMLElement | null): void;
|
|
1002
|
+
initEvents(): void;
|
|
1003
|
+
destroy(): void;
|
|
1004
|
+
resetMention(): void;
|
|
1005
|
+
private updateModelValue;
|
|
1006
|
+
handleInput: () => void;
|
|
1007
|
+
handleKeyDown: (event: KeyboardEvent) => void;
|
|
1008
|
+
private handleClick;
|
|
1009
|
+
private handleDocumentClick;
|
|
1010
|
+
private checkPrefixMatch;
|
|
1011
|
+
private handleArrowKey;
|
|
1012
|
+
private getCurrentActiveIndex;
|
|
1013
|
+
private handleSelect;
|
|
1014
|
+
updateOverlayPosition(): Promise<{
|
|
1015
|
+
top: string;
|
|
1016
|
+
left: string;
|
|
1017
|
+
width: string;
|
|
1018
|
+
} | undefined>;
|
|
1019
|
+
getCurrentSearchValue(): string;
|
|
1020
|
+
getCurrentTrigger(): string;
|
|
1021
|
+
}
|
|
1022
|
+
|
|
1023
|
+
declare class MentionComponent extends BaseComponent<MentionFoundation> implements OnInit, AfterViewInit, OnDestroy, ControlValueAccessor {
|
|
1024
|
+
prefix: Array<string | Trigger>;
|
|
1025
|
+
fitHostWidth: boolean;
|
|
1026
|
+
menuClass?: string;
|
|
1027
|
+
private _optionsCount;
|
|
1028
|
+
set optionsCount(val: number);
|
|
1029
|
+
get optionsCount(): number;
|
|
1030
|
+
updateModelValue: EventEmitter<boolean>;
|
|
1031
|
+
searchChange: EventEmitter<SearchChangeEvent>;
|
|
1032
|
+
toggleChange: EventEmitter<boolean>;
|
|
1033
|
+
activeIndexChange: EventEmitter<number>;
|
|
1034
|
+
activeIndex: number;
|
|
1035
|
+
popperTriggerEl: ElementRef;
|
|
1036
|
+
originEl: ElementRef;
|
|
1037
|
+
overlayEl: ElementRef;
|
|
1038
|
+
overlayStyle: {
|
|
1039
|
+
top: string;
|
|
1040
|
+
left: string;
|
|
1041
|
+
width: string;
|
|
1042
|
+
};
|
|
1043
|
+
private inputEl;
|
|
1044
|
+
constructor();
|
|
1045
|
+
ngOnInit(): void;
|
|
1046
|
+
get adapter(): any;
|
|
1047
|
+
ngAfterViewInit(): void;
|
|
1048
|
+
ngOnDestroy(): void;
|
|
1049
|
+
set modelValue(val: boolean);
|
|
1050
|
+
get modelValue(): boolean;
|
|
1051
|
+
private _modelValue;
|
|
1052
|
+
private onChange;
|
|
1053
|
+
private onTouched;
|
|
1054
|
+
writeValue(value: boolean): void;
|
|
1055
|
+
registerOnChange(fn: (value: boolean) => void): void;
|
|
1056
|
+
registerOnTouched(fn: () => void): void;
|
|
1057
|
+
setDisabledState?(isDisabled: boolean): void;
|
|
1058
|
+
ngAfterContentInit(): void;
|
|
1059
|
+
private cleanupDocumentClick;
|
|
1060
|
+
private onDocumentClick;
|
|
1061
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MentionComponent, never>;
|
|
1062
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<MentionComponent, "mc-mention", never, { "prefix": { "alias": "prefix"; "required": false; }; "fitHostWidth": { "alias": "fitHostWidth"; "required": false; }; "menuClass": { "alias": "menuClass"; "required": false; }; "optionsCount": { "alias": "optionsCount"; "required": false; }; "modelValue": { "alias": "modelValue"; "required": false; }; }, { "updateModelValue": "updateModelValue"; "searchChange": "searchChange"; "toggleChange": "toggleChange"; "activeIndexChange": "activeIndexChange"; }, never, ["*", "[slot=menu]"], true, never>;
|
|
1063
|
+
}
|
|
1064
|
+
|
|
1065
|
+
declare class MentionModule {
|
|
1066
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MentionModule, never>;
|
|
1067
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<MentionModule, never, [typeof i1.CommonModule, typeof MentionComponent], [typeof MentionComponent]>;
|
|
1068
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<MentionModule>;
|
|
1069
|
+
}
|
|
1070
|
+
|
|
1071
|
+
declare class CopyIconComponent {
|
|
1072
|
+
width: number;
|
|
1073
|
+
height: number;
|
|
1074
|
+
isActive: boolean;
|
|
1075
|
+
text: string;
|
|
1076
|
+
title: string;
|
|
1077
|
+
copied: boolean;
|
|
1078
|
+
handleClick(): Promise<void>;
|
|
1079
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CopyIconComponent, never>;
|
|
1080
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CopyIconComponent, "mc-copy-icon", never, { "width": { "alias": "width"; "required": false; }; "height": { "alias": "height"; "required": false; }; "isActive": { "alias": "isActive"; "required": false; }; "text": { "alias": "text"; "required": false; }; "title": { "alias": "title"; "required": false; }; }, {}, never, never, true, never>;
|
|
1081
|
+
}
|
|
1082
|
+
|
|
1083
|
+
declare class DeleteIconComponent {
|
|
1084
|
+
width: number;
|
|
1085
|
+
height: number;
|
|
1086
|
+
isActive: boolean;
|
|
1087
|
+
title: string;
|
|
1088
|
+
text: string;
|
|
1089
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DeleteIconComponent, never>;
|
|
1090
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<DeleteIconComponent, "mc-delete-icon", never, { "width": { "alias": "width"; "required": false; }; "height": { "alias": "height"; "required": false; }; "isActive": { "alias": "isActive"; "required": false; }; "title": { "alias": "title"; "required": false; }; "text": { "alias": "text"; "required": false; }; }, {}, never, never, true, never>;
|
|
1091
|
+
}
|
|
1092
|
+
|
|
1093
|
+
declare class DislikeIconComponent implements OnChanges {
|
|
1094
|
+
width: number;
|
|
1095
|
+
height: number;
|
|
1096
|
+
isActive: boolean;
|
|
1097
|
+
title: string;
|
|
1098
|
+
text: string;
|
|
1099
|
+
activeChange: EventEmitter<boolean>;
|
|
1100
|
+
active: boolean;
|
|
1101
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
1102
|
+
handleClick(): void;
|
|
1103
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DislikeIconComponent, never>;
|
|
1104
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<DislikeIconComponent, "mc-dislike-icon", never, { "width": { "alias": "width"; "required": false; }; "height": { "alias": "height"; "required": false; }; "isActive": { "alias": "isActive"; "required": false; }; "title": { "alias": "title"; "required": false; }; "text": { "alias": "text"; "required": false; }; }, { "activeChange": "activeChange"; }, never, never, true, never>;
|
|
1105
|
+
}
|
|
1106
|
+
|
|
1107
|
+
declare class LikeIconComponent implements OnChanges {
|
|
1108
|
+
width: number;
|
|
1109
|
+
height: number;
|
|
1110
|
+
isActive: boolean;
|
|
1111
|
+
title: string;
|
|
1112
|
+
text: string;
|
|
1113
|
+
activeChange: EventEmitter<boolean>;
|
|
1114
|
+
active: boolean;
|
|
1115
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
1116
|
+
handleClick(): void;
|
|
1117
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LikeIconComponent, never>;
|
|
1118
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<LikeIconComponent, "mc-like-icon", never, { "width": { "alias": "width"; "required": false; }; "height": { "alias": "height"; "required": false; }; "isActive": { "alias": "isActive"; "required": false; }; "title": { "alias": "title"; "required": false; }; "text": { "alias": "text"; "required": false; }; }, { "activeChange": "activeChange"; }, never, never, true, never>;
|
|
1119
|
+
}
|
|
1120
|
+
|
|
1121
|
+
declare class RefreshIconComponent {
|
|
1122
|
+
width: number;
|
|
1123
|
+
height: number;
|
|
1124
|
+
isActive: boolean;
|
|
1125
|
+
title: string;
|
|
1126
|
+
text: string;
|
|
1127
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<RefreshIconComponent, never>;
|
|
1128
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<RefreshIconComponent, "mc-refresh-icon", never, { "width": { "alias": "width"; "required": false; }; "height": { "alias": "height"; "required": false; }; "isActive": { "alias": "isActive"; "required": false; }; "title": { "alias": "title"; "required": false; }; "text": { "alias": "text"; "required": false; }; }, {}, never, never, true, never>;
|
|
1129
|
+
}
|
|
1130
|
+
|
|
1131
|
+
declare class ShareIconComponent {
|
|
1132
|
+
width: number;
|
|
1133
|
+
height: number;
|
|
1134
|
+
isActive: boolean;
|
|
1135
|
+
title: string;
|
|
1136
|
+
text: string;
|
|
1137
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ShareIconComponent, never>;
|
|
1138
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ShareIconComponent, "mc-share-icon", never, { "width": { "alias": "width"; "required": false; }; "height": { "alias": "height"; "required": false; }; "isActive": { "alias": "isActive"; "required": false; }; "title": { "alias": "title"; "required": false; }; "text": { "alias": "text"; "required": false; }; }, {}, never, never, true, never>;
|
|
1139
|
+
}
|
|
1140
|
+
|
|
1141
|
+
declare enum ToolbarAction {
|
|
1142
|
+
COPY = "copy",
|
|
1143
|
+
LIKE = "like",
|
|
1144
|
+
DISLIKE = "dislike",
|
|
1145
|
+
REFRESH = "refresh",
|
|
1146
|
+
SHARE = "share",
|
|
1147
|
+
DELETE = "delete"
|
|
1148
|
+
}
|
|
1149
|
+
interface ActionItem {
|
|
1150
|
+
key: string;
|
|
1151
|
+
icon?: ToolbarAction;
|
|
1152
|
+
label?: string;
|
|
1153
|
+
onClick?: (actionItem: ActionItem, e: MouseEvent) => void;
|
|
1154
|
+
isActive?: boolean;
|
|
1155
|
+
text?: string;
|
|
1156
|
+
}
|
|
1157
|
+
|
|
1158
|
+
declare class ToolbarComponent implements OnInit, AfterContentInit {
|
|
1159
|
+
items: ActionItem[];
|
|
1160
|
+
gap: number;
|
|
1161
|
+
iconSize: number;
|
|
1162
|
+
onClick: EventEmitter<{
|
|
1163
|
+
item: ActionItem;
|
|
1164
|
+
event: MouseEvent;
|
|
1165
|
+
}>;
|
|
1166
|
+
private allTemplates;
|
|
1167
|
+
CustomSlotComponent: {};
|
|
1168
|
+
actionItems: ActionItem[];
|
|
1169
|
+
ToolbarAction: typeof ToolbarAction;
|
|
1170
|
+
constructor();
|
|
1171
|
+
ngOnInit(): void;
|
|
1172
|
+
ngAfterContentInit(): void;
|
|
1173
|
+
trackByKey(index: number, item: ActionItem): string;
|
|
1174
|
+
/** 初始化:确保点赞和点踩不同时激活 */
|
|
1175
|
+
private init;
|
|
1176
|
+
/** 点赞点击处理:取消点踩状态 */
|
|
1177
|
+
private handleLikeClick;
|
|
1178
|
+
/** 点踩点击处理:取消点赞状态 */
|
|
1179
|
+
private handleDislikeClick;
|
|
1180
|
+
/** 操作项点击事件 */
|
|
1181
|
+
actionClick(event: MouseEvent, actionItem: ActionItem): void;
|
|
1182
|
+
/** 激活状态变更 */
|
|
1183
|
+
activeChange(isActive: boolean, actionItem: ActionItem): void;
|
|
1184
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ToolbarComponent, never>;
|
|
1185
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ToolbarComponent, "mc-toolbar", never, { "items": { "alias": "items"; "required": false; }; "gap": { "alias": "gap"; "required": false; }; "iconSize": { "alias": "iconSize"; "required": false; }; }, { "onClick": "onClick"; }, ["allTemplates"], never, true, never>;
|
|
1186
|
+
}
|
|
1187
|
+
|
|
1188
|
+
declare class ToolbarModule {
|
|
1189
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ToolbarModule, never>;
|
|
1190
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<ToolbarModule, never, [typeof i1.CommonModule, typeof ToolbarComponent, typeof CopyIconComponent, typeof DeleteIconComponent, typeof RefreshIconComponent, typeof ShareIconComponent, typeof LikeIconComponent, typeof DislikeIconComponent], [typeof ToolbarComponent, typeof CopyIconComponent, typeof DeleteIconComponent, typeof RefreshIconComponent, typeof ShareIconComponent, typeof LikeIconComponent, typeof DislikeIconComponent]>;
|
|
1191
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<ToolbarModule>;
|
|
1192
|
+
}
|
|
1193
|
+
|
|
1194
|
+
interface IconConfig {
|
|
1195
|
+
name: string;
|
|
1196
|
+
size?: string;
|
|
1197
|
+
color?: string;
|
|
1198
|
+
component?: object;
|
|
1199
|
+
}
|
|
1200
|
+
interface Prompt {
|
|
1201
|
+
value: string | number;
|
|
1202
|
+
label: string;
|
|
1203
|
+
iconConfig?: IconConfig;
|
|
1204
|
+
desc?: string;
|
|
1205
|
+
}
|
|
1206
|
+
|
|
1207
|
+
interface PromptAdapter extends DefaultAdapter {
|
|
1208
|
+
}
|
|
1209
|
+
declare class PromptFoundation extends BaseFoundation<PromptAdapter> {
|
|
1210
|
+
constructor(adapter: PromptAdapter);
|
|
1211
|
+
}
|
|
1212
|
+
|
|
1213
|
+
declare class PromptComponent extends BaseComponent<PromptFoundation> {
|
|
1214
|
+
direction: ListDirection;
|
|
1215
|
+
list: Prompt[];
|
|
1216
|
+
variant: ListVariant;
|
|
1217
|
+
itemClick: EventEmitter<Prompt>;
|
|
1218
|
+
constructor();
|
|
1219
|
+
ngOnInit(): void;
|
|
1220
|
+
get adapter(): PromptAdapter;
|
|
1221
|
+
handleItemClick(item: Prompt): void;
|
|
1222
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PromptComponent, never>;
|
|
1223
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<PromptComponent, "mc-prompt", never, { "direction": { "alias": "direction"; "required": false; }; "list": { "alias": "list"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; }, { "itemClick": "itemClick"; }, never, never, true, never>;
|
|
1224
|
+
}
|
|
1225
|
+
|
|
1226
|
+
declare class PromptModule {
|
|
1227
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PromptModule, never>;
|
|
1228
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<PromptModule, never, [typeof i1.CommonModule, typeof PromptComponent], [typeof PromptComponent]>;
|
|
1229
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<PromptModule>;
|
|
1230
|
+
}
|
|
1231
|
+
|
|
1232
|
+
declare class LayoutAsideComponent {
|
|
1233
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutAsideComponent, never>;
|
|
1234
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<LayoutAsideComponent, "mc-layout-aside", never, {}, {}, never, ["*"], true, never>;
|
|
1235
|
+
}
|
|
1236
|
+
|
|
1237
|
+
declare class LayoutAsideModule {
|
|
1238
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutAsideModule, never>;
|
|
1239
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<LayoutAsideModule, never, [typeof i1.CommonModule, typeof LayoutAsideComponent], [typeof LayoutAsideComponent]>;
|
|
1240
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<LayoutAsideModule>;
|
|
1241
|
+
}
|
|
1242
|
+
|
|
1243
|
+
declare class LayoutContentComponent {
|
|
1244
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutContentComponent, never>;
|
|
1245
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<LayoutContentComponent, "mc-layout-content", never, {}, {}, never, ["*"], true, never>;
|
|
1246
|
+
}
|
|
1247
|
+
|
|
1248
|
+
declare class LayoutContentModule {
|
|
1249
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutContentModule, never>;
|
|
1250
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<LayoutContentModule, never, [typeof i1.CommonModule, typeof LayoutContentComponent], [typeof LayoutContentComponent]>;
|
|
1251
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<LayoutContentModule>;
|
|
1252
|
+
}
|
|
1253
|
+
|
|
1254
|
+
declare class LayoutHeaderComponent {
|
|
1255
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutHeaderComponent, never>;
|
|
1256
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<LayoutHeaderComponent, "mc-layout-header", never, {}, {}, never, ["*"], true, never>;
|
|
1257
|
+
}
|
|
1258
|
+
|
|
1259
|
+
declare class LayoutHeaderModule {
|
|
1260
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutHeaderModule, never>;
|
|
1261
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<LayoutHeaderModule, never, [typeof i1.CommonModule, typeof LayoutHeaderComponent], [typeof LayoutHeaderComponent]>;
|
|
1262
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<LayoutHeaderModule>;
|
|
1263
|
+
}
|
|
1264
|
+
|
|
1265
|
+
declare class LayoutComponent {
|
|
1266
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutComponent, never>;
|
|
1267
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<LayoutComponent, "mc-layout", never, {}, {}, never, ["*"], true, never>;
|
|
1268
|
+
}
|
|
1269
|
+
|
|
1270
|
+
declare class LayoutModule {
|
|
1271
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutModule, never>;
|
|
1272
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<LayoutModule, never, [typeof i1.CommonModule, typeof LayoutComponent], [typeof LayoutComponent]>;
|
|
1273
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<LayoutModule>;
|
|
1274
|
+
}
|
|
1275
|
+
|
|
1276
|
+
declare class LayoutSenderComponent {
|
|
1277
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutSenderComponent, never>;
|
|
1278
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<LayoutSenderComponent, "mc-layout-sender", never, {}, {}, never, ["*"], true, never>;
|
|
1279
|
+
}
|
|
1280
|
+
|
|
1281
|
+
declare class LayoutSenderModule {
|
|
1282
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LayoutSenderModule, never>;
|
|
1283
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<LayoutSenderModule, never, [typeof i1.CommonModule, typeof LayoutSenderComponent], [typeof LayoutSenderComponent]>;
|
|
1284
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<LayoutSenderModule>;
|
|
1285
|
+
}
|
|
1286
|
+
|
|
1287
|
+
export { AttachmentComponent, AttachmentModule, AvatarBodyIconComponent, AvatarComponent, AvatarNoBodyIconComponent, BubbleComponent, BubbleLoadingComponent, BubbleModule, CodeBlockComponent, CopyIconComponent, DeleteIconComponent, DislikeIconComponent, HeaderComponent, HeaderModule, InputComponent, InputModule, IntroductionComponent, IntroductionModule, LayoutAsideComponent, LayoutAsideModule, LayoutComponent, LayoutContentComponent, LayoutContentModule, LayoutHeaderComponent, LayoutHeaderModule, LayoutModule, LayoutSenderComponent, LayoutSenderModule, LikeIconComponent, ListComponent, ListDirection, ListModule, ListVariant, LocaleModule, LocaleService, MarkdownCardComponent, MarkdownCardModule, MentionComponent, MentionModule, PromptComponent, PromptModule, RefreshIconComponent, ShareIconComponent, ToolbarAction, ToolbarComponent, ToolbarModule, TranslatePipe, inputContextToken };
|
|
1288
|
+
export type { ActionItem, LanguageCode, ListItemData, LocaleData, TextareaAutoSize };
|