@smart-factor/gem-ui-components 0.0.1
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 +29 -0
- package/dist/Drawer-STwjDQmP.js +8723 -0
- package/dist/components/AccordionSummary/AccordionSummary.d.ts +7 -0
- package/dist/components/AccordionSummary/AccordionSummary.stories.d.ts +8 -0
- package/dist/components/AccordionSummary/AccordionSummary.styles.d.ts +7 -0
- package/dist/components/Button/Button.d.ts +8 -0
- package/dist/components/Button/Button.stories.d.ts +8 -0
- package/dist/components/Button/Button.styles.d.ts +6 -0
- package/dist/components/Button/ButtonAdd.d.ts +3 -0
- package/dist/components/ButtonWithIcon/ButtonWithIcon.d.ts +10 -0
- package/dist/components/ButtonWithIcon/ButtonWithIcon.stories.d.ts +7 -0
- package/dist/components/Dialog/Dialog.d.ts +3 -0
- package/dist/components/Dialog/Dialog.stories.d.ts +7 -0
- package/dist/components/Dialog/Dialog.styles.d.ts +11 -0
- package/dist/components/Dialog/index.d.ts +2 -0
- package/dist/components/Dialog/types.d.ts +9 -0
- package/dist/components/Drawer/Drawer.d.ts +15 -0
- package/dist/components/Drawer/Drawer.stories.d.ts +8 -0
- package/dist/components/Drawer/DrawerContent.d.ts +6 -0
- package/dist/components/Drawer/DrawerFooter.d.ts +6 -0
- package/dist/components/Drawer/DrawerHeader.d.ts +7 -0
- package/dist/components/Drawer/index.d.ts +1 -0
- package/dist/components/Drawer/index.js +4 -0
- package/dist/components/Dropzone/Dropzone.d.ts +7 -0
- package/dist/components/Dropzone/Dropzone.stories.d.ts +9 -0
- package/dist/components/Dropzone/Dropzone.styles.d.ts +17 -0
- package/dist/components/Dropzone/DropzoneField.d.ts +12 -0
- package/dist/components/Dropzone/const.d.ts +12 -0
- package/dist/components/Dropzone/index.d.ts +3 -0
- package/dist/components/ElementsPicker/ElementsPicker.d.ts +8 -0
- package/dist/components/ElementsPicker/ElementsPicker.stories.d.ts +8 -0
- package/dist/components/ElementsPicker/ElementsPickerElement.d.ts +9 -0
- package/dist/components/ElementsPicker/index.d.ts +2 -0
- package/dist/components/FixedActionsBottomPanel/FixedActionsBottomPanel.d.ts +15 -0
- package/dist/components/FixedActionsBottomPanel/FixedActionsBottomPanel.stories.d.ts +9 -0
- package/dist/components/FixedActionsBottomPanel/FixedActionsBottomPanel.styles.d.ts +6 -0
- package/dist/components/FormComponents/ContextualSearch/ContextualSearch.d.ts +24 -0
- package/dist/components/FormComponents/ContextualSearch/ContextualSearch.stories.d.ts +10 -0
- package/dist/components/FormComponents/ContextualSearch/ContextualSearchOption.d.ts +13 -0
- package/dist/components/FormComponents/ContextualSearch/getTransformOnChange.d.ts +4 -0
- package/dist/components/FormComponents/ContextualSearch/getTransformValue.d.ts +3 -0
- package/dist/components/FormComponents/ContextualSearch/index.d.ts +2 -0
- package/dist/components/FormComponents/DatePicker/DatePicker.d.ts +12 -0
- package/dist/components/FormComponents/DatePicker/DatePicker.stories.d.ts +9 -0
- package/dist/components/FormComponents/DatePicker/DatePicker.styles.d.ts +7 -0
- package/dist/components/FormComponents/DateTimePicker/DateTimePicker.d.ts +12 -0
- package/dist/components/FormComponents/DateTimePicker/DateTimePicker.stories.d.ts +9 -0
- package/dist/components/FormComponents/DateTimePicker/DateTimePicker.styles.d.ts +7 -0
- package/dist/components/FormComponents/Input/Input.d.ts +11 -0
- package/dist/components/FormComponents/Input/Input.stories.d.ts +11 -0
- package/dist/components/FormComponents/Input/Input.styles.d.ts +3 -0
- package/dist/components/FormComponents/RadioChips/RadioChips.d.ts +21 -0
- package/dist/components/FormComponents/RadioChips/RadioChips.stories.d.ts +9 -0
- package/dist/components/FormComponents/RadioChips/RadioChips.styles.d.ts +10 -0
- package/dist/components/FormComponents/SearchInput/SearchInput.d.ts +8 -0
- package/dist/components/FormComponents/SearchInput/SearchInput.stories.d.ts +9 -0
- package/dist/components/FormComponents/SearchInput/SearchInput.styles.d.ts +1 -0
- package/dist/components/FormComponents/Select/Select.d.ts +29 -0
- package/dist/components/FormComponents/Select/Select.stories.d.ts +11 -0
- package/dist/components/FormComponents/Select/Select.styles.d.ts +4 -0
- package/dist/components/FormComponents/index.d.ts +8 -0
- package/dist/components/LoadingBackdrop/LoadingBackdrop.d.ts +7 -0
- package/dist/components/LoadingBackdrop/LoadingBackdrop.stories.d.ts +7 -0
- package/dist/components/LoadingBackdrop/index.d.ts +1 -0
- package/dist/components/ResizableWrapper/ResizableWrapper.d.ts +9 -0
- package/dist/components/ResizableWrapper/ResizableWrapper.stories.d.ts +7 -0
- package/dist/components/ResizableWrapper/ResizableWrapper.styles.d.ts +10 -0
- package/dist/components/SimpleInput/SimpleInput.d.ts +9 -0
- package/dist/components/SimpleInput/SimpleInput.stories.d.ts +7 -0
- package/dist/components/SimpleSelect/SimpleSelect.d.ts +13 -0
- package/dist/components/SimpleSelect/SimpleSelect.stories.d.ts +7 -0
- package/dist/components/Stepper/Stepper.d.ts +13 -0
- package/dist/components/Stepper/Stepper.stories.d.ts +7 -0
- package/dist/components/Stepper/Stepper.styles.d.ts +9 -0
- package/dist/components/StickyContainer/StickyContainer.d.ts +7 -0
- package/dist/components/StickyContainer/StickyContainer.stories.d.ts +7 -0
- package/dist/components/StickyContainer/StickyContainer.styles.d.ts +7 -0
- package/dist/components/TableComponents/ContextMenu/ContextMenu.d.ts +6 -0
- package/dist/components/TableComponents/ContextMenu/ContextMenu.stories.d.ts +7 -0
- package/dist/components/TableComponents/ContextMenu/ContextMenu.styles.d.ts +1 -0
- package/dist/components/TableComponents/ContextMenu/ContextMenuContext.d.ts +7 -0
- package/dist/components/TableComponents/ContextMenu/ContextMenuItem.d.ts +8 -0
- package/dist/components/TableComponents/ContextMenu/ContextMenuPropsContext/ContextMenuPropsContext.d.ts +6 -0
- package/dist/components/TableComponents/ContextMenu/ContextMenuPropsContext/useContextMenuProps.d.ts +3 -0
- package/dist/components/TableComponents/ContextMenu/index.d.ts +2 -0
- package/dist/components/TableComponents/TableActions/TableActions.d.ts +7 -0
- package/dist/components/TableComponents/TableActions/TableActions.stories.d.ts +7 -0
- package/dist/components/TableComponents/TableActions/index.d.ts +2 -0
- package/dist/components/TableComponents/TableRecord/TableRecord.d.ts +8 -0
- package/dist/components/TableComponents/TableRecord/index.d.ts +1 -0
- package/dist/components/TableComponents/TableWithPagination/TableWithPagination.d.ts +4 -0
- package/dist/components/TableComponents/TableWithPagination/TableWithPagination.stories.d.ts +12 -0
- package/dist/components/TableComponents/TableWithPagination/TableWrapper.d.ts +8 -0
- package/dist/components/TableComponents/TableWithPagination/types.d.ts +51 -0
- package/dist/components/TableComponents/index.d.ts +4 -0
- package/dist/components/TabsPanel/TabsPanel.d.ts +14 -0
- package/dist/components/TabsPanel/TabsPanel.stories.d.ts +7 -0
- package/dist/components/TabsPanel/TabsPanel.styles.d.ts +8 -0
- package/dist/components/Toast/Toast.stories.d.ts +7 -0
- package/dist/components/Toast/Toast.styles.d.ts +12 -0
- package/dist/components/Toast/ToastContent.d.ts +4 -0
- package/dist/components/Toast/errorToast.d.ts +1 -0
- package/dist/components/Toast/index.d.ts +2 -0
- package/dist/components/Toast/successToast.d.ts +1 -0
- package/dist/consts/data-grid.d.ts +122 -0
- package/dist/hooks/index.d.ts +4 -0
- package/dist/hooks/useContextMenu.d.ts +8 -0
- package/dist/hooks/useDataGridState.d.ts +9 -0
- package/dist/hooks/useGetFileUrl.d.ts +5 -0
- package/dist/hooks/useKeepDefinedValue.d.ts +1 -0
- package/dist/hooks/useScrollPosition.d.ts +2 -0
- package/dist/main.d.ts +23 -0
- package/dist/main.js +59502 -0
- package/dist/providers/GemUIComponentsProvider.d.ts +4 -0
- package/dist/providers/ToasterProvider.d.ts +1 -0
- package/dist/theme/theme.d.ts +13 -0
- package/package.json +96 -0
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { SearchInput } from '..';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
|
|
4
|
+
declare const meta: Meta<typeof SearchInput>;
|
|
5
|
+
export default meta;
|
|
6
|
+
type Story = StoryObj<typeof meta>;
|
|
7
|
+
export declare const Docs: Story;
|
|
8
|
+
export declare const Loading: Story;
|
|
9
|
+
export declare const WithSearchTerm: Story;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const StyledInput: import('@emotion/styled').StyledComponent<import('@mui/material').InputProps & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { Control, FieldValues, Path, PathValue } from 'react-hook-form';
|
|
3
|
+
import { SelectChangeEvent, SelectProps as MuiSelectProps } from '@mui/material';
|
|
4
|
+
|
|
5
|
+
export interface SelectValueOption {
|
|
6
|
+
value: string | number;
|
|
7
|
+
label: ReactNode;
|
|
8
|
+
disabled?: boolean;
|
|
9
|
+
}
|
|
10
|
+
type OnChangeHandler<T> = (event: SelectChangeEvent<PathValue<T, Path<T>>[]>, child: ReactNode) => void;
|
|
11
|
+
interface SelectProps<T extends FieldValues> {
|
|
12
|
+
name: Path<T>;
|
|
13
|
+
control: Control<T>;
|
|
14
|
+
label: string;
|
|
15
|
+
options: SelectValueOption[];
|
|
16
|
+
defaultValue?: PathValue<T, Path<T>>;
|
|
17
|
+
errorMessage?: string;
|
|
18
|
+
multiple?: boolean;
|
|
19
|
+
disabled?: boolean;
|
|
20
|
+
required?: boolean;
|
|
21
|
+
dataTestId?: string;
|
|
22
|
+
leadingOption?: ReactNode;
|
|
23
|
+
renderValue?: (value: PathValue<T, Path<T>> | PathValue<T, Path<T>>[]) => ReactNode;
|
|
24
|
+
onChange?: OnChangeHandler<T>;
|
|
25
|
+
variant?: MuiSelectProps['variant'];
|
|
26
|
+
size?: MuiSelectProps['size'];
|
|
27
|
+
}
|
|
28
|
+
export declare const Select: <T extends FieldValues>({ name, control, label, defaultValue: defaultValueProp, options, errorMessage: errorMessageProps, multiple, disabled, required, dataTestId, renderValue, onChange: onChangeProps, variant, size, }: SelectProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { Select } from './Select';
|
|
3
|
+
|
|
4
|
+
declare const meta: Meta<typeof Select>;
|
|
5
|
+
export default meta;
|
|
6
|
+
type Story = StoryObj<typeof meta>;
|
|
7
|
+
export declare const Docs: Story;
|
|
8
|
+
export declare const Default: Story;
|
|
9
|
+
export declare const Error: Story;
|
|
10
|
+
export declare const WithDefaultValue: Story;
|
|
11
|
+
export declare const MultiSelect: Story;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledSelectWrapper: import('@emotion/styled').StyledComponent<import('@mui/material').FormControlOwnProps & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
3
|
+
ref?: ((instance: HTMLDivElement | null) => void) | import('react').RefObject<HTMLDivElement> | null | undefined;
|
|
4
|
+
}, "className" | "style" | "classes" | "children" | "disabled" | "sx" | "color" | "margin" | "required" | "size" | "fullWidth" | "variant" | "error" | "focused" | "hiddenLabel"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export { ContextualSearch } from './ContextualSearch';
|
|
2
|
+
export { DatePicker } from './DatePicker/DatePicker';
|
|
3
|
+
export { DateTimePicker } from './DateTimePicker/DateTimePicker';
|
|
4
|
+
export { Input } from './Input/Input';
|
|
5
|
+
export { RadioChips } from './RadioChips/RadioChips';
|
|
6
|
+
export { SearchInput } from './SearchInput/SearchInput';
|
|
7
|
+
export type { SelectValueOption } from './Select/Select';
|
|
8
|
+
export { Select } from './Select/Select';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { LoadingBackdrop } from './LoadingBackdrop';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export interface ResizableWrapperProps {
|
|
3
|
+
children: React.ReactNode;
|
|
4
|
+
isOpen: boolean;
|
|
5
|
+
customCloseWidth?: number;
|
|
6
|
+
customCloseHeight?: number;
|
|
7
|
+
direction: 'horizontal' | 'vertical';
|
|
8
|
+
}
|
|
9
|
+
export declare const ResizableWrapper: ({ direction, children, isOpen, customCloseWidth, customCloseHeight, }: ResizableWrapperProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const Content: import('@emotion/styled').StyledComponent<import('@mui/system').BoxOwnProps<import('@mui/material').Theme> & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
3
|
+
ref?: ((instance: HTMLDivElement | null) => void) | import('react').RefObject<HTMLDivElement> | null | undefined;
|
|
4
|
+
}, keyof import('@mui/system').BoxOwnProps<import('@mui/material').Theme>> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
5
|
+
export declare const StyledResizableWrapper: import('@emotion/styled').StyledComponent<import('@mui/material').StackOwnProps & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
6
|
+
ref?: ((instance: HTMLDivElement | null) => void) | import('react').RefObject<HTMLDivElement> | null | undefined;
|
|
7
|
+
}, keyof import('@mui/material/OverridableComponent').CommonProps | keyof import('@mui/material').StackOwnProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & {
|
|
8
|
+
width: number | string;
|
|
9
|
+
height: number | string;
|
|
10
|
+
}, {}, {}>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { TextFieldProps } from '@mui/material';
|
|
2
|
+
import { SelectInputProps } from '@mui/material/Select/SelectInput';
|
|
3
|
+
|
|
4
|
+
export type SimpleInputProps<T extends SelectInputProps['value']> = {
|
|
5
|
+
value: T;
|
|
6
|
+
onChange(newValue: T): void;
|
|
7
|
+
errorMessage?: string | null;
|
|
8
|
+
} & TextFieldProps;
|
|
9
|
+
export declare const SimpleInput: <T extends unknown>({ id, value, label, onChange, type, sx, errorMessage, }: SimpleInputProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { SimpleInput, SimpleInputProps } from './SimpleInput';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
|
|
4
|
+
declare const meta: Meta<typeof SimpleInput>;
|
|
5
|
+
export default meta;
|
|
6
|
+
type Story = StoryObj<SimpleInputProps<string>>;
|
|
7
|
+
export declare const Docs: Story;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { SelectInputProps } from '@mui/material/Select/SelectInput';
|
|
2
|
+
|
|
3
|
+
export interface SimpleSelectProps<T extends SelectInputProps['value']> {
|
|
4
|
+
id: string;
|
|
5
|
+
value: T;
|
|
6
|
+
onChange(newValue: T): void;
|
|
7
|
+
label: string;
|
|
8
|
+
menuItems: {
|
|
9
|
+
value: string | number;
|
|
10
|
+
label: string;
|
|
11
|
+
}[];
|
|
12
|
+
}
|
|
13
|
+
export declare const SimpleSelect: <T extends unknown>({ id, value, label, onChange, menuItems, }: SimpleSelectProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { SimpleSelect, SimpleSelectProps } from './SimpleSelect';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
|
|
4
|
+
declare const meta: Meta<typeof SimpleSelect>;
|
|
5
|
+
export default meta;
|
|
6
|
+
type Story = StoryObj<SimpleSelectProps<string>>;
|
|
7
|
+
export declare const Docs: Story;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export interface StepperStep<T> {
|
|
3
|
+
label: string;
|
|
4
|
+
value: T;
|
|
5
|
+
}
|
|
6
|
+
export interface StepperProps<T extends number> {
|
|
7
|
+
steps: StepperStep<T>[];
|
|
8
|
+
activeStep: T;
|
|
9
|
+
setActiveStep: (newStep: T) => void;
|
|
10
|
+
stepsContent?: React.ReactNode[];
|
|
11
|
+
noHeader?: boolean;
|
|
12
|
+
}
|
|
13
|
+
export declare const Stepper: <T extends number>({ steps, activeStep, setActiveStep, stepsContent, noHeader, }: StepperProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledStepButton: import('@emotion/styled').StyledComponent<import('@mui/material').StepButtonOwnProps & Omit<import('@mui/material').ButtonBaseOwnProps, "classes"> & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & {
|
|
3
|
+
ref?: ((instance: HTMLButtonElement | null) => void) | import('react').RefObject<HTMLButtonElement> | null | undefined;
|
|
4
|
+
}, "className" | "style" | "classes" | "action" | "centerRipple" | "children" | "disabled" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "sx" | "tabIndex" | "TouchRippleProps" | "touchRippleRef" | "icon" | "optional"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
5
|
+
export declare const StyledStepper: import('@emotion/styled').StyledComponent<import('@mui/material').StepperOwnProps & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
6
|
+
ref?: ((instance: HTMLDivElement | null) => void) | import('react').RefObject<HTMLDivElement> | null | undefined;
|
|
7
|
+
}, "className" | "style" | "classes" | "children" | "sx" | "elevation" | "orientation" | "variant" | "square" | "activeStep" | "alternativeLabel" | "connector" | "nonLinear"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & {
|
|
8
|
+
noHeader?: boolean | undefined;
|
|
9
|
+
}, {}, {}>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { StackProps } from '@mui/material';
|
|
2
|
+
|
|
3
|
+
export interface StickyContainerProps extends StackProps {
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
withBoxShadow?: boolean;
|
|
6
|
+
}
|
|
7
|
+
export declare function StickyContainer({ children, top, withBoxShadow, ...rest }: StickyContainerProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledStickyContainer: import('@emotion/styled').StyledComponent<import('@mui/material').StackOwnProps & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
3
|
+
ref?: ((instance: HTMLDivElement | null) => void) | import('react').RefObject<HTMLDivElement> | null | undefined;
|
|
4
|
+
}, keyof import('@mui/material/OverridableComponent').CommonProps | keyof import('@mui/material').StackOwnProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & {
|
|
5
|
+
withBoxShadow?: boolean | undefined;
|
|
6
|
+
isScrolled: boolean;
|
|
7
|
+
}, {}, {}>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const StyledMenu: import('@emotion/styled').StyledComponent<import('@mui/material').MenuProps & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { MenuItemProps } from '@mui/material';
|
|
2
|
+
|
|
3
|
+
type ContextMenuItemLinkProps = MenuItemProps & {
|
|
4
|
+
to: string;
|
|
5
|
+
};
|
|
6
|
+
type ContextMenuItemProps = MenuItemProps | ContextMenuItemLinkProps;
|
|
7
|
+
export declare function ContextMenuItem(props: ContextMenuItemProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TableRecord } from './TableRecord';
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { GridValidRowModel } from '@mui/x-data-grid-pro';
|
|
2
|
+
import { TableWithPaginationProps } from './types';
|
|
3
|
+
|
|
4
|
+
export declare const TableWithPagination: <T extends GridValidRowModel>({ rowsData, paginationAndSortState, setPaginationAndSortState, isLoading, columns, offset, tableKey, filterModel, onFilterModelChange, pinnedColumns, }: TableWithPaginationProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { GridValidRowModel } from '@mui/x-data-grid-pro';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
import { TableWithPagination } from './TableWithPagination';
|
|
4
|
+
import { TableWithPaginationProps } from './types';
|
|
5
|
+
|
|
6
|
+
declare const meta: Meta<typeof TableWithPagination>;
|
|
7
|
+
export default meta;
|
|
8
|
+
type Story = StoryObj<TableWithPaginationProps<GridValidRowModel>>;
|
|
9
|
+
export declare const Docs: Story;
|
|
10
|
+
export declare const Default: Story;
|
|
11
|
+
export declare const Loading: Story;
|
|
12
|
+
export declare const Empty: Story;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { Dispatch, SetStateAction } from 'react';
|
|
2
|
+
import { GridCallbackDetails, GridColDef, GridColumnPinningState, GridFilterModel, GridValidRowModel } from '@mui/x-data-grid-pro';
|
|
3
|
+
|
|
4
|
+
interface SortState {
|
|
5
|
+
field: string;
|
|
6
|
+
direction: 'asc' | 'desc' | '';
|
|
7
|
+
}
|
|
8
|
+
export interface PaginationAndSortState {
|
|
9
|
+
page: number;
|
|
10
|
+
size: number;
|
|
11
|
+
sort: SortState;
|
|
12
|
+
}
|
|
13
|
+
export interface SortObject {
|
|
14
|
+
sorted?: boolean;
|
|
15
|
+
unsorted?: boolean;
|
|
16
|
+
empty?: boolean;
|
|
17
|
+
}
|
|
18
|
+
export interface PageableObject {
|
|
19
|
+
offset?: number;
|
|
20
|
+
sort?: SortObject;
|
|
21
|
+
pageSize?: number;
|
|
22
|
+
pageNumber?: number;
|
|
23
|
+
paged?: boolean;
|
|
24
|
+
unpaged?: boolean;
|
|
25
|
+
}
|
|
26
|
+
export interface GenericPageDataDto<T> {
|
|
27
|
+
total_elements?: number;
|
|
28
|
+
total_pages?: number;
|
|
29
|
+
size?: number;
|
|
30
|
+
content?: T[];
|
|
31
|
+
number?: number;
|
|
32
|
+
sort?: SortObject;
|
|
33
|
+
pageable?: PageableObject;
|
|
34
|
+
first?: boolean;
|
|
35
|
+
last?: boolean;
|
|
36
|
+
number_of_elements?: number;
|
|
37
|
+
empty?: boolean;
|
|
38
|
+
}
|
|
39
|
+
export interface TableWithPaginationProps<T extends GridValidRowModel> {
|
|
40
|
+
rowsData: GenericPageDataDto<T> | undefined;
|
|
41
|
+
isLoading: boolean;
|
|
42
|
+
columns: GridColDef<T>[];
|
|
43
|
+
tableKey: string;
|
|
44
|
+
offset?: number;
|
|
45
|
+
pinnedColumns?: GridColumnPinningState;
|
|
46
|
+
paginationAndSortState: PaginationAndSortState;
|
|
47
|
+
setPaginationAndSortState: Dispatch<SetStateAction<PaginationAndSortState>>;
|
|
48
|
+
filterModel?: GridFilterModel;
|
|
49
|
+
onFilterModelChange?: (model: GridFilterModel, details: GridCallbackDetails<'filter'>) => void;
|
|
50
|
+
}
|
|
51
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { TabProps as TabPropsMUI } from '@mui/material';
|
|
2
|
+
|
|
3
|
+
export interface TabProps extends TabPropsMUI {
|
|
4
|
+
label: string;
|
|
5
|
+
icon?: JSX.Element;
|
|
6
|
+
}
|
|
7
|
+
export interface TabsPanelProps {
|
|
8
|
+
tabs: TabProps[];
|
|
9
|
+
children: JSX.Element[];
|
|
10
|
+
onChange?: (value: number) => void;
|
|
11
|
+
defaultTab?: number;
|
|
12
|
+
extraComponent?: JSX.Element;
|
|
13
|
+
}
|
|
14
|
+
export declare const TabsPanel: ({ tabs, children, onChange, defaultTab, extraComponent, }: TabsPanelProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { TabProps } from './TabsPanel';
|
|
2
|
+
|
|
3
|
+
export declare const StyledTab: import('@emotion/styled').StyledComponent<TabProps & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
4
|
+
export declare const StyledTabs: import('@emotion/styled').StyledComponent<import('@mui/material').TabsOwnProps & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
5
|
+
ref?: ((instance: HTMLDivElement | null) => void) | import('react').RefObject<HTMLDivElement> | null | undefined;
|
|
6
|
+
}, "className" | "style" | "classes" | "action" | "children" | "sx" | "aria-label" | "aria-labelledby" | "onChange" | "orientation" | "value" | "variant" | "slots" | "slotProps" | "allowScrollButtonsMobile" | "centered" | "indicatorColor" | "ScrollButtonComponent" | "scrollButtons" | "selectionFollowsFocus" | "TabIndicatorProps" | "TabScrollButtonProps" | "textColor" | "visibleScrollbar"> & {
|
|
7
|
+
component?: import('react').ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
8
|
+
} & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledToastMessage: import('@emotion/styled').StyledComponent<import('@mui/material').TypographyOwnProps & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
|
|
3
|
+
ref?: ((instance: HTMLSpanElement | null) => void) | import('react').RefObject<HTMLSpanElement> | null | undefined;
|
|
4
|
+
}, "className" | "style" | "classes" | "children" | "sx" | "p" | "color" | "border" | "boxShadow" | "fontWeight" | "zIndex" | "alignContent" | "alignItems" | "alignSelf" | "bottom" | "boxSizing" | "columnGap" | "display" | "flexBasis" | "flexDirection" | "flexGrow" | "flexShrink" | "flexWrap" | "fontFamily" | "fontSize" | "fontStyle" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateColumns" | "gridTemplateRows" | "height" | "justifyContent" | "justifyItems" | "justifySelf" | "left" | "letterSpacing" | "lineHeight" | "marginBlockEnd" | "marginBlockStart" | "marginBottom" | "marginInlineEnd" | "marginInlineStart" | "marginLeft" | "marginRight" | "marginTop" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "order" | "paddingBlockEnd" | "paddingBlockStart" | "paddingBottom" | "paddingInlineEnd" | "paddingInlineStart" | "paddingLeft" | "paddingRight" | "paddingTop" | "position" | "right" | "rowGap" | "textAlign" | "textOverflow" | "textTransform" | "top" | "visibility" | "whiteSpace" | "width" | "borderBottom" | "borderColor" | "borderLeft" | "borderRadius" | "borderRight" | "borderTop" | "flex" | "gap" | "gridArea" | "gridColumn" | "gridRow" | "margin" | "marginBlock" | "marginInline" | "overflow" | "padding" | "paddingBlock" | "paddingInline" | "bgcolor" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "typography" | "displayPrint" | "align" | "variant" | "gutterBottom" | "noWrap" | "paragraph" | "variantMapping"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
5
|
+
export declare const StyledToastClose: import('@emotion/styled').StyledComponent<import('@mui/material').TypographyOwnProps & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
|
|
6
|
+
ref?: ((instance: HTMLSpanElement | null) => void) | import('react').RefObject<HTMLSpanElement> | null | undefined;
|
|
7
|
+
}, "className" | "style" | "classes" | "children" | "sx" | "p" | "color" | "border" | "boxShadow" | "fontWeight" | "zIndex" | "alignContent" | "alignItems" | "alignSelf" | "bottom" | "boxSizing" | "columnGap" | "display" | "flexBasis" | "flexDirection" | "flexGrow" | "flexShrink" | "flexWrap" | "fontFamily" | "fontSize" | "fontStyle" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateColumns" | "gridTemplateRows" | "height" | "justifyContent" | "justifyItems" | "justifySelf" | "left" | "letterSpacing" | "lineHeight" | "marginBlockEnd" | "marginBlockStart" | "marginBottom" | "marginInlineEnd" | "marginInlineStart" | "marginLeft" | "marginRight" | "marginTop" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "order" | "paddingBlockEnd" | "paddingBlockStart" | "paddingBottom" | "paddingInlineEnd" | "paddingInlineStart" | "paddingLeft" | "paddingRight" | "paddingTop" | "position" | "right" | "rowGap" | "textAlign" | "textOverflow" | "textTransform" | "top" | "visibility" | "whiteSpace" | "width" | "borderBottom" | "borderColor" | "borderLeft" | "borderRadius" | "borderRight" | "borderTop" | "flex" | "gap" | "gridArea" | "gridColumn" | "gridRow" | "margin" | "marginBlock" | "marginInline" | "overflow" | "padding" | "paddingBlock" | "paddingInline" | "bgcolor" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "typography" | "displayPrint" | "align" | "variant" | "gutterBottom" | "noWrap" | "paragraph" | "variantMapping"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
8
|
+
export declare const ToastWrapper: import('@emotion/styled').StyledComponent<import('@mui/material').StackOwnProps & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
9
|
+
ref?: ((instance: HTMLDivElement | null) => void) | import('react').RefObject<HTMLDivElement> | null | undefined;
|
|
10
|
+
}, keyof import('@mui/material/OverridableComponent').CommonProps | keyof import('@mui/material').StackOwnProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & {
|
|
11
|
+
type: 'success' | 'error';
|
|
12
|
+
}, {}, {}>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const errorToast: (message: string) => void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const successToast: (message: string) => void;
|