@vadimcomanescu/nadicode-design-system 5.0.2 → 6.0.1

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 (188) hide show
  1. package/.agents/skills/seed/SKILL.md +2 -2
  2. package/.agents/skills/seed/references/composition.md +1 -1
  3. package/README.md +1 -1
  4. package/contracts/message-catalog-contract.json +9 -3
  5. package/contracts/release-governance-baseline.json +2 -2
  6. package/dist/{TeamPage-UO3V2JDK.js → TeamPage-XL574KIF.js} +54 -53
  7. package/dist/catalog/catalog.d.ts +290 -10
  8. package/dist/catalog/catalog.js +12 -12
  9. package/dist/catalog/components.d.ts +18 -16
  10. package/dist/catalog/components.js +53 -52
  11. package/dist/catalog/definitions/blocks-agent.d.ts +35 -2
  12. package/dist/catalog/definitions/blocks-agent.js +1 -1
  13. package/dist/catalog/definitions/blocks-auth.d.ts +40 -0
  14. package/dist/catalog/definitions/blocks-auth.js +1 -1
  15. package/dist/catalog/definitions/blocks-content.d.ts +22 -0
  16. package/dist/catalog/definitions/blocks-content.js +1 -1
  17. package/dist/catalog/definitions/blocks-crud.d.ts +102 -2
  18. package/dist/catalog/definitions/blocks-crud.js +1 -1
  19. package/dist/catalog/definitions/blocks-data.d.ts +58 -2
  20. package/dist/catalog/definitions/blocks-data.js +1 -1
  21. package/dist/catalog/definitions/blocks-marketing.d.ts +29 -4
  22. package/dist/catalog/definitions/blocks-marketing.js +1 -1
  23. package/dist/catalog/definitions/blocks-misc.d.ts +2 -0
  24. package/dist/catalog/definitions/blocks-misc.js +1 -1
  25. package/dist/catalog/definitions/display.d.ts +2 -0
  26. package/dist/catalog/definitions/display.js +1 -1
  27. package/dist/catalog/definitions/index.d.ts +290 -10
  28. package/dist/catalog/definitions/index.js +11 -11
  29. package/dist/catalog/primitives/chat.d.ts +2 -2
  30. package/dist/catalog/primitives/chat.js +1 -1
  31. package/dist/catalog/primitives/display.d.ts +7 -7
  32. package/dist/catalog/primitives/display.js +3 -3
  33. package/dist/catalog/primitives/form.d.ts +1 -1
  34. package/dist/catalog/primitives/form.js +1 -1
  35. package/dist/catalog/primitives/index.d.ts +14 -14
  36. package/dist/catalog/primitives/index.js +10 -10
  37. package/dist/catalog/primitives/layout.d.ts +1 -1
  38. package/dist/catalog/primitives/layout.js +1 -1
  39. package/dist/catalog/primitives/navigation.d.ts +4 -4
  40. package/dist/catalog/primitives/navigation.js +1 -1
  41. package/dist/catalog/primitives/overlay.d.ts +2 -2
  42. package/dist/catalog/primitives/overlay.js +1 -1
  43. package/dist/{chunk-PQOL3E2V.js → chunk-25QQEKGR.js} +7 -7
  44. package/dist/{chunk-XLN4NVKU.js → chunk-2BCMZV5U.js} +17 -10
  45. package/dist/{chunk-VQVWFCHF.js → chunk-2OEVKFZ2.js} +10 -10
  46. package/dist/{chunk-V4NBPGED.js → chunk-2UY4XZC6.js} +3 -1
  47. package/dist/{chunk-AP5SGSN7.js → chunk-3MGQGQTS.js} +8 -0
  48. package/dist/{chunk-WGQHM56J.js → chunk-4BG7ILL5.js} +43 -41
  49. package/dist/{chunk-OWWQP3YW.js → chunk-4DQMGKPG.js} +2 -2
  50. package/dist/{chunk-JDHD4L6N.js → chunk-4NRASS74.js} +1 -1
  51. package/dist/{chunk-4ZST7OY5.js → chunk-5DLTCQN4.js} +29 -7
  52. package/dist/{chunk-NBDUZA66.js → chunk-5HFOPRXI.js} +18 -13
  53. package/dist/{chunk-DSNPOAE6.js → chunk-5S34SGPQ.js} +7 -2
  54. package/dist/{chunk-BVXSAVKY.js → chunk-72EJ2TYY.js} +7 -10
  55. package/dist/{chunk-3BGWXRQC.js → chunk-7U55EQZD.js} +8 -11
  56. package/dist/{chunk-MPVYXUOD.js → chunk-A2IYJPTF.js} +3 -1
  57. package/dist/chunk-ACIJEUAH.js +213 -0
  58. package/dist/{chunk-PD6WW7E5.js → chunk-BRESMZ6G.js} +2 -5
  59. package/dist/{chunk-Q4CRHV5T.js → chunk-BVOJIX27.js} +55 -10
  60. package/dist/{chunk-PYRHNONA.js → chunk-CJDVIJEF.js} +6 -5
  61. package/dist/{chunk-FSU7ZM5V.js → chunk-CJT7SZNI.js} +8 -15
  62. package/dist/{chunk-PQBVNNEG.js → chunk-DEILZQEX.js} +12 -3
  63. package/dist/chunk-DORWHCRI.js +112 -0
  64. package/dist/{chunk-EJQ73FJ5.js → chunk-DW3XHDFX.js} +70 -15
  65. package/dist/{chunk-ZL6BPQNN.js → chunk-EKSXBDOA.js} +23 -11
  66. package/dist/{chunk-UCFR7GLW.js → chunk-EX5AIP2Q.js} +4 -4
  67. package/dist/chunk-F4BPNMAD.js +185 -0
  68. package/dist/{chunk-STNVWBJH.js → chunk-FGGGUS5L.js} +1 -1
  69. package/dist/{chunk-IZ7A62GI.js → chunk-GBKAQWME.js} +23 -23
  70. package/dist/{chunk-XYMFKNKG.js → chunk-GW7A5G4W.js} +26 -5
  71. package/dist/{chunk-IW36SVOH.js → chunk-HBVZYYTD.js} +79 -12
  72. package/dist/{chunk-P5I63ETD.js → chunk-HZ6WO2OD.js} +30 -3
  73. package/dist/{chunk-MOFWXBTK.js → chunk-IWFPYUHD.js} +1 -1
  74. package/dist/{chunk-CQ75K2DH.js → chunk-JA6QAEVX.js} +15 -13
  75. package/dist/{chunk-YEAJLVGB.js → chunk-JYDPEIAA.js} +31 -22
  76. package/dist/chunk-KEQFAIPJ.js +84 -0
  77. package/dist/{chunk-QCFDSOTV.js → chunk-KPRBRDSY.js} +6 -11
  78. package/dist/{chunk-W4KI424V.js → chunk-KRNAMBZZ.js} +5 -3
  79. package/dist/{chunk-XMGWLDNG.js → chunk-KSJUX6EA.js} +2 -2
  80. package/dist/{chunk-5RBO2IMZ.js → chunk-KYLXPIFE.js} +23 -16
  81. package/dist/{chunk-B4373MDA.js → chunk-M4AK7ZXY.js} +8 -1
  82. package/dist/{chunk-KANK5FAG.js → chunk-M5MUMF7S.js} +15 -6
  83. package/dist/{chunk-WAIZR4CR.js → chunk-MIVKO3MG.js} +3 -2
  84. package/dist/{chunk-FX3GYS5O.js → chunk-N3WTIJIB.js} +19 -3
  85. package/dist/{chunk-H3KTAHJP.js → chunk-NPJN6OLX.js} +11 -20
  86. package/dist/{chunk-7AUNUDHM.js → chunk-NPNQGXA7.js} +47 -13
  87. package/dist/{chunk-D6MFOI3N.js → chunk-OO2K4JUF.js} +35 -7
  88. package/dist/{chunk-3QMHVXSQ.js → chunk-OPX27RJE.js} +12 -2
  89. package/dist/{chunk-KKBTPNXT.js → chunk-QJ5ODJTH.js} +5 -1
  90. package/dist/{chunk-ZKA5X3E4.js → chunk-QLNATCF6.js} +5 -11
  91. package/dist/{chunk-ZU7MDRCI.js → chunk-RI4IK37T.js} +26 -11
  92. package/dist/{chunk-YMAEXGD2.js → chunk-RPUONGMF.js} +7 -2
  93. package/dist/{chunk-XUWKGDUY.js → chunk-S4ZZ3SJU.js} +32 -22
  94. package/dist/{chunk-6NL36QN3.js → chunk-T3ASBCI3.js} +8 -2
  95. package/dist/{chunk-R4SBK6Y5.js → chunk-T3J7RZV6.js} +9 -19
  96. package/dist/{chunk-UPMSE6PQ.js → chunk-TCDBSHAY.js} +4 -2
  97. package/dist/{chunk-PJ7DVYWA.js → chunk-TOMUOPVE.js} +4 -0
  98. package/dist/{chunk-OS2BLQ2G.js → chunk-TYNILBCP.js} +7 -2
  99. package/dist/{chunk-V5RSV4ZV.js → chunk-VTIT5C7L.js} +17 -3
  100. package/dist/{chunk-33UWVOQ6.js → chunk-WS6PKHGX.js} +1 -1
  101. package/dist/chunk-X5BYH7WG.js +27 -0
  102. package/dist/{chunk-IYK2ABFE.js → chunk-XMXH63A7.js} +2 -2
  103. package/dist/{chunk-3LROWCZE.js → chunk-XVV52J35.js} +24 -5
  104. package/dist/{chunk-OUXJUUCB.js → chunk-XZZVSBPC.js} +34 -3
  105. package/dist/{chunk-UMEBNHKR.js → chunk-YGB5BFFI.js} +4 -2
  106. package/dist/{chunk-CTVV6JS6.js → chunk-Z3NGVHHE.js} +1 -1
  107. package/dist/{chunk-A4QNTJUR.js → chunk-ZCYD22F2.js} +51 -7
  108. package/dist/components/blocks/AgentConversationBlock.d.ts +1 -1
  109. package/dist/components/blocks/AgentConversationBlock.js +107 -1
  110. package/dist/components/blocks/ApiKeysBlock.js +3 -1
  111. package/dist/components/blocks/AuthLayout.js +3 -2
  112. package/dist/components/blocks/BlogIndexBlock.d.ts +1 -1
  113. package/dist/components/blocks/BlogIndexBlock.js +1 -1
  114. package/dist/components/blocks/CallToActionBlock.d.ts +1 -1
  115. package/dist/components/blocks/CallToActionBlock.js +1 -2
  116. package/dist/components/blocks/ChartCollectionBlock.d.ts +1 -1
  117. package/dist/components/blocks/ChartCollectionBlock.js +2 -1
  118. package/dist/components/blocks/ChatLayout.d.ts +1 -1
  119. package/dist/components/blocks/ChatLayout.js +1 -2
  120. package/dist/components/blocks/CheckEmailBlock.js +2 -1
  121. package/dist/components/blocks/CommandPaletteBlock.js +1 -1
  122. package/dist/components/blocks/ContactBlock.js +2 -2
  123. package/dist/components/blocks/CreateBlock.js +2 -1
  124. package/dist/components/blocks/CrudListBlock.js +1 -1
  125. package/dist/components/blocks/DashboardBlock.js +2 -2
  126. package/dist/components/blocks/DataGridBlock.d.ts +3 -3
  127. package/dist/components/blocks/DataGridBlock.js +4 -2
  128. package/dist/components/blocks/DirectoryBlock.d.ts +1 -1
  129. package/dist/components/blocks/DirectoryBlock.js +1 -1
  130. package/dist/components/blocks/FAQBlock.d.ts +1 -1
  131. package/dist/components/blocks/FAQBlock.js +1 -1
  132. package/dist/components/blocks/FooterBlock.d.ts +1 -1
  133. package/dist/components/blocks/FooterBlock.js +1 -2
  134. package/dist/components/blocks/FormFieldBlock.d.ts +1 -1
  135. package/dist/components/blocks/FormFieldBlock.js +1 -1
  136. package/dist/components/blocks/GalleryBlock.d.ts +1 -1
  137. package/dist/components/blocks/GalleryBlock.js +1 -1
  138. package/dist/components/blocks/HeaderBlock.d.ts +1 -1
  139. package/dist/components/blocks/HeaderBlock.js +1 -2
  140. package/dist/components/blocks/HeroBlock.js +1 -2
  141. package/dist/components/blocks/IntegrationsBlock.js +2 -2
  142. package/dist/components/blocks/LoginBlock.js +2 -1
  143. package/dist/components/blocks/LogoCloud.js +2 -2
  144. package/dist/components/blocks/NewsletterBlock.js +2 -2
  145. package/dist/components/blocks/OnboardingFlowBlock.js +1 -1
  146. package/dist/components/blocks/PasswordRecoveryBlock.d.ts +3 -1
  147. package/dist/components/blocks/PasswordRecoveryBlock.js +2 -2
  148. package/dist/components/blocks/PricingBlock.d.ts +3 -1
  149. package/dist/components/blocks/PricingBlock.js +1 -1
  150. package/dist/components/blocks/ResetPasswordBlock.js +1 -1
  151. package/dist/components/blocks/SettingsNavBlock.d.ts +1 -1
  152. package/dist/components/blocks/SettingsNavBlock.js +1 -1
  153. package/dist/components/blocks/StatsMarketingBlock.js +1 -2
  154. package/dist/components/blocks/TeamManagementBlock.d.ts +3 -0
  155. package/dist/components/blocks/TeamManagementBlock.js +129 -0
  156. package/dist/components/blocks/TeamShowcaseBlock.d.ts +3 -0
  157. package/dist/components/blocks/{TeamBlock.js → TeamShowcaseBlock.js} +1 -1
  158. package/dist/components/blocks/TestimonialsBlock.js +2 -2
  159. package/dist/components/blocks/TwoFactorSetupBlock.d.ts +3 -1
  160. package/dist/components/blocks/TwoFactorSetupBlock.js +1 -2
  161. package/dist/components/blocks/WizardBlock.js +1 -1
  162. package/dist/components/blocks/user/InviteUserModal.js +2 -1
  163. package/dist/components/logos/index.js +1 -1
  164. package/dist/components/ui/CheckoutForm.js +1 -1
  165. package/dist/components/ui/DataTable.d.ts +4 -2
  166. package/dist/components/ui/DataTable.js +1 -1
  167. package/dist/components/ui/NavUser.d.ts +1 -1
  168. package/dist/components/ui/NavUser.js +1 -1
  169. package/dist/components/ui/SettingsModal.d.ts +2 -1
  170. package/dist/components/ui/SettingsModal.js +1 -1
  171. package/dist/components/ui/WorkspaceSwitcherBlock.js +1 -1
  172. package/dist/lib/json-render/app.js +1 -1
  173. package/dist/lib/json-render/catalog.d.ts +122 -8
  174. package/dist/lib/json-render/catalog.js +13 -13
  175. package/dist/lib/json-render/registry.js +13 -13
  176. package/dist/lib/json-render/showcase-spec.js +1 -1
  177. package/dist/messages/en.js +1 -1
  178. package/dist/messages/it.js +1 -1
  179. package/dist/test/PublicSeedTestProvider.js +2 -2
  180. package/eslint-rules/nadicode/data/catalog-names.json +2 -1
  181. package/eslint-rules/nadicode/rules/__tests__/require-catalog-import.test.js +0 -5
  182. package/eslint-rules/nadicode/rules/require-catalog-import.js +0 -1
  183. package/package.json +1 -1
  184. package/dist/chunk-6OBT3A5O.js +0 -21
  185. package/dist/chunk-NDQO7AO6.js +0 -105
  186. package/dist/chunk-TTDKPZ75.js +0 -45
  187. package/dist/chunk-YB3J4ZRZ.js +0 -180
  188. package/dist/components/blocks/TeamBlock.d.ts +0 -3
