@qualcomm-ui/angular 1.1.1 → 1.2.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.
Files changed (61) hide show
  1. package/button/index.d.ts +3 -2
  2. package/button/index.d.ts.map +1 -1
  3. package/combobox/index.d.ts +1 -0
  4. package/combobox/index.d.ts.map +1 -1
  5. package/fesm2022/qualcomm-ui-angular-button.mjs +10 -6
  6. package/fesm2022/qualcomm-ui-angular-button.mjs.map +1 -1
  7. package/fesm2022/qualcomm-ui-angular-combobox.mjs +12 -9
  8. package/fesm2022/qualcomm-ui-angular-combobox.mjs.map +1 -1
  9. package/fesm2022/qualcomm-ui-angular-inline-icon-button.mjs +4 -1
  10. package/fesm2022/qualcomm-ui-angular-inline-icon-button.mjs.map +1 -1
  11. package/fesm2022/qualcomm-ui-angular-inline-notification.mjs +8 -5
  12. package/fesm2022/qualcomm-ui-angular-inline-notification.mjs.map +1 -1
  13. package/fesm2022/qualcomm-ui-angular-link.mjs +4 -1
  14. package/fesm2022/qualcomm-ui-angular-link.mjs.map +1 -1
  15. package/fesm2022/qualcomm-ui-angular-menu.mjs +12 -7
  16. package/fesm2022/qualcomm-ui-angular-menu.mjs.map +1 -1
  17. package/fesm2022/qualcomm-ui-angular-number-input.mjs +12 -8
  18. package/fesm2022/qualcomm-ui-angular-number-input.mjs.map +1 -1
  19. package/fesm2022/qualcomm-ui-angular-password-input.mjs +4 -1
  20. package/fesm2022/qualcomm-ui-angular-password-input.mjs.map +1 -1
  21. package/fesm2022/qualcomm-ui-angular-progress-ring.mjs +4 -1
  22. package/fesm2022/qualcomm-ui-angular-progress-ring.mjs.map +1 -1
  23. package/fesm2022/qualcomm-ui-angular-segmented-control.mjs +6 -3
  24. package/fesm2022/qualcomm-ui-angular-segmented-control.mjs.map +1 -1
  25. package/fesm2022/qualcomm-ui-angular-switch.mjs +8 -4
  26. package/fesm2022/qualcomm-ui-angular-switch.mjs.map +1 -1
  27. package/fesm2022/qualcomm-ui-angular-table.mjs +6 -2
  28. package/fesm2022/qualcomm-ui-angular-table.mjs.map +1 -1
  29. package/fesm2022/qualcomm-ui-angular-text-input.mjs +10 -7
  30. package/fesm2022/qualcomm-ui-angular-text-input.mjs.map +1 -1
  31. package/fesm2022/qualcomm-ui-angular-theme.mjs +85 -57
  32. package/fesm2022/qualcomm-ui-angular-theme.mjs.map +1 -1
  33. package/fesm2022/qualcomm-ui-angular-transitions.mjs +34 -0
  34. package/fesm2022/qualcomm-ui-angular-transitions.mjs.map +1 -0
  35. package/inline-icon-button/index.d.ts +2 -1
  36. package/inline-icon-button/index.d.ts.map +1 -1
  37. package/inline-notification/index.d.ts +2 -1
  38. package/inline-notification/index.d.ts.map +1 -1
  39. package/link/index.d.ts +2 -1
  40. package/link/index.d.ts.map +1 -1
  41. package/menu/index.d.ts +2 -1
  42. package/menu/index.d.ts.map +1 -1
  43. package/number-input/index.d.ts +3 -2
  44. package/number-input/index.d.ts.map +1 -1
  45. package/package.json +8 -4
  46. package/password-input/index.d.ts +2 -1
  47. package/password-input/index.d.ts.map +1 -1
  48. package/progress-ring/index.d.ts +2 -1
  49. package/progress-ring/index.d.ts.map +1 -1
  50. package/segmented-control/index.d.ts +2 -1
  51. package/segmented-control/index.d.ts.map +1 -1
  52. package/switch/index.d.ts +3 -2
  53. package/switch/index.d.ts.map +1 -1
  54. package/table/index.d.ts +2 -1
  55. package/table/index.d.ts.map +1 -1
  56. package/text-input/index.d.ts +2 -1
  57. package/text-input/index.d.ts.map +1 -1
  58. package/theme/index.d.ts +36 -23
  59. package/theme/index.d.ts.map +1 -1
  60. package/transitions/index.d.ts +13 -0
  61. package/transitions/index.d.ts.map +1 -0
