react-ui-basics 0.0.160 → 0.0.163

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 (50) hide show
  1. package/Animated.js +8 -9
  2. package/AutocompleteSelect.js +63 -64
  3. package/Button.js +11 -12
  4. package/Checkbox.js +9 -10
  5. package/CircleProgress.js +4 -5
  6. package/CommonFields.js +3 -1
  7. package/DNDContainer.js +22 -23
  8. package/DNDDraggable.js +9 -10
  9. package/DNDDroppable.js +8 -9
  10. package/Dialog.js +17 -18
  11. package/DropFileInput.js +4 -5
  12. package/DroppableHorizontalList.js +11 -12
  13. package/DroppableList.js +11 -12
  14. package/Dropzone.js +13 -14
  15. package/FilteredList.js +33 -34
  16. package/FloatingActionButton.js +6 -7
  17. package/FormUploadProgress.js +8 -9
  18. package/ImageGallery.js +35 -36
  19. package/MaterialIcon.js +5 -6
  20. package/Modal.js +14 -15
  21. package/ModalMenu.js +10 -11
  22. package/ReactConstants.d.ts +5 -4
  23. package/ReactConstants.js +7 -9
  24. package/ReactCreateElement.js +2 -1
  25. package/ReadyListener.js +10 -11
  26. package/Scrollable.js +17 -18
  27. package/ScrollableTable.js +4 -5
  28. package/Size.js +3 -4
  29. package/Snackbar.js +7 -8
  30. package/SpinningProgress.js +5 -6
  31. package/Switch.js +19 -20
  32. package/Table.d.ts +8 -1
  33. package/Table.js +48 -56
  34. package/TextField.js +19 -20
  35. package/Tools.d.ts +1 -1
  36. package/Tools.js +6 -2
  37. package/_virtual/_commonjsHelpers.js +2 -1
  38. package/_virtual/_react.js +2 -1
  39. package/_virtual/react-jsx-runtime.development.js +2 -1
  40. package/bundle.css +609 -609
  41. package/index.js +3 -3
  42. package/package.json +1 -1
  43. package/router/HistoryTools.js +2 -1
  44. package/router/Link.js +6 -7
  45. package/router/NavLink.js +5 -6
  46. package/router/Route.js +7 -8
  47. package/router/index.js +2 -3
  48. package/store/ProxyTools.js +2 -3
  49. package/store/Store.js +3 -3
  50. package/store/Store.js.map +1 -1
package/Modal.js CHANGED
@@ -1,10 +1,9 @@
1
- import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, scrollLeft as __scrollLeft, scrollTop as __scrollTop, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
1
+ import ReactConstants from "./ReactConstants";
2
+ import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, props as __props, scrollLeft as __scrollLeft, scrollTop as __scrollTop, state as __state, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
2
3
  import { inherits as _inherits, createSuper as _createSuper, classCallCheck as _classCallCheck, assertThisInitialized as _assertThisInitialized, slicedToArray as _slicedToArray, createClass as _createClass } from './_virtual/_rollupPluginBabelHelpers.js';
3
4
  import {toConsumableArray as __toConsumableArray} from "./_virtual/_rollupPluginBabelHelpers";
4
5
  import {extends as __extends} from "./_virtual/_rollupPluginBabelHelpers";
5
6
  import {inherits as __inherits} from "./_virtual/_rollupPluginBabelHelpers";
6
- import {className as __className} from "./ReactConstants";
7
- import {children as __children} from "./ReactConstants";
8
7
  import React from 'react';
9
8
  import ReactDOM from 'react-dom';
10
9
  import ReactCreateElement from './ReactCreateElement.js';
@@ -65,25 +64,25 @@ var Modal = function (_PureComponent) {
65
64
  };
66
65
  addEventListener(overlay(), transitionend, listener);
67
66
  };
