dash-core-components 1.16.0 → 2.2.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 (80) hide show
  1. package/README.md +8 -44
  2. package/dash_core_components/async-datepicker.js +1 -1
  3. package/dash_core_components/async-datepicker.js.map +1 -1
  4. package/dash_core_components/async-dropdown.js +2 -2
  5. package/dash_core_components/async-dropdown.js.map +1 -1
  6. package/dash_core_components/async-graph.js +1 -1
  7. package/dash_core_components/async-graph.js.map +1 -1
  8. package/dash_core_components/async-highlight.js +1 -1
  9. package/dash_core_components/async-highlight.js.map +1 -1
  10. package/dash_core_components/async-markdown.js +2 -2
  11. package/dash_core_components/async-markdown.js.map +1 -1
  12. package/dash_core_components/async-plotlyjs.js +2 -2
  13. package/dash_core_components/async-slider.js +1 -2
  14. package/dash_core_components/async-slider.js.map +1 -1
  15. package/dash_core_components/async-upload.js +1 -1
  16. package/dash_core_components/async-upload.js.map +1 -1
  17. package/dash_core_components/dash_core_components-shared.js +2 -2
  18. package/dash_core_components/dash_core_components-shared.js.map +1 -1
  19. package/dash_core_components/dash_core_components.js +3 -0
  20. package/dash_core_components/dash_core_components.js.map +1 -0
  21. package/dash_core_components/plotly.min.js +30 -26
  22. package/lib/components/Checklist.react.js +77 -35
  23. package/lib/components/Clipboard.react.js +354 -0
  24. package/lib/components/ConfirmDialog.react.js +16 -12
  25. package/lib/components/ConfirmDialogProvider.react.js +19 -15
  26. package/lib/components/DatePickerRange.react.js +111 -97
  27. package/lib/components/DatePickerSingle.react.js +95 -81
  28. package/lib/components/Download.react.js +16 -12
  29. package/lib/components/Dropdown.react.js +69 -47
  30. package/lib/components/Graph.react.js +36 -24
  31. package/lib/components/Input.react.js +98 -92
  32. package/lib/components/Interval.react.js +18 -12
  33. package/lib/components/Link.react.js +36 -30
  34. package/lib/components/Loading.react.js +21 -15
  35. package/lib/components/Location.react.js +15 -13
  36. package/lib/components/LogoutButton.react.js +18 -14
  37. package/lib/components/Markdown.react.js +23 -17
  38. package/lib/components/RadioItems.react.js +77 -35
  39. package/lib/components/RangeSlider.react.js +61 -55
  40. package/lib/components/Slider.react.js +52 -46
  41. package/lib/components/Store.react.js +16 -16
  42. package/lib/components/Tab.react.js +6 -2
  43. package/lib/components/Tabs.react.js +31 -22
  44. package/lib/components/Textarea.react.js +19 -13
  45. package/lib/components/Tooltip.react.js +152 -0
  46. package/lib/components/Upload.react.js +23 -17
  47. package/lib/components/css/Dropdown.css +1 -1
  48. package/lib/fragments/DatePickerRange.react.js +28 -17
  49. package/lib/fragments/DatePickerSingle.react.js +28 -17
  50. package/lib/fragments/Dropdown.react.js +29 -21
  51. package/lib/fragments/Graph.privateprops.js +1 -1
  52. package/lib/fragments/Graph.react.js +45 -29
  53. package/lib/fragments/Loading/spinners/CircleSpinner.js +16 -16
  54. package/lib/fragments/Loading/spinners/CubeSpinner.js +11 -11
  55. package/lib/fragments/Loading/spinners/DefaultSpinner.js +9 -9
  56. package/lib/fragments/Loading/spinners/DotSpinner.js +7 -7
  57. package/lib/fragments/Loading/spinners/GraphSpinner.js +18 -18
  58. package/lib/fragments/Markdown.react.js +35 -32
  59. package/lib/fragments/RangeSlider.react.js +57 -22
  60. package/lib/fragments/Slider.react.js +40 -21
  61. package/lib/fragments/Upload.react.js +19 -13
  62. package/lib/index.js +72 -56
  63. package/lib/third-party/highlight.js +12 -0
  64. package/lib/utils/LazyLoader/datePickerRange.js +9 -3
  65. package/lib/utils/LazyLoader/datePickerSingle.js +9 -3
  66. package/lib/utils/LazyLoader/dropdown.js +9 -3
  67. package/lib/utils/LazyLoader/graph.js +9 -3
  68. package/lib/utils/LazyLoader/hljs.js +9 -3
  69. package/lib/utils/LazyLoader/markdown.js +9 -3
  70. package/lib/utils/LazyLoader/plotly.js +9 -3
  71. package/lib/utils/LazyLoader/rangeSlider.js +9 -3
  72. package/lib/utils/LazyLoader/slider.js +9 -3
  73. package/lib/utils/LazyLoader/upload.js +9 -3
  74. package/lib/utils/computeSliderMarkers.js +230 -0
  75. package/lib/utils/convertToMoment.js +4 -0
  76. package/lib/utils/optionTypes.js +52 -0
  77. package/package.json +70 -78
  78. package/CHANGELOG.md +0 -1050
  79. package/dash_core_components/dash_core_components.min.js +0 -2
  80. package/dash_core_components/dash_core_components.min.js.map +0 -1
