@odx/angular 12.21.4 → 12.21.6
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/components/timepicker/lib/directives/timepicker-input-control.directive.d.ts +6 -0
- package/esm2022/components/timepicker/lib/directives/timepicker-input-control.directive.mjs +11 -1
- package/esm2022/components/timepicker/lib/timepicker.component.mjs +10 -7
- package/fesm2022/odx-angular-animations.mjs.map +1 -1
- package/fesm2022/odx-angular-breakpoints.mjs +1 -1
- package/fesm2022/odx-angular-breakpoints.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-a11y.mjs +1 -1
- package/fesm2022/odx-angular-cdk-a11y.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-active-indicator.mjs +1 -1
- package/fesm2022/odx-angular-cdk-active-indicator.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-autocomplete-control.mjs +1 -1
- package/fesm2022/odx-angular-cdk-autocomplete-control.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-checkbox-control.mjs +1 -1
- 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-connected-overlay.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-custom-form-control.mjs +1 -1
- package/fesm2022/odx-angular-cdk-custom-form-control.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-date-input.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-dynamic-view.mjs +1 -1
- package/fesm2022/odx-angular-cdk-dynamic-view.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-event-plugins.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-expandable.mjs +1 -1
- package/fesm2022/odx-angular-cdk-expandable.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-option-control.mjs +1 -1
- package/fesm2022/odx-angular-cdk-option-control.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-radio-group-control.mjs +1 -1
- package/fesm2022/odx-angular-cdk-radio-group-control.mjs.map +1 -1
- package/fesm2022/odx-angular-cdk-scrollable.mjs.map +1 -1
- package/fesm2022/odx-angular-components-accordion.mjs +1 -1
- package/fesm2022/odx-angular-components-accordion.mjs.map +1 -1
- package/fesm2022/odx-angular-components-action-group.mjs +1 -1
- package/fesm2022/odx-angular-components-action-group.mjs.map +1 -1
- package/fesm2022/odx-angular-components-anchor-navigation.mjs +1 -1
- package/fesm2022/odx-angular-components-anchor-navigation.mjs.map +1 -1
- package/fesm2022/odx-angular-components-area-header.mjs +1 -1
- package/fesm2022/odx-angular-components-area-header.mjs.map +1 -1
- package/fesm2022/odx-angular-components-autocomplete.mjs +1 -1
- package/fesm2022/odx-angular-components-autocomplete.mjs.map +1 -1
- package/fesm2022/odx-angular-components-avatar.mjs +1 -1
- package/fesm2022/odx-angular-components-avatar.mjs.map +1 -1
- package/fesm2022/odx-angular-components-badge.mjs +1 -1
- package/fesm2022/odx-angular-components-badge.mjs.map +1 -1
- package/fesm2022/odx-angular-components-bar.mjs +1 -1
- package/fesm2022/odx-angular-components-bar.mjs.map +1 -1
- package/fesm2022/odx-angular-components-breadcrumbs.mjs +1 -1
- package/fesm2022/odx-angular-components-breadcrumbs.mjs.map +1 -1
- package/fesm2022/odx-angular-components-button-group.mjs +1 -1
- package/fesm2022/odx-angular-components-button-group.mjs.map +1 -1
- package/fesm2022/odx-angular-components-button.mjs +1 -1
- package/fesm2022/odx-angular-components-button.mjs.map +1 -1
- package/fesm2022/odx-angular-components-calendar.mjs +2 -2
- package/fesm2022/odx-angular-components-calendar.mjs.map +1 -1
- package/fesm2022/odx-angular-components-card.mjs +2 -2
- package/fesm2022/odx-angular-components-card.mjs.map +1 -1
- package/fesm2022/odx-angular-components-checkbox.mjs +1 -1
- package/fesm2022/odx-angular-components-checkbox.mjs.map +1 -1
- package/fesm2022/odx-angular-components-chip.mjs +1 -1
- package/fesm2022/odx-angular-components-chip.mjs.map +1 -1
- package/fesm2022/odx-angular-components-circular-progress.mjs +1 -1
- package/fesm2022/odx-angular-components-circular-progress.mjs.map +1 -1
- package/fesm2022/odx-angular-components-content-box.mjs +1 -1
- package/fesm2022/odx-angular-components-content-box.mjs.map +1 -1
- package/fesm2022/odx-angular-components-data-table.mjs +1 -1
- package/fesm2022/odx-angular-components-data-table.mjs.map +1 -1
- package/fesm2022/odx-angular-components-datepicker.mjs +2 -2
- package/fesm2022/odx-angular-components-datepicker.mjs.map +1 -1
- package/fesm2022/odx-angular-components-daterangepicker.mjs +3 -3
- package/fesm2022/odx-angular-components-daterangepicker.mjs.map +1 -1
- package/fesm2022/odx-angular-components-dropdown.mjs +1 -1
- package/fesm2022/odx-angular-components-dropdown.mjs.map +1 -1
- package/fesm2022/odx-angular-components-error-page.mjs +1 -1
- package/fesm2022/odx-angular-components-error-page.mjs.map +1 -1
- package/fesm2022/odx-angular-components-footer.mjs +2 -2
- package/fesm2022/odx-angular-components-footer.mjs.map +1 -1
- package/fesm2022/odx-angular-components-form-field.mjs +1 -1
- 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-navigation.mjs.map +1 -1
- package/fesm2022/odx-angular-components-header.mjs +1 -1
- package/fesm2022/odx-angular-components-header.mjs.map +1 -1
- package/fesm2022/odx-angular-components-icon.mjs +1 -1
- package/fesm2022/odx-angular-components-icon.mjs.map +1 -1
- package/fesm2022/odx-angular-components-inline-message.mjs +1 -1
- package/fesm2022/odx-angular-components-inline-message.mjs.map +1 -1
- package/fesm2022/odx-angular-components-link.mjs.map +1 -1
- package/fesm2022/odx-angular-components-list.mjs +2 -2
- package/fesm2022/odx-angular-components-list.mjs.map +1 -1
- package/fesm2022/odx-angular-components-loading-spinner.mjs +1 -1
- package/fesm2022/odx-angular-components-loading-spinner.mjs.map +1 -1
- package/fesm2022/odx-angular-components-logo.mjs +1 -1
- package/fesm2022/odx-angular-components-logo.mjs.map +1 -1
- package/fesm2022/odx-angular-components-main-menu.mjs +2 -2
- package/fesm2022/odx-angular-components-main-menu.mjs.map +1 -1
- package/fesm2022/odx-angular-components-mainfilter-group.mjs +1 -1
- package/fesm2022/odx-angular-components-mainfilter-group.mjs.map +1 -1
- package/fesm2022/odx-angular-components-menu.mjs +1 -1
- package/fesm2022/odx-angular-components-menu.mjs.map +1 -1
- package/fesm2022/odx-angular-components-modal.mjs +1 -1
- package/fesm2022/odx-angular-components-modal.mjs.map +1 -1
- package/fesm2022/odx-angular-components-navigation-back.mjs +1 -1
- package/fesm2022/odx-angular-components-navigation-back.mjs.map +1 -1
- package/fesm2022/odx-angular-components-notification-testing.mjs.map +1 -1
- package/fesm2022/odx-angular-components-notification.mjs +3 -3
- package/fesm2022/odx-angular-components-notification.mjs.map +1 -1
- package/fesm2022/odx-angular-components-paginator.mjs +1 -1
- package/fesm2022/odx-angular-components-paginator.mjs.map +1 -1
- package/fesm2022/odx-angular-components-progress.mjs +1 -1
- package/fesm2022/odx-angular-components-progress.mjs.map +1 -1
- package/fesm2022/odx-angular-components-radio-group.mjs +1 -1
- package/fesm2022/odx-angular-components-radio-group.mjs.map +1 -1
- package/fesm2022/odx-angular-components-rail-navigation.mjs +1 -1
- package/fesm2022/odx-angular-components-rail-navigation.mjs.map +1 -1
- package/fesm2022/odx-angular-components-rich-list.mjs +1 -1
- package/fesm2022/odx-angular-components-rich-list.mjs.map +1 -1
- package/fesm2022/odx-angular-components-search-bar.mjs.map +1 -1
- package/fesm2022/odx-angular-components-select.mjs +1 -1
- package/fesm2022/odx-angular-components-select.mjs.map +1 -1
- package/fesm2022/odx-angular-components-slider.mjs +1 -1
- package/fesm2022/odx-angular-components-slider.mjs.map +1 -1
- package/fesm2022/odx-angular-components-spinbox.mjs +1 -1
- package/fesm2022/odx-angular-components-spinbox.mjs.map +1 -1
- package/fesm2022/odx-angular-components-switch.mjs +1 -1
- 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-tab-bar.mjs.map +1 -1
- package/fesm2022/odx-angular-components-table.mjs +1 -1
- package/fesm2022/odx-angular-components-table.mjs.map +1 -1
- package/fesm2022/odx-angular-components-timepicker.mjs +21 -9
- package/fesm2022/odx-angular-components-timepicker.mjs.map +1 -1
- package/fesm2022/odx-angular-components-toast.mjs +1 -1
- package/fesm2022/odx-angular-components-toast.mjs.map +1 -1
- package/fesm2022/odx-angular-components-toggle-button-group.mjs +1 -1
- package/fesm2022/odx-angular-components-toggle-button-group.mjs.map +1 -1
- package/fesm2022/odx-angular-components-tooltip.mjs +1 -1
- package/fesm2022/odx-angular-components-tooltip.mjs.map +1 -1
- package/fesm2022/odx-angular-components-wizard.mjs +1 -1
- package/fesm2022/odx-angular-components-wizard.mjs.map +1 -1
- package/fesm2022/odx-angular-internal-translate.mjs.map +1 -1
- package/fesm2022/odx-angular-internal.mjs.map +1 -1
- package/fesm2022/odx-angular-localization.mjs.map +1 -1
- package/fesm2022/odx-angular-rxjs.mjs.map +1 -1
- package/fesm2022/odx-angular-sdk.mjs.map +1 -1
- package/fesm2022/odx-angular-theming.mjs.map +1 -1
- package/fesm2022/odx-angular-utils.mjs.map +1 -1
- package/fesm2022/odx-angular.mjs +2 -2
- package/fesm2022/odx-angular.mjs.map +1 -1
- package/package.json +7 -7
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odx-angular-components-daterangepicker.mjs","sources":["../../../../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 { Directive, EventEmitter, HostListener, inject, Output } from '@angular/core';\nimport { ReadonlyController, WithTabIndex } from '@odx/angular';\nimport { InputControlDirective } from '@odx/angular/cdk/custom-form-control';\nimport { getDateInputFormat, getDateInputValueAsDate, injectDateConfig } from '@odx/angular/cdk/date-input';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { NgxMaskDirective, provideNgxMask } from 'ngx-mask';\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({ validation: false, leadZeroDateTime: true })],\n hostDirectives: [WithTabIndex, NgxMaskDirective],\n})\nexport class DaterangepickerInputControlDirective extends InputControlDirective {\n protected readonly readonlyController = ReadonlyController.inject();\n protected readonly config = injectDateConfig();\n public readonly ngxMaskDirective = inject(NgxMaskDirective);\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 * 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 getDateInputValueAsDate(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 getDateInputFormat(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 { getDateInputFormat, getDateInputMask, initNgxMask, injectDateConfig } from '@odx/angular/cdk/date-input';\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 { DaterangepickerInputControlDirective } from './directives';\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 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 = injectDateConfig();\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 this.updateInputFields();\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 /**\n * Resets the daterangepicker's value to an empty date range (both start and end as null).\n */\n public reset(): void {\n this.updateInternalValue({ start: null, end: null });\n }\n\n /**\n * @internal\n * Writes a new value to the element.\n * Part of the ControlValueAccessor interface.\n * @param {DateRange | null} value - The new date range value.\n */\n public override writeValue(value: DateRange | null): void {\n super.writeValue(value);\n this.updateInputFields();\n }\n\n /**\n * Opens the date range picker dropdown.\n *\n * @param {KeyboardEvent} event\n */\n @HostListener('keydown.alt.ArrowDown', ['$event'])\n public openDaterangepicker(event?: KeyboardEvent) {\n event?.stopPropagation();\n\n if (this.isReadonly || this.isDisabled) return;\n\n this.dropdown.open(event);\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 initNgxMask(this.startDateField?.ngxMaskDirective, getDateInputMask(this.config));\n initNgxMask(this.endDateField?.ngxMaskDirective, getDateInputMask(this.config));\n this.startDateField?.valueChange$.pipe(this.takeUntilDestroyed()).subscribe((value) => {\n this.updateWidth(this.startDateField, this.startDateMirror, value);\n this.updateValue({ start: this.startDateField?.valueAsDate ?? null, end: this.endDateField?.valueAsDate ?? null });\n });\n this.endDateField?.valueChange$.pipe(this.takeUntilDestroyed()).subscribe((value) => {\n this.updateWidth(this.endDateField, this.endDateMirror, value);\n this.updateValue({ start: this.startDateField?.valueAsDate ?? null, end: this.endDateField?.valueAsDate ?? null });\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 private updateStartDateField(date: Date | null): void {\n if (!this.startDateField) return;\n\n const dateFormat = getDateInputFormat(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 = getDateInputFormat(this.config);\n this.endDateField.nativeElementValue = date ? format(date, dateFormat) : '';\n this.updateWidth(this.endDateField, this.endDateMirror, date ? format(date, dateFormat) : '');\n }\n\n private updateInputFields(): void {\n deferFn(() => {\n if (this.value === null) return this.reset();\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","<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":["i1","i2"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAOA;;;;;;;AAOG;AAYI,IAAM,oCAAoC,GAA1C,MAAM,oCAAqC,SAAQ,qBAAqB,CAAA;AAAxE,IAAA,WAAA,GAAA;;AACc,QAAA,IAAA,CAAA,kBAAkB,GAAG,kBAAkB,CAAC,MAAM,EAAE,CAAC;QACjD,IAAM,CAAA,MAAA,GAAG,gBAAgB,EAAE,CAAC;AAC/B,QAAA,IAAA,CAAA,gBAAgB,GAAG,MAAM,CAAC,gBAAgB,CAAC,CAAC;AAE5D;;;;AAIG;AAEI,QAAA,IAAA,CAAA,OAAO,GAAG,IAAI,YAAY,EAAW,CAAC;AA6B9C,KAAA;AA3BC;;;;AAIG;AACH,IAAA,IAAW,WAAW,GAAA;QACpB,OAAO,uBAAuB,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,kBAAkB,CAAC,CAAC;KACtE;AAED;;;;AAIG;AACH,IAAA,IAAW,WAAW,GAAA;QACpB,OAAO,kBAAkB,CAAC,IAAI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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 { Directive, EventEmitter, HostListener, inject, Output } from '@angular/core';\nimport { ReadonlyController, WithTabIndex } from '@odx/angular';\nimport { InputControlDirective } from '@odx/angular/cdk/custom-form-control';\nimport { getDateInputFormat, getDateInputValueAsDate, injectDateConfig } from '@odx/angular/cdk/date-input';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { NgxMaskDirective, provideNgxMask } from 'ngx-mask';\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({ validation: false, leadZeroDateTime: true })],\n hostDirectives: [WithTabIndex, NgxMaskDirective],\n})\nexport class DaterangepickerInputControlDirective extends InputControlDirective {\n protected readonly readonlyController = ReadonlyController.inject();\n protected readonly config = injectDateConfig();\n public readonly ngxMaskDirective = inject(NgxMaskDirective);\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 * 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 getDateInputValueAsDate(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 getDateInputFormat(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 { getDateInputFormat, getDateInputMask, initNgxMask, injectDateConfig } from '@odx/angular/cdk/date-input';\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 { DaterangepickerInputControlDirective } from './directives';\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 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 = injectDateConfig();\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 this.updateInputFields();\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 /**\n * Resets the daterangepicker's value to an empty date range (both start and end as null).\n */\n public reset(): void {\n this.updateInternalValue({ start: null, end: null });\n }\n\n /**\n * @internal\n * Writes a new value to the element.\n * Part of the ControlValueAccessor interface.\n * @param {DateRange | null} value - The new date range value.\n */\n public override writeValue(value: DateRange | null): void {\n super.writeValue(value);\n this.updateInputFields();\n }\n\n /**\n * Opens the date range picker dropdown.\n *\n * @param {KeyboardEvent} event\n */\n @HostListener('keydown.alt.ArrowDown', ['$event'])\n public openDaterangepicker(event?: KeyboardEvent) {\n event?.stopPropagation();\n\n if (this.isReadonly || this.isDisabled) return;\n\n this.dropdown.open(event);\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 initNgxMask(this.startDateField?.ngxMaskDirective, getDateInputMask(this.config));\n initNgxMask(this.endDateField?.ngxMaskDirective, getDateInputMask(this.config));\n this.startDateField?.valueChange$.pipe(this.takeUntilDestroyed()).subscribe((value) => {\n this.updateWidth(this.startDateField, this.startDateMirror, value);\n this.updateValue({ start: this.startDateField?.valueAsDate ?? null, end: this.endDateField?.valueAsDate ?? null });\n });\n this.endDateField?.valueChange$.pipe(this.takeUntilDestroyed()).subscribe((value) => {\n this.updateWidth(this.endDateField, this.endDateMirror, value);\n this.updateValue({ start: this.startDateField?.valueAsDate ?? null, end: this.endDateField?.valueAsDate ?? null });\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 private updateStartDateField(date: Date | null): void {\n if (!this.startDateField) return;\n\n const dateFormat = getDateInputFormat(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 = getDateInputFormat(this.config);\n this.endDateField.nativeElementValue = date ? format(date, dateFormat) : '';\n this.updateWidth(this.endDateField, this.endDateMirror, date ? format(date, dateFormat) : '');\n }\n\n private updateInputFields(): void {\n deferFn(() => {\n if (this.value === null) return this.reset();\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","<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":["i1","i2"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAOA;;;;;;;AAOG;AAYI,IAAM,oCAAoC,GAA1C,MAAM,oCAAqC,SAAQ,qBAAqB,CAAA;AAAxE,IAAA,WAAA,GAAA;;AACc,QAAA,IAAA,CAAA,kBAAkB,GAAG,kBAAkB,CAAC,MAAM,EAAE;QAChD,IAAA,CAAA,MAAM,GAAG,gBAAgB,EAAE;AAC9B,QAAA,IAAA,CAAA,gBAAgB,GAAG,MAAM,CAAC,gBAAgB,CAAC;AAE3D;;;;AAIG;AAEI,QAAA,IAAA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wB,EAAE,oCAAoC,EAAE,6BAA6B,EAAE,gCAAgC,CAAC;MAMpI,qBAAqB,CAAA;+GAArB,qBAAqB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;AAArB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,qBAAqB,YANjB,wBAAwB,EAAE,oCAAoC,EAAE,6BAA6B,EAAE,gCAAgC,CAAA,EAAA,OAAA,EAAA,CAIpI,UAAU,EAJL,wBAAwB,EAAE,oCAAoC,EAAE,6BAA6B,EAAE,gCAAgC,CAAA,EAAA,CAAA,CAAA;gHAMnI,qBAAqB,EAAA,OAAA,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,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 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odx-angular-components-dropdown.mjs","sources":["../../../../libs/angular/components/dropdown/src/lib/models/close-dropdown-event.ts","../../../../libs/angular/components/dropdown/src/lib/models/dropdown-options.ts","../../../../libs/angular/components/dropdown/src/lib/dropdown.directive.ts","../../../../libs/angular/components/dropdown/src/lib/dropdown.component.ts","../../../../libs/angular/components/dropdown/src/lib/dropdown.component.html","../../../../libs/angular/components/dropdown/src/lib/dropdown.module.ts","../../../../libs/angular/components/dropdown/src/lib/helpers/close-current-dropdown.ts","../../../../libs/angular/components/dropdown/src/odx-angular-components-dropdown.ts"],"sourcesContent":["export class CloseDropdownEvent extends Event {\n public static readonly TYPE = 'odxDropdownClose';\n\n constructor() {\n super(CloseDropdownEvent.TYPE, { bubbles: true });\n }\n}\n","import { ConnectedOverlayOptions } from '@odx/angular/cdk/connected-overlay';\n\nexport type DropdownOptions = Pick<\n ConnectedOverlayOptions,\n 'position' | 'containerClass' | 'enableFallback' | 'matchReferenceWidth' | 'minHeight' | 'offset' | 'showArrow' | 'outerPadding'\n>;\n\nexport const DefaultDropdownOptions: DropdownOptions = {\n position: 'bottom',\n matchReferenceWidth: false,\n enableFallback: true,\n minHeight: 0,\n offset: 6,\n outerPadding: 12,\n};\n","import {\n AfterViewInit,\n booleanAttribute,\n ChangeDetectorRef,\n Directive,\n EventEmitter,\n inject,\n Injector,\n Input,\n OnChanges,\n OnDestroy,\n Output,\n ViewContainerRef,\n} from '@angular/core';\nimport { ConnectedOverlayOptions, ConnectedOverlayRef, ConnectedOverlayService } from '@odx/angular/cdk/connected-overlay';\nimport { DynamicContent } from '@odx/angular/cdk/dynamic-view';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { EventManager, GetProperties, hasChanged, injectElement, NgChanges } from '@odx/angular/utils';\nimport { DropdownComponent } from './dropdown.component';\nimport { DefaultDropdownOptions, DropdownOptions } from './models';\n\nexport const DEFAULT_DROPDOWN_OPEN_TRIGGERS = ['click', 'keydown.enter'];\nexport const DEFAULT_DROPDOWN_CLOSE_TRIGGERS = ['keyup.esc'];\n\n/**\n * Represents a directive that enables dropdown functionality in Angular.\n * This directive handles the opening and closing of a dropdown menu, as well as\n * managing the associated overlay and event handling.\n */\n@CSSComponent('dropdown-host')\n@Directive({\n standalone: true,\n selector: '[odxDropdown]',\n exportAs: 'odxDropdown',\n providers: [EventManager],\n host: {\n '[attr.aria-haspopup]': 'true',\n '[attr.aria-expanded]': 'isOpen',\n },\n})\nexport class DropdownDirective implements AfterViewInit, OnChanges, OnDestroy {\n private readonly changeDetector = inject(ChangeDetectorRef);\n private readonly connectedOverlayService = inject(ConnectedOverlayService);\n private readonly eventManager = inject(EventManager);\n private readonly viewContainer = inject(ViewContainerRef);\n private readonly injector = inject(Injector);\n private overlayRef: ConnectedOverlayRef | null = null;\n\n public readonly element = injectElement();\n\n /**\n * Gets a value indicating whether the dropdown is currently open.\n *\n * @returns {boolean}\n */\n public get isOpen(): boolean {\n return this.overlayRef !== null;\n }\n\n /**\n * The content to be displayed in the dropdown.\n * It can be either a static content or a dynamically loaded content.\n *\n * @type {DynamicContent | null}\n */\n @Input('odxDropdown')\n public content?: DynamicContent | null;\n\n /**\n * Indicates whether the dropdown is disabled or not.\n *\n * @type {boolean}\n * @default false\n */\n @Input({ alias: 'odxDropdownDisabled', transform: booleanAttribute })\n public disabled = false;\n\n /**\n * Indicates whether the loader should be shown.\n *\n * @type {boolean}\n * @default false\n */\n @Input({ alias: 'odxDropdownShowLoader', transform: booleanAttribute })\n public showLoader = false;\n\n /**\n * Determines whether the dropdown should close when a click event occurs outside of it.\n *\n * @type {boolean}\n * @default true\n */\n @Input({ alias: 'odxDropdownClickOutsideActive', transform: booleanAttribute })\n public clickOutsideActive = true;\n\n /**\n * The options to be used when creating the dropdown overlay.\n *\n * @type {Partial<DropdownOptions> | null}\n */\n @Input('odxDropdownOptions')\n public options?: Partial<DropdownOptions> | null;\n\n /**\n * The reference element to which the dropdown is anchored.\n *\n * @type {HTMLElement | null}\n */\n @Input('odxDropdownReferenceElement')\n public referenceElement?: HTMLElement | null;\n\n /**\n * The trigger element that opens the dropdown.\n *\n * @type {HTMLElement | null}\n */\n @Input('odxDropdownTriggerElement')\n public triggerElement?: HTMLElement | null;\n\n /**\n * The host element to which the dropdown is appended.\n *\n * @type {HTMLElement | ViewContainerRef | null}\n */\n @Input('odxDropdownHost')\n public host?: HTMLElement | ViewContainerRef | null = this.viewContainer;\n\n /**\n * The event triggers that open the dropdown.\n *\n * @type {string[] | null}\n * @default DEFAULT_DROPDOWN_OPEN_TRIGGERS\n */\n @Input('odxDropdownOpenTrigger')\n public openTrigger?: string[] | null = DEFAULT_DROPDOWN_OPEN_TRIGGERS;\n\n /**\n * The event triggers that close the dropdown.\n *\n * @type {string[] | null}\n * @default DEFAULT_DROPDOWN_CLOSE_TRIGGERS\n */\n @Input('odxDropdownCloseTrigger')\n public closeTrigger?: string[] | null = DEFAULT_DROPDOWN_CLOSE_TRIGGERS;\n\n /**\n * Event emitter that emits before the dropdown is opened.\n *\n * @emits {void}\n */\n @Output('odxDropdownBeforeOpen')\n public beforeOpen = new EventEmitter<void>();\n\n /**\n * Event emitter that emits after the dropdown is opened.\n *\n * @emits {void}\n */\n @Output('odxDropdownAfterOpen')\n public afterOpen = new EventEmitter<void>();\n\n /**\n * Event emitter that emits before the dropdown is closed.\n *\n * @emits {void}\n */\n @Output('odxDropdownBeforeClose')\n public beforeClose = new EventEmitter<void>();\n\n /**\n * Event emitter that emits after the dropdown is closed.\n *\n * @emits {void}\n */\n @Output('odxDropdownAfterClose')\n public afterClose = new EventEmitter<void>();\n\n public ngAfterViewInit(): void {\n this.eventManager.register(this.openTrigger ?? [], (event) => this.toggle(event), this.triggerElement ?? this.referenceElement);\n this.eventManager.register(this.closeTrigger ?? [], () => this.close(), 'document');\n }\n\n public ngOnDestroy(): void {\n this.close();\n }\n\n public ngOnChanges(changes: NgChanges<DropdownDirective>) {\n if (hasChanged(changes, 'disabled') && this.disabled) {\n this.close();\n }\n if (hasChanged(changes, ['options', 'content', 'showLoader', 'clickOutsideActive'])) {\n this.overlayRef?.update(this.createOverlayOptions());\n }\n }\n\n /**\n * Toggles the state of the dropdown.\n * If the dropdown is open, it will be closed. If it is closed, it will be opened.\n *\n * @param {Event | undefined} event - The optional event that triggered the toggle.\n */\n public toggle(event?: Event): void {\n if (this.isOpen) {\n this.close(event);\n } else {\n this.open(event);\n }\n }\n\n /**\n * Opens the dropdown.\n *\n * @param {Event | undefined} event - The optional event that triggered the open.\n */\n public open(event?: Event) {\n event?.preventDefault();\n if (this.isOpen || !this.content || this.disabled) return;\n this.overlayRef = this.connectedOverlayService.createOverlay(this.referenceElement ?? this.element.nativeElement, this.createOverlayOptions(), {\n host: this.referenceElement?.parentElement ?? this.host,\n injector: this.injector,\n });\n this.changeDetector.markForCheck();\n }\n\n /**\n * Closes the dropdown.\n *\n * @param {Event | undefined} event - The optional event that triggered the close.\n */\n public close(event?: Event) {\n event?.preventDefault();\n this.overlayRef?.close();\n this.overlayRef = null;\n this.changeDetector.markForCheck();\n }\n\n private createOverlayOptions(): Partial<ConnectedOverlayOptions> {\n const containerClass = ['odx-dropdown-overlay', this.options?.containerClass].filter(Boolean).join(' ');\n const context = {\n content: this.content,\n showLoader: this.showLoader,\n clickOutsideActive: this.clickOutsideActive,\n } as Partial<GetProperties<DropdownComponent>>;\n return {\n ...DefaultDropdownOptions,\n ...this.options,\n fallbackAxisSideDirection: 'end',\n containerClass,\n content: DropdownComponent,\n context,\n hooks: {\n beforeOpen: () => this.beforeOpen.emit(),\n afterOpen: () => this.afterOpen.emit(),\n beforeClose: () => this.beforeClose.emit(),\n afterClose: () => this.afterClose.emit(),\n },\n };\n }\n}\n","import { ChangeDetectionStrategy, Component, HostListener, inject, Injector, Input, ViewEncapsulation } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { A11yModule } from '@odx/angular/cdk/a11y';\nimport { DynamicContent, DynamicViewDirective } from '@odx/angular/cdk/dynamic-view';\nimport { LoadingSpinnerModule } from '@odx/angular/components/loading-spinner';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { injectElement } from '@odx/angular/utils';\nimport { DropdownDirective } from './dropdown.directive';\nimport { CloseDropdownEvent } from './models';\n\n/**\n * Represents a dropdown component.\n */\n@CSSComponent('dropdown')\n@Component({\n standalone: true,\n selector: 'odx-dropdown',\n imports: [CoreModule, DynamicViewDirective, LoadingSpinnerModule, A11yModule],\n templateUrl: './dropdown.component.html',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class DropdownComponent {\n protected readonly host = inject(DropdownDirective);\n protected readonly injector = inject(Injector);\n public readonly element = injectElement();\n\n /**\n * The content to be displayed in the dropdown.\n *\n * @type {DynamicContent | null}\n */\n @Input()\n public content?: DynamicContent | null;\n\n /**\n * Indicates whether to show a loader while loading the dropdown content.\n *\n * @type {boolean | undefined}\n */\n @Input()\n public showLoader?: boolean;\n\n /**\n * Indicates whether clicking outside the dropdown should close it.\n *\n * @type {boolean | undefined}\n */\n @Input()\n public clickOutsideActive?: boolean;\n\n @HostListener(CloseDropdownEvent.TYPE)\n protected onDropdownClose(): void {\n this.host.close();\n }\n}\n","<div class=\"odx-dropdown__inner\" [odxLoadingSpinner]=\"showLoader\" [odxClickOutsideActive]=\"clickOutsideActive\" (odxClickOutside)=\"host.close()\" cdkTrapFocus>\n <ng-template [odxDynamicView]=\"content\" [odxDynamicViewInjector]=\"injector\" />\n</div>\n","import { NgModule } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { DropdownDirective } from './dropdown.directive';\n\nconst modules = [DropdownDirective];\n\n@NgModule({\n imports: modules,\n exports: [CoreModule, ...modules],\n})\nexport class DropdownModule {}\n","import { CloseDropdownEvent } from '../models';\n\n/**\n * @internal\n * Dispatches a CloseDropdownEvent for target to close the current dropdown.\n *\n * @param {Element} target - The target element to close the dropdown for.\n */\nexport function closeCurrentDropdown(target: Element): void {\n target.dispatchEvent(new CloseDropdownEvent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A,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,cAAc,YAFf,UAAU,CAAA,EAAA,CAAA,CAAA,EAAA;;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,CAAA;;;ACPD;;;;;AAKG;AACG,SAAU,oBAAoB,CAAC,MAAe,EAAA;AAClD,IAAA,MAAM,CAAC,aAAa,CAAC,IAAI,kBAAkB,EAAE,CAAC,CAAC;AACjD;;ACVA;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"odx-angular-components-dropdown.mjs","sources":["../../../../libs/angular/components/dropdown/src/lib/models/close-dropdown-event.ts","../../../../libs/angular/components/dropdown/src/lib/models/dropdown-options.ts","../../../../libs/angular/components/dropdown/src/lib/dropdown.directive.ts","../../../../libs/angular/components/dropdown/src/lib/dropdown.component.ts","../../../../libs/angular/components/dropdown/src/lib/dropdown.component.html","../../../../libs/angular/components/dropdown/src/lib/dropdown.module.ts","../../../../libs/angular/components/dropdown/src/lib/helpers/close-current-dropdown.ts","../../../../libs/angular/components/dropdown/src/odx-angular-components-dropdown.ts"],"sourcesContent":["export class CloseDropdownEvent extends Event {\n public static readonly TYPE = 'odxDropdownClose';\n\n constructor() {\n super(CloseDropdownEvent.TYPE, { bubbles: true });\n }\n}\n","import { ConnectedOverlayOptions } from '@odx/angular/cdk/connected-overlay';\n\nexport type DropdownOptions = Pick<\n ConnectedOverlayOptions,\n 'position' | 'containerClass' | 'enableFallback' | 'matchReferenceWidth' | 'minHeight' | 'offset' | 'showArrow' | 'outerPadding'\n>;\n\nexport const DefaultDropdownOptions: DropdownOptions = {\n position: 'bottom',\n matchReferenceWidth: false,\n enableFallback: true,\n minHeight: 0,\n offset: 6,\n outerPadding: 12,\n};\n","import {\n AfterViewInit,\n booleanAttribute,\n ChangeDetectorRef,\n Directive,\n EventEmitter,\n inject,\n Injector,\n Input,\n OnChanges,\n OnDestroy,\n Output,\n ViewContainerRef,\n} from '@angular/core';\nimport { ConnectedOverlayOptions, ConnectedOverlayRef, ConnectedOverlayService } from '@odx/angular/cdk/connected-overlay';\nimport { DynamicContent } from '@odx/angular/cdk/dynamic-view';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { EventManager, GetProperties, hasChanged, injectElement, NgChanges } from '@odx/angular/utils';\nimport { DropdownComponent } from './dropdown.component';\nimport { DefaultDropdownOptions, DropdownOptions } from './models';\n\nexport const DEFAULT_DROPDOWN_OPEN_TRIGGERS = ['click', 'keydown.enter'];\nexport const DEFAULT_DROPDOWN_CLOSE_TRIGGERS = ['keyup.esc'];\n\n/**\n * Represents a directive that enables dropdown functionality in Angular.\n * This directive handles the opening and closing of a dropdown menu, as well as\n * managing the associated overlay and event handling.\n */\n@CSSComponent('dropdown-host')\n@Directive({\n standalone: true,\n selector: '[odxDropdown]',\n exportAs: 'odxDropdown',\n providers: [EventManager],\n host: {\n '[attr.aria-haspopup]': 'true',\n '[attr.aria-expanded]': 'isOpen',\n },\n})\nexport class DropdownDirective implements AfterViewInit, OnChanges, OnDestroy {\n private readonly changeDetector = inject(ChangeDetectorRef);\n private readonly connectedOverlayService = inject(ConnectedOverlayService);\n private readonly eventManager = inject(EventManager);\n private readonly viewContainer = inject(ViewContainerRef);\n private readonly injector = inject(Injector);\n private overlayRef: ConnectedOverlayRef | null = null;\n\n public readonly element = injectElement();\n\n /**\n * Gets a value indicating whether the dropdown is currently open.\n *\n * @returns {boolean}\n */\n public get isOpen(): boolean {\n return this.overlayRef !== null;\n }\n\n /**\n * The content to be displayed in the dropdown.\n * It can be either a static content or a dynamically loaded content.\n *\n * @type {DynamicContent | null}\n */\n @Input('odxDropdown')\n public content?: DynamicContent | null;\n\n /**\n * Indicates whether the dropdown is disabled or not.\n *\n * @type {boolean}\n * @default false\n */\n @Input({ alias: 'odxDropdownDisabled', transform: booleanAttribute })\n public disabled = false;\n\n /**\n * Indicates whether the loader should be shown.\n *\n * @type {boolean}\n * @default false\n */\n @Input({ alias: 'odxDropdownShowLoader', transform: booleanAttribute })\n public showLoader = false;\n\n /**\n * Determines whether the dropdown should close when a click event occurs outside of it.\n *\n * @type {boolean}\n * @default true\n */\n @Input({ alias: 'odxDropdownClickOutsideActive', transform: booleanAttribute })\n public clickOutsideActive = true;\n\n /**\n * The options to be used when creating the dropdown overlay.\n *\n * @type {Partial<DropdownOptions> | null}\n */\n @Input('odxDropdownOptions')\n public options?: Partial<DropdownOptions> | null;\n\n /**\n * The reference element to which the dropdown is anchored.\n *\n * @type {HTMLElement | null}\n */\n @Input('odxDropdownReferenceElement')\n public referenceElement?: HTMLElement | null;\n\n /**\n * The trigger element that opens the dropdown.\n *\n * @type {HTMLElement | null}\n */\n @Input('odxDropdownTriggerElement')\n public triggerElement?: HTMLElement | null;\n\n /**\n * The host element to which the dropdown is appended.\n *\n * @type {HTMLElement | ViewContainerRef | null}\n */\n @Input('odxDropdownHost')\n public host?: HTMLElement | ViewContainerRef | null = this.viewContainer;\n\n /**\n * The event triggers that open the dropdown.\n *\n * @type {string[] | null}\n * @default DEFAULT_DROPDOWN_OPEN_TRIGGERS\n */\n @Input('odxDropdownOpenTrigger')\n public openTrigger?: string[] | null = DEFAULT_DROPDOWN_OPEN_TRIGGERS;\n\n /**\n * The event triggers that close the dropdown.\n *\n * @type {string[] | null}\n * @default DEFAULT_DROPDOWN_CLOSE_TRIGGERS\n */\n @Input('odxDropdownCloseTrigger')\n public closeTrigger?: string[] | null = DEFAULT_DROPDOWN_CLOSE_TRIGGERS;\n\n /**\n * Event emitter that emits before the dropdown is opened.\n *\n * @emits {void}\n */\n @Output('odxDropdownBeforeOpen')\n public beforeOpen = new EventEmitter<void>();\n\n /**\n * Event emitter that emits after the dropdown is opened.\n *\n * @emits {void}\n */\n @Output('odxDropdownAfterOpen')\n public afterOpen = new EventEmitter<void>();\n\n /**\n * Event emitter that emits before the dropdown is closed.\n *\n * @emits {void}\n */\n @Output('odxDropdownBeforeClose')\n public beforeClose = new EventEmitter<void>();\n\n /**\n * Event emitter that emits after the dropdown is closed.\n *\n * @emits {void}\n */\n @Output('odxDropdownAfterClose')\n public afterClose = new EventEmitter<void>();\n\n public ngAfterViewInit(): void {\n this.eventManager.register(this.openTrigger ?? [], (event) => this.toggle(event), this.triggerElement ?? this.referenceElement);\n this.eventManager.register(this.closeTrigger ?? [], () => this.close(), 'document');\n }\n\n public ngOnDestroy(): void {\n this.close();\n }\n\n public ngOnChanges(changes: NgChanges<DropdownDirective>) {\n if (hasChanged(changes, 'disabled') && this.disabled) {\n this.close();\n }\n if (hasChanged(changes, ['options', 'content', 'showLoader', 'clickOutsideActive'])) {\n this.overlayRef?.update(this.createOverlayOptions());\n }\n }\n\n /**\n * Toggles the state of the dropdown.\n * If the dropdown is open, it will be closed. If it is closed, it will be opened.\n *\n * @param {Event | undefined} event - The optional event that triggered the toggle.\n */\n public toggle(event?: Event): void {\n if (this.isOpen) {\n this.close(event);\n } else {\n this.open(event);\n }\n }\n\n /**\n * Opens the dropdown.\n *\n * @param {Event | undefined} event - The optional event that triggered the open.\n */\n public open(event?: Event) {\n event?.preventDefault();\n if (this.isOpen || !this.content || this.disabled) return;\n this.overlayRef = this.connectedOverlayService.createOverlay(this.referenceElement ?? this.element.nativeElement, this.createOverlayOptions(), {\n host: this.referenceElement?.parentElement ?? this.host,\n injector: this.injector,\n });\n this.changeDetector.markForCheck();\n }\n\n /**\n * Closes the dropdown.\n *\n * @param {Event | undefined} event - The optional event that triggered the close.\n */\n public close(event?: Event) {\n event?.preventDefault();\n this.overlayRef?.close();\n this.overlayRef = null;\n this.changeDetector.markForCheck();\n }\n\n private createOverlayOptions(): Partial<ConnectedOverlayOptions> {\n const containerClass = ['odx-dropdown-overlay', this.options?.containerClass].filter(Boolean).join(' ');\n const context = {\n content: this.content,\n showLoader: this.showLoader,\n clickOutsideActive: this.clickOutsideActive,\n } as Partial<GetProperties<DropdownComponent>>;\n return {\n ...DefaultDropdownOptions,\n ...this.options,\n fallbackAxisSideDirection: 'end',\n containerClass,\n content: DropdownComponent,\n context,\n hooks: {\n beforeOpen: () => this.beforeOpen.emit(),\n afterOpen: () => this.afterOpen.emit(),\n beforeClose: () => this.beforeClose.emit(),\n afterClose: () => this.afterClose.emit(),\n },\n };\n }\n}\n","import { ChangeDetectionStrategy, Component, HostListener, inject, Injector, Input, ViewEncapsulation } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { A11yModule } from '@odx/angular/cdk/a11y';\nimport { DynamicContent, DynamicViewDirective } from '@odx/angular/cdk/dynamic-view';\nimport { LoadingSpinnerModule } from '@odx/angular/components/loading-spinner';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { injectElement } from '@odx/angular/utils';\nimport { DropdownDirective } from './dropdown.directive';\nimport { CloseDropdownEvent } from './models';\n\n/**\n * Represents a dropdown component.\n */\n@CSSComponent('dropdown')\n@Component({\n standalone: true,\n selector: 'odx-dropdown',\n imports: [CoreModule, DynamicViewDirective, LoadingSpinnerModule, A11yModule],\n templateUrl: './dropdown.component.html',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class DropdownComponent {\n protected readonly host = inject(DropdownDirective);\n protected readonly injector = inject(Injector);\n public readonly element = injectElement();\n\n /**\n * The content to be displayed in the dropdown.\n *\n * @type {DynamicContent | null}\n */\n @Input()\n public content?: DynamicContent | null;\n\n /**\n * Indicates whether to show a loader while loading the dropdown content.\n *\n * @type {boolean | undefined}\n */\n @Input()\n public showLoader?: boolean;\n\n /**\n * Indicates whether clicking outside the dropdown should close it.\n *\n * @type {boolean | undefined}\n */\n @Input()\n public clickOutsideActive?: boolean;\n\n @HostListener(CloseDropdownEvent.TYPE)\n protected onDropdownClose(): void {\n this.host.close();\n }\n}\n","<div class=\"odx-dropdown__inner\" [odxLoadingSpinner]=\"showLoader\" [odxClickOutsideActive]=\"clickOutsideActive\" (odxClickOutside)=\"host.close()\" cdkTrapFocus>\n <ng-template [odxDynamicView]=\"content\" [odxDynamicViewInjector]=\"injector\" />\n</div>\n","import { NgModule } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { DropdownDirective } from './dropdown.directive';\n\nconst modules = [DropdownDirective];\n\n@NgModule({\n imports: modules,\n exports: [CoreModule, ...modules],\n})\nexport class DropdownModule {}\n","import { CloseDropdownEvent } from '../models';\n\n/**\n * @internal\n * Dispatches a CloseDropdownEvent for target to close the current dropdown.\n *\n * @param {Element} target - The target element to close the dropdown for.\n */\nexport function closeCurrentDropdown(target: Element): void {\n target.dispatchEvent(new CloseDropdownEvent());\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;AAAM,MAAO,kBAAmB,SAAQ,KAAK,CAAA;aACpB,IAAA,CAAA,IAAI,GAAG,kBAAkB,CAAC;AAEjD,IAAA,WAAA,GAAA;QACE,KAAK,CAAC,kBAAkB,CAAC,IAAI,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;IACnD;;;ACEK,MAAM,sBAAsB,GAAoB;AACrD,IAAA,QAAQ,EAAE,QAAQ;AAClB,IAAA,mBAAmB,EAAE,KAAK;AAC1B,IAAA,cAAc,EAAE,IAAI;AACpB,IAAA,SAAS,EAAE,CAAC;AACZ,IAAA,MAAM,EAAE,CAAC;AACT,IAAA,YAAY,EAAE,EAAE;;;MCQL,8BAA8B,GAAG,CAAC,OAAO,EAAE,eAAe;AAChE,MAAM,+BAA+B,GAAG,CAAC,WAAW;AAE3D;;;;AAIG;AAYI,IAAM,iBAAiB,GAAvB,MAAM,iBAAiB,CAAA;AAAvB,IAAA,WAAA,GAAA;AACY,QAAA,IAAA,CAAA,cAAc,GAAG,MAAM,CAAC,iBAAiB,CAAC;AAC1C,QAAA,IAAA,CAAA,uBAAuB,GAAG,MAAM,CAAC,uBAAuB,CAAC;AACzD,Q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EAAA,IAAA,EAAA,cAAc,YAFf,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;;;ACPD;;;;;AAKG;AACG,SAAU,oBAAoB,CAAC,MAAe,EAAA;AAClD,IAAA,MAAM,CAAC,aAAa,CAAC,IAAI,kBAAkB,EAAE,CAAC;AAChD;;ACVA;;AAEG;;;;"}
|
|
@@ -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';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odx-angular-components-error-page.mjs","sources":["../../../../libs/angular/components/error-page/src/lib/error-page.config.ts","../../../../libs/angular/components/error-page/src/lib/error-page.component.ts","../../../../libs/angular/components/error-page/src/lib/error-page.component.html","../../../../libs/angular/components/error-page/src/odx-angular-components-error-page.ts"],"sourcesContent":["import { EnvironmentProviders, makeEnvironmentProviders } from '@angular/core';\nimport { DynamicContent } from '@odx/angular/cdk/dynamic-view';\nimport { ConfigDependencies, ConfigProvider, createConfigTokens } from '@odx/angular/utils';\n\n/**\n * Defines the configuration for an error page used within an application. This can include custom icons,\n * titles, descriptions, actions, and an optional error message.\n * @property {string} [icon] - The name of the icon to display on the error page.\n * @property {string} [iconSet] - The icon set that the icon belongs to.\n * @property {DynamicContent} title - The title content for the error page, which can be a string or a dynamic template.\n * @property {DynamicContent} [description] - Optional description content for the error page.\n * @property { { label: DynamicContent; action: () => void; }[] } actions - A list of actions that can be taken from the error page, each with a label and an action function.\n * @property {DynamicContent} [errorMessage] - Optional additional error message content.\n */\nexport interface ErrorPageConfig {\n icon?: string | null;\n iconSet?: string;\n title: DynamicContent;\n description?: DynamicContent;\n actions: {\n label: DynamicContent;\n action: () => void;\n }[];\n\n errorMessage?: DynamicContent;\n}\n\nexport const { ErrorPageConfig, ErrorPageDefaultConfig, injectErrorPageConfig, provideErrorPageConfig } = createConfigTokens(\n 'ErrorPage',\n '@odx/components/error-page',\n {\n title: '',\n actions: [],\n } as ErrorPageConfig,\n);\n\n/**\n * Configures and provides the necessary providers for an error page, using a configuration object that specifies\n * icons, titles, descriptions, and actions.\n *\n * @param {ConfigProvider<Partial<ErrorPageConfig>, D>} config - A configuration object or provider function that supplies an `ErrorPageConfig`.\n * @returns {EnvironmentProviders} Returns a configuration that can be used to register the error page providers.\n *\n */\nexport function configureErrorPage<D extends ConfigDependencies>(config: ConfigProvider<Partial<ErrorPageConfig>, D>): EnvironmentProviders {\n return makeEnvironmentProviders([provideErrorPageConfig(config)]);\n}\n","import { ChangeDetectionStrategy, Component, ViewEncapsulation } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { DynamicViewDirective } from '@odx/angular/cdk/dynamic-view';\nimport { ButtonComponent } from '@odx/angular/components/button';\nimport { IconComponent } from '@odx/angular/components/icon';\nimport { LogoDirective } from '@odx/angular/components/logo';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { injectElement } from '@odx/angular/utils';\nimport { injectErrorPageConfig } from './error-page.config';\n\n/**\n * Represents the ErrorPageComponent class.\n * This component is responsible for displaying an error page.\n */\n@CSSComponent('error-page')\n@Component({\n standalone: true,\n selector: 'odx-error-page',\n templateUrl: './error-page.component.html',\n imports: [LogoDirective, IconComponent, CoreModule, ButtonComponent, DynamicViewDirective],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class ErrorPageComponent {\n public readonly element = injectElement();\n\n /**\n * Represents the options for the error page component.\n *\n * @type {ErrorPageConfig}\n */\n public options = injectErrorPageConfig();\n}\n","@let icon = options.icon;\n\n<div class=\"odx-error-page__container\">\n @if (icon !== null) {\n <div class=\"odx-error-page__icon-container\">\n @if (icon) {\n <odx-icon size=\"xlarge\" [name]=\"icon\" />\n } @else {\n <odx-logo size=\"large\" />\n }\n </div>\n }\n\n <div class=\"odx-error-page__title\">\n <ng-template [odxDynamicView]=\"options.title\" />\n </div>\n @if (options.description; as description) {\n <div class=\"odx-error-page__description\">\n <ng-template [odxDynamicView]=\"description\" />\n </div>\n }\n <div class=\"odx-error-page__actions\">\n @for (button of options.actions; let isFirst = $first; track $index) {\n <button [variant]=\"isFirst ? 'primary' : 'secondary'\" odxButton (click)=\"button.action()\">\n <ng-template [odxDynamicView]=\"button.label\" />\n </button>\n }\n </div>\n</div>\n@if (options.errorMessage; as errorMessage) {\n <div class=\"odx-error-page__footer\">\n <ng-template [odxDynamicView]=\"errorMessage\" />\n </div>\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"odx-angular-components-error-page.mjs","sources":["../../../../libs/angular/components/error-page/src/lib/error-page.config.ts","../../../../libs/angular/components/error-page/src/lib/error-page.component.ts","../../../../libs/angular/components/error-page/src/lib/error-page.component.html","../../../../libs/angular/components/error-page/src/odx-angular-components-error-page.ts"],"sourcesContent":["import { EnvironmentProviders, makeEnvironmentProviders } from '@angular/core';\nimport { DynamicContent } from '@odx/angular/cdk/dynamic-view';\nimport { ConfigDependencies, ConfigProvider, createConfigTokens } from '@odx/angular/utils';\n\n/**\n * Defines the configuration for an error page used within an application. This can include custom icons,\n * titles, descriptions, actions, and an optional error message.\n * @property {string} [icon] - The name of the icon to display on the error page.\n * @property {string} [iconSet] - The icon set that the icon belongs to.\n * @property {DynamicContent} title - The title content for the error page, which can be a string or a dynamic template.\n * @property {DynamicContent} [description] - Optional description content for the error page.\n * @property { { label: DynamicContent; action: () => void; }[] } actions - A list of actions that can be taken from the error page, each with a label and an action function.\n * @property {DynamicContent} [errorMessage] - Optional additional error message content.\n */\nexport interface ErrorPageConfig {\n icon?: string | null;\n iconSet?: string;\n title: DynamicContent;\n description?: DynamicContent;\n actions: {\n label: DynamicContent;\n action: () => void;\n }[];\n\n errorMessage?: DynamicContent;\n}\n\nexport const { ErrorPageConfig, ErrorPageDefaultConfig, injectErrorPageConfig, provideErrorPageConfig } = createConfigTokens(\n 'ErrorPage',\n '@odx/components/error-page',\n {\n title: '',\n actions: [],\n } as ErrorPageConfig,\n);\n\n/**\n * Configures and provides the necessary providers for an error page, using a configuration object that specifies\n * icons, titles, descriptions, and actions.\n *\n * @param {ConfigProvider<Partial<ErrorPageConfig>, D>} config - A configuration object or provider function that supplies an `ErrorPageConfig`.\n * @returns {EnvironmentProviders} Returns a configuration that can be used to register the error page providers.\n *\n */\nexport function configureErrorPage<D extends ConfigDependencies>(config: ConfigProvider<Partial<ErrorPageConfig>, D>): EnvironmentProviders {\n return makeEnvironmentProviders([provideErrorPageConfig(config)]);\n}\n","import { ChangeDetectionStrategy, Component, ViewEncapsulation } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { DynamicViewDirective } from '@odx/angular/cdk/dynamic-view';\nimport { ButtonComponent } from '@odx/angular/components/button';\nimport { IconComponent } from '@odx/angular/components/icon';\nimport { LogoDirective } from '@odx/angular/components/logo';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { injectElement } from '@odx/angular/utils';\nimport { injectErrorPageConfig } from './error-page.config';\n\n/**\n * Represents the ErrorPageComponent class.\n * This component is responsible for displaying an error page.\n */\n@CSSComponent('error-page')\n@Component({\n standalone: true,\n selector: 'odx-error-page',\n templateUrl: './error-page.component.html',\n imports: [LogoDirective, IconComponent, CoreModule, ButtonComponent, DynamicViewDirective],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class ErrorPageComponent {\n public readonly element = injectElement();\n\n /**\n * Represents the options for the error page component.\n *\n * @type {ErrorPageConfig}\n */\n public options = injectErrorPageConfig();\n}\n","@let icon = options.icon;\n\n<div class=\"odx-error-page__container\">\n @if (icon !== null) {\n <div class=\"odx-error-page__icon-container\">\n @if (icon) {\n <odx-icon size=\"xlarge\" [name]=\"icon\" />\n } @else {\n <odx-logo size=\"large\" />\n }\n </div>\n }\n\n <div class=\"odx-error-page__title\">\n <ng-template [odxDynamicView]=\"options.title\" />\n </div>\n @if (options.description; as description) {\n <div class=\"odx-error-page__description\">\n <ng-template [odxDynamicView]=\"description\" />\n </div>\n }\n <div class=\"odx-error-page__actions\">\n @for (button of options.actions; let isFirst = $first; track $index) {\n <button [variant]=\"isFirst ? 'primary' : 'secondary'\" odxButton (click)=\"button.action()\">\n <ng-template [odxDynamicView]=\"button.label\" />\n </button>\n }\n </div>\n</div>\n@if (options.errorMessage; as errorMessage) {\n <div class=\"odx-error-page__footer\">\n <ng-template [odxDynamicView]=\"errorMessage\" />\n </div>\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;AA2BO,MAAM,EAAE,eAAe,EAAE,sBAAsB,EAAE,qBAAqB,EAAE,sBAAsB,EAAE,GAAG,kBAAkB,CAC1H,WAAW,EACX,4BAA4B,EAC5B;AACE,IAAA,KAAK,EAAE,EAAE;AACT,IAAA,OAAO,EAAE,EAAE;AACO,CAAA;AAGtB;;;;;;;AAOG;AACG,SAAU,kBAAkB,CAA+B,MAAmD,EAAA;IAClH,OAAO,wBAAwB,CAAC,CAAC,sBAAsB,CAAC,MAAM,CAAC,CAAC,CAAC;AACnE;;ACpCA;;;AAGG;AAUI,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB,CAAA;AAAxB,IAAA,WAAA,GAAA;QACW,IAAA,CAAA,OAAO,GAAG,aAAa,EA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iCACI,IAAI,EAAA,QAAA,EACN,gBAAgB,EAAA,OAAA,EAEjB,CAAC,aAAa,EAAE,aAAa,EAAE,UAAU,EAAE,eAAe,EAAE,oBAAoB,CAAC,EAAA,eAAA,EACzE,uBAAuB,CAAC,MAAM,EAAA,aAAA,EAChC,iBAAiB,CAAC,IAAI,EAAA,QAAA,EAAA,siCAAA,EAAA;;;AErBvC;;AAEG;;;;"}
|
|
@@ -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
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odx-angular-components-footer.mjs","sources":["../../../../libs/angular/components/footer/src/lib/footer.i18n.ts","../../../../libs/angular/components/footer/src/lib/footer.config.ts","../../../../libs/angular/components/footer/src/lib/helpers/create-footer-links.ts","../../../../libs/angular/components/footer/src/lib/models/footer-variant.ts","../../../../libs/angular/components/footer/src/lib/footer.component.ts","../../../../libs/angular/components/footer/src/lib/footer.component.html","../../../../libs/angular/components/footer/src/odx-angular-components-footer.ts"],"sourcesContent":["import { TranslationObject } from '@odx/angular/internal/translate';\n\nexport default {\n en: {\n legalNotice: 'Legal notice',\n providerIdentification: 'Provider identification',\n dataProtection: 'Data protection',\n openSource: 'Open-source licenses',\n termsAndConditions: 'Terms and Conditions',\n status: 'Status',\n },\n de: {\n legalNotice: 'Rechtliche Hinweise',\n providerIdentification: 'Impressum',\n dataProtection: 'Datenschutz',\n openSource: 'Open-Source-Lizenzen',\n termsAndConditions: 'Allgemeine Geschäftsbedingungen',\n status: 'Status',\n },\n} as TranslationObject;\n","import { MainMenuLinksConfig } from '@odx/angular/components/main-menu';\nimport { buildWebsiteUrl, createConfigTokens } from '@odx/angular/utils';\nimport { Observable } from 'rxjs';\nimport { FooterLink } from './models';\n\nexport interface FooterLinksConfig extends MainMenuLinksConfig {\n dynamicLinks?: Observable<FooterLink[]>;\n}\n\n/**\n * Creates configuration tokens for the footer links, providing a structured way to inject and manage footer link configurations.\n * This utility function encapsulates the configuration for footer links, including defaults and the ability to inject custom configurations.\n *\n * @returns {Object} An object containing configuration tokens for footer links:\n * - `FooterLinksConfig`: A token for injecting the footer links configuration.\n * - `FooterLinksDefaultConfig`: A token representing the default configuration values.\n * - `injectFooterLinksConfig`: A function to inject the current footer links configuration.\n * - `provideFooterLinksConfig`: A function to provide a custom configuration for footer links.\n *\n * @example\n * ```ts\n * // In your module or component\n * @NgModule({\n * providers: [\n * provideFooterLinksConfig({\n * legalNoticeUrl: 'https://www.custom-url/legal-notice',\n * providerIdentificationUrl: 'https://www.custom-url/provider-identification',\n * dynamicLinks: myDynamicLinksObservable\n * })\n * ]\n * })\n * export class MyModule {}\n * ```\n */\nexport const { FooterLinksConfig, FooterLinksDefaultConfig, injectFooterLinksConfig, provideFooterLinksConfig } = createConfigTokens(\n 'FooterLinks',\n '@odx/angular/components/footer',\n {\n providerIdentificationUrl: buildWebsiteUrl('provideridentification'),\n legalNoticeUrl: buildWebsiteUrl('legalnotice'),\n } as FooterLinksConfig,\n);\n","import { Observable, combineLatest, map, of } from 'rxjs';\nimport { injectFooterLinksConfig } from '../footer.config';\nimport { FooterLink } from '../models';\n\n/**\n * Creates an observable stream of footer links, combining statically configured links with dynamically provided ones.\n * It leverages the footer links configuration injected from `injectFooterLinksConfig` and optionally includes\n * dynamic links if provided. All links are filtered to include only those with a non-empty URL.\n *\n * @returns {Observable<FooterLink[]>} - An Observable that emits an array of `FooterLink` objects. Each `FooterLink`\n * contains a `name` and a `url`. The observable emits updates if the set of dynamic links changes.\n */\n\nexport function createFooterLinks$(): Observable<FooterLink[]> {\n const { legalNoticeUrl, providerIdentificationUrl, dataProtectionUrl, openSourceUrl, termsAndConditionsUrl, statusUrl, dynamicLinks } =\n injectFooterLinksConfig();\n const dynamicLinks$ = dynamicLinks ?? of([]);\n const links = [\n { name: 'status', url: statusUrl },\n { name: 'termsAndConditions', url: termsAndConditionsUrl },\n { name: 'providerIdentification', url: providerIdentificationUrl },\n { name: 'openSource', url: openSourceUrl },\n { name: 'dataProtection', url: dataProtectionUrl },\n { name: 'legalNotice', url: legalNoticeUrl },\n ];\n\n return combineLatest([dynamicLinks$, of(links)]).pipe(map((links) => links.flat().filter((link): link is FooterLink => !!link.url)));\n}\n","export type FooterVariant = (typeof FooterVariant)[keyof typeof FooterVariant];\n\nexport const FooterVariant = {\n LIGHT: 'light',\n DARK: 'dark',\n} as const;\n","import { CommonModule } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, Input, ViewEncapsulation } from '@angular/core';\nimport { DynamicTextContent, DynamicViewDirective } from '@odx/angular/cdk/dynamic-view';\nimport { LinkDirective } from '@odx/angular/components/link';\nimport { LogoDirective } from '@odx/angular/components/logo';\nimport { CSSComponent, CSSModifier } from '@odx/angular/internal';\nimport { TranslatePipe, provideTranslations } from '@odx/angular/internal/translate';\nimport { injectElement } from '@odx/angular/utils';\nimport footerTranslations from './footer.i18n';\nimport { createFooterLinks$ } from './helpers';\nimport { FooterVariant } from './models';\n\n/**\n * Represents the footer component of an application, dynamically generating links and supporting various styles.\n * This component integrates dynamic and static content for the footer, including a logo, navigational links, and a customizable description.\n */\n\n@CSSComponent('footer')\n@Component({\n standalone: true,\n selector: 'odx-footer',\n imports: [LinkDirective, LogoDirective, DynamicViewDirective, CommonModule, TranslatePipe],\n templateUrl: './footer.component.html',\n providers: [provideTranslations(footerTranslations)],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class FooterComponent {\n protected readonly footerLinks$ = createFooterLinks$();\n public readonly element = injectElement();\n\n /**\n * The description of the footer component.\n * It can be of type DynamicTextContent or null.\n *\n * @type {DynamicTextContent}\n * @default null\n */\n @Input()\n public description?: DynamicTextContent | null = null;\n\n /**\n * The variant of the footer component.\n *\n * @type {FooterVariant}\n * @default FooterVariant.LIGHT\n */\n @CSSModifier()\n @Input()\n public variant: FooterVariant = FooterVariant.LIGHT;\n}\n","<div class=\"odx-footer__inner\">\n <div class=\"odx-footer__content\">\n <ng-content />\n </div>\n <nav class=\"odx-footer__navigation\">\n <ng-content select=\"[odxLink]\" />\n @for (link of footerLinks$ | async; track $index) {\n <a odxLink [href]=\"link.url\" target=\"_blank\">\n {{ link.name | odxTranslate | async }}\n </a>\n }\n </nav>\n @if (description) {\n <p class=\"odx-footer__description\">\n <ng-template [odxDynamicView]=\"description\" />\n </p>\n }\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;AAEA,yBAAe;AACb,IAAA,EAAE,EAAE;AACF,QAAA,WAAW,EAAE,cAAc;AAC3B,QAAA,sBAAsB,EAAE,yBAAyB;AACjD,QAAA,cAAc,EAAE,iBAAiB;AACjC,QAAA,UAAU,EAAE,sBAAsB;AAClC,QAAA,kBAAkB,EAAE,sBAAsB;AAC1C,QAAA,MAAM,EAAE,QAAQ;AACjB,KAAA;AACD,IAAA,EAAE,EAAE;AACF,QAAA,WAAW,EAAE,qBAAqB;AAClC,QAAA,sBAAsB,EAAE,WAAW;AACnC,QAAA,cAAc,EAAE,aAAa;AAC7B,QAAA,UAAU,EAAE,sBAAsB;AAClC,QAAA,kBAAk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,CAAA,uBAAA,CAAA,MAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA,EAAA;;AA4BlF,UAAA,CAAA;AAFN,IAAA,WAAW,EAAE;;AAEsC,CAAA,EAAA,eAAA,CAAA,SAAA,EAAA,SAAA,EAAA,KAAA,CAAA,CAAA,CAAA;AAtBzC,eAAe,GAAA,UAAA,CAAA;IAV3B,YAAY,CAAC,QAAQ,CAAC;AAUV,CAAA,EAAA,eAAe,CAuB3B,CAAA;4FAvBY,eAAe,EAAA,UAAA,EAAA,CAAA;kBAT3B,SAAS;AACI,YAAA,IAAA,EAAA,CAAA,EAAA,UAAA,EAAA,IAAI,EACN,QAAA,EAAA,YAAY,EACb,OAAA,EAAA,CAAC,aAAa,EAAE,aAAa,EAAE,oBAAoB,EAAE,YAAY,EAAE,aAAa,CAAC,EAE/E,SAAA,EAAA,CAAC,mBAAmB,CAAC,kBAAkB,CAAC,CAAC,EAAA,eAAA,EACnC,uBAAuB,CAAC,MAAM,EAAA,aAAA,EAChC,iBAAiB,CAAC,IAAI,EAAA,QAAA,EAAA,6gBAAA,EAAA,CAAA;8BAc9B,WAAW,EAAA,CAAA;sBADjB,KAAK;gBAWC,OAAO,EAAA,CAAA;sBADb,KAAK;;;AEhDR;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"odx-angular-components-footer.mjs","sources":["../../../../libs/angular/components/footer/src/lib/footer.i18n.ts","../../../../libs/angular/components/footer/src/lib/footer.config.ts","../../../../libs/angular/components/footer/src/lib/helpers/create-footer-links.ts","../../../../libs/angular/components/footer/src/lib/models/footer-variant.ts","../../../../libs/angular/components/footer/src/lib/footer.component.ts","../../../../libs/angular/components/footer/src/lib/footer.component.html","../../../../libs/angular/components/footer/src/odx-angular-components-footer.ts"],"sourcesContent":["import { TranslationObject } from '@odx/angular/internal/translate';\n\nexport default {\n en: {\n legalNotice: 'Legal notice',\n providerIdentification: 'Provider identification',\n dataProtection: 'Data protection',\n openSource: 'Open-source licenses',\n termsAndConditions: 'Terms and Conditions',\n status: 'Status',\n },\n de: {\n legalNotice: 'Rechtliche Hinweise',\n providerIdentification: 'Impressum',\n dataProtection: 'Datenschutz',\n openSource: 'Open-Source-Lizenzen',\n termsAndConditions: 'Allgemeine Geschäftsbedingungen',\n status: 'Status',\n },\n} as TranslationObject;\n","import { MainMenuLinksConfig } from '@odx/angular/components/main-menu';\nimport { buildWebsiteUrl, createConfigTokens } from '@odx/angular/utils';\nimport { Observable } from 'rxjs';\nimport { FooterLink } from './models';\n\nexport interface FooterLinksConfig extends MainMenuLinksConfig {\n dynamicLinks?: Observable<FooterLink[]>;\n}\n\n/**\n * Creates configuration tokens for the footer links, providing a structured way to inject and manage footer link configurations.\n * This utility function encapsulates the configuration for footer links, including defaults and the ability to inject custom configurations.\n *\n * @returns {Object} An object containing configuration tokens for footer links:\n * - `FooterLinksConfig`: A token for injecting the footer links configuration.\n * - `FooterLinksDefaultConfig`: A token representing the default configuration values.\n * - `injectFooterLinksConfig`: A function to inject the current footer links configuration.\n * - `provideFooterLinksConfig`: A function to provide a custom configuration for footer links.\n *\n * @example\n * ```ts\n * // In your module or component\n * @NgModule({\n * providers: [\n * provideFooterLinksConfig({\n * legalNoticeUrl: 'https://www.custom-url/legal-notice',\n * providerIdentificationUrl: 'https://www.custom-url/provider-identification',\n * dynamicLinks: myDynamicLinksObservable\n * })\n * ]\n * })\n * export class MyModule {}\n * ```\n */\nexport const { FooterLinksConfig, FooterLinksDefaultConfig, injectFooterLinksConfig, provideFooterLinksConfig } = createConfigTokens(\n 'FooterLinks',\n '@odx/angular/components/footer',\n {\n providerIdentificationUrl: buildWebsiteUrl('provideridentification'),\n legalNoticeUrl: buildWebsiteUrl('legalnotice'),\n } as FooterLinksConfig,\n);\n","import { Observable, combineLatest, map, of } from 'rxjs';\nimport { injectFooterLinksConfig } from '../footer.config';\nimport { FooterLink } from '../models';\n\n/**\n * Creates an observable stream of footer links, combining statically configured links with dynamically provided ones.\n * It leverages the footer links configuration injected from `injectFooterLinksConfig` and optionally includes\n * dynamic links if provided. All links are filtered to include only those with a non-empty URL.\n *\n * @returns {Observable<FooterLink[]>} - An Observable that emits an array of `FooterLink` objects. Each `FooterLink`\n * contains a `name` and a `url`. The observable emits updates if the set of dynamic links changes.\n */\n\nexport function createFooterLinks$(): Observable<FooterLink[]> {\n const { legalNoticeUrl, providerIdentificationUrl, dataProtectionUrl, openSourceUrl, termsAndConditionsUrl, statusUrl, dynamicLinks } =\n injectFooterLinksConfig();\n const dynamicLinks$ = dynamicLinks ?? of([]);\n const links = [\n { name: 'status', url: statusUrl },\n { name: 'termsAndConditions', url: termsAndConditionsUrl },\n { name: 'providerIdentification', url: providerIdentificationUrl },\n { name: 'openSource', url: openSourceUrl },\n { name: 'dataProtection', url: dataProtectionUrl },\n { name: 'legalNotice', url: legalNoticeUrl },\n ];\n\n return combineLatest([dynamicLinks$, of(links)]).pipe(map((links) => links.flat().filter((link): link is FooterLink => !!link.url)));\n}\n","export type FooterVariant = (typeof FooterVariant)[keyof typeof FooterVariant];\n\nexport const FooterVariant = {\n LIGHT: 'light',\n DARK: 'dark',\n} as const;\n","import { CommonModule } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, Input, ViewEncapsulation } from '@angular/core';\nimport { DynamicTextContent, DynamicViewDirective } from '@odx/angular/cdk/dynamic-view';\nimport { LinkDirective } from '@odx/angular/components/link';\nimport { LogoDirective } from '@odx/angular/components/logo';\nimport { CSSComponent, CSSModifier } from '@odx/angular/internal';\nimport { TranslatePipe, provideTranslations } from '@odx/angular/internal/translate';\nimport { injectElement } from '@odx/angular/utils';\nimport footerTranslations from './footer.i18n';\nimport { createFooterLinks$ } from './helpers';\nimport { FooterVariant } from './models';\n\n/**\n * Represents the footer component of an application, dynamically generating links and supporting various styles.\n * This component integrates dynamic and static content for the footer, including a logo, navigational links, and a customizable description.\n */\n\n@CSSComponent('footer')\n@Component({\n standalone: true,\n selector: 'odx-footer',\n imports: [LinkDirective, LogoDirective, DynamicViewDirective, CommonModule, TranslatePipe],\n templateUrl: './footer.component.html',\n providers: [provideTranslations(footerTranslations)],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class FooterComponent {\n protected readonly footerLinks$ = createFooterLinks$();\n public readonly element = injectElement();\n\n /**\n * The description of the footer component.\n * It can be of type DynamicTextContent or null.\n *\n * @type {DynamicTextContent}\n * @default null\n */\n @Input()\n public description?: DynamicTextContent | null = null;\n\n /**\n * The variant of the footer component.\n *\n * @type {FooterVariant}\n * @default FooterVariant.LIGHT\n */\n @CSSModifier()\n @Input()\n public variant: FooterVariant = FooterVariant.LIGHT;\n}\n","<div class=\"odx-footer__inner\">\n <div class=\"odx-footer__content\">\n <ng-content />\n </div>\n <nav class=\"odx-footer__navigation\">\n <ng-content select=\"[odxLink]\" />\n @for (link of footerLinks$ | async; track $index) {\n <a odxLink [href]=\"link.url\" target=\"_blank\">\n {{ link.name | odxTranslate | async }}\n </a>\n }\n </nav>\n @if (description) {\n <p class=\"odx-footer__description\">\n <ng-template [odxDynamicView]=\"description\" />\n </p>\n }\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;AAEA,yBAAe;AACb,IAAA,EAAE,EAAE;AACF,QAAA,WAAW,EAAE,cAAc;AAC3B,QAAA,sBAAsB,EAAE,yBAAyB;AACjD,QAAA,cAAc,EAAE,iBAAiB;AACjC,QAAA,UAAU,EAAE,sBAAsB;AAClC,QAAA,kBAAkB,EAAE,sBAAsB;AAC1C,QAAA,MAAM,EAAE,QAAQ;AACjB,KAAA;AACD,IAAA,EAAE,EAAE;AACF,QAAA,WAAW,EAAE,qBAAqB;AAClC,QAAA,sBAAsB,EAAE,WAAW;AACnC,QAAA,cAAc,EAAE,aAAa;AAC7B,QAAA,UAAU,EAAE,sBAAsB;AAClC,QAAA,kBAAkB,EAAE,iCAAiC;AACrD,QAAA,MAA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AAA;;AA4BlF,UAAA,CAAA;AAFN,IAAA,WAAW,EAAE;;AAEsC,CAAA,EAAA,eAAA,CAAA,SAAA,EAAA,SAAA,EAAA,KAAA,CAAA,CAAA;AAtBzC,eAAe,GAAA,UAAA,CAAA;IAV3B,YAAY,CAAC,QAAQ;AAUT,CAAA,EAAA,eAAe,CAuB3B;4FAvBY,eAAe,EAAA,UAAA,EAAA,CAAA;kBAT3B,SAAS;AACI,YAAA,IAAA,EAAA,CAAA,EAAA,UAAA,EAAA,IAAI,EAAA,QAAA,EACN,YAAY,EAAA,OAAA,EACb,CAAC,aAAa,EAAE,aAAa,EAAE,oBAAoB,EAAE,YAAY,EAAE,aAAa,CAAC,EAAA,SAAA,EAE/E,CAAC,mBAAmB,CAAC,kBAAkB,CAAC,CAAC,EAAA,eAAA,EACnC,uBAAuB,CAAC,MAAM,EAAA,aAAA,EAChC,iBAAiB,CAAC,IAAI,EAAA,QAAA,EAAA,6gBAAA,EAAA;8BAc9B,WAAW,EAAA,CAAA;sBADjB;gBAWM,OAAO,EAAA,CAAA;sBADb;;;AEhDH;;AAEG;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Injectable, inject,
|
|
2
|
+
import { Injectable, inject, Input, ViewEncapsulation, Component, ContentChildren, ChangeDetectionStrategy, Directive, TemplateRef, booleanAttribute, ViewChild, ContentChild, NgModule } from '@angular/core';
|
|
3
3
|
import { Controller, DisabledController, ReadonlyController, CoreModule } from '@odx/angular';
|
|
4
4
|
import { DynamicViewDirective } from '@odx/angular/cdk/dynamic-view';
|
|
5
5
|
import { Validators, NgControl, FormControl } from '@angular/forms';
|