@webiny/ui 5.23.1-beta.0 → 5.24.0

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 (74) hide show
  1. package/Accordion/Accordion.d.ts +3 -3
  2. package/Accordion/AccordionItem.js +4 -0
  3. package/AutoComplete/AutoComplete.d.ts +8 -19
  4. package/AutoComplete/AutoComplete.js +3 -4
  5. package/AutoComplete/MultiAutoComplete.d.ts +18 -34
  6. package/AutoComplete/MultiAutoComplete.js +4 -8
  7. package/AutoComplete/utils.d.ts +11 -5
  8. package/AutoComplete/utils.js +1 -1
  9. package/Button/Button.d.ts +7 -7
  10. package/Checkbox/Checkbox.d.ts +4 -8
  11. package/Checkbox/Checkbox.js +2 -1
  12. package/CodeEditor/CodeEditor.d.ts +1 -5
  13. package/CodeEditor/CodeEditor.js +2 -1
  14. package/ColorPicker/ColorPicker.d.ts +3 -6
  15. package/ColorPicker/ColorPicker.js +2 -1
  16. package/ConfirmationDialog/ConfirmationDialog.d.ts +1 -1
  17. package/ConfirmationDialog/withConfirmation.d.ts +1 -1
  18. package/Dialog/Dialog.d.ts +1 -2
  19. package/DynamicFieldset/Fieldset.d.ts +22 -12
  20. package/DynamicFieldset/Fieldset.js +3 -0
  21. package/Helpers/ClassNames.d.ts +1 -1
  22. package/Icon/Icon.d.ts +2 -5
  23. package/Icon/Icon.js +0 -3
  24. package/ImageEditor/ImageEditor.d.ts +21 -23
  25. package/ImageEditor/ImageEditor.js +23 -8
  26. package/ImageEditor/toolbar/crop.js +3 -1
  27. package/ImageEditor/toolbar/filter.js +3 -1
  28. package/ImageEditor/toolbar/flip.js +3 -1
  29. package/ImageEditor/toolbar/rotate.js +3 -1
  30. package/ImageEditor/toolbar/types.d.ts +21 -11
  31. package/ImageUpload/ImageEditorDialog.d.ts +7 -3
  32. package/ImageUpload/MultiImageUpload.d.ts +7 -28
  33. package/ImageUpload/MultiImageUpload.js +15 -2
  34. package/ImageUpload/SingleImageUpload.d.ts +4 -26
  35. package/ImageUpload/SingleImageUpload.js +4 -2
  36. package/ImageUpload/styled.d.ts +10 -10
  37. package/Input/Input.d.ts +1 -7
  38. package/List/DataList/DataList.d.ts +11 -35
  39. package/List/DataList/DataList.js +5 -1
  40. package/List/DataList/DataListModalOverlay/DataListModalOverlay.d.ts +2 -2
  41. package/List/DataList/Loader.js +5 -0
  42. package/Menu/Menu.d.ts +1 -4
  43. package/Menu/Menu.stories.js +1 -1
  44. package/Mosaic/Mosaic.d.ts +4 -14
  45. package/Mosaic/Mosaic.js +11 -3
  46. package/Progress/CircularProgress.d.ts +7 -15
  47. package/Radio/Radio.d.ts +1 -5
  48. package/Radio/Radio.js +2 -1
  49. package/Radio/RadioGroup.d.ts +1 -5
  50. package/Radio/RadioGroup.js +2 -1
  51. package/RichTextEditor/RichTextEditor.d.ts +6 -6
  52. package/RichTextEditor/createPropsFromConfig.d.ts +11 -1
  53. package/RichTextEditor/createPropsFromConfig.js +7 -3
  54. package/Ripple/Ripple.d.ts +3 -4
  55. package/Ripple/Ripple.stories.js +1 -1
  56. package/Scrollbar/Scrollbar.d.ts +4 -4
  57. package/Section/index.d.ts +3 -4
  58. package/Select/Select.d.ts +5 -8
  59. package/Select/Select.js +11 -3
  60. package/Slider/Slider.d.ts +1 -5
  61. package/Slider/Slider.js +2 -1
  62. package/Snackbar/Snackbar.d.ts +1 -1
  63. package/Switch/Switch.d.ts +1 -5
  64. package/Switch/Switch.js +2 -1
  65. package/Tabs/Tab.d.ts +4 -0
  66. package/Tabs/Tabs.d.ts +18 -12
  67. package/Tabs/Tabs.js +2 -2
  68. package/Tags/Tags.d.ts +2 -8
  69. package/Tags/Tags.js +7 -3
  70. package/Tooltip/Tooltip.d.ts +5 -7
  71. package/Tooltip/Tooltip.js +6 -1
  72. package/TopProgressBar/TopProgressBar.d.ts +5 -5
  73. package/Typography/Typography.d.ts +3 -3
  74. package/package.json +12 -7
