@loomui-ng/ui 0.0.0-stage → 0.1.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 (270) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +46 -2
  3. package/accordion/README.md +38 -0
  4. package/alert/README.md +32 -0
  5. package/alert-dialog/README.md +37 -0
  6. package/aspect-ratio/README.md +24 -0
  7. package/attachment/README.md +40 -0
  8. package/avatar/README.md +34 -0
  9. package/badge/README.md +29 -0
  10. package/breadcrumb/README.md +33 -0
  11. package/bubble/README.md +32 -0
  12. package/button/README.md +31 -0
  13. package/button-group/README.md +30 -0
  14. package/calendar/README.md +35 -0
  15. package/card/README.md +41 -0
  16. package/carousel/README.md +41 -0
  17. package/chart/README.md +25 -0
  18. package/checkbox/README.md +31 -0
  19. package/collapsible/README.md +31 -0
  20. package/combobox/README.md +47 -0
  21. package/command/README.md +44 -0
  22. package/context-menu/README.md +36 -0
  23. package/data-table/README.md +39 -0
  24. package/date-picker/README.md +23 -0
  25. package/dialog/README.md +52 -0
  26. package/direction/README.md +19 -0
  27. package/drawer/README.md +37 -0
  28. package/dropdown-menu/README.md +46 -0
  29. package/empty/README.md +38 -0
  30. package/fesm2022/loomui-ng-ui-accordion.mjs +555 -0
  31. package/fesm2022/loomui-ng-ui-accordion.mjs.map +1 -0
  32. package/fesm2022/loomui-ng-ui-alert-dialog.mjs +652 -0
  33. package/fesm2022/loomui-ng-ui-alert-dialog.mjs.map +1 -0
  34. package/fesm2022/loomui-ng-ui-alert.mjs +286 -0
  35. package/fesm2022/loomui-ng-ui-alert.mjs.map +1 -0
  36. package/fesm2022/loomui-ng-ui-aspect-ratio.mjs +97 -0
  37. package/fesm2022/loomui-ng-ui-aspect-ratio.mjs.map +1 -0
  38. package/fesm2022/loomui-ng-ui-attachment.mjs +713 -0
  39. package/fesm2022/loomui-ng-ui-attachment.mjs.map +1 -0
  40. package/fesm2022/loomui-ng-ui-avatar.mjs +561 -0
  41. package/fesm2022/loomui-ng-ui-avatar.mjs.map +1 -0
  42. package/fesm2022/loomui-ng-ui-badge.mjs +102 -0
  43. package/fesm2022/loomui-ng-ui-badge.mjs.map +1 -0
  44. package/fesm2022/loomui-ng-ui-breadcrumb.mjs +520 -0
  45. package/fesm2022/loomui-ng-ui-breadcrumb.mjs.map +1 -0
  46. package/fesm2022/loomui-ng-ui-bubble.mjs +386 -0
  47. package/fesm2022/loomui-ng-ui-bubble.mjs.map +1 -0
  48. package/fesm2022/loomui-ng-ui-button-group.mjs +193 -0
  49. package/fesm2022/loomui-ng-ui-button-group.mjs.map +1 -0
  50. package/fesm2022/loomui-ng-ui-button.mjs +162 -0
  51. package/fesm2022/loomui-ng-ui-button.mjs.map +1 -0
  52. package/fesm2022/loomui-ng-ui-calendar.mjs +681 -0
  53. package/fesm2022/loomui-ng-ui-calendar.mjs.map +1 -0
  54. package/fesm2022/loomui-ng-ui-card.mjs +461 -0
  55. package/fesm2022/loomui-ng-ui-card.mjs.map +1 -0
  56. package/fesm2022/loomui-ng-ui-carousel.mjs +532 -0
  57. package/fesm2022/loomui-ng-ui-carousel.mjs.map +1 -0
  58. package/fesm2022/loomui-ng-ui-chart.mjs +373 -0
  59. package/fesm2022/loomui-ng-ui-chart.mjs.map +1 -0
  60. package/fesm2022/loomui-ng-ui-checkbox.mjs +265 -0
  61. package/fesm2022/loomui-ng-ui-checkbox.mjs.map +1 -0
  62. package/fesm2022/loomui-ng-ui-collapsible.mjs +274 -0
  63. package/fesm2022/loomui-ng-ui-collapsible.mjs.map +1 -0
  64. package/fesm2022/loomui-ng-ui-combobox.mjs +971 -0
  65. package/fesm2022/loomui-ng-ui-combobox.mjs.map +1 -0
  66. package/fesm2022/loomui-ng-ui-command.mjs +982 -0
  67. package/fesm2022/loomui-ng-ui-command.mjs.map +1 -0
  68. package/fesm2022/loomui-ng-ui-context-menu.mjs +1359 -0
  69. package/fesm2022/loomui-ng-ui-context-menu.mjs.map +1 -0
  70. package/fesm2022/loomui-ng-ui-data-table.mjs +535 -0
  71. package/fesm2022/loomui-ng-ui-data-table.mjs.map +1 -0
  72. package/fesm2022/loomui-ng-ui-date-picker.mjs +312 -0
  73. package/fesm2022/loomui-ng-ui-date-picker.mjs.map +1 -0
  74. package/fesm2022/loomui-ng-ui-dialog.mjs +508 -0
  75. package/fesm2022/loomui-ng-ui-dialog.mjs.map +1 -0
  76. package/fesm2022/loomui-ng-ui-direction.mjs +112 -0
  77. package/fesm2022/loomui-ng-ui-direction.mjs.map +1 -0
  78. package/fesm2022/loomui-ng-ui-drawer.mjs +590 -0
  79. package/fesm2022/loomui-ng-ui-drawer.mjs.map +1 -0
  80. package/fesm2022/loomui-ng-ui-dropdown-menu.mjs +1322 -0
  81. package/fesm2022/loomui-ng-ui-dropdown-menu.mjs.map +1 -0
  82. package/fesm2022/loomui-ng-ui-empty.mjs +408 -0
  83. package/fesm2022/loomui-ng-ui-empty.mjs.map +1 -0
  84. package/fesm2022/loomui-ng-ui-field.mjs +630 -0
  85. package/fesm2022/loomui-ng-ui-field.mjs.map +1 -0
  86. package/fesm2022/loomui-ng-ui-hover-card.mjs +230 -0
  87. package/fesm2022/loomui-ng-ui-hover-card.mjs.map +1 -0
  88. package/fesm2022/loomui-ng-ui-icon.mjs +498 -0
  89. package/fesm2022/loomui-ng-ui-icon.mjs.map +1 -0
  90. package/fesm2022/loomui-ng-ui-input-group.mjs +463 -0
  91. package/fesm2022/loomui-ng-ui-input-group.mjs.map +1 -0
  92. package/fesm2022/loomui-ng-ui-input-otp.mjs +586 -0
  93. package/fesm2022/loomui-ng-ui-input-otp.mjs.map +1 -0
  94. package/fesm2022/loomui-ng-ui-input.mjs +289 -0
  95. package/fesm2022/loomui-ng-ui-input.mjs.map +1 -0
  96. package/fesm2022/loomui-ng-ui-item.mjs +598 -0
  97. package/fesm2022/loomui-ng-ui-item.mjs.map +1 -0
  98. package/fesm2022/loomui-ng-ui-kbd.mjs +129 -0
  99. package/fesm2022/loomui-ng-ui-kbd.mjs.map +1 -0
  100. package/fesm2022/loomui-ng-ui-label.mjs +68 -0
  101. package/fesm2022/loomui-ng-ui-label.mjs.map +1 -0
  102. package/fesm2022/loomui-ng-ui-marker.mjs +234 -0
  103. package/fesm2022/loomui-ng-ui-marker.mjs.map +1 -0
  104. package/fesm2022/loomui-ng-ui-menubar.mjs +1523 -0
  105. package/fesm2022/loomui-ng-ui-menubar.mjs.map +1 -0
  106. package/fesm2022/loomui-ng-ui-message-scroller.mjs +519 -0
  107. package/fesm2022/loomui-ng-ui-message-scroller.mjs.map +1 -0
  108. package/fesm2022/loomui-ng-ui-message.mjs +408 -0
  109. package/fesm2022/loomui-ng-ui-message.mjs.map +1 -0
  110. package/fesm2022/loomui-ng-ui-native-select.mjs +389 -0
  111. package/fesm2022/loomui-ng-ui-native-select.mjs.map +1 -0
  112. package/fesm2022/loomui-ng-ui-navigation-menu.mjs +609 -0
  113. package/fesm2022/loomui-ng-ui-navigation-menu.mjs.map +1 -0
  114. package/fesm2022/loomui-ng-ui-pagination.mjs +611 -0
  115. package/fesm2022/loomui-ng-ui-pagination.mjs.map +1 -0
  116. package/fesm2022/loomui-ng-ui-popover.mjs +358 -0
  117. package/fesm2022/loomui-ng-ui-popover.mjs.map +1 -0
  118. package/fesm2022/loomui-ng-ui-progress.mjs +159 -0
  119. package/fesm2022/loomui-ng-ui-progress.mjs.map +1 -0
  120. package/fesm2022/loomui-ng-ui-questionnaire.mjs +1012 -0
  121. package/fesm2022/loomui-ng-ui-questionnaire.mjs.map +1 -0
  122. package/fesm2022/loomui-ng-ui-radio-group.mjs +399 -0
  123. package/fesm2022/loomui-ng-ui-radio-group.mjs.map +1 -0
  124. package/fesm2022/loomui-ng-ui-resizable.mjs +518 -0
  125. package/fesm2022/loomui-ng-ui-resizable.mjs.map +1 -0
  126. package/fesm2022/loomui-ng-ui-scroll-area.mjs +135 -0
  127. package/fesm2022/loomui-ng-ui-scroll-area.mjs.map +1 -0
  128. package/fesm2022/loomui-ng-ui-select.mjs +863 -0
  129. package/fesm2022/loomui-ng-ui-select.mjs.map +1 -0
  130. package/fesm2022/loomui-ng-ui-separator.mjs +114 -0
  131. package/fesm2022/loomui-ng-ui-separator.mjs.map +1 -0
  132. package/fesm2022/loomui-ng-ui-sheet.mjs +530 -0
  133. package/fesm2022/loomui-ng-ui-sheet.mjs.map +1 -0
  134. package/fesm2022/loomui-ng-ui-sidebar.mjs +1918 -0
  135. package/fesm2022/loomui-ng-ui-sidebar.mjs.map +1 -0
  136. package/fesm2022/loomui-ng-ui-skeleton.mjs +69 -0
  137. package/fesm2022/loomui-ng-ui-skeleton.mjs.map +1 -0
  138. package/fesm2022/loomui-ng-ui-slider.mjs +390 -0
  139. package/fesm2022/loomui-ng-ui-slider.mjs.map +1 -0
  140. package/fesm2022/loomui-ng-ui-spinner.mjs +85 -0
  141. package/fesm2022/loomui-ng-ui-spinner.mjs.map +1 -0
  142. package/fesm2022/loomui-ng-ui-switch.mjs +212 -0
  143. package/fesm2022/loomui-ng-ui-switch.mjs.map +1 -0
  144. package/fesm2022/loomui-ng-ui-table.mjs +559 -0
  145. package/fesm2022/loomui-ng-ui-table.mjs.map +1 -0
  146. package/fesm2022/loomui-ng-ui-tabs.mjs +544 -0
  147. package/fesm2022/loomui-ng-ui-tabs.mjs.map +1 -0
  148. package/fesm2022/loomui-ng-ui-textarea.mjs +206 -0
  149. package/fesm2022/loomui-ng-ui-textarea.mjs.map +1 -0
  150. package/fesm2022/loomui-ng-ui-toast.mjs +432 -0
  151. package/fesm2022/loomui-ng-ui-toast.mjs.map +1 -0
  152. package/fesm2022/loomui-ng-ui-toggle-group.mjs +477 -0
  153. package/fesm2022/loomui-ng-ui-toggle-group.mjs.map +1 -0
  154. package/fesm2022/loomui-ng-ui-toggle.mjs +219 -0
  155. package/fesm2022/loomui-ng-ui-toggle.mjs.map +1 -0
  156. package/fesm2022/loomui-ng-ui-tooltip.mjs +240 -0
  157. package/fesm2022/loomui-ng-ui-tooltip.mjs.map +1 -0
  158. package/fesm2022/loomui-ng-ui-typography.mjs +129 -0
  159. package/fesm2022/loomui-ng-ui-typography.mjs.map +1 -0
  160. package/fesm2022/loomui-ng-ui-utils.mjs +1533 -0
  161. package/fesm2022/loomui-ng-ui-utils.mjs.map +1 -0
  162. package/fesm2022/loomui-ng-ui.mjs +4 -0
  163. package/fesm2022/loomui-ng-ui.mjs.map +1 -0
  164. package/field/README.md +43 -0
  165. package/hover-card/README.md +31 -0
  166. package/icon/README.md +42 -0
  167. package/input/README.md +26 -0
  168. package/input-group/README.md +40 -0
  169. package/input-otp/README.md +35 -0
  170. package/item/README.md +33 -0
  171. package/kbd/README.md +21 -0
  172. package/label/README.md +24 -0
  173. package/marker/README.md +24 -0
  174. package/menubar/README.md +40 -0
  175. package/message/README.md +32 -0
  176. package/message-scroller/README.md +40 -0
  177. package/native-select/README.md +26 -0
  178. package/navigation-menu/README.md +39 -0
  179. package/package.json +325 -3
  180. package/pagination/README.md +37 -0
  181. package/popover/README.md +37 -0
  182. package/progress/README.md +25 -0
  183. package/questionnaire/README.md +52 -0
  184. package/radio-group/README.md +33 -0
  185. package/resizable/README.md +37 -0
  186. package/scroll-area/README.md +25 -0
  187. package/select/README.md +45 -0
  188. package/separator/README.md +28 -0
  189. package/sheet/README.md +38 -0
  190. package/sidebar/README.md +60 -0
  191. package/skeleton/README.md +21 -0
  192. package/slider/README.md +29 -0
  193. package/spinner/README.md +15 -0
  194. package/styles/loomui.css +330 -0
  195. package/switch/README.md +29 -0
  196. package/table/README.md +31 -0
  197. package/tabs/README.md +42 -0
  198. package/textarea/README.md +28 -0
  199. package/toast/README.md +27 -0
  200. package/toggle/README.md +27 -0
  201. package/toggle-group/README.md +37 -0
  202. package/tooltip/README.md +31 -0
  203. package/types/loomui-ng-ui-accordion.d.ts +141 -0
  204. package/types/loomui-ng-ui-alert-dialog.d.ts +175 -0
  205. package/types/loomui-ng-ui-alert.d.ts +77 -0
  206. package/types/loomui-ng-ui-aspect-ratio.d.ts +31 -0
  207. package/types/loomui-ng-ui-attachment.d.ts +192 -0
  208. package/types/loomui-ng-ui-avatar.d.ts +147 -0
  209. package/types/loomui-ng-ui-badge.d.ts +32 -0
  210. package/types/loomui-ng-ui-breadcrumb.d.ts +118 -0
  211. package/types/loomui-ng-ui-bubble.d.ts +100 -0
  212. package/types/loomui-ng-ui-button-group.d.ts +51 -0
  213. package/types/loomui-ng-ui-button.d.ts +57 -0
  214. package/types/loomui-ng-ui-calendar.d.ts +171 -0
  215. package/types/loomui-ng-ui-card.d.ts +123 -0
  216. package/types/loomui-ng-ui-carousel.d.ts +140 -0
  217. package/types/loomui-ng-ui-chart.d.ts +95 -0
  218. package/types/loomui-ng-ui-checkbox.d.ts +62 -0
  219. package/types/loomui-ng-ui-collapsible.d.ts +74 -0
  220. package/types/loomui-ng-ui-combobox.d.ts +229 -0
  221. package/types/loomui-ng-ui-command.d.ts +231 -0
  222. package/types/loomui-ng-ui-context-menu.d.ts +288 -0
  223. package/types/loomui-ng-ui-data-table.d.ts +111 -0
  224. package/types/loomui-ng-ui-date-picker.d.ts +63 -0
  225. package/types/loomui-ng-ui-dialog.d.ts +127 -0
  226. package/types/loomui-ng-ui-direction.d.ts +42 -0
  227. package/types/loomui-ng-ui-drawer.d.ts +149 -0
  228. package/types/loomui-ng-ui-dropdown-menu.d.ts +258 -0
  229. package/types/loomui-ng-ui-empty.d.ts +109 -0
  230. package/types/loomui-ng-ui-field.d.ts +169 -0
  231. package/types/loomui-ng-ui-hover-card.d.ts +62 -0
  232. package/types/loomui-ng-ui-icon.d.ts +156 -0
  233. package/types/loomui-ng-ui-input-group.d.ts +130 -0
  234. package/types/loomui-ng-ui-input-otp.d.ts +149 -0
  235. package/types/loomui-ng-ui-input.d.ts +89 -0
  236. package/types/loomui-ng-ui-item.d.ts +157 -0
  237. package/types/loomui-ng-ui-kbd.d.ts +36 -0
  238. package/types/loomui-ng-ui-label.d.ts +19 -0
  239. package/types/loomui-ng-ui-marker.d.ts +61 -0
  240. package/types/loomui-ng-ui-menubar.d.ts +321 -0
  241. package/types/loomui-ng-ui-message-scroller.d.ts +138 -0
  242. package/types/loomui-ng-ui-message.d.ts +109 -0
  243. package/types/loomui-ng-ui-native-select.d.ts +84 -0
  244. package/types/loomui-ng-ui-navigation-menu.d.ts +160 -0
  245. package/types/loomui-ng-ui-pagination.d.ts +130 -0
  246. package/types/loomui-ng-ui-popover.d.ts +90 -0
  247. package/types/loomui-ng-ui-progress.d.ts +39 -0
  248. package/types/loomui-ng-ui-questionnaire.d.ts +274 -0
  249. package/types/loomui-ng-ui-radio-group.d.ts +109 -0
  250. package/types/loomui-ng-ui-resizable.d.ts +121 -0
  251. package/types/loomui-ng-ui-scroll-area.d.ts +44 -0
  252. package/types/loomui-ng-ui-select.d.ts +204 -0
  253. package/types/loomui-ng-ui-separator.d.ts +35 -0
  254. package/types/loomui-ng-ui-sheet.d.ts +124 -0
  255. package/types/loomui-ng-ui-sidebar.d.ts +485 -0
  256. package/types/loomui-ng-ui-skeleton.d.ts +20 -0
  257. package/types/loomui-ng-ui-slider.d.ts +103 -0
  258. package/types/loomui-ng-ui-spinner.d.ts +19 -0
  259. package/types/loomui-ng-ui-switch.d.ts +56 -0
  260. package/types/loomui-ng-ui-table.d.ts +148 -0
  261. package/types/loomui-ng-ui-tabs.d.ts +148 -0
  262. package/types/loomui-ng-ui-textarea.d.ts +52 -0
  263. package/types/loomui-ng-ui-toast.d.ts +97 -0
  264. package/types/loomui-ng-ui-toggle-group.d.ts +138 -0
  265. package/types/loomui-ng-ui-toggle.d.ts +63 -0
  266. package/types/loomui-ng-ui-tooltip.d.ts +63 -0
  267. package/types/loomui-ng-ui-typography.d.ts +42 -0
  268. package/types/loomui-ng-ui-utils.d.ts +392 -0
  269. package/types/loomui-ng-ui.d.ts +5 -0
  270. package/typography/README.md +29 -0
