@nanahoshi/mona-ui 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (176) hide show
  1. package/auto-complete/package.json +4 -0
  2. package/avatar/package.json +4 -0
  3. package/breadcrumb/package.json +4 -0
  4. package/button/package.json +4 -0
  5. package/button-group/package.json +4 -0
  6. package/calendar/package.json +4 -0
  7. package/check-box/package.json +4 -0
  8. package/chip/package.json +4 -0
  9. package/circular-progress-bar/package.json +4 -0
  10. package/color-gradient/package.json +4 -0
  11. package/color-palette/package.json +4 -0
  12. package/color-picker/package.json +4 -0
  13. package/combo-box/package.json +4 -0
  14. package/common/package.json +4 -0
  15. package/contextmenu/package.json +4 -0
  16. package/date-input/package.json +4 -0
  17. package/date-picker/package.json +4 -0
  18. package/datetime-picker/package.json +4 -0
  19. package/dialog/package.json +4 -0
  20. package/dropdown-button/package.json +4 -0
  21. package/dropdown-list/package.json +4 -0
  22. package/dropdowns/package.json +4 -0
  23. package/editor/package.json +4 -0
  24. package/expansion-panel/package.json +4 -0
  25. package/fesm2022/nanahoshi-mona-ui-auto-complete.mjs +40 -55
  26. package/fesm2022/nanahoshi-mona-ui-breadcrumb.mjs +24 -58
  27. package/fesm2022/nanahoshi-mona-ui-button-group.mjs +37 -48
  28. package/fesm2022/nanahoshi-mona-ui-button.mjs +130 -129
  29. package/fesm2022/nanahoshi-mona-ui-calendar.mjs +69 -165
  30. package/fesm2022/nanahoshi-mona-ui-check-box.mjs +81 -128
  31. package/fesm2022/nanahoshi-mona-ui-chip.mjs +102 -112
  32. package/fesm2022/nanahoshi-mona-ui-circular-progress-bar.mjs +11 -25
  33. package/fesm2022/nanahoshi-mona-ui-color-gradient.mjs +41 -92
  34. package/fesm2022/nanahoshi-mona-ui-color-palette.mjs +27 -49
  35. package/fesm2022/nanahoshi-mona-ui-color-picker.mjs +64 -65
  36. package/fesm2022/nanahoshi-mona-ui-combo-box.mjs +39 -61
  37. package/fesm2022/nanahoshi-mona-ui-date-input.mjs +12 -15
  38. package/fesm2022/nanahoshi-mona-ui-date-picker.mjs +44 -33
  39. package/fesm2022/nanahoshi-mona-ui-datetime-picker.mjs +58 -60
  40. package/fesm2022/nanahoshi-mona-ui-dialog.mjs +52 -165
  41. package/fesm2022/nanahoshi-mona-ui-dropdown-list.mjs +36 -59
  42. package/fesm2022/nanahoshi-mona-ui-dropdowns.mjs +56 -61
  43. package/fesm2022/nanahoshi-mona-ui-editor.mjs +302 -81
  44. package/fesm2022/nanahoshi-mona-ui-expansion-panel.mjs +33 -84
  45. package/fesm2022/nanahoshi-mona-ui-fieldset.mjs +12 -45
  46. package/fesm2022/nanahoshi-mona-ui-filter.mjs +18 -48
  47. package/fesm2022/{nanahoshi-mona-ui-grid-grid-footer-cell.component-B9SQH5N-.mjs → nanahoshi-mona-ui-grid-grid-footer-cell.component-B6FBLtrr.mjs} +14 -14
  48. package/fesm2022/{nanahoshi-mona-ui-grid-grid-footer-table-cell.directive-DlLwcCFT.mjs → nanahoshi-mona-ui-grid-grid-footer-table-cell.directive-OJe4UYuw.mjs} +4 -8
  49. package/fesm2022/nanahoshi-mona-ui-grid-grid-list.component-DCd8K6ng.mjs +121 -0
  50. package/fesm2022/{nanahoshi-mona-ui-grid-grid-toggle.component-DIUutx9s.mjs → nanahoshi-mona-ui-grid-grid-toggle.component-Dl8Hlkhj.mjs} +26 -55
  51. package/fesm2022/nanahoshi-mona-ui-grid-grid-virtual-list.component-C5FRZlvv.mjs +231 -0
  52. package/fesm2022/{nanahoshi-mona-ui-grid-nanahoshi-mona-ui-grid-C3eZIaJK.mjs → nanahoshi-mona-ui-grid-nanahoshi-mona-ui-grid-BRZUd8cE.mjs} +167 -451
  53. package/fesm2022/nanahoshi-mona-ui-grid.mjs +1 -1
  54. package/fesm2022/nanahoshi-mona-ui-internal-indicator-icon.mjs +10 -28
  55. package/fesm2022/nanahoshi-mona-ui-internal-list.mjs +57 -87
  56. package/fesm2022/nanahoshi-mona-ui-internal-tree.mjs +48 -139
  57. package/fesm2022/nanahoshi-mona-ui-internal.mjs +29 -1
  58. package/fesm2022/nanahoshi-mona-ui-list-box.mjs +10 -32
  59. package/fesm2022/nanahoshi-mona-ui-list-view.mjs +8 -21
  60. package/fesm2022/nanahoshi-mona-ui-menubar.mjs +50 -156
  61. package/fesm2022/nanahoshi-mona-ui-multi-select.mjs +40 -69
  62. package/fesm2022/nanahoshi-mona-ui-notification.mjs +32 -116
  63. package/fesm2022/nanahoshi-mona-ui-numeric-text-box.mjs +81 -107
  64. package/fesm2022/nanahoshi-mona-ui-pager.mjs +33 -85
  65. package/fesm2022/nanahoshi-mona-ui-placeholder.mjs +12 -34
  66. package/fesm2022/nanahoshi-mona-ui-popover.mjs +31 -52
  67. package/fesm2022/nanahoshi-mona-ui-popup-menu.mjs +38 -110
  68. package/fesm2022/nanahoshi-mona-ui-popup.mjs +4 -4
  69. package/fesm2022/nanahoshi-mona-ui-progress-bar.mjs +21 -62
  70. package/fesm2022/nanahoshi-mona-ui-radio-button.mjs +66 -111
  71. package/fesm2022/nanahoshi-mona-ui-scroll-view.mjs +60 -151
  72. package/fesm2022/nanahoshi-mona-ui-slider.mjs +117 -173
  73. package/fesm2022/nanahoshi-mona-ui-split-button.mjs +32 -45
  74. package/fesm2022/nanahoshi-mona-ui-splitter.mjs +29 -64
  75. package/fesm2022/nanahoshi-mona-ui-stepper.mjs +38 -101
  76. package/fesm2022/nanahoshi-mona-ui-switch.mjs +58 -79
  77. package/fesm2022/nanahoshi-mona-ui-tabs.mjs +42 -118
  78. package/fesm2022/nanahoshi-mona-ui-text-area.mjs +29 -37
  79. package/fesm2022/nanahoshi-mona-ui-text-box.mjs +60 -81
  80. package/fesm2022/nanahoshi-mona-ui-theme.mjs +1111 -269
  81. package/fesm2022/nanahoshi-mona-ui-time-picker.mjs +45 -39
  82. package/fesm2022/nanahoshi-mona-ui-time-selector.mjs +45 -109
  83. package/fesm2022/nanahoshi-mona-ui-tooltip.mjs +54 -82
  84. package/fesm2022/nanahoshi-mona-ui-tree-view.mjs +2 -2
  85. package/fesm2022/nanahoshi-mona-ui-window.mjs +35 -115
  86. package/fieldset/package.json +4 -0
  87. package/filter/package.json +4 -0
  88. package/grid/package.json +4 -0
  89. package/internal/filter-input/package.json +4 -0
  90. package/internal/indicator-icon/package.json +4 -0
  91. package/internal/list/package.json +4 -0
  92. package/internal/package.json +4 -0
  93. package/internal/tree/package.json +4 -0
  94. package/list/package.json +4 -0
  95. package/list-box/package.json +4 -0
  96. package/list-view/package.json +4 -0
  97. package/menubar/package.json +4 -0
  98. package/multi-select/package.json +4 -0
  99. package/notification/package.json +4 -0
  100. package/numeric-text-box/package.json +4 -0
  101. package/package.json +31 -5
  102. package/pager/package.json +4 -0
  103. package/placeholder/package.json +4 -0
  104. package/popover/package.json +4 -0
  105. package/popup/package.json +4 -0
  106. package/popup-menu/package.json +4 -0
  107. package/progress-bar/package.json +4 -0
  108. package/query/package.json +4 -0
  109. package/radio-button/package.json +4 -0
  110. package/scroll-view/package.json +4 -0
  111. package/slider/package.json +4 -0
  112. package/split-button/package.json +4 -0
  113. package/splitter/package.json +4 -0
  114. package/stepper/package.json +4 -0
  115. package/switch/package.json +4 -0
  116. package/tabs/package.json +4 -0
  117. package/text-area/package.json +4 -0
  118. package/text-box/package.json +4 -0
  119. package/theme/package.json +4 -0
  120. package/time-picker/package.json +4 -0
  121. package/time-selector/package.json +4 -0
  122. package/tooltip/package.json +4 -0
  123. package/tree-view/package.json +4 -0
  124. package/types/nanahoshi-mona-ui-auto-complete.d.ts +6 -7
  125. package/types/nanahoshi-mona-ui-breadcrumb.d.ts +4 -6
  126. package/types/nanahoshi-mona-ui-button-group.d.ts +2 -3
  127. package/types/nanahoshi-mona-ui-button.d.ts +6 -6
  128. package/types/nanahoshi-mona-ui-calendar.d.ts +21 -22
  129. package/types/nanahoshi-mona-ui-check-box.d.ts +6 -9
  130. package/types/nanahoshi-mona-ui-chip.d.ts +2 -3
  131. package/types/nanahoshi-mona-ui-circular-progress-bar.d.ts +2 -4
  132. package/types/nanahoshi-mona-ui-color-gradient.d.ts +10 -11
  133. package/types/nanahoshi-mona-ui-color-palette.d.ts +4 -5
  134. package/types/nanahoshi-mona-ui-color-picker.d.ts +6 -8
  135. package/types/nanahoshi-mona-ui-combo-box.d.ts +6 -7
  136. package/types/nanahoshi-mona-ui-date-input.d.ts +2 -3
  137. package/types/nanahoshi-mona-ui-date-picker.d.ts +2 -3
  138. package/types/nanahoshi-mona-ui-dialog.d.ts +7 -8
  139. package/types/nanahoshi-mona-ui-dropdown-list.d.ts +6 -7
  140. package/types/nanahoshi-mona-ui-dropdowns.d.ts +2 -3
  141. package/types/nanahoshi-mona-ui-editor.d.ts +17 -17
  142. package/types/nanahoshi-mona-ui-expansion-panel.d.ts +8 -10
  143. package/types/nanahoshi-mona-ui-fieldset.d.ts +6 -8
  144. package/types/nanahoshi-mona-ui-filter.d.ts +3 -4
  145. package/types/nanahoshi-mona-ui-grid.d.ts +16 -17
  146. package/types/nanahoshi-mona-ui-internal-indicator-icon.d.ts +0 -1
  147. package/types/nanahoshi-mona-ui-internal-tree.d.ts +16 -16
  148. package/types/nanahoshi-mona-ui-internal.d.ts +8 -1
  149. package/types/nanahoshi-mona-ui-list-box.d.ts +4 -5
  150. package/types/nanahoshi-mona-ui-list-view.d.ts +2 -3
  151. package/types/nanahoshi-mona-ui-menubar.d.ts +7 -8
  152. package/types/nanahoshi-mona-ui-multi-select.d.ts +8 -9
  153. package/types/nanahoshi-mona-ui-numeric-text-box.d.ts +2 -3
  154. package/types/nanahoshi-mona-ui-pager.d.ts +6 -7
  155. package/types/nanahoshi-mona-ui-placeholder.d.ts +4 -6
  156. package/types/nanahoshi-mona-ui-popover.d.ts +8 -9
  157. package/types/nanahoshi-mona-ui-popup-menu.d.ts +12 -13
  158. package/types/nanahoshi-mona-ui-progress-bar.d.ts +8 -9
  159. package/types/nanahoshi-mona-ui-radio-button.d.ts +8 -11
  160. package/types/nanahoshi-mona-ui-scroll-view.d.ts +18 -20
  161. package/types/nanahoshi-mona-ui-slider.d.ts +18 -18
  162. package/types/nanahoshi-mona-ui-split-button.d.ts +2 -3
  163. package/types/nanahoshi-mona-ui-splitter.d.ts +6 -8
  164. package/types/nanahoshi-mona-ui-stepper.d.ts +13 -14
  165. package/types/nanahoshi-mona-ui-switch.d.ts +6 -7
  166. package/types/nanahoshi-mona-ui-tabs.d.ts +15 -17
  167. package/types/nanahoshi-mona-ui-text-area.d.ts +2 -4
  168. package/types/nanahoshi-mona-ui-text-box.d.ts +4 -6
  169. package/types/nanahoshi-mona-ui-theme.d.ts +111 -12
  170. package/types/nanahoshi-mona-ui-time-picker.d.ts +2 -3
  171. package/types/nanahoshi-mona-ui-time-selector.d.ts +10 -11
  172. package/types/nanahoshi-mona-ui-tooltip.d.ts +4 -5
  173. package/types/nanahoshi-mona-ui-window.d.ts +16 -17
  174. package/window/package.json +4 -0
  175. package/fesm2022/nanahoshi-mona-ui-grid-grid-list.component-Dgea-O0X.mjs +0 -130
  176. package/fesm2022/nanahoshi-mona-ui-grid-grid-virtual-list.component-DRHycGIh.mjs +0 -240
