@carbon/ibm-products 2.43.2-canary.305 → 2.43.2-canary.307
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/css/index-full-carbon.css +206 -268
- 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 +3 -3
- package/css/index-without-carbon-released-only.min.css +1 -1
- package/css/index-without-carbon.css +10 -14
- 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 +85 -94
- 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/APIKeyModal/APIKeyDownloader.d.ts +2 -1
- package/es/components/AboutModal/AboutModal.js +1 -3
- package/es/components/ActionBar/ActionBarOverflowItems.d.ts +2 -2
- package/es/components/AddSelect/AddSelectBreadcrumbs.d.ts +2 -1
- package/es/components/AddSelect/AddSelectColumn.d.ts +2 -1
- package/es/components/AddSelect/AddSelectFilter.d.ts +2 -1
- package/es/components/AddSelect/AddSelectFilter.js +5 -5
- package/es/components/AddSelect/AddSelectFormControl.d.ts +2 -1
- package/es/components/AddSelect/AddSelectList.d.ts +2 -1
- package/es/components/AddSelect/AddSelectMetaPanel.d.ts +2 -1
- package/es/components/AddSelect/AddSelectRow.d.ts +2 -1
- package/es/components/AddSelect/AddSelectSidebar.d.ts +2 -1
- package/es/components/AddSelect/AddSelectSort.d.ts +2 -1
- package/es/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.d.ts +2 -1
- package/es/components/ButtonSetWithOverflow/ButtonSetWithOverflow.d.ts +2 -1
- package/es/components/Card/CardFooter.d.ts +1 -1
- package/es/components/Card/CardHeader.d.ts +1 -1
- package/es/components/ComboButton/ComboButtonItem/index.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionBlock/ConditionBlock.d.ts +1 -1
- package/es/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.d.ts +1 -1
- package/es/components/ConditionBuilder/ConditionBuilderConnector/ConditionConnector.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionBuilderConnector/GroupConnector.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.d.ts +1 -1
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemNumber/ConditionBuilderItemNumber.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOptionForValueField.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemTime/ConditionBuilderItemTime.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.d.ts +2 -1
- package/es/components/ConditionBuilder/ConditionPreview/ConditionPreview.d.ts +2 -1
- package/es/components/CreateInfluencer/CreateInfluencer.d.ts +2 -2
- package/es/components/Datagrid/Datagrid/DatagridBody.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/DatagridContent.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/DatagridEmptyBody.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/DatagridExpandedRow.d.ts +2 -2
- package/es/components/Datagrid/Datagrid/DatagridHead.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/DatagridRefBody.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/DatagridRow.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/DatagridSelectAll.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/DatagridSelectAllWithToggle.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/DatagridSimpleBody.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/DatagridToolbar.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/DatagridVirtualBody.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/DraggableElement.d.ts +2 -2
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/Actions.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/ButtonWrapper.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/Columns.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/DraggableItemsList.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/TearsheetWrapper.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.d.ts +1 -1
- package/es/components/Datagrid/Datagrid/addons/Filtering/OverflowCheckboxes.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.d.ts +1 -1
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.d.ts +2 -1
- package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/InlineEditContext.d.ts +1 -1
- package/es/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.d.ts +2 -1
- package/es/components/EmptyStates/EmptyStateContent.d.ts +2 -1
- package/es/components/EmptyStates/EmptyStateIllustration.d.ts +2 -1
- package/es/components/EmptyStates/assets/ErrorIllustration.d.ts +2 -1
- package/es/components/EmptyStates/assets/NoDataIllustration.d.ts +2 -1
- package/es/components/EmptyStates/assets/NoTagsIllustration.d.ts +2 -1
- package/es/components/EmptyStates/assets/NotFoundIllustration.d.ts +2 -1
- package/es/components/EmptyStates/assets/NotificationsIllustration.d.ts +2 -1
- package/es/components/EmptyStates/assets/UnauthorizedIllustration.d.ts +2 -1
- package/es/components/ExportModal/ExportModal.js +1 -3
- package/es/components/FeatureFlags/index.d.ts +5 -4
- package/es/components/FeatureFlags/index.js +17 -10
- package/es/components/FullPageError/assets/Error403SVG.d.ts +2 -1
- package/es/components/FullPageError/assets/Error404SVG.d.ts +2 -1
- package/es/components/FullPageError/assets/ErrorGenericSVG.d.ts +2 -1
- package/es/components/HTTPErrors/HTTPErrorContent.d.ts +2 -1
- package/es/components/HTTPErrors/assets/HTTPErrorSvg403.d.ts +2 -1
- package/es/components/HTTPErrors/assets/HTTPErrorSvg404.d.ts +2 -1
- package/es/components/HTTPErrors/assets/HTTPErrorSvgOther.d.ts +2 -1
- package/es/components/Nav/NavItem.d.ts +2 -1
- package/es/components/PageHeader/PageHeaderTitle.d.ts +2 -1
- package/es/components/SimpleHeader/SimpleHeader.d.ts +2 -1
- package/es/components/TagOverflow/TagOverflow.d.ts +3 -0
- package/es/components/TagOverflow/TagOverflow.js +9 -4
- package/es/components/TagOverflow/TagOverflowModal.d.ts +6 -1
- package/es/components/TagOverflow/TagOverflowModal.js +17 -6
- package/es/components/TagOverflow/TagOverflowPopover.js +17 -9
- package/es/components/TagSet/TagSet.d.ts +4 -0
- package/es/components/TagSet/TagSet.js +20 -8
- package/es/components/TagSet/TagSetModal.js +0 -1
- package/es/components/Tearsheet/TearsheetShell.js +1 -3
- package/es/components/TooltipTrigger/TooltipTrigger.d.ts +2 -1
- package/es/components/_Canary/Canary.d.ts +2 -1
- package/es/node_modules/@carbon/icons-react/es/generated/bucket-9.js +742 -740
- package/lib/components/APIKeyModal/APIKeyDownloader.d.ts +2 -1
- package/lib/components/AboutModal/AboutModal.js +1 -3
- package/lib/components/ActionBar/ActionBarOverflowItems.d.ts +2 -2
- package/lib/components/AddSelect/AddSelectBreadcrumbs.d.ts +2 -1
- package/lib/components/AddSelect/AddSelectColumn.d.ts +2 -1
- package/lib/components/AddSelect/AddSelectFilter.d.ts +2 -1
- package/lib/components/AddSelect/AddSelectFilter.js +4 -4
- package/lib/components/AddSelect/AddSelectFormControl.d.ts +2 -1
- package/lib/components/AddSelect/AddSelectList.d.ts +2 -1
- package/lib/components/AddSelect/AddSelectMetaPanel.d.ts +2 -1
- package/lib/components/AddSelect/AddSelectRow.d.ts +2 -1
- package/lib/components/AddSelect/AddSelectSidebar.d.ts +2 -1
- package/lib/components/AddSelect/AddSelectSort.d.ts +2 -1
- package/lib/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.d.ts +2 -1
- package/lib/components/ButtonSetWithOverflow/ButtonSetWithOverflow.d.ts +2 -1
- package/lib/components/Card/CardFooter.d.ts +1 -1
- package/lib/components/Card/CardHeader.d.ts +1 -1
- package/lib/components/ComboButton/ComboButtonItem/index.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionBlock/ConditionBlock.d.ts +1 -1
- package/lib/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.d.ts +1 -1
- package/lib/components/ConditionBuilder/ConditionBuilderConnector/ConditionConnector.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionBuilderConnector/GroupConnector.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.d.ts +1 -1
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemNumber/ConditionBuilderItemNumber.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOptionForValueField.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemTime/ConditionBuilderItemTime.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.d.ts +2 -1
- package/lib/components/ConditionBuilder/ConditionPreview/ConditionPreview.d.ts +2 -1
- package/lib/components/CreateInfluencer/CreateInfluencer.d.ts +2 -2
- package/lib/components/Datagrid/Datagrid/DatagridBody.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridContent.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridEmptyBody.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridExpandedRow.d.ts +2 -2
- package/lib/components/Datagrid/Datagrid/DatagridHead.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridRefBody.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridRow.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridSelectAll.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridSelectAllWithToggle.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridSimpleBody.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridToolbar.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/DatagridVirtualBody.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/DraggableElement.d.ts +2 -2
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/Actions.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/ButtonWrapper.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/Columns.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/DraggableItemsList.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/TearsheetWrapper.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.d.ts +1 -1
- package/lib/components/Datagrid/Datagrid/addons/Filtering/OverflowCheckboxes.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.d.ts +1 -1
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.d.ts +2 -1
- package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/InlineEditContext.d.ts +1 -1
- package/lib/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.d.ts +2 -1
- package/lib/components/EmptyStates/EmptyStateContent.d.ts +2 -1
- package/lib/components/EmptyStates/EmptyStateIllustration.d.ts +2 -1
- package/lib/components/EmptyStates/assets/ErrorIllustration.d.ts +2 -1
- package/lib/components/EmptyStates/assets/NoDataIllustration.d.ts +2 -1
- package/lib/components/EmptyStates/assets/NoTagsIllustration.d.ts +2 -1
- package/lib/components/EmptyStates/assets/NotFoundIllustration.d.ts +2 -1
- package/lib/components/EmptyStates/assets/NotificationsIllustration.d.ts +2 -1
- package/lib/components/EmptyStates/assets/UnauthorizedIllustration.d.ts +2 -1
- package/lib/components/ExportModal/ExportModal.js +1 -3
- package/lib/components/FeatureFlags/index.d.ts +5 -4
- package/lib/components/FeatureFlags/index.js +16 -9
- package/lib/components/FullPageError/assets/Error403SVG.d.ts +2 -1
- package/lib/components/FullPageError/assets/Error404SVG.d.ts +2 -1
- package/lib/components/FullPageError/assets/ErrorGenericSVG.d.ts +2 -1
- package/lib/components/HTTPErrors/HTTPErrorContent.d.ts +2 -1
- package/lib/components/HTTPErrors/assets/HTTPErrorSvg403.d.ts +2 -1
- package/lib/components/HTTPErrors/assets/HTTPErrorSvg404.d.ts +2 -1
- package/lib/components/HTTPErrors/assets/HTTPErrorSvgOther.d.ts +2 -1
- package/lib/components/Nav/NavItem.d.ts +2 -1
- package/lib/components/PageHeader/PageHeaderTitle.d.ts +2 -1
- package/lib/components/SimpleHeader/SimpleHeader.d.ts +2 -1
- package/lib/components/TagOverflow/TagOverflow.d.ts +3 -0
- package/lib/components/TagOverflow/TagOverflow.js +8 -3
- package/lib/components/TagOverflow/TagOverflowModal.d.ts +6 -1
- package/lib/components/TagOverflow/TagOverflowModal.js +16 -5
- package/lib/components/TagOverflow/TagOverflowPopover.js +16 -8
- package/lib/components/TagSet/TagSet.d.ts +4 -0
- package/lib/components/TagSet/TagSet.js +19 -7
- package/lib/components/TagSet/TagSetModal.js +0 -1
- package/lib/components/Tearsheet/TearsheetShell.js +1 -3
- package/lib/components/TooltipTrigger/TooltipTrigger.d.ts +2 -1
- package/lib/components/_Canary/Canary.d.ts +2 -1
- package/lib/node_modules/@carbon/icons-react/es/generated/bucket-9.js +742 -740
- package/package.json +10 -10
@@ -2,7 +2,7 @@ export function PageHeaderTitle({ blockClass, hasBreadcrumbRow, title }: {
|
|
2
2
|
blockClass: any;
|
3
3
|
hasBreadcrumbRow: any;
|
4
4
|
title: any;
|
5
|
-
}):
|
5
|
+
}): React.JSX.Element;
|
6
6
|
export namespace PageHeaderTitle {
|
7
7
|
namespace propTypes {
|
8
8
|
let blockClass: PropTypes.Validator<string>;
|
@@ -28,4 +28,5 @@ export namespace PageHeaderTitle {
|
|
28
28
|
export function editInPlaceRequired({ onSave }: {
|
29
29
|
onSave: any;
|
30
30
|
}): boolean;
|
31
|
+
import React from 'react';
|
31
32
|
import PropTypes from 'prop-types';
|
@@ -20,7 +20,7 @@ export function SimpleHeader({ breadcrumbs, className, title, noTrailingSlash, m
|
|
20
20
|
maxVisible: any;
|
21
21
|
overflowAriaLabel: any;
|
22
22
|
overflowTooltipAlign: any;
|
23
|
-
}):
|
23
|
+
}): React.JSX.Element;
|
24
24
|
export namespace SimpleHeader {
|
25
25
|
namespace propTypes {
|
26
26
|
export let breadcrumbs: PropTypes.Requireable<(PropTypes.InferProps<{
|
@@ -43,4 +43,5 @@ export namespace SimpleHeader {
|
|
43
43
|
export let title: PropTypes.Requireable<string>;
|
44
44
|
}
|
45
45
|
}
|
46
|
+
import React from 'react';
|
46
47
|
import PropTypes from 'prop-types';
|
@@ -7,6 +7,9 @@
|
|
7
7
|
import React, { ReactNode, RefObject } from 'react';
|
8
8
|
export interface TagOverflowItem {
|
9
9
|
className?: string;
|
10
|
+
/**
|
11
|
+
* @deprecated The `filter` prop is no longer going to be used. To use DismissibleTags, pass in an onClose function.
|
12
|
+
*/
|
10
13
|
filter?: boolean;
|
11
14
|
id: string;
|
12
15
|
label: string;
|
@@ -7,7 +7,7 @@
|
|
7
7
|
|
8
8
|
import { objectWithoutProperties as _objectWithoutProperties, slicedToArray as _slicedToArray, objectSpread2 as _objectSpread2, extends as _extends, defineProperty as _defineProperty } from '../../_virtual/_rollupPluginBabelHelpers.js';
|
9
9
|
import React__default, { forwardRef, useRef, useState, useCallback, useEffect, createElement } from 'react';
|
10
|
-
import { Tooltip, Tag } from '@carbon/react';
|
10
|
+
import { Tooltip, DismissibleTag, Tag } from '@carbon/react';
|
11
11
|
import PropTypes from '../../_virtual/index.js';
|
12
12
|
import { TYPES } from './constants.js';
|
13
13
|
import { TagOverflowModal } from './TagOverflowModal.js';
|
@@ -21,7 +21,7 @@ import { useResizeObserver } from '../../global/js/hooks/useResizeObserver.js';
|
|
21
21
|
var _excluded = ["align", "allTagsModalAriaLabel", "allTagsModalSearchLabel", "allTagsModalSearchPlaceholderText", "allTagsModalTarget", "allTagsModalTitle", "autoAlign", "className", "containingElementRef", "items", "maxVisible", "measurementOffset", "multiline", "overflowAlign", "overflowClassName", "overflowType", "onOverflowTagChange", "showAllTagsLabel", "tagComponent"],
|
22
22
|
_excluded2 = ["className", "id"],
|
23
23
|
_excluded3 = ["tagType"],
|
24
|
-
_excluded4 = ["id", "label", "tagType", "onClose"];
|
24
|
+
_excluded4 = ["id", "label", "tagType", "onClose", "filter"];
|
25
25
|
var blockClass = "".concat(pkg.prefix, "--tag-overflow");
|
26
26
|
var componentName = 'TagOverflow';
|
27
27
|
var allTagsModalSearchThreshold = 10;
|
@@ -181,6 +181,7 @@ var TagOverflow = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
181
181
|
label = item.label,
|
182
182
|
tagType = item.tagType,
|
183
183
|
_onClose = item.onClose,
|
184
|
+
filter = item.filter,
|
184
185
|
other = _objectWithoutProperties(item, _excluded4);
|
185
186
|
// If there is no template prop, then render items as Tags
|
186
187
|
return /*#__PURE__*/React__default.createElement("div", {
|
@@ -191,12 +192,16 @@ var TagOverflow = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
191
192
|
}, /*#__PURE__*/React__default.createElement(Tooltip, {
|
192
193
|
align: overflowAlign,
|
193
194
|
label: label
|
194
|
-
}, /*#__PURE__*/React__default.createElement(
|
195
|
+
}, typeof _onClose === 'function' || filter ? /*#__PURE__*/React__default.createElement(DismissibleTag, _extends({}, other, {
|
195
196
|
className: "".concat(blockClass, "__item--tag"),
|
196
197
|
type: tagType,
|
197
198
|
onClose: function onClose() {
|
198
199
|
return handleTagOnClose(_onClose, index);
|
199
|
-
}
|
200
|
+
},
|
201
|
+
text: label
|
202
|
+
})) : /*#__PURE__*/React__default.createElement(Tag, _extends({}, other, {
|
203
|
+
className: "".concat(blockClass, "__item--tag"),
|
204
|
+
type: tagType
|
200
205
|
}), label)));
|
201
206
|
}
|
202
207
|
}), /*#__PURE__*/React__default.createElement("span", {
|
@@ -11,6 +11,10 @@ interface TagOverflowModalProps {
|
|
11
11
|
className?: string;
|
12
12
|
modalAriaLabel?: string;
|
13
13
|
onClose?: () => void;
|
14
|
+
onTagClose?: (params: {
|
15
|
+
label: string;
|
16
|
+
id: any;
|
17
|
+
}) => void;
|
14
18
|
open?: boolean;
|
15
19
|
overflowType?: 'default' | 'tag';
|
16
20
|
portalTarget?: ReactNode;
|
@@ -19,13 +23,14 @@ interface TagOverflowModalProps {
|
|
19
23
|
title?: string;
|
20
24
|
}
|
21
25
|
export declare const TagOverflowModal: {
|
22
|
-
({ allTags, className, title, modalAriaLabel, onClose, open, overflowType, portalTarget: portalTargetIn, searchLabel, searchPlaceholder, ...rest }: TagOverflowModalProps): any;
|
26
|
+
({ allTags, className, title, modalAriaLabel, onClose, onTagClose, open, overflowType, portalTarget: portalTargetIn, searchLabel, searchPlaceholder, ...rest }: TagOverflowModalProps): any;
|
23
27
|
propTypes: {
|
24
28
|
allTags: PropTypes.Requireable<(PropTypes.InferProps<{
|
25
29
|
label: PropTypes.Validator<string>;
|
26
30
|
}> | null | undefined)[]>;
|
27
31
|
className: PropTypes.Requireable<string>;
|
28
32
|
onClose: PropTypes.Requireable<(...args: any[]) => any>;
|
33
|
+
onTagClose: PropTypes.Requireable<(...args: any[]) => any>;
|
29
34
|
open: PropTypes.Requireable<boolean>;
|
30
35
|
overflowType: PropTypes.Requireable<string>;
|
31
36
|
portalTarget: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
@@ -9,12 +9,12 @@ import { objectSpread2 as _objectSpread2, objectWithoutProperties as _objectWith
|
|
9
9
|
import React__default, { useState } from 'react';
|
10
10
|
import PropTypes from '../../_virtual/index.js';
|
11
11
|
import cx from 'classnames';
|
12
|
-
import { Tag, ComposedModal, ModalHeader, Search, ModalBody } from '@carbon/react';
|
12
|
+
import { Tag, ComposedModal, ModalHeader, Search, ModalBody, DismissibleTag } from '@carbon/react';
|
13
13
|
import { pkg } from '../../settings.js';
|
14
14
|
import { prepareProps } from '../../global/js/utils/props-helper.js';
|
15
15
|
import { usePortalTarget } from '../../global/js/hooks/usePortalTarget.js';
|
16
16
|
|
17
|
-
var _excluded = ["allTags", "className", "title", "modalAriaLabel", "onClose", "open", "overflowType", "portalTarget", "searchLabel", "searchPlaceholder"];
|
17
|
+
var _excluded = ["allTags", "className", "title", "modalAriaLabel", "onClose", "onTagClose", "open", "overflowType", "portalTarget", "searchLabel", "searchPlaceholder"];
|
18
18
|
var componentName = 'TagOverflowModal';
|
19
19
|
var blockClass = "".concat(pkg.prefix, "--tag-overflow-modal");
|
20
20
|
|
@@ -32,6 +32,7 @@ var TagOverflowModal = function TagOverflowModal(_ref) {
|
|
32
32
|
_ref$modalAriaLabel = _ref.modalAriaLabel,
|
33
33
|
modalAriaLabel = _ref$modalAriaLabel === void 0 ? defaults.modalAriaLabel : _ref$modalAriaLabel,
|
34
34
|
onClose = _ref.onClose,
|
35
|
+
onTagClose = _ref.onTagClose,
|
35
36
|
open = _ref.open,
|
36
37
|
overflowType = _ref.overflowType,
|
37
38
|
portalTargetIn = _ref.portalTarget,
|
@@ -82,11 +83,20 @@ var TagOverflowModal = function TagOverflowModal(_ref) {
|
|
82
83
|
}, getFilteredItems().map(function (_ref2) {
|
83
84
|
var label = _ref2.label,
|
84
85
|
id = _ref2.id,
|
85
|
-
filter = _ref2.filter
|
86
|
-
|
87
|
-
|
86
|
+
filter = _ref2.filter,
|
87
|
+
onClose = _ref2.onClose;
|
88
|
+
var isFilterable = overflowType === 'tag' && (typeof onClose === 'function' || filter);
|
89
|
+
return isFilterable ? /*#__PURE__*/React__default.createElement(DismissibleTag, {
|
88
90
|
key: id,
|
89
|
-
|
91
|
+
text: label,
|
92
|
+
onClose: function onClose() {
|
93
|
+
return onTagClose === null || onTagClose === void 0 ? void 0 : onTagClose({
|
94
|
+
label: label,
|
95
|
+
id: id
|
96
|
+
});
|
97
|
+
}
|
98
|
+
}) : /*#__PURE__*/React__default.createElement(Tag, {
|
99
|
+
key: id
|
90
100
|
}, label);
|
91
101
|
}), /*#__PURE__*/React__default.createElement("div", {
|
92
102
|
className: "".concat(blockClass, "__fade")
|
@@ -98,6 +108,7 @@ TagOverflowModal.propTypes = {
|
|
98
108
|
}))),
|
99
109
|
className: PropTypes.string,
|
100
110
|
onClose: PropTypes.func,
|
111
|
+
onTagClose: PropTypes.func,
|
101
112
|
open: PropTypes.bool,
|
102
113
|
overflowType: PropTypes.oneOf(['default', 'tag']),
|
103
114
|
portalTarget: PropTypes.node,
|
@@ -9,7 +9,7 @@ import { objectWithoutProperties as _objectWithoutProperties, extends as _extend
|
|
9
9
|
import React__default, { forwardRef, useRef } from 'react';
|
10
10
|
import PropTypes from '../../_virtual/index.js';
|
11
11
|
import cx from 'classnames';
|
12
|
-
import { Popover, OperationalTag, PopoverContent, Tag, Link } from '@carbon/react';
|
12
|
+
import { Popover, OperationalTag, PopoverContent, DismissibleTag, Tag, Link } from '@carbon/react';
|
13
13
|
import { pkg } from '../../settings.js';
|
14
14
|
import { useClickOutside } from '../../global/js/hooks/useClickOutside.js';
|
15
15
|
|
@@ -88,17 +88,25 @@ var TagOverflowPopover = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
88
88
|
_onClose = _ref.onClose,
|
89
89
|
other = _objectWithoutProperties(_ref, _excluded2);
|
90
90
|
var typeValue = overflowType === 'tag' ? 'high-contrast' : tagType;
|
91
|
-
var isFilterable = overflowType === 'tag'
|
91
|
+
var isFilterable = overflowType === 'tag' && (typeof _onClose === 'function' || filter);
|
92
|
+
var tag;
|
93
|
+
if (isFilterable) {
|
94
|
+
tag = /*#__PURE__*/React__default.createElement(DismissibleTag, _extends({}, other, {
|
95
|
+
onClose: function onClose() {
|
96
|
+
return _onClose === null || _onClose === void 0 ? void 0 : _onClose();
|
97
|
+
},
|
98
|
+
type: typeValue,
|
99
|
+
text: label
|
100
|
+
}));
|
101
|
+
} else {
|
102
|
+
tag = /*#__PURE__*/React__default.createElement(Tag, _extends({}, other, {
|
103
|
+
type: typeValue
|
104
|
+
}), label);
|
105
|
+
}
|
92
106
|
return /*#__PURE__*/React__default.createElement("li", {
|
93
107
|
className: cx("".concat(blockClass, "__tag-item"), _defineProperty(_defineProperty({}, "".concat(blockClass, "__tag-item--default"), overflowType === 'default'), "".concat(blockClass, "__tag-item--tag"), overflowType === 'tag')),
|
94
108
|
key: id
|
95
|
-
}, overflowType === 'tag' ?
|
96
|
-
onClose: function onClose() {
|
97
|
-
return _onClose === null || _onClose === void 0 ? void 0 : _onClose();
|
98
|
-
},
|
99
|
-
type: typeValue,
|
100
|
-
filter: isFilterable
|
101
|
-
}), label) : label);
|
109
|
+
}, overflowType === 'tag' ? tag : label);
|
102
110
|
})), ((_overflowTags$length = overflowTags === null || overflowTags === void 0 ? void 0 : overflowTags.length) !== null && _overflowTags$length !== void 0 ? _overflowTags$length : 0) > (allTagsModalSearchThreshold !== null && allTagsModalSearchThreshold !== void 0 ? allTagsModalSearchThreshold : 0) && /*#__PURE__*/React__default.createElement(Link, {
|
103
111
|
className: "".concat(blockClass, "__show-all-tags-link"),
|
104
112
|
href: "",
|
@@ -6,6 +6,10 @@ type OverflowType = 'default' | 'tag';
|
|
6
6
|
type TagType = {
|
7
7
|
label: string;
|
8
8
|
type?: keyof typeof tagTypes;
|
9
|
+
/**
|
10
|
+
* @deprecated Use the `onClose` function instead to render as a DismissibleTag
|
11
|
+
*/
|
12
|
+
filter?: boolean;
|
9
13
|
} & TagBaseProps;
|
10
14
|
export interface TagSetProps extends PropsWithChildren {
|
11
15
|
/**
|
@@ -8,7 +8,7 @@
|
|
8
8
|
import { objectSpread2 as _objectSpread2, objectWithoutProperties as _objectWithoutProperties, slicedToArray as _slicedToArray, extends as _extends } from '../../_virtual/_rollupPluginBabelHelpers.js';
|
9
9
|
import React__default, { useState, useRef, useEffect, useCallback } from 'react';
|
10
10
|
import PropTypes from '../../_virtual/index.js';
|
11
|
-
import { Tag } from '@carbon/react';
|
11
|
+
import { Tag, DismissibleTag } from '@carbon/react';
|
12
12
|
import { TagSetModal } from './TagSetModal.js';
|
13
13
|
import { TagSetOverflow } from './TagSetOverflow.js';
|
14
14
|
import cx from 'classnames';
|
@@ -18,8 +18,8 @@ import { pkg } from '../../settings.js';
|
|
18
18
|
import { useResizeObserver } from '../../global/js/hooks/useResizeObserver.js';
|
19
19
|
|
20
20
|
var _excluded = ["align", "allTagsModalTarget", "className", "maxVisible", "multiline", "overflowAutoAlign", "overflowAlign", "overflowClassName", "overflowType", "allTagsModalAriaLabel", "allTagsModalTitle", "allTagsModalSearchLabel", "allTagsModalSearchPlaceholderText", "showAllTagsLabel", "onOverflowClick", "tags", "containingElementRef", "measurementOffset", "onOverflowTagChange"],
|
21
|
-
_excluded2 = ["label", "id"],
|
22
|
-
_excluded3 = ["label", "onClose"];
|
21
|
+
_excluded2 = ["label", "id", "filter", "onClose"],
|
22
|
+
_excluded3 = ["label", "onClose", "filter"];
|
23
23
|
var componentName = 'TagSet';
|
24
24
|
var blockClass = "".concat(pkg.prefix, "--tag-set");
|
25
25
|
var allTagsModalSearchThreshold = 10;
|
@@ -108,6 +108,8 @@ var TagSet = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
|
|
108
108
|
setHiddenSizingTags(tags && tags.length > 0 ? tags.map(function (_ref2, index) {
|
109
109
|
var label = _ref2.label,
|
110
110
|
id = _ref2.id,
|
111
|
+
filter = _ref2.filter,
|
112
|
+
onClose = _ref2.onClose,
|
111
113
|
other = _objectWithoutProperties(_ref2, _excluded2);
|
112
114
|
return /*#__PURE__*/React__default.createElement("div", {
|
113
115
|
key: index,
|
@@ -117,7 +119,10 @@ var TagSet = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
|
|
117
119
|
newSizingTags[index] = el;
|
118
120
|
}
|
119
121
|
}
|
120
|
-
}, /*#__PURE__*/React__default.createElement(
|
122
|
+
}, typeof onClose === 'function' || filter ? /*#__PURE__*/React__default.createElement(DismissibleTag, _extends({}, other, {
|
123
|
+
"data-original-id": id,
|
124
|
+
text: label
|
125
|
+
})) : /*#__PURE__*/React__default.createElement(Tag, _extends({}, other, {
|
121
126
|
// ensure id is not duplicated
|
122
127
|
"data-original-id": id
|
123
128
|
}), label));
|
@@ -136,15 +141,22 @@ var TagSet = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
|
|
136
141
|
var newDisplayedTags = tags && tags.length > 0 ? tags.map(function (_ref3, index) {
|
137
142
|
var label = _ref3.label,
|
138
143
|
_onClose = _ref3.onClose,
|
144
|
+
filter = _ref3.filter,
|
139
145
|
other = _objectWithoutProperties(_ref3, _excluded3);
|
140
146
|
if (index == tags.length - 1 && other.size) {
|
141
147
|
size = other.size;
|
142
148
|
}
|
149
|
+
if (typeof _onClose === 'function' || filter) {
|
150
|
+
return /*#__PURE__*/React__default.createElement(DismissibleTag, _extends({}, other, {
|
151
|
+
key: "displayed-tag-".concat(index),
|
152
|
+
onClose: function onClose() {
|
153
|
+
return handleTagOnClose(_onClose, index);
|
154
|
+
},
|
155
|
+
text: label
|
156
|
+
}));
|
157
|
+
}
|
143
158
|
return /*#__PURE__*/React__default.createElement(Tag, _extends({}, other, {
|
144
|
-
key: "displayed-tag-".concat(index)
|
145
|
-
onClose: function onClose() {
|
146
|
-
return handleTagOnClose(_onClose, index);
|
147
|
-
}
|
159
|
+
key: "displayed-tag-".concat(index)
|
148
160
|
}), label);
|
149
161
|
}) : [];
|
150
162
|
|
@@ -96,7 +96,6 @@ var TagSetModal = function TagSetModal(_ref) {
|
|
96
96
|
var label = _ref2.label,
|
97
97
|
other = _objectWithoutProperties(_ref2, _excluded2);
|
98
98
|
return /*#__PURE__*/React__default.createElement(Tag, _extends({}, other, {
|
99
|
-
filter: false,
|
100
99
|
key: "all-tags-".concat(index)
|
101
100
|
}), label);
|
102
101
|
}), /*#__PURE__*/React__default.createElement("div", {
|
@@ -260,9 +260,7 @@ var TearsheetShell = /*#__PURE__*/React__default.forwardRef(function (_ref, ref)
|
|
260
260
|
return _defineProperty(_defineProperty({}, "--".concat(bc, "--stacking-scale-factor-single"), (width - 32) / width), "--".concat(bc, "--stacking-scale-factor-double"), (width - 64) / width);
|
261
261
|
};
|
262
262
|
return renderPortalUse( /*#__PURE__*/React__default.createElement(unstable_FeatureFlags, {
|
263
|
-
|
264
|
-
'enable-experimental-focus-wrap-without-sentinels': true
|
265
|
-
}
|
263
|
+
enableExperimentalFocusWrapWithoutSentinels: true
|
266
264
|
}, /*#__PURE__*/React__default.createElement(ComposedModal, _extends({}, rest, {
|
267
265
|
"aria-label": ariaLabel || getNodeTextContent(title),
|
268
266
|
className: cx(bc, className, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(bc, "--stacked-").concat(position, "-of-").concat(depth),
|
@@ -2,7 +2,7 @@ export function TooltipTrigger({ children, className, ...rest }: {
|
|
2
2
|
[x: string]: any;
|
3
3
|
children: any;
|
4
4
|
className: any;
|
5
|
-
}):
|
5
|
+
}): React.JSX.Element;
|
6
6
|
export namespace TooltipTrigger {
|
7
7
|
export { componentName as displayName };
|
8
8
|
export namespace propTypes {
|
@@ -10,6 +10,7 @@ export namespace TooltipTrigger {
|
|
10
10
|
let className: PropTypes.Requireable<string>;
|
11
11
|
}
|
12
12
|
}
|
13
|
+
import React from 'react';
|
13
14
|
declare const componentName: "TooltipTrigger";
|
14
15
|
import PropTypes from 'prop-types';
|
15
16
|
export {};
|
@@ -2,11 +2,12 @@ export function Canary({ className, componentName, ...rest }: {
|
|
2
2
|
[x: string]: any;
|
3
3
|
className: any;
|
4
4
|
componentName: any;
|
5
|
-
}):
|
5
|
+
}): React.JSX.Element;
|
6
6
|
export namespace Canary {
|
7
7
|
namespace propTypes {
|
8
8
|
let className: PropTypes.Requireable<string>;
|
9
9
|
let componentName: PropTypes.Validator<string>;
|
10
10
|
}
|
11
11
|
}
|
12
|
+
import React from 'react';
|
12
13
|
import PropTypes from 'prop-types';
|