@scania/tegel-angular-17 1.12.1 → 1.13.0

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,7 +1,12 @@
1
1
  import * as i0 from "@angular/core";
2
2
  import * as i1 from "./stencil-generated/components";
3
+ import * as i2 from "./stencil-generated/boolean-value-accessor";
4
+ import * as i3 from "./stencil-generated/number-value-accessor";
5
+ import * as i4 from "./stencil-generated/text-value-accessor";
6
+ import * as i5 from "./directives/tds-radio-value-accessor";
7
+ import * as i6 from "./directives/tds-dropdown-value-accessor";
3
8
  export declare class TegelModule {
4
9
  static ɵfac: i0.ɵɵFactoryDeclaration<TegelModule, never>;
5
- static ɵmod: i0.ɵɵNgModuleDeclaration<TegelModule, [typeof i1.TdsAccordion, typeof i1.TdsAccordionItem, typeof i1.TdsBadge, typeof i1.TdsBanner, typeof i1.TdsBlock, typeof i1.TdsBodyCell, typeof i1.TdsBreadcrumb, typeof i1.TdsBreadcrumbs, typeof i1.TdsButton, typeof i1.TdsCard, typeof i1.TdsCheckbox, typeof i1.TdsChip, typeof i1.TdsCoreHeaderItem, typeof i1.TdsDatetime, typeof i1.TdsDivider, typeof i1.TdsDropdown, typeof i1.TdsDropdownOption, typeof i1.TdsFolderTab, typeof i1.TdsFolderTabs, typeof i1.TdsFooter, typeof i1.TdsFooterGroup, typeof i1.TdsFooterItem, typeof i1.TdsHeader, typeof i1.TdsHeaderBrandSymbol, typeof i1.TdsHeaderCell, typeof i1.TdsHeaderDropdown, typeof i1.TdsHeaderDropdownList, typeof i1.TdsHeaderDropdownListItem, typeof i1.TdsHeaderDropdownListUser, typeof i1.TdsHeaderHamburger, typeof i1.TdsHeaderItem, typeof i1.TdsHeaderLauncher, typeof i1.TdsHeaderLauncherButton, typeof i1.TdsHeaderLauncherGrid, typeof i1.TdsHeaderLauncherGridItem, typeof i1.TdsHeaderLauncherGridTitle, typeof i1.TdsHeaderLauncherList, typeof i1.TdsHeaderLauncherListItem, typeof i1.TdsHeaderLauncherListTitle, typeof i1.TdsHeaderTitle, typeof i1.TdsIcon, typeof i1.TdsInlineTab, typeof i1.TdsInlineTabs, typeof i1.TdsLink, typeof i1.TdsMessage, typeof i1.TdsModal, typeof i1.TdsNavigationTab, typeof i1.TdsNavigationTabs, typeof i1.TdsPopoverCanvas, typeof i1.TdsPopoverCore, typeof i1.TdsPopoverMenu, typeof i1.TdsPopoverMenuItem, typeof i1.TdsRadioButton, typeof i1.TdsSideMenu, typeof i1.TdsSideMenuCloseButton, typeof i1.TdsSideMenuCollapseButton, typeof i1.TdsSideMenuDropdown, typeof i1.TdsSideMenuDropdownList, typeof i1.TdsSideMenuDropdownListItem, typeof i1.TdsSideMenuItem, typeof i1.TdsSideMenuOverlay, typeof i1.TdsSideMenuUser, typeof i1.TdsSideMenuUserImage, typeof i1.TdsSideMenuUserLabel, typeof i1.TdsSlider, typeof i1.TdsSpinner, typeof i1.TdsStep, typeof i1.TdsStepper, typeof i1.TdsTable, typeof i1.TdsTableBody, typeof i1.TdsTableBodyRow, typeof i1.TdsTableBodyRowExpandable, typeof i1.TdsTableFooter, typeof i1.TdsTableHeader, typeof i1.TdsTableToolbar, typeof i1.TdsTextField, typeof i1.TdsTextarea, typeof i1.TdsToast, typeof i1.TdsToggle, typeof i1.TdsTooltip], never, [typeof i1.TdsAccordion, typeof i1.TdsAccordionItem, typeof i1.TdsBadge, typeof i1.TdsBanner, typeof i1.TdsBlock, typeof i1.TdsBodyCell, typeof i1.TdsBreadcrumb, typeof i1.TdsBreadcrumbs, typeof i1.TdsButton, typeof i1.TdsCard, typeof i1.TdsCheckbox, typeof i1.TdsChip, typeof i1.TdsCoreHeaderItem, typeof i1.TdsDatetime, typeof i1.TdsDivider, typeof i1.TdsDropdown, typeof i1.TdsDropdownOption, typeof i1.TdsFolderTab, typeof i1.TdsFolderTabs, typeof i1.TdsFooter, typeof i1.TdsFooterGroup, typeof i1.TdsFooterItem, typeof i1.TdsHeader, typeof i1.TdsHeaderBrandSymbol, typeof i1.TdsHeaderCell, typeof i1.TdsHeaderDropdown, typeof i1.TdsHeaderDropdownList, typeof i1.TdsHeaderDropdownListItem, typeof i1.TdsHeaderDropdownListUser, typeof i1.TdsHeaderHamburger, typeof i1.TdsHeaderItem, typeof i1.TdsHeaderLauncher, typeof i1.TdsHeaderLauncherButton, typeof i1.TdsHeaderLauncherGrid, typeof i1.TdsHeaderLauncherGridItem, typeof i1.TdsHeaderLauncherGridTitle, typeof i1.TdsHeaderLauncherList, typeof i1.TdsHeaderLauncherListItem, typeof i1.TdsHeaderLauncherListTitle, typeof i1.TdsHeaderTitle, typeof i1.TdsIcon, typeof i1.TdsInlineTab, typeof i1.TdsInlineTabs, typeof i1.TdsLink, typeof i1.TdsMessage, typeof i1.TdsModal, typeof i1.TdsNavigationTab, typeof i1.TdsNavigationTabs, typeof i1.TdsPopoverCanvas, typeof i1.TdsPopoverCore, typeof i1.TdsPopoverMenu, typeof i1.TdsPopoverMenuItem, typeof i1.TdsRadioButton, typeof i1.TdsSideMenu, typeof i1.TdsSideMenuCloseButton, typeof i1.TdsSideMenuCollapseButton, typeof i1.TdsSideMenuDropdown, typeof i1.TdsSideMenuDropdownList, typeof i1.TdsSideMenuDropdownListItem, typeof i1.TdsSideMenuItem, typeof i1.TdsSideMenuOverlay, typeof i1.TdsSideMenuUser, typeof i1.TdsSideMenuUserImage, typeof i1.TdsSideMenuUserLabel, typeof i1.TdsSlider, typeof i1.TdsSpinner, typeof i1.TdsStep, typeof i1.TdsStepper, typeof i1.TdsTable, typeof i1.TdsTableBody, typeof i1.TdsTableBodyRow, typeof i1.TdsTableBodyRowExpandable, typeof i1.TdsTableFooter, typeof i1.TdsTableHeader, typeof i1.TdsTableToolbar, typeof i1.TdsTextField, typeof i1.TdsTextarea, typeof i1.TdsToast, typeof i1.TdsToggle, typeof i1.TdsTooltip]>;
10
+ static ɵmod: i0.ɵɵNgModuleDeclaration<TegelModule, [typeof i1.TdsAccordion, typeof i1.TdsAccordionItem, typeof i1.TdsBadge, typeof i1.TdsBanner, typeof i1.TdsBlock, typeof i1.TdsBodyCell, typeof i1.TdsBreadcrumb, typeof i1.TdsBreadcrumbs, typeof i1.TdsButton, typeof i1.TdsCard, typeof i1.TdsCheckbox, typeof i1.TdsChip, typeof i1.TdsCoreHeaderItem, typeof i1.TdsDatetime, typeof i1.TdsDivider, typeof i1.TdsDropdown, typeof i1.TdsDropdownOption, typeof i1.TdsFolderTab, typeof i1.TdsFolderTabs, typeof i1.TdsFooter, typeof i1.TdsFooterGroup, typeof i1.TdsFooterItem, typeof i1.TdsHeader, typeof i1.TdsHeaderBrandSymbol, typeof i1.TdsHeaderCell, typeof i1.TdsHeaderDropdown, typeof i1.TdsHeaderDropdownList, typeof i1.TdsHeaderDropdownListItem, typeof i1.TdsHeaderDropdownListUser, typeof i1.TdsHeaderHamburger, typeof i1.TdsHeaderItem, typeof i1.TdsHeaderLauncher, typeof i1.TdsHeaderLauncherButton, typeof i1.TdsHeaderLauncherGrid, typeof i1.TdsHeaderLauncherGridItem, typeof i1.TdsHeaderLauncherGridTitle, typeof i1.TdsHeaderLauncherList, typeof i1.TdsHeaderLauncherListItem, typeof i1.TdsHeaderLauncherListTitle, typeof i1.TdsHeaderTitle, typeof i1.TdsIcon, typeof i1.TdsInlineTab, typeof i1.TdsInlineTabs, typeof i1.TdsLink, typeof i1.TdsMessage, typeof i1.TdsModal, typeof i1.TdsNavigationTab, typeof i1.TdsNavigationTabs, typeof i1.TdsPopoverCanvas, typeof i1.TdsPopoverCore, typeof i1.TdsPopoverMenu, typeof i1.TdsPopoverMenuItem, typeof i1.TdsRadioButton, typeof i1.TdsSideMenu, typeof i1.TdsSideMenuCloseButton, typeof i1.TdsSideMenuCollapseButton, typeof i1.TdsSideMenuDropdown, typeof i1.TdsSideMenuDropdownList, typeof i1.TdsSideMenuDropdownListItem, typeof i1.TdsSideMenuItem, typeof i1.TdsSideMenuOverlay, typeof i1.TdsSideMenuUser, typeof i1.TdsSideMenuUserImage, typeof i1.TdsSideMenuUserLabel, typeof i1.TdsSlider, typeof i1.TdsSpinner, typeof i1.TdsStep, typeof i1.TdsStepper, typeof i1.TdsTable, typeof i1.TdsTableBody, typeof i1.TdsTableBodyRow, typeof i1.TdsTableBodyRowExpandable, typeof i1.TdsTableFooter, typeof i1.TdsTableHeader, typeof i1.TdsTableToolbar, typeof i1.TdsTextField, typeof i1.TdsTextarea, typeof i1.TdsToast, typeof i1.TdsToggle, typeof i1.TdsTooltip, typeof i2.BooleanValueAccessor, typeof i3.NumericValueAccessor, typeof i4.TextValueAccessor, typeof i5.TdsRadioValueAccessor, typeof i6.TdsDropdownValueAccessor], never, [typeof i1.TdsAccordion, typeof i1.TdsAccordionItem, typeof i1.TdsBadge, typeof i1.TdsBanner, typeof i1.TdsBlock, typeof i1.TdsBodyCell, typeof i1.TdsBreadcrumb, typeof i1.TdsBreadcrumbs, typeof i1.TdsButton, typeof i1.TdsCard, typeof i1.TdsCheckbox, typeof i1.TdsChip, typeof i1.TdsCoreHeaderItem, typeof i1.TdsDatetime, typeof i1.TdsDivider, typeof i1.TdsDropdown, typeof i1.TdsDropdownOption, typeof i1.TdsFolderTab, typeof i1.TdsFolderTabs, typeof i1.TdsFooter, typeof i1.TdsFooterGroup, typeof i1.TdsFooterItem, typeof i1.TdsHeader, typeof i1.TdsHeaderBrandSymbol, typeof i1.TdsHeaderCell, typeof i1.TdsHeaderDropdown, typeof i1.TdsHeaderDropdownList, typeof i1.TdsHeaderDropdownListItem, typeof i1.TdsHeaderDropdownListUser, typeof i1.TdsHeaderHamburger, typeof i1.TdsHeaderItem, typeof i1.TdsHeaderLauncher, typeof i1.TdsHeaderLauncherButton, typeof i1.TdsHeaderLauncherGrid, typeof i1.TdsHeaderLauncherGridItem, typeof i1.TdsHeaderLauncherGridTitle, typeof i1.TdsHeaderLauncherList, typeof i1.TdsHeaderLauncherListItem, typeof i1.TdsHeaderLauncherListTitle, typeof i1.TdsHeaderTitle, typeof i1.TdsIcon, typeof i1.TdsInlineTab, typeof i1.TdsInlineTabs, typeof i1.TdsLink, typeof i1.TdsMessage, typeof i1.TdsModal, typeof i1.TdsNavigationTab, typeof i1.TdsNavigationTabs, typeof i1.TdsPopoverCanvas, typeof i1.TdsPopoverCore, typeof i1.TdsPopoverMenu, typeof i1.TdsPopoverMenuItem, typeof i1.TdsRadioButton, typeof i1.TdsSideMenu, typeof i1.TdsSideMenuCloseButton, typeof i1.TdsSideMenuCollapseButton, typeof i1.TdsSideMenuDropdown, typeof i1.TdsSideMenuDropdownList, typeof i1.TdsSideMenuDropdownListItem, typeof i1.TdsSideMenuItem, typeof i1.TdsSideMenuOverlay, typeof i1.TdsSideMenuUser, typeof i1.TdsSideMenuUserImage, typeof i1.TdsSideMenuUserLabel, typeof i1.TdsSlider, typeof i1.TdsSpinner, typeof i1.TdsStep, typeof i1.TdsStepper, typeof i1.TdsTable, typeof i1.TdsTableBody, typeof i1.TdsTableBodyRow, typeof i1.TdsTableBodyRowExpandable, typeof i1.TdsTableFooter, typeof i1.TdsTableHeader, typeof i1.TdsTableToolbar, typeof i1.TdsTextField, typeof i1.TdsTextarea, typeof i1.TdsToast, typeof i1.TdsToggle, typeof i1.TdsTooltip, typeof i2.BooleanValueAccessor, typeof i3.NumericValueAccessor, typeof i4.TextValueAccessor, typeof i5.TdsRadioValueAccessor, typeof i6.TdsDropdownValueAccessor]>;
6
11
  static ɵinj: i0.ɵɵInjectorDeclaration<TegelModule>;
7
12
  }
