@radix-ng/primitives 0.50.0 → 1.0.0-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (207) hide show
  1. package/collection/README.md +1 -0
  2. package/fesm2022/radix-ng-primitives-accordion.mjs +134 -66
  3. package/fesm2022/radix-ng-primitives-accordion.mjs.map +1 -1
  4. package/fesm2022/radix-ng-primitives-alert-dialog.mjs +224 -132
  5. package/fesm2022/radix-ng-primitives-alert-dialog.mjs.map +1 -1
  6. package/fesm2022/radix-ng-primitives-arrow.mjs +26 -10
  7. package/fesm2022/radix-ng-primitives-arrow.mjs.map +1 -1
  8. package/fesm2022/radix-ng-primitives-aspect-ratio.mjs +6 -6
  9. package/fesm2022/radix-ng-primitives-aspect-ratio.mjs.map +1 -1
  10. package/fesm2022/radix-ng-primitives-avatar.mjs +68 -75
  11. package/fesm2022/radix-ng-primitives-avatar.mjs.map +1 -1
  12. package/fesm2022/radix-ng-primitives-button.mjs +123 -0
  13. package/fesm2022/radix-ng-primitives-button.mjs.map +1 -0
  14. package/fesm2022/radix-ng-primitives-calendar.mjs +104 -103
  15. package/fesm2022/radix-ng-primitives-calendar.mjs.map +1 -1
  16. package/fesm2022/radix-ng-primitives-checkbox.mjs +414 -80
  17. package/fesm2022/radix-ng-primitives-checkbox.mjs.map +1 -1
  18. package/fesm2022/radix-ng-primitives-collapsible.mjs +193 -92
  19. package/fesm2022/radix-ng-primitives-collapsible.mjs.map +1 -1
  20. package/fesm2022/radix-ng-primitives-collection.mjs +72 -0
  21. package/fesm2022/radix-ng-primitives-collection.mjs.map +1 -0
  22. package/fesm2022/radix-ng-primitives-config.mjs +5 -5
  23. package/fesm2022/radix-ng-primitives-config.mjs.map +1 -1
  24. package/fesm2022/radix-ng-primitives-context-menu.mjs +143 -427
  25. package/fesm2022/radix-ng-primitives-context-menu.mjs.map +1 -1
  26. package/fesm2022/radix-ng-primitives-core.mjs +757 -757
  27. package/fesm2022/radix-ng-primitives-core.mjs.map +1 -1
  28. package/fesm2022/radix-ng-primitives-cropper.mjs +55 -53
  29. package/fesm2022/radix-ng-primitives-cropper.mjs.map +1 -1
  30. package/fesm2022/radix-ng-primitives-date-field.mjs +93 -86
  31. package/fesm2022/radix-ng-primitives-date-field.mjs.map +1 -1
  32. package/fesm2022/radix-ng-primitives-dialog.mjs +658 -330
  33. package/fesm2022/radix-ng-primitives-dialog.mjs.map +1 -1
  34. package/fesm2022/radix-ng-primitives-dismissable-layer.mjs +98 -76
  35. package/fesm2022/radix-ng-primitives-dismissable-layer.mjs.map +1 -1
  36. package/fesm2022/radix-ng-primitives-drawer.mjs +1059 -0
  37. package/fesm2022/radix-ng-primitives-drawer.mjs.map +1 -0
  38. package/fesm2022/radix-ng-primitives-editable.mjs +20 -20
  39. package/fesm2022/radix-ng-primitives-editable.mjs.map +1 -1
  40. package/fesm2022/radix-ng-primitives-field.mjs +363 -0
  41. package/fesm2022/radix-ng-primitives-field.mjs.map +1 -0
  42. package/fesm2022/radix-ng-primitives-fieldset.mjs +79 -0
  43. package/fesm2022/radix-ng-primitives-fieldset.mjs.map +1 -0
  44. package/fesm2022/radix-ng-primitives-focus-guards.mjs +3 -3
  45. package/fesm2022/radix-ng-primitives-focus-guards.mjs.map +1 -1
  46. package/fesm2022/radix-ng-primitives-focus-scope.mjs +29 -14
  47. package/fesm2022/radix-ng-primitives-focus-scope.mjs.map +1 -1
  48. package/fesm2022/radix-ng-primitives-input.mjs +172 -0
  49. package/fesm2022/radix-ng-primitives-input.mjs.map +1 -0
  50. package/fesm2022/radix-ng-primitives-label.mjs +11 -11
  51. package/fesm2022/radix-ng-primitives-label.mjs.map +1 -1
  52. package/fesm2022/radix-ng-primitives-menu.mjs +1484 -353
  53. package/fesm2022/radix-ng-primitives-menu.mjs.map +1 -1
  54. package/fesm2022/radix-ng-primitives-menubar.mjs +290 -162
  55. package/fesm2022/radix-ng-primitives-menubar.mjs.map +1 -1
  56. package/fesm2022/radix-ng-primitives-meter.mjs +271 -0
  57. package/fesm2022/radix-ng-primitives-meter.mjs.map +1 -0
  58. package/fesm2022/radix-ng-primitives-navigation-menu.mjs +1060 -1553
  59. package/fesm2022/radix-ng-primitives-navigation-menu.mjs.map +1 -1
  60. package/fesm2022/radix-ng-primitives-number-field.mjs +1102 -366
  61. package/fesm2022/radix-ng-primitives-number-field.mjs.map +1 -1
  62. package/fesm2022/radix-ng-primitives-pagination.mjs +51 -51
  63. package/fesm2022/radix-ng-primitives-pagination.mjs.map +1 -1
  64. package/fesm2022/radix-ng-primitives-popover.mjs +980 -995
  65. package/fesm2022/radix-ng-primitives-popover.mjs.map +1 -1
  66. package/fesm2022/radix-ng-primitives-popper.mjs +137 -82
  67. package/fesm2022/radix-ng-primitives-popper.mjs.map +1 -1
  68. package/fesm2022/radix-ng-primitives-portal.mjs +40 -16
  69. package/fesm2022/radix-ng-primitives-portal.mjs.map +1 -1
  70. package/fesm2022/radix-ng-primitives-presence.mjs +134 -246
  71. package/fesm2022/radix-ng-primitives-presence.mjs.map +1 -1
  72. package/fesm2022/radix-ng-primitives-preview-card.mjs +997 -0
  73. package/fesm2022/radix-ng-primitives-preview-card.mjs.map +1 -0
  74. package/fesm2022/radix-ng-primitives-progress.mjs +231 -92
  75. package/fesm2022/radix-ng-primitives-progress.mjs.map +1 -1
  76. package/fesm2022/radix-ng-primitives-radio.mjs +211 -70
  77. package/fesm2022/radix-ng-primitives-radio.mjs.map +1 -1
  78. package/fesm2022/radix-ng-primitives-roving-focus.mjs +127 -77
  79. package/fesm2022/radix-ng-primitives-roving-focus.mjs.map +1 -1
  80. package/fesm2022/radix-ng-primitives-select.mjs +791 -511
  81. package/fesm2022/radix-ng-primitives-select.mjs.map +1 -1
  82. package/fesm2022/radix-ng-primitives-separator.mjs +16 -45
  83. package/fesm2022/radix-ng-primitives-separator.mjs.map +1 -1
  84. package/fesm2022/radix-ng-primitives-slider.mjs +976 -720
  85. package/fesm2022/radix-ng-primitives-slider.mjs.map +1 -1
  86. package/fesm2022/radix-ng-primitives-stepper.mjs +69 -71
  87. package/fesm2022/radix-ng-primitives-stepper.mjs.map +1 -1
  88. package/fesm2022/radix-ng-primitives-switch.mjs +128 -124
  89. package/fesm2022/radix-ng-primitives-switch.mjs.map +1 -1
  90. package/fesm2022/radix-ng-primitives-tabs.mjs +388 -115
  91. package/fesm2022/radix-ng-primitives-tabs.mjs.map +1 -1
  92. package/fesm2022/radix-ng-primitives-time-field.mjs +111 -117
  93. package/fesm2022/radix-ng-primitives-time-field.mjs.map +1 -1
  94. package/fesm2022/radix-ng-primitives-toggle-group.mjs +122 -248
  95. package/fesm2022/radix-ng-primitives-toggle-group.mjs.map +1 -1
  96. package/fesm2022/radix-ng-primitives-toggle.mjs +99 -62
  97. package/fesm2022/radix-ng-primitives-toggle.mjs.map +1 -1
  98. package/fesm2022/radix-ng-primitives-toolbar.mjs +307 -94
  99. package/fesm2022/radix-ng-primitives-toolbar.mjs.map +1 -1
  100. package/fesm2022/radix-ng-primitives-tooltip.mjs +690 -1079
  101. package/fesm2022/radix-ng-primitives-tooltip.mjs.map +1 -1
  102. package/fesm2022/radix-ng-primitives-visually-hidden.mjs +46 -87
  103. package/fesm2022/radix-ng-primitives-visually-hidden.mjs.map +1 -1
  104. package/fesm2022/radix-ng-primitives.mjs.map +1 -1
  105. package/meter/README.md +3 -0
  106. package/navigation-menu/README.md +2 -1
  107. package/package.json +85 -63
  108. package/portal/README.md +2 -0
  109. package/preview-card/README.md +3 -0
  110. package/schematics/collection.json +1 -0
  111. package/schematics/ng-add/index.d.ts +3 -2
  112. package/schematics/ng-add/index.js +62 -31
  113. package/schematics/ng-add/index.js.map +1 -1
  114. package/schematics/ng-add/package-config.d.ts +4 -2
  115. package/schematics/ng-add/package-config.js +10 -2
  116. package/schematics/ng-add/package-config.js.map +1 -1
  117. package/schematics/ng-add/schema.d.ts +3 -0
  118. package/schematics/ng-add/schema.js +3 -0
  119. package/schematics/ng-add/schema.js.map +1 -0
  120. package/schematics/ng-add/schema.json +14 -0
  121. package/select/README.md +2 -0
  122. package/{accordion/index.d.ts → types/radix-ng-primitives-accordion.d.ts} +102 -67
  123. package/types/radix-ng-primitives-alert-dialog.d.ts +114 -0
  124. package/{arrow/index.d.ts → types/radix-ng-primitives-arrow.d.ts} +1 -1
  125. package/{aspect-ratio/index.d.ts → types/radix-ng-primitives-aspect-ratio.d.ts} +1 -1
  126. package/{avatar/index.d.ts → types/radix-ng-primitives-avatar.d.ts} +7 -11
  127. package/types/radix-ng-primitives-button.d.ts +73 -0
  128. package/{calendar/index.d.ts → types/radix-ng-primitives-calendar.d.ts} +2 -3
  129. package/types/radix-ng-primitives-checkbox.d.ts +337 -0
  130. package/types/radix-ng-primitives-collapsible.d.ts +159 -0
  131. package/types/radix-ng-primitives-collection.d.ts +44 -0
  132. package/{config/index.d.ts → types/radix-ng-primitives-config.d.ts} +1 -1
  133. package/types/radix-ng-primitives-context-menu.d.ts +73 -0
  134. package/{core/index.d.ts → types/radix-ng-primitives-core.d.ts} +311 -236
  135. package/{cropper/index.d.ts → types/radix-ng-primitives-cropper.d.ts} +6 -5
  136. package/{date-field/index.d.ts → types/radix-ng-primitives-date-field.d.ts} +42 -27
  137. package/types/radix-ng-primitives-dialog.d.ts +323 -0
  138. package/{dismissable-layer/index.d.ts → types/radix-ng-primitives-dismissable-layer.d.ts} +15 -7
  139. package/types/radix-ng-primitives-drawer.d.ts +448 -0
  140. package/{editable/index.d.ts → types/radix-ng-primitives-editable.d.ts} +1 -1
  141. package/types/radix-ng-primitives-field.d.ts +373 -0
  142. package/types/radix-ng-primitives-fieldset.d.ts +48 -0
  143. package/{focus-scope/index.d.ts → types/radix-ng-primitives-focus-scope.d.ts} +13 -5
  144. package/types/radix-ng-primitives-input.d.ts +87 -0
  145. package/{label/index.d.ts → types/radix-ng-primitives-label.d.ts} +0 -1
  146. package/types/radix-ng-primitives-menu.d.ts +612 -0
  147. package/types/radix-ng-primitives-menubar.d.ts +66 -0
  148. package/types/radix-ng-primitives-meter.d.ts +193 -0
  149. package/types/radix-ng-primitives-navigation-menu.d.ts +488 -0
  150. package/types/radix-ng-primitives-number-field.d.ts +464 -0
  151. package/{pagination/index.d.ts → types/radix-ng-primitives-pagination.d.ts} +2 -2
  152. package/types/radix-ng-primitives-popover.d.ts +416 -0
  153. package/{popper/index.d.ts → types/radix-ng-primitives-popper.d.ts} +50 -9
  154. package/types/radix-ng-primitives-portal.d.ts +30 -0
  155. package/types/radix-ng-primitives-presence.d.ts +55 -0
  156. package/types/radix-ng-primitives-preview-card.d.ts +359 -0
  157. package/types/radix-ng-primitives-progress.d.ts +206 -0
  158. package/{radio/index.d.ts → types/radix-ng-primitives-radio.d.ts} +56 -26
  159. package/{roving-focus/index.d.ts → types/radix-ng-primitives-roving-focus.d.ts} +38 -27
  160. package/types/radix-ng-primitives-select.d.ts +512 -0
  161. package/types/radix-ng-primitives-separator.d.ts +38 -0
  162. package/types/radix-ng-primitives-slider.d.ts +377 -0
  163. package/{stepper/index.d.ts → types/radix-ng-primitives-stepper.d.ts} +21 -22
  164. package/types/radix-ng-primitives-switch.d.ts +121 -0
  165. package/types/radix-ng-primitives-tabs.d.ts +247 -0
  166. package/{time-field/index.d.ts → types/radix-ng-primitives-time-field.d.ts} +46 -31
  167. package/types/radix-ng-primitives-toggle-group.d.ts +116 -0
  168. package/types/radix-ng-primitives-toggle.d.ts +65 -0
  169. package/types/radix-ng-primitives-toolbar.d.ts +180 -0
  170. package/types/radix-ng-primitives-tooltip.d.ts +395 -0
  171. package/{visually-hidden/index.d.ts → types/radix-ng-primitives-visually-hidden.d.ts} +19 -19
  172. package/alert-dialog/index.d.ts +0 -57
  173. package/checkbox/index.d.ts +0 -164
  174. package/collapsible/index.d.ts +0 -85
  175. package/context-menu/index.d.ts +0 -129
  176. package/dialog/index.d.ts +0 -205
  177. package/dropdown-menu/README.md +0 -1
  178. package/dropdown-menu/index.d.ts +0 -171
  179. package/fesm2022/radix-ng-primitives-dropdown-menu.mjs +0 -583
  180. package/fesm2022/radix-ng-primitives-dropdown-menu.mjs.map +0 -1
  181. package/fesm2022/radix-ng-primitives-hover-card.mjs +0 -1246
  182. package/fesm2022/radix-ng-primitives-hover-card.mjs.map +0 -1
  183. package/fesm2022/radix-ng-primitives-tooltip2.mjs +0 -740
  184. package/fesm2022/radix-ng-primitives-tooltip2.mjs.map +0 -1
  185. package/hover-card/README.md +0 -3
  186. package/hover-card/index.d.ts +0 -472
  187. package/menu/index.d.ts +0 -139
  188. package/menubar/index.d.ts +0 -56
  189. package/navigation-menu/index.d.ts +0 -405
  190. package/number-field/index.d.ts +0 -203
  191. package/popover/index.d.ts +0 -403
  192. package/portal/index.d.ts +0 -22
  193. package/presence/index.d.ts +0 -103
  194. package/progress/index.d.ts +0 -79
  195. package/select/index.d.ts +0 -214
  196. package/separator/index.d.ts +0 -63
  197. package/slider/index.d.ts +0 -263
  198. package/switch/index.d.ts +0 -105
  199. package/tabs/index.d.ts +0 -112
  200. package/toggle/index.d.ts +0 -75
  201. package/toggle-group/index.d.ts +0 -194
  202. package/toolbar/index.d.ts +0 -55
  203. package/tooltip/index.d.ts +0 -433
  204. package/tooltip2/README.md +0 -3
  205. package/tooltip2/index.d.ts +0 -325
  206. /package/{focus-guards/index.d.ts → types/radix-ng-primitives-focus-guards.d.ts} +0 -0
  207. /package/{index.d.ts → types/radix-ng-primitives.d.ts} +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"radix-ng-primitives-progress.mjs","sources":["../tmp-esm2022/progress/src/progress-root.directive.js","../tmp-esm2022/progress/src/progress-indicator.directive.js","../tmp-esm2022/progress/index.js","../tmp-esm2022/progress/radix-ng-primitives-progress.js"],"sourcesContent":["import { computed, Directive, effect, inject, InjectionToken, input, model } from '@angular/core';\nimport { isNullish, isNumber, provideToken } from '@radix-ng/primitives/core';\nimport * as i0 from \"@angular/core\";\nexport const RdxProgressToken = new InjectionToken('RdxProgressDirective');\n/**\n * Injects the current instance of RdxProgressRootDirective.\n * @returns The instance of RdxProgressRootDirective.\n */\nexport function injectProgress() {\n return inject(RdxProgressToken);\n}\nconst MIN_PERCENT = 0;\nconst DEFAULT_MAX = 100;\n/**\n * Directive to manage progress bar state and attributes.\n *\n * This directive provides a way to create a progress bar with customizable value and max attributes.\n * It handles aria attributes for accessibility and provides different states like 'indeterminate', 'complete', and 'loading'.\n *\n * @group Components\n */\nexport class RdxProgressRootDirective {\n constructor() {\n /**\n * The current value of the progress bar.\n * @group Props\n * @defaultValue 0\n */\n this.value = model(MIN_PERCENT, ...(ngDevMode ? [{ debugName: \"value\" }] : []));\n /**\n * The maximum value of the progress bar.\n * @defaultValue 100\n * @group Props\n */\n this.max = model(DEFAULT_MAX, ...(ngDevMode ? [{ debugName: \"max\" }] : []));\n /**\n * Function to generate the value label.\n * @group Props\n */\n this.valueLabel = input((value, max) => this.defaultGetValueLabel(value, max), ...(ngDevMode ? [{ debugName: \"valueLabel\" }] : []));\n this.label = computed(() => this.valueLabel()(this.value(), this.max()), ...(ngDevMode ? [{ debugName: \"label\" }] : []));\n this.progressState = computed(() => {\n if (isNullish(this.value())) {\n return 'indeterminate';\n }\n if (this.value() === this.max()) {\n return 'complete';\n }\n return 'loading';\n }, ...(ngDevMode ? [{ debugName: \"progressState\" }] : []));\n effect(() => {\n const correctedValue = this.validateValue(this.value(), this.max());\n if (correctedValue != null && correctedValue !== this.value()) {\n this.value.set(correctedValue);\n }\n });\n effect(() => {\n const correctedMax = this.validateMax(this.max());\n if (correctedMax !== this.max()) {\n this.max.set(correctedMax);\n }\n });\n }\n validateValue(value, max) {\n const isValidValueError = isNullish(value) || (isNumber(value) && !Number.isNaN(value) && value <= max && value >= 0);\n if (isValidValueError)\n return value;\n console.error(`Invalid prop \\`value\\` of value \\`${value}\\` supplied to \\`ProgressRoot\\`. The \\`value\\` prop must be:\n - a positive number\n - less than the value passed to \\`max\\` (or ${DEFAULT_MAX} if no \\`max\\` prop is set)\n - \\`null\\` or \\`undefined\\` if the progress is indeterminate.\n\nDefaulting to \\`null\\`.`);\n return null;\n }\n validateMax(max) {\n const isValidMaxError = isNumber(max) && !Number.isNaN(max) && max > 0;\n if (isValidMaxError)\n return max;\n console.error(`Invalid prop \\`max\\` of value \\`${max}\\` supplied to \\`ProgressRoot\\`. Only numbers greater than 0 are valid max values. Defaulting to \\`${DEFAULT_MAX}\\`.`);\n return DEFAULT_MAX;\n }\n defaultGetValueLabel(value, max) {\n return `${Math.round((value / max) * 100)}%`;\n }\n static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"20.3.3\", ngImport: i0, type: RdxProgressRootDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }\n static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: \"17.1.0\", version: \"20.3.3\", type: RdxProgressRootDirective, isStandalone: true, selector: \"[rdxProgressRoot]\", inputs: { value: { classPropertyName: \"value\", publicName: \"value\", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: \"max\", publicName: \"max\", isSignal: true, isRequired: false, transformFunction: null }, valueLabel: { classPropertyName: \"valueLabel\", publicName: \"valueLabel\", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: \"valueChange\", max: \"maxChange\" }, host: { attributes: { \"role\": \"progressbar\", \"tabindex\": \"-1\" }, properties: { \"attr.aria-valuemax\": \"max()\", \"attr.aria-valuemin\": \"0\", \"attr.aria-valuenow\": \"value()\", \"attr.aria-valuetext\": \"label()\", \"attr.aria-label\": \"label()\", \"attr.data-state\": \"progressState()\", \"attr.data-value\": \"value() ?? undefined\", \"attr.data-max\": \"max()\" } }, providers: [provideToken(RdxProgressToken, RdxProgressRootDirective)], exportAs: [\"rdxProgressRoot\"], ngImport: i0 }); }\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"20.3.3\", ngImport: i0, type: RdxProgressRootDirective, decorators: [{\n type: Directive,\n args: [{\n selector: '[rdxProgressRoot]',\n exportAs: 'rdxProgressRoot',\n providers: [provideToken(RdxProgressToken, RdxProgressRootDirective)],\n host: {\n role: 'progressbar',\n '[attr.aria-valuemax]': 'max()',\n '[attr.aria-valuemin]': '0',\n '[attr.aria-valuenow]': 'value()',\n '[attr.aria-valuetext]': 'label()',\n '[attr.aria-label]': 'label()',\n '[attr.data-state]': 'progressState()',\n '[attr.data-value]': 'value() ?? undefined',\n '[attr.data-max]': 'max()',\n // set tab index to -1 so screen readers will read the aria-label\n // Note: there is a known issue with JAWS that does not read progressbar aria labels on FireFox\n tabindex: '-1'\n }\n }]\n }], ctorParameters: () => [] });\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHJvZ3Jlc3Mtcm9vdC5kaXJlY3RpdmUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy9wcmltaXRpdmVzL3Byb2dyZXNzL3NyYy9wcm9ncmVzcy1yb290LmRpcmVjdGl2ZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsUUFBUSxFQUFFLFNBQVMsRUFBRSxNQUFNLEVBQUUsTUFBTSxFQUFFLGNBQWMsRUFBRSxLQUFLLEVBQUUsS0FBSyxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBQ2xHLE9BQU8sRUFBRSxTQUFTLEVBQUUsUUFBUSxFQUFFLFlBQVksRUFBRSxNQUFNLDJCQUEyQixDQUFDOztBQUU5RSxNQUFNLENBQUMsTUFBTSxnQkFBZ0IsR0FBRyxJQUFJLGNBQWMsQ0FBMkIsc0JBQXNCLENBQUMsQ0FBQztBQUVyRzs7O0dBR0c7QUFDSCxNQUFNLFVBQVUsY0FBYztJQUMxQixPQUFPLE1BQU0sQ0FBQyxnQkFBZ0IsQ0FBQyxDQUFDO0FBQ3BDLENBQUM7QUFlRCxNQUFNLFdBQVcsR0FBRyxDQUFDLENBQUM7QUFDdEIsTUFBTSxXQUFXLEdBQUcsR0FBRyxDQUFDO0F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iAgICB9XG59XG4iXX0=","import { Directive } from '@angular/core';\nimport { injectProgress } from './progress-root.directive';\nimport * as i0 from \"@angular/core\";\n/**\n * Directive to manage progress indicator state and attributes.\n *\n * This directive is used to display the progress indicator inside the progress bar.\n * It inherits the state and value from the `RdxProgressRootDirective`.\n */\nexport class RdxProgressIndicatorDirective {\n constructor() {\n /**\n * This allows the directive to access the progress bar state and values.\n */\n this.progress = injectProgress();\n }\n static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"20.3.3\", ngImport: i0, type: RdxProgressIndicatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }\n static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: \"14.0.0\", version: \"20.3.3\", type: RdxProgressIndicatorDirective, isStandalone: true, selector: \"[rdxProgressIndicator]\", host: { properties: { \"attr.data-state\": \"progress.progressState()\", \"attr.data-value\": \"progress.value()\", \"attr.data-max\": \"progress.max()\" } }, exportAs: [\"rdxProgressIndicator\"], ngImport: i0 }); }\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"20.3.3\", ngImport: i0, type: RdxProgressIndicatorDirective, decorators: [{\n type: Directive,\n args: [{\n selector: '[rdxProgressIndicator]',\n exportAs: 'rdxProgressIndicator',\n host: {\n '[attr.data-state]': 'progress.progressState()',\n '[attr.data-value]': 'progress.value()',\n '[attr.data-max]': 'progress.max()'\n }\n }]\n }] });\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHJvZ3Jlc3MtaW5kaWNhdG9yLmRpcmVjdGl2ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3BhY2thZ2VzL3ByaW1pdGl2ZXMvcHJvZ3Jlc3Mvc3JjL3Byb2dyZXNzLWluZGljYXRvci5kaXJlY3RpdmUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEs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ncmVzc0luZGljYXRvcl0nLFxuICAgIGV4cG9ydEFzOiAncmR4UHJvZ3Jlc3NJbmRpY2F0b3InLFxuICAgIGhvc3Q6IHtcbiAgICAgICAgJ1thdHRyLmRhdGEtc3RhdGVdJzogJ3Byb2dyZXNzLnByb2dyZXNzU3RhdGUoKScsXG4gICAgICAgICdbYXR0ci5kYXRhLXZhbHVlXSc6ICdwcm9ncmVzcy52YWx1ZSgpJyxcbiAgICAgICAgJ1thdHRyLmRhdGEtbWF4XSc6ICdwcm9ncmVzcy5tYXgoKSdcbiAgICB9XG59KVxuZXhwb3J0IGNsYXNzIFJkeFByb2dyZXNzSW5kaWNhdG9yRGlyZWN0aXZlIHtcbiAgICAvKipcbiAgICAgKiBUaGlzIGFsbG93cyB0aGUgZGlyZWN0aXZlIHRvIGFjY2VzcyB0aGUgcHJvZ3Jlc3MgYmFyIHN0YXRlIGFuZCB2YWx1ZXMuXG4gICAgICovXG4gICAgcHJvdGVjdGVkIHJlYWRvbmx5IHByb2dyZXNzID0gaW5qZWN0UHJvZ3Jlc3MoKTtcbn1cbiJdfQ==","import { NgModule } from '@angular/core';\nimport { RdxProgressIndicatorDirective } from './src/progress-indicator.directive';\nimport { RdxProgressRootDirective } from './src/progress-root.directive';\nimport * as i0 from \"@angular/core\";\nexport * from './src/progress-indicator.directive';\nexport * from './src/progress-root.directive';\nconst _imports = [RdxProgressRootDirective, RdxProgressIndicatorDirective];\nexport class RdxProgressModule {\n static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"20.3.3\", ngImport: i0, type: RdxProgressModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }\n static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: \"14.0.0\", version: \"20.3.3\", ngImport: i0, type: RdxProgressModule, imports: [RdxProgressRootDirective, RdxProgressIndicatorDirective], exports: [RdxProgressRootDirective, RdxProgressIndicatorDirective] }); }\n static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: \"12.0.0\", version: \"20.3.3\", ngImport: i0, type: RdxProgressModule }); }\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"20.3.3\", ngImport: i0, type: RdxProgressModule, decorators: [{\n type: NgModule,\n args: [{\n imports: [..._imports],\n exports: [..._imports]\n }]\n }] });\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9wcmltaXRpdmVzL3Byb2dyZXNzL2luZGV4LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxRQUFRLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFDekMsT0FBTyxFQUFFLDZCQUE2QixFQUFFLE1BQU0sb0NBQW9DLENBQUM7QUFDbkYsT0FBTyxFQUFFLHdCQUF3QixFQUFFLE1BQU0sK0JBQStCLENBQUM7O0FBRXpFLGNBQWMsb0NBQW9DLENBQUM7QUFDbkQsY0FBYywrQkFBK0IsQ0FBQztBQUk5QyxNQUFNLFFBQVEsR0FBRyxDQUFDLHdCQUF3QixFQUFFLDZCQUE2QixDQUFDLENBQUM7QUFNM0UsTUFBTSxPQUFPLGlCQUFpQjs4R0FBakIsaUJBQWlCOytHQUFqQixpQkFBaUIsWUFOWix3QkFBd0IsRUFBRSw2QkFBNkIsYUFBdkQsd0JBQXdCLEVBQUUsNkJBQTZCOytHQU01RCxpQkFBaUI7OzJGQUFqQixpQkFBaUI7a0JBSjdCLFFBQVE7bUJBQUM7b0JBQ04sT0FBTyxFQUFFLENBQUMsR0FBRyxRQUFRLENBQUM7b0JBQ3RCLE9BQU8sRUFBRSxDQUFDLEdBQUcsUUFBUSxDQUFDO2lCQUN6QiIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IE5nTW9kdWxlIH0gZnJvbSAnQGFuZ3VsYXIvY29yZ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AI,GAAG,EAAE,CAAC,mBAAmB,CAAC,EAAE,UAAU,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,iBAAiB,EAAE,OAAO,EAAE,CAAC,wBAAwB,EAAE,6BAA6B,CAAC,EAAE,OAAO,EAAE,CAAC,wBAAwB,EAAE,6BAA6B,CAAC,EAAE,CAAC,CAAC;AAC5Q,IAAI,SAAS,IAAI,CAAC,IAAI,GAAG,EAAE,CAAC,mBAAmB,CAAC,EAAE,UAAU,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,iBAAiB,EAAE,CAAC,CAAC;AACpI;AACA,EAAE,CAAC,wBAAwB,CAAC,EAAE,UAAU,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,iBAAiB,EAAE,UAAU,EAAE,CAAC;AAC3H,YAAY,IAAI,EAAE,QAAQ;AAC1B,YAAY,IAAI,EAAE,CAAC;AACnB,oBAAoB,OAAO,EAAE,CAAC,GAAG,QAAQ,CAAC;AAC1C,oBAAoB,OAAO,EAAE,CAAC,GAAG,QAAQ;AACzC,iBAAiB;AACjB,SAAS,CAAC,EAAE,CAAC;;AClBb;AACA;AACA;;;;"}
