@atlaskit/smart-card 32.7.5 → 32.7.7
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 +16 -0
- package/dist/cjs/extractors/flexible/actions/index.js +5 -7
- package/dist/cjs/state/hooks/use-ai-summary/ai-summary-service/index.js +9 -6
- package/dist/cjs/state/hooks/use-ai-summary/ai-summary-service/types.js +4 -5
- package/dist/cjs/state/hooks/use-ai-summary/index.js +18 -4
- package/dist/cjs/utils/analytics/analytics.js +4 -6
- package/dist/cjs/utils/mocks.js +5 -7
- package/dist/cjs/view/BlockCard/views/styled.js +1 -1
- package/dist/cjs/view/Card/index.js +5 -7
- package/dist/cjs/view/EmbedCard/EmbedResizeMessageListener.js +7 -10
- package/dist/cjs/view/FlexibleCard/components/actions/action/action-button/index.js +1 -1
- package/dist/cjs/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-container/common/test-utils.js +10 -12
- package/dist/cjs/view/FlexibleCard/components/blocks/utils.js +1 -1
- package/dist/cjs/view/FlexibleCard/components/common/atlaskit-icon/index.js +61 -61
- package/dist/cjs/view/FlexibleCard/components/elements/badge/index.js +1 -1
- package/dist/cjs/view/FlexibleCard/components/elements/utils.js +34 -34
- package/dist/cjs/view/FlexibleCard/components/utils.js +5 -5
- package/dist/cjs/view/HoverCard/styled.js +1 -1
- package/dist/cjs/view/InlineCard/ErroredView/index.js +8 -11
- package/dist/cjs/view/InlineCard/ForbiddenView/index.js +10 -13
- package/dist/cjs/view/InlineCard/IconAndTitleLayout/index.js +7 -10
- package/dist/cjs/view/InlineCard/ResolvedView/index.js +5 -7
- package/dist/cjs/view/InlineCard/ResolvingView/index.js +5 -7
- package/dist/cjs/view/LinkUrl/index.js +1 -1
- package/dist/cjs/view/LinkView/index.js +5 -7
- package/dist/es2019/state/hooks/use-ai-summary/ai-summary-service/index.js +6 -1
- package/dist/es2019/state/hooks/use-ai-summary/index.js +13 -1
- package/dist/es2019/utils/analytics/analytics.js +1 -1
- package/dist/es2019/view/BlockCard/views/styled.js +1 -1
- package/dist/es2019/view/FlexibleCard/components/actions/action/action-button/index.js +1 -1
- package/dist/es2019/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-container/common/test-utils.js +3 -3
- package/dist/es2019/view/FlexibleCard/components/utils.js +3 -3
- package/dist/es2019/view/HoverCard/styled.js +1 -1
- package/dist/es2019/view/LinkUrl/index.js +1 -1
- package/dist/esm/extractors/flexible/actions/index.js +5 -7
- package/dist/esm/state/hooks/use-ai-summary/ai-summary-service/index.js +9 -6
- package/dist/esm/state/hooks/use-ai-summary/ai-summary-service/types.js +4 -5
- package/dist/esm/state/hooks/use-ai-summary/index.js +18 -4
- package/dist/esm/utils/analytics/analytics.js +4 -6
- package/dist/esm/utils/mocks.js +5 -7
- package/dist/esm/view/BlockCard/views/styled.js +1 -1
- package/dist/esm/view/Card/index.js +5 -7
- package/dist/esm/view/EmbedCard/EmbedResizeMessageListener.js +7 -10
- package/dist/esm/view/FlexibleCard/components/actions/action/action-button/index.js +1 -1
- package/dist/esm/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-container/common/test-utils.js +10 -12
- package/dist/esm/view/FlexibleCard/components/blocks/utils.js +1 -1
- package/dist/esm/view/FlexibleCard/components/common/atlaskit-icon/index.js +61 -61
- package/dist/esm/view/FlexibleCard/components/elements/badge/index.js +1 -1
- package/dist/esm/view/FlexibleCard/components/elements/utils.js +34 -34
- package/dist/esm/view/FlexibleCard/components/utils.js +5 -5
- package/dist/esm/view/HoverCard/styled.js +1 -1
- package/dist/esm/view/InlineCard/ErroredView/index.js +8 -11
- package/dist/esm/view/InlineCard/ForbiddenView/index.js +10 -13
- package/dist/esm/view/InlineCard/IconAndTitleLayout/index.js +7 -10
- package/dist/esm/view/InlineCard/ResolvedView/index.js +5 -7
- package/dist/esm/view/InlineCard/ResolvingView/index.js +5 -7
- package/dist/esm/view/LinkUrl/index.js +1 -1
- package/dist/esm/view/LinkView/index.js +5 -7
- package/dist/types/state/hooks/use-ai-summary/ai-summary-service/index.d.ts +1 -0
- package/dist/types/state/hooks/use-ai-summary/ai-summary-service/types.d.ts +2 -0
- package/dist/types-ts4.5/state/hooks/use-ai-summary/ai-summary-service/index.d.ts +1 -0
- package/dist/types-ts4.5/state/hooks/use-ai-summary/ai-summary-service/types.d.ts +2 -0
- package/package.json +4 -1
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
2
2
|
import _createClass from "@babel/runtime/helpers/createClass";
|
|
3
3
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
4
|
-
var _SmartLinkActionTypeT, _SmartLinkActionTypeU;
|
|
5
4
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
6
5
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
7
6
|
import { SmartLinkActionType } from '@atlaskit/linking-types';
|
|
@@ -10,7 +9,7 @@ export var ANALYTICS_CHANNEL = 'media';
|
|
|
10
9
|
export var context = {
|
|
11
10
|
componentName: 'smart-cards',
|
|
12
11
|
packageName: "@atlaskit/smart-card",
|
|
13
|
-
packageVersion: "32.7.
|
|
12
|
+
packageVersion: "32.7.7"
|
|
14
13
|
};
|
|
15
14
|
export var TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
16
15
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -22,8 +21,8 @@ export var TrackQuickActionFailureReason = /*#__PURE__*/function (TrackQuickActi
|
|
|
22
21
|
TrackQuickActionFailureReason["UnknownError"] = "UnknownError";
|
|
23
22
|
return TrackQuickActionFailureReason;
|
|
24
23
|
}({});
|
|
25
|
-
export var SmartLinkActionTypeTrackingEventMapper = (
|
|
26
|
-
export var SmartLinkActionTypeUiEventMapper = (
|
|
24
|
+
export var SmartLinkActionTypeTrackingEventMapper = _defineProperty(_defineProperty(_defineProperty({}, SmartLinkActionType.FollowEntityAction, 'Follow'), SmartLinkActionType.StatusUpdateAction, 'StatusUpdate'), SmartLinkActionType.UnfollowEntityAction, 'Unfollow');
|
|
25
|
+
export var SmartLinkActionTypeUiEventMapper = _defineProperty(_defineProperty({}, SmartLinkActionType.FollowEntityAction, 'smartLinkFollowButton'), SmartLinkActionType.UnfollowEntityAction, 'smartLinkFollowButton');
|
|
27
26
|
var uiActionSubjectIds = {
|
|
28
27
|
DownloadAction: 'downloadDocument',
|
|
29
28
|
PreviewAction: 'invokePreviewScreen',
|
|
@@ -34,7 +33,7 @@ export var SmartLinkEvents = /*#__PURE__*/function () {
|
|
|
34
33
|
function SmartLinkEvents() {
|
|
35
34
|
_classCallCheck(this, SmartLinkEvents);
|
|
36
35
|
}
|
|
37
|
-
_createClass(SmartLinkEvents, [{
|
|
36
|
+
return _createClass(SmartLinkEvents, [{
|
|
38
37
|
key: "insertSmartLink",
|
|
39
38
|
value: function insertSmartLink(url, type, createAnalyticsEvent) {
|
|
40
39
|
fireSmartLinkEvent({
|
|
@@ -50,7 +49,6 @@ export var SmartLinkEvents = /*#__PURE__*/function () {
|
|
|
50
49
|
}, createAnalyticsEvent);
|
|
51
50
|
}
|
|
52
51
|
}]);
|
|
53
|
-
return SmartLinkEvents;
|
|
54
52
|
}();
|
|
55
53
|
export var fireSmartLinkEvent = function fireSmartLinkEvent(payload, createAnalyticsEvent) {
|
|
56
54
|
if (createAnalyticsEvent) {
|
package/dist/esm/utils/mocks.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
2
2
|
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
3
3
|
import _createClass from "@babel/runtime/helpers/createClass";
|
|
4
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
5
4
|
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
6
5
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
6
|
+
import _inherits from "@babel/runtime/helpers/inherits";
|
|
7
7
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
8
8
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
9
|
-
function
|
|
9
|
+
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
10
10
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
11
11
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
12
12
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
@@ -201,13 +201,12 @@ export var fakeResponse = function fakeResponse() {
|
|
|
201
201
|
};
|
|
202
202
|
export var fakeFactory = function fakeFactory(implementation, implementationPost, implementationPrefetch, implementationAri) {
|
|
203
203
|
return /*#__PURE__*/function (_CardClient) {
|
|
204
|
-
_inherits(CustomClient, _CardClient);
|
|
205
|
-
var _super = _createSuper(CustomClient);
|
|
206
204
|
function CustomClient() {
|
|
207
205
|
_classCallCheck(this, CustomClient);
|
|
208
|
-
return
|
|
206
|
+
return _callSuper(this, CustomClient, arguments);
|
|
209
207
|
}
|
|
210
|
-
|
|
208
|
+
_inherits(CustomClient, _CardClient);
|
|
209
|
+
return _createClass(CustomClient, [{
|
|
211
210
|
key: "fetchData",
|
|
212
211
|
value: // @ts-ignore
|
|
213
212
|
function () {
|
|
@@ -297,7 +296,6 @@ export var fakeFactory = function fakeFactory(implementation, implementationPost
|
|
|
297
296
|
return fetchDataAris;
|
|
298
297
|
}()
|
|
299
298
|
}]);
|
|
300
|
-
return CustomClient;
|
|
301
299
|
}(CardClient);
|
|
302
300
|
};
|
|
303
301
|
export var waitFor = function waitFor() {
|
|
@@ -23,7 +23,7 @@ export var titleBlockCss = css({
|
|
|
23
23
|
gap: "var(--ds-space-100, 0.5em)",
|
|
24
24
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
|
|
25
25
|
"[data-smart-element='Title']": {
|
|
26
|
-
fontWeight: 600
|
|
26
|
+
fontWeight: "var(--ds-font-weight-semibold, 600)"
|
|
27
27
|
}
|
|
28
28
|
});
|
|
29
29
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
2
2
|
import _createClass from "@babel/runtime/helpers/createClass";
|
|
3
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
4
3
|
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
5
4
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
6
|
-
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
|
+
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
7
7
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
8
8
|
import React from 'react';
|
|
9
9
|
import { injectIntl, IntlProvider } from 'react-intl-next';
|
|
@@ -11,13 +11,12 @@ import { withAnalyticsContext, withAnalyticsEvents } from '@atlaskit/analytics-n
|
|
|
11
11
|
import { context } from '../../utils/analytics';
|
|
12
12
|
import { CardWithURLRenderer } from '../CardWithUrl/loader';
|
|
13
13
|
var PlainCard = /*#__PURE__*/function (_React$PureComponent) {
|
|
14
|
-
_inherits(PlainCard, _React$PureComponent);
|
|
15
|
-
var _super = _createSuper(PlainCard);
|
|
16
14
|
function PlainCard() {
|
|
17
15
|
_classCallCheck(this, PlainCard);
|
|
18
|
-
return
|
|
16
|
+
return _callSuper(this, PlainCard, arguments);
|
|
19
17
|
}
|
|
20
|
-
|
|
18
|
+
_inherits(PlainCard, _React$PureComponent);
|
|
19
|
+
return _createClass(PlainCard, [{
|
|
21
20
|
key: "render",
|
|
22
21
|
value: function render() {
|
|
23
22
|
var content = /*#__PURE__*/React.createElement(CardWithURLRenderer, this.props);
|
|
@@ -26,7 +25,6 @@ var PlainCard = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
26
25
|
}, content);
|
|
27
26
|
}
|
|
28
27
|
}]);
|
|
29
|
-
return PlainCard;
|
|
30
28
|
}(React.PureComponent);
|
|
31
29
|
export var Card = withAnalyticsContext(context)(withAnalyticsEvents()(injectIntl(PlainCard, {
|
|
32
30
|
enforceContext: false
|
|
@@ -1,25 +1,22 @@
|
|
|
1
1
|
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
2
2
|
import _createClass from "@babel/runtime/helpers/createClass";
|
|
3
|
-
import _assertThisInitialized from "@babel/runtime/helpers/assertThisInitialized";
|
|
4
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
5
3
|
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
6
4
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/inherits";
|
|
7
6
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
8
|
-
function
|
|
7
|
+
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
9
8
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
10
9
|
import React from 'react';
|
|
11
10
|
import { embedHeaderHeight } from './components/styled';
|
|
12
11
|
export var EmbedResizeMessageListener = /*#__PURE__*/function (_React$Component) {
|
|
13
|
-
_inherits(EmbedResizeMessageListener, _React$Component);
|
|
14
|
-
var _super = _createSuper(EmbedResizeMessageListener);
|
|
15
12
|
function EmbedResizeMessageListener() {
|
|
16
13
|
var _this;
|
|
17
14
|
_classCallCheck(this, EmbedResizeMessageListener);
|
|
18
15
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
19
16
|
args[_key] = arguments[_key];
|
|
20
17
|
}
|
|
21
|
-
_this =
|
|
22
|
-
_defineProperty(
|
|
18
|
+
_this = _callSuper(this, EmbedResizeMessageListener, [].concat(args));
|
|
19
|
+
_defineProperty(_this, "messageCallback", function (event) {
|
|
23
20
|
var embedIframeRef = _this.props.embedIframeRef;
|
|
24
21
|
var isFromExpectedIframe = embedIframeRef.current && event.source === embedIframeRef.current.contentWindow;
|
|
25
22
|
var isStringData = typeof event.data === 'string';
|
|
@@ -34,14 +31,15 @@ export var EmbedResizeMessageListener = /*#__PURE__*/function (_React$Component)
|
|
|
34
31
|
} catch (e) {}
|
|
35
32
|
}
|
|
36
33
|
});
|
|
37
|
-
_defineProperty(
|
|
34
|
+
_defineProperty(_this, "onEmbedHeightChange", function (data) {
|
|
38
35
|
var onHeightUpdate = _this.props.onHeightUpdate;
|
|
39
36
|
var height = data.height + embedHeaderHeight;
|
|
40
37
|
onHeightUpdate(height);
|
|
41
38
|
});
|
|
42
39
|
return _this;
|
|
43
40
|
}
|
|
44
|
-
|
|
41
|
+
_inherits(EmbedResizeMessageListener, _React$Component);
|
|
42
|
+
return _createClass(EmbedResizeMessageListener, [{
|
|
45
43
|
key: "componentDidMount",
|
|
46
44
|
value: function componentDidMount() {
|
|
47
45
|
window.addEventListener('message', this.messageCallback);
|
|
@@ -57,5 +55,4 @@ export var EmbedResizeMessageListener = /*#__PURE__*/function (_React$Component)
|
|
|
57
55
|
return this.props.children;
|
|
58
56
|
}
|
|
59
57
|
}]);
|
|
60
|
-
return EmbedResizeMessageListener;
|
|
61
58
|
}(React.Component);
|
|
@@ -26,7 +26,7 @@ var getButtonStyle = function getButtonStyle(size, iconOnly) {
|
|
|
26
26
|
case SmartLinkSize.Small:
|
|
27
27
|
return css({
|
|
28
28
|
fontSize: '0.75rem',
|
|
29
|
-
fontWeight: 500,
|
|
29
|
+
fontWeight: "var(--ds-font-weight-medium, 500)",
|
|
30
30
|
lineHeight: '1rem',
|
|
31
31
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
32
32
|
'button, button:hover, button:focus, button:active': [{
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
2
2
|
import _createClass from "@babel/runtime/helpers/createClass";
|
|
3
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
4
3
|
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
5
4
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
6
|
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
|
7
7
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
8
8
|
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
9
|
-
function
|
|
9
|
+
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
10
10
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
11
11
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
12
12
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
@@ -89,17 +89,16 @@ export var renderWithDi = function renderWithDi(node) {
|
|
|
89
89
|
}));
|
|
90
90
|
};
|
|
91
91
|
export var createGenericComponent = function createGenericComponent(displayName) {
|
|
92
|
-
var
|
|
92
|
+
var _Class;
|
|
93
93
|
var renderChildren = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
|
94
94
|
var childrenParams = arguments.length > 2 ? arguments[2] : undefined;
|
|
95
|
-
return
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
_classCallCheck(this, _class);
|
|
100
|
-
return _super.apply(this, arguments);
|
|
95
|
+
return _Class = /*#__PURE__*/function (_Component) {
|
|
96
|
+
function _Class() {
|
|
97
|
+
_classCallCheck(this, _Class);
|
|
98
|
+
return _callSuper(this, _Class, arguments);
|
|
101
99
|
}
|
|
102
|
-
|
|
100
|
+
_inherits(_Class, _Component);
|
|
101
|
+
return _createClass(_Class, [{
|
|
103
102
|
key: "render",
|
|
104
103
|
value: function render() {
|
|
105
104
|
if (renderChildren && typeof this.props.children === 'function') {
|
|
@@ -114,6 +113,5 @@ export var createGenericComponent = function createGenericComponent(displayName)
|
|
|
114
113
|
return null;
|
|
115
114
|
}
|
|
116
115
|
}]);
|
|
117
|
-
|
|
118
|
-
}(Component), _defineProperty(_class, "displayName", displayName), _class;
|
|
116
|
+
}(Component), _defineProperty(_Class, "displayName", displayName), _Class;
|
|
119
117
|
};
|
|
@@ -17,7 +17,7 @@ import ElementGroup from './element-group';
|
|
|
17
17
|
|
|
18
18
|
// Determine whether the element can be display as inline/block.
|
|
19
19
|
|
|
20
|
-
export var ElementDisplaySchema = (_ElementDisplaySchema = {}, _defineProperty(_ElementDisplaySchema, ElementName.AssignedTo, ['inline']),
|
|
20
|
+
export var ElementDisplaySchema = (_ElementDisplaySchema = {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_ElementDisplaySchema, ElementName.AssignedTo, ['inline']), ElementName.AssignedToGroup, ['inline']), ElementName.AttachmentCount, ['inline']), ElementName.AuthorGroup, ['inline']), ElementName.ChecklistProgress, ['inline']), ElementName.CollaboratorGroup, ['inline']), ElementName.CommentCount, ['inline']), ElementName.CreatedBy, ['inline']), ElementName.CreatedOn, ['inline']), ElementName.DueOn, ['inline']), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_ElementDisplaySchema, ElementName.LatestCommit, ['inline']), ElementName.LinkIcon, ['inline']), ElementName.Location, ['inline']), ElementName.ModifiedBy, ['inline']), ElementName.ModifiedOn, ['inline']), ElementName.OwnedBy, ['inline']), ElementName.OwnedByGroup, ['inline']), ElementName.Preview, ['block']), ElementName.Priority, ['inline']), ElementName.ProgrammingLanguage, ['inline']), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_ElementDisplaySchema, ElementName.Provider, ['inline']), ElementName.ReactCount, ['inline']), ElementName.ReadTime, ['inline']), ElementName.Snippet, ['block']), ElementName.SourceBranch, ['inline']), ElementName.SentOn, ['inline']), ElementName.State, ['inline']), ElementName.SubscriberCount, ['inline']), ElementName.SubTasksProgress, ['inline']), ElementName.StoryPoints, ['inline']), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_ElementDisplaySchema, ElementName.TargetBranch, ['inline']), ElementName.Title, ['inline']), ElementName.ViewCount, ['inline']), ElementName.VoteCount, ['inline']));
|
|
21
21
|
var getDirectionStyles = function getDirectionStyles(direction) {
|
|
22
22
|
switch (direction) {
|
|
23
23
|
case SmartLinkDirection.Vertical:
|
|
@@ -8,139 +8,139 @@ import { ConfluenceIcon, JiraIcon } from '@atlaskit/logo';
|
|
|
8
8
|
import { R400 } from '@atlaskit/theme/colors';
|
|
9
9
|
import { IconType } from '../../../../../constants';
|
|
10
10
|
// prettier-ignore
|
|
11
|
-
var importIconMapper = (_importIconMapper = {}, _defineProperty(_importIconMapper, IconType.Archive, function () {
|
|
11
|
+
var importIconMapper = (_importIconMapper = {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_importIconMapper, IconType.Archive, function () {
|
|
12
12
|
return import( /* webpackChunkName: "glyphArchive" */'@atlaskit/icon-file-type/glyph/archive/16');
|
|
13
|
-
}),
|
|
13
|
+
}), IconType.Audio, function () {
|
|
14
14
|
return import( /* webpackChunkName: "glyphAudio" */'@atlaskit/icon-file-type/glyph/audio/16');
|
|
15
|
-
}),
|
|
15
|
+
}), IconType.Code, function () {
|
|
16
16
|
return import( /* webpackChunkName: "glyphCode" */'@atlaskit/icon-file-type/glyph/source-code/16');
|
|
17
|
-
}),
|
|
17
|
+
}), IconType.Executable, function () {
|
|
18
18
|
return import( /* webpackChunkName: "glyphExecutable" */'@atlaskit/icon-file-type/glyph/executable/16');
|
|
19
|
-
}),
|
|
19
|
+
}), IconType.File, function () {
|
|
20
20
|
return import( /* webpackChunkName: "glyphFile" */'@atlaskit/icon-file-type/glyph/generic/16');
|
|
21
|
-
}),
|
|
21
|
+
}), IconType.Folder, function () {
|
|
22
22
|
return import( /* webpackChunkName: "glyphFolder" */'@atlaskit/icon-file-type/glyph/folder/16');
|
|
23
|
-
}),
|
|
23
|
+
}), IconType.Generic, function () {
|
|
24
24
|
return import( /* webpackChunkName: "glyphGeneric" */'@atlaskit/icon-file-type/glyph/generic/16');
|
|
25
|
-
}),
|
|
25
|
+
}), IconType.GIF, function () {
|
|
26
26
|
return import( /* webpackChunkName: "glyphGIF" */'@atlaskit/icon-file-type/glyph/gif/16');
|
|
27
|
-
}),
|
|
27
|
+
}), IconType.GoogleDocs, function () {
|
|
28
28
|
return import( /* webpackChunkName: "glyphGoogleDocs" */'@atlaskit/icon-file-type/glyph/google-doc/16');
|
|
29
|
-
}),
|
|
29
|
+
}), IconType.GoogleForms, function () {
|
|
30
30
|
return import( /* webpackChunkName: "glyphGoogleForms" */'@atlaskit/icon-file-type/glyph/google-form/16');
|
|
31
|
-
}), _defineProperty(_importIconMapper, IconType.GoogleSheets, function () {
|
|
31
|
+
}), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_importIconMapper, IconType.GoogleSheets, function () {
|
|
32
32
|
return import( /* webpackChunkName: "glyphGoogleSheets" */'@atlaskit/icon-file-type/glyph/google-sheet/16');
|
|
33
|
-
}),
|
|
33
|
+
}), IconType.GoogleSlides, function () {
|
|
34
34
|
return import( /* webpackChunkName: "glyphGoogleSlides" */'@atlaskit/icon-file-type/glyph/google-slide/16');
|
|
35
|
-
}),
|
|
35
|
+
}), IconType.Image, function () {
|
|
36
36
|
return import( /* webpackChunkName: "glyphImage" */'@atlaskit/icon-file-type/glyph/image/16');
|
|
37
|
-
}),
|
|
37
|
+
}), IconType.MSExcel, function () {
|
|
38
38
|
return import( /* webpackChunkName: "glyphMSExcel" */'@atlaskit/icon-file-type/glyph/excel-spreadsheet/16');
|
|
39
|
-
}),
|
|
39
|
+
}), IconType.MSPowerpoint, function () {
|
|
40
40
|
return import( /* webpackChunkName: "glyphMSPowerpoint" */'@atlaskit/icon-file-type/glyph/powerpoint-presentation/16');
|
|
41
|
-
}),
|
|
41
|
+
}), IconType.MSWord, function () {
|
|
42
42
|
return import( /* webpackChunkName: "glyphMSWord" */'@atlaskit/icon-file-type/glyph/word-document/16');
|
|
43
|
-
}),
|
|
43
|
+
}), IconType.PDF, function () {
|
|
44
44
|
return import( /* webpackChunkName: "glyphPDF" */'@atlaskit/icon-file-type/glyph/pdf-document/16');
|
|
45
|
-
}),
|
|
45
|
+
}), IconType.Presentation, function () {
|
|
46
46
|
return import( /* webpackChunkName: "glyphPresentation" */'@atlaskit/icon-file-type/glyph/presentation/16');
|
|
47
|
-
}),
|
|
47
|
+
}), IconType.Sketch, function () {
|
|
48
48
|
return import( /* webpackChunkName: "glyphSketch" */'@atlaskit/icon-file-type/glyph/sketch/16');
|
|
49
|
-
}),
|
|
49
|
+
}), IconType.Spreadsheet, function () {
|
|
50
50
|
return import( /* webpackChunkName: "glyphSpreadsheet" */'@atlaskit/icon-file-type/glyph/spreadsheet/16');
|
|
51
|
-
}), _defineProperty(_importIconMapper, IconType.Template, function () {
|
|
51
|
+
}), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_importIconMapper, IconType.Template, function () {
|
|
52
52
|
return import( /* webpackChunkName: "glyphTemplate" */'@atlaskit/icon/glyph/document-filled');
|
|
53
|
-
}),
|
|
53
|
+
}), IconType.Video, function () {
|
|
54
54
|
return import( /* webpackChunkName: "glyphVideo" */'@atlaskit/icon-file-type/glyph/video/16');
|
|
55
|
-
}),
|
|
55
|
+
}), IconType.Branch, function () {
|
|
56
56
|
return import( /* webpackChunkName: "glyphBranch" */'@atlaskit/icon-object/glyph/branch/16');
|
|
57
|
-
}),
|
|
57
|
+
}), IconType.Commit, function () {
|
|
58
58
|
return import( /* webpackChunkName: "glyphCommit" */'@atlaskit/icon-object/glyph/commit/16');
|
|
59
|
-
}),
|
|
59
|
+
}), IconType.Project, function () {
|
|
60
60
|
return import( /* webpackChunkName: "glyphProject" */'@atlaskit/icon/glyph/people-group');
|
|
61
|
-
}),
|
|
61
|
+
}), IconType.PullRequest, function () {
|
|
62
62
|
return import( /* webpackChunkName: "glyphPullRequest" */'@atlaskit/icon-object/glyph/pull-request/16');
|
|
63
|
-
}),
|
|
63
|
+
}), IconType.Repo, function () {
|
|
64
64
|
return import( /* webpackChunkName: "glyphRepo" */'@atlaskit/icon-object/glyph/code/16');
|
|
65
|
-
}),
|
|
65
|
+
}), IconType.Bug, function () {
|
|
66
66
|
return import( /* webpackChunkName: "glyphBug" */'@atlaskit/icon-object/glyph/bug/16');
|
|
67
|
-
}),
|
|
67
|
+
}), IconType.Change, function () {
|
|
68
68
|
return import( /* webpackChunkName: "glyphChange" */'@atlaskit/icon-object/glyph/changes/16');
|
|
69
|
-
}),
|
|
69
|
+
}), IconType.Epic, function () {
|
|
70
70
|
return import( /* webpackChunkName: "glyphEpic" */'@atlaskit/icon-object/glyph/epic/16');
|
|
71
|
-
}), _defineProperty(_importIconMapper, IconType.Incident, function () {
|
|
71
|
+
}), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_importIconMapper, IconType.Incident, function () {
|
|
72
72
|
return import( /* webpackChunkName: "glyphIncident" */'@atlaskit/icon-object/glyph/incident/16');
|
|
73
|
-
}),
|
|
73
|
+
}), IconType.Problem, function () {
|
|
74
74
|
return import( /* webpackChunkName: "glyphProblem" */'@atlaskit/icon-object/glyph/problem/16');
|
|
75
|
-
}),
|
|
75
|
+
}), IconType.ServiceRequest, function () {
|
|
76
76
|
return import( /* webpackChunkName: "glyphServiceRequest" */'@atlaskit/icon-object/glyph/issue/16');
|
|
77
|
-
}),
|
|
77
|
+
}), IconType.Story, function () {
|
|
78
78
|
return import( /* webpackChunkName: "glyphStory" */'@atlaskit/icon-object/glyph/story/16');
|
|
79
|
-
}),
|
|
79
|
+
}), IconType.SubTask, function () {
|
|
80
80
|
return import( /* webpackChunkName: "glyphSubTask" */'@atlaskit/icon-object/glyph/subtask/16');
|
|
81
|
-
}),
|
|
81
|
+
}), IconType.Task, function () {
|
|
82
82
|
return import( /* webpackChunkName: "glyphTask" */'@atlaskit/icon-object/glyph/task/16');
|
|
83
|
-
}),
|
|
83
|
+
}), IconType.Confluence, function () {
|
|
84
84
|
return import( /* webpackChunkName: "glyphConfluence" */'@atlaskit/logo/confluence-icon').then(function (_ref) {
|
|
85
85
|
var ConfluenceIcon = _ref.ConfluenceIcon;
|
|
86
86
|
return {
|
|
87
87
|
default: ConfluenceIcon
|
|
88
88
|
};
|
|
89
89
|
});
|
|
90
|
-
}),
|
|
90
|
+
}), IconType.Jira, function () {
|
|
91
91
|
return import( /* webpackChunkName: "glyphJira" */'@atlaskit/logo/jira-icon').then(function (_ref2) {
|
|
92
92
|
var JiraIcon = _ref2.JiraIcon;
|
|
93
93
|
return {
|
|
94
94
|
default: JiraIcon
|
|
95
95
|
};
|
|
96
96
|
});
|
|
97
|
-
}),
|
|
97
|
+
}), IconType.Default, function () {
|
|
98
98
|
return import( /* webpackChunkName: "glyphDefault" */'@atlaskit/icon/glyph/link');
|
|
99
|
-
}),
|
|
99
|
+
}), IconType.Error, function () {
|
|
100
100
|
return import( /* webpackChunkName: "glyphError" */'@atlaskit/icon/glyph/error');
|
|
101
|
-
}), _defineProperty(_importIconMapper, IconType.Forbidden, function () {
|
|
101
|
+
}), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_importIconMapper, IconType.Forbidden, function () {
|
|
102
102
|
return import( /* webpackChunkName: "glyphForbidden" */'@atlaskit/icon/glyph/lock-filled');
|
|
103
|
-
}),
|
|
103
|
+
}), IconType.Attachment, function () {
|
|
104
104
|
return import( /* webpackChunkName: "glyphAttachment" */'@atlaskit/icon/glyph/attachment');
|
|
105
|
-
}),
|
|
105
|
+
}), IconType.CheckItem, function () {
|
|
106
106
|
return import( /* webpackChunkName: "glyphAttachment" */'@atlaskit/icon/glyph/task');
|
|
107
|
-
}),
|
|
107
|
+
}), IconType.Comment, function () {
|
|
108
108
|
return import( /* webpackChunkName: "glyphComment" */'@atlaskit/icon/glyph/comment');
|
|
109
|
-
}),
|
|
109
|
+
}), IconType.View, function () {
|
|
110
110
|
return import( /* webpackChunkName: "glyphComment" */'@atlaskit/icon/glyph/watch');
|
|
111
|
-
}),
|
|
111
|
+
}), IconType.React, function () {
|
|
112
112
|
return import( /* webpackChunkName: "glyphComment" */'@atlaskit/icon/glyph/like');
|
|
113
|
-
}),
|
|
113
|
+
}), IconType.Vote, function () {
|
|
114
114
|
return import( /* webpackChunkName: "glyphComment" */'@atlaskit/icon/glyph/arrow-up');
|
|
115
|
-
}),
|
|
115
|
+
}), IconType.PriorityBlocker, function () {
|
|
116
116
|
return import( /* webpackChunkName: "glyphBlocker" */'@atlaskit/icon-priority/glyph/priority-blocker');
|
|
117
|
-
}),
|
|
117
|
+
}), IconType.PriorityCritical, function () {
|
|
118
118
|
return import( /* webpackChunkName: "glyphCritical" */'@atlaskit/icon-priority/glyph/priority-critical');
|
|
119
|
-
}),
|
|
119
|
+
}), IconType.PriorityHigh, function () {
|
|
120
120
|
return import( /* webpackChunkName: "glyphHigh" */'@atlaskit/icon-priority/glyph/priority-high');
|
|
121
|
-
}), _defineProperty(_importIconMapper, IconType.PriorityHighest, function () {
|
|
121
|
+
}), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_importIconMapper, IconType.PriorityHighest, function () {
|
|
122
122
|
return import( /* webpackChunkName: "glyphHighest" */'@atlaskit/icon-priority/glyph/priority-highest');
|
|
123
|
-
}),
|
|
123
|
+
}), IconType.PriorityLow, function () {
|
|
124
124
|
return import( /* webpackChunkName: "glyphLow" */'@atlaskit/icon-priority/glyph/priority-low');
|
|
125
|
-
}),
|
|
125
|
+
}), IconType.PriorityLowest, function () {
|
|
126
126
|
return import( /* webpackChunkName: "glyphLowest" */'@atlaskit/icon-priority/glyph/priority-lowest');
|
|
127
|
-
}),
|
|
127
|
+
}), IconType.PriorityMajor, function () {
|
|
128
128
|
return import( /* webpackChunkName: "glyphMajor" */'@atlaskit/icon-priority/glyph/priority-major');
|
|
129
|
-
}),
|
|
129
|
+
}), IconType.PriorityMedium, function () {
|
|
130
130
|
return import( /* webpackChunkName: "glyphMedium" */'@atlaskit/icon-priority/glyph/priority-medium');
|
|
131
|
-
}),
|
|
131
|
+
}), IconType.PriorityMinor, function () {
|
|
132
132
|
return import( /* webpackChunkName: "glyphMinor" */'@atlaskit/icon-priority/glyph/priority-minor');
|
|
133
|
-
}),
|
|
133
|
+
}), IconType.PriorityTrivial, function () {
|
|
134
134
|
return import( /* webpackChunkName: "glyphTrivial" */'@atlaskit/icon-priority/glyph/priority-trivial');
|
|
135
|
-
}),
|
|
135
|
+
}), IconType.PriorityUndefined, function () {
|
|
136
136
|
return import( /* webpackChunkName: "glyphUndefined" */'@atlaskit/icon/glyph/question');
|
|
137
|
-
}),
|
|
137
|
+
}), IconType.ProgrammingLanguage, function () {
|
|
138
138
|
return import( /* webpackChunkName: "glyphProgrammingLanguage" */'@atlaskit/icon/glyph/code');
|
|
139
|
-
}),
|
|
139
|
+
}), IconType.Subscriber, function () {
|
|
140
140
|
return import( /* webpackChunkName: "glyphSubscriber" */'@atlaskit/icon/glyph/people');
|
|
141
141
|
}), _defineProperty(_importIconMapper, IconType.SubTasksProgress, function () {
|
|
142
142
|
return import( /* webpackChunkName: "glyphSubtaskProgress" */'@atlaskit/icon/glyph/subtask');
|
|
143
|
-
})
|
|
143
|
+
}));
|
|
144
144
|
var getIconImportFn = function getIconImportFn(icon) {
|
|
145
145
|
return importIconMapper[icon];
|
|
146
146
|
};
|
|
@@ -29,7 +29,7 @@ var labelStyles = css({
|
|
|
29
29
|
paddingLeft: "var(--ds-space-025, 0.125rem)",
|
|
30
30
|
verticalAlign: 'middle'
|
|
31
31
|
});
|
|
32
|
-
var messageMapper = (_messageMapper = {}, _defineProperty(_messageMapper, IconType.PriorityBlocker, messages.priority_blocker),
|
|
32
|
+
var messageMapper = (_messageMapper = {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_messageMapper, IconType.PriorityBlocker, messages.priority_blocker), IconType.PriorityCritical, messages.priority_critical), IconType.PriorityHigh, messages.priority_high), IconType.PriorityHighest, messages.priority_highest), IconType.PriorityLow, messages.priority_low), IconType.PriorityLowest, messages.priority_lowest), IconType.PriorityMajor, messages.priority_major), IconType.PriorityMedium, messages.priority_medium), IconType.PriorityMinor, messages.priority_minor), IconType.PriorityTrivial, messages.priority_trivial), _defineProperty(_messageMapper, IconType.PriorityUndefined, messages.priority_undefined));
|
|
33
33
|
var getFormattedMessageFromIcon = function getFormattedMessageFromIcon(icon) {
|
|
34
34
|
if (icon) {
|
|
35
35
|
var descriptor = messageMapper[icon];
|