@kouji-ui/components 0.1.5 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -771,6 +771,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImpor
|
|
|
771
771
|
* --kj-badge-dot-size — Diameter of the leading dot (when `dot` is set).
|
|
772
772
|
* --kj-badge-dot-color — Fill of the leading dot. Defaults to currentColor.
|
|
773
773
|
*
|
|
774
|
+
* Custom colours: the `bg` / `fg` / `dotColor` inputs set these variables as
|
|
775
|
+
* inline styles on the badge span, so they win over any variant or theme rule.
|
|
776
|
+
* Use for data-driven colour maps (status pills, role badges).
|
|
777
|
+
*
|
|
774
778
|
* @doc-category Library/Data display
|
|
775
779
|
* @doc
|
|
776
780
|
* @doc-name badge
|
|
@@ -783,14 +787,26 @@ class KjBadgeComponent {
|
|
|
783
787
|
size = input('md', /* @ts-ignore */
|
|
784
788
|
...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
785
789
|
dot = input(false, { ...(ngDevMode ? { debugName: "dot" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
790
|
+
/** Custom background — any CSS color/var(). Wins over the variant (inline style). Empty = variant colours. */
|
|
791
|
+
bg = input('', /* @ts-ignore */
|
|
792
|
+
...(ngDevMode ? [{ debugName: "bg" }] : /* istanbul ignore next */ []));
|
|
793
|
+
/** Custom foreground — any CSS color/var(). Wins over the variant (inline style). */
|
|
794
|
+
fg = input('', /* @ts-ignore */
|
|
795
|
+
...(ngDevMode ? [{ debugName: "fg" }] : /* istanbul ignore next */ []));
|
|
796
|
+
/** Custom dot colour (with `dot`). Defaults to currentColor via the theme. */
|
|
797
|
+
dotColor = input('', /* @ts-ignore */
|
|
798
|
+
...(ngDevMode ? [{ debugName: "dotColor" }] : /* istanbul ignore next */ []));
|
|
786
799
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: KjBadgeComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
787
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.5", type: KjBadgeComponent, isStandalone: true, selector: "kj-badge", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, dot: { classPropertyName: "dot", publicName: "dot", isSignal: true, isRequired: false, transformFunction: null } }, host: { styleAttribute: "display: contents;" }, ngImport: i0, template: `
|
|
800
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.5", type: KjBadgeComponent, isStandalone: true, selector: "kj-badge", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, dot: { classPropertyName: "dot", publicName: "dot", isSignal: true, isRequired: false, transformFunction: null }, bg: { classPropertyName: "bg", publicName: "bg", isSignal: true, isRequired: false, transformFunction: null }, fg: { classPropertyName: "fg", publicName: "fg", isSignal: true, isRequired: false, transformFunction: null }, dotColor: { classPropertyName: "dotColor", publicName: "dotColor", isSignal: true, isRequired: false, transformFunction: null } }, host: { styleAttribute: "display: contents;" }, ngImport: i0, template: `
|
|
788
801
|
<span
|
|
789
802
|
kjBadge
|
|
790
803
|
class="kj-badge"
|
|
791
804
|
[kjBadgeVariant]="variant()"
|
|
792
805
|
[kjBadgeDot]="dot()"
|
|
793
806
|
[attr.data-size]="size()"
|
|
807
|
+
[style.--kj-badge-bg]="bg() || null"
|
|
808
|
+
[style.--kj-badge-fg]="fg() || null"
|
|
809
|
+
[style.--kj-badge-dot-color]="dotColor() || null"
|
|
794
810
|
>
|
|
795
811
|
<ng-content />
|
|
796
812
|
</span>
|
|
@@ -805,11 +821,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImpor
|
|
|
805
821
|
[kjBadgeVariant]="variant()"
|
|
806
822
|
[kjBadgeDot]="dot()"
|
|
807
823
|
[attr.data-size]="size()"
|
|
824
|
+
[style.--kj-badge-bg]="bg() || null"
|
|
825
|
+
[style.--kj-badge-fg]="fg() || null"
|
|
826
|
+
[style.--kj-badge-dot-color]="dotColor() || null"
|
|
808
827
|
>
|
|
809
828
|
<ng-content />
|
|
810
829
|
</span>
|
|
811
830
|
`, encapsulation: ViewEncapsulation.None, host: { style: 'display: contents;' }, changeDetection: ChangeDetectionStrategy.OnPush, styles: ["@layer kj.component{.kj-badge{--kj-badge-bg: var(--kj-bg-primary);--kj-badge-fg: var(--kj-fg-on-primary);--kj-badge-border-color: transparent;--kj-badge-radius: var(--kj-radius-selector);--kj-badge-padding-x: var(--kj-space-sm);--kj-badge-padding-y: .125rem;--kj-badge-font-size: .75rem;--kj-badge-dot-size: .375rem;--kj-badge-dot-color: currentColor;display:inline-flex;align-items:center;gap:.25rem;background:var(--kj-badge-bg);color:var(--kj-badge-fg);border:var(--kj-border) solid var(--kj-badge-border-color);border-radius:var(--kj-badge-radius);padding:var(--kj-badge-padding-y) var(--kj-badge-padding-x);font:var(--kj-badge-font-size) / 1 var(--kj-font-sans);font-weight:500}.kj-badge[data-dot]:before{content:\"\";flex:none;width:var(--kj-badge-dot-size);height:var(--kj-badge-dot-size);border-radius:50%;background:var(--kj-badge-dot-color)}.kj-badge[data-variant=secondary]{--kj-badge-bg: var(--kj-bg-surface);--kj-badge-fg: var(--kj-fg-default)}.kj-badge[data-variant=destructive]{--kj-badge-bg: var(--kj-bg-danger);--kj-badge-fg: var(--kj-fg-on-danger)}.kj-badge[data-variant=outline]{--kj-badge-bg: transparent;--kj-badge-fg: var(--kj-fg-default);--kj-badge-border-color: var(--kj-border-default)}.kj-badge[data-size=xs]{--kj-badge-padding-x: .1875rem;--kj-badge-padding-y: .03125rem;--kj-badge-font-size: .5625rem}.kj-badge[data-size=sm]{--kj-badge-padding-x: .375rem;--kj-badge-padding-y: .125rem;--kj-badge-font-size: .6875rem}.kj-badge[data-size=lg]{--kj-badge-padding-x: var(--kj-space-md);--kj-badge-font-size: .875rem}}\n"] }]
|
|
812
|
-
}], propDecorators: { variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], dot: [{ type: i0.Input, args: [{ isSignal: true, alias: "dot", required: false }] }] } });
|
|
831
|
+
}], propDecorators: { variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], dot: [{ type: i0.Input, args: [{ isSignal: true, alias: "dot", required: false }] }], bg: [{ type: i0.Input, args: [{ isSignal: true, alias: "bg", required: false }] }], fg: [{ type: i0.Input, args: [{ isSignal: true, alias: "fg", required: false }] }], dotColor: [{ type: i0.Input, args: [{ isSignal: true, alias: "dotColor", required: false }] }] } });
|
|
813
832
|
|
|
814
833
|
/**
|
|
815
834
|
* Styled wrapper around the headless `KjBreadcrumb` directive — root of the
|
|
@@ -3548,7 +3567,7 @@ class KjDatePickerComponent {
|
|
|
3548
3567
|
/>
|
|
3549
3568
|
</div>
|
|
3550
3569
|
</div>
|
|
3551
|
-
`, isInline: true, styles: [".kj-date-picker{display:inline-flex;align-items:center;gap:var(--kj-space-xs);position:relative}.kj-date-picker__input{--kj-date-picker-input-height: 2.25rem;appearance:none;border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-field);padding:0 var(--kj-space-md);height:var(--kj-date-picker-input-height);font:inherit;background:var(--kj-bg-field);color:var(--kj-fg-default);min-width:12ch}.kj-date-picker[data-size=xs] .kj-date-picker__input{--kj-date-picker-input-height: 1.75rem;font-size:.75rem;padding-inline:var(--kj-space-sm);min-width:0}.kj-date-picker[data-size=sm] .kj-date-picker__input{--kj-date-picker-input-height: 2rem;font-size:.8125rem}.kj-date-picker[data-size=lg] .kj-date-picker__input{--kj-date-picker-input-height: 2.75rem;font-size:1rem}.kj-date-picker__input:focus{outline:2px solid var(--kj-border-focus);outline-offset:2px;border-color:var(--kj-border-focus)}.kj-date-picker__input[disabled]{opacity:.55;cursor:not-allowed}.kj-date-picker__panel{box-sizing:border-box;z-index:50;display:inline-block;background:var(--kj-bg-elevated);color:var(--kj-fg-default);border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-box);box-shadow:var(--kj-shadow-md);padding:var(--kj-space-sm)}.kj-date-picker__panel .kj-calendar{padding:0}.kj-date-picker__panel[hidden]{display:none}\n"], dependencies: [{ kind: "directive", type: KjDatePicker, selector: "[kjDatePicker]", inputs: ["kjValue", "kjMin", "kjMax", "kjDisabledDates", "kjLocale", "kjFirstDayOfWeek", "kjReadonly", "kjOpen"], outputs: ["kjValueChange", "kjOpenChange"], exportAs: ["kjDatePicker"] }, { kind: "directive", type: KjDatePickerTrigger, selector: "input[kjDatePickerTrigger]", exportAs: ["kjDatePickerTrigger"] }, { kind: "directive", type: KjDatePickerCalendar, selector: "[kjDatePickerCalendar]", inputs: ["kjSide", "kjAlign", "kjOffset"], exportAs: ["kjDatePickerCalendar"] }, { kind: "component", type: KjCalendarComponent, selector: "kj-calendar", inputs: ["kjValue", "kjMin", "kjMax", "kjDisabledDates", "kjLocale", "kjFirstDayOfWeek", "kjAriaLabel", "kjDisabled"], outputs: ["kjValueChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
3570
|
+
`, isInline: true, styles: [".kj-date-picker{display:inline-flex;align-items:center;gap:var(--kj-space-xs);position:relative}.kj-date-picker__input{--kj-date-picker-input-height: 2.25rem;appearance:none;border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-field);padding:0 var(--kj-space-md);height:var(--kj-date-picker-input-height);font:inherit;background:var(--kj-bg-field);color:var(--kj-fg-default);min-width:12ch}.kj-date-picker[data-size=xs] .kj-date-picker__input{--kj-date-picker-input-height: 1.75rem;font-size:.75rem;padding-inline:var(--kj-space-sm);min-width:0}.kj-date-picker[data-size=sm] .kj-date-picker__input{--kj-date-picker-input-height: 2rem;font-size:.8125rem}.kj-date-picker[data-size=lg] .kj-date-picker__input{--kj-date-picker-input-height: 2.75rem;font-size:1rem}.kj-date-picker__input:focus{outline:2px solid var(--kj-border-focus);outline-offset:2px;border-color:var(--kj-border-focus)}.kj-date-picker__input[disabled]{opacity:.55;cursor:not-allowed}.kj-date-picker__panel{box-sizing:border-box;z-index:50;display:inline-block;background:var(--kj-bg-elevated);color:var(--kj-fg-default);border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-box);box-shadow:var(--kj-shadow-md);padding:var(--kj-space-sm)}.kj-date-picker__panel .kj-calendar{padding:0}.kj-date-picker__panel[hidden]{display:none}\n"], dependencies: [{ kind: "directive", type: KjDatePicker, selector: "[kjDatePicker]", inputs: ["kjValue", "kjMin", "kjMax", "kjDisabledDates", "kjLocale", "kjFirstDayOfWeek", "kjReadonly", "kjOpen"], outputs: ["kjValueChange", "kjOpenChange"], exportAs: ["kjDatePicker"] }, { kind: "directive", type: KjDatePickerTrigger, selector: "input[kjDatePickerTrigger]", inputs: ["kjDisplayFormat"], exportAs: ["kjDatePickerTrigger"] }, { kind: "directive", type: KjDatePickerCalendar, selector: "[kjDatePickerCalendar]", inputs: ["kjSide", "kjAlign", "kjOffset"], exportAs: ["kjDatePickerCalendar"] }, { kind: "component", type: KjCalendarComponent, selector: "kj-calendar", inputs: ["kjValue", "kjMin", "kjMax", "kjDisabledDates", "kjLocale", "kjFirstDayOfWeek", "kjAriaLabel", "kjDisabled"], outputs: ["kjValueChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
3552
3571
|
}
|
|
3553
3572
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: KjDatePickerComponent, decorators: [{
|
|
3554
3573
|
type: Component,
|
|
@@ -3599,6 +3618,209 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImpor
|
|
|
3599
3618
|
`, encapsulation: ViewEncapsulation.None, host: { class: 'kj-date-picker-host', style: 'display: contents;' }, changeDetection: ChangeDetectionStrategy.OnPush, styles: [".kj-date-picker{display:inline-flex;align-items:center;gap:var(--kj-space-xs);position:relative}.kj-date-picker__input{--kj-date-picker-input-height: 2.25rem;appearance:none;border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-field);padding:0 var(--kj-space-md);height:var(--kj-date-picker-input-height);font:inherit;background:var(--kj-bg-field);color:var(--kj-fg-default);min-width:12ch}.kj-date-picker[data-size=xs] .kj-date-picker__input{--kj-date-picker-input-height: 1.75rem;font-size:.75rem;padding-inline:var(--kj-space-sm);min-width:0}.kj-date-picker[data-size=sm] .kj-date-picker__input{--kj-date-picker-input-height: 2rem;font-size:.8125rem}.kj-date-picker[data-size=lg] .kj-date-picker__input{--kj-date-picker-input-height: 2.75rem;font-size:1rem}.kj-date-picker__input:focus{outline:2px solid var(--kj-border-focus);outline-offset:2px;border-color:var(--kj-border-focus)}.kj-date-picker__input[disabled]{opacity:.55;cursor:not-allowed}.kj-date-picker__panel{box-sizing:border-box;z-index:50;display:inline-block;background:var(--kj-bg-elevated);color:var(--kj-fg-default);border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-box);box-shadow:var(--kj-shadow-md);padding:var(--kj-space-sm)}.kj-date-picker__panel .kj-calendar{padding:0}.kj-date-picker__panel[hidden]{display:none}\n"] }]
|
|
3600
3619
|
}], propDecorators: { kjValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjValue", required: false }] }, { type: i0.Output, args: ["kjValueChange"] }], kjOpen: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjOpen", required: false }] }, { type: i0.Output, args: ["kjOpenChange"] }], kjMin: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjMin", required: false }] }], kjMax: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjMax", required: false }] }], kjDisabledDates: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjDisabledDates", required: false }] }], kjLocale: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjLocale", required: false }] }], kjFirstDayOfWeek: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjFirstDayOfWeek", required: false }] }], kjPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjPlaceholder", required: false }] }], kjReadonly: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjReadonly", required: false }] }], kjDisabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjDisabled", required: false }] }], kjSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjSize", required: false }] }] } });
|
|
3601
3620
|
|
|
3621
|
+
/** Format a Date as a locale short date + HH:mm time. */
|
|
3622
|
+
function formatDateTime(d, locale) {
|
|
3623
|
+
const date = new Intl.DateTimeFormat(locale || undefined, { dateStyle: 'short' }).format(d);
|
|
3624
|
+
const time = new Intl.DateTimeFormat(locale || undefined, { hour: '2-digit', minute: '2-digit', hour12: false }).format(d);
|
|
3625
|
+
return date + ' ' + time;
|
|
3626
|
+
}
|
|
3627
|
+
/** "HH:mm" for the panel's time input. */
|
|
3628
|
+
function toTimeString(d) {
|
|
3629
|
+
if (!d)
|
|
3630
|
+
return '';
|
|
3631
|
+
const hh = String(d.getHours()).padStart(2, '0');
|
|
3632
|
+
const mm = String(d.getMinutes()).padStart(2, '0');
|
|
3633
|
+
return hh + ':' + mm;
|
|
3634
|
+
}
|
|
3635
|
+
/**
|
|
3636
|
+
* Themed datetime picker — the date-picker's calendar popover plus a time
|
|
3637
|
+
* field in the panel. Value is a single native `Date` carrying both parts.
|
|
3638
|
+
*
|
|
3639
|
+
* Unlike `kj-date-picker`, selecting a calendar day keeps the panel open so
|
|
3640
|
+
* the time can be adjusted; the day merge preserves the current time-of-day
|
|
3641
|
+
* (defaults to 09:00 for a fresh value). Close with Escape or by clicking
|
|
3642
|
+
* outside.
|
|
3643
|
+
*
|
|
3644
|
+
* @doc-example Default
|
|
3645
|
+
* Pick a meeting date and time — a single `Date` two-way binding.
|
|
3646
|
+
* @doc-file datetime-picker.example.ts
|
|
3647
|
+
*
|
|
3648
|
+
* @doc-keyboard
|
|
3649
|
+
* Enter|ArrowDown — Opens the calendar popover from the trigger
|
|
3650
|
+
* Escape — Closes the popover and returns focus to the trigger
|
|
3651
|
+
*
|
|
3652
|
+
* @doc-css-var
|
|
3653
|
+
* --kj-datetime-picker-input-height — Height of the trigger input. Sizes override.
|
|
3654
|
+
*
|
|
3655
|
+
* @doc-related date-picker,calendar,time-picker
|
|
3656
|
+
*
|
|
3657
|
+
* @doc-category Library/Data input
|
|
3658
|
+
* @doc
|
|
3659
|
+
* @doc-name datetime-picker
|
|
3660
|
+
* @doc-description Themed date + time picker sharing one native Date value; calendar popover with a time field.
|
|
3661
|
+
* @doc-is-main
|
|
3662
|
+
*/
|
|
3663
|
+
class KjDatetimePickerComponent {
|
|
3664
|
+
/** Selected date + time. Two-way bindable — `[(kjValue)]`. `null` clears. */
|
|
3665
|
+
kjValue = model(null, /* @ts-ignore */
|
|
3666
|
+
...(ngDevMode ? [{ debugName: "kjValue" }] : /* istanbul ignore next */ []));
|
|
3667
|
+
/** Two-way bindable open state for the popover. */
|
|
3668
|
+
kjOpen = model(false, /* @ts-ignore */
|
|
3669
|
+
...(ngDevMode ? [{ debugName: "kjOpen" }] : /* istanbul ignore next */ []));
|
|
3670
|
+
/** Earliest selectable date (inclusive). */
|
|
3671
|
+
kjMin = input(null, /* @ts-ignore */
|
|
3672
|
+
...(ngDevMode ? [{ debugName: "kjMin" }] : /* istanbul ignore next */ []));
|
|
3673
|
+
/** Latest selectable date (inclusive). */
|
|
3674
|
+
kjMax = input(null, /* @ts-ignore */
|
|
3675
|
+
...(ngDevMode ? [{ debugName: "kjMax" }] : /* istanbul ignore next */ []));
|
|
3676
|
+
/** BCP-47 locale tag. Defaults to Angular's `LOCALE_ID`. */
|
|
3677
|
+
kjLocale = input('', /* @ts-ignore */
|
|
3678
|
+
...(ngDevMode ? [{ debugName: "kjLocale" }] : /* istanbul ignore next */ []));
|
|
3679
|
+
/** First day of the week override (0=Sun … 6=Sat). */
|
|
3680
|
+
kjFirstDayOfWeek = input(null, /* @ts-ignore */
|
|
3681
|
+
...(ngDevMode ? [{ debugName: "kjFirstDayOfWeek" }] : /* istanbul ignore next */ []));
|
|
3682
|
+
/** Placeholder text for the trigger input. */
|
|
3683
|
+
kjPlaceholder = input('', /* @ts-ignore */
|
|
3684
|
+
...(ngDevMode ? [{ debugName: "kjPlaceholder" }] : /* istanbul ignore next */ []));
|
|
3685
|
+
/** Label for the time row inside the panel. */
|
|
3686
|
+
kjTimeLabel = input('Time', /* @ts-ignore */
|
|
3687
|
+
...(ngDevMode ? [{ debugName: "kjTimeLabel" }] : /* istanbul ignore next */ []));
|
|
3688
|
+
/** Hour used when a day is picked on a previously-empty value. */
|
|
3689
|
+
kjDefaultHour = input(9, /* @ts-ignore */
|
|
3690
|
+
...(ngDevMode ? [{ debugName: "kjDefaultHour" }] : /* istanbul ignore next */ []));
|
|
3691
|
+
kjReadonly = input(false, { ...(ngDevMode ? { debugName: "kjReadonly" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
3692
|
+
kjDisabled = input(false, { ...(ngDevMode ? { debugName: "kjDisabled" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
3693
|
+
/** Size preset for the trigger input. */
|
|
3694
|
+
kjSize = input('md', /* @ts-ignore */
|
|
3695
|
+
...(ngDevMode ? [{ debugName: "kjSize" }] : /* istanbul ignore next */ []));
|
|
3696
|
+
/** Trigger display: locale short date + HH:mm. */
|
|
3697
|
+
displayFormat = formatDateTime;
|
|
3698
|
+
timeText = computed(() => toTimeString(this.kjValue()), /* @ts-ignore */
|
|
3699
|
+
...(ngDevMode ? [{ debugName: "timeText" }] : /* istanbul ignore next */ []));
|
|
3700
|
+
/** Merge the picked day into the value, preserving time-of-day. Keeps the
|
|
3701
|
+
* panel open so the time can be adjusted next. */
|
|
3702
|
+
onCalendarSelect(day) {
|
|
3703
|
+
if (!day) {
|
|
3704
|
+
this.kjValue.set(null);
|
|
3705
|
+
return;
|
|
3706
|
+
}
|
|
3707
|
+
const prev = this.kjValue();
|
|
3708
|
+
const next = new Date(day);
|
|
3709
|
+
if (prev) {
|
|
3710
|
+
next.setHours(prev.getHours(), prev.getMinutes(), 0, 0);
|
|
3711
|
+
}
|
|
3712
|
+
else {
|
|
3713
|
+
next.setHours(this.kjDefaultHour(), 0, 0, 0);
|
|
3714
|
+
}
|
|
3715
|
+
this.kjValue.set(next);
|
|
3716
|
+
}
|
|
3717
|
+
/** Merge an "HH:mm" time into the value, preserving the date part. */
|
|
3718
|
+
onTimeInput(event) {
|
|
3719
|
+
const raw = event.target.value;
|
|
3720
|
+
const match = /^(\d{2}):(\d{2})$/.exec(raw);
|
|
3721
|
+
if (!match)
|
|
3722
|
+
return;
|
|
3723
|
+
const base = this.kjValue() ?? new Date();
|
|
3724
|
+
const next = new Date(base);
|
|
3725
|
+
next.setHours(Number(match[1]), Number(match[2]), 0, 0);
|
|
3726
|
+
this.kjValue.set(next);
|
|
3727
|
+
}
|
|
3728
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: KjDatetimePickerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
3729
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.5", type: KjDatetimePickerComponent, isStandalone: true, selector: "kj-datetime-picker", inputs: { kjValue: { classPropertyName: "kjValue", publicName: "kjValue", isSignal: true, isRequired: false, transformFunction: null }, kjOpen: { classPropertyName: "kjOpen", publicName: "kjOpen", isSignal: true, isRequired: false, transformFunction: null }, kjMin: { classPropertyName: "kjMin", publicName: "kjMin", isSignal: true, isRequired: false, transformFunction: null }, kjMax: { classPropertyName: "kjMax", publicName: "kjMax", isSignal: true, isRequired: false, transformFunction: null }, kjLocale: { classPropertyName: "kjLocale", publicName: "kjLocale", isSignal: true, isRequired: false, transformFunction: null }, kjFirstDayOfWeek: { classPropertyName: "kjFirstDayOfWeek", publicName: "kjFirstDayOfWeek", isSignal: true, isRequired: false, transformFunction: null }, kjPlaceholder: { classPropertyName: "kjPlaceholder", publicName: "kjPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, kjTimeLabel: { classPropertyName: "kjTimeLabel", publicName: "kjTimeLabel", isSignal: true, isRequired: false, transformFunction: null }, kjDefaultHour: { classPropertyName: "kjDefaultHour", publicName: "kjDefaultHour", isSignal: true, isRequired: false, transformFunction: null }, kjReadonly: { classPropertyName: "kjReadonly", publicName: "kjReadonly", isSignal: true, isRequired: false, transformFunction: null }, kjDisabled: { classPropertyName: "kjDisabled", publicName: "kjDisabled", isSignal: true, isRequired: false, transformFunction: null }, kjSize: { classPropertyName: "kjSize", publicName: "kjSize", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { kjValue: "kjValueChange", kjOpen: "kjOpenChange" }, host: { styleAttribute: "display: contents;", classAttribute: "kj-datetime-picker-host" }, ngImport: i0, template: `
|
|
3730
|
+
<div
|
|
3731
|
+
kjDatePicker
|
|
3732
|
+
class="kj-datetime-picker"
|
|
3733
|
+
#picker="kjDatePicker"
|
|
3734
|
+
[attr.data-size]="kjSize() === 'md' ? null : kjSize()"
|
|
3735
|
+
[kjValue]="kjValue() ?? null!"
|
|
3736
|
+
(kjValueChange)="kjValue.set($event)"
|
|
3737
|
+
[(kjOpen)]="kjOpen"
|
|
3738
|
+
[kjMin]="kjMin() ?? null!"
|
|
3739
|
+
[kjMax]="kjMax() ?? null!"
|
|
3740
|
+
[kjLocale]="kjLocale()"
|
|
3741
|
+
[kjFirstDayOfWeek]="kjFirstDayOfWeek() ?? 0"
|
|
3742
|
+
[kjReadonly]="kjReadonly()"
|
|
3743
|
+
[kjDisabled]="kjDisabled()"
|
|
3744
|
+
>
|
|
3745
|
+
<input
|
|
3746
|
+
kjDatePickerTrigger
|
|
3747
|
+
#trig="kjDatePickerTrigger"
|
|
3748
|
+
class="kj-datetime-picker__input"
|
|
3749
|
+
[kjDisplayFormat]="displayFormat"
|
|
3750
|
+
[placeholder]="kjPlaceholder()"
|
|
3751
|
+
/>
|
|
3752
|
+
<div kjDatePickerCalendar [kjFor]="trig" class="kj-datetime-picker__panel">
|
|
3753
|
+
<kj-calendar
|
|
3754
|
+
[kjValue]="kjValue()"
|
|
3755
|
+
[kjMin]="kjMin()"
|
|
3756
|
+
[kjMax]="kjMax()"
|
|
3757
|
+
[kjLocale]="kjLocale()"
|
|
3758
|
+
[kjFirstDayOfWeek]="kjFirstDayOfWeek() ?? 0"
|
|
3759
|
+
(kjValueChange)="onCalendarSelect($event)"
|
|
3760
|
+
/>
|
|
3761
|
+
<label class="kj-datetime-picker__time">
|
|
3762
|
+
<span class="kj-datetime-picker__time-label">{{ kjTimeLabel() }}</span>
|
|
3763
|
+
<input
|
|
3764
|
+
type="time"
|
|
3765
|
+
class="kj-datetime-picker__time-input"
|
|
3766
|
+
[value]="timeText()"
|
|
3767
|
+
[disabled]="kjDisabled()"
|
|
3768
|
+
(change)="onTimeInput($event)"
|
|
3769
|
+
/>
|
|
3770
|
+
</label>
|
|
3771
|
+
</div>
|
|
3772
|
+
</div>
|
|
3773
|
+
`, isInline: true, styles: [".kj-datetime-picker{display:inline-flex;align-items:center;gap:var(--kj-space-xs);position:relative}.kj-datetime-picker__input{--kj-datetime-picker-input-height: 2.25rem;appearance:none;border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-field);padding:0 var(--kj-space-md);height:var(--kj-datetime-picker-input-height);font:inherit;background:var(--kj-bg-field);color:var(--kj-fg-default);width:19ch;min-width:0}.kj-datetime-picker[data-size=xs] .kj-datetime-picker__input{--kj-datetime-picker-input-height: 1.75rem;font-size:.75rem;padding-inline:var(--kj-space-sm);min-width:0}.kj-datetime-picker[data-size=sm] .kj-datetime-picker__input{--kj-datetime-picker-input-height: 2rem;font-size:.8125rem}.kj-datetime-picker[data-size=lg] .kj-datetime-picker__input{--kj-datetime-picker-input-height: 2.75rem;font-size:1rem}.kj-datetime-picker__input:focus{outline:2px solid var(--kj-border-focus);outline-offset:2px;border-color:var(--kj-border-focus)}.kj-datetime-picker__input[disabled]{opacity:.55;cursor:not-allowed}.kj-datetime-picker__panel{box-sizing:border-box;z-index:50;display:inline-block;background:var(--kj-bg-elevated);color:var(--kj-fg-default);border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-box);box-shadow:var(--kj-shadow-md);padding:var(--kj-space-sm)}.kj-datetime-picker__panel .kj-calendar{padding:0}.kj-datetime-picker__panel[hidden]{display:none}.kj-datetime-picker__time{display:flex;align-items:center;justify-content:space-between;gap:var(--kj-space-sm);margin-top:var(--kj-space-sm);padding:var(--kj-space-sm) var(--kj-space-xs) 0;border-top:var(--kj-border) solid var(--kj-border-muted);font-size:.8125rem;color:var(--kj-fg-muted)}.kj-datetime-picker__time-input{appearance:none;border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-field);background:var(--kj-bg-field);color:var(--kj-fg-default);font:inherit;font-size:.8125rem;padding:2px var(--kj-space-sm)}.kj-datetime-picker__time-input:focus{outline:2px solid var(--kj-border-focus);outline-offset:1px}\n"], dependencies: [{ kind: "directive", type: KjDatePicker, selector: "[kjDatePicker]", inputs: ["kjValue", "kjMin", "kjMax", "kjDisabledDates", "kjLocale", "kjFirstDayOfWeek", "kjReadonly", "kjOpen"], outputs: ["kjValueChange", "kjOpenChange"], exportAs: ["kjDatePicker"] }, { kind: "directive", type: KjDatePickerTrigger, selector: "input[kjDatePickerTrigger]", inputs: ["kjDisplayFormat"], exportAs: ["kjDatePickerTrigger"] }, { kind: "directive", type: KjDatePickerCalendar, selector: "[kjDatePickerCalendar]", inputs: ["kjSide", "kjAlign", "kjOffset"], exportAs: ["kjDatePickerCalendar"] }, { kind: "component", type: KjCalendarComponent, selector: "kj-calendar", inputs: ["kjValue", "kjMin", "kjMax", "kjDisabledDates", "kjLocale", "kjFirstDayOfWeek", "kjAriaLabel", "kjDisabled"], outputs: ["kjValueChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
3774
|
+
}
|
|
3775
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: KjDatetimePickerComponent, decorators: [{
|
|
3776
|
+
type: Component,
|
|
3777
|
+
args: [{ selector: 'kj-datetime-picker', standalone: true, imports: [KjDatePicker, KjDatePickerTrigger, KjDatePickerCalendar, KjCalendarComponent], template: `
|
|
3778
|
+
<div
|
|
3779
|
+
kjDatePicker
|
|
3780
|
+
class="kj-datetime-picker"
|
|
3781
|
+
#picker="kjDatePicker"
|
|
3782
|
+
[attr.data-size]="kjSize() === 'md' ? null : kjSize()"
|
|
3783
|
+
[kjValue]="kjValue() ?? null!"
|
|
3784
|
+
(kjValueChange)="kjValue.set($event)"
|
|
3785
|
+
[(kjOpen)]="kjOpen"
|
|
3786
|
+
[kjMin]="kjMin() ?? null!"
|
|
3787
|
+
[kjMax]="kjMax() ?? null!"
|
|
3788
|
+
[kjLocale]="kjLocale()"
|
|
3789
|
+
[kjFirstDayOfWeek]="kjFirstDayOfWeek() ?? 0"
|
|
3790
|
+
[kjReadonly]="kjReadonly()"
|
|
3791
|
+
[kjDisabled]="kjDisabled()"
|
|
3792
|
+
>
|
|
3793
|
+
<input
|
|
3794
|
+
kjDatePickerTrigger
|
|
3795
|
+
#trig="kjDatePickerTrigger"
|
|
3796
|
+
class="kj-datetime-picker__input"
|
|
3797
|
+
[kjDisplayFormat]="displayFormat"
|
|
3798
|
+
[placeholder]="kjPlaceholder()"
|
|
3799
|
+
/>
|
|
3800
|
+
<div kjDatePickerCalendar [kjFor]="trig" class="kj-datetime-picker__panel">
|
|
3801
|
+
<kj-calendar
|
|
3802
|
+
[kjValue]="kjValue()"
|
|
3803
|
+
[kjMin]="kjMin()"
|
|
3804
|
+
[kjMax]="kjMax()"
|
|
3805
|
+
[kjLocale]="kjLocale()"
|
|
3806
|
+
[kjFirstDayOfWeek]="kjFirstDayOfWeek() ?? 0"
|
|
3807
|
+
(kjValueChange)="onCalendarSelect($event)"
|
|
3808
|
+
/>
|
|
3809
|
+
<label class="kj-datetime-picker__time">
|
|
3810
|
+
<span class="kj-datetime-picker__time-label">{{ kjTimeLabel() }}</span>
|
|
3811
|
+
<input
|
|
3812
|
+
type="time"
|
|
3813
|
+
class="kj-datetime-picker__time-input"
|
|
3814
|
+
[value]="timeText()"
|
|
3815
|
+
[disabled]="kjDisabled()"
|
|
3816
|
+
(change)="onTimeInput($event)"
|
|
3817
|
+
/>
|
|
3818
|
+
</label>
|
|
3819
|
+
</div>
|
|
3820
|
+
</div>
|
|
3821
|
+
`, encapsulation: ViewEncapsulation.None, host: { class: 'kj-datetime-picker-host', style: 'display: contents;' }, changeDetection: ChangeDetectionStrategy.OnPush, styles: [".kj-datetime-picker{display:inline-flex;align-items:center;gap:var(--kj-space-xs);position:relative}.kj-datetime-picker__input{--kj-datetime-picker-input-height: 2.25rem;appearance:none;border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-field);padding:0 var(--kj-space-md);height:var(--kj-datetime-picker-input-height);font:inherit;background:var(--kj-bg-field);color:var(--kj-fg-default);width:19ch;min-width:0}.kj-datetime-picker[data-size=xs] .kj-datetime-picker__input{--kj-datetime-picker-input-height: 1.75rem;font-size:.75rem;padding-inline:var(--kj-space-sm);min-width:0}.kj-datetime-picker[data-size=sm] .kj-datetime-picker__input{--kj-datetime-picker-input-height: 2rem;font-size:.8125rem}.kj-datetime-picker[data-size=lg] .kj-datetime-picker__input{--kj-datetime-picker-input-height: 2.75rem;font-size:1rem}.kj-datetime-picker__input:focus{outline:2px solid var(--kj-border-focus);outline-offset:2px;border-color:var(--kj-border-focus)}.kj-datetime-picker__input[disabled]{opacity:.55;cursor:not-allowed}.kj-datetime-picker__panel{box-sizing:border-box;z-index:50;display:inline-block;background:var(--kj-bg-elevated);color:var(--kj-fg-default);border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-box);box-shadow:var(--kj-shadow-md);padding:var(--kj-space-sm)}.kj-datetime-picker__panel .kj-calendar{padding:0}.kj-datetime-picker__panel[hidden]{display:none}.kj-datetime-picker__time{display:flex;align-items:center;justify-content:space-between;gap:var(--kj-space-sm);margin-top:var(--kj-space-sm);padding:var(--kj-space-sm) var(--kj-space-xs) 0;border-top:var(--kj-border) solid var(--kj-border-muted);font-size:.8125rem;color:var(--kj-fg-muted)}.kj-datetime-picker__time-input{appearance:none;border:var(--kj-border) solid var(--kj-border-default);border-radius:var(--kj-radius-field);background:var(--kj-bg-field);color:var(--kj-fg-default);font:inherit;font-size:.8125rem;padding:2px var(--kj-space-sm)}.kj-datetime-picker__time-input:focus{outline:2px solid var(--kj-border-focus);outline-offset:1px}\n"] }]
|
|
3822
|
+
}], propDecorators: { kjValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjValue", required: false }] }, { type: i0.Output, args: ["kjValueChange"] }], kjOpen: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjOpen", required: false }] }, { type: i0.Output, args: ["kjOpenChange"] }], kjMin: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjMin", required: false }] }], kjMax: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjMax", required: false }] }], kjLocale: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjLocale", required: false }] }], kjFirstDayOfWeek: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjFirstDayOfWeek", required: false }] }], kjPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjPlaceholder", required: false }] }], kjTimeLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjTimeLabel", required: false }] }], kjDefaultHour: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjDefaultHour", required: false }] }], kjReadonly: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjReadonly", required: false }] }], kjDisabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjDisabled", required: false }] }], kjSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjSize", required: false }] }] } });
|
|
3823
|
+
|
|
3602
3824
|
/**
|
|
3603
3825
|
* Service-launched modal dialog. Inject `KjDialogService` and call `open()`
|
|
3604
3826
|
* with a template; mount `[kjDialog]` once near your trigger to host the
|
|
@@ -11994,6 +12216,45 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImpor
|
|
|
11994
12216
|
}]
|
|
11995
12217
|
}], ctorParameters: () => [], propDecorators: { kjCount: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjCount", required: true }] }], kjEstimateSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjEstimateSize", required: false }] }], kjOverscan: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjOverscan", required: false }] }] } });
|
|
11996
12218
|
|
|
12219
|
+
/**
|
|
12220
|
+
* Registers a custom cell template for one column of a `<kj-table>`.
|
|
12221
|
+
*
|
|
12222
|
+
* Declare inside the table's content with the column id, and use the template
|
|
12223
|
+
* context to render arbitrary markup (badges, buttons, avatars…) instead of
|
|
12224
|
+
* the default `getValue()` text:
|
|
12225
|
+
*
|
|
12226
|
+
* ```html
|
|
12227
|
+
* <kj-table [kjData]="rows()" [kjColumns]="cols">
|
|
12228
|
+
* <ng-template kjCellTemplate="role" let-row let-value="value">
|
|
12229
|
+
* <kj-badge [bg]="roleBg(row.role)">{{ value }}</kj-badge>
|
|
12230
|
+
* </ng-template>
|
|
12231
|
+
* </kj-table>
|
|
12232
|
+
* ```
|
|
12233
|
+
*
|
|
12234
|
+
* Context: `$implicit` / `row` — the row data; `value` — `cell.getValue()`;
|
|
12235
|
+
* `cell` — the TanStack cell instance.
|
|
12236
|
+
*
|
|
12237
|
+
* Editing, grouping, and aggregation cells keep their built-in rendering;
|
|
12238
|
+
* the template applies to plain data cells only.
|
|
12239
|
+
*
|
|
12240
|
+
* @doc-category Library/Data display
|
|
12241
|
+
* @doc
|
|
12242
|
+
* @doc-name table
|
|
12243
|
+
*/
|
|
12244
|
+
class KjCellTemplateDirective {
|
|
12245
|
+
/** Column id this template renders. */
|
|
12246
|
+
kjCellTemplate = input.required(/* @ts-ignore */
|
|
12247
|
+
...(ngDevMode ? [{ debugName: "kjCellTemplate" }] : /* istanbul ignore next */ []));
|
|
12248
|
+
/** @internal */
|
|
12249
|
+
template = inject(TemplateRef);
|
|
12250
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: KjCellTemplateDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
12251
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.0.5", type: KjCellTemplateDirective, isStandalone: true, selector: "ng-template[kjCellTemplate]", inputs: { kjCellTemplate: { classPropertyName: "kjCellTemplate", publicName: "kjCellTemplate", isSignal: true, isRequired: true, transformFunction: null } }, ngImport: i0 });
|
|
12252
|
+
}
|
|
12253
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: KjCellTemplateDirective, decorators: [{
|
|
12254
|
+
type: Directive,
|
|
12255
|
+
args: [{ selector: 'ng-template[kjCellTemplate]', standalone: true }]
|
|
12256
|
+
}], propDecorators: { kjCellTemplate: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjCellTemplate", required: true }] }] } });
|
|
12257
|
+
|
|
11997
12258
|
/**
|
|
11998
12259
|
* Inline text cell editor for `<kj-table>`. Renders the styled
|
|
11999
12260
|
* `<kj-input>` component (which wraps the headless `kjInput` directive and
|
|
@@ -13515,6 +13776,17 @@ class KjTableComponent {
|
|
|
13515
13776
|
/** Template for master-detail row expansion. Receives `$implicit = row`. */
|
|
13516
13777
|
kjRowExpansionTpl = contentChild('kjRowExpansion', /* @ts-ignore */
|
|
13517
13778
|
...(ngDevMode ? [{ debugName: "kjRowExpansionTpl" }] : /* istanbul ignore next */ []));
|
|
13779
|
+
/** Custom cell templates declared as `ng-template[kjCellTemplate]` content. */
|
|
13780
|
+
cellTemplates = contentChildren(KjCellTemplateDirective, /* @ts-ignore */
|
|
13781
|
+
...(ngDevMode ? [{ debugName: "cellTemplates" }] : /* istanbul ignore next */ []));
|
|
13782
|
+
/** Resolve the registered template for a cell's column, if any. */
|
|
13783
|
+
cellTpl(cell) {
|
|
13784
|
+
for (const t of this.cellTemplates()) {
|
|
13785
|
+
if (t.kjCellTemplate() === cell.column.id)
|
|
13786
|
+
return t.template;
|
|
13787
|
+
}
|
|
13788
|
+
return null;
|
|
13789
|
+
}
|
|
13518
13790
|
// ── Outputs ─────────────────────────────────────────────────────────────
|
|
13519
13791
|
cellEdit = output();
|
|
13520
13792
|
stateChange = output();
|
|
@@ -13928,7 +14200,7 @@ class KjTableComponent {
|
|
|
13928
14200
|
this.editingCell.set(null);
|
|
13929
14201
|
}
|
|
13930
14202
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: KjTableComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
13931
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: KjTableComponent, isStandalone: true, selector: "kj-table", inputs: { kjResource: { classPropertyName: "kjResource", publicName: "kjResource", isSignal: true, isRequired: false, transformFunction: null }, kjDensity: { classPropertyName: "kjDensity", publicName: "kjDensity", isSignal: true, isRequired: false, transformFunction: null }, kjVariant: { classPropertyName: "kjVariant", publicName: "kjVariant", isSignal: true, isRequired: false, transformFunction: null }, kjLoading: { classPropertyName: "kjLoading", publicName: "kjLoading", isSignal: true, isRequired: false, transformFunction: null }, kjSelection: { classPropertyName: "kjSelection", publicName: "kjSelection", isSignal: true, isRequired: false, transformFunction: null }, kjSelectionMode: { classPropertyName: "kjSelectionMode", publicName: "kjSelectionMode", isSignal: true, isRequired: false, transformFunction: null }, kjShowSelectionColumn: { classPropertyName: "kjShowSelectionColumn", publicName: "kjShowSelectionColumn", isSignal: true, isRequired: false, transformFunction: null }, kjStorageKey: { classPropertyName: "kjStorageKey", publicName: "kjStorageKey", isSignal: true, isRequired: false, transformFunction: null }, kjStorageAdapter: { classPropertyName: "kjStorageAdapter", publicName: "kjStorageAdapter", isSignal: true, isRequired: false, transformFunction: null }, kjVirtual: { classPropertyName: "kjVirtual", publicName: "kjVirtual", isSignal: true, isRequired: false, transformFunction: null }, kjEstimatedRowSize: { classPropertyName: "kjEstimatedRowSize", publicName: "kjEstimatedRowSize", isSignal: true, isRequired: false, transformFunction: null }, kjEnableFilters: { classPropertyName: "kjEnableFilters", publicName: "kjEnableFilters", isSignal: true, isRequired: false, transformFunction: null }, kjEnableResize: { classPropertyName: "kjEnableResize", publicName: "kjEnableResize", isSignal: true, isRequired: false, transformFunction: null }, kjEnableRowPinning: { classPropertyName: "kjEnableRowPinning", publicName: "kjEnableRowPinning", isSignal: true, isRequired: false, transformFunction: null }, kjEditOnDoubleClick: { classPropertyName: "kjEditOnDoubleClick", publicName: "kjEditOnDoubleClick", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { kjSelection: "kjSelectionChange", cellEdit: "cellEdit", stateChange: "stateChange", rowClick: "rowClick", rowDoubleClick: "rowDoubleClick" }, host: { properties: { "attr.data-density": "t.state.density()", "attr.data-variant": "kjVariant()", "attr.data-loading": "isLoading() ? \"\" : null", "attr.data-error": "hasError() ? \"\" : null" } }, queries: [{ propertyName: "kjRowExpansionTpl", first: true, predicate: ["kjRowExpansion"], descendants: true, isSignal: true }], hostDirectives: [{ directive: i1.KjTable, inputs: ["kjTable", "kjColumns", "kjTableData", "kjData", "kjGetRowId", "kjGetRowId"] }], ngImport: i0, template: `
|
|
14203
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.5", type: KjTableComponent, isStandalone: true, selector: "kj-table", inputs: { kjResource: { classPropertyName: "kjResource", publicName: "kjResource", isSignal: true, isRequired: false, transformFunction: null }, kjDensity: { classPropertyName: "kjDensity", publicName: "kjDensity", isSignal: true, isRequired: false, transformFunction: null }, kjVariant: { classPropertyName: "kjVariant", publicName: "kjVariant", isSignal: true, isRequired: false, transformFunction: null }, kjLoading: { classPropertyName: "kjLoading", publicName: "kjLoading", isSignal: true, isRequired: false, transformFunction: null }, kjSelection: { classPropertyName: "kjSelection", publicName: "kjSelection", isSignal: true, isRequired: false, transformFunction: null }, kjSelectionMode: { classPropertyName: "kjSelectionMode", publicName: "kjSelectionMode", isSignal: true, isRequired: false, transformFunction: null }, kjShowSelectionColumn: { classPropertyName: "kjShowSelectionColumn", publicName: "kjShowSelectionColumn", isSignal: true, isRequired: false, transformFunction: null }, kjStorageKey: { classPropertyName: "kjStorageKey", publicName: "kjStorageKey", isSignal: true, isRequired: false, transformFunction: null }, kjStorageAdapter: { classPropertyName: "kjStorageAdapter", publicName: "kjStorageAdapter", isSignal: true, isRequired: false, transformFunction: null }, kjVirtual: { classPropertyName: "kjVirtual", publicName: "kjVirtual", isSignal: true, isRequired: false, transformFunction: null }, kjEstimatedRowSize: { classPropertyName: "kjEstimatedRowSize", publicName: "kjEstimatedRowSize", isSignal: true, isRequired: false, transformFunction: null }, kjEnableFilters: { classPropertyName: "kjEnableFilters", publicName: "kjEnableFilters", isSignal: true, isRequired: false, transformFunction: null }, kjEnableResize: { classPropertyName: "kjEnableResize", publicName: "kjEnableResize", isSignal: true, isRequired: false, transformFunction: null }, kjEnableRowPinning: { classPropertyName: "kjEnableRowPinning", publicName: "kjEnableRowPinning", isSignal: true, isRequired: false, transformFunction: null }, kjEditOnDoubleClick: { classPropertyName: "kjEditOnDoubleClick", publicName: "kjEditOnDoubleClick", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { kjSelection: "kjSelectionChange", cellEdit: "cellEdit", stateChange: "stateChange", rowClick: "rowClick", rowDoubleClick: "rowDoubleClick" }, host: { properties: { "attr.data-density": "t.state.density()", "attr.data-variant": "kjVariant()", "attr.data-loading": "isLoading() ? \"\" : null", "attr.data-error": "hasError() ? \"\" : null" } }, queries: [{ propertyName: "kjRowExpansionTpl", first: true, predicate: ["kjRowExpansion"], descendants: true, isSignal: true }, { propertyName: "cellTemplates", predicate: KjCellTemplateDirective, isSignal: true }], hostDirectives: [{ directive: i1.KjTable, inputs: ["kjTable", "kjColumns", "kjTableData", "kjData", "kjGetRowId", "kjGetRowId"] }], ngImport: i0, template: `
|
|
13932
14204
|
<div class="kj-table-wrapper">
|
|
13933
14205
|
<!-- Toolbar projection: matches either an explicit [kjToolbar] marker
|
|
13934
14206
|
OR the styled <kj-table-toolbar> element directly, so users don't
|
|
@@ -14046,7 +14318,11 @@ class KjTableComponent {
|
|
|
14046
14318
|
(editCancel)="onEditorCancel()"
|
|
14047
14319
|
></span>
|
|
14048
14320
|
} @else {
|
|
14049
|
-
|
|
14321
|
+
@if (cellTpl(c); as tpl) {
|
|
14322
|
+
<ng-container [ngTemplateOutlet]="tpl" [ngTemplateOutletContext]="{ $implicit: r.original, row: r.original, value: c.getValue(), cell: c }" />
|
|
14323
|
+
} @else {
|
|
14324
|
+
{{ c.getValue() }}
|
|
14325
|
+
}
|
|
14050
14326
|
}
|
|
14051
14327
|
</td>
|
|
14052
14328
|
}
|
|
@@ -14102,7 +14378,11 @@ class KjTableComponent {
|
|
|
14102
14378
|
(editCancel)="onEditorCancel()"
|
|
14103
14379
|
></span>
|
|
14104
14380
|
} @else {
|
|
14105
|
-
|
|
14381
|
+
@if (cellTpl(c); as tpl) {
|
|
14382
|
+
<ng-container [ngTemplateOutlet]="tpl" [ngTemplateOutletContext]="{ $implicit: r.original, row: r.original, value: c.getValue(), cell: c }" />
|
|
14383
|
+
} @else {
|
|
14384
|
+
{{ c.getValue() }}
|
|
14385
|
+
}
|
|
14106
14386
|
}
|
|
14107
14387
|
</td>
|
|
14108
14388
|
}
|
|
@@ -14174,7 +14454,11 @@ class KjTableComponent {
|
|
|
14174
14454
|
{{ c.renderValue() }}
|
|
14175
14455
|
} @else if (c.getIsPlaceholder?.()) {
|
|
14176
14456
|
} @else {
|
|
14177
|
-
|
|
14457
|
+
@if (cellTpl(c); as tpl) {
|
|
14458
|
+
<ng-container [ngTemplateOutlet]="tpl" [ngTemplateOutletContext]="{ $implicit: r.original, row: r.original, value: c.getValue(), cell: c }" />
|
|
14459
|
+
} @else {
|
|
14460
|
+
{{ c.getValue() }}
|
|
14461
|
+
}
|
|
14178
14462
|
}
|
|
14179
14463
|
</td>
|
|
14180
14464
|
}
|
|
@@ -14211,7 +14495,13 @@ class KjTableComponent {
|
|
|
14211
14495
|
</td>
|
|
14212
14496
|
}
|
|
14213
14497
|
@for (c of r.getVisibleCells(); track c.id) {
|
|
14214
|
-
<td kjTableCell [kjCell]="c" tabindex="-1">
|
|
14498
|
+
<td kjTableCell [kjCell]="c" tabindex="-1">
|
|
14499
|
+
@if (cellTpl(c); as tpl) {
|
|
14500
|
+
<ng-container [ngTemplateOutlet]="tpl" [ngTemplateOutletContext]="{ $implicit: r.original, row: r.original, value: c.getValue(), cell: c }" />
|
|
14501
|
+
} @else {
|
|
14502
|
+
{{ c.getValue() }}
|
|
14503
|
+
}
|
|
14504
|
+
</td>
|
|
14215
14505
|
}
|
|
14216
14506
|
</tr>
|
|
14217
14507
|
}
|
|
@@ -14392,7 +14682,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImpor
|
|
|
14392
14682
|
(editCancel)="onEditorCancel()"
|
|
14393
14683
|
></span>
|
|
14394
14684
|
} @else {
|
|
14395
|
-
|
|
14685
|
+
@if (cellTpl(c); as tpl) {
|
|
14686
|
+
<ng-container [ngTemplateOutlet]="tpl" [ngTemplateOutletContext]="{ $implicit: r.original, row: r.original, value: c.getValue(), cell: c }" />
|
|
14687
|
+
} @else {
|
|
14688
|
+
{{ c.getValue() }}
|
|
14689
|
+
}
|
|
14396
14690
|
}
|
|
14397
14691
|
</td>
|
|
14398
14692
|
}
|
|
@@ -14448,7 +14742,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImpor
|
|
|
14448
14742
|
(editCancel)="onEditorCancel()"
|
|
14449
14743
|
></span>
|
|
14450
14744
|
} @else {
|
|
14451
|
-
|
|
14745
|
+
@if (cellTpl(c); as tpl) {
|
|
14746
|
+
<ng-container [ngTemplateOutlet]="tpl" [ngTemplateOutletContext]="{ $implicit: r.original, row: r.original, value: c.getValue(), cell: c }" />
|
|
14747
|
+
} @else {
|
|
14748
|
+
{{ c.getValue() }}
|
|
14749
|
+
}
|
|
14452
14750
|
}
|
|
14453
14751
|
</td>
|
|
14454
14752
|
}
|
|
@@ -14520,7 +14818,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImpor
|
|
|
14520
14818
|
{{ c.renderValue() }}
|
|
14521
14819
|
} @else if (c.getIsPlaceholder?.()) {
|
|
14522
14820
|
} @else {
|
|
14523
|
-
|
|
14821
|
+
@if (cellTpl(c); as tpl) {
|
|
14822
|
+
<ng-container [ngTemplateOutlet]="tpl" [ngTemplateOutletContext]="{ $implicit: r.original, row: r.original, value: c.getValue(), cell: c }" />
|
|
14823
|
+
} @else {
|
|
14824
|
+
{{ c.getValue() }}
|
|
14825
|
+
}
|
|
14524
14826
|
}
|
|
14525
14827
|
</td>
|
|
14526
14828
|
}
|
|
@@ -14557,7 +14859,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImpor
|
|
|
14557
14859
|
</td>
|
|
14558
14860
|
}
|
|
14559
14861
|
@for (c of r.getVisibleCells(); track c.id) {
|
|
14560
|
-
<td kjTableCell [kjCell]="c" tabindex="-1">
|
|
14862
|
+
<td kjTableCell [kjCell]="c" tabindex="-1">
|
|
14863
|
+
@if (cellTpl(c); as tpl) {
|
|
14864
|
+
<ng-container [ngTemplateOutlet]="tpl" [ngTemplateOutletContext]="{ $implicit: r.original, row: r.original, value: c.getValue(), cell: c }" />
|
|
14865
|
+
} @else {
|
|
14866
|
+
{{ c.getValue() }}
|
|
14867
|
+
}
|
|
14868
|
+
</td>
|
|
14561
14869
|
}
|
|
14562
14870
|
</tr>
|
|
14563
14871
|
}
|
|
@@ -14592,7 +14900,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImpor
|
|
|
14592
14900
|
<ng-content />
|
|
14593
14901
|
</div>
|
|
14594
14902
|
`, encapsulation: ViewEncapsulation.Emulated, styles: [":host{display:flex;flex-direction:column;min-height:0;min-width:0;font-family:var(--kj-font-sans);font-size:var(--kj-text-sm);--kj-table-row-height: 2.25rem}:host([data-density=\"compact\"]){--kj-table-row-height: 1.75rem}:host([data-density=\"comfortable\"]){--kj-table-row-height: 2.75rem}.kj-table-wrapper{display:flex;flex-direction:column;flex:1 1 auto;min-height:0;min-width:0;position:relative}.kj-table-body{position:relative;overflow:auto;display:block;flex:1 1 auto;min-height:0;min-width:0}.kj-table-body>table{min-width:100%}:host th,:host td{height:var(--kj-table-row-height)}:host table{width:100%;border-collapse:collapse;background:var(--kj-bg-surface);color:var(--kj-fg-default)}:host th,:host td{text-align:left;padding:var(--kj-base-space-sm) var(--kj-base-space-md);border-bottom:1px solid var(--kj-border-default);position:relative}:host th{font-weight:600;background:var(--kj-bg-elevated)}:host th[aria-sort]{-webkit-user-select:none;user-select:none}.kj-table-sort-indicator{display:inline-flex;align-items:center;margin-inline-start:var(--kj-base-space-xs, .25rem);color:var(--kj-fg-subtle, var(--kj-fg-muted));transition:color var(--kj-transition);vertical-align:middle}:host th[data-sort=asc] .kj-table-sort-indicator,:host th[data-sort=desc] .kj-table-sort-indicator{color:var(--kj-fg-primary)}:host th[aria-sort]:hover .kj-table-sort-indicator,:host th[aria-sort]:focus-visible .kj-table-sort-indicator{color:var(--kj-fg-default)}:host([data-density=\"compact\"]) th,:host([data-density=\"compact\"]) td{padding:var(--kj-base-space-xs) var(--kj-base-space-sm)}:host([data-density=\"comfortable\"]) th,:host([data-density=\"comfortable\"]) td{padding:var(--kj-base-space-md) var(--kj-base-space-lg)}:host([data-variant=\"striped\"]) tbody tr:nth-child(2n) td{background:var(--kj-bg-elevated)}:host([data-variant=\"clean\"]) th,:host([data-variant=\"clean\"]) td{border-bottom-color:transparent}:host td:focus-visible,:host th:focus-visible{outline:2px solid var(--kj-border-focus);outline-offset:-2px}:host td.kj-table-cell--editing{position:relative}:host td .kj-table-cell-ghost{visibility:hidden;white-space:pre;display:inline-block;pointer-events:none}:host td.kj-table-cell--editing ::ng-deep kj-text-editor,:host td.kj-table-cell--editing ::ng-deep kj-number-editor,:host td.kj-table-cell--editing ::ng-deep kj-select-editor,:host td.kj-table-cell--editing ::ng-deep kj-date-editor,:host td.kj-table-cell--editing ::ng-deep kj-boolean-editor{position:absolute!important;inset:0!important;display:flex!important;align-items:center!important;padding:inherit!important;background:var(--kj-bg-surface);z-index:1}:host td.kj-table-cell--editing ::ng-deep kj-input,:host td.kj-table-cell--editing ::ng-deep kj-number-input,:host td.kj-table-cell--editing ::ng-deep kj-select{display:flex!important;width:100%!important;min-width:0!important;box-sizing:border-box}:host td.kj-table-cell--editing ::ng-deep input,:host td.kj-table-cell--editing ::ng-deep .kj-select-trigger{width:100%!important;min-width:0!important;box-sizing:border-box}:host td .kj-table-editor-anchor{display:none}:host tr[data-selected] td{background:color-mix(in oklab,var(--kj-bg-primary, var(--kj-bg-accent, currentColor)) 12%,var(--kj-bg-surface))}:host tr[data-selected] td:first-child{box-shadow:inset 3px 0 0 0 var(--kj-bg-primary, var(--kj-fg-primary))}:host td[data-pin=left],:host th[data-pin=left]{position:sticky;left:0;z-index:1;background:var(--kj-bg-surface)}:host td[data-pin=right],:host th[data-pin=right]{position:sticky;right:0;z-index:1;background:var(--kj-bg-surface)}:host td[data-pin=left]:not(:has(+td[data-pin=left])),:host th[data-pin=left]:not(:has(+th[data-pin=left])){border-right:1px solid var(--kj-border-strong, var(--kj-border-default));box-shadow:4px 0 6px -4px #00000040}:host tr>:not([data-pin=right])+td[data-pin=right],:host tr>:not([data-pin=right])+th[data-pin=right]{border-left:1px solid var(--kj-border-strong, var(--kj-border-default));box-shadow:-4px 0 6px -4px #00000040}:host([data-variant=\"striped\"]) tbody tr:nth-child(2n) td[data-pin]{background:var(--kj-bg-elevated)}.kj-table-resize-handle{position:absolute;top:25%;right:0;width:6px;height:50%;cursor:col-resize;-webkit-user-select:none;user-select:none;touch-action:none;background:transparent;border-right:2px solid var(--kj-border-strong, var(--kj-border-default));transition:border-color var(--kj-transition),background var(--kj-transition),width var(--kj-transition)}.kj-table-resize-handle:hover,.kj-table-resize-handle:focus-visible{border-right-color:var(--kj-border-focus);background:color-mix(in srgb,var(--kj-border-focus) 20%,transparent);width:8px;outline:none}:host th[data-resizing] .kj-table-resize-handle{top:0;height:9999px;width:0;background:transparent;border-right:2px solid var(--kj-border-focus, var(--kj-bg-primary));transform:translate(var(--kj-resize-delta, 0px));pointer-events:none;z-index:3;transition:none}:host th.kj-table-select-cell,:host td.kj-table-select-cell{width:2.5rem;padding-inline:var(--kj-base-space-sm);text-align:center;vertical-align:middle}.kj-table-select-cell kj-checkbox{display:inline-flex;align-items:center;justify-content:center}.kj-table-filter-row>th{font-weight:400;background:var(--kj-bg-surface);border-top:1px solid var(--kj-border-muted, var(--kj-border-default))}.kj-table-filter-cell{padding-top:var(--kj-base-space-xs);padding-bottom:var(--kj-base-space-xs);vertical-align:middle}.kj-table-filter-cell .kj-table-filter-anchor+*,.kj-table-filter-cell kj-input,.kj-table-filter-cell kj-number-input,.kj-table-filter-cell kj-date-picker,.kj-table-filter-cell kj-select{width:100%}.kj-table-filter-anchor{display:block;width:100%}:host .kj-table-editor-anchor .kj-input,:host .kj-table-editor-anchor .kj-select{--kj-input-height: 1.75rem;--kj-input-font-size: var(--kj-text-xs);--kj-input-padding-x: var(--kj-base-space-sm);--kj-input-padding-y: 0;--kj-input-radius: var(--kj-radius-selector)}.kj-table-empty,.kj-table-error,.kj-table-loading{display:flex;align-items:center;justify-content:center;padding:var(--kj-base-space-lg);color:var(--kj-fg-muted)}.kj-table-loading{position:absolute;inset:0;background:color-mix(in srgb,var(--kj-bg-surface) 70%,transparent);pointer-events:none}.kj-table-loading[data-has-rows]{inset:0 0 auto;height:2px;background:var(--kj-bg-primary);padding:0;animation:kj-table-loading-pulse 1.4s ease-in-out infinite}.kj-table-loading[data-has-rows] .kj-table-loading-fallback,.kj-table-loading[data-has-rows] ::ng-deep [kjLoading]{display:none}@keyframes kj-table-loading-pulse{0%,to{opacity:.55}50%{opacity:1}}.kj-table-error{color:var(--kj-fg-error, var(--kj-fg-default))}.kj-table-loading-fallback{font-size:var(--kj-text-sm)}.kj-table-expansion-row>td{background:var(--kj-bg-elevated)}.kj-table-tbody-pinned[data-pin=top]>tr>td{background:var(--kj-bg-elevated);border-bottom:2px solid var(--kj-border-primary, var(--kj-border-strong, var(--kj-border-default)));box-shadow:0 4px 6px -4px #00000040;position:sticky;top:0;z-index:2}.kj-table-tbody-pinned[data-pin=bottom]>tr>td{background:var(--kj-bg-elevated);border-top:2px solid var(--kj-border-primary, var(--kj-border-strong, var(--kj-border-default)));box-shadow:0 -4px 6px -4px #00000040;position:sticky;bottom:0;z-index:2}.kj-table-group-toggle{display:inline-flex;align-items:center;gap:var(--kj-base-space-xs, .25rem);background:transparent;border:0;padding:0;font:inherit;color:inherit;cursor:pointer}.kj-table-group-toggle__chevron{display:inline-block;width:.75rem;font-family:var(--kj-font-mono);color:var(--kj-fg-muted);transition:transform var(--kj-transition)}.kj-table-group-toggle[aria-expanded=true] .kj-table-group-toggle__chevron{transform:rotate(90deg)}.kj-table-group-toggle__count{margin-inline-start:var(--kj-base-space-xs, .25rem);font-size:.75em;color:var(--kj-fg-muted);font-variant-numeric:tabular-nums}:host tbody tr[data-row-grouped] td{background:var(--kj-bg-elevated);font-weight:600}\n"] }]
|
|
14595
|
-
}], ctorParameters: () => [], propDecorators: { kjResource: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjResource", required: false }] }], kjDensity: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjDensity", required: false }] }], kjVariant: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjVariant", required: false }] }], kjLoading: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjLoading", required: false }] }], kjSelection: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjSelection", required: false }] }, { type: i0.Output, args: ["kjSelectionChange"] }], kjSelectionMode: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjSelectionMode", required: false }] }], kjShowSelectionColumn: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjShowSelectionColumn", required: false }] }], kjStorageKey: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjStorageKey", required: false }] }], kjStorageAdapter: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjStorageAdapter", required: false }] }], kjVirtual: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjVirtual", required: false }] }], kjEstimatedRowSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjEstimatedRowSize", required: false }] }], kjEnableFilters: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjEnableFilters", required: false }] }], kjEnableResize: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjEnableResize", required: false }] }], kjEnableRowPinning: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjEnableRowPinning", required: false }] }], kjEditOnDoubleClick: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjEditOnDoubleClick", required: false }] }], kjRowExpansionTpl: [{ type: i0.ContentChild, args: ['kjRowExpansion', { isSignal: true }] }], cellEdit: [{ type: i0.Output, args: ["cellEdit"] }], stateChange: [{ type: i0.Output, args: ["stateChange"] }], rowClick: [{ type: i0.Output, args: ["rowClick"] }], rowDoubleClick: [{ type: i0.Output, args: ["rowDoubleClick"] }] } });
|
|
14903
|
+
}], ctorParameters: () => [], propDecorators: { kjResource: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjResource", required: false }] }], kjDensity: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjDensity", required: false }] }], kjVariant: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjVariant", required: false }] }], kjLoading: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjLoading", required: false }] }], kjSelection: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjSelection", required: false }] }, { type: i0.Output, args: ["kjSelectionChange"] }], kjSelectionMode: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjSelectionMode", required: false }] }], kjShowSelectionColumn: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjShowSelectionColumn", required: false }] }], kjStorageKey: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjStorageKey", required: false }] }], kjStorageAdapter: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjStorageAdapter", required: false }] }], kjVirtual: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjVirtual", required: false }] }], kjEstimatedRowSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjEstimatedRowSize", required: false }] }], kjEnableFilters: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjEnableFilters", required: false }] }], kjEnableResize: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjEnableResize", required: false }] }], kjEnableRowPinning: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjEnableRowPinning", required: false }] }], kjEditOnDoubleClick: [{ type: i0.Input, args: [{ isSignal: true, alias: "kjEditOnDoubleClick", required: false }] }], kjRowExpansionTpl: [{ type: i0.ContentChild, args: ['kjRowExpansion', { isSignal: true }] }], cellTemplates: [{ type: i0.ContentChildren, args: [i0.forwardRef(() => KjCellTemplateDirective), { isSignal: true }] }], cellEdit: [{ type: i0.Output, args: ["cellEdit"] }], stateChange: [{ type: i0.Output, args: ["stateChange"] }], rowClick: [{ type: i0.Output, args: ["rowClick"] }], rowDoubleClick: [{ type: i0.Output, args: ["rowDoubleClick"] }] } });
|
|
14596
14904
|
// ── helpers ───────────────────────────────────────────────────────────────
|
|
14597
14905
|
function cellMeta(col) {
|
|
14598
14906
|
return col.columnDef.meta?.kj;
|
|
@@ -17674,5 +17982,5 @@ const KJ_COMPONENTS_VERSION = '0.0.1';
|
|
|
17674
17982
|
* Generated bundle index. Do not edit.
|
|
17675
17983
|
*/
|
|
17676
17984
|
|
|
17677
|
-
export { KJ_COMPONENTS_VERSION, KJ_EDITOR_CONTRACT, KJ_FILTER_CONTEXT, KjAccordionComponent, KjAccordionContentComponent, KjAccordionItemComponent, KjAccordionTriggerComponent, KjAlertActionsComponent, KjAlertComponent, KjAlertDescriptionComponent, KjAlertDismissComponent, KjAlertIconComponent, KjAlertTitleComponent, KjAvatarComponent, KjAvatarGroupComponent, KjBadgeComponent, KjBooleanEditor, KjBreadcrumbComponent, KjBreadcrumbCurrentComponent, KjBreadcrumbEllipsisComponent, KjBreadcrumbItemComponent, KjBreadcrumbLinkComponent, KjBreadcrumbListComponent, KjBreadcrumbSeparatorComponent, KjBulkAction, KjButtonComponent, KjButtonGroupComponent, KjCalendarComponent, KjCardComponent, KjCardContentComponent, KjCardCoverComponent, KjCardFooterComponent, KjCardHeaderComponent, KjCardSubtitleComponent, KjCardTitleComponent, KjCarouselAutoplayComponent, KjCarouselComponent, KjCarouselIndicatorsComponent, KjCarouselNextComponent, KjCarouselPauseComponent, KjCarouselPreviousComponent, KjCarouselSlideComponent, KjCarouselViewportComponent, KjCascadeOptionComponent, KjCascadeSelectComponent, KjCascadeSubPanelComponent, KjCellEditorOutlet, KjChatAvatarComponent, KjChatBubbleComponent, KjChatComponent, KjChatFooterComponent, KjChatHeaderComponent, KjChatLogComponent, KjCheckboxComponent, KjColorPickerComponent, KjComboboxComponent, KjComboboxEmptyComponent, KjComboboxLoadingComponent, KjComboboxOptionComponent, KjCommandEmptyComponent, KjCommandGroupComponent, KjCommandInputComponent, KjCommandItemComponent, KjCommandPaletteComponent, KjCommandPaletteFooter, KjCommandPaletteItemTemplate, KjCommandSeparatorComponent, KjConfirmPopupActionComponent, KjConfirmPopupActionsComponent, KjConfirmPopupCancelComponent, KjConfirmPopupComponent, KjConfirmPopupContentComponent, KjConfirmPopupMessageComponent, KjConfirmPopupTriggerComponent, KjDateEditor, KjDateFilter, KjDatePickerComponent, KjDialogComponent, KjDividerComponent, KjDrawerComponent, KjDropdownMenuComponent, KjEmptyStateActionsComponent, KjEmptyStateComponent, KjEmptyStateDescriptionComponent, KjEmptyStateIconComponent, KjEmptyStateTitleComponent, KjFieldComponent, KjFieldErrorComponent, KjFieldGroupComponent, KjFieldHelpComponent, KjFieldLabelComponent, KjFileUploadComponent, KjFilterCellOutlet, KjFormActionsComponent, KjFormComponent, KjFormSummaryComponent, KjIconGalleryExample, KjIconUsageExample, KjInputComponent, KjInputGroupAddonComponent, KjInputGroupComponent, KjInputMaskComponent, KjInputMaskCreditCardExample, KjInputMaskCustomTokensExample, KjInputMaskDateExample, KjInputMaskExample, KjInputMaskUsageExample, KjInputMaskValidationExample, KjInputOtpComponent, KjKbdComponent, KjLinkComponent, KjListComponent, KjListItemComponent, KjMenubarComponent, KjMenubarItemComponent, KjNumberEditor, KjNumberFilter, KjNumberInputComponent, KjOptionComponent, KjOverlayBadgeComponent, KjOverlayBadgeContentComponent, KjPaginationComponent, KjPaginationDefaultComponent, KjPaginationEllipsisComponent, KjPaginationFirstComponent, KjPaginationInfoComponent, KjPaginationItemComponent, KjPaginationLastComponent, KjPaginationNextComponent, KjPaginationPreviousComponent, KjPasswordInputComponent, KjPopoverComponent, KjProgressBarComponent, KjRadioComponent, KjRadioGroupComponent, KjSelectComponent, KjSelectEditor, KjSelectFilter, KjSkeletonComponent, KjSliderComponent, KjSpeedDialActionComponent, KjSpeedDialActionsComponent, KjSpeedDialComponent, KjSpeedDialTriggerComponent, KjSpinnerComponent, KjStepComponent, KjStepContentComponent, KjStepLabelComponent, KjStepperComponent, KjStepperNextComponent, KjStepperPreviousComponent, KjStepperResetComponent, KjTabComponent, KjTabListComponent, KjTabPanelComponent, KjTableComponent, KjTablePaginationComponent, KjTableSidePanelComponent, KjTableSidePanelContent, KjTableStatusBarComponent, KjTableToolbarComponent, KjTableVirtual, KjTabsComponent, KjTagComponent, KjTagListComponent, KjTagRemoveComponent, KjTextEditor, KjTextFilter, KjTextareaComponent, KjTimePickerComponent, KjToastCloseComponent, KjToastComponent, KjToastViewportComponent, KjToastWrapperComponent, KjToggleComponent, KjTooltipComponent, KjTreeSelectComponent, KjTreeSelectNodeComponent, LUCIDE_ICON_NAMES, copyToClipboard, downloadString, exportCsv, exportJson, provideLucideIcons, toTsv };
|
|
17985
|
+
export { KJ_COMPONENTS_VERSION, KJ_EDITOR_CONTRACT, KJ_FILTER_CONTEXT, KjAccordionComponent, KjAccordionContentComponent, KjAccordionItemComponent, KjAccordionTriggerComponent, KjAlertActionsComponent, KjAlertComponent, KjAlertDescriptionComponent, KjAlertDismissComponent, KjAlertIconComponent, KjAlertTitleComponent, KjAvatarComponent, KjAvatarGroupComponent, KjBadgeComponent, KjBooleanEditor, KjBreadcrumbComponent, KjBreadcrumbCurrentComponent, KjBreadcrumbEllipsisComponent, KjBreadcrumbItemComponent, KjBreadcrumbLinkComponent, KjBreadcrumbListComponent, KjBreadcrumbSeparatorComponent, KjBulkAction, KjButtonComponent, KjButtonGroupComponent, KjCalendarComponent, KjCardComponent, KjCardContentComponent, KjCardCoverComponent, KjCardFooterComponent, KjCardHeaderComponent, KjCardSubtitleComponent, KjCardTitleComponent, KjCarouselAutoplayComponent, KjCarouselComponent, KjCarouselIndicatorsComponent, KjCarouselNextComponent, KjCarouselPauseComponent, KjCarouselPreviousComponent, KjCarouselSlideComponent, KjCarouselViewportComponent, KjCascadeOptionComponent, KjCascadeSelectComponent, KjCascadeSubPanelComponent, KjCellEditorOutlet, KjCellTemplateDirective, KjChatAvatarComponent, KjChatBubbleComponent, KjChatComponent, KjChatFooterComponent, KjChatHeaderComponent, KjChatLogComponent, KjCheckboxComponent, KjColorPickerComponent, KjComboboxComponent, KjComboboxEmptyComponent, KjComboboxLoadingComponent, KjComboboxOptionComponent, KjCommandEmptyComponent, KjCommandGroupComponent, KjCommandInputComponent, KjCommandItemComponent, KjCommandPaletteComponent, KjCommandPaletteFooter, KjCommandPaletteItemTemplate, KjCommandSeparatorComponent, KjConfirmPopupActionComponent, KjConfirmPopupActionsComponent, KjConfirmPopupCancelComponent, KjConfirmPopupComponent, KjConfirmPopupContentComponent, KjConfirmPopupMessageComponent, KjConfirmPopupTriggerComponent, KjDateEditor, KjDateFilter, KjDatePickerComponent, KjDatetimePickerComponent, KjDialogComponent, KjDividerComponent, KjDrawerComponent, KjDropdownMenuComponent, KjEmptyStateActionsComponent, KjEmptyStateComponent, KjEmptyStateDescriptionComponent, KjEmptyStateIconComponent, KjEmptyStateTitleComponent, KjFieldComponent, KjFieldErrorComponent, KjFieldGroupComponent, KjFieldHelpComponent, KjFieldLabelComponent, KjFileUploadComponent, KjFilterCellOutlet, KjFormActionsComponent, KjFormComponent, KjFormSummaryComponent, KjIconGalleryExample, KjIconUsageExample, KjInputComponent, KjInputGroupAddonComponent, KjInputGroupComponent, KjInputMaskComponent, KjInputMaskCreditCardExample, KjInputMaskCustomTokensExample, KjInputMaskDateExample, KjInputMaskExample, KjInputMaskUsageExample, KjInputMaskValidationExample, KjInputOtpComponent, KjKbdComponent, KjLinkComponent, KjListComponent, KjListItemComponent, KjMenubarComponent, KjMenubarItemComponent, KjNumberEditor, KjNumberFilter, KjNumberInputComponent, KjOptionComponent, KjOverlayBadgeComponent, KjOverlayBadgeContentComponent, KjPaginationComponent, KjPaginationDefaultComponent, KjPaginationEllipsisComponent, KjPaginationFirstComponent, KjPaginationInfoComponent, KjPaginationItemComponent, KjPaginationLastComponent, KjPaginationNextComponent, KjPaginationPreviousComponent, KjPasswordInputComponent, KjPopoverComponent, KjProgressBarComponent, KjRadioComponent, KjRadioGroupComponent, KjSelectComponent, KjSelectEditor, KjSelectFilter, KjSkeletonComponent, KjSliderComponent, KjSpeedDialActionComponent, KjSpeedDialActionsComponent, KjSpeedDialComponent, KjSpeedDialTriggerComponent, KjSpinnerComponent, KjStepComponent, KjStepContentComponent, KjStepLabelComponent, KjStepperComponent, KjStepperNextComponent, KjStepperPreviousComponent, KjStepperResetComponent, KjTabComponent, KjTabListComponent, KjTabPanelComponent, KjTableComponent, KjTablePaginationComponent, KjTableSidePanelComponent, KjTableSidePanelContent, KjTableStatusBarComponent, KjTableToolbarComponent, KjTableVirtual, KjTabsComponent, KjTagComponent, KjTagListComponent, KjTagRemoveComponent, KjTextEditor, KjTextFilter, KjTextareaComponent, KjTimePickerComponent, KjToastCloseComponent, KjToastComponent, KjToastViewportComponent, KjToastWrapperComponent, KjToggleComponent, KjTooltipComponent, KjTreeSelectComponent, KjTreeSelectNodeComponent, LUCIDE_ICON_NAMES, copyToClipboard, downloadString, exportCsv, exportJson, provideLucideIcons, toTsv };
|
|
17678
17986
|
//# sourceMappingURL=kouji-ui-components.mjs.map
|