1
+ {"version":3,"file":"radix-ng-primitives-progress.mjs","sources":["../../../packages/primitives/progress/src/progress-root.directive.ts","../../../packages/primitives/progress/src/progress-indicator.directive.ts","../../../packages/primitives/progress/src/progress-label.directive.ts","../../../packages/primitives/progress/src/progress-track.directive.ts","../../../packages/primitives/progress/src/progress-value.directive.ts","../../../packages/primitives/progress/index.ts","../../../packages/primitives/progress/radix-ng-primitives-progress.ts"],"sourcesContent":["import { computed, Directive, inject, input, numberAttribute } from '@angular/core';\nimport { createContext } from '@radix-ng/primitives/core';\n\nlet progressId = 0;\n\nconst attr = (value: boolean) => (value ? '' : undefined);\n\nexport type ProgressState = 'indeterminate' | 'complete' | 'progressing';\n\nexport type ProgressValueFormatter = (value: number, min: number, max: number) => string;\n\nexport interface ProgressProps {\n value?: number | null;\n min?: number;\n max?: number;\n valueLabel?: ProgressValueFormatter;\n}\n\nconst DEFAULT_MIN = 0;\nconst DEFAULT_MAX = 100;\n\nconst isValidNumber = (value: unknown): value is number => typeof value === 'number' && !Number.isNaN(value);\n\nconst clamp = (value: number, min: number, max: number) => Math.min(Math.max(value, min), max);\n\nconst progressRootContext = () => {\n const root = injectProgressRoot();\n\n return {\n labelId: root.labelId,\n valueId: root.valueId,\n minState: root.minState,\n maxState: root.maxState,\n valueState: root.valueState,\n percentageState: root.percentageState,\n valueLabelState: root.valueLabelState,\n progressState: root.progressState,\n completeState: root.completeState,\n progressingState: root.progressingState,\n indeterminateState: root.indeterminateState\n };\n};\n\nexport type RdxProgressRootContext = ReturnType<typeof progressRootContext>;\n\nexport const [injectProgressRootContext, provideProgressRootContext] =\n createContext<RdxProgressRootContext>('RdxProgressRoot');\n\n/**\n * Provides progress state and accessibility attributes.\n *\n * @group Components\n */\n@Directive({\n selector: '[rdxProgressRoot]',\n exportAs: 'rdxProgressRoot',\n providers: [provideProgressRootContext(progressRootContext)],\n host: {\n role: 'progressbar',\n '[attr.aria-labelledby]': 'labelId()',\n '[attr.aria-describedby]': 'valueId()',\n '[attr.aria-valuemin]': 'indeterminateState() ? undefined : minState()',\n '[attr.aria-valuemax]': 'indeterminateState() ? undefined : maxState()',\n '[attr.aria-valuenow]': 'valueState() ?? undefined',\n '[attr.aria-valuetext]': 'valueLabelState()',\n '[attr.data-state]': 'progressState()',\n '[attr.data-value]': 'valueState() ?? undefined',\n '[attr.data-min]': 'minState()',\n '[attr.data-max]': 'maxState()',\n '[attr.data-complete]': 'dataAttr(completeState())',\n '[attr.data-progressing]': 'dataAttr(progressingState())',\n '[attr.data-indeterminate]': 'dataAttr(indeterminateState())'\n }\n})\nexport class RdxProgressRootDirective {\n /**\n * Current progress value. Set to `null` for indeterminate progress.\n *\n * @group Props\n * @defaultValue null\n */\n readonly value = input<number | null, number | null>(null, { transform: (value) => this.valueTransform(value) });\n\n /**\n * Minimum progress value.\n *\n * @group Props\n * @defaultValue 0\n */\n readonly min = input(DEFAULT_MIN, { transform: numberAttribute });\n\n /**\n * Maximum progress value.\n *\n * @group Props\n * @defaultValue 100\n */\n readonly max = input(DEFAULT_MAX, { transform: numberAttribute });\n\n /**\n * Formats the current value for assistive technologies and `rdxProgressValue`.\n *\n * @group Props\n */\n readonly valueLabel = input<ProgressValueFormatter>((value, min, max) => this.defaultValueLabel(value, min, max));\n\n readonly labelId = input(`rdx-progress-label-${progressId++}`);\n readonly valueId = input(`rdx-progress-value-${progressId++}`);\n\n readonly minState = computed(() => (isValidNumber(this.min()) ? this.min() : DEFAULT_MIN));\n readonly maxState = computed(() => {\n const min = this.minState();\n const max = this.max();\n\n return isValidNumber(max) && max > min ? max : min + DEFAULT_MAX;\n });\n\n readonly valueState = computed(() => {\n const value = this.value();\n\n if (value === null || !isValidNumber(value)) {\n return null;\n }\n\n return clamp(value, this.minState(), this.maxState());\n });\n\n readonly percentageState = computed(() => {\n const value = this.valueState();\n\n if (value === null) {\n return null;\n }\n\n const min = this.minState();\n const max = this.maxState();\n\n return ((value - min) / (max - min)) * 100;\n });\n\n readonly valueLabelState = computed(() => {\n const value = this.valueState();\n\n return value === null ? undefined : this.valueLabel()(value, this.minState(), this.maxState());\n });\n\n readonly progressState = computed<ProgressState>(() => {\n const value = this.valueState();\n\n if (value === null) {\n return 'indeterminate';\n }\n\n if (value === this.maxState()) {\n return 'complete';\n }\n\n return 'progressing';\n });\n\n readonly completeState = computed(() => this.progressState() === 'complete');\n readonly progressingState = computed(() => this.progressState() === 'progressing');\n readonly indeterminateState = computed(() => this.progressState() === 'indeterminate');\n\n protected readonly dataAttr = attr;\n\n private valueTransform(value: number | null): number | null {\n return value === null ? null : numberAttribute(value);\n }\n\n private defaultValueLabel(value: number, min: number, max: number) {\n return `${Math.round(((value - min) / (max - min)) * 100)}%`;\n }\n}\n\nfunction injectProgressRoot(): RdxProgressRootDirective {\n return inject(RdxProgressRootDirective);\n}\n","import { Directive } from '@angular/core';\nimport { injectProgressRootContext } from './progress-root.directive';\n\nconst attr = (value: boolean) => (value ? '' : undefined);\n\n/**\n * Displays the visual progress fill.\n *\n * @group Components\n */\n@Directive({\n selector: '[rdxProgressIndicator]',\n exportAs: 'rdxProgressIndicator',\n host: {\n '[attr.data-state]': 'progress.progressState()',\n '[attr.data-value]': 'progress.valueState() ?? undefined',\n '[attr.data-min]': 'progress.minState()',\n '[attr.data-max]': 'progress.maxState()',\n '[attr.data-percent]': 'progress.percentageState() ?? undefined',\n '[attr.data-complete]': 'dataAttr(progress.completeState())',\n '[attr.data-progressing]': 'dataAttr(progress.progressingState())',\n '[attr.data-indeterminate]': 'dataAttr(progress.indeterminateState())'\n }\n})\nexport class RdxProgressIndicatorDirective {\n protected readonly progress = injectProgressRootContext()!;\n protected readonly dataAttr = attr;\n}\n","import { Directive } from '@angular/core';\nimport { injectProgressRootContext } from './progress-root.directive';\n\nconst attr = (value: boolean) => (value ? '' : undefined);\n\n/**\n * Labels the progress task.\n *\n * @group Components\n */\n@Directive({\n selector: '[rdxProgressLabel]',\n exportAs: 'rdxProgressLabel',\n host: {\n '[attr.id]': 'progress.labelId()',\n '[attr.data-state]': 'progress.progressState()',\n '[attr.data-complete]': 'dataAttr(progress.completeState())',\n '[attr.data-progressing]': 'dataAttr(progress.progressingState())',\n '[attr.data-indeterminate]': 'dataAttr(progress.indeterminateState())'\n }\n})\nexport class RdxProgressLabelDirective {\n protected readonly progress = injectProgressRootContext()!;\n protected readonly dataAttr = attr;\n}\n","import { Directive } from '@angular/core';\nimport { injectProgressRootContext } from './progress-root.directive';\n\nconst attr = (value: boolean) => (value ? '' : undefined);\n\n/**\n * Contains the visual progress indicator.\n *\n * @group Components\n */\n@Directive({\n selector: '[rdxProgressTrack]',\n exportAs: 'rdxProgressTrack',\n host: {\n '[attr.data-state]': 'progress.progressState()',\n '[attr.data-value]': 'progress.valueState() ?? undefined',\n '[attr.data-min]': 'progress.minState()',\n '[attr.data-max]': 'progress.maxState()',\n '[attr.data-complete]': 'dataAttr(progress.completeState())',\n '[attr.data-progressing]': 'dataAttr(progress.progressingState())',\n '[attr.data-indeterminate]': 'dataAttr(progress.indeterminateState())'\n }\n})\nexport class RdxProgressTrackDirective {\n protected readonly progress = injectProgressRootContext()!;\n protected readonly dataAttr = attr;\n}\n","import { Directive } from '@angular/core';\nimport { injectProgressRootContext } from './progress-root.directive';\n\nconst attr = (value: boolean) => (value ? '' : undefined);\n\n/**\n * Displays the formatted progress value.\n *\n * @group Components\n */\n@Directive({\n selector: '[rdxProgressValue]',\n exportAs: 'rdxProgressValue',\n host: {\n '[attr.id]': 'progress.valueId()',\n '[textContent]': 'progress.valueLabelState() ?? \"\"',\n '[attr.data-state]': 'progress.progressState()',\n '[attr.data-value]': 'progress.valueState() ?? undefined',\n '[attr.data-min]': 'progress.minState()',\n '[attr.data-max]': 'progress.maxState()',\n '[attr.data-complete]': 'dataAttr(progress.completeState())',\n '[attr.data-progressing]': 'dataAttr(progress.progressingState())',\n '[attr.data-indeterminate]': 'dataAttr(progress.indeterminateState())'\n }\n})\nexport class RdxProgressValueDirective {\n protected readonly progress = injectProgressRootContext()!;\n protected readonly dataAttr = attr;\n}\n","import { NgModule } from '@angular/core';\nimport { RdxProgressIndicatorDirective } from './src/progress-indicator.directive';\nimport { RdxProgressLabelDirective } from './src/progress-label.directive';\nimport { RdxProgressRootDirective } from './src/progress-root.directive';\nimport { RdxProgressTrackDirective } from './src/progress-track.directive';\nimport { RdxProgressValueDirective } from './src/progress-value.directive';\n\nexport * from './src/progress-indicator.directive';\nexport * from './src/progress-label.directive';\nexport * from './src/progress-root.directive';\nexport * from './src/progress-track.directive';\nexport * from './src/progress-value.directive';\n\nexport type { ProgressProps, ProgressState, ProgressValueFormatter } from './src/progress-root.directive';\n\nconst _imports = [\n RdxProgressRootDirective,\n RdxProgressLabelDirective,\n RdxProgressValueDirective,\n RdxProgressTrackDirective,\n RdxProgressIndicatorDirective\n];\n\n@NgModule({\n imports: [..._imports],\n exports: [..._imports]\n})\nexport class RdxProgressModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["attr"],"mappings":";;;;AAGA,IAAI,UAAU,GAAG,CAAC;AAElB,MAAMA,MAAI,GAAG,CAAC,KAAc,MAAM,KAAK,GAAG,EAAE,GAAG,SAAS,CAAC;AAazD,MAAM,WAAW,GAAG,CAAC;AACrB,MAAM,WAAW,GAAG,GAAG;AAEvB,MAAM,aAAa,GAAG,CAAC,KAAc,KAAsB,OAAO,KAAK,KAAK,QAAQ,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC;AAE5G,MAAM,KAAK,GAAG,CAAC,KAAa,EAAE,GAAW,EAAE,GAAW,KAAK,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK,EAAE,GAAG,CAAC,EAAE,GAAG,CAAC;AAE9F,MAAM,mBAAmB,GAAG,MAAK;AAC7B,IAAA,MAAM,IAAI,GAAG,kBAAkB,EAAE;IAEjC,OAAO;QACH,OAAO,EAAE,IAAI,CAAC,OAAO;QACrB,OAAO,EAAE,IAAI,CAAC,OAAO;QACrB,QAAQ,EAAE,IAAI,CAAC,QAAQ;QACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ;QACvB,UAAU,EAAE,IAAI,CAAC,UAAU;QAC3B,eAAe,EAAE,IAAI,CAAC,eAAe;QACrC,eAAe,EAAE,IAAI,CAAC,eAAe;QACrC,aAAa,EAAE,IAAI,CAAC,aAAa;QACjC,aAAa,EAAE,IAAI,CAAC,aAAa;QACjC,gBAAgB,EAAE,IAAI,CAAC,gBAAgB;QACvC,kBAAkB,EAAE,IAAI,CAAC;KAC5B;AACL,CAAC;AAIM,MAAM,CAAC,yBAAyB,EAAE,0BAA0B,CAAC,GAChE,aA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,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,iBAAiB,YAX1B,wBAAwB;YACxB,yBAAyB;YACzB,yBAAyB;YACzB,yBAAyB;AACzB,YAAA,6BAA6B,aAJ7B,wBAAwB;YACxB,yBAAyB;YACzB,yBAAyB;YACzB,yBAAyB;YACzB,6BAA6B,CAAA,EAAA,CAAA,CAAA;+GAOpB,iBAAiB,EAAA,CAAA,CAAA;;2FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAJ7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE,CAAC,GAAG,QAAQ,CAAC;AACtB,oBAAA,OAAO,EAAE,CAAC,GAAG,QAAQ;AACxB,iBAAA;;;AC1BD;;AAEG;;;;"}
@@ -1,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { InjectionToken, model, input, booleanAttribute, output, signal, computed, Input, Directive, inject, ElementRef } from '@angular/core';
2
+ import { InjectionToken, model, input, booleanAttribute, output, signal, computed, effect, Directive, inject, ElementRef, Renderer2, DestroyRef } from '@angular/core';
3
3
  import { provideValueAccessor, provideToken } from '@radix-ng/primitives/core';
4
4
  import * as i1 from '@radix-ng/primitives/roving-focus';
5
5
  import { RdxRovingFocusGroupDirective, RdxRovingFocusItemDirective } from '@radix-ng/primitives/roving-focus';
@@ -10,16 +10,21 @@ const RDX_RADIO_GROUP = new InjectionToken('RdxRadioGroup');
10
10
 
11
11
  class RdxRadioGroupDirective {
12
12
  constructor() {
13
- this.value = model(null, ...(ngDevMode ? [{ debugName: "value" }] : []));
14
- this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled", transform: booleanAttribute }] : [{ transform: booleanAttribute }]));
15
- this.required = input(false, ...(ngDevMode ? [{ debugName: "required", transform: booleanAttribute }] : [{ transform: booleanAttribute }]));
16
- this.orientation = input(...(ngDevMode ? [undefined, { debugName: "orientation" }] : []));
13
+ this.value = model(null, ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
14
+ this.defaultValue = input(...(ngDevMode ? [undefined, { debugName: "defaultValue" }] : /* istanbul ignore next */ []));
15
+ this.name = input(...(ngDevMode ? [undefined, { debugName: "name" }] : /* istanbul ignore next */ []));
16
+ this.form = input(...(ngDevMode ? [undefined, { debugName: "form" }] : /* istanbul ignore next */ []));
17
+ this.disabled = input(false, { ...(ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
18
+ this.readonly = input(false, { ...(ngDevMode ? { debugName: "readonly" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
19
+ this.required = input(false, { ...(ngDevMode ? { debugName: "required" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
20
+ this.orientation = input(...(ngDevMode ? [undefined, { debugName: "orientation" }] : /* istanbul ignore next */ []));
17
21
  /**
18
22
  * Event handler called when the value changes.
19
23
  */
20
24
  this.onValueChange = output();
21
- this.disable = signal(this.disabled(), ...(ngDevMode ? [{ debugName: "disable" }] : []));
22
- this.disableState = computed(() => this.disable() || this.disabled(), ...(ngDevMode ? [{ debugName: "disableState" }] : []));
25
+ this.disable = signal(this.disabled(), ...(ngDevMode ? [{ debugName: "disable" }] : /* istanbul ignore next */ []));
26
+ this.disabledState = computed(() => this.disable() || this.disabled(), ...(ngDevMode ? [{ debugName: "disabledState" }] : /* istanbul ignore next */ []));
27
+ this.arrowNavigation = signal(false, ...(ngDevMode ? [{ debugName: "arrowNavigation" }] : /* istanbul ignore next */ []));
23
28
  /**
24
29
  * The callback function to call when the value of the radio group changes.
25
30
  */
@@ -33,6 +38,11 @@ class RdxRadioGroupDirective {
33
38
  this.onTouched = () => {
34
39
  /* Empty */
35
40
  };
41
+ effect(() => {
42
+ if (this.value() === null && this.defaultValue() !== undefined) {
43
+ this.value.set(this.defaultValue());
44
+ }
45
+ });
36
46
  }
37
47
  /**
38
48
  * Select a radio item.
@@ -40,8 +50,13 @@ class RdxRadioGroupDirective {
40
50
  * @ignore
41
51
  */
42
52
  select(value) {
53
+ if (this.disabledState() || this.readonly() || this.value() === value) {
54
+ return;
55
+ }
43
56
  this.value.set(value);
44
- this.onValueChange.emit(value);
57
+ if (value !== null) {
58
+ this.onValueChange.emit(value);
59
+ }
45
60
  this.onChange?.(value);
46
61
  this.onTouched();
47
62
  }
@@ -73,17 +88,23 @@ class RdxRadioGroupDirective {
73
88
  setDisabledState(isDisabled) {
74
89
  this.disable.set(isDisabled);
75
90
  }
91
+ setArrowNavigation(value) {
92
+ this.arrowNavigation.set(value);
93
+ }
94
+ isArrowNavigation() {
95
+ return this.arrowNavigation();
96
+ }
76
97
  onKeydown() {
77
- if (this.disableState())
98
+ if (this.disabledState())
78
99
  return;
79
100
  }
80
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.3", ngImport: i0, type: RdxRadioGroupDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
81
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.3", type: RdxRadioGroupDirective, isStandalone: true, selector: "[rdxRadioRoot]", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, defaultValue: { classPropertyName: "defaultValue", publicName: "defaultValue", isSignal: false, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", onValueChange: "onValueChange" }, host: { attributes: { "role": "radiogroup" }, listeners: { "keydown": "onKeydown()" }, properties: { "attr.aria-orientation": "orientation()", "attr.aria-required": "required()", "attr.data-disabled": "disableState() ? \"\" : null" } }, providers: [
101
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxRadioGroupDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
102
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.9", type: RdxRadioGroupDirective, isStandalone: true, selector: "[rdxRadioRoot]", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, defaultValue: { classPropertyName: "defaultValue", publicName: "defaultValue", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, form: { classPropertyName: "form", publicName: "form", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", onValueChange: "onValueChange" }, host: { attributes: { "role": "radiogroup" }, listeners: { "keydown": "onKeydown()" }, properties: { "attr.aria-orientation": "orientation()", "attr.aria-required": "required() ? \"true\" : undefined", "attr.data-disabled": "disabledState() ? \"\" : undefined", "attr.data-readonly": "readonly() ? \"\" : undefined", "attr.data-required": "required() ? \"\" : undefined" } }, providers: [
82
103
  provideValueAccessor(RdxRadioGroupDirective),
83
104
  { provide: RDX_RADIO_GROUP, useExisting: RdxRadioGroupDirective }
84
105
  ], exportAs: ["rdxRadioRoot"], hostDirectives: [{ directive: i1.RdxRovingFocusGroupDirective, inputs: ["dir", "dir", "orientation", "orientation", "loop", "loop"] }], ngImport: i0 }); }
85
106
  }
86
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImport: i0, type: RdxRadioGroupDirective, decorators: [{
107
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxRadioGroupDirective, decorators: [{
87
108
  type: Directive,
88
109
  args: [{
89
110
  selector: '[rdxRadioRoot]',
@@ -96,14 +117,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
96
117
  host: {
97
118
  role: 'radiogroup',
98
119
  '[attr.aria-orientation]': 'orientation()',
99
- '[attr.aria-required]': 'required()',
100
- '[attr.data-disabled]': 'disableState() ? "" : null',
120
+ '[attr.aria-required]': 'required() ? "true" : undefined',
121
+ '[attr.data-disabled]': 'disabledState() ? "" : undefined',
122
+ '[attr.data-readonly]': 'readonly() ? "" : undefined',
123
+ '[attr.data-required]': 'required() ? "" : undefined',
101
124
  '(keydown)': 'onKeydown()'
102
125
  }
103
126
  }]
104
- }], propDecorators: { defaultValue: [{
105
- type: Input
106
- }] } });
127
+ }], ctorParameters: () => [], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], defaultValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "defaultValue", required: false }] }], name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: false }] }], form: [{ type: i0.Input, args: [{ isSignal: true, alias: "form", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], readonly: [{ type: i0.Input, args: [{ isSignal: true, alias: "readonly", required: false }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }], orientation: [{ type: i0.Input, args: [{ isSignal: true, alias: "orientation", required: false }] }], onValueChange: [{ type: i0.Output, args: ["onValueChange"] }] } });
107
128
 
108
129
  const RdxRadioItemToken = new InjectionToken('RadioItemToken');
109
130
  function injectRadioItem() {
@@ -113,55 +134,136 @@ class RdxRadioItemDirective {
113
134
  constructor() {
114
135
  this.radioGroup = inject(RDX_RADIO_GROUP);
115
136
  this.elementRef = inject(ElementRef);
116
- this.value = input.required(...(ngDevMode ? [{ debugName: "value" }] : []));
117
- this.id = input(...(ngDevMode ? [undefined, { debugName: "id" }] : []));
118
- this.required = input(...(ngDevMode ? [undefined, { debugName: "required" }] : []));
119
- this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled", transform: booleanAttribute }] : [{ transform: booleanAttribute }]));
120
- this.disabledState = computed(() => this.radioGroup.disableState() || this.disabled(), ...(ngDevMode ? [{ debugName: "disabledState" }] : []));
121
- this.checkedState = computed(() => this.radioGroup.value() === this.value(), ...(ngDevMode ? [{ debugName: "checkedState" }] : []));
137
+ this.renderer = inject(Renderer2);
138
+ this.rovingFocusItem = inject(RdxRovingFocusItemDirective);
139
+ this.destroyRef = inject(DestroyRef);
140
+ this.inputElement = this.renderer.createElement('input');
141
+ this.value = input.required(...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
142
+ this.id = input(...(ngDevMode ? [undefined, { debugName: "id" }] : /* istanbul ignore next */ []));
143
+ this.required = input(false, { ...(ngDevMode ? { debugName: "required" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
144
+ this.disabled = input(false, { ...(ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
145
+ this.readonly = input(false, { ...(ngDevMode ? { debugName: "readonly" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
146
+ this.nativeButton = input(false, { ...(ngDevMode ? { debugName: "nativeButton" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
147
+ this.nativeButtonState = computed(() => this.nativeButton() || this.elementRef.nativeElement.tagName === 'BUTTON', ...(ngDevMode ? [{ debugName: "nativeButtonState" }] : /* istanbul ignore next */ []));
148
+ this.disabledState = computed(() => this.radioGroup.disabledState() || this.disabled(), ...(ngDevMode ? [{ debugName: "disabledState" }] : /* istanbul ignore next */ []));
149
+ this.readonlyState = computed(() => this.radioGroup.readonly() || this.readonly(), ...(ngDevMode ? [{ debugName: "readonlyState" }] : /* istanbul ignore next */ []));
150
+ this.requiredState = computed(() => this.radioGroup.required() || this.required(), ...(ngDevMode ? [{ debugName: "requiredState" }] : /* istanbul ignore next */ []));
151
+ this.checkedState = computed(() => this.radioGroup.value() === this.value(), ...(ngDevMode ? [{ debugName: "checkedState" }] : /* istanbul ignore next */ []));
122
152
  this.ARROW_KEYS = ['ArrowUp', 'ArrowDown', 'ArrowLeft', 'ArrowRight'];
123
- this.isArrowKeyPressedSignal = signal(false, ...(ngDevMode ? [{ debugName: "isArrowKeyPressedSignal" }] : []));
124
- }
125
- /** @ignore */
126
- ngOnInit() {
127
- if (this.radioGroup.defaultValue === this.value()) {
128
- this.radioGroup.select(this.value());
129
- }
153
+ this.createHiddenInput();
154
+ const unlistenInputChange = this.renderer.listen(this.inputElement, 'change', () => {
155
+ if (this.inputElement.checked) {
156
+ this.radioGroup.select(this.value());
157
+ }
158
+ });
159
+ this.destroyRef.onDestroy(() => {
160
+ unlistenInputChange();
161
+ const parent = this.inputElement.parentNode;
162
+ if (parent) {
163
+ this.renderer.removeChild(parent, this.inputElement);
164
+ }
165
+ });
166
+ effect(() => {
167
+ this.rovingFocusItem.setActive(this.checkedState());
168
+ this.rovingFocusItem.setFocusable(!this.disabledState());
169
+ this.syncHiddenInput();
170
+ });
130
171
  }
131
172
  /** @ignore */
132
173
  onClick() {
133
- if (!this.disabledState()) {
174
+ if (!this.disabledState() && !this.readonlyState()) {
134
175
  this.radioGroup.select(this.value());
135
- this.isArrowKeyPressedSignal.set(true);
136
176
  }
137
177
  }
138
178
  /** @ignore */
139
179
  onKeyDown(event) {
140
- if (this.ARROW_KEYS.includes(event.key)) {
141
- this.isArrowKeyPressedSignal.set(true);
180
+ const keyEvent = event;
181
+ if (keyEvent.key === ' ' || keyEvent.key === 'Enter') {
182
+ this.onClick();
183
+ return;
184
+ }
185
+ if (this.isAllowedArrowKey(keyEvent.key)) {
186
+ this.radioGroup.setArrowNavigation(true);
142
187
  }
143
188
  }
144
189
  /** @ignore */
145
190
  onKeyUp() {
146
- this.isArrowKeyPressedSignal.set(false);
191
+ this.radioGroup.setArrowNavigation(false);
147
192
  }
148
193
  /** @ignore */
149
194
  onFocus() {
150
- this.radioGroup.select(this.value());
151
- setTimeout(() => {
152
- /**
153
- * When navigating with arrow keys, focus triggers on the radio item.
154
- * To "check" the radio, we programmatically trigger a click event.
155
- */
156
- if (this.isArrowKeyPressedSignal()) {
157
- this.elementRef.nativeElement.click();
195
+ queueMicrotask(() => {
196
+ if (this.radioGroup.isArrowNavigation()) {
197
+ this.radioGroup.select(this.value());
198
+ this.radioGroup.setArrowNavigation(false);
158
199
  }
159
- }, 0);
200
+ });
201
+ }
202
+ isAllowedArrowKey(key) {
203
+ if (!this.ARROW_KEYS.includes(key)) {
204
+ return false;
205
+ }
206
+ const orientation = this.radioGroup.orientation() ?? 'horizontal';
207
+ if (orientation === 'vertical') {
208
+ return key === 'ArrowUp' || key === 'ArrowDown';
209
+ }
210
+ return key === 'ArrowLeft' || key === 'ArrowRight';
160
211
  }
161
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.3", ngImport: i0, type: RdxRadioItemDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
162
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.3", type: RdxRadioItemDirective, isStandalone: true, selector: "[rdxRadioItem]", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: true, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "type": "button", "role": "radio" }, listeners: { "click": "onClick()", "keydown": "onKeyDown($event)", "keyup": "onKeyUp()", "focus": "onFocus()" }, properties: { "attr.aria-checked": "checkedState()", "attr.data-disabled": "disabledState() ? \"\" : null", "attr.data-state": "checkedState() ? \"checked\" : \"unchecked\"", "disabled": "disabledState()" } }, providers: [provideToken(RdxRadioItemToken, RdxRadioItemDirective)], exportAs: ["rdxRadioItem"], hostDirectives: [{ directive: i1.RdxRovingFocusItemDirective, inputs: ["tabStopId", "id", "focusable", "focusable", "active", "active", "allowShiftKey", "allowShiftKey"] }], ngImport: i0 }); }
212
+ createHiddenInput() {
213
+ const host = this.elementRef.nativeElement;
214
+ const parent = host.parentNode;
215
+ this.renderer.setAttribute(this.inputElement, 'type', 'radio');
216
+ this.renderer.setAttribute(this.inputElement, 'tabindex', '-1');
217
+ this.renderer.setAttribute(this.inputElement, 'aria-hidden', 'true');
218
+ this.renderer.setStyle(this.inputElement, 'position', 'absolute');
219
+ this.renderer.setStyle(this.inputElement, 'pointer-events', 'none');
220
+ this.renderer.setStyle(this.inputElement, 'opacity', '0');
221
+ this.renderer.setStyle(this.inputElement, 'margin', '0');
222
+ this.renderer.setStyle(this.inputElement, 'inset', '0');
223
+ this.renderer.setStyle(this.inputElement, 'transform', 'translateX(-100%)');
224
+ if (parent) {
225
+ this.renderer.insertBefore(parent, this.inputElement, host.nextSibling);
226
+ }
227
+ }
228
+ syncHiddenInput() {
229
+ const checked = this.checkedState();
230
+ this.inputElement.name = this.radioGroup.name() ?? '';
231
+ this.inputElement.value = this.value();
232
+ this.inputElement.checked = checked;
233
+ this.inputElement.required = this.requiredState();
234
+ this.inputElement.disabled = this.disabledState();
235
+ this.setOptionalAttribute('name', this.radioGroup.name());
236
+ this.setOptionalAttribute('form', this.radioGroup.form());
237
+ this.setBooleanAttribute('checked', checked);
238
+ this.setBooleanAttribute('required', this.requiredState());
239
+ this.setBooleanAttribute('disabled', this.disabledState());
240
+ this.renderer.setAttribute(this.inputElement, 'value', this.value());
241
+ if (this.previousCheckedState === false && checked) {
242
+ this.inputElement.dispatchEvent(new Event('input', { bubbles: true }));
243
+ this.inputElement.dispatchEvent(new Event('change', { bubbles: true }));
244
+ }
245
+ this.previousCheckedState = checked;
246
+ }
247
+ setOptionalAttribute(name, value) {
248
+ if (value) {
249
+ this.renderer.setAttribute(this.inputElement, name, value);
250
+ }
251
+ else {
252
+ this.renderer.removeAttribute(this.inputElement, name);
253
+ }
254
+ }
255
+ setBooleanAttribute(name, value) {
256
+ if (value) {
257
+ this.renderer.setAttribute(this.inputElement, name, '');
258
+ }
259
+ else {
260
+ this.renderer.removeAttribute(this.inputElement, name);
261
+ }
262
+ }
263
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxRadioItemDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
264
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.9", type: RdxRadioItemDirective, isStandalone: true, selector: "[rdxRadioItem]", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: true, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, nativeButton: { classPropertyName: "nativeButton", publicName: "nativeButton", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "radio" }, listeners: { "click": "onClick()", "keydown": "onKeyDown($event)", "keyup": "onKeyUp()", "focus": "onFocus()" }, properties: { "attr.type": "nativeButtonState() ? \"button\" : undefined", "attr.aria-checked": "checkedState()", "attr.aria-readonly": "readonlyState() ? \"true\" : undefined", "attr.aria-required": "requiredState() ? \"true\" : undefined", "attr.data-checked": "checkedState() ? \"\" : undefined", "attr.data-unchecked": "!checkedState() ? \"\" : undefined", "attr.data-disabled": "disabledState() ? \"\" : undefined", "attr.data-readonly": "readonlyState() ? \"\" : undefined", "attr.data-required": "requiredState() ? \"\" : undefined", "attr.data-state": "checkedState() ? \"checked\" : \"unchecked\"", "attr.disabled": "nativeButtonState() && disabledState() ? \"\" : undefined" } }, providers: [provideToken(RdxRadioItemToken, RdxRadioItemDirective)], exportAs: ["rdxRadioItem"], hostDirectives: [{ directive: i1.RdxRovingFocusItemDirective, inputs: ["tabStopId", "id", "focusable", "focusable", "active", "active", "allowShiftKey", "allowShiftKey"] }], ngImport: i0 }); }
163
265
  }
164
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImport: i0, type: RdxRadioItemDirective, decorators: [{
266
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxRadioItemDirective, decorators: [{
165
267
  type: Directive,
166
268
  args: [{
167
269
  selector: '[rdxRadioItem]',
@@ -171,36 +273,48 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
171
273
  { directive: RdxRovingFocusItemDirective, inputs: ['tabStopId: id', 'focusable', 'active', 'allowShiftKey'] }
172
274
  ],
173
275
  host: {
174
- type: 'button',
276
+ '[attr.type]': 'nativeButtonState() ? "button" : undefined',
175
277
  role: 'radio',
176
278
  '[attr.aria-checked]': 'checkedState()',
177
- '[attr.data-disabled]': 'disabledState() ? "" : null',
279
+ '[attr.aria-readonly]': 'readonlyState() ? "true" : undefined',
280
+ '[attr.aria-required]': 'requiredState() ? "true" : undefined',
281
+ '[attr.data-checked]': 'checkedState() ? "" : undefined',
282
+ '[attr.data-unchecked]': '!checkedState() ? "" : undefined',
283
+ '[attr.data-disabled]': 'disabledState() ? "" : undefined',
284
+ '[attr.data-readonly]': 'readonlyState() ? "" : undefined',
285
+ '[attr.data-required]': 'requiredState() ? "" : undefined',
178
286
  '[attr.data-state]': 'checkedState() ? "checked" : "unchecked"',
179
- '[disabled]': 'disabledState()',
287
+ '[attr.disabled]': 'nativeButtonState() && disabledState() ? "" : undefined',
180
288
  '(click)': 'onClick()',
181
289
  '(keydown)': 'onKeyDown($event)',
182
290
  '(keyup)': 'onKeyUp()',
183
291
  '(focus)': 'onFocus()'
184
292
  }
185
293
  }]
186
- }] });
294
+ }], ctorParameters: () => [], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: true }] }], id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], readonly: [{ type: i0.Input, args: [{ isSignal: true, alias: "readonly", required: false }] }], nativeButton: [{ type: i0.Input, args: [{ isSignal: true, alias: "nativeButton", required: false }] }] } });
187
295
 
188
296
  class RdxRadioIndicatorDirective {
189
297
  constructor() {
190
298
  this.radioGroup = inject(RDX_RADIO_GROUP);
191
299
  this.radioItem = inject(RdxRadioItemDirective);
192
300
  }
193
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.3", ngImport: i0, type: RdxRadioIndicatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
194
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.3", type: RdxRadioIndicatorDirective, isStandalone: true, selector: "[rdxRadioIndicator]", host: { properties: { "attr.data-state": "radioItem.checkedState() ? \"checked\" : \"unchecked\"", "attr.data-disabled": "radioItem.disabled() ? \"\" : undefined" } }, exportAs: ["rdxRadioIndicator"], ngImport: i0 }); }
301
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxRadioIndicatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
302
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.9", type: RdxRadioIndicatorDirective, isStandalone: true, selector: "[rdxRadioIndicator]", host: { properties: { "attr.data-checked": "radioItem.checkedState() ? \"\" : undefined", "attr.data-unchecked": "!radioItem.checkedState() ? \"\" : undefined", "attr.data-state": "radioItem.checkedState() ? \"checked\" : \"unchecked\"", "attr.data-disabled": "radioItem.disabledState() ? \"\" : undefined", "attr.data-readonly": "radioItem.readonlyState() ? \"\" : undefined", "attr.data-required": "radioItem.requiredState() ? \"\" : undefined", "hidden": "!radioItem.checkedState()", "style.pointer-events": "\"none\"" } }, exportAs: ["rdxRadioIndicator"], ngImport: i0 }); }
195
303
  }
