@atlaskit/smart-card 44.3.23 → 44.3.24

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 CHANGED
@@ -1,5 +1,14 @@
1
1
  # @atlaskit/smart-card
2
2
 
3
+ ## 44.3.24
4
+
5
+ ### Patch Changes
6
+
7
+ - [`0e8d752e6dbb2`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/0e8d752e6dbb2) -
8
+ fix the conditional for fg check for mini modal logic
9
+ - [`5f2a9a94761d1`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/5f2a9a94761d1) -
10
+ FG Cleanup platform_sl_a11y_enghealth_46829
11
+
3
12
  ## 44.3.23
4
13
 
5
14
  ### Patch Changes
@@ -35,7 +35,7 @@ var useRovoChat = function useRovoChat() {
35
35
  agentId: undefined
36
36
  }),
37
37
  openChat: true,
38
- openChatMode: product && jiraProducts.includes(product) && (0, _platformFeatureFlags.fg)('platform_sl_3p_auth_rovo_block_jira_kill_switch') || (0, _platformFeatureFlags.fg)('rovogrowth-640-inline-action-nudge-fg') ? 'mini-modal' : 'sidebar'
38
+ openChatMode: product && jiraProducts.includes(product) && ((0, _platformFeatureFlags.fg)('platform_sl_3p_auth_rovo_block_jira_kill_switch') || (0, _platformFeatureFlags.fg)('rovogrowth-640-inline-action-nudge-fg')) ? 'mini-modal' : 'sidebar'
39
39
  },
40
40
  onAcknowledgeTimeout: function onAcknowledgeTimeout() {
41
41
  // NAVX-3599: Add analytics event
@@ -11,7 +11,7 @@ var ANALYTICS_CHANNEL = exports.ANALYTICS_CHANNEL = 'media';
11
11
  var context = exports.context = {
12
12
  componentName: 'smart-cards',
13
13
  packageName: "@atlaskit/smart-card" || '',
14
- packageVersion: "44.3.22" || ''
14
+ packageVersion: "44.3.23" || ''
15
15
  };
16
16
  var TrackQuickActionType = exports.TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
17
17
  TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
@@ -6,10 +6,8 @@ Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
8
  exports.default = void 0;
9
- var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
10
9
  var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
11
10
  var _react = _interopRequireWildcard(require("react"));
12
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
13
11
  var _constants = require("../../../../../constants");
14
12
  var _utils = require("../../../../../utils");
15
13
  var _HoverCard = require("../../../../HoverCard");
@@ -72,14 +70,12 @@ var HoverCardControl = function HoverCardControl(_ref) {
72
70
  actionOptions: actionOptions,
73
71
  url: url,
74
72
  hoverPreviewOptions: hoverPreviewOptions
75
- }, /*#__PURE__*/_react.default.createElement("span", (0, _extends2.default)({}, (0, _platformFeatureFlags.fg)('platform_sl_a11y_enghealth_46829') ? {
76
- onBlur: _utils.noop
77
- } : undefined, {
78
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
73
+ }, /*#__PURE__*/_react.default.createElement("span", {
74
+ onBlur: _utils.noop,
79
75
  onMouseLeave: onMouseLeave,
80
76
  onMouseMove: onMouseMove,
81
77
  "data-testid": "".concat(testId, "-hover-card-wrapper"),
82
78
  role: 'presentation'
83
- }), children));
79
+ }, children));
84
80
  };
85
81
  var _default = exports.default = HoverCardControl;
@@ -6,11 +6,9 @@ Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
8
  exports.default = void 0;
9
- var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
10
9
  var _react = _interopRequireWildcard(require("react"));
11
10
  var _dropdownMenu = require("@atlaskit/dropdown-menu");
12
11
  var _lozenge = _interopRequireDefault(require("@atlaskit/lozenge"));
13
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
14
12
  function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
15
13
  var LozengeActionItem = function LozengeActionItem(_ref) {
16
14
  var appearance = _ref.appearance,
@@ -30,13 +28,11 @@ var LozengeActionItem = function LozengeActionItem(_ref) {
30
28
  var _e$currentTarget;
31
29
  (_e$currentTarget = e.currentTarget) === null || _e$currentTarget === void 0 || (_e$currentTarget = _e$currentTarget.firstElementChild) === null || _e$currentTarget === void 0 || _e$currentTarget.focus();
32
30
  }, []);
