@symply.io/basic-components 1.0.0-beta.12 → 1.0.0-beta.13

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.
Files changed (37) hide show
  1. package/AlertDialog/index.d.ts +1 -0
  2. package/Autocomplete/index.d.ts +1 -0
  3. package/Autocomplete/index.js +0 -1
  4. package/Autocomplete/types.d.ts +6 -5
  5. package/AutocompleteWithFilter/index.d.ts +1 -0
  6. package/AutocompleteWithFilter/types.d.ts +3 -4
  7. package/BasicModal/Content.d.ts +1 -0
  8. package/BasicModal/index.d.ts +1 -0
  9. package/BasicTable/TableBodyRow.d.ts +1 -0
  10. package/BasicTable/TableFooter.d.ts +1 -0
  11. package/BasicTable/TableHeader.d.ts +1 -0
  12. package/BasicTable/index.d.ts +1 -0
  13. package/BreadCrumbs/index.d.ts +1 -0
  14. package/CheckBox/CheckBox.d.ts +1 -0
  15. package/CheckBox/CheckBoxGroup.d.ts +1 -0
  16. package/CheckBox/types.d.ts +2 -2
  17. package/Copyright/index.d.ts +1 -0
  18. package/DateInput/FullDateInput/index.d.ts +1 -0
  19. package/DateInput/MonthDayInput/index.d.ts +1 -0
  20. package/DateInput/MonthYearInput/index.d.ts +1 -0
  21. package/DigitInput/index.d.ts +1 -0
  22. package/DynamicHeaderBar/HeaderButtons.d.ts +1 -0
  23. package/FeinInput/index.d.ts +1 -0
  24. package/FormRadioGroup/index.d.ts +1 -0
  25. package/FormSelector/MultipleSelector.d.ts +1 -0
  26. package/FormSelector/SimpleSelector.d.ts +1 -0
  27. package/LoadingModal/index.d.ts +1 -0
  28. package/MenuButtonGroup/MenuItem.d.ts +1 -0
  29. package/README.md +4 -4
  30. package/Sidebar/SidebarItem.d.ts +1 -0
  31. package/Sidebar/SidebarLink.d.ts +1 -0
  32. package/Sidebar/index.d.ts +1 -0
  33. package/SocialInput/index.d.ts +1 -0
  34. package/TablePagination/Actions.d.ts +1 -0
  35. package/TablePagination/index.d.ts +1 -0
  36. package/VideoPlayerModal/index.d.ts +1 -0
  37. package/package.json +8 -6
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { AlertDialogProps } from "./types";
2
3
  declare const AlertDialog: (props: AlertDialogProps) => JSX.Element;
3
4
  export default AlertDialog;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { AutocompleteProps } from "./types";
2
3
  declare function CustomAutocomplete<T, multiple extends boolean | undefined = false>(props: AutocompleteProps<T, multiple>): JSX.Element;
3
4
  export default CustomAutocomplete;
@@ -31,7 +31,6 @@ function CustomAutocomplete(props) {
31
31
  var theme = useCustomTheme({ primaryColor: primaryColor, secondaryColor: secondaryColor });
32
32
  var _a = useInteractions(), inputValue = _a.inputValue, onInputChange = _a.onInputChange;
33
33
  return (_jsx(ThemeProvider, __assign({ theme: theme }, { children: _jsx(Autocomplete, { size: size, fullWidth: true, options: options, multiple: multiple, onChange: function (_, val) {
34
- console.log({ val: val });
35
34
  onChange(val);
36
35
  }, isOptionEqualToValue: function (opt, val) { return opt.label === val.label; }, value: value, inputValue: inputValue, onInputChange: onInputChange, renderInput: function (params) { return _jsx(TextField, __assign({}, params, rest, { size: size })); } }) })));
37
36
  }
@@ -1,15 +1,16 @@
1
1
  import { CSSProperties } from "react";
2
2
  import { TextFieldProps } from "@mui/material/TextField";
