@splunk/react-ui 4.38.0 → 4.39.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 (136) 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 +28 -0
  11. package/Calendar.js +353 -414
  12. package/Card.js +183 -243
  13. package/CardLayout.js +86 -83
  14. package/Chip.js +104 -122
  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 +165 -194
  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 +92 -38
  39. package/Markdown.js +288 -347
  40. package/Menu.js +506 -532
  41. package/Message.js +173 -196
  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 +1589 -1902
  47. package/Number.js +159 -178
  48. package/Paginator.js +296 -335
  49. package/Paragraph.js +24 -32
  50. package/Popover.js +448 -441
  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 +1077 -1345
  60. package/SidePanel.js +122 -142
  61. package/Slider.js +132 -145
  62. package/SlidingPanels.js +238 -270
  63. package/SplitButton.js +222 -245
  64. package/StaticContent.js +68 -76
  65. package/StepBar.js +206 -205
  66. package/Switch.js +176 -205
  67. package/TabBar.js +222 -258
  68. package/TabLayout.js +114 -139
  69. package/Table.js +2017 -2180
  70. package/Text.js +379 -493
  71. package/TextArea.js +411 -441
  72. package/Tooltip.js +116 -132
  73. package/TransitionOpen.js +160 -178
  74. package/Tree.js +268 -287
  75. package/Typography.js +48 -52
  76. package/WaitSpinner.js +60 -68
  77. package/cypress/support/commands.ts +9 -0
  78. package/cypress/support/index.d.ts +6 -0
  79. package/cypress/tsconfig.cypress.json +1 -0
  80. package/docker-compose.yml +0 -1
  81. package/package.json +14 -14
  82. package/types/src/Button/Button.d.ts +5 -1
  83. package/types/src/ButtonSimple/ButtonSimple.d.ts +2 -2
  84. package/types/src/CollapsiblePanel/CollapsiblePanel.d.ts +1 -1
  85. package/types/src/Color/Color.d.ts +2 -2
  86. package/types/src/Color/Palette.d.ts +4 -2
  87. package/types/src/ComboBox/Option.d.ts +1 -1
  88. package/types/src/ControlGroup/ControlGroup.d.ts +1 -2
  89. package/types/src/Date/Date.d.ts +2 -2
  90. package/types/src/File/File.d.ts +2 -3
  91. package/types/src/File/Retry.d.ts +1 -2
  92. package/types/src/Menu/Item.d.ts +18 -5
  93. package/types/src/Menu/Menu.d.ts +3 -3
  94. package/types/src/Menu/docs/examples/Adornments.d.ts +2 -0
  95. package/types/src/Menu/docs/examples/SelectableWithAdornments.d.ts +2 -0
  96. package/types/src/ModalLayer/ModalLayer.d.ts +1 -1
  97. package/types/src/Multiselect/Option.d.ts +2 -0
  98. package/types/src/Number/Number.d.ts +3 -3
  99. package/types/src/Popover/Popover.d.ts +3 -4
  100. package/types/src/RadioBar/RadioBar.d.ts +2 -2
  101. package/types/src/ResultsMenu/VirtualizedResultsMenu/VirtualizedResultsMenu.d.ts +1 -1
  102. package/types/src/ScrollContainerContext/ScrollContainerContext.d.ts +2 -2
  103. package/types/src/Search/Option.d.ts +9 -3
  104. package/types/src/Select/Option.d.ts +3 -1
  105. package/types/src/Select/OptionBase.d.ts +7 -5
  106. package/types/src/Select/Select.d.ts +1 -1
  107. package/types/src/Select/SelectAllOption.d.ts +4 -4
  108. package/types/src/SidePanel/SidePanel.d.ts +1 -1
  109. package/types/src/Slider/Slider.d.ts +2 -2
  110. package/types/src/SlidingPanels/SlidingPanels.d.ts +1 -1
  111. package/types/src/StepBar/Step.d.ts +1 -2
  112. package/types/src/Switch/Switch.d.ts +0 -1
  113. package/types/src/TabBar/Tab.d.ts +1 -1
  114. package/types/src/TabBar/TabBar.d.ts +3 -1
  115. package/types/src/TabLayout/TabLayout.d.ts +2 -0
  116. package/types/src/Table/HeadDropdownCell.d.ts +2 -0
  117. package/types/src/Table/Table.d.ts +0 -1
  118. package/types/src/Table/docs/examples/StripeRows.d.ts +2 -0
  119. package/types/src/Text/IconOutlinedHide.d.ts +1 -2
  120. package/types/src/Text/IconOutlinedView.d.ts +1 -2
  121. package/types/src/Text/Text.d.ts +2 -2
  122. package/types/src/TextArea/TextArea.d.ts +2 -2
  123. package/types/src/Tooltip/Tooltip.d.ts +4 -4
  124. package/types/src/TransitionOpen/TransitionOpen.d.ts +1 -1
  125. package/useForceUpdate.js +30 -32
  126. package/useKeyPress.js +1 -1
  127. package/types/src/ButtonGroup/docs/examples/prisma/Basic.d.ts +0 -1
  128. package/types/src/File/docs/examples/prisma/Error.d.ts +0 -1
  129. package/types/src/Menu/docs/examples/Icons.d.ts +0 -2
  130. package/types/src/Menu/docs/examples/SelectableWithIcons.d.ts +0 -2
  131. package/types/src/TabBar/docs/examples/prisma/Context.d.ts +0 -2
  132. package/types/src/TabLayout/docs/examples/prisma/Context.d.ts +0 -2
  133. package/types/src/Table/docs/examples/prisma/Basic.d.ts +0 -2
  134. /package/types/src/Message/docs/examples/{prisma/Title.d.ts → Title.d.ts} +0 -0
  135. /package/types/src/StepBar/docs/examples/{prisma/Error.d.ts → Error.d.ts} +0 -0
  136. /package/types/src/TabBar/docs/examples/{prisma/Disabled.d.ts → Disabled.d.ts} +0 -0