68
- that[render] = function () {
67
+ that[ReactConstants[3]] = function () {
69
68
  var _props2 = props(),
70
- className = _props2[__className],
69
+ className = _props2[ReactConstants[5]],
71
70
  top = __top(_props2),
72
71
  _props2$container = _props2.container,
73
72
  container = _props2$container === void 0 ? Modal.defaultContainer : _props2$container,
74
- children = _props2[__children],
73
+ children = _props2[ReactConstants[4]],
75
74
  closeIcon = _props2.closeIcon;
76
75
  var menu = getMenu();
77
76
  var show = isShow();
78
77
  var modal = ReactCreateElement("div", {
79
- [__className]: classNames("Modal", className, show && 'show'),
78
+ [ReactConstants[5]]: classNames("Modal", className, show && 'show'),
80
79
  ref: el,
81
- onClick: shouldClose
80
+ [ReactConstants[6]]: shouldClose
82
81
  }, ReactCreateElement("div", {
83
82
  ref: overlay,
84
- [__className]: classNames("overlay", show && 'show')
83
+ [ReactConstants[5]]: classNames("overlay", show && 'show')
85
84
  }), ReactCreateElement("div", {
86
- [__className]: classNames("content", show && 'show', top && 'top'),
85
+ [ReactConstants[5]]: classNames("content", show && 'show', top && 'top'),
87
86
  style: top && {
88
87
  top: top + 'px'
89
88
  },
@@ -94,10 +93,10 @@ var Modal = function (_PureComponent) {
94
93
  modalBeforeCloseConsumer: getBeforeClose
95
94
  });
96
95
  }), menu, ReactCreateElement(Button, {
97
- [__className]: "close",
96
+ [ReactConstants[5]]: "close",
98
97
  flat: true,
99
98
  round: true,
100
- onClick: beforeClose
99
+ [ReactConstants[6]]: beforeClose
101
100
  }, closeIcon)));
102
101
  return container ? ReactDOM.createPortal(modal, container) : modal;
103
102
  };
@@ -120,7 +119,7 @@ var Modal = function (_PureComponent) {
120
119
  };
121
120
  addListener(that, listener);
122
121
  };