3
- export declare type AutocompleteOptionType<T> = T & {
3
+ export declare type AutocompleteOptionType<T = {
4
+ [name: string]: unknown;
5
+ }> = T & {
4
6
  label: string;
5
7
  };
6
- export declare type AutocompleteValueNonNullableType<T, multiple extends boolean | undefined> = multiple extends false | undefined ? AutocompleteOptionType<T> : Array<AutocompleteOptionType<T>>;
7
- export declare type AutocompleteValueNullableType<T, multiple extends boolean | undefined> = multiple extends false | undefined ? AutocompleteOptionType<T> | null : Array<AutocompleteOptionType<T>> | null;
8
+ export declare type AutocompleteValueType<T, multiple extends boolean | undefined> = multiple extends false | undefined ? AutocompleteOptionType<T> | null : Array<AutocompleteOptionType<T>>;
8
9
  export interface AutocompleteProps<T, multiple extends boolean | undefined> extends Omit<TextFieldProps, "onChange"> {
9
10
  multiple?: multiple;
10
11
  options: Array<AutocompleteOptionType<T>>;
11
- value?: AutocompleteValueNonNullableType<T, multiple>;
12
+ value: AutocompleteValueType<T, multiple>;
12
13
  primaryColor?: CSSProperties["color"];
13
14
  secondaryColor?: CSSProperties["color"];
14
- onChange: (value: AutocompleteValueNullableType<T, multiple>) => void;
15
+ onChange: (value: AutocompleteValueType<T, multiple>) => void;
15
16
  }
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { AutocompleteWithFilterProps } from "./types";
2
3
  declare function AutocompleteWithFilter<T, multiple extends boolean | undefined = false>(props: AutocompleteWithFilterProps<T, multiple>): JSX.Element;
3
4
  export default AutocompleteWithFilter;
@@ -3,14 +3,13 @@ import { TextFieldProps } from "@mui/material/TextField";
3
3
  export declare type AutocompleteWithFilterOptionType<T> = T & {
4
4
  label: string;
5
5
  };
6
- export declare type AutocompleteWithFilterlNonNullableValueType<T, multiple extends boolean | undefined> = multiple extends false | undefined ? AutocompleteWithFilterOptionType<T> : Array<AutocompleteWithFilterOptionType<T>>;
7
- export declare type AutocompleteWithFilterlNullableValueType<T, multiple extends boolean | undefined> = multiple extends false | undefined ? AutocompleteWithFilterOptionType<T> | null : Array<AutocompleteWithFilterOptionType<T>> | null;
6
+ export declare type AutocompleteWithFilterlValueType<T, multiple extends boolean | undefined> = multiple extends false | undefined ? AutocompleteWithFilterOptionType<T> | null : Array<AutocompleteWithFilterOptionType<T>>;
8
7
  export interface AutocompleteWithFilterProps<T, multiple extends boolean | undefined> extends Omit<TextFieldProps, "onChange"> {
9
- value: AutocompleteWithFilterlNonNullableValueType<T, multiple>;
8
+ value: AutocompleteWithFilterlValueType<T, multiple>;
10
9
  options: Array<AutocompleteWithFilterOptionType<T>>;
11
10
  disableCloseOnSelect?: boolean;
12
11
  multiple?: multiple;
13
12
  primaryColor?: CSSProperties["color"];
14
13
  secondaryColor?: CSSProperties["color"];
15
- onChange: (value: AutocompleteWithFilterlNullableValueType<T, multiple>) => void;
14
+ onChange: (value: AutocompleteWithFilterlValueType<T, multiple>) => void;
16
15
  }
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { BasicModalContentProps } from "./types";
2
3
  declare function Content(props: BasicModalContentProps): JSX.Element;
3
4
  export default Content;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { BasicModalProps } from "./types";
2
3
  declare function BasicModal(props: BasicModalProps): JSX.Element;
3
4
  export default BasicModal;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { BasicTableBodyRowProps } from "./types";
2
3
  declare function BasicTableBodyRow(props: BasicTableBodyRowProps): JSX.Element;
3
4
  export default BasicTableBodyRow;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { BasicTableFooterProps } from "./types";
2
3
  declare function BasicTableFooter(props: BasicTableFooterProps): JSX.Element;
3
4
  export default BasicTableFooter;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { BasicTableHeaderProps } from "./types";
2
3
  declare function BasicTableHeader(props: BasicTableHeaderProps): JSX.Element;
3
4
  export default BasicTableHeader;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { BasicTableProps } from "./types";
2
3
  declare function BasicTable(props: BasicTableProps): JSX.Element;
3
4
  export default BasicTable;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { BreadCrumbsProps } from "./types";
2
3
  declare function Crumbs(props: BreadCrumbsProps): JSX.Element;
3
4
  export default Crumbs;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { CheckBoxProps } from "./types";
2
3
  export declare function CheckBox(props: CheckBoxProps): JSX.Element;
3
4
  export default CheckBox;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { CheckBoxGroupProps } from "./types";
2
3
  export declare function CheckBoxGroup(props: CheckBoxGroupProps): JSX.Element;
3
4
  export default CheckBoxGroup;
@@ -1,8 +1,8 @@
1
- import { CSSProperties, ReactNode } from "react";
1
+ import { CSSProperties, ReactElement } from "react";
2
2
  import { CheckboxProps } from "@mui/material/Checkbox";
3
3
  import { FormGroupProps } from "@mui/material/FormGroup";
4
4
  export interface CheckBoxProps extends Omit<CheckboxProps, "onChange"> {
5
- label: string | ReactNode;
5
+ label: string | ReactElement;
6
6
  onChange: (val: boolean) => void;
7
7
  primaryColor?: CSSProperties["color"];
8
8
  secondaryColor?: CSSProperties["color"];
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { CopyrightProps } from "./types";
2
3
  declare function Copyright(props: CopyrightProps): JSX.Element;
3
4
  export default Copyright;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { DateInputprops } from "./types";
2
3
  export declare function MonthDayYearFormat(str: string): string;
3
4
  export declare function onValidateDate(dateString: string): boolean;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { DateInputprops } from "./types";
2
3
  export declare function MonthDayFormat(str: string): string;
3
4
  export declare function onValidateMonthDay(monthDayString: string): boolean;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { DateInputprops } from "./types";
2
3
  export declare function MonthYearFormat(str: string): string;
3
4
  export declare function onValidateMonthYear(monthYearString: string): boolean;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { DigitInputProps } from "./types";
2
3
  declare function DigitInput(props: DigitInputProps): JSX.Element;
3
4
  export default DigitInput;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { HeaderButtonProps } from "./types";
2
3
  export interface HeaderButtonsProps {
3
4
  buttons: Array<HeaderButtonProps>;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { FeinInputProps } from "./types";
2
3
  export declare function FeinInputFormat(str: string): string;
3
4
  export declare function onValidateFein(feinString: string): boolean;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { FormRadioGroupProps } from "./types";
2
3
  declare function FormRadioGroup(props: FormRadioGroupProps): JSX.Element;
3
4
  export default FormRadioGroup;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { MultipleSelectorProps } from "./types";
2
3
  declare function MultipleSelector(props: MultipleSelectorProps): JSX.Element;
3
4
  export default MultipleSelector;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { SimpleSelectorProps } from "./types";
2
3
  declare function SimpleSelector(props: SimpleSelectorProps): JSX.Element;
3
4
  export default SimpleSelector;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { LoadingModalProps } from "./types";
2
3
  declare function LoadingModal(props: LoadingModalProps): JSX.Element;
3
4
  export default LoadingModal;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { MenuItemProps } from "@mui/material/MenuItem";
2
3
  import { ListItemIconProps } from "@mui/material/ListItemIcon";
3
4
  export interface ButtonItemProps {
package/README.md CHANGED
@@ -298,10 +298,10 @@ import CheckBox from '@symply.io/basic-components/CheckBox/CheckBox';
298
298
 
299
299
  <h5>Props</h5>
300
300
 
301
- | Name | Type | Default | Required | Description |
302
- | -------- | ------------------- | ------- | -------- | ------------------------------------------------------------ |
303
- | label | string \| ReactNode | | true | The label of the checkbox. |
304
- | onChange | func | | true | Callback fired when the `checkbox` value is changed.<br />**Signature:**<br/>`function(value: boolean) => void`<br/>*value:* The value of the `checkbox` element. |
301
+ | Name | Type | Default | Required | Description |
302
+ | -------- | ---------------------- | ------- | -------- | ------------------------------------------------------------ |
303
+ | label | string \| ReactElement | | true | The label of the checkbox. |
304
+ | onChange | func | | true | Callback fired when the `checkbox` value is changed.<br />**Signature:**<br/>`function(value: boolean) => void`<br/>*value:* The value of the `checkbox` element. |
305
305
 
306
306
 
307
307
 
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { SidebarItemProps } from "./types";
2
3
  declare function SidebarItem(props: SidebarItemProps): JSX.Element;
3
4
  export default SidebarItem;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { SidebarLinkProps } from "./types";
2
3
  declare function SidebarLink(props: SidebarLinkProps): JSX.Element;
3
4
  export default SidebarLink;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import SidebarItem from "./SidebarItem";
2
3
  import SidebarItemsGroup from "./SidebarItemsGroup";
3
4
  import { SidebarProps } from "./types";
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { SocialInputProps } from "./types";
2
3
  export declare function SocialInputFormat(str: string): string;
3
4
  export declare function onValidateSocial(socialString: string): boolean;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { TablePaginationActionsProps } from "./types";
2
3
  declare function TablePaginationActions(props: TablePaginationActionsProps): JSX.Element;
3
4
  export default TablePaginationActions;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { TablePaginationProps } from "./types";
2
3
  declare function Pagination(props: TablePaginationProps): JSX.Element;
3
4
  export default Pagination;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { VideoPlayerModalProps } from "./types";
2
3
  declare function VideoPlayerModal(props: VideoPlayerModalProps): JSX.Element;
3
4
  export default VideoPlayerModal;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@symply.io/basic-components",
3
- "version": "1.0.0-beta.12",
3
+ "version": "1.0.0-beta.13",
4
4
  "description": "Basic and reusable components for all frontend of Symply apps",
5
5
  "keywords": [
6
6
  "react",
@@ -45,19 +45,21 @@
45
45
  "devDependencies": {
46
46
  "@types/body-parser": "^1.19.2",
47
47
  "@types/reach__router": "^1.3.10",
48
- "@types/react": "^17.0.27",
49
- "@types/react-dom": "^17.0.9",
48
+ "@types/react": "17.0.27",
49
+ "@types/react-dom": "17.0.9",
50
50
  "babel-loader": "^8.2.2",
51
51
  "typescript": "~4.6.3"
52
52
  },
53
53
  "dependencies": {
54
54
  "@emotion/react": "^11.7.1",
55
55
  "@emotion/styled": "^11.6.0",
56
- "@mui/icons-material": "^5.4.2",
57
- "@mui/material": "^5.4.2",
58
- "@mui/system": "^5.4.2",
56
+ "@mui/icons-material": "~5.4.2",
57
+ "@mui/material": "~5.4.2",
58
+ "@mui/system": "~5.4.2",
59
59
  "@reach/router": "^1.3.4",
60
60
  "color-alpha": "^1.1.3",
61
+ "react": "17.0.2",
62
+ "react-dom": "17.0.2",
61
63
  "react-player": "^2.9.0",
62
64
  "rifm": "^0.12.1"
63
65
  },