@tectra-ng/ui 0.1.0 → 0.1.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.
Files changed (96) hide show
  1. package/country/README.md +14 -4
  2. package/data-view/README.md +71 -0
  3. package/fesm2022/tectra-ng-ui-autocomplete.mjs +2 -2
  4. package/fesm2022/tectra-ng-ui-autocomplete.mjs.map +1 -1
  5. package/fesm2022/tectra-ng-ui-cascade-select.mjs +2 -2
  6. package/fesm2022/tectra-ng-ui-cascade-select.mjs.map +1 -1
  7. package/fesm2022/tectra-ng-ui-chip.mjs +2 -2
  8. package/fesm2022/tectra-ng-ui-chip.mjs.map +1 -1
  9. package/fesm2022/tectra-ng-ui-chips-input.mjs +2 -2
  10. package/fesm2022/tectra-ng-ui-chips-input.mjs.map +1 -1
  11. package/fesm2022/tectra-ng-ui-color-picker.mjs +2 -2
  12. package/fesm2022/tectra-ng-ui-color-picker.mjs.map +1 -1
  13. package/fesm2022/tectra-ng-ui-country.mjs +47 -6
  14. package/fesm2022/tectra-ng-ui-country.mjs.map +1 -1
  15. package/fesm2022/tectra-ng-ui-data-view.mjs +1370 -0
  16. package/fesm2022/tectra-ng-ui-data-view.mjs.map +1 -0
  17. package/fesm2022/tectra-ng-ui-fieldset.mjs +2 -2
  18. package/fesm2022/tectra-ng-ui-fieldset.mjs.map +1 -1
  19. package/fesm2022/tectra-ng-ui-input-number.mjs +2 -2
  20. package/fesm2022/tectra-ng-ui-input-number.mjs.map +1 -1
  21. package/fesm2022/tectra-ng-ui-input.mjs +2 -2
  22. package/fesm2022/tectra-ng-ui-input.mjs.map +1 -1
  23. package/fesm2022/tectra-ng-ui-listbox.mjs +2 -2
  24. package/fesm2022/tectra-ng-ui-listbox.mjs.map +1 -1
  25. package/fesm2022/tectra-ng-ui-menu.mjs +2 -2
  26. package/fesm2022/tectra-ng-ui-menu.mjs.map +1 -1
  27. package/fesm2022/tectra-ng-ui-message.mjs +2 -2
  28. package/fesm2022/tectra-ng-ui-message.mjs.map +1 -1
  29. package/fesm2022/tectra-ng-ui-multiselect.mjs +2 -2
  30. package/fesm2022/tectra-ng-ui-multiselect.mjs.map +1 -1
  31. package/fesm2022/tectra-ng-ui-paginator.mjs +2 -2
  32. package/fesm2022/tectra-ng-ui-paginator.mjs.map +1 -1
  33. package/fesm2022/tectra-ng-ui-select.mjs +4 -4
  34. package/fesm2022/tectra-ng-ui-select.mjs.map +1 -1
  35. package/fesm2022/tectra-ng-ui-slider.mjs +2 -2
  36. package/fesm2022/tectra-ng-ui-slider.mjs.map +1 -1
  37. package/fesm2022/tectra-ng-ui-table.mjs +1373 -1333
  38. package/fesm2022/tectra-ng-ui-table.mjs.map +1 -1
  39. package/fesm2022/tectra-ng-ui-tag.mjs +2 -2
  40. package/fesm2022/tectra-ng-ui-tag.mjs.map +1 -1
  41. package/fesm2022/tectra-ng-ui-toggle-switch.mjs +2 -2
  42. package/fesm2022/tectra-ng-ui-toggle-switch.mjs.map +1 -1
  43. package/fesm2022/tectra-ng-ui-tree-select.mjs +7 -46
  44. package/fesm2022/tectra-ng-ui-tree-select.mjs.map +1 -1
  45. package/fesm2022/tectra-ng-ui-tree-table.mjs +901 -0
  46. package/fesm2022/tectra-ng-ui-tree-table.mjs.map +1 -0
  47. package/fesm2022/tectra-ng-ui-tree.mjs +1940 -0
  48. package/fesm2022/tectra-ng-ui-tree.mjs.map +1 -0
  49. package/fesm2022/tectra-ng-ui-virtual-scroller.mjs +928 -0
  50. package/fesm2022/tectra-ng-ui-virtual-scroller.mjs.map +1 -0
  51. package/package.json +17 -1
  52. package/tree/README.md +93 -0
  53. package/tree-table/README.md +84 -0
  54. package/types/tectra-ng-ui-autocomplete.d.ts +11 -0
  55. package/types/tectra-ng-ui-autocomplete.d.ts.map +1 -1
  56. package/types/tectra-ng-ui-chip.d.ts +3 -0
  57. package/types/tectra-ng-ui-chip.d.ts.map +1 -1
  58. package/types/tectra-ng-ui-country-select.d.ts +11 -0
  59. package/types/tectra-ng-ui-country-select.d.ts.map +1 -1
  60. package/types/tectra-ng-ui-country.d.ts +9 -3
  61. package/types/tectra-ng-ui-country.d.ts.map +1 -1
  62. package/types/tectra-ng-ui-data-view.d.ts +363 -0
  63. package/types/tectra-ng-ui-data-view.d.ts.map +1 -0
  64. package/types/tectra-ng-ui-fieldset.d.ts +8 -0
  65. package/types/tectra-ng-ui-fieldset.d.ts.map +1 -1
  66. package/types/tectra-ng-ui-input-number.d.ts +1 -0
  67. package/types/tectra-ng-ui-input-number.d.ts.map +1 -1
  68. package/types/tectra-ng-ui-input.d.ts +4 -0
  69. package/types/tectra-ng-ui-input.d.ts.map +1 -1
  70. package/types/tectra-ng-ui-menu.d.ts +2 -0
  71. package/types/tectra-ng-ui-menu.d.ts.map +1 -1
  72. package/types/tectra-ng-ui-message.d.ts +5 -0
  73. package/types/tectra-ng-ui-message.d.ts.map +1 -1
  74. package/types/tectra-ng-ui-multiselect.d.ts +11 -0
  75. package/types/tectra-ng-ui-multiselect.d.ts.map +1 -1
  76. package/types/tectra-ng-ui-paginator.d.ts +1 -0
  77. package/types/tectra-ng-ui-paginator.d.ts.map +1 -1
  78. package/types/tectra-ng-ui-select.d.ts +11 -0
  79. package/types/tectra-ng-ui-select.d.ts.map +1 -1
  80. package/types/tectra-ng-ui-slider.d.ts +1 -0
  81. package/types/tectra-ng-ui-slider.d.ts.map +1 -1
  82. package/types/tectra-ng-ui-table.d.ts +181 -15
  83. package/types/tectra-ng-ui-table.d.ts.map +1 -1
  84. package/types/tectra-ng-ui-tag.d.ts +8 -0
  85. package/types/tectra-ng-ui-tag.d.ts.map +1 -1
  86. package/types/tectra-ng-ui-toggle-switch.d.ts +5 -0
  87. package/types/tectra-ng-ui-toggle-switch.d.ts.map +1 -1
  88. package/types/tectra-ng-ui-tree-select.d.ts +19 -22
  89. package/types/tectra-ng-ui-tree-select.d.ts.map +1 -1
  90. package/types/tectra-ng-ui-tree-table.d.ts +94 -0
  91. package/types/tectra-ng-ui-tree-table.d.ts.map +1 -0
  92. package/types/tectra-ng-ui-tree.d.ts +571 -0
  93. package/types/tectra-ng-ui-tree.d.ts.map +1 -0
  94. package/types/tectra-ng-ui-virtual-scroller.d.ts +297 -0
  95. package/types/tectra-ng-ui-virtual-scroller.d.ts.map +1 -0
  96. package/virtual-scroller/README.md +60 -0
@@ -231,7 +231,7 @@ var TxTag = class TxTag {
231
231
  }