package/TransitionOpen.js CHANGED
@@ -61,213 +61,191 @@
61
61
  e.r(t);
62
62
  // EXPORTS
63
63
  e.d(t, {
64
- default: () => /* reexport */ W
64
+ default: () => /* reexport */ A
65
65
  });
66
66
  // CONCATENATED MODULE: external "react"
67
67
  const n = require("react");
68
68
  var r = e.n(n);
69
69
  // CONCATENATED MODULE: external "prop-types"
70
70
  const o = require("prop-types");
71
- var a = e.n(o);
71
+ var i = e.n(o);
72
72
  // CONCATENATED MODULE: external "lodash/keys"
73
- const i = require("lodash/keys");
74
- var s = e.n(i);
73
+ const a = require("lodash/keys");
74
+ var s = e.n(a);
75
75
  // CONCATENATED MODULE: external "lodash/omit"
76
76
  const l = require("lodash/omit");
77
77
  var u = e.n(l);
78
78
  // CONCATENATED MODULE: external "@splunk/react-ui/Animation"
79
79
  const c = require("@splunk/react-ui/Animation");
80
80
  // CONCATENATED MODULE: external "@splunk/ui-utils/focus"
81
- const f = require("@splunk/ui-utils/focus");
81
+ const p = require("@splunk/ui-utils/focus");
82
82
  // CONCATENATED MODULE: external "@splunk/ui-utils/style"
83
- const p = require("@splunk/ui-utils/style");
83
+ const f = require("@splunk/ui-utils/style");
84
84
  // CONCATENATED MODULE: external "react-spring"
85
85
  const d = require("react-spring");
86
86
  // CONCATENATED MODULE: external "styled-components"
87
87
  const m = require("styled-components");
88
88
  var y = e.n(m);
