ui-czn 1.0.52 → 1.0.54
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/README.md +54 -54
- package/dist/assets/check.svg +9 -9
- package/dist/assets/checkbox-checked.svg +10 -10
- package/dist/assets/plus.svg +3 -3
- package/dist/assets/star.svg +9 -9
- package/dist/index.d.ts +23 -3
- package/dist/ui-czn.es.js +2098 -2074
- package/dist/ui-czn.umd.js +37 -37
- package/package.json +86 -86
package/dist/index.d.ts
CHANGED
|
@@ -8,7 +8,6 @@ import * as RadioGroupPrimitive from '@radix-ui/react-radio-group';
|
|
|
8
8
|
import * as React_2 from 'react';
|
|
9
9
|
import { ReactNode } from 'react';
|
|
10
10
|
import { VariantProps } from 'class-variance-authority';
|
|
11
|
-
import * as z from 'zod';
|
|
12
11
|
|
|
13
12
|
export declare function Badge({ className, variant, ...props }: BadgeProps): JSX.Element;
|
|
14
13
|
|
|
@@ -33,7 +32,7 @@ export declare interface BaseFormProps {
|
|
|
33
32
|
watch: any;
|
|
34
33
|
setValue: any;
|
|
35
34
|
}) => React_2.ReactNode;
|
|
36
|
-
extraSchema?:
|
|
35
|
+
extraSchema?: ExtraSchema;
|
|
37
36
|
onSubmit?: (data: any) => void;
|
|
38
37
|
}
|
|
39
38
|
|
|
@@ -109,7 +108,7 @@ export declare const CardWithIcon: React_2.ForwardRefExoticComponent<CardWithIco
|
|
|
109
108
|
export declare interface CardWithIconProps extends VariantProps<typeof cardWithIconVariants>, VariantProps<typeof contentVariants>, VariantProps<typeof iconVariants> {
|
|
110
109
|
icon: string;
|
|
111
110
|
content: ReactNode;
|
|
112
|
-
alt
|
|
111
|
+
alt?: string;
|
|
113
112
|
className?: string;
|
|
114
113
|
iconClassName?: string;
|
|
115
114
|
contentClassName?: string;
|
|
@@ -182,6 +181,27 @@ declare interface DefaultInputProps extends React_2.ComponentProps<"input"> {
|
|
|
182
181
|
isTouched?: boolean;
|
|
183
182
|
}
|
|
184
183
|
|
|
184
|
+
declare type ExtraSchema = Record<string, ExtraSchemaField>;
|
|
185
|
+
|
|
186
|
+
declare interface ExtraSchemaField {
|
|
187
|
+
type: ExtraSchemaFieldType;
|
|
188
|
+
/** обычный required */
|
|
189
|
+
required?: boolean;
|
|
190
|
+
/** сообщение об ошибке */
|
|
191
|
+
errorMessage?: string;
|
|
192
|
+
/** для array */
|
|
193
|
+
items?: {
|
|
194
|
+
type: Exclude<ExtraSchemaFieldType, "array">;
|
|
195
|
+
};
|
|
196
|
+
/** условный required */
|
|
197
|
+
requiredIf?: {
|
|
198
|
+
field: string;
|
|
199
|
+
equals: any;
|
|
200
|
+
};
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
declare type ExtraSchemaFieldType = "string" | "number" | "boolean" | "array" | "date";
|
|
204
|
+
|
|
185
205
|
export declare function Field({ className, orientation, ...props }: default_2.ComponentProps<"div"> & VariantProps<typeof fieldVariants>): JSX.Element;
|
|
186
206
|
|
|
187
207
|
export declare function FieldContent({ className, ...props }: default_2.ComponentProps<"div">): JSX.Element;
|