@pdg/react-form 1.0.76 → 1.0.78

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.
@@ -1,5 +1,6 @@
1
- import { PrivateMonthPickerBaseValue, PrivateMonthPickerProps } from '../PrivateMonthPicker.types';
1
+ import { PrivateMonthPickerBaseValue, PrivateMonthPickerProps, PrivateMonthPickerValue } from '../PrivateMonthPicker.types';
2
2
  export interface PrivateMonthPickerMonthListProps extends Pick<PrivateMonthPickerProps, 'value' | 'disablePast' | 'disableFuture' | 'selectFromValue' | 'selectToValue'> {
3
+ defaultValue?: PrivateMonthPickerValue;
3
4
  minAvailableValue: PrivateMonthPickerBaseValue;
4
5
  maxAvailableValue: PrivateMonthPickerBaseValue;
5
6
  onChange(value: PrivateMonthPickerBaseValue): void;
@@ -33,6 +33,8 @@ export interface FormValueItemBaseCommands<T, AllowUndefinedValue extends boolea
33
33
  isExceptValue(): boolean;
34
34
  isDisabled(): boolean;
35
35
  setDisabled(disabled: boolean): void;
36
+ isHidden(): boolean;
37
+ setHidden(hidden: boolean): void;
36
38
  focus(): void;
37
39
  focusValidate(): void;
38
40
  validate(): boolean;
@@ -121,6 +123,7 @@ export interface FormValueItemProps<T, AllowUndefinedValue extends boolean = tru
121
123
  disabled?: boolean;
122
124
  readOnly?: boolean;
123
125
  error?: boolean;
126
+ hidden?: boolean;
124
127
  exceptValue?: boolean;
125
128
  helperText?: ReactNode;
126
129
  data?: FormValueItemData;
@@ -32,6 +32,8 @@ export interface FormCommands {
32
32
  isExceptValue(name: string): boolean;
33
33
  isDisabled(name: string): boolean;
34
34
  setDisabled(name: string, disabled: boolean): void;
35
+ isHidden(name: string): boolean;
36
+ setHidden(name: string, hidden: boolean): void;
35
37
  focus(name: string): void;
36
38
  validate(name: string): boolean;
37
39
  setError(name: string, error: boolean, helperText: ReactNode): void;
@@ -27,7 +27,6 @@ export interface FormAutocompleteProps<T extends FormAutocompleteSingleValue, Mu
27
27
  openOnFocus?: boolean;
28
28
  disableClearable?: boolean;
29
29
  async?: boolean;
30
- hidden?: boolean;
31
30
  onLoadItems?: (inputValue?: string) => Promise<FormAutocompleteItems<T>>;
32
31
  onAsyncLoadValueItem?: (value: FormAutocompleteValue<T, Multiple>) => Promise<FormAutocompleteComponentValue<T, Multiple>>;
33
32
  onRenderItem?: (item: FormAutocompleteItem<T>) => ReactNode;
@@ -11,7 +11,6 @@ export interface FormCheckboxProps extends CommonSxProps, Omit<CheckboxProps, 'c
11
11
  text?: ReactNode;
12
12
  inputRef?: RefObject<HTMLInputElement>;
13
13
  action?: RefObject<ButtonBaseActions>;
14
- hidden?: boolean;
15
14
  onChange?(checked: boolean): void;
16
15
  }
17
16
  export declare const FormCheckboxDefaultProps: Pick<FormCheckboxProps, 'checked' | 'value' | 'uncheckedValue'>;
@@ -39,7 +39,6 @@ export interface FormDateRangePickerProps extends CommonSxProps, Omit<FormValueI
39
39
  disableFuture?: boolean;
40
40
  minDate?: Dayjs;
41
41
  maxDate?: Dayjs;
42
- hidden?: boolean;
43
42
  onGetActionButtons?(): {
44
43
  label: string;
45
44
  start: Dayjs;
@@ -20,7 +20,6 @@ export interface FormFileProps extends CommonSxProps, FormValueItemProps<FormFil
20
20
  labelShrink?: boolean;
21
21
  maxFileSize?: number;
22
22
  preview?: ReactNode;
23
- hidden?: boolean;
24
23
  onFile?(file: File): Promise<string>;
25
24
  onLink?(url: string): Promise<string>;
26
25
  }
@@ -6,7 +6,6 @@ export type FormMonthPickerBaseValue = PrivateMonthPickerBaseValue;
6
6
  export type FormMonthPickerValue = PrivateMonthPickerValue;
7
7
  export interface FormMonthPickerProps extends CommonSxProps, FormValueItemProps<FormMonthPickerValue, false> {
8
8
  required?: boolean;
9
- hidden?: boolean;
10
9
  icon?: string;
11
10
  format?: string;
12
11
  labelShrink?: boolean;
@@ -10,7 +10,6 @@ export interface FormMonthRangePickerProps extends CommonSxProps, Omit<FormValue
10
10
  endLabel?: ReactNode;
11
11
  endLabelIcon?: string;
12
12
  required?: boolean;
13
- hidden?: boolean;
14
13
  icon?: string;
15
14
  format?: string;
16
15
  labelShrink?: boolean;
@@ -15,7 +15,6 @@ export interface FormRadioGroupProps<T extends FormRadioGroupSingleValue> extend
15
15
  inline?: boolean;
16
16
  loading?: boolean;
17
17
  nowrap?: boolean;
18
- hidden?: boolean;
19
18
  onLoadItems?(): Promise<FormRadioGroupItem<T>[]>;
20
19
  onValue?(value: FormRadioGroupValue<T>): FormRadioGroupValue<T>;
21
20
  }
@@ -6,7 +6,6 @@ export interface FormRatingProps extends CommonSxProps, PartialPick<RatingProps,
6
6
  required?: boolean;
7
7
  icon?: string;
8
8
  emptyIcon?: string;
9
- hidden?: boolean;
10
9
  onValue?(value: FormRatingValue): FormRatingValue;
11
10
  }
