@ojiepermana/angular-component 22.0.27

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 (244) hide show
  1. package/README.md +82 -0
  2. package/accordion/README.md +193 -0
  3. package/alert/README.md +180 -0
  4. package/alert-dialog/README.md +239 -0
  5. package/aspect-ratio/README.md +112 -0
  6. package/avatar/README.md +176 -0
  7. package/badge/README.md +133 -0
  8. package/breadcrumb/README.md +216 -0
  9. package/button/README.md +139 -0
  10. package/button-group/README.md +208 -0
  11. package/calendar/README.md +135 -0
  12. package/card/README.md +220 -0
  13. package/carousel/README.md +276 -0
  14. package/checkbox/README.md +149 -0
  15. package/collapsible/README.md +195 -0
  16. package/combobox/README.md +198 -0
  17. package/command/README.md +275 -0
  18. package/composer/README.md +235 -0
  19. package/context-menu/README.md +267 -0
  20. package/date-picker/README.md +179 -0
  21. package/dialog/README.md +235 -0
  22. package/drawer/README.md +145 -0
  23. package/dropdown-menu/README.md +311 -0
  24. package/editor/README.md +136 -0
  25. package/empty/README.md +183 -0
  26. package/fesm2022/ojiepermana-angular-component-accordion.mjs +186 -0
  27. package/fesm2022/ojiepermana-angular-component-accordion.mjs.map +1 -0
  28. package/fesm2022/ojiepermana-angular-component-alert-dialog.mjs +276 -0
  29. package/fesm2022/ojiepermana-angular-component-alert-dialog.mjs.map +1 -0
  30. package/fesm2022/ojiepermana-angular-component-alert.mjs +99 -0
  31. package/fesm2022/ojiepermana-angular-component-alert.mjs.map +1 -0
  32. package/fesm2022/ojiepermana-angular-component-aspect-ratio.mjs +37 -0
  33. package/fesm2022/ojiepermana-angular-component-aspect-ratio.mjs.map +1 -0
  34. package/fesm2022/ojiepermana-angular-component-avatar.mjs +139 -0
  35. package/fesm2022/ojiepermana-angular-component-avatar.mjs.map +1 -0
  36. package/fesm2022/ojiepermana-angular-component-badge.mjs +50 -0
  37. package/fesm2022/ojiepermana-angular-component-badge.mjs.map +1 -0
  38. package/fesm2022/ojiepermana-angular-component-breadcrumb.mjs +200 -0
  39. package/fesm2022/ojiepermana-angular-component-breadcrumb.mjs.map +1 -0
  40. package/fesm2022/ojiepermana-angular-component-button-group.mjs +103 -0
  41. package/fesm2022/ojiepermana-angular-component-button-group.mjs.map +1 -0
  42. package/fesm2022/ojiepermana-angular-component-button.mjs +68 -0
  43. package/fesm2022/ojiepermana-angular-component-button.mjs.map +1 -0
  44. package/fesm2022/ojiepermana-angular-component-calendar.mjs +103 -0
  45. package/fesm2022/ojiepermana-angular-component-calendar.mjs.map +1 -0
  46. package/fesm2022/ojiepermana-angular-component-card.mjs +152 -0
  47. package/fesm2022/ojiepermana-angular-component-card.mjs.map +1 -0
  48. package/fesm2022/ojiepermana-angular-component-carousel.mjs +334 -0
  49. package/fesm2022/ojiepermana-angular-component-carousel.mjs.map +1 -0
  50. package/fesm2022/ojiepermana-angular-component-checkbox.mjs +165 -0
  51. package/fesm2022/ojiepermana-angular-component-checkbox.mjs.map +1 -0
  52. package/fesm2022/ojiepermana-angular-component-collapsible.mjs +121 -0
  53. package/fesm2022/ojiepermana-angular-component-collapsible.mjs.map +1 -0
  54. package/fesm2022/ojiepermana-angular-component-combobox.mjs +274 -0
  55. package/fesm2022/ojiepermana-angular-component-combobox.mjs.map +1 -0
  56. package/fesm2022/ojiepermana-angular-component-command.mjs +297 -0
  57. package/fesm2022/ojiepermana-angular-component-command.mjs.map +1 -0
  58. package/fesm2022/ojiepermana-angular-component-composer.mjs +352 -0
  59. package/fesm2022/ojiepermana-angular-component-composer.mjs.map +1 -0
  60. package/fesm2022/ojiepermana-angular-component-context-menu.mjs +108 -0
  61. package/fesm2022/ojiepermana-angular-component-context-menu.mjs.map +1 -0
  62. package/fesm2022/ojiepermana-angular-component-date-picker.mjs +186 -0
  63. package/fesm2022/ojiepermana-angular-component-date-picker.mjs.map +1 -0
  64. package/fesm2022/ojiepermana-angular-component-dialog.mjs +283 -0
  65. package/fesm2022/ojiepermana-angular-component-dialog.mjs.map +1 -0
  66. package/fesm2022/ojiepermana-angular-component-drawer.mjs +6 -0
  67. package/fesm2022/ojiepermana-angular-component-drawer.mjs.map +1 -0
  68. package/fesm2022/ojiepermana-angular-component-dropdown-menu.mjs +494 -0
  69. package/fesm2022/ojiepermana-angular-component-dropdown-menu.mjs.map +1 -0
  70. package/fesm2022/ojiepermana-angular-component-editor.mjs +680 -0
  71. package/fesm2022/ojiepermana-angular-component-editor.mjs.map +1 -0
  72. package/fesm2022/ojiepermana-angular-component-empty.mjs +145 -0
  73. package/fesm2022/ojiepermana-angular-component-empty.mjs.map +1 -0
  74. package/fesm2022/ojiepermana-angular-component-form.mjs +364 -0
  75. package/fesm2022/ojiepermana-angular-component-form.mjs.map +1 -0
  76. package/fesm2022/ojiepermana-angular-component-hover-card.mjs +275 -0
  77. package/fesm2022/ojiepermana-angular-component-hover-card.mjs.map +1 -0
  78. package/fesm2022/ojiepermana-angular-component-icon.mjs +86 -0
  79. package/fesm2022/ojiepermana-angular-component-icon.mjs.map +1 -0
  80. package/fesm2022/ojiepermana-angular-component-input-group.mjs +179 -0
  81. package/fesm2022/ojiepermana-angular-component-input-group.mjs.map +1 -0
  82. package/fesm2022/ojiepermana-angular-component-input-otp.mjs +517 -0
  83. package/fesm2022/ojiepermana-angular-component-input-otp.mjs.map +1 -0
  84. package/fesm2022/ojiepermana-angular-component-input.mjs +45 -0
  85. package/fesm2022/ojiepermana-angular-component-input.mjs.map +1 -0
  86. package/fesm2022/ojiepermana-angular-component-item.mjs +264 -0
  87. package/fesm2022/ojiepermana-angular-component-item.mjs.map +1 -0
  88. package/fesm2022/ojiepermana-angular-component-kanban.mjs +314 -0
  89. package/fesm2022/ojiepermana-angular-component-kanban.mjs.map +1 -0
  90. package/fesm2022/ojiepermana-angular-component-kbd.mjs +55 -0
  91. package/fesm2022/ojiepermana-angular-component-kbd.mjs.map +1 -0
  92. package/fesm2022/ojiepermana-angular-component-label.mjs +33 -0
  93. package/fesm2022/ojiepermana-angular-component-label.mjs.map +1 -0
  94. package/fesm2022/ojiepermana-angular-component-menubar.mjs +311 -0
  95. package/fesm2022/ojiepermana-angular-component-menubar.mjs.map +1 -0
  96. package/fesm2022/ojiepermana-angular-component-native-select.mjs +67 -0
  97. package/fesm2022/ojiepermana-angular-component-native-select.mjs.map +1 -0
  98. package/fesm2022/ojiepermana-angular-component-navigation-menu.mjs +408 -0
  99. package/fesm2022/ojiepermana-angular-component-navigation-menu.mjs.map +1 -0
  100. package/fesm2022/ojiepermana-angular-component-pagination.mjs +226 -0
  101. package/fesm2022/ojiepermana-angular-component-pagination.mjs.map +1 -0
  102. package/fesm2022/ojiepermana-angular-component-pillbox.mjs +810 -0
  103. package/fesm2022/ojiepermana-angular-component-pillbox.mjs.map +1 -0
  104. package/fesm2022/ojiepermana-angular-component-popover.mjs +145 -0
  105. package/fesm2022/ojiepermana-angular-component-popover.mjs.map +1 -0
  106. package/fesm2022/ojiepermana-angular-component-progress.mjs +60 -0
  107. package/fesm2022/ojiepermana-angular-component-progress.mjs.map +1 -0
  108. package/fesm2022/ojiepermana-angular-component-radio.mjs +173 -0
  109. package/fesm2022/ojiepermana-angular-component-radio.mjs.map +1 -0
  110. package/fesm2022/ojiepermana-angular-component-resizable.mjs +478 -0
  111. package/fesm2022/ojiepermana-angular-component-resizable.mjs.map +1 -0
  112. package/fesm2022/ojiepermana-angular-component-scroll-area.mjs +54 -0
  113. package/fesm2022/ojiepermana-angular-component-scroll-area.mjs.map +1 -0
  114. package/fesm2022/ojiepermana-angular-component-select.mjs +297 -0
  115. package/fesm2022/ojiepermana-angular-component-select.mjs.map +1 -0
  116. package/fesm2022/ojiepermana-angular-component-separator.mjs +37 -0
  117. package/fesm2022/ojiepermana-angular-component-separator.mjs.map +1 -0
  118. package/fesm2022/ojiepermana-angular-component-sheet.mjs +297 -0
  119. package/fesm2022/ojiepermana-angular-component-sheet.mjs.map +1 -0
  120. package/fesm2022/ojiepermana-angular-component-skeleton.mjs +31 -0
  121. package/fesm2022/ojiepermana-angular-component-skeleton.mjs.map +1 -0
  122. package/fesm2022/ojiepermana-angular-component-slider.mjs +423 -0
  123. package/fesm2022/ojiepermana-angular-component-slider.mjs.map +1 -0
  124. package/fesm2022/ojiepermana-angular-component-spinner.mjs +60 -0
  125. package/fesm2022/ojiepermana-angular-component-spinner.mjs.map +1 -0
  126. package/fesm2022/ojiepermana-angular-component-switch.mjs +140 -0
  127. package/fesm2022/ojiepermana-angular-component-switch.mjs.map +1 -0
  128. package/fesm2022/ojiepermana-angular-component-table.mjs +155 -0
  129. package/fesm2022/ojiepermana-angular-component-table.mjs.map +1 -0
  130. package/fesm2022/ojiepermana-angular-component-tabs.mjs +271 -0
  131. package/fesm2022/ojiepermana-angular-component-tabs.mjs.map +1 -0
  132. package/fesm2022/ojiepermana-angular-component-textarea.mjs +39 -0
  133. package/fesm2022/ojiepermana-angular-component-textarea.mjs.map +1 -0
  134. package/fesm2022/ojiepermana-angular-component-timeline.mjs +237 -0
  135. package/fesm2022/ojiepermana-angular-component-timeline.mjs.map +1 -0
  136. package/fesm2022/ojiepermana-angular-component-toast.mjs +161 -0
  137. package/fesm2022/ojiepermana-angular-component-toast.mjs.map +1 -0
  138. package/fesm2022/ojiepermana-angular-component-toggle-group.mjs +289 -0
  139. package/fesm2022/ojiepermana-angular-component-toggle-group.mjs.map +1 -0
  140. package/fesm2022/ojiepermana-angular-component-toggle.mjs +82 -0
  141. package/fesm2022/ojiepermana-angular-component-toggle.mjs.map +1 -0
  142. package/fesm2022/ojiepermana-angular-component-tooltip.mjs +410 -0
  143. package/fesm2022/ojiepermana-angular-component-tooltip.mjs.map +1 -0
  144. package/fesm2022/ojiepermana-angular-component-utils.mjs +81 -0
  145. package/fesm2022/ojiepermana-angular-component-utils.mjs.map +1 -0
  146. package/fesm2022/ojiepermana-angular-component.mjs +11 -0
  147. package/fesm2022/ojiepermana-angular-component.mjs.map +1 -0
  148. package/form/README.md +210 -0
  149. package/hover-card/README.md +142 -0
  150. package/icon/README.md +25 -0
  151. package/input/README.md +159 -0
  152. package/input-group/README.md +237 -0
  153. package/input-otp/README.md +278 -0
  154. package/item/README.md +247 -0
  155. package/kanban/README.md +81 -0
  156. package/kbd/README.md +139 -0
  157. package/label/README.md +135 -0
  158. package/menubar/README.md +269 -0
  159. package/native-select/README.md +176 -0
  160. package/navigation-menu/README.md +160 -0
  161. package/package.json +291 -0
  162. package/pagination/README.md +144 -0
  163. package/pillbox/README.md +67 -0
  164. package/popover/README.md +43 -0
  165. package/progress/README.md +160 -0
  166. package/radio/README.md +209 -0
  167. package/resizable/README.md +168 -0
  168. package/scroll-area/README.md +143 -0
  169. package/select/README.md +174 -0
  170. package/separator/README.md +170 -0
  171. package/sheet/README.md +183 -0
  172. package/skeleton/README.md +158 -0
  173. package/slider/README.md +207 -0
  174. package/spinner/README.md +160 -0
  175. package/switch/README.md +166 -0
  176. package/table/README.md +291 -0
  177. package/tabs/README.md +214 -0
  178. package/textarea/README.md +153 -0
  179. package/timeline/README.md +94 -0
  180. package/toast/README.md +321 -0
  181. package/toggle/README.md +131 -0
  182. package/toggle-group/README.md +206 -0
  183. package/tooltip/README.md +207 -0
  184. package/types/ojiepermana-angular-component-accordion.d.ts +51 -0
  185. package/types/ojiepermana-angular-component-alert-dialog.d.ts +93 -0
  186. package/types/ojiepermana-angular-component-alert.d.ts +37 -0
  187. package/types/ojiepermana-angular-component-aspect-ratio.d.ts +12 -0
  188. package/types/ojiepermana-angular-component-avatar.d.ts +51 -0
  189. package/types/ojiepermana-angular-component-badge.d.ts +19 -0
  190. package/types/ojiepermana-angular-component-breadcrumb.d.ts +46 -0
  191. package/types/ojiepermana-angular-component-button-group.d.ts +26 -0
  192. package/types/ojiepermana-angular-component-button.d.ts +22 -0
  193. package/types/ojiepermana-angular-component-calendar.d.ts +39 -0
  194. package/types/ojiepermana-angular-component-card.d.ts +60 -0
  195. package/types/ojiepermana-angular-component-carousel.d.ts +86 -0
  196. package/types/ojiepermana-angular-component-checkbox.d.ts +42 -0
  197. package/types/ojiepermana-angular-component-collapsible.d.ts +42 -0
  198. package/types/ojiepermana-angular-component-combobox.d.ts +53 -0
  199. package/types/ojiepermana-angular-component-command.d.ts +102 -0
  200. package/types/ojiepermana-angular-component-composer.d.ts +90 -0
  201. package/types/ojiepermana-angular-component-context-menu.d.ts +36 -0
  202. package/types/ojiepermana-angular-component-date-picker.d.ts +48 -0
  203. package/types/ojiepermana-angular-component-dialog.d.ts +87 -0
  204. package/types/ojiepermana-angular-component-drawer.d.ts +1 -0
  205. package/types/ojiepermana-angular-component-dropdown-menu.d.ts +140 -0
  206. package/types/ojiepermana-angular-component-editor.d.ts +126 -0
  207. package/types/ojiepermana-angular-component-empty.d.ts +50 -0
  208. package/types/ojiepermana-angular-component-form.d.ts +140 -0
  209. package/types/ojiepermana-angular-component-hover-card.d.ts +75 -0
  210. package/types/ojiepermana-angular-component-icon.d.ts +31 -0
  211. package/types/ojiepermana-angular-component-input-group.d.ts +51 -0
  212. package/types/ojiepermana-angular-component-input-otp.d.ts +142 -0
  213. package/types/ojiepermana-angular-component-input.d.ts +16 -0
  214. package/types/ojiepermana-angular-component-item.d.ts +88 -0
  215. package/types/ojiepermana-angular-component-kanban.d.ts +70 -0
  216. package/types/ojiepermana-angular-component-kbd.d.ts +16 -0
  217. package/types/ojiepermana-angular-component-label.d.ts +11 -0
  218. package/types/ojiepermana-angular-component-menubar.d.ts +69 -0
  219. package/types/ojiepermana-angular-component-native-select.d.ts +26 -0
  220. package/types/ojiepermana-angular-component-navigation-menu.d.ts +98 -0
  221. package/types/ojiepermana-angular-component-pagination.d.ts +33 -0
  222. package/types/ojiepermana-angular-component-pillbox.d.ts +156 -0
  223. package/types/ojiepermana-angular-component-popover.d.ts +50 -0
  224. package/types/ojiepermana-angular-component-progress.d.ts +17 -0
  225. package/types/ojiepermana-angular-component-radio.d.ts +57 -0
  226. package/types/ojiepermana-angular-component-resizable.d.ts +99 -0
  227. package/types/ojiepermana-angular-component-scroll-area.d.ts +19 -0
  228. package/types/ojiepermana-angular-component-select.d.ts +56 -0
  229. package/types/ojiepermana-angular-component-separator.d.ts +14 -0
  230. package/types/ojiepermana-angular-component-sheet.d.ts +78 -0
  231. package/types/ojiepermana-angular-component-skeleton.d.ts +10 -0
  232. package/types/ojiepermana-angular-component-slider.d.ts +74 -0
  233. package/types/ojiepermana-angular-component-spinner.d.ts +13 -0
  234. package/types/ojiepermana-angular-component-switch.d.ts +44 -0
  235. package/types/ojiepermana-angular-component-table.d.ts +52 -0
  236. package/types/ojiepermana-angular-component-tabs.d.ts +92 -0
  237. package/types/ojiepermana-angular-component-textarea.d.ts +12 -0
  238. package/types/ojiepermana-angular-component-timeline.d.ts +63 -0
  239. package/types/ojiepermana-angular-component-toast.d.ts +51 -0
  240. package/types/ojiepermana-angular-component-toggle-group.d.ts +89 -0
  241. package/types/ojiepermana-angular-component-toggle.d.ts +25 -0
  242. package/types/ojiepermana-angular-component-tooltip.d.ts +101 -0
  243. package/types/ojiepermana-angular-component-utils.d.ts +30 -0
  244. package/types/ojiepermana-angular-component.d.ts +2 -0
