@masterteam/components 0.0.307 → 0.0.309

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.
@@ -2299,11 +2299,11 @@ class EntityListDrawer {
2299
2299
  activeLang = sharedActiveLang(inject(TranslocoService));
2300
2300
  rows = computed(() => buildEntityListRows(this.data(), this.fields(), this.activeLang()), ...(ngDevMode ? [{ debugName: "rows" }] : /* istanbul ignore next */ []));
2301
2301
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: EntityListDrawer, deps: [], target: i0.ɵɵFactoryTarget.Component });
2302
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: EntityListDrawer, isStandalone: true, selector: "mt-entity-list-drawer", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: true, transformFunction: null }, fields: { classPropertyName: "fields", publicName: "fields", isSignal: true, isRequired: false, transformFunction: null }, table: { classPropertyName: "table", publicName: "table", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "block h-full" }, ngImport: i0, template: "<!--\n Owns its scroll rather than taking the shared `mt-modal-content` shell: that\n class reserves 60px for a footer, and this drawer is read-only and has none,\n so it would leave a dead strip at the bottom. `h-full` chains off the host's,\n which chains off `.p-drawer-content` \u2014 the one definite height here.\n-->\n<div class=\"flex h-full flex-col gap-2 overflow-auto p-5\">\n @if (table(); as host) {\n <!--\n The list as a record preview renders it: the read-only\n `mt-entity-list-field`, through the component the opener handed over \u2014\n it cannot be imported here without a circular entry point.\n -->\n <ng-container\n *ngComponentOutlet=\"host.component; inputs: host.inputs\"\n ></ng-container>\n } @else {\n @for (row of rows(); track row.id) {\n <div\n class=\"rounded-md border border-surface-200 bg-surface-50 px-3 py-2.5\"\n >\n @if (row.title; as title) {\n <div class=\"min-w-0 text-sm font-medium text-color\">\n <mt-entity-value-preview [data]=\"title\" attachmentShape=\"compact\" />\n </div>\n }\n\n @if (row.fields.length) {\n <!--\n The drawer has room the cell did not, so fields get a real grid with\n their labels instead of being crushed onto one wrapping line.\n `auto-fill` adapts to the drawer's actual width without a container\n query, and the `min()` floor keeps a narrow drawer from being forced\n wider than the viewport.\n -->\n <div\n class=\"mt-2 grid gap-x-4 gap-y-3 [grid-template-columns:repeat(auto-fill,minmax(min(9rem,100%),1fr))]\"\n >\n @for (field of row.fields; track field.key) {\n <div class=\"min-w-0 overflow-hidden\">\n <mt-entity-value-preview\n [data]=\"field\"\n attachmentShape=\"compact\"\n />\n </div>\n }\n </div>\n }\n </div>\n }\n }\n</div>\n", dependencies: [{ kind: "component", type: EntityValuePreview, selector: "mt-entity-value-preview", inputs: ["data", "attachmentShape"] }, { kind: "directive", type: NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletEnvironmentInjector", "ngComponentOutletContent", "ngComponentOutletNgModule"], exportAs: ["ngComponentOutlet"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
2302
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: EntityListDrawer, isStandalone: true, selector: "mt-entity-list-drawer", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: true, transformFunction: null }, fields: { classPropertyName: "fields", publicName: "fields", isSignal: true, isRequired: false, transformFunction: null }, table: { classPropertyName: "table", publicName: "table", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "block h-full" }, ngImport: i0, template: "<!--\r\n Owns its scroll rather than taking the shared `mt-modal-content` shell: that\r\n class reserves 60px for a footer, and this drawer is read-only and has none,\r\n so it would leave a dead strip at the bottom. `h-full` chains off the host's,\r\n which chains off `.p-drawer-content` \u2014 the one definite height here.\r\n-->\r\n<div class=\"flex h-full flex-col gap-2 overflow-auto p-5\">\r\n @if (table(); as host) {\r\n <!--\r\n The list as a record preview renders it: the read-only\r\n `mt-entity-list-field`, through the component the opener handed over \u2014\r\n it cannot be imported here without a circular entry point.\r\n -->\r\n <ng-container\r\n *ngComponentOutlet=\"host.component; inputs: host.inputs\"\r\n ></ng-container>\r\n } @else {\r\n @for (row of rows(); track row.id) {\r\n <div\r\n class=\"rounded-md border border-surface-200 bg-surface-50 px-3 py-2.5\"\r\n >\r\n @if (row.title; as title) {\r\n <div class=\"min-w-0 text-sm font-medium text-color\">\r\n <mt-entity-value-preview [data]=\"title\" attachmentShape=\"compact\" />\r\n </div>\r\n }\r\n\r\n @if (row.fields.length) {\r\n <!--\r\n The drawer has room the cell did not, so fields get a real grid with\r\n their labels instead of being crushed onto one wrapping line.\r\n `auto-fill` adapts to the drawer's actual width without a container\r\n query, and the `min()` floor keeps a narrow drawer from being forced\r\n wider than the viewport.\r\n -->\r\n <div\r\n class=\"mt-2 grid gap-x-4 gap-y-3 [grid-template-columns:repeat(auto-fill,minmax(min(9rem,100%),1fr))]\"\r\n >\r\n @for (field of row.fields; track field.key) {\r\n <div class=\"min-w-0 overflow-hidden\">\r\n <mt-entity-value-preview\r\n [data]=\"field\"\r\n attachmentShape=\"compact\"\r\n />\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n }\r\n }\r\n</div>\r\n", dependencies: [{ kind: "component", type: EntityValuePreview, selector: "mt-entity-value-preview", inputs: ["data", "attachmentShape"] }, { kind: "directive", type: NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletEnvironmentInjector", "ngComponentOutletContent", "ngComponentOutletNgModule"], exportAs: ["ngComponentOutlet"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
2303
2303
  }
2304
2304
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: EntityListDrawer, decorators: [{
2305
2305
  type: Component,
2306
- args: [{ selector: 'mt-entity-list-drawer', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [EntityValuePreview, NgComponentOutlet], host: { class: 'block h-full' }, template: "<!--\n Owns its scroll rather than taking the shared `mt-modal-content` shell: that\n class reserves 60px for a footer, and this drawer is read-only and has none,\n so it would leave a dead strip at the bottom. `h-full` chains off the host's,\n which chains off `.p-drawer-content` \u2014 the one definite height here.\n-->\n<div class=\"flex h-full flex-col gap-2 overflow-auto p-5\">\n @if (table(); as host) {\n <!--\n The list as a record preview renders it: the read-only\n `mt-entity-list-field`, through the component the opener handed over \u2014\n it cannot be imported here without a circular entry point.\n -->\n <ng-container\n *ngComponentOutlet=\"host.component; inputs: host.inputs\"\n ></ng-container>\n } @else {\n @for (row of rows(); track row.id) {\n <div\n class=\"rounded-md border border-surface-200 bg-surface-50 px-3 py-2.5\"\n >\n @if (row.title; as title) {\n <div class=\"min-w-0 text-sm font-medium text-color\">\n <mt-entity-value-preview [data]=\"title\" attachmentShape=\"compact\" />\n </div>\n }\n\n @if (row.fields.length) {\n <!--\n The drawer has room the cell did not, so fields get a real grid with\n their labels instead of being crushed onto one wrapping line.\n `auto-fill` adapts to the drawer's actual width without a container\n query, and the `min()` floor keeps a narrow drawer from being forced\n wider than the viewport.\n -->\n <div\n class=\"mt-2 grid gap-x-4 gap-y-3 [grid-template-columns:repeat(auto-fill,minmax(min(9rem,100%),1fr))]\"\n >\n @for (field of row.fields; track field.key) {\n <div class=\"min-w-0 overflow-hidden\">\n <mt-entity-value-preview\n [data]=\"field\"\n attachmentShape=\"compact\"\n />\n </div>\n }\n </div>\n }\n </div>\n }\n }\n</div>\n" }]
2306
+ args: [{ selector: 'mt-entity-list-drawer', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [EntityValuePreview, NgComponentOutlet], host: { class: 'block h-full' }, template: "<!--\r\n Owns its scroll rather than taking the shared `mt-modal-content` shell: that\r\n class reserves 60px for a footer, and this drawer is read-only and has none,\r\n so it would leave a dead strip at the bottom. `h-full` chains off the host's,\r\n which chains off `.p-drawer-content` \u2014 the one definite height here.\r\n-->\r\n<div class=\"flex h-full flex-col gap-2 overflow-auto p-5\">\r\n @if (table(); as host) {\r\n <!--\r\n The list as a record preview renders it: the read-only\r\n `mt-entity-list-field`, through the component the opener handed over \u2014\r\n it cannot be imported here without a circular entry point.\r\n -->\r\n <ng-container\r\n *ngComponentOutlet=\"host.component; inputs: host.inputs\"\r\n ></ng-container>\r\n } @else {\r\n @for (row of rows(); track row.id) {\r\n <div\r\n class=\"rounded-md border border-surface-200 bg-surface-50 px-3 py-2.5\"\r\n >\r\n @if (row.title; as title) {\r\n <div class=\"min-w-0 text-sm font-medium text-color\">\r\n <mt-entity-value-preview [data]=\"title\" attachmentShape=\"compact\" />\r\n </div>\r\n }\r\n\r\n @if (row.fields.length) {\r\n <!--\r\n The drawer has room the cell did not, so fields get a real grid with\r\n their labels instead of being crushed onto one wrapping line.\r\n `auto-fill` adapts to the drawer's actual width without a container\r\n query, and the `min()` floor keeps a narrow drawer from being forced\r\n wider than the viewport.\r\n -->\r\n <div\r\n class=\"mt-2 grid gap-x-4 gap-y-3 [grid-template-columns:repeat(auto-fill,minmax(min(9rem,100%),1fr))]\"\r\n >\r\n @for (field of row.fields; track field.key) {\r\n <div class=\"min-w-0 overflow-hidden\">\r\n <mt-entity-value-preview\r\n [data]=\"field\"\r\n attachmentShape=\"compact\"\r\n />\r\n </div>\r\n }\r\n </div>\r\n }\r\n </div>\r\n }\r\n }\r\n</div>\r\n" }]
2307
2307
  }], propDecorators: { data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: true }] }], fields: [{ type: i0.Input, args: [{ isSignal: true, alias: "fields", required: false }] }], table: [{ type: i0.Input, args: [{ isSignal: true, alias: "table", required: false }] }] } });
