@splunk/react-ui 4.14.0 → 4.15.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/.dockerignore +2 -0
- package/Accordion.js +41 -16
- package/Anchor.js +9 -9
- package/Animation.js +6 -6
- package/AnimationToggle.js +2 -2
- package/Box.js +9 -9
- package/Button.js +35 -34
- package/ButtonGroup.js +9 -9
- package/ButtonSimple.js +14 -14
- package/CHANGELOG.md +30 -0
- package/Calendar.js +124 -106
- package/Card.js +68 -68
- package/CardLayout.js +9 -9
- package/Chip.js +23 -23
- package/Clickable.js +38 -14
- package/CloseButton.js +23 -23
- package/Code.js +484 -436
- package/CollapsiblePanel.js +59 -34
- package/Color.js +297 -187
- package/ColumnLayout.js +18 -17
- package/ComboBox.js +81 -32
- package/Concertina.js +88 -27
- package/ControlGroup.js +81 -24
- package/Date.js +44 -31
- package/DefinitionList.js +14 -8
- package/Divider.d.ts +2 -0
- package/Divider.js +9 -9
- package/Dockerfile.enterprise.storybook +7 -0
- package/Dockerfile.prisma.storybook +7 -0
- package/Dockerfile.visual +10 -0
- package/Dropdown.js +78 -18
- package/EventListener.js +17 -17
- package/File.js +96 -43
- package/FormRows.js +38 -37
- package/Heading.js +83 -55
- package/Image.js +67 -42
- package/JSONTree.js +106 -21
- package/Layer.js +59 -34
- package/Link.js +17 -17
- package/List.js +3 -3
- package/Markdown.js +71 -65
- package/Menu.js +155 -121
- package/Message.js +129 -129
- package/MessageBar.js +136 -136
- package/Modal.js +57 -32
- package/ModalLayer.js +15 -15
- package/Monogram.js +18 -17
- package/Multiselect.js +2793 -2315
- package/Number.js +74 -37
- package/Paginator.js +99 -86
- package/Paragraph.js +10 -10
- package/Popover.js +191 -54
- package/Progress.js +23 -22
- package/RadioBar.js +32 -14
- package/RadioList.js +17 -11
- package/Resize.js +33 -20
- package/ResultsMenu.js +36 -23
- package/ScreenReaderContent.js +9 -9
- package/Scroll.js +50 -25
- package/ScrollContainerContext.js +48 -48
- package/Search.js +68 -31
- package/Select.js +347 -69
- package/SidePanel.js +37 -24
- package/Slider.js +54 -24
- package/SlidingPanels.js +52 -14
- package/SplitButton.js +23 -22
- package/StaticContent.js +9 -9
- package/StepBar.js +22 -22
- package/Switch.js +18 -13
- package/TabBar.js +22 -22
- package/TabLayout.js +43 -18
- package/Table.js +371 -162
- package/Text.js +91 -49
- package/TextArea.d.ts +2 -0
- package/TextArea.js +127 -49
- package/Tooltip.js +236 -59
- package/TransitionOpen.js +39 -26
- package/Typography.d.ts +2 -0
- package/Typography.js +17 -16
- package/WaitSpinner.js +15 -15
- package/docker-compose.yml +42 -0
- package/package.json +12 -10
- package/test-runner-jest.config.js +11 -6
- package/types/src/Accordion/AccordionContext.d.ts +1 -0
- package/types/src/Button/docs/examples/Selected.d.ts +2 -2
- package/types/src/ButtonGroup/ButtonGroupContext.d.ts +1 -0
- package/types/src/Calendar/Calendar.d.ts +2 -0
- package/types/src/CardLayout/CardLayoutContext.d.ts +1 -0
- package/types/src/Concertina/ConcertinaContext.d.ts +1 -0
- package/types/src/ControlGroup/ControlGroup.d.ts +15 -8
- package/types/src/ControlGroup/docs/examples/HelpWithErrorText.d.ts +2 -0
- package/types/src/ControlGroup/docs/examples/Required.d.ts +2 -0
- package/types/src/File/File.d.ts +4 -2
- package/types/src/File/FileContext.d.ts +1 -0
- package/types/src/FormRows/FormRowsContext.d.ts +1 -0
- package/types/src/Markdown/renderers/MarkdownLink.d.ts +1 -1
- package/types/src/Menu/MenuContext.d.ts +1 -0
- package/types/src/Modal/ModalContext.d.ts +1 -0
- package/types/src/Multiselect/Compact.d.ts +10 -1
- package/types/src/Multiselect/Multiselect.d.ts +12 -1
- package/types/src/Multiselect/Normal.d.ts +2 -0
- package/types/src/Popover/Popover.d.ts +25 -5
- package/types/src/Popover/PopoverContext.d.ts +1 -0
- package/types/src/RadioBar/RadioBar.d.ts +5 -3
- package/types/src/RadioBar/RadioBarContext.d.ts +1 -0
- package/types/src/RadioList/RadioList.d.ts +5 -1
- package/types/src/RadioList/RadioListContext.d.ts +1 -0
- package/types/src/Select/SelectBase.d.ts +2 -0
- package/types/src/Slider/Slider.d.ts +5 -3
- package/types/src/StepBar/StepBarContext.d.ts +1 -0
- package/types/src/Switch/Switch.d.ts +2 -0
- package/types/src/TabBar/TabBarContext.d.ts +1 -0
- package/types/src/Table/Head.d.ts +2 -0
- package/types/src/Table/TableContext.d.ts +1 -0
- package/types/src/Text/Text.d.ts +5 -3
- package/types/src/TextArea/TextArea.d.ts +5 -3
- package/types/src/Tooltip/Tooltip.d.ts +16 -4
- package/types/src/useForceUpdate/useForceUpdate.d.ts +1 -0
- package/useForceUpdate.js +9 -9
- package/useKeyPress.js +2 -2
- package/usePrevious.js +9 -9
- package/.storybook-visual/config/snapshotResolver.js +0 -29
- package/.storybook-visual/main.js +0 -22
- package/.storybook-visual/preview.jsx +0 -31
- package/.storybook-visual/scripts/test.sh +0 -108
- package/.storybook-visual/test-runner.js +0 -108
package/ColumnLayout.js
CHANGED
|
@@ -82,7 +82,7 @@ module.exports =
|
|
|
82
82
|
/******/
|
|
83
83
|
/******/
|
|
84
84
|
/******/ // Load entry module and return exports
|
|
85
|
-
/******/ return __webpack_require__(__webpack_require__.s =
|
|
85
|
+
/******/ return __webpack_require__(__webpack_require__.s = 173);
|
|
86
86
|
/******/ })
|
|
87
87
|
/************************************************************************/
|
|
88
88
|
/******/ ({
|
|
@@ -101,7 +101,14 @@ module.exports = require("prop-types");
|
|
|
101
101
|
|
|
102
102
|
/***/ }),
|
|
103
103
|
|
|
104
|
-
/***/
|
|
104
|
+
/***/ 108:
|
|
105
|
+
/***/ (function(module, exports) {
|
|
106
|
+
|
|
107
|
+
module.exports = require("lodash/defaults");
|
|
108
|
+
|
|
109
|
+
/***/ }),
|
|
110
|
+
|
|
111
|
+
/***/ 173:
|
|
105
112
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
106
113
|
|
|
107
114
|
"use strict";
|
|
@@ -122,11 +129,12 @@ var external_prop_types_ = __webpack_require__(1);
|
|
|
122
129
|
var external_prop_types_default = /*#__PURE__*/__webpack_require__.n(external_prop_types_);
|
|
123
130
|
|
|
124
131
|
// EXTERNAL MODULE: external "@splunk/themes/useSplunkTheme"
|
|
125
|
-
var useSplunkTheme_ = __webpack_require__(
|
|
132
|
+
var useSplunkTheme_ = __webpack_require__(52);
|
|
126
133
|
var useSplunkTheme_default = /*#__PURE__*/__webpack_require__.n(useSplunkTheme_);
|
|
127
134
|
|
|
128
|
-
// EXTERNAL MODULE: external "lodash"
|
|
129
|
-
var
|
|
135
|
+
// EXTERNAL MODULE: external "lodash/defaults"
|
|
136
|
+
var defaults_ = __webpack_require__(108);
|
|
137
|
+
var defaults_default = /*#__PURE__*/__webpack_require__.n(defaults_);
|
|
130
138
|
|
|
131
139
|
// EXTERNAL MODULE: external "styled-components"
|
|
132
140
|
var external_styled_components_ = __webpack_require__(3);
|
|
@@ -144,7 +152,7 @@ var Styled = external_styled_components_default.a.div.withConfig({
|
|
|
144
152
|
})(["", ";"], themes_["mixins"].reset('block'));
|
|
145
153
|
|
|
146
154
|
// EXTERNAL MODULE: ./src/utils/types.ts
|
|
147
|
-
var types = __webpack_require__(
|
|
155
|
+
var types = __webpack_require__(76);
|
|
148
156
|
|
|
149
157
|
// CONCATENATED MODULE: ./src/ColumnLayout/Column.tsx
|
|
150
158
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
@@ -200,7 +208,7 @@ function Column(_ref) {
|
|
|
200
208
|
return /*#__PURE__*/external_react_default.a.createElement(Styled, _extends({
|
|
201
209
|
"data-test": "column",
|
|
202
210
|
ref: elementRef,
|
|
203
|
-
style:
|
|
211
|
+
style: defaults_default()({}, style, calcStyle)
|
|
204
212
|
}, otherProps), children);
|
|
205
213
|
}
|
|
206
214
|
|
|
@@ -297,7 +305,7 @@ function Row(_ref) {
|
|
|
297
305
|
};
|
|
298
306
|
var childrenCloned = external_react_["Children"].toArray(children).filter(external_react_["isValidElement"]).map(cloneColumn).reduce(insertDividers, []);
|
|
299
307
|
return /*#__PURE__*/external_react_default.a.createElement(RowStyles_Styled, Row_extends({
|
|
300
|
-
style:
|
|
308
|
+
style: defaults_default()({}, style, gutterStyle),
|
|
301
309
|
"data-align-items": alignItems,
|
|
302
310
|
"data-test": "row",
|
|
303
311
|
ref: elementRef
|
|
@@ -428,21 +436,14 @@ module.exports = require("styled-components");
|
|
|
428
436
|
|
|
429
437
|
/***/ }),
|
|
430
438
|
|
|
431
|
-
/***/
|
|
432
|
-
/***/ (function(module, exports) {
|
|
433
|
-
|
|
434
|
-
module.exports = require("lodash");
|
|
435
|
-
|
|
436
|
-
/***/ }),
|
|
437
|
-
|
|
438
|
-
/***/ 42:
|
|
439
|
+
/***/ 52:
|
|
439
440
|
/***/ (function(module, exports) {
|
|
440
441
|
|
|
441
442
|
module.exports = require("@splunk/themes/useSplunkTheme");
|
|
442
443
|
|
|
443
444
|
/***/ }),
|
|
444
445
|
|
|
445
|
-
/***/
|
|
446
|
+
/***/ 76:
|
|
446
447
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
447
448
|
|
|
448
449
|
"use strict";
|
package/ComboBox.js
CHANGED
|
@@ -82,7 +82,7 @@ module.exports =
|
|
|
82
82
|
/******/
|
|
83
83
|
/******/
|
|
84
84
|
/******/ // Load entry module and return exports
|
|
85
|
-
/******/ return __webpack_require__(__webpack_require__.s =
|
|
85
|
+
/******/ return __webpack_require__(__webpack_require__.s = 210);
|
|
86
86
|
/******/ })
|
|
87
87
|
/************************************************************************/
|
|
88
88
|
/******/ ({
|
|
@@ -94,7 +94,14 @@ module.exports = require("prop-types");
|
|
|
94
94
|
|
|
95
95
|
/***/ }),
|
|
96
96
|
|
|
97
|
-
/***/
|
|
97
|
+
/***/ 11:
|
|
98
|
+
/***/ (function(module, exports) {
|
|
99
|
+
|
|
100
|
+
module.exports = require("lodash/has");
|
|
101
|
+
|
|
102
|
+
/***/ }),
|
|
103
|
+
|
|
104
|
+
/***/ 12:
|
|
98
105
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
99
106
|
|
|
100
107
|
"use strict";
|
|
@@ -121,21 +128,35 @@ function updateReactRef(ref, current) {
|
|
|
121
128
|
|
|
122
129
|
/***/ }),
|
|
123
130
|
|
|
124
|
-
/***/
|
|
131
|
+
/***/ 125:
|
|
125
132
|
/***/ (function(module, exports) {
|
|
126
133
|
|
|
127
|
-
module.exports = require("
|
|
134
|
+
module.exports = require("lodash/some");
|
|
128
135
|
|
|
129
136
|
/***/ }),
|
|
130
137
|
|
|
131
138
|
/***/ 13:
|
|
132
139
|
/***/ (function(module, exports) {
|
|
133
140
|
|
|
141
|
+
module.exports = require("@splunk/ui-utils/id");
|
|
142
|
+
|
|
143
|
+
/***/ }),
|
|
144
|
+
|
|
145
|
+
/***/ 15:
|
|
146
|
+
/***/ (function(module, exports) {
|
|
147
|
+
|
|
134
148
|
module.exports = require("@splunk/react-ui/Menu");
|
|
135
149
|
|
|
136
150
|
/***/ }),
|
|
137
151
|
|
|
138
|
-
/***/
|
|
152
|
+
/***/ 2:
|
|
153
|
+
/***/ (function(module, exports) {
|
|
154
|
+
|
|
155
|
+
module.exports = require("react");
|
|
156
|
+
|
|
157
|
+
/***/ }),
|
|
158
|
+
|
|
159
|
+
/***/ 210:
|
|
139
160
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
140
161
|
|
|
141
162
|
"use strict";
|
|
@@ -156,34 +177,51 @@ var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_)
|
|
|
156
177
|
var external_prop_types_ = __webpack_require__(1);
|
|
157
178
|
var external_prop_types_default = /*#__PURE__*/__webpack_require__.n(external_prop_types_);
|
|
158
179
|
|
|
159
|
-
// EXTERNAL MODULE: external "lodash"
|
|
160
|
-
var
|
|
180
|
+
// EXTERNAL MODULE: external "lodash/extend"
|
|
181
|
+
var extend_ = __webpack_require__(48);
|
|
182
|
+
var extend_default = /*#__PURE__*/__webpack_require__.n(extend_);
|
|
183
|
+
|
|
184
|
+
// EXTERNAL MODULE: external "lodash/has"
|
|
185
|
+
var has_ = __webpack_require__(11);
|
|
186
|
+
var has_default = /*#__PURE__*/__webpack_require__.n(has_);
|
|
187
|
+
|
|
188
|
+
// EXTERNAL MODULE: external "lodash/omit"
|
|
189
|
+
var omit_ = __webpack_require__(5);
|
|
190
|
+
var omit_default = /*#__PURE__*/__webpack_require__.n(omit_);
|
|
191
|
+
|
|
192
|
+
// EXTERNAL MODULE: external "lodash/pick"
|
|
193
|
+
var pick_ = __webpack_require__(34);
|
|
194
|
+
var pick_default = /*#__PURE__*/__webpack_require__.n(pick_);
|
|
195
|
+
|
|
196
|
+
// EXTERNAL MODULE: external "lodash/some"
|
|
197
|
+
var some_ = __webpack_require__(125);
|
|
198
|
+
var some_default = /*#__PURE__*/__webpack_require__.n(some_);
|
|
161
199
|
|
|
162
200
|
// EXTERNAL MODULE: external "@splunk/ui-utils/filter"
|
|
163
|
-
var filter_ = __webpack_require__(
|
|
201
|
+
var filter_ = __webpack_require__(33);
|
|
164
202
|
|
|
165
203
|
// EXTERNAL MODULE: external "@splunk/ui-utils/id"
|
|
166
|
-
var id_ = __webpack_require__(
|
|
204
|
+
var id_ = __webpack_require__(13);
|
|
167
205
|
|
|
168
206
|
// EXTERNAL MODULE: external "@splunk/ui-utils/i18n"
|
|
169
|
-
var i18n_ = __webpack_require__(
|
|
207
|
+
var i18n_ = __webpack_require__(4);
|
|
170
208
|
|
|
171
209
|
// EXTERNAL MODULE: external "@splunk/ui-utils/keyboard"
|
|
172
210
|
var keyboard_ = __webpack_require__(9);
|
|
173
211
|
|
|
174
212
|
// EXTERNAL MODULE: external "@splunk/react-ui/Menu"
|
|
175
|
-
var Menu_ = __webpack_require__(
|
|
213
|
+
var Menu_ = __webpack_require__(15);
|
|
176
214
|
|
|
177
215
|
// EXTERNAL MODULE: external "@splunk/react-ui/Popover"
|
|
178
|
-
var Popover_ = __webpack_require__(
|
|
216
|
+
var Popover_ = __webpack_require__(23);
|
|
179
217
|
var Popover_default = /*#__PURE__*/__webpack_require__.n(Popover_);
|
|
180
218
|
|
|
181
219
|
// EXTERNAL MODULE: external "@splunk/react-ui/ResultsMenu"
|
|
182
|
-
var ResultsMenu_ = __webpack_require__(
|
|
220
|
+
var ResultsMenu_ = __webpack_require__(45);
|
|
183
221
|
var ResultsMenu_default = /*#__PURE__*/__webpack_require__.n(ResultsMenu_);
|
|
184
222
|
|
|
185
223
|
// EXTERNAL MODULE: external "@splunk/react-ui/Text"
|
|
186
|
-
var Text_ = __webpack_require__(
|
|
224
|
+
var Text_ = __webpack_require__(30);
|
|
187
225
|
var Text_default = /*#__PURE__*/__webpack_require__.n(Text_);
|
|
188
226
|
|
|
189
227
|
// CONCATENATED MODULE: ./src/ComboBox/Option.tsx
|
|
@@ -326,7 +364,7 @@ _defineProperty(Option_Option, "defaultProps", defaultProps);
|
|
|
326
364
|
|
|
327
365
|
/* harmony default export */ var ComboBox_Option = (Option_Option);
|
|
328
366
|
// EXTERNAL MODULE: ./src/utils/updateReactRef.ts
|
|
329
|
-
var updateReactRef = __webpack_require__(
|
|
367
|
+
var updateReactRef = __webpack_require__(12);
|
|
330
368
|
|
|
331
369
|
// CONCATENATED MODULE: ./src/ComboBox/ComboBox.tsx
|
|
332
370
|
function ComboBox_typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { ComboBox_typeof = function _typeof(obj) { return typeof obj; }; } else { ComboBox_typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return ComboBox_typeof(obj); }
|
|
@@ -372,6 +410,10 @@ function ComboBox_defineProperty(obj, key, value) { if (key in obj) { Object.def
|
|
|
372
410
|
|
|
373
411
|
|
|
374
412
|
|
|
413
|
+
|
|
414
|
+
|
|
415
|
+
|
|
416
|
+
|
|
375
417
|
var ComboBox_propTypes = {
|
|
376
418
|
animateLoading: external_prop_types_default.a.bool,
|
|
377
419
|
append: external_prop_types_default.a.bool,
|
|
@@ -643,7 +685,7 @@ var ComboBox_ComboBox = /*#__PURE__*/function (_Component) {
|
|
|
643
685
|
var value = _this.getValue();
|
|
644
686
|
|
|
645
687
|
var initialOptions = external_react_["Children"].toArray(children).filter(external_react_["isValidElement"]);
|
|
646
|
-
var hasExactMatch =
|
|
688
|
+
var hasExactMatch = some_default()(initialOptions, function (option) {
|
|
647
689
|
if (option.type === Menu_["Heading"]) {
|
|
648
690
|
return false;
|
|
649
691
|
}
|
|
@@ -682,7 +724,7 @@ var ComboBox_ComboBox = /*#__PURE__*/function (_Component) {
|
|
|
682
724
|
|
|
683
725
|
return true; // Keep all headers and non-interactive options
|
|
684
726
|
})).map(function (option, index) {
|
|
685
|
-
if (!
|
|
727
|
+
if (!has_default()(option.props, 'active')) {
|
|
686
728
|
// ignore Headings and Dividers
|
|
687
729
|
return option;
|
|
688
730
|
}
|
|
@@ -711,7 +753,7 @@ var ComboBox_ComboBox = /*#__PURE__*/function (_Component) {
|
|
|
711
753
|
});
|
|
712
754
|
});
|
|
713
755
|
return /*#__PURE__*/external_react_default.a.createElement(ResultsMenu_default.a, ComboBox_extends({
|
|
714
|
-
style:
|
|
756
|
+
style: extend_default()({
|
|
715
757
|
overflow: 'auto',
|
|
716
758
|
width: Math.max(anchorWidth !== null && anchorWidth !== void 0 ? anchorWidth : 0, 200)
|
|
717
759
|
}, menuStyle),
|
|
@@ -719,7 +761,7 @@ var ComboBox_ComboBox = /*#__PURE__*/function (_Component) {
|
|
|
719
761
|
maxHeight: maxHeight !== null && maxHeight !== void 0 ? maxHeight : undefined,
|
|
720
762
|
onScrollBottom: onScrollBottom ? _this.handleScrollBottom : undefined,
|
|
721
763
|
isLoading: isLoadingOptions
|
|
722
|
-
},
|
|
764
|
+
}, pick_default()(_this.props, 'className', 'noOptionsMessage', 'footerMessage', 'animateLoading', 'loadingMessage', 'onScroll')), _this.options);
|
|
723
765
|
});
|
|
724
766
|
|
|
725
767
|
_this.state = {
|
|
@@ -729,7 +771,7 @@ var ComboBox_ComboBox = /*#__PURE__*/function (_Component) {
|
|
|
729
771
|
open: false,
|
|
730
772
|
value: props.defaultValue || ''
|
|
731
773
|
};
|
|
732
|
-
_this.controlledExternally =
|
|
774
|
+
_this.controlledExternally = has_default()(props, 'value');
|
|
733
775
|
_this.popoverId = Object(id_["createDOMID"])('popover');
|
|
734
776
|
_this.activeItemId = Object(id_["createDOMID"])('active-item');
|
|
735
777
|
|
|
@@ -828,7 +870,7 @@ var ComboBox_ComboBox = /*#__PURE__*/function (_Component) {
|
|
|
828
870
|
spellCheck: false,
|
|
829
871
|
canClear: true,
|
|
830
872
|
"data-test": "combo-box"
|
|
831
|
-
},
|
|
873
|
+
}, omit_default()(this.props, 'animateLoading', 'className', 'controlledFilter', 'defaultValue', 'footerMessage', 'isLoadingOptions', 'loadingMessage', 'menuStyle', 'noOptionsMessage', 'onClose', 'onOpen', 'onScroll', 'onScrollBottom', 'spellCheck'), {
|
|
832
874
|
"data-test-popover-id": this.popoverId,
|
|
833
875
|
"data-test-label": currentDisplayValue,
|
|
834
876
|
"data-test-value": currentValue,
|
|
@@ -880,52 +922,59 @@ ComboBox_defineProperty(ComboBox_ComboBox, "Heading", Menu_["Heading"]);
|
|
|
880
922
|
|
|
881
923
|
/***/ }),
|
|
882
924
|
|
|
883
|
-
/***/
|
|
925
|
+
/***/ 23:
|
|
884
926
|
/***/ (function(module, exports) {
|
|
885
927
|
|
|
886
928
|
module.exports = require("@splunk/react-ui/Popover");
|
|
887
929
|
|
|
888
930
|
/***/ }),
|
|
889
931
|
|
|
890
|
-
/***/
|
|
932
|
+
/***/ 30:
|
|
891
933
|
/***/ (function(module, exports) {
|
|
892
934
|
|
|
893
|
-
module.exports = require("react");
|
|
935
|
+
module.exports = require("@splunk/react-ui/Text");
|
|
894
936
|
|
|
895
937
|
/***/ }),
|
|
896
938
|
|
|
897
|
-
/***/
|
|
939
|
+
/***/ 33:
|
|
898
940
|
/***/ (function(module, exports) {
|
|
899
941
|
|
|
900
|
-
module.exports = require("@splunk/
|
|
942
|
+
module.exports = require("@splunk/ui-utils/filter");
|
|
901
943
|
|
|
902
944
|
/***/ }),
|
|
903
945
|
|
|
904
|
-
/***/
|
|
946
|
+
/***/ 34:
|
|
905
947
|
/***/ (function(module, exports) {
|
|
906
948
|
|
|
907
|
-
module.exports = require("
|
|
949
|
+
module.exports = require("lodash/pick");
|
|
908
950
|
|
|
909
951
|
/***/ }),
|
|
910
952
|
|
|
911
|
-
/***/
|
|
953
|
+
/***/ 4:
|
|
954
|
+
/***/ (function(module, exports) {
|
|
955
|
+
|
|
956
|
+
module.exports = require("@splunk/ui-utils/i18n");
|
|
957
|
+
|
|
958
|
+
/***/ }),
|
|
959
|
+
|
|
960
|
+
/***/ 45:
|
|
912
961
|
/***/ (function(module, exports) {
|
|
913
962
|
|
|
914
963
|
module.exports = require("@splunk/react-ui/ResultsMenu");
|
|
915
964
|
|
|
916
965
|
/***/ }),
|
|
917
966
|
|
|
918
|
-
/***/
|
|
967
|
+
/***/ 48:
|
|
919
968
|
/***/ (function(module, exports) {
|
|
920
969
|
|
|
921
|
-
module.exports = require("lodash");
|
|
970
|
+
module.exports = require("lodash/extend");
|
|
922
971
|
|
|
923
972
|
/***/ }),
|
|
924
973
|
|
|
925
974
|
/***/ 5:
|
|
926
975
|
/***/ (function(module, exports) {
|
|
927
976
|
|
|
928
|
-
module.exports = require("
|
|
977
|
+
module.exports = require("lodash/omit");
|
|
929
978
|
|
|
930
979
|
/***/ }),
|
|
931
980
|
|
package/Concertina.js
CHANGED
|
@@ -82,7 +82,7 @@ module.exports =
|
|
|
82
82
|
/******/
|
|
83
83
|
/******/
|
|
84
84
|
/******/ // Load entry module and return exports
|
|
85
|
-
/******/ return __webpack_require__(__webpack_require__.s =
|
|
85
|
+
/******/ return __webpack_require__(__webpack_require__.s = 174);
|
|
86
86
|
/******/ })
|
|
87
87
|
/************************************************************************/
|
|
88
88
|
/******/ ({
|
|
@@ -102,6 +102,27 @@ module.exports = require("prop-types");
|
|
|
102
102
|
/***/ }),
|
|
103
103
|
|
|
104
104
|
/***/ 10:
|
|
105
|
+
/***/ (function(module, exports) {
|
|
106
|
+
|
|
107
|
+
module.exports = require("lodash/keys");
|
|
108
|
+
|
|
109
|
+
/***/ }),
|
|
110
|
+
|
|
111
|
+
/***/ 116:
|
|
112
|
+
/***/ (function(module, exports) {
|
|
113
|
+
|
|
114
|
+
module.exports = require("lodash/take");
|
|
115
|
+
|
|
116
|
+
/***/ }),
|
|
117
|
+
|
|
118
|
+
/***/ 117:
|
|
119
|
+
/***/ (function(module, exports) {
|
|
120
|
+
|
|
121
|
+
module.exports = require("lodash/takeRight");
|
|
122
|
+
|
|
123
|
+
/***/ }),
|
|
124
|
+
|
|
125
|
+
/***/ 12:
|
|
105
126
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
106
127
|
|
|
107
128
|
"use strict";
|
|
@@ -128,14 +149,21 @@ function updateReactRef(ref, current) {
|
|
|
128
149
|
|
|
129
150
|
/***/ }),
|
|
130
151
|
|
|
131
|
-
/***/
|
|
152
|
+
/***/ 14:
|
|
132
153
|
/***/ (function(module, exports) {
|
|
133
154
|
|
|
134
155
|
module.exports = require("@splunk/react-ui/Clickable");
|
|
135
156
|
|
|
136
157
|
/***/ }),
|
|
137
158
|
|
|
138
|
-
/***/
|
|
159
|
+
/***/ 17:
|
|
160
|
+
/***/ (function(module, exports) {
|
|
161
|
+
|
|
162
|
+
module.exports = require("@splunk/react-ui/EventListener");
|
|
163
|
+
|
|
164
|
+
/***/ }),
|
|
165
|
+
|
|
166
|
+
/***/ 174:
|
|
139
167
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
140
168
|
|
|
141
169
|
"use strict";
|
|
@@ -154,19 +182,36 @@ var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_)
|
|
|
154
182
|
var external_prop_types_ = __webpack_require__(1);
|
|
155
183
|
var external_prop_types_default = /*#__PURE__*/__webpack_require__.n(external_prop_types_);
|
|
156
184
|
|
|
157
|
-
// EXTERNAL MODULE: external "lodash"
|
|
158
|
-
var
|
|
185
|
+
// EXTERNAL MODULE: external "lodash/debounce"
|
|
186
|
+
var debounce_ = __webpack_require__(63);
|
|
187
|
+
var debounce_default = /*#__PURE__*/__webpack_require__.n(debounce_);
|
|
188
|
+
|
|
189
|
+
// EXTERNAL MODULE: external "lodash/take"
|
|
190
|
+
var take_ = __webpack_require__(116);
|
|
191
|
+
var take_default = /*#__PURE__*/__webpack_require__.n(take_);
|
|
192
|
+
|
|
193
|
+
// EXTERNAL MODULE: external "lodash/takeRight"
|
|
194
|
+
var takeRight_ = __webpack_require__(117);
|
|
195
|
+
var takeRight_default = /*#__PURE__*/__webpack_require__.n(takeRight_);
|
|
159
196
|
|
|
160
197
|
// EXTERNAL MODULE: external "@splunk/react-ui/EventListener"
|
|
161
|
-
var EventListener_ = __webpack_require__(
|
|
198
|
+
var EventListener_ = __webpack_require__(17);
|
|
162
199
|
var EventListener_default = /*#__PURE__*/__webpack_require__.n(EventListener_);
|
|
163
200
|
|
|
201
|
+
// EXTERNAL MODULE: external "lodash/keys"
|
|
202
|
+
var keys_ = __webpack_require__(10);
|
|
203
|
+
var keys_default = /*#__PURE__*/__webpack_require__.n(keys_);
|
|
204
|
+
|
|
205
|
+
// EXTERNAL MODULE: external "lodash/omit"
|
|
206
|
+
var omit_ = __webpack_require__(5);
|
|
207
|
+
var omit_default = /*#__PURE__*/__webpack_require__.n(omit_);
|
|
208
|
+
|
|
164
209
|
// EXTERNAL MODULE: external "styled-components"
|
|
165
210
|
var external_styled_components_ = __webpack_require__(3);
|
|
166
211
|
var external_styled_components_default = /*#__PURE__*/__webpack_require__.n(external_styled_components_);
|
|
167
212
|
|
|
168
213
|
// EXTERNAL MODULE: external "@splunk/react-ui/Clickable"
|
|
169
|
-
var Clickable_ = __webpack_require__(
|
|
214
|
+
var Clickable_ = __webpack_require__(14);
|
|
170
215
|
var Clickable_default = /*#__PURE__*/__webpack_require__.n(Clickable_);
|
|
171
216
|
|
|
172
217
|
// EXTERNAL MODULE: external "@splunk/themes"
|
|
@@ -237,6 +282,7 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
237
282
|
|
|
238
283
|
|
|
239
284
|
|
|
285
|
+
|
|
240
286
|
var propTypes = {
|
|
241
287
|
children: external_prop_types_default.a.node.isRequired,
|
|
242
288
|
description: external_prop_types_default.a.node,
|
|
@@ -317,7 +363,7 @@ var Heading_Heading = /*#__PURE__*/function (_Component) {
|
|
|
317
363
|
ref: this.handleMount,
|
|
318
364
|
"data-test": "heading",
|
|
319
365
|
"data-test-panel-id": panelId
|
|
320
|
-
},
|
|
366
|
+
}, omit_default()(this.props, keys_default()(Heading.propTypes))), /*#__PURE__*/external_react_default.a.createElement(StyledHeadingContent, null, /*#__PURE__*/external_react_default.a.createElement("span", {
|
|
321
367
|
"data-concertina-role": "title"
|
|
322
368
|
}, children), description && /*#__PURE__*/external_react_default.a.createElement(StyledDescription, {
|
|
323
369
|
"data-concertina-role": "description"
|
|
@@ -333,12 +379,16 @@ _defineProperty(Heading_Heading, "propTypes", propTypes);
|
|
|
333
379
|
_defineProperty(Heading_Heading, "defaultProps", defaultProps);
|
|
334
380
|
|
|
335
381
|
/* harmony default export */ var Concertina_Heading = (Heading_Heading);
|
|
382
|
+
// EXTERNAL MODULE: external "lodash/throttle"
|
|
383
|
+
var throttle_ = __webpack_require__(31);
|
|
384
|
+
var throttle_default = /*#__PURE__*/__webpack_require__.n(throttle_);
|
|
385
|
+
|
|
336
386
|
// EXTERNAL MODULE: external "@splunk/react-ui/Box"
|
|
337
387
|
var Box_ = __webpack_require__(8);
|
|
338
388
|
var Box_default = /*#__PURE__*/__webpack_require__.n(Box_);
|
|
339
389
|
|
|
340
390
|
// EXTERNAL MODULE: external "@splunk/react-ui/Scroll"
|
|
341
|
-
var Scroll_ = __webpack_require__(
|
|
391
|
+
var Scroll_ = __webpack_require__(90);
|
|
342
392
|
var Scroll_default = /*#__PURE__*/__webpack_require__.n(Scroll_);
|
|
343
393
|
|
|
344
394
|
// CONCATENATED MODULE: ./src/Concertina/ConcertinaStyles.ts
|
|
@@ -378,7 +428,7 @@ var StyledPanelBody = external_styled_components_default.a.div.withConfig({
|
|
|
378
428
|
}));
|
|
379
429
|
|
|
380
430
|
// EXTERNAL MODULE: ./src/utils/updateReactRef.ts
|
|
381
|
-
var updateReactRef = __webpack_require__(
|
|
431
|
+
var updateReactRef = __webpack_require__(12);
|
|
382
432
|
|
|
383
433
|
// CONCATENATED MODULE: ./src/Concertina/ConcertinaContext.tsx
|
|
384
434
|
|
|
@@ -432,6 +482,8 @@ function Panel_defineProperty(obj, key, value) { if (key in obj) { Object.define
|
|
|
432
482
|
|
|
433
483
|
|
|
434
484
|
|
|
485
|
+
|
|
486
|
+
|
|
435
487
|
var Panel_propTypes = {
|
|
436
488
|
children: external_prop_types_default.a.node,
|
|
437
489
|
description: external_prop_types_default.a.node,
|
|
@@ -485,7 +537,7 @@ var Panel_Panel = /*#__PURE__*/function (_Component) {
|
|
|
485
537
|
(_this$context$onChang = (_this$context = _this.context).onChange) === null || _this$context$onChang === void 0 ? void 0 : _this$context$onChang.call(_this$context, e, data);
|
|
486
538
|
});
|
|
487
539
|
|
|
488
|
-
Panel_defineProperty(Panel_assertThisInitialized(_this), "handleResize",
|
|
540
|
+
Panel_defineProperty(Panel_assertThisInitialized(_this), "handleResize", throttle_default()(_this.measureHeight, 300));
|
|
489
541
|
|
|
490
542
|
Panel_defineProperty(Panel_assertThisInitialized(_this), "handleMount", function (el) {
|
|
491
543
|
_this.setState({
|
|
@@ -550,7 +602,7 @@ var Panel_Panel = /*#__PURE__*/function (_Component) {
|
|
|
550
602
|
ref: this.handleMount,
|
|
551
603
|
"data-test": "panel",
|
|
552
604
|
"data-test-panel-id": panelId || "".concat(index)
|
|
553
|
-
},
|
|
605
|
+
}, omit_default()(this.props, [].concat(_toConsumableArray(keys_default()(Panel.propTypes)), ['style']))), /*#__PURE__*/external_react_default.a.createElement(Concertina_Heading, {
|
|
554
606
|
onClick: onHeadingClickContext,
|
|
555
607
|
ref: this.handleHeadingMount,
|
|
556
608
|
description: description,
|
|
@@ -620,6 +672,8 @@ function Concertina_defineProperty(obj, key, value) { if (key in obj) { Object.d
|
|
|
620
672
|
|
|
621
673
|
|
|
622
674
|
|
|
675
|
+
|
|
676
|
+
|
|
623
677
|
var Concertina_propTypes = {
|
|
624
678
|
children: external_prop_types_default.a.node,
|
|
625
679
|
elementRef: external_prop_types_default.a.oneOfType([external_prop_types_default.a.func, external_prop_types_default.a.object])
|
|
@@ -699,13 +753,13 @@ var Concertina_Concertina = /*#__PURE__*/function (_Component) {
|
|
|
699
753
|
return;
|
|
700
754
|
}
|
|
701
755
|
|
|
702
|
-
var headingsBeforeHeight =
|
|
756
|
+
var headingsBeforeHeight = take_default()(_this.panelPositions, index).map(function (item) {
|
|
703
757
|
return item.headingHeight;
|
|
704
758
|
}).reduce(function (a, b) {
|
|
705
759
|
return a + b;
|
|
706
760
|
}, 0); // sum the heights
|
|
707
761
|
|
|
708
|
-
var headingsAfterHeight =
|
|
762
|
+
var headingsAfterHeight = takeRight_default()(_this.panelPositions, _this.panelPositions.length - index - 1).map(function (item) {
|
|
709
763
|
return item.headingHeight;
|
|
710
764
|
}).reduce(function (a, b) {
|
|
711
765
|
return a + b;
|
|
@@ -767,7 +821,7 @@ var Concertina_Concertina = /*#__PURE__*/function (_Component) {
|
|
|
767
821
|
});
|
|
768
822
|
});
|
|
769
823
|
|
|
770
|
-
Concertina_defineProperty(Concertina_assertThisInitialized(_this), "updateHeadings",
|
|
824
|
+
Concertina_defineProperty(Concertina_assertThisInitialized(_this), "updateHeadings", debounce_default()(_this.updateHeadingsImpl, 0));
|
|
771
825
|
|
|
772
826
|
_this.state = {
|
|
773
827
|
innerWidth: '100%',
|
|
@@ -817,8 +871,8 @@ var Concertina_Concertina = /*#__PURE__*/function (_Component) {
|
|
|
817
871
|
index: index
|
|
818
872
|
});
|
|
819
873
|
});
|
|
820
|
-
var topPanels =
|
|
821
|
-
var bottomPanels =
|
|
874
|
+
var topPanels = take_default()(childrenCleaned, this.state.panelsTopCount);
|
|
875
|
+
var bottomPanels = takeRight_default()(childrenCleaned, this.state.panelsBottomCount);
|
|
822
876
|
return /*#__PURE__*/external_react_default.a.createElement(StyledBox, Concertina_extends({
|
|
823
877
|
"data-test": "concertina"
|
|
824
878
|
}, otherProps), /*#__PURE__*/external_react_default.a.createElement(EventListener_default.a, {
|
|
@@ -869,38 +923,38 @@ Concertina_defineProperty(Concertina_Concertina, "Panel", Concertina_Panel);
|
|
|
869
923
|
|
|
870
924
|
/***/ }),
|
|
871
925
|
|
|
872
|
-
/***/
|
|
926
|
+
/***/ 2:
|
|
873
927
|
/***/ (function(module, exports) {
|
|
874
928
|
|
|
875
|
-
module.exports = require("
|
|
929
|
+
module.exports = require("react");
|
|
876
930
|
|
|
877
931
|
/***/ }),
|
|
878
932
|
|
|
879
|
-
/***/
|
|
933
|
+
/***/ 3:
|
|
880
934
|
/***/ (function(module, exports) {
|
|
881
935
|
|
|
882
|
-
module.exports = require("
|
|
936
|
+
module.exports = require("styled-components");
|
|
883
937
|
|
|
884
938
|
/***/ }),
|
|
885
939
|
|
|
886
|
-
/***/
|
|
940
|
+
/***/ 31:
|
|
887
941
|
/***/ (function(module, exports) {
|
|
888
942
|
|
|
889
|
-
module.exports = require("
|
|
943
|
+
module.exports = require("lodash/throttle");
|
|
890
944
|
|
|
891
945
|
/***/ }),
|
|
892
946
|
|
|
893
|
-
/***/
|
|
947
|
+
/***/ 5:
|
|
894
948
|
/***/ (function(module, exports) {
|
|
895
949
|
|
|
896
|
-
module.exports = require("lodash");
|
|
950
|
+
module.exports = require("lodash/omit");
|
|
897
951
|
|
|
898
952
|
/***/ }),
|
|
899
953
|
|
|
900
|
-
/***/
|
|
954
|
+
/***/ 63:
|
|
901
955
|
/***/ (function(module, exports) {
|
|
902
956
|
|
|
903
|
-
module.exports = require("
|
|
957
|
+
module.exports = require("lodash/debounce");
|
|
904
958
|
|
|
905
959
|
/***/ }),
|
|
906
960
|
|
|
@@ -909,6 +963,13 @@ module.exports = require("@splunk/react-ui/Scroll");
|
|
|
909
963
|
|
|
910
964
|
module.exports = require("@splunk/react-ui/Box");
|
|
911
965
|
|
|
966
|
+
/***/ }),
|
|
967
|
+
|
|
968
|
+
/***/ 90:
|
|
969
|
+
/***/ (function(module, exports) {
|
|
970
|
+
|
|
971
|
+
module.exports = require("@splunk/react-ui/Scroll");
|
|
972
|
+
|
|
912
973
|
/***/ })
|
|
913
974
|
|
|
914
975
|
/******/ });
|