12
11
  export declare const FormRatingDefaultProps: Pick<FormRatingProps, 'value' | 'precision'>;
@@ -6,7 +6,6 @@ export interface FormTextEditorProps extends CommonSxProps, Omit<FormValueItemPr
6
6
  required?: boolean;
7
7
  menubar?: boolean;
8
8
  height?: number;
9
- hidden?: boolean;
10
9
  onImageUpload?(blob: Blob, success: (url: string) => void, failure: (err: string) => void, progress?: (percent: number) => void): void;
11
10
  }
12
11
  export declare const FormTextEditorDefaultProps: Pick<FormTextEditorProps, 'value' | 'menubar' | 'height'>;
@@ -20,7 +20,6 @@ export interface FormToggleButtonGroupProps<T extends FormToggleButtonGroupSingl
20
20
  formValueSeparator?: string;
21
21
  formValueSort?: boolean;
22
22
  loading?: boolean;
23
- hidden?: boolean;
24
23
  itemWidth?: number | string;
25
24
  onLoadItems?: () => Promise<FormToggleButtonGroupItem<T>[]>;
26
25
  onValue?: (value: FormToggleButtonGroupValue<T, Multiple>) => FormToggleButtonGroupValue<T, Multiple>;
@@ -6,7 +6,6 @@ export type FormYearPickerBaseValue = PrivateYearPickerBaseValue;
6
6
  export type FormYearPickerValue = PrivateYearPickerValue;
