@splunk/react-ui 4.38.0 → 4.40.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 (172) hide show
  1. package/Accordion.js +131 -153
  2. package/Anchor.js +50 -58
  3. package/Animation.js +64 -59
  4. package/AnimationToggle.js +59 -61
  5. package/Box.js +59 -67
  6. package/Breadcrumbs.js +113 -127
  7. package/Button.js +151 -169
  8. package/ButtonGroup.js +41 -49
  9. package/ButtonSimple.js +264 -295
  10. package/CHANGELOG.md +49 -0
  11. package/Calendar.js +353 -414
  12. package/Card.js +186 -244
  13. package/CardLayout.js +86 -83
  14. package/Chip.js +136 -146
  15. package/Clickable.js +180 -198
  16. package/CloseButton.js +52 -60
  17. package/Code.js +24 -31
  18. package/CollapsiblePanel.js +172 -202
  19. package/Color.js +371 -412
  20. package/ColumnLayout.js +72 -96
  21. package/ComboBox.js +266 -303
  22. package/Concertina.js +406 -454
  23. package/ControlGroup.js +178 -210
  24. package/Date.js +116 -131
  25. package/DefinitionList.js +125 -149
  26. package/Divider.js +81 -79
  27. package/Dropdown.js +226 -237
  28. package/DualListbox.js +150 -186
  29. package/EventListener.js +4 -1
  30. package/File.js +1032 -955
  31. package/FormRows.js +281 -334
  32. package/Heading.js +27 -35
  33. package/Image.js +101 -116
  34. package/JSONTree.js +301 -344
  35. package/Layer.js +118 -126
  36. package/Link.js +141 -159
  37. package/List.js +61 -77
  38. package/MIGRATION.mdx +123 -38
  39. package/Markdown.js +288 -347
  40. package/Menu.js +506 -532
  41. package/Message.js +197 -207
  42. package/MessageBar.js +58 -66
  43. package/Modal.js +241 -290
  44. package/ModalLayer.js +130 -148
  45. package/Monogram.js +138 -138
  46. package/Multiselect.js +3137 -3433
  47. package/Number.js +164 -178
  48. package/Paginator.js +296 -335
  49. package/Paragraph.js +24 -32
  50. package/Popover.js +450 -442
  51. package/Progress.js +65 -75
  52. package/RadioBar.js +301 -303
  53. package/RadioList.js +77 -119
  54. package/Resize.js +105 -127
  55. package/ResultsMenu.js +373 -385
  56. package/ScreenReaderContent.js +50 -58
  57. package/Scroll.js +209 -244
  58. package/Search.js +379 -391
  59. package/Select.js +2085 -2345
  60. package/SidePanel.js +122 -142
  61. package/Slider.js +132 -145
  62. package/SlidingPanels.js +238 -270
  63. package/SplitButton.d.ts +2 -0
  64. package/SplitButton.js +222 -245
  65. package/StaticContent.js +68 -76
  66. package/StepBar.js +206 -205
  67. package/Switch.js +176 -205
  68. package/TabBar.js +235 -268
  69. package/TabLayout.js +122 -141
  70. package/Table.js +2103 -2261
  71. package/Text.js +379 -493
  72. package/TextArea.js +411 -441
  73. package/Tooltip.js +116 -132
  74. package/TransitionOpen.js +160 -178
  75. package/Tree.js +268 -287
  76. package/Typography.js +48 -52
  77. package/WaitSpinner.js +61 -69
  78. package/cypress/support/commands.ts +9 -0
  79. package/cypress/support/index.d.ts +6 -0
  80. package/cypress/tsconfig.cypress.json +1 -0
  81. package/docker-compose.yml +0 -1
  82. package/package.json +15 -15
  83. package/types/src/Button/Button.d.ts +5 -1
  84. package/types/src/ButtonSimple/ButtonSimple.d.ts +2 -2
  85. package/types/src/Card/Card.d.ts +1 -0
  86. package/types/src/Card/Footer.d.ts +1 -0
  87. package/types/src/Chip/Chip.d.ts +3 -6
  88. package/types/src/CollapsiblePanel/CollapsiblePanel.d.ts +1 -1
  89. package/types/src/Color/Color.d.ts +2 -2
  90. package/types/src/Color/Palette.d.ts +4 -2
  91. package/types/src/ComboBox/ComboBox.d.ts +1 -1
  92. package/types/src/ComboBox/Option.d.ts +1 -1
  93. package/types/src/ControlGroup/ControlGroup.d.ts +1 -2
  94. package/types/src/Date/Date.d.ts +2 -2
  95. package/types/src/File/File.d.ts +2 -3
  96. package/types/src/File/Retry.d.ts +1 -2
  97. package/types/src/Menu/Item.d.ts +18 -5
  98. package/types/src/Menu/Menu.d.ts +3 -3
  99. package/types/src/Menu/docs/examples/Adornments.d.ts +2 -0
  100. package/types/src/Menu/docs/examples/SelectableWithAdornments.d.ts +2 -0
  101. package/types/src/ModalLayer/ModalLayer.d.ts +1 -1
  102. package/types/src/Multiselect/Compact.d.ts +1 -1
  103. package/types/src/Multiselect/Multiselect.d.ts +1 -1
  104. package/types/src/Multiselect/Normal.d.ts +1 -1
  105. package/types/src/Multiselect/Option.d.ts +2 -0
  106. package/types/src/Number/Number.d.ts +3 -3
  107. package/types/src/Popover/Popover.d.ts +3 -4
  108. package/types/src/RadioBar/RadioBar.d.ts +2 -2
  109. package/types/src/ResultsMenu/VirtualizedResultsMenu/VirtualizedResultsMenu.d.ts +1 -1
  110. package/types/src/ScrollContainerContext/ScrollContainerContext.d.ts +2 -2
  111. package/types/src/Search/Option.d.ts +9 -3
  112. package/types/src/Select/Option.d.ts +3 -1
  113. package/types/src/Select/OptionBase.d.ts +7 -5
  114. package/types/src/Select/Select.d.ts +4 -2
  115. package/types/src/Select/SelectAllOption.d.ts +4 -4
  116. package/types/src/Select/SelectBase.d.ts +104 -66
  117. package/types/src/Select/docs/examples/Appearance.d.ts +0 -2
  118. package/types/src/SidePanel/SidePanel.d.ts +1 -1
  119. package/types/src/Slider/Slider.d.ts +2 -2
  120. package/types/src/SlidingPanels/SlidingPanels.d.ts +1 -1
  121. package/types/src/StepBar/Step.d.ts +1 -2
  122. package/types/src/Switch/Switch.d.ts +0 -1
  123. package/types/src/TabBar/Tab.d.ts +1 -1
  124. package/types/src/TabBar/TabBar.d.ts +3 -1
  125. package/types/src/TabLayout/TabLayout.d.ts +2 -0
  126. package/types/src/Table/Cell.d.ts +0 -2
  127. package/types/src/Table/HeadDropdownCell.d.ts +2 -0
  128. package/types/src/Table/HeadInner.d.ts +5 -1
  129. package/types/src/Table/Table.d.ts +0 -1
  130. package/types/src/Table/docs/examples/StripeRows.d.ts +2 -0
  131. package/types/src/Text/IconOutlinedHide.d.ts +1 -2
  132. package/types/src/Text/IconOutlinedView.d.ts +1 -2
  133. package/types/src/Text/Text.d.ts +2 -2
  134. package/types/src/TextArea/TextArea.d.ts +2 -2
  135. package/types/src/Tooltip/Tooltip.d.ts +4 -4
  136. package/types/src/TransitionOpen/TransitionOpen.d.ts +1 -1
  137. package/types/src/WaitSpinner/WaitSpinner.d.ts +0 -1
  138. package/types/src/useControlled/index.d.ts +2 -0
  139. package/types/src/useControlled/useControlled.d.ts +21 -0
  140. package/types/src/useResizeObserver/index.d.ts +2 -0
  141. package/types/src/useResizeObserver/useResizeObserver.d.ts +12 -0
  142. package/useControlled.js +112 -0
  143. package/useForceUpdate.js +30 -32
  144. package/useKeyPress.d.ts +2 -0
  145. package/useKeyPress.js +1 -1
  146. package/useResizeObserver.d.ts +2 -0
  147. package/useResizeObserver.js +137 -0
  148. package/types/src/ButtonGroup/docs/examples/prisma/Basic.d.ts +0 -1
  149. package/types/src/Chip/docs/examples/Basic.d.ts +0 -2
  150. package/types/src/Chip/docs/examples/prisma/Appearance.d.ts +0 -2
  151. package/types/src/Color/docs/examples/prisma/Controlled.d.ts +0 -2
  152. package/types/src/Color/docs/examples/prisma/ThemeVariables.d.ts +0 -1
  153. package/types/src/Color/docs/examples/prisma/Uncontrolled.d.ts +0 -2
  154. package/types/src/Dropdown/docs/examples/prisma/Basic.d.ts +0 -2
  155. package/types/src/Dropdown/docs/examples/prisma/BasicMenu.d.ts +0 -2
  156. package/types/src/Dropdown/docs/examples/prisma/ControlledDropdown.d.ts +0 -2
  157. package/types/src/Dropdown/docs/examples/prisma/Dialog.d.ts +0 -2
  158. package/types/src/Dropdown/docs/examples/prisma/OtherToggles.d.ts +0 -2
  159. package/types/src/Dropdown/docs/examples/prisma/ScrollingMenu.d.ts +0 -2
  160. package/types/src/File/docs/examples/prisma/Disabled.d.ts +0 -12
  161. package/types/src/File/docs/examples/prisma/Error.d.ts +0 -1
  162. package/types/src/Menu/docs/examples/Icons.d.ts +0 -2
  163. package/types/src/Menu/docs/examples/SelectableWithIcons.d.ts +0 -2
  164. package/types/src/Message/docs/examples/prisma/Title.d.ts +0 -2
  165. package/types/src/TabBar/docs/examples/prisma/Context.d.ts +0 -2
  166. package/types/src/TabLayout/docs/examples/prisma/Context.d.ts +0 -2
  167. package/types/src/Table/docs/examples/prisma/Basic.d.ts +0 -2
  168. package/types/src/WaitSpinner/docs/examples/prisma/Basic.d.ts +0 -2
  169. /package/types/src/Color/docs/examples/{prisma/CustomizedPalette.d.ts → CustomizedPalette.d.ts} +0 -0
  170. /package/types/src/Color/docs/examples/{prisma/HideInput.d.ts → HideInput.d.ts} +0 -0
  171. /package/types/src/StepBar/docs/examples/{prisma/Error.d.ts → Error.d.ts} +0 -0
  172. /package/types/src/TabBar/docs/examples/{prisma/Disabled.d.ts → Disabled.d.ts} +0 -0
