@ac-design/design-system 1.0.3 → 2.0.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 (186) hide show
  1. package/README.md +27 -18
  2. package/dist/lib/charts/ChartFrame.js +5 -0
  3. package/dist/lib/charts/ChartFrame.vue.d.ts +69 -0
  4. package/dist/lib/charts/ChartFrame.vue_vue_type_script_setup_true_lang.js +168 -0
  5. package/dist/lib/charts/index.d.ts +7 -0
  6. package/dist/lib/charts/index.js +5 -0
  7. package/dist/lib/charts/shared.d.ts +60 -0
  8. package/dist/lib/charts/shared.js +114 -0
  9. package/dist/lib/charts/xy.d.ts +65 -0
  10. package/dist/lib/charts/xy.js +92 -0
  11. package/dist/lib/compat.css +1707 -1042
  12. package/dist/lib/components/AcAccordion.vue_vue_type_script_setup_true_lang.js +2 -2
  13. package/dist/lib/components/AcAccordionItem.vue.d.ts +1 -1
  14. package/dist/lib/components/AcAccordionItem.vue_vue_type_script_setup_true_lang.js +5 -5
  15. package/dist/lib/components/AcAlert.vue.d.ts +1 -1
  16. package/dist/lib/components/AcAlert.vue_vue_type_script_setup_true_lang.js +19 -25
  17. package/dist/lib/components/AcAppSwitcher.vue_vue_type_script_setup_true_lang.js +19 -19
  18. package/dist/lib/components/AcAreaChart.js +5 -0
  19. package/dist/lib/components/AcAreaChart.vue.d.ts +44 -0
  20. package/dist/lib/components/AcAreaChart.vue_vue_type_script_setup_true_lang.js +215 -0
  21. package/dist/lib/components/AcAvatar.vue_vue_type_script_setup_true_lang.js +8 -8
  22. package/dist/lib/components/AcBadge.vue.d.ts +16 -7
  23. package/dist/lib/components/AcBadge.vue_vue_type_script_setup_true_lang.js +59 -43
  24. package/dist/lib/components/AcBanner.vue.d.ts +1 -1
  25. package/dist/lib/components/AcBanner.vue_vue_type_script_setup_true_lang.js +30 -30
  26. package/dist/lib/components/AcBarChart.js +5 -0
  27. package/dist/lib/components/AcBarChart.vue.d.ts +43 -0
  28. package/dist/lib/components/AcBarChart.vue_vue_type_script_setup_true_lang.js +217 -0
  29. package/dist/lib/components/AcBreadcrumb.vue_vue_type_script_setup_true_lang.js +27 -26
  30. package/dist/lib/components/AcBulkActionBar.js +5 -0
  31. package/dist/lib/components/AcBulkActionBar.vue.d.ts +43 -0
  32. package/dist/lib/components/AcBulkActionBar.vue_vue_type_script_setup_true_lang.js +84 -0
  33. package/dist/lib/components/AcButton.vue.d.ts +3 -3
  34. package/dist/lib/components/AcButton.vue_vue_type_script_setup_true_lang.js +42 -34
  35. package/dist/lib/components/AcButtons.vue_vue_type_script_setup_true_lang.js +1 -1
  36. package/dist/lib/components/AcCard.vue.d.ts +10 -2
  37. package/dist/lib/components/AcCard.vue_vue_type_script_setup_true_lang.js +37 -11
  38. package/dist/lib/components/AcCellValue.vue.d.ts +4 -1
  39. package/dist/lib/components/AcCellValue.vue_vue_type_script_setup_true_lang.js +214 -179
  40. package/dist/lib/components/AcCheckBox.vue.d.ts +17 -3
  41. package/dist/lib/components/AcCheckBox.vue_vue_type_script_setup_true_lang.js +126 -29
  42. package/dist/lib/components/AcCheckRadio.vue.d.ts +1 -1
  43. package/dist/lib/components/AcCheckRadio.vue_vue_type_script_setup_true_lang.js +33 -21
  44. package/dist/lib/components/AcCircularProgress.js +5 -0
  45. package/dist/lib/components/AcCircularProgress.vue.d.ts +44 -0
  46. package/dist/lib/components/AcCircularProgress.vue_vue_type_script_setup_true_lang.js +111 -0
  47. package/dist/lib/components/AcClusterSwitcher.vue_vue_type_script_setup_true_lang.js +142 -167
  48. package/dist/lib/components/AcCodeEditor.vue_vue_type_script_setup_true_lang.js +9 -9
  49. package/dist/lib/components/AcColorInput.js +5 -0
  50. package/dist/lib/components/AcColorInput.vue.d.ts +54 -0
  51. package/dist/lib/components/AcColorInput.vue_vue_type_script_setup_true_lang.js +187 -0
  52. package/dist/lib/components/AcConfirmModal.js +5 -0
  53. package/dist/lib/components/AcConfirmModal.vue.d.ts +56 -0
  54. package/dist/lib/components/AcConfirmModal.vue_vue_type_script_setup_true_lang.js +92 -0
  55. package/dist/lib/components/AcContentHeader.vue.d.ts +1 -1
  56. package/dist/lib/components/AcContentHeader.vue_vue_type_script_setup_true_lang.js +5 -4
  57. package/dist/lib/components/AcContentLayout.vue_vue_type_script_setup_true_lang.js +2 -2
  58. package/dist/lib/components/AcCopyButton.js +5 -0
  59. package/dist/lib/components/AcCopyButton.vue.d.ts +43 -0
  60. package/dist/lib/components/AcCopyButton.vue_vue_type_script_setup_true_lang.js +92 -0
  61. package/dist/lib/components/AcDatePicker.vue.d.ts +5 -5
  62. package/dist/lib/components/AcDatePicker.vue_vue_type_script_setup_true_lang.js +204 -213
  63. package/dist/lib/components/AcDeleteModal.vue.d.ts +4 -4
  64. package/dist/lib/components/AcDeleteModal.vue_vue_type_script_setup_true_lang.js +37 -46
  65. package/dist/lib/components/AcDonutChart.js +5 -0
  66. package/dist/lib/components/AcDonutChart.vue.d.ts +73 -0
  67. package/dist/lib/components/AcDonutChart.vue_vue_type_script_setup_true_lang.js +210 -0
  68. package/dist/lib/components/AcDropdown.vue.d.ts +1 -1
  69. package/dist/lib/components/AcDropdown.vue_vue_type_script_setup_true_lang.js +9 -9
  70. package/dist/lib/components/AcDropdownDivider.vue_vue_type_script_setup_true_lang.js +2 -2
  71. package/dist/lib/components/AcDropdownItem.vue.d.ts +1 -1
  72. package/dist/lib/components/AcDropdownItem.vue_vue_type_script_setup_true_lang.js +3 -3
  73. package/dist/lib/components/AcEmptyState.vue.d.ts +4 -1
  74. package/dist/lib/components/AcEmptyState.vue_vue_type_script_setup_true_lang.js +50 -39
  75. package/dist/lib/components/AcFeatureCard.vue_vue_type_script_setup_true_lang.js +14 -13
  76. package/dist/lib/components/AcFileEditor.vue_vue_type_script_setup_true_lang.js +16 -16
  77. package/dist/lib/components/AcFileUpload.vue.d.ts +2 -2
  78. package/dist/lib/components/AcFileUpload.vue_vue_type_script_setup_true_lang.js +55 -53
  79. package/dist/lib/components/AcFontScale.vue_vue_type_script_setup_true_lang.js +2 -2
  80. package/dist/lib/components/AcFooter.js +5 -0
  81. package/dist/lib/components/AcFooter.vue.d.ts +37 -0
  82. package/dist/lib/components/AcFooter.vue_vue_type_script_setup_true_lang.js +107 -0
  83. package/dist/lib/components/AcForm.vue.d.ts +3 -0
  84. package/dist/lib/components/AcForm.vue_vue_type_script_setup_true_lang.js +4 -2
  85. package/dist/lib/components/AcFormArray.vue.d.ts +2 -2
  86. package/dist/lib/components/AcFormArray.vue_vue_type_script_setup_true_lang.js +149 -147
  87. package/dist/lib/components/AcFormFooter.vue.d.ts +2 -2
  88. package/dist/lib/components/AcFormFooter.vue_vue_type_script_setup_true_lang.js +2 -2
  89. package/dist/lib/components/AcFormSection.vue.d.ts +7 -0
  90. package/dist/lib/components/AcFormSection.vue_vue_type_script_setup_true_lang.js +31 -21
  91. package/dist/lib/components/AcHeader.vue.d.ts +3 -3
  92. package/dist/lib/components/AcHeader.vue_vue_type_script_setup_true_lang.js +22 -22
  93. package/dist/lib/components/AcInfoTable.vue_vue_type_script_setup_true_lang.js +17 -13
  94. package/dist/lib/components/AcInput.vue.d.ts +3 -3
  95. package/dist/lib/components/AcInput.vue_vue_type_script_setup_true_lang.js +98 -87
  96. package/dist/lib/components/AcKbd.vue_vue_type_script_setup_true_lang.js +1 -1
  97. package/dist/lib/components/AcKeyValueInput.js +5 -0
  98. package/dist/lib/components/AcKeyValueInput.vue.d.ts +114 -0
  99. package/dist/lib/components/AcKeyValueInput.vue_vue_type_script_setup_true_lang.js +320 -0
  100. package/dist/lib/components/AcLineChart.js +5 -0
  101. package/dist/lib/components/AcLineChart.vue.d.ts +38 -0
  102. package/dist/lib/components/AcLineChart.vue_vue_type_script_setup_true_lang.js +187 -0
  103. package/dist/lib/components/AcLocaleSwitcher.js +5 -0
  104. package/dist/lib/components/AcLocaleSwitcher.vue.d.ts +46 -0
  105. package/dist/lib/components/AcLocaleSwitcher.vue_vue_type_script_setup_true_lang.js +103 -0
  106. package/dist/lib/components/AcModal.vue_vue_type_script_setup_true_lang.js +23 -23
  107. package/dist/lib/components/AcNavbar.vue_vue_type_script_setup_true_lang.js +6 -6
  108. package/dist/lib/components/AcNavbarItem.vue.d.ts +1 -1
  109. package/dist/lib/components/AcNavbarItem.vue_vue_type_script_setup_true_lang.js +22 -22
  110. package/dist/lib/components/AcNotificationMenu.vue_vue_type_script_setup_true_lang.js +26 -26
  111. package/dist/lib/components/AcNumberInput.js +5 -0
  112. package/dist/lib/components/AcNumberInput.vue.d.ts +79 -0
  113. package/dist/lib/components/AcNumberInput.vue_vue_type_script_setup_true_lang.js +251 -0
  114. package/dist/lib/components/AcPage.vue.d.ts +2 -2
  115. package/dist/lib/components/AcPage.vue_vue_type_script_setup_true_lang.js +2 -2
  116. package/dist/lib/components/AcPagination.vue.d.ts +20 -3
  117. package/dist/lib/components/AcPagination.vue_vue_type_script_setup_true_lang.js +81 -53
  118. package/dist/lib/components/AcPreloader.vue.d.ts +1 -1
  119. package/dist/lib/components/AcPreloader.vue_vue_type_script_setup_true_lang.js +3 -3
  120. package/dist/lib/components/AcProgress.vue.d.ts +2 -2
  121. package/dist/lib/components/AcProgress.vue_vue_type_script_setup_true_lang.js +4 -4
  122. package/dist/lib/components/AcResourceCard.vue.d.ts +2 -2
  123. package/dist/lib/components/AcResourceCard.vue_vue_type_script_setup_true_lang.js +13 -13
  124. package/dist/lib/components/AcSearchBar.vue.d.ts +1 -1
  125. package/dist/lib/components/AcSearchBar.vue_vue_type_script_setup_true_lang.js +9 -8
  126. package/dist/lib/components/AcSectionContent.vue.d.ts +2 -2
  127. package/dist/lib/components/AcSectionContent.vue_vue_type_script_setup_true_lang.js +8 -8
  128. package/dist/lib/components/AcSegmentedControl.vue.d.ts +1 -1
  129. package/dist/lib/components/AcSegmentedControl.vue_vue_type_script_setup_true_lang.js +4 -4
  130. package/dist/lib/components/AcSelect.vue.d.ts +4 -4
  131. package/dist/lib/components/AcSelect.vue_vue_type_script_setup_true_lang.js +230 -227
  132. package/dist/lib/components/AcSidePanel.vue_vue_type_script_setup_true_lang.js +31 -31
  133. package/dist/lib/components/AcSideTabs.vue.d.ts +1 -1
  134. package/dist/lib/components/AcSideTabs.vue_vue_type_script_setup_true_lang.js +37 -37
  135. package/dist/lib/components/AcSidebar.vue.d.ts +3 -3
  136. package/dist/lib/components/AcSidebar.vue_vue_type_script_setup_true_lang.js +75 -75
  137. package/dist/lib/components/AcSidebarItem.vue_vue_type_script_setup_true_lang.js +33 -32
  138. package/dist/lib/components/AcSidebarSection.vue_vue_type_script_setup_true_lang.js +6 -6
  139. package/dist/lib/components/AcSkeleton.vue_vue_type_script_setup_true_lang.js +8 -8
  140. package/dist/lib/components/AcSlider.vue.d.ts +1 -1
  141. package/dist/lib/components/AcSlider.vue_vue_type_script_setup_true_lang.js +174 -172
  142. package/dist/lib/components/AcStatCard.vue.d.ts +3 -3
  143. package/dist/lib/components/AcStatCard.vue_vue_type_script_setup_true_lang.js +90 -85
  144. package/dist/lib/components/AcStatusBar.vue.d.ts +1 -1
  145. package/dist/lib/components/AcStatusBar.vue_vue_type_script_setup_true_lang.js +6 -6
  146. package/dist/lib/components/AcSteps.vue_vue_type_script_setup_true_lang.js +28 -28
  147. package/dist/lib/components/AcSwitch.vue_vue_type_script_setup_true_lang.js +39 -34
  148. package/dist/lib/components/AcSwitchCard.js +5 -0
  149. package/dist/lib/components/AcSwitchCard.vue.d.ts +59 -0
  150. package/dist/lib/components/AcSwitchCard.vue_vue_type_script_setup_true_lang.js +119 -0
  151. package/dist/lib/components/AcTable.vue_vue_type_script_setup_true_lang.js +87 -87
  152. package/dist/lib/components/AcTabs.vue_vue_type_script_setup_true_lang.js +4 -4
  153. package/dist/lib/components/AcTag.vue.d.ts +1 -1
  154. package/dist/lib/components/AcTag.vue_vue_type_script_setup_true_lang.js +22 -22
  155. package/dist/lib/components/AcTagInput.js +5 -0
  156. package/dist/lib/components/AcTagInput.vue.d.ts +74 -0
  157. package/dist/lib/components/AcTagInput.vue_vue_type_script_setup_true_lang.js +291 -0
  158. package/dist/lib/components/AcTextarea.vue.d.ts +3 -3
  159. package/dist/lib/components/AcTextarea.vue_vue_type_script_setup_true_lang.js +89 -64
  160. package/dist/lib/components/AcThemeMode.vue_vue_type_script_setup_true_lang.js +3 -3
  161. package/dist/lib/components/AcTimePicker.js +5 -0
  162. package/dist/lib/components/AcTimePicker.vue.d.ts +65 -0
  163. package/dist/lib/components/AcTimePicker.vue_vue_type_script_setup_true_lang.js +463 -0
  164. package/dist/lib/components/AcToaster.vue_vue_type_script_setup_true_lang.js +65 -71
  165. package/dist/lib/components/AcTooltip.vue.d.ts +1 -1
  166. package/dist/lib/components/AcTooltip.vue_vue_type_script_setup_true_lang.js +77 -67
  167. package/dist/lib/components/AcUsageCard.vue_vue_type_script_setup_true_lang.js +27 -27
  168. package/dist/lib/components/AcUserMenu.vue_vue_type_script_setup_true_lang.js +111 -103
  169. package/dist/lib/components/index.d.ts +14 -2
  170. package/dist/lib/components/status.d.ts +26 -0
  171. package/dist/lib/components/status.js +110 -0
  172. package/dist/lib/composables/copyText.d.ts +2 -1
  173. package/dist/lib/composables/copyText.js +2 -2
  174. package/dist/lib/composables/useApiPagination.d.ts +55 -0
  175. package/dist/lib/composables/useApiPagination.js +58 -0
  176. package/dist/lib/composables/useBulkSelection.d.ts +44 -0
  177. package/dist/lib/composables/useBulkSelection.js +41 -0
  178. package/dist/lib/composables/useFormValidation.d.ts +65 -0
  179. package/dist/lib/composables/useFormValidation.js +148 -0
  180. package/dist/lib/composables/useTablePagination.d.ts +49 -0
  181. package/dist/lib/composables/useTablePagination.js +41 -0
  182. package/dist/lib/editor/theme.js +65 -62
  183. package/dist/lib/index.d.ts +14 -0
  184. package/dist/lib/index.js +95 -78
  185. package/dist/lib/theme.css +391 -272
  186. package/package.json +11 -4
