@splunk/visualizations-shared 26.4.1 → 27.1.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 (63) hide show
  1. package/.loki/reference/chrome_docker_SizeAwareWrapper_50_parent.png +0 -0
  2. package/.loki/reference/chrome_docker_SizeAwareWrapper_Fix_size_container.png +0 -0
  3. package/.loki/reference/chrome_docker_SizeAwareWrapper_Flex_layout_container.png +0 -0
  4. package/.loki/reference/chrome_docker_SizeAwareWrapper_Flex_layout_container_with_extra_wrapper.png +0 -0
  5. package/Downloader.js +164 -403
  6. package/Downloader.js.map +7 -1
  7. package/FileDownloader.js +121 -557
  8. package/FileDownloader.js.map +7 -1
  9. package/JSONSchemaUtils.js +58 -134
  10. package/JSONSchemaUtils.js.map +7 -1
  11. package/Message.js +105 -270
  12. package/Message.js.map +7 -1
  13. package/RemoteIcon.js +272 -736
  14. package/RemoteIcon.js.map +7 -1
  15. package/RemoteImage.js +190 -458
  16. package/RemoteImage.js.map +7 -1
  17. package/SanitizeProps.js +117 -238
  18. package/SanitizeProps.js.map +7 -1
  19. package/SizeAwareWrapper.js +108 -306
  20. package/SizeAwareWrapper.js.map +7 -1
  21. package/SizeAwareWrapperDeprecated.js +117 -326
  22. package/SizeAwareWrapperDeprecated.js.map +7 -1
  23. package/VisualizationDocPage.js +212 -461
  24. package/VisualizationDocPage.js.map +7 -1
  25. package/colorConstants.js +81 -132
  26. package/colorConstants.js.map +7 -1
  27. package/colorUtils.js +47 -134
  28. package/colorUtils.js.map +7 -1
  29. package/configUtils.js +28 -112
  30. package/configUtils.js.map +7 -1
  31. package/console.js +45 -183
  32. package/console.js.map +7 -1
  33. package/dataSourceUtils.js +45 -140
  34. package/dataSourceUtils.js.map +7 -1
  35. package/domUtils.js +58 -122
  36. package/domUtils.js.map +7 -1
  37. package/hocUtils.js +45 -122
  38. package/hocUtils.js.map +7 -1
  39. package/i18n.js +168 -323
  40. package/i18n.js.map +7 -1
  41. package/iconUtils.js +47 -178
  42. package/iconUtils.js.map +7 -1
  43. package/mapUtils.js +45 -122
  44. package/mapUtils.js.map +7 -1
  45. package/numberUtils.js +101 -275
  46. package/numberUtils.js.map +7 -1
  47. package/package.json +18 -22
  48. package/previewVizMessage.js +28 -108
  49. package/previewVizMessage.js.map +7 -1
  50. package/propUtils.js +88 -212
  51. package/propUtils.js.map +7 -1
  52. package/schemaUtils.js +58 -185
  53. package/schemaUtils.js.map +7 -1
  54. package/simpleXMLOptions.js +142 -225
  55. package/simpleXMLOptions.js.map +7 -1
  56. package/style.js +65 -168
  57. package/style.js.map +7 -1
  58. package/testHelper.js +247 -303
  59. package/testHelper.js.map +7 -1
  60. package/themeUtils.js +63 -142
  61. package/themeUtils.js.map +7 -1
  62. package/trellisUtils.js +108 -276
  63. package/trellisUtils.js.map +7 -1