123
- that[componentDidMount] = function () {
122
+ that[ReactConstants[0]] = function () {
124
123
  var _props = props();
125
124
  orNoop(_props.open)(function () {
126
125
  setTimeout(open, 0);
@@ -130,7 +129,7 @@ var Modal = function (_PureComponent) {
130
129
  });
131
130
  _props.show && setTimeout(open, 0);
132
131
  };
133
- that[componentDidUpdate] = function (prevProps) {
132
+ that[ReactConstants[2]] = function (prevProps) {
134
133
  var show = props().show;
135
134
  if (show !== prevProps.show) {
136
135
  show ? open() : close();
@@ -151,7 +150,7 @@ Modal.addListener = addListener;
151
150
  var Modal$1 = Modal;
152
151
  if (process.env.NODE_ENV !== 'production') {
153
152
  Modal.propTypes = {
154
- [__className]: PropTypes.string,
153
+ [ReactConstants[5]]: PropTypes.string,
155
154
  top: PropTypes.number,
156
155
  container: PropTypes.node
157
156
  };
package/ModalMenu.js CHANGED
@@ -1,10 +1,9 @@
1
- import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, scrollLeft as __scrollLeft, scrollTop as __scrollTop, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
1
+ import ReactConstants from "./ReactConstants";
2
+ import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, props as __props, scrollLeft as __scrollLeft, scrollTop as __scrollTop, state as __state, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
2
3
  import { inherits as _inherits, createSuper as _createSuper, classCallCheck as _classCallCheck, assertThisInitialized as _assertThisInitialized, createClass as _createClass } from './_virtual/_rollupPluginBabelHelpers.js';
3
4
  import {toConsumableArray as __toConsumableArray} from "./_virtual/_rollupPluginBabelHelpers";
4
5
  import {extends as __extends} from "./_virtual/_rollupPluginBabelHelpers";
5
6
  import {inherits as __inherits} from "./_virtual/_rollupPluginBabelHelpers";
6
- import {className as __className} from "./ReactConstants";
7
- import {children as __children} from "./ReactConstants";
8
7
  import 'react';
9
8
  import ReactCreateElement from './ReactCreateElement.js';
10
9
  import { stateGS, render, PureComponent } from './ReactConstants.js';
@@ -25,15 +24,15 @@ var ModalMenu = function (_PureComponent) {
25
24
  var toggle = function toggle() {
26
25
  isOpen(!isOpen());
27
26
  };
28
- _this[render] = function () {
29
- var items = _this.props.items;
27
+ _this[ReactConstants[3]] = function () {
28
+ var items = __props(_this).items;
30
29
  var filtered = (items || []).filter(function (it) {
31
30
  return !!it;
32
31
  });
33
- if (filtered.length === 0) return null;
32
+ if (__length(filtered) === 0) return null;
34
33
  var open = isOpen();
35
34
  return ReactCreateElement("div", {
36
- [__className]: classNames("ModalMenu", 'row', open && 'open')
35
+ [ReactConstants[5]]: classNames("ModalMenu", 'row', open && 'open')
37
36
  }, filtered.map(function (it, i) {
38
37
  return ReactCreateElement(Animated, {
39
38
  value: open,
@@ -50,19 +49,19 @@ var ModalMenu = function (_PureComponent) {
50
49
  }, ReactCreateElement(Button, {
51
50
  flat: true,
52
51
  round: true,
53
- onClick: it.action
52
+ [ReactConstants[6]]: it.action
54
53
  }, ReactCreateElement(MaterialIcon, {
55
54
  icon: it.icon
56
55
  })));
57
56
  }), ReactCreateElement(Button, {
58
- [__className]: classNames("more", open && 'active'),
57
+ [ReactConstants[5]]: classNames("more", open && 'active'),
59
58
  flat: true,
60
59
  round: true,
61
- onClick: toggle
60
+ [ReactConstants[6]]: toggle
62
61
  }, ReactCreateElement(MaterialIcon, {
63
62
  icon: "more_vert"
64
63
  })), ReactCreateElement("div", {
65
- [__className]: "separator"
64
+ [ReactConstants[5]]: "separator"
66
65
  }));
67
66
  };
68
67
  return _this;
@@ -4,10 +4,7 @@ export declare const propsGetter: <P>(that: React.Component<P>) => (() => P);
4
4
  export declare const state: <P, S>(that: React.Component<P, S>) => S;
5
5
  export declare const setState: (that: any, data: any, cb?: any) => void;
6
6
  export declare const stateFieldSetter: (that: any, key: any, cb?: any) => (value: any, cb2?: any) => void;
7
- export declare const stateGS: (that: any) => {
8
- (): any;
9
- toString(): string;
10
- };
7
+ export declare const stateGS: ((that: React.Component) => (v?: any, cb?: any) => any);
11
8
  export declare const stateGSs: (that: any, num: any) => any[];
12
9
  export declare const componentDidMount = "componentDidMount";
13
10
  export declare const componentWillUnmount = "componentWillUnmount";
@@ -15,4 +12,8 @@ export declare const componentDidUpdate = "componentDidUpdate";
15
12
  export declare const render = "render";
16
13
  export declare const children = "children";
17
14
  export declare const className = "className";
15
+ export declare const onClick = "onClick";
16
+ export declare const onChange = "onChange";
18
17
  export declare const PureComponent: typeof React.PureComponent;
18
+ declare const _default: string[];
19
+ export default _default;
package/ReactConstants.js CHANGED
@@ -1,12 +1,7 @@
1
1
  import React from 'react';
2
2
 
3
3
  var EMPTY = {};
4
- var props = function (that) {
5
- if (!that) {
6
- debugger;
7
- }
8
- return that.props;
9
- };
4
+ var props = function (that) { return that.props; };
10
5
  var propsGetter = function (that) { return function () { return props(that); }; };
11
6
  // @ts-ignore //ignore incompatible casting EMPTY to S
12
7
  var state = function (that) { return that.state || EMPTY; };
@@ -18,8 +13,8 @@ var stateFieldSetter = function (that, key, cb) { return function (value, cb2) {
18
13
  setState(that, (_a = {}, _a[key] = value, _a), cb2 || cb);
19
14
  }; };
20
15
  var stateGS = function (that) {
21
- !that.sfc && (that.sfc = 0);
22
- var key = '_' + (that.sfc++);
16
+ !that['sfc'] && (that['sfc'] = 0);
17
+ var key = '_' + (that['sfc']++);
23
18
  var setter = stateFieldSetter(that, key);
24
19
  var result = function () {
25
20
  return !arguments.length ? state(that)[key] : setter.apply(null, arguments);
@@ -40,7 +35,10 @@ var componentDidUpdate = 'componentDidUpdate';
40
35
  var render = 'render';
41
36
  var children = 'children';
42
37
  var className = 'className';
38
+ var onClick = 'onClick';
39
+ var onChange = 'onChange';
43
40
  var PureComponent = React.PureComponent;
41
+ var ReactConstants = [componentDidMount, componentWillUnmount, componentDidUpdate, render, children, className, onClick, onChange];
44
42
 
45
- export { PureComponent, children, className, componentDidMount, componentDidUpdate, componentWillUnmount, props, propsGetter, render, setState, state, stateFieldSetter, stateGS, stateGSs };
43
+ export { PureComponent, children, className, componentDidMount, componentDidUpdate, componentWillUnmount, ReactConstants as default, onChange, onClick, props, propsGetter, render, setState, state, stateFieldSetter, stateGS, stateGSs };
46
44
  //# sourceMappingURL=ReactConstants.js.map
@@ -1,4 +1,5 @@
1
- import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, scrollLeft as __scrollLeft, scrollTop as __scrollTop, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
1
+ import ReactConstants from "./ReactConstants";
2
+ import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, props as __props, scrollLeft as __scrollLeft, scrollTop as __scrollTop, state as __state, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
2
3
  import React from 'react';
3
4
 
4
5
  var ReactCreateElement = React.createElement;
package/ReadyListener.js CHANGED
@@ -1,10 +1,9 @@
1
- import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, scrollLeft as __scrollLeft, scrollTop as __scrollTop, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
1
+ import ReactConstants from "./ReactConstants";
2
+ import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, props as __props, scrollLeft as __scrollLeft, scrollTop as __scrollTop, state as __state, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
2
3
  import { inherits as _inherits, createSuper as _createSuper, classCallCheck as _classCallCheck, assertThisInitialized as _assertThisInitialized, createClass as _createClass } from './_virtual/_rollupPluginBabelHelpers.js';
3
4
  import {toConsumableArray as __toConsumableArray} from "./_virtual/_rollupPluginBabelHelpers";
4
5
  import {extends as __extends} from "./_virtual/_rollupPluginBabelHelpers";
5
6
  import {inherits as __inherits} from "./_virtual/_rollupPluginBabelHelpers";
6
- import {className as __className} from "./ReactConstants";
7
- import {children as __children} from "./ReactConstants";
8
7
  import 'react';
9
8
  import { render, props, state, children, componentDidMount, componentDidUpdate, setState, componentWillUnmount, PureComponent } from './ReactConstants.js';
10
9
  import { orNoop } from './Tools.js';
@@ -24,14 +23,14 @@ var createReadyListener = function createReadyListener() {
24
23
  r: true
25
24
  };
26
25
  indicator = that;
27
- that[render] = function () {
26
+ that[ReactConstants[3]] = function () {
28
27
  var _props = props(that),
29
- renderer = _props[render],
28
+ renderer = _props[ReactConstants[3]],
30
29
  ready = state(that).r;
31
- if (renderer) return renderer(ready);else return !ready && _props[children] || null;
30
+ if (renderer) return renderer(ready);else return !ready && _props[ReactConstants[4]] || null;
32
31
  };
33
- that[componentDidMount] = that[componentDidUpdate] = function () {
34
- orNoop(props(that).onChange)(state(that).r);
32
+ that[ReactConstants[0]] = that[ReactConstants[2]] = function () {
33
+ orNoop(props(that)[ReactConstants[7]])(state(that).r);
35
34
  };
36
35
  return _this;
37
36
  }
@@ -45,18 +44,18 @@ var createReadyListener = function createReadyListener() {
45
44
  _classCallCheck(this, NotReady);
46
45
  _this2 = _super2.call(this, props);
47
46
  var that = _assertThisInitialized(_this2);
48
- that[componentDidMount] = function () {
47
+ that[ReactConstants[0]] = function () {
49
48
  count++;
50
49
  setState(indicator, {
51
50
  r: false
52
51
  });
53
52
  };
54
- that[componentWillUnmount] = function () {
53
+ that[ReactConstants[1]] = function () {
55
54
  setState(indicator, {
56
55
  r: --count === 0
57
56
  });
58
57
  };
59
- that[render] = function () {
58
+ that[ReactConstants[3]] = function () {
60
59
  return null;
61
60
  };
62
61
  return _this2;
package/Scrollable.js CHANGED
@@ -1,10 +1,9 @@
1
- import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, scrollLeft as __scrollLeft, scrollTop as __scrollTop, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
1
+ import ReactConstants from "./ReactConstants";
2
+ import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, props as __props, scrollLeft as __scrollLeft, scrollTop as __scrollTop, state as __state, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
2
3
  import { inherits as _inherits, createSuper as _createSuper, classCallCheck as _classCallCheck, assertThisInitialized as _assertThisInitialized, createClass as _createClass } from './_virtual/_rollupPluginBabelHelpers.js';
3
4
  import {toConsumableArray as __toConsumableArray} from "./_virtual/_rollupPluginBabelHelpers";
4
5
  import {extends as __extends} from "./_virtual/_rollupPluginBabelHelpers";
5
6
  import {inherits as __inherits} from "./_virtual/_rollupPluginBabelHelpers";
6
- import {className as __className} from "./ReactConstants";
7
- import {children as __children} from "./ReactConstants";
8
7
  import 'react';
9
8
  import ReactCreateElement from './ReactCreateElement.js';
10
9
  import PropTypes from 'prop-types';
@@ -143,13 +142,13 @@ var Scrollable = function (_PureComponent) {
143
142
  thumbH.ondragstart = preventDefault;
144
143
  thumbH.onmouseup = reset;
145
144
  scrollbar.onclick = function (e) {
146
- if (e.target === scrollbar) {
145
+ if (__target(e) === scrollbar) {
147
146
  var thumbPosition = parseInt(__top(styleOf(thumb)));
148
147
  viewport.scrollTop += offsetHeightOf(viewport) * 0.9 * (e.offsetY < thumbPosition ? -1 : 1);
149
148
  }
150
149
  };
151
150
  scrollbarH.onclick = function (e) {
152
- if (e.target === scrollbarH) {
151
+ if (__target(e) === scrollbarH) {
153
152
  var thumbPosition = parseInt(__left(styleOf(thumbH)));
154
153
  viewport.scrollLeft += offsetWidthOf(viewport) * 0.9 * (e.offsetX < thumbPosition ? -1 : 1);
155
154
  }
@@ -274,9 +273,9 @@ var Scrollable = function (_PureComponent) {
274
273
  }, 50);
275
274
  }, 200);
276
275
  };
277
- that[componentDidMount] = init;
278
- that[componentWillUnmount] = clear;
279
- that[componentDidUpdate] = function (prevProps) {
276
+ that[ReactConstants[0]] = init;
277
+ that[ReactConstants[1]] = clear;
278
+ that[ReactConstants[2]] = function (prevProps) {
280
279
  if (scrollBarModeOf(props()) !== scrollBarModeOf(prevProps)) init();else if (onScroll(props()) !== onScroll(prevProps)) init();
281
280
  };
282
281
  that.setScroll = function (y) {
@@ -291,28 +290,28 @@ var Scrollable = function (_PureComponent) {
291
290
  that.getHeight = function () {
292
291
  return __clientHeight(containerRef());
293
292
  };
294
- that[render] = function () {
293
+ that[ReactConstants[3]] = function () {
295
294
  var _props = props();
296
- var className = _props[__className],
297
- children = _props[__children];
295
+ var className = _props[ReactConstants[5]],
296
+ children = _props[ReactConstants[4]];
298
297
  return ReactCreateElement("div", {
299
- [__className]: classNames('Scrollable', className, status() || WITH_SCROLL, statusH() + '-horizontal'),
298
+ [ReactConstants[5]]: classNames('Scrollable', className, status() || WITH_SCROLL, statusH() + '-horizontal'),
300
299
  style: styleOf(_props),
301
300
  ref: containerRef
302
301
  }, ReactCreateElement("div", {
303
- [__className]: "viewport",
302
+ [ReactConstants[5]]: "viewport",
304
303
  ref: viewportRef
305
304
  }, children), ReactCreateElement("div", {
306
- [__className]: classNames('scrollbar', scrollBarModeOf(_props) || SCROLLBAR_MODE_AUTO),
305
+ [ReactConstants[5]]: classNames('scrollbar', scrollBarModeOf(_props) || SCROLLBAR_MODE_AUTO),
307
306
  ref: scrollbarRef
308
307
  }, ReactCreateElement("div", {
309
- [__className]: "thumb",
308
+ [ReactConstants[5]]: "thumb",
310
309
  ref: thumbRef
311
310
  })), ReactCreateElement("div", {
312
- [__className]: classNames('scrollbar horizontal', horizontalScrollBarModeOf(_props)),
311
+ [ReactConstants[5]]: classNames('scrollbar horizontal', horizontalScrollBarModeOf(_props)),
313
312
  ref: horizontalScrollbarRef
314
313
  }, ReactCreateElement("div", {
315
- [__className]: "thumb",
314
+ [ReactConstants[5]]: "thumb",
316
315
  ref: horizontalThumbRef
317
316
  })));
318
317
  };
@@ -329,7 +328,7 @@ if (process.env.NODE_ENV !== 'production') {
329
328
  Scrollable.propTypes = {
330
329
  scrollBarMode: PropTypes.oneOf([SCROLLBAR_MODE_AUTO, SCROLLBAR_MODE_HIDDEN, SCROLLBAR_MODE_VISIBLE]),
331
330
  horizontalScrollBarMode: PropTypes.oneOf([SCROLLBAR_MODE_AUTO, SCROLLBAR_MODE_HIDDEN, SCROLLBAR_MODE_VISIBLE]),
332
- [__className]: PropTypes.string,
331
+ [ReactConstants[5]]: PropTypes.string,
333
332
  style: PropTypes.object,
334
333
  onScrolledToBottom: PropTypes.func,
335
334
  onScrolledToTop: PropTypes.func,
@@ -1,11 +1,10 @@
1
- import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, scrollLeft as __scrollLeft, scrollTop as __scrollTop, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
1
+ import ReactConstants from "./ReactConstants";
2
+ import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, props as __props, scrollLeft as __scrollLeft, scrollTop as __scrollTop, state as __state, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
2
3
 
3
4
  import { jsx as jsxRuntime_2 } from 'react/jsx-runtime';
4
5
  import {toConsumableArray as __toConsumableArray} from "./_virtual/_rollupPluginBabelHelpers";
5
6
  import {extends as __extends} from "./_virtual/_rollupPluginBabelHelpers";
6
7
  import {inherits as __inherits} from "./_virtual/_rollupPluginBabelHelpers";
7
- import {className as __className} from "./ReactConstants";
8
- import {children as __children} from "./ReactConstants";
9
8
  import Table from './Table.js';
10
9
  import Scrollable from './Scrollable.js';
11
10
  import { render, props, PureComponent } from './ReactConstants.js';
@@ -17,8 +16,8 @@ var ScrollableTable = /** @class */ (function (_super) {
17
16
  var _this = _super.call(this, properties) || this;
18
17
  var that = _this;
19
18
  var scrollableRef = createRef();
20
- that[render] = function () {
21
- return jsxRuntime_2("div", __extends({ [__className]: "ScrollableTable" }, { [__children]: jsxRuntime_2(Scrollable, __extends({ ref: scrollableRef }, props(that).scrollableProps, { [__children]: jsxRuntime_2(Table, __extends({}, props(that))) })) }));
19
+ that[ReactConstants[3]] = function () {
20
+ return jsxRuntime_2("div", __extends({ [ReactConstants[5]]: "ScrollableTable" }, { [ReactConstants[4]]: jsxRuntime_2(Scrollable, __extends({ ref: scrollableRef }, props(that).scrollableProps, { [ReactConstants[4]]: jsxRuntime_2(Table, __extends({}, props(that))) })) }));
22
21
  };
23
22
  that.getScrollable = function () { return scrollableRef(); };
24
23
  return _this;
package/Size.js CHANGED
@@ -1,17 +1,16 @@
1
- import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, scrollLeft as __scrollLeft, scrollTop as __scrollTop, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
1
+ import ReactConstants from "./ReactConstants";
2
+ import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, props as __props, scrollLeft as __scrollLeft, scrollTop as __scrollTop, state as __state, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
2
3
  import 'react';
3
4
  import {toConsumableArray as __toConsumableArray} from "./_virtual/_rollupPluginBabelHelpers";
4
5
  import {extends as __extends} from "./_virtual/_rollupPluginBabelHelpers";
5
6
  import {inherits as __inherits} from "./_virtual/_rollupPluginBabelHelpers";
6
- import {className as __className} from "./ReactConstants";
7
- import {children as __children} from "./ReactConstants";
8
7
  import ReactCreateElement from './ReactCreateElement.js';
9
8
  import { isUndefined } from './Tools.js';
10
9
 
11
10
  var Size = function Size(_ref) {
12
11
  var value = __value(_ref);
13
12
  return ReactCreateElement("span", {
14
- [__className]: "Size"
13
+ [ReactConstants[5]]: "Size"
15
14
  }, formatNumber(value, 1), "\xA0", formatAbbreviation(value));
16
15
  };
17
16
  var formatNumberWithMaxLength = function formatNumberWithMaxLength(size, fractionalLength, toAbbreviation, maxLength) {
package/Snackbar.js CHANGED
@@ -1,10 +1,9 @@
1
- import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, scrollLeft as __scrollLeft, scrollTop as __scrollTop, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
1
+ import ReactConstants from "./ReactConstants";
2
+ import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, props as __props, scrollLeft as __scrollLeft, scrollTop as __scrollTop, state as __state, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
2
3
  import { inherits as _inherits, createSuper as _createSuper, classCallCheck as _classCallCheck, assertThisInitialized as _assertThisInitialized, slicedToArray as _slicedToArray, createClass as _createClass } from './_virtual/_rollupPluginBabelHelpers.js';
3
4
  import {toConsumableArray as __toConsumableArray} from "./_virtual/_rollupPluginBabelHelpers";
4
5
  import {extends as __extends} from "./_virtual/_rollupPluginBabelHelpers";
5
6
  import {inherits as __inherits} from "./_virtual/_rollupPluginBabelHelpers";
6
- import {className as __className} from "./ReactConstants";
7
- import {children as __children} from "./ReactConstants";
8
7
  import 'react';
9
8
  import ReactDOM from 'react-dom';
10
9
  import ReactCreateElement from './ReactCreateElement.js';
@@ -28,16 +27,16 @@ var Snackbar = function (_PureComponent) {
28
27
  getText = _stateGSs2[1],
29
28
  clazzName = _stateGSs2[2];
30
29
  var timeout;
31
- that[componentWillUnmount] = function () {
30
+ that[ReactConstants[1]] = function () {
32
31
  clearTimeout(timeout);
33
32
  };
34
- that[render] = function () {
33
+ that[ReactConstants[3]] = function () {
35
34
  var _props = props(that);
36
35
  var container = _props.container;
37
36
  var el = ReactCreateElement("div", {
38
- [__className]: classNames("Snackbar", _props[className], isShow() && shown, clazzName())
37
+ [ReactConstants[5]]: classNames("Snackbar", _props[ReactConstants[5]], isShow() && shown, clazzName())
39
38
  }, ReactCreateElement("div", {
40
- [__className]: "message"
39
+ [ReactConstants[5]]: "message"
41
40
  }, getText() || _props.text));
42
41
  return container ? ReactDOM.createPortal(el, container) : el;
43
42
  };
@@ -63,7 +62,7 @@ var Snackbar = function (_PureComponent) {
63
62
  }(PureComponent);
64
63
  if (process.env.NODE_ENV !== 'production') {
65
64
  Snackbar.propTypes = {
66
- [__className]: PropTypes.string,
65
+ [ReactConstants[5]]: PropTypes.string,
67
66
  text: PropTypes.string,
68
67
  container: PropTypes.node
69
68
  };
@@ -1,20 +1,19 @@
1
- import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, scrollLeft as __scrollLeft, scrollTop as __scrollTop, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
1
+ import ReactConstants from "./ReactConstants";
2
+ import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, props as __props, scrollLeft as __scrollLeft, scrollTop as __scrollTop, state as __state, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
2
3
  import 'react';
3
4
  import {toConsumableArray as __toConsumableArray} from "./_virtual/_rollupPluginBabelHelpers";
4
5
  import {extends as __extends} from "./_virtual/_rollupPluginBabelHelpers";
5
6
  import {inherits as __inherits} from "./_virtual/_rollupPluginBabelHelpers";
6
- import {className as __className} from "./ReactConstants";
7
- import {children as __children} from "./ReactConstants";
8
7
  import ReactCreateElement from './ReactCreateElement.js';
9
8
 
10
9
  var SpinningProgress = function SpinningProgress() {
11
10
  return ReactCreateElement("div", {
12
- [__className]: "SpinningProgress"
11
+ [ReactConstants[5]]: "SpinningProgress"
13
12
  }, ReactCreateElement("svg", {
14
- [__className]: "circular",
13
+ [ReactConstants[5]]: "circular",
15
14
  viewBox: "0 0 24 24"
16
15
  }, ReactCreateElement("circle", {
17
- [__className]: "line",
16
+ [ReactConstants[5]]: "line",
18
17
  cx: "12",
19
18
  cy: "12",
20
19
  r: "8.75",
package/Switch.js CHANGED
@@ -1,10 +1,9 @@
1
- import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, scrollLeft as __scrollLeft, scrollTop as __scrollTop, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
1
+ import ReactConstants from "./ReactConstants";
2
+ import {clientHeight as __clientHeight, clientWidth as __clientWidth, createAccessor as __createAccessor, data as __data, height as __height, left as __left, length as __length, pageX as __pageX, pageY as __pageY, props as __props, scrollLeft as __scrollLeft, scrollTop as __scrollTop, state as __state, style as __style, target as __target, top as __top, value as __value, width as __width} from "./CommonFields";
2
3
  import { inherits as _inherits, createSuper as _createSuper, classCallCheck as _classCallCheck, createClass as _createClass } from './_virtual/_rollupPluginBabelHelpers.js';
3
4
  import {toConsumableArray as __toConsumableArray} from "./_virtual/_rollupPluginBabelHelpers";
4
5
  import {extends as __extends} from "./_virtual/_rollupPluginBabelHelpers";
5
6
  import {inherits as __inherits} from "./_virtual/_rollupPluginBabelHelpers";
6
- import {className as __className} from "./ReactConstants";
7
- import {children as __children} from "./ReactConstants";
8
7
  import 'react';
9
8
  import ReactCreateElement from './ReactCreateElement.js';
10
9
  import { classNames, getRandomId } from './Tools.js';
@@ -19,34 +18,34 @@ var Switch = function (_PureComponent) {
19
18
  _classCallCheck(this, Switch);
20
19
  _this = _super.call(this, props);
21
20
  var randomId = getRandomId('sw-');
22
- _this[render] = function () {
23
- var _this$props = _this.props,
21
+ _this[ReactConstants[3]] = function () {
22
+ var _this$props = __props(_this),
24
23
  label = _this$props.label,
25
- className = _this$props[__className],
24
+ className = _this$props[ReactConstants[5]],
26
25
  labelOn = _this$props.labelOn,
27
26
  labelOff = _this$props.labelOff,
28
- onChange = _this$props.onChange,
27
+ onChange = _this$props[ReactConstants[7]],
29
28
  value = __value(_this$props),
30
- onClick = _this$props.onClick;
31
- var id = _this.props.id || randomId;
29
+ onClick = _this$props[ReactConstants[6]];
30
+ var id = __props(_this).id || randomId;
32
31
  return ReactCreateElement("div", {
33
- [__className]: classNames("Switch", className),
34
- onClick: onClick
32
+ [ReactConstants[5]]: classNames("Switch", className),
33
+ [ReactConstants[6]]: onClick
35
34
  }, ReactCreateElement("input", {
36
35
  type: "checkbox",
37
36
  id: id,
38
- [__className]: "switch-input",
39
- onChange: onChange,
37
+ [ReactConstants[5]]: "switch-input",
38
+ [ReactConstants[7]]: onChange,
40
39
  checked: value
41
40
  }), ReactCreateElement("label", {
42
41
  htmlFor: id,
43
- [__className]: "switch-label"
42
+ [ReactConstants[5]]: "switch-label"
44
43
  }, label && ReactCreateElement("span", {
45
- [__className]: "label"
44
+ [ReactConstants[5]]: "label"
46
45
  }, label), labelOn && ReactCreateElement("span", {
47
- [__className]: "toggle--on"
46
+ [ReactConstants[5]]: "toggle--on"
48
47
  }, labelOn), labelOff && ReactCreateElement("span", {
49
- [__className]: "toggle--off"
48
+ [ReactConstants[5]]: "toggle--off"
50
49
  }, labelOff)));
51
50
  };
52
51
  return _this;
@@ -56,13 +55,13 @@ var Switch = function (_PureComponent) {
56
55
  var Switch$1 = Switch;
57
56
  if (process.env.NODE_ENV !== 'production') {
58
57
  Switch.propTypes = {
59
- [__className]: PropTypes.string,
58
+ [ReactConstants[5]]: PropTypes.string,
60
59
  label: PropTypes.string,
61
60
  labelOn: PropTypes.string,
62
61
  labelOff: PropTypes.string,
63
62
  value: PropTypes.bool,
64
- onChange: PropTypes.func,
65
- onClick: PropTypes.func,
63
+ [ReactConstants[7]]: PropTypes.func,
64
+ [ReactConstants[6]]: PropTypes.func,
66
65
  id: PropTypes.oneOfType([PropTypes.string, PropTypes.number])
67
66
  };
68
67
  }
package/Table.d.ts CHANGED
@@ -51,9 +51,16 @@ export interface TableState<T> {
51
51
  sortBy?: string;
52
52
  comparator?: Comparator;
53
53
  data?: T[];
54
- editing?: any;
55
54
  }
56
55
  declare class Table<T> extends Component<TableProps<T>, TableState<T>> {
57
56
  constructor(properties: any);
58
57
  }
58
+ export interface TableColumnSelect extends TableColumn<any> {
59
+ editorData?: any;
60
+ multiSelect?: any;
61
+ onSelect?: any;
62
+ editorSelectedComponent?: any;
63
+ editorChildCompononent?: any;
64
+ prefilter?: any;
65
+ }
59
66
  export default Table;