@@ -1 +1 @@
1
- {"version":3,"file":"qualcomm-ui-angular-segmented-control.mjs","sources":["../../src/segmented-control/qds-segmented-control-context.service.ts","../../src/segmented-control/segmented-control-hidden-input.directive.ts","../../src/segmented-control/segmented-control-item-root.directive.ts","../../src/segmented-control/segmented-control-item-text.directive.ts","../../src/segmented-control/segmented-control-item.component.ts","../../src/segmented-control/segmented-control.directive.ts","../../src/segmented-control/segmented-control.module.ts","../../src/segmented-control/qualcomm-ui-angular-segmented-control.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable} from \"@angular/core\"\n\nimport {\n type ApiContext,\n BaseApiContextService,\n createApiContext,\n} from \"@qualcomm-ui/angular-core/machine\"\nimport type {QdsSegmentedControlApi} from \"@qualcomm-ui/qds-core/segmented-control\"\n\n@Injectable()\nexport class QdsSegmentedControlContextService extends BaseApiContextService<QdsSegmentedControlApi> {}\n\nexport const [\n QDS_SEGMENTED_CONTROL_CONTEXT,\n useQdsSegmentedControlContext,\n provideQdsSegmentedControlContext,\n]: ApiContext<QdsSegmentedControlApi> =\n createApiContext<QdsSegmentedControlApi>(\n \"QdsSegmentedControlContext\",\n QdsSegmentedControlContextService,\n )\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {CoreSegmentedControlHiddenInputDirective} from \"@qualcomm-ui/angular-core/segmented-control\"\n\nimport {useQdsSegmentedControlContext} from \"./qds-segmented-control-context.service\"\n\n/**\n * The segmented control item hidden input.\n */\n@Directive({\n selector: \"[q-segmented-control-hidden-input]\",\n standalone: false,\n})\nexport class SegmentedControlHiddenInputDirective extends CoreSegmentedControlHiddenInputDirective {\n protected readonly qdsSegmentedControlContext =\n useQdsSegmentedControlContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() =>\n this.qdsSegmentedControlContext().getItemHiddenInputBindings(),\n ),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {provideCheckboxContext} from \"@qualcomm-ui/angular-core/checkbox\"\nimport {CoreSegmentedControlItemDirective} from \"@qualcomm-ui/angular-core/segmented-control\"\n\nimport {useQdsSegmentedControlContext} from \"./qds-segmented-control-context.service\"\n\n@Directive({\n providers: [provideCheckboxContext()],\n selector: \"[q-segmented-control-item-root]\",\n standalone: false,\n})\nexport class SegmentedControlItemRootDirective extends CoreSegmentedControlItemDirective {\n protected readonly qdsSegmentedControlContext =\n useQdsSegmentedControlContext()\n\n override ngOnInit() {\n super.ngOnInit()\n\n this.trackBindings.extendWith(\n computed(() => this.qdsSegmentedControlContext().getItemBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {CoreSegmentedControlItemTextDirective} from \"@qualcomm-ui/angular-core/segmented-control\"\n\nimport {useQdsSegmentedControlContext} from \"./qds-segmented-control-context.service\"\n\n/**\n * The text of the segmented control item.\n */\n@Directive({\n selector: \"[q-segmented-control-item-text]\",\n standalone: false,\n})\nexport class SegmentedControlItemTextDirective extends CoreSegmentedControlItemTextDirective {\n protected readonly qdsSegmentedControlContext =\n useQdsSegmentedControlContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSegmentedControlContext().getItemTextBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Component, input} from \"@angular/core\"\n\nimport {provideCheckboxContext} from \"@qualcomm-ui/angular-core/checkbox\"\nimport type {LucideIcon} from \"@qualcomm-ui/angular-core/lucide\"\n\nimport {SegmentedControlItemRootDirective} from \"./segmented-control-item-root.directive\"\n\n@Component({\n providers: [provideCheckboxContext()],\n selector: \"[q-segmented-control-item]\",\n standalone: false,\n template: `\n <ng-content select=\"[q-segmented-control-item-icon]\">\n @if (icon()) {\n <svg [qIcon]=\"icon()!\"></svg>\n }\n </ng-content>\n <ng-content select=\"[q-segmented-control-item-text]\">\n @if (text()) {\n <span q-segmented-control-item-text>{{ text() }}</span>\n }\n </ng-content>\n <ng-content select=\"[q-segmented-control-hidden-input]\">\n <input q-segmented-control-hidden-input />\n </ng-content>\n `,\n})\nexport class SegmentedControlItemComponent extends SegmentedControlItemRootDirective {\n readonly text = input<string>()\n readonly icon = input<LucideIcon | string>()\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive, inject, input} from \"@angular/core\"\n\nimport {normalizeProps} from \"@qualcomm-ui/angular-core/machine\"\nimport {\n CoreSegmentedControlRootDirective,\n provideSegmentedControlContext,\n} from \"@qualcomm-ui/angular-core/segmented-control\"\nimport type {SignalifyInput} from \"@qualcomm-ui/angular-core/signals\"\nimport {\n createQdsSegmentedControlApi,\n type QdsSegmentedControlApiProps,\n type QdsSegmentedControlLayout,\n type QdsSegmentedControlSize,\n type QdsSegmentedControlVariant,\n} from \"@qualcomm-ui/qds-core/segmented-control\"\n\nimport {\n provideQdsSegmentedControlContext,\n QdsSegmentedControlContextService,\n} from \"./qds-segmented-control-context.service\"\n\n@Directive({\n providers: [\n provideSegmentedControlContext(),\n provideQdsSegmentedControlContext(),\n ],\n selector: \"[q-segmented-control]\",\n standalone: false,\n})\nexport class SegmentedControlDirective\n extends CoreSegmentedControlRootDirective\n implements SignalifyInput<QdsSegmentedControlApiProps>\n{\n /**\n * Governs the width and height of the segmented control as well as the font size\n * of its content.\n */\n readonly size = input<QdsSegmentedControlSize | undefined>()\n\n /**\n * The style variant of the segmented control.\n */\n readonly variant = input<QdsSegmentedControlVariant | undefined>()\n\n /**\n * The style variant of the segmented control.\n */\n readonly layout = input<QdsSegmentedControlLayout | undefined>()\n\n protected readonly qdsSegmentedControlService = inject(\n QdsSegmentedControlContextService,\n )\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() =>\n this.qdsSegmentedControlService.context().getGroupBindings(),\n ),\n )\n }\n\n override ngOnInit() {\n super.ngOnInit()\n\n const qdsSegmentedControlApi = computed(() =>\n createQdsSegmentedControlApi(\n {\n layout: this.layout(),\n size: this.size(),\n variant: this.variant(),\n },\n normalizeProps,\n ),\n )\n\n this.qdsSegmentedControlService.init(qdsSegmentedControlApi)\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {NgModule} from \"@angular/core\"\n\nimport {IconDirective} from \"@qualcomm-ui/angular/icon\"\n\nimport {SegmentedControlHiddenInputDirective} from \"./segmented-control-hidden-input.directive\"\nimport {SegmentedControlItemRootDirective} from \"./segmented-control-item-root.directive\"\nimport {SegmentedControlItemTextDirective} from \"./segmented-control-item-text.directive\"\nimport {SegmentedControlItemComponent} from \"./segmented-control-item.component\"\nimport {SegmentedControlDirective} from \"./segmented-control.directive\"\n\n@NgModule({\n declarations: [\n SegmentedControlDirective,\n SegmentedControlItemComponent,\n SegmentedControlItemRootDirective,\n SegmentedControlItemTextDirective,\n SegmentedControlHiddenInputDirective,\n ],\n exports: [\n SegmentedControlDirective,\n SegmentedControlItemComponent,\n SegmentedControlItemRootDirective,\n SegmentedControlItemTextDirective,\n SegmentedControlHiddenInputDirective,\n ],\n imports: [IconDirective],\n})\nexport class SegmentedControlModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i2.SegmentedControlItemTextDirective","i3.SegmentedControlHiddenInputDirective"],"mappings":";;;;;;;;;AAAA;AACA;AAYM,MAAO,iCAAkC,SAAQ,qBAA6C,CAAA;wGAAvF,iCAAiC,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA;4GAAjC,iCAAiC,EAAA,CAAA;;4FAAjC,iCAAiC,EAAA,UAAA,EAAA,CAAA;kBAD7C;;AAGM,MAAM,CACX,6BAA6B,EAC7B,6B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A,IAAA,EAAA,CAAA;AACT,oBAAA,SAAS,EAAE;AACT,wBAAA,8BAA8B,EAAE;AAChC,wBAAA,iCAAiC,EAAE;AACpC,qBAAA;AACD,oBAAA,QAAQ,EAAE,uBAAuB;AACjC,oBAAA,UAAU,EAAE,KAAK;AAClB,iBAAA;;;AC/BD;AACA;MA6Ba,sBAAsB,CAAA;wGAAtB,sBAAsB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA;AAAtB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,sBAAsB,iBAf/B,yBAAyB;YACzB,6BAA6B;YAC7B,iCAAiC;YACjC,iCAAiC;YACjC,oCAAoC,CAAA,EAAA,OAAA,EAAA,CAS5B,aAAa,CAAA,EAAA,OAAA,EAAA,CANrB,yBAAyB;YACzB,6BAA6B;YAC7B,iCAAiC;YACjC,iCAAiC;YACjC,oCAAoC,CAAA,EAAA,CAAA;yGAI3B,sBAAsB,EAAA,CAAA;;4FAAtB,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBAjBlC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE;wBACZ,yBAAyB;wBACzB,6BAA6B;wBAC7B,iCAAiC;wBACjC,iCAAiC;wBACjC,oCAAoC;AACrC,qBAAA;AACD,oBAAA,OAAO,EAAE;wBACP,yBAAyB;wBACzB,6BAA6B;wBAC7B,iCAAiC;wBACjC,iCAAiC;wBACjC,oCAAoC;AACrC,qBAAA;oBACD,OAAO,EAAE,CAAC,aAAa,CAAC;AACzB,iBAAA;;;AC7BD;;AAEG;;;;"}
1
+ {"version":3,"file":"qualcomm-ui-angular-segmented-control.mjs","sources":["../../src/segmented-control/qds-segmented-control-context.service.ts","../../src/segmented-control/segmented-control-hidden-input.directive.ts","../../src/segmented-control/segmented-control-item-root.directive.ts","../../src/segmented-control/segmented-control-item-text.directive.ts","../../src/segmented-control/segmented-control-item.component.ts","../../src/segmented-control/segmented-control.directive.ts","../../src/segmented-control/segmented-control.module.ts","../../src/segmented-control/qualcomm-ui-angular-segmented-control.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable} from \"@angular/core\"\n\nimport {\n type ApiContext,\n BaseApiContextService,\n createApiContext,\n} from \"@qualcomm-ui/angular-core/machine\"\nimport type {QdsSegmentedControlApi} from \"@qualcomm-ui/qds-core/segmented-control\"\n\n@Injectable()\nexport class QdsSegmentedControlContextService extends BaseApiContextService<QdsSegmentedControlApi> {}\n\nexport const [\n QDS_SEGMENTED_CONTROL_CONTEXT,\n useQdsSegmentedControlContext,\n provideQdsSegmentedControlContext,\n]: ApiContext<QdsSegmentedControlApi> =\n createApiContext<QdsSegmentedControlApi>(\n \"QdsSegmentedControlContext\",\n QdsSegmentedControlContextService,\n )\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {CoreSegmentedControlHiddenInputDirective} from \"@qualcomm-ui/angular-core/segmented-control\"\n\nimport {useQdsSegmentedControlContext} from \"./qds-segmented-control-context.service\"\n\n/**\n * The segmented control item hidden input.\n */\n@Directive({\n selector: \"[q-segmented-control-hidden-input]\",\n standalone: false,\n})\nexport class SegmentedControlHiddenInputDirective extends CoreSegmentedControlHiddenInputDirective {\n protected readonly qdsSegmentedControlContext =\n useQdsSegmentedControlContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() =>\n this.qdsSegmentedControlContext().getItemHiddenInputBindings(),\n ),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {QuiPreloadDirective} from \"@qualcomm-ui/angular/transitions\"\nimport {provideCheckboxContext} from \"@qualcomm-ui/angular-core/checkbox\"\nimport {CoreSegmentedControlItemDirective} from \"@qualcomm-ui/angular-core/segmented-control\"\n\nimport {useQdsSegmentedControlContext} from \"./qds-segmented-control-context.service\"\n\n@Directive({\n hostDirectives: [QuiPreloadDirective],\n providers: [provideCheckboxContext()],\n selector: \"[q-segmented-control-item-root]\",\n standalone: false,\n})\nexport class SegmentedControlItemRootDirective extends CoreSegmentedControlItemDirective {\n protected readonly qdsSegmentedControlContext =\n useQdsSegmentedControlContext()\n\n override ngOnInit() {\n super.ngOnInit()\n\n this.trackBindings.extendWith(\n computed(() => this.qdsSegmentedControlContext().getItemBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {CoreSegmentedControlItemTextDirective} from \"@qualcomm-ui/angular-core/segmented-control\"\n\nimport {useQdsSegmentedControlContext} from \"./qds-segmented-control-context.service\"\n\n/**\n * The text of the segmented control item.\n */\n@Directive({\n selector: \"[q-segmented-control-item-text]\",\n standalone: false,\n})\nexport class SegmentedControlItemTextDirective extends CoreSegmentedControlItemTextDirective {\n protected readonly qdsSegmentedControlContext =\n useQdsSegmentedControlContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSegmentedControlContext().getItemTextBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Component, input} from \"@angular/core\"\n\nimport {provideCheckboxContext} from \"@qualcomm-ui/angular-core/checkbox\"\nimport type {LucideIcon} from \"@qualcomm-ui/angular-core/lucide\"\n\nimport {SegmentedControlItemRootDirective} from \"./segmented-control-item-root.directive\"\n\n@Component({\n providers: [provideCheckboxContext()],\n selector: \"[q-segmented-control-item]\",\n standalone: false,\n template: `\n <ng-content select=\"[q-segmented-control-item-icon]\">\n @if (icon()) {\n <svg [qIcon]=\"icon()!\"></svg>\n }\n </ng-content>\n <ng-content select=\"[q-segmented-control-item-text]\">\n @if (text()) {\n <span q-segmented-control-item-text>{{ text() }}</span>\n }\n </ng-content>\n <ng-content select=\"[q-segmented-control-hidden-input]\">\n <input q-segmented-control-hidden-input />\n </ng-content>\n `,\n})\nexport class SegmentedControlItemComponent extends SegmentedControlItemRootDirective {\n readonly text = input<string>()\n readonly icon = input<LucideIcon | string>()\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive, inject, input} from \"@angular/core\"\n\nimport {normalizeProps} from \"@qualcomm-ui/angular-core/machine\"\nimport {\n CoreSegmentedControlRootDirective,\n provideSegmentedControlContext,\n} from \"@qualcomm-ui/angular-core/segmented-control\"\nimport type {SignalifyInput} from \"@qualcomm-ui/angular-core/signals\"\nimport {\n createQdsSegmentedControlApi,\n type QdsSegmentedControlApiProps,\n type QdsSegmentedControlLayout,\n type QdsSegmentedControlSize,\n type QdsSegmentedControlVariant,\n} from \"@qualcomm-ui/qds-core/segmented-control\"\n\nimport {\n provideQdsSegmentedControlContext,\n QdsSegmentedControlContextService,\n} from \"./qds-segmented-control-context.service\"\n\n@Directive({\n providers: [\n provideSegmentedControlContext(),\n provideQdsSegmentedControlContext(),\n ],\n selector: \"[q-segmented-control]\",\n standalone: false,\n})\nexport class SegmentedControlDirective\n extends CoreSegmentedControlRootDirective\n implements SignalifyInput<QdsSegmentedControlApiProps>\n{\n /**\n * Governs the width and height of the segmented control as well as the font size\n * of its content.\n */\n readonly size = input<QdsSegmentedControlSize | undefined>()\n\n /**\n * The style variant of the segmented control.\n */\n readonly variant = input<QdsSegmentedControlVariant | undefined>()\n\n /**\n * The style variant of the segmented control.\n */\n readonly layout = input<QdsSegmentedControlLayout | undefined>()\n\n protected readonly qdsSegmentedControlService = inject(\n QdsSegmentedControlContextService,\n )\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() =>\n this.qdsSegmentedControlService.context().getGroupBindings(),\n ),\n )\n }\n\n override ngOnInit() {\n super.ngOnInit()\n\n const qdsSegmentedControlApi = computed(() =>\n createQdsSegmentedControlApi(\n {\n layout: this.layout(),\n size: this.size(),\n variant: this.variant(),\n },\n normalizeProps,\n ),\n )\n\n this.qdsSegmentedControlService.init(qdsSegmentedControlApi)\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {NgModule} from \"@angular/core\"\n\nimport {IconDirective} from \"@qualcomm-ui/angular/icon\"\n\nimport {SegmentedControlHiddenInputDirective} from \"./segmented-control-hidden-input.directive\"\nimport {SegmentedControlItemRootDirective} from \"./segmented-control-item-root.directive\"\nimport {SegmentedControlItemTextDirective} from \"./segmented-control-item-text.directive\"\nimport {SegmentedControlItemComponent} from \"./segmented-control-item.component\"\nimport {SegmentedControlDirective} from \"./segmented-control.directive\"\n\n@NgModule({\n declarations: [\n SegmentedControlDirective,\n SegmentedControlItemComponent,\n SegmentedControlItemRootDirective,\n SegmentedControlItemTextDirective,\n SegmentedControlHiddenInputDirective,\n ],\n exports: [\n SegmentedControlDirective,\n SegmentedControlItemComponent,\n SegmentedControlItemRootDirective,\n SegmentedControlItemTextDirective,\n SegmentedControlHiddenInputDirective,\n ],\n imports: [IconDirective],\n})\nexport class SegmentedControlModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1","i2.SegmentedControlItemTextDirective","i3.SegmentedControlHiddenInputDirective"],"mappings":";;;;;;;;;;;AAAA;AACA;AAYM,MAAO,iCAAkC,SAAQ,qBAA6C,CAAA;wGAAvF,iCAAiC,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,C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AAE;wBACP,yBAAyB;wBACzB,6BAA6B;wBAC7B,iCAAiC;wBACjC,iCAAiC;wBACjC,oCAAoC;AACrC,qBAAA;oBACD,OAAO,EAAE,CAAC,aAAa,CAAC;AACzB,iBAAA;;;AC7BD;;AAEG;;;;"}
@@ -1,9 +1,11 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { Injectable, computed, Directive, Component, input, inject, NgModule } from '@angular/core';
3
3
  import { BaseApiContextService, createApiContext, normalizeProps, QBindDirective } from '@qualcomm-ui/angular-core/machine';