@@ -1,7 +1,6 @@
1
1
  import { NgTemplateOutlet, DecimalPipe } from '@angular/common';
2
2
  import * as i0 from '@angular/core';
3
3
  import { inject, TemplateRef, Directive, computed, contentChild, input, Component } from '@angular/core';
4
- import { ThemeService } from '@nanahoshi/mona-ui/theme';
5
4
  import { getPercentage } from '@nanahoshi/mona-ui/common';
6
5
  import { twMerge } from 'tailwind-merge';
7
6
  import { cva } from 'class-variance-authority';
@@ -20,14 +19,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
20
19
  }]
21
20
  }] });
22
21
 
23
- const progressBarBaseVariants = cva(`
22
+ const progressBarBaseThemeVariants = cva(`
24
23
  relative flex items-center justify-center
25
- w-full h-5.5
26
- bg-input-background border border-input-border
24
+ h-5.5 w-full
27
25
  overflow-hidden select-none
26
+ bg-surface-muted
28
27
  data-[disabled='true']:pointer-events-none
29
28
  data-[disabled='true']:cursor-not-allowed
30
- data-[disabled='true']:opacity-50
29
+ data-[disabled='true']:bg-disabled-background
30
+ data-[disabled='true']:text-disabled-foreground
31
+ data-[disabled='true']:[&_[data-prev='true']]:bg-disabled-foreground
31
32
  `, {
32
33
  variants: {
33
34
  rounded: {
@@ -39,29 +40,26 @@ const progressBarBaseVariants = cva(`
39
40
  }