@@ -0,0 +1,271 @@
1
+ import * as i0 from '@angular/core';
2
+ import { Directive, model, input, computed, forwardRef, ChangeDetectionStrategy, Component, inject, ElementRef } from '@angular/core';
3
+ import { uniqueId, cn } from '@ojiepermana/angular-component/utils';
4
+
5
+ /**
6
+ * Shared state for a tabs group. Children read the active value and register
7
+ * themselves so the group can drive roving-tabindex keyboard navigation.
8
+ */
9
+ class TabsContextBase {
10
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsContextBase, deps: [], target: i0.ɵɵFactoryTarget.Directive });
11
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.2", type: TabsContextBase, isStandalone: true, ngImport: i0 });
12
+ }
13
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsContextBase, decorators: [{
14
+ type: Directive
15
+ }] });
16
+ class TabsListContextBase {
17
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsListContextBase, deps: [], target: i0.ɵɵFactoryTarget.Directive });
18
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.2", type: TabsListContextBase, isStandalone: true, ngImport: i0 });
19
+ }
20
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsListContextBase, decorators: [{
21
+ type: Directive
22
+ }] });
23
+ class TabsComponent extends TabsContextBase {
24
+ value = model(null, /* @ts-ignore */
25
+ ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
26
+ orientation = input('horizontal', /* @ts-ignore */
27
+ ...(ngDevMode ? [{ debugName: "orientation" }] : /* istanbul ignore next */ []));
28
+ class = input('', /* @ts-ignore */
29
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
30
+ idPrefix = uniqueId('Tabs');
31
+ triggers = new Map();
32
+ classes = computed(() => cn(this.orientation() === 'vertical' ? 'flex items-start gap-4' : 'block', this.class()), /* @ts-ignore */
33
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
34
+ register(element, value, disabled) {
35
+ this.triggers.set(element, { element, value, disabled });
36
+ if (this.value() == null && !disabled()) {
37
+ this.value.set(value());
38
+ }
39
+ }
40
+ unregister(element) {
41
+ this.triggers.delete(element);
42
+ }
43
+ activate(value, focus = false) {
44
+ const trigger = this.triggerForValue(value);
45
+ if (!trigger || trigger.disabled())
46
+ return;
47
+ this.value.set(value);
48
+ if (focus) {
49
+ trigger.element.focus();
50
+ }
51
+ }
52
+ focusNext(from, offset) {
53
+ const enabledTriggers = this.enabledTriggers();
54
+ const currentIndex = enabledTriggers.findIndex((trigger) => trigger.element === from);
55
+ if (currentIndex < 0 || enabledTriggers.length === 0)
56
+ return;
57
+ const nextTrigger = enabledTriggers[(currentIndex + offset + enabledTriggers.length) % enabledTriggers.length];
58
+ this.activate(nextTrigger.value(), true);
59
+ }
60
+ focusFirst() {
61
+ const firstTrigger = this.enabledTriggers()[0];
62
+ if (firstTrigger)
63
+ this.activate(firstTrigger.value(), true);
64
+ }
65
+ focusLast() {
66
+ const enabledTriggers = this.enabledTriggers();
67
+ const lastTrigger = enabledTriggers[enabledTriggers.length - 1];
68
+ if (lastTrigger)
69
+ this.activate(lastTrigger.value(), true);
70
+ }
71
+ triggerId(value) {
72
+ return `${this.idPrefix}-trigger-${this.normalizeValue(value)}`;
73
+ }
74
+ contentId(value) {
75
+ return `${this.idPrefix}-content-${this.normalizeValue(value)}`;
76
+ }
77
+ enabledTriggers() {
78
+ return [...this.triggers.values()].filter((trigger) => !trigger.disabled());
79
+ }
80
+ triggerForValue(value) {
81
+ return [...this.triggers.values()].find((trigger) => trigger.value() === value);
82
+ }
83
+ normalizeValue(value) {
84
+ const normalized = value
85
+ .toLowerCase()
86
+ .replace(/[^a-z0-9_-]+/g, '-')
87
+ .replace(/^-+|-+$/g, '');
88
+ return normalized || 'tab';
89
+ }
90
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
91
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: TabsComponent, isStandalone: true, selector: "Tabs", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, host: { properties: { "class": "classes()", "attr.data-orientation": "orientation()" } }, providers: [{ provide: TabsContextBase, useExisting: forwardRef(() => TabsComponent) }], usesInheritance: true, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
92
+ }
93
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsComponent, decorators: [{
94
+ type: Component,
95
+ args: [{
96
+ selector: 'Tabs',
97
+ changeDetection: ChangeDetectionStrategy.OnPush,
98
+ providers: [{ provide: TabsContextBase, useExisting: forwardRef(() => TabsComponent) }],
99
+ host: {
100
+ '[class]': 'classes()',
101
+ '[attr.data-orientation]': 'orientation()',
102
+ },
103
+ template: `<ng-content />`,
104
+ }]
105
+ }], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], orientation: [{ type: i0.Input, args: [{ isSignal: true, alias: "orientation", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
106
+ class TabsListComponent extends TabsListContextBase {
107
+ ctx = inject(TabsComponent);
108
+ variant = input('default', /* @ts-ignore */
109
+ ...(ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []));
110
+ class = input('', /* @ts-ignore */
111
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
112
+ classes = computed(() => cn(this.variantClasses(), this.class()), /* @ts-ignore */
113
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
114
+ listVariant() {
115
+ return this.variant();
116
+ }
117
+ variantClasses() {
118
+ if (this.variant() === 'line') {
119
+ return this.ctx.orientation() === 'vertical'
120
+ ? 'inline-flex flex-col items-stretch justify-start gap-1 border-e border-border bg-transparent p-0 pe-3 text-muted-foreground'
121
+ : 'inline-flex h-9 items-center justify-start gap-4 border-b border-border bg-transparent p-0 text-muted-foreground';
122
+ }
123
+ return this.ctx.orientation() === 'vertical'
124
+ ? 'inline-flex flex-col items-stretch justify-start rounded-md bg-muted p-1 text-muted-foreground'
125
+ : 'inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground';
126
+ }
127
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsListComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
128
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: TabsListComponent, isStandalone: true, selector: "TabsList", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.role": "\"tablist\"", "attr.aria-orientation": "ctx.orientation()", "attr.data-variant": "variant()" } }, providers: [{ provide: TabsListContextBase, useExisting: forwardRef(() => TabsListComponent) }], usesInheritance: true, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
129
+ }
130
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsListComponent, decorators: [{
131
+ type: Component,
132
+ args: [{
133
+ selector: 'TabsList',
134
+ changeDetection: ChangeDetectionStrategy.OnPush,
135
+ providers: [{ provide: TabsListContextBase, useExisting: forwardRef(() => TabsListComponent) }],
136
+ host: {
137
+ '[class]': 'classes()',
138
+ '[attr.role]': '"tablist"',
139
+ '[attr.aria-orientation]': 'ctx.orientation()',
140
+ '[attr.data-variant]': 'variant()',
141
+ },
142
+ template: `<ng-content />`,
143
+ }]
144
+ }], propDecorators: { variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
145
+ class TabsTriggerComponent {
146
+ ctx = inject(TabsComponent);
147
+ list = inject(TabsListContextBase, { optional: true });
148
+ el = inject(ElementRef);
149
+ value = input.required(/* @ts-ignore */
150
+ ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
151
+ disabled = input(false, /* @ts-ignore */
152
+ ...(ngDevMode ? [{ debugName: "disabled" }] : /* istanbul ignore next */ []));
153
+ class = input('', /* @ts-ignore */
154
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
155
+ selected = computed(() => this.ctx.value() === this.value(), /* @ts-ignore */
156
+ ...(ngDevMode ? [{ debugName: "selected" }] : /* istanbul ignore next */ []));
157
+ triggerId = computed(() => this.ctx.triggerId(this.value()), /* @ts-ignore */
158
+ ...(ngDevMode ? [{ debugName: "triggerId" }] : /* istanbul ignore next */ []));
159
+ contentId = computed(() => this.ctx.contentId(this.value()), /* @ts-ignore */
160
+ ...(ngDevMode ? [{ debugName: "contentId" }] : /* istanbul ignore next */ []));
161
+ classes = computed(() => cn('inline-flex items-center justify-center gap-1.5 whitespace-nowrap text-sm font-medium', 'ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2', 'disabled:pointer-events-none disabled:opacity-50', this.variantClasses(), this.class()), /* @ts-ignore */
162
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
163
+ ngOnInit() {
164
+ this.ctx.register(this.el.nativeElement, this.value, this.disabled);
165
+ }
166
+ ngOnDestroy() {
167
+ this.ctx.unregister(this.el.nativeElement);
168
+ }
169
+ onClick() {
170
+ if (this.disabled())
171
+ return;
172
+ this.ctx.activate(this.value());
173
+ }
174
+ onArrow(e, delta, axis) {
175
+ if (this.ctx.orientation() !== axis)
176
+ return;
177
+ e.preventDefault();
178
+ this.ctx.focusNext(this.el.nativeElement, delta);
179
+ }
180
+ onHome(e) {
181
+ e.preventDefault();
182
+ this.ctx.focusFirst();
183
+ }
184
+ onEnd(e) {
185
+ e.preventDefault();
186
+ this.ctx.focusLast();
187
+ }
188
+ variantClasses() {
189
+ const variant = this.list?.listVariant() ?? 'default';
190
+ if (variant === 'line') {
191
+ return this.ctx.orientation() === 'vertical'
192
+ ? 'w-full justify-start rounded-none border-e-2 border-transparent px-3 py-2 data-[state=active]:border-foreground data-[state=active]:bg-transparent data-[state=active]:text-foreground data-[state=active]:shadow-none'
193
+ : 'rounded-none border-b-2 border-transparent px-2 py-2 data-[state=active]:border-foreground data-[state=active]:bg-transparent data-[state=active]:text-foreground data-[state=active]:shadow-none';
194
+ }
195
+ return cn('rounded-sm px-3 py-1.5 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm', this.ctx.orientation() === 'vertical' && 'w-full justify-start');
196
+ }
197
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsTriggerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
198
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: TabsTriggerComponent, isStandalone: true, selector: "button[TabsTrigger]", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: true, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "type": "button" }, listeners: { "click": "onClick()", "keydown.arrowRight": "onArrow($any($event), 1, \"horizontal\")", "keydown.arrowLeft": "onArrow($any($event), -1, \"horizontal\")", "keydown.arrowDown": "onArrow($any($event), 1, \"vertical\")", "keydown.arrowUp": "onArrow($any($event), -1, \"vertical\")", "keydown.home": "onHome($any($event))", "keydown.end": "onEnd($any($event))" }, properties: { "class": "classes()", "id": "triggerId()", "attr.role": "\"tab\"", "attr.aria-selected": "selected()", "attr.aria-controls": "contentId()", "attr.aria-disabled": "disabled() ? \"true\" : null", "attr.tabindex": "selected() ? 0 : -1", "attr.data-state": "selected() ? \"active\" : \"inactive\"", "disabled": "disabled() || null" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
199
+ }
200
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsTriggerComponent, decorators: [{
201
+ type: Component,
202
+ args: [{
203
+ selector: 'button[TabsTrigger]',
204
+ changeDetection: ChangeDetectionStrategy.OnPush,
205
+ host: {
206
+ '[class]': 'classes()',
207
+ '[id]': 'triggerId()',
208
+ type: 'button',
209
+ '[attr.role]': '"tab"',
210
+ '[attr.aria-selected]': 'selected()',
211
+ '[attr.aria-controls]': 'contentId()',
212
+ '[attr.aria-disabled]': 'disabled() ? "true" : null',
213
+ '[attr.tabindex]': 'selected() ? 0 : -1',
214
+ '[attr.data-state]': 'selected() ? "active" : "inactive"',
215
+ '[disabled]': 'disabled() || null',
216
+ '(click)': 'onClick()',
217
+ '(keydown.arrowRight)': 'onArrow($any($event), 1, "horizontal")',
218
+ '(keydown.arrowLeft)': 'onArrow($any($event), -1, "horizontal")',
219
+ '(keydown.arrowDown)': 'onArrow($any($event), 1, "vertical")',
220
+ '(keydown.arrowUp)': 'onArrow($any($event), -1, "vertical")',
221
+ '(keydown.home)': 'onHome($any($event))',
222
+ '(keydown.end)': 'onEnd($any($event))',
223
+ },
224
+ template: `<ng-content />`,
225
+ }]
226
+ }], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: true }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
227
+ class TabsContentComponent {
228
+ ctx = inject(TabsComponent);
229
+ value = input.required(/* @ts-ignore */
230
+ ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
231
+ class = input('', /* @ts-ignore */
232
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
233
+ active = computed(() => this.ctx.value() === this.value(), /* @ts-ignore */
234
+ ...(ngDevMode ? [{ debugName: "active" }] : /* istanbul ignore next */ []));
235
+ triggerId = computed(() => this.ctx.triggerId(this.value()), /* @ts-ignore */
236
+ ...(ngDevMode ? [{ debugName: "triggerId" }] : /* istanbul ignore next */ []));
237
+ contentId = computed(() => this.ctx.contentId(this.value()), /* @ts-ignore */
238
+ ...(ngDevMode ? [{ debugName: "contentId" }] : /* istanbul ignore next */ []));
239
+ classes = computed(() => cn('mt-2 block ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring', this.class()), /* @ts-ignore */
240
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
241
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
242
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.2", type: TabsContentComponent, isStandalone: true, selector: "TabsContent", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: true, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "tabindex": "0" }, properties: { "class": "classes()", "id": "contentId()", "attr.role": "\"tabpanel\"", "attr.aria-labelledby": "triggerId()", "attr.data-state": "active() ? \"active\" : \"inactive\"", "hidden": "!active()" } }, ngImport: i0, template: `@if (active()) {
243
+ <ng-content />
244
+ }`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
245
+ }
246
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TabsContentComponent, decorators: [{
247
+ type: Component,
248
+ args: [{
249
+ selector: 'TabsContent',
250
+ changeDetection: ChangeDetectionStrategy.OnPush,
251
+ host: {
252
+ '[class]': 'classes()',
253
+ '[id]': 'contentId()',
254
+ '[attr.role]': '"tabpanel"',
255
+ '[attr.aria-labelledby]': 'triggerId()',
256
+ '[attr.data-state]': 'active() ? "active" : "inactive"',
257
+ '[hidden]': '!active()',
258
+ tabindex: '0',
259
+ },
260
+ template: `@if (active()) {
261
+ <ng-content />
262
+ }`,
263
+ }]
264
+ }], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: true }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
265
+
266
+ /**
267
+ * Generated bundle index. Do not edit.
268
+ */
269
+
270
+ export { TabsComponent, TabsContentComponent, TabsContextBase, TabsListComponent, TabsListContextBase, TabsTriggerComponent };
271
+ //# sourceMappingURL=ojiepermana-angular-component-tabs.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ojiepermana-angular-component-tabs.mjs","sources":["../../../library/component/tabs/tabs.component.ts","../../../library/component/tabs/ojiepermana-angular-component-tabs.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n Directive,\n ElementRef,\n computed,\n forwardRef,\n inject,\n input,\n model,\n} from '@angular/core';\nimport { cn, uniqueId } from '@ojiepermana/angular-component/utils';\n\nexport type TabsListVariant = 'default' | 'line';\n\ninterface TabsTriggerRegistration {\n readonly element: HTMLElement;\n readonly value: () => string;\n readonly disabled: () => boolean;\n}\n\n/**\n * Shared state for a tabs group. Children read the active value and register\n * themselves so the group can drive roving-tabindex keyboard navigation.\n */\n@Directive()\nexport abstract class TabsContextBase {\n abstract value: ReturnType<typeof model<string | null>>;\n abstract register(element: HTMLElement, value: () => string, disabled: () => boolean): void;\n abstract unregister(element: HTMLElement): void;\n abstract activate(value: string, focus?: boolean): void;\n abstract focusNext(from: HTMLElement, offset: number): void;\n abstract focusFirst(): void;\n abstract focusLast(): void;\n abstract triggerId(value: string): string;\n abstract contentId(value: string): string;\n}\n\n@Directive()\nexport abstract class TabsListContextBase {\n abstract listVariant(): TabsListVariant;\n}\n\n@Component({\n selector: 'Tabs',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [{ provide: TabsContextBase, useExisting: forwardRef(() => TabsComponent) }],\n host: {\n '[class]': 'classes()',\n '[attr.data-orientation]': 'orientation()',\n },\n template: `<ng-content />`,\n})\nexport class TabsComponent extends TabsContextBase {\n readonly value = model<string | null>(null);\n readonly orientation = input<'horizontal' | 'vertical'>('horizontal');\n readonly class = input<string>('');\n\n private readonly idPrefix = uniqueId('Tabs');\n private readonly triggers = new Map<HTMLElement, TabsTriggerRegistration>();\n\n protected readonly classes = computed(() =>\n cn(this.orientation() === 'vertical' ? 'flex items-start gap-4' : 'block', this.class()),\n );\n\n override register(element: HTMLElement, value: () => string, disabled: () => boolean): void {\n this.triggers.set(element, { element, value, disabled });\n\n if (this.value() == null && !disabled()) {\n this.value.set(value());\n }\n }\n\n override unregister(element: HTMLElement): void {\n this.triggers.delete(element);\n }\n\n override activate(value: string, focus = false): void {\n const trigger = this.triggerForValue(value);\n if (!trigger || trigger.disabled()) return;\n\n this.value.set(value);\n if (focus) {\n trigger.element.focus();\n }\n }\n\n override focusNext(from: HTMLElement, offset: number): void {\n const enabledTriggers = this.enabledTriggers();\n const currentIndex = enabledTriggers.findIndex((trigger) => trigger.element === from);\n if (currentIndex < 0 || enabledTriggers.length === 0) return;\n\n const nextTrigger = enabledTriggers[(currentIndex + offset + enabledTriggers.length) % enabledTriggers.length];\n this.activate(nextTrigger.value(), true);\n }\n\n override focusFirst(): void {\n const firstTrigger = this.enabledTriggers()[0];\n if (firstTrigger) this.activate(firstTrigger.value(), true);\n }\n\n override focusLast(): void {\n const enabledTriggers = this.enabledTriggers();\n const lastTrigger = enabledTriggers[enabledTriggers.length - 1];\n if (lastTrigger) this.activate(lastTrigger.value(), true);\n }\n\n override triggerId(value: string): string {\n return `${this.idPrefix}-trigger-${this.normalizeValue(value)}`;\n }\n\n override contentId(value: string): string {\n return `${this.idPrefix}-content-${this.normalizeValue(value)}`;\n }\n\n private enabledTriggers(): TabsTriggerRegistration[] {\n return [...this.triggers.values()].filter((trigger) => !trigger.disabled());\n }\n\n private triggerForValue(value: string): TabsTriggerRegistration | undefined {\n return [...this.triggers.values()].find((trigger) => trigger.value() === value);\n }\n\n private normalizeValue(value: string): string {\n const normalized = value\n .toLowerCase()\n .replace(/[^a-z0-9_-]+/g, '-')\n .replace(/^-+|-+$/g, '');\n\n return normalized || 'tab';\n }\n}\n\n@Component({\n selector: 'TabsList',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [{ provide: TabsListContextBase, useExisting: forwardRef(() => TabsListComponent) }],\n host: {\n '[class]': 'classes()',\n '[attr.role]': '\"tablist\"',\n '[attr.aria-orientation]': 'ctx.orientation()',\n '[attr.data-variant]': 'variant()',\n },\n template: `<ng-content />`,\n})\nexport class TabsListComponent extends TabsListContextBase {\n protected readonly ctx = inject(TabsComponent);\n readonly variant = input<TabsListVariant>('default');\n readonly class = input<string>('');\n\n protected readonly classes = computed(() => cn(this.variantClasses(), this.class()));\n\n override listVariant(): TabsListVariant {\n return this.variant();\n }\n\n private variantClasses(): string {\n if (this.variant() === 'line') {\n return this.ctx.orientation() === 'vertical'\n ? 'inline-flex flex-col items-stretch justify-start gap-1 border-e border-border bg-transparent p-0 pe-3 text-muted-foreground'\n : 'inline-flex h-9 items-center justify-start gap-4 border-b border-border bg-transparent p-0 text-muted-foreground';\n }\n\n return this.ctx.orientation() === 'vertical'\n ? 'inline-flex flex-col items-stretch justify-start rounded-md bg-muted p-1 text-muted-foreground'\n : 'inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground';\n }\n}\n\n@Component({\n selector: 'button[TabsTrigger]',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[class]': 'classes()',\n '[id]': 'triggerId()',\n type: 'button',\n '[attr.role]': '\"tab\"',\n '[attr.aria-selected]': 'selected()',\n '[attr.aria-controls]': 'contentId()',\n '[attr.aria-disabled]': 'disabled() ? \"true\" : null',\n '[attr.tabindex]': 'selected() ? 0 : -1',\n '[attr.data-state]': 'selected() ? \"active\" : \"inactive\"',\n '[disabled]': 'disabled() || null',\n '(click)': 'onClick()',\n '(keydown.arrowRight)': 'onArrow($any($event), 1, \"horizontal\")',\n '(keydown.arrowLeft)': 'onArrow($any($event), -1, \"horizontal\")',\n '(keydown.arrowDown)': 'onArrow($any($event), 1, \"vertical\")',\n '(keydown.arrowUp)': 'onArrow($any($event), -1, \"vertical\")',\n '(keydown.home)': 'onHome($any($event))',\n '(keydown.end)': 'onEnd($any($event))',\n },\n template: `<ng-content />`,\n})\nexport class TabsTriggerComponent {\n protected readonly ctx = inject(TabsComponent);\n private readonly list = inject(TabsListContextBase, { optional: true });\n private readonly el = inject<ElementRef<HTMLElement>>(ElementRef);\n\n readonly value = input.required<string>();\n readonly disabled = input<boolean>(false);\n readonly class = input<string>('');\n\n protected readonly selected = computed(() => this.ctx.value() === this.value());\n protected readonly triggerId = computed(() => this.ctx.triggerId(this.value()));\n protected readonly contentId = computed(() => this.ctx.contentId(this.value()));\n\n protected readonly classes = computed(() =>\n cn(\n 'inline-flex items-center justify-center gap-1.5 whitespace-nowrap text-sm font-medium',\n 'ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2',\n 'disabled:pointer-events-none disabled:opacity-50',\n this.variantClasses(),\n this.class(),\n ),\n );\n\n ngOnInit(): void {\n this.ctx.register(this.el.nativeElement, this.value, this.disabled);\n }\n\n ngOnDestroy(): void {\n this.ctx.unregister(this.el.nativeElement);\n }\n\n protected onClick(): void {\n if (this.disabled()) return;\n this.ctx.activate(this.value());\n }\n\n protected onArrow(e: KeyboardEvent, delta: number, axis: 'horizontal' | 'vertical'): void {\n if (this.ctx.orientation() !== axis) return;\n e.preventDefault();\n this.ctx.focusNext(this.el.nativeElement, delta);\n }\n\n protected onHome(e: KeyboardEvent): void {\n e.preventDefault();\n this.ctx.focusFirst();\n }\n\n protected onEnd(e: KeyboardEvent): void {\n e.preventDefault();\n this.ctx.focusLast();\n }\n\n private variantClasses(): string {\n const variant = this.list?.listVariant() ?? 'default';\n\n if (variant === 'line') {\n return this.ctx.orientation() === 'vertical'\n ? 'w-full justify-start rounded-none border-e-2 border-transparent px-3 py-2 data-[state=active]:border-foreground data-[state=active]:bg-transparent data-[state=active]:text-foreground data-[state=active]:shadow-none'\n : 'rounded-none border-b-2 border-transparent px-2 py-2 data-[state=active]:border-foreground data-[state=active]:bg-transparent data-[state=active]:text-foreground data-[state=active]:shadow-none';\n }\n\n return cn(\n 'rounded-sm px-3 py-1.5 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm',\n this.ctx.orientation() === 'vertical' && 'w-full justify-start',\n );\n }\n}\n\n@Component({\n selector: 'TabsContent',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[class]': 'classes()',\n '[id]': 'contentId()',\n '[attr.role]': '\"tabpanel\"',\n '[attr.aria-labelledby]': 'triggerId()',\n '[attr.data-state]': 'active() ? \"active\" : \"inactive\"',\n '[hidden]': '!active()',\n tabindex: '0',\n },\n template: `@if (active()) {\n <ng-content />\n }`,\n})\nexport class TabsContentComponent {\n private readonly ctx = inject(TabsComponent);\n readonly value = input.required<string>();\n readonly class = input<string>('');\n protected readonly active = computed(() => this.ctx.value() === this.value());\n protected readonly triggerId = computed(() => this.ctx.triggerId(this.value()));\n protected readonly contentId = computed(() => this.ctx.contentId(this.value()));\n protected readonly classes = computed(() =>\n cn(\n 'mt-2 block ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring',\n this.class(),\n ),\n );\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAqBA;;;AAGG;MAEmB,eAAe,CAAA;uGAAf,eAAe,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAAf,eAAe,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAAf,eAAe,EAAA,UAAA,EAAA,CAAA;kBADpC;;MAcqB,mBAAmB,CAAA;uGAAnB,mBAAmB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAAnB,mBAAmB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,E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BAAA,EAAA,IAAA,EAAA,EAAA,KAAA,EAAA,EAAA,iBAAA,EAAA,OAAA,EAAA,UAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,UAAA,EAAA,GAAA,EAAA,EAAA,UAAA,EAAA,EAAA,OAAA,EAAA,WAAA,EAAA,IAAA,EAAA,aAAA,EAAA,WAAA,EAAA,cAAA,EAAA,sBAAA,EAAA,aAAA,EAAA,iBAAA,EAAA,sCAAA,EAAA,QAAA,EAAA,WAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EAJrB,CAAA;;AAER,GAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;2FAES,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBAhBhC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,aAAa;oBACvB,eAAe,EAAE,uBAAuB,CAAC,MAAM;AAC/C,oBAAA,IAAI,EAAE;AACJ,wBAAA,SAAS,EAAE,WAAW;AACtB,wBAAA,MAAM,EAAE,aAAa;AACrB,wBAAA,aAAa,EAAE,YAAY;AAC3B,wBAAA,wBAAwB,EAAE,aAAa;AACvC,wBAAA,mBAAmB,EAAE,kCAAkC;AACvD,wBAAA,UAAU,EAAE,WAAW;AACvB,wBAAA,QAAQ,EAAE,GAAG;AACd,qBAAA;AACD,oBAAA,QAAQ,EAAE,CAAA;;AAER,GAAA,CAAA;AACH,iBAAA;;;ACpRD;;AAEG;;;;"}
@@ -0,0 +1,39 @@
1
+ import * as i0 from '@angular/core';
2
+ import { inject, ElementRef, input, computed, ChangeDetectionStrategy, Component } from '@angular/core';
3
+ import { cn } from '@ojiepermana/angular-component/utils';
4
+
5
+ class TextareaComponent {
6
+ el = inject(ElementRef);
7
+ class = input('', /* @ts-ignore */
8
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
9
+ classes = computed(() => cn([
10
+ 'flex min-h-[60px] w-full resize-y rounded-md border border-input bg-transparent px-3 py-2',
11
+ 'text-sm shadow-sm transition-colors',
12
+ 'placeholder:text-muted-foreground',
13
+ 'focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring',
14
+ 'disabled:cursor-not-allowed disabled:opacity-50',
15
+ 'aria-[invalid=true]:border-destructive aria-[invalid=true]:focus-visible:ring-destructive',
16
+ ].join(' '), this.class()), /* @ts-ignore */
17
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
18
+ focus() {
19
+ this.el.nativeElement.focus();
20
+ }
21
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TextareaComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
22
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: TextareaComponent, isStandalone: true, selector: "textarea[Textarea]", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()" } }, ngImport: i0, template: '', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
23
+ }
24
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TextareaComponent, decorators: [{
25
+ type: Component,
26
+ args: [{
27
+ selector: 'textarea[Textarea]',
28
+ changeDetection: ChangeDetectionStrategy.OnPush,
29
+ host: { '[class]': 'classes()' },
30
+ template: '',
31
+ }]
32
+ }], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
33
+
34
+ /**
35
+ * Generated bundle index. Do not edit.
36
+ */
37
+
38
+ export { TextareaComponent };
39
+ //# sourceMappingURL=ojiepermana-angular-component-textarea.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ojiepermana-angular-component-textarea.mjs","sources":["../../../library/component/textarea/textarea.component.ts","../../../library/component/textarea/ojiepermana-angular-component-textarea.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, ElementRef, computed, inject, input } from '@angular/core';\nimport { cn } from '@ojiepermana/angular-component/utils';\n\n@Component({\n selector: 'textarea[Textarea]',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: { '[class]': 'classes()' },\n template: '',\n})\nexport class TextareaComponent {\n private readonly el = inject<ElementRef<HTMLTextAreaElement>>(ElementRef);\n readonly class = input<string>('');\n\n protected readonly classes = computed(() =>\n cn(\n [\n 'flex min-h-[60px] w-full resize-y rounded-md border border-input bg-transparent px-3 py-2',\n 'text-sm shadow-sm transition-colors',\n 'placeholder:text-muted-foreground',\n 'focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring',\n 'disabled:cursor-not-allowed disabled:opacity-50',\n 'aria-[invalid=true]:border-destructive aria-[invalid=true]:focus-visible:ring-destructive',\n ].join(' '),\n this.class(),\n ),\n );\n\n focus(): void {\n this.el.nativeElement.focus();\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;MASa,iBAAiB,CAAA;AACX,IAAA,EAAE,GAAG,MAAM,CAAkC,UAAU,CAAC;IAChE,KAAK,GAAG,KAAK,CAAS,EAAE;8EAAC;AAEf,IAAA,OAAO,GAAG,QAAQ,CAAC,MACpC,EAAE,CACA;QACE,2FAA2F;QAC3F,qCAAqC;QACrC,mCAAmC;QACnC,yEAAyE;QACzE,iDAAiD;QACjD,2FAA2F;KAC5F,CAAC,IAAI,CAAC,GAAG,CAAC,EACX,IAAI,CAAC,KAAK,EAAE,CACb;gFACF;IAED,KAAK,GAAA;AACH,QAAA,IAAI,CAAC,EAAE,CAAC,aAAa,CAAC,KAAK,EAAE;IAC/B;uGApBW,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAjB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,iBAAiB,kQAFlB,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;2FAED,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAN7B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,oBAAoB;oBAC9B,eAAe,EAAE,uBAAuB,CAAC,MAAM;AAC/C,oBAAA,IAAI,EAAE,EAAE,SAAS,EAAE,WAAW,EAAE;AAChC,oBAAA,QAAQ,EAAE,EAAE;AACb,iBAAA;;;ACRD;;AAEG;;;;"}
@@ -0,0 +1,237 @@
1
+ import * as i0 from '@angular/core';
2
+ import { input, booleanAttribute, computed, ChangeDetectionStrategy, Component, inject } from '@angular/core';
3
+ import { cn } from '@ojiepermana/angular-component/utils';
4
+
5
+ const TIMELINE_BASE = [
6
+ 'w-full min-w-0 text-sm text-foreground',
7
+ '[--timeline-content-gap:0.75rem] [--timeline-indicator-size:1.5rem] [--timeline-item-gap:1.5rem]',
8
+ ].join(' ');
9
+ const timelineSizeClasses = {
10
+ default: '[--timeline-indicator-size:1.5rem]',
11
+ lg: '[--timeline-indicator-size:2.5rem] [--timeline-content-gap:1rem]',
12
+ };
13
+ const timelineAlignClasses = {
14
+ start: 'items-start',
15
+ baseline: 'items-baseline',
16
+ center: 'items-center',
17
+ end: 'items-end',
18
+ };
19
+ const timelineItemStatusClasses = {
20
+ complete: 'before:bg-primary after:bg-primary',
21
+ current: 'before:bg-border after:bg-border',
22
+ incomplete: 'before:bg-border/70 after:bg-border/70',
23
+ };
24
+ const timelineIndicatorStatusClasses = {
25
+ complete: 'border-primary bg-primary text-primary-foreground',
26
+ current: 'border-ring bg-background text-foreground ring-2 ring-ring ring-offset-2 ring-offset-background',
27
+ incomplete: 'border-border bg-background text-muted-foreground',
28
+ };
29
+ const timelineIndicatorColorClasses = {
30
+ red: 'border-[hsl(var(--timeline-indicator-red))] bg-[hsl(var(--timeline-indicator-red))] text-[hsl(var(--timeline-indicator-red-foreground))]',
31
+ orange: 'border-[hsl(var(--timeline-indicator-orange))] bg-[hsl(var(--timeline-indicator-orange))] text-[hsl(var(--timeline-indicator-orange-foreground))]',
32
+ amber: 'border-[hsl(var(--timeline-indicator-amber))] bg-[hsl(var(--timeline-indicator-amber))] text-[hsl(var(--timeline-indicator-amber-foreground))]',
33
+ yellow: 'border-[hsl(var(--timeline-indicator-yellow))] bg-[hsl(var(--timeline-indicator-yellow))] text-[hsl(var(--timeline-indicator-yellow-foreground))]',
34
+ lime: 'border-[hsl(var(--timeline-indicator-lime))] bg-[hsl(var(--timeline-indicator-lime))] text-[hsl(var(--timeline-indicator-lime-foreground))]',
35
+ green: 'border-[hsl(var(--timeline-indicator-green))] bg-[hsl(var(--timeline-indicator-green))] text-[hsl(var(--timeline-indicator-green-foreground))]',
36
+ emerald: 'border-[hsl(var(--timeline-indicator-emerald))] bg-[hsl(var(--timeline-indicator-emerald))] text-[hsl(var(--timeline-indicator-emerald-foreground))]',
37
+ teal: 'border-[hsl(var(--timeline-indicator-teal))] bg-[hsl(var(--timeline-indicator-teal))] text-[hsl(var(--timeline-indicator-teal-foreground))]',
38
+ cyan: 'border-[hsl(var(--timeline-indicator-cyan))] bg-[hsl(var(--timeline-indicator-cyan))] text-[hsl(var(--timeline-indicator-cyan-foreground))]',
39
+ sky: 'border-[hsl(var(--timeline-indicator-sky))] bg-[hsl(var(--timeline-indicator-sky))] text-[hsl(var(--timeline-indicator-sky-foreground))]',
40
+ blue: 'border-[hsl(var(--timeline-indicator-blue))] bg-[hsl(var(--timeline-indicator-blue))] text-[hsl(var(--timeline-indicator-blue-foreground))]',
41
+ indigo: 'border-[hsl(var(--timeline-indicator-indigo))] bg-[hsl(var(--timeline-indicator-indigo))] text-[hsl(var(--timeline-indicator-indigo-foreground))]',
42
+ violet: 'border-[hsl(var(--timeline-indicator-violet))] bg-[hsl(var(--timeline-indicator-violet))] text-[hsl(var(--timeline-indicator-violet-foreground))]',
43
+ purple: 'border-[hsl(var(--timeline-indicator-purple))] bg-[hsl(var(--timeline-indicator-purple))] text-[hsl(var(--timeline-indicator-purple-foreground))]',
44
+ fuchsia: 'border-[hsl(var(--timeline-indicator-fuchsia))] bg-[hsl(var(--timeline-indicator-fuchsia))] text-[hsl(var(--timeline-indicator-fuchsia-foreground))]',
45
+ pink: 'border-[hsl(var(--timeline-indicator-pink))] bg-[hsl(var(--timeline-indicator-pink))] text-[hsl(var(--timeline-indicator-pink-foreground))]',
46
+ rose: 'border-[hsl(var(--timeline-indicator-rose))] bg-[hsl(var(--timeline-indicator-rose))] text-[hsl(var(--timeline-indicator-rose-foreground))]',
47
+ };
48
+ class TimelineComponent {
49
+ horizontal = input(false, { ...(ngDevMode ? { debugName: "horizontal" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
50
+ align = input('center', /* @ts-ignore */
51
+ ...(ngDevMode ? [{ debugName: "align" }] : /* istanbul ignore next */ []));
52
+ size = input('default', /* @ts-ignore */
53
+ ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
54
+ class = input('', /* @ts-ignore */
55
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
56
+ classes = computed(() => cn(TIMELINE_BASE, timelineSizeClasses[this.size()], this.horizontal() ? 'flex min-w-0 items-start gap-[var(--timeline-item-gap)] overflow-x-auto pb-1' : 'grid', this.class()), /* @ts-ignore */
57
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
58
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
59
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: TimelineComponent, isStandalone: true, selector: "Timeline", inputs: { horizontal: { classPropertyName: "horizontal", publicName: "horizontal", isSignal: true, isRequired: false, transformFunction: null }, align: { classPropertyName: "align", publicName: "align", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-slot": "\"timeline\"", "attr.data-orientation": "horizontal() ? \"horizontal\" : \"vertical\"", "attr.data-align": "align()", "attr.data-size": "size()" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
60
+ }
61
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineComponent, decorators: [{
62
+ type: Component,
63
+ args: [{
64
+ selector: 'Timeline',
65
+ changeDetection: ChangeDetectionStrategy.OnPush,
66
+ host: {
67
+ '[class]': 'classes()',
68
+ '[attr.data-slot]': '"timeline"',
69
+ '[attr.data-orientation]': 'horizontal() ? "horizontal" : "vertical"',
70
+ '[attr.data-align]': 'align()',
71
+ '[attr.data-size]': 'size()',
72
+ },
73
+ template: `<ng-content />`,
74
+ }]
75
+ }], propDecorators: { horizontal: [{ type: i0.Input, args: [{ isSignal: true, alias: "horizontal", required: false }] }], align: [{ type: i0.Input, args: [{ isSignal: true, alias: "align", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
76
+ class TimelineItemComponent {
77
+ timeline = inject(TimelineComponent, { optional: true });
78
+ status = input(null, /* @ts-ignore */
79
+ ...(ngDevMode ? [{ debugName: "status" }] : /* istanbul ignore next */ []));
80
+ align = input(null, /* @ts-ignore */
81
+ ...(ngDevMode ? [{ debugName: "align" }] : /* istanbul ignore next */ []));
82
+ size = input(null, /* @ts-ignore */
83
+ ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
84
+ class = input('', /* @ts-ignore */
85
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
86
+ orientation = computed(() => (this.timeline?.horizontal() ? 'horizontal' : 'vertical'), /* @ts-ignore */
87
+ ...(ngDevMode ? [{ debugName: "orientation" }] : /* istanbul ignore next */ []));
88
+ resolvedAlign = computed(() => this.align() ?? this.timeline?.align() ?? 'center', /* @ts-ignore */
89
+ ...(ngDevMode ? [{ debugName: "resolvedAlign" }] : /* istanbul ignore next */ []));
90
+ resolvedSize = computed(() => this.size() ?? this.timeline?.size() ?? 'default', /* @ts-ignore */
91
+ ...(ngDevMode ? [{ debugName: "resolvedSize" }] : /* istanbul ignore next */ []));
92
+ classes = computed(() => {
93
+ const status = this.status();
94
+ const orientation = this.orientation();
95
+ return cn('relative min-w-0', timelineSizeClasses[this.resolvedSize()], orientation === 'horizontal'
96
+ ? [
97
+ "before:content-['']",
98
+ 'grid min-w-32 flex-1 justify-items-center gap-y-2 text-center',
99
+ 'before:absolute before:left-0 before:right-0 before:top-[calc(var(--timeline-indicator-size)/2)] before:h-px before:bg-border',
100
+ 'first:before:left-1/2 last:before:right-1/2',
101
+ ].join(' ')
102
+ : [
103
+ "after:content-['']",
104
+ 'grid grid-cols-[var(--timeline-indicator-size)_minmax(0,1fr)] gap-x-[var(--timeline-content-gap)] pb-[var(--timeline-item-gap)] last:pb-0',
105
+ 'after:absolute after:bottom-0 after:left-[calc(var(--timeline-indicator-size)/2)] after:top-[calc(var(--timeline-indicator-size)+0.25rem)] after:w-px after:-translate-x-1/2 after:bg-border last:after:hidden',
106
+ timelineAlignClasses[this.resolvedAlign()],
107
+ ].join(' '), status ? timelineItemStatusClasses[status] : 'before:bg-border after:bg-border', this.class());
108
+ }, /* @ts-ignore */
109
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
110
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineItemComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
111
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: TimelineItemComponent, isStandalone: true, selector: "TimelineItem", inputs: { status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null }, align: { classPropertyName: "align", publicName: "align", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-slot": "\"timeline-item\"", "attr.data-orientation": "orientation()", "attr.data-align": "resolvedAlign()", "attr.data-size": "resolvedSize()", "attr.data-status": "status() ?? null" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
112
+ }
113
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineItemComponent, decorators: [{
114
+ type: Component,
115
+ args: [{
116
+ selector: 'TimelineItem',
117
+ changeDetection: ChangeDetectionStrategy.OnPush,
118
+ host: {
119
+ '[class]': 'classes()',
120
+ '[attr.data-slot]': '"timeline-item"',
121
+ '[attr.data-orientation]': 'orientation()',
122
+ '[attr.data-align]': 'resolvedAlign()',
123
+ '[attr.data-size]': 'resolvedSize()',
124
+ '[attr.data-status]': 'status() ?? null',
125
+ },
126
+ template: `<ng-content />`,
127
+ }]
128
+ }], propDecorators: { status: [{ type: i0.Input, args: [{ isSignal: true, alias: "status", required: false }] }], align: [{ type: i0.Input, args: [{ isSignal: true, alias: "align", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
129
+ class TimelineIndicatorComponent {
130
+ item = inject(TimelineItemComponent, { optional: true });
131
+ variant = input('default', /* @ts-ignore */
132
+ ...(ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []));
133
+ status = input(null, /* @ts-ignore */
134
+ ...(ngDevMode ? [{ debugName: "status" }] : /* istanbul ignore next */ []));
135
+ color = input(null, /* @ts-ignore */
136
+ ...(ngDevMode ? [{ debugName: "color" }] : /* istanbul ignore next */ []));
137
+ class = input('', /* @ts-ignore */
138
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
139
+ resolvedStatus = computed(() => this.status() ?? this.item?.status() ?? 'incomplete', /* @ts-ignore */
140
+ ...(ngDevMode ? [{ debugName: "resolvedStatus" }] : /* istanbul ignore next */ []));
141
+ classes = computed(() => {
142
+ const color = this.color();
143
+ return cn('relative z-10 col-start-1 row-start-1 inline-flex shrink-0 items-center justify-center justify-self-center', this.item?.orientation() === 'horizontal' ? 'row-start-1' : '', this.variant() === 'bare'
144
+ ? 'bg-background text-muted-foreground'
145
+ : [
146
+ 'size-[var(--timeline-indicator-size)] rounded-full border text-xs font-medium shadow-sm',
147
+ color ? timelineIndicatorColorClasses[color] : timelineIndicatorStatusClasses[this.resolvedStatus()],
148
+ ].join(' '), this.class());
149
+ }, /* @ts-ignore */
150
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
151
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineIndicatorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
152
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: TimelineIndicatorComponent, isStandalone: true, selector: "TimelineIndicator", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-slot": "\"timeline-indicator\"", "attr.data-variant": "variant()", "attr.data-status": "resolvedStatus()", "attr.data-color": "color() ?? null" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
153
+ }
154
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineIndicatorComponent, decorators: [{
155
+ type: Component,
156
+ args: [{
157
+ selector: 'TimelineIndicator',
158
+ changeDetection: ChangeDetectionStrategy.OnPush,
159
+ host: {
160
+ '[class]': 'classes()',
161
+ '[attr.data-slot]': '"timeline-indicator"',
162
+ '[attr.data-variant]': 'variant()',
163
+ '[attr.data-status]': 'resolvedStatus()',
164
+ '[attr.data-color]': 'color() ?? null',
165
+ },
166
+ template: `<ng-content />`,
167
+ }]
168
+ }], propDecorators: { variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], status: [{ type: i0.Input, args: [{ isSignal: true, alias: "status", required: false }] }], color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
169
+ class TimelineContentComponent {
170
+ item = inject(TimelineItemComponent, { optional: true });
171
+ class = input('', /* @ts-ignore */
172
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
173
+ classes = computed(() => cn('min-w-0 text-sm leading-6 text-foreground', this.item?.orientation() === 'horizontal' ? 'row-start-2 max-w-40 text-center' : 'col-start-2 row-start-1', this.class()), /* @ts-ignore */
174
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
175
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
176
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: TimelineContentComponent, isStandalone: true, selector: "TimelineContent", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-slot": "\"timeline-content\"" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
177
+ }
178
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineContentComponent, decorators: [{
179
+ type: Component,
180
+ args: [{
181
+ selector: 'TimelineContent',
182
+ changeDetection: ChangeDetectionStrategy.OnPush,
183
+ host: {
184
+ '[class]': 'classes()',
185
+ '[attr.data-slot]': '"timeline-content"',
186
+ },
187
+ template: `<ng-content />`,
188
+ }]
189
+ }], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
190
+ class TimelineBlockComponent {
191
+ item = inject(TimelineItemComponent, { optional: true });
192
+ class = input('', /* @ts-ignore */
193
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
194
+ classes = computed(() => cn('min-w-0', this.item?.orientation() === 'horizontal' ? 'row-start-2 w-full' : 'col-span-full', this.class()), /* @ts-ignore */
195
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
196
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineBlockComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
197
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: TimelineBlockComponent, isStandalone: true, selector: "TimelineBlock", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-slot": "\"timeline-block\"" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
198
+ }
199
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineBlockComponent, decorators: [{
200
+ type: Component,
201
+ args: [{
202
+ selector: 'TimelineBlock',
203
+ changeDetection: ChangeDetectionStrategy.OnPush,
204
+ host: {
205
+ '[class]': 'classes()',
206
+ '[attr.data-slot]': '"timeline-block"',
207
+ },
208
+ template: `<ng-content />`,
209
+ }]
210
+ }], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
211
+ class TimelineSubgridComponent {
212
+ class = input('', /* @ts-ignore */
213
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
214
+ classes = computed(() => cn('grid min-w-0 grid-cols-[var(--timeline-indicator-size)_minmax(0,1fr)] gap-x-[var(--timeline-content-gap)]', this.class()), /* @ts-ignore */
215
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
216
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineSubgridComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
217
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.2", type: TimelineSubgridComponent, isStandalone: true, selector: "TimelineSubgrid", inputs: { class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "classes()", "attr.data-slot": "\"timeline-subgrid\"" } }, ngImport: i0, template: `<ng-content />`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
218
+ }
219
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: TimelineSubgridComponent, decorators: [{
220
+ type: Component,
221
+ args: [{
222
+ selector: 'TimelineSubgrid',
223
+ changeDetection: ChangeDetectionStrategy.OnPush,
224
+ host: {
225
+ '[class]': 'classes()',
226
+ '[attr.data-slot]': '"timeline-subgrid"',
227
+ },
228
+ template: `<ng-content />`,
229
+ }]
230
+ }], propDecorators: { class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }] } });
231
+
232
+ /**
233
+ * Generated bundle index. Do not edit.
234
+ */
235
+
236
+ export { TimelineBlockComponent, TimelineComponent, TimelineContentComponent, TimelineIndicatorComponent, TimelineItemComponent, TimelineSubgridComponent };
237
+ //# sourceMappingURL=ojiepermana-angular-component-timeline.mjs.map