@spartan-ng/brain 0.0.1-alpha.533 → 0.0.1-alpha.534

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.
@@ -5,9 +5,10 @@ export declare class BrnAutocompleteSearchInput extends DefaultValueAccessor {
5
5
  private readonly elementRef;
6
6
  private readonly _autocomplete;
7
7
  /** The initial value of the search input */
8
- readonly value: import("@angular/core").InputSignal<string>;
9
- /** @internal The "real" value of the search input */
10
- readonly valueState: import("@angular/core").WritableSignal<string>;
8
+ readonly value: import("@angular/core").ModelSignal<string>;
9
+ /** Emitted when the value changes */
10
+ readonly valueChange: import("@angular/core").OutputEmitterRef<string>;
11
+ /** Whether the autocomplete panel is expanded */
11
12
  protected readonly _isExpanded: import("@angular/core").Signal<boolean>;
12
13
  /** The id of the active option */
13
14
  protected readonly _activeDescendant: import("@angular/core").WritableSignal<string | undefined>;
@@ -19,5 +20,5 @@ export declare class BrnAutocompleteSearchInput extends DefaultValueAccessor {
19
20
  /** CONROL VALUE ACCESSOR */
20
21
  writeValue(value: string | null): void;
21
22
  static ɵfac: i0.ɵɵFactoryDeclaration<BrnAutocompleteSearchInput, [null, null, { optional: true; }]>;
22
- static ɵdir: i0.ɵɵDirectiveDeclaration<BrnAutocompleteSearchInput, "input[brnAutocompleteSearchInput]", never, { "value": { "alias": "value"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
23
+ static ɵdir: i0.ɵɵDirectiveDeclaration<BrnAutocompleteSearchInput, "input[brnAutocompleteSearchInput]", never, { "value": { "alias": "value"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; "valueChange": "valueChange"; }, never, never, true, never>;
23
24
  }
@@ -14,6 +14,8 @@ export declare class BrnAutocomplete<T> {
14
14
  private readonly _brnPopover;
15
15
  /** Access the search input if present */
16
16
  private readonly _searchInput;
17
+ /** @internal The focus strategy when opening */
18
+ private readonly _focus;
17
19
  /** @internal Access all the items within the autocomplete */
18
20
  readonly items: import("@angular/core").Signal<readonly BrnAutocompleteItem<T>[]>;
19
21
  /** @internal The key manager for managing active descendant */
@@ -22,6 +24,9 @@ export declare class BrnAutocomplete<T> {
22
24
  readonly isExpanded: import("@angular/core").Signal<boolean>;
23
25
  constructor();
24
26
  protected selectActiveItem(): void;
27
+ open(focus?: 'first' | 'last'): void;
28
+ close(): void;
29
+ toggle(): void;
25
30
  static ɵfac: i0.ɵɵFactoryDeclaration<BrnAutocomplete<any>, never>;
26
31
  static ɵdir: i0.ɵɵDirectiveDeclaration<BrnAutocomplete<any>, "[brnAutocomplete]", never, { "id": { "alias": "id"; "required": false; "isSignal": true; }; }, { "valueChange": "valueChange"; }, ["_searchInput", "items"], never, true, never>;
27
32
  }
@@ -9,9 +9,9 @@ export declare class BrnCalendarMonthSelect {
9
9
  /** Access the calendar i18n */
10
10
  protected readonly _i18n: import("./i18n/calendar-i18n").BrnCalendarI18nService;
11
11
  protected readonly _selectedMonth: import("@angular/core").Signal<string>;
12
+ constructor();
12
13
  /** Focus selected month */
13
14
  protected monthSelected(selectedMonth: string): void;
14
- constructor();
15
15
  static ɵfac: i0.ɵɵFactoryDeclaration<BrnCalendarMonthSelect, never>;
16
16
  static ɵdir: i0.ɵɵDirectiveDeclaration<BrnCalendarMonthSelect, "brn-select[brnCalendarMonthSelect]", never, {}, {}, never, never, true, never>;
17
17
  }
@@ -8,9 +8,9 @@ export declare class BrnCalendarYearSelect {
8
8
  private readonly _dateAdapter;
9
9
  /** Access the calendar i18n */
10
10
  protected readonly _i18n: import("./i18n/calendar-i18n").BrnCalendarI18nService;
11
+ constructor();
11
12
  /** Focus selected year */
12
13
  protected yearSelected(year: number): void;
13
- constructor();
14
14
  static ɵfac: i0.ɵɵFactoryDeclaration<BrnCalendarYearSelect, never>;
15
15
  static ɵdir: i0.ɵɵDirectiveDeclaration<BrnCalendarYearSelect, "brn-select[brnCalendarYearSelect]", never, {}, {}, never, never, true, never>;
16
16
  }
@@ -31,17 +31,10 @@ export declare class BrnCalendar<T> implements BrnCalendarBase<T> {
31
31
  readonly header: import("@angular/core").Signal<BrnCalendarHeader | undefined>;
32
32
  /** Store the cells */
33
33
  protected readonly _cells: import("@angular/core").Signal<readonly BrnCalendarCellButton<T>[]>;
34
- /**
35
- * @internal
36
- * The internal state of the component.
37
- */
38
- readonly state: import("@angular/core").Signal<{
39
- focusedDate: import("@angular/core").WritableSignal<T>;
40
- }>;
41
34
  /**
42
35
  * The focused date.
43
36
  */
44
- readonly focusedDate: import("@angular/core").Signal<T>;
37
+ readonly focusedDate: import("@angular/core").WritableSignal<T>;
45
38
  /**
46
39
  * Get all the days to display, this is the days of the current month
47
40
  * and the days of the previous and next month to fill the grid.
@@ -10,11 +10,8 @@ export interface BrnCalendarBase<T> {
10
10
  isEndOfRange: (date: T) => boolean;
11
11
  isBetweenRange: (date: T) => boolean;
12
12
  disabled: Signal<boolean>;
13
- focusedDate: Signal<T>;
13
+ focusedDate: WritableSignal<T>;
14
14
  header: Signal<BrnCalendarHeader | undefined>;
15
- state: Signal<{
16
- focusedDate: WritableSignal<T>;
17
- }>;
18
15
  days: Signal<T[]>;
19
16
  }
20
17
  export declare const BrnCalendarToken: InjectionToken<BrnCalendarBase<unknown>>;
@@ -55,17 +55,10 @@ export declare class BrnCalendarMulti<T> implements BrnCalendarBase<T> {
55
55
  readonly header: import("@angular/core").Signal<BrnCalendarHeader | undefined>;
56
56
  /** Store the cells */
57
57
  protected readonly _cells: import("@angular/core").Signal<readonly BrnCalendarCellButton<T>[]>;
58
- /**
59
- * @internal
60
- * The internal state of the component.
61
- */
62
- readonly state: import("@angular/core").Signal<{
63
- focusedDate: import("@angular/core").WritableSignal<T>;
64
- }>;
65
58
  /**
66
59
  * The focused date.
67
60
  */
68
- readonly focusedDate: import("@angular/core").Signal<T>;
61
+ readonly focusedDate: import("@angular/core").WritableSignal<T>;
69
62
  /**
70
63
  * Get all the days to display, this is the days of the current month
71
64
  * and the days of the previous and next month to fill the grid.
@@ -28,17 +28,10 @@ export declare class BrnCalendarRange<T> implements BrnCalendarBase<T> {
28
28
  readonly header: import("@angular/core").Signal<BrnCalendarHeader | undefined>;
29
29
  /** Store the cells */
30
30
  protected readonly _cells: import("@angular/core").Signal<readonly BrnCalendarCellButton<T>[]>;
31
- /**
32
- * @internal
33
- * The internal state of the component.
34
- */
35
- readonly state: import("@angular/core").Signal<{
36
- focusedDate: import("@angular/core").WritableSignal<T>;
37
- }>;
38
31
  /**
39
32
  * The focused date.
40
33
  */
41
- readonly focusedDate: import("@angular/core").Signal<T>;
34
+ readonly focusedDate: import("@angular/core").WritableSignal<T>;
42
35
  /**
43
36
  * The selected start date
44
37
  */
@@ -1,6 +1,6 @@
1
1
  import { ActiveDescendantKeyManager } from '@angular/cdk/a11y';
2
2
  import * as i0 from '@angular/core';
3
- import { InjectionToken, inject, input, linkedSignal, signal, effect, forwardRef, Optional, Inject, Directive, Injector, output, computed, contentChild, contentChildren, untracked, TemplateRef, ViewContainerRef, PLATFORM_ID, ElementRef, booleanAttribute } from '@angular/core';
3
+ import { InjectionToken, inject, model, output, signal, effect, forwardRef, Optional, Inject, Directive, Injector, input, computed, contentChild, contentChildren, untracked, TemplateRef, ViewContainerRef, PLATFORM_ID, ElementRef, booleanAttribute } from '@angular/core';
4
4
  import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
5
5
  import { BrnPopover } from '@spartan-ng/brain/popover';
6
6
  import { DefaultValueAccessor, COMPOSITION_BUFFER_MODE, NG_VALUE_ACCESSOR } from '@angular/forms';
@@ -29,9 +29,10 @@ class BrnAutocompleteSearchInput extends DefaultValueAccessor {
29
29
  elementRef;
30
30
  _autocomplete = injectBrnAutocomplete();
31
31
  /** The initial value of the search input */
32
- value = input('');
33
- /** @internal The "real" value of the search input */
34
- valueState = linkedSignal(() => this.value());
32
+ value = model('');
33
+ /** Emitted when the value changes */
34
+ valueChange = output();
35
+ /** Whether the autocomplete panel is expanded */
35
36
  _isExpanded = this._autocomplete.isExpanded;
36
37
  /** The id of the active option */
37
38
  _activeDescendant = signal(undefined);
@@ -42,12 +43,14 @@ class BrnAutocompleteSearchInput extends DefaultValueAccessor {
42
43
  .pipe(startWith(this._autocomplete.keyManager.activeItemIndex), takeUntilDestroyed())
43
44
  .subscribe(() => this._activeDescendant.set(this._autocomplete.keyManager.activeItem?.id()));
44
45
  effect(() => {
45
- this.elementRef.nativeElement.value = this.valueState();
46
+ const value = this.value();
47
+ this.elementRef.nativeElement.value = value;
48
+ this.valueChange.emit(value);
46
49
  });
47
50
  }
48
51
  /** Listen for changes to the input value */
49
52
  onInput() {
50
- this.valueState.set(this.elementRef.nativeElement.value);
53
+ this.value.set(this.elementRef.nativeElement.value);
51
54
  }
52
55
  /** Listen for keydown events */
53
56
  onKeyDown(event) {
@@ -55,17 +58,28 @@ class BrnAutocompleteSearchInput extends DefaultValueAccessor {
55
58
  // prevent form submission if inside a form
56
59
  event.preventDefault();
57
60
  }
61
+ if (!this._isExpanded()) {
62
+ if (event.key === 'ArrowDown') {
63
+ this._autocomplete.open('first');
64
+ }
65
+ if (event.key === 'ArrowUp') {
66
+ this._autocomplete.open('last');
67
+ }
68
+ if (event.key === 'Escape') {
69
+ this.value.set('');
70
+ }
71
+ }
58
72
  this._autocomplete.keyManager.onKeydown(event);
59
73
  }
60
74
  /** CONROL VALUE ACCESSOR */
61
75
  writeValue(value) {
62
76
  super.writeValue(value);
63
77
  if (value) {
64
- this.valueState.set(value);
78
+ this.value.set(value);
65
79
  }
66
80
  }
67
81
  /** @nocollapse */ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: BrnAutocompleteSearchInput, deps: [{ token: i0.Renderer2 }, { token: i0.ElementRef }, { token: COMPOSITION_BUFFER_MODE, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
68
- /** @nocollapse */ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.8", type: BrnAutocompleteSearchInput, isStandalone: true, selector: "input[brnAutocompleteSearchInput]", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "combobox", "aria-autocomplete": "list" }, listeners: { "keydown": "onKeyDown($event)", "input": "onInput()" }, properties: { "attr.aria-activedescendant": "_activeDescendant()", "attr.aria-expanded": "_isExpanded()" } }, providers: [
82
+ /** @nocollapse */ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.8", type: BrnAutocompleteSearchInput, isStandalone: true, selector: "input[brnAutocompleteSearchInput]", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", valueChange: "valueChange" }, host: { attributes: { "role": "combobox", "aria-autocomplete": "list" }, listeners: { "keydown": "onKeyDown($event)", "input": "onInput()" }, properties: { "attr.aria-activedescendant": "_activeDescendant()", "attr.aria-expanded": "_isExpanded()" } }, providers: [
69
83
  provideBrnAutocompleteSearchInput(BrnAutocompleteSearchInput),
70
84
  {
71
85
  provide: NG_VALUE_ACCESSOR,
@@ -110,13 +124,15 @@ class BrnAutocomplete {
110
124
  /** when the selection has changed */
111
125
  valueChange = output();
112
126
  /** @internal The search query */
113
- search = computed(() => this._searchInput()?.valueState() ?? '');
127
+ search = computed(() => this._searchInput()?.value() ?? '');
114
128
  /** Access the popover if present */
115
129
  _brnPopover = inject(BrnPopover, { optional: true });
116
130
  /** Access the search input if present */
117
131
  _searchInput = contentChild(BrnAutocompleteSearchInput, {
118
132
  descendants: true,
119
133
  });
134
+ /** @internal The focus strategy when opening */
135
+ _focus = signal('first');
120
136
  /** @internal Access all the items within the autocomplete */
121
137
  items = contentChildren(BrnAutocompleteItemToken, {
122
138
  descendants: true,
@@ -133,10 +149,13 @@ class BrnAutocomplete {
133
149
  .skipPredicate((item) => item.disabled);
134
150
  effect(() => {
135
151
  const items = this.items();
152
+ const focus = this._focus();
136
153
  untracked(() => {
154
+ if (!items.length)
155
+ return;
137
156
  const activeItem = this.keyManager.activeItem;
138
- if (!activeItem || !items.includes(activeItem) || items[0] !== activeItem) {
139
- this.keyManager.setFirstItemActive();
157
+ if (!activeItem || !items.includes(activeItem)) {
158
+ focus === 'first' ? this.keyManager.setFirstItemActive() : this.keyManager.setLastItemActive();
140
159
  }
141
160
  });
142
161
  });
@@ -152,6 +171,16 @@ class BrnAutocomplete {
152
171
  this.keyManager.activeItem?.selected.emit();
153
172
  }
154
173
  }
174
+ open(focus = 'first') {
175
+ this._brnPopover?.open();
176
+ this._focus.set(focus);
177
+ }
178
+ close() {
179
+ this._brnPopover?.close();
180
+ }
181
+ toggle() {
182
+ this.isExpanded() ? this.close() : this.open();
183
+ }
155
184
  /** @nocollapse */ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: BrnAutocomplete, deps: [], target: i0.ɵɵFactoryTarget.Directive });
156
185
  /** @nocollapse */ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.2.0", version: "19.2.8", type: BrnAutocomplete, isStandalone: true, selector: "[brnAutocomplete]", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange" }, host: { listeners: { "keydown.enter": "selectActiveItem()" }, properties: { "id": "id()" } }, providers: [provideBrnAutocomplete(BrnAutocomplete)], queries: [{ propertyName: "_searchInput", first: true, predicate: BrnAutocompleteSearchInput, descendants: true, isSignal: true }, { propertyName: "items", predicate: BrnAutocompleteItemToken, descendants: true, isSignal: true }], ngImport: i0 });
157
186
  }
@@ -1 +1 @@
1
- {"version":3,"file":"spartan-ng-brain-autocomplete.mjs","sources":["../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-item.token.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-search-input.token.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete.token.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-search-input.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-empty.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-group.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-item.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-list.ts","../../../../libs/brain/autocomplete/src/index.ts","../../../../libs/brain/autocomplete/src/spartan-ng-brain-autocomplete.ts"],"sourcesContent":["import { type ExistingProvider, InjectionToken, type Type } from '@angular/core';\nimport type { BrnAutocompleteItem } from './brn-autocomplete-item';\n\nexport const BrnAutocompleteItemToken = new InjectionToken<BrnAutocompleteItem<unknown>>('BrnAutocompleteItemToken');\n\nexport function provideBrnAutocompleteItem<T>(autocomplete: Type<BrnAutocompleteItem<T>>): ExistingProvider {\n\treturn { provide: BrnAutocompleteItemToken, useExisting: autocomplete };\n}\n","import { type ExistingProvider, InjectionToken, type Type } from '@angular/core';\nimport type { BrnAutocompleteSearchInput } from './brn-autocomplete-search-input';\n\nexport const BrnAutocompleteSearchInputToken = new InjectionToken<BrnAutocompleteSearchInput>(\n\t'BrnAutocompleteSearchInputToken',\n);\n\nexport function provideBrnAutocompleteSearchInput(autocomplete: Type<BrnAutocompleteSearchInput>): ExistingProvider {\n\treturn { provide: BrnAutocompleteSearchInputToken, useExisting: autocomplete };\n}\n","import { type ExistingProvider, inject, InjectionToken, type Type } from '@angular/core';\nimport type { BrnAutocomplete } from './brn-autocomplete';\n\nexport const BrnAutocompleteToken = new InjectionToken<BrnAutocomplete<unknown>>('BrnAutocompleteToken');\n\nexport function provideBrnAutocomplete<T>(autocomplete: Type<BrnAutocomplete<T>>): ExistingProvider {\n\treturn { provide: BrnAutocompleteToken, useExisting: autocomplete };\n}\n\nexport function injectBrnAutocomplete<T>(): BrnAutocomplete<T> {\n\treturn inject(BrnAutocompleteToken) as BrnAutocomplete<T>;\n}\n","import {\n\tDirective,\n\teffect,\n\tElementRef,\n\tforwardRef,\n\tInject,\n\tinput,\n\tlinkedSignal,\n\tOptional,\n\tRenderer2,\n\tsignal,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { COMPOSITION_BUFFER_MODE, DefaultValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { startWith } from 'rxjs/operators';\nimport { provideBrnAutocompleteSearchInput } from './brn-autocomplete-search-input.token';\nimport { injectBrnAutocomplete } from './brn-autocomplete.token';\n\n@Directive({\n\tselector: 'input[brnAutocompleteSearchInput]',\n\tproviders: [\n\t\tprovideBrnAutocompleteSearchInput(BrnAutocompleteSearchInput),\n\t\t{\n\t\t\tprovide: NG_VALUE_ACCESSOR,\n\t\t\tuseExisting: forwardRef(() => BrnAutocompleteSearchInput),\n\t\t\tmulti: true,\n\t\t},\n\t],\n\thost: {\n\t\trole: 'combobox',\n\t\t'aria-autocomplete': 'list',\n\t\t'[attr.aria-activedescendant]': '_activeDescendant()',\n\t\t'[attr.aria-expanded]': '_isExpanded()',\n\t\t'(keydown)': 'onKeyDown($event)',\n\t\t'(input)': 'onInput()',\n\t},\n})\nexport class BrnAutocompleteSearchInput extends DefaultValueAccessor {\n\tprivate readonly _autocomplete = injectBrnAutocomplete();\n\n\t/** The initial value of the search input */\n\tpublic readonly value = input<string>('');\n\n\t/** @internal The \"real\" value of the search input */\n\tpublic readonly valueState = linkedSignal(() => this.value());\n\n\tprotected readonly _isExpanded = this._autocomplete.isExpanded;\n\n\t/** The id of the active option */\n\tprotected readonly _activeDescendant = signal<string | undefined>(undefined);\n\n\tconstructor(\n\t\trenderer: Renderer2,\n\t\tprivate readonly elementRef: ElementRef,\n\t\t@Optional() @Inject(COMPOSITION_BUFFER_MODE) compositionMode: boolean,\n\t) {\n\t\tsuper(renderer, elementRef, compositionMode);\n\t\tthis._autocomplete.keyManager.change\n\t\t\t.pipe(startWith(this._autocomplete.keyManager.activeItemIndex), takeUntilDestroyed())\n\t\t\t.subscribe(() => this._activeDescendant.set(this._autocomplete.keyManager.activeItem?.id()));\n\n\t\teffect(() => {\n\t\t\tthis.elementRef.nativeElement.value = this.valueState();\n\t\t});\n\t}\n\t/** Listen for changes to the input value */\n\tprotected onInput(): void {\n\t\tthis.valueState.set(this.elementRef.nativeElement.value);\n\t}\n\n\t/** Listen for keydown events */\n\tprotected onKeyDown(event: KeyboardEvent): void {\n\t\tif (event.key === 'Enter') {\n\t\t\t// prevent form submission if inside a form\n\t\t\tevent.preventDefault();\n\t\t}\n\n\t\tthis._autocomplete.keyManager.onKeydown(event);\n\t}\n\n\t/** CONROL VALUE ACCESSOR */\n\toverride writeValue(value: string | null): void {\n\t\tsuper.writeValue(value);\n\t\tif (value) {\n\t\t\tthis.valueState.set(value);\n\t\t}\n\t}\n}\n","import { ActiveDescendantKeyManager } from '@angular/cdk/a11y';\nimport {\n\tcomputed,\n\tcontentChild,\n\tcontentChildren,\n\tDirective,\n\teffect,\n\tinject,\n\tInjector,\n\tinput,\n\toutput,\n\tuntracked,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { BrnPopover } from '@spartan-ng/brain/popover';\nimport type { BrnAutocompleteItem } from './brn-autocomplete-item';\nimport { BrnAutocompleteItemToken } from './brn-autocomplete-item.token';\nimport { BrnAutocompleteSearchInput } from './brn-autocomplete-search-input';\nimport { provideBrnAutocomplete } from './brn-autocomplete.token';\n\n@Directive({\n\tselector: '[brnAutocomplete]',\n\tproviders: [provideBrnAutocomplete(BrnAutocomplete)],\n\thost: {\n\t\t'[id]': 'id()',\n\t\t'(keydown.enter)': 'selectActiveItem()',\n\t},\n})\nexport class BrnAutocomplete<T> {\n\tprivate static _id = 0;\n\n\tprivate readonly _injector = inject(Injector);\n\n\t/** The id of the autocomplete */\n\tpublic readonly id = input<string>(`brn-autocomplete-${++BrnAutocomplete._id}`);\n\n\t/** when the selection has changed */\n\tpublic readonly valueChange = output<T>();\n\n\t/** @internal The search query */\n\tpublic readonly search = computed(() => this._searchInput()?.valueState() ?? '');\n\n\t/** Access the popover if present */\n\tprivate readonly _brnPopover = inject(BrnPopover, { optional: true });\n\n\t/** Access the search input if present */\n\tprivate readonly _searchInput = contentChild(BrnAutocompleteSearchInput, {\n\t\tdescendants: true,\n\t});\n\n\t/** @internal Access all the items within the autocomplete */\n\tpublic readonly items = contentChildren<BrnAutocompleteItem<T>>(BrnAutocompleteItemToken, {\n\t\tdescendants: true,\n\t});\n\n\t/** @internal The key manager for managing active descendant */\n\tpublic readonly keyManager = new ActiveDescendantKeyManager(this.items, this._injector);\n\n\t/** @internal Whether the autocomplete is expanded */\n\tpublic readonly isExpanded = computed(() => this._brnPopover?.stateComputed() === 'open');\n\n\tconstructor() {\n\t\tthis.keyManager\n\t\t\t.withVerticalOrientation()\n\t\t\t.withHomeAndEnd()\n\t\t\t.withWrap()\n\t\t\t.skipPredicate((item) => item.disabled);\n\n\t\teffect(() => {\n\t\t\tconst items = this.items();\n\n\t\t\tuntracked(() => {\n\t\t\t\tconst activeItem = this.keyManager.activeItem;\n\t\t\t\tif (!activeItem || !items.includes(activeItem) || items[0] !== activeItem) {\n\t\t\t\t\tthis.keyManager.setFirstItemActive();\n\t\t\t\t}\n\t\t\t});\n\t\t});\n\n\t\tthis.keyManager.change.pipe(takeUntilDestroyed()).subscribe(() => {\n\t\t\tconst value = this.keyManager.activeItem?.value();\n\t\t\tif (value) {\n\t\t\t\tthis.valueChange.emit(value);\n\t\t\t}\n\t\t});\n\t}\n\n\tprotected selectActiveItem(): void {\n\t\tif (this._brnPopover?.stateComputed() === 'open') {\n\t\t\tthis.keyManager.activeItem?.selected.emit();\n\t\t}\n\t}\n}\n","import { computed, Directive, effect, inject, TemplateRef, ViewContainerRef } from '@angular/core';\nimport { injectBrnAutocomplete } from './brn-autocomplete.token';\n\n@Directive({\n\tselector: '[brnAutocompleteEmpty]',\n})\nexport class BrnAutocompleteEmpty {\n\tprivate readonly _templateRef = inject<TemplateRef<void>>(TemplateRef);\n\tprivate readonly _viewContainerRef = inject(ViewContainerRef);\n\tprivate readonly _autocomplete = injectBrnAutocomplete();\n\n\t/** Determine if the autocomplete has any items */\n\tprivate readonly _visible = computed(() => this._autocomplete.items().length > 0);\n\n\tconstructor() {\n\t\teffect(() => {\n\t\t\tif (this._visible()) {\n\t\t\t\tthis._viewContainerRef.clear();\n\t\t\t} else {\n\t\t\t\tthis._viewContainerRef.createEmbeddedView(this._templateRef);\n\t\t\t}\n\t\t});\n\t}\n}\n","import { Directive, input } from '@angular/core';\n\n@Directive({\n\tselector: '[brnAutocompleteGroup]',\n\thost: {\n\t\trole: 'group',\n\t\t'[id]': 'id()',\n\t},\n})\nexport class BrnAutocompleteGroup {\n\tprivate static _id = 0;\n\n\t/** The id of the autocomplete list */\n\tpublic readonly id = input<string>(`brn-autocomplete-group-${++BrnAutocompleteGroup._id}`);\n}\n","import type { Highlightable } from '@angular/cdk/a11y';\nimport type { BooleanInput } from '@angular/cdk/coercion';\nimport { isPlatformBrowser } from '@angular/common';\nimport { booleanAttribute, Directive, ElementRef, inject, input, output, PLATFORM_ID, signal } from '@angular/core';\nimport { provideBrnAutocompleteItem } from './brn-autocomplete-item.token';\nimport { injectBrnAutocomplete } from './brn-autocomplete.token';\n\n@Directive({\n\tselector: 'button[brnAutocompleteItem]',\n\tproviders: [provideBrnAutocompleteItem(BrnAutocompleteItem)],\n\thost: {\n\t\ttype: 'button',\n\t\trole: 'option',\n\t\ttabIndex: '-1',\n\t\t'[id]': 'id()',\n\t\t'[attr.disabled]': '_disabled() ? true : null',\n\t\t'[attr.data-disabled]': '_disabled() ? \"\" : null',\n\t\t'[attr.data-value]': 'value()',\n\t\t'[attr.aria-selected]': '_active()',\n\t\t'[attr.data-selected]': \"_active() ? '' : null\",\n\t\t'(click)': 'onClick()',\n\t\t'(mouseenter)': 'activate()',\n\t},\n})\nexport class BrnAutocompleteItem<T> implements Highlightable {\n\tprivate static _id = 0;\n\n\tprivate readonly _platform = inject(PLATFORM_ID);\n\n\tprivate readonly _elementRef = inject<ElementRef<HTMLElement>>(ElementRef);\n\n\t/** Access the autocomplete component */\n\tprivate readonly _autocomplete = injectBrnAutocomplete<T>();\n\n\t/** A unique id for the item */\n\tpublic readonly id = input(`brn-autocomplete-item-${++BrnAutocompleteItem._id}`);\n\n\t/** The value this item represents. */\n\tpublic readonly value = input.required<T>();\n\n\t/** Whether the item is disabled. */\n\t// eslint-disable-next-line @typescript-eslint/naming-convention\n\tpublic readonly _disabled = input<boolean, BooleanInput>(false, {\n\t\talias: 'disabled',\n\t\ttransform: booleanAttribute,\n\t});\n\n\t/** Expose disabled as a value - used by the Highlightable interface */\n\tpublic get disabled() {\n\t\treturn this._disabled();\n\t}\n\n\t/** Whether the item is selected. */\n\tprotected readonly _active = signal(false);\n\n\t/** Emits when the item is selected. */\n\tpublic readonly selected = output<void>();\n\n\t/** @internal Get the display value */\n\tpublic getLabel(): string {\n\t\treturn this._elementRef.nativeElement.textContent?.trim() ?? '';\n\t}\n\n\t/** @internal */\n\tsetActiveStyles(): void {\n\t\tthis._active.set(true);\n\n\t\t// ensure the item is in view\n\t\tif (isPlatformBrowser(this._platform)) {\n\t\t\tthis._elementRef.nativeElement.scrollIntoView({ block: 'nearest' });\n\t\t}\n\t}\n\n\t/** @internal */\n\tsetInactiveStyles(): void {\n\t\tthis._active.set(false);\n\t}\n\n\tprotected onClick(): void {\n\t\tthis._autocomplete.keyManager.setActiveItem(this);\n\t\tthis.selected.emit();\n\t}\n\n\tprotected activate(): void {\n\t\tif (this._disabled()) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._autocomplete.keyManager.setActiveItem(this);\n\t}\n}\n","import { Directive, input } from '@angular/core';\n\n@Directive({\n\tselector: '[brnAutocompleteList]',\n\thost: {\n\t\trole: 'listbox',\n\t\t'[id]': 'id()',\n\t},\n})\nexport class BrnAutocompleteList {\n\tprivate static _id = 0;\n\n\t/** The id of the command list */\n\tpublic readonly id = input<string>(`brn-autocomplete-list-${++BrnAutocompleteList._id}`);\n}\n","import { BrnAutocomplete } from './lib/brn-autocomplete';\nimport { BrnAutocompleteEmpty } from './lib/brn-autocomplete-empty';\nimport { BrnAutocompleteGroup } from './lib/brn-autocomplete-group';\nimport { BrnAutocompleteItem } from './lib/brn-autocomplete-item';\nimport { BrnAutocompleteList } from './lib/brn-autocomplete-list';\nimport { BrnAutocompleteSearchInput } from './lib/brn-autocomplete-search-input';\n\nexport * from './lib/brn-autocomplete';\nexport * from './lib/brn-autocomplete-empty';\nexport * from './lib/brn-autocomplete-group';\nexport * from './lib/brn-autocomplete-item';\nexport * from './lib/brn-autocomplete-item.token';\nexport * from './lib/brn-autocomplete-list';\nexport * from './lib/brn-autocomplete-search-input';\nexport * from './lib/brn-autocomplete-search-input.token';\nexport * from './lib/brn-autocomplete.token';\n\nexport const BrnAutocompleteImports = [\n\tBrnAutocomplete,\n\tBrnAutocompleteEmpty,\n\tBrnAutocompleteGroup,\n\tBrnAutocompleteItem,\n\tBrnAutocompleteList,\n\tBrnAutocompleteSearchInput,\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;MAGa,wBAAwB,GAAG,IAAI,cAAc,CAA+B,0BAA0B;AAE7G,SAAU,0BAA0B,CAAI,YAA0C,EAAA;IACvF,OAAO,EAAE,OAAO,EAAE,wBAAwB,EAAE,WAAW,EAAE,YAAY,EAAE;AACxE;;MCJa,+BAA+B,GAAG,IAAI,cAAc,CAChE,iCAAiC;AAG5B,SAAU,iCAAiC,CAAC,YAA8C,EAAA;IAC/F,OAAO,EAAE,OAAO,EAAE,+BAA+B,EAAE,WAAW,EAAE,YAAY,EAAE;AAC/E;;MCNa,oBAAoB,GAAG,IAAI,cAAc,CAA2B,sBAAsB;AAEjG,SAAU,sBAAsB,CAAI,YAAsC,EAAA;IAC/E,OAAO,EAAE,OAAO,EAAE,oBAAoB,EAAE,WAAW,EAAE,YAAY,EAAE;AACpE;SAEgB,qBAAqB,GAAA;AACpC,IAAA,OAAO,MAAM,CAAC,oBAAoB,CAAuB;AAC1D;;AC0BM,MAAO,0BAA2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nB,mBAAmB;IACnB,0BAA0B;;;ACvB3B;;AAEG;;;;"}
1
+ {"version":3,"file":"spartan-ng-brain-autocomplete.mjs","sources":["../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-item.token.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-search-input.token.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete.token.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-search-input.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-empty.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-group.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-item.ts","../../../../libs/brain/autocomplete/src/lib/brn-autocomplete-list.ts","../../../../libs/brain/autocomplete/src/index.ts","../../../../libs/brain/autocomplete/src/spartan-ng-brain-autocomplete.ts"],"sourcesContent":["import { type ExistingProvider, InjectionToken, type Type } from '@angular/core';\nimport type { BrnAutocompleteItem } from './brn-autocomplete-item';\n\nexport const BrnAutocompleteItemToken = new InjectionToken<BrnAutocompleteItem<unknown>>('BrnAutocompleteItemToken');\n\nexport function provideBrnAutocompleteItem<T>(autocomplete: Type<BrnAutocompleteItem<T>>): ExistingProvider {\n\treturn { provide: BrnAutocompleteItemToken, useExisting: autocomplete };\n}\n","import { type ExistingProvider, InjectionToken, type Type } from '@angular/core';\nimport type { BrnAutocompleteSearchInput } from './brn-autocomplete-search-input';\n\nexport const BrnAutocompleteSearchInputToken = new InjectionToken<BrnAutocompleteSearchInput>(\n\t'BrnAutocompleteSearchInputToken',\n);\n\nexport function provideBrnAutocompleteSearchInput(autocomplete: Type<BrnAutocompleteSearchInput>): ExistingProvider {\n\treturn { provide: BrnAutocompleteSearchInputToken, useExisting: autocomplete };\n}\n","import { type ExistingProvider, inject, InjectionToken, type Type } from '@angular/core';\nimport type { BrnAutocomplete } from './brn-autocomplete';\n\nexport const BrnAutocompleteToken = new InjectionToken<BrnAutocomplete<unknown>>('BrnAutocompleteToken');\n\nexport function provideBrnAutocomplete<T>(autocomplete: Type<BrnAutocomplete<T>>): ExistingProvider {\n\treturn { provide: BrnAutocompleteToken, useExisting: autocomplete };\n}\n\nexport function injectBrnAutocomplete<T>(): BrnAutocomplete<T> {\n\treturn inject(BrnAutocompleteToken) as BrnAutocomplete<T>;\n}\n","import {\n\tDirective,\n\teffect,\n\tElementRef,\n\tforwardRef,\n\tInject,\n\tmodel,\n\tOptional,\n\toutput,\n\tRenderer2,\n\tsignal,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { COMPOSITION_BUFFER_MODE, DefaultValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { startWith } from 'rxjs/operators';\nimport { provideBrnAutocompleteSearchInput } from './brn-autocomplete-search-input.token';\nimport { injectBrnAutocomplete } from './brn-autocomplete.token';\n\n@Directive({\n\tselector: 'input[brnAutocompleteSearchInput]',\n\tproviders: [\n\t\tprovideBrnAutocompleteSearchInput(BrnAutocompleteSearchInput),\n\t\t{\n\t\t\tprovide: NG_VALUE_ACCESSOR,\n\t\t\tuseExisting: forwardRef(() => BrnAutocompleteSearchInput),\n\t\t\tmulti: true,\n\t\t},\n\t],\n\thost: {\n\t\trole: 'combobox',\n\t\t'aria-autocomplete': 'list',\n\t\t'[attr.aria-activedescendant]': '_activeDescendant()',\n\t\t'[attr.aria-expanded]': '_isExpanded()',\n\t\t'(keydown)': 'onKeyDown($event)',\n\t\t'(input)': 'onInput()',\n\t},\n})\nexport class BrnAutocompleteSearchInput extends DefaultValueAccessor {\n\tprivate readonly _autocomplete = injectBrnAutocomplete();\n\n\t/** The initial value of the search input */\n\tpublic readonly value = model<string>('');\n\n\t/** Emitted when the value changes */\n\tpublic readonly valueChange = output<string>();\n\n\t/** Whether the autocomplete panel is expanded */\n\tprotected readonly _isExpanded = this._autocomplete.isExpanded;\n\n\t/** The id of the active option */\n\tprotected readonly _activeDescendant = signal<string | undefined>(undefined);\n\n\tconstructor(\n\t\trenderer: Renderer2,\n\t\tprivate readonly elementRef: ElementRef,\n\t\t@Optional() @Inject(COMPOSITION_BUFFER_MODE) compositionMode: boolean,\n\t) {\n\t\tsuper(renderer, elementRef, compositionMode);\n\t\tthis._autocomplete.keyManager.change\n\t\t\t.pipe(startWith(this._autocomplete.keyManager.activeItemIndex), takeUntilDestroyed())\n\t\t\t.subscribe(() => this._activeDescendant.set(this._autocomplete.keyManager.activeItem?.id()));\n\n\t\teffect(() => {\n\t\t\tconst value = this.value();\n\t\t\tthis.elementRef.nativeElement.value = value;\n\t\t\tthis.valueChange.emit(value);\n\t\t});\n\t}\n\t/** Listen for changes to the input value */\n\tprotected onInput(): void {\n\t\tthis.value.set(this.elementRef.nativeElement.value);\n\t}\n\n\t/** Listen for keydown events */\n\tprotected onKeyDown(event: KeyboardEvent): void {\n\t\tif (event.key === 'Enter') {\n\t\t\t// prevent form submission if inside a form\n\t\t\tevent.preventDefault();\n\t\t}\n\n\t\tif (!this._isExpanded()) {\n\t\t\tif (event.key === 'ArrowDown') {\n\t\t\t\tthis._autocomplete.open('first');\n\t\t\t}\n\n\t\t\tif (event.key === 'ArrowUp') {\n\t\t\t\tthis._autocomplete.open('last');\n\t\t\t}\n\n\t\t\tif (event.key === 'Escape') {\n\t\t\t\tthis.value.set('');\n\t\t\t}\n\t\t}\n\n\t\tthis._autocomplete.keyManager.onKeydown(event);\n\t}\n\n\t/** CONROL VALUE ACCESSOR */\n\toverride writeValue(value: string | null): void {\n\t\tsuper.writeValue(value);\n\t\tif (value) {\n\t\t\tthis.value.set(value);\n\t\t}\n\t}\n}\n","import { ActiveDescendantKeyManager } from '@angular/cdk/a11y';\nimport {\n\tcomputed,\n\tcontentChild,\n\tcontentChildren,\n\tDirective,\n\teffect,\n\tinject,\n\tInjector,\n\tinput,\n\toutput,\n\tsignal,\n\tuntracked,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { BrnPopover } from '@spartan-ng/brain/popover';\nimport type { BrnAutocompleteItem } from './brn-autocomplete-item';\nimport { BrnAutocompleteItemToken } from './brn-autocomplete-item.token';\nimport { BrnAutocompleteSearchInput } from './brn-autocomplete-search-input';\nimport { provideBrnAutocomplete } from './brn-autocomplete.token';\n\n@Directive({\n\tselector: '[brnAutocomplete]',\n\tproviders: [provideBrnAutocomplete(BrnAutocomplete)],\n\thost: {\n\t\t'[id]': 'id()',\n\t\t'(keydown.enter)': 'selectActiveItem()',\n\t},\n})\nexport class BrnAutocomplete<T> {\n\tprivate static _id = 0;\n\n\tprivate readonly _injector = inject(Injector);\n\n\t/** The id of the autocomplete */\n\tpublic readonly id = input<string>(`brn-autocomplete-${++BrnAutocomplete._id}`);\n\n\t/** when the selection has changed */\n\tpublic readonly valueChange = output<T>();\n\n\t/** @internal The search query */\n\tpublic readonly search = computed(() => this._searchInput()?.value() ?? '');\n\n\t/** Access the popover if present */\n\tprivate readonly _brnPopover = inject(BrnPopover, { optional: true });\n\n\t/** Access the search input if present */\n\tprivate readonly _searchInput = contentChild(BrnAutocompleteSearchInput, {\n\t\tdescendants: true,\n\t});\n\n\t/** @internal The focus strategy when opening */\n\tprivate readonly _focus = signal<'first' | 'last'>('first');\n\n\t/** @internal Access all the items within the autocomplete */\n\tpublic readonly items = contentChildren<BrnAutocompleteItem<T>>(BrnAutocompleteItemToken, {\n\t\tdescendants: true,\n\t});\n\n\t/** @internal The key manager for managing active descendant */\n\tpublic readonly keyManager = new ActiveDescendantKeyManager(this.items, this._injector);\n\n\t/** @internal Whether the autocomplete is expanded */\n\tpublic readonly isExpanded = computed(() => this._brnPopover?.stateComputed() === 'open');\n\n\tconstructor() {\n\t\tthis.keyManager\n\t\t\t.withVerticalOrientation()\n\t\t\t.withHomeAndEnd()\n\t\t\t.withWrap()\n\t\t\t.skipPredicate((item) => item.disabled);\n\n\t\teffect(() => {\n\t\t\tconst items = this.items();\n\t\t\tconst focus = this._focus();\n\n\t\t\tuntracked(() => {\n\t\t\t\tif (!items.length) return;\n\n\t\t\t\tconst activeItem = this.keyManager.activeItem;\n\n\t\t\t\tif (!activeItem || !items.includes(activeItem)) {\n\t\t\t\t\tfocus === 'first' ? this.keyManager.setFirstItemActive() : this.keyManager.setLastItemActive();\n\t\t\t\t}\n\t\t\t});\n\t\t});\n\n\t\tthis.keyManager.change.pipe(takeUntilDestroyed()).subscribe(() => {\n\t\t\tconst value = this.keyManager.activeItem?.value();\n\t\t\tif (value) {\n\t\t\t\tthis.valueChange.emit(value);\n\t\t\t}\n\t\t});\n\t}\n\n\tprotected selectActiveItem(): void {\n\t\tif (this._brnPopover?.stateComputed() === 'open') {\n\t\t\tthis.keyManager.activeItem?.selected.emit();\n\t\t}\n\t}\n\n\topen(focus: 'first' | 'last' = 'first') {\n\t\tthis._brnPopover?.open();\n\t\tthis._focus.set(focus);\n\t}\n\n\tclose() {\n\t\tthis._brnPopover?.close();\n\t}\n\n\ttoggle() {\n\t\tthis.isExpanded() ? this.close() : this.open();\n\t}\n}\n","import { computed, Directive, effect, inject, TemplateRef, ViewContainerRef } from '@angular/core';\nimport { injectBrnAutocomplete } from './brn-autocomplete.token';\n\n@Directive({\n\tselector: '[brnAutocompleteEmpty]',\n})\nexport class BrnAutocompleteEmpty {\n\tprivate readonly _templateRef = inject<TemplateRef<void>>(TemplateRef);\n\tprivate readonly _viewContainerRef = inject(ViewContainerRef);\n\tprivate readonly _autocomplete = injectBrnAutocomplete();\n\n\t/** Determine if the autocomplete has any items */\n\tprivate readonly _visible = computed(() => this._autocomplete.items().length > 0);\n\n\tconstructor() {\n\t\teffect(() => {\n\t\t\tif (this._visible()) {\n\t\t\t\tthis._viewContainerRef.clear();\n\t\t\t} else {\n\t\t\t\tthis._viewContainerRef.createEmbeddedView(this._templateRef);\n\t\t\t}\n\t\t});\n\t}\n}\n","import { Directive, input } from '@angular/core';\n\n@Directive({\n\tselector: '[brnAutocompleteGroup]',\n\thost: {\n\t\trole: 'group',\n\t\t'[id]': 'id()',\n\t},\n})\nexport class BrnAutocompleteGroup {\n\tprivate static _id = 0;\n\n\t/** The id of the autocomplete list */\n\tpublic readonly id = input<string>(`brn-autocomplete-group-${++BrnAutocompleteGroup._id}`);\n}\n","import type { Highlightable } from '@angular/cdk/a11y';\nimport type { BooleanInput } from '@angular/cdk/coercion';\nimport { isPlatformBrowser } from '@angular/common';\nimport { booleanAttribute, Directive, ElementRef, inject, input, output, PLATFORM_ID, signal } from '@angular/core';\nimport { provideBrnAutocompleteItem } from './brn-autocomplete-item.token';\nimport { injectBrnAutocomplete } from './brn-autocomplete.token';\n\n@Directive({\n\tselector: 'button[brnAutocompleteItem]',\n\tproviders: [provideBrnAutocompleteItem(BrnAutocompleteItem)],\n\thost: {\n\t\ttype: 'button',\n\t\trole: 'option',\n\t\ttabIndex: '-1',\n\t\t'[id]': 'id()',\n\t\t'[attr.disabled]': '_disabled() ? true : null',\n\t\t'[attr.data-disabled]': '_disabled() ? \"\" : null',\n\t\t'[attr.data-value]': 'value()',\n\t\t'[attr.aria-selected]': '_active()',\n\t\t'[attr.data-selected]': \"_active() ? '' : null\",\n\t\t'(click)': 'onClick()',\n\t\t'(mouseenter)': 'activate()',\n\t},\n})\nexport class BrnAutocompleteItem<T> implements Highlightable {\n\tprivate static _id = 0;\n\n\tprivate readonly _platform = inject(PLATFORM_ID);\n\n\tprivate readonly _elementRef = inject<ElementRef<HTMLElement>>(ElementRef);\n\n\t/** Access the autocomplete component */\n\tprivate readonly _autocomplete = injectBrnAutocomplete<T>();\n\n\t/** A unique id for the item */\n\tpublic readonly id = input(`brn-autocomplete-item-${++BrnAutocompleteItem._id}`);\n\n\t/** The value this item represents. */\n\tpublic readonly value = input.required<T>();\n\n\t/** Whether the item is disabled. */\n\t// eslint-disable-next-line @typescript-eslint/naming-convention\n\tpublic readonly _disabled = input<boolean, BooleanInput>(false, {\n\t\talias: 'disabled',\n\t\ttransform: booleanAttribute,\n\t});\n\n\t/** Expose disabled as a value - used by the Highlightable interface */\n\tpublic get disabled() {\n\t\treturn this._disabled();\n\t}\n\n\t/** Whether the item is selected. */\n\tprotected readonly _active = signal(false);\n\n\t/** Emits when the item is selected. */\n\tpublic readonly selected = output<void>();\n\n\t/** @internal Get the display value */\n\tpublic getLabel(): string {\n\t\treturn this._elementRef.nativeElement.textContent?.trim() ?? '';\n\t}\n\n\t/** @internal */\n\tsetActiveStyles(): void {\n\t\tthis._active.set(true);\n\n\t\t// ensure the item is in view\n\t\tif (isPlatformBrowser(this._platform)) {\n\t\t\tthis._elementRef.nativeElement.scrollIntoView({ block: 'nearest' });\n\t\t}\n\t}\n\n\t/** @internal */\n\tsetInactiveStyles(): void {\n\t\tthis._active.set(false);\n\t}\n\n\tprotected onClick(): void {\n\t\tthis._autocomplete.keyManager.setActiveItem(this);\n\t\tthis.selected.emit();\n\t}\n\n\tprotected activate(): void {\n\t\tif (this._disabled()) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._autocomplete.keyManager.setActiveItem(this);\n\t}\n}\n","import { Directive, input } from '@angular/core';\n\n@Directive({\n\tselector: '[brnAutocompleteList]',\n\thost: {\n\t\trole: 'listbox',\n\t\t'[id]': 'id()',\n\t},\n})\nexport class BrnAutocompleteList {\n\tprivate static _id = 0;\n\n\t/** The id of the command list */\n\tpublic readonly id = input<string>(`brn-autocomplete-list-${++BrnAutocompleteList._id}`);\n}\n","import { BrnAutocomplete } from './lib/brn-autocomplete';\nimport { BrnAutocompleteEmpty } from './lib/brn-autocomplete-empty';\nimport { BrnAutocompleteGroup } from './lib/brn-autocomplete-group';\nimport { BrnAutocompleteItem } from './lib/brn-autocomplete-item';\nimport { BrnAutocompleteList } from './lib/brn-autocomplete-list';\nimport { BrnAutocompleteSearchInput } from './lib/brn-autocomplete-search-input';\n\nexport * from './lib/brn-autocomplete';\nexport * from './lib/brn-autocomplete-empty';\nexport * from './lib/brn-autocomplete-group';\nexport * from './lib/brn-autocomplete-item';\nexport * from './lib/brn-autocomplete-item.token';\nexport * from './lib/brn-autocomplete-list';\nexport * from './lib/brn-autocomplete-search-input';\nexport * from './lib/brn-autocomplete-search-input.token';\nexport * from './lib/brn-autocomplete.token';\n\nexport const BrnAutocompleteImports = [\n\tBrnAutocomplete,\n\tBrnAutocompleteEmpty,\n\tBrnAutocompleteGroup,\n\tBrnAutocompleteItem,\n\tBrnAutocompleteList,\n\tBrnAutocompleteSearchInput,\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;MAGa,wBAAwB,GAAG,IAAI,cAAc,CAA+B,0BAA0B;AAE7G,SAAU,0BAA0B,CAAI,YAA0C,EAAA;IACvF,OAAO,EAAE,OAAO,EAAE,wBAAwB,EAAE,WAAW,EAAE,YAAY,EAAE;AACxE;;MCJa,+BAA+B,GAAG,IAAI,cAAc,CAChE,iCAAiC;AAG5B,SAAU,iCAAiC,CAAC,YAA8C,EAAA;IAC/F,OAAO,EAAE,OAAO,EAAE,+BAA+B,EAAE,WAAW,EAAE,YAAY,EAAE;AAC/E;;MCNa,oBAAoB,GAAG,IAAI,cAAc,CAA2B,sBAAsB;AAEjG,SAAU,sBAAsB,CAAI,YAAsC,EAAA;IAC/E,OAAO,EAAE,OAAO,EAAE,oBAAoB,EAAE,WAAW,EAAE,YAAY,EAAE;AACpE;SAEgB,qBAAqB,GAAA;AACpC,IAAA,OAAO,MAAM,CAAC,oBAAoB,CAAuB;AAC1D;;AC0BM,MAAO,0BAA2B,SAAQ,oBAAoB,CAAA;AAiBjD,IAAA,UAAA;IAhBD,aAAa,GAAG,qBAAqB,EAAE;;AAGxC,IAAA,KAAK,GAAG,KAAK,CAAS,EAAE,CAAC;;IAGzB,WAAW,GAAG,MAAM,EAAU;;AAG3B,IAAA,WAAW,GAAG,IAAI,CAAC,aAAa,CAAC,UAAU;;AAG3C,IAAA,iBAAiB,GAAG,MAAM,CAAqB,SAAS,CAAC;AAE5E,IAAA,WAAA,CACC,QAAmB,EACF,UAAsB,EACM,eAAwB,EAAA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AA,CAAA;8GAAnB,mBAAmB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,uBAAA,EAAA,MAAA,EAAA,EAAA,EAAA,EAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,MAAA,EAAA,SAAA,EAAA,EAAA,UAAA,EAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAAnB,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAP/B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,QAAQ,EAAE,uBAAuB;AACjC,oBAAA,IAAI,EAAE;AACL,wBAAA,IAAI,EAAE,SAAS;AACf,wBAAA,MAAM,EAAE,MAAM;AACd,qBAAA;AACD,iBAAA;;;ACSM,MAAM,sBAAsB,GAAG;IACrC,eAAe;IACf,oBAAoB;IACpB,oBAAoB;IACpB,mBAAmB;IACnB,mBAAmB;IACnB,0BAA0B;;;ACvB3B;;AAEG;;;;"}
@@ -1,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { InjectionToken, inject, ElementRef, input, computed, Directive, signal, Injectable, ChangeDetectorRef, Injector, booleanAttribute, model, numberAttribute, contentChild, contentChildren, afterNextRender, effect, HostListener, ViewContainerRef, TemplateRef, untracked } from '@angular/core';
2
+ import { InjectionToken, inject, ElementRef, input, computed, Directive, signal, Injectable, ChangeDetectorRef, Injector, booleanAttribute, model, numberAttribute, contentChild, contentChildren, linkedSignal, afterNextRender, effect, ViewContainerRef, TemplateRef, untracked } from '@angular/core';
3
3
  import { injectDateAdapter } from '@spartan-ng/brain/date-time';
4
4
  import { BrnSelect } from '@spartan-ng/brain/select';
5
5
 
@@ -289,24 +289,17 @@ class BrnCalendar {
289
289
  _cells = contentChildren(BrnCalendarCellButton, {
290
290
  descendants: true,
291
291
  });
292
- /**
293
- * @internal
294
- * The internal state of the component.
295
- */
296
- state = computed(() => ({
297
- focusedDate: signal(this.constrainDate(this.defaultFocusedDate() ?? this.date() ?? this._dateAdapter.now())),
298
- }));
299
292
  /**
300
293
  * The focused date.
301
294
  */
302
- focusedDate = computed(() => this.state().focusedDate());
295
+ focusedDate = linkedSignal(() => this.constrainDate(this.defaultFocusedDate() ?? this.date() ?? this._dateAdapter.now()));
303
296
  /**
304
297
  * Get all the days to display, this is the days of the current month
305
298
  * and the days of the previous and next month to fill the grid.
306
299
  */
307
300
  days = computed(() => {
308
301
  const weekStartsOn = this._weekStartsOn();
309
- const month = this.state().focusedDate();
302
+ const month = this.focusedDate();
310
303
  const days = [];
311
304
  // Get the first and last day of the month.
312
305
  let firstDay = this._dateAdapter.startOfMonth(month);
@@ -379,7 +372,7 @@ class BrnCalendar {
379
372
  else {
380
373
  this.date.set(date);
381
374
  }
382
- this.state().focusedDate.set(date);
375
+ this.focusedDate.set(date);
383
376
  }
384
377
  /** @internal Set the focused date */
385
378
  setFocusedDate(date) {
@@ -387,7 +380,7 @@ class BrnCalendar {
387
380
  if (this.isDateDisabled(date)) {
388
381
  return;
389
382
  }
390
- this.state().focusedDate.set(date);
383
+ this.focusedDate.set(date);
391
384
  // wait until the cells have all updated
392
385
  afterNextRender({
393
386
  write: () => {
@@ -484,19 +477,19 @@ class BrnCalendarMonthSelect {
484
477
  _selectedMonth = computed(() => {
485
478
  return this._i18n.config().months()[this._dateAdapter.getMonth(this._calendar.focusedDate())];
486
479
  });
480
+ constructor() {
481
+ effect(() => {
482
+ this._select.writeValue(this._selectedMonth());
483
+ });
484
+ }
487
485
  /** Focus selected month */
488
486
  monthSelected(selectedMonth) {
489
487
  const month = this._i18n
490
488
  .config()
491
489
  .months()
492
490
  .findIndex((month) => month === selectedMonth);
493
- const targetDate = this._dateAdapter.set(this._calendar.state().focusedDate(), { month });
494
- this._calendar.state().focusedDate.set(targetDate);
495
- }
496
- constructor() {
497
- effect(() => {
498
- this._select.writeValue(this._selectedMonth());
499
- });
491
+ const targetDate = this._dateAdapter.set(this._calendar.focusedDate(), { month });
492
+ this._calendar.focusedDate.set(targetDate);
500
493
  }
501
494
  /** @nocollapse */ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: BrnCalendarMonthSelect, deps: [], target: i0.ɵɵFactoryTarget.Directive });
502
495
  /** @nocollapse */ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.8", type: BrnCalendarMonthSelect, isStandalone: true, selector: "brn-select[brnCalendarMonthSelect]", host: { listeners: { "valueChange": "monthSelected($event)" } }, ngImport: i0 });
@@ -520,15 +513,15 @@ class BrnCalendarNextButton {
520
513
  _i18n = injectBrnCalendarI18n();
521
514
  /** Focus the previous month */
522
515
  focusPreviousMonth() {
523
- const targetDate = this._dateAdapter.add(this._calendar.state().focusedDate(), { months: 1 });
516
+ const targetDate = this._dateAdapter.add(this._calendar.focusedDate(), { months: 1 });
524
517
  // if the date is disabled, but there are available dates in the month, focus the last day of the month.
525
518
  const possibleDate = this._calendar.constrainDate(targetDate);
526
519
  if (this._dateAdapter.isSameMonth(possibleDate, targetDate)) {
527
520
  // if this date is within the same month, then focus it
528
- this._calendar.state().focusedDate.set(possibleDate);
521
+ this._calendar.focusedDate.set(possibleDate);
529
522
  return;
530
523
  }
531
- this._calendar.state().focusedDate.set(targetDate);
524
+ this._calendar.focusedDate.set(targetDate);
532
525
  }
533
526
  /** @nocollapse */ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: BrnCalendarNextButton, deps: [], target: i0.ɵɵFactoryTarget.Directive });
534
527
  /** @nocollapse */ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.8", type: BrnCalendarNextButton, isStandalone: true, selector: "[brnCalendarNextButton]", host: { attributes: { "type": "button" }, listeners: { "click": "focusPreviousMonth()" }, properties: { "attr.aria-label": "_i18n.config().labelNext()" } }, ngImport: i0 });
@@ -540,12 +533,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImpor
540
533
  host: {
541
534
  type: 'button',
542
535
  '[attr.aria-label]': '_i18n.config().labelNext()',
536
+ '(click)': 'focusPreviousMonth()',
543
537
  },
544
538
  }]
545
- }], propDecorators: { focusPreviousMonth: [{
546
- type: HostListener,
547
- args: ['click']
548
- }] } });
539
+ }] });
549
540
 
550
541
  class BrnCalendarPreviousButton {
551
542
  /** Access the calendar */
@@ -556,15 +547,15 @@ class BrnCalendarPreviousButton {
556
547
  _i18n = injectBrnCalendarI18n();
557
548
  /** Focus the previous month */
558
549
  focusPreviousMonth() {
559
- const targetDate = this._dateAdapter.subtract(this._calendar.state().focusedDate(), { months: 1 });
550
+ const targetDate = this._dateAdapter.subtract(this._calendar.focusedDate(), { months: 1 });
560
551
  // if the date is disabled, but there are available dates in the month, focus the last day of the month.
561
552
  const possibleDate = this._calendar.constrainDate(targetDate);
562
553
  if (this._dateAdapter.isSameMonth(possibleDate, targetDate)) {
563
554
  // if this date is within the same month, then focus it
564
- this._calendar.state().focusedDate.set(possibleDate);
555
+ this._calendar.focusedDate.set(possibleDate);
565
556
  return;
566
557
  }
567
- this._calendar.state().focusedDate.set(targetDate);
558
+ this._calendar.focusedDate.set(targetDate);
568
559
  }
569
560
  /** @nocollapse */ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: BrnCalendarPreviousButton, deps: [], target: i0.ɵɵFactoryTarget.Directive });
570
561
  /** @nocollapse */ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.8", type: BrnCalendarPreviousButton, isStandalone: true, selector: "[brnCalendarPreviousButton]", host: { attributes: { "type": "button" }, listeners: { "click": "focusPreviousMonth()" }, properties: { "attr.aria-label": "_i18n.config().labelPrevious()" } }, ngImport: i0 });
@@ -576,12 +567,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.8", ngImpor
576
567
  host: {
577
568
  type: 'button',
578
569
  '[attr.aria-label]': '_i18n.config().labelPrevious()',
570
+ '(click)': 'focusPreviousMonth()',
579
571
  },
580
572
  }]
581
- }], propDecorators: { focusPreviousMonth: [{
582
- type: HostListener,
583
- args: ['click']
584
- }] } });
573
+ }] });
585
574
 