@@ -0,0 +1,213 @@
1
+ import { Typography } from './chunk-Q7PCHHVJ.js';
2
+ import { RoleBadge } from './chunk-OHCQPI3W.js';
3
+ import { Heading } from './chunk-UXX6HHPS.js';
4
+ import { DropdownMenu, DropdownMenuTrigger, DropdownMenuContent, DropdownMenuLabel, DropdownMenuSeparator, DropdownMenuSub, DropdownMenuSubTrigger, DropdownMenuSubContent, DropdownMenuItem } from './chunk-ETS5O4ZQ.js';
5
+ import { Input } from './chunk-AP3XXYAY.js';
6
+ import { Empty, EmptyTitle, EmptyDescription } from './chunk-4TF4QFIM.js';
7
+ import { Skeleton } from './chunk-RASEB2XI.js';
8
+ import { Avatar, AvatarImage, AvatarFallback } from './chunk-NAAU5IWU.js';
9
+ import { Button } from './chunk-7KIDDF3I.js';
10
+ import { UsersIcon } from './chunk-WUO7OONN.js';
11
+ import { PlusIcon } from './chunk-E7RBK6ML.js';
12
+ import { SearchIcon } from './chunk-T6BRD7TS.js';
13
+ import { EllipsisIcon } from './chunk-5ESF6N36.js';
14
+ import { Badge } from './chunk-S4JAHKOP.js';
15
+ import { cn } from './chunk-QYZT24TS.js';
16
+ import { useBoundProp } from '@json-render/react';
17
+ import { useState, useMemo } from 'react';
18
+ import { jsxs, jsx } from 'react/jsx-runtime';
19
+
20
+ var ROLES = ["owner", "admin", "member", "guest"];
21
+ var DEFAULT_MEMBERS = [
22
+ { id: "dm-1", name: "Sofia Reyes", email: "sofia@acme.com", role: "owner", avatar: null, joinedAt: "2025-06-01T00:00:00Z", status: "active" },
23
+ { id: "dm-2", name: "Marcus Chen", email: "marcus@acme.com", role: "admin", avatar: null, joinedAt: "2025-08-15T00:00:00Z", status: "active" },
24
+ { id: "dm-3", name: "Aisha Patel", email: "aisha@acme.com", role: "member", avatar: null, joinedAt: "2025-11-20T00:00:00Z", status: "active" },
25
+ { id: "dm-4", name: "Jordan Lee", email: "jordan@acme.com", role: "guest", avatar: null, joinedAt: null, status: "pending" }
26
+ ];
27
+ function deriveState(state, members) {
28
+ if (state) return state;
29
+ if (members.length === 0) return "empty";
30
+ return "has-data";
31
+ }
32
+ function getInitials(name) {
33
+ return name.split(" ").map((part) => part[0]).filter(Boolean).slice(0, 2).join("").toUpperCase();
34
+ }
35
+ var STATUS_LABELS = {
36
+ active: "Active",
37
+ pending: "Pending",
38
+ deactivated: "Deactivated"
39
+ };
40
+ function StatusBadge({ status }) {
41
+ if (!status || status === "active") return null;
42
+ return /* @__PURE__ */ jsx(
43
+ Badge,
44
+ {
45
+ variant: "outline",
46
+ className: cn(
47
+ status === "pending" && "border-warning/40 text-warning",
48
+ status === "deactivated" && "border-destructive/40 text-destructive/80"
49
+ ),
50
+ children: STATUS_LABELS[status] ?? status
51
+ }
52
+ );
53
+ }
54
+ function TeamManagementBlock({
55
+ props,
56
+ emit,
57
+ bindings
58
+ }) {
59
+ const members = props.members ?? DEFAULT_MEMBERS;
60
+ const title = props.title ?? "Team Members";
61
+ const description = props.description;
62
+ const errorMessage = props.errorMessage;
63
+ const className = props.className;
64
+ const [, setBoundSearchQuery] = useBoundProp(
65
+ props.searchQuery,
66
+ bindings?.searchQuery
67
+ );
68
+ const [localSearchQuery, setLocalSearchQuery] = useState("");
69
+ const isBoundSearch = !!bindings?.searchQuery;
70
+ const searchQuery = isBoundSearch ? props.searchQuery ?? "" : localSearchQuery;
71
+ const setSearchQuery = isBoundSearch ? setBoundSearchQuery : setLocalSearchQuery;
72
+ const [, setBoundSelectedMemberId] = useBoundProp(
73
+ props.selectedMemberId,
74
+ bindings?.selectedMemberId
75
+ );
76
+ const [, setBoundSelectedRole] = useBoundProp(
77
+ props.selectedRole,
78
+ bindings?.selectedRole
79
+ );
80
+ const resolvedState = deriveState(props.state, members);
81
+ const filteredMembers = useMemo(() => {
82
+ if (!searchQuery.trim()) return members;
83
+ const q = searchQuery.toLowerCase();
84
+ return members.filter(
85
+ (m) => m.name.toLowerCase().includes(q) || m.email.toLowerCase().includes(q) || m.role.toLowerCase().includes(q)
86
+ );
87
+ }, [members, searchQuery]);
88
+ return /* @__PURE__ */ jsxs("section", { className: cn("space-y-6", className), children: [
89
+ /* @__PURE__ */ jsxs("header", { className: "flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between", children: [
90
+ /* @__PURE__ */ jsxs("div", { className: "space-y-1", children: [
91
+ /* @__PURE__ */ jsx(Heading, { level: 3, children: title }),
92
+ description ? /* @__PURE__ */ jsx(Typography, { variant: "muted", children: description }) : null
93
+ ] }),
94
+ /* @__PURE__ */ jsxs(
95
+ Button,
96
+ {
97
+ onClick: () => emit("invite"),
98
+ "aria-label": "Invite member",
99
+ children: [
100
+ /* @__PURE__ */ jsx(PlusIcon, { size: 16, className: "mr-2" }),
101
+ "Invite"
102
+ ]
103
+ }
104
+ )
105
+ ] }),
106
+ resolvedState !== "loading" && resolvedState !== "error" && members.length > 0 ? /* @__PURE__ */ jsxs("div", { className: "relative", children: [
107
+ /* @__PURE__ */ jsx(SearchIcon, { size: 16, className: "absolute left-3 top-1/2 -translate-y-1/2 text-text-tertiary" }),
108
+ /* @__PURE__ */ jsx(
109
+ Input,
110
+ {
111
+ "aria-label": "Search members",
112
+ placeholder: "Search by name, email, or role...",
113
+ value: searchQuery,
114
+ className: "pl-9",
115
+ onChange: (e) => {
116
+ setSearchQuery(e.target.value);
117
+ emit("searchChange");
118
+ }
119
+ }
120
+ )
121
+ ] }) : null,
122
+ resolvedState === "loading" ? /* @__PURE__ */ jsx("div", { className: "space-y-3", "aria-label": "Loading team members", children: Array.from({ length: 3 }, (_, i) => /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-4 rounded-lg border border-border p-4", children: [
123
+ /* @__PURE__ */ jsx(Skeleton, { className: "h-10 w-10 rounded-full" }),
124
+ /* @__PURE__ */ jsxs("div", { className: "flex-1 space-y-2", children: [
125
+ /* @__PURE__ */ jsx(Skeleton, { className: "h-4 w-32" }),
126
+ /* @__PURE__ */ jsx(Skeleton, { className: "h-3 w-48" })
127
+ ] }),
128
+ /* @__PURE__ */ jsx(Skeleton, { className: "h-6 w-16" })
129
+ ] }, i)) }) : null,
130
+ resolvedState === "error" ? /* @__PURE__ */ jsx(
131
+ "div",
132
+ {
133
+ role: "alert",
134
+ className: "rounded-md border border-destructive/40 bg-destructive/10 px-4 py-3 text-sm text-destructive",
135
+ children: errorMessage ?? "Unable to load team members. Please try again."
136
+ }
137
+ ) : null,
138
+ resolvedState === "empty" || resolvedState === "has-data" && filteredMembers.length === 0 ? /* @__PURE__ */ jsxs(Empty, { children: [
139
+ /* @__PURE__ */ jsx(UsersIcon, { size: 40, className: "text-text-tertiary" }),
140
+ /* @__PURE__ */ jsx(EmptyTitle, { children: searchQuery.trim() ? "No members found" : "No team members" }),
141
+ /* @__PURE__ */ jsx(EmptyDescription, { children: searchQuery.trim() ? "Try a different search term." : "Invite your first team member to get started." })
142
+ ] }) : null,
143
+ resolvedState === "has-data" && filteredMembers.length > 0 ? /* @__PURE__ */ jsx("ul", { className: "divide-y divide-border rounded-lg border border-border", role: "list", children: filteredMembers.map((member) => /* @__PURE__ */ jsxs(
144
+ "li",
145
+ {
146
+ className: "flex items-center gap-4 px-4 py-3",
147
+ children: [
148
+ /* @__PURE__ */ jsxs(Avatar, { className: "h-10 w-10", children: [
149
+ member.avatar ? /* @__PURE__ */ jsx(AvatarImage, { src: member.avatar, alt: member.name }) : null,
150
+ /* @__PURE__ */ jsx(AvatarFallback, { children: getInitials(member.name) })
151
+ ] }),
152
+ /* @__PURE__ */ jsxs("div", { className: "min-w-0 flex-1", children: [
153
+ /* @__PURE__ */ jsx(Typography, { variant: "small", className: "font-medium truncate", children: member.name }),
154
+ /* @__PURE__ */ jsx(Typography, { variant: "muted", className: "truncate text-xs", children: member.email })
155
+ ] }),
156
+ /* @__PURE__ */ jsxs("div", { className: "hidden items-center gap-2 sm:flex", children: [
157
+ /* @__PURE__ */ jsx(StatusBadge, { status: member.status }),
158
+ /* @__PURE__ */ jsx(RoleBadge, { role: member.role })
159
+ ] }),
160
+ /* @__PURE__ */ jsxs(DropdownMenu, { children: [
161
+ /* @__PURE__ */ jsx(DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ jsx(
162
+ Button,
163
+ {
164
+ variant: "ghost",
165
+ size: "sm",
166
+ "aria-label": `Actions for ${member.name}`,
167
+ children: /* @__PURE__ */ jsx(EllipsisIcon, { size: 16 })
168
+ }
169
+ ) }),
170
+ /* @__PURE__ */ jsxs(DropdownMenuContent, { align: "end", children: [
171
+ /* @__PURE__ */ jsx(DropdownMenuLabel, { children: "Actions" }),
172
+ /* @__PURE__ */ jsx(DropdownMenuSeparator, {}),
173
+ /* @__PURE__ */ jsxs(DropdownMenuSub, { children: [
174
+ /* @__PURE__ */ jsx(DropdownMenuSubTrigger, { children: "Change role" }),
175
+ /* @__PURE__ */ jsx(DropdownMenuSubContent, { children: ROLES.map((role) => /* @__PURE__ */ jsxs(
176
+ DropdownMenuItem,
177
+ {
178
+ disabled: role === member.role,
179
+ onClick: () => {
180
+ setBoundSelectedMemberId(member.id);
181
+ setBoundSelectedRole(role);
182
+ emit("roleChange");
183
+ },
184
+ children: [
185
+ role.charAt(0).toUpperCase() + role.slice(1),
186
+ role === member.role ? " (current)" : ""
187
+ ]
188
+ },
189
+ role
190
+ )) })
191
+ ] }),
192
+ /* @__PURE__ */ jsx(DropdownMenuSeparator, {}),
193
+ /* @__PURE__ */ jsx(
194
+ DropdownMenuItem,
195
+ {
196
+ className: "text-destructive focus:text-destructive",
197
+ onClick: () => {
198
+ setBoundSelectedMemberId(member.id);
199
+ emit("removeMember");
200
+ },
201
+ children: "Remove member"
202
+ }
203
+ )
204
+ ] })
205
+ ] })
206
+ ]
207
+ },
208
+ member.id
209
+ )) }) : null
210
+ ] });
211
+ }
212
+
213
+ export { TeamManagementBlock };
@@ -1,7 +1,6 @@
1
1
  import { CountingNumber } from './chunk-F3T2U7YL.js';