40
41
  }
41
42
  });
42
- const progressBarIndeterminateVariants = cva(`
43
- absolute w-full h-full
44
- flex items-center justify-center
45
- bg-[repeating-linear-gradient(135deg,var(--color-background),var(--color-background)_10px,var(--color-secondary)_10px,var(--color-secondary)_20px)]
43
+ const progressBarIndeterminateThemeVariants = cva(`
44
+ absolute flex h-full w-full items-center justify-center
45
+ bg-[repeating-linear-gradient(135deg,var(--color-surface-muted),var(--color-surface-muted)_10px,var(--color-primary)_10px,var(--color-primary)_20px)]
46
46
  bg-size-[200%_200%]
47
47
  `);
48
- const progressBarLabelVariants = cva(`
48
+ const progressBarLabelThemeVariants = cva(`
49
49
  px-1.5
50
50
  `);
51
- const progressBarTrackVariants = cva(`
52
- relative
53
- flex items-center justify-center
54
- w-full h-full
51
+ const progressBarTrackThemeVariants = cva(`
52
+ relative flex h-full w-full items-center justify-center
55
53
  text-xs font-medium
56
54
  bg-primary text-primary-foreground
57
55
  data-[prev='true']:transition-[background-color]
58
- data-[prev='true']:duration-200
56
+ data-[prev='true']:duration-(--mona-motion-fast)
59
57
  data-[prev='true']:ease-in
60
58
  data-[next='true']:absolute
61
- data-[next='true']:bg-background
59
+ data-[next='true']:bg-surface-muted
62
60
  data-[next='true']:text-foreground
63
61
  data-[next='true']:transition-[clip-path]
64
- data-[next='true']:duration-200
62
+ data-[next='true']:duration-(--mona-motion-fast)
65
63
  data-[next='true']:ease-in
66
64
  data-[value='0']:bg-transparent
67
65
  data-[left='true']:justify-start
@@ -78,39 +76,6 @@ const progressBarTrackVariants = cva(`
78
76
  }
79
77
  });
80
78
 
81
- const progressBarBaseThemeVariants = (theme) => {
82
- switch (theme) {
83
- case "mona":
84
- return progressBarBaseVariants;
85
- default:
86
- return progressBarBaseVariants;
87
- }
88
- };
89
- const progressBarIndeterminateThemeVariants = (theme) => {
90
- switch (theme) {
91
- case "mona":
92
- return progressBarIndeterminateVariants;
93
- default:
94
- return progressBarIndeterminateVariants;
95
- }
96
- };
97
- const progressBarLabelThemeVariants = (theme) => {
98
- switch (theme) {
99
- case "mona":
100
- return progressBarLabelVariants;
101
- default:
102
- return progressBarLabelVariants;
103
- }
104
- };
105
- const progressBarTrackThemeVariants = (theme) => {
106
- switch (theme) {
107
- case "mona":
108
- return progressBarTrackVariants;
109
- default:
110
- return progressBarTrackVariants;
111
- }
112
- };
113
-
114
79
  class ProgressBarComponent {
115
80
  constructor() {
116
81
  this.#color = computed(() => {
@@ -119,23 +84,19 @@ class ProgressBarComponent {
119
84
  return typeof color === "string" ? color : color?.(progress);
120
85
  }, /* @ts-ignore */
121
86
  ...(ngDevMode ? [{ debugName: "#color" }] : /* istanbul ignore next */ []));
122
- this.#themeService = inject(ThemeService);
123
87
  this.baseClasses = computed(() => {
124
- const theme = this.#themeService.theme();
125
88
  const rounded = this.rounded();
126
- const classes = progressBarBaseThemeVariants(theme)({ rounded });
89
+ const classes = progressBarBaseThemeVariants({ rounded });
127
90
  const userClass = this.userClass();
128
91
  return twMerge(classes, userClass);
129
92
  }, /* @ts-ignore */
130
93
  ...(ngDevMode ? [{ debugName: "baseClasses" }] : /* istanbul ignore next */ []));
131
94
  this.indeterminateClasses = computed(() => {
132
- const theme = this.#themeService.theme();
133
- return progressBarIndeterminateThemeVariants(theme)();
95
+ return progressBarIndeterminateThemeVariants();
134
96
  }, /* @ts-ignore */
135
97
  ...(ngDevMode ? [{ debugName: "indeterminateClasses" }] : /* istanbul ignore next */ []));
136
98
  this.labelClasses = computed(() => {
137
- const theme = this.#themeService.theme();
138
- return progressBarLabelThemeVariants(theme)();
99
+ return progressBarLabelThemeVariants();
139
100
  }, /* @ts-ignore */
140
101
  ...(ngDevMode ? [{ debugName: "labelClasses" }] : /* istanbul ignore next */ []));
141
102
  this.labelTemplate = contentChild(ProgressBarLabelTemplateDirective, /* @ts-ignore */
@@ -158,9 +119,8 @@ class ProgressBarComponent {
158
119
  this.progress = computed(() => getPercentage(this.value(), this.min(), this.max()), /* @ts-ignore */
159
120
  ...(ngDevMode ? [{ debugName: "progress" }] : /* istanbul ignore next */ []));
160
121
  this.trackClasses = computed(() => {
161
- const theme = this.#themeService.theme();
162
122
  const rounded = this.rounded();
163
- const classes = progressBarTrackThemeVariants(theme)({ rounded });
123
+ const classes = progressBarTrackThemeVariants({ rounded });
164
124
  return this.animate()
165
125
  ? classes
166
126
  : twMerge(classes, "data-[next='true']:transition-none data-[prev='true']:transition-none");
@@ -262,9 +222,8 @@ class ProgressBarComponent {
262
222
  ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
263
223
  }
264
224
  #color;
265
- #themeService;
266
225
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: ProgressBarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
267
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: ProgressBarComponent, isStandalone: true, selector: "mona-progress-bar", inputs: { ariaLabel: { classPropertyName: "ariaLabel", publicName: "aria-label", isSignal: true, isRequired: false, transformFunction: null }, ariaValueText: { classPropertyName: "ariaValueText", publicName: "aria-valuetext", isSignal: true, isRequired: false, transformFunction: null }, animate: { classPropertyName: "animate", publicName: "animate", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, indeterminate: { classPropertyName: "indeterminate", publicName: "indeterminate", isSignal: true, isRequired: false, transformFunction: null }, labelPosition: { classPropertyName: "labelPosition", publicName: "labelPosition", isSignal: true, isRequired: false, transformFunction: null }, labelStyles: { classPropertyName: "labelStyles", publicName: "labelStyles", isSignal: true, isRequired: false, transformFunction: null }, labelVisible: { classPropertyName: "labelVisible", publicName: "labelVisible", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, rounded: { classPropertyName: "rounded", publicName: "rounded", isSignal: true, isRequired: false, transformFunction: null }, userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "progressbar" }, properties: { "class": "baseClasses()", "attr.aria-busy": "indeterminate() || null", "attr.aria-label": "ariaLabel() || null", "attr.aria-valuemin": "indeterminate() ? null : min()", "attr.aria-valuemax": "indeterminate() ? null : max()", "attr.aria-valuenow": "indeterminate() ? null : value()", "attr.aria-valuetext": "ariaValueText() || null", "attr.aria-disabled": "disabled() || null", "attr.data-disabled": "disabled()" } }, queries: [{ propertyName: "labelTemplate", first: true, predicate: ProgressBarLabelTemplateDirective, descendants: true, isSignal: true }], ngImport: i0, template: "<div\r\n [class]=\"trackClasses()\"\r\n [style.background-color]=\"trackColor()\"\r\n [attr.data-prev]=\"true\"\r\n [attr.data-left]=\"labelPosition() === 'start'\"\r\n [attr.data-right]=\"labelPosition() === 'end'\"\r\n [attr.data-indeterminate]=\"indeterminate()\"\r\n [attr.data-value]=\"progress()\"\r\n [style.clip-path]=\"prevTrackClipPath()\">\r\n @if (indeterminate()) {\r\n <div [class]=\"indeterminateClasses()\" class=\"indeterminate\"></div>\r\n } @else if (labelVisible()) {\r\n @if (labelTemplate()) {\r\n <ng-container\r\n [ngTemplateOutlet]=\"labelTemplate()?.templateRef\"\r\n [ngTemplateOutletContext]=\"{ $implicit: value(), min: min(), max: max(), percent: progress() }\">\r\n </ng-container>\r\n } @else {\r\n <span [class]=\"labelClasses()\" [style]=\"labelStyles()\">{{ progress() | number: \"1.0-2\" }}</span>\r\n }\r\n }\r\n</div>\r\n\r\n@if (!indeterminate()) {\r\n <div\r\n [class]=\"trackClasses()\"\r\n [attr.data-next]=\"true\"\r\n [attr.data-left]=\"labelPosition() === 'start'\"\r\n [attr.data-right]=\"labelPosition() === 'end'\"\r\n [style.clip-path]=\"nextTrackClipPath()\">\r\n @if (labelVisible()) {\r\n @if (labelTemplate()) {\r\n <ng-container\r\n [ngTemplateOutlet]=\"labelTemplate()?.templateRef\"\r\n [ngTemplateOutletContext]=\"{ $implicit: value(), min: min(), max: max(), percent: progress() }\">\r\n </ng-container>\r\n } @else {\r\n <span [class]=\"labelClasses()\" [style]=\"labelStyles()\">{{ progress() | number: \"1.0-2\" }}</span>\r\n }\r\n }\r\n </div>\r\n}\r\n", styles: [".indeterminate{animation:indeterminate 16s linear infinite}@keyframes indeterminate{0%{background-position:0 0}to{background-position:100% 0}}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: DecimalPipe, name: "number" }] }); }
226
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: ProgressBarComponent, isStandalone: true, selector: "mona-progress-bar", inputs: { ariaLabel: { classPropertyName: "ariaLabel", publicName: "aria-label", isSignal: true, isRequired: false, transformFunction: null }, ariaValueText: { classPropertyName: "ariaValueText", publicName: "aria-valuetext", isSignal: true, isRequired: false, transformFunction: null }, animate: { classPropertyName: "animate", publicName: "animate", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, indeterminate: { classPropertyName: "indeterminate", publicName: "indeterminate", isSignal: true, isRequired: false, transformFunction: null }, labelPosition: { classPropertyName: "labelPosition", publicName: "labelPosition", isSignal: true, isRequired: false, transformFunction: null }, labelStyles: { classPropertyName: "labelStyles", publicName: "labelStyles", isSignal: true, isRequired: false, transformFunction: null }, labelVisible: { classPropertyName: "labelVisible", publicName: "labelVisible", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, rounded: { classPropertyName: "rounded", publicName: "rounded", isSignal: true, isRequired: false, transformFunction: null }, userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "progressbar" }, properties: { "class": "baseClasses()", "attr.aria-busy": "indeterminate() || null", "attr.aria-label": "ariaLabel() || null", "attr.aria-valuemin": "indeterminate() ? null : min()", "attr.aria-valuemax": "indeterminate() ? null : max()", "attr.aria-valuenow": "indeterminate() ? null : value()", "attr.aria-valuetext": "ariaValueText() || null", "attr.aria-disabled": "disabled() || null", "attr.data-disabled": "disabled()" } }, queries: [{ propertyName: "labelTemplate", first: true, predicate: ProgressBarLabelTemplateDirective, descendants: true, isSignal: true }], ngImport: i0, template: "<div\n [class]=\"trackClasses()\"\n [style.background-color]=\"trackColor()\"\n [attr.data-prev]=\"true\"\n [attr.data-left]=\"labelPosition() === 'start'\"\n [attr.data-right]=\"labelPosition() === 'end'\"\n [attr.data-indeterminate]=\"indeterminate()\"\n [attr.data-value]=\"progress()\"\n [style.clip-path]=\"prevTrackClipPath()\">\n @if (indeterminate()) {\n <div [class]=\"indeterminateClasses()\" class=\"indeterminate\"></div>\n } @else if (labelVisible()) {\n @if (labelTemplate()) {\n <ng-container\n [ngTemplateOutlet]=\"labelTemplate()?.templateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: value(), min: min(), max: max(), percent: progress() }\">\n </ng-container>\n } @else {\n <span [class]=\"labelClasses()\" [style]=\"labelStyles()\">{{ progress() | number: \"1.0-2\" }}</span>\n }\n }\n</div>\n\n@if (!indeterminate()) {\n <div\n [class]=\"trackClasses()\"\n [attr.data-next]=\"true\"\n [attr.data-left]=\"labelPosition() === 'start'\"\n [attr.data-right]=\"labelPosition() === 'end'\"\n [style.clip-path]=\"nextTrackClipPath()\">\n @if (labelVisible()) {\n @if (labelTemplate()) {\n <ng-container\n [ngTemplateOutlet]=\"labelTemplate()?.templateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: value(), min: min(), max: max(), percent: progress() }\">\n </ng-container>\n } @else {\n <span [class]=\"labelClasses()\" [style]=\"labelStyles()\">{{ progress() | number: \"1.0-2\" }}</span>\n }\n }\n </div>\n}\n", styles: [".indeterminate{animation:indeterminate 16s linear infinite}@keyframes indeterminate{0%{background-position:0 0}to{background-position:100% 0}}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "pipe", type: DecimalPipe, name: "number" }] }); }
268
227
  }
269
228
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: ProgressBarComponent, decorators: [{
270
229
  type: Component,
@@ -279,7 +238,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImpor
279
238
  "[attr.aria-disabled]": "disabled() || null",
280
239
  "[attr.data-disabled]": "disabled()",
281
240
  role: "progressbar"
282
- }, template: "<div\r\n [class]=\"trackClasses()\"\r\n [style.background-color]=\"trackColor()\"\r\n [attr.data-prev]=\"true\"\r\n [attr.data-left]=\"labelPosition() === 'start'\"\r\n [attr.data-right]=\"labelPosition() === 'end'\"\r\n [attr.data-indeterminate]=\"indeterminate()\"\r\n [attr.data-value]=\"progress()\"\r\n [style.clip-path]=\"prevTrackClipPath()\">\r\n @if (indeterminate()) {\r\n <div [class]=\"indeterminateClasses()\" class=\"indeterminate\"></div>\r\n } @else if (labelVisible()) {\r\n @if (labelTemplate()) {\r\n <ng-container\r\n [ngTemplateOutlet]=\"labelTemplate()?.templateRef\"\r\n [ngTemplateOutletContext]=\"{ $implicit: value(), min: min(), max: max(), percent: progress() }\">\r\n </ng-container>\r\n } @else {\r\n <span [class]=\"labelClasses()\" [style]=\"labelStyles()\">{{ progress() | number: \"1.0-2\" }}</span>\r\n }\r\n }\r\n</div>\r\n\r\n@if (!indeterminate()) {\r\n <div\r\n [class]=\"trackClasses()\"\r\n [attr.data-next]=\"true\"\r\n [attr.data-left]=\"labelPosition() === 'start'\"\r\n [attr.data-right]=\"labelPosition() === 'end'\"\r\n [style.clip-path]=\"nextTrackClipPath()\">\r\n @if (labelVisible()) {\r\n @if (labelTemplate()) {\r\n <ng-container\r\n [ngTemplateOutlet]=\"labelTemplate()?.templateRef\"\r\n [ngTemplateOutletContext]=\"{ $implicit: value(), min: min(), max: max(), percent: progress() }\">\r\n </ng-container>\r\n } @else {\r\n <span [class]=\"labelClasses()\" [style]=\"labelStyles()\">{{ progress() | number: \"1.0-2\" }}</span>\r\n }\r\n }\r\n </div>\r\n}\r\n", styles: [".indeterminate{animation:indeterminate 16s linear infinite}@keyframes indeterminate{0%{background-position:0 0}to{background-position:100% 0}}\n"] }]
241
+ }, template: "<div\n [class]=\"trackClasses()\"\n [style.background-color]=\"trackColor()\"\n [attr.data-prev]=\"true\"\n [attr.data-left]=\"labelPosition() === 'start'\"\n [attr.data-right]=\"labelPosition() === 'end'\"\n [attr.data-indeterminate]=\"indeterminate()\"\n [attr.data-value]=\"progress()\"\n [style.clip-path]=\"prevTrackClipPath()\">\n @if (indeterminate()) {\n <div [class]=\"indeterminateClasses()\" class=\"indeterminate\"></div>\n } @else if (labelVisible()) {\n @if (labelTemplate()) {\n <ng-container\n [ngTemplateOutlet]=\"labelTemplate()?.templateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: value(), min: min(), max: max(), percent: progress() }\">\n </ng-container>\n } @else {\n <span [class]=\"labelClasses()\" [style]=\"labelStyles()\">{{ progress() | number: \"1.0-2\" }}</span>\n }\n }\n</div>\n\n@if (!indeterminate()) {\n <div\n [class]=\"trackClasses()\"\n [attr.data-next]=\"true\"\n [attr.data-left]=\"labelPosition() === 'start'\"\n [attr.data-right]=\"labelPosition() === 'end'\"\n [style.clip-path]=\"nextTrackClipPath()\">\n @if (labelVisible()) {\n @if (labelTemplate()) {\n <ng-container\n [ngTemplateOutlet]=\"labelTemplate()?.templateRef\"\n [ngTemplateOutletContext]=\"{ $implicit: value(), min: min(), max: max(), percent: progress() }\">\n </ng-container>\n } @else {\n <span [class]=\"labelClasses()\" [style]=\"labelStyles()\">{{ progress() | number: \"1.0-2\" }}</span>\n }\n }\n </div>\n}\n", styles: [".indeterminate{animation:indeterminate 16s linear infinite}@keyframes indeterminate{0%{background-position:0 0}to{background-position:100% 0}}\n"] }]
283
242
  }], propDecorators: { labelTemplate: [{ type: i0.ContentChild, args: [i0.forwardRef(() => ProgressBarLabelTemplateDirective), { isSignal: true }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "aria-label", required: false }] }], ariaValueText: [{ type: i0.Input, args: [{ isSignal: true, alias: "aria-valuetext", required: false }] }], animate: [{ type: i0.Input, args: [{ isSignal: true, alias: "animate", required: false }] }], color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], indeterminate: [{ type: i0.Input, args: [{ isSignal: true, alias: "indeterminate", required: false }] }], labelPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "labelPosition", required: false }] }], labelStyles: [{ type: i0.Input, args: [{ isSignal: true, alias: "labelStyles", required: false }] }], labelVisible: [{ type: i0.Input, args: [{ isSignal: true, alias: "labelVisible", required: false }] }], max: [{ type: i0.Input, args: [{ isSignal: true, alias: "max", required: false }] }], min: [{ type: i0.Input, args: [{ isSignal: true, alias: "min", required: false }] }], rounded: [{ type: i0.Input, args: [{ isSignal: true, alias: "rounded", required: false }] }], userClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }] } });
284
243
 
285
244
  /*
@@ -1,32 +1,34 @@
1
1
  import { NgTemplateOutlet } from '@angular/common';
2
2
  import * as i0 from '@angular/core';
3
- import { inject, computed, input, output, model, Component, Directive } from '@angular/core';
3
+ import { computed, input, output, model, Component, Directive } from '@angular/core';
4
4
  import { FormsModule } from '@angular/forms';
5
5
  import { twMerge } from 'tailwind-merge';
6
- import { ThemeService } from '@nanahoshi/mona-ui/theme';
7
6
  import { cva } from 'class-variance-authority';
7
+ import { themeControlSurfaceClasses } from '@nanahoshi/mona-ui/internal';
8
8
 
9
- const radioButtonVariants = cva(`
10
- appearance-none outline-none
11
- peer absolute inset-0 w-full h-full
12
- opacity-0 cursor-pointer z-10
13
- focus:ring-2 focus:ring-primary focus:ring-offset-2
14
- disabled:cursor-not-allowed
9
+ const radioButtonThemeVariants = cva(`
10
+ peer absolute inset-0 z-10 h-full w-full
11
+ cursor-pointer appearance-none opacity-0
12
+ outline-none
13
+ disabled:cursor-not-allowed
15
14
  `);
16
- const radioButtonCircleVariants = cva(`
17
- w-4.5 h-4.5
18
- flex items-center justify-center
19
- overflow-hidden
20
- bg-input-background
21
- border border-input-border
22
- cursor-pointer
23
- relative
24
- transition-colors duration-200
25
- peer-focus:ring-2 peer-focus:ring-primary/40
26
- peer-disabled:opacity-50 peer-disabled:cursor-not-allowed
27
-
28
- data-[invalid='true']:border-error
29
- data-[invalid='true']:ring-2 data-[invalid='true']:ring-error/40
15
+ const radioButtonCircleThemeVariants = cva(`
16
+ relative flex h-4.5 w-4.5 items-center justify-center
17
+ cursor-pointer overflow-hidden
18
+ ${themeControlSurfaceClasses}
19
+ border border-input-border
20
+ transition-colors duration-(--mona-motion-fast)
21
+
22
+ peer-disabled:cursor-not-allowed
23
+ peer-disabled:border-disabled-border peer-disabled:bg-disabled-background peer-disabled:text-disabled-foreground
24
+
25
+ peer-focus-visible:border-focus-indicator
26
+ peer-focus-visible:ring-2 peer-focus-visible:ring-focus-indicator/35
27
+
28
+ data-[invalid='true']:border-error
29
+ data-[invalid='true']:ring-2 data-[invalid='true']:ring-error/35
30
+ data-[invalid='true']:peer-focus-visible:border-error
31
+ data-[invalid='true']:peer-focus-visible:ring-error/35
30
32
  `, {
31
33
  variants: {
32
34
  rounded: {
@@ -38,8 +40,10 @@ const radioButtonCircleVariants = cva(`
38
40
  }
39
41
  }
40
42
  });
