@vadimcomanescu/nadicode-design-system 5.0.0 → 5.0.2
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.
- package/.agents/skills/seed/SKILL.md +100 -24
- package/.agents/skills/seed/references/composition.md +37 -21
- package/.agents/skills/seed/references/glass-and-effects.md +7 -5
- package/.agents/skills/seed/references/responsive.md +22 -63
- package/.agents/skills/seed/references/state-machines.md +54 -46
- package/contracts/release-governance-baseline.json +0 -1
- package/dist/{TeamPage-BX3RMSZU.js → TeamPage-UO3V2JDK.js} +33 -32
- package/dist/catalog/catalog.d.ts +66 -4
- package/dist/catalog/catalog.js +9 -9
- package/dist/catalog/components.d.ts +1 -2
- package/dist/catalog/components.js +27 -27
- package/dist/catalog/definitions/blocks-agent.d.ts +0 -1
- package/dist/catalog/definitions/blocks-agent.js +1 -1
- package/dist/catalog/definitions/blocks-auth.d.ts +16 -0
- package/dist/catalog/definitions/blocks-auth.js +1 -1
- package/dist/catalog/definitions/blocks-content.d.ts +18 -0
- package/dist/catalog/definitions/blocks-content.js +1 -1
- package/dist/catalog/definitions/blocks-crud.d.ts +22 -2
- package/dist/catalog/definitions/blocks-crud.js +1 -1
- package/dist/catalog/definitions/blocks-data.d.ts +2 -0
- package/dist/catalog/definitions/blocks-data.js +1 -1
- package/dist/catalog/definitions/blocks-marketing.d.ts +8 -0
- package/dist/catalog/definitions/blocks-marketing.js +1 -1
- package/dist/catalog/definitions/chat.d.ts +0 -1
- package/dist/catalog/definitions/chat.js +1 -1
- package/dist/catalog/definitions/index.d.ts +66 -4
- package/dist/catalog/definitions/index.js +8 -8
- package/dist/catalog/primitives/chat.js +2 -2
- package/dist/catalog/primitives/index.js +3 -3
- package/dist/{chunk-C7LO3JEF.js → chunk-33UWVOQ6.js} +44 -12
- package/dist/{chunk-IHGZJS7N.js → chunk-3FJG5MAT.js} +8 -2
- package/dist/{chunk-UOUERAB4.js → chunk-3LROWCZE.js} +26 -8
- package/dist/{chunk-UIYX2EMT.js → chunk-5RBO2IMZ.js} +7 -2
- package/dist/{chunk-7SRNVMBY.js → chunk-7LYRUSWM.js} +8 -3
- package/dist/{chunk-ZND7AAWG.js → chunk-A4QNTJUR.js} +4 -2
- package/dist/{chunk-P7CTBRHO.js → chunk-AP5SGSN7.js} +15 -5
- package/dist/{chunk-5MLOZVOQ.js → chunk-B4373MDA.js} +9 -4
- package/dist/{chunk-KV726HMK.js → chunk-BOWKE7OE.js} +4 -4
- package/dist/{chunk-NVBF4OWT.js → chunk-BY6LWOHB.js} +7 -2
- package/dist/{chunk-4TK2PXMJ.js → chunk-CTVV6JS6.js} +1 -1
- package/dist/{chunk-6KRT337C.js → chunk-E4KUPYHE.js} +1 -1
- package/dist/{chunk-3TYPQWKD.js → chunk-FSU7ZM5V.js} +7 -2
- package/dist/{chunk-QLPU2IEO.js → chunk-FX3GYS5O.js} +27 -4
- package/dist/{chunk-OMI2LLXM.js → chunk-H3KTAHJP.js} +17 -3
- package/dist/{chunk-UGXI4PES.js → chunk-IW36SVOH.js} +17 -7
- package/dist/{chunk-5L2RFJZR.js → chunk-JDHD4L6N.js} +1 -1
- package/dist/{chunk-CAET62YQ.js → chunk-NBDUZA66.js} +11 -4
- package/dist/{chunk-TNDMBLYP.js → chunk-NDQO7AO6.js} +15 -3
- package/dist/{chunk-MT76BPYV.js → chunk-PQOL3E2V.js} +1 -1
- package/dist/{chunk-ZNF6S3DQ.js → chunk-QCFDSOTV.js} +9 -5
- package/dist/{chunk-ID3N3MHQ.js → chunk-R4SBK6Y5.js} +7 -2
- package/dist/{chunk-GNKNT52O.js → chunk-TTDKPZ75.js} +1 -1
- package/dist/{chunk-BAB6AHOM.js → chunk-U43JTK45.js} +1 -1
- package/dist/{chunk-WHYKEOUV.js → chunk-U5QLJHYN.js} +0 -2
- package/dist/{chunk-4ACR6NGQ.js → chunk-UAN2YEI5.js} +3 -7
- package/dist/{chunk-NA6ZPKIK.js → chunk-UCFR7GLW.js} +11 -17
- package/dist/{chunk-R4DPHCHJ.js → chunk-UMEBNHKR.js} +9 -6
- package/dist/{chunk-A44E44UV.js → chunk-UPMSE6PQ.js} +7 -2
- package/dist/{chunk-HMN4K4L6.js → chunk-VQVWFCHF.js} +7 -7
- package/dist/{chunk-LZ66ADSL.js → chunk-WGQHM56J.js} +25 -25
- package/dist/{chunk-JPNNAU26.js → chunk-XLN4NVKU.js} +16 -28
- package/dist/{chunk-CPHVCY3M.js → chunk-XUWKGDUY.js} +1 -1
- package/dist/{chunk-FAKTXE3F.js → chunk-YEAJLVGB.js} +8 -4
- package/dist/{chunk-56TNQ2P4.js → chunk-YMAEXGD2.js} +1 -1
- package/dist/{chunk-YNBDA24W.js → chunk-ZKA5X3E4.js} +12 -3
- package/dist/{chunk-VUNXVYOH.js → chunk-ZL6BPQNN.js} +19 -10
- package/dist/{chunk-XYYZRQES.js → chunk-ZU7MDRCI.js} +1 -1
- package/dist/components/blocks/AgentConversationBlock.d.ts +2 -5
- package/dist/components/blocks/AgentConversationBlock.js +2 -2
- package/dist/components/blocks/AgentWorkbenchBlock.d.ts +2 -5
- package/dist/components/blocks/AgentWorkbenchBlock.js +2 -2
- package/dist/components/blocks/ApiKeysBlock.d.ts +1 -1
- package/dist/components/blocks/ApiKeysBlock.js +1 -1
- package/dist/components/blocks/AuthLayout.d.ts +1 -1
- package/dist/components/blocks/AuthLayout.js +2 -2
- package/dist/components/blocks/CommandPaletteBlock.d.ts +1 -1
- package/dist/components/blocks/CommandPaletteBlock.js +1 -1
- package/dist/components/blocks/ContactBlock.d.ts +1 -1
- package/dist/components/blocks/ContactBlock.js +1 -1
- package/dist/components/blocks/CreateBlock.d.ts +1 -1
- package/dist/components/blocks/CreateBlock.js +1 -1
- package/dist/components/blocks/CrudListBlock.d.ts +1 -1
- package/dist/components/blocks/CrudListBlock.js +1 -1
- package/dist/components/blocks/DashboardBlock.js +1 -1
- package/dist/components/blocks/HeroBlock.d.ts +1 -25
- package/dist/components/blocks/HeroBlock.js +1 -1
- package/dist/components/blocks/InteractiveAreaChartBlock.d.ts +1 -1
- package/dist/components/blocks/InteractiveAreaChartBlock.js +1 -1
- package/dist/components/blocks/LoginBlock.d.ts +1 -1
- package/dist/components/blocks/LoginBlock.js +1 -1
- package/dist/components/blocks/NewsletterBlock.d.ts +3 -1
- package/dist/components/blocks/NewsletterBlock.js +1 -1
- package/dist/components/blocks/OTPBlock.d.ts +1 -1
- package/dist/components/blocks/OTPBlock.js +1 -1
- package/dist/components/blocks/OnboardingBlock.d.ts +1 -1
- package/dist/components/blocks/OnboardingBlock.js +1 -1
- package/dist/components/blocks/OnboardingFlowBlock.d.ts +1 -1
- package/dist/components/blocks/OnboardingFlowBlock.js +2 -2
- package/dist/components/blocks/PasswordRecoveryBlock.d.ts +1 -1
- package/dist/components/blocks/PasswordRecoveryBlock.js +1 -1
- package/dist/components/blocks/ResetPasswordBlock.d.ts +1 -1
- package/dist/components/blocks/ResetPasswordBlock.js +1 -1
- package/dist/components/blocks/TwoFactorSetupBlock.d.ts +1 -1
- package/dist/components/blocks/TwoFactorSetupBlock.js +2 -2
- package/dist/components/blocks/WizardBlock.d.ts +1 -1
- package/dist/components/blocks/WizardBlock.js +1 -1
- package/dist/components/blocks/user/InviteUserModal.d.ts +1 -18
- package/dist/components/blocks/user/InviteUserModal.js +1 -1
- package/dist/components/ui/ChatMessage.d.ts +2 -6
- package/dist/components/ui/ChatMessage.js +1 -1
- package/dist/components/ui/FormWizard.d.ts +1 -2
- package/dist/components/ui/FormWizard.js +1 -1
- package/dist/components/ui/KanbanBoard.d.ts +3 -3
- package/dist/components/ui/KanbanBoard.js +1 -1
- package/dist/index.js +0 -137
- package/dist/lib/json-render/app.js +1 -1
- package/dist/lib/json-render/catalog.d.ts +28 -0
- package/dist/lib/json-render/catalog.js +10 -10
- package/dist/lib/json-render/registry.js +10 -10
- package/dist/lib/json-render/showcase-spec.js +1 -1
- package/dist/lib-index.d.ts +6 -24
- package/package.json +1 -5
- package/dist/catalog/types.d.ts +0 -4
- package/dist/catalog/types.js +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { StaggerChildren } from './chunk-DQPK2XRL.js';
|
|
2
2
|
import { InputOTP, InputOTPGroup, InputOTPSlot } from './chunk-WN5ONOHC.js';
|
|
3
|
-
import { FormWizard } from './chunk-
|
|
3
|
+
import { FormWizard } from './chunk-U5QLJHYN.js';
|
|
4
4
|
import { Label } from './chunk-LIBXYD5Q.js';
|
|
5
5
|
import { useSafeTimeout } from './chunk-MDAYDDTC.js';
|
|
6
6
|
import { Checkbox } from './chunk-756Q7AC5.js';
|
|
@@ -13,6 +13,7 @@ import { ShieldIcon } from './chunk-P6IRHPFM.js';
|
|
|
13
13
|
import { Badge } from './chunk-S4JAHKOP.js';
|
|
14
14
|
import { CopyIcon } from './chunk-TV4RSQH4.js';
|
|
15
15
|
import * as React from 'react';
|
|
16
|
+
import { useBoundProp } from '@json-render/react';
|
|
16
17
|
import { useReducedMotion } from 'motion/react';
|
|
17
18
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
18
19
|
|
|
@@ -26,14 +27,18 @@ var DEFAULT_BACKUP_CODES = [
|
|
|
26
27
|
"y5z6-a7b8",
|
|
27
28
|
"c9d0-e1f2"
|
|
28
29
|
];
|
|
29
|
-
function TwoFactorSetupBlock({ props, emit }) {
|
|
30
|
+
function TwoFactorSetupBlock({ props, bindings, emit, on }) {
|
|
30
31
|
const qrCodeUrl = props.qrCodeUrl ?? void 0;
|
|
31
32
|
const secret = props.secret ?? "JBSWY3DPEHPK3PXP";
|
|
32
33
|
const backupCodes = props.backupCodes ?? DEFAULT_BACKUP_CODES;
|
|
33
34
|
const title = props.title ?? "Set up two-factor authentication";
|
|
34
35
|
const description = props.description ?? "Add an extra layer of security to your account";
|
|
35
36
|
const prefersReduced = useReducedMotion();
|
|
36
|
-
const [
|
|
37
|
+
const [boundCode, setBoundCode] = useBoundProp(props.verifyCode, bindings?.verifyCode);
|
|
38
|
+
const [localOtpCode, setLocalOtpCode] = React.useState("");
|
|
39
|
+
const isCodeBound = !!bindings?.verifyCode;
|
|
40
|
+
const otpCode = isCodeBound ? boundCode ?? "" : localOtpCode;
|
|
41
|
+
const setOtpCode = isCodeBound ? setBoundCode : setLocalOtpCode;
|
|
37
42
|
const [verified, setVerified] = React.useState(false);
|
|
38
43
|
const [verifyError, setVerifyError] = React.useState();
|
|
39
44
|
const [savedCodes, setSavedCodes] = React.useState(false);
|
|
@@ -154,8 +159,7 @@ function TwoFactorSetupBlock({ props, emit }) {
|
|
|
154
159
|
emit: (event) => {
|
|
155
160
|
if (event === "complete") emit("complete");
|
|
156
161
|
},
|
|
157
|
-
on
|
|
158
|
-
}, shouldPreventDefault: false, bound: false }),
|
|
162
|
+
on,
|
|
159
163
|
steps
|
|
160
164
|
}
|
|
161
165
|
) })
|
|
@@ -12,6 +12,7 @@ import { CheckIcon } from './chunk-CXACRCZ4.js';
|
|
|
12
12
|
import { Badge } from './chunk-S4JAHKOP.js';
|
|
13
13
|
import { cn } from './chunk-QYZT24TS.js';
|
|
14
14
|
import * as React from 'react';
|
|
15
|
+
import { useBoundProp } from '@json-render/react';
|
|
15
16
|
import { useTranslations } from 'next-intl';
|
|
16
17
|
import { useReducedMotion } from 'motion/react';
|
|
17
18
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
@@ -21,12 +22,16 @@ var MODE_ICONS = {
|
|
|
21
22
|
"magic-link": /* @__PURE__ */ jsx(SparklesIcon, { size: 32, className: "text-accent" })
|
|
22
23
|
};
|
|
23
24
|
var INSTRUCTION_STEPS = ["step1", "step2", "step3"];
|
|
24
|
-
function PasswordRecoveryBlock({ props, emit }) {
|
|
25
|
+
function PasswordRecoveryBlock({ props, bindings, emit }) {
|
|
25
26
|
const mode = props.mode ?? "reset";
|
|
26
27
|
const prefersReduced = useReducedMotion();
|
|
27
28
|
const tShared = useTranslations("auth.passwordRecovery.shared");
|
|
28
29
|
const tMode = useTranslations(mode === "magic-link" ? "auth.passwordRecovery.magicLink" : "auth.passwordRecovery.reset");
|
|
29
|
-
const [
|
|
30
|
+
const [boundEmail, setBoundEmail] = useBoundProp(props.email, bindings?.email);
|
|
31
|
+
const [localEmail, setLocalEmail] = React.useState("");
|
|
32
|
+
const isEmailBound = !!bindings?.email;
|
|
33
|
+
const email = isEmailBound ? boundEmail ?? "" : localEmail;
|
|
34
|
+
const setEmail = isEmailBound ? setBoundEmail : setLocalEmail;
|
|
30
35
|
const [state, setState] = React.useState("entry");
|
|
31
36
|
const [resendState, setResendState] = React.useState("idle");
|
|
32
37
|
const setSafeTimeout = useSafeTimeout();
|
|
@@ -2,7 +2,7 @@ import { mapToolCallStatus } from './chunk-STKNMEJA.js';
|
|
|
2
2
|
import { ScrollArea } from './chunk-GLU236NN.js';
|
|
3
3
|
import { ChatThinkingMessage } from './chunk-CY3PROVO.js';
|
|
4
4
|
import { ChatToolCall, ChatToolCallHeader, ChatToolCallContent, ChatToolCallInput, ChatToolCallOutput } from './chunk-L2IRYY6K.js';
|
|
5
|
-
import { ChatMessage, ChatMessageContent, ChatMessageFooter, ChatMessageTimestamp } from './chunk-
|
|
5
|
+
import { ChatMessage, ChatMessageContent, ChatMessageFooter, ChatMessageTimestamp } from './chunk-UAN2YEI5.js';
|
|
6
6
|
import * as React from 'react';
|
|
7
7
|
import { useTranslations } from 'next-intl';
|
|
8
8
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
@@ -7,7 +7,7 @@ import { Heading } from './chunk-UXX6HHPS.js';
|
|
|
7
7
|
import { CodeDiffViewer } from './chunk-DFPXK2JO.js';
|
|
8
8
|
import { ChatThinkingMessage } from './chunk-CY3PROVO.js';
|
|
9
9
|
import { ChatToolCall, ChatToolCallHeader, ChatToolCallContent, ChatToolCallInput, ChatToolCallOutput } from './chunk-L2IRYY6K.js';
|
|
10
|
-
import { ChatMessage, ChatMessageContent } from './chunk-
|
|
10
|
+
import { ChatMessage, ChatMessageContent } from './chunk-UAN2YEI5.js';
|
|
11
11
|
import { Button } from './chunk-7KIDDF3I.js';
|
|
12
12
|
import { ArtifactCard } from './chunk-D4NC7WX5.js';
|
|
13
13
|
import { SendIcon } from './chunk-CRZ2JE24.js';
|
|
@@ -54,7 +54,6 @@ function FormWizard({
|
|
|
54
54
|
bindings,
|
|
55
55
|
emit,
|
|
56
56
|
steps = DEFAULT_STEPS,
|
|
57
|
-
onComplete,
|
|
58
57
|
ref
|
|
59
58
|
}) {
|
|
60
59
|
const {
|
|
@@ -92,7 +91,6 @@ function FormWizard({
|
|
|
92
91
|
goTo(currentStep + 1);
|
|
93
92
|
} else {
|
|
94
93
|
emit("complete");
|
|
95
|
-
onComplete?.();
|
|
96
94
|
}
|
|
97
95
|
};
|
|
98
96
|
const handleBack = () => {
|
|
@@ -8,9 +8,6 @@ var ChatMessageContext = createContext("user");
|
|
|
8
8
|
function useMessageRole() {
|
|
9
9
|
return useContext(ChatMessageContext);
|
|
10
10
|
}
|
|
11
|
-
function normalizeRole(role) {
|
|
12
|
-
return role === "agent" ? "assistant" : role;
|
|
13
|
-
}
|
|
14
11
|
var chatMessageVariants = cva("flex gap-4 max-w-full", {
|
|
15
12
|
variants: {
|
|
16
13
|
role: {
|
|
@@ -45,12 +42,11 @@ function ChatMessage({
|
|
|
45
42
|
ref,
|
|
46
43
|
...props
|
|
47
44
|
}) {
|
|
48
|
-
const normalized = normalizeRole(role);
|
|
49
45
|
return /* @__PURE__ */ jsx(ChatMessageContext.Provider, { value: role, children: /* @__PURE__ */ jsx(
|
|
50
46
|
"div",
|
|
51
47
|
{
|
|
52
48
|
ref,
|
|
53
|
-
className: cn(chatMessageVariants({ role
|
|
49
|
+
className: cn(chatMessageVariants({ role }), className),
|
|
54
50
|
...props,
|
|
55
51
|
children
|
|
56
52
|
}
|
|
@@ -64,7 +60,7 @@ function ChatMessageContent({
|
|
|
64
60
|
ref,
|
|
65
61
|
...props
|
|
66
62
|
}) {
|
|
67
|
-
const role =
|
|
63
|
+
const role = useMessageRole();
|
|
68
64
|
return /* @__PURE__ */ jsxs(
|
|
69
65
|
"div",
|
|
70
66
|
{
|
|
@@ -91,7 +87,7 @@ function ChatMessageAvatar({
|
|
|
91
87
|
className,
|
|
92
88
|
ref
|
|
93
89
|
}) {
|
|
94
|
-
const role =
|
|
90
|
+
const role = useMessageRole();
|
|
95
91
|
const fallback = name ? name.slice(0, 2).toUpperCase() : role === "user" ? "U" : "AI";
|
|
96
92
|
const label = role === "user" ? "User avatar" : "Assistant avatar";
|
|
97
93
|
return /* @__PURE__ */ jsxs(
|
|
@@ -195,23 +195,17 @@ function HeroSplitVariant({
|
|
|
195
195
|
] })
|
|
196
196
|
] }) });
|
|
197
197
|
}
|
|
198
|
-
function HeroBlock(
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
if (variant2 === "split") return /* @__PURE__ */ jsx(HeroSplitVariant, { ...internalProps });
|
|
210
|
-
return /* @__PURE__ */ jsx(HeroCenteredVariant, { ...internalProps });
|
|
211
|
-
}
|
|
212
|
-
const { variant = "centered", ...rest } = blockProps;
|
|
213
|
-
if (variant === "split") return /* @__PURE__ */ jsx(HeroSplitVariant, { ...rest });
|
|
214
|
-
return /* @__PURE__ */ jsx(HeroCenteredVariant, { ...rest });
|
|
198
|
+
function HeroBlock({ props, emit }) {
|
|
199
|
+
const variant = props.variant ?? "centered";
|
|
200
|
+
const internalProps = {
|
|
201
|
+
headline: props.headline ?? void 0,
|
|
202
|
+
subheadline: props.subheadline ?? void 0,
|
|
203
|
+
primaryAction: props.primaryAction ? { label: props.primaryAction.label, onClick: () => emit("primaryAction") } : void 0,
|
|
204
|
+
secondaryAction: props.secondaryAction ? { label: props.secondaryAction.label, onClick: () => emit("secondaryAction") } : void 0,
|
|
205
|
+
announcement: props.announcement ? { label: props.announcement.label, text: props.announcement.text, href: props.announcement.href ?? void 0 } : void 0
|
|
206
|
+
};
|
|
207
|
+
if (variant === "split") return /* @__PURE__ */ jsx(HeroSplitVariant, { ...internalProps });
|
|
208
|
+
return /* @__PURE__ */ jsx(HeroCenteredVariant, { ...internalProps });
|
|
215
209
|
}
|
|
216
210
|
|
|
217
211
|
export { HeroBlock };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { LoginBlock } from './chunk-
|
|
1
|
+
import { LoginBlock } from './chunk-FX3GYS5O.js';
|
|
2
2
|
import { StaggerChildren } from './chunk-DQPK2XRL.js';
|
|
3
3
|
import { Heading } from './chunk-UXX6HHPS.js';
|
|
4
4
|
import { siteConfig } from './chunk-A7NUWD76.js';
|
|
@@ -17,6 +17,8 @@ var defaultLabels = {
|
|
|
17
17
|
};
|
|
18
18
|
function AuthLayout({
|
|
19
19
|
props,
|
|
20
|
+
emit,
|
|
21
|
+
on,
|
|
20
22
|
children
|
|
21
23
|
}) {
|
|
22
24
|
const mode = props.mode ?? "login";
|
|
@@ -62,12 +64,13 @@ function AuthLayout({
|
|
|
62
64
|
showSocial: null,
|
|
63
65
|
forgotPasswordHref: null,
|
|
64
66
|
signUpHref: null,
|
|
65
|
-
signInHref: null
|
|
67
|
+
signInHref: null,
|
|
68
|
+
email: null,
|
|
69
|
+
password: null,
|
|
70
|
+
fullName: null
|
|
66
71
|
},
|
|
67
|
-
emit
|
|
68
|
-
|
|
69
|
-
on: () => ({ emit: () => {
|
|
70
|
-
}, shouldPreventDefault: false, bound: false })
|
|
72
|
+
emit,
|
|
73
|
+
on
|
|
71
74
|
}
|
|
72
75
|
)
|
|
73
76
|
}
|
|
@@ -3,15 +3,20 @@ import { CommandDialog, CommandInput, CommandList, CommandEmpty, CommandGroup, C
|
|
|
3
3
|
import { Button } from './chunk-7KIDDF3I.js';
|
|
4
4
|
import { SearchIcon } from './chunk-T6BRD7TS.js';
|
|
5
5
|
import { Badge } from './chunk-S4JAHKOP.js';
|
|
6
|
+
import { useBoundProp } from '@json-render/react';
|
|
6
7
|
import { useState, useCallback, useMemo } from 'react';
|
|
7
8
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
8
9
|
|
|
9
10
|
var EMPTY_ITEMS = [];
|
|
10
|
-
function CommandPaletteBlock({ props, emit }) {
|
|
11
|
+
function CommandPaletteBlock({ props, bindings, emit }) {
|
|
11
12
|
const items = props.items ?? EMPTY_ITEMS;
|
|
12
13
|
const placeholder = props.placeholder ?? "Search...";
|
|
13
14
|
const [open, setOpen] = useState(false);
|
|
14
|
-
const [
|
|
15
|
+
const [boundQuery, setBoundQuery] = useBoundProp(props.searchValue, bindings?.searchValue);
|
|
16
|
+
const [localQuery, setLocalQuery] = useState("");
|
|
17
|
+
const isBound = !!bindings?.searchValue;
|
|
18
|
+
const query = isBound ? boundQuery ?? "" : localQuery;
|
|
19
|
+
const setQuery = isBound ? setBoundQuery : setLocalQuery;
|
|
15
20
|
const toggle = useCallback(() => setOpen((prev) => !prev), []);
|
|
16
21
|
useHotkey("mod+k", toggle);
|
|
17
22
|
const grouped = useMemo(() => {
|
|
@@ -2,19 +2,19 @@ import { overlayDefinitions } from './chunk-LYI5YMC6.js';
|
|
|
2
2
|
import { textEffectsDefinitions } from './chunk-UXYLA2IV.js';
|
|
3
3
|
import { textDefinitions } from './chunk-YXRIXTXW.js';
|
|
4
4
|
import { chartDefinitions } from './chunk-UQB54LIA.js';
|
|
5
|
-
import { chatDefinitions } from './chunk-
|
|
5
|
+
import { chatDefinitions } from './chunk-E4KUPYHE.js';
|
|
6
6
|
import { displayDefinitions } from './chunk-W4KI424V.js';
|
|
7
7
|
import { effectsDefinitions } from './chunk-7SOMHO2L.js';
|
|
8
8
|
import { formDefinitions } from './chunk-XI775QZZ.js';
|
|
9
9
|
import { layoutDefinitions } from './chunk-P7JS4B7U.js';
|
|
10
10
|
import { navigationDefinitions } from './chunk-QCL76CM6.js';
|
|
11
11
|
import { agentDefinitions } from './chunk-5XDYCBR6.js';
|
|
12
|
-
import { blocksAgentDefinitions } from './chunk-
|
|
13
|
-
import { blocksAuthDefinitions } from './chunk-
|
|
14
|
-
import { blocksContentDefinitions } from './chunk-
|
|
15
|
-
import { blocksCrudDefinitions } from './chunk-
|
|
16
|
-
import { blocksDataDefinitions } from './chunk-
|
|
17
|
-
import { blocksMarketingDefinitions } from './chunk-
|
|
12
|
+
import { blocksAgentDefinitions } from './chunk-ZU7MDRCI.js';
|
|
13
|
+
import { blocksAuthDefinitions } from './chunk-ZL6BPQNN.js';
|
|
14
|
+
import { blocksContentDefinitions } from './chunk-3LROWCZE.js';
|
|
15
|
+
import { blocksCrudDefinitions } from './chunk-IW36SVOH.js';
|
|
16
|
+
import { blocksDataDefinitions } from './chunk-A4QNTJUR.js';
|
|
17
|
+
import { blocksMarketingDefinitions } from './chunk-YEAJLVGB.js';
|
|
18
18
|
import { blocksMiscDefinitions } from './chunk-WAIZR4CR.js';
|
|
19
19
|
import { actionDefinitions } from './chunk-XLIFWBE7.js';
|
|
20
20
|
|
|
@@ -1,41 +1,41 @@
|
|
|
1
|
-
import { primitiveComponents } from './chunk-
|
|
2
|
-
import { InviteUserModal } from './chunk-
|
|
1
|
+
import { primitiveComponents } from './chunk-PQOL3E2V.js';
|
|
2
|
+
import { InviteUserModal } from './chunk-XLN4NVKU.js';
|
|
3
3
|
import { StatsBlock } from './chunk-A4TQNK7R.js';
|
|
4
4
|
import { StatsMarketingBlock } from './chunk-PD6WW7E5.js';
|
|
5
5
|
import { TeamBlock } from './chunk-XMGWLDNG.js';
|
|
6
6
|
import { TestimonialsBlock } from './chunk-PYRHNONA.js';
|
|
7
7
|
import { TimezonePickerBlock } from './chunk-HF2HNDE7.js';
|
|
8
|
-
import { TwoFactorSetupBlock } from './chunk-
|
|
8
|
+
import { TwoFactorSetupBlock } from './chunk-QCFDSOTV.js';
|
|
9
9
|
import { UsageDonutBlock } from './chunk-HZTWLK7C.js';
|
|
10
|
-
import { WizardBlock } from './chunk-
|
|
11
|
-
import { OnboardingFlowBlock } from './chunk-
|
|
12
|
-
import { PasswordRecoveryBlock } from './chunk-
|
|
10
|
+
import { WizardBlock } from './chunk-B4373MDA.js';
|
|
11
|
+
import { OnboardingFlowBlock } from './chunk-33UWVOQ6.js';
|
|
12
|
+
import { PasswordRecoveryBlock } from './chunk-R4SBK6Y5.js';
|
|
13
13
|
import { PricingBlock } from './chunk-PQBVNNEG.js';
|
|
14
14
|
import { ProcessFlowBlock } from './chunk-B4YCI5NM.js';
|
|
15
15
|
import { ROICalculatorBlock } from './chunk-L77KWJJB.js';
|
|
16
|
-
import { ResetPasswordBlock } from './chunk-
|
|
16
|
+
import { ResetPasswordBlock } from './chunk-ZKA5X3E4.js';
|
|
17
17
|
import { SettingsNavBlock } from './chunk-PJ7DVYWA.js';
|
|
18
18
|
import { SolutionShowcaseBlock } from './chunk-HX3VXWNJ.js';
|
|
19
19
|
import { IntegrationsBlock } from './chunk-IYK2ABFE.js';
|
|
20
|
-
import { InteractiveAreaChartBlock } from './chunk-
|
|
20
|
+
import { InteractiveAreaChartBlock } from './chunk-3FJG5MAT.js';
|
|
21
21
|
import { LogoCloud } from './chunk-STNVWBJH.js';
|
|
22
|
-
import { NewsletterBlock } from './chunk-
|
|
22
|
+
import { NewsletterBlock } from './chunk-FSU7ZM5V.js';
|
|
23
23
|
import { NotFoundBlock } from './chunk-4EHXVFQY.js';
|
|
24
|
-
import { OTPBlock } from './chunk-
|
|
25
|
-
import { OnboardingBlock } from './chunk-
|
|
24
|
+
import { OTPBlock } from './chunk-7LYRUSWM.js';
|
|
25
|
+
import { OnboardingBlock } from './chunk-BY6LWOHB.js';
|
|
26
26
|
import { FAQBlock } from './chunk-DSNPOAE6.js';
|
|
27
27
|
import { FeatureBlock } from './chunk-JPA45CDE.js';
|
|
28
28
|
import { FooterBlock } from './chunk-Q4CRHV5T.js';
|
|
29
29
|
import { FormFieldBlock } from './chunk-KANK5FAG.js';
|
|
30
30
|
import { GalleryBlock } from './chunk-6NL36QN3.js';
|
|
31
31
|
import { HeaderBlock } from './chunk-CQ75K2DH.js';
|
|
32
|
-
import { HeroBlock } from './chunk-
|
|
33
|
-
import { CommandPaletteBlock } from './chunk-
|
|
32
|
+
import { HeroBlock } from './chunk-UCFR7GLW.js';
|
|
33
|
+
import { CommandPaletteBlock } from './chunk-UPMSE6PQ.js';
|
|
34
34
|
import { ComparisonBlock } from './chunk-GE4WUAAE.js';
|
|
35
|
-
import { ContactBlock } from './chunk-
|
|
36
|
-
import { CreateBlock } from './chunk-
|
|
37
|
-
import { CrudListBlock } from './chunk-
|
|
38
|
-
import { DashboardBlock } from './chunk-
|
|
35
|
+
import { ContactBlock } from './chunk-H3KTAHJP.js';
|
|
36
|
+
import { CreateBlock } from './chunk-NDQO7AO6.js';
|
|
37
|
+
import { CrudListBlock } from './chunk-AP5SGSN7.js';
|
|
38
|
+
import { DashboardBlock } from './chunk-XUWKGDUY.js';
|
|
39
39
|
import { DataGridBlock } from './chunk-D6MFOI3N.js';
|
|
40
40
|
import { DirectoryBlock } from './chunk-7AUNUDHM.js';
|
|
41
41
|
import { BlogIndexBlock } from './chunk-4ZST7OY5.js';
|
|
@@ -48,23 +48,23 @@ import { ChatLayout } from './chunk-IZ7A62GI.js';
|
|
|
48
48
|
import { CheckEmailBlock } from './chunk-BVXSAVKY.js';
|
|
49
49
|
import { CodeBlock } from './chunk-GVOWGEGX.js';
|
|
50
50
|
import { AgentRunOverviewBlock } from './chunk-KMTLCN6S.js';
|
|
51
|
-
import { AgentWorkbenchBlock } from './chunk-
|
|
52
|
-
import { ApiKeysBlock } from './chunk-
|
|
53
|
-
import { AuthLayout } from './chunk-
|
|
54
|
-
import { LoginBlock } from './chunk-
|
|
51
|
+
import { AgentWorkbenchBlock } from './chunk-U43JTK45.js';
|
|
52
|
+
import { ApiKeysBlock } from './chunk-5RBO2IMZ.js';
|
|
53
|
+
import { AuthLayout } from './chunk-UMEBNHKR.js';
|
|
54
|
+
import { LoginBlock } from './chunk-FX3GYS5O.js';
|
|
55
55
|
import { AuthSuccessBlock } from './chunk-OMGVZWRM.js';
|
|
56
56
|
import { BannerBlock } from './chunk-JVQQQS2M.js';
|
|
57
57
|
import { BenchmarksBlock } from './chunk-DGSNEGJP.js';
|
|
58
58
|
import { BlogDetailBlock } from './chunk-6NND57T2.js';
|
|
59
59
|
import { AccountLockedBlock } from './chunk-7OOO22KB.js';
|
|
60
60
|
import { ActivityFeedBlock } from './chunk-KWIIKHIB.js';
|
|
61
|
-
import { AgentConversationBlock } from './chunk-
|
|
61
|
+
import { AgentConversationBlock } from './chunk-TTDKPZ75.js';
|
|
62
62
|
import { AgentProfileGridBlock } from './chunk-SIXPY62Q.js';
|
|
63
63
|
import { VoiceAgentCard } from './chunk-TL5UCQC3.js';
|
|
64
64
|
import { WorkspaceSwitcherBlock } from './chunk-6OBT3A5O.js';
|
|
65
65
|
import { NavUser } from './chunk-OS2BLQ2G.js';
|
|
66
|
-
import { KanbanItem, KanbanHandle, KanbanColumnHeader, KanbanColumn,
|
|
67
|
-
import { formWizardVariants, FormWizard } from './chunk-
|
|
66
|
+
import { KanbanItem, KanbanHandle, KanbanColumnHeader, KanbanColumn, KanbanBoard } from './chunk-BOWKE7OE.js';
|
|
67
|
+
import { formWizardVariants, FormWizard } from './chunk-U5QLJHYN.js';
|
|
68
68
|
import { CheckoutForm } from './chunk-MOFWXBTK.js';
|
|
69
69
|
|
|
70
70
|
// src/catalog/components.tsx
|
|
@@ -111,7 +111,7 @@ var seedComponents = {
|
|
|
111
111
|
FormFieldBlock,
|
|
112
112
|
IntegrationsBlock,
|
|
113
113
|
InviteUserModal,
|
|
114
|
-
KanbanBoard: { KanbanBoard,
|
|
114
|
+
KanbanBoard: { KanbanBoard, KanbanColumn, KanbanColumnHeader, KanbanHandle, KanbanItem },
|
|
115
115
|
NavUser,
|
|
116
116
|
SettingsNavBlock,
|
|
117
117
|
TeamBlock,
|
|
@@ -8,22 +8,24 @@ import { PlusIcon } from './chunk-E7RBK6ML.js';
|
|
|
8
8
|
import { MailIcon } from './chunk-XQ2UDMPO.js';
|
|
9
9
|
import { CheckIcon } from './chunk-CXACRCZ4.js';
|
|
10
10
|
import * as React from 'react';
|
|
11
|
+
import { useBoundProp } from '@json-render/react';
|
|
11
12
|
import { useForm } from 'react-hook-form';
|
|
12
13
|
import { zodResolver } from '@hookform/resolvers/zod';
|
|
13
14
|
import * as z from 'zod';
|
|
14
|
-
import { jsxs, jsx
|
|
15
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
15
16
|
|
|
16
17
|
var inviteSchema = z.object({
|
|
17
18
|
email: z.string().email({ message: "Please enter a valid email address." }),
|
|
18
19
|
role: z.enum(["admin", "member", "guest"])
|
|
19
20
|
});
|
|
20
21
|
function InviteUserModal({
|
|
22
|
+
props,
|
|
21
23
|
emit,
|
|
22
|
-
|
|
24
|
+
bindings
|
|
23
25
|
}) {
|
|
24
26
|
const [open, setOpen] = React.useState(false);
|
|
25
|
-
const [
|
|
26
|
-
const [
|
|
27
|
+
const [, setBoundEmail] = useBoundProp(props.email, bindings?.email);
|
|
28
|
+
const [, setBoundRole] = useBoundProp(props.role, bindings?.role);
|
|
27
29
|
const {
|
|
28
30
|
register,
|
|
29
31
|
handleSubmit,
|
|
@@ -33,29 +35,16 @@ function InviteUserModal({
|
|
|
33
35
|
} = useForm({
|
|
34
36
|
resolver: zodResolver(inviteSchema),
|
|
35
37
|
defaultValues: {
|
|
36
|
-
role: "member"
|
|
38
|
+
role: props.role ?? "member",
|
|
39
|
+
...props.email ? { email: props.email } : {}
|
|
37
40
|
}
|
|
38
41
|
});
|
|
39
42
|
function onSubmit(values) {
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
return;
|
|
46
|
-
}
|
|
47
|
-
if (typeof result === "object" && result !== null && "success" in result && result.success === false) {
|
|
48
|
-
setSubmitError(result.error ?? "Failed to send invitation.");
|
|
49
|
-
return;
|
|
50
|
-
}
|
|
51
|
-
emit("invite");
|
|
52
|
-
setOpen(false);
|
|
53
|
-
reset();
|
|
54
|
-
emit("invited");
|
|
55
|
-
}).catch(() => {
|
|
56
|
-
setSubmitError("Failed to send invitation.");
|
|
57
|
-
});
|
|
58
|
-
});
|
|
43
|
+
if (bindings?.email) setBoundEmail(values.email);
|
|
44
|
+
if (bindings?.role) setBoundRole(values.role);
|
|
45
|
+
emit("submit");
|
|
46
|
+
setOpen(false);
|
|
47
|
+
reset();
|
|
59
48
|
}
|
|
60
49
|
return /* @__PURE__ */ jsxs(Dialog, { open, onOpenChange: setOpen, children: [
|
|
61
50
|
/* @__PURE__ */ jsx(DialogTrigger, { asChild: true, children: /* @__PURE__ */ jsxs(Button, { variant: "accent", className: "gap-2", children: [
|
|
@@ -122,12 +111,11 @@ function InviteUserModal({
|
|
|
122
111
|
children: "Cancel"
|
|
123
112
|
}
|
|
124
113
|
),
|
|
125
|
-
/* @__PURE__ */
|
|
114
|
+
/* @__PURE__ */ jsxs(Button, { type: "submit", variant: "accent", children: [
|
|
126
115
|
/* @__PURE__ */ jsx(CheckIcon, { size: 16, className: "mr-2" }),
|
|
127
116
|
" Send Invite"
|
|
128
|
-
] })
|
|
129
|
-
] })
|
|
130
|
-
!!submitError && /* @__PURE__ */ jsx("p", { className: "text-xs font-medium text-destructive", children: submitError })
|
|
117
|
+
] })
|
|
118
|
+
] })
|
|
131
119
|
] })
|
|
132
120
|
] })
|
|
133
121
|
] });
|
|
@@ -25,7 +25,7 @@ import dynamic from 'next/dynamic';
|
|
|
25
25
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
26
26
|
|
|
27
27
|
var ProfilePage = dynamic(() => import('./ProfilePage-KJVA3ZQ5.js').then((m) => ({ default: m.ProfilePage })), { ssr: false, loading: () => null });
|
|
28
|
-
var TeamPage = dynamic(() => import('./TeamPage-
|
|
28
|
+
var TeamPage = dynamic(() => import('./TeamPage-UO3V2JDK.js').then((m) => ({ default: m.TeamPage })), { ssr: false, loading: () => null });
|
|
29
29
|
function SettingsContent({ tab }) {
|
|
30
30
|
switch (tab) {
|
|
31
31
|
case "profile":
|
|
@@ -61,11 +61,14 @@ var blocksMarketingDefinitions = {
|
|
|
61
61
|
emailPlaceholder: z.string().nullable(),
|
|
62
62
|
messagePlaceholder: z.string().nullable(),
|
|
63
63
|
successTitle: z.string().nullable(),
|
|
64
|
-
submitLabel: z.string().nullable()
|
|
64
|
+
submitLabel: z.string().nullable(),
|
|
65
|
+
name: z.string().nullable(),
|
|
66
|
+
email: z.string().nullable(),
|
|
67
|
+
message: z.string().nullable()
|
|
65
68
|
}),
|
|
66
69
|
events: ["submit"],
|
|
67
70
|
description: "Contact form with name, email, and message fields. Shows success state after submission.",
|
|
68
|
-
example: { title: "Get in touch", description: null, namePlaceholder: null, emailPlaceholder: null, messagePlaceholder: null, successTitle: null, submitLabel: "Send message" }
|
|
71
|
+
example: { title: "Get in touch", description: null, namePlaceholder: null, emailPlaceholder: null, messagePlaceholder: null, successTitle: null, submitLabel: "Send message", name: null, email: null, message: null }
|
|
69
72
|
},
|
|
70
73
|
FAQBlock: {
|
|
71
74
|
props: z.object({
|
|
@@ -208,11 +211,12 @@ var blocksMarketingDefinitions = {
|
|
|
208
211
|
NewsletterBlock: {
|
|
209
212
|
props: z.object({
|
|
210
213
|
title: z.string().nullable(),
|
|
211
|
-
description: z.string().nullable()
|
|
214
|
+
description: z.string().nullable(),
|
|
215
|
+
email: z.string().nullable()
|
|
212
216
|
}),
|
|
213
217
|
events: ["subscribe"],
|
|
214
218
|
description: "Newsletter signup form with email input and subscribe button.",
|
|
215
|
-
example: { title: "Stay in the loop", description: "Get product updates and engineering insights delivered weekly." }
|
|
219
|
+
example: { title: "Stay in the loop", description: "Get product updates and engineering insights delivered weekly.", email: null }
|
|
216
220
|
},
|
|
217
221
|
SolutionShowcaseBlock: {
|
|
218
222
|
props: z.object({
|
|
@@ -3,7 +3,7 @@ import { Conversation, ConversationContent } from './chunk-KXZP6XI2.js';
|
|
|
3
3
|
import { ChatResponse } from './chunk-4EOX2S37.js';
|
|
4
4
|
import { ChatToolCall, ChatToolCallHeader, ChatToolCallContent } from './chunk-L2IRYY6K.js';
|
|
5
5
|
import { ChatGreeting } from './chunk-MB75U2OV.js';
|
|
6
|
-
import { ChatMessage, ChatMessageContent } from './chunk-
|
|
6
|
+
import { ChatMessage, ChatMessageContent } from './chunk-UAN2YEI5.js';
|
|
7
7
|
import { ChatPromptInput, ChatPromptInputTextarea, ChatPromptInputActions, ChatPromptInputSubmit } from './chunk-SEJXMNMK.js';
|
|
8
8
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
9
9
|
|
|
@@ -8,6 +8,7 @@ import { KeyIcon } from './chunk-QSU23VYZ.js';
|
|
|
8
8
|
import { CheckIcon } from './chunk-CXACRCZ4.js';
|
|
9
9
|
import { XIcon } from './chunk-UIUMTURU.js';
|
|
10
10
|
import * as React from 'react';
|
|
11
|
+
import { useBoundProp } from '@json-render/react';
|
|
11
12
|
import { useTranslations } from 'next-intl';
|
|
12
13
|
import { useReducedMotion } from 'motion/react';
|
|
13
14
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
@@ -18,11 +19,19 @@ var RULE_TESTS = [
|
|
|
18
19
|
{ key: "number", test: (v) => /\d/.test(v) },
|
|
19
20
|
{ key: "special", test: (v) => /[^A-Za-z0-9]/.test(v) }
|
|
20
21
|
];
|
|
21
|
-
function ResetPasswordBlock({ props, emit }) {
|
|
22
|
+
function ResetPasswordBlock({ props, bindings, emit }) {
|
|
22
23
|
const prefersReduced = useReducedMotion();
|
|
23
24
|
const t = useTranslations("auth.reset");
|
|
24
|
-
const [
|
|
25
|
-
const [
|
|
25
|
+
const [boundPassword, setBoundPassword] = useBoundProp(props.password, bindings?.password);
|
|
26
|
+
const [localPassword, setLocalPassword] = React.useState("");
|
|
27
|
+
const isPasswordBound = !!bindings?.password;
|
|
28
|
+
const password = isPasswordBound ? boundPassword ?? "" : localPassword;
|
|
29
|
+
const setPassword = isPasswordBound ? setBoundPassword : setLocalPassword;
|
|
30
|
+
const [boundConfirm, setBoundConfirm] = useBoundProp(props.confirmPassword, bindings?.confirmPassword);
|
|
31
|
+
const [localConfirm, setLocalConfirm] = React.useState("");
|
|
32
|
+
const isConfirmBound = !!bindings?.confirmPassword;
|
|
33
|
+
const confirm = isConfirmBound ? boundConfirm ?? "" : localConfirm;
|
|
34
|
+
const setConfirm = isConfirmBound ? setBoundConfirm : setLocalConfirm;
|
|
26
35
|
const [loading, setLoading] = React.useState(false);
|
|
27
36
|
const [error, setError] = React.useState("");
|
|
28
37
|
const resolvedTitle = props.title ?? t("title");
|
|
@@ -66,11 +66,14 @@ var blocksAuthDefinitions = {
|
|
|
66
66
|
error: z.string().nullable(),
|
|
67
67
|
forgotPasswordHref: z.string().nullable(),
|
|
68
68
|
signUpHref: z.string().nullable(),
|
|
69
|
-
signInHref: z.string().nullable()
|
|
69
|
+
signInHref: z.string().nullable(),
|
|
70
|
+
email: z.string().nullable(),
|
|
71
|
+
password: z.string().nullable(),
|
|
72
|
+
fullName: z.string().nullable()
|
|
70
73
|
}),
|
|
71
74
|
events: ["submit", "socialLogin"],
|
|
72
75
|
description: "Authentication login form with email/password fields and optional social login buttons.",
|
|
73
|
-
example: { type: "login", showSocial: true, error: null, forgotPasswordHref: "/reset-password", signUpHref: null, signInHref: null }
|
|
76
|
+
example: { type: "login", showSocial: true, error: null, forgotPasswordHref: "/reset-password", signUpHref: null, signInHref: null, email: null, password: null, fullName: null }
|
|
74
77
|
},
|
|
75
78
|
OTPBlock: {
|
|
76
79
|
props: z.object({
|
|
@@ -79,11 +82,12 @@ var blocksAuthDefinitions = {
|
|
|
79
82
|
maxLength: z.number().nullable(),
|
|
80
83
|
buttonText: z.string().nullable(),
|
|
81
84
|
error: z.string().nullable(),
|
|
82
|
-
backupCodeLink: z.string().nullable()
|
|
85
|
+
backupCodeLink: z.string().nullable(),
|
|
86
|
+
value: z.string().nullable()
|
|
83
87
|
}),
|
|
84
88
|
events: ["verify", "useBackupCode", "backToLogin"],
|
|
85
89
|
description: "OTP verification card with configurable code length, title, verify callback, optional error shake, and optional backup code link.",
|
|
86
|
-
example: { title: "Two-Factor Authentication", description: "Enter the 6-digit code from your authenticator app.", maxLength: 6, buttonText: "Verify", error: null, backupCodeLink: "/auth/backup-codes" }
|
|
90
|
+
example: { title: "Two-Factor Authentication", description: "Enter the 6-digit code from your authenticator app.", maxLength: 6, buttonText: "Verify", error: null, backupCodeLink: "/auth/backup-codes", value: null }
|
|
87
91
|
},
|
|
88
92
|
PasswordRecoveryBlock: {
|
|
89
93
|
props: z.object({
|
|
@@ -91,20 +95,23 @@ var blocksAuthDefinitions = {
|
|
|
91
95
|
title: z.string().nullable(),
|
|
92
96
|
description: z.string().nullable(),
|
|
93
97
|
buttonText: z.string().nullable(),
|
|
94
|
-
successTitle: z.string().nullable()
|
|
98
|
+
successTitle: z.string().nullable(),
|
|
99
|
+
email: z.string().nullable()
|
|
95
100
|
}),
|
|
96
101
|
events: ["submit", "backToLogin"],
|
|
97
102
|
description: "Password recovery form with email input. Supports reset and magic-link modes.",
|
|
98
|
-
example: { mode: "reset", title: "Forgot your password?", description: "Enter your email and we will send a reset link.", buttonText: "Send Reset Link", successTitle: "Check your inbox" }
|
|
103
|
+
example: { mode: "reset", title: "Forgot your password?", description: "Enter your email and we will send a reset link.", buttonText: "Send Reset Link", successTitle: "Check your inbox", email: null }
|
|
99
104
|
},
|
|
100
105
|
ResetPasswordBlock: {
|
|
101
106
|
props: z.object({
|
|
102
107
|
title: z.string().nullable(),
|
|
103
|
-
description: z.string().nullable()
|
|
108
|
+
description: z.string().nullable(),
|
|
109
|
+
password: z.string().nullable(),
|
|
110
|
+
confirmPassword: z.string().nullable()
|
|
104
111
|
}),
|
|
105
112
|
events: ["submit", "backToLogin"],
|
|
106
113
|
description: "New password form with password confirmation. Shown after recovery link click.",
|
|
107
|
-
example: { title: "Set New Password", description: "Choose a strong password for your account." }
|
|
114
|
+
example: { title: "Set New Password", description: "Choose a strong password for your account.", password: null, confirmPassword: null }
|
|
108
115
|
},
|
|
109
116
|
TwoFactorSetupBlock: {
|
|
110
117
|
props: z.object({
|
|
@@ -112,7 +119,8 @@ var blocksAuthDefinitions = {
|
|
|
112
119
|
secret: z.string().nullable(),
|
|
113
120
|
backupCodes: z.array(z.string()).nullable(),
|
|
114
121
|
title: z.string().nullable(),
|
|
115
|
-
description: z.string().nullable()
|
|
122
|
+
description: z.string().nullable(),
|
|
123
|
+
verifyCode: z.string().nullable()
|
|
116
124
|
}),
|
|
117
125
|
events: ["verify", "complete"],
|
|
118
126
|
description: "Two-factor setup wizard with QR code, secret key display, backup codes, and verification.",
|
|
@@ -121,7 +129,8 @@ var blocksAuthDefinitions = {
|
|
|
121
129
|
secret: "JBSWY3DPEHPK3PXP",
|
|
122
130
|
backupCodes: ["a1b2c3d4", "e5f6g7h8", "i9j0k1l2"],
|
|
123
131
|
title: "Enable Two-Factor Authentication",
|
|
124
|
-
description: "Scan the QR code with your authenticator app."
|
|
132
|
+
description: "Scan the QR code with your authenticator app.",
|
|
133
|
+
verifyCode: null
|
|
125
134
|
}
|
|
126
135
|
}
|
|
127
136
|
};
|
|
@@ -149,7 +149,7 @@ var blocksAgentDefinitions = {
|
|
|
149
149
|
messages: z.array(
|
|
150
150
|
z.object({
|
|
151
151
|
id: z.string(),
|
|
152
|
-
role: z.enum(["user", "assistant", "
|
|
152
|
+
role: z.enum(["user", "assistant", "system"]),
|
|
153
153
|
content: z.string(),
|
|
154
154
|
timestamp: z.string().nullable(),
|
|
155
155
|
isThinking: z.boolean().nullable(),
|