@masterteam/components 0.0.16 → 0.0.17
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/common.css +20 -0
- package/breadcrumb/index.d.ts +12 -0
- package/fesm2022/masterteam-components-breadcrumb.mjs +26 -0
- package/fesm2022/masterteam-components-breadcrumb.mjs.map +1 -0
- package/fesm2022/masterteam-components-paginator.mjs +50 -0
- package/fesm2022/masterteam-components-paginator.mjs.map +1 -0
- package/fesm2022/masterteam-components-radio-button-field.mjs +84 -0
- package/fesm2022/masterteam-components-radio-button-field.mjs.map +1 -0
- package/fesm2022/masterteam-components-radio-cards-field.mjs +70 -0
- package/fesm2022/masterteam-components-radio-cards-field.mjs.map +1 -0
- package/fesm2022/masterteam-components-radio-cards.mjs +116 -0
- package/fesm2022/masterteam-components-radio-cards.mjs.map +1 -0
- package/fesm2022/masterteam-components.mjs +128 -0
- package/fesm2022/masterteam-components.mjs.map +1 -1
- package/package.json +49 -29
- package/paginator/index.d.ts +20 -0
- package/radio-button-field/index.d.ts +40 -0
- package/radio-cards/index.d.ts +36 -0
- package/radio-cards-field/index.d.ts +30 -0
package/assets/common.css
CHANGED
|
@@ -1,6 +1,26 @@
|
|
|
1
1
|
@import "tailwindcss";
|
|
2
2
|
@plugin "tailwindcss-primeui";
|
|
3
3
|
|
|
4
|
+
@source inline("{dark:,}bg-primary-{50,{100..900..100},950}");
|
|
5
|
+
@source inline("bg-teal-{50,{100..900..100},550}");
|
|
6
|
+
@source inline("bg-violet-{50,{100..900..100},550}");
|
|
7
|
+
@source inline("bg-red-{50,{100..900..100},550}");
|
|
8
|
+
|
|
9
|
+
@source inline("border-primary-{50,{100..500..100},550}");
|
|
10
|
+
@source inline("border-teal-{50,{100..500..100},550}");
|
|
11
|
+
@source inline("border-violet-{50,{100..500..100},550}");
|
|
12
|
+
@source inline("border-red-{50,{100..500..100},550}");
|
|
13
|
+
|
|
14
|
+
@source inline("ring-primary-{50,{100..500..100},550}");
|
|
15
|
+
@source inline("ring-teal-{50,{100..500..100},550}");
|
|
16
|
+
@source inline("ring-violet-{50,{100..500..100},550}");
|
|
17
|
+
@source inline("ring-red-{50,{100..500..100},550}");
|
|
18
|
+
|
|
19
|
+
@source inline("text-primary-{50,{100..500..100},550}");
|
|
20
|
+
@source inline("text-teal-{50,{100..500..100},550}");
|
|
21
|
+
@source inline("text-violet-{50,{100..500..100},550}");
|
|
22
|
+
@source inline("text-red-{50,{100..500..100},550}");
|
|
23
|
+
|
|
4
24
|
@custom-variant dark (&:where(.dark, .dark *));
|
|
5
25
|
|
|
6
26
|
:root {
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import * as _angular_core from '@angular/core';
|
|
2
|
+
import { MenuItem } from 'primeng/api';
|
|
3
|
+
|
|
4
|
+
declare class Breadcrumb {
|
|
5
|
+
readonly items: _angular_core.InputSignal<MenuItem[]>;
|
|
6
|
+
readonly home: _angular_core.InputSignal<MenuItem>;
|
|
7
|
+
readonly styleClass: _angular_core.InputSignal<string | undefined>;
|
|
8
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<Breadcrumb, never>;
|
|
9
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<Breadcrumb, "mt-breadcrumb", never, { "items": { "alias": "items"; "required": false; "isSignal": true; }; "home": { "alias": "home"; "required": false; "isSignal": true; }; "styleClass": { "alias": "styleClass"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export { Breadcrumb };
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, Component } from '@angular/core';
|
|
3
|
+
import * as i1 from 'primeng/breadcrumb';
|
|
4
|
+
import { BreadcrumbModule } from 'primeng/breadcrumb';
|
|
5
|
+
|
|
6
|
+
class Breadcrumb {
|
|
7
|
+
items = input([], ...(ngDevMode ? [{ debugName: "items" }] : []));
|
|
8
|
+
home = input({ icon: 'pi pi-home' }, ...(ngDevMode ? [{ debugName: "home" }] : []));
|
|
9
|
+
styleClass = input(undefined, ...(ngDevMode ? [{ debugName: "styleClass" }] : []));
|
|
10
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: Breadcrumb, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
11
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.1.3", type: Breadcrumb, isStandalone: true, selector: "mt-breadcrumb", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: false, transformFunction: null }, home: { classPropertyName: "home", publicName: "home", isSignal: true, isRequired: false, transformFunction: null }, styleClass: { classPropertyName: "styleClass", publicName: "styleClass", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "styleClass()" }, classAttribute: "grid gap-1" }, ngImport: i0, template: "<p-breadcrumb [model]=\"items()\" [home]=\"home()\" />\n", styles: [""], dependencies: [{ kind: "ngmodule", type: BreadcrumbModule }, { kind: "component", type: i1.Breadcrumb, selector: "p-breadcrumb", inputs: ["model", "style", "styleClass", "home", "homeAriaLabel"], outputs: ["onItemClick"] }] });
|
|
12
|
+
}
|
|
13
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: Breadcrumb, decorators: [{
|
|
14
|
+
type: Component,
|
|
15
|
+
args: [{ selector: 'mt-breadcrumb', standalone: true, imports: [BreadcrumbModule], host: {
|
|
16
|
+
class: 'grid gap-1',
|
|
17
|
+
'[class]': 'styleClass()',
|
|
18
|
+
}, template: "<p-breadcrumb [model]=\"items()\" [home]=\"home()\" />\n" }]
|
|
19
|
+
}] });
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* Generated bundle index. Do not edit.
|
|
23
|
+
*/
|
|
24
|
+
|
|
25
|
+
export { Breadcrumb };
|
|
26
|
+
//# sourceMappingURL=masterteam-components-breadcrumb.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"masterteam-components-breadcrumb.mjs","sources":["../../../../packages/masterteam/components/breadcrumb/breadcrumb.ts","../../../../packages/masterteam/components/breadcrumb/breadcrumb.html","../../../../packages/masterteam/components/breadcrumb/masterteam-components-breadcrumb.ts"],"sourcesContent":["import { Component, input } from '@angular/core';\nimport { MenuItem } from 'primeng/api';\nimport { BreadcrumbModule } from 'primeng/breadcrumb';\n\n@Component({\n selector: 'mt-breadcrumb',\n standalone: true,\n imports: [BreadcrumbModule],\n templateUrl: './breadcrumb.html',\n styleUrls: ['./breadcrumb.scss'],\n host: {\n class: 'grid gap-1',\n '[class]': 'styleClass()',\n },\n})\nexport class Breadcrumb {\n readonly items = input<MenuItem[]>([]);\n readonly home = input<MenuItem>({ icon: 'pi pi-home' });\n readonly styleClass = input<string | undefined>(undefined);\n}\n","<p-breadcrumb [model]=\"items()\" [home]=\"home()\" />\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;MAea,UAAU,CAAA;AACZ,IAAA,KAAK,GAAG,KAAK,CAAa,EAAE,iDAAC;IAC7B,IAAI,GAAG,KAAK,CAAW,EAAE,IAAI,EAAE,YAAY,EAAE,EAAA,IAAA,SAAA,GAAA,CAAA,EAAA,SAAA,EAAA,MAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAC;AAC9C,IAAA,UAAU,GAAG,KAAK,CAAqB,SAAS,sDAAC;uGAH/C,UAAU,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAAV,UAAU,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,eAAA,EAAA,MAAA,EAAA,EAAA,KAAA,EAAA,EAAA,iBAAA,EAAA,OAAA,EAAA,UAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,E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import { FormsModule } from '@angular/forms';
|
|
4
|
+
import * as i1 from 'primeng/paginator';
|
|
5
|
+
import { PaginatorModule } from 'primeng/paginator';
|
|
6
|
+
import * as i2 from 'primeng/api';
|
|
7
|
+
|
|
8
|
+
class Paginator {
|
|
9
|
+
rows = model(10, ...(ngDevMode ? [{ debugName: "rows" }] : []));
|
|
10
|
+
totalRecords = input(0, ...(ngDevMode ? [{ debugName: "totalRecords" }] : []));
|
|
11
|
+
first = model(0, ...(ngDevMode ? [{ debugName: "first" }] : []));
|
|
12
|
+
page = model(0, ...(ngDevMode ? [{ debugName: "page" }] : []));
|
|
13
|
+
rowsPerPageOptions = input(undefined, ...(ngDevMode ? [{ debugName: "rowsPerPageOptions" }] : []));
|
|
14
|
+
showFirstLastIcon = input(false, ...(ngDevMode ? [{ debugName: "showFirstLastIcon", transform: booleanAttribute }] : [{
|
|
15
|
+
transform: booleanAttribute,
|
|
16
|
+
}]));
|
|
17
|
+
showCurrentPageReport = input(false, ...(ngDevMode ? [{ debugName: "showCurrentPageReport", transform: booleanAttribute }] : [{
|
|
18
|
+
transform: booleanAttribute,
|
|
19
|
+
}]));
|
|
20
|
+
fluid = input(false, ...(ngDevMode ? [{ debugName: "fluid", transform: booleanAttribute }] : [{
|
|
21
|
+
transform: booleanAttribute,
|
|
22
|
+
}]));
|
|
23
|
+
// Paginator Inputs
|
|
24
|
+
pageLinkSize = input(6, ...(ngDevMode ? [{ debugName: "pageLinkSize" }] : []));
|
|
25
|
+
alwaysShow = input(true, ...(ngDevMode ? [{ debugName: "alwaysShow", transform: booleanAttribute }] : [{
|
|
26
|
+
transform: booleanAttribute,
|
|
27
|
+
}]));
|
|
28
|
+
onPageChange = output();
|
|
29
|
+
onPaginatorChange(event) {
|
|
30
|
+
this.first.set(event.first);
|
|
31
|
+
this.page.set(event.page);
|
|
32
|
+
this.rows.set(event.rows);
|
|
33
|
+
this.onPageChange.emit(event);
|
|
34
|
+
}
|
|
35
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: Paginator, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
36
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.1.3", type: Paginator, isStandalone: true, selector: "mt-paginator", inputs: { rows: { classPropertyName: "rows", publicName: "rows", isSignal: true, isRequired: false, transformFunction: null }, totalRecords: { classPropertyName: "totalRecords", publicName: "totalRecords", isSignal: true, isRequired: false, transformFunction: null }, first: { classPropertyName: "first", publicName: "first", isSignal: true, isRequired: false, transformFunction: null }, page: { classPropertyName: "page", publicName: "page", isSignal: true, isRequired: false, transformFunction: null }, rowsPerPageOptions: { classPropertyName: "rowsPerPageOptions", publicName: "rowsPerPageOptions", isSignal: true, isRequired: false, transformFunction: null }, showFirstLastIcon: { classPropertyName: "showFirstLastIcon", publicName: "showFirstLastIcon", isSignal: true, isRequired: false, transformFunction: null }, showCurrentPageReport: { classPropertyName: "showCurrentPageReport", publicName: "showCurrentPageReport", isSignal: true, isRequired: false, transformFunction: null }, fluid: { classPropertyName: "fluid", publicName: "fluid", isSignal: true, isRequired: false, transformFunction: null }, pageLinkSize: { classPropertyName: "pageLinkSize", publicName: "pageLinkSize", isSignal: true, isRequired: false, transformFunction: null }, alwaysShow: { classPropertyName: "alwaysShow", publicName: "alwaysShow", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { rows: "rowsChange", first: "firstChange", page: "pageChange", onPageChange: "onPageChange" }, host: { classAttribute: "grid gap-1" }, ngImport: i0, template: "<p-paginator\n [rows]=\"rows()\"\n [totalRecords]=\"totalRecords()\"\n [first]=\"first()\"\n [pageLinkSize]=\"pageLinkSize()\"\n [rowsPerPageOptions]=\"rowsPerPageOptions()\"\n [showFirstLastIcon]=\"showFirstLastIcon()\"\n [showCurrentPageReport]=\"showCurrentPageReport()\"\n [alwaysShow]=\"alwaysShow()\"\n (onPageChange)=\"onPaginatorChange($event)\"\n appendTo=\"body\"\n>\n <ng-template pTemplate=\"previouspagelinkicon\">\n <div class=\"flex items-center justify-center px-3 gap-3\">\n <svg\n width=\"12\"\n height=\"12\"\n viewBox=\"0 0 14 14\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n d=\"M12.8346 6.99984H1.16797M1.16797 6.99984L7.0013 12.8332M1.16797 6.99984L7.0013 1.1665\"\n stroke=\"#414651\"\n stroke-width=\"1.67\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n </svg>\n <span>Previous</span>\n </div>\n </ng-template>\n\n <ng-template pTemplate=\"nextpagelinkicon\">\n <div class=\"flex items-center justify-center px-3 gap-3\">\n <span>Next</span>\n <svg\n width=\"12\"\n height=\"12\"\n viewBox=\"0 0 14 14\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n d=\"M1.16797 6.99984H12.8346M12.8346 6.99984L7.0013 1.1665M12.8346 6.99984L7.0013 12.8332\"\n stroke=\"#414651\"\n stroke-width=\"1.67\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n </svg>\n </div>\n </ng-template>\n</p-paginator>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: PaginatorModule }, { kind: "component", type: i1.Paginator, selector: "p-paginator", inputs: ["pageLinkSize", "styleClass", "alwaysShow", "dropdownAppendTo", "templateLeft", "templateRight", "dropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showFirstLastIcon", "totalRecords", "rows", "rowsPerPageOptions", "showJumpToPageDropdown", "showJumpToPageInput", "jumpToPageItemTemplate", "showPageLinks", "locale", "dropdownItemTemplate", "first", "appendTo"], outputs: ["onPageChange"] }, { kind: "directive", type: i2.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }] });
|
|
37
|
+
}
|
|
38
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: Paginator, decorators: [{
|
|
39
|
+
type: Component,
|
|
40
|
+
args: [{ selector: 'mt-paginator', standalone: true, imports: [FormsModule, PaginatorModule], host: {
|
|
41
|
+
class: 'grid gap-1',
|
|
42
|
+
}, template: "<p-paginator\n [rows]=\"rows()\"\n [totalRecords]=\"totalRecords()\"\n [first]=\"first()\"\n [pageLinkSize]=\"pageLinkSize()\"\n [rowsPerPageOptions]=\"rowsPerPageOptions()\"\n [showFirstLastIcon]=\"showFirstLastIcon()\"\n [showCurrentPageReport]=\"showCurrentPageReport()\"\n [alwaysShow]=\"alwaysShow()\"\n (onPageChange)=\"onPaginatorChange($event)\"\n appendTo=\"body\"\n>\n <ng-template pTemplate=\"previouspagelinkicon\">\n <div class=\"flex items-center justify-center px-3 gap-3\">\n <svg\n width=\"12\"\n height=\"12\"\n viewBox=\"0 0 14 14\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n d=\"M12.8346 6.99984H1.16797M1.16797 6.99984L7.0013 12.8332M1.16797 6.99984L7.0013 1.1665\"\n stroke=\"#414651\"\n stroke-width=\"1.67\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n </svg>\n <span>Previous</span>\n </div>\n </ng-template>\n\n <ng-template pTemplate=\"nextpagelinkicon\">\n <div class=\"flex items-center justify-center px-3 gap-3\">\n <span>Next</span>\n <svg\n width=\"12\"\n height=\"12\"\n viewBox=\"0 0 14 14\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n d=\"M1.16797 6.99984H12.8346M12.8346 6.99984L7.0013 1.1665M12.8346 6.99984L7.0013 12.8332\"\n stroke=\"#414651\"\n stroke-width=\"1.67\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n </svg>\n </div>\n </ng-template>\n</p-paginator>\n" }]
|
|
43
|
+
}] });
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* Generated bundle index. Do not edit.
|
|
47
|
+
*/
|
|
48
|
+
|
|
49
|
+
export { Paginator };
|
|
50
|
+
//# sourceMappingURL=masterteam-components-paginator.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"masterteam-components-paginator.mjs","sources":["../../../../packages/masterteam/components/paginator/paginator.ts","../../../../packages/masterteam/components/paginator/paginator.html","../../../../packages/masterteam/components/paginator/masterteam-components-paginator.ts"],"sourcesContent":["import {\n booleanAttribute,\n Component,\n input,\n output,\n model,\n} from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { PaginatorModule } from 'primeng/paginator';\n\n@Component({\n selector: 'mt-paginator',\n standalone: true,\n imports: [FormsModule, PaginatorModule],\n templateUrl: './paginator.html',\n styleUrls: ['./paginator.scss'],\n host: {\n class: 'grid gap-1',\n },\n})\nexport class Paginator {\n readonly rows = model<number>(10);\n readonly totalRecords = input<number>(0);\n readonly first = model<number>(0);\n readonly page = model<number>(0);\n readonly rowsPerPageOptions = input<number[] | undefined>(undefined);\n readonly showFirstLastIcon = input<boolean, unknown>(false, {\n transform: booleanAttribute,\n });\n readonly showCurrentPageReport = input<boolean, unknown>(false, {\n transform: booleanAttribute,\n });\n readonly fluid = input<boolean, unknown>(false, {\n transform: booleanAttribute,\n });\n\n // Paginator Inputs\n readonly pageLinkSize = input<number | undefined>(6);\n readonly alwaysShow = input<boolean, unknown>(true, {\n transform: booleanAttribute,\n });\n\n readonly onPageChange = output<any>();\n\n onPaginatorChange(event: any) {\n this.first.set(event.first);\n this.page.set(event.page);\n this.rows.set(event.rows);\n this.onPageChange.emit(event);\n }\n}\n","<p-paginator\n [rows]=\"rows()\"\n [totalRecords]=\"totalRecords()\"\n [first]=\"first()\"\n [pageLinkSize]=\"pageLinkSize()\"\n [rowsPerPageOptions]=\"rowsPerPageOptions()\"\n [showFirstLastIcon]=\"showFirstLastIcon()\"\n [showCurrentPageReport]=\"showCurrentPageReport()\"\n [alwaysShow]=\"alwaysShow()\"\n (onPageChange)=\"onPaginatorChange($event)\"\n appendTo=\"body\"\n>\n <ng-template pTemplate=\"previouspagelinkicon\">\n <div class=\"flex items-center justify-center px-3 gap-3\">\n <svg\n width=\"12\"\n height=\"12\"\n viewBox=\"0 0 14 14\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n d=\"M12.8346 6.99984H1.16797M1.16797 6.99984L7.0013 12.8332M1.16797 6.99984L7.0013 1.1665\"\n stroke=\"#414651\"\n stroke-width=\"1.67\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n </svg>\n <span>Previous</span>\n </div>\n </ng-template>\n\n <ng-template pTemplate=\"nextpagelinkicon\">\n <div class=\"flex items-center justify-center px-3 gap-3\">\n <span>Next</span>\n <svg\n width=\"12\"\n height=\"12\"\n viewBox=\"0 0 14 14\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n d=\"M1.16797 6.99984H12.8346M12.8346 6.99984L7.0013 1.1665M12.8346 6.99984L7.0013 12.8332\"\n stroke=\"#414651\"\n stroke-width=\"1.67\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n </svg>\n </div>\n </ng-template>\n</p-paginator>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;MAoBa,SAAS,CAAA;AACX,IAAA,IAAI,GAAG,KAAK,CAAS,EAAE,gDAAC;AACxB,IAAA,YAAY,GAAG,KAAK,CAAS,CAAC,wDAAC;AAC/B,IAAA,KAAK,GAAG,KAAK,CAAS,CAAC,iDAAC;AACxB,IAAA,IAAI,GAAG,KAAK,CAAS,CAAC,gDAAC;AACvB,IAAA,kBAAkB,GAAG,KAAK,CAAuB,SAAS,8DAAC;IAC3D,iBAAiB,GAAG,KAAK,CAAmB,KAAK,qDACxD,SAAS,EAAE,gBAAgB,EAAA,CAAA,GAAA,CAD+B;AAC1D,YAAA,SAAS,EAAE,gBAAgB;AAC5B,SAAA,CAAA,CAAA,CAAC;IACO,qBAAqB,GAAG,KAAK,CAA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,wBAAA,KAAK,EAAE,YAAY;AACpB,qBAAA,EAAA,QAAA,EAAA,4mDAAA,EAAA;;;AElBH;;AAEG;;;;"}
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, output, inject, computed, signal, effect, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
|
+
import * as i1 from '@angular/forms';
|
|
4
|
+
import { NgControl, Validators, FormsModule } from '@angular/forms';
|
|
5
|
+
import * as i2 from 'primeng/radiobutton';
|
|
6
|
+
import { RadioButtonModule } from 'primeng/radiobutton';
|
|
7
|
+
import { FieldValidation } from '@masterteam/components/field-validation';
|
|
8
|
+
import { isInvalid } from '@masterteam/components';
|
|
9
|
+
|
|
10
|
+
class RadioButtonField {
|
|
11
|
+
radioButton;
|
|
12
|
+
labelPosition = input('end', ...(ngDevMode ? [{ debugName: "labelPosition" }] : []));
|
|
13
|
+
readonly = input(false, ...(ngDevMode ? [{ debugName: "readonly" }] : []));
|
|
14
|
+
pInputs = input(...(ngDevMode ? [undefined, { debugName: "pInputs" }] : []));
|
|
15
|
+
required = input(false, ...(ngDevMode ? [{ debugName: "required" }] : []));
|
|
16
|
+
options = input([], ...(ngDevMode ? [{ debugName: "options" }] : []));
|
|
17
|
+
size = input(...(ngDevMode ? [undefined, { debugName: "size" }] : []));
|
|
18
|
+
label = input(...(ngDevMode ? [undefined, { debugName: "label" }] : []));
|
|
19
|
+
onChange = output();
|
|
20
|
+
ngControl = inject(NgControl, { self: true });
|
|
21
|
+
isInvalid = isInvalid;
|
|
22
|
+
isVertical = computed(() => this.labelPosition() === 'top' || this.labelPosition() === 'bottom', ...(ngDevMode ? [{ debugName: "isVertical" }] : []));
|
|
23
|
+
requiredValidator = Validators.required;
|
|
24
|
+
value = signal(null, ...(ngDevMode ? [{ debugName: "value" }] : []));
|
|
25
|
+
disabled = signal(false, ...(ngDevMode ? [{ debugName: "disabled" }] : []));
|
|
26
|
+
onTouched = () => { };
|
|
27
|
+
onModelChange = () => { };
|
|
28
|
+
constructor() {
|
|
29
|
+
if (this.ngControl) {
|
|
30
|
+
this.ngControl.valueAccessor = this;
|
|
31
|
+
}
|
|
32
|
+
// Effect to apply pInputs reactively when the pInputs signal changes
|
|
33
|
+
effect(() => {
|
|
34
|
+
const currentPInputs = this.pInputs();
|
|
35
|
+
if (this.radioButton && currentPInputs) {
|
|
36
|
+
this.applyInputsToRadioButton();
|
|
37
|
+
}
|
|
38
|
+
});
|
|
39
|
+
// Effect to add required validator if required input is true
|
|
40
|
+
effect(() => {
|
|
41
|
+
if (this.ngControl?.control && this.required()) {
|
|
42
|
+
this.ngControl.control.addValidators(Validators.required);
|
|
43
|
+
this.ngControl.control.updateValueAndValidity();
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
applyInputsToRadioButton() {
|
|
48
|
+
const currentPInputs = this.pInputs();
|
|
49
|
+
if (currentPInputs) {
|
|
50
|
+
Object.assign(this.radioButton, currentPInputs);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
onValueChange(value) {
|
|
54
|
+
this.onModelChange(value);
|
|
55
|
+
this.value.set(value);
|
|
56
|
+
}
|
|
57
|
+
writeValue(value) {
|
|
58
|
+
this.value.set(value);
|
|
59
|
+
}
|
|
60
|
+
registerOnChange(fn) {
|
|
61
|
+
this.onModelChange = fn;
|
|
62
|
+
}
|
|
63
|
+
registerOnTouched(fn) {
|
|
64
|
+
this.onTouched = fn;
|
|
65
|
+
}
|
|
66
|
+
setDisabledState(disabled) {
|
|
67
|
+
this.disabled.set(disabled);
|
|
68
|
+
}
|
|
69
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: RadioButtonField, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
70
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.3", type: RadioButtonField, isStandalone: true, selector: "mt-radio-button-field", inputs: { labelPosition: { classPropertyName: "labelPosition", publicName: "labelPosition", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, pInputs: { classPropertyName: "pInputs", publicName: "pInputs", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onChange: "onChange" }, host: { classAttribute: "grid gap-1" }, ngImport: i0, template: "@if (label()) {\n <label\n [class.required]=\"ngControl?.control?.hasValidator(requiredValidator)\"\n >{{ label() }}</label\n >\n}\n\n@for (option of options(); track option) {\n <div\n class=\"flex gap-1\"\n [class.items-center]=\"!isVertical()\"\n [class.gap-2]=\"!isVertical()\"\n [class.flex-col]=\"isVertical()\"\n [class.flex-col-reverse]=\"labelPosition() === 'top'\"\n [class.flex-row-reverse]=\"labelPosition() === 'start'\"\n [class.justify-end]=\"labelPosition() === 'start'\"\n >\n <p-radiobutton\n [size]=\"size()\"\n #radiobutton\n [ngModel]=\"value()\"\n [value]=\"option.value\"\n [inputId]=\"option?.label\"\n (ngModelChange)=\"onValueChange($event)\"\n (onClick)=\"onChange.emit($event)\"\n (onBlur)=\"onTouched()\"\n [disabled]=\"disabled() || readonly()\"\n [invalid]=\"isInvalid(ngControl?.control)\"\n class=\"leading-none\"\n ></p-radiobutton>\n\n @if (option?.label) {\n <label [for]=\"option?.label\">{{ option?.label }}</label>\n }\n </div>\n}\n<mt-field-validation [control]=\"ngControl?.control\"></mt-field-validation>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: RadioButtonModule }, { kind: "component", type: i2.RadioButton, selector: "p-radioButton, p-radiobutton, p-radio-button", inputs: ["value", "tabindex", "inputId", "ariaLabelledBy", "ariaLabel", "styleClass", "autofocus", "binary", "variant", "size"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: FieldValidation, selector: "mt-field-validation", inputs: ["control", "touched"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
71
|
+
}
|
|
72
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: RadioButtonField, decorators: [{
|
|
73
|
+
type: Component,
|
|
74
|
+
args: [{ selector: 'mt-radio-button-field', standalone: true, imports: [FormsModule, RadioButtonModule, FieldValidation], changeDetection: ChangeDetectionStrategy.OnPush, host: {
|
|
75
|
+
class: 'grid gap-1',
|
|
76
|
+
}, template: "@if (label()) {\n <label\n [class.required]=\"ngControl?.control?.hasValidator(requiredValidator)\"\n >{{ label() }}</label\n >\n}\n\n@for (option of options(); track option) {\n <div\n class=\"flex gap-1\"\n [class.items-center]=\"!isVertical()\"\n [class.gap-2]=\"!isVertical()\"\n [class.flex-col]=\"isVertical()\"\n [class.flex-col-reverse]=\"labelPosition() === 'top'\"\n [class.flex-row-reverse]=\"labelPosition() === 'start'\"\n [class.justify-end]=\"labelPosition() === 'start'\"\n >\n <p-radiobutton\n [size]=\"size()\"\n #radiobutton\n [ngModel]=\"value()\"\n [value]=\"option.value\"\n [inputId]=\"option?.label\"\n (ngModelChange)=\"onValueChange($event)\"\n (onClick)=\"onChange.emit($event)\"\n (onBlur)=\"onTouched()\"\n [disabled]=\"disabled() || readonly()\"\n [invalid]=\"isInvalid(ngControl?.control)\"\n class=\"leading-none\"\n ></p-radiobutton>\n\n @if (option?.label) {\n <label [for]=\"option?.label\">{{ option?.label }}</label>\n }\n </div>\n}\n<mt-field-validation [control]=\"ngControl?.control\"></mt-field-validation>\n" }]
|
|
77
|
+
}], ctorParameters: () => [] });
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* Generated bundle index. Do not edit.
|
|
81
|
+
*/
|
|
82
|
+
|
|
83
|
+
export { RadioButtonField };
|
|
84
|
+
//# sourceMappingURL=masterteam-components-radio-button-field.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"masterteam-components-radio-button-field.mjs","sources":["../../../../packages/masterteam/components/radio-button-field/radio-button-field.ts","../../../../packages/masterteam/components/radio-button-field/radio-button-field.html","../../../../packages/masterteam/components/radio-button-field/masterteam-components-radio-button-field.ts"],"sourcesContent":["import {\n Component,\n signal,\n input,\n output,\n inject,\n ChangeDetectionStrategy,\n computed,\n effect,\n} from '@angular/core';\nimport {\n ControlValueAccessor,\n FormsModule,\n NgControl,\n Validators,\n} from '@angular/forms';\nimport { RadioButton, RadioButtonModule } from 'primeng/radiobutton';\nimport { FieldValidation } from '@masterteam/components/field-validation';\nimport { isInvalid } from '@masterteam/components';\n\nexport interface radioOptions {\n label: string;\n value: string;\n}\n\n@Component({\n selector: 'mt-radio-button-field',\n standalone: true,\n imports: [FormsModule, RadioButtonModule, FieldValidation],\n templateUrl: './radio-button-field.html',\n styleUrls: ['./radio-button-field.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n class: 'grid gap-1',\n },\n})\nexport class RadioButtonField implements ControlValueAccessor {\n radioButton: RadioButton;\n labelPosition = input<'top' | 'start' | 'end' | 'bottom'>('end');\n readonly = input<boolean>(false);\n pInputs = input<Partial<RadioButton>>();\n required = input<boolean>(false);\n options = input<radioOptions[]>([]);\n size = input<'small' | 'large' | undefined>();\n label = input<string>();\n onChange = output<string>();\n\n public ngControl = inject(NgControl, { self: true });\n\n isInvalid = isInvalid;\n\n isVertical = computed(\n () => this.labelPosition() === 'top' || this.labelPosition() === 'bottom',\n );\n\n requiredValidator = Validators.required;\n value = signal<string | null>(null);\n disabled = signal<boolean>(false);\n\n onTouched: () => void = () => {};\n onModelChange: (value: string | null) => void = () => {};\n\n constructor() {\n if (this.ngControl) {\n this.ngControl.valueAccessor = this;\n }\n\n // Effect to apply pInputs reactively when the pInputs signal changes\n effect(() => {\n const currentPInputs = this.pInputs();\n\n if (this.radioButton && currentPInputs) {\n this.applyInputsToRadioButton();\n }\n });\n\n // Effect to add required validator if required input is true\n effect(() => {\n if (this.ngControl?.control && this.required()) {\n this.ngControl.control.addValidators(Validators.required);\n this.ngControl.control.updateValueAndValidity();\n }\n });\n }\n\n applyInputsToRadioButton() {\n const currentPInputs = this.pInputs();\n if (currentPInputs) {\n Object.assign(this.radioButton, currentPInputs);\n }\n }\n\n onValueChange(value: string | null) {\n this.onModelChange(value);\n this.value.set(value);\n }\n\n writeValue(value: string | null) {\n this.value.set(value);\n }\n\n registerOnChange(fn: any) {\n this.onModelChange = fn;\n }\n\n registerOnTouched(fn: any) {\n this.onTouched = fn;\n }\n\n setDisabledState(disabled: boolean) {\n this.disabled.set(disabled);\n }\n}\n","@if (label()) {\n <label\n [class.required]=\"ngControl?.control?.hasValidator(requiredValidator)\"\n >{{ label() }}</label\n >\n}\n\n@for (option of options(); track option) {\n <div\n class=\"flex gap-1\"\n [class.items-center]=\"!isVertical()\"\n [class.gap-2]=\"!isVertical()\"\n [class.flex-col]=\"isVertical()\"\n [class.flex-col-reverse]=\"labelPosition() === 'top'\"\n [class.flex-row-reverse]=\"labelPosition() === 'start'\"\n [class.justify-end]=\"labelPosition() === 'start'\"\n >\n <p-radiobutton\n [size]=\"size()\"\n #radiobutton\n [ngModel]=\"value()\"\n [value]=\"option.value\"\n [inputId]=\"option?.label\"\n (ngModelChange)=\"onValueChange($event)\"\n (onClick)=\"onChange.emit($event)\"\n (onBlur)=\"onTouched()\"\n [disabled]=\"disabled() || readonly()\"\n [invalid]=\"isInvalid(ngControl?.control)\"\n class=\"leading-none\"\n ></p-radiobutton>\n\n @if (option?.label) {\n <label [for]=\"option?.label\">{{ option?.label }}</label>\n }\n </div>\n}\n<mt-field-validation [control]=\"ngControl?.control\"></mt-field-validation>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;MAoCa,gBAAgB,CAAA;AAC3B,IAAA,WAAW;AACX,IAAA,aAAa,GAAG,KAAK,CAAqC,KAAK,yDAAC;AAChE,IAAA,QAAQ,GAAG,KAAK,CAAU,KAAK,oDAAC;IAChC,OAAO,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,SAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAwB;AACvC,IAAA,QAAQ,GAAG,KAAK,CAAU,KAAK,oDAAC;AAChC,IAAA,OAAO,GAAG,KAAK,CAAiB,EAAE,mDAAC;IACnC,IAAI,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,MAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAiC;IAC7C,KAAK,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,OAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAU;IACvB,QAAQ,GAAG,MAAM,EAAU;IAEpB,SAAS,GAAG,MAAM,CAAC,SAAS,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;IAEpD,SAAS,GAAG,SAAS;IAErB,UAAU,GAAG,QAAQ,CACnB,MAAM,IAAI,CAAC,aAAa,EAAE,KAAK,KAAK,IAAI,IAAI,CAAC,aAAa,EAAE,KAAK,QAAQ,sDAC1E;AAED,IAAA,iBAAiB,GAAG,UAAU,CAAC,QAAQ;AACvC,IAAA,KAAK,GAAG,MAAM,CAAgB,IAAI,iDAAC;AACnC,IAAA,QAAQ,GAAG,MAAM,CAAU,KAAK,oDAAC;AAEjC,IAAA,SAA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CAAC,WAAW,EAAE,iBAAiB,EAAE,eAAe,CAAC,EAAA,eAAA,EAGzC,uBAAuB,CAAC,MAAM,EAAA,IAAA,EACzC;AACJ,wBAAA,KAAK,EAAE,YAAY;AACpB,qBAAA,EAAA,QAAA,EAAA,moCAAA,EAAA;;;AElCH;;AAEG;;;;"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, booleanAttribute, contentChild, TemplateRef, signal, inject, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
|
+
import { Validators, NgControl, FormsModule } from '@angular/forms';
|
|
4
|
+
import { RadioCards } from '@masterteam/components/radio-cards';
|
|
5
|
+
import { FieldValidation } from '@masterteam/components/field-validation';
|
|
6
|
+
|
|
7
|
+
class RadioCardsField {
|
|
8
|
+
circle = input(false, ...(ngDevMode ? [{ debugName: "circle", transform: booleanAttribute }] : [{
|
|
9
|
+
transform: booleanAttribute,
|
|
10
|
+
}]));
|
|
11
|
+
label = input(...(ngDevMode ? [undefined, { debugName: "label" }] : []));
|
|
12
|
+
required = input(false, ...(ngDevMode ? [{ debugName: "required" }] : []));
|
|
13
|
+
color = input('primary', ...(ngDevMode ? [{ debugName: "color" }] : []));
|
|
14
|
+
size = input('medium', ...(ngDevMode ? [{ debugName: "size" }] : []));
|
|
15
|
+
options = input.required(...(ngDevMode ? [{ debugName: "options" }] : []));
|
|
16
|
+
itemTemplate = contentChild('option', ...(ngDevMode ? [{ debugName: "itemTemplate", read: TemplateRef }] : [{ read: TemplateRef }]));
|
|
17
|
+
selectedId = signal(null, ...(ngDevMode ? [{ debugName: "selectedId" }] : []));
|
|
18
|
+
isDisabled = signal(false, ...(ngDevMode ? [{ debugName: "isDisabled" }] : []));
|
|
19
|
+
requiredValidator = Validators.required;
|
|
20
|
+
ngControl = null;
|
|
21
|
+
constructor() {
|
|
22
|
+
try {
|
|
23
|
+
this.ngControl = inject(NgControl, { self: true, optional: true });
|
|
24
|
+
if (this.ngControl) {
|
|
25
|
+
this.ngControl.valueAccessor = this;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
catch (_e) {
|
|
29
|
+
this.ngControl = null;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
// --- CVA Methods ---
|
|
33
|
+
onChange = () => { };
|
|
34
|
+
onTouched = () => { };
|
|
35
|
+
writeValue(value) {
|
|
36
|
+
this.selectedId.set(value);
|
|
37
|
+
}
|
|
38
|
+
registerOnChange(fn) {
|
|
39
|
+
this.onChange = fn;
|
|
40
|
+
}
|
|
41
|
+
registerOnTouched(fn) {
|
|
42
|
+
this.onTouched = fn;
|
|
43
|
+
}
|
|
44
|
+
setDisabledState(isDisabled) {
|
|
45
|
+
this.isDisabled.set(isDisabled);
|
|
46
|
+
}
|
|
47
|
+
onSelectionChange(selectedItem) {
|
|
48
|
+
if (!this.isDisabled()) {
|
|
49
|
+
const newId = selectedItem.id;
|
|
50
|
+
this.selectedId.set(newId);
|
|
51
|
+
this.onChange(newId);
|
|
52
|
+
this.onTouched();
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: RadioCardsField, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
56
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.3", type: RadioCardsField, isStandalone: true, selector: "mt-radio-cards-field", inputs: { circle: { classPropertyName: "circle", publicName: "circle", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: true, transformFunction: null } }, host: { classAttribute: "grid gap-1" }, providers: [], queries: [{ propertyName: "itemTemplate", first: true, predicate: ["option"], descendants: true, read: TemplateRef, isSignal: true }], ngImport: i0, template: "@if (label()) {\n <label\n [class.required]=\"ngControl?.control?.hasValidator(requiredValidator)\"\n [for]=\"ngControl?.name || label()\"\n >{{ label() }}</label\n >\n}\n<div\n class=\"relative\"\n [class.opacity-50]=\"isDisabled()\"\n [class.pointer-events-none]=\"isDisabled()\"\n [id]=\"ngControl?.name || label()\"\n>\n <mt-radio-cards\n [options]=\"options()\"\n [activeId]=\"selectedId()\"\n [color]=\"color()\"\n [size]=\"size()\"\n [circle]=\"circle()\"\n (selectionChange)=\"onSelectionChange($event)\"\n [itemTemplate]=\"itemTemplate()\"\n ></mt-radio-cards>\n</div>\n\n<mt-field-validation [control]=\"ngControl?.control\"></mt-field-validation>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "component", type: RadioCards, selector: "mt-radio-cards", inputs: ["circle", "color", "size", "options", "activeId", "itemTemplate"], outputs: ["optionsChange", "activeIdChange", "selectionChange"] }, { kind: "component", type: FieldValidation, selector: "mt-field-validation", inputs: ["control", "touched"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
57
|
+
}
|
|
58
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: RadioCardsField, decorators: [{
|
|
59
|
+
type: Component,
|
|
60
|
+
args: [{ selector: 'mt-radio-cards-field', standalone: true, imports: [FormsModule, RadioCards, FieldValidation], changeDetection: ChangeDetectionStrategy.OnPush, host: {
|
|
61
|
+
class: 'grid gap-1',
|
|
62
|
+
}, providers: [], template: "@if (label()) {\n <label\n [class.required]=\"ngControl?.control?.hasValidator(requiredValidator)\"\n [for]=\"ngControl?.name || label()\"\n >{{ label() }}</label\n >\n}\n<div\n class=\"relative\"\n [class.opacity-50]=\"isDisabled()\"\n [class.pointer-events-none]=\"isDisabled()\"\n [id]=\"ngControl?.name || label()\"\n>\n <mt-radio-cards\n [options]=\"options()\"\n [activeId]=\"selectedId()\"\n [color]=\"color()\"\n [size]=\"size()\"\n [circle]=\"circle()\"\n (selectionChange)=\"onSelectionChange($event)\"\n [itemTemplate]=\"itemTemplate()\"\n ></mt-radio-cards>\n</div>\n\n<mt-field-validation [control]=\"ngControl?.control\"></mt-field-validation>\n" }]
|
|
63
|
+
}], ctorParameters: () => [] });
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Generated bundle index. Do not edit.
|
|
67
|
+
*/
|
|
68
|
+
|
|
69
|
+
export { RadioCardsField };
|
|
70
|
+
//# sourceMappingURL=masterteam-components-radio-cards-field.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"masterteam-components-radio-cards-field.mjs","sources":["../../../../packages/masterteam/components/radio-cards-field/radio-cards-field.ts","../../../../packages/masterteam/components/radio-cards-field/radio-cards-field.html","../../../../packages/masterteam/components/radio-cards-field/masterteam-components-radio-cards-field.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n input,\n signal,\n TemplateRef,\n contentChild,\n inject,\n booleanAttribute,\n} from '@angular/core';\nimport {\n ControlValueAccessor,\n FormsModule,\n NgControl,\n Validators,\n} from '@angular/forms';\nimport { RadioCards, RadioItem } from '@masterteam/components/radio-cards';\nimport { FieldValidation } from '@masterteam/components/field-validation';\n\n@Component({\n selector: 'mt-radio-cards-field',\n standalone: true,\n imports: [FormsModule, RadioCards, FieldValidation],\n templateUrl: './radio-cards-field.html',\n styleUrl: './radio-cards-field.css',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n class: 'grid gap-1',\n },\n providers: [],\n})\nexport class RadioCardsField implements ControlValueAccessor {\n readonly circle = input<boolean, unknown>(false, {\n transform: booleanAttribute,\n });\n readonly label = input<string>();\n readonly required = input<boolean>(false);\n readonly color = input<string>('primary');\n readonly size = input<'small' | 'medium' | 'large'>('medium');\n readonly options = input.required<RadioItem[]>();\n readonly itemTemplate = contentChild('option', { read: TemplateRef });\n\n protected selectedId = signal<string | number | null>(null);\n protected isDisabled = signal(false);\n\n requiredValidator = Validators.required;\n\n public ngControl: NgControl | null = null;\n\n constructor() {\n try {\n this.ngControl = inject(NgControl, { self: true, optional: true });\n if (this.ngControl) {\n this.ngControl.valueAccessor = this;\n }\n } catch (_e) {\n this.ngControl = null;\n }\n }\n\n // --- CVA Methods ---\n private onChange: (value: string | number) => void = () => {};\n private onTouched: () => void = () => {};\n\n writeValue(value: string | number): void {\n this.selectedId.set(value);\n }\n\n registerOnChange(fn: (value: string | number) => void): void {\n this.onChange = fn;\n }\n\n registerOnTouched(fn: () => void): void {\n this.onTouched = fn;\n }\n\n setDisabledState(isDisabled: boolean): void {\n this.isDisabled.set(isDisabled);\n }\n\n onSelectionChange(selectedItem: RadioItem): void {\n if (!this.isDisabled()) {\n const newId = selectedItem.id;\n this.selectedId.set(newId);\n this.onChange(newId);\n this.onTouched();\n }\n }\n}\n","@if (label()) {\n <label\n [class.required]=\"ngControl?.control?.hasValidator(requiredValidator)\"\n [for]=\"ngControl?.name || label()\"\n >{{ label() }}</label\n >\n}\n<div\n class=\"relative\"\n [class.opacity-50]=\"isDisabled()\"\n [class.pointer-events-none]=\"isDisabled()\"\n [id]=\"ngControl?.name || label()\"\n>\n <mt-radio-cards\n [options]=\"options()\"\n [activeId]=\"selectedId()\"\n [color]=\"color()\"\n [size]=\"size()\"\n [circle]=\"circle()\"\n (selectionChange)=\"onSelectionChange($event)\"\n [itemTemplate]=\"itemTemplate()\"\n ></mt-radio-cards>\n</div>\n\n<mt-field-validation [control]=\"ngControl?.control\"></mt-field-validation>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;MA+Ba,eAAe,CAAA;IACjB,MAAM,GAAG,KAAK,CAAmB,KAAK,0CAC7C,SAAS,EAAE,gBAAgB,EAAA,CAAA,GAAA,CADoB;AAC/C,YAAA,SAAS,EAAE,gBAAgB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,uBAAA,CAAA,MAAA,EAAA,CAAA;;2FASvC,eAAe,EAAA,UAAA,EAAA,CAAA;kBAZ3B,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,sBAAsB,EAAA,UAAA,EACpB,IAAI,EAAA,OAAA,EACP,CAAC,WAAW,EAAE,UAAU,EAAE,eAAe,CAAC,EAAA,eAAA,EAGlC,uBAAuB,CAAC,MAAM,EAAA,IAAA,EACzC;AACJ,wBAAA,KAAK,EAAE,YAAY;AACpB,qBAAA,EAAA,SAAA,EACU,EAAE,EAAA,QAAA,EAAA,2rBAAA,EAAA;;;AE7Bf;;AAEG;;;;"}
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, booleanAttribute, computed, model, output, contentChild, TemplateRef, effect, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
|
+
import { Avatar } from '@masterteam/components/avatar';
|
|
4
|
+
import { NgTemplateOutlet } from '@angular/common';
|
|
5
|
+
|
|
6
|
+
class RadioCards {
|
|
7
|
+
circle = input(false, ...(ngDevMode ? [{ debugName: "circle", transform: booleanAttribute }] : [{ transform: booleanAttribute }]));
|
|
8
|
+
color = input('primary', ...(ngDevMode ? [{ debugName: "color", transform: (value) => {
|
|
9
|
+
if (value) {
|
|
10
|
+
return value;
|
|
11
|
+
}
|
|
12
|
+
return 'primary';
|
|
13
|
+
} }] : [{
|
|
14
|
+
transform: (value) => {
|
|
15
|
+
if (value) {
|
|
16
|
+
return value;
|
|
17
|
+
}
|
|
18
|
+
return 'primary';
|
|
19
|
+
},
|
|
20
|
+
}]));
|
|
21
|
+
size = input('medium', ...(ngDevMode ? [{ debugName: "size", transform: (value) => {
|
|
22
|
+
if (value) {
|
|
23
|
+
switch (value) {
|
|
24
|
+
case 'small':
|
|
25
|
+
return 'xs';
|
|
26
|
+
case 'medium':
|
|
27
|
+
return 'base';
|
|
28
|
+
case 'large':
|
|
29
|
+
return '2xl';
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
return 'base';
|
|
33
|
+
} }] : [{
|
|
34
|
+
transform: (value) => {
|
|
35
|
+
if (value) {
|
|
36
|
+
switch (value) {
|
|
37
|
+
case 'small':
|
|
38
|
+
return 'xs';
|
|
39
|
+
case 'medium':
|
|
40
|
+
return 'base';
|
|
41
|
+
case 'large':
|
|
42
|
+
return '2xl';
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
return 'base';
|
|
46
|
+
},
|
|
47
|
+
}]));
|
|
48
|
+
avatarSize = computed(() => {
|
|
49
|
+
switch (this.size()) {
|
|
50
|
+
case 'xs':
|
|
51
|
+
return 'normal';
|
|
52
|
+
case 'base':
|
|
53
|
+
return 'large';
|
|
54
|
+
case '2xl':
|
|
55
|
+
return 'xlarge';
|
|
56
|
+
default:
|
|
57
|
+
return 'normal';
|
|
58
|
+
}
|
|
59
|
+
}, ...(ngDevMode ? [{ debugName: "avatarSize" }] : []));
|
|
60
|
+
options = model.required(...(ngDevMode ? [{ debugName: "options" }] : []));
|
|
61
|
+
activeId = model(...(ngDevMode ? [undefined, { debugName: "activeId" }] : []));
|
|
62
|
+
selectionChange = output();
|
|
63
|
+
itemTemplate = input(null, ...(ngDevMode ? [{ debugName: "itemTemplate" }] : []));
|
|
64
|
+
itemTemplateContent = contentChild('option', ...(ngDevMode ? [{ debugName: "itemTemplateContent", read: TemplateRef }] : [{ read: TemplateRef }]));
|
|
65
|
+
/**
|
|
66
|
+
* A computed signal that generates the dynamic Tailwind CSS classes
|
|
67
|
+
* for the active state based on the color input.
|
|
68
|
+
*/
|
|
69
|
+
activeColorClasses = computed(() => {
|
|
70
|
+
const color = this.color();
|
|
71
|
+
return {
|
|
72
|
+
[`bg-${color}-50`]: true,
|
|
73
|
+
[`dark:bg-${color}-800`]: true,
|
|
74
|
+
[`border-${color}-400`]: true,
|
|
75
|
+
[`ring-${color}-200`]: true,
|
|
76
|
+
};
|
|
77
|
+
}, ...(ngDevMode ? [{ debugName: "activeColorClasses" }] : []));
|
|
78
|
+
constructor() {
|
|
79
|
+
effect(() => {
|
|
80
|
+
const active = this.activeId();
|
|
81
|
+
console.log('Active ID changed to:', active);
|
|
82
|
+
this.options.update((options) => {
|
|
83
|
+
return options.map((option) => {
|
|
84
|
+
option.active = option.id === active;
|
|
85
|
+
return option;
|
|
86
|
+
});
|
|
87
|
+
});
|
|
88
|
+
});
|
|
89
|
+
}
|
|
90
|
+
selectItem(item) {
|
|
91
|
+
if (this.activeId() !== item.id) {
|
|
92
|
+
this.activeId.set(item.id);
|
|
93
|
+
this.selectionChange.emit(item);
|
|
94
|
+
}
|
|
95
|
+
const options = this.options();
|
|
96
|
+
options.map((option) => {
|
|
97
|
+
const active = option.id === this.activeId();
|
|
98
|
+
option.active = active;
|
|
99
|
+
return option;
|
|
100
|
+
});
|
|
101
|
+
this.options.set(options);
|
|
102
|
+
}
|
|
103
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: RadioCards, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
104
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.3", type: RadioCards, isStandalone: true, selector: "mt-radio-cards", inputs: { circle: { classPropertyName: "circle", publicName: "circle", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: true, transformFunction: null }, activeId: { classPropertyName: "activeId", publicName: "activeId", isSignal: true, isRequired: false, transformFunction: null }, itemTemplate: { classPropertyName: "itemTemplate", publicName: "itemTemplate", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { options: "optionsChange", activeId: "activeIdChange", selectionChange: "selectionChange" }, queries: [{ propertyName: "itemTemplateContent", first: true, predicate: ["option"], descendants: true, read: TemplateRef, isSignal: true }], ngImport: i0, template: "<div>\n <div class=\"flex flex-wrap gap-3\">\n @for (item of options(); track item.id) {\n <div\n (click)=\"selectItem(item)\"\n class=\"flex items-center space-x-4 p-4 rounded-lg cursor-pointer border-2 border-dashed transition-all ease-in-out duration-300\"\n [class]=\"\n item.active\n ? activeColorClasses()\n : 'border-gray-300 hover:border-gray-400 hover:bg-gray-50 dark:hover:bg-gray-800 hover:text-gray-600 dark:hover:text-gray-100 '\n \"\n >\n <ng-container\n *ngTemplateOutlet=\"\n itemTemplate() || itemTemplateContent() || defaultTemplate;\n context: {\n $implicit: item,\n active: item.active,\n color: color(),\n size: size(),\n }\n \"\n >\n </ng-container>\n </div>\n }\n </div>\n</div>\n\n<ng-template\n #defaultTemplate\n let-template\n let-active=\"active\"\n let-color=\"color\"\n let-size=\"size\"\n>\n @if (template.icon) {\n <mt-avatar\n [shape]=\"circle() ? 'circle' : 'square'\"\n [size]=\"avatarSize()\"\n [icon]=\"template.icon\"\n ></mt-avatar>\n }\n @if (template.name) {\n <span\n class=\"font-semibold\"\n [class]=\"\n 'text-' +\n size +\n ' ' +\n (active\n ? 'text-' + color + '-500'\n : 'dark:text-gray-100 text-gray-600 ')\n \"\n >\n {{ template.name }}\n </span>\n }\n</ng-template>\n", styles: [":host{display:block}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: Avatar, selector: "mt-avatar", inputs: ["label", "icon", "image", "size", "shape", "badge", "badgeSize", "badgeSeverity"], outputs: ["onImageError"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
105
|
+
}
|
|
106
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.3", ngImport: i0, type: RadioCards, decorators: [{
|
|
107
|
+
type: Component,
|
|
108
|
+
args: [{ selector: 'mt-radio-cards', standalone: true, imports: [NgTemplateOutlet, Avatar], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div>\n <div class=\"flex flex-wrap gap-3\">\n @for (item of options(); track item.id) {\n <div\n (click)=\"selectItem(item)\"\n class=\"flex items-center space-x-4 p-4 rounded-lg cursor-pointer border-2 border-dashed transition-all ease-in-out duration-300\"\n [class]=\"\n item.active\n ? activeColorClasses()\n : 'border-gray-300 hover:border-gray-400 hover:bg-gray-50 dark:hover:bg-gray-800 hover:text-gray-600 dark:hover:text-gray-100 '\n \"\n >\n <ng-container\n *ngTemplateOutlet=\"\n itemTemplate() || itemTemplateContent() || defaultTemplate;\n context: {\n $implicit: item,\n active: item.active,\n color: color(),\n size: size(),\n }\n \"\n >\n </ng-container>\n </div>\n }\n </div>\n</div>\n\n<ng-template\n #defaultTemplate\n let-template\n let-active=\"active\"\n let-color=\"color\"\n let-size=\"size\"\n>\n @if (template.icon) {\n <mt-avatar\n [shape]=\"circle() ? 'circle' : 'square'\"\n [size]=\"avatarSize()\"\n [icon]=\"template.icon\"\n ></mt-avatar>\n }\n @if (template.name) {\n <span\n class=\"font-semibold\"\n [class]=\"\n 'text-' +\n size +\n ' ' +\n (active\n ? 'text-' + color + '-500'\n : 'dark:text-gray-100 text-gray-600 ')\n \"\n >\n {{ template.name }}\n </span>\n }\n</ng-template>\n", styles: [":host{display:block}\n"] }]
|
|
109
|
+
}], ctorParameters: () => [] });
|
|
110
|
+
|
|
111
|
+
/**
|
|
112
|
+
* Generated bundle index. Do not edit.
|
|
113
|
+
*/
|
|
114
|
+
|
|
115
|
+
export { RadioCards };
|
|
116
|
+
//# sourceMappingURL=masterteam-components-radio-cards.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"masterteam-components-radio-cards.mjs","sources":["../../../../packages/masterteam/components/radio-cards/radio-cards.ts","../../../../packages/masterteam/components/radio-cards/radio-cards.html","../../../../packages/masterteam/components/radio-cards/masterteam-components-radio-cards.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n contentChild,\n input,\n output,\n TemplateRef,\n computed,\n model,\n effect,\n booleanAttribute,\n} from '@angular/core';\nimport { MTIcon } from '@masterteam/icons';\nimport { Avatar } from '@masterteam/components/avatar';\nimport { NgTemplateOutlet } from '@angular/common';\n\nexport interface RadioItem {\n id: string | number;\n name?: string;\n active?: boolean;\n icon?: MTIcon;\n [key: string]: any;\n}\n\n@Component({\n selector: 'mt-radio-cards',\n standalone: true,\n imports: [NgTemplateOutlet, Avatar],\n templateUrl: './radio-cards.html',\n styleUrl: './radio-cards.css',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class RadioCards {\n circle = input<boolean, unknown>(false, { transform: booleanAttribute });\n color = input('primary', {\n transform: (value: string) => {\n if (value) {\n return value;\n }\n return 'primary';\n },\n });\n size = input('medium', {\n transform: (value: 'small' | 'medium' | 'large') => {\n if (value) {\n switch (value) {\n case 'small':\n return 'xs';\n case 'medium':\n return 'base';\n case 'large':\n return '2xl';\n }\n }\n return 'base';\n },\n });\n avatarSize = computed(() => {\n switch (this.size()) {\n case 'xs':\n return 'normal';\n case 'base':\n return 'large';\n case '2xl':\n return 'xlarge';\n default:\n return 'normal';\n }\n });\n options = model.required<RadioItem[]>();\n activeId = model<string | number>();\n selectionChange = output<RadioItem>();\n\n itemTemplate = input<TemplateRef<any> | null>(null);\n itemTemplateContent = contentChild('option', { read: TemplateRef });\n\n /**\n * A computed signal that generates the dynamic Tailwind CSS classes\n * for the active state based on the color input.\n */\n protected activeColorClasses = computed(() => {\n const color = this.color();\n return {\n [`bg-${color}-50`]: true,\n [`dark:bg-${color}-800`]: true,\n [`border-${color}-400`]: true,\n [`ring-${color}-200`]: true,\n };\n });\n\n constructor() {\n effect(() => {\n const active = this.activeId();\n console.log('Active ID changed to:', active);\n this.options.update((options) => {\n return options.map((option) => {\n option.active = option.id === active;\n return option;\n });\n });\n });\n }\n\n public selectItem(item: RadioItem): void {\n if (this.activeId() !== item.id) {\n this.activeId.set(item.id);\n this.selectionChange.emit(item);\n }\n const options = this.options();\n options.map((option) => {\n const active = option.id === this.activeId();\n option.active = active;\n return option;\n });\n this.options.set(options);\n }\n}\n","<div>\n <div class=\"flex flex-wrap gap-3\">\n @for (item of options(); track item.id) {\n <div\n (click)=\"selectItem(item)\"\n class=\"flex items-center space-x-4 p-4 rounded-lg cursor-pointer border-2 border-dashed transition-all ease-in-out duration-300\"\n [class]=\"\n item.active\n ? activeColorClasses()\n : 'border-gray-300 hover:border-gray-400 hover:bg-gray-50 dark:hover:bg-gray-800 hover:text-gray-600 dark:hover:text-gray-100 '\n \"\n >\n <ng-container\n *ngTemplateOutlet=\"\n itemTemplate() || itemTemplateContent() || defaultTemplate;\n context: {\n $implicit: item,\n active: item.active,\n color: color(),\n size: size(),\n }\n \"\n >\n </ng-container>\n </div>\n }\n </div>\n</div>\n\n<ng-template\n #defaultTemplate\n let-template\n let-active=\"active\"\n let-color=\"color\"\n let-size=\"size\"\n>\n @if (template.icon) {\n <mt-avatar\n [shape]=\"circle() ? 'circle' : 'square'\"\n [size]=\"avatarSize()\"\n [icon]=\"template.icon\"\n ></mt-avatar>\n }\n @if (template.name) {\n <span\n class=\"font-semibold\"\n [class]=\"\n 'text-' +\n size +\n ' ' +\n (active\n ? 'text-' + color + '-500'\n : 'dark:text-gray-100 text-gray-600 ')\n \"\n >\n {{ template.name }}\n </span>\n }\n</ng-template>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;MAgCa,UAAU,CAAA;AACrB,IAAA,MAAM,GAAG,KAAK,CAAmB,KAAK,0CAAI,SAAS,EAAE,gBAAgB,EAAA,CAAA,GAAA,CAA7B,EAAE,SAAS,EAAE,gBAAgB,EAAE,GAAC;IACxE,KAAK,GAAG,KAAK,CAAC,SAAS,EAAA,IAAA,SAAA,GAAA,CAAA,EAAA,SAAA,EAAA,OAAA,EACrB,SAAS,EAAE,CAAC,KAAa,KAAI;gBAC3B,IAAI,KAAK,EAAE;AACT,oBAAA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,WAAA,EAAA,eAAA,CAAA,EAAA,OAAA,EAAA,CAAA,cAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;2FAKvB,UAAU,EAAA,UAAA,EAAA,CAAA;kBARtB,SAAS;+BACE,gBAAgB,EAAA,UAAA,EACd,IAAI,EAAA,OAAA,EACP,CAAC,gBAAgB,EAAE,MAAM,CAAC,EAAA,eAAA,EAGlB,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,2/CAAA,EAAA,MAAA,EAAA,CAAA,wBAAA,CAAA,EAAA;;;AE9BjD;;AAEG;;;;"}
|
|
@@ -225,6 +225,134 @@ const MTPreset = (primaryColor) => definePreset(Aura, {
|
|
|
225
225
|
borderRadius: '{border.radius.lg}',
|
|
226
226
|
},
|
|
227
227
|
},
|
|
228
|
+
breadcrumb: {
|
|
229
|
+
root: {
|
|
230
|
+
padding: '0.5rem 1rem',
|
|
231
|
+
},
|
|
232
|
+
item: {
|
|
233
|
+
color: '{surface.700}',
|
|
234
|
+
hoverColor: '{primary.600}',
|
|
235
|
+
focusRing: {
|
|
236
|
+
color: '{primary.700}',
|
|
237
|
+
},
|
|
238
|
+
borderRadius: '0',
|
|
239
|
+
},
|
|
240
|
+
separator: {
|
|
241
|
+
color: '{surface.500}',
|
|
242
|
+
},
|
|
243
|
+
css: () => `
|
|
244
|
+
.p-breadcrumb-list .p-breadcrumb-item-link {
|
|
245
|
+
font-size: 0.9rem;
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
.p-breadcrumb-list .p-breadcrumb-separator {
|
|
249
|
+
width: 12px
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
.p-breadcrumb-list .p-breadcrumb-item:last-child .p-breadcrumb-item-link {
|
|
253
|
+
color: var(--p-primary-400);
|
|
254
|
+
background: var(--p-primary-50);
|
|
255
|
+
cursor: default;
|
|
256
|
+
pointer-events: none;
|
|
257
|
+
padding: 0 0.4rem
|
|
258
|
+
}
|
|
259
|
+
`,
|
|
260
|
+
},
|
|
261
|
+
paginator: {
|
|
262
|
+
root: {
|
|
263
|
+
borderRadius: '{border.radius.lg}',
|
|
264
|
+
padding: '0 .5rem',
|
|
265
|
+
},
|
|
266
|
+
navButton: {
|
|
267
|
+
borderRadius: '0',
|
|
268
|
+
},
|
|
269
|
+
colorScheme: {
|
|
270
|
+
light: {
|
|
271
|
+
navButton: {
|
|
272
|
+
color: '{surface.600}',
|
|
273
|
+
hoverBackground: '#fff',
|
|
274
|
+
selectedBackground: '{surface.200}',
|
|
275
|
+
selectedColor: '{surface.600}',
|
|
276
|
+
focusRing: {
|
|
277
|
+
color: '{surface.200}',
|
|
278
|
+
},
|
|
279
|
+
},
|
|
280
|
+
},
|
|
281
|
+
dark: {
|
|
282
|
+
navButton: {
|
|
283
|
+
color: '{surface.200}',
|
|
284
|
+
hoverBackground: 'transparent',
|
|
285
|
+
selectedBackground: 'transparent',
|
|
286
|
+
selectedColor: '#fff',
|
|
287
|
+
focusRing: {
|
|
288
|
+
color: '#fff',
|
|
289
|
+
},
|
|
290
|
+
},
|
|
291
|
+
},
|
|
292
|
+
},
|
|
293
|
+
css: () => `
|
|
294
|
+
.p-paginator {
|
|
295
|
+
--p-paginator-gap: 0;
|
|
296
|
+
--p-paginator-nav-button-width: 2.2rem;
|
|
297
|
+
--p-paginator-nav-button-height: 2.2rem;
|
|
298
|
+
width: fit-content;
|
|
299
|
+
border: 1px solid var(--p-surface-200);
|
|
300
|
+
overflow: hidden;
|
|
301
|
+
font-size: .95rem;
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
.p-paginator-pages button,
|
|
305
|
+
.p-paginator-prev,
|
|
306
|
+
.p-paginator-next {
|
|
307
|
+
border-color: var(--p-surface-200);
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
.p-paginator-pages button {
|
|
311
|
+
border-style: solid;
|
|
312
|
+
border-width: 0 0 0 1px;
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
.p-paginator-pages button:first-child {
|
|
316
|
+
border-left: none;
|
|
317
|
+
}
|
|
318
|
+
|
|
319
|
+
.p-paginator-prev {
|
|
320
|
+
border-right: 1px solid var(--p-surface-200);
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
.p-paginator-next {
|
|
324
|
+
border-left: 1px solid var(--p-surface-200);
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
.p-paginator .p-select {
|
|
328
|
+
border: 0;
|
|
329
|
+
background: transparent;
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
.p-paginator .p-select .p-select-label {
|
|
333
|
+
padding: 0;
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
/* Dark Mode Styles */
|
|
337
|
+
.dark .p-paginator {
|
|
338
|
+
border-color: var(--p-surface-500);
|
|
339
|
+
}
|
|
340
|
+
|
|
341
|
+
.dark .p-paginator-pages button,
|
|
342
|
+
.dark .p-paginator-prev,
|
|
343
|
+
.dark .p-paginator-next {
|
|
344
|
+
border-color: var(--p-surface-500);
|
|
345
|
+
}
|
|
346
|
+
|
|
347
|
+
.dark .p-paginator-prev {
|
|
348
|
+
border-right-color: var(--p-surface-500);
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
.dark .p-paginator-next {
|
|
352
|
+
border-left-color: var(--p-surface-500);
|
|
353
|
+
}
|
|
354
|
+
`,
|
|
355
|
+
},
|
|
228
356
|
// steps: {
|
|
229
357
|
// item: {
|
|
230
358
|
// link: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"masterteam-components.mjs","sources":["../../../../packages/masterteam/components/src/lib/utils/theme.ts","../../../../packages/masterteam/components/src/lib/config/providemt.ts","../../../../packages/masterteam/components/src/lib/config/povide-messages.ts","../../../../packages/masterteam/components/src/lib/utils/inputs.ts","../../../../packages/masterteam/components/src/lib/config/dynamic-form.model.ts","../../../../packages/masterteam/components/src/public-api.ts","../../../../packages/masterteam/components/src/masterteam-components.ts"],"sourcesContent":["type HSLTuple = [number, number, number]; // [hue, saturation, lightness]\ntype TailwindColorPalette = {\n [key: string]: string; // e.g., '50': '#f0f9ff', '500': '#0284c7'\n};\n\n/**\n * Converts a hex color string to an HSL tuple.\n * @param hex - The hex color string (e.g., \"#RRGGBB\" or \"#RGB\").\n * @returns An HSL tuple [hue, saturation, lightness] where hue is in degrees (0-360),\n * and saturation/lightness are percentages (0-100).\n */\nfunction hexToHsl(hex: string): HSLTuple {\n let r: number = 0,\n g: number = 0,\n b: number = 0;\n\n // Handle shorthand hex codes\n if (hex.length === 4) {\n r = parseInt(hex[1] + hex[1], 16);\n g = parseInt(hex[2] + hex[2], 16);\n b = parseInt(hex[3] + hex[3], 16);\n } else if (hex.length === 7) {\n r = parseInt(hex.substring(1, 3), 16);\n g = parseInt(hex.substring(3, 5), 16);\n b = parseInt(hex.substring(5, 7), 16);\n } else {\n throw new Error('Invalid hex color format. Expected #RGB or #RRGGBB.');\n }\n\n r /= 255;\n g /= 255;\n b /= 255;\n\n const max: number = Math.max(r, g, b);\n const min: number = Math.min(r, g, b);\n let h: number = 0,\n s: number;\n const l: number = (max + min) / 2;\n\n if (max === min) {\n h = s = 0; // achromatic\n } else {\n const d: number = max - min;\n s = l > 0.5 ? d / (2 - max - min) : d / (max + min);\n switch (max) {\n case r:\n h = (g - b) / d + (g < b ? 6 : 0);\n break;\n case g:\n h = (b - r) / d + 2;\n break;\n case b:\n h = (r - g) / d + 4;\n break;\n }\n h /= 6;\n }\n\n return [h * 360, s * 100, l * 100]; // HSL in degrees, percentage, percentage\n}\n\n/**\n * Converts HSL values to a hex color string.\n * @param h - Hue (0-360).\n * @param s - Saturation (0-100).\n * @param l - Lightness (0-100).\n * @returns The hex color string (e.g., \"#RRGGBB\").\n */\nfunction hslToHex(h: number, s: number, l: number): string {\n l /= 100;\n const a: number = (s * Math.min(l, 1 - l)) / 100;\n const f = (n: number): string => {\n const k: number = (n + h / 30) % 12;\n const color: number = l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n return Math.round(255 * color)\n .toString(16)\n .padStart(2, '0');\n };\n return `#${f(0)}${f(8)}${f(4)}`;\n}\n\n/**\n * Generates a Tailwind-like color palette (50-950) from a primary color (assumed to be 500).\n *\n * @param primaryColor500 - The hex string of the primary color (e.g., \"#0284c7\").\n * @returns An object representing the color palette, where keys are color numbers (e.g., \"50\", \"100\")\n * and values are hex color strings.\n */\nexport function generateTailwindPalette(\n primaryColor500: string,\n): TailwindColorPalette {\n const [h, s, _l]: HSLTuple = hexToHsl(primaryColor500);\n\n const palette: TailwindColorPalette = {\n '500': primaryColor500,\n };\n\n // Define steps for lighter shades (50 - 400)\n const lightnessStepsLighter: { [key: string]: number } = {\n '50': 95,\n '100': 90,\n '200': 80,\n '300': 70,\n '400': 60,\n };\n\n const saturationReductionsLighter: { [key: string]: number } = {\n '50': 40, // More desaturated\n '100': 30,\n '200': 20,\n '300': 10,\n '400': 5, // Slightly desaturated\n };\n\n for (const shade in lightnessStepsLighter) {\n if (Object.prototype.hasOwnProperty.call(lightnessStepsLighter, shade)) {\n const newL: number = lightnessStepsLighter[shade];\n // Ensure saturation doesn't go below 0\n const newS: number = Math.max(0, s - saturationReductionsLighter[shade]);\n palette[shade] = hslToHex(h, newS, newL);\n }\n }\n\n // Define steps for darker shades (600 - 950)\n const lightnessStepsDarker: { [key: string]: number } = {\n '600': 45,\n '700': 35,\n '800': 25,\n '900': 15,\n '950': 8, // More aggressive darkening for 950\n };\n\n const saturationIncreasesDarker: { [key: string]: number } = {\n '600': 5,\n '700': 10,\n '800': 15,\n '900': 20,\n '950': 25, // Can increase saturation for darker shades\n };\n\n for (const shade in lightnessStepsDarker) {\n if (Object.prototype.hasOwnProperty.call(lightnessStepsDarker, shade)) {\n const newL: number = lightnessStepsDarker[shade];\n // Ensure saturation doesn't exceed 100\n const newS: number = Math.min(100, s + saturationIncreasesDarker[shade]);\n palette[shade] = hslToHex(h, newS, newL);\n }\n }\n\n // Sort the keys numerically to ensure consistent order\n const sortedPalette: TailwindColorPalette = {};\n Object.keys(palette)\n .sort((a, b) => parseInt(a) - parseInt(b))\n .forEach((key: string) => {\n sortedPalette[key] = palette[key];\n });\n\n return sortedPalette;\n}\n","import { providePrimeNG } from 'primeng/config';\nimport { generateTailwindPalette } from '../utils/theme';\nimport Aura from '@primeuix/themes/aura';\nimport { definePreset, updatePreset } from '@primeuix/themes';\nimport { ToastTokenSections } from '@primeuix/themes/types/toast';\nimport { EnvironmentProviders } from '@angular/core';\n\nconst toastStyle: ToastTokenSections.Success = {\n // borderColor: '{surface.300}',\n background: '{content.background}',\n // color: '{surface.600}',\n // closeButton: {\n // hoverBackground: '{surface.100}',\n // focusRing: {\n // color: '{surface.600}',\n // },\n // },\n};\n\nexport function changePrimaryColor(color: string): void {\n updatePreset({\n semantic: {\n primary: generateTailwindPalette(color || '#334dff'),\n },\n });\n}\n\nconst MTPreset = (primaryColor?: string) =>\n definePreset(Aura, {\n options: {\n prefix: 'mt',\n cssLayer: {\n name: 'primeng',\n order: 'theme, base, primeng',\n },\n },\n semantic: {\n primary: generateTailwindPalette(primaryColor || '#334dff'),\n content: {\n borderRadius: '{border.radius.lg}',\n },\n formField: {\n borderRadius: '{border.radius.lg}',\n },\n },\n components: {\n toast: {\n root: {\n borderRadius: '{border.radius.xl}',\n },\n colorScheme: {\n light: {\n success: toastStyle,\n info: toastStyle,\n warn: toastStyle,\n error: toastStyle,\n secondary: toastStyle,\n },\n dark: {\n success: toastStyle,\n info: toastStyle,\n warn: toastStyle,\n error: toastStyle,\n secondary: toastStyle,\n },\n },\n },\n togglebutton: {\n root: {\n padding: '1px',\n sm: {\n padding: '1px',\n },\n lg: {\n padding: '1px',\n },\n },\n colorScheme: {\n light: {\n root: {\n checkedColor: '{primary.500}',\n },\n },\n dark: {\n root: {\n checkedColor: '{primary.400}',\n },\n },\n },\n },\n selectbutton: {\n root: {\n borderRadius: '{border.radius.lg}',\n },\n },\n // steps: {\n // item: {\n // link: {\n // gap: 'calc(50% + 0.25rem)',\n // },\n // number: {\n // font: {\n // size: '0.9rem',\n // },\n // active: {\n // color: 'white',\n // background: '{primary.500}',\n // border: {\n // color: '{primary.500}',\n // },\n // },\n // },\n // },\n // },\n },\n });\n\nexport function provideMTComponents(\n primaryColor?: string,\n): EnvironmentProviders {\n return providePrimeNG({\n zIndex: {\n modal: 1900,\n overlay: 1500,\n menu: 1500,\n tooltip: 1600,\n },\n theme: {\n preset: MTPreset(primaryColor),\n options: {\n darkModeSelector: '.dark',\n },\n },\n });\n}\n","import { MessageService } from 'primeng/api';\n\nexport function provideMTMessages() {\n return MessageService;\n}\n","import { AbstractControl } from '@angular/forms';\n\nexport function isInvalid(control: AbstractControl | null) {\n if (!control) return false;\n return control && control?.invalid && control?.touched;\n}\n","import { AbstractControl, ValidationErrors, ValidatorFn } from '@angular/forms';\n\nexport type FieldType =\n | 'text'\n | 'textarea'\n | 'select'\n | 'date'\n | 'number'\n | 'slider'\n | 'multi-select'\n | 'checkbox'\n | 'icon-field'\n | 'color-picker'\n | string;\n\nexport type ValidatorType =\n | 'required'\n | 'email'\n | 'minLength'\n | 'maxLength'\n | 'min'\n | 'max'\n | 'pattern'\n | 'custom';\n\nexport class ValidatorConfig {\n type: ValidatorType;\n value?: any;\n message?: string;\n customValidator?: (value: any) => boolean | Promise<boolean>;\n\n constructor(config: {\n type: ValidatorType;\n value?: any;\n message?: string;\n customValidator?: (value: any) => boolean | Promise<boolean>;\n }) {\n this.type = config.type;\n this.value = config.value;\n this.message = config.message;\n this.customValidator = config.customValidator;\n }\n\n // Factory methods for common validators\n static required(message = 'This field is required'): ValidatorConfig {\n return new ValidatorConfig({ type: 'required', message });\n }\n\n static email(message = 'Please enter a valid email'): ValidatorConfig {\n return new ValidatorConfig({ type: 'email', message });\n }\n\n static minLength(length: number, message?: string): ValidatorConfig {\n return new ValidatorConfig({\n type: 'minLength',\n value: length,\n message: message || `Minimum length is ${length} characters`,\n });\n }\n\n static maxLength(length: number, message?: string): ValidatorConfig {\n return new ValidatorConfig({\n type: 'maxLength',\n value: length,\n message: message || `Maximum length is ${length} characters`,\n });\n }\n\n static min(value: number, message?: string): ValidatorConfig {\n return new ValidatorConfig({\n type: 'min',\n value,\n message: message || `Minimum value is ${value}`,\n });\n }\n\n static max(value: number, message?: string): ValidatorConfig {\n return new ValidatorConfig({\n type: 'max',\n value,\n message: message || `Maximum value is ${value}`,\n });\n }\n\n static pattern(pattern: string, message = 'Invalid format'): ValidatorConfig {\n return new ValidatorConfig({ type: 'pattern', value: pattern, message });\n }\n\n static custom(\n validator: (value: any) => boolean | Promise<boolean>,\n message = 'Invalid value',\n ): ValidatorConfig {\n return new ValidatorConfig({\n type: 'custom',\n customValidator: validator,\n message,\n });\n }\n}\n\nexport type BaseFieldConstructorConfig = ConstructorParameters<\n typeof BaseFieldConfig\n>[0];\n\nexport abstract class BaseFieldConfig {\n key: string;\n label: string;\n type: FieldType;\n required: boolean;\n disabled: boolean;\n readonly: boolean;\n hidden: boolean;\n placeholder: string;\n hint: string;\n cssClass: string;\n validators: ValidatorConfig[];\n order: number;\n\n defaultValue?: any;\n\n customTemplate: string;\n\n constructor(config: {\n key?: string;\n label?: string;\n type: FieldType;\n required?: boolean;\n disabled?: boolean;\n readonly?: boolean;\n hidden?: boolean;\n placeholder?: string;\n hint?: string;\n cssClass?: string;\n validators?: ValidatorConfig[];\n order?: number;\n defaultValue?: any;\n }) {\n this.key = config.key || 'Key';\n this.label = config.label || '';\n this.type = config.type;\n this.required = config.required || false;\n this.disabled = config.disabled || false;\n this.readonly = config.readonly || false;\n this.hidden = config.hidden || false;\n this.placeholder = config.placeholder || '';\n this.hint = config.hint || '';\n this.cssClass = config.cssClass || '';\n this.validators = config.validators || [];\n this.order = config.order || 0;\n this.defaultValue = config.defaultValue;\n }\n}\n\n// Specific configurations for different field types\nexport class TextFieldConfig extends BaseFieldConfig {\n inputType: 'text' | 'email';\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n inputType?: 'text' | 'email';\n },\n ) {\n super({ ...config, type: 'text' });\n this.inputType = config.inputType || 'text';\n }\n}\n\nexport class TextareaFieldConfig extends BaseFieldConfig {\n rows: number;\n autoResize: boolean;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n rows?: number;\n autoResize?: boolean;\n },\n ) {\n super({ ...config, type: 'textarea' });\n this.rows = config.rows || 3;\n this.autoResize = config.autoResize || false;\n }\n}\n\nexport class SelectFieldConfig extends BaseFieldConfig {\n options: any[];\n optionLabel: string;\n optionValue: string;\n multiple: boolean;\n filter: boolean;\n filterBy: string;\n filterPlaceholder: string;\n showClear: boolean;\n emptyMessage: string;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n options: any[];\n optionLabel?: string;\n optionValue?: string;\n multiple?: boolean;\n filter?: boolean;\n filterBy?: string;\n filterPlaceholder?: string;\n showClear?: boolean;\n emptyMessage?: string;\n },\n ) {\n super({ ...config, type: 'select' });\n this.options = config.options;\n this.optionLabel = config.optionLabel || 'label';\n this.optionValue = config.optionValue || 'value';\n this.multiple = config.multiple || false;\n this.filter = config.filter || false;\n this.filterBy = config.filterBy || '';\n this.filterPlaceholder = config.filterPlaceholder || 'Search...';\n this.showClear = config.showClear || false;\n this.emptyMessage = config.emptyMessage || 'No options available';\n }\n}\n\nexport class DateFieldConfig extends BaseFieldConfig {\n dateFormat: string;\n showTime: boolean;\n showSeconds: boolean;\n hourFormat: '12' | '24';\n minDate?: Date;\n maxDate?: Date;\n disabledDates: Date[];\n disabledDays: number[];\n yearRange: string;\n showIcon: boolean;\n icon: string;\n showButtonBar: boolean;\n showClear: boolean;\n inline: boolean;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n dateFormat?: string;\n showTime?: boolean;\n showSeconds?: boolean;\n hourFormat?: '12' | '24';\n minDate?: Date;\n maxDate?: Date;\n disabledDates?: Date[];\n disabledDays?: number[];\n yearRange?: string;\n showIcon?: boolean;\n icon?: string;\n showButtonBar?: boolean;\n showClear?: boolean;\n inline?: boolean;\n },\n ) {\n super({ ...config, type: 'date' });\n this.dateFormat = config.dateFormat || 'yyyy-mm-dd';\n this.showTime = config.showTime || false;\n this.showSeconds = config.showSeconds || false;\n this.hourFormat = config.hourFormat || '24';\n this.minDate = config.minDate;\n this.maxDate = config.maxDate;\n this.disabledDates = config.disabledDates || [];\n this.disabledDays = config.disabledDays || [];\n this.yearRange = config.yearRange || '1900:2030';\n this.showIcon = config.showIcon || true;\n this.icon = config.icon || 'pi pi-calendar';\n this.showButtonBar = config.showButtonBar || false;\n this.showClear = config.showClear || true;\n this.inline = config.inline || false;\n }\n}\n\nexport class NumberFieldConfig extends BaseFieldConfig {\n min?: number;\n max?: number;\n step?: number;\n prefix?: string;\n suffix?: string;\n currency?: string;\n locale?: string;\n minFractionDigits?: number;\n maxFractionDigits?: number;\n useGrouping?: boolean;\n showButtons?: boolean;\n buttonLayout?: 'stacked' | 'horizontal';\n incrementButtonClass?: string;\n decrementButtonClass?: string;\n incrementButtonIcon?: string;\n decrementButtonIcon?: string;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n min?: number;\n max?: number;\n step?: number;\n prefix?: string;\n suffix?: string;\n currency?: string;\n locale?: string;\n minFractionDigits?: number;\n maxFractionDigits?: number;\n useGrouping?: boolean;\n showButtons?: boolean;\n buttonLayout?: 'stacked' | 'horizontal';\n incrementButtonClass?: string;\n decrementButtonClass?: string;\n incrementButtonIcon?: string;\n decrementButtonIcon?: string;\n },\n ) {\n super({ ...config, type: 'number' });\n this.min = config.min;\n this.max = config.max;\n this.step = config.step || 1;\n this.prefix = config.prefix;\n this.suffix = config.suffix;\n this.currency = config.currency;\n this.locale = config.locale;\n this.minFractionDigits = config.minFractionDigits;\n this.maxFractionDigits = config.maxFractionDigits;\n this.useGrouping = config.useGrouping || false;\n this.showButtons = config.showButtons || false;\n this.buttonLayout = config.buttonLayout || 'stacked';\n this.incrementButtonClass = config.incrementButtonClass;\n this.decrementButtonClass = config.decrementButtonClass;\n this.incrementButtonIcon = config.incrementButtonIcon;\n this.decrementButtonIcon = config.decrementButtonIcon;\n }\n}\n\nexport class SliderFieldConfig extends BaseFieldConfig {\n min?: number;\n max?: number;\n step?: number;\n orientation?: 'horizontal' | 'vertical';\n range?: boolean;\n animate?: boolean;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n min?: number;\n max?: number;\n step?: number;\n orientation?: 'horizontal' | 'vertical';\n range?: boolean;\n animate?: boolean;\n },\n ) {\n super({ ...config, type: 'slider' });\n this.min = config.min || 0;\n this.max = config.max || 100;\n this.step = config.step || 1;\n this.orientation = config.orientation || 'horizontal';\n this.range = config.range || false;\n this.animate = config.animate || false;\n }\n}\n\nexport class MultiSelectFieldConfig extends BaseFieldConfig {\n options: any[];\n optionLabel: string;\n optionValue: string;\n filter: boolean;\n filterBy: string;\n filterPlaceholder: string;\n showClear: boolean;\n emptyMessage: string;\n display?: 'comma' | 'chip';\n maxSelectedLabels?: number;\n selectedItemsLabel?: string;\n showToggleAll?: boolean;\n resetFilterOnHide?: boolean;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n options: any[];\n optionLabel?: string;\n optionValue?: string;\n filter?: boolean;\n filterBy?: string;\n filterPlaceholder?: string;\n showClear?: boolean;\n emptyMessage?: string;\n display?: 'comma' | 'chip';\n maxSelectedLabels?: number;\n selectedItemsLabel?: string;\n showToggleAll?: boolean;\n resetFilterOnHide?: boolean;\n },\n ) {\n super({ ...config, type: 'multi-select' });\n this.options = config.options;\n this.optionLabel = config.optionLabel || 'label';\n this.optionValue = config.optionValue || 'value';\n this.filter = config.filter || false;\n this.filterBy = config.filterBy || '';\n this.filterPlaceholder = config.filterPlaceholder || 'Search...';\n this.showClear = config.showClear || false;\n this.emptyMessage = config.emptyMessage || 'No options available';\n this.display = config.display || 'comma';\n this.maxSelectedLabels = config.maxSelectedLabels || 3;\n this.selectedItemsLabel = config.selectedItemsLabel || '{0} items selected';\n this.showToggleAll = config.showToggleAll || true;\n this.resetFilterOnHide = config.resetFilterOnHide || false;\n }\n}\n\nexport class CheckboxFieldConfig extends BaseFieldConfig {\n binary?: boolean;\n trueValue?: any;\n falseValue?: any;\n checkboxIcon?: string;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n binary?: boolean;\n trueValue?: any;\n falseValue?: any;\n checkboxIcon?: string;\n },\n ) {\n super({ ...config, type: 'checkbox' });\n this.binary = config.binary !== false; // Default to true\n this.trueValue = config.trueValue !== undefined ? config.trueValue : true;\n this.falseValue =\n config.falseValue !== undefined ? config.falseValue : false;\n this.checkboxIcon = config.checkboxIcon;\n }\n}\n\nexport class ColorPickerFieldConfig extends BaseFieldConfig {\n format?: 'hex' | 'rgb' | 'hsb';\n inline?: boolean;\n appendTo?: any;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n format?: 'hex' | 'rgb' | 'hsb';\n inline?: boolean;\n appendTo?: any;\n },\n ) {\n super({ ...config, type: 'color-picker' });\n this.format = config.format || 'hex';\n this.inline = config.inline || false;\n this.appendTo = config.appendTo || 'body';\n }\n}\n\nexport class IconFieldConfig extends BaseFieldConfig {\n constructor(config: Omit<BaseFieldConstructorConfig, 'type'> & {}) {\n super({ ...config, type: 'icon-field' });\n }\n}\n\n// Union type for all field configurations\nexport type DynamicFieldConfig = {\n [K in keyof (TextFieldConfig &\n TextareaFieldConfig &\n SelectFieldConfig &\n DateFieldConfig &\n NumberFieldConfig &\n SliderFieldConfig &\n MultiSelectFieldConfig &\n CheckboxFieldConfig &\n ColorPickerFieldConfig &\n IconFieldConfig &\n BaseFieldConfig)]?: (TextFieldConfig &\n TextareaFieldConfig &\n SelectFieldConfig &\n DateFieldConfig &\n NumberFieldConfig &\n SliderFieldConfig &\n MultiSelectFieldConfig &\n CheckboxFieldConfig &\n ColorPickerFieldConfig &\n IconFieldConfig &\n BaseFieldConfig)[K];\n};\n\n// Layout configuration\nexport interface LayoutConfig {\n containerClass?: string;\n sectionClass?: string;\n fieldClass?: string;\n}\n\n// Simplified form configuration interface\nexport interface DynamicFormConfig {\n sections: SectionConfig[];\n layout?: LayoutConfig;\n}\nexport interface SectionConfig {\n key?: string;\n label?: string;\n type: 'none' | 'header';\n cssClass?: string;\n bodyClass?: string;\n headerClass?: string;\n\n order?: number;\n fields: DynamicFieldConfig[];\n}\n\nexport function createCustomValidator(\n customValidator: (value: any) => boolean | Promise<boolean>,\n message?: string,\n): ValidatorFn {\n return (control: AbstractControl): ValidationErrors | null => {\n const result = customValidator(control.value);\n\n if (result instanceof Promise) {\n // Handle async validation\n result.then((isValid) => {\n if (!isValid) {\n control.setErrors({\n custom: { message: message || 'Invalid value' },\n });\n }\n });\n return null; // For async, return null initially\n } else {\n // Handle sync validation\n return result\n ? null\n : { custom: { message: message || 'Invalid value' } };\n }\n };\n}\n\nexport function wrapValidatorWithMessage(\n validator: ValidatorFn,\n errorKey: string,\n message: string,\n): ValidatorFn {\n return (control: AbstractControl): ValidationErrors | null => {\n const result = validator(control);\n if (result) {\n // Replace the default error with custom message\n return { [errorKey]: { ...result[Object.keys(result)[0]], message } };\n }\n return null;\n };\n}\n// DynamicFieldConfig = input.required<any>({\n// transform: (value: any) => this.transformToDateFieldConfig(value)\n// });\n// transformToDateFieldConfig(value: any){\n// return new TextFieldConfig()\n// }\n","/*\n * Public API Surface of components\n */\n\nexport * from './lib/config/providemt';\nexport * from './lib/config/povide-messages';\nexport * from './lib/utils/theme';\nexport * from './lib/utils/inputs';\nexport * from './lib/config/dynamic-form.model';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAKA;;;;;AAKG;AACH,SAAS,QAAQ,CAAC,GAAW,EAAA;IAC3B,IAAI,CAAC,GAAW,CAAC,EACf,CAAC,GAAW,CAAC,EACb,CAAC,GAAW,CAAC;;AAGf,IAAA,IAAI,GAAG,CAAC,MAAM,KAAK,CAAC,EAAE;AACpB,QAAA,CAAC,GAAG,QA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","../../../../packages/masterteam/components/src/lib/config/providemt.ts","../../../../packages/masterteam/components/src/lib/config/povide-messages.ts","../../../../packages/masterteam/components/src/lib/utils/inputs.ts","../../../../packages/masterteam/components/src/lib/config/dynamic-form.model.ts","../../../../packages/masterteam/components/src/public-api.ts","../../../../packages/masterteam/components/src/masterteam-components.ts"],"sourcesContent":["type HSLTuple = [number, number, number]; // [hue, saturation, lightness]\ntype TailwindColorPalette = {\n [key: string]: string; // e.g., '50': '#f0f9ff', '500': '#0284c7'\n};\n\n/**\n * Converts a hex color string to an HSL tuple.\n * @param hex - The hex color string (e.g., \"#RRGGBB\" or \"#RGB\").\n * @returns An HSL tuple [hue, saturation, lightness] where hue is in degrees (0-360),\n * and saturation/lightness are percentages (0-100).\n */\nfunction hexToHsl(hex: string): HSLTuple {\n let r: number = 0,\n g: number = 0,\n b: number = 0;\n\n // Handle shorthand hex codes\n if (hex.length === 4) {\n r = parseInt(hex[1] + hex[1], 16);\n g = parseInt(hex[2] + hex[2], 16);\n b = parseInt(hex[3] + hex[3], 16);\n } else if (hex.length === 7) {\n r = parseInt(hex.substring(1, 3), 16);\n g = parseInt(hex.substring(3, 5), 16);\n b = parseInt(hex.substring(5, 7), 16);\n } else {\n throw new Error('Invalid hex color format. Expected #RGB or #RRGGBB.');\n }\n\n r /= 255;\n g /= 255;\n b /= 255;\n\n const max: number = Math.max(r, g, b);\n const min: number = Math.min(r, g, b);\n let h: number = 0,\n s: number;\n const l: number = (max + min) / 2;\n\n if (max === min) {\n h = s = 0; // achromatic\n } else {\n const d: number = max - min;\n s = l > 0.5 ? d / (2 - max - min) : d / (max + min);\n switch (max) {\n case r:\n h = (g - b) / d + (g < b ? 6 : 0);\n break;\n case g:\n h = (b - r) / d + 2;\n break;\n case b:\n h = (r - g) / d + 4;\n break;\n }\n h /= 6;\n }\n\n return [h * 360, s * 100, l * 100]; // HSL in degrees, percentage, percentage\n}\n\n/**\n * Converts HSL values to a hex color string.\n * @param h - Hue (0-360).\n * @param s - Saturation (0-100).\n * @param l - Lightness (0-100).\n * @returns The hex color string (e.g., \"#RRGGBB\").\n */\nfunction hslToHex(h: number, s: number, l: number): string {\n l /= 100;\n const a: number = (s * Math.min(l, 1 - l)) / 100;\n const f = (n: number): string => {\n const k: number = (n + h / 30) % 12;\n const color: number = l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);\n return Math.round(255 * color)\n .toString(16)\n .padStart(2, '0');\n };\n return `#${f(0)}${f(8)}${f(4)}`;\n}\n\n/**\n * Generates a Tailwind-like color palette (50-950) from a primary color (assumed to be 500).\n *\n * @param primaryColor500 - The hex string of the primary color (e.g., \"#0284c7\").\n * @returns An object representing the color palette, where keys are color numbers (e.g., \"50\", \"100\")\n * and values are hex color strings.\n */\nexport function generateTailwindPalette(\n primaryColor500: string,\n): TailwindColorPalette {\n const [h, s, _l]: HSLTuple = hexToHsl(primaryColor500);\n\n const palette: TailwindColorPalette = {\n '500': primaryColor500,\n };\n\n // Define steps for lighter shades (50 - 400)\n const lightnessStepsLighter: { [key: string]: number } = {\n '50': 95,\n '100': 90,\n '200': 80,\n '300': 70,\n '400': 60,\n };\n\n const saturationReductionsLighter: { [key: string]: number } = {\n '50': 40, // More desaturated\n '100': 30,\n '200': 20,\n '300': 10,\n '400': 5, // Slightly desaturated\n };\n\n for (const shade in lightnessStepsLighter) {\n if (Object.prototype.hasOwnProperty.call(lightnessStepsLighter, shade)) {\n const newL: number = lightnessStepsLighter[shade];\n // Ensure saturation doesn't go below 0\n const newS: number = Math.max(0, s - saturationReductionsLighter[shade]);\n palette[shade] = hslToHex(h, newS, newL);\n }\n }\n\n // Define steps for darker shades (600 - 950)\n const lightnessStepsDarker: { [key: string]: number } = {\n '600': 45,\n '700': 35,\n '800': 25,\n '900': 15,\n '950': 8, // More aggressive darkening for 950\n };\n\n const saturationIncreasesDarker: { [key: string]: number } = {\n '600': 5,\n '700': 10,\n '800': 15,\n '900': 20,\n '950': 25, // Can increase saturation for darker shades\n };\n\n for (const shade in lightnessStepsDarker) {\n if (Object.prototype.hasOwnProperty.call(lightnessStepsDarker, shade)) {\n const newL: number = lightnessStepsDarker[shade];\n // Ensure saturation doesn't exceed 100\n const newS: number = Math.min(100, s + saturationIncreasesDarker[shade]);\n palette[shade] = hslToHex(h, newS, newL);\n }\n }\n\n // Sort the keys numerically to ensure consistent order\n const sortedPalette: TailwindColorPalette = {};\n Object.keys(palette)\n .sort((a, b) => parseInt(a) - parseInt(b))\n .forEach((key: string) => {\n sortedPalette[key] = palette[key];\n });\n\n return sortedPalette;\n}\n","import { providePrimeNG } from 'primeng/config';\nimport { generateTailwindPalette } from '../utils/theme';\nimport Aura from '@primeuix/themes/aura';\nimport { definePreset, updatePreset } from '@primeuix/themes';\nimport { ToastTokenSections } from '@primeuix/themes/types/toast';\nimport { EnvironmentProviders } from '@angular/core';\n\nconst toastStyle: ToastTokenSections.Success = {\n // borderColor: '{surface.300}',\n background: '{content.background}',\n // color: '{surface.600}',\n // closeButton: {\n // hoverBackground: '{surface.100}',\n // focusRing: {\n // color: '{surface.600}',\n // },\n // },\n};\n\nexport function changePrimaryColor(color: string): void {\n updatePreset({\n semantic: {\n primary: generateTailwindPalette(color || '#334dff'),\n },\n });\n}\n\nconst MTPreset = (primaryColor?: string) =>\n definePreset(Aura, {\n options: {\n prefix: 'mt',\n cssLayer: {\n name: 'primeng',\n order: 'theme, base, primeng',\n },\n },\n semantic: {\n primary: generateTailwindPalette(primaryColor || '#334dff'),\n content: {\n borderRadius: '{border.radius.lg}',\n },\n formField: {\n borderRadius: '{border.radius.lg}',\n },\n },\n components: {\n toast: {\n root: {\n borderRadius: '{border.radius.xl}',\n },\n colorScheme: {\n light: {\n success: toastStyle,\n info: toastStyle,\n warn: toastStyle,\n error: toastStyle,\n secondary: toastStyle,\n },\n dark: {\n success: toastStyle,\n info: toastStyle,\n warn: toastStyle,\n error: toastStyle,\n secondary: toastStyle,\n },\n },\n },\n togglebutton: {\n root: {\n padding: '1px',\n sm: {\n padding: '1px',\n },\n lg: {\n padding: '1px',\n },\n },\n colorScheme: {\n light: {\n root: {\n checkedColor: '{primary.500}',\n },\n },\n dark: {\n root: {\n checkedColor: '{primary.400}',\n },\n },\n },\n },\n selectbutton: {\n root: {\n borderRadius: '{border.radius.lg}',\n },\n },\n\n breadcrumb: {\n root: {\n padding: '0.5rem 1rem',\n },\n item: {\n color: '{surface.700}',\n hoverColor: '{primary.600}',\n focusRing: {\n color: '{primary.700}',\n },\n borderRadius: '0',\n },\n separator: {\n color: '{surface.500}',\n },\n css: () => `\n .p-breadcrumb-list .p-breadcrumb-item-link {\n font-size: 0.9rem;\n }\n\n .p-breadcrumb-list .p-breadcrumb-separator {\n width: 12px\n }\n\n .p-breadcrumb-list .p-breadcrumb-item:last-child .p-breadcrumb-item-link {\n color: var(--p-primary-400);\n background: var(--p-primary-50);\n cursor: default;\n pointer-events: none;\n padding: 0 0.4rem\n }\n `,\n },\n\n paginator: {\n root: {\n borderRadius: '{border.radius.lg}',\n padding: '0 .5rem',\n },\n navButton: {\n borderRadius: '0',\n },\n\n colorScheme: {\n light: {\n navButton: {\n color: '{surface.600}',\n hoverBackground: '#fff',\n selectedBackground: '{surface.200}',\n selectedColor: '{surface.600}',\n focusRing: {\n color: '{surface.200}',\n },\n },\n },\n dark: {\n navButton: {\n color: '{surface.200}',\n hoverBackground: 'transparent',\n selectedBackground: 'transparent',\n selectedColor: '#fff',\n focusRing: {\n color: '#fff',\n },\n },\n },\n },\n\n css: () => `\n .p-paginator {\n --p-paginator-gap: 0;\n --p-paginator-nav-button-width: 2.2rem;\n --p-paginator-nav-button-height: 2.2rem;\n width: fit-content;\n border: 1px solid var(--p-surface-200);\n overflow: hidden;\n font-size: .95rem;\n }\n\n .p-paginator-pages button,\n .p-paginator-prev,\n .p-paginator-next {\n border-color: var(--p-surface-200);\n }\n\n .p-paginator-pages button {\n border-style: solid;\n border-width: 0 0 0 1px;\n }\n\n .p-paginator-pages button:first-child {\n border-left: none;\n }\n\n .p-paginator-prev {\n border-right: 1px solid var(--p-surface-200);\n }\n\n .p-paginator-next {\n border-left: 1px solid var(--p-surface-200);\n }\n\n .p-paginator .p-select {\n border: 0;\n background: transparent;\n }\n\n .p-paginator .p-select .p-select-label {\n padding: 0;\n }\n\n /* Dark Mode Styles */\n .dark .p-paginator {\n border-color: var(--p-surface-500);\n }\n\n .dark .p-paginator-pages button,\n .dark .p-paginator-prev,\n .dark .p-paginator-next {\n border-color: var(--p-surface-500);\n }\n\n .dark .p-paginator-prev {\n border-right-color: var(--p-surface-500);\n }\n\n .dark .p-paginator-next {\n border-left-color: var(--p-surface-500);\n }\n `,\n },\n // steps: {\n // item: {\n // link: {\n // gap: 'calc(50% + 0.25rem)',\n // },\n // number: {\n // font: {\n // size: '0.9rem',\n // },\n // active: {\n // color: 'white',\n // background: '{primary.500}',\n // border: {\n // color: '{primary.500}',\n // },\n // },\n // },\n // },\n // },\n },\n });\n\nexport function provideMTComponents(\n primaryColor?: string,\n): EnvironmentProviders {\n return providePrimeNG({\n zIndex: {\n modal: 1900,\n overlay: 1500,\n menu: 1500,\n tooltip: 1600,\n },\n theme: {\n preset: MTPreset(primaryColor),\n options: {\n darkModeSelector: '.dark',\n },\n },\n });\n}\n","import { MessageService } from 'primeng/api';\n\nexport function provideMTMessages() {\n return MessageService;\n}\n","import { AbstractControl } from '@angular/forms';\n\nexport function isInvalid(control: AbstractControl | null) {\n if (!control) return false;\n return control && control?.invalid && control?.touched;\n}\n","import { AbstractControl, ValidationErrors, ValidatorFn } from '@angular/forms';\n\nexport type FieldType =\n | 'text'\n | 'textarea'\n | 'select'\n | 'date'\n | 'number'\n | 'slider'\n | 'multi-select'\n | 'checkbox'\n | 'icon-field'\n | 'color-picker'\n | string;\n\nexport type ValidatorType =\n | 'required'\n | 'email'\n | 'minLength'\n | 'maxLength'\n | 'min'\n | 'max'\n | 'pattern'\n | 'custom';\n\nexport class ValidatorConfig {\n type: ValidatorType;\n value?: any;\n message?: string;\n customValidator?: (value: any) => boolean | Promise<boolean>;\n\n constructor(config: {\n type: ValidatorType;\n value?: any;\n message?: string;\n customValidator?: (value: any) => boolean | Promise<boolean>;\n }) {\n this.type = config.type;\n this.value = config.value;\n this.message = config.message;\n this.customValidator = config.customValidator;\n }\n\n // Factory methods for common validators\n static required(message = 'This field is required'): ValidatorConfig {\n return new ValidatorConfig({ type: 'required', message });\n }\n\n static email(message = 'Please enter a valid email'): ValidatorConfig {\n return new ValidatorConfig({ type: 'email', message });\n }\n\n static minLength(length: number, message?: string): ValidatorConfig {\n return new ValidatorConfig({\n type: 'minLength',\n value: length,\n message: message || `Minimum length is ${length} characters`,\n });\n }\n\n static maxLength(length: number, message?: string): ValidatorConfig {\n return new ValidatorConfig({\n type: 'maxLength',\n value: length,\n message: message || `Maximum length is ${length} characters`,\n });\n }\n\n static min(value: number, message?: string): ValidatorConfig {\n return new ValidatorConfig({\n type: 'min',\n value,\n message: message || `Minimum value is ${value}`,\n });\n }\n\n static max(value: number, message?: string): ValidatorConfig {\n return new ValidatorConfig({\n type: 'max',\n value,\n message: message || `Maximum value is ${value}`,\n });\n }\n\n static pattern(pattern: string, message = 'Invalid format'): ValidatorConfig {\n return new ValidatorConfig({ type: 'pattern', value: pattern, message });\n }\n\n static custom(\n validator: (value: any) => boolean | Promise<boolean>,\n message = 'Invalid value',\n ): ValidatorConfig {\n return new ValidatorConfig({\n type: 'custom',\n customValidator: validator,\n message,\n });\n }\n}\n\nexport type BaseFieldConstructorConfig = ConstructorParameters<\n typeof BaseFieldConfig\n>[0];\n\nexport abstract class BaseFieldConfig {\n key: string;\n label: string;\n type: FieldType;\n required: boolean;\n disabled: boolean;\n readonly: boolean;\n hidden: boolean;\n placeholder: string;\n hint: string;\n cssClass: string;\n validators: ValidatorConfig[];\n order: number;\n\n defaultValue?: any;\n\n customTemplate: string;\n\n constructor(config: {\n key?: string;\n label?: string;\n type: FieldType;\n required?: boolean;\n disabled?: boolean;\n readonly?: boolean;\n hidden?: boolean;\n placeholder?: string;\n hint?: string;\n cssClass?: string;\n validators?: ValidatorConfig[];\n order?: number;\n defaultValue?: any;\n }) {\n this.key = config.key || 'Key';\n this.label = config.label || '';\n this.type = config.type;\n this.required = config.required || false;\n this.disabled = config.disabled || false;\n this.readonly = config.readonly || false;\n this.hidden = config.hidden || false;\n this.placeholder = config.placeholder || '';\n this.hint = config.hint || '';\n this.cssClass = config.cssClass || '';\n this.validators = config.validators || [];\n this.order = config.order || 0;\n this.defaultValue = config.defaultValue;\n }\n}\n\n// Specific configurations for different field types\nexport class TextFieldConfig extends BaseFieldConfig {\n inputType: 'text' | 'email';\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n inputType?: 'text' | 'email';\n },\n ) {\n super({ ...config, type: 'text' });\n this.inputType = config.inputType || 'text';\n }\n}\n\nexport class TextareaFieldConfig extends BaseFieldConfig {\n rows: number;\n autoResize: boolean;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n rows?: number;\n autoResize?: boolean;\n },\n ) {\n super({ ...config, type: 'textarea' });\n this.rows = config.rows || 3;\n this.autoResize = config.autoResize || false;\n }\n}\n\nexport class SelectFieldConfig extends BaseFieldConfig {\n options: any[];\n optionLabel: string;\n optionValue: string;\n multiple: boolean;\n filter: boolean;\n filterBy: string;\n filterPlaceholder: string;\n showClear: boolean;\n emptyMessage: string;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n options: any[];\n optionLabel?: string;\n optionValue?: string;\n multiple?: boolean;\n filter?: boolean;\n filterBy?: string;\n filterPlaceholder?: string;\n showClear?: boolean;\n emptyMessage?: string;\n },\n ) {\n super({ ...config, type: 'select' });\n this.options = config.options;\n this.optionLabel = config.optionLabel || 'label';\n this.optionValue = config.optionValue || 'value';\n this.multiple = config.multiple || false;\n this.filter = config.filter || false;\n this.filterBy = config.filterBy || '';\n this.filterPlaceholder = config.filterPlaceholder || 'Search...';\n this.showClear = config.showClear || false;\n this.emptyMessage = config.emptyMessage || 'No options available';\n }\n}\n\nexport class DateFieldConfig extends BaseFieldConfig {\n dateFormat: string;\n showTime: boolean;\n showSeconds: boolean;\n hourFormat: '12' | '24';\n minDate?: Date;\n maxDate?: Date;\n disabledDates: Date[];\n disabledDays: number[];\n yearRange: string;\n showIcon: boolean;\n icon: string;\n showButtonBar: boolean;\n showClear: boolean;\n inline: boolean;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n dateFormat?: string;\n showTime?: boolean;\n showSeconds?: boolean;\n hourFormat?: '12' | '24';\n minDate?: Date;\n maxDate?: Date;\n disabledDates?: Date[];\n disabledDays?: number[];\n yearRange?: string;\n showIcon?: boolean;\n icon?: string;\n showButtonBar?: boolean;\n showClear?: boolean;\n inline?: boolean;\n },\n ) {\n super({ ...config, type: 'date' });\n this.dateFormat = config.dateFormat || 'yyyy-mm-dd';\n this.showTime = config.showTime || false;\n this.showSeconds = config.showSeconds || false;\n this.hourFormat = config.hourFormat || '24';\n this.minDate = config.minDate;\n this.maxDate = config.maxDate;\n this.disabledDates = config.disabledDates || [];\n this.disabledDays = config.disabledDays || [];\n this.yearRange = config.yearRange || '1900:2030';\n this.showIcon = config.showIcon || true;\n this.icon = config.icon || 'pi pi-calendar';\n this.showButtonBar = config.showButtonBar || false;\n this.showClear = config.showClear || true;\n this.inline = config.inline || false;\n }\n}\n\nexport class NumberFieldConfig extends BaseFieldConfig {\n min?: number;\n max?: number;\n step?: number;\n prefix?: string;\n suffix?: string;\n currency?: string;\n locale?: string;\n minFractionDigits?: number;\n maxFractionDigits?: number;\n useGrouping?: boolean;\n showButtons?: boolean;\n buttonLayout?: 'stacked' | 'horizontal';\n incrementButtonClass?: string;\n decrementButtonClass?: string;\n incrementButtonIcon?: string;\n decrementButtonIcon?: string;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n min?: number;\n max?: number;\n step?: number;\n prefix?: string;\n suffix?: string;\n currency?: string;\n locale?: string;\n minFractionDigits?: number;\n maxFractionDigits?: number;\n useGrouping?: boolean;\n showButtons?: boolean;\n buttonLayout?: 'stacked' | 'horizontal';\n incrementButtonClass?: string;\n decrementButtonClass?: string;\n incrementButtonIcon?: string;\n decrementButtonIcon?: string;\n },\n ) {\n super({ ...config, type: 'number' });\n this.min = config.min;\n this.max = config.max;\n this.step = config.step || 1;\n this.prefix = config.prefix;\n this.suffix = config.suffix;\n this.currency = config.currency;\n this.locale = config.locale;\n this.minFractionDigits = config.minFractionDigits;\n this.maxFractionDigits = config.maxFractionDigits;\n this.useGrouping = config.useGrouping || false;\n this.showButtons = config.showButtons || false;\n this.buttonLayout = config.buttonLayout || 'stacked';\n this.incrementButtonClass = config.incrementButtonClass;\n this.decrementButtonClass = config.decrementButtonClass;\n this.incrementButtonIcon = config.incrementButtonIcon;\n this.decrementButtonIcon = config.decrementButtonIcon;\n }\n}\n\nexport class SliderFieldConfig extends BaseFieldConfig {\n min?: number;\n max?: number;\n step?: number;\n orientation?: 'horizontal' | 'vertical';\n range?: boolean;\n animate?: boolean;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n min?: number;\n max?: number;\n step?: number;\n orientation?: 'horizontal' | 'vertical';\n range?: boolean;\n animate?: boolean;\n },\n ) {\n super({ ...config, type: 'slider' });\n this.min = config.min || 0;\n this.max = config.max || 100;\n this.step = config.step || 1;\n this.orientation = config.orientation || 'horizontal';\n this.range = config.range || false;\n this.animate = config.animate || false;\n }\n}\n\nexport class MultiSelectFieldConfig extends BaseFieldConfig {\n options: any[];\n optionLabel: string;\n optionValue: string;\n filter: boolean;\n filterBy: string;\n filterPlaceholder: string;\n showClear: boolean;\n emptyMessage: string;\n display?: 'comma' | 'chip';\n maxSelectedLabels?: number;\n selectedItemsLabel?: string;\n showToggleAll?: boolean;\n resetFilterOnHide?: boolean;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n options: any[];\n optionLabel?: string;\n optionValue?: string;\n filter?: boolean;\n filterBy?: string;\n filterPlaceholder?: string;\n showClear?: boolean;\n emptyMessage?: string;\n display?: 'comma' | 'chip';\n maxSelectedLabels?: number;\n selectedItemsLabel?: string;\n showToggleAll?: boolean;\n resetFilterOnHide?: boolean;\n },\n ) {\n super({ ...config, type: 'multi-select' });\n this.options = config.options;\n this.optionLabel = config.optionLabel || 'label';\n this.optionValue = config.optionValue || 'value';\n this.filter = config.filter || false;\n this.filterBy = config.filterBy || '';\n this.filterPlaceholder = config.filterPlaceholder || 'Search...';\n this.showClear = config.showClear || false;\n this.emptyMessage = config.emptyMessage || 'No options available';\n this.display = config.display || 'comma';\n this.maxSelectedLabels = config.maxSelectedLabels || 3;\n this.selectedItemsLabel = config.selectedItemsLabel || '{0} items selected';\n this.showToggleAll = config.showToggleAll || true;\n this.resetFilterOnHide = config.resetFilterOnHide || false;\n }\n}\n\nexport class CheckboxFieldConfig extends BaseFieldConfig {\n binary?: boolean;\n trueValue?: any;\n falseValue?: any;\n checkboxIcon?: string;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n binary?: boolean;\n trueValue?: any;\n falseValue?: any;\n checkboxIcon?: string;\n },\n ) {\n super({ ...config, type: 'checkbox' });\n this.binary = config.binary !== false; // Default to true\n this.trueValue = config.trueValue !== undefined ? config.trueValue : true;\n this.falseValue =\n config.falseValue !== undefined ? config.falseValue : false;\n this.checkboxIcon = config.checkboxIcon;\n }\n}\n\nexport class ColorPickerFieldConfig extends BaseFieldConfig {\n format?: 'hex' | 'rgb' | 'hsb';\n inline?: boolean;\n appendTo?: any;\n\n constructor(\n config: Omit<BaseFieldConstructorConfig, 'type'> & {\n format?: 'hex' | 'rgb' | 'hsb';\n inline?: boolean;\n appendTo?: any;\n },\n ) {\n super({ ...config, type: 'color-picker' });\n this.format = config.format || 'hex';\n this.inline = config.inline || false;\n this.appendTo = config.appendTo || 'body';\n }\n}\n\nexport class IconFieldConfig extends BaseFieldConfig {\n constructor(config: Omit<BaseFieldConstructorConfig, 'type'> & {}) {\n super({ ...config, type: 'icon-field' });\n }\n}\n\n// Union type for all field configurations\nexport type DynamicFieldConfig = {\n [K in keyof (TextFieldConfig &\n TextareaFieldConfig &\n SelectFieldConfig &\n DateFieldConfig &\n NumberFieldConfig &\n SliderFieldConfig &\n MultiSelectFieldConfig &\n CheckboxFieldConfig &\n ColorPickerFieldConfig &\n IconFieldConfig &\n BaseFieldConfig)]?: (TextFieldConfig &\n TextareaFieldConfig &\n SelectFieldConfig &\n DateFieldConfig &\n NumberFieldConfig &\n SliderFieldConfig &\n MultiSelectFieldConfig &\n CheckboxFieldConfig &\n ColorPickerFieldConfig &\n IconFieldConfig &\n BaseFieldConfig)[K];\n};\n\n// Layout configuration\nexport interface LayoutConfig {\n containerClass?: string;\n sectionClass?: string;\n fieldClass?: string;\n}\n\n// Simplified form configuration interface\nexport interface DynamicFormConfig {\n sections: SectionConfig[];\n layout?: LayoutConfig;\n}\nexport interface SectionConfig {\n key?: string;\n label?: string;\n type: 'none' | 'header';\n cssClass?: string;\n bodyClass?: string;\n headerClass?: string;\n\n order?: number;\n fields: DynamicFieldConfig[];\n}\n\nexport function createCustomValidator(\n customValidator: (value: any) => boolean | Promise<boolean>,\n message?: string,\n): ValidatorFn {\n return (control: AbstractControl): ValidationErrors | null => {\n const result = customValidator(control.value);\n\n if (result instanceof Promise) {\n // Handle async validation\n result.then((isValid) => {\n if (!isValid) {\n control.setErrors({\n custom: { message: message || 'Invalid value' },\n });\n }\n });\n return null; // For async, return null initially\n } else {\n // Handle sync validation\n return result\n ? null\n : { custom: { message: message || 'Invalid value' } };\n }\n };\n}\n\nexport function wrapValidatorWithMessage(\n validator: ValidatorFn,\n errorKey: string,\n message: string,\n): ValidatorFn {\n return (control: AbstractControl): ValidationErrors | null => {\n const result = validator(control);\n if (result) {\n // Replace the default error with custom message\n return { [errorKey]: { ...result[Object.keys(result)[0]], message } };\n }\n return null;\n };\n}\n// DynamicFieldConfig = input.required<any>({\n// transform: (value: any) => this.transformToDateFieldConfig(value)\n// });\n// transformToDateFieldConfig(value: any){\n// return new TextFieldConfig()\n// }\n","/*\n * Public API Surface of components\n */\n\nexport * from './lib/config/providemt';\nexport * from './lib/config/povide-messages';\nexport * from './lib/utils/theme';\nexport * from './lib/utils/inputs';\nexport * from './lib/config/dynamic-form.model';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAKA;;;;;AAKG;AACH,SAAS,QAAQ,CAAC,GAAW,EAAA;IAC3B,IAAI,CAAC,GAAW,CAAC,EACf,CAAC,GAAW,CAAC,EACb,CAAC,GAAW,CAAC;;AAGf,IAAA,IAAI,GAAG,CAAC,MAAM,KAAK,CAAC,EAAE;AACpB,QAAA,CAAC,GAAG,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;AACjC,QAAA,CAAC,GAAG,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;AACjC,QAAA,CAAC,GAAG,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;IACnC;AAAO,SAAA,IAAI,GAAG,CAAC,MAAM,KAAK,CAAC,EAAE;AAC3B,QAAA,CAAC,GAAG,QAAQ,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC;AACrC,QAAA,CAAC,GAAG,QAAQ,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC;AACrC,QAAA,CAAC,GAAG,QAAQ,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC;IACvC;SAAO;AACL,QAAA,MAAM,IAAI,KAAK,CAAC,qDAAqD,CAAC;IACxE;IAEA,CAAC,IAAI,GAAG;IACR,CAAC,IAAI,GAAG;IACR,CAAC,IAAI,GAAG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,CACtC,SAAsB,EACtB,QAAgB,EAChB,OAAe,EAAA;IAEf,OAAO,CAAC,OAAwB,KAA6B;AAC3D,QAAA,MAAM,MAAM,GAAG,SAAS,CAAC,OAAO,CAAC;QACjC,IAAI,MAAM,EAAE;;YAEV,OAAO,EAAE,CAAC,QAAQ,GAAG,EAAE,GAAG,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,EAAE;QACvE;AACA,QAAA,OAAO,IAAI;AACb,IAAA,CAAC;AACH;AACA;AACA;AACA;AACA;AACA;AACA;;ACriBA;;AAEG;;ACFH;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@masterteam/components",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.17",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"directory": ".",
|
|
6
6
|
"linkDirectory": false,
|
|
@@ -38,38 +38,42 @@
|
|
|
38
38
|
"types": "./index.d.ts",
|
|
39
39
|
"default": "./fesm2022/masterteam-components.mjs"
|
|
40
40
|
},
|
|
41
|
-
"./button-group": {
|
|
42
|
-
"types": "./button-group/index.d.ts",
|
|
43
|
-
"default": "./fesm2022/masterteam-components-button-group.mjs"
|
|
44
|
-
},
|
|
45
|
-
"./button": {
|
|
46
|
-
"types": "./button/index.d.ts",
|
|
47
|
-
"default": "./fesm2022/masterteam-components-button.mjs"
|
|
48
|
-
},
|
|
49
41
|
"./avatar-text": {
|
|
50
42
|
"types": "./avatar-text/index.d.ts",
|
|
51
43
|
"default": "./fesm2022/masterteam-components-avatar-text.mjs"
|
|
52
44
|
},
|
|
53
|
-
"./
|
|
54
|
-
"types": "./
|
|
55
|
-
"default": "./fesm2022/masterteam-components-
|
|
45
|
+
"./avatar": {
|
|
46
|
+
"types": "./avatar/index.d.ts",
|
|
47
|
+
"default": "./fesm2022/masterteam-components-avatar.mjs"
|
|
48
|
+
},
|
|
49
|
+
"./button-group": {
|
|
50
|
+
"types": "./button-group/index.d.ts",
|
|
51
|
+
"default": "./fesm2022/masterteam-components-button-group.mjs"
|
|
56
52
|
},
|
|
57
53
|
"./card": {
|
|
58
54
|
"types": "./card/index.d.ts",
|
|
59
55
|
"default": "./fesm2022/masterteam-components-card.mjs"
|
|
60
56
|
},
|
|
57
|
+
"./button": {
|
|
58
|
+
"types": "./button/index.d.ts",
|
|
59
|
+
"default": "./fesm2022/masterteam-components-button.mjs"
|
|
60
|
+
},
|
|
61
61
|
"./checkbox-field": {
|
|
62
62
|
"types": "./checkbox-field/index.d.ts",
|
|
63
63
|
"default": "./fesm2022/masterteam-components-checkbox-field.mjs"
|
|
64
64
|
},
|
|
65
|
-
"./
|
|
66
|
-
"types": "./
|
|
67
|
-
"default": "./fesm2022/masterteam-components-
|
|
65
|
+
"./chip": {
|
|
66
|
+
"types": "./chip/index.d.ts",
|
|
67
|
+
"default": "./fesm2022/masterteam-components-chip.mjs"
|
|
68
68
|
},
|
|
69
69
|
"./color-picker-field": {
|
|
70
70
|
"types": "./color-picker-field/index.d.ts",
|
|
71
71
|
"default": "./fesm2022/masterteam-components-color-picker-field.mjs"
|
|
72
72
|
},
|
|
73
|
+
"./breadcrumb": {
|
|
74
|
+
"types": "./breadcrumb/index.d.ts",
|
|
75
|
+
"default": "./fesm2022/masterteam-components-breadcrumb.mjs"
|
|
76
|
+
},
|
|
73
77
|
"./editor-field": {
|
|
74
78
|
"types": "./editor-field/index.d.ts",
|
|
75
79
|
"default": "./fesm2022/masterteam-components-editor-field.mjs"
|
|
@@ -78,38 +82,54 @@
|
|
|
78
82
|
"types": "./date-field/index.d.ts",
|
|
79
83
|
"default": "./fesm2022/masterteam-components-date-field.mjs"
|
|
80
84
|
},
|
|
81
|
-
"./icon-field": {
|
|
82
|
-
"types": "./icon-field/index.d.ts",
|
|
83
|
-
"default": "./fesm2022/masterteam-components-icon-field.mjs"
|
|
84
|
-
},
|
|
85
|
-
"./formula-builder": {
|
|
86
|
-
"types": "./formula-builder/index.d.ts",
|
|
87
|
-
"default": "./fesm2022/masterteam-components-formula-builder.mjs"
|
|
88
|
-
},
|
|
89
85
|
"./field-validation": {
|
|
90
86
|
"types": "./field-validation/index.d.ts",
|
|
91
87
|
"default": "./fesm2022/masterteam-components-field-validation.mjs"
|
|
92
88
|
},
|
|
89
|
+
"./list": {
|
|
90
|
+
"types": "./list/index.d.ts",
|
|
91
|
+
"default": "./fesm2022/masterteam-components-list.mjs"
|
|
92
|
+
},
|
|
93
|
+
"./icon-field": {
|
|
94
|
+
"types": "./icon-field/index.d.ts",
|
|
95
|
+
"default": "./fesm2022/masterteam-components-icon-field.mjs"
|
|
96
|
+
},
|
|
93
97
|
"./multi-select-field": {
|
|
94
98
|
"types": "./multi-select-field/index.d.ts",
|
|
95
99
|
"default": "./fesm2022/masterteam-components-multi-select-field.mjs"
|
|
96
100
|
},
|
|
97
|
-
"./
|
|
98
|
-
"types": "./
|
|
99
|
-
"default": "./fesm2022/masterteam-components-
|
|
101
|
+
"./formula-builder": {
|
|
102
|
+
"types": "./formula-builder/index.d.ts",
|
|
103
|
+
"default": "./fesm2022/masterteam-components-formula-builder.mjs"
|
|
100
104
|
},
|
|
101
105
|
"./number-field": {
|
|
102
106
|
"types": "./number-field/index.d.ts",
|
|
103
107
|
"default": "./fesm2022/masterteam-components-number-field.mjs"
|
|
104
108
|
},
|
|
105
|
-
"./
|
|
106
|
-
"types": "./
|
|
107
|
-
"default": "./fesm2022/masterteam-components-
|
|
109
|
+
"./paginator": {
|
|
110
|
+
"types": "./paginator/index.d.ts",
|
|
111
|
+
"default": "./fesm2022/masterteam-components-paginator.mjs"
|
|
112
|
+
},
|
|
113
|
+
"./radio-button-field": {
|
|
114
|
+
"types": "./radio-button-field/index.d.ts",
|
|
115
|
+
"default": "./fesm2022/masterteam-components-radio-button-field.mjs"
|
|
116
|
+
},
|
|
117
|
+
"./radio-cards": {
|
|
118
|
+
"types": "./radio-cards/index.d.ts",
|
|
119
|
+
"default": "./fesm2022/masterteam-components-radio-cards.mjs"
|
|
108
120
|
},
|
|
109
121
|
"./slider-field": {
|
|
110
122
|
"types": "./slider-field/index.d.ts",
|
|
111
123
|
"default": "./fesm2022/masterteam-components-slider-field.mjs"
|
|
112
124
|
},
|
|
125
|
+
"./radio-cards-field": {
|
|
126
|
+
"types": "./radio-cards-field/index.d.ts",
|
|
127
|
+
"default": "./fesm2022/masterteam-components-radio-cards-field.mjs"
|
|
128
|
+
},
|
|
129
|
+
"./select-field": {
|
|
130
|
+
"types": "./select-field/index.d.ts",
|
|
131
|
+
"default": "./fesm2022/masterteam-components-select-field.mjs"
|
|
132
|
+
},
|
|
113
133
|
"./text-field": {
|
|
114
134
|
"types": "./text-field/index.d.ts",
|
|
115
135
|
"default": "./fesm2022/masterteam-components-text-field.mjs"
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as _angular_core from '@angular/core';
|
|
2
|
+
|
|
3
|
+
declare class Paginator {
|
|
4
|
+
readonly rows: _angular_core.ModelSignal<number>;
|
|
5
|
+
readonly totalRecords: _angular_core.InputSignal<number>;
|
|
6
|
+
readonly first: _angular_core.ModelSignal<number>;
|
|
7
|
+
readonly page: _angular_core.ModelSignal<number>;
|
|
8
|
+
readonly rowsPerPageOptions: _angular_core.InputSignal<number[] | undefined>;
|
|
9
|
+
readonly showFirstLastIcon: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
10
|
+
readonly showCurrentPageReport: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
11
|
+
readonly fluid: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
12
|
+
readonly pageLinkSize: _angular_core.InputSignal<number | undefined>;
|
|
13
|
+
readonly alwaysShow: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
14
|
+
readonly onPageChange: _angular_core.OutputEmitterRef<any>;
|
|
15
|
+
onPaginatorChange(event: any): void;
|
|
16
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<Paginator, never>;
|
|
17
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<Paginator, "mt-paginator", never, { "rows": { "alias": "rows"; "required": false; "isSignal": true; }; "totalRecords": { "alias": "totalRecords"; "required": false; "isSignal": true; }; "first": { "alias": "first"; "required": false; "isSignal": true; }; "page": { "alias": "page"; "required": false; "isSignal": true; }; "rowsPerPageOptions": { "alias": "rowsPerPageOptions"; "required": false; "isSignal": true; }; "showFirstLastIcon": { "alias": "showFirstLastIcon"; "required": false; "isSignal": true; }; "showCurrentPageReport": { "alias": "showCurrentPageReport"; "required": false; "isSignal": true; }; "fluid": { "alias": "fluid"; "required": false; "isSignal": true; }; "pageLinkSize": { "alias": "pageLinkSize"; "required": false; "isSignal": true; }; "alwaysShow": { "alias": "alwaysShow"; "required": false; "isSignal": true; }; }, { "rows": "rowsChange"; "first": "firstChange"; "page": "pageChange"; "onPageChange": "onPageChange"; }, never, never, true, never>;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export { Paginator };
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import * as _angular_core from '@angular/core';
|
|
2
|
+
import { ControlValueAccessor, NgControl, Validators } from '@angular/forms';
|
|
3
|
+
import { RadioButton } from 'primeng/radiobutton';
|
|
4
|
+
import { isInvalid } from '@masterteam/components';
|
|
5
|
+
|
|
6
|
+
interface radioOptions {
|
|
7
|
+
label: string;
|
|
8
|
+
value: string;
|
|
9
|
+
}
|
|
10
|
+
declare class RadioButtonField implements ControlValueAccessor {
|
|
11
|
+
radioButton: RadioButton;
|
|
12
|
+
labelPosition: _angular_core.InputSignal<"top" | "start" | "end" | "bottom">;
|
|
13
|
+
readonly: _angular_core.InputSignal<boolean>;
|
|
14
|
+
pInputs: _angular_core.InputSignal<Partial<RadioButton> | undefined>;
|
|
15
|
+
required: _angular_core.InputSignal<boolean>;
|
|
16
|
+
options: _angular_core.InputSignal<radioOptions[]>;
|
|
17
|
+
size: _angular_core.InputSignal<"small" | "large" | undefined>;
|
|
18
|
+
label: _angular_core.InputSignal<string | undefined>;
|
|
19
|
+
onChange: _angular_core.OutputEmitterRef<string>;
|
|
20
|
+
ngControl: NgControl;
|
|
21
|
+
isInvalid: typeof isInvalid;
|
|
22
|
+
isVertical: _angular_core.Signal<boolean>;
|
|
23
|
+
requiredValidator: typeof Validators.required;
|
|
24
|
+
value: _angular_core.WritableSignal<string | null>;
|
|
25
|
+
disabled: _angular_core.WritableSignal<boolean>;
|
|
26
|
+
onTouched: () => void;
|
|
27
|
+
onModelChange: (value: string | null) => void;
|
|
28
|
+
constructor();
|
|
29
|
+
applyInputsToRadioButton(): void;
|
|
30
|
+
onValueChange(value: string | null): void;
|
|
31
|
+
writeValue(value: string | null): void;
|
|
32
|
+
registerOnChange(fn: any): void;
|
|
33
|
+
registerOnTouched(fn: any): void;
|
|
34
|
+
setDisabledState(disabled: boolean): void;
|
|
35
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<RadioButtonField, never>;
|
|
36
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<RadioButtonField, "mt-radio-button-field", never, { "labelPosition": { "alias": "labelPosition"; "required": false; "isSignal": true; }; "readonly": { "alias": "readonly"; "required": false; "isSignal": true; }; "pInputs": { "alias": "pInputs"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "options": { "alias": "options"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; }, { "onChange": "onChange"; }, never, never, true, never>;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export { RadioButtonField };
|
|
40
|
+
export type { radioOptions };
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import * as _angular_core from '@angular/core';
|
|
2
|
+
import { TemplateRef } from '@angular/core';
|
|
3
|
+
import { MTIcon } from '@masterteam/icons';
|
|
4
|
+
|
|
5
|
+
interface RadioItem {
|
|
6
|
+
id: string | number;
|
|
7
|
+
name?: string;
|
|
8
|
+
active?: boolean;
|
|
9
|
+
icon?: MTIcon;
|
|
10
|
+
[key: string]: any;
|
|
11
|
+
}
|
|
12
|
+
declare class RadioCards {
|
|
13
|
+
circle: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
14
|
+
color: _angular_core.InputSignalWithTransform<string, string>;
|
|
15
|
+
size: _angular_core.InputSignalWithTransform<"medium" | "xs" | "base" | "2xl", "medium" | "small" | "large">;
|
|
16
|
+
avatarSize: _angular_core.Signal<"large" | "normal" | "xlarge">;
|
|
17
|
+
options: _angular_core.ModelSignal<RadioItem[]>;
|
|
18
|
+
activeId: _angular_core.ModelSignal<string | number | undefined>;
|
|
19
|
+
selectionChange: _angular_core.OutputEmitterRef<RadioItem>;
|
|
20
|
+
itemTemplate: _angular_core.InputSignal<TemplateRef<any> | null>;
|
|
21
|
+
itemTemplateContent: _angular_core.Signal<TemplateRef<any> | undefined>;
|
|
22
|
+
/**
|
|
23
|
+
* A computed signal that generates the dynamic Tailwind CSS classes
|
|
24
|
+
* for the active state based on the color input.
|
|
25
|
+
*/
|
|
26
|
+
protected activeColorClasses: _angular_core.Signal<{
|
|
27
|
+
[x: string]: boolean;
|
|
28
|
+
}>;
|
|
29
|
+
constructor();
|
|
30
|
+
selectItem(item: RadioItem): void;
|
|
31
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<RadioCards, never>;
|
|
32
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<RadioCards, "mt-radio-cards", never, { "circle": { "alias": "circle"; "required": false; "isSignal": true; }; "color": { "alias": "color"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "options": { "alias": "options"; "required": true; "isSignal": true; }; "activeId": { "alias": "activeId"; "required": false; "isSignal": true; }; "itemTemplate": { "alias": "itemTemplate"; "required": false; "isSignal": true; }; }, { "options": "optionsChange"; "activeId": "activeIdChange"; "selectionChange": "selectionChange"; }, ["itemTemplateContent"], never, true, never>;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export { RadioCards };
|
|
36
|
+
export type { RadioItem };
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import * as _angular_core from '@angular/core';
|
|
2
|
+
import { TemplateRef } from '@angular/core';
|
|
3
|
+
import { ControlValueAccessor, Validators, NgControl } from '@angular/forms';
|
|
4
|
+
import { RadioItem } from '@masterteam/components/radio-cards';
|
|
5
|
+
|
|
6
|
+
declare class RadioCardsField implements ControlValueAccessor {
|
|
7
|
+
readonly circle: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
8
|
+
readonly label: _angular_core.InputSignal<string | undefined>;
|
|
9
|
+
readonly required: _angular_core.InputSignal<boolean>;
|
|
10
|
+
readonly color: _angular_core.InputSignal<string>;
|
|
11
|
+
readonly size: _angular_core.InputSignal<"small" | "medium" | "large">;
|
|
12
|
+
readonly options: _angular_core.InputSignal<RadioItem[]>;
|
|
13
|
+
readonly itemTemplate: _angular_core.Signal<TemplateRef<any> | undefined>;
|
|
14
|
+
protected selectedId: _angular_core.WritableSignal<string | number | null>;
|
|
15
|
+
protected isDisabled: _angular_core.WritableSignal<boolean>;
|
|
16
|
+
requiredValidator: typeof Validators.required;
|
|
17
|
+
ngControl: NgControl | null;
|
|
18
|
+
constructor();
|
|
19
|
+
private onChange;
|
|
20
|
+
private onTouched;
|
|
21
|
+
writeValue(value: string | number): void;
|
|
22
|
+
registerOnChange(fn: (value: string | number) => void): void;
|
|
23
|
+
registerOnTouched(fn: () => void): void;
|
|
24
|
+
setDisabledState(isDisabled: boolean): void;
|
|
25
|
+
onSelectionChange(selectedItem: RadioItem): void;
|
|
26
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<RadioCardsField, never>;
|
|
27
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<RadioCardsField, "mt-radio-cards-field", never, { "circle": { "alias": "circle"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "color": { "alias": "color"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "options": { "alias": "options"; "required": true; "isSignal": true; }; }, {}, ["itemTemplate"], never, true, never>;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export { RadioCardsField };
|