@i-cell/ids-angular 0.2.1 → 0.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -60,11 +60,18 @@ class IdsIconButtonComponent extends ComponentBaseWithDefaults {
60
60
  this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled", transform: coerceBooleanAttribute }] : [{ transform: coerceBooleanAttribute }]));
61
61
  this._icons = contentChildren(IdsIconComponent, ...(ngDevMode ? [{ debugName: "_icons" }] : []));
62
62
  this._parentOrSelfAppearance = computed(() => this._parent?.embeddedIconButtonAppearance() ?? this.appearance(), ...(ngDevMode ? [{ debugName: "_parentOrSelfAppearance" }] : []));
63
+ this._parentOrSelfSize = computed(() => {
64
+ const embeddedIconButtonSize = this._parent?.embeddedIconButtonSize;
65
+ return embeddedIconButtonSize ? embeddedIconButtonSize() : this.size();
66
+ }, ...(ngDevMode ? [{ debugName: "_parentOrSelfSize" }] : []));
63
67
  this._parentOrSelfVariant = computed(() => this._parent?.embeddedIconButtonVariant() ?? this.variant(), ...(ngDevMode ? [{ debugName: "_parentOrSelfVariant" }] : []));
64
- this._parentOrSelfDisabled = computed(() => this._parent?.disabled() ?? this.disabled(), ...(ngDevMode ? [{ debugName: "_parentOrSelfDisabled" }] : []));
68
+ this._parentOrSelfDisabled = computed(() => {
69
+ const parentDisabled = this._parent?.disabled;
70
+ return parentDisabled ? parentDisabled() : this.disabled();
71
+ }, ...(ngDevMode ? [{ debugName: "_parentOrSelfDisabled" }] : []));
65
72
  this._hostClasses = computed(() => this._getHostClasses([
66
73
  this._parentOrSelfAppearance(),
67
- this.size(),
74
+ this._parentOrSelfSize(),
68
75
  this._parentOrSelfVariant(),
69
76
  this.disabled() ? 'disabled' : null,
70
77
  ]), ...(ngDevMode ? [{ debugName: "_hostClasses" }] : []));
@@ -1 +1 @@
1
- {"version":3,"file":"i-cell-ids-angular-icon-button.mjs","sources":["../../../projects/widgets/icon-button/tokens/icon-button-parent.ts","../../../projects/widgets/icon-button/types/icon-button-appearance.type.ts","../../../projects/widgets/icon-button/types/icon-button-variant.type.ts","../../../projects/widgets/icon-button/icon-button-defaults.ts","../../../projects/widgets/icon-button/icon-button.component.ts","../../../projects/widgets/icon-button/icon-button.component.html","../../../projects/widgets/icon-button/i-cell-ids-angular-icon-button.ts"],"sourcesContent":["import { IdsIconButtonAppearanceType } from '../types/icon-button-appearance.type';\nimport { IdsIconButtonVariantType } from '../types/icon-button-variant.type';\n\nimport { InjectionToken, Signal } from '@angular/core';\n\nexport abstract class IdsIconButtonParent {\n public readonly embeddedIconButtonVariant!: Signal<IdsIconButtonVariantType>;\n public readonly embeddedIconButtonAppearance!: Signal<IdsIconButtonAppearanceType>;\n public readonly disabled!: Signal<boolean>;\n};\n\nexport const IDS_ICON_BUTTON_PARENT = new InjectionToken<IdsIconButtonParent>(\n 'IDS_ICON_BUTTON_PARENT',\n);\n","export const IdsIconButtonAppearance = {\n FILLED: 'filled',\n OUTLINED: 'outlined',\n STANDARD: 'standard',\n} as const;\n\nexport type IdsIconButtonAppearanceType = (typeof IdsIconButtonAppearance)[keyof typeof IdsIconButtonAppearance];\n","export const IdsIconButtonVariant = {\n PRIMARY: 'primary',\n SECONDARY: 'secondary',\n SURFACE: 'surface',\n BRAND: 'brand',\n LIGHT: 'light',\n DARK: 'dark',\n INFO: 'info',\n SUCCESS: 'success',\n WARNING: 'warning',\n ERROR: 'error',\n} as const;\n\nexport type IdsIconButtonVariantType = (typeof IdsIconButtonVariant)[keyof typeof IdsIconButtonVariant];\n\n","import { IdsIconButtonAppearance, IdsIconButtonAppearanceType } from './types/icon-button-appearance.type';\nimport { IdsIconButtonVariant, IdsIconButtonVariantType } from './types/icon-button-variant.type';\n\nimport { InjectionToken } from '@angular/core';\nimport { IdsSize, IdsSizeType } from '@i-cell/ids-angular/core';\n\nexport interface IdsIconButtonDefaultConfig {\n appearance?: IdsIconButtonAppearanceType,\n size?: IdsSizeType,\n variant?: IdsIconButtonVariantType,\n}\n\nexport const IDS_ICON_BUTTON_DEFAULT_CONFIG = new InjectionToken<IdsIconButtonDefaultConfig>(\n 'IDS_ICON_BUTTON_DEFAULT_CONFIG',\n {\n providedIn: 'root',\n factory: IDS_ICON_BUTTON_DEFAULT_CONFIG_FACTORY,\n },\n);\n\nexport function IDS_ICON_BUTTON_DEFAULT_CONFIG_FACTORY(): Required<IdsIconButtonDefaultConfig> {\n return {\n appearance: IdsIconButtonAppearance.FILLED,\n size: IdsSize.COMPACT,\n variant: IdsIconButtonVariant.PRIMARY,\n };\n}\n\n","import { IDS_ICON_BUTTON_DEFAULT_CONFIG, IDS_ICON_BUTTON_DEFAULT_CONFIG_FACTORY, IdsIconButtonDefaultConfig } from './icon-button-defaults';\nimport { IDS_ICON_BUTTON_PARENT } from './tokens/icon-button-parent';\nimport { IdsIconButtonAppearanceType } from './types/icon-button-appearance.type';\nimport { IdsIconButtonVariantType } from './types/icon-button-variant.type';\n\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n ViewEncapsulation,\n computed,\n contentChildren,\n effect,\n inject,\n input,\n} from '@angular/core';\nimport { RouterLink } from '@angular/router';\nimport {\n ComponentBaseWithDefaults,\n IdsSizeType,\n coerceBooleanAttribute,\n} from '@i-cell/ids-angular/core';\nimport { IdsIconComponent } from '@i-cell/ids-angular/icon';\n\nconst defaultConfig = IDS_ICON_BUTTON_DEFAULT_CONFIG_FACTORY();\n\n@Component({\n selector: 'button[idsIconButton], a[idsIconButton]',\n imports: [],\n templateUrl: './icon-button.component.html',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[attr.disabled]': '_parentOrSelfDisabled() ? \"\" : null',\n '[attr.aria-disabled]': '_parentOrSelfDisabled()',\n },\n})\nexport class IdsIconButtonComponent extends ComponentBaseWithDefaults<IdsIconButtonDefaultConfig> {\n protected override get _hostName(): string {\n return 'icon-button';\n }\n\n private readonly _parent = inject(IDS_ICON_BUTTON_PARENT, { optional: true });\n private _hostElement = inject<ElementRef<HTMLElement>>(ElementRef<HTMLElement>).nativeElement;\n private _routerLink = inject(RouterLink, { optional: true, self: true });\n\n protected readonly _defaultConfig = this._getDefaultConfig(defaultConfig, IDS_ICON_BUTTON_DEFAULT_CONFIG);\n\n public appearance = input<IdsIconButtonAppearanceType>(this._defaultConfig.appearance);\n public size = input<IdsSizeType>(this._defaultConfig.size);\n public variant = input<IdsIconButtonVariantType>(this._defaultConfig.variant);\n public disabled = input(false, { transform: coerceBooleanAttribute });\n\n protected _icons = contentChildren(IdsIconComponent);\n\n private _parentOrSelfAppearance = computed(() => this._parent?.embeddedIconButtonAppearance() ?? this.appearance());\n private _parentOrSelfVariant = computed(() => this._parent?.embeddedIconButtonVariant() ?? this.variant());\n private _parentOrSelfDisabled = computed(() => this._parent?.disabled() ?? this.disabled());\n protected _hostClasses = computed(() => this._getHostClasses([\n this._parentOrSelfAppearance(),\n this.size(),\n this._parentOrSelfVariant(),\n this.disabled() ? 'disabled' : null,\n ]));\n\n private get _buttonType(): string | null {\n return this._hostElement.tagName === 'BUTTON' ? 'button' : null;\n }\n\n constructor() {\n super();\n\n effect(() => {\n if (this._buttonType) {\n return;\n }\n\n const link = this._hostElement as HTMLAnchorElement;\n\n if (this.disabled()) {\n this._disableLink(link);\n } else {\n this._enableLink(link);\n }\n });\n }\n\n private _disableLink(link: HTMLAnchorElement): void {\n if (!this._routerLink) {\n link.setAttribute('data-href', link.href);\n }\n link.removeAttribute('href');\n }\n\n private _enableLink(link: HTMLAnchorElement): void {\n const prevHref = this._routerLink?.href ?? link.getAttribute('data-href') ?? '';\n\n if (prevHref) {\n link.href = prevHref;\n link.removeAttribute('data-href');\n }\n }\n}\n","@if (_icons().length) {\n <ng-content select=\"ids-icon\" />\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;MAKsB,mBAAmB,CAAA;AAIxC;AAAA;MAEY,sBAAsB,GAAG,IAAI,cAAc,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AC,IAAI,EAAA,eAAA,EACpB,uBAAuB,CAAC,MAAM,EAAA,IAAA,EACzC;AACJ,wBAAA,iBAAiB,EAAE,qCAAqC;AACxD,wBAAA,sBAAsB,EAAE,yBAAyB;AAClD,qBAAA,EAAA,QAAA,EAAA,oEAAA,EAAA;;;AEnCH;;AAEG;;;;"}
1
+ {"version":3,"file":"i-cell-ids-angular-icon-button.mjs","sources":["../../../projects/widgets/icon-button/tokens/icon-button-parent.ts","../../../projects/widgets/icon-button/types/icon-button-appearance.type.ts","../../../projects/widgets/icon-button/types/icon-button-variant.type.ts","../../../projects/widgets/icon-button/icon-button-defaults.ts","../../../projects/widgets/icon-button/icon-button.component.ts","../../../projects/widgets/icon-button/icon-button.component.html","../../../projects/widgets/icon-button/i-cell-ids-angular-icon-button.ts"],"sourcesContent":["import { IdsIconButtonAppearanceType } from '../types/icon-button-appearance.type';\nimport { IdsIconButtonVariantType } from '../types/icon-button-variant.type';\n\nimport { InjectionToken, Signal } from '@angular/core';\n\nexport abstract class IdsIconButtonParent {\n public readonly embeddedIconButtonVariant!: Signal<IdsIconButtonVariantType>;\n public readonly embeddedIconButtonAppearance!: Signal<IdsIconButtonAppearanceType>;\n public readonly disabled!: Signal<boolean>;\n};\n\nexport const IDS_ICON_BUTTON_PARENT = new InjectionToken<IdsIconButtonParent>(\n 'IDS_ICON_BUTTON_PARENT',\n);\n","export const IdsIconButtonAppearance = {\n FILLED: 'filled',\n OUTLINED: 'outlined',\n STANDARD: 'standard',\n} as const;\n\nexport type IdsIconButtonAppearanceType = (typeof IdsIconButtonAppearance)[keyof typeof IdsIconButtonAppearance];\n","export const IdsIconButtonVariant = {\n PRIMARY: 'primary',\n SECONDARY: 'secondary',\n SURFACE: 'surface',\n BRAND: 'brand',\n LIGHT: 'light',\n DARK: 'dark',\n INFO: 'info',\n SUCCESS: 'success',\n WARNING: 'warning',\n ERROR: 'error',\n} as const;\n\nexport type IdsIconButtonVariantType = (typeof IdsIconButtonVariant)[keyof typeof IdsIconButtonVariant];\n\n","import { IdsIconButtonAppearance, IdsIconButtonAppearanceType } from './types/icon-button-appearance.type';\nimport { IdsIconButtonVariant, IdsIconButtonVariantType } from './types/icon-button-variant.type';\n\nimport { InjectionToken } from '@angular/core';\nimport { IdsSize, IdsSizeType } from '@i-cell/ids-angular/core';\n\nexport interface IdsIconButtonDefaultConfig {\n appearance?: IdsIconButtonAppearanceType,\n size?: IdsSizeType,\n variant?: IdsIconButtonVariantType,\n}\n\nexport const IDS_ICON_BUTTON_DEFAULT_CONFIG = new InjectionToken<IdsIconButtonDefaultConfig>(\n 'IDS_ICON_BUTTON_DEFAULT_CONFIG',\n {\n providedIn: 'root',\n factory: IDS_ICON_BUTTON_DEFAULT_CONFIG_FACTORY,\n },\n);\n\nexport function IDS_ICON_BUTTON_DEFAULT_CONFIG_FACTORY(): Required<IdsIconButtonDefaultConfig> {\n return {\n appearance: IdsIconButtonAppearance.FILLED,\n size: IdsSize.COMPACT,\n variant: IdsIconButtonVariant.PRIMARY,\n };\n}\n\n","import { IDS_ICON_BUTTON_DEFAULT_CONFIG, IDS_ICON_BUTTON_DEFAULT_CONFIG_FACTORY, IdsIconButtonDefaultConfig } from './icon-button-defaults';\nimport { IDS_ICON_BUTTON_PARENT } from './tokens/icon-button-parent';\nimport { IdsIconButtonAppearanceType } from './types/icon-button-appearance.type';\nimport { IdsIconButtonVariantType } from './types/icon-button-variant.type';\n\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n ViewEncapsulation,\n computed,\n contentChildren,\n effect,\n inject,\n input,\n} from '@angular/core';\nimport { RouterLink } from '@angular/router';\nimport {\n ComponentBaseWithDefaults,\n IdsSizeType,\n coerceBooleanAttribute,\n} from '@i-cell/ids-angular/core';\nimport { IdsIconComponent } from '@i-cell/ids-angular/icon';\n\nconst defaultConfig = IDS_ICON_BUTTON_DEFAULT_CONFIG_FACTORY();\n\n@Component({\n selector: 'button[idsIconButton], a[idsIconButton]',\n imports: [],\n templateUrl: './icon-button.component.html',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[attr.disabled]': '_parentOrSelfDisabled() ? \"\" : null',\n '[attr.aria-disabled]': '_parentOrSelfDisabled()',\n },\n})\nexport class IdsIconButtonComponent extends ComponentBaseWithDefaults<IdsIconButtonDefaultConfig> {\n protected override get _hostName(): string {\n return 'icon-button';\n }\n\n private readonly _parent = inject(IDS_ICON_BUTTON_PARENT, { optional: true });\n private _hostElement = inject<ElementRef<HTMLElement>>(ElementRef<HTMLElement>).nativeElement;\n private _routerLink = inject(RouterLink, { optional: true, self: true });\n\n protected readonly _defaultConfig = this._getDefaultConfig(defaultConfig, IDS_ICON_BUTTON_DEFAULT_CONFIG);\n\n public appearance = input<IdsIconButtonAppearanceType>(this._defaultConfig.appearance);\n public size = input<IdsSizeType>(this._defaultConfig.size);\n public variant = input<IdsIconButtonVariantType>(this._defaultConfig.variant);\n public disabled = input(false, { transform: coerceBooleanAttribute });\n\n protected _icons = contentChildren(IdsIconComponent);\n\n private _parentOrSelfAppearance = computed(() => this._parent?.embeddedIconButtonAppearance() ?? this.appearance());\n private _parentOrSelfSize = computed(() => {\n const embeddedIconButtonSize = this._parent?.embeddedIconButtonSize;\n return embeddedIconButtonSize ? embeddedIconButtonSize() : this.size();\n });\n\n private _parentOrSelfVariant = computed(() => this._parent?.embeddedIconButtonVariant() ?? this.variant());\n private _parentOrSelfDisabled = computed(() => {\n const parentDisabled = this._parent?.disabled;\n return parentDisabled ? parentDisabled() : this.disabled();\n });\n\n protected _hostClasses = computed(() => this._getHostClasses([\n this._parentOrSelfAppearance(),\n this._parentOrSelfSize(),\n this._parentOrSelfVariant(),\n this.disabled() ? 'disabled' : null,\n ]));\n\n private get _buttonType(): string | null {\n return this._hostElement.tagName === 'BUTTON' ? 'button' : null;\n }\n\n constructor() {\n super();\n\n effect(() => {\n if (this._buttonType) {\n return;\n }\n\n const link = this._hostElement as HTMLAnchorElement;\n\n if (this.disabled()) {\n this._disableLink(link);\n } else {\n this._enableLink(link);\n }\n });\n }\n\n private _disableLink(link: HTMLAnchorElement): void {\n if (!this._routerLink) {\n link.setAttribute('data-href', link.href);\n }\n link.removeAttribute('href');\n }\n\n private _enableLink(link: HTMLAnchorElement): void {\n const prevHref = this._routerLink?.href ?? link.getAttribute('data-href') ?? '';\n\n if (prevHref) {\n link.href = prevHref;\n link.removeAttribute('data-href');\n }\n }\n}\n","@if (_icons().length) {\n <ng-content select=\"ids-icon\" />\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;MAKsB,mBAAmB,CAAA;AAIxC;AAAA;MAEY,sBAAsB,GAAG,IAAI,cAAc,CACtD,wBAAwB;;ACZnB,MAAM,uBAAuB,GAAG;AACrC,IAAA,MAAM,EAAE,QAAQ;AAChB,IAAA,QAAQ,EAAE,UAAU;AACpB,IAAA,QAAQ,EAAE,UAAU;;;ACHf,MAAM,oBAAoB,GAAG;AAClC,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,SAAS,EAAE,WAAW;AACtB,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,KAAK,EAAE,OAAO;AACd,IAAA,KAAK,EAAE,OAAO;AACd,IAAA,IAAI,EAAE,MAAM;AACZ,IAAA,IAAI,EAAE,MAAM;AACZ,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,KAAK,EAAE,OAAO;;;MCEH,8BAA8B,GAAG,IAAI,cAAc,CAC9D,gCAAgC,EAChC;AACE,IAAA,UAAU,EAAE,MAAM;AAClB,IAAA,OAAO,EAAE,sCAAsC;AAChD,CAAA;SAGa,sCAAsC,GAAA;IACpD,OAAO;QACL,UAAU,EAAE,uBAAuB,CAAC,MAAM;QAC1C,IAAI,EAAE,OAAO,CAAC,OAAO;QACrB,OAAO,EAAE,oBAAoB,CAAC,OAAO;KACtC;AACH;;ACFA,MAAM,aAAa,GAAG,sCAAsC,EA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EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,QAAA,EAAA,EAAA,iBAAA,EAAA,UAAA,EAAA,UAAA,EAAA,UAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,eAAA,EAAA,uCAAA,EAAA,oBAAA,EAAA,yBAAA,EAAA,EAAA,EAAA,OAAA,EAAA,CAAA,EAAA,YAAA,EAAA,QAAA,EAAA,SAAA,EAgBE,gBAAgB,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,ECrDrD,oEAGA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;;2FDkCa,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBAXlC,SAAS;+BACE,yCAAyC,EAAA,OAAA,EAC1C,EAAE,EAAA,aAAA,EAEI,iBAAiB,CAAC,IAAI,EAAA,eAAA,EACpB,uBAAuB,CAAC,MAAM,EAAA,IAAA,EACzC;AACJ,wBAAA,iBAAiB,EAAE,qCAAqC;AACxD,wBAAA,sBAAsB,EAAE,yBAAyB;AAClD,qBAAA,EAAA,QAAA,EAAA,oEAAA,EAAA;;;AEnCH;;AAEG;;;;"}
@@ -0,0 +1,375 @@
1
+ import * as i0 from '@angular/core';
2
+ import { InjectionToken, input, computed, contentChildren, inject, contentChild, TemplateRef, Component } from '@angular/core';
3
+ import { IdsSize, coerceBooleanAttribute, ComponentBaseWithDefaults } from '@i-cell/ids-angular/core';
4
+ import { trigger, transition, style, animate } from '@angular/animations';
5
+ import { NgTemplateOutlet } from '@angular/common';
6
+ import { Router } from '@angular/router';
7
+ import { IdsIconComponent } from '@i-cell/ids-angular/icon';
8
+ import { IdsIconButtonComponent, IDS_ICON_BUTTON_PARENT } from '@i-cell/ids-angular/icon-button';
9
+
10
+ const IdsSideNavVariant = {
11
+ SURFACE: 'surface',
12
+ LIGHT: 'light',
13
+ };
14
+
15
+ const IdsSideNavAppearance = {
16
+ STANDARD: 'standard',
17
+ };
18
+
19
+ const IDS_SIDE_NAV_DEFAULT_CONFIG = new InjectionToken('IDS_SIDE_NAV_DEFAULT_CONFIG', {
20
+ providedIn: 'root',
21
+ factory: IDS_SIDE_NAV_DEFAULT_CONFIG_FACTORY,
22
+ });
23
+ function IDS_SIDE_NAV_DEFAULT_CONFIG_FACTORY() {
24
+ return {
25
+ appearance: IdsSideNavAppearance.STANDARD,
26
+ size: IdsSize.COMPACT,
27
+ variant: IdsSideNavVariant.SURFACE,
28
+ hasActiveIndicator: false,
29
+ hasLabel: true,
30
+ };
31
+ }
32
+
33
+ const IDS_SIDE_NAV_PARENT = new InjectionToken('IDS_SIDE_NAV_PARENT');
34
+
35
+ /**
36
+ * Side navigation item
37
+ * - it can be a single list element or an expandable list element, containing another list of elements
38
+ * - it can be used with selectors like `ids-side-nav-item` or `li[idsSideNavItem]`
39
+ * - children can be provided with content projection:
40
+ * - either project `ids-side-nav-item` elements
41
+ * - or list elements as `<li>` elements in an ng-template, marked with `idsSideNavItemChildren` variable
42
+ */
43
+ class IdsSideNavItemComponent {
44
+ constructor() {
45
+ this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled", transform: (value) => coerceBooleanAttribute(value) }] : [{ transform: (value) => coerceBooleanAttribute(value) }]));
46
+ this.label = input.required(...(ngDevMode ? [{ debugName: "label" }] : []));
47
+ this.target = input('', ...(ngDevMode ? [{ debugName: "target" }] : []));
48
+ this.templateChildren = input(...(ngDevMode ? [undefined, { debugName: "templateChildren" }] : []));
49
+ this._active = computed(() => this._router.isActive(this.target(), { paths: 'exact', queryParams: 'exact', fragment: 'ignored', matrixParams: 'ignored' }), ...(ngDevMode ? [{ debugName: "_active" }] : []));
50
+ this._expandable = computed(() => this._contentChildren().length > 0 || this._contentTemplate(), ...(ngDevMode ? [{ debugName: "_expandable" }] : []));
51
+ this._expanded = false;
52
+ this._iconLeading = contentChildren('[icon-leading]', ...(ngDevMode ? [{ debugName: "_iconLeading" }] : []));
53
+ this._iconTrailing = contentChildren('[icon-trailing]', ...(ngDevMode ? [{ debugName: "_iconTrailing" }] : []));
54
+ this._parent = inject(IDS_SIDE_NAV_PARENT, { optional: true });
55
+ this._contentTemplate = contentChild('idsSideNavItemChildren', ...(ngDevMode ? [{ debugName: "_contentTemplate", read: TemplateRef }] : [{ read: TemplateRef }]));
56
+ this._contentChildren = contentChildren(IdsSideNavItemComponent, ...(ngDevMode ? [{ debugName: "_contentChildren" }] : []));
57
+ this._router = inject(Router);
58
+ }
59
+ _onClick(event) {
60
+ if (this.disabled()) {
61
+ return;
62
+ }
63
+ if ([
64
+ 'button',
65
+ 'ids-icon',
66
+ ].includes(event.target.localName)) {
67
+ this._toggle();
68
+ }
69
+ else {
70
+ this._navigate();
71
+ }
72
+ }
73
+ _onKeyDown(event) {
74
+ if (this.disabled()) {
75
+ return;
76
+ }
77
+ if ([
78
+ 'Enter',
79
+ 'Space',
80
+ ].includes(event.code)) {
81
+ event.preventDefault();
82
+ if (event.target.localName === 'button') {
83
+ this._toggle();
84
+ }
85
+ else {
86
+ this._navigate();
87
+ }
88
+ }
89
+ else if ([
90
+ 'ArrowUp',
91
+ 'ArrowDown',
92
+ 'Escape',
93
+ ].includes(event.code)) {
94
+ event.preventDefault();
95
+ event.stopImmediatePropagation();
96
+ this._toggle();
97
+ }
98
+ }
99
+ _toggle() {
100
+ if (this._expandable()) {
101
+ this._expanded = !this._expanded;
102
+ }
103
+ }
104
+ _navigate() {
105
+ const target = this.target();
106
+ if (target) {
107
+ this._router.navigateByUrl(target);
108
+ }
109
+ }
110
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.7", ngImport: i0, type: IdsSideNavItemComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
111
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.7", type: IdsSideNavItemComponent, isStandalone: true, selector: "ids-side-nav-item, li[idsSideNavItem]", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null }, target: { classPropertyName: "target", publicName: "target", isSignal: true, isRequired: false, transformFunction: null }, templateChildren: { classPropertyName: "templateChildren", publicName: "templateChildren", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class.ids-side-nav-item-expandable": "_expandable()", "role": "_expandable() ? \"group\" : \"treeitem\"" }, classAttribute: "ids-side-nav-item" }, queries: [{ propertyName: "_iconLeading", predicate: ["[icon-leading]"], isSignal: true }, { propertyName: "_iconTrailing", predicate: ["[icon-trailing]"], isSignal: true }, { propertyName: "_contentTemplate", first: true, predicate: ["idsSideNavItemChildren"], descendants: true, read: TemplateRef, isSignal: true }, { propertyName: "_contentChildren", predicate: IdsSideNavItemComponent, isSignal: true }], ngImport: i0, template: `
112
+ <a
113
+ [class.ids-side-nav-item-single]="!_expandable()"
114
+ [class.ids-side-nav-item-expandable-summary]="_expandable()"
115
+ [attr.tabindex]="!disabled() ? 0 : null"
116
+ [attr.disabled]="disabled() ? '' : null"
117
+ [attr.is-active]="_active() ? '' : null"
118
+ [attr.is-active-indicator]="_active() && _parent?.hasActiveIndicator() ? '' : null"
119
+ [attr.aria-disabled]="disabled() ? '' : null"
120
+ [attr.aria-current]="_active()"
121
+ [attr.aria-expanded]="!_expandable() ? null : _expanded ? 'true' : 'false'"
122
+ [attr.aria-label]="label()"
123
+ (keydown)="_onKeyDown($event)"
124
+ (click)="_onClick($event)"
125
+ >
126
+ @if (_iconLeading()) {
127
+ <ng-content select="[icon-leading]" />
128
+ }
129
+ @if (_parent?.hasLabel()) {
130
+ <span class="ids-side-nav-item-label">{{ label() }}</span>
131
+ }
132
+ @if (_iconTrailing()) {
133
+ <ng-content select="[icon-trailing]" />
134
+ }
135
+ @if (_expandable()) {
136
+ <button idsIconButton type="button" [disabled]="disabled()">
137
+ <ids-icon aria-hidden="true" alt="" [fontIcon]="_expanded ? 'chevron-up' : 'chevron-down'" />
138
+ </button>
139
+ }
140
+ </a>
141
+ @if (_expandable() && _expanded) {
142
+ <ul @enterLeave class="ids-side-nav-item-expandable-submenu">
143
+ <ng-content select="ids-side-nav-item,[idsSideNavItem]" />
144
+ <ng-container *ngTemplateOutlet="_contentTemplate()" />
145
+ </ul>
146
+ }
147
+ <ng-content select="ng-template"/>
148
+ `, isInline: true, dependencies: [{ kind: "component", type: IdsIconComponent, selector: "ids-icon", inputs: ["size", "sizeCollection", "variant", "fontIcon", "svgIcon", "aria-hidden"] }, { kind: "component", type: IdsIconButtonComponent, selector: "button[idsIconButton], a[idsIconButton]", inputs: ["appearance", "size", "variant", "disabled"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], animations: [
149
+ trigger('enterLeave', [
150
+ transition(':enter', [
151
+ style({ height: 0, opacity: 0 }),
152
+ animate('150ms ease-out', style({ height: '*' })),
153
+ animate('150ms ease-in', style({ opacity: 1 })),
154
+ ]),
155
+ transition(':leave', [
156
+ animate('150ms ease-out', style({ opacity: 0 })),
157
+ animate('150ms ease-in', style({ height: 0 })),
158
+ ]),
159
+ ]),
160
+ ] }); }
161
+ }
162
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.7", ngImport: i0, type: IdsSideNavItemComponent, decorators: [{
163
+ type: Component,
164
+ args: [{
165
+ selector: 'ids-side-nav-item, li[idsSideNavItem]',
166
+ imports: [
167
+ IdsIconComponent,
168
+ IdsIconButtonComponent,
169
+ NgTemplateOutlet,
170
+ ],
171
+ template: `
172
+ <a
173
+ [class.ids-side-nav-item-single]="!_expandable()"
174
+ [class.ids-side-nav-item-expandable-summary]="_expandable()"
175
+ [attr.tabindex]="!disabled() ? 0 : null"
176
+ [attr.disabled]="disabled() ? '' : null"
177
+ [attr.is-active]="_active() ? '' : null"
178
+ [attr.is-active-indicator]="_active() && _parent?.hasActiveIndicator() ? '' : null"
179
+ [attr.aria-disabled]="disabled() ? '' : null"
180
+ [attr.aria-current]="_active()"
181
+ [attr.aria-expanded]="!_expandable() ? null : _expanded ? 'true' : 'false'"
182
+ [attr.aria-label]="label()"
183
+ (keydown)="_onKeyDown($event)"
184
+ (click)="_onClick($event)"
185
+ >
186
+ @if (_iconLeading()) {
187
+ <ng-content select="[icon-leading]" />
188
+ }
189
+ @if (_parent?.hasLabel()) {
190
+ <span class="ids-side-nav-item-label">{{ label() }}</span>
191
+ }
192
+ @if (_iconTrailing()) {
193
+ <ng-content select="[icon-trailing]" />
194
+ }
195
+ @if (_expandable()) {
196
+ <button idsIconButton type="button" [disabled]="disabled()">
197
+ <ids-icon aria-hidden="true" alt="" [fontIcon]="_expanded ? 'chevron-up' : 'chevron-down'" />
198
+ </button>
199
+ }
200
+ </a>
201
+ @if (_expandable() && _expanded) {
202
+ <ul @enterLeave class="ids-side-nav-item-expandable-submenu">
203
+ <ng-content select="ids-side-nav-item,[idsSideNavItem]" />
204
+ <ng-container *ngTemplateOutlet="_contentTemplate()" />
205
+ </ul>
206
+ }
207
+ <ng-content select="ng-template"/>
208
+ `,
209
+ host: {
210
+ class: 'ids-side-nav-item',
211
+ '[class.ids-side-nav-item-expandable]': '_expandable()',
212
+ '[role]': '_expandable() ? "group" : "treeitem"',
213
+ },
214
+ animations: [
215
+ trigger('enterLeave', [
216
+ transition(':enter', [
217
+ style({ height: 0, opacity: 0 }),
218
+ animate('150ms ease-out', style({ height: '*' })),
219
+ animate('150ms ease-in', style({ opacity: 1 })),
220
+ ]),
221
+ transition(':leave', [
222
+ animate('150ms ease-out', style({ opacity: 0 })),
223
+ animate('150ms ease-in', style({ height: 0 })),
224
+ ]),
225
+ ]),
226
+ ],
227
+ }]
228
+ }] });
229
+
230
+ /**
231
+ * Side navigation (section) title
232
+ * - title of the navigation section
233
+ * - it can be used with selectors like `ids-side-nav-title` or `li[idsSideNavTitle]`
234
+ * - leading and trailing icons should be projected, label is bound by input
235
+ */
236
+ class IdsSideNavTitleComponent {
237
+ constructor() {
238
+ this.label = input.required(...(ngDevMode ? [{ debugName: "label" }] : []));
239
+ this._iconLeading = contentChildren('[icon-leading]', ...(ngDevMode ? [{ debugName: "_iconLeading" }] : []));
240
+ this._iconTrailing = contentChildren('[icon-trailing]', ...(ngDevMode ? [{ debugName: "_iconTrailing" }] : []));
241
+ this._parent = inject(IDS_SIDE_NAV_PARENT, { optional: true });
242
+ }
243
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.7", ngImport: i0, type: IdsSideNavTitleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
244
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.7", type: IdsSideNavTitleComponent, isStandalone: true, selector: "ids-side-nav-title, li[idsSideNavTitle]", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null } }, host: { attributes: { "role": "treeitem" }, classAttribute: "ids-side-nav-title" }, queries: [{ propertyName: "_iconLeading", predicate: ["[icon-leading]"], isSignal: true }, { propertyName: "_iconTrailing", predicate: ["[icon-trailing]"], isSignal: true }], ngImport: i0, template: `
245
+ @if (_iconLeading()) {
246
+ <ng-content select="[icon-leading]" />
247
+ }
248
+ @if (_parent?.hasLabel()) {
249
+ <span class="ids-side-nav-title-label">{{ label() }}</span>
250
+ }
251
+ @if (_iconTrailing()) {
252
+ <ng-content select="[icon-trailing]" />
253
+ }
254
+ `, isInline: true }); }
255
+ }
256
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.7", ngImport: i0, type: IdsSideNavTitleComponent, decorators: [{
257
+ type: Component,
258
+ args: [{
259
+ selector: 'ids-side-nav-title, li[idsSideNavTitle]',
260
+ imports: [],
261
+ template: `
262
+ @if (_iconLeading()) {
263
+ <ng-content select="[icon-leading]" />
264
+ }
265
+ @if (_parent?.hasLabel()) {
266
+ <span class="ids-side-nav-title-label">{{ label() }}</span>
267
+ }
268
+ @if (_iconTrailing()) {
269
+ <ng-content select="[icon-trailing]" />
270
+ }
271
+ `,
272
+ host: {
273
+ class: 'ids-side-nav-title',
274
+ role: 'treeitem',
275
+ },
276
+ }]
277
+ }] });
278
+
279
+ /**
280
+ * Side navigation section
281
+ * - section wrapper inside the navigation
282
+ * - it can be used with selectors like `ids-side-nav-section` or `li[idsSideNavSection]`
283
+ * - content should be projected
284
+ */
285
+ class IdsSideNavSectionComponent {
286
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.7", ngImport: i0, type: IdsSideNavSectionComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
287
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.1.7", type: IdsSideNavSectionComponent, isStandalone: true, selector: "ids-side-nav-section, ul[idsSideNavSection]", host: { attributes: { "role": "tree" }, classAttribute: "ids-side-nav-section" }, ngImport: i0, template: '<ng-content />', isInline: true }); }
288
+ }
289
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.7", ngImport: i0, type: IdsSideNavSectionComponent, decorators: [{
290
+ type: Component,
291
+ args: [{
292
+ selector: 'ids-side-nav-section, ul[idsSideNavSection]',
293
+ imports: [],
294
+ template: '<ng-content />',
295
+ host: {
296
+ class: 'ids-side-nav-section',
297
+ role: 'tree',
298
+ },
299
+ }]
300
+ }] });
301
+
302
+ const defaultConfig = IDS_SIDE_NAV_DEFAULT_CONFIG_FACTORY();
303
+ /**
304
+ * Side navigation
305
+ * - wrapper element for side navigation elements (sections, then title and items as part of section)
306
+ * - content should be projected
307
+ */
308
+ class IdsSideNavComponent extends ComponentBaseWithDefaults {
309
+ constructor() {
310
+ super(...arguments);
311
+ this._defaultConfig = this._getDefaultConfig(defaultConfig, IDS_SIDE_NAV_DEFAULT_CONFIG);
312
+ this.appearance = input(this._defaultConfig.appearance, ...(ngDevMode ? [{ debugName: "appearance" }] : []));
313
+ this.size = input(this._defaultConfig.size, ...(ngDevMode ? [{ debugName: "size" }] : []));
314
+ this.variant = input(this._defaultConfig.variant, ...(ngDevMode ? [{ debugName: "variant" }] : []));
315
+ this.hasLabel = input(coerceBooleanAttribute(this._defaultConfig.hasLabel), ...(ngDevMode ? [{ debugName: "hasLabel" }] : []));
316
+ this.hasActiveIndicator = input(coerceBooleanAttribute(this._defaultConfig.hasActiveIndicator), ...(ngDevMode ? [{ debugName: "hasActiveIndicator" }] : []));
317
+ this.embeddedIconButtonAppearance = computed(() => this.appearance(), ...(ngDevMode ? [{ debugName: "embeddedIconButtonAppearance" }] : []));
318
+ this.embeddedIconButtonVariant = computed(() => this.variant(), ...(ngDevMode ? [{ debugName: "embeddedIconButtonVariant" }] : []));
319
+ this.embeddedIconButtonSize = computed(() => {
320
+ switch (this.size()) {
321
+ // NOTE: SPACIOUS icon button size sticks out of side-nav item, size need to be adjusted
322
+ case IdsSize.SPACIOUS:
323
+ return IdsSize.COMFORTABLE;
324
+ default:
325
+ return this.size();
326
+ }
327
+ }, ...(ngDevMode ? [{ debugName: "embeddedIconButtonSize" }] : []));
328
+ this._hostClasses = computed(() => this._getHostClasses([
329
+ this.appearance(),
330
+ this.variant(),
331
+ this.size(),
332
+ ]), ...(ngDevMode ? [{ debugName: "_hostClasses" }] : []));
333
+ }
334
+ get _hostName() {
335
+ return 'side-nav';
336
+ }
337
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.7", ngImport: i0, type: IdsSideNavComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
338
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.1.7", type: IdsSideNavComponent, isStandalone: true, selector: "nav[idsSideNav]", inputs: { appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, hasLabel: { classPropertyName: "hasLabel", publicName: "hasLabel", isSignal: true, isRequired: false, transformFunction: null }, hasActiveIndicator: { classPropertyName: "hasActiveIndicator", publicName: "hasActiveIndicator", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "ids-side-nav" }, providers: [
339
+ {
340
+ provide: IDS_ICON_BUTTON_PARENT,
341
+ useExisting: IdsSideNavComponent,
342
+ },
343
+ {
344
+ provide: IDS_SIDE_NAV_PARENT,
345
+ useExisting: IdsSideNavComponent,
346
+ },
347
+ ], usesInheritance: true, ngImport: i0, template: '<ng-content/>', isInline: true }); }
348
+ }
349
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.7", ngImport: i0, type: IdsSideNavComponent, decorators: [{
350
+ type: Component,
351
+ args: [{
352
+ selector: 'nav[idsSideNav]',
353
+ template: '<ng-content/>',
354
+ host: {
355
+ class: 'ids-side-nav',
356
+ },
357
+ providers: [
358
+ {
359
+ provide: IDS_ICON_BUTTON_PARENT,
360
+ useExisting: IdsSideNavComponent,
361
+ },
362
+ {
363
+ provide: IDS_SIDE_NAV_PARENT,
364
+ useExisting: IdsSideNavComponent,
365
+ },
366
+ ],
367
+ }]
368
+ }] });
369
+
370
+ /**
371
+ * Generated bundle index. Do not edit.
372
+ */
373
+
374
+ export { IDS_SIDE_NAV_DEFAULT_CONFIG, IDS_SIDE_NAV_DEFAULT_CONFIG_FACTORY, IdsSideNavAppearance, IdsSideNavComponent, IdsSideNavItemComponent, IdsSideNavSectionComponent, IdsSideNavTitleComponent, IdsSideNavVariant };
375
+ //# sourceMappingURL=i-cell-ids-angular-side-nav.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"i-cell-ids-angular-side-nav.mjs","sources":["../../../projects/widgets/side-nav/types/side-nav-variant.type.ts","../../../projects/widgets/side-nav/types/side-nav-appearance.type.ts","../../../projects/widgets/side-nav/side-nav-defaults.ts","../../../projects/widgets/side-nav/tokens/ids-side-nav-parent.ts","../../../projects/widgets/side-nav/side-nav-item.component.ts","../../../projects/widgets/side-nav/side-nav-title.component.ts","../../../projects/widgets/side-nav/side-nav-section.component.ts","../../../projects/widgets/side-nav/side-nav.component.ts","../../../projects/widgets/side-nav/i-cell-ids-angular-side-nav.ts"],"sourcesContent":["export const IdsSideNavVariant = {\n SURFACE: 'surface',\n LIGHT: 'light',\n} as const;\n\nexport type IdsSideNavVariantType = (typeof IdsSideNavVariant)[keyof typeof IdsSideNavVariant];\n","export const IdsSideNavAppearance = {\n STANDARD: 'standard',\n} as const;\n\nexport type IdsSideNavAppearanceType = (typeof IdsSideNavAppearance)[keyof typeof IdsSideNavAppearance];\n","import { IdsSideNavAppearance, IdsSideNavAppearanceType } from './types/side-nav-appearance.type';\nimport { IdsSideNavVariant, IdsSideNavVariantType } from './types/side-nav-variant.type';\n\nimport { InjectionToken } from '@angular/core';\nimport { IdsSize, IdsSizeType } from '@i-cell/ids-angular/core';\n\nexport interface IdsSideNavDefaultConfig {\n appearance?: IdsSideNavAppearanceType,\n size?: IdsSizeType,\n variant?: IdsSideNavVariantType,\n hasActiveIndicator?: boolean,\n hasLabel?: boolean,\n}\n\nexport const IDS_SIDE_NAV_DEFAULT_CONFIG = new InjectionToken<IdsSideNavDefaultConfig>(\n 'IDS_SIDE_NAV_DEFAULT_CONFIG',\n {\n providedIn: 'root',\n factory: IDS_SIDE_NAV_DEFAULT_CONFIG_FACTORY,\n },\n);\n\nexport function IDS_SIDE_NAV_DEFAULT_CONFIG_FACTORY(): Required<IdsSideNavDefaultConfig> {\n return {\n appearance: IdsSideNavAppearance.STANDARD,\n size: IdsSize.COMPACT,\n variant: IdsSideNavVariant.SURFACE,\n hasActiveIndicator: false,\n hasLabel: true,\n };\n}\n\n","import { IdsSideNavComponent } from '../side-nav.component';\n\nimport { InjectionToken } from '@angular/core';\n\nexport const IDS_SIDE_NAV_PARENT = new InjectionToken<IdsSideNavComponent>(\n 'IDS_SIDE_NAV_PARENT',\n);\n","import { IDS_SIDE_NAV_PARENT } from './tokens/ids-side-nav-parent';\n\nimport { animate, style, transition, trigger } from '@angular/animations';\nimport { NgTemplateOutlet } from '@angular/common';\nimport { Component, computed, contentChild, contentChildren, inject, input, TemplateRef } from '@angular/core';\nimport { Router } from '@angular/router';\nimport { coerceBooleanAttribute } from '@i-cell/ids-angular/core';\nimport { IdsIconComponent } from '@i-cell/ids-angular/icon';\nimport { IdsIconButtonComponent } from '@i-cell/ids-angular/icon-button';\n\n/**\n * Side navigation item\n * - it can be a single list element or an expandable list element, containing another list of elements\n * - it can be used with selectors like `ids-side-nav-item` or `li[idsSideNavItem]`\n * - children can be provided with content projection:\n * - either project `ids-side-nav-item` elements\n * - or list elements as `<li>` elements in an ng-template, marked with `idsSideNavItemChildren` variable\n */\n@Component({\n selector: 'ids-side-nav-item, li[idsSideNavItem]',\n imports: [\n IdsIconComponent,\n IdsIconButtonComponent,\n NgTemplateOutlet,\n ],\n template: `\n <a\n [class.ids-side-nav-item-single]=\"!_expandable()\"\n [class.ids-side-nav-item-expandable-summary]=\"_expandable()\"\n [attr.tabindex]=\"!disabled() ? 0 : null\"\n [attr.disabled]=\"disabled() ? '' : null\"\n [attr.is-active]=\"_active() ? '' : null\"\n [attr.is-active-indicator]=\"_active() && _parent?.hasActiveIndicator() ? '' : null\"\n [attr.aria-disabled]=\"disabled() ? '' : null\"\n [attr.aria-current]=\"_active()\"\n [attr.aria-expanded]=\"!_expandable() ? null : _expanded ? 'true' : 'false'\"\n [attr.aria-label]=\"label()\"\n (keydown)=\"_onKeyDown($event)\"\n (click)=\"_onClick($event)\"\n >\n @if (_iconLeading()) {\n <ng-content select=\"[icon-leading]\" />\n }\n @if (_parent?.hasLabel()) {\n <span class=\"ids-side-nav-item-label\">{{ label() }}</span>\n }\n @if (_iconTrailing()) {\n <ng-content select=\"[icon-trailing]\" />\n }\n @if (_expandable()) {\n <button idsIconButton type=\"button\" [disabled]=\"disabled()\">\n <ids-icon aria-hidden=\"true\" alt=\"\" [fontIcon]=\"_expanded ? 'chevron-up' : 'chevron-down'\" />\n </button>\n }\n </a>\n @if (_expandable() && _expanded) {\n <ul @enterLeave class=\"ids-side-nav-item-expandable-submenu\">\n <ng-content select=\"ids-side-nav-item,[idsSideNavItem]\" />\n <ng-container *ngTemplateOutlet=\"_contentTemplate()\" />\n </ul>\n }\n <ng-content select=\"ng-template\"/>\n `,\n host: {\n class: 'ids-side-nav-item',\n '[class.ids-side-nav-item-expandable]': '_expandable()',\n '[role]': '_expandable() ? \"group\" : \"treeitem\"',\n },\n animations: [\n trigger('enterLeave', [\n transition(':enter', [\n style({ height: 0, opacity: 0 }),\n animate('150ms ease-out', style({ height: '*' })),\n animate('150ms ease-in', style({ opacity: 1 })),\n ]),\n transition(':leave', [\n animate('150ms ease-out', style({ opacity: 0 })),\n animate('150ms ease-in', style({ height: 0 })),\n ]),\n ]),\n ],\n})\nexport class IdsSideNavItemComponent {\n public disabled = input(false, { transform: (value: boolean | string) => coerceBooleanAttribute(value) });\n public label = input.required<string>();\n public target = input<string>('');\n public templateChildren = input<TemplateRef<HTMLElement>>();\n protected _active = computed(() =>\n this._router.isActive(this.target(), { paths: 'exact', queryParams: 'exact', fragment: 'ignored', matrixParams: 'ignored' }),\n );\n\n protected _expandable = computed(() => this._contentChildren().length > 0 || this._contentTemplate());\n protected _expanded = false;\n protected _iconLeading = contentChildren<IdsIconComponent>('[icon-leading]');\n protected _iconTrailing = contentChildren<IdsIconComponent>('[icon-trailing]');\n protected readonly _parent = inject(IDS_SIDE_NAV_PARENT, { optional: true });\n protected readonly _contentTemplate = contentChild('idsSideNavItemChildren', { read: TemplateRef });\n private readonly _contentChildren = contentChildren(IdsSideNavItemComponent);\n private readonly _router = inject(Router);\n\n protected _onClick(event: MouseEvent): void {\n if (this.disabled()) {\n return;\n }\n if ([\n 'button',\n 'ids-icon',\n ].includes((event.target as Element).localName)) {\n this._toggle();\n } else {\n this._navigate();\n }\n }\n\n protected _onKeyDown(event: KeyboardEvent): void {\n if (this.disabled()) {\n return;\n }\n if ([\n 'Enter',\n 'Space',\n ].includes(event.code)) {\n event.preventDefault();\n if ((event.target as Element).localName === 'button') {\n this._toggle();\n } else {\n this._navigate();\n }\n } else if ([\n 'ArrowUp',\n 'ArrowDown',\n 'Escape',\n ].includes(event.code)) {\n event.preventDefault();\n event.stopImmediatePropagation();\n this._toggle();\n }\n }\n\n protected _toggle(): void {\n if (this._expandable()) {\n this._expanded = !this._expanded;\n }\n }\n\n protected _navigate(): void {\n const target = this.target();\n if (target) {\n this._router.navigateByUrl(target);\n }\n }\n}\n","import { IDS_SIDE_NAV_PARENT } from './tokens/ids-side-nav-parent';\n\nimport { Component, contentChildren, inject, input } from '@angular/core';\nimport { IdsIconComponent } from '@i-cell/ids-angular/icon';\n\n/**\n * Side navigation (section) title\n * - title of the navigation section\n * - it can be used with selectors like `ids-side-nav-title` or `li[idsSideNavTitle]`\n * - leading and trailing icons should be projected, label is bound by input\n */\n@Component({\n selector: 'ids-side-nav-title, li[idsSideNavTitle]',\n imports: [],\n template: `\n @if (_iconLeading()) {\n <ng-content select=\"[icon-leading]\" />\n }\n @if (_parent?.hasLabel()) {\n <span class=\"ids-side-nav-title-label\">{{ label() }}</span>\n }\n @if (_iconTrailing()) {\n <ng-content select=\"[icon-trailing]\" />\n }\n `,\n host: {\n class: 'ids-side-nav-title',\n role: 'treeitem',\n },\n})\nexport class IdsSideNavTitleComponent {\n public label = input.required<string>();\n protected _iconLeading = contentChildren<IdsIconComponent>('[icon-leading]');\n protected _iconTrailing = contentChildren<IdsIconComponent>('[icon-trailing]');\n protected readonly _parent = inject(IDS_SIDE_NAV_PARENT, { optional: true });\n}\n","import { Component } from '@angular/core';\n\n/**\n * Side navigation section\n * - section wrapper inside the navigation\n * - it can be used with selectors like `ids-side-nav-section` or `li[idsSideNavSection]`\n * - content should be projected\n */\n@Component({\n selector: 'ids-side-nav-section, ul[idsSideNavSection]',\n imports: [],\n template: '<ng-content />',\n host: {\n class: 'ids-side-nav-section',\n role: 'tree',\n },\n})\nexport class IdsSideNavSectionComponent {}\n","import { IDS_SIDE_NAV_DEFAULT_CONFIG, IDS_SIDE_NAV_DEFAULT_CONFIG_FACTORY, IdsSideNavDefaultConfig } from './side-nav-defaults';\nimport { IDS_SIDE_NAV_PARENT } from './tokens/ids-side-nav-parent';\nimport { IdsSideNavAppearanceType } from './types/side-nav-appearance.type';\nimport { IdsSideNavVariantType } from './types/side-nav-variant.type';\n\nimport { Component, computed, input } from '@angular/core';\nimport { coerceBooleanAttribute, ComponentBaseWithDefaults, IdsSize, IdsSizeType } from '@i-cell/ids-angular/core';\nimport { IDS_ICON_BUTTON_PARENT, IdsIconButtonAppearanceType, IdsIconButtonVariantType, IdsIconButtonParent } from '@i-cell/ids-angular/icon-button';\n\nconst defaultConfig = IDS_SIDE_NAV_DEFAULT_CONFIG_FACTORY();\n\n/**\n * Side navigation\n * - wrapper element for side navigation elements (sections, then title and items as part of section)\n * - content should be projected\n */\n@Component({\n selector: 'nav[idsSideNav]',\n template: '<ng-content/>',\n host: {\n class: 'ids-side-nav',\n },\n providers: [\n {\n provide: IDS_ICON_BUTTON_PARENT,\n useExisting: IdsSideNavComponent,\n },\n {\n provide: IDS_SIDE_NAV_PARENT,\n useExisting: IdsSideNavComponent,\n },\n ],\n})\nexport class IdsSideNavComponent extends ComponentBaseWithDefaults<IdsSideNavDefaultConfig> implements IdsIconButtonParent {\n protected override get _hostName(): string {\n return 'side-nav';\n }\n\n protected readonly _defaultConfig = this._getDefaultConfig(defaultConfig, IDS_SIDE_NAV_DEFAULT_CONFIG);\n\n public appearance = input<IdsSideNavAppearanceType>(this._defaultConfig.appearance);\n public size = input<IdsSizeType>(this._defaultConfig.size);\n public variant = input<IdsSideNavVariantType>(this._defaultConfig.variant);\n public hasLabel = input<boolean>(coerceBooleanAttribute(this._defaultConfig.hasLabel));\n public hasActiveIndicator = input<boolean>(coerceBooleanAttribute(this._defaultConfig.hasActiveIndicator));\n\n public embeddedIconButtonAppearance = computed<IdsIconButtonAppearanceType>(() => this.appearance());\n public embeddedIconButtonVariant = computed<IdsIconButtonVariantType>(() => this.variant());\n public embeddedIconButtonSize = computed<IdsSizeType>(() => {\n switch (this.size()) {\n // NOTE: SPACIOUS icon button size sticks out of side-nav item, size need to be adjusted\n case IdsSize.SPACIOUS:\n return IdsSize.COMFORTABLE;\n default:\n return this.size();\n }\n });\n\n protected _hostClasses = computed(() => this._getHostClasses([\n this.appearance(),\n this.variant(),\n this.size(),\n ]));\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;AAAO,MAAM,iBAAiB,GAAG;AAC/B,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,KAAK,EAAE,OAAO;;;ACFT,MAAM,oBAAoB,GAAG;AAClC,IAAA,QAAQ,EAAE,UAAU;;;MCaT,2BAA2B,GAAG,IAAI,cAAc,CAC3D,6BAA6B,EAC7B;AACE,IAAA,UAAU,EAAE,MAAM;AAClB,IAAA,OAAO,EAAE,mCAAmC;AAC7C,CAAA;SAGa,mCAAmC,GAAA;IACjD,OAAO;QACL,UAAU,EAAE,oBAAoB,CAAC,QAAQ;QACzC,IAAI,EAAE,OAAO,CAAC,OAAO;QACrB,OAAO,EAAE,iBAAiB,CAAC,OAAO;AAClC,QAAA,kBAAkB,EAAE,KAAK;AACzB,QAAA,QAAQ,EAAE,IAAI;KACf;AACH;;AC1BO,MAAM,mBAAmB,GAAG,IAAI,cAAc,CACnD,qBAAqB,CACtB;;ACID;;;;;;;AAOG;MAiEU,uBAAuB,CAAA;AA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AA;AACD,oBAAA,SAAS,EAAE;AACT,wBAAA;AACE,4BAAA,OAAO,EAAE,sBAAsB;AAC/B,4BAAA,WAAW,EAAA,mBAAqB;AACjC,yBAAA;AACD,wBAAA;AACE,4BAAA,OAAO,EAAE,mBAAmB;AAC5B,4BAAA,WAAW,EAAA,mBAAqB;AACjC,yBAAA;AACF,qBAAA;AACF,iBAAA;;;AChCD;;AAEG;;;;"}
@@ -27,7 +27,8 @@ type IdsIconButtonVariantType = (typeof IdsIconButtonVariant)[keyof typeof IdsIc
27
27
  declare abstract class IdsIconButtonParent {
28
28
  readonly embeddedIconButtonVariant: Signal<IdsIconButtonVariantType>;
29
29
  readonly embeddedIconButtonAppearance: Signal<IdsIconButtonAppearanceType>;
30
- readonly disabled: Signal<boolean>;
30
+ readonly embeddedIconButtonSize?: Signal<IdsSizeType>;
31
+ readonly disabled?: Signal<boolean>;
31
32
  }
32
33
  declare const IDS_ICON_BUTTON_PARENT: InjectionToken<IdsIconButtonParent>;
33
34
 
@@ -51,6 +52,7 @@ declare class IdsIconButtonComponent extends ComponentBaseWithDefaults<IdsIconBu
51
52
  disabled: _angular_core.InputSignalWithTransform<boolean, unknown>;
52
53
  protected _icons: _angular_core.Signal<readonly IdsIconComponent[]>;
53
54
  private _parentOrSelfAppearance;
55
+ private _parentOrSelfSize;
54
56
  private _parentOrSelfVariant;
55
57
  private _parentOrSelfDisabled;
56
58
  protected _hostClasses: _angular_core.Signal<string>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@i-cell/ids-angular",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "private": false,
5
5
  "description": "i-Cell Design System UI Kit components for Angular",
6
6
  "publishConfig": {
@@ -52,34 +52,30 @@
52
52
  "types": "./accordion/index.d.ts",
53
53
  "default": "./fesm2022/i-cell-ids-angular-accordion.mjs"
54
54
  },
55
- "./avatar": {
56
- "types": "./avatar/index.d.ts",
57
- "default": "./fesm2022/i-cell-ids-angular-avatar.mjs"
55
+ "./badge": {
56
+ "types": "./badge/index.d.ts",
57
+ "default": "./fesm2022/i-cell-ids-angular-badge.mjs"
58
58
  },
59
59
  "./breadcrumb": {
60
60
  "types": "./breadcrumb/index.d.ts",
61
61
  "default": "./fesm2022/i-cell-ids-angular-breadcrumb.mjs"
62
62
  },
63
- "./badge": {
64
- "types": "./badge/index.d.ts",
65
- "default": "./fesm2022/i-cell-ids-angular-badge.mjs"
66
- },
67
63
  "./button": {
68
64
  "types": "./button/index.d.ts",
69
65
  "default": "./fesm2022/i-cell-ids-angular-button.mjs"
70
66
  },
71
- "./card": {
72
- "types": "./card/index.d.ts",
73
- "default": "./fesm2022/i-cell-ids-angular-card.mjs"
74
- },
75
- "./checkbox": {
76
- "types": "./checkbox/index.d.ts",
77
- "default": "./fesm2022/i-cell-ids-angular-checkbox.mjs"
67
+ "./avatar": {
68
+ "types": "./avatar/index.d.ts",
69
+ "default": "./fesm2022/i-cell-ids-angular-avatar.mjs"
78
70
  },
79
71
  "./chip": {
80
72
  "types": "./chip/index.d.ts",
81
73
  "default": "./fesm2022/i-cell-ids-angular-chip.mjs"
82
74
  },
75
+ "./checkbox": {
76
+ "types": "./checkbox/index.d.ts",
77
+ "default": "./fesm2022/i-cell-ids-angular-checkbox.mjs"
78
+ },
83
79
  "./core": {
84
80
  "types": "./core/index.d.ts",
85
81
  "default": "./fesm2022/i-cell-ids-angular-core.mjs"
@@ -88,14 +84,14 @@
88
84
  "types": "./datepicker/index.d.ts",
89
85
  "default": "./fesm2022/i-cell-ids-angular-datepicker.mjs"
90
86
  },
91
- "./dialog": {
92
- "types": "./dialog/index.d.ts",
93
- "default": "./fesm2022/i-cell-ids-angular-dialog.mjs"
94
- },
95
87
  "./divider": {
96
88
  "types": "./divider/index.d.ts",
97
89
  "default": "./fesm2022/i-cell-ids-angular-divider.mjs"
98
90
  },
91
+ "./dialog": {
92
+ "types": "./dialog/index.d.ts",
93
+ "default": "./fesm2022/i-cell-ids-angular-dialog.mjs"
94
+ },
99
95
  "./forms": {
100
96
  "types": "./forms/index.d.ts",
101
97
  "default": "./fesm2022/i-cell-ids-angular-forms.mjs"
@@ -112,26 +108,22 @@
112
108
  "types": "./menu/index.d.ts",
113
109
  "default": "./fesm2022/i-cell-ids-angular-menu.mjs"
114
110
  },
115
- "./notification": {
116
- "types": "./notification/index.d.ts",
117
- "default": "./fesm2022/i-cell-ids-angular-notification.mjs"
111
+ "./card": {
112
+ "types": "./card/index.d.ts",
113
+ "default": "./fesm2022/i-cell-ids-angular-card.mjs"
118
114
  },
119
115
  "./overlay-panel": {
120
116
  "types": "./overlay-panel/index.d.ts",
121
117
  "default": "./fesm2022/i-cell-ids-angular-overlay-panel.mjs"
122
118
  },
119
+ "./notification": {
120
+ "types": "./notification/index.d.ts",
121
+ "default": "./fesm2022/i-cell-ids-angular-notification.mjs"
122
+ },
123
123
  "./paginator": {
124
124
  "types": "./paginator/index.d.ts",
125
125
  "default": "./fesm2022/i-cell-ids-angular-paginator.mjs"
126
126
  },
127
- "./radio": {
128
- "types": "./radio/index.d.ts",
129
- "default": "./fesm2022/i-cell-ids-angular-radio.mjs"
130
- },
131
- "./segmented-control": {
132
- "types": "./segmented-control/index.d.ts",
133
- "default": "./fesm2022/i-cell-ids-angular-segmented-control.mjs"
134
- },
135
127
  "./segmented-control-toggle": {
136
128
  "types": "./segmented-control-toggle/index.d.ts",
137
129
  "default": "./fesm2022/i-cell-ids-angular-segmented-control-toggle.mjs"
@@ -140,10 +132,18 @@
140
132
  "types": "./select/index.d.ts",
141
133
  "default": "./fesm2022/i-cell-ids-angular-select.mjs"
142
134
  },
135
+ "./segmented-control": {
136
+ "types": "./segmented-control/index.d.ts",
137
+ "default": "./fesm2022/i-cell-ids-angular-segmented-control.mjs"
138
+ },
143
139
  "./side-sheet": {
144
140
  "types": "./side-sheet/index.d.ts",
145
141
  "default": "./fesm2022/i-cell-ids-angular-side-sheet.mjs"
146
142
  },
143
+ "./side-nav": {
144
+ "types": "./side-nav/index.d.ts",
145
+ "default": "./fesm2022/i-cell-ids-angular-side-nav.mjs"
146
+ },
147
147
  "./snackbar": {
148
148
  "types": "./snackbar/index.d.ts",
149
149
  "default": "./fesm2022/i-cell-ids-angular-snackbar.mjs"
@@ -156,13 +156,17 @@
156
156
  "types": "./switch/index.d.ts",
157
157
  "default": "./fesm2022/i-cell-ids-angular-switch.mjs"
158
158
  },
159
+ "./tab": {
160
+ "types": "./tab/index.d.ts",
161
+ "default": "./fesm2022/i-cell-ids-angular-tab.mjs"
162
+ },
159
163
  "./table": {
160
164
  "types": "./table/index.d.ts",
161
165
  "default": "./fesm2022/i-cell-ids-angular-table.mjs"
162
166
  },
163
- "./tab": {
164
- "types": "./tab/index.d.ts",
165
- "default": "./fesm2022/i-cell-ids-angular-tab.mjs"
167
+ "./radio": {
168
+ "types": "./radio/index.d.ts",
169
+ "default": "./fesm2022/i-cell-ids-angular-radio.mjs"
166
170
  },
167
171
  "./tag": {
168
172
  "types": "./tag/index.d.ts",
@@ -0,0 +1,107 @@
1
+ import * as _angular_core from '@angular/core';
2
+ import { InjectionToken, TemplateRef } from '@angular/core';
3
+ import { IdsSizeType, ComponentBaseWithDefaults } from '@i-cell/ids-angular/core';
4
+ import * as _i_cell_ids_angular_side_nav from '@i-cell/ids-angular/side-nav';
5
+ import { IdsIconComponent } from '@i-cell/ids-angular/icon';
6
+ import { IdsIconButtonParent, IdsIconButtonAppearanceType, IdsIconButtonVariantType } from '@i-cell/ids-angular/icon-button';
7
+
8
+ declare const IdsSideNavVariant: {
9
+ readonly SURFACE: "surface";
10
+ readonly LIGHT: "light";
11
+ };
12
+ type IdsSideNavVariantType = (typeof IdsSideNavVariant)[keyof typeof IdsSideNavVariant];
13
+
14
+ declare const IdsSideNavAppearance: {
15
+ readonly STANDARD: "standard";
16
+ };
17
+ type IdsSideNavAppearanceType = (typeof IdsSideNavAppearance)[keyof typeof IdsSideNavAppearance];
18
+
19
+ interface IdsSideNavDefaultConfig {
20
+ appearance?: IdsSideNavAppearanceType;
21
+ size?: IdsSizeType;
22
+ variant?: IdsSideNavVariantType;
23
+ hasActiveIndicator?: boolean;
24
+ hasLabel?: boolean;
25
+ }
26
+ declare const IDS_SIDE_NAV_DEFAULT_CONFIG: InjectionToken<IdsSideNavDefaultConfig>;
27
+ declare function IDS_SIDE_NAV_DEFAULT_CONFIG_FACTORY(): Required<IdsSideNavDefaultConfig>;
28
+
29
+ /**
30
+ * Side navigation item
31
+ * - it can be a single list element or an expandable list element, containing another list of elements
32
+ * - it can be used with selectors like `ids-side-nav-item` or `li[idsSideNavItem]`
33
+ * - children can be provided with content projection:
34
+ * - either project `ids-side-nav-item` elements
35
+ * - or list elements as `<li>` elements in an ng-template, marked with `idsSideNavItemChildren` variable
36
+ */
37
+ declare class IdsSideNavItemComponent {
38
+ disabled: _angular_core.InputSignalWithTransform<boolean, string | boolean>;
39
+ label: _angular_core.InputSignal<string>;
40
+ target: _angular_core.InputSignal<string>;
41
+ templateChildren: _angular_core.InputSignal<TemplateRef<HTMLElement> | undefined>;
42
+ protected _active: _angular_core.Signal<boolean>;
43
+ protected _expandable: _angular_core.Signal<true | TemplateRef<any> | undefined>;
44
+ protected _expanded: boolean;
45
+ protected _iconLeading: _angular_core.Signal<readonly IdsIconComponent[]>;
46
+ protected _iconTrailing: _angular_core.Signal<readonly IdsIconComponent[]>;
47
+ protected readonly _parent: _i_cell_ids_angular_side_nav.IdsSideNavComponent | null;
48
+ protected readonly _contentTemplate: _angular_core.Signal<TemplateRef<any> | undefined>;
49
+ private readonly _contentChildren;
50
+ private readonly _router;
51
+ protected _onClick(event: MouseEvent): void;
52
+ protected _onKeyDown(event: KeyboardEvent): void;
53
+ protected _toggle(): void;
54
+ protected _navigate(): void;
55
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<IdsSideNavItemComponent, never>;
56
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<IdsSideNavItemComponent, "ids-side-nav-item, li[idsSideNavItem]", never, { "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": true; "isSignal": true; }; "target": { "alias": "target"; "required": false; "isSignal": true; }; "templateChildren": { "alias": "templateChildren"; "required": false; "isSignal": true; }; }, {}, ["_iconLeading", "_iconTrailing", "_contentTemplate", "_contentChildren"], ["[icon-leading]", "[icon-trailing]", "ids-side-nav-item,[idsSideNavItem]", "ng-template"], true, never>;
57
+ }
58
+
59
+ /**
60
+ * Side navigation (section) title
61
+ * - title of the navigation section
62
+ * - it can be used with selectors like `ids-side-nav-title` or `li[idsSideNavTitle]`
63
+ * - leading and trailing icons should be projected, label is bound by input
64
+ */
65
+ declare class IdsSideNavTitleComponent {
66
+ label: _angular_core.InputSignal<string>;
67
+ protected _iconLeading: _angular_core.Signal<readonly IdsIconComponent[]>;
68
+ protected _iconTrailing: _angular_core.Signal<readonly IdsIconComponent[]>;
69
+ protected readonly _parent: _i_cell_ids_angular_side_nav.IdsSideNavComponent | null;
70
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<IdsSideNavTitleComponent, never>;
71
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<IdsSideNavTitleComponent, "ids-side-nav-title, li[idsSideNavTitle]", never, { "label": { "alias": "label"; "required": true; "isSignal": true; }; }, {}, ["_iconLeading", "_iconTrailing"], ["[icon-leading]", "[icon-trailing]"], true, never>;
72
+ }
73
+
74
+ /**
75
+ * Side navigation section
76
+ * - section wrapper inside the navigation
77
+ * - it can be used with selectors like `ids-side-nav-section` or `li[idsSideNavSection]`
78
+ * - content should be projected
79
+ */
80
+ declare class IdsSideNavSectionComponent {
81
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<IdsSideNavSectionComponent, never>;
82
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<IdsSideNavSectionComponent, "ids-side-nav-section, ul[idsSideNavSection]", never, {}, {}, never, ["*"], true, never>;
83
+ }
84
+
85
+ /**
86
+ * Side navigation
87
+ * - wrapper element for side navigation elements (sections, then title and items as part of section)
88
+ * - content should be projected
89
+ */
90
+ declare class IdsSideNavComponent extends ComponentBaseWithDefaults<IdsSideNavDefaultConfig> implements IdsIconButtonParent {
91
+ protected get _hostName(): string;
92
+ protected readonly _defaultConfig: Required<IdsSideNavDefaultConfig>;
93
+ appearance: _angular_core.InputSignal<"standard">;
94
+ size: _angular_core.InputSignal<IdsSizeType>;
95
+ variant: _angular_core.InputSignal<IdsSideNavVariantType>;
96
+ hasLabel: _angular_core.InputSignal<boolean>;
97
+ hasActiveIndicator: _angular_core.InputSignal<boolean>;
98
+ embeddedIconButtonAppearance: _angular_core.Signal<IdsIconButtonAppearanceType>;
99
+ embeddedIconButtonVariant: _angular_core.Signal<IdsIconButtonVariantType>;
100
+ embeddedIconButtonSize: _angular_core.Signal<IdsSizeType>;
101
+ protected _hostClasses: _angular_core.Signal<string>;
102
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<IdsSideNavComponent, never>;
103
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<IdsSideNavComponent, "nav[idsSideNav]", never, { "appearance": { "alias": "appearance"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "hasLabel": { "alias": "hasLabel"; "required": false; "isSignal": true; }; "hasActiveIndicator": { "alias": "hasActiveIndicator"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
104
+ }
105
+
106
+ export { IDS_SIDE_NAV_DEFAULT_CONFIG, IDS_SIDE_NAV_DEFAULT_CONFIG_FACTORY, IdsSideNavAppearance, IdsSideNavComponent, IdsSideNavItemComponent, IdsSideNavSectionComponent, IdsSideNavTitleComponent, IdsSideNavVariant };
107
+ export type { IdsSideNavAppearanceType, IdsSideNavDefaultConfig, IdsSideNavVariantType };