@bluemarble/bm-components 0.0.11 → 0.0.14

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,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { CheckboxProps as MuiCheckboxProps, FormControlLabelProps } from "@mui/material";
3
2
  declare type CheckboxProps = CheckboxWithFormik | CheckboxWithoutFormik;
4
3
  interface CheckboxWithFormik extends MuiCheckboxProps {
@@ -1,6 +1,6 @@
1
1
  import React, { PropsWithChildren, ReactNode } from "react";
2
2
  import { TableCellProps } from "@mui/material";
3
- export interface ColumnTitleProps<T = {}> {
3
+ export interface ColumnTitleProps<T = Record<string, any>> {
4
4
  name: keyof T | "-";
5
5
  label: string;
6
6
  transformer?: (value: string | number | Date) => string;
@@ -1,8 +1,9 @@
1
1
  import { ReactNode } from "react";
2
- import { ButtonProps } from "@mui/material";
2
+ import { ButtonProps, CircularProgressProps } from "@mui/material";
3
3
  interface LargeButtonProps extends ButtonProps {
4
4
  loading?: boolean;
5
5
  children: ReactNode;
6
+ CircularProgressProps?: CircularProgressProps;
6
7
  }
7
- export declare const LargeButton: ({ loading, children, ...rest }: LargeButtonProps) => JSX.Element;
8
+ export declare const LargeButton: ({ loading, children, CircularProgressProps, ...rest }: LargeButtonProps) => JSX.Element;
8
9
  export {};
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { RadioGroupProps } from "@mui/material";
3
2
  declare type RadioOptionProps = {
4
3
  value: string | number | boolean;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { SwitchProps as MuiSwitchProps, FormControlLabelProps } from "@mui/material";
3
2
  declare type SwitchProps = SwitchWithFormik | SwitchWithoutFormik;
4
3
  interface SwitchWithFormik extends MuiSwitchProps {
@@ -1,4 +1,5 @@
1
1
  export { default as Grid, IFilter, ColumnTitleProps, FilterProps, filterData, Tr, Td, EditableTableCell, } from "./Grid";
2
+ export { GridV2 } from "./GridV2";
2
3
  export { Input } from "./Input";
3
4
  export { InputMask } from "./InputMask";
4
5
  export { Select } from "./Select";
package/dist/index.d.ts CHANGED
@@ -1,9 +1,10 @@
1
1
  /// <reference types="react" />
2
- import React, { ReactNode, FC } from 'react';
3
- import { TableCellProps, TextFieldProps, TableRowProps, StandardTextFieldProps, SelectProps as SelectProps$1, FormControlProps, InputLabelProps, AutocompleteRenderInputParams, AutocompleteProps as AutocompleteProps$1, CheckboxProps as CheckboxProps$1, FormControlLabelProps, SwitchProps as SwitchProps$1, RadioGroupProps, ButtonProps } from '@mui/material';
2
+ import React, { ReactNode, PropsWithChildren, FC } from 'react';
3
+ import { TableCellProps, TextFieldProps, TableRowProps, StandardTextFieldProps, SelectProps as SelectProps$1, FormControlProps, InputLabelProps, AutocompleteRenderInputParams, AutocompleteProps as AutocompleteProps$1, CheckboxProps as CheckboxProps$1, FormControlLabelProps, SwitchProps as SwitchProps$1, RadioGroupProps, ButtonProps, CircularProgressProps } from '@mui/material';
4
+ import { TableOptions } from 'react-table';
4
5
  import IMask$1 from 'imask';
5
6
 
6
- interface ColumnTitleProps<T = {}> {
7
+ interface ColumnTitleProps<T = Record<string, any>> {
7
8
  name: keyof T | "-";
8
9
  label: string;
9
10
  transformer?: (value: string | number | Date) => string;
@@ -71,6 +72,10 @@ declare const Tr: React.MemoExoticComponent<(props: CustomTableRowProps) => JSX.
71
72
 
72
73
  declare const Td: React.MemoExoticComponent<({ children, ...props }: TableCellProps) => JSX.Element>;
73
74
 
75
+ interface GridV2Props<T extends Record<string, unknown>> extends TableOptions<T> {
76
+ }
77
+ declare function GridV2<T extends Record<string, any>>({ columns, data, }: PropsWithChildren<GridV2Props<T>>): JSX.Element;
78
+
74
79
  interface InputProps extends StandardTextFieldProps {
75
80
  name: string;
76
81
  label: string;
@@ -170,7 +175,8 @@ declare const Radio: ({ name, withFormik, ...rest }: RadioOptionsProps) => JSX.E
170
175
  interface LargeButtonProps extends ButtonProps {
171
176
  loading?: boolean;
172
177
  children: ReactNode;
178
+ CircularProgressProps?: CircularProgressProps;
173
179
  }
174
- declare const LargeButton: ({ loading, children, ...rest }: LargeButtonProps) => JSX.Element;
180
+ declare const LargeButton: ({ loading, children, CircularProgressProps, ...rest }: LargeButtonProps) => JSX.Element;
175
181
 
176
- export { Autocomplete, Checkbox, ColumnTitleProps, EditableTableCell, FilterProps, Grid, IFilter, Input, InputMask, LargeButton, Radio, Select, Switch, Td, Tr, filterData };
182
+ export { Autocomplete, Checkbox, ColumnTitleProps, EditableTableCell, FilterProps, Grid, GridV2, IFilter, Input, InputMask, LargeButton, Radio, Select, Switch, Td, Tr, filterData };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bluemarble/bm-components",
3
- "version": "0.0.11",
3
+ "version": "0.0.14",
4
4
  "description": "BM components",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",