@kumix/ui 0.4.4 → 0.5.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 (89) hide show
  1. package/README.md +14 -12
  2. package/dist/components/agents/approval-card/index.js +0 -1
  3. package/dist/components/agents/approval-card/index.js.map +1 -1
  4. package/dist/components/agents/prompt-input.js +0 -1
  5. package/dist/components/agents/prompt-input.js.map +1 -1
  6. package/dist/components/charts/bar-chart/context.d.ts.map +1 -1
  7. package/dist/components/charts/line-chart/context.d.ts.map +1 -1
  8. package/dist/components/charts/returns-calendar.d.ts.map +1 -1
  9. package/dist/components/charts/treemap.d.ts.map +1 -1
  10. package/dist/components/motion/bouncy-accordion.d.ts.map +1 -1
  11. package/dist/components/motion/bouncy-accordion.js +20 -34
  12. package/dist/components/motion/bouncy-accordion.js.map +1 -1
  13. package/dist/components/motion/crash/crash-balloon.d.ts +9 -0
  14. package/dist/components/motion/crash/crash-balloon.d.ts.map +1 -0
  15. package/dist/components/motion/crash/crash-balloon.js +829 -0
  16. package/dist/components/motion/crash/crash-balloon.js.map +1 -0
  17. package/dist/components/motion/crash/crash-parts.d.ts +59 -0
  18. package/dist/components/motion/crash/crash-parts.d.ts.map +1 -0
  19. package/dist/components/motion/crash/crash-parts.js +2 -0
  20. package/dist/components/motion/crash/crash-tower.d.ts +9 -0
  21. package/dist/components/motion/crash/crash-tower.d.ts.map +1 -0
  22. package/dist/components/motion/crash/crash-tower.js +370 -0
  23. package/dist/components/motion/crash/crash-tower.js.map +1 -0
  24. package/dist/components/motion/crash.d.ts +9 -0
  25. package/dist/components/motion/crash.d.ts.map +1 -0
  26. package/dist/components/motion/crash.js +590 -0
  27. package/dist/components/motion/crash.js.map +1 -0
  28. package/dist/components/motion/feedback-widget.js +0 -1
  29. package/dist/components/motion/feedback-widget.js.map +1 -1
  30. package/dist/components/motion/liquid.js +2 -2
  31. package/dist/components/motion/liquid.js.map +1 -1
  32. package/dist/components/motion/mines.d.ts +41 -0
  33. package/dist/components/motion/mines.d.ts.map +1 -0
  34. package/dist/components/motion/mines.js +762 -0
  35. package/dist/components/motion/mines.js.map +1 -0
  36. package/dist/components/motion/plinko.d.ts +59 -0
  37. package/dist/components/motion/plinko.d.ts.map +1 -0
  38. package/dist/components/motion/plinko.js +385 -0
  39. package/dist/components/motion/plinko.js.map +1 -0
  40. package/dist/components/motion/signup-form.js +0 -1
  41. package/dist/components/motion/signup-form.js.map +1 -1
  42. package/dist/components/motion/swap.d.ts +1 -1
  43. package/dist/components/motion/tooltip.d.ts +2 -2
  44. package/dist/components/motion/tooltip.d.ts.map +1 -1
  45. package/dist/components/motion/wallet-card/index.js +0 -1
  46. package/dist/components/motion/wallet-card/index.js.map +1 -1
  47. package/dist/components/reui/alert.d.ts +1 -1
  48. package/dist/components/reui/badge.d.ts +1 -1
  49. package/dist/components/reui/code-block/code-block.d.ts +1 -0
  50. package/dist/components/reui/code-block/code-block.d.ts.map +1 -1
  51. package/dist/components/reui/data-grid/data-grid-table.d.ts +1 -1
  52. package/dist/components/reui/data-grid/data-grid-table.d.ts.map +1 -1
  53. package/dist/components/reui/frame.d.ts +1 -1
  54. package/dist/components/reui/icon-tile.d.ts +1 -1
  55. package/dist/components/reui/tree.d.ts +1 -0
  56. package/dist/components/reui/tree.d.ts.map +1 -1
  57. package/dist/components/ui/badge.d.ts +1 -1
  58. package/dist/components/ui/bubble.d.ts +1 -1
  59. package/dist/components/ui/button.d.ts +2 -2
  60. package/dist/components/ui/empty.d.ts +1 -1
  61. package/dist/components/ui/item.d.ts +1 -1
  62. package/dist/components/ui/marker.d.ts +1 -1
  63. package/dist/components/ui/tabs.d.ts +1 -1
  64. package/dist/crash-parts-CUv5gFYQ.js +1053 -0
  65. package/dist/crash-parts-CUv5gFYQ.js.map +1 -0
  66. package/dist/{ease-CHhXKlG3.d.ts → ease-DjhlGGZO.d.ts} +4 -2
  67. package/dist/ease-DjhlGGZO.d.ts.map +1 -0
  68. package/dist/hooks/use-highlighted-code.d.ts +1 -1
  69. package/dist/hooks/use-highlighted-code.d.ts.map +1 -1
  70. package/dist/lib/audio-context.d.ts +11 -0
  71. package/dist/lib/audio-context.d.ts.map +1 -0
  72. package/dist/lib/audio-context.js +37 -0
  73. package/dist/lib/audio-context.js.map +1 -0
  74. package/dist/lib/ease.d.ts +2 -2
  75. package/dist/lib/ease.js +8 -1
  76. package/dist/lib/ease.js.map +1 -1
  77. package/dist/lib/game-sounds.d.ts +18 -0
  78. package/dist/lib/game-sounds.d.ts.map +1 -0
  79. package/dist/lib/game-sounds.js +142 -0
  80. package/dist/lib/game-sounds.js.map +1 -0
  81. package/dist/lib/tick-sound.d.ts +4 -3
  82. package/dist/lib/tick-sound.d.ts.map +1 -1
  83. package/dist/lib/tick-sound.js +30 -37
  84. package/dist/lib/tick-sound.js.map +1 -1
  85. package/dist/tooltip-CNEYdIX3.d.ts.map +1 -1
  86. package/dist/use-crash-game-B3RHxFkm.d.ts +108 -0
  87. package/dist/use-crash-game-B3RHxFkm.d.ts.map +1 -0
  88. package/package.json +7 -7
  89. package/dist/ease-CHhXKlG3.d.ts.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"signup-form.js","names":[],"sources":["../../../src/components/motion/signup-form.tsx"],"sourcesContent":["\"use client\";\n\nimport { type FormEvent, type ReactNode, useCallback, useId, useMemo, useState } from \"react\";\nimport { Eye, EyeOff, Lock, Mail, User } from \"lucide-react\";\nimport { AnimatePresence, motion, useReducedMotion } from \"motion/react\";\n\nimport { cn } from \"@kumix/utils\";\nimport { EASE_OUT, SPRING_LAYOUT } from \"../../lib/ease\";\nimport { StatefulButton } from \"./button\";\nimport { Checkbox } from \"./checkbox\";\nimport { Input } from \"./input\";\n\nexport type SignUpStatus = \"idle\" | \"loading\" | \"success\" | \"error\";\n\nexport type SignUpValues = {\n name: string;\n email: string;\n password: string;\n confirmPassword: string;\n terms: boolean;\n};\n\nexport type SignUpErrors = Partial<Record<keyof SignUpValues, string>>;\n\nexport type SignUpFormClassNames = {\n root?: string;\n header?: string;\n title?: string;\n description?: string;\n fields?: string;\n strength?: string;\n terms?: string;\n submit?: string;\n footer?: string;\n};\n\nexport interface SignUpFormProps {\n /** Controlled values. Omit for uncontrolled. */\n values?: SignUpValues;\n defaultValues?: Partial<SignUpValues>;\n onValuesChange?: (values: SignUpValues) => void;\n /** Called with valid values only. Return a promise to drive the button state. */\n onSubmit?: (values: SignUpValues) => void | Promise<void>;\n /** Replace the built-in rules — return a message per invalid field. */\n validate?: (values: SignUpValues) => SignUpErrors;\n /** Controlled submit state. Omit to let the form track it. */\n status?: SignUpStatus;\n /** Form-level failure message, shown above the submit button. */\n errorMessage?: string;\n title?: ReactNode;\n description?: ReactNode;\n submitLabel?: string;\n footer?: ReactNode;\n /** Show the password strength meter. */\n strengthMeter?: boolean;\n className?: string;\n classNames?: SignUpFormClassNames;\n}\n\nconst EMPTY_VALUES: SignUpValues = {\n name: \"\",\n email: \"\",\n password: \"\",\n confirmPassword: \"\",\n terms: false,\n};\n\n// Deliberately permissive. Full RFC 5322 matching is impractical in a regex and\n// rejects addresses that deliver fine; the only real check is sending mail.\nconst EMAIL_PATTERN = /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/;\n\nconst MIN_PASSWORD_LENGTH = 8;\n\nconst STRENGTH_LABELS = [\"Too short\", \"Weak\", \"Fair\", \"Good\", \"Strong\"] as const;\n\nconst STRENGTH_COLORS = [\n \"bg-destructive\",\n \"bg-destructive\",\n \"bg-amber-500\",\n \"bg-amber-400\",\n \"bg-(--color-success)\",\n] as const;\n\n/**\n * Length-weighted strength score, 0-4. NIST SP 800-63B advises against\n * composition requirements and treats length as the dominant factor, so extra\n * character classes only nudge the score — they can't rescue a short password.\n * This is a heuristic for feedback, not entropy estimation; pair it with a\n * breach-list check server-side for anything real.\n */\nexport function passwordStrength(password: string): number {\n if (password.length < MIN_PASSWORD_LENGTH) return 0;\n\n let score = 1;\n if (password.length >= 12) score += 1;\n if (password.length >= 16) score += 1;\n\n const classes = [/[a-z]/, /[A-Z]/, /\\d/, /[^A-Za-z0-9]/].filter((pattern) =>\n pattern.test(password),\n ).length;\n if (classes >= 3) score += 1;\n\n return Math.min(score, 4);\n}\n\nfunction defaultValidate(values: SignUpValues): SignUpErrors {\n const errors: SignUpErrors = {};\n\n if (!values.name.trim()) {\n errors.name = \"Enter your name.\";\n }\n\n if (!values.email.trim()) {\n errors.email = \"Enter your email.\";\n } else if (!EMAIL_PATTERN.test(values.email)) {\n errors.email = \"That doesn't look like an email address.\";\n }\n\n if (!values.password) {\n errors.password = \"Choose a password.\";\n } else if (values.password.length < MIN_PASSWORD_LENGTH) {\n errors.password = `Use at least ${MIN_PASSWORD_LENGTH} characters.`;\n }\n\n if (!values.confirmPassword) {\n errors.confirmPassword = \"Confirm your password.\";\n } else if (values.confirmPassword !== values.password) {\n errors.confirmPassword = \"Passwords don't match.\";\n }\n\n if (!values.terms) {\n errors.terms = \"Accept the terms to continue.\";\n }\n\n return errors;\n}\n\nexport function SignUpForm({\n values: valuesProp,\n defaultValues,\n onValuesChange,\n onSubmit,\n validate,\n status: statusProp,\n errorMessage,\n title = \"Create your account\",\n description = \"Start building in under a minute.\",\n submitLabel = \"Create account\",\n footer,\n strengthMeter = true,\n className,\n classNames,\n}: SignUpFormProps) {\n const reduce = useReducedMotion();\n const baseId = useId();\n\n const controlled = valuesProp !== undefined;\n const [internalValues, setInternalValues] = useState<SignUpValues>({\n ...EMPTY_VALUES,\n ...defaultValues,\n });\n const values = controlled ? valuesProp : internalValues;\n\n const [internalStatus, setInternalStatus] = useState<SignUpStatus>(\"idle\");\n const status = statusProp ?? internalStatus;\n\n const [revealPassword, setRevealPassword] = useState(false);\n\n // \"Reward early, punish late\": errors are computed on every change, but a\n // field only *shows* its error once it has been blurred (or submit touched\n // everything). So a first entry is never flagged mid-typing, while a field\n // already in error clears the moment it becomes valid.\n const [touched, setTouched] = useState<Partial<Record<keyof SignUpValues, boolean>>>({});\n\n const errors = useMemo(() => (validate ?? defaultValidate)(values), [values, validate]);\n\n const setValue = useCallback(\n <K extends keyof SignUpValues>(key: K, next: SignUpValues[K]) => {\n const nextValues = { ...values, [key]: next };\n if (!controlled) {\n setInternalValues(nextValues);\n if (statusProp === undefined) {\n setInternalStatus((current) =>\n current === \"success\" || current === \"error\" ? \"idle\" : current,\n );\n }\n }\n onValuesChange?.(nextValues);\n },\n [controlled, onValuesChange, statusProp, values],\n );\n\n const touch = useCallback((key: keyof SignUpValues) => {\n setTouched((prev) => (prev[key] ? prev : { ...prev, [key]: true }));\n }, []);\n\n /** Error to render for a field — hidden until the field has been touched. */\n const shownError = (key: keyof SignUpValues) => (touched[key] ? errors[key] : undefined);\n\n /** Success check draws only once a touched field is non-empty and valid. */\n const isValid = (key: keyof SignUpValues) =>\n Boolean(touched[key]) && !errors[key] && Boolean(values[key]);\n\n const strength = passwordStrength(values.password);\n const showStrength = strengthMeter && values.password.length > 0;\n const isSubmitting = status === \"loading\";\n\n const handleSubmit = async (event: FormEvent<HTMLFormElement>) => {\n event.preventDefault();\n\n setTouched({\n name: true,\n email: true,\n password: true,\n confirmPassword: true,\n terms: true,\n });\n\n if (Object.keys(errors).length > 0) return;\n if (!onSubmit) return;\n\n if (statusProp === undefined) setInternalStatus(\"loading\");\n try {\n await onSubmit(values);\n if (statusProp === undefined) setInternalStatus(\"success\");\n } catch {\n if (statusProp === undefined) setInternalStatus(\"error\");\n }\n };\n\n const termsErrorId = `${baseId}-terms-error`;\n const formErrorId = `${baseId}-form-error`;\n\n return (\n <form\n noValidate\n onSubmit={handleSubmit}\n className={cn(\n \"border-border flex w-full max-w-sm flex-col gap-5 rounded-3xl border p-6\",\n className,\n classNames?.root,\n )}\n >\n {title || description ? (\n <div className={cn(\"flex flex-col gap-1\", classNames?.header)}>\n {title ? (\n <h2\n className={cn(\n \"text-foreground text-xl font-semibold tracking-tight\",\n classNames?.title,\n )}\n >\n {title}\n </h2>\n ) : null}\n {description ? (\n <p className={cn(\"text-muted-foreground text-sm\", classNames?.description)}>\n {description}\n </p>\n ) : null}\n </div>\n ) : null}\n\n <div className={cn(\"flex flex-col gap-1\", classNames?.fields)}>\n <Input\n label=\"Name\"\n autoComplete=\"name\"\n placeholder=\"Ada Lovelace\"\n leftIcon={<User />}\n disabled={isSubmitting}\n value={values.name}\n onChange={(next) => setValue(\"name\", next)}\n onBlur={() => touch(\"name\")}\n error={shownError(\"name\")}\n reserveErrorLine\n success={isValid(\"name\")}\n />\n\n <Input\n label=\"Email\"\n type=\"email\"\n inputMode=\"email\"\n autoComplete=\"email\"\n placeholder=\"you@example.com\"\n leftIcon={<Mail />}\n disabled={isSubmitting}\n value={values.email}\n onChange={(next) => setValue(\"email\", next)}\n onBlur={() => touch(\"email\")}\n error={shownError(\"email\")}\n reserveErrorLine\n success={isValid(\"email\")}\n />\n\n <div className=\"flex flex-col gap-2\">\n <Input\n label=\"Password\"\n type={revealPassword ? \"text\" : \"password\"}\n autoComplete=\"new-password\"\n placeholder=\"At least 8 characters\"\n leftIcon={<Lock />}\n rightIcon={\n <button\n type=\"button\"\n disabled={isSubmitting}\n onClick={() => setRevealPassword((prev) => !prev)}\n aria-label={revealPassword ? \"Hide password\" : \"Show password\"}\n className=\"text-muted-foreground hover:text-foreground focus-visible:text-foreground transition-colors outline-none\"\n >\n {revealPassword ? <EyeOff /> : <Eye />}\n </button>\n }\n disabled={isSubmitting}\n value={values.password}\n onChange={(next) => setValue(\"password\", next)}\n onBlur={() => touch(\"password\")}\n error={shownError(\"password\")}\n reserveErrorLine\n />\n\n <AnimatePresence initial={false}>\n {showStrength ? (\n <motion.div\n initial={reduce ? { opacity: 0 } : { opacity: 0, y: -4 }}\n animate={{ opacity: 1, y: 0 }}\n exit={reduce ? { opacity: 0 } : { opacity: 0, y: -4 }}\n transition={{ duration: 0.18, ease: EASE_OUT }}\n className={cn(\"flex flex-col gap-1.5 px-1\", classNames?.strength)}\n >\n <div className=\"flex gap-1.5\" aria-hidden>\n {[0, 1, 2, 3].map((index) => (\n <span\n key={index}\n className=\"bg-muted-foreground/20 h-1 flex-1 overflow-hidden rounded-full\"\n >\n {/* scaleX rather than width — transforms only, per the\n motion conventions, and it keeps the bar off layout. */}\n <motion.span\n initial={false}\n animate={{ scaleX: index < strength ? 1 : 0 }}\n transition={reduce ? { duration: 0 } : SPRING_LAYOUT}\n className={cn(\n \"block h-full w-full origin-left rounded-full\",\n STRENGTH_COLORS[strength],\n )}\n />\n </span>\n ))}\n </div>\n <p aria-live=\"polite\" className=\"text-muted-foreground text-xs\">\n Password strength: {STRENGTH_LABELS[strength]}\n </p>\n </motion.div>\n ) : null}\n </AnimatePresence>\n </div>\n\n <Input\n label=\"Confirm password\"\n type={revealPassword ? \"text\" : \"password\"}\n autoComplete=\"new-password\"\n placeholder=\"Re-enter your password\"\n leftIcon={<Lock />}\n disabled={isSubmitting}\n value={values.confirmPassword}\n onChange={(next) => setValue(\"confirmPassword\", next)}\n onBlur={() => touch(\"confirmPassword\")}\n error={shownError(\"confirmPassword\")}\n reserveErrorLine\n success={isValid(\"confirmPassword\")}\n />\n </div>\n\n <div className={cn(\"flex flex-col gap-1.5\", classNames?.terms)}>\n <Checkbox\n checked={values.terms}\n disabled={isSubmitting}\n onCheckedChange={(next) => {\n setValue(\"terms\", next);\n touch(\"terms\");\n }}\n label=\"I agree to the Terms and Privacy Policy\"\n aria-describedby={shownError(\"terms\") ? termsErrorId : undefined}\n />\n <AnimatePresence initial={false}>\n {shownError(\"terms\") ? (\n <motion.p\n id={termsErrorId}\n role=\"alert\"\n initial={reduce ? { opacity: 0 } : { opacity: 0, y: -4, filter: \"blur(4px)\" }}\n animate={{ opacity: 1, y: 0, filter: \"blur(0px)\" }}\n exit={reduce ? { opacity: 0 } : { opacity: 0, y: -4, filter: \"blur(4px)\" }}\n transition={{ duration: 0.2 }}\n className=\"text-destructive px-1 text-xs\"\n >\n {shownError(\"terms\")}\n </motion.p>\n ) : null}\n </AnimatePresence>\n </div>\n\n <AnimatePresence initial={false}>\n {errorMessage ? (\n <motion.p\n id={formErrorId}\n role=\"alert\"\n initial={reduce ? { opacity: 0 } : { opacity: 0, y: -4 }}\n animate={{ opacity: 1, y: 0 }}\n exit={reduce ? { opacity: 0 } : { opacity: 0, y: -4 }}\n transition={{ duration: 0.2 }}\n className=\"border-destructive/30 bg-destructive/10 text-destructive rounded-2xl border px-3 py-2 text-xs\"\n >\n {errorMessage}\n </motion.p>\n ) : null}\n </AnimatePresence>\n\n <StatefulButton\n type=\"submit\"\n size=\"lg\"\n state={status}\n loadingText=\"Creating account\"\n successText=\"Account created\"\n errorText=\"Try again\"\n aria-describedby={errorMessage ? formErrorId : undefined}\n className={cn(\"w-full\", classNames?.submit)}\n >\n {submitLabel}\n </StatefulButton>\n\n {footer ? (\n <div className={cn(\"text-muted-foreground text-center text-sm\", classNames?.footer)}>\n {footer}\n </div>\n ) : null}\n </form>\n );\n}\n"],"mappings":";;;;;;;;;;;;AA2DA,MAAM,eAA6B;CACjC,MAAM;CACN,OAAO;CACP,UAAU;CACV,iBAAiB;CACjB,OAAO;AACT;AAIA,MAAM,gBAAgB;AAEtB,MAAM,sBAAsB;AAE5B,MAAM,kBAAkB;CAAC;CAAa;CAAQ;CAAQ;CAAQ;AAAQ;AAEtE,MAAM,kBAAkB;CACtB;CACA;CACA;CACA;CACA;AACF;;;;;;;;AASA,SAAgB,iBAAiB,UAA0B;CACzD,IAAI,SAAS,SAAS,qBAAqB,OAAO;CAElD,IAAI,QAAQ;CACZ,IAAI,SAAS,UAAU,IAAI,SAAS;CACpC,IAAI,SAAS,UAAU,IAAI,SAAS;CAKpC,IAHgB;EAAC;EAAS;EAAS;EAAM;CAAc,CAAC,CAAC,QAAQ,YAC/D,QAAQ,KAAK,QAAQ,CACvB,CAAC,CAAC,UACa,GAAG,SAAS;CAE3B,OAAO,KAAK,IAAI,OAAO,CAAC;AAC1B;AAEA,SAAS,gBAAgB,QAAoC;CAC3D,MAAM,SAAuB,CAAC;CAE9B,IAAI,CAAC,OAAO,KAAK,KAAK,GAC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KACN,oBAAkB,WAAW,OAAO,IAAI,eAAe,KAAA;IACxD,CAAA,GACD,oBAAC,iBAAD;KAAiB,SAAS;KACvB,UAAA,WAAW,OAAO,IACjB,oBAAC,OAAO,GAAR;MACE,IAAI;MACJ,MAAK;MACL,SAAS,SAAS,EAAE,SAAS,EAAE,IAAI;OAAE,SAAS;OAAG,GAAG;OAAI,QAAQ;MAAY;MAC5E,SAAS;OAAE,SAAS;OAAG,GAAG;OAAG,QAAQ;MAAY;MACjD,MAAM,SAAS,EAAE,SAAS,EAAE,IAAI;OAAE,SAAS;OAAG,GAAG;OAAI,QAAQ;MAAY;MACzE,YAAY,EAAE,UAAU,GAAI;MAC5B,WAAU;MAET,UAAA,WAAW,OAAO;KACX,CAAA,IACR;IACW,CAAA,CACd;;GAEL,oBAAC,iBAAD;IAAiB,SAAS;IACvB,UAAA,eACC,oBAAC,OAAO,GAAR;KACE,IAAI;KACJ,MAAK;KACL,SAAS,SAAS,EAAE,SAAS,EAAE,IAAI;MAAE,SAAS;MAAG,GAAG;KAAG;KACvD,SAAS;MAAE,SAAS;MAAG,GAAG;KAAE;KAC5B,MAAM,SAAS,EAAE,SAAS,EAAE,IAAI;MAAE,SAAS;MAAG,GAAG;KAAG;KACpD,YAAY,EAAE,UAAU,GAAI;KAC5B,WAAU;KAET,UAAA;IACO,CAAA,IACR;GACW,CAAA;GAEjB,oBAAC,gBAAD;IACE,MAAK;IACL,MAAK;IACL,OAAO;IACP,aAAY;IACZ,aAAY;IACZ,WAAU;IACV,oBAAkB,eAAe,cAAc,KAAA;IAC/C,WAAW,GAAG,UAAU,YAAY,MAAM;IAEzC,UAAA;GACa,CAAA;GAEf,SACC,oBAAC,OAAD;IAAK,WAAW,GAAG,6CAA6C,YAAY,MAAM;IAC/E,UAAA;GACE,CAAA,IACH;EACA;;AAEV"}