@@ -1,354 +1,145 @@
1
- /*!
2
- * Copyright © 2024 Splunk Inc.
3
- * SPLUNK CONFIDENTIAL – Use or disclosure of this material in whole or
4
- * in part without a valid written license from Splunk Inc. is PROHIBITED.
5
- */
6
- module.exports =
7
- /******/ (function(modules) { // webpackBootstrap
8
- /******/ // The module cache
9
- /******/ var installedModules = {};
10
- /******/
11
- /******/ // The require function
12
- /******/ function __webpack_require__(moduleId) {
13
- /******/
14
- /******/ // Check if module is in cache
15
- /******/ if(installedModules[moduleId]) {
16
- /******/ return installedModules[moduleId].exports;
17
- /******/ }
18
- /******/ // Create a new module (and put it into the cache)
19
- /******/ var module = installedModules[moduleId] = {
20
- /******/ i: moduleId,
21
- /******/ l: false,
22
- /******/ exports: {}
23
- /******/ };
24
- /******/
25
- /******/ // Execute the module function
26
- /******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
27
- /******/
28
- /******/ // Flag the module as loaded
29
- /******/ module.l = true;
30
- /******/
31
- /******/ // Return the exports of the module
32
- /******/ return module.exports;
33
- /******/ }
34
- /******/
35
- /******/
36
- /******/ // expose the modules object (__webpack_modules__)
37
- /******/ __webpack_require__.m = modules;
38
- /******/
39
- /******/ // expose the module cache
40
- /******/ __webpack_require__.c = installedModules;
41
- /******/
42
- /******/ // define getter function for harmony exports
43
- /******/ __webpack_require__.d = function(exports, name, getter) {
44
- /******/ if(!__webpack_require__.o(exports, name)) {
45
- /******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
46
- /******/ }
47
- /******/ };
48
- /******/
49
- /******/ // define __esModule on exports
50
- /******/ __webpack_require__.r = function(exports) {
51
- /******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
52
- /******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
53
- /******/ }
54
- /******/ Object.defineProperty(exports, '__esModule', { value: true });
55
- /******/ };
56
- /******/
57
- /******/ // create a fake namespace object
58
- /******/ // mode & 1: value is a module id, require it
59
- /******/ // mode & 2: merge all properties of value into the ns
60
- /******/ // mode & 4: return value when already ns object
61
- /******/ // mode & 8|1: behave like require
62
- /******/ __webpack_require__.t = function(value, mode) {
63
- /******/ if(mode & 1) value = __webpack_require__(value);
64
- /******/ if(mode & 8) return value;
65
- /******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
66
- /******/ var ns = Object.create(null);
67
- /******/ __webpack_require__.r(ns);
68
- /******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
69
- /******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
70
- /******/ return ns;
71
- /******/ };
72
- /******/
73
- /******/ // getDefaultExport function for compatibility with non-harmony modules
74
- /******/ __webpack_require__.n = function(module) {
75
- /******/ var getter = module && module.__esModule ?
76
- /******/ function getDefault() { return module['default']; } :
77
- /******/ function getModuleExports() { return module; };
78
- /******/ __webpack_require__.d(getter, 'a', getter);
79
- /******/ return getter;
80
- /******/ };
81
- /******/
82
- /******/ // Object.prototype.hasOwnProperty.call
83
- /******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
84
- /******/
85
- /******/ // __webpack_public_path__
86
- /******/ __webpack_require__.p = "";
87
- /******/
88
- /******/
89
- /******/ // Load entry module and return exports
90
- /******/ return __webpack_require__(__webpack_require__.s = 48);
91
- /******/ })
92
- /************************************************************************/
93
- /******/ ({
94
-
95
- /***/ 0:
96
- /***/ (function(module, exports) {
97
-
98
- module.exports = require("prop-types");
99
-
100
- /***/ }),
101
-
102
- /***/ 1:
103
- /***/ (function(module, exports) {
104
-
105
- module.exports = require("react");
106
-
107
- /***/ }),
108
-
109
- /***/ 11:
110
- /***/ (function(module, exports) {
111
-
112
- module.exports = require("@babel/runtime/helpers/assertThisInitialized");
113
-
114
- /***/ }),
115
-
116
- /***/ 2:
117
- /***/ (function(module, exports) {
118
-
119
- module.exports = require("@babel/runtime/helpers/defineProperty");
120
-
121
- /***/ }),
122
-
123
- /***/ 3:
124
- /***/ (function(module, exports) {
125
-
126
- module.exports = require("@babel/runtime/helpers/getPrototypeOf");
127
-
128
- /***/ }),
129
-
130
- /***/ 48:
131
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
132
-
133
- "use strict";
134
- __webpack_require__.r(__webpack_exports__);
135
- /* harmony import */ var _babel_runtime_helpers_classCallCheck__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5);
136
- /* harmony import */ var _babel_runtime_helpers_classCallCheck__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_classCallCheck__WEBPACK_IMPORTED_MODULE_0__);
137
- /* harmony import */ var _babel_runtime_helpers_createClass__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6);
138
- /* harmony import */ var _babel_runtime_helpers_createClass__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_createClass__WEBPACK_IMPORTED_MODULE_1__);
139
- /* harmony import */ var _babel_runtime_helpers_assertThisInitialized__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(11);
140
- /* harmony import */ var _babel_runtime_helpers_assertThisInitialized__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_assertThisInitialized__WEBPACK_IMPORTED_MODULE_2__);
141
- /* harmony import */ var _babel_runtime_helpers_inherits__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7);
142
- /* harmony import */ var _babel_runtime_helpers_inherits__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_inherits__WEBPACK_IMPORTED_MODULE_3__);
143
- /* harmony import */ var _babel_runtime_helpers_possibleConstructorReturn__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(8);
144
- /* harmony import */ var _babel_runtime_helpers_possibleConstructorReturn__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_possibleConstructorReturn__WEBPACK_IMPORTED_MODULE_4__);
145
- /* harmony import */ var _babel_runtime_helpers_getPrototypeOf__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(3);
146
- /* harmony import */ var _babel_runtime_helpers_getPrototypeOf__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_getPrototypeOf__WEBPACK_IMPORTED_MODULE_5__);
147
- /* harmony import */ var _babel_runtime_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(2);
148
- /* harmony import */ var _babel_runtime_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_babel_runtime_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_6__);
149
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(1);
150
- /* harmony import */ var react__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_7__);
151
- /* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(0);
152
- /* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_8__);
153
-
154
-
155
-
156
-
157
-
158
-
159
-
160
-
161
- function _createSuper(Derived) {
162
- var hasNativeReflectConstruct = _isNativeReflectConstruct();
163
-
164
- return function _createSuperInternal() {
165
- var Super = _babel_runtime_helpers_getPrototypeOf__WEBPACK_IMPORTED_MODULE_5___default()(Derived),
166
- result;
167
-
168
- if (hasNativeReflectConstruct) {
169
- var NewTarget = _babel_runtime_helpers_getPrototypeOf__WEBPACK_IMPORTED_MODULE_5___default()(this).constructor;
170
-
171
- result = Reflect.construct(Super, arguments, NewTarget);
172
- } else {
173
- result = Super.apply(this, arguments);
174
- }
175
-
176
- return _babel_runtime_helpers_possibleConstructorReturn__WEBPACK_IMPORTED_MODULE_4___default()(this, result);
177
- };
178
- }
179
-
180
- function _isNativeReflectConstruct() {
181
- if (typeof Reflect === "undefined" || !Reflect.construct) return false;
182
- if (Reflect.construct.sham) return false;
183
- if (typeof Proxy === "function") return true;
184
-
185
- try {
186
- Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
187
- return true;
188
- } catch (e) {
189
- return false;
1
+ /* Copyright © 2020 Splunk Inc.
2
+ SPLUNK CONFIDENTIAL – Use or disclosure of this material in whole or
3
+ in part without a valid written license from Splunk Inc. is PROHIBITED. */
4
+ var __create = Object.create;
5
+ var __defProp = Object.defineProperty;
6
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
7
+ var __getOwnPropNames = Object.getOwnPropertyNames;
8
+ var __getProtoOf = Object.getPrototypeOf;
9
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
10
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
11
+ var __export = (target, all) => {
12
+ for (var name in all)
13
+ __defProp(target, name, { get: all[name], enumerable: true });
14
+ };
15
+ var __copyProps = (to, from, except, desc) => {
16
+ if (from && typeof from === "object" || typeof from === "function") {
17
+ for (let key of __getOwnPropNames(from))
18
+ if (!__hasOwnProp.call(to, key) && key !== except)
19
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
190
20
  }
191
- }
192
-
193
-
194
-
21
+ return to;
22
+ };
23
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
24
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
25
+ // If the importer is in node compatibility mode or this is not an ESM
26
+ // file that has been converted to a CommonJS file using a Babel-
27
+ // compatible transform (i.e. "__esModule" has not been set), then set
28
+ // "default" to the CommonJS "module.exports" for node compatibility.
29
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
30
+ mod
31
+ ));
32
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
33
+ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
34
+
35
+ // src/SizeAwareWrapperDeprecated.jsx
36
+ var SizeAwareWrapperDeprecated_exports = {};
37
+ __export(SizeAwareWrapperDeprecated_exports, {
38
+ default: () => SizeAwareWrapperDeprecated_default
39
+ });
40
+ module.exports = __toCommonJS(SizeAwareWrapperDeprecated_exports);
41
+
42
+ // esm-externals:react
43
+ var react_exports = {};
44
+ __export(react_exports, {
45
+ default: () => react_default
46
+ });
47
+ var defaultImport = __toESM(require("react"));
48
+ __reExport(react_exports, require("react"));
49
+ var react_default = "default" in defaultImport ? defaultImport.default : defaultImport;
50
+
51
+ // esm-externals:prop-types
52
+ var prop_types_exports = {};
53
+ __export(prop_types_exports, {
54
+ default: () => prop_types_default
55
+ });
56
+ var defaultImport2 = __toESM(require("prop-types"));
57
+ __reExport(prop_types_exports, require("prop-types"));
58
+ var prop_types_default = "default" in defaultImport2 ? defaultImport2.default : defaultImport2;
59
+
60
+ // src/SizeAwareWrapperDeprecated.jsx
195
61
  var styles = {
196
- position: 'absolute',
62
+ position: "absolute",
197
63
  width: 0,
198
64
  height: 0,
199
- visibility: 'hidden',
200
- display: 'none'
65
+ visibility: "hidden",
66
+ display: "none"
201
67
  };