@@ -1,10 +1,10 @@
1
1
  import * as React from "react";
2
2
  import { ListItem, ListProps } from "..";
3
3
  import { PaginationProp, SortersProp } from "./types";
4
- declare type Props = {
4
+ interface DataListProps {
5
5
  children?: Function;
6
6
  title?: React.ReactNode;
7
- data?: Object[];
7
+ data?: Record<string, any>[];
8
8
  refresh?: Function;
9
9
  loading?: boolean;
10
10
  loader?: React.ReactNode;
@@ -24,38 +24,14 @@ declare type Props = {
24
24
  search?: React.ReactElement;
25
25
  modalOverlay?: React.ReactElement;
26
26
  modalOverlayAction?: React.ReactElement;
27
- };
28
- export declare const DataList: {
29
- (props: Props): JSX.Element;
30
- defaultProps: {
31
- children: any;
32
- title: any;
33
- data: any;
34
- meta: any;
35
- loading: boolean;
36
- refresh: any;
37
- setPage: any;
38
- setPerPage: any;
39
- perPageOptions: number[];
40
- filters: any;
41
- sorters: any;
42
- setSorters: any;
43
- actions: any;
44
- multiSelectAll: any;
45
- isAllMultiSelected: () => boolean;
46
- isNoneMultiSelected: () => boolean;
47
- loader: JSX.Element;
48
- noData: JSX.Element;
49
- showOptions: {
50
- refresh: boolean;
51
- pagination: boolean;
52
- sorters: boolean;
53
- filters: boolean;
54
- };
55
- };
56
- };
57
- export declare type ScrollListProps = ListProps & {
27
+ meta?: Record<string, any>;
28
+ setPage?: (page: string) => void;
29
+ setPerPage?: (page: string) => void;
30
+ perPageOptions?: number[];
31
+ }
32
+ export declare const DataList: React.FC<DataListProps>;
33
+ export interface ScrollListProps extends ListProps {
58
34
  children: React.ReactElement<typeof ListItem>[];
59
- };
60
- export declare const ScrollList: (props: ScrollListProps) => JSX.Element;
35
+ }
36
+ export declare const ScrollList: React.FC<ScrollListProps>;
61
37
  export {};
@@ -248,7 +248,11 @@ export var DataList = function DataList(props) {
248
248
  } else if (isEmpty(props.data)) {
249
249
  render = props.noData;
250
250
  } else {
251
- render = typeof props.children === "function" ? props.children(props) : null;
251
+ /**
252
+ * TODO: figure out the correct type.
253
+ */
254
+ var ch = props.children;
255
+ render = typeof ch === "function" ? ch(props) : null;
252
256
  }
253
257
 
254
258
  return /*#__PURE__*/React.createElement(DataListModalOverlayProvider, null, /*#__PURE__*/React.createElement(ListContainer, {
@@ -2,13 +2,13 @@ import React from "react";
2
2
  export declare type SimpleOverlayProps = {
3
3
  showOverlay: boolean;
4
4
  };
5
- export declare const SimpleOverlay: import("@emotion/styled-base").StyledComponent<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, Pick<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & SimpleOverlayProps, "onError" | "className" | "style" | "title" | "children" | "onBlur" | "onClick" | "onContextMenu" | "onCopy" | "onCut" | "onAuxClick" | "onDoubleClick" | "onDragEnd" | "onDragStart" | "onDrop" | "onFocus" | "onInput" | "onInvalid" | "onKeyDown" | "onKeyPress" | "onKeyUp" | "onMouseDown" | "onMouseUp" | "onPaste" | "onPause" | "onPlay" | "onPointerCancel" | "onPointerDown" | "onPointerUp" | "onRateChange" | "onReset" | "onSeeked" | "onSubmit" | "onTouchCancel" | "onTouchEnd" | "onTouchStart" | "onVolumeChange" | "onAbort" | "onAnimationEnd" | "onAnimationIteration" | "onAnimationStart" | "onCanPlay" | "onCanPlayThrough" | "onDrag" | "onDragEnter" | "onDragExit" | "onDragLeave" | "onDragOver" | "onDurationChange" | "onEmptied" | "onEncrypted" | "onEnded" | "onGotPointerCapture" | "onLoad" | "onLoadedData" | "onLoadedMetadata" | "onLoadStart" | "onLostPointerCapture" | "onMouseMove" | "onMouseOut" | "onMouseOver" | "onPlaying" | "onPointerMove" | "onPointerOut" | "onPointerOver" | "onProgress" | "onScroll" | "onSeeking" | "onStalled" | "onSuspend" | "onTimeUpdate" | "onTouchMove" | "onTransitionEnd" | "onWaiting" | "onWheel" | "onMouseEnter" | "onMouseLeave" | "onPointerEnter" | "onPointerLeave" | "onChange" | "onSelect" | "onBeforeInput" | "onCompositionEnd" | "onCompositionStart" | "onCompositionUpdate" | "placeholder" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "slot" | "spellCheck" | "tabIndex" | "inputMode" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopyCapture" | "onCutCapture" | "onPasteCapture" | "onCompositionEndCapture" | "onCompositionStartCapture" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChangeCapture" | "onBeforeInputCapture" | "onInputCapture" | "onResetCapture" | "onSubmitCapture" | "onInvalidCapture" | "onLoadCapture" | "onErrorCapture" | "onKeyDownCapture" | "onKeyPressCapture" | "onKeyUpCapture" | "onAbortCapture" | "onCanPlayCapture" | "onCanPlayThroughCapture" | "onDurationChangeCapture" | "onEmptiedCapture" | "onEncryptedCapture" | "onEndedCapture" | "onLoadedDataCapture" | "onLoadedMetadataCapture" | "onLoadStartCapture" | "onPauseCapture" | "onPlayCapture" | "onPlayingCapture" | "onProgressCapture" | "onRateChangeCapture" | "onSeekedCapture" | "onSeekingCapture" | "onStalledCapture" | "onSuspendCapture" | "onTimeUpdateCapture" | "onVolumeChangeCapture" | "onWaitingCapture" | "onAuxClickCapture" | "onClickCapture" | "onContextMenuCapture" | "onDoubleClickCapture" | "onDragCapture" | "onDragEndCapture" | "onDragEnterCapture" | "onDragExitCapture" | "onDragLeaveCapture" | "onDragOverCapture" | "onDragStartCapture" | "onDropCapture" | "onMouseDownCapture" | "onMouseMoveCapture" | "onMouseOutCapture" | "onMouseOverCapture" | "onMouseUpCapture" | "onSelectCapture" | "onTouchCancelCapture" | "onTouchEndCapture" | "onTouchMoveCapture" | "onTouchStartCapture" | "onPointerDownCapture" | "onPointerMoveCapture" | "onPointerUpCapture" | "onPointerCancelCapture" | "onPointerEnterCapture" | "onPointerLeaveCapture" | "onPointerOverCapture" | "onPointerOutCapture" | "onGotPointerCaptureCapture" | "onLostPointerCaptureCapture" | "onScrollCapture" | "onWheelCapture" | "onAnimationStartCapture" | "onAnimationEndCapture" | "onAnimationIterationCapture" | "onTransitionEndCapture" | "translate" | "css" | "showOverlay"> & {
5
+ export declare const SimpleOverlay: import("@emotion/styled-base").StyledComponent<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, Pick<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & SimpleOverlayProps, "hidden" | "dir" | "slot" | "style" | "title" | "color" | "translate" | "children" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "draggable" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "css" | "showOverlay"> & {
6
6
  theme: object;
7
7
  }, object>;
8
8
  export declare type DataListModalWrapperProps = {
9
9
  showOverlay: boolean;
10
10
  };
11
- export declare const DataListModalWrapper: import("@emotion/styled-base").StyledComponent<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, Pick<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & DataListModalWrapperProps, "onError" | "className" | "style" | "title" | "children" | "onBlur" | "onClick" | "onContextMenu" | "onCopy" | "onCut" | "onAuxClick" | "onDoubleClick" | "onDragEnd" | "onDragStart" | "onDrop" | "onFocus" | "onInput" | "onInvalid" | "onKeyDown" | "onKeyPress" | "onKeyUp" | "onMouseDown" | "onMouseUp" | "onPaste" | "onPause" | "onPlay" | "onPointerCancel" | "onPointerDown" | "onPointerUp" | "onRateChange" | "onReset" | "onSeeked" | "onSubmit" | "onTouchCancel" | "onTouchEnd" | "onTouchStart" | "onVolumeChange" | "onAbort" | "onAnimationEnd" | "onAnimationIteration" | "onAnimationStart" | "onCanPlay" | "onCanPlayThrough" | "onDrag" | "onDragEnter" | "onDragExit" | "onDragLeave" | "onDragOver" | "onDurationChange" | "onEmptied" | "onEncrypted" | "onEnded" | "onGotPointerCapture" | "onLoad" | "onLoadedData" | "onLoadedMetadata" | "onLoadStart" | "onLostPointerCapture" | "onMouseMove" | "onMouseOut" | "onMouseOver" | "onPlaying" | "onPointerMove" | "onPointerOut" | "onPointerOver" | "onProgress" | "onScroll" | "onSeeking" | "onStalled" | "onSuspend" | "onTimeUpdate" | "onTouchMove" | "onTransitionEnd" | "onWaiting" | "onWheel" | "onMouseEnter" | "onMouseLeave" | "onPointerEnter" | "onPointerLeave" | "onChange" | "onSelect" | "onBeforeInput" | "onCompositionEnd" | "onCompositionStart" | "onCompositionUpdate" | "placeholder" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "slot" | "spellCheck" | "tabIndex" | "inputMode" | "is" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopyCapture" | "onCutCapture" | "onPasteCapture" | "onCompositionEndCapture" | "onCompositionStartCapture" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChangeCapture" | "onBeforeInputCapture" | "onInputCapture" | "onResetCapture" | "onSubmitCapture" | "onInvalidCapture" | "onLoadCapture" | "onErrorCapture" | "onKeyDownCapture" | "onKeyPressCapture" | "onKeyUpCapture" | "onAbortCapture" | "onCanPlayCapture" | "onCanPlayThroughCapture" | "onDurationChangeCapture" | "onEmptiedCapture" | "onEncryptedCapture" | "onEndedCapture" | "onLoadedDataCapture" | "onLoadedMetadataCapture" | "onLoadStartCapture" | "onPauseCapture" | "onPlayCapture" | "onPlayingCapture" | "onProgressCapture" | "onRateChangeCapture" | "onSeekedCapture" | "onSeekingCapture" | "onStalledCapture" | "onSuspendCapture" | "onTimeUpdateCapture" | "onVolumeChangeCapture" | "onWaitingCapture" | "onAuxClickCapture" | "onClickCapture" | "onContextMenuCapture" | "onDoubleClickCapture" | "onDragCapture" | "onDragEndCapture" | "onDragEnterCapture" | "onDragExitCapture" | "onDragLeaveCapture" | "onDragOverCapture" | "onDragStartCapture" | "onDropCapture" | "onMouseDownCapture" | "onMouseMoveCapture" | "onMouseOutCapture" | "onMouseOverCapture" | "onMouseUpCapture" | "onSelectCapture" | "onTouchCancelCapture" | "onTouchEndCapture" | "onTouchMoveCapture" | "onTouchStartCapture" | "onPointerDownCapture" | "onPointerMoveCapture" | "onPointerUpCapture" | "onPointerCancelCapture" | "onPointerEnterCapture" | "onPointerLeaveCapture" | "onPointerOverCapture" | "onPointerOutCapture" | "onGotPointerCaptureCapture" | "onLostPointerCaptureCapture" | "onScrollCapture" | "onWheelCapture" | "onAnimationStartCapture" | "onAnimationEndCapture" | "onAnimationIterationCapture" | "onTransitionEndCapture" | "translate" | "css" | "showOverlay"> & {
11
+ export declare const DataListModalWrapper: import("@emotion/styled-base").StyledComponent<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, Pick<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & DataListModalWrapperProps, "hidden" | "dir" | "slot" | "style" | "title" | "color" | "translate" | "children" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "draggable" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "css" | "showOverlay"> & {
12
12
  theme: object;
13
13
  }, object>;
14
14
  export declare type DataListModalOverlayProps = {
@@ -1,5 +1,10 @@
1
1
  import * as React from "react";
2
2
  import styled from "@emotion/styled";
3
+ /**
4
+ * Package react-loading-skeleton does not have types.
5
+ */
6
+ // @ts-ignore
7
+
3
8
  import Skeleton from "react-loading-skeleton";
4
9
  var LoaderUl = /*#__PURE__*/styled("ul", {
5
10
  target: "e1nb7uzc0",
package/Menu/Menu.d.ts CHANGED
@@ -16,10 +16,7 @@ declare type State = {
16
16
  * Use Menu component to display a list of choices, once the handler is triggered.
17
17
  */
18
18
  declare class Menu extends React.Component<MenuProps, State> {
19
- static defaultProps: {
20
- handle: any;
21
- anchor: string;
22
- };
19
+ static defaultProps: Partial<MenuProps>;
23
20
  state: {
24
21
  menuIsOpen: boolean;
25
22
  };
@@ -1,7 +1,7 @@
1
1
  import React from "react";
2
2
  import { storiesOf } from "@storybook/react";
3
3
  import { Story, StoryReadme, StorySandbox, StorySandboxExample, StorySandboxCode } from "@webiny/storybook-utils/Story";
4
- import { ButtonPrimary } from "./../Button";
4
+ import { ButtonPrimary } from "../Button";
5
5
  import readme from "./../Menu/README.md";
6
6
  import { Menu, MenuItem, MenuDivider } from "./Menu";
7
7
  var story = storiesOf("Components/Menu", module);
@@ -1,19 +1,9 @@
1
1
  import React from "react";
2
- export declare type MosaicProps = {
3
- children: React.ReactNode;
4
- columns: {
2
+ export interface MosaicProps {
3
+ columns?: {
5
4
  [key: string]: number;
6
5
  };
7
6
  className?: string;
8
- };
9
- export declare function Mosaic({ children, columns, className }: MosaicProps): JSX.Element;
10
- export declare namespace Mosaic {
11
- var defaultProps: {
12
- columns: {
13
- 320: number;
14
- 480: number;
15
- 800: number;
16
- 1366: number;
17
- };
18
- };
19
7
  }
8
+ declare const Mosaic: React.FC<MosaicProps>;
9
+ export { Mosaic };
package/Mosaic/Mosaic.js CHANGED
@@ -1,6 +1,12 @@
1
1
  import React from "react";
2
+ /**
3
+ * Package react-columned does not have types.
4
+ */
5
+ // @ts-ignore
6
+
2
7
  import Columned from "react-columned";
3
- export function Mosaic(_ref) {
8
+
9
+ var Mosaic = function Mosaic(_ref) {
4
10
  var children = _ref.children,
5
11
  columns = _ref.columns,
6
12
  className = _ref.className;
@@ -8,7 +14,8 @@ export function Mosaic(_ref) {
8
14
  columns: columns,
9
15
  className: className
10
16
  }, children);
11
- }
17
+ };
18
+
12
19
  Mosaic.defaultProps = {
13
20
  columns: {
14
21
  320: 1,
@@ -16,4 +23,5 @@ Mosaic.defaultProps = {
16
23
  800: 3,
17
24
  1366: 4
18
25
  }
19
- };
26
+ };
27
+ export { Mosaic };
@@ -1,19 +1,11 @@
1
1
  import * as React from "react";
2
- declare type Props = {
2
+ interface Props {
3
3
  label?: React.ReactNode;
4
- size: number;
5
- spinnerColor: string;
6
- spinnerWidth: number;
7
- visible: boolean;
4
+ size?: number;
5
+ spinnerColor?: string;
6
+ spinnerWidth?: number;
7
+ visible?: boolean;
8
8
  style?: React.CSSProperties;
9
- };
10
- declare const CircularProgress: {
11
- ({ label, size, spinnerWidth, spinnerColor, visible, style }: Props): JSX.Element;
12
- defaultProps: {
13
- size: number;
14
- spinnerColor: string;
15
- spinnerWidth: number;
16
- visible: boolean;
17
- };
18
- };
9
+ }
10
+ declare const CircularProgress: React.FC<Props>;
19
11
  export default CircularProgress;
package/Radio/Radio.d.ts CHANGED
@@ -10,11 +10,7 @@ declare type Props = FormComponentProps & {
10
10
  * Each Radio component must receive value and onChange callback via props.
11
11
  */
12
12
  declare class Radio extends React.Component<Props> {
13
- static defaultProps: {
14
- validation: {
15
- isValid: any;
16
- };
17
- };
13
+ static defaultProps: Partial<Props>;
18
14
  onChange: (e: React.SyntheticEvent<HTMLInputElement>) => void;
19
15
  render(): JSX.Element;
20
16
  }
package/Radio/Radio.js CHANGED
@@ -61,7 +61,8 @@ var Radio = /*#__PURE__*/function (_React$Component) {
61
61
 
62
62
  _defineProperty(Radio, "defaultProps", {
63
63
  validation: {
64
- isValid: null
64
+ isValid: null,
65
+ message: null
65
66
  }
66
67
  });
67
68
 
@@ -10,11 +10,7 @@ declare type Props = FormComponentProps & {
10
10
  children: (props: RadioGroupRenderParams) => React.ReactNode;
11
11
  };
12
12
  declare class RadioGroup extends React.Component<Props> {
13
- static defaultProps: {
14
- validation: {
15
- isValid: any;
16
- };
17
- };
13
+ static defaultProps: Partial<Props>;
18
14
  render(): JSX.Element;
19
15
  }
20
16
  export default RadioGroup;
@@ -49,7 +49,8 @@ var RadioGroup = /*#__PURE__*/function (_React$Component) {
49
49
 
50
50
  _defineProperty(RadioGroup, "defaultProps", {
51
51
  validation: {
52
- isValid: null
52
+ isValid: null,
53
+ message: null
53
54
  }
54
55
  });
55
56
 
@@ -1,10 +1,10 @@
1
- /// <reference types="react" />
1
+ import React from "react";
2
2
  import { OutputBlockData, OutputData, SanitizerConfig, ToolSettings } from "@editorjs/editorjs/types";
3
- export declare type OnReadyParams = {
3
+ export interface OnReadyParams {
4
4
  editor: any;
5
5
  initialData: OutputData;
6
- };
7
- export declare type RichTextEditorProps = {
6
+ }
7
+ export interface RichTextEditorProps {
8
8
  autofocus?: boolean;
9
9
  context?: {
10
10
  [key: string]: any;
@@ -23,5 +23,5 @@ export declare type RichTextEditorProps = {
23
23
  label?: string;
24
24
  description?: string;
25
25
  disabled?: boolean;
26
- };
27
- export declare const RichTextEditor: (props: RichTextEditorProps) => JSX.Element;
26
+ }
27
+ export declare const RichTextEditor: React.FC<RichTextEditorProps>;
@@ -1,5 +1,15 @@
1
1
  import { RichTextEditorProps } from "./RichTextEditor";
2
+ import { ToolSettings } from "@editorjs/editorjs";
3
+ interface CreatePropsFromConfigResult {
4
+ onReady: (editor: any) => void;
5
+ tools: {
6
+ [key: string]: ToolSettings;
7
+ };
8
+ }
2
9
  /**
3
10
  * Creates RichTextEditor props from the given config (or array of configs).
11
+ *
12
+ * TODO: figure out types for editor and return type of the function.
4
13
  */
5
- export declare const createPropsFromConfig: (config: any) => Partial<RichTextEditorProps>;
14
+ export declare const createPropsFromConfig: (config: RichTextEditorProps[]) => CreatePropsFromConfigResult;
15
+ export {};
@@ -1,18 +1,22 @@
1
+ import _objectSpread from "@babel/runtime/helpers/objectSpread2";
2
+
1
3
  /**
2
4
  * Creates RichTextEditor props from the given config (or array of configs).
5
+ *
6
+ * TODO: figure out types for editor and return type of the function.
3
7
  */
4
8
  export var createPropsFromConfig = function createPropsFromConfig(config) {
5
9
  var configs = Array.isArray(config) ? config : [config];
6
10
  return {
7
- onReady: function onReady(editor) {
11
+ onReady: function onReady(params) {
8
12
  configs.forEach(function (config) {
9
13
  if (typeof config.onReady === "function") {
10
- config.onReady(editor);
14
+ config.onReady(params);
11
15
  }
12
16
  });
13
17
  },
14
18
  tools: configs.reduce(function (tools, config) {
15
- return Object.assign(tools, config.tools);
19
+ return _objectSpread(_objectSpread({}, tools), config.tools);
16
20
  }, {})
17
21
  };
18
22
  };
@@ -1,11 +1,10 @@
1
1
  import * as React from "react";
2
- declare type Props = {
3
- children?: React.ReactNode;
2
+ interface Props {
4
3
  type?: "unbounded" | "primary" | "accent";
5
4
  disabled?: boolean;
6
- };
5
+ }
7
6
  /**
8
7
  * Use Ripple component to display a list of choices, once the handler is triggered.
9
8
  */
10
- declare const Ripple: (props: Props) => JSX.Element;
9
+ declare const Ripple: React.FC<Props>;
11
10
  export { Ripple };
@@ -2,7 +2,7 @@ import * as React from "react";
2
2
  import { storiesOf } from "@storybook/react";
3
3
  import { Story, StoryReadme, StorySandboxCode, StorySandbox, StorySandboxExample } from "@webiny/storybook-utils/Story";
4
4
  import readme from "./../Ripple/README.md";
5
- import { Icon } from "./../Icon";
5
+ import { Icon } from "../Icon";
6
6
  import { withKnobs, boolean } from "@storybook/addon-knobs";
7
7
  import { ReactComponent as AutoRenewIcon } from "./svg/baseline-autorenew-24px.svg";
8
8
  import { ReactComponent as CloudDoneIcon } from "./svg/baseline-cloud_done-24px.svg";
@@ -1,11 +1,11 @@
1
1
  import * as React from "react";
2
- declare type Props = {
3
- children?: React.ReactNode;
2
+ import { ScrollbarProps } from "react-custom-scrollbars";
3
+ interface Props extends ScrollbarProps {
4
4
  style?: React.CSSProperties;
5
5
  [key: string]: any;
6
- };
6
+ }
7
7
  /**
8
8
  * Use Scrollbar component to show vertical or horizontal scrollbars.
9
9
  */
10
- declare const Scrollbar: (props: Props) => JSX.Element;
10
+ declare const Scrollbar: React.FC<Props>;
11
11
  export { Scrollbar };
@@ -1,7 +1,6 @@
1
1
  import * as React from "react";
2
- declare type SectionProps = {
3
- children?: React.ReactNode;
2
+ interface SectionProps {
4
3
  title?: String;
5
- };
6
- declare const Section: ({ children, title, ...props }: SectionProps) => JSX.Element;
4
+ }
5
+ declare const Section: React.FC<SectionProps>;
7
6
  export default Section;
@@ -11,12 +11,9 @@ export declare type SelectProps = FormComponentProps & RmwcSelectProps & {
11
11
  rootProps?: Object;
12
12
  className?: string;
13
13
  };
14
- export declare const Select: {
15
- (props: SelectProps): JSX.Element;
16
- defaultProps: {
17
- validation: {
18
- isValid: any;
19
- };
20
- };
21
- };
14
+ /**
15
+ * We check for null and undefined in the value because React is complaining about those values.
16
+ * Error says to use the empty string in null/undefined case.
17
+ */
18
+ export declare const Select: React.FC<SelectProps>;
22
19
  export default Select;
package/Select/Select.js CHANGED
@@ -30,18 +30,25 @@ var getRmwcProps = function getRmwcProps(props) {
30
30
  var newProps = {};
31
31
  Object.keys(props).filter(function (name) {
32
32
  return !skipProps.includes(name);
33
- }).forEach(function (name) {
33
+ }) // @ts-ignore
34
+ .forEach(function (name) {
34
35
  return newProps[name] = props[name];
35
36
  });
36
37
  return newProps;
37
38
  };
39
+ /**
40
+ * We check for null and undefined in the value because React is complaining about those values.
41
+ * Error says to use the empty string in null/undefined case.
42
+ */
43
+
38
44
 
39
45
  export var Select = function Select(props) {
40
- var value = props.value,
46
+ var initialValue = props.value,
41
47
  description = props.description,
42
48
  validation = props.validation,
43
49
  other = _objectWithoutProperties(props, _excluded);
44
50
 
51
+ var value = initialValue === null || initialValue === undefined ? "" : initialValue;
45
52
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(RmwcSelect, Object.assign({}, getRmwcProps(other), {
46
53
  value: value,
47
54
  className: classNames("webiny-ui-select", props.className, _defineProperty({}, noLabel, !props.label)),
@@ -54,7 +61,8 @@ export var Select = function Select(props) {
54
61
  };
55
62
  Select.defaultProps = {
56
63
  validation: {
57
- isValid: null
64
+ isValid: null,
65
+ message: null
58
66
  }
59
67
  };
60
68
  export default Select;
@@ -15,11 +15,7 @@ declare type Props = FormComponentProps & {
15
15
  * Slider component lets users choose a value from given range.
16
16
  */
17
17
  declare class Slider extends React.Component<Props> {
18
- static defaultProps: {
19
- validation: {
20
- isValid: any;
21
- };
22
- };
18
+ static defaultProps: Partial<Props>;
23
19
  onChange: (e: {
24
20
  detail: {
25
21
  value: number;
package/Slider/Slider.js CHANGED
@@ -80,7 +80,8 @@ var Slider = /*#__PURE__*/function (_React$Component) {
80
80
 
81
81
  _defineProperty(Slider, "defaultProps", {
82
82
  validation: {
83
- isValid: null
83
+ isValid: null,
84
+ message: null
84
85
  }
85
86
  });
86
87
 
@@ -9,7 +9,7 @@ declare type Props = SnackbarProps;
9
9
  */
10
10
  declare class Snackbar extends React.Component<Props> {
11
11
  container?: Element;
12
- constructor(props: any);
12
+ constructor(props: Props);
13
13
  render(): JSX.Element;
14
14
  }
15
15
  export { Snackbar, SnackbarAction };
@@ -9,11 +9,7 @@ declare type Props = FormComponentProps & SwitchProps & {
9
9
  * Switch component can be used to store simple boolean values.
10
10
  */
11
11
  declare class Switch extends React.Component<Props> {
12
- static defaultProps: {
13
- validation: {
14
- isValid: any;
15
- };
16
- };
12
+ static defaultProps: Partial<Props>;
17
13
  static rmwcProps: string[];
18
14
  onChange: (e: React.SyntheticEvent<HTMLElement>) => void;
19
15
  render(): JSX.Element;
package/Switch/Switch.js CHANGED
@@ -58,7 +58,8 @@ var Switch = /*#__PURE__*/function (_React$Component) {
58
58
 
59
59
  _defineProperty(Switch, "defaultProps", {
60
60
  validation: {
61
- isValid: null
61
+ isValid: null,
62
+ message: null
62
63
  }
63
64
  });
64
65
 
package/Tabs/Tab.d.ts CHANGED
@@ -10,5 +10,9 @@ export declare type TabProps = RmwcTabProps & {
10
10
  * Style object
11
11
  */
12
12
  style?: React.CSSProperties;
13
+ /**
14
+ * Tab ID for the testing.
15
+ */
16
+ "data-testid"?: string;
13
17
  };
14
18
  export declare const Tab: (props: TabProps) => JSX.Element;