@lerianstudio/sindarian-ui 1.1.0 → 1.1.1-beta.1
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/components/form/combo-box-field/index.d.ts +5 -5
- package/dist/components/form/combo-box-field/index.d.ts.map +1 -1
- package/dist/components/form/date-picker-field/index.d.ts +5 -5
- package/dist/components/form/date-picker-field/index.d.ts.map +1 -1
- package/dist/components/form/date-range-field/index.d.ts +5 -5
- package/dist/components/form/date-range-field/index.d.ts.map +1 -1
- package/dist/components/form/input-field/index.d.ts +5 -5
- package/dist/components/form/input-field/index.d.ts.map +1 -1
- package/dist/components/form/pagination-limit-field/index.d.ts +4 -4
- package/dist/components/form/pagination-limit-field/index.d.ts.map +1 -1
- package/dist/components/form/select-field/index.d.ts +5 -5
- package/dist/components/form/select-field/index.d.ts.map +1 -1
- package/dist/components/form/switch-field/index.d.ts +5 -5
- package/dist/components/form/switch-field/index.d.ts.map +1 -1
- package/package.json +3 -3
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { Control } from 'react-hook-form';
|
|
3
|
-
export type ComboBoxFieldProps = React.PropsWithChildren & {
|
|
4
|
-
name:
|
|
2
|
+
import { Control, FieldValues, Path } from 'react-hook-form';
|
|
3
|
+
export type ComboBoxFieldProps<T extends FieldValues = FieldValues> = React.PropsWithChildren & {
|
|
4
|
+
name: Path<T>;
|
|
5
5
|
label?: string;
|
|
6
6
|
placeholder?: string;
|
|
7
7
|
emptyMessage?: string;
|
|
8
|
-
control: Control<
|
|
8
|
+
control: Control<T>;
|
|
9
9
|
disabled?: boolean;
|
|
10
10
|
readOnly?: boolean;
|
|
11
11
|
required?: boolean;
|
|
12
12
|
};
|
|
13
|
-
export declare const ComboBoxField: ({ name, label, placeholder, emptyMessage, required, children, readOnly, ...others }: ComboBoxFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export declare const ComboBoxField: <T extends FieldValues = FieldValues>({ name, label, placeholder, emptyMessage, required, children, readOnly, ...others }: ComboBoxFieldProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
14
14
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/combo-box-field/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAOzB,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/combo-box-field/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAOzB,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAA;AAiB5D,MAAM,MAAM,kBAAkB,CAAC,CAAC,SAAS,WAAW,GAAG,WAAW,IAChE,KAAK,CAAC,iBAAiB,GAAG;IACxB,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;IACb,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,CAAA;AAEH,eAAO,MAAM,aAAa,GAAI,CAAC,SAAS,WAAW,GAAG,WAAW,EAAE,qFAShE,kBAAkB,CAAC,CAAC,CAAC,4CA0FvB,CAAA"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { Control } from 'react-hook-form';
|
|
3
|
-
export type DatePickerFieldProps = {
|
|
4
|
-
name:
|
|
2
|
+
import { Control, FieldValues, Path } from 'react-hook-form';
|
|
3
|
+
export type DatePickerFieldProps<T extends FieldValues = FieldValues> = {
|
|
4
|
+
name: Path<T>;
|
|
5
5
|
label?: ReactNode;
|
|
6
6
|
tooltip?: string;
|
|
7
7
|
labelExtra?: ReactNode;
|
|
@@ -9,12 +9,12 @@ export type DatePickerFieldProps = {
|
|
|
9
9
|
placeholder?: string;
|
|
10
10
|
disabled?: boolean;
|
|
11
11
|
readOnly?: boolean;
|
|
12
|
-
control: Control<
|
|
12
|
+
control: Control<T>;
|
|
13
13
|
required?: boolean;
|
|
14
14
|
dateFormat?: string;
|
|
15
15
|
align?: 'start' | 'center' | 'end';
|
|
16
16
|
'data-testid'?: string;
|
|
17
17
|
valueAsString?: boolean;
|
|
18
18
|
};
|
|
19
|
-
export declare const DatePickerField: ({ name, label, tooltip, labelExtra, description, placeholder, disabled, readOnly, control, required, dateFormat, align, valueAsString, ...others }: DatePickerFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare const DatePickerField: <T extends FieldValues = FieldValues>({ name, label, tooltip, labelExtra, description, placeholder, disabled, readOnly, control, required, dateFormat, align, valueAsString, ...others }: DatePickerFieldProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
20
20
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/date-picker-field/index.tsx"],"names":[],"mappings":"AAqBA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACjC,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/date-picker-field/index.tsx"],"names":[],"mappings":"AAqBA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACjC,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAA;AAE5D,MAAM,MAAM,oBAAoB,CAAC,CAAC,SAAS,WAAW,GAAG,WAAW,IAAI;IACtE,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;IACb,KAAK,CAAC,EAAE,SAAS,CAAA;IACjB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,UAAU,CAAC,EAAE,SAAS,CAAA;IACtB,WAAW,CAAC,EAAE,SAAS,CAAA;IACvB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,KAAK,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,KAAK,CAAA;IAClC,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,aAAa,CAAC,EAAE,OAAO,CAAA;CACxB,CAAA;AAED,eAAO,MAAM,eAAe,GAAI,CAAC,SAAS,WAAW,GAAG,WAAW,EAAE,oJAelE,oBAAoB,CAAC,CAAC,CAAC,4CAsFzB,CAAA"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { Control } from 'react-hook-form';
|
|
3
|
-
export type DateRangeFieldProps = {
|
|
4
|
-
name:
|
|
2
|
+
import { Control, FieldValues, Path } from 'react-hook-form';
|
|
3
|
+
export type DateRangeFieldProps<T extends FieldValues = FieldValues> = {
|
|
4
|
+
name: Path<T>;
|
|
5
5
|
label?: ReactNode;
|
|
6
6
|
tooltip?: string;
|
|
7
7
|
labelExtra?: ReactNode;
|
|
@@ -9,12 +9,12 @@ export type DateRangeFieldProps = {
|
|
|
9
9
|
placeholder?: string;
|
|
10
10
|
disabled?: boolean;
|
|
11
11
|
readOnly?: boolean;
|
|
12
|
-
control: Control<
|
|
12
|
+
control: Control<T>;
|
|
13
13
|
required?: boolean;
|
|
14
14
|
numberOfMonths?: number;
|
|
15
15
|
dateFormat?: string;
|
|
16
16
|
align?: 'start' | 'center' | 'end';
|
|
17
17
|
'data-testid'?: string;
|
|
18
18
|
};
|
|
19
|
-
export declare const DateRangeField: ({ name, label, tooltip, labelExtra, description, placeholder, disabled, readOnly, control, required, numberOfMonths, dateFormat, align, ...others }: DateRangeFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare const DateRangeField: <T extends FieldValues = FieldValues>({ name, label, tooltip, labelExtra, description, placeholder, disabled, readOnly, control, required, numberOfMonths, dateFormat, align, ...others }: DateRangeFieldProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
20
20
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/date-range-field/index.tsx"],"names":[],"mappings":"AAqBA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEjC,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/date-range-field/index.tsx"],"names":[],"mappings":"AAqBA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEjC,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAA;AAE5D,MAAM,MAAM,mBAAmB,CAAC,CAAC,SAAS,WAAW,GAAG,WAAW,IAAI;IACrE,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;IACb,KAAK,CAAC,EAAE,SAAS,CAAA;IACjB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,UAAU,CAAC,EAAE,SAAS,CAAA;IACtB,WAAW,CAAC,EAAE,SAAS,CAAA;IACvB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,KAAK,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,KAAK,CAAA;IAClC,aAAa,CAAC,EAAE,MAAM,CAAA;CACvB,CAAA;AAED,eAAO,MAAM,cAAc,GAAI,CAAC,SAAS,WAAW,GAAG,WAAW,EAAE,qJAejE,mBAAmB,CAAC,CAAC,CAAC,4CAoExB,CAAA"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { HTMLInputTypeAttribute, ReactNode } from 'react';
|
|
2
|
-
import { Control } from 'react-hook-form';
|
|
3
|
-
export type InputFieldProps = {
|
|
2
|
+
import { Control, FieldValues, Path } from 'react-hook-form';
|
|
3
|
+
export type InputFieldProps<T extends FieldValues = FieldValues> = {
|
|
4
4
|
className?: string;
|
|
5
|
-
name:
|
|
5
|
+
name: Path<T>;
|
|
6
6
|
type?: HTMLInputTypeAttribute;
|
|
7
7
|
label?: ReactNode;
|
|
8
8
|
tooltip?: string;
|
|
@@ -11,7 +11,7 @@ export type InputFieldProps = {
|
|
|
11
11
|
description?: ReactNode;
|
|
12
12
|
startAdornment?: ReactNode;
|
|
13
13
|
endAdornment?: ReactNode;
|
|
14
|
-
control: Control<
|
|
14
|
+
control: Control<T>;
|
|
15
15
|
disabled?: boolean;
|
|
16
16
|
readOnly?: boolean;
|
|
17
17
|
minHeight?: number;
|
|
@@ -22,5 +22,5 @@ export type InputFieldProps = {
|
|
|
22
22
|
'data-testid'?: string;
|
|
23
23
|
onChange?: (e: React.ChangeEvent<HTMLInputElement | HTMLTextAreaElement>) => void;
|
|
24
24
|
};
|
|
25
|
-
export declare const InputField: ({ className, type, label, tooltip, labelExtra, placeholder, description, startAdornment, endAdornment, required, readOnly, minHeight, maxHeight, textArea, defaultValue, onChange, ...others }: InputFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
25
|
+
export declare const InputField: <T extends FieldValues = FieldValues>({ className, type, label, tooltip, labelExtra, placeholder, description, startAdornment, endAdornment, required, readOnly, minHeight, maxHeight, textArea, defaultValue, onChange, ...others }: InputFieldProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
26
26
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/input-field/index.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,sBAAsB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACzD,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/input-field/index.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,sBAAsB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACzD,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAA;AAE5D,MAAM,MAAM,eAAe,CAAC,CAAC,SAAS,WAAW,GAAG,WAAW,IAAI;IACjE,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;IACb,IAAI,CAAC,EAAE,sBAAsB,CAAA;IAC7B,KAAK,CAAC,EAAE,SAAS,CAAA;IACjB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,UAAU,CAAC,EAAE,SAAS,CAAA;IACtB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,WAAW,CAAC,EAAE,SAAS,CAAA;IACvB,cAAc,CAAC,EAAE,SAAS,CAAA;IAC1B,YAAY,CAAC,EAAE,SAAS,CAAA;IACxB,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,QAAQ,CAAC,EAAE,CACT,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC,gBAAgB,GAAG,mBAAmB,CAAC,KACzD,IAAI,CAAA;CACV,CAAA;AACD,eAAO,MAAM,UAAU,GAAI,CAAC,SAAS,WAAW,GAAG,WAAW,EAAE,gMAkB7D,eAAe,CAAC,CAAC,CAAC,4CAkDpB,CAAA"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { Control } from 'react-hook-form';
|
|
2
|
-
export type PaginationLimitFieldProps = {
|
|
1
|
+
import { Control, FieldValues } from 'react-hook-form';
|
|
2
|
+
export type PaginationLimitFieldProps<T extends FieldValues = FieldValues> = {
|
|
3
3
|
label?: string;
|
|
4
4
|
options?: number[];
|
|
5
|
-
control: Control<
|
|
5
|
+
control: Control<T>;
|
|
6
6
|
['data-testid']?: string;
|
|
7
7
|
};
|
|
8
|
-
export declare const PaginationLimitField: ({ options, label, control, ["data-testid"]: dataTestId }: PaginationLimitFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export declare const PaginationLimitField: <T extends FieldValues = FieldValues>({ options, label, control, ["data-testid"]: dataTestId }: PaginationLimitFieldProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
9
9
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/pagination-limit-field/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/pagination-limit-field/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,WAAW,EAAQ,MAAM,iBAAiB,CAAA;AAI5D,MAAM,MAAM,yBAAyB,CAAC,CAAC,SAAS,WAAW,GAAG,WAAW,IAAI;IAC3E,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,EAAE,CAAA;IAClB,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,CAAA;IACnB,CAAC,aAAa,CAAC,CAAC,EAAE,MAAM,CAAA;CACzB,CAAA;AAED,eAAO,MAAM,oBAAoB,GAAI,CAAC,SAAS,WAAW,GAAG,WAAW,EAAE,0DAKvE,yBAAyB,CAAC,CAAC,CAAC,4CAe9B,CAAA"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { PropsWithChildren, ReactNode } from 'react';
|
|
2
|
-
import { Control } from 'react-hook-form';
|
|
3
|
-
export type SelectFieldProps = PropsWithChildren & {
|
|
4
|
-
name:
|
|
2
|
+
import { Control, FieldValues, Path } from 'react-hook-form';
|
|
3
|
+
export type SelectFieldProps<T extends FieldValues = FieldValues> = PropsWithChildren & {
|
|
4
|
+
name: Path<T>;
|
|
5
5
|
label?: ReactNode;
|
|
6
6
|
tooltip?: string;
|
|
7
7
|
labelExtra?: React.ReactNode;
|
|
@@ -9,12 +9,12 @@ export type SelectFieldProps = PropsWithChildren & {
|
|
|
9
9
|
placeholder?: string;
|
|
10
10
|
disabled?: boolean;
|
|
11
11
|
readOnly?: boolean;
|
|
12
|
-
control: Control<
|
|
12
|
+
control: Control<T>;
|
|
13
13
|
multi?: boolean;
|
|
14
14
|
required?: boolean;
|
|
15
15
|
emptyMessage?: string;
|
|
16
16
|
onChange?: (value: string | string[]) => void;
|
|
17
17
|
'data-testid'?: string;
|
|
18
18
|
};
|
|
19
|
-
export declare const SelectField: ({ name, label, tooltip, labelExtra, required, placeholder, description, disabled, readOnly, multi, control, children, emptyMessage, onChange, ...others }: SelectFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare const SelectField: <T extends FieldValues = FieldValues>({ name, label, tooltip, labelExtra, required, placeholder, description, disabled, readOnly, multi, control, children, emptyMessage, onChange, ...others }: SelectFieldProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
20
20
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/select-field/index.tsx"],"names":[],"mappings":"AAuBA,OAAO,KAAK,EAAE,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAC3D,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/select-field/index.tsx"],"names":[],"mappings":"AAuBA,OAAO,KAAK,EAAE,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAC3D,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAA;AAE5D,MAAM,MAAM,gBAAgB,CAAC,CAAC,SAAS,WAAW,GAAG,WAAW,IAC9D,iBAAiB,GAAG;IAClB,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;IACb,KAAK,CAAC,EAAE,SAAS,CAAA;IACjB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,UAAU,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IAC5B,WAAW,CAAC,EAAE,SAAS,CAAA;IACvB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,CAAA;IACnB,KAAK,CAAC,EAAE,OAAO,CAAA;IACf,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,KAAK,IAAI,CAAA;IAC7C,aAAa,CAAC,EAAE,MAAM,CAAA;CACvB,CAAA;AAEH,eAAO,MAAM,WAAW,GAAI,CAAC,SAAS,WAAW,GAAG,WAAW,EAAE,2JAgB9D,gBAAgB,CAAC,CAAC,CAAC,4CAmErB,CAAA"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { Control } from 'react-hook-form';
|
|
3
|
-
export type SwitchFieldProps = {
|
|
2
|
+
import { Control, FieldValues, Path } from 'react-hook-form';
|
|
3
|
+
export type SwitchFieldProps<T extends FieldValues = FieldValues> = {
|
|
4
4
|
label?: string;
|
|
5
|
-
name:
|
|
6
|
-
control: Control<
|
|
5
|
+
name: Path<T>;
|
|
6
|
+
control: Control<T>;
|
|
7
7
|
labelExtra?: ReactNode;
|
|
8
8
|
tooltip?: string;
|
|
9
9
|
required?: boolean;
|
|
@@ -11,5 +11,5 @@ export type SwitchFieldProps = {
|
|
|
11
11
|
disabledTooltip?: string;
|
|
12
12
|
'data-testid'?: string;
|
|
13
13
|
};
|
|
14
|
-
export declare const SwitchField: ({ label, name, control, labelExtra, tooltip, required, disabled, disabledTooltip, "data-testid": dataTestId }: SwitchFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export declare const SwitchField: <T extends FieldValues = FieldValues>({ label, name, control, labelExtra, tooltip, required, disabled, disabledTooltip, "data-testid": dataTestId }: SwitchFieldProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
15
15
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/switch-field/index.tsx"],"names":[],"mappings":"AAeA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACjC,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/form/switch-field/index.tsx"],"names":[],"mappings":"AAeA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACjC,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAA;AAE5D,MAAM,MAAM,gBAAgB,CAAC,CAAC,SAAS,WAAW,GAAG,WAAW,IAAI;IAClE,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,CAAA;IACb,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,CAAA;IACnB,UAAU,CAAC,EAAE,SAAS,CAAA;IACtB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,aAAa,CAAC,EAAE,MAAM,CAAA;CACvB,CAAA;AAED,eAAO,MAAM,WAAW,GAAI,CAAC,SAAS,WAAW,GAAG,WAAW,EAAE,+GAU9D,gBAAgB,CAAC,CAAC,CAAC,4CAiDrB,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lerianstudio/sindarian-ui",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.1-beta.1",
|
|
4
4
|
"description": "Sindarian UI - A UI library for Midaz Console",
|
|
5
5
|
"license": "ISC",
|
|
6
6
|
"author": {
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
"class-variance-authority": "^0.7.1",
|
|
52
52
|
"clsx": "^2.1.1",
|
|
53
53
|
"cmdk": "^1.1.1",
|
|
54
|
-
"dayjs": "^1.11.
|
|
54
|
+
"dayjs": "^1.11.20",
|
|
55
55
|
"postcss": "^8.5.6",
|
|
56
56
|
"tailwind-merge": "^3.4.0",
|
|
57
57
|
"tailwindcss": "^4.1.18",
|
|
@@ -70,7 +70,7 @@
|
|
|
70
70
|
"@storybook/addon-docs": "^10.2.0",
|
|
71
71
|
"@storybook/addon-links": "^10.2.0",
|
|
72
72
|
"@storybook/nextjs": "^10.2.0",
|
|
73
|
-
"@types/react": "^19.2.
|
|
73
|
+
"@types/react": "^19.2.14",
|
|
74
74
|
"storybook": "^10.2.0"
|
|
75
75
|
},
|
|
76
76
|
"publishConfig": {
|