@atlaskit/smart-card 26.50.6 → 26.50.8
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 +12 -0
- package/client/package.json +1 -1
- package/dist/cjs/state/analytics/ufoExperiences.js +1 -1
- package/dist/cjs/utils/analytics/analytics.js +1 -1
- package/dist/cjs/view/CardWithUrl/component.js +2 -1
- package/dist/cjs/view/EmbedCard/components/styled.js +8 -9
- package/dist/cjs/view/LinkUrl/index.js +1 -1
- package/dist/es2019/state/analytics/ufoExperiences.js +1 -1
- package/dist/es2019/utils/analytics/analytics.js +1 -1
- package/dist/es2019/view/CardWithUrl/component.js +2 -1
- package/dist/es2019/view/EmbedCard/components/styled.js +3 -5
- package/dist/es2019/view/LinkUrl/index.js +1 -1
- package/dist/esm/state/analytics/ufoExperiences.js +1 -1
- package/dist/esm/utils/analytics/analytics.js +1 -1
- package/dist/esm/view/CardWithUrl/component.js +2 -1
- package/dist/esm/view/EmbedCard/components/styled.js +8 -9
- package/dist/esm/view/LinkUrl/index.js +1 -1
- package/dist/types/common/analytics/generated/create-event-payload.d.ts +1 -1
- package/dist/types/common/analytics/generated/use-analytics-events.d.ts +1 -1
- package/dist/types/state/analytics/useLinkClicked.d.ts +2 -2
- package/dist/types/utils/actions/create-invoke-request.d.ts +1 -1
- package/dist/types/utils/analytics/click.d.ts +1 -1
- package/dist/types/view/Card/index.d.ts +1 -1
- package/dist/types/view/EmbedCard/components/styled.d.ts +1 -1
- package/dist/types/view/EmbedCard/constants.d.ts +3 -3
- package/dist/types/view/EmbedCard/utils.d.ts +1 -1
- package/dist/types/view/FlexibleCard/components/blocks/types.d.ts +8 -0
- package/dist/types/view/LinkUrl/LinkWarningModal/index.d.ts +2 -2
- package/dist/types-ts4.5/common/analytics/generated/create-event-payload.d.ts +1 -1
- package/dist/types-ts4.5/common/analytics/generated/use-analytics-events.d.ts +1 -1
- package/dist/types-ts4.5/state/analytics/useLinkClicked.d.ts +2 -2
- package/dist/types-ts4.5/utils/actions/create-invoke-request.d.ts +1 -1
- package/dist/types-ts4.5/utils/analytics/click.d.ts +1 -1
- package/dist/types-ts4.5/view/Card/index.d.ts +1 -1
- package/dist/types-ts4.5/view/EmbedCard/components/styled.d.ts +1 -1
- package/dist/types-ts4.5/view/EmbedCard/constants.d.ts +3 -3
- package/dist/types-ts4.5/view/EmbedCard/utils.d.ts +1 -1
- package/dist/types-ts4.5/view/FlexibleCard/components/blocks/types.d.ts +8 -0
- package/dist/types-ts4.5/view/LinkUrl/LinkWarningModal/index.d.ts +2 -2
- package/hooks/package.json +1 -1
- package/hover-card/package.json +1 -1
- package/in-product/package.json +1 -1
- package/link-url/package.json +1 -1
- package/package.json +5 -5
- package/ssr/package.json +1 -1
- package/types/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @atlaskit/smart-card
|
|
2
2
|
|
|
3
|
+
## 26.50.8
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#82741](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/82741) [`2acb6d77c0a6`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/2acb6d77c0a6) - Update UFO experience type for Smart link AI summary
|
|
8
|
+
|
|
9
|
+
## 26.50.7
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#83116](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/83116) [`8d4e99057fe0`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/8d4e99057fe0) - Upgrade Typescript from `4.9.5` to `5.4.2`
|
|
14
|
+
|
|
3
15
|
## 26.50.6
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
package/client/package.json
CHANGED
|
@@ -24,7 +24,7 @@ var aiExperience = {
|
|
|
24
24
|
component: 'smart-links'
|
|
25
25
|
},
|
|
26
26
|
type: _ufo.ExperienceTypes.Experience,
|
|
27
|
-
performanceType: _ufo.ExperiencePerformanceTypes.
|
|
27
|
+
performanceType: _ufo.ExperiencePerformanceTypes.InlineResult
|
|
28
28
|
};
|
|
29
29
|
var ufoExperiences = {
|
|
30
30
|
'smart-link-rendered': new _ufo.ConcurrentExperience('smart-link-rendered', renderExperience),
|
|
@@ -22,7 +22,7 @@ var ANALYTICS_CHANNEL = exports.ANALYTICS_CHANNEL = 'media';
|
|
|
22
22
|
var context = exports.context = {
|
|
23
23
|
componentName: 'smart-cards',
|
|
24
24
|
packageName: "@atlaskit/smart-card",
|
|
25
|
-
packageVersion: "26.50.
|
|
25
|
+
packageVersion: "26.50.8"
|
|
26
26
|
};
|
|
27
27
|
var TrackQuickActionType = exports.TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
28
28
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -125,12 +125,13 @@ function Component(_ref) {
|
|
|
125
125
|
(0, _react.useEffect)(function () {
|
|
126
126
|
measure.mark(id, state.status);
|
|
127
127
|
if (state.status !== 'pending' && state.status !== 'resolving') {
|
|
128
|
+
var _state$error;
|
|
128
129
|
measure.create(id, state.status);
|
|
129
130
|
analytics.operational.instrument({
|
|
130
131
|
id: id,
|
|
131
132
|
status: state.status,
|
|
132
133
|
definitionId: definitionId,
|
|
133
|
-
extensionKey: extensionKey,
|
|
134
|
+
extensionKey: extensionKey !== null && extensionKey !== void 0 ? extensionKey : (_state$error = state.error) === null || _state$error === void 0 ? void 0 : _state$error.extensionKey,
|
|
134
135
|
resourceType: resourceType,
|
|
135
136
|
error: state.error
|
|
136
137
|
});
|
|
@@ -183,15 +183,14 @@ var Description = exports.Description = _styled.default.div({
|
|
|
183
183
|
var ResolvedViewIconWrapper = exports.ResolvedViewIconWrapper = _styled.default.div({
|
|
184
184
|
marginTop: "var(--ds-space-050, 4px)"
|
|
185
185
|
});
|
|
186
|
-
var Thumbnail = exports.Thumbnail = _styled.default.div(borderRadius, csssize(48), {
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
}
|
|
194
|
-
backgroundSize: 'cover'
|
|
186
|
+
var Thumbnail = exports.Thumbnail = _styled.default.div(borderRadius, csssize(48), function (props) {
|
|
187
|
+
return {
|
|
188
|
+
float: 'right',
|
|
189
|
+
margin: "var(--ds-space-050, 4px)".concat(" 0 ", "var(--ds-space-150, 12px)", " ", "var(--ds-space-150, 12px)"),
|
|
190
|
+
backgroundColor: "var(--ds-skeleton, ".concat(colors.N30, ")"),
|
|
191
|
+
backgroundImage: "url(".concat(props.src, ")"),
|
|
192
|
+
backgroundSize: 'cover'
|
|
193
|
+
};
|
|
195
194
|
});
|
|
196
195
|
var UsersWrapper = exports.UsersWrapper = _styled.default.div({
|
|
197
196
|
marginTop: "var(--ds-space-100, 8px)"
|
|
@@ -17,7 +17,7 @@ var _excluded = ["href", "children", "checkSafety", "onClick", "testId"],
|
|
|
17
17
|
_excluded2 = ["isLinkSafe", "showSafetyWarningModal"];
|
|
18
18
|
var PACKAGE_DATA = {
|
|
19
19
|
packageName: "@atlaskit/smart-card",
|
|
20
|
-
packageVersion: "26.50.
|
|
20
|
+
packageVersion: "26.50.8",
|
|
21
21
|
componentName: 'linkUrl'
|
|
22
22
|
};
|
|
23
23
|
var Link = (0, _click.withLinkClickedEvent)('a');
|
|
@@ -18,7 +18,7 @@ const aiExperience = {
|
|
|
18
18
|
component: 'smart-links'
|
|
19
19
|
},
|
|
20
20
|
type: ExperienceTypes.Experience,
|
|
21
|
-
performanceType: ExperiencePerformanceTypes.
|
|
21
|
+
performanceType: ExperiencePerformanceTypes.InlineResult
|
|
22
22
|
};
|
|
23
23
|
const ufoExperiences = {
|
|
24
24
|
'smart-link-rendered': new ConcurrentExperience('smart-link-rendered', renderExperience),
|
|
@@ -4,7 +4,7 @@ export const ANALYTICS_CHANNEL = 'media';
|
|
|
4
4
|
export const context = {
|
|
5
5
|
componentName: 'smart-cards',
|
|
6
6
|
packageName: "@atlaskit/smart-card",
|
|
7
|
-
packageVersion: "26.50.
|
|
7
|
+
packageVersion: "26.50.8"
|
|
8
8
|
};
|
|
9
9
|
export let TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
10
10
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -112,12 +112,13 @@ function Component({
|
|
|
112
112
|
useEffect(() => {
|
|
113
113
|
measure.mark(id, state.status);
|
|
114
114
|
if (state.status !== 'pending' && state.status !== 'resolving') {
|
|
115
|
+
var _state$error;
|
|
115
116
|
measure.create(id, state.status);
|
|
116
117
|
analytics.operational.instrument({
|
|
117
118
|
id,
|
|
118
119
|
status: state.status,
|
|
119
120
|
definitionId,
|
|
120
|
-
extensionKey,
|
|
121
|
+
extensionKey: extensionKey !== null && extensionKey !== void 0 ? extensionKey : (_state$error = state.error) === null || _state$error === void 0 ? void 0 : _state$error.extensionKey,
|
|
121
122
|
resourceType,
|
|
122
123
|
error: state.error
|
|
123
124
|
});
|
|
@@ -281,15 +281,13 @@ export const Description = styled.div({
|
|
|
281
281
|
export const ResolvedViewIconWrapper = styled.div({
|
|
282
282
|
marginTop: "var(--ds-space-050, 4px)"
|
|
283
283
|
});
|
|
284
|
-
export const Thumbnail = styled.div(borderRadius, csssize(48), {
|
|
284
|
+
export const Thumbnail = styled.div(borderRadius, csssize(48), props => ({
|
|
285
285
|
float: 'right',
|
|
286
286
|
margin: `${"var(--ds-space-050, 4px)"} 0 ${"var(--ds-space-150, 12px)"} ${"var(--ds-space-150, 12px)"}`,
|
|
287
287
|
backgroundColor: `var(--ds-skeleton, ${colors.N30})`,
|
|
288
|
-
backgroundImage: `url(${
|
|
289
|
-
src
|
|
290
|
-
}) => src})`,
|
|
288
|
+
backgroundImage: `url(${props.src})`,
|
|
291
289
|
backgroundSize: 'cover'
|
|
292
|
-
});
|
|
290
|
+
}));
|
|
293
291
|
export const UsersWrapper = styled.div({
|
|
294
292
|
marginTop: "var(--ds-space-100, 8px)"
|
|
295
293
|
});
|
|
@@ -7,7 +7,7 @@ import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-m
|
|
|
7
7
|
import LinkWarningModal from './LinkWarningModal';
|
|
8
8
|
const PACKAGE_DATA = {
|
|
9
9
|
packageName: "@atlaskit/smart-card",
|
|
10
|
-
packageVersion: "26.50.
|
|
10
|
+
packageVersion: "26.50.8",
|
|
11
11
|
componentName: 'linkUrl'
|
|
12
12
|
};
|
|
13
13
|
const Link = withLinkClickedEvent('a');
|
|
@@ -18,7 +18,7 @@ var aiExperience = {
|
|
|
18
18
|
component: 'smart-links'
|
|
19
19
|
},
|
|
20
20
|
type: ExperienceTypes.Experience,
|
|
21
|
-
performanceType: ExperiencePerformanceTypes.
|
|
21
|
+
performanceType: ExperiencePerformanceTypes.InlineResult
|
|
22
22
|
};
|
|
23
23
|
var ufoExperiences = {
|
|
24
24
|
'smart-link-rendered': new ConcurrentExperience('smart-link-rendered', renderExperience),
|
|
@@ -15,7 +15,7 @@ export var ANALYTICS_CHANNEL = 'media';
|
|
|
15
15
|
export var context = {
|
|
16
16
|
componentName: 'smart-cards',
|
|
17
17
|
packageName: "@atlaskit/smart-card",
|
|
18
|
-
packageVersion: "26.50.
|
|
18
|
+
packageVersion: "26.50.8"
|
|
19
19
|
};
|
|
20
20
|
export var TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
21
21
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -115,12 +115,13 @@ function Component(_ref) {
|
|
|
115
115
|
useEffect(function () {
|
|
116
116
|
measure.mark(id, state.status);
|
|
117
117
|
if (state.status !== 'pending' && state.status !== 'resolving') {
|
|
118
|
+
var _state$error;
|
|
118
119
|
measure.create(id, state.status);
|
|
119
120
|
analytics.operational.instrument({
|
|
120
121
|
id: id,
|
|
121
122
|
status: state.status,
|
|
122
123
|
definitionId: definitionId,
|
|
123
|
-
extensionKey: extensionKey,
|
|
124
|
+
extensionKey: extensionKey !== null && extensionKey !== void 0 ? extensionKey : (_state$error = state.error) === null || _state$error === void 0 ? void 0 : _state$error.extensionKey,
|
|
124
125
|
resourceType: resourceType,
|
|
125
126
|
error: state.error
|
|
126
127
|
});
|
|
@@ -173,15 +173,14 @@ export var Description = styled.div({
|
|
|
173
173
|
export var ResolvedViewIconWrapper = styled.div({
|
|
174
174
|
marginTop: "var(--ds-space-050, 4px)"
|
|
175
175
|
});
|
|
176
|
-
export var Thumbnail = styled.div(borderRadius, csssize(48), {
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
}
|
|
184
|
-
backgroundSize: 'cover'
|
|
176
|
+
export var Thumbnail = styled.div(borderRadius, csssize(48), function (props) {
|
|
177
|
+
return {
|
|
178
|
+
float: 'right',
|
|
179
|
+
margin: "var(--ds-space-050, 4px)".concat(" 0 ", "var(--ds-space-150, 12px)", " ", "var(--ds-space-150, 12px)"),
|
|
180
|
+
backgroundColor: "var(--ds-skeleton, ".concat(colors.N30, ")"),
|
|
181
|
+
backgroundImage: "url(".concat(props.src, ")"),
|
|
182
|
+
backgroundSize: 'cover'
|
|
183
|
+
};
|
|
185
184
|
});
|
|
186
185
|
export var UsersWrapper = styled.div({
|
|
187
186
|
marginTop: "var(--ds-space-100, 8px)"
|
|
@@ -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.50.
|
|
13
|
+
packageVersion: "26.50.8",
|
|
14
14
|
componentName: 'linkUrl'
|
|
15
15
|
};
|
|
16
16
|
var Link = withLinkClickedEvent('a');
|
|
@@ -23,5 +23,5 @@ type EventPayload<K extends EventKey> = {
|
|
|
23
23
|
actionSubjectId?: string;
|
|
24
24
|
attributes?: AnalyticsEventAttributes[K];
|
|
25
25
|
};
|
|
26
|
-
declare const createEventPayload: <K extends keyof AnalyticsEventAttributes>(eventKey: K, ...[attributes]:
|
|
26
|
+
declare const createEventPayload: <K extends keyof AnalyticsEventAttributes>(eventKey: K, ...[attributes]: EventPayloadAttributes<K>) => ScreenEventPayload<K> | EventPayload<K>;
|
|
27
27
|
export default createEventPayload;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export declare const useAnalyticsEvents: () => {
|
|
2
|
-
fireEvent: <K extends keyof import("./analytics.types").AnalyticsEventAttributes>(
|
|
2
|
+
fireEvent: <K extends keyof import("./analytics.types").AnalyticsEventAttributes>(eventKey: K, ...params_1: undefined extends import("./analytics.types").AnalyticsEventAttributes[K] ? [param?: import("./analytics.types").AnalyticsEventAttributes[K] | undefined] : [param: import("./analytics.types").AnalyticsEventAttributes[K]]) => void;
|
|
3
3
|
};
|
|
@@ -4,5 +4,5 @@ export declare enum ClickButton {
|
|
|
4
4
|
Middle = 1,
|
|
5
5
|
Right = 2
|
|
6
6
|
}
|
|
7
|
-
export declare const useLinkClicked: <T extends import("react").MouseEventHandler<Element>>(handler?: T
|
|
8
|
-
export declare const useMouseDownEvent: <T extends import("react").MouseEventHandler<Element>>(onMouseDown?: T
|
|
7
|
+
export declare const useLinkClicked: <T extends import("react").MouseEventHandler<Element>>(handler?: T, predicate?: ((event: React.MouseEvent) => boolean) | undefined) => (...args: Parameters<T>) => void;
|
|
8
|
+
export declare const useMouseDownEvent: <T extends import("react").MouseEventHandler<Element>>(onMouseDown?: T) => (...args: Parameters<T>) => void;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { InvokeRequest } from '@atlaskit/linking-types/smart-link-actions';
|
|
2
|
-
declare const createInvokeRequest: <TPayload extends object>(request: InvokeRequest, payload?: TPayload
|
|
2
|
+
declare const createInvokeRequest: <TPayload extends object>(request: InvokeRequest, payload?: TPayload) => InvokeRequest<TPayload>;
|
|
3
3
|
export default createInvokeRequest;
|
|
@@ -4,7 +4,7 @@ import { GasPayload } from '@atlaskit/analytics-gas-types';
|
|
|
4
4
|
import { ClickOutcome, ClickType, UiLinkClickedEventProps } from './types';
|
|
5
5
|
import { AnalyticsPayload } from '../types';
|
|
6
6
|
export declare const buttonMap: Map<number | undefined, "left" | "right" | "none" | "middle">;
|
|
7
|
-
export declare const getKeys: (e: React.MouseEvent) => ("meta" | "
|
|
7
|
+
export declare const getKeys: (e: React.MouseEvent) => ("meta" | "shift" | "alt" | "ctrl")[];
|
|
8
8
|
export declare function getLinkClickOutcome(e: React.MouseEvent, clickType: ClickType): ClickOutcome;
|
|
9
9
|
export declare const createLinkClickedPayload: (event: React.MouseEvent) => AnalyticsPayload | undefined;
|
|
10
10
|
type DeepPartial<T> = T extends object ? {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { CardAppearance, CardPlatform, CardProps } from './types';
|
|
3
3
|
import { WrappedComponentProps } from 'react-intl-next';
|
|
4
|
-
export declare const Card: React.ForwardRefExoticComponent<Pick<Omit<React.PropsWithChildren<import("react-intl-next").WithIntlProps<CardProps & WrappedComponentProps
|
|
4
|
+
export declare const Card: React.ForwardRefExoticComponent<Pick<Omit<React.PropsWithChildren<import("react-intl-next").WithIntlProps<CardProps & WrappedComponentProps>>, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps> & React.RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "url" | "children" | "data" | "key" | "id" | "placeholder" | "onError" | "onClick" | "appearance" | "container" | "testId" | "analyticsContext" | "isSelected" | "inheritDimensions" | "actionOptions" | "onResolve" | "ui" | "showHoverPreview" | "showAuthTooltip" | "platform" | "isHovered" | "isFrameVisible" | "frameStyle" | "importer" | "showActions" | "showServerActions" | "fallbackComponent" | "embedIframeRef" | "embedIframeUrlType" | "inlinePreloaderStyle" | "analyticsEvents" | "useLegacyBlockCard" | "forwardedRef"> & React.RefAttributes<any>>;
|
|
5
5
|
export type { CardAppearance, CardProps, CardPlatform };
|
|
@@ -86,7 +86,7 @@ export interface ThumbnailProps {
|
|
|
86
86
|
export declare const Thumbnail: import("@emotion/styled").StyledComponent<{
|
|
87
87
|
theme?: import("@emotion/react").Theme | undefined;
|
|
88
88
|
as?: import("react").ElementType<any> | undefined;
|
|
89
|
-
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
89
|
+
} & ThumbnailProps, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
90
90
|
export declare const UsersWrapper: import("@emotion/styled").StyledComponent<{
|
|
91
91
|
theme?: import("@emotion/react").Theme | undefined;
|
|
92
92
|
as?: import("react").ElementType<any> | undefined;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export declare const LockImage
|
|
2
|
-
export declare const NotFoundImage
|
|
3
|
-
export declare const UnauthorisedImage
|
|
1
|
+
export declare const LockImage = "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/lock.svg";
|
|
2
|
+
export declare const NotFoundImage = "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/not_found.svg";
|
|
3
|
+
export declare const UnauthorisedImage = "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/unauth.svg";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const getUnresolvedEmbedCardImage: (status: 'forbidden' | 'unauthorized' | 'notFound') =>
|
|
1
|
+
export declare const getUnresolvedEmbedCardImage: (status: 'forbidden' | 'unauthorized' | 'notFound') => "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/lock.svg" | "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/not_found.svg" | "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/unauth.svg";
|
|
@@ -76,6 +76,10 @@ export type BaseActionItem = {
|
|
|
76
76
|
* Determines whether the action should hide the icon inside the button.
|
|
77
77
|
*/
|
|
78
78
|
hideIcon?: boolean;
|
|
79
|
+
/**
|
|
80
|
+
* Determines where the icon should be rendered if text is provided.
|
|
81
|
+
*/
|
|
82
|
+
iconPosition?: 'before' | 'after';
|
|
79
83
|
/**
|
|
80
84
|
* Determines the text and icon representation of the action, with exception
|
|
81
85
|
* to CustomAction.
|
|
@@ -85,6 +89,10 @@ export type BaseActionItem = {
|
|
|
85
89
|
* Determines the onClick behaviour of the action.
|
|
86
90
|
*/
|
|
87
91
|
onClick: () => any;
|
|
92
|
+
/**
|
|
93
|
+
* Determines the text content of the Action.
|
|
94
|
+
*/
|
|
95
|
+
content?: React.ReactNode;
|
|
88
96
|
/**
|
|
89
97
|
* Additional CSS properties on the Action.
|
|
90
98
|
*/
|
|
@@ -8,7 +8,7 @@ interface LinkWarningModalProps {
|
|
|
8
8
|
unsafeLinkText: string | null;
|
|
9
9
|
url: string | null;
|
|
10
10
|
}
|
|
11
|
-
declare const _default: React.FC<import("react-intl-next").WithIntlProps<LinkWarningModalProps & WrappedComponentProps
|
|
12
|
-
WrappedComponent: React.ComponentType<LinkWarningModalProps & WrappedComponentProps
|
|
11
|
+
declare const _default: React.FC<import("react-intl-next").WithIntlProps<LinkWarningModalProps & WrappedComponentProps>> & {
|
|
12
|
+
WrappedComponent: React.ComponentType<LinkWarningModalProps & WrappedComponentProps>;
|
|
13
13
|
};
|
|
14
14
|
export default _default;
|
|
@@ -27,5 +27,5 @@ type EventPayload<K extends EventKey> = {
|
|
|
27
27
|
actionSubjectId?: string;
|
|
28
28
|
attributes?: AnalyticsEventAttributes[K];
|
|
29
29
|
};
|
|
30
|
-
declare const createEventPayload: <K extends keyof AnalyticsEventAttributes>(eventKey: K, ...[attributes]:
|
|
30
|
+
declare const createEventPayload: <K extends keyof AnalyticsEventAttributes>(eventKey: K, ...[attributes]: EventPayloadAttributes<K>) => ScreenEventPayload<K> | EventPayload<K>;
|
|
31
31
|
export default createEventPayload;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export declare const useAnalyticsEvents: () => {
|
|
2
|
-
fireEvent: <K extends keyof import("./analytics.types").AnalyticsEventAttributes>(
|
|
2
|
+
fireEvent: <K extends keyof import("./analytics.types").AnalyticsEventAttributes>(eventKey: K, ...params_1: undefined extends import("./analytics.types").AnalyticsEventAttributes[K] ? [
|
|
3
3
|
param?: import("./analytics.types").AnalyticsEventAttributes[K] | undefined
|
|
4
4
|
] : [
|
|
5
5
|
param: import("./analytics.types").AnalyticsEventAttributes[K]
|
|
@@ -4,5 +4,5 @@ export declare enum ClickButton {
|
|
|
4
4
|
Middle = 1,
|
|
5
5
|
Right = 2
|
|
6
6
|
}
|
|
7
|
-
export declare const useLinkClicked: <T extends import("react").MouseEventHandler<Element>>(handler?: T
|
|
8
|
-
export declare const useMouseDownEvent: <T extends import("react").MouseEventHandler<Element>>(onMouseDown?: T
|
|
7
|
+
export declare const useLinkClicked: <T extends import("react").MouseEventHandler<Element>>(handler?: T, predicate?: ((event: React.MouseEvent) => boolean) | undefined) => (...args: Parameters<T>) => void;
|
|
8
|
+
export declare const useMouseDownEvent: <T extends import("react").MouseEventHandler<Element>>(onMouseDown?: T) => (...args: Parameters<T>) => void;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { InvokeRequest } from '@atlaskit/linking-types/smart-link-actions';
|
|
2
|
-
declare const createInvokeRequest: <TPayload extends object>(request: InvokeRequest, payload?: TPayload
|
|
2
|
+
declare const createInvokeRequest: <TPayload extends object>(request: InvokeRequest, payload?: TPayload) => InvokeRequest<TPayload>;
|
|
3
3
|
export default createInvokeRequest;
|
|
@@ -4,7 +4,7 @@ import { GasPayload } from '@atlaskit/analytics-gas-types';
|
|
|
4
4
|
import { ClickOutcome, ClickType, UiLinkClickedEventProps } from './types';
|
|
5
5
|
import { AnalyticsPayload } from '../types';
|
|
6
6
|
export declare const buttonMap: Map<number | undefined, "left" | "right" | "none" | "middle">;
|
|
7
|
-
export declare const getKeys: (e: React.MouseEvent) => ("meta" | "
|
|
7
|
+
export declare const getKeys: (e: React.MouseEvent) => ("meta" | "shift" | "alt" | "ctrl")[];
|
|
8
8
|
export declare function getLinkClickOutcome(e: React.MouseEvent, clickType: ClickType): ClickOutcome;
|
|
9
9
|
export declare const createLinkClickedPayload: (event: React.MouseEvent) => AnalyticsPayload | undefined;
|
|
10
10
|
type DeepPartial<T> = T extends object ? {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { CardAppearance, CardPlatform, CardProps } from './types';
|
|
3
3
|
import { WrappedComponentProps } from 'react-intl-next';
|
|
4
|
-
export declare const Card: React.ForwardRefExoticComponent<Pick<Omit<React.PropsWithChildren<import("react-intl-next").WithIntlProps<CardProps & WrappedComponentProps
|
|
4
|
+
export declare const Card: React.ForwardRefExoticComponent<Pick<Omit<React.PropsWithChildren<import("react-intl-next").WithIntlProps<CardProps & WrappedComponentProps>>, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps> & React.RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "url" | "children" | "data" | "key" | "id" | "placeholder" | "onError" | "onClick" | "appearance" | "container" | "testId" | "analyticsContext" | "isSelected" | "inheritDimensions" | "actionOptions" | "onResolve" | "ui" | "showHoverPreview" | "showAuthTooltip" | "platform" | "isHovered" | "isFrameVisible" | "frameStyle" | "importer" | "showActions" | "showServerActions" | "fallbackComponent" | "embedIframeRef" | "embedIframeUrlType" | "inlinePreloaderStyle" | "analyticsEvents" | "useLegacyBlockCard" | "forwardedRef"> & React.RefAttributes<any>>;
|
|
5
5
|
export type { CardAppearance, CardProps, CardPlatform };
|
|
@@ -86,7 +86,7 @@ export interface ThumbnailProps {
|
|
|
86
86
|
export declare const Thumbnail: import("@emotion/styled").StyledComponent<{
|
|
87
87
|
theme?: import("@emotion/react").Theme | undefined;
|
|
88
88
|
as?: import("react").ElementType<any> | undefined;
|
|
89
|
-
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
89
|
+
} & ThumbnailProps, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
90
90
|
export declare const UsersWrapper: import("@emotion/styled").StyledComponent<{
|
|
91
91
|
theme?: import("@emotion/react").Theme | undefined;
|
|
92
92
|
as?: import("react").ElementType<any> | undefined;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export declare const LockImage
|
|
2
|
-
export declare const NotFoundImage
|
|
3
|
-
export declare const UnauthorisedImage
|
|
1
|
+
export declare const LockImage = "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/lock.svg";
|
|
2
|
+
export declare const NotFoundImage = "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/not_found.svg";
|
|
3
|
+
export declare const UnauthorisedImage = "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/unauth.svg";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const getUnresolvedEmbedCardImage: (status: 'forbidden' | 'unauthorized' | 'notFound') =>
|
|
1
|
+
export declare const getUnresolvedEmbedCardImage: (status: 'forbidden' | 'unauthorized' | 'notFound') => "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/lock.svg" | "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/not_found.svg" | "https://smart-links-cdn.us-east-1.prod.public.atl-paas.net/unauth.svg";
|
|
@@ -76,6 +76,10 @@ export type BaseActionItem = {
|
|
|
76
76
|
* Determines whether the action should hide the icon inside the button.
|
|
77
77
|
*/
|
|
78
78
|
hideIcon?: boolean;
|
|
79
|
+
/**
|
|
80
|
+
* Determines where the icon should be rendered if text is provided.
|
|
81
|
+
*/
|
|
82
|
+
iconPosition?: 'before' | 'after';
|
|
79
83
|
/**
|
|
80
84
|
* Determines the text and icon representation of the action, with exception
|
|
81
85
|
* to CustomAction.
|
|
@@ -85,6 +89,10 @@ export type BaseActionItem = {
|
|
|
85
89
|
* Determines the onClick behaviour of the action.
|
|
86
90
|
*/
|
|
87
91
|
onClick: () => any;
|
|
92
|
+
/**
|
|
93
|
+
* Determines the text content of the Action.
|
|
94
|
+
*/
|
|
95
|
+
content?: React.ReactNode;
|
|
88
96
|
/**
|
|
89
97
|
* Additional CSS properties on the Action.
|
|
90
98
|
*/
|
|
@@ -8,7 +8,7 @@ interface LinkWarningModalProps {
|
|
|
8
8
|
unsafeLinkText: string | null;
|
|
9
9
|
url: string | null;
|
|
10
10
|
}
|
|
11
|
-
declare const _default: React.FC<import("react-intl-next").WithIntlProps<LinkWarningModalProps & WrappedComponentProps
|
|
12
|
-
WrappedComponent: React.ComponentType<LinkWarningModalProps & WrappedComponentProps
|
|
11
|
+
declare const _default: React.FC<import("react-intl-next").WithIntlProps<LinkWarningModalProps & WrappedComponentProps>> & {
|
|
12
|
+
WrappedComponent: React.ComponentType<LinkWarningModalProps & WrappedComponentProps>;
|
|
13
13
|
};
|
|
14
14
|
export default _default;
|
package/hooks/package.json
CHANGED
package/hover-card/package.json
CHANGED
package/in-product/package.json
CHANGED
package/link-url/package.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/smart-card",
|
|
3
|
-
"version": "26.50.
|
|
3
|
+
"version": "26.50.8",
|
|
4
4
|
"description": "Smart card component",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"@atlaskit/link-analytics": "^8.3.0",
|
|
44
44
|
"@atlaskit/link-client-extension": "^1.8.0",
|
|
45
45
|
"@atlaskit/link-extractors": "^1.2.0",
|
|
46
|
-
"@atlaskit/linking-common": "^5.
|
|
46
|
+
"@atlaskit/linking-common": "^5.6.0",
|
|
47
47
|
"@atlaskit/linking-types": "^8.7.0",
|
|
48
48
|
"@atlaskit/logo": "^13.15.0",
|
|
49
49
|
"@atlaskit/lozenge": "^11.6.0",
|
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
"uuid": "^3.1.0"
|
|
75
75
|
},
|
|
76
76
|
"peerDependencies": {
|
|
77
|
-
"@atlaskit/link-provider": "^1.
|
|
77
|
+
"@atlaskit/link-provider": "^1.9.0",
|
|
78
78
|
"react": "^16.8.0",
|
|
79
79
|
"react-dom": "^16.8.0",
|
|
80
80
|
"react-intl-next": "npm:react-intl@^5.18.1"
|
|
@@ -84,7 +84,7 @@
|
|
|
84
84
|
"@af/visual-regression": "*",
|
|
85
85
|
"@atlaskit/analytics-listeners": "^8.9.0",
|
|
86
86
|
"@atlaskit/css-reset": "^6.7.0",
|
|
87
|
-
"@atlaskit/link-test-helpers": "^
|
|
87
|
+
"@atlaskit/link-test-helpers": "^7.0.0",
|
|
88
88
|
"@atlaskit/media-test-helpers": "^33.0.0",
|
|
89
89
|
"@atlaskit/ssr": "*",
|
|
90
90
|
"@atlaskit/visual-regression": "*",
|
|
@@ -116,7 +116,7 @@
|
|
|
116
116
|
"react-intl-next": "npm:react-intl@^5.18.1",
|
|
117
117
|
"react-test-renderer": "^16.8.0",
|
|
118
118
|
"ts-jest": "26.5.6",
|
|
119
|
-
"typescript": "~4.
|
|
119
|
+
"typescript": "~5.4.2",
|
|
120
120
|
"xhr-mock": "^2.4.0"
|
|
121
121
|
},
|
|
122
122
|
"techstack": {
|
package/ssr/package.json
CHANGED