196
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImport: i0, type: RdxRadioIndicatorDirective, decorators: [{
304
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxRadioIndicatorDirective, decorators: [{
197
305
  type: Directive,
198
306
  args: [{
199
307
  selector: '[rdxRadioIndicator]',
200
308
  exportAs: 'rdxRadioIndicator',
201
309
  host: {
310
+ '[attr.data-checked]': 'radioItem.checkedState() ? "" : undefined',
311
+ '[attr.data-unchecked]': '!radioItem.checkedState() ? "" : undefined',
202
312
  '[attr.data-state]': 'radioItem.checkedState() ? "checked" : "unchecked"',
203
- '[attr.data-disabled]': 'radioItem.disabled() ? "" : undefined'
313
+ '[attr.data-disabled]': 'radioItem.disabledState() ? "" : undefined',
314
+ '[attr.data-readonly]': 'radioItem.readonlyState() ? "" : undefined',
315
+ '[attr.data-required]': 'radioItem.requiredState() ? "" : undefined',
316
+ '[hidden]': '!radioItem.checkedState()',
317
+ '[style.pointer-events]': '"none"'
204
318
  }
205
319
  }]
206
320
  }] });
@@ -208,31 +322,58 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImpor
208
322
  class RdxRadioItemInputDirective {
209
323
  constructor() {
210
324
  this.radioItem = injectRadioItem();
211
- this.name = input(...(ngDevMode ? [undefined, { debugName: "name" }] : []));
212
- this.value = computed(() => this.radioItem.value() || undefined, ...(ngDevMode ? [{ debugName: "value" }] : []));
213
- this.checked = computed(() => this.radioItem.checkedState() || undefined, ...(ngDevMode ? [{ debugName: "checked" }] : []));
214
- this.required = input(this.radioItem.required(), ...(ngDevMode ? [{ debugName: "required" }] : []));
215
- this.disabled = input(this.radioItem.disabled(), ...(ngDevMode ? [{ debugName: "disabled" }] : []));
216
- }
217
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.3", ngImport: i0, type: RdxRadioItemInputDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
218
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.3", type: RdxRadioItemInputDirective, isStandalone: true, selector: "[rdxRadioItemInput]", inputs: { name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "type": "radio" }, properties: { "attr.name": "name()", "attr.required": "required()", "attr.disabled": "disabled() ? disabled() : undefined", "attr.checked": "checked()", "value": "value()" } }, exportAs: ["rdxRadioItemInput"], hostDirectives: [{ directive: i1$1.RdxVisuallyHiddenDirective, inputs: ["feature", "feature"] }], ngImport: i0 }); }
325
+ this.radioGroup = inject(RDX_RADIO_GROUP);
326
+ this.input = inject(ElementRef).nativeElement;
327
+ this.name = computed(() => this.radioGroup.name(), ...(ngDevMode ? [{ debugName: "name" }] : /* istanbul ignore next */ []));
328
+ this.form = computed(() => this.radioGroup.form(), ...(ngDevMode ? [{ debugName: "form" }] : /* istanbul ignore next */ []));
329
+ this.value = computed(() => this.radioItem.value() || undefined, ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
330
+ this.checked = computed(() => this.radioItem.checkedState(), ...(ngDevMode ? [{ debugName: "checked" }] : /* istanbul ignore next */ []));
331
+ this.required = computed(() => this.radioItem.requiredState(), ...(ngDevMode ? [{ debugName: "required" }] : /* istanbul ignore next */ []));
332
+ this.disabled = computed(() => this.radioItem.disabledState(), ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
333
+ let isInitial = true;
334
+ effect(() => {
335
+ const checked = this.checked();
336
+ if (isInitial) {
337
+ isInitial = false;
338
+ return;
339
+ }
340
+ if (checked) {
341
+ this.input.dispatchEvent(new Event('input', { bubbles: true }));
342
+ this.input.dispatchEvent(new Event('change', { bubbles: true }));
343
+ }
344
+ });
345
+ }
346
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxRadioItemInputDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
347
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.9", type: RdxRadioItemInputDirective, isStandalone: true, selector: "input[rdxRadioItemInput]", host: { attributes: { "type": "radio", "tabindex": "-1", "aria-hidden": "true" }, properties: { "attr.name": "name()", "attr.form": "form()", "attr.required": "required() ? \"\" : undefined", "attr.disabled": "disabled() ? \"\" : undefined", "attr.checked": "checked() ? \"\" : undefined", "checked": "checked()", "attr.value": "value()", "style": "{\n position: 'absolute',\n pointerEvents: 'none',\n opacity: 0,\n margin: 0,\n inset: 0,\n transform: 'translateX(-100%)',\n }" } }, exportAs: ["rdxRadioItemInput"], hostDirectives: [{ directive: i1$1.RdxVisuallyHiddenDirective, inputs: ["feature", "feature"] }], ngImport: i0 }); }
219
348
  }