33
- return /*#__PURE__*/_react.default.createElement("span", (0, _extends2.default)({}, (0, _platformFeatureFlags.fg)('platform_sl_a11y_enghealth_46829') ? {
34
- onFocus: handleMouseEnter
35
- } : undefined, {
36
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
31
+ return /*#__PURE__*/_react.default.createElement("span", {
32
+ onFocus: handleMouseEnter,
37
33
  onMouseEnter: handleMouseEnter,
38
34
  role: "presentation"
39
- }), /*#__PURE__*/_react.default.createElement(_dropdownMenu.DropdownItem, {
35
+ }, /*#__PURE__*/_react.default.createElement(_dropdownMenu.DropdownItem, {
40
36
  onClick: handleClick,
41
37
  testId: testId
42
38
  }, /*#__PURE__*/_react.default.createElement(_lozenge.default, {
@@ -248,10 +248,7 @@ var HoverCardComponent = exports.HoverCardComponent = function HoverCardComponen
248
248
  return /*#__PURE__*/_react.default.createElement("span", {
249
249
  ref: parentSpan
250
250
  }, /*#__PURE__*/_react.default.createElement("span", (0, _extends2.default)({}, triggerProps, {
251
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
252
- onMouseOver: initShowCard
253
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
254
- ,
251
+ onMouseOver: initShowCard,
255
252
  onMouseLeave: initHideCard,
256
253
  onMouseMove: setMousePosition,
257
254
  onKeyDown: (0, _platformFeatureFlags.fg)('fix_hover_card_on_focus_a11y') ? handleKeyDown : undefined,
@@ -260,11 +257,11 @@ var HoverCardComponent = exports.HoverCardComponent = function HoverCardComponen
260
257
  "data-testid": HOVER_CARD_TRIGGER_WRAPPER
261
258
  }, (0, _experiments.editorExperiment)('platform_editor_preview_panel_linking_exp', true) ? {
262
259
  className: HOVER_CARD_TRIGGER_WRAPPER
263
- } : {}, (0, _platformFeatureFlags.fg)('platform_sl_a11y_enghealth_46829') ? {
260
+ } : {}, {
264
261
  onFocus: _utils.noop,
265
262
  onBlur: _utils.noop,
266
- role: 'none'
267
- } : undefined), children));
263
+ role: "none"
264
+ }), children));
268
265
  }, [children, initHideCard, initShowCard, onChildClick, onContextMenuClick, setMousePosition, handleKeyDown]);
269
266
  var popupComponent = (0, _react.useMemo)(
270
267
  // Within the Popup component, if shouldRenderToParent, the zIndex prop is ignored
@@ -22,7 +22,7 @@ var _excluded = ["href", "children", "checkSafety", "onClick", "testId", "isLink
22
22
  _excluded2 = ["isLinkSafe", "showSafetyWarningModal"];
23
23
  var PACKAGE_DATA = {
24
24
  packageName: "@atlaskit/smart-card",
25
- packageVersion: "44.3.22",
25
+ packageVersion: "44.3.23",
26
26
  componentName: 'linkUrl'
27
27
  };
28
28
  var Anchor = (0, _click.withLinkClickedEvent)('a');
@@ -27,7 +27,7 @@ const useRovoChat = () => {
27
27
  agentId: undefined
28
28
  },
29
29
  openChat: true,
30
- openChatMode: product && jiraProducts.includes(product) && fg('platform_sl_3p_auth_rovo_block_jira_kill_switch') || fg('rovogrowth-640-inline-action-nudge-fg') ? 'mini-modal' : 'sidebar'
30
+ openChatMode: product && jiraProducts.includes(product) && (fg('platform_sl_3p_auth_rovo_block_jira_kill_switch') || fg('rovogrowth-640-inline-action-nudge-fg')) ? 'mini-modal' : 'sidebar'
31
31
  },
32
32
  onAcknowledgeTimeout: () => {
33
33
  // NAVX-3599: Add analytics event
@@ -2,7 +2,7 @@ export const ANALYTICS_CHANNEL = 'media';
2
2
  export const context = {
3
3
  componentName: 'smart-cards',
4
4
  packageName: "@atlaskit/smart-card" || '',
5
- packageVersion: "44.3.22" || ''
5
+ packageVersion: "44.3.23" || ''
6
6
  };
7
7
  export let TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
8
8
  TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
@@ -1,6 +1,4 @@
1
- import _extends from "@babel/runtime/helpers/extends";
2
1
  import React, { useCallback, useEffect, useRef, useState } from 'react';
3
- import { fg } from '@atlaskit/platform-feature-flags';
4
2
  import { ElementName } from '../../../../../constants';
5
3
  import { noop } from '../../../../../utils';
6
4
  import { HoverCard } from '../../../../HoverCard';
@@ -59,14 +57,12 @@ const HoverCardControl = ({
59
57
  actionOptions: actionOptions,
60
58
  url: url,
61
59
  hoverPreviewOptions: hoverPreviewOptions
62
- }, /*#__PURE__*/React.createElement("span", _extends({}, fg('platform_sl_a11y_enghealth_46829') ? {
63
- onBlur: noop
64
- } : undefined, {
65
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
60
+ }, /*#__PURE__*/React.createElement("span", {
61
+ onBlur: noop,
66
62
  onMouseLeave: onMouseLeave,
67
63
  onMouseMove: onMouseMove,
68
64
  "data-testid": `${testId}-hover-card-wrapper`,
69
65
  role: 'presentation'
70
- }), children));
66
+ }, children));
71
67
  };