202
-
203
- var SizeAwareWrapperDeprecated = /*#__PURE__*/function (_PureComponent) {
204
- _babel_runtime_helpers_inherits__WEBPACK_IMPORTED_MODULE_3___default()(SizeAwareWrapperDeprecated, _PureComponent);
205
-
206
- var _super = _createSuper(SizeAwareWrapperDeprecated);
207
-
208
- function SizeAwareWrapperDeprecated(props) {
209
- var _this;
210
-
211
- _babel_runtime_helpers_classCallCheck__WEBPACK_IMPORTED_MODULE_0___default()(this, SizeAwareWrapperDeprecated);
212
-
213
- _this = _super.call(this, props);
214
-
215
- _babel_runtime_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_6___default()(_babel_runtime_helpers_assertThisInitialized__WEBPACK_IMPORTED_MODULE_2___default()(_this), "getElement", function () {
216
- // it listens on the size of its parent elemnt
217
- var parentElement = _this.el && _this.el.parentElement;
68
+ var SizeAwareWrapperDeprecated = class extends react_exports.PureComponent {
69
+ constructor(props) {
70
+ super(props);
71
+ __publicField(this, "getElement", () => {
72
+ const parentElement = this.el && this.el.parentElement;
218
73
  return parentElement;
219
74
  });
220
-
221
- _babel_runtime_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_6___default()(_babel_runtime_helpers_assertThisInitialized__WEBPACK_IMPORTED_MODULE_2___default()(_this), "handleResize", function (entries) {
222
- entries.forEach(function (entry) {
223
- var _entry$contentRect = entry.contentRect,
224
- width = _entry$contentRect.width,
225
- height = _entry$contentRect.height; // use requestAnimationFrame to make sure width/height is updated in time
226
-
227
- _this.animationFrameID = window.requestAnimationFrame(function () {
228
- _this.setState({
229
- width: width,
230
- height: height
231
- });
75
+ __publicField(this, "handleResize", (entries) => {
76
+ entries.forEach((entry) => {
77
+ const { width, height } = entry.contentRect;
78
+ this.animationFrameID = window.requestAnimationFrame(() => {
79
+ this.setState({ width, height });
232
80
  });
233
81
  });
234
82
  });
235
-
236
- _babel_runtime_helpers_defineProperty__WEBPACK_IMPORTED_MODULE_6___default()(_babel_runtime_helpers_assertThisInitialized__WEBPACK_IMPORTED_MODULE_2___default()(_this), "renderChildren", function () {
237
- // expect children to be a function
238
- var _this$state = _this.state,
239
- width = _this$state.width,
240
- height = _this$state.height;
241
- var children = _this.props.children;
242
-
243
- if (width != null && height != null && typeof children === 'function') {
244
- return children({
245
- width: width,
246
- height: height
247
- });
83
+ __publicField(this, "renderChildren", () => {
84
+ const { width, height } = this.state;
85
+ const { children } = this.props;
86
+ if (width != null && height != null && typeof children === "function") {
87
+ return children({ width, height });
248
88
  }
249
-
250
89
  return null;
251
90
  });
252
-
253
- _this.state = {
91
+ this.state = {
254
92
  width: null,
255
93
  height: null
256
94
  };
257
- _this.animationFrameID = null;
258
- _this.ro = _this.getResizeObserver();
259
- return _this;
95
+ this.animationFrameID = null;
96
+ this.ro = this.getResizeObserver();
260
97
  }
261
-
262
- _babel_runtime_helpers_createClass__WEBPACK_IMPORTED_MODULE_1___default()(SizeAwareWrapperDeprecated, [{
263
- key: "componentDidMount",
264
- value: function componentDidMount() {
265
- var resizableElement = this.getElement();
266
-
267
- if (resizableElement) {
268
- this.ro.observe(resizableElement);
269
- }
98
+ componentDidMount() {
99
+ const resizableElement = this.getElement();
100
+ if (resizableElement) {
101
+ this.ro.observe(resizableElement);
270
102
  }
271
- }, {
272
- key: "componentWillUnmount",
273
- value: function componentWillUnmount() {
274
- var resizableElement = this.getElement();
275
-
276
- if (resizableElement) {
277
- this.ro.unobserve(resizableElement);
278
- }
279
-
280
- if (window && this.animationFrameID) {
281
- window.cancelAnimationFrame(this.animationFrameID);
282
- }
103
+ }
104
+ componentWillUnmount() {
105
+ const resizableElement = this.getElement();
106
+ if (resizableElement) {
107
+ this.ro.unobserve(resizableElement);
283
108
  }
284
- }, {
285
- key: "getResizeObserver",
286
- value: function getResizeObserver() {
287
- if (typeof ResizeObserver !== 'function') {
288
- return {
289
- observe: function observe() {},
290
- unobserve: function unobserve() {}
291
- };
292
- }
293
-
294
- return new ResizeObserver(this.handleResize);
109
+ if (window && this.animationFrameID) {
110
+ window.cancelAnimationFrame(this.animationFrameID);
295
111
  }
296
- }, {
297
- key: "render",
298
- value: function render() {
299
- var _this2 = this;
300
-
301
- return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_7___default.a.createElement(react__WEBPACK_IMPORTED_MODULE_7___default.a.Fragment, null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_7___default.a.createElement("div", {
112
+ }
113
+ getResizeObserver() {
114
+ if (typeof ResizeObserver !== "function") {
115
+ return {
116
+ observe() {
117
+ },
118
+ unobserve() {
119
+ }
120
+ };
121
+ }
122
+ return new ResizeObserver(this.handleResize);
123
+ }
124
+ render() {
125
+ return /* @__PURE__ */ react_default.createElement(react_default.Fragment, null, /* @__PURE__ */ react_default.createElement(
126
+ "div",
127
+ {
302
128
  key: "resize-detector",
303
129
  style: styles,
304
- ref: function ref(el) {
305
- _this2.el = el;
130
+ ref: (el) => {
131
+ this.el = el;
306
132
  }
307
- }), this.renderChildren());
308
- }
309
- }]);
310
-
311
- return SizeAwareWrapperDeprecated;
312
- }(react__WEBPACK_IMPORTED_MODULE_7__["PureComponent"]);
313
-
133
+ }
134
+ ), this.renderChildren());
135
+ }
136
+ };
314
137
  SizeAwareWrapperDeprecated.propTypes = {
315
- children: prop_types__WEBPACK_IMPORTED_MODULE_8___default.a.any // eslint-disable-line react/forbid-prop-types
316
-
138
+ children: prop_types_default.any
139
+ // eslint-disable-line react/forbid-prop-types
317
140
  };
318
141
  SizeAwareWrapperDeprecated.defaultProps = {
319
142
  children: null
320
143
  };
321
- /* harmony default export */ __webpack_exports__["default"] = (SizeAwareWrapperDeprecated);
322
-
323
- /***/ }),
324
-
325
- /***/ 5:
326
- /***/ (function(module, exports) {
327
-
328
- module.exports = require("@babel/runtime/helpers/classCallCheck");
329
-
330
- /***/ }),
331
-
332
- /***/ 6:
333
- /***/ (function(module, exports) {
334
-
335
- module.exports = require("@babel/runtime/helpers/createClass");
336
-
337
- /***/ }),
338
-
339
- /***/ 7:
340
- /***/ (function(module, exports) {
341
-
342
- module.exports = require("@babel/runtime/helpers/inherits");
343
-
344
- /***/ }),
345
-
346
- /***/ 8:
347
- /***/ (function(module, exports) {
348
-
349
- module.exports = require("@babel/runtime/helpers/possibleConstructorReturn");
350
-
351
- /***/ })
352
-
353
- /******/ });
354
- //# sourceMappingURL=SizeAwareWrapperDeprecated.js.map
144
+ var SizeAwareWrapperDeprecated_default = SizeAwareWrapperDeprecated;
145
+ //# sourceMappingURL=SizeAwareWrapperDeprecated.js.map
@@ -1 +1,7 @@
1
- {"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///external \"prop-types\"","webpack:///external \"react\"","webpack:///external \"@babel/runtime/helpers/assertThisInitialized\"","webpack:///external \"@babel/runtime/helpers/defineProperty\"","webpack:///external \"@babel/runtime/helpers/getPrototypeOf\"","webpack:///./src/SizeAwareWrapperDeprecated.jsx","webpack:///external \"@babel/runtime/helpers/classCallCheck\"","webpack:///external \"@babel/runtime/helpers/createClass\"","webpack:///external \"@babel/runtime/helpers/inherits\"","webpack:///external \"@babel/runtime/helpers/possibleConstructorReturn\""],"names":["styles","position","width","height","visibility","display","SizeAwareWrapperDeprecated","parentElement","entries","entry","children","resizableElement","window","observe","unobserve","PureComponent","T"],"mappings":";;;;;;;QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA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BAAa;AACTD,WAAK,EADI;AAETC,YAAM,EAAE;AAFC,KAAb;AAIA;AACA,eAAU,MAAV,iBAAU,EAAV;AAPe;AAQlB;;;;WAED,6BAAoB;AAChB,UAAMQ,gBAAgB,GAAG,KAAzB,UAAyB,EAAzB;;AACA,4BAAsB;AAClB;AACH;AACJ;;;WAED,gCAAuB;AACnB,UAAMA,gBAAgB,GAAG,KAAzB,UAAyB,EAAzB;;AACA,4BAAsB;AAClB;AACH;;AACD,UAAIC,MAAM,IAAI,KAAd,kBAAqC;AACjCA,cAAM,CAANA,qBAA4B,KAA5BA;AACH;AACJ;;;WAQD,6BAAoB;AAChB,UAAI,0BAAJ,YAA0C;AACtC,eAAO;AACHC,iBADG,qBACO,CADP;AAEHC,mBAFG,uBAES,CAAE;AAFX,SAAP;AAIH;;AACD,aAAO,mBAAmB,KAA1B,YAAO,CAAP;AACH;;;WAsBD,kBAAS;AAAA;;AACL,0BACI,2DAAC,4CAAD,8BACI;AACI,WAAG,EADP;AAEI,aAAK,EAFT;AAGI,WAAG,EAAE,iBAAM;AACP,gBAAI,CAAJ;AACH;AALL,QADJ,EAQK,KATT,cASS,EARL,CADJ;AAYH;;;;EA7EoCC,mD;;AAgFzCT,0BAA0B,CAA1BA,YAAuC;AACnCI,UAAQ,EAAEM,iDAAC,CADwB,IAClB;;AADkB,CAAvCV;AAIAA,0BAA0B,CAA1BA,eAA0C;AACtCI,UAAQ,EAAE;AAD4B,CAA1CJ;AAIA,2F;;;;;;;ACnGA,kE;;;;;;;ACAA,+D;;;;;;;ACAA,4D;;;;;;;ACAA,6E","file":"SizeAwareWrapperDeprecated.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 48);\n","module.exports = require(\"prop-types\");","module.exports = require(\"react\");","module.exports = require(\"@babel/runtime/helpers/assertThisInitialized\");","module.exports = require(\"@babel/runtime/helpers/defineProperty\");","module.exports = require(\"@babel/runtime/helpers/getPrototypeOf\");","import React, { PureComponent } from 'react';\nimport T from 'prop-types';\n\nconst styles = {\n position: 'absolute',\n width: 0,\n height: 0,\n visibility: 'hidden',\n display: 'none',\n};\n\nclass SizeAwareWrapperDeprecated extends PureComponent {\n constructor(props) {\n super(props);\n this.state = {\n width: null,\n height: null,\n };\n this.animationFrameID = null;\n this.ro = this.getResizeObserver();\n }\n\n componentDidMount() {\n const resizableElement = this.getElement();\n if (resizableElement) {\n this.ro.observe(resizableElement);\n }\n }\n\n componentWillUnmount() {\n const resizableElement = this.getElement();\n if (resizableElement) {\n this.ro.unobserve(resizableElement);\n }\n if (window && this.animationFrameID) {\n window.cancelAnimationFrame(this.animationFrameID);\n }\n }\n\n getElement = () => {\n // it listens on the size of its parent elemnt\n const parentElement = this.el && this.el.parentElement;\n return parentElement;\n };\n\n getResizeObserver() {\n if (typeof ResizeObserver !== 'function') {\n return {\n observe() {},\n unobserve() {},\n };\n }\n return new ResizeObserver(this.handleResize);\n }\n\n handleResize = entries => {\n entries.forEach(entry => {\n const { width, height } = entry.contentRect;\n // use requestAnimationFrame to make sure width/height is updated in time\n this.animationFrameID = window.requestAnimationFrame(() => {\n this.setState({ width, height });\n });\n });\n };\n\n renderChildren = () => {\n // expect children to be a function\n const { width, height } = this.state;\n const { children } = this.props;\n if (width != null && height != null && typeof children === 'function') {\n return children({ width, height });\n }\n return null;\n };\n\n render() {\n return (\n <React.Fragment>\n <div\n key=\"resize-detector\"\n style={styles}\n ref={el => {\n this.el = el;\n }}\n />\n {this.renderChildren()}\n </React.Fragment>\n );\n }\n}\n\nSizeAwareWrapperDeprecated.propTypes = {\n children: T.any, // eslint-disable-line react/forbid-prop-types\n};\n\nSizeAwareWrapperDeprecated.defaultProps = {\n children: null,\n};\n\nexport default SizeAwareWrapperDeprecated;\n","module.exports = require(\"@babel/runtime/helpers/classCallCheck\");","module.exports = require(\"@babel/runtime/helpers/createClass\");","module.exports = require(\"@babel/runtime/helpers/inherits\");","module.exports = require(\"@babel/runtime/helpers/possibleConstructorReturn\");"],"sourceRoot":""}
1
+ {
2
+ "version": 3,
3
+ "sources": ["src/SizeAwareWrapperDeprecated.jsx", "esm-externals:react", "esm-externals:prop-types"],
4
+ "sourcesContent": ["import React, { PureComponent } from 'react';\nimport T from 'prop-types';\n\nconst styles = {\n position: 'absolute',\n width: 0,\n height: 0,\n visibility: 'hidden',\n display: 'none',\n};\n\nclass SizeAwareWrapperDeprecated extends PureComponent {\n constructor(props) {\n super(props);\n this.state = {\n width: null,\n height: null,\n };\n this.animationFrameID = null;\n this.ro = this.getResizeObserver();\n }\n\n componentDidMount() {\n const resizableElement = this.getElement();\n if (resizableElement) {\n this.ro.observe(resizableElement);\n }\n }\n\n componentWillUnmount() {\n const resizableElement = this.getElement();\n if (resizableElement) {\n this.ro.unobserve(resizableElement);\n }\n if (window && this.animationFrameID) {\n window.cancelAnimationFrame(this.animationFrameID);\n }\n }\n\n getElement = () => {\n // it listens on the size of its parent elemnt\n const parentElement = this.el && this.el.parentElement;\n return parentElement;\n };\n\n getResizeObserver() {\n if (typeof ResizeObserver !== 'function') {\n return {\n observe() {},\n unobserve() {},\n };\n }\n return new ResizeObserver(this.handleResize);\n }\n\n handleResize = entries => {\n entries.forEach(entry => {\n const { width, height } = entry.contentRect;\n // use requestAnimationFrame to make sure width/height is updated in time\n this.animationFrameID = window.requestAnimationFrame(() => {\n this.setState({ width, height });\n });\n });\n };\n\n renderChildren = () => {\n // expect children to be a function\n const { width, height } = this.state;\n const { children } = this.props;\n if (width != null && height != null && typeof children === 'function') {\n return children({ width, height });\n }\n return null;\n };\n\n render() {\n return (\n <React.Fragment>\n <div\n key=\"resize-detector\"\n style={styles}\n ref={el => {\n this.el = el;\n }}\n />\n {this.renderChildren()}\n </React.Fragment>\n );\n }\n}\n\nSizeAwareWrapperDeprecated.propTypes = {\n children: T.any, // eslint-disable-line react/forbid-prop-types\n};\n\nSizeAwareWrapperDeprecated.defaultProps = {\n children: null,\n};\n\nexport default SizeAwareWrapperDeprecated;\n", "\nimport * as defaultImport from \"react\";\nexport * from \"react\";\nexport default ('default' in defaultImport ? defaultImport.default : defaultImport);\n", "\nimport * as defaultImport from \"prop-types\";\nexport * from \"prop-types\";\nexport default ('default' in defaultImport ? defaultImport.default : defaultImport);\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA;AAAA;AAAA;AAAA;AACA,oBAA+B;AAC/B,0BAAc;AACd,IAAO,gBAAS,aAAa,gBAA8B,wBAAU;;;ACHrE;AAAA;AAAA;AAAA;AACA,IAAAA,iBAA+B;AAC/B,+BAAc;AACd,IAAO,qBAAS,aAAaA,iBAA8B,yBAAUA;;;AFArE,IAAM,SAAS;AAAA,EACX,UAAU;AAAA,EACV,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,YAAY;AAAA,EACZ,SAAS;AACb;AAEA,IAAM,6BAAN,cAAyC,4BAAc;AAAA,EACnD,YAAY,OAAO;AACf,UAAM,KAAK;AA0Bf,sCAAa,MAAM;AAEf,YAAM,gBAAgB,KAAK,MAAM,KAAK,GAAG;AACzC,aAAO;AAAA,IACX;AAYA,wCAAe,aAAW;AACtB,cAAQ,QAAQ,WAAS;AACrB,cAAM,EAAE,OAAO,OAAO,IAAI,MAAM;AAEhC,aAAK,mBAAmB,OAAO,sBAAsB,MAAM;AACvD,eAAK,SAAS,EAAE,OAAO,OAAO,CAAC;AAAA,QACnC,CAAC;AAAA,MACL,CAAC;AAAA,IACL;AAEA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