mirror of
https://github.com/hanzoai/shadcn.git
synced 2026-11-03 03:18:52 +00:00
13 lines
801 B
JSON
13 lines
801 B
JSON
{
|
|
"name": "input-otp-pattern",
|
|
"registryDependencies": [
|
|
"input-otp"
|
|
],
|
|
"files": [
|
|
{
|
|
"name": "input-otp-pattern.tsx",
|
|
"content": "\"use client\"\n\nimport { REGEXP_ONLY_DIGITS_AND_CHARS } from \"input-otp\"\n\nimport {\n InputOTP,\n InputOTPGroup,\n InputOTPSlot,\n} from \"@/registry/default/ui/input-otp\"\n\nexport default function InputOTPPattern() {\n return (\n <InputOTP maxLength={6} pattern={REGEXP_ONLY_DIGITS_AND_CHARS}>\n <InputOTPGroup>\n <InputOTPSlot index={0} />\n <InputOTPSlot index={1} />\n <InputOTPSlot index={2} />\n <InputOTPSlot index={3} />\n <InputOTPSlot index={4} />\n <InputOTPSlot index={5} />\n </InputOTPGroup>\n </InputOTP>\n )\n}\n"
|
|
}
|
|
],
|
|
"type": "components:example"
|
|
} |