@atlaskit/smart-card 30.2.7 → 30.3.1

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.
Files changed (81) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/dist/cjs/state/analytics/useSmartLinkAnalytics.js +146 -216
  3. package/dist/cjs/utils/analytics/analytics.js +78 -140
  4. package/dist/cjs/utils/analytics/index.js +0 -6
  5. package/dist/cjs/view/BlockCard/components/Name.js +1 -3
  6. package/dist/cjs/view/BlockCard/views/ResolvingView.js +1 -2
  7. package/dist/cjs/view/CardWithUrl/component.js +14 -41
  8. package/dist/cjs/view/EmbedCard/components/styled.js +4 -11
  9. package/dist/cjs/view/EmbedCard/views/ErroredView.js +2 -2
  10. package/dist/cjs/view/EmbedCard/views/unresolved-view/index.js +1 -1
  11. package/dist/cjs/view/EmbedModal/components/link-info/styled.js +2 -3
  12. package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +1 -6
  13. package/dist/cjs/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-modal/sub-components/header/main.js +2 -4
  14. package/dist/cjs/view/FlexibleCard/components/actions/follow-action/goal-icon/index.js +2 -21
  15. package/dist/cjs/view/FlexibleCard/components/actions/follow-action/projects-icon/index.js +3 -21
  16. package/dist/cjs/view/FlexibleCard/components/actions/follow-action/unfollow-icon/index.js +4 -28
  17. package/dist/cjs/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +1 -4
  18. package/dist/cjs/view/FlexibleCard/components/blocks/ai-footer-block/icons/info/index.js +6 -23
  19. package/dist/cjs/view/FlexibleCard/components/blocks/ai-footer-block/resolved/ai-footer-metadata.js +2 -2
  20. package/dist/cjs/view/FlexibleCard/components/elements/link/index.js +1 -1
  21. package/dist/cjs/view/LinkUrl/index.js +1 -1
  22. package/dist/es2019/state/analytics/useSmartLinkAnalytics.js +1 -69
  23. package/dist/es2019/utils/analytics/analytics.js +1 -63
  24. package/dist/es2019/utils/analytics/index.js +1 -1
  25. package/dist/es2019/view/BlockCard/components/Name.js +1 -3
  26. package/dist/es2019/view/BlockCard/views/ResolvingView.js +1 -2
  27. package/dist/es2019/view/CardWithUrl/component.js +14 -41
  28. package/dist/es2019/view/EmbedCard/components/styled.js +4 -11
  29. package/dist/es2019/view/EmbedCard/views/ErroredView.js +2 -2
  30. package/dist/es2019/view/EmbedCard/views/unresolved-view/index.js +1 -1
  31. package/dist/es2019/view/EmbedModal/components/link-info/styled.js +2 -3
  32. package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +1 -6
  33. package/dist/es2019/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-modal/sub-components/header/main.js +2 -4
  34. package/dist/es2019/view/FlexibleCard/components/actions/follow-action/goal-icon/index.js +1 -16
  35. package/dist/es2019/view/FlexibleCard/components/actions/follow-action/projects-icon/index.js +2 -16
  36. package/dist/es2019/view/FlexibleCard/components/actions/follow-action/unfollow-icon/index.js +4 -26
  37. package/dist/es2019/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +1 -4
  38. package/dist/es2019/view/FlexibleCard/components/blocks/ai-footer-block/icons/info/index.js +6 -21
  39. package/dist/es2019/view/FlexibleCard/components/blocks/ai-footer-block/resolved/ai-footer-metadata.js +2 -2
  40. package/dist/es2019/view/FlexibleCard/components/elements/link/index.js +1 -1
  41. package/dist/es2019/view/LinkUrl/index.js +1 -1
  42. package/dist/esm/state/analytics/useSmartLinkAnalytics.js +147 -217
  43. package/dist/esm/utils/analytics/analytics.js +77 -139
  44. package/dist/esm/utils/analytics/index.js +1 -1
  45. package/dist/esm/view/BlockCard/components/Name.js +1 -3
  46. package/dist/esm/view/BlockCard/views/ResolvingView.js +1 -2
  47. package/dist/esm/view/CardWithUrl/component.js +14 -41
  48. package/dist/esm/view/EmbedCard/components/styled.js +4 -11
  49. package/dist/esm/view/EmbedCard/views/ErroredView.js +2 -2
  50. package/dist/esm/view/EmbedCard/views/unresolved-view/index.js +1 -1
  51. package/dist/esm/view/EmbedModal/components/link-info/styled.js +2 -3
  52. package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +1 -6
  53. package/dist/esm/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-modal/sub-components/header/main.js +2 -4
  54. package/dist/esm/view/FlexibleCard/components/actions/follow-action/goal-icon/index.js +1 -20
  55. package/dist/esm/view/FlexibleCard/components/actions/follow-action/projects-icon/index.js +2 -20
  56. package/dist/esm/view/FlexibleCard/components/actions/follow-action/unfollow-icon/index.js +4 -28
  57. package/dist/esm/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +1 -4
  58. package/dist/esm/view/FlexibleCard/components/blocks/ai-footer-block/icons/info/index.js +6 -23
  59. package/dist/esm/view/FlexibleCard/components/blocks/ai-footer-block/resolved/ai-footer-metadata.js +2 -2
  60. package/dist/esm/view/FlexibleCard/components/elements/link/index.js +1 -1
  61. package/dist/esm/view/LinkUrl/index.js +1 -1
  62. package/dist/types/state/analytics/useSmartLinkAnalytics.d.ts +1 -29
  63. package/dist/types/state/hooks/useSmartLink.d.ts +0 -2
  64. package/dist/types/utils/analytics/analytics.d.ts +1 -9
  65. package/dist/types/utils/analytics/index.d.ts +1 -1
  66. package/dist/types/utils/analytics/types.d.ts +0 -12
  67. package/dist/types/utils/mocks.d.ts +0 -2
  68. package/dist/types/view/FlexibleCard/components/blocks/ai-footer-block/icons/info/index.d.ts +2 -2
  69. package/dist/types-ts4.5/state/analytics/useSmartLinkAnalytics.d.ts +1 -29
  70. package/dist/types-ts4.5/state/hooks/useSmartLink.d.ts +0 -2
  71. package/dist/types-ts4.5/utils/analytics/analytics.d.ts +1 -9
  72. package/dist/types-ts4.5/utils/analytics/index.d.ts +1 -1
  73. package/dist/types-ts4.5/utils/analytics/types.d.ts +0 -12
  74. package/dist/types-ts4.5/utils/mocks.d.ts +0 -2
  75. package/dist/types-ts4.5/view/FlexibleCard/components/blocks/ai-footer-block/icons/info/index.d.ts +2 -2
  76. package/package.json +4 -6
  77. package/dist/cjs/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-modal/sub-components/header/manual-trigger-icon/index.js +0 -29
  78. package/dist/es2019/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-modal/sub-components/header/manual-trigger-icon/index.js +0 -20
  79. package/dist/esm/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-modal/sub-components/header/manual-trigger-icon/index.js +0 -22
  80. package/dist/types/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-modal/sub-components/header/manual-trigger-icon/index.d.ts +0 -3
  81. package/dist/types-ts4.5/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-modal/sub-components/header/manual-trigger-icon/index.d.ts +0 -3