220
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImport: i0, type: RdxRadioItemInputDirective, decorators: [{
349
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RdxRadioItemInputDirective, decorators: [{
221
350
  type: Directive,
222
351
  args: [{
223
- selector: '[rdxRadioItemInput]',
352
+ selector: 'input[rdxRadioItemInput]',
224
353
  exportAs: 'rdxRadioItemInput',
225
354
  hostDirectives: [{ directive: RdxVisuallyHiddenDirective, inputs: ['feature'] }],
226
355
  host: {
227
356
  type: 'radio',
357
+ tabindex: '-1',
358
+ 'aria-hidden': 'true',
228
359
  '[attr.name]': 'name()',
229
- '[attr.required]': 'required()',
230
- '[attr.disabled]': 'disabled() ? disabled() : undefined',
231
- '[attr.checked]': 'checked()',
232
- '[value]': 'value()'
360
+ '[attr.form]': 'form()',
361
+ '[attr.required]': 'required() ? "" : undefined',
362
+ '[attr.disabled]': 'disabled() ? "" : undefined',
363
+ '[attr.checked]': 'checked() ? "" : undefined',
364
+ '[checked]': 'checked()',
365
+ '[attr.value]': 'value()',
366
+ '[style]': `{
367
+ position: 'absolute',
368
+ pointerEvents: 'none',
369
+ opacity: 0,
370
+ margin: 0,
371
+ inset: 0,
372
+ transform: 'translateX(-100%)',
373
+ }`
233
374
  }
234
375
  }]
235
- }] });
376
+ }], ctorParameters: () => [] });
236
377
 
237
378
  /**
238
379
  * Generated bundle index. Do not edit.