2
2
  import { StaggerChildren } from './chunk-DQPK2XRL.js';
3
3
  import { Heading } from './chunk-UXX6HHPS.js';
4
- import { siteConfig } from './chunk-A7NUWD76.js';
5
4
  import { jsx, jsxs } from 'react/jsx-runtime';
6
5
 
7
6
  var defaultStats = [
@@ -9,11 +8,9 @@ var defaultStats = [
9
8
  { value: 22, label: "Active Users", suffix: " Million", prefix: null },
10
9
  { value: 500, label: "Powered Apps", prefix: "+", suffix: null }
11
10
  ];
12
- var defaultTitle = `${siteConfig.name} in numbers`;
13
- var defaultDescription = `The numbers speak for themselves. ${siteConfig.name} powers the next generation of AI interfaces with premium design tokens, glass effects, and accessible components.`;
14
11
  function StatsMarketingBlock({ props }) {
15
- const title = props.title ?? defaultTitle;
16
- const description = props.description ?? defaultDescription;
12
+ const title = props.title ?? "Your Platform in numbers";
13
+ const description = props.description ?? "The numbers speak for themselves. Premium design tokens, glass effects, and accessible components powering the next generation of interfaces.";
17
14
  const stats = props.stats ?? defaultStats;
18
15
  return /* @__PURE__ */ jsx("section", { className: "py-12 md:py-16", children: /* @__PURE__ */ jsxs("div", { className: "mx-auto max-w-5xl space-y-8 px-6 md:space-y-16", children: [
19
16
  /* @__PURE__ */ jsxs("div", { className: "relative z-10 mx-auto max-w-xl space-y-6 text-center", children: [
@@ -1,6 +1,5 @@
1
1
  import { StaggerChildren } from './chunk-DQPK2XRL.js';
2
2
  import { Heading } from './chunk-UXX6HHPS.js';
3
- import { siteConfig } from './chunk-A7NUWD76.js';
4
3
  import { Separator } from './chunk-CUZJIDU7.js';
5
4
  import { Input } from './chunk-AP3XXYAY.js';
6
5
  import { ScrollFadeIn } from './chunk-I23DDSU7.js';
@@ -8,8 +7,10 @@ import { Button } from './chunk-7KIDDF3I.js';
8
7
  import { TwitterIcon } from './chunk-LCDDAE7J.js';
9
8
  import { LinkedinIcon } from './chunk-2IZC7HSV.js';
10
9
  import { GithubIcon } from './chunk-WGPK3FQ7.js';
10
+ import { useState } from 'react';
11
11
  import { useTranslations } from 'next-intl';
12
12
  import Link from 'next/link';
13
+ import { useBoundProp } from '@json-render/react';
13
14
  import { jsx, jsxs } from 'react/jsx-runtime';
14
15
 
15
16
  var CURRENT_YEAR = (/* @__PURE__ */ new Date()).getFullYear();
@@ -18,19 +19,41 @@ var SOCIAL_ICON_MAP = {
18
19
  github: { icon: /* @__PURE__ */ jsx(GithubIcon, { size: 16 }), label: "GitHub" },
19
20
  linkedin: { icon: /* @__PURE__ */ jsx(LinkedinIcon, { size: 16 }), label: "LinkedIn" }
20
21
  };
22
+ var defaultProductLinks = [
23
+ { name: "Components", href: "#" },
24
+ { name: "Blocks", href: "#" },
25
+ { name: "Themes", href: "#" },
26
+ { name: "Showcase", href: "#" }
27
+ ];
28
+ var defaultCompanyLinks = [
29
+ { name: "About", href: "#" },
30
+ { name: "Blog", href: "#" },
31
+ { name: "Careers", href: "#" },
32
+ { name: "Contact", href: "#" }
33
+ ];
34
+ var defaultLegalLinks = [
35
+ { name: "Privacy", href: "#" },
36
+ { name: "Terms", href: "#" },
37
+ { name: "License", href: "#" }
38
+ ];
21
39
  var defaultSocialLinks = [
22
40
  { platform: "twitter", href: "#" },
23
41
  { platform: "github", href: "#" },
24
42
  { platform: "linkedin", href: "#" }
25
43
  ];
26
- function FooterBlock({ props }) {
27
- const brandName = props.brandName ?? siteConfig.name;
44
+ function FooterBlock({ props, bindings, emit }) {
45
+ const brandName = props.brandName ?? "Your Brand";
28
46
  const brandDescription = props.brandDescription ?? "The ultimate design system for building futuristic, high-contrast AI interfaces.";
29
47
  const newsletterPlaceholder = props.newsletterPlaceholder ?? "Enter your email";
30
- const productLinks = props.productLinks ?? siteConfig.nav.footer.product;
31
- const companyLinks = props.companyLinks ?? siteConfig.nav.footer.company;
32
- const legalLinks = props.legalLinks ?? siteConfig.nav.footer.legal;
48
+ const productLinks = props.productLinks ?? defaultProductLinks;
49
+ const companyLinks = props.companyLinks ?? defaultCompanyLinks;
50
+ const legalLinks = props.legalLinks ?? defaultLegalLinks;
33
51
  const socialLinks = props.socialLinks ?? defaultSocialLinks;
52
+ const [boundEmail, setBoundEmail] = useBoundProp(props.email, bindings?.email);
53
+ const [localEmail, setLocalEmail] = useState("");
54
+ const isEmailBound = !!bindings?.email;
55
+ const newsletterEmail = isEmailBound ? boundEmail ?? "" : localEmail;
56
+ const setNewsletterEmail = isEmailBound ? setBoundEmail : setLocalEmail;
34
57
  const t = useTranslations("blocks.footerBlock");
35
58
  return /* @__PURE__ */ jsx(ScrollFadeIn, { children: /* @__PURE__ */ jsx("footer", { className: "bg-background py-12 lg:py-16 border-t border-border/50", children: /* @__PURE__ */ jsxs("div", { className: "container mx-auto px-6 lg:px-8", children: [
36
59
  /* @__PURE__ */ jsxs("div", { className: "grid gap-12 lg:grid-cols-4", children: [
@@ -40,10 +63,32 @@ function FooterBlock({ props }) {
40
63
  /* @__PURE__ */ jsx("span", { className: "text-xl font-semibold text-text-primary", children: brandName })
41
64
  ] }),
42
65
  /* @__PURE__ */ jsx("p", { className: "max-w-xs text-text-secondary", children: brandDescription }),
43
- /* @__PURE__ */ jsxs("div", { className: "flex max-w-sm flex-col gap-2 sm:flex-row", children: [
44
- /* @__PURE__ */ jsx(Input, { placeholder: newsletterPlaceholder, type: "email", className: "bg-surface/50 border-border/50" }),
45
- /* @__PURE__ */ jsx(Button, { variant: "primary", children: t("subscribe") })
46
- ] })
66
+ /* @__PURE__ */ jsxs(
67
+ "form",
68
+ {
69
+ onSubmit: (e) => {
70
+ e.preventDefault();
71
+ if (!newsletterEmail.trim()) return;
72
+ emit("subscribe");
73
+ },
74
+ className: "flex max-w-sm flex-col gap-2 sm:flex-row",
75
+ children: [
76
+ /* @__PURE__ */ jsx(
77
+ Input,
78
+ {
79
+ name: "email",
80
+ placeholder: newsletterPlaceholder,
81
+ type: "email",
82
+ value: newsletterEmail,
83
+ onChange: (e) => setNewsletterEmail(e.target.value),
84
+ required: true,
85
+ className: "bg-surface/50 border-border/50"
86
+ }
87
+ ),
88
+ /* @__PURE__ */ jsx(Button, { type: "submit", variant: "primary", children: t("subscribe") })
89
+ ]
90
+ }
91
+ )
47
92
  ] }),
48
93
  /* @__PURE__ */ jsxs(StaggerChildren, { staggerMs: 60, className: "grid grid-cols-2 gap-8 lg:col-span-2 sm:grid-cols-3", children: [
49
94
  /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
@@ -1,4 +1,4 @@
1
- import { createAvatarDataUri, LOCAL_NIKE_LOGO_SRC } from './chunk-OWWQP3YW.js';
1
+ import { createAvatarDataUri } from './chunk-4DQMGKPG.js';
2
2
  import { Shine } from './chunk-DARC2ACH.js';
3
3
  import { ShimmeringText } from './chunk-SGI25ZJ6.js';
4
4
  import { StaggerChildren } from './chunk-DQPK2XRL.js';
@@ -42,6 +42,7 @@ function TestimonialsBlock({ props }) {
42
42
  const title = props.title ?? "Build by makers, loved by thousand developers";
43
43
  const description = props.description ?? "Gemini is evolving to be more than just the models. It supports an entire to the APIs and platforms helping developers and businesses innovate.";
44
44
  const testimonials = props.testimonials ?? defaultTestimonials;
45
+ const featuredCompanyLogo = props.featuredCompanyLogo ?? null;
45
46
  const featured = React.useMemo(() => testimonials.find((t) => t.featured) ?? testimonials[0], [testimonials]);
46
47
  const rest = React.useMemo(() => testimonials.filter((t) => t !== featured), [testimonials, featured]);
47
48
  return /* @__PURE__ */ jsx("section", { className: "py-16 md:py-32", children: /* @__PURE__ */ jsxs("div", { className: "mx-auto max-w-6xl space-y-8 px-6 md:space-y-16", children: [
@@ -59,16 +60,16 @@ function TestimonialsBlock({ props }) {
59
60
  ] }),
60
61
  /* @__PURE__ */ jsxs(StaggerChildren, { staggerMs: 80, direction: "up", distance: 16, className: "grid gap-4 sm:grid-cols-2 md:grid-cols-4 lg:grid-rows-2", children: [
61
62
  !!featured && /* @__PURE__ */ jsx(Shine, { enableOnHover: true, loop: true, loopDelay: 200, color: "var(--color-accent)", opacity: 0.12, className: "sm:col-span-2 lg:row-span-2", children: /* @__PURE__ */ jsxs(Card, { className: "grid grid-rows-[auto_1fr] gap-8 h-full sm:p-6", children: [
62
- /* @__PURE__ */ jsx(CardHeader, { children: /* @__PURE__ */ jsx(
63
+ featuredCompanyLogo ? /* @__PURE__ */ jsx(CardHeader, { children: /* @__PURE__ */ jsx(
63
64
  "img",
64
65
  {
65
66
  className: "h-6 w-fit dark:invert",
66
- src: LOCAL_NIKE_LOGO_SRC,
67
- alt: "Nike Logo",
67
+ src: featuredCompanyLogo,
68
+ alt: "Company Logo",
68
69
  height: "24",
69
70
  width: "auto"
70
71
  }
71
- ) }),
72
+ ) }) : null,
72
73
  /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsxs("blockquote", { className: "grid h-full grid-rows-[1fr_auto] gap-6", children: [
73
74
  /* @__PURE__ */ jsx("p", { className: "text-xl font-medium", children: featured.quote }),
74
75
  /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-[auto_1fr] items-center gap-4", children: [
@@ -3,10 +3,10 @@ import { Typography } from './chunk-Q7PCHHVJ.js';
3
3
  import { Spinner } from './chunk-ZLSWCV55.js';
4
4
  import { Heading } from './chunk-UXX6HHPS.js';
5
5
  import { Input } from './chunk-AP3XXYAY.js';
6
- import { useSafeTimeout } from './chunk-MDAYDDTC.js';
7
6
  import { ScrollFadeIn } from './chunk-I23DDSU7.js';
8
7
  import { Button } from './chunk-7KIDDF3I.js';
9
8
  import { CheckIcon } from './chunk-CXACRCZ4.js';
9
+ import { Alert, AlertDescription } from './chunk-6CLSVCWP.js';
10
10
  import { cn } from './chunk-QYZT24TS.js';
11
11
  import { useState } from 'react';
12
12
  import { useBoundProp } from '@json-render/react';
@@ -15,30 +15,22 @@ import { jsx, jsxs } from 'react/jsx-runtime';
15
15
  function NewsletterBlock({ props, bindings, emit }) {
16
16
  const title = props.title ?? "Stay in the loop";
17
17
  const description = props.description ?? "Get notified about new components, updates, and design system tips. No spam.";
18
+ const state = props.state ?? "idle";
19
+ const error = props.error ?? null;
18
20
  const [boundEmail, setBoundEmail] = useBoundProp(props.email, bindings?.email);
19
21
  const [localEmail, setLocalEmail] = useState("");
20
22
  const isEmailBound = !!bindings?.email;
21
23
  const email = isEmailBound ? boundEmail ?? "" : localEmail;
22
24
  const setEmail = isEmailBound ? setBoundEmail : setLocalEmail;
23
- const [status, setStatus] = useState("idle");
24
- const setSafeTimeout = useSafeTimeout();
25
- const handleSubmit = async (e) => {
25
+ const handleSubmit = (e) => {
26
26
  e.preventDefault();
27
27
  if (!email.trim()) return;
28
- setStatus("loading");
29
28
  emit("subscribe");
30
- setSafeTimeout(() => {
31
- setStatus("success");
32
- setSafeTimeout(() => {
33
- setStatus("idle");
34
- setEmail("");
35
- }, 3e3);
36
- }, 600);
37
29
  };
38
30
  return /* @__PURE__ */ jsx("section", { className: cn("py-16 md:py-24"), children: /* @__PURE__ */ jsx("div", { className: "mx-auto max-w-xl px-6", children: /* @__PURE__ */ jsx(ScrollFadeIn, { children: /* @__PURE__ */ jsx(Shine, { enableOnHover: true, loop: true, loopDelay: 300, color: "var(--color-accent)", opacity: 0.1, children: /* @__PURE__ */ jsxs("div", { className: "glass-panel rounded-2xl border border-border/50 p-8 text-center sm:p-12", children: [
39
31
  /* @__PURE__ */ jsx(Heading, { level: 2, size: "section", className: "text-text-primary", children: title }),
40
32
  /* @__PURE__ */ jsx(Typography, { variant: "body", className: "mt-4 text-text-secondary", children: description }),
41
- status === "success" ? /* @__PURE__ */ jsxs("div", { className: "mt-8 flex items-center justify-center gap-2 text-success", children: [
33
+ state === "success" ? /* @__PURE__ */ jsxs("div", { className: "mt-8 flex items-center justify-center gap-2 text-success", children: [
42
34
  /* @__PURE__ */ jsx(CheckIcon, { size: 20 }),
43
35
  /* @__PURE__ */ jsxs("span", { className: "text-sm font-medium", children: [
44
36
  "You",
@@ -68,14 +60,15 @@ function NewsletterBlock({ props, bindings, emit }) {
68
60
  {
69
61
  type: "submit",
70
62
  variant: "accent",
71
- disabled: status === "loading",
63
+ disabled: state === "loading",
72
64
  className: "shrink-0",
73
- children: status === "loading" ? /* @__PURE__ */ jsx(Spinner, { className: "h-4 w-4" }) : "Subscribe"
65
+ children: state === "loading" ? /* @__PURE__ */ jsx(Spinner, { className: "h-4 w-4" }) : "Subscribe"
74
66
  }
75
67
  )
76
68
  ]
77
69
  }
78
70
  ),
71
+ !!error && /* @__PURE__ */ jsx(Alert, { variant: "destructive", className: "mt-4", children: /* @__PURE__ */ jsx(AlertDescription, { children: error }) }),
79
72
  /* @__PURE__ */ jsx(Typography, { variant: "small", className: "mt-4 text-text-tertiary", children: "Unsubscribe anytime. We respect your inbox." })
80
73
  ] }) }) }) }) });
81
74
  }
@@ -9,6 +9,7 @@ import { CheckIcon } from './chunk-CXACRCZ4.js';
9
9
  import { Badge } from './chunk-S4JAHKOP.js';
10
10
  import { cn } from './chunk-QYZT24TS.js';
11
11
  import { useTranslations } from 'next-intl';
12
+ import { useBoundProp } from '@json-render/react';
12
13
  import { useState } from 'react';
13
14
  import { jsx, jsxs } from 'react/jsx-runtime';
14
15
 
@@ -47,13 +48,18 @@ var defaultPlans = [
47
48
  badge: null
48
49
  }
49
50
  ];
50
- function PricingBlock({ props, emit }) {
51
+ function PricingBlock({ props, emit, bindings }) {
51
52
  const title = props.title ?? "Simple, transparent pricing";
52
53
  const description = props.description ?? "Choose the plan that's right for you. Change or cancel anytime.";
53
54
  const plans = props.plans ?? defaultPlans;
54
55
  const showBillingToggle = props.showBillingToggle ?? true;
55
56
  const t = useTranslations("blocks.pricingBlock");
56
- const [isYearly, setIsYearly] = useState(false);
57
+ const [, setBoundSelectedPlanName] = useBoundProp(props.selectedPlanName, bindings?.selectedPlanName);
58
+ const [, setBoundIsYearly] = useBoundProp(props.isYearly, bindings?.isYearly);
59
+ const [localIsYearly, setLocalIsYearly] = useState(false);
60
+ const isYearlyBound = !!bindings?.isYearly;
61
+ const isYearly = isYearlyBound ? props.isYearly ?? false : localIsYearly;
62
+ const setIsYearly = isYearlyBound ? setBoundIsYearly : setLocalIsYearly;
57
63
  return /* @__PURE__ */ jsx("section", { className: "py-16 md:py-24", children: /* @__PURE__ */ jsxs("div", { className: "container mx-auto px-6 lg:px-8", children: [
58
64
  /* @__PURE__ */ jsxs("div", { className: "mb-12 text-center", children: [
59
65
  /* @__PURE__ */ jsx(Heading, { level: 2, size: "section", className: "mb-4 sm:text-4xl", children: title }),
@@ -97,7 +103,10 @@ function PricingBlock({ props, emit }) {
97
103
  feature
98
104
  ] }, feature)) })
99
105
  ] }),
100
- /* @__PURE__ */ jsx(CardFooter, { children: /* @__PURE__ */ jsx(Button, { className: "w-full", variant: plan.variant, onClick: () => emit("selectPlan"), children: plan.action }) })
106
+ /* @__PURE__ */ jsx(CardFooter, { children: /* @__PURE__ */ jsx(Button, { className: "w-full", variant: plan.variant, onClick: () => {
107
+ setBoundSelectedPlanName(plan.name);
108
+ emit("selectPlan");
109
+ }, children: plan.action }) })
101
110
  ]
102
111
  },
103
112
  plan.name
@@ -0,0 +1,112 @@
1
+ import { Textarea } from './chunk-4OBE2FS2.js';
2
+ import { StaggerChildren } from './chunk-DQPK2XRL.js';
3
+ import { Select, SelectTrigger, SelectValue, SelectContent, SelectItem } from './chunk-WH62BE24.js';
4
+ import { Form, FormField, FormItem, FormLabel, FormControl, FormDescription, FormMessage } from './chunk-UN2SJ42K.js';
5
+ import { Input } from './chunk-AP3XXYAY.js';
6
+ import { Card, CardHeader, CardTitle, CardDescription, CardContent } from './chunk-7UY24UWL.js';
7
+ import { Button } from './chunk-7KIDDF3I.js';
8
+ import { Alert, AlertDescription } from './chunk-6CLSVCWP.js';
9
+ import { zodResolver } from '@hookform/resolvers/zod';
10
+ import { useForm } from 'react-hook-form';
11
+ import { z } from 'zod';
12
+ import { useBoundProp } from '@json-render/react';
13
+ import { jsxs, jsx } from 'react/jsx-runtime';
14
+
15
+ var profileFormSchema = z.object({
16
+ username: z.string().min(2, {
17
+ message: "Username must be at least 2 characters."
18
+ }).max(30, {
19
+ message: "Username must not be longer than 30 characters."
20
+ }),
21
+ email: z.string({
22
+ error: "Please select an email to display."
23
+ }).email(),
24
+ bio: z.string().max(160).min(4)
25
+ });
26
+ var defaultFormValues = {
27
+ bio: "I own a computer."
28
+ };
29
+ var DEFAULT_EMAIL_OPTIONS = [
30
+ { value: "user@example.com", label: "user@example.com" }
31
+ ];
32
+ function CreateBlock({ props, emit, bindings }) {
33
+ const title = props.title ?? "Create Profile";
34
+ const description = props.description ?? "Example of a complex form with Zod validation.";
35
+ const submitLabel = props.submitLabel ?? "Update profile";
36
+ const state = props.state ?? "idle";
37
+ const error = props.error ?? null;
38
+ const emailOptions = props.emailOptions ?? DEFAULT_EMAIL_OPTIONS;
39
+ const [, setBoundUsername] = useBoundProp(props.username, bindings?.username);
40
+ const [, setBoundEmail] = useBoundProp(props.email, bindings?.email);
41
+ const [, setBoundBio] = useBoundProp(props.bio, bindings?.bio);
42
+ const form = useForm({
43
+ resolver: zodResolver(profileFormSchema),
44
+ defaultValues: {
45
+ ...defaultFormValues,
46
+ ...props.username ? { username: props.username } : {},
47
+ ...props.email ? { email: props.email } : {},
48
+ ...props.bio ? { bio: props.bio } : {}
49
+ },
50
+ mode: "onChange"
51
+ });
52
+ function handleSubmit(data) {
53
+ setBoundUsername(data.username);
54
+ setBoundEmail(data.email);
55
+ setBoundBio(data.bio);
56
+ emit("submit");
57
+ }
58
+ return /* @__PURE__ */ jsxs(Card, { className: "w-full max-w-2xl mx-auto", children: [
59
+ /* @__PURE__ */ jsxs(CardHeader, { children: [
60
+ /* @__PURE__ */ jsx(CardTitle, { children: title }),
61
+ /* @__PURE__ */ jsx(CardDescription, { children: description })
62
+ ] }),
63
+ /* @__PURE__ */ jsxs(CardContent, { children: [
64
+ !!error && /* @__PURE__ */ jsx(Alert, { variant: "destructive", className: "mb-4", children: /* @__PURE__ */ jsx(AlertDescription, { children: error }) }),
65
+ /* @__PURE__ */ jsx(Form, { ...form, children: /* @__PURE__ */ jsx(StaggerChildren, { staggerMs: 60, className: "space-y-8 text-text-primary", children: /* @__PURE__ */ jsxs("form", { onSubmit: form.handleSubmit(handleSubmit), className: "contents", children: [
66
+ /* @__PURE__ */ jsx(
67
+ FormField,
68
+ {
69
+ control: form.control,
70
+ name: "username",
71
+ render: ({ field }) => /* @__PURE__ */ jsxs(FormItem, { children: [
72
+ /* @__PURE__ */ jsx(FormLabel, { children: "Username" }),
73
+ /* @__PURE__ */ jsx(FormControl, { children: /* @__PURE__ */ jsx(Input, { placeholder: "shadcn", ...field }) }),
74
+ /* @__PURE__ */ jsx(FormDescription, { children: "Public display name." }),
75
+ /* @__PURE__ */ jsx(FormMessage, {})
76
+ ] })
77
+ }
78
+ ),
79
+ /* @__PURE__ */ jsx(
80
+ FormField,
81
+ {
82
+ control: form.control,
83
+ name: "email",
84
+ render: ({ field }) => /* @__PURE__ */ jsxs(FormItem, { children: [
85
+ /* @__PURE__ */ jsx(FormLabel, { children: "Email" }),
86
+ /* @__PURE__ */ jsxs(Select, { onValueChange: field.onChange, defaultValue: field.value, children: [
87
+ /* @__PURE__ */ jsx(FormControl, { children: /* @__PURE__ */ jsx(SelectTrigger, { children: /* @__PURE__ */ jsx(SelectValue, { placeholder: "Select email" }) }) }),
88
+ /* @__PURE__ */ jsx(SelectContent, { children: emailOptions.map((opt) => /* @__PURE__ */ jsx(SelectItem, { value: opt.value, children: opt.label }, opt.value)) })
89
+ ] }),
90
+ /* @__PURE__ */ jsx(FormMessage, {})
91
+ ] })
92
+ }
93
+ ),
94
+ /* @__PURE__ */ jsx(
95
+ FormField,
96
+ {
97
+ control: form.control,
98
+ name: "bio",
99
+ render: ({ field }) => /* @__PURE__ */ jsxs(FormItem, { children: [
100
+ /* @__PURE__ */ jsx(FormLabel, { children: "Bio" }),
101
+ /* @__PURE__ */ jsx(FormControl, { children: /* @__PURE__ */ jsx(Textarea, { placeholder: "Bio...", ...field }) }),
102
+ /* @__PURE__ */ jsx(FormMessage, {})
103
+ ] })
104
+ }
105
+ ),
106
+ /* @__PURE__ */ jsx(Button, { type: "submit", disabled: state === "submitting", children: state === "submitting" ? "Submitting..." : submitLabel })
107
+ ] }) }) })
108
+ ] })
109
+ ] });
110
+ }
111
+
112
+ export { CreateBlock };