72
68
  export default HoverCardControl;
@@ -1,8 +1,6 @@
1
- import _extends from "@babel/runtime/helpers/extends";
2
1
  import React, { useCallback } from 'react';
3
2
  import { DropdownItem } from '@atlaskit/dropdown-menu';
4
3
  import Lozenge from '@atlaskit/lozenge';
5
- import { fg } from '@atlaskit/platform-feature-flags';
6
4
  const LozengeActionItem = ({
7
5
  appearance,
8
6
  id,
@@ -22,13 +20,11 @@ const LozengeActionItem = ({
22
20
  var _e$currentTarget, _e$currentTarget$firs;
23
21
  (_e$currentTarget = e.currentTarget) === null || _e$currentTarget === void 0 ? void 0 : (_e$currentTarget$firs = _e$currentTarget.firstElementChild) === null || _e$currentTarget$firs === void 0 ? void 0 : _e$currentTarget$firs.focus();
24
22
  }, []);
25
- return /*#__PURE__*/React.createElement("span", _extends({}, fg('platform_sl_a11y_enghealth_46829') ? {
26
- onFocus: handleMouseEnter
27
- } : undefined, {
28
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
23
+ return /*#__PURE__*/React.createElement("span", {
24
+ onFocus: handleMouseEnter,
29
25
  onMouseEnter: handleMouseEnter,
30
26
  role: "presentation"
31
- }), /*#__PURE__*/React.createElement(DropdownItem, {
27
+ }, /*#__PURE__*/React.createElement(DropdownItem, {
32
28
  onClick: handleClick,
33
29
  testId: testId
34
30
  }, /*#__PURE__*/React.createElement(Lozenge, {
@@ -222,10 +222,7 @@ export const HoverCardComponent = ({
222
222
  }) => /*#__PURE__*/React.createElement("span", {
223
223
  ref: parentSpan
224
224
  }, /*#__PURE__*/React.createElement("span", _extends({}, triggerProps, {
225
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
226
- onMouseOver: initShowCard
227
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
228
- ,
225
+ onMouseOver: initShowCard,
229
226
  onMouseLeave: initHideCard,
230
227
  onMouseMove: setMousePosition,
231
228
  onKeyDown: fg('fix_hover_card_on_focus_a11y') ? handleKeyDown : undefined,
@@ -234,11 +231,11 @@ export const HoverCardComponent = ({
234
231
  "data-testid": HOVER_CARD_TRIGGER_WRAPPER
235
232
  }, editorExperiment('platform_editor_preview_panel_linking_exp', true) ? {
236
233
  className: HOVER_CARD_TRIGGER_WRAPPER
237
- } : {}, fg('platform_sl_a11y_enghealth_46829') ? {
234
+ } : {}, {
238
235
  onFocus: noop,
239
236
  onBlur: noop,
240
- role: 'none'
241
- } : undefined), children)), [children, initHideCard, initShowCard, onChildClick, onContextMenuClick, setMousePosition, handleKeyDown]);
237
+ role: "none"
238
+ }), children)), [children, initHideCard, initShowCard, onChildClick, onContextMenuClick, setMousePosition, handleKeyDown]);
242
239
  const popupComponent = useMemo(
243
240
  // Within the Popup component, if shouldRenderToParent, the zIndex prop is ignored
244
241
  // as it is assumed that the custom popup container has the desired styles
@@ -12,7 +12,7 @@ import LinkWarningModal from './LinkWarningModal';
12
12
  import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
13
13
  const PACKAGE_DATA = {
14
14
  packageName: "@atlaskit/smart-card",
15
- packageVersion: "44.3.22",
15
+ packageVersion: "44.3.23",
16
16
  componentName: 'linkUrl'
17
17
  };
18
18
  const Anchor = withLinkClickedEvent('a');
@@ -28,7 +28,7 @@ var useRovoChat = function useRovoChat() {
28
28
  agentId: undefined
29
29
  }),
30
30
  openChat: true,
31
- openChatMode: product && jiraProducts.includes(product) && fg('platform_sl_3p_auth_rovo_block_jira_kill_switch') || fg('rovogrowth-640-inline-action-nudge-fg') ? 'mini-modal' : 'sidebar'
31
+ openChatMode: product && jiraProducts.includes(product) && (fg('platform_sl_3p_auth_rovo_block_jira_kill_switch') || fg('rovogrowth-640-inline-action-nudge-fg')) ? 'mini-modal' : 'sidebar'
32
32
  },
33
33
  onAcknowledgeTimeout: function onAcknowledgeTimeout() {
34
34
  // NAVX-3599: Add analytics event
@@ -4,7 +4,7 @@ export var ANALYTICS_CHANNEL = 'media';
4
4
  export var context = {
5
5
  componentName: 'smart-cards',
6
6
  packageName: "@atlaskit/smart-card" || '',
7
- packageVersion: "44.3.22" || ''
7
+ packageVersion: "44.3.23" || ''
8
8
  };
9
9
  export var TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
10
10
  TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
@@ -1,7 +1,5 @@
1
- import _extends from "@babel/runtime/helpers/extends";
2
1
  import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
3
2
  import React, { useCallback, useEffect, useRef, useState } from 'react';
4
- import { fg } from '@atlaskit/platform-feature-flags';
5
3
  import { ElementName } from '../../../../../constants';
6
4
  import { noop } from '../../../../../utils';
7
5
  import { HoverCard } from '../../../../HoverCard';
@@ -63,14 +61,12 @@ var HoverCardControl = function HoverCardControl(_ref) {
63
61
  actionOptions: actionOptions,
64
62
  url: url,
65
63
  hoverPreviewOptions: hoverPreviewOptions
66
- }, /*#__PURE__*/React.createElement("span", _extends({}, fg('platform_sl_a11y_enghealth_46829') ? {
67
- onBlur: noop
68
- } : undefined, {
69
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
64
+ }, /*#__PURE__*/React.createElement("span", {
65
+ onBlur: noop,
70
66
  onMouseLeave: onMouseLeave,
71
67
  onMouseMove: onMouseMove,
72
68
  "data-testid": "".concat(testId, "-hover-card-wrapper"),
73
69
  role: 'presentation'
74
- }), children));
70
+ }, children));
75
71
  };
76
72
  export default HoverCardControl;
@@ -1,8 +1,6 @@
1
- import _extends from "@babel/runtime/helpers/extends";
2
1
  import React, { useCallback } from 'react';
3
2
  import { DropdownItem } from '@atlaskit/dropdown-menu';
4
3
  import Lozenge from '@atlaskit/lozenge';
5
- import { fg } from '@atlaskit/platform-feature-flags';
6
4
  var LozengeActionItem = function LozengeActionItem(_ref) {
7
5
  var appearance = _ref.appearance,
8
6
  id = _ref.id,
@@ -21,13 +19,11 @@ var LozengeActionItem = function LozengeActionItem(_ref) {
21
19
  var _e$currentTarget;
22
20
  (_e$currentTarget = e.currentTarget) === null || _e$currentTarget === void 0 || (_e$currentTarget = _e$currentTarget.firstElementChild) === null || _e$currentTarget === void 0 || _e$currentTarget.focus();
23
21
  }, []);
24
- return /*#__PURE__*/React.createElement("span", _extends({}, fg('platform_sl_a11y_enghealth_46829') ? {
25
- onFocus: handleMouseEnter
26
- } : undefined, {
27
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
22
+ return /*#__PURE__*/React.createElement("span", {
23
+ onFocus: handleMouseEnter,
28
24
  onMouseEnter: handleMouseEnter,
29
25
  role: "presentation"
30
- }), /*#__PURE__*/React.createElement(DropdownItem, {
26
+ }, /*#__PURE__*/React.createElement(DropdownItem, {
31
27
  onClick: handleClick,
32
28
  testId: testId
33
29
  }, /*#__PURE__*/React.createElement(Lozenge, {
@@ -239,10 +239,7 @@ export var HoverCardComponent = function HoverCardComponent(_ref) {
239
239
  return /*#__PURE__*/React.createElement("span", {
240
240
  ref: parentSpan
241
241
  }, /*#__PURE__*/React.createElement("span", _extends({}, triggerProps, {
242
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
243
- onMouseOver: initShowCard
244
- // eslint-disable-next-line @atlassian/a11y/mouse-events-have-key-events
245
- ,
242
+ onMouseOver: initShowCard,
246
243
  onMouseLeave: initHideCard,
247
244
  onMouseMove: setMousePosition,
248
245
  onKeyDown: fg('fix_hover_card_on_focus_a11y') ? handleKeyDown : undefined,
@@ -251,11 +248,11 @@ export var HoverCardComponent = function HoverCardComponent(_ref) {
251
248
  "data-testid": HOVER_CARD_TRIGGER_WRAPPER
252
249
  }, editorExperiment('platform_editor_preview_panel_linking_exp', true) ? {
253
250
  className: HOVER_CARD_TRIGGER_WRAPPER
254
- } : {}, fg('platform_sl_a11y_enghealth_46829') ? {
251
+ } : {}, {
255
252
  onFocus: noop,
256
253
  onBlur: noop,
257
- role: 'none'
258
- } : undefined), children));
254
+ role: "none"
255
+ }), children));
259
256
  }, [children, initHideCard, initShowCard, onChildClick, onContextMenuClick, setMousePosition, handleKeyDown]);
260
257
  var popupComponent = useMemo(
261
258
  // Within the Popup component, if shouldRenderToParent, the zIndex prop is ignored
@@ -15,7 +15,7 @@ import LinkWarningModal from './LinkWarningModal';
15
15
  import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
16
16
  var PACKAGE_DATA = {
17
17
  packageName: "@atlaskit/smart-card",
18
- packageVersion: "44.3.22",
18
+ packageVersion: "44.3.23",
19
19
  componentName: 'linkUrl'
20
20
  };
21
21
  var Anchor = withLinkClickedEvent('a');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/smart-card",
3
- "version": "44.3.23",
3
+ "version": "44.3.24",
4
4
  "description": "Smart card component",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -226,9 +226,6 @@
226
226
  "fix_hover_card_on_focus_a11y": {
227
227
  "type": "boolean"
228
228
  },
229
- "platform_sl_a11y_enghealth_46829": {
230
- "type": "boolean"
231
- },
232
229
  "platform_sl_3p_preauth_better_hovercard_killswitch": {
233
230
  "type": "boolean"
234
231
  },