232
232
  `,
233
233
  isInline: true,
234
- styles: [":host{display:inline-flex;align-items:center;max-width:100%;vertical-align:middle;white-space:nowrap}.tx-tag__label{min-width:0;overflow:hidden;text-overflow:ellipsis}.tx-tag__label:empty{display:none}:host([data-styled]){--_tone: var(--tx-tag-primary-color);flex-shrink:0;gap:var(--tx-tag-gap);box-sizing:border-box;padding:var(--tx-tag-padding-y) var(--tx-tag-padding-x);border-radius:var(--tx-tag-border-radius);background:color-mix(in srgb,var(--_tone) var(--tx-tag-tint),transparent);color:var(--_tone);font-family:var(--tx-font-family);font-size:var(--tx-tag-font-size);font-weight:var(--tx-tag-font-weight);line-height:var(--tx-tag-line-height)}:host([data-styled][data-severity=secondary]){--_tone: var(--tx-tag-secondary-color)}:host([data-styled][data-severity=success]){--_tone: var(--tx-tag-success-color)}:host([data-styled][data-severity=info]){--_tone: var(--tx-tag-info-color)}:host([data-styled][data-severity=warn]){--_tone: var(--tx-tag-warn-color)}:host([data-styled][data-severity=danger]){--_tone: var(--tx-tag-danger-color)}:host([data-styled][data-severity=help]){--_tone: var(--tx-tag-help-color)}:host([data-styled][data-severity=contrast]){--_tone: var(--tx-tag-contrast-color)}:host([data-styled][data-size=small]){padding:var(--tx-tag-sm-padding-y) var(--tx-tag-sm-padding-x);font-size:var(--tx-tag-sm-font-size)}:host([data-styled][data-size=large]){padding:var(--tx-tag-lg-padding-y) var(--tx-tag-lg-padding-x);font-size:var(--tx-tag-lg-font-size)}:host([data-styled][data-size=large]){gap:var(--tx-tag-lg-gap)}:host([data-styled].tx-tag--rounded){border-radius:var(--tx-tag-rounded-border-radius)}:host([data-styled]) .tx-tag__icon{display:inline-flex;flex-shrink:0;font-size:var(--tx-tag-icon-size)}:host([data-styled]) .tx-tag__action{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--tx-tag-action-size);height:var(--tx-tag-action-size);margin-inline-end:-3px;padding:0;border:none;border-radius:var(--tx-radius-xs);background:transparent;color:inherit;font-size:.85em;opacity:.75;cursor:pointer;transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),opacity var(--tx-motion-duration) var(--tx-motion-easing)}:host([data-styled]) .tx-tag__action:hover{background:color-mix(in srgb,currentColor 16%,transparent);opacity:1}:host([data-styled]) .tx-tag__action:focus-visible{outline:2px solid var(--tx-tag-focus-ring-color);outline-offset:1px;opacity:1}:host([data-styled]) .tx-tag__action+.tx-tag__action{margin-inline-start:-2px}:host([data-styled]) .tx-tag__copy--done{opacity:1}\n"],
234
+ styles: [":host{display:inline-flex;align-items:center;max-width:100%;vertical-align:middle;white-space:nowrap}.tx-tag__label{min-width:0;overflow:hidden;text-overflow:ellipsis}.tx-tag__label:empty{display:none}:host([data-styled]){--_tone: var(--tx-tag-primary-color);--_background: var(--tx-tag-primary-background);flex-shrink:0;gap:var(--tx-tag-gap);box-sizing:border-box;padding:var(--tx-tag-padding-y) var(--tx-tag-padding-x);border-radius:var(--tx-tag-border-radius);background:color-mix(in srgb,var(--_background) var(--tx-tag-tint),transparent);color:var(--_tone);font-family:var(--tx-font-family);font-size:var(--tx-tag-font-size);font-weight:var(--tx-tag-font-weight);line-height:var(--tx-tag-line-height)}:host([data-styled][data-severity=secondary]){--_tone: var(--tx-tag-secondary-color);--_background: var(--tx-tag-secondary-background)}:host([data-styled][data-severity=success]){--_tone: var(--tx-tag-success-color);--_background: var(--tx-tag-success-background)}:host([data-styled][data-severity=info]){--_tone: var(--tx-tag-info-color);--_background: var(--tx-tag-info-background)}:host([data-styled][data-severity=warn]){--_tone: var(--tx-tag-warn-color);--_background: var(--tx-tag-warn-background)}:host([data-styled][data-severity=danger]){--_tone: var(--tx-tag-danger-color);--_background: var(--tx-tag-danger-background)}:host([data-styled][data-severity=help]){--_tone: var(--tx-tag-help-color);--_background: var(--tx-tag-help-background)}:host([data-styled][data-severity=contrast]){--_tone: var(--tx-tag-contrast-color);--_background: var(--tx-tag-contrast-background)}:host([data-styled][data-size=small]){padding:var(--tx-tag-sm-padding-y) var(--tx-tag-sm-padding-x);font-size:var(--tx-tag-sm-font-size)}:host([data-styled][data-size=large]){padding:var(--tx-tag-lg-padding-y) var(--tx-tag-lg-padding-x);font-size:var(--tx-tag-lg-font-size)}:host([data-styled][data-size=large]){gap:var(--tx-tag-lg-gap)}:host([data-styled].tx-tag--rounded){border-radius:var(--tx-tag-rounded-border-radius)}:host([data-styled]) .tx-tag__icon{display:inline-flex;flex-shrink:0;font-size:var(--tx-tag-icon-size)}:host([data-styled]) .tx-tag__action{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--tx-tag-action-size);height:var(--tx-tag-action-size);margin-inline-end:-3px;padding:0;border:none;border-radius:var(--tx-radius-xs);background:transparent;color:inherit;font-size:.85em;opacity:.75;cursor:pointer;transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),opacity var(--tx-motion-duration) var(--tx-motion-easing)}:host([data-styled]) .tx-tag__action:hover{background:color-mix(in srgb,currentColor 16%,transparent);opacity:1}:host([data-styled]) .tx-tag__action:focus-visible{outline:2px solid var(--tx-tag-focus-ring-color);outline-offset:1px;opacity:1}:host([data-styled]) .tx-tag__action+.tx-tag__action{margin-inline-start:-2px}:host([data-styled]) .tx-tag__copy--done{opacity:1}\n"],
235
235
  dependencies: [{
236
236
  kind: "component",
237
237
  type: TxIcon,
@@ -302,7 +302,7 @@ i0.ɵɵngDeclareClassMetadata({
302
302
  "[attr.data-size]": "resolvedSize()",
303
303
  "[class.tx-tag--rounded]": "rounded()"
304
304
  },
305
- styles: [":host{display:inline-flex;align-items:center;max-width:100%;vertical-align:middle;white-space:nowrap}.tx-tag__label{min-width:0;overflow:hidden;text-overflow:ellipsis}.tx-tag__label:empty{display:none}:host([data-styled]){--_tone: var(--tx-tag-primary-color);flex-shrink:0;gap:var(--tx-tag-gap);box-sizing:border-box;padding:var(--tx-tag-padding-y) var(--tx-tag-padding-x);border-radius:var(--tx-tag-border-radius);background:color-mix(in srgb,var(--_tone) var(--tx-tag-tint),transparent);color:var(--_tone);font-family:var(--tx-font-family);font-size:var(--tx-tag-font-size);font-weight:var(--tx-tag-font-weight);line-height:var(--tx-tag-line-height)}:host([data-styled][data-severity=secondary]){--_tone: var(--tx-tag-secondary-color)}:host([data-styled][data-severity=success]){--_tone: var(--tx-tag-success-color)}:host([data-styled][data-severity=info]){--_tone: var(--tx-tag-info-color)}:host([data-styled][data-severity=warn]){--_tone: var(--tx-tag-warn-color)}:host([data-styled][data-severity=danger]){--_tone: var(--tx-tag-danger-color)}:host([data-styled][data-severity=help]){--_tone: var(--tx-tag-help-color)}:host([data-styled][data-severity=contrast]){--_tone: var(--tx-tag-contrast-color)}:host([data-styled][data-size=small]){padding:var(--tx-tag-sm-padding-y) var(--tx-tag-sm-padding-x);font-size:var(--tx-tag-sm-font-size)}:host([data-styled][data-size=large]){padding:var(--tx-tag-lg-padding-y) var(--tx-tag-lg-padding-x);font-size:var(--tx-tag-lg-font-size)}:host([data-styled][data-size=large]){gap:var(--tx-tag-lg-gap)}:host([data-styled].tx-tag--rounded){border-radius:var(--tx-tag-rounded-border-radius)}:host([data-styled]) .tx-tag__icon{display:inline-flex;flex-shrink:0;font-size:var(--tx-tag-icon-size)}:host([data-styled]) .tx-tag__action{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--tx-tag-action-size);height:var(--tx-tag-action-size);margin-inline-end:-3px;padding:0;border:none;border-radius:var(--tx-radius-xs);background:transparent;color:inherit;font-size:.85em;opacity:.75;cursor:pointer;transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),opacity var(--tx-motion-duration) var(--tx-motion-easing)}:host([data-styled]) .tx-tag__action:hover{background:color-mix(in srgb,currentColor 16%,transparent);opacity:1}:host([data-styled]) .tx-tag__action:focus-visible{outline:2px solid var(--tx-tag-focus-ring-color);outline-offset:1px;opacity:1}:host([data-styled]) .tx-tag__action+.tx-tag__action{margin-inline-start:-2px}:host([data-styled]) .tx-tag__copy--done{opacity:1}\n"]
305
+ styles: [":host{display:inline-flex;align-items:center;max-width:100%;vertical-align:middle;white-space:nowrap}.tx-tag__label{min-width:0;overflow:hidden;text-overflow:ellipsis}.tx-tag__label:empty{display:none}:host([data-styled]){--_tone: var(--tx-tag-primary-color);--_background: var(--tx-tag-primary-background);flex-shrink:0;gap:var(--tx-tag-gap);box-sizing:border-box;padding:var(--tx-tag-padding-y) var(--tx-tag-padding-x);border-radius:var(--tx-tag-border-radius);background:color-mix(in srgb,var(--_background) var(--tx-tag-tint),transparent);color:var(--_tone);font-family:var(--tx-font-family);font-size:var(--tx-tag-font-size);font-weight:var(--tx-tag-font-weight);line-height:var(--tx-tag-line-height)}:host([data-styled][data-severity=secondary]){--_tone: var(--tx-tag-secondary-color);--_background: var(--tx-tag-secondary-background)}:host([data-styled][data-severity=success]){--_tone: var(--tx-tag-success-color);--_background: var(--tx-tag-success-background)}:host([data-styled][data-severity=info]){--_tone: var(--tx-tag-info-color);--_background: var(--tx-tag-info-background)}:host([data-styled][data-severity=warn]){--_tone: var(--tx-tag-warn-color);--_background: var(--tx-tag-warn-background)}:host([data-styled][data-severity=danger]){--_tone: var(--tx-tag-danger-color);--_background: var(--tx-tag-danger-background)}:host([data-styled][data-severity=help]){--_tone: var(--tx-tag-help-color);--_background: var(--tx-tag-help-background)}:host([data-styled][data-severity=contrast]){--_tone: var(--tx-tag-contrast-color);--_background: var(--tx-tag-contrast-background)}:host([data-styled][data-size=small]){padding:var(--tx-tag-sm-padding-y) var(--tx-tag-sm-padding-x);font-size:var(--tx-tag-sm-font-size)}:host([data-styled][data-size=large]){padding:var(--tx-tag-lg-padding-y) var(--tx-tag-lg-padding-x);font-size:var(--tx-tag-lg-font-size)}:host([data-styled][data-size=large]){gap:var(--tx-tag-lg-gap)}:host([data-styled].tx-tag--rounded){border-radius:var(--tx-tag-rounded-border-radius)}:host([data-styled]) .tx-tag__icon{display:inline-flex;flex-shrink:0;font-size:var(--tx-tag-icon-size)}:host([data-styled]) .tx-tag__action{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;width:var(--tx-tag-action-size);height:var(--tx-tag-action-size);margin-inline-end:-3px;padding:0;border:none;border-radius:var(--tx-radius-xs);background:transparent;color:inherit;font-size:.85em;opacity:.75;cursor:pointer;transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),opacity var(--tx-motion-duration) var(--tx-motion-easing)}:host([data-styled]) .tx-tag__action:hover{background:color-mix(in srgb,currentColor 16%,transparent);opacity:1}:host([data-styled]) .tx-tag__action:focus-visible{outline:2px solid var(--tx-tag-focus-ring-color);outline-offset:1px;opacity:1}:host([data-styled]) .tx-tag__action+.tx-tag__action{margin-inline-start:-2px}:host([data-styled]) .tx-tag__copy--done{opacity:1}\n"]
306
306
  }]
307
307
  }],
308
308
  ctorParameters: () => [],
@@ -1 +1 @@
1
- {"version":3,"file":"tectra-ng-ui-tag.mjs","names":[],"sources":["../../../../packages/ui/tag/src/tag.component.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, DOCUMENT, DestroyRef, ElementRef, booleanAttribute, computed, inject, input, output, signal, viewChild } from '@angular/core';\nimport { TxPassThrough, TxPassThroughOptions, injectPassThrough, injectUnstyled } from '@tectra-ng/core/config';\nimport { injectTranslations } from '@tectra-ng/core/i18n';\nimport { optionalBoolean } from '@tectra-ng/core/utils';\nimport { TxIcon, TxIconName, TxIconRegistry } from '@tectra-ng/icons';\nimport { TectraDeepPartial, TectraTagTokens, toStyleObject } from '@tectra-ng/themes';\nimport { TxTagPart, TxTagSeverity, TxTagSize } from './tag.types';\n\nconst COPIED_FOR = 1500;\n\n@Component({\n selector: 'tx-tag',\n imports: [TxIcon],\n template: `\n @if (icon(); as icon) {\n <span class=\"tx-tag__icon\" aria-hidden=\"true\" [class]=\"passThrough().icon?.class\" [style]=\"passThrough().icon?.style\">\n @if (iconName(); as name) {\n <tx-icon [name]=\"name\" />\n } @else {\n <span [class]=\"icon\"></span>\n }\n </span>\n }\n <span #label class=\"tx-tag__label\" [class]=\"passThrough().label?.class\" [style]=\"passThrough().label?.style\">{{ value() }}<ng-content /></span>\n @if (copyable()) {\n <button\n type=\"button\"\n class=\"tx-tag__action tx-tag__copy\"\n [class.tx-tag__copy--done]=\"isCopied()\"\n [class]=\"passThrough().copy?.class\"\n [style]=\"passThrough().copy?.style\"\n [attr.aria-label]=\"isCopied() ? translations().copied : translations().copy\"\n [title]=\"isCopied() ? translations().copied : translations().copy\"\n (click)=\"copy()\"\n >\n <tx-icon [name]=\"isCopied() ? 'check' : 'copy'\" />\n </button>\n }\n @if (removable()) {\n <button\n type=\"button\"\n class=\"tx-tag__action tx-tag__remove\"\n [class]=\"passThrough().remove?.class\"\n [style]=\"passThrough().remove?.style\"\n [attr.aria-label]=\"removeLabel() ?? translations().remove\"\n [title]=\"removeLabel() ?? translations().remove\"\n (click)=\"remove($event)\"\n (keydown.delete)=\"remove($event)\"\n (keydown.backspace)=\"remove($event)\"\n >\n <tx-icon [name]=\"'times'\" />\n </button>\n }\n `,\n styleUrl: './tag.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n class: 'tx-tag',\n '[class]': 'passThrough().root?.class',\n '[style]': 'hostStyle()',\n '[attr.data-styled]': '!isUnstyled() || null',\n '[attr.data-severity]': 'severity()',\n '[attr.data-size]': 'resolvedSize()',\n '[class.tx-tag--rounded]': 'rounded()',\n },\n})\nexport class TxTag {\n private txIconRegistry = inject(TxIconRegistry);\n private document = inject(DOCUMENT);\n private timer: ReturnType<typeof setTimeout> | null = null;\n\n readonly value = input<string | number | undefined>(undefined);\n readonly severity = input<TxTagSeverity>('primary');\n readonly size = input<TxTagSize>('medium');\n readonly rounded = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly icon = input<TxIconName | (string & {}) | undefined>(undefined);\n readonly copyable = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly removable = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly removeLabel = input<string | undefined>(undefined);\n readonly dt = input<TectraDeepPartial<TectraTagTokens> | undefined>(undefined);\n readonly pt = input<TxPassThrough<TxTagPart, TxTag> | undefined>(undefined);\n readonly ptOptions = input<TxPassThroughOptions | undefined>(undefined);\n readonly unstyled = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n\n readonly copied = output<string>();\n readonly removed = output<Event>();\n\n readonly label = viewChild.required<ElementRef<HTMLElement>>('label');\n\n readonly translations = injectTranslations();\n readonly isUnstyled = injectUnstyled(this.unstyled);\n readonly passThrough = injectPassThrough('tag', this, this.pt, this.ptOptions);\n readonly isCopied = signal(false);\n readonly resolvedSize = computed(() => (this.size() === 'normal' ? 'medium' : this.size()));\n readonly iconName = computed(() => {\n const icon = this.icon();\n return icon && this.txIconRegistry.has(icon) ? icon : null;\n });\n readonly hostStyle = computed(() => ({ ...toStyleObject(this.dt(), '--tx-tag'), ...this.passThrough().root?.style }));\n\n constructor() {\n inject(DestroyRef).onDestroy(() => this.timer && clearTimeout(this.timer));\n }\n\n copy(): void {\n const text = (this.label().nativeElement.textContent ?? '').trim();\n this.document.defaultView?.navigator.clipboard?.writeText(text);\n this.copied.emit(text);\n this.isCopied.set(true);\n if (this.timer) {\n clearTimeout(this.timer);\n }\n this.timer = setTimeout(() => this.isCopied.set(false), COPIED_FOR);\n }\n\n remove(event: Event): void {\n event.preventDefault();\n event.stopPropagation();\n this.removed.emit(event);\n }\n}\n"],"mappings":";;;;;;;AAQA,MAAM,aAAa;AA0DnB,IAAa,QAAb,MAAa,MAAK;CACR,iBAAiB,OAAO,cAAc;CACtC,WAAW,OAAO,QAAQ;CAC1B,QAA8C;CAE7C,QAAQ,MAAmC,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,QAAA,CAAA,+BA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":["../../../../packages/ui/tag/src/tag.component.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, DOCUMENT, DestroyRef, ElementRef, booleanAttribute, computed, inject, input, output, signal, viewChild } from '@angular/core';\nimport { TxPassThrough, TxPassThroughOptions, injectPassThrough, injectUnstyled } from '@tectra-ng/core/config';\nimport { injectTranslations } from '@tectra-ng/core/i18n';\nimport { optionalBoolean } from '@tectra-ng/core/utils';\nimport { TxIcon, TxIconName, TxIconRegistry } from '@tectra-ng/icons';\nimport { TectraDeepPartial, TectraTagTokens, toStyleObject } from '@tectra-ng/themes';\nimport { TxTagPart, TxTagSeverity, TxTagSize } from './tag.types';\n\nconst COPIED_FOR = 1500;\n\n@Component({\n selector: 'tx-tag',\n imports: [TxIcon],\n template: `\n @if (icon(); as icon) {\n <span class=\"tx-tag__icon\" aria-hidden=\"true\" [class]=\"passThrough().icon?.class\" [style]=\"passThrough().icon?.style\">\n @if (iconName(); as name) {\n <tx-icon [name]=\"name\" />\n } @else {\n <span [class]=\"icon\"></span>\n }\n </span>\n }\n <span #label class=\"tx-tag__label\" [class]=\"passThrough().label?.class\" [style]=\"passThrough().label?.style\">{{ value() }}<ng-content /></span>\n @if (copyable()) {\n <button\n type=\"button\"\n class=\"tx-tag__action tx-tag__copy\"\n [class.tx-tag__copy--done]=\"isCopied()\"\n [class]=\"passThrough().copy?.class\"\n [style]=\"passThrough().copy?.style\"\n [attr.aria-label]=\"isCopied() ? translations().copied : translations().copy\"\n [title]=\"isCopied() ? translations().copied : translations().copy\"\n (click)=\"copy()\"\n >\n <tx-icon [name]=\"isCopied() ? 'check' : 'copy'\" />\n </button>\n }\n @if (removable()) {\n <button\n type=\"button\"\n class=\"tx-tag__action tx-tag__remove\"\n [class]=\"passThrough().remove?.class\"\n [style]=\"passThrough().remove?.style\"\n [attr.aria-label]=\"removeLabel() ?? translations().remove\"\n [title]=\"removeLabel() ?? translations().remove\"\n (click)=\"remove($event)\"\n (keydown.delete)=\"remove($event)\"\n (keydown.backspace)=\"remove($event)\"\n >\n <tx-icon [name]=\"'times'\" />\n </button>\n }\n `,\n styleUrl: './tag.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n class: 'tx-tag',\n '[class]': 'passThrough().root?.class',\n '[style]': 'hostStyle()',\n '[attr.data-styled]': '!isUnstyled() || null',\n '[attr.data-severity]': 'severity()',\n '[attr.data-size]': 'resolvedSize()',\n '[class.tx-tag--rounded]': 'rounded()',\n },\n})\nexport class TxTag {\n private txIconRegistry = inject(TxIconRegistry);\n private document = inject(DOCUMENT);\n private timer: ReturnType<typeof setTimeout> | null = null;\n\n readonly value = input<string | number | undefined>(undefined);\n readonly severity = input<TxTagSeverity>('primary');\n readonly size = input<TxTagSize>('medium');\n readonly rounded = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly icon = input<TxIconName | (string & {}) | undefined>(undefined);\n readonly copyable = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly removable = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly removeLabel = input<string | undefined>(undefined);\n readonly dt = input<TectraDeepPartial<TectraTagTokens> | undefined>(undefined);\n readonly pt = input<TxPassThrough<TxTagPart, TxTag> | undefined>(undefined);\n readonly ptOptions = input<TxPassThroughOptions | undefined>(undefined);\n readonly unstyled = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n\n readonly copied = output<string>();\n readonly removed = output<Event>();\n\n readonly label = viewChild.required<ElementRef<HTMLElement>>('label');\n\n readonly translations = injectTranslations();\n readonly isUnstyled = injectUnstyled(this.unstyled);\n readonly passThrough = injectPassThrough('tag', this, this.pt, this.ptOptions);\n readonly isCopied = signal(false);\n readonly resolvedSize = computed(() => (this.size() === 'normal' ? 'medium' : this.size()));\n readonly iconName = computed(() => {\n const icon = this.icon();\n return icon && this.txIconRegistry.has(icon) ? icon : null;\n });\n readonly hostStyle = computed(() => ({ ...toStyleObject(this.dt(), '--tx-tag'), ...this.passThrough().root?.style }));\n\n constructor() {\n inject(DestroyRef).onDestroy(() => this.timer && clearTimeout(this.timer));\n }\n\n copy(): void {\n const text = (this.label().nativeElement.textContent ?? '').trim();\n this.document.defaultView?.navigator.clipboard?.writeText(text);\n this.copied.emit(text);\n this.isCopied.set(true);\n if (this.timer) {\n clearTimeout(this.timer);\n }\n this.timer = setTimeout(() => this.isCopied.set(false), COPIED_FOR);\n }\n\n remove(event: Event): void {\n event.preventDefault();\n event.stopPropagation();\n this.removed.emit(event);\n }\n}\n"],"mappings":";;;;;;;AAQA,MAAM,aAAa;AA0DnB,IAAa,QAAb,MAAa,MAAK;CACR,iBAAiB,OAAO,cAAc;CACtC,WAAW,OAAO,QAAQ;CAC1B,QAA8C;CAE7C,QAAQ,MAAmC,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,QAAA,CAAA,+BAAA,CAAA,CAAA;CACrD,WAAW,MAAqB,WAAU,GAAA,YAAA,CAAA,EAAA,WAAA,WAAA,CAAA,+BAAA,CAAA,CAAA;CAC1C,OAAO,MAAiB,UAAS,GAAA,YAAA,CAAA,EAAA,WAAA,OAAA,CAAA,+BAAA,CAAA,CAAA;CACjC,UAAU,MAAwB,OAAK;EAAA,GAAA,YAAA,EAAA,WAAA,UAAA,+BAAA,CAAA;EAAI,WAAW;CAAgB,CAAA;CACtE,OAAO,MAA8C,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,OAAA,CAAA,+BAAA,CAAA,CAAA;CAC/D,WAAW,MAAwB,OAAK;EAAA,GAAA,YAAA,EAAA,WAAA,WAAA,+BAAA,CAAA;EAAI,WAAW;CAAgB,CAAA;CACvE,YAAY,MAAwB,OAAK;EAAA,GAAA,YAAA,EAAA,WAAA,YAAA,+BAAA,CAAA;EAAI,WAAW;CAAgB,CAAA;CACxE,cAAc,MAA0B,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,cAAA,CAAA,+BAAA,CAAA,CAAA;CAClD,KAAK,MAAsD,QAAU,GAAA,YAAA,CAAA,EAAA,WAAA,KAAA,CAAA,+BAAA,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MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,UAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,QAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA,QAAA;EAAA,CAAA;EAAA,SAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA,SAAA;EAAA,CAAA;EAAA,OAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA,SAAO,EAAA,UAAA,KAAA,CAAA;EAAA,CAAA;CAAA;AAAA,CAAA"}
@@ -321,7 +321,7 @@ var TxToggleSwitch = class TxToggleSwitch extends TxFormControlBase {
321
321
  usesInheritance: true,
322
322
  ngImport: i0,
323
323
  template: "<span class=\"tx-toggle-switch__track\" [class]=\"passThrough().track?.class\" [style]=\"passThrough().track?.style\">\n <input\n #input\n type=\"checkbox\"\n role=\"switch\"\n class=\"tx-toggle-switch__input\"\n [class]=\"passThrough().input?.class\"\n [style]=\"passThrough().input?.style\"\n [id]=\"resolvedId()\"\n [checked]=\"checked()\"\n [disabled]=\"isDisabled()\"\n [required]=\"required()\"\n [attr.aria-checked]=\"checked()\"\n [attr.name]=\"name() ?? null\"\n [attr.tabindex]=\"tabindex() ?? null\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.aria-describedby]=\"description() ? descriptionId : null\"\n [attr.aria-invalid]=\"isInvalid() || null\"\n [attr.aria-readonly]=\"readonly() || null\"\n (click)=\"onInputClick($event)\"\n (change)=\"onInputChange($event)\"\n (blur)=\"onBlur()\"\n />\n <span class=\"tx-toggle-switch__handle\" aria-hidden=\"true\" [class]=\"passThrough().handle?.class\" [style]=\"passThrough().handle?.style\">\n @if (handleTemplate(); as template) {\n <ng-container [ngTemplateOutlet]=\"template.templateRef\" [ngTemplateOutletContext]=\"{ $implicit: checked() }\" />\n } @else if (handleIcon(); as icon) {\n @if (handleIconName(); as name) {\n <tx-icon [name]=\"name\" />\n } @else {\n <span [class]=\"icon\"></span>\n }\n }\n </span>\n</span>\n<span class=\"tx-toggle-switch__text\">\n <label class=\"tx-toggle-switch__label\" [for]=\"resolvedId()\" [class]=\"passThrough().label?.class\" [style]=\"passThrough().label?.style\"\n >{{ label() }}<ng-content\n /></label>\n @if (description()) {\n <span\n class=\"tx-toggle-switch__description\"\n [id]=\"descriptionId\"\n [class]=\"passThrough().description?.class\"\n [style]=\"passThrough().description?.style\"\n >{{ description() }}</span\n >\n }\n</span>\n",
324
- styles: [":host{display:inline-flex;align-items:flex-start;vertical-align:top}:host([data-label-position=start]){flex-direction:row-reverse}:host([data-styled]){--_width: var(--tx-toggle-switch-width);--_height: var(--tx-toggle-switch-height);--_handle: var(--tx-toggle-switch-handle-size);--_icon: var(--tx-toggle-switch-handle-icon-size);--_label-font-size: var(--tx-toggle-switch-label-font-size);gap:var(--tx-toggle-switch-gap);font-family:var(--tx-font-family)}:host([data-styled][data-size=small]){--_width: var(--tx-toggle-switch-sm-width);--_height: var(--tx-toggle-switch-sm-height);--_handle: var(--tx-toggle-switch-sm-handle-size);--_icon: var(--tx-toggle-switch-sm-icon-size);--_label-font-size: var(--tx-toggle-switch-sm-label-font-size)}:host([data-styled][data-size=large]){--_width: var(--tx-toggle-switch-lg-width);--_height: var(--tx-toggle-switch-lg-height);--_handle: var(--tx-toggle-switch-lg-handle-size);--_icon: var(--tx-toggle-switch-lg-icon-size);--_label-font-size: var(--tx-toggle-switch-lg-label-font-size)}.tx-toggle-switch__track{position:relative;display:inline-flex;flex-shrink:0}.tx-toggle-switch__input{position:absolute;inset:0;z-index:1;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}.tx-toggle-switch__input:disabled{cursor:not-allowed}:host([data-styled]) .tx-toggle-switch__track{width:var(--_width);height:var(--_height);margin-top:max(0px,(var(--_label-font-size) * 1.5 - var(--_height)) / 2);border-radius:var(--tx-toggle-switch-border-radius);background:var(--tx-toggle-switch-background);transition:background-color var(--tx-toggle-switch-transition-duration)}:host([data-styled]) .tx-toggle-switch__handle{position:absolute;top:50%;left:var(--tx-toggle-switch-gutter);display:inline-flex;align-items:center;justify-content:center;width:var(--_handle);height:var(--_handle);border-radius:50%;background:var(--tx-toggle-switch-handle-background);box-shadow:var(--tx-toggle-switch-handle-shadow);color:var(--tx-toggle-switch-handle-icon-color);font-size:var(--_icon);transform:translateY(-50%);transition:left var(--tx-toggle-switch-transition-duration) cubic-bezier(.2,0,0,1),background-color var(--tx-toggle-switch-transition-duration),color var(--tx-toggle-switch-transition-duration)}:host([data-styled].tx-toggle-switch--checked) .tx-toggle-switch__track{background:var(--tx-toggle-switch-checked-background)}:host([data-styled].tx-toggle-switch--checked) .tx-toggle-switch__handle{left:calc(100% - var(--_handle) - var(--tx-toggle-switch-gutter));background:var(--tx-toggle-switch-handle-checked-background);color:var(--tx-toggle-switch-handle-checked-icon-color)}:host([data-styled]:not(.tx-toggle-switch--disabled):not(.tx-toggle-switch--readonly)) .tx-toggle-switch__track:hover{background:var(--tx-toggle-switch-hover-background)}:host([data-styled].tx-toggle-switch--checked:not(.tx-toggle-switch--disabled):not(.tx-toggle-switch--readonly)) .tx-toggle-switch__track:hover{background:var(--tx-toggle-switch-checked-hover-background)}:host([data-styled]) .tx-toggle-switch__track:has(.tx-toggle-switch__input:focus-visible){outline:var(--tx-toggle-switch-focus-ring-width) solid var(--tx-toggle-switch-focus-ring-color);outline-offset:var(--tx-toggle-switch-focus-ring-offset)}:host([data-styled].tx-toggle-switch--invalid) .tx-toggle-switch__track{box-shadow:0 0 0 1px var(--tx-toggle-switch-invalid-ring-color)}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__track{background:var(--tx-toggle-switch-disabled-background)}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__handle{background:var(--tx-toggle-switch-handle-disabled-background);box-shadow:none}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__label{color:var(--tx-toggle-switch-disabled-label-color);cursor:not-allowed}:host([data-styled].tx-toggle-switch--disabled.tx-toggle-switch--checked) .tx-toggle-switch__track{background:var(--tx-toggle-switch-disabled-checked-background)}:host(.tx-toggle-switch--readonly) .tx-toggle-switch__input,:host(.tx-toggle-switch--readonly) .tx-toggle-switch__label{cursor:default}.tx-toggle-switch__text{display:flex;flex-direction:column;min-width:0}.tx-toggle-switch__label:empty{display:none}:host([data-styled]) .tx-toggle-switch__label{color:var(--tx-toggle-switch-label-color);font-size:var(--_label-font-size);line-height:1.5;cursor:pointer}:host([data-styled]) .tx-toggle-switch__description{color:var(--tx-toggle-switch-description-color);font-size:var(--tx-toggle-switch-description-font-size);line-height:1.45}@media(prefers-reduced-motion:reduce){:host([data-styled]) .tx-toggle-switch__track,:host([data-styled]) .tx-toggle-switch__handle{transition:none}}\n"],
324
+ styles: [":host{display:inline-flex;align-items:flex-start;vertical-align:top}:host([data-label-position=start]){flex-direction:row-reverse}:host([data-styled]){--_width: var(--tx-toggle-switch-width);--_height: var(--tx-toggle-switch-height);--_handle: var(--tx-toggle-switch-handle-size);--_icon: var(--tx-toggle-switch-handle-icon-size);--_label-font-size: var(--tx-toggle-switch-label-font-size);gap:var(--tx-toggle-switch-gap);font-family:var(--tx-font-family)}:host([data-styled][data-size=small]){--_width: var(--tx-toggle-switch-sm-width);--_height: var(--tx-toggle-switch-sm-height);--_handle: var(--tx-toggle-switch-sm-handle-size);--_icon: var(--tx-toggle-switch-sm-icon-size);--_label-font-size: var(--tx-toggle-switch-sm-label-font-size)}:host([data-styled][data-size=large]){--_width: var(--tx-toggle-switch-lg-width);--_height: var(--tx-toggle-switch-lg-height);--_handle: var(--tx-toggle-switch-lg-handle-size);--_icon: var(--tx-toggle-switch-lg-icon-size);--_label-font-size: var(--tx-toggle-switch-lg-label-font-size)}.tx-toggle-switch__track{position:relative;display:inline-flex;flex-shrink:0}.tx-toggle-switch__input{position:absolute;inset:0;z-index:1;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}.tx-toggle-switch__input:disabled{cursor:not-allowed}:host([data-styled]) .tx-toggle-switch__track{width:var(--_width);height:var(--_height);box-sizing:border-box;margin-top:max(0px,(var(--_label-font-size) * 1.5 - var(--_height)) / 2);border:var(--tx-toggle-switch-border-width) solid var(--tx-toggle-switch-border-color);border-radius:var(--tx-toggle-switch-border-radius);background:var(--tx-toggle-switch-background);transition:background-color var(--tx-toggle-switch-transition-duration),border-color var(--tx-toggle-switch-transition-duration)}:host([data-styled]) .tx-toggle-switch__handle{position:absolute;top:50%;left:var(--tx-toggle-switch-gutter);display:inline-flex;align-items:center;justify-content:center;width:var(--_handle);height:var(--_handle);border-radius:50%;background:var(--tx-toggle-switch-handle-background);box-shadow:var(--tx-toggle-switch-handle-shadow);color:var(--tx-toggle-switch-handle-icon-color);font-size:var(--_icon);transform:translateY(-50%);transition:left var(--tx-toggle-switch-transition-duration) cubic-bezier(.2,0,0,1),background-color var(--tx-toggle-switch-transition-duration),color var(--tx-toggle-switch-transition-duration)}:host([data-styled].tx-toggle-switch--checked) .tx-toggle-switch__track{border-color:var(--tx-toggle-switch-checked-border-color);background:var(--tx-toggle-switch-checked-background)}:host([data-styled].tx-toggle-switch--checked) .tx-toggle-switch__handle{left:calc(100% - var(--_handle) - var(--tx-toggle-switch-gutter));background:var(--tx-toggle-switch-handle-checked-background);color:var(--tx-toggle-switch-handle-checked-icon-color)}:host([data-styled]:not(.tx-toggle-switch--disabled):not(.tx-toggle-switch--readonly)) .tx-toggle-switch__track:hover{border-color:var(--tx-toggle-switch-hover-border-color);background:var(--tx-toggle-switch-hover-background)}:host([data-styled].tx-toggle-switch--checked:not(.tx-toggle-switch--disabled):not(.tx-toggle-switch--readonly)) .tx-toggle-switch__track:hover{border-color:var(--tx-toggle-switch-checked-hover-border-color);background:var(--tx-toggle-switch-checked-hover-background)}:host([data-styled]) .tx-toggle-switch__track:has(.tx-toggle-switch__input:focus-visible){outline:var(--tx-toggle-switch-focus-ring-width) solid var(--tx-toggle-switch-focus-ring-color);outline-offset:var(--tx-toggle-switch-focus-ring-offset)}:host([data-styled].tx-toggle-switch--invalid) .tx-toggle-switch__track{box-shadow:0 0 0 1px var(--tx-toggle-switch-invalid-ring-color)}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__track{background:var(--tx-toggle-switch-disabled-background)}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__handle{background:var(--tx-toggle-switch-handle-disabled-background);box-shadow:none}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__label{color:var(--tx-toggle-switch-disabled-label-color);cursor:not-allowed}:host([data-styled].tx-toggle-switch--disabled.tx-toggle-switch--checked) .tx-toggle-switch__track{background:var(--tx-toggle-switch-disabled-checked-background)}:host(.tx-toggle-switch--readonly) .tx-toggle-switch__input,:host(.tx-toggle-switch--readonly) .tx-toggle-switch__label{cursor:default}.tx-toggle-switch__text{display:flex;flex-direction:column;min-width:0}.tx-toggle-switch__label:empty{display:none}:host([data-styled]) .tx-toggle-switch__label{color:var(--tx-toggle-switch-label-color);font-size:var(--_label-font-size);line-height:1.5;cursor:pointer}:host([data-styled]) .tx-toggle-switch__description{color:var(--tx-toggle-switch-description-color);font-size:var(--tx-toggle-switch-description-font-size);line-height:1.45}@media(prefers-reduced-motion:reduce){:host([data-styled]) .tx-toggle-switch__track,:host([data-styled]) .tx-toggle-switch__handle{transition:none}}\n"],
325
325
  dependencies: [{
326
326
  kind: "directive",
327
327
  type: NgTemplateOutlet,
@@ -369,7 +369,7 @@ i0.ɵɵngDeclareClassMetadata({
369
369
  "[class.tx-toggle-switch--invalid]": "isInvalid()"
370
370
  },
371
371
  template: "<span class=\"tx-toggle-switch__track\" [class]=\"passThrough().track?.class\" [style]=\"passThrough().track?.style\">\n <input\n #input\n type=\"checkbox\"\n role=\"switch\"\n class=\"tx-toggle-switch__input\"\n [class]=\"passThrough().input?.class\"\n [style]=\"passThrough().input?.style\"\n [id]=\"resolvedId()\"\n [checked]=\"checked()\"\n [disabled]=\"isDisabled()\"\n [required]=\"required()\"\n [attr.aria-checked]=\"checked()\"\n [attr.name]=\"name() ?? null\"\n [attr.tabindex]=\"tabindex() ?? null\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.aria-describedby]=\"description() ? descriptionId : null\"\n [attr.aria-invalid]=\"isInvalid() || null\"\n [attr.aria-readonly]=\"readonly() || null\"\n (click)=\"onInputClick($event)\"\n (change)=\"onInputChange($event)\"\n (blur)=\"onBlur()\"\n />\n <span class=\"tx-toggle-switch__handle\" aria-hidden=\"true\" [class]=\"passThrough().handle?.class\" [style]=\"passThrough().handle?.style\">\n @if (handleTemplate(); as template) {\n <ng-container [ngTemplateOutlet]=\"template.templateRef\" [ngTemplateOutletContext]=\"{ $implicit: checked() }\" />\n } @else if (handleIcon(); as icon) {\n @if (handleIconName(); as name) {\n <tx-icon [name]=\"name\" />\n } @else {\n <span [class]=\"icon\"></span>\n }\n }\n </span>\n</span>\n<span class=\"tx-toggle-switch__text\">\n <label class=\"tx-toggle-switch__label\" [for]=\"resolvedId()\" [class]=\"passThrough().label?.class\" [style]=\"passThrough().label?.style\"\n >{{ label() }}<ng-content\n /></label>\n @if (description()) {\n <span\n class=\"tx-toggle-switch__description\"\n [id]=\"descriptionId\"\n [class]=\"passThrough().description?.class\"\n [style]=\"passThrough().description?.style\"\n >{{ description() }}</span\n >\n }\n</span>\n",
372
- styles: [":host{display:inline-flex;align-items:flex-start;vertical-align:top}:host([data-label-position=start]){flex-direction:row-reverse}:host([data-styled]){--_width: var(--tx-toggle-switch-width);--_height: var(--tx-toggle-switch-height);--_handle: var(--tx-toggle-switch-handle-size);--_icon: var(--tx-toggle-switch-handle-icon-size);--_label-font-size: var(--tx-toggle-switch-label-font-size);gap:var(--tx-toggle-switch-gap);font-family:var(--tx-font-family)}:host([data-styled][data-size=small]){--_width: var(--tx-toggle-switch-sm-width);--_height: var(--tx-toggle-switch-sm-height);--_handle: var(--tx-toggle-switch-sm-handle-size);--_icon: var(--tx-toggle-switch-sm-icon-size);--_label-font-size: var(--tx-toggle-switch-sm-label-font-size)}:host([data-styled][data-size=large]){--_width: var(--tx-toggle-switch-lg-width);--_height: var(--tx-toggle-switch-lg-height);--_handle: var(--tx-toggle-switch-lg-handle-size);--_icon: var(--tx-toggle-switch-lg-icon-size);--_label-font-size: var(--tx-toggle-switch-lg-label-font-size)}.tx-toggle-switch__track{position:relative;display:inline-flex;flex-shrink:0}.tx-toggle-switch__input{position:absolute;inset:0;z-index:1;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}.tx-toggle-switch__input:disabled{cursor:not-allowed}:host([data-styled]) .tx-toggle-switch__track{width:var(--_width);height:var(--_height);margin-top:max(0px,(var(--_label-font-size) * 1.5 - var(--_height)) / 2);border-radius:var(--tx-toggle-switch-border-radius);background:var(--tx-toggle-switch-background);transition:background-color var(--tx-toggle-switch-transition-duration)}:host([data-styled]) .tx-toggle-switch__handle{position:absolute;top:50%;left:var(--tx-toggle-switch-gutter);display:inline-flex;align-items:center;justify-content:center;width:var(--_handle);height:var(--_handle);border-radius:50%;background:var(--tx-toggle-switch-handle-background);box-shadow:var(--tx-toggle-switch-handle-shadow);color:var(--tx-toggle-switch-handle-icon-color);font-size:var(--_icon);transform:translateY(-50%);transition:left var(--tx-toggle-switch-transition-duration) cubic-bezier(.2,0,0,1),background-color var(--tx-toggle-switch-transition-duration),color var(--tx-toggle-switch-transition-duration)}:host([data-styled].tx-toggle-switch--checked) .tx-toggle-switch__track{background:var(--tx-toggle-switch-checked-background)}:host([data-styled].tx-toggle-switch--checked) .tx-toggle-switch__handle{left:calc(100% - var(--_handle) - var(--tx-toggle-switch-gutter));background:var(--tx-toggle-switch-handle-checked-background);color:var(--tx-toggle-switch-handle-checked-icon-color)}:host([data-styled]:not(.tx-toggle-switch--disabled):not(.tx-toggle-switch--readonly)) .tx-toggle-switch__track:hover{background:var(--tx-toggle-switch-hover-background)}:host([data-styled].tx-toggle-switch--checked:not(.tx-toggle-switch--disabled):not(.tx-toggle-switch--readonly)) .tx-toggle-switch__track:hover{background:var(--tx-toggle-switch-checked-hover-background)}:host([data-styled]) .tx-toggle-switch__track:has(.tx-toggle-switch__input:focus-visible){outline:var(--tx-toggle-switch-focus-ring-width) solid var(--tx-toggle-switch-focus-ring-color);outline-offset:var(--tx-toggle-switch-focus-ring-offset)}:host([data-styled].tx-toggle-switch--invalid) .tx-toggle-switch__track{box-shadow:0 0 0 1px var(--tx-toggle-switch-invalid-ring-color)}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__track{background:var(--tx-toggle-switch-disabled-background)}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__handle{background:var(--tx-toggle-switch-handle-disabled-background);box-shadow:none}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__label{color:var(--tx-toggle-switch-disabled-label-color);cursor:not-allowed}:host([data-styled].tx-toggle-switch--disabled.tx-toggle-switch--checked) .tx-toggle-switch__track{background:var(--tx-toggle-switch-disabled-checked-background)}:host(.tx-toggle-switch--readonly) .tx-toggle-switch__input,:host(.tx-toggle-switch--readonly) .tx-toggle-switch__label{cursor:default}.tx-toggle-switch__text{display:flex;flex-direction:column;min-width:0}.tx-toggle-switch__label:empty{display:none}:host([data-styled]) .tx-toggle-switch__label{color:var(--tx-toggle-switch-label-color);font-size:var(--_label-font-size);line-height:1.5;cursor:pointer}:host([data-styled]) .tx-toggle-switch__description{color:var(--tx-toggle-switch-description-color);font-size:var(--tx-toggle-switch-description-font-size);line-height:1.45}@media(prefers-reduced-motion:reduce){:host([data-styled]) .tx-toggle-switch__track,:host([data-styled]) .tx-toggle-switch__handle{transition:none}}\n"]
372
+ styles: [":host{display:inline-flex;align-items:flex-start;vertical-align:top}:host([data-label-position=start]){flex-direction:row-reverse}:host([data-styled]){--_width: var(--tx-toggle-switch-width);--_height: var(--tx-toggle-switch-height);--_handle: var(--tx-toggle-switch-handle-size);--_icon: var(--tx-toggle-switch-handle-icon-size);--_label-font-size: var(--tx-toggle-switch-label-font-size);gap:var(--tx-toggle-switch-gap);font-family:var(--tx-font-family)}:host([data-styled][data-size=small]){--_width: var(--tx-toggle-switch-sm-width);--_height: var(--tx-toggle-switch-sm-height);--_handle: var(--tx-toggle-switch-sm-handle-size);--_icon: var(--tx-toggle-switch-sm-icon-size);--_label-font-size: var(--tx-toggle-switch-sm-label-font-size)}:host([data-styled][data-size=large]){--_width: var(--tx-toggle-switch-lg-width);--_height: var(--tx-toggle-switch-lg-height);--_handle: var(--tx-toggle-switch-lg-handle-size);--_icon: var(--tx-toggle-switch-lg-icon-size);--_label-font-size: var(--tx-toggle-switch-lg-label-font-size)}.tx-toggle-switch__track{position:relative;display:inline-flex;flex-shrink:0}.tx-toggle-switch__input{position:absolute;inset:0;z-index:1;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}.tx-toggle-switch__input:disabled{cursor:not-allowed}:host([data-styled]) .tx-toggle-switch__track{width:var(--_width);height:var(--_height);box-sizing:border-box;margin-top:max(0px,(var(--_label-font-size) * 1.5 - var(--_height)) / 2);border:var(--tx-toggle-switch-border-width) solid var(--tx-toggle-switch-border-color);border-radius:var(--tx-toggle-switch-border-radius);background:var(--tx-toggle-switch-background);transition:background-color var(--tx-toggle-switch-transition-duration),border-color var(--tx-toggle-switch-transition-duration)}:host([data-styled]) .tx-toggle-switch__handle{position:absolute;top:50%;left:var(--tx-toggle-switch-gutter);display:inline-flex;align-items:center;justify-content:center;width:var(--_handle);height:var(--_handle);border-radius:50%;background:var(--tx-toggle-switch-handle-background);box-shadow:var(--tx-toggle-switch-handle-shadow);color:var(--tx-toggle-switch-handle-icon-color);font-size:var(--_icon);transform:translateY(-50%);transition:left var(--tx-toggle-switch-transition-duration) cubic-bezier(.2,0,0,1),background-color var(--tx-toggle-switch-transition-duration),color var(--tx-toggle-switch-transition-duration)}:host([data-styled].tx-toggle-switch--checked) .tx-toggle-switch__track{border-color:var(--tx-toggle-switch-checked-border-color);background:var(--tx-toggle-switch-checked-background)}:host([data-styled].tx-toggle-switch--checked) .tx-toggle-switch__handle{left:calc(100% - var(--_handle) - var(--tx-toggle-switch-gutter));background:var(--tx-toggle-switch-handle-checked-background);color:var(--tx-toggle-switch-handle-checked-icon-color)}:host([data-styled]:not(.tx-toggle-switch--disabled):not(.tx-toggle-switch--readonly)) .tx-toggle-switch__track:hover{border-color:var(--tx-toggle-switch-hover-border-color);background:var(--tx-toggle-switch-hover-background)}:host([data-styled].tx-toggle-switch--checked:not(.tx-toggle-switch--disabled):not(.tx-toggle-switch--readonly)) .tx-toggle-switch__track:hover{border-color:var(--tx-toggle-switch-checked-hover-border-color);background:var(--tx-toggle-switch-checked-hover-background)}:host([data-styled]) .tx-toggle-switch__track:has(.tx-toggle-switch__input:focus-visible){outline:var(--tx-toggle-switch-focus-ring-width) solid var(--tx-toggle-switch-focus-ring-color);outline-offset:var(--tx-toggle-switch-focus-ring-offset)}:host([data-styled].tx-toggle-switch--invalid) .tx-toggle-switch__track{box-shadow:0 0 0 1px var(--tx-toggle-switch-invalid-ring-color)}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__track{background:var(--tx-toggle-switch-disabled-background)}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__handle{background:var(--tx-toggle-switch-handle-disabled-background);box-shadow:none}:host([data-styled].tx-toggle-switch--disabled) .tx-toggle-switch__label{color:var(--tx-toggle-switch-disabled-label-color);cursor:not-allowed}:host([data-styled].tx-toggle-switch--disabled.tx-toggle-switch--checked) .tx-toggle-switch__track{background:var(--tx-toggle-switch-disabled-checked-background)}:host(.tx-toggle-switch--readonly) .tx-toggle-switch__input,:host(.tx-toggle-switch--readonly) .tx-toggle-switch__label{cursor:default}.tx-toggle-switch__text{display:flex;flex-direction:column;min-width:0}.tx-toggle-switch__label:empty{display:none}:host([data-styled]) .tx-toggle-switch__label{color:var(--tx-toggle-switch-label-color);font-size:var(--_label-font-size);line-height:1.5;cursor:pointer}:host([data-styled]) .tx-toggle-switch__description{color:var(--tx-toggle-switch-description-color);font-size:var(--tx-toggle-switch-description-font-size);line-height:1.45}@media(prefers-reduced-motion:reduce){:host([data-styled]) .tx-toggle-switch__track,:host([data-styled]) .tx-toggle-switch__handle{transition:none}}\n"]
373
373
  }]
374
374
  }],
