@nanahoshi/mona-ui 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/nanahoshi-mona-ui-auto-complete.mjs +11 -11
- package/fesm2022/nanahoshi-mona-ui-breadcrumb.mjs +17 -17
- package/fesm2022/nanahoshi-mona-ui-button-group.mjs +26 -26
- package/fesm2022/nanahoshi-mona-ui-button.mjs +109 -107
- package/fesm2022/nanahoshi-mona-ui-calendar.mjs +53 -53
- package/fesm2022/nanahoshi-mona-ui-check-box.mjs +80 -80
- package/fesm2022/nanahoshi-mona-ui-chip.mjs +98 -98
- package/fesm2022/nanahoshi-mona-ui-circular-progress-bar.mjs +2 -2
- package/fesm2022/nanahoshi-mona-ui-color-gradient.mjs +38 -38
- package/fesm2022/nanahoshi-mona-ui-color-palette.mjs +25 -25
- package/fesm2022/nanahoshi-mona-ui-color-picker.mjs +41 -37
- package/fesm2022/nanahoshi-mona-ui-combo-box.mjs +17 -19
- package/fesm2022/nanahoshi-mona-ui-date-input.mjs +6 -6
- package/fesm2022/nanahoshi-mona-ui-date-picker.mjs +11 -13
- package/fesm2022/nanahoshi-mona-ui-datetime-picker.mjs +18 -20
- package/fesm2022/nanahoshi-mona-ui-dialog.mjs +40 -40
- package/fesm2022/nanahoshi-mona-ui-dropdown-list.mjs +14 -16
- package/fesm2022/nanahoshi-mona-ui-dropdowns.mjs +52 -52
- package/fesm2022/nanahoshi-mona-ui-editor.mjs +462 -81
- package/fesm2022/nanahoshi-mona-ui-expansion-panel.mjs +26 -26
- package/fesm2022/nanahoshi-mona-ui-fieldset.mjs +8 -8
- package/fesm2022/nanahoshi-mona-ui-filter.mjs +14 -14
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-footer-cell.component-B9SQH5N-.mjs → nanahoshi-mona-ui-grid-grid-footer-cell.component-B2ETh-uI.mjs} +14 -14
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-footer-table-cell.directive-DlLwcCFT.mjs → nanahoshi-mona-ui-grid-grid-footer-table-cell.directive-DZk18LJC.mjs} +2 -2
- package/fesm2022/nanahoshi-mona-ui-grid-grid-list.component-C7WKhhig.mjs +128 -0
- package/fesm2022/{nanahoshi-mona-ui-grid-grid-toggle.component-DIUutx9s.mjs → nanahoshi-mona-ui-grid-grid-toggle.component-BRiY0CDX.mjs} +13 -13
- package/fesm2022/nanahoshi-mona-ui-grid-grid-virtual-list.component-BrYpFMyF.mjs +240 -0
- package/fesm2022/{nanahoshi-mona-ui-grid-nanahoshi-mona-ui-grid-C3eZIaJK.mjs → nanahoshi-mona-ui-grid-nanahoshi-mona-ui-grid-T9Bj98kl.mjs} +120 -120
- package/fesm2022/nanahoshi-mona-ui-grid.mjs +1 -1
- package/fesm2022/nanahoshi-mona-ui-internal-list.mjs +81 -81
- package/fesm2022/nanahoshi-mona-ui-internal-tree.mjs +35 -35
- package/fesm2022/nanahoshi-mona-ui-list-box.mjs +8 -8
- package/fesm2022/nanahoshi-mona-ui-list-view.mjs +7 -7
- package/fesm2022/nanahoshi-mona-ui-menubar.mjs +50 -50
- package/fesm2022/nanahoshi-mona-ui-multi-select.mjs +12 -14
- package/fesm2022/nanahoshi-mona-ui-notification.mjs +24 -24
- package/fesm2022/nanahoshi-mona-ui-numeric-text-box.mjs +69 -69
- package/fesm2022/nanahoshi-mona-ui-pager.mjs +29 -29
- package/fesm2022/nanahoshi-mona-ui-placeholder.mjs +9 -9
- package/fesm2022/nanahoshi-mona-ui-popover.mjs +12 -12
- package/fesm2022/nanahoshi-mona-ui-popup-menu.mjs +26 -26
- package/fesm2022/nanahoshi-mona-ui-popup.mjs +4 -4
- package/fesm2022/nanahoshi-mona-ui-progress-bar.mjs +2 -2
- package/fesm2022/nanahoshi-mona-ui-radio-button.mjs +55 -55
- package/fesm2022/nanahoshi-mona-ui-scroll-view.mjs +49 -49
- package/fesm2022/nanahoshi-mona-ui-slider.mjs +96 -96
- package/fesm2022/nanahoshi-mona-ui-split-button.mjs +30 -30
- package/fesm2022/nanahoshi-mona-ui-splitter.mjs +24 -24
- package/fesm2022/nanahoshi-mona-ui-stepper.mjs +29 -29
- package/fesm2022/nanahoshi-mona-ui-switch.mjs +42 -42
- package/fesm2022/nanahoshi-mona-ui-tabs.mjs +35 -39
- package/fesm2022/nanahoshi-mona-ui-text-area.mjs +22 -22
- package/fesm2022/nanahoshi-mona-ui-text-box.mjs +54 -54
- package/fesm2022/nanahoshi-mona-ui-time-picker.mjs +11 -19
- package/fesm2022/nanahoshi-mona-ui-time-selector.mjs +29 -29
- package/fesm2022/nanahoshi-mona-ui-tooltip.mjs +51 -51
- package/fesm2022/nanahoshi-mona-ui-tree-view.mjs +2 -2
- package/fesm2022/nanahoshi-mona-ui-window.mjs +27 -28
- package/package.json +30 -5
- package/types/nanahoshi-mona-ui-button.d.ts +4 -3
- package/types/nanahoshi-mona-ui-color-picker.d.ts +0 -3
- package/types/nanahoshi-mona-ui-dialog.d.ts +2 -2
- package/types/nanahoshi-mona-ui-editor.d.ts +17 -17
- package/types/nanahoshi-mona-ui-fieldset.d.ts +1 -1
- package/types/nanahoshi-mona-ui-filter.d.ts +2 -2
- package/types/nanahoshi-mona-ui-grid.d.ts +3 -3
- package/types/nanahoshi-mona-ui-internal-tree.d.ts +16 -16
- package/types/nanahoshi-mona-ui-menubar.d.ts +2 -2
- package/types/nanahoshi-mona-ui-stepper.d.ts +2 -2
- package/types/nanahoshi-mona-ui-tabs.d.ts +2 -2
- package/fesm2022/nanahoshi-mona-ui-grid-grid-list.component-Dgea-O0X.mjs +0 -130
- package/fesm2022/nanahoshi-mona-ui-grid-grid-virtual-list.component-DRHycGIh.mjs +0 -240
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { inject, computed, input, Directive, Component, signal, ElementRef, viewChild, output, effect, untracked, afterNextRender, ChangeDetectionStrategy, LOCALE_ID, model } from '@angular/core';
|
|
3
3
|
import { ThemeService } from '@nanahoshi/mona-ui/theme';
|
|
4
|
-
import { k as gridListTableCellThemeVariants, l as gridDetailContentCellThemeVariants, m as gridDetailIndentCellThemeVariants, n as gridDetailRowThemeVariants, c as GridService, o as gridListTableRowThemeVariants, p as gridCellEditorBaseThemeVariants, q as gridCellEditorInputThemeVariants, h as GridLockedCellDirective, f as GridLogicalCellDirective, r as gridCellBaseThemeVariants, s as gridCellContainerThemeVariants, t as gridCellDirtyIndicatorThemeVariants, u as gridCellTextThemeVariants } from './nanahoshi-mona-ui-grid-nanahoshi-mona-ui-grid-
|
|
4
|
+
import { k as gridListTableCellThemeVariants, l as gridDetailContentCellThemeVariants, m as gridDetailIndentCellThemeVariants, n as gridDetailRowThemeVariants, c as GridService, o as gridListTableRowThemeVariants, p as gridCellEditorBaseThemeVariants, q as gridCellEditorInputThemeVariants, h as GridLockedCellDirective, f as GridLogicalCellDirective, r as gridCellBaseThemeVariants, s as gridCellContainerThemeVariants, t as gridCellDirtyIndicatorThemeVariants, u as gridCellTextThemeVariants } from './nanahoshi-mona-ui-grid-nanahoshi-mona-ui-grid-T9Bj98kl.mjs';
|
|
5
5
|
import { ImmutableList } from '@mirei/ts-collections';
|
|
6
6
|
import * as i1 from '@angular/cdk/a11y';
|
|
7
7
|
import { A11yModule } from '@angular/cdk/a11y';
|
|
8
8
|
import { NgTemplateOutlet, formatDate } from '@angular/common';
|
|
9
9
|
import { LucideCheck, LucideOctagonAlert, LucideX, LucidePencil, LucideTrash2, LucideMinus, LucideChevronDown, LucidePlus, LucideChevronRight, LucideDynamicIcon } from '@lucide/angular';
|
|
10
|
-
import { take } from 'rxjs';
|
|
11
10
|
import { ButtonDirective } from '@nanahoshi/mona-ui/button';
|
|
12
11
|
import { DialogService } from '@nanahoshi/mona-ui/dialog';
|
|
13
12
|
import { TooltipComponent } from '@nanahoshi/mona-ui/tooltip';
|
|
13
|
+
import { take } from 'rxjs';
|
|
14
14
|
import { FormField } from '@angular/forms/signals';
|
|
15
15
|
import { CheckBoxComponent } from '@nanahoshi/mona-ui/check-box';
|
|
16
16
|
import { DatePickerComponent } from '@nanahoshi/mona-ui/date-picker';
|
|
@@ -308,7 +308,7 @@ class GridCommandCellComponent {
|
|
|
308
308
|
this.gridService.commitRowEdit(event);
|
|
309
309
|
}
|
|
310
310
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: GridCommandCellComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
311
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: GridCommandCellComponent, isStandalone: true, selector: "mona-grid-command-cell", inputs: { column: { classPropertyName: "column", publicName: "column", isSignal: true, isRequired: true, transformFunction: null }, newRow: { classPropertyName: "newRow", publicName: "newRow", isSignal: true, isRequired: false, transformFunction: null }, row: { classPropertyName: "row", publicName: "row", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "w-full" }, ngImport: i0, template: "@if (column().commandTemplate) {\
|
|
311
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: GridCommandCellComponent, isStandalone: true, selector: "mona-grid-command-cell", inputs: { column: { classPropertyName: "column", publicName: "column", isSignal: true, isRequired: true, transformFunction: null }, newRow: { classPropertyName: "newRow", publicName: "newRow", isSignal: true, isRequired: false, transformFunction: null }, row: { classPropertyName: "row", publicName: "row", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "w-full" }, ngImport: i0, template: "@if (column().commandTemplate) {\n <ng-container\n [ngTemplateOutlet]=\"column().commandTemplate\"\n [ngTemplateOutletContext]=\"commandContext()\"></ng-container>\n} @else {\n <div class=\"flex h-full items-center gap-1 px-1\">\n @if (isEditing()) {\n @if (hasRowError()) {\n <span class=\"shrink-0 px-1 text-error\" #rowErrorIcon>\n <svg lucideOctagonAlert [size]=\"14\"></svg>\n </span>\n <mona-tooltip [target]=\"rowErrorIcon\">\n <span class=\"p-1 whitespace-pre-line\">{{ rowErrorTooltip() }}</span>\n </mona-tooltip>\n }\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n [iconOnly]=\"true\"\n aria-label=\"Save row\"\n title=\"Save\"\n class=\"w-6 h-6\"\n [tabindex]=\"-1\"\n (click)=\"save($event)\">\n <svg lucideCheck [size]=\"14\"></svg>\n </button>\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n [iconOnly]=\"true\"\n aria-label=\"Cancel row edit\"\n title=\"Cancel\"\n class=\"w-6 h-6\"\n [tabindex]=\"-1\"\n (click)=\"cancel($event)\">\n <svg lucideX [size]=\"14\"></svg>\n </button>\n } @else {\n @if (canEditRows()) {\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n [iconOnly]=\"true\"\n aria-label=\"Edit row\"\n title=\"Edit\"\n class=\"w-6 h-6\"\n [tabindex]=\"-1\"\n (click)=\"edit($event)\">\n <svg lucidePencil [size]=\"14\"></svg>\n </button>\n }\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n [iconOnly]=\"true\"\n aria-label=\"Remove row\"\n title=\"Remove\"\n class=\"w-6 h-6\"\n [tabindex]=\"-1\"\n (click)=\"remove($event)\">\n <svg lucideTrash2 [size]=\"14\"></svg>\n </button>\n }\n </div>\n}\n", dependencies: [{ kind: "directive", type: ButtonDirective, selector: "button[monaButton]", inputs: ["aria-haspopup", "disabled", "iconOnly", "loading", "look", "rounded", "selected", "size", "tabindex", "toggleable", "class"], outputs: ["disabledChange", "loadingChange", "lookChange", "selectedChange"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: LucideCheck, selector: "svg[lucideCheck]" }, { kind: "component", type: LucideOctagonAlert, selector: "svg[lucideOctagonAlert], svg[lucideAlertOctagon]" }, { kind: "component", type: LucideX, selector: "svg[lucideX]" }, { kind: "component", type: LucidePencil, selector: "svg[lucidePencil]" }, { kind: "component", type: LucideTrash2, selector: "svg[lucideTrash2]" }, { kind: "component", type: TooltipComponent, selector: "mona-tooltip", inputs: ["disabled", "hideDelay", "position", "rounded", "showDelay", "target"], outputs: ["hidden", "shown"] }] }); }
|
|
312
312
|
}
|
|
313
313
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: GridCommandCellComponent, decorators: [{
|
|
314
314
|
type: Component,
|
|
@@ -323,7 +323,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
323
323
|
TooltipComponent
|
|
324
324
|
], host: {
|
|
325
325
|
class: "w-full"
|
|
326
|
-
}, template: "@if (column().commandTemplate) {\
|
|
326
|
+
}, template: "@if (column().commandTemplate) {\n <ng-container\n [ngTemplateOutlet]=\"column().commandTemplate\"\n [ngTemplateOutletContext]=\"commandContext()\"></ng-container>\n} @else {\n <div class=\"flex h-full items-center gap-1 px-1\">\n @if (isEditing()) {\n @if (hasRowError()) {\n <span class=\"shrink-0 px-1 text-error\" #rowErrorIcon>\n <svg lucideOctagonAlert [size]=\"14\"></svg>\n </span>\n <mona-tooltip [target]=\"rowErrorIcon\">\n <span class=\"p-1 whitespace-pre-line\">{{ rowErrorTooltip() }}</span>\n </mona-tooltip>\n }\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n [iconOnly]=\"true\"\n aria-label=\"Save row\"\n title=\"Save\"\n class=\"w-6 h-6\"\n [tabindex]=\"-1\"\n (click)=\"save($event)\">\n <svg lucideCheck [size]=\"14\"></svg>\n </button>\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n [iconOnly]=\"true\"\n aria-label=\"Cancel row edit\"\n title=\"Cancel\"\n class=\"w-6 h-6\"\n [tabindex]=\"-1\"\n (click)=\"cancel($event)\">\n <svg lucideX [size]=\"14\"></svg>\n </button>\n } @else {\n @if (canEditRows()) {\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n [iconOnly]=\"true\"\n aria-label=\"Edit row\"\n title=\"Edit\"\n class=\"w-6 h-6\"\n [tabindex]=\"-1\"\n (click)=\"edit($event)\">\n <svg lucidePencil [size]=\"14\"></svg>\n </button>\n }\n <button\n monaButton\n look=\"ghost\"\n size=\"small\"\n [iconOnly]=\"true\"\n aria-label=\"Remove row\"\n title=\"Remove\"\n class=\"w-6 h-6\"\n [tabindex]=\"-1\"\n (click)=\"remove($event)\">\n <svg lucideTrash2 [size]=\"14\"></svg>\n </button>\n }\n </div>\n}\n" }]
|
|
327
327
|
}], propDecorators: { column: [{ type: i0.Input, args: [{ isSignal: true, alias: "column", required: true }] }], newRow: [{ type: i0.Input, args: [{ isSignal: true, alias: "newRow", required: false }] }], row: [{ type: i0.Input, args: [{ isSignal: true, alias: "row", required: false }] }] } });
|
|
328
328
|
|
|
329
329
|
class GridEditorComponent {
|
|
@@ -501,7 +501,7 @@ class GridEditorComponent {
|
|
|
501
501
|
this.formField()().value.set(value);
|
|
502
502
|
}
|
|
503
503
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: GridEditorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
504
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: GridEditorComponent, isStandalone: true, selector: "mona-grid-editor", inputs: { autoFocus: { classPropertyName: "autoFocus", publicName: "autoFocus", isSignal: true, isRequired: false, transformFunction: null }, column: { classPropertyName: "column", publicName: "column", isSignal: true, isRequired: true, transformFunction: null }, isNew: { classPropertyName: "isNew", publicName: "isNew", isSignal: true, isRequired: false, transformFunction: null }, session: { classPropertyName: "session", publicName: "session", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { cancel: "cancel", commit: "commit" }, host: { properties: { "class": "baseClass()" } }, viewQueries: [{ propertyName: "numericTextBoxRef", first: true, predicate: NumericTextBoxComponent, descendants: true, isSignal: true }, { propertyName: "textBoxRef", first: true, predicate: TextBoxComponent, descendants: true, isSignal: true }], ngImport: i0, template: "@if (column().editTemplate) {\
|
|
504
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: GridEditorComponent, isStandalone: true, selector: "mona-grid-editor", inputs: { autoFocus: { classPropertyName: "autoFocus", publicName: "autoFocus", isSignal: true, isRequired: false, transformFunction: null }, column: { classPropertyName: "column", publicName: "column", isSignal: true, isRequired: true, transformFunction: null }, isNew: { classPropertyName: "isNew", publicName: "isNew", isSignal: true, isRequired: false, transformFunction: null }, session: { classPropertyName: "session", publicName: "session", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { cancel: "cancel", commit: "commit" }, host: { properties: { "class": "baseClass()" } }, viewQueries: [{ propertyName: "numericTextBoxRef", first: true, predicate: NumericTextBoxComponent, descendants: true, isSignal: true }, { propertyName: "textBoxRef", first: true, predicate: TextBoxComponent, descendants: true, isSignal: true }], ngImport: i0, template: "@if (column().editTemplate) {\n <ng-container\n [ngTemplateOutlet]=\"column().editTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: editTemplateContext() }\"></ng-container>\n} @else {\n <div class=\"relative flex items-center w-full h-full\">\n @switch (column().dataType) {\n @case (\"string\") {\n <mona-text-box\n [class]=\"editorInputClass()\"\n [inputAttributes]=\"{ autocomplete: 'off' }\"\n [rounded]=\"'none'\"\n [formField]=\"$any(formField())\"\n (keydown.enter)=\"commit.emit()\"\n (keydown.escape)=\"onEditCancel()\"\n (inputBlur)=\"commit.emit()\"\n [size]=\"'small'\"></mona-text-box>\n }\n @case (\"number\") {\n <mona-numeric-text-box\n [class]=\"editorInputClass()\"\n [rounded]=\"'none'\"\n [formField]=\"$any(formField())\"\n (keydown.enter)=\"commit.emit()\"\n (keydown.escape)=\"onEditCancel()\"\n (inputBlur)=\"commit.emit()\"\n [size]=\"'small'\"></mona-numeric-text-box>\n }\n @case (\"boolean\") {\n <mona-check-box\n class=\"{{ editorInputClass() }} ml-2\"\n [rounded]=\"'none'\"\n [formField]=\"$any(formField())\"\n (click)=\"onBooleanEditorClick()\"\n (focusout)=\"onBooleanEditorFocusOut($event)\"\n (pointerdown)=\"onBooleanEditorPointerDown()\"\n (keydown.escape)=\"onEditCancel()\"\n (keydown.enter)=\"commit.emit()\"></mona-check-box>\n }\n @case (\"date\") {\n <mona-date-picker\n [class]=\"editorInputClass()\"\n [rounded]=\"'none'\"\n [formField]=\"$any(formField())\"\n (keydown.enter)=\"onDatePickerEnter($event)\"\n (keydown.escape)=\"onEditCancel()\"\n (focusout)=\"onDatePickerFocusOut($event)\"\n (opened)=\"onDatePickerOpen()\"\n (closed)=\"onDatePickerClose()\"\n size=\"small\"></mona-date-picker>\n }\n }\n @if (hasFieldError()) {\n <span class=\"shrink-0 px-1 text-error\" #fieldErrorIcon>\n <svg lucideOctagonAlert [size]=\"12\"></svg>\n </span>\n <mona-tooltip [target]=\"fieldErrorIcon\">\n <span class=\"p-1\">{{ fieldErrorMessage() }}</span>\n </mona-tooltip>\n }\n </div>\n}\n", dependencies: [{ kind: "component", type: CheckBoxComponent, selector: "mona-check-box", inputs: ["checked", "disabled", "indeterminate", "invalid", "label", "labelPosition", "labelSize", "required", "rounded", "tabIndex", "touched", "class"], outputs: ["checkedChange", "inputBlur", "inputChange", "inputFocus", "touch"] }, { kind: "component", type: DatePickerComponent, selector: "mona-date-picker", inputs: ["disabled", "disabledDates", "firstDay", "format", "invalid", "max", "min", "placeholder", "popupClass", "popupHeight", "popupWidth", "readonly", "readonlyInput", "required", "rounded", "showClearButton", "size", "touched", "class", "value", "weekNumber"], outputs: ["close", "closed", "open", "opened", "touch", "valueChange"] }, { kind: "directive", type: FormField, selector: "[formField]", inputs: ["formField"], exportAs: ["formField"] }, { kind: "component", type: LucideOctagonAlert, selector: "svg[lucideOctagonAlert], svg[lucideAlertOctagon]" }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: NumericTextBoxComponent, selector: "mona-numeric-text-box", inputs: ["aria-label", "decimals", "disabled", "formatter", "maxValue", "minValue", "nullable", "readonly", "required", "invalid", "rounded", "size", "spinners", "step", "tabindex", "touched", "class", "value"], outputs: ["inputBlur", "inputFocus", "inputFocusOut", "touch", "valueChange"] }, { kind: "component", type: TextBoxComponent, selector: "mona-text-box", inputs: ["clearButton", "disabled", "inputAttributes", "inputClass", "inputStyle", "invalid", "placeholder", "readonly", "required", "rounded", "size", "touched", "type", "class", "value"], outputs: ["inputBlur", "inputFocus", "touch", "valueChange"] }, { kind: "component", type: TooltipComponent, selector: "mona-tooltip", inputs: ["disabled", "hideDelay", "position", "rounded", "showDelay", "target"], outputs: ["hidden", "shown"] }] }); }
|
|
505
505
|
}
|
|
506
506
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: GridEditorComponent, decorators: [{
|
|
507
507
|
type: Component,
|
|
@@ -516,7 +516,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
516
516
|
TooltipComponent
|
|
517
517
|
], host: {
|
|
518
518
|
"[class]": "baseClass()"
|
|
519
|
-
}, template: "@if (column().editTemplate) {\
|
|
519
|
+
}, template: "@if (column().editTemplate) {\n <ng-container\n [ngTemplateOutlet]=\"column().editTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: editTemplateContext() }\"></ng-container>\n} @else {\n <div class=\"relative flex items-center w-full h-full\">\n @switch (column().dataType) {\n @case (\"string\") {\n <mona-text-box\n [class]=\"editorInputClass()\"\n [inputAttributes]=\"{ autocomplete: 'off' }\"\n [rounded]=\"'none'\"\n [formField]=\"$any(formField())\"\n (keydown.enter)=\"commit.emit()\"\n (keydown.escape)=\"onEditCancel()\"\n (inputBlur)=\"commit.emit()\"\n [size]=\"'small'\"></mona-text-box>\n }\n @case (\"number\") {\n <mona-numeric-text-box\n [class]=\"editorInputClass()\"\n [rounded]=\"'none'\"\n [formField]=\"$any(formField())\"\n (keydown.enter)=\"commit.emit()\"\n (keydown.escape)=\"onEditCancel()\"\n (inputBlur)=\"commit.emit()\"\n [size]=\"'small'\"></mona-numeric-text-box>\n }\n @case (\"boolean\") {\n <mona-check-box\n class=\"{{ editorInputClass() }} ml-2\"\n [rounded]=\"'none'\"\n [formField]=\"$any(formField())\"\n (click)=\"onBooleanEditorClick()\"\n (focusout)=\"onBooleanEditorFocusOut($event)\"\n (pointerdown)=\"onBooleanEditorPointerDown()\"\n (keydown.escape)=\"onEditCancel()\"\n (keydown.enter)=\"commit.emit()\"></mona-check-box>\n }\n @case (\"date\") {\n <mona-date-picker\n [class]=\"editorInputClass()\"\n [rounded]=\"'none'\"\n [formField]=\"$any(formField())\"\n (keydown.enter)=\"onDatePickerEnter($event)\"\n (keydown.escape)=\"onEditCancel()\"\n (focusout)=\"onDatePickerFocusOut($event)\"\n (opened)=\"onDatePickerOpen()\"\n (closed)=\"onDatePickerClose()\"\n size=\"small\"></mona-date-picker>\n }\n }\n @if (hasFieldError()) {\n <span class=\"shrink-0 px-1 text-error\" #fieldErrorIcon>\n <svg lucideOctagonAlert [size]=\"12\"></svg>\n </span>\n <mona-tooltip [target]=\"fieldErrorIcon\">\n <span class=\"p-1\">{{ fieldErrorMessage() }}</span>\n </mona-tooltip>\n }\n </div>\n}\n" }]
|
|
520
520
|
}], ctorParameters: () => [], propDecorators: { numericTextBoxRef: [{ type: i0.ViewChild, args: [i0.forwardRef(() => NumericTextBoxComponent), { isSignal: true }] }], textBoxRef: [{ type: i0.ViewChild, args: [i0.forwardRef(() => TextBoxComponent), { isSignal: true }] }], autoFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoFocus", required: false }] }], cancel: [{ type: i0.Output, args: ["cancel"] }], column: [{ type: i0.Input, args: [{ isSignal: true, alias: "column", required: true }] }], commit: [{ type: i0.Output, args: ["commit"] }], isNew: [{ type: i0.Input, args: [{ isSignal: true, alias: "isNew", required: false }] }], session: [{ type: i0.Input, args: [{ isSignal: true, alias: "session", required: true }] }] } });
|
|
521
521
|
|
|
522
522
|
class GridAddRowComponent {
|
|
@@ -545,7 +545,7 @@ class GridAddRowComponent {
|
|
|
545
545
|
this.gridService.patchAddCell(column.field, value);
|
|
546
546
|
}
|
|
547
547
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: GridAddRowComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
548
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: GridAddRowComponent, isStandalone: true, selector: "tr[monaGridAddRow]", inputs: { columns: { classPropertyName: "columns", publicName: "columns", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "row", "data-grid-add-row": "true" }, properties: { "class": "baseClass()" } }, ngImport: i0, template: "@if (gridService.addRowData(); as rowData) {\
|
|
548
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: GridAddRowComponent, isStandalone: true, selector: "tr[monaGridAddRow]", inputs: { columns: { classPropertyName: "columns", publicName: "columns", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "row", "data-grid-add-row": "true" }, properties: { "class": "baseClass()" } }, ngImport: i0, template: "@if (gridService.addRowData(); as rowData) {\n @let session = gridService.editSession();\n @for (_ of gridService.groupColumns(); track $index) {\n <td\n monaGridCell\n monaGridLockedCell\n [lockedCellHeader]=\"true\"\n [lockedStructuralOffset]=\"$index * gridService.groupColumnWidth\"\n [grouped]=\"true\"\n [indentCell]=\"true\"\n [attr.colspan]=\"1\"\n [style.width.px]=\"gridService.groupColumnWidth\"></td>\n }\n @if (gridService.masterDetailTemplate()) {\n <td\n monaGridCell\n monaGridLogicalCell\n monaGridLockedCell\n [lockedStructuralOffset]=\"gridService.groupColumns().length * gridService.groupColumnWidth\"\n [masterDetailToggle]=\"true\"\n [rowIndex]=\"-1\"\n [colIndex]=\"0\"\n [cellKind]=\"'detail'\"\n [firstInRow]=\"true\"\n [lastInRow]=\"columns().length === 0\"\n [section]=\"'add'\"\n [style.width.px]=\"gridService.detailColumnWidth\"></td>\n }\n @for (column of columns(); track $index) {\n @let colIndex = gridService.masterDetailTemplate() ? $index + 1 : $index;\n <td\n monaGridCell\n monaGridLockedCell\n [column]=\"column\"\n [dataCell]=\"true\"\n monaGridLogicalCell\n [cellKind]=\"column.kind\"\n [colIndex]=\"colIndex\"\n [columnId]=\"column.id\"\n [rowIndex]=\"-1\"\n [section]=\"'add'\"\n [firstInRow]=\"colIndex === 0\"\n [lastInRow]=\"colIndex === columns().length - (gridService.masterDetailTemplate() ? 0 : 1)\"\n [attr.colspan]=\"1\"\n [style.width.px]=\"column.calculatedWidth\"\n [style.min-width.px]=\"column.minWidth\">\n @if (column.kind === \"command\") {\n <mona-grid-command-cell [column]=\"column\" [newRow]=\"true\"></mona-grid-command-cell>\n } @else if (column.editable && session) {\n <mona-grid-editor\n [column]=\"column\"\n [autoFocus]=\"isFirstEditableColumn(column)\"\n [isNew]=\"true\"\n [session]=\"session\"\n (commit)=\"onCommit()\"\n (cancel)=\"onCancel()\"></mona-grid-editor>\n } @else {\n <span class=\"block truncate px-2\">{{ rowData[column.field] }}</span>\n }\n </td>\n }\n}\n", dependencies: [{ kind: "directive", type: GridCellDirective, selector: "td[monaGridCell]", inputs: ["dataCell", "groupHeader", "groupToggle", "grouped", "indentCell", "lastInRow", "masterDetailContent", "masterDetailToggle", "nextRowType", "prevRowType"] }, { kind: "component", type: GridCommandCellComponent, selector: "mona-grid-command-cell", inputs: ["column", "newRow", "row"] }, { kind: "component", type: GridEditorComponent, selector: "mona-grid-editor", inputs: ["autoFocus", "column", "isNew", "session"], outputs: ["cancel", "commit"] }, { kind: "directive", type: GridLockedCellDirective, selector: "td[monaGridLockedCell], th[monaGridLockedCell]", inputs: ["column", "lockedCellHeader", "lockedStructuralOffset"] }, { kind: "directive", type: GridLogicalCellDirective, selector: "td[monaGridLogicalCell], th[monaGridLogicalCell]", inputs: ["cellKind", "colIndex", "columnId", "firstInRow", "groupHeader", "groupKey", "lastInRow", "rowIndex", "rowUid", "section"], outputs: ["edit", "toggle"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
549
549
|
}
|
|
550
550
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: GridAddRowComponent, decorators: [{
|
|
551
551
|
type: Component,
|
|
@@ -559,7 +559,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
|
|
|
559
559
|
"[class]": "baseClass()",
|
|
560
560
|
role: "row",
|
|
561
561
|
"data-grid-add-row": "true"
|
|
562
|
-
}, template: "@if (gridService.addRowData(); as rowData) {\
|
|
562
|
+
}, template: "@if (gridService.addRowData(); as rowData) {\n @let session = gridService.editSession();\n @for (_ of gridService.groupColumns(); track $index) {\n <td\n monaGridCell\n monaGridLockedCell\n [lockedCellHeader]=\"true\"\n [lockedStructuralOffset]=\"$index * gridService.groupColumnWidth\"\n [grouped]=\"true\"\n [indentCell]=\"true\"\n [attr.colspan]=\"1\"\n [style.width.px]=\"gridService.groupColumnWidth\"></td>\n }\n @if (gridService.masterDetailTemplate()) {\n <td\n monaGridCell\n monaGridLogicalCell\n monaGridLockedCell\n [lockedStructuralOffset]=\"gridService.groupColumns().length * gridService.groupColumnWidth\"\n [masterDetailToggle]=\"true\"\n [rowIndex]=\"-1\"\n [colIndex]=\"0\"\n [cellKind]=\"'detail'\"\n [firstInRow]=\"true\"\n [lastInRow]=\"columns().length === 0\"\n [section]=\"'add'\"\n [style.width.px]=\"gridService.detailColumnWidth\"></td>\n }\n @for (column of columns(); track $index) {\n @let colIndex = gridService.masterDetailTemplate() ? $index + 1 : $index;\n <td\n monaGridCell\n monaGridLockedCell\n [column]=\"column\"\n [dataCell]=\"true\"\n monaGridLogicalCell\n [cellKind]=\"column.kind\"\n [colIndex]=\"colIndex\"\n [columnId]=\"column.id\"\n [rowIndex]=\"-1\"\n [section]=\"'add'\"\n [firstInRow]=\"colIndex === 0\"\n [lastInRow]=\"colIndex === columns().length - (gridService.masterDetailTemplate() ? 0 : 1)\"\n [attr.colspan]=\"1\"\n [style.width.px]=\"column.calculatedWidth\"\n [style.min-width.px]=\"column.minWidth\">\n @if (column.kind === \"command\") {\n <mona-grid-command-cell [column]=\"column\" [newRow]=\"true\"></mona-grid-command-cell>\n } @else if (column.editable && session) {\n <mona-grid-editor\n [column]=\"column\"\n [autoFocus]=\"isFirstEditableColumn(column)\"\n [isNew]=\"true\"\n [session]=\"session\"\n (commit)=\"onCommit()\"\n (cancel)=\"onCancel()\"></mona-grid-editor>\n } @else {\n <span class=\"block truncate px-2\">{{ rowData[column.field] }}</span>\n }\n </td>\n }\n}\n" }]
|
|
563
563
|
}], propDecorators: { columns: [{ type: i0.Input, args: [{ isSignal: true, alias: "columns", required: false }] }] } });
|
|
564
564
|
|
|
565
565
|
const FOCUSABLE_TARGET_SELECTOR = "button, input, select, textarea, a[href], [tabindex]";
|
|
@@ -729,13 +729,13 @@ class GridCellComponent {
|
|
|
729
729
|
this.gridService.startCellEdit(this.cellUid(), this.row(), this.column(), originalEvent);
|
|
730
730
|
}
|
|
731
731
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: GridCellComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
732
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: GridCellComponent, isStandalone: true, selector: "mona-grid-cell", inputs: { column: { classPropertyName: "column", publicName: "column", isSignal: true, isRequired: true, transformFunction: null }, row: { classPropertyName: "row", publicName: "row", isSignal: true, isRequired: true, transformFunction: null } }, host: { properties: { "class": "baseClass()" } }, ngImport: i0, template: "@let dataItem = row().data;\
|
|
732
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: GridCellComponent, isStandalone: true, selector: "mona-grid-cell", inputs: { column: { classPropertyName: "column", publicName: "column", isSignal: true, isRequired: true, transformFunction: null }, row: { classPropertyName: "row", publicName: "row", isSignal: true, isRequired: true, transformFunction: null } }, host: { properties: { "class": "baseClass()" } }, ngImport: i0, template: "@let dataItem = row().data;\n@let dataKey = column().field;\n\n@if (column().kind === \"command\") {\n <mona-grid-command-cell [column]=\"column()\" [row]=\"row()\"></mona-grid-command-cell>\n} @else {\n <div\n role=\"gridcell\"\n [class]=\"cellContainerClass()\"\n cdkMonitorSubtreeFocus\n [attr.data-uid]=\"cellUid()\"\n [attr.data-ruid]=\"row().uid\"\n [attr.data-field]=\"dataKey\"\n [attr.data-col-index]=\"column().index\"\n [attr.aria-readonly]=\"!(gridService.editableOptions().enabled && column().editable)\"\n (dblclick)=\"onCellDoubleClick($event)\">\n @if (isEditing() && gridService.editSession(); as session) {\n <mona-grid-editor\n [column]=\"column()\"\n [autoFocus]=\"shouldAutoFocusEditor()\"\n [session]=\"session\"\n (commit)=\"onEditCommit()\"\n (cancel)=\"onEditCancel()\"></mona-grid-editor>\n } @else if (column().cellTemplate) {\n <ng-container\n [ngTemplateOutlet]=\"column().cellTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: dataItem, column: column().field }\"></ng-container>\n } @else {\n <span [class]=\"cellTextClass()\">{{ formattedDisplayValue() }}</span>\n }\n @if (!isCellPristine()) {\n <span aria-hidden=\"true\" [class]=\"cellDirtyIndicatorClass()\" title=\"Modified\"></span>\n }\n </div>\n}\n", dependencies: [{ kind: "ngmodule", type: A11yModule }, { kind: "directive", type: i1.CdkMonitorFocus, selector: "[cdkMonitorElementFocus], [cdkMonitorSubtreeFocus]", outputs: ["cdkFocusChange"], exportAs: ["cdkMonitorFocus"] }, { kind: "component", type: GridCommandCellComponent, selector: "mona-grid-command-cell", inputs: ["column", "newRow", "row"] }, { kind: "component", type: GridEditorComponent, selector: "mona-grid-editor", inputs: ["autoFocus", "column", "isNew", "session"], outputs: ["cancel", "commit"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] }); }
|
|
733
733
|
}
|
|
734
734
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: GridCellComponent, decorators: [{
|
|
735
735
|
type: Component,
|
|
736
736
|
args: [{ selector: "mona-grid-cell", imports: [A11yModule, GridCommandCellComponent, GridEditorComponent, NgTemplateOutlet], host: {
|
|
737
737
|
"[class]": "baseClass()"
|
|
738
|
-
}, template: "@let dataItem = row().data;\
|
|
738
|
+
}, template: "@let dataItem = row().data;\n@let dataKey = column().field;\n\n@if (column().kind === \"command\") {\n <mona-grid-command-cell [column]=\"column()\" [row]=\"row()\"></mona-grid-command-cell>\n} @else {\n <div\n role=\"gridcell\"\n [class]=\"cellContainerClass()\"\n cdkMonitorSubtreeFocus\n [attr.data-uid]=\"cellUid()\"\n [attr.data-ruid]=\"row().uid\"\n [attr.data-field]=\"dataKey\"\n [attr.data-col-index]=\"column().index\"\n [attr.aria-readonly]=\"!(gridService.editableOptions().enabled && column().editable)\"\n (dblclick)=\"onCellDoubleClick($event)\">\n @if (isEditing() && gridService.editSession(); as session) {\n <mona-grid-editor\n [column]=\"column()\"\n [autoFocus]=\"shouldAutoFocusEditor()\"\n [session]=\"session\"\n (commit)=\"onEditCommit()\"\n (cancel)=\"onEditCancel()\"></mona-grid-editor>\n } @else if (column().cellTemplate) {\n <ng-container\n [ngTemplateOutlet]=\"column().cellTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: dataItem, column: column().field }\"></ng-container>\n } @else {\n <span [class]=\"cellTextClass()\">{{ formattedDisplayValue() }}</span>\n }\n @if (!isCellPristine()) {\n <span aria-hidden=\"true\" [class]=\"cellDirtyIndicatorClass()\" title=\"Modified\"></span>\n }\n </div>\n}\n" }]
|
|
739
739
|
}], propDecorators: { column: [{ type: i0.Input, args: [{ isSignal: true, alias: "column", required: true }] }], row: [{ type: i0.Input, args: [{ isSignal: true, alias: "row", required: true }] }] } });
|
|
740
740
|
|
|
741
741
|
class GridToggleComponent {
|
|
@@ -762,12 +762,12 @@ class GridToggleComponent {
|
|
|
762
762
|
this.expanded.update(v => !v);
|
|
763
763
|
}
|
|
764
764
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: GridToggleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
765
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: GridToggleComponent, isStandalone: true, selector: "mona-grid-toggle", inputs: { expanded: { classPropertyName: "expanded", publicName: "expanded", isSignal: true, isRequired: true, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: true, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { expanded: "expandedChange" }, ngImport: i0, template: "<span\
|
|
765
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: GridToggleComponent, isStandalone: true, selector: "mona-grid-toggle", inputs: { expanded: { classPropertyName: "expanded", publicName: "expanded", isSignal: true, isRequired: true, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: true, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { expanded: "expandedChange" }, ngImport: i0, template: "<span\n [style.width.px]=\"width()\"\n class=\"inline-flex items-center justify-center h-full aspect-square\"\n (click)=\"onToggleDetailClick($event)\">\n @if (expanded()) {\n <svg [lucideIcon]=\"collapseIcon()\" [size]=\"16\"></svg>\n } @else {\n <svg [lucideIcon]=\"expandIcon()\" [size]=\"16\"></svg>\n }\n</span>\n", dependencies: [{ kind: "component", type: LucideDynamicIcon, selector: "svg[lucideIcon]", inputs: ["lucideIcon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
766
766
|
}
|
|
767
767
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: GridToggleComponent, decorators: [{
|
|
768
768
|
type: Component,
|
|
769
|
-
args: [{ selector: "mona-grid-toggle", imports: [LucideDynamicIcon], changeDetection: ChangeDetectionStrategy.OnPush, template: "<span\
|
|
769
|
+
args: [{ selector: "mona-grid-toggle", imports: [LucideDynamicIcon], changeDetection: ChangeDetectionStrategy.OnPush, template: "<span\n [style.width.px]=\"width()\"\n class=\"inline-flex items-center justify-center h-full aspect-square\"\n (click)=\"onToggleDetailClick($event)\">\n @if (expanded()) {\n <svg [lucideIcon]=\"collapseIcon()\" [size]=\"16\"></svg>\n } @else {\n <svg [lucideIcon]=\"expandIcon()\" [size]=\"16\"></svg>\n }\n</span>\n" }]
|
|
770
770
|
}], propDecorators: { expanded: [{ type: i0.Input, args: [{ isSignal: true, alias: "expanded", required: true }] }, { type: i0.Output, args: ["expandedChange"] }], type: [{ type: i0.Input, args: [{ isSignal: true, alias: "type", required: true }] }], width: [{ type: i0.Input, args: [{ isSignal: true, alias: "width", required: true }] }] } });
|
|
771
771
|
|
|
772
772
|
export { GridAddRowComponent as G, GridCellComponent as a, GridRowDirective as b, GridCellDirective as c, GridDetailRowDirective as d, GridDetailIndentCellDirective as e, GridDetailContentCellDirective as f, GridToggleComponent as g };
|
|
773
|
-
//# sourceMappingURL=nanahoshi-mona-ui-grid-grid-toggle.component-
|
|
773
|
+
//# sourceMappingURL=nanahoshi-mona-ui-grid-grid-toggle.component-BRiY0CDX.mjs.map
|