@@ -0,0 +1,713 @@
1
+ import * as i0 from "@angular/core";
2
+ import { Directive, booleanAttribute, computed, input } from "@angular/core";
3
+ import { cva } from "class-variance-authority";
4
+ import * as i1 from "@loomui-ng/ui/utils";
5
+ import { UiElementHost, cn } from "@loomui-ng/ui/utils";
6
+ import { buttonVariants } from "@loomui-ng/ui/button";
7
+ var UiAttachmentGroup = class UiAttachmentGroup {
8
+ userClass = input("", {
9
+ ...ngDevMode ? { debugName: "userClass" } : /* istanbul ignore next */ {},
10
+ alias: "class"
11
+ });
12
+ classes = computed(() => cn("flex min-w-0 scroll-fade-x snap-x snap-mandatory scroll-px-1 scrollbar-none gap-3 overflow-x-auto overscroll-x-contain py-1 *:data-[slot=attachment]:flex-none *:data-[slot=attachment]:snap-start w-full", this.userClass()), ...ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []);
13
+ static ɵfac = i0.ɵɵngDeclareFactory({
14
+ minVersion: "12.0.0",
15
+ version: "22.2.2",
16
+ ngImport: i0,
17
+ type: UiAttachmentGroup,
18
+ deps: [],
19
+ target: i0.ɵɵFactoryTarget.Directive
20
+ });
21
+ static ɵdir = i0.ɵɵngDeclareDirective({
22
+ minVersion: "17.1.0",
23
+ version: "22.2.2",
24
+ type: UiAttachmentGroup,
25
+ isStandalone: true,
26
+ selector: "[uiAttachmentGroup], ui-attachment-group",
27
+ inputs: { userClass: {
28
+ classPropertyName: "userClass",
29
+ publicName: "class",
30
+ isSignal: true,
31
+ isRequired: false,
32
+ transformFunction: null
33
+ } },
34
+ host: {
35
+ attributes: { "data-slot": "attachment-group" },
36
+ properties: { "attr.class": "classes()" }
37
+ },
38
+ hostDirectives: [{ directive: i1.UiElementHost }],
39
+ ngImport: i0
40
+ });
41
+ };
42
+ i0.ɵɵngDeclareClassMetadata({
43
+ minVersion: "12.0.0",
44
+ version: "22.2.2",
45
+ ngImport: i0,
46
+ type: UiAttachmentGroup,
47
+ decorators: [{
48
+ type: Directive,
49
+ args: [{
50
+ selector: "[uiAttachmentGroup], ui-attachment-group",
51
+ hostDirectives: [UiElementHost],
52
+ host: {
53
+ "data-slot": "attachment-group",
54
+ "[attr.class]": "classes()"
55
+ }
56
+ }]
57
+ }],
58
+ propDecorators: { userClass: [{
59
+ type: i0.Input,
60
+ args: [{
61
+ isSignal: true,
62
+ alias: "class",
63
+ required: false
64
+ }]
65
+ }] }
66
+ });
67
+ const attachmentVariants = cva("group/attachment relative flex max-w-full shrink-0 flex-wrap border bg-card text-card-foreground transition-colors focus-within:ring-1 focus-within:ring-ring/30 has-[>a,>button]:hover:bg-muted/50 data-[state=error]:border-destructive/30 data-[state=idle]:border-dashed", {
68
+ variants: {
69
+ size: {
70
+ default: "rounded-2xl gap-2 text-sm has-data-[slot=attachment-content]:px-2.5 has-data-[slot=attachment-content]:py-2 has-data-[slot=attachment-media]:p-2",
71
+ sm: "rounded-2xl gap-2.5 text-xs has-data-[slot=attachment-content]:px-2 has-data-[slot=attachment-content]:py-1.5 has-data-[slot=attachment-media]:p-1.5 min-w-40 items-center w-full",
72
+ xs: "gap-1.5 rounded-xl text-xs has-data-[slot=attachment-content]:px-1.5 has-data-[slot=attachment-content]:py-1 has-data-[slot=attachment-media]:p-1 min-w-40 items-center w-full"
73
+ },
74
+ orientation: {
75
+ vertical: "min-w-0 rounded-2xl gap-2 text-sm has-data-[slot=attachment-content]:px-2.5 has-data-[slot=attachment-content]:py-2 has-data-[slot=attachment-media]:p-2 w-24 flex-col has-data-[slot=attachment-content]:w-30",
76
+ horizontal: "min-w-40 items-center w-full"
77
+ }
78
+ },
79
+ defaultVariants: {
80
+ size: "default",
81
+ orientation: "vertical"
82
+ }
83
+ });
84
+ var UiAttachment = class UiAttachment {
85
+ state = input("done", ...ngDevMode ? [{ debugName: "state" }] : /* istanbul ignore next */ []);
86
+ size = input("default", ...ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []);
87
+ orientation = input("vertical", ...ngDevMode ? [{ debugName: "orientation" }] : /* istanbul ignore next */ []);
88
+ userClass = input("", {
89
+ ...ngDevMode ? { debugName: "userClass" } : /* istanbul ignore next */ {},
90
+ alias: "class"
91
+ });
92
+ classes = computed(() => cn(attachmentVariants({
93
+ size: this.size(),
94
+ orientation: this.orientation()
95
+ }), this.userClass()), ...ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []);
96
+ static ɵfac = i0.ɵɵngDeclareFactory({
97
+ minVersion: "12.0.0",
98
+ version: "22.2.2",
99
+ ngImport: i0,
100
+ type: UiAttachment,
101
+ deps: [],
102
+ target: i0.ɵɵFactoryTarget.Directive
103
+ });
104
+ static ɵdir = i0.ɵɵngDeclareDirective({
105
+ minVersion: "17.1.0",
106
+ version: "22.2.2",
107
+ type: UiAttachment,
108
+ isStandalone: true,
109
+ selector: "[uiAttachment], ui-attachment",
110
+ inputs: {
111
+ state: {
112
+ classPropertyName: "state",
113
+ publicName: "state",
114
+ isSignal: true,
115
+ isRequired: false,
116
+ transformFunction: null
117
+ },
118
+ size: {
119
+ classPropertyName: "size",
120
+ publicName: "size",
121
+ isSignal: true,
122
+ isRequired: false,
123
+ transformFunction: null
124
+ },
125
+ orientation: {
126
+ classPropertyName: "orientation",
127
+ publicName: "orientation",
128
+ isSignal: true,
129
+ isRequired: false,
130
+ transformFunction: null
131
+ },
132
+ userClass: {
133
+ classPropertyName: "userClass",
134
+ publicName: "class",
135
+ isSignal: true,
136
+ isRequired: false,
137
+ transformFunction: null
138
+ }
139
+ },
140
+ host: {
141
+ attributes: { "data-slot": "attachment" },
142
+ properties: {
143
+ "attr.data-size": "size()",
144
+ "attr.data-orientation": "orientation()",
145
+ "attr.data-state": "state()",
146
+ "attr.class": "classes()"
147
+ }
148
+ },
149
+ hostDirectives: [{ directive: i1.UiElementHost }],
150
+ ngImport: i0
151
+ });
152
+ };
153
+ i0.ɵɵngDeclareClassMetadata({
154
+ minVersion: "12.0.0",
155
+ version: "22.2.2",
156
+ ngImport: i0,
157
+ type: UiAttachment,
158
+ decorators: [{
159
+ type: Directive,
160
+ args: [{
161
+ selector: "[uiAttachment], ui-attachment",
162
+ hostDirectives: [UiElementHost],
163
+ host: {
164
+ "data-slot": "attachment",
165
+ "[attr.data-size]": "size()",
166
+ "[attr.data-orientation]": "orientation()",
167
+ "[attr.data-state]": "state()",
168
+ "[attr.class]": "classes()"
169
+ }
170
+ }]
171
+ }],
172
+ propDecorators: {
173
+ state: [{
174
+ type: i0.Input,
175
+ args: [{
176
+ isSignal: true,
177
+ alias: "state",
178
+ required: false
179
+ }]
180
+ }],
181
+ size: [{
182
+ type: i0.Input,
183
+ args: [{
184
+ isSignal: true,
185
+ alias: "size",
186
+ required: false
187
+ }]
188
+ }],
189
+ orientation: [{
190
+ type: i0.Input,
191
+ args: [{
192
+ isSignal: true,
193
+ alias: "orientation",
194
+ required: false
195
+ }]
196
+ }],
197
+ userClass: [{
198
+ type: i0.Input,
199
+ args: [{
200
+ isSignal: true,
201
+ alias: "class",
202
+ required: false
203
+ }]
204
+ }]
205
+ }
206
+ });
207
+ const attachmentMediaVariants = cva("relative flex aspect-square w-10 shrink-0 items-center justify-center overflow-hidden rounded-lg bg-muted text-foreground group-data-[orientation=vertical]/attachment:w-full group-data-[size=sm]/attachment:w-8 group-data-[size=xs]/attachment:w-7 group-data-[size=xs]/attachment:rounded-md group-data-[state=error]/attachment:bg-destructive/10 group-data-[state=error]/attachment:text-destructive group-data-[orientation=vertical]/attachment:*:data-[slot=spinner]:size-6! [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 group-data-[orientation=vertical]/attachment:[&_svg:not([class*='size-'])]:size-6 group-data-[size=xs]/attachment:[&_svg:not([class*='size-'])]:size-3.5", {
208
+ variants: { variant: {
209
+ image: "opacity-60 group-data-[state=done]/attachment:opacity-100 group-data-[state=idle]/attachment:opacity-100 *:[img]:aspect-square *:[img]:w-full *:[img]:object-cover",
210
+ icon: ""
211
+ } },
212
+ defaultVariants: { variant: "icon" }
213
+ });
214
+ var UiAttachmentMedia = class UiAttachmentMedia {
215
+ variant = input("icon", ...ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []);
216
+ userClass = input("", {
217
+ ...ngDevMode ? { debugName: "userClass" } : /* istanbul ignore next */ {},
218
+ alias: "class"
219
+ });
220
+ classes = computed(() => cn(attachmentMediaVariants({ variant: this.variant() }), this.userClass()), ...ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []);
221
+ static ɵfac = i0.ɵɵngDeclareFactory({
222
+ minVersion: "12.0.0",
223
+ version: "22.2.2",
224
+ ngImport: i0,
225
+ type: UiAttachmentMedia,
226
+ deps: [],
227
+ target: i0.ɵɵFactoryTarget.Directive
228
+ });
229
+ static ɵdir = i0.ɵɵngDeclareDirective({
230
+ minVersion: "17.1.0",
231
+ version: "22.2.2",
232
+ type: UiAttachmentMedia,
233
+ isStandalone: true,
234
+ selector: "[uiAttachmentMedia], ui-attachment-media",
235
+ inputs: {
236
+ variant: {
237
+ classPropertyName: "variant",
238
+ publicName: "variant",
239
+ isSignal: true,
240
+ isRequired: false,
241
+ transformFunction: null
242
+ },
243
+ userClass: {
244
+ classPropertyName: "userClass",
245
+ publicName: "class",
246
+ isSignal: true,
247
+ isRequired: false,
248
+ transformFunction: null
249
+ }
250
+ },
251
+ host: {
252
+ attributes: { "data-slot": "attachment-media" },
253
+ properties: {
254
+ "attr.data-variant": "variant()",
255
+ "attr.class": "classes()"
256
+ }
257
+ },
258
+ hostDirectives: [{ directive: i1.UiElementHost }],
259
+ ngImport: i0
260
+ });
261
+ };
262
+ i0.ɵɵngDeclareClassMetadata({
263
+ minVersion: "12.0.0",
264
+ version: "22.2.2",
265
+ ngImport: i0,
266
+ type: UiAttachmentMedia,
267
+ decorators: [{
268
+ type: Directive,
269
+ args: [{
270
+ selector: "[uiAttachmentMedia], ui-attachment-media",
271
+ hostDirectives: [UiElementHost],
272
+ host: {
273
+ "data-slot": "attachment-media",
274
+ "[attr.data-variant]": "variant()",
275
+ "[attr.class]": "classes()"
276
+ }
277
+ }]
278
+ }],
279
+ propDecorators: {
280
+ variant: [{
281
+ type: i0.Input,
282
+ args: [{
283
+ isSignal: true,
284
+ alias: "variant",
285
+ required: false
286
+ }]
287
+ }],
288
+ userClass: [{
289
+ type: i0.Input,
290
+ args: [{
291
+ isSignal: true,
292
+ alias: "class",
293
+ required: false
294
+ }]
295
+ }]
296
+ }
297
+ });
298
+ var UiAttachmentContent = class UiAttachmentContent {
299
+ userClass = input("", {
300
+ ...ngDevMode ? { debugName: "userClass" } : /* istanbul ignore next */ {},
301
+ alias: "class"
302
+ });
303
+ classes = computed(() => cn("max-w-full min-w-0 flex-1 leading-tight group-data-[orientation=vertical]/attachment:px-1", this.userClass()), ...ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []);
304
+ static ɵfac = i0.ɵɵngDeclareFactory({
305
+ minVersion: "12.0.0",
306
+ version: "22.2.2",
307
+ ngImport: i0,
308
+ type: UiAttachmentContent,
309
+ deps: [],
310
+ target: i0.ɵɵFactoryTarget.Directive
311
+ });
312
+ static ɵdir = i0.ɵɵngDeclareDirective({
313
+ minVersion: "17.1.0",
314
+ version: "22.2.2",
315
+ type: UiAttachmentContent,
316
+ isStandalone: true,
317
+ selector: "[uiAttachmentContent], ui-attachment-content",
318
+ inputs: { userClass: {
319
+ classPropertyName: "userClass",
320
+ publicName: "class",
321
+ isSignal: true,
322
+ isRequired: false,
323
+ transformFunction: null
324
+ } },
325
+ host: {
326
+ attributes: { "data-slot": "attachment-content" },
327
+ properties: { "attr.class": "classes()" }
328
+ },
329
+ hostDirectives: [{ directive: i1.UiElementHost }],
330
+ ngImport: i0
331
+ });
332
+ };
333
+ i0.ɵɵngDeclareClassMetadata({
334
+ minVersion: "12.0.0",
335
+ version: "22.2.2",
336
+ ngImport: i0,
337
+ type: UiAttachmentContent,
338
+ decorators: [{
339
+ type: Directive,
340
+ args: [{
341
+ selector: "[uiAttachmentContent], ui-attachment-content",
342
+ hostDirectives: [UiElementHost],
343
+ host: {
344
+ "data-slot": "attachment-content",
345
+ "[attr.class]": "classes()"
346
+ }
347
+ }]
348
+ }],
349
+ propDecorators: { userClass: [{
350
+ type: i0.Input,
351
+ args: [{
352
+ isSignal: true,
353
+ alias: "class",
354
+ required: false
355
+ }]
356
+ }] }
357
+ });
358
+ var UiAttachmentTitle = class UiAttachmentTitle {
359
+ userClass = input("", {
360
+ ...ngDevMode ? { debugName: "userClass" } : /* istanbul ignore next */ {},
361
+ alias: "class"
362
+ });
363
+ classes = computed(() => cn("block max-w-full min-w-0 truncate font-medium group-data-[state=processing]/attachment:shimmer group-data-[state=uploading]/attachment:shimmer", this.userClass()), ...ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []);
364
+ static ɵfac = i0.ɵɵngDeclareFactory({
365
+ minVersion: "12.0.0",
366
+ version: "22.2.2",
367
+ ngImport: i0,
368
+ type: UiAttachmentTitle,
369
+ deps: [],
370
+ target: i0.ɵɵFactoryTarget.Directive
371
+ });
372
+ static ɵdir = i0.ɵɵngDeclareDirective({
373
+ minVersion: "17.1.0",
374
+ version: "22.2.2",
375
+ type: UiAttachmentTitle,
376
+ isStandalone: true,
377
+ selector: "span[uiAttachmentTitle], ui-attachment-title",
378
+ inputs: { userClass: {
379
+ classPropertyName: "userClass",
380
+ publicName: "class",
381
+ isSignal: true,
382
+ isRequired: false,
383
+ transformFunction: null
384
+ } },
385
+ host: {
386
+ attributes: { "data-slot": "attachment-title" },
387
+ properties: { "attr.class": "classes()" }
388
+ },
389
+ hostDirectives: [{ directive: i1.UiElementHost }],
390
+ ngImport: i0
391
+ });
392
+ };
393
+ i0.ɵɵngDeclareClassMetadata({
394
+ minVersion: "12.0.0",
395
+ version: "22.2.2",
396
+ ngImport: i0,
397
+ type: UiAttachmentTitle,
398
+ decorators: [{
399
+ type: Directive,
400
+ args: [{
401
+ selector: "span[uiAttachmentTitle], ui-attachment-title",
402
+ hostDirectives: [UiElementHost],
403
+ host: {
404
+ "data-slot": "attachment-title",
405
+ "[attr.class]": "classes()"
406
+ }
407
+ }]
408
+ }],
409
+ propDecorators: { userClass: [{
410
+ type: i0.Input,
411
+ args: [{
412
+ isSignal: true,
413
+ alias: "class",
414
+ required: false
415
+ }]
416
+ }] }
417
+ });
418
+ var UiAttachmentDescription = class UiAttachmentDescription {
419
+ userClass = input("", {
420
+ ...ngDevMode ? { debugName: "userClass" } : /* istanbul ignore next */ {},
421
+ alias: "class"
422
+ });
423
+ classes = computed(() => cn("mt-0.5 block min-w-0 truncate text-xs text-muted-foreground group-data-[state=error]/attachment:text-destructive/80 max-w-full", this.userClass()), ...ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []);
424
+ static ɵfac = i0.ɵɵngDeclareFactory({
425
+ minVersion: "12.0.0",
426
+ version: "22.2.2",
427
+ ngImport: i0,
428
+ type: UiAttachmentDescription,
429
+ deps: [],
430
+ target: i0.ɵɵFactoryTarget.Directive
431
+ });
432
+ static ɵdir = i0.ɵɵngDeclareDirective({
433
+ minVersion: "17.1.0",
434
+ version: "22.2.2",
435
+ type: UiAttachmentDescription,
436
+ isStandalone: true,
437
+ selector: "span[uiAttachmentDescription], ui-attachment-description",
438
+ inputs: { userClass: {
439
+ classPropertyName: "userClass",
440
+ publicName: "class",
441
+ isSignal: true,
442
+ isRequired: false,
443
+ transformFunction: null
444
+ } },
445
+ host: {
446
+ attributes: { "data-slot": "attachment-description" },
447
+ properties: { "attr.class": "classes()" }
448
+ },
449
+ hostDirectives: [{ directive: i1.UiElementHost }],
450
+ ngImport: i0
451
+ });
452
+ };
453
+ i0.ɵɵngDeclareClassMetadata({
454
+ minVersion: "12.0.0",
455
+ version: "22.2.2",
456
+ ngImport: i0,
457
+ type: UiAttachmentDescription,
458
+ decorators: [{
459
+ type: Directive,
460
+ args: [{
461
+ selector: "span[uiAttachmentDescription], ui-attachment-description",
462
+ hostDirectives: [UiElementHost],
463
+ host: {
464
+ "data-slot": "attachment-description",
465
+ "[attr.class]": "classes()"
466
+ }
467
+ }]
468
+ }],
469
+ propDecorators: { userClass: [{
470
+ type: i0.Input,
471
+ args: [{
472
+ isSignal: true,
473
+ alias: "class",
474
+ required: false
475
+ }]
476
+ }] }
477
+ });
478
+ var UiAttachmentActions = class UiAttachmentActions {
479
+ userClass = input("", {
480
+ ...ngDevMode ? { debugName: "userClass" } : /* istanbul ignore next */ {},
481
+ alias: "class"
482
+ });
483
+ classes = computed(() => cn("relative z-20 flex shrink-0 items-center group-data-[orientation=vertical]/attachment:absolute group-data-[orientation=vertical]/attachment:top-3 group-data-[orientation=vertical]/attachment:end-3 group-data-[orientation=vertical]/attachment:gap-1", this.userClass()), ...ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []);
484
+ static ɵfac = i0.ɵɵngDeclareFactory({
485
+ minVersion: "12.0.0",
486
+ version: "22.2.2",
487
+ ngImport: i0,
488
+ type: UiAttachmentActions,
489
+ deps: [],
490
+ target: i0.ɵɵFactoryTarget.Directive
491
+ });
492
+ static ɵdir = i0.ɵɵngDeclareDirective({
493
+ minVersion: "17.1.0",
494
+ version: "22.2.2",
495
+ type: UiAttachmentActions,
496
+ isStandalone: true,
497
+ selector: "[uiAttachmentActions], ui-attachment-actions",
498
+ inputs: { userClass: {
499
+ classPropertyName: "userClass",
500
+ publicName: "class",
501
+ isSignal: true,
502
+ isRequired: false,
503
+ transformFunction: null
504
+ } },
505
+ host: {
506
+ attributes: { "data-slot": "attachment-actions" },
507
+ properties: { "attr.class": "classes()" }
508
+ },
509
+ hostDirectives: [{ directive: i1.UiElementHost }],
510
+ ngImport: i0
511
+ });
512
+ };
513
+ i0.ɵɵngDeclareClassMetadata({
514
+ minVersion: "12.0.0",
515
+ version: "22.2.2",
516
+ ngImport: i0,
517
+ type: UiAttachmentActions,
518
+ decorators: [{
519
+ type: Directive,
520
+ args: [{
521
+ selector: "[uiAttachmentActions], ui-attachment-actions",
522
+ hostDirectives: [UiElementHost],
523
+ host: {
524
+ "data-slot": "attachment-actions",
525
+ "[attr.class]": "classes()"
526
+ }
527
+ }]
528
+ }],
529
+ propDecorators: { userClass: [{
530
+ type: i0.Input,
531
+ args: [{
532
+ isSignal: true,
533
+ alias: "class",
534
+ required: false
535
+ }]
536
+ }] }
537
+ });
538
+ const attachmentTriggerClass = "absolute inset-0 z-10 outline-none";
539
+ const UI_ATTACHMENT_GENERATED = [
540
+ UiAttachmentGroup,
541
+ UiAttachment,
542
+ UiAttachmentMedia,
543
+ UiAttachmentContent,
544
+ UiAttachmentTitle,
545
+ UiAttachmentDescription,
546
+ UiAttachmentActions
547
+ ];
548
+ var UiAttachmentTrigger = class UiAttachmentTrigger {
549
+ userClass = input("", {
550
+ ...ngDevMode ? { debugName: "userClass" } : /* istanbul ignore next */ {},
551
+ alias: "class"
552
+ });
553
+ classes = computed(() => cn(attachmentTriggerClass, this.userClass()), ...ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []);
554
+ static ɵfac = i0.ɵɵngDeclareFactory({
555
+ minVersion: "12.0.0",
556
+ version: "22.2.2",
557
+ ngImport: i0,
558
+ type: UiAttachmentTrigger,
559
+ deps: [],
560
+ target: i0.ɵɵFactoryTarget.Directive
561
+ });
562
+ static ɵdir = i0.ɵɵngDeclareDirective({
563
+ minVersion: "17.1.0",
564
+ version: "22.2.2",
565
+ type: UiAttachmentTrigger,
566
+ isStandalone: true,
567
+ selector: "a[uiAttachmentTrigger], button[uiAttachmentTrigger], ui-attachment-trigger",
568
+ inputs: { userClass: {
569
+ classPropertyName: "userClass",
570
+ publicName: "class",
571
+ isSignal: true,
572
+ isRequired: false,
573
+ transformFunction: null
574
+ } },
575
+ host: {
576
+ attributes: { "data-slot": "attachment-trigger" },
577
+ properties: { "attr.class": "classes()" }
578
+ },
579
+ hostDirectives: [{ directive: i1.UiElementHost }],
580
+ ngImport: i0
581
+ });
582
+ };
583
+ i0.ɵɵngDeclareClassMetadata({
584
+ minVersion: "12.0.0",
585
+ version: "22.2.2",
586
+ ngImport: i0,
587
+ type: UiAttachmentTrigger,
588
+ decorators: [{
589
+ type: Directive,
590
+ args: [{
591
+ selector: "a[uiAttachmentTrigger], button[uiAttachmentTrigger], ui-attachment-trigger",
592
+ hostDirectives: [UiElementHost],
593
+ host: {
594
+ "data-slot": "attachment-trigger",
595
+ "[attr.class]": "classes()"
596
+ }
597
+ }]
598
+ }],
599
+ propDecorators: { userClass: [{
600
+ type: i0.Input,
601
+ args: [{
602
+ isSignal: true,
603
+ alias: "class",
604
+ required: false
605
+ }]
606
+ }] }
607
+ });
608
+ var UiAttachmentAction = class UiAttachmentAction {
609
+ disabled = input(false, {
610
+ ...ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {},
611
+ transform: booleanAttribute
612
+ });
613
+ userClass = input("", {
614
+ ...ngDevMode ? { debugName: "userClass" } : /* istanbul ignore next */ {},
615
+ alias: "class"
616
+ });
617
+ classes = computed(() => cn(buttonVariants({
618
+ variant: "ghost",
619
+ size: "icon-xs"
620
+ }), "relative z-20", this.userClass()), ...ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []);
621
+ static ɵfac = i0.ɵɵngDeclareFactory({
622
+ minVersion: "12.0.0",
623
+ version: "22.2.2",
624
+ ngImport: i0,
625
+ type: UiAttachmentAction,
626
+ deps: [],
627
+ target: i0.ɵɵFactoryTarget.Directive
628
+ });
629
+ static ɵdir = i0.ɵɵngDeclareDirective({
630
+ minVersion: "17.1.0",
631
+ version: "22.2.2",
632
+ type: UiAttachmentAction,
633
+ isStandalone: true,
634
+ selector: "button[uiAttachmentAction], ui-attachment-action",
635
+ inputs: {
636
+ disabled: {
637
+ classPropertyName: "disabled",
638
+ publicName: "disabled",
639
+ isSignal: true,
640
+ isRequired: false,
641
+ transformFunction: null
642
+ },
643
+ userClass: {
644
+ classPropertyName: "userClass",
645
+ publicName: "class",
646
+ isSignal: true,
647
+ isRequired: false,
648
+ transformFunction: null
649
+ }
650
+ },
651
+ host: {
652
+ attributes: {
653
+ "type": "button",
654
+ "data-slot": "attachment-action",
655
+ "data-variant": "ghost",
656
+ "data-size": "icon-xs"
657
+ },
658
+ properties: {
659
+ "attr.disabled": "disabled() ? \"\" : null",
660
+ "attr.class": "classes()"
661
+ }
662
+ },
663
+ hostDirectives: [{ directive: i1.UiElementHost }],
664
+ ngImport: i0
665
+ });
666
+ };
667
+ i0.ɵɵngDeclareClassMetadata({
668
+ minVersion: "12.0.0",
669
+ version: "22.2.2",
670
+ ngImport: i0,
671
+ type: UiAttachmentAction,
672
+ decorators: [{
673
+ type: Directive,
674
+ args: [{
675
+ selector: "button[uiAttachmentAction], ui-attachment-action",
676
+ hostDirectives: [UiElementHost],
677
+ host: {
678
+ "[attr.disabled]": "disabled() ? \"\" : null",
679
+ type: "button",
680
+ "data-slot": "attachment-action",
681
+ "data-variant": "ghost",
682
+ "data-size": "icon-xs",
683
+ "[attr.class]": "classes()"
684
+ }
685
+ }]
686
+ }],
687
+ propDecorators: {
688
+ disabled: [{
689
+ type: i0.Input,
690
+ args: [{
691
+ isSignal: true,
692
+ alias: "disabled",
693
+ required: false
694
+ }]
695
+ }],
696
+ userClass: [{
697
+ type: i0.Input,
698
+ args: [{
699
+ isSignal: true,
700
+ alias: "class",
701
+ required: false
702
+ }]
703
+ }]
704
+ }
705
+ });
706
+ const UI_ATTACHMENT = [
707
+ ...UI_ATTACHMENT_GENERATED,
708
+ UiAttachmentTrigger,
709
+ UiAttachmentAction
710
+ ];
711
+ export { UI_ATTACHMENT, UI_ATTACHMENT_GENERATED, UiAttachment, UiAttachmentAction, UiAttachmentActions, UiAttachmentContent, UiAttachmentDescription, UiAttachmentGroup, UiAttachmentMedia, UiAttachmentTitle, UiAttachmentTrigger, attachmentMediaVariants, attachmentTriggerClass, attachmentVariants };
712
+
713
+ //# sourceMappingURL=loomui-ng-ui-attachment.mjs.map