@cdek-it/angular-ui-kit 0.2.7-test → 0.2.8-test
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/components/avatar/index.d.ts +2 -2
- package/components/button/index.d.ts +6 -6
- package/components/confirm-dialog/index.d.ts +1 -1
- package/components/fileupload/index.d.ts +62 -0
- package/components/message/index.d.ts +3 -1
- package/components/progressspinner/index.d.ts +1 -1
- package/components/select-button/index.d.ts +38 -0
- package/components/tag/index.d.ts +1 -1
- package/components/togglebutton/index.d.ts +41 -0
- package/fesm2022/cdek-it-angular-ui-kit-components-avatar.mjs +2 -2
- package/fesm2022/cdek-it-angular-ui-kit-components-avatar.mjs.map +1 -1
- package/fesm2022/cdek-it-angular-ui-kit-components-button.mjs +9 -9
- package/fesm2022/cdek-it-angular-ui-kit-components-button.mjs.map +1 -1
- package/fesm2022/cdek-it-angular-ui-kit-components-confirm-dialog.mjs +2 -2
- package/fesm2022/cdek-it-angular-ui-kit-components-confirm-dialog.mjs.map +1 -1
- package/fesm2022/cdek-it-angular-ui-kit-components-fileupload.mjs +436 -0
- package/fesm2022/cdek-it-angular-ui-kit-components-fileupload.mjs.map +1 -0
- package/fesm2022/cdek-it-angular-ui-kit-components-message.mjs +11 -4
- package/fesm2022/cdek-it-angular-ui-kit-components-message.mjs.map +1 -1
- package/fesm2022/cdek-it-angular-ui-kit-components-progressspinner.mjs +1 -1
- package/fesm2022/cdek-it-angular-ui-kit-components-progressspinner.mjs.map +1 -1
- package/fesm2022/cdek-it-angular-ui-kit-components-select-button.mjs +136 -0
- package/fesm2022/cdek-it-angular-ui-kit-components-select-button.mjs.map +1 -0
- package/fesm2022/cdek-it-angular-ui-kit-components-stepper.mjs +1 -1
- package/fesm2022/cdek-it-angular-ui-kit-components-stepper.mjs.map +1 -1
- package/fesm2022/cdek-it-angular-ui-kit-components-tag.mjs +2 -0
- package/fesm2022/cdek-it-angular-ui-kit-components-tag.mjs.map +1 -1
- package/fesm2022/cdek-it-angular-ui-kit-components-togglebutton.mjs +167 -0
- package/fesm2022/cdek-it-angular-ui-kit-components-togglebutton.mjs.map +1 -0
- package/fesm2022/cdek-it-angular-ui-kit-providers.mjs +5189 -3114
- package/fesm2022/cdek-it-angular-ui-kit-providers.mjs.map +1 -1
- package/package.json +13 -1
- package/tailwind/theme.css +8 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
|
|
3
|
-
type ExtraAvatarSize = '
|
|
3
|
+
type ExtraAvatarSize = 'base' | 'large' | 'xlarge';
|
|
4
4
|
type ExtraAvatarShape = 'square' | 'circle';
|
|
5
5
|
declare class ExtraAvatarComponent {
|
|
6
6
|
label: string;
|
|
@@ -9,7 +9,7 @@ declare class ExtraAvatarComponent {
|
|
|
9
9
|
size: ExtraAvatarSize;
|
|
10
10
|
shape: ExtraAvatarShape;
|
|
11
11
|
get hostClass(): string;
|
|
12
|
-
get primeSize(): '
|
|
12
|
+
get primeSize(): 'large' | 'xlarge' | undefined;
|
|
13
13
|
static ɵfac: i0.ɵɵFactoryDeclaration<ExtraAvatarComponent, never>;
|
|
14
14
|
static ɵcmp: i0.ɵɵComponentDeclaration<ExtraAvatarComponent, "extra-avatar", never, { "label": { "alias": "label"; "required": false; }; "icon": { "alias": "icon"; "required": false; }; "image": { "alias": "image"; "required": false; }; "size": { "alias": "size"; "required": false; }; "shape": { "alias": "shape"; "required": false; }; }, {}, never, never, true, never>;
|
|
15
15
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { ButtonSeverity, Button } from 'primeng/button';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
3
|
|
|
4
|
-
type ExtraButtonVariant = 'primary' | 'secondary' | '
|
|
4
|
+
type ExtraButtonVariant = 'primary' | 'secondary' | 'tertiary' | 'text' | 'link';
|
|
5
5
|
type ExtraButtonSeverity = 'success' | 'warning' | 'danger' | 'info' | null;
|
|
6
6
|
type ExtraButtonSize = 'small' | 'base' | 'large' | 'xlarge';
|
|
7
|
-
type
|
|
7
|
+
type ExtraButtonIconPosition = 'prefix' | 'postfix' | null;
|
|
8
8
|
type ExtraBadgeSeverity = 'success' | 'info' | 'warning' | 'danger' | 'secondary' | 'contrast' | null;
|
|
9
9
|
type PrimeBadgeSeverity = Extract<Button['badgeSeverity'], string | null>;
|
|
10
10
|
type ExtraButtonSeverityValue = ButtonSeverity;
|
|
@@ -15,7 +15,7 @@ declare class ExtraButtonComponent {
|
|
|
15
15
|
severity: ExtraButtonSeverity;
|
|
16
16
|
size: ExtraButtonSize;
|
|
17
17
|
rounded: boolean;
|
|
18
|
-
|
|
18
|
+
iconPosition: ExtraButtonIconPosition;
|
|
19
19
|
iconOnly: boolean;
|
|
20
20
|
icon: string;
|
|
21
21
|
disabled: boolean;
|
|
@@ -29,12 +29,12 @@ declare class ExtraButtonComponent {
|
|
|
29
29
|
tabindex: number | undefined;
|
|
30
30
|
text: boolean;
|
|
31
31
|
get primeSize(): 'small' | 'large' | undefined;
|
|
32
|
-
get
|
|
32
|
+
get primeIconPosition(): 'left' | 'right';
|
|
33
33
|
get primeSeverity(): ExtraButtonSeverityValue | null;
|
|
34
34
|
get primeBadgeSeverity(): ExtraBadgeSeverityValue;
|
|
35
35
|
static ɵfac: i0.ɵɵFactoryDeclaration<ExtraButtonComponent, never>;
|
|
36
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<ExtraButtonComponent, "extra-button", never, { "label": { "alias": "label"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "severity": { "alias": "severity"; "required": false; }; "size": { "alias": "size"; "required": false; }; "rounded": { "alias": "rounded"; "required": false; }; "
|
|
36
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ExtraButtonComponent, "extra-button", never, { "label": { "alias": "label"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "severity": { "alias": "severity"; "required": false; }; "size": { "alias": "size"; "required": false; }; "rounded": { "alias": "rounded"; "required": false; }; "iconPosition": { "alias": "iconPosition"; "required": false; }; "iconOnly": { "alias": "iconOnly"; "required": false; }; "icon": { "alias": "icon"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "badge": { "alias": "badge"; "required": false; }; "badgeSeverity": { "alias": "badgeSeverity"; "required": false; }; "showBadge": { "alias": "showBadge"; "required": false; }; "fluid": { "alias": "fluid"; "required": false; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; }; "autofocus": { "alias": "autofocus"; "required": false; }; "tabindex": { "alias": "tabindex"; "required": false; }; "text": { "alias": "text"; "required": false; }; }, {}, never, never, true, never>;
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
export { ExtraButtonComponent };
|
|
40
|
-
export type { ExtraBadgeSeverity,
|
|
40
|
+
export type { ExtraBadgeSeverity, ExtraButtonIconPosition, ExtraButtonSeverity, ExtraButtonSize, ExtraButtonVariant };
|
|
@@ -3,7 +3,7 @@ import { TemplateRef, Provider } from '@angular/core';
|
|
|
3
3
|
import { Confirmation, ConfirmationService } from 'primeng/api';
|
|
4
4
|
|
|
5
5
|
type ExtraConfirmDialogSize = 'sm' | 'default' | 'lg' | 'xlg';
|
|
6
|
-
type ExtraConfirmDialogSeverity = 'success' | 'info' | '
|
|
6
|
+
type ExtraConfirmDialogSeverity = 'success' | 'info' | 'warning' | 'help' | 'danger' | 'default';
|
|
7
7
|
declare class ExtraConfirmDialogHeaderDirective {
|
|
8
8
|
static ɵfac: i0.ɵɵFactoryDeclaration<ExtraConfirmDialogHeaderDirective, never>;
|
|
9
9
|
static ɵdir: i0.ɵɵDirectiveDeclaration<ExtraConfirmDialogHeaderDirective, "[extraConfirmDialogHeader]", never, {}, {}, never, never, true, never>;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { EventEmitter } from '@angular/core';
|
|
3
|
+
import { ControlValueAccessor } from '@angular/forms';
|
|
4
|
+
import { FileUpload, FileSelectEvent, FileRemoveEvent, FileUploadErrorEvent, FileUploadHandlerEvent } from 'primeng/fileupload';
|
|
5
|
+
|
|
6
|
+
type PreviewFile = File & {
|
|
7
|
+
objectURL?: string;
|
|
8
|
+
};
|
|
9
|
+
declare class ExtraFileUploadComponent implements ControlValueAccessor {
|
|
10
|
+
private el;
|
|
11
|
+
private cdr;
|
|
12
|
+
fuRef: FileUpload;
|
|
13
|
+
name: string;
|
|
14
|
+
url: string;
|
|
15
|
+
multiple: boolean;
|
|
16
|
+
accept: string;
|
|
17
|
+
maxFileSize: number;
|
|
18
|
+
fileLimit: number | undefined;
|
|
19
|
+
disabled: boolean;
|
|
20
|
+
dropzoneTitle: string;
|
|
21
|
+
dropzoneCaption: string;
|
|
22
|
+
invalidFileSizeMessageSummary: string;
|
|
23
|
+
invalidFileSizeMessageDetail: string;
|
|
24
|
+
invalidFileTypeMessageSummary: string;
|
|
25
|
+
invalidFileTypeMessageDetail: string;
|
|
26
|
+
invalidFileLimitMessageSummary: string;
|
|
27
|
+
invalidFileLimitMessageDetail: string;
|
|
28
|
+
onSelectEvent: EventEmitter<FileSelectEvent>;
|
|
29
|
+
onRemoveEvent: EventEmitter<FileRemoveEvent>;
|
|
30
|
+
onClearEvent: EventEmitter<void>;
|
|
31
|
+
onError: EventEmitter<FileUploadErrorEvent>;
|
|
32
|
+
onUpload: EventEmitter<FileUploadHandlerEvent>;
|
|
33
|
+
selectedFiles: PreviewFile[];
|
|
34
|
+
uploadedFiles: PreviewFile[];
|
|
35
|
+
totalSize: number;
|
|
36
|
+
totalSizePercent: number;
|
|
37
|
+
uploadSuccess: boolean;
|
|
38
|
+
isUploading: boolean;
|
|
39
|
+
private uploadCbRef;
|
|
40
|
+
private clearCbRef;
|
|
41
|
+
private onChange;
|
|
42
|
+
private onTouched;
|
|
43
|
+
writeValue(files: File[]): void;
|
|
44
|
+
registerOnChange(fn: (files: File[]) => void): void;
|
|
45
|
+
registerOnTouched(fn: () => void): void;
|
|
46
|
+
setDisabledState(isDisabled: boolean): void;
|
|
47
|
+
get uploadCb(): (() => void) | null;
|
|
48
|
+
storeCallbacks(upload: () => void, clear: () => void): string;
|
|
49
|
+
onDrop(event: DragEvent): void;
|
|
50
|
+
private filterFilesByAccept;
|
|
51
|
+
onChooseClick(): void;
|
|
52
|
+
isImage(file: File): boolean;
|
|
53
|
+
formatSize(bytes: number): string;
|
|
54
|
+
onSelectedFiles(event: FileSelectEvent): void;
|
|
55
|
+
onUploader(event: FileUploadHandlerEvent): void;
|
|
56
|
+
onRemoveFile(file: File, removeFileCallback: (index: number) => void, index: number): void;
|
|
57
|
+
onClearUpload(): void;
|
|
58
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ExtraFileUploadComponent, never>;
|
|
59
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ExtraFileUploadComponent, "extra-fileupload", never, { "name": { "alias": "name"; "required": false; }; "url": { "alias": "url"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "accept": { "alias": "accept"; "required": false; }; "maxFileSize": { "alias": "maxFileSize"; "required": false; }; "fileLimit": { "alias": "fileLimit"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "dropzoneTitle": { "alias": "dropzoneTitle"; "required": false; }; "dropzoneCaption": { "alias": "dropzoneCaption"; "required": false; }; "invalidFileSizeMessageSummary": { "alias": "invalidFileSizeMessageSummary"; "required": false; }; "invalidFileSizeMessageDetail": { "alias": "invalidFileSizeMessageDetail"; "required": false; }; "invalidFileTypeMessageSummary": { "alias": "invalidFileTypeMessageSummary"; "required": false; }; "invalidFileTypeMessageDetail": { "alias": "invalidFileTypeMessageDetail"; "required": false; }; "invalidFileLimitMessageSummary": { "alias": "invalidFileLimitMessageSummary"; "required": false; }; "invalidFileLimitMessageDetail": { "alias": "invalidFileLimitMessageDetail"; "required": false; }; }, { "onSelectEvent": "onSelectEvent"; "onRemoveEvent": "onRemoveEvent"; "onClearEvent": "onClearEvent"; "onError": "onError"; "onUpload": "onUpload"; }, never, never, true, never>;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export { ExtraFileUploadComponent };
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { EventEmitter } from '@angular/core';
|
|
3
3
|
|
|
4
|
-
type ExtraMessageSeverity = 'success' | 'info' | '
|
|
4
|
+
type ExtraMessageSeverity = 'success' | 'info' | 'warning' | 'danger' | 'secondary' | 'contrast';
|
|
5
|
+
type PrimeMessageSeverity = 'success' | 'info' | 'warn' | 'error' | 'secondary' | 'contrast';
|
|
5
6
|
declare class ExtraMessageComponent {
|
|
6
7
|
severity: ExtraMessageSeverity;
|
|
7
8
|
summary: string;
|
|
@@ -11,6 +12,7 @@ declare class ExtraMessageComponent {
|
|
|
11
12
|
life: number | undefined;
|
|
12
13
|
onClose: EventEmitter<Event>;
|
|
13
14
|
get resolvedIcon(): string;
|
|
15
|
+
get primeSeverity(): PrimeMessageSeverity;
|
|
14
16
|
static ɵfac: i0.ɵɵFactoryDeclaration<ExtraMessageComponent, never>;
|
|
15
17
|
static ɵcmp: i0.ɵɵComponentDeclaration<ExtraMessageComponent, "extra-message", never, { "severity": { "alias": "severity"; "required": false; }; "summary": { "alias": "summary"; "required": false; }; "detail": { "alias": "detail"; "required": false; }; "icon": { "alias": "icon"; "required": false; }; "closable": { "alias": "closable"; "required": false; }; "life": { "alias": "life"; "required": false; }; }, { "onClose": "onClose"; }, never, ["*"], true, never>;
|
|
16
18
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
|
|
3
|
-
type ExtraProgressSpinnerSize = 'small' | '
|
|
3
|
+
type ExtraProgressSpinnerSize = 'small' | 'base' | 'large' | 'xlarge';
|
|
4
4
|
declare class ExtraProgressSpinnerComponent {
|
|
5
5
|
size: ExtraProgressSpinnerSize;
|
|
6
6
|
multicolor: boolean;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { EventEmitter } from '@angular/core';
|
|
3
|
+
import { ControlValueAccessor, NgControl } from '@angular/forms';
|
|
4
|
+
|
|
5
|
+
interface ExtraSelectButtonItem {
|
|
6
|
+
label: string;
|
|
7
|
+
value: string;
|
|
8
|
+
icon?: string;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
}
|
|
11
|
+
declare class ExtraSelectButtonComponent implements ControlValueAccessor {
|
|
12
|
+
private ngControl;
|
|
13
|
+
options: unknown[];
|
|
14
|
+
optionLabel: string;
|
|
15
|
+
optionValue: string;
|
|
16
|
+
optionDisabled: string;
|
|
17
|
+
size: 'base' | 'small' | 'large' | 'xlarge';
|
|
18
|
+
multiple: boolean;
|
|
19
|
+
allowEmpty: boolean;
|
|
20
|
+
valueChange: EventEmitter<string | string[]>;
|
|
21
|
+
value: string | string[];
|
|
22
|
+
private _disabled;
|
|
23
|
+
private onChange;
|
|
24
|
+
private onTouched;
|
|
25
|
+
constructor(ngControl: NgControl);
|
|
26
|
+
get isDisabled(): boolean;
|
|
27
|
+
get sizeClass(): string;
|
|
28
|
+
writeValue(value: string | string[]): void;
|
|
29
|
+
registerOnChange(fn: (value: string | string[]) => void): void;
|
|
30
|
+
registerOnTouched(fn: () => void): void;
|
|
31
|
+
setDisabledState(isDisabled: boolean): void;
|
|
32
|
+
onValueChange(newValue: string | string[]): void;
|
|
33
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ExtraSelectButtonComponent, [{ optional: true; self: true; }]>;
|
|
34
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ExtraSelectButtonComponent, "extra-select-button", never, { "options": { "alias": "options"; "required": false; }; "optionLabel": { "alias": "optionLabel"; "required": false; }; "optionValue": { "alias": "optionValue"; "required": false; }; "optionDisabled": { "alias": "optionDisabled"; "required": false; }; "size": { "alias": "size"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "allowEmpty": { "alias": "allowEmpty"; "required": false; }; }, { "valueChange": "valueChange"; }, never, never, true, never>;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export { ExtraSelectButtonComponent };
|
|
38
|
+
export type { ExtraSelectButtonItem };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
|
|
3
|
-
type ExtraTagSeverity = 'primary' | 'secondary' | 'success' | 'info' | '
|
|
3
|
+
type ExtraTagSeverity = 'primary' | 'secondary' | 'success' | 'info' | 'warning' | 'danger';
|
|
4
4
|
declare class ExtraTagComponent {
|
|
5
5
|
value: string;
|
|
6
6
|
severity: ExtraTagSeverity;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { ChangeDetectorRef, EventEmitter } from '@angular/core';
|
|
3
|
+
import { ControlValueAccessor } from '@angular/forms';
|
|
4
|
+
import { ToggleButtonChangeEvent } from 'primeng/togglebutton';
|
|
5
|
+
|
|
6
|
+
type ExtraToggleButtonSize = 'small' | 'base' | 'large' | 'xlarge';
|
|
7
|
+
declare class ExtraToggleButtonComponent implements ControlValueAccessor {
|
|
8
|
+
private cdr;
|
|
9
|
+
constructor(cdr: ChangeDetectorRef);
|
|
10
|
+
onLabel: string;
|
|
11
|
+
offLabel: string;
|
|
12
|
+
onIcon: string | undefined;
|
|
13
|
+
offIcon: string | undefined;
|
|
14
|
+
iconPos: 'left' | 'right';
|
|
15
|
+
size: ExtraToggleButtonSize;
|
|
16
|
+
disabled: boolean;
|
|
17
|
+
iconOnly: boolean;
|
|
18
|
+
allowEmpty: boolean | undefined;
|
|
19
|
+
fluid: boolean;
|
|
20
|
+
ariaLabel: string | undefined;
|
|
21
|
+
ariaLabelledBy: string | undefined;
|
|
22
|
+
inputId: string | undefined;
|
|
23
|
+
tabindex: number | undefined;
|
|
24
|
+
autofocus: boolean | undefined;
|
|
25
|
+
onChange: EventEmitter<ToggleButtonChangeEvent>;
|
|
26
|
+
modelValue: boolean;
|
|
27
|
+
private _onChange;
|
|
28
|
+
private _onTouched;
|
|
29
|
+
get primeSize(): 'small' | 'large' | undefined;
|
|
30
|
+
get extraClasses(): Record<string, boolean>;
|
|
31
|
+
onChangeHandler(event: ToggleButtonChangeEvent): void;
|
|
32
|
+
writeValue(value: any): void;
|
|
33
|
+
registerOnChange(fn: (value: any) => void): void;
|
|
34
|
+
registerOnTouched(fn: () => void): void;
|
|
35
|
+
setDisabledState(isDisabled: boolean): void;
|
|
36
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ExtraToggleButtonComponent, never>;
|
|
37
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ExtraToggleButtonComponent, "extra-toggle-button", never, { "onLabel": { "alias": "onLabel"; "required": false; }; "offLabel": { "alias": "offLabel"; "required": false; }; "onIcon": { "alias": "onIcon"; "required": false; }; "offIcon": { "alias": "offIcon"; "required": false; }; "iconPos": { "alias": "iconPos"; "required": false; }; "size": { "alias": "size"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "iconOnly": { "alias": "iconOnly"; "required": false; }; "allowEmpty": { "alias": "allowEmpty"; "required": false; }; "fluid": { "alias": "fluid"; "required": false; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; }; "ariaLabelledBy": { "alias": "ariaLabelledBy"; "required": false; }; "inputId": { "alias": "inputId"; "required": false; }; "tabindex": { "alias": "tabindex"; "required": false; }; "autofocus": { "alias": "autofocus"; "required": false; }; }, { "onChange": "onChange"; }, never, never, true, never>;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export { ExtraToggleButtonComponent };
|
|
41
|
+
export type { ExtraToggleButtonSize };
|
|
@@ -7,7 +7,7 @@ class ExtraAvatarComponent {
|
|
|
7
7
|
label = '';
|
|
8
8
|
icon = '';
|
|
9
9
|
image = '';
|
|
10
|
-
size = '
|
|
10
|
+
size = 'base';
|
|
11
11
|
shape = 'square';
|
|
12
12
|
get hostClass() {
|
|
13
13
|
const classes = ['ui-avatar'];
|
|
@@ -18,7 +18,7 @@ class ExtraAvatarComponent {
|
|
|
18
18
|
return classes.join(' ');
|
|
19
19
|
}
|
|
20
20
|
get primeSize() {
|
|
21
|
-
return this.size === '
|
|
21
|
+
return this.size === 'base' ? undefined : this.size;
|
|
22
22
|
}
|
|
23
23
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ExtraAvatarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
24
24
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.15", type: ExtraAvatarComponent, isStandalone: true, selector: "extra-avatar", inputs: { label: "label", icon: "icon", image: "image", size: "size", shape: "shape" }, host: { properties: { "class": "this.hostClass" } }, ngImport: i0, template: `
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cdek-it-angular-ui-kit-components-avatar.mjs","sources":["../../src/lib/components/avatar/avatar.component.ts","../../src/lib/components/avatar/cdek-it-angular-ui-kit-components-avatar.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, HostBinding, Input } from '@angular/core';\nimport { Avatar } from 'primeng/avatar';\nimport { AvatarGroup } from 'primeng/avatargroup';\n\nexport type ExtraAvatarSize = '
|
|
1
|
+
{"version":3,"file":"cdek-it-angular-ui-kit-components-avatar.mjs","sources":["../../src/lib/components/avatar/avatar.component.ts","../../src/lib/components/avatar/cdek-it-angular-ui-kit-components-avatar.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, HostBinding, Input } from '@angular/core';\nimport { Avatar } from 'primeng/avatar';\nimport { AvatarGroup } from 'primeng/avatargroup';\n\nexport type ExtraAvatarSize = 'base' | 'large' | 'xlarge';\nexport type ExtraAvatarShape = 'square' | 'circle';\n\n@Component({\n selector: 'extra-avatar',\n standalone: true,\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [Avatar],\n template: `\n <p-avatar\n [label]=\"label || undefined\"\n [icon]=\"icon || undefined\"\n [image]=\"image || undefined\"\n [size]=\"primeSize\"\n [shape]=\"shape\"\n ></p-avatar>\n `\n})\nexport class ExtraAvatarComponent {\n @Input() label = '';\n @Input() icon = '';\n @Input() image = '';\n @Input() size: ExtraAvatarSize = 'base';\n @Input() shape: ExtraAvatarShape = 'square';\n\n @HostBinding('class') get hostClass(): string {\n const classes = ['ui-avatar'];\n if (this.size === 'large') classes.push('ui-avatar-lg');\n if (this.size === 'xlarge') classes.push('ui-avatar-xl');\n return classes.join(' ');\n }\n\n get primeSize(): 'large' | 'xlarge' | undefined {\n return this.size === 'base' ? undefined : this.size;\n }\n}\n\n@Component({\n selector: 'extra-avatar-group',\n standalone: true,\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [AvatarGroup],\n template: `\n <p-avatar-group>\n <ng-content></ng-content>\n </p-avatar-group>\n `\n})\nexport class ExtraAvatarGroupComponent {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;MAsBa,oBAAoB,CAAA;IACtB,KAAK,GAAG,EAAE;IACV,IAAI,GAAG,EAAE;IACT,KAAK,GAAG,EAAE;IACV,IAAI,GAAoB,MAAM;IAC9B,KAAK,GAAqB,QAAQ;AAE3C,IAAA,IAA0B,SAAS,GAAA;AACjC,QAAA,MAAM,OAAO,GAAG,CAAC,WAAW,CAAC;AAC7B,QAAA,IAAI,IAAI,CAAC,IAAI,KAAK,OAAO;AAAE,YAAA,OAAO,CAAC,IAAI,CAAC,cAAc,CAAC;AACvD,QAAA,IAAI,IAAI,CAAC,IAAI,KAAK,QAAQ;AAAE,YAAA,OAAO,CAAC,IAAI,CAAC,cAAc,CAAC;AACxD,QAAA,OAAO,OAAO,CAAC,IAAI,CAAC,GAAG,CAAC;IAC1B;AAEA,IAAA,IAAI,SAAS,GAAA;AACX,QAAA,OAAO,IAAI,CAAC,IAAI,KAAK,MAAM,GAAG,SAAS,GAAG,IAAI,CAAC,IAAI;IACrD;wGAhBW,oBAAoB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA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AyB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAzB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,yBAAyB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,oBAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EAN1B;;;;AAIT,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EALS,WAAW,EAAA,QAAA,EAAA,8CAAA,EAAA,MAAA,EAAA,CAAA,YAAA,EAAA,OAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;4FAOV,yBAAyB,EAAA,UAAA,EAAA,CAAA;kBAXrC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,oBAAoB;AAC9B,oBAAA,UAAU,EAAE,IAAI;oBAChB,eAAe,EAAE,uBAAuB,CAAC,MAAM;oBAC/C,OAAO,EAAE,CAAC,WAAW,CAAC;AACtB,oBAAA,QAAQ,EAAE;;;;AAIT,EAAA;AACF,iBAAA;;;ACnDD;;AAEG;;;;"}
|
|
@@ -8,7 +8,7 @@ class ExtraButtonComponent {
|
|
|
8
8
|
severity = null;
|
|
9
9
|
size = 'base';
|
|
10
10
|
rounded = false;
|
|
11
|
-
|
|
11
|
+
iconPosition = null;
|
|
12
12
|
iconOnly = false;
|
|
13
13
|
icon = '';
|
|
14
14
|
disabled = false;
|
|
@@ -28,8 +28,8 @@ class ExtraButtonComponent {
|
|
|
28
28
|
return 'large';
|
|
29
29
|
return undefined;
|
|
30
30
|
}
|
|
31
|
-
get
|
|
32
|
-
return this.
|
|
31
|
+
get primeIconPosition() {
|
|
32
|
+
return this.iconPosition === 'postfix' ? 'right' : 'left';
|
|
33
33
|
}
|
|
34
34
|
get primeSeverity() {
|
|
35
35
|
if (this.variant === 'secondary')
|
|
@@ -44,7 +44,7 @@ class ExtraButtonComponent {
|
|
|
44
44
|
return this.badgeSeverity;
|
|
45
45
|
}
|
|
46
46
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ExtraButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
47
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.15", type: ExtraButtonComponent, isStandalone: true, selector: "extra-button", inputs: { label: "label", variant: "variant", severity: "severity", size: "size", rounded: "rounded",
|
|
47
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.15", type: ExtraButtonComponent, isStandalone: true, selector: "extra-button", inputs: { label: "label", variant: "variant", severity: "severity", size: "size", rounded: "rounded", iconPosition: "iconPosition", iconOnly: "iconOnly", icon: "icon", disabled: "disabled", loading: "loading", badge: "badge", badgeSeverity: "badgeSeverity", showBadge: "showBadge", fluid: "fluid", ariaLabel: "ariaLabel", autofocus: "autofocus", tabindex: "tabindex", text: "text" }, ngImport: i0, template: `
|
|
48
48
|
<p-button
|
|
49
49
|
[label]="iconOnly ? '' : label"
|
|
50
50
|
[disabled]="disabled"
|
|
@@ -52,11 +52,11 @@ class ExtraButtonComponent {
|
|
|
52
52
|
[size]="primeSize"
|
|
53
53
|
[styleClass]="size === 'xlarge' ? 'p-button-xlg' : ''"
|
|
54
54
|
[rounded]="rounded"
|
|
55
|
-
[outlined]="variant === '
|
|
55
|
+
[outlined]="variant === 'tertiary'"
|
|
56
56
|
[text]="variant === 'text' || text"
|
|
57
57
|
[link]="variant === 'link'"
|
|
58
58
|
[icon]="icon"
|
|
59
|
-
[iconPos]="
|
|
59
|
+
[iconPos]="primeIconPosition"
|
|
60
60
|
[severity]="primeSeverity"
|
|
61
61
|
[badge]="showBadge ? badge || ' ' : undefined"
|
|
62
62
|
[badgeSeverity]="primeBadgeSeverity"
|
|
@@ -82,11 +82,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImpo
|
|
|
82
82
|
[size]="primeSize"
|
|
83
83
|
[styleClass]="size === 'xlarge' ? 'p-button-xlg' : ''"
|
|
84
84
|
[rounded]="rounded"
|
|
85
|
-
[outlined]="variant === '
|
|
85
|
+
[outlined]="variant === 'tertiary'"
|
|
86
86
|
[text]="variant === 'text' || text"
|
|
87
87
|
[link]="variant === 'link'"
|
|
88
88
|
[icon]="icon"
|
|
89
|
-
[iconPos]="
|
|
89
|
+
[iconPos]="primeIconPosition"
|
|
90
90
|
[severity]="primeSeverity"
|
|
91
91
|
[badge]="showBadge ? badge || ' ' : undefined"
|
|
92
92
|
[badgeSeverity]="primeBadgeSeverity"
|
|
@@ -107,7 +107,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImpo
|
|
|
107
107
|
type: Input
|
|
108
108
|
}], rounded: [{
|
|
109
109
|
type: Input
|
|
110
|
-
}],
|
|
110
|
+
}], iconPosition: [{
|
|
111
111
|
type: Input
|
|
112
112
|
}], iconOnly: [{
|
|
113
113
|
type: Input
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cdek-it-angular-ui-kit-components-button.mjs","sources":["../../src/lib/components/button/button.component.ts","../../src/lib/components/button/cdek-it-angular-ui-kit-components-button.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\nimport { Button, ButtonSeverity as PrimeButtonSeverity } from 'primeng/button';\n\nexport type ExtraButtonVariant = 'primary' | 'secondary' | '
|
|
1
|
+
{"version":3,"file":"cdek-it-angular-ui-kit-components-button.mjs","sources":["../../src/lib/components/button/button.component.ts","../../src/lib/components/button/cdek-it-angular-ui-kit-components-button.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\nimport { Button, ButtonSeverity as PrimeButtonSeverity } from 'primeng/button';\n\nexport type ExtraButtonVariant = 'primary' | 'secondary' | 'tertiary' | 'text' | 'link';\nexport type ExtraButtonSeverity = 'success' | 'warning' | 'danger' | 'info' | null;\nexport type ExtraButtonSize = 'small' | 'base' | 'large' | 'xlarge';\nexport type ExtraButtonIconPosition = 'prefix' | 'postfix' | null;\nexport type ExtraBadgeSeverity = 'success' | 'info' | 'warning' | 'danger' | 'secondary' | 'contrast' | null;\ntype PrimeBadgeSeverity = Extract<Button['badgeSeverity'], string | null>;\ntype ExtraButtonSeverityValue = PrimeButtonSeverity;\ntype ExtraBadgeSeverityValue = PrimeBadgeSeverity;\n\n@Component({\n selector: 'extra-button',\n standalone: true,\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [Button],\n template: `\n <p-button\n [label]=\"iconOnly ? '' : label\"\n [disabled]=\"disabled\"\n [loading]=\"loading\"\n [size]=\"primeSize\"\n [styleClass]=\"size === 'xlarge' ? 'p-button-xlg' : ''\"\n [rounded]=\"rounded\"\n [outlined]=\"variant === 'tertiary'\"\n [text]=\"variant === 'text' || text\"\n [link]=\"variant === 'link'\"\n [icon]=\"icon\"\n [iconPos]=\"primeIconPosition\"\n [severity]=\"primeSeverity\"\n [badge]=\"showBadge ? badge || ' ' : undefined\"\n [badgeSeverity]=\"primeBadgeSeverity\"\n [fluid]=\"fluid\"\n [ariaLabel]=\"ariaLabel\"\n [autofocus]=\"autofocus\"\n [tabindex]=\"tabindex\"\n ></p-button>\n `\n})\nexport class ExtraButtonComponent {\n @Input() label = 'Button';\n @Input() variant: ExtraButtonVariant = 'primary';\n @Input() severity: ExtraButtonSeverity = null;\n @Input() size: ExtraButtonSize = 'base';\n @Input() rounded = false;\n @Input() iconPosition: ExtraButtonIconPosition = null;\n @Input() iconOnly = false;\n @Input() icon = '';\n @Input() disabled = false;\n @Input() loading = false;\n @Input() badge = '';\n @Input() badgeSeverity: ExtraBadgeSeverity = null;\n @Input() showBadge = false;\n @Input() fluid = false;\n @Input() ariaLabel: string | undefined = undefined;\n @Input() autofocus = false;\n @Input() tabindex: number | undefined = undefined;\n @Input() text = false;\n\n get primeSize(): 'small' | 'large' | undefined {\n if (this.size === 'small') return 'small';\n if (this.size === 'large') return 'large';\n return undefined;\n }\n\n get primeIconPosition(): 'left' | 'right' {\n return this.iconPosition === 'postfix' ? 'right' : 'left';\n }\n\n get primeSeverity(): ExtraButtonSeverityValue | null {\n if (this.variant === 'secondary') return 'secondary';\n if (this.severity === 'warning') return 'warn';\n return this.severity;\n }\n\n get primeBadgeSeverity(): ExtraBadgeSeverityValue {\n if (this.badgeSeverity === 'warning') return 'warn';\n return this.badgeSeverity;\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;MAwCa,oBAAoB,CAAA;IACtB,KAAK,GAAG,QAAQ;IAChB,OAAO,GAAuB,SAAS;IACvC,QAAQ,GAAwB,IAAI;IACpC,IAAI,GAAoB,MAAM;IAC9B,OAAO,GAAG,KAAK;IACf,YAAY,GAA4B,IAAI;IAC5C,QAAQ,GAAG,KAAK;IAChB,IAAI,GAAG,EAAE;IACT,QAAQ,GAAG,KAAK;IAChB,OAAO,GAAG,KAAK;IACf,KAAK,GAAG,EAAE;IACV,aAAa,GAAuB,IAAI;IACxC,SAAS,GAAG,KAAK;IACjB,KAAK,GAAG,KAAK;IACb,SAAS,GAAuB,SAAS;IACzC,SAAS,GAAG,KAAK;IACjB,QAAQ,GAAuB,SAAS;IACxC,IAAI,GAAG,KAAK;AAErB,IAAA,IAAI,SAAS,GAAA;AACX,QAAA,IAAI,IAAI,CAAC,IAAI,KAAK,OAAO;AAAE,YAAA,OAAO,OAAO;AACzC,QAAA,IAAI,IAAI,CAAC,IAAI,KAAK,OAAO;AAAE,YAAA,OAAO,OAAO;AACzC,QAAA,OAAO,SAAS;IAClB;AAEA,IAAA,IAAI,iBAAiB,GAA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42
|
-
|
|
42
|
+
warning: 'p-confirm-dialog-warn',
|
|
43
43
|
help: 'p-confirm-dialog-help',
|
|
44
44
|
danger: 'p-confirm-dialog-error',
|
|
45
45
|
default: ''
|
|
@@ -95,7 +95,7 @@ class ExtraConfirmDialogComponent {
|
|
|
95
95
|
}
|
|
96
96
|
</ng-template>
|
|
97
97
|
</p-confirmDialog>
|
|
98
|
-
`, isInline: true, dependencies: [{ kind: "component", type: ConfirmDialog, selector: "p-confirmDialog, p-confirmdialog, p-confirm-dialog", inputs: ["header", "icon", "message", "style", "styleClass", "maskStyleClass", "acceptIcon", "acceptLabel", "closeAriaLabel", "acceptAriaLabel", "acceptVisible", "rejectIcon", "rejectLabel", "rejectAriaLabel", "rejectVisible", "acceptButtonStyleClass", "rejectButtonStyleClass", "closeOnEscape", "dismissableMask", "blockScroll", "rtl", "closable", "appendTo", "key", "autoZIndex", "baseZIndex", "transitionOptions", "focusTrap", "defaultFocus", "breakpoints", "modal", "visible", "position", "draggable"], outputs: ["onHide"] }, { kind: "component", type: ExtraButtonComponent, selector: "extra-button", inputs: ["label", "variant", "severity", "size", "rounded", "
|
|
98
|
+
`, isInline: true, dependencies: [{ kind: "component", type: ConfirmDialog, selector: "p-confirmDialog, p-confirmdialog, p-confirm-dialog", inputs: ["header", "icon", "message", "style", "styleClass", "maskStyleClass", "acceptIcon", "acceptLabel", "closeAriaLabel", "acceptAriaLabel", "acceptVisible", "rejectIcon", "rejectLabel", "rejectAriaLabel", "rejectVisible", "acceptButtonStyleClass", "rejectButtonStyleClass", "closeOnEscape", "dismissableMask", "blockScroll", "rtl", "closable", "appendTo", "key", "autoZIndex", "baseZIndex", "transitionOptions", "focusTrap", "defaultFocus", "breakpoints", "modal", "visible", "position", "draggable"], outputs: ["onHide"] }, { kind: "component", type: ExtraButtonComponent, selector: "extra-button", inputs: ["label", "variant", "severity", "size", "rounded", "iconPosition", "iconOnly", "icon", "disabled", "loading", "badge", "badgeSeverity", "showBadge", "fluid", "ariaLabel", "autofocus", "tabindex", "text"] }, { kind: "directive", type: PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] });
|
|
99
99
|
}
|
|
100
100
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.15", ngImport: i0, type: ExtraConfirmDialogComponent, decorators: [{
|
|
101
101
|
type: Component,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cdek-it-angular-ui-kit-components-confirm-dialog.mjs","sources":["../../src/lib/components/confirm-dialog/confirm-dialog.component.ts","../../src/lib/components/confirm-dialog/confirm-dialog.service.ts","../../src/lib/components/confirm-dialog/cdek-it-angular-ui-kit-components-confirm-dialog.ts"],"sourcesContent":["import { Component, ContentChild, Directive, Input, TemplateRef } from '@angular/core';\nimport { NgTemplateOutlet } from '@angular/common';\nimport { ConfirmDialog } from 'primeng/confirmdialog';\nimport { PrimeTemplate } from 'primeng/api';\nimport { ExtraButtonComponent } from '@cdek-it/angular-ui-kit/components/button';\n\nexport type ExtraConfirmDialogSize = 'sm' | 'default' | 'lg' | 'xlg';\nexport type ExtraConfirmDialogSeverity = 'success' | 'info' | '
|
|
1
|
+
{"version":3,"file":"cdek-it-angular-ui-kit-components-confirm-dialog.mjs","sources":["../../src/lib/components/confirm-dialog/confirm-dialog.component.ts","../../src/lib/components/confirm-dialog/confirm-dialog.service.ts","../../src/lib/components/confirm-dialog/cdek-it-angular-ui-kit-components-confirm-dialog.ts"],"sourcesContent":["import { Component, ContentChild, Directive, Input, TemplateRef } from '@angular/core';\nimport { NgTemplateOutlet } from '@angular/common';\nimport { ConfirmDialog } from 'primeng/confirmdialog';\nimport { PrimeTemplate } from 'primeng/api';\nimport { ExtraButtonComponent } from '@cdek-it/angular-ui-kit/components/button';\n\nexport type ExtraConfirmDialogSize = 'sm' | 'default' | 'lg' | 'xlg';\nexport type ExtraConfirmDialogSeverity = 'success' | 'info' | 'warning' | 'help' | 'danger' | 'default';\n\n@Directive({ selector: '[extraConfirmDialogHeader]', standalone: true })\nexport class ExtraConfirmDialogHeaderDirective {}\n\n@Directive({ selector: '[extraConfirmDialogFooter]', standalone: true })\nexport class ExtraConfirmDialogFooterDirective {}\n\n@Component({\n selector: 'extra-confirm-dialog',\n host: { style: 'display: contents' },\n standalone: true,\n imports: [ConfirmDialog, ExtraButtonComponent, PrimeTemplate, NgTemplateOutlet],\n template: `\n <p-confirmDialog [key]=\"key\" [styleClass]=\"computedClass\" appendTo=\"body\">\n <ng-template pTemplate=\"headless\" let-message let-onAccept=\"onAccept\" let-onReject=\"onReject\">\n @if (headerTemplate) {\n <ng-container\n [ngTemplateOutlet]=\"headerTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: message, onAccept, onReject }\"\n >\n </ng-container>\n } @else {\n <div class=\"p-dialog-header\">\n <div class=\"p-dialog-title\">\n <i [class]=\"message.icon\"></i>\n <span>{{ message.header }}</span>\n </div>\n <extra-button\n styleClass=\"p-dialog-close-button\"\n variant=\"text\"\n icon=\"ti ti-x\"\n [rounded]=\"true\"\n [iconOnly]=\"true\"\n (click)=\"onReject()\"\n ></extra-button>\n </div>\n }\n <div class=\"p-dialog-content\">\n <p>{{ message.message }}</p>\n </div>\n @if (footerTemplate) {\n <ng-container\n [ngTemplateOutlet]=\"footerTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: message, onAccept, onReject }\"\n >\n </ng-container>\n } @else {\n <div class=\"p-dialog-footer\">\n <extra-button [label]=\"message.rejectLabel\" variant=\"text\" (click)=\"onReject()\"></extra-button>\n <extra-button\n [label]=\"message.acceptLabel\"\n [severity]=\"message.acceptButtonProps?.severity\"\n (click)=\"onAccept()\"\n ></extra-button>\n </div>\n }\n </ng-template>\n </p-confirmDialog>\n `\n})\nexport class ExtraConfirmDialogComponent {\n @Input() key = '';\n @Input() size: ExtraConfirmDialogSize = 'default';\n @Input() severity: ExtraConfirmDialogSeverity = 'default';\n @ContentChild(ExtraConfirmDialogHeaderDirective, { read: TemplateRef }) headerTemplate: TemplateRef<any> | null =\n null;\n @ContentChild(ExtraConfirmDialogFooterDirective, { read: TemplateRef }) footerTemplate: TemplateRef<any> | null =\n null;\n\n get computedClass(): string {\n const classes: string[] = [];\n if (this.size === 'sm') classes.push('p-confirmdialog-sm');\n else if (this.size === 'lg') classes.push('p-confirmdialog-lg');\n else if (this.size === 'xlg') classes.push('p-confirmdialog-xlg');\n\n const severityMap: Record<ExtraConfirmDialogSeverity, string> = {\n success: 'p-confirm-dialog-accept',\n info: 'p-confirm-dialog-info',\n warning: 'p-confirm-dialog-warn',\n help: 'p-confirm-dialog-help',\n danger: 'p-confirm-dialog-error',\n default: ''\n };\n if (severityMap[this.severity]) classes.push(severityMap[this.severity]);\n\n return classes.join(' ');\n }\n}\n","import { Injectable, Provider } from '@angular/core';\nimport { Confirmation, ConfirmationService } from 'primeng/api';\n\nexport type ExtraConfirmDialogOptions = Pick<\n Confirmation,\n 'key' | 'message' | 'header' | 'icon' | 'acceptLabel' | 'rejectLabel' | 'accept' | 'reject' | 'acceptButtonProps'\n>;\n\nexport function provideExtraConfirmDialog(): Provider[] {\n return [ConfirmationService, ExtraConfirmDialogService];\n}\n\n@Injectable()\nexport class ExtraConfirmDialogService {\n constructor(private readonly confirmationService: ConfirmationService) {}\n\n confirm(options: ExtraConfirmDialogOptions): void {\n this.confirmationService.confirm(options);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;MAUa,iCAAiC,CAAA;wGAAjC,iCAAiC,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;4FAAjC,iCAAiC,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,4BAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;4F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