1
+ {"version":3,"file":"signup-form.js","names":[],"sources":["../../../src/components/motion/signup-form.tsx"],"sourcesContent":["\"use client\";\n\nimport { type FormEvent, type ReactNode, useCallback, useId, useMemo, useState } from \"react\";\nimport { Eye, EyeOff, Lock, Mail, User } from \"lucide-react\";\nimport { AnimatePresence, motion, useReducedMotion } from \"motion/react\";\n\nimport { cn } from \"@kumix/utils\";\nimport { EASE_OUT, SPRING_LAYOUT } from \"../../lib/ease\";\nimport { StatefulButton } from \"./button\";\nimport { Checkbox } from \"./checkbox\";\nimport { Input } from \"./input\";\n\nexport type SignUpStatus = \"idle\" | \"loading\" | \"success\" | \"error\";\n\nexport type SignUpValues = {\n name: string;\n email: string;\n password: string;\n confirmPassword: string;\n terms: boolean;\n};\n\nexport type SignUpErrors = Partial<Record<keyof SignUpValues, string>>;\n\nexport type SignUpFormClassNames = {\n root?: string;\n header?: string;\n title?: string;\n description?: string;\n fields?: string;\n strength?: string;\n terms?: string;\n submit?: string;\n footer?: string;\n};\n\nexport interface SignUpFormProps {\n /** Controlled values. Omit for uncontrolled. */\n values?: SignUpValues;\n defaultValues?: Partial<SignUpValues>;\n onValuesChange?: (values: SignUpValues) => void;\n /** Called with valid values only. Return a promise to drive the button state. */\n onSubmit?: (values: SignUpValues) => void | Promise<void>;\n /** Replace the built-in rules — return a message per invalid field. */\n validate?: (values: SignUpValues) => SignUpErrors;\n /** Controlled submit state. Omit to let the form track it. */\n status?: SignUpStatus;\n /** Form-level failure message, shown above the submit button. */\n errorMessage?: string;\n title?: ReactNode;\n description?: ReactNode;\n submitLabel?: string;\n footer?: ReactNode;\n /** Show the password strength meter. */\n strengthMeter?: boolean;\n className?: string;\n classNames?: SignUpFormClassNames;\n}\n\nconst EMPTY_VALUES: SignUpValues = {\n name: \"\",\n email: \"\",\n password: \"\",\n confirmPassword: \"\",\n terms: false,\n};\n\n// Deliberately permissive. Full RFC 5322 matching is impractical in a regex and\n// rejects addresses that deliver fine; the only real check is sending mail.\nconst EMAIL_PATTERN = /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/;\n\nconst MIN_PASSWORD_LENGTH = 8;\n\nconst STRENGTH_LABELS = [\"Too short\", \"Weak\", \"Fair\", \"Good\", \"Strong\"] as const;\n\nconst STRENGTH_COLORS = [\n \"bg-destructive\",\n \"bg-destructive\",\n \"bg-amber-500\",\n \"bg-amber-400\",\n \"bg-(--color-success)\",\n] as const;\n\n/**\n * Length-weighted strength score, 0-4. NIST SP 800-63B advises against\n * composition requirements and treats length as the dominant factor, so extra\n * character classes only nudge the score — they can't rescue a short password.\n * This is a heuristic for feedback, not entropy estimation; pair it with a\n * breach-list check server-side for anything real.\n */\nexport function passwordStrength(password: string): number {\n if (password.length < MIN_PASSWORD_LENGTH) return 0;\n\n let score = 1;\n if (password.length >= 12) score += 1;\n if (password.length >= 16) score += 1;\n\n const classes = [/[a-z]/, /[A-Z]/, /\\d/, /[^A-Za-z0-9]/].filter((pattern) =>\n pattern.test(password),\n ).length;\n if (classes >= 3) score += 1;\n\n return Math.min(score, 4);\n}\n\nfunction defaultValidate(values: SignUpValues): SignUpErrors {\n const errors: SignUpErrors = {};\n\n if (!values.name.trim()) {\n errors.name = \"Enter your name.\";\n }\n\n if (!values.email.trim()) {\n errors.email = \"Enter your email.\";\n } else if (!EMAIL_PATTERN.test(values.email)) {\n errors.email = \"That doesn't look like an email address.\";\n }\n\n if (!values.password) {\n errors.password = \"Choose a password.\";\n } else if (values.password.length < MIN_PASSWORD_LENGTH) {\n errors.password = `Use at least ${MIN_PASSWORD_LENGTH} characters.`;\n }\n\n if (!values.confirmPassword) {\n errors.confirmPassword = \"Confirm your password.\";\n } else if (values.confirmPassword !== values.password) {\n errors.confirmPassword = \"Passwords don't match.\";\n }\n\n if (!values.terms) {\n errors.terms = \"Accept the terms to continue.\";\n }\n\n return errors;\n}\n\nexport function SignUpForm({\n values: valuesProp,\n defaultValues,\n onValuesChange,\n onSubmit,\n validate,\n status: statusProp,\n errorMessage,\n title = \"Create your account\",\n description = \"Start building in under a minute.\",\n submitLabel = \"Create account\",\n footer,\n strengthMeter = true,\n className,\n classNames,\n}: SignUpFormProps) {\n const reduce = useReducedMotion();\n const baseId = useId();\n\n const controlled = valuesProp !== undefined;\n const [internalValues, setInternalValues] = useState<SignUpValues>({\n ...EMPTY_VALUES,\n ...defaultValues,\n });\n const values = controlled ? valuesProp : internalValues;\n\n const [internalStatus, setInternalStatus] = useState<SignUpStatus>(\"idle\");\n const status = statusProp ?? internalStatus;\n\n const [revealPassword, setRevealPassword] = useState(false);\n\n // \"Reward early, punish late\": errors are computed on every change, but a\n // field only *shows* its error once it has been blurred (or submit touched\n // everything). So a first entry is never flagged mid-typing, while a field\n // already in error clears the moment it becomes valid.\n const [touched, setTouched] = useState<Partial<Record<keyof SignUpValues, boolean>>>({});\n\n const errors = useMemo(() => (validate ?? defaultValidate)(values), [values, validate]);\n\n const setValue = useCallback(\n <K extends keyof SignUpValues>(key: K, next: SignUpValues[K]) => {\n const nextValues = { ...values, [key]: next };\n if (!controlled) {\n setInternalValues(nextValues);\n if (statusProp === undefined) {\n setInternalStatus((current) =>\n current === \"success\" || current === \"error\" ? \"idle\" : current,\n );\n }\n }\n onValuesChange?.(nextValues);\n },\n [controlled, onValuesChange, statusProp, values],\n );\n\n const touch = useCallback((key: keyof SignUpValues) => {\n setTouched((prev) => (prev[key] ? prev : { ...prev, [key]: true }));\n }, []);\n\n /** Error to render for a field — hidden until the field has been touched. */\n const shownError = (key: keyof SignUpValues) => (touched[key] ? errors[key] : undefined);\n\n /** Success check draws only once a touched field is non-empty and valid. */\n const isValid = (key: keyof SignUpValues) =>\n Boolean(touched[key]) && !errors[key] && Boolean(values[key]);\n\n const strength = passwordStrength(values.password);\n const showStrength = strengthMeter && values.password.length > 0;\n const isSubmitting = status === \"loading\";\n\n const handleSubmit = async (event: FormEvent<HTMLFormElement>) => {\n event.preventDefault();\n\n setTouched({\n name: true,\n email: true,\n password: true,\n confirmPassword: true,\n terms: true,\n });\n\n if (Object.keys(errors).length > 0) return;\n if (!onSubmit) return;\n\n if (statusProp === undefined) setInternalStatus(\"loading\");\n try {\n await onSubmit(values);\n if (statusProp === undefined) setInternalStatus(\"success\");\n } catch {\n if (statusProp === undefined) setInternalStatus(\"error\");\n }\n };\n\n const termsErrorId = `${baseId}-terms-error`;\n const formErrorId = `${baseId}-form-error`;\n\n return (\n <form\n noValidate\n onSubmit={handleSubmit}\n className={cn(\n \"border-border flex w-full max-w-sm flex-col gap-5 rounded-3xl border p-6\",\n className,\n classNames?.root,\n )}\n >\n {title || description ? (\n <div className={cn(\"flex flex-col gap-1\", classNames?.header)}>\n {title ? (\n <h2\n className={cn(\n \"text-foreground text-xl font-semibold tracking-tight\",\n classNames?.title,\n )}\n >\n {title}\n </h2>\n ) : null}\n {description ? (\n <p className={cn(\"text-muted-foreground text-sm\", classNames?.description)}>\n {description}\n </p>\n ) : null}\n </div>\n ) : null}\n\n <div className={cn(\"flex flex-col gap-1\", classNames?.fields)}>\n <Input\n label=\"Name\"\n autoComplete=\"name\"\n placeholder=\"Ada Lovelace\"\n leftIcon={<User />}\n disabled={isSubmitting}\n value={values.name}\n onChange={(next) => setValue(\"name\", next)}\n onBlur={() => touch(\"name\")}\n error={shownError(\"name\")}\n reserveErrorLine\n success={isValid(\"name\")}\n />\n\n <Input\n label=\"Email\"\n type=\"email\"\n inputMode=\"email\"\n autoComplete=\"email\"\n placeholder=\"you@example.com\"\n leftIcon={<Mail />}\n disabled={isSubmitting}\n value={values.email}\n onChange={(next) => setValue(\"email\", next)}\n onBlur={() => touch(\"email\")}\n error={shownError(\"email\")}\n reserveErrorLine\n success={isValid(\"email\")}\n />\n\n <div className=\"flex flex-col gap-2\">\n <Input\n label=\"Password\"\n type={revealPassword ? \"text\" : \"password\"}\n autoComplete=\"new-password\"\n placeholder=\"At least 8 characters\"\n leftIcon={<Lock />}\n rightIcon={\n <button\n type=\"button\"\n disabled={isSubmitting}\n onClick={() => setRevealPassword((prev) => !prev)}\n aria-label={revealPassword ? \"Hide password\" : \"Show password\"}\n className=\"text-muted-foreground hover:text-foreground focus-visible:text-foreground transition-colors outline-none\"\n >\n {revealPassword ? <EyeOff /> : <Eye />}\n </button>\n }\n disabled={isSubmitting}\n value={values.password}\n onChange={(next) => setValue(\"password\", next)}\n onBlur={() => touch(\"password\")}\n error={shownError(\"password\")}\n reserveErrorLine\n />\n\n <AnimatePresence initial={false}>\n {showStrength ? (\n <motion.div\n initial={reduce ? { opacity: 0 } : { opacity: 0, y: -4 }}\n animate={{ opacity: 1, y: 0 }}\n exit={reduce ? { opacity: 0 } : { opacity: 0, y: -4 }}\n transition={{ duration: 0.18, ease: EASE_OUT }}\n className={cn(\"flex flex-col gap-1.5 px-1\", classNames?.strength)}\n >\n <div className=\"flex gap-1.5\" aria-hidden>\n {[0, 1, 2, 3].map((index) => (\n <span\n key={index}\n className=\"bg-muted-foreground/20 h-1 flex-1 overflow-hidden rounded-full\"\n >\n {/* scaleX rather than width — transforms only, per the\n motion conventions, and it keeps the bar off layout. */}\n <motion.span\n initial={false}\n animate={{ scaleX: index < strength ? 1 : 0 }}\n transition={reduce ? { duration: 0 } : SPRING_LAYOUT}\n className={cn(\n \"block h-full w-full origin-left rounded-full\",\n STRENGTH_COLORS[strength],\n )}\n />\n </span>\n ))}\n </div>\n <p aria-live=\"polite\" className=\"text-muted-foreground text-xs\">\n Password strength: {STRENGTH_LABELS[strength]}\n </p>\n </motion.div>\n ) : null}\n </AnimatePresence>\n </div>\n\n <Input\n label=\"Confirm password\"\n type={revealPassword ? \"text\" : \"password\"}\n autoComplete=\"new-password\"\n placeholder=\"Re-enter your password\"\n leftIcon={<Lock />}\n disabled={isSubmitting}\n value={values.confirmPassword}\n onChange={(next) => setValue(\"confirmPassword\", next)}\n onBlur={() => touch(\"confirmPassword\")}\n error={shownError(\"confirmPassword\")}\n reserveErrorLine\n success={isValid(\"confirmPassword\")}\n />\n </div>\n\n <div className={cn(\"flex flex-col gap-1.5\", classNames?.terms)}>\n <Checkbox\n checked={values.terms}\n disabled={isSubmitting}\n onCheckedChange={(next) => {\n setValue(\"terms\", next);\n touch(\"terms\");\n }}\n label=\"I agree to the Terms and Privacy Policy\"\n aria-describedby={shownError(\"terms\") ? termsErrorId : undefined}\n />\n <AnimatePresence initial={false}>\n {shownError(\"terms\") ? (\n <motion.p\n id={termsErrorId}\n role=\"alert\"\n initial={reduce ? { opacity: 0 } : { opacity: 0, y: -4, filter: \"blur(4px)\" }}\n animate={{ opacity: 1, y: 0, filter: \"blur(0px)\" }}\n exit={reduce ? { opacity: 0 } : { opacity: 0, y: -4, filter: \"blur(4px)\" }}\n transition={{ duration: 0.2 }}\n className=\"text-destructive px-1 text-xs\"\n >\n {shownError(\"terms\")}\n </motion.p>\n ) : null}\n </AnimatePresence>\n </div>\n\n <AnimatePresence initial={false}>\n {errorMessage ? (\n <motion.p\n id={formErrorId}\n role=\"alert\"\n initial={reduce ? { opacity: 0 } : { opacity: 0, y: -4 }}\n animate={{ opacity: 1, y: 0 }}\n exit={reduce ? { opacity: 0 } : { opacity: 0, y: -4 }}\n transition={{ duration: 0.2 }}\n className=\"border-destructive/30 bg-destructive/10 text-destructive rounded-2xl border px-3 py-2 text-xs\"\n >\n {errorMessage}\n </motion.p>\n ) : null}\n </AnimatePresence>\n\n <StatefulButton\n type=\"submit\"\n size=\"lg\"\n state={status}\n loadingText=\"Creating account\"\n successText=\"Account created\"\n errorText=\"Try again\"\n aria-describedby={errorMessage ? formErrorId : undefined}\n className={cn(\"w-full\", classNames?.submit)}\n >\n {submitLabel}\n </StatefulButton>\n\n {footer ? (\n <div className={cn(\"text-muted-foreground text-center text-sm\", classNames?.footer)}>\n {footer}\n </div>\n ) : null}\n </form>\n );\n}\n"],"mappings":";;;;;;;;;;;AA2DA,MAAM,eAA6B;CACjC,MAAM;CACN,OAAO;CACP,UAAU;CACV,iBAAiB;CACjB,OAAO;AACT;AAIA,MAAM,gBAAgB;AAEtB,MAAM,sBAAsB;AAE5B,MAAM,kBAAkB;CAAC;CAAa;CAAQ;CAAQ;CAAQ;AAAQ;AAEtE,MAAM,kBAAkB;CACtB;CACA;CACA;CACA;CACA;AACF;;;;;;;;AAS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UAAA;IACO,CAAA,IACR;GACW,CAAA;GAEjB,oBAAC,gBAAD;IACE,MAAK;IACL,MAAK;IACL,OAAO;IACP,aAAY;IACZ,aAAY;IACZ,WAAU;IACV,oBAAkB,eAAe,cAAc,KAAA;IAC/C,WAAW,GAAG,UAAU,YAAY,MAAM;IAEzC,UAAA;GACa,CAAA;GAEf,SACC,oBAAC,OAAD;IAAK,WAAW,GAAG,6CAA6C,YAAY,MAAM;IAC/E,UAAA;GACE,CAAA,IACH;EACA;;AAEV"}
@@ -1,5 +1,5 @@
1
1
  import { n as Token, t as Chain } from "../../types-qTGsGdN1.js";