41
- const radioButtonIndicatorVariants = cva(`
42
- flex w-3 h-3 bg-primary transition-all duration-200
43
+ const radioButtonIndicatorThemeVariants = cva(`
44
+ flex h-3 w-3
45
+ bg-primary
46
+ transition-all duration-(--mona-motion-fast)
43
47
  `, {
44
48
  variants: {
45
49
  rounded: {
@@ -51,13 +55,12 @@ const radioButtonIndicatorVariants = cva(`
51
55
  }
52
56
  }
53
57
  });
54
- const radioButtonContainerLabelVariants = cva(`
55
- w-full h-full flex items-center justify-center gap-1
56
- relative
57
- cursor-pointer
58
- data-[disabled='true']:pointer-events-none
59
- data-[disabled='true']:cursor-not-allowed
60
- data-[disabled='true']:opacity-50
58
+ const radioButtonContainerLabelThemeVariants = cva(`
59
+ relative flex h-full w-full items-center justify-center gap-1
60
+ cursor-pointer
61
+ data-[disabled='true']:pointer-events-none
62
+ data-[disabled='true']:cursor-not-allowed
63
+ data-[disabled='true']:text-disabled-foreground
61
64
  `, {
62
65
  variants: {
63
66
  labelSize: {
@@ -70,30 +73,31 @@ const radioButtonContainerLabelVariants = cva(`
70
73
  labelSize: "medium"
71
74
  }
