@vsn-ux/ngx-gaia 0.8.3 → 0.8.4
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.
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { InjectionToken, makeEnvironmentProviders, inject, ElementRef, input, numberAttribute, computed,
|
|
2
|
+
import { InjectionToken, makeEnvironmentProviders, inject, ElementRef, HostAttributeToken, input, numberAttribute, computed, ViewEncapsulation, Component, NgModule, Injectable, booleanAttribute, ChangeDetectionStrategy, output, contentChild, forwardRef, Injector, signal, linkedSignal, Directive, model, HostListener, TemplateRef, NgZone, HostBinding, Input, DOCUMENT, effect, DestroyRef, afterNextRender, Renderer2, afterEveryRender, contentChildren, viewChild } from '@angular/core';
|
|
3
3
|
import * as i1 from 'lucide-angular';
|
|
4
4
|
import { LucideAngularModule, X, CircleCheck, TriangleAlert, OctagonAlert, Info, Check, Minus, ChevronUp, ChevronDown } from 'lucide-angular';
|
|
5
5
|
import { NG_VALUE_ACCESSOR, NgControl, NG_VALIDATORS, CheckboxRequiredValidator, RequiredValidator } from '@angular/forms';
|
|
6
6
|
import * as i1$4 from '@angular/cdk/overlay';
|
|
7
|
-
import { Overlay, OverlayRef, CdkOverlayOrigin, OverlayModule } from '@angular/cdk/overlay';
|
|
7
|
+
import { Overlay, createBlockScrollStrategy, OverlayRef, CdkOverlayOrigin, OverlayModule } from '@angular/cdk/overlay';
|
|
8
8
|
import { ComponentPortal } from '@angular/cdk/portal';
|
|
9
9
|
import { Subject, takeUntil, map, merge, filter, Observable, isObservable } from 'rxjs';
|
|
10
10
|
import { ESCAPE, hasModifierKey } from '@angular/cdk/keycodes';
|
|
11
11
|
import { NgTemplateOutlet } from '@angular/common';
|
|
12
12
|
import * as i1$1 from '@angular/cdk/menu';
|
|
13
|
-
import { CdkMenu, CdkMenuItem, CdkMenuTrigger } from '@angular/cdk/menu';
|
|
13
|
+
import { CdkMenu, CdkMenuItem, CdkMenuTrigger, MENU_SCROLL_STRATEGY } from '@angular/cdk/menu';
|
|
14
14
|
import { toSignal, takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
15
15
|
import { Router, ResolveStart } from '@angular/router';
|
|
16
16
|
import * as i1$2 from '@angular/cdk/a11y';
|
|
@@ -35,6 +35,9 @@ const GA_ICON_DEFAULT_SIZE = 24;
|
|
|
35
35
|
class GaIconComponent {
|
|
36
36
|
elementRef = inject(ElementRef);
|
|
37
37
|
baseFontSize = inject(GA_BASE_FONT_SIZE);
|
|
38
|
+
ariaHiddenAttr = inject(new HostAttributeToken('aria-hidden'), {
|
|
39
|
+
optional: true,
|
|
40
|
+
});
|
|
38
41
|
icon = input.required();
|
|
39
42
|
size = input(GA_ICON_DEFAULT_SIZE);
|
|
40
43
|
color = input();
|
|
@@ -48,12 +51,12 @@ class GaIconComponent {
|
|
|
48
51
|
}
|
|
49
52
|
return size;
|
|
50
53
|
});
|
|
51
|
-
constructor(
|
|
52
|
-
if (!ariaHiddenAttr) {
|
|
54
|
+
constructor() {
|
|
55
|
+
if (!this.ariaHiddenAttr) {
|
|
53
56
|
this.elementRef.nativeElement.setAttribute('aria-hidden', 'true');
|
|
54
57
|
}
|
|
55
58
|
}
|
|
56
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaIconComponent, deps: [
|
|
59
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaIconComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
57
60
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.0.4", type: GaIconComponent, isStandalone: true, selector: "ga-icon", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: true, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, strokeWidth: { classPropertyName: "strokeWidth", publicName: "strokeWidth", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "img" }, properties: { "style": "{ '--ga-icon-size': sizeWithDimension() }" }, classAttribute: "ga-icon" }, ngImport: i0, template: `<lucide-icon
|
|
58
61
|
[name]="icon()"
|
|
59
62
|
[color]="color()"
|
|
@@ -71,10 +74,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImpor
|
|
|
71
74
|
role: 'img',
|
|
72
75
|
'[style]': "{ '--ga-icon-size': sizeWithDimension() }",
|
|
73
76
|
}, encapsulation: ViewEncapsulation.None, styles: [".ga-icon{display:inline-block;vertical-align:middle;-webkit-user-select:none;user-select:none;width:fit-content;height:fit-content}.ga-icon lucide-icon>svg{width:var(--ga-icon-size);height:var(--ga-icon-size)}\n"] }]
|
|
74
|
-
}], ctorParameters: () => [
|
|
75
|
-
type: Attribute,
|
|
76
|
-
args: ['aria-hidden']
|
|
77
|
-
}] }] });
|
|
77
|
+
}], ctorParameters: () => [] });
|
|
78
78
|
|
|
79
79
|
class GaIconModule {
|
|
80
80
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaIconModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
@@ -542,11 +542,14 @@ const CHECKBOX_CONTROL_VALUE_ACCESSOR = {
|
|
|
542
542
|
// Inspired by @angular/components
|
|
543
543
|
let nextUniqueId$8 = 0;
|
|
544
544
|
class GaCheckboxComponent {
|
|
545
|
-
tabindex;
|
|
546
545
|
/** @ignore */
|
|
547
546
|
_uniqueId = `ga-checkbox-${++nextUniqueId$8}`;
|
|
548
547
|
/** @ignore */
|
|
549
548
|
injector = inject(Injector);
|
|
549
|
+
/** @ignore */
|
|
550
|
+
tabindex = inject(new HostAttributeToken('tabindex'), {
|
|
551
|
+
optional: true,
|
|
552
|
+
});
|
|
550
553
|
icons = { Minus, Check };
|
|
551
554
|
/** @ignore */
|
|
552
555
|
_onTouched;
|
|
@@ -594,11 +597,6 @@ class GaCheckboxComponent {
|
|
|
594
597
|
? this.ariaInvalid() === 'true'
|
|
595
598
|
: this._invalidNgModel();
|
|
596
599
|
});
|
|
597
|
-
constructor(
|
|
598
|
-
/** @ignore */
|
|
599
|
-
tabindex) {
|
|
600
|
-
this.tabindex = tabindex;
|
|
601
|
-
}
|
|
602
600
|
ngDoCheck() {
|
|
603
601
|
const ngControl = this.injector.get(NgControl, null, { self: true });
|
|
604
602
|
if (ngControl) {
|
|
@@ -643,7 +641,7 @@ class GaCheckboxComponent {
|
|
|
643
641
|
this._onModelChanged?.(this.checkedModel());
|
|
644
642
|
this.change.emit(this.checkedModel());
|
|
645
643
|
}
|
|
646
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaCheckboxComponent, deps: [
|
|
644
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaCheckboxComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
647
645
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.0.4", type: GaCheckboxComponent, isStandalone: true, selector: "ga-checkbox", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, checked: { classPropertyName: "checked", publicName: "checked", isSignal: true, isRequired: false, transformFunction: null }, nameInput: { classPropertyName: "nameInput", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, indeterminate: { classPropertyName: "indeterminate", publicName: "indeterminate", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "aria-label", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelledby: { classPropertyName: "ariaLabelledby", publicName: "aria-labelledby", isSignal: true, isRequired: false, transformFunction: null }, ariaDescribedby: { classPropertyName: "ariaDescribedby", publicName: "aria-describedby", isSignal: true, isRequired: false, transformFunction: null }, ariaInvalid: { classPropertyName: "ariaInvalid", publicName: "aria-invalid", isSignal: true, isRequired: false, transformFunction: null }, ariaErrormessage: { classPropertyName: "ariaErrormessage", publicName: "aria-errormessage", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { change: "change", indeterminateChange: "indeterminateChange" }, host: { properties: { "class.ga-checkbox--invalid": "invalid()", "attr.id": "null", "attr.tabindex": "null", "attr.aria-label": "null", "attr.aria-labelledby": "null", "attr.aria-describedby": "null", "attr.aria-invalid": "null", "attr.aria-errormessage": "null" }, classAttribute: "ga-checkbox" }, providers: [CHECKBOX_CONTROL_VALUE_ACCESSOR], ngImport: i0, template: "<input\n type=\"checkbox\"\n class=\"ga-checkbox__native\"\n [attr.id]=\"inputId()\"\n [name]=\"name()\"\n [checked]=\"checkedModel()\"\n [indeterminate]=\"indeterminate()\"\n [disabled]=\"disabledModel()\"\n [required]=\"required()\"\n [attr.value]=\"value()\"\n [attr.tabindex]=\"tabindex\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledby()\"\n [attr.aria-describedby]=\"ariaDescribedby()\"\n [attr.aria-invalid]=\"ariaInvalid()\"\n [attr.aria-errormessage]=\"ariaErrormessage()\"\n (change)=\"onInputChange($event)\"\n (blur)=\"onBlur()\"\n/>\n<div class=\"ga-checkbox__marker\">\n <lucide-icon\n [img]=\"icons.Check\"\n class=\"ga-checkbox__marker__indicator-checked\"\n [size]=\"12\"\n [strokeWidth]=\"2\"\n [absoluteStrokeWidth]=\"true\"\n />\n <lucide-icon\n [img]=\"icons.Minus\"\n class=\"ga-checkbox__marker__indicator-indeterminate\"\n [size]=\"12\"\n [strokeWidth]=\"2\"\n [absoluteStrokeWidth]=\"true\"\n />\n</div>\n\n<label class=\"ga-checkbox__label\" [attr.for]=\"inputId()\"\n ><ng-content></ng-content\n></label>\n", dependencies: [{ kind: "ngmodule", type: LucideAngularModule }, { kind: "component", type: i1.LucideAngularComponent, selector: "lucide-angular, lucide-icon, i-lucide, span-lucide", inputs: ["class", "name", "img", "color", "absoluteStrokeWidth", "size", "strokeWidth"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
648
646
|
}
|
|
649
647
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaCheckboxComponent, decorators: [{
|
|
@@ -659,10 +657,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImpor
|
|
|
659
657
|
'[attr.aria-invalid]': 'null',
|
|
660
658
|
'[attr.aria-errormessage]': 'null',
|
|
661
659
|
}, template: "<input\n type=\"checkbox\"\n class=\"ga-checkbox__native\"\n [attr.id]=\"inputId()\"\n [name]=\"name()\"\n [checked]=\"checkedModel()\"\n [indeterminate]=\"indeterminate()\"\n [disabled]=\"disabledModel()\"\n [required]=\"required()\"\n [attr.value]=\"value()\"\n [attr.tabindex]=\"tabindex\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledby()\"\n [attr.aria-describedby]=\"ariaDescribedby()\"\n [attr.aria-invalid]=\"ariaInvalid()\"\n [attr.aria-errormessage]=\"ariaErrormessage()\"\n (change)=\"onInputChange($event)\"\n (blur)=\"onBlur()\"\n/>\n<div class=\"ga-checkbox__marker\">\n <lucide-icon\n [img]=\"icons.Check\"\n class=\"ga-checkbox__marker__indicator-checked\"\n [size]=\"12\"\n [strokeWidth]=\"2\"\n [absoluteStrokeWidth]=\"true\"\n />\n <lucide-icon\n [img]=\"icons.Minus\"\n class=\"ga-checkbox__marker__indicator-indeterminate\"\n [size]=\"12\"\n [strokeWidth]=\"2\"\n [absoluteStrokeWidth]=\"true\"\n />\n</div>\n\n<label class=\"ga-checkbox__label\" [attr.for]=\"inputId()\"\n ><ng-content></ng-content\n></label>\n" }]
|
|
662
|
-
}]
|
|
663
|
-
type: Attribute,
|
|
664
|
-
args: ['tabindex']
|
|
665
|
-
}] }] });
|
|
660
|
+
}] });
|
|
666
661
|
|
|
667
662
|
const GA_CHECKBOX_REQUIRED_VALIDATOR = {
|
|
668
663
|
provide: NG_VALIDATORS,
|
|
@@ -681,6 +676,7 @@ class GaCheckboxRequiredValidator extends CheckboxRequiredValidator {
|
|
|
681
676
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaCheckboxRequiredValidator, decorators: [{
|
|
682
677
|
type: Directive,
|
|
683
678
|
args: [{
|
|
679
|
+
// eslint-disable-next-line @angular-eslint/directive-selector
|
|
684
680
|
selector: `ga-checkbox[required][formControlName], ga-checkbox[required][formControl], ga-checkbox[required][ngModel]`,
|
|
685
681
|
providers: [GA_CHECKBOX_REQUIRED_VALIDATOR],
|
|
686
682
|
}]
|
|
@@ -925,6 +921,7 @@ class GaInputDirective {
|
|
|
925
921
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaInputDirective, decorators: [{
|
|
926
922
|
type: Component,
|
|
927
923
|
args: [{
|
|
924
|
+
// eslint-disable-next-line @angular-eslint/component-selector
|
|
928
925
|
selector: '[gaInput]',
|
|
929
926
|
template: '',
|
|
930
927
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
@@ -1384,11 +1381,11 @@ class GaFieldLabelComponent {
|
|
|
1384
1381
|
}
|
|
1385
1382
|
}
|
|
1386
1383
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaFieldLabelComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1387
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.0.4", type: GaFieldLabelComponent, isStandalone: true, selector: "ga-label", inputs: { for: { classPropertyName: "for", publicName: "for", isSignal: true, isRequired: false, transformFunction: null }, definition: { classPropertyName: "definition", publicName: "definition", isSignal: true, isRequired: false, transformFunction: null }, state: { classPropertyName: "state", publicName: "state", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<label\n [attr.id]=\"uniqueId\"\n [attr.for]=\"controlId()\"\n class=\"ga-form-field__label\"\n [class.ga-form-field__label--defined]=\"!!definition()\"\n [class.ga-form-field__label--disabled]=\"\n !!formField.formControl()?._formControlDisabled()\n \"\n (click)=\"focusControl()\"\n [attr.tabindex]=\"definition() ? 0 : -1\"\n>\n <span\n class=\"ga-form-field__label-text\"\n [gaTooltip]=\"definition()\"\n gaTooltipPlacement=\"top-start\"\n ><ng-content\n /></span>\n @if (state()) {\n <span class=\"ga-form-field__label-state\">{{ state() }}</span>\n }\n</label>\n", dependencies: [{ kind: "ngmodule", type: GaTooltipModule }, { kind: "directive", type: GaTooltipDirective, selector: "[gaTooltip]", inputs: ["gaTooltip", "gaTooltipDisabled", "gaTooltipControlMode", "gaTooltipShowControlMode", "gaTooltipHideControlMode", "gaTooltipOffsetSize", "gaTooltipPlacement"], exportAs: ["gaTooltip"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1384
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.0.4", type: GaFieldLabelComponent, isStandalone: true, selector: "ga-label", inputs: { for: { classPropertyName: "for", publicName: "for", isSignal: true, isRequired: false, transformFunction: null }, definition: { classPropertyName: "definition", publicName: "definition", isSignal: true, isRequired: false, transformFunction: null }, state: { classPropertyName: "state", publicName: "state", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events -->\n<label\n [attr.id]=\"uniqueId\"\n [attr.for]=\"controlId()\"\n class=\"ga-form-field__label\"\n [class.ga-form-field__label--defined]=\"!!definition()\"\n [class.ga-form-field__label--disabled]=\"\n !!formField.formControl()?._formControlDisabled()\n \"\n (click)=\"focusControl()\"\n [attr.tabindex]=\"definition() ? 0 : -1\"\n>\n <span\n class=\"ga-form-field__label-text\"\n [gaTooltip]=\"definition()\"\n gaTooltipPlacement=\"top-start\"\n ><ng-content\n /></span>\n @if (state()) {\n <span class=\"ga-form-field__label-state\">{{ state() }}</span>\n }\n</label>\n", dependencies: [{ kind: "ngmodule", type: GaTooltipModule }, { kind: "directive", type: GaTooltipDirective, selector: "[gaTooltip]", inputs: ["gaTooltip", "gaTooltipDisabled", "gaTooltipControlMode", "gaTooltipShowControlMode", "gaTooltipHideControlMode", "gaTooltipOffsetSize", "gaTooltipPlacement"], exportAs: ["gaTooltip"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1388
1385
|
}
|
|
1389
1386
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaFieldLabelComponent, decorators: [{
|
|
1390
1387
|
type: Component,
|
|
1391
|
-
args: [{ selector: 'ga-label', imports: [GaTooltipModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "<label\n [attr.id]=\"uniqueId\"\n [attr.for]=\"controlId()\"\n class=\"ga-form-field__label\"\n [class.ga-form-field__label--defined]=\"!!definition()\"\n [class.ga-form-field__label--disabled]=\"\n !!formField.formControl()?._formControlDisabled()\n \"\n (click)=\"focusControl()\"\n [attr.tabindex]=\"definition() ? 0 : -1\"\n>\n <span\n class=\"ga-form-field__label-text\"\n [gaTooltip]=\"definition()\"\n gaTooltipPlacement=\"top-start\"\n ><ng-content\n /></span>\n @if (state()) {\n <span class=\"ga-form-field__label-state\">{{ state() }}</span>\n }\n</label>\n" }]
|
|
1388
|
+
args: [{ selector: 'ga-label', imports: [GaTooltipModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "<!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events -->\n<label\n [attr.id]=\"uniqueId\"\n [attr.for]=\"controlId()\"\n class=\"ga-form-field__label\"\n [class.ga-form-field__label--defined]=\"!!definition()\"\n [class.ga-form-field__label--disabled]=\"\n !!formField.formControl()?._formControlDisabled()\n \"\n (click)=\"focusControl()\"\n [attr.tabindex]=\"definition() ? 0 : -1\"\n>\n <span\n class=\"ga-form-field__label-text\"\n [gaTooltip]=\"definition()\"\n gaTooltipPlacement=\"top-start\"\n ><ng-content\n /></span>\n @if (state()) {\n <span class=\"ga-form-field__label-state\">{{ state() }}</span>\n }\n</label>\n" }]
|
|
1392
1389
|
}] });
|
|
1393
1390
|
|
|
1394
1391
|
class GaFieldInfoComponent {
|
|
@@ -1516,7 +1513,15 @@ class GaMenuTriggerDirective {
|
|
|
1516
1513
|
});
|
|
1517
1514
|
}
|
|
1518
1515
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaMenuTriggerDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1519
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.0.4", type: GaMenuTriggerDirective, isStandalone: true, selector: "[gaMenuTrigger]", inputs: { menuRef: { classPropertyName: "menuRef", publicName: "gaMenuTrigger", isSignal: true, isRequired: true, transformFunction: null } },
|
|
1516
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.0.4", type: GaMenuTriggerDirective, isStandalone: true, selector: "[gaMenuTrigger]", inputs: { menuRef: { classPropertyName: "menuRef", publicName: "gaMenuTrigger", isSignal: true, isRequired: true, transformFunction: null } }, providers: [
|
|
1517
|
+
{
|
|
1518
|
+
provide: MENU_SCROLL_STRATEGY,
|
|
1519
|
+
useFactory: () => {
|
|
1520
|
+
const injector = inject(Injector);
|
|
1521
|
+
return () => createBlockScrollStrategy(injector);
|
|
1522
|
+
},
|
|
1523
|
+
},
|
|
1524
|
+
], exportAs: ["gaMenuTrigger"], hostDirectives: [{ directive: i1$1.CdkMenuTrigger, outputs: ["cdkMenuOpened", "gaMenuOpened", "cdkMenuClosed", "gaMenuClosed"] }], ngImport: i0 });
|
|
1520
1525
|
}
|
|
1521
1526
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaMenuTriggerDirective, decorators: [{
|
|
1522
1527
|
type: Directive,
|
|
@@ -1530,6 +1535,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImpor
|
|
|
1530
1535
|
outputs: ['cdkMenuOpened: gaMenuOpened', 'cdkMenuClosed: gaMenuClosed'],
|
|
1531
1536
|
},
|
|
1532
1537
|
],
|
|
1538
|
+
providers: [
|
|
1539
|
+
{
|
|
1540
|
+
provide: MENU_SCROLL_STRATEGY,
|
|
1541
|
+
useFactory: () => {
|
|
1542
|
+
const injector = inject(Injector);
|
|
1543
|
+
return () => createBlockScrollStrategy(injector);
|
|
1544
|
+
},
|
|
1545
|
+
},
|
|
1546
|
+
],
|
|
1533
1547
|
}]
|
|
1534
1548
|
}], ctorParameters: () => [] });
|
|
1535
1549
|
|
|
@@ -1628,7 +1642,7 @@ class GaModalService {
|
|
|
1628
1642
|
return this.openModalsAtThisLevel;
|
|
1629
1643
|
}
|
|
1630
1644
|
open(component, ...args) {
|
|
1631
|
-
|
|
1645
|
+
const [data] = args;
|
|
1632
1646
|
const overlayRef = this.createOverlay();
|
|
1633
1647
|
return this.attachContent(component, data, overlayRef);
|
|
1634
1648
|
}
|
|
@@ -1890,10 +1904,13 @@ class GaModalTitleDirective {
|
|
|
1890
1904
|
renderer = inject(Renderer2);
|
|
1891
1905
|
elementRef = inject(ElementRef);
|
|
1892
1906
|
modalRef = inject(GaModalRef);
|
|
1907
|
+
idAttribute = inject(new HostAttributeToken('id'), {
|
|
1908
|
+
optional: true,
|
|
1909
|
+
});
|
|
1893
1910
|
id;
|
|
1894
|
-
constructor(
|
|
1895
|
-
if (
|
|
1896
|
-
this.id =
|
|
1911
|
+
constructor() {
|
|
1912
|
+
if (this.idAttribute) {
|
|
1913
|
+
this.id = this.idAttribute;
|
|
1897
1914
|
}
|
|
1898
1915
|
else {
|
|
1899
1916
|
this.id = `gaModalTitle${nextUniqueModalTitleId++}`;
|
|
@@ -1903,7 +1920,7 @@ class GaModalTitleDirective {
|
|
|
1903
1920
|
ngAfterViewInit() {
|
|
1904
1921
|
this.modalRef.instance.labelledBy.set(this.id);
|
|
1905
1922
|
}
|
|
1906
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaModalTitleDirective, deps: [
|
|
1923
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaModalTitleDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1907
1924
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.0.4", type: GaModalTitleDirective, isStandalone: true, selector: "[gaModalTitle]", host: { classAttribute: "ga-modal__title" }, ngImport: i0 });
|
|
1908
1925
|
}
|
|
1909
1926
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaModalTitleDirective, decorators: [{
|
|
@@ -1912,19 +1929,19 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImpor
|
|
|
1912
1929
|
selector: '[gaModalTitle]',
|
|
1913
1930
|
host: { class: 'ga-modal__title' },
|
|
1914
1931
|
}]
|
|
1915
|
-
}], ctorParameters: () => [
|
|
1916
|
-
type: Attribute,
|
|
1917
|
-
args: ['id']
|
|
1918
|
-
}] }] });
|
|
1932
|
+
}], ctorParameters: () => [] });
|
|
1919
1933
|
let nextUniqueModalDescriptionId = 0;
|
|
1920
1934
|
class GaModalDescriptionDirective {
|
|
1921
1935
|
renderer = inject(Renderer2);
|
|
1922
1936
|
elementRef = inject(ElementRef);
|
|
1923
1937
|
modalRef = inject(GaModalRef);
|
|
1938
|
+
idAttribute = inject(new HostAttributeToken('id'), {
|
|
1939
|
+
optional: true,
|
|
1940
|
+
});
|
|
1924
1941
|
id;
|
|
1925
|
-
constructor(
|
|
1926
|
-
if (
|
|
1927
|
-
this.id =
|
|
1942
|
+
constructor() {
|
|
1943
|
+
if (this.idAttribute) {
|
|
1944
|
+
this.id = this.idAttribute;
|
|
1928
1945
|
}
|
|
1929
1946
|
else {
|
|
1930
1947
|
this.id = `gaModalDescription${nextUniqueModalDescriptionId++}`;
|
|
@@ -1934,7 +1951,7 @@ class GaModalDescriptionDirective {
|
|
|
1934
1951
|
ngAfterViewInit() {
|
|
1935
1952
|
this.modalRef.instance.describedBy.set(this.id);
|
|
1936
1953
|
}
|
|
1937
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaModalDescriptionDirective, deps: [
|
|
1954
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaModalDescriptionDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1938
1955
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.0.4", type: GaModalDescriptionDirective, isStandalone: true, selector: "[gaModalDescription]", host: { classAttribute: "ga-modal__description" }, ngImport: i0 });
|
|
1939
1956
|
}
|
|
1940
1957
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaModalDescriptionDirective, decorators: [{
|
|
@@ -1943,25 +1960,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImpor
|
|
|
1943
1960
|
selector: '[gaModalDescription]',
|
|
1944
1961
|
host: { class: 'ga-modal__description' },
|
|
1945
1962
|
}]
|
|
1946
|
-
}], ctorParameters: () => [
|
|
1947
|
-
type: Attribute,
|
|
1948
|
-
args: ['id']
|
|
1949
|
-
}] }] });
|
|
1963
|
+
}], ctorParameters: () => [] });
|
|
1950
1964
|
let nextUniqueModalLabelId = 0;
|
|
1951
1965
|
class GaModalLabelDirective {
|
|
1952
1966
|
renderer = inject(Renderer2);
|
|
1953
1967
|
elementRef = inject(ElementRef);
|
|
1968
|
+
idAttribute = inject(new HostAttributeToken('id'), {
|
|
1969
|
+
optional: true,
|
|
1970
|
+
});
|
|
1954
1971
|
id;
|
|
1955
|
-
constructor(
|
|
1956
|
-
if (
|
|
1957
|
-
this.id =
|
|
1972
|
+
constructor() {
|
|
1973
|
+
if (this.idAttribute) {
|
|
1974
|
+
this.id = this.idAttribute;
|
|
1958
1975
|
}
|
|
1959
1976
|
else {
|
|
1960
1977
|
this.id = `gaModalLabel${nextUniqueModalLabelId++}`;
|
|
1961
1978
|
this.renderer.setAttribute(this.elementRef.nativeElement, 'id', this.id);
|
|
1962
1979
|
}
|
|
1963
1980
|
}
|
|
1964
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaModalLabelDirective, deps: [
|
|
1981
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaModalLabelDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1965
1982
|
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.0.4", type: GaModalLabelDirective, isStandalone: true, selector: "[gaModalLabel]", host: { classAttribute: "ga-modal__label" }, ngImport: i0 });
|
|
1966
1983
|
}
|
|
1967
1984
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaModalLabelDirective, decorators: [{
|
|
@@ -1970,10 +1987,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImpor
|
|
|
1970
1987
|
selector: '[gaModalLabel]',
|
|
1971
1988
|
host: { class: 'ga-modal__label' },
|
|
1972
1989
|
}]
|
|
1973
|
-
}], ctorParameters: () => [
|
|
1974
|
-
type: Attribute,
|
|
1975
|
-
args: ['id']
|
|
1976
|
-
}] }] });
|
|
1990
|
+
}], ctorParameters: () => [] });
|
|
1977
1991
|
|
|
1978
1992
|
class GaModalDescriptionComponent {
|
|
1979
1993
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaModalDescriptionComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -2262,10 +2276,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImpor
|
|
|
2262
2276
|
// Increasing integer for generating unique ids for radio button components.
|
|
2263
2277
|
let nextUniqueId$3 = 0;
|
|
2264
2278
|
class GaRadioButtonComponent {
|
|
2265
|
-
tabindex;
|
|
2266
2279
|
radioGroup = inject(GaRadioGroupComponent, {
|
|
2267
2280
|
optional: true,
|
|
2268
2281
|
});
|
|
2282
|
+
tabindex = inject(new HostAttributeToken('tabindex'), {
|
|
2283
|
+
optional: true,
|
|
2284
|
+
});
|
|
2269
2285
|
_uniqueId = `ga-radio-button-${++nextUniqueId$3}`;
|
|
2270
2286
|
/** The value attribute of the native input element */
|
|
2271
2287
|
value = input(null);
|
|
@@ -2300,9 +2316,6 @@ class GaRadioButtonComponent {
|
|
|
2300
2316
|
name = computed(() => this.radioGroup?.name() ?? this.inputName() ?? this._uniqueId);
|
|
2301
2317
|
disabled = computed(() => this.radioGroup?.disabledModel() || this.inputDisabled());
|
|
2302
2318
|
checked = computed(() => this.radioGroup?.valueModel() === this.value() || this.inputChecked());
|
|
2303
|
-
constructor(tabindex) {
|
|
2304
|
-
this.tabindex = tabindex;
|
|
2305
|
-
}
|
|
2306
2319
|
onInputChange(event) {
|
|
2307
2320
|
// We always have to stop propagation on the change event.
|
|
2308
2321
|
// Otherwise the change event, from the input element, will bubble up and
|
|
@@ -2317,7 +2330,7 @@ class GaRadioButtonComponent {
|
|
|
2317
2330
|
onBlur() {
|
|
2318
2331
|
this.radioGroup?.onBlur();
|
|
2319
2332
|
}
|
|
2320
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaRadioButtonComponent, deps: [
|
|
2333
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaRadioButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2321
2334
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.0.4", type: GaRadioButtonComponent, isStandalone: true, selector: "ga-radio-button", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, inputId: { classPropertyName: "inputId", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, inputName: { classPropertyName: "inputName", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, inputChecked: { classPropertyName: "inputChecked", publicName: "checked", isSignal: true, isRequired: false, transformFunction: null }, inputDisabled: { classPropertyName: "inputDisabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "aria-label", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelledby: { classPropertyName: "ariaLabelledby", publicName: "aria-labelledby", isSignal: true, isRequired: false, transformFunction: null }, ariaDescribedby: { classPropertyName: "ariaDescribedby", publicName: "aria-describedby", isSignal: true, isRequired: false, transformFunction: null }, ariaInvalid: { classPropertyName: "ariaInvalid", publicName: "aria-invalid", isSignal: true, isRequired: false, transformFunction: null }, ariaErrormessage: { classPropertyName: "ariaErrormessage", publicName: "aria-errormessage", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { change: "change" }, host: { properties: { "class.ga-radio-button--invalid": "ariaInvalid()", "attr.id": "null", "attr.tabindex": "null", "attr.aria-label": "null", "attr.aria-labelledby": "null", "attr.aria-describedby": "null" }, classAttribute: "ga-radio-button" }, ngImport: i0, template: "<input\n type=\"radio\"\n class=\"ga-radio-button__native\"\n [attr.id]=\"id()\"\n [name]=\"name()\"\n [checked]=\"checked()\"\n [disabled]=\"disabled()\"\n [attr.tabindex]=\"tabindex\"\n [attr.value]=\"value()\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledby()\"\n [attr.aria-describedby]=\"ariaDescribedby()\"\n [attr.aria-invalid]=\"ariaInvalid()\"\n [attr.aria-errormessage]=\"ariaErrormessage()\"\n (change)=\"onInputChange($event)\"\n (blur)=\"onBlur()\"\n/>\n\n<div class=\"ga-radio-button__marker\"></div>\n<label class=\"ga-radio-button__label\" [attr.for]=\"id()\"\n ><ng-content></ng-content\n></label>\n", changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2322
2335
|
}
|
|
2323
2336
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaRadioButtonComponent, decorators: [{
|
|
@@ -2331,10 +2344,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImpor
|
|
|
2331
2344
|
'[attr.aria-labelledby]': 'null',
|
|
2332
2345
|
'[attr.aria-describedby]': 'null',
|
|
2333
2346
|
}, template: "<input\n type=\"radio\"\n class=\"ga-radio-button__native\"\n [attr.id]=\"id()\"\n [name]=\"name()\"\n [checked]=\"checked()\"\n [disabled]=\"disabled()\"\n [attr.tabindex]=\"tabindex\"\n [attr.value]=\"value()\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledby()\"\n [attr.aria-describedby]=\"ariaDescribedby()\"\n [attr.aria-invalid]=\"ariaInvalid()\"\n [attr.aria-errormessage]=\"ariaErrormessage()\"\n (change)=\"onInputChange($event)\"\n (blur)=\"onBlur()\"\n/>\n\n<div class=\"ga-radio-button__marker\"></div>\n<label class=\"ga-radio-button__label\" [attr.for]=\"id()\"\n ><ng-content></ng-content\n></label>\n" }]
|
|
2334
|
-
}]
|
|
2335
|
-
type: Attribute,
|
|
2336
|
-
args: ['tabindex']
|
|
2337
|
-
}] }] });
|
|
2347
|
+
}] });
|
|
2338
2348
|
|
|
2339
2349
|
class GaRadioModule {
|
|
2340
2350
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaRadioModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
@@ -2486,6 +2496,7 @@ class GaSelectComponent {
|
|
|
2486
2496
|
];
|
|
2487
2497
|
injector = inject(Injector);
|
|
2488
2498
|
overlayOrigin = inject(CdkOverlayOrigin);
|
|
2499
|
+
blockScrollStrategy = createBlockScrollStrategy(this.injector);
|
|
2489
2500
|
implicitInvalid = signal(false);
|
|
2490
2501
|
_isOpen = signal(false);
|
|
2491
2502
|
value = model(null);
|
|
@@ -2701,7 +2712,8 @@ class GaSelectComponent {
|
|
|
2701
2712
|
const currentIndex = options.findIndex(({ cdkOption }) => cdkOption.isActive());
|
|
2702
2713
|
const findNextEnabled = (startIndex) => {
|
|
2703
2714
|
let index = startIndex;
|
|
2704
|
-
|
|
2715
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
2716
|
+
for (const _ of options) {
|
|
2705
2717
|
// calculate next index with wrapping (using modulo)
|
|
2706
2718
|
index = (index + direction + options.length) % options.length;
|
|
2707
2719
|
if (!options[index].cdkOption.disabled) {
|
|
@@ -2726,7 +2738,7 @@ class GaSelectComponent {
|
|
|
2726
2738
|
provide: GA_FORM_CONTROL,
|
|
2727
2739
|
useExisting: forwardRef(() => GaSelectComponent),
|
|
2728
2740
|
},
|
|
2729
|
-
], queries: [{ propertyName: "gaOptions", predicate: GaOptionComponent, descendants: true, read: GaOptionComponent, isSignal: true }, { propertyName: "cdkListbox", first: true, predicate: CdkListbox, descendants: true, isSignal: true }, { propertyName: "customSelectValue", first: true, predicate: GaSelectValueComponent, descendants: true, isSignal: true }], viewQueries: [{ propertyName: "inputSearch", first: true, predicate: ["inputSearch"], descendants: true, isSignal: true }, { propertyName: "content", first: true, predicate: ["ngContent"], descendants: true, read: ElementRef, isSignal: true }], hostDirectives: [{ directive: i1$4.CdkOverlayOrigin }, { directive: GaLabelledByFormFieldDirective }], ngImport: i0, template: "@if (leftIcon()) {\n <ga-icon [icon]=\"leftIcon()!\" />\n}\n\n<div class=\"ga-select__main-area\">\n @if (hasValue() && (!textValue() || multiple())) {\n @if (customSelectValue()) {\n <div class=\"ga-select__value\">\n <ng-content select=\"ga-select-value\" />\n </div>\n } @else {\n <ga-select-default-value />\n }\n } @else if (!searchable()) {\n <div class=\"ga-select__placeholder\">\n {{ placeholder() }}\n </div>\n }\n\n @if (searchable()) {\n <input\n #inputSearch\n type=\"text\"\n class=\"ga-select__input\"\n aria-autocomplete=\"list\"\n [value]=\"textValue()\"\n (input)=\"open(); textValue.set(inputSearch.value)\"\n (click)=\"open(); $event.stopPropagation()\"\n [attr.aria-expanded]=\"isOpen()\"\n [attr.aria-controls]=\"cdkListbox().id\"\n [attr.aria-activedescendant]=\"activeDescendantId()\"\n [placeholder]=\"hasValue() ? '' : placeholder()\"\n (keydown)=\"onInputKeyDown($event)\"\n tabindex=\"-1\"\n />\n }\n</div>\n\n<div class=\"ga-select__suffix\">\n <ga-icon [icon]=\"menuStatusIcon()\" class=\"ga-select__action-icon\" />\n</div>\n\n<ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayLockPosition\n [cdkConnectedOverlayOrigin]=\"overlayOrigin\"\n [cdkConnectedOverlayOpen]=\"isOpen()\"\n [cdkConnectedOverlayPositions]=\"positions\"\n (overlayOutsideClick)=\"close()\"\n (attach)=\"onOverlayAttach()\"\n (detach)=\"onOverlayDetach()\"\n>\n <ng-content select=\"ga-select-dropdown\" />\n</ng-template>\n", dependencies: [{ kind: "ngmodule", type: GaIconModule }, { kind: "component", type: GaIconComponent, selector: "ga-icon", inputs: ["icon", "size", "color", "strokeWidth"] }, { kind: "ngmodule", type: GaButtonModule }, { kind: "ngmodule", type: OverlayModule }, { kind: "directive", type: i1$4.CdkConnectedOverlay, selector: "[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]", inputs: ["cdkConnectedOverlayOrigin", "cdkConnectedOverlayPositions", "cdkConnectedOverlayPositionStrategy", "cdkConnectedOverlayOffsetX", "cdkConnectedOverlayOffsetY", "cdkConnectedOverlayWidth", "cdkConnectedOverlayHeight", "cdkConnectedOverlayMinWidth", "cdkConnectedOverlayMinHeight", "cdkConnectedOverlayBackdropClass", "cdkConnectedOverlayPanelClass", "cdkConnectedOverlayViewportMargin", "cdkConnectedOverlayScrollStrategy", "cdkConnectedOverlayOpen", "cdkConnectedOverlayDisableClose", "cdkConnectedOverlayTransformOriginOn", "cdkConnectedOverlayHasBackdrop", "cdkConnectedOverlayLockPosition", "cdkConnectedOverlayFlexibleDimensions", "cdkConnectedOverlayGrowAfterOpen", "cdkConnectedOverlayPush", "cdkConnectedOverlayDisposeOnNavigation"], outputs: ["backdropClick", "positionChange", "attach", "detach", "overlayKeydown", "overlayOutsideClick"], exportAs: ["cdkConnectedOverlay"] }, { kind: "component", type: GaSelectDefaultValueComponent, selector: "ga-select-default-value" }] });
|
|
2741
|
+
], queries: [{ propertyName: "gaOptions", predicate: GaOptionComponent, descendants: true, read: GaOptionComponent, isSignal: true }, { propertyName: "cdkListbox", first: true, predicate: CdkListbox, descendants: true, isSignal: true }, { propertyName: "customSelectValue", first: true, predicate: GaSelectValueComponent, descendants: true, isSignal: true }], viewQueries: [{ propertyName: "inputSearch", first: true, predicate: ["inputSearch"], descendants: true, isSignal: true }, { propertyName: "content", first: true, predicate: ["ngContent"], descendants: true, read: ElementRef, isSignal: true }], hostDirectives: [{ directive: i1$4.CdkOverlayOrigin }, { directive: GaLabelledByFormFieldDirective }], ngImport: i0, template: "@if (leftIcon()) {\n <ga-icon [icon]=\"leftIcon()!\" />\n}\n\n<div class=\"ga-select__main-area\">\n @if (hasValue() && (!textValue() || multiple())) {\n @if (customSelectValue()) {\n <div class=\"ga-select__value\">\n <ng-content select=\"ga-select-value\" />\n </div>\n } @else {\n <ga-select-default-value />\n }\n } @else if (!searchable()) {\n <div class=\"ga-select__placeholder\">\n {{ placeholder() }}\n </div>\n }\n\n @if (searchable()) {\n <input\n #inputSearch\n type=\"text\"\n class=\"ga-select__input\"\n aria-autocomplete=\"list\"\n [value]=\"textValue()\"\n (input)=\"open(); textValue.set(inputSearch.value)\"\n (click)=\"open(); $event.stopPropagation()\"\n [attr.aria-expanded]=\"isOpen()\"\n [attr.aria-controls]=\"cdkListbox().id\"\n [attr.aria-activedescendant]=\"activeDescendantId()\"\n [placeholder]=\"hasValue() ? '' : placeholder()\"\n (keydown)=\"onInputKeyDown($event)\"\n tabindex=\"-1\"\n />\n }\n</div>\n\n<div class=\"ga-select__suffix\">\n <ga-icon [icon]=\"menuStatusIcon()\" class=\"ga-select__action-icon\" />\n</div>\n\n<ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayLockPosition\n [cdkConnectedOverlayOrigin]=\"overlayOrigin\"\n [cdkConnectedOverlayOpen]=\"isOpen()\"\n [cdkConnectedOverlayPositions]=\"positions\"\n [cdkConnectedOverlayScrollStrategy]=\"blockScrollStrategy\"\n (overlayOutsideClick)=\"close()\"\n (attach)=\"onOverlayAttach()\"\n (detach)=\"onOverlayDetach()\"\n>\n <ng-content select=\"ga-select-dropdown\" />\n</ng-template>\n", dependencies: [{ kind: "ngmodule", type: GaIconModule }, { kind: "component", type: GaIconComponent, selector: "ga-icon", inputs: ["icon", "size", "color", "strokeWidth"] }, { kind: "ngmodule", type: GaButtonModule }, { kind: "ngmodule", type: OverlayModule }, { kind: "directive", type: i1$4.CdkConnectedOverlay, selector: "[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]", inputs: ["cdkConnectedOverlayOrigin", "cdkConnectedOverlayPositions", "cdkConnectedOverlayPositionStrategy", "cdkConnectedOverlayOffsetX", "cdkConnectedOverlayOffsetY", "cdkConnectedOverlayWidth", "cdkConnectedOverlayHeight", "cdkConnectedOverlayMinWidth", "cdkConnectedOverlayMinHeight", "cdkConnectedOverlayBackdropClass", "cdkConnectedOverlayPanelClass", "cdkConnectedOverlayViewportMargin", "cdkConnectedOverlayScrollStrategy", "cdkConnectedOverlayOpen", "cdkConnectedOverlayDisableClose", "cdkConnectedOverlayTransformOriginOn", "cdkConnectedOverlayHasBackdrop", "cdkConnectedOverlayLockPosition", "cdkConnectedOverlayFlexibleDimensions", "cdkConnectedOverlayGrowAfterOpen", "cdkConnectedOverlayPush", "cdkConnectedOverlayDisposeOnNavigation"], outputs: ["backdropClick", "positionChange", "attach", "detach", "overlayKeydown", "overlayOutsideClick"], exportAs: ["cdkConnectedOverlay"] }, { kind: "component", type: GaSelectDefaultValueComponent, selector: "ga-select-default-value" }] });
|
|
2730
2742
|
}
|
|
2731
2743
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaSelectComponent, decorators: [{
|
|
2732
2744
|
type: Component,
|
|
@@ -2766,7 +2778,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImpor
|
|
|
2766
2778
|
'(keydown.arrowdown)': 'open(); $event.preventDefault()',
|
|
2767
2779
|
'(keydown.space)': 'open(); $event.preventDefault()',
|
|
2768
2780
|
'(keydown.enter)': 'open(); $event.preventDefault()',
|
|
2769
|
-
}, template: "@if (leftIcon()) {\n <ga-icon [icon]=\"leftIcon()!\" />\n}\n\n<div class=\"ga-select__main-area\">\n @if (hasValue() && (!textValue() || multiple())) {\n @if (customSelectValue()) {\n <div class=\"ga-select__value\">\n <ng-content select=\"ga-select-value\" />\n </div>\n } @else {\n <ga-select-default-value />\n }\n } @else if (!searchable()) {\n <div class=\"ga-select__placeholder\">\n {{ placeholder() }}\n </div>\n }\n\n @if (searchable()) {\n <input\n #inputSearch\n type=\"text\"\n class=\"ga-select__input\"\n aria-autocomplete=\"list\"\n [value]=\"textValue()\"\n (input)=\"open(); textValue.set(inputSearch.value)\"\n (click)=\"open(); $event.stopPropagation()\"\n [attr.aria-expanded]=\"isOpen()\"\n [attr.aria-controls]=\"cdkListbox().id\"\n [attr.aria-activedescendant]=\"activeDescendantId()\"\n [placeholder]=\"hasValue() ? '' : placeholder()\"\n (keydown)=\"onInputKeyDown($event)\"\n tabindex=\"-1\"\n />\n }\n</div>\n\n<div class=\"ga-select__suffix\">\n <ga-icon [icon]=\"menuStatusIcon()\" class=\"ga-select__action-icon\" />\n</div>\n\n<ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayLockPosition\n [cdkConnectedOverlayOrigin]=\"overlayOrigin\"\n [cdkConnectedOverlayOpen]=\"isOpen()\"\n [cdkConnectedOverlayPositions]=\"positions\"\n (overlayOutsideClick)=\"close()\"\n (attach)=\"onOverlayAttach()\"\n (detach)=\"onOverlayDetach()\"\n>\n <ng-content select=\"ga-select-dropdown\" />\n</ng-template>\n" }]
|
|
2781
|
+
}, template: "@if (leftIcon()) {\n <ga-icon [icon]=\"leftIcon()!\" />\n}\n\n<div class=\"ga-select__main-area\">\n @if (hasValue() && (!textValue() || multiple())) {\n @if (customSelectValue()) {\n <div class=\"ga-select__value\">\n <ng-content select=\"ga-select-value\" />\n </div>\n } @else {\n <ga-select-default-value />\n }\n } @else if (!searchable()) {\n <div class=\"ga-select__placeholder\">\n {{ placeholder() }}\n </div>\n }\n\n @if (searchable()) {\n <input\n #inputSearch\n type=\"text\"\n class=\"ga-select__input\"\n aria-autocomplete=\"list\"\n [value]=\"textValue()\"\n (input)=\"open(); textValue.set(inputSearch.value)\"\n (click)=\"open(); $event.stopPropagation()\"\n [attr.aria-expanded]=\"isOpen()\"\n [attr.aria-controls]=\"cdkListbox().id\"\n [attr.aria-activedescendant]=\"activeDescendantId()\"\n [placeholder]=\"hasValue() ? '' : placeholder()\"\n (keydown)=\"onInputKeyDown($event)\"\n tabindex=\"-1\"\n />\n }\n</div>\n\n<div class=\"ga-select__suffix\">\n <ga-icon [icon]=\"menuStatusIcon()\" class=\"ga-select__action-icon\" />\n</div>\n\n<ng-template\n cdkConnectedOverlay\n cdkConnectedOverlayLockPosition\n [cdkConnectedOverlayOrigin]=\"overlayOrigin\"\n [cdkConnectedOverlayOpen]=\"isOpen()\"\n [cdkConnectedOverlayPositions]=\"positions\"\n [cdkConnectedOverlayScrollStrategy]=\"blockScrollStrategy\"\n (overlayOutsideClick)=\"close()\"\n (attach)=\"onOverlayAttach()\"\n (detach)=\"onOverlayDetach()\"\n>\n <ng-content select=\"ga-select-dropdown\" />\n</ng-template>\n" }]
|
|
2770
2782
|
}], ctorParameters: () => [] });
|
|
2771
2783
|
|
|
2772
2784
|
class GaOptgroupComponent {
|
|
@@ -2848,6 +2860,7 @@ class GaSelectRequiredValidator extends RequiredValidator {
|
|
|
2848
2860
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaSelectRequiredValidator, decorators: [{
|
|
2849
2861
|
type: Directive,
|
|
2850
2862
|
args: [{
|
|
2863
|
+
// eslint-disable-next-line @angular-eslint/directive-selector
|
|
2851
2864
|
selector: `ga-select[required][formControlName], ga-select[required][formControl], ga-select[required][ngModel]`,
|
|
2852
2865
|
providers: [GA_SELECT_REQUIRED_VALIDATOR],
|
|
2853
2866
|
}]
|
|
@@ -3066,6 +3079,7 @@ class GaLinkDirective {
|
|
|
3066
3079
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: GaLinkDirective, decorators: [{
|
|
3067
3080
|
type: Component,
|
|
3068
3081
|
args: [{
|
|
3082
|
+
// eslint-disable-next-line @angular-eslint/component-selector
|
|
3069
3083
|
selector: 'a[gaLink], button[gaLink]',
|
|
3070
3084
|
template: `
|
|
3071
3085
|
@if (leadingIcon()) {
|