@zimyo/ui 1.3.0 → 1.4.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/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as React$1 from 'react';
2
2
  import React__default from 'react';
3
- import { ButtonProps as ButtonProps$1, AccordionProps as AccordionProps$1, AccordionSummaryProps, AccordionDetailsProps, SwitchProps as SwitchProps$1, TextFieldProps, TypographyProps, SxProps as SxProps$1 } from '@mui/material';
3
+ import { ButtonProps as ButtonProps$1, AccordionProps as AccordionProps$1, AccordionSummaryProps, AccordionDetailsProps, SwitchProps as SwitchProps$1, TypographyProps, SxProps as SxProps$1 } from '@mui/material';
4
4
  import { SxProps } from '@mui/system';
5
5
  import * as react_jsx_runtime from 'react/jsx-runtime';
6
6
  import { Props, GroupBase } from 'react-select';
@@ -74,19 +74,6 @@ interface SwitchProps extends Omit<SwitchProps$1, 'onChange'> {
74
74
  }
75
75
  declare const Switch: React__default.ForwardRefExoticComponent<Omit<SwitchProps, "ref"> & React__default.RefAttributes<HTMLButtonElement>>;
76
76
 
77
- interface TextInputProps extends Omit<TextFieldProps, 'variant'> {
78
- label?: string;
79
- placeholder?: string;
80
- IS_MANDATORY?: boolean | number | string;
81
- startIcon?: React__default.ReactNode;
82
- endIcon?: React__default.ReactNode;
83
- error?: boolean;
84
- variant?: 'outlined' | 'filled' | 'standard';
85
- helperText?: string;
86
- type?: 'text' | 'password' | 'email' | 'number' | 'tel' | 'search';
87
- }
88
- declare const TextInput: React__default.ForwardRefExoticComponent<Omit<TextInputProps, "ref"> & React__default.RefAttributes<HTMLInputElement>>;
89
-
90
77
  interface RadioOption {
91
78
  value: string;
92
79
  label: string;
@@ -192,7 +179,7 @@ declare const badgeVariants: (props?: ({
192
179
  } & class_variance_authority_dist_types.ClassProp) | undefined) => string;
193
180
  declare const Badge: ({ label, icon, iconPosition, dot, dotPosition, variant, size, type, color, className, }: BadgeProps) => react_jsx_runtime.JSX.Element;
194
181
 
195
- type InputSize = "sm" | "md" | "lg";
182
+ type InputSize$2 = "sm" | "md" | "lg";
196
183
  type InputVariant = "outlined" | "contained";
197
184
  interface InputProps extends React$1.InputHTMLAttributes<HTMLInputElement> {
198
185
  label?: string;
@@ -200,7 +187,7 @@ interface InputProps extends React$1.InputHTMLAttributes<HTMLInputElement> {
200
187
  error?: string;
201
188
  leftIcon?: React$1.ReactNode;
202
189
  rightIcon?: React$1.ReactNode;
203
- size?: InputSize;
190
+ size?: InputSize$2;
204
191
  variant?: InputVariant;
205
192
  allowedPattern?: "number" | "alpha" | RegExp;
206
193
  }
@@ -221,6 +208,63 @@ interface NoticeProps {
221
208
  }
222
209
  declare const Notice: React$1.FC<NoticeProps>;
223
210
 
211
+ type DayOfWeek = 0 | 1 | 2 | 3 | 4 | 5 | 6;
212
+ type DateRange = {
213
+ from: Date;
214
+ to: Date;
215
+ };
216
+ type DisabledDateObject = {
217
+ dayOfWeek: DayOfWeek[];
218
+ } | {
219
+ before: Date;
220
+ } | {
221
+ after: Date;
222
+ } | {
223
+ before: Date;
224
+ after: Date;
225
+ } | DateRange;
226
+ type DisabledProp = boolean | Date | Date[] | DisabledDateObject;
227
+ type InputSize$1 = "sm" | "md" | "lg";
228
+ type DatePickerVariant$1 = "outlined" | "contained";
229
+ interface DatePickerProps {
230
+ label?: string;
231
+ value?: Date;
232
+ onChange?: (date: Date | undefined) => void;
233
+ placeholder?: string;
234
+ required?: boolean;
235
+ description?: string;
236
+ error?: string;
237
+ disabled?: boolean;
238
+ variant?: DatePickerVariant$1;
239
+ size?: InputSize$1;
240
+ className?: string;
241
+ disableRange?: DisabledProp;
242
+ }
243
+ declare const DatePicker: React$1.FC<DatePickerProps>;
244
+
245
+ type InputSize = "sm" | "md" | "lg";
246
+ type DatePickerVariant = "outlined" | "contained";
247
+ interface DateRangePickerProps {
248
+ label?: string;
249
+ value?: {
250
+ from: Date;
251
+ to: Date;
252
+ };
253
+ onChange?: (range: {
254
+ from: Date;
255
+ to: Date;
256
+ } | undefined) => void;
257
+ placeholder?: string;
258
+ required?: boolean;
259
+ description?: string;
260
+ error?: string;
261
+ disabled?: boolean;
262
+ variant?: DatePickerVariant;
263
+ size?: InputSize;
264
+ className?: string;
265
+ }
266
+ declare const DateRangePicker: React$1.FC<DateRangePickerProps>;
267
+
224
268
  interface UILibraryThemeProviderProps {
225
269
  children: React__default.ReactNode;
226
270
  primaryColor?: string;
@@ -310,5 +354,5 @@ declare const designTokens: {
310
354
  declare function cn(...inputs: ClassValue[]): string;
311
355
  declare function useStableId(prefix?: string): string;
312
356
 
313
- export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Badge, Blockquote, Button, Caption, Code, Drawer, Heading, Input, Lead, Modal, Muted, Notice, RadioGroup, Select, Strong, Switch, Text, TextInput, UILibraryThemeProvider, cn, createCustomTheme, designTokens, theme, useStableId };
314
- export type { AccordionContentProps, AccordionItemProps, AccordionProps, AccordionTriggerProps, BadgeProps, ButtonProps, DrawerProps, InputProps, ModalProps, NoticeProps, RadioGroupProps, RadioOption, SelectProps, SwitchProps, TextInputProps, ThemeConfig, UILibraryThemeProviderProps };
357
+ export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Badge, Blockquote, Button, Caption, Code, DatePicker, DateRangePicker, Drawer, Heading, Input, Lead, Modal, Muted, Notice, RadioGroup, Select, Strong, Switch, Text, UILibraryThemeProvider, cn, createCustomTheme, designTokens, theme, useStableId };
358
+ export type { AccordionContentProps, AccordionItemProps, AccordionProps, AccordionTriggerProps, BadgeProps, ButtonProps, DatePickerProps, DateRangePickerProps, DrawerProps, InputProps, ModalProps, NoticeProps, RadioGroupProps, RadioOption, SelectProps, SwitchProps, ThemeConfig, UILibraryThemeProviderProps };