@@ -0,0 +1,11 @@
1
+ import { ValueAccessor } from '../stencil-generated/value-accessor';
2
+ import * as i0 from "@angular/core";
3
+ /**
4
+ * A custom value accessor for the tds-dropdown. It extends the default ValueAccessor that is auto-generated by Stencil
5
+ * The tds-dropdown requires slightly different event handling since it doesn't act like any of the native inputs.
6
+ * The main difference between this value accessor and the other value accessors that are auto-generated by Stencil, is that this one handles `$event.detail.value` instead of `$event.target.value`.
7
+ */
8
+ export declare class TdsDropdownValueAccessor extends ValueAccessor {
9
+ static ɵfac: i0.ɵɵFactoryDeclaration<TdsDropdownValueAccessor, never>;
10
+ static ɵdir: i0.ɵɵDirectiveDeclaration<TdsDropdownValueAccessor, "tds-dropdown", never, {}, {}, never, never, false, never>;
11
+ }
@@ -0,0 +1,13 @@
1
+ import { ValueAccessor } from '../stencil-generated/value-accessor';
2
+ import * as i0 from "@angular/core";
3
+ /**
4
+ * A custom value accessor for the tds-radio-button and tds-chip of type radio. It extends the default ValueAccessor that is auto-generated by Stencil
5
+ * Stencil offers an autogenerated radio value accessor but does not currently work as expected.
6
+ * An issue was submitted to their repository: https://github.com/ionic-team/stencil-ds-output-targets/issues/434
7
+ * If the issue is ever fixed this value accessor can be replaced with the one auto-generated by Stencil.
8
+ */
9
+ export declare class TdsRadioValueAccessor extends ValueAccessor {
10
+ writeValue(value: any): void;
11
+ static ɵfac: i0.ɵɵFactoryDeclaration<TdsRadioValueAccessor, never>;
12
+ static ɵdir: i0.ɵɵDirectiveDeclaration<TdsRadioValueAccessor, "tds-radio-button, tds-chip[type=\"radio\"]", never, {}, {}, never, never, false, never>;
13
+ }
@@ -0,0 +1,9 @@
1
+ import { ElementRef } from '@angular/core';
2
+ import { ValueAccessor } from './value-accessor';
3
+ import * as i0 from "@angular/core";
4
+ export declare class BooleanValueAccessor extends ValueAccessor {
5
+ constructor(el: ElementRef);
6
+ writeValue(value: any): void;
7
+ static ɵfac: i0.ɵɵFactoryDeclaration<BooleanValueAccessor, never>;
8
+ static ɵdir: i0.ɵɵDirectiveDeclaration<BooleanValueAccessor, "tds-checkbox, tds-chip[type=\"checkbox\"], tds-toggle", never, {}, {}, never, never, false, never>;
9
+ }
@@ -0,0 +1,9 @@
1
+ import { ElementRef } from '@angular/core';
2
+ import { ValueAccessor } from './value-accessor';
3
+ import * as i0 from "@angular/core";
4
+ export declare class NumericValueAccessor extends ValueAccessor {
5
+ constructor(el: ElementRef);
6
+ registerOnChange(fn: (_: number | null) => void): void;
7
+ static ɵfac: i0.ɵɵFactoryDeclaration<NumericValueAccessor, never>;
8
+ static ɵdir: i0.ɵɵDirectiveDeclaration<NumericValueAccessor, "tds-slider", never, {}, {}, never, never, false, never>;
9
+ }
@@ -0,0 +1,8 @@
1
+ import { ElementRef } from '@angular/core';
2
+ import { ValueAccessor } from './value-accessor';
3
+ import * as i0 from "@angular/core";
4
+ export declare class TextValueAccessor extends ValueAccessor {
5
+ constructor(el: ElementRef);
6
+ static ɵfac: i0.ɵɵFactoryDeclaration<TextValueAccessor, never>;
7
+ static ɵdir: i0.ɵɵDirectiveDeclaration<TextValueAccessor, "tds-text-field, tds-textarea, tds-datetime", never, {}, {}, never, never, false, never>;
8
+ }
@@ -0,0 +1,18 @@
1
+ import { ElementRef } from '@angular/core';
2
+ import { ControlValueAccessor } from '@angular/forms';
3
+ import * as i0 from "@angular/core";
4
+ export declare class ValueAccessor implements ControlValueAccessor {
5
+ protected el: ElementRef;
6
+ private onChange;
7
+ private onTouched;
8
+ protected lastValue: any;
9
+ constructor(el: ElementRef);
10
+ writeValue(value: any): void;
11
+ handleChangeEvent(value: any): void;
12
+ _handleBlurEvent(): void;
13
+ registerOnChange(fn: (value: any) => void): void;
14
+ registerOnTouched(fn: () => void): void;
15
+ setDisabledState(isDisabled: boolean): void;
16
+ static ɵfac: i0.ɵɵFactoryDeclaration<ValueAccessor, never>;
17
+ static ɵdir: i0.ɵɵDirectiveDeclaration<ValueAccessor, never, never, {}, {}, never, never, false, never>;
18
+ }
package/package.json CHANGED
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "@scania/tegel-angular-17",
3
- "version": "1.12.1",
3
+ "version": "1.13.0",
4
4
  "description": "Angular wrappers for Tegel package using Angular 17 and above",
5
5
  "peerDependencies": {
6
6
  "@angular/common": ">=17.0.0",
7
7
  "@angular/core": ">=17.0.0",
8
- "@scania/tegel": "^1.12.1"
8
+ "@scania/tegel": "^1.13.0"
9
9
  },
10
10
  "dependencies": {
11
11
  "tslib": "^2.3.0"
package/public-api.d.ts CHANGED
@@ -1,3 +1,8 @@
1
1
  export * from './lib/components.module';
2
2
  export { DIRECTIVES } from './lib/stencil-generated';
3
+ export { TextValueAccessor } from './lib/stencil-generated/text-value-accessor';
4
+ export { BooleanValueAccessor } from './lib/stencil-generated/boolean-value-accessor';
5
+ export { NumericValueAccessor } from './lib/stencil-generated/number-value-accessor';
6
+ export { TdsRadioValueAccessor } from './lib/directives/tds-radio-value-accessor';
7
+ export { TdsDropdownValueAccessor } from './lib/directives/tds-dropdown-value-accessor';
3
8
  export * from './lib/stencil-generated/components';