89
89
  // CONCATENATED MODULE: external "@splunk/themes"
90
- const h = require("@splunk/themes");
90
+ const v = require("@splunk/themes");
91
91
  // CONCATENATED MODULE: ./src/TransitionOpen/TransitionOpenStyles.ts
92
- var v = y()(d.animated.div).withConfig({
92
+ var b = y()(d.animated.div).withConfig({
93
93
  displayName: "TransitionOpenStyles__Styled",
94
94
  componentId: "sc-1x58s0g-0"
95
- })([ "", ";", ";" ], h.mixins.reset("block"), (function(e) {
95
+ })([ "", ";", ";" ], v.mixins.reset("block"), (function(e) {
96
96
  var t = e.$hideOverflow;
97
97
  return t && (0, m.css)([ "overflow:hidden;" ]);
98
98
  }));
99
- var b = y()(d.animated.div).withConfig({
99
+ var h = y()(d.animated.div).withConfig({
100
100
  displayName: "TransitionOpenStyles__StyledInner",
101
101
  componentId: "sc-1x58s0g-1"
102
- })([ "", ";", ";width:100%;" ], h.mixins.reset("table"), h.mixins.clearfix());
102
+ })([ "", ";", ";width:100%;" ], v.mixins.reset("table"), v.mixins.clearfix());
103
103
  // CONCATENATED MODULE: ./src/TransitionOpen/TransitionOpen.tsx
104
104
  function g(e) {
105
105
  "@babel/helpers - typeof";
106
- if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
107
- g = function e(t) {
108
- return typeof t;
109
- };
110
- } else {
111
- g = function e(t) {
112
- return t && typeof Symbol === "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
113
- };
114
- }
115
- return g(e);
106
+ return g = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
107
+ return typeof e;
108
+ } : function(e) {
109
+ return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
110
+ }, g(e);
116
111
  }
117
112
  function O() {
118
- O = Object.assign || function(e) {
113
+ return O = Object.assign ? Object.assign.bind() : function(e) {
119
114
  for (var t = 1; t < arguments.length; t++) {
120
115
  var n = arguments[t];
121
116
  for (var r in n) {
122
- if (Object.prototype.hasOwnProperty.call(n, r)) {
123
- e[r] = n[r];
124
- }
117
+ ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
125
118
  }
126
119
  }
127
120
  return e;
128
- };
129
- return O.apply(this, arguments);
121
+ }, O.apply(null, arguments);
130
122
  }
131
123
  function w(e, t) {
132
124
  var n = Object.keys(e);
133
125
  if (Object.getOwnPropertySymbols) {
134
126
  var r = Object.getOwnPropertySymbols(e);
135
- if (t) r = r.filter((function(t) {
127
+ t && (r = r.filter((function(t) {
136
128
  return Object.getOwnPropertyDescriptor(e, t).enumerable;
137
- }));
138
- n.push.apply(n, r);
129
+ }))), n.push.apply(n, r);
139
130
  }
140
131
  return n;
141
132
  }
142
- function S(e) {
133
+ function j(e) {
143
134
  for (var t = 1; t < arguments.length; t++) {
144
- var n = arguments[t] != null ? arguments[t] : {};
145
- if (t % 2) {
146
- w(Object(n), true).forEach((function(t) {
147
- R(e, t, n[t]);
148
- }));
149
- } else if (Object.getOwnPropertyDescriptors) {
150
- Object.defineProperties(e, Object.getOwnPropertyDescriptors(n));
151
- } else {
152
- w(Object(n)).forEach((function(t) {
153
- Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
154
- }));
155
- }
135
+ var n = null != arguments[t] ? arguments[t] : {};
136
+ t % 2 ? w(Object(n), !0).forEach((function(t) {
137
+ R(e, t, n[t]);
138
+ })) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : w(Object(n)).forEach((function(t) {
139
+ Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
140
+ }));
156
141
  }
157
142
  return e;
158
143
  }
159
- function j(e, t) {
160
- if (!(e instanceof t)) {
161
- throw new TypeError("Cannot call a class as a function");
162
- }
144
+ function S(e, t) {
145
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function");
163
146
  }
164
- function F(e, t) {
147
+ function P(e, t) {
165
148
  for (var n = 0; n < t.length; n++) {
166
149
  var r = t[n];
167
- r.enumerable = r.enumerable || false;
168
- r.configurable = true;
169
- if ("value" in r) r.writable = true;
170
- Object.defineProperty(e, r.key, r);
150
+ r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0),
151
+ Object.defineProperty(e, q(r.key), r);
171
152
  }
172
153
  }
173
- function x(e, t, n) {
174
- if (t) F(e.prototype, t);
175
- if (n) F(e, n);
176
- return e;
154
+ function F(e, t, n) {
155
+ return t && P(e.prototype, t), n && P(e, n), Object.defineProperty(e, "prototype", {
156
+ writable: !1
157
+ }), e;
177
158
  }
178
- function P(e, t) {
179
- if (typeof t !== "function" && t !== null) {
180
- throw new TypeError("Super expression must either be null or a function");
181
- }
159
+ function T(e, t) {
160
+ if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function");
182
161
  e.prototype = Object.create(t && t.prototype, {
183
162
  constructor: {
184
163
  value: e,
185
- writable: true,
186
- configurable: true
164
+ writable: !0,
165
+ configurable: !0
187
166
  }
188
- });
189
- if (t) T(e, t);
167
+ }), Object.defineProperty(e, "prototype", {
168
+ writable: !1
169
+ }), t && x(e, t);
190
170
  }
191
- function T(e, t) {
192
- T = Object.setPrototypeOf || function e(t, n) {
193
- t.__proto__ = n;
194
- return t;
195
- };
196
- return T(e, t);
171
+ function x(e, t) {
172
+ return x = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(e, t) {
173
+ return e.__proto__ = t, e;
174
+ }, x(e, t);
197
175
  }
198
176
  function k(e) {
199
177
  var t = _();
200
- return function n() {
201
- var r = N(e), o;
178
+ return function() {
179
+ var n, r = N(e);
202
180
  if (t) {
203
- var a = N(this).constructor;
204
- o = Reflect.construct(r, arguments, a);
205
- } else {
206
- o = r.apply(this, arguments);
207
- }
208
- return E(this, o);
181
+ var o = N(this).constructor;
182
+ n = Reflect.construct(r, arguments, o);
183
+ } else n = r.apply(this, arguments);
184
+ return E(this, n);
209
185
  };
210
186
  }
211
187
  function E(e, t) {
212
- if (t && (g(t) === "object" || typeof t === "function")) {
213
- return t;
214
- }
188
+ if (t && ("object" == g(t) || "function" == typeof t)) return t;
189
+ if (void 0 !== t) throw new TypeError("Derived constructors may only return object or undefined");
215
190
  return C(e);
216
191
  }
217
192
  function C(e) {
218
- if (e === void 0) {
219
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
220
- }
193
+ if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
221
194
  return e;
222
195
  }
223
196
  function _() {
224
- if (typeof Reflect === "undefined" || !Reflect.construct) return false;
225
- if (Reflect.construct.sham) return false;
226
- if (typeof Proxy === "function") return true;
227
197
  try {
228
- Date.prototype.toString.call(Reflect.construct(Date, [], (function() {})));
229
- return true;
230
- } catch (e) {
231
- return false;
232
- }
198
+ var e = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], (function() {})));
199
+ } catch (e) {}
200
+ return (_ = function t() {
201
+ return !!e;
202
+ })();
233
203
  }