375
375
  propDecorators: {
@@ -1 +1 @@
1
- {"version":3,"file":"tectra-ng-ui-toggle-switch.mjs","names":[],"sources":["../../../../packages/ui/toggle-switch/src/toggle-switch-templates.directive.ts","../../../../packages/ui/toggle-switch/src/toggle-switch.component.ts","../../../../packages/ui/toggle-switch/src/toggle-switch.component.html"],"sourcesContent":["import { Directive, TemplateRef, inject } from '@angular/core';\nimport { TxToggleSwitchHandleContext } from './toggle-switch.types';\n\n@Directive({ selector: 'ng-template[txToggleSwitchHandle]' })\nexport class TxToggleSwitchHandleTemplate {\n readonly templateRef = inject<TemplateRef<TxToggleSwitchHandleContext>>(TemplateRef);\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n booleanAttribute,\n computed,\n contentChild,\n forwardRef,\n inject,\n input,\n output,\n viewChild,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { uniqueId } from '@tectra-ng/core/a11y';\nimport { TxPassThrough, TxPassThroughOptions, injectPassThrough, injectUnstyled } from '@tectra-ng/core/config';\nimport { TxFormControlBase, injectFieldInvalid } from '@tectra-ng/core/forms';\nimport { optionalBoolean, optionalNumber } from '@tectra-ng/core/utils';\nimport { TxIcon, TxIconName, TxIconRegistry } from '@tectra-ng/icons';\nimport { TectraDeepPartial, TectraToggleSwitchTokens, toStyleObject } from '@tectra-ng/themes';\nimport { TxToggleSwitchHandleTemplate } from './toggle-switch-templates.directive';\nimport { TxToggleSwitchChangeEvent, TxToggleSwitchLabelPosition, TxToggleSwitchPart, TxToggleSwitchSize } from './toggle-switch.types';\n\n@Component({\n selector: 'tx-toggle-switch',\n imports: [NgTemplateOutlet, TxIcon],\n templateUrl: './toggle-switch.component.html',\n styleUrl: './toggle-switch.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [{ provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => TxToggleSwitch), multi: true }],\n host: {\n class: 'tx-toggle-switch',\n '[class]': 'passThrough().root?.class',\n '[style]': 'hostStyle()',\n '[attr.data-styled]': '!isUnstyled() || null',\n '[attr.data-size]': 'size()',\n '[attr.data-label-position]': 'labelPosition()',\n '[class.tx-toggle-switch--checked]': 'checked()',\n '[class.tx-toggle-switch--disabled]': 'isDisabled()',\n '[class.tx-toggle-switch--readonly]': 'readonly()',\n '[class.tx-toggle-switch--invalid]': 'isInvalid()',\n },\n})\nexport class TxToggleSwitch extends TxFormControlBase<unknown> {\n private txIconRegistry = inject(TxIconRegistry);\n private generatedId = uniqueId('tx-toggle-switch');\n\n readonly label = input<string | undefined>(undefined);\n readonly description = input<string | undefined>(undefined);\n readonly labelPosition = input<TxToggleSwitchLabelPosition>('end');\n readonly trueValue = input<unknown>(true);\n readonly falseValue = input<unknown>(false);\n readonly onIcon = input<TxIconName | (string & {}) | undefined>(undefined);\n readonly offIcon = input<TxIconName | (string & {}) | undefined>(undefined);\n readonly size = input<TxToggleSwitchSize>('medium');\n readonly invalid = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n // eslint-disable-next-line @angular-eslint/no-input-rename\n readonly disabledInput = input<boolean, unknown>(false, { alias: 'disabled', transform: booleanAttribute });\n readonly readonly = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly required = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly name = input<string | undefined>(undefined);\n readonly inputId = input<string | undefined>(undefined);\n readonly ariaLabel = input<string | undefined>(undefined);\n readonly ariaLabelledBy = input<string | undefined>(undefined);\n readonly tabindex = input<number | undefined, unknown>(undefined, { transform: optionalNumber });\n readonly dt = input<TectraDeepPartial<TectraToggleSwitchTokens> | undefined>(undefined);\n readonly pt = input<TxPassThrough<TxToggleSwitchPart, TxToggleSwitch> | undefined>(undefined);\n readonly ptOptions = input<TxPassThroughOptions | undefined>(undefined);\n readonly unstyled = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n\n readonly changed = output<TxToggleSwitchChangeEvent>();\n\n readonly handleTemplate = contentChild(TxToggleSwitchHandleTemplate);\n readonly inputRef = viewChild.required<ElementRef<HTMLInputElement>>('input');\n\n readonly isUnstyled = injectUnstyled(this.unstyled);\n readonly passThrough = injectPassThrough('toggleSwitch', this, this.pt, this.ptOptions);\n readonly isInvalid = injectFieldInvalid(this.invalid);\n\n readonly resolvedId = computed(() => this.inputId() ?? this.generatedId);\n readonly descriptionId = `${this.generatedId}-description`;\n readonly isDisabled = computed(() => this.disabled() || this.disabledInput());\n readonly checked = computed(() => this.value() === this.trueValue());\n readonly handleIcon = computed(() => (this.checked() ? this.onIcon() : this.offIcon()));\n readonly handleIconName = computed(() => {\n const icon = this.handleIcon();\n return icon && this.txIconRegistry.has(icon) ? icon : null;\n });\n readonly hostStyle = computed(() => ({ ...toStyleObject(this.dt(), '--tx-toggle-switch'), ...this.passThrough().root?.style }));\n\n override writeValue(value: unknown): void {\n super.writeValue(value === undefined || value === null ? this.falseValue() : value);\n }\n\n focus(): void {\n this.inputRef().nativeElement.focus();\n }\n\n onInputClick(event: MouseEvent): void {\n if (this.readonly()) {\n event.preventDefault();\n }\n }\n\n onInputChange(event: Event): void {\n const checked = (event.target as HTMLInputElement).checked;\n const value = checked ? this.trueValue() : this.falseValue();\n this.updateValue(value);\n this.changed.emit({ checked, value, originalEvent: event });\n }\n\n onBlur(): void {\n this.markTouched();\n }\n}\n","<span class=\"tx-toggle-switch__track\" [class]=\"passThrough().track?.class\" [style]=\"passThrough().track?.style\">\n <input\n #input\n type=\"checkbox\"\n role=\"switch\"\n class=\"tx-toggle-switch__input\"\n [class]=\"passThrough().input?.class\"\n [style]=\"passThrough().input?.style\"\n [id]=\"resolvedId()\"\n [checked]=\"checked()\"\n [disabled]=\"isDisabled()\"\n [required]=\"required()\"\n [attr.aria-checked]=\"checked()\"\n [attr.name]=\"name() ?? null\"\n [attr.tabindex]=\"tabindex() ?? null\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.aria-describedby]=\"description() ? descriptionId : null\"\n [attr.aria-invalid]=\"isInvalid() || null\"\n [attr.aria-readonly]=\"readonly() || null\"\n (click)=\"onInputClick($event)\"\n (change)=\"onInputChange($event)\"\n (blur)=\"onBlur()\"\n />\n <span class=\"tx-toggle-switch__handle\" aria-hidden=\"true\" [class]=\"passThrough().handle?.class\" [style]=\"passThrough().handle?.style\">\n @if (handleTemplate(); as template) {\n <ng-container [ngTemplateOutlet]=\"template.templateRef\" [ngTemplateOutletContext]=\"{ $implicit: checked() }\" />\n } @else if (handleIcon(); as icon) {\n @if (handleIconName(); as name) {\n <tx-icon [name]=\"name\" />\n } @else {\n <span [class]=\"icon\"></span>\n }\n }\n </span>\n</span>\n<span class=\"tx-toggle-switch__text\">\n <label class=\"tx-toggle-switch__label\" [for]=\"resolvedId()\" [class]=\"passThrough().label?.class\" [style]=\"passThrough().label?.style\"\n >{{ label() }}<ng-content\n /></label>\n @if (description()) {\n <span\n class=\"tx-toggle-switch__description\"\n [id]=\"descriptionId\"\n [class]=\"passThrough().description?.class\"\n [style]=\"passThrough().description?.style\"\n >{{ description() }}</span\n >\n }\n</span>\n"],"mappings":";;;;;;;;;;AAIA,IAAa,+BAAb,MAAa,6BAA4B;CAC9B,cAAc,OAAiD,WAAW;CADxE,OAAA,OAAA,GAAA,mBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,UAAA;EAAA,MAAA;EAA4B,MAAA,CAAA;EAAA,QAAA,GAAA,gBAAA;CAAA,CAAA;CAA5B,OAAA,OAAA,GAAA,qBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,MA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src/toggle-switch-templates.directive.ts","../../../../packages/ui/toggle-switch/src/toggle-switch.component.ts","../../../../packages/ui/toggle-switch/src/toggle-switch.component.html"],"sourcesContent":["import { Directive, TemplateRef, inject } from '@angular/core';\nimport { TxToggleSwitchHandleContext } from './toggle-switch.types';\n\n@Directive({ selector: 'ng-template[txToggleSwitchHandle]' })\nexport class TxToggleSwitchHandleTemplate {\n readonly templateRef = inject<TemplateRef<TxToggleSwitchHandleContext>>(TemplateRef);\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n booleanAttribute,\n computed,\n contentChild,\n forwardRef,\n inject,\n input,\n output,\n viewChild,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { uniqueId } from '@tectra-ng/core/a11y';\nimport { TxPassThrough, TxPassThroughOptions, injectPassThrough, injectUnstyled } from '@tectra-ng/core/config';\nimport { TxFormControlBase, injectFieldInvalid } from '@tectra-ng/core/forms';\nimport { optionalBoolean, optionalNumber } from '@tectra-ng/core/utils';\nimport { TxIcon, TxIconName, TxIconRegistry } from '@tectra-ng/icons';\nimport { TectraDeepPartial, TectraToggleSwitchTokens, toStyleObject } from '@tectra-ng/themes';\nimport { TxToggleSwitchHandleTemplate } from './toggle-switch-templates.directive';\nimport { TxToggleSwitchChangeEvent, TxToggleSwitchLabelPosition, TxToggleSwitchPart, TxToggleSwitchSize } from './toggle-switch.types';\n\n@Component({\n selector: 'tx-toggle-switch',\n imports: [NgTemplateOutlet, TxIcon],\n templateUrl: './toggle-switch.component.html',\n styleUrl: './toggle-switch.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [{ provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => TxToggleSwitch), multi: true }],\n host: {\n class: 'tx-toggle-switch',\n '[class]': 'passThrough().root?.class',\n '[style]': 'hostStyle()',\n '[attr.data-styled]': '!isUnstyled() || null',\n '[attr.data-size]': 'size()',\n '[attr.data-label-position]': 'labelPosition()',\n '[class.tx-toggle-switch--checked]': 'checked()',\n '[class.tx-toggle-switch--disabled]': 'isDisabled()',\n '[class.tx-toggle-switch--readonly]': 'readonly()',\n '[class.tx-toggle-switch--invalid]': 'isInvalid()',\n },\n})\nexport class TxToggleSwitch extends TxFormControlBase<unknown> {\n private txIconRegistry = inject(TxIconRegistry);\n private generatedId = uniqueId('tx-toggle-switch');\n\n readonly label = input<string | undefined>(undefined);\n readonly description = input<string | undefined>(undefined);\n readonly labelPosition = input<TxToggleSwitchLabelPosition>('end');\n readonly trueValue = input<unknown>(true);\n readonly falseValue = input<unknown>(false);\n readonly onIcon = input<TxIconName | (string & {}) | undefined>(undefined);\n readonly offIcon = input<TxIconName | (string & {}) | undefined>(undefined);\n readonly size = input<TxToggleSwitchSize>('medium');\n readonly invalid = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n // eslint-disable-next-line @angular-eslint/no-input-rename\n readonly disabledInput = input<boolean, unknown>(false, { alias: 'disabled', transform: booleanAttribute });\n readonly readonly = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly required = input<boolean, unknown>(false, { transform: booleanAttribute });\n readonly name = input<string | undefined>(undefined);\n readonly inputId = input<string | undefined>(undefined);\n readonly ariaLabel = input<string | undefined>(undefined);\n readonly ariaLabelledBy = input<string | undefined>(undefined);\n readonly tabindex = input<number | undefined, unknown>(undefined, { transform: optionalNumber });\n readonly dt = input<TectraDeepPartial<TectraToggleSwitchTokens> | undefined>(undefined);\n readonly pt = input<TxPassThrough<TxToggleSwitchPart, TxToggleSwitch> | undefined>(undefined);\n readonly ptOptions = input<TxPassThroughOptions | undefined>(undefined);\n readonly unstyled = input<boolean | undefined, unknown>(undefined, { transform: optionalBoolean });\n\n readonly changed = output<TxToggleSwitchChangeEvent>();\n\n readonly handleTemplate = contentChild(TxToggleSwitchHandleTemplate);\n readonly inputRef = viewChild.required<ElementRef<HTMLInputElement>>('input');\n\n readonly isUnstyled = injectUnstyled(this.unstyled);\n readonly passThrough = injectPassThrough('toggleSwitch', this, this.pt, this.ptOptions);\n readonly isInvalid = injectFieldInvalid(this.invalid);\n\n readonly resolvedId = computed(() => this.inputId() ?? this.generatedId);\n readonly descriptionId = `${this.generatedId}-description`;\n readonly isDisabled = computed(() => this.disabled() || this.disabledInput());\n readonly checked = computed(() => this.value() === this.trueValue());\n readonly handleIcon = computed(() => (this.checked() ? this.onIcon() : this.offIcon()));\n readonly handleIconName = computed(() => {\n const icon = this.handleIcon();\n return icon && this.txIconRegistry.has(icon) ? icon : null;\n });\n readonly hostStyle = computed(() => ({ ...toStyleObject(this.dt(), '--tx-toggle-switch'), ...this.passThrough().root?.style }));\n\n override writeValue(value: unknown): void {\n super.writeValue(value === undefined || value === null ? this.falseValue() : value);\n }\n\n focus(): void {\n this.inputRef().nativeElement.focus();\n }\n\n onInputClick(event: MouseEvent): void {\n if (this.readonly()) {\n event.preventDefault();\n }\n }\n\n onInputChange(event: Event): void {\n const checked = (event.target as HTMLInputElement).checked;\n const value = checked ? this.trueValue() : this.falseValue();\n this.updateValue(value);\n this.changed.emit({ checked, value, originalEvent: event });\n }\n\n onBlur(): void {\n this.markTouched();\n }\n}\n","<span class=\"tx-toggle-switch__track\" [class]=\"passThrough().track?.class\" [style]=\"passThrough().track?.style\">\n <input\n #input\n type=\"checkbox\"\n role=\"switch\"\n class=\"tx-toggle-switch__input\"\n [class]=\"passThrough().input?.class\"\n [style]=\"passThrough().input?.style\"\n [id]=\"resolvedId()\"\n [checked]=\"checked()\"\n [disabled]=\"isDisabled()\"\n [required]=\"required()\"\n [attr.aria-checked]=\"checked()\"\n [attr.name]=\"name() ?? null\"\n [attr.tabindex]=\"tabindex() ?? null\"\n [attr.aria-label]=\"ariaLabel() ?? null\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.aria-describedby]=\"description() ? descriptionId : null\"\n [attr.aria-invalid]=\"isInvalid() || null\"\n [attr.aria-readonly]=\"readonly() || null\"\n (click)=\"onInputClick($event)\"\n (change)=\"onInputChange($event)\"\n (blur)=\"onBlur()\"\n />\n <span class=\"tx-toggle-switch__handle\" aria-hidden=\"true\" [class]=\"passThrough().handle?.class\" [style]=\"passThrough().handle?.style\">\n @if (handleTemplate(); as template) {\n <ng-container [ngTemplateOutlet]=\"template.templateRef\" [ngTemplateOutletContext]=\"{ $implicit: checked() }\" />\n } @else if (handleIcon(); as icon) {\n @if (handleIconName(); as name) {\n <tx-icon [name]=\"name\" />\n } @else {\n <span [class]=\"icon\"></span>\n }\n }\n </span>\n</span>\n<span class=\"tx-toggle-switch__text\">\n <label class=\"tx-toggle-switch__label\" [for]=\"resolvedId()\" [class]=\"passThrough().label?.class\" [style]=\"passThrough().label?.style\"\n >{{ label() }}<ng-content\n /></label>\n @if (description()) {\n <span\n class=\"tx-toggle-switch__description\"\n [id]=\"descriptionId\"\n [class]=\"passThrough().description?.class\"\n [style]=\"passThrough().description?.style\"\n >{{ description() }}</span\n >\n }\n</span>\n"],"mappings":";;;;;;;;;;AAIA,IAAa,+BAAb,MAAa,6BAA4B;CAC9B,cAAc,OAAiD,WAAW;CADxE,OAAA,OAAA,GAAA,mBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,UAAA;EAAA,MAAA;EAA4B,MAAA,CAAA;EAAA,QAAA,GAAA,gBAAA;CAAA,CAAA;CAA5B,OAAA,OAAA,GAAA,qBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,MAAA;EAA4B,cAAA;EAAA,UAAA;EAAA,UAAA;CAAA,CAAA;;AAA5B,GAAA,yBAAA;CAAA,YAAA;CAAA,SAAA;CAAA,UAAA;CAAA,MAAA;CAA4B,YAAA,CAAA;EADxC,MAAA;EAAU,MAAA,CAAA,EAAE,UAAU,oCAAmC,CAAE;;;ACyC5D,IAAa,iBAAb,MAAa,uBAAuB,kBAA0B;CACpD,iBAAiB,OAAO,cAAc;CACtC,cAAc,SAAS,kBAAkB;CAExC,QAAQ,MAA0B,QAAU,GAAA,YAAA,CAAA,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AA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,IAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,IAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,WAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,UAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA;IAAA,UAAA;IAAA,OAAA;IAAA,UAAA;GAAA,CAAA;EAAA,CAAA;EAAA,SAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA,SAAA;EAAA,CAAA;EAAA,gBAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CAAA,GAAA,iBAAA,4BAA4B,GAAA,EAAA,UAAA,KAAA,CAAA;EAAA,CAAA;EAAA,UAAA,CAAA;GAAA,MAAA,GAAA;GAAA,MAAA,CACE,SAAO,EAAA,UAAA,KAAA,CAAA;EAAA,CAAA;CAAA;AAAA,CAAA"}
@@ -12,46 +12,7 @@ import { optionalBoolean } from "@tectra-ng/core/utils";
12
12
  import { TxIcon } from "@tectra-ng/icons";