72
75
  });
73
- const radioButtonDirectiveVariants = cva(`
74
- appearance-none outline-none
75
- w-4.5 h-4.5
76
- bg-input-background border border-input-border
77
- cursor-pointer
78
- relative
79
- place-content-center
80
- flex items-center justify-center
81
-
82
- disabled:pointer-events-none
83
- disabled:cursor-not-allowed
84
- disabled:opacity-50
85
-
86
- after:content-['']
87
- after:w-3 after:h-3
88
- after:inline-grid
89
- after:place-content-center
90
-
91
- checked:after:bg-primary
92
- checked:after:rounded-full
93
-
94
- focus-visible:ring-2 focus-visible:ring-primary/40
95
-
96
- [&.ng-touched.ng-invalid]:border-error
76
+ const radioButtonDirectiveThemeVariants = cva(`
77
+ relative flex h-4.5 w-4.5 items-center justify-center place-content-center
78
+ cursor-pointer appearance-none
79
+ ${themeControlSurfaceClasses}
80
+ border border-input-border
81
+ outline-none
82
+
83
+ disabled:pointer-events-none disabled:cursor-not-allowed
84
+ disabled:border-disabled-border disabled:bg-disabled-background disabled:text-disabled-foreground
85
+
86
+ after:inline-grid
87
+ after:h-3 after:w-3
88
+ after:place-content-center
89
+ after:content-['']
90
+
91
+ checked:after:bg-primary
92
+ checked:after:rounded-full
93
+
94
+ focus-visible:border-focus-indicator
95
+ focus-visible:ring-2 focus-visible:ring-focus-indicator/35
96
+
97
+ [&.ng-touched.ng-invalid]:border-error
98
+ [&.ng-touched.ng-invalid]:ring-2 [&.ng-touched.ng-invalid]:ring-error/35
99
+ [&.ng-touched.ng-invalid]:focus-visible:border-error
100
+ [&.ng-touched.ng-invalid]:focus-visible:ring-error/35
97
101
  `, {
98
102
  variants: {
99
103
  rounded: {
@@ -128,70 +132,25 @@ const radioButtonDirectiveVariants = cva(`
128
132
  ]