2
- import { t as EASE_DRAWER } from "../../ease-CHhXKlG3.js";
2
+ import { t as EASE_DRAWER } from "../../ease-DjhlGGZO.js";
3
3
  export interface MultiChainSwapProps {
4
4
  chains?: Chain[];
5
5
  tokens?: Token[];
@@ -40,7 +40,7 @@ export interface TooltipTriggerProps extends ComponentProps<"button"> {
40
40
  /** Use the single child element as the trigger instead of rendering a button. */
41
41
  asChild?: boolean;
42
42
  }
43
- export declare function TooltipTrigger({ asChild, children, ref, ...props }: TooltipTriggerProps): string | number | bigint | boolean | import("react").JSX.Element | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | null | undefined;
43
+ export declare function TooltipTrigger({ asChild, children, ref, ...props }: TooltipTriggerProps): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react").JSX.Element | null | undefined;
44
44
  export interface TooltipContentProps {
45
45
  children?: ReactNode;
46
46
  side?: TooltipSide;
@@ -63,6 +63,6 @@ export interface TooltipProps extends TooltipRootProps, Omit<TooltipContentProps
63
63
  /** Shorthand only: classes for the tooltip surface. */
64
64
  className?: string;
65
65
  }
66
- export declare function Tooltip(props: TooltipProps): string | number | bigint | boolean | import("react").JSX.Element | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | null;
66
+ export declare function Tooltip(props: TooltipProps): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react").JSX.Element | null;
67
67
  export type { TooltipAlign, TooltipSide };
68
68
  //# sourceMappingURL=tooltip.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tooltip.d.ts","names":[],"sources":["../../../src/components/motion/tooltip.tsx"],"mappings":";;UA6CU;;EAER;;EAEA;;EAEA;;iBAKe,6BAA6B,QAAQ;EACpD,UAAU;;;wBAII,kBAAkB,aAAa,UAAU,uCAAoB,IAAA;iBAoD5D;EACf,WAAW;EACX;EACA;EACA,gBAAgB;;EAEhB;;EAEA;;EAEA;;;;;EAKA;;EAEA;;EAEA,YAAY,UAAU;;EAEtB;;iBA2Ve,4BAA4B;;EAE3C;;wBAGc,iBAAiB,SAAiB,UAAU,QAAQ,SAAS,2EAAmB,IAAA,UAAA,SAAA,aAAA,6DAAA,cAAA,+CAAA,8BAAA,SAAA;iBA0D/E;EACf,WAAW;EACX,OAAO;EACP,QAAQ;;EAER;;EAEA;;EAEA,cAAc;EACd;;wBAGc,iBACd,UACA,MACA,OACA,YACA,OACA,aACA,aACC,sCAAmB;iBA6EL,qBACP,kBACN,KAAK;;;;;EAKP,UAAU;;EAEV;;wBAGc,QAAQ,OAAO,oEAAY,IAAA,UAAA,SAAA,aAAA,6DAAA,cAAA,+CAAA,8BAAA,SAAA"}
1
+ {"version":3,"file":"tooltip.d.ts","names":[],"sources":["../../../src/components/motion/tooltip.tsx"],"mappings":";;UA6CU;;EAER;;EAEA;;EAEA;;iBAKe,6BAA6B,QAAQ;EACpD,UAAU;;;wBAII,kBAAkB,aAAa,UAAU,uCAAoB,IAAA;iBAoD5D;EACf,WAAW;EACX;EACA;EACA,gBAAgB;;EAEhB;;EAEA;;EAEA;;;;;EAKA;;EAEA;;EAEA,YAAY,UAAU;;EAEtB;;iBA2Ve,4BAA4B;;EAE3C;;wBAGc,iBAAiB,SAAiB,UAAU,QAAQ,SAAS,2DAAmB,SAAA,aAAA,6DAAA,cAAA,+CAAA,8BAAA,SAAA,iDAAA,IAAA;iBA0D/E;EACf,WAAW;EACX,OAAO;EACP,QAAQ;;EAER;;EAEA;;EAEA,cAAc;EACd;;wBAGc,iBACd,UACA,MACA,OACA,YACA,OACA,aACA,aACC,sCAAmB;iBA6EL,qBACP,kBACN,KAAK;;;;;EAKP,UAAU;;EAEV;;wBAGc,QAAQ,OAAO,oDAAY,SAAA,aAAA,6DAAA,cAAA,+CAAA,8BAAA,SAAA,iDAAA,IAAA"}
@@ -1,6 +1,5 @@
1
1
  "use client";
2
2
  import { ActionSwapText } from "../action-swap.js";
3
- import "../button/index.js";
4
3
  import { Button } from "../button/base.js";
5
4
  import { AccountSwitcher } from "./account-switcher.js";
6
5
  import { WalletActions } from "./actions.js";
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/motion/wallet-card/index.tsx"],"sourcesContent":["\"use client\";\n\nimport { useState } from \"react\";\nimport { Bell, Eye, EyeOff } from \"lucide-react\";\n\nimport { cn } from \"@kumix/utils\";\nimport { ActionSwapText } from \"../action-swap\";\nimport { Button } from \"../button\";\nimport { AccountSwitcher } from \"./account-switcher\";\nimport { WalletActions } from \"./actions\";\nimport { BalanceDelta } from \"./balance-delta\";\nimport { SearchBar } from \"./search-bar\";\nimport type { WalletCardProps } from \"./types\";\n\nexport type { WalletAccount, WalletCardProps } from \"./types\";\n\n/**\n * Composed wallet overview card: an account switcher whose trigger morphs open\n * into a full-width panel, a search icon that morphs into a search bar, a\n * rolling balance with a transient change indicator, and Send / Deposit\n * actions. Actions and search are plain callbacks — the resulting flow is left\n * to the consumer.\n */\nexport function WalletCard({\n accounts,\n accountId,\n defaultAccountId,\n onAccountChange,\n balance,\n balancePrefix = \"$\",\n defaultChange,\n defaultBalanceHidden = false,\n onSend,\n onDeposit,\n onSwap,\n onBuy,\n searchPlaceholder,\n searchRecent,\n onSearchChange,\n onSearchSubmit,\n hasNotifications = false,\n onNotifications,\n className,\n}: WalletCardProps) {\n const accountControlled = accountId !== undefined;\n const [internalAccountId, setInternalAccountId] = useState(defaultAccountId ?? accounts[0]?.id);\n const [balanceHidden, setBalanceHidden] = useState(defaultBalanceHidden);\n\n const shownBalance = `${balancePrefix}${balance.toLocaleString(undefined, {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })}`;\n const maskedBalance = \"*\".repeat(7);\n const activeAccountId = accountControlled ? accountId : internalAccountId;\n const activeAccount = accounts.find((a) => a.id === activeAccountId) ?? accounts[0];\n\n const handleAccountChange = (id: string) => {\n if (!accountControlled) setInternalAccountId(id);\n onAccountChange?.(id);\n };\n\n return (\n <div\n className={cn(\n \"border-border relative w-full max-w-xs overflow-hidden rounded-4xl border p-6\",\n className,\n )}\n >\n {/* relative anchor so the switcher + search panels span the whole row */}\n <div className=\"relative flex items-center justify-between gap-2\">\n <AccountSwitcher\n accounts={accounts}\n activeAccount={activeAccount}\n onSelect={handleAccountChange}\n />\n\n <div className=\"flex shrink-0 items-center gap-1\">\n <SearchBar\n placeholder={searchPlaceholder}\n recent={searchRecent}\n onChange={onSearchChange}\n onSubmit={onSearchSubmit}\n />\n <Button\n variant=\"ghost\"\n size=\"icon\"\n onClick={onNotifications}\n aria-label=\"Notifications\"\n className=\"relative\"\n >\n <Bell className=\"h-4 w-4\" />\n {hasNotifications ? (\n <span className=\"absolute top-1.5 right-1.5 flex h-2 w-2\">\n <span className=\"bg-primary absolute inline-flex h-full w-full animate-ping rounded-full opacity-60\" />\n <span className=\"bg-primary relative inline-flex h-2 w-2 rounded-full\" />\n </span>\n ) : null}\n </Button>\n </div>\n </div>\n\n <div className=\"mt-8 flex flex-col items-center text-center\">\n <div className=\"flex items-center gap-1.5\">\n <p className=\"text-muted-foreground text-xs\">Balance</p>\n <button\n type=\"button\"\n onClick={() => setBalanceHidden((h) => !h)}\n aria-label={balanceHidden ? \"Show balance\" : \"Hide balance\"}\n aria-pressed={balanceHidden}\n className=\"text-muted-foreground hover:text-foreground transition-colors outline-none\"\n >\n {balanceHidden ? <EyeOff className=\"h-3.5 w-3.5\" /> : <Eye className=\"h-3.5 w-3.5\" />}\n </button>\n </div>\n {/* One ActionSwapText swaps the number and the asterisk mask with a\n per-letter cascade — same baseline, no overlap or layout shift. */}\n <ActionSwapText\n value={balanceHidden ? \"hidden\" : shownBalance}\n animation=\"cascade\"\n className=\"text-foreground text-3xl font-semibold\"\n >\n {balanceHidden ? maskedBalance : shownBalance}\n </ActionSwapText>\n {balanceHidden ? (\n <div className=\"mt-2 flex h-7 items-center justify-center\">\n <span className=\"text-muted-foreground translate-y-[3px] text-sm leading-none font-semibold tracking-[0.3em]\">\n *****\n </span>\n </div>\n ) : (\n <BalanceDelta balance={balance} initialChange={defaultChange} />\n )}\n </div>\n\n <div className=\"mt-8\">\n <WalletActions onSend={onSend} onDeposit={onDeposit} onSwap={onSwap} onBuy={onBuy} />\n </div>\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAuBA,SAAgB,WAAW,EACzB,UACA,WACA,kBACA,iBACA,SACA,gBAAgB,KAChB,eACA,uBAAuB,OACvB,QACA,WACA,QACA,OACA,mBACA,cACA,gBACA,gBACA,mBAAmB,OACnB,iBACA,aACkB;CAClB,MAAM,oBAAoB,cAAc,KAAA;CACxC,MAAM,CAAC,mBAAmB,wBAAwB,SAAS,oBAAoB,SAAS,EAAE,EAAE,EAAE;CAC9F,MAAM,CAAC,eAAe,oBAAoB,SAAS,oBAAoB;CAEvE,MAAM,eAAe,GAAG,gBAAgB,QAAQ,eAAe,KAAA,GAAW;EACxE,uBAAuB;EACvB,uBAAuB;CACzB,CAAC;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,oBAAC,gBAAD;MACE,OAAO,gBAAgB,WAAW;MAClC,WAAU;MACV,WAAU;MAET,UAAA,gBAAgB,gBAAgB;KACnB,CAAA;KACf,gBACC,oBAAC,OAAD;MAAK,WAAU;MACb,UAAA,oBAAC,QAAD;OAAM,WAAU;OAA8F,UAAA;MAExG,CAAA;KACH,CAAA,IAEL,oBAAC,cAAD;MAAuB;MAAS,eAAe;KAAgB,CAAA;IAE9D;;GAEL,oBAAC,OAAD;IAAK,WAAU;IACb,UAAA,oBAAC,eAAD;KAAuB;KAAmB;KAAmB;KAAe;IAAQ,CAAA;GACjF,CAAA;EACF;;AAET"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../../../src/components/motion/wallet-card/index.tsx"],"sourcesContent":["\"use client\";\n\nimport { useState } from \"react\";\nimport { Bell, Eye, EyeOff } from \"lucide-react\";\n\nimport { cn } from \"@kumix/utils\";\nimport { ActionSwapText } from \"../action-swap\";\nimport { Button } from \"../button\";\nimport { AccountSwitcher } from \"./account-switcher\";\nimport { WalletActions } from \"./actions\";\nimport { BalanceDelta } from \"./balance-delta\";\nimport { SearchBar } from \"./search-bar\";\nimport type { WalletCardProps } from \"./types\";\n\nexport type { WalletAccount, WalletCardProps } from \"./types\";\n\n/**\n * Composed wallet overview card: an account switcher whose trigger morphs open\n * into a full-width panel, a search icon that morphs into a search bar, a\n * rolling balance with a transient change indicator, and Send / Deposit\n * actions. Actions and search are plain callbacks — the resulting flow is left\n * to the consumer.\n */\nexport function WalletCard({\n accounts,\n accountId,\n defaultAccountId,\n onAccountChange,\n balance,\n balancePrefix = \"$\",\n defaultChange,\n defaultBalanceHidden = false,\n onSend,\n onDeposit,\n onSwap,\n onBuy,\n searchPlaceholder,\n searchRecent,\n onSearchChange,\n onSearchSubmit,\n hasNotifications = false,\n onNotifications,\n className,\n}: WalletCardProps) {\n const accountControlled = accountId !== undefined;\n const [internalAccountId, setInternalAccountId] = useState(defaultAccountId ?? accounts[0]?.id);\n const [balanceHidden, setBalanceHidden] = useState(defaultBalanceHidden);\n\n const shownBalance = `${balancePrefix}${balance.toLocaleString(undefined, {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })}`;\n const maskedBalance = \"*\".repeat(7);\n const activeAccountId = accountControlled ? accountId : internalAccountId;\n const activeAccount = accounts.find((a) => a.id === activeAccountId) ?? accounts[0];\n\n const handleAccountChange = (id: string) => {\n if (!accountControlled) setInternalAccountId(id);\n onAccountChange?.(id);\n };\n\n return (\n <div\n className={cn(\n \"border-border relative w-full max-w-xs overflow-hidden rounded-4xl border p-6\",\n className,\n )}\n >\n {/* relative anchor so the switcher + search panels span the whole row */}\n <div className=\"relative flex items-center justify-between gap-2\">\n <AccountSwitcher\n accounts={accounts}\n activeAccount={activeAccount}\n onSelect={handleAccountChange}\n />\n\n <div className=\"flex shrink-0 items-center gap-1\">\n <SearchBar\n placeholder={searchPlaceholder}\n recent={searchRecent}\n onChange={onSearchChange}\n onSubmit={onSearchSubmit}\n />\n <Button\n variant=\"ghost\"\n size=\"icon\"\n onClick={onNotifications}\n aria-label=\"Notifications\"\n className=\"relative\"\n >\n <Bell className=\"h-4 w-4\" />\n {hasNotifications ? (\n <span className=\"absolute top-1.5 right-1.5 flex h-2 w-2\">\n <span className=\"bg-primary absolute inline-flex h-full w-full animate-ping rounded-full opacity-60\" />\n <span className=\"bg-primary relative inline-flex h-2 w-2 rounded-full\" />\n </span>\n ) : null}\n </Button>\n </div>\n </div>\n\n <div className=\"mt-8 flex flex-col items-center text-center\">\n <div className=\"flex items-center gap-1.5\">\n <p className=\"text-muted-foreground text-xs\">Balance</p>\n <button\n type=\"button\"\n onClick={() => setBalanceHidden((h) => !h)}\n aria-label={balanceHidden ? \"Show balance\" : \"Hide balance\"}\n aria-pressed={balanceHidden}\n className=\"text-muted-foreground hover:text-foreground transition-colors outline-none\"\n >\n {balanceHidden ? <EyeOff className=\"h-3.5 w-3.5\" /> : <Eye className=\"h-3.5 w-3.5\" />}\n </button>\n </div>\n {/* One ActionSwapText swaps the number and the asterisk mask with a\n per-letter cascade — same baseline, no overlap or layout shift. */}\n <ActionSwapText\n value={balanceHidden ? \"hidden\" : shownBalance}\n animation=\"cascade\"\n className=\"text-foreground text-3xl font-semibold\"\n >\n {balanceHidden ? maskedBalance : shownBalance}\n </ActionSwapText>\n {balanceHidden ? (\n <div className=\"mt-2 flex h-7 items-center justify-center\">\n <span className=\"text-muted-foreground translate-y-[3px] text-sm leading-none font-semibold tracking-[0.3em]\">\n *****\n </span>\n </div>\n ) : (\n <BalanceDelta balance={balance} initialChange={defaultChange} />\n )}\n </div>\n\n <div className=\"mt-8\">\n <WalletActions onSend={onSend} onDeposit={onDeposit} onSwap={onSwap} onBuy={onBuy} />\n </div>\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAuBA,SAAgB,WAAW,EACzB,UACA,WACA,kBACA,iBACA,SACA,gBAAgB,KAChB,eACA,uBAAuB,OACvB,QACA,WACA,QACA,OACA,mBACA,cACA,gBACA,gBACA,mBAAmB,OACnB,iBACA,aACkB;CAClB,MAAM,oBAAoB,cAAc,KAAA;CACxC,MAAM,CAAC,mBAAmB,wBAAwB,SAAS,oBAAoB,SAAS,EAAE,EAAE,EAAE;CAC9F,MAAM,CAAC,eAAe,oBAAoB,SAAS,oBAAoB;CAEvE,MAAM,eAAe,GAAG,gBAAgB,QAAQ,eAAe,KAAA,GAAW;EACxE,uBAAuB;EACvB,uBAAuB;CACzB,CAAC;CACD,MAAM,gBAAgB,IAAI,OAAO,CAAC;CAClC,MAAM,kBAAkB,oBAAoB,YAAY;CACxD,MAAM,gBAAgB,SAAS,MAAM,MAAM,EAAE,OAAO,eAAe,KAAK,SAAS;CAEjF,MAAM,uBAAuB,OAAe;EAC1C,IAAI,CAAC,mBAAmB,qBAAqB,EAAE;EAC/C,kBAAkB,EAAE;CACtB;CAEA,OACE,qBAAC,OAAD;EACE,WAAW,GACT,iFACA,SACF;EAJF,UAAA;GAOE,qBAAC,OAAD;IAAK,W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KAAuB;KAAmB;KAAmB;KAAe;IAAQ,CAAA;GACjF,CAAA;EACF;;AAET"}
@@ -1,6 +1,6 @@
1
1
  import { VariantProps } from "class-variance-authority";
