@odx/angular 12.4.0 → 12.4.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/cdk/checkbox-control/lib/checkbox-control.directive.d.ts +0 -2
- package/cdk/custom-form-control/lib/custom-form-control.d.ts +3 -1
- package/esm2022/cdk/checkbox-control/lib/checkbox-control.directive.mjs +1 -4
- package/esm2022/cdk/custom-form-control/lib/custom-form-control.mjs +9 -5
- package/esm2022/components/checkbox/lib/checkbox.component.mjs +3 -3
- package/esm2022/components/datepicker/lib/datepicker.component.mjs +2 -2
- package/esm2022/components/daterangepicker/lib/daterangepicker.component.mjs +3 -5
- package/esm2022/components/form-field/lib/components/form-field-info/form-field-info.component.mjs +2 -3
- package/esm2022/components/form-field/lib/form-field.component.mjs +3 -3
- package/esm2022/components/form-field/lib/form-field.service.mjs +3 -2
- package/esm2022/components/switch/lib/switch.component.mjs +3 -3
- package/fesm2022/odx-angular-breakpoints.mjs +1 -1
- package/fesm2022/odx-angular-cdk-a11y.mjs +1 -1
- package/fesm2022/odx-angular-cdk-active-indicator.mjs +1 -1
- package/fesm2022/odx-angular-cdk-autocomplete-control.mjs +1 -1
- package/fesm2022/odx-angular-cdk-checkbox-control.mjs +1 -4
- package/fesm2022/odx-angular-cdk-checkbox-control.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-connected-overlay.mjs +1 -1
- package/fesm2022/odx-angular-cdk-custom-form-control.mjs +8 -4
- package/fesm2022/odx-angular-cdk-custom-form-control.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-dynamic-view.mjs +1 -1
- package/fesm2022/odx-angular-cdk-expandable.mjs +1 -1
- package/fesm2022/odx-angular-cdk-option-control.mjs +1 -1
- package/fesm2022/odx-angular-cdk-radio-group-control.mjs +1 -1
- package/fesm2022/odx-angular-components-accordion.mjs +1 -1
- package/fesm2022/odx-angular-components-action-group.mjs +1 -1
- package/fesm2022/odx-angular-components-area-header.mjs +1 -1
- package/fesm2022/odx-angular-components-autocomplete.mjs +1 -1
- package/fesm2022/odx-angular-components-avatar.mjs +1 -1
- package/fesm2022/odx-angular-components-badge.mjs +1 -1
- package/fesm2022/odx-angular-components-bar.mjs +1 -1
- package/fesm2022/odx-angular-components-breadcrumbs.mjs +1 -1
- package/fesm2022/odx-angular-components-button-group.mjs +1 -1
- package/fesm2022/odx-angular-components-button.mjs +1 -1
- package/fesm2022/odx-angular-components-calendar.mjs +2 -2
- package/fesm2022/odx-angular-components-card.mjs +2 -2
- package/fesm2022/odx-angular-components-checkbox.mjs +3 -3
- package/fesm2022/odx-angular-components-checkbox.mjs.map +1 -1
- package/fesm2022/odx-angular-components-chip.mjs +1 -1
- package/fesm2022/odx-angular-components-circular-progress.mjs +1 -1
- package/fesm2022/odx-angular-components-content-box.mjs +1 -1
- package/fesm2022/odx-angular-components-datepicker.mjs +3 -3
- package/fesm2022/odx-angular-components-datepicker.mjs.map +1 -1
- package/fesm2022/odx-angular-components-daterangepicker.mjs +5 -7
- package/fesm2022/odx-angular-components-daterangepicker.mjs.map +1 -1
- package/fesm2022/odx-angular-components-dropdown.mjs +1 -1
- package/fesm2022/odx-angular-components-error-page.mjs +1 -1
- package/fesm2022/odx-angular-components-footer.mjs +2 -2
- package/fesm2022/odx-angular-components-form-field.mjs +77 -76
- package/fesm2022/odx-angular-components-form-field.mjs.map +1 -1
- package/fesm2022/odx-angular-components-header-navigation.mjs +1 -1
- package/fesm2022/odx-angular-components-header.mjs +1 -1
- package/fesm2022/odx-angular-components-icon.mjs +1 -1
- package/fesm2022/odx-angular-components-inline-message.mjs +1 -1
- package/fesm2022/odx-angular-components-list.mjs +2 -2
- package/fesm2022/odx-angular-components-loading-spinner.mjs +1 -1
- package/fesm2022/odx-angular-components-logo.mjs +1 -1
- package/fesm2022/odx-angular-components-main-menu.mjs +2 -2
- package/fesm2022/odx-angular-components-mainfilter-group.mjs +1 -1
- package/fesm2022/odx-angular-components-menu.mjs +1 -1
- package/fesm2022/odx-angular-components-modal.mjs +1 -1
- package/fesm2022/odx-angular-components-navigation-back.mjs +1 -1
- package/fesm2022/odx-angular-components-notification.mjs +3 -3
- package/fesm2022/odx-angular-components-paginator.mjs +1 -1
- package/fesm2022/odx-angular-components-progress.mjs +1 -1
- package/fesm2022/odx-angular-components-radio-group.mjs +1 -1
- package/fesm2022/odx-angular-components-rail-navigation.mjs +1 -1
- package/fesm2022/odx-angular-components-rich-list.mjs +1 -1
- package/fesm2022/odx-angular-components-select.mjs +1 -1
- package/fesm2022/odx-angular-components-slider.mjs +1 -1
- package/fesm2022/odx-angular-components-spinbox.mjs +1 -1
- package/fesm2022/odx-angular-components-switch.mjs +3 -3
- package/fesm2022/odx-angular-components-switch.mjs.map +1 -1
- package/fesm2022/odx-angular-components-tab-bar.mjs +1 -1
- package/fesm2022/odx-angular-components-table.mjs +1 -1
- package/fesm2022/odx-angular-components-timepicker.mjs +2 -2
- package/fesm2022/odx-angular-components-toast.mjs +1 -1
- package/fesm2022/odx-angular-components-toggle-button-group.mjs +1 -1
- package/fesm2022/odx-angular-components-tooltip.mjs +1 -1
- package/fesm2022/odx-angular-components-wizard.mjs +1 -1
- package/fesm2022/odx-angular.mjs +2 -2
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __decorate, __metadata } from 'tslib';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import {
|
|
3
|
+
import { ViewEncapsulation, ChangeDetectionStrategy, Component, HostBinding, Input, inject, EventEmitter, ElementRef, Output, ContentChild, ViewChild, Directive, NgModule } from '@angular/core';
|
|
4
4
|
import * as i1 from '@odx/angular/cdk/a11y';
|
|
5
5
|
import { InteractiveDirective, A11yModule } from '@odx/angular/cdk/a11y';
|
|
6
6
|
import { ActionGroupComponent } from '@odx/angular/components/action-group';
|
|
@@ -8,7 +8,7 @@ import { ButtonComponent } from '@odx/angular/components/button';
|
|
|
8
8
|
import { ChipListRowComponent } from '@odx/angular/components/chip';
|
|
9
9
|
import { IconComponent } from '@odx/angular/components/icon';
|
|
10
10
|
import * as i3 from '@odx/angular/components/menu';
|
|
11
|
-
import {
|
|
11
|
+
import { MenuModule, MenuDirective, MenuComponent } from '@odx/angular/components/menu';
|
|
12
12
|
import { CSSComponent, CSSModifier } from '@odx/angular/internal';
|
|
13
13
|
import { createConfigTokens, injectElement, untilDestroyed, containsElement } from '@odx/angular/utils';
|
|
14
14
|
import * as i2 from '@angular/common';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __decorate, __metadata } from 'tslib';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { EventEmitter, booleanAttribute,
|
|
3
|
+
import { EventEmitter, booleanAttribute, Output, Input, ViewEncapsulation, ChangeDetectionStrategy, Component, forwardRef, Directive, NgModule } from '@angular/core';
|
|
4
4
|
import * as i1 from '@odx/angular';
|
|
5
5
|
import { ReadonlyController, WithDisabledState, CoreModule } from '@odx/angular';
|
|
6
6
|
import { CheckBoxControl } from '@odx/angular/cdk/checkbox-control';
|
|
@@ -76,7 +76,7 @@ let CheckboxComponent = class CheckboxComponent extends CheckBoxControl {
|
|
|
76
76
|
this.checkedChange.next(this.checked);
|
|
77
77
|
}
|
|
78
78
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: CheckboxComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
79
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.13", type: CheckboxComponent, isStandalone: true, selector: "odx-checkbox", inputs: { indeterminate: ["indeterminate", "indeterminate", booleanAttribute] }, outputs: { indeterminateChange: "indeterminateChange" }, host: { properties: { "class.is-active": "checked || indeterminate" } }, providers: [ReadonlyController.connect()], usesInheritance: true, hostDirectives: [{ directive: i1.WithDisabledState }], ngImport: i0, template: "<label class=\"odx-checkbox__label\">\n <input\n odxControl\n class=\"odx-checkbox__input\"\n [attr.aria-checked]=\"ariaChecked\"\n [attr.aria-invalid]=\"hasError || null\"\n [attr.aria-readonly]=\"isReadonly || null\"\n [attr.aria-required]=\"isRequired || null\"\n [attr.tabindex]=\"tabindex || null\"\n [checked]=\"checked\"\n [disabled]=\"isDisabled || isReadonly\"\n [indeterminate]=\"indeterminate\"\n [name]=\"name\"\n [readonly]=\"isReadonly\"\n [value]=\"value\"\n type=\"checkbox\"\n (blur)=\"onTouched()\"\n (change)=\"onChanged($event)\"\n />\n <div class=\"odx-checkbox__indicator\">\n <odx-icon [name]=\"modifierIcon\" iconSet=\"core\" />\n </div>\n <div class=\"odx-checkbox__content\">\n <div class=\"odx-checkbox__title\">\n <ng-content />\n @if (
|
|
79
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.13", type: CheckboxComponent, isStandalone: true, selector: "odx-checkbox", inputs: { indeterminate: ["indeterminate", "indeterminate", booleanAttribute] }, outputs: { indeterminateChange: "indeterminateChange" }, host: { properties: { "class.is-active": "checked || indeterminate" } }, providers: [ReadonlyController.connect()], usesInheritance: true, hostDirectives: [{ directive: i1.WithDisabledState }], ngImport: i0, template: "<label class=\"odx-checkbox__label\">\n <input\n odxControl\n class=\"odx-checkbox__input\"\n [attr.aria-checked]=\"ariaChecked\"\n [attr.aria-invalid]=\"hasError || null\"\n [attr.aria-readonly]=\"isReadonly || null\"\n [attr.aria-required]=\"isRequired || null\"\n [attr.tabindex]=\"tabindex || null\"\n [checked]=\"checked\"\n [disabled]=\"isDisabled || isReadonly\"\n [indeterminate]=\"indeterminate\"\n [name]=\"name\"\n [readonly]=\"isReadonly\"\n [value]=\"value\"\n type=\"checkbox\"\n (blur)=\"onTouched()\"\n (change)=\"onChanged($event)\"\n />\n <div class=\"odx-checkbox__indicator\">\n <odx-icon [name]=\"modifierIcon\" iconSet=\"core\" />\n </div>\n <div class=\"odx-checkbox__content\">\n <div class=\"odx-checkbox__title\">\n <ng-content />\n @if (isRequired) {\n <span class=\"odx-checkbox__required\">*</span>\n }\n </div>\n <ng-content select=\".odx-checkbox__subtitle\" />\n </div>\n</label>\n", dependencies: [{ kind: "component", type: IconComponent, selector: "odx-icon", inputs: ["inline", "size", "name", "iconSet", "identifier"] }, { kind: "directive", type: ControlDirective, selector: "[odxControl]", exportAs: ["odxControl"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
80
80
|
};
|
|
81
81
|
__decorate([
|
|
82
82
|
CSSModifier(),
|
|
@@ -90,7 +90,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
90
90
|
type: Component,
|
|
91
91
|
args: [{ standalone: true, selector: 'odx-checkbox', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [IconComponent, ControlDirective], providers: [ReadonlyController.connect()], hostDirectives: [WithDisabledState], host: {
|
|
92
92
|
'[class.is-active]': 'checked || indeterminate',
|
|
93
|
-
}, template: "<label class=\"odx-checkbox__label\">\n <input\n odxControl\n class=\"odx-checkbox__input\"\n [attr.aria-checked]=\"ariaChecked\"\n [attr.aria-invalid]=\"hasError || null\"\n [attr.aria-readonly]=\"isReadonly || null\"\n [attr.aria-required]=\"isRequired || null\"\n [attr.tabindex]=\"tabindex || null\"\n [checked]=\"checked\"\n [disabled]=\"isDisabled || isReadonly\"\n [indeterminate]=\"indeterminate\"\n [name]=\"name\"\n [readonly]=\"isReadonly\"\n [value]=\"value\"\n type=\"checkbox\"\n (blur)=\"onTouched()\"\n (change)=\"onChanged($event)\"\n />\n <div class=\"odx-checkbox__indicator\">\n <odx-icon [name]=\"modifierIcon\" iconSet=\"core\" />\n </div>\n <div class=\"odx-checkbox__content\">\n <div class=\"odx-checkbox__title\">\n <ng-content />\n @if (
|
|
93
|
+
}, template: "<label class=\"odx-checkbox__label\">\n <input\n odxControl\n class=\"odx-checkbox__input\"\n [attr.aria-checked]=\"ariaChecked\"\n [attr.aria-invalid]=\"hasError || null\"\n [attr.aria-readonly]=\"isReadonly || null\"\n [attr.aria-required]=\"isRequired || null\"\n [attr.tabindex]=\"tabindex || null\"\n [checked]=\"checked\"\n [disabled]=\"isDisabled || isReadonly\"\n [indeterminate]=\"indeterminate\"\n [name]=\"name\"\n [readonly]=\"isReadonly\"\n [value]=\"value\"\n type=\"checkbox\"\n (blur)=\"onTouched()\"\n (change)=\"onChanged($event)\"\n />\n <div class=\"odx-checkbox__indicator\">\n <odx-icon [name]=\"modifierIcon\" iconSet=\"core\" />\n </div>\n <div class=\"odx-checkbox__content\">\n <div class=\"odx-checkbox__title\">\n <ng-content />\n @if (isRequired) {\n <span class=\"odx-checkbox__required\">*</span>\n }\n </div>\n <ng-content select=\".odx-checkbox__subtitle\" />\n </div>\n</label>\n" }]
|
|
94
94
|
}], propDecorators: { indeterminate: [{
|
|
95
95
|
type: Input,
|
|
96
96
|
args: [{ transform: booleanAttribute }]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odx-angular-components-checkbox.mjs","sources":["../../../../libs/angular/components/checkbox/src/lib/checkbox.component.ts","../../../../libs/angular/components/checkbox/src/lib/checkbox.component.html","../../../../libs/angular/components/checkbox/src/lib/checkbox.validator.ts","../../../../libs/angular/components/checkbox/src/lib/checkbox.module.ts","../../../../libs/angular/components/checkbox/src/odx-angular-components-checkbox.ts"],"sourcesContent":["import { booleanAttribute, ChangeDetectionStrategy, Component, EventEmitter, Input, Output, ViewEncapsulation } from '@angular/core';\nimport { ReadonlyController, WithDisabledState } from '@odx/angular';\nimport { CheckBoxControl } from '@odx/angular/cdk/checkbox-control';\nimport { ControlDirective } from '@odx/angular/cdk/custom-form-control';\nimport { IconComponent } from '@odx/angular/components/icon';\nimport { CSSComponent, CSSModifier } from '@odx/angular/internal';\n\n/**\n * Represents a checkbox component.\n * @extends {CheckBoxControl}\n *\n * @remarks\n * To add subtitle text to the checkbox, use class `odx-checkbox__subtitle` in template's content.\n *\n * @example\n * ```html\n * <odx-checkbox [(checked)]=\"isChecked\">\n * Checkbox label\n * <span class=\"odx-checkbox__subtitle\">Subtitle text</span>\n * </odx-checkbox>\n * ```\n */\n@CSSComponent('checkbox')\n@Component({\n standalone: true,\n selector: 'odx-checkbox',\n templateUrl: 'checkbox.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n imports: [IconComponent, ControlDirective],\n providers: [ReadonlyController.connect()],\n hostDirectives: [WithDisabledState],\n host: {\n '[class.is-active]': 'checked || indeterminate',\n },\n})\nexport class CheckboxComponent extends CheckBoxControl {\n private isIndeterminate = false;\n\n /**\n * Gets or sets a value indicating whether the checkbox is in an indeterminate state.\n *\n * @type {boolean}\n *\n * @remarks\n * The indeterminate state is typically used when the checkbox represents a group of checkboxes\n * and not all of them are checked or unchecked.\n */\n @CSSModifier()\n @Input({ transform: booleanAttribute })\n public set indeterminate(value: boolean) {\n if (this.isIndeterminate !== value) {\n this.isIndeterminate = value;\n this.indeterminateChange.emit(this.isIndeterminate);\n }\n }\n\n public get indeterminate(): boolean {\n return this.isIndeterminate;\n }\n\n /**\n * Emits a boolean value when the indeterminate state of the checkbox changes.\n *\n * @emits {boolean} The new value of the indeterminate state.\n */\n @Output()\n public readonly indeterminateChange = new EventEmitter<boolean>();\n\n /**\n * Gets the value of the `ariaChecked` attribute.\n *\n * @returns {string} - The value of the `ariaChecked` attribute as a string.\n */\n public override get ariaChecked(): string {\n return this.checked ? 'true' : this.indeterminate ? 'mixed' : 'false';\n }\n\n /**\n * Gets the modifier icon for the checkbox component.\n *\n * @returns {string} 'minus' if the checkbox is in indeterminate state, otherwise returns 'check'.\n */\n public get modifierIcon(): string {\n return this.indeterminate ? 'minus' : 'check';\n }\n\n public override onChanged(event: Event): void {\n event.stopPropagation();\n this.indeterminate = false;\n super.updateValue((event.target as HTMLInputElement).checked);\n this.checkedChange.next(this.checked);\n }\n}\n","<label class=\"odx-checkbox__label\">\n <input\n odxControl\n class=\"odx-checkbox__input\"\n [attr.aria-checked]=\"ariaChecked\"\n [attr.aria-invalid]=\"hasError || null\"\n [attr.aria-readonly]=\"isReadonly || null\"\n [attr.aria-required]=\"isRequired || null\"\n [attr.tabindex]=\"tabindex || null\"\n [checked]=\"checked\"\n [disabled]=\"isDisabled || isReadonly\"\n [indeterminate]=\"indeterminate\"\n [name]=\"name\"\n [readonly]=\"isReadonly\"\n [value]=\"value\"\n type=\"checkbox\"\n (blur)=\"onTouched()\"\n (change)=\"onChanged($event)\"\n />\n <div class=\"odx-checkbox__indicator\">\n <odx-icon [name]=\"modifierIcon\" iconSet=\"core\" />\n </div>\n <div class=\"odx-checkbox__content\">\n <div class=\"odx-checkbox__title\">\n <ng-content />\n @if (requiredGetter) {\n <span class=\"odx-checkbox__required\">*</span>\n }\n </div>\n <ng-content select=\".odx-checkbox__subtitle\" />\n </div>\n</label>\n","import { Directive, forwardRef } from '@angular/core';\nimport { CheckboxRequiredValidator, NG_VALIDATORS } from '@angular/forms';\n\n/**\n * A directive that extends Angular's `CheckboxRequiredValidator` for use with `odx-checkbox` components,\n * enforcing required validation. This directive ensures that an `odx-checkbox` marked as required\n * is checked in order to be considered valid within a form.\n *\n * The directive is automatically applied to `odx-checkbox` elements that have the `required` attribute\n * along with either `formControlName`, `formControl`, or `ngModel` directives, making it integrate seamlessly\n * with both reactive and template-driven forms.\n *\n * @example\n * ```html\n * <!-- In a reactive form -->\n * <odx-checkbox formControlName=\"acceptTerms\" required />\n *\n * <!-- In a template-driven form -->\n * <odx-checkbox [(ngModel)]=\"acceptTerms\" name=\"acceptTerms\" required />\n * ```\n *\n * By using this directive, forms containing `odx-checkbox` components with the required validation\n * will ensure the checkbox is checked before considering the form valid.\n *\n * @extends {CheckboxRequiredValidator} Inherits the behavior of Angular's `CheckboxRequiredValidator`.\n */\n@Directive({\n standalone: true,\n selector: 'odx-checkbox[required][formControlName], odx-checkbox[required][formControl], odx-checkbox[required][ngModel]',\n providers: [\n {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => CheckboxValidator),\n multi: true,\n },\n ],\n})\nexport class CheckboxValidator extends CheckboxRequiredValidator {}\n","import { NgModule } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { CheckboxComponent } from './checkbox.component';\nimport { CheckboxValidator } from './checkbox.validator';\n\nconst modules = [CheckboxComponent, CheckboxValidator];\n\n@NgModule({\n imports: modules,\n exports: [CoreModule, ...modules],\n})\nexport class CheckboxModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;AAOA;;;;;;;;;;;;;;AAcG;AAeI,IAAM,iBAAiB,GAAvB,MAAM,iBAAkB,SAAQ,eAAe,CAAA;AAA/C,IAAA,WAAA,GAAA;;QACG,IAAe,CAAA,eAAA,GAAG,KAAK;AAwB/B;;;;AAIG;AAEa,QAAA,IAAA,CAAA,mBAAmB,GAAG,IAAI,YAAY,EAAW;AA0BlE;AAtDC;;;;;;;;AAQG;IACH,IAEW,aAAa,CAAC,KAAc,EAAA;AACrC,QAAA,IAAI,IAAI,CAAC,eAAe,KAAK,KAAK,EAAE;AAClC,YAAA,IAAI,CAAC,eAAe,GAAG,KAAK;YAC5B,IAAI,CAAC,mBAAmB,CAAC,IAAI,CAAC,IAAI,CAAC,eAAe,CAAC;;;AAIvD,IAAA,IAAW,aAAa,GAAA;QACtB,OAAO,IAAI,CAAC,eAAe;;AAW7B;;;;AAIG;AACH,IAAA,IAAoB,WAAW,GAAA;QAC7B,OAAO,IAAI,CAAC,OAAO,GAAG,MAAM,GAAG,IAAI,CAAC,aAAa,GAAG,OAAO,GAAG,OAAO;;AAGvE;;;;AAIG;AACH,IAAA,IAAW,YAAY,GAAA;QACrB,OAAO,IAAI,CAAC,aAAa,GAAG,OAAO,GAAG,OAAO;;AAG/B,IAAA,SAAS,CAAC,KAAY,EAAA;QACpC,KAAK,CAAC,eAAe,EAAE;AACvB,QAAA,IAAI,CAAC,aAAa,GAAG,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A,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAEU,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAX7B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,UAAU,EAAE,IAAI;AAChB,oBAAA,QAAQ,EAAE,+GAA+G;AACzH,oBAAA,SAAS,EAAE;AACT,wBAAA;AACE,4BAAA,OAAO,EAAE,aAAa;AACtB,4BAAA,WAAW,EAAE,UAAU,CAAC,uBAAuB,CAAC;AAChD,4BAAA,KAAK,EAAE,IAAI;AACZ,yBAAA;AACF,qBAAA;AACF,iBAAA;;;AC/BD,MAAM,OAAO,GAAG,CAAC,iBAAiB,EAAE,iBAAiB,CAAC;MAMzC,cAAc,CAAA;+GAAd,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;gHAAd,cAAc,EAAA,OAAA,EAAA,CANV,iBAAiB,EAAE,iBAAiB,aAIzC,UAAU,EAJL,iBAAiB,EAAE,iBAAiB,CAAA,EAAA,CAAA,CAAA;gHAMxC,cAAc,EAAA,OAAA,EAAA,CANV,iBAAiB,EAItB,UAAU,CAAA,EAAA,CAAA,CAAA;;4FAET,cAAc,EAAA,UAAA,EAAA,CAAA;kBAJ1B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,OAAO;AAChB,oBAAA,OAAO,EAAE,CAAC,UAAU,EAAE,GAAG,OAAO,CAAC;AAClC,iBAAA;;;ACVD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"odx-angular-components-checkbox.mjs","sources":["../../../../libs/angular/components/checkbox/src/lib/checkbox.component.ts","../../../../libs/angular/components/checkbox/src/lib/checkbox.component.html","../../../../libs/angular/components/checkbox/src/lib/checkbox.validator.ts","../../../../libs/angular/components/checkbox/src/lib/checkbox.module.ts","../../../../libs/angular/components/checkbox/src/odx-angular-components-checkbox.ts"],"sourcesContent":["import { booleanAttribute, ChangeDetectionStrategy, Component, EventEmitter, Input, Output, ViewEncapsulation } from '@angular/core';\nimport { ReadonlyController, WithDisabledState } from '@odx/angular';\nimport { CheckBoxControl } from '@odx/angular/cdk/checkbox-control';\nimport { ControlDirective } from '@odx/angular/cdk/custom-form-control';\nimport { IconComponent } from '@odx/angular/components/icon';\nimport { CSSComponent, CSSModifier } from '@odx/angular/internal';\n\n/**\n * Represents a checkbox component.\n * @extends {CheckBoxControl}\n *\n * @remarks\n * To add subtitle text to the checkbox, use class `odx-checkbox__subtitle` in template's content.\n *\n * @example\n * ```html\n * <odx-checkbox [(checked)]=\"isChecked\">\n * Checkbox label\n * <span class=\"odx-checkbox__subtitle\">Subtitle text</span>\n * </odx-checkbox>\n * ```\n */\n@CSSComponent('checkbox')\n@Component({\n standalone: true,\n selector: 'odx-checkbox',\n templateUrl: 'checkbox.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n imports: [IconComponent, ControlDirective],\n providers: [ReadonlyController.connect()],\n hostDirectives: [WithDisabledState],\n host: {\n '[class.is-active]': 'checked || indeterminate',\n },\n})\nexport class CheckboxComponent extends CheckBoxControl {\n private isIndeterminate = false;\n\n /**\n * Gets or sets a value indicating whether the checkbox is in an indeterminate state.\n *\n * @type {boolean}\n *\n * @remarks\n * The indeterminate state is typically used when the checkbox represents a group of checkboxes\n * and not all of them are checked or unchecked.\n */\n @CSSModifier()\n @Input({ transform: booleanAttribute })\n public set indeterminate(value: boolean) {\n if (this.isIndeterminate !== value) {\n this.isIndeterminate = value;\n this.indeterminateChange.emit(this.isIndeterminate);\n }\n }\n\n public get indeterminate(): boolean {\n return this.isIndeterminate;\n }\n\n /**\n * Emits a boolean value when the indeterminate state of the checkbox changes.\n *\n * @emits {boolean} The new value of the indeterminate state.\n */\n @Output()\n public readonly indeterminateChange = new EventEmitter<boolean>();\n\n /**\n * Gets the value of the `ariaChecked` attribute.\n *\n * @returns {string} - The value of the `ariaChecked` attribute as a string.\n */\n public override get ariaChecked(): string {\n return this.checked ? 'true' : this.indeterminate ? 'mixed' : 'false';\n }\n\n /**\n * Gets the modifier icon for the checkbox component.\n *\n * @returns {string} 'minus' if the checkbox is in indeterminate state, otherwise returns 'check'.\n */\n public get modifierIcon(): string {\n return this.indeterminate ? 'minus' : 'check';\n }\n\n public override onChanged(event: Event): void {\n event.stopPropagation();\n this.indeterminate = false;\n super.updateValue((event.target as HTMLInputElement).checked);\n this.checkedChange.next(this.checked);\n }\n}\n","<label class=\"odx-checkbox__label\">\n <input\n odxControl\n class=\"odx-checkbox__input\"\n [attr.aria-checked]=\"ariaChecked\"\n [attr.aria-invalid]=\"hasError || null\"\n [attr.aria-readonly]=\"isReadonly || null\"\n [attr.aria-required]=\"isRequired || null\"\n [attr.tabindex]=\"tabindex || null\"\n [checked]=\"checked\"\n [disabled]=\"isDisabled || isReadonly\"\n [indeterminate]=\"indeterminate\"\n [name]=\"name\"\n [readonly]=\"isReadonly\"\n [value]=\"value\"\n type=\"checkbox\"\n (blur)=\"onTouched()\"\n (change)=\"onChanged($event)\"\n />\n <div class=\"odx-checkbox__indicator\">\n <odx-icon [name]=\"modifierIcon\" iconSet=\"core\" />\n </div>\n <div class=\"odx-checkbox__content\">\n <div class=\"odx-checkbox__title\">\n <ng-content />\n @if (isRequired) {\n <span class=\"odx-checkbox__required\">*</span>\n }\n </div>\n <ng-content select=\".odx-checkbox__subtitle\" />\n </div>\n</label>\n","import { Directive, forwardRef } from '@angular/core';\nimport { CheckboxRequiredValidator, NG_VALIDATORS } from '@angular/forms';\n\n/**\n * A directive that extends Angular's `CheckboxRequiredValidator` for use with `odx-checkbox` components,\n * enforcing required validation. This directive ensures that an `odx-checkbox` marked as required\n * is checked in order to be considered valid within a form.\n *\n * The directive is automatically applied to `odx-checkbox` elements that have the `required` attribute\n * along with either `formControlName`, `formControl`, or `ngModel` directives, making it integrate seamlessly\n * with both reactive and template-driven forms.\n *\n * @example\n * ```html\n * <!-- In a reactive form -->\n * <odx-checkbox formControlName=\"acceptTerms\" required />\n *\n * <!-- In a template-driven form -->\n * <odx-checkbox [(ngModel)]=\"acceptTerms\" name=\"acceptTerms\" required />\n * ```\n *\n * By using this directive, forms containing `odx-checkbox` components with the required validation\n * will ensure the checkbox is checked before considering the form valid.\n *\n * @extends {CheckboxRequiredValidator} Inherits the behavior of Angular's `CheckboxRequiredValidator`.\n */\n@Directive({\n standalone: true,\n selector: 'odx-checkbox[required][formControlName], odx-checkbox[required][formControl], odx-checkbox[required][ngModel]',\n providers: [\n {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => CheckboxValidator),\n multi: true,\n },\n ],\n})\nexport class CheckboxValidator extends CheckboxRequiredValidator {}\n","import { NgModule } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { CheckboxComponent } from './checkbox.component';\nimport { CheckboxValidator } from './checkbox.validator';\n\nconst modules = [CheckboxComponent, CheckboxValidator];\n\n@NgModule({\n imports: modules,\n exports: [CoreModule, ...modules],\n})\nexport class CheckboxModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;AAOA;;;;;;;;;;;;;;AAcG;AAeI,IAAM,iBAAiB,GAAvB,MAAM,iBAAkB,SAAQ,eAAe,CAAA;AAA/C,IAAA,WAAA,GAAA;;QACG,IAAe,CAAA,eAAA,GAAG,KAAK;AAwB/B;;;;AAIG;AAEa,QAAA,IAAA,CAAA,mBAAmB,GAAG,IAAI,YAAY,EAAW;AA0BlE;AAtDC;;;;;;;;AAQG;IACH,IAEW,aAAa,CAAC,KAAc,EAAA;AACrC,QAAA,IAAI,IAAI,CAAC,eAAe,KAAK,KAAK,EAAE;AAClC,YAAA,IAAI,CAAC,eAAe,GAAG,KAAK;YAC5B,IAAI,CAAC,mBAAmB,CAAC,IAAI,CAAC,IAAI,CAAC,eAAe,CAAC;;;AAIvD,IAAA,IAAW,aAAa,GAAA;QACtB,OAAO,IAAI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EAAE,OAAO;AAChB,oBAAA,OAAO,EAAE,CAAC,UAAU,EAAE,GAAG,OAAO,CAAC;AAClC,iBAAA;;;ACVD;;AAEG;;;;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __decorate, __metadata } from 'tslib';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import {
|
|
3
|
+
import { ChangeDetectionStrategy, ViewEncapsulation, Component, EventEmitter, booleanAttribute, Output, Input } from '@angular/core';
|
|
4
4
|
import { CSSComponent, CSSModifier } from '@odx/angular/internal';
|
|
5
5
|
import { injectElement } from '@odx/angular/utils';
|
|
6
6
|
import { CoreModule } from '@odx/angular';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __decorate, __metadata } from 'tslib';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { inject, ChangeDetectorRef, numberAttribute,
|
|
3
|
+
import { inject, ChangeDetectorRef, numberAttribute, Input, ViewEncapsulation, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
4
4
|
import { CSSModifier, CSSComponent } from '@odx/angular/internal';
|
|
5
5
|
import { fromElementResize$ } from '@odx/angular/rxjs';
|
|
6
6
|
import { untilDestroyed, injectElement, hasChanged } from '@odx/angular/utils';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import {
|
|
2
|
+
import { ChangeDetectionStrategy, ViewEncapsulation, Component, Directive, NgModule } from '@angular/core';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Represents a content box component.
|
|
@@ -2,7 +2,7 @@ import { __decorate, __metadata } from 'tslib';
|
|
|
2
2
|
import * as i1$1 from '@angular/cdk/a11y';
|
|
3
3
|
import { A11yModule } from '@angular/cdk/a11y';
|
|
4
4
|
import * as i0 from '@angular/core';
|
|
5
|
-
import { inject, EventEmitter,
|
|
5
|
+
import { inject, EventEmitter, HostListener, Output, Directive, input, booleanAttribute, ElementRef, ContentChild, ViewChild, Input, ViewEncapsulation, ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
|
|
6
6
|
import * as i1 from '@odx/angular';
|
|
7
7
|
import { ReadonlyController, WithTabIndex, detectControllerChanges, CoreModule } from '@odx/angular';
|
|
8
8
|
import { InputControlDirective, CustomFormControl } from '@odx/angular/cdk/custom-form-control';
|
|
@@ -10,7 +10,7 @@ import { ActionGroupComponent } from '@odx/angular/components/action-group';
|
|
|
10
10
|
import { ButtonComponent } from '@odx/angular/components/button';
|
|
11
11
|
import { CalendarComponent } from '@odx/angular/components/calendar';
|
|
12
12
|
import * as i2 from '@odx/angular/components/dropdown';
|
|
13
|
-
import {
|
|
13
|
+
import { DropdownModule, DropdownDirective } from '@odx/angular/components/dropdown';
|
|
14
14
|
import { IconComponent } from '@odx/angular/components/icon';
|
|
15
15
|
import { CSSComponent } from '@odx/angular/internal';
|
|
16
16
|
import { createConfigTokens, untilDestroyed, injectElement, deferFn } from '@odx/angular/utils';
|
|
@@ -279,7 +279,7 @@ let DatepickerComponent = class DatepickerComponent extends CustomFormControl {
|
|
|
279
279
|
deferFn(() => {
|
|
280
280
|
if (!this.value)
|
|
281
281
|
return;
|
|
282
|
-
this.
|
|
282
|
+
this.updateDateField(startOfDay(this.value));
|
|
283
283
|
});
|
|
284
284
|
}
|
|
285
285
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odx-angular-components-datepicker.mjs","sources":["../../../../libs/angular/components/datepicker/src/lib/models/datepicker-input-date-order.ts","../../../../libs/angular/components/datepicker/src/lib/models/datepicker-input-pattern.ts","../../../../libs/angular/components/datepicker/src/lib/datepicker.config.ts","../../../../libs/angular/components/datepicker/src/lib/utils/get-datepicker-input-pattern.ts","../../../../libs/angular/components/datepicker/src/lib/utils/get-datepicker-input-value-as-date.ts","../../../../libs/angular/components/datepicker/src/lib/directives/datepicker-input-control.directive.ts","../../../../libs/angular/components/datepicker/src/lib/datepicker.component.ts","../../../../libs/angular/components/datepicker/src/lib/datepicker.component.html","../../../../libs/angular/components/datepicker/src/lib/datepicker.module.ts","../../../../libs/angular/components/datepicker/src/odx-angular-components-datepicker.ts"],"sourcesContent":["export type DatepickerInputDateOrder = (typeof DatepickerInputDateOrder)[keyof typeof DatepickerInputDateOrder];\n\nexport const DatepickerInputDateOrder = {\n DMY: 'DMY',\n MDY: 'MDY',\n YMD: 'YMD',\n};\n","export type DatepickerInputPattern = typeof DatepickerInputFormat | typeof DatepickerInputMask;\n\nexport const DatepickerInputFormat = {\n DAYS: 'dd',\n MONTH: 'MM',\n YEAR: 'yyyy',\n};\n\nexport const DatepickerInputMask = {\n DAYS: 'd0',\n MONTH: 'M0',\n YEAR: '0000',\n};\n","import { createConfigTokens } from '@odx/angular/utils';\nimport { DatepickerInputDateOrder } from './models';\n\nexport interface DatepickerConfig {\n /**\n * Date's order ('DMY' | 'MDY' | 'YMD').\n * @default DatepickerInputDateOrder.DMY\n */\n inputDateOrder: DatepickerInputDateOrder;\n /**\n * Single-character date's separator (dot, slash etc.).\n * @default '.'\n */\n inputDateSeparator: string;\n}\n\n/**\n * Tools for injecting and providing the datepicker configuration with default configuration for the datepicker.\n *\n * @example\n * // Providing custom datepicker configuration.\n * ```ts\n * @Component({\n * providers: [provideDatepickerConfig({ inputDateOrder: DatepickerInputDateOrder.MDY, inputDateSeparator: '/'})]\n * })\n * export class MyComponent {}\n *\n * // Injecting the datepicker configuration.\n * ```ts\n * @Component({})\n * export class MyComponent {\n * constructor(@Inject(injectDatepickerConfig()) private readonly datepickerConfig: DatepickerConfig) {}\n * }\n * ```\n */\nexport const { DatepickerConfig, DatepickerDefaultConfig, injectDatepickerConfig, provideDatepickerConfig } = createConfigTokens(\n 'Datepicker',\n '@odx/angular/components/datepicker',\n {\n inputDateOrder: DatepickerInputDateOrder.DMY,\n inputDateSeparator: '.',\n },\n);\n","import { DatepickerConfig } from '../datepicker.config';\nimport { DatepickerInputDateOrder, DatepickerInputFormat, DatepickerInputMask, DatepickerInputPattern } from '../models';\n\nfunction getDatepickerInputPattern({ inputDateOrder, inputDateSeparator }: DatepickerConfig, pattern: DatepickerInputPattern): string {\n const patternList: Record<DatepickerInputDateOrder, string> = {\n [DatepickerInputDateOrder.DMY]: `${pattern.DAYS}${inputDateSeparator}${pattern.MONTH}${inputDateSeparator}${pattern.YEAR}`,\n [DatepickerInputDateOrder.MDY]: `${pattern.MONTH}${inputDateSeparator}${pattern.DAYS}${inputDateSeparator}${pattern.YEAR}`,\n [DatepickerInputDateOrder.YMD]: `${pattern.YEAR}${inputDateSeparator}${pattern.MONTH}${inputDateSeparator}${pattern.DAYS}`,\n };\n\n return patternList[inputDateOrder];\n}\n\n/** @internal */\nexport function getDatepickerInputFormat(config: DatepickerConfig): string {\n return getDatepickerInputPattern(config, DatepickerInputFormat);\n}\n\n/** @internal */\nexport function getDatepickerInputMask(config: DatepickerConfig): string {\n return getDatepickerInputPattern(config, DatepickerInputMask);\n}\n","import { isValid, toDate } from 'date-fns';\nimport { DatepickerConfig } from '../datepicker.config';\nimport { DatepickerInputDateOrder } from '../models';\n\ninterface DateCandidateInterface {\n month: string;\n day: string;\n year: string;\n}\n\nconst functionList: Record<DatepickerInputDateOrder, (splittedValue: string[]) => DateCandidateInterface> = {\n [DatepickerInputDateOrder.DMY]: (splittedValue: string[]) => {\n const [day, month, year] = splittedValue;\n return { month, day, year };\n },\n [DatepickerInputDateOrder.MDY]: (splittedValue: string[]) => {\n const [month, day, year] = splittedValue;\n return { month, day, year };\n },\n [DatepickerInputDateOrder.YMD]: (splittedValue: string[]) => {\n const [year, month, day] = splittedValue;\n return { month, day, year };\n },\n};\n\nfunction getDateCandidate({ inputDateOrder, inputDateSeparator }: DatepickerConfig, value: string): string | null {\n const splittedValue = value.split(inputDateSeparator);\n\n const { month, day, year }: DateCandidateInterface = functionList[inputDateOrder](splittedValue);\n\n const isDateCandidateInvalid = !month || !day || !year;\n\n return isDateCandidateInvalid ? null : `${month}.${day}.${year}`;\n}\n\n/** @internal */\nexport function getDatepickerInputValueAsDate(config: DatepickerConfig, value: string): Date | null {\n const dateCandidate: string | null = getDateCandidate(config, value);\n\n if (!dateCandidate) return null;\n\n const date = toDate(Date.parse(dateCandidate));\n\n return isValid(date) ? date : null;\n}\n","import { Directive, EventEmitter, HostListener, inject, Output } from '@angular/core';\nimport { ReadonlyController, WithTabIndex } from '@odx/angular';\nimport { InputControlDirective } from '@odx/angular/cdk/custom-form-control';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { NgxMaskConfig, NgxMaskPipe, provideNgxMask } from 'ngx-mask';\nimport { distinctUntilChanged, fromEvent, map, tap } from 'rxjs';\nimport { injectDatepickerConfig } from '../datepicker.config';\nimport { getDatepickerInputFormat, getDatepickerInputMask, getDatepickerInputValueAsDate } from '../utils';\n\n/**\n * A directive to enhance an input element as part of a datepicker control. It applies date input formatting,\n * mask handling, and emits focus events. This directive integrates with ngx-mask to handle input masking and\n * ensures that the input complies with the date format specified in the datepicker configuration.\n * Extends the `InputControlDirective` to provide input control functionality.\n * Has host directive `WithTabIndex` to manage the tabindex attribute of the input element.\n *\n * @see {InputControlDirective}\n * @see {WithTabIndex}\n */\n@CSSComponent('datepicker__control')\n@Directive({\n standalone: true,\n selector: 'input[odxDatepickerControl]',\n host: {\n '[attr.readonly]': 'readonlyController?.readonly || null',\n '[attr.placeholder]': 'placeholder',\n },\n providers: [ReadonlyController.connect(), provideNgxMask(), NgxMaskPipe],\n hostDirectives: [WithTabIndex],\n})\nexport class DatepickerInputControlDirective extends InputControlDirective {\n private readonly maskConfig: Partial<NgxMaskConfig> = { validation: false, leadZeroDateTime: true };\n\n protected readonly readonlyController = ReadonlyController.inject();\n protected readonly config = injectDatepickerConfig();\n protected readonly inputMask = getDatepickerInputMask(this.config);\n protected readonly ngxMaskPipe = inject(NgxMaskPipe);\n\n /**\n * Emits an event when the input field receives focus or loses focus, indicating the focus state.\n *\n * @emits {boolean} - Indicates whether the input field is focused.\n */\n @Output()\n public focused = new EventEmitter<boolean>();\n\n /**\n * Observable stream capturing and processing input events on the native element, applying the mask,\n * and emitting the current value.\n *\n * @emits {string} - The current value of the input field.\n */\n public override valueChange$ = fromEvent(this.element.nativeElement, 'input').pipe(\n distinctUntilChanged(),\n tap(() => this.applyMask()),\n map(() => this.nativeElementValue),\n );\n\n /**\n * Applies the configured input mask to the native element's value.\n */\n public applyMask(): void {\n this.nativeElementValue = this.ngxMaskPipe.transform(this.nativeElementValue, this.inputMask, this.maskConfig);\n }\n\n /**\n * Gets the current value of the input field as a `Date` object, based on the date format from the datepicker\n * configuration.\n *\n * @returns {Date | null} - The current value of the input field as a `Date` object, or `null` if the value is invalid.\n */\n public get valueAsDate(): Date | null {\n return getDatepickerInputValueAsDate(this.config, this.nativeElementValue);\n }\n\n /**\n * Computes the placeholder text for the input based on the date format from\n * the datepicker configuration.\n *\n * @returns {string} - The placeholder text, typically the date format in uppercase.\n */\n public get placeholder(): string {\n return getDatepickerInputFormat(this.config).toUpperCase();\n }\n\n @HostListener('focusin')\n protected handleFocusIn(): void {\n this.focused.emit(true);\n }\n\n @HostListener('focusout')\n protected handleFocusOut(): void {\n this.focused.emit(false);\n }\n}\n","import { A11yModule } from '@angular/cdk/a11y';\nimport {\n AfterViewInit,\n booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n ContentChild,\n ElementRef,\n EventEmitter,\n HostListener,\n input,\n Input,\n Output,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { detectControllerChanges } from '@odx/angular';\nimport { CustomFormControl } from '@odx/angular/cdk/custom-form-control';\nimport { ActionGroupComponent } from '@odx/angular/components/action-group';\nimport { ButtonComponent } from '@odx/angular/components/button';\nimport { CalendarComponent, DateFilter } from '@odx/angular/components/calendar';\nimport { DropdownDirective, DropdownModule } from '@odx/angular/components/dropdown';\nimport { IconComponent } from '@odx/angular/components/icon';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { deferFn, injectElement, Position, untilDestroyed } from '@odx/angular/utils';\nimport { format, startOfDay } from 'date-fns';\nimport { injectDatepickerConfig } from './datepicker.config';\nimport { DatepickerInputControlDirective } from './directives';\nimport { getDatepickerInputFormat } from './utils';\n\n/**\n * Represents a datepicker component for selecting a date.\n * Extends the `CustomFormControl` class and implements the `AfterViewInit` interface.\n *\n * @see {CustomFormControl}\n */\n@CSSComponent('datepicker')\n@Component({\n selector: 'odx-datepicker',\n standalone: true,\n imports: [A11yModule, ActionGroupComponent, ButtonComponent, CalendarComponent, DropdownModule, IconComponent],\n templateUrl: './datepicker.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class DatepickerComponent extends CustomFormControl<Date | null> implements AfterViewInit {\n protected readonly takeUntilDestroyed = untilDestroyed();\n\n protected readonly config = injectDatepickerConfig();\n\n public readonly element = injectElement();\n\n /**\n * Gets a value indicating whether the datepicker is currently open.\n *\n * @returns {boolean}\n */\n public get isOpen(): boolean {\n return !!this.dropdown.isOpen;\n }\n\n /**\n * Represents the current date.\n *\n * @type {Date}\n */\n public today = new Date();\n\n /**\n * The filter function used to determine if a date should be included or excluded in the datepicker.\n * If set to `null`, no filtering will be applied.\n *\n * @type {DateFilter | null}\n * @default null\n *\n * @example\n * ```ts\n * // Excludes mondays from the datepicker.\n * const filterFn: DateFilter = (date) => date.getDay() !== 1;\n * ```\n */\n @Input()\n public filterFn: DateFilter | null = null;\n\n /**\n * The minimum selectable date for the datepicker.\n * If set to null, there is no minimum date restriction.\n *\n * @type {Date | null}\n * @default null\n */\n @Input()\n public minDate: Date | null = null;\n\n /**\n * The maximum selectable date for the datepicker.\n * If set to null, there is no maximum date restriction.\n *\n * @type {Date | null}\n * @default null\n */\n @Input()\n public maxDate: Date | null = null;\n\n /**\n * The position of the dropdown relative to the input field.\n *\n * @type {Position}\n * @default Position.BOTTOM\n */\n @Input()\n public dropdownPosition: Position = 'bottom';\n\n /**\n * When set to true, the select will display a reset button.\n *\n * @type {boolean}\n * @default false\n */\n public clearable = input(false, { transform: booleanAttribute });\n\n /**\n * Emits the selected date when it changes.\n *\n * @emits {Date}\n */\n @Output()\n public selectedChange = new EventEmitter<Date>();\n\n /**\n * The dropdown directive used in the datepicker component.\n *\n * @type {DropdownDirective}\n */\n @ViewChild(DropdownDirective)\n public dropdown!: DropdownDirective;\n\n /**\n * The dropdown trigger element used in the datepicker component.\n *\n * @type {ElementRef<HTMLElement>}\n */\n @ViewChild('dropdownTrigger', { read: ElementRef, static: true })\n public dropdownTriggerElement!: ElementRef<HTMLElement>;\n\n /**\n * The date field input control directive used in the datepicker component.\n *\n * @type {DatepickerInputControlDirective | undefined}\n */\n @ContentChild(DatepickerInputControlDirective)\n public dateField?: DatepickerInputControlDirective;\n\n constructor() {\n super(null);\n detectControllerChanges(this).subscribe();\n }\n\n public ngAfterViewInit(): void {\n this.handleDateFieldChanges();\n this.handleDateFieldFocus();\n\n deferFn(() => {\n if (!this.value) return;\n this.updateInternalValue(startOfDay(this.value));\n });\n }\n\n /**\n * Selects a date.\n *\n * @param {Date | null} value - The date value to be selected.\n */\n public selectDate(value: Date | null): void {\n if (!value) return;\n\n this.updateInternalValue(value);\n\n this.selectedChange.emit(value);\n\n this.dropdown.close();\n }\n\n public reset(): void {\n this.updateInternalValue(null);\n }\n\n protected updateInternalValue(value: Date | null): void {\n this.updateValue(value);\n this.updateDateField(value);\n }\n\n protected handleDateFieldChanges(): void {\n this.dateField?.valueChange$.pipe(this.takeUntilDestroyed()).subscribe(() => this.updateValue(this.dateField?.valueAsDate ?? null));\n }\n\n protected handleDateFieldFocus(): void {\n this.dateField?.focused.pipe(this.takeUntilDestroyed()).subscribe((isFocused) => {\n if (!isFocused) {\n this.onTouched();\n }\n if (this.isOpen) {\n this.dropdown.close();\n }\n });\n }\n\n @HostListener('keydown.alt.ArrowDown', ['$event'])\n protected openDatepicker(event: KeyboardEvent) {\n event.stopPropagation();\n\n if (this.isReadonly || this.isDisabled) return;\n\n this.dropdown.open(event);\n }\n\n private updateDateField(date: Date | null): void {\n if (!this.dateField) return;\n\n const dateFormat = getDatepickerInputFormat(this.config);\n this.dateField.nativeElementValue = date ? format(date, dateFormat) : '';\n }\n}\n","<ng-content select=\"input[odxDatepickerControl]\" />\n\n<odx-action-group class=\"odx-datepicker__trigger-wrapper\">\n @if (clearable() && value) {\n <button odxButton class=\"odx-datepicker__clear\" (click)=\"reset()\" size=\"small\" aria-label=\"Reset time\">\n <odx-icon name=\"close\" iconSet=\"core\" />\n </button>\n }\n <button\n #dropdownTrigger\n odxButton\n size=\"small\"\n variant=\"ghost\"\n class=\"odx-datepicker__trigger\"\n [odxDropdown]=\"calendarOverlay\"\n [odxDropdownOptions]=\"{ position: dropdownPosition }\"\n [odxDropdownTriggerElement]=\"dropdownTriggerElement.nativeElement\"\n [odxDropdownHost]=\"null\"\n [odxDropdownReferenceElement]=\"element.nativeElement\"\n (odxDropdownBeforeClose)=\"onTouched()\"\n >\n <odx-icon name=\"calendar\" />\n </button>\n <ng-content select=\"[odxButton]\" ngProjectAs=\"[odxButton]\" />\n</odx-action-group>\n\n<ng-template #calendarOverlay>\n <odx-calendar\n [selectedDate]=\"value || today\"\n [filterFn]=\"filterFn\"\n [minDate]=\"minDate\"\n [maxDate]=\"maxDate\"\n cdkTrapFocus\n cdkTrapFocusAutoCapture\n (selectedDateChange)=\"selectDate($event)\"\n />\n</ng-template>\n","import { NgModule } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { DatepickerComponent } from './datepicker.component';\nimport { DatepickerInputControlDirective } from './directives';\n\nconst modules = [DatepickerComponent, DatepickerInputControlDirective];\n\n@NgModule({\n imports: modules,\n exports: [CoreModule, ...modules],\n})\nexport class DatepickerModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;;;;;;;;AAEa,MAAA,wBAAwB,GAAG;AACtC,IAAA,GAAG,EAAE,KAAK;AACV,IAAA,GAAG,EAAE,KAAK;AACV,IAAA,GAAG,EAAE,KAAK;;;ACHC,MAAA,qBAA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angular-components-datepicker.mjs","sources":["../../../../libs/angular/components/datepicker/src/lib/models/datepicker-input-date-order.ts","../../../../libs/angular/components/datepicker/src/lib/models/datepicker-input-pattern.ts","../../../../libs/angular/components/datepicker/src/lib/datepicker.config.ts","../../../../libs/angular/components/datepicker/src/lib/utils/get-datepicker-input-pattern.ts","../../../../libs/angular/components/datepicker/src/lib/utils/get-datepicker-input-value-as-date.ts","../../../../libs/angular/components/datepicker/src/lib/directives/datepicker-input-control.directive.ts","../../../../libs/angular/components/datepicker/src/lib/datepicker.component.ts","../../../../libs/angular/components/datepicker/src/lib/datepicker.component.html","../../../../libs/angular/components/datepicker/src/lib/datepicker.module.ts","../../../../libs/angular/components/datepicker/src/odx-angular-components-datepicker.ts"],"sourcesContent":["export type DatepickerInputDateOrder = (typeof DatepickerInputDateOrder)[keyof typeof DatepickerInputDateOrder];\n\nexport const DatepickerInputDateOrder = {\n DMY: 'DMY',\n MDY: 'MDY',\n YMD: 'YMD',\n};\n","export type DatepickerInputPattern = typeof DatepickerInputFormat | typeof DatepickerInputMask;\n\nexport const DatepickerInputFormat = {\n DAYS: 'dd',\n MONTH: 'MM',\n YEAR: 'yyyy',\n};\n\nexport const DatepickerInputMask = {\n DAYS: 'd0',\n MONTH: 'M0',\n YEAR: '0000',\n};\n","import { createConfigTokens } from '@odx/angular/utils';\nimport { DatepickerInputDateOrder } from './models';\n\nexport interface DatepickerConfig {\n /**\n * Date's order ('DMY' | 'MDY' | 'YMD').\n * @default DatepickerInputDateOrder.DMY\n */\n inputDateOrder: DatepickerInputDateOrder;\n /**\n * Single-character date's separator (dot, slash etc.).\n * @default '.'\n */\n inputDateSeparator: string;\n}\n\n/**\n * Tools for injecting and providing the datepicker configuration with default configuration for the datepicker.\n *\n * @example\n * // Providing custom datepicker configuration.\n * ```ts\n * @Component({\n * providers: [provideDatepickerConfig({ inputDateOrder: DatepickerInputDateOrder.MDY, inputDateSeparator: '/'})]\n * })\n * export class MyComponent {}\n *\n * // Injecting the datepicker configuration.\n * ```ts\n * @Component({})\n * export class MyComponent {\n * constructor(@Inject(injectDatepickerConfig()) private readonly datepickerConfig: DatepickerConfig) {}\n * }\n * ```\n */\nexport const { DatepickerConfig, DatepickerDefaultConfig, injectDatepickerConfig, provideDatepickerConfig } = createConfigTokens(\n 'Datepicker',\n '@odx/angular/components/datepicker',\n {\n inputDateOrder: DatepickerInputDateOrder.DMY,\n inputDateSeparator: '.',\n },\n);\n","import { DatepickerConfig } from '../datepicker.config';\nimport { DatepickerInputDateOrder, DatepickerInputFormat, DatepickerInputMask, DatepickerInputPattern } from '../models';\n\nfunction getDatepickerInputPattern({ inputDateOrder, inputDateSeparator }: DatepickerConfig, pattern: DatepickerInputPattern): string {\n const patternList: Record<DatepickerInputDateOrder, string> = {\n [DatepickerInputDateOrder.DMY]: `${pattern.DAYS}${inputDateSeparator}${pattern.MONTH}${inputDateSeparator}${pattern.YEAR}`,\n [DatepickerInputDateOrder.MDY]: `${pattern.MONTH}${inputDateSeparator}${pattern.DAYS}${inputDateSeparator}${pattern.YEAR}`,\n [DatepickerInputDateOrder.YMD]: `${pattern.YEAR}${inputDateSeparator}${pattern.MONTH}${inputDateSeparator}${pattern.DAYS}`,\n };\n\n return patternList[inputDateOrder];\n}\n\n/** @internal */\nexport function getDatepickerInputFormat(config: DatepickerConfig): string {\n return getDatepickerInputPattern(config, DatepickerInputFormat);\n}\n\n/** @internal */\nexport function getDatepickerInputMask(config: DatepickerConfig): string {\n return getDatepickerInputPattern(config, DatepickerInputMask);\n}\n","import { isValid, toDate } from 'date-fns';\nimport { DatepickerConfig } from '../datepicker.config';\nimport { DatepickerInputDateOrder } from '../models';\n\ninterface DateCandidateInterface {\n month: string;\n day: string;\n year: string;\n}\n\nconst functionList: Record<DatepickerInputDateOrder, (splittedValue: string[]) => DateCandidateInterface> = {\n [DatepickerInputDateOrder.DMY]: (splittedValue: string[]) => {\n const [day, month, year] = splittedValue;\n return { month, day, year };\n },\n [DatepickerInputDateOrder.MDY]: (splittedValue: string[]) => {\n const [month, day, year] = splittedValue;\n return { month, day, year };\n },\n [DatepickerInputDateOrder.YMD]: (splittedValue: string[]) => {\n const [year, month, day] = splittedValue;\n return { month, day, year };\n },\n};\n\nfunction getDateCandidate({ inputDateOrder, inputDateSeparator }: DatepickerConfig, value: string): string | null {\n const splittedValue = value.split(inputDateSeparator);\n\n const { month, day, year }: DateCandidateInterface = functionList[inputDateOrder](splittedValue);\n\n const isDateCandidateInvalid = !month || !day || !year;\n\n return isDateCandidateInvalid ? null : `${month}.${day}.${year}`;\n}\n\n/** @internal */\nexport function getDatepickerInputValueAsDate(config: DatepickerConfig, value: string): Date | null {\n const dateCandidate: string | null = getDateCandidate(config, value);\n\n if (!dateCandidate) return null;\n\n const date = toDate(Date.parse(dateCandidate));\n\n return isValid(date) ? date : null;\n}\n","import { Directive, EventEmitter, HostListener, inject, Output } from '@angular/core';\nimport { ReadonlyController, WithTabIndex } from '@odx/angular';\nimport { InputControlDirective } from '@odx/angular/cdk/custom-form-control';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { NgxMaskConfig, NgxMaskPipe, provideNgxMask } from 'ngx-mask';\nimport { distinctUntilChanged, fromEvent, map, tap } from 'rxjs';\nimport { injectDatepickerConfig } from '../datepicker.config';\nimport { getDatepickerInputFormat, getDatepickerInputMask, getDatepickerInputValueAsDate } from '../utils';\n\n/**\n * A directive to enhance an input element as part of a datepicker control. It applies date input formatting,\n * mask handling, and emits focus events. This directive integrates with ngx-mask to handle input masking and\n * ensures that the input complies with the date format specified in the datepicker configuration.\n * Extends the `InputControlDirective` to provide input control functionality.\n * Has host directive `WithTabIndex` to manage the tabindex attribute of the input element.\n *\n * @see {InputControlDirective}\n * @see {WithTabIndex}\n */\n@CSSComponent('datepicker__control')\n@Directive({\n standalone: true,\n selector: 'input[odxDatepickerControl]',\n host: {\n '[attr.readonly]': 'readonlyController?.readonly || null',\n '[attr.placeholder]': 'placeholder',\n },\n providers: [ReadonlyController.connect(), provideNgxMask(), NgxMaskPipe],\n hostDirectives: [WithTabIndex],\n})\nexport class DatepickerInputControlDirective extends InputControlDirective {\n private readonly maskConfig: Partial<NgxMaskConfig> = { validation: false, leadZeroDateTime: true };\n\n protected readonly readonlyController = ReadonlyController.inject();\n protected readonly config = injectDatepickerConfig();\n protected readonly inputMask = getDatepickerInputMask(this.config);\n protected readonly ngxMaskPipe = inject(NgxMaskPipe);\n\n /**\n * Emits an event when the input field receives focus or loses focus, indicating the focus state.\n *\n * @emits {boolean} - Indicates whether the input field is focused.\n */\n @Output()\n public focused = new EventEmitter<boolean>();\n\n /**\n * Observable stream capturing and processing input events on the native element, applying the mask,\n * and emitting the current value.\n *\n * @emits {string} - The current value of the input field.\n */\n public override valueChange$ = fromEvent(this.element.nativeElement, 'input').pipe(\n distinctUntilChanged(),\n tap(() => this.applyMask()),\n map(() => this.nativeElementValue),\n );\n\n /**\n * Applies the configured input mask to the native element's value.\n */\n public applyMask(): void {\n this.nativeElementValue = this.ngxMaskPipe.transform(this.nativeElementValue, this.inputMask, this.maskConfig);\n }\n\n /**\n * Gets the current value of the input field as a `Date` object, based on the date format from the datepicker\n * configuration.\n *\n * @returns {Date | null} - The current value of the input field as a `Date` object, or `null` if the value is invalid.\n */\n public get valueAsDate(): Date | null {\n return getDatepickerInputValueAsDate(this.config, this.nativeElementValue);\n }\n\n /**\n * Computes the placeholder text for the input based on the date format from\n * the datepicker configuration.\n *\n * @returns {string} - The placeholder text, typically the date format in uppercase.\n */\n public get placeholder(): string {\n return getDatepickerInputFormat(this.config).toUpperCase();\n }\n\n @HostListener('focusin')\n protected handleFocusIn(): void {\n this.focused.emit(true);\n }\n\n @HostListener('focusout')\n protected handleFocusOut(): void {\n this.focused.emit(false);\n }\n}\n","import { A11yModule } from '@angular/cdk/a11y';\nimport {\n AfterViewInit,\n booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n ContentChild,\n ElementRef,\n EventEmitter,\n HostListener,\n input,\n Input,\n Output,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { detectControllerChanges } from '@odx/angular';\nimport { CustomFormControl } from '@odx/angular/cdk/custom-form-control';\nimport { ActionGroupComponent } from '@odx/angular/components/action-group';\nimport { ButtonComponent } from '@odx/angular/components/button';\nimport { CalendarComponent, DateFilter } from '@odx/angular/components/calendar';\nimport { DropdownDirective, DropdownModule } from '@odx/angular/components/dropdown';\nimport { IconComponent } from '@odx/angular/components/icon';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { deferFn, injectElement, Position, untilDestroyed } from '@odx/angular/utils';\nimport { format, startOfDay } from 'date-fns';\nimport { injectDatepickerConfig } from './datepicker.config';\nimport { DatepickerInputControlDirective } from './directives';\nimport { getDatepickerInputFormat } from './utils';\n\n/**\n * Represents a datepicker component for selecting a date.\n * Extends the `CustomFormControl` class and implements the `AfterViewInit` interface.\n *\n * @see {CustomFormControl}\n */\n@CSSComponent('datepicker')\n@Component({\n selector: 'odx-datepicker',\n standalone: true,\n imports: [A11yModule, ActionGroupComponent, ButtonComponent, CalendarComponent, DropdownModule, IconComponent],\n templateUrl: './datepicker.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class DatepickerComponent extends CustomFormControl<Date | null> implements AfterViewInit {\n protected readonly takeUntilDestroyed = untilDestroyed();\n\n protected readonly config = injectDatepickerConfig();\n\n public readonly element = injectElement();\n\n /**\n * Gets a value indicating whether the datepicker is currently open.\n *\n * @returns {boolean}\n */\n public get isOpen(): boolean {\n return !!this.dropdown.isOpen;\n }\n\n /**\n * Represents the current date.\n *\n * @type {Date}\n */\n public today = new Date();\n\n /**\n * The filter function used to determine if a date should be included or excluded in the datepicker.\n * If set to `null`, no filtering will be applied.\n *\n * @type {DateFilter | null}\n * @default null\n *\n * @example\n * ```ts\n * // Excludes mondays from the datepicker.\n * const filterFn: DateFilter = (date) => date.getDay() !== 1;\n * ```\n */\n @Input()\n public filterFn: DateFilter | null = null;\n\n /**\n * The minimum selectable date for the datepicker.\n * If set to null, there is no minimum date restriction.\n *\n * @type {Date | null}\n * @default null\n */\n @Input()\n public minDate: Date | null = null;\n\n /**\n * The maximum selectable date for the datepicker.\n * If set to null, there is no maximum date restriction.\n *\n * @type {Date | null}\n * @default null\n */\n @Input()\n public maxDate: Date | null = null;\n\n /**\n * The position of the dropdown relative to the input field.\n *\n * @type {Position}\n * @default Position.BOTTOM\n */\n @Input()\n public dropdownPosition: Position = 'bottom';\n\n /**\n * When set to true, the select will display a reset button.\n *\n * @type {boolean}\n * @default false\n */\n public clearable = input(false, { transform: booleanAttribute });\n\n /**\n * Emits the selected date when it changes.\n *\n * @emits {Date}\n */\n @Output()\n public selectedChange = new EventEmitter<Date>();\n\n /**\n * The dropdown directive used in the datepicker component.\n *\n * @type {DropdownDirective}\n */\n @ViewChild(DropdownDirective)\n public dropdown!: DropdownDirective;\n\n /**\n * The dropdown trigger element used in the datepicker component.\n *\n * @type {ElementRef<HTMLElement>}\n */\n @ViewChild('dropdownTrigger', { read: ElementRef, static: true })\n public dropdownTriggerElement!: ElementRef<HTMLElement>;\n\n /**\n * The date field input control directive used in the datepicker component.\n *\n * @type {DatepickerInputControlDirective | undefined}\n */\n @ContentChild(DatepickerInputControlDirective)\n public dateField?: DatepickerInputControlDirective;\n\n constructor() {\n super(null);\n detectControllerChanges(this).subscribe();\n }\n\n public ngAfterViewInit(): void {\n this.handleDateFieldChanges();\n this.handleDateFieldFocus();\n\n deferFn(() => {\n if (!this.value) return;\n this.updateDateField(startOfDay(this.value));\n });\n }\n\n /**\n * Selects a date.\n *\n * @param {Date | null} value - The date value to be selected.\n */\n public selectDate(value: Date | null): void {\n if (!value) return;\n\n this.updateInternalValue(value);\n\n this.selectedChange.emit(value);\n\n this.dropdown.close();\n }\n\n public reset(): void {\n this.updateInternalValue(null);\n }\n\n protected updateInternalValue(value: Date | null): void {\n this.updateValue(value);\n this.updateDateField(value);\n }\n\n protected handleDateFieldChanges(): void {\n this.dateField?.valueChange$.pipe(this.takeUntilDestroyed()).subscribe(() => this.updateValue(this.dateField?.valueAsDate ?? null));\n }\n\n protected handleDateFieldFocus(): void {\n this.dateField?.focused.pipe(this.takeUntilDestroyed()).subscribe((isFocused) => {\n if (!isFocused) {\n this.onTouched();\n }\n if (this.isOpen) {\n this.dropdown.close();\n }\n });\n }\n\n @HostListener('keydown.alt.ArrowDown', ['$event'])\n protected openDatepicker(event: KeyboardEvent) {\n event.stopPropagation();\n\n if (this.isReadonly || this.isDisabled) return;\n\n this.dropdown.open(event);\n }\n\n private updateDateField(date: Date | null): void {\n if (!this.dateField) return;\n\n const dateFormat = getDatepickerInputFormat(this.config);\n this.dateField.nativeElementValue = date ? format(date, dateFormat) : '';\n }\n}\n","<ng-content select=\"input[odxDatepickerControl]\" />\n\n<odx-action-group class=\"odx-datepicker__trigger-wrapper\">\n @if (clearable() && value) {\n <button odxButton class=\"odx-datepicker__clear\" (click)=\"reset()\" size=\"small\" aria-label=\"Reset time\">\n <odx-icon name=\"close\" iconSet=\"core\" />\n </button>\n }\n <button\n #dropdownTrigger\n odxButton\n size=\"small\"\n variant=\"ghost\"\n class=\"odx-datepicker__trigger\"\n [odxDropdown]=\"calendarOverlay\"\n [odxDropdownOptions]=\"{ position: dropdownPosition }\"\n [odxDropdownTriggerElement]=\"dropdownTriggerElement.nativeElement\"\n [odxDropdownHost]=\"null\"\n [odxDropdownReferenceElement]=\"element.nativeElement\"\n (odxDropdownBeforeClose)=\"onTouched()\"\n >\n <odx-icon name=\"calendar\" />\n </button>\n <ng-content select=\"[odxButton]\" ngProjectAs=\"[odxButton]\" />\n</odx-action-group>\n\n<ng-template #calendarOverlay>\n <odx-calendar\n [selectedDate]=\"value || today\"\n [filterFn]=\"filterFn\"\n [minDate]=\"minDate\"\n [maxDate]=\"maxDate\"\n cdkTrapFocus\n cdkTrapFocusAutoCapture\n (selectedDateChange)=\"selectDate($event)\"\n />\n</ng-template>\n","import { NgModule } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { DatepickerComponent } from './datepicker.component';\nimport { DatepickerInputControlDirective } from './directives';\n\nconst modules = [DatepickerComponent, DatepickerInputControlDirective];\n\n@NgModule({\n imports: modules,\n exports: [CoreModule, ...modules],\n})\nexport class DatepickerModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;;;;;;;;AAEa,MAAA,wBAAwB,GAAG;AACtC,IAAA,GAAG,EAAE,KAAK;AACV,IAAA,GAAG,EAAE,KAAK;AACV,IAAA,GAAG,EAAE,KAAK;;;ACHC,MAAA,qBAAqB,GAAG;AACnC,IAAA,IAAI,EAAE,IAAI;AACV,IAAA,KAAK,EAAE,IAAI;AACX,IAAA,IAAI,EAAE,MAAM;;AAGD,MAAA,mBAAmB,GAAG;AACjC,IAAA,IAAI,EAAE,IAAI;AACV,IAAA,KAAK,EAAE,IAAI;AACX,IAAA,IAAI,EAAE,MAAM;;;ACKd;;;;;;;;;;;;;;;;;;AAkBG;AACU,MAAA,EAAE,gBAAgB,EAAE,uBAAuB,EAAE,sBAAsB,EAAE,uBAAuB,EAAE,GAAG,kBAAkB,CAC9H,YAAY,EACZ,oCAAoC,EACpC;IACE,cAAc,EAAE,wBAAwB,CAAC,GAAG;AAC5C,IAAA,kBAAkB,EAAE,GAAG;AACxB,CAAA;;ACtCH,SAAS,yBAAyB,CAAC,EAAE,cAAc,EAAE,kBAAkB,EAAoB,EAAE,OAA+B,EAAA;AAC1H,IAAA,MAAM,WAAW,GAA6C;QAC5D,CAAC,wBAAwB,CAAC,GAAG,GAAG,CAAG,EAAA,OAAO,CAAC,IAAI,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,KAAK,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,IAAI,CAAE,CAAA;QAC1H,CAAC,wBAAwB,CAAC,GAAG,GAAG,CAAG,EAAA,OAAO,CAAC,KAAK,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,I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E,+BAA+B,CAAA,EAAA,CAAA,CAAA;gHAMxD,gBAAgB,EAAA,OAAA,EAAA,CANZ,mBAAmB,EAIxB,UAAU,CAAA,EAAA,CAAA,CAAA;;4FAET,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAJ5B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,OAAO;AAChB,oBAAA,OAAO,EAAE,CAAC,UAAU,EAAE,GAAG,OAAO,CAAC;AAClC,iBAAA;;;ACVD;;AAEG;;;;"}
|
|
@@ -2,15 +2,15 @@ import { __decorate, __metadata } from 'tslib';
|
|
|
2
2
|
import * as i1$1 from '@angular/cdk/a11y';
|
|
3
3
|
import { A11yModule } from '@angular/cdk/a11y';
|
|
4
4
|
import * as i0 from '@angular/core';
|
|
5
|
-
import { inject, EventEmitter,
|
|
5
|
+
import { inject, EventEmitter, HostListener, Output, Directive, input, booleanAttribute, ElementRef, ViewChild, ContentChildren, Input, ViewEncapsulation, ChangeDetectionStrategy, Component, forwardRef, NgModule } from '@angular/core';
|
|
6
6
|
import * as i1 from '@odx/angular';
|
|
7
7
|
import { ReadonlyController, WithTabIndex, detectControllerChanges, CoreModule } from '@odx/angular';
|
|
8
8
|
import { InputControlDirective, CustomFormControl } from '@odx/angular/cdk/custom-form-control';
|
|
9
9
|
import { ActionGroupComponent } from '@odx/angular/components/action-group';
|
|
10
10
|
import { ButtonComponent } from '@odx/angular/components/button';
|
|
11
|
-
import { provideCalendarConfig, CalendarSelectionMode,
|
|
11
|
+
import { CalendarComponent, provideCalendarConfig, CalendarSelectionMode, validateDaterange } from '@odx/angular/components/calendar';
|
|
12
12
|
import * as i2 from '@odx/angular/components/dropdown';
|
|
13
|
-
import {
|
|
13
|
+
import { DropdownModule, DropdownDirective } from '@odx/angular/components/dropdown';
|
|
14
14
|
import { IconComponent } from '@odx/angular/components/icon';
|
|
15
15
|
import { CSSComponent } from '@odx/angular/internal';
|
|
16
16
|
import { createConfigTokens, untilDestroyed, injectElement, deferFn } from '@odx/angular/utils';
|
|
@@ -280,10 +280,8 @@ let DaterangepickerComponent = class DaterangepickerComponent extends CustomForm
|
|
|
280
280
|
deferFn(() => {
|
|
281
281
|
if (!this.value || !this.value.start || !this.value.end)
|
|
282
282
|
return;
|
|
283
|
-
this.
|
|
284
|
-
|
|
285
|
-
end: startOfDay(this.value.end),
|
|
286
|
-
});
|
|
283
|
+
this.updateStartDateField(startOfDay(this.value.start));
|
|
284
|
+
this.updateEndDateField(startOfDay(this.value.end));
|
|
287
285
|
});
|
|
288
286
|
}
|
|
289
287
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odx-angular-components-daterangepicker.mjs","sources":["../../../../libs/angular/components/daterangepicker/src/lib/daterangepicker.config.ts","../../../../libs/angular/components/daterangepicker/src/lib/utils/get-daterangepicker-input-pattern.ts","../../../../libs/angular/components/daterangepicker/src/lib/utils/get-daterangepicker-input-value-as-date.ts","../../../../libs/angular/components/daterangepicker/src/lib/directives/daterangepicker-input-control.directive.ts","../../../../libs/angular/components/daterangepicker/src/lib/daterangepicker.component.ts","../../../../libs/angular/components/daterangepicker/src/lib/daterangepicker.component.html","../../../../libs/angular/components/daterangepicker/src/lib/range.validator.ts","../../../../libs/angular/components/daterangepicker/src/lib/required.validator.ts","../../../../libs/angular/components/daterangepicker/src/lib/daterangepicker.module.ts","../../../../libs/angular/components/daterangepicker/src/odx-angular-components-daterangepicker.ts"],"sourcesContent":["import { createConfigTokens } from '@odx/angular/utils';\nimport { DaterangepickerInputDateOrder } from './models';\n\nexport interface DaterangepickerConfig {\n /**\n * Date's order ('DMY' | 'MDY' | 'YMD').\n * @default DaterangepickerInputDateOrder.DMY\n */\n inputDateOrder: DaterangepickerInputDateOrder;\n /**\n * Single-character date's separator (dot, slash etc.).\n * @default '.'\n */\n inputDateSeparator: string;\n}\n\n/**\n * Tools for injecting and providing the daterangepicker configuration with default configuration for the daterangepicker.\n *\n * @example\n * // Providing custom daterangepicker configuration.\n * ```ts\n * @Component({\n * providers: [provideDaterangepickerConfig({ inputDateOrder: DaterangepickerInputDateOrder.MDY, inputDateSeparator: '/'})]\n * })\n * export class MyComponent {}\n *\n * // Injecting the daterangepicker configuration.\n * ```ts\n * @Component({})\n * export class MyComponent {\n * constructor(@Inject(injectDaterangepickerConfig()) private readonly daterangepickerConfig: DaterangepickerConfig) {}\n * }\n * ```\n */\nexport const { DaterangepickerConfig, DaterangepickerDefaultConfig, injectDaterangepickerConfig, provideDaterangepickerConfig } = createConfigTokens(\n 'Daterangepicker',\n '@odx/angular/components/daterangepicker',\n {\n inputDateOrder: DaterangepickerInputDateOrder.DMY,\n inputDateSeparator: '.',\n },\n);\n","import { DaterangepickerConfig } from '../daterangepicker.config';\nimport { DaterangepickerInputDateOrder, DaterangepickerInputFormat, DaterangepickerInputMask, DaterangepickerInputPattern } from '../models';\n\nfunction getDaterangepickerInputPattern({ inputDateOrder, inputDateSeparator }: DaterangepickerConfig, pattern: DaterangepickerInputPattern): string {\n const patternList: Record<DaterangepickerInputDateOrder, string> = {\n [DaterangepickerInputDateOrder.DMY]: `${pattern.DAYS}${inputDateSeparator}${pattern.MONTH}${inputDateSeparator}${pattern.YEAR}`,\n [DaterangepickerInputDateOrder.MDY]: `${pattern.MONTH}${inputDateSeparator}${pattern.DAYS}${inputDateSeparator}${pattern.YEAR}`,\n [DaterangepickerInputDateOrder.YMD]: `${pattern.YEAR}${inputDateSeparator}${pattern.MONTH}${inputDateSeparator}${pattern.DAYS}`,\n };\n\n return patternList[inputDateOrder];\n}\n\n/** @internal */\nexport function getDaterangepickerInputFormat(config: DaterangepickerConfig): string {\n return getDaterangepickerInputPattern(config, DaterangepickerInputFormat);\n}\n\n/** @internal */\nexport function getDaterangepickerInputMask(config: DaterangepickerConfig): string {\n return getDaterangepickerInputPattern(config, DaterangepickerInputMask);\n}\n","import { isValid, toDate } from 'date-fns';\nimport { DaterangepickerConfig } from '../daterangepicker.config';\nimport { DaterangepickerInputDateOrder } from '../models';\n\ninterface DateCandidateInterface {\n month: string;\n day: string;\n year: string;\n}\n\nconst functionList: Record<DaterangepickerInputDateOrder, (splittedValue: string[]) => DateCandidateInterface> = {\n [DaterangepickerInputDateOrder.DMY]: (splittedValue: string[]) => {\n const [day, month, year] = splittedValue;\n return { month, day, year };\n },\n [DaterangepickerInputDateOrder.MDY]: (splittedValue: string[]) => {\n const [month, day, year] = splittedValue;\n return { month, day, year };\n },\n [DaterangepickerInputDateOrder.YMD]: (splittedValue: string[]) => {\n const [year, month, day] = splittedValue;\n return { month, day, year };\n },\n};\n\nfunction getDateCandidate({ inputDateOrder, inputDateSeparator }: DaterangepickerConfig, value: string): string | null {\n const splittedValue = value.split(inputDateSeparator);\n\n const { month, day, year }: DateCandidateInterface = functionList[inputDateOrder](splittedValue);\n\n const isDateCandidateInvalid = !month || !day || !year;\n\n return isDateCandidateInvalid ? null : `${month}.${day}.${year}`;\n}\n\n/** @internal */\nexport function getDaterangepickerInputValueAsDate(config: DaterangepickerConfig, value: string): Date | null {\n const dateCandidate: string | null = getDateCandidate(config, value);\n\n if (!dateCandidate) return null;\n\n const date = toDate(Date.parse(dateCandidate));\n\n return isValid(date) ? date : null;\n}\n","import { Directive, EventEmitter, HostListener, inject, Output } from '@angular/core';\nimport { ReadonlyController, WithTabIndex } from '@odx/angular';\nimport { InputControlDirective } from '@odx/angular/cdk/custom-form-control';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { NgxMaskConfig, NgxMaskPipe, provideNgxMask } from 'ngx-mask';\nimport { distinctUntilChanged, fromEvent, map, tap } from 'rxjs';\nimport { injectDaterangepickerConfig } from '../daterangepicker.config';\nimport { getDaterangepickerInputFormat, getDaterangepickerInputMask, getDaterangepickerInputValueAsDate } from '../utils';\n\n/**\n * Enhances an input element to support date range picking, applying an input mask for date formatting\n * and managing focus events. This directive is typically used within a date range picker to provide\n * consistent and configurable input behavior. Extends the `InputControlDirective` to provide form control.\n * Has host directive `WithTabIndex` to manage the tab index attribute of the input element.\n *\n * @see {InputControlDirective}\n */\n@CSSComponent('daterangepicker__control')\n@Directive({\n standalone: true,\n selector: 'input[odxDaterangepickerControl],input[odxDaterangepickerStartDateControl], input[odxDaterangepickerEndDateControl]',\n host: {\n '[attr.readonly]': 'readonlyController?.readonly || null',\n '[attr.placeholder]': 'placeholder',\n },\n providers: [ReadonlyController.connect(), provideNgxMask(), NgxMaskPipe],\n hostDirectives: [WithTabIndex],\n})\nexport class DaterangepickerInputControlDirective extends InputControlDirective {\n private readonly maskConfig: Partial<NgxMaskConfig> = { validation: false, leadZeroDateTime: true };\n\n protected readonly readonlyController = ReadonlyController.inject();\n protected readonly config = injectDaterangepickerConfig();\n protected readonly inputMask = getDaterangepickerInputMask(this.config);\n protected readonly ngxMaskPipe = inject(NgxMaskPipe);\n\n /**\n * Emits an event when the input gains or loses focus, facilitating external event handling.\n *\n * @emits {boolean} - Indicates whether the input is focused.\n */\n @Output()\n public focused = new EventEmitter<boolean>();\n\n /**\n * Captures and processes changes to the input element's value, applying the mask and updating\n * the form control.\n *\n * @emits {string} - The updated value of the input element.\n */\n public override valueChange$ = fromEvent(this.element.nativeElement, 'input').pipe(\n distinctUntilChanged(),\n tap(() => this.applyMask()),\n map(() => this.nativeElementValue),\n );\n\n /**\n * Applies the configured input mask to the native input element's value.\n */\n public applyMask(): void {\n this.nativeElementValue = this.ngxMaskPipe.transform(this.nativeElementValue, this.inputMask, this.maskConfig);\n }\n\n /**\n * Converts the current input value to a Date object based on the configuration's date format.\n *\n * @returns {Date | null} The parsed date object or null if the input does not represent a valid date.\n */\n public get valueAsDate(): Date | null {\n return getDaterangepickerInputValueAsDate(this.config, this.nativeElementValue);\n }\n\n /**\n * Provides the placeholder text for the input, typically the date format in uppercase.\n *\n * @returns {string} The placeholder text for the input.\n */\n public get placeholder(): string {\n return getDaterangepickerInputFormat(this.config).toUpperCase();\n }\n\n @HostListener('focusin')\n protected handleFocusIn(): void {\n this.focused.emit(true);\n }\n\n @HostListener('focusout')\n protected handleFocusOut(): void {\n this.focused.emit(false);\n }\n}\n","import { A11yModule } from '@angular/cdk/a11y';\nimport {\n AfterViewInit,\n booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n ContentChildren,\n ElementRef,\n EventEmitter,\n HostListener,\n input,\n Input,\n Output,\n QueryList,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { detectControllerChanges } from '@odx/angular';\nimport { CustomFormControl } from '@odx/angular/cdk/custom-form-control';\nimport { ActionGroupComponent } from '@odx/angular/components/action-group';\nimport { ButtonComponent } from '@odx/angular/components/button';\nimport { CalendarComponent, CalendarSelectionMode, DateFilter, DateRange, provideCalendarConfig } from '@odx/angular/components/calendar';\nimport { DropdownDirective, DropdownModule } from '@odx/angular/components/dropdown';\nimport { IconComponent } from '@odx/angular/components/icon';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { deferFn, injectElement, Position, untilDestroyed } from '@odx/angular/utils';\nimport { format, startOfDay } from 'date-fns';\nimport { injectDaterangepickerConfig } from './daterangepicker.config';\nimport { DaterangepickerInputControlDirective } from './directives';\nimport { getDaterangepickerInputFormat } from './utils';\n\n/**\n * A component for selecting a date range, integrated with dropdowns and input fields for start and end dates.\n * It supports custom configurations for minimum, maximum dates, and date filters. The component also handles\n * the dropdown's behavior for date selection and applies date formats automatically based on configuration.\n * The component extends the `CustomFormControl` class to provide form control functionality.\n *\n * @see {CustomFormControl}\n */\n@CSSComponent('daterangepicker')\n@Component({\n selector: 'odx-daterangepicker',\n standalone: true,\n imports: [A11yModule, ActionGroupComponent, ButtonComponent, CalendarComponent, DropdownModule, IconComponent],\n templateUrl: './daterangepicker.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [\n provideCalendarConfig({\n displayAdjacentDays: false,\n selectionMode: CalendarSelectionMode.DateRange,\n }),\n ],\n})\nexport class DaterangepickerComponent extends CustomFormControl<DateRange | null> implements AfterViewInit {\n protected readonly takeUntilDestroyed = untilDestroyed();\n\n protected readonly config = injectDaterangepickerConfig();\n\n public readonly element = injectElement();\n\n /**\n * Indicates whether the dropdown part of the date range picker is open.\n *\n * @type {boolean}\n */\n public get isOpen(): boolean {\n return !!this.dropdown.isOpen;\n }\n\n /**\n * Represents today's date, used for default selections and validations.\n *\n * @type {Date}\n */\n public today = new Date();\n\n /**\n * A function that defines additional rules for disabled dates within the picker.\n *\n * @type {DateFilter | null}\n * @default null\n *\n * @example\n * ```ts\n * // Disables all Wednesdays in the picker.\n * const filterFn: DateFilter = (date: Date) => date.getDay() !== 3;\n * ```\n */\n @Input()\n public filterFn: DateFilter | null = null;\n\n /**\n * The earliest date that can be selected in the picker.\n *\n * @type {Date | null}\n * @default null\n */\n @Input()\n public minDate: Date | null = null;\n\n /**\n * The latest date that can be selected in the picker.\n *\n * @type {Date | null}\n * @default null\n */\n @Input()\n public maxDate: Date | null = null;\n\n /**\n * Position of the dropdown relative to the input fields.\n *\n * @type {Position}\n * @default Position.BOTTOM\n */\n @Input()\n public dropdownPosition: Position = 'bottom';\n\n /**\n * When set to true, the select will display a reset button.\n *\n * @type {boolean}\n * @default false\n */\n public clearable = input(false, { transform: booleanAttribute });\n\n /**\n * Emits the selected date range when it changes.\n *\n * @emits {DateRange}\n */\n @Output()\n public selectedChange = new EventEmitter<DateRange>();\n\n /**\n * Directive managing the dropdown functionality.\n *\n * @type {DropdownDirective}\n */\n @ViewChild(DropdownDirective)\n public dropdown!: DropdownDirective;\n\n /**\n * Reference to the element triggering the dropdown.\n *\n * @type {ElementRef<HTMLElement>}\n */\n @ViewChild('dropdownTrigger', { read: ElementRef, static: true })\n public dropdownTriggerElement!: ElementRef<HTMLElement>;\n\n /**\n * Query list of the input controls within the date range picker.\n *\n * @type {QueryList<DaterangepickerInputControlDirective>}\n */\n @ContentChildren(DaterangepickerInputControlDirective)\n public dateFields!: QueryList<DaterangepickerInputControlDirective>;\n\n /**\n * Reference to the element mirroring the start date input field.\n *\n * @type {ElementRef<HTMLElement>}\n */\n @ViewChild('startDateMirror', { read: ElementRef, static: true })\n public startDateMirror!: ElementRef<HTMLElement>;\n\n /**\n * Reference to the element mirroring the end date input field.\n *\n * @type {ElementRef<HTMLElement>}\n */\n @ViewChild('endDateMirror', { read: ElementRef, static: true })\n public endDateMirror!: ElementRef<HTMLElement>;\n\n /**\n * The input control for the start date.\n *\n * @type {DaterangepickerInputControlDirective | undefined}\n */\n public get startDateField(): DaterangepickerInputControlDirective | undefined {\n const [startDate, _endDate] = this.dateFields;\n return startDate;\n }\n\n /**\n * The input control for the end date.\n *\n * @type {DaterangepickerInputControlDirective | undefined}\n */\n public get endDateField(): DaterangepickerInputControlDirective | undefined {\n const [_startDate, endDate] = this.dateFields;\n return endDate;\n }\n\n constructor() {\n super(null);\n detectControllerChanges(this).subscribe();\n }\n\n public ngAfterViewInit(): void {\n this.updateWidth(this.startDateField, this.startDateMirror);\n this.updateWidth(this.endDateField, this.endDateMirror);\n this.handleDateFieldChanges();\n this.handleDateFieldFocus();\n\n deferFn(() => {\n if (!this.value || !this.value.start || !this.value.end) return;\n this.updateInternalValue({\n start: startOfDay(this.value.start),\n end: startOfDay(this.value.end),\n });\n });\n }\n\n /**\n * Selects a date range, updates the form value, and emits the selected range.\n *\n * @param {DateRange | null} value - The date range to select.\n */\n public selectDateRange(value: DateRange | null): void {\n if (!value || !value.start || !value.end) return;\n\n this.updateInternalValue(value);\n\n this.selectedChange.emit(value);\n this.dropdown.close();\n }\n\n public reset(): void {\n this.updateInternalValue({ start: null, end: null });\n }\n\n protected isEmpty(value: DateRange | null): boolean {\n return !value || !value.start || !value.end;\n }\n\n protected updateInternalValue(value: DateRange): void {\n this.updateValue(value);\n this.updateStartDateField(value.start);\n this.updateEndDateField(value.end);\n }\n\n protected handleDateFieldChanges(): void {\n this.startDateField?.valueChange$.pipe(this.takeUntilDestroyed()).subscribe((value: string) => {\n this.updateValue({ start: this.startDateField?.valueAsDate ?? null, end: this.endDateField?.valueAsDate ?? null });\n this.updateWidth(this.startDateField, this.startDateMirror, value);\n });\n this.endDateField?.valueChange$.pipe(this.takeUntilDestroyed()).subscribe((value: string) => {\n this.updateValue({ start: this.startDateField?.valueAsDate ?? null, end: this.endDateField?.valueAsDate ?? null });\n this.updateWidth(this.endDateField, this.endDateMirror, value);\n });\n }\n\n protected updateWidth(target: DaterangepickerInputControlDirective | undefined, source: ElementRef<HTMLElement>, value = ''): void {\n const compensationPx = 2;\n source.nativeElement.textContent = value || target?.placeholder || null;\n if (target) {\n deferFn(() => (target.element.nativeElement.style.width = `${source.nativeElement.offsetWidth + compensationPx}px`));\n }\n }\n\n protected handleDateFieldFocus(): void {\n this.startDateField?.focused.pipe(this.takeUntilDestroyed()).subscribe((isFocused) => {\n if (!isFocused) {\n this.onTouched();\n }\n if (this.isOpen) {\n this.dropdown.close();\n }\n });\n this.endDateField?.focused.pipe(this.takeUntilDestroyed()).subscribe((isFocused) => {\n if (!isFocused) {\n this.onTouched();\n }\n if (this.isOpen) {\n this.dropdown.close();\n }\n });\n }\n\n @HostListener('keydown.alt.ArrowDown', ['$event'])\n protected openDaterangepicker(event: KeyboardEvent) {\n event.stopPropagation();\n\n if (this.isReadonly || this.isDisabled) return;\n\n this.dropdown.open(event);\n }\n\n private updateStartDateField(date: Date | null): void {\n if (!this.startDateField) return;\n\n const dateFormat = getDaterangepickerInputFormat(this.config);\n this.startDateField.nativeElementValue = date ? format(date, dateFormat) : '';\n this.updateWidth(this.startDateField, this.startDateMirror, date ? format(date, dateFormat) : '');\n }\n\n private updateEndDateField(date: Date | null): void {\n if (!this.endDateField) return;\n\n const dateFormat = getDaterangepickerInputFormat(this.config);\n this.endDateField.nativeElementValue = date ? format(date, dateFormat) : '';\n this.updateWidth(this.endDateField, this.endDateMirror, date ? format(date, dateFormat) : '');\n }\n}\n","<span #startDateMirror role=\"none\" class=\"odx-daterangepicker__mirror\"></span>\n<ng-content select=\"input[odxDaterangepickerStartDateControl]\" />\n<span role=\"none\" class=\"odx-daterangepicker__separator\">–</span>\n<span #endDateMirror role=\"none\" class=\"odx-daterangepicker__mirror\"></span>\n<ng-content select=\"input[odxDaterangepickerEndDateControl]\" />\n\n<odx-action-group class=\"odx-daterangepicker__trigger-wrapper\">\n @if (clearable() && !isEmpty(value)) {\n <button class=\"odx-daterangepicker__clear\" (click)=\"reset()\" odxButton size=\"small\" aria-label=\"Reset time\">\n <odx-icon name=\"close\" iconSet=\"core\" />\n </button>\n }\n <button\n #dropdownTrigger\n odxButton\n size=\"small\"\n variant=\"ghost\"\n class=\"odx-daterangepicker__trigger\"\n [odxDropdown]=\"calendarOverlay\"\n [odxDropdownOptions]=\"{ position: dropdownPosition }\"\n [odxDropdownTriggerElement]=\"dropdownTriggerElement.nativeElement\"\n [odxDropdownHost]=\"null\"\n [odxDropdownReferenceElement]=\"element.nativeElement\"\n (odxDropdownBeforeClose)=\"onTouched()\"\n >\n <odx-icon name=\"calendar\" />\n </button>\n <ng-content select=\"[odxButton]\" ngProjectAs=\"[odxButton]\" />\n</odx-action-group>\n\n<ng-template #calendarOverlay>\n <odx-calendar\n [selectedDate]=\"today\"\n [selectedDateRange]=\"value\"\n (selectedDateRangeChange)=\"selectDateRange($event)\"\n [filterFn]=\"filterFn\"\n [minDate]=\"minDate\"\n [maxDate]=\"maxDate\"\n cdkTrapFocus\n cdkTrapFocusAutoCapture\n />\n</ng-template>\n","import { Directive, forwardRef } from '@angular/core';\nimport { FormControl, NG_VALIDATORS } from '@angular/forms';\nimport { DateRange, validateDaterange } from '@odx/angular/components/calendar';\n\n/**\n * A validation directive to be used with date range picker controls. This validator ensures that the date range\n * selected is valid, meaning the start date must occur on or before the end date. If the date range is invalid,\n * this validator will provide a validation error that can be used to display an appropriate message or to style\n * the form control.\n *\n * The validator is designed to be used with form controls that manage `DateRange` objects in Angular forms.\n */\n@Directive({\n standalone: true,\n selector: 'odx-daterangepicker[formControlName], odx-daterangepicker[formControl], odx-daterangepicker[ngModel]',\n providers: [\n {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => DaterangepickerRangeValidator),\n multi: true,\n },\n ],\n})\nexport class DaterangepickerRangeValidator {\n /**\n * Performs the validation check on the form control's value.\n *\n * @param {FormControl<DateRange | null>} control - The form control instance associated with the date range input.\n * @returns {ValidationErrors | null} An object expressing validation errors if the range is invalid,\n * or null if the range is valid. The object returned in case of a validation error is `{ invalidRange: true }`.\n */\n public validate({ value }: FormControl<DateRange | null>) {\n const valuesArePresent = value && value.start && value.end;\n\n const isValidRange = value && value.start && value.end && validateDaterange(value.start, value.end);\n\n return (\n valuesArePresent &&\n !isValidRange && {\n invalidRange: true,\n }\n );\n }\n}\n","import { Directive, forwardRef } from '@angular/core';\nimport { FormControl, NG_VALIDATORS } from '@angular/forms';\nimport { DateRange } from '@odx/angular/components/calendar';\n\n/**\n * A validation directive to ensure that both start and end dates are provided for a date range picker.\n * This validator is essential for forms where the date range is a required field. It checks that both the\n * start and end date values exist in the date range object. If one or both dates are missing, it flags the\n * form control as having a validation error.\n */\n@Directive({\n standalone: true,\n selector: 'odx-daterangepicker[required][formControlName], odx-daterangepicker[required][formControl], odx-daterangepicker[required][ngModel]',\n providers: [\n {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => DaterangepickerRequiredValidator),\n multi: true,\n },\n ],\n})\nexport class DaterangepickerRequiredValidator {\n /**\n * Validates the form control associated with the date range input.\n * Checks if both start and end dates are present. If either is missing, it returns a validation error.\n *\n * @param {FormControl<DateRange | null>} control - The form control instance that contains the date range value.\n * @returns {ValidationErrors | null} An object expressing validation errors if the range is incomplete,\n * or null if the range is fully specified. If validation fails, the object returned is `{ required: true }`.\n */\n public validate({ value }: FormControl<DateRange | null>) {\n const isValid = value && value.start && value.end;\n\n return (\n !isValid && {\n required: true,\n }\n );\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { DaterangepickerComponent } from './daterangepicker.component';\nimport { DaterangepickerInputControlDirective } from './directives';\nimport { DaterangepickerRangeValidator } from './range.validator';\nimport { DaterangepickerRequiredValidator } from './required.validator';\n\nconst modules = [DaterangepickerComponent, DaterangepickerInputControlDirective, DaterangepickerRangeValidator, DaterangepickerRequiredValidator];\n\n@NgModule({\n imports: modules,\n exports: [CoreModule, ...modules],\n})\nexport class DaterangepickerModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["DaterangepickerInputDateOrder","DaterangepickerInputFormat","DaterangepickerInputMask","i1"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAgBA;;;;;;;;;;;;;;;;;;AAkBG;AACU,MAAA,EAAE,qBAAqB,EAAE,4BAA4B,EAAE,2BAA2B,EAAE,4BAA4B,EAAE,GAAG,kBAAkB,CAClJ,iBAAiB,EACjB,yCAAyC,EACzC;IACE,cAAc,EAAEA,wBAA6B,CAAC,GAAG;AACjD,IAAA,kBAAkB,EAAE,GAAG;AACxB,CAAA;;ACtCH,SAAS,8BAA8B,CAAC,EAAE,cAAc,EAAE,kBAAkB,EAAyB,EAAE,OAAoC,EAAA;AACzI,IAAA,MAAM,WAAW,GAAkD;QACjE,CAACA,wBAA6B,CAAC,GAAG,GAAG,CAAG,EAAA,OAAO,CAAC,IAAI,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,KAAK,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,IAAI,CAAE,CAAA;QAC/H,CAACA,wBAA6B,CAAC,GAAG,GAAG,CAAG,EAAA,OAAO,CAAC,KAAK,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,IAAI,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,IAAI,CAAE,CAAA;QAC/H,CAACA,wBAA6B,CAAC,GAAG,GAAG,CAAG,EAAA,OAAO,CAAC,IAAI,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,KAAK,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,IAAI,CAAE,CAAA;KAChI;AAED,IAAA,OAAO,WAA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AAA,EAAA,CANjB,wBAAwB,EAI7B,UAAU,CAAA,EAAA,CAAA,CAAA;;4FAET,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBAJjC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,OAAO;AAChB,oBAAA,OAAO,EAAE,CAAC,UAAU,EAAE,GAAG,OAAO,CAAC;AAClC,iBAAA;;;ACZD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"odx-angular-components-daterangepicker.mjs","sources":["../../../../libs/angular/components/daterangepicker/src/lib/daterangepicker.config.ts","../../../../libs/angular/components/daterangepicker/src/lib/utils/get-daterangepicker-input-pattern.ts","../../../../libs/angular/components/daterangepicker/src/lib/utils/get-daterangepicker-input-value-as-date.ts","../../../../libs/angular/components/daterangepicker/src/lib/directives/daterangepicker-input-control.directive.ts","../../../../libs/angular/components/daterangepicker/src/lib/daterangepicker.component.ts","../../../../libs/angular/components/daterangepicker/src/lib/daterangepicker.component.html","../../../../libs/angular/components/daterangepicker/src/lib/range.validator.ts","../../../../libs/angular/components/daterangepicker/src/lib/required.validator.ts","../../../../libs/angular/components/daterangepicker/src/lib/daterangepicker.module.ts","../../../../libs/angular/components/daterangepicker/src/odx-angular-components-daterangepicker.ts"],"sourcesContent":["import { createConfigTokens } from '@odx/angular/utils';\nimport { DaterangepickerInputDateOrder } from './models';\n\nexport interface DaterangepickerConfig {\n /**\n * Date's order ('DMY' | 'MDY' | 'YMD').\n * @default DaterangepickerInputDateOrder.DMY\n */\n inputDateOrder: DaterangepickerInputDateOrder;\n /**\n * Single-character date's separator (dot, slash etc.).\n * @default '.'\n */\n inputDateSeparator: string;\n}\n\n/**\n * Tools for injecting and providing the daterangepicker configuration with default configuration for the daterangepicker.\n *\n * @example\n * // Providing custom daterangepicker configuration.\n * ```ts\n * @Component({\n * providers: [provideDaterangepickerConfig({ inputDateOrder: DaterangepickerInputDateOrder.MDY, inputDateSeparator: '/'})]\n * })\n * export class MyComponent {}\n *\n * // Injecting the daterangepicker configuration.\n * ```ts\n * @Component({})\n * export class MyComponent {\n * constructor(@Inject(injectDaterangepickerConfig()) private readonly daterangepickerConfig: DaterangepickerConfig) {}\n * }\n * ```\n */\nexport const { DaterangepickerConfig, DaterangepickerDefaultConfig, injectDaterangepickerConfig, provideDaterangepickerConfig } = createConfigTokens(\n 'Daterangepicker',\n '@odx/angular/components/daterangepicker',\n {\n inputDateOrder: DaterangepickerInputDateOrder.DMY,\n inputDateSeparator: '.',\n },\n);\n","import { DaterangepickerConfig } from '../daterangepicker.config';\nimport { DaterangepickerInputDateOrder, DaterangepickerInputFormat, DaterangepickerInputMask, DaterangepickerInputPattern } from '../models';\n\nfunction getDaterangepickerInputPattern({ inputDateOrder, inputDateSeparator }: DaterangepickerConfig, pattern: DaterangepickerInputPattern): string {\n const patternList: Record<DaterangepickerInputDateOrder, string> = {\n [DaterangepickerInputDateOrder.DMY]: `${pattern.DAYS}${inputDateSeparator}${pattern.MONTH}${inputDateSeparator}${pattern.YEAR}`,\n [DaterangepickerInputDateOrder.MDY]: `${pattern.MONTH}${inputDateSeparator}${pattern.DAYS}${inputDateSeparator}${pattern.YEAR}`,\n [DaterangepickerInputDateOrder.YMD]: `${pattern.YEAR}${inputDateSeparator}${pattern.MONTH}${inputDateSeparator}${pattern.DAYS}`,\n };\n\n return patternList[inputDateOrder];\n}\n\n/** @internal */\nexport function getDaterangepickerInputFormat(config: DaterangepickerConfig): string {\n return getDaterangepickerInputPattern(config, DaterangepickerInputFormat);\n}\n\n/** @internal */\nexport function getDaterangepickerInputMask(config: DaterangepickerConfig): string {\n return getDaterangepickerInputPattern(config, DaterangepickerInputMask);\n}\n","import { isValid, toDate } from 'date-fns';\nimport { DaterangepickerConfig } from '../daterangepicker.config';\nimport { DaterangepickerInputDateOrder } from '../models';\n\ninterface DateCandidateInterface {\n month: string;\n day: string;\n year: string;\n}\n\nconst functionList: Record<DaterangepickerInputDateOrder, (splittedValue: string[]) => DateCandidateInterface> = {\n [DaterangepickerInputDateOrder.DMY]: (splittedValue: string[]) => {\n const [day, month, year] = splittedValue;\n return { month, day, year };\n },\n [DaterangepickerInputDateOrder.MDY]: (splittedValue: string[]) => {\n const [month, day, year] = splittedValue;\n return { month, day, year };\n },\n [DaterangepickerInputDateOrder.YMD]: (splittedValue: string[]) => {\n const [year, month, day] = splittedValue;\n return { month, day, year };\n },\n};\n\nfunction getDateCandidate({ inputDateOrder, inputDateSeparator }: DaterangepickerConfig, value: string): string | null {\n const splittedValue = value.split(inputDateSeparator);\n\n const { month, day, year }: DateCandidateInterface = functionList[inputDateOrder](splittedValue);\n\n const isDateCandidateInvalid = !month || !day || !year;\n\n return isDateCandidateInvalid ? null : `${month}.${day}.${year}`;\n}\n\n/** @internal */\nexport function getDaterangepickerInputValueAsDate(config: DaterangepickerConfig, value: string): Date | null {\n const dateCandidate: string | null = getDateCandidate(config, value);\n\n if (!dateCandidate) return null;\n\n const date = toDate(Date.parse(dateCandidate));\n\n return isValid(date) ? date : null;\n}\n","import { Directive, EventEmitter, HostListener, inject, Output } from '@angular/core';\nimport { ReadonlyController, WithTabIndex } from '@odx/angular';\nimport { InputControlDirective } from '@odx/angular/cdk/custom-form-control';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { NgxMaskConfig, NgxMaskPipe, provideNgxMask } from 'ngx-mask';\nimport { distinctUntilChanged, fromEvent, map, tap } from 'rxjs';\nimport { injectDaterangepickerConfig } from '../daterangepicker.config';\nimport { getDaterangepickerInputFormat, getDaterangepickerInputMask, getDaterangepickerInputValueAsDate } from '../utils';\n\n/**\n * Enhances an input element to support date range picking, applying an input mask for date formatting\n * and managing focus events. This directive is typically used within a date range picker to provide\n * consistent and configurable input behavior. Extends the `InputControlDirective` to provide form control.\n * Has host directive `WithTabIndex` to manage the tab index attribute of the input element.\n *\n * @see {InputControlDirective}\n */\n@CSSComponent('daterangepicker__control')\n@Directive({\n standalone: true,\n selector: 'input[odxDaterangepickerControl],input[odxDaterangepickerStartDateControl], input[odxDaterangepickerEndDateControl]',\n host: {\n '[attr.readonly]': 'readonlyController?.readonly || null',\n '[attr.placeholder]': 'placeholder',\n },\n providers: [ReadonlyController.connect(), provideNgxMask(), NgxMaskPipe],\n hostDirectives: [WithTabIndex],\n})\nexport class DaterangepickerInputControlDirective extends InputControlDirective {\n private readonly maskConfig: Partial<NgxMaskConfig> = { validation: false, leadZeroDateTime: true };\n\n protected readonly readonlyController = ReadonlyController.inject();\n protected readonly config = injectDaterangepickerConfig();\n protected readonly inputMask = getDaterangepickerInputMask(this.config);\n protected readonly ngxMaskPipe = inject(NgxMaskPipe);\n\n /**\n * Emits an event when the input gains or loses focus, facilitating external event handling.\n *\n * @emits {boolean} - Indicates whether the input is focused.\n */\n @Output()\n public focused = new EventEmitter<boolean>();\n\n /**\n * Captures and processes changes to the input element's value, applying the mask and updating\n * the form control.\n *\n * @emits {string} - The updated value of the input element.\n */\n public override valueChange$ = fromEvent(this.element.nativeElement, 'input').pipe(\n distinctUntilChanged(),\n tap(() => this.applyMask()),\n map(() => this.nativeElementValue),\n );\n\n /**\n * Applies the configured input mask to the native input element's value.\n */\n public applyMask(): void {\n this.nativeElementValue = this.ngxMaskPipe.transform(this.nativeElementValue, this.inputMask, this.maskConfig);\n }\n\n /**\n * Converts the current input value to a Date object based on the configuration's date format.\n *\n * @returns {Date | null} The parsed date object or null if the input does not represent a valid date.\n */\n public get valueAsDate(): Date | null {\n return getDaterangepickerInputValueAsDate(this.config, this.nativeElementValue);\n }\n\n /**\n * Provides the placeholder text for the input, typically the date format in uppercase.\n *\n * @returns {string} The placeholder text for the input.\n */\n public get placeholder(): string {\n return getDaterangepickerInputFormat(this.config).toUpperCase();\n }\n\n @HostListener('focusin')\n protected handleFocusIn(): void {\n this.focused.emit(true);\n }\n\n @HostListener('focusout')\n protected handleFocusOut(): void {\n this.focused.emit(false);\n }\n}\n","import { A11yModule } from '@angular/cdk/a11y';\nimport {\n AfterViewInit,\n booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n ContentChildren,\n ElementRef,\n EventEmitter,\n HostListener,\n input,\n Input,\n Output,\n QueryList,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { detectControllerChanges } from '@odx/angular';\nimport { CustomFormControl } from '@odx/angular/cdk/custom-form-control';\nimport { ActionGroupComponent } from '@odx/angular/components/action-group';\nimport { ButtonComponent } from '@odx/angular/components/button';\nimport { CalendarComponent, CalendarSelectionMode, DateFilter, DateRange, provideCalendarConfig } from '@odx/angular/components/calendar';\nimport { DropdownDirective, DropdownModule } from '@odx/angular/components/dropdown';\nimport { IconComponent } from '@odx/angular/components/icon';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { deferFn, injectElement, Position, untilDestroyed } from '@odx/angular/utils';\nimport { format, startOfDay } from 'date-fns';\nimport { injectDaterangepickerConfig } from './daterangepicker.config';\nimport { DaterangepickerInputControlDirective } from './directives';\nimport { getDaterangepickerInputFormat } from './utils';\n\n/**\n * A component for selecting a date range, integrated with dropdowns and input fields for start and end dates.\n * It supports custom configurations for minimum, maximum dates, and date filters. The component also handles\n * the dropdown's behavior for date selection and applies date formats automatically based on configuration.\n * The component extends the `CustomFormControl` class to provide form control functionality.\n *\n * @see {CustomFormControl}\n */\n@CSSComponent('daterangepicker')\n@Component({\n selector: 'odx-daterangepicker',\n standalone: true,\n imports: [A11yModule, ActionGroupComponent, ButtonComponent, CalendarComponent, DropdownModule, IconComponent],\n templateUrl: './daterangepicker.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [\n provideCalendarConfig({\n displayAdjacentDays: false,\n selectionMode: CalendarSelectionMode.DateRange,\n }),\n ],\n})\nexport class DaterangepickerComponent extends CustomFormControl<DateRange | null> implements AfterViewInit {\n protected readonly takeUntilDestroyed = untilDestroyed();\n\n protected readonly config = injectDaterangepickerConfig();\n\n public readonly element = injectElement();\n\n /**\n * Indicates whether the dropdown part of the date range picker is open.\n *\n * @type {boolean}\n */\n public get isOpen(): boolean {\n return !!this.dropdown.isOpen;\n }\n\n /**\n * Represents today's date, used for default selections and validations.\n *\n * @type {Date}\n */\n public today = new Date();\n\n /**\n * A function that defines additional rules for disabled dates within the picker.\n *\n * @type {DateFilter | null}\n * @default null\n *\n * @example\n * ```ts\n * // Disables all Wednesdays in the picker.\n * const filterFn: DateFilter = (date: Date) => date.getDay() !== 3;\n * ```\n */\n @Input()\n public filterFn: DateFilter | null = null;\n\n /**\n * The earliest date that can be selected in the picker.\n *\n * @type {Date | null}\n * @default null\n */\n @Input()\n public minDate: Date | null = null;\n\n /**\n * The latest date that can be selected in the picker.\n *\n * @type {Date | null}\n * @default null\n */\n @Input()\n public maxDate: Date | null = null;\n\n /**\n * Position of the dropdown relative to the input fields.\n *\n * @type {Position}\n * @default Position.BOTTOM\n */\n @Input()\n public dropdownPosition: Position = 'bottom';\n\n /**\n * When set to true, the select will display a reset button.\n *\n * @type {boolean}\n * @default false\n */\n public clearable = input(false, { transform: booleanAttribute });\n\n /**\n * Emits the selected date range when it changes.\n *\n * @emits {DateRange}\n */\n @Output()\n public selectedChange = new EventEmitter<DateRange>();\n\n /**\n * Directive managing the dropdown functionality.\n *\n * @type {DropdownDirective}\n */\n @ViewChild(DropdownDirective)\n public dropdown!: DropdownDirective;\n\n /**\n * Reference to the element triggering the dropdown.\n *\n * @type {ElementRef<HTMLElement>}\n */\n @ViewChild('dropdownTrigger', { read: ElementRef, static: true })\n public dropdownTriggerElement!: ElementRef<HTMLElement>;\n\n /**\n * Query list of the input controls within the date range picker.\n *\n * @type {QueryList<DaterangepickerInputControlDirective>}\n */\n @ContentChildren(DaterangepickerInputControlDirective)\n public dateFields!: QueryList<DaterangepickerInputControlDirective>;\n\n /**\n * Reference to the element mirroring the start date input field.\n *\n * @type {ElementRef<HTMLElement>}\n */\n @ViewChild('startDateMirror', { read: ElementRef, static: true })\n public startDateMirror!: ElementRef<HTMLElement>;\n\n /**\n * Reference to the element mirroring the end date input field.\n *\n * @type {ElementRef<HTMLElement>}\n */\n @ViewChild('endDateMirror', { read: ElementRef, static: true })\n public endDateMirror!: ElementRef<HTMLElement>;\n\n /**\n * The input control for the start date.\n *\n * @type {DaterangepickerInputControlDirective | undefined}\n */\n public get startDateField(): DaterangepickerInputControlDirective | undefined {\n const [startDate, _endDate] = this.dateFields;\n return startDate;\n }\n\n /**\n * The input control for the end date.\n *\n * @type {DaterangepickerInputControlDirective | undefined}\n */\n public get endDateField(): DaterangepickerInputControlDirective | undefined {\n const [_startDate, endDate] = this.dateFields;\n return endDate;\n }\n\n constructor() {\n super(null);\n detectControllerChanges(this).subscribe();\n }\n\n public ngAfterViewInit(): void {\n this.updateWidth(this.startDateField, this.startDateMirror);\n this.updateWidth(this.endDateField, this.endDateMirror);\n this.handleDateFieldChanges();\n this.handleDateFieldFocus();\n\n deferFn(() => {\n if (!this.value || !this.value.start || !this.value.end) return;\n this.updateStartDateField(startOfDay(this.value.start));\n this.updateEndDateField(startOfDay(this.value.end));\n });\n }\n\n /**\n * Selects a date range, updates the form value, and emits the selected range.\n *\n * @param {DateRange | null} value - The date range to select.\n */\n public selectDateRange(value: DateRange | null): void {\n if (!value || !value.start || !value.end) return;\n\n this.updateInternalValue(value);\n\n this.selectedChange.emit(value);\n this.dropdown.close();\n }\n\n public reset(): void {\n this.updateInternalValue({ start: null, end: null });\n }\n\n protected isEmpty(value: DateRange | null): boolean {\n return !value || !value.start || !value.end;\n }\n\n protected updateInternalValue(value: DateRange): void {\n this.updateValue(value);\n this.updateStartDateField(value.start);\n this.updateEndDateField(value.end);\n }\n\n protected handleDateFieldChanges(): void {\n this.startDateField?.valueChange$.pipe(this.takeUntilDestroyed()).subscribe((value: string) => {\n this.updateValue({ start: this.startDateField?.valueAsDate ?? null, end: this.endDateField?.valueAsDate ?? null });\n this.updateWidth(this.startDateField, this.startDateMirror, value);\n });\n this.endDateField?.valueChange$.pipe(this.takeUntilDestroyed()).subscribe((value: string) => {\n this.updateValue({ start: this.startDateField?.valueAsDate ?? null, end: this.endDateField?.valueAsDate ?? null });\n this.updateWidth(this.endDateField, this.endDateMirror, value);\n });\n }\n\n protected updateWidth(target: DaterangepickerInputControlDirective | undefined, source: ElementRef<HTMLElement>, value = ''): void {\n const compensationPx = 2;\n source.nativeElement.textContent = value || target?.placeholder || null;\n if (target) {\n deferFn(() => (target.element.nativeElement.style.width = `${source.nativeElement.offsetWidth + compensationPx}px`));\n }\n }\n\n protected handleDateFieldFocus(): void {\n this.startDateField?.focused.pipe(this.takeUntilDestroyed()).subscribe((isFocused) => {\n if (!isFocused) {\n this.onTouched();\n }\n if (this.isOpen) {\n this.dropdown.close();\n }\n });\n this.endDateField?.focused.pipe(this.takeUntilDestroyed()).subscribe((isFocused) => {\n if (!isFocused) {\n this.onTouched();\n }\n if (this.isOpen) {\n this.dropdown.close();\n }\n });\n }\n\n @HostListener('keydown.alt.ArrowDown', ['$event'])\n protected openDaterangepicker(event: KeyboardEvent) {\n event.stopPropagation();\n\n if (this.isReadonly || this.isDisabled) return;\n\n this.dropdown.open(event);\n }\n\n private updateStartDateField(date: Date | null): void {\n if (!this.startDateField) return;\n\n const dateFormat = getDaterangepickerInputFormat(this.config);\n this.startDateField.nativeElementValue = date ? format(date, dateFormat) : '';\n this.updateWidth(this.startDateField, this.startDateMirror, date ? format(date, dateFormat) : '');\n }\n\n private updateEndDateField(date: Date | null): void {\n if (!this.endDateField) return;\n\n const dateFormat = getDaterangepickerInputFormat(this.config);\n this.endDateField.nativeElementValue = date ? format(date, dateFormat) : '';\n this.updateWidth(this.endDateField, this.endDateMirror, date ? format(date, dateFormat) : '');\n }\n}\n","<span #startDateMirror role=\"none\" class=\"odx-daterangepicker__mirror\"></span>\n<ng-content select=\"input[odxDaterangepickerStartDateControl]\" />\n<span role=\"none\" class=\"odx-daterangepicker__separator\">–</span>\n<span #endDateMirror role=\"none\" class=\"odx-daterangepicker__mirror\"></span>\n<ng-content select=\"input[odxDaterangepickerEndDateControl]\" />\n\n<odx-action-group class=\"odx-daterangepicker__trigger-wrapper\">\n @if (clearable() && !isEmpty(value)) {\n <button class=\"odx-daterangepicker__clear\" (click)=\"reset()\" odxButton size=\"small\" aria-label=\"Reset time\">\n <odx-icon name=\"close\" iconSet=\"core\" />\n </button>\n }\n <button\n #dropdownTrigger\n odxButton\n size=\"small\"\n variant=\"ghost\"\n class=\"odx-daterangepicker__trigger\"\n [odxDropdown]=\"calendarOverlay\"\n [odxDropdownOptions]=\"{ position: dropdownPosition }\"\n [odxDropdownTriggerElement]=\"dropdownTriggerElement.nativeElement\"\n [odxDropdownHost]=\"null\"\n [odxDropdownReferenceElement]=\"element.nativeElement\"\n (odxDropdownBeforeClose)=\"onTouched()\"\n >\n <odx-icon name=\"calendar\" />\n </button>\n <ng-content select=\"[odxButton]\" ngProjectAs=\"[odxButton]\" />\n</odx-action-group>\n\n<ng-template #calendarOverlay>\n <odx-calendar\n [selectedDate]=\"today\"\n [selectedDateRange]=\"value\"\n (selectedDateRangeChange)=\"selectDateRange($event)\"\n [filterFn]=\"filterFn\"\n [minDate]=\"minDate\"\n [maxDate]=\"maxDate\"\n cdkTrapFocus\n cdkTrapFocusAutoCapture\n />\n</ng-template>\n","import { Directive, forwardRef } from '@angular/core';\nimport { FormControl, NG_VALIDATORS } from '@angular/forms';\nimport { DateRange, validateDaterange } from '@odx/angular/components/calendar';\n\n/**\n * A validation directive to be used with date range picker controls. This validator ensures that the date range\n * selected is valid, meaning the start date must occur on or before the end date. If the date range is invalid,\n * this validator will provide a validation error that can be used to display an appropriate message or to style\n * the form control.\n *\n * The validator is designed to be used with form controls that manage `DateRange` objects in Angular forms.\n */\n@Directive({\n standalone: true,\n selector: 'odx-daterangepicker[formControlName], odx-daterangepicker[formControl], odx-daterangepicker[ngModel]',\n providers: [\n {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => DaterangepickerRangeValidator),\n multi: true,\n },\n ],\n})\nexport class DaterangepickerRangeValidator {\n /**\n * Performs the validation check on the form control's value.\n *\n * @param {FormControl<DateRange | null>} control - The form control instance associated with the date range input.\n * @returns {ValidationErrors | null} An object expressing validation errors if the range is invalid,\n * or null if the range is valid. The object returned in case of a validation error is `{ invalidRange: true }`.\n */\n public validate({ value }: FormControl<DateRange | null>) {\n const valuesArePresent = value && value.start && value.end;\n\n const isValidRange = value && value.start && value.end && validateDaterange(value.start, value.end);\n\n return (\n valuesArePresent &&\n !isValidRange && {\n invalidRange: true,\n }\n );\n }\n}\n","import { Directive, forwardRef } from '@angular/core';\nimport { FormControl, NG_VALIDATORS } from '@angular/forms';\nimport { DateRange } from '@odx/angular/components/calendar';\n\n/**\n * A validation directive to ensure that both start and end dates are provided for a date range picker.\n * This validator is essential for forms where the date range is a required field. It checks that both the\n * start and end date values exist in the date range object. If one or both dates are missing, it flags the\n * form control as having a validation error.\n */\n@Directive({\n standalone: true,\n selector: 'odx-daterangepicker[required][formControlName], odx-daterangepicker[required][formControl], odx-daterangepicker[required][ngModel]',\n providers: [\n {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => DaterangepickerRequiredValidator),\n multi: true,\n },\n ],\n})\nexport class DaterangepickerRequiredValidator {\n /**\n * Validates the form control associated with the date range input.\n * Checks if both start and end dates are present. If either is missing, it returns a validation error.\n *\n * @param {FormControl<DateRange | null>} control - The form control instance that contains the date range value.\n * @returns {ValidationErrors | null} An object expressing validation errors if the range is incomplete,\n * or null if the range is fully specified. If validation fails, the object returned is `{ required: true }`.\n */\n public validate({ value }: FormControl<DateRange | null>) {\n const isValid = value && value.start && value.end;\n\n return (\n !isValid && {\n required: true,\n }\n );\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { DaterangepickerComponent } from './daterangepicker.component';\nimport { DaterangepickerInputControlDirective } from './directives';\nimport { DaterangepickerRangeValidator } from './range.validator';\nimport { DaterangepickerRequiredValidator } from './required.validator';\n\nconst modules = [DaterangepickerComponent, DaterangepickerInputControlDirective, DaterangepickerRangeValidator, DaterangepickerRequiredValidator];\n\n@NgModule({\n imports: modules,\n exports: [CoreModule, ...modules],\n})\nexport class DaterangepickerModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["DaterangepickerInputDateOrder","DaterangepickerInputFormat","DaterangepickerInputMask","i1"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAgBA;;;;;;;;;;;;;;;;;;AAkBG;AACU,MAAA,EAAE,qBAAqB,EAAE,4BAA4B,EAAE,2BAA2B,EAAE,4BAA4B,EAAE,GAAG,kBAAkB,CAClJ,iBAAiB,EACjB,yCAAyC,EACzC;IACE,cAAc,EAAEA,wBAA6B,CAAC,GAAG;AACjD,IAAA,kBAAkB,EAAE,GAAG;AACxB,CAAA;;ACtCH,SAAS,8BAA8B,CAAC,EAAE,cAAc,EAAE,kBAAkB,EAAyB,EAAE,OAAoC,EAAA;AACzI,IAAA,MAAM,WAAW,GAAkD;QACjE,CAACA,wBAA6B,CAAC,GAAG,GAAG,CAAG,EAAA,OAAO,CAAC,IAAI,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,KAAK,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,IAAI,CAAE,CAAA;QAC/H,CAACA,wBAA6B,CAAC,GAAG,GAAG,CAAG,EAAA,OAAO,CAAC,KAAK,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,IAAI,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,IAAI,CAAE,CAAA;QAC/H,CAACA,wBAA6B,CAAC,GAAG,GAAG,CAAG,EAAA,OAAO,CAAC,IAAI,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,KAAK,CAAA,EAAG,kBAAkB,CAAG,EAAA,OAAO,CAAC,IAAI,CAAE,CAAA;KAChI;AAED,IAAA,OAAO,WAAW,CAAC,cAAc,CAAC;AACpC;AAEA;AACM,SAAU,6BAA6B,CAAC,MAA6B,EAAA;AACzE,IAAA,OAAO,8BAA8B,CAAC,MAAM,EAAE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AQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,OAAO;AAChB,oBAAA,OAAO,EAAE,CAAC,UAAU,EAAE,GAAG,OAAO,CAAC;AAClC,iBAAA;;;ACZD;;AAEG;;;;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __decorate } from 'tslib';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { inject, ChangeDetectorRef, ViewContainerRef, Injector, EventEmitter, booleanAttribute,
|
|
3
|
+
import { inject, ChangeDetectorRef, ViewContainerRef, Injector, EventEmitter, booleanAttribute, Output, Input, Directive, HostListener, ChangeDetectionStrategy, ViewEncapsulation, Component, NgModule } from '@angular/core';
|
|
4
4
|
import * as i1 from '@odx/angular';
|
|
5
5
|
import { CoreModule } from '@odx/angular';
|
|
6
6
|
import { A11yModule } from '@odx/angular/cdk/a11y';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __decorate } from 'tslib';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { makeEnvironmentProviders,
|
|
3
|
+
import { makeEnvironmentProviders, ViewEncapsulation, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
4
4
|
import { CoreModule } from '@odx/angular';
|
|
5
5
|
import { DynamicViewDirective } from '@odx/angular/cdk/dynamic-view';
|
|
6
6
|
import { ButtonComponent } from '@odx/angular/components/button';
|
|
@@ -2,12 +2,12 @@ import { __decorate, __metadata } from 'tslib';
|
|
|
2
2
|
import * as i1 from '@angular/common';
|
|
3
3
|
import { CommonModule } from '@angular/common';
|
|
4
4
|
import * as i0 from '@angular/core';
|
|
5
|
-
import {
|
|
5
|
+
import { Input, ViewEncapsulation, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
6
6
|
import { DynamicViewDirective } from '@odx/angular/cdk/dynamic-view';
|
|
7
7
|
import { LinkDirective } from '@odx/angular/components/link';
|
|
8
8
|
import { LogoDirective } from '@odx/angular/components/logo';
|
|
9
9
|
import { CSSModifier, CSSComponent } from '@odx/angular/internal';
|
|
10
|
-
import {
|
|
10
|
+
import { TranslatePipe, provideTranslations } from '@odx/angular/internal/translate';
|
|
11
11
|
import { createConfigTokens, buildWebsiteUrl, injectElement } from '@odx/angular/utils';
|
|
12
12
|
import { of, combineLatest, map } from 'rxjs';
|
|
13
13
|
|