docthub-core-components 2.3.0 → 2.3.6
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/dist/index.esm.js +4218 -16673
- package/dist/registry/@docthub/alert.json +1 -1
- package/dist/registry/@docthub/auto-complete-component.test.json +2 -5
- package/dist/registry/@docthub/avatar.json +3 -3
- package/dist/registry/@docthub/badge.json +1 -1
- package/dist/registry/@docthub/button.json +3 -3
- package/dist/registry/@docthub/button.test.json +2 -5
- package/dist/registry/@docthub/calendar.json +2 -2
- package/dist/registry/@docthub/checkbox.json +3 -3
- package/dist/registry/@docthub/command.json +3 -3
- package/dist/registry/@docthub/dialog.json +1 -1
- package/dist/registry/@docthub/drawer.json +1 -1
- package/dist/registry/@docthub/dropdown-menu.json +3 -3
- package/dist/registry/@docthub/index.json +105 -105
- package/dist/registry/@docthub/input.json +1 -1
- package/dist/registry/@docthub/label.json +3 -3
- package/dist/registry/@docthub/popover.json +3 -3
- package/dist/registry/@docthub/progress.json +3 -3
- package/dist/registry/@docthub/radio-group.json +3 -3
- package/dist/registry/@docthub/select.json +3 -3
- package/dist/registry/@docthub/skeleton.json +1 -1
- package/dist/registry/@docthub/tabs.json +3 -3
- package/dist/registry/@docthub/textarea.json +1 -1
- package/dist/registry/@docthub/toast.json +1 -1
- package/dist/registry/@docthub/toast.test.json +2 -4
- package/dist/registry/@docthub/tooltip.json +3 -3
- package/dist/registry/@docthub/typography.json +2 -2
- package/dist/registry/@docthub/typography.test.json +2 -5
- package/dist/src/components/overrides/ui/auto-complete.d.ts +5 -1
- package/dist/src/components/overrides/ui/autocomplete-checkbox.d.ts +44 -0
- package/dist/src/components/overrides/ui/chips/doct-chip.d.ts +10 -4
- package/dist/src/components/overrides/ui/expandable-card.d.ts +6 -1
- package/dist/src/components/overrides/ui/inputs/labeled-input.d.ts +8 -3
- package/dist/src/components/overrides/ui/inputs/otp-input.d.ts +4 -0
- package/dist/src/components/overrides/ui/inputs/password-input.d.ts +6 -2
- package/dist/src/components/overrides/ui/pickers/date-picker-field.d.ts +9 -9
- package/dist/src/components/overrides/ui/pickers/select-field.d.ts +13 -4
- package/dist/src/components/ui/alert.d.ts +14 -3
- package/dist/src/components/ui/avatar.d.ts +8 -2
- package/dist/src/components/ui/breadcrumb.d.ts +19 -0
- package/dist/src/components/ui/button.d.ts +1 -1
- package/dist/src/components/ui/checkbox.d.ts +1 -1
- package/dist/src/components/ui/collapsible.d.ts +6 -0
- package/dist/src/components/ui/dialog.d.ts +18 -0
- package/dist/src/components/ui/dropdown-menu.d.ts +1 -1
- package/dist/src/components/ui/input.d.ts +5 -1
- package/dist/src/components/ui/label.d.ts +1 -1
- package/dist/src/components/ui/popover.d.ts +1 -1
- package/dist/src/components/ui/progress.d.ts +20 -2
- package/dist/src/components/ui/radio-group.d.ts +1 -1
- package/dist/src/components/ui/select.d.ts +1 -1
- package/dist/src/components/ui/separator.d.ts +4 -0
- package/dist/src/components/ui/sheet.d.ts +25 -0
- package/dist/src/components/ui/sidebar.d.ts +80 -0
- package/dist/src/components/ui/skeleton.d.ts +14 -1
- package/dist/src/components/ui/tabs.d.ts +8 -3
- package/dist/src/components/ui/textarea.d.ts +5 -0
- package/dist/src/components/ui/timeline.d.ts +41 -0
- package/dist/src/components/ui/tooltip.d.ts +6 -2
- package/dist/src/components/ui/typography.d.ts +3 -1
- package/dist/src/hooks/use-mobile.d.ts +1 -0
- package/dist/src/hooks/useAutocompleteCheckbox.d.ts +55 -0
- package/dist/src/index.d.ts +9 -1
- package/dist/style.css +1 -0
- package/package.json +90 -25
- package/dist/docthub-core-components.css +0 -1
- package/dist/index.cjs.js +0 -225
- package/dist/src/components/overrides/ui/pickers/manual-date-picker-field.d.ts +0 -20
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
{
|
|
2
|
-
"type": "registry:ui",
|
|
3
2
|
"name": "select",
|
|
3
|
+
"type": "registry:ui",
|
|
4
4
|
"title": "Select",
|
|
5
5
|
"description": "Select component",
|
|
6
6
|
"dependencies": [
|
|
7
|
-
"radix-ui",
|
|
7
|
+
"@radix-ui/react-select",
|
|
8
8
|
"lucide-react"
|
|
9
9
|
],
|
|
10
10
|
"files": [
|
|
11
11
|
{
|
|
12
12
|
"type": "registry:ui",
|
|
13
13
|
"path": "components/ui/select.tsx",
|
|
14
|
-
"content": "import * as React from \"react\"\r\nimport
|
|
14
|
+
"content": "import * as React from \"react\"\r\nimport * as SelectPrimitive from \"@radix-ui/react-select\"\r\nimport { Check, ChevronDown, ChevronUp } from \"lucide-react\"\r\n\r\nimport { cn } from \"@/lib/utils\"\r\n\r\nconst Select = SelectPrimitive.Root\r\n\r\nconst SelectGroup = SelectPrimitive.Group\r\n\r\nconst SelectValue = SelectPrimitive.Value\r\n\r\nconst SelectTrigger = React.forwardRef<\r\n React.ElementRef<typeof SelectPrimitive.Trigger>,\r\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.Trigger>\r\n>(({ className, children, ...props }, ref) => (\r\n <SelectPrimitive.Trigger\r\n ref={ref}\r\n className={cn(\r\n \"flex h-10 w-full items-center justify-between rounded-md border border-gray-300 bg-background px-3 py-2 text-sm ring-offset-background data-[placeholder]:text-muted-foreground focus:outline-none disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1\",\r\n className\r\n )}\r\n {...props}\r\n >\r\n {children}\r\n <SelectPrimitive.Icon asChild>\r\n <ChevronDown strokeWidth={1.5} className=\"h-4 w-4 text-foreground\" />\r\n </SelectPrimitive.Icon>\r\n </SelectPrimitive.Trigger>\r\n))\r\nSelectTrigger.displayName = SelectPrimitive.Trigger.displayName\r\n\r\nconst SelectScrollUpButton = React.forwardRef<\r\n React.ElementRef<typeof SelectPrimitive.ScrollUpButton>,\r\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.ScrollUpButton>\r\n>(({ className, ...props }, ref) => (\r\n <SelectPrimitive.ScrollUpButton\r\n ref={ref}\r\n className={cn(\r\n \"flex cursor-default items-center justify-center py-1\",\r\n className\r\n )}\r\n {...props}\r\n >\r\n <ChevronUp className=\"h-4 w-4\" />\r\n </SelectPrimitive.ScrollUpButton>\r\n))\r\nSelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName\r\n\r\nconst SelectScrollDownButton = React.forwardRef<\r\n React.ElementRef<typeof SelectPrimitive.ScrollDownButton>,\r\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.ScrollDownButton>\r\n>(({ className, ...props }, ref) => (\r\n <SelectPrimitive.ScrollDownButton\r\n ref={ref}\r\n className={cn(\r\n \"flex cursor-default items-center justify-center py-1\",\r\n className\r\n )}\r\n {...props}\r\n >\r\n <ChevronDown className=\"h-4 w-4\" />\r\n </SelectPrimitive.ScrollDownButton>\r\n))\r\nSelectScrollDownButton.displayName =\r\n SelectPrimitive.ScrollDownButton.displayName\r\n\r\nconst SelectContent = React.forwardRef<\r\n React.ElementRef<typeof SelectPrimitive.Content>,\r\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.Content>\r\n>(({ className, children, position = \"popper\", ...props }, ref) => (\r\n <SelectPrimitive.Portal>\r\n <SelectPrimitive.Content\r\n ref={ref}\r\n className={cn(\r\n \"relative z-50 max-h-[--radix-select-content-available-height] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-select-content-transform-origin]\",\r\n position === \"popper\" &&\r\n \"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1\",\r\n className\r\n )}\r\n position={position}\r\n {...props}\r\n >\r\n <SelectScrollUpButton />\r\n <SelectPrimitive.Viewport\r\n className={cn(\r\n \"p-1\",\r\n position === \"popper\" &&\r\n \"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]\"\r\n )}\r\n >\r\n {children}\r\n </SelectPrimitive.Viewport>\r\n <SelectScrollDownButton />\r\n </SelectPrimitive.Content>\r\n </SelectPrimitive.Portal>\r\n))\r\nSelectContent.displayName = SelectPrimitive.Content.displayName\r\n\r\nconst SelectLabel = React.forwardRef<\r\n React.ElementRef<typeof SelectPrimitive.Label>,\r\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.Label>\r\n>(({ className, ...props }, ref) => (\r\n <SelectPrimitive.Label\r\n ref={ref}\r\n className={cn(\"py-1.5 pl-8 pr-2 text-sm font-semibold\", className)}\r\n {...props}\r\n />\r\n))\r\nSelectLabel.displayName = SelectPrimitive.Label.displayName\r\n\r\nconst SelectItem = React.forwardRef<\r\n React.ElementRef<typeof SelectPrimitive.Item>,\r\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.Item>\r\n>(({ className, children, ...props }, ref) => (\r\n <SelectPrimitive.Item\r\n ref={ref}\r\n className={cn(\r\n \"relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50\",\r\n className\r\n )}\r\n {...props}\r\n >\r\n <span className=\"absolute left-2 flex h-3.5 w-3.5 items-center justify-center\">\r\n <SelectPrimitive.ItemIndicator>\r\n <Check className=\"h-4 w-4\" />\r\n </SelectPrimitive.ItemIndicator>\r\n </span>\r\n\r\n <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>\r\n </SelectPrimitive.Item>\r\n))\r\nSelectItem.displayName = SelectPrimitive.Item.displayName\r\n\r\nconst SelectSeparator = React.forwardRef<\r\n React.ElementRef<typeof SelectPrimitive.Separator>,\r\n React.ComponentPropsWithoutRef<typeof SelectPrimitive.Separator>\r\n>(({ className, ...props }, ref) => (\r\n <SelectPrimitive.Separator\r\n ref={ref}\r\n className={cn(\"-mx-1 my-1 h-px bg-muted\", className)}\r\n {...props}\r\n />\r\n))\r\nSelectSeparator.displayName = SelectPrimitive.Separator.displayName\r\n\r\nexport {\r\n Select,\r\n SelectGroup,\r\n SelectValue,\r\n SelectTrigger,\r\n SelectContent,\r\n SelectLabel,\r\n SelectItem,\r\n SelectSeparator,\r\n SelectScrollUpButton,\r\n SelectScrollDownButton,\r\n}\r\n"
|
|
15
15
|
}
|
|
16
16
|
]
|
|
17
17
|
}
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
{
|
|
2
|
-
"type": "registry:ui",
|
|
3
2
|
"name": "tabs",
|
|
3
|
+
"type": "registry:ui",
|
|
4
4
|
"title": "Tabs",
|
|
5
5
|
"description": "Tabs component",
|
|
6
6
|
"dependencies": [
|
|
7
|
-
"radix-ui"
|
|
7
|
+
"@radix-ui/react-tabs"
|
|
8
8
|
],
|
|
9
9
|
"files": [
|
|
10
10
|
{
|
|
11
11
|
"type": "registry:ui",
|
|
12
12
|
"path": "components/ui/tabs.tsx",
|
|
13
|
-
"content": "import * as React from \"react\"\r\nimport
|
|
13
|
+
"content": "import * as React from \"react\"\r\nimport * as TabsPrimitive from \"@radix-ui/react-tabs\"\r\n\r\nimport { cn } from \"@/lib/utils\"\r\n\r\nconst Tabs = TabsPrimitive.Root\r\n\r\nconst TabsList = React.forwardRef<\r\n React.ElementRef<typeof TabsPrimitive.List>,\r\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.List>\r\n>(({ className, ...props }, ref) => (\r\n <TabsPrimitive.List\r\n ref={ref}\r\n className={cn(\r\n \"inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground\",\r\n className\r\n )}\r\n {...props}\r\n />\r\n))\r\nTabsList.displayName = TabsPrimitive.List.displayName\r\n\r\nconst TabsTrigger = React.forwardRef<\r\n React.ElementRef<typeof TabsPrimitive.Trigger>,\r\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger>\r\n>(({ className, ...props }, ref) => (\r\n <TabsPrimitive.Trigger\r\n ref={ref}\r\n className={cn(\r\n \"inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm\",\r\n className\r\n )}\r\n {...props}\r\n />\r\n))\r\nTabsTrigger.displayName = TabsPrimitive.Trigger.displayName\r\n\r\nconst TabsContent = React.forwardRef<\r\n React.ElementRef<typeof TabsPrimitive.Content>,\r\n React.ComponentPropsWithoutRef<typeof TabsPrimitive.Content>\r\n>(({ className, ...props }, ref) => (\r\n <TabsPrimitive.Content\r\n ref={ref}\r\n className={cn(\r\n \"mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2\",\r\n className\r\n )}\r\n {...props}\r\n />\r\n))\r\nTabsContent.displayName = TabsPrimitive.Content.displayName\r\n\r\nexport { Tabs, TabsList, TabsTrigger, TabsContent }\r\n"
|
|
14
14
|
}
|
|
15
15
|
]
|
|
16
16
|
}
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
{
|
|
2
|
-
"type": "registry:ui",
|
|
3
2
|
"name": "toast.test",
|
|
3
|
+
"type": "registry:ui",
|
|
4
4
|
"title": "Toast.test",
|
|
5
5
|
"description": "Toast.test component",
|
|
6
|
-
"dependencies": [
|
|
7
|
-
"@testing-library/react"
|
|
8
|
-
],
|
|
6
|
+
"dependencies": [],
|
|
9
7
|
"files": [
|
|
10
8
|
{
|
|
11
9
|
"type": "registry:ui",
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
{
|
|
2
|
-
"type": "registry:ui",
|
|
3
2
|
"name": "tooltip",
|
|
3
|
+
"type": "registry:ui",
|
|
4
4
|
"title": "Tooltip",
|
|
5
5
|
"description": "Tooltip component",
|
|
6
6
|
"dependencies": [
|
|
7
|
-
"radix-ui"
|
|
7
|
+
"@radix-ui/react-tooltip"
|
|
8
8
|
],
|
|
9
9
|
"files": [
|
|
10
10
|
{
|
|
11
11
|
"type": "registry:ui",
|
|
12
12
|
"path": "components/ui/tooltip.tsx",
|
|
13
|
-
"content": "import * as React from \"react\";\r\nimport
|
|
13
|
+
"content": "import * as React from \"react\";\r\nimport * as TooltipPrimitive from \"@radix-ui/react-tooltip\";\r\nimport { cn } from \"@/lib/utils\";\r\n\r\nconst TooltipProvider = TooltipPrimitive.Provider;\r\nconst Tooltip = TooltipPrimitive.Root;\r\nconst TooltipTrigger = TooltipPrimitive.Trigger;\r\n\r\nconst TooltipContent = React.forwardRef<\r\n React.ElementRef<typeof TooltipPrimitive.Content>,\r\n React.ComponentPropsWithoutRef<typeof TooltipPrimitive.Content>\r\n>(({ className, sideOffset = 4, children, ...props }, ref) => (\r\n <TooltipPrimitive.Content\r\n ref={ref}\r\n sideOffset={sideOffset}\r\n className={cn(\r\n \"z-50 rounded-xl border border-border bg-background px-3 py-1.5 text-sm text-foreground shadow-xl transition-all\",\r\n \"animate-in fade-in zoom-in-95\",\r\n \"data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95\",\r\n \"data-[side=bottom]:slide-in-from-top-2\",\r\n \"data-[side=left]:slide-in-from-right-2\",\r\n \"data-[side=right]:slide-in-from-left-2\",\r\n \"data-[side=top]:slide-in-from-bottom-2\",\r\n \"origin-[--radix-tooltip-content-transform-origin]\",\r\n className\r\n )}\r\n {...props}\r\n >\r\n {children}\r\n <TooltipPrimitive.Arrow className=\"fill-background stroke-border h-2 w-4\" />\r\n </TooltipPrimitive.Content>\r\n));\r\nTooltipContent.displayName = TooltipPrimitive.Content.displayName;\r\n\r\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\r\n"
|
|
14
14
|
}
|
|
15
15
|
]
|
|
16
16
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
|
-
"type": "registry:ui",
|
|
3
2
|
"name": "typography",
|
|
3
|
+
"type": "registry:ui",
|
|
4
4
|
"title": "Typography",
|
|
5
5
|
"description": "Typography component",
|
|
6
6
|
"dependencies": [],
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
{
|
|
9
9
|
"type": "registry:ui",
|
|
10
10
|
"path": "components/ui/typography.tsx",
|
|
11
|
-
"content": "import React from \"react\";\r\n\r\nexport interface DoctTypographyProps {\r\n variant:\r\n | \"h1\"\r\n | \"h2\"\r\n | \"h3\"\r\n | \"h4\"\r\n | \"h5\"\r\n | \"h6\"\r\n | \"h7\"\r\n | \"h8\"\r\n | \"title1\"\r\n | \"title2\"\r\n | \"title3\"\r\n | \"title4\"\r\n | \"body1\"\r\n | \"body2\"\r\n | \"body3\"\r\n | \"body4\"\r\n | \"textLabel1\"\r\n | \"textLabel2\"\r\n | \"textLabel3\"\r\n | \"textLabel4\";\r\n weight?: \"regular\" | \"medium\" | \"semiBold\" | \"bold\" | \"extraBold\" | \"light\";\r\n children: React.ReactNode;\r\n color?: string;\r\n align?: \"inherit\" | \"left\" | \"center\" | \"right\" | \"justify\";\r\n className?: string;\r\n}\r\n\r\nconst typographyStyles: Record<\r\n DoctTypographyProps[\"variant\"],\r\n { fontSize: string; tag: keyof JSX.IntrinsicElements }\r\n> = {\r\n h1: { fontSize: \"3.5rem\", tag: \"h1\" },\r\n h2: { fontSize: \"2.875rem\", tag: \"h2\" },\r\n h3: { fontSize: \"2.25rem\", tag: \"h3\" },\r\n h4: { fontSize: \"2rem\", tag: \"h4\" }, // 32px -> 2rem\r\n h5: { fontSize: \"1.75rem\", tag: \"h5\" }, // 28px -> 1.75rem\r\n h6: { fontSize: \"1.5rem\", tag: \"h6\" }, // 24px -> 1.5rem\r\n h7: { fontSize: \"1.25rem\", tag: \"p\" }, // 20px -> 1.25rem\r\n h8: { fontSize: \"1.125rem\", tag: \"p\" }, // 18px -> 1.125rem\r\n title1: { fontSize: \"1.375rem\", tag: \"p\" }, // 22px -> 1.375rem\r\n title2: { fontSize: \"1.125rem\", tag: \"p\" }, // 18px -> 1.125rem\r\n title3: { fontSize: \"0.875rem\", tag: \"p\" }, // 14px -> 0.875rem\r\n title4: { fontSize: \"0.75rem\", tag: \"p\" }, // 12px -> 0.75rem\r\n body1: { fontSize: \"1rem\", tag: \"p\" }, // 16px -> 1rem\r\n body2: { fontSize: \"0.875rem\", tag: \"p\" }, // 14px -> 0.875rem\r\n body3: { fontSize: \"0.75rem\", tag: \"p\" }, // 12px -> 0.75rem\r\n body4: { fontSize: \"0.625rem\", tag: \"p\" }, // 10px -> 0.625rem\r\n textLabel1: { fontSize: \"1rem\", tag: \"span\" }, // 16px -> 1rem\r\n textLabel2: { fontSize: \"0.875rem\", tag: \"span\" }, // 14px -> 0.875rem\r\n textLabel3: { fontSize: \"0.75rem\", tag: \"span\" }, // 12px -> 0.75rem\r\n textLabel4: { fontSize: \"0.6875rem\", tag: \"span\" }, // 11px -> 0.6875rem\r\n};\r\n\r\nconst fontWeights: Record<string, string> = {\r\n regular: \"400\",\r\n medium: \"500\",\r\n semiBold: \"600\",\r\n bold: \"700\",\r\n extraBold: \"800\",\r\n light: \"300\",\r\n};\r\n\r\nconst DoctTypography: React.FC<DoctTypographyProps> = ({\r\n variant,\r\n weight = \"regular\",\r\n children,\r\n color = \"#000\",\r\n align = \"inherit\",\r\n className = \"\",\r\n}) => {\r\n const typographyStyle = typographyStyles[variant] ?? {\r\n fontSize: \"16px\",\r\n tag: \"p\",\r\n };\r\n const { fontSize, tag: Tag } = typographyStyle;\r\n\r\n return (\r\n <Tag\r\n className={className}\r\n style={{\r\n fontSize,\r\n fontWeight: fontWeights[weight] ?? \"400\",\r\n color,\r\n textAlign: align,\r\n }}\r\n >\r\n {children}\r\n </Tag>\r\n );\r\n};\r\n\r\nexport { DoctTypography };\r\n"
|
|
11
|
+
"content": "import React from \"react\";\r\n\r\nexport interface DoctTypographyProps {\r\n variant:\r\n | \"h1\"\r\n | \"h2\"\r\n | \"h3\"\r\n | \"h4\"\r\n | \"h5\"\r\n | \"h6\"\r\n | \"h7\"\r\n | \"h8\"\r\n | \"title1\"\r\n | \"title2\"\r\n | \"title3\"\r\n | \"title4\"\r\n | \"body1\"\r\n | \"body2\"\r\n | \"body3\"\r\n | \"body4\"\r\n | \"textLabel1\"\r\n | \"textLabel2\"\r\n | \"textLabel3\"\r\n | \"textLabel4\";\r\n weight?: \"regular\" | \"medium\" | \"semiBold\" | \"bold\" | \"extraBold\" | \"light\";\r\n children: React.ReactNode;\r\n color?: string;\r\n align?: \"inherit\" | \"left\" | \"center\" | \"right\" | \"justify\";\r\n className?: string;\r\n}\r\n\r\nconst typographyStyles: Record<\r\n DoctTypographyProps[\"variant\"],\r\n { fontSize: string; tag: keyof React.JSX.IntrinsicElements }\r\n> = {\r\n h1: { fontSize: \"3.5rem\", tag: \"h1\" },\r\n h2: { fontSize: \"2.875rem\", tag: \"h2\" },\r\n h3: { fontSize: \"2.25rem\", tag: \"h3\" },\r\n h4: { fontSize: \"2rem\", tag: \"h4\" }, // 32px -> 2rem\r\n h5: { fontSize: \"1.75rem\", tag: \"h5\" }, // 28px -> 1.75rem\r\n h6: { fontSize: \"1.5rem\", tag: \"h6\" }, // 24px -> 1.5rem\r\n h7: { fontSize: \"1.25rem\", tag: \"p\" }, // 20px -> 1.25rem\r\n h8: { fontSize: \"1.125rem\", tag: \"p\" }, // 18px -> 1.125rem\r\n title1: { fontSize: \"1.375rem\", tag: \"p\" }, // 22px -> 1.375rem\r\n title2: { fontSize: \"1.125rem\", tag: \"p\" }, // 18px -> 1.125rem\r\n title3: { fontSize: \"0.875rem\", tag: \"p\" }, // 14px -> 0.875rem\r\n title4: { fontSize: \"0.75rem\", tag: \"p\" }, // 12px -> 0.75rem\r\n body1: { fontSize: \"1rem\", tag: \"p\" }, // 16px -> 1rem\r\n body2: { fontSize: \"0.875rem\", tag: \"p\" }, // 14px -> 0.875rem\r\n body3: { fontSize: \"0.75rem\", tag: \"p\" }, // 12px -> 0.75rem\r\n body4: { fontSize: \"0.625rem\", tag: \"p\" }, // 10px -> 0.625rem\r\n textLabel1: { fontSize: \"1rem\", tag: \"span\" }, // 16px -> 1rem\r\n textLabel2: { fontSize: \"0.875rem\", tag: \"span\" }, // 14px -> 0.875rem\r\n textLabel3: { fontSize: \"0.75rem\", tag: \"span\" }, // 12px -> 0.75rem\r\n textLabel4: { fontSize: \"0.6875rem\", tag: \"span\" }, // 11px -> 0.6875rem\r\n};\r\n\r\nconst fontWeights: Record<string, string> = {\r\n regular: \"400\",\r\n medium: \"500\",\r\n semiBold: \"600\",\r\n bold: \"700\",\r\n extraBold: \"800\",\r\n light: \"300\",\r\n};\r\n\r\nconst DoctTypography: React.FC<DoctTypographyProps> = ({\r\n variant,\r\n weight = \"regular\",\r\n children,\r\n color = \"#000\",\r\n align = \"inherit\",\r\n className = \"\",\r\n}) => {\r\n const typographyStyle = typographyStyles[variant] ?? {\r\n fontSize: \"16px\",\r\n tag: \"p\",\r\n };\r\n const { fontSize, tag: Tag } = typographyStyle;\r\n\r\n return (\r\n <Tag\r\n className={className}\r\n style={{\r\n fontSize,\r\n fontWeight: fontWeights[weight] ?? \"400\",\r\n color,\r\n textAlign: align,\r\n }}\r\n >\r\n {children}\r\n </Tag>\r\n );\r\n};\r\n\r\nexport { DoctTypography };\r\n"
|
|
12
12
|
}
|
|
13
13
|
]
|
|
14
14
|
}
|
|
@@ -1,12 +1,9 @@
|
|
|
1
1
|
{
|
|
2
|
-
"type": "registry:ui",
|
|
3
2
|
"name": "typography.test",
|
|
3
|
+
"type": "registry:ui",
|
|
4
4
|
"title": "Typography.test",
|
|
5
5
|
"description": "Typography.test component",
|
|
6
|
-
"dependencies": [
|
|
7
|
-
"@testing-library/react",
|
|
8
|
-
"vitest"
|
|
9
|
-
],
|
|
6
|
+
"dependencies": [],
|
|
10
7
|
"files": [
|
|
11
8
|
{
|
|
12
9
|
"type": "registry:ui",
|
|
@@ -42,6 +42,10 @@ interface AutocompleteProps<T> {
|
|
|
42
42
|
emptyMessage?: string;
|
|
43
43
|
className?: string;
|
|
44
44
|
inputClassName?: string;
|
|
45
|
+
debounceMs?: number;
|
|
46
|
+
minSearchLength?: number;
|
|
47
|
+
/** Control built-in bolding of matched query segments (default: false) */
|
|
48
|
+
ntt?: boolean;
|
|
45
49
|
}
|
|
46
|
-
export declare const DoctAutocomplete: <T extends OptionType>({ options, dataSource, value, onChange, change, onInputChange, placeholder, multiple, freeSolo, disabled, loading, size, variant, label, helperText, error, required, fullWidth, clearable, disableCloseOnSelect, filterOptions, getOptionLabel, getOptionValue, isOptionEqualToValue, renderOption, renderTags, fields, noOptionsText, emptyMessage, className, inputClassName, ...props }: AutocompleteProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
50
|
+
export declare const DoctAutocomplete: <T extends OptionType>({ options, dataSource, value, onChange, change, onInputChange, placeholder, multiple, freeSolo, disabled, loading, size, variant, label, helperText, error, required, fullWidth, clearable, disableCloseOnSelect, filterOptions, getOptionLabel, getOptionValue, isOptionEqualToValue, renderOption, renderTags, fields, noOptionsText, emptyMessage, className, inputClassName, debounceMs, minSearchLength, ntt, ...props }: AutocompleteProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
47
51
|
export {};
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { OptionType } from '../../../hooks/useAutocompleteCheckbox';
|
|
3
|
+
export interface AutocompleteCheckboxProps<T = unknown> {
|
|
4
|
+
options: T[];
|
|
5
|
+
value?: T[];
|
|
6
|
+
onChange?: (event: React.SyntheticEvent | null, value: T[]) => void;
|
|
7
|
+
onInputChange?: (event: React.ChangeEvent<HTMLInputElement>, value: string) => void;
|
|
8
|
+
placeholder?: string;
|
|
9
|
+
label?: string;
|
|
10
|
+
helperText?: string;
|
|
11
|
+
error?: string;
|
|
12
|
+
noOptionsText?: string;
|
|
13
|
+
emptyMessage?: string;
|
|
14
|
+
disabled?: boolean;
|
|
15
|
+
loading?: boolean;
|
|
16
|
+
required?: boolean;
|
|
17
|
+
clearable?: boolean;
|
|
18
|
+
disableCloseOnSelect?: boolean;
|
|
19
|
+
freeSolo?: T extends string ? boolean : never;
|
|
20
|
+
size?: "small" | "medium" | "large";
|
|
21
|
+
variant?: "outlined" | "filled" | "standard";
|
|
22
|
+
fullWidth?: boolean;
|
|
23
|
+
className?: string;
|
|
24
|
+
inputClassName?: string;
|
|
25
|
+
getOptionLabel?: (option: T) => string;
|
|
26
|
+
getOptionValue?: (option: T) => string | T;
|
|
27
|
+
isOptionEqualToValue?: (option: T, value: T) => boolean;
|
|
28
|
+
filterOptions?: (options: T[], state: {
|
|
29
|
+
inputValue: string;
|
|
30
|
+
}) => T[];
|
|
31
|
+
renderOption?: (option: T, index: number) => React.ReactNode;
|
|
32
|
+
renderTags?: (value: T[], handleTagRemove: (tag: T) => void) => React.ReactNode;
|
|
33
|
+
limitTags?: number;
|
|
34
|
+
fields?: {
|
|
35
|
+
value: string | number;
|
|
36
|
+
text: string;
|
|
37
|
+
};
|
|
38
|
+
dataSource?: T[];
|
|
39
|
+
change?: (event: {
|
|
40
|
+
itemData: T[];
|
|
41
|
+
}) => void;
|
|
42
|
+
}
|
|
43
|
+
export declare function AutocompleteCheckbox<T extends OptionType>({ options, dataSource, value, onChange, change, onInputChange, placeholder, label, helperText, error, noOptionsText, emptyMessage, disabled, loading, required, clearable, disableCloseOnSelect, freeSolo, size, variant, fullWidth, className, inputClassName, getOptionLabel, getOptionValue, isOptionEqualToValue, filterOptions, renderOption, renderTags, limitTags, fields, }: AutocompleteCheckboxProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
44
|
+
export default AutocompleteCheckbox;
|
|
@@ -1,16 +1,22 @@
|
|
|
1
|
-
import { ReactNode, MouseEvent, FC } from 'react';
|
|
1
|
+
import { ReactNode, MouseEvent, KeyboardEvent, FC } from 'react';
|
|
2
2
|
export interface ChipProps {
|
|
3
3
|
label: string;
|
|
4
|
-
variant?: "filled" | "outlined";
|
|
4
|
+
variant?: "filled" | "outlined" | "soft";
|
|
5
5
|
color?: "default" | "primary" | "secondary" | "success" | "warning" | "error";
|
|
6
6
|
size?: "small" | "medium" | "large";
|
|
7
|
+
/** Chip corner style */
|
|
8
|
+
shape?: "pill" | "square";
|
|
7
9
|
deletable?: boolean;
|
|
8
|
-
onDelete?: (e: MouseEvent<HTMLButtonElement>) => void;
|
|
9
|
-
onClick?: (e: MouseEvent<HTMLDivElement>) => void;
|
|
10
|
+
onDelete?: (e: MouseEvent<HTMLButtonElement> | KeyboardEvent<HTMLButtonElement>) => void;
|
|
11
|
+
onClick?: (e: MouseEvent<HTMLDivElement> | KeyboardEvent<HTMLDivElement>) => void;
|
|
10
12
|
icon?: ReactNode;
|
|
11
13
|
avatar?: ReactNode | string;
|
|
12
14
|
disabled?: boolean;
|
|
13
15
|
className?: string;
|
|
16
|
+
/** ARIA label for the chip */
|
|
17
|
+
"aria-label"?: string;
|
|
18
|
+
/** ARIA label for the delete button */
|
|
19
|
+
deleteAriaLabel?: string;
|
|
14
20
|
}
|
|
15
21
|
export declare const Chip: FC<ChipProps>;
|
|
16
22
|
export interface ChipsContainerProps {
|
|
@@ -4,9 +4,14 @@ interface ExpandableCardProps {
|
|
|
4
4
|
title: React.ReactNode;
|
|
5
5
|
content: React.ReactNode;
|
|
6
6
|
defaultOpen?: boolean;
|
|
7
|
+
open?: boolean;
|
|
8
|
+
onOpenChange?: (open: boolean) => void;
|
|
7
9
|
className?: string;
|
|
8
10
|
titleTypographyProps?: Partial<DoctTypographyProps>;
|
|
9
11
|
contentTypographyProps?: Partial<DoctTypographyProps>;
|
|
12
|
+
animationDuration?: number;
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
clickableArea?: "full" | "header" | "button";
|
|
10
15
|
}
|
|
11
|
-
export declare function ExpandableCard({ title, content, defaultOpen, className, titleTypographyProps, contentTypographyProps, }: ExpandableCardProps): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
export declare function ExpandableCard({ title, content, defaultOpen, open: controlledOpen, onOpenChange, className, titleTypographyProps, contentTypographyProps, animationDuration, disabled, clickableArea, }: ExpandableCardProps): import("react/jsx-runtime").JSX.Element;
|
|
12
17
|
export {};
|
|
@@ -1,21 +1,26 @@
|
|
|
1
1
|
import { FC, ReactNode } from 'react';
|
|
2
|
-
interface LabeledInputProps extends React.
|
|
2
|
+
interface LabeledInputProps extends React.InputHTMLAttributes<HTMLInputElement> {
|
|
3
3
|
label?: string;
|
|
4
4
|
placeholder?: string;
|
|
5
5
|
helperText?: string;
|
|
6
6
|
error?: string;
|
|
7
7
|
required?: boolean;
|
|
8
|
-
type?: "text" | "email" | "password" | "number" | "tel";
|
|
8
|
+
type?: "text" | "email" | "password" | "number" | "tel" | "url" | "search";
|
|
9
9
|
leftIcon?: ReactNode;
|
|
10
10
|
rightIcon?: ReactNode;
|
|
11
11
|
className?: string;
|
|
12
12
|
inputClassName?: string;
|
|
13
13
|
onChange?: (e: React.ChangeEvent<HTMLInputElement>) => void;
|
|
14
|
+
onValueChange?: (value: string) => void;
|
|
14
15
|
showCharCount?: boolean;
|
|
15
16
|
maxLength?: number;
|
|
16
|
-
|
|
17
|
+
characterLimit?: number;
|
|
17
18
|
disabled?: boolean;
|
|
19
|
+
readOnly?: boolean;
|
|
20
|
+
/** @deprecated Use `readOnly` instead. Will be removed in v3.0 */
|
|
18
21
|
fridged?: boolean;
|
|
22
|
+
"aria-label"?: string;
|
|
23
|
+
"aria-describedby"?: string;
|
|
19
24
|
}
|
|
20
25
|
export declare const LabeledInput: FC<LabeledInputProps>;
|
|
21
26
|
export {};
|
|
@@ -7,6 +7,10 @@ interface OtpInputProps {
|
|
|
7
7
|
className?: string;
|
|
8
8
|
error?: string;
|
|
9
9
|
inputClassName?: string;
|
|
10
|
+
autoFocus?: boolean;
|
|
11
|
+
autoSubmit?: boolean;
|
|
12
|
+
secure?: boolean;
|
|
13
|
+
"aria-label"?: string;
|
|
10
14
|
}
|
|
11
15
|
export declare const OtpInput: React.FC<OtpInputProps>;
|
|
12
16
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
interface PasswordInputProps extends Omit<React.HTMLAttributes<HTMLInputElement>,
|
|
1
|
+
interface PasswordInputProps extends Omit<React.HTMLAttributes<HTMLInputElement>, "onChange"> {
|
|
2
2
|
label?: string;
|
|
3
3
|
placeholder?: string;
|
|
4
4
|
helperText?: string;
|
|
@@ -9,6 +9,10 @@ interface PasswordInputProps extends Omit<React.HTMLAttributes<HTMLInputElement>
|
|
|
9
9
|
onShowPasswordChange?: (show: boolean) => void;
|
|
10
10
|
value?: string;
|
|
11
11
|
onChange?: (value: string) => void;
|
|
12
|
+
onChangeEvent?: (e: React.ChangeEvent<HTMLInputElement>) => void;
|
|
13
|
+
onValueChange?: (value: string) => void;
|
|
14
|
+
autoComplete?: string;
|
|
15
|
+
"aria-label"?: string;
|
|
12
16
|
}
|
|
13
|
-
export declare function PasswordInput({ label, placeholder, helperText, error, required, className, showPassword, onShowPasswordChange, value, onChange, ...restProps }: PasswordInputProps): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export declare function PasswordInput({ label, placeholder, helperText, error, required, className, showPassword, onShowPasswordChange, value, onChange, onChangeEvent, onValueChange, autoComplete, ...restProps }: PasswordInputProps): import("react/jsx-runtime").JSX.Element;
|
|
14
18
|
export {};
|
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
import { DayPickerSingleProps } from 'react-day-picker';
|
|
2
2
|
import * as React from "react";
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
* - All custom props are explicit.
|
|
6
|
-
* - Extra DayPicker props can be passed via ...dayPickerProps.
|
|
7
|
-
* - All extra HTML div props can be passed via ...rest.
|
|
8
|
-
*/
|
|
9
|
-
export interface DatePickerFieldProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "onSelect"> {
|
|
3
|
+
export type DateFormat = "MM/DD/YYYY" | "DD/MM/YYYY" | "YYYY-MM-DD" | "DD-MM-YYYY";
|
|
4
|
+
export interface DatePickerFieldProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "onSelect" | "onChange"> {
|
|
10
5
|
label?: string;
|
|
11
6
|
placeholder?: string;
|
|
12
7
|
helperText?: string;
|
|
13
|
-
error?: string;
|
|
14
8
|
required?: boolean;
|
|
15
9
|
value?: Date;
|
|
16
10
|
onSelect?: (date: Date | undefined) => void;
|
|
11
|
+
onChange?: (date: Date | undefined) => void;
|
|
17
12
|
className?: string;
|
|
18
13
|
minDate?: Date;
|
|
19
14
|
maxDate?: Date;
|
|
20
15
|
disabled?: boolean;
|
|
21
16
|
readOnly?: boolean;
|
|
22
17
|
locale?: string;
|
|
18
|
+
dateFormat?: DateFormat;
|
|
19
|
+
inputClassName?: string;
|
|
20
|
+
error?: string;
|
|
23
21
|
showOutsideDays?: boolean;
|
|
24
|
-
|
|
22
|
+
clearable?: boolean;
|
|
25
23
|
month?: Date;
|
|
26
24
|
onMonthChange?: (month: Date) => void;
|
|
27
25
|
open?: boolean;
|
|
28
26
|
onOpenChange?: (open: boolean) => void;
|
|
27
|
+
dayPickerProps?: Partial<DayPickerSingleProps>;
|
|
28
|
+
manual?: boolean;
|
|
29
29
|
}
|
|
30
30
|
export declare const DatePickerField: React.FC<DatePickerFieldProps>;
|
|
@@ -2,21 +2,30 @@ import { ReactNode } from 'react';
|
|
|
2
2
|
interface SelectOption {
|
|
3
3
|
value: string;
|
|
4
4
|
label: string;
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
group?: string;
|
|
5
7
|
}
|
|
6
8
|
interface SelectFieldProps {
|
|
7
9
|
label?: string;
|
|
8
10
|
placeholder?: string;
|
|
9
11
|
options: SelectOption[];
|
|
10
12
|
value?: string;
|
|
13
|
+
onValueChange?: (value: string) => void;
|
|
14
|
+
onChange?: (value: string) => void;
|
|
11
15
|
leadingIcon?: ReactNode;
|
|
16
|
+
trailingIcon?: ReactNode;
|
|
17
|
+
startIcon?: ReactNode;
|
|
18
|
+
endIcon?: ReactNode;
|
|
12
19
|
helperText?: string;
|
|
13
20
|
error?: string;
|
|
14
21
|
required?: boolean;
|
|
15
|
-
onValueChange?: (value: string) => void;
|
|
16
|
-
className?: string;
|
|
17
|
-
variant?: "default" | "gray";
|
|
18
22
|
disabled?: boolean;
|
|
23
|
+
loading?: boolean;
|
|
19
24
|
clearable?: boolean;
|
|
25
|
+
className?: string;
|
|
26
|
+
variant?: "default" | "gray";
|
|
27
|
+
"aria-label"?: string;
|
|
28
|
+
"aria-describedby"?: string;
|
|
20
29
|
}
|
|
21
|
-
export declare function SelectField({ label, placeholder, options, value, leadingIcon, helperText, error, required,
|
|
30
|
+
export declare function SelectField({ label, placeholder, options, value, onValueChange, onChange, leadingIcon, trailingIcon, startIcon, endIcon, helperText, error, required, disabled, loading, clearable, className, variant, }: SelectFieldProps): import("react/jsx-runtime").JSX.Element;
|
|
22
31
|
export {};
|
|
@@ -1,8 +1,19 @@
|
|
|
1
1
|
import { VariantProps } from 'class-variance-authority';
|
|
2
2
|
import * as React from "react";
|
|
3
|
-
declare const
|
|
4
|
-
variant?: "default" | "destructive" | null | undefined;
|
|
5
|
-
} & import('class-variance-authority/types').ClassProp) | undefined) => string
|
|
3
|
+
declare const alertVariants: (props?: ({
|
|
4
|
+
variant?: "default" | "error" | "success" | "warning" | "destructive" | "info" | null | undefined;
|
|
5
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
6
|
+
export interface AlertProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof alertVariants> {
|
|
7
|
+
/** Custom icon to display. Set to false to hide icon. */
|
|
8
|
+
icon?: React.ReactNode | false;
|
|
9
|
+
/** Callback when alert is dismissed */
|
|
10
|
+
onClose?: () => void;
|
|
11
|
+
/** Custom action element (e.g., button) */
|
|
12
|
+
action?: React.ReactNode;
|
|
13
|
+
/** Alias for variant (MUI compatibility) */
|
|
14
|
+
severity?: VariantProps<typeof alertVariants>["variant"];
|
|
15
|
+
}
|
|
16
|
+
declare const Alert: React.ForwardRefExoticComponent<AlertProps & React.RefAttributes<HTMLDivElement>>;
|
|
6
17
|
declare const AlertTitle: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLHeadingElement> & React.RefAttributes<HTMLHeadingElement>>;
|
|
7
18
|
declare const AlertDescription: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLParagraphElement> & React.RefAttributes<HTMLParagraphElement>>;
|
|
8
19
|
export { Alert, AlertTitle, AlertDescription };
|
|
@@ -1,6 +1,12 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { VariantProps } from 'class-variance-authority';
|
|
2
2
|
import * as React from "react";
|
|
3
|
-
|
|
3
|
+
import * as AvatarPrimitive from "@radix-ui/react-avatar";
|
|
4
|
+
declare const avatarVariants: (props?: ({
|
|
5
|
+
size?: "sm" | "md" | "lg" | "xl" | null | undefined;
|
|
6
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
7
|
+
export interface AvatarProps extends React.ComponentPropsWithoutRef<typeof AvatarPrimitive.Root>, VariantProps<typeof avatarVariants> {
|
|
8
|
+
}
|
|
9
|
+
declare const Avatar: React.ForwardRefExoticComponent<AvatarProps & React.RefAttributes<HTMLSpanElement>>;
|
|
4
10
|
declare const AvatarImage: React.ForwardRefExoticComponent<Omit<AvatarPrimitive.AvatarImageProps & React.RefAttributes<HTMLImageElement>, "ref"> & React.RefAttributes<HTMLImageElement>>;
|
|
5
11
|
declare const AvatarFallback: React.ForwardRefExoticComponent<Omit<AvatarPrimitive.AvatarFallbackProps & React.RefAttributes<HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
|
6
12
|
export { Avatar, AvatarImage, AvatarFallback };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
declare const Breadcrumb: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
|
|
3
|
+
separator?: React.ReactNode;
|
|
4
|
+
} & React.RefAttributes<HTMLElement>>;
|
|
5
|
+
declare const BreadcrumbList: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.OlHTMLAttributes<HTMLOListElement>, HTMLOListElement>, "ref"> & React.RefAttributes<HTMLOListElement>>;
|
|
6
|
+
declare const BreadcrumbItem: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
|
|
7
|
+
declare const BreadcrumbLink: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "ref"> & {
|
|
8
|
+
asChild?: boolean;
|
|
9
|
+
} & React.RefAttributes<HTMLAnchorElement>>;
|
|
10
|
+
declare const BreadcrumbPage: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
|
11
|
+
declare const BreadcrumbSeparator: {
|
|
12
|
+
({ children, className, ...props }: React.ComponentProps<"li">): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
displayName: string;
|
|
14
|
+
};
|
|
15
|
+
declare const BreadcrumbEllipsis: {
|
|
16
|
+
({ className, ...props }: React.ComponentProps<"span">): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
displayName: string;
|
|
18
|
+
};
|
|
19
|
+
export { Breadcrumb, BreadcrumbList, BreadcrumbItem, BreadcrumbLink, BreadcrumbPage, BreadcrumbSeparator, BreadcrumbEllipsis, };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { VariantProps } from 'class-variance-authority';
|
|
2
2
|
import { default as React } from 'react';
|
|
3
3
|
declare const DoctButtonVariants: (props?: ({
|
|
4
|
-
variant?: "default" | "outline" | "ghost" | "error" | "success" | "warning" | "blue" | "disabled" | "brandBlue" | "primary" | null | undefined;
|
|
4
|
+
variant?: "default" | "outline" | "ghost" | "error" | "success" | "warning" | "blue" | "disabled" | "brandBlue" | "primary" | "namya" | null | undefined;
|
|
5
5
|
size?: "small" | "large" | "medium" | "icon.large" | "icon.medium" | "icon.small" | null | undefined;
|
|
6
6
|
iconSize?: "small" | "large" | "medium" | null | undefined;
|
|
7
7
|
iconPosition?: "left" | "right" | null | undefined;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Checkbox as CheckboxPrimitive } from 'radix-ui';
|
|
2
1
|
import * as React from "react";
|
|
2
|
+
import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
|
|
3
3
|
export interface CheckboxProps extends React.ComponentPropsWithoutRef<typeof CheckboxPrimitive.Root> {
|
|
4
4
|
color?: string;
|
|
5
5
|
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import * as CollapsiblePrimitive from "@radix-ui/react-collapsible";
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
declare const Collapsible: React.ForwardRefExoticComponent<CollapsiblePrimitive.CollapsibleProps & React.RefAttributes<HTMLDivElement>>;
|
|
4
|
+
declare const CollapsibleTrigger: React.ForwardRefExoticComponent<CollapsiblePrimitive.CollapsibleTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
5
|
+
declare const CollapsibleContent: React.ForwardRefExoticComponent<Omit<CollapsiblePrimitive.CollapsibleContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
6
|
+
export { Collapsible, CollapsibleContent, CollapsibleTrigger };
|
|
@@ -5,8 +5,26 @@ declare const DialogTrigger: React.ForwardRefExoticComponent<DialogPrimitive.Dia
|
|
|
5
5
|
declare const DialogPortal: React.FC<DialogPrimitive.DialogPortalProps>;
|
|
6
6
|
declare const DialogClose: React.ForwardRefExoticComponent<DialogPrimitive.DialogCloseProps & React.RefAttributes<HTMLButtonElement>>;
|
|
7
7
|
declare const DialogOverlay: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogOverlayProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
declare const sizeClasses: {
|
|
9
|
+
xs: string;
|
|
10
|
+
sm: string;
|
|
11
|
+
md: string;
|
|
12
|
+
lg: string;
|
|
13
|
+
xl: string;
|
|
14
|
+
"2xl": string;
|
|
15
|
+
full: string;
|
|
16
|
+
};
|
|
8
17
|
declare const DialogContent: React.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
18
|
+
/** Close dialog when clicking outside */
|
|
9
19
|
closeOnOutsideClick?: boolean;
|
|
20
|
+
/** Initial focus element ref */
|
|
21
|
+
initialFocusRef?: React.RefObject<HTMLElement>;
|
|
22
|
+
/** Size preset */
|
|
23
|
+
size?: keyof typeof sizeClasses;
|
|
24
|
+
/** Show close button */
|
|
25
|
+
showCloseButton?: boolean;
|
|
26
|
+
/** Close on Escape key */
|
|
27
|
+
closeOnEscape?: boolean;
|
|
10
28
|
} & React.RefAttributes<HTMLDivElement>>;
|
|
11
29
|
declare const DialogHeader: {
|
|
12
30
|
({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
|
|
2
2
|
import * as React from "react";
|
|
3
3
|
declare const DropdownMenu: React.FC<DropdownMenuPrimitive.DropdownMenuProps>;
|
|
4
4
|
declare const DropdownMenuTrigger: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -1,3 +1,7 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
|
|
2
|
+
export interface InputProps extends React.ComponentProps<"input"> {
|
|
3
|
+
error?: boolean;
|
|
4
|
+
hasError?: boolean;
|
|
5
|
+
}
|
|
6
|
+
declare const Input: React.ForwardRefExoticComponent<Omit<InputProps, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
3
7
|
export { Input };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Label as LabelPrimitive } from 'radix-ui';
|
|
2
1
|
import { VariantProps } from 'class-variance-authority';
|
|
3
2
|
import * as React from "react";
|
|
3
|
+
import * as LabelPrimitive from "@radix-ui/react-label";
|
|
4
4
|
declare const Label: React.ForwardRefExoticComponent<Omit<LabelPrimitive.LabelProps & React.RefAttributes<HTMLLabelElement>, "ref"> & VariantProps<(props?: import('class-variance-authority/types').ClassProp | undefined) => string> & React.RefAttributes<HTMLLabelElement>>;
|
|
5
5
|
export { Label };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Popover as PopoverPrimitive } from 'radix-ui';
|
|
2
1
|
import * as React from "react";
|
|
2
|
+
import * as PopoverPrimitive from "@radix-ui/react-popover";
|
|
3
3
|
declare const Popover: React.FC<PopoverPrimitive.PopoverProps>;
|
|
4
4
|
declare const PopoverTrigger: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
5
5
|
declare const PopoverAnchor: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverAnchorProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -1,4 +1,22 @@
|
|
|
1
|
-
import { Progress as ProgressPrimitive } from 'radix-ui';
|
|
2
1
|
import * as React from "react";
|
|
3
|
-
|
|
2
|
+
import * as ProgressPrimitive from "@radix-ui/react-progress";
|
|
3
|
+
type ColorVariant = "primary" | "secondary" | "success" | "error" | "warning" | "info";
|
|
4
|
+
type ProgressVariant = "determinate" | "indeterminate" | "buffer" | "query";
|
|
5
|
+
export interface ProgressProps extends Omit<React.ComponentPropsWithoutRef<typeof ProgressPrimitive.Root>, "color"> {
|
|
6
|
+
/** Progress value between 0-100 */
|
|
7
|
+
value?: number;
|
|
8
|
+
/** Buffer value for buffer variant (0-100) */
|
|
9
|
+
valueBuffer?: number;
|
|
10
|
+
/** Progress variant */
|
|
11
|
+
variant?: ProgressVariant;
|
|
12
|
+
/** Color variant or custom color */
|
|
13
|
+
color?: ColorVariant | string;
|
|
14
|
+
/** Custom color (overrides color variant) */
|
|
15
|
+
customColor?: string;
|
|
16
|
+
/** Show percentage label */
|
|
17
|
+
showLabel?: boolean;
|
|
18
|
+
/** Custom label text or formatter function */
|
|
19
|
+
label?: string | ((value: number) => string);
|
|
20
|
+
}
|
|
21
|
+
declare const Progress: React.ForwardRefExoticComponent<ProgressProps & React.RefAttributes<HTMLDivElement>>;
|
|
4
22
|
export { Progress };
|