129
133
  });
130
134
 
131
- const radioButtonThemeVariants = (theme) => {
132
- switch (theme) {
133
- case "mona":
134
- return radioButtonVariants;
135
- default:
136
- return radioButtonVariants; // Default to Mona styles
137
- }
138
- };
139
- const radioButtonCircleThemeVariants = (theme) => {
140
- switch (theme) {
141
- case "mona":
142
- return radioButtonCircleVariants;
143
- default:
144
- return radioButtonCircleVariants; // Default to Mona styles
145
- }
146
- };
147
- const radioButtonIndicatorThemeVariants = (theme) => {
148
- switch (theme) {
149
- case "mona":
150
- return radioButtonIndicatorVariants;
151
- default:
152
- return radioButtonIndicatorVariants; // Default to Mona styles
153
- }
154
- };
155
- const radioButtonContainerLabelThemeVariants = (theme) => {
156
- switch (theme) {
157
- case "mona":
158
- return radioButtonContainerLabelVariants;
159
- default:
160
- return radioButtonContainerLabelVariants; // Default to Mona styles
161
- }
162
- };
163
- const radioButtonDirectiveThemeVariants = (theme) => {
164
- switch (theme) {
165
- case "mona":
166
- return radioButtonDirectiveVariants;
167
- default:
168
- return radioButtonDirectiveVariants; // Default to Mona styles
169
- }
170
- };
171
-
172
135
  class RadioButtonComponent {
173
136
  constructor() {
174
- this.#themeService = inject(ThemeService);
175
137
  this.containerLabelClasses = computed(() => {
176
- const theme = this.#themeService.theme();
177
138
  const labelSize = this.labelSize();
178
139
  const userClasses = this.userClass();
179
- const variantClasses = radioButtonContainerLabelThemeVariants(theme)({ labelSize });
140
+ const variantClasses = radioButtonContainerLabelThemeVariants({ labelSize });
180
141
  return twMerge(variantClasses, userClasses);
181
142
  }, /* @ts-ignore */
182
143
  ...(ngDevMode ? [{ debugName: "containerLabelClasses" }] : /* istanbul ignore next */ []));
183
144
  this.radioButtonCircleClasses = computed(() => {
184
- const theme = this.#themeService.theme();
185
145
  const rounded = this.rounded();
186
- return radioButtonCircleThemeVariants(theme)({ rounded });
146
+ return radioButtonCircleThemeVariants({ rounded });
187
147
  }, /* @ts-ignore */
188
148
  ...(ngDevMode ? [{ debugName: "radioButtonCircleClasses" }] : /* istanbul ignore next */ []));
189
- this.radioButtonClasses = computed(() => radioButtonThemeVariants(this.#themeService.theme())(), /* @ts-ignore */
149
+ this.radioButtonClasses = computed(() => radioButtonThemeVariants(), /* @ts-ignore */
190
150
  ...(ngDevMode ? [{ debugName: "radioButtonClasses" }] : /* istanbul ignore next */ []));
191
151
  this.radioButtonIndicatorClasses = computed(() => {
192
- const theme = this.#themeService.theme();
193
152
  const rounded = this.rounded();
194
- return radioButtonIndicatorThemeVariants(theme)({ rounded });
153
+ return radioButtonIndicatorThemeVariants({ rounded });
195
154
  }, /* @ts-ignore */
196
155
  ...(ngDevMode ? [{ debugName: "radioButtonIndicatorClasses" }] : /* istanbul ignore next */ []));
197
156
  /**
@@ -276,7 +235,6 @@ class RadioButtonComponent {
276
235
  this.value = model(undefined, /* @ts-ignore */
277
236
  ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
278
237
  }
279
- #themeService;
280
238
  onBlur(event) {
281
239
  this.inputBlur.emit(event);
282
240
  this.touch.emit();
@@ -286,23 +244,21 @@ class RadioButtonComponent {
286
244
  this.touch.emit();
287
245
  }
288
246
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: RadioButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
289
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: RadioButtonComponent, isStandalone: true, selector: "mona-radio-button", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, labelPosition: { classPropertyName: "labelPosition", publicName: "labelPosition", isSignal: true, isRequired: false, transformFunction: null }, labelSize: { classPropertyName: "labelSize", publicName: "labelSize", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, radioValue: { classPropertyName: "radioValue", publicName: "radioValue", isSignal: true, isRequired: false, transformFunction: null }, rounded: { classPropertyName: "rounded", publicName: "rounded", isSignal: true, isRequired: false, transformFunction: null }, userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { inputBlur: "inputBlur", inputClick: "inputClick", inputFocus: "inputFocus", touch: "touch", value: "valueChange" }, host: { properties: { "attr.data-selected": "radioValue()===value()", "attr.data-disabled": "disabled()" } }, ngImport: i0, template: "<label [class]=\"containerLabelClasses()\" [attr.data-disabled]=\"disabled()\">\r\n @if (labelPosition() === \"before\") {\r\n <ng-container [ngTemplateOutlet]=\"labelTemplate\"></ng-container>\r\n }\r\n <input\r\n type=\"radio\"\r\n [disabled]=\"disabled()\"\r\n [name]=\"name()\"\r\n [value]=\"radioValue()\"\r\n [class]=\"radioButtonClasses()\"\r\n [checked]=\"radioValue() === value()\"\r\n [attr.aria-invalid]=\"invalid() ? 'true' : null\"\r\n (blur)=\"onBlur($event)\"\r\n (click)=\"inputClick.emit($event)\"\r\n (focus)=\"inputFocus.emit($event)\"\r\n (change)=\"onSelectionChange()\" />\r\n <span [class]=\"radioButtonCircleClasses()\" [attr.data-invalid]=\"invalid() || null\">\r\n @if (radioValue() === value()) {\r\n <span [class]=\"radioButtonIndicatorClasses()\"></span>\r\n }\r\n </span>\r\n @if (labelPosition() === \"after\") {\r\n <ng-container [ngTemplateOutlet]=\"labelTemplate\"></ng-container>\r\n }\r\n</label>\r\n\r\n<ng-template #labelTemplate>\r\n @if (label()) {\r\n <span>{{ label() }}</span>\r\n } @else {\r\n <ng-content></ng-content>\r\n }\r\n</ng-template>\r\n", dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] }); }
247
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.6", type: RadioButtonComponent, isStandalone: true, selector: "mona-radio-button", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, labelPosition: { classPropertyName: "labelPosition", publicName: "labelPosition", isSignal: true, isRequired: false, transformFunction: null }, labelSize: { classPropertyName: "labelSize", publicName: "labelSize", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, radioValue: { classPropertyName: "radioValue", publicName: "radioValue", isSignal: true, isRequired: false, transformFunction: null }, rounded: { classPropertyName: "rounded", publicName: "rounded", isSignal: true, isRequired: false, transformFunction: null }, userClass: { classPropertyName: "userClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { inputBlur: "inputBlur", inputClick: "inputClick", inputFocus: "inputFocus", touch: "touch", value: "valueChange" }, host: { properties: { "attr.data-selected": "radioValue()===value()", "attr.data-disabled": "disabled()" } }, ngImport: i0, template: "<label [class]=\"containerLabelClasses()\" [attr.data-disabled]=\"disabled()\">\n @if (labelPosition() === \"before\") {\n <ng-container [ngTemplateOutlet]=\"labelTemplate\"></ng-container>\n }\n <input\n type=\"radio\"\n [disabled]=\"disabled()\"\n [name]=\"name()\"\n [value]=\"radioValue()\"\n [class]=\"radioButtonClasses()\"\n [checked]=\"radioValue() === value()\"\n [attr.aria-invalid]=\"invalid() ? 'true' : null\"\n (blur)=\"onBlur($event)\"\n (click)=\"inputClick.emit($event)\"\n (focus)=\"inputFocus.emit($event)\"\n (change)=\"onSelectionChange()\" />\n <span [class]=\"radioButtonCircleClasses()\" [attr.data-invalid]=\"invalid() || null\">\n @if (radioValue() === value()) {\n <span [class]=\"radioButtonIndicatorClasses()\"></span>\n }\n </span>\n @if (labelPosition() === \"after\") {\n <ng-container [ngTemplateOutlet]=\"labelTemplate\"></ng-container>\n }\n</label>\n\n<ng-template #labelTemplate>\n @if (label()) {\n <span>{{ label() }}</span>\n } @else {\n <ng-content></ng-content>\n }\n</ng-template>\n", dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] }); }
290
248
  }