@@ -1,38 +1,48 @@
1
- import { computed as e, createCommentVNode as t, createElementBlock as n, createElementVNode as r, createTextVNode as i, defineComponent as a, inject as o, normalizeClass as s, openBlock as c, renderSlot as l, toDisplayString as u, unref as d, useId as f } from "vue";
1
+ import { computed as e, createBlock as t, createCommentVNode as n, createElementBlock as r, createElementVNode as i, createTextVNode as a, defineComponent as o, inject as s, normalizeClass as c, openBlock as l, renderSlot as u, resolveDynamicComponent as d, toDisplayString as f, unref as p, useId as m } from "vue";
2
2
  //#region src/lib/components/AcFormSection.vue?vue&type=script&setup=true&lang.ts
3
- var p = ["aria-labelledby", "aria-describedby"], m = { class: "min-w-0 flex-1" }, h = ["id"], g = ["id"], _ = {
3
+ var h = ["aria-labelledby", "aria-describedby"], g = {
4
4
  key: 0,
5
+ class: "flex size-7 shrink-0 items-center justify-center rounded-8 border border-primary/20 bg-primary/8 text-primary",
6
+ "aria-hidden": "true"
7
+ }, _ = { class: "min-w-0 flex-1" }, v = ["id"], y = ["id"], b = {
8
+ key: 1,
5
9
  class: "flex shrink-0 items-center gap-2"
6
- }, v = /*@__PURE__*/ a({
10
+ }, x = /*@__PURE__*/ o({
7
11
  __name: "AcFormSection",
8
12
  props: {
9
13
  title: { default: "" },
10
14
  description: { default: "" },
15
+ icon: { default: void 0 },
11
16
  layout: { default: void 0 },
17
+ variant: { default: void 0 },
12
18
  columns: { default: 1 }
13
19
  },
14
- setup(a) {
15
- let v = a, y = o("ac-form", null), b = f(), x = e(() => v.layout ?? y?.layout.value ?? "stacked");
16
- return (e, o) => (c(), n("div", {
20
+ setup(o) {
21
+ let x = o, S = s("ac-form", null), C = m(), w = e(() => x.layout ?? S?.layout.value ?? "stacked"), T = e(() => x.variant ?? S?.variant?.value ?? "card");
22
+ return (e, s) => (l(), r("div", {
17
23
  role: "group",
18
- "aria-labelledby": a.title ? `${d(b)}-title` : void 0,
19
- "aria-describedby": a.description || e.$slots.description ? `${d(b)}-desc` : void 0,
20
- class: s(["border-t border-border-light py-7 first:border-t-0 first:pt-0", x.value === "aside" && "md:grid md:grid-cols-[minmax(0,1fr)_minmax(0,2fr)] md:gap-10"]),
24
+ "aria-labelledby": o.title ? `${p(C)}-title` : void 0,
25
+ "aria-describedby": o.description || e.$slots.description ? `${p(C)}-desc` : void 0,
26
+ class: c([T.value === "card" ? "rounded-14 border border-border bg-surface p-5" : "border-t border-border py-7 first:border-t-0 first:pt-0", w.value === "aside" && "md:grid md:grid-cols-[minmax(0,1fr)_minmax(0,2fr)] md:gap-10"]),
21
27
  "data-ac-ds": "",
22
28
  "data-testid": "ac-form-section"
23
- }, [a.title || a.description || e.$slots.description || e.$slots.actions ? (c(), n("div", {
29
+ }, [o.title || o.description || o.icon || e.$slots.description || e.$slots.actions ? (l(), r("div", {
24
30
  key: 0,
25
- class: s(["mb-5 flex items-start gap-4", x.value === "aside" && "md:mb-0"])
26
- }, [r("div", m, [a.title ? (c(), n("h3", {
27
- key: 0,
28
- id: `${d(b)}-title`,
29
- class: "text-xl leading-6 font-semibold tracking-[-0.01em] text-heading"
30
- }, u(a.title), 9, h)) : t("", !0), a.description || e.$slots.description ? (c(), n("div", {
31
- key: 1,
32
- id: `${d(b)}-desc`,
33
- class: "mt-1 text-base text-muted [&_a]:font-medium [&_a]:text-primary-20 [&_a]:underline [&_a]:underline-offset-2"
34
- }, [l(e.$slots, "description", {}, () => [i(u(a.description), 1)])], 8, g)) : t("", !0)]), e.$slots.actions && x.value === "stacked" ? (c(), n("div", _, [l(e.$slots, "actions")])) : t("", !0)], 2)) : t("", !0), r("div", { class: s(["grid min-w-0 gap-5", [a.columns === 2 && "sm:grid-cols-2", x.value === "aside" && "md:col-start-2"]]) }, [l(e.$slots, "default")], 2)], 10, p));
31
+ class: c(["mb-5 flex items-start gap-3", w.value === "aside" && "md:mb-0"])
32
+ }, [
33
+ o.icon ? (l(), r("span", g, [(l(), t(d(o.icon), { class: "size-3.5" }))])) : n("", !0),
34
+ i("div", _, [o.title ? (l(), r("h3", {
35
+ key: 0,
36
+ id: `${p(C)}-title`,
37
+ class: c(["font-heading font-semibold tracking-tight text-heading", T.value === "card" ? "text-base" : "text-lg"])
38
+ }, f(o.title), 11, v)) : n("", !0), o.description || e.$slots.description ? (l(), r("div", {
39
+ key: 1,
40
+ id: `${p(C)}-desc`,
41
+ class: c([T.value === "card" ? "mt-0.5 text-xs leading-relaxed" : "mt-1 text-base", "text-muted [&_a]:font-medium [&_a]:text-primary-strong [&_a]:underline [&_a]:underline-offset-2"])
42
+ }, [u(e.$slots, "description", {}, () => [a(f(o.description), 1)])], 10, y)) : n("", !0)]),
43
+ e.$slots.actions && w.value === "stacked" ? (l(), r("div", b, [u(e.$slots, "actions")])) : n("", !0)
44
+ ], 2)) : n("", !0), i("div", { class: c(["grid min-w-0 gap-5", [o.columns === 2 && "sm:grid-cols-2", w.value === "aside" && "md:col-start-2"]]) }, [u(e.$slots, "default")], 2)], 10, h));
35
45
  }
36
46
  });
37
47
  //#endregion
38
- export { v as default };
48
+ export { x as default };
@@ -7,13 +7,13 @@ export interface Props {
7
7
  backButton?: boolean;
8
8
  /** Sticks to the top while the page scrolls. */
9
9
  sticky?: boolean;
10
- /** Distance from the top when sticky, e.g. `"56px"` under an app navbar. */
10
+ /** Distance from the top when sticky, e.g. `"72px"` under an app navbar. */
11
11
  top?: string;
12
- /** `normal` suits a page's main header. `compact` has a 14px title and less padding, for dense pages and forms. */
12
+ /** `normal` suits a page's main header: a 20px title, 24px from 768px. `compact` has a 16px title and less padding, for dense pages and forms. */
13
13
  size?: "normal" | "compact";
14
14
  }
15
15
  type __VLS_Slots = {
16
- /** A logo or icon before the title, e.g. the database engine's logo on a resource page. Shown in a 40px tile. */
16
+ /** A logo or icon before the title, shown in a 44px tile: a Lucide icon gets a solid primary tile, an `<img>` (e.g. the database engine's logo) a bordered white one. */
17
17
  icon?: () => unknown;
18
18
  /** Breadcrumb above the title. */
19
19
  breadcrumb?: () => unknown;
@@ -1,20 +1,16 @@
1
1
  import { computed as e, createCommentVNode as t, createElementBlock as n, createElementVNode as r, createVNode as i, defineComponent as a, normalizeClass as o, normalizeStyle as s, openBlock as c, renderSlot as l, toDisplayString as u, unref as d } from "vue";
2
2
  import { ArrowLeft as f } from "@lucide/vue";
3
3
  //#region src/lib/components/AcHeader.vue?vue&type=script&setup=true&lang.ts
4
- var p = { class: "flex min-w-0 items-center gap-3.5" }, m = {
5
- key: 1,
6
- class: "inline-flex size-11 shrink-0 items-center justify-center overflow-hidden rounded-10 border border-border-light bg-surface p-2 text-label shadow-xs ring-1 ring-black/[0.02] [&_img]:size-full [&_img]:object-contain [&_svg]:size-5",
7
- "aria-hidden": "true"
8
- }, h = { class: "min-w-0" }, g = {
4
+ var p = { class: "flex min-w-0 items-center gap-3.5" }, m = { class: "min-w-0" }, h = {
9
5
  key: 0,
10
- class: "mb-1 text-xs text-muted"
11
- }, _ = { class: "flex min-w-0 items-center gap-2.5" }, v = {
6
+ class: "mb-2"
7
+ }, g = { class: "flex min-w-0 flex-wrap items-center gap-2.5" }, _ = {
12
8
  key: 0,
13
- class: "mt-px truncate text-sm leading-5 text-muted"
14
- }, y = {
9
+ class: "mt-1 max-w-prose truncate text-base text-muted"
10
+ }, v = {
15
11
  key: 0,
16
- class: "flex flex-wrap items-center gap-2"
17
- }, b = /*@__PURE__*/ a({
12
+ class: "flex shrink-0 flex-wrap items-center gap-2"
13
+ }, y = /*@__PURE__*/ a({
18
14
  __name: "AcHeader",
19
15
  props: {
20
16
  title: { default: "" },
@@ -31,30 +27,34 @@ var p = { class: "flex min-w-0 items-center gap-3.5" }, m = {
31
27
  size: { default: "normal" }
32
28
  },
33
29
  emits: ["back"],
34
- setup(a, { emit: b }) {
35
- let x = a, S = e(() => x.size === "compact"), C = b;
36
- return (e, b) => (c(), n("header", {
37
- class: o(["z-20 border-b border-border-light bg-surface/85 shadow-[0_1px_2px_0_rgb(15_23_42/0.03)] backdrop-blur-md backdrop-saturate-150", a.sticky && "sticky"]),
30
+ setup(a, { emit: y }) {
31
+ let b = a, x = e(() => b.size === "compact"), S = y;
32
+ return (e, y) => (c(), n("header", {
33
+ class: o(["z-20 border-b border-border/80 bg-surface/90 backdrop-blur-sm", a.sticky && "sticky"]),
38
34
  style: s(a.sticky ? { top: a.top } : void 0),
39
35
  "data-ac-ds": "",
40
36
  "data-testid": "ac-header"
41
- }, [r("div", { class: o(["flex flex-wrap items-center justify-between gap-x-6 gap-y-3", S.value ? "px-5 py-2.5" : "px-6 py-3.5"]) }, [r("div", p, [
37
+ }, [r("div", { class: o(["flex flex-wrap items-center justify-between gap-x-6 gap-y-4", x.value ? "px-4 py-3 sm:px-6" : "px-4 py-5 sm:px-6"]) }, [r("div", p, [
42
38
  a.backButton ? (c(), n("button", {
43
39
  key: 0,
44
40
  type: "button",
45
- class: "inline-flex size-9 shrink-0 cursor-pointer items-center justify-center rounded-8 border border-border bg-surface text-label shadow-xs transition hover:border-border-dark hover:bg-surface-muted hover:text-heading active:scale-95 focus-visible:outline-none focus-visible:ring-[3px] focus-visible:ring-ring",
41
+ class: "inline-flex size-9 shrink-0 cursor-pointer items-center justify-center rounded-10 border border-border bg-surface text-heading transition-[color,background-color,border-color,box-shadow,transform] duration-200 hover:bg-surface-sunken/70 focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-surface focus-visible:outline-none active:translate-y-px motion-reduce:active:translate-y-0",
46
42
  "aria-label": "Back",
47
43
  "data-ac-ds": "",
48
44
  "data-testid": "ac-header-back",
49
- onClick: b[0] ||= (e) => C("back")
45
+ onClick: y[0] ||= (e) => S("back")
50
46
  }, [i(d(f), {
51
47
  class: "size-4",
52
48
  "aria-hidden": "true"
53
49
  })])) : t("", !0),
54
- e.$slots.icon ? (c(), n("span", m, [l(e.$slots, "icon")])) : t("", !0),
55
- r("div", h, [e.$slots.breadcrumb ? (c(), n("div", g, [l(e.$slots, "breadcrumb")])) : t("", !0), l(e.$slots, "title", {}, () => [r("div", _, [r("h4", { class: o(["truncate font-semibold text-heading", S.value ? "text-lg leading-6 tracking-[-0.01em]" : "text-xl leading-7 tracking-tight"]) }, u(a.title), 3), l(e.$slots, "title-extra")]), a.subtitle ? (c(), n("p", v, u(a.subtitle), 1)) : t("", !0)])])
56
- ]), e.$slots.default ? (c(), n("div", y, [l(e.$slots, "default")])) : t("", !0)], 2)], 6));
50
+ e.$slots.icon ? (c(), n("span", {
51
+ key: 1,
52
+ class: o(["inline-flex shrink-0 items-center justify-center overflow-hidden bg-primary text-white has-[img]:border has-[img]:border-border has-[img]:bg-surface has-[img]:p-2 [&_img]:size-full [&_img]:object-contain", x.value ? "size-9 rounded-10 [&_svg]:size-5" : "size-11 rounded-14 [&_svg]:size-6"]),
53
+ "aria-hidden": "true"
54
+ }, [l(e.$slots, "icon")], 2)) : t("", !0),
55
+ r("div", m, [e.$slots.breadcrumb ? (c(), n("div", h, [l(e.$slots, "breadcrumb")])) : t("", !0), l(e.$slots, "title", {}, () => [r("div", g, [r("h4", { class: o(["truncate font-heading font-semibold tracking-tight text-heading", x.value ? "text-lg" : "text-2xl md:text-3xl"]) }, u(a.title), 3), l(e.$slots, "title-extra")]), a.subtitle ? (c(), n("p", _, u(a.subtitle), 1)) : t("", !0)])])
56
+ ]), e.$slots.default ? (c(), n("div", v, [l(e.$slots, "default")])) : t("", !0)], 2)], 6));
57
57
  }
58
58
  });
59
59
  //#endregion
60
- export { b as default };
60
+ export { y as default };
@@ -5,7 +5,7 @@ import { Check as b, Copy as x, Eye as S, EyeOff as C } from "@lucide/vue";
5
5
  //#region src/lib/components/AcInfoTable.vue?vue&type=script&setup=true&lang.ts
6
6
  var w = {
7
7
  key: 0,
8
- class: "text-lg leading-6 font-semibold tracking-[-0.01em] text-heading"
8
+ class: "font-heading text-lg leading-tight font-semibold tracking-tight text-heading"
9
9
  }, T = {
10
10
  key: 1,
11
11
  class: "ml-auto flex shrink-0 items-center gap-2"
@@ -48,10 +48,14 @@ var w = {
48
48
  item: e,
49
49
  key: e.key ?? e.label
50
50
  }))), z = r(() => [
51
- "min-w-0 border-t border-border-light py-2.5 first:border-t-0",
51
+ "min-w-0 border-t border-border py-3.5 first:border-t-0",
52
52
  N.columns === 2 && "md:[&:nth-child(2)]:border-t-0",
53
- N.layout === "horizontal" ? "flex flex-col gap-0.5 sm:flex-row sm:items-baseline sm:gap-4" : "flex flex-col gap-1"
54
- ]), B = r(() => ["flex items-center gap-1.5 text-base text-muted", N.layout === "horizontal" && (N.columns === 2 ? "sm:w-36 sm:shrink-0" : "sm:w-48 sm:shrink-0")]);
53
+ N.layout === "horizontal" ? "flex flex-col gap-1 sm:flex-row sm:items-baseline sm:gap-4" : "flex flex-col gap-1"
54
+ ]), B = r(() => [
55
+ "flex items-center gap-2 text-muted",
56
+ N.layout === "stacked" ? "text-xs font-medium" : "text-base",
57
+ N.layout === "horizontal" && (N.columns === 2 ? "sm:w-36 sm:shrink-0" : "sm:w-48 sm:shrink-0")
58
+ ]);
55
59
  function V(e) {
56
60
  return e == null || e === "";
57
61
  }
@@ -65,34 +69,34 @@ var w = {
65
69
  } catch {}
66
70
  }
67
71
  return d(() => clearTimeout(L)), (t, r) => (f(), o("div", {
68
- class: u(l.bordered && "rounded-10 border border-border bg-surface shadow-xs"),
72
+ class: u(l.bordered && "rounded-14 border border-border bg-surface"),
69
73
  "data-ac-ds": "",
70
74
  "data-testid": "ac-info-table"
71
75
  }, [l.title || t.$slots.actions ? (f(), o("div", {
72
76
  key: 0,
73
- class: u(["flex items-center justify-between gap-4", l.bordered ? "border-b border-border-light px-5 py-3.5" : "mb-2"])
77
+ class: u(["flex items-center justify-between gap-4", l.bordered ? "border-b border-border px-6 pt-5 pb-3" : "mb-2"])
74
78
  }, [l.title ? (f(), o("h3", w, _(l.title), 1)) : a("", !0), t.$slots.actions ? (f(), o("div", T, [h(t.$slots, "actions")])) : a("", !0)], 2)) : a("", !0), !l.loading && !l.items.length ? (f(), o("p", {
75
79
  key: 1,
76
- class: u(["py-6 text-center text-base text-muted", l.bordered && "px-5"])
80
+ class: u(["py-10 text-center text-base text-muted", l.bordered && "px-6"])
77
81
  }, _(l.emptyText), 3)) : (f(), o("dl", {
78
82
  key: 2,
79
- class: u(["grid", [l.columns === 2 && "md:grid-cols-2 md:gap-x-10", l.bordered ? "px-5 py-2" : ""]]),
83
+ class: u(["grid", [l.columns === 2 && "md:grid-cols-2 md:gap-x-10", l.bordered ? "px-6 py-1" : ""]]),
80
84
  "aria-busy": l.loading || void 0
81
85
  }, [l.loading && !l.items.length ? (f(), o(n, { key: 0 }, m(P, (e, t) => s("div", {
82
86
  key: t,
83
87
  class: u(z.value)
84
- }, [s("dt", { class: u(B.value) }, [...r[0] ||= [s("span", { class: "h-3 w-20 animate-pulse rounded-4 bg-surface-sunken" }, null, -1)]], 2), s("dd", D, [s("span", { class: u(["h-3 animate-pulse rounded-4 bg-surface-sunken", e]) }, null, 2)])], 2)), 64)) : a("", !0), (f(!0), o(n, null, m(R.value, ({ item: n, key: r }, d) => (f(), o("div", {
88
+ }, [s("dt", { class: u(B.value) }, [...r[0] ||= [s("span", { class: "h-3 w-20 animate-pulse rounded-full bg-surface-sunken" }, null, -1)]], 2), s("dd", D, [s("span", { class: u(["h-3 animate-pulse rounded-full bg-surface-sunken", e]) }, null, 2)])], 2)), 64)) : a("", !0), (f(!0), o(n, null, m(R.value, ({ item: n, key: r }, d) => (f(), o("div", {
85
89
  key: r,
86
90
  class: u(z.value)
87
91
  }, [s("dt", { class: u(B.value) }, [h(t.$slots, `label-${r}`, { item: n }, () => [c(_(n.label), 1)])], 2), s("dd", O, [l.loading ? (f(), o("span", {
88
92
  key: 0,
89
- class: u(["h-3 animate-pulse rounded-4 bg-surface-sunken", P[d % P.length]])
93
+ class: u(["h-3 animate-pulse rounded-full bg-surface-sunken", P[d % P.length]])
90
94
  }, null, 2)) : h(t.$slots, `value-${r}`, { item: n }, () => [V(n.value) ? (f(), o("span", k, "—")) : (f(), o("span", A, [
91
95
  s("span", { class: u(["min-w-0 [overflow-wrap:anywhere]", (n.mono || n.secret) && "font-mono text-xs leading-5"]) }, _(n.secret && !I.value.has(r) ? "••••••••••••" : n.value), 3),
92
96
  n.secret ? (f(), o("button", {
93
97
  key: 0,
94
98
  type: "button",
95
- class: "-my-0.5 inline-flex size-6 shrink-0 cursor-pointer items-center justify-center rounded-4 text-muted transition hover:bg-surface-sunken hover:text-heading focus-visible:outline-none focus-visible:ring-[3px] focus-visible:ring-ring",
99
+ class: "-my-0.5 inline-flex size-6 shrink-0 cursor-pointer items-center justify-center rounded-8 text-muted transition-colors duration-200 hover:bg-surface-sunken hover:text-heading focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
96
100
  "aria-label": I.value.has(r) ? `Hide ${n.label}` : `Show ${n.label}`,
97
101
  "aria-pressed": I.value.has(r),
98
102
  onClick: (e) => H(r)
@@ -106,12 +110,12 @@ var w = {
106
110
  }, {
107
111
  default: y(() => [s("button", {
108
112
  type: "button",
109
- class: "-my-0.5 inline-flex size-6 shrink-0 cursor-pointer items-center justify-center rounded-4 text-muted transition hover:bg-surface-sunken hover:text-heading focus-visible:outline-none focus-visible:ring-[3px] focus-visible:ring-ring",
113
+ class: "-my-0.5 inline-flex size-6 shrink-0 cursor-pointer items-center justify-center rounded-8 text-muted transition-colors duration-200 hover:bg-surface-sunken hover:text-heading focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
110
114
  "aria-label": F.value === r ? `${n.label} copied` : `Copy ${n.label}`,
111
115
  onClick: (e) => U(r, n.value)
112
116
  }, [F.value === r ? (f(), i(v(b), {
113
117
  key: 0,
114
- class: "size-3.5 text-success",
118
+ class: "size-3.5 text-success-strong",
115
119
  "aria-hidden": "true"
116
120
  })) : (f(), i(v(x), {
117
121
  key: 1,
@@ -1,6 +1,6 @@
1
1
  import type { Component } from "vue";
2
2
  export interface Props {
3
- /** Floating label. It rests inside the field and rises on focus or when filled. With a `prefix`, it always sits on the top edge. */
3
+ /** Label above the field. Pass `placeholder` for an example value inside it. */
4
4
  label: string;
5
5
  /** Native `name` attribute. */
6
6
  name?: string;
@@ -10,11 +10,11 @@ export interface Props {
10
10
  required?: boolean;
11
11
  /** Disables the field. */
12
12
  disabled?: boolean;
13
- /** Read-only field with a gray background. */
13
+ /** Read-only field: a muted fill, and "(read only)" after the label. */
14
14
  readonly?: boolean;
15
15
  /** Error text under the field. Turns the border and label red and sets `aria-invalid`. */
16
16
  errorMsg?: string;
17
- /** Helper text under the field (hidden while `errorMsg` is set). */
17
+ /** Help text between the label and the field. */
18
18
  hint?: string;
19
19
  /** `small` 36px or `normal` 40px tall. */
20
20
  size?: "small" | "normal";
@@ -1,10 +1,17 @@
1
1
  import { computed as e, createBlock as t, createCommentVNode as n, createElementBlock as r, createElementVNode as i, createTextVNode as a, createVNode as o, defineComponent as s, mergeModels as c, mergeProps as l, normalizeClass as u, openBlock as d, ref as f, renderSlot as p, resolveDynamicComponent as m, toDisplayString as h, unref as g, useAttrs as _, useId as v, useModel as y, useSlots as b, vModelDynamic as x, withDirectives as S } from "vue";
2
2
  import { CircleAlert as C, Eye as w, EyeOff as T } from "@lucide/vue";
3
3
  //#region src/lib/components/AcInput.vue?vue&type=script&setup=true&lang.ts
4
- var E = { class: "flex" }, D = {
4
+ var E = ["for"], D = {
5
5
  key: 0,
6
- class: "flex h-full shrink-0 items-center pl-3 text-base whitespace-nowrap text-muted select-none [&_svg]:size-4"
7
- }, O = [
6
+ class: "font-normal text-muted"
7
+ }, O = {
8
+ key: 1,
9
+ class: "text-danger",
10
+ "aria-hidden": "true"
11
+ }, k = ["id"], A = { class: "flex" }, j = {
12
+ key: 0,
13
+ class: "flex h-full shrink-0 items-center pl-3.5 text-base whitespace-nowrap text-muted select-none [&_svg]:size-4"
14
+ }, M = [
8
15
  "id",
9
16
  "name",
10
17
  "type",
@@ -13,15 +20,11 @@ var E = { class: "flex" }, D = {
13
20
  "required",
14
21
  "aria-invalid",
15
22
  "aria-describedby"
16
- ], k = ["for"], A = {
17
- key: 0,
18
- class: "text-danger",
19
- "aria-hidden": "true"
20
- }, j = ["aria-label"], M = [
23
+ ], N = ["aria-label", "aria-pressed"], P = [
21
24
  "disabled",
22
25
  "aria-label",
23
26
  "title"
24
- ], N = { key: 1 }, P = ["id"], F = ["id"], I = /*@__PURE__*/ s({
27
+ ], F = { key: 1 }, I = ["id"], L = /*@__PURE__*/ s({
25
28
  inheritAttrs: !1,
26
29
  __name: "AcInput",
27
30
  props: /*@__PURE__*/ c({
@@ -42,7 +45,7 @@ var E = { class: "flex" }, D = {
42
45
  },
43
46
  errorMsg: { default: "" },
44
47
  hint: { default: "" },
45
- size: { default: "small" },
48
+ size: { default: "normal" },
46
49
  addonLabel: { default: "" },
47
50
  addonIcon: { default: void 0 },
48
51
  addonIconOnly: {
@@ -54,90 +57,98 @@ var E = { class: "flex" }, D = {
54
57
  modelModifiers: {}
55
58
  }),
56
59
  emits: /*@__PURE__*/ c(["addon"], ["update:modelValue"]),
57
- setup(s, { expose: c, emit: I }) {
58
- let L = s, R = y(s, "modelValue"), z = I, B = v(), V = _(), H = b(), U = e(() => ({
59
- class: V.class,
60
- style: V.style
61
- })), W = e(() => {
62
- let { class: e, style: t, ...n } = V;
60
+ setup(s, { expose: c, emit: L }) {
61
+ let R = s, z = y(s, "modelValue"), B = L, V = v(), H = _(), U = b(), W = e(() => ({
62
+ class: H.class,
63
+ style: H.style
64
+ })), G = e(() => {
65
+ let { class: e, style: t, ...n } = H;
63
66
  return n;
64
- }), G = f(null), K = f(!1), q = e(() => L.type === "password" && K.value ? "text" : L.type), J = e(() => L.errorMsg || L.hint ? `${B}-msg` : void 0), Y = e(() => !!L.addonLabel || !!L.addonIcon), X = e(() => !!H.suffix || L.type === "password");
65
- function Z(e) {
66
- L.disabled || z("addon", e);
67
+ }), K = f(null), q = f(!1), J = e(() => R.type === "password" && q.value ? "text" : R.type), Y = e(() => [R.hint && `${V}-hint`, R.errorMsg && `${V}-msg`].filter(Boolean).join(" ") || void 0), X = e(() => !!R.addonLabel || !!R.addonIcon), Z = e(() => !!U.suffix || R.type === "password");
68
+ function Q(e) {
69
+ R.disabled || B("addon", e);
67
70
  }
68
- return c({ focus: () => G.value?.focus() }), (e, c) => (d(), r("div", l(U.value, {
69
- class: ["w-full", s.disabled && "opacity-60"],
71
+ return c({ focus: () => K.value?.focus() }), (e, c) => (d(), r("div", l(W.value, {
72
+ class: ["w-full", s.disabled && "opacity-50"],
70
73
  "data-ac-ds": "",
71
74
  "data-testid": "ac-input"
72
- }), [i("div", E, [i("div", { class: u(["relative flex min-w-0 flex-1 items-center border shadow-xs transition-[border-color,box-shadow] duration-150", [
73
- s.size === "small" ? "h-9" : "h-10",
74
- Y.value ? "rounded-l-6" : "rounded-6",
75
- s.disabled || s.readonly ? "bg-surface-muted" : "bg-surface",
76
- s.readonly && "shadow-none",
77
- s.errorMsg ? "border-red-60 focus-within:border-danger focus-within:shadow-[0_0_0_3px_var(--color-red-90)]" : "border-border hover:border-border-dark focus-within:focus-ring"
78
- ]]) }, [
79
- e.$slots.prefix ? (d(), r("span", D, [p(e.$slots, "prefix")])) : n("", !0),
80
- S(i("input", l({
81
- id: g(B),
82
- ref_key: "input",
83
- ref: G
84
- }, W.value, {
85
- "onUpdate:modelValue": c[0] ||= (e) => R.value = e,
86
- name: s.name,
87
- type: q.value,
88
- disabled: s.disabled,
89
- readonly: s.readonly,
90
- required: s.required,
91
- "aria-invalid": !!s.errorMsg || void 0,
92
- "aria-describedby": J.value,
93
- placeholder: " ",
94
- class: ["peer block h-full w-full min-w-0 flex-1 rounded-6 bg-transparent text-base text-heading outline-none placeholder:text-transparent disabled:cursor-not-allowed", [e.$slots.prefix ? "pl-1" : "pl-3", X.value ? "pr-1.5" : "pr-3"]]
95
- }), null, 16, O), [[x, R.value]]),
75
+ }), [
96
76
  i("label", {
97
- for: g(B),
98
- class: u(["pointer-events-none absolute -top-px left-2.25 max-w-[calc(100%-20px)] -translate-y-1/2 truncate rounded-2 bg-surface px-1 text-xs font-medium whitespace-nowrap text-label transition-all duration-150 ease-out peer-focus:text-primary-20 peer-read-only:bg-linear-to-b peer-read-only:from-surface peer-read-only:from-50% peer-read-only:to-surface-muted peer-read-only:to-50% peer-disabled:bg-linear-to-b peer-disabled:from-surface peer-disabled:from-50% peer-disabled:to-surface-muted peer-disabled:to-50%", [!e.$slots.prefix && "peer-placeholder-shown:top-1/2 peer-placeholder-shown:text-base peer-placeholder-shown:font-normal peer-placeholder-shown:text-muted peer-focus:-top-px peer-focus:text-xs peer-focus:font-medium", s.errorMsg && "text-red-30! peer-focus:text-red-30!"]])
99
- }, [a(h(s.label), 1), s.required ? (d(), r("span", A, " *")) : n("", !0)], 10, k),
100
- e.$slots.suffix ? (d(), r("span", {
101
- key: 1,
102
- class: u(["relative flex h-full shrink-0 items-center bg-inherit text-base whitespace-nowrap text-muted select-none [&_svg]:size-4", s.type === "password" ? "pr-1" : "pr-3"])
103
- }, [p(e.$slots, "suffix")], 2)) : n("", !0),
104
- s.type === "password" ? (d(), r("button", {
105
- key: 2,
77
+ for: g(V),
78
+ class: "mb-2 flex items-center gap-1 text-base font-medium text-heading"
79
+ }, [
80
+ i("span", null, h(s.label), 1),
81
+ s.readonly ? (d(), r("span", D, "(read only)")) : n("", !0),
82
+ s.required ? (d(), r("span", O, "*")) : n("", !0)
83
+ ], 8, E),
84
+ s.hint ? (d(), r("p", {
85
+ key: 0,
86
+ id: `${g(V)}-hint`,
87
+ class: "mb-2 text-base text-muted"
88
+ }, h(s.hint), 9, k)) : n("", !0),
89
+ i("div", A, [i("div", { class: u(["relative flex min-w-0 flex-1 items-center border transition-[border-color,box-shadow,background-color] duration-200", [
90
+ s.size === "small" ? "h-9" : "h-10",
91
+ X.value ? "rounded-l-10" : "rounded-10",
92
+ s.readonly ? "bg-surface-muted" : "bg-background",
93
+ s.errorMsg ? "border-danger/60 focus-within:border-danger focus-within:shadow-[0_0_0_2px_color-mix(in_srgb,var(--color-danger)_20%,transparent)]" : ["border-border focus-within:focus-ring", !s.disabled && "hover:border-accent-active"]
94
+ ]]) }, [
95
+ e.$slots.prefix ? (d(), r("span", j, [p(e.$slots, "prefix")])) : n("", !0),
96
+ S(i("input", l({
97
+ id: g(V),
98
+ ref_key: "input",
99
+ ref: K
100
+ }, G.value, {
101
+ "onUpdate:modelValue": c[0] ||= (e) => z.value = e,
102
+ name: s.name,
103
+ type: J.value,
104
+ disabled: s.disabled,
105
+ readonly: s.readonly,
106
+ required: s.required,
107
+ "aria-invalid": !!s.errorMsg || void 0,
108
+ "aria-describedby": Y.value,
109
+ class: ["block h-full w-full min-w-0 flex-1 rounded-10 bg-transparent text-base font-normal text-heading outline-none placeholder:text-muted/80 disabled:cursor-not-allowed", [e.$slots.prefix ? "pl-2" : s.size === "small" ? "pl-3" : "pl-4", Z.value ? "pr-2" : s.size === "small" ? "pr-3" : "pr-4"]]
110
+ }), null, 16, M), [[x, z.value]]),
111
+ e.$slots.suffix ? (d(), r("span", {
112
+ key: 1,
113
+ class: u(["relative flex h-full shrink-0 items-center text-base whitespace-nowrap text-muted select-none [&_svg]:size-4", s.type === "password" ? "pr-1" : "pr-3.5"])
114
+ }, [p(e.$slots, "suffix")], 2)) : n("", !0),
115
+ s.type === "password" ? (d(), r("button", {
116
+ key: 2,
117
+ type: "button",
118
+ class: "relative mr-1.5 inline-flex size-7 shrink-0 cursor-pointer items-center justify-center rounded-8 text-muted transition-colors hover:bg-surface-sunken hover:text-heading focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",
119
+ "aria-label": q.value ? "Hide value" : "Show value",
120
+ "aria-pressed": q.value,
121
+ onClick: c[1] ||= (e) => q.value = !q.value
122
+ }, [(d(), t(m(q.value ? g(T) : g(w)), {
123
+ class: "size-4",
124
+ "aria-hidden": "true"
125
+ }))], 8, N)) : n("", !0)
126
+ ], 2), X.value ? (d(), r("button", {
127
+ key: 0,
106
128
  type: "button",
107
- class: "relative mr-1.5 inline-flex size-6 shrink-0 cursor-pointer items-center justify-center rounded-4 text-muted transition hover:bg-surface-sunken hover:text-heading",
108
- "aria-label": K.value ? "Hide value" : "Show value",
109
- onClick: c[1] ||= (e) => K.value = !K.value
110
- }, [(d(), t(m(K.value ? g(T) : g(w)), {
111
- class: "size-4",
129
+ class: u(["relative -ml-px inline-flex shrink-0 cursor-pointer items-center justify-center gap-1.5 rounded-r-10 border border-border bg-surface text-base font-medium whitespace-nowrap text-heading transition-colors duration-200 hover:bg-surface-sunken/70 focus-visible:z-10 focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none disabled:cursor-not-allowed disabled:hover:bg-surface", [s.size === "small" ? "h-9" : "h-10", s.addonIconOnly ? s.size === "small" ? "w-9" : "w-10" : "px-4"]]),
130
+ disabled: s.disabled,
131
+ "aria-label": s.addonIconOnly ? s.addonLabel : void 0,
132
+ title: s.addonIconOnly ? s.addonLabel : void 0,
133
+ "data-ac-ds": "",
134
+ "data-testid": "ac-input-addon",
135
+ onClick: Q
136
+ }, [s.addonIcon ? (d(), t(m(s.addonIcon), {
137
+ key: 0,
138
+ class: "size-4 text-muted",
112
139
  "aria-hidden": "true"
113
- }))], 8, j)) : n("", !0)
114
- ], 2), Y.value ? (d(), r("button", {
115
- key: 0,
116
- type: "button",
117
- class: u(["relative -ml-px inline-flex shrink-0 cursor-pointer items-center justify-center gap-1.5 rounded-r-6 border border-border bg-surface-muted text-base font-medium whitespace-nowrap text-heading shadow-xs transition-[background-color,border-color,box-shadow] duration-150 hover:bg-surface-sunken focus-visible:z-10 focus-visible:outline-none focus-visible:ring-[3px] focus-visible:ring-ring disabled:cursor-not-allowed disabled:hover:bg-surface-muted", [s.size === "small" ? "h-9" : "h-10", s.addonIconOnly ? "w-9" : "px-3"]]),
118
- disabled: s.disabled,
119
- "aria-label": s.addonIconOnly ? s.addonLabel : void 0,
120
- title: s.addonIconOnly ? s.addonLabel : void 0,
121
- "data-ac-ds": "",
122
- "data-testid": "ac-input-addon",
123
- onClick: Z
124
- }, [s.addonIcon ? (d(), t(m(s.addonIcon), {
125
- key: 0,
126
- class: "size-4 text-label",
127
- "aria-hidden": "true"
128
- })) : n("", !0), s.addonIconOnly ? n("", !0) : (d(), r("span", N, h(s.addonLabel), 1))], 10, M)) : n("", !0)]), s.errorMsg ? (d(), r("p", {
129
- key: 0,
130
- id: `${g(B)}-msg`,
131
- class: "mt-1.5 flex items-center gap-1 text-xs text-red-30"
132
- }, [o(g(C), {
133
- class: "size-3.5 shrink-0",
134
- "aria-hidden": "true"
135
- }), a(" " + h(s.errorMsg), 1)], 8, P)) : s.hint ? (d(), r("p", {
136
- key: 1,
137
- id: `${g(B)}-msg`,
138
- class: "mt-1.5 text-xs text-muted"
139
- }, h(s.hint), 9, F)) : n("", !0)], 16));
140
+ })) : n("", !0), s.addonIconOnly ? n("", !0) : (d(), r("span", F, h(s.addonLabel), 1))], 10, P)) : n("", !0)]),
141
+ s.errorMsg ? (d(), r("p", {
142
+ key: 1,
143
+ id: `${g(V)}-msg`,
144
+ class: "mt-1.5 flex items-center gap-1.5 text-base text-danger-strong",
145
+ role: "alert"
146
+ }, [o(g(C), {
147
+ class: "size-4 shrink-0",
148
+ "aria-hidden": "true"
149
+ }), a(" " + h(s.errorMsg), 1)], 8, I)) : n("", !0)
150
+ ], 16));
140
151
  }
141
152
  });
142
153
  //#endregion
143
- export { I as default };
154
+ export { L as default };
@@ -8,7 +8,7 @@ var f = {
8
8
  }, p = {
9
9
  key: 0,
10
10
  class: "px-px text-xs text-muted"
11
- }, m = { "aria-hidden": "true" }, h = { class: "sr-only" }, g = "inline-flex items-center justify-center border border-border border-b-border-dark bg-surface-muted font-sans font-medium text-label shadow-[inset_0_-1px_0_0_var(--color-border)] select-none", _ = /*@__PURE__*/ o({
11
+ }, m = { "aria-hidden": "true" }, h = { class: "sr-only" }, g = "inline-flex items-center justify-center border border-border bg-surface-muted font-mono font-medium text-muted select-none", _ = /*@__PURE__*/ o({
12
12
  __name: "AcKbd",
13
13
  props: {
14
14
  keys: { default: () => [] },
@@ -0,0 +1,5 @@
1
+ import e from "./AcKeyValueInput.vue_vue_type_script_setup_true_lang.js";
2
+ //#region src/lib/components/AcKeyValueInput.vue
3
+ var t = e;
4
+ //#endregion
5
+ export { t as default };