@splunk/react-ui 5.0.0-beta.4 → 5.0.0-rc.1

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 (88) hide show
  1. package/Button.js +3 -1
  2. package/ButtonSimple.js +92 -168
  3. package/CHANGELOG.md +4 -1
  4. package/CHANGELOG.v5.mdx +59 -0
  5. package/Card.js +29 -28
  6. package/Chip.js +171 -225
  7. package/Clickable.js +79 -76
  8. package/CollapsiblePanel.js +172 -164
  9. package/Color.js +584 -506
  10. package/ComboBox.js +1 -1
  11. package/ControlGroup.js +132 -127
  12. package/Date.js +163 -198
  13. package/Dropdown.js +97 -99
  14. package/DualListbox.js +439 -504
  15. package/File.js +449 -324
  16. package/FormRows.js +177 -175
  17. package/JSONTree.js +586 -617
  18. package/Layer.js +162 -97
  19. package/Link.js +20 -13
  20. package/MIGRATION.v5.mdx +98 -0
  21. package/Markdown.js +1 -1
  22. package/Menu.js +194 -195
  23. package/Message.js +119 -141
  24. package/MessageBar.js +109 -168
  25. package/ModalLayer.js +171 -217
  26. package/Multiselect.js +595 -602
  27. package/Number.js +103 -102
  28. package/Popover.js +195 -190
  29. package/Progress.js +68 -54
  30. package/RadioBar.js +146 -145
  31. package/RadioList.js +67 -65
  32. package/Resize.js +377 -265
  33. package/ResultsMenu.js +573 -663
  34. package/ScrollContainerContext.js +13 -9
  35. package/Search.js +50 -50
  36. package/Select.js +206 -199
  37. package/Slider.js +454 -329
  38. package/StepBar.js +2 -2
  39. package/Switch.js +220 -146
  40. package/TabBar.js +411 -409
  41. package/TabLayout.js +34 -34
  42. package/Table.js +1163 -1156
  43. package/Text.js +58 -58
  44. package/TextArea.js +278 -152
  45. package/Tooltip.js +173 -177
  46. package/Tree.js +177 -188
  47. package/Typography.js +30 -28
  48. package/WaitSpinner.js +6 -11
  49. package/cypress/support/commands.ts +14 -4
  50. package/cypress/support/index.d.ts +1 -1
  51. package/package.json +5 -5
  52. package/stubs-splunkui.d.ts +0 -4
  53. package/types/src/Card/Card.d.ts +3 -1
  54. package/types/src/Card/Header.d.ts +2 -0
  55. package/types/src/Card/docs/examples/HeadingTitle.d.ts +3 -0
  56. package/types/src/Clickable/Clickable.d.ts +11 -3
  57. package/types/src/Color/Color.d.ts +2 -2
  58. package/types/src/Layer/Layer.d.ts +2 -1
  59. package/types/src/Layer/index.d.ts +1 -0
  60. package/types/src/Link/Link.d.ts +4 -0
  61. package/types/src/Message/Message.d.ts +1 -1
  62. package/types/src/MessageBar/MessageBar.d.ts +1 -1
  63. package/types/src/ModalLayer/ModalLayer.d.ts +16 -21
  64. package/types/src/Multiselect/Multiselect.d.ts +1 -8
  65. package/types/src/Multiselect/Normal.d.ts +1 -7
  66. package/types/src/Multiselect/docs/examples/Children.d.ts +2 -9
  67. package/types/src/Multiselect/docs/examples/Controlled.d.ts +2 -9
  68. package/types/src/Multiselect/docs/examples/CustomizeSelected.d.ts +2 -9
  69. package/types/src/Multiselect/docs/examples/Disabled.d.ts +2 -9
  70. package/types/src/Multiselect/docs/examples/Error.d.ts +2 -9
  71. package/types/src/Multiselect/docs/examples/Fetching.d.ts +2 -22
  72. package/types/src/Multiselect/docs/examples/Headings.d.ts +2 -1
  73. package/types/src/Multiselect/docs/examples/LoadMoreOnScrollBottom.d.ts +2 -25
  74. package/types/src/Multiselect/docs/examples/NewValues.d.ts +2 -9
  75. package/types/src/Multiselect/docs/examples/TabInput.d.ts +2 -9
  76. package/types/src/Popover/Popover.d.ts +4 -2
  77. package/types/src/ResultsMenu/ResultsMenu.d.ts +23 -34
  78. package/types/src/Select/SelectBase.d.ts +2 -2
  79. package/types/src/TabBar/TabBar.d.ts +8 -5
  80. package/types/src/TabBar/TabBarContext.d.ts +1 -1
  81. package/types/src/TabLayout/TabLayout.d.ts +8 -5
  82. package/types/src/Typography/Typography.d.ts +27 -22
  83. package/useRovingFocus.js +20 -23
  84. package/types/src/Date/Icon.d.ts +0 -3
  85. package/types/src/TabBar/docs/examples/IconsAbove.d.ts +0 -3
  86. package/types/src/TabBar/docs/examples/VerticalIconsAbove.d.ts +0 -3
  87. /package/types/src/TabBar/docs/examples/{IconsLeft.d.ts → Icons.d.ts} +0 -0
  88. /package/types/src/TabBar/docs/examples/{VerticalIconsLeft.d.ts → VerticalIcons.d.ts} +0 -0
package/Button.js CHANGED
@@ -171,7 +171,9 @@
171
171
  value: i().any
172
172
  };
173
173
  var I = (0, v._)("(Opens new window)");