@@ -7,35 +7,11 @@ Object.defineProperty(exports, "__esModule", {
7
7
  exports.default = void 0;
8
8
  var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
9
9
  var _react = _interopRequireDefault(require("react"));
10
- var _icon = _interopRequireDefault(require("@atlaskit/icon"));
11
- var UnfollowGlyph = function UnfollowGlyph(props) {
12
- return /*#__PURE__*/_react.default.createElement("svg", {
13
- width: "16",
14
- height: "16",
15
- viewBox: "0 0 16 16",
16
- "data-testid": props['data-testid'],
17
- "aria-label": props['aria-label']
18
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
19
- ,
20
- className: props.className,
21
- role: "presentation",
22
- xmlns: "http://www.w3.org/2000/svg"
23
- }, /*#__PURE__*/_react.default.createElement("path", {
24
- d: "M14 4.66667H11.3333C10.9652 4.66667 10.6667 4.96514 10.6667 5.33333C10.6667 5.70152 10.9652 6 11.3333 6H14C14.3682 6 14.6667 5.70152 14.6667 5.33333C14.6667 4.96514 14.3682 4.66667 14 4.66667Z",
25
- fill: "currentColor"
26
- }), /*#__PURE__*/_react.default.createElement("path", {
27
- fillRule: "evenodd",
28
- clipRule: "evenodd",
29
- d: "M3.33334 9.33333C3.33334 8.59667 3.93468 8 4.67268 8H9.99401C10.734 8 11.3333 8.596 11.3333 9.33733V12.2973C11.3333 14.5673 3.33334 14.5673 3.33334 12.2973V9.33333Z",
30
- fill: "currentColor"
31
- }), /*#__PURE__*/_react.default.createElement("path", {
32
- d: "M7.33334 7.33333C8.8061 7.33333 10 6.13943 10 4.66667C10 3.19391 8.8061 2 7.33334 2C5.86058 2 4.66668 3.19391 4.66668 4.66667C4.66668 6.13943 5.86058 7.33333 7.33334 7.33333Z",
33
- fill: "currentColor"
34
- }));
35
- };
10
+ var _personRemove = _interopRequireDefault(require("@atlaskit/icon/core/person-remove"));
11
+ var _unfollowIcon = _interopRequireDefault(require("@atlaskit/legacy-custom-icons/unfollow-icon"));
36
12
  var UnfollowIcon = function UnfollowIcon(props) {
37
- return /*#__PURE__*/_react.default.createElement(_icon.default, (0, _extends2.default)({
38
- glyph: UnfollowGlyph
13
+ return /*#__PURE__*/_react.default.createElement(_personRemove.default, (0, _extends2.default)({
14
+ LEGACY_fallbackIcon: _unfollowIcon.default
39
15
  }, props));
40
16
  };
41
17
  var _default = exports.default = UnfollowIcon;
@@ -30,10 +30,7 @@ var errorContentStyles = (0, _primitives.xcss)({
30
30
  });
31
31
  var titleStyles = (0, _primitives.xcss)({
32
32
  color: 'color.text.subtle',
33
- fontSize: '12px',
34
- fontStyle: 'normal',
35
- fontWeight: '400',
36
- lineHeight: '16px'
33
+ font: "var(--ds-font-body-UNSAFE_small, normal 400 12px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)"
37
34
  });
38
35
  var getIcon = function getIcon(appearance) {
39
36
  switch (appearance) {
@@ -7,28 +7,11 @@ Object.defineProperty(exports, "__esModule", {
7
7
  exports.InfoIcon = void 0;
8
8
  var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
9
9
  var _react = _interopRequireDefault(require("react"));
10
- var _icon = _interopRequireDefault(require("@atlaskit/icon"));
11
- var CustomGlyph = function CustomGlyph(props) {
12
- return /*#__PURE__*/_react.default.createElement("svg", (0, _extends2.default)({
13
- width: "16",
14
- height: "16",
15
- viewBox: "0 0 16 16",
16
- fill: "none"
17
- }, props), /*#__PURE__*/_react.default.createElement("path", {
18
- d: "M7 5C7 5.55228 7.44772 6 8 6C8.55228 6 9 5.55228 9 5C9 4.44772 8.55228 4 8 4C7.44772 4 7 4.44772 7 5Z",
19
- fill: "currentColor"
20
- }), /*#__PURE__*/_react.default.createElement("path", {
21
- d: "M7.25 7L7.25 12H8.75L8.75 7H7.25Z",
22
- fill: "currentColor"
23
- }), /*#__PURE__*/_react.default.createElement("path", {
24
- fillRule: "evenodd",
25
- clipRule: "evenodd",
26
- d: "M8 1C4.13401 1 1 4.13401 1 8C1 11.866 4.13401 15 8 15C11.866 15 15 11.866 15 8C15 4.13401 11.866 1 8 1ZM2.5 8C2.5 11.0376 4.96243 13.5 8 13.5C11.0376 13.5 13.5 11.0376 13.5 8C13.5 4.96243 11.0376 2.5 8 2.5C4.96243 2.5 2.5 4.96243 2.5 8Z",
27
- fill: "currentColor"
28
- }));
29
- };
10
+ var _information = _interopRequireDefault(require("@atlaskit/icon/core/information"));
11
+ var _infoIcon = _interopRequireDefault(require("@atlaskit/legacy-custom-icons/info-icon"));
30
12
  var InfoIcon = exports.InfoIcon = function InfoIcon(props) {
31
- return /*#__PURE__*/_react.default.createElement(_icon.default, (0, _extends2.default)({}, props, {
32
- glyph: CustomGlyph
33
- }));
13
+ return /*#__PURE__*/_react.default.createElement(_information.default, (0, _extends2.default)({
14
+ color: props.color || 'currentColor',
15
+ LEGACY_fallbackIcon: _infoIcon.default
16
+ }, props));
34
17
  };
@@ -34,8 +34,8 @@ var AIFooterMetadata = exports.AIFooterMetadata = function AIFooterMetadata(_ref
34
34
  }, function (tooltipProps) {
35
35
  return /*#__PURE__*/_react.default.createElement(_primitives.Box, tooltipProps, /*#__PURE__*/_react.default.createElement(_info.InfoIcon, {
36
36
  label: "Information",
37
- size: "small",
38
- primaryColor: "var(--ds-icon-subtle, #626F86)"
37
+ LEGACY_size: "small",
38
+ color: "var(--ds-icon-subtle, #626F86)"
39
39
  }));
40
40
  }), /*#__PURE__*/_react.default.createElement(_atlassianIntelligence.default, {
41
41
  label: "AI",
@@ -41,7 +41,7 @@ var getThemeStyles = function getThemeStyles(theme) {
41
41
  color: "var(--ds-text-subtlest, #626F86)",
42
42
  textDecoration: 'underline'
43
43
  },
44
- fontSize: '12px'
44
+ font: "var(--ds-font-body-UNSAFE_small, normal 400 12px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)"
45
45
  }
46
46
  });
47
47
  // eslint-disable-next-line @atlaskit/design-system/ensure-design-token-usage
@@ -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: "30.2.7",
20
+ packageVersion: "30.3.1",
21
21
  componentName: 'linkUrl'
22
22
  };
23
23
  var Link = (0, _click.withLinkClickedEvent)('a');
@@ -2,7 +2,7 @@ import { useMemo } from 'react';
2
2
  import { useSmartLinkContext } from '@atlaskit/link-provider';
3
3
  import { getUrl } from '@atlaskit/linking-common';
4
4
  import { chunkloadFailedEvent, connectFailedEvent, connectSucceededEvent, context, instrumentEvent, invokeFailedEvent, invokeSucceededEvent, screenAuthPopupEvent, trackAppAccountAuthStarted, trackAppAccountConnected, uiActionClickedEvent, uiAuthAlternateAccountEvent, uiAuthEvent, uiCardClickedEvent, uiClosedAuthEvent, uiHoverCardDismissedEvent, uiHoverCardOpenLinkClickedEvent, uiHoverCardViewedEvent, uiLearnMoreLinkClickedEvent, uiRenderFailedEvent, uiRenderSuccessEvent, uiSmartLinkStatusListItemButtonClicked, uiSmartLinkStatusLozengeButtonClicked, uiSmartLinkStatusOpenPreviewButtonClicked } from '../../utils/analytics';
5
- import { trackHoverCardResolutionStarted, trackSmartLinkQuickActionFailed, trackSmartLinkQuickActionStarted, trackSmartLinkQuickActionSuccess, uiIframeDwelledEvent, uiIframeFocusedEvent, uiServerActionClicked } from '../../utils/analytics/analytics';
5
+ import { trackHoverCardResolutionStarted, trackSmartLinkQuickActionFailed, trackSmartLinkQuickActionStarted, trackSmartLinkQuickActionSuccess, uiServerActionClicked } from '../../utils/analytics/analytics';
6
6
  import { getDefinitionId, getExtensionKey, getProduct, getResourceType, getStatusDetails, getSubproduct } from '../helpers';
7
7
  import { failUfoExperience, startUfoExperience, succeedUfoExperience } from './ufoExperiences';
8
8
  import { useDispatchAnalytics } from './useDispatchAnalytics';
@@ -157,74 +157,6 @@ export const useSmartLinkAnalytics = (url, id, defaultLocation) => {
157
157
  destinationSubproduct,
158
158
  actionSubjectId
159
159
  }), commonAttributes)),
160
- /**
161
- * This fires an event that represents when a user dwells their cursor on a Smart Link's iframe.
162
- * @param id The unique ID for this Smart Link.
163
- * @param display Whether the card was an Inline, Block, Embed or Flexible UI.
164
- * @param status What status the Smart Link is currently in (e.g. resolved, unresolved)
165
- * @param definitionId The definitionId of the Smart Link resolver invoked.
166
- * @param extensionKey The extensionKey of the Smart Link resovler invoked.
167
- * @param location Where the Smart Link is currently rendered.
168
- * @param destinationProduct The product the Smart Link is linked to.
169
- * @param dwellTime Total seconds that the user has dwelled on this iframe
170
- * @param dwellPercentVisible Percentage element was visible at end of dwell
171
- * @returns
172
- * @deprecated
173
- */
174
- iframeDwelledEvent: ({
175
- id,
176
- display,
177
- status,
178
- definitionId,
179
- extensionKey,
180
- location,
181
- destinationProduct,
182
- destinationSubproduct,
183
- dwellTime,
184
- dwellPercentVisible
185
- }) => dispatchAnalytics(applyCommonAttributes(uiIframeDwelledEvent({
186
- id,
187
- display,
188
- status,
189
- definitionId,
190
- extensionKey,
191
- location,
192
- destinationProduct,
193
- destinationSubproduct,
194
- dwellTime,
195
- dwellPercentVisible
196
- }), commonAttributes)),
197
- /**
198
- * This fires an event that represents when a user clicks or tabs into a Smart Link's iframe.
199
- * @param id The unique ID for this Smart Link.
200
- * @param display Whether the card was an Inline, Block, Embed or Flexible UI.
201
- * @param status What status the Smart Link is currently in (e.g. resolved, unresolved)
202
- * @param definitionId The definitionId of the Smart Link resolver invoked.
203
- * @param extensionKey The extensionKey of the Smart Link resovler invoked.
204
- * @param location Where the Smart Link is currently rendered.
205
- * @param destinationProduct The product the Smart Link is linked to.
206
- * @returns
207
- * @deprecated
208
- */
209
- iframeFocusedEvent: ({
210
- id,
211
- display,
212
- status,
213
- definitionId,
214
- extensionKey,
215
- location,
216
- destinationProduct,
217
- destinationSubproduct
218
- }) => dispatchAnalytics(applyCommonAttributes(uiIframeFocusedEvent({
219
- id,
220
- display,
221
- status,
222
- definitionId,
223
- extensionKey,
224
- location,
225
- destinationProduct,
226
- destinationSubproduct
227
- }), commonAttributes)),
228
160
  /**
229
161
  * This fires an event that represents when a user clicks on a Smart Link action.
230
162
  * Note: This also starts the UFO smart-link-action-invocation experience.
@@ -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: "30.2.7"
7
+ packageVersion: "30.3.1"
8
8
  };
9
9
  export let TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
10
10
  TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
@@ -394,68 +394,6 @@ export const uiCardClickedEvent = ({
394
394
  destinationSubproduct
395
395
  }
396
396
  });
397
-
398
- /**
399
- * @deprecated
400
- */
401
- export const uiIframeDwelledEvent = ({
402
- id,
403
- display,
404
- status,
405
- definitionId,
406
- extensionKey,
407
- location,
408
- destinationProduct,
409
- destinationSubproduct,
410
- dwellTime,
411
- dwellPercentVisible
412
- }) => ({
413
- action: 'dwelled',
414
- actionSubject: 'smartLinkIframe',
415
- eventType: 'ui',
416
- attributes: {
417
- ...context,
418
- id,
419
- status,
420
- definitionId,
421
- extensionKey,
422
- display,
423
- location,
424
- destinationProduct,
425
- destinationSubproduct,
426
- dwellTime,
427
- dwellPercentVisible
428
- }
429
- });
430
-
431
- /**
432
- * @deprecated
433
- */
434
- export const uiIframeFocusedEvent = ({
435
- id,
436
- display,
437
- status,
438
- definitionId,
439
- extensionKey,
440
- location,
441
- destinationProduct,
442
- destinationSubproduct
443
- }) => ({
444
- action: 'focused',
445
- actionSubject: 'smartLinkIframe',
446
- eventType: 'ui',
447
- attributes: {
448
- ...context,
449
- id,
450
- status,
451
- definitionId,
452
- extensionKey,
453
- display,
454
- location,
455
- destinationProduct,
456
- destinationSubproduct
457
- }
458
- });
459
397
  export const uiActionClickedEvent = ({
460
398
  id,
461
399
  actionType,
@@ -1,6 +1,6 @@
1
1
  import { getMeasure } from '../performance';
2
2
  import { resolvedEvent, unresolvedEvent } from './analytics';
3
- export { ANALYTICS_CHANNEL, context, fireSmartLinkEvent, resolvedEvent, unresolvedEvent, invokeSucceededEvent, invokeFailedEvent, chunkloadFailedEvent, connectSucceededEvent, connectFailedEvent, trackAppAccountAuthStarted, trackAppAccountConnected, uiAuthEvent, uiAuthAlternateAccountEvent, uiCardClickedEvent, uiActionClickedEvent, uiClosedAuthEvent, screenAuthPopupEvent, uiRenderSuccessEvent, uiRenderFailedEvent, uiHoverCardViewedEvent, uiHoverCardDismissedEvent, uiHoverCardOpenLinkClickedEvent, uiLearnMoreLinkClickedEvent, uiIframeDwelledEvent, uiSmartLinkStatusLozengeButtonClicked, uiSmartLinkStatusListItemButtonClicked, uiSmartLinkStatusOpenPreviewButtonClicked } from './analytics';
3
+ export { ANALYTICS_CHANNEL, context, fireSmartLinkEvent, resolvedEvent, unresolvedEvent, invokeSucceededEvent, invokeFailedEvent, chunkloadFailedEvent, connectSucceededEvent, connectFailedEvent, trackAppAccountAuthStarted, trackAppAccountConnected, uiAuthEvent, uiAuthAlternateAccountEvent, uiCardClickedEvent, uiActionClickedEvent, uiClosedAuthEvent, screenAuthPopupEvent, uiRenderSuccessEvent, uiRenderFailedEvent, uiHoverCardViewedEvent, uiHoverCardDismissedEvent, uiHoverCardOpenLinkClickedEvent, uiLearnMoreLinkClickedEvent, uiSmartLinkStatusLozengeButtonClicked, uiSmartLinkStatusListItemButtonClicked, uiSmartLinkStatusOpenPreviewButtonClicked } from './analytics';
4
4
  export const instrumentEvent = ({
5
5
  id,
6
6
  status,
@@ -4,7 +4,6 @@
4
4
  */
5
5
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
6
6
  import { css, jsx } from '@emotion/react';
7
- import { fontSize } from '@atlaskit/theme/constants';
8
7
  import { gs } from '../../common/utils';
9
8
  /**
10
9
  * Class name for selecting non-flexible block card header name
@@ -14,8 +13,7 @@ import { gs } from '../../common/utils';
14
13
  */
15
14
  export const blockCardContentHeaderNameClassName = 'block-card-content-header-name';
16
15
  const baseStyles = css({
17
- fontSize: `${fontSize()}px`,
18
- fontWeight: 500,
16
+ font: "var(--ds-font-heading-xsmall, normal 600 14px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)",
19
17
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
20
18
  lineHeight: gs(2.5),
21
19
  // Spec: show max two lines.
@@ -7,7 +7,6 @@ import { css, jsx } from '@emotion/react';
7
7
  import { FormattedMessage } from 'react-intl-next';
8
8
  import DocumentFilledIcon from '@atlaskit/icon/core/migration/file--editor-file';
9
9
  import { N50, N90 } from '@atlaskit/theme/colors';
10
- import { fontSize } from '@atlaskit/theme/constants';
11
10
  import { messages } from '../../../messages';
12
11
  import { gs } from '../../common/utils';
13
12
  import { Frame } from '../components/Frame';
@@ -19,7 +18,7 @@ import { Frame } from '../components/Frame';
19
18
  */
20
19
  export const blockCardResolvingViewClassName = 'block-card-resolving-view';
21
20
  const messageStyles = css({
22
- fontSize: `${fontSize()}px`,
21
+ font: "var(--ds-font-heading-xsmall, normal 600 14px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)",
23
22
  color: `var(--ds-text-subtlest, ${N90})`,
24
23
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
25
24
  marginLeft: gs(0.5)
@@ -1,6 +1,5 @@
1
1
  import React, { useCallback, useEffect, useMemo } from 'react';
2
2
  import { useAnalyticsEvents as useAnalyticsEventsNext } from '@atlaskit/analytics-next';
3
- import { fg } from '@atlaskit/platform-feature-flags';
4
3
  import { useAnalyticsEvents } from '../../common/analytics/generated/use-analytics-events';
5
4
  import { CardDisplay } from '../../constants';
6
5
  import { useSmartLink } from '../../state';
@@ -148,47 +147,21 @@ function Component({
148
147
  }
149
148
  }, [isFlexibleUi, appearance, state.status, url, definitionId, extensionKey, analytics.ui, id, canBeDatasource]);
150
149
  const onIframeDwell = useCallback((dwellTime, dwellPercentVisible) => {
151
- if (fg('smart-card-migrate-smartlinkiframe-analytics')) {
152
- fireEvent('ui.smartLinkIframe.dwelled', {
153
- id,
154
- definitionId: definitionId !== null && definitionId !== void 0 ? definitionId : null,
155
- display: isFlexibleUi ? 'flexible' : appearance,
156
- dwellPercentVisible,
157
- dwellTime
158
- });
159
- } else {
160
- analytics.ui.iframeDwelledEvent({
161
- id,
162
- display: isFlexibleUi ? 'flexible' : appearance,
163
- status: state.status,
164
- definitionId,
165
- extensionKey,
166
- destinationProduct: product,
167
- destinationSubproduct: subproduct,
168
- dwellTime: dwellTime,
169
- dwellPercentVisible: dwellPercentVisible
170
- });
171
- }
172
- }, [id, state.status, analytics.ui, appearance, definitionId, extensionKey, isFlexibleUi, product, subproduct, fireEvent]);
150
+ fireEvent('ui.smartLinkIframe.dwelled', {
151
+ id,
152
+ definitionId: definitionId !== null && definitionId !== void 0 ? definitionId : null,
153
+ display: isFlexibleUi ? 'flexible' : appearance,
154
+ dwellPercentVisible,
155
+ dwellTime
156
+ });
157
+ }, [id, appearance, definitionId, isFlexibleUi, fireEvent]);
173
158
  const onIframeFocus = useCallback(() => {
174
- if (fg('smart-card-migrate-smartlinkiframe-analytics')) {
175
- fireEvent('ui.smartLinkIframe.focus', {
176
- id,
177
- definitionId: definitionId !== null && definitionId !== void 0 ? definitionId : null,
178
- display: isFlexibleUi ? 'flexible' : appearance
179
- });
180
- } else {
181
- analytics.ui.iframeFocusedEvent({
182
- id,
183
- display: isFlexibleUi ? 'flexible' : appearance,
184
- status: state.status,
185
- definitionId,
186
- extensionKey,
187
- destinationProduct: product,
188
- destinationSubproduct: subproduct
189
- });
190
- }
191
- }, [id, state.status, analytics.ui, appearance, definitionId, extensionKey, isFlexibleUi, product, subproduct, fireEvent]);
159
+ fireEvent('ui.smartLinkIframe.focus', {
160
+ id,
161
+ definitionId: definitionId !== null && definitionId !== void 0 ? definitionId : null,
162
+ display: isFlexibleUi ? 'flexible' : appearance
163
+ });
164
+ }, [id, appearance, definitionId, isFlexibleUi, fireEvent]);
192
165
  if (isFlexibleUi) {
193
166
  let cardState = state;
194
167
  if (error) {
@@ -214,8 +214,7 @@ ${/* eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-va
214
214
  }, {
215
215
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
216
216
  color: `var(--ds-text-subtlest, ${colors.N300})`,
217
- fontSize: '12px',
218
- lineHeight: '16px'
217
+ font: "var(--ds-font-body-UNSAFE_small, normal 400 12px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)"
219
218
  },
220
219
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
221
220
  ellipsis('none'));
@@ -292,9 +291,7 @@ export const ContentWrapper = styled.div({
292
291
  export const Title = styled.div({
293
292
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
294
293
  color: `var(--ds-text, ${colors.N900})`,
295
- fontSize: '16px',
296
- fontWeight: 500,
297
- lineHeight: 20 / 16,
294
+ font: "var(--ds-font-heading-small, normal 600 16px/20px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)",
298
295
  maxHeight: `${20 * 4}px`,
299
296
  overflow: 'hidden'
300
297
  });
@@ -304,9 +301,7 @@ export const Byline = styled.div({
304
301
  marginTop: "var(--ds-space-050, 4px)",
305
302
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
306
303
  color: `var(--ds-text-subtlest, ${colors.N300})`,
307
- fontSize: '12px',
308
- fontWeight: 'normal',
309
- lineHeight: 16 / 12
304
+ font: "var(--ds-font-body-UNSAFE_small, normal 400 12px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)"
310
305
  },
311
306
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
312
307
  ellipsis('100%'));
@@ -316,9 +311,7 @@ export const Description = styled.div({
316
311
  marginTop: `calc(${"var(--ds-space-100, 8px)"} - 1px)`,
317
312
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
318
313
  color: `var(--ds-text, ${colors.N800})`,
319
- fontSize: '12px',
320
- fontWeight: 'normal',
321
- lineHeight: 18 / 12,
314
+ font: "var(--ds-font-body-UNSAFE_small, normal 400 12px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)",
322
315
  maxHeight: `${18 * 3}px`,
323
316
  overflow: 'hidden'
324
317
  });
@@ -8,12 +8,12 @@ import { FormattedMessage } from 'react-intl-next';
8
8
  import Button from '@atlaskit/button';
9
9
  import ErrorIcon from '@atlaskit/icon/core/migration/error';
10
10
  import { R300 } from '@atlaskit/theme/colors';
11
- import { fontSize } from '@atlaskit/theme/constants';
12
11
  import { messages } from '../../../messages';
13
12
  import { Frame } from '../../BlockCard/components/Frame';
14
13
  import { gs } from '../../common/utils';
15
14
  const messageStyles = css({
16
- fontSize: `${fontSize()}px`,
15
+ font: "var(--ds-font-heading-xsmall, normal 600 14px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)",
16
+ fontWeight: "var(--ds-font-weight-regular, 400)",
17
17
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
18
18
  marginLeft: gs(0.5),
19
19
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
@@ -26,7 +26,7 @@ const contentStyles = css({
26
26
  maxWidth: gs(50)
27
27
  });
28
28
  const descriptionStyles = css({
29
- fontSize: '1em',
29
+ font: "var(--ds-font-body, normal 400 14px/20px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)",
30
30
  textAlign: 'center'
31
31
  });
32
32
  const imageStyles = css({
@@ -34,9 +34,8 @@ export const titleCss = css({
34
34
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
35
35
  h3: {
36
36
  flex: '1 1 auto',
37
- fontSize: '16px',
38
- fontWeight: 400,
39
- lineHeight: height,
37
+ font: "var(--ds-font-heading-small, normal 600 16px/20px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)",
38
+ fontWeight: "var(--ds-font-weight-regular, 400)",
40
39
  display: '-webkit-box',
41
40
  marginBottom: 0,
42
41
  overflow: 'hidden',
@@ -17,12 +17,7 @@ const buttonStyles = xcss({
17
17
  });
18
18
  const contentStyles = xcss({
19
19
  color: 'color.text',
20
- // Replace with font token once it becomes stable (currently alpha)
21
- // font: 'font.body.small',
22
- fontSize: '12px',
23
- fontStyle: 'normal',
24
- fontWeight: '400',
25
- lineHeight: '20px'
20
+ font: "var(--ds-font-body-UNSAFE_small, normal 400 12px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)"
26
21
  });
27
22
  const ActionButton = ({
28
23
  content,
@@ -1,12 +1,11 @@
1
1
  import React from 'react';
2
2
  import { defineMessages, useIntl } from 'react-intl-next';
3
3
  import Heading from '@atlaskit/heading';
4
- import Icon from '@atlaskit/icon';
4
+ import LegacyManualTriggerIcon from '@atlaskit/legacy-custom-icons/manual-trigger-icon';
5
5
  import { ModalHeader, useModal } from '@atlaskit/modal-dialog';
6
6
  import { Box, Inline, Stack, xcss } from '@atlaskit/primitives';
7
7
  import { G50 } from '@atlaskit/theme/colors';
8
8
  import { useAutomationMenu } from '../../menu-context';
9
- import { ManualTriggerGlyph } from './manual-trigger-icon';
10
9
  const i18n = defineMessages({
11
10
  modalHeaderIconLabel: {
12
11
  id: 'automation-menu.modal.header.icon.label',
@@ -43,9 +42,8 @@ export const AutomationModalHeader = ({
43
42
  xcss: iconStyle,
44
43
  paddingInline: "space.050",
45
44
  paddingBlock: "space.025"
46
- }, /*#__PURE__*/React.createElement(Icon, {
45
+ }, /*#__PURE__*/React.createElement(LegacyManualTriggerIcon, {
47
46
  size: "small",
48
- glyph: ManualTriggerGlyph,
49
47
  label: formatMessage(i18n.modalHeaderIconLabel),
50
48
  primaryColor: `var(--ds-icon-accent-green, ${G50})`
51
49
  })), /*#__PURE__*/React.createElement(Heading, {
@@ -1,22 +1,7 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
2
  import React from 'react';
3
- import Icon from '@atlaskit/icon';
4
3
  import GoalGlyph from '@atlaskit/icon/core/goal';
5
- const LegacyGoalGlyph = _props => /*#__PURE__*/React.createElement("svg", {
6
- xmlns: "http://www.w3.org/2000/svg",
7
- width: "16",
8
- height: "16",
9
- viewBox: "0 0 16 16",
10
- fill: "none"
11
- }, /*#__PURE__*/React.createElement("path", {
12
- fillRule: "evenodd",
13
- clipRule: "evenodd",
14
- d: "M12.6667 8C12.6667 10.5773 10.5773 12.6667 8 12.6667C5.42267 12.6667 3.33333 10.5773 3.33333 8C3.33333 5.42267 5.42267 3.33333 8 3.33333C10.5773 3.33333 12.6667 5.42267 12.6667 8ZM14 8C14 11.3137 11.3137 14 8 14C4.68629 14 2 11.3137 2 8C2 4.68629 4.68629 2 8 2C11.3137 2 14 4.68629 14 8ZM9.33333 8C9.33333 8.73638 8.73638 9.33333 8 9.33333C7.26362 9.33333 6.66667 8.73638 6.66667 8C6.66667 7.26362 7.26362 6.66667 8 6.66667C8.73638 6.66667 9.33333 7.26362 9.33333 8ZM10.6667 8C10.6667 9.47276 9.47276 10.6667 8 10.6667C6.52724 10.6667 5.33333 9.47276 5.33333 8C5.33333 6.52724 6.52724 5.33333 8 5.33333C9.47276 5.33333 10.6667 6.52724 10.6667 8Z",
15
- fill: "var(--ds-icon, #44546F)"
16
- }));
17
- const LegacyGoalIcon = props => /*#__PURE__*/React.createElement(Icon, _extends({
18
- glyph: LegacyGoalGlyph
19
- }, props));
4
+ import LegacyGoalIcon from '@atlaskit/legacy-custom-icons/goal-bold-icon';
20
5
  export const GoalIcon = props => /*#__PURE__*/React.createElement(GoalGlyph, _extends({
21
6
  color: "var(--ds-icon, #44546F)",
22
7
  LEGACY_fallbackIcon: LegacyGoalIcon,
@@ -1,24 +1,10 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
2
  import React from 'react';
3
- import Icon from '@atlaskit/icon';
4
3
  import ProjectIcon from '@atlaskit/icon/core/project';
5
- const ProjectsGlyph = _props => /*#__PURE__*/React.createElement("svg", {
6
- xmlns: "http://www.w3.org/2000/svg",
7
- width: "16",
8
- height: "16",
9
- viewBox: "0 0 16 16",
10
- fill: "none"
11
- }, /*#__PURE__*/React.createElement("path", {
12
- fillRule: "evenodd",
13
- clipRule: "evenodd",
14
- d: "M9.88573 4.00002C9.70892 4.00002 9.53935 4.07026 9.41433 4.19528L6.97282 6.63678L4.20525 6.94429C4.05479 6.96101 3.91451 7.02844 3.80746 7.13548L3.60959 7.33335L4.35367 8.07743C4.6791 8.40287 4.6791 8.93051 4.35367 9.25594L3.47152 10.1381C3.21117 10.3984 2.78906 10.3984 2.52871 10.1381C2.26836 9.87774 2.26836 9.45563 2.52871 9.19528L3.0573 8.66669L2.43108 8.04046C2.04055 7.64993 2.04055 7.01677 2.43108 6.62625L2.86465 6.19267C3.18578 5.87154 3.60664 5.66927 4.05801 5.61911L6.36073 5.36326L8.47152 3.25247C8.84659 2.8774 9.3553 2.66669 9.88573 2.66669H12.0001C12.7365 2.66669 13.3334 3.26364 13.3334 4.00002V6.1144C13.3334 6.64483 13.1227 7.15354 12.7477 7.52862L10.6369 9.6394L10.381 11.9421C10.3309 12.3935 10.1286 12.8143 9.80746 13.1355L9.37389 13.5691C8.98336 13.9596 8.3502 13.9596 7.95967 13.5691L7.33345 12.9428L6.80485 13.4714C6.5445 13.7318 6.12239 13.7318 5.86204 13.4714C5.60169 13.2111 5.60169 12.789 5.86204 12.5286L6.74419 11.6465C7.06963 11.321 7.59726 11.321 7.9227 11.6465L8.66678 12.3905L8.86466 12.1927C8.9717 12.0856 9.03912 11.9453 9.05584 11.7949L9.36335 9.02731L11.8049 6.58581C11.9299 6.46078 12.0001 6.29121 12.0001 6.1144V4.00002H9.88573ZM5.80486 10.1953C6.06521 10.4556 6.06521 10.8777 5.80486 11.1381L3.80486 13.1381C3.54451 13.3984 3.1224 13.3984 2.86205 13.1381C2.6017 12.8777 2.6017 12.4556 2.86205 12.1953L4.86205 10.1953C5.1224 9.93493 5.54451 9.93493 5.80486 10.1953ZM10.0001 6.66669C10.3683 6.66669 10.6668 6.36821 10.6668 6.00002C10.6668 5.63183 10.3683 5.33335 10.0001 5.33335C9.63193 5.33335 9.33346 5.63183 9.33346 6.00002C9.33346 6.36821 9.63193 6.66669 10.0001 6.66669Z",
15
- fill: "var(--ds-icon, #44546F)"
16
- }));
17
- const LegacyProjectsIcon = props => /*#__PURE__*/React.createElement(Icon, _extends({
18
- glyph: ProjectsGlyph
19
- }, props));
4
+ import LegacyProjectsIcon from '@atlaskit/legacy-custom-icons/project-icon';
20
5
  export const ProjectsIcon = props => /*#__PURE__*/React.createElement(ProjectIcon, _extends({
21
6
  color: "var(--ds-icon, #44546F)",
22
7
  LEGACY_fallbackIcon: LegacyProjectsIcon,
8
+ LEGACY_margin: "10px",
23
9
  spacing: "spacious"
24
10
  }, props));
@@ -1,30 +1,8 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
2
  import React from 'react';
3
- import Icon from '@atlaskit/icon';
4
- const UnfollowGlyph = props => /*#__PURE__*/React.createElement("svg", {
5
- width: "16",
6
- height: "16",
7
- viewBox: "0 0 16 16",
8
- "data-testid": props['data-testid'],
9
- "aria-label": props['aria-label']
10
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
11
- ,
12
- className: props.className,
13
- role: "presentation",
14
- xmlns: "http://www.w3.org/2000/svg"
15
- }, /*#__PURE__*/React.createElement("path", {
16
- d: "M14 4.66667H11.3333C10.9652 4.66667 10.6667 4.96514 10.6667 5.33333C10.6667 5.70152 10.9652 6 11.3333 6H14C14.3682 6 14.6667 5.70152 14.6667 5.33333C14.6667 4.96514 14.3682 4.66667 14 4.66667Z",
17
- fill: "currentColor"
18
- }), /*#__PURE__*/React.createElement("path", {
19
- fillRule: "evenodd",
20
- clipRule: "evenodd",
21
- d: "M3.33334 9.33333C3.33334 8.59667 3.93468 8 4.67268 8H9.99401C10.734 8 11.3333 8.596 11.3333 9.33733V12.2973C11.3333 14.5673 3.33334 14.5673 3.33334 12.2973V9.33333Z",
22
- fill: "currentColor"
23
- }), /*#__PURE__*/React.createElement("path", {
24
- d: "M7.33334 7.33333C8.8061 7.33333 10 6.13943 10 4.66667C10 3.19391 8.8061 2 7.33334 2C5.86058 2 4.66668 3.19391 4.66668 4.66667C4.66668 6.13943 5.86058 7.33333 7.33334 7.33333Z",
25
- fill: "currentColor"
26
- }));
27
- const UnfollowIcon = props => /*#__PURE__*/React.createElement(Icon, _extends({
28
- glyph: UnfollowGlyph
3
+ import PersonRemoveIcon from '@atlaskit/icon/core/person-remove';
4
+ import LegacyUnfollowIcon from '@atlaskit/legacy-custom-icons/unfollow-icon';
5
+ const UnfollowIcon = props => /*#__PURE__*/React.createElement(PersonRemoveIcon, _extends({
6
+ LEGACY_fallbackIcon: LegacyUnfollowIcon
29
7
  }, props));
30
8
  export default UnfollowIcon;
@@ -23,10 +23,7 @@ const errorContentStyles = xcss({
23
23
  });
24
24
  const titleStyles = xcss({
25
25
  color: 'color.text.subtle',
26
- fontSize: '12px',
27
- fontStyle: 'normal',
28
- fontWeight: '400',
29
- lineHeight: '16px'
26
+ font: "var(--ds-font-body-UNSAFE_small, normal 400 12px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)"
30
27
  });
31
28
  const getIcon = appearance => {
32
29
  switch (appearance) {