7
7
  export interface FormYearPickerProps extends CommonSxProps, FormValueItemProps<FormYearPickerValue, false> {
8
8
  required?: boolean;
9
- hidden?: boolean;
10
9
  icon?: string;
11
10
  format?: string;
12
11
  labelShrink?: boolean;
@@ -10,7 +10,6 @@ export interface FormYearRangePickerProps extends CommonSxProps, Omit<FormValueI
10
10
  endLabel?: ReactNode;
11
11
  endLabelIcon?: string;
12
12
  required?: boolean;
13
- hidden?: boolean;
14
13
  icon?: string;
15
14
  format?: string;
16
15
  labelShrink?: boolean;
@@ -14,7 +14,6 @@ export type FormTextFieldProps<T = FormTextFieldValue, AllowUndefinedValue exten
14
14
  startAdornment?: ReactNode;
15
15
  endAdornment?: ReactNode;
16
16
  noFormValueItem?: boolean;
17
- hidden?: boolean;
18
17
  disableReturnKey?: boolean;
19
18
  onValue?(value: V): V;
20
19
  };
@@ -0,0 +1,17 @@
1
+ /// <reference types="react" />
2
+ export declare const StyledItem: import("@emotion/styled").StyledComponent<import("@mui/system").SystemProps<import("@mui/material").Theme> & {
3
+ children?: import("react").ReactNode;
4
+ classes?: Partial<import("@mui/material").GridClasses> | undefined;
5
+ columns?: import("@mui/system").ResponsiveStyleValue<number> | undefined;
6
+ columnSpacing?: import("@mui/system").ResponsiveStyleValue<import("@mui/material").GridSpacing> | undefined;
7
+ container?: boolean | undefined;
8
+ direction?: import("@mui/system").ResponsiveStyleValue<import("@mui/material").GridDirection> | undefined;
9
+ item?: boolean | undefined;
10
+ rowSpacing?: import("@mui/system").ResponsiveStyleValue<import("@mui/material").GridSpacing> | undefined;
11
+ spacing?: import("@mui/system").ResponsiveStyleValue<import("@mui/material").GridSpacing> | undefined;
12
+ sx?: import("@mui/material").SxProps<import("@mui/material").Theme> | undefined;
13
+ wrap?: import("@mui/material").GridWrap | undefined;
14
+ zeroMinWidth?: boolean | undefined;
15
+ } & import("@mui/material").RegularBreakpoints & import("@mui/material/OverridableComponent").CommonProps & Omit<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
16
+ ref?: ((instance: HTMLDivElement | null) => void) | import("react").RefObject<HTMLDivElement> | null | undefined;
17
+ }, keyof import("@mui/material/OverridableComponent").CommonProps | "direction" | "columns" | "container" | ("border" | "borderTop" | "borderRight" | "borderBottom" | "borderLeft" | "borderColor" | "borderRadius" | "display" | "displayPrint" | "overflow" | "textOverflow" | "visibility" | "whiteSpace" | "flexBasis" | "flexDirection" | "flexWrap" | "justifyContent" | "alignItems" | "alignContent" | "order" | "flex" | "flexGrow" | "flexShrink" | "alignSelf" | "justifyItems" | "justifySelf" | "gap" | "columnGap" | "rowGap" | "gridColumn" | "gridRow" | "gridAutoFlow" | "gridAutoColumns" | "gridAutoRows" | "gridTemplateColumns" | "gridTemplateRows" | "gridTemplateAreas" | "gridArea" | "bgcolor" | "color" | "zIndex" | "position" | "top" | "right" | "bottom" | "left" | "boxShadow" | "width" | "maxWidth" | "minWidth" | "height" | "maxHeight" | "minHeight" | "boxSizing" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "my" | "p" | "pt" | "pr" | "pb" | "pl" | "px" | "py" | "margin" | "marginTop" | "marginRight" | "marginBottom" | "marginLeft" | "marginX" | "marginY" | "padding" | "paddingTop" | "paddingRight" | "paddingBottom" | "paddingLeft" | "paddingX" | "paddingY" | "typography" | "fontFamily" | "fontSize" | "fontStyle" | "fontWeight" | "letterSpacing" | "lineHeight" | "textAlign" | "textTransform") | "wrap" | "children" | "columnSpacing" | "item" | "rowSpacing" | "spacing" | "sx" | "zeroMinWidth" | keyof import("@mui/material").RegularBreakpoints> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;