291
249
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: RadioButtonComponent, decorators: [{
292
250
  type: Component,
293
251
  args: [{ selector: "mona-radio-button", imports: [FormsModule, NgTemplateOutlet], host: {
294
252
  "[attr.data-selected]": "radioValue()===value()",
295
253
  "[attr.data-disabled]": "disabled()"
296
- }, template: "<label [class]=\"containerLabelClasses()\" [attr.data-disabled]=\"disabled()\">\r\n @if (labelPosition() === \"before\") {\r\n <ng-container [ngTemplateOutlet]=\"labelTemplate\"></ng-container>\r\n }\r\n <input\r\n type=\"radio\"\r\n [disabled]=\"disabled()\"\r\n [name]=\"name()\"\r\n [value]=\"radioValue()\"\r\n [class]=\"radioButtonClasses()\"\r\n [checked]=\"radioValue() === value()\"\r\n [attr.aria-invalid]=\"invalid() ? 'true' : null\"\r\n (blur)=\"onBlur($event)\"\r\n (click)=\"inputClick.emit($event)\"\r\n (focus)=\"inputFocus.emit($event)\"\r\n (change)=\"onSelectionChange()\" />\r\n <span [class]=\"radioButtonCircleClasses()\" [attr.data-invalid]=\"invalid() || null\">\r\n @if (radioValue() === value()) {\r\n <span [class]=\"radioButtonIndicatorClasses()\"></span>\r\n }\r\n </span>\r\n @if (labelPosition() === \"after\") {\r\n <ng-container [ngTemplateOutlet]=\"labelTemplate\"></ng-container>\r\n }\r\n</label>\r\n\r\n<ng-template #labelTemplate>\r\n @if (label()) {\r\n <span>{{ label() }}</span>\r\n } @else {\r\n <ng-content></ng-content>\r\n }\r\n</ng-template>\r\n" }]
254
+ }, template: "<label [class]=\"containerLabelClasses()\" [attr.data-disabled]=\"disabled()\">\n @if (labelPosition() === \"before\") {\n <ng-container [ngTemplateOutlet]=\"labelTemplate\"></ng-container>\n }\n <input\n type=\"radio\"\n [disabled]=\"disabled()\"\n [name]=\"name()\"\n [value]=\"radioValue()\"\n [class]=\"radioButtonClasses()\"\n [checked]=\"radioValue() === value()\"\n [attr.aria-invalid]=\"invalid() ? 'true' : null\"\n (blur)=\"onBlur($event)\"\n (click)=\"inputClick.emit($event)\"\n (focus)=\"inputFocus.emit($event)\"\n (change)=\"onSelectionChange()\" />\n <span [class]=\"radioButtonCircleClasses()\" [attr.data-invalid]=\"invalid() || null\">\n @if (radioValue() === value()) {\n <span [class]=\"radioButtonIndicatorClasses()\"></span>\n }\n </span>\n @if (labelPosition() === \"after\") {\n <ng-container [ngTemplateOutlet]=\"labelTemplate\"></ng-container>\n }\n</label>\n\n<ng-template #labelTemplate>\n @if (label()) {\n <span>{{ label() }}</span>\n } @else {\n <ng-content></ng-content>\n }\n</ng-template>\n" }]
297
255
  }], propDecorators: { disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], inputBlur: [{ type: i0.Output, args: ["inputBlur"] }], inputClick: [{ type: i0.Output, args: ["inputClick"] }], inputFocus: [{ type: i0.Output, args: ["inputFocus"] }], invalid: [{ type: i0.Input, args: [{ isSignal: true, alias: "invalid", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], labelPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "labelPosition", required: false }] }], labelSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "labelSize", required: false }] }], name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: false }] }], radioValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "radioValue", required: false }] }], rounded: [{ type: i0.Input, args: [{ isSignal: true, alias: "rounded", required: false }] }], touch: [{ type: i0.Output, args: ["touch"] }], userClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }] } });
298
256
 
299
257
  class RadioButtonDirective {
300
258
  constructor() {
301
- this.#themeService = inject(ThemeService);
302
259
  this.classes = computed(() => {
303
- const theme = this.#themeService.theme();
304
260
  const rounded = this.rounded();
305
- return radioButtonDirectiveThemeVariants(theme)({ rounded });
261
+ return radioButtonDirectiveThemeVariants({ rounded });
306
262
  }, /* @ts-ignore */
307
263
  ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
308
264
  /**
@@ -312,7 +268,6 @@ class RadioButtonDirective {
312
268
  this.rounded = input("none", /* @ts-ignore */
313
269
  ...(ngDevMode ? [{ debugName: "rounded" }] : /* istanbul ignore next */ []));
314
270
  }
315
- #themeService;
316
271
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.6", ngImport: i0, type: RadioButtonDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
317
272
  static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.0.6", type: RadioButtonDirective, isStandalone: true, selector: "input[type='radio'][monaRadioButton]", inputs: { rounded: { classPropertyName: "rounded", publicName: "rounded", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.role": "'radio'" } }, ngImport: i0 }); }
318
273
  }