13
13
  import { toStyleObject } from "@tectra-ng/themes";
14
14
  import { foldText } from "@tectra-ng/ui/select";
15
- function walkTree(nodes, visit, parent = null) {
16
- for (const node of nodes) {
17
- visit(node, parent);
18
- walkTree(node.children ?? [], visit, node);
19
- }
20
- }
21
- function findNode(nodes, key) {
22
- let found = null;
23
- walkTree(nodes, (node) => {
24
- if (!found && node.key === key) found = node;
25
- });
26
- return found;
27
- }
28
- function descendantKeys(node) {
29
- const keys = [];
30
- walkTree(node.children ?? [], (child) => {
31
- if (!child.disabled) keys.push(child.key);
32
- });
33
- return keys;
34
- }
35
- function parentMap(nodes) {
36
- const parents = /* @__PURE__ */ new Map();
37
- walkTree(nodes, (node, parent) => parents.set(node.key, parent));
38
- return parents;
39
- }
40
- function normalizeChecked(nodes, keys) {
41
- const checked = new Set(keys);
42
- const settle = (node) => {
43
- const children = (node.children ?? []).filter((child) => !child.disabled);
44
- if (!children.length) return checked.has(node.key);
45
- const all = children.map(settle).every(Boolean);
46
- if (all) checked.add(node.key);
47
- else checked.delete(node.key);
48
- return all;
49
- };
50
- nodes.forEach(settle);
51
- const order = [];
52
- walkTree(nodes, (node) => checked.has(node.key) && order.push(node.key));
53
- return order;
54
- }
15
+ import { descendantKeys, descendantKeys as descendantKeys$1, findNode, findNode as findNode$1, normalizeChecked, normalizeChecked as normalizeChecked$1, parentMap, parentMap as parentMap$1, walkTree } from "@tectra-ng/ui/tree";
55
16
  var TxTreeSelect = class TxTreeSelect extends TxFormControlBase {
56
17
  options = input([], ...ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ []);
57
18
  selectionMode = input("single", ...ngDevMode ? [{ debugName: "selectionMode" }] : /* istanbul ignore next */ []);
@@ -125,8 +86,8 @@ var TxTreeSelect = class TxTreeSelect extends TxFormControlBase {
125
86
  if (Array.isArray(value)) return value;
126
87
  return value === null || value === void 0 || value === "" ? [] : [value];
127
88
  }, ...ngDevMode ? [{ debugName: "selectedKeys" }] : /* istanbul ignore next */ []);
