@useloops/design-system 1.4.95 → 1.4.98
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/esm/index.js +4 -4
- package/dist/index.d.ts +110 -57
- package/dist/index.js +3 -3
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -244,7 +244,7 @@ interface CheckboxProps {
|
|
|
244
244
|
disabled?: boolean;
|
|
245
245
|
id?: string;
|
|
246
246
|
required?: boolean;
|
|
247
|
-
value?:
|
|
247
|
+
value?: boolean;
|
|
248
248
|
}
|
|
249
249
|
declare const Checkbox: FunctionComponent<CheckboxProps>;
|
|
250
250
|
|
|
@@ -334,6 +334,11 @@ interface GridOverlayProps {
|
|
|
334
334
|
}
|
|
335
335
|
declare const GridOverlay: FunctionComponent<GridOverlayProps>;
|
|
336
336
|
|
|
337
|
+
interface HtmlProps {
|
|
338
|
+
children: ReactElement;
|
|
339
|
+
}
|
|
340
|
+
declare const Html: FunctionComponent<HtmlProps>;
|
|
341
|
+
|
|
337
342
|
interface IconProps {
|
|
338
343
|
name: 'arrow-forward' | 'expand-more' | 'close' | 'play' | 'positive' | 'negative' | 'neutral' | 'info' | 'check-circle' | 'error-outline' | 'lightbulb' | 'warning-amber' | 'access-time' | 'linkedin' | 'medium' | 'menu' | 'unfold-more' | 'navigation-arrow' | 'lock' | 'loopsOfficial' | 'google' | 'linkedin-color' | 'check' | 'dash' | 'gift' | string;
|
|
339
344
|
size?: number;
|
|
@@ -505,11 +510,50 @@ interface RadioGroupProps {
|
|
|
505
510
|
other?: RadioGroupOther;
|
|
506
511
|
onChange: (value: string) => void;
|
|
507
512
|
internalChange?: () => void;
|
|
508
|
-
name
|
|
513
|
+
name: string;
|
|
509
514
|
value: string;
|
|
510
515
|
}
|
|
511
516
|
declare const RadioGroup: FunctionComponent<RadioGroupProps>;
|
|
512
517
|
|
|
518
|
+
type SelectOption = {
|
|
519
|
+
label: string;
|
|
520
|
+
value: string;
|
|
521
|
+
};
|
|
522
|
+
|
|
523
|
+
type SelectOnChange = (event: SelectChangeEvent<any>, child: React.ReactNode) => void;
|
|
524
|
+
type AutocompleteOnChange = (value: string[]) => void;
|
|
525
|
+
type SelectProps = {
|
|
526
|
+
selections: SelectOption[];
|
|
527
|
+
autoComplete?: boolean;
|
|
528
|
+
autoFocus?: boolean;
|
|
529
|
+
disabled?: boolean;
|
|
530
|
+
disablePortal?: boolean;
|
|
531
|
+
error?: boolean;
|
|
532
|
+
fullWidth?: boolean;
|
|
533
|
+
id?: string;
|
|
534
|
+
inputRef?: SelectProps$1['inputRef'];
|
|
535
|
+
internalChange?: () => void;
|
|
536
|
+
MenuProps?: SelectProps$1['MenuProps'];
|
|
537
|
+
name: string;
|
|
538
|
+
onBlur?: SelectProps$1['onBlur'];
|
|
539
|
+
onChange?: SelectOnChange | AutocompleteOnChange;
|
|
540
|
+
placeholder?: string | undefined;
|
|
541
|
+
readOnly?: boolean;
|
|
542
|
+
ref?: SelectProps$1['ref'];
|
|
543
|
+
required?: boolean;
|
|
544
|
+
selectOptionProps?: MenuItemProps;
|
|
545
|
+
sizing?: 'xs' | 'md' | 'lg';
|
|
546
|
+
sx?: SelectProps$1['sx'];
|
|
547
|
+
value?: SelectProps$1['value'];
|
|
548
|
+
renderListItem?: (label: string) => ReactElement;
|
|
549
|
+
};
|
|
550
|
+
declare const Select: FunctionComponent<SelectProps>;
|
|
551
|
+
|
|
552
|
+
interface Option {
|
|
553
|
+
label: string;
|
|
554
|
+
value: string;
|
|
555
|
+
}
|
|
556
|
+
|
|
513
557
|
interface Props$1 {
|
|
514
558
|
id: UniqueIdentifier;
|
|
515
559
|
top?: JSX.Element;
|
|
@@ -534,13 +578,17 @@ declare namespace SortableList {
|
|
|
534
578
|
var DragHandle: typeof DragHandle;
|
|
535
579
|
}
|
|
536
580
|
|
|
537
|
-
interface RankProps extends Omit<SortableListProps<any>, 'renderItem'> {
|
|
581
|
+
interface RankProps extends Omit<SortableListProps<any>, 'renderItem' | 'items'> {
|
|
538
582
|
labelTop: string;
|
|
539
583
|
labelBottom: string;
|
|
540
584
|
fullWidth?: boolean;
|
|
541
|
-
options:
|
|
585
|
+
options: (Option & {
|
|
586
|
+
id: string;
|
|
587
|
+
})[];
|
|
542
588
|
internalChange?: () => void;
|
|
543
|
-
value?:
|
|
589
|
+
value?: (Option & {
|
|
590
|
+
id: string;
|
|
591
|
+
})[];
|
|
544
592
|
}
|
|
545
593
|
declare const Rank: FunctionComponent<RankProps>;
|
|
546
594
|
|
|
@@ -553,40 +601,6 @@ type RichTextFieldProps = Omit<InputFieldBaseProps$1, 'value'> & {
|
|
|
553
601
|
};
|
|
554
602
|
declare const RichTextField: FunctionComponent<RichTextFieldProps>;
|
|
555
603
|
|
|
556
|
-
type SelectOption = {
|
|
557
|
-
label: string;
|
|
558
|
-
value: string;
|
|
559
|
-
};
|
|
560
|
-
|
|
561
|
-
type SelectOnChange = (event: SelectChangeEvent<any>, child: React.ReactNode) => void;
|
|
562
|
-
type AutocompleteOnChange = (value: string[]) => void;
|
|
563
|
-
type SelectProps = {
|
|
564
|
-
selections: SelectOption[];
|
|
565
|
-
autoComplete?: boolean;
|
|
566
|
-
autoFocus?: boolean;
|
|
567
|
-
disabled?: boolean;
|
|
568
|
-
disablePortal?: boolean;
|
|
569
|
-
error?: boolean;
|
|
570
|
-
fullWidth?: boolean;
|
|
571
|
-
id?: string;
|
|
572
|
-
inputRef?: SelectProps$1['inputRef'];
|
|
573
|
-
internalChange?: () => void;
|
|
574
|
-
MenuProps?: SelectProps$1['MenuProps'];
|
|
575
|
-
name?: string | undefined;
|
|
576
|
-
onBlur?: SelectProps$1['onBlur'];
|
|
577
|
-
onChange?: SelectOnChange | AutocompleteOnChange;
|
|
578
|
-
placeholder?: string | undefined;
|
|
579
|
-
readOnly?: boolean;
|
|
580
|
-
ref?: SelectProps$1['ref'];
|
|
581
|
-
required?: boolean;
|
|
582
|
-
selectOptionProps?: MenuItemProps;
|
|
583
|
-
sizing?: 'xs' | 'md' | 'lg';
|
|
584
|
-
sx?: SelectProps$1['sx'];
|
|
585
|
-
value?: SelectProps$1['value'];
|
|
586
|
-
renderListItem?: (label: string) => ReactElement;
|
|
587
|
-
};
|
|
588
|
-
declare const Select: FunctionComponent<SelectProps>;
|
|
589
|
-
|
|
590
604
|
interface SliderProps {
|
|
591
605
|
labelLeft: string;
|
|
592
606
|
labelRight: string;
|
|
@@ -596,7 +610,6 @@ interface SliderProps {
|
|
|
596
610
|
labelRightProps?: InputLabelHelpProps;
|
|
597
611
|
labelLeftProps?: InputLabelHelpProps;
|
|
598
612
|
internalChange?: () => void;
|
|
599
|
-
defaultValue?: number;
|
|
600
613
|
disabled?: boolean;
|
|
601
614
|
onChange?: (event: Event, value: number | number[], activeThumb: number) => void;
|
|
602
615
|
step?: number;
|
|
@@ -605,12 +618,11 @@ interface SliderProps {
|
|
|
605
618
|
declare const Slider: FunctionComponent<SliderProps>;
|
|
606
619
|
|
|
607
620
|
interface StarRatingProps {
|
|
608
|
-
defaultValue?: number;
|
|
609
621
|
disabled?: boolean;
|
|
610
622
|
readOnly?: boolean;
|
|
611
623
|
onChange?: (event: React.ChangeEvent<{}>, value: number | null) => void;
|
|
612
624
|
precision?: number;
|
|
613
|
-
name
|
|
625
|
+
name: string;
|
|
614
626
|
IconContainerComponent?: any;
|
|
615
627
|
value?: number | null;
|
|
616
628
|
internalChange?: () => void;
|
|
@@ -709,27 +721,68 @@ interface FormGeneratorConfig {
|
|
|
709
721
|
sxStack?: SxProps<Theme>;
|
|
710
722
|
};
|
|
711
723
|
}
|
|
712
|
-
type TextFieldType =
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
type
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
type
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
type
|
|
722
|
-
|
|
724
|
+
type TextFieldType = {
|
|
725
|
+
fieldType: 'textfield';
|
|
726
|
+
} & BaseField & Omit<TextFieldProps, 'value' | 'onChange' | 'name'>;
|
|
727
|
+
type NumberFieldType = {
|
|
728
|
+
fieldType: 'numberfield';
|
|
729
|
+
} & BaseField & Omit<NumberFieldProps$1, 'value' | 'onChange' | 'name'>;
|
|
730
|
+
type TextareaType = {
|
|
731
|
+
fieldType: 'textarea';
|
|
732
|
+
} & BaseField & Omit<TextareaProps, 'value' | 'onChange' | 'name'>;
|
|
733
|
+
type SelectType = {
|
|
734
|
+
fieldType: 'select';
|
|
735
|
+
defaultValue?: SelectProps['value'];
|
|
736
|
+
} & BaseField & Omit<SelectProps, 'value' | 'onChange' | 'name'>;
|
|
737
|
+
type CheckboxType = {
|
|
738
|
+
fieldType: 'checkbox';
|
|
739
|
+
defaultValue?: CheckboxProps['value'];
|
|
740
|
+
} & BaseField & Omit<CheckboxProps, 'value' | 'onChange' | 'name'>;
|
|
741
|
+
type CheckboxGroupType = {
|
|
742
|
+
fieldType: 'checkboxGroup';
|
|
743
|
+
defaultValue?: string[];
|
|
744
|
+
} & BaseField & Omit<CheckboxGroupProps, 'value' | 'onChange' | 'name'>;
|
|
745
|
+
type SliderType = {
|
|
746
|
+
fieldType: 'slider';
|
|
747
|
+
defaultValue?: SliderProps['value'];
|
|
748
|
+
} & BaseField & Omit<SliderProps, 'value' | 'onChange' | 'name'>;
|
|
749
|
+
type DifferentialType = {
|
|
750
|
+
fieldType: 'differential';
|
|
751
|
+
defaultValue?: DifferentialProps['value'];
|
|
752
|
+
} & BaseField & Omit<DifferentialProps, 'value' | 'onChange' | 'name'>;
|
|
753
|
+
type LikertType = {
|
|
754
|
+
fieldType: 'likert';
|
|
755
|
+
defaultValue?: LikertProps['value'];
|
|
756
|
+
} & BaseField & Omit<LikertProps, 'value' | 'onChange' | 'name'>;
|
|
757
|
+
type RadioGroupType = {
|
|
758
|
+
fieldType: 'radioGroup';
|
|
759
|
+
defaultValue?: RadioGroupProps['value'];
|
|
760
|
+
} & BaseField & Omit<RadioGroupProps, 'value' | 'onChange' | 'name'>;
|
|
761
|
+
type DragAndDropRankingType = {
|
|
762
|
+
fieldType: 'ranking';
|
|
763
|
+
defaultValue?: RankProps['value'];
|
|
764
|
+
} & BaseField & Omit<RankProps, 'value' | 'onChange' | 'name'>;
|
|
765
|
+
type RichTextFieldType = {
|
|
766
|
+
fieldType: 'richTextfield';
|
|
767
|
+
defaultValue?: RichTextFieldProps$1['value'];
|
|
768
|
+
} & BaseField & Omit<RichTextFieldProps$1, 'value' | 'onChange' | 'name'>;
|
|
769
|
+
type StarRatingType = {
|
|
770
|
+
fieldType: 'starRating';
|
|
771
|
+
defaultValue?: StarRatingProps['value'];
|
|
772
|
+
} & BaseField & Omit<StarRatingProps, 'value' | 'onChange' | 'name'>;
|
|
773
|
+
type HTMLType = {
|
|
774
|
+
fieldType: 'html';
|
|
775
|
+
content: HtmlProps['children'];
|
|
776
|
+
defaultValue?: never;
|
|
777
|
+
} & BaseField;
|
|
723
778
|
type DynamicFieldType = 'textfield' | 'numberfield' | 'textarea' | 'select' | 'checkbox' | 'checkboxGroup' | 'slider' | 'differential' | 'likert' | 'starRating' | 'radioGroup' | 'ranking' | 'richTextfield';
|
|
724
779
|
type FieldType = DynamicFieldType | 'html';
|
|
725
|
-
type FieldTypes = CheckboxType | CheckboxGroupType | SelectType | TextFieldType | SliderType | DifferentialType | RichTextFieldType | LikertType | RadioGroupType | DragAndDropRankingType | NumberFieldType;
|
|
780
|
+
type FieldTypes = CheckboxType | CheckboxGroupType | TextareaType | SelectType | TextFieldType | SliderType | DifferentialType | RichTextFieldType | LikertType | RadioGroupType | DragAndDropRankingType | NumberFieldType | StarRatingType | HTMLType;
|
|
726
781
|
interface BaseField {
|
|
727
782
|
name: string;
|
|
728
783
|
ref?: any;
|
|
729
784
|
multiline?: boolean;
|
|
730
|
-
fieldType: FieldType;
|
|
731
785
|
content?: ReactElement;
|
|
732
|
-
defaultValue?: string | number | string[] | boolean | undefined;
|
|
733
786
|
label?: string;
|
|
734
787
|
labelProps?: InputLabelProps;
|
|
735
788
|
helperText?: string;
|
|
@@ -1184,4 +1237,4 @@ declare module '@mui/system' {
|
|
|
1184
1237
|
}
|
|
1185
1238
|
}
|
|
1186
1239
|
|
|
1187
|
-
export { AnnualController, type AnnualControllerProps, AuthContainerSurface, type AuthContainerSurfaceProps, AuthFormHeader, type AuthFormHeaderProps, Avatar, AvatarGroup, type AvatarGroupProps, type AvatarProps, Button, type ButtonProps, CheckboxGroup as CheckBoxGroup, Checkbox, type CheckboxGroupProps, type CheckboxProps, ColorBackgroundContainer, type ColorBackgroundContainerProps, DEFAULT_MAX_INPUT_LENGTH, Differential, type DifferentialProps, DropdownMenu, type FieldType, type FieldTypes, FormControlLabel, FormGenerator, type FormGeneratorConfig, type FormGeneratorHandler, GridOverlay, type GridOverlayProps, Icon, IconButton, IconButtonGroup, InputLabel, InputLabelHelp, type InputLabelHelpProps, type InputLabelProps, Likert, type LikertProps, Link, type LinkProps, Loader, type LoaderProps, Logo, NumberField, type NumberFieldProps, Pill, type PillProps, PlanFeatureTable, type PlanFeatureTableProps, PlanTierCard, type PlanTierCardProps, PlanTierCardScale, type PlanTierCardScaleProps, Portal, type PortalProps, PoweredByWatermarkLogo, Progress, type ProgressProps, Radio, RadioGroup, type RadioGroupProps, type RadioProps, Rank, type RankProps, RichTextField, type RichTextFieldProps, Select, type SelectProps, Slider, type SliderProps, SortableList, type SortableListProps, StarRating, type StarRatingProps, Surface, type SurfaceProps, Switch, type SwitchProps, Textarea as TextArea, TextBarDivider, type TextBarDividerProps, TextField, type TextFieldProps, type TextareaProps, ThemeProvider, TickGroup, type TickGroupProps, Toast, type ToastProps, Tooltip, type TooltipProps, Typography, type TypographyProps, backgroundCreator, chooseArticle, defaultInputValidation, emailValidation, passwordValidation, useDropdownMenu };
|
|
1240
|
+
export { AnnualController, type AnnualControllerProps, AuthContainerSurface, type AuthContainerSurfaceProps, AuthFormHeader, type AuthFormHeaderProps, Avatar, AvatarGroup, type AvatarGroupProps, type AvatarProps, Button, type ButtonProps, CheckboxGroup as CheckBoxGroup, Checkbox, type CheckboxGroupProps, type CheckboxProps, ColorBackgroundContainer, type ColorBackgroundContainerProps, DEFAULT_MAX_INPUT_LENGTH, Differential, type DifferentialProps, DropdownMenu, type FieldType, type FieldTypes, FormControlLabel, FormGenerator, type FormGeneratorConfig, type FormGeneratorHandler, GridOverlay, type GridOverlayProps, Html, type HtmlProps, Icon, IconButton, IconButtonGroup, InputLabel, InputLabelHelp, type InputLabelHelpProps, type InputLabelProps, Likert, type LikertProps, Link, type LinkProps, Loader, type LoaderProps, Logo, NumberField, type NumberFieldProps, Pill, type PillProps, PlanFeatureTable, type PlanFeatureTableProps, PlanTierCard, type PlanTierCardProps, PlanTierCardScale, type PlanTierCardScaleProps, Portal, type PortalProps, PoweredByWatermarkLogo, Progress, type ProgressProps, Radio, RadioGroup, type RadioGroupProps, type RadioProps, Rank, type RankProps, RichTextField, type RichTextFieldProps, Select, type SelectProps, Slider, type SliderProps, SortableList, type SortableListProps, StarRating, type StarRatingProps, Surface, type SurfaceProps, Switch, type SwitchProps, Textarea as TextArea, TextBarDivider, type TextBarDividerProps, TextField, type TextFieldProps, type TextareaProps, ThemeProvider, TickGroup, type TickGroupProps, Toast, type ToastProps, Tooltip, type TooltipProps, Typography, type TypographyProps, backgroundCreator, chooseArticle, defaultInputValidation, emailValidation, passwordValidation, useDropdownMenu };
|