@tekus/design-system 5.1.3 → 5.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/readme-images/tk-modal-anatomy.png +0 -0
- package/assets/readme-images/tk-modal-basic.png +0 -0
- package/assets/readme-images/tk-modal-full.png +0 -0
- package/components/modal/index.d.ts +5 -0
- package/components/modal/public-api.d.ts +3 -0
- package/components/modal/src/modal.component.d.ts +83 -0
- package/components/modal/src/modal.types.d.ts +16 -0
- package/components/modal/src/services/modal.service.d.ts +16 -0
- package/fesm2022/tekus-design-system-components-button.mjs +2 -2
- package/fesm2022/tekus-design-system-components-button.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-fallback-view.mjs +2 -2
- package/fesm2022/tekus-design-system-components-fallback-view.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-modal.mjs +178 -0
- package/fesm2022/tekus-design-system-components-modal.mjs.map +1 -0
- package/fesm2022/tekus-design-system-core-types.mjs +82 -60
- package/fesm2022/tekus-design-system-core-types.mjs.map +1 -1
- package/fesm2022/tekus-design-system-core.mjs +82 -60
- package/fesm2022/tekus-design-system-core.mjs.map +1 -1
- package/package.json +8 -4
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { EventEmitter } from '@angular/core';
|
|
2
|
+
import { ModalFooterButton, ModalSizeType } from './modal.types';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
/**
|
|
5
|
+
* @component ModalComponent
|
|
6
|
+
* @description
|
|
7
|
+
* A programmatically controlled modal dialog used for displaying dynamic content, titles, and footer actions.
|
|
8
|
+
* The modal is not instantiated via template bindings, but rather opened through a service with a configuration object.
|
|
9
|
+
*
|
|
10
|
+
* This component supports:
|
|
11
|
+
* - Configurable title and content.
|
|
12
|
+
* - Optional footer buttons with callbacks and return values.
|
|
13
|
+
* - Multiple sizes: `'small' | 'large' | 'full'`.
|
|
14
|
+
* - Closable modal and outside-click behavior.
|
|
15
|
+
* - Passing arbitrary data to the modal instance.
|
|
16
|
+
*
|
|
17
|
+
* @usage
|
|
18
|
+
* ### Open a modal from TypeScript using the modal service
|
|
19
|
+
* ```ts
|
|
20
|
+
* this.modalService.open({
|
|
21
|
+
* title: 'Demo Modal',
|
|
22
|
+
* content: 'This modal is opened from TypeScript using the service.',
|
|
23
|
+
* footerButtons: [
|
|
24
|
+
* {
|
|
25
|
+
* label: 'Accept',
|
|
26
|
+
* severity: 'secondary',
|
|
27
|
+
* action: () => console.log('Accept clicked'),
|
|
28
|
+
* returnValue: true,
|
|
29
|
+
* },
|
|
30
|
+
* {
|
|
31
|
+
* label: 'Cancel',
|
|
32
|
+
* severity: 'danger',
|
|
33
|
+
* action: () => console.log('Cancel clicked'),
|
|
34
|
+
* returnValue: false,
|
|
35
|
+
* },
|
|
36
|
+
* ],
|
|
37
|
+
* size: 'small',
|
|
38
|
+
* closable: true,
|
|
39
|
+
* closeOnOutsideClick: false,
|
|
40
|
+
* }).subscribe((result) => {
|
|
41
|
+
* console.log('Modal closed with value:', result);
|
|
42
|
+
* });
|
|
43
|
+
* ```
|
|
44
|
+
*/
|
|
45
|
+
export declare class ModalComponent {
|
|
46
|
+
/** The title displayed at the top of the modal */
|
|
47
|
+
title: import("@angular/core").InputSignal<string>;
|
|
48
|
+
/** The main content of the modal */
|
|
49
|
+
content: import("@angular/core").InputSignal<string | null>;
|
|
50
|
+
/** Array of footer buttons with label, callback, and return value */
|
|
51
|
+
footerButtons: import("@angular/core").InputSignal<ModalFooterButton[]>;
|
|
52
|
+
/** Modal size: 'small', 'large', or 'full' */
|
|
53
|
+
size: import("@angular/core").InputSignal<ModalSizeType>;
|
|
54
|
+
/** Whether the modal can be closed by the user */
|
|
55
|
+
closable: import("@angular/core").InputSignal<boolean>;
|
|
56
|
+
/** Whether clicking outside closes the modal */
|
|
57
|
+
closeOnOutsideClick: import("@angular/core").InputSignal<boolean>;
|
|
58
|
+
/** Computed: whether the modal has footer buttons */
|
|
59
|
+
hasFooter: import("@angular/core").Signal<boolean>;
|
|
60
|
+
/** Computed: calculates modal width based on `size` */
|
|
61
|
+
modalWidth: import("@angular/core").Signal<"67.5rem" | "98vw" | "25rem">;
|
|
62
|
+
/** Visibility flag */
|
|
63
|
+
isOpened: boolean;
|
|
64
|
+
/** Emits when the modal closes, passing the return value from footer buttons or null */
|
|
65
|
+
readonly onClose: EventEmitter<unknown>;
|
|
66
|
+
private alreadyEmitted;
|
|
67
|
+
private returnValueOnClose;
|
|
68
|
+
/** Opens the modal */
|
|
69
|
+
open(): void;
|
|
70
|
+
/** Closes the modal and emits onClose with null */
|
|
71
|
+
handleClose(): void;
|
|
72
|
+
/** Closes the modal without emitting an event */
|
|
73
|
+
close(): void;
|
|
74
|
+
/**
|
|
75
|
+
* Handles footer button actions.
|
|
76
|
+
* Executes the action callback, emits `onClose` with the provided returnValue, then closes the modal.
|
|
77
|
+
* @param action Callback to execute when the button is clicked
|
|
78
|
+
* @param returnValue Value emitted on modal close
|
|
79
|
+
*/
|
|
80
|
+
handleAction(action: () => void, returnValue: unknown): void;
|
|
81
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ModalComponent, never>;
|
|
82
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ModalComponent, "tk-modal", never, { "title": { "alias": "title"; "required": false; "isSignal": true; }; "content": { "alias": "content"; "required": false; "isSignal": true; }; "footerButtons": { "alias": "footerButtons"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "closable": { "alias": "closable"; "required": false; "isSignal": true; }; "closeOnOutsideClick": { "alias": "closeOnOutsideClick"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
83
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export type ModalSizeType = 'small' | 'large' | 'full';
|
|
2
|
+
export type SeverityType = 'primary' | 'secondary' | 'danger';
|
|
3
|
+
export interface ModalFooterButton {
|
|
4
|
+
label: string;
|
|
5
|
+
severity: SeverityType;
|
|
6
|
+
action: () => void;
|
|
7
|
+
returnValue?: unknown;
|
|
8
|
+
}
|
|
9
|
+
export interface ModalConfig {
|
|
10
|
+
title: string;
|
|
11
|
+
content?: string;
|
|
12
|
+
footerButtons?: ModalFooterButton[];
|
|
13
|
+
size?: ModalSizeType;
|
|
14
|
+
closable?: boolean;
|
|
15
|
+
closeOnOutsideClick?: boolean;
|
|
16
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ApplicationRef, ComponentRef, Injector } from '@angular/core';
|
|
2
|
+
import { ModalComponent } from '../modal.component';
|
|
3
|
+
import { Observable } from 'rxjs';
|
|
4
|
+
import { ModalConfig } from '../modal.types';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
export declare class ModalService {
|
|
7
|
+
private readonly injector;
|
|
8
|
+
private readonly appRef;
|
|
9
|
+
private modalRef;
|
|
10
|
+
constructor(injector: Injector, appRef: ApplicationRef);
|
|
11
|
+
get _modalRefForTesting(): ComponentRef<ModalComponent> | null;
|
|
12
|
+
set _modalRefForTesting(ref: ComponentRef<ModalComponent> | null);
|
|
13
|
+
open(config: ModalConfig): Observable<unknown>;
|
|
14
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ModalService, never>;
|
|
15
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ModalService>;
|
|
16
|
+
}
|
|
@@ -102,11 +102,11 @@ class ButtonComponent {
|
|
|
102
102
|
this.clicked.emit('mouse');
|
|
103
103
|
}
|
|
104
104
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
105
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: ButtonComponent, isStandalone: true, selector: "tk-button", inputs: { label: "label", disabled: "disabled", type: "type", severity: "severity", link: "link" }, outputs: { clicked: "clicked" }, ngImport: i0, template: "<p-button\n class=\"tk-button\"\n [label]=\"label\"\n [disabled]=\"disabled\"\n [type]=\"type\"\n [severity]=\"link ? null : severity\"\n [link]=\"link\"\n (click)=\"onButtonClick()\"\n (keydown.enter)=\"onButtonClick()\"\n (keydown.space)=\"onButtonClick()\">\n</p-button>\n", styles: [":host ::ng-deep .p-button.p-button-primary .p-button-label,:host ::ng-deep .p-button.p-button-
|
|
105
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.15", type: ButtonComponent, isStandalone: true, selector: "tk-button", inputs: { label: "label", disabled: "disabled", type: "type", severity: "severity", link: "link" }, outputs: { clicked: "clicked" }, ngImport: i0, template: "<p-button\n class=\"tk-button\"\n [label]=\"label\"\n [disabled]=\"disabled\"\n [type]=\"type\"\n [severity]=\"link ? null : severity\"\n [link]=\"link\"\n (click)=\"onButtonClick()\"\n (keydown.enter)=\"onButtonClick()\"\n (keydown.space)=\"onButtonClick()\">\n</p-button>\n", styles: [":host ::ng-deep .p-button.p-button-primary .p-button-label,:host ::ng-deep .p-button.p-button-danger .p-button-label{color:var(--tk-color-base-surface-0, #ffffff)!important}:host ::ng-deep .p-button.p-button-link .p-button-label{color:var(--tk-color-base-primary-500, #16006f)!important}:host ::ng-deep .p-button.p-button-link:hover .p-button-label{color:var(--tk-color-base-primary-400, #45338c)!important}:host ::ng-deep .p-button.p-button-secondary .p-button-label{color:var(--tk-color-base-surface-500, #8a8a8b)!important}:host ::ng-deep .p-button.p-button-secondary .p-button-label,:host ::ng-deep .p-button.p-button-danger .p-button-label{font-weight:var(--tk-font-weight-400, 400)}\n"], dependencies: [{ kind: "ngmodule", type: ButtonModule }, { kind: "component", type: i1.Button, selector: "p-button", inputs: ["type", "iconPos", "icon", "badge", "label", "disabled", "loading", "loadingIcon", "raised", "rounded", "text", "plain", "severity", "outlined", "link", "tabindex", "size", "variant", "style", "styleClass", "badgeClass", "badgeSeverity", "ariaLabel", "autofocus", "fluid", "buttonProps"], outputs: ["onClick", "onFocus", "onBlur"] }] }); }
|
|
106
106
|
}
|
|
107
107
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ButtonComponent, decorators: [{
|
|
108
108
|
type: Component,
|
|
109
|
-
args: [{ selector: 'tk-button', standalone: true, imports: [ButtonModule], template: "<p-button\n class=\"tk-button\"\n [label]=\"label\"\n [disabled]=\"disabled\"\n [type]=\"type\"\n [severity]=\"link ? null : severity\"\n [link]=\"link\"\n (click)=\"onButtonClick()\"\n (keydown.enter)=\"onButtonClick()\"\n (keydown.space)=\"onButtonClick()\">\n</p-button>\n", styles: [":host ::ng-deep .p-button.p-button-primary .p-button-label,:host ::ng-deep .p-button.p-button-
|
|
109
|
+
args: [{ selector: 'tk-button', standalone: true, imports: [ButtonModule], template: "<p-button\n class=\"tk-button\"\n [label]=\"label\"\n [disabled]=\"disabled\"\n [type]=\"type\"\n [severity]=\"link ? null : severity\"\n [link]=\"link\"\n (click)=\"onButtonClick()\"\n (keydown.enter)=\"onButtonClick()\"\n (keydown.space)=\"onButtonClick()\">\n</p-button>\n", styles: [":host ::ng-deep .p-button.p-button-primary .p-button-label,:host ::ng-deep .p-button.p-button-danger .p-button-label{color:var(--tk-color-base-surface-0, #ffffff)!important}:host ::ng-deep .p-button.p-button-link .p-button-label{color:var(--tk-color-base-primary-500, #16006f)!important}:host ::ng-deep .p-button.p-button-link:hover .p-button-label{color:var(--tk-color-base-primary-400, #45338c)!important}:host ::ng-deep .p-button.p-button-secondary .p-button-label{color:var(--tk-color-base-surface-500, #8a8a8b)!important}:host ::ng-deep .p-button.p-button-secondary .p-button-label,:host ::ng-deep .p-button.p-button-danger .p-button-label{font-weight:var(--tk-font-weight-400, 400)}\n"] }]
|
|
110
110
|
}], propDecorators: { label: [{
|
|
111
111
|
type: Input
|
|
112
112
|
}], disabled: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tekus-design-system-components-button.mjs","sources":["../../../projects/design-system/components/button/src/button.component.ts","../../../projects/design-system/components/button/src/button.component.html","../../../projects/design-system/components/button/tekus-design-system-components-button.ts"],"sourcesContent":["import { Component, EventEmitter, Input, Output } from '@angular/core';\nimport { ButtonModule } from 'primeng/button';\n\nexport type ButtonSeverity = 'primary' | 'secondary' | 'danger';\n\n/**\n * @component ButtonComponent\n * @description\n * Atomic button component that provides a reusable and customizable button element\n * across the application.\n * It uses PrimeNG’s `ButtonModule` under the hood and allows setting different visual\n * variants (severity), button types, and disabled states.\n *\n * This component ensures consistent design and behavior in all button interactions.\n * It is accessible via both mouse clicks and keyboard actions (Enter/Space).\n *\n * @usage\n * ```html\n * <tk-button\n * label=\"Save\"\n * [severity]=\"'primary'\"\n * [type]=\"'submit'\"\n * (clicked)=\"handleSave()\">\n * </tk-button>\n *\n * <tk-button\n * label=\"Cancel\"\n * [severity]=\"'secondary'\"\n * [disabled]=\"true\">\n * </tk-button>\n * ```\n */\n@Component({\n selector: 'tk-button',\n standalone: true,\n imports: [ButtonModule],\n templateUrl: './button.component.html',\n styleUrls: ['./button.component.scss'],\n})\nexport class ButtonComponent {\n /**\n * @property {string} label\n * @description\n * Text displayed inside the button.\n *\n * @default `'Label'`\n */\n @Input() label = 'Label';\n\n /**\n * @property {boolean} disabled\n * @description\n * Disables the button, preventing user interaction and applying a visual style\n * that indicates the inactive state.\n *\n * @default `false`\n */\n @Input() disabled = false;\n\n /**\n * @property {'button' | 'submit'} type\n * @description\n * Defines the button’s HTML type attribute.\n * - `'button'`: Standard clickable button (default).\n * - `'submit'`: Used to submit forms.\n *\n * @default `'button'`\n */\n @Input() type: 'button' | 'submit' = 'button';\n\n /**\n * @property {ButtonSeverity} severity\n * @description\n * Defines the visual importance or style of the button.\n * - `'primary'`: Default, neutral action.\n * - `'secondary'`: Secondary option.\n * - `'danger'`: Destructive or warning actions.\n *\n * @default `'secondary'`\n */\n @Input() severity: ButtonSeverity = 'primary';\n\n /**\n * @property {boolean} link\n * @description\n * When true, the button will be styled as a link (text only with underline).\n *\n * @default false\n */\n @Input() link = false;\n\n /**\n * @event clicked\n * @description\n * Emits when the button is activated via click or keyboard (Enter/Space),\n * unless the button is disabled.\n *\n * @example\n * ```html\n * <tk-button label=\"Click me\" (clicked)=\"handleClick()\"></tk-button>\n * ```\n */\n @Output() clicked = new EventEmitter<'mouse' | 'keyboard'>();\n\n /**\n * @method onButtonClick\n * @description\n * Handles the native click event. Emits the `clicked` event if the button\n * is not disabled.\n */\n onButtonClick(): void {\n if (!this.disabled) this.clicked.emit('mouse');\n }\n}\n","<p-button\n class=\"tk-button\"\n [label]=\"label\"\n [disabled]=\"disabled\"\n [type]=\"type\"\n [severity]=\"link ? null : severity\"\n [link]=\"link\"\n (click)=\"onButtonClick()\"\n (keydown.enter)=\"onButtonClick()\"\n (keydown.space)=\"onButtonClick()\">\n</p-button>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAKA;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BG;MAQU,eAAe,CAAA;AAP5B,IAAA,WAAA,GAAA;AAQE;;;;;;AAMG;QACM,IAAK,CAAA,KAAA,GAAG,OAAO;AAExB;;;;;;;AAOG;QACM,IAAQ,CAAA,QAAA,GAAG,KAAK;AAEzB;;;;;;;;AAQG;QACM,IAAI,CAAA,IAAA,GAAwB,QAAQ;AAE7C;;;;;;;;;AASG;QACM,IAAQ,CAAA,QAAA,GAAmB,SAAS;AAE7C;;;;;;AAMG;QACM,IAAI,CAAA,IAAA,GAAG,KAAK;AAErB;;;;;;;;;;AAUG;AACO,QAAA,IAAA,CAAA,OAAO,GAAG,IAAI,YAAY,EAAwB;AAW7D;AATC;;;;;AAKG;IACH,aAAa,GAAA;QACX,IAAI,CAAC,IAAI,CAAC,QAAQ;AAAE,YAAA,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC;;+GAxErC,eAAe,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;mGAAf,eAAe,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,WAAA,EAAA,MAAA,EAAA,EAAA,KAAA,EAAA,OAAA,EAAA,QAAA,EAAA,UAAA,EAAA,IAAA,EAAA,MAAA,EAAA,QAAA,EAAA,UAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,OAAA,EAAA,EAAA,OAAA,EAAA,SAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,ECvC5B,8RAWA,EAAA,MAAA,EAAA,CAAA,
|
|
1
|
+
{"version":3,"file":"tekus-design-system-components-button.mjs","sources":["../../../projects/design-system/components/button/src/button.component.ts","../../../projects/design-system/components/button/src/button.component.html","../../../projects/design-system/components/button/tekus-design-system-components-button.ts"],"sourcesContent":["import { Component, EventEmitter, Input, Output } from '@angular/core';\nimport { ButtonModule } from 'primeng/button';\n\nexport type ButtonSeverity = 'primary' | 'secondary' | 'danger';\n\n/**\n * @component ButtonComponent\n * @description\n * Atomic button component that provides a reusable and customizable button element\n * across the application.\n * It uses PrimeNG’s `ButtonModule` under the hood and allows setting different visual\n * variants (severity), button types, and disabled states.\n *\n * This component ensures consistent design and behavior in all button interactions.\n * It is accessible via both mouse clicks and keyboard actions (Enter/Space).\n *\n * @usage\n * ```html\n * <tk-button\n * label=\"Save\"\n * [severity]=\"'primary'\"\n * [type]=\"'submit'\"\n * (clicked)=\"handleSave()\">\n * </tk-button>\n *\n * <tk-button\n * label=\"Cancel\"\n * [severity]=\"'secondary'\"\n * [disabled]=\"true\">\n * </tk-button>\n * ```\n */\n@Component({\n selector: 'tk-button',\n standalone: true,\n imports: [ButtonModule],\n templateUrl: './button.component.html',\n styleUrls: ['./button.component.scss'],\n})\nexport class ButtonComponent {\n /**\n * @property {string} label\n * @description\n * Text displayed inside the button.\n *\n * @default `'Label'`\n */\n @Input() label = 'Label';\n\n /**\n * @property {boolean} disabled\n * @description\n * Disables the button, preventing user interaction and applying a visual style\n * that indicates the inactive state.\n *\n * @default `false`\n */\n @Input() disabled = false;\n\n /**\n * @property {'button' | 'submit'} type\n * @description\n * Defines the button’s HTML type attribute.\n * - `'button'`: Standard clickable button (default).\n * - `'submit'`: Used to submit forms.\n *\n * @default `'button'`\n */\n @Input() type: 'button' | 'submit' = 'button';\n\n /**\n * @property {ButtonSeverity} severity\n * @description\n * Defines the visual importance or style of the button.\n * - `'primary'`: Default, neutral action.\n * - `'secondary'`: Secondary option.\n * - `'danger'`: Destructive or warning actions.\n *\n * @default `'secondary'`\n */\n @Input() severity: ButtonSeverity = 'primary';\n\n /**\n * @property {boolean} link\n * @description\n * When true, the button will be styled as a link (text only with underline).\n *\n * @default false\n */\n @Input() link = false;\n\n /**\n * @event clicked\n * @description\n * Emits when the button is activated via click or keyboard (Enter/Space),\n * unless the button is disabled.\n *\n * @example\n * ```html\n * <tk-button label=\"Click me\" (clicked)=\"handleClick()\"></tk-button>\n * ```\n */\n @Output() clicked = new EventEmitter<'mouse' | 'keyboard'>();\n\n /**\n * @method onButtonClick\n * @description\n * Handles the native click event. Emits the `clicked` event if the button\n * is not disabled.\n */\n onButtonClick(): void {\n if (!this.disabled) this.clicked.emit('mouse');\n }\n}\n","<p-button\n class=\"tk-button\"\n [label]=\"label\"\n [disabled]=\"disabled\"\n [type]=\"type\"\n [severity]=\"link ? null : severity\"\n [link]=\"link\"\n (click)=\"onButtonClick()\"\n (keydown.enter)=\"onButtonClick()\"\n (keydown.space)=\"onButtonClick()\">\n</p-button>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAKA;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BG;MAQU,eAAe,CAAA;AAP5B,IAAA,WAAA,GAAA;AAQE;;;;;;AAMG;QACM,IAAK,CAAA,KAAA,GAAG,OAAO;AAExB;;;;;;;AAOG;QACM,IAAQ,CAAA,QAAA,GAAG,KAAK;AA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AA,EAAA,OAAA,EAAA,YAAA,EAAA,YAAA,EAAA,eAAA,EAAA,WAAA,EAAA,WAAA,EAAA,OAAA,EAAA,aAAA,CAAA,EAAA,OAAA,EAAA,CAAA,SAAA,EAAA,SAAA,EAAA,QAAA,CAAA,EAAA,CAAA,EAAA,CAAA,CAAA;;4FAIX,eAAe,EAAA,UAAA,EAAA,CAAA;kBAP3B,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,WAAW,EACT,UAAA,EAAA,IAAI,EACP,OAAA,EAAA,CAAC,YAAY,CAAC,EAAA,QAAA,EAAA,8RAAA,EAAA,MAAA,EAAA,CAAA,orBAAA,CAAA,EAAA;8BAYd,KAAK,EAAA,CAAA;sBAAb;gBAUQ,QAAQ,EAAA,CAAA;sBAAhB;gBAWQ,IAAI,EAAA,CAAA;sBAAZ;gBAYQ,QAAQ,EAAA,CAAA;sBAAhB;gBASQ,IAAI,EAAA,CAAA;sBAAZ;gBAaS,OAAO,EAAA,CAAA;sBAAhB;;;AEtGH;;AAEG;;;;"}
|
|
@@ -163,11 +163,11 @@ class FallbackViewComponent {
|
|
|
163
163
|
this.linkAction.emit();
|
|
164
164
|
}
|
|
165
165
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: FallbackViewComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
166
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: FallbackViewComponent, isStandalone: true, selector: "tk-fallback-view", inputs: { type: "type", imageSrc: "imageSrc", illustrationAlt: "illustrationAlt", title: "title", message: "message", buttonLabel: "buttonLabel", linkLabel: "linkLabel", buttonDisabled: "buttonDisabled" }, outputs: { buttonAction: "buttonAction", linkAction: "linkAction" }, ngImport: i0, template: "<div\n class=\"tk-fallback-view\"\n [class.tk-fallback-view--section]=\"type === 'section'\">\n <ng-content select=\"[image]\"></ng-content>\n @if (imageSrc) {\n <img\n [src]=\"imageSrc\"\n [alt]=\"illustrationAlt || 'fallback illustration'\"\n class=\"tk-fallback-view__image\" />\n }\n\n <ng-content select=\"[title]\"></ng-content>\n @if (title && type === 'content') {\n <h2 class=\"tk-fallback-view__title\">{{ title }}</h2>\n }\n\n <ng-content select=\"[message]\"></ng-content>\n @if (message) {\n <p class=\"tk-fallback-view__message\" [innerHTML]=\"message\"></p>\n }\n\n <ng-content select=\"[actions]\"></ng-content>\n @if (type === 'content' && (buttonLabel || linkLabel)) {\n <div class=\"tk-fallback-view__actions\">\n @if (buttonLabel) {\n <tk-button\n [label]=\"buttonLabel\"\n severity=\"primary\"\n [disabled]=\"buttonDisabled\"\n (clicked)=\"onButtonActionClick()\" />\n } @if (linkLabel) {\n <tk-button\n [label]=\"linkLabel\"\n [link]=\"true\"\n (clicked)=\"onLinkActionClick()\" />\n }\n </div>\n }\n</div>\n", styles: [":host{display:block;width:100%}.tk-fallback-view{display:flex;flex-direction:column;align-items:center;text-align:center;gap:var(--tk-spacing-
|
|
166
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: FallbackViewComponent, isStandalone: true, selector: "tk-fallback-view", inputs: { type: "type", imageSrc: "imageSrc", illustrationAlt: "illustrationAlt", title: "title", message: "message", buttonLabel: "buttonLabel", linkLabel: "linkLabel", buttonDisabled: "buttonDisabled" }, outputs: { buttonAction: "buttonAction", linkAction: "linkAction" }, ngImport: i0, template: "<div\n class=\"tk-fallback-view\"\n [class.tk-fallback-view--section]=\"type === 'section'\">\n <ng-content select=\"[image]\"></ng-content>\n @if (imageSrc) {\n <img\n [src]=\"imageSrc\"\n [alt]=\"illustrationAlt || 'fallback illustration'\"\n class=\"tk-fallback-view__image\" />\n }\n\n <ng-content select=\"[title]\"></ng-content>\n @if (title && type === 'content') {\n <h2 class=\"tk-fallback-view__title\">{{ title }}</h2>\n }\n\n <ng-content select=\"[message]\"></ng-content>\n @if (message) {\n <p class=\"tk-fallback-view__message\" [innerHTML]=\"message\"></p>\n }\n\n <ng-content select=\"[actions]\"></ng-content>\n @if (type === 'content' && (buttonLabel || linkLabel)) {\n <div class=\"tk-fallback-view__actions\">\n @if (buttonLabel) {\n <tk-button\n [label]=\"buttonLabel\"\n severity=\"primary\"\n [disabled]=\"buttonDisabled\"\n (clicked)=\"onButtonActionClick()\" />\n } @if (linkLabel) {\n <tk-button\n [label]=\"linkLabel\"\n [link]=\"true\"\n (clicked)=\"onLinkActionClick()\" />\n }\n </div>\n }\n</div>\n", styles: [":host{display:block;width:100%}.tk-fallback-view{display:flex;flex-direction:column;align-items:center;text-align:center;gap:var(--tk-spacing-gap-m, 1rem);padding:var(--tk-spacing-paddingY-xl, 1.5rem) var(--tk-spacing-paddingY-m, 1rem);margin:0 auto}.tk-fallback-view__image,.tk-fallback-view>[image]{max-width:18.75rem;max-height:18.75rem;width:auto;height:auto;object-fit:contain;margin-bottom:var(--tk-spacing-base-150, 1.5rem)}.tk-fallback-view__title,.tk-fallback-view>[title]{font-size:var(--tk-font-size-base-150, 1.5rem);font-weight:var(--tk-font-weight-bold, 700);margin:0;max-width:31.25rem;color:var(--tk-color-base-surface-950, #191a1b)}.tk-fallback-view__message,.tk-fallback-view>[message]{font-size:var(--tk-font-size-base-100, 1rem);font-weight:var(--tk-font-weight-regular, 400);margin:0;max-width:31.25rem;color:var(--tk-color-base-surface-950, #191a1b)}.tk-fallback-view__actions,.tk-fallback-view>[actions]{display:flex;flex-direction:column;align-items:center;gap:var(--tk-spacing-75, .75rem)}.tk-fallback-view--section{flex-direction:row;justify-content:center;align-items:center;text-align:left;gap:var(--tk-spacing-gap-m, 1rem);width:100%;min-height:3.75rem;padding:var(--tk-spacing-paddingY-xl, 1.5rem) var(--tk-spacing-paddingY-m, 1rem);background-color:var(--tk-color-base-surface-0, #ffffff);color:var(--tk-color-base-surface-950, #191a1b)}.tk-fallback-view--section .tk-fallback-view__image,.tk-fallback-view--section>[image]{width:3.75rem;height:3.75rem;max-width:3.75rem;max-height:3.75rem;margin-bottom:0;object-fit:contain}.tk-fallback-view--section .tk-fallback-view__message,.tk-fallback-view--section>[message]{font-size:var(--tk-font-size-base-100, 1rem);font-weight:var(--tk-font-weight-regular, 400)}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: ButtonComponent, selector: "tk-button", inputs: ["label", "disabled", "type", "severity", "link"], outputs: ["clicked"] }, { kind: "ngmodule", type: CardModule }], encapsulation: i0.ViewEncapsulation.None }); }
|
|
167
167
|
}
|
|
168
168
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: FallbackViewComponent, decorators: [{
|
|
169
169
|
type: Component,
|
|
170
|
-
args: [{ selector: 'tk-fallback-view', standalone: true, imports: [CommonModule, ButtonComponent, CardModule], encapsulation: ViewEncapsulation.None, template: "<div\n class=\"tk-fallback-view\"\n [class.tk-fallback-view--section]=\"type === 'section'\">\n <ng-content select=\"[image]\"></ng-content>\n @if (imageSrc) {\n <img\n [src]=\"imageSrc\"\n [alt]=\"illustrationAlt || 'fallback illustration'\"\n class=\"tk-fallback-view__image\" />\n }\n\n <ng-content select=\"[title]\"></ng-content>\n @if (title && type === 'content') {\n <h2 class=\"tk-fallback-view__title\">{{ title }}</h2>\n }\n\n <ng-content select=\"[message]\"></ng-content>\n @if (message) {\n <p class=\"tk-fallback-view__message\" [innerHTML]=\"message\"></p>\n }\n\n <ng-content select=\"[actions]\"></ng-content>\n @if (type === 'content' && (buttonLabel || linkLabel)) {\n <div class=\"tk-fallback-view__actions\">\n @if (buttonLabel) {\n <tk-button\n [label]=\"buttonLabel\"\n severity=\"primary\"\n [disabled]=\"buttonDisabled\"\n (clicked)=\"onButtonActionClick()\" />\n } @if (linkLabel) {\n <tk-button\n [label]=\"linkLabel\"\n [link]=\"true\"\n (clicked)=\"onLinkActionClick()\" />\n }\n </div>\n }\n</div>\n", styles: [":host{display:block;width:100%}.tk-fallback-view{display:flex;flex-direction:column;align-items:center;text-align:center;gap:var(--tk-spacing-
|
|
170
|
+
args: [{ selector: 'tk-fallback-view', standalone: true, imports: [CommonModule, ButtonComponent, CardModule], encapsulation: ViewEncapsulation.None, template: "<div\n class=\"tk-fallback-view\"\n [class.tk-fallback-view--section]=\"type === 'section'\">\n <ng-content select=\"[image]\"></ng-content>\n @if (imageSrc) {\n <img\n [src]=\"imageSrc\"\n [alt]=\"illustrationAlt || 'fallback illustration'\"\n class=\"tk-fallback-view__image\" />\n }\n\n <ng-content select=\"[title]\"></ng-content>\n @if (title && type === 'content') {\n <h2 class=\"tk-fallback-view__title\">{{ title }}</h2>\n }\n\n <ng-content select=\"[message]\"></ng-content>\n @if (message) {\n <p class=\"tk-fallback-view__message\" [innerHTML]=\"message\"></p>\n }\n\n <ng-content select=\"[actions]\"></ng-content>\n @if (type === 'content' && (buttonLabel || linkLabel)) {\n <div class=\"tk-fallback-view__actions\">\n @if (buttonLabel) {\n <tk-button\n [label]=\"buttonLabel\"\n severity=\"primary\"\n [disabled]=\"buttonDisabled\"\n (clicked)=\"onButtonActionClick()\" />\n } @if (linkLabel) {\n <tk-button\n [label]=\"linkLabel\"\n [link]=\"true\"\n (clicked)=\"onLinkActionClick()\" />\n }\n </div>\n }\n</div>\n", styles: [":host{display:block;width:100%}.tk-fallback-view{display:flex;flex-direction:column;align-items:center;text-align:center;gap:var(--tk-spacing-gap-m, 1rem);padding:var(--tk-spacing-paddingY-xl, 1.5rem) var(--tk-spacing-paddingY-m, 1rem);margin:0 auto}.tk-fallback-view__image,.tk-fallback-view>[image]{max-width:18.75rem;max-height:18.75rem;width:auto;height:auto;object-fit:contain;margin-bottom:var(--tk-spacing-base-150, 1.5rem)}.tk-fallback-view__title,.tk-fallback-view>[title]{font-size:var(--tk-font-size-base-150, 1.5rem);font-weight:var(--tk-font-weight-bold, 700);margin:0;max-width:31.25rem;color:var(--tk-color-base-surface-950, #191a1b)}.tk-fallback-view__message,.tk-fallback-view>[message]{font-size:var(--tk-font-size-base-100, 1rem);font-weight:var(--tk-font-weight-regular, 400);margin:0;max-width:31.25rem;color:var(--tk-color-base-surface-950, #191a1b)}.tk-fallback-view__actions,.tk-fallback-view>[actions]{display:flex;flex-direction:column;align-items:center;gap:var(--tk-spacing-75, .75rem)}.tk-fallback-view--section{flex-direction:row;justify-content:center;align-items:center;text-align:left;gap:var(--tk-spacing-gap-m, 1rem);width:100%;min-height:3.75rem;padding:var(--tk-spacing-paddingY-xl, 1.5rem) var(--tk-spacing-paddingY-m, 1rem);background-color:var(--tk-color-base-surface-0, #ffffff);color:var(--tk-color-base-surface-950, #191a1b)}.tk-fallback-view--section .tk-fallback-view__image,.tk-fallback-view--section>[image]{width:3.75rem;height:3.75rem;max-width:3.75rem;max-height:3.75rem;margin-bottom:0;object-fit:contain}.tk-fallback-view--section .tk-fallback-view__message,.tk-fallback-view--section>[message]{font-size:var(--tk-font-size-base-100, 1rem);font-weight:var(--tk-font-weight-regular, 400)}\n"] }]
|
|
171
171
|
}], propDecorators: { type: [{
|
|
172
172
|
type: Input
|
|
173
173
|
}], imageSrc: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tekus-design-system-components-fallback-view.mjs","sources":["../../../projects/design-system/components/fallback-view/src/fallback-view.component.ts","../../../projects/design-system/components/fallback-view/src/fallback-view.component.html","../../../projects/design-system/components/fallback-view/tekus-design-system-components-fallback-view.ts"],"sourcesContent":["import {\n Component,\n EventEmitter,\n Input,\n Output,\n ViewEncapsulation,\n} from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ButtonComponent } from '@tekus/design-system/components/button';\nimport { CardModule } from 'primeng/card';\n\nexport type FallbackViewType = 'content' | 'section';\n\n/**\n * @component FallbackViewComponent\n * @description\n * A reusable component for displaying fallback or empty states such as\n * “no results found”, “error loading data”, or “content not available”.\n * It provides a consistent structure with support for an image, title,\n * message, and optional action buttons.\n *\n * The component can be used in two ways:\n * 1. **Via Inputs:** Pass data directly through component inputs (`imageSrc`, `title`, `message`, etc.).\n * 2. **Via Content Projection (`ng-content`):** Use your own HTML structure for full customization.\n *\n * @usage\n * ### Basic Usage (via Inputs)\n * ```html\n * <tk-fallback-view\n * imageSrc=\"assets/img/empty-state.svg\"\n * title=\"No Items Found\"\n * message=\"There are currently no items to display. Try adding one.\"\n * buttonLabel=\"Add New Item\"\n * linkLabel=\"Learn More\"\n * (buttonAction)=\"handleAddNewItem()\"\n * (linkAction)=\"handleLearnMore()\">\n * </tk-fallback-view>\n * ```\n *\n * ### Compact Variant (Section type)\n * ```html\n * <tk-fallback-view\n * [type]=\"'section'\"\n * imageSrc=\"assets/img/check.svg\"\n * message=\"Saved successfully\">\n * </tk-fallback-view>\n * ```\n *\n * ### Advanced Usage (via ng-content)\n * ```html\n * <tk-fallback-view [type]=\"'content'\">\n * <img image src=\"assets/img/empty-state.svg\" alt=\"Tekus logo\">\n * <h2 title>Custom Title</h2>\n * <p message>\n * This is a <b>custom message</b> with <strong>HTML content</strong>.\n * </p>\n * <div actions>\n * <tk-button\n * label=\"Primary Action\"\n * severity=\"primary\"\n * (click)=\"onPrimaryAction()\">\n * </tk-button>\n * <tk-button\n * label=\"Secondary Action\"\n * [link]=\"true\"\n * (click)=\"onSecondaryAction()\">\n * </tk-button>\n * </div>\n * </tk-fallback-view>\n * ```\n */\n\n@Component({\n selector: 'tk-fallback-view',\n standalone: true,\n imports: [CommonModule, ButtonComponent, CardModule],\n templateUrl: './fallback-view.component.html',\n styleUrl: './fallback-view.component.scss',\n encapsulation: ViewEncapsulation.None,\n})\nexport class FallbackViewComponent {\n /**\n * @property {FallbackViewType} type\n * @description\n * Controls the overall type and spacing of the component.\n * - `'content'`: Standard size.\n * - `'section'`: A more compact version.\n *\n * @default `'default'`\n */\n @Input() type: FallbackViewType = 'content';\n\n /**\n * @property {string} imageSrc\n * @description\n * The URL for the illustrative image to be displayed at the top.\n *\n * @default `''`\n */\n @Input() imageSrc = '';\n\n /**\n * @property {string} illustrationAlt\n * Descriptive alternative text for the image. Improves accessibility.\n */\n @Input() illustrationAlt = '';\n\n /**\n * @property {string} title\n * @description\n * The main title or heading of the fallback view.\n *\n * @default `''`\n */\n @Input() title = '';\n\n /**\n * @property {string} message\n * @description\n * The descriptive text or message displayed below the title.\n *\n * @default `''`\n */\n @Input() message = '';\n\n /**\n * @property {string} buttonLabel\n * @description\n * Text for the primary action button. If left empty, the button is not rendered.\n *\n * @default `''`\n */\n @Input() buttonLabel = '';\n\n /**\n * @property {string} linkLabel\n * @description\n * Text for the secondary action, which is styled as a link.\n * If left empty, the link is not rendered.\n *\n * @default `''`\n */\n @Input() linkLabel = '';\n\n /**\n * @property {boolean} buttonDisabled\n * @description\n * Controls whether the primary action button is disabled.\n * When true, the button is visually disabled and cannot be clicked.\n *\n * @default false\n */\n @Input() buttonDisabled = false;\n\n /**\n * @event buttonAction\n * @description\n * Emits when the main action button is clicked. Listen to this event\n * to handle the primary call-to-action.\n */\n @Output() buttonAction = new EventEmitter<void>();\n\n /**\n * @event linkAction\n * @description\n * Emits when the link-styled button is clicked. Use for secondary\n * or alternative actions.\n */\n @Output() linkAction = new EventEmitter<void>();\n\n /**\n * @method onButtonActionClick\n * @description\n * Internal handler that emits the `primaryAction` event when the\n * main button is clicked.\n */\n onButtonActionClick(): void {\n this.buttonAction.emit();\n }\n\n /**\n * @method onLinkActionClick\n * @description\n * Internal handler that emits the `linkAction` event when the\n * link button is clicked.\n */\n onLinkActionClick(): void {\n this.linkAction.emit();\n }\n}\n","<div\n class=\"tk-fallback-view\"\n [class.tk-fallback-view--section]=\"type === 'section'\">\n <ng-content select=\"[image]\"></ng-content>\n @if (imageSrc) {\n <img\n [src]=\"imageSrc\"\n [alt]=\"illustrationAlt || 'fallback illustration'\"\n class=\"tk-fallback-view__image\" />\n }\n\n <ng-content select=\"[title]\"></ng-content>\n @if (title && type === 'content') {\n <h2 class=\"tk-fallback-view__title\">{{ title }}</h2>\n }\n\n <ng-content select=\"[message]\"></ng-content>\n @if (message) {\n <p class=\"tk-fallback-view__message\" [innerHTML]=\"message\"></p>\n }\n\n <ng-content select=\"[actions]\"></ng-content>\n @if (type === 'content' && (buttonLabel || linkLabel)) {\n <div class=\"tk-fallback-view__actions\">\n @if (buttonLabel) {\n <tk-button\n [label]=\"buttonLabel\"\n severity=\"primary\"\n [disabled]=\"buttonDisabled\"\n (clicked)=\"onButtonActionClick()\" />\n } @if (linkLabel) {\n <tk-button\n [label]=\"linkLabel\"\n [link]=\"true\"\n (clicked)=\"onLinkActionClick()\" />\n }\n </div>\n }\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAaA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyDG;MAUU,qBAAqB,CAAA;AARlC,IAAA,WAAA,GAAA;AASE;;;;;;;;AAQG;QACM,IAAI,CAAA,IAAA,GAAqB,SAAS;AAE3C;;;;;;AAMG;QACM,IAAQ,CAAA,QAAA,GAAG,EAAE;AAEtB;;;AAGG;QACM,IAAe,CAAA,eAAA,GAAG,EAAE;AAE7B;;;;;;AAMG;QACM,IAAK,CAAA,KAAA,GAAG,EAAE;AAEnB;;;;;;AAMG;QACM,IAAO,CAAA,OAAA,GAAG,EAAE;AAErB;;;;;;AAMG;QACM,IAAW,CAAA,WAAA,GAAG,EAAE;AAEzB;;;;;;;AAOG;QACM,IAAS,CAAA,SAAA,GAAG,EAAE;AAEvB;;;;;;;AAOG;QACM,IAAc,CAAA,cAAA,GAAG,KAAK;AAE/B;;;;;AAKG;AACO,QAAA,IAAA,CAAA,YAAY,GAAG,IAAI,YAAY,EAAQ;AAEjD;;;;;AAKG;AACO,QAAA,IAAA,CAAA,UAAU,GAAG,IAAI,YAAY,EAAQ;AAqBhD;AAnBC;;;;;AAKG;IACH,mBAAmB,GAAA;AACjB,QAAA,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE;;AAG1B;;;;;AAKG;IACH,iBAAiB,GAAA;AACf,QAAA,IAAI,CAAC,UAAU,CAAC,IAAI,EAAE;;+GA3Gb,qBAAqB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAArB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,qBAAqB,+VChFlC,slCAuCA,EAAA,MAAA,EAAA,CAAA,
|
|
1
|
+
{"version":3,"file":"tekus-design-system-components-fallback-view.mjs","sources":["../../../projects/design-system/components/fallback-view/src/fallback-view.component.ts","../../../projects/design-system/components/fallback-view/src/fallback-view.component.html","../../../projects/design-system/components/fallback-view/tekus-design-system-components-fallback-view.ts"],"sourcesContent":["import {\n Component,\n EventEmitter,\n Input,\n Output,\n ViewEncapsulation,\n} from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ButtonComponent } from '@tekus/design-system/components/button';\nimport { CardModule } from 'primeng/card';\n\nexport type FallbackViewType = 'content' | 'section';\n\n/**\n * @component FallbackViewComponent\n * @description\n * A reusable component for displaying fallback or empty states such as\n * “no results found”, “error loading data”, or “content not available”.\n * It provides a consistent structure with support for an image, title,\n * message, and optional action buttons.\n *\n * The component can be used in two ways:\n * 1. **Via Inputs:** Pass data directly through component inputs (`imageSrc`, `title`, `message`, etc.).\n * 2. **Via Content Projection (`ng-content`):** Use your own HTML structure for full customization.\n *\n * @usage\n * ### Basic Usage (via Inputs)\n * ```html\n * <tk-fallback-view\n * imageSrc=\"assets/img/empty-state.svg\"\n * title=\"No Items Found\"\n * message=\"There are currently no items to display. Try adding one.\"\n * buttonLabel=\"Add New Item\"\n * linkLabel=\"Learn More\"\n * (buttonAction)=\"handleAddNewItem()\"\n * (linkAction)=\"handleLearnMore()\">\n * </tk-fallback-view>\n * ```\n *\n * ### Compact Variant (Section type)\n * ```html\n * <tk-fallback-view\n * [type]=\"'section'\"\n * imageSrc=\"assets/img/check.svg\"\n * message=\"Saved successfully\">\n * </tk-fallback-view>\n * ```\n *\n * ### Advanced Usage (via ng-content)\n * ```html\n * <tk-fallback-view [type]=\"'content'\">\n * <img image src=\"assets/img/empty-state.svg\" alt=\"Tekus logo\">\n * <h2 title>Custom Title</h2>\n * <p message>\n * This is a <b>custom message</b> with <strong>HTML content</strong>.\n * </p>\n * <div actions>\n * <tk-button\n * label=\"Primary Action\"\n * severity=\"primary\"\n * (click)=\"onPrimaryAction()\">\n * </tk-button>\n * <tk-button\n * label=\"Secondary Action\"\n * [link]=\"true\"\n * (click)=\"onSecondaryAction()\">\n * </tk-button>\n * </div>\n * </tk-fallback-view>\n * ```\n */\n\n@Component({\n selector: 'tk-fallback-view',\n standalone: true,\n imports: [CommonModule, ButtonComponent, CardModule],\n templateUrl: './fallback-view.component.html',\n styleUrl: './fallback-view.component.scss',\n encapsulation: ViewEncapsulation.None,\n})\nexport class FallbackViewComponent {\n /**\n * @property {FallbackViewType} type\n * @description\n * Controls the overall type and spacing of the component.\n * - `'content'`: Standard size.\n * - `'section'`: A more compact version.\n *\n * @default `'default'`\n */\n @Input() type: FallbackViewType = 'content';\n\n /**\n * @property {string} imageSrc\n * @description\n * The URL for the illustrative image to be displayed at the top.\n *\n * @default `''`\n */\n @Input() imageSrc = '';\n\n /**\n * @property {string} illustrationAlt\n * Descriptive alternative text for the image. Improves accessibility.\n */\n @Input() illustrationAlt = '';\n\n /**\n * @property {string} title\n * @description\n * The main title or heading of the fallback view.\n *\n * @default `''`\n */\n @Input() title = '';\n\n /**\n * @property {string} message\n * @description\n * The descriptive text or message displayed below the title.\n *\n * @default `''`\n */\n @Input() message = '';\n\n /**\n * @property {string} buttonLabel\n * @description\n * Text for the primary action button. If left empty, the button is not rendered.\n *\n * @default `''`\n */\n @Input() buttonLabel = '';\n\n /**\n * @property {string} linkLabel\n * @description\n * Text for the secondary action, which is styled as a link.\n * If left empty, the link is not rendered.\n *\n * @default `''`\n */\n @Input() linkLabel = '';\n\n /**\n * @property {boolean} buttonDisabled\n * @description\n * Controls whether the primary action button is disabled.\n * When true, the button is visually disabled and cannot be clicked.\n *\n * @default false\n */\n @Input() buttonDisabled = false;\n\n /**\n * @event buttonAction\n * @description\n * Emits when the main action button is clicked. Listen to this event\n * to handle the primary call-to-action.\n */\n @Output() buttonAction = new EventEmitter<void>();\n\n /**\n * @event linkAction\n * @description\n * Emits when the link-styled button is clicked. Use for secondary\n * or alternative actions.\n */\n @Output() linkAction = new EventEmitter<void>();\n\n /**\n * @method onButtonActionClick\n * @description\n * Internal handler that emits the `primaryAction` event when the\n * main button is clicked.\n */\n onButtonActionClick(): void {\n this.buttonAction.emit();\n }\n\n /**\n * @method onLinkActionClick\n * @description\n * Internal handler that emits the `linkAction` event when the\n * link button is clicked.\n */\n onLinkActionClick(): void {\n this.linkAction.emit();\n }\n}\n","<div\n class=\"tk-fallback-view\"\n [class.tk-fallback-view--section]=\"type === 'section'\">\n <ng-content select=\"[image]\"></ng-content>\n @if (imageSrc) {\n <img\n [src]=\"imageSrc\"\n [alt]=\"illustrationAlt || 'fallback illustration'\"\n class=\"tk-fallback-view__image\" />\n }\n\n <ng-content select=\"[title]\"></ng-content>\n @if (title && type === 'content') {\n <h2 class=\"tk-fallback-view__title\">{{ title }}</h2>\n }\n\n <ng-content select=\"[message]\"></ng-content>\n @if (message) {\n <p class=\"tk-fallback-view__message\" [innerHTML]=\"message\"></p>\n }\n\n <ng-content select=\"[actions]\"></ng-content>\n @if (type === 'content' && (buttonLabel || linkLabel)) {\n <div class=\"tk-fallback-view__actions\">\n @if (buttonLabel) {\n <tk-button\n [label]=\"buttonLabel\"\n severity=\"primary\"\n [disabled]=\"buttonDisabled\"\n (clicked)=\"onButtonActionClick()\" />\n } @if (linkLabel) {\n <tk-button\n [label]=\"linkLabel\"\n [link]=\"true\"\n (clicked)=\"onLinkActionClick()\" />\n }\n </div>\n }\n</div>\n","/**\n * Generated bundle index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A,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EDoCY,YAAY,EAAE,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,eAAe,sIAAE,UAAU,EAAA,CAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;;4FAKxC,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBARjC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,kBAAkB,EAChB,UAAA,EAAA,IAAI,EACP,OAAA,EAAA,CAAC,YAAY,EAAE,eAAe,EAAE,UAAU,CAAC,EAGrC,aAAA,EAAA,iBAAiB,CAAC,IAAI,EAAA,QAAA,EAAA,slCAAA,EAAA,MAAA,EAAA,CAAA,+sDAAA,CAAA,EAAA;8BAY5B,IAAI,EAAA,CAAA;sBAAZ;gBASQ,QAAQ,EAAA,CAAA;sBAAhB;gBAMQ,eAAe,EAAA,CAAA;sBAAvB;gBASQ,KAAK,EAAA,CAAA;sBAAb;gBASQ,OAAO,EAAA,CAAA;sBAAf;gBASQ,WAAW,EAAA,CAAA;sBAAnB;gBAUQ,SAAS,EAAA,CAAA;sBAAjB;gBAUQ,cAAc,EAAA,CAAA;sBAAtB;gBAQS,YAAY,EAAA,CAAA;sBAArB;gBAQS,UAAU,EAAA,CAAA;sBAAnB;;;AExKH;;AAEG;;;;"}
|
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, computed, EventEmitter, Component, createComponent, Injectable } from '@angular/core';
|
|
3
|
+
import { ButtonComponent } from '@tekus/design-system/components/button';
|
|
4
|
+
import * as i1 from 'primeng/dialog';
|
|
5
|
+
import { DialogModule } from 'primeng/dialog';
|
|
6
|
+
import { Subject } from 'rxjs';
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* @component ModalComponent
|
|
10
|
+
* @description
|
|
11
|
+
* A programmatically controlled modal dialog used for displaying dynamic content, titles, and footer actions.
|
|
12
|
+
* The modal is not instantiated via template bindings, but rather opened through a service with a configuration object.
|
|
13
|
+
*
|
|
14
|
+
* This component supports:
|
|
15
|
+
* - Configurable title and content.
|
|
16
|
+
* - Optional footer buttons with callbacks and return values.
|
|
17
|
+
* - Multiple sizes: `'small' | 'large' | 'full'`.
|
|
18
|
+
* - Closable modal and outside-click behavior.
|
|
19
|
+
* - Passing arbitrary data to the modal instance.
|
|
20
|
+
*
|
|
21
|
+
* @usage
|
|
22
|
+
* ### Open a modal from TypeScript using the modal service
|
|
23
|
+
* ```ts
|
|
24
|
+
* this.modalService.open({
|
|
25
|
+
* title: 'Demo Modal',
|
|
26
|
+
* content: 'This modal is opened from TypeScript using the service.',
|
|
27
|
+
* footerButtons: [
|
|
28
|
+
* {
|
|
29
|
+
* label: 'Accept',
|
|
30
|
+
* severity: 'secondary',
|
|
31
|
+
* action: () => console.log('Accept clicked'),
|
|
32
|
+
* returnValue: true,
|
|
33
|
+
* },
|
|
34
|
+
* {
|
|
35
|
+
* label: 'Cancel',
|
|
36
|
+
* severity: 'danger',
|
|
37
|
+
* action: () => console.log('Cancel clicked'),
|
|
38
|
+
* returnValue: false,
|
|
39
|
+
* },
|
|
40
|
+
* ],
|
|
41
|
+
* size: 'small',
|
|
42
|
+
* closable: true,
|
|
43
|
+
* closeOnOutsideClick: false,
|
|
44
|
+
* }).subscribe((result) => {
|
|
45
|
+
* console.log('Modal closed with value:', result);
|
|
46
|
+
* });
|
|
47
|
+
* ```
|
|
48
|
+
*/
|
|
49
|
+
class ModalComponent {
|
|
50
|
+
constructor() {
|
|
51
|
+
/** The title displayed at the top of the modal */
|
|
52
|
+
this.title = input('');
|
|
53
|
+
/** The main content of the modal */
|
|
54
|
+
this.content = input(null);
|
|
55
|
+
/** Array of footer buttons with label, callback, and return value */
|
|
56
|
+
this.footerButtons = input([]);
|
|
57
|
+
/** Modal size: 'small', 'large', or 'full' */
|
|
58
|
+
this.size = input('small');
|
|
59
|
+
/** Whether the modal can be closed by the user */
|
|
60
|
+
this.closable = input(true);
|
|
61
|
+
/** Whether clicking outside closes the modal */
|
|
62
|
+
this.closeOnOutsideClick = input(false);
|
|
63
|
+
/** Computed: whether the modal has footer buttons */
|
|
64
|
+
this.hasFooter = computed(() => (this.footerButtons() ?? []).length > 0);
|
|
65
|
+
/** Computed: calculates modal width based on `size` */
|
|
66
|
+
this.modalWidth = computed(() => {
|
|
67
|
+
switch (this.size()) {
|
|
68
|
+
case 'large':
|
|
69
|
+
return '67.5rem'; // Large
|
|
70
|
+
case 'full':
|
|
71
|
+
return '98vw'; // Full
|
|
72
|
+
default:
|
|
73
|
+
return '25rem'; // Small
|
|
74
|
+
}
|
|
75
|
+
});
|
|
76
|
+
/** Visibility flag */
|
|
77
|
+
this.isOpened = false;
|
|
78
|
+
/** Emits when the modal closes, passing the return value from footer buttons or null */
|
|
79
|
+
this.onClose = new EventEmitter();
|
|
80
|
+
this.alreadyEmitted = false;
|
|
81
|
+
this.returnValueOnClose = null;
|
|
82
|
+
}
|
|
83
|
+
/** Opens the modal */
|
|
84
|
+
open() {
|
|
85
|
+
this.isOpened = true;
|
|
86
|
+
this.alreadyEmitted = false;
|
|
87
|
+
this.returnValueOnClose = null;
|
|
88
|
+
}
|
|
89
|
+
/** Closes the modal and emits onClose with null */
|
|
90
|
+
handleClose() {
|
|
91
|
+
if (!this.alreadyEmitted) {
|
|
92
|
+
this.onClose.emit(null);
|
|
93
|
+
}
|
|
94
|
+
else {
|
|
95
|
+
this.onClose.emit(this.returnValueOnClose);
|
|
96
|
+
}
|
|
97
|
+
this.alreadyEmitted = false;
|
|
98
|
+
this.returnValueOnClose = null;
|
|
99
|
+
}
|
|
100
|
+
/** Closes the modal without emitting an event */
|
|
101
|
+
close() {
|
|
102
|
+
this.isOpened = false;
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* Handles footer button actions.
|
|
106
|
+
* Executes the action callback, emits `onClose` with the provided returnValue, then closes the modal.
|
|
107
|
+
* @param action Callback to execute when the button is clicked
|
|
108
|
+
* @param returnValue Value emitted on modal close
|
|
109
|
+
*/
|
|
110
|
+
handleAction(action, returnValue) {
|
|
111
|
+
if (action)
|
|
112
|
+
action();
|
|
113
|
+
this.alreadyEmitted = true;
|
|
114
|
+
this.returnValueOnClose = returnValue;
|
|
115
|
+
this.isOpened = false;
|
|
116
|
+
}
|
|
117
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ModalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
118
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: ModalComponent, isStandalone: true, selector: "tk-modal", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, content: { classPropertyName: "content", publicName: "content", isSignal: true, isRequired: false, transformFunction: null }, footerButtons: { classPropertyName: "footerButtons", publicName: "footerButtons", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, closable: { classPropertyName: "closable", publicName: "closable", isSignal: true, isRequired: false, transformFunction: null }, closeOnOutsideClick: { classPropertyName: "closeOnOutsideClick", publicName: "closeOnOutsideClick", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<p-dialog\n [modal]=\"true\"\n [(visible)]=\"isOpened\"\n [closable]=\"closable()\"\n [dismissableMask]=\"closeOnOutsideClick()\"\n [draggable]=\"false\"\n [header]=\"title()\"\n [style]=\"{ width: modalWidth() }\"\n (onHide)=\"handleClose()\"\n class=\"tk-modal\"\n>\n <section>\n @if (content()) {\n <p [innerHTML]=\"content()\" class=\"tk-modal__content\"></p>\n }\n </section>\n\n @if (hasFooter()) {\n <section class=\"tk-modal__footer\">\n @for (btn of footerButtons()!; track $index) {\n <tk-button\n [label]=\"btn.label\"\n [severity]=\"btn.severity\"\n (clicked)=\"handleAction(btn.action, btn.returnValue)\"\n (keydown.enter)=\"handleAction(btn.action, btn.returnValue)\"\n (keydown.space)=\"handleAction(btn.action, btn.returnValue)\"\n />\n }\n </section>\n }\n</p-dialog>\n", styles: [":host ::ng-deep .p-dialog-title{color:var(--tk-color-text-default, #212121)}:host ::ng-deep .p-dialog-close-button{color:var(--tk-surface-500, #8a8a8b)}:host ::ng-deep .p-dialog-close-button:hover{background:var(--tk-color-base-surface-100, #f0f0f0)!important;color:var(--tk-surface-500, #8a8a8b)}.tk-modal__content{padding-bottom:var(--tk-spacing-paddingY-l, 1.25rem);color:var(--tk-surface-1000, #000000)}.tk-modal__footer{display:flex;flex-direction:row;justify-content:end;align-items:center;gap:var(--tk-spacing-gap-s, .5rem)}\n"], dependencies: [{ kind: "ngmodule", type: DialogModule }, { kind: "component", type: i1.Dialog, selector: "p-dialog", inputs: ["header", "draggable", "resizable", "positionLeft", "positionTop", "contentStyle", "contentStyleClass", "modal", "closeOnEscape", "dismissableMask", "rtl", "closable", "responsive", "appendTo", "breakpoints", "styleClass", "maskStyleClass", "maskStyle", "showHeader", "breakpoint", "blockScroll", "autoZIndex", "baseZIndex", "minX", "minY", "focusOnShow", "maximizable", "keepInViewport", "focusTrap", "transitionOptions", "closeIcon", "closeAriaLabel", "closeTabindex", "minimizeIcon", "maximizeIcon", "closeButtonProps", "maximizeButtonProps", "visible", "style", "position", "role", "content", "contentTemplate", "footerTemplate", "closeIconTemplate", "maximizeIconTemplate", "minimizeIconTemplate", "headlessTemplate"], outputs: ["onShow", "onHide", "visibleChange", "onResizeInit", "onResizeEnd", "onDragEnd", "onMaximize"] }, { kind: "component", type: ButtonComponent, selector: "tk-button", inputs: ["label", "disabled", "type", "severity", "link"], outputs: ["clicked"] }] }); }
|
|
119
|
+
}
|
|
120
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ModalComponent, decorators: [{
|
|
121
|
+
type: Component,
|
|
122
|
+
args: [{ selector: 'tk-modal', standalone: true, imports: [DialogModule, ButtonComponent], template: "<p-dialog\n [modal]=\"true\"\n [(visible)]=\"isOpened\"\n [closable]=\"closable()\"\n [dismissableMask]=\"closeOnOutsideClick()\"\n [draggable]=\"false\"\n [header]=\"title()\"\n [style]=\"{ width: modalWidth() }\"\n (onHide)=\"handleClose()\"\n class=\"tk-modal\"\n>\n <section>\n @if (content()) {\n <p [innerHTML]=\"content()\" class=\"tk-modal__content\"></p>\n }\n </section>\n\n @if (hasFooter()) {\n <section class=\"tk-modal__footer\">\n @for (btn of footerButtons()!; track $index) {\n <tk-button\n [label]=\"btn.label\"\n [severity]=\"btn.severity\"\n (clicked)=\"handleAction(btn.action, btn.returnValue)\"\n (keydown.enter)=\"handleAction(btn.action, btn.returnValue)\"\n (keydown.space)=\"handleAction(btn.action, btn.returnValue)\"\n />\n }\n </section>\n }\n</p-dialog>\n", styles: [":host ::ng-deep .p-dialog-title{color:var(--tk-color-text-default, #212121)}:host ::ng-deep .p-dialog-close-button{color:var(--tk-surface-500, #8a8a8b)}:host ::ng-deep .p-dialog-close-button:hover{background:var(--tk-color-base-surface-100, #f0f0f0)!important;color:var(--tk-surface-500, #8a8a8b)}.tk-modal__content{padding-bottom:var(--tk-spacing-paddingY-l, 1.25rem);color:var(--tk-surface-1000, #000000)}.tk-modal__footer{display:flex;flex-direction:row;justify-content:end;align-items:center;gap:var(--tk-spacing-gap-s, .5rem)}\n"] }]
|
|
123
|
+
}] });
|
|
124
|
+
|
|
125
|
+
class ModalService {
|
|
126
|
+
constructor(injector, appRef) {
|
|
127
|
+
this.injector = injector;
|
|
128
|
+
this.appRef = appRef;
|
|
129
|
+
this.modalRef = null;
|
|
130
|
+
}
|
|
131
|
+
get _modalRefForTesting() {
|
|
132
|
+
return this.modalRef;
|
|
133
|
+
}
|
|
134
|
+
set _modalRefForTesting(ref) {
|
|
135
|
+
this.modalRef = ref;
|
|
136
|
+
}
|
|
137
|
+
open(config) {
|
|
138
|
+
if (this.modalRef) {
|
|
139
|
+
return this.modalRef.instance.onClose.asObservable();
|
|
140
|
+
}
|
|
141
|
+
const componentRef = createComponent(ModalComponent, {
|
|
142
|
+
environmentInjector: this.appRef.injector,
|
|
143
|
+
});
|
|
144
|
+
this.appRef.attachView(componentRef.hostView);
|
|
145
|
+
const domElem = componentRef.hostView.rootNodes[0];
|
|
146
|
+
document.body.appendChild(domElem);
|
|
147
|
+
componentRef.setInput('title', config.title);
|
|
148
|
+
componentRef.setInput('content', config.content ?? null);
|
|
149
|
+
componentRef.setInput('footerButtons', config.footerButtons ?? []);
|
|
150
|
+
componentRef.setInput('size', config.size ?? 'small');
|
|
151
|
+
componentRef.setInput('closable', config.closable ?? true);
|
|
152
|
+
componentRef.setInput('closeOnOutsideClick', config.closeOnOutsideClick ?? false);
|
|
153
|
+
const close$ = new Subject();
|
|
154
|
+
componentRef.instance.onClose.subscribe((value) => {
|
|
155
|
+
close$.next(value);
|
|
156
|
+
close$.complete();
|
|
157
|
+
this.appRef.detachView(componentRef.hostView);
|
|
158
|
+
componentRef.destroy();
|
|
159
|
+
this.modalRef = null;
|
|
160
|
+
});
|
|
161
|
+
componentRef.instance.open();
|
|
162
|
+
this.modalRef = componentRef;
|
|
163
|
+
return close$.asObservable();
|
|
164
|
+
}
|
|
165
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ModalService, deps: [{ token: i0.Injector }, { token: i0.ApplicationRef }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
166
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ModalService, providedIn: 'root' }); }
|
|
167
|
+
}
|
|
168
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: ModalService, decorators: [{
|
|
169
|
+
type: Injectable,
|
|
170
|
+
args: [{ providedIn: 'root' }]
|
|
171
|
+
}], ctorParameters: () => [{ type: i0.Injector }, { type: i0.ApplicationRef }] });
|
|
172
|
+
|
|
173
|
+
/**
|
|
174
|
+
* Generated bundle index. Do not edit.
|
|
175
|
+
*/
|
|
176
|
+
|
|
177
|
+
export { ModalComponent, ModalService };
|
|
178
|
+
//# sourceMappingURL=tekus-design-system-components-modal.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tekus-design-system-components-modal.mjs","sources":["../../../projects/design-system/components/modal/src/modal.component.ts","../../../projects/design-system/components/modal/src/modal.component.html","../../../projects/design-system/components/modal/src/services/modal.service.ts","../../../projects/design-system/components/modal/tekus-design-system-components-modal.ts"],"sourcesContent":["import { Component, computed, input, EventEmitter } from '@angular/core';\nimport { ButtonComponent } from '@tekus/design-system/components/button';\nimport { DialogModule } from 'primeng/dialog';\nimport { ModalFooterButton, ModalSizeType } from './modal.types';\n\n/**\n * @component ModalComponent\n * @description\n * A programmatically controlled modal dialog used for displaying dynamic content, titles, and footer actions.\n * The modal is not instantiated via template bindings, but rather opened through a service with a configuration object.\n *\n * This component supports:\n * - Configurable title and content.\n * - Optional footer buttons with callbacks and return values.\n * - Multiple sizes: `'small' | 'large' | 'full'`.\n * - Closable modal and outside-click behavior.\n * - Passing arbitrary data to the modal instance.\n *\n * @usage\n * ### Open a modal from TypeScript using the modal service\n * ```ts\n * this.modalService.open({\n * title: 'Demo Modal',\n * content: 'This modal is opened from TypeScript using the service.',\n * footerButtons: [\n * {\n * label: 'Accept',\n * severity: 'secondary',\n * action: () => console.log('Accept clicked'),\n * returnValue: true,\n * },\n * {\n * label: 'Cancel',\n * severity: 'danger',\n * action: () => console.log('Cancel clicked'),\n * returnValue: false,\n * },\n * ],\n * size: 'small',\n * closable: true,\n * closeOnOutsideClick: false,\n * }).subscribe((result) => {\n * console.log('Modal closed with value:', result);\n * });\n * ```\n */\n\n@Component({\n selector: 'tk-modal',\n standalone: true,\n imports: [DialogModule, ButtonComponent],\n templateUrl: './modal.component.html',\n styleUrls: ['./modal.component.scss']\n})\nexport class ModalComponent {\n\n /** The title displayed at the top of the modal */\n title = input<string>('');\n /** The main content of the modal */\n content = input<string | null>(null);\n /** Array of footer buttons with label, callback, and return value */\n footerButtons = input<ModalFooterButton[]>([]);\n /** Modal size: 'small', 'large', or 'full' */\n size = input<ModalSizeType>('small');\n /** Whether the modal can be closed by the user */\n closable = input<boolean>(true);\n /** Whether clicking outside closes the modal */\n closeOnOutsideClick = input<boolean>(false);\n /** Computed: whether the modal has footer buttons */\n hasFooter = computed(() => (this.footerButtons() ?? []).length > 0);\n /** Computed: calculates modal width based on `size` */\n modalWidth = computed(() => {\n switch (this.size()) {\n case 'large':\n return '67.5rem'; // Large\n case 'full':\n return '98vw'; // Full\n default:\n return '25rem'; // Small\n }\n});\n\n /** Visibility flag */\n isOpened: boolean = false;\n\n /** Emits when the modal closes, passing the return value from footer buttons or null */\n readonly onClose = new EventEmitter<unknown>();\n private alreadyEmitted = false;\n private returnValueOnClose: unknown = null;\n\n /** Opens the modal */\n open() {\n this.isOpened = true;\n this.alreadyEmitted = false;\n this.returnValueOnClose = null;\n }\n\n /** Closes the modal and emits onClose with null */\n handleClose() {\n if (!this.alreadyEmitted) {\n this.onClose.emit(null);\n } else {\n this.onClose.emit(this.returnValueOnClose);\n }\n this.alreadyEmitted = false;\n this.returnValueOnClose = null;\n }\n\n /** Closes the modal without emitting an event */\n close() {\n this.isOpened = false;\n }\n\n /**\n * Handles footer button actions.\n * Executes the action callback, emits `onClose` with the provided returnValue, then closes the modal.\n * @param action Callback to execute when the button is clicked\n * @param returnValue Value emitted on modal close\n */\n handleAction(action: () => void, returnValue: unknown) {\n if (action) action();\n this.alreadyEmitted = true;\n this.returnValueOnClose = returnValue;\n this.isOpened = false;\n }\n}\n","<p-dialog\n [modal]=\"true\"\n [(visible)]=\"isOpened\"\n [closable]=\"closable()\"\n [dismissableMask]=\"closeOnOutsideClick()\"\n [draggable]=\"false\"\n [header]=\"title()\"\n [style]=\"{ width: modalWidth() }\"\n (onHide)=\"handleClose()\"\n class=\"tk-modal\"\n>\n <section>\n @if (content()) {\n <p [innerHTML]=\"content()\" class=\"tk-modal__content\"></p>\n }\n </section>\n\n @if (hasFooter()) {\n <section class=\"tk-modal__footer\">\n @for (btn of footerButtons()!; track $index) {\n <tk-button\n [label]=\"btn.label\"\n [severity]=\"btn.severity\"\n (clicked)=\"handleAction(btn.action, btn.returnValue)\"\n (keydown.enter)=\"handleAction(btn.action, btn.returnValue)\"\n (keydown.space)=\"handleAction(btn.action, btn.returnValue)\"\n />\n }\n </section>\n }\n</p-dialog>\n","import {\n Injectable,\n ApplicationRef,\n ComponentRef,\n Injector,\n createComponent,\n EmbeddedViewRef,\n} from '@angular/core';\nimport { ModalComponent } from '../modal.component';\nimport { Observable, Subject } from 'rxjs';\nimport { ModalConfig } from '../modal.types';\n\n@Injectable({ providedIn: 'root' })\nexport class ModalService {\n private modalRef: ComponentRef<ModalComponent> | null = null;\n\n constructor(\n private readonly injector: Injector,\n private readonly appRef: ApplicationRef\n ) {}\n\n get _modalRefForTesting(): ComponentRef<ModalComponent> | null {\n return this.modalRef;\n }\n set _modalRefForTesting(ref: ComponentRef<ModalComponent> | null) {\n this.modalRef = ref;\n }\n\n open(config: ModalConfig): Observable<unknown> {\n if (this.modalRef) {\n return this.modalRef.instance.onClose.asObservable();\n }\n\n const componentRef = createComponent(ModalComponent, {\n environmentInjector: this.appRef.injector,\n });\n\n this.appRef.attachView(componentRef.hostView);\n\n const domElem = (componentRef.hostView as EmbeddedViewRef<unknown>).rootNodes[0] as HTMLElement;\n document.body.appendChild(domElem);\n\n componentRef.setInput('title', config.title);\n componentRef.setInput('content', config.content ?? null);\n componentRef.setInput('footerButtons', config.footerButtons ?? []);\n componentRef.setInput('size', config.size ?? 'small');\n componentRef.setInput('closable', config.closable ?? true);\n componentRef.setInput('closeOnOutsideClick', config.closeOnOutsideClick ?? false);\n\n const close$ = new Subject<unknown>();\n\n componentRef.instance.onClose.subscribe((value) => {\n close$.next(value);\n close$.complete();\n\n this.appRef.detachView(componentRef.hostView);\n componentRef.destroy();\n this.modalRef = null;\n });\n\n componentRef.instance.open();\n this.modalRef = componentRef;\n\n return close$.asObservable();\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;AAKA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwCG;MASU,cAAc,CAAA;AAP3B,IAAA,WAAA,GAAA;;AAUE,QAAA,IAAA,CAAA,KAAK,GAAG,KAAK,CAAS,EAAE,CAAC;;AAEzB,QAAA,IAAA,CAAA,OAAO,GAAG,KAAK,CAAgB,IAAI,CAAC;;AAEpC,QAAA,IAAA,CAAA,aAAa,GAAG,KAAK,CAAsB,EAAE,CAAC;;AAE9C,QAAA,IAAA,CAAA,IAAI,GAAG,KAAK,CAAgB,OAAO,CAAC;;AAEpC,QAAA,IAAA,CAAA,QAAQ,GAAG,KAAK,CAAU,IAAI,CAAC;;AAE/B,QAAA,IAAA,CAAA,mBAAmB,GAAG,KAAK,CAAU,KAAK,CAAC;;AAE3C,QAAA,IAAA,CAAA,SAAS,GAAG,QAAQ,CAAC,MAAM,CAAC,IAAI,CAAC,aAAa,EAAE,IAAI,EAAE,EAAE,MAAM,GAAG,CAAC,CAAC;;AAEnE,QAAA,IAAA,CAAA,UAAU,GAAG,QAAQ,CAAC,MAAK;AAC3B,YAAA,QAAQ,IAAI,CAAC,IAAI,EAAE;AACjB,gBAAA,KAAK,OAAO;oBACV,OAAO,SAAS,CAAC;AACnB,gBAAA,KAAK,MAAM;oBACT,OAAO,MAAM,CAAC;AAChB,gBAAA;oBACE,OAAO,OAAO,CAAC;;AAErB,SAAC,CAAC;;QAGA,IAAQ,CAAA,QAAA,GAAY,KAAK;;AAGhB,QAAA,IAAA,CAAA,OAAO,GAAG,IAAI,YAAY,EAAW;QACtC,IAAc,CAAA,cAAA,GAAG,KAAK;QACtB,IAAk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|
|
|
47
47
|
const TkPreset = definePreset(Aura, {
|
|
48
48
|
semantic: {
|
|
49
49
|
primary: {
|
|
50
|
-
|
|
51
|
-
|
|
50
|
+
50: 'var(--tk-color-base-primary-50)',
|
|
51
|
+
100: 'var(--tk-color-base-primary-100)',
|
|
52
|
+
200: 'var(--tk-color-base-primary-200)',
|
|
52
53
|
300: 'var(--tk-color-base-primary-300)',
|
|
54
|
+
400: 'var(--tk-color-base-primary-400)',
|
|
55
|
+
500: 'var(--tk-color-base-primary-500)',
|
|
56
|
+
600: 'var(--tk-color-base-primary-600)',
|
|
57
|
+
700: 'var(--tk-color-base-primary-700)',
|
|
58
|
+
800: 'var(--tk-color-base-primary-800)',
|
|
59
|
+
900: 'var(--tk-color-base-primary-900)',
|
|
60
|
+
950: 'var(--tk-color-base-primary-950)'
|
|
61
|
+
},
|
|
62
|
+
red: {
|
|
63
|
+
50: 'var(--tk-color-base-red-50)',
|
|
64
|
+
100: 'var(--tk-color-base-red-100)',
|
|
65
|
+
200: 'var(--tk-color-base-red-200)',
|
|
66
|
+
300: 'var(--tk-color-base-red-300)',
|
|
67
|
+
400: 'var(--tk-color-base-red-400)',
|
|
68
|
+
500: 'var(--tk-color-base-red-500)',
|
|
69
|
+
600: 'var(--tk-color-base-red-600)',
|
|
70
|
+
700: 'var(--tk-color-base-red-700)',
|
|
71
|
+
800: 'var(--tk-color-base-red-800)',
|
|
72
|
+
900: 'var(--tk-color-base-red-900)',
|
|
73
|
+
950: 'var(--tk-color-base-red-950)'
|
|
53
74
|
},
|
|
54
75
|
surface: {
|
|
55
76
|
0: 'var(--tk-color-base-surface-0)',
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
77
|
+
50: 'var(--tk-color-base-surface-50)',
|
|
78
|
+
100: 'var(--tk-color-base-surface-100)',
|
|
79
|
+
200: 'var(--tk-color-base-surface-200)',
|
|
80
|
+
300: 'var(--tk-color-base-surface-300)',
|
|
81
|
+
400: 'var(--tk-color-base-surface-400)',
|
|
82
|
+
500: 'var(--tk-color-base-surface-500)',
|
|
83
|
+
600: 'var(--tk-color-base-surface-600)',
|
|
84
|
+
700: 'var(--tk-color-base-surface-700)',
|
|
85
|
+
800: 'var(--tk-color-base-surface-800)',
|
|
86
|
+
900: 'var(--tk-color-base-surface-900)',
|
|
87
|
+
950: 'var(--tk-color-base-surface-950)'
|
|
59
88
|
},
|
|
60
89
|
},
|
|
61
90
|
font: {
|
|
62
|
-
family: 'var(tk-font-family)',
|
|
63
|
-
size: {
|
|
64
|
-
md: 'var(--tk-font-size-base-150)',
|
|
65
|
-
'2xs': 'var(--tk-font-size-base-100)',
|
|
66
|
-
},
|
|
67
|
-
weight: {
|
|
68
|
-
regular: 'var(--tk-font-weight-400)',
|
|
69
|
-
medium: '500',
|
|
70
|
-
bold: 'var(--tk-font-weight-600)',
|
|
71
|
-
},
|
|
72
|
-
},
|
|
73
|
-
spacing: {
|
|
74
|
-
3: 'var(--tk-spacing-base-75)',
|
|
75
|
-
4: 'var(--tk-spacing-base-100)',
|
|
76
|
-
6: 'var(--tk-spacing-base-150)',
|
|
77
|
-
8: 'var(--tk-spacing-base-200)',
|
|
91
|
+
family: 'var(--tk-font-family)',
|
|
78
92
|
},
|
|
79
93
|
components: {
|
|
80
94
|
button: {
|
|
@@ -89,58 +103,66 @@ const TkPreset = definePreset(Aura, {
|
|
|
89
103
|
},
|
|
90
104
|
colorScheme: {
|
|
91
105
|
light: {
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
106
|
+
root: {
|
|
107
|
+
primary: {
|
|
108
|
+
hoverBackground: 'var(--tk-color-base-primary-400)',
|
|
109
|
+
activeBackground: 'var(--tk-color-base-primary-400)',
|
|
110
|
+
hoverBorderColor: 'transparent',
|
|
111
|
+
activeBorderColor: 'transparent',
|
|
112
|
+
},
|
|
113
|
+
secondary: {
|
|
114
|
+
background: 'var(--tk-color-base-surface-0)',
|
|
115
|
+
hoverBackground: 'var(--tk-color-base-surface-100)',
|
|
116
|
+
borderColor: 'var(--tk-color-base-surface-200)',
|
|
117
|
+
hoverBorderColor: 'var(--tk-color-base-surface-200)',
|
|
118
|
+
activeBorderColor: 'var(--tk-color-base-surface-200)',
|
|
119
|
+
},
|
|
102
120
|
},
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
fontSize: '{font.size.2xs}',
|
|
109
|
-
fontWeight: '{font.weight.medium}',
|
|
110
|
-
hoverColor: '{primary.400}',
|
|
111
|
-
hoverBackground: 'none',
|
|
112
|
-
activeColor: '{primary.300}',
|
|
113
|
-
activeBackground: 'none',
|
|
121
|
+
text: {
|
|
122
|
+
secondary: {
|
|
123
|
+
hoverBackground: 'var(--tk-color-base-surface-200)',
|
|
124
|
+
activeBackground: 'var(--tk-color-base-surface-200)',
|
|
125
|
+
},
|
|
114
126
|
},
|
|
115
127
|
},
|
|
116
128
|
dark: {
|
|
117
129
|
primary: {
|
|
118
|
-
background: '
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
hoverColor: '{surface.0}',
|
|
122
|
-
activeBackground: '{primary.400}',
|
|
123
|
-
activeColor: '{surface.0}',
|
|
130
|
+
background: 'var(--tk-color-base-primary-500)',
|
|
131
|
+
hoverBackground: 'var(--tk-color-base-primary-400)',
|
|
132
|
+
activeBackground: 'var(--tk-color-base-primary-400)',
|
|
124
133
|
borderColor: 'transparent',
|
|
125
134
|
hoverBorderColor: 'transparent',
|
|
126
135
|
activeBorderColor: 'transparent',
|
|
127
136
|
},
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
fontWeight: '{font.weight.medium}',
|
|
135
|
-
hoverColor: '{primary.400}',
|
|
136
|
-
hoverBackground: 'none',
|
|
137
|
-
activeColor: '{primary.300}',
|
|
138
|
-
activeBackground: 'none',
|
|
137
|
+
secondary: {
|
|
138
|
+
background: 'var(--tk-color-base-surface-0)',
|
|
139
|
+
hoverBackground: 'var(--tk-color-base-surface-200)',
|
|
140
|
+
borderColor: 'var(--tk-color-base-surface-200)',
|
|
141
|
+
hoverBorderColor: 'var(--tk-color-base-surface-200)',
|
|
142
|
+
activeBorderColor: 'var(--tk-color-base-surface-200)',
|
|
139
143
|
},
|
|
144
|
+
danger: {
|
|
145
|
+
background: 'var(--tk-color-base-red-500)',
|
|
146
|
+
hoverBackground: 'var(--tk-color-base-red-600)',
|
|
147
|
+
activeBackground: 'var(--tk-color-base-red-700)',
|
|
148
|
+
borderColor: 'var(--tk-color-base-red-500)',
|
|
149
|
+
hoverBorderColor: 'var(--tk-color-base-red-600)',
|
|
150
|
+
activeBorderColor: 'var(--tk-color-base-red-700)',
|
|
151
|
+
}
|
|
140
152
|
},
|
|
141
153
|
},
|
|
142
154
|
},
|
|
143
|
-
|
|
155
|
+
dialog: {
|
|
156
|
+
colorScheme: {
|
|
157
|
+
dark: {
|
|
158
|
+
root: {
|
|
159
|
+
background: 'var(--tk-color-base-surface-0)',
|
|
160
|
+
borderColor: 'var(--tk-color-base-surface-200)',
|
|
161
|
+
},
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
}
|
|
144
166
|
});
|
|
145
167
|
|
|
146
168
|
function themeFactory(config, document) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tekus-design-system-core-types.mjs","sources":["../../../projects/design-system/core/types/src/grids/grid.enum.ts","../../../projects/design-system/core/types/src/breakpoints/breakpoints.ts","../../../projects/design-system/core/types/src/theme/tk-preset.ts","../../../projects/design-system/core/types/src/theme/theme.provider.ts","../../../projects/design-system/core/types/tekus-design-system-core-types.ts"],"sourcesContent":["enum GapGutter {\n normal = '24px',\n small = '16px',\n large = '32px',\n extraLarge = '40px',\n}\n\nenum PaddingGridContainer {\n large = '32px',\n medium = '24px',\n small = '16px'\n}\n\nenum Gutter {\n normal = 'normal',\n small = 'small',\n large = 'large',\n extraLarge = 'extraLarge',\n\n}\n\nexport {\n Gutter,\n GapGutter,\n PaddingGridContainer\n}","export const Breakpoints = {\n // Covers all devices with a width less than or equal to 360px.\n mobileSmall: '(max-width: 360px)',\n\n // For small phones (e.g., most modern cell phones)\n mobile: '(min-width: 361px) and (max-width: 424px)',\n\n // For large phones (e.g., Google Pixel, iPhone Plus/Max)\n mobileLarge: '(min-width: 425px) and (max-width: 575px)',\n\n // Vertical tablets and medium-sized devices\n tabletVertical: '(min-width: 576px) and (max-width: 767px)',\n\n // Tablets in landscape mode\n tabletHorizontal: '(min-width: 768px) and (max-width: 991px)',\n\n // Laptops and small desktops\n desktopSmall: '(min-width: 992px) and (max-width: 1199px)',\n\n // Large desks\n desktop: '(min-width: 1200px) and (max-width: 1399px)',\n\n // Ultra-wide screens\n desktopLarge: '(min-width: 1400px)',\n}","import { definePreset } from '@primeng/themes';\nimport Aura from '@primeng/themes/aura';\n\nexport const TkPreset = definePreset(Aura, {\n semantic: {\n primary: {\n 500: 'var(--tk-color-base-primary-500)',\n 400: 'var(--tk-color-base-primary-400)',\n 300: 'var(--tk-color-base-primary-300)',\n },\n surface: {\n 0: 'var(--tk-color-base-surface-0)',\n },\n text: {\n default: 'var(--tk-color-text-default)',\n },\n },\n font: {\n family: 'var(tk-font-family)',\n size: {\n md: 'var(--tk-font-size-base-150)',\n '2xs': 'var(--tk-font-size-base-100)',\n },\n weight: {\n regular: 'var(--tk-font-weight-400)',\n medium: '500',\n bold: 'var(--tk-font-weight-600)',\n },\n },\n spacing: {\n 3: 'var(--tk-spacing-base-75)',\n 4: 'var(--tk-spacing-base-100)',\n 6: 'var(--tk-spacing-base-150)',\n 8: 'var(--tk-spacing-base-200)',\n },\n components: {\n button: {\n root: {\n outline: 'none',\n boxShadow: 'none',\n border: 'none',\n focusBoxShadow: 'none',\n },\n label: {\n color: 'inherit',\n },\n colorScheme: {\n light: {\n primary: {\n background: '{primary.500}',\n color: '{surface.0}',\n hoverBackground: '{primary.400}',\n hoverColor: '{surface.0}',\n activeBackground: '{primary.400}',\n activeColor: '{surface.0}',\n borderColor: 'transparent',\n hoverBorderColor: 'transparent',\n activeBorderColor: 'transparent',\n },\n link: {\n textDecoration: 'underline',\n background: 'none',\n boxShadow: 'none',\n color: '{primary.500}',\n fontSize: '{font.size.2xs}',\n fontWeight: '{font.weight.medium}',\n hoverColor: '{primary.400}',\n hoverBackground: 'none',\n activeColor: '{primary.300}',\n activeBackground: 'none',\n },\n },\n dark: {\n primary: {\n background: '{primary.500}',\n color: '{surface.0}',\n hoverBackground: '{primary.400}',\n hoverColor: '{surface.0}',\n activeBackground: '{primary.400}',\n activeColor: '{surface.0}',\n borderColor: 'transparent',\n hoverBorderColor: 'transparent',\n activeBorderColor: 'transparent',\n },\n link: {\n textDecoration: 'underline',\n background: 'none',\n boxShadow: 'none',\n color: '{primary.500}',\n fontSize: '{font.size.2xs}',\n fontWeight: '{font.weight.medium}',\n hoverColor: '{primary.400}',\n hoverBackground: 'none',\n activeColor: '{primary.300}',\n activeBackground: 'none',\n },\n },\n },\n },\n },\n});\n","import { inject, provideAppInitializer } from '@angular/core';\nimport { DOCUMENT } from '@angular/common';\nimport { PrimeNG } from 'primeng/config';\nimport { TkPreset } from './tk-preset';\n\nfunction themeFactory(config: PrimeNG, document: Document): () => void {\n return () => {\n const fontLink = document.createElement('link');\n fontLink.rel = 'stylesheet';\n fontLink.href =\n 'https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap';\n document.head.appendChild(fontLink);\n\n const style = document.createElement('style');\n style.innerHTML = `\n body {\n font-family: 'Poppins', sans-serif;\n }\n `;\n document.head.appendChild(style);\n\n config.theme.set({\n preset: TkPreset,\n options: {\n prefix: 'tk',\n darkMode: false\n },\n });\n };\n}\n\nexport function provideTkTheme() {\n return provideAppInitializer(() => {\n const config = inject(PrimeNG);\n const document = inject(DOCUMENT);\n return themeFactory(config, document)();\n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;AACvB,wBAAA,WAAW,EAAE,eAAe;AAC5B,wBAAA,gBAAgB,EAAE,MAAM;AACzB,qBAAA;AACF,iBAAA;AACF,aAAA;AACF,SAAA;AACF,KAAA;AACF,CAAA;;AC/FD,SAAS,YAAY,CAAC,MAAe,EAAE,QAAkB,EAAA;AACvD,IAAA,OAAO,MAAK;QACV,MAAM,QAAQ,GAAG,QAAQ,CAAC,aAAa,CAAC,MAAM,CAAC;AAC/C,QAAA,QAAQ,CAAC,GAAG,GAAG,YAAY;AAC3B,QAAA,QAAQ,CAAC,IAAI;AACX,YAAA,wFAAwF;AAC1F,QAAA,QAAQ,CAAC,IAAI,CAAC,WAAW,CAAC,QAAQ,CAAC;QAEnC,MAAM,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC;QAC7C,KAAK,CAAC,SAAS,GAAG;;;;KAIjB;AACD,QAAA,QAAQ,CAAC,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC;AAEhC,QAAA,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC;AACf,YAAA,MAAM,EAAE,QAAQ;AAChB,YAAA,OAAO,EAAE;AACP,gBAAA,MAAM,EAAE,IAAI;AACZ,gBAAA,QAAQ,EAAE;AACX,aAAA;AACF,SAAA,CAAC;AACJ,KAAC;AACH;SAEgB,cAAc,GAAA;IAC5B,OAAO,qBAAqB,CAAC,MAAK;AAChC,QAAA,MAAM,MAAM,GAAG,MAAM,CAAC,OAAO,CAAC;AAC9B,QAAA,MAAM,QAAQ,GAAG,MAAM,CAAC,QAAQ,CAAC;AACjC,QAAA,OAAO,YAAY,CAAC,MAAM,EAAE,QAAQ,CAAC,EAAE;AACzC,KAAC,CAAC;AACJ;;ACrCA;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"tekus-design-system-core-types.mjs","sources":["../../../projects/design-system/core/types/src/grids/grid.enum.ts","../../../projects/design-system/core/types/src/breakpoints/breakpoints.ts","../../../projects/design-system/core/types/src/theme/tk-preset.ts","../../../projects/design-system/core/types/src/theme/theme.provider.ts","../../../projects/design-system/core/types/tekus-design-system-core-types.ts"],"sourcesContent":["enum GapGutter {\n normal = '24px',\n small = '16px',\n large = '32px',\n extraLarge = '40px',\n}\n\nenum PaddingGridContainer {\n large = '32px',\n medium = '24px',\n small = '16px'\n}\n\nenum Gutter {\n normal = 'normal',\n small = 'small',\n large = 'large',\n extraLarge = 'extraLarge',\n\n}\n\nexport {\n Gutter,\n GapGutter,\n PaddingGridContainer\n}","export const Breakpoints = {\n // Covers all devices with a width less than or equal to 360px.\n mobileSmall: '(max-width: 360px)',\n\n // For small phones (e.g., most modern cell phones)\n mobile: '(min-width: 361px) and (max-width: 424px)',\n\n // For large phones (e.g., Google Pixel, iPhone Plus/Max)\n mobileLarge: '(min-width: 425px) and (max-width: 575px)',\n\n // Vertical tablets and medium-sized devices\n tabletVertical: '(min-width: 576px) and (max-width: 767px)',\n\n // Tablets in landscape mode\n tabletHorizontal: '(min-width: 768px) and (max-width: 991px)',\n\n // Laptops and small desktops\n desktopSmall: '(min-width: 992px) and (max-width: 1199px)',\n\n // Large desks\n desktop: '(min-width: 1200px) and (max-width: 1399px)',\n\n // Ultra-wide screens\n desktopLarge: '(min-width: 1400px)',\n}","import { definePreset } from '@primeng/themes';\nimport Aura from '@primeng/themes/aura';\n\nexport const TkPreset = definePreset(Aura, {\n semantic: {\n primary: {\n 50: 'var(--tk-color-base-primary-50)',\n 100: 'var(--tk-color-base-primary-100)',\n 200: 'var(--tk-color-base-primary-200)',\n 300: 'var(--tk-color-base-primary-300)',\n 400: 'var(--tk-color-base-primary-400)',\n 500: 'var(--tk-color-base-primary-500)',\n 600: 'var(--tk-color-base-primary-600)',\n 700: 'var(--tk-color-base-primary-700)',\n 800: 'var(--tk-color-base-primary-800)',\n 900: 'var(--tk-color-base-primary-900)',\n 950: 'var(--tk-color-base-primary-950)'\n },\n red: {\n 50: 'var(--tk-color-base-red-50)',\n 100: 'var(--tk-color-base-red-100)',\n 200: 'var(--tk-color-base-red-200)',\n 300: 'var(--tk-color-base-red-300)',\n 400: 'var(--tk-color-base-red-400)',\n 500: 'var(--tk-color-base-red-500)',\n 600: 'var(--tk-color-base-red-600)',\n 700: 'var(--tk-color-base-red-700)',\n 800: 'var(--tk-color-base-red-800)',\n 900: 'var(--tk-color-base-red-900)',\n 950: 'var(--tk-color-base-red-950)'\n },\n surface: {\n 0: 'var(--tk-color-base-surface-0)',\n 50: 'var(--tk-color-base-surface-50)',\n 100: 'var(--tk-color-base-surface-100)',\n 200: 'var(--tk-color-base-surface-200)',\n 300: 'var(--tk-color-base-surface-300)',\n 400: 'var(--tk-color-base-surface-400)',\n 500: 'var(--tk-color-base-surface-500)',\n 600: 'var(--tk-color-base-surface-600)',\n 700: 'var(--tk-color-base-surface-700)',\n 800: 'var(--tk-color-base-surface-800)',\n 900: 'var(--tk-color-base-surface-900)',\n 950: 'var(--tk-color-base-surface-950)'\n },\n },\n font: {\n family: 'var(--tk-font-family)',\n },\n\n components: {\n button: {\n root: {\n outline: 'none',\n boxShadow: 'none',\n border: 'none',\n focusBoxShadow: 'none',\n },\n label: {\n color: 'inherit',\n },\n colorScheme: {\n light: {\n root: {\n primary: {\n hoverBackground: 'var(--tk-color-base-primary-400)',\n activeBackground: 'var(--tk-color-base-primary-400)',\n hoverBorderColor: 'transparent',\n activeBorderColor: 'transparent',\n },\n secondary: {\n background: 'var(--tk-color-base-surface-0)',\n hoverBackground: 'var(--tk-color-base-surface-100)',\n borderColor: 'var(--tk-color-base-surface-200)',\n hoverBorderColor: 'var(--tk-color-base-surface-200)',\n activeBorderColor: 'var(--tk-color-base-surface-200)',\n },\n },\n text: {\n secondary: {\n hoverBackground: 'var(--tk-color-base-surface-200)',\n activeBackground: 'var(--tk-color-base-surface-200)',\n },\n },\n },\n dark: {\n primary: {\n background: 'var(--tk-color-base-primary-500)',\n hoverBackground: 'var(--tk-color-base-primary-400)',\n activeBackground: 'var(--tk-color-base-primary-400)',\n borderColor: 'transparent',\n hoverBorderColor: 'transparent',\n activeBorderColor: 'transparent',\n },\n secondary: {\n background: 'var(--tk-color-base-surface-0)',\n hoverBackground: 'var(--tk-color-base-surface-200)',\n borderColor: 'var(--tk-color-base-surface-200)',\n hoverBorderColor: 'var(--tk-color-base-surface-200)',\n activeBorderColor: 'var(--tk-color-base-surface-200)',\n },\n danger: {\n background: 'var(--tk-color-base-red-500)',\n hoverBackground: 'var(--tk-color-base-red-600)',\n activeBackground: 'var(--tk-color-base-red-700)',\n borderColor: 'var(--tk-color-base-red-500)',\n hoverBorderColor: 'var(--tk-color-base-red-600)',\n activeBorderColor: 'var(--tk-color-base-red-700)',\n }\n },\n },\n },\n dialog: {\n colorScheme: {\n dark: {\n root: {\n background: 'var(--tk-color-base-surface-0)',\n borderColor: 'var(--tk-color-base-surface-200)',\n },\n }\n }\n }\n }\n});\n","import { inject, provideAppInitializer } from '@angular/core';\nimport { DOCUMENT } from '@angular/common';\nimport { PrimeNG } from 'primeng/config';\nimport { TkPreset } from './tk-preset';\n\nfunction themeFactory(config: PrimeNG, document: Document): () => void {\n return () => {\n const fontLink = document.createElement('link');\n fontLink.rel = 'stylesheet';\n fontLink.href =\n 'https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap';\n document.head.appendChild(fontLink);\n\n const style = document.createElement('style');\n style.innerHTML = `\n body {\n font-family: 'Poppins', sans-serif;\n }\n `;\n document.head.appendChild(style);\n\n config.theme.set({\n preset: TkPreset,\n options: {\n prefix: 'tk',\n darkMode: false\n },\n });\n };\n}\n\nexport function provideTkTheme() {\n return provideAppInitializer(() => {\n const config = inject(PrimeNG);\n const document = inject(DOCUMENT);\n return themeFactory(config, document)();\n });\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAAA,IAAK;AAAL,CAAA,UAAK,SAAS,EAAA;AACV,IAAA,SAAA,CAAA,QAAA,CAAA,GAAA,MAAe;AACf,IAAA,SAAA,CAAA,OAAA,CAA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AAK;AAChC,QAAA,MAAM,MAAM,GAAG,MAAM,CAAC,OAAO,CAAC;AAC9B,QAAA,MAAM,QAAQ,GAAG,MAAM,CAAC,QAAQ,CAAC;AACjC,QAAA,OAAO,YAAY,CAAC,MAAM,EAAE,QAAQ,CAAC,EAAE;AACzC,KAAC,CAAC;AACJ;;ACrCA;;AAEG;;;;"}
|
|
@@ -47,34 +47,48 @@ const Breakpoints = {
|
|
|
47
47
|
const TkPreset = definePreset(Aura, {
|
|
48
48
|
semantic: {
|
|
49
49
|
primary: {
|
|
50
|
-
|
|
51
|
-
|
|
50
|
+
50: 'var(--tk-color-base-primary-50)',
|
|
51
|
+
100: 'var(--tk-color-base-primary-100)',
|
|
52
|
+
200: 'var(--tk-color-base-primary-200)',
|
|
52
53
|
300: 'var(--tk-color-base-primary-300)',
|
|
54
|
+
400: 'var(--tk-color-base-primary-400)',
|
|
55
|
+
500: 'var(--tk-color-base-primary-500)',
|
|
56
|
+
600: 'var(--tk-color-base-primary-600)',
|
|
57
|
+
700: 'var(--tk-color-base-primary-700)',
|
|
58
|
+
800: 'var(--tk-color-base-primary-800)',
|
|
59
|
+
900: 'var(--tk-color-base-primary-900)',
|
|
60
|
+
950: 'var(--tk-color-base-primary-950)'
|
|
61
|
+
},
|
|
62
|
+
red: {
|
|
63
|
+
50: 'var(--tk-color-base-red-50)',
|
|
64
|
+
100: 'var(--tk-color-base-red-100)',
|
|
65
|
+
200: 'var(--tk-color-base-red-200)',
|
|
66
|
+
300: 'var(--tk-color-base-red-300)',
|
|
67
|
+
400: 'var(--tk-color-base-red-400)',
|
|
68
|
+
500: 'var(--tk-color-base-red-500)',
|
|
69
|
+
600: 'var(--tk-color-base-red-600)',
|
|
70
|
+
700: 'var(--tk-color-base-red-700)',
|
|
71
|
+
800: 'var(--tk-color-base-red-800)',
|
|
72
|
+
900: 'var(--tk-color-base-red-900)',
|
|
73
|
+
950: 'var(--tk-color-base-red-950)'
|
|
53
74
|
},
|
|
54
75
|
surface: {
|
|
55
76
|
0: 'var(--tk-color-base-surface-0)',
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
77
|
+
50: 'var(--tk-color-base-surface-50)',
|
|
78
|
+
100: 'var(--tk-color-base-surface-100)',
|
|
79
|
+
200: 'var(--tk-color-base-surface-200)',
|
|
80
|
+
300: 'var(--tk-color-base-surface-300)',
|
|
81
|
+
400: 'var(--tk-color-base-surface-400)',
|
|
82
|
+
500: 'var(--tk-color-base-surface-500)',
|
|
83
|
+
600: 'var(--tk-color-base-surface-600)',
|
|
84
|
+
700: 'var(--tk-color-base-surface-700)',
|
|
85
|
+
800: 'var(--tk-color-base-surface-800)',
|
|
86
|
+
900: 'var(--tk-color-base-surface-900)',
|
|
87
|
+
950: 'var(--tk-color-base-surface-950)'
|
|
59
88
|
},
|
|
60
89
|
},
|
|
61
90
|
font: {
|
|
62
|
-
family: 'var(tk-font-family)',
|
|
63
|
-
size: {
|
|
64
|
-
md: 'var(--tk-font-size-base-150)',
|
|
65
|
-
'2xs': 'var(--tk-font-size-base-100)',
|
|
66
|
-
},
|
|
67
|
-
weight: {
|
|
68
|
-
regular: 'var(--tk-font-weight-400)',
|
|
69
|
-
medium: '500',
|
|
70
|
-
bold: 'var(--tk-font-weight-600)',
|
|
71
|
-
},
|
|
72
|
-
},
|
|
73
|
-
spacing: {
|
|
74
|
-
3: 'var(--tk-spacing-base-75)',
|
|
75
|
-
4: 'var(--tk-spacing-base-100)',
|
|
76
|
-
6: 'var(--tk-spacing-base-150)',
|
|
77
|
-
8: 'var(--tk-spacing-base-200)',
|
|
91
|
+
family: 'var(--tk-font-family)',
|
|
78
92
|
},
|
|
79
93
|
components: {
|
|
80
94
|
button: {
|
|
@@ -89,58 +103,66 @@ const TkPreset = definePreset(Aura, {
|
|
|
89
103
|
},
|
|
90
104
|
colorScheme: {
|
|
91
105
|
light: {
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
106
|
+
root: {
|
|
107
|
+
primary: {
|
|
108
|
+
hoverBackground: 'var(--tk-color-base-primary-400)',
|
|
109
|
+
activeBackground: 'var(--tk-color-base-primary-400)',
|
|
110
|
+
hoverBorderColor: 'transparent',
|
|
111
|
+
activeBorderColor: 'transparent',
|
|
112
|
+
},
|
|
113
|
+
secondary: {
|
|
114
|
+
background: 'var(--tk-color-base-surface-0)',
|
|
115
|
+
hoverBackground: 'var(--tk-color-base-surface-100)',
|
|
116
|
+
borderColor: 'var(--tk-color-base-surface-200)',
|
|
117
|
+
hoverBorderColor: 'var(--tk-color-base-surface-200)',
|
|
118
|
+
activeBorderColor: 'var(--tk-color-base-surface-200)',
|
|
119
|
+
},
|
|
102
120
|
},
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
fontSize: '{font.size.2xs}',
|
|
109
|
-
fontWeight: '{font.weight.medium}',
|
|
110
|
-
hoverColor: '{primary.400}',
|
|
111
|
-
hoverBackground: 'none',
|
|
112
|
-
activeColor: '{primary.300}',
|
|
113
|
-
activeBackground: 'none',
|
|
121
|
+
text: {
|
|
122
|
+
secondary: {
|
|
123
|
+
hoverBackground: 'var(--tk-color-base-surface-200)',
|
|
124
|
+
activeBackground: 'var(--tk-color-base-surface-200)',
|
|
125
|
+
},
|
|
114
126
|
},
|
|
115
127
|
},
|
|
116
128
|
dark: {
|
|
117
129
|
primary: {
|
|
118
|
-
background: '
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
hoverColor: '{surface.0}',
|
|
122
|
-
activeBackground: '{primary.400}',
|
|
123
|
-
activeColor: '{surface.0}',
|
|
130
|
+
background: 'var(--tk-color-base-primary-500)',
|
|
131
|
+
hoverBackground: 'var(--tk-color-base-primary-400)',
|
|
132
|
+
activeBackground: 'var(--tk-color-base-primary-400)',
|
|
124
133
|
borderColor: 'transparent',
|
|
125
134
|
hoverBorderColor: 'transparent',
|
|
126
135
|
activeBorderColor: 'transparent',
|
|
127
136
|
},
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
fontWeight: '{font.weight.medium}',
|
|
135
|
-
hoverColor: '{primary.400}',
|
|
136
|
-
hoverBackground: 'none',
|
|
137
|
-
activeColor: '{primary.300}',
|
|
138
|
-
activeBackground: 'none',
|
|
137
|
+
secondary: {
|
|
138
|
+
background: 'var(--tk-color-base-surface-0)',
|
|
139
|
+
hoverBackground: 'var(--tk-color-base-surface-200)',
|
|
140
|
+
borderColor: 'var(--tk-color-base-surface-200)',
|
|
141
|
+
hoverBorderColor: 'var(--tk-color-base-surface-200)',
|
|
142
|
+
activeBorderColor: 'var(--tk-color-base-surface-200)',
|
|
139
143
|
},
|
|
144
|
+
danger: {
|
|
145
|
+
background: 'var(--tk-color-base-red-500)',
|
|
146
|
+
hoverBackground: 'var(--tk-color-base-red-600)',
|
|
147
|
+
activeBackground: 'var(--tk-color-base-red-700)',
|
|
148
|
+
borderColor: 'var(--tk-color-base-red-500)',
|
|
149
|
+
hoverBorderColor: 'var(--tk-color-base-red-600)',
|
|
150
|
+
activeBorderColor: 'var(--tk-color-base-red-700)',
|
|
151
|
+
}
|
|
140
152
|
},
|
|
141
153
|
},
|
|
142
154
|
},
|
|
143
|
-
|
|
155
|
+
dialog: {
|
|
156
|
+
colorScheme: {
|
|
157
|
+
dark: {
|
|
158
|
+
root: {
|
|
159
|
+
background: 'var(--tk-color-base-surface-0)',
|
|
160
|
+
borderColor: 'var(--tk-color-base-surface-200)',
|
|
161
|
+
},
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
}
|
|
144
166
|
});
|
|
145
167
|
|
|
146
168
|
function themeFactory(config, document) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tekus-design-system-core.mjs","sources":["../../../projects/design-system/core/types/src/grids/grid.enum.ts","../../../projects/design-system/core/types/src/breakpoints/breakpoints.ts","../../../projects/design-system/core/types/src/theme/tk-preset.ts","../../../projects/design-system/core/types/src/theme/theme.provider.ts","../../../projects/design-system/core/tekus-design-system-core.ts"],"sourcesContent":["enum GapGutter {\n normal = '24px',\n small = '16px',\n large = '32px',\n extraLarge = '40px',\n}\n\nenum PaddingGridContainer {\n large = '32px',\n medium = '24px',\n small = '16px'\n}\n\nenum Gutter {\n normal = 'normal',\n small = 'small',\n large = 'large',\n extraLarge = 'extraLarge',\n\n}\n\nexport {\n Gutter,\n GapGutter,\n PaddingGridContainer\n}","export const Breakpoints = {\n // Covers all devices with a width less than or equal to 360px.\n mobileSmall: '(max-width: 360px)',\n\n // For small phones (e.g., most modern cell phones)\n mobile: '(min-width: 361px) and (max-width: 424px)',\n\n // For large phones (e.g., Google Pixel, iPhone Plus/Max)\n mobileLarge: '(min-width: 425px) and (max-width: 575px)',\n\n // Vertical tablets and medium-sized devices\n tabletVertical: '(min-width: 576px) and (max-width: 767px)',\n\n // Tablets in landscape mode\n tabletHorizontal: '(min-width: 768px) and (max-width: 991px)',\n\n // Laptops and small desktops\n desktopSmall: '(min-width: 992px) and (max-width: 1199px)',\n\n // Large desks\n desktop: '(min-width: 1200px) and (max-width: 1399px)',\n\n // Ultra-wide screens\n desktopLarge: '(min-width: 1400px)',\n}","import { definePreset } from '@primeng/themes';\nimport Aura from '@primeng/themes/aura';\n\nexport const TkPreset = definePreset(Aura, {\n semantic: {\n primary: {\n 500: 'var(--tk-color-base-primary-500)',\n 400: 'var(--tk-color-base-primary-400)',\n 300: 'var(--tk-color-base-primary-300)',\n },\n surface: {\n 0: 'var(--tk-color-base-surface-0)',\n },\n text: {\n default: 'var(--tk-color-text-default)',\n },\n },\n font: {\n family: 'var(tk-font-family)',\n size: {\n md: 'var(--tk-font-size-base-150)',\n '2xs': 'var(--tk-font-size-base-100)',\n },\n weight: {\n regular: 'var(--tk-font-weight-400)',\n medium: '500',\n bold: 'var(--tk-font-weight-600)',\n },\n },\n spacing: {\n 3: 'var(--tk-spacing-base-75)',\n 4: 'var(--tk-spacing-base-100)',\n 6: 'var(--tk-spacing-base-150)',\n 8: 'var(--tk-spacing-base-200)',\n },\n components: {\n button: {\n root: {\n outline: 'none',\n boxShadow: 'none',\n border: 'none',\n focusBoxShadow: 'none',\n },\n label: {\n color: 'inherit',\n },\n colorScheme: {\n light: {\n primary: {\n background: '{primary.500}',\n color: '{surface.0}',\n hoverBackground: '{primary.400}',\n hoverColor: '{surface.0}',\n activeBackground: '{primary.400}',\n activeColor: '{surface.0}',\n borderColor: 'transparent',\n hoverBorderColor: 'transparent',\n activeBorderColor: 'transparent',\n },\n link: {\n textDecoration: 'underline',\n background: 'none',\n boxShadow: 'none',\n color: '{primary.500}',\n fontSize: '{font.size.2xs}',\n fontWeight: '{font.weight.medium}',\n hoverColor: '{primary.400}',\n hoverBackground: 'none',\n activeColor: '{primary.300}',\n activeBackground: 'none',\n },\n },\n dark: {\n primary: {\n background: '{primary.500}',\n color: '{surface.0}',\n hoverBackground: '{primary.400}',\n hoverColor: '{surface.0}',\n activeBackground: '{primary.400}',\n activeColor: '{surface.0}',\n borderColor: 'transparent',\n hoverBorderColor: 'transparent',\n activeBorderColor: 'transparent',\n },\n link: {\n textDecoration: 'underline',\n background: 'none',\n boxShadow: 'none',\n color: '{primary.500}',\n fontSize: '{font.size.2xs}',\n fontWeight: '{font.weight.medium}',\n hoverColor: '{primary.400}',\n hoverBackground: 'none',\n activeColor: '{primary.300}',\n activeBackground: 'none',\n },\n },\n },\n },\n },\n});\n","import { inject, provideAppInitializer } from '@angular/core';\nimport { DOCUMENT } from '@angular/common';\nimport { PrimeNG } from 'primeng/config';\nimport { TkPreset } from './tk-preset';\n\nfunction themeFactory(config: PrimeNG, document: Document): () => void {\n return () => {\n const fontLink = document.createElement('link');\n fontLink.rel = 'stylesheet';\n fontLink.href =\n 'https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap';\n document.head.appendChild(fontLink);\n\n const style = document.createElement('style');\n style.innerHTML = `\n body {\n font-family: 'Poppins', sans-serif;\n }\n `;\n document.head.appendChild(style);\n\n config.theme.set({\n preset: TkPreset,\n options: {\n prefix: 'tk',\n darkMode: false\n },\n });\n };\n}\n\nexport function provideTkTheme() {\n return provideAppInitializer(() => {\n const config = inject(PrimeNG);\n const document = inject(DOCUMENT);\n return themeFactory(config, document)();\n });\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAAA,IAAK;AAAL,CAAA,UAAK,SAAS,EAAA;AACV,IAAA,SAAA,CAAA,QAAA,CAAA,GAAA,MAAe;AACf,IAAA,SAAA,CAAA,OAAA,CAAA,GAAA,MAAc;AACd,IAAA,SAAA,CAAA,OAAA,CAAA,GAAA,MAAc;AACd,IAAA,SAAA,CAAA,YAAA,CAAA,GAAA,MAAmB;AACvB,CAAC,EALI,SAAS,KAAT,SAAS,GAKb,EAAA,CAAA,CAAA;AAED,IAAK;AAAL,CAAA,UAAK,oBAAoB,EAAA;AACrB,IAAA,oBAAA,CAAA,OAAA,CAAA,GAAA,MAAc;AACd,IAAA,oBAAA,CAAA,QAAA,CAAA,GAAA,MAAe;AACf,IAAA,oBAAA,CAAA,OAAA,CAAA,GAAA,MAAc;AAClB,CAAC,EAJI,oBAAoB,KAApB,oBAAoB,GAIxB,EAAA,CAAA,CAAA;AAED,IAAK;AAAL,CAAA,UAAK,MAAM,EAAA;AACP,IAAA,MAAA,CAAA,QAAA,CAAA,GAAA,QAAiB;AACjB,IAAA,MAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACf,IAAA,MAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACf,IAAA,MAAA,CAAA,YAAA,CAAA,GAAA,YAAyB;AAE7B,CAAC,EANI,MAAM,KAAN,MAAM,GAMV,EAAA,CAAA,CAAA;;ACnBY,MAAA,WAAW,GAAG;;AAEvB,IAAA,WAAW,EAAE,oBAAoB;;AAG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,OAAO,YAAY,CAAC,MAAM,EAAE,QAAQ,CAAC,EAAE;AACzC,KAAC,CAAC;AACJ;;ACrCA;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"tekus-design-system-core.mjs","sources":["../../../projects/design-system/core/types/src/grids/grid.enum.ts","../../../projects/design-system/core/types/src/breakpoints/breakpoints.ts","../../../projects/design-system/core/types/src/theme/tk-preset.ts","../../../projects/design-system/core/types/src/theme/theme.provider.ts","../../../projects/design-system/core/tekus-design-system-core.ts"],"sourcesContent":["enum GapGutter {\n normal = '24px',\n small = '16px',\n large = '32px',\n extraLarge = '40px',\n}\n\nenum PaddingGridContainer {\n large = '32px',\n medium = '24px',\n small = '16px'\n}\n\nenum Gutter {\n normal = 'normal',\n small = 'small',\n large = 'large',\n extraLarge = 'extraLarge',\n\n}\n\nexport {\n Gutter,\n GapGutter,\n PaddingGridContainer\n}","export const Breakpoints = {\n // Covers all devices with a width less than or equal to 360px.\n mobileSmall: '(max-width: 360px)',\n\n // For small phones (e.g., most modern cell phones)\n mobile: '(min-width: 361px) and (max-width: 424px)',\n\n // For large phones (e.g., Google Pixel, iPhone Plus/Max)\n mobileLarge: '(min-width: 425px) and (max-width: 575px)',\n\n // Vertical tablets and medium-sized devices\n tabletVertical: '(min-width: 576px) and (max-width: 767px)',\n\n // Tablets in landscape mode\n tabletHorizontal: '(min-width: 768px) and (max-width: 991px)',\n\n // Laptops and small desktops\n desktopSmall: '(min-width: 992px) and (max-width: 1199px)',\n\n // Large desks\n desktop: '(min-width: 1200px) and (max-width: 1399px)',\n\n // Ultra-wide screens\n desktopLarge: '(min-width: 1400px)',\n}","import { definePreset } from '@primeng/themes';\nimport Aura from '@primeng/themes/aura';\n\nexport const TkPreset = definePreset(Aura, {\n semantic: {\n primary: {\n 50: 'var(--tk-color-base-primary-50)',\n 100: 'var(--tk-color-base-primary-100)',\n 200: 'var(--tk-color-base-primary-200)',\n 300: 'var(--tk-color-base-primary-300)',\n 400: 'var(--tk-color-base-primary-400)',\n 500: 'var(--tk-color-base-primary-500)',\n 600: 'var(--tk-color-base-primary-600)',\n 700: 'var(--tk-color-base-primary-700)',\n 800: 'var(--tk-color-base-primary-800)',\n 900: 'var(--tk-color-base-primary-900)',\n 950: 'var(--tk-color-base-primary-950)'\n },\n red: {\n 50: 'var(--tk-color-base-red-50)',\n 100: 'var(--tk-color-base-red-100)',\n 200: 'var(--tk-color-base-red-200)',\n 300: 'var(--tk-color-base-red-300)',\n 400: 'var(--tk-color-base-red-400)',\n 500: 'var(--tk-color-base-red-500)',\n 600: 'var(--tk-color-base-red-600)',\n 700: 'var(--tk-color-base-red-700)',\n 800: 'var(--tk-color-base-red-800)',\n 900: 'var(--tk-color-base-red-900)',\n 950: 'var(--tk-color-base-red-950)'\n },\n surface: {\n 0: 'var(--tk-color-base-surface-0)',\n 50: 'var(--tk-color-base-surface-50)',\n 100: 'var(--tk-color-base-surface-100)',\n 200: 'var(--tk-color-base-surface-200)',\n 300: 'var(--tk-color-base-surface-300)',\n 400: 'var(--tk-color-base-surface-400)',\n 500: 'var(--tk-color-base-surface-500)',\n 600: 'var(--tk-color-base-surface-600)',\n 700: 'var(--tk-color-base-surface-700)',\n 800: 'var(--tk-color-base-surface-800)',\n 900: 'var(--tk-color-base-surface-900)',\n 950: 'var(--tk-color-base-surface-950)'\n },\n },\n font: {\n family: 'var(--tk-font-family)',\n },\n\n components: {\n button: {\n root: {\n outline: 'none',\n boxShadow: 'none',\n border: 'none',\n focusBoxShadow: 'none',\n },\n label: {\n color: 'inherit',\n },\n colorScheme: {\n light: {\n root: {\n primary: {\n hoverBackground: 'var(--tk-color-base-primary-400)',\n activeBackground: 'var(--tk-color-base-primary-400)',\n hoverBorderColor: 'transparent',\n activeBorderColor: 'transparent',\n },\n secondary: {\n background: 'var(--tk-color-base-surface-0)',\n hoverBackground: 'var(--tk-color-base-surface-100)',\n borderColor: 'var(--tk-color-base-surface-200)',\n hoverBorderColor: 'var(--tk-color-base-surface-200)',\n activeBorderColor: 'var(--tk-color-base-surface-200)',\n },\n },\n text: {\n secondary: {\n hoverBackground: 'var(--tk-color-base-surface-200)',\n activeBackground: 'var(--tk-color-base-surface-200)',\n },\n },\n },\n dark: {\n primary: {\n background: 'var(--tk-color-base-primary-500)',\n hoverBackground: 'var(--tk-color-base-primary-400)',\n activeBackground: 'var(--tk-color-base-primary-400)',\n borderColor: 'transparent',\n hoverBorderColor: 'transparent',\n activeBorderColor: 'transparent',\n },\n secondary: {\n background: 'var(--tk-color-base-surface-0)',\n hoverBackground: 'var(--tk-color-base-surface-200)',\n borderColor: 'var(--tk-color-base-surface-200)',\n hoverBorderColor: 'var(--tk-color-base-surface-200)',\n activeBorderColor: 'var(--tk-color-base-surface-200)',\n },\n danger: {\n background: 'var(--tk-color-base-red-500)',\n hoverBackground: 'var(--tk-color-base-red-600)',\n activeBackground: 'var(--tk-color-base-red-700)',\n borderColor: 'var(--tk-color-base-red-500)',\n hoverBorderColor: 'var(--tk-color-base-red-600)',\n activeBorderColor: 'var(--tk-color-base-red-700)',\n }\n },\n },\n },\n dialog: {\n colorScheme: {\n dark: {\n root: {\n background: 'var(--tk-color-base-surface-0)',\n borderColor: 'var(--tk-color-base-surface-200)',\n },\n }\n }\n }\n }\n});\n","import { inject, provideAppInitializer } from '@angular/core';\nimport { DOCUMENT } from '@angular/common';\nimport { PrimeNG } from 'primeng/config';\nimport { TkPreset } from './tk-preset';\n\nfunction themeFactory(config: PrimeNG, document: Document): () => void {\n return () => {\n const fontLink = document.createElement('link');\n fontLink.rel = 'stylesheet';\n fontLink.href =\n 'https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap';\n document.head.appendChild(fontLink);\n\n const style = document.createElement('style');\n style.innerHTML = `\n body {\n font-family: 'Poppins', sans-serif;\n }\n `;\n document.head.appendChild(style);\n\n config.theme.set({\n preset: TkPreset,\n options: {\n prefix: 'tk',\n darkMode: false\n },\n });\n };\n}\n\nexport function provideTkTheme() {\n return provideAppInitializer(() => {\n const config = inject(PrimeNG);\n const document = inject(DOCUMENT);\n return themeFactory(config, document)();\n });\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAAA,IAAK;AAAL,CAAA,UAAK,SAAS,EAAA;AACV,IAAA,SAAA,CAAA,QAAA,CAAA,GAAA,MAAe;AACf,IAAA,SAAA,CAAA,OAAA,CAAA,GAAA,MAAc;AACd,IAAA,SAAA,CAAA,OAAA,CAAA,GAAA,MAAc;AACd,IAAA,SAAA,CAAA,YAAA,CAAA,GAAA,MAAmB;AACvB,CAAC,EALI,SAAS,KAAT,SAAS,GAKb,EAAA,CAAA,CAAA;AAED,IAAK;AAAL,CAAA,UAAK,oBAAoB,EAAA;AACrB,IAAA,oBAAA,CAAA,OAAA,CAAA,GAAA,MAAc;AACd,IAAA,oBAAA,CAAA,QAAA,CAAA,GAAA,MAAe;AACf,IAAA,oBAAA,CAAA,OAAA,CAAA,GAAA,MAAc;AAClB,CAAC,EAJI,oBAAoB,KAApB,oBAAoB,GAIxB,EAAA,CAAA,CAAA;AAED,IAAK;AAAL,CAAA,UAAK,MAAM,EAAA;AACP,IAAA,MAAA,CAAA,QAAA,CAAA,GAAA,QAAiB;AACjB,IAAA,MAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACf,IAAA,MAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACf,IAAA,MAAA,CAAA,YAAA,CAAA,GAAA,YAAyB;AAE7B,CAAC,EANI,MAAM,KAAN,MAAM,GAMV,EAAA,CAAA,CAAA;;ACnBY,MAAA,WAAW,GAAG;;AAEvB,IAAA,WAAW,EAAE,oBAAoB;;AAGjC,IAAA,MAAM,EAAE,2CAA2C;;AAGnD,IAAA,WAAW,EAAE,2CAA2C;;AAGxD,IAAA,cAAc,EAAE,2CAA2C;;AAG3D,IAAA,gBAAgB,EAAE,2CAA2C;;AAG7D,IAAA,YAAY,EAAE,4CAA4C;;AAG1D,IAAA,OAAO,EAAE,6CAA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,QAAA,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC;AACf,YAAA,MAAM,EAAE,QAAQ;AAChB,YAAA,OAAO,EAAE;AACP,gBAAA,MAAM,EAAE,IAAI;AACZ,gBAAA,QAAQ,EAAE;AACX,aAAA;AACF,SAAA,CAAC;AACJ,KAAC;AACH;SAEgB,cAAc,GAAA;IAC5B,OAAO,qBAAqB,CAAC,MAAK;AAChC,QAAA,MAAM,MAAM,GAAG,MAAM,CAAC,OAAO,CAAC;AAC9B,QAAA,MAAM,QAAQ,GAAG,MAAM,CAAC,QAAQ,CAAC;AACjC,QAAA,OAAO,YAAY,CAAC,MAAM,EAAE,QAAQ,CAAC,EAAE;AACzC,KAAC,CAAC;AACJ;;ACrCA;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tekus/design-system",
|
|
3
3
|
"description": "Tekus design system library",
|
|
4
|
-
"version": "5.
|
|
4
|
+
"version": "5.2.0",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"peerDependencies": {
|
|
7
7
|
"@angular/core": "^19.2.15",
|
|
@@ -47,14 +47,18 @@
|
|
|
47
47
|
"types": "./components/fallback-view/index.d.ts",
|
|
48
48
|
"default": "./fesm2022/tekus-design-system-components-fallback-view.mjs"
|
|
49
49
|
},
|
|
50
|
-
"./
|
|
51
|
-
"types": "./
|
|
52
|
-
"default": "./fesm2022/tekus-design-system-
|
|
50
|
+
"./components/modal": {
|
|
51
|
+
"types": "./components/modal/index.d.ts",
|
|
52
|
+
"default": "./fesm2022/tekus-design-system-components-modal.mjs"
|
|
53
53
|
},
|
|
54
54
|
"./directives/gird-item": {
|
|
55
55
|
"types": "./directives/gird-item/index.d.ts",
|
|
56
56
|
"default": "./fesm2022/tekus-design-system-directives-gird-item.mjs"
|
|
57
57
|
},
|
|
58
|
+
"./core/types": {
|
|
59
|
+
"types": "./core/types/index.d.ts",
|
|
60
|
+
"default": "./fesm2022/tekus-design-system-core-types.mjs"
|
|
61
|
+
},
|
|
58
62
|
"./utils/sanitizer-utils": {
|
|
59
63
|
"types": "./utils/sanitizer-utils/index.d.ts",
|
|
60
64
|
"default": "./fesm2022/tekus-design-system-utils-sanitizer-utils.mjs"
|