2
2
  declare const alertVariants: (props?: ({
3
- variant?: "default" | "destructive" | "success" | "info" | "warning" | "invert" | null | undefined;
3
+ variant?: "default" | "destructive" | "info" | "success" | "warning" | "invert" | null | undefined;
4
4
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
5
5
  declare function Alert({ className, variant, ...props }: React.ComponentProps<"div"> & VariantProps<typeof alertVariants>): import("react").JSX.Element;
6
6
  declare function AlertTitle({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
@@ -1,7 +1,7 @@
1
1
  import { VariantProps } from "class-variance-authority";
2
2
  import { useRender } from "@base-ui/react/use-render";
3
3
  declare const badgeVariants: (props?: ({
4
- variant?: "outline" | "default" | "destructive" | "success" | "info" | "warning" | "invert" | "secondary" | "focus" | "primary-light" | "warning-light" | "success-light" | "info-light" | "destructive-light" | "invert-light" | "focus-light" | "primary-outline" | "warning-outline" | "success-outline" | "info-outline" | "destructive-outline" | "invert-outline" | "focus-outline" | null | undefined;
4
+ variant?: "outline" | "secondary" | "default" | "destructive" | "info" | "success" | "warning" | "invert" | "focus" | "primary-light" | "warning-light" | "success-light" | "info-light" | "destructive-light" | "invert-light" | "focus-light" | "primary-outline" | "warning-outline" | "success-outline" | "info-outline" | "destructive-outline" | "invert-outline" | "focus-outline" | null | undefined;
5
5
  size?: "default" | "sm" | "lg" | "xs" | "xl" | null | undefined;
6
6
  radius?: "default" | "full" | null | undefined;
7
7
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
@@ -1,3 +1,4 @@
1
+ /** biome-ignore-all assist/source/organizeImports: <> */
1
2
  import { Button } from "../../ui/button.js";
2
3
  import { CodeBlockDiffSpec, CodeBlockHighlightOptions, CodeBlockLevelSpec, CodeBlockLine, CodeBlockLineActionsRender, CodeBlockLineSpec, CodeBlockLineState, CodeBlockPatchFile, CodeBlockThemes, CodeBlockToken, CodeBlockTransformer, CodeBlockWordSpec, ansiToLines, markdownCodeProps, markdownFences, parseUnifiedDiff } from "./code-block-highlight.js";
3
4
  import { ComponentProps, ReactNode } from "react";
@@ -1 +1 @@
1
- {"version":3,"file":"code-block.d.ts","names":[],"sources":["../../../../src/components/reui/code-block/code-block.tsx"],"mappings":";;;;;;;KAwDK;EACH;EACA;EACA;EACA;EACA,UAAU;EACV;EACA;EACA,cAAc;EACd;EACA;EACA;;;;;;;YAqCU;iBAsBH,mBAAmB,eAAe;EAAyB;;YAqMxD;;EAEV;;EAEA;;YAsVU;EACV;EACA;EACA,QAAQ;EACR,SAAS;EACT;EACA;EACA;EACA;EACA;EACA,gBAAgB;EAChB;EACA;EACA;EACA,mBAAmB;EACnB,mBAAmB;EACnB,eAAe;EACf,OAAO;EACP,aAAa;EACb,eAAe;EACf;EACA;EACA;EACA;EACA,yBAAyB;;EAEzB;;EAEA;EACA;EACA,oBAAoB;;EAEpB;;;;;;EAMA,cAAc;;EAEd;;EAEA;EACA,kBAAkB;EAClB,WAAW;IACT,KAAK;;;;;;;iBAQA,YACP,MACA,UACA,OAAO,WACP,QACA,WACA,iBACA,WACA,MAAM,UACN,aACA,cACA,UACA,SACA,OACA,kBACA,kBACA,cACA,MACA,YACA,cACA,WACA,YACA,eACA,sBACA,uBACA,sBACA,UAAU,cACV,iBACA,kBACA,UACA,aAAa,iBACb,QACA,eACA,gBACA,WACA,aACG,SACF,iCAAc,IAAA;;;;;;;iBA0cR,mBAAmB;EAAe;oBAAoB,IAAA;;;;;;iBAiatD,kBAAkB,cAAc,SAAS,wCAAqB,IAAA;iBAe9D,iBAAiB,cAAc,SAAS,wCAAqB,IAAA;;;;;;iBAe7D,oBAAoB,WAAW,aAAa,SAAS,yCAAsB,IAAA;YAsDxE;EACV;EACA;EACA,UAAU;EACV,eAAe;;EAEf;IAAW;IAAe;;;EAE1B;EACA;IACE,KAAK,sBAAsB;;;;;;;iBAQtB,sBACP,OACA,SACA,QACA,aACA,QACA,UACA,eACA,WACA,SACA,MACA,aACG,SACF,2CAAwB,IAAA;iBAwFlB,sBACP,WACA,UACA,SACA,MACA,YACG,SACF,sBAAsB,0BAAO,IAAA;;;;;;;iBA6BvB,wBACP,WACA,UACA,SACA,MACA,YACG,SACF,sBAAsB,0BAAO,IAAA;YA8CpB;EACV,UAAU;;;;;;;EAOV,OAAO;;YAsCG;;EAEV;;EAEA;EACA,cAAc;;EAEd;EACA;;EAEA;IACE,KAAK,sBAAsB;;;;;;iBAOtB,0BACP,OACA,UACA,YACA,UACA,eACA,OACA,WACA,SACA,MACA,aACG,SACF,+CAA4B,IAAA;iBA8DtB,uBAAuB,UAAU,QAAgB;;;;;;iBAiBjD;;;;EAj9Da,aAAA;;;;;;;;;;iBA++Db;;;EAp/DY,aAAA,cAAM;EACH"}
1
+ {"version":3,"file":"code-block.d.ts","names":[],"sources":["../../../../src/components/reui/code-block/code-block.tsx"],"mappings":";;;;;;;;KAwDK;EACH;EACA;EACA;EACA;EACA,UAAU;EACV;EACA;EACA,cAAc;EACd;EACA;EACA;;;;;;;YAqCU;iBAsBH,mBAAmB,eAAe;EAAyB;;YAqMxD;;EAEV;;EAEA;;YAsVU;EACV;EACA;EACA,QAAQ;EACR,SAAS;EACT;EACA;EACA;EACA;EACA;EACA,gBAAgB;EAChB;EACA;EACA;EACA,mBAAmB;EACnB,mBAAmB;EACnB,eAAe;EACf,OAAO;EACP,aAAa;EACb,eAAe;EACf;EACA;EACA;EACA;EACA,yBAAyB;;EAEzB;;EAEA;EACA;EACA,oBAAoB;;EAEpB;;;;;;EAMA,cAAc;;EAEd;;EAEA;EACA,kBAAkB;EAClB,WAAW;IACT,KAAK;;;;;;;iBAQA,YACP,MACA,UACA,OAAO,WACP,QACA,WACA,iBACA,WACA,MAAM,UACN,aACA,cACA,UACA,SACA,OACA,kBACA,kBACA,cACA,MACA,YACA,cACA,WACA,YACA,eACA,sBACA,uBACA,sBACA,UAAU,cACV,iBACA,kBACA,UACA,aAAa,iBACb,QACA,eACA,gBACA,WACA,aACG,SACF,iCAAc,IAAA;;;;;;;iBA0cR,mBAAmB;EAAe;oBAAoB,IAAA;;;;;;iBAiatD,kBAAkB,cAAc,SAAS,wCAAqB,IAAA;iBAe9D,iBAAiB,cAAc,SAAS,wCAAqB,IAAA;;;;;;iBAe7D,oBAAoB,WAAW,aAAa,SAAS,yCAAsB,IAAA;YAsDxE;EACV;EACA;EACA,UAAU;EACV,eAAe;;EAEf;IAAW;IAAe;;;EAE1B;EACA;IACE,KAAK,sBAAsB;;;;;;;iBAQtB,sBACP,OACA,SACA,QACA,aACA,QACA,UACA,eACA,WACA,SACA,MACA,aACG,SACF,2CAAwB,IAAA;iBAwFlB,sBACP,WACA,UACA,SACA,MACA,YACG,SACF,sBAAsB,0BAAO,IAAA;;;;;;;iBA6BvB,wBACP,WACA,UACA,SACA,MACA,YACG,SACF,sBAAsB,0BAAO,IAAA;YA8CpB;EACV,UAAU;;;;;;;EAOV,OAAO;;YAsCG;;EAEV;;EAEA;EACA,cAAc;;EAEd;EACA;;EAEA;IACE,KAAK,sBAAsB;;;;;;iBAOtB,0BACP,OACA,UACA,YACA,UACA,eACA,OACA,WACA,SACA,MACA,aACG,SACF,+CAA4B,IAAA;iBA8DtB,uBAAuB,UAAU,QAAgB;;;;;;iBAiBjD;;;;EAj9Da,aAAA;;;;;;;;;;iBA++Db;;;EAp/DY,aAAA,cAAM;EACH"}
@@ -147,7 +147,7 @@ declare function getDataGridTableMergedHeaderGroups<TData extends object>(table:
147
147
  columnMeta: DataGridColumnMeta<any>;
148
148
  }, TData, unknown>[]>;
149
149
  }[];
150
- declare function renderDataGridTableHeadCellContent<TData extends object>(header: Header<DataGridFeatures, TData, unknown>): string | number | bigint | boolean | import("react").JSX.Element | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | null | undefined;
150
+ declare function renderDataGridTableHeadCellContent<TData extends object>(header: Header<DataGridFeatures, TData, unknown>): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react").JSX.Element | null | undefined;
151
151
  declare function getDataGridHeadCellResizeHeader<TData extends object>(header: Header<DataGridFeatures, TData, unknown>, coveredHeaders?: Header<DataGridFeatures, TData, unknown>[]): Header<{
152
152
  columnVisibilityFeature: import("@tanstack/react-table").TableFeature;
153
153
  columnOrderingFeature: import("@tanstack/react-table").TableFeature;
@@ -1 +1 @@
1
- {"version":3,"file":"data-grid-table.d.ts","names":["_$__data_grid0.DataGridColumnMeta"],"sources":["../../../../src/components/reui/data-grid/data-grid-table.tsx"],"mappings":";;;iBAuDS,iBAAiB,sBACxB,QAAQ,OAAO,kBAAkB,kBAChC;iBAqBM,2BAA2B,sBAClC,KAAK,IAAI,kBAAkB,QAC3B,kBACC;;;;;;iBAsBM,8BAA8B,MAAM,cAAc;KAoYtD;iBAEI,4BAA4B,sBACnC,OAAO,sBAAsB,QAC7B;EAImB,SAAA,IAAI,kBAAkB;EACG,YAAA,IAAI,kBAAkB;EAC5C,YAAA,IAAI,kBAAkB;;iBAWrC,6BAA6B,sBACpC,OAAO,sBAAsB,QAC7B;EAIO,KAAA,IAAI,kBAAkB;EACV,iBAAA;;iBAmEZ,mCAAmC,sBAC1C,OAAO,sBAAsB;;EA+DpB,SAAA,OAAO,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA2C3B,mCAAmC,sBAC1C,QAAQ,OAAO,kBAAkB,uEAAe,IAAA,UAAA,SAAA,aAAA,6DAAA,8BAAA,+CAAA,8BAAA,SAAA;iBASzC,gC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AS,MAAM,IAAI;EACnB,SAAS,MAAM,IAAI;EACnB,WAAW;EACX;EACA;oBACD,IAAA;iBAmFQ,8BAA8B,wBACrC;EAEA,KAAK,IAAI,kBAAkB;oBAC5B,IAAA;iBA2CQ,yBAAyB,wBAChC,UACA,MACA,QACA,UACA;EAEA,UAAU;EACV,MAAM,KAAK,kBAAkB;EAC7B,SAAS,MAAM,IAAI;EACnB,WAAW;;EAEX;oBACD,IAAA;iBAgMQ,yBAAyB,wBAChC,KACA,gBACA,QACA,UACA;EAEA,KAAK,IAAI,kBAAkB;EAC3B,iBAAiB;EACjB,SAAS,MAAM,IAAI;;EAEnB;;;;;;;;EAQA;IAAiB;IAAe;;oBACjC,IAAA;iBA+DQ,sCAAkB,IAAA;iBAgDlB,uCAAmB,IAAA;iBAanB,oBAAoB,wBAAwB;EAAS,KAAK,IAAI,kBAAkB;oBAAQ,IAAA;;;;;;;;;;;;;iBAkExF,uBAAuB,wBAC9B;EAEA,KAAK,IAAI,kBAAkB;oBAC5B,IAAA;iBAuBQ,6CAAyB,IAAA;iBA2BzB,uBAAuB,wBAC9B,KACA,QACA,WACA;EAEA,KAAK,IAAI,kBAAkB;;EAE3B;EACA;;EAEA,WAAW;oBACZ,IAAA;iBAkKQ,oBAAoB,0CAAqB,IAAA;iBAiDzC,cAAc,yBACrB,eACA;EAEA,gBAAgB;EAChB;oBACD,IAAA"}
1
+ {"version":3,"file":"data-grid-table.d.ts","names":[],"sources":["../../../../src/components/reui/data-grid/data-grid-table.tsx"],"mappings":";;;iBAuDS,iBAAiB,sBACxB,QAAQ,OAAO,kBAAkB,kBAChC;iBAqBM,2BAA2B,sBAClC,KAAK,IAAI,kBAAkB,QAC3B,kBACC;;;;;;iBAsBM,8BAA8B,MAAM,cAAc;KAoYtD;iBAEI,4BAA4B,sBACnC,OAAO,sBAAsB,QAC7B;EAImB,SAAA,IAAI,kBAAkB;EACG,YAAA,IAAI,kBAAkB;EAC5C,YAAA,IAAI,kBAAkB;;iBAWrC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cAAc,yBACrB,eACA;EAEA,gBAAgB;EAChB;oBACD,IAAA"}
@@ -6,7 +6,7 @@ import { VariantProps } from "class-variance-authority";
6
6
  * own bg-* on a panel still wins on source order, with no :not() and no `!`.
7
7
  */
8
8
  declare const frameVariants: (props?: ({
9
- variant?: "default" | "inverse" | "ghost" | null | undefined;
9
+ variant?: "ghost" | "default" | "inverse" | null | undefined;
10
10
  spacing?: "default" | "sm" | "lg" | "xs" | null | undefined;
11
11
  stacked?: boolean | null | undefined;
12
12
  dense?: boolean | null | undefined;
@@ -21,7 +21,7 @@ import { useRender } from "@base-ui/react/use-render";
21
21
  * default to `text-primary`; override it to recolor without touching internals.
22
22
  */
23
23
  declare const iconTileVariants: (props?: ({
24
- variant?: "frame" | "outline" | "solid" | "elevated" | "soft" | null | undefined;
24
+ variant?: "outline" | "frame" | "soft" | "solid" | "elevated" | null | undefined;
25
25
  size?: "default" | "sm" | "lg" | "xs" | "xl" | null | undefined;
26
26
  radius?: "default" | "full" | null | undefined;
27
27
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
@@ -1,3 +1,4 @@
1
+ /** biome-ignore-all lint/suspicious/noExplicitAny: <> */
1
2
  import { useRender } from "@base-ui/react/use-render";
2
3
  import { ItemInstance } from "@headless-tree/core";
3
4
  type ToggleIconType = "chevron" | "plus-minus";
@@ -1 +1 @@
1
- {"version":3,"file":"tree.d.ts","names":[],"sources":["../../../src/components/reui/tree.tsx"],"mappings":";;KAYK;UAoBK,kBAAkB,MAAM,eAAe;EAC/C;EACA;EACA,iBAAiB;;iBAGV,OAAO,QAAa,MAAM,WAAW,mBAA+B,SAAS,4BAAS,IAAA;UA0BrF,cAAc,iBAAiB,KAAK,UAAU;EACtD,MAAM,aAAa;EACnB;;iBAGO,SAAS,WAAW,MAAM,WAAW,QAAQ,aAAa,SAAS,cAAc,qBAAE,IAAA;UA4ClF,mBAAmB,iBAAiB,MAAM,eAAe;EACjE,OAAO,aAAa;;iBAGb,cAAc,WACrB,MAAM,UACN,UACA,cACG,SACF,mBAAmB,qBAAE,IAAA;iBA6Cf,eAAe,cAAc,SAAS,MAAM,eAAe,kCAAe,IAAA"}
1
+ {"version":3,"file":"tree.d.ts","names":[],"sources":["../../../src/components/reui/tree.tsx"],"mappings":";;;KAYK;UAoBK,kBAAkB,MAAM,eAAe;EAC/C;EACA;EACA,iBAAiB;;iBAGV,OAAO,QAAa,MAAM,WAAW,mBAA+B,SAAS,4BAAS,IAAA;UA0BrF,cAAc,iBAAiB,KAAK,UAAU;EACtD,MAAM,aAAa;EACnB;;iBAGO,SAAS,WAAW,MAAM,WAAW,QAAQ,aAAa,SAAS,cAAc,qBAAE,IAAA;UA4ClF,mBAAmB,iBAAiB,MAAM,eAAe;EACjE,OAAO,aAAa;;iBAGb,cAAc,WACrB,MAAM,UACN,UACA,cACG,SACF,mBAAmB,qBAAE,IAAA;iBA6Cf,eAAe,cAAc,SAAS,MAAM,eAAe,kCAAe,IAAA"}
@@ -1,7 +1,7 @@
1
1
  import { VariantProps } from "class-variance-authority";
2
2
  import { useRender } from "@base-ui/react/use-render";
3
3
  declare const badgeVariants: (props?: ({
4
- variant?: "link" | "outline" | "default" | "destructive" | "secondary" | "ghost" | null | undefined;
4
+ variant?: "ghost" | "outline" | "secondary" | "default" | "link" | "destructive" | null | undefined;
5
5
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
6
6
  declare function Badge({ className, variant, render, ...props }: useRender.ComponentProps<"span"> & VariantProps<typeof badgeVariants>): import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>>;
7
7
  export { Badge, badgeVariants };
@@ -3,7 +3,7 @@ import { VariantProps } from "class-variance-authority";
3
3
  import { useRender } from "@base-ui/react/use-render";
4
4
  declare function BubbleGroup({ className, ...props }: React$1.ComponentProps<"div">): React$1.JSX.Element;
5
5
  declare const bubbleVariants: (props?: ({
6
- variant?: "outline" | "default" | "destructive" | "secondary" | "ghost" | "muted" | "tinted" | null | undefined;
6
+ variant?: "ghost" | "outline" | "secondary" | "default" | "destructive" | "muted" | "tinted" | null | undefined;
7
7
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
8
8
  declare function Bubble({ variant, align, className, ...props }: React$1.ComponentProps<"div"> & VariantProps<typeof bubbleVariants> & {
9
9
  align?: "start" | "end";
@@ -1,8 +1,8 @@
1
1
  import { Button as Button$1 } from "@base-ui/react/button";
2
2
  import { VariantProps } from "class-variance-authority";
3
3
  declare const buttonVariants: (props?: ({
4
- variant?: "link" | "outline" | "default" | "destructive" | "secondary" | "ghost" | null | undefined;
5
- size?: "icon" | "default" | "sm" | "lg" | "xs" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
4
+ variant?: "ghost" | "outline" | "secondary" | "default" | "link" | "destructive" | null | undefined;
5
+ size?: "default" | "sm" | "icon" | "lg" | "xs" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
6
6
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
7
7
  declare function Button({ className, variant, size, ...props }: Button$1.Props & VariantProps<typeof buttonVariants>): import("react").JSX.Element;
8
8
  export { Button, buttonVariants };
@@ -2,7 +2,7 @@ import { VariantProps } from "class-variance-authority";
2
2
  declare function Empty({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
3
3
  declare function EmptyHeader({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
4
4
  declare const emptyMediaVariants: (props?: ({
5
- variant?: "icon" | "default" | null | undefined;
5
+ variant?: "default" | "icon" | null | undefined;
6
6
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
7
7
  declare function EmptyMedia({ className, variant, ...props }: React.ComponentProps<"div"> & VariantProps<typeof emptyMediaVariants>): import("react").JSX.Element;
8
8
  declare function EmptyTitle({ className, ...props }: React.ComponentProps<"div">): import("react").JSX.Element;
@@ -10,7 +10,7 @@ declare const itemVariants: (props?: ({
10
10
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
11
11
  declare function Item({ className, variant, size, render, ...props }: useRender.ComponentProps<"div"> & VariantProps<typeof itemVariants>): React$1.ReactElement<unknown, string | React$1.JSXElementConstructor<any>>;
12
12
  declare const itemMediaVariants: (props?: ({
13
- variant?: "image" | "icon" | "default" | null | undefined;
13
+ variant?: "default" | "image" | "icon" | null | undefined;
14
14
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
15
15
  declare function ItemMedia({ className, variant, ...props }: React$1.ComponentProps<"div"> & VariantProps<typeof itemMediaVariants>): React$1.JSX.Element;
16
16
  declare function ItemContent({ className, ...props }: React$1.ComponentProps<"div">): React$1.JSX.Element;
@@ -2,7 +2,7 @@ import * as React$1 from "react";
2
2
  import { VariantProps } from "class-variance-authority";
3
3
  import { useRender } from "@base-ui/react/use-render";
4
4
  declare const markerVariants: (props?: ({
5
- variant?: "separator" | "border" | "default" | null | undefined;
5
+ variant?: "default" | "separator" | "border" | null | undefined;
6
6
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
7
7
  declare function Marker({ className, variant, render, ...props }: useRender.ComponentProps<"div"> & VariantProps<typeof markerVariants>): React$1.ReactElement<unknown, string | React$1.JSXElementConstructor<any>>;
8
8
  declare function MarkerIcon({ className, ...props }: React$1.ComponentProps<"span">): React$1.JSX.Element;
@@ -2,7 +2,7 @@ import { VariantProps } from "class-variance-authority";
2
2
  import { Tabs as Tabs$1 } from "@base-ui/react/tabs";
3
3
  declare function Tabs({ className, orientation, ...props }: Tabs$1.Root.Props): import("react").JSX.Element;
4
4
  declare const tabsListVariants: (props?: ({
5
- variant?: "line" | "default" | null | undefined;
5
+ variant?: "default" | "line" | null | undefined;
6
6
  } & import("class-variance-authority/types").ClassProp) | undefined) => string;
7
7
  declare function TabsList({ className, variant, ...props }: Tabs$1.List.Props & VariantProps<typeof tabsListVariants>): import("react").JSX.Element;
8
8
  declare function TabsTrigger({ className, ...props }: Tabs$1.Tab.Props): import("react").JSX.Element;