dash-core-components 2.10.0 → 2.11.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.
@@ -16,6 +16,7 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
16
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; }
17
17
  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; }
18
18
  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; }
19
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
19
20
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
20
21
  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."); }
21
22
  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); }
@@ -23,7 +24,6 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
23
24
  function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
24
25
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
25
26
  function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
26
- function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
27
27
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
28
28
  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, _toPropertyKey(descriptor.key), descriptor); } }
29
29
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
@@ -120,7 +120,9 @@ var PlotlyGraph = /*#__PURE__*/function (_Component) {
120
120
  value: function clearState(dataKey) {
121
121
  this.setState(function (props) {
122
122
  var data = props[dataKey];
123
- var res = data && data.length ? _defineProperty({}, dataKey, EMPTY_DATA) : undefined;
123
+ var res = data && data.length ? {
124
+ [dataKey]: EMPTY_DATA
125
+ } : undefined;
124
126
  return res;
125
127
  });
126
128
  }
@@ -137,9 +139,9 @@ var PlotlyGraph = /*#__PURE__*/function (_Component) {
137
139
  return PlotlyGraph;
138
140
  }(_react.Component);
139
141
  var RealPlotlyGraph = (0, _dashComponentPlugins.asyncDecorator)(PlotlyGraph, function () {
140
- return Promise.all([(0, _graph.default)(), (0, _plotly.default)(), PlotlyGraph._loadMathjax ? (0, _mathjax.default)() : undefined]).then(function (_ref2) {
141
- var _ref3 = _slicedToArray(_ref2, 1),
142
- graph = _ref3[0];
142
+ return Promise.all([(0, _graph.default)(), (0, _plotly.default)(), PlotlyGraph._loadMathjax ? (0, _mathjax.default)() : undefined]).then(function (_ref) {
143
+ var _ref2 = _slicedToArray(_ref, 1),
144
+ graph = _ref2[0];
143
145
  return graph;
144
146
  });
145
147
  });
@@ -132,14 +132,14 @@ var Location = /*#__PURE__*/function (_Component) {
132
132
  }, {
133
133
  key: "componentDidMount",
134
134
  value: function componentDidMount() {
135
- window.onpopstate = this.onLocationChange;
135
+ window.addEventListener('popstate', this.onLocationChange);
136
136
  window.addEventListener('_dashprivate_pushstate', this.onLocationChange);
137
137
  this.updateLocation(this.props);
138
138
  }
139
139
  }, {
140
140
  key: "componentWillUnmount",
141
141
  value: function componentWillUnmount() {
142
- window.onpopstate = function () {};
142
+ window.removeEventListener('popstate', this.onLocationChange);
143
143
  window.removeEventListener('_dashprivate_pushstate', this.onLocationChange);
144
144
  }
145
145
  }, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dash-core-components",
3
- "version": "2.10.0",
3
+ "version": "2.11.0",
4
4
  "description": "Core component suite for Dash",
5
5
  "repository": {
6
6
  "type": "git",
@@ -49,7 +49,7 @@
49
49
  "mathjax": "^3.2.2",
50
50
  "moment": "^2.29.4",
51
51
  "node-polyfill-webpack-plugin": "^2.0.1",
52
- "plotly.js-dist-min": "2.23.2",
52
+ "plotly.js-dist-min": "2.24.2",
53
53
  "prop-types": "^15.8.1",
54
54
  "ramda": "^0.29.0",
55
55
  "rc-slider": "^9.7.5",
@@ -90,8 +90,8 @@
90
90
  "react-jsx-parser": "1.21.0",
91
91
  "style-loader": "^3.3.3",
92
92
  "styled-jsx": "^3.4.4",
93
- "webpack": "^5.83.1",
94
- "webpack-cli": "^5.1.1"
93
+ "webpack": "^5.88.0",
94
+ "webpack-cli": "^5.1.4"
95
95
  },
96
96
  "files": [
97
97
  "/dash_core_components/*{.js,.map}",