234
204
  function N(e) {
235
- N = Object.setPrototypeOf ? Object.getPrototypeOf : function e(t) {
236
- return t.__proto__ || Object.getPrototypeOf(t);
237
- };
238
- return N(e);
205
+ return N = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(e) {
206
+ return e.__proto__ || Object.getPrototypeOf(e);
207
+ }, N(e);
239
208
  }
240
209
  function R(e, t, n) {
241
- if (t in e) {
242
- Object.defineProperty(e, t, {
243
- value: n,
244
- enumerable: true,
245
- configurable: true,
246
- writable: true
247
- });
248
- } else {
249
- e[t] = n;
210
+ return (t = q(t)) in e ? Object.defineProperty(e, t, {
211
+ value: n,
212
+ enumerable: !0,
213
+ configurable: !0,
214
+ writable: !0
215
+ }) : e[t] = n, e;
216
+ }
217
+ function q(e) {
218
+ var t = D(e, "string");
219
+ return "symbol" == g(t) ? t : t + "";
220
+ }
221
+ function D(e, t) {
222
+ if ("object" != g(e) || !e) return e;
223
+ var n = e[Symbol.toPrimitive];
224
+ if (void 0 !== n) {
225
+ var r = n.call(e, t || "default");
226
+ if ("object" != g(r)) return r;
227
+ throw new TypeError("@@toPrimitive must return a primitive value.");
250
228
  }
251
- return e;
229
+ return ("string" === t ? String : Number)(e);
252
230
  }
253
- var q = {
254
- animation: a().oneOf([ "slideFromTop", "slideFromRight", "slideFromBottom", "slideFromLeft", "expandHeight", "expandWidth", "none" ]),
255
- animateOnMount: a().bool,
256
- children: a().node,
257
- className: a().string,
258
- id: a().string,
259
- innerClassName: a().string,
260
- innerStyle: a().object,
261
- onAnimationEnd: a().func,
262
- open: a().bool,
263
- outerClassName: a().string,
264
- outerId: a().string,
265
- outerStyle: a().object,
266
- renderChildrenWhenCollapsed: a().bool,
267
- retainFocus: a().bool,
268
- takeFocus: a().bool
231
+ var M = {
232
+ animation: i().oneOf([ "slideFromTop", "slideFromRight", "slideFromBottom", "slideFromLeft", "expandHeight", "expandWidth", "none" ]),
233
+ animateOnMount: i().bool,
234
+ children: i().node,
235
+ className: i().string,
236
+ id: i().string,
237
+ innerClassName: i().string,
238
+ innerStyle: i().object,
239
+ onAnimationEnd: i().func,
240
+ open: i().bool,
241
+ outerClassName: i().string,
242
+ outerId: i().string,
243
+ outerStyle: i().object,
244
+ renderChildrenWhenCollapsed: i().bool,
245
+ retainFocus: i().bool,
246
+ takeFocus: i().bool
269
247
  };
270
- var D = {
248
+ var W = {
271
249
  animation: "expandHeight",
272
250
  animateOnMount: false,
273
251
  innerStyle: {},
@@ -277,13 +255,25 @@
277
255
  retainFocus: false,
278
256
  takeFocus: false
279
257
  };
280
- var M = function(e) {
281
- P(n, e);
258
+ var I = function(e) {
259
+ T(n, e);
282
260
  var t = k(n);
283
- // @docs-props-type TransitionOpenPropsBase
284
- function n(e) {
261
+ F(n, null, [ {
262
+ key: "getDerivedStateFromProps",
263
+ // @docs-props-type TransitionOpenPropsBase
264
+ value: function e(t, n) {
265
+ if (t.open !== n.prevOpen) {
266
+ return {
267
+ animating: true,
268
+ prevOpen: t.open
269
+ };
270
+ }
271
+ return null;
272
+ }
273
+ } ]);
274
+ function n(e) {
285
275
  var o;
286
- j(this, n);
276
+ S(this, n);
287
277
  o = t.call(this, e);
288
278
  R(C(o), "allowAnimationUpdates", true);
289
279
  R(C(o), "getValue", (function(e) {
@@ -291,7 +281,7 @@
291
281
  var n = 0;
292
282
  if (e) {
293
283
  if (o.props.takeFocus) {
294
- (0, f.takeFocus)(e, "container");
284
+ (0, p.takeFocus)(e, "container");
295
285
  }
296
286
  switch (t) {
297
287
  case "slideFromTop":
@@ -331,41 +321,41 @@
331
321
  }));
332
322
  R(C(o), "handleTab", (function(e) {
333
323
  if (o.state.innerEl) {
334
- (0, f.handleTab)(o.state.innerEl, e);
324
+ (0, p.handleTab)(o.state.innerEl, e);
335
325
  }
336
326
  }));
337
327
  R(C(o), "internalRender", (function(e) {
338
- var t = e.value, a = e.transform;
339
- var i = o.props, l = i.animation, c = i.className, f = i.children, d = i.id, m = i.innerClassName, y = i.innerStyle, h = i.open, g = i.outerClassName, w = i.outerId, j = i.outerStyle, F = i.renderChildrenWhenCollapsed;
340
- var x = o.state.animating;
341
- var P;
342
- if (x) {
328
+ var t = e.value, i = e.transform;
329
+ var a = o.props, l = a.animation, c = a.className, p = a.children, d = a.id, m = a.innerClassName, y = a.innerStyle, v = a.open, g = a.outerClassName, w = a.outerId, S = a.outerStyle, P = a.renderChildrenWhenCollapsed;
330
+ var F = o.state.animating;
331
+ var T;
332
+ if (F) {
343
333
  switch (l) {
344
334
  case "slideFromTop":
345
335
  case "slideFromBottom":
346
336
  case "expandHeight":
347
337
  case "none":
348
- P = "height";
338
+ T = "height";
349
339
  break;
350
340
 
351
341
  case "slideFromLeft":
352
342
  case "slideFromRight":
353
343
  case "expandWidth":
354
- P = "width";
344
+ T = "width";
355
345
  break;
356
346
 
357
347
  default:
358
348
  // Intentionally left empty.
359
349
  }
360
350
  }
361
- if (!h && !x && F) {
351
+ if (!v && !F && P) {
362
352
 
363
- return r().createElement(v, {
353
+ return r().createElement(b, {
364
354
  $hideOverflow: false,
365
- className: (0, p.toClassName)(c, g),
366
- style: S(S({}, j), P && R({}, P, t)),
355
+ className: (0, f.toClassName)(c, g),
356
+ style: j(j({}, S), T && R({}, T, t)),
367
357
  id: w
368
- }, r().createElement(b, O({
358
+ }, r().createElement(h, O({
369
359
  "data-test": "transition-open"
370
360
  }, u()(o.props, s()(n.propTypes)), {
371
361
  ref: o.handleMount,
@@ -373,19 +363,19 @@
373
363
  className: m,
374
364
  id: d,
375
365
  onKeyDown: o.props.retainFocus ? o.handleTab : undefined,
376
- style: S(S({}, y), {}, {
377
- transform: a,
366
+ style: j(j({}, y), {}, {
367
+ transform: i,
378
368
  display: "none"
379
369
  })
380
- }), f));
370
+ }), p));
381
371
  }
382
372
  /* eslint-disable jsx-a11y/no-static-element-interactions */
383
- return r().createElement(v, {
384
- $hideOverflow: !h || x,
385
- className: (0, p.toClassName)(c, g),
386
- style: S(S({}, j), P && R({}, P, t)),
373
+ return r().createElement(b, {
374
+ $hideOverflow: !v || F,
375
+ className: (0, f.toClassName)(c, g),
376
+ style: j(j({}, S), T && R({}, T, t)),
387
377
  id: w
388
- }, (h || x) && r().createElement(b, O({
378
+ }, (v || F) && r().createElement(h, O({
389
379
  "data-test": "transition-open"
390
380
  }, u()(o.props, s()(n.propTypes)), {
391
381
  ref: o.handleMount,
@@ -393,18 +383,18 @@
393
383
  className: m,
394
384
  id: d,
395
385
  onKeyDown: o.props.retainFocus ? o.handleTab : undefined,
396
- style: S(S({}, y), {}, {
397
- transform: a
386
+ style: j(j({}, y), {}, {
387
+ transform: i
398
388
  })
399
- }), f));
389
+ }), p));
400
390
  }));
401
391
  R(C(o), "getSpringTransition", (function() {
402
392
  var e = o.props, t = e.open, n = e.animation;
403
393
  var r = o.state.value;
404
- var a = {
394
+ var i = {
405
395
  value: t ? r : 0
406
396
  };
407
- var i = {
397
+ var a = {
408
398
  value: t ? 0 : r
409
399
  };
410
400
  var s = {
@@ -414,34 +404,34 @@
414
404
  // Expansion doesn't require a valid value; the subsequent render animates it.
415
405
  if (n === "expandWidth" || n === "expandHeight" || n === "none") {
416
406
  return {
417
- to: a,
407
+ to: i,
418
408
  config: s
419
409
  };
420
410
  }
421
- // Slide transitions require a valid value, render without transition first.
411
+ // Slide transitions require a valid value, render without transition first.
422
412
  if (!r) {
423
413
  return null;
424
414
  }
425
415
  if (n !== "slideFromTop" && n !== "slideFromLeft") {
426
416
  // Return the standard transition if not using a transform.
427
417
  return {
428
- to: a,
429
- from: i,
418
+ to: i,
419
+ from: a,
430
420
  config: s
431
421
  };
432
422
  }
433
- // The top and left directions require an additional transform of their inner content to match the outer dimension animation.
423
+ // The top and left directions require an additional transform of their inner content to match the outer dimension animation.
434
424
  // This is needed to achieve a clipping effect from the outer div, rather than the consumer providing their own.
435
425
  var l = n === "slideFromTop" ? "Y" : "X";
436
426
  var u = "translate".concat(l, "(").concat(t ? 0 : -r, "px)");
437
427
  var c = "translate".concat(l, "(").concat(t ? -r : 0, "px)");
438
428
  return {
439
- to: S({
429
+ to: j({
440
430
  transform: u
441
- }, a),
442
- from: S({
431
+ }, i),
432
+ from: j({
443
433
  transform: c
444
- }, i)
434
+ }, a)
445
435
  };
446
436
  }));
447
437
  o.state = {
@@ -451,7 +441,7 @@
451
441
  };
452
442
  return o;
453
443
  }
454
- x(n, [ {
444
+ F(n, [ {
455
445
  key: "componentDidUpdate",
456
446
  value: function e() {
457
447
  var t = this.getValue(this.state.innerEl);
@@ -475,24 +465,16 @@
475
465
  return r().createElement(c.Spring, O({}, this.getSpringTransition(), {
476
466
  immediate: t === "none",
477
467
  onRest: this.handleRest
478
- }), // eslint-disable-next-line @typescript-eslint/no-explicit-any
468
+ }),
469
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
479
470
  this.internalRender);
480
471
  }
481
472
  } ]);
482
473
  return n;
483
474
  }(n.Component);
484
- R(M, "propTypes", q);
485
- R(M, "defaultProps", D);
486
- R(M, "getDerivedStateFromProps", (function(e, t) {
487
- if (e.open !== t.prevOpen) {
488
- return {
489
- animating: true,
490
- prevOpen: e.open
491
- };
492
- }
493
- return null;
494
- }));
495
- /* harmony default export */ const W = M;
475
+ R(I, "propTypes", M);
476
+ R(I, "defaultProps", W);
477
+ /* harmony default export */ const A = I;
496
478
  // CONCATENATED MODULE: ./src/TransitionOpen/index.ts
497
479
  module.exports = t;
498
480
  /******/})();