4
+ import * as i1 from '@qualcomm-ui/angular/transitions';
5
+ import { QuiPreloadDirective } from '@qualcomm-ui/angular/transitions';
4
6
  import { CoreSwitchThumbDirective, CoreSwitchControlDirective, CoreSwitchErrorTextDirective, CoreSwitchHiddenInputDirective, CoreSwitchLabelDirective, CoreSwitchRootDirective, provideSwitchContext } from '@qualcomm-ui/angular-core/switch';
5
7
  import { CircleAlert } from 'lucide-angular';
6
- import * as i1 from '@qualcomm-ui/angular/icon';
8
+ import * as i1$1 from '@qualcomm-ui/angular/icon';
7
9
  import { IconDirective } from '@qualcomm-ui/angular/icon';
8
10
  import { useForbiddenFormControlWarning } from '@qualcomm-ui/angular-core/forms';
9
11
  import { createQdsSwitchApi } from '@qualcomm-ui/qds-core/switch';
@@ -28,11 +30,12 @@ class SwitchThumbDirective extends CoreSwitchThumbDirective {
28
30
  this.trackBindings.extendWith(computed(() => this.qdsSwitchContext().getThumbBindings()));
29
31
  }
30
32
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: SwitchThumbDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
31
- static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.12", type: SwitchThumbDirective, isStandalone: false, selector: "[q-switch-thumb]", usesInheritance: true, ngImport: i0 });
33
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.12", type: SwitchThumbDirective, isStandalone: false, selector: "[q-switch-thumb]", usesInheritance: true, hostDirectives: [{ directive: i1.QuiPreloadDirective }], ngImport: i0 });
32
34
  }
