@gravionlabs/helix-ui 22.2.6 → 22.2.7

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.
@@ -2,7 +2,7 @@ import * as i1 from "@angular/cdk/accordion";
2
2
  import { CdkAccordion, CdkAccordionItem } from "@angular/cdk/accordion";
3
3
  import { DOCUMENT, NgComponentOutlet, NgStyle, NgTemplateOutlet, isPlatformBrowser } from "@angular/common";
4
4
  import * as i0 from "@angular/core";
5
- import { ChangeDetectionStrategy, Component, DestroyRef, Directive, ElementRef, Injectable, InjectionToken, Injector, NgZone, PLATFORM_ID, TemplateRef, afterEveryRender, afterNextRender, booleanAttribute, computed, contentChild, contentChildren, effect, forwardRef, inject, input, makeEnvironmentProviders, model, numberAttribute, output, provideEnvironmentInitializer, signal, untracked, viewChild } from "@angular/core";
5
+ import { ChangeDetectionStrategy, Component, DestroyRef, Directive, ElementRef, Injectable, InjectionToken, Injector, PLATFORM_ID, TemplateRef, afterEveryRender, afterNextRender, booleanAttribute, computed, contentChild, contentChildren, effect, forwardRef, inject, input, isDevMode, makeEnvironmentProviders, model, numberAttribute, output, provideEnvironmentInitializer, signal, untracked, viewChild } from "@angular/core";
6
6
  import { takeUntilDestroyed } from "@angular/core/rxjs-interop";
7
7
  import { CdkConnectedOverlay, CdkOverlayOrigin, Overlay } from "@angular/cdk/overlay";
8
8
  import { NG_VALUE_ACCESSOR, NgControl } from "@angular/forms";
@@ -2614,446 +2614,6 @@ i0.ɵɵngDeclareClassMetadata({
2614
2614
  }]
2615
2615
  }
2616
2616
  });
