@carbon/ibm-products 2.15.1 → 2.16.0
Sign up to get free protection for your applications and to get access to all the features.
- package/css/index-full-carbon.css +217 -9
- package/css/index-full-carbon.css.map +1 -1
- package/css/index-full-carbon.min.css +1 -1
- package/css/index-full-carbon.min.css.map +1 -1
- package/css/index-without-carbon-released-only.css +1 -1
- package/css/index-without-carbon-released-only.css.map +1 -1
- package/css/index-without-carbon-released-only.min.css +1 -1
- package/css/index-without-carbon-released-only.min.css.map +1 -1
- package/css/index-without-carbon.css +217 -9
- package/css/index-without-carbon.css.map +1 -1
- package/css/index-without-carbon.min.css +1 -1
- package/css/index-without-carbon.min.css.map +1 -1
- package/css/index.css +27 -9
- package/css/index.css.map +1 -1
- package/css/index.min.css +1 -1
- package/css/index.min.css.map +1 -1
- package/es/components/Datagrid/Datagrid/DatagridContent.js +12 -9
- package/es/components/Datagrid/Datagrid/DatagridExpandedRow.js +4 -4
- package/es/components/Datagrid/Datagrid/DatagridHeaderRow.js +40 -25
- package/es/components/Datagrid/Datagrid/DatagridRefBody.js +4 -1
- package/es/components/Datagrid/Datagrid/DatagridRow.js +5 -2
- package/es/components/Datagrid/Datagrid/DatagridSelectAll.js +12 -11
- package/es/components/Datagrid/Datagrid/DatagridSimpleBody.js +4 -1
- package/es/components/Datagrid/Datagrid/DatagridVirtualBody.js +35 -28
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/DraggableItemsList.js +2 -2
- package/es/components/Datagrid/Datagrid/addons/stateReducer.js +50 -14
- package/es/components/Datagrid/Datagrid.docs-page.js +8 -2
- package/es/components/Datagrid/useActionsColumn.js +7 -5
- package/es/components/Datagrid/useDatagrid.js +13 -1
- package/es/components/Datagrid/useInfiniteScroll.js +10 -9
- package/es/components/Datagrid/useOnRowClick.js +6 -7
- package/es/components/Datagrid/useParentDimensions.js +6 -6
- package/es/components/Datagrid/useResizeTable.js +7 -7
- package/es/components/Datagrid/useSelectRows.js +8 -5
- package/es/components/Datagrid/useSkeletonRows.js +6 -6
- package/es/components/Datagrid/useSortableColumns.js +5 -7
- package/es/components/Datagrid/useStickyColumn.js +13 -6
- package/es/components/EmptyStates/ErrorEmptyState/ErrorEmptyState.js +2 -1
- package/es/components/EmptyStates/NoTagsEmptyState/NoTagsEmptyState.js +2 -1
- package/es/components/EmptyStates/NotFoundEmptyState/NotFoundEmptyState.js +2 -1
- package/es/components/EmptyStates/NotificationsEmptyState/NotificationsEmptyState.js +2 -1
- package/es/components/EmptyStates/UnauthorizedEmptyState/UnauthorizedEmptyState.js +2 -1
- package/es/components/EmptyStates/assets/ErrorIllustration.js +5 -3
- package/es/components/EmptyStates/assets/NoDataIllustration.js +5 -3
- package/es/components/EmptyStates/assets/NoTagsIllustration.js +5 -3
- package/es/components/EmptyStates/assets/NotFoundIllustration.js +5 -3
- package/es/components/EmptyStates/assets/NotificationsIllustration.js +5 -3
- package/es/components/EmptyStates/assets/UnauthorizedIllustration.js +5 -3
- package/es/components/InlineTip/InlineTip.docs-page.js +13 -0
- package/es/components/InlineTip/InlineTip.js +217 -0
- package/es/components/InlineTip/InlineTipButton.js +53 -0
- package/es/components/InlineTip/InlineTipLink.js +57 -0
- package/es/components/InlineTip/index.js +10 -0
- package/es/components/InlineTip/utils.js +36 -0
- package/es/components/SteppedAnimatedMedia/SteppedAnimatedMedia.docs-page.js +11 -0
- package/es/components/SteppedAnimatedMedia/SteppedAnimatedMedia.js +140 -0
- package/es/components/SteppedAnimatedMedia/assets/index.js +4 -0
- package/es/components/SteppedAnimatedMedia/index.js +8 -0
- package/es/global/js/package-settings.js +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridContent.js +12 -9
- package/lib/components/Datagrid/Datagrid/DatagridExpandedRow.js +4 -4
- package/lib/components/Datagrid/Datagrid/DatagridHeaderRow.js +45 -32
- package/lib/components/Datagrid/Datagrid/DatagridRefBody.js +4 -1
- package/lib/components/Datagrid/Datagrid/DatagridRow.js +5 -2
- package/lib/components/Datagrid/Datagrid/DatagridSelectAll.js +11 -11
- package/lib/components/Datagrid/Datagrid/DatagridSimpleBody.js +4 -1
- package/lib/components/Datagrid/Datagrid/DatagridVirtualBody.js +33 -27
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/DraggableItemsList.js +2 -2
- package/lib/components/Datagrid/Datagrid/addons/stateReducer.js +51 -15
- package/lib/components/Datagrid/Datagrid.docs-page.js +8 -2
- package/lib/components/Datagrid/useActionsColumn.js +7 -5
- package/lib/components/Datagrid/useDatagrid.js +13 -1
- package/lib/components/Datagrid/useInfiniteScroll.js +9 -9
- package/lib/components/Datagrid/useOnRowClick.js +6 -7
- package/lib/components/Datagrid/useParentDimensions.js +5 -6
- package/lib/components/Datagrid/useResizeTable.js +6 -7
- package/lib/components/Datagrid/useSelectRows.js +8 -5
- package/lib/components/Datagrid/useSkeletonRows.js +6 -6
- package/lib/components/Datagrid/useSortableColumns.js +5 -7
- package/lib/components/Datagrid/useStickyColumn.js +13 -6
- package/lib/components/EmptyStates/ErrorEmptyState/ErrorEmptyState.js +2 -1
- package/lib/components/EmptyStates/NoTagsEmptyState/NoTagsEmptyState.js +2 -1
- package/lib/components/EmptyStates/NotFoundEmptyState/NotFoundEmptyState.js +2 -1
- package/lib/components/EmptyStates/NotificationsEmptyState/NotificationsEmptyState.js +2 -1
- package/lib/components/EmptyStates/UnauthorizedEmptyState/UnauthorizedEmptyState.js +2 -1
- package/lib/components/EmptyStates/assets/ErrorIllustration.js +5 -3
- package/lib/components/EmptyStates/assets/NoDataIllustration.js +5 -3
- package/lib/components/EmptyStates/assets/NoTagsIllustration.js +5 -3
- package/lib/components/EmptyStates/assets/NotFoundIllustration.js +5 -3
- package/lib/components/EmptyStates/assets/NotificationsIllustration.js +5 -3
- package/lib/components/EmptyStates/assets/UnauthorizedIllustration.js +5 -3
- package/lib/components/InlineTip/InlineTip.docs-page.js +23 -0
- package/lib/components/InlineTip/InlineTip.js +224 -0
- package/lib/components/InlineTip/InlineTipButton.js +57 -0
- package/lib/components/InlineTip/InlineTipLink.js +61 -0
- package/lib/components/InlineTip/index.js +26 -0
- package/lib/components/InlineTip/utils.js +43 -0
- package/lib/components/SteppedAnimatedMedia/SteppedAnimatedMedia.docs-page.js +21 -0
- package/lib/components/SteppedAnimatedMedia/SteppedAnimatedMedia.js +148 -0
- package/lib/components/SteppedAnimatedMedia/assets/index.js +9 -0
- package/lib/components/SteppedAnimatedMedia/index.js +12 -0
- package/lib/global/js/package-settings.js +2 -1
- package/package.json +2 -2
- package/scss/components/Datagrid/styles/_datagrid.scss +31 -5
- package/scss/components/InlineTip/_index.scss +8 -0
- package/scss/components/InlineTip/_inline-tip.scss +229 -0
- package/scss/components/InlineTip/_storybook-styles.scss +20 -0
- package/scss/components/SidePanel/_side-panel.scss +1 -4
- package/scss/components/SteppedAnimatedMedia/_index.scss +8 -0
- package/scss/components/SteppedAnimatedMedia/_stepped-animated-media.scss +6 -0
- package/scss/components/SteppedAnimatedMedia/_storybook-styles.scss +13 -0
- package/scss/components/_index.scss +1 -0
@@ -1,10 +1,10 @@
|
|
1
|
-
|
2
|
-
*
|
3
|
-
*
|
4
|
-
*
|
5
|
-
*
|
6
|
-
* restricted by GSA ADP Schedule Contract with IBM Corp.
|
1
|
+
/**
|
2
|
+
* Copyright IBM Corp. 2020, 2023
|
3
|
+
*
|
4
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
7
6
|
*/
|
7
|
+
|
8
8
|
import { useLayoutEffect } from 'react';
|
9
9
|
var useResizeTable = function useResizeTable(hooks) {
|
10
10
|
var useInstanceBeforeDimensions = function useInstanceBeforeDimensions(instance) {
|
@@ -26,7 +26,7 @@ var useResizeTable = function useResizeTable(hooks) {
|
|
26
26
|
resizeObserver = null;
|
27
27
|
};
|
28
28
|
}
|
29
|
-
return console.error('
|
29
|
+
return console.error('Could not resize table, no support for ResizeObserver');
|
30
30
|
}, [handleResize, parent]);
|
31
31
|
};
|
32
32
|
hooks.useInstanceBeforeDimensions.push(useInstanceBeforeDimensions);
|
@@ -20,6 +20,7 @@ import { TableSelectRow } from '@carbon/react';
|
|
20
20
|
import { SelectAll } from './Datagrid/DatagridSelectAll';
|
21
21
|
import { selectionColumnId } from './common-column-ids';
|
22
22
|
import { pkg, carbon } from '../../settings';
|
23
|
+
import { handleToggleRowSelected } from './Datagrid/addons/stateReducer';
|
23
24
|
var blockClass = "".concat(pkg.prefix, "--datagrid");
|
24
25
|
var checkboxClass = "".concat(pkg.prefix, "--datagrid__checkbox-cell");
|
25
26
|
var useSelectRows = function useSelectRows(hooks) {
|
@@ -77,7 +78,8 @@ var SelectRow = function SelectRow(datagridState) {
|
|
77
78
|
onRadioSelect = datagridState.onRadioSelect,
|
78
79
|
onRowSelect = datagridState.onRowSelect,
|
79
80
|
columns = datagridState.columns,
|
80
|
-
withStickyColumn = datagridState.withStickyColumn
|
81
|
+
withStickyColumn = datagridState.withStickyColumn,
|
82
|
+
dispatch = datagridState.dispatch;
|
81
83
|
var _useState = useState(window.innerWidth),
|
82
84
|
_useState2 = _slicedToArray(_useState, 2),
|
83
85
|
windowSize = _useState2[0],
|
@@ -91,16 +93,17 @@ var SelectRow = function SelectRow(datagridState) {
|
|
91
93
|
return window.removeEventListener('resize', updateSize);
|
92
94
|
};
|
93
95
|
}, []);
|
94
|
-
var onSelectHandler = function onSelectHandler(
|
95
|
-
|
96
|
+
var onSelectHandler = function onSelectHandler(event) {
|
97
|
+
event.stopPropagation(); // avoid triggering onRowClick
|
96
98
|
if (radio) {
|
97
99
|
toggleAllRowsSelected(false);
|
98
100
|
if (onRadioSelect) {
|
99
101
|
onRadioSelect(row);
|
100
102
|
}
|
101
103
|
}
|
102
|
-
onChange(
|
103
|
-
onRowSelect === null || onRowSelect === void 0 || onRowSelect(row,
|
104
|
+
onChange(event);
|
105
|
+
onRowSelect === null || onRowSelect === void 0 || onRowSelect(row, event);
|
106
|
+
handleToggleRowSelected(dispatch, row, event.target.checked);
|
104
107
|
};
|
105
108
|
var selectDisabled = isFetching || row.getRowProps().disabled;
|
106
109
|
var _row$getToggleRowSele2 = row.getToggleRowSelectedProps(),
|
@@ -1,11 +1,11 @@
|
|
1
1
|
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
2
|
-
|
3
|
-
*
|
4
|
-
*
|
5
|
-
*
|
6
|
-
*
|
7
|
-
* restricted by GSA ADP Schedule Contract with IBM Corp.
|
2
|
+
/**
|
3
|
+
* Copyright IBM Corp. 2020, 2023
|
4
|
+
*
|
5
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
6
|
+
* LICENSE file in the root directory of this source tree.
|
8
7
|
*/
|
8
|
+
|
9
9
|
var useSkeletons = function useSkeletons(hooks) {
|
10
10
|
var useInstance = function useInstance(instance) {
|
11
11
|
var isFetching = instance.isFetching,
|
@@ -28,9 +28,8 @@ var getAriaSortValue = function getAriaSortValue(col, _ref) {
|
|
28
28
|
if (!col) {
|
29
29
|
return;
|
30
30
|
}
|
31
|
-
var
|
32
|
-
|
33
|
-
isSortedDesc = _ref2.isSortedDesc;
|
31
|
+
var isSorted = col.isSorted,
|
32
|
+
isSortedDesc = col.isSortedDesc;
|
34
33
|
if (!isSorted) {
|
35
34
|
return defaultSortableLabelText;
|
36
35
|
}
|
@@ -45,17 +44,16 @@ var getAriaPressedValue = function getAriaPressedValue(col) {
|
|
45
44
|
if (!col) {
|
46
45
|
return;
|
47
46
|
}
|
48
|
-
var
|
49
|
-
isSorted = _ref3.isSorted;
|
47
|
+
var isSorted = col.isSorted;
|
50
48
|
if (isSorted) {
|
51
49
|
return 'true';
|
52
50
|
}
|
53
51
|
return 'false';
|
54
52
|
};
|
55
53
|
var useSortableColumns = function useSortableColumns(hooks) {
|
56
|
-
var sortableVisibleColumns = function sortableVisibleColumns(visibleColumns,
|
54
|
+
var sortableVisibleColumns = function sortableVisibleColumns(visibleColumns, _ref2) {
|
57
55
|
var _instance$customizeCo;
|
58
|
-
var instance =
|
56
|
+
var instance = _ref2.instance;
|
59
57
|
var onSort = instance.onSort,
|
60
58
|
ascendingSortableLabelText = instance.ascendingSortableLabelText,
|
61
59
|
descendingSortableLabelText = instance.descendingSortableLabelText,
|
@@ -2,12 +2,11 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
3
3
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
4
4
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
5
|
-
|
6
|
-
*
|
7
|
-
*
|
8
|
-
*
|
9
|
-
*
|
10
|
-
* restricted by GSA ADP Schedule Contract with IBM Corp.
|
5
|
+
/**
|
6
|
+
* Copyright IBM Corp. 2021, 2023
|
7
|
+
*
|
8
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
9
|
+
* LICENSE file in the root directory of this source tree.
|
11
10
|
*/
|
12
11
|
|
13
12
|
import { useEffect, useRef, useLayoutEffect, useState } from 'react';
|
@@ -29,9 +28,11 @@ var useStickyColumn = function useStickyColumn(hooks) {
|
|
29
28
|
setWindowSize(window.innerWidth);
|
30
29
|
}, []);
|
31
30
|
useLayoutEffect(function () {
|
31
|
+
/* istanbul ignore next */
|
32
32
|
function updateSize() {
|
33
33
|
setWindowSize(window.innerWidth);
|
34
34
|
}
|
35
|
+
/* istanbul ignore next */
|
35
36
|
window.addEventListener('resize', updateSize);
|
36
37
|
return function () {
|
37
38
|
return window.removeEventListener('resize', updateSize);
|
@@ -52,14 +53,17 @@ var useStickyColumn = function useStickyColumn(hooks) {
|
|
52
53
|
useEffect(function () {
|
53
54
|
var tableBodyElement = tableBodyRef.current;
|
54
55
|
var headerCellElement = stickyHeaderCellRef.current;
|
56
|
+
/* istanbul ignore next */
|
55
57
|
if (hasVertScroll(tableBodyElement) && headerCellElement) {
|
56
58
|
headerCellElement.classList.add(OFFSET_SCROLL_CLASS);
|
57
59
|
}
|
58
60
|
var boundListener = debounce(onBodyResize.bind(null, tableBodyElement, headerCellElement), 250);
|
61
|
+
/* istanbul ignore next */
|
59
62
|
if (typeof window !== 'undefined') {
|
60
63
|
window.addEventListener('resize', boundListener);
|
61
64
|
}
|
62
65
|
return function () {
|
66
|
+
/* istanbul ignore next */
|
63
67
|
if (typeof window !== 'undefined') {
|
64
68
|
window.removeEventListener('resize', boundListener);
|
65
69
|
}
|
@@ -158,6 +162,7 @@ var changeProps = function changeProps(elementName, headerCellRef, windowSize, p
|
|
158
162
|
};
|
159
163
|
var onBodyResize = function onBodyResize(tableBodyEle, headerCellEle) {
|
160
164
|
if (headerCellEle) {
|
165
|
+
/* istanbul ignore next */
|
161
166
|
if (hasVertScroll(tableBodyEle)) {
|
162
167
|
headerCellEle.classList.add(OFFSET_SCROLL_CLASS);
|
163
168
|
} else {
|
@@ -167,6 +172,7 @@ var onBodyResize = function onBodyResize(tableBodyEle, headerCellEle) {
|
|
167
172
|
}
|
168
173
|
};
|
169
174
|
var toggleStickyShadow = function toggleStickyShadow(tableBodyEle, headerCellEle) {
|
175
|
+
/* istanbul ignore next */
|
170
176
|
if (tableBodyEle && headerCellEle) {
|
171
177
|
var isScrolledToRight = tableBodyEle.scrollLeft + tableBodyEle.clientWidth === tableBodyEle.scrollWidth;
|
172
178
|
if (isScrolledToRight) {
|
@@ -179,6 +185,7 @@ var toggleStickyShadow = function toggleStickyShadow(tableBodyEle, headerCellEle
|
|
179
185
|
}
|
180
186
|
};
|
181
187
|
var hasVertScroll = function hasVertScroll(element) {
|
188
|
+
/* istanbul ignore next */
|
182
189
|
if (!element) {
|
183
190
|
return false;
|
184
191
|
}
|
@@ -48,7 +48,8 @@ export var ErrorEmptyState = /*#__PURE__*/React.forwardRef(function (_ref, ref)
|
|
48
48
|
ref: ref
|
49
49
|
}, getDevtoolsProps(componentName)), /*#__PURE__*/React.createElement(ErrorIllustration, {
|
50
50
|
theme: illustrationTheme,
|
51
|
-
size: size
|
51
|
+
size: size,
|
52
|
+
title: title
|
52
53
|
}), /*#__PURE__*/React.createElement(EmptyStateContent, {
|
53
54
|
action: action,
|
54
55
|
link: link,
|
@@ -48,7 +48,8 @@ export var NoTagsEmptyState = /*#__PURE__*/React.forwardRef(function (_ref, ref)
|
|
48
48
|
ref: ref
|
49
49
|
}, getDevtoolsProps(componentName)), /*#__PURE__*/React.createElement(NoTagsIllustration, {
|
50
50
|
theme: illustrationTheme,
|
51
|
-
size: size
|
51
|
+
size: size,
|
52
|
+
title: title
|
52
53
|
}), /*#__PURE__*/React.createElement(EmptyStateContent, {
|
53
54
|
action: action,
|
54
55
|
link: link,
|
@@ -48,7 +48,8 @@ export var NotFoundEmptyState = /*#__PURE__*/React.forwardRef(function (_ref, re
|
|
48
48
|
ref: ref
|
49
49
|
}, getDevtoolsProps(componentName)), /*#__PURE__*/React.createElement(NotFoundIllustration, {
|
50
50
|
theme: illustrationTheme,
|
51
|
-
size: size
|
51
|
+
size: size,
|
52
|
+
title: title
|
52
53
|
}), /*#__PURE__*/React.createElement(EmptyStateContent, {
|
53
54
|
action: action,
|
54
55
|
link: link,
|
@@ -48,7 +48,8 @@ export var NotificationsEmptyState = /*#__PURE__*/React.forwardRef(function (_re
|
|
48
48
|
ref: ref
|
49
49
|
}, getDevtoolsProps(componentName)), /*#__PURE__*/React.createElement(NotificationsIllustration, {
|
50
50
|
size: size,
|
51
|
-
theme: illustrationTheme
|
51
|
+
theme: illustrationTheme,
|
52
|
+
title: title
|
52
53
|
}), /*#__PURE__*/React.createElement(EmptyStateContent, {
|
53
54
|
action: action,
|
54
55
|
link: link,
|
@@ -48,7 +48,8 @@ export var UnauthorizedEmptyState = /*#__PURE__*/React.forwardRef(function (_ref
|
|
48
48
|
ref: ref
|
49
49
|
}, getDevtoolsProps(componentName)), /*#__PURE__*/React.createElement(UnauthorizedIllustration, {
|
50
50
|
size: size,
|
51
|
-
theme: illustrationTheme
|
51
|
+
theme: illustrationTheme,
|
52
|
+
title: title
|
52
53
|
}), /*#__PURE__*/React.createElement(EmptyStateContent, {
|
53
54
|
action: action,
|
54
55
|
link: link,
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
3
|
-
var _excluded = ["theme", "size"];
|
3
|
+
var _excluded = ["theme", "title", "size"];
|
4
4
|
/**
|
5
5
|
* Copyright IBM Corp. 2020, 2021
|
6
6
|
*
|
@@ -21,6 +21,7 @@ import uuidv4 from '../../../global/js/utils/uuidv4';
|
|
21
21
|
var blockClass = "".concat(pkg.prefix, "--empty-state");
|
22
22
|
export var ErrorIllustration = function ErrorIllustration(_ref) {
|
23
23
|
var theme = _ref.theme,
|
24
|
+
title = _ref.title,
|
24
25
|
size = _ref.size,
|
25
26
|
rest = _objectWithoutProperties(_ref, _excluded);
|
26
27
|
var svgId = uuidv4();
|
@@ -31,7 +32,7 @@ export var ErrorIllustration = function ErrorIllustration(_ref) {
|
|
31
32
|
viewBox: "0 0 80 80",
|
32
33
|
className: cx(["".concat(blockClass, "__illustration"), "".concat(blockClass, "__illustration-error"), "".concat(blockClass, "__illustration--").concat(size)]),
|
33
34
|
role: "img"
|
34
|
-
}), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
35
|
+
}), /*#__PURE__*/React.createElement("title", null, title), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
35
36
|
id: "prefix__a_dark_".concat(svgId),
|
36
37
|
x1: 38.9,
|
37
38
|
y1: 77.08,
|
@@ -209,5 +210,6 @@ export var ErrorIllustration = function ErrorIllustration(_ref) {
|
|
209
210
|
};
|
210
211
|
ErrorIllustration.propTypes = {
|
211
212
|
size: PropTypes.oneOf(['lg', 'sm']),
|
212
|
-
theme: PropTypes.oneOf(['light', 'dark'])
|
213
|
+
theme: PropTypes.oneOf(['light', 'dark']),
|
214
|
+
title: PropTypes.string
|
213
215
|
};
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
3
|
-
var _excluded = ["theme", "size"];
|
3
|
+
var _excluded = ["theme", "title", "size"];
|
4
4
|
/**
|
5
5
|
* Copyright IBM Corp. 2020, 2021
|
6
6
|
*
|
@@ -21,6 +21,7 @@ import uuidv4 from '../../../global/js/utils/uuidv4';
|
|
21
21
|
var blockClass = "".concat(pkg.prefix, "--empty-state");
|
22
22
|
export var NoDataIllustration = function NoDataIllustration(_ref) {
|
23
23
|
var theme = _ref.theme,
|
24
|
+
title = _ref.title,
|
24
25
|
size = _ref.size,
|
25
26
|
rest = _objectWithoutProperties(_ref, _excluded);
|
26
27
|
var svgId = uuidv4();
|
@@ -31,7 +32,7 @@ export var NoDataIllustration = function NoDataIllustration(_ref) {
|
|
31
32
|
viewBox: "0 0 80 80",
|
32
33
|
className: cx(["".concat(blockClass, "__illustration"), "".concat(blockClass, "__illustration-noData"), "".concat(blockClass, "__illustration--").concat(size)]),
|
33
34
|
role: "img"
|
34
|
-
}), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
35
|
+
}), /*#__PURE__*/React.createElement("title", null, title), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
35
36
|
id: "prefix__a_dark_".concat(svgId),
|
36
37
|
x1: 11.12,
|
37
38
|
y1: 43.34,
|
@@ -172,5 +173,6 @@ export var NoDataIllustration = function NoDataIllustration(_ref) {
|
|
172
173
|
};
|
173
174
|
NoDataIllustration.propTypes = {
|
174
175
|
size: PropTypes.oneOf(['lg', 'sm']),
|
175
|
-
theme: PropTypes.oneOf(['light', 'dark'])
|
176
|
+
theme: PropTypes.oneOf(['light', 'dark']),
|
177
|
+
title: PropTypes.string
|
176
178
|
};
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
3
|
-
var _excluded = ["theme", "size"];
|
3
|
+
var _excluded = ["theme", "title", "size"];
|
4
4
|
/**
|
5
5
|
* Copyright IBM Corp. 2020, 2021
|
6
6
|
*
|
@@ -21,6 +21,7 @@ import uuidv4 from '../../../global/js/utils/uuidv4';
|
|
21
21
|
var blockClass = "".concat(pkg.prefix, "--empty-state");
|
22
22
|
export var NoTagsIllustration = function NoTagsIllustration(_ref) {
|
23
23
|
var theme = _ref.theme,
|
24
|
+
title = _ref.title,
|
24
25
|
size = _ref.size,
|
25
26
|
rest = _objectWithoutProperties(_ref, _excluded);
|
26
27
|
var svgId = uuidv4();
|
@@ -32,7 +33,7 @@ export var NoTagsIllustration = function NoTagsIllustration(_ref) {
|
|
32
33
|
viewBox: "0 0 80 80",
|
33
34
|
className: cx(["".concat(blockClass, "__illustration"), "".concat(blockClass, "__illustration-noTags"), "".concat(blockClass, "__illustration--").concat(size)]),
|
34
35
|
role: "img"
|
35
|
-
}), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
36
|
+
}), /*#__PURE__*/React.createElement("title", null, title), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
36
37
|
id: "prefix__c_dark_".concat(svgId),
|
37
38
|
x1: 34.96,
|
38
39
|
y1: 5.37,
|
@@ -479,5 +480,6 @@ export var NoTagsIllustration = function NoTagsIllustration(_ref) {
|
|
479
480
|
};
|
480
481
|
NoTagsIllustration.propTypes = {
|
481
482
|
size: PropTypes.oneOf(['lg', 'sm']),
|
482
|
-
theme: PropTypes.oneOf(['light', 'dark'])
|
483
|
+
theme: PropTypes.oneOf(['light', 'dark']),
|
484
|
+
title: PropTypes.string
|
483
485
|
};
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
3
|
-
var _excluded = ["theme", "size"];
|
3
|
+
var _excluded = ["theme", "title", "size"];
|
4
4
|
/**
|
5
5
|
* Copyright IBM Corp. 2020, 2021
|
6
6
|
*
|
@@ -21,6 +21,7 @@ import uuidv4 from '../../../global/js/utils/uuidv4';
|
|
21
21
|
var blockClass = "".concat(pkg.prefix, "--empty-state");
|
22
22
|
export var NotFoundIllustration = function NotFoundIllustration(_ref) {
|
23
23
|
var theme = _ref.theme,
|
24
|
+
title = _ref.title,
|
24
25
|
size = _ref.size,
|
25
26
|
rest = _objectWithoutProperties(_ref, _excluded);
|
26
27
|
var svgId = uuidv4();
|
@@ -31,7 +32,7 @@ export var NotFoundIllustration = function NotFoundIllustration(_ref) {
|
|
31
32
|
viewBox: "0 0 80 80",
|
32
33
|
className: cx(["".concat(blockClass, "__illustration"), "".concat(blockClass, "__illustration-notFound"), "".concat(blockClass, "__illustration--").concat(size)]),
|
33
34
|
role: "img"
|
34
|
-
}), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
35
|
+
}), /*#__PURE__*/React.createElement("title", null, title), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
35
36
|
id: "prefix__a_dark_".concat(svgId),
|
36
37
|
x1: 2.6,
|
37
38
|
y1: -12.81,
|
@@ -356,5 +357,6 @@ export var NotFoundIllustration = function NotFoundIllustration(_ref) {
|
|
356
357
|
};
|
357
358
|
NotFoundIllustration.propTypes = {
|
358
359
|
size: PropTypes.oneOf(['lg', 'sm']),
|
359
|
-
theme: PropTypes.oneOf(['light', 'dark'])
|
360
|
+
theme: PropTypes.oneOf(['light', 'dark']),
|
361
|
+
title: PropTypes.string
|
360
362
|
};
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
3
|
-
var _excluded = ["theme", "size"];
|
3
|
+
var _excluded = ["theme", "title", "size"];
|
4
4
|
/**
|
5
5
|
* Copyright IBM Corp. 2020, 2021
|
6
6
|
*
|
@@ -21,6 +21,7 @@ import uuidv4 from '../../../global/js/utils/uuidv4';
|
|
21
21
|
var blockClass = "".concat(pkg.prefix, "--empty-state");
|
22
22
|
export var NotificationsIllustration = function NotificationsIllustration(_ref) {
|
23
23
|
var theme = _ref.theme,
|
24
|
+
title = _ref.title,
|
24
25
|
size = _ref.size,
|
25
26
|
rest = _objectWithoutProperties(_ref, _excluded);
|
26
27
|
var svgId = uuidv4();
|
@@ -31,7 +32,7 @@ export var NotificationsIllustration = function NotificationsIllustration(_ref)
|
|
31
32
|
viewBox: "0 0 80 80",
|
32
33
|
className: cx(["".concat(blockClass, "__illustration"), "".concat(blockClass, "__illustration-notification"), "".concat(blockClass, "__illustration--").concat(size)]),
|
33
34
|
role: "img"
|
34
|
-
}), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
35
|
+
}), /*#__PURE__*/React.createElement("title", null, title), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
35
36
|
id: "prefix__a_dark_".concat(svgId),
|
36
37
|
x1: 30.05,
|
37
38
|
y1: 54.31,
|
@@ -327,5 +328,6 @@ export var NotificationsIllustration = function NotificationsIllustration(_ref)
|
|
327
328
|
};
|
328
329
|
NotificationsIllustration.propTypes = {
|
329
330
|
size: PropTypes.oneOf(['lg', 'sm']),
|
330
|
-
theme: PropTypes.oneOf(['light', 'dark'])
|
331
|
+
theme: PropTypes.oneOf(['light', 'dark']),
|
332
|
+
title: PropTypes.string
|
331
333
|
};
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
3
|
-
var _excluded = ["theme", "size"];
|
3
|
+
var _excluded = ["theme", "title", "size"];
|
4
4
|
/**
|
5
5
|
* Copyright IBM Corp. 2020, 2021
|
6
6
|
*
|
@@ -21,6 +21,7 @@ import uuidv4 from '../../../global/js/utils/uuidv4';
|
|
21
21
|
var blockClass = "".concat(pkg.prefix, "--empty-state");
|
22
22
|
export var UnauthorizedIllustration = function UnauthorizedIllustration(_ref) {
|
23
23
|
var theme = _ref.theme,
|
24
|
+
title = _ref.title,
|
24
25
|
size = _ref.size,
|
25
26
|
rest = _objectWithoutProperties(_ref, _excluded);
|
26
27
|
var svgId = uuidv4();
|
@@ -32,7 +33,7 @@ export var UnauthorizedIllustration = function UnauthorizedIllustration(_ref) {
|
|
32
33
|
viewBox: "0 0 80 80",
|
33
34
|
className: cx(["".concat(blockClass, "__illustration"), "".concat(blockClass, "__illustration-unauthorized"), "".concat(blockClass, "__illustration--").concat(size)]),
|
34
35
|
role: "img"
|
35
|
-
}), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
36
|
+
}), /*#__PURE__*/React.createElement("title", null, title), theme === 'dark' ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("linearGradient", {
|
36
37
|
id: "prefix__b_dark_".concat(svgId),
|
37
38
|
x1: 17.33,
|
38
39
|
y1: 40.68,
|
@@ -300,5 +301,6 @@ export var UnauthorizedIllustration = function UnauthorizedIllustration(_ref) {
|
|
300
301
|
};
|
301
302
|
UnauthorizedIllustration.propTypes = {
|
302
303
|
size: PropTypes.oneOf(['lg', 'sm']),
|
303
|
-
theme: PropTypes.oneOf(['light', 'dark'])
|
304
|
+
theme: PropTypes.oneOf(['light', 'dark']),
|
305
|
+
title: PropTypes.string
|
304
306
|
};
|
@@ -0,0 +1,13 @@
|
|
1
|
+
import React from 'react';
|
2
|
+
import { StoryDocsPage } from '../../global/js/utils/StoryDocsPage';
|
3
|
+
import * as stories from './InlineTip.stories';
|
4
|
+
var DocsPage = function DocsPage() {
|
5
|
+
return /*#__PURE__*/React.createElement(StoryDocsPage, {
|
6
|
+
blocks: [{
|
7
|
+
story: stories.inlineTip
|
8
|
+
}, {
|
9
|
+
story: stories.inlineTipNarrow
|
10
|
+
}]
|
11
|
+
});
|
12
|
+
};
|
13
|
+
export default DocsPage;
|