33
35
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: SwitchThumbDirective, decorators: [{
34
36
  type: Directive,
35
37
  args: [{
38
+ hostDirectives: [QuiPreloadDirective],
36
39
  selector: "[q-switch-thumb]",
37
40
  standalone: false,
38
41
  }]
@@ -47,7 +50,7 @@ class SwitchControlComponent extends CoreSwitchControlDirective {
47
50
  this.trackBindings.extendWith(computed(() => this.qdsSwitchContext().getControlBindings()));
48
51
  }
49
52
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: SwitchControlComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
50
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.12", type: SwitchControlComponent, isStandalone: false, selector: "[q-switch-control]", usesInheritance: true, ngImport: i0, template: `
53
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.12", type: SwitchControlComponent, isStandalone: false, selector: "[q-switch-control]", usesInheritance: true, hostDirectives: [{ directive: i1.QuiPreloadDirective }], ngImport: i0, template: `
51
54
  <ng-content>
52
55
  <span q-switch-thumb></span>
53
56
  </ng-content>
@@ -56,6 +59,7 @@ class SwitchControlComponent extends CoreSwitchControlDirective {
56
59
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: SwitchControlComponent, decorators: [{
57
60
  type: Component,
58
61
  args: [{
62
+ hostDirectives: [QuiPreloadDirective],
59
63
  selector: "[q-switch-control]",
60
64
  standalone: false,
61
65
  template: `
@@ -84,7 +88,7 @@ class SwitchErrorTextComponent extends CoreSwitchErrorTextDirective {
84
88
  static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.12", type: SwitchErrorTextComponent, isStandalone: false, selector: "[q-switch-error-text]", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: `
85
89
  <svg [qIcon]="icon()!" />
86
90
  <ng-content />
87
- `, isInline: true, dependencies: [{ kind: "directive", type: i1.IconDirective, selector: "svg[qIcon]", inputs: ["qIcon", "size", "viewBox", "xmlns", "height", "width"] }] });
91
+ `, isInline: true, dependencies: [{ kind: "directive", type: i1$1.IconDirective, selector: "svg[qIcon]", inputs: ["qIcon", "size", "viewBox", "xmlns", "height", "width"] }] });
88
92
  }
89
93
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: SwitchErrorTextComponent, decorators: [{
90
94
  type: Component,
@@ -1 +1 @@
1
- {"version":3,"file":"qualcomm-ui-angular-switch.mjs","sources":["../../src/switch/qds-switch-context.service.ts","../../src/switch/switch-thumb.directive.ts","../../src/switch/switch-control.component.ts","../../src/switch/switch-error-text.component.ts","../../src/switch/switch-hidden-input.directive.ts","../../src/switch/switch-label.directive.ts","../../src/switch/switch-root.directive.ts","../../src/switch/switch.component.ts","../../src/switch/switch.module.ts","../../src/switch/qualcomm-ui-angular-switch.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable} from \"@angular/core\"\n\nimport {\n type ApiContext,\n BaseApiContextService,\n createApiContext,\n} from \"@qualcomm-ui/angular-core/machine\"\nimport type {QdsSwitchApi} from \"@qualcomm-ui/qds-core/switch\"\n\n@Injectable()\nexport class QdsSwitchContextService extends BaseApiContextService<QdsSwitchApi> {}\n\nexport const [\n QDS_SWITCH_CONTEXT,\n useQdsSwitchContext,\n provideQdsSwitchContext,\n]: ApiContext<QdsSwitchApi> = createApiContext<QdsSwitchApi>(\n \"QdsSwitchContext\",\n QdsSwitchContextService,\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {CoreSwitchThumbDirective} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {useQdsSwitchContext} from \"./qds-switch-context.service\"\n\n@Directive({\n selector: \"[q-switch-thumb]\",\n standalone: false,\n})\nexport class SwitchThumbDirective extends CoreSwitchThumbDirective {\n protected readonly qdsSwitchContext = useQdsSwitchContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchContext().getThumbBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Component, computed} from \"@angular/core\"\n\nimport {CoreSwitchControlDirective} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {useQdsSwitchContext} from \"./qds-switch-context.service\"\n\n@Component({\n selector: \"[q-switch-control]\",\n standalone: false,\n template: `\n <ng-content>\n <span q-switch-thumb></span>\n </ng-content>\n `,\n})\nexport class SwitchControlComponent extends CoreSwitchControlDirective {\n protected readonly qdsSwitchContext = useQdsSwitchContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchContext().getControlBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Component, computed, input} from \"@angular/core\"\nimport {CircleAlert} from \"lucide-angular\"\n\nimport type {LucideIconOrString} from \"@qualcomm-ui/angular-core/lucide\"\nimport {CoreSwitchErrorTextDirective} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {useQdsSwitchContext} from \"./qds-switch-context.service\"\n\n@Component({\n selector: \"[q-switch-error-text]\",\n standalone: false,\n template: `\n <svg [qIcon]=\"icon()!\" />\n <ng-content />\n `,\n})\nexport class SwitchErrorTextComponent extends CoreSwitchErrorTextDirective {\n /**\n * Error indicator icon.\n *\n * @default CircleAlert\n */\n readonly icon = input<LucideIconOrString>(CircleAlert)\n\n protected readonly qdsSwitchContext = useQdsSwitchContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchContext().getErrorTextBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {useForbiddenFormControlWarning} from \"@qualcomm-ui/angular-core/forms\"\nimport {CoreSwitchHiddenInputDirective} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {useQdsSwitchContext} from \"./qds-switch-context.service\"\n\n@Directive({\n selector: \"[q-switch-hidden-input]\",\n standalone: false,\n})\nexport class SwitchHiddenInputDirective extends CoreSwitchHiddenInputDirective {\n protected readonly qdsSwitchContext = useQdsSwitchContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchContext().getHiddenInputBindings()),\n )\n useForbiddenFormControlWarning({\n directive: \"q-switch-hidden-input\",\n rootDirective: \"q-switch\",\n })\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {CoreSwitchLabelDirective} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {useQdsSwitchContext} from \"./qds-switch-context.service\"\n\n@Directive({\n selector: \"[q-switch-label]\",\n standalone: false,\n})\nexport class SwitchLabelDirective extends CoreSwitchLabelDirective {\n protected readonly qdsSwitchContext = useQdsSwitchContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchContext().getLabelBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive, inject, input} from \"@angular/core\"\n\nimport {normalizeProps} from \"@qualcomm-ui/angular-core/machine\"\nimport type {SignalifyInput} from \"@qualcomm-ui/angular-core/signals\"\nimport {\n CoreSwitchRootDirective,\n provideSwitchContext,\n} from \"@qualcomm-ui/angular-core/switch\"\nimport {\n createQdsSwitchApi,\n type QdsSwitchApiProps,\n type QdsSwitchSize,\n} from \"@qualcomm-ui/qds-core/switch\"\n\nimport {\n provideQdsSwitchContext,\n QdsSwitchContextService,\n} from \"./qds-switch-context.service\"\n\n@Directive({\n providers: [provideSwitchContext(), provideQdsSwitchContext()],\n selector: \"[q-switch-root]\",\n standalone: false,\n})\nexport class SwitchRootDirective\n extends CoreSwitchRootDirective\n implements SignalifyInput<QdsSwitchApiProps>\n{\n /**\n * Size of the component and its label.\n *\n * @default \"md\"\n */\n readonly size = input<QdsSwitchSize | undefined>()\n\n readonly qdsSwitchService = inject(QdsSwitchContextService)\n\n override ngOnInit() {\n super.ngOnInit()\n\n this.qdsSwitchService.init(\n computed(() => createQdsSwitchApi({size: this.size()}, normalizeProps)),\n )\n\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchService.context().getRootBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Component, input} from \"@angular/core\"\n\nimport {provideSwitchContext} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {provideQdsSwitchContext} from \"./qds-switch-context.service\"\nimport {SwitchRootDirective} from \"./switch-root.directive\"\n\n@Component({\n providers: [provideSwitchContext(), provideQdsSwitchContext()],\n selector: \"[q-switch]\",\n standalone: false,\n template: `\n <ng-content select=\"[q-switch-hidden-input]\">\n <input q-switch-hidden-input />\n </ng-content>\n <ng-content select=\"[q-switch-control]\">\n <div q-switch-control>\n <div q-switch-thumb></div>\n </div>\n </ng-content>\n <ng-content select=\"[q-switch-label]\">\n @if (label()) {\n <span q-switch-label>\n {{ label() }}\n </span>\n }\n </ng-content>\n <ng-content select=\"[q-switch-error-text]\">\n @if (errorText()) {\n <div q-switch-error-text>\n {{ errorText() }}\n </div>\n }\n </ng-content>\n `,\n})\nexport class SwitchComponent extends SwitchRootDirective {\n /**\n * Optional error that describes the switch when the field is invalid. This\n * element is automatically associated with the switch for accessibility.\n *\n * @remarks\n * To customize the element, provide it using the directive instead:\n *\n * ```angular-html\n * <label q-switch>\n * <div q-switch-error-text>...</div>\n * </label>\n * ```\n */\n readonly errorText = input<string>()\n\n /**\n * Optional label describing the element. Recommended. This element is\n * automatically associated with the component's input element for accessibility.\n *\n * @remarks\n * To customize the element, provide it using the directive instead:\n *\n * ```angular-html\n * <label q-switch>\n * <div q-switch-label>...</div>\n * </label>\n * ```\n */\n readonly label = input<string>()\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {NgModule} from \"@angular/core\"\n\nimport {IconDirective} from \"@qualcomm-ui/angular/icon\"\nimport {QBindDirective} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {SwitchControlComponent} from \"./switch-control.component\"\nimport {SwitchErrorTextComponent} from \"./switch-error-text.component\"\nimport {SwitchHiddenInputDirective} from \"./switch-hidden-input.directive\"\nimport {SwitchLabelDirective} from \"./switch-label.directive\"\nimport {SwitchRootDirective} from \"./switch-root.directive\"\nimport {SwitchThumbDirective} from \"./switch-thumb.directive\"\nimport {SwitchComponent} from \"./switch.component\"\n\n@NgModule({\n declarations: [\n SwitchComponent,\n SwitchRootDirective,\n SwitchControlComponent,\n SwitchLabelDirective,\n SwitchHiddenInputDirective,\n SwitchThumbDirective,\n SwitchErrorTextComponent,\n ],\n exports: [\n SwitchComponent,\n SwitchRootDirective,\n SwitchControlComponent,\n SwitchLabelDirective,\n SwitchHiddenInputDirective,\n SwitchThumbDirective,\n SwitchErrorTextComponent,\n ],\n imports: [QBindDirective, IconDirective],\n})\nexport class SwitchModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1.SwitchThumbD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BACf,mBAAmB;wBACnB,sBAAsB;wBACtB,oBAAoB;wBACpB,0BAA0B;wBAC1B,oBAAoB;wBACpB,wBAAwB;AACzB,qBAAA;AACD,oBAAA,OAAO,EAAE;wBACP,eAAe;wBACf,mBAAmB;wBACnB,sBAAsB;wBACtB,oBAAoB;wBACpB,0BAA0B;wBAC1B,oBAAoB;wBACpB,wBAAwB;AACzB,qBAAA;AACD,oBAAA,OAAO,EAAE,CAAC,cAAc,EAAE,aAAa,CAAC;AACzC,iBAAA;;;ACpCD;;AAEG;;;;"}
1
+ {"version":3,"file":"qualcomm-ui-angular-switch.mjs","sources":["../../src/switch/qds-switch-context.service.ts","../../src/switch/switch-thumb.directive.ts","../../src/switch/switch-control.component.ts","../../src/switch/switch-error-text.component.ts","../../src/switch/switch-hidden-input.directive.ts","../../src/switch/switch-label.directive.ts","../../src/switch/switch-root.directive.ts","../../src/switch/switch.component.ts","../../src/switch/switch.module.ts","../../src/switch/qualcomm-ui-angular-switch.ts"],"sourcesContent":["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Injectable} from \"@angular/core\"\n\nimport {\n type ApiContext,\n BaseApiContextService,\n createApiContext,\n} from \"@qualcomm-ui/angular-core/machine\"\nimport type {QdsSwitchApi} from \"@qualcomm-ui/qds-core/switch\"\n\n@Injectable()\nexport class QdsSwitchContextService extends BaseApiContextService<QdsSwitchApi> {}\n\nexport const [\n QDS_SWITCH_CONTEXT,\n useQdsSwitchContext,\n provideQdsSwitchContext,\n]: ApiContext<QdsSwitchApi> = createApiContext<QdsSwitchApi>(\n \"QdsSwitchContext\",\n QdsSwitchContextService,\n)\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {QuiPreloadDirective} from \"@qualcomm-ui/angular/transitions\"\nimport {CoreSwitchThumbDirective} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {useQdsSwitchContext} from \"./qds-switch-context.service\"\n\n@Directive({\n hostDirectives: [QuiPreloadDirective],\n selector: \"[q-switch-thumb]\",\n standalone: false,\n})\nexport class SwitchThumbDirective extends CoreSwitchThumbDirective {\n protected readonly qdsSwitchContext = useQdsSwitchContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchContext().getThumbBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Component, computed} from \"@angular/core\"\n\nimport {QuiPreloadDirective} from \"@qualcomm-ui/angular/transitions\"\nimport {CoreSwitchControlDirective} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {useQdsSwitchContext} from \"./qds-switch-context.service\"\n\n@Component({\n hostDirectives: [QuiPreloadDirective],\n selector: \"[q-switch-control]\",\n standalone: false,\n template: `\n <ng-content>\n <span q-switch-thumb></span>\n </ng-content>\n `,\n})\nexport class SwitchControlComponent extends CoreSwitchControlDirective {\n protected readonly qdsSwitchContext = useQdsSwitchContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchContext().getControlBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Component, computed, input} from \"@angular/core\"\nimport {CircleAlert} from \"lucide-angular\"\n\nimport type {LucideIconOrString} from \"@qualcomm-ui/angular-core/lucide\"\nimport {CoreSwitchErrorTextDirective} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {useQdsSwitchContext} from \"./qds-switch-context.service\"\n\n@Component({\n selector: \"[q-switch-error-text]\",\n standalone: false,\n template: `\n <svg [qIcon]=\"icon()!\" />\n <ng-content />\n `,\n})\nexport class SwitchErrorTextComponent extends CoreSwitchErrorTextDirective {\n /**\n * Error indicator icon.\n *\n * @default CircleAlert\n */\n readonly icon = input<LucideIconOrString>(CircleAlert)\n\n protected readonly qdsSwitchContext = useQdsSwitchContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchContext().getErrorTextBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {useForbiddenFormControlWarning} from \"@qualcomm-ui/angular-core/forms\"\nimport {CoreSwitchHiddenInputDirective} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {useQdsSwitchContext} from \"./qds-switch-context.service\"\n\n@Directive({\n selector: \"[q-switch-hidden-input]\",\n standalone: false,\n})\nexport class SwitchHiddenInputDirective extends CoreSwitchHiddenInputDirective {\n protected readonly qdsSwitchContext = useQdsSwitchContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchContext().getHiddenInputBindings()),\n )\n useForbiddenFormControlWarning({\n directive: \"q-switch-hidden-input\",\n rootDirective: \"q-switch\",\n })\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive} from \"@angular/core\"\n\nimport {CoreSwitchLabelDirective} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {useQdsSwitchContext} from \"./qds-switch-context.service\"\n\n@Directive({\n selector: \"[q-switch-label]\",\n standalone: false,\n})\nexport class SwitchLabelDirective extends CoreSwitchLabelDirective {\n protected readonly qdsSwitchContext = useQdsSwitchContext()\n\n constructor() {\n super()\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchContext().getLabelBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {computed, Directive, inject, input} from \"@angular/core\"\n\nimport {normalizeProps} from \"@qualcomm-ui/angular-core/machine\"\nimport type {SignalifyInput} from \"@qualcomm-ui/angular-core/signals\"\nimport {\n CoreSwitchRootDirective,\n provideSwitchContext,\n} from \"@qualcomm-ui/angular-core/switch\"\nimport {\n createQdsSwitchApi,\n type QdsSwitchApiProps,\n type QdsSwitchSize,\n} from \"@qualcomm-ui/qds-core/switch\"\n\nimport {\n provideQdsSwitchContext,\n QdsSwitchContextService,\n} from \"./qds-switch-context.service\"\n\n@Directive({\n providers: [provideSwitchContext(), provideQdsSwitchContext()],\n selector: \"[q-switch-root]\",\n standalone: false,\n})\nexport class SwitchRootDirective\n extends CoreSwitchRootDirective\n implements SignalifyInput<QdsSwitchApiProps>\n{\n /**\n * Size of the component and its label.\n *\n * @default \"md\"\n */\n readonly size = input<QdsSwitchSize | undefined>()\n\n readonly qdsSwitchService = inject(QdsSwitchContextService)\n\n override ngOnInit() {\n super.ngOnInit()\n\n this.qdsSwitchService.init(\n computed(() => createQdsSwitchApi({size: this.size()}, normalizeProps)),\n )\n\n this.trackBindings.extendWith(\n computed(() => this.qdsSwitchService.context().getRootBindings()),\n )\n }\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {Component, input} from \"@angular/core\"\n\nimport {provideSwitchContext} from \"@qualcomm-ui/angular-core/switch\"\n\nimport {provideQdsSwitchContext} from \"./qds-switch-context.service\"\nimport {SwitchRootDirective} from \"./switch-root.directive\"\n\n@Component({\n providers: [provideSwitchContext(), provideQdsSwitchContext()],\n selector: \"[q-switch]\",\n standalone: false,\n template: `\n <ng-content select=\"[q-switch-hidden-input]\">\n <input q-switch-hidden-input />\n </ng-content>\n <ng-content select=\"[q-switch-control]\">\n <div q-switch-control>\n <div q-switch-thumb></div>\n </div>\n </ng-content>\n <ng-content select=\"[q-switch-label]\">\n @if (label()) {\n <span q-switch-label>\n {{ label() }}\n </span>\n }\n </ng-content>\n <ng-content select=\"[q-switch-error-text]\">\n @if (errorText()) {\n <div q-switch-error-text>\n {{ errorText() }}\n </div>\n }\n </ng-content>\n `,\n})\nexport class SwitchComponent extends SwitchRootDirective {\n /**\n * Optional error that describes the switch when the field is invalid. This\n * element is automatically associated with the switch for accessibility.\n *\n * @remarks\n * To customize the element, provide it using the directive instead:\n *\n * ```angular-html\n * <label q-switch>\n * <div q-switch-error-text>...</div>\n * </label>\n * ```\n */\n readonly errorText = input<string>()\n\n /**\n * Optional label describing the element. Recommended. This element is\n * automatically associated with the component's input element for accessibility.\n *\n * @remarks\n * To customize the element, provide it using the directive instead:\n *\n * ```angular-html\n * <label q-switch>\n * <div q-switch-label>...</div>\n * </label>\n * ```\n */\n readonly label = input<string>()\n}\n","// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {NgModule} from \"@angular/core\"\n\nimport {IconDirective} from \"@qualcomm-ui/angular/icon\"\nimport {QBindDirective} from \"@qualcomm-ui/angular-core/machine\"\n\nimport {SwitchControlComponent} from \"./switch-control.component\"\nimport {SwitchErrorTextComponent} from \"./switch-error-text.component\"\nimport {SwitchHiddenInputDirective} from \"./switch-hidden-input.directive\"\nimport {SwitchLabelDirective} from \"./switch-label.directive\"\nimport {SwitchRootDirective} from \"./switch-root.directive\"\nimport {SwitchThumbDirective} from \"./switch-thumb.directive\"\nimport {SwitchComponent} from \"./switch.component\"\n\n@NgModule({\n declarations: [\n SwitchComponent,\n SwitchRootDirective,\n SwitchControlComponent,\n SwitchLabelDirective,\n SwitchHiddenInputDirective,\n SwitchThumbDirective,\n SwitchErrorTextComponent,\n ],\n exports: [\n SwitchComponent,\n SwitchRootDirective,\n SwitchControlComponent,\n SwitchLabelDirective,\n SwitchHiddenInputDirective,\n SwitchThumbDirective,\n SwitchErrorTextComponent,\n ],\n imports: [QBindDirective, IconDirective],\n})\nexport class SwitchModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i2.SwitchThumbDirective","i1","i1.SwitchControlComponent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YACpB,0BAA0B;YAC1B,oBAAoB;YACpB,wBAAwB,CAAA,EAAA,CAAA;yGAIf,YAAY,EAAA,CAAA;;4FAAZ,YAAY,EAAA,UAAA,EAAA,CAAA;kBArBxB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE;wBACZ,eAAe;wBACf,mBAAmB;wBACnB,sBAAsB;wBACtB,oBAAoB;wBACpB,0BAA0B;wBAC1B,oBAAoB;wBACpB,wBAAwB;AACzB,qBAAA;AACD,oBAAA,OAAO,EAAE;wBACP,eAAe;wBACf,mBAAmB;wBACnB,sBAAsB;wBACtB,oBAAoB;wBACpB,0BAA0B;wBAC1B,oBAAoB;wBACpB,wBAAwB;AACzB,qBAAA;AACD,oBAAA,OAAO,EAAE,CAAC,cAAc,EAAE,aAAa,CAAC;AACzC,iBAAA;;;ACpCD;;AAEG;;;;"}
@@ -834,6 +834,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
834
834
  // Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
835
835
  // SPDX-License-Identifier: BSD-3-Clause-Clear
836
836
  class TableRowExpandButtonDirective {
837
+ isExpanded = input(undefined, ...(ngDevMode ? [{ debugName: "isExpanded", transform: booleanAttribute }] : [{
838
+ transform: booleanAttribute,
839
+ }]));
837
840
  /**
838
841
  * The row associated with the expand button.
839
842
  */
@@ -850,13 +853,14 @@ class TableRowExpandButtonDirective {
850
853
  variant: "fixed",
851
854
  });
852
855
  trackBindings = useTrackBindings(() => mergeProps(this.inlineIconButtonApi().getRootBindings(), qdsTableApi.getRowExpandButtonBindings({
856
+ isExpanded: this.isExpanded(),
853
857
  row: this.row(),
854
858
  })));
855
859
  ngOnInit() {
856
860
  this.trackBindings();
857
861
  }
858
862
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: TableRowExpandButtonDirective, deps: [], target: i0.ɵɵFactoryTarget.Component });
859
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.12", type: TableRowExpandButtonDirective, isStandalone: false, selector: "[q-table-row-expand-button]", inputs: { row: { classPropertyName: "row", publicName: "row", isSignal: true, isRequired: true, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null } }, providers: [provideIcons({ ChevronRight })], ngImport: i0, template: `
863
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.12", type: TableRowExpandButtonDirective, isStandalone: false, selector: "[q-table-row-expand-button]", inputs: { isExpanded: { classPropertyName: "isExpanded", publicName: "isExpanded", isSignal: true, isRequired: false, transformFunction: null }, row: { classPropertyName: "row", publicName: "row", isSignal: true, isRequired: true, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null } }, providers: [provideIcons({ ChevronRight })], ngImport: i0, template: `
860
864
  <svg
861
865
  [q-bind]="inlineIconButtonApi().getIconBindings()"
862
866
  [qIcon]="icon()"
@@ -876,7 +880,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
876
880
  ></svg>
877
881
  `,
878
882
  }]
879
- }], propDecorators: { row: [{ type: i0.Input, args: [{ isSignal: true, alias: "row", required: true }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }] } });
883
+ }], propDecorators: { isExpanded: [{ type: i0.Input, args: [{ isSignal: true, alias: "isExpanded", required: false }] }], row: [{ type: i0.Input, args: [{ isSignal: true, alias: "row", required: true }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }] } });
880
884
 
881
885
  // Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
882
886
  // SPDX-License-Identifier: BSD-3-Clause-Clear