@atlaskit/smart-card 40.5.6 → 40.6.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 +8 -0
- package/dist/cjs/utils/analytics/analytics.js +1 -1
- package/dist/cjs/view/EmbedCard/components/IFrame.js +3 -2
- package/dist/cjs/view/EmbedModal/components/link-info/index.js +3 -1
- package/dist/cjs/view/FlexibleCard/components/container/hover-card-control/index.js +2 -1
- package/dist/cjs/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-error/index.compiled.css +13 -1
- package/dist/cjs/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-error/index.js +20 -12
- package/dist/cjs/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-item/index.js +11 -14
- package/dist/cjs/view/LinkUrl/index.js +1 -1
- package/dist/cjs/view/RelatedLinksModal/components/related-link-item/index.js +1 -0
- package/dist/cjs/view/common/stop-propagation/index.js +10 -3
- package/dist/es2019/utils/analytics/analytics.js +1 -1
- package/dist/es2019/view/EmbedCard/components/IFrame.js +3 -2
- package/dist/es2019/view/EmbedModal/components/link-info/index.js +3 -1
- package/dist/es2019/view/FlexibleCard/components/container/hover-card-control/index.js +2 -1
- package/dist/es2019/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-error/index.compiled.css +12 -0
- package/dist/es2019/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-error/index.js +20 -9
- package/dist/es2019/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-item/index.js +11 -14
- package/dist/es2019/view/LinkUrl/index.js +1 -1
- package/dist/es2019/view/RelatedLinksModal/components/related-link-item/index.js +1 -0
- package/dist/es2019/view/common/stop-propagation/index.js +10 -3
- package/dist/esm/utils/analytics/analytics.js +1 -1
- package/dist/esm/view/EmbedCard/components/IFrame.js +3 -2
- package/dist/esm/view/EmbedModal/components/link-info/index.js +3 -1
- package/dist/esm/view/FlexibleCard/components/container/hover-card-control/index.js +2 -1
- package/dist/esm/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-error/index.compiled.css +13 -1
- package/dist/esm/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-error/index.js +20 -12
- package/dist/esm/view/FlexibleCard/components/elements/common/base-lozenge-element/lozenge-action/lozenge-action-item/index.js +11 -14
- package/dist/esm/view/LinkUrl/index.js +1 -1
- package/dist/esm/view/RelatedLinksModal/components/related-link-item/index.js +1 -0
- package/dist/esm/view/common/stop-propagation/index.js +10 -3
- package/package.json +5 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/smart-card
|
|
2
2
|
|
|
3
|
+
## 40.6.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#191974](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/191974)
|
|
8
|
+
[`e04653dbc86fd`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/e04653dbc86fd) -
|
|
9
|
+
NAVX-1184 Removing and fixing eslint a11y rules from linking-platform packages
|
|
10
|
+
|
|
3
11
|
## 40.5.6
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -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: "40.5.
|
|
14
|
+
packageVersion: "40.5.6"
|
|
15
15
|
};
|
|
16
16
|
var TrackQuickActionType = exports.TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
17
17
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -16,10 +16,11 @@ var IFrame = exports.IFrame = function IFrame(_ref) {
|
|
|
16
16
|
var childRef = _ref.childRef,
|
|
17
17
|
className = _ref.className,
|
|
18
18
|
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
19
|
-
// eslint-disable-next-line
|
|
19
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop
|
|
20
20
|
return /*#__PURE__*/_react.default.createElement("iframe", (0, _extends2.default)({
|
|
21
21
|
className: className
|
|
22
22
|
}, props, {
|
|
23
|
-
ref: childRef
|
|
23
|
+
ref: childRef,
|
|
24
|
+
title: props.title
|
|
24
25
|
}));
|
|
25
26
|
};
|
|
@@ -148,7 +148,9 @@ var LinkInfo = function LinkInfo(_ref) {
|
|
|
148
148
|
color: "color.text",
|
|
149
149
|
testId: "".concat(testId, "-title")
|
|
150
150
|
}, title), /*#__PURE__*/_react.default.createElement("span", {
|
|
151
|
-
tabIndex: 0
|
|
151
|
+
tabIndex: 0,
|
|
152
|
+
role: "button",
|
|
153
|
+
"aria-hidden": true
|
|
152
154
|
})), /*#__PURE__*/_react.default.createElement("div", {
|
|
153
155
|
className: (0, _runtime.ax)(["_16jlidpf _1o9zidpf _i0dl1wug _zulp1b66 _1e0c1txw _3kllglyw"])
|
|
154
156
|
}, downloadButton, urlButton, sizeButton, (0, _platformFeatureFlags.fg)('platform-smart-card-remove-legacy-button') ? /*#__PURE__*/_react.default.createElement(_linkInfoButton.default, {
|
|
@@ -72,7 +72,8 @@ var HoverCardControl = function HoverCardControl(_ref) {
|
|
|
72
72
|
}, /*#__PURE__*/_react.default.createElement("span", {
|
|
73
73
|
onMouseLeave: onMouseLeave,
|
|
74
74
|
onMouseMove: onMouseMove,
|
|
75
|
-
"data-testid": "".concat(testId, "-hover-card-wrapper")
|
|
75
|
+
"data-testid": "".concat(testId, "-hover-card-wrapper"),
|
|
76
|
+
role: "presentation"
|
|
76
77
|
}, children));
|
|
77
78
|
};
|
|
78
79
|
var _default = exports.default = HoverCardControl;
|
|
@@ -5,9 +5,12 @@
|
|
|
5
5
|
._14hp1wdt button{width:220px}
|
|
6
6
|
._18m915vq{overflow-y:hidden}
|
|
7
7
|
._18u0xy5q{margin-left:var(--ds-space-400,2pc)}
|
|
8
|
+
._19bvze3t{padding-left:var(--ds-space-0,0)}
|
|
8
9
|
._19pku2gc{margin-top:var(--ds-space-100,8px)}
|
|
9
10
|
._19pkv77o{margin-top:var(--ds-space-025,2px)}
|
|
11
|
+
._1bah1e5h{justify-content:left}
|
|
10
12
|
._1bto1l2s{text-overflow:ellipsis}
|
|
13
|
+
._1e0c1kw7{display:inherit}
|
|
11
14
|
._1e0c1txw{display:flex}
|
|
12
15
|
._1e0ccj1k{display:-webkit-box}
|
|
13
16
|
._1nmz1hna{word-break:break-word}
|
|
@@ -18,10 +21,19 @@
|
|
|
18
21
|
._4cvr1h6o{align-items:center}
|
|
19
22
|
._4cvr1y6m{align-items:flex-start}
|
|
20
23
|
._80omtlke{cursor:pointer}
|
|
21
|
-
.
|
|
24
|
+
._bfhk1j28{background-color:transparent}
|
|
25
|
+
._ca0qze3t{padding-top:var(--ds-space-0,0)}
|
|
26
|
+
._n3tdze3t{padding-bottom:var(--ds-space-0,0)}
|
|
27
|
+
._ngc01fxt >div, ._1t4p1fxt >span{color:var(--ds-text,#172b4d)}
|
|
22
28
|
._o5724jg8{white-space:normal}
|
|
23
29
|
._otyrv77o{margin-bottom:var(--ds-space-025,2px)}
|
|
24
30
|
._sudp1e54{-webkit-box-orient:vertical}
|
|
31
|
+
._syaz14q2{color:var(--ds-link,#0c66e4)}
|
|
32
|
+
._u5f3ze3t{padding-right:var(--ds-space-0,0)}
|
|
33
|
+
._1bnx8stv:hover{text-decoration-line:underline}
|
|
25
34
|
._1eo073ad button:hover{cursor:default}
|
|
35
|
+
._30l316c2:hover{color:var(--ds-link-pressed,#05c)}
|
|
26
36
|
._6pup1kw7 button:hover{background-color:inherit}
|
|
37
|
+
._9oik1r31:hover{text-decoration-color:currentColor}
|
|
38
|
+
._jf4cnqa1:hover{text-decoration-style:solid}
|
|
27
39
|
@supports not (-webkit-line-clamp:1){._102k1hw0{max-height:var(--_hm3wc5)}}
|
|
@@ -15,6 +15,7 @@ var _reactIntlNext = require("react-intl-next");
|
|
|
15
15
|
var _dropdownMenu = require("@atlaskit/dropdown-menu");
|
|
16
16
|
var _statusErrorError = _interopRequireDefault(require("@atlaskit/icon/core/migration/status-error--error"));
|
|
17
17
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
18
|
+
var _compiled = require("@atlaskit/primitives/compiled");
|
|
18
19
|
var _colors = require("@atlaskit/theme/colors");
|
|
19
20
|
var _useAnalyticsEvents2 = require("../../../../../../../../common/analytics/generated/use-analytics-events");
|
|
20
21
|
var _messages = require("../../../../../../../../messages");
|
|
@@ -22,10 +23,13 @@ var _useInvokeClientAction = _interopRequireDefault(require("../../../../../../.
|
|
|
22
23
|
var _utils = require("../../../../../utils");
|
|
23
24
|
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); }
|
|
24
25
|
var MAX_LINE_NUMBER = 8;
|
|
25
|
-
var
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
26
|
+
var styles = {
|
|
27
|
+
contentStyles: "_zulpu2gc _11c81ixg _1reo15vq _18m915vq _1e0c1txw _1ul9idpf _2lx2vrvc _19pkv77o _4cvr1y6m _pqme2smr _102e2smr _ngc01fxt _1t4p1fxt",
|
|
28
|
+
linkStyles: "_zulpu2gc _1reo15vq _18m915vq _11c82smr _1e0c1txw _1ul9idpf _2lx2vrvc _4cvr1h6o _80omtlke _19pku2gc _18u0xy5q _otyrv77o",
|
|
29
|
+
textStylesBase: "_11c81ixg _1reo15vq _18m915vq _o5724jg8 _1e0ccj1k _1bto1l2s _1nmz1hna _sudp1e54",
|
|
30
|
+
dropdownItemGroupStyles: "_14hp1wdt _6pup1kw7 _1eo073ad",
|
|
31
|
+
openIssueInJiraStyles: "_11c82smr _bfhk1j28 _1bah1e5h _1e0c1kw7 _syaz14q2 _ca0qze3t _u5f3ze3t _n3tdze3t _19bvze3t _9oik1r31 _1bnx8stv _jf4cnqa1 _30l316c2"
|
|
32
|
+
};
|
|
29
33
|
var LozengeActionError = function LozengeActionError(_ref) {
|
|
30
34
|
var errorMessage = _ref.errorMessage,
|
|
31
35
|
testId = _ref.testId,
|
|
@@ -47,10 +51,7 @@ var LozengeActionError = function LozengeActionError(_ref) {
|
|
|
47
51
|
var dynamicCss = null;
|
|
48
52
|
var content = (0, _react.useMemo)(function () {
|
|
49
53
|
return /*#__PURE__*/React.createElement(_react.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
50
|
-
className: (0, _runtime.ax)([
|
|
51
|
-
style: {
|
|
52
|
-
"--_ggxzyp": (0, _runtime.ix)("var(--ds-text, ".concat(_colors.N800, ")"))
|
|
53
|
-
}
|
|
54
|
+
className: (0, _runtime.ax)([styles.contentStyles])
|
|
54
55
|
}, /*#__PURE__*/React.createElement(_statusErrorError.default, {
|
|
55
56
|
testId: "".concat(testId, "-icon"),
|
|
56
57
|
LEGACY_size: "medium",
|
|
@@ -60,14 +61,21 @@ var LozengeActionError = function LozengeActionError(_ref) {
|
|
|
60
61
|
spacing: "spacious"
|
|
61
62
|
}), /*#__PURE__*/React.createElement("span", {
|
|
62
63
|
"data-testid": "".concat(testId, "-error-message"),
|
|
63
|
-
className: (0, _runtime.ax)([
|
|
64
|
+
className: (0, _runtime.ax)([styles.textStylesBase, "_1yyj1n6p _102k1hw0"]),
|
|
64
65
|
style: {
|
|
65
66
|
"--_t4prqe": (0, _runtime.ix)(maxLineNumber),
|
|
66
67
|
"--_hm3wc5": (0, _runtime.ix)("calc(".concat(maxLineNumber, " * 1rem)"))
|
|
67
68
|
}
|
|
68
69
|
}, typeof errorMessage === 'string' ? errorMessage : (0, _utils.getFormattedMessage)(errorMessage))), isPreviewAvailable ? /*#__PURE__*/React.createElement("div", {
|
|
69
|
-
className: (0, _runtime.ax)([
|
|
70
|
-
}, /*#__PURE__*/React.createElement(
|
|
70
|
+
className: (0, _runtime.ax)([styles.linkStyles])
|
|
71
|
+
}, (0, _platformFeatureFlags.fg)('navx-1184-fix-smart-link-a11y-interactive-states') ? /*#__PURE__*/React.createElement(_compiled.Pressable, {
|
|
72
|
+
testId: "".concat(testId, "-open-embed"),
|
|
73
|
+
onClick: handlePreviewOpen,
|
|
74
|
+
xcss: styles.openIssueInJiraStyles
|
|
75
|
+
}, (0, _platformFeatureFlags.fg)('confluence-issue-terminology-refresh') ? /*#__PURE__*/React.createElement(_reactIntlNext.FormattedMessage, _messages.messages.open_issue_in_jiraIssueTermRefresh) : /*#__PURE__*/React.createElement(_reactIntlNext.FormattedMessage, _messages.messages.open_issue_in_jira)) :
|
|
76
|
+
/*#__PURE__*/
|
|
77
|
+
// eslint-disable-next-line @atlaskit/design-system/no-html-anchor, jsx-a11y/anchor-is-valid, jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
|
|
78
|
+
React.createElement("a", {
|
|
71
79
|
target: "_blank",
|
|
72
80
|
"data-testid": "".concat(testId, "-open-embed"),
|
|
73
81
|
onClick: handlePreviewOpen
|
|
@@ -75,7 +83,7 @@ var LozengeActionError = function LozengeActionError(_ref) {
|
|
|
75
83
|
}, [errorMessage, handlePreviewOpen, isPreviewAvailable, testId, dynamicCss]);
|
|
76
84
|
return /*#__PURE__*/React.createElement("span", {
|
|
77
85
|
"data-testid": "".concat(testId, "-error-item-group"),
|
|
78
|
-
className: (0, _runtime.ax)([
|
|
86
|
+
className: (0, _runtime.ax)([styles.dropdownItemGroupStyles])
|
|
79
87
|
}, /*#__PURE__*/React.createElement(_dropdownMenu.DropdownItemGroup, null, /*#__PURE__*/React.createElement(_dropdownMenu.DropdownItem, {
|
|
80
88
|
testId: "".concat(testId, "-error")
|
|
81
89
|
}, content)));
|
|
@@ -30,19 +30,16 @@ var LozengeActionItem = function LozengeActionItem(_ref) {
|
|
|
30
30
|
var _e$currentTarget;
|
|
31
31
|
(_e$currentTarget = e.currentTarget) === null || _e$currentTarget === void 0 || (_e$currentTarget = _e$currentTarget.firstElementChild) === null || _e$currentTarget === void 0 || _e$currentTarget.focus();
|
|
32
32
|
}, []);
|
|
33
|
-
return (
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
isBold: true
|
|
45
|
-
} : undefined), text)))
|
|
46
|
-
);
|
|
33
|
+
return /*#__PURE__*/_react.default.createElement("span", {
|
|
34
|
+
onMouseEnter: handleMouseEnter,
|
|
35
|
+
role: "presentation"
|
|
36
|
+
}, /*#__PURE__*/_react.default.createElement(_dropdownMenu.DropdownItem, {
|
|
37
|
+
onClick: handleClick,
|
|
38
|
+
testId: testId
|
|
39
|
+
}, /*#__PURE__*/_react.default.createElement(_lozenge.default, (0, _extends2.default)({
|
|
40
|
+
appearance: appearance
|
|
41
|
+
}, (0, _platformFeatureFlags.fg)('platform-component-visual-refresh') ? {
|
|
42
|
+
isBold: true
|
|
43
|
+
} : undefined), text)));
|
|
47
44
|
};
|
|
48
45
|
var _default = exports.default = LozengeActionItem;
|
|
@@ -19,7 +19,7 @@ var _excluded = ["href", "children", "checkSafety", "onClick", "testId", "isLink
|
|
|
19
19
|
_excluded2 = ["isLinkSafe", "showSafetyWarningModal"];
|
|
20
20
|
var PACKAGE_DATA = {
|
|
21
21
|
packageName: "@atlaskit/smart-card",
|
|
22
|
-
packageVersion: "40.5.
|
|
22
|
+
packageVersion: "40.5.6",
|
|
23
23
|
componentName: 'linkUrl'
|
|
24
24
|
};
|
|
25
25
|
var Anchor = (0, _click.withLinkClickedEvent)('a');
|
|
@@ -35,6 +35,7 @@ var RelatedLinkItem = function RelatedLinkItem(_ref) {
|
|
|
35
35
|
return /*#__PURE__*/React.createElement("div", {
|
|
36
36
|
"data-testId": testId,
|
|
37
37
|
onFocus: onFocus,
|
|
38
|
+
role: "presentation",
|
|
38
39
|
className: (0, _runtime.ax)(["_195g10v4 _18zr1ejb", "_irr3166n _1di61dty", isSelected && "_bfhkfg4m _16qsd1ld _irr3i1yw _1di619ru"]),
|
|
39
40
|
style: {
|
|
40
41
|
"--_g94mg3": (0, _runtime.ix)("inset 2px 0 0 0 ".concat("var(--ds-border-selected, #0C66E4)"))
|
|
@@ -9,16 +9,23 @@ exports.StopPropagation = void 0;
|
|
|
9
9
|
require("./index.compiled.css");
|
|
10
10
|
var _runtime = require("@compiled/react/runtime");
|
|
11
11
|
var _react = _interopRequireWildcard(require("react"));
|
|
12
|
+
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
13
|
+
var _compiled = require("@atlaskit/primitives/compiled");
|
|
12
14
|
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); }
|
|
13
|
-
var styles =
|
|
15
|
+
var styles = {
|
|
16
|
+
pressable: "_c71lidpf _p12fidpf _kqswstnw"
|
|
17
|
+
};
|
|
14
18
|
var StopPropagation = exports.StopPropagation = function StopPropagation(_ref) {
|
|
15
19
|
var children = _ref.children;
|
|
16
20
|
var onClick = (0, _react.useCallback)(function (e) {
|
|
17
21
|
// Prevent click event inside modal from bubble up
|
|
18
22
|
e.stopPropagation();
|
|
19
23
|
}, []);
|
|
20
|
-
return /*#__PURE__*/_react.default.createElement(
|
|
24
|
+
return (0, _platformFeatureFlags.fg)('navx-1184-fix-smart-link-a11y-interactive-states') ? /*#__PURE__*/_react.default.createElement(_compiled.Pressable, {
|
|
25
|
+
xcss: styles.pressable,
|
|
26
|
+
onClick: onClick
|
|
27
|
+
}, children) : /*#__PURE__*/_react.default.createElement("span", {
|
|
21
28
|
onClick: onClick,
|
|
22
|
-
className: (0, _runtime.ax)([
|
|
29
|
+
className: (0, _runtime.ax)([styles.pressable])
|
|
23
30
|
}, children);
|
|
24
31
|
};
|
|
@@ -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: "40.5.
|
|
5
|
+
packageVersion: "40.5.6"
|
|
6
6
|
};
|
|
7
7
|
export let TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
8
8
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -8,10 +8,11 @@ export const IFrame = ({
|
|
|
8
8
|
className,
|
|
9
9
|
...props
|
|
10
10
|
}) => {
|
|
11
|
-
// eslint-disable-next-line
|
|
11
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop
|
|
12
12
|
return /*#__PURE__*/React.createElement("iframe", _extends({
|
|
13
13
|
className: className
|
|
14
14
|
}, props, {
|
|
15
|
-
ref: childRef
|
|
15
|
+
ref: childRef,
|
|
16
|
+
title: props.title
|
|
16
17
|
}));
|
|
17
18
|
};
|
|
@@ -135,7 +135,9 @@ const LinkInfo = ({
|
|
|
135
135
|
color: "color.text",
|
|
136
136
|
testId: `${testId}-title`
|
|
137
137
|
}, title), /*#__PURE__*/React.createElement("span", {
|
|
138
|
-
tabIndex: 0
|
|
138
|
+
tabIndex: 0,
|
|
139
|
+
role: "button",
|
|
140
|
+
"aria-hidden": true
|
|
139
141
|
})), /*#__PURE__*/React.createElement("div", {
|
|
140
142
|
className: ax(["_16jlidpf _1o9zidpf _i0dl1wug _zulp1b66 _1e0c1txw _3kllglyw"])
|
|
141
143
|
}, downloadButton, urlButton, sizeButton, fg('platform-smart-card-remove-legacy-button') ? /*#__PURE__*/React.createElement(LinkInfoButton, {
|
|
@@ -59,7 +59,8 @@ const HoverCardControl = ({
|
|
|
59
59
|
}, /*#__PURE__*/React.createElement("span", {
|
|
60
60
|
onMouseLeave: onMouseLeave,
|
|
61
61
|
onMouseMove: onMouseMove,
|
|
62
|
-
"data-testid": `${testId}-hover-card-wrapper
|
|
62
|
+
"data-testid": `${testId}-hover-card-wrapper`,
|
|
63
|
+
role: "presentation"
|
|
63
64
|
}, children));
|
|
64
65
|
};
|
|
65
66
|
export default HoverCardControl;
|
|
@@ -5,9 +5,12 @@
|
|
|
5
5
|
._14hp1wdt button{width:220px}
|
|
6
6
|
._18m915vq{overflow-y:hidden}
|
|
7
7
|
._18u0xy5q{margin-left:var(--ds-space-400,2pc)}
|
|
8
|
+
._19bvze3t{padding-left:var(--ds-space-0,0)}
|
|
8
9
|
._19pku2gc{margin-top:var(--ds-space-100,8px)}
|
|
9
10
|
._19pkv77o{margin-top:var(--ds-space-025,2px)}
|
|
11
|
+
._1bah1e5h{justify-content:left}
|
|
10
12
|
._1bto1l2s{text-overflow:ellipsis}
|
|
13
|
+
._1e0c1kw7{display:inherit}
|
|
11
14
|
._1e0c1txw{display:flex}
|
|
12
15
|
._1e0ccj1k{display:-webkit-box}
|
|
13
16
|
._1nmz1hna{word-break:break-word}
|
|
@@ -18,10 +21,19 @@
|
|
|
18
21
|
._4cvr1h6o{align-items:center}
|
|
19
22
|
._4cvr1y6m{align-items:flex-start}
|
|
20
23
|
._80omtlke{cursor:pointer}
|
|
24
|
+
._bfhk1j28{background-color:transparent}
|
|
25
|
+
._ca0qze3t{padding-top:var(--ds-space-0,0)}
|
|
26
|
+
._n3tdze3t{padding-bottom:var(--ds-space-0,0)}
|
|
21
27
|
._ngc01fxt >div, ._1t4p1fxt >span{color:var(--ds-text,#172b4d)}
|
|
22
28
|
._o5724jg8{white-space:normal}
|
|
23
29
|
._otyrv77o{margin-bottom:var(--ds-space-025,2px)}
|
|
24
30
|
._sudp1e54{-webkit-box-orient:vertical}
|
|
31
|
+
._syaz14q2{color:var(--ds-link,#0c66e4)}
|
|
32
|
+
._u5f3ze3t{padding-right:var(--ds-space-0,0)}
|
|
33
|
+
._1bnx8stv:hover{text-decoration-line:underline}
|
|
25
34
|
._1eo073ad button:hover{cursor:default}
|
|
35
|
+
._30l316c2:hover{color:var(--ds-link-pressed,#05c)}
|
|
26
36
|
._6pup1kw7 button:hover{background-color:inherit}
|
|
37
|
+
._9oik1r31:hover{text-decoration-color:currentColor}
|
|
38
|
+
._jf4cnqa1:hover{text-decoration-style:solid}
|
|
27
39
|
@supports not (-webkit-line-clamp:1){._102k16q4{max-height:calc(var(--_t4prqe)*1rem)}}
|
|
@@ -7,16 +7,20 @@ import { FormattedMessage } from 'react-intl-next';
|
|
|
7
7
|
import { DropdownItem, DropdownItemGroup } from '@atlaskit/dropdown-menu';
|
|
8
8
|
import ErrorIcon from '@atlaskit/icon/core/migration/status-error--error';
|
|
9
9
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
10
|
+
import { Pressable } from '@atlaskit/primitives/compiled';
|
|
10
11
|
import { N800, R50, R500 } from '@atlaskit/theme/colors';
|
|
11
12
|
import { useAnalyticsEvents } from '../../../../../../../../common/analytics/generated/use-analytics-events';
|
|
12
13
|
import { messages } from '../../../../../../../../messages';
|
|
13
14
|
import useInvokeClientAction from '../../../../../../../../state/hooks/use-invoke-client-action';
|
|
14
15
|
import { getFormattedMessage } from '../../../../../utils';
|
|
15
16
|
const MAX_LINE_NUMBER = 8;
|
|
16
|
-
const
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
17
|
+
const styles = {
|
|
18
|
+
contentStyles: "_zulpu2gc _11c81ixg _1reo15vq _18m915vq _1e0c1txw _1ul9idpf _2lx2vrvc _19pkv77o _4cvr1y6m _pqme2smr _102e2smr _ngc01fxt _1t4p1fxt",
|
|
19
|
+
linkStyles: "_zulpu2gc _1reo15vq _18m915vq _11c82smr _1e0c1txw _1ul9idpf _2lx2vrvc _4cvr1h6o _80omtlke _19pku2gc _18u0xy5q _otyrv77o",
|
|
20
|
+
textStylesBase: "_11c81ixg _1reo15vq _18m915vq _o5724jg8 _1e0ccj1k _1bto1l2s _1nmz1hna _sudp1e54",
|
|
21
|
+
dropdownItemGroupStyles: "_14hp1wdt _6pup1kw7 _1eo073ad",
|
|
22
|
+
openIssueInJiraStyles: "_11c82smr _bfhk1j28 _1bah1e5h _1e0c1kw7 _syaz14q2 _ca0qze3t _u5f3ze3t _n3tdze3t _19bvze3t _9oik1r31 _1bnx8stv _jf4cnqa1 _30l316c2"
|
|
23
|
+
};
|
|
20
24
|
const LozengeActionError = ({
|
|
21
25
|
errorMessage,
|
|
22
26
|
testId,
|
|
@@ -39,7 +43,7 @@ const LozengeActionError = ({
|
|
|
39
43
|
const dynamicCss = null;
|
|
40
44
|
const content = useMemo(() => {
|
|
41
45
|
return /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
42
|
-
className: ax([
|
|
46
|
+
className: ax([styles.contentStyles])
|
|
43
47
|
}, /*#__PURE__*/React.createElement(ErrorIcon, {
|
|
44
48
|
testId: `${testId}-icon`,
|
|
45
49
|
LEGACY_size: "medium",
|
|
@@ -49,13 +53,20 @@ const LozengeActionError = ({
|
|
|
49
53
|
spacing: "spacious"
|
|
50
54
|
}), /*#__PURE__*/React.createElement("span", {
|
|
51
55
|
"data-testid": `${testId}-error-message`,
|
|
52
|
-
className: ax([
|
|
56
|
+
className: ax([styles.textStylesBase, "_1yyj1n6p _102k16q4"]),
|
|
53
57
|
style: {
|
|
54
58
|
"--_t4prqe": ix(maxLineNumber)
|
|
55
59
|
}
|
|
56
60
|
}, typeof errorMessage === 'string' ? errorMessage : getFormattedMessage(errorMessage))), isPreviewAvailable ? /*#__PURE__*/React.createElement("div", {
|
|
57
|
-
className: ax([
|
|
58
|
-
}, /*#__PURE__*/React.createElement(
|
|
61
|
+
className: ax([styles.linkStyles])
|
|
62
|
+
}, fg('navx-1184-fix-smart-link-a11y-interactive-states') ? /*#__PURE__*/React.createElement(Pressable, {
|
|
63
|
+
testId: `${testId}-open-embed`,
|
|
64
|
+
onClick: handlePreviewOpen,
|
|
65
|
+
xcss: styles.openIssueInJiraStyles
|
|
66
|
+
}, fg('confluence-issue-terminology-refresh') ? /*#__PURE__*/React.createElement(FormattedMessage, messages.open_issue_in_jiraIssueTermRefresh) : /*#__PURE__*/React.createElement(FormattedMessage, messages.open_issue_in_jira)) :
|
|
67
|
+
/*#__PURE__*/
|
|
68
|
+
// eslint-disable-next-line @atlaskit/design-system/no-html-anchor, jsx-a11y/anchor-is-valid, jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
|
|
69
|
+
React.createElement("a", {
|
|
59
70
|
target: "_blank",
|
|
60
71
|
"data-testid": `${testId}-open-embed`,
|
|
61
72
|
onClick: handlePreviewOpen
|
|
@@ -63,7 +74,7 @@ const LozengeActionError = ({
|
|
|
63
74
|
}, [errorMessage, handlePreviewOpen, isPreviewAvailable, testId, dynamicCss]);
|
|
64
75
|
return /*#__PURE__*/React.createElement("span", {
|
|
65
76
|
"data-testid": `${testId}-error-item-group`,
|
|
66
|
-
className: ax([
|
|
77
|
+
className: ax([styles.dropdownItemGroupStyles])
|
|
67
78
|
}, /*#__PURE__*/React.createElement(DropdownItemGroup, null, /*#__PURE__*/React.createElement(DropdownItem, {
|
|
68
79
|
testId: `${testId}-error`
|
|
69
80
|
}, content)));
|
|
@@ -22,19 +22,16 @@ const LozengeActionItem = ({
|
|
|
22
22
|
var _e$currentTarget, _e$currentTarget$firs;
|
|
23
23
|
(_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
24
|
}, []);
|
|
25
|
-
return (
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
isBold: true
|
|
37
|
-
} : undefined), text)))
|
|
38
|
-
);
|
|
25
|
+
return /*#__PURE__*/React.createElement("span", {
|
|
26
|
+
onMouseEnter: handleMouseEnter,
|
|
27
|
+
role: "presentation"
|
|
28
|
+
}, /*#__PURE__*/React.createElement(DropdownItem, {
|
|
29
|
+
onClick: handleClick,
|
|
30
|
+
testId: testId
|
|
31
|
+
}, /*#__PURE__*/React.createElement(Lozenge, _extends({
|
|
32
|
+
appearance: appearance
|
|
33
|
+
}, fg('platform-component-visual-refresh') ? {
|
|
34
|
+
isBold: true
|
|
35
|
+
} : undefined), text)));
|
|
39
36
|
};
|
|
40
37
|
export default LozengeActionItem;
|
|
@@ -9,7 +9,7 @@ import LinkWarningModal from './LinkWarningModal';
|
|
|
9
9
|
import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
|
|
10
10
|
const PACKAGE_DATA = {
|
|
11
11
|
packageName: "@atlaskit/smart-card",
|
|
12
|
-
packageVersion: "40.5.
|
|
12
|
+
packageVersion: "40.5.6",
|
|
13
13
|
componentName: 'linkUrl'
|
|
14
14
|
};
|
|
15
15
|
const Anchor = withLinkClickedEvent('a');
|
|
@@ -28,6 +28,7 @@ const RelatedLinkItem = ({
|
|
|
28
28
|
return /*#__PURE__*/React.createElement("div", {
|
|
29
29
|
"data-testId": testId,
|
|
30
30
|
onFocus: onFocus,
|
|
31
|
+
role: "presentation",
|
|
31
32
|
className: ax(["_195g10v4 _18zr1ejb", "_irr3166n _1di61dty", isSelected && "_bfhkfg4m _16qs1kf8 _irr3i1yw _1di619ru"])
|
|
32
33
|
}, /*#__PURE__*/React.createElement(Card, {
|
|
33
34
|
appearance: "block",
|
|
@@ -2,7 +2,11 @@
|
|
|
2
2
|
import "./index.compiled.css";
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React, { useCallback } from 'react';
|
|
5
|
-
|
|
5
|
+
import { fg } from "@atlaskit/platform-feature-flags";
|
|
6
|
+
import { Pressable } from '@atlaskit/primitives/compiled';
|
|
7
|
+
const styles = {
|
|
8
|
+
pressable: "_c71lidpf _p12fidpf _kqswstnw"
|
|
9
|
+
};
|
|
6
10
|
export const StopPropagation = ({
|
|
7
11
|
children
|
|
8
12
|
}) => {
|
|
@@ -10,8 +14,11 @@ export const StopPropagation = ({
|
|
|
10
14
|
// Prevent click event inside modal from bubble up
|
|
11
15
|
e.stopPropagation();
|
|
12
16
|
}, []);
|
|
13
|
-
return /*#__PURE__*/React.createElement(
|
|
17
|
+
return fg('navx-1184-fix-smart-link-a11y-interactive-states') ? /*#__PURE__*/React.createElement(Pressable, {
|
|
18
|
+
xcss: styles.pressable,
|
|
19
|
+
onClick: onClick
|
|
20
|
+
}, children) : /*#__PURE__*/React.createElement("span", {
|
|
14
21
|
onClick: onClick,
|
|
15
|
-
className: ax([
|
|
22
|
+
className: ax([styles.pressable])
|
|
16
23
|
}, children);
|
|
17
24
|
};
|
|
@@ -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: "40.5.
|
|
7
|
+
packageVersion: "40.5.6"
|
|
8
8
|
};
|
|
9
9
|
export var TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
10
10
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -9,10 +9,11 @@ export var IFrame = function IFrame(_ref) {
|
|
|
9
9
|
var childRef = _ref.childRef,
|
|
10
10
|
className = _ref.className,
|
|
11
11
|
props = _objectWithoutProperties(_ref, _excluded);
|
|
12
|
-
// eslint-disable-next-line
|
|
12
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop
|
|
13
13
|
return /*#__PURE__*/React.createElement("iframe", _extends({
|
|
14
14
|
className: className
|
|
15
15
|
}, props, {
|
|
16
|
-
ref: childRef
|
|
16
|
+
ref: childRef,
|
|
17
|
+
title: props.title
|
|
17
18
|
}));
|
|
18
19
|
};
|
|
@@ -139,7 +139,9 @@ var LinkInfo = function LinkInfo(_ref) {
|
|
|
139
139
|
color: "color.text",
|
|
140
140
|
testId: "".concat(testId, "-title")
|
|
141
141
|
}, title), /*#__PURE__*/React.createElement("span", {
|
|
142
|
-
tabIndex: 0
|
|
142
|
+
tabIndex: 0,
|
|
143
|
+
role: "button",
|
|
144
|
+
"aria-hidden": true
|
|
143
145
|
})), /*#__PURE__*/React.createElement("div", {
|
|
144
146
|
className: ax(["_16jlidpf _1o9zidpf _i0dl1wug _zulp1b66 _1e0c1txw _3kllglyw"])
|
|
145
147
|
}, downloadButton, urlButton, sizeButton, fg('platform-smart-card-remove-legacy-button') ? /*#__PURE__*/React.createElement(LinkInfoButton, {
|
|
@@ -63,7 +63,8 @@ var HoverCardControl = function HoverCardControl(_ref) {
|
|
|
63
63
|
}, /*#__PURE__*/React.createElement("span", {
|
|
64
64
|
onMouseLeave: onMouseLeave,
|
|
65
65
|
onMouseMove: onMouseMove,
|
|
66
|
-
"data-testid": "".concat(testId, "-hover-card-wrapper")
|
|
66
|
+
"data-testid": "".concat(testId, "-hover-card-wrapper"),
|
|
67
|
+
role: "presentation"
|
|
67
68
|
}, children));
|
|
68
69
|
};
|
|
69
70
|
export default HoverCardControl;
|
|
@@ -5,9 +5,12 @@
|
|
|
5
5
|
._14hp1wdt button{width:220px}
|
|
6
6
|
._18m915vq{overflow-y:hidden}
|
|
7
7
|
._18u0xy5q{margin-left:var(--ds-space-400,2pc)}
|
|
8
|
+
._19bvze3t{padding-left:var(--ds-space-0,0)}
|
|
8
9
|
._19pku2gc{margin-top:var(--ds-space-100,8px)}
|
|
9
10
|
._19pkv77o{margin-top:var(--ds-space-025,2px)}
|
|
11
|
+
._1bah1e5h{justify-content:left}
|
|
10
12
|
._1bto1l2s{text-overflow:ellipsis}
|
|
13
|
+
._1e0c1kw7{display:inherit}
|
|
11
14
|
._1e0c1txw{display:flex}
|
|
12
15
|
._1e0ccj1k{display:-webkit-box}
|
|
13
16
|
._1nmz1hna{word-break:break-word}
|
|
@@ -18,10 +21,19 @@
|
|
|
18
21
|
._4cvr1h6o{align-items:center}
|
|
19
22
|
._4cvr1y6m{align-items:flex-start}
|
|
20
23
|
._80omtlke{cursor:pointer}
|
|
21
|
-
.
|
|
24
|
+
._bfhk1j28{background-color:transparent}
|
|
25
|
+
._ca0qze3t{padding-top:var(--ds-space-0,0)}
|
|
26
|
+
._n3tdze3t{padding-bottom:var(--ds-space-0,0)}
|
|
27
|
+
._ngc01fxt >div, ._1t4p1fxt >span{color:var(--ds-text,#172b4d)}
|
|
22
28
|
._o5724jg8{white-space:normal}
|
|
23
29
|
._otyrv77o{margin-bottom:var(--ds-space-025,2px)}
|
|
24
30
|
._sudp1e54{-webkit-box-orient:vertical}
|
|
31
|
+
._syaz14q2{color:var(--ds-link,#0c66e4)}
|
|
32
|
+
._u5f3ze3t{padding-right:var(--ds-space-0,0)}
|
|
33
|
+
._1bnx8stv:hover{text-decoration-line:underline}
|
|
25
34
|
._1eo073ad button:hover{cursor:default}
|
|
35
|
+
._30l316c2:hover{color:var(--ds-link-pressed,#05c)}
|
|
26
36
|
._6pup1kw7 button:hover{background-color:inherit}
|
|
37
|
+
._9oik1r31:hover{text-decoration-color:currentColor}
|
|
38
|
+
._jf4cnqa1:hover{text-decoration-style:solid}
|
|
27
39
|
@supports not (-webkit-line-clamp:1){._102k1hw0{max-height:var(--_hm3wc5)}}
|
|
@@ -7,16 +7,20 @@ import { FormattedMessage } from 'react-intl-next';
|
|
|
7
7
|
import { DropdownItem, DropdownItemGroup } from '@atlaskit/dropdown-menu';
|
|
8
8
|
import ErrorIcon from '@atlaskit/icon/core/migration/status-error--error';
|
|
9
9
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
10
|
+
import { Pressable } from '@atlaskit/primitives/compiled';
|
|
10
11
|
import { N800, R50, R500 } from '@atlaskit/theme/colors';
|
|
11
12
|
import { useAnalyticsEvents } from '../../../../../../../../common/analytics/generated/use-analytics-events';
|
|
12
13
|
import { messages } from '../../../../../../../../messages';
|
|
13
14
|
import useInvokeClientAction from '../../../../../../../../state/hooks/use-invoke-client-action';
|
|
14
15
|
import { getFormattedMessage } from '../../../../../utils';
|
|
15
16
|
var MAX_LINE_NUMBER = 8;
|
|
16
|
-
var
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
17
|
+
var styles = {
|
|
18
|
+
contentStyles: "_zulpu2gc _11c81ixg _1reo15vq _18m915vq _1e0c1txw _1ul9idpf _2lx2vrvc _19pkv77o _4cvr1y6m _pqme2smr _102e2smr _ngc01fxt _1t4p1fxt",
|
|
19
|
+
linkStyles: "_zulpu2gc _1reo15vq _18m915vq _11c82smr _1e0c1txw _1ul9idpf _2lx2vrvc _4cvr1h6o _80omtlke _19pku2gc _18u0xy5q _otyrv77o",
|
|
20
|
+
textStylesBase: "_11c81ixg _1reo15vq _18m915vq _o5724jg8 _1e0ccj1k _1bto1l2s _1nmz1hna _sudp1e54",
|
|
21
|
+
dropdownItemGroupStyles: "_14hp1wdt _6pup1kw7 _1eo073ad",
|
|
22
|
+
openIssueInJiraStyles: "_11c82smr _bfhk1j28 _1bah1e5h _1e0c1kw7 _syaz14q2 _ca0qze3t _u5f3ze3t _n3tdze3t _19bvze3t _9oik1r31 _1bnx8stv _jf4cnqa1 _30l316c2"
|
|
23
|
+
};
|
|
20
24
|
var LozengeActionError = function LozengeActionError(_ref) {
|
|
21
25
|
var errorMessage = _ref.errorMessage,
|
|
22
26
|
testId = _ref.testId,
|
|
@@ -38,10 +42,7 @@ var LozengeActionError = function LozengeActionError(_ref) {
|
|
|
38
42
|
var dynamicCss = null;
|
|
39
43
|
var content = useMemo(function () {
|
|
40
44
|
return /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
41
|
-
className: ax([
|
|
42
|
-
style: {
|
|
43
|
-
"--_ggxzyp": ix("var(--ds-text, ".concat(N800, ")"))
|
|
44
|
-
}
|
|
45
|
+
className: ax([styles.contentStyles])
|
|
45
46
|
}, /*#__PURE__*/React.createElement(ErrorIcon, {
|
|
46
47
|
testId: "".concat(testId, "-icon"),
|
|
47
48
|
LEGACY_size: "medium",
|
|
@@ -51,14 +52,21 @@ var LozengeActionError = function LozengeActionError(_ref) {
|
|
|
51
52
|
spacing: "spacious"
|
|
52
53
|
}), /*#__PURE__*/React.createElement("span", {
|
|
53
54
|
"data-testid": "".concat(testId, "-error-message"),
|
|
54
|
-
className: ax([
|
|
55
|
+
className: ax([styles.textStylesBase, "_1yyj1n6p _102k1hw0"]),
|
|
55
56
|
style: {
|
|
56
57
|
"--_t4prqe": ix(maxLineNumber),
|
|
57
58
|
"--_hm3wc5": ix("calc(".concat(maxLineNumber, " * 1rem)"))
|
|
58
59
|
}
|
|
59
60
|
}, typeof errorMessage === 'string' ? errorMessage : getFormattedMessage(errorMessage))), isPreviewAvailable ? /*#__PURE__*/React.createElement("div", {
|
|
60
|
-
className: ax([
|
|
61
|
-
}, /*#__PURE__*/React.createElement(
|
|
61
|
+
className: ax([styles.linkStyles])
|
|
62
|
+
}, fg('navx-1184-fix-smart-link-a11y-interactive-states') ? /*#__PURE__*/React.createElement(Pressable, {
|
|
63
|
+
testId: "".concat(testId, "-open-embed"),
|
|
64
|
+
onClick: handlePreviewOpen,
|
|
65
|
+
xcss: styles.openIssueInJiraStyles
|
|
66
|
+
}, fg('confluence-issue-terminology-refresh') ? /*#__PURE__*/React.createElement(FormattedMessage, messages.open_issue_in_jiraIssueTermRefresh) : /*#__PURE__*/React.createElement(FormattedMessage, messages.open_issue_in_jira)) :
|
|
67
|
+
/*#__PURE__*/
|
|
68
|
+
// eslint-disable-next-line @atlaskit/design-system/no-html-anchor, jsx-a11y/anchor-is-valid, jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
|
|
69
|
+
React.createElement("a", {
|
|
62
70
|
target: "_blank",
|
|
63
71
|
"data-testid": "".concat(testId, "-open-embed"),
|
|
64
72
|
onClick: handlePreviewOpen
|
|
@@ -66,7 +74,7 @@ var LozengeActionError = function LozengeActionError(_ref) {
|
|
|
66
74
|
}, [errorMessage, handlePreviewOpen, isPreviewAvailable, testId, dynamicCss]);
|
|
67
75
|
return /*#__PURE__*/React.createElement("span", {
|
|
68
76
|
"data-testid": "".concat(testId, "-error-item-group"),
|
|
69
|
-
className: ax([
|
|
77
|
+
className: ax([styles.dropdownItemGroupStyles])
|
|
70
78
|
}, /*#__PURE__*/React.createElement(DropdownItemGroup, null, /*#__PURE__*/React.createElement(DropdownItem, {
|
|
71
79
|
testId: "".concat(testId, "-error")
|
|
72
80
|
}, content)));
|
|
@@ -21,19 +21,16 @@ var LozengeActionItem = function LozengeActionItem(_ref) {
|
|
|
21
21
|
var _e$currentTarget;
|
|
22
22
|
(_e$currentTarget = e.currentTarget) === null || _e$currentTarget === void 0 || (_e$currentTarget = _e$currentTarget.firstElementChild) === null || _e$currentTarget === void 0 || _e$currentTarget.focus();
|
|
23
23
|
}, []);
|
|
24
|
-
return (
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
isBold: true
|
|
36
|
-
} : undefined), text)))
|
|
37
|
-
);
|
|
24
|
+
return /*#__PURE__*/React.createElement("span", {
|
|
25
|
+
onMouseEnter: handleMouseEnter,
|
|
26
|
+
role: "presentation"
|
|
27
|
+
}, /*#__PURE__*/React.createElement(DropdownItem, {
|
|
28
|
+
onClick: handleClick,
|
|
29
|
+
testId: testId
|
|
30
|
+
}, /*#__PURE__*/React.createElement(Lozenge, _extends({
|
|
31
|
+
appearance: appearance
|
|
32
|
+
}, fg('platform-component-visual-refresh') ? {
|
|
33
|
+
isBold: true
|
|
34
|
+
} : undefined), text)));
|
|
38
35
|
};
|
|
39
36
|
export default LozengeActionItem;
|
|
@@ -12,7 +12,7 @@ import LinkWarningModal from './LinkWarningModal';
|
|
|
12
12
|
import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
|
|
13
13
|
var PACKAGE_DATA = {
|
|
14
14
|
packageName: "@atlaskit/smart-card",
|
|
15
|
-
packageVersion: "40.5.
|
|
15
|
+
packageVersion: "40.5.6",
|
|
16
16
|
componentName: 'linkUrl'
|
|
17
17
|
};
|
|
18
18
|
var Anchor = withLinkClickedEvent('a');
|
|
@@ -27,6 +27,7 @@ var RelatedLinkItem = function RelatedLinkItem(_ref) {
|
|
|
27
27
|
return /*#__PURE__*/React.createElement("div", {
|
|
28
28
|
"data-testId": testId,
|
|
29
29
|
onFocus: onFocus,
|
|
30
|
+
role: "presentation",
|
|
30
31
|
className: ax(["_195g10v4 _18zr1ejb", "_irr3166n _1di61dty", isSelected && "_bfhkfg4m _16qsd1ld _irr3i1yw _1di619ru"]),
|
|
31
32
|
style: {
|
|
32
33
|
"--_g94mg3": ix("inset 2px 0 0 0 ".concat("var(--ds-border-selected, #0C66E4)"))
|
|
@@ -2,15 +2,22 @@
|
|
|
2
2
|
import "./index.compiled.css";
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React, { useCallback } from 'react';
|
|
5
|
-
|
|
5
|
+
import { fg } from "@atlaskit/platform-feature-flags";
|
|
6
|
+
import { Pressable } from '@atlaskit/primitives/compiled';
|
|
7
|
+
var styles = {
|
|
8
|
+
pressable: "_c71lidpf _p12fidpf _kqswstnw"
|
|
9
|
+
};
|
|
6
10
|
export var StopPropagation = function StopPropagation(_ref) {
|
|
7
11
|
var children = _ref.children;
|
|
8
12
|
var onClick = useCallback(function (e) {
|
|
9
13
|
// Prevent click event inside modal from bubble up
|
|
10
14
|
e.stopPropagation();
|
|
11
15
|
}, []);
|
|
12
|
-
return /*#__PURE__*/React.createElement(
|
|
16
|
+
return fg('navx-1184-fix-smart-link-a11y-interactive-states') ? /*#__PURE__*/React.createElement(Pressable, {
|
|
17
|
+
xcss: styles.pressable,
|
|
18
|
+
onClick: onClick
|
|
19
|
+
}, children) : /*#__PURE__*/React.createElement("span", {
|
|
13
20
|
onClick: onClick,
|
|
14
|
-
className: ax([
|
|
21
|
+
className: ax([styles.pressable])
|
|
15
22
|
}, children);
|
|
16
23
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/smart-card",
|
|
3
|
-
"version": "40.
|
|
3
|
+
"version": "40.6.0",
|
|
4
4
|
"description": "Smart card component",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"@atlaskit/form": "^12.0.0",
|
|
39
39
|
"@atlaskit/frontend-utilities": "^3.1.0",
|
|
40
40
|
"@atlaskit/heading": "^5.2.0",
|
|
41
|
-
"@atlaskit/icon": "^27.
|
|
41
|
+
"@atlaskit/icon": "^27.8.0",
|
|
42
42
|
"@atlaskit/icon-file-type": "^7.0.0",
|
|
43
43
|
"@atlaskit/icon-lab": "^5.2.0",
|
|
44
44
|
"@atlaskit/icon-object": "^7.1.0",
|
|
@@ -243,6 +243,9 @@
|
|
|
243
243
|
},
|
|
244
244
|
"platform-linking-slack-entity-support": {
|
|
245
245
|
"type": "boolean"
|
|
246
|
+
},
|
|
247
|
+
"navx-1184-fix-smart-link-a11y-interactive-states": {
|
|
248
|
+
"type": "boolean"
|
|
246
249
|
}
|
|
247
250
|
},
|
|
248
251
|
"compassUnitTestMetricSourceId": "ari:cloud:compass:a436116f-02ce-4520-8fbb-7301462a1674:metric-source/c5751cc6-3513-4070-9deb-af31e86aed34/f74ef1bc-7240-4aac-9dc8-9dc43b502089"
|