2617
- const HX_CHART_LOADER = new InjectionToken("HX_CHART_LOADER", {
2618
- providedIn: "root",
2619
- factory: () => () => import("chart.js/auto")
2620
- });
2621
- const PALETTE = [
2622
- "--h-primary-color",
2623
- "--h-orange-500",
2624
- "--h-green-500",
2625
- "--h-purple-500",
2626
- "--h-sky-500",
2627
- "--h-red-500",
2628
- "--h-yellow-500",
2629
- "--h-teal-500"
2630
- ];
2631
- const isObject = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
2632
- function merge(defaults, overrides) {
2633
- const out = { ...defaults };
2634
- for (const [key, value] of Object.entries(overrides)) {
2635
- const base = out[key];
2636
- out[key] = isObject(base) && isObject(value) ? merge(base, value) : value;
2637
- }
2638
- return out;
2639
- }
2640
- var HxChart = class HxChart {
2641
- #host = inject(ElementRef).nativeElement;
2642
- #zone = inject(NgZone);
2643
- #loader = inject(HX_CHART_LOADER);
2644
- #platform = inject(PLATFORM_ID);
2645
- canvas = viewChild.required("canvas", ...ngDevMode ? [{ debugName: "canvas" }] : /* istanbul ignore next */ []);
2646
- type = input("bar", ...ngDevMode ? [{ debugName: "type" }] : /* istanbul ignore next */ []);
2647
- data = input({}, ...ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []);
2648
- options = input({}, ...ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ []);
2649
- plugins = input([], ...ngDevMode ? [{ debugName: "plugins" }] : /* istanbul ignore next */ []);
2650
- width = input(...ngDevMode ? [void 0, { debugName: "width" }] : /* istanbul ignore next */ []);
2651
- height = input(...ngDevMode ? [void 0, { debugName: "height" }] : /* istanbul ignore next */ []);
2652
- responsive = input(true, {
2653
- ...ngDevMode ? { debugName: "responsive" } : /* istanbul ignore next */ {},
2654
- transform: (v) => v !== false && v !== "false"
2655
- });
2656
- ariaLabel = input(...ngDevMode ? [void 0, { debugName: "ariaLabel" }] : /* istanbul ignore next */ []);
2657
- ariaLabelledBy = input(...ngDevMode ? [void 0, { debugName: "ariaLabelledBy" }] : /* istanbul ignore next */ []);
2658
- themeDelay = input(50, {
2659
- ...ngDevMode ? { debugName: "themeDelay" } : /* istanbul ignore next */ {},
2660
- transform: numberAttribute
2661
- });
2662
- dataSelect = output();
2663
- #chart;
2664
- #chartType;
2665
- #ready = false;
2666
- #loading = false;
2667
- #observer;
2668
- #timer;
2669
- constructor() {
2670
- afterNextRender(() => {
2671
- this.#ready = true;
2672
- this.#render();
2673
- this.#watchTheme();
2674
- });
2675
- effect(() => {
2676
- this.type();
2677
- this.data();
2678
- this.options();
2679
- this.plugins();
2680
- this.responsive();
2681
- this.width();
2682
- this.height();
2683
- untracked(() => {
2684
- if (this.#ready) this.#render();
2685
- });
2686
- });
2687
- inject(DestroyRef).onDestroy(() => {
2688
- clearTimeout(this.#timer);
2689
- this.#observer?.disconnect();
2690
- this.#chart?.destroy();
2691
- this.#chart = void 0;
2692
- this.#ready = false;
2693
- });
2694
- }
2695
- get chart() {
2696
- return this.#chart;
2697
- }
2698
- refresh() {
2699
- if (this.#chart) {
2700
- this.#apply(this.#chart);
2701
- this.#chart.update();
2702
- }
2703
- }
2704
- onClick(event) {
2705
- const chart = this.#chart;
2706
- if (!chart) return;
2707
- const element = chart.getElementsAtEventForMode(event, "nearest", { intersect: true }, false);
2708
- const dataset = chart.getElementsAtEventForMode(event, "dataset", { intersect: true }, false);
2709
- if (element?.[0] && dataset) this.dataSelect.emit({
2710
- originalEvent: event,
2711
- element: element[0],
2712
- dataset
2713
- });
2714
- }
2715
- async #render() {
2716
- if (!isPlatformBrowser(this.#platform)) return;
2717
- const type = this.type();
2718
- if (this.#chart && this.#chartType === type) {
2719
- this.#apply(this.#chart);
2720
- this.#chart.update();
2721
- return;
2722
- }
2723
- if (this.#loading) return;
2724
- this.#loading = true;
2725
- try {
2726
- const module = await this.#loader();
2727
- if (!this.#ready) return;
2728
- this.#chart?.destroy();
2729
- const Chart = module.default;
2730
- this.#zone.runOutsideAngular(() => {
2731
- this.#chart = new Chart(this.canvas().nativeElement, {
2732
- type: this.type(),
2733
- data: this.#themedData(),
2734
- options: this.#themedOptions(),
2735
- plugins: [...this.plugins()]
2736
- });
2737
- });
2738
- this.#chartType = this.type();
2739
- } catch (error) {
2740
- console.error("hx-chart: chart.js could not be loaded. Is the peer dependency \"chart.js\" installed?", error);
2741
- return;
2742
- } finally {
2743
- this.#loading = false;
2744
- }
2745
- if (this.#chart && this.#chartType !== this.type()) await this.#render();
2746
- }
2747
- #apply(chart) {
2748
- chart.data = this.#themedData();
2749
- chart.options = this.#themedOptions();
2750
- }
2751
- #token(name) {
2752
- return getComputedStyle(this.#host).getPropertyValue(name).trim();
2753
- }
2754
- #themedData() {
2755
- const data = this.data();
2756
- const datasets = data.datasets;
2757
- if (!Array.isArray(datasets)) return data;
2758
- const palette = PALETTE.map((name) => this.#token(name)).filter(Boolean);
2759
- if (palette.length === 0) return data;
2760
- const perPoint = [
2761
- "pie",
2762
- "doughnut",
2763
- "polarArea"
2764
- ].includes(this.type());
2765
- return {
2766
- ...data,
2767
- datasets: datasets.map((dataset, i) => {
2768
- if (!isObject(dataset)) return dataset;
2769
- const color = palette[i % palette.length];
2770
- const count = Array.isArray(dataset.data) ? dataset.data.length : 0;
2771
- const points = Array.from({ length: count }, (_, n) => palette[n % palette.length]);
2772
- const filled = this.type() === "line" || this.type() === "radar";
2773
- return {
2774
- ...dataset,
2775
- backgroundColor: dataset.backgroundColor ?? (perPoint ? points : filled ? `color-mix(in srgb, ${color}, transparent 80%)` : color),
2776
- borderColor: dataset.borderColor ?? (perPoint ? this.#token("--h-content-background") : color)
2777
- };
2778
- })
2779
- };
2780
- }
2781
- #themedOptions() {
2782
- const text = this.#token("--h-text-color");
2783
- const muted = this.#token("--h-text-muted-color");
2784
- const grid = this.#token("--h-content-border-color");
2785
- const axis = {
2786
- ticks: { color: muted },
2787
- grid: { color: grid },
2788
- border: { color: grid }
2789
- };
2790
- const radial = {
2791
- ticks: {
2792
- color: muted,
2793
- backdropColor: "transparent"
2794
- },
2795
- grid: { color: grid },
2796
- angleLines: { color: grid },
2797
- pointLabels: { color: text }
2798
- };
2799
- const type = this.type();
2800
- const scales = type === "radar" || type === "polarArea" ? { r: radial } : type === "pie" || type === "doughnut" ? {} : {
2801
- x: axis,
2802
- y: axis
2803
- };
2804
- return merge({
2805
- responsive: this.responsive(),
2806
- maintainAspectRatio: !(this.height() || this.width()),
2807
- color: muted,
2808
- borderColor: grid,
2809
- plugins: { legend: { labels: { color: text } } },
2810
- scales
2811
- }, this.options());
2812
- }
2813
- #watchTheme() {
2814
- if (typeof MutationObserver === "undefined") return;
2815
- this.#observer = new MutationObserver(() => {
2816
- clearTimeout(this.#timer);
2817
- this.#timer = setTimeout(() => this.refresh(), this.themeDelay());
2818
- });
2819
- this.#observer.observe(document.documentElement, {
2820
- attributes: true,
2821
- attributeFilter: [
2822
- "class",
2823
- "style",
2824
- "data-theme"
2825
- ]
2826
- });
2827
- }
2828
- static ɵfac = i0.ɵɵngDeclareFactory({
2829
- minVersion: "12.0.0",
2830
- version: "22.2.1",
2831
- ngImport: i0,
2832
- type: HxChart,
2833
- deps: [],
2834
- target: i0.ɵɵFactoryTarget.Component
2835
- });
2836
- static ɵcmp = i0.ɵɵngDeclareComponent({
2837
- minVersion: "17.2.0",
2838
- version: "22.2.1",
2839
- type: HxChart,
2840
- isStandalone: true,
2841
- selector: "hx-chart",
2842
- inputs: {
2843
- type: {
2844
- classPropertyName: "type",
2845
- publicName: "type",
2846
- isSignal: true,
2847
- isRequired: false,
2848
- transformFunction: null
2849
- },
2850
- data: {
2851
- classPropertyName: "data",
2852
- publicName: "data",
2853
- isSignal: true,
2854
- isRequired: false,
2855
- transformFunction: null
2856
- },
2857
- options: {
2858
- classPropertyName: "options",
2859
- publicName: "options",
2860
- isSignal: true,
2861
- isRequired: false,
2862
- transformFunction: null
2863
- },
2864
- plugins: {
2865
- classPropertyName: "plugins",
2866
- publicName: "plugins",
2867
- isSignal: true,
2868
- isRequired: false,
2869
- transformFunction: null
2870
- },
2871
- width: {
2872
- classPropertyName: "width",
2873
- publicName: "width",
2874
- isSignal: true,
2875
- isRequired: false,
2876
- transformFunction: null
2877
- },
2878
- height: {
2879
- classPropertyName: "height",
2880
- publicName: "height",
2881
- isSignal: true,
2882
- isRequired: false,
2883
- transformFunction: null
2884
- },
2885
- responsive: {
2886
- classPropertyName: "responsive",
2887
- publicName: "responsive",
2888
- isSignal: true,
2889
- isRequired: false,
2890
- transformFunction: null
2891
- },
2892
- ariaLabel: {
2893
- classPropertyName: "ariaLabel",
2894
- publicName: "ariaLabel",
2895
- isSignal: true,
2896
- isRequired: false,
2897
- transformFunction: null
2898
- },
2899
- ariaLabelledBy: {
2900
- classPropertyName: "ariaLabelledBy",
2901
- publicName: "ariaLabelledBy",
2902
- isSignal: true,
2903
- isRequired: false,
2904
- transformFunction: null
2905
- },
2906
- themeDelay: {
2907
- classPropertyName: "themeDelay",
2908
- publicName: "themeDelay",
2909
- isSignal: true,
2910
- isRequired: false,
2911
- transformFunction: null
2912
- }
2913
- },
2914
- outputs: { dataSelect: "dataSelect" },
2915
- host: { classAttribute: "hx-chart" },
2916
- viewQueries: [{
2917
- propertyName: "canvas",
2918
- first: true,
2919
- predicate: ["canvas"],
2920
- descendants: true,
2921
- isSignal: true
2922
- }],
2923
- ngImport: i0,
2924
- template: `
2925
- <div class="hx-chart-frame" [style.width]="width() ?? null" [style.height]="height() ?? null">
2926
- <canvas
2927
- #canvas
2928
- class="hx-chart-canvas"
2929
- role="img"
2930
- [attr.aria-label]="ariaLabel() || null"
2931
- [attr.aria-labelledby]="ariaLabelledBy() || null"
2932
- (click)="onClick($event)"
2933
- ><ng-content select="[hxChartFallback]" /></canvas>
2934
- </div>
2935
- `,
2936
- isInline: true,
2937
- changeDetection: i0.ChangeDetectionStrategy.OnPush
2938
- });
2939
- };
2940
- i0.ɵɵngDeclareClassMetadata({
2941
- minVersion: "12.0.0",
2942
- version: "22.2.1",
2943
- ngImport: i0,
2944
- type: HxChart,
2945
- decorators: [{
2946
- type: Component,
2947
- args: [{
2948
- selector: "hx-chart",
2949
- changeDetection: ChangeDetectionStrategy.OnPush,
2950
- host: { class: "hx-chart" },
2951
- template: `
2952
- <div class="hx-chart-frame" [style.width]="width() ?? null" [style.height]="height() ?? null">
2953
- <canvas
2954
- #canvas
2955
- class="hx-chart-canvas"
2956
- role="img"
2957
- [attr.aria-label]="ariaLabel() || null"
2958
- [attr.aria-labelledby]="ariaLabelledBy() || null"
2959
- (click)="onClick($event)"
2960
- ><ng-content select="[hxChartFallback]" /></canvas>
2961
- </div>
2962
- `
2963
- }]
2964
- }],
2965
- ctorParameters: () => [],
2966
- propDecorators: {
2967
- canvas: [{
2968
- type: i0.ViewChild,
2969
- args: ["canvas", { isSignal: true }]
2970
- }],
2971
- type: [{
2972
- type: i0.Input,
2973
- args: [{
2974
- isSignal: true,
2975
- alias: "type",
2976
- required: false
2977
- }]
2978
- }],
2979
- data: [{
2980
- type: i0.Input,
2981
- args: [{
2982
- isSignal: true,
2983
- alias: "data",
2984
- required: false
2985
- }]
2986
- }],
2987
- options: [{
2988
- type: i0.Input,
2989
- args: [{
2990
- isSignal: true,
2991
- alias: "options",
2992
- required: false
2993
- }]
2994
- }],
2995
- plugins: [{
2996
- type: i0.Input,
2997
- args: [{
2998
- isSignal: true,
2999
- alias: "plugins",
3000
- required: false
3001
- }]
3002
- }],
3003
- width: [{
3004
- type: i0.Input,
3005
- args: [{
3006
- isSignal: true,
3007
- alias: "width",
3008
- required: false
3009
- }]
3010
- }],
3011
- height: [{
3012
- type: i0.Input,
3013
- args: [{
3014
- isSignal: true,
3015
- alias: "height",
3016
- required: false
3017
- }]
3018
- }],
3019
- responsive: [{
3020
- type: i0.Input,
3021
- args: [{
3022
- isSignal: true,
3023
- alias: "responsive",
3024
- required: false
3025
- }]
3026
- }],
3027
- ariaLabel: [{
3028
- type: i0.Input,
3029
- args: [{
3030
- isSignal: true,
3031
- alias: "ariaLabel",
3032
- required: false
3033
- }]
3034
- }],
3035
- ariaLabelledBy: [{
3036
- type: i0.Input,
3037
- args: [{
3038
- isSignal: true,
3039
- alias: "ariaLabelledBy",
3040
- required: false
3041
- }]
3042
- }],
3043
- themeDelay: [{
3044
- type: i0.Input,
3045
- args: [{
3046
- isSignal: true,
3047
- alias: "themeDelay",
3048
- required: false
3049
- }]
3050
- }],
3051
- dataSelect: [{
3052
- type: i0.Output,
3053
- args: ["dataSelect"]
3054
- }]
3055
- }
3056
- });
3057
2617
  var HxCheckbox = class HxCheckbox {
3058
2618
  size = input("medium", ...ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []);
3059
2619
  static ɵfac = i0.ɵɵngDeclareFactory({
@@ -5607,9 +5167,14 @@ var HxPaginator = class HxPaginator {
5607
5167
  lastPageLabel = input("Last page", ...ngDevMode ? [{ debugName: "lastPageLabel" }] : /* istanbul ignore next */ []);
5608
5168
  pageLabelTemplate = input("Page {page}", ...ngDevMode ? [{ debugName: "pageLabelTemplate" }] : /* istanbul ignore next */ []);
5609
5169
  rowsPerPageLabel = input("Rows per page", ...ngDevMode ? [{ debugName: "rowsPerPageLabel" }] : /* istanbul ignore next */ []);
5170
+ allLabel = input("All", ...ngDevMode ? [{ debugName: "allLabel" }] : /* istanbul ignore next */ []);
5171
+ showAll = model(false, ...ngDevMode ? [{ debugName: "showAll" }] : /* istanbul ignore next */ []);
5172
+ allSelected = computed(() => this.showAll() && !!this.rowsPerPageOptions()?.includes("all"), ...ngDevMode ? [{ debugName: "allSelected" }] : /* istanbul ignore next */ []);
5173
+ perPage = computed(() => this.allSelected() ? Math.max(1, this.totalRecords()) : this.rows(), ...ngDevMode ? [{ debugName: "perPage" }] : /* istanbul ignore next */ []);
5174
+ rowsValue = computed(() => this.allSelected() ? "all" : this.rows(), ...ngDevMode ? [{ debugName: "rowsValue" }] : /* istanbul ignore next */ []);
5610
5175
  pageChange = output();
5611
- pageCount = computed(() => Math.max(1, Math.ceil(this.totalRecords() / Math.max(1, this.rows()))), ...ngDevMode ? [{ debugName: "pageCount" }] : /* istanbul ignore next */ []);
5612
- page = computed(() => Math.min(this.pageCount() - 1, Math.floor(this.first() / Math.max(1, this.rows()))), ...ngDevMode ? [{ debugName: "page" }] : /* istanbul ignore next */ []);
5176
+ pageCount = computed(() => Math.max(1, Math.ceil(this.totalRecords() / Math.max(1, this.perPage()))), ...ngDevMode ? [{ debugName: "pageCount" }] : /* istanbul ignore next */ []);
5177
+ page = computed(() => Math.min(this.pageCount() - 1, Math.floor(this.first() / Math.max(1, this.perPage()))), ...ngDevMode ? [{ debugName: "page" }] : /* istanbul ignore next */ []);
5613
5178
  isFirst = computed(() => this.page() === 0, ...ngDevMode ? [{ debugName: "isFirst" }] : /* istanbul ignore next */ []);
5614
5179
  isLast = computed(() => this.page() >= this.pageCount() - 1, ...ngDevMode ? [{ debugName: "isLast" }] : /* istanbul ignore next */ []);
5615
5180
  links = computed(() => {
@@ -5620,13 +5185,13 @@ var HxPaginator = class HxPaginator {
5620
5185
  return Array.from({ length: size }, (_, i) => start + i);
5621
5186
  }, ...ngDevMode ? [{ debugName: "links" }] : /* istanbul ignore next */ []);
5622
5187
  rowsOptions = computed(() => (this.rowsPerPageOptions() ?? []).map((n) => ({
5623
- label: String(n),
5188
+ label: n === "all" ? this.allLabel() : String(n),
5624
5189
  value: n
5625
5190
  })), ...ngDevMode ? [{ debugName: "rowsOptions" }] : /* istanbul ignore next */ []);
5626
5191
  report = computed(() => {
5627
5192
  const total = this.totalRecords();
5628
- const first = total === 0 ? 0 : this.page() * this.rows() + 1;
5629
- const last = Math.min(total, (this.page() + 1) * this.rows());
5193
+ const first = total === 0 ? 0 : this.page() * this.perPage() + 1;
5194
+ const last = Math.min(total, (this.page() + 1) * this.perPage());
5630
5195
  return this.currentPageReportTemplate().replace("{first}", String(first)).replace("{last}", String(last)).replace("{totalRecords}", String(total)).replace("{page}", String(this.page() + 1)).replace("{pageCount}", String(this.pageCount()));
5631
5196
  }, ...ngDevMode ? [{ debugName: "report" }] : /* istanbul ignore next */ []);
5632
5197
  pageLabel(page) {
@@ -5634,13 +5199,21 @@ var HxPaginator = class HxPaginator {
5634
5199
  }
5635
5200
  goTo(page) {
5636
5201
  const target = Math.min(this.pageCount() - 1, Math.max(0, page));
5637
- if (target === this.page() && this.first() === target * this.rows()) return;
5638
- this.first.set(target * this.rows());
5202
+ if (target === this.page() && this.first() === target * this.perPage()) return;
5203
+ this.first.set(target * this.perPage());
5639
5204
  this.emit();
5640
5205
  }
5641
5206
  setRows(value) {
5207
+ if (value === "all") {
5208
+ if (this.allSelected()) return;
5209
+ this.showAll.set(true);
5210
+ this.first.set(0);
5211
+ this.emit();
5212
+ return;
5213
+ }
5642
5214
  const rows = Number(value);
5643
- if (!rows || rows === this.rows()) return;
5215
+ if (!rows || rows === this.rows() && !this.allSelected()) return;
5216
+ this.showAll.set(false);
5644
5217
  this.rows.set(rows);
5645
5218
  this.first.set(Math.floor(this.first() / rows) * rows);
5646
5219
  this.emit();
@@ -5648,9 +5221,10 @@ var HxPaginator = class HxPaginator {
5648
5221
  emit() {
5649
5222
  this.pageChange.emit({
5650
5223
  first: this.first(),
5651
- rows: this.rows(),
5224
+ rows: this.perPage(),
5652
5225
  page: this.page(),
5653
- pageCount: this.pageCount()
5226
+ pageCount: this.pageCount(),
5227
+ ...this.allSelected() ? { all: true } : {}
5654
5228
  });
5655
5229
  }
5656
5230
  static ɵfac = i0.ɵɵngDeclareFactory({
@@ -5772,16 +5346,31 @@ var HxPaginator = class HxPaginator {
5772
5346
  isSignal: true,
5773
5347
  isRequired: false,
5774
5348
  transformFunction: null
5349
+ },
5350
+ allLabel: {
5351
+ classPropertyName: "allLabel",
5352
+ publicName: "allLabel",
5353
+ isSignal: true,
5354
+ isRequired: false,
5355
+ transformFunction: null
5356
+ },
5357
+ showAll: {
5358
+ classPropertyName: "showAll",
5359
+ publicName: "showAll",
5360
+ isSignal: true,
5361
+ isRequired: false,
5362
+ transformFunction: null
5775
5363
  }
5776
5364
  },
5777
5365
  outputs: {
5778
5366
  rows: "rowsChange",
5779
5367
  first: "firstChange",
5368
+ showAll: "showAllChange",
5780
5369
  pageChange: "pageChange"
5781
5370
  },
5782
5371
  host: { classAttribute: "hx-paginator" },
5783
5372
  ngImport: i0,
5784
- template: "<nav class=\"hx-paginator-nav\" [attr.aria-label]=\"ariaLabel()\">\n @if (showCurrentPageReport()) {\n <span class=\"hx-paginator-report\" aria-live=\"polite\">{{ report() }}</span>\n }\n <div class=\"hx-paginator-pages\">\n @if (showFirstLastButtons()) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-first\" [disabled]=\"isFirst()\" [attr.aria-label]=\"firstPageLabel()\" [title]=\"firstPageLabel()\" (click)=\"goTo(0)\"></button>\n }\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-prev\" [disabled]=\"isFirst()\" [attr.aria-label]=\"previousPageLabel()\" [title]=\"previousPageLabel()\" (click)=\"goTo(page() - 1)\"></button>\n @for (p of links(); track p) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-page\" [class.hx-paginator-page-current]=\"p === page()\" [attr.aria-label]=\"pageLabel(p)\" [attr.aria-current]=\"p === page() ? 'page' : null\" (click)=\"goTo(p)\">{{ p + 1 }}</button>\n }\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-next\" [disabled]=\"isLast()\" [attr.aria-label]=\"nextPageLabel()\" [title]=\"nextPageLabel()\" (click)=\"goTo(page() + 1)\"></button>\n @if (showFirstLastButtons()) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-last\" [disabled]=\"isLast()\" [attr.aria-label]=\"lastPageLabel()\" [title]=\"lastPageLabel()\" (click)=\"goTo(pageCount() - 1)\"></button>\n }\n </div>\n @if (rowsOptions().length) {\n <hx-select class=\"hx-paginator-rows\" [options]=\"rowsOptions()\" [value]=\"rows()\" (valueChange)=\"setRows($event)\" [ariaLabel]=\"rowsPerPageLabel()\" />\n }\n</nav>\n",
5373
+ template: "<nav class=\"hx-paginator-nav\" [attr.aria-label]=\"ariaLabel()\">\n @if (showCurrentPageReport()) {\n <span class=\"hx-paginator-report\" aria-live=\"polite\">{{ report() }}</span>\n }\n <div class=\"hx-paginator-pages\">\n @if (showFirstLastButtons()) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-first\" [disabled]=\"isFirst()\" [attr.aria-label]=\"firstPageLabel()\" [title]=\"firstPageLabel()\" (click)=\"goTo(0)\"></button>\n }\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-prev\" [disabled]=\"isFirst()\" [attr.aria-label]=\"previousPageLabel()\" [title]=\"previousPageLabel()\" (click)=\"goTo(page() - 1)\"></button>\n @for (p of links(); track p) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-page\" [class.hx-paginator-page-current]=\"p === page()\" [attr.aria-label]=\"pageLabel(p)\" [attr.aria-current]=\"p === page() ? 'page' : null\" (click)=\"goTo(p)\">{{ p + 1 }}</button>\n }\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-next\" [disabled]=\"isLast()\" [attr.aria-label]=\"nextPageLabel()\" [title]=\"nextPageLabel()\" (click)=\"goTo(page() + 1)\"></button>\n @if (showFirstLastButtons()) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-last\" [disabled]=\"isLast()\" [attr.aria-label]=\"lastPageLabel()\" [title]=\"lastPageLabel()\" (click)=\"goTo(pageCount() - 1)\"></button>\n }\n </div>\n @if (rowsOptions().length) {\n <hx-select class=\"hx-paginator-rows\" [options]=\"rowsOptions()\" [value]=\"rowsValue()\" (valueChange)=\"setRows($event)\" [ariaLabel]=\"rowsPerPageLabel()\" />\n }\n</nav>\n",
5785
5374
  dependencies: [{
5786
5375
  kind: "component",
5787
5376
  type: HxSelect,
@@ -5826,7 +5415,7 @@ i0.ɵɵngDeclareClassMetadata({
5826
5415
  imports: [HxSelect],
5827
5416
  changeDetection: ChangeDetectionStrategy.OnPush,
5828
5417
  host: { class: "hx-paginator" },
5829
- template: "<nav class=\"hx-paginator-nav\" [attr.aria-label]=\"ariaLabel()\">\n @if (showCurrentPageReport()) {\n <span class=\"hx-paginator-report\" aria-live=\"polite\">{{ report() }}</span>\n }\n <div class=\"hx-paginator-pages\">\n @if (showFirstLastButtons()) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-first\" [disabled]=\"isFirst()\" [attr.aria-label]=\"firstPageLabel()\" [title]=\"firstPageLabel()\" (click)=\"goTo(0)\"></button>\n }\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-prev\" [disabled]=\"isFirst()\" [attr.aria-label]=\"previousPageLabel()\" [title]=\"previousPageLabel()\" (click)=\"goTo(page() - 1)\"></button>\n @for (p of links(); track p) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-page\" [class.hx-paginator-page-current]=\"p === page()\" [attr.aria-label]=\"pageLabel(p)\" [attr.aria-current]=\"p === page() ? 'page' : null\" (click)=\"goTo(p)\">{{ p + 1 }}</button>\n }\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-next\" [disabled]=\"isLast()\" [attr.aria-label]=\"nextPageLabel()\" [title]=\"nextPageLabel()\" (click)=\"goTo(page() + 1)\"></button>\n @if (showFirstLastButtons()) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-last\" [disabled]=\"isLast()\" [attr.aria-label]=\"lastPageLabel()\" [title]=\"lastPageLabel()\" (click)=\"goTo(pageCount() - 1)\"></button>\n }\n </div>\n @if (rowsOptions().length) {\n <hx-select class=\"hx-paginator-rows\" [options]=\"rowsOptions()\" [value]=\"rows()\" (valueChange)=\"setRows($event)\" [ariaLabel]=\"rowsPerPageLabel()\" />\n }\n</nav>\n"
5418
+ template: "<nav class=\"hx-paginator-nav\" [attr.aria-label]=\"ariaLabel()\">\n @if (showCurrentPageReport()) {\n <span class=\"hx-paginator-report\" aria-live=\"polite\">{{ report() }}</span>\n }\n <div class=\"hx-paginator-pages\">\n @if (showFirstLastButtons()) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-first\" [disabled]=\"isFirst()\" [attr.aria-label]=\"firstPageLabel()\" [title]=\"firstPageLabel()\" (click)=\"goTo(0)\"></button>\n }\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-prev\" [disabled]=\"isFirst()\" [attr.aria-label]=\"previousPageLabel()\" [title]=\"previousPageLabel()\" (click)=\"goTo(page() - 1)\"></button>\n @for (p of links(); track p) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-page\" [class.hx-paginator-page-current]=\"p === page()\" [attr.aria-label]=\"pageLabel(p)\" [attr.aria-current]=\"p === page() ? 'page' : null\" (click)=\"goTo(p)\">{{ p + 1 }}</button>\n }\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-next\" [disabled]=\"isLast()\" [attr.aria-label]=\"nextPageLabel()\" [title]=\"nextPageLabel()\" (click)=\"goTo(page() + 1)\"></button>\n @if (showFirstLastButtons()) {\n <button type=\"button\" class=\"hx-paginator-button hx-paginator-last\" [disabled]=\"isLast()\" [attr.aria-label]=\"lastPageLabel()\" [title]=\"lastPageLabel()\" (click)=\"goTo(pageCount() - 1)\"></button>\n }\n </div>\n @if (rowsOptions().length) {\n <hx-select class=\"hx-paginator-rows\" [options]=\"rowsOptions()\" [value]=\"rowsValue()\" (valueChange)=\"setRows($event)\" [ariaLabel]=\"rowsPerPageLabel()\" />\n }\n</nav>\n"
5830
5419
  }]
5831
5420
  }],
5832
5421
  propDecorators: {
@@ -5956,6 +5545,25 @@ i0.ɵɵngDeclareClassMetadata({
5956
5545
  required: false
5957
5546
  }]
5958
5547
  }],
5548
+ allLabel: [{
5549
+ type: i0.Input,
5550
+ args: [{
5551
+ isSignal: true,
5552
+ alias: "allLabel",
5553
+ required: false
5554
+ }]
5555
+ }],
5556
+ showAll: [{
5557
+ type: i0.Input,
5558
+ args: [{
5559
+ isSignal: true,
5560
+ alias: "showAll",
5561
+ required: false
5562
+ }]
5563
+ }, {
5564
+ type: i0.Output,
5565
+ args: ["showAllChange"]
5566
+ }],
5959
5567
  pageChange: [{
5960
5568
  type: i0.Output,
5961
5569
  args: ["pageChange"]
@@ -6298,6 +5906,54 @@ i0.ɵɵngDeclareClassMetadata({
6298
5906
  }]
6299
5907
  }] }
6300
5908
  });
5909
+ var HxColumnHeader = class HxColumnHeader {
5910
+ field = input.required({
5911
+ ...ngDevMode ? { debugName: "field" } : /* istanbul ignore next */ {},
5912
+ alias: "hxColumnHeader"
5913
+ });
5914
+ template = inject(TemplateRef);
5915
+ static ɵfac = i0.ɵɵngDeclareFactory({
5916
+ minVersion: "12.0.0",
5917
+ version: "22.2.1",
5918
+ ngImport: i0,
5919
+ type: HxColumnHeader,
5920
+ deps: [],
5921
+ target: i0.ɵɵFactoryTarget.Directive
5922
+ });
5923
+ static ɵdir = i0.ɵɵngDeclareDirective({
5924
+ minVersion: "17.1.0",
5925
+ version: "22.2.1",
5926
+ type: HxColumnHeader,
5927
+ isStandalone: true,
5928
+ selector: "ng-template[hxColumnHeader]",
5929
+ inputs: { field: {
5930
+ classPropertyName: "field",
5931
+ publicName: "hxColumnHeader",
5932
+ isSignal: true,
5933
+ isRequired: true,
5934
+ transformFunction: null
5935
+ } },
5936
+ ngImport: i0
5937
+ });
5938
+ };
5939
+ i0.ɵɵngDeclareClassMetadata({
5940
+ minVersion: "12.0.0",
5941
+ version: "22.2.1",
5942
+ ngImport: i0,
5943
+ type: HxColumnHeader,
5944
+ decorators: [{
5945
+ type: Directive,
5946
+ args: [{ selector: "ng-template[hxColumnHeader]" }]
5947
+ }],
5948
+ propDecorators: { field: [{
5949
+ type: i0.Input,
5950
+ args: [{
5951
+ isSignal: true,
5952
+ alias: "hxColumnHeader",
5953
+ required: true
5954
+ }]
5955
+ }] }
5956
+ });
6301
5957
  var HxTableHeader = class HxTableHeader {
6302
5958
  template = inject(TemplateRef);
6303
5959
  static ɵfac = i0.ɵɵngDeclareFactory({
@@ -6490,6 +6146,9 @@ var HxDataTable = class HxDataTable {
6490
6146
  transform: booleanAttribute
6491
6147
  });
6492
6148
  emptyMessage = input("No records found", ...ngDevMode ? [{ debugName: "emptyMessage" }] : /* istanbul ignore next */ []);
6149
+ rowClass = input(...ngDevMode ? [void 0, { debugName: "rowClass" }] : /* istanbul ignore next */ []);
6150
+ emptyValue = input("", ...ngDevMode ? [{ debugName: "emptyValue" }] : /* istanbul ignore next */ []);
6151
+ allLabel = input("All", ...ngDevMode ? [{ debugName: "allLabel" }] : /* istanbul ignore next */ []);
6493
6152
  loading = input(false, {
6494
6153
  ...ngDevMode ? { debugName: "loading" } : /* istanbul ignore next */ {},
6495
6154
  transform: booleanAttribute
@@ -6506,6 +6165,7 @@ var HxDataTable = class HxDataTable {
6506
6165
  sortOrder = model(1, ...ngDevMode ? [{ debugName: "sortOrder" }] : /* istanbul ignore next */ []);
6507
6166
  multiSortMeta = model([], ...ngDevMode ? [{ debugName: "multiSortMeta" }] : /* istanbul ignore next */ []);
6508
6167
  sortFunction = input(...ngDevMode ? [void 0, { debugName: "sortFunction" }] : /* istanbul ignore next */ []);
6168
+ sortFirstOrder = input("asc", ...ngDevMode ? [{ debugName: "sortFirstOrder" }] : /* istanbul ignore next */ []);
6509
6169
  paginator = input(false, {
6510
6170
  ...ngDevMode ? { debugName: "paginator" } : /* istanbul ignore next */ {},
6511
6171
  transform: booleanAttribute
@@ -6544,7 +6204,14 @@ var HxDataTable = class HxDataTable {
6544
6204
  collapseLabel = input("Collapse row", ...ngDevMode ? [{ debugName: "collapseLabel" }] : /* istanbul ignore next */ []);
6545
6205
  announcement = signal("", ...ngDevMode ? [{ debugName: "announcement" }] : /* istanbul ignore next */ []);
6546
6206
  globalText = signal("", ...ngDevMode ? [{ debugName: "globalText" }] : /* istanbul ignore next */ []);
6207
+ showAll = signal(false, ...ngDevMode ? [{ debugName: "showAll" }] : /* istanbul ignore next */ []);
6208
+ resetAll = effect(() => {
6209
+ this.rows();
6210
+ untracked(() => this.showAll.set(false));
6211
+ }, ...ngDevMode ? [{ debugName: "resetAll" }] : /* istanbul ignore next */ []);
6212
+ allActive = computed(() => this.showAll() && !!this.rowsPerPageOptions()?.includes("all"), ...ngDevMode ? [{ debugName: "allActive" }] : /* istanbul ignore next */ []);
6547
6213
  cellTemplates = contentChildren(HxCell, ...ngDevMode ? [{ debugName: "cellTemplates" }] : /* istanbul ignore next */ []);
6214
+ columnHeaderTemplates = contentChildren(HxColumnHeader, ...ngDevMode ? [{ debugName: "columnHeaderTemplates" }] : /* istanbul ignore next */ []);
6548
6215
  headerTemplate = contentChild(HxTableHeader, ...ngDevMode ? [{ debugName: "headerTemplate" }] : /* istanbul ignore next */ []);
6549
6216
  bodyTemplate = contentChild(HxTableBody, ...ngDevMode ? [{ debugName: "bodyTemplate" }] : /* istanbul ignore next */ []);
6550
6217
  footerTemplate = contentChild(HxTableFooter, ...ngDevMode ? [{ debugName: "footerTemplate" }] : /* istanbul ignore next */ []);
@@ -6582,10 +6249,23 @@ var HxDataTable = class HxDataTable {
6582
6249
  total = computed(() => this.lazy() ? this.totalRecords() ?? this.value().length : this.sorted().length, ...ngDevMode ? [{ debugName: "total" }] : /* istanbul ignore next */ []);
6583
6250
  visibleRows = computed(() => {
6584
6251
  const rows = this.sorted();
6585
- if (!this.paginator() || this.lazy()) return rows;
6252
+ if (!this.paginator() || this.lazy() || this.allActive()) return rows;
6586
6253
  return rows.slice(this.first(), this.first() + this.rows());
6587
6254
  }, ...ngDevMode ? [{ debugName: "visibleRows" }] : /* istanbul ignore next */ []);
6588
6255
  cells = computed(() => new Map(this.cellTemplates().map((cell) => [cell.field(), cell.template])), ...ngDevMode ? [{ debugName: "cells" }] : /* istanbul ignore next */ []);
6256
+ warnedFields = /* @__PURE__ */ new Set();
6257
+ columnHeaders = computed(() => {
6258
+ const map = /* @__PURE__ */ new Map();
6259
+ for (const header of this.columnHeaderTemplates()) {
6260
+ const field = header.field();
6261
+ if (map.has(field) && isDevMode() && !this.warnedFields.has(field)) {
6262
+ this.warnedFields.add(field);
6263
+ console.warn(`hx-data-table: more than one hxColumnHeader template for "${field}"; the last one wins.`);
6264
+ }
6265
+ map.set(field, header.template);
6266
+ }
6267
+ return map;
6268
+ }, ...ngDevMode ? [{ debugName: "columnHeaders" }] : /* istanbul ignore next */ []);
6589
6269
  scrolls = computed(() => this.scrollable() || !!this.scrollHeight(), ...ngDevMode ? [{ debugName: "scrolls" }] : /* istanbul ignore next */ []);
6590
6270
  hasCaption = computed(() => !!this.caption() || !!this.captionTemplate() || !!this.ariaLabel(), ...ngDevMode ? [{ debugName: "hasCaption" }] : /* istanbul ignore next */ []);
6591
6271
  captionHidden = computed(() => !this.caption() && !this.captionTemplate(), ...ngDevMode ? [{ debugName: "captionHidden" }] : /* istanbul ignore next */ []);
@@ -6682,7 +6362,8 @@ var HxDataTable = class HxDataTable {
6682
6362
  }
6683
6363
  sort(column) {
6684
6364
  const order = this.orderOf(column);
6685
- const next = order === 0 ? 1 : order === 1 ? -1 : 0;
6365
+ const firstOrder = (column.sortFirstOrder ?? this.sortFirstOrder()) === "desc" ? -1 : 1;
6366
+ const next = order === 0 ? firstOrder : order === firstOrder ? -firstOrder : 0;
6686
6367
  if (this.sortMode() === "multiple") {
6687
6368
  const rest = this.multiSortMeta().filter((m) => m.field !== column.field);
6688
6369
  this.multiSortMeta.set(next === 0 ? rest : order === 0 ? [...rest, {
@@ -6702,13 +6383,13 @@ var HxDataTable = class HxDataTable {
6702
6383
  }
6703
6384
  onPage(event) {
6704
6385
  this.first.set(event.first);
6705
- this.rows.set(event.rows);
6386
+ if (!event.all) this.rows.set(event.rows);
6706
6387
  if (this.lazy()) this.emitLazy();
6707
6388
  }
6708
6389
  emitLazy() {
6709
6390
  this.lazyLoad.emit({
6710
6391
  first: this.first(),
6711
- rows: this.rows(),
6392
+ rows: this.allActive() && this.total() > 0 ? this.total() : this.rows(),
6712
6393
  sortField: this.sortMode() === "multiple" ? this.multiSortMeta()[0]?.field ?? null : this.sortField(),
6713
6394
  sortOrder: this.sortMode() === "multiple" ? this.multiSortMeta()[0]?.order ?? 1 : this.sortOrder(),
6714
6395
  multiSortMeta: this.sortMode() === "multiple" ? this.multiSortMeta() : this.sortMeta(),
@@ -6720,6 +6401,9 @@ var HxDataTable = class HxDataTable {
6720
6401
  const key = this.dataKey();
6721
6402
  return key ? resolveField(row, key) ?? index : index;
6722
6403
  }
6404
+ rowClassOf(row) {
6405
+ return this.rowClass()?.(row);
6406
+ }
6723
6407
  valueOf(row, column) {
6724
6408
  return resolveField(row, column.field);
6725
6409
  }
@@ -6794,6 +6478,27 @@ var HxDataTable = class HxDataTable {
6794
6478
  isRequired: false,
6795
6479
  transformFunction: null
6796
6480
  },
6481
+ rowClass: {
6482
+ classPropertyName: "rowClass",
6483
+ publicName: "rowClass",
6484
+ isSignal: true,
6485
+ isRequired: false,
6486
+ transformFunction: null
6487
+ },
6488
+ emptyValue: {
6489
+ classPropertyName: "emptyValue",
6490
+ publicName: "emptyValue",
6491
+ isSignal: true,
6492
+ isRequired: false,
6493
+ transformFunction: null
6494
+ },
6495
+ allLabel: {
6496
+ classPropertyName: "allLabel",
6497
+ publicName: "allLabel",
6498
+ isSignal: true,
6499
+ isRequired: false,
6500
+ transformFunction: null
6501
+ },
6797
6502
  loading: {
6798
6503
  classPropertyName: "loading",
6799
6504
  publicName: "loading",
@@ -6864,6 +6569,13 @@ var HxDataTable = class HxDataTable {
6864
6569
  isRequired: false,
6865
6570
  transformFunction: null
6866
6571
  },
6572
+ sortFirstOrder: {
6573
+ classPropertyName: "sortFirstOrder",
6574
+ publicName: "sortFirstOrder",
6575
+ isSignal: true,
6576
+ isRequired: false,
6577
+ transformFunction: null
6578
+ },
6867
6579
  paginator: {
6868
6580
  classPropertyName: "paginator",
6869
6581
  publicName: "paginator",
@@ -7023,6 +6735,11 @@ var HxDataTable = class HxDataTable {
7023
6735
  predicate: HxCell,
7024
6736
  isSignal: true
7025
6737
  },
6738
+ {
6739
+ propertyName: "columnHeaderTemplates",
6740
+ predicate: HxColumnHeader,
6741
+ isSignal: true
6742
+ },
7026
6743
  {
7027
6744
  propertyName: "headerTemplate",
7028
6745
  first: true,
@@ -7067,7 +6784,7 @@ var HxDataTable = class HxDataTable {
7067
6784
  }
7068
6785
  ],
7069
6786
  ngImport: i0,
7070
- template: "<div class=\"hx-data-table-frame\" [attr.aria-busy]=\"loading() ? 'true' : null\">\n <div\n class=\"hx-table-scroll hx-data-table-scroll\"\n [class.hx-data-table-scrolls]=\"scrolls()\"\n [style.max-height]=\"scrollHeight() ?? null\"\n [attr.role]=\"scrolls() ? 'region' : null\"\n [attr.aria-label]=\"scrolls() ? (ariaLabel() ?? caption() ?? null) : null\"\n [attr.tabindex]=\"scrolls() ? 0 : null\"\n >\n <table\n class=\"hx-table\"\n [class.hx-table-sm]=\"size() === 'small'\"\n [class.hx-table-lg]=\"size() === 'large'\"\n [class.hx-table-striped]=\"stripedRows()\"\n [class.hx-table-gridlines]=\"showGridlines()\"\n [class.hx-table-hoverable]=\"hoverRows()\"\n [class.hx-table-sticky]=\"!!scrollHeight()\"\n >\n @if (hasCaption()) {\n <caption [class.hx-data-table-caption-hidden]=\"captionHidden()\">\n @if (captionTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" />\n } @else {\n {{ caption() ?? ariaLabel() }}\n }\n </caption>\n }\n <thead>\n <tr>\n @if (expanderColumn()) {\n <th scope=\"col\" class=\"hx-data-table-expander-cell\"><span class=\"hx-data-table-caption-hidden\">Row details</span></th>\n }\n @if (checkboxColumn()) {\n <th scope=\"col\" class=\"hx-data-table-select-cell\">\n <input type=\"checkbox\" hx-checkbox [attr.aria-label]=\"selectAllLabel()\" [checked]=\"allSelected()\" [indeterminate]=\"someSelected()\" (change)=\"toggleSelectAll($any($event.target).checked)\" />\n </th>\n }\n @if (headerTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: columns() }\" />\n } @else {\n @for (column of columns(); track column.field) {\n <th\n scope=\"col\"\n [class]=\"'hx-data-table-align-' + (column.align ?? 'left')\"\n [class.hx-data-table-sorted]=\"orderOf(column) !== 0\"\n [style.width]=\"column.width ?? null\"\n [attr.aria-sort]=\"ariaSort(column)\"\n >\n @if (column.sortable) {\n <button type=\"button\" class=\"hx-data-table-sort\" (click)=\"sort(column)\">\n <span>{{ column.header }}</span>\n <span class=\"hx-data-table-sort-icon\" [class.hx-data-table-sort-asc]=\"orderOf(column) === 1\" [class.hx-data-table-sort-desc]=\"orderOf(column) === -1\" aria-hidden=\"true\"></span>\n @if (sortRank(column); as rank) {\n <span class=\"hx-data-table-sort-rank\" aria-hidden=\"true\">{{ rank }}</span>\n }\n </button>\n } @else {\n {{ column.header }}\n }\n </th>\n }\n }\n </tr>\n @if (filterRow()) {\n <tr class=\"hx-data-table-filter-row\">\n @if (expanderColumn()) { <th></th> }\n @if (checkboxColumn()) { <th></th> }\n @for (column of columns(); track column.field) {\n <th>\n @if (column.filter) {\n <input type=\"text\" hx-input size=\"small\" fluid [attr.aria-label]=\"filterLabel().replace('{header}', column.header)\" [value]=\"filters()[column.field] ?? ''\" (input)=\"setFilter(column, $any($event.target).value)\" />\n }\n </th>\n }\n </tr>\n }\n </thead>\n <tbody>\n @for (row of visibleRows(); track trackRow(row, $index); let i = $index) {\n <tr\n [class.hx-data-table-selectable]=\"selectable()\"\n [attr.aria-selected]=\"selectionMode() ? (isSelected(row) ? 'true' : 'false') : null\"\n [attr.tabindex]=\"selectable() ? 0 : null\"\n (click)=\"selectRow(row, $event)\"\n (keydown.enter)=\"onRowKey(row, $event)\"\n (keydown.space)=\"onRowKey(row, $event)\"\n >\n @if (expanderColumn()) {\n <td class=\"hx-data-table-expander-cell\">\n <button type=\"button\" class=\"hx-data-table-expander\" [class.hx-data-table-expander-open]=\"isExpanded(row, i)\" [attr.aria-expanded]=\"isExpanded(row, i)\" [attr.aria-label]=\"isExpanded(row, i) ? collapseLabel() : expandLabel()\" (click)=\"toggleExpansion(row, i)\"></button>\n </td>\n }\n @if (checkboxColumn()) {\n <td class=\"hx-data-table-select-cell\">\n <input type=\"checkbox\" hx-checkbox [attr.aria-label]=\"selectRowLabel().replace('{row}', '' + (first() + i + 1))\" [checked]=\"isSelected(row)\" (change)=\"toggleRowCheckbox(row, $any($event.target).checked)\" />\n </td>\n }\n @if (bodyTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: row, index: i, columns: columns() }\" />\n } @else {\n @for (column of columns(); track column.field) {\n <td [class]=\"'hx-data-table-align-' + (column.align ?? 'left')\">\n @if (cells().get(column.field); as cell) {\n <ng-container [ngTemplateOutlet]=\"cell\" [ngTemplateOutletContext]=\"{ $implicit: row, value: valueOf(row, column), index: i }\" />\n } @else {\n {{ valueOf(row, column) }}\n }\n </td>\n }\n }\n </tr>\n @if (expansionTemplate(); as tpl) {\n @if (isExpanded(row, i)) {\n <tr class=\"hx-data-table-expansion\">\n <td [attr.colspan]=\"colspan()\">\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: row, index: i, columns: columns() }\" />\n </td>\n </tr>\n }\n }\n } @empty {\n <tr class=\"hx-data-table-empty\">\n <td [attr.colspan]=\"colspan()\">\n @if (emptyTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" />\n } @else {\n {{ emptyMessage() }}\n }\n </td>\n </tr>\n }\n </tbody>\n @if (footerTemplate(); as tpl) {\n <tfoot>\n <tr>\n @if (expanderColumn()) { <td></td> }\n @if (checkboxColumn()) { <td></td> }\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: columns() }\" />\n </tr>\n </tfoot>\n }\n </table>\n </div>\n <span class=\"hx-data-table-caption-hidden\" aria-live=\"polite\">{{ announcement() }}</span>\n @if (loading()) {\n <div class=\"hx-data-table-loading\" role=\"status\">\n <hx-progress-spinner ariaLabel=\"Loading\" />\n </div>\n }\n @if (paginator()) {\n <hx-paginator\n class=\"hx-data-table-paginator\"\n [rows]=\"rows()\"\n [first]=\"first()\"\n [totalRecords]=\"total()\"\n [rowsPerPageOptions]=\"rowsPerPageOptions()\"\n [showCurrentPageReport]=\"showCurrentPageReport()\"\n (pageChange)=\"onPage($event)\"\n />\n }\n</div>\n",
6787
+ template: "<div class=\"hx-data-table-frame\" [attr.aria-busy]=\"loading() ? 'true' : null\">\n <div\n class=\"hx-table-scroll hx-data-table-scroll\"\n [class.hx-data-table-scrolls]=\"scrolls()\"\n [style.max-height]=\"scrollHeight() ?? null\"\n [attr.role]=\"scrolls() ? 'region' : null\"\n [attr.aria-label]=\"scrolls() ? (ariaLabel() ?? caption() ?? null) : null\"\n [attr.tabindex]=\"scrolls() ? 0 : null\"\n >\n <table\n class=\"hx-table\"\n [class.hx-table-sm]=\"size() === 'small'\"\n [class.hx-table-lg]=\"size() === 'large'\"\n [class.hx-table-striped]=\"stripedRows()\"\n [class.hx-table-gridlines]=\"showGridlines()\"\n [class.hx-table-hoverable]=\"hoverRows()\"\n [class.hx-table-sticky]=\"!!scrollHeight()\"\n >\n @if (hasCaption()) {\n <caption [class.hx-data-table-caption-hidden]=\"captionHidden()\">\n @if (captionTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" />\n } @else {\n {{ caption() ?? ariaLabel() }}\n }\n </caption>\n }\n <thead>\n <tr>\n @if (expanderColumn()) {\n <th scope=\"col\" class=\"hx-data-table-expander-cell\"><span class=\"hx-data-table-caption-hidden\">Row details</span></th>\n }\n @if (checkboxColumn()) {\n <th scope=\"col\" class=\"hx-data-table-select-cell\">\n <input type=\"checkbox\" hx-checkbox [attr.aria-label]=\"selectAllLabel()\" [checked]=\"allSelected()\" [indeterminate]=\"someSelected()\" (change)=\"toggleSelectAll($any($event.target).checked)\" />\n </th>\n }\n @if (headerTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: columns() }\" />\n } @else {\n @for (column of columns(); track column.field) {\n <th\n scope=\"col\"\n [class]=\"'hx-data-table-align-' + (column.align ?? 'left')\"\n [class.hx-data-table-sorted]=\"orderOf(column) !== 0\"\n [style.width]=\"column.width ?? null\"\n [attr.aria-sort]=\"ariaSort(column)\"\n [attr.title]=\"column.title ?? null\"\n >\n @if (columnHeaders().get(column.field); as extra) {\n <div class=\"hx-data-table-header-content\">\n <ng-container [ngTemplateOutlet]=\"label\" [ngTemplateOutletContext]=\"{ $implicit: column }\" />\n <ng-container [ngTemplateOutlet]=\"extra\" [ngTemplateOutletContext]=\"{ $implicit: column }\" />\n </div>\n } @else {\n <ng-container [ngTemplateOutlet]=\"label\" [ngTemplateOutletContext]=\"{ $implicit: column }\" />\n }\n </th>\n }\n }\n </tr>\n @if (filterRow()) {\n <tr class=\"hx-data-table-filter-row\">\n @if (expanderColumn()) { <th></th> }\n @if (checkboxColumn()) { <th></th> }\n @for (column of columns(); track column.field) {\n <th>\n @if (column.filter) {\n <input type=\"text\" hx-input size=\"small\" fluid [attr.aria-label]=\"filterLabel().replace('{header}', column.header)\" [value]=\"filters()[column.field] ?? ''\" (input)=\"setFilter(column, $any($event.target).value)\" />\n }\n </th>\n }\n </tr>\n }\n </thead>\n <tbody>\n @for (row of visibleRows(); track trackRow(row, $index); let i = $index) {\n <tr\n [class]=\"rowClassOf(row)\"\n [class.hx-data-table-selectable]=\"selectable()\"\n [attr.aria-selected]=\"selectionMode() ? (isSelected(row) ? 'true' : 'false') : null\"\n [attr.tabindex]=\"selectable() ? 0 : null\"\n (click)=\"selectRow(row, $event)\"\n (keydown.enter)=\"onRowKey(row, $event)\"\n (keydown.space)=\"onRowKey(row, $event)\"\n >\n @if (expanderColumn()) {\n <td class=\"hx-data-table-expander-cell\">\n <button type=\"button\" class=\"hx-data-table-expander\" [class.hx-data-table-expander-open]=\"isExpanded(row, i)\" [attr.aria-expanded]=\"isExpanded(row, i)\" [attr.aria-label]=\"isExpanded(row, i) ? collapseLabel() : expandLabel()\" (click)=\"toggleExpansion(row, i)\"></button>\n </td>\n }\n @if (checkboxColumn()) {\n <td class=\"hx-data-table-select-cell\">\n <input type=\"checkbox\" hx-checkbox [attr.aria-label]=\"selectRowLabel().replace('{row}', '' + (first() + i + 1))\" [checked]=\"isSelected(row)\" (change)=\"toggleRowCheckbox(row, $any($event.target).checked)\" />\n </td>\n }\n @if (bodyTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: row, index: i, columns: columns() }\" />\n } @else {\n @for (column of columns(); track column.field) {\n <td [class]=\"'hx-data-table-align-' + (column.align ?? 'left')\">\n @if (cells().get(column.field); as cell) {\n <ng-container [ngTemplateOutlet]=\"cell\" [ngTemplateOutletContext]=\"{ $implicit: row, value: valueOf(row, column), index: i }\" />\n } @else {\n {{ valueOf(row, column) ?? emptyValue() }}\n }\n </td>\n }\n }\n </tr>\n @if (expansionTemplate(); as tpl) {\n @if (isExpanded(row, i)) {\n <tr class=\"hx-data-table-expansion\">\n <td [attr.colspan]=\"colspan()\">\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: row, index: i, columns: columns() }\" />\n </td>\n </tr>\n }\n }\n } @empty {\n <tr class=\"hx-data-table-empty\">\n <td [attr.colspan]=\"colspan()\">\n @if (emptyTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" />\n } @else {\n {{ emptyMessage() }}\n }\n </td>\n </tr>\n }\n </tbody>\n @if (footerTemplate(); as tpl) {\n <tfoot>\n <tr>\n @if (expanderColumn()) { <td></td> }\n @if (checkboxColumn()) { <td></td> }\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: columns() }\" />\n </tr>\n </tfoot>\n }\n </table>\n </div>\n <span class=\"hx-data-table-caption-hidden\" aria-live=\"polite\">{{ announcement() }}</span>\n @if (loading()) {\n <div class=\"hx-data-table-loading\" role=\"status\">\n <hx-progress-spinner ariaLabel=\"Loading\" />\n </div>\n }\n @if (paginator()) {\n <hx-paginator\n class=\"hx-data-table-paginator\"\n [rows]=\"rows()\"\n [first]=\"first()\"\n [totalRecords]=\"total()\"\n [rowsPerPageOptions]=\"rowsPerPageOptions()\"\n [showAll]=\"showAll()\"\n (showAllChange)=\"showAll.set($event)\"\n [allLabel]=\"allLabel()\"\n [showCurrentPageReport]=\"showCurrentPageReport()\"\n (pageChange)=\"onPage($event)\"\n />\n }\n</div>\n\n<ng-template #label let-column>\n @if (column.sortable) {\n <button type=\"button\" class=\"hx-data-table-sort\" (click)=\"sort(column)\">\n <span>{{ column.header }}</span>\n <span class=\"hx-data-table-sort-icon\" [class.hx-data-table-sort-asc]=\"orderOf(column) === 1\" [class.hx-data-table-sort-desc]=\"orderOf(column) === -1\" aria-hidden=\"true\"></span>\n @if (sortRank(column); as rank) {\n <span class=\"hx-data-table-sort-rank\" aria-hidden=\"true\">{{ rank }}</span>\n }\n </button>\n } @else {\n {{ column.header }}\n }\n</ng-template>\n",
7071
6788
  dependencies: [
7072
6789
  {
7073
6790
  kind: "directive",
@@ -7108,11 +6825,14 @@ var HxDataTable = class HxDataTable {
7108
6825
  "nextPageLabel",
7109
6826
  "lastPageLabel",
7110
6827
  "pageLabelTemplate",
7111
- "rowsPerPageLabel"
6828
+ "rowsPerPageLabel",
6829
+ "allLabel",
6830
+ "showAll"
7112
6831
  ],
7113
6832
  outputs: [
7114
6833
  "rowsChange",
7115
6834
  "firstChange",
6835
+ "showAllChange",
7116
6836
  "pageChange"
7117
6837
  ]
7118
6838
  },
@@ -7157,7 +6877,7 @@ i0.ɵɵngDeclareClassMetadata({
7157
6877
  ],
7158
6878
  changeDetection: ChangeDetectionStrategy.OnPush,
7159
6879
  host: { class: "hx-data-table" },
7160
- template: "<div class=\"hx-data-table-frame\" [attr.aria-busy]=\"loading() ? 'true' : null\">\n <div\n class=\"hx-table-scroll hx-data-table-scroll\"\n [class.hx-data-table-scrolls]=\"scrolls()\"\n [style.max-height]=\"scrollHeight() ?? null\"\n [attr.role]=\"scrolls() ? 'region' : null\"\n [attr.aria-label]=\"scrolls() ? (ariaLabel() ?? caption() ?? null) : null\"\n [attr.tabindex]=\"scrolls() ? 0 : null\"\n >\n <table\n class=\"hx-table\"\n [class.hx-table-sm]=\"size() === 'small'\"\n [class.hx-table-lg]=\"size() === 'large'\"\n [class.hx-table-striped]=\"stripedRows()\"\n [class.hx-table-gridlines]=\"showGridlines()\"\n [class.hx-table-hoverable]=\"hoverRows()\"\n [class.hx-table-sticky]=\"!!scrollHeight()\"\n >\n @if (hasCaption()) {\n <caption [class.hx-data-table-caption-hidden]=\"captionHidden()\">\n @if (captionTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" />\n } @else {\n {{ caption() ?? ariaLabel() }}\n }\n </caption>\n }\n <thead>\n <tr>\n @if (expanderColumn()) {\n <th scope=\"col\" class=\"hx-data-table-expander-cell\"><span class=\"hx-data-table-caption-hidden\">Row details</span></th>\n }\n @if (checkboxColumn()) {\n <th scope=\"col\" class=\"hx-data-table-select-cell\">\n <input type=\"checkbox\" hx-checkbox [attr.aria-label]=\"selectAllLabel()\" [checked]=\"allSelected()\" [indeterminate]=\"someSelected()\" (change)=\"toggleSelectAll($any($event.target).checked)\" />\n </th>\n }\n @if (headerTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: columns() }\" />\n } @else {\n @for (column of columns(); track column.field) {\n <th\n scope=\"col\"\n [class]=\"'hx-data-table-align-' + (column.align ?? 'left')\"\n [class.hx-data-table-sorted]=\"orderOf(column) !== 0\"\n [style.width]=\"column.width ?? null\"\n [attr.aria-sort]=\"ariaSort(column)\"\n >\n @if (column.sortable) {\n <button type=\"button\" class=\"hx-data-table-sort\" (click)=\"sort(column)\">\n <span>{{ column.header }}</span>\n <span class=\"hx-data-table-sort-icon\" [class.hx-data-table-sort-asc]=\"orderOf(column) === 1\" [class.hx-data-table-sort-desc]=\"orderOf(column) === -1\" aria-hidden=\"true\"></span>\n @if (sortRank(column); as rank) {\n <span class=\"hx-data-table-sort-rank\" aria-hidden=\"true\">{{ rank }}</span>\n }\n </button>\n } @else {\n {{ column.header }}\n }\n </th>\n }\n }\n </tr>\n @if (filterRow()) {\n <tr class=\"hx-data-table-filter-row\">\n @if (expanderColumn()) { <th></th> }\n @if (checkboxColumn()) { <th></th> }\n @for (column of columns(); track column.field) {\n <th>\n @if (column.filter) {\n <input type=\"text\" hx-input size=\"small\" fluid [attr.aria-label]=\"filterLabel().replace('{header}', column.header)\" [value]=\"filters()[column.field] ?? ''\" (input)=\"setFilter(column, $any($event.target).value)\" />\n }\n </th>\n }\n </tr>\n }\n </thead>\n <tbody>\n @for (row of visibleRows(); track trackRow(row, $index); let i = $index) {\n <tr\n [class.hx-data-table-selectable]=\"selectable()\"\n [attr.aria-selected]=\"selectionMode() ? (isSelected(row) ? 'true' : 'false') : null\"\n [attr.tabindex]=\"selectable() ? 0 : null\"\n (click)=\"selectRow(row, $event)\"\n (keydown.enter)=\"onRowKey(row, $event)\"\n (keydown.space)=\"onRowKey(row, $event)\"\n >\n @if (expanderColumn()) {\n <td class=\"hx-data-table-expander-cell\">\n <button type=\"button\" class=\"hx-data-table-expander\" [class.hx-data-table-expander-open]=\"isExpanded(row, i)\" [attr.aria-expanded]=\"isExpanded(row, i)\" [attr.aria-label]=\"isExpanded(row, i) ? collapseLabel() : expandLabel()\" (click)=\"toggleExpansion(row, i)\"></button>\n </td>\n }\n @if (checkboxColumn()) {\n <td class=\"hx-data-table-select-cell\">\n <input type=\"checkbox\" hx-checkbox [attr.aria-label]=\"selectRowLabel().replace('{row}', '' + (first() + i + 1))\" [checked]=\"isSelected(row)\" (change)=\"toggleRowCheckbox(row, $any($event.target).checked)\" />\n </td>\n }\n @if (bodyTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: row, index: i, columns: columns() }\" />\n } @else {\n @for (column of columns(); track column.field) {\n <td [class]=\"'hx-data-table-align-' + (column.align ?? 'left')\">\n @if (cells().get(column.field); as cell) {\n <ng-container [ngTemplateOutlet]=\"cell\" [ngTemplateOutletContext]=\"{ $implicit: row, value: valueOf(row, column), index: i }\" />\n } @else {\n {{ valueOf(row, column) }}\n }\n </td>\n }\n }\n </tr>\n @if (expansionTemplate(); as tpl) {\n @if (isExpanded(row, i)) {\n <tr class=\"hx-data-table-expansion\">\n <td [attr.colspan]=\"colspan()\">\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: row, index: i, columns: columns() }\" />\n </td>\n </tr>\n }\n }\n } @empty {\n <tr class=\"hx-data-table-empty\">\n <td [attr.colspan]=\"colspan()\">\n @if (emptyTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" />\n } @else {\n {{ emptyMessage() }}\n }\n </td>\n </tr>\n }\n </tbody>\n @if (footerTemplate(); as tpl) {\n <tfoot>\n <tr>\n @if (expanderColumn()) { <td></td> }\n @if (checkboxColumn()) { <td></td> }\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: columns() }\" />\n </tr>\n </tfoot>\n }\n </table>\n </div>\n <span class=\"hx-data-table-caption-hidden\" aria-live=\"polite\">{{ announcement() }}</span>\n @if (loading()) {\n <div class=\"hx-data-table-loading\" role=\"status\">\n <hx-progress-spinner ariaLabel=\"Loading\" />\n </div>\n }\n @if (paginator()) {\n <hx-paginator\n class=\"hx-data-table-paginator\"\n [rows]=\"rows()\"\n [first]=\"first()\"\n [totalRecords]=\"total()\"\n [rowsPerPageOptions]=\"rowsPerPageOptions()\"\n [showCurrentPageReport]=\"showCurrentPageReport()\"\n (pageChange)=\"onPage($event)\"\n />\n }\n</div>\n"
6880
+ template: "<div class=\"hx-data-table-frame\" [attr.aria-busy]=\"loading() ? 'true' : null\">\n <div\n class=\"hx-table-scroll hx-data-table-scroll\"\n [class.hx-data-table-scrolls]=\"scrolls()\"\n [style.max-height]=\"scrollHeight() ?? null\"\n [attr.role]=\"scrolls() ? 'region' : null\"\n [attr.aria-label]=\"scrolls() ? (ariaLabel() ?? caption() ?? null) : null\"\n [attr.tabindex]=\"scrolls() ? 0 : null\"\n >\n <table\n class=\"hx-table\"\n [class.hx-table-sm]=\"size() === 'small'\"\n [class.hx-table-lg]=\"size() === 'large'\"\n [class.hx-table-striped]=\"stripedRows()\"\n [class.hx-table-gridlines]=\"showGridlines()\"\n [class.hx-table-hoverable]=\"hoverRows()\"\n [class.hx-table-sticky]=\"!!scrollHeight()\"\n >\n @if (hasCaption()) {\n <caption [class.hx-data-table-caption-hidden]=\"captionHidden()\">\n @if (captionTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" />\n } @else {\n {{ caption() ?? ariaLabel() }}\n }\n </caption>\n }\n <thead>\n <tr>\n @if (expanderColumn()) {\n <th scope=\"col\" class=\"hx-data-table-expander-cell\"><span class=\"hx-data-table-caption-hidden\">Row details</span></th>\n }\n @if (checkboxColumn()) {\n <th scope=\"col\" class=\"hx-data-table-select-cell\">\n <input type=\"checkbox\" hx-checkbox [attr.aria-label]=\"selectAllLabel()\" [checked]=\"allSelected()\" [indeterminate]=\"someSelected()\" (change)=\"toggleSelectAll($any($event.target).checked)\" />\n </th>\n }\n @if (headerTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: columns() }\" />\n } @else {\n @for (column of columns(); track column.field) {\n <th\n scope=\"col\"\n [class]=\"'hx-data-table-align-' + (column.align ?? 'left')\"\n [class.hx-data-table-sorted]=\"orderOf(column) !== 0\"\n [style.width]=\"column.width ?? null\"\n [attr.aria-sort]=\"ariaSort(column)\"\n [attr.title]=\"column.title ?? null\"\n >\n @if (columnHeaders().get(column.field); as extra) {\n <div class=\"hx-data-table-header-content\">\n <ng-container [ngTemplateOutlet]=\"label\" [ngTemplateOutletContext]=\"{ $implicit: column }\" />\n <ng-container [ngTemplateOutlet]=\"extra\" [ngTemplateOutletContext]=\"{ $implicit: column }\" />\n </div>\n } @else {\n <ng-container [ngTemplateOutlet]=\"label\" [ngTemplateOutletContext]=\"{ $implicit: column }\" />\n }\n </th>\n }\n }\n </tr>\n @if (filterRow()) {\n <tr class=\"hx-data-table-filter-row\">\n @if (expanderColumn()) { <th></th> }\n @if (checkboxColumn()) { <th></th> }\n @for (column of columns(); track column.field) {\n <th>\n @if (column.filter) {\n <input type=\"text\" hx-input size=\"small\" fluid [attr.aria-label]=\"filterLabel().replace('{header}', column.header)\" [value]=\"filters()[column.field] ?? ''\" (input)=\"setFilter(column, $any($event.target).value)\" />\n }\n </th>\n }\n </tr>\n }\n </thead>\n <tbody>\n @for (row of visibleRows(); track trackRow(row, $index); let i = $index) {\n <tr\n [class]=\"rowClassOf(row)\"\n [class.hx-data-table-selectable]=\"selectable()\"\n [attr.aria-selected]=\"selectionMode() ? (isSelected(row) ? 'true' : 'false') : null\"\n [attr.tabindex]=\"selectable() ? 0 : null\"\n (click)=\"selectRow(row, $event)\"\n (keydown.enter)=\"onRowKey(row, $event)\"\n (keydown.space)=\"onRowKey(row, $event)\"\n >\n @if (expanderColumn()) {\n <td class=\"hx-data-table-expander-cell\">\n <button type=\"button\" class=\"hx-data-table-expander\" [class.hx-data-table-expander-open]=\"isExpanded(row, i)\" [attr.aria-expanded]=\"isExpanded(row, i)\" [attr.aria-label]=\"isExpanded(row, i) ? collapseLabel() : expandLabel()\" (click)=\"toggleExpansion(row, i)\"></button>\n </td>\n }\n @if (checkboxColumn()) {\n <td class=\"hx-data-table-select-cell\">\n <input type=\"checkbox\" hx-checkbox [attr.aria-label]=\"selectRowLabel().replace('{row}', '' + (first() + i + 1))\" [checked]=\"isSelected(row)\" (change)=\"toggleRowCheckbox(row, $any($event.target).checked)\" />\n </td>\n }\n @if (bodyTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: row, index: i, columns: columns() }\" />\n } @else {\n @for (column of columns(); track column.field) {\n <td [class]=\"'hx-data-table-align-' + (column.align ?? 'left')\">\n @if (cells().get(column.field); as cell) {\n <ng-container [ngTemplateOutlet]=\"cell\" [ngTemplateOutletContext]=\"{ $implicit: row, value: valueOf(row, column), index: i }\" />\n } @else {\n {{ valueOf(row, column) ?? emptyValue() }}\n }\n </td>\n }\n }\n </tr>\n @if (expansionTemplate(); as tpl) {\n @if (isExpanded(row, i)) {\n <tr class=\"hx-data-table-expansion\">\n <td [attr.colspan]=\"colspan()\">\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: row, index: i, columns: columns() }\" />\n </td>\n </tr>\n }\n }\n } @empty {\n <tr class=\"hx-data-table-empty\">\n <td [attr.colspan]=\"colspan()\">\n @if (emptyTemplate(); as tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl.template\" />\n } @else {\n {{ emptyMessage() }}\n }\n </td>\n </tr>\n }\n </tbody>\n @if (footerTemplate(); as tpl) {\n <tfoot>\n <tr>\n @if (expanderColumn()) { <td></td> }\n @if (checkboxColumn()) { <td></td> }\n <ng-container [ngTemplateOutlet]=\"tpl.template\" [ngTemplateOutletContext]=\"{ $implicit: columns() }\" />\n </tr>\n </tfoot>\n }\n </table>\n </div>\n <span class=\"hx-data-table-caption-hidden\" aria-live=\"polite\">{{ announcement() }}</span>\n @if (loading()) {\n <div class=\"hx-data-table-loading\" role=\"status\">\n <hx-progress-spinner ariaLabel=\"Loading\" />\n </div>\n }\n @if (paginator()) {\n <hx-paginator\n class=\"hx-data-table-paginator\"\n [rows]=\"rows()\"\n [first]=\"first()\"\n [totalRecords]=\"total()\"\n [rowsPerPageOptions]=\"rowsPerPageOptions()\"\n [showAll]=\"showAll()\"\n (showAllChange)=\"showAll.set($event)\"\n [allLabel]=\"allLabel()\"\n [showCurrentPageReport]=\"showCurrentPageReport()\"\n (pageChange)=\"onPage($event)\"\n />\n }\n</div>\n\n<ng-template #label let-column>\n @if (column.sortable) {\n <button type=\"button\" class=\"hx-data-table-sort\" (click)=\"sort(column)\">\n <span>{{ column.header }}</span>\n <span class=\"hx-data-table-sort-icon\" [class.hx-data-table-sort-asc]=\"orderOf(column) === 1\" [class.hx-data-table-sort-desc]=\"orderOf(column) === -1\" aria-hidden=\"true\"></span>\n @if (sortRank(column); as rank) {\n <span class=\"hx-data-table-sort-rank\" aria-hidden=\"true\">{{ rank }}</span>\n }\n </button>\n } @else {\n {{ column.header }}\n }\n</ng-template>\n"
7161
6881
  }]
7162
6882
  }],
7163
6883
  propDecorators: {
@@ -7225,6 +6945,30 @@ i0.ɵɵngDeclareClassMetadata({
7225
6945
  required: false
7226
6946
  }]
7227
6947
  }],
6948
+ rowClass: [{
6949
+ type: i0.Input,
6950
+ args: [{
6951
+ isSignal: true,
6952
+ alias: "rowClass",
6953
+ required: false
6954
+ }]
6955
+ }],
6956
+ emptyValue: [{
6957
+ type: i0.Input,
6958
+ args: [{
6959
+ isSignal: true,
6960
+ alias: "emptyValue",
6961
+ required: false
6962
+ }]
6963
+ }],
6964
+ allLabel: [{
6965
+ type: i0.Input,
6966
+ args: [{
6967
+ isSignal: true,
6968
+ alias: "allLabel",
6969
+ required: false
6970
+ }]
6971
+ }],
7228
6972
  loading: [{
7229
6973
  type: i0.Input,
7230
6974
  args: [{
@@ -7314,6 +7058,14 @@ i0.ɵɵngDeclareClassMetadata({
7314
7058
  required: false
7315
7059
  }]
7316
7060
  }],
7061
+ sortFirstOrder: [{
7062
+ type: i0.Input,
7063
+ args: [{
7064
+ isSignal: true,
7065
+ alias: "sortFirstOrder",
7066
+ required: false
7067
+ }]
7068
+ }],
7317
7069
  paginator: [{
7318
7070
  type: i0.Input,
7319
7071
  args: [{
@@ -7497,6 +7249,10 @@ i0.ɵɵngDeclareClassMetadata({
7497
7249
  type: i0.ContentChildren,
7498
7250
  args: [i0.forwardRef(() => HxCell), { isSignal: true }]
7499
7251
  }],
7252
+ columnHeaderTemplates: [{
7253
+ type: i0.ContentChildren,
7254
+ args: [i0.forwardRef(() => HxColumnHeader), { isSignal: true }]
7255
+ }],
7500
7256
  headerTemplate: [{
7501
7257
  type: i0.ContentChild,
7502
7258
  args: [i0.forwardRef(() => HxTableHeader), { isSignal: true }]
@@ -10906,17 +10662,25 @@ const EMPTY = {
10906
10662
  to: null
10907
10663
  };
10908
10664
  const earlier = (a, b) => a && b ? a <= b ? a : b : a ?? b;
10665
+ const sameTime = (a, b) => a?.getTime() === b?.getTime();
10666
+ const sameRange = (a, b) => sameTime(a.from, b.from) && sameTime(a.to, b.to);
10909
10667
  const later = (a, b) => a && b ? a >= b ? a : b : a ?? b;
10910
10668
  var HxDateTimeRangePicker = class HxDateTimeRangePicker {
10911
10669
  fromLabel = input("From", ...ngDevMode ? [{ debugName: "fromLabel" }] : /* istanbul ignore next */ []);
10912
10670
  toLabel = input("To", ...ngDevMode ? [{ debugName: "toLabel" }] : /* istanbul ignore next */ []);
10913
10671
  separator = input("-", ...ngDevMode ? [{ debugName: "separator" }] : /* istanbul ignore next */ []);
10914
10672
  placeholder = input("", ...ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ []);
10673
+ presetsLabel = input("Presets", ...ngDevMode ? [{ debugName: "presetsLabel" }] : /* istanbul ignore next */ []);
10674
+ presets = input([], ...ngDevMode ? [{ debugName: "presets" }] : /* istanbul ignore next */ []);
10915
10675
  clearLabel = input("Clear", ...ngDevMode ? [{ debugName: "clearLabel" }] : /* istanbul ignore next */ []);
10916
10676
  cancelLabel = input("Cancel", ...ngDevMode ? [{ debugName: "cancelLabel" }] : /* istanbul ignore next */ []);
10917
10677
  submitLabel = input("Submit", ...ngDevMode ? [{ debugName: "submitLabel" }] : /* istanbul ignore next */ []);
10918
10678
  chooseLabel = input("Choose date range", ...ngDevMode ? [{ debugName: "chooseLabel" }] : /* istanbul ignore next */ []);
10919
10679
  inputId = input(...ngDevMode ? [void 0, { debugName: "inputId" }] : /* istanbul ignore next */ []);
10680
+ typeable = input(false, {
10681
+ ...ngDevMode ? { debugName: "typeable" } : /* istanbul ignore next */ {},
10682
+ transform: booleanAttribute
10683
+ });
10920
10684
  showTime = input(true, {
10921
10685
  ...ngDevMode ? { debugName: "showTime" } : /* istanbul ignore next */ {},
10922
10686
  transform: booleanAttribute
@@ -10995,6 +10759,7 @@ var HxDateTimeRangePicker = class HxDateTimeRangePicker {
10995
10759
  #lastFrom = null;
10996
10760
  #lastTo = null;
10997
10761
  #cvaDisabled = signal(false, ...ngDevMode ? [{ debugName: "#cvaDisabled" }] : /* istanbul ignore next */ []);
10762
+ #typed = signal(null, ...ngDevMode ? [{ debugName: "#typed" }] : /* istanbul ignore next */ []);
10998
10763
  #format = computed(() => {
10999
10764
  const custom = this.dateFormat();
11000
10765
  if (custom) return new Intl.DateTimeFormat(this.locale(), custom);
@@ -11012,6 +10777,8 @@ var HxDateTimeRangePicker = class HxDateTimeRangePicker {
11012
10777
  return new Intl.DateTimeFormat(this.locale(), options);
11013
10778
  }, ...ngDevMode ? [{ debugName: "#format" }] : /* istanbul ignore next */ []);
11014
10779
  text = computed(() => {
10780
+ const typed = this.#typed();
10781
+ if (typed !== null) return typed;
11015
10782
  const { from, to } = this.value();
11016
10783
  if (!from && !to) return "";
11017
10784
  const fmt = this.#format();
@@ -11026,6 +10793,12 @@ var HxDateTimeRangePicker = class HxDateTimeRangePicker {
11026
10793
  toValue = computed(() => this.#pickerValue(this.draft().to), ...ngDevMode ? [{ debugName: "toValue" }] : /* istanbul ignore next */ []);
11027
10794
  #onChange = () => {};
11028
10795
  #onTouched = () => {};
10796
+ constructor() {
10797
+ effect(() => {
10798
+ this.value();
10799
+ untracked(() => this.#typed.set(null));
10800
+ });
10801
+ }
11029
10802
  writeValue(value) {
11030
10803
  this.value.set({
11031
10804
  from: value?.from ?? null,
@@ -11061,12 +10834,76 @@ var HxDateTimeRangePicker = class HxDateTimeRangePicker {
11061
10834
  onAttach() {
11062
10835
  afterNextRender(() => (this.daysPicker() ?? this.timePicker())?.focus(), { injector: this.#injector });
11063
10836
  }
10837
+ onFieldClick() {
10838
+ if (!this.typeable()) this.show();
10839
+ }
11064
10840
  onFieldKeydown(event) {
11065
- if (event.key === "ArrowDown" || event.key === "Enter" || event.key === " " || event.altKey && event.key === "ArrowUp") {
10841
+ if (this.typeable() && event.key === "Enter") {
10842
+ event.preventDefault();
10843
+ this.commitTyping();
10844
+ } else if (this.typeable() && event.key === "Escape" && this.#typed() !== null) {
10845
+ event.preventDefault();
10846
+ this.#revertTyping();
10847
+ } else if (event.key === "ArrowDown" || event.altKey && event.key === "ArrowUp" || !this.typeable() && (event.key === "Enter" || event.key === " ")) {
11066
10848
  event.preventDefault();
11067
10849
  this.show();
11068
10850
  }
11069
10851
  }
10852
+ onTyping(event) {
10853
+ if (!this.typeable() || this.isDisabled()) return;
10854
+ this.#typed.set(event.target.value);
10855
+ }
10856
+ commitTyping() {
10857
+ const typed = this.#typed();
10858
+ if (typed === null || this.isDisabled()) return;
10859
+ this.#typed.set(null);
10860
+ const next = this.#parseRange(typed);
10861
+ if (next && !sameRange(next, this.value())) {
10862
+ this.#commit(next);
10863
+ if (this.open()) this.#stage(next);
10864
+ }
10865
+ this.#showValue();
10866
+ }
10867
+ #revertTyping() {
10868
+ this.#typed.set(null);
10869
+ this.#showValue();
10870
+ }
10871
+ #showValue() {
10872
+ const field = this.field();
10873
+ if (field) field.nativeElement.value = this.text();
10874
+ }
10875
+ #parseRange(typed) {
10876
+ const text = typed.trim();
10877
+ if (text === "") return EMPTY;
10878
+ const separator = this.separator().trim().replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
10879
+ const parts = separator ? text.split(new RegExp(`(?:^|\\s+)${separator}(?:\\s+|$)`)) : [text];
10880
+ if (parts.length > 2) return null;
10881
+ const { from: oldFrom, to: oldTo } = this.value();
10882
+ const from = this.#parseSide(parts[0], oldFrom);
10883
+ const to = this.#parseSide(parts[1] ?? "", oldTo ?? oldFrom);
10884
+ if (from === void 0 || to === void 0) return null;
10885
+ return from && to && to < from ? {
10886
+ from: to,
10887
+ to: from
10888
+ } : {
10889
+ from,
10890
+ to
10891
+ };
10892
+ }
10893
+ #parseSide(part, old) {
10894
+ const text = part.trim();
10895
+ if (text === "") return null;
10896
+ const date = this.#timed() ? parseDateTimeText(text, {
10897
+ locale: this.locale(),
10898
+ showMinutes: this.showMinutes(),
10899
+ timeOnly: this.timeOnly(),
10900
+ fallbackDay: old ?? /* @__PURE__ */ new Date()
10901
+ }) : parseDateText(text, this.locale());
10902
+ if (!date || this.#isBlocked(date)) return void 0;
10903
+ const [min, max] = [this.minDate(), this.maxDate()];
10904
+ if (min && date < min || max && date > max) return void 0;
10905
+ return date;
10906
+ }
11070
10907
  onOverlayKeydown(event) {
11071
10908
  if (event.key === "Escape") {
11072
10909
  event.preventDefault();
@@ -11079,6 +10916,27 @@ var HxDateTimeRangePicker = class HxDateTimeRangePicker {
11079
10916
  clear() {
11080
10917
  this.#stage(EMPTY);
11081
10918
  }
10919
+ applyPreset(preset) {
10920
+ const { from: oldFrom, to: oldTo } = this.draft();
10921
+ const from = this.#fitPreset(preset.from(), oldFrom);
10922
+ const to = this.#fitPreset(preset.to(), oldTo ?? oldFrom);
10923
+ if (from === void 0 || to === void 0) return;
10924
+ this.#stage(from && to && to < from ? {
10925
+ from: to,
10926
+ to: from
10927
+ } : {
10928
+ from,
10929
+ to
10930
+ });
10931
+ }
10932
+ #fitPreset(date, old) {
10933
+ if (!isValidDate(date)) return null;
10934
+ const fitted = this.timeOnly() ? this.#atTime(old ?? /* @__PURE__ */ new Date(), date) : this.#timed() ? date : startOfDay(date);
10935
+ return this.#isBlocked(fitted) ? void 0 : fitted;
10936
+ }
10937
+ #timed() {
10938
+ return this.showTime() || this.timeOnly();
10939
+ }
11082
10940
  submit() {
11083
10941
  this.#commit(this.draft());
11084
10942
  this.close(true);
@@ -11220,6 +11078,20 @@ var HxDateTimeRangePicker = class HxDateTimeRangePicker {
11220
11078
  isRequired: false,
11221
11079
  transformFunction: null
11222
11080
  },
11081
+ presetsLabel: {
11082
+ classPropertyName: "presetsLabel",
11083
+ publicName: "presetsLabel",
11084
+ isSignal: true,
11085
+ isRequired: false,
11086
+ transformFunction: null
11087
+ },
11088
+ presets: {
11089
+ classPropertyName: "presets",
11090
+ publicName: "presets",
11091
+ isSignal: true,
11092
+ isRequired: false,
11093
+ transformFunction: null
11094
+ },
11223
11095
  clearLabel: {
11224
11096
  classPropertyName: "clearLabel",
11225
11097
  publicName: "clearLabel",
@@ -11255,6 +11127,13 @@ var HxDateTimeRangePicker = class HxDateTimeRangePicker {
11255
11127
  isRequired: false,
11256
11128
  transformFunction: null
11257
11129
  },
11130
+ typeable: {
11131
+ classPropertyName: "typeable",
11132
+ publicName: "typeable",
11133
+ isSignal: true,
11134
+ isRequired: false,
11135
+ transformFunction: null
11136
+ },
11258
11137
  showTime: {
11259
11138
  classPropertyName: "showTime",
11260
11139
  publicName: "showTime",
@@ -11433,7 +11312,7 @@ var HxDateTimeRangePicker = class HxDateTimeRangePicker {
11433
11312
  }
11434
11313
  ],
11435
11314
  ngImport: i0,
11436
- template: "<div\n class=\"hx-date-picker hx-date-picker-has-icon hx-date-time-range-picker-control\"\n [class.hx-date-picker-open]=\"open()\"\n [class.hx-date-picker-disabled]=\"isDisabled()\"\n [class.hx-date-picker-invalid]=\"invalid()\"\n>\n <div class=\"hx-date-picker-field\" cdkOverlayOrigin #origin=\"cdkOverlayOrigin\">\n <input\n #field\n type=\"text\"\n readonly\n class=\"hx-date-picker-input\"\n autocomplete=\"off\"\n aria-haspopup=\"dialog\"\n [attr.id]=\"inputId() ?? null\"\n [placeholder]=\"placeholder()\"\n [disabled]=\"isDisabled()\"\n [value]=\"text()\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"open() ? popupId : null\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledby() ?? null\"\n [attr.aria-invalid]=\"invalid() ? 'true' : null\"\n (click)=\"show()\"\n (keydown)=\"onFieldKeydown($event)\"\n />\n <button\n type=\"button\"\n class=\"hx-date-picker-trigger\"\n aria-haspopup=\"dialog\"\n [attr.aria-label]=\"chooseLabel()\"\n [attr.aria-expanded]=\"open()\"\n [disabled]=\"isDisabled()\"\n (click)=\"toggle()\"\n >\n <span class=\"hx-date-picker-trigger-icon\" aria-hidden=\"true\"></span>\n </button>\n </div>\n <ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayPanelClass=\"hx-date-picker-overlay\"\n [cdkConnectedOverlayOrigin]=\"origin\"\n [cdkConnectedOverlayOpen]=\"open()\"\n [cdkConnectedOverlayPositions]=\"positions\"\n [cdkConnectedOverlayPush]=\"true\"\n (overlayOutsideClick)=\"onOutsideClick($event)\"\n (overlayKeydown)=\"onOverlayKeydown($event)\"\n (attach)=\"onAttach()\"\n (detach)=\"open.set(false)\"\n >\n <div\n class=\"hx-date-picker-popup hx-date-time-range-picker-popup\"\n role=\"dialog\"\n aria-modal=\"false\"\n [id]=\"popupId\"\n [attr.aria-label]=\"ariaLabel() ?? chooseLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledby() ?? null\"\n (focusout)=\"onPopupFocusOut($event)\"\n >\n <div class=\"hx-date-time-range-picker-body\">\n @if (!timeOnly()) {\n <hx-date-picker\n class=\"hx-date-time-range-picker-days\"\n inline\n selectionMode=\"range\"\n [ariaLabel]=\"chooseLabel()\"\n [value]=\"days()\"\n [minDate]=\"minDate()\"\n [maxDate]=\"maxDate()\"\n [locale]=\"locale()\"\n [firstDayOfWeek]=\"firstDayOfWeek()\"\n [disabledDates]=\"disabledDates()\"\n (valueChange)=\"setDays($event)\"\n />\n }\n @if (showTime() || timeOnly()) {\n <div class=\"hx-date-time-range-picker-times\">\n <div class=\"hx-date-time-range-picker-time\">\n <span class=\"hx-date-time-range-picker-caption\" aria-hidden=\"true\">{{ fromLabel() }}</span>\n <hx-time-picker\n inline\n class=\"hx-date-time-range-picker-from\"\n [ariaLabel]=\"fromLabel()\"\n [value]=\"fromValue()\"\n [hourFormat]=\"hourFormat()\"\n [showMinutes]=\"showMinutes()\"\n [showSeconds]=\"showSeconds()\"\n [stepHour]=\"stepHour()\"\n [stepMinute]=\"stepMinute()\"\n [stepSecond]=\"stepSecond()\"\n [locale]=\"locale()\"\n [disabled]=\"isDisabled()\"\n (valueChange)=\"setFromTime($event)\"\n />\n </div>\n <div class=\"hx-date-time-range-picker-time\">\n <span class=\"hx-date-time-range-picker-caption\" aria-hidden=\"true\">{{ toLabel() }}</span>\n <hx-time-picker\n inline\n class=\"hx-date-time-range-picker-to\"\n [ariaLabel]=\"toLabel()\"\n [value]=\"toValue()\"\n [hourFormat]=\"hourFormat()\"\n [showMinutes]=\"showMinutes()\"\n [showSeconds]=\"showSeconds()\"\n [stepHour]=\"stepHour()\"\n [stepMinute]=\"stepMinute()\"\n [stepSecond]=\"stepSecond()\"\n [locale]=\"locale()\"\n [disabled]=\"isDisabled()\"\n (valueChange)=\"setToTime($event)\"\n />\n </div>\n </div>\n }\n </div>\n <div class=\"hx-date-picker-buttonbar hx-date-time-range-picker-footer\">\n @if (showButtonBar()) {\n <button type=\"button\" class=\"hx-date-picker-button\" (click)=\"clear()\">{{ clearLabel() }}</button>\n }\n <span class=\"hx-date-time-range-picker-spacer\"></span>\n <button type=\"button\" class=\"hx-date-picker-button hx-date-time-range-picker-cancel\" (click)=\"close(true)\">{{ cancelLabel() }}</button>\n <button type=\"button\" class=\"hx-date-picker-button hx-date-time-range-picker-submit\" (click)=\"submit()\">{{ submitLabel() }}</button>\n </div>\n </div>\n </ng-template>\n</div>\n",
11315
+ template: "<div\n class=\"hx-date-picker hx-date-picker-has-icon hx-date-time-range-picker-control\"\n [class.hx-date-picker-open]=\"open()\"\n [class.hx-date-picker-disabled]=\"isDisabled()\"\n [class.hx-date-picker-invalid]=\"invalid()\"\n>\n <div class=\"hx-date-picker-field\" cdkOverlayOrigin #origin=\"cdkOverlayOrigin\">\n <input\n #field\n type=\"text\"\n [readOnly]=\"!typeable()\"\n class=\"hx-date-picker-input\"\n autocomplete=\"off\"\n aria-haspopup=\"dialog\"\n [attr.id]=\"inputId() ?? null\"\n [placeholder]=\"placeholder()\"\n [disabled]=\"isDisabled()\"\n [value]=\"text()\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"open() ? popupId : null\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledby() ?? null\"\n [attr.aria-invalid]=\"invalid() ? 'true' : null\"\n (input)=\"onTyping($event)\"\n (change)=\"commitTyping()\"\n (click)=\"onFieldClick()\"\n (keydown)=\"onFieldKeydown($event)\"\n />\n <button\n type=\"button\"\n class=\"hx-date-picker-trigger\"\n aria-haspopup=\"dialog\"\n [attr.aria-label]=\"chooseLabel()\"\n [attr.aria-expanded]=\"open()\"\n [disabled]=\"isDisabled()\"\n (click)=\"toggle()\"\n >\n <span class=\"hx-date-picker-trigger-icon\" aria-hidden=\"true\"></span>\n </button>\n </div>\n <ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayPanelClass=\"hx-date-picker-overlay\"\n [cdkConnectedOverlayOrigin]=\"origin\"\n [cdkConnectedOverlayOpen]=\"open()\"\n [cdkConnectedOverlayPositions]=\"positions\"\n [cdkConnectedOverlayPush]=\"true\"\n (overlayOutsideClick)=\"onOutsideClick($event)\"\n (overlayKeydown)=\"onOverlayKeydown($event)\"\n (attach)=\"onAttach()\"\n (detach)=\"open.set(false)\"\n >\n <div\n class=\"hx-date-picker-popup hx-date-time-range-picker-popup\"\n role=\"dialog\"\n aria-modal=\"false\"\n [id]=\"popupId\"\n [attr.aria-label]=\"ariaLabel() ?? chooseLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledby() ?? null\"\n (focusout)=\"onPopupFocusOut($event)\"\n >\n @if (presets().length > 0) {\n <div class=\"hx-date-time-range-picker-presets\" role=\"group\" [attr.aria-label]=\"presetsLabel()\">\n @for (preset of presets(); track $index) {\n <button type=\"button\" class=\"hx-date-picker-button hx-date-time-range-picker-preset\" (click)=\"applyPreset(preset)\">{{ preset.label }}</button>\n }\n </div>\n }\n <div class=\"hx-date-time-range-picker-body\">\n @if (!timeOnly()) {\n <hx-date-picker\n class=\"hx-date-time-range-picker-days\"\n inline\n selectionMode=\"range\"\n [ariaLabel]=\"chooseLabel()\"\n [value]=\"days()\"\n [minDate]=\"minDate()\"\n [maxDate]=\"maxDate()\"\n [locale]=\"locale()\"\n [firstDayOfWeek]=\"firstDayOfWeek()\"\n [disabledDates]=\"disabledDates()\"\n (valueChange)=\"setDays($event)\"\n />\n }\n @if (showTime() || timeOnly()) {\n <div class=\"hx-date-time-range-picker-times\">\n <div class=\"hx-date-time-range-picker-time\">\n <span class=\"hx-date-time-range-picker-caption\" aria-hidden=\"true\">{{ fromLabel() }}</span>\n <hx-time-picker\n inline\n class=\"hx-date-time-range-picker-from\"\n [ariaLabel]=\"fromLabel()\"\n [value]=\"fromValue()\"\n [hourFormat]=\"hourFormat()\"\n [showMinutes]=\"showMinutes()\"\n [showSeconds]=\"showSeconds()\"\n [stepHour]=\"stepHour()\"\n [stepMinute]=\"stepMinute()\"\n [stepSecond]=\"stepSecond()\"\n [locale]=\"locale()\"\n [disabled]=\"isDisabled()\"\n (valueChange)=\"setFromTime($event)\"\n />\n </div>\n <div class=\"hx-date-time-range-picker-time\">\n <span class=\"hx-date-time-range-picker-caption\" aria-hidden=\"true\">{{ toLabel() }}</span>\n <hx-time-picker\n inline\n class=\"hx-date-time-range-picker-to\"\n [ariaLabel]=\"toLabel()\"\n [value]=\"toValue()\"\n [hourFormat]=\"hourFormat()\"\n [showMinutes]=\"showMinutes()\"\n [showSeconds]=\"showSeconds()\"\n [stepHour]=\"stepHour()\"\n [stepMinute]=\"stepMinute()\"\n [stepSecond]=\"stepSecond()\"\n [locale]=\"locale()\"\n [disabled]=\"isDisabled()\"\n (valueChange)=\"setToTime($event)\"\n />\n </div>\n </div>\n }\n </div>\n <div class=\"hx-date-picker-buttonbar hx-date-time-range-picker-footer\">\n @if (showButtonBar()) {\n <button type=\"button\" class=\"hx-date-picker-button\" (click)=\"clear()\">{{ clearLabel() }}</button>\n }\n <span class=\"hx-date-time-range-picker-spacer\"></span>\n <button type=\"button\" class=\"hx-date-picker-button hx-date-time-range-picker-cancel\" (click)=\"close(true)\">{{ cancelLabel() }}</button>\n <button type=\"button\" class=\"hx-date-picker-button hx-date-time-range-picker-submit\" (click)=\"submit()\">{{ submitLabel() }}</button>\n </div>\n </div>\n </ng-template>\n</div>\n",
11437
11316
  dependencies: [
11438
11317
  {
11439
11318
  kind: "directive",
@@ -11575,9 +11454,10 @@ i0.ɵɵngDeclareClassMetadata({
11575
11454
  class: "hx-date-time-range-picker",
11576
11455
  "(focusout)": "onHostFocusOut($event)"
11577
11456
  },
11578
- template: "<div\n class=\"hx-date-picker hx-date-picker-has-icon hx-date-time-range-picker-control\"\n [class.hx-date-picker-open]=\"open()\"\n [class.hx-date-picker-disabled]=\"isDisabled()\"\n [class.hx-date-picker-invalid]=\"invalid()\"\n>\n <div class=\"hx-date-picker-field\" cdkOverlayOrigin #origin=\"cdkOverlayOrigin\">\n <input\n #field\n type=\"text\"\n readonly\n class=\"hx-date-picker-input\"\n autocomplete=\"off\"\n aria-haspopup=\"dialog\"\n [attr.id]=\"inputId() ?? null\"\n [placeholder]=\"placeholder()\"\n [disabled]=\"isDisabled()\"\n [value]=\"text()\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"open() ? popupId : null\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledby() ?? null\"\n [attr.aria-invalid]=\"invalid() ? 'true' : null\"\n (click)=\"show()\"\n (keydown)=\"onFieldKeydown($event)\"\n />\n <button\n type=\"button\"\n class=\"hx-date-picker-trigger\"\n aria-haspopup=\"dialog\"\n [attr.aria-label]=\"chooseLabel()\"\n [attr.aria-expanded]=\"open()\"\n [disabled]=\"isDisabled()\"\n (click)=\"toggle()\"\n >\n <span class=\"hx-date-picker-trigger-icon\" aria-hidden=\"true\"></span>\n </button>\n </div>\n <ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayPanelClass=\"hx-date-picker-overlay\"\n [cdkConnectedOverlayOrigin]=\"origin\"\n [cdkConnectedOverlayOpen]=\"open()\"\n [cdkConnectedOverlayPositions]=\"positions\"\n [cdkConnectedOverlayPush]=\"true\"\n (overlayOutsideClick)=\"onOutsideClick($event)\"\n (overlayKeydown)=\"onOverlayKeydown($event)\"\n (attach)=\"onAttach()\"\n (detach)=\"open.set(false)\"\n >\n <div\n class=\"hx-date-picker-popup hx-date-time-range-picker-popup\"\n role=\"dialog\"\n aria-modal=\"false\"\n [id]=\"popupId\"\n [attr.aria-label]=\"ariaLabel() ?? chooseLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledby() ?? null\"\n (focusout)=\"onPopupFocusOut($event)\"\n >\n <div class=\"hx-date-time-range-picker-body\">\n @if (!timeOnly()) {\n <hx-date-picker\n class=\"hx-date-time-range-picker-days\"\n inline\n selectionMode=\"range\"\n [ariaLabel]=\"chooseLabel()\"\n [value]=\"days()\"\n [minDate]=\"minDate()\"\n [maxDate]=\"maxDate()\"\n [locale]=\"locale()\"\n [firstDayOfWeek]=\"firstDayOfWeek()\"\n [disabledDates]=\"disabledDates()\"\n (valueChange)=\"setDays($event)\"\n />\n }\n @if (showTime() || timeOnly()) {\n <div class=\"hx-date-time-range-picker-times\">\n <div class=\"hx-date-time-range-picker-time\">\n <span class=\"hx-date-time-range-picker-caption\" aria-hidden=\"true\">{{ fromLabel() }}</span>\n <hx-time-picker\n inline\n class=\"hx-date-time-range-picker-from\"\n [ariaLabel]=\"fromLabel()\"\n [value]=\"fromValue()\"\n [hourFormat]=\"hourFormat()\"\n [showMinutes]=\"showMinutes()\"\n [showSeconds]=\"showSeconds()\"\n [stepHour]=\"stepHour()\"\n [stepMinute]=\"stepMinute()\"\n [stepSecond]=\"stepSecond()\"\n [locale]=\"locale()\"\n [disabled]=\"isDisabled()\"\n (valueChange)=\"setFromTime($event)\"\n />\n </div>\n <div class=\"hx-date-time-range-picker-time\">\n <span class=\"hx-date-time-range-picker-caption\" aria-hidden=\"true\">{{ toLabel() }}</span>\n <hx-time-picker\n inline\n class=\"hx-date-time-range-picker-to\"\n [ariaLabel]=\"toLabel()\"\n [value]=\"toValue()\"\n [hourFormat]=\"hourFormat()\"\n [showMinutes]=\"showMinutes()\"\n [showSeconds]=\"showSeconds()\"\n [stepHour]=\"stepHour()\"\n [stepMinute]=\"stepMinute()\"\n [stepSecond]=\"stepSecond()\"\n [locale]=\"locale()\"\n [disabled]=\"isDisabled()\"\n (valueChange)=\"setToTime($event)\"\n />\n </div>\n </div>\n }\n </div>\n <div class=\"hx-date-picker-buttonbar hx-date-time-range-picker-footer\">\n @if (showButtonBar()) {\n <button type=\"button\" class=\"hx-date-picker-button\" (click)=\"clear()\">{{ clearLabel() }}</button>\n }\n <span class=\"hx-date-time-range-picker-spacer\"></span>\n <button type=\"button\" class=\"hx-date-picker-button hx-date-time-range-picker-cancel\" (click)=\"close(true)\">{{ cancelLabel() }}</button>\n <button type=\"button\" class=\"hx-date-picker-button hx-date-time-range-picker-submit\" (click)=\"submit()\">{{ submitLabel() }}</button>\n </div>\n </div>\n </ng-template>\n</div>\n"
11457
+ template: "<div\n class=\"hx-date-picker hx-date-picker-has-icon hx-date-time-range-picker-control\"\n [class.hx-date-picker-open]=\"open()\"\n [class.hx-date-picker-disabled]=\"isDisabled()\"\n [class.hx-date-picker-invalid]=\"invalid()\"\n>\n <div class=\"hx-date-picker-field\" cdkOverlayOrigin #origin=\"cdkOverlayOrigin\">\n <input\n #field\n type=\"text\"\n [readOnly]=\"!typeable()\"\n class=\"hx-date-picker-input\"\n autocomplete=\"off\"\n aria-haspopup=\"dialog\"\n [attr.id]=\"inputId() ?? null\"\n [placeholder]=\"placeholder()\"\n [disabled]=\"isDisabled()\"\n [value]=\"text()\"\n [attr.aria-expanded]=\"open()\"\n [attr.aria-controls]=\"open() ? popupId : null\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledby() ?? null\"\n [attr.aria-invalid]=\"invalid() ? 'true' : null\"\n (input)=\"onTyping($event)\"\n (change)=\"commitTyping()\"\n (click)=\"onFieldClick()\"\n (keydown)=\"onFieldKeydown($event)\"\n />\n <button\n type=\"button\"\n class=\"hx-date-picker-trigger\"\n aria-haspopup=\"dialog\"\n [attr.aria-label]=\"chooseLabel()\"\n [attr.aria-expanded]=\"open()\"\n [disabled]=\"isDisabled()\"\n (click)=\"toggle()\"\n >\n <span class=\"hx-date-picker-trigger-icon\" aria-hidden=\"true\"></span>\n </button>\n </div>\n <ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayPanelClass=\"hx-date-picker-overlay\"\n [cdkConnectedOverlayOrigin]=\"origin\"\n [cdkConnectedOverlayOpen]=\"open()\"\n [cdkConnectedOverlayPositions]=\"positions\"\n [cdkConnectedOverlayPush]=\"true\"\n (overlayOutsideClick)=\"onOutsideClick($event)\"\n (overlayKeydown)=\"onOverlayKeydown($event)\"\n (attach)=\"onAttach()\"\n (detach)=\"open.set(false)\"\n >\n <div\n class=\"hx-date-picker-popup hx-date-time-range-picker-popup\"\n role=\"dialog\"\n aria-modal=\"false\"\n [id]=\"popupId\"\n [attr.aria-label]=\"ariaLabel() ?? chooseLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledby() ?? null\"\n (focusout)=\"onPopupFocusOut($event)\"\n >\n @if (presets().length > 0) {\n <div class=\"hx-date-time-range-picker-presets\" role=\"group\" [attr.aria-label]=\"presetsLabel()\">\n @for (preset of presets(); track $index) {\n <button type=\"button\" class=\"hx-date-picker-button hx-date-time-range-picker-preset\" (click)=\"applyPreset(preset)\">{{ preset.label }}</button>\n }\n </div>\n }\n <div class=\"hx-date-time-range-picker-body\">\n @if (!timeOnly()) {\n <hx-date-picker\n class=\"hx-date-time-range-picker-days\"\n inline\n selectionMode=\"range\"\n [ariaLabel]=\"chooseLabel()\"\n [value]=\"days()\"\n [minDate]=\"minDate()\"\n [maxDate]=\"maxDate()\"\n [locale]=\"locale()\"\n [firstDayOfWeek]=\"firstDayOfWeek()\"\n [disabledDates]=\"disabledDates()\"\n (valueChange)=\"setDays($event)\"\n />\n }\n @if (showTime() || timeOnly()) {\n <div class=\"hx-date-time-range-picker-times\">\n <div class=\"hx-date-time-range-picker-time\">\n <span class=\"hx-date-time-range-picker-caption\" aria-hidden=\"true\">{{ fromLabel() }}</span>\n <hx-time-picker\n inline\n class=\"hx-date-time-range-picker-from\"\n [ariaLabel]=\"fromLabel()\"\n [value]=\"fromValue()\"\n [hourFormat]=\"hourFormat()\"\n [showMinutes]=\"showMinutes()\"\n [showSeconds]=\"showSeconds()\"\n [stepHour]=\"stepHour()\"\n [stepMinute]=\"stepMinute()\"\n [stepSecond]=\"stepSecond()\"\n [locale]=\"locale()\"\n [disabled]=\"isDisabled()\"\n (valueChange)=\"setFromTime($event)\"\n />\n </div>\n <div class=\"hx-date-time-range-picker-time\">\n <span class=\"hx-date-time-range-picker-caption\" aria-hidden=\"true\">{{ toLabel() }}</span>\n <hx-time-picker\n inline\n class=\"hx-date-time-range-picker-to\"\n [ariaLabel]=\"toLabel()\"\n [value]=\"toValue()\"\n [hourFormat]=\"hourFormat()\"\n [showMinutes]=\"showMinutes()\"\n [showSeconds]=\"showSeconds()\"\n [stepHour]=\"stepHour()\"\n [stepMinute]=\"stepMinute()\"\n [stepSecond]=\"stepSecond()\"\n [locale]=\"locale()\"\n [disabled]=\"isDisabled()\"\n (valueChange)=\"setToTime($event)\"\n />\n </div>\n </div>\n }\n </div>\n <div class=\"hx-date-picker-buttonbar hx-date-time-range-picker-footer\">\n @if (showButtonBar()) {\n <button type=\"button\" class=\"hx-date-picker-button\" (click)=\"clear()\">{{ clearLabel() }}</button>\n }\n <span class=\"hx-date-time-range-picker-spacer\"></span>\n <button type=\"button\" class=\"hx-date-picker-button hx-date-time-range-picker-cancel\" (click)=\"close(true)\">{{ cancelLabel() }}</button>\n <button type=\"button\" class=\"hx-date-picker-button hx-date-time-range-picker-submit\" (click)=\"submit()\">{{ submitLabel() }}</button>\n </div>\n </div>\n </ng-template>\n</div>\n"
11579
11458
  }]
11580
11459
  }],
11460
+ ctorParameters: () => [],
11581
11461
  propDecorators: {
11582
11462
  fromLabel: [{
11583
11463
  type: i0.Input,
@@ -11611,6 +11491,22 @@ i0.ɵɵngDeclareClassMetadata({
11611
11491
  required: false
11612
11492
  }]
11613
11493
  }],
11494
+ presetsLabel: [{
11495
+ type: i0.Input,
11496
+ args: [{
11497
+ isSignal: true,
11498
+ alias: "presetsLabel",
11499
+ required: false
11500
+ }]
11501
+ }],
11502
+ presets: [{
11503
+ type: i0.Input,
11504
+ args: [{
11505
+ isSignal: true,
11506
+ alias: "presets",
11507
+ required: false
11508
+ }]
11509
+ }],
11614
11510
  clearLabel: [{
11615
11511
  type: i0.Input,
11616
11512
  args: [{
@@ -11651,6 +11547,14 @@ i0.ɵɵngDeclareClassMetadata({
11651
11547
  required: false
11652
11548
  }]
11653
11549
  }],
11550
+ typeable: [{
11551
+ type: i0.Input,
11552
+ args: [{
11553
+ isSignal: true,
11554
+ alias: "typeable",
11555
+ required: false
11556
+ }]
11557
+ }],
11654
11558
  showTime: [{
11655
11559
  type: i0.Input,
11656
11560
  args: [{
@@ -21743,7 +21647,7 @@ var HxTheme = class HxTheme {
21743
21647
  constructor() {
21744
21648
  effect(() => {
21745
21649
  const dark = this.#dark();
21746
- if (!this.#browser) return;
21650
+ if (!this.#browser || this.#options.manageDark === false) return;
21747
21651
  const root = this.#doc.documentElement;
21748
21652
  const doc = this.#doc;
21749
21653
  const apply = () => this.#darkSelector.apply(root, dark);
@@ -23848,6 +23752,6 @@ i0.ɵɵngDeclareClassMetadata({
23848
23752
  }]
23849
23753
  }
23850
23754
  });
23851
- export { HX_CHART_LOADER, HX_DIALOG_DATA, HX_PRIMARY_COLORS, HX_SURFACES, HX_SURFACE_NAMES, HX_THEME_OPTIONS, HxAccordion, HxAccordionContent, HxAccordionHeader, HxAccordionPanel, HxAutoComplete, HxAvatar, HxAvatarGroup, HxBadge, HxBreadcrumb, HxButton, HxButtonGroup, HxCard, HxCarousel, HxCarouselItem, HxCell, HxChart, HxCheckbox, HxChip, HxConfirmDialog, HxConfirmPopup, HxConfirmationService, HxDataTable, HxDatePicker, HxDateTimePicker, HxDateTimeRangePicker, HxDialog, HxDialogRef, HxDialogService, HxDivider, HxDrawer, HxFieldset, HxFileUpload, HxFloatLabel, HxGalleria, HxGalleriaCaption, HxGalleriaItemTemplate, HxGalleriaThumbnail, HxIconField, HxImage, HxImageIndicator, HxInput, HxInputGroup, HxInputGroupAddon, HxInputIcon, HxInputNumber, HxListbox, HxMenu, HxMenubar, HxMessage, HxMessageService, HxMultiSelect, HxOverlayBadge, HxPaginator, HxPanel, HxPassword, HxPopover, HxProgressBar, HxProgressSpinner, HxRadio, HxRating, HxRowExpansion, HxSelect, HxSelectButton, HxSkeleton, HxSlider, HxSplitButton, HxStep, HxStepContent, HxStepList, HxStepPanel, HxStepPanels, HxStepper, HxSwitch, HxTab, HxTabContent, HxTabList, HxTabPanel, HxTabPanels, HxTable, HxTableBody, HxTableCaption, HxTableEmpty, HxTableFooter, HxTableHeader, HxTabs, HxTag, HxTheme, HxTimePicker, HxTimeline, HxTimelineContent, HxTimelineMarker, HxTimelineOpposite, HxToast, HxToastItem, HxToggleButton, HxToolbar, HxTooltip, HxTree, HxTreeNodeTemplate, compareValues, formatFileSize, matchesAccept, provideHxTheme, resolveField };
23755
+ export { HX_DIALOG_DATA, HX_PRIMARY_COLORS, HX_SURFACES, HX_SURFACE_NAMES, HX_THEME_OPTIONS, HxAccordion, HxAccordionContent, HxAccordionHeader, HxAccordionPanel, HxAutoComplete, HxAvatar, HxAvatarGroup, HxBadge, HxBreadcrumb, HxButton, HxButtonGroup, HxCard, HxCarousel, HxCarouselItem, HxCell, HxCheckbox, HxChip, HxColumnHeader, HxConfirmDialog, HxConfirmPopup, HxConfirmationService, HxDataTable, HxDatePicker, HxDateTimePicker, HxDateTimeRangePicker, HxDialog, HxDialogRef, HxDialogService, HxDivider, HxDrawer, HxFieldset, HxFileUpload, HxFloatLabel, HxGalleria, HxGalleriaCaption, HxGalleriaItemTemplate, HxGalleriaThumbnail, HxIconField, HxImage, HxImageIndicator, HxInput, HxInputGroup, HxInputGroupAddon, HxInputIcon, HxInputNumber, HxListbox, HxMenu, HxMenubar, HxMessage, HxMessageService, HxMultiSelect, HxOverlayBadge, HxPaginator, HxPanel, HxPassword, HxPopover, HxProgressBar, HxProgressSpinner, HxRadio, HxRating, HxRowExpansion, HxSelect, HxSelectButton, HxSkeleton, HxSlider, HxSplitButton, HxStep, HxStepContent, HxStepList, HxStepPanel, HxStepPanels, HxStepper, HxSwitch, HxTab, HxTabContent, HxTabList, HxTabPanel, HxTabPanels, HxTable, HxTableBody, HxTableCaption, HxTableEmpty, HxTableFooter, HxTableHeader, HxTabs, HxTag, HxTheme, HxTimePicker, HxTimeline, HxTimelineContent, HxTimelineMarker, HxTimelineOpposite, HxToast, HxToastItem, HxToggleButton, HxToolbar, HxTooltip, HxTree, HxTreeNodeTemplate, compareValues, formatFileSize, matchesAccept, provideHxTheme, resolveField };
23852
23756
 
23853
23757
  //# sourceMappingURL=gravionlabs-helix-ui.mjs.map