@@ -1,9 +1,11 @@
1
1
  "use strict";
2
2
 
3
+ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
+
3
5
  Object.defineProperty(exports, "__esModule", {
4
6
  value: true
5
7
  });
6
- exports.default = exports.graphDefaultProps = exports.graphPropTypes = void 0;
8
+ exports.graphPropTypes = exports.graphDefaultProps = exports.default = void 0;
7
9
 
8
10
  var _react = _interopRequireWildcard(require("react"));
9
11
 
@@ -19,19 +21,25 @@ var _Graph = require("../fragments/Graph.privateprops");
19
21
 
20
22
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
21
23
 
22
- function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } }
24
+ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
23
25
 
24
- function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) { return Object.getOwnPropertyDescriptor(source, sym).enumerable; })); } ownKeys.forEach(function (key) { _defineProperty(target, key, source[key]); }); } return target; }
26
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
25
27
 
26
- function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); }
28
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
27
29
 
28
- function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); }
30
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
29
31
 
30
- function _iterableToArrayLimit(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
32
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
31
33
 
32
- function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
34
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
35
+
36
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
37
+
38
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
33
39
 
34
- function _typeof(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
40
+ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
41
+
42
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
35
43
 
36
44
  function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
37
45
 
@@ -41,17 +49,21 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
41
49
 
42
50
  function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
43
51
 
44
- function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
52
+ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
45
53
 
46
- function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
54
+ function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
47
55
 
48
- function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
56
+ function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
57
+
58
+ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
59
+
60
+ function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
49
61
 
50
62
  function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
51
63
 
52
- function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
64
+ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
53
65
 
54
- function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
66
+ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
55
67
 
56
68
  var EMPTY_DATA = [];
57
69
  /**
@@ -61,17 +73,17 @@ var EMPTY_DATA = [];
61
73
  * hovering, clicking or selecting
62
74
  */
63
75
 
64
- var PlotlyGraph =
65
- /*#__PURE__*/
66
- function (_Component) {
76
+ var PlotlyGraph = /*#__PURE__*/function (_Component) {
67
77
  _inherits(PlotlyGraph, _Component);
68
78
 
79
+ var _super = _createSuper(PlotlyGraph);
80
+
69
81
  function PlotlyGraph(props) {
70
82
  var _this;
71
83
 
72
84
  _classCallCheck(this, PlotlyGraph);
73
85
 
74
- _this = _possibleConstructorReturn(this, _getPrototypeOf(PlotlyGraph).call(this, props));
86
+ _this = _super.call(this, props);
75
87
  _this.state = {
76
88
  prependData: [],
77
89
  extendData: []
@@ -154,7 +166,7 @@ function (_Component) {
154
166
  }, {
155
167
  key: "render",
156
168
  value: function render() {
157
- return _react.default.createElement(ControlledPlotlyGraph, _extends({}, this.props, {
169
+ return /*#__PURE__*/_react.default.createElement(ControlledPlotlyGraph, _extends({}, this.props, {
158
170
  prependData: this.state.prependData,
159
171
  extendData: this.state.extendData,
160
172
  clearState: this.clearState
@@ -173,21 +185,21 @@ var RealPlotlyGraph = (0, _dashComponentPlugins.asyncDecorator)(PlotlyGraph, fun
173
185
  return graph;
174
186
  });
175
187
  });
176
- var ControlledPlotlyGraph = (0, _react.memo)(function (props) {
188
+ var ControlledPlotlyGraph = /*#__PURE__*/(0, _react.memo)(function (props) {
177
189
  var className = props.className,
178
190
  id = props.id;
179
191
  var extendedClassName = className ? 'dash-graph ' + className : 'dash-graph';
180
- return _react.default.createElement(_react.Suspense, {
181
- fallback: _react.default.createElement("div", {
192
+ return /*#__PURE__*/_react.default.createElement(_react.Suspense, {
193
+ fallback: /*#__PURE__*/_react.default.createElement("div", {
182
194
  id: id,
183
195
  key: id,
184
196
  className: "".concat(extendedClassName, " dash-graph--pending")
185
197
  })
186
- }, _react.default.createElement(RealPlotlyGraph, _extends({}, props, {
198
+ }, /*#__PURE__*/_react.default.createElement(RealPlotlyGraph, _extends({}, props, {
187
199
  className: extendedClassName
188
200
  })));
189
201
  });
190
- PlotlyGraph.propTypes = _objectSpread({}, _Graph.privatePropTypes, {
202
+ PlotlyGraph.propTypes = _objectSpread(_objectSpread({}, _Graph.privatePropTypes), {}, {
191
203
  /**
192
204
  * The ID of this component, used to identify dash components
193
205
  * in callbacks. The ID needs to be unique across all of the
@@ -590,7 +602,7 @@ PlotlyGraph.propTypes = _objectSpread({}, _Graph.privatePropTypes, {
590
602
  })
591
603
  });
592
604
  ControlledPlotlyGraph.propTypes = PlotlyGraph.propTypes;
593
- PlotlyGraph.defaultProps = _objectSpread({}, _Graph.privateDefaultProps, {
605
+ PlotlyGraph.defaultProps = _objectSpread(_objectSpread({}, _Graph.privateDefaultProps), {}, {
594
606
  clickData: null,
595
607
  clickAnnotationData: null,
596
608
  hoverData: null,
@@ -1,5 +1,7 @@
1
1
  "use strict";
2
2
 
3
+ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
+
3
5
  Object.defineProperty(exports, "__esModule", {
4
6
  value: true
5
7
  });
@@ -17,9 +19,9 @@ require("./css/input.css");
17
19
 
18
20
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
19
21
 
20
- function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } }
22
+ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
21
23
 
22
- function _typeof(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
24
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
23
25
 
24
26
  function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
25
27
 
@@ -27,17 +29,21 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
27
29
 
28
30
  function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
29
31
 
30
- function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
32
+ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
31
33
 
32
- function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
34
+ function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
33
35
 
34
- function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
36
+ function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
37
+
38
+ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
39
+
40
+ function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
35
41
 
36
42
  function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
37
43
 
38
- function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
44
+ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
39
45
 
40
- function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
46
+ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
41
47
 
42
48
  // eslint-disable-next-line no-implicit-coercion
43
49
  var convert = function convert(val) {
@@ -56,18 +62,18 @@ var isEquivalent = function isEquivalent(v1, v2) {
56
62
  */
57
63
 
58
64
 
59
- var Input =
60
- /*#__PURE__*/
61
- function (_PureComponent) {
65
+ var Input = /*#__PURE__*/function (_PureComponent) {
62
66
  _inherits(Input, _PureComponent);
63
67
 
68
+ var _super = _createSuper(Input);
69
+
64
70
  function Input(props) {
65
71
  var _this;
66
72
 
67
73
  _classCallCheck(this, Input);
68
74
 
69
- _this = _possibleConstructorReturn(this, _getPrototypeOf(Input).call(this, props));
70
- _this.input = _react.default.createRef();
75
+ _this = _super.call(this, props);
76
+ _this.input = /*#__PURE__*/_react.default.createRef();
71
77
  _this.onBlur = _this.onBlur.bind(_assertThisInitialized(_this));
72
78
  _this.onChange = _this.onChange.bind(_assertThisInitialized(_this));
73
79
  _this.onEvent = _this.onEvent.bind(_assertThisInitialized(_this));
@@ -113,7 +119,7 @@ function (_PureComponent) {
113
119
  value: this.state.value
114
120
  };
115
121
  var loading_state = this.props.loading_state;
116
- return _react.default.createElement("input", _extends({
122
+ return /*#__PURE__*/_react.default.createElement("input", _extends({
117
123
  "data-dash-is-loading": loading_state && loading_state.is_loading || undefined,
118
124
  ref: this.input,
119
125
  onBlur: this.onBlur,
@@ -210,27 +216,16 @@ Input.defaultProps = {
210
216
  persistence_type: 'local'
211
217
  };
212
218
  Input.propTypes = {
213
- /**
214
- * The ID of this component, used to identify dash components
215
- * in callbacks. The ID needs to be unique across all of the
216
- * components in an app.
217
- */
218
- id: _propTypes.default.string,
219
-
220
219
  /**
221
220
  * The value of the input
222
221
  */
223
222
  value: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
224
223
 
225
224
  /**
226
- * The input's inline styles
227
- */
228
- style: _propTypes.default.object,
229
-
230
- /**
231
- * The class of the input element
225
+ * The type of control to render.
232
226
  */
233
- className: _propTypes.default.string,
227
+ type: _propTypes.default.oneOf([// Only allowing the input types with wide browser compatibility
228
+ 'text', 'number', 'password', 'email', 'range', 'search', 'tel', 'url', 'hidden']),
234
229
 
235
230
  /**
236
231
  * If true, changes to input will be sent back to the Dash server only on enter or when losing focus.
@@ -239,30 +234,19 @@ Input.propTypes = {
239
234
  debounce: _propTypes.default.bool,
240
235
 
241
236
  /**
242
- * The type of control to render.
243
- */
244
- type: _propTypes.default.oneOf([// Only allowing the input types with wide browser compatibility
245
- 'text', 'number', 'password', 'email', 'range', 'search', 'tel', 'url', 'hidden']),
246
-
247
- /**
248
- * This attribute indicates whether the value of the control can be automatically completed by the browser.
237
+ * A hint to the user of what can be entered in the control . The placeholder text must not contain carriage returns or line-feeds. Note: Do not use the placeholder attribute instead of a <label> element, their purposes are different. The <label> attribute describes the role of the form element (i.e. it indicates what kind of information is expected), and the placeholder attribute is a hint about the format that the content should take. There are cases in which the placeholder attribute is never displayed to the user, so the form must be understandable without it.
249
238
  */
250
- autoComplete: _propTypes.default.string,
239
+ placeholder: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
251
240
 
252
241
  /**
253
- * The element should be automatically focused after the page loaded.
254
- * autoFocus is an HTML boolean attribute - it is enabled by a boolean or
255
- * 'autoFocus'. Alternative capitalizations `autofocus` & `AUTOFOCUS`
256
- * are also acccepted.
242
+ * Number of times the `Enter` key was pressed while the input had focus.
257
243
  */
258
- autoFocus: _propTypes.default.oneOfType([_propTypes.default.oneOf(['autoFocus', 'autofocus', 'AUTOFOCUS']), _propTypes.default.bool]),
244
+ n_submit: _propTypes.default.number,
259
245
 
260
246
  /**
261
- * If true, the input is disabled and can't be clicked on.
262
- * disabled is an HTML boolean attribute - it is enabled by a boolean or
263
- * 'disabled'. Alternative capitalizations `DISABLED`
247
+ * Last time that `Enter` was pressed.
264
248
  */
265
- disabled: _propTypes.default.oneOfType([_propTypes.default.oneOf(['disabled', 'DISABLED']), _propTypes.default.bool]),
249
+ n_submit_timestamp: _propTypes.default.number,
266
250
 
267
251
  /**
268
252
  * Provides a hint to the browser as to the type of data that might be
@@ -315,80 +299,96 @@ Input.propTypes = {
315
299
  'url']),
316
300
 
317
301
  /**
318
- * Identifies a list of pre-defined options to suggest to the user.
319
- * The value must be the id of a <datalist> element in the same document.
320
- * The browser displays only options that are valid values for this
321
- * input element.
322
- * This attribute is ignored when the type attribute's value is
323
- * hidden, checkbox, radio, file, or a button type.
302
+ * This attribute indicates whether the value of the control can be automatically completed by the browser.
324
303
  */
325
- list: _propTypes.default.string,
304
+ autoComplete: _propTypes.default.string,
326
305
 
327
306
  /**
328
- * The maximum (numeric or date-time) value for this item, which must not be less than its minimum (min attribute) value.
307
+ * This attribute indicates that the user cannot modify the value of the control. The value of the attribute is irrelevant. If you need read-write access to the input value, do not add the "readonly" attribute. It is ignored if the value of the type attribute is hidden, range, color, checkbox, radio, file, or a button type (such as button or submit).
308
+ * readOnly is an HTML boolean attribute - it is enabled by a boolean or
309
+ * 'readOnly'. Alternative capitalizations `readonly` & `READONLY`
310
+ * are also acccepted.
329
311
  */
330
- max: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
312
+ readOnly: _propTypes.default.oneOfType([_propTypes.default.bool, _propTypes.default.oneOf(['readOnly', 'readonly', 'READONLY'])]),
331
313
 
332
314
  /**
333
- * If the value of the type attribute is text, email, search, password, tel, or url, this attribute specifies the maximum number of characters (in UTF-16 code units) that the user can enter. For other control types, it is ignored. It can exceed the value of the size attribute. If it is not specified, the user can enter an unlimited number of characters. Specifying a negative number results in the default behavior (i.e. the user can enter an unlimited number of characters). The constraint is evaluated only when the value of the attribute has been changed.
315
+ * This attribute specifies that the user must fill in a value before submitting a form. It cannot be used when the type attribute is hidden, image, or a button type (submit, reset, or button). The :optional and :required CSS pseudo-classes will be applied to the field as appropriate.
316
+ * required is an HTML boolean attribute - it is enabled by a boolean or
317
+ * 'required'. Alternative capitalizations `REQUIRED`
318
+ * are also acccepted.
334
319
  */
335
- maxLength: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
320
+ required: _propTypes.default.oneOfType([_propTypes.default.oneOf(['required', 'REQUIRED']), _propTypes.default.bool]),
336
321
 
337
322
  /**
338
- * The minimum (numeric or date-time) value for this item, which must not be greater than its maximum (max attribute) value.
323
+ * The element should be automatically focused after the page loaded.
324
+ * autoFocus is an HTML boolean attribute - it is enabled by a boolean or
325
+ * 'autoFocus'. Alternative capitalizations `autofocus` & `AUTOFOCUS`
326
+ * are also acccepted.
339
327
  */
340
- min: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
328
+ autoFocus: _propTypes.default.oneOfType([_propTypes.default.oneOf(['autoFocus', 'autofocus', 'AUTOFOCUS']), _propTypes.default.bool]),
341
329
 
342
330
  /**
343
- * If the value of the type attribute is text, email, search, password, tel, or url, this attribute specifies the minimum number of characters (in Unicode code points) that the user can enter. For other control types, it is ignored.
331
+ * If true, the input is disabled and can't be clicked on.
332
+ * disabled is an HTML boolean attribute - it is enabled by a boolean or
333
+ * 'disabled'. Alternative capitalizations `DISABLED`
344
334
  */
345
- minLength: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
335
+ disabled: _propTypes.default.oneOfType([_propTypes.default.oneOf(['disabled', 'DISABLED']), _propTypes.default.bool]),
336
+
337
+ /**
338
+ * Identifies a list of pre-defined options to suggest to the user.
339
+ * The value must be the id of a <datalist> element in the same document.
340
+ * The browser displays only options that are valid values for this
341
+ * input element.
342
+ * This attribute is ignored when the type attribute's value is
343
+ * hidden, checkbox, radio, file, or a button type.
344
+ */
345
+ list: _propTypes.default.string,
346
346
 
347
347
  /**
348
348
  * This Boolean attribute indicates whether the user can enter more than one value. This attribute applies when the type attribute is set to email or file, otherwise it is ignored.
349
349
  */
350
350
  multiple: _propTypes.default.bool,
351
351
 
352
+ /**
353
+ * Setting the value of this attribute to true indicates that the element needs to have its spelling and grammar checked. The value default indicates that the element is to act according to a default behavior, possibly based on the parent element's own spellcheck value. The value false indicates that the element should not be checked.
354
+ */
355
+ spellCheck: _propTypes.default.oneOfType([// enumerated property, not a boolean property: https://www.w3.org/TR/html51/editing.html#spelling-and-grammar-checking
356
+ _propTypes.default.oneOf(['true', 'false']), _propTypes.default.bool]),
357
+
352
358
  /**
353
359
  * The name of the control, which is submitted with the form data.
354
360
  */
355
361
  name: _propTypes.default.string,
356
362
 
357
363
  /**
358
- * A regular expression that the control's value is checked against. The pattern must match the entire value, not just some subset. Use the title attribute to describe the pattern to help the user. This attribute applies when the value of the type attribute is text, search, tel, url, email, or password, otherwise it is ignored. The regular expression language is the same as JavaScript RegExp algorithm, with the 'u' parameter that makes it treat the pattern as a sequence of unicode code points. The pattern is not surrounded by forward slashes.
364
+ * The minimum (numeric or date-time) value for this item, which must not be greater than its maximum (max attribute) value.
359
365
  */
360
- pattern: _propTypes.default.string,
366
+ min: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
361
367
 
362
368
  /**
363
- * A hint to the user of what can be entered in the control . The placeholder text must not contain carriage returns or line-feeds. Note: Do not use the placeholder attribute instead of a <label> element, their purposes are different. The <label> attribute describes the role of the form element (i.e. it indicates what kind of information is expected), and the placeholder attribute is a hint about the format that the content should take. There are cases in which the placeholder attribute is never displayed to the user, so the form must be understandable without it.
369
+ * The maximum (numeric or date-time) value for this item, which must not be less than its minimum (min attribute) value.
364
370
  */
365
- placeholder: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
371
+ max: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
366
372
 
367
373
  /**
368
- * This attribute indicates that the user cannot modify the value of the control. The value of the attribute is irrelevant. If you need read-write access to the input value, do not add the "readonly" attribute. It is ignored if the value of the type attribute is hidden, range, color, checkbox, radio, file, or a button type (such as button or submit).
369
- * readOnly is an HTML boolean attribute - it is enabled by a boolean or
370
- * 'readOnly'. Alternative capitalizations `readonly` & `READONLY`
371
- * are also acccepted.
374
+ * Works with the min and max attributes to limit the increments at which a numeric or date-time value can be set. It can be the string any or a positive floating point number. If this attribute is not set to any, the control accepts only values at multiples of the step value greater than the minimum.
372
375
  */
373
- readOnly: _propTypes.default.oneOfType([_propTypes.default.bool, _propTypes.default.oneOf(['readOnly', 'readonly', 'READONLY'])]),
376
+ step: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
374
377
 
375
378
  /**
376
- * This attribute specifies that the user must fill in a value before submitting a form. It cannot be used when the type attribute is hidden, image, or a button type (submit, reset, or button). The :optional and :required CSS pseudo-classes will be applied to the field as appropriate.
377
- * required is an HTML boolean attribute - it is enabled by a boolean or
378
- * 'required'. Alternative capitalizations `REQUIRED`
379
- * are also acccepted.
379
+ * If the value of the type attribute is text, email, search, password, tel, or url, this attribute specifies the minimum number of characters (in Unicode code points) that the user can enter. For other control types, it is ignored.
380
380
  */
381
- required: _propTypes.default.oneOfType([_propTypes.default.oneOf(['required', 'REQUIRED']), _propTypes.default.bool]),
381
+ minLength: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
382
382
 
383
383
  /**
384
- * The direction in which selection occurred. This is "forward" if the selection was made from left-to-right in an LTR locale or right-to-left in an RTL locale, or "backward" if the selection was made in the opposite direction. On platforms on which it's possible this value isn't known, the value can be "none"; for example, on macOS, the default direction is "none", then as the user begins to modify the selection using the keyboard, this will change to reflect the direction in which the selection is expanding.
384
+ * If the value of the type attribute is text, email, search, password, tel, or url, this attribute specifies the maximum number of characters (in UTF-16 code units) that the user can enter. For other control types, it is ignored. It can exceed the value of the size attribute. If it is not specified, the user can enter an unlimited number of characters. Specifying a negative number results in the default behavior (i.e. the user can enter an unlimited number of characters). The constraint is evaluated only when the value of the attribute has been changed.
385
385
  */
386
- selectionDirection: _propTypes.default.string,
386
+ maxLength: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
387
387
 
388
388
  /**
389
- * The offset into the element's text content of the last selected character. If there's no selection, this value indicates the offset to the character following the current text input cursor position (that is, the position the next character typed would occupy).
389
+ * A regular expression that the control's value is checked against. The pattern must match the entire value, not just some subset. Use the title attribute to describe the pattern to help the user. This attribute applies when the value of the type attribute is text, search, tel, url, email, or password, otherwise it is ignored. The regular expression language is the same as JavaScript RegExp algorithm, with the 'u' parameter that makes it treat the pattern as a sequence of unicode code points. The pattern is not surrounded by forward slashes.
390
390
  */
391
- selectionEnd: _propTypes.default.string,
391
+ pattern: _propTypes.default.string,
392
392
 
393
393
  /**
394
394
  * The offset into the element's text content of the first selected character. If there's no selection, this value indicates the offset to the character following the current text input cursor position (that is, the position the next character typed would occupy).
@@ -396,40 +396,46 @@ Input.propTypes = {
396
396
  selectionStart: _propTypes.default.string,
397
397
 
398
398
  /**
399
- * The initial size of the control. This value is in pixels unless the value of the type attribute is text or password, in which case it is an integer number of characters. Starting in, this attribute applies only when the type attribute is set to text, search, tel, url, email, or password, otherwise it is ignored. In addition, the size must be greater than zero. If you do not specify a size, a default value of 20 is used.' simply states "the user agent should ensure that at least that many characters are visible", but different characters can have different widths in certain fonts. In some browsers, a certain string with x characters will not be entirely visible even if size is defined to at least x.
399
+ * The offset into the element's text content of the last selected character. If there's no selection, this value indicates the offset to the character following the current text input cursor position (that is, the position the next character typed would occupy).
400
400
  */
401
- size: _propTypes.default.string,
401
+ selectionEnd: _propTypes.default.string,
402
402
 
403
403
  /**
404
- * Setting the value of this attribute to true indicates that the element needs to have its spelling and grammar checked. The value default indicates that the element is to act according to a default behavior, possibly based on the parent element's own spellcheck value. The value false indicates that the element should not be checked.
404
+ * The direction in which selection occurred. This is "forward" if the selection was made from left-to-right in an LTR locale or right-to-left in an RTL locale, or "backward" if the selection was made in the opposite direction. On platforms on which it's possible this value isn't known, the value can be "none"; for example, on macOS, the default direction is "none", then as the user begins to modify the selection using the keyboard, this will change to reflect the direction in which the selection is expanding.
405
405
  */
406
- spellCheck: _propTypes.default.oneOfType([// enumerated property, not a boolean property: https://www.w3.org/TR/html51/editing.html#spelling-and-grammar-checking
407
- _propTypes.default.oneOf(['true', 'false']), _propTypes.default.bool]),
406
+ selectionDirection: _propTypes.default.string,
408
407
 
409
408
  /**
410
- * Works with the min and max attributes to limit the increments at which a numeric or date-time value can be set. It can be the string any or a positive floating point number. If this attribute is not set to any, the control accepts only values at multiples of the step value greater than the minimum.
409
+ * Number of times the input lost focus.
411
410
  */
412
- step: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]),
411
+ n_blur: _propTypes.default.number,
413
412
 
414
413
  /**
415
- * Number of times the `Enter` key was pressed while the input had focus.
414
+ * Last time the input lost focus.
416
415
  */
417
- n_submit: _propTypes.default.number,
416
+ n_blur_timestamp: _propTypes.default.number,
418
417
 
419
418
  /**
420
- * Last time that `Enter` was pressed.
419
+ * The initial size of the control. This value is in pixels unless the value of the type attribute is text or password, in which case it is an integer number of characters. Starting in, this attribute applies only when the type attribute is set to text, search, tel, url, email, or password, otherwise it is ignored. In addition, the size must be greater than zero. If you do not specify a size, a default value of 20 is used.' simply states "the user agent should ensure that at least that many characters are visible", but different characters can have different widths in certain fonts. In some browsers, a certain string with x characters will not be entirely visible even if size is defined to at least x.
421
420
  */
422
- n_submit_timestamp: _propTypes.default.number,
421
+ size: _propTypes.default.string,
423
422
 
424
423
  /**
425
- * Number of times the input lost focus.
424
+ * The input's inline styles
426
425
  */
427
- n_blur: _propTypes.default.number,
426
+ style: _propTypes.default.object,
428
427
 
429
428
  /**
430
- * Last time the input lost focus.
429
+ * The class of the input element
431
430
  */
432
- n_blur_timestamp: _propTypes.default.number,
431
+ className: _propTypes.default.string,
432
+
433
+ /**
434
+ * The ID of this component, used to identify dash components
435
+ * in callbacks. The ID needs to be unique across all of the
436
+ * components in an app.
437
+ */
438
+ id: _propTypes.default.string,
433
439
 
434
440
  /**
435
441
  * Dash-assigned callback that gets fired when the value changes.
@@ -1,5 +1,7 @@
1
1
  "use strict";
2
2
 
3
+ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
+
3
5
  Object.defineProperty(exports, "__esModule", {
4
6
  value: true
5
7
  });
@@ -9,27 +11,31 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
9
11
 
10
12
  var _react = _interopRequireWildcard(require("react"));
11
13
 
12
- function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = Object.defineProperty && Object.getOwnPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : {}; if (desc.get || desc.set) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } } newObj.default = obj; return newObj; } }
14
+ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
13
15
 
14
- function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
16
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
15
17
 
16
- function _typeof(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
18
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
17
19
 
18
20
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
19
21
 
20
22
  function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
21
23
 
22
- function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
24
+ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
23
25
 
24
- function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }
26
+ function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
25
27
 
26
- function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
28
+ function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
29
+
30
+ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
31
+
32
+ function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
27
33
 
28
34
  function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
29
35
 
30
- function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
36
+ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
31
37
 
32
- function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
38
+ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
33
39
 
34
40
  // eslint-disable-line no-unused-vars
35
41
 
@@ -39,17 +45,17 @@ function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || func
39
45
  * Interval is good for triggering a component on a recurring basis.
40
46
  * The time delay is set with the property "interval" in milliseconds.
41
47
  */
42
- var Interval =
43
- /*#__PURE__*/
44
- function (_Component) {
48
+ var Interval = /*#__PURE__*/function (_Component) {
45
49
  _inherits(Interval, _Component);
46
50
 
51
+ var _super = _createSuper(Interval);
52
+
47
53
  function Interval(props) {
48
54
  var _this;
49
55
 
50
56
  _classCallCheck(this, Interval);
51
57
 
52
- _this = _possibleConstructorReturn(this, _getPrototypeOf(Interval).call(this, props));
58
+ _this = _super.call(this, props);
53
59
  _this.intervalId = null;
54
60
  _this.reportInterval = _this.reportInterval.bind(_assertThisInitialized(_this));
55
61
  _this.handleTimer = _this.handleTimer.bind(_assertThisInitialized(_this));