128
- parents = computed(() => parentMap(this.options()), ...ngDevMode ? [{ debugName: "parents" }] : /* istanbul ignore next */ []);
129
- selectedNodes = computed(() => this.selectedKeys().map((key) => findNode(this.options(), key)).filter((node) => !!node).filter((node) => this.selectionMode() !== "checkbox" || !this.parentChecked(node)), ...ngDevMode ? [{ debugName: "selectedNodes" }] : /* istanbul ignore next */ []);
89
+ parents = computed(() => parentMap$1(this.options()), ...ngDevMode ? [{ debugName: "parents" }] : /* istanbul ignore next */ []);
90
+ selectedNodes = computed(() => this.selectedKeys().map((key) => findNode$1(this.options(), key)).filter((node) => !!node).filter((node) => this.selectionMode() !== "checkbox" || !this.parentChecked(node)), ...ngDevMode ? [{ debugName: "selectedNodes" }] : /* istanbul ignore next */ []);
130
91
  branches = computed(() => {
131
92
  const query = foldText(this.query().trim());
132
93
  const expanded = new Set(this.expandedKeys());
@@ -387,7 +348,7 @@ var TxTreeSelect = class TxTreeSelect extends TxFormControlBase {
387
348
  }
388
349
  check(node, checked) {
389
350
  const keys = new Set(this.selectedKeys());
390
- const affected = [node.key, ...descendantKeys(node)];
351
+ const affected = [node.key, ...descendantKeys$1(node)];
391
352
  if (checked) affected.forEach((key) => keys.add(key));
392
353
  else {
393
354
  affected.forEach((key) => keys.delete(key));
@@ -397,7 +358,7 @@ var TxTreeSelect = class TxTreeSelect extends TxFormControlBase {
397
358
  parent = this.parents().get(parent.key) ?? null;
398
359
  }
399
360
  }
400
- this.commit(normalizeChecked(this.options(), [...keys]), node);
361
+ this.commit(normalizeChecked$1(this.options(), [...keys]), node);
401
362
  }
402
363
  commit(value, node) {
403
364
  const next = this.multiple() ? Array.isArray(value) ? value : value ? [value] : [] : value;
@@ -662,7 +623,7 @@ var TxTreeSelect = class TxTreeSelect extends TxFormControlBase {
662
623
  usesInheritance: true,
663
624
  ngImport: i0,
664
625
  template: "<!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -- the combobox inside the box takes focus and keys; the box only widens the click area -->\n<div\n #box\n #origin=\"cdkOverlayOrigin\"\n cdkOverlayOrigin\n class=\"tx-select__box\"\n [class]=\"passThrough().box?.class\"\n [style]=\"passThrough().box?.style\"\n (click)=\"onBoxClick($event)\"\n>\n <button\n #trigger\n type=\"button\"\n role=\"combobox\"\n class=\"tx-select__trigger\"\n aria-haspopup=\"tree\"\n [class]=\"passThrough().trigger?.class\"\n [style]=\"passThrough().trigger?.style\"\n [attr.id]=\"inputId() ?? null\"\n [attr.aria-label]=\"ariaLabel() ?? (ariaLabelledBy() || inputId() ? null : placeholder() || null)\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.aria-expanded]=\"isOpen()\"\n [attr.aria-controls]=\"treeId\"\n [attr.aria-activedescendant]=\"filter() ? null : activeId()\"\n [attr.aria-invalid]=\"isInvalid() || null\"\n [attr.aria-readonly]=\"readonly() || null\"\n [disabled]=\"disabled()\"\n (keydown)=\"onKeydown($event)\"\n >\n @if (!selectedNodes().length) {\n <span class=\"tx-select__value tx-select__value--placeholder\" [class]=\"passThrough().value?.class\" [style]=\"passThrough().value?.style\">{{\n placeholder()\n }}</span>\n } @else if (multiple() && display() === 'chip') {\n <span class=\"tx-select__value tx-select__chips\" [class]=\"passThrough().value?.class\" [style]=\"passThrough().value?.style\">\n @for (node of selectedNodes(); track node.key) {\n <span class=\"tx-select__chip\" [class]=\"passThrough().chip?.class\" [style]=\"passThrough().chip?.style\">\n <span class=\"tx-select__chip-label\">{{ node.label }}</span>\n @if (!disabled() && !readonly()) {\n <span class=\"tx-select__chip-remove\" aria-hidden=\"true\" (click)=\"removeNode(node, $event)\">\n <tx-icon [name]=\"'times'\" />\n </span>\n }\n </span>\n }\n </span>\n } @else {\n <span class=\"tx-select__value\" [class]=\"passThrough().value?.class\" [style]=\"passThrough().value?.style\">{{ commaText() }}</span>\n }\n </button>\n @if (canClear()) {\n <button\n type=\"button\"\n class=\"tx-select__clear\"\n [class]=\"passThrough().clear?.class\"\n [style]=\"passThrough().clear?.style\"\n [attr.aria-label]=\"translations().clear\"\n (click)=\"clear()\"\n >\n <tx-icon [name]=\"'times'\" />\n </button>\n }\n <span class=\"tx-select__dropdown\" aria-hidden=\"true\" [class]=\"passThrough().dropdown?.class\" [style]=\"passThrough().dropdown?.style\">\n <tx-icon class=\"tx-select__chevron\" [name]=\"'chevron-down'\" />\n </span>\n</div>\n\n<ng-template\n cdkConnectedOverlay\n txOverlayAnchor\n [cdkConnectedOverlayOrigin]=\"origin\"\n [cdkConnectedOverlayOpen]=\"isPanelMounted()\"\n [cdkConnectedOverlayPositions]=\"positions()\"\n [cdkConnectedOverlayScrollStrategy]=\"scrollStrategy\"\n [cdkConnectedOverlayViewportMargin]=\"viewportMargin()\"\n [cdkConnectedOverlayDisableClose]=\"true\"\n [cdkConnectedOverlayWidth]=\"panelWidth()\"\n (overlayOutsideClick)=\"onOutsideClick($event)\"\n (attach)=\"onAttach()\"\n (positionChange)=\"onPositionChange($event)\"\n (detach)=\"close()\"\n>\n <div\n #panel\n class=\"tx-select__panel\"\n [attr.data-styled]=\"!isUnstyled() || null\"\n [class]=\"passThrough().panel?.class\"\n [style]=\"panelStyle()\"\n (mousedown)=\"onPanelMousedown($event)\"\n >\n @if (filter()) {\n <div class=\"tx-select__filter\" [class]=\"passThrough().filter?.class\" [style]=\"passThrough().filter?.style\">\n <span class=\"tx-select__filter-field\">\n <input\n #filterInput\n type=\"text\"\n autocomplete=\"off\"\n class=\"tx-select__filter-input\"\n role=\"searchbox\"\n [class]=\"passThrough().filterInput?.class\"\n [style]=\"passThrough().filterInput?.style\"\n [attr.aria-label]=\"filterPlaceholder() ?? translations().searchPlaceholder\"\n [attr.aria-controls]=\"treeId\"\n [attr.aria-activedescendant]=\"activeId()\"\n [placeholder]=\"filterPlaceholder() ?? translations().searchPlaceholder\"\n [value]=\"query()\"\n (input)=\"onFilter($event)\"\n (keydown)=\"onKeydown($event)\"\n />\n <tx-icon class=\"tx-select__filter-icon\" [name]=\"'search'\" />\n </span>\n </div>\n }\n @if (rows().length) {\n <div\n class=\"tx-tree-select__tree\"\n role=\"tree\"\n [id]=\"treeId\"\n [attr.aria-multiselectable]=\"multiple() || null\"\n [attr.aria-label]=\"ariaLabel() || placeholder() || null\"\n [style.max-height]=\"scrollHeight() ?? null\"\n [class]=\"passThrough().tree?.class\"\n [style]=\"passThrough().tree?.style\"\n >\n <ng-container [ngTemplateOutlet]=\"branch\" [ngTemplateOutletContext]=\"{ $implicit: branches() }\" />\n </div>\n } @else {\n <div class=\"tx-tree-select__tree tx-tree-select__tree--empty\" role=\"tree\" [id]=\"treeId\" [attr.aria-label]=\"ariaLabel() || placeholder() || null\">\n <div class=\"tx-select__empty tx-tree-select__empty\" role=\"presentation\" [class]=\"passThrough().empty?.class\" [style]=\"passThrough().empty?.style\">\n {{ emptyText() }}\n </div>\n </div>\n }\n </div>\n</ng-template>\n\n<ng-template #branch let-branches>\n @for (item of branches; track item.row.id) {\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -- tree items use aria-activedescendant: focus and keys stay on the field -->\n <div\n role=\"treeitem\"\n class=\"tx-tree-select__node\"\n [id]=\"item.row.id\"\n [style.--tx-tree-level]=\"item.row.level - 1\"\n [class.tx-tree-select__node--active]=\"item.row.node.key === activeKey()\"\n [class.tx-tree-select__node--selected]=\"item.row.checked && selectionMode() !== 'checkbox'\"\n [class.tx-tree-select__node--disabled]=\"!item.row.selectable\"\n [attr.aria-level]=\"item.row.level\"\n [attr.aria-setsize]=\"item.row.setSize\"\n [attr.aria-posinset]=\"item.row.posInSet\"\n [attr.aria-expanded]=\"item.row.hasChildren ? item.row.expanded : null\"\n [attr.aria-selected]=\"selectionMode() === 'checkbox' ? null : item.row.checked\"\n [attr.aria-checked]=\"selectionMode() === 'checkbox' ? checkState(item.row) : null\"\n [attr.aria-disabled]=\"!item.row.selectable || null\"\n [attr.aria-owns]=\"item.children.length ? item.row.id + '-group' : null\"\n [class]=\"passThrough().node?.class\"\n [style]=\"passThrough().node?.style\"\n (mouseenter)=\"activeKey.set(item.row.node.key)\"\n (click)=\"onRowClick(item.row, $event)\"\n >\n <span\n class=\"tx-tree-select__toggler\"\n aria-hidden=\"true\"\n [class.tx-tree-select__toggler--leaf]=\"!item.row.hasChildren\"\n [class]=\"passThrough().toggler?.class\"\n [style]=\"passThrough().toggler?.style\"\n >\n @if (item.row.hasChildren) {\n <tx-icon class=\"tx-tree-select__chevron\" [class.tx-tree-select__chevron--open]=\"item.row.expanded\" [name]=\"'chevron-right'\" />\n }\n </span>\n @if (selectionMode() === 'checkbox') {\n <span class=\"tx-select__checkbox tx-tree-select__checkbox\" aria-hidden=\"true\">\n @if (item.row.checked) {\n <tx-icon [name]=\"'check'\" />\n } @else if (item.row.partial) {\n <tx-icon [name]=\"'minus'\" />\n }\n </span>\n }\n @if (item.row.node.icon; as icon) {\n <tx-icon class=\"tx-tree-select__icon\" [name]=\"icon\" />\n }\n <span class=\"tx-tree-select__label\">{{ item.row.node.label }}</span>\n </div>\n @if (item.children.length) {\n <div\n role=\"group\"\n class=\"tx-tree-select__children\"\n [id]=\"item.row.id + '-group'\"\n [class.tx-tree-select__children--open]=\"item.row.expanded\"\n [attr.inert]=\"item.row.expanded ? null : ''\"\n >\n <div class=\"tx-tree-select__children-inner\">\n @if (item.row.expanded || mounted().has(item.row.node.key)) {\n <ng-container [ngTemplateOutlet]=\"branch\" [ngTemplateOutletContext]=\"{ $implicit: item.children }\" />\n }\n </div>\n </div>\n }\n }\n</ng-template>\n",
665
- styles: [":host{display:block;width:100%}.tx-select__box{display:flex;align-items:center;cursor:pointer}.tx-select__trigger{flex:1 1 auto;min-width:0}.tx-select__value{display:block;min-height:1lh;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tx-select__dropdown{display:inline-flex}:host(.tx-tree-select--disabled) .tx-select__box{cursor:not-allowed}:host(.tx-tree-select--readonly) .tx-select__box{cursor:default}:host([data-styled]){font-family:var(--tx-font-family)}:host([data-styled]) .tx-select__box{box-sizing:border-box;padding-top:var(--tx-field-padding-top, var(--tx-form-field-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-padding-y));padding-inline:calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-end, 0px));border:1px solid var(--tx-form-field-border-color);border-radius:var(--tx-form-field-border-radius);outline:none;background:var(--tx-form-field-background);box-shadow:var(--tx-form-field-shadow);color:var(--tx-form-field-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height);transition:background-color var(--tx-form-field-transition-duration),border-color var(--tx-form-field-transition-duration),box-shadow var(--tx-form-field-transition-duration);--_px: var(--tx-form-field-padding-x);--_py: var(--tx-form-field-padding-y);gap:var(--tx-select-gap);width:100%;padding-inline-end:0}:host([data-styled])[data-variant=filled] .tx-select__box{background:var(--tx-form-field-filled-background)}:host([data-styled]):not(.tx-tree-select--disabled,.tx-tree-select--readonly) .tx-select__box:not(:has(.tx-select__trigger:focus)):hover{border-color:var(--tx-form-field-hover-border-color)}:host([data-styled])[data-variant=filled]:not(.tx-tree-select--disabled,.tx-tree-select--readonly) .tx-select__box:not(:has(.tx-select__trigger:focus)):hover{background:var(--tx-form-field-filled-hover-background)}:host([data-styled]) .tx-select__box:has(.tx-select__trigger:focus){border-color:var(--tx-form-field-focus-border-color);box-shadow:var(--tx-form-field-focus-ring-shadow)}:host([data-styled])[data-variant=filled] .tx-select__box:has(.tx-select__trigger:focus){background:var(--tx-form-field-filled-focus-background)}:host([data-styled]).tx-tree-select--readonly .tx-select__box,:host([data-styled]).tx-tree-select--readonly .tx-select__box:hover{background:var(--tx-form-field-readonly-background);cursor:default;border-color:var(--tx-form-field-border-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__box{border-color:var(--tx-form-field-invalid-border-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__box:has(.tx-select__trigger:focus){border-color:var(--tx-form-field-invalid-border-color);box-shadow:var(--tx-form-field-invalid-focus-ring-shadow)}:host([data-styled]).tx-tree-select--disabled .tx-select__box{background:var(--tx-form-field-disabled-background);box-shadow:none;color:var(--tx-form-field-disabled-color);cursor:not-allowed}:host([data-styled])[data-size=small] .tx-select__box{padding-top:var(--tx-field-padding-top, var(--tx-form-field-sm-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-sm-padding-y));padding-inline:calc(var(--tx-form-field-sm-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-sm-padding-x) + var(--tx-field-inset-end, 0px));font-size:var(--tx-form-field-sm-font-size);line-height:var(--tx-form-field-sm-line-height);--_px: var(--tx-form-field-sm-padding-x);--_py: var(--tx-form-field-sm-padding-y);padding-inline-end:0}:host([data-styled])[data-size=large] .tx-select__box{padding-top:var(--tx-field-padding-top, var(--tx-form-field-lg-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-lg-padding-y));padding-inline:calc(var(--tx-form-field-lg-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-lg-padding-x) + var(--tx-field-inset-end, 0px));font-size:var(--tx-form-field-lg-font-size);line-height:var(--tx-form-field-lg-line-height);--_px: var(--tx-form-field-lg-padding-x);--_py: var(--tx-form-field-lg-padding-y);padding-inline-end:0}:host([data-styled]) .tx-select__trigger{padding:0;padding-inline-end:var(--_px);border:none;outline:none;background:transparent;color:inherit;font:inherit;line-height:inherit;text-align:left;cursor:inherit}:host([data-styled]) .tx-select__input{cursor:text}:host([data-styled]) .tx-select__input::placeholder{color:var(--tx-form-field-placeholder-color)}:host([data-styled]) .tx-select__input:disabled{cursor:not-allowed}:host([data-styled]).tx-tree-select--invalid .tx-select__input::placeholder{color:var(--tx-form-field-invalid-placeholder-color)}:host([data-styled]) .tx-select__value--placeholder{color:var(--tx-form-field-placeholder-color)}:host([data-styled])[data-variant=filled] .tx-select__value--placeholder,:host([data-styled])[data-variant=filled] .tx-select__input::placeholder{color:var(--tx-form-field-filled-placeholder-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__value--placeholder{color:var(--tx-form-field-invalid-placeholder-color)}:host([data-styled]) .tx-select__clear{display:grid;flex:none;place-items:center;width:var(--tx-select-clear-size);height:var(--tx-select-clear-size);padding:0;border:none;border-radius:var(--tx-radius-full);background:none;color:var(--tx-select-dropdown-color);font-size:var(--tx-select-clear-size);cursor:pointer;transition:color var(--tx-motion-duration) var(--tx-motion-easing)}:host([data-styled]) .tx-select__clear:hover{color:var(--tx-form-field-color)}:host([data-styled]) .tx-select__clear:focus-visible{outline:2px solid var(--tx-focus-ring-color);outline-offset:2px}:host([data-styled]) .tx-select__dropdown{flex:none;align-items:center;align-self:stretch;justify-content:center;width:var(--tx-select-dropdown-width);color:var(--tx-select-dropdown-color)}:host([data-styled]) .tx-select__spinner{animation:tx-select-spin .8s linear infinite}@keyframes tx-select-spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){:host([data-styled]) .tx-select__spinner{animation-duration:2.4s}}.tx-select__panel{box-sizing:border-box;width:100%}.tx-select__panel[data-styled]{overflow:hidden;border:1px solid var(--tx-select-overlay-border-color);border-radius:var(--tx-select-overlay-border-radius);background:var(--tx-select-overlay-background);box-shadow:var(--tx-select-overlay-shadow);color:var(--tx-select-option-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height)}.tx-select__panel[data-styled] .tx-select__header{padding:var(--tx-select-header-padding)}.tx-select__panel[data-styled] .tx-select__footer{padding:var(--tx-select-footer-padding)}.tx-select__panel[data-styled] .tx-select__filter{display:flex;align-items:center;gap:var(--tx-select-filter-gap);padding:var(--tx-select-filter-padding)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-field{position:relative;display:flex;flex:1 1 auto;align-items:center;min-width:0}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input{box-sizing:border-box;padding-top:var(--tx-field-padding-top, var(--tx-form-field-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-padding-y));padding-inline:calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-end, 0px));border:1px solid var(--tx-form-field-border-color);border-radius:var(--tx-form-field-border-radius);outline:none;background:var(--tx-form-field-background);box-shadow:var(--tx-form-field-shadow);color:var(--tx-form-field-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height);transition:background-color var(--tx-form-field-transition-duration),border-color var(--tx-form-field-transition-duration),box-shadow var(--tx-form-field-transition-duration);width:100%;min-width:0;padding-inline-end:calc(var(--tx-form-field-padding-x) + 1em + var(--tx-select-filter-icon-inset))}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input:hover{border-color:var(--tx-form-field-hover-border-color)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input:focus{border-color:var(--tx-form-field-focus-border-color);box-shadow:var(--tx-form-field-focus-ring-shadow)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input::placeholder{color:var(--tx-form-field-placeholder-color)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-icon{position:absolute;right:var(--tx-select-filter-icon-inset);color:var(--tx-form-field-icon-color);pointer-events:none}.tx-select__chips{display:flex;flex-wrap:wrap;align-items:center}.tx-select__chip{display:inline-flex;align-items:center;max-width:100%}.tx-select__chip-label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host([data-styled]) .tx-select__chips{gap:var(--tx-select-chip-gap);margin-block:calc((1lh - var(--tx-select-chip-font-size) * 1.5 - 2 * var(--tx-select-chip-padding-y)) / 2);white-space:normal}:host([data-styled]) .tx-select__chip{gap:var(--tx-select-chip-gap);padding:var(--tx-select-chip-padding-y) var(--tx-select-chip-padding-end) var(--tx-select-chip-padding-y) var(--tx-select-chip-padding-start);border-radius:var(--tx-select-chip-border-radius);background:var(--tx-select-chip-background);color:var(--tx-select-chip-color);font-size:var(--tx-select-chip-font-size);line-height:1.5}:host([data-styled]) .tx-select__chip-remove{transition:color var(--tx-motion-duration) var(--tx-motion-easing);font-size:var(--tx-select-chip-remove-size);display:inline-grid;place-items:center;border-radius:var(--tx-radius-full);color:var(--tx-select-chip-remove-color);cursor:pointer}:host([data-styled]) .tx-select__chip-remove:hover{color:var(--tx-select-chip-remove-hover-color)}.tx-tree-select__tree{overflow-y:auto}.tx-tree-select__node{display:flex;align-items:center;cursor:pointer}.tx-tree-select__node--disabled{cursor:default}.tx-tree-select__toggler{display:inline-grid;flex:none;place-items:center}.tx-tree-select__label{flex:1 1 auto;min-width:0}.tx-tree-select__children{display:grid;grid-template-rows:0fr}.tx-tree-select__children--open{grid-template-rows:1fr}.tx-tree-select__children-inner{min-height:0;overflow:hidden}.tx-tree-select__children:not(.tx-tree-select__children--open)>.tx-tree-select__children-inner{visibility:hidden}.tx-select__panel[data-styled] .tx-tree-select__tree{max-height:var(--tx-select-list-max-height);padding:calc(var(--tx-select-list-padding) - var(--tx-select-list-gap)) var(--tx-select-list-padding) var(--tx-select-list-padding)}.tx-select__panel[data-styled] .tx-tree-select__tree--empty{padding:var(--tx-select-list-padding)}.tx-select__panel[data-styled] .tx-tree-select__children{transition:grid-template-rows calc(var(--tx-motion-duration) * 1.6) cubic-bezier(.2,0,0,1)}.tx-select__panel[data-styled] .tx-tree-select__children:not(.tx-tree-select__children--open)>.tx-tree-select__children-inner{transition:visibility 0s linear calc(var(--tx-motion-duration) * 1.6)}.tx-select__panel[data-styled] .tx-tree-select__node{margin-top:var(--tx-select-list-gap);gap:var(--tx-tree-gap);transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),color var(--tx-motion-duration) var(--tx-motion-easing);padding:var(--tx-select-option-padding);padding-inline-start:calc(var(--tx-tree-level, 0) * var(--tx-tree-indent) + 4px);border-radius:var(--tx-select-option-border-radius);color:var(--tx-select-option-color)}.tx-select__panel[data-styled] .tx-tree-select__node--active{background:var(--tx-select-option-focus-background)}.tx-select__panel[data-styled] .tx-tree-select__node--selected{background:var(--tx-select-option-selected-background);color:var(--tx-select-option-selected-color);font-weight:var(--tx-select-option-selected-font-weight)}.tx-select__panel[data-styled] .tx-tree-select__node--selected.tx-tree-select__node--active{background:var(--tx-select-option-selected-focus-background);color:var(--tx-select-option-selected-focus-color)}.tx-select__panel[data-styled] .tx-tree-select__node--disabled{color:var(--tx-select-option-disabled-color)}.tx-select__panel[data-styled] .tx-tree-select__toggler{transition:background-color var(--tx-motion-duration) var(--tx-motion-easing);width:var(--tx-tree-toggler-size);height:var(--tx-tree-toggler-size);border-radius:var(--tx-radius-sm);color:var(--tx-tree-toggler-color)}.tx-select__panel[data-styled] .tx-tree-select__toggler:not(.tx-tree-select__toggler--leaf):hover{background:var(--tx-tree-toggler-hover-background)}.tx-select__panel[data-styled] .tx-tree-select__icon{color:var(--tx-tree-icon-color)}.tx-select__panel[data-styled] .tx-tree-select__label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tx-select__panel[data-styled] .tx-tree-select__checkbox{transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),border-color var(--tx-motion-duration) var(--tx-motion-easing);display:inline-grid;flex:none;place-items:center;box-sizing:border-box;width:var(--tx-select-checkbox-size);height:var(--tx-select-checkbox-size);border:1px solid var(--tx-select-checkbox-border-color);border-radius:var(--tx-select-checkbox-border-radius);background:var(--tx-select-checkbox-background);color:var(--tx-select-checkbox-checked-color);font-size:var(--tx-select-checkbox-icon-size)}.tx-select__panel[data-styled] .tx-tree-select__node[aria-checked=true] .tx-tree-select__checkbox,.tx-select__panel[data-styled] .tx-tree-select__node[aria-checked=mixed] .tx-tree-select__checkbox{border-color:var(--tx-select-checkbox-checked-background);background:var(--tx-select-checkbox-checked-background)}.tx-select__panel[data-styled] .tx-select__empty{padding:var(--tx-select-empty-padding);color:var(--tx-select-empty-color)}.tx-select__panel[data-styled] .tx-tree-select__chevron{transition:transform var(--tx-motion-duration) var(--tx-motion-easing)}.tx-select__panel[data-styled] .tx-tree-select__chevron--open{transform:rotate(90deg)}@media(prefers-reduced-motion:reduce){.tx-select__panel[data-styled] .tx-tree-select__chevron,.tx-select__panel[data-styled] .tx-tree-select__children,.tx-select__panel[data-styled] .tx-tree-select__children-inner{transition:none}}\n"],
626
+ styles: [":host{display:block;width:100%}.tx-select__box{display:flex;align-items:center;cursor:pointer}.tx-select__trigger{flex:1 1 auto;min-width:0}.tx-select__value{display:block;min-height:1lh;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tx-select__dropdown{display:inline-flex}:host(.tx-tree-select--disabled) .tx-select__box{cursor:not-allowed}:host(.tx-tree-select--readonly) .tx-select__box{cursor:default}:host([data-styled]){font-family:var(--tx-font-family)}:host([data-styled]) .tx-select__box{box-sizing:border-box;padding-top:var(--tx-field-padding-top, var(--tx-form-field-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-padding-y));padding-inline:calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-end, 0px));border:1px solid var(--tx-form-field-border-color);border-radius:var(--tx-form-field-border-radius);outline:none;background-color:var(--tx-form-field-background);box-shadow:var(--tx-form-field-shadow);color:var(--tx-form-field-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height);transition:background-color var(--tx-form-field-transition-duration),border-color var(--tx-form-field-transition-duration),box-shadow var(--tx-form-field-transition-duration);--_px: var(--tx-form-field-padding-x);--_py: var(--tx-form-field-padding-y);gap:var(--tx-select-gap);width:100%;padding-inline-end:0}:host([data-styled])[data-variant=filled] .tx-select__box{background-color:var(--tx-form-field-filled-background)}:host([data-styled]):not(.tx-tree-select--disabled,.tx-tree-select--readonly) .tx-select__box:not(:has(.tx-select__trigger:focus)):hover{border-color:var(--tx-form-field-hover-border-color)}:host([data-styled])[data-variant=filled]:not(.tx-tree-select--disabled,.tx-tree-select--readonly) .tx-select__box:not(:has(.tx-select__trigger:focus)):hover{background-color:var(--tx-form-field-filled-hover-background)}:host([data-styled]) .tx-select__box:has(.tx-select__trigger:focus){border-color:var(--tx-form-field-focus-border-color);outline:var(--tx-form-field-focus-ring-width) var(--tx-form-field-focus-ring-style) var(--tx-form-field-focus-ring-color);outline-offset:var(--tx-form-field-focus-ring-offset);box-shadow:var(--tx-form-field-focus-ring-shadow)}:host([data-styled])[data-variant=filled] .tx-select__box:has(.tx-select__trigger:focus){background-color:var(--tx-form-field-filled-focus-background)}:host([data-styled]).tx-tree-select--readonly .tx-select__box,:host([data-styled]).tx-tree-select--readonly .tx-select__box:hover{background-color:var(--tx-form-field-readonly-background);cursor:default;border-color:var(--tx-form-field-border-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__box{border-color:var(--tx-form-field-invalid-border-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__box:has(.tx-select__trigger:focus){border-color:var(--tx-form-field-invalid-border-color);box-shadow:var(--tx-form-field-invalid-focus-ring-shadow)}:host([data-styled]).tx-tree-select--disabled .tx-select__box{background-color:var(--tx-form-field-disabled-background);box-shadow:none;color:var(--tx-form-field-disabled-color);cursor:not-allowed}:host([data-styled])[data-size=small] .tx-select__box{padding-top:var(--tx-field-padding-top, var(--tx-form-field-sm-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-sm-padding-y));padding-inline:calc(var(--tx-form-field-sm-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-sm-padding-x) + var(--tx-field-inset-end, 0px));font-size:var(--tx-form-field-sm-font-size);line-height:var(--tx-form-field-sm-line-height);--_px: var(--tx-form-field-sm-padding-x);--_py: var(--tx-form-field-sm-padding-y);padding-inline-end:0}:host([data-styled])[data-size=large] .tx-select__box{padding-top:var(--tx-field-padding-top, var(--tx-form-field-lg-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-lg-padding-y));padding-inline:calc(var(--tx-form-field-lg-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-lg-padding-x) + var(--tx-field-inset-end, 0px));font-size:var(--tx-form-field-lg-font-size);line-height:var(--tx-form-field-lg-line-height);--_px: var(--tx-form-field-lg-padding-x);--_py: var(--tx-form-field-lg-padding-y);padding-inline-end:0}:host([data-styled]) .tx-select__trigger{padding:0;padding-inline-end:var(--_px);border:none;outline:none;background:transparent;color:inherit;font:inherit;line-height:inherit;text-align:left;cursor:inherit}:host([data-styled]) .tx-select__input{cursor:text}:host([data-styled]) .tx-select__input::placeholder{color:var(--tx-form-field-placeholder-color)}:host([data-styled]) .tx-select__input:disabled{cursor:not-allowed}:host([data-styled]).tx-tree-select--invalid .tx-select__input::placeholder{color:var(--tx-form-field-invalid-placeholder-color)}:host([data-styled]) .tx-select__value--placeholder{color:var(--tx-form-field-placeholder-color)}:host([data-styled])[data-variant=filled] .tx-select__value--placeholder,:host([data-styled])[data-variant=filled] .tx-select__input::placeholder{color:var(--tx-form-field-filled-placeholder-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__value--placeholder{color:var(--tx-form-field-invalid-placeholder-color)}:host([data-styled]) .tx-select__clear{display:grid;flex:none;place-items:center;width:var(--tx-select-clear-size);height:var(--tx-select-clear-size);padding:0;border:none;border-radius:var(--tx-radius-full);background:none;color:var(--tx-select-dropdown-color);font-size:var(--tx-select-clear-size);cursor:pointer;transition:color var(--tx-motion-duration) var(--tx-motion-easing)}:host([data-styled]) .tx-select__clear:hover{color:var(--tx-form-field-color)}:host([data-styled]) .tx-select__clear:focus-visible{outline:2px solid var(--tx-focus-ring-color);outline-offset:2px}:host([data-styled]) .tx-select__dropdown{flex:none;align-items:center;align-self:stretch;justify-content:center;width:var(--tx-select-dropdown-width);color:var(--tx-select-dropdown-color)}:host([data-styled]) .tx-select__spinner{animation:tx-select-spin .8s linear infinite}@keyframes tx-select-spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){:host([data-styled]) .tx-select__spinner{animation-duration:2.4s}}.tx-select__panel{box-sizing:border-box;width:100%}.tx-select__panel[data-styled]{overflow:hidden;border:1px solid var(--tx-select-overlay-border-color);border-radius:var(--tx-select-overlay-border-radius);background:var(--tx-select-overlay-background);box-shadow:var(--tx-select-overlay-shadow);color:var(--tx-select-option-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height)}.tx-select__panel[data-styled] .tx-select__header{padding:var(--tx-select-header-padding)}.tx-select__panel[data-styled] .tx-select__footer{padding:var(--tx-select-footer-padding)}.tx-select__panel[data-styled] .tx-select__filter{display:flex;align-items:center;gap:var(--tx-select-filter-gap);padding:var(--tx-select-filter-padding)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-field{position:relative;display:flex;flex:1 1 auto;align-items:center;min-width:0}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input{box-sizing:border-box;padding-top:var(--tx-field-padding-top, var(--tx-form-field-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-padding-y));padding-inline:calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-end, 0px));border:1px solid var(--tx-form-field-border-color);border-radius:var(--tx-form-field-border-radius);outline:none;background-color:var(--tx-form-field-background);box-shadow:var(--tx-form-field-shadow);color:var(--tx-form-field-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height);transition:background-color var(--tx-form-field-transition-duration),border-color var(--tx-form-field-transition-duration),box-shadow var(--tx-form-field-transition-duration);width:100%;min-width:0;padding-inline-end:calc(var(--tx-form-field-padding-x) + 1em + var(--tx-select-filter-icon-inset))}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input:hover{border-color:var(--tx-form-field-hover-border-color)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input:focus{border-color:var(--tx-form-field-focus-border-color);outline:var(--tx-form-field-focus-ring-width) var(--tx-form-field-focus-ring-style) var(--tx-form-field-focus-ring-color);outline-offset:var(--tx-form-field-focus-ring-offset);box-shadow:var(--tx-form-field-focus-ring-shadow)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input::placeholder{color:var(--tx-form-field-placeholder-color)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-icon{position:absolute;right:var(--tx-select-filter-icon-inset);color:var(--tx-form-field-icon-color);pointer-events:none}.tx-select__chips{display:flex;flex-wrap:wrap;align-items:center}.tx-select__chip{display:inline-flex;align-items:center;max-width:100%}.tx-select__chip-label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host([data-styled]) .tx-select__chips{gap:var(--tx-select-chip-gap);margin-block:calc((1lh - var(--tx-select-chip-font-size) * 1.5 - 2 * var(--tx-select-chip-padding-y)) / 2);white-space:normal}:host([data-styled]) .tx-select__chip{gap:var(--tx-select-chip-gap);padding:var(--tx-select-chip-padding-y) var(--tx-select-chip-padding-end) var(--tx-select-chip-padding-y) var(--tx-select-chip-padding-start);border-radius:var(--tx-select-chip-border-radius);background:var(--tx-select-chip-background);color:var(--tx-select-chip-color);font-size:var(--tx-select-chip-font-size);line-height:1.5}:host([data-styled]) .tx-select__chip-remove{transition:color var(--tx-motion-duration) var(--tx-motion-easing);font-size:var(--tx-select-chip-remove-size);display:inline-grid;place-items:center;border-radius:var(--tx-radius-full);color:var(--tx-select-chip-remove-color);cursor:pointer}:host([data-styled]) .tx-select__chip-remove:hover{color:var(--tx-select-chip-remove-hover-color)}.tx-tree-select__tree{overflow-y:auto}.tx-tree-select__node{display:flex;align-items:center;cursor:pointer}.tx-tree-select__node--disabled{cursor:default}.tx-tree-select__toggler{display:inline-grid;flex:none;place-items:center}.tx-tree-select__label{flex:1 1 auto;min-width:0}.tx-tree-select__children{display:grid;grid-template-rows:0fr}.tx-tree-select__children--open{grid-template-rows:1fr}.tx-tree-select__children-inner{min-height:0;overflow:hidden}.tx-tree-select__children:not(.tx-tree-select__children--open)>.tx-tree-select__children-inner{visibility:hidden}.tx-select__panel[data-styled] .tx-tree-select__tree{max-height:var(--tx-select-list-max-height);padding:calc(var(--tx-select-list-padding) - var(--tx-select-list-gap)) var(--tx-select-list-padding) var(--tx-select-list-padding)}.tx-select__panel[data-styled] .tx-tree-select__tree--empty{padding:var(--tx-select-list-padding)}.tx-select__panel[data-styled] .tx-tree-select__children{transition:grid-template-rows calc(var(--tx-motion-duration) * 1.6) cubic-bezier(.2,0,0,1)}.tx-select__panel[data-styled] .tx-tree-select__children:not(.tx-tree-select__children--open)>.tx-tree-select__children-inner{transition:visibility 0s linear calc(var(--tx-motion-duration) * 1.6)}.tx-select__panel[data-styled] .tx-tree-select__node{margin-top:var(--tx-select-list-gap);gap:var(--tx-tree-node-gap);transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),color var(--tx-motion-duration) var(--tx-motion-easing);padding:var(--tx-select-option-padding);padding-inline-start:calc(var(--tx-tree-level, 0) * var(--tx-tree-indent) + 4px);border-radius:var(--tx-select-option-border-radius);color:var(--tx-select-option-color)}.tx-select__panel[data-styled] .tx-tree-select__node--active{background:var(--tx-select-option-focus-background)}.tx-select__panel[data-styled] .tx-tree-select__node--selected{background:var(--tx-select-option-selected-background);color:var(--tx-select-option-selected-color);font-weight:var(--tx-select-option-selected-font-weight)}.tx-select__panel[data-styled] .tx-tree-select__node--selected.tx-tree-select__node--active{background:var(--tx-select-option-selected-focus-background);color:var(--tx-select-option-selected-focus-color)}.tx-select__panel[data-styled] .tx-tree-select__node--disabled{color:var(--tx-select-option-disabled-color)}.tx-select__panel[data-styled] .tx-tree-select__toggler{transition:background-color var(--tx-motion-duration) var(--tx-motion-easing);width:var(--tx-tree-node-toggle-button-size);height:var(--tx-tree-node-toggle-button-size);border-radius:var(--tx-tree-node-toggle-button-border-radius);color:var(--tx-tree-node-toggle-button-color)}.tx-select__panel[data-styled] .tx-tree-select__toggler:not(.tx-tree-select__toggler--leaf):hover{background:var(--tx-tree-node-toggle-button-hover-background)}.tx-select__panel[data-styled] .tx-tree-select__icon{color:var(--tx-tree-node-icon-color)}.tx-select__panel[data-styled] .tx-tree-select__label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tx-select__panel[data-styled] .tx-tree-select__checkbox{transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),border-color var(--tx-motion-duration) var(--tx-motion-easing);display:inline-grid;flex:none;place-items:center;box-sizing:border-box;width:var(--tx-select-checkbox-size);height:var(--tx-select-checkbox-size);border:1px solid var(--tx-select-checkbox-border-color);border-radius:var(--tx-select-checkbox-border-radius);background:var(--tx-select-checkbox-background);color:var(--tx-select-checkbox-checked-color);font-size:var(--tx-select-checkbox-icon-size)}.tx-select__panel[data-styled] .tx-tree-select__node[aria-checked=true] .tx-tree-select__checkbox,.tx-select__panel[data-styled] .tx-tree-select__node[aria-checked=mixed] .tx-tree-select__checkbox{border-color:var(--tx-select-checkbox-checked-background);background:var(--tx-select-checkbox-checked-background)}.tx-select__panel[data-styled] .tx-select__empty{padding:var(--tx-select-empty-padding);color:var(--tx-select-empty-color)}.tx-select__panel[data-styled] .tx-tree-select__chevron{transition:transform var(--tx-motion-duration) var(--tx-motion-easing)}.tx-select__panel[data-styled] .tx-tree-select__chevron--open{transform:rotate(90deg)}@media(prefers-reduced-motion:reduce){.tx-select__panel[data-styled] .tx-tree-select__chevron,.tx-select__panel[data-styled] .tx-tree-select__children,.tx-select__panel[data-styled] .tx-tree-select__children-inner{transition:none}}\n"],
666
627
  dependencies: [
667
628
  {
668
629
  kind: "directive",
@@ -772,7 +733,7 @@ i0.ɵɵngDeclareClassMetadata({
772
733
  "[class.tx-tree-select--filled]": "selectedKeys().length > 0"
773
734
  },
774
735
  template: "<!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -- the combobox inside the box takes focus and keys; the box only widens the click area -->\n<div\n #box\n #origin=\"cdkOverlayOrigin\"\n cdkOverlayOrigin\n class=\"tx-select__box\"\n [class]=\"passThrough().box?.class\"\n [style]=\"passThrough().box?.style\"\n (click)=\"onBoxClick($event)\"\n>\n <button\n #trigger\n type=\"button\"\n role=\"combobox\"\n class=\"tx-select__trigger\"\n aria-haspopup=\"tree\"\n [class]=\"passThrough().trigger?.class\"\n [style]=\"passThrough().trigger?.style\"\n [attr.id]=\"inputId() ?? null\"\n [attr.aria-label]=\"ariaLabel() ?? (ariaLabelledBy() || inputId() ? null : placeholder() || null)\"\n [attr.aria-labelledby]=\"ariaLabelledBy() ?? null\"\n [attr.aria-expanded]=\"isOpen()\"\n [attr.aria-controls]=\"treeId\"\n [attr.aria-activedescendant]=\"filter() ? null : activeId()\"\n [attr.aria-invalid]=\"isInvalid() || null\"\n [attr.aria-readonly]=\"readonly() || null\"\n [disabled]=\"disabled()\"\n (keydown)=\"onKeydown($event)\"\n >\n @if (!selectedNodes().length) {\n <span class=\"tx-select__value tx-select__value--placeholder\" [class]=\"passThrough().value?.class\" [style]=\"passThrough().value?.style\">{{\n placeholder()\n }}</span>\n } @else if (multiple() && display() === 'chip') {\n <span class=\"tx-select__value tx-select__chips\" [class]=\"passThrough().value?.class\" [style]=\"passThrough().value?.style\">\n @for (node of selectedNodes(); track node.key) {\n <span class=\"tx-select__chip\" [class]=\"passThrough().chip?.class\" [style]=\"passThrough().chip?.style\">\n <span class=\"tx-select__chip-label\">{{ node.label }}</span>\n @if (!disabled() && !readonly()) {\n <span class=\"tx-select__chip-remove\" aria-hidden=\"true\" (click)=\"removeNode(node, $event)\">\n <tx-icon [name]=\"'times'\" />\n </span>\n }\n </span>\n }\n </span>\n } @else {\n <span class=\"tx-select__value\" [class]=\"passThrough().value?.class\" [style]=\"passThrough().value?.style\">{{ commaText() }}</span>\n }\n </button>\n @if (canClear()) {\n <button\n type=\"button\"\n class=\"tx-select__clear\"\n [class]=\"passThrough().clear?.class\"\n [style]=\"passThrough().clear?.style\"\n [attr.aria-label]=\"translations().clear\"\n (click)=\"clear()\"\n >\n <tx-icon [name]=\"'times'\" />\n </button>\n }\n <span class=\"tx-select__dropdown\" aria-hidden=\"true\" [class]=\"passThrough().dropdown?.class\" [style]=\"passThrough().dropdown?.style\">\n <tx-icon class=\"tx-select__chevron\" [name]=\"'chevron-down'\" />\n </span>\n</div>\n\n<ng-template\n cdkConnectedOverlay\n txOverlayAnchor\n [cdkConnectedOverlayOrigin]=\"origin\"\n [cdkConnectedOverlayOpen]=\"isPanelMounted()\"\n [cdkConnectedOverlayPositions]=\"positions()\"\n [cdkConnectedOverlayScrollStrategy]=\"scrollStrategy\"\n [cdkConnectedOverlayViewportMargin]=\"viewportMargin()\"\n [cdkConnectedOverlayDisableClose]=\"true\"\n [cdkConnectedOverlayWidth]=\"panelWidth()\"\n (overlayOutsideClick)=\"onOutsideClick($event)\"\n (attach)=\"onAttach()\"\n (positionChange)=\"onPositionChange($event)\"\n (detach)=\"close()\"\n>\n <div\n #panel\n class=\"tx-select__panel\"\n [attr.data-styled]=\"!isUnstyled() || null\"\n [class]=\"passThrough().panel?.class\"\n [style]=\"panelStyle()\"\n (mousedown)=\"onPanelMousedown($event)\"\n >\n @if (filter()) {\n <div class=\"tx-select__filter\" [class]=\"passThrough().filter?.class\" [style]=\"passThrough().filter?.style\">\n <span class=\"tx-select__filter-field\">\n <input\n #filterInput\n type=\"text\"\n autocomplete=\"off\"\n class=\"tx-select__filter-input\"\n role=\"searchbox\"\n [class]=\"passThrough().filterInput?.class\"\n [style]=\"passThrough().filterInput?.style\"\n [attr.aria-label]=\"filterPlaceholder() ?? translations().searchPlaceholder\"\n [attr.aria-controls]=\"treeId\"\n [attr.aria-activedescendant]=\"activeId()\"\n [placeholder]=\"filterPlaceholder() ?? translations().searchPlaceholder\"\n [value]=\"query()\"\n (input)=\"onFilter($event)\"\n (keydown)=\"onKeydown($event)\"\n />\n <tx-icon class=\"tx-select__filter-icon\" [name]=\"'search'\" />\n </span>\n </div>\n }\n @if (rows().length) {\n <div\n class=\"tx-tree-select__tree\"\n role=\"tree\"\n [id]=\"treeId\"\n [attr.aria-multiselectable]=\"multiple() || null\"\n [attr.aria-label]=\"ariaLabel() || placeholder() || null\"\n [style.max-height]=\"scrollHeight() ?? null\"\n [class]=\"passThrough().tree?.class\"\n [style]=\"passThrough().tree?.style\"\n >\n <ng-container [ngTemplateOutlet]=\"branch\" [ngTemplateOutletContext]=\"{ $implicit: branches() }\" />\n </div>\n } @else {\n <div class=\"tx-tree-select__tree tx-tree-select__tree--empty\" role=\"tree\" [id]=\"treeId\" [attr.aria-label]=\"ariaLabel() || placeholder() || null\">\n <div class=\"tx-select__empty tx-tree-select__empty\" role=\"presentation\" [class]=\"passThrough().empty?.class\" [style]=\"passThrough().empty?.style\">\n {{ emptyText() }}\n </div>\n </div>\n }\n </div>\n</ng-template>\n\n<ng-template #branch let-branches>\n @for (item of branches; track item.row.id) {\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -- tree items use aria-activedescendant: focus and keys stay on the field -->\n <div\n role=\"treeitem\"\n class=\"tx-tree-select__node\"\n [id]=\"item.row.id\"\n [style.--tx-tree-level]=\"item.row.level - 1\"\n [class.tx-tree-select__node--active]=\"item.row.node.key === activeKey()\"\n [class.tx-tree-select__node--selected]=\"item.row.checked && selectionMode() !== 'checkbox'\"\n [class.tx-tree-select__node--disabled]=\"!item.row.selectable\"\n [attr.aria-level]=\"item.row.level\"\n [attr.aria-setsize]=\"item.row.setSize\"\n [attr.aria-posinset]=\"item.row.posInSet\"\n [attr.aria-expanded]=\"item.row.hasChildren ? item.row.expanded : null\"\n [attr.aria-selected]=\"selectionMode() === 'checkbox' ? null : item.row.checked\"\n [attr.aria-checked]=\"selectionMode() === 'checkbox' ? checkState(item.row) : null\"\n [attr.aria-disabled]=\"!item.row.selectable || null\"\n [attr.aria-owns]=\"item.children.length ? item.row.id + '-group' : null\"\n [class]=\"passThrough().node?.class\"\n [style]=\"passThrough().node?.style\"\n (mouseenter)=\"activeKey.set(item.row.node.key)\"\n (click)=\"onRowClick(item.row, $event)\"\n >\n <span\n class=\"tx-tree-select__toggler\"\n aria-hidden=\"true\"\n [class.tx-tree-select__toggler--leaf]=\"!item.row.hasChildren\"\n [class]=\"passThrough().toggler?.class\"\n [style]=\"passThrough().toggler?.style\"\n >\n @if (item.row.hasChildren) {\n <tx-icon class=\"tx-tree-select__chevron\" [class.tx-tree-select__chevron--open]=\"item.row.expanded\" [name]=\"'chevron-right'\" />\n }\n </span>\n @if (selectionMode() === 'checkbox') {\n <span class=\"tx-select__checkbox tx-tree-select__checkbox\" aria-hidden=\"true\">\n @if (item.row.checked) {\n <tx-icon [name]=\"'check'\" />\n } @else if (item.row.partial) {\n <tx-icon [name]=\"'minus'\" />\n }\n </span>\n }\n @if (item.row.node.icon; as icon) {\n <tx-icon class=\"tx-tree-select__icon\" [name]=\"icon\" />\n }\n <span class=\"tx-tree-select__label\">{{ item.row.node.label }}</span>\n </div>\n @if (item.children.length) {\n <div\n role=\"group\"\n class=\"tx-tree-select__children\"\n [id]=\"item.row.id + '-group'\"\n [class.tx-tree-select__children--open]=\"item.row.expanded\"\n [attr.inert]=\"item.row.expanded ? null : ''\"\n >\n <div class=\"tx-tree-select__children-inner\">\n @if (item.row.expanded || mounted().has(item.row.node.key)) {\n <ng-container [ngTemplateOutlet]=\"branch\" [ngTemplateOutletContext]=\"{ $implicit: item.children }\" />\n }\n </div>\n </div>\n }\n }\n</ng-template>\n",
775
- styles: [":host{display:block;width:100%}.tx-select__box{display:flex;align-items:center;cursor:pointer}.tx-select__trigger{flex:1 1 auto;min-width:0}.tx-select__value{display:block;min-height:1lh;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tx-select__dropdown{display:inline-flex}:host(.tx-tree-select--disabled) .tx-select__box{cursor:not-allowed}:host(.tx-tree-select--readonly) .tx-select__box{cursor:default}:host([data-styled]){font-family:var(--tx-font-family)}:host([data-styled]) .tx-select__box{box-sizing:border-box;padding-top:var(--tx-field-padding-top, var(--tx-form-field-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-padding-y));padding-inline:calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-end, 0px));border:1px solid var(--tx-form-field-border-color);border-radius:var(--tx-form-field-border-radius);outline:none;background:var(--tx-form-field-background);box-shadow:var(--tx-form-field-shadow);color:var(--tx-form-field-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height);transition:background-color var(--tx-form-field-transition-duration),border-color var(--tx-form-field-transition-duration),box-shadow var(--tx-form-field-transition-duration);--_px: var(--tx-form-field-padding-x);--_py: var(--tx-form-field-padding-y);gap:var(--tx-select-gap);width:100%;padding-inline-end:0}:host([data-styled])[data-variant=filled] .tx-select__box{background:var(--tx-form-field-filled-background)}:host([data-styled]):not(.tx-tree-select--disabled,.tx-tree-select--readonly) .tx-select__box:not(:has(.tx-select__trigger:focus)):hover{border-color:var(--tx-form-field-hover-border-color)}:host([data-styled])[data-variant=filled]:not(.tx-tree-select--disabled,.tx-tree-select--readonly) .tx-select__box:not(:has(.tx-select__trigger:focus)):hover{background:var(--tx-form-field-filled-hover-background)}:host([data-styled]) .tx-select__box:has(.tx-select__trigger:focus){border-color:var(--tx-form-field-focus-border-color);box-shadow:var(--tx-form-field-focus-ring-shadow)}:host([data-styled])[data-variant=filled] .tx-select__box:has(.tx-select__trigger:focus){background:var(--tx-form-field-filled-focus-background)}:host([data-styled]).tx-tree-select--readonly .tx-select__box,:host([data-styled]).tx-tree-select--readonly .tx-select__box:hover{background:var(--tx-form-field-readonly-background);cursor:default;border-color:var(--tx-form-field-border-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__box{border-color:var(--tx-form-field-invalid-border-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__box:has(.tx-select__trigger:focus){border-color:var(--tx-form-field-invalid-border-color);box-shadow:var(--tx-form-field-invalid-focus-ring-shadow)}:host([data-styled]).tx-tree-select--disabled .tx-select__box{background:var(--tx-form-field-disabled-background);box-shadow:none;color:var(--tx-form-field-disabled-color);cursor:not-allowed}:host([data-styled])[data-size=small] .tx-select__box{padding-top:var(--tx-field-padding-top, var(--tx-form-field-sm-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-sm-padding-y));padding-inline:calc(var(--tx-form-field-sm-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-sm-padding-x) + var(--tx-field-inset-end, 0px));font-size:var(--tx-form-field-sm-font-size);line-height:var(--tx-form-field-sm-line-height);--_px: var(--tx-form-field-sm-padding-x);--_py: var(--tx-form-field-sm-padding-y);padding-inline-end:0}:host([data-styled])[data-size=large] .tx-select__box{padding-top:var(--tx-field-padding-top, var(--tx-form-field-lg-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-lg-padding-y));padding-inline:calc(var(--tx-form-field-lg-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-lg-padding-x) + var(--tx-field-inset-end, 0px));font-size:var(--tx-form-field-lg-font-size);line-height:var(--tx-form-field-lg-line-height);--_px: var(--tx-form-field-lg-padding-x);--_py: var(--tx-form-field-lg-padding-y);padding-inline-end:0}:host([data-styled]) .tx-select__trigger{padding:0;padding-inline-end:var(--_px);border:none;outline:none;background:transparent;color:inherit;font:inherit;line-height:inherit;text-align:left;cursor:inherit}:host([data-styled]) .tx-select__input{cursor:text}:host([data-styled]) .tx-select__input::placeholder{color:var(--tx-form-field-placeholder-color)}:host([data-styled]) .tx-select__input:disabled{cursor:not-allowed}:host([data-styled]).tx-tree-select--invalid .tx-select__input::placeholder{color:var(--tx-form-field-invalid-placeholder-color)}:host([data-styled]) .tx-select__value--placeholder{color:var(--tx-form-field-placeholder-color)}:host([data-styled])[data-variant=filled] .tx-select__value--placeholder,:host([data-styled])[data-variant=filled] .tx-select__input::placeholder{color:var(--tx-form-field-filled-placeholder-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__value--placeholder{color:var(--tx-form-field-invalid-placeholder-color)}:host([data-styled]) .tx-select__clear{display:grid;flex:none;place-items:center;width:var(--tx-select-clear-size);height:var(--tx-select-clear-size);padding:0;border:none;border-radius:var(--tx-radius-full);background:none;color:var(--tx-select-dropdown-color);font-size:var(--tx-select-clear-size);cursor:pointer;transition:color var(--tx-motion-duration) var(--tx-motion-easing)}:host([data-styled]) .tx-select__clear:hover{color:var(--tx-form-field-color)}:host([data-styled]) .tx-select__clear:focus-visible{outline:2px solid var(--tx-focus-ring-color);outline-offset:2px}:host([data-styled]) .tx-select__dropdown{flex:none;align-items:center;align-self:stretch;justify-content:center;width:var(--tx-select-dropdown-width);color:var(--tx-select-dropdown-color)}:host([data-styled]) .tx-select__spinner{animation:tx-select-spin .8s linear infinite}@keyframes tx-select-spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){:host([data-styled]) .tx-select__spinner{animation-duration:2.4s}}.tx-select__panel{box-sizing:border-box;width:100%}.tx-select__panel[data-styled]{overflow:hidden;border:1px solid var(--tx-select-overlay-border-color);border-radius:var(--tx-select-overlay-border-radius);background:var(--tx-select-overlay-background);box-shadow:var(--tx-select-overlay-shadow);color:var(--tx-select-option-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height)}.tx-select__panel[data-styled] .tx-select__header{padding:var(--tx-select-header-padding)}.tx-select__panel[data-styled] .tx-select__footer{padding:var(--tx-select-footer-padding)}.tx-select__panel[data-styled] .tx-select__filter{display:flex;align-items:center;gap:var(--tx-select-filter-gap);padding:var(--tx-select-filter-padding)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-field{position:relative;display:flex;flex:1 1 auto;align-items:center;min-width:0}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input{box-sizing:border-box;padding-top:var(--tx-field-padding-top, var(--tx-form-field-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-padding-y));padding-inline:calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-end, 0px));border:1px solid var(--tx-form-field-border-color);border-radius:var(--tx-form-field-border-radius);outline:none;background:var(--tx-form-field-background);box-shadow:var(--tx-form-field-shadow);color:var(--tx-form-field-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height);transition:background-color var(--tx-form-field-transition-duration),border-color var(--tx-form-field-transition-duration),box-shadow var(--tx-form-field-transition-duration);width:100%;min-width:0;padding-inline-end:calc(var(--tx-form-field-padding-x) + 1em + var(--tx-select-filter-icon-inset))}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input:hover{border-color:var(--tx-form-field-hover-border-color)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input:focus{border-color:var(--tx-form-field-focus-border-color);box-shadow:var(--tx-form-field-focus-ring-shadow)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input::placeholder{color:var(--tx-form-field-placeholder-color)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-icon{position:absolute;right:var(--tx-select-filter-icon-inset);color:var(--tx-form-field-icon-color);pointer-events:none}.tx-select__chips{display:flex;flex-wrap:wrap;align-items:center}.tx-select__chip{display:inline-flex;align-items:center;max-width:100%}.tx-select__chip-label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host([data-styled]) .tx-select__chips{gap:var(--tx-select-chip-gap);margin-block:calc((1lh - var(--tx-select-chip-font-size) * 1.5 - 2 * var(--tx-select-chip-padding-y)) / 2);white-space:normal}:host([data-styled]) .tx-select__chip{gap:var(--tx-select-chip-gap);padding:var(--tx-select-chip-padding-y) var(--tx-select-chip-padding-end) var(--tx-select-chip-padding-y) var(--tx-select-chip-padding-start);border-radius:var(--tx-select-chip-border-radius);background:var(--tx-select-chip-background);color:var(--tx-select-chip-color);font-size:var(--tx-select-chip-font-size);line-height:1.5}:host([data-styled]) .tx-select__chip-remove{transition:color var(--tx-motion-duration) var(--tx-motion-easing);font-size:var(--tx-select-chip-remove-size);display:inline-grid;place-items:center;border-radius:var(--tx-radius-full);color:var(--tx-select-chip-remove-color);cursor:pointer}:host([data-styled]) .tx-select__chip-remove:hover{color:var(--tx-select-chip-remove-hover-color)}.tx-tree-select__tree{overflow-y:auto}.tx-tree-select__node{display:flex;align-items:center;cursor:pointer}.tx-tree-select__node--disabled{cursor:default}.tx-tree-select__toggler{display:inline-grid;flex:none;place-items:center}.tx-tree-select__label{flex:1 1 auto;min-width:0}.tx-tree-select__children{display:grid;grid-template-rows:0fr}.tx-tree-select__children--open{grid-template-rows:1fr}.tx-tree-select__children-inner{min-height:0;overflow:hidden}.tx-tree-select__children:not(.tx-tree-select__children--open)>.tx-tree-select__children-inner{visibility:hidden}.tx-select__panel[data-styled] .tx-tree-select__tree{max-height:var(--tx-select-list-max-height);padding:calc(var(--tx-select-list-padding) - var(--tx-select-list-gap)) var(--tx-select-list-padding) var(--tx-select-list-padding)}.tx-select__panel[data-styled] .tx-tree-select__tree--empty{padding:var(--tx-select-list-padding)}.tx-select__panel[data-styled] .tx-tree-select__children{transition:grid-template-rows calc(var(--tx-motion-duration) * 1.6) cubic-bezier(.2,0,0,1)}.tx-select__panel[data-styled] .tx-tree-select__children:not(.tx-tree-select__children--open)>.tx-tree-select__children-inner{transition:visibility 0s linear calc(var(--tx-motion-duration) * 1.6)}.tx-select__panel[data-styled] .tx-tree-select__node{margin-top:var(--tx-select-list-gap);gap:var(--tx-tree-gap);transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),color var(--tx-motion-duration) var(--tx-motion-easing);padding:var(--tx-select-option-padding);padding-inline-start:calc(var(--tx-tree-level, 0) * var(--tx-tree-indent) + 4px);border-radius:var(--tx-select-option-border-radius);color:var(--tx-select-option-color)}.tx-select__panel[data-styled] .tx-tree-select__node--active{background:var(--tx-select-option-focus-background)}.tx-select__panel[data-styled] .tx-tree-select__node--selected{background:var(--tx-select-option-selected-background);color:var(--tx-select-option-selected-color);font-weight:var(--tx-select-option-selected-font-weight)}.tx-select__panel[data-styled] .tx-tree-select__node--selected.tx-tree-select__node--active{background:var(--tx-select-option-selected-focus-background);color:var(--tx-select-option-selected-focus-color)}.tx-select__panel[data-styled] .tx-tree-select__node--disabled{color:var(--tx-select-option-disabled-color)}.tx-select__panel[data-styled] .tx-tree-select__toggler{transition:background-color var(--tx-motion-duration) var(--tx-motion-easing);width:var(--tx-tree-toggler-size);height:var(--tx-tree-toggler-size);border-radius:var(--tx-radius-sm);color:var(--tx-tree-toggler-color)}.tx-select__panel[data-styled] .tx-tree-select__toggler:not(.tx-tree-select__toggler--leaf):hover{background:var(--tx-tree-toggler-hover-background)}.tx-select__panel[data-styled] .tx-tree-select__icon{color:var(--tx-tree-icon-color)}.tx-select__panel[data-styled] .tx-tree-select__label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tx-select__panel[data-styled] .tx-tree-select__checkbox{transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),border-color var(--tx-motion-duration) var(--tx-motion-easing);display:inline-grid;flex:none;place-items:center;box-sizing:border-box;width:var(--tx-select-checkbox-size);height:var(--tx-select-checkbox-size);border:1px solid var(--tx-select-checkbox-border-color);border-radius:var(--tx-select-checkbox-border-radius);background:var(--tx-select-checkbox-background);color:var(--tx-select-checkbox-checked-color);font-size:var(--tx-select-checkbox-icon-size)}.tx-select__panel[data-styled] .tx-tree-select__node[aria-checked=true] .tx-tree-select__checkbox,.tx-select__panel[data-styled] .tx-tree-select__node[aria-checked=mixed] .tx-tree-select__checkbox{border-color:var(--tx-select-checkbox-checked-background);background:var(--tx-select-checkbox-checked-background)}.tx-select__panel[data-styled] .tx-select__empty{padding:var(--tx-select-empty-padding);color:var(--tx-select-empty-color)}.tx-select__panel[data-styled] .tx-tree-select__chevron{transition:transform var(--tx-motion-duration) var(--tx-motion-easing)}.tx-select__panel[data-styled] .tx-tree-select__chevron--open{transform:rotate(90deg)}@media(prefers-reduced-motion:reduce){.tx-select__panel[data-styled] .tx-tree-select__chevron,.tx-select__panel[data-styled] .tx-tree-select__children,.tx-select__panel[data-styled] .tx-tree-select__children-inner{transition:none}}\n"]
736
+ styles: [":host{display:block;width:100%}.tx-select__box{display:flex;align-items:center;cursor:pointer}.tx-select__trigger{flex:1 1 auto;min-width:0}.tx-select__value{display:block;min-height:1lh;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tx-select__dropdown{display:inline-flex}:host(.tx-tree-select--disabled) .tx-select__box{cursor:not-allowed}:host(.tx-tree-select--readonly) .tx-select__box{cursor:default}:host([data-styled]){font-family:var(--tx-font-family)}:host([data-styled]) .tx-select__box{box-sizing:border-box;padding-top:var(--tx-field-padding-top, var(--tx-form-field-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-padding-y));padding-inline:calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-end, 0px));border:1px solid var(--tx-form-field-border-color);border-radius:var(--tx-form-field-border-radius);outline:none;background-color:var(--tx-form-field-background);box-shadow:var(--tx-form-field-shadow);color:var(--tx-form-field-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height);transition:background-color var(--tx-form-field-transition-duration),border-color var(--tx-form-field-transition-duration),box-shadow var(--tx-form-field-transition-duration);--_px: var(--tx-form-field-padding-x);--_py: var(--tx-form-field-padding-y);gap:var(--tx-select-gap);width:100%;padding-inline-end:0}:host([data-styled])[data-variant=filled] .tx-select__box{background-color:var(--tx-form-field-filled-background)}:host([data-styled]):not(.tx-tree-select--disabled,.tx-tree-select--readonly) .tx-select__box:not(:has(.tx-select__trigger:focus)):hover{border-color:var(--tx-form-field-hover-border-color)}:host([data-styled])[data-variant=filled]:not(.tx-tree-select--disabled,.tx-tree-select--readonly) .tx-select__box:not(:has(.tx-select__trigger:focus)):hover{background-color:var(--tx-form-field-filled-hover-background)}:host([data-styled]) .tx-select__box:has(.tx-select__trigger:focus){border-color:var(--tx-form-field-focus-border-color);outline:var(--tx-form-field-focus-ring-width) var(--tx-form-field-focus-ring-style) var(--tx-form-field-focus-ring-color);outline-offset:var(--tx-form-field-focus-ring-offset);box-shadow:var(--tx-form-field-focus-ring-shadow)}:host([data-styled])[data-variant=filled] .tx-select__box:has(.tx-select__trigger:focus){background-color:var(--tx-form-field-filled-focus-background)}:host([data-styled]).tx-tree-select--readonly .tx-select__box,:host([data-styled]).tx-tree-select--readonly .tx-select__box:hover{background-color:var(--tx-form-field-readonly-background);cursor:default;border-color:var(--tx-form-field-border-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__box{border-color:var(--tx-form-field-invalid-border-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__box:has(.tx-select__trigger:focus){border-color:var(--tx-form-field-invalid-border-color);box-shadow:var(--tx-form-field-invalid-focus-ring-shadow)}:host([data-styled]).tx-tree-select--disabled .tx-select__box{background-color:var(--tx-form-field-disabled-background);box-shadow:none;color:var(--tx-form-field-disabled-color);cursor:not-allowed}:host([data-styled])[data-size=small] .tx-select__box{padding-top:var(--tx-field-padding-top, var(--tx-form-field-sm-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-sm-padding-y));padding-inline:calc(var(--tx-form-field-sm-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-sm-padding-x) + var(--tx-field-inset-end, 0px));font-size:var(--tx-form-field-sm-font-size);line-height:var(--tx-form-field-sm-line-height);--_px: var(--tx-form-field-sm-padding-x);--_py: var(--tx-form-field-sm-padding-y);padding-inline-end:0}:host([data-styled])[data-size=large] .tx-select__box{padding-top:var(--tx-field-padding-top, var(--tx-form-field-lg-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-lg-padding-y));padding-inline:calc(var(--tx-form-field-lg-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-lg-padding-x) + var(--tx-field-inset-end, 0px));font-size:var(--tx-form-field-lg-font-size);line-height:var(--tx-form-field-lg-line-height);--_px: var(--tx-form-field-lg-padding-x);--_py: var(--tx-form-field-lg-padding-y);padding-inline-end:0}:host([data-styled]) .tx-select__trigger{padding:0;padding-inline-end:var(--_px);border:none;outline:none;background:transparent;color:inherit;font:inherit;line-height:inherit;text-align:left;cursor:inherit}:host([data-styled]) .tx-select__input{cursor:text}:host([data-styled]) .tx-select__input::placeholder{color:var(--tx-form-field-placeholder-color)}:host([data-styled]) .tx-select__input:disabled{cursor:not-allowed}:host([data-styled]).tx-tree-select--invalid .tx-select__input::placeholder{color:var(--tx-form-field-invalid-placeholder-color)}:host([data-styled]) .tx-select__value--placeholder{color:var(--tx-form-field-placeholder-color)}:host([data-styled])[data-variant=filled] .tx-select__value--placeholder,:host([data-styled])[data-variant=filled] .tx-select__input::placeholder{color:var(--tx-form-field-filled-placeholder-color)}:host([data-styled]).tx-tree-select--invalid .tx-select__value--placeholder{color:var(--tx-form-field-invalid-placeholder-color)}:host([data-styled]) .tx-select__clear{display:grid;flex:none;place-items:center;width:var(--tx-select-clear-size);height:var(--tx-select-clear-size);padding:0;border:none;border-radius:var(--tx-radius-full);background:none;color:var(--tx-select-dropdown-color);font-size:var(--tx-select-clear-size);cursor:pointer;transition:color var(--tx-motion-duration) var(--tx-motion-easing)}:host([data-styled]) .tx-select__clear:hover{color:var(--tx-form-field-color)}:host([data-styled]) .tx-select__clear:focus-visible{outline:2px solid var(--tx-focus-ring-color);outline-offset:2px}:host([data-styled]) .tx-select__dropdown{flex:none;align-items:center;align-self:stretch;justify-content:center;width:var(--tx-select-dropdown-width);color:var(--tx-select-dropdown-color)}:host([data-styled]) .tx-select__spinner{animation:tx-select-spin .8s linear infinite}@keyframes tx-select-spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){:host([data-styled]) .tx-select__spinner{animation-duration:2.4s}}.tx-select__panel{box-sizing:border-box;width:100%}.tx-select__panel[data-styled]{overflow:hidden;border:1px solid var(--tx-select-overlay-border-color);border-radius:var(--tx-select-overlay-border-radius);background:var(--tx-select-overlay-background);box-shadow:var(--tx-select-overlay-shadow);color:var(--tx-select-option-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height)}.tx-select__panel[data-styled] .tx-select__header{padding:var(--tx-select-header-padding)}.tx-select__panel[data-styled] .tx-select__footer{padding:var(--tx-select-footer-padding)}.tx-select__panel[data-styled] .tx-select__filter{display:flex;align-items:center;gap:var(--tx-select-filter-gap);padding:var(--tx-select-filter-padding)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-field{position:relative;display:flex;flex:1 1 auto;align-items:center;min-width:0}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input{box-sizing:border-box;padding-top:var(--tx-field-padding-top, var(--tx-form-field-padding-y));padding-bottom:var(--tx-field-padding-bottom, var(--tx-form-field-padding-y));padding-inline:calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-start, 0px)) calc(var(--tx-form-field-padding-x) + var(--tx-field-inset-end, 0px));border:1px solid var(--tx-form-field-border-color);border-radius:var(--tx-form-field-border-radius);outline:none;background-color:var(--tx-form-field-background);box-shadow:var(--tx-form-field-shadow);color:var(--tx-form-field-color);font-family:var(--tx-font-family);font-size:var(--tx-form-field-font-size);line-height:var(--tx-form-field-line-height);transition:background-color var(--tx-form-field-transition-duration),border-color var(--tx-form-field-transition-duration),box-shadow var(--tx-form-field-transition-duration);width:100%;min-width:0;padding-inline-end:calc(var(--tx-form-field-padding-x) + 1em + var(--tx-select-filter-icon-inset))}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input:hover{border-color:var(--tx-form-field-hover-border-color)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input:focus{border-color:var(--tx-form-field-focus-border-color);outline:var(--tx-form-field-focus-ring-width) var(--tx-form-field-focus-ring-style) var(--tx-form-field-focus-ring-color);outline-offset:var(--tx-form-field-focus-ring-offset);box-shadow:var(--tx-form-field-focus-ring-shadow)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-input::placeholder{color:var(--tx-form-field-placeholder-color)}.tx-select__panel[data-styled] .tx-select__filter .tx-select__filter-icon{position:absolute;right:var(--tx-select-filter-icon-inset);color:var(--tx-form-field-icon-color);pointer-events:none}.tx-select__chips{display:flex;flex-wrap:wrap;align-items:center}.tx-select__chip{display:inline-flex;align-items:center;max-width:100%}.tx-select__chip-label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host([data-styled]) .tx-select__chips{gap:var(--tx-select-chip-gap);margin-block:calc((1lh - var(--tx-select-chip-font-size) * 1.5 - 2 * var(--tx-select-chip-padding-y)) / 2);white-space:normal}:host([data-styled]) .tx-select__chip{gap:var(--tx-select-chip-gap);padding:var(--tx-select-chip-padding-y) var(--tx-select-chip-padding-end) var(--tx-select-chip-padding-y) var(--tx-select-chip-padding-start);border-radius:var(--tx-select-chip-border-radius);background:var(--tx-select-chip-background);color:var(--tx-select-chip-color);font-size:var(--tx-select-chip-font-size);line-height:1.5}:host([data-styled]) .tx-select__chip-remove{transition:color var(--tx-motion-duration) var(--tx-motion-easing);font-size:var(--tx-select-chip-remove-size);display:inline-grid;place-items:center;border-radius:var(--tx-radius-full);color:var(--tx-select-chip-remove-color);cursor:pointer}:host([data-styled]) .tx-select__chip-remove:hover{color:var(--tx-select-chip-remove-hover-color)}.tx-tree-select__tree{overflow-y:auto}.tx-tree-select__node{display:flex;align-items:center;cursor:pointer}.tx-tree-select__node--disabled{cursor:default}.tx-tree-select__toggler{display:inline-grid;flex:none;place-items:center}.tx-tree-select__label{flex:1 1 auto;min-width:0}.tx-tree-select__children{display:grid;grid-template-rows:0fr}.tx-tree-select__children--open{grid-template-rows:1fr}.tx-tree-select__children-inner{min-height:0;overflow:hidden}.tx-tree-select__children:not(.tx-tree-select__children--open)>.tx-tree-select__children-inner{visibility:hidden}.tx-select__panel[data-styled] .tx-tree-select__tree{max-height:var(--tx-select-list-max-height);padding:calc(var(--tx-select-list-padding) - var(--tx-select-list-gap)) var(--tx-select-list-padding) var(--tx-select-list-padding)}.tx-select__panel[data-styled] .tx-tree-select__tree--empty{padding:var(--tx-select-list-padding)}.tx-select__panel[data-styled] .tx-tree-select__children{transition:grid-template-rows calc(var(--tx-motion-duration) * 1.6) cubic-bezier(.2,0,0,1)}.tx-select__panel[data-styled] .tx-tree-select__children:not(.tx-tree-select__children--open)>.tx-tree-select__children-inner{transition:visibility 0s linear calc(var(--tx-motion-duration) * 1.6)}.tx-select__panel[data-styled] .tx-tree-select__node{margin-top:var(--tx-select-list-gap);gap:var(--tx-tree-node-gap);transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),color var(--tx-motion-duration) var(--tx-motion-easing);padding:var(--tx-select-option-padding);padding-inline-start:calc(var(--tx-tree-level, 0) * var(--tx-tree-indent) + 4px);border-radius:var(--tx-select-option-border-radius);color:var(--tx-select-option-color)}.tx-select__panel[data-styled] .tx-tree-select__node--active{background:var(--tx-select-option-focus-background)}.tx-select__panel[data-styled] .tx-tree-select__node--selected{background:var(--tx-select-option-selected-background);color:var(--tx-select-option-selected-color);font-weight:var(--tx-select-option-selected-font-weight)}.tx-select__panel[data-styled] .tx-tree-select__node--selected.tx-tree-select__node--active{background:var(--tx-select-option-selected-focus-background);color:var(--tx-select-option-selected-focus-color)}.tx-select__panel[data-styled] .tx-tree-select__node--disabled{color:var(--tx-select-option-disabled-color)}.tx-select__panel[data-styled] .tx-tree-select__toggler{transition:background-color var(--tx-motion-duration) var(--tx-motion-easing);width:var(--tx-tree-node-toggle-button-size);height:var(--tx-tree-node-toggle-button-size);border-radius:var(--tx-tree-node-toggle-button-border-radius);color:var(--tx-tree-node-toggle-button-color)}.tx-select__panel[data-styled] .tx-tree-select__toggler:not(.tx-tree-select__toggler--leaf):hover{background:var(--tx-tree-node-toggle-button-hover-background)}.tx-select__panel[data-styled] .tx-tree-select__icon{color:var(--tx-tree-node-icon-color)}.tx-select__panel[data-styled] .tx-tree-select__label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tx-select__panel[data-styled] .tx-tree-select__checkbox{transition:background-color var(--tx-motion-duration) var(--tx-motion-easing),border-color var(--tx-motion-duration) var(--tx-motion-easing);display:inline-grid;flex:none;place-items:center;box-sizing:border-box;width:var(--tx-select-checkbox-size);height:var(--tx-select-checkbox-size);border:1px solid var(--tx-select-checkbox-border-color);border-radius:var(--tx-select-checkbox-border-radius);background:var(--tx-select-checkbox-background);color:var(--tx-select-checkbox-checked-color);font-size:var(--tx-select-checkbox-icon-size)}.tx-select__panel[data-styled] .tx-tree-select__node[aria-checked=true] .tx-tree-select__checkbox,.tx-select__panel[data-styled] .tx-tree-select__node[aria-checked=mixed] .tx-tree-select__checkbox{border-color:var(--tx-select-checkbox-checked-background);background:var(--tx-select-checkbox-checked-background)}.tx-select__panel[data-styled] .tx-select__empty{padding:var(--tx-select-empty-padding);color:var(--tx-select-empty-color)}.tx-select__panel[data-styled] .tx-tree-select__chevron{transition:transform var(--tx-motion-duration) var(--tx-motion-easing)}.tx-select__panel[data-styled] .tx-tree-select__chevron--open{transform:rotate(90deg)}@media(prefers-reduced-motion:reduce){.tx-select__panel[data-styled] .tx-tree-select__chevron,.tx-select__panel[data-styled] .tx-tree-select__children,.tx-select__panel[data-styled] .tx-tree-select__children-inner{transition:none}}\n"]
776
737
  }]
777
738
  }],
778
739
  propDecorators: {