586
575
  class BrnCalendarWeek {
587
576
  /** Access the calendar */
@@ -715,16 +704,16 @@ class BrnCalendarYearSelect {
715
704
  _dateAdapter = injectDateAdapter();
716
705
  /** Access the calendar i18n */
717
706
  _i18n = injectBrnCalendarI18n();
718
- /** Focus selected year */
719
- yearSelected(year) {
720
- const targetDate = this._dateAdapter.set(this._calendar.state().focusedDate(), { year });
721
- this._calendar.state().focusedDate.set(targetDate);
722
- }
723
707
  constructor() {
724
708
  effect(() => {
725
709
  this._select.writeValue(this._dateAdapter.getYear(this._calendar.focusedDate()));
726
710
  });
727
711
  }
712
+ /** Focus selected year */
713
+ yearSelected(year) {
714
+ const targetDate = this._dateAdapter.set(this._calendar.focusedDate(), { year });
715
+ this._calendar.focusedDate.set(targetDate);
716
+ }
728
717
  /** @nocollapse */ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.8", ngImport: i0, type: BrnCalendarYearSelect, deps: [], target: i0.ɵɵFactoryTarget.Directive });
729
718
  /** @nocollapse */ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.8", type: BrnCalendarYearSelect, isStandalone: true, selector: "brn-select[brnCalendarYearSelect]", host: { listeners: { "valueChange": "yearSelected($event)" } }, ngImport: i0 });
730
719
  }
@@ -806,24 +795,17 @@ class BrnCalendarMulti {
806
795
  _cells = contentChildren(BrnCalendarCellButton, {
807
796
  descendants: true,
808
797
  });
809
- /**
810
- * @internal
811
- * The internal state of the component.
812
- */
813
- state = computed(() => ({
814
- focusedDate: signal(this.constrainDate(this.defaultFocusedDate() ?? this._dateAdapter.now())),
815
- }));
816
798
  /**
817
799
  * The focused date.
818
800
  */
819
- focusedDate = computed(() => this.state().focusedDate());
801
+ focusedDate = linkedSignal(() => this.constrainDate(this.defaultFocusedDate() ?? this._dateAdapter.now()));
820
802
  /**
821
803
  * Get all the days to display, this is the days of the current month
822
804
  * and the days of the previous and next month to fill the grid.
823
805
  */
824
806
  days = computed(() => {
825
807
  const weekStartsOn = this._weekStartsOn();
826
- const month = this.state().focusedDate();
808
+ const month = this.focusedDate();
827
809
  const days = [];
828
810
  // Get the first and last day of the month.
829
811
  let firstDay = this._dateAdapter.startOfMonth(month);
@@ -917,7 +899,7 @@ class BrnCalendarMulti {
917
899
  if (this.isDateDisabled(date)) {
918
900
  return;
919
901
  }
920
- this.state().focusedDate.set(date);
902
+ this.focusedDate.set(date);
921
903
  // wait until the cells have all updated
922
904
  afterNextRender({
923
905
  write: () => {
@@ -975,17 +957,10 @@ class BrnCalendarRange {
975
957
  _cells = contentChildren(BrnCalendarCellButton, {
976
958
  descendants: true,
977
959
  });
978
- /**
979
- * @internal
980
- * The internal state of the component.
981
- */
982
- state = computed(() => ({
983
- focusedDate: signal(this.constrainDate(this.defaultFocusedDate() ?? this.startDate() ?? this._dateAdapter.now())),
984
- }));
985
960
  /**
986
961
  * The focused date.
987
962
  */
988
- focusedDate = computed(() => this.state().focusedDate());
963
+ focusedDate = linkedSignal(() => this.constrainDate(this.defaultFocusedDate() ?? this.startDate() ?? this._dateAdapter.now()));
989
964
  /**
990
965
  * The selected start date
991
966
  */
@@ -1000,7 +975,7 @@ class BrnCalendarRange {
1000
975
  */
1001
976
  days = computed(() => {
1002
977
  const weekStartsOn = this._weekStartsOn();
1003
- const month = this.state().focusedDate();
978
+ const month = this.focusedDate();
1004
979
  const days = [];
1005
980
  // Get the first and last day of the month.
1006
981
  let firstDay = this._dateAdapter.startOfMonth(month);
@@ -1103,7 +1078,7 @@ class BrnCalendarRange {
1103
1078
  if (this.isDateDisabled(date)) {
1104
1079
  return;
1105
1080
  }
1106
- this.state().focusedDate.set(date);
1081
+ this.focusedDate.set(date);
1107
1082
  // wait until the cells have all updated
1108
1083
  afterNextRender({
1109
1084
  write: () => {
@@ -1 +1 @@
1
- {"version":3,"file":"spartan-ng-brain-calendar.mjs","sources":["../../../../libs/brain/calendar/src/lib/brn-calendar.token.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-cell-button.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-header.ts","../../../../libs/brain/calendar/src/lib/i18n/calendar-i18n.ts","../../../../libs/brain/calendar/src/lib/brn-calendar.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-cell.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-grid.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-month-select.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-next-button.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-previous-button.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-week.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-weekday.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-year-select.ts","../../../../libs/brain/calendar/src/lib/mode/brn-calendar-multiple.ts","../../../../libs/brain/calendar/src/lib/mode/brn-calendar-range.ts","../../../../libs/brain/calendar/src/index.ts","../../../../libs/brain/calendar/src/spartan-ng-brain-calendar.ts"],"sourcesContent":["import {\n\ttype ExistingProvider,\n\tInjectionToken,\n\ttype Signal,\n\ttype Type,\n\ttype WritableSignal,\n\tinject,\n} from '@angular/core';\nimport type { BrnCalendarHeader } from './brn-calendar-header';\n\nexport interface BrnCalendarBase<T> {\n\tisSelected: (date: T) => boolean;\n\tselectDate: (date: T) => void;\n\n\tconstrainDate: (date: T) => T;\n\tisDateDisabled: (date: T) => boolean;\n\tsetFocusedDate: (date: T) => void;\n\n\tisStartOfRange: (date: T) => boolean;\n\tisEndOfRange: (date: T) => boolean;\n\tisBetweenRange: (date: T) => boolean;\n\n\tdisabled: Signal<boolean>;\n\tfocusedDate: Signal<T>;\n\theader: Signal<BrnCalendarHeader | undefined>;\n\tstate: Signal<{\n\t\tfocusedDate: WritableSignal<T>;\n\t}>;\n\tdays: Signal<T[]>;\n}\n\nexport const BrnCalendarToken = new InjectionToken<BrnCalendarBase<unknown>>('BrnCalendarToken');\n\nexport function provideBrnCalendar<T>(instance: Type<BrnCalendarBase<T>>): ExistingProvider {\n\treturn { provide: BrnCalendarToken, useExisting: instance };\n}\n\n/**\n * Inject the calendar component.\n */\nexport function injectBrnCalendar<T>(): BrnCalendarBase<T> {\n\treturn inject(BrnCalendarToken) as BrnCalendarBase<T>;\n}\n","import { Directive, ElementRef, computed, inject, input } from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { injectBrnCalendar } from './brn-calendar.token';\n\n@Directive({\n\tselector: 'button[brnCalendarCellButton]',\n\thost: {\n\t\trole: 'gridcell',\n\t\t'[tabindex]': 'focusable() ? 0 : -1',\n\t\ttype: 'button',\n\t\t'[attr.data-outside]': \"outside() && (!end() && !start())? '' : null\",\n\t\t'[attr.data-today]': \"today() && !selected() ? '' : null\",\n\t\t'[attr.data-selected]': \"selected() ? '' : null\",\n\t\t'[attr.data-disabled]': \"disabled() ? '' : null\",\n\t\t'[attr.aria-selected]': \"selected() ? 'true' : null\",\n\t\t'[attr.aria-disabled]': \"disabled() ? 'true' : null\",\n\t\t'[attr.data-range-start]': 'start() ? \"\" : null',\n\t\t'[attr.data-range-end]': 'end() ? \"\" : null',\n\t\t'[attr.data-range-between]': 'betweenRange() ? \"\" : null',\n\t\t'[disabled]': 'disabled()',\n\t\t'(click)': '_calendar.selectDate(date())',\n\t\t'(keydown.arrowLeft)': 'focusPrevious($event)',\n\t\t'(keydown.arrowRight)': 'focusNext($event)',\n\t\t'(keydown.arrowUp)': 'focusAbove($event)',\n\t\t'(keydown.arrowDown)': 'focusBelow($event)',\n\t\t'(keydown.home)': 'focusFirst($event)',\n\t\t'(keydown.end)': 'focusLast($event)',\n\t\t'(keydown.pageUp)': 'focusPreviousMonth($event)',\n\t\t'(keydown.pageDown)': 'focusNextMonth($event)',\n\t},\n})\nexport class BrnCalendarCellButton<T> {\n\t/** Access the date adapter */\n\tprotected readonly _dateAdapter = injectDateAdapter<T>();\n\n\t/** Access the calendar component */\n\tprotected readonly _calendar = injectBrnCalendar<T>();\n\n\t/** Access the element ref */\n\tprivate readonly _elementRef = inject<ElementRef<HTMLButtonElement>>(ElementRef);\n\n\t/** The date this cell represents */\n\tpublic readonly date = input.required<T>();\n\n\t/** Whether this date is currently selected */\n\tpublic readonly selected = computed(() => this._calendar.isSelected(this.date()));\n\tpublic readonly start = computed(() => this._calendar.isStartOfRange(this.date()));\n\tpublic readonly end = computed(() => this._calendar.isEndOfRange(this.date()));\n\tpublic readonly betweenRange = computed(() => this._calendar.isBetweenRange(this.date()));\n\n\t/** Whether this date is focusable */\n\tpublic readonly focusable = computed(() => this._dateAdapter.isSameDay(this._calendar.focusedDate(), this.date()));\n\n\tpublic readonly outside = computed(() => {\n\t\tconst focusedDate = this._calendar.focusedDate();\n\t\treturn !this._dateAdapter.isSameMonth(this.date(), focusedDate);\n\t});\n\n\t/** Whether this date is today */\n\tpublic readonly today = computed(() => this._dateAdapter.isSameDay(this.date(), this._dateAdapter.now()));\n\n\t/** Whether this date is disabled */\n\tpublic readonly disabled = computed(() => this._calendar.isDateDisabled(this.date()) || this._calendar.disabled());\n\n\t/**\n\t * Focus the previous cell.\n\t */\n\tprotected focusPrevious(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\n\t\t// in rtl, the arrow keys are reversed.\n\t\tconst targetDate = this._dateAdapter.add(this._calendar.focusedDate(), {\n\t\t\tdays: this.getDirection() === 'rtl' ? 1 : -1,\n\t\t});\n\n\t\tthis._calendar.setFocusedDate(targetDate);\n\t}\n\n\t/**\n\t * Focus the next cell.\n\t */\n\tprotected focusNext(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\n\t\tconst targetDate = this._dateAdapter.add(this._calendar.focusedDate(), {\n\t\t\tdays: this.getDirection() === 'rtl' ? -1 : 1,\n\t\t});\n\n\t\tthis._calendar.setFocusedDate(targetDate);\n\t}\n\n\t/**\n\t * Focus the above cell.\n\t */\n\tprotected focusAbove(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\t\tthis._calendar.setFocusedDate(this._dateAdapter.subtract(this._calendar.focusedDate(), { days: 7 }));\n\t}\n\n\t/**\n\t * Focus the below cell.\n\t */\n\tprotected focusBelow(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\t\tthis._calendar.setFocusedDate(this._dateAdapter.add(this._calendar.focusedDate(), { days: 7 }));\n\t}\n\n\t/**\n\t * Focus the first date of the month.\n\t */\n\tprotected focusFirst(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\t\tthis._calendar.setFocusedDate(this._dateAdapter.startOfMonth(this._calendar.focusedDate()));\n\t}\n\n\t/**\n\t * Focus the last date of the month.\n\t */\n\tprotected focusLast(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\t\tthis._calendar.setFocusedDate(this._dateAdapter.endOfMonth(this._calendar.focusedDate()));\n\t}\n\n\t/**\n\t * Focus the same date in the previous month.\n\t */\n\tprotected focusPreviousMonth(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\n\t\tconst date = this._dateAdapter.getDate(this._calendar.focusedDate());\n\n\t\tlet previousMonthTarget = this._dateAdapter.startOfMonth(this._calendar.focusedDate());\n\t\tpreviousMonthTarget = this._dateAdapter.subtract(previousMonthTarget, { months: 1 });\n\n\t\tconst lastDay = this._dateAdapter.endOfMonth(previousMonthTarget);\n\n\t\t// if we are on a date that does not exist in the previous month, we should focus the last day of the month.\n\t\tif (date > this._dateAdapter.getDate(lastDay)) {\n\t\t\tthis._calendar.setFocusedDate(lastDay);\n\t\t} else {\n\t\t\tthis._calendar.setFocusedDate(this._dateAdapter.set(previousMonthTarget, { day: date }));\n\t\t}\n\t}\n\n\t/**\n\t * Focus the same date in the next month.\n\t */\n\tprotected focusNextMonth(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\n\t\tconst date = this._dateAdapter.getDate(this._calendar.focusedDate());\n\n\t\tlet nextMonthTarget = this._dateAdapter.startOfMonth(this._calendar.focusedDate());\n\t\tnextMonthTarget = this._dateAdapter.add(nextMonthTarget, { months: 1 });\n\n\t\tconst lastDay = this._dateAdapter.endOfMonth(nextMonthTarget);\n\n\t\t// if we are on a date that does not exist in the next month, we should focus the last day of the month.\n\t\tif (date > this._dateAdapter.getDate(lastDay)) {\n\t\t\tthis._calendar.setFocusedDate(lastDay);\n\t\t} else {\n\t\t\tthis._calendar.setFocusedDate(this._dateAdapter.set(nextMonthTarget, { day: date }));\n\t\t}\n\t}\n\n\t/**\n\t * Get the direction of the element.\n\t */\n\tprivate getDirection(): 'ltr' | 'rtl' {\n\t\treturn getComputedStyle(this._elementRef.nativeElement).direction === 'rtl' ? 'rtl' : 'ltr';\n\t}\n\n\tfocus(): void {\n\t\tthis._elementRef.nativeElement.focus();\n\t}\n}\n","import { Directive, input } from '@angular/core';\n\nlet uniqueId = 0;\n\n@Directive({\n\tselector: '[brnCalendarHeader]',\n\thost: {\n\t\t'[id]': 'id()',\n\t\t'aria-live': 'polite',\n\t\trole: 'presentation',\n\t},\n})\nexport class BrnCalendarHeader {\n\t/** The unique id for the header */\n\tpublic readonly id = input(`brn-calendar-header-${++uniqueId}`);\n}\n","import { inject, Injectable, InjectionToken, type Provider, signal } from '@angular/core';\n\nexport type Weekday = 0 | 1 | 2 | 3 | 4 | 5 | 6;\n\ninterface BrnCalendarI18n {\n\tformatWeekdayName: (index: number) => string;\n\tformatHeader: (month: number, year: number) => string;\n\tformatYear: (year: number) => string;\n\tformatMonth: (month: number) => string;\n\tlabelPrevious: () => string;\n\tlabelNext: () => string;\n\tlabelWeekday: (index: number) => string;\n\tmonths: () => [string, string, string, string, string, string, string, string, string, string, string, string];\n\tyears: (startYear?: number, endYear?: number) => number[];\n\tfirstDayOfWeek: () => Weekday;\n}\n\nexport const BrnCalendarI18nToken = new InjectionToken<BrnCalendarI18nService>('BrnCalendarI18nToken');\n\n/**\n * Provide the calendar i18n configuration.\n */\nexport function provideBrnCalendarI18n(configuration?: BrnCalendarI18n): Provider {\n\treturn {\n\t\tprovide: BrnCalendarI18nToken,\n\t\tuseFactory: () => {\n\t\t\tconst service = new BrnCalendarI18nService();\n\t\t\tservice.use(configuration ?? defaultCalendarI18n);\n\t\t\treturn service;\n\t\t},\n\t};\n}\n\nconst defaultCalendarI18n: BrnCalendarI18n = {\n\tformatWeekdayName: (index: number) => {\n\t\tconst weekdays = ['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa'];\n\t\treturn weekdays[index];\n\t},\n\tmonths: () => ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],\n\tyears: (startYear = 1925, endYear = new Date().getFullYear()) =>\n\t\tArray.from({ length: endYear - startYear + 1 }, (_, i) => startYear + i),\n\tformatHeader: (month: number, year: number) => {\n\t\treturn new Date(year, month).toLocaleDateString(undefined, {\n\t\t\tmonth: 'long',\n\t\t\tyear: 'numeric',\n\t\t});\n\t},\n\tformatMonth: (month: number) => {\n\t\treturn new Date(2000, month).toLocaleDateString(undefined, {\n\t\t\tmonth: 'short',\n\t\t});\n\t},\n\tformatYear: (year: number): string => {\n\t\treturn new Date(year, 0).toLocaleDateString(undefined, {\n\t\t\tyear: 'numeric',\n\t\t});\n\t},\n\tlabelPrevious: () => 'Go to the previous month',\n\tlabelNext: () => 'Go to the next month',\n\tlabelWeekday: (index: number) => {\n\t\tconst weekdays = ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'];\n\t\treturn weekdays[index];\n\t},\n\tfirstDayOfWeek: () => 0,\n};\n\n/**\n * Inject the calendar i18n configuration.\n */\nexport function injectBrnCalendarI18n(): BrnCalendarI18nService {\n\treturn inject(BrnCalendarI18nToken, { optional: true }) ?? inject(BrnCalendarI18nService); // fallback\n}\n\n@Injectable({ providedIn: 'root' })\nexport class BrnCalendarI18nService {\n\tprivate readonly _config = signal<BrnCalendarI18n>(defaultCalendarI18n);\n\n\tpublic readonly config = this._config.asReadonly();\n\n\tpublic use(config: Partial<BrnCalendarI18n>) {\n\t\tthis._config.set({ ...this.config(), ...config });\n\t}\n}\n","import type { BooleanInput, NumberInput } from '@angular/cdk/coercion';\nimport {\n\tafterNextRender,\n\tbooleanAttribute,\n\tChangeDetectorRef,\n\tcomputed,\n\tcontentChild,\n\tcontentChildren,\n\tDirective,\n\tinject,\n\tInjector,\n\tinput,\n\tmodel,\n\tnumberAttribute,\n\tsignal,\n} from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { BrnCalendarCellButton } from './brn-calendar-cell-button';\nimport { BrnCalendarHeader } from './brn-calendar-header';\nimport { type BrnCalendarBase, provideBrnCalendar } from './brn-calendar.token';\nimport { injectBrnCalendarI18n, type Weekday } from './i18n/calendar-i18n';\n\n@Directive({\n\tselector: '[brnCalendar]',\n\tproviders: [provideBrnCalendar(BrnCalendar)],\n})\nexport class BrnCalendar<T> implements BrnCalendarBase<T> {\n\tprivate readonly _i18n = injectBrnCalendarI18n();\n\n\t/** Access the date adapter */\n\tprotected readonly _dateAdapter = injectDateAdapter<T>();\n\n\t/** Access the change detector */\n\tprivate readonly _changeDetector = inject(ChangeDetectorRef);\n\n\t/** Access the injector */\n\tprivate readonly _injector = inject(Injector);\n\n\t/** The minimum date that can be selected.*/\n\tpublic readonly min = input<T>();\n\n\t/** The maximum date that can be selected. */\n\tpublic readonly max = input<T>();\n\n\t/** Determine if the date picker is disabled. */\n\tpublic readonly disabled = input<boolean, BooleanInput>(false, {\n\t\ttransform: booleanAttribute,\n\t});\n\n\t/** The selected value. */\n\tpublic readonly date = model<T>();\n\n\t/** Whether a specific date is disabled. */\n\tpublic readonly dateDisabled = input<(date: T) => boolean>(() => false);\n\n\t/** The day the week starts on */\n\tpublic readonly weekStartsOn = input<Weekday, NumberInput | undefined>(undefined, {\n\t\ttransform: (v: unknown) => (v === undefined || v === null ? undefined : (numberAttribute(v) as Weekday)),\n\t});\n\n\tprotected readonly _weekStartsOn = computed(() => this.weekStartsOn() ?? this._i18n.config().firstDayOfWeek());\n\n\t/** The default focused date. */\n\tpublic readonly defaultFocusedDate = input<T>();\n\n\t/** @internal Access the header */\n\tpublic readonly header = contentChild(BrnCalendarHeader);\n\n\t/** Store the cells */\n\tprotected readonly _cells = contentChildren<BrnCalendarCellButton<T>>(BrnCalendarCellButton, {\n\t\tdescendants: true,\n\t});\n\n\t/**\n\t * @internal\n\t * The internal state of the component.\n\t */\n\tpublic readonly state = computed(() => ({\n\t\tfocusedDate: signal(this.constrainDate(this.defaultFocusedDate() ?? this.date() ?? this._dateAdapter.now())),\n\t}));\n\n\t/**\n\t * The focused date.\n\t */\n\tpublic readonly focusedDate = computed(() => this.state().focusedDate());\n\n\t/**\n\t * Get all the days to display, this is the days of the current month\n\t * and the days of the previous and next month to fill the grid.\n\t */\n\tpublic readonly days = computed(() => {\n\t\tconst weekStartsOn = this._weekStartsOn();\n\t\tconst month = this.state().focusedDate();\n\t\tconst days: T[] = [];\n\n\t\t// Get the first and last day of the month.\n\t\tlet firstDay = this._dateAdapter.startOfMonth(month);\n\t\tlet lastDay = this._dateAdapter.endOfMonth(month);\n\n\t\t// we need to subtract until we get the to starting day before or on the start of the month.\n\t\twhile (this._dateAdapter.getDay(firstDay) !== weekStartsOn) {\n\t\t\tfirstDay = this._dateAdapter.subtract(firstDay, { days: 1 });\n\t\t}\n\n\t\tconst weekEndsOn = (weekStartsOn + 6) % 7;\n\n\t\t// we need to add until we get to the ending day after or on the end of the month.\n\t\twhile (this._dateAdapter.getDay(lastDay) !== weekEndsOn) {\n\t\t\tlastDay = this._dateAdapter.add(lastDay, { days: 1 });\n\t\t}\n\n\t\t// collect all the days to display.\n\t\twhile (firstDay <= lastDay) {\n\t\t\tdays.push(firstDay);\n\t\t\tfirstDay = this._dateAdapter.add(firstDay, { days: 1 });\n\t\t}\n\n\t\treturn days;\n\t});\n\n\t/** @internal Constrain a date to the min and max boundaries */\n\tconstrainDate(date: T): T {\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\t// If there is no min or max, return the date.\n\t\tif (!min && !max) {\n\t\t\treturn date;\n\t\t}\n\n\t\t// If there is a min and the date is before the min, return the min.\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn min;\n\t\t}\n\n\t\t// If there is a max and the date is after the max, return the max.\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn max;\n\t\t}\n\n\t\t// Return the date.\n\t\treturn date;\n\t}\n\n\t/** @internal Determine if a date is disabled */\n\tisDateDisabled(date: T): boolean {\n\t\t// if the calendar is disabled we can't select this date\n\t\tif (this.disabled()) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if the date is outside the min and max range\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn true;\n\t\t}\n\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if this specific date is disabled\n\t\tconst disabledFn = this.dateDisabled();\n\n\t\tif (disabledFn(date)) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}\n\n\tisSelected(date: T): boolean {\n\t\tconst selected = this.date() as T | undefined;\n\t\treturn selected !== undefined && this._dateAdapter.isSameDay(date, selected);\n\t}\n\n\tselectDate(date: T): void {\n\t\tif (this.isSelected(date)) {\n\t\t\tthis.date.set(undefined);\n\t\t} else {\n\t\t\tthis.date.set(date);\n\t\t}\n\t\tthis.state().focusedDate.set(date);\n\t}\n\n\t/** @internal Set the focused date */\n\tsetFocusedDate(date: T): void {\n\t\t// check if the date is disabled.\n\t\tif (this.isDateDisabled(date)) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.state().focusedDate.set(date);\n\n\t\t// wait until the cells have all updated\n\t\tafterNextRender(\n\t\t\t{\n\t\t\t\twrite: () => {\n\t\t\t\t\t// focus the cell with the target date.\n\t\t\t\t\tconst cell = this._cells().find((c) => this._dateAdapter.isSameDay(c.date(), date));\n\n\t\t\t\t\tif (cell) {\n\t\t\t\t\t\tcell.focus();\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tinjector: this._injector,\n\t\t\t},\n\t\t);\n\n\t\t// we must update the view to ensure the focused cell is visible.\n\t\tthis._changeDetector.detectChanges();\n\t}\n\n\t/**\n\t * Determine if a date is the start of a range. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisStartOfRange(_: T): boolean {\n\t\treturn false;\n\t}\n\n\t/**\n\t * Determine if a date is the end of a range. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisEndOfRange(_: T): boolean {\n\t\treturn false;\n\t}\n\n\t/**\n\t * Determine if a date is between the start and end dates. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns True if the date is between the start and end dates, false otherwise.\n\t * @internal\n\t */\n\tisBetweenRange(_: T): boolean {\n\t\treturn false;\n\t}\n}\n","import { Directive } from '@angular/core';\n\n@Directive({\n\tselector: '[brnCalendarCell]',\n\thost: {\n\t\trole: 'presentation',\n\t},\n})\nexport class BrnCalendarCell {}\n","import { Directive } from '@angular/core';\nimport { injectBrnCalendar } from './brn-calendar.token';\n\n@Directive({\n\tselector: '[brnCalendarGrid]',\n\thost: {\n\t\trole: 'grid',\n\t\t'[attr.aria-labelledby]': '_calendar.header()?.id()',\n\t},\n})\nexport class BrnCalendarGrid<T> {\n\t/** Access the calendar component */\n\tprotected readonly _calendar = injectBrnCalendar<T>();\n}\n","import { computed, Directive, effect, inject } from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { BrnSelect } from '@spartan-ng/brain/select';\nimport { injectBrnCalendar } from './brn-calendar.token';\nimport { injectBrnCalendarI18n } from './i18n/calendar-i18n';\n\n@Directive({\n\tselector: 'brn-select[brnCalendarMonthSelect]',\n\thost: {\n\t\t'(valueChange)': 'monthSelected($event)',\n\t},\n})\nexport class BrnCalendarMonthSelect {\n\t/** Access the select */\n\tprivate readonly _select = inject(BrnSelect);\n\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar();\n\n\t/** Access the date adapter */\n\tprivate readonly _dateAdapter = injectDateAdapter();\n\n\t/** Access the calendar i18n */\n\tprotected readonly _i18n = injectBrnCalendarI18n();\n\n\tprotected readonly _selectedMonth = computed(() => {\n\t\treturn this._i18n.config().months()[this._dateAdapter.getMonth(this._calendar.focusedDate())];\n\t});\n\n\t/** Focus selected month */\n\tprotected monthSelected(selectedMonth: string): void {\n\t\tconst month = this._i18n\n\t\t\t.config()\n\t\t\t.months()\n\t\t\t.findIndex((month) => month === selectedMonth);\n\t\tconst targetDate = this._dateAdapter.set(this._calendar.state().focusedDate(), { month });\n\t\tthis._calendar.state().focusedDate.set(targetDate);\n\t}\n\n\tconstructor() {\n\t\teffect(() => {\n\t\t\tthis._select.writeValue(this._selectedMonth());\n\t\t});\n\t}\n}\n","import { Directive, HostListener } from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { injectBrnCalendar } from './brn-calendar.token';\nimport { injectBrnCalendarI18n } from './i18n/calendar-i18n';\n\n@Directive({\n\tselector: '[brnCalendarNextButton]',\n\thost: {\n\t\ttype: 'button',\n\t\t'[attr.aria-label]': '_i18n.config().labelNext()',\n\t},\n})\nexport class BrnCalendarNextButton {\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar();\n\n\t/** Access the date adapter */\n\tprivate readonly _dateAdapter = injectDateAdapter();\n\n\t/** Access the calendar i18n */\n\tprotected readonly _i18n = injectBrnCalendarI18n();\n\n\t/** Focus the previous month */\n\t@HostListener('click')\n\tprotected focusPreviousMonth(): void {\n\t\tconst targetDate = this._dateAdapter.add(this._calendar.state().focusedDate(), { months: 1 });\n\n\t\t// if the date is disabled, but there are available dates in the month, focus the last day of the month.\n\t\tconst possibleDate = this._calendar.constrainDate(targetDate);\n\n\t\tif (this._dateAdapter.isSameMonth(possibleDate, targetDate)) {\n\t\t\t// if this date is within the same month, then focus it\n\t\t\tthis._calendar.state().focusedDate.set(possibleDate);\n\t\t\treturn;\n\t\t}\n\n\t\tthis._calendar.state().focusedDate.set(targetDate);\n\t}\n}\n","import { Directive, HostListener } from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { injectBrnCalendar } from './brn-calendar.token';\nimport { injectBrnCalendarI18n } from './i18n/calendar-i18n';\n\n@Directive({\n\tselector: '[brnCalendarPreviousButton]',\n\thost: {\n\t\ttype: 'button',\n\t\t'[attr.aria-label]': '_i18n.config().labelPrevious()',\n\t},\n})\nexport class BrnCalendarPreviousButton {\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar();\n\n\t/** Access the date adapter */\n\tprivate readonly _dateAdapter = injectDateAdapter();\n\n\t/** Access the calendar i18n */\n\tprotected readonly _i18n = injectBrnCalendarI18n();\n\n\t/** Focus the previous month */\n\t@HostListener('click')\n\tprotected focusPreviousMonth(): void {\n\t\tconst targetDate = this._dateAdapter.subtract(this._calendar.state().focusedDate(), { months: 1 });\n\n\t\t// if the date is disabled, but there are available dates in the month, focus the last day of the month.\n\t\tconst possibleDate = this._calendar.constrainDate(targetDate);\n\n\t\tif (this._dateAdapter.isSameMonth(possibleDate, targetDate)) {\n\t\t\t// if this date is within the same month, then focus it\n\t\t\tthis._calendar.state().focusedDate.set(possibleDate);\n\t\t\treturn;\n\t\t}\n\n\t\tthis._calendar.state().focusedDate.set(targetDate);\n\t}\n}\n","import {\n\tChangeDetectorRef,\n\tDirective,\n\ttype EmbeddedViewRef,\n\ttype OnDestroy,\n\tTemplateRef,\n\tViewContainerRef,\n\tcomputed,\n\teffect,\n\tinject,\n\tuntracked,\n} from '@angular/core';\nimport { injectBrnCalendar } from './brn-calendar.token';\n\n@Directive({\n\tselector: '[brnCalendarWeek]',\n})\nexport class BrnCalendarWeek<T> implements OnDestroy {\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar<T>();\n\n\t/** Access the view container ref */\n\tprivate readonly _viewContainerRef = inject(ViewContainerRef);\n\n\t/** Access the change detector */\n\tprivate readonly _changeDetector = inject(ChangeDetectorRef);\n\n\t/** Access the template ref */\n\tprivate readonly _templateRef = inject<TemplateRef<BrnWeekContext<T>>>(TemplateRef);\n\n\t// get the weeks to display.\n\tprotected readonly _weeks = computed(() => {\n\t\tconst days = this._calendar.days();\n\t\tconst weeks = [];\n\n\t\tfor (let i = 0; i < days.length; i += 7) {\n\t\t\tweeks.push(days.slice(i, i + 7));\n\t\t}\n\n\t\treturn weeks;\n\t});\n\n\t/** Store the view refs */\n\tprivate _viewRefs: EmbeddedViewRef<BrnWeekContext<T>>[] = [];\n\n\t// Make sure the template checker knows the type of the context with which the\n\t// template of this directive will be rendered\n\tstatic ngTemplateContextGuard<T>(_: BrnCalendarWeek<T>, ctx: unknown): ctx is BrnWeekContext<T> {\n\t\treturn true;\n\t}\n\n\tconstructor() {\n\t\t// this should use `afterRenderEffect` but it's not available in the current version\n\t\teffect(() => {\n\t\t\tconst weeks = this._weeks();\n\t\t\tuntracked(() => this._renderWeeks(weeks));\n\t\t});\n\t}\n\n\tprivate _renderWeeks(weeks: T[][]): void {\n\t\t// Destroy all the views when the directive is destroyed\n\t\tfor (const viewRef of this._viewRefs) {\n\t\t\tviewRef.destroy();\n\t\t}\n\n\t\tthis._viewRefs = [];\n\n\t\t// Create a new view for each week\n\t\tfor (const week of weeks) {\n\t\t\tconst viewRef = this._viewContainerRef.createEmbeddedView(this._templateRef, {\n\t\t\t\t$implicit: week,\n\t\t\t});\n\t\t\tthis._viewRefs.push(viewRef);\n\t\t}\n\n\t\tthis._changeDetector.detectChanges();\n\t}\n\n\tngOnDestroy(): void {\n\t\t// Destroy all the views when the directive is destroyed\n\t\tfor (const viewRef of this._viewRefs) {\n\t\t\tviewRef.destroy();\n\t\t}\n\t}\n}\n\ninterface BrnWeekContext<T> {\n\t$implicit: T[];\n}\n","import {\n\tChangeDetectorRef,\n\tcomputed,\n\tDirective,\n\teffect,\n\ttype EmbeddedViewRef,\n\tinject,\n\ttype OnDestroy,\n\tTemplateRef,\n\tuntracked,\n\tViewContainerRef,\n} from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { injectBrnCalendar } from './brn-calendar.token';\n\n@Directive({\n\tselector: '[brnCalendarWeekday]',\n})\nexport class BrnCalendarWeekday<T> implements OnDestroy {\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar<T>();\n\n\t/** Access the date time adapter */\n\tprivate readonly _dateAdapter = injectDateAdapter<T>();\n\n\t/** Access the view container ref */\n\tprivate readonly _viewContainerRef = inject(ViewContainerRef);\n\n\t/** Access the change detector */\n\tprivate readonly _changeDetector = inject(ChangeDetectorRef);\n\n\t/** Access the template ref */\n\tprivate readonly _templateRef = inject<TemplateRef<BrnWeekdayContext>>(TemplateRef);\n\n\t/** Get the days of the week to display in the header. */\n\tprotected readonly _weekdays = computed(() => this._calendar.days().slice(0, 7));\n\n\t/** Store the view refs */\n\tprivate _viewRefs: EmbeddedViewRef<BrnWeekdayContext>[] = [];\n\n\t// Make sure the template checker knows the type of the context with which the\n\t// template of this directive will be rendered\n\tstatic ngTemplateContextGuard<T>(_: BrnCalendarWeekday<T>, ctx: unknown): ctx is BrnWeekdayContext {\n\t\treturn true;\n\t}\n\n\tconstructor() {\n\t\t// Create a new view for each day\n\t\teffect(() => {\n\t\t\t// Get the weekdays to display\n\t\t\tconst weekdays = this._weekdays();\n\t\t\t// Render the weekdays\n\t\t\tuntracked(() => this._renderWeekdays(weekdays));\n\t\t});\n\t}\n\n\tprivate _renderWeekdays(weekdays: T[]): void {\n\t\t// Destroy all the views when the directive is destroyed\n\t\tfor (const viewRef of this._viewRefs) {\n\t\t\tviewRef.destroy();\n\t\t}\n\n\t\tthis._viewRefs = [];\n\n\t\t// Create a new view for each day\n\t\tfor (const day of weekdays) {\n\t\t\tconst viewRef = this._viewContainerRef.createEmbeddedView(this._templateRef, {\n\t\t\t\t$implicit: this._dateAdapter.getDay(day),\n\t\t\t});\n\t\t\tthis._viewRefs.push(viewRef);\n\t\t}\n\n\t\tthis._changeDetector.detectChanges();\n\t}\n\n\tngOnDestroy(): void {\n\t\t// Destroy all the views when the directive is destroyed\n\t\tfor (const viewRef of this._viewRefs) {\n\t\t\tviewRef.destroy();\n\t\t}\n\t}\n}\n\ninterface BrnWeekdayContext {\n\t$implicit: number;\n}\n","import { Directive, effect, inject } from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { BrnSelect } from '@spartan-ng/brain/select';\nimport { injectBrnCalendar } from './brn-calendar.token';\nimport { injectBrnCalendarI18n } from './i18n/calendar-i18n';\n\n@Directive({\n\tselector: 'brn-select[brnCalendarYearSelect]',\n\thost: {\n\t\t'(valueChange)': 'yearSelected($event)',\n\t},\n})\nexport class BrnCalendarYearSelect {\n\t/** Access the select */\n\tprivate readonly _select = inject(BrnSelect);\n\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar();\n\n\t/** Access the date adapter */\n\tprivate readonly _dateAdapter = injectDateAdapter();\n\n\t/** Access the calendar i18n */\n\tprotected readonly _i18n = injectBrnCalendarI18n();\n\n\t/** Focus selected year */\n\tprotected yearSelected(year: number): void {\n\t\tconst targetDate = this._dateAdapter.set(this._calendar.state().focusedDate(), { year });\n\t\tthis._calendar.state().focusedDate.set(targetDate);\n\t}\n\n\tconstructor() {\n\t\teffect(() => {\n\t\t\tthis._select.writeValue(this._dateAdapter.getYear(this._calendar.focusedDate()));\n\t\t});\n\t}\n}\n","import type { BooleanInput, NumberInput } from '@angular/cdk/coercion';\nimport {\n\tafterNextRender,\n\tbooleanAttribute,\n\tChangeDetectorRef,\n\tcomputed,\n\tcontentChild,\n\tcontentChildren,\n\tDirective,\n\tinject,\n\tInjector,\n\tinput,\n\tmodel,\n\tnumberAttribute,\n\tsignal,\n} from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { BrnCalendarCellButton } from '../brn-calendar-cell-button';\nimport { BrnCalendarHeader } from '../brn-calendar-header';\nimport { type BrnCalendarBase, provideBrnCalendar } from '../brn-calendar.token';\nimport { injectBrnCalendarI18n, type Weekday } from '../i18n/calendar-i18n';\n\n@Directive({\n\tselector: '[brnCalendarMulti]',\n\tproviders: [provideBrnCalendar(BrnCalendarMulti)],\n})\nexport class BrnCalendarMulti<T> implements BrnCalendarBase<T> {\n\tprivate readonly _i18n = injectBrnCalendarI18n();\n\n\t/**\n\t * Determine if a date is the start of a range. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisStartOfRange(_: T): boolean {\n\t\treturn false;\n\t}\n\n\t/**\n\t * Determine if a date is the end of a range. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisEndOfRange(_: T): boolean {\n\t\treturn false;\n\t}\n\n\t/**\n\t * Determine if a date is between the start and end dates. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns True if the date is between the start and end dates, false otherwise.\n\t * @internal\n\t */\n\tisBetweenRange(_: T): boolean {\n\t\treturn false;\n\t}\n\n\t// /** Access the date adapter */\n\tprotected readonly _dateAdapter = injectDateAdapter<T>();\n\n\t/** Access the change detector */\n\tprivate readonly _changeDetector = inject(ChangeDetectorRef);\n\n\t/** Access the injector */\n\tprivate readonly _injector = inject(Injector);\n\n\t/** The minimum date that can be selected.*/\n\tpublic readonly min = input<T>();\n\n\t/** The maximum date that can be selected. */\n\tpublic readonly max = input<T>();\n\n\t/** The minimum selectable dates. */\n\tpublic readonly minSelection = input<number, NumberInput>(undefined, {\n\t\ttransform: numberAttribute,\n\t});\n\n\t/** The maximum selectable dates. */\n\tpublic readonly maxSelection = input<number, NumberInput>(undefined, {\n\t\ttransform: numberAttribute,\n\t});\n\n\t/** Determine if the date picker is disabled. */\n\tpublic readonly disabled = input<boolean, BooleanInput>(false, {\n\t\ttransform: booleanAttribute,\n\t});\n\n\t/** The selected value. */\n\tpublic readonly date = model<T[]>();\n\n\t/** Whether a specific date is disabled. */\n\tpublic readonly dateDisabled = input<(date: T) => boolean>(() => false);\n\n\t/** The day the week starts on */\n\tpublic readonly weekStartsOn = input<Weekday, NumberInput | undefined>(undefined, {\n\t\ttransform: (v: unknown) => (v === undefined || v === null ? undefined : (numberAttribute(v) as Weekday)),\n\t});\n\n\tprotected readonly _weekStartsOn = computed(() => this.weekStartsOn() ?? this._i18n.config().firstDayOfWeek());\n\n\t/** The default focused date. */\n\tpublic readonly defaultFocusedDate = input<T>();\n\n\t/** @internal Access the header */\n\tpublic readonly header = contentChild(BrnCalendarHeader);\n\n\t/** Store the cells */\n\tprotected readonly _cells = contentChildren<BrnCalendarCellButton<T>>(BrnCalendarCellButton, {\n\t\tdescendants: true,\n\t});\n\n\t/**\n\t * @internal\n\t * The internal state of the component.\n\t */\n\tpublic readonly state = computed(() => ({\n\t\tfocusedDate: signal(this.constrainDate(this.defaultFocusedDate() ?? this._dateAdapter.now())),\n\t}));\n\n\t/**\n\t * The focused date.\n\t */\n\tpublic readonly focusedDate = computed(() => this.state().focusedDate());\n\n\t/**\n\t * Get all the days to display, this is the days of the current month\n\t * and the days of the previous and next month to fill the grid.\n\t */\n\tpublic readonly days = computed(() => {\n\t\tconst weekStartsOn = this._weekStartsOn();\n\t\tconst month = this.state().focusedDate();\n\t\tconst days: T[] = [];\n\n\t\t// Get the first and last day of the month.\n\t\tlet firstDay = this._dateAdapter.startOfMonth(month);\n\t\tlet lastDay = this._dateAdapter.endOfMonth(month);\n\n\t\t// we need to subtract until we get the to starting day before or on the start of the month.\n\t\twhile (this._dateAdapter.getDay(firstDay) !== weekStartsOn) {\n\t\t\tfirstDay = this._dateAdapter.subtract(firstDay, { days: 1 });\n\t\t}\n\n\t\tconst weekEndsOn = (weekStartsOn + 6) % 7;\n\n\t\t// we need to add until we get to the ending day after or on the end of the month.\n\t\twhile (this._dateAdapter.getDay(lastDay) !== weekEndsOn) {\n\t\t\tlastDay = this._dateAdapter.add(lastDay, { days: 1 });\n\t\t}\n\n\t\t// collect all the days to display.\n\t\twhile (firstDay <= lastDay) {\n\t\t\tdays.push(firstDay);\n\t\t\tfirstDay = this._dateAdapter.add(firstDay, { days: 1 });\n\t\t}\n\n\t\treturn days;\n\t});\n\n\tisSelected(date: T): boolean {\n\t\treturn this.date()?.some((d) => this._dateAdapter.isSameDay(d, date)) ?? false;\n\t}\n\n\tselectDate(date: T): void {\n\t\tconst selected = this.date() as T[] | undefined;\n\t\tif (this.isSelected(date)) {\n\t\t\tconst minSelection = this.minSelection();\n\t\t\tif (selected?.length === minSelection) {\n\t\t\t\t// min selection reached, do not allow to deselect\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tthis.date.set(selected?.filter((d) => !this._dateAdapter.isSameDay(d, date)));\n\t\t} else {\n\t\t\tconst maxSelection = this.maxSelection();\n\t\t\tif (selected?.length === maxSelection) {\n\t\t\t\t// max selection reached, reset the selection to date\n\t\t\t\tthis.date.set([date]);\n\t\t\t} else {\n\t\t\t\t// add the date to the selection\n\t\t\t\tthis.date.set([...(selected ?? []), date]);\n\t\t\t}\n\t\t}\n\t}\n\n\t// same as in brn-calendar.directive.ts\n\t/** @internal Constrain a date to the min and max boundaries */\n\tconstrainDate(date: T): T {\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\t// If there is no min or max, return the date.\n\t\tif (!min && !max) {\n\t\t\treturn date;\n\t\t}\n\n\t\t// If there is a min and the date is before the min, return the min.\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn min;\n\t\t}\n\n\t\t// If there is a max and the date is after the max, return the max.\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn max;\n\t\t}\n\n\t\t// Return the date.\n\t\treturn date;\n\t}\n\n\t/** @internal Determine if a date is disabled */\n\tisDateDisabled(date: T): boolean {\n\t\t// if the calendar is disabled we can't select this date\n\t\tif (this.disabled()) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if the date is outside the min and max range\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn true;\n\t\t}\n\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if this specific date is disabled\n\t\tconst disabledFn = this.dateDisabled();\n\n\t\tif (disabledFn(date)) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}\n\n\t/** @internal Set the focused date */\n\tsetFocusedDate(date: T): void {\n\t\t// check if the date is disabled.\n\t\tif (this.isDateDisabled(date)) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.state().focusedDate.set(date);\n\n\t\t// wait until the cells have all updated\n\t\tafterNextRender(\n\t\t\t{\n\t\t\t\twrite: () => {\n\t\t\t\t\t// focus the cell with the target date.\n\t\t\t\t\tconst cell = this._cells().find((c) => this._dateAdapter.isSameDay(c.date(), date));\n\n\t\t\t\t\tif (cell) {\n\t\t\t\t\t\tcell.focus();\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tinjector: this._injector,\n\t\t\t},\n\t\t);\n\n\t\t// we must update the view to ensure the focused cell is visible.\n\t\tthis._changeDetector.detectChanges();\n\t}\n}\n","import type { BooleanInput, NumberInput } from '@angular/cdk/coercion';\nimport {\n\tafterNextRender,\n\tbooleanAttribute,\n\tChangeDetectorRef,\n\tcomputed,\n\tcontentChild,\n\tcontentChildren,\n\tDirective,\n\tinject,\n\tInjector,\n\tinput,\n\tmodel,\n\tnumberAttribute,\n\tsignal,\n} from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { BrnCalendarCellButton } from '../brn-calendar-cell-button';\nimport { BrnCalendarHeader } from '../brn-calendar-header';\nimport { type BrnCalendarBase, provideBrnCalendar } from '../brn-calendar.token';\nimport { injectBrnCalendarI18n, type Weekday } from '../i18n/calendar-i18n';\n\n@Directive({\n\tselector: '[brnCalendarRange]',\n\tproviders: [provideBrnCalendar(BrnCalendarRange)],\n})\nexport class BrnCalendarRange<T> implements BrnCalendarBase<T> {\n\tprivate readonly _i18n = injectBrnCalendarI18n();\n\t// /** Access the date adapter */\n\tprotected readonly _dateAdapter = injectDateAdapter<T>();\n\n\t/** Access the change detector */\n\tprivate readonly _changeDetector = inject(ChangeDetectorRef);\n\n\t/** Access the injector */\n\tprivate readonly _injector = inject(Injector);\n\n\t/** The minimum date that can be selected.*/\n\tpublic readonly min = input<T>();\n\n\t/** The maximum date that can be selected. */\n\tpublic readonly max = input<T>();\n\n\t/** Determine if the date picker is disabled. */\n\tpublic readonly disabled = input<boolean, BooleanInput>(false, {\n\t\ttransform: booleanAttribute,\n\t});\n\n\t/** Whether a specific date is disabled. */\n\tpublic readonly dateDisabled = input<(date: T) => boolean>(() => false);\n\n\t/** The day the week starts on */\n\tpublic readonly weekStartsOn = input<Weekday, NumberInput | undefined>(undefined, {\n\t\ttransform: (v: unknown) => (v === undefined || v === null ? undefined : (numberAttribute(v) as Weekday)),\n\t});\n\n\tprotected readonly _weekStartsOn = computed(() => this.weekStartsOn() ?? this._i18n.config().firstDayOfWeek());\n\n\t/** The default focused date. */\n\tpublic readonly defaultFocusedDate = input<T>();\n\n\t/** @internal Access the header */\n\tpublic readonly header = contentChild(BrnCalendarHeader);\n\n\t/** Store the cells */\n\tprotected readonly _cells = contentChildren<BrnCalendarCellButton<T>>(BrnCalendarCellButton, {\n\t\tdescendants: true,\n\t});\n\n\t/**\n\t * @internal\n\t * The internal state of the component.\n\t */\n\tpublic readonly state = computed(() => ({\n\t\tfocusedDate: signal(this.constrainDate(this.defaultFocusedDate() ?? this.startDate() ?? this._dateAdapter.now())),\n\t}));\n\n\t/**\n\t * The focused date.\n\t */\n\tpublic readonly focusedDate = computed(() => this.state().focusedDate());\n\n\t/**\n\t * The selected start date\n\t */\n\tpublic readonly startDate = model<T>();\n\n\t/**\n\t * The selected end date\n\t */\n\tpublic readonly endDate = model<T>();\n\n\t/**\n\t * Get all the days to display, this is the days of the current month\n\t * and the days of the previous and next month to fill the grid.\n\t */\n\tpublic readonly days = computed(() => {\n\t\tconst weekStartsOn = this._weekStartsOn();\n\t\tconst month = this.state().focusedDate();\n\t\tconst days: T[] = [];\n\n\t\t// Get the first and last day of the month.\n\t\tlet firstDay = this._dateAdapter.startOfMonth(month);\n\t\tlet lastDay = this._dateAdapter.endOfMonth(month);\n\n\t\t// we need to subtract until we get the to starting day before or on the start of the month.\n\t\twhile (this._dateAdapter.getDay(firstDay) !== weekStartsOn) {\n\t\t\tfirstDay = this._dateAdapter.subtract(firstDay, { days: 1 });\n\t\t}\n\n\t\tconst weekEndsOn = (weekStartsOn + 6) % 7;\n\n\t\t// we need to add until we get to the ending day after or on the end of the month.\n\t\twhile (this._dateAdapter.getDay(lastDay) !== weekEndsOn) {\n\t\t\tlastDay = this._dateAdapter.add(lastDay, { days: 1 });\n\t\t}\n\n\t\t// collect all the days to display.\n\t\twhile (firstDay <= lastDay) {\n\t\t\tdays.push(firstDay);\n\t\t\tfirstDay = this._dateAdapter.add(firstDay, { days: 1 });\n\t\t}\n\n\t\treturn days;\n\t});\n\n\tisSelected(date: T): boolean {\n\t\tconst start = this.startDate();\n\t\tconst end = this.endDate();\n\n\t\tif (!start && !end) {\n\t\t\treturn false;\n\t\t}\n\t\tconst isStartSelected = start ? this._dateAdapter.isSameDay(date, start) : false;\n\t\tconst isEndSelected = end ? this._dateAdapter.isSameDay(date, end) : false;\n\n\t\treturn isStartSelected || isEndSelected;\n\t}\n\n\tselectDate(date: T): void {\n\t\tconst start = this.startDate();\n\t\tconst end = this.endDate();\n\n\t\tif (!start && !end) {\n\t\t\tthis.startDate.set(date);\n\n\t\t\treturn;\n\t\t}\n\n\t\tif (start && !end) {\n\t\t\tif (this._dateAdapter.isAfter(date, start)) {\n\t\t\t\tthis.endDate.set(date);\n\t\t\t} else if (this._dateAdapter.isBefore(date, start)) {\n\t\t\t\tthis.startDate.set(date);\n\t\t\t\tthis.endDate.set(start);\n\t\t\t} else if (this._dateAdapter.isSameDay(date, start)) {\n\t\t\t\tthis.endDate.set(date);\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\n\t\t// If both start and end are selected, reset selection\n\t\tthis.startDate.set(date);\n\n\t\tthis.endDate.set(undefined);\n\t}\n\n\t// same as in brn-calendar.directive.ts\n\t/** @internal Constrain a date to the min and max boundaries */\n\tconstrainDate(date: T): T {\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\t// If there is no min or max, return the date.\n\t\tif (!min && !max) {\n\t\t\treturn date;\n\t\t}\n\n\t\t// If there is a min and the date is before the min, return the min.\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn min;\n\t\t}\n\n\t\t// If there is a max and the date is after the max, return the max.\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn max;\n\t\t}\n\n\t\t// Return the date.\n\t\treturn date;\n\t}\n\n\t/** @internal Determine if a date is disabled */\n\tisDateDisabled(date: T): boolean {\n\t\t// if the calendar is disabled we can't select this date\n\t\tif (this.disabled()) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if the date is outside the min and max range\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn true;\n\t\t}\n\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if this specific date is disabled\n\t\tconst disabledFn = this.dateDisabled();\n\n\t\tif (disabledFn(date)) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}\n\n\t/** @internal Set the focused date */\n\tsetFocusedDate(date: T): void {\n\t\t// check if the date is disabled.\n\t\tif (this.isDateDisabled(date)) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.state().focusedDate.set(date);\n\n\t\t// wait until the cells have all updated\n\t\tafterNextRender(\n\t\t\t{\n\t\t\t\twrite: () => {\n\t\t\t\t\t// focus the cell with the target date.\n\t\t\t\t\tconst cell = this._cells().find((c) => this._dateAdapter.isSameDay(c.date(), date));\n\n\t\t\t\t\tif (cell) {\n\t\t\t\t\t\tcell.focus();\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tinjector: this._injector,\n\t\t\t},\n\t\t);\n\n\t\t// we must update the view to ensure the focused cell is visible.\n\t\tthis._changeDetector.detectChanges();\n\t}\n\n\t/**\n\t * Determine if a date is the start of a range.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisStartOfRange(date: T): boolean {\n\t\tconst start = this.startDate();\n\t\treturn start ? this._dateAdapter.isSameDay(date, start) : false;\n\t}\n\n\t/**\n\t * Determine if a date is the end of a range.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisEndOfRange(date: T): boolean {\n\t\tconst end = this.endDate();\n\t\treturn end ? this._dateAdapter.isSameDay(date, end) : false;\n\t}\n\n\t/**\n\t * Determine if a date is between the start and end dates.\n\t * @param date The date to check.\n\t * @returns True if the date is between the start and end dates, false otherwise.\n\t * @internal\n\t */\n\tisBetweenRange(date: T): boolean {\n\t\tconst start = this.startDate();\n\t\tconst end = this.endDate();\n\n\t\tif (!start || !end) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn this._dateAdapter.isAfter(date, start) && this._dateAdapter.isBefore(date, end);\n\t}\n}\n","import { BrnCalendar } from './lib/brn-calendar';\nimport { BrnCalendarCell } from './lib/brn-calendar-cell';\nimport { BrnCalendarCellButton } from './lib/brn-calendar-cell-button';\nimport { BrnCalendarGrid } from './lib/brn-calendar-grid';\nimport { BrnCalendarHeader } from './lib/brn-calendar-header';\nimport { BrnCalendarMonthSelect } from './lib/brn-calendar-month-select';\nimport { BrnCalendarNextButton } from './lib/brn-calendar-next-button';\nimport { BrnCalendarPreviousButton } from './lib/brn-calendar-previous-button';\nimport { BrnCalendarWeek } from './lib/brn-calendar-week';\nimport { BrnCalendarWeekday } from './lib/brn-calendar-weekday';\nimport { BrnCalendarYearSelect } from './lib/brn-calendar-year-select';\nimport { BrnCalendarMulti } from './lib/mode/brn-calendar-multiple';\nimport { BrnCalendarRange } from './lib/mode/brn-calendar-range';\n\nexport * from './lib/brn-calendar';\nexport * from './lib/brn-calendar-cell';\nexport * from './lib/brn-calendar-cell-button';\nexport * from './lib/brn-calendar-grid';\nexport * from './lib/brn-calendar-header';\nexport * from './lib/brn-calendar-month-select';\nexport * from './lib/brn-calendar-next-button';\nexport * from './lib/brn-calendar-previous-button';\nexport * from './lib/brn-calendar-week';\nexport * from './lib/brn-calendar-weekday';\nexport * from './lib/brn-calendar-year-select';\nexport * from './lib/brn-calendar.token';\nexport * from './lib/i18n/calendar-i18n';\nexport * from './lib/mode/brn-calendar-multiple';\nexport * from './lib/mode/brn-calendar-range';\n\nexport const BrnCalendarImports = [\n\tBrnCalendarCellButton,\n\tBrnCalendarGrid,\n\tBrnCalendarHeader,\n\tBrnCalendarNextButton,\n\tBrnCalendarPreviousButton,\n\tBrnCalendarWeek,\n\tBrnCalendarWeekday,\n\tBrnCalendar,\n\tBrnCalendarCell,\n\tBrnCalendarMulti,\n\tBrnCalendarRange,\n\tBrnCalendarMonthSelect,\n\tBrnCalendarYearSelect,\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;MA+Ba,gBAAgB,GAAG,IAAI,cAAc,CAA2B,kBAAkB;AAEzF,SAAU,kBAAkB,CAAI,QAAkC,EAAA;IACvE,OAAO,EAAE,OAAO,EAAE,gBAAgB,EAAE,WAAW,EAAE,QAAQ,EAAE;AAC5D;AAEA;;AAEG;SACa,iBAAiB,GAAA;AAChC,IAAA,OAAO,MAAM,CAAC,gBAAgB,CAAuB;AACtD;;MCXa,qBAAqB,CAAA;;IAEd,YAAY,GAAG,iBAAiB,EAAK;;IAGrC,SAAS,GAAG,iBAAiB,EAAK;;AAGpC,IAAA,WAAW,GAAG,MAAM,CAAgC,UAAU,CAAC;;AAGhE,IAAA,IAAI,GAAG,KAAK,CAAC,QAAQ,EAAK;;AAG1B,IAAA,QAAQ,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;AACjE,IAAA,KAAK,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;AAClE,IAAA,GAAG,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,SAAS,CAAC,YAAY,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;AAC9D,IAAA,YAAY,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;;IAGzE,SAAS,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,YAAY,CAAC,SAAS,CAAC,IAAI,CAAC,SAAS,CAAC,WAAW,EAAE,EAAE,IAAI,CAAC,IAAI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A,EAAA,SAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,OAAA,EAAA,EAAA,SAAA,EAAA,iBAAA,EAAA,OAAA,EAAA,eAAA,EAAA,EAAA,SAAA,EAFjB,CAAC,kBAAkB,CAAC,gBAAgB,CAAC,CAAC,EAAA,OAAA,EAAA,CAAA,EAAA,YAAA,EAAA,QAAA,EAAA,KAAA,EAAA,IAAA,EAAA,SAAA,EAsCX,iBAAiB,EAAA,WAAA,EAAA,IAAA,EAAA,QAAA,EAAA,IAAA,EAAA,EAAA,EAAA,YAAA,EAAA,QAAA,EAAA,SAAA,EAGe,qBAAqB,EAAA,WAAA,EAAA,IAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAvC/E,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAJ5B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,QAAQ,EAAE,oBAAoB;AAC9B,oBAAA,SAAS,EAAE,CAAC,kBAAkB,CAAA,gBAAA,CAAkB,CAAC;AACjD,iBAAA;;;ACKM,MAAM,kBAAkB,GAAG;IACjC,qBAAqB;IACrB,eAAe;IACf,iBAAiB;IACjB,qBAAqB;IACrB,yBAAyB;IACzB,eAAe;IACf,kBAAkB;IAClB,WAAW;IACX,eAAe;IACf,gBAAgB;IAChB,gBAAgB;IAChB,sBAAsB;IACtB,qBAAqB;;;AC3CtB;;AAEG;;;;"}
1
+ {"version":3,"file":"spartan-ng-brain-calendar.mjs","sources":["../../../../libs/brain/calendar/src/lib/brn-calendar.token.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-cell-button.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-header.ts","../../../../libs/brain/calendar/src/lib/i18n/calendar-i18n.ts","../../../../libs/brain/calendar/src/lib/brn-calendar.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-cell.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-grid.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-month-select.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-next-button.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-previous-button.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-week.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-weekday.ts","../../../../libs/brain/calendar/src/lib/brn-calendar-year-select.ts","../../../../libs/brain/calendar/src/lib/mode/brn-calendar-multiple.ts","../../../../libs/brain/calendar/src/lib/mode/brn-calendar-range.ts","../../../../libs/brain/calendar/src/index.ts","../../../../libs/brain/calendar/src/spartan-ng-brain-calendar.ts"],"sourcesContent":["import {\n\ttype ExistingProvider,\n\tInjectionToken,\n\ttype Signal,\n\ttype Type,\n\ttype WritableSignal,\n\tinject,\n} from '@angular/core';\nimport type { BrnCalendarHeader } from './brn-calendar-header';\n\nexport interface BrnCalendarBase<T> {\n\tisSelected: (date: T) => boolean;\n\tselectDate: (date: T) => void;\n\n\tconstrainDate: (date: T) => T;\n\tisDateDisabled: (date: T) => boolean;\n\tsetFocusedDate: (date: T) => void;\n\n\tisStartOfRange: (date: T) => boolean;\n\tisEndOfRange: (date: T) => boolean;\n\tisBetweenRange: (date: T) => boolean;\n\n\tdisabled: Signal<boolean>;\n\tfocusedDate: WritableSignal<T>;\n\theader: Signal<BrnCalendarHeader | undefined>;\n\tdays: Signal<T[]>;\n}\n\nexport const BrnCalendarToken = new InjectionToken<BrnCalendarBase<unknown>>('BrnCalendarToken');\n\nexport function provideBrnCalendar<T>(instance: Type<BrnCalendarBase<T>>): ExistingProvider {\n\treturn { provide: BrnCalendarToken, useExisting: instance };\n}\n\n/**\n * Inject the calendar component.\n */\nexport function injectBrnCalendar<T>(): BrnCalendarBase<T> {\n\treturn inject(BrnCalendarToken) as BrnCalendarBase<T>;\n}\n","import { Directive, ElementRef, computed, inject, input } from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { injectBrnCalendar } from './brn-calendar.token';\n\n@Directive({\n\tselector: 'button[brnCalendarCellButton]',\n\thost: {\n\t\trole: 'gridcell',\n\t\t'[tabindex]': 'focusable() ? 0 : -1',\n\t\ttype: 'button',\n\t\t'[attr.data-outside]': \"outside() && (!end() && !start())? '' : null\",\n\t\t'[attr.data-today]': \"today() && !selected() ? '' : null\",\n\t\t'[attr.data-selected]': \"selected() ? '' : null\",\n\t\t'[attr.data-disabled]': \"disabled() ? '' : null\",\n\t\t'[attr.aria-selected]': \"selected() ? 'true' : null\",\n\t\t'[attr.aria-disabled]': \"disabled() ? 'true' : null\",\n\t\t'[attr.data-range-start]': 'start() ? \"\" : null',\n\t\t'[attr.data-range-end]': 'end() ? \"\" : null',\n\t\t'[attr.data-range-between]': 'betweenRange() ? \"\" : null',\n\t\t'[disabled]': 'disabled()',\n\t\t'(click)': '_calendar.selectDate(date())',\n\t\t'(keydown.arrowLeft)': 'focusPrevious($event)',\n\t\t'(keydown.arrowRight)': 'focusNext($event)',\n\t\t'(keydown.arrowUp)': 'focusAbove($event)',\n\t\t'(keydown.arrowDown)': 'focusBelow($event)',\n\t\t'(keydown.home)': 'focusFirst($event)',\n\t\t'(keydown.end)': 'focusLast($event)',\n\t\t'(keydown.pageUp)': 'focusPreviousMonth($event)',\n\t\t'(keydown.pageDown)': 'focusNextMonth($event)',\n\t},\n})\nexport class BrnCalendarCellButton<T> {\n\t/** Access the date adapter */\n\tprotected readonly _dateAdapter = injectDateAdapter<T>();\n\n\t/** Access the calendar component */\n\tprotected readonly _calendar = injectBrnCalendar<T>();\n\n\t/** Access the element ref */\n\tprivate readonly _elementRef = inject<ElementRef<HTMLButtonElement>>(ElementRef);\n\n\t/** The date this cell represents */\n\tpublic readonly date = input.required<T>();\n\n\t/** Whether this date is currently selected */\n\tpublic readonly selected = computed(() => this._calendar.isSelected(this.date()));\n\tpublic readonly start = computed(() => this._calendar.isStartOfRange(this.date()));\n\tpublic readonly end = computed(() => this._calendar.isEndOfRange(this.date()));\n\tpublic readonly betweenRange = computed(() => this._calendar.isBetweenRange(this.date()));\n\n\t/** Whether this date is focusable */\n\tpublic readonly focusable = computed(() => this._dateAdapter.isSameDay(this._calendar.focusedDate(), this.date()));\n\n\tpublic readonly outside = computed(() => {\n\t\tconst focusedDate = this._calendar.focusedDate();\n\t\treturn !this._dateAdapter.isSameMonth(this.date(), focusedDate);\n\t});\n\n\t/** Whether this date is today */\n\tpublic readonly today = computed(() => this._dateAdapter.isSameDay(this.date(), this._dateAdapter.now()));\n\n\t/** Whether this date is disabled */\n\tpublic readonly disabled = computed(() => this._calendar.isDateDisabled(this.date()) || this._calendar.disabled());\n\n\t/**\n\t * Focus the previous cell.\n\t */\n\tprotected focusPrevious(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\n\t\t// in rtl, the arrow keys are reversed.\n\t\tconst targetDate = this._dateAdapter.add(this._calendar.focusedDate(), {\n\t\t\tdays: this.getDirection() === 'rtl' ? 1 : -1,\n\t\t});\n\n\t\tthis._calendar.setFocusedDate(targetDate);\n\t}\n\n\t/**\n\t * Focus the next cell.\n\t */\n\tprotected focusNext(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\n\t\tconst targetDate = this._dateAdapter.add(this._calendar.focusedDate(), {\n\t\t\tdays: this.getDirection() === 'rtl' ? -1 : 1,\n\t\t});\n\n\t\tthis._calendar.setFocusedDate(targetDate);\n\t}\n\n\t/**\n\t * Focus the above cell.\n\t */\n\tprotected focusAbove(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\t\tthis._calendar.setFocusedDate(this._dateAdapter.subtract(this._calendar.focusedDate(), { days: 7 }));\n\t}\n\n\t/**\n\t * Focus the below cell.\n\t */\n\tprotected focusBelow(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\t\tthis._calendar.setFocusedDate(this._dateAdapter.add(this._calendar.focusedDate(), { days: 7 }));\n\t}\n\n\t/**\n\t * Focus the first date of the month.\n\t */\n\tprotected focusFirst(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\t\tthis._calendar.setFocusedDate(this._dateAdapter.startOfMonth(this._calendar.focusedDate()));\n\t}\n\n\t/**\n\t * Focus the last date of the month.\n\t */\n\tprotected focusLast(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\t\tthis._calendar.setFocusedDate(this._dateAdapter.endOfMonth(this._calendar.focusedDate()));\n\t}\n\n\t/**\n\t * Focus the same date in the previous month.\n\t */\n\tprotected focusPreviousMonth(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\n\t\tconst date = this._dateAdapter.getDate(this._calendar.focusedDate());\n\n\t\tlet previousMonthTarget = this._dateAdapter.startOfMonth(this._calendar.focusedDate());\n\t\tpreviousMonthTarget = this._dateAdapter.subtract(previousMonthTarget, { months: 1 });\n\n\t\tconst lastDay = this._dateAdapter.endOfMonth(previousMonthTarget);\n\n\t\t// if we are on a date that does not exist in the previous month, we should focus the last day of the month.\n\t\tif (date > this._dateAdapter.getDate(lastDay)) {\n\t\t\tthis._calendar.setFocusedDate(lastDay);\n\t\t} else {\n\t\t\tthis._calendar.setFocusedDate(this._dateAdapter.set(previousMonthTarget, { day: date }));\n\t\t}\n\t}\n\n\t/**\n\t * Focus the same date in the next month.\n\t */\n\tprotected focusNextMonth(event: Event): void {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\n\t\tconst date = this._dateAdapter.getDate(this._calendar.focusedDate());\n\n\t\tlet nextMonthTarget = this._dateAdapter.startOfMonth(this._calendar.focusedDate());\n\t\tnextMonthTarget = this._dateAdapter.add(nextMonthTarget, { months: 1 });\n\n\t\tconst lastDay = this._dateAdapter.endOfMonth(nextMonthTarget);\n\n\t\t// if we are on a date that does not exist in the next month, we should focus the last day of the month.\n\t\tif (date > this._dateAdapter.getDate(lastDay)) {\n\t\t\tthis._calendar.setFocusedDate(lastDay);\n\t\t} else {\n\t\t\tthis._calendar.setFocusedDate(this._dateAdapter.set(nextMonthTarget, { day: date }));\n\t\t}\n\t}\n\n\t/**\n\t * Get the direction of the element.\n\t */\n\tprivate getDirection(): 'ltr' | 'rtl' {\n\t\treturn getComputedStyle(this._elementRef.nativeElement).direction === 'rtl' ? 'rtl' : 'ltr';\n\t}\n\n\tfocus(): void {\n\t\tthis._elementRef.nativeElement.focus();\n\t}\n}\n","import { Directive, input } from '@angular/core';\n\nlet uniqueId = 0;\n\n@Directive({\n\tselector: '[brnCalendarHeader]',\n\thost: {\n\t\t'[id]': 'id()',\n\t\t'aria-live': 'polite',\n\t\trole: 'presentation',\n\t},\n})\nexport class BrnCalendarHeader {\n\t/** The unique id for the header */\n\tpublic readonly id = input(`brn-calendar-header-${++uniqueId}`);\n}\n","import { inject, Injectable, InjectionToken, type Provider, signal } from '@angular/core';\n\nexport type Weekday = 0 | 1 | 2 | 3 | 4 | 5 | 6;\n\ninterface BrnCalendarI18n {\n\tformatWeekdayName: (index: number) => string;\n\tformatHeader: (month: number, year: number) => string;\n\tformatYear: (year: number) => string;\n\tformatMonth: (month: number) => string;\n\tlabelPrevious: () => string;\n\tlabelNext: () => string;\n\tlabelWeekday: (index: number) => string;\n\tmonths: () => [string, string, string, string, string, string, string, string, string, string, string, string];\n\tyears: (startYear?: number, endYear?: number) => number[];\n\tfirstDayOfWeek: () => Weekday;\n}\n\nexport const BrnCalendarI18nToken = new InjectionToken<BrnCalendarI18nService>('BrnCalendarI18nToken');\n\n/**\n * Provide the calendar i18n configuration.\n */\nexport function provideBrnCalendarI18n(configuration?: BrnCalendarI18n): Provider {\n\treturn {\n\t\tprovide: BrnCalendarI18nToken,\n\t\tuseFactory: () => {\n\t\t\tconst service = new BrnCalendarI18nService();\n\t\t\tservice.use(configuration ?? defaultCalendarI18n);\n\t\t\treturn service;\n\t\t},\n\t};\n}\n\nconst defaultCalendarI18n: BrnCalendarI18n = {\n\tformatWeekdayName: (index: number) => {\n\t\tconst weekdays = ['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa'];\n\t\treturn weekdays[index];\n\t},\n\tmonths: () => ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],\n\tyears: (startYear = 1925, endYear = new Date().getFullYear()) =>\n\t\tArray.from({ length: endYear - startYear + 1 }, (_, i) => startYear + i),\n\tformatHeader: (month: number, year: number) => {\n\t\treturn new Date(year, month).toLocaleDateString(undefined, {\n\t\t\tmonth: 'long',\n\t\t\tyear: 'numeric',\n\t\t});\n\t},\n\tformatMonth: (month: number) => {\n\t\treturn new Date(2000, month).toLocaleDateString(undefined, {\n\t\t\tmonth: 'short',\n\t\t});\n\t},\n\tformatYear: (year: number): string => {\n\t\treturn new Date(year, 0).toLocaleDateString(undefined, {\n\t\t\tyear: 'numeric',\n\t\t});\n\t},\n\tlabelPrevious: () => 'Go to the previous month',\n\tlabelNext: () => 'Go to the next month',\n\tlabelWeekday: (index: number) => {\n\t\tconst weekdays = ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'];\n\t\treturn weekdays[index];\n\t},\n\tfirstDayOfWeek: () => 0,\n};\n\n/**\n * Inject the calendar i18n configuration.\n */\nexport function injectBrnCalendarI18n(): BrnCalendarI18nService {\n\treturn inject(BrnCalendarI18nToken, { optional: true }) ?? inject(BrnCalendarI18nService); // fallback\n}\n\n@Injectable({ providedIn: 'root' })\nexport class BrnCalendarI18nService {\n\tprivate readonly _config = signal<BrnCalendarI18n>(defaultCalendarI18n);\n\n\tpublic readonly config = this._config.asReadonly();\n\n\tpublic use(config: Partial<BrnCalendarI18n>) {\n\t\tthis._config.set({ ...this.config(), ...config });\n\t}\n}\n","import type { BooleanInput, NumberInput } from '@angular/cdk/coercion';\nimport {\n\tafterNextRender,\n\tbooleanAttribute,\n\tChangeDetectorRef,\n\tcomputed,\n\tcontentChild,\n\tcontentChildren,\n\tDirective,\n\tinject,\n\tInjector,\n\tinput,\n\tlinkedSignal,\n\tmodel,\n\tnumberAttribute,\n} from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { BrnCalendarCellButton } from './brn-calendar-cell-button';\nimport { BrnCalendarHeader } from './brn-calendar-header';\nimport { type BrnCalendarBase, provideBrnCalendar } from './brn-calendar.token';\nimport { injectBrnCalendarI18n, type Weekday } from './i18n/calendar-i18n';\n\n@Directive({\n\tselector: '[brnCalendar]',\n\tproviders: [provideBrnCalendar(BrnCalendar)],\n})\nexport class BrnCalendar<T> implements BrnCalendarBase<T> {\n\tprivate readonly _i18n = injectBrnCalendarI18n();\n\n\t/** Access the date adapter */\n\tprotected readonly _dateAdapter = injectDateAdapter<T>();\n\n\t/** Access the change detector */\n\tprivate readonly _changeDetector = inject(ChangeDetectorRef);\n\n\t/** Access the injector */\n\tprivate readonly _injector = inject(Injector);\n\n\t/** The minimum date that can be selected.*/\n\tpublic readonly min = input<T>();\n\n\t/** The maximum date that can be selected. */\n\tpublic readonly max = input<T>();\n\n\t/** Determine if the date picker is disabled. */\n\tpublic readonly disabled = input<boolean, BooleanInput>(false, {\n\t\ttransform: booleanAttribute,\n\t});\n\n\t/** The selected value. */\n\tpublic readonly date = model<T>();\n\n\t/** Whether a specific date is disabled. */\n\tpublic readonly dateDisabled = input<(date: T) => boolean>(() => false);\n\n\t/** The day the week starts on */\n\tpublic readonly weekStartsOn = input<Weekday, NumberInput | undefined>(undefined, {\n\t\ttransform: (v: unknown) => (v === undefined || v === null ? undefined : (numberAttribute(v) as Weekday)),\n\t});\n\n\tprotected readonly _weekStartsOn = computed(() => this.weekStartsOn() ?? this._i18n.config().firstDayOfWeek());\n\n\t/** The default focused date. */\n\tpublic readonly defaultFocusedDate = input<T>();\n\n\t/** @internal Access the header */\n\tpublic readonly header = contentChild(BrnCalendarHeader);\n\n\t/** Store the cells */\n\tprotected readonly _cells = contentChildren<BrnCalendarCellButton<T>>(BrnCalendarCellButton, {\n\t\tdescendants: true,\n\t});\n\n\t/**\n\t * The focused date.\n\t */\n\tpublic readonly focusedDate = linkedSignal(() =>\n\t\tthis.constrainDate(this.defaultFocusedDate() ?? this.date() ?? this._dateAdapter.now()),\n\t);\n\n\t/**\n\t * Get all the days to display, this is the days of the current month\n\t * and the days of the previous and next month to fill the grid.\n\t */\n\tpublic readonly days = computed(() => {\n\t\tconst weekStartsOn = this._weekStartsOn();\n\t\tconst month = this.focusedDate();\n\t\tconst days: T[] = [];\n\n\t\t// Get the first and last day of the month.\n\t\tlet firstDay = this._dateAdapter.startOfMonth(month);\n\t\tlet lastDay = this._dateAdapter.endOfMonth(month);\n\n\t\t// we need to subtract until we get the to starting day before or on the start of the month.\n\t\twhile (this._dateAdapter.getDay(firstDay) !== weekStartsOn) {\n\t\t\tfirstDay = this._dateAdapter.subtract(firstDay, { days: 1 });\n\t\t}\n\n\t\tconst weekEndsOn = (weekStartsOn + 6) % 7;\n\n\t\t// we need to add until we get to the ending day after or on the end of the month.\n\t\twhile (this._dateAdapter.getDay(lastDay) !== weekEndsOn) {\n\t\t\tlastDay = this._dateAdapter.add(lastDay, { days: 1 });\n\t\t}\n\n\t\t// collect all the days to display.\n\t\twhile (firstDay <= lastDay) {\n\t\t\tdays.push(firstDay);\n\t\t\tfirstDay = this._dateAdapter.add(firstDay, { days: 1 });\n\t\t}\n\n\t\treturn days;\n\t});\n\n\t/** @internal Constrain a date to the min and max boundaries */\n\tconstrainDate(date: T): T {\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\t// If there is no min or max, return the date.\n\t\tif (!min && !max) {\n\t\t\treturn date;\n\t\t}\n\n\t\t// If there is a min and the date is before the min, return the min.\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn min;\n\t\t}\n\n\t\t// If there is a max and the date is after the max, return the max.\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn max;\n\t\t}\n\n\t\t// Return the date.\n\t\treturn date;\n\t}\n\n\t/** @internal Determine if a date is disabled */\n\tisDateDisabled(date: T): boolean {\n\t\t// if the calendar is disabled we can't select this date\n\t\tif (this.disabled()) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if the date is outside the min and max range\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn true;\n\t\t}\n\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if this specific date is disabled\n\t\tconst disabledFn = this.dateDisabled();\n\n\t\tif (disabledFn(date)) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}\n\n\tisSelected(date: T): boolean {\n\t\tconst selected = this.date() as T | undefined;\n\t\treturn selected !== undefined && this._dateAdapter.isSameDay(date, selected);\n\t}\n\n\tselectDate(date: T): void {\n\t\tif (this.isSelected(date)) {\n\t\t\tthis.date.set(undefined);\n\t\t} else {\n\t\t\tthis.date.set(date);\n\t\t}\n\t\tthis.focusedDate.set(date);\n\t}\n\n\t/** @internal Set the focused date */\n\tsetFocusedDate(date: T): void {\n\t\t// check if the date is disabled.\n\t\tif (this.isDateDisabled(date)) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.focusedDate.set(date);\n\n\t\t// wait until the cells have all updated\n\t\tafterNextRender(\n\t\t\t{\n\t\t\t\twrite: () => {\n\t\t\t\t\t// focus the cell with the target date.\n\t\t\t\t\tconst cell = this._cells().find((c) => this._dateAdapter.isSameDay(c.date(), date));\n\n\t\t\t\t\tif (cell) {\n\t\t\t\t\t\tcell.focus();\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tinjector: this._injector,\n\t\t\t},\n\t\t);\n\n\t\t// we must update the view to ensure the focused cell is visible.\n\t\tthis._changeDetector.detectChanges();\n\t}\n\n\t/**\n\t * Determine if a date is the start of a range. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisStartOfRange(_: T): boolean {\n\t\treturn false;\n\t}\n\n\t/**\n\t * Determine if a date is the end of a range. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisEndOfRange(_: T): boolean {\n\t\treturn false;\n\t}\n\n\t/**\n\t * Determine if a date is between the start and end dates. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns True if the date is between the start and end dates, false otherwise.\n\t * @internal\n\t */\n\tisBetweenRange(_: T): boolean {\n\t\treturn false;\n\t}\n}\n","import { Directive } from '@angular/core';\n\n@Directive({\n\tselector: '[brnCalendarCell]',\n\thost: {\n\t\trole: 'presentation',\n\t},\n})\nexport class BrnCalendarCell {}\n","import { Directive } from '@angular/core';\nimport { injectBrnCalendar } from './brn-calendar.token';\n\n@Directive({\n\tselector: '[brnCalendarGrid]',\n\thost: {\n\t\trole: 'grid',\n\t\t'[attr.aria-labelledby]': '_calendar.header()?.id()',\n\t},\n})\nexport class BrnCalendarGrid<T> {\n\t/** Access the calendar component */\n\tprotected readonly _calendar = injectBrnCalendar<T>();\n}\n","import { computed, Directive, effect, inject } from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { BrnSelect } from '@spartan-ng/brain/select';\nimport { injectBrnCalendar } from './brn-calendar.token';\nimport { injectBrnCalendarI18n } from './i18n/calendar-i18n';\n\n@Directive({\n\tselector: 'brn-select[brnCalendarMonthSelect]',\n\thost: {\n\t\t'(valueChange)': 'monthSelected($event)',\n\t},\n})\nexport class BrnCalendarMonthSelect {\n\t/** Access the select */\n\tprivate readonly _select = inject(BrnSelect);\n\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar();\n\n\t/** Access the date adapter */\n\tprivate readonly _dateAdapter = injectDateAdapter();\n\n\t/** Access the calendar i18n */\n\tprotected readonly _i18n = injectBrnCalendarI18n();\n\n\tprotected readonly _selectedMonth = computed(() => {\n\t\treturn this._i18n.config().months()[this._dateAdapter.getMonth(this._calendar.focusedDate())];\n\t});\n\n\tconstructor() {\n\t\teffect(() => {\n\t\t\tthis._select.writeValue(this._selectedMonth());\n\t\t});\n\t}\n\n\t/** Focus selected month */\n\tprotected monthSelected(selectedMonth: string): void {\n\t\tconst month = this._i18n\n\t\t\t.config()\n\t\t\t.months()\n\t\t\t.findIndex((month) => month === selectedMonth);\n\t\tconst targetDate = this._dateAdapter.set(this._calendar.focusedDate(), { month });\n\t\tthis._calendar.focusedDate.set(targetDate);\n\t}\n}\n","import { Directive } from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { injectBrnCalendar } from './brn-calendar.token';\nimport { injectBrnCalendarI18n } from './i18n/calendar-i18n';\n\n@Directive({\n\tselector: '[brnCalendarNextButton]',\n\thost: {\n\t\ttype: 'button',\n\t\t'[attr.aria-label]': '_i18n.config().labelNext()',\n\t\t'(click)': 'focusPreviousMonth()',\n\t},\n})\nexport class BrnCalendarNextButton {\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar();\n\n\t/** Access the date adapter */\n\tprivate readonly _dateAdapter = injectDateAdapter();\n\n\t/** Access the calendar i18n */\n\tprotected readonly _i18n = injectBrnCalendarI18n();\n\n\t/** Focus the previous month */\n\tprotected focusPreviousMonth(): void {\n\t\tconst targetDate = this._dateAdapter.add(this._calendar.focusedDate(), { months: 1 });\n\n\t\t// if the date is disabled, but there are available dates in the month, focus the last day of the month.\n\t\tconst possibleDate = this._calendar.constrainDate(targetDate);\n\n\t\tif (this._dateAdapter.isSameMonth(possibleDate, targetDate)) {\n\t\t\t// if this date is within the same month, then focus it\n\t\t\tthis._calendar.focusedDate.set(possibleDate);\n\t\t\treturn;\n\t\t}\n\n\t\tthis._calendar.focusedDate.set(targetDate);\n\t}\n}\n","import { Directive } from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { injectBrnCalendar } from './brn-calendar.token';\nimport { injectBrnCalendarI18n } from './i18n/calendar-i18n';\n\n@Directive({\n\tselector: '[brnCalendarPreviousButton]',\n\thost: {\n\t\ttype: 'button',\n\t\t'[attr.aria-label]': '_i18n.config().labelPrevious()',\n\t\t'(click)': 'focusPreviousMonth()',\n\t},\n})\nexport class BrnCalendarPreviousButton {\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar();\n\n\t/** Access the date adapter */\n\tprivate readonly _dateAdapter = injectDateAdapter();\n\n\t/** Access the calendar i18n */\n\tprotected readonly _i18n = injectBrnCalendarI18n();\n\n\t/** Focus the previous month */\n\tprotected focusPreviousMonth(): void {\n\t\tconst targetDate = this._dateAdapter.subtract(this._calendar.focusedDate(), { months: 1 });\n\n\t\t// if the date is disabled, but there are available dates in the month, focus the last day of the month.\n\t\tconst possibleDate = this._calendar.constrainDate(targetDate);\n\n\t\tif (this._dateAdapter.isSameMonth(possibleDate, targetDate)) {\n\t\t\t// if this date is within the same month, then focus it\n\t\t\tthis._calendar.focusedDate.set(possibleDate);\n\t\t\treturn;\n\t\t}\n\n\t\tthis._calendar.focusedDate.set(targetDate);\n\t}\n}\n","import {\n\tChangeDetectorRef,\n\tDirective,\n\ttype EmbeddedViewRef,\n\ttype OnDestroy,\n\tTemplateRef,\n\tViewContainerRef,\n\tcomputed,\n\teffect,\n\tinject,\n\tuntracked,\n} from '@angular/core';\nimport { injectBrnCalendar } from './brn-calendar.token';\n\n@Directive({\n\tselector: '[brnCalendarWeek]',\n})\nexport class BrnCalendarWeek<T> implements OnDestroy {\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar<T>();\n\n\t/** Access the view container ref */\n\tprivate readonly _viewContainerRef = inject(ViewContainerRef);\n\n\t/** Access the change detector */\n\tprivate readonly _changeDetector = inject(ChangeDetectorRef);\n\n\t/** Access the template ref */\n\tprivate readonly _templateRef = inject<TemplateRef<BrnWeekContext<T>>>(TemplateRef);\n\n\t// get the weeks to display.\n\tprotected readonly _weeks = computed(() => {\n\t\tconst days = this._calendar.days();\n\t\tconst weeks = [];\n\n\t\tfor (let i = 0; i < days.length; i += 7) {\n\t\t\tweeks.push(days.slice(i, i + 7));\n\t\t}\n\n\t\treturn weeks;\n\t});\n\n\t/** Store the view refs */\n\tprivate _viewRefs: EmbeddedViewRef<BrnWeekContext<T>>[] = [];\n\n\t// Make sure the template checker knows the type of the context with which the\n\t// template of this directive will be rendered\n\tstatic ngTemplateContextGuard<T>(_: BrnCalendarWeek<T>, ctx: unknown): ctx is BrnWeekContext<T> {\n\t\treturn true;\n\t}\n\n\tconstructor() {\n\t\t// this should use `afterRenderEffect` but it's not available in the current version\n\t\teffect(() => {\n\t\t\tconst weeks = this._weeks();\n\t\t\tuntracked(() => this._renderWeeks(weeks));\n\t\t});\n\t}\n\n\tprivate _renderWeeks(weeks: T[][]): void {\n\t\t// Destroy all the views when the directive is destroyed\n\t\tfor (const viewRef of this._viewRefs) {\n\t\t\tviewRef.destroy();\n\t\t}\n\n\t\tthis._viewRefs = [];\n\n\t\t// Create a new view for each week\n\t\tfor (const week of weeks) {\n\t\t\tconst viewRef = this._viewContainerRef.createEmbeddedView(this._templateRef, {\n\t\t\t\t$implicit: week,\n\t\t\t});\n\t\t\tthis._viewRefs.push(viewRef);\n\t\t}\n\n\t\tthis._changeDetector.detectChanges();\n\t}\n\n\tngOnDestroy(): void {\n\t\t// Destroy all the views when the directive is destroyed\n\t\tfor (const viewRef of this._viewRefs) {\n\t\t\tviewRef.destroy();\n\t\t}\n\t}\n}\n\ninterface BrnWeekContext<T> {\n\t$implicit: T[];\n}\n","import {\n\tChangeDetectorRef,\n\tcomputed,\n\tDirective,\n\teffect,\n\ttype EmbeddedViewRef,\n\tinject,\n\ttype OnDestroy,\n\tTemplateRef,\n\tuntracked,\n\tViewContainerRef,\n} from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { injectBrnCalendar } from './brn-calendar.token';\n\n@Directive({\n\tselector: '[brnCalendarWeekday]',\n})\nexport class BrnCalendarWeekday<T> implements OnDestroy {\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar<T>();\n\n\t/** Access the date time adapter */\n\tprivate readonly _dateAdapter = injectDateAdapter<T>();\n\n\t/** Access the view container ref */\n\tprivate readonly _viewContainerRef = inject(ViewContainerRef);\n\n\t/** Access the change detector */\n\tprivate readonly _changeDetector = inject(ChangeDetectorRef);\n\n\t/** Access the template ref */\n\tprivate readonly _templateRef = inject<TemplateRef<BrnWeekdayContext>>(TemplateRef);\n\n\t/** Get the days of the week to display in the header. */\n\tprotected readonly _weekdays = computed(() => this._calendar.days().slice(0, 7));\n\n\t/** Store the view refs */\n\tprivate _viewRefs: EmbeddedViewRef<BrnWeekdayContext>[] = [];\n\n\t// Make sure the template checker knows the type of the context with which the\n\t// template of this directive will be rendered\n\tstatic ngTemplateContextGuard<T>(_: BrnCalendarWeekday<T>, ctx: unknown): ctx is BrnWeekdayContext {\n\t\treturn true;\n\t}\n\n\tconstructor() {\n\t\t// Create a new view for each day\n\t\teffect(() => {\n\t\t\t// Get the weekdays to display\n\t\t\tconst weekdays = this._weekdays();\n\t\t\t// Render the weekdays\n\t\t\tuntracked(() => this._renderWeekdays(weekdays));\n\t\t});\n\t}\n\n\tprivate _renderWeekdays(weekdays: T[]): void {\n\t\t// Destroy all the views when the directive is destroyed\n\t\tfor (const viewRef of this._viewRefs) {\n\t\t\tviewRef.destroy();\n\t\t}\n\n\t\tthis._viewRefs = [];\n\n\t\t// Create a new view for each day\n\t\tfor (const day of weekdays) {\n\t\t\tconst viewRef = this._viewContainerRef.createEmbeddedView(this._templateRef, {\n\t\t\t\t$implicit: this._dateAdapter.getDay(day),\n\t\t\t});\n\t\t\tthis._viewRefs.push(viewRef);\n\t\t}\n\n\t\tthis._changeDetector.detectChanges();\n\t}\n\n\tngOnDestroy(): void {\n\t\t// Destroy all the views when the directive is destroyed\n\t\tfor (const viewRef of this._viewRefs) {\n\t\t\tviewRef.destroy();\n\t\t}\n\t}\n}\n\ninterface BrnWeekdayContext {\n\t$implicit: number;\n}\n","import { Directive, effect, inject } from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { BrnSelect } from '@spartan-ng/brain/select';\nimport { injectBrnCalendar } from './brn-calendar.token';\nimport { injectBrnCalendarI18n } from './i18n/calendar-i18n';\n\n@Directive({\n\tselector: 'brn-select[brnCalendarYearSelect]',\n\thost: {\n\t\t'(valueChange)': 'yearSelected($event)',\n\t},\n})\nexport class BrnCalendarYearSelect {\n\t/** Access the select */\n\tprivate readonly _select = inject(BrnSelect);\n\n\t/** Access the calendar */\n\tprivate readonly _calendar = injectBrnCalendar();\n\n\t/** Access the date adapter */\n\tprivate readonly _dateAdapter = injectDateAdapter();\n\n\t/** Access the calendar i18n */\n\tprotected readonly _i18n = injectBrnCalendarI18n();\n\n\tconstructor() {\n\t\teffect(() => {\n\t\t\tthis._select.writeValue(this._dateAdapter.getYear(this._calendar.focusedDate()));\n\t\t});\n\t}\n\n\t/** Focus selected year */\n\tprotected yearSelected(year: number): void {\n\t\tconst targetDate = this._dateAdapter.set(this._calendar.focusedDate(), { year });\n\t\tthis._calendar.focusedDate.set(targetDate);\n\t}\n}\n","import type { BooleanInput, NumberInput } from '@angular/cdk/coercion';\nimport {\n\tafterNextRender,\n\tbooleanAttribute,\n\tChangeDetectorRef,\n\tcomputed,\n\tcontentChild,\n\tcontentChildren,\n\tDirective,\n\tinject,\n\tInjector,\n\tinput,\n\tlinkedSignal,\n\tmodel,\n\tnumberAttribute,\n} from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { BrnCalendarCellButton } from '../brn-calendar-cell-button';\nimport { BrnCalendarHeader } from '../brn-calendar-header';\nimport { type BrnCalendarBase, provideBrnCalendar } from '../brn-calendar.token';\nimport { injectBrnCalendarI18n, type Weekday } from '../i18n/calendar-i18n';\n\n@Directive({\n\tselector: '[brnCalendarMulti]',\n\tproviders: [provideBrnCalendar(BrnCalendarMulti)],\n})\nexport class BrnCalendarMulti<T> implements BrnCalendarBase<T> {\n\tprivate readonly _i18n = injectBrnCalendarI18n();\n\n\t/**\n\t * Determine if a date is the start of a range. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisStartOfRange(_: T): boolean {\n\t\treturn false;\n\t}\n\n\t/**\n\t * Determine if a date is the end of a range. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisEndOfRange(_: T): boolean {\n\t\treturn false;\n\t}\n\n\t/**\n\t * Determine if a date is between the start and end dates. In a date picker, this is always false.\n\t * @param date The date to check.\n\t * @returns True if the date is between the start and end dates, false otherwise.\n\t * @internal\n\t */\n\tisBetweenRange(_: T): boolean {\n\t\treturn false;\n\t}\n\n\t// /** Access the date adapter */\n\tprotected readonly _dateAdapter = injectDateAdapter<T>();\n\n\t/** Access the change detector */\n\tprivate readonly _changeDetector = inject(ChangeDetectorRef);\n\n\t/** Access the injector */\n\tprivate readonly _injector = inject(Injector);\n\n\t/** The minimum date that can be selected.*/\n\tpublic readonly min = input<T>();\n\n\t/** The maximum date that can be selected. */\n\tpublic readonly max = input<T>();\n\n\t/** The minimum selectable dates. */\n\tpublic readonly minSelection = input<number, NumberInput>(undefined, {\n\t\ttransform: numberAttribute,\n\t});\n\n\t/** The maximum selectable dates. */\n\tpublic readonly maxSelection = input<number, NumberInput>(undefined, {\n\t\ttransform: numberAttribute,\n\t});\n\n\t/** Determine if the date picker is disabled. */\n\tpublic readonly disabled = input<boolean, BooleanInput>(false, {\n\t\ttransform: booleanAttribute,\n\t});\n\n\t/** The selected value. */\n\tpublic readonly date = model<T[]>();\n\n\t/** Whether a specific date is disabled. */\n\tpublic readonly dateDisabled = input<(date: T) => boolean>(() => false);\n\n\t/** The day the week starts on */\n\tpublic readonly weekStartsOn = input<Weekday, NumberInput | undefined>(undefined, {\n\t\ttransform: (v: unknown) => (v === undefined || v === null ? undefined : (numberAttribute(v) as Weekday)),\n\t});\n\n\tprotected readonly _weekStartsOn = computed(() => this.weekStartsOn() ?? this._i18n.config().firstDayOfWeek());\n\n\t/** The default focused date. */\n\tpublic readonly defaultFocusedDate = input<T>();\n\n\t/** @internal Access the header */\n\tpublic readonly header = contentChild(BrnCalendarHeader);\n\n\t/** Store the cells */\n\tprotected readonly _cells = contentChildren<BrnCalendarCellButton<T>>(BrnCalendarCellButton, {\n\t\tdescendants: true,\n\t});\n\n\t/**\n\t * The focused date.\n\t */\n\tpublic readonly focusedDate = linkedSignal(() =>\n\t\tthis.constrainDate(this.defaultFocusedDate() ?? this._dateAdapter.now()),\n\t);\n\n\t/**\n\t * Get all the days to display, this is the days of the current month\n\t * and the days of the previous and next month to fill the grid.\n\t */\n\tpublic readonly days = computed(() => {\n\t\tconst weekStartsOn = this._weekStartsOn();\n\t\tconst month = this.focusedDate();\n\t\tconst days: T[] = [];\n\n\t\t// Get the first and last day of the month.\n\t\tlet firstDay = this._dateAdapter.startOfMonth(month);\n\t\tlet lastDay = this._dateAdapter.endOfMonth(month);\n\n\t\t// we need to subtract until we get the to starting day before or on the start of the month.\n\t\twhile (this._dateAdapter.getDay(firstDay) !== weekStartsOn) {\n\t\t\tfirstDay = this._dateAdapter.subtract(firstDay, { days: 1 });\n\t\t}\n\n\t\tconst weekEndsOn = (weekStartsOn + 6) % 7;\n\n\t\t// we need to add until we get to the ending day after or on the end of the month.\n\t\twhile (this._dateAdapter.getDay(lastDay) !== weekEndsOn) {\n\t\t\tlastDay = this._dateAdapter.add(lastDay, { days: 1 });\n\t\t}\n\n\t\t// collect all the days to display.\n\t\twhile (firstDay <= lastDay) {\n\t\t\tdays.push(firstDay);\n\t\t\tfirstDay = this._dateAdapter.add(firstDay, { days: 1 });\n\t\t}\n\n\t\treturn days;\n\t});\n\n\tisSelected(date: T): boolean {\n\t\treturn this.date()?.some((d) => this._dateAdapter.isSameDay(d, date)) ?? false;\n\t}\n\n\tselectDate(date: T): void {\n\t\tconst selected = this.date() as T[] | undefined;\n\t\tif (this.isSelected(date)) {\n\t\t\tconst minSelection = this.minSelection();\n\t\t\tif (selected?.length === minSelection) {\n\t\t\t\t// min selection reached, do not allow to deselect\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tthis.date.set(selected?.filter((d) => !this._dateAdapter.isSameDay(d, date)));\n\t\t} else {\n\t\t\tconst maxSelection = this.maxSelection();\n\t\t\tif (selected?.length === maxSelection) {\n\t\t\t\t// max selection reached, reset the selection to date\n\t\t\t\tthis.date.set([date]);\n\t\t\t} else {\n\t\t\t\t// add the date to the selection\n\t\t\t\tthis.date.set([...(selected ?? []), date]);\n\t\t\t}\n\t\t}\n\t}\n\n\t// same as in brn-calendar.directive.ts\n\t/** @internal Constrain a date to the min and max boundaries */\n\tconstrainDate(date: T): T {\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\t// If there is no min or max, return the date.\n\t\tif (!min && !max) {\n\t\t\treturn date;\n\t\t}\n\n\t\t// If there is a min and the date is before the min, return the min.\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn min;\n\t\t}\n\n\t\t// If there is a max and the date is after the max, return the max.\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn max;\n\t\t}\n\n\t\t// Return the date.\n\t\treturn date;\n\t}\n\n\t/** @internal Determine if a date is disabled */\n\tisDateDisabled(date: T): boolean {\n\t\t// if the calendar is disabled we can't select this date\n\t\tif (this.disabled()) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if the date is outside the min and max range\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn true;\n\t\t}\n\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if this specific date is disabled\n\t\tconst disabledFn = this.dateDisabled();\n\n\t\tif (disabledFn(date)) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}\n\n\t/** @internal Set the focused date */\n\tsetFocusedDate(date: T): void {\n\t\t// check if the date is disabled.\n\t\tif (this.isDateDisabled(date)) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.focusedDate.set(date);\n\n\t\t// wait until the cells have all updated\n\t\tafterNextRender(\n\t\t\t{\n\t\t\t\twrite: () => {\n\t\t\t\t\t// focus the cell with the target date.\n\t\t\t\t\tconst cell = this._cells().find((c) => this._dateAdapter.isSameDay(c.date(), date));\n\n\t\t\t\t\tif (cell) {\n\t\t\t\t\t\tcell.focus();\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tinjector: this._injector,\n\t\t\t},\n\t\t);\n\n\t\t// we must update the view to ensure the focused cell is visible.\n\t\tthis._changeDetector.detectChanges();\n\t}\n}\n","import type { BooleanInput, NumberInput } from '@angular/cdk/coercion';\nimport {\n\tafterNextRender,\n\tbooleanAttribute,\n\tChangeDetectorRef,\n\tcomputed,\n\tcontentChild,\n\tcontentChildren,\n\tDirective,\n\tinject,\n\tInjector,\n\tinput,\n\tlinkedSignal,\n\tmodel,\n\tnumberAttribute,\n} from '@angular/core';\nimport { injectDateAdapter } from '@spartan-ng/brain/date-time';\nimport { BrnCalendarCellButton } from '../brn-calendar-cell-button';\nimport { BrnCalendarHeader } from '../brn-calendar-header';\nimport { type BrnCalendarBase, provideBrnCalendar } from '../brn-calendar.token';\nimport { injectBrnCalendarI18n, type Weekday } from '../i18n/calendar-i18n';\n\n@Directive({\n\tselector: '[brnCalendarRange]',\n\tproviders: [provideBrnCalendar(BrnCalendarRange)],\n})\nexport class BrnCalendarRange<T> implements BrnCalendarBase<T> {\n\tprivate readonly _i18n = injectBrnCalendarI18n();\n\t// /** Access the date adapter */\n\tprotected readonly _dateAdapter = injectDateAdapter<T>();\n\n\t/** Access the change detector */\n\tprivate readonly _changeDetector = inject(ChangeDetectorRef);\n\n\t/** Access the injector */\n\tprivate readonly _injector = inject(Injector);\n\n\t/** The minimum date that can be selected.*/\n\tpublic readonly min = input<T>();\n\n\t/** The maximum date that can be selected. */\n\tpublic readonly max = input<T>();\n\n\t/** Determine if the date picker is disabled. */\n\tpublic readonly disabled = input<boolean, BooleanInput>(false, {\n\t\ttransform: booleanAttribute,\n\t});\n\n\t/** Whether a specific date is disabled. */\n\tpublic readonly dateDisabled = input<(date: T) => boolean>(() => false);\n\n\t/** The day the week starts on */\n\tpublic readonly weekStartsOn = input<Weekday, NumberInput | undefined>(undefined, {\n\t\ttransform: (v: unknown) => (v === undefined || v === null ? undefined : (numberAttribute(v) as Weekday)),\n\t});\n\n\tprotected readonly _weekStartsOn = computed(() => this.weekStartsOn() ?? this._i18n.config().firstDayOfWeek());\n\n\t/** The default focused date. */\n\tpublic readonly defaultFocusedDate = input<T>();\n\n\t/** @internal Access the header */\n\tpublic readonly header = contentChild(BrnCalendarHeader);\n\n\t/** Store the cells */\n\tprotected readonly _cells = contentChildren<BrnCalendarCellButton<T>>(BrnCalendarCellButton, {\n\t\tdescendants: true,\n\t});\n\n\t/**\n\t * The focused date.\n\t */\n\tpublic readonly focusedDate = linkedSignal(() =>\n\t\tthis.constrainDate(this.defaultFocusedDate() ?? this.startDate() ?? this._dateAdapter.now()),\n\t);\n\n\t/**\n\t * The selected start date\n\t */\n\tpublic readonly startDate = model<T>();\n\n\t/**\n\t * The selected end date\n\t */\n\tpublic readonly endDate = model<T>();\n\n\t/**\n\t * Get all the days to display, this is the days of the current month\n\t * and the days of the previous and next month to fill the grid.\n\t */\n\tpublic readonly days = computed(() => {\n\t\tconst weekStartsOn = this._weekStartsOn();\n\t\tconst month = this.focusedDate();\n\t\tconst days: T[] = [];\n\n\t\t// Get the first and last day of the month.\n\t\tlet firstDay = this._dateAdapter.startOfMonth(month);\n\t\tlet lastDay = this._dateAdapter.endOfMonth(month);\n\n\t\t// we need to subtract until we get the to starting day before or on the start of the month.\n\t\twhile (this._dateAdapter.getDay(firstDay) !== weekStartsOn) {\n\t\t\tfirstDay = this._dateAdapter.subtract(firstDay, { days: 1 });\n\t\t}\n\n\t\tconst weekEndsOn = (weekStartsOn + 6) % 7;\n\n\t\t// we need to add until we get to the ending day after or on the end of the month.\n\t\twhile (this._dateAdapter.getDay(lastDay) !== weekEndsOn) {\n\t\t\tlastDay = this._dateAdapter.add(lastDay, { days: 1 });\n\t\t}\n\n\t\t// collect all the days to display.\n\t\twhile (firstDay <= lastDay) {\n\t\t\tdays.push(firstDay);\n\t\t\tfirstDay = this._dateAdapter.add(firstDay, { days: 1 });\n\t\t}\n\n\t\treturn days;\n\t});\n\n\tisSelected(date: T): boolean {\n\t\tconst start = this.startDate();\n\t\tconst end = this.endDate();\n\n\t\tif (!start && !end) {\n\t\t\treturn false;\n\t\t}\n\t\tconst isStartSelected = start ? this._dateAdapter.isSameDay(date, start) : false;\n\t\tconst isEndSelected = end ? this._dateAdapter.isSameDay(date, end) : false;\n\n\t\treturn isStartSelected || isEndSelected;\n\t}\n\n\tselectDate(date: T): void {\n\t\tconst start = this.startDate();\n\t\tconst end = this.endDate();\n\n\t\tif (!start && !end) {\n\t\t\tthis.startDate.set(date);\n\n\t\t\treturn;\n\t\t}\n\n\t\tif (start && !end) {\n\t\t\tif (this._dateAdapter.isAfter(date, start)) {\n\t\t\t\tthis.endDate.set(date);\n\t\t\t} else if (this._dateAdapter.isBefore(date, start)) {\n\t\t\t\tthis.startDate.set(date);\n\t\t\t\tthis.endDate.set(start);\n\t\t\t} else if (this._dateAdapter.isSameDay(date, start)) {\n\t\t\t\tthis.endDate.set(date);\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\n\t\t// If both start and end are selected, reset selection\n\t\tthis.startDate.set(date);\n\n\t\tthis.endDate.set(undefined);\n\t}\n\n\t// same as in brn-calendar.directive.ts\n\t/** @internal Constrain a date to the min and max boundaries */\n\tconstrainDate(date: T): T {\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\t// If there is no min or max, return the date.\n\t\tif (!min && !max) {\n\t\t\treturn date;\n\t\t}\n\n\t\t// If there is a min and the date is before the min, return the min.\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn min;\n\t\t}\n\n\t\t// If there is a max and the date is after the max, return the max.\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn max;\n\t\t}\n\n\t\t// Return the date.\n\t\treturn date;\n\t}\n\n\t/** @internal Determine if a date is disabled */\n\tisDateDisabled(date: T): boolean {\n\t\t// if the calendar is disabled we can't select this date\n\t\tif (this.disabled()) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if the date is outside the min and max range\n\t\tconst min = this.min();\n\t\tconst max = this.max();\n\n\t\tif (min && this._dateAdapter.isBefore(date, this._dateAdapter.startOfDay(min))) {\n\t\t\treturn true;\n\t\t}\n\n\t\tif (max && this._dateAdapter.isAfter(date, this._dateAdapter.endOfDay(max))) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// if this specific date is disabled\n\t\tconst disabledFn = this.dateDisabled();\n\n\t\tif (disabledFn(date)) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}\n\n\t/** @internal Set the focused date */\n\tsetFocusedDate(date: T): void {\n\t\t// check if the date is disabled.\n\t\tif (this.isDateDisabled(date)) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.focusedDate.set(date);\n\n\t\t// wait until the cells have all updated\n\t\tafterNextRender(\n\t\t\t{\n\t\t\t\twrite: () => {\n\t\t\t\t\t// focus the cell with the target date.\n\t\t\t\t\tconst cell = this._cells().find((c) => this._dateAdapter.isSameDay(c.date(), date));\n\n\t\t\t\t\tif (cell) {\n\t\t\t\t\t\tcell.focus();\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tinjector: this._injector,\n\t\t\t},\n\t\t);\n\n\t\t// we must update the view to ensure the focused cell is visible.\n\t\tthis._changeDetector.detectChanges();\n\t}\n\n\t/**\n\t * Determine if a date is the start of a range.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisStartOfRange(date: T): boolean {\n\t\tconst start = this.startDate();\n\t\treturn start ? this._dateAdapter.isSameDay(date, start) : false;\n\t}\n\n\t/**\n\t * Determine if a date is the end of a range.\n\t * @param date The date to check.\n\t * @returns Always false.\n\t * @internal\n\t */\n\tisEndOfRange(date: T): boolean {\n\t\tconst end = this.endDate();\n\t\treturn end ? this._dateAdapter.isSameDay(date, end) : false;\n\t}\n\n\t/**\n\t * Determine if a date is between the start and end dates.\n\t * @param date The date to check.\n\t * @returns True if the date is between the start and end dates, false otherwise.\n\t * @internal\n\t */\n\tisBetweenRange(date: T): boolean {\n\t\tconst start = this.startDate();\n\t\tconst end = this.endDate();\n\n\t\tif (!start || !end) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn this._dateAdapter.isAfter(date, start) && this._dateAdapter.isBefore(date, end);\n\t}\n}\n","import { BrnCalendar } from './lib/brn-calendar';\nimport { BrnCalendarCell } from './lib/brn-calendar-cell';\nimport { BrnCalendarCellButton } from './lib/brn-calendar-cell-button';\nimport { BrnCalendarGrid } from './lib/brn-calendar-grid';\nimport { BrnCalendarHeader } from './lib/brn-calendar-header';\nimport { BrnCalendarMonthSelect } from './lib/brn-calendar-month-select';\nimport { BrnCalendarNextButton } from './lib/brn-calendar-next-button';\nimport { BrnCalendarPreviousButton } from './lib/brn-calendar-previous-button';\nimport { BrnCalendarWeek } from './lib/brn-calendar-week';\nimport { BrnCalendarWeekday } from './lib/brn-calendar-weekday';\nimport { BrnCalendarYearSelect } from './lib/brn-calendar-year-select';\nimport { BrnCalendarMulti } from './lib/mode/brn-calendar-multiple';\nimport { BrnCalendarRange } from './lib/mode/brn-calendar-range';\n\nexport * from './lib/brn-calendar';\nexport * from './lib/brn-calendar-cell';\nexport * from './lib/brn-calendar-cell-button';\nexport * from './lib/brn-calendar-grid';\nexport * from './lib/brn-calendar-header';\nexport * from './lib/brn-calendar-month-select';\nexport * from './lib/brn-calendar-next-button';\nexport * from './lib/brn-calendar-previous-button';\nexport * from './lib/brn-calendar-week';\nexport * from './lib/brn-calendar-weekday';\nexport * from './lib/brn-calendar-year-select';\nexport * from './lib/brn-calendar.token';\nexport * from './lib/i18n/calendar-i18n';\nexport * from './lib/mode/brn-calendar-multiple';\nexport * from './lib/mode/brn-calendar-range';\n\nexport const BrnCalendarImports = [\n\tBrnCalendarCellButton,\n\tBrnCalendarGrid,\n\tBrnCalendarHeader,\n\tBrnCalendarNextButton,\n\tBrnCalendarPreviousButton,\n\tBrnCalendarWeek,\n\tBrnCalendarWeekday,\n\tBrnCalendar,\n\tBrnCalendarCell,\n\tBrnCalendarMulti,\n\tBrnCalendarRange,\n\tBrnCalendarMonthSelect,\n\tBrnCalendarYearSelect,\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;MA4Ba,gBAAgB,GAAG,IAAI,cAAc,CAA2B,kBAAkB;AAEzF,SAAU,kBAAkB,CAAI,QAAkC,EAAA;IACvE,OAAO,EAAE,OAAO,EAAE,gBAAgB,EAAE,WAAW,EAAE,QAAQ,EAAE;AAC5D;AAEA;;AAEG;SACa,iBAAiB,GAAA;AAChC,IAAA,OAAO,MAAM,CAAC,gBAAgB,CAAuB;AACtD;;MCRa,qBAAqB,CAAA;;IAEd,YAAY,GAAG,iBAAiB,EAAK;;IAGrC,SAAS,GAAG,iBAAiB,EAAK;;AAGpC,IAAA,WAAW,GAAG,MAAM,CAAgC,UAAU,CAAC;;AAGhE,IAAA,IAAI,GAAG,KAAK,CAAC,QAAQ,EAAK;;AAG1B,IAAA,QAAQ,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;AAC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A,IAAA,EAAA,QAAA,EAAA,IAAA,EAAA,EAAA,EAAA,YAAA,EAAA,QAAA,EAAA,SAAA,EAGe,qBAAqB,EAAA,WAAA,EAAA,IAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAvC/E,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAJ5B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,QAAQ,EAAE,oBAAoB;AAC9B,oBAAA,SAAS,EAAE,CAAC,kBAAkB,CAAA,gBAAA,CAAkB,CAAC;AACjD,iBAAA;;;ACKM,MAAM,kBAAkB,GAAG;IACjC,qBAAqB;IACrB,eAAe;IACf,iBAAiB;IACjB,qBAAqB;IACrB,yBAAyB;IACzB,eAAe;IACf,kBAAkB;IAClB,WAAW;IACX,eAAe;IACf,gBAAgB;IAChB,gBAAgB;IAChB,sBAAsB;IACtB,qBAAqB;;;AC3CtB;;AAEG;;;;"}
@@ -1,29 +1,41 @@
1
- @plugin "tailwindcss-animate";
1
+ @import '@angular/cdk/overlay-prebuilt.css';
2
+ @import 'tw-animate-css';
3
+
4
+ @custom-variant dark (&:is(.dark *));
2
5
 
3
6
  @theme inline {
4
- --radius-xs: 0.125rem;
5
- --radius-sm: calc(var(--radius) - 4px);
6
- --radius-md: calc(var(--radius) - 2px);
7
- --radius-lg: var(--radius);
8
- --radius-xl: calc(var(--radius) + 4px);
9
- --color-background: var(--background);
10
- --color-foreground: var(--foreground);
11
- --color-card: var(--card);
12
- --color-card-foreground: var(--card-foreground);
13
- --color-popover: var(--popover);
14
- --color-popover-foreground: var(--popover-foreground);
15
- --color-primary: var(--primary);
16
- --color-primary-foreground: var(--primary-foreground);
17
- --color-secondary: var(--secondary);
18
- --color-secondary-foreground: var(--secondary-foreground);
19
- --color-muted: var(--muted);
20
- --color-muted-foreground: var(--muted-foreground);
21
- --color-accent: var(--accent);
22
- --color-accent-foreground: var(--accent-foreground);
23
- --color-destructive: var(--destructive);
24
- --color-border: var(--border);
25
- --color-input: var(--input);
26
- --color-ring: var(--ring);
7
+ --color-background: var(--background);
8
+ --color-foreground: var(--foreground);
9
+ --font-sans: var(--font-sans);
10
+ --font-mono: var(--font-mono);
11
+ --color-sidebar-ring: var(--sidebar-ring);
12
+ --color-sidebar-border: var(--sidebar-border);
13
+ --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
14
+ --color-sidebar-accent: var(--sidebar-accent);
15
+ --color-sidebar-primary-foreground: var(--sidebar-primary-foreground);
16
+ --color-sidebar-primary: var(--sidebar-primary);
17
+ --color-sidebar-foreground: var(--sidebar-foreground);
18
+ --color-sidebar: var(--sidebar);
19
+ --color-ring: var(--ring);
20
+ --color-input: var(--input);
21
+ --color-border: var(--border);
22
+ --color-destructive: var(--destructive);
23
+ --color-accent-foreground: var(--accent-foreground);
24
+ --color-accent: var(--accent);
25
+ --color-muted-foreground: var(--muted-foreground);
26
+ --color-muted: var(--muted);
27
+ --color-secondary-foreground: var(--secondary-foreground);
28
+ --color-secondary: var(--secondary);
29
+ --color-primary-foreground: var(--primary-foreground);
30
+ --color-primary: var(--primary);
31
+ --color-popover-foreground: var(--popover-foreground);
32
+ --color-popover: var(--popover);
33
+ --color-card-foreground: var(--card-foreground);
34
+ --color-card: var(--card);
35
+ --radius-sm: calc(var(--radius) - 4px);
36
+ --radius-md: calc(var(--radius) - 2px);
37
+ --radius-lg: var(--radius);
38
+ --radius-xl: calc(var(--radius) + 4px);
27
39
  --animate-indeterminate: indeterminate 4s ease-in-out infinite;
28
40
  }
29
41
 
@@ -37,6 +49,6 @@
37
49
  }
38
50
 
39
51
  @utility container {
40
- margin-inline: auto;
41
- padding-inline: 2rem;
52
+ margin-inline: auto;
53
+ padding-inline: 2rem;
42
54
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spartan-ng/brain",
3
- "version": "0.0.1-alpha.533",
3
+ "version": "0.0.1-alpha.534",
4
4
  "sideEffects": false,
5
5
  "exports": {
6
6
  "./hlm-tailwind-preset": {
@@ -18,14 +18,14 @@
18
18
  "types": "./accordion/index.d.ts",
19
19
  "default": "./fesm2022/spartan-ng-brain-accordion.mjs"
20
20
  },
21
- "./alert-dialog": {
22
- "types": "./alert-dialog/index.d.ts",
23
- "default": "./fesm2022/spartan-ng-brain-alert-dialog.mjs"
24
- },
25
21
  "./autocomplete": {
26
22
  "types": "./autocomplete/index.d.ts",
27
23
  "default": "./fesm2022/spartan-ng-brain-autocomplete.mjs"
28
24
  },
25
+ "./alert-dialog": {
26
+ "types": "./alert-dialog/index.d.ts",
27
+ "default": "./fesm2022/spartan-ng-brain-alert-dialog.mjs"
28
+ },
29
29
  "./avatar": {
30
30
  "types": "./avatar/index.d.ts",
31
31
  "default": "./fesm2022/spartan-ng-brain-avatar.mjs"
@@ -147,8 +147,7 @@
147
147
  "clsx": ">=2.0.0",
148
148
  "luxon": ">=3.0.0",
149
149
  "rxjs": ">=6.6.0",
150
- "tailwindcss": ">=3.3.0",
151
- "tailwindcss-animate": ">=1.0.7"
150
+ "tailwindcss": ">=3.3.0"
152
151
  },
153
152
  "peerDependenciesMeta": {
154
153
  "luxon": {