174
- var P = r().forwardRef((function(e, n) {
174
+ var P = r().forwardRef((function(e,
175
+ // SUI-7623 - needs to be specified for react-docgen versions less than 7.1.0
176
+ n) {
175
177
  var a = e.action, i = e.appearance, l = i === void 0 ? "default" : i, s = e.append, c = e.children, d = e.className, v = e.classNamePrivate, m = e.disabled, y = e.error, g = e.icon, h = e.inline, w = h === void 0 ? true : h, N = e.isMenu, k = e.label, P = e.onClick, _ = e.openInNewContext, j = e.prepend, M = e.value, E = C(e, [ "action", "appearance", "append", "children", "className", "classNamePrivate", "disabled", "error", "icon", "inline", "isMenu", "label", "onClick", "openInNewContext", "prepend", "value" ]);
176
178
  // @docs-props-type ButtonPropsBase
177
179
  var T = (0, t.useCallback)((function(e) {
package/ButtonSimple.js CHANGED
@@ -61,8 +61,8 @@
61
61
  r.r(e);
62
62
  // EXPORTS
63
63
  r.d(e, {
64
- buttonMixin: () => /* reexport */ C,
65
- default: () => /* reexport */ M
64
+ buttonMixin: () => /* reexport */ g,
65
+ default: () => /* reexport */ h
66
66
  });
67
67
  // CONCATENATED MODULE: external "react"
68
68
  const o = require("react");
@@ -75,12 +75,12 @@
75
75
  var c = r.n(i);
76
76
  // CONCATENATED MODULE: external "@splunk/react-ui/Clickable"
77
77
  const l = require("@splunk/react-ui/Clickable");
78
- var s = r.n(l);
78
+ var d = r.n(l);
79
79
  // CONCATENATED MODULE: external "@splunk/themes"
80
- const d = require("@splunk/themes");
80
+ const s = require("@splunk/themes");
81
81
  // CONCATENATED MODULE: external "lodash/merge"
82
- const b = require("lodash/merge");
83
- var v = r.n(b);
82
+ const v = require("lodash/merge");
83
+ var b = r.n(v);
84
84
  // CONCATENATED MODULE: ./src/ButtonSimple/mixin.ts
85
85
  function u(r) {
86
86
  "@babel/helpers - typeof";
@@ -100,73 +100,73 @@
100
100
  var i;
101
101
  var c;
102
102
  var l;
103
- var s = d.variables.contentColorActive;
104
- var b;
105
- var v = d.variables.contentColorDisabled;
103
+ var d = s.variables.contentColorActive;
104
+ var v;
105
+ var b = s.variables.contentColorDisabled;
106
106
  var u;
107
107
  switch (r) {
108
108
  case "primary":
109
109
  {
110
- e = d.variables.actionColorBackgroundPrimary;
111
- o = d.variables.actionColorBackgroundPrimaryActive;
112
- a = d.variables.actionColorBackgroundPrimaryDisabled;
113
- t = d.variables.actionColorBackgroundPrimaryHover;
114
- s = d.variables.contentColorInverted;
115
- v = d.variables.contentColorInverted;
110
+ e = s.variables.actionColorBackgroundPrimary;
111
+ o = s.variables.actionColorBackgroundPrimaryActive;
112
+ a = s.variables.actionColorBackgroundPrimaryDisabled;
113
+ t = s.variables.actionColorBackgroundPrimaryHover;
114
+ d = s.variables.contentColorInverted;
115
+ b = s.variables.contentColorInverted;
116
116
  break;
117
117
  }
118
118
 
119
119
  case "destructive":
120
120
  {
121
- e = d.variables.actionColorBackgroundDestructive;
122
- o = d.variables.actionColorBackgroundDestructiveActive;
123
- a = d.variables.actionColorBackgroundDestructiveDisabled;
124
- t = d.variables.actionColorBackgroundDestructiveHover;
125
- s = d.variables.contentColorInverted;
126
- v = d.variables.contentColorInverted;
121
+ e = s.variables.actionColorBackgroundDestructive;
122
+ o = s.variables.actionColorBackgroundDestructiveActive;
123
+ a = s.variables.actionColorBackgroundDestructiveDisabled;
124
+ t = s.variables.actionColorBackgroundDestructiveHover;
125
+ d = s.variables.contentColorInverted;
126
+ b = s.variables.contentColorInverted;
127
127
  break;
128
128
  }
129
129
 
130
130
  case "destructiveSecondary":
131
131
  {
132
- n = d.variables.actionColorBorderDestructiveSecondary;
133
- i = d.variables.actionColorBorderDestructiveSecondaryActive;
134
- c = d.variables.actionColorBorderDestructiveSecondaryDisabled;
135
- l = d.variables.actionColorBorderDestructiveSecondaryHover;
136
- e = d.variables.actionColorBackgroundDestructiveSecondary;
137
- o = d.variables.actionColorBackgroundDestructiveSecondaryActive;
138
- a = d.variables.actionColorBackgroundDestructiveSecondaryDisabled;
139
- t = d.variables.actionColorBackgroundDestructiveSecondaryHover;
140
- s = d.variables.contentColorNegative;
141
- v = d.variables.contentColorNegativeWeak;
132
+ n = s.variables.actionColorBorderDestructiveSecondary;
133
+ i = s.variables.actionColorBorderDestructiveSecondaryActive;
134
+ c = s.variables.actionColorBorderDestructiveSecondaryDisabled;
135
+ l = s.variables.actionColorBorderDestructiveSecondaryHover;
136
+ e = s.variables.actionColorBackgroundDestructiveSecondary;
137
+ o = s.variables.actionColorBackgroundDestructiveSecondaryActive;
138
+ a = s.variables.actionColorBackgroundDestructiveSecondaryDisabled;
139
+ t = s.variables.actionColorBackgroundDestructiveSecondaryHover;
140
+ d = s.variables.contentColorNegative;
141
+ b = s.variables.contentColorNegativeWeak;
142
142
  break;
143
143
  }
144
144
 
145
145
  case "secondary":
146
- n = d.variables.actionColorBorderSecondary;
147
- i = d.variables.actionColorBorderSecondaryActive;
148
- c = d.variables.actionColorBorderSecondaryDisabled;
149
- l = d.variables.actionColorBorderSecondaryHover;
150
- e = d.variables.actionColorBackgroundSecondary;
151
- o = d.variables.actionColorBackgroundSecondaryActive;
152
- t = d.variables.actionColorBackgroundSecondaryHover;
146
+ n = s.variables.actionColorBorderSecondary;
147
+ i = s.variables.actionColorBorderSecondaryActive;
148
+ c = s.variables.actionColorBorderSecondaryDisabled;
149
+ l = s.variables.actionColorBorderSecondaryHover;
150
+ e = s.variables.actionColorBackgroundSecondary;
151
+ o = s.variables.actionColorBackgroundSecondaryActive;
152
+ t = s.variables.actionColorBackgroundSecondaryHover;
153
153
  break;
154
154
 
155
155
  case "subtle":
156
- b = d.variables.contentColorAccentStrong;
157
- u = d.variables.contentColorAccentStrong;
158
- o = d.variables.actionColorBackgroundSubtleActive;
159
- t = d.variables.actionColorBackgroundSubtleHover;
156
+ v = s.variables.contentColorAccentStrong;
157
+ u = s.variables.contentColorAccentStrong;
158
+ o = s.variables.actionColorBackgroundSubtleActive;
159
+ t = s.variables.actionColorBackgroundSubtleHover;
160
160
  break;
161
161
 
162
162
  case "standalone":
163
- s = d.variables.contentColorAccent;
164
- b = d.variables.contentColorAccentStrong;
165
- v = d.variables.contentColorAccentWeak;
166
- u = d.variables.contentColorAccentStrong;
167
- e = d.variables.actionColorBackgroundSubtle;
168
- o = d.variables.actionColorBackgroundSubtleActive;
169
- t = d.variables.actionColorBackgroundSubtleHover;
163
+ d = s.variables.contentColorAccent;
164
+ v = s.variables.contentColorAccentStrong;
165
+ b = s.variables.contentColorAccentWeak;
166
+ u = s.variables.contentColorAccentStrong;
167
+ e = s.variables.actionColorBackgroundSubtle;
168
+ o = s.variables.actionColorBackgroundSubtleActive;
169
+ t = s.variables.actionColorBackgroundSubtleHover;
170
170
  break;
171
171
 
172
172
  default:
@@ -180,9 +180,9 @@
180
180
  borderColorActive: i,
181
181
  borderColorDisabled: c,
182
182
  borderColorHover: l,
183
- color: s,
184
- colorActive: b,
185
- colorDisabled: v,
183
+ color: d,
184
+ colorActive: v,
185
+ colorDisabled: b,
186
186
  colorHover: u
187
187
  };
188
188
  return p;
@@ -196,126 +196,50 @@
196
196
  a = r;
197
197
  }
198
198
  var t = y(o);
199
- var n = v()(t, a), c = n.background, l = n.backgroundActive, s = n.backgroundDisabled, b = n.backgroundDisabledSelected, f = n.backgroundHover, C = n.borderColor, g = n.borderColorActive, m = n.borderColorDisabled, k = n.borderColorHover, S = n.color, O = n.colorActive, B = n.colorDisabled, A = n.colorHover;
200
- var D = c != null && c !== "transparent";
199
+ var n = b()(t, a), c = n.background, l = n.backgroundActive, d = n.backgroundDisabled, v = n.backgroundDisabledSelected, f = n.backgroundHover, g = n.borderColor, C = n.borderColorActive, k = n.borderColorDisabled, S = n.borderColorHover, m = n.color, B = n.colorActive, A = n.colorDisabled, D = n.colorHover;
200
+ var h = c != null && c !== "transparent";
201
201
  return function() {
202
- return (0, i.css)([ "border:", " solid ", ";border-radius:", ";", " ", " cursor:pointer;position:relative;font-weight:", ";&:focus,&:hover{z-index:3;}&:focus{box-shadow:", ";}&:not([disabled],[aria-disabled='true']){background-color:", ";color:", ";transition:background-color 0.2s,box-shadow 0.2s,text-decoration 0.2s;&:hover{background-color:", ";border-color:", ";color:", ";}&:active{background-color:", ";border-color:", ";color:", ";transition:none;}}&[disabled],&[aria-disabled='true']{border-color:", ";color:", ";", "}" ], d.variables.inputBorderWidth, C, d.variables.borderRadius, (function(r) {
202
+ return (0, i.css)([ "border:", " solid ", ";border-radius:", ";", " ", " cursor:pointer;position:relative;font-weight:", ";&:focus,&:hover{z-index:3;}&:focus{box-shadow:", ";}&:not([disabled],[aria-disabled='true']){background-color:", ";color:", ";transition:background-color 0.2s,box-shadow 0.2s,text-decoration 0.2s;&:hover{background-color:", ";border-color:", ";color:", ";}&:active{background-color:", ";border-color:", ";color:", ";transition:none;}}&[disabled],&[aria-disabled='true']{border-color:", ";color:", ";", "}" ], s.variables.inputBorderWidth, g, s.variables.borderRadius, (function(r) {
203
203
  var e = r.$append;
204
204
  return e && (0, i.css)([ "border-top-right-radius:0.1px;border-bottom-right-radius:0.1px;border-right:none;" ]);
205
205
  }), (function(r) {
206
206
  var e = r.$prepend;
207
207
  return e && (0, i.css)([ "border-top-left-radius:0.1px;border-bottom-left-radius:0.1px;" ]);
208
- }), d.variables.fontWeightSemiBold, d.variables.focusShadow, c, S, f, k, A, l, g, O, m, B, (function(r) {
208
+ }), s.variables.fontWeightSemiBold, s.variables.focusShadow, c, m, f, S, D, l, C, B, k, A, (function(r) {
209
209
  var e = r.$selected;
210
- return D && (0, i.css)([ "background-color:", ";" ], e ? b : s);
210
+ return h && (0, i.css)([ "background-color:", ";" ], e ? v : d);
211
211
  }));
212
212
  };
213
213
  }
214
- /* harmony default export */ const C = f;
214
+ /* harmony default export */ const g = f;
215
215
  // CONCATENATED MODULE: ./src/ButtonSimple/ButtonSimpleStyles.ts
216
- function g(r) {
217
- "@babel/helpers - typeof";
218
- return g = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(r) {
219
- return typeof r;
220
- } : function(r) {
221
- return r && "function" == typeof Symbol && r.constructor === Symbol && r !== Symbol.prototype ? "symbol" : typeof r;
222
- }, g(r);
223
- }
224
- function m(r, e) {
225
- var o = Object.keys(r);
226
- if (Object.getOwnPropertySymbols) {
227
- var a = Object.getOwnPropertySymbols(r);
228
- e && (a = a.filter((function(e) {
229
- return Object.getOwnPropertyDescriptor(r, e).enumerable;
230
- }))), o.push.apply(o, a);
231
- }
232
- return o;
233
- }
234
- function k(r) {
235
- for (var e = 1; e < arguments.length; e++) {
236
- var o = null != arguments[e] ? arguments[e] : {};
237
- e % 2 ? m(Object(o), !0).forEach((function(e) {
238
- S(r, e, o[e]);
239
- })) : Object.getOwnPropertyDescriptors ? Object.defineProperties(r, Object.getOwnPropertyDescriptors(o)) : m(Object(o)).forEach((function(e) {
240
- Object.defineProperty(r, e, Object.getOwnPropertyDescriptor(o, e));
241
- }));
242
- }
243
- return r;
244
- }
245
- function S(r, e, o) {
246
- return (e = O(e)) in r ? Object.defineProperty(r, e, {
247
- value: o,
248
- enumerable: !0,
249
- configurable: !0,
250
- writable: !0
251
- }) : r[e] = o, r;
252
- }
253
- function O(r) {
254
- var e = B(r, "string");
255
- return "symbol" == g(e) ? e : e + "";
256
- }
257
- function B(r, e) {
258
- if ("object" != g(r) || !r) return r;
259
- var o = r[Symbol.toPrimitive];
260
- if (void 0 !== o) {
261
- var a = o.call(r, e || "default");
262
- if ("object" != g(a)) return a;
263
- throw new TypeError("@@toPrimitive must return a primitive value.");
264
- }
265
- return ("string" === e ? String : Number)(r);
266
- }
267
- var A = {
268
- borderColor: d.variables.interactiveColorAccentError,
269
- borderColorActive: d.variables.interactiveColorAccentError,
270
- borderColorHover: d.mixins.overlayColors(d.variables.interactiveColorAccentError, d.variables.interactiveColorBorderHover)
271
- };
272
- var D = {
273
- background: d.variables.interactiveColorBackground,
274
- backgroundActive: d.variables.interactiveColorOverlayActive,
275
- backgroundHover: d.variables.interactiveColorOverlayHover,
276
- borderColor: d.variables.transparent,
277
- borderColorActive: d.variables.transparent,
278
- borderColorDisabled: d.variables.transparent,
279
- borderColorHover: d.variables.transparent,
280
- color: d.variables.contentColorActive,
281
- colorActive: d.variables.contentColorActive,
282
- colorDisable: d.variables.contentColorDisabled,
283
- colorHover: d.variables.contentColorActive
284
- };
285
- var h = {
286
- background: d.variables.interactiveColorBackground,
287
- backgroundActive: d.variables.interactiveColorOverlayActive,
288
- backgroundHover: d.variables.interactiveColorOverlayHover,
289
- borderColor: d.variables.interactiveColorBorder,
290
- borderColorActive: d.variables.interactiveColorBorderActive,
291
- borderColorDisabled: d.variables.interactiveColorBorderDisabled,
292
- borderColorHover: d.variables.interactiveColorBorderHover
216
+ var C = {
217
+ borderColor: s.variables.interactiveColorAccentError,
218
+ borderColorActive: s.variables.interactiveColorAccentError,
219
+ borderColorHover: s.mixins.overlayColors(s.variables.interactiveColorAccentError, s.variables.interactiveColorBorderHover)
293
220
  };
294
- var j = c()(s()).withConfig({
221
+ var k = c()(d()).withConfig({
295
222
  displayName: "ButtonSimpleStyles__StyledClickable",
296
223
  componentId: "vlarwe-0"
297
- })([ "", " align-items:center;justify-content:center;&:not([disabled],[aria-disabled='true']){", "}", "" ], d.mixins.reset("flex"), (function(r) {
298
- var e = r.$error, o = r.$isMenu;
299
- return e && (0, i.css)([ "", "" ], (0, d.pickVariant)("$variant", {
300
- default: o ? C("secondary", k(k({}, h), A)) : C("secondary", A),
301
- secondary: o ? C("secondary", k(k({}, h), A)) : C("secondary", A),
302
- subtle: o ? C("secondary", k(k({}, D), A)) : C("subtle", A)
224
+ })([ "", " align-items:center;justify-content:center;&:not([disabled],[aria-disabled='true']){", "}", "" ], s.mixins.reset("flex"), (function(r) {
225
+ var e = r.$error;
226
+ return e && (0, i.css)([ "", "" ], (0, s.pickVariant)("$variant", {
227
+ default: g("secondary", C),
228
+ secondary: g("secondary", C),
229
+ subtle: g("subtle", C)
303
230
  }));
304
- }), (function(r) {
305
- var e = r.$isMenu;
306
- return (0, d.pickVariant)("$variant", {
307
- default: e ? C("secondary", h) : C("secondary"),
308
- primary: C("primary"),
309
- secondary: e ? C("secondary", h) : C("secondary"),
310
- subtle: e ? C("secondary", D) : C("subtle"),
311
- destructive: C("destructive"),
312
- destructiveSecondary: C("destructiveSecondary"),
313
- standalone: C("standalone")
314
- });
231
+ }), (0, s.pickVariant)("$variant", {
232
+ default: g("secondary"),
233
+ primary: g("primary"),
234
+ secondary: g("secondary"),
235
+ subtle: g("subtle"),
236
+ destructive: g("destructive"),
237
+ destructiveSecondary: g("destructiveSecondary"),
238
+ standalone: g("standalone")
315
239
  }));
316
240
  // CONCATENATED MODULE: ./src/ButtonSimple/ButtonSimple.tsx
317
- function H() {
318
- return H = Object.assign ? Object.assign.bind() : function(r) {
241
+ function S() {
242
+ return S = Object.assign ? Object.assign.bind() : function(r) {
319
243
  for (var e = 1; e < arguments.length; e++) {
320
244
  var o = arguments[e];
321
245
  for (var a in o) {
@@ -323,11 +247,11 @@
323
247
  }
324
248
  }
325
249
  return r;
326
- }, H.apply(null, arguments);
250
+ }, S.apply(null, arguments);
327
251
  }
328
- function w(r, e) {
252
+ function m(r, e) {
329
253
  if (null == r) return {};
330
- var o, a, t = P(r, e);
254
+ var o, a, t = B(r, e);
331
255
  if (Object.getOwnPropertySymbols) {
332
256
  var n = Object.getOwnPropertySymbols(r);
333
257
  for (a = 0; a < n.length; a++) {
@@ -336,7 +260,7 @@
336
260
  }
337
261
  return t;
338
262
  }
339
- function P(r, e) {
263
+ function B(r, e) {
340
264
  if (null == r) return {};
341
265
  var o = {};
342
266
  for (var a in r) {
@@ -347,7 +271,7 @@
347
271
  }
348
272
  return o;
349
273
  }
350
- var x = {
274
+ var A = {
351
275
  action: n().string,
352
276
  appearance: n().oneOf([ "default", "secondary", "primary", "destructive", "destructiveSecondary", "subtle", "standalone" ]),
353
277
  append: n().bool,
@@ -360,24 +284,24 @@
360
284
  prepend: n().bool,
361
285
  to: n().string
362
286
  };
363
- var $ = a().forwardRef((function(r, e) {
364
- var o = r.appearance, t = o === void 0 ? "default" : o, n = r.append, i = r.children, c = r.disabled, l = r.error, s = r.isMenu, d = r.prepend, b = w(r, [ "appearance", "append", "children", "disabled", "error", "isMenu", "prepend" ]);
287
+ var D = a().forwardRef((function(r, e) {
288
+ var o = r.appearance, t = o === void 0 ? "default" : o, n = r.append, i = r.children, c = r.disabled, l = r.error, d = r.isMenu, s = r.prepend, v = m(r, [ "appearance", "append", "children", "disabled", "error", "isMenu", "prepend" ]);
365
289
  // @docs-props-type ButtonSimplePropsBase
366
290
 
367
- return a().createElement(j, H({
291
+ return a().createElement(k, S({
368
292
  "aria-invalid": l,
369
293
  "data-test": "button-simple",
370
294
  disabled: c,
371
295
  $variant: t,
372
296
  $append: n,
373
- $prepend: d,
297
+ $prepend: s,
374
298
  $error: l,
375
- $isMenu: s,
299
+ $isMenu: d,
376
300
  ref: e
377
- }, b), i);
301
+ }, v), i);
378
302
  }));
379
- $.propTypes = x;
380
- /* harmony default export */ const M = $;
303
+ D.propTypes = A;
304
+ /* harmony default export */ const h = D;
381
305
  // only for styled-components that wrap ButtonSimple
382
306
  // CONCATENATED MODULE: ./src/ButtonSimple/index.ts
383
307
  module.exports = e;
package/CHANGELOG.md CHANGED
@@ -1,10 +1,13 @@
1
1
  Change Log
2
2
  ============
3
3
 
4
- 4.45.0 - TBD
4
+ 4.45.0 - May 6, 2025
5
5
  ----------
6
6
  Bug Fixes:
7
7
  * `Table` now displays `cursor: default` when a row is not clickable and is an empty action cell (SUI-7232).
8
+ * `Table` now maintains consistent IDs for expansion rows through renders (SUI-7698).
9
+ * `Layer` will now render at the correct `z-index` when `separateStackingContexts` is set in `LayerStackGlobalProvider` (SUI-7241).
10
+ * `Concertina`, `File`, `Layer`, `Slider`, `Resize`, and `TextArea` will no longer cause issues with server-side rendering (SUI-7737)
8
11
 
9
12
  4.44.1 - April 10, 2025
10
13
  ----------
package/CHANGELOG.v5.mdx CHANGED
@@ -1,6 +1,64 @@
1
1
  Change Log
2
2
  ============
3
3
 
4
+ 5.0.0-rc.1 - May 14, 2025
5
+ ----------
6
+ New Features:
7
+ * `Card` now defaults to a borderless appearance for non-clickable cards (SUI-7651).
8
+ * `Dropdown`, `Search`, and `TabBar` now uses `KeyboardEvent`'s `key` property instead of deprecated `keycode` property (SUI-7352).
9
+ * `Table` now uses `KeyboardEvent`'s `key` property instead of deprecated `keycode` property (SUI-7352).
10
+ * `FormRows`, `JSONTree`, `Number`, and `RadioBar` now use `KeyboardEvent`'s `key` property instead of deprecated `keycode` property (SUI-7352).
11
+
12
+ Bug Fixes:
13
+ * `Table`'s `rowExpansion` button now correctly displays hover styles (SUI-7772).
14
+ * `Text` no longer has border hover effects incorrectly applied when `disabled` or `dimmed` (SUI-7639).
15
+ * `Switch`'s `toggle` appearance now has correct role of `switch` (SUI-7713).
16
+ * `Table.HeadCell`'s and `Table.HeadDropdownCell`'s borders now span the full cell height when content wraps to multiline (SUI-7760)
17
+ * `CollapsiblePanel` no longer flickers on open or close of panel (SUI-7620).
18
+ * `Color` now passes `className` and `elementRef` to the root element instead of an inner component, allowing proper styling with `styled-components` (SUI-6211).
19
+ * `Button`'s now have consistent styling when using `appearance="secondary"` and `isMenu` (SUI-7611).
20
+
21
+ Deprecations:
22
+ * `Popover`'s `"inverted"` value of the `appearance` prop has been deprecated and will be removed in the next major version. See the migration guide for details (SUI-6154).
23
+
24
+ API Changes:
25
+ * `Color`'s test hook `[data-test="color"]` is now on the root component and `[data-test="toggle-swatch"]` is on the toggle swatch. See migration guide for details (SUI-7773).
26
+
27
+ 5.0.0-beta.5 - May 7, 2025
28
+ ----------
29
+ New Features:
30
+ * `TabBar` supports a new prop `maxTabWidth` prop (SUI-7599).
31
+ * `data-test-disabled` test hook has been added to data entry components for testing (SUI-7575).
32
+ * `Table`'s resize handler now supports hover state (SUI-7302).
33
+ * `Card.Header`'s `truncateTitle` prop now truncates title when a node with text content is passed into `title` prop (SUI-6333).
34
+ * `Typography` has reintroduced the `withReset` prop, which defaults to `true` and removes all browser-default styles while applying theme-specific defaults (SUI-7638).
35
+
36
+ Bug Fixes:
37
+ * `Message` content are now displayed using flow layout instead of flex (SUI-6271).
38
+ * `Progress` performance improved by preventing styled-components from generating excessive classes (SUI-7625).
39
+ * `Tooltip`'s toggletip focus and hover styles now have the correct shape (SUI-6155, SUI-7719).
40
+ * `Card.Header`'s `actions` now center align with the first line of the title (SUI-7657).
41
+ * `Slider` now correctly displays the bar when `minLabel` or `maxLabel` are set to null (SUI-7730).
42
+ * `Slider`'s drag handle no longer covers labels (SUI-7732).
43
+ * `RadioBar` now has improved visual contrast to better differentiate between selected and unselected options (SUI-7654).
44
+ * `Table` now correctly aligns multiline content when it wraps to a new line (SUI-7606).
45
+ * `Prose` should no longer apply margin to the last element (SUI-7227).
46
+ * `Text` now displays the `not-allowed` cursor on adornments when disabled (SUI-7532).
47
+ * `Typography`'s styles are now consistent with equivalent content components (SUI-7638).
48
+ * `Link` will now always render as an `a` tag, even when disabled (SUI-7543).
49
+
50
+ API Changes:
51
+ * `TabBar`'s `tabWidth` prop has been removed. See migration guide for details (SUI-7599).
52
+ * For enforcing a max width of `TabBar.Tab`s use `maxTabWidth` instead.
53
+ * `Multiselect`'s `useClickawayOverlay` prop has been removed (SUI-7722).
54
+
55
+ Deprecations:
56
+ * `TabBar` and `TabLayout`'s `iconPosition` prop has been deprecated and will be removed in the next major version. See the migration guide for details (SUI-7736).
57
+ Bug Fixes:
58
+ * FormRows correctly takes up the full width given (SUI-7716)
59
+ * FormRows no longer reserves extra space for remove button when rows are not removable (SUI-7717)
60
+ * `Card.Header`'s `anchor` prop is deprecated and will be removed in the next major version. See the migration guide for details (SUI-6577).
61
+
4
62
  5.0.0-beta.4 - April 22, 2025
5
63
  ----------
6
64
  New Features:
@@ -146,6 +204,7 @@ API Changes:
146
204
  * `Button`'s `appearance` prop no longer supports the `"flat"`, `"pill"`, or `"toggle"` values (SUI-6561).
147
205
  * `Button`'s `selected` prop has been removed (SUI-6058).
148
206
  * `Button` no longer supports the `error` prop.
207
+ * `Button`'s `label` prop no longer sets HTML `label` attribute. See migration guide for details (SUI-6054).
149
208
 
150
209
  * `Card` and `Card.Footer`'s `showBorder` prop has been removed (SUI-6577).
151
210
 
package/Card.js CHANGED
@@ -61,10 +61,10 @@
61
61
  e.r(r);
62
62
  // EXPORTS
63
63
  e.d(r, {
64
- Body: () => /* reexport */ j,
64
+ Body: () => /* reexport */ x,
65
65
  Footer: () => /* reexport */ _,
66
- Header: () => /* reexport */ J,
67
- default: () => /* reexport */ je
66
+ Header: () => /* reexport */ G,
67
+ default: () => /* reexport */ xe
68
68
  });
69
69
  // CONCATENATED MODULE: external "react"
70
70
  const t = require("react");
@@ -88,11 +88,11 @@
88
88
  var f = l().div.withConfig({
89
89
  displayName: "HeaderStyles__StyledTitle",
90
90
  componentId: "eqi6uk-0"
91
- })([ "", " ", " margin:0;overflow-wrap:break-word;padding:0;" ], u.mixins.reset("block"), u.mixins.typography("title3"));
91
+ })([ "", " ", " overflow-wrap:break-word;" ], u.mixins.reset("block"), u.mixins.typography("title3"));
92
92
  var p = l().div.withConfig({
93
93
  displayName: "HeaderStyles__StyledSubtitle",
94
94
  componentId: "eqi6uk-1"
95
- })([ "", " ", " margin:0;overflow-wrap:break-word;padding:0;" ], u.mixins.reset("block"), u.mixins.typography("body", {
95
+ })([ "", " ", " overflow-wrap:break-word;" ], u.mixins.reset("block"), u.mixins.typography("body", {
96
96
  color: "active"
97
97
  }));
98
98
  var y = l().div.withConfig({
@@ -100,12 +100,12 @@
100
100
  componentId: "eqi6uk-2"
101
101
  })([ "", " flex:0 1 auto;", " &:not(:last-child){margin-right:", ";}" ], u.mixins.reset("block"), (function(e) {
102
102
  var r = e.$truncateTitle;
103
- return r && (0, a.css)([ "overflow:hidden;& > ", ",& > ", "{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}" ], /* sc-sel */ f, /* sc-sel */ p);
103
+ return r && (0, a.css)([ "overflow:hidden;& > ", ",& > ", ",& > ", " *{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}" ], /* sc-sel */ f, /* sc-sel */ p, /* sc-sel */ f);
104
104
  }), u.variables.spacingSmall);
105
105
  var b = l().div.withConfig({
106
106
  displayName: "HeaderStyles__StyledActionContainer",
107
107
  componentId: "eqi6uk-3"
108
- })([ "", " align-items:center;display:flex;flex:0 0 auto;justify-content:space-between;gap:", ";" ], u.mixins.reset("block"), u.variables.spacingSmall);
108
+ })([ "", " align-items:center;flex:0 0 auto;justify-content:space-between;gap:", ";transform:translateY(calc(-1 * (", " - 20px) / 2));" ], u.mixins.reset("flex"), u.variables.spacingSmall, u.variables.inputHeight);
109
109
  var v = l()(s()).withConfig({
110
110
  displayName: "HeaderStyles__StyledBox",
111
111
  componentId: "eqi6uk-4"
@@ -169,9 +169,9 @@
169
169
  }, i), r);
170
170
  }
171
171
  S.propTypes = O;
172
- /* harmony default export */ const j = S;
172
+ /* harmony default export */ const x = S;
173
173
  // CONCATENATED MODULE: ./src/Card/FooterStyles.ts
174
- var x = l()(s()).withConfig({
174
+ var j = l()(s()).withConfig({
175
175
  displayName: "FooterStyles__StyledBox",
176
176
  componentId: "sc-1yu3r4s-0"
177
177
  })([ "", " ", " text-align:right;align-self:end;" ], u.mixins.typography("body"), d);
@@ -219,7 +219,7 @@
219
219
  var r = e.children, t = C(e, [ "children" ]);
220
220
  // @docs-props-type FooterPropsBase
221
221
 
222
- return n().createElement(x, k({
222
+ return n().createElement(j, k({
223
223
  "data-test": "footer"
224
224
  }, t), r);
225
225
  }
@@ -233,10 +233,10 @@
233
233
  var R = e.n(N);
234
234
  // CONCATENATED MODULE: external "@splunk/react-ui/Button"
235
235
  const A = require("@splunk/react-ui/Button");
236
- var W = e.n(A);
236
+ var H = e.n(A);
237
237
  // CONCATENATED MODULE: external "@splunk/react-ui/Dropdown"
238
- const B = require("@splunk/react-ui/Dropdown");
239
- var H = e.n(B);
238
+ const W = require("@splunk/react-ui/Dropdown");
239
+ var B = e.n(W);
240
240
  // CONCATENATED MODULE: external "@splunk/react-ui/Tooltip"
241
241
  const $ = require("@splunk/react-ui/Tooltip");
242
242
  var D = e.n($);
@@ -291,12 +291,12 @@
291
291
  // when we want actions to be the intended use case
292
292
  var X = n().createElement(q(), null);
293
293
  // `forwardRef` is used to enable focus on toggle when Dropdown is closing
294
- var z = n().forwardRef((function(e, r) {
294
+ var Y = n().forwardRef((function(e, r) {
295
295
 
296
296
  return n().createElement(D(), U({
297
297
  content: (0, F._)("Actions"),
298
298
  contentRelationship: "label"
299
- }, e), n().createElement(W(), {
299
+ }, e), n().createElement(H(), {
300
300
  appearance: "secondary",
301
301
  "data-test": "actions-secondary-toggle",
302
302
  icon: X,
@@ -305,16 +305,17 @@
305
305
  }));
306
306
  /**
307
307
  * A styled container for `Card` header content.
308
- */ function G(e) {
308
+ */ function z(e) {
309
309
  var r = e.actions, t = e.actionPrimary, o = e.actionsSecondary, i = e.anchor, a = e.children, l = e.subtitle, c = e.title, s = e.truncateTitle, u = s === void 0 ? true : s, d = L(e, [ "actions", "actionPrimary", "actionsSecondary", "anchor", "children", "subtitle", "title", "truncateTitle" ]);
310
310
  // @docs-props-type HeaderPropsBase
311
311
  if (false) {}
312
+ if (false) {}
312
313
  var m;
313
314
  if (r) {
314
315
  m = r();
315
316
  } else if (t || o) {
316
- m = n().createElement(n().Fragment, null, t, o && n().createElement(H(), {
317
- toggle: n().createElement(z, null)
317
+ m = n().createElement(n().Fragment, null, t, o && n().createElement(B(), {
318
+ toggle: n().createElement(Y, null)
318
319
  }, o));
319
320
  }
320
321
 
@@ -326,14 +327,14 @@
326
327
  name: i
327
328
  }, c) : c), l && n().createElement(p, null, l)), a, m && n().createElement(b, null, m));
328
329
  }
329
- G.propTypes = V;
330
- /* harmony default export */ const J = G;
330
+ z.propTypes = V;
331
+ /* harmony default export */ const G = z;
331
332
  // CONCATENATED MODULE: external "@splunk/react-ui/Clickable"
332
- const K = require("@splunk/react-ui/Clickable");
333
- var Q = e.n(K);
333
+ const J = require("@splunk/react-ui/Clickable");
334
+ var K = e.n(J);
334
335
  // CONCATENATED MODULE: ./src/Card/CardStyles.ts
335
- var Y = "0.2s";
336
- var Z = (0, a.css)([ "", ";gap:", " 0;grid-template-rows:min-content;background-color:", ";min-width:100px;flex:1;vertical-align:top;border:2px solid ", ";border-radius:", ";box-shadow:", ";transition:height ", ",width ", ",min-width ", ",max-width ", ",margin ", ",box-shadow ", ",border-color ", ";&[data-clickable='true']{cursor:pointer;", " &:hover{background-color:", ";box-shadow:", ";", "{text-decoration:underline;}}&:focus{box-shadow:", ";", "{text-decoration:underline;}}}" ], u.mixins.reset("inline-grid"), u.variables.spacingLarge, u.variables.backgroundColorSection, u.variables.borderColorWeak, u.variables.borderRadius, u.variables.embossShadow, Y, Y, Y, Y, Y, Y, Y, (function(e) {
336
+ var Q = "0.2s";
337
+ var Z = (0, a.css)([ "", ";gap:", " 0;grid-template-rows:min-content;background-color:", ";min-width:100px;flex:1;vertical-align:top;border:1px solid ", ";border-radius:", ";box-shadow:", ";transition:height ", ",width ", ",min-width ", ",max-width ", ",margin ", ",box-shadow ", ",border-color ", ";&[data-clickable='true']{cursor:pointer;border-color:", ";", " &:hover{background-color:", ";box-shadow:", ";", "{text-decoration:underline;}}&:focus{box-shadow:", ";", "{text-decoration:underline;}}}" ], u.mixins.reset("inline-grid"), u.variables.spacingLarge, u.variables.backgroundColorSection, u.variables.transparent, u.variables.borderRadius, u.variables.embossShadow, Q, Q, Q, Q, Q, Q, Q, u.variables.borderColorWeak, (function(e) {
337
338
  var r = e.$selected;
338
339
  return r && (0, a.css)([ "background-color:", ";" ], u.mixins.overlayColors(u.variables.backgroundColorSection, u.variables.interactiveColorOverlaySelected));
339
340
  }), u.mixins.overlayColors(u.variables.backgroundColorSection, u.variables.interactiveColorOverlayHover), u.variables.overlayShadow, /* sc-sel */ f, u.variables.focusShadow, /* sc-sel */ f);
@@ -341,7 +342,7 @@
341
342
  displayName: "CardStyles__Styled",
342
343
  componentId: "ola3x0-0"
343
344
  })([ "", "" ], Z);
344
- var re = l()(Q()).withConfig({
345
+ var re = l()(K()).withConfig({
345
346
  displayName: "CardStyles__StyledClickable",
346
347
  componentId: "ola3x0-1"
347
348
  })([ "", "" ], Z);
@@ -545,10 +546,10 @@
545
546
  return ge(e) ? n().createElement(we, e) : n().createElement(Oe, e);
546
547
  }
547
548
  Se.propTypes = me;
548
- Se.Header = J;
549
- Se.Body = j;
549
+ Se.Header = G;
550
+ Se.Body = x;
550
551
  Se.Footer = _;
551
- /* harmony default export */ const je = Se;
552
+ /* harmony default export */ const xe = Se;
552
553
  // CONCATENATED MODULE: ./src/Card/index.ts
553
554
  module.exports = r;
554
555
  /******/})();