@atlaskit/smart-card 26.70.0 → 26.72.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/CHANGELOG.md +20 -0
- package/dist/cjs/state/hooks/use-ai-summary/ai-summary-service/index.js +2 -2
- package/dist/cjs/state/hooks/use-ai-summary/ai-summary-service/utils.js +31 -1
- package/dist/cjs/utils/analytics/analytics.js +1 -1
- package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +87 -0
- package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/index.js +14 -78
- package/dist/cjs/view/FlexibleCard/components/actions/action/index.js +3 -1
- package/dist/cjs/view/FlexibleCard/components/actions/ai-summary-action/ai-summary-action-component.js +8 -1
- package/dist/cjs/view/FlexibleCard/components/blocks/action-block/index.js +11 -2
- package/dist/cjs/view/FlexibleCard/components/blocks/title-block/errored/index.js +3 -1
- package/dist/cjs/view/FlexibleCard/components/blocks/title-block/index.js +4 -2
- package/dist/cjs/view/FlexibleCard/components/blocks/title-block/resolved/index.js +3 -1
- package/dist/cjs/view/FlexibleCard/components/elements/icon/index.js +3 -2
- package/dist/cjs/view/LinkUrl/index.js +1 -1
- package/dist/es2019/state/hooks/use-ai-summary/ai-summary-service/index.js +3 -3
- package/dist/es2019/state/hooks/use-ai-summary/ai-summary-service/utils.js +30 -0
- package/dist/es2019/utils/analytics/analytics.js +1 -1
- package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +79 -0
- package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/index.js +15 -80
- package/dist/es2019/view/FlexibleCard/components/actions/action/index.js +3 -1
- package/dist/es2019/view/FlexibleCard/components/actions/ai-summary-action/ai-summary-action-component.js +5 -1
- package/dist/es2019/view/FlexibleCard/components/blocks/action-block/index.js +8 -2
- package/dist/es2019/view/FlexibleCard/components/blocks/title-block/errored/index.js +2 -0
- package/dist/es2019/view/FlexibleCard/components/blocks/title-block/index.js +3 -1
- package/dist/es2019/view/FlexibleCard/components/blocks/title-block/resolved/index.js +2 -0
- package/dist/es2019/view/FlexibleCard/components/elements/icon/index.js +3 -2
- package/dist/es2019/view/LinkUrl/index.js +1 -1
- package/dist/esm/state/hooks/use-ai-summary/ai-summary-service/index.js +3 -3
- package/dist/esm/state/hooks/use-ai-summary/ai-summary-service/utils.js +30 -0
- package/dist/esm/utils/analytics/analytics.js +1 -1
- package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +78 -0
- package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/index.js +14 -75
- package/dist/esm/view/FlexibleCard/components/actions/action/index.js +3 -1
- package/dist/esm/view/FlexibleCard/components/actions/ai-summary-action/ai-summary-action-component.js +5 -1
- package/dist/esm/view/FlexibleCard/components/blocks/action-block/index.js +11 -2
- package/dist/esm/view/FlexibleCard/components/blocks/title-block/errored/index.js +3 -1
- package/dist/esm/view/FlexibleCard/components/blocks/title-block/index.js +4 -2
- package/dist/esm/view/FlexibleCard/components/blocks/title-block/resolved/index.js +3 -1
- package/dist/esm/view/FlexibleCard/components/elements/icon/index.js +3 -2
- package/dist/esm/view/LinkUrl/index.js +1 -1
- package/dist/types/state/hooks/use-ai-summary/ai-summary-service/utils.d.ts +7 -0
- package/dist/types/view/BlockCard/index.d.ts +2 -2
- package/dist/types/view/BlockCard/views/flexible/unresolved-view/index.d.ts +1 -1
- package/dist/types/view/FlexibleCard/components/actions/action/action-stack-item/action-button.d.ts +12 -0
- package/dist/types/view/FlexibleCard/components/actions/action/action-stack-item/index.d.ts +3 -3
- package/dist/types/view/FlexibleCard/components/actions/action/action-stack-item/types.d.ts +2 -5
- package/dist/types/view/FlexibleCard/components/actions/action/types.d.ts +5 -0
- package/dist/types/view/FlexibleCard/components/blocks/title-block/errored/index.d.ts +1 -1
- package/dist/types/view/FlexibleCard/components/blocks/title-block/index.d.ts +1 -1
- package/dist/types/view/FlexibleCard/components/blocks/title-block/resolved/index.d.ts +1 -1
- package/dist/types/view/FlexibleCard/components/blocks/title-block/types.d.ts +10 -5
- package/dist/types/view/FlexibleCard/components/elements/icon/index.d.ts +1 -1
- package/dist/types/view/FlexibleCard/components/elements/icon/types.d.ts +7 -2
- package/dist/types/view/FlexibleCard/components/elements/link/index.d.ts +1 -1
- package/dist/types/view/FlexibleCard/components/elements/link/types.d.ts +3 -3
- package/dist/types-ts4.5/state/hooks/use-ai-summary/ai-summary-service/utils.d.ts +7 -0
- package/dist/types-ts4.5/view/BlockCard/index.d.ts +2 -2
- package/dist/types-ts4.5/view/BlockCard/views/flexible/unresolved-view/index.d.ts +1 -1
- package/dist/types-ts4.5/view/FlexibleCard/components/actions/action/action-stack-item/action-button.d.ts +12 -0
- package/dist/types-ts4.5/view/FlexibleCard/components/actions/action/action-stack-item/index.d.ts +3 -3
- package/dist/types-ts4.5/view/FlexibleCard/components/actions/action/action-stack-item/types.d.ts +2 -5
- package/dist/types-ts4.5/view/FlexibleCard/components/actions/action/types.d.ts +5 -0
- package/dist/types-ts4.5/view/FlexibleCard/components/blocks/title-block/errored/index.d.ts +1 -1
- package/dist/types-ts4.5/view/FlexibleCard/components/blocks/title-block/index.d.ts +1 -1
- package/dist/types-ts4.5/view/FlexibleCard/components/blocks/title-block/resolved/index.d.ts +1 -1
- package/dist/types-ts4.5/view/FlexibleCard/components/blocks/title-block/types.d.ts +10 -5
- package/dist/types-ts4.5/view/FlexibleCard/components/elements/icon/index.d.ts +1 -1
- package/dist/types-ts4.5/view/FlexibleCard/components/elements/icon/types.d.ts +7 -2
- package/dist/types-ts4.5/view/FlexibleCard/components/elements/link/index.d.ts +1 -1
- package/dist/types-ts4.5/view/FlexibleCard/components/elements/link/types.d.ts +3 -3
- package/package.json +2 -2
|
@@ -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 = ["actionGroup", "metadata", "position", "subtitle", "testId", "text", "title", "metadataPosition", "hideIcon"];
|
|
3
|
+
var _excluded = ["actionGroup", "metadata", "position", "subtitle", "testId", "text", "icon", "title", "metadataPosition", "hideIcon"];
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { css } from '@emotion/react';
|
|
6
6
|
import { LinkIcon } from '../../../elements';
|
|
@@ -23,6 +23,7 @@ var TitleBlockResolvedView = function TitleBlockResolvedView(_ref) {
|
|
|
23
23
|
subtitle = _ref$subtitle === void 0 ? [] : _ref$subtitle,
|
|
24
24
|
testId = _ref.testId,
|
|
25
25
|
text = _ref.text,
|
|
26
|
+
icon = _ref.icon,
|
|
26
27
|
title = _ref.title,
|
|
27
28
|
metadataPosition = _ref.metadataPosition,
|
|
28
29
|
hideIcon = _ref.hideIcon,
|
|
@@ -32,6 +33,7 @@ var TitleBlockResolvedView = function TitleBlockResolvedView(_ref) {
|
|
|
32
33
|
return /*#__PURE__*/React.createElement(Block, _extends({}, blockProps, {
|
|
33
34
|
testId: "".concat(testId, "-resolved-view")
|
|
34
35
|
}), !hideIcon && /*#__PURE__*/React.createElement(LinkIcon, {
|
|
36
|
+
overrideIcon: icon,
|
|
35
37
|
position: position
|
|
36
38
|
}), /*#__PURE__*/React.createElement(ElementGroup, {
|
|
37
39
|
direction: SmartLinkDirection.Vertical,
|
|
@@ -70,6 +70,7 @@ var renderImageIcon = function renderImageIcon(defaultIcon, url, testId) {
|
|
|
70
70
|
*/
|
|
71
71
|
var Icon = function Icon(_ref) {
|
|
72
72
|
var icon = _ref.icon,
|
|
73
|
+
overrideIcon = _ref.overrideIcon,
|
|
73
74
|
_ref$label = _ref.label,
|
|
74
75
|
label = _ref$label === void 0 ? 'Link' : _ref$label,
|
|
75
76
|
name = _ref.name,
|
|
@@ -84,8 +85,8 @@ var Icon = function Icon(_ref) {
|
|
|
84
85
|
url = _ref.url;
|
|
85
86
|
var element = useMemo(function () {
|
|
86
87
|
var defaultIcon = renderDefaultIcon(label, testId);
|
|
87
|
-
return (render === null || render === void 0 ? void 0 : render()) || renderImageIcon(defaultIcon, url, testId) || renderAtlaskitIcon(icon, label, testId) || defaultIcon;
|
|
88
|
-
}, [icon, label, render, testId, url]);
|
|
88
|
+
return overrideIcon || (render === null || render === void 0 ? void 0 : render()) || renderImageIcon(defaultIcon, url, testId) || renderAtlaskitIcon(icon, label, testId) || defaultIcon;
|
|
89
|
+
}, [overrideIcon, icon, label, render, testId, url]);
|
|
89
90
|
var width = getIconWidth(size);
|
|
90
91
|
var styles = getIconStyles(position, width);
|
|
91
92
|
var renderStyles = render ? getCustomRenderStyles(width) : undefined;
|
|
@@ -10,7 +10,7 @@ import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-m
|
|
|
10
10
|
import LinkWarningModal from './LinkWarningModal';
|
|
11
11
|
var PACKAGE_DATA = {
|
|
12
12
|
packageName: "@atlaskit/smart-card",
|
|
13
|
-
packageVersion: "26.
|
|
13
|
+
packageVersion: "26.72.0",
|
|
14
14
|
componentName: 'linkUrl'
|
|
15
15
|
};
|
|
16
16
|
var Link = withLinkClickedEvent('a');
|
|
@@ -1,2 +1,9 @@
|
|
|
1
|
+
import { type ProductType } from '@atlaskit/linking-common';
|
|
1
2
|
export declare const getBufferReader: (response: Response) => ReadableStreamDefaultReader<string>;
|
|
2
3
|
export declare const addPath: (baseUrl: string, path: string) => string;
|
|
4
|
+
/**
|
|
5
|
+
* Converts a `ProductType` to the expected `x-product` header value for AI Mate.
|
|
6
|
+
*
|
|
7
|
+
* @see https://developer.atlassian.com/platform/assistance-service/security/entitlements/#approach
|
|
8
|
+
*/
|
|
9
|
+
export declare const getXProductHeaderValue: (product: ProductType | undefined) => "CONFLUENCE" | "ATLAS" | "BITBUCKET" | "TRELLO" | "JSM" | "JPD" | "ELEVATE" | "JIRA-SOFTWARE" | "JIRA-CORE" | undefined;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
|
-
import { FC } from 'react';
|
|
3
|
-
import { BlockCardProps } from './types';
|
|
2
|
+
import { type FC } from 'react';
|
|
3
|
+
import { type BlockCardProps } from './types';
|
|
4
4
|
import { AuthorizeAction } from './actions/AuthorizeAction';
|
|
5
5
|
import { ForbiddenAction } from './actions/ForbiddenAction';
|
|
6
6
|
import { ResolvedView as BlockCardResolvedView } from './views/ResolvedView';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { UnresolvedViewProps } from './types';
|
|
2
|
+
import { type UnresolvedViewProps } from './types';
|
|
3
3
|
declare const UnresolvedView: ({ actions, cardState, children, onAuthorize, onClick, onError, showPreview, testId, title, url, }: UnresolvedViewProps) => JSX.Element;
|
|
4
4
|
export default UnresolvedView;
|
package/dist/types/view/FlexibleCard/components/actions/action/action-stack-item/action-button.d.ts
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { ActionStackItemProps } from './types';
|
|
3
|
+
import type { TriggerProps } from '@atlaskit/tooltip';
|
|
4
|
+
declare const ActionButton: ({ content, icon: iconOption, isDisabled, isLoading, onClick: onClickCallback, size, space: spaceOption, testId, tooltipProps, xcss, }: import("../types").ActionProps & {
|
|
5
|
+
size: import("../../../../../..").SmartLinkSize;
|
|
6
|
+
space?: "space.0" | "space.025" | "space.050" | "space.075" | "space.100" | "space.150" | "space.200" | "space.250" | "space.300" | "space.400" | "space.500" | "space.600" | "space.800" | "space.1000" | undefined;
|
|
7
|
+
tooltipOnHide?: ((analyticsEvent: import("@atlaskit/analytics-next").UIAnalyticsEvent) => any) | undefined;
|
|
8
|
+
hideTooltipOnMouseDown?: boolean | undefined;
|
|
9
|
+
} & {
|
|
10
|
+
tooltipProps?: TriggerProps | undefined;
|
|
11
|
+
}) => JSX.Element;
|
|
12
|
+
export default ActionButton;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
3
|
-
declare const ActionStackItem:
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { ActionStackItemProps } from './types';
|
|
3
|
+
declare const ActionStackItem: ({ content, tooltipMessage, tooltipOnHide, hideTooltipOnMouseDown, hideTooltip, ...props }: ActionStackItemProps) => JSX.Element;
|
|
4
4
|
export default ActionStackItem;
|
|
@@ -1,13 +1,10 @@
|
|
|
1
|
-
import type { Space
|
|
1
|
+
import type { Space } from '@atlaskit/primitives';
|
|
2
2
|
import type { SmartLinkSize } from '../../../../../../constants';
|
|
3
3
|
import type { ActionProps } from '../types';
|
|
4
|
-
import { UIAnalyticsEvent } from '@atlaskit/analytics-next';
|
|
4
|
+
import type { UIAnalyticsEvent } from '@atlaskit/analytics-next';
|
|
5
5
|
export type ActionStackItemProps = ActionProps & {
|
|
6
|
-
isLoading?: boolean;
|
|
7
6
|
size: SmartLinkSize;
|
|
8
|
-
isDisabled?: boolean;
|
|
9
7
|
space?: Space;
|
|
10
|
-
xcss?: XCSS;
|
|
11
8
|
tooltipOnHide?: (analyticsEvent: UIAnalyticsEvent) => any;
|
|
12
9
|
hideTooltipOnMouseDown?: boolean;
|
|
13
10
|
};
|
|
@@ -60,6 +60,10 @@ export type ActionProps = {
|
|
|
60
60
|
* Determines the hideTooltipOnMouseDown behaviour of the Tooltip
|
|
61
61
|
*/
|
|
62
62
|
hideTooltipOnMouseDown?: boolean;
|
|
63
|
+
/**
|
|
64
|
+
* Determines if the tooltip should be hidden
|
|
65
|
+
*/
|
|
66
|
+
hideTooltip?: boolean;
|
|
63
67
|
/**
|
|
64
68
|
* @deprecated Use 'as' instead
|
|
65
69
|
* Used to determine whether the Action is in a Dropdown.
|
|
@@ -102,4 +106,5 @@ export type ActionProps = {
|
|
|
102
106
|
* Cleanup on https://product-fabric.atlassian.net/browse/EDM-9649
|
|
103
107
|
*/
|
|
104
108
|
wrapper?: React.ElementType;
|
|
109
|
+
onLoadingChange?: (isLoading: boolean) => void;
|
|
105
110
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { TitleBlockProps } from './types';
|
|
2
|
+
import { type TitleBlockProps } from './types';
|
|
3
3
|
/**
|
|
4
4
|
* Represents a TitleBlock, which is the foundation of Flexible UI.
|
|
5
5
|
* This contains an icon, the link, and any associated metadata and actions in one block.
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { ActionItem, BlockProps, ElementItem, OnActionMenuOpenChangeOptions } from '../types';
|
|
3
|
-
import { SmartLinkPosition, SmartLinkTheme } from '../../../../../constants';
|
|
4
|
-
import { RetryOptions } from '../../../types';
|
|
5
|
-
import { AnchorTarget } from '../../types';
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import { type ActionItem, type BlockProps, type ElementItem, type OnActionMenuOpenChangeOptions } from '../types';
|
|
3
|
+
import { type SmartLinkPosition, type SmartLinkTheme } from '../../../../../constants';
|
|
4
|
+
import { type RetryOptions } from '../../../types';
|
|
5
|
+
import { type AnchorTarget } from '../../types';
|
|
6
6
|
export type TitleBlockProps = {
|
|
7
7
|
/**
|
|
8
8
|
* An array of action items to be displayed after the title
|
|
@@ -80,6 +80,11 @@ export type TitleBlockProps = {
|
|
|
80
80
|
* the Smart Link.
|
|
81
81
|
*/
|
|
82
82
|
text?: string;
|
|
83
|
+
/**
|
|
84
|
+
* The icon to display in the title block. Overrides any icon that is retrieved from
|
|
85
|
+
* the Smart Link.
|
|
86
|
+
*/
|
|
87
|
+
icon?: React.ReactNode;
|
|
83
88
|
/**
|
|
84
89
|
* The theme of the link text. Can be Black or Link (default URL blue)
|
|
85
90
|
* @internal
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { ElementProps } from '../types';
|
|
3
|
-
import { IconType, SmartLinkPosition } from '../../../../../constants';
|
|
2
|
+
import { type ElementProps } from '../types';
|
|
3
|
+
import { type IconType, type SmartLinkPosition } from '../../../../../constants';
|
|
4
4
|
export type IconProps = ElementProps & {
|
|
5
5
|
/**
|
|
6
6
|
* If provided, Icon element will use this render function instead.
|
|
@@ -11,6 +11,11 @@ export type IconProps = ElementProps & {
|
|
|
11
11
|
* will be used.
|
|
12
12
|
*/
|
|
13
13
|
icon?: IconType;
|
|
14
|
+
/**
|
|
15
|
+
* If provided, overrideIcon will be rendered in the place of the provided icon or one that is
|
|
16
|
+
* supplied by the URL.
|
|
17
|
+
*/
|
|
18
|
+
overrideIcon?: React.ReactNode;
|
|
14
19
|
/**
|
|
15
20
|
* The label provided to the Atlaskit Icon.
|
|
16
21
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { ElementProps } from '../types';
|
|
3
|
-
import { SmartLinkTheme } from '../../../../../constants';
|
|
4
|
-
import { AnchorTarget } from '../../types';
|
|
2
|
+
import { type ElementProps } from '../types';
|
|
3
|
+
import { type SmartLinkTheme } from '../../../../../constants';
|
|
4
|
+
import { type AnchorTarget } from '../../types';
|
|
5
5
|
export type LinkProps = ElementProps & {
|
|
6
6
|
/**
|
|
7
7
|
* Determines whether the link should display tooltip on hover.
|
|
@@ -1,2 +1,9 @@
|
|
|
1
|
+
import { type ProductType } from '@atlaskit/linking-common';
|
|
1
2
|
export declare const getBufferReader: (response: Response) => ReadableStreamDefaultReader<string>;
|
|
2
3
|
export declare const addPath: (baseUrl: string, path: string) => string;
|
|
4
|
+
/**
|
|
5
|
+
* Converts a `ProductType` to the expected `x-product` header value for AI Mate.
|
|
6
|
+
*
|
|
7
|
+
* @see https://developer.atlassian.com/platform/assistance-service/security/entitlements/#approach
|
|
8
|
+
*/
|
|
9
|
+
export declare const getXProductHeaderValue: (product: ProductType | undefined) => "CONFLUENCE" | "ATLAS" | "BITBUCKET" | "TRELLO" | "JSM" | "JPD" | "ELEVATE" | "JIRA-SOFTWARE" | "JIRA-CORE" | undefined;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
|
-
import { FC } from 'react';
|
|
3
|
-
import { BlockCardProps } from './types';
|
|
2
|
+
import { type FC } from 'react';
|
|
3
|
+
import { type BlockCardProps } from './types';
|
|
4
4
|
import { AuthorizeAction } from './actions/AuthorizeAction';
|
|
5
5
|
import { ForbiddenAction } from './actions/ForbiddenAction';
|
|
6
6
|
import { ResolvedView as BlockCardResolvedView } from './views/ResolvedView';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { UnresolvedViewProps } from './types';
|
|
2
|
+
import { type UnresolvedViewProps } from './types';
|
|
3
3
|
declare const UnresolvedView: ({ actions, cardState, children, onAuthorize, onClick, onError, showPreview, testId, title, url, }: UnresolvedViewProps) => JSX.Element;
|
|
4
4
|
export default UnresolvedView;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { ActionStackItemProps } from './types';
|
|
3
|
+
import type { TriggerProps } from '@atlaskit/tooltip';
|
|
4
|
+
declare const ActionButton: ({ content, icon: iconOption, isDisabled, isLoading, onClick: onClickCallback, size, space: spaceOption, testId, tooltipProps, xcss, }: import("../types").ActionProps & {
|
|
5
|
+
size: import("../../../../../..").SmartLinkSize;
|
|
6
|
+
space?: "space.0" | "space.025" | "space.050" | "space.075" | "space.100" | "space.150" | "space.200" | "space.250" | "space.300" | "space.400" | "space.500" | "space.600" | "space.800" | "space.1000" | undefined;
|
|
7
|
+
tooltipOnHide?: ((analyticsEvent: import("@atlaskit/analytics-next").UIAnalyticsEvent) => any) | undefined;
|
|
8
|
+
hideTooltipOnMouseDown?: boolean | undefined;
|
|
9
|
+
} & {
|
|
10
|
+
tooltipProps?: TriggerProps | undefined;
|
|
11
|
+
}) => JSX.Element;
|
|
12
|
+
export default ActionButton;
|
package/dist/types-ts4.5/view/FlexibleCard/components/actions/action/action-stack-item/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
3
|
-
declare const ActionStackItem:
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { ActionStackItemProps } from './types';
|
|
3
|
+
declare const ActionStackItem: ({ content, tooltipMessage, tooltipOnHide, hideTooltipOnMouseDown, hideTooltip, ...props }: ActionStackItemProps) => JSX.Element;
|
|
4
4
|
export default ActionStackItem;
|
package/dist/types-ts4.5/view/FlexibleCard/components/actions/action/action-stack-item/types.d.ts
CHANGED
|
@@ -1,13 +1,10 @@
|
|
|
1
|
-
import type { Space
|
|
1
|
+
import type { Space } from '@atlaskit/primitives';
|
|
2
2
|
import type { SmartLinkSize } from '../../../../../../constants';
|
|
3
3
|
import type { ActionProps } from '../types';
|
|
4
|
-
import { UIAnalyticsEvent } from '@atlaskit/analytics-next';
|
|
4
|
+
import type { UIAnalyticsEvent } from '@atlaskit/analytics-next';
|
|
5
5
|
export type ActionStackItemProps = ActionProps & {
|
|
6
|
-
isLoading?: boolean;
|
|
7
6
|
size: SmartLinkSize;
|
|
8
|
-
isDisabled?: boolean;
|
|
9
7
|
space?: Space;
|
|
10
|
-
xcss?: XCSS;
|
|
11
8
|
tooltipOnHide?: (analyticsEvent: UIAnalyticsEvent) => any;
|
|
12
9
|
hideTooltipOnMouseDown?: boolean;
|
|
13
10
|
};
|
|
@@ -60,6 +60,10 @@ export type ActionProps = {
|
|
|
60
60
|
* Determines the hideTooltipOnMouseDown behaviour of the Tooltip
|
|
61
61
|
*/
|
|
62
62
|
hideTooltipOnMouseDown?: boolean;
|
|
63
|
+
/**
|
|
64
|
+
* Determines if the tooltip should be hidden
|
|
65
|
+
*/
|
|
66
|
+
hideTooltip?: boolean;
|
|
63
67
|
/**
|
|
64
68
|
* @deprecated Use 'as' instead
|
|
65
69
|
* Used to determine whether the Action is in a Dropdown.
|
|
@@ -102,4 +106,5 @@ export type ActionProps = {
|
|
|
102
106
|
* Cleanup on https://product-fabric.atlassian.net/browse/EDM-9649
|
|
103
107
|
*/
|
|
104
108
|
wrapper?: React.ElementType;
|
|
109
|
+
onLoadingChange?: (isLoading: boolean) => void;
|
|
105
110
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { TitleBlockProps } from './types';
|
|
2
|
+
import { type TitleBlockProps } from './types';
|
|
3
3
|
/**
|
|
4
4
|
* Represents a TitleBlock, which is the foundation of Flexible UI.
|
|
5
5
|
* This contains an icon, the link, and any associated metadata and actions in one block.
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { ActionItem, BlockProps, ElementItem, OnActionMenuOpenChangeOptions } from '../types';
|
|
3
|
-
import { SmartLinkPosition, SmartLinkTheme } from '../../../../../constants';
|
|
4
|
-
import { RetryOptions } from '../../../types';
|
|
5
|
-
import { AnchorTarget } from '../../types';
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
import { type ActionItem, type BlockProps, type ElementItem, type OnActionMenuOpenChangeOptions } from '../types';
|
|
3
|
+
import { type SmartLinkPosition, type SmartLinkTheme } from '../../../../../constants';
|
|
4
|
+
import { type RetryOptions } from '../../../types';
|
|
5
|
+
import { type AnchorTarget } from '../../types';
|
|
6
6
|
export type TitleBlockProps = {
|
|
7
7
|
/**
|
|
8
8
|
* An array of action items to be displayed after the title
|
|
@@ -80,6 +80,11 @@ export type TitleBlockProps = {
|
|
|
80
80
|
* the Smart Link.
|
|
81
81
|
*/
|
|
82
82
|
text?: string;
|
|
83
|
+
/**
|
|
84
|
+
* The icon to display in the title block. Overrides any icon that is retrieved from
|
|
85
|
+
* the Smart Link.
|
|
86
|
+
*/
|
|
87
|
+
icon?: React.ReactNode;
|
|
83
88
|
/**
|
|
84
89
|
* The theme of the link text. Can be Black or Link (default URL blue)
|
|
85
90
|
* @internal
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { ElementProps } from '../types';
|
|
3
|
-
import { IconType, SmartLinkPosition } from '../../../../../constants';
|
|
2
|
+
import { type ElementProps } from '../types';
|
|
3
|
+
import { type IconType, type SmartLinkPosition } from '../../../../../constants';
|
|
4
4
|
export type IconProps = ElementProps & {
|
|
5
5
|
/**
|
|
6
6
|
* If provided, Icon element will use this render function instead.
|
|
@@ -11,6 +11,11 @@ export type IconProps = ElementProps & {
|
|
|
11
11
|
* will be used.
|
|
12
12
|
*/
|
|
13
13
|
icon?: IconType;
|
|
14
|
+
/**
|
|
15
|
+
* If provided, overrideIcon will be rendered in the place of the provided icon or one that is
|
|
16
|
+
* supplied by the URL.
|
|
17
|
+
*/
|
|
18
|
+
overrideIcon?: React.ReactNode;
|
|
14
19
|
/**
|
|
15
20
|
* The label provided to the Atlaskit Icon.
|
|
16
21
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { ElementProps } from '../types';
|
|
3
|
-
import { SmartLinkTheme } from '../../../../../constants';
|
|
4
|
-
import { AnchorTarget } from '../../types';
|
|
2
|
+
import { type ElementProps } from '../types';
|
|
3
|
+
import { type SmartLinkTheme } from '../../../../../constants';
|
|
4
|
+
import { type AnchorTarget } from '../../types';
|
|
5
5
|
export type LinkProps = ElementProps & {
|
|
6
6
|
/**
|
|
7
7
|
* Determines whether the link should display tooltip on hover.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/smart-card",
|
|
3
|
-
"version": "26.
|
|
3
|
+
"version": "26.72.0",
|
|
4
4
|
"description": "Smart card component",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"@atlaskit/button": "^17.15.0",
|
|
37
37
|
"@atlaskit/checkbox": "^13.3.0",
|
|
38
38
|
"@atlaskit/dropdown-menu": "^12.10.0",
|
|
39
|
-
"@atlaskit/form": "^10.
|
|
39
|
+
"@atlaskit/form": "^10.2.0",
|
|
40
40
|
"@atlaskit/frontend-utilities": "^2.7.0",
|
|
41
41
|
"@atlaskit/heading": "^2.3.0",
|
|
42
42
|
"@atlaskit/icon": "^22.3.0",
|