2308
2308
 
2309
2309
  /** Rows named in the tooltip before it collapses into "+N more". */
@@ -2535,11 +2535,11 @@ class EntityListPreview {
2535
2535
  });
2536
2536
  }
2537
2537
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: EntityListPreview, deps: [], target: i0.ɵɵFactoryTarget.Component });
2538
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: EntityListPreview, isStandalone: true, selector: "mt-entity-list-preview", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: true, transformFunction: null }, fields: { classPropertyName: "fields", publicName: "fields", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<mt-entity-field\n [label]=\"label()\"\n [configuration]=\"data().configuration\"\n gap=\"normal\"\n>\n @if (tableHost(); as host) {\n <!--\n The related records, rendered in full by the read-only\n `mt-entity-list-field`. It owns the metadata request, the access notices\n and the column projection \u2014 see `ENTITY_LIST_TABLE_COMPONENT` for why it\n arrives through an outlet rather than an import.\n -->\n <ng-container\n *ngComponentOutlet=\"host.component; inputs: host.inputs\"\n ></ng-container>\n } @else if (showTrigger()) {\n <!--\n The count carries the information; the button carries the affordance.\n `mt-button` owns the tooltip and the accessible name, so the trigger is\n one element rather than a button wrapped in a tooltip host. A Related\n list opened as a table says \"View\" instead of a count; see\n `triggerLabel`.\n -->\n <mt-button\n icon=\"general.eye\"\n [label]=\"triggerLabel()\"\n [tooltip]=\"tooltip()\"\n [ariaLabel]=\"ariaLabel()\"\n variant=\"text\"\n size=\"small\"\n styleClass=\"!px-2 !py-1 !gap-1\"\n (onClick)=\"openDrawer()\"\n />\n } @else {\n <span\n class=\"inline-flex w-fit items-center rounded-md bg-surface-100 px-3 py-2 text-xs font-semibold text-muted-color\"\n >\n {{ emptyLabel }}\n </span>\n }\n</mt-entity-field>\n", dependencies: [{ kind: "component", type: EntityField, selector: "mt-entity-field", inputs: ["label", "labelIconName", "configuration", "gap"] }, { kind: "component", type: Button, selector: "mt-button", inputs: ["icon", "label", "tooltip", "class", "type", "styleClass", "severity", "badge", "variant", "badgeSeverity", "size", "iconPos", "autofocus", "fluid", "raised", "rounded", "text", "plain", "outlined", "link", "disabled", "loading", "pInputs", "ariaLabel"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "directive", type: NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletEnvironmentInjector", "ngComponentOutletContent", "ngComponentOutletNgModule"], exportAs: ["ngComponentOutlet"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
2538
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.8", type: EntityListPreview, isStandalone: true, selector: "mt-entity-list-preview", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: true, transformFunction: null }, fields: { classPropertyName: "fields", publicName: "fields", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<mt-entity-field\r\n [label]=\"label()\"\r\n [configuration]=\"data().configuration\"\r\n gap=\"normal\"\r\n>\r\n @if (tableHost(); as host) {\r\n <!--\r\n The related records, rendered in full by the read-only\r\n `mt-entity-list-field`. It owns the metadata request, the access notices\r\n and the column projection \u2014 see `ENTITY_LIST_TABLE_COMPONENT` for why it\r\n arrives through an outlet rather than an import.\r\n -->\r\n <ng-container\r\n *ngComponentOutlet=\"host.component; inputs: host.inputs\"\r\n ></ng-container>\r\n } @else if (showTrigger()) {\r\n <!--\r\n The count carries the information; the button carries the affordance.\r\n `mt-button` owns the tooltip and the accessible name, so the trigger is\r\n one element rather than a button wrapped in a tooltip host. A Related\r\n list opened as a table says \"View\" instead of a count; see\r\n `triggerLabel`.\r\n -->\r\n <mt-button\r\n icon=\"general.eye\"\r\n [label]=\"triggerLabel()\"\r\n [tooltip]=\"tooltip()\"\r\n [ariaLabel]=\"ariaLabel()\"\r\n variant=\"text\"\r\n size=\"small\"\r\n styleClass=\"!px-2 !py-1 !gap-1\"\r\n (onClick)=\"openDrawer()\"\r\n />\r\n } @else {\r\n <span\r\n class=\"inline-flex w-fit items-center rounded-md bg-surface-100 px-3 py-2 text-xs font-semibold text-muted-color\"\r\n >\r\n {{ emptyLabel }}\r\n </span>\r\n }\r\n</mt-entity-field>\r\n", dependencies: [{ kind: "component", type: EntityField, selector: "mt-entity-field", inputs: ["label", "labelIconName", "configuration", "gap"] }, { kind: "component", type: Button, selector: "mt-button", inputs: ["icon", "label", "tooltip", "class", "type", "styleClass", "severity", "badge", "variant", "badgeSeverity", "size", "iconPos", "autofocus", "fluid", "raised", "rounded", "text", "plain", "outlined", "link", "disabled", "loading", "pInputs", "ariaLabel"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "directive", type: NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletEnvironmentInjector", "ngComponentOutletContent", "ngComponentOutletNgModule"], exportAs: ["ngComponentOutlet"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
2539
2539
  }
2540
2540
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.8", ngImport: i0, type: EntityListPreview, decorators: [{
2541
2541
  type: Component,
2542
- args: [{ selector: 'mt-entity-list-preview', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [EntityField, Button, NgComponentOutlet], template: "<mt-entity-field\n [label]=\"label()\"\n [configuration]=\"data().configuration\"\n gap=\"normal\"\n>\n @if (tableHost(); as host) {\n <!--\n The related records, rendered in full by the read-only\n `mt-entity-list-field`. It owns the metadata request, the access notices\n and the column projection \u2014 see `ENTITY_LIST_TABLE_COMPONENT` for why it\n arrives through an outlet rather than an import.\n -->\n <ng-container\n *ngComponentOutlet=\"host.component; inputs: host.inputs\"\n ></ng-container>\n } @else if (showTrigger()) {\n <!--\n The count carries the information; the button carries the affordance.\n `mt-button` owns the tooltip and the accessible name, so the trigger is\n one element rather than a button wrapped in a tooltip host. A Related\n list opened as a table says \"View\" instead of a count; see\n `triggerLabel`.\n -->\n <mt-button\n icon=\"general.eye\"\n [label]=\"triggerLabel()\"\n [tooltip]=\"tooltip()\"\n [ariaLabel]=\"ariaLabel()\"\n variant=\"text\"\n size=\"small\"\n styleClass=\"!px-2 !py-1 !gap-1\"\n (onClick)=\"openDrawer()\"\n />\n } @else {\n <span\n class=\"inline-flex w-fit items-center rounded-md bg-surface-100 px-3 py-2 text-xs font-semibold text-muted-color\"\n >\n {{ emptyLabel }}\n </span>\n }\n</mt-entity-field>\n" }]
2542
+ args: [{ selector: 'mt-entity-list-preview', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [EntityField, Button, NgComponentOutlet], template: "<mt-entity-field\r\n [label]=\"label()\"\r\n [configuration]=\"data().configuration\"\r\n gap=\"normal\"\r\n>\r\n @if (tableHost(); as host) {\r\n <!--\r\n The related records, rendered in full by the read-only\r\n `mt-entity-list-field`. It owns the metadata request, the access notices\r\n and the column projection \u2014 see `ENTITY_LIST_TABLE_COMPONENT` for why it\r\n arrives through an outlet rather than an import.\r\n -->\r\n <ng-container\r\n *ngComponentOutlet=\"host.component; inputs: host.inputs\"\r\n ></ng-container>\r\n } @else if (showTrigger()) {\r\n <!--\r\n The count carries the information; the button carries the affordance.\r\n `mt-button` owns the tooltip and the accessible name, so the trigger is\r\n one element rather than a button wrapped in a tooltip host. A Related\r\n list opened as a table says \"View\" instead of a count; see\r\n `triggerLabel`.\r\n -->\r\n <mt-button\r\n icon=\"general.eye\"\r\n [label]=\"triggerLabel()\"\r\n [tooltip]=\"tooltip()\"\r\n [ariaLabel]=\"ariaLabel()\"\r\n variant=\"text\"\r\n size=\"small\"\r\n styleClass=\"!px-2 !py-1 !gap-1\"\r\n (onClick)=\"openDrawer()\"\r\n />\r\n } @else {\r\n <span\r\n class=\"inline-flex w-fit items-center rounded-md bg-surface-100 px-3 py-2 text-xs font-semibold text-muted-color\"\r\n >\r\n {{ emptyLabel }}\r\n </span>\r\n }\r\n</mt-entity-field>\r\n" }]
2543
2543
  }], propDecorators: { data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: true }] }], fields: [{ type: i0.Input, args: [{ isSignal: true, alias: "fields", required: false }] }] } });
2544
2544
 
2545
2545
  /**