@candy.thieves/ui-kit-lumos 0.0.6 → 0.0.8
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/types/components/Checkbox/Checkbox.d.ts +10 -0
- package/dist/types/components/Checkbox/FormCheckbox.d.ts +8 -0
- package/dist/types/components/Checkbox/index.d.ts +2 -0
- package/dist/types/components/Input/FormInput.d.ts +8 -0
- package/dist/types/components/Input/Input.d.ts +13 -0
- package/dist/types/components/Input/index.d.ts +2 -0
- package/dist/types/components/PasswordInput/FormPasswordInput.d.ts +8 -0
- package/dist/types/components/PasswordInput/PasswordInput.d.ts +5 -0
- package/dist/types/components/PasswordInput/index.d.ts +2 -0
- package/dist/types/components/SearchInput/SearchInput.d.ts +3 -0
- package/dist/types/components/SearchInput/index.d.ts +1 -0
- package/package.json +7 -2
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ComponentPropsWithoutRef, ReactNode } from 'react';
|
|
2
|
+
import * as CheckboxPrimitive from '@radix-ui/react-checkbox';
|
|
3
|
+
export type CheckboxProps = Omit<ComponentPropsWithoutRef<typeof CheckboxPrimitive.Root>, 'onCheckedChange'> & {
|
|
4
|
+
label?: ReactNode;
|
|
5
|
+
onCheckedChange?: (checked: boolean) => void;
|
|
6
|
+
};
|
|
7
|
+
export declare const Checkbox: import("react").ForwardRefExoticComponent<Omit<Omit<CheckboxPrimitive.CheckboxProps & import("react").RefAttributes<HTMLButtonElement>, "ref">, "onCheckedChange"> & {
|
|
8
|
+
label?: ReactNode;
|
|
9
|
+
onCheckedChange?: (checked: boolean) => void;
|
|
10
|
+
} & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { type Control, type FieldValues, type Path } from 'react-hook-form';
|
|
2
|
+
import { type CheckboxProps } from './Checkbox';
|
|
3
|
+
type FormCheckboxProps<T extends FieldValues> = Omit<CheckboxProps, 'checked' | 'defaultChecked' | 'onCheckedChange'> & {
|
|
4
|
+
control: Control<T>;
|
|
5
|
+
name: Path<T>;
|
|
6
|
+
};
|
|
7
|
+
export declare const FormCheckbox: <T extends FieldValues>({ control, name, ...props }: FormCheckboxProps<T>) => import("react").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { type Control, type FieldPath, type FieldValues } from 'react-hook-form';
|
|
2
|
+
import { type InputProps } from './Input';
|
|
3
|
+
type FormInputProps<T extends FieldValues> = {
|
|
4
|
+
control: Control<T>;
|
|
5
|
+
name: FieldPath<T>;
|
|
6
|
+
} & Omit<InputProps, 'name' | 'onBlur' | 'onChange' | 'value'>;
|
|
7
|
+
export declare const FormInput: <T extends FieldValues>({ control, name, ...props }: FormInputProps<T>) => import("react").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { type ComponentPropsWithoutRef, type ReactNode } from 'react';
|
|
2
|
+
export type InputProps = {
|
|
3
|
+
label?: string;
|
|
4
|
+
error?: string;
|
|
5
|
+
startAdornment?: ReactNode;
|
|
6
|
+
endAdornment?: ReactNode;
|
|
7
|
+
} & ComponentPropsWithoutRef<'input'>;
|
|
8
|
+
export declare const Input: import("react").ForwardRefExoticComponent<{
|
|
9
|
+
label?: string;
|
|
10
|
+
error?: string;
|
|
11
|
+
startAdornment?: ReactNode;
|
|
12
|
+
endAdornment?: ReactNode;
|
|
13
|
+
} & Omit<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "ref"> & import("react").RefAttributes<HTMLInputElement>>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { type Control, type FieldPath, type FieldValues } from 'react-hook-form';
|
|
2
|
+
import { type PasswordInputProps } from './PasswordInput';
|
|
3
|
+
type FormPasswordInputProps<T extends FieldValues> = {
|
|
4
|
+
control: Control<T>;
|
|
5
|
+
name: FieldPath<T>;
|
|
6
|
+
} & Omit<PasswordInputProps, 'name' | 'onBlur' | 'onChange' | 'value'>;
|
|
7
|
+
export declare const FormPasswordInput: <T extends FieldValues>({ control, name, ...props }: FormPasswordInputProps<T>) => import("react").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { SearchInput } from './SearchInput';
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@candy.thieves/ui-kit-lumos",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.8",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"module": "dist/index.js",
|
|
@@ -26,6 +26,7 @@
|
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"@fontsource-variable/inter": "^5.3.0",
|
|
28
28
|
"@fontsource-variable/roboto": "^5.3.0",
|
|
29
|
+
"@radix-ui/react-checkbox": "^1.3.8",
|
|
29
30
|
"@radix-ui/react-radio-group": "^1.4.5",
|
|
30
31
|
"@radix-ui/themes": "^3.3.0",
|
|
31
32
|
"clsx": "^2.1.1",
|
|
@@ -75,7 +76,8 @@
|
|
|
75
76
|
"typescript": "~6.0.2",
|
|
76
77
|
"typescript-eslint": "^8.62.0",
|
|
77
78
|
"vite": "^8.1.1",
|
|
78
|
-
"vitest": "^4.1.10"
|
|
79
|
+
"vitest": "^4.1.10",
|
|
80
|
+
"react-hook-form": "^7.82.0"
|
|
79
81
|
},
|
|
80
82
|
"lint-staged": {
|
|
81
83
|
"**/*.{jsx,js,tsx,ts}": [
|
|
@@ -87,5 +89,8 @@
|
|
|
87
89
|
"**/*": [
|
|
88
90
|
"prettier --write --ignore-unknown"
|
|
89
91
|
]
|
|
92
|
+
},
|
|
93
|
+
"peerDependencies": {
|
|
94
|
+
"react-hook-form": "^7.82.0"
|
|
90
95
|
}
|
|
91
96
|
}
|