@kroo-web/design-system 1.2.6 → 1.3.0
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/cjs/index.js +8 -8
- package/dist/cjs/src/components/TextField/index.d.ts +17 -0
- package/dist/cjs/src/components/shared/FormField/index.d.ts +2 -2
- package/dist/esm/index.js +2 -2
- package/dist/esm/src/components/TextField/index.d.ts +17 -0
- package/dist/esm/src/components/shared/FormField/index.d.ts +2 -2
- package/dist/types.d.ts +18 -1
- package/package.json +1 -1
|
@@ -18,3 +18,20 @@ export type TTextFieldProps<T extends FieldValues> = {
|
|
|
18
18
|
type?: DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>['type'];
|
|
19
19
|
} & DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
|
|
20
20
|
export declare const TextField: React.ForwardRefExoticComponent<Omit<TTextFieldProps<FieldValues>, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
21
|
+
export type TNativeTextFieldProps = {
|
|
22
|
+
className?: string;
|
|
23
|
+
error?: {
|
|
24
|
+
message: string;
|
|
25
|
+
};
|
|
26
|
+
helper?: {
|
|
27
|
+
message: ReactNode | string;
|
|
28
|
+
};
|
|
29
|
+
id: string;
|
|
30
|
+
label: string;
|
|
31
|
+
leftContent?: ReactNode | string;
|
|
32
|
+
missing?: boolean;
|
|
33
|
+
prefix?: ReactNode | string;
|
|
34
|
+
rightContent?: ReactNode | string;
|
|
35
|
+
suffix?: ReactNode | string;
|
|
36
|
+
} & DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
|
|
37
|
+
export declare const NativeTextField: React.ForwardRefExoticComponent<Omit<TNativeTextFieldProps, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -2,8 +2,8 @@ import React, { ReactNode } from 'react';
|
|
|
2
2
|
export type TFormFieldProps = {
|
|
3
3
|
children: ReactNode;
|
|
4
4
|
error?: string;
|
|
5
|
-
helper?: string;
|
|
5
|
+
helper?: ReactNode | string;
|
|
6
6
|
id: string;
|
|
7
|
-
label
|
|
7
|
+
label?: string;
|
|
8
8
|
};
|
|
9
9
|
export declare const FormField: ({ children, error, helper, id, label }: TFormFieldProps) => React.JSX.Element;
|
package/dist/types.d.ts
CHANGED
|
@@ -394,6 +394,23 @@ type TTextFieldProps<T extends FieldValues> = {
|
|
|
394
394
|
type?: DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>['type'];
|
|
395
395
|
} & DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
|
|
396
396
|
declare const TextField: React$1.ForwardRefExoticComponent<Omit<TTextFieldProps<FieldValues>, "ref"> & React$1.RefAttributes<HTMLInputElement>>;
|
|
397
|
+
type TNativeTextFieldProps = {
|
|
398
|
+
className?: string;
|
|
399
|
+
error?: {
|
|
400
|
+
message: string;
|
|
401
|
+
};
|
|
402
|
+
helper?: {
|
|
403
|
+
message: ReactNode | string;
|
|
404
|
+
};
|
|
405
|
+
id: string;
|
|
406
|
+
label: string;
|
|
407
|
+
leftContent?: ReactNode | string;
|
|
408
|
+
missing?: boolean;
|
|
409
|
+
prefix?: ReactNode | string;
|
|
410
|
+
rightContent?: ReactNode | string;
|
|
411
|
+
suffix?: ReactNode | string;
|
|
412
|
+
} & DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
|
|
413
|
+
declare const NativeTextField: React$1.ForwardRefExoticComponent<Omit<TNativeTextFieldProps, "ref"> & React$1.RefAttributes<HTMLInputElement>>;
|
|
397
414
|
|
|
398
415
|
type TToastRootProps = {
|
|
399
416
|
children: React$1.ReactNode;
|
|
@@ -438,4 +455,4 @@ interface WrapperProps extends PropsWithChildren {
|
|
|
438
455
|
}
|
|
439
456
|
declare const Wrapper: ({ as, children, className, variants }: WrapperProps) => React$1.JSX.Element;
|
|
440
457
|
|
|
441
|
-
export { Accordion, Button, Buttons, Callout, Card, Cards, type CardsVariants, Checkbox, Columns, ComboBox, DatePicker, Disclosure, Field, Form, type ICardOwnProps, type ICardProps, type ICardsProps, Icon, Link, Loading, Modal, NumberField, OTPInput, PhoneField, PinInput, Popover, ProgressIndicator, RadioGroup, Range, Select, Skeleton, type TAccordionRootProps, type TAccordionTriggerProps, type TButtonProps, type TCalloutRootProps, type TCalloutTextProps, type TCardVariants, type TCheckboxProps, type TColumnsProps, type TComboBoxItem, type TComboBoxProps, type TDatePicker, type TDisclosureProps, type TIconProps, type TItem, type TLegacyMarketingFooter, type TLegacyMarketingHeading, type TLegacyMarketingText, type TLink, type TLoadingProps, type TModalButtonProps, type TModalContentProps, type TModalControlProps, type TModalHeaderProps, type TNumberFieldProps, type TPhoneFieldProps, type TPinInputProps, type TPopoverContentProps, type TPopoverRootProps, type TPopoverTriggerProps, type TProgressIndicatorProps, type TRadioGroupProps, type TRangeProps, type TSelectProps, type TSkeletonProps, type TTabsContent, type TTabsList, type TTabsRoot, type TTabsTrigger, type TTagProps, type TTextFieldProps, type TToastDescriptionProps, type TToastIconProps, type TToastRootProps, type TToastTitleProps, type TTooltipContentProps, type TTooltipRootProps, type TTooltipTriggerProps, type TTypography, type TTypographyProps, type TTypographyVariants, type TUseModalProps, Table, TableBody, TableData, TableFooter, TableHead, TableHeader, TableRoot, TableRow, Tabs, Tag, TextField, Toast, Tooltip, Typography, Wrapper, type WrapperProps, type WrapperVariants, useModal };
|
|
458
|
+
export { Accordion, Button, Buttons, Callout, Card, Cards, type CardsVariants, Checkbox, Columns, ComboBox, DatePicker, Disclosure, Field, Form, type ICardOwnProps, type ICardProps, type ICardsProps, Icon, Link, Loading, Modal, NativeTextField, NumberField, OTPInput, PhoneField, PinInput, Popover, ProgressIndicator, RadioGroup, Range, Select, Skeleton, type TAccordionRootProps, type TAccordionTriggerProps, type TButtonProps, type TCalloutRootProps, type TCalloutTextProps, type TCardVariants, type TCheckboxProps, type TColumnsProps, type TComboBoxItem, type TComboBoxProps, type TDatePicker, type TDisclosureProps, type TIconProps, type TItem, type TLegacyMarketingFooter, type TLegacyMarketingHeading, type TLegacyMarketingText, type TLink, type TLoadingProps, type TModalButtonProps, type TModalContentProps, type TModalControlProps, type TModalHeaderProps, type TNativeTextFieldProps, type TNumberFieldProps, type TPhoneFieldProps, type TPinInputProps, type TPopoverContentProps, type TPopoverRootProps, type TPopoverTriggerProps, type TProgressIndicatorProps, type TRadioGroupProps, type TRangeProps, type TSelectProps, type TSkeletonProps, type TTabsContent, type TTabsList, type TTabsRoot, type TTabsTrigger, type TTagProps, type TTextFieldProps, type TToastDescriptionProps, type TToastIconProps, type TToastRootProps, type TToastTitleProps, type TTooltipContentProps, type TTooltipRootProps, type TTooltipTriggerProps, type TTypography, type TTypographyProps, type TTypographyVariants, type TUseModalProps, Table, TableBody, TableData, TableFooter, TableHead, TableHeader, TableRoot, TableRow, Tabs, Tag, TextField, Toast, Tooltip, Typography, Wrapper, type WrapperProps, type WrapperVariants, useModal };
|
package/package.json
CHANGED