@splunk/react-ui 4.35.0 → 4.36.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.
package/MIGRATION.mdx CHANGED
@@ -648,3 +648,20 @@ With the new `Search` component optimized for user interaction, Text's `appearan
648
648
  #### Migration steps
649
649
 
650
650
  Replace all usage of `Text`'s `appearance="search"` value with the `Search` component. Remove all usage of `Text`'s `appearance="default"` value.
651
+
652
+ ## 4.36.0
653
+
654
+ ### Deprecated `ComboBox`, `ControlGroup`, and `StaticContent`'s `size` prop
655
+
656
+ #### Change
657
+
658
+ `ComboBox`, `ControlGroup`, and `StaticContent`'s `size` prop has been deprecated and will be removed in the next major version.
659
+
660
+ #### Context
661
+
662
+ The `size` prop currently does not do anything in `ComboBox`, `ControlGroup`, or `StaticContent`, so it will be removed in the next major version.
663
+
664
+ #### Migration steps
665
+
666
+ Remove all usage of `ComboBox`, `ControlGroup`, and `StaticContent`'s `size` prop. To change the size of components, use the `SplunkThemeProvider`'s `density` prop.
667
+
package/Modal.js CHANGED
@@ -489,7 +489,7 @@
489
489
  id: p,
490
490
  "data-test": "subtitle"
491
491
  }, a)) : t, i && n().createElement(ae, null, n().createElement(le, null, n().createElement(ce, {
492
- appearance: "pill",
492
+ appearance: "subtle",
493
493
  "aria-label": (0, Y._)("Close"),
494
494
  "data-test": "close",
495
495
  onClick: i
package/Multiselect.js CHANGED
@@ -2940,8 +2940,14 @@
2940
2940
  gr(br(a), "popoverId", void 0);
2941
2941
  gr(br(a), "previousActiveIndex", null);
2942
2942
  gr(br(a), "handleClick", (function() {
2943
- var e;
2944
- (e = a.input) === null || e === void 0 ? void 0 : e.focus();
2943
+ if (a.state.hasFocus) {
2944
+ a.open({
2945
+ resetFilterKeyword: false
2946
+ });
2947
+ } else {
2948
+ var e;
2949
+ (e = a.input) === null || e === void 0 ? void 0 : e.focus();
2950
+ }
2945
2951
  }));
2946
2952
  gr(br(a), "handleRequestRemove", (function(e, t) {
2947
2953
  var n = t.value;
@@ -2950,6 +2956,19 @@
2950
2956
  }));
2951
2957
  // allow the event to bubble before removing.
2952
2958
  }));
2959
+ gr(br(a), "open", (function(e) {
2960
+ var t = e.resetFilterKeyword;
2961
+ a.setState((function(e) {
2962
+ return {
2963
+ filterKeyword: t ? "" : e.filterKeyword,
2964
+ hasFocus: true,
2965
+ open: true
2966
+ };
2967
+ }), (function() {
2968
+ var e, t;
2969
+ (e = (t = a.props).onOpen) === null || e === void 0 ? void 0 : e.call(t);
2970
+ }));
2971
+ }));
2953
2972
  gr(br(a), "handleInputFocus", (function(e) {
2954
2973
  if (a.state.filterKeyword !== "") {
2955
2974
  var t, n;
@@ -2957,14 +2976,9 @@
2957
2976
  keyword: ""
2958
2977
  });
2959
2978
  }
2960
- a.setState({
2961
- filterKeyword: "",
2962
- hasFocus: true,
2963
- open: true
2964
- }, (function() {
2965
- var e, t;
2966
- (e = (t = a.props).onOpen) === null || e === void 0 ? void 0 : e.call(t);
2967
- }));
2979
+ a.open({
2980
+ resetFilterKeyword: true
2981
+ });
2968
2982
  }));
2969
2983
  gr(br(a), "handleInputKeyDown", (function(e) {
2970
2984
  var t, r;
@@ -3055,6 +3069,7 @@
3055
3069
  gr(br(a), "handleMenuOptionClick", (function(e, t) {
3056
3070
  var n;
3057
3071
  var r = t.value;
3072
+ e.stopPropagation();
3058
3073
  a.addValue(e, r);
3059
3074
  (n = a.input) === null || n === void 0 ? void 0 : n.focus();
3060
3075
  }));
@@ -3208,6 +3223,9 @@
3208
3223
  key: "addValue",
3209
3224
  value: function e(t, n) {
3210
3225
  var r, o, a;
3226
+ if (!this.state.open) {
3227
+ return;
3228
+ }
3211
3229
  var i = ((r = this.getCurrentValues()) !== null && r !== void 0 ? r : []).concat([ n ]);
3212
3230
  var l = this.props.name;
3213
3231
  if (!this.isControlled()) {
package/Paginator.js CHANGED
@@ -229,7 +229,7 @@
229
229
  $current: o || false,
230
230
  "data-test": "page",
231
231
  "data-test-page": i,
232
- appearance: "pill",
232
+ appearance: "subtle",
233
233
  disabled: a,
234
234
  inline: false,
235
235
  onClick: s