package/ModalLayer.js CHANGED
@@ -9,26 +9,26 @@
9
9
  /******/ (() => {
10
10
  /******/ // getDefaultExport function for compatibility with non-harmony modules
11
11
  /******/ e.n = t => {
12
- /******/ var n = t && t.__esModule ?
12
+ /******/ var r = t && t.__esModule ?
13
13
  /******/ () => t["default"]
14
14
  /******/ : () => t
15
15
  /******/;
16
- e.d(n, {
17
- a: n
16
+ e.d(r, {
17
+ a: r
18
18
  });
19
- /******/ return n;
19
+ /******/ return r;
20
20
  /******/ };
21
21
  /******/ })();
22
22
  /******/
23
23
  /******/ /* webpack/runtime/define property getters */
24
24
  /******/ (() => {
25
25
  /******/ // define getter functions for harmony exports
26
- /******/ e.d = (t, n) => {
27
- /******/ for (var r in n) {
28
- /******/ if (e.o(n, r) && !e.o(t, r)) {
29
- /******/ Object.defineProperty(t, r, {
26
+ /******/ e.d = (t, r) => {
27
+ /******/ for (var n in r) {
28
+ /******/ if (e.o(r, n) && !e.o(t, n)) {
29
+ /******/ Object.defineProperty(t, n, {
30
30
  enumerable: true,
31
- get: n[r]
31
+ get: r[n]
32
32
  });
33
33
  /******/ }
34
34
  /******/ }
@@ -61,11 +61,11 @@
61
61
  e.r(t);
62
62
  // EXPORTS
63
63
  e.d(t, {
64
- default: () => /* reexport */ E
64
+ default: () => /* reexport */ T
65
65
  });
66
66
  // CONCATENATED MODULE: external "react"
67
- const n = require("react");
68
- var r = e.n(n);
67
+ const r = require("react");
68
+ var n = e.n(r);
69
69
  // CONCATENATED MODULE: external "prop-types"
70
70
  const o = require("prop-types");
71
71
  var i = e.n(o);
@@ -76,154 +76,135 @@
76
76
  var l = e.n(c);
77
77
  // CONCATENATED MODULE: external "styled-components"
78
78
  const u = require("styled-components");
79
- var s = e.n(u);
79
+ var p = e.n(u);
80
80
  // CONCATENATED MODULE: external "react-spring"
81
- const f = require("react-spring");
81
+ const s = require("react-spring");
82
82
  // CONCATENATED MODULE: external "@splunk/themes"
83
- const p = require("@splunk/themes");
83
+ const f = require("@splunk/themes");
84
84
  // CONCATENATED MODULE: ./src/ModalLayer/ModalLayerStyles.ts
85
- var y = (0, u.css)([ "", ";position:fixed;top:0;right:0;bottom:0;left:0;" ], p.mixins.reset("block"));
86
- var d = s()(f.animated.div).withConfig({
85
+ var y = (0, u.css)([ "", ";position:fixed;top:0;right:0;bottom:0;left:0;" ], f.mixins.reset("block"));
86
+ var d = p()(s.animated.div).withConfig({
87
87
  displayName: "ModalLayerStyles__StyledClickAwayOverlay",
88
88
  componentId: "sc-1sa3n1j-0"
89
- })([ "", ";background-color:", ";z-index:", ";" ], y, p.variables.backgroundColorScrim, p.variables.zindexModalBackdrop);
89
+ })([ "", ";background-color:", ";z-index:", ";" ], y, f.variables.backgroundColorScrim, f.variables.zindexModalBackdrop);
90
90
  // CONCATENATED MODULE: ./src/ModalLayer/ModalLayer.tsx
91
91
  function v(e) {
92
92
  "@babel/helpers - typeof";
93
- if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
94
- v = function e(t) {
95
- return typeof t;
96
- };
97
- } else {
98
- v = function e(t) {
99
- return t && typeof Symbol === "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
100
- };
101
- }
102
- return v(e);
93
+ return v = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
94
+ return typeof e;
95
+ } : function(e) {
96
+ return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
97
+ }, v(e);
103
98
  }
104
99
  function b(e, t) {
105
- var n = Object.keys(e);
100
+ var r = Object.keys(e);
106
101
  if (Object.getOwnPropertySymbols) {
107
- var r = Object.getOwnPropertySymbols(e);
108
- if (t) r = r.filter((function(t) {
102
+ var n = Object.getOwnPropertySymbols(e);
103
+ t && (n = n.filter((function(t) {
109
104
  return Object.getOwnPropertyDescriptor(e, t).enumerable;
110
- }));
111
- n.push.apply(n, r);
105
+ }))), r.push.apply(r, n);
112
106
  }
113
- return n;
107
+ return r;
114
108
  }
115
109
  function m(e) {
116
110
  for (var t = 1; t < arguments.length; t++) {
117
- var n = arguments[t] != null ? arguments[t] : {};
118
- if (t % 2) {
119
- b(Object(n), true).forEach((function(t) {
120
- R(e, t, n[t]);
121
- }));
122
- } else if (Object.getOwnPropertyDescriptors) {
123
- Object.defineProperties(e, Object.getOwnPropertyDescriptors(n));
124
- } else {
125
- b(Object(n)).forEach((function(t) {
126
- Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
127
- }));
128
- }
111
+ var r = null != arguments[t] ? arguments[t] : {};
112
+ t % 2 ? b(Object(r), !0).forEach((function(t) {
113
+ E(e, t, r[t]);
114
+ })) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(r)) : b(Object(r)).forEach((function(t) {
115
+ Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(r, t));
116
+ }));
129
117
  }
130
118
  return e;
131
119
  }
132
120
  function O(e, t) {
133
- if (!(e instanceof t)) {
134
- throw new TypeError("Cannot call a class as a function");
135
- }
121
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function");
136
122
  }
137
123
  function h(e, t) {
138
- for (var n = 0; n < t.length; n++) {
139
- var r = t[n];
140
- r.enumerable = r.enumerable || false;
141
- r.configurable = true;
142
- if ("value" in r) r.writable = true;
143
- Object.defineProperty(e, r.key, r);
124
+ for (var r = 0; r < t.length; r++) {
125
+ var n = t[r];
126
+ n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0),
127
+ Object.defineProperty(e, q(n.key), n);
144
128
  }
145
129
  }
146
- function g(e, t, n) {
147
- if (t) h(e.prototype, t);
148
- if (n) h(e, n);
149
- return e;
130
+ function g(e, t, r) {
131
+ return t && h(e.prototype, t), r && h(e, r), Object.defineProperty(e, "prototype", {
132
+ writable: !1
133
+ }), e;
150
134
  }
151
135
  function w(e, t) {
152
- if (typeof t !== "function" && t !== null) {
153
- throw new TypeError("Super expression must either be null or a function");
154
- }
136
+ if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function");
155
137
  e.prototype = Object.create(t && t.prototype, {
156
138
  constructor: {
157
139
  value: e,
158
- writable: true,
159
- configurable: true
140
+ writable: !0,
141
+ configurable: !0
160
142
  }
161
- });
162
- if (t) j(e, t);
143
+ }), Object.defineProperty(e, "prototype", {
144
+ writable: !1
145
+ }), t && j(e, t);
163
146
  }
164
147
  function j(e, t) {
165
- j = Object.setPrototypeOf || function e(t, n) {
166
- t.__proto__ = n;
167
- return t;
168
- };
169
- return j(e, t);
148
+ return j = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(e, t) {
149
+ return e.__proto__ = t, e;
150
+ }, j(e, t);
170
151
  }
171
- function S(e) {
152
+ function P(e) {
172
153
  var t = A();
173
- return function n() {
174
- var r = _(e), o;
154
+ return function() {
155
+ var r, n = _(e);
175
156
  if (t) {
176
- var i = _(this).constructor;
177
- o = Reflect.construct(r, arguments, i);
178
- } else {
179
- o = r.apply(this, arguments);
180
- }
181
- return P(this, o);
157
+ var o = _(this).constructor;
158
+ r = Reflect.construct(n, arguments, o);
159
+ } else r = n.apply(this, arguments);
160
+ return S(this, r);
182
161
  };
183
162
  }
184
- function P(e, t) {
185
- if (t && (v(t) === "object" || typeof t === "function")) {
186
- return t;
187
- }
163
+ function S(e, t) {
164
+ if (t && ("object" == v(t) || "function" == typeof t)) return t;
165
+ if (void 0 !== t) throw new TypeError("Derived constructors may only return object or undefined");
188
166
  return k(e);
189
167
  }
190
168
  function k(e) {
191
- if (e === void 0) {
192
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
193
- }
169
+ if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
194
170
  return e;
195
171
  }
196
172
  function A() {
197
- if (typeof Reflect === "undefined" || !Reflect.construct) return false;
198
- if (Reflect.construct.sham) return false;
199
- if (typeof Proxy === "function") return true;
200
173
  try {
201
- Date.prototype.toString.call(Reflect.construct(Date, [], (function() {})));
202
- return true;
203
- } catch (e) {
204
- return false;
205
- }
174
+ var e = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], (function() {})));
175
+ } catch (e) {}
176
+ return (A = function t() {
177
+ return !!e;
178
+ })();
206
179
  }
207
180
  function _(e) {
208
- _ = Object.setPrototypeOf ? Object.getPrototypeOf : function e(t) {
209
- return t.__proto__ || Object.getPrototypeOf(t);
210
- };
211
- return _(e);
181
+ return _ = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(e) {
182
+ return e.__proto__ || Object.getPrototypeOf(e);
183
+ }, _(e);
212
184
  }
213
- function R(e, t, n) {
214
- if (t in e) {
215
- Object.defineProperty(e, t, {
216
- value: n,
217
- enumerable: true,
218
- configurable: true,
219
- writable: true
220
- });
221
- } else {
222
- e[t] = n;
185
+ function E(e, t, r) {
186
+ return (t = q(t)) in e ? Object.defineProperty(e, t, {
187
+ value: r,
188
+ enumerable: !0,
189
+ configurable: !0,
190
+ writable: !0
191
+ }) : e[t] = r, e;
192
+ }
193
+ function q(e) {
194
+ var t = M(e, "string");
195
+ return "symbol" == v(t) ? t : t + "";
196
+ }
197
+ function M(e, t) {
198
+ if ("object" != v(e) || !e) return e;
199
+ var r = e[Symbol.toPrimitive];
200
+ if (void 0 !== r) {
201
+ var n = r.call(e, t || "default");
202
+ if ("object" != v(n)) return n;
203
+ throw new TypeError("@@toPrimitive must return a primitive value.");
223
204
  }
224
- return e;
205
+ return ("string" === t ? String : Number)(e);
225
206
  }
226
- var q = {
207
+ var C = {
227
208
  childrenInAnimation: i().bool,
228
209
  getDefaultMotionStyle: i().func,
229
210
  getMotionStyle: i().func,
@@ -232,53 +213,64 @@
232
213
  renderModal: i().func.isRequired,
233
214
  scrim: i().oneOf([ "visible", "hidden", "interactive" ])
234
215
  };
235
- var M = {
216
+ var R = {
236
217
  childrenInAnimation: false,
237
218
  open: false,
238
219
  scrim: "interactive"
239
220
  };
240
- var C = function(e) {
241
- w(n, e);
242
- var t = S(n);
243
- function n(e) {
221
+ var D = function(e) {
222
+ w(r, e);
223
+ var t = P(r);
224
+ g(r, null, [ {
225
+ key: "getDerivedStateFromProps",
226
+ value: function e(t, r) {
227
+ if (t.open !== r.prevOpen) {
228
+ return {
229
+ animating: true,
230
+ prevOpen: t.open
231
+ };
232
+ }
233
+ return null;
234
+ }
235
+ } ]);
236
+ function r(e) {
244
237
  var o;
245
- O(this, n);
238
+ O(this, r);
246
239
  o = t.call(this, e);
247
- R(k(o), "allowAnimationUpdates", true);
248
- R(k(o), "handleClickAway", (function(e) {
249
- var t, n;
250
- (t = (n = o.props).onRequestClose) === null || t === void 0 ? void 0 : t.call(n, {
240
+ E(k(o), "allowAnimationUpdates", true);
241
+ E(k(o), "handleClickAway", (function(e) {
242
+ var t, r;
243
+ (t = (r = o.props).onRequestClose) === null || t === void 0 ? void 0 : t.call(r, {
251
244
  reason: "clickAway",
252
245
  event: e
253
246
  });
254
247
  }));
255
- R(k(o), "handleAnimationEnd", (function() {
248
+ E(k(o), "handleAnimationEnd", (function() {
256
249
  if (o.allowAnimationUpdates) {
257
250
  o.setState({
258
251
  animating: false
259
252
  });
260
253
  }
261
254
  }));
262
- R(k(o), "renderLayer", (function() {
263
- var e = o.props, t = e.getDefaultMotionStyle, n = e.getMotionStyle, i = e.renderModal, c = e.scrim;
255
+ E(k(o), "renderLayer", (function() {
256
+ var e = o.props, t = e.getDefaultMotionStyle, r = e.getMotionStyle, i = e.renderModal, c = e.scrim;
264
257
  var l = o.props.open || o.state.animating;
265
258
  var u = l && c !== "hidden";
266
259
 
267
- return r().createElement(a.Spring, {
260
+ return n().createElement(a.Spring, {
268
261
  from: m(m({}, t === null || t === void 0 ? void 0 : t()), {}, {
269
262
  overlayOpacity: 0,
270
263
  opacity: 0
271
264
  }),
272
- to: m(m({}, n === null || n === void 0 ? void 0 : n()), {}, {
265
+ to: m(m({}, r === null || r === void 0 ? void 0 : r()), {}, {
273
266
  overlayOpacity: o.props.open ? 1 : 0,
274
267
  opacity: o.props.open ? 1 : 0
275
268
  }),
276
269
  onRest: o.handleAnimationEnd
277
270
  }, (function(e) {
278
271
 
279
- return r().createElement("div", null,
280
- /* eslint-disable-next-line @typescript-eslint/no-explicit-any */
281
- i(e), u && r().createElement(d, {
272
+ return n().createElement("div", null, /* eslint-disable-next-line @typescript-eslint/no-explicit-any */
273
+ i(e), u && n().createElement(d, {
282
274
  "data-test": "modal-overlay",
283
275
  onMouseDown: c === "interactive" ? o.handleClickAway : undefined,
284
276
  key: "clickAway",
@@ -295,38 +287,28 @@
295
287
  };
296
288
  return o;
297
289
  }
298
- g(n, [ {
290
+ g(r, [ {
299
291
  key: "componentWillUnmount",
300
292
  value: function e() {
301
293
  this.allowAnimationUpdates = false;
302
294
  }
303
- }, {
295
+ /* eslint-disable jsx-a11y/no-static-element-interactions */ }, {
304
296
  key: "render",
305
- /* eslint-enable jsx-a11y/no-static-element-interactions */
306
- value: function e() {
297
+ /* eslint-enable jsx-a11y/no-static-element-interactions */ value: function e() {
307
298
  var t = this.props.open || this.state.animating || this.props.childrenInAnimation;
308
299
 
309
- return r().createElement(l(), {
300
+ return n().createElement(l(), {
310
301
  open: t,
311
302
  closeReasons: [ "escapeKey" ],
312
303
  onRequestClose: this.props.onRequestClose
313
304
  }, t && this.renderLayer());
314
305
  }
315
306
  } ]);
316
- return n;
317
- }(n.Component);
318
- R(C, "propTypes", q);
319
- R(C, "defaultProps", M);
320
- R(C, "getDerivedStateFromProps", (function(e, t) {
321
- if (e.open !== t.prevOpen) {
322
- return {
323
- animating: true,
324
- prevOpen: e.open
325
- };
326
- }
327
- return null;
328
- }));
329
- /* harmony default export */ const E = C;
307
+ return r;
308
+ }(r.Component);
309
+ E(D, "propTypes", C);
310
+ E(D, "defaultProps", R);
311
+ /* harmony default export */ const T = D;
330
312
  // CONCATENATED MODULE: ./src/ModalLayer/index.ts
331
313
  module.exports = t;
332
314
  /******/})();