@atlaskit/smart-card 34.10.4 → 34.10.6
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 +15 -0
- package/dist/cjs/common/ui/icons/live-document-icon.js +12 -0
- package/dist/cjs/common/ui/icons/utils.js +1 -1
- package/dist/cjs/extractors/common/icon/extractIconFromDocument.js +5 -1
- package/dist/cjs/utils/analytics/analytics.js +1 -1
- package/dist/cjs/utils/flexible.js +6 -3
- package/dist/cjs/utils/index.js +19 -24
- package/dist/cjs/view/FlexibleCard/components/common/atlaskit-icon/index.js +23 -25
- package/dist/cjs/view/FlexibleCard/components/container/index.js +81 -44
- package/dist/cjs/view/LinkUrl/index.js +1 -1
- package/dist/es2019/common/ui/icons/live-document-icon.js +5 -0
- package/dist/es2019/common/ui/icons/utils.js +1 -1
- package/dist/es2019/extractors/common/icon/extractIconFromDocument.js +5 -1
- package/dist/es2019/utils/analytics/analytics.js +1 -1
- package/dist/es2019/utils/flexible.js +5 -2
- package/dist/es2019/utils/index.js +1 -5
- package/dist/es2019/view/FlexibleCard/components/common/atlaskit-icon/index.js +7 -6
- package/dist/es2019/view/FlexibleCard/components/container/index.js +59 -20
- package/dist/es2019/view/LinkUrl/index.js +1 -1
- package/dist/esm/common/ui/icons/live-document-icon.js +5 -0
- package/dist/esm/common/ui/icons/utils.js +1 -1
- package/dist/esm/extractors/common/icon/extractIconFromDocument.js +5 -1
- package/dist/esm/utils/analytics/analytics.js +1 -1
- package/dist/esm/utils/flexible.js +5 -2
- package/dist/esm/utils/index.js +19 -24
- package/dist/esm/view/FlexibleCard/components/common/atlaskit-icon/index.js +23 -23
- package/dist/esm/view/FlexibleCard/components/container/index.js +81 -43
- package/dist/esm/view/LinkUrl/index.js +1 -1
- package/dist/types/common/ui/icons/live-document-icon.d.ts +3 -0
- package/dist/types/common/ui/icons/utils.d.ts +1 -1
- package/dist/types/utils/flexible.d.ts +1 -0
- package/dist/types-ts4.5/common/ui/icons/live-document-icon.d.ts +3 -0
- package/dist/types-ts4.5/common/ui/icons/utils.d.ts +1 -1
- package/dist/types-ts4.5/utils/flexible.d.ts +1 -0
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,20 @@
|
|
|
1
1
|
# @atlaskit/smart-card
|
|
2
2
|
|
|
3
|
+
## 34.10.6
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 34.10.5
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#109069](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/109069)
|
|
14
|
+
[`94a79aaaf7581`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/94a79aaaf7581) -
|
|
15
|
+
Fix an issue where the ui props in FlexibleCard container was not passed down to its children when
|
|
16
|
+
compiled styles is used.
|
|
17
|
+
|
|
3
18
|
## 34.10.4
|
|
4
19
|
|
|
5
20
|
### Patch Changes
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.default = void 0;
|
|
8
|
+
var _pageLiveDoc = _interopRequireDefault(require("@atlaskit/icon-lab/core/page-live-doc"));
|
|
9
|
+
var _utils = require("./utils");
|
|
10
|
+
var LiveDocumentIconWithColor = (0, _utils.renderIconTile)(_pageLiveDoc.default, 'magentaBold');
|
|
11
|
+
LiveDocumentIconWithColor.displayName = 'LiveDocumentIconWithColor';
|
|
12
|
+
var _default = exports.default = LiveDocumentIconWithColor;
|
|
@@ -41,7 +41,7 @@ var renderIconTile = exports.renderIconTile = function renderIconTile(Icon, appe
|
|
|
41
41
|
icon: Icon,
|
|
42
42
|
size: transformSmartLinkSizeToIconTileSize(size)
|
|
43
43
|
}, props, {
|
|
44
|
-
LEGACY_fallbackComponent: /*#__PURE__*/_react.default.createElement(LegacyIcon, props)
|
|
44
|
+
LEGACY_fallbackComponent: LegacyIcon && /*#__PURE__*/_react.default.createElement(LegacyIcon, props)
|
|
45
45
|
}));
|
|
46
46
|
};
|
|
47
47
|
};
|
|
@@ -6,6 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.extractIconFromDocument = void 0;
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
var _icon = require("@atlaskit/icon");
|
|
9
10
|
var _ = _interopRequireDefault(require("@atlaskit/icon-file-type/glyph/document/16"));
|
|
10
11
|
var _2 = _interopRequireDefault(require("@atlaskit/icon-file-type/glyph/generic/16"));
|
|
11
12
|
var _3 = _interopRequireDefault(require("@atlaskit/icon-file-type/glyph/presentation/16"));
|
|
@@ -142,8 +143,11 @@ var documentTypeToIcon = function documentTypeToIcon(type, opts) {
|
|
|
142
143
|
var digitalDocumentToIcon = function digitalDocumentToIcon(opts) {
|
|
143
144
|
var _opts$provider;
|
|
144
145
|
if ((_opts$provider = opts.provider) !== null && _opts$provider !== void 0 && _opts$provider.id && (0, _linkExtractors.isConfluenceGenerator)(opts.provider.id)) {
|
|
145
|
-
return /*#__PURE__*/_react.default.createElement(
|
|
146
|
+
return /*#__PURE__*/_react.default.createElement(_icon.IconTile, {
|
|
147
|
+
icon: _pageLiveDoc.default,
|
|
146
148
|
label: "live-doc",
|
|
149
|
+
appearance: "magentaBold",
|
|
150
|
+
shape: "square",
|
|
147
151
|
testId: "live-doc-icon"
|
|
148
152
|
});
|
|
149
153
|
} else {
|
|
@@ -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: "34.10.
|
|
14
|
+
packageVersion: "34.10.6"
|
|
15
15
|
};
|
|
16
16
|
var TrackQuickActionType = exports.TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
17
17
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -5,7 +5,7 @@ var _typeof = require("@babel/runtime/helpers/typeof");
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports.isFlexibleUiTitleBlock = exports.isFlexibleUiPreviewBlock = exports.isFlexibleUiFooterBlock = exports.isFlexibleUiElement = exports.isFlexibleUiCard = exports.isFlexibleUiBlock = void 0;
|
|
8
|
+
exports.isStyleCacheProvider = exports.isFlexibleUiTitleBlock = exports.isFlexibleUiPreviewBlock = exports.isFlexibleUiFooterBlock = exports.isFlexibleUiElement = exports.isFlexibleUiCard = exports.isFlexibleUiBlock = void 0;
|
|
9
9
|
var _react = _interopRequireDefault(require("react"));
|
|
10
10
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
11
11
|
var _blocks = _interopRequireWildcard(require("../view/FlexibleCard/components/blocks"));
|
|
@@ -92,7 +92,6 @@ var _isFlexibleUiElement = exports.isFlexibleUiElement = function isFlexibleUiEl
|
|
|
92
92
|
return false;
|
|
93
93
|
};
|
|
94
94
|
var _isFlexibleUiTitleBlock = exports.isFlexibleUiTitleBlock = function isFlexibleUiTitleBlock(node) {
|
|
95
|
-
var _node$type3;
|
|
96
95
|
if (!(0, _platformFeatureFlags.fg)('bandicoots-compiled-migration-smartcard')) {
|
|
97
96
|
return /*#__PURE__*/_react.default.isValidElement(node) && node.type === _blocks.TitleBlock;
|
|
98
97
|
}
|
|
@@ -102,7 +101,7 @@ var _isFlexibleUiTitleBlock = exports.isFlexibleUiTitleBlock = function isFlexib
|
|
|
102
101
|
if (node.type === _blocks.TitleBlock) {
|
|
103
102
|
return true;
|
|
104
103
|
}
|
|
105
|
-
if (
|
|
104
|
+
if (isStyleCacheProvider(node)) {
|
|
106
105
|
// Component wrapped with compiled at runtime, check for children
|
|
107
106
|
var isChildrenValid = true;
|
|
108
107
|
_react.default.Children.map(node.props.children, function (child) {
|
|
@@ -122,6 +121,10 @@ var _isFlexibleUiTitleBlock = exports.isFlexibleUiTitleBlock = function isFlexib
|
|
|
122
121
|
}
|
|
123
122
|
return false;
|
|
124
123
|
};
|
|
124
|
+
var isStyleCacheProvider = exports.isStyleCacheProvider = function isStyleCacheProvider(node) {
|
|
125
|
+
var _node$type3;
|
|
126
|
+
return typeof node.type !== 'string' && ((_node$type3 = node.type) === null || _node$type3 === void 0 ? void 0 : _node$type3.name) === 'StyleCacheProvider' && node.props.children;
|
|
127
|
+
};
|
|
125
128
|
var _isFlexibleUiPreviewBlock = exports.isFlexibleUiPreviewBlock = function isFlexibleUiPreviewBlock(node) {
|
|
126
129
|
var _node$type4;
|
|
127
130
|
if (!(0, _platformFeatureFlags.fg)('bandicoots-compiled-migration-smartcard')) {
|
package/dist/cjs/utils/index.js
CHANGED
|
@@ -337,8 +337,8 @@ var typeToIcon = {
|
|
|
337
337
|
|
|
338
338
|
// prettier-ignore
|
|
339
339
|
var getLazyIcons = exports.getLazyIcons = function getLazyIcons() {
|
|
340
|
-
var
|
|
341
|
-
return
|
|
340
|
+
var _ref3;
|
|
341
|
+
return _ref3 = {}, (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_ref3, _constants.IconType.Document, {
|
|
342
342
|
default: function _default() {
|
|
343
343
|
return Promise.resolve().then(function () {
|
|
344
344
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_page-icon" */'../common/ui/icons/page-icon'));
|
|
@@ -398,7 +398,7 @@ var getLazyIcons = exports.getLazyIcons = function getLazyIcons() {
|
|
|
398
398
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_list-bullet-icon" */'../common/ui/icons/list-bullet-icon'));
|
|
399
399
|
});
|
|
400
400
|
}
|
|
401
|
-
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(
|
|
401
|
+
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_ref3, _constants.IconType.Video, {
|
|
402
402
|
default: function _default() {
|
|
403
403
|
return Promise.resolve().then(function () {
|
|
404
404
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_video-icon" */'../common/ui/icons/video-icon'));
|
|
@@ -483,7 +483,7 @@ var getLazyIcons = exports.getLazyIcons = function getLazyIcons() {
|
|
|
483
483
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_glyphGoogleForms" */'@atlaskit/icon-file-type/glyph/google-form/24'));
|
|
484
484
|
});
|
|
485
485
|
}
|
|
486
|
-
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(
|
|
486
|
+
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_ref3, _constants.IconType.GoogleSheets, {
|
|
487
487
|
default: function _default() {
|
|
488
488
|
return Promise.resolve().then(function () {
|
|
489
489
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_glyphGoogleSheets" */'@atlaskit/icon-file-type/glyph/google-sheet/16'));
|
|
@@ -593,7 +593,7 @@ var getLazyIcons = exports.getLazyIcons = function getLazyIcons() {
|
|
|
593
593
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_glyphPullRequest" */'@atlaskit/icon-object/glyph/pull-request/24'));
|
|
594
594
|
});
|
|
595
595
|
}
|
|
596
|
-
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(
|
|
596
|
+
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_ref3, _constants.IconType.Repo, {
|
|
597
597
|
default: function _default() {
|
|
598
598
|
return Promise.resolve().then(function () {
|
|
599
599
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_glyphRepo" */'@atlaskit/icon-object/glyph/code/16'));
|
|
@@ -703,23 +703,18 @@ var getLazyIcons = exports.getLazyIcons = function getLazyIcons() {
|
|
|
703
703
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_glyphTask" */'@atlaskit/icon-object/glyph/task/24'));
|
|
704
704
|
});
|
|
705
705
|
}
|
|
706
|
-
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(
|
|
706
|
+
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_ref3, _constants.IconType.LiveDocument, {
|
|
707
707
|
default: function _default() {
|
|
708
708
|
return Promise.resolve().then(function () {
|
|
709
|
-
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-
|
|
710
|
-
}).then(function (_ref) {
|
|
711
|
-
var LiveDocumentIcon = _ref.default;
|
|
712
|
-
return {
|
|
713
|
-
default: LiveDocumentIcon
|
|
714
|
-
};
|
|
709
|
+
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_live-document-icon" */'../common/ui/icons/live-document-icon'));
|
|
715
710
|
});
|
|
716
711
|
}
|
|
717
712
|
}), _constants.IconType.Confluence, {
|
|
718
713
|
default: function _default() {
|
|
719
714
|
return Promise.resolve().then(function () {
|
|
720
715
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_glyphConfluence" */'@atlaskit/logo/confluence-icon'));
|
|
721
|
-
}).then(function (
|
|
722
|
-
var ConfluenceIcon =
|
|
716
|
+
}).then(function (_ref) {
|
|
717
|
+
var ConfluenceIcon = _ref.ConfluenceIcon;
|
|
723
718
|
return {
|
|
724
719
|
default: ConfluenceIcon
|
|
725
720
|
};
|
|
@@ -729,8 +724,8 @@ var getLazyIcons = exports.getLazyIcons = function getLazyIcons() {
|
|
|
729
724
|
default: function _default() {
|
|
730
725
|
return Promise.resolve().then(function () {
|
|
731
726
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_glyphJira" */'@atlaskit/logo/jira-icon'));
|
|
732
|
-
}).then(function (
|
|
733
|
-
var JiraIcon =
|
|
727
|
+
}).then(function (_ref2) {
|
|
728
|
+
var JiraIcon = _ref2.JiraIcon;
|
|
734
729
|
return {
|
|
735
730
|
default: JiraIcon
|
|
736
731
|
};
|
|
@@ -778,7 +773,7 @@ var getLazyIcons = exports.getLazyIcons = function getLazyIcons() {
|
|
|
778
773
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_glyphBlocker" */'@atlaskit/icon-priority/glyph/priority-blocker'));
|
|
779
774
|
});
|
|
780
775
|
}
|
|
781
|
-
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(
|
|
776
|
+
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_ref3, _constants.IconType.PriorityCritical, {
|
|
782
777
|
default: function _default() {
|
|
783
778
|
return Promise.resolve().then(function () {
|
|
784
779
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_glyphCritical" */'@atlaskit/icon-priority/glyph/priority-critical'));
|
|
@@ -838,7 +833,7 @@ var getLazyIcons = exports.getLazyIcons = function getLazyIcons() {
|
|
|
838
833
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_glyphUndefined" */'@atlaskit/icon/core/migration/question-circle--question'));
|
|
839
834
|
});
|
|
840
835
|
}
|
|
841
|
-
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(
|
|
836
|
+
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_ref3, _constants.IconType.ProgrammingLanguage, {
|
|
842
837
|
default: function _default() {
|
|
843
838
|
return Promise.resolve().then(function () {
|
|
844
839
|
return _interopRequireWildcard(require( /* webpackChunkName: "@atlaskit-internal_glyphProgrammingLanguage" */'@atlaskit/icon/core/migration/angle-brackets--code'));
|
|
@@ -890,7 +885,7 @@ var sleep = exports.sleep = function sleep(ms) {
|
|
|
890
885
|
});
|
|
891
886
|
};
|
|
892
887
|
var _importWithRetry = exports.importWithRetry = /*#__PURE__*/function () {
|
|
893
|
-
var
|
|
888
|
+
var _ref4 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee(importFn) {
|
|
894
889
|
var retries,
|
|
895
890
|
interval,
|
|
896
891
|
_args = arguments;
|
|
@@ -924,11 +919,11 @@ var _importWithRetry = exports.importWithRetry = /*#__PURE__*/function () {
|
|
|
924
919
|
}, _callee, null, [[2, 8]]);
|
|
925
920
|
}));
|
|
926
921
|
return function importWithRetry(_x) {
|
|
927
|
-
return
|
|
922
|
+
return _ref4.apply(this, arguments);
|
|
928
923
|
};
|
|
929
924
|
}();
|
|
930
925
|
var downloadUrl = exports.downloadUrl = /*#__PURE__*/function () {
|
|
931
|
-
var
|
|
926
|
+
var _ref5 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee2(url) {
|
|
932
927
|
var isIE11, isSafari, iframeName, link, iframe;
|
|
933
928
|
return _regenerator.default.wrap(function _callee2$(_context2) {
|
|
934
929
|
while (1) switch (_context2.prev = _context2.next) {
|
|
@@ -964,11 +959,11 @@ var downloadUrl = exports.downloadUrl = /*#__PURE__*/function () {
|
|
|
964
959
|
}, _callee2);
|
|
965
960
|
}));
|
|
966
961
|
return function downloadUrl(_x2) {
|
|
967
|
-
return
|
|
962
|
+
return _ref5.apply(this, arguments);
|
|
968
963
|
};
|
|
969
964
|
}();
|
|
970
965
|
var openUrl = exports.openUrl = /*#__PURE__*/function () {
|
|
971
|
-
var
|
|
966
|
+
var _ref6 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee3(url) {
|
|
972
967
|
return _regenerator.default.wrap(function _callee3$(_context3) {
|
|
973
968
|
while (1) switch (_context3.prev = _context3.next) {
|
|
974
969
|
case 0:
|
|
@@ -986,7 +981,7 @@ var openUrl = exports.openUrl = /*#__PURE__*/function () {
|
|
|
986
981
|
}, _callee3);
|
|
987
982
|
}));
|
|
988
983
|
return function openUrl(_x3) {
|
|
989
|
-
return
|
|
984
|
+
return _ref6.apply(this, arguments);
|
|
990
985
|
};
|
|
991
986
|
}();
|
|
992
987
|
|
|
@@ -16,6 +16,7 @@ var _logo = require("@atlaskit/logo");
|
|
|
16
16
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
17
17
|
var _colors = require("@atlaskit/theme/colors");
|
|
18
18
|
var _blogIcon = _interopRequireDefault(require("../../../../../common/ui/icons/blog-icon"));
|
|
19
|
+
var _liveDocumentIcon = _interopRequireDefault(require("../../../../../common/ui/icons/live-document-icon"));
|
|
19
20
|
var _pageIcon = _interopRequireDefault(require("../../../../../common/ui/icons/page-icon"));
|
|
20
21
|
var _constants = require("../../../../../constants");
|
|
21
22
|
var _utils = require("../../../../../utils");
|
|
@@ -167,20 +168,11 @@ var importIconMapperOld = (_importIconMapperOld = {}, (0, _defineProperty2.defau
|
|
|
167
168
|
return Promise.resolve().then(function () {
|
|
168
169
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphTask" */'@atlaskit/icon-object/glyph/task/16'));
|
|
169
170
|
});
|
|
170
|
-
}), _constants.IconType.LiveDocument, function () {
|
|
171
|
-
return Promise.resolve().then(function () {
|
|
172
|
-
return _interopRequireWildcard(require( /* webpackChunkName: "glyphConfluenceLiveDocument" */'@atlaskit/icon-lab/core/page-live-doc'));
|
|
173
|
-
}).then(function (_ref) {
|
|
174
|
-
var LiveDocumentIcon = _ref.default;
|
|
175
|
-
return {
|
|
176
|
-
default: LiveDocumentIcon
|
|
177
|
-
};
|
|
178
|
-
});
|
|
179
171
|
}), _constants.IconType.Confluence, function () {
|
|
180
172
|
return Promise.resolve().then(function () {
|
|
181
173
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphConfluence" */'@atlaskit/logo/confluence-icon'));
|
|
182
|
-
}).then(function (
|
|
183
|
-
var ConfluenceIcon =
|
|
174
|
+
}).then(function (_ref) {
|
|
175
|
+
var ConfluenceIcon = _ref.ConfluenceIcon;
|
|
184
176
|
return {
|
|
185
177
|
default: ConfluenceIcon
|
|
186
178
|
};
|
|
@@ -188,8 +180,8 @@ var importIconMapperOld = (_importIconMapperOld = {}, (0, _defineProperty2.defau
|
|
|
188
180
|
}), _constants.IconType.Jira, function () {
|
|
189
181
|
return Promise.resolve().then(function () {
|
|
190
182
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphJira" */'@atlaskit/logo/jira-icon'));
|
|
191
|
-
}).then(function (
|
|
192
|
-
var JiraIcon =
|
|
183
|
+
}).then(function (_ref2) {
|
|
184
|
+
var JiraIcon = _ref2.JiraIcon;
|
|
193
185
|
return {
|
|
194
186
|
default: JiraIcon
|
|
195
187
|
};
|
|
@@ -198,11 +190,11 @@ var importIconMapperOld = (_importIconMapperOld = {}, (0, _defineProperty2.defau
|
|
|
198
190
|
return Promise.resolve().then(function () {
|
|
199
191
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphDefault" */'@atlaskit/icon/glyph/link'));
|
|
200
192
|
});
|
|
201
|
-
}),
|
|
193
|
+
}), _constants.IconType.Error, function () {
|
|
202
194
|
return Promise.resolve().then(function () {
|
|
203
195
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphError" */'@atlaskit/icon/glyph/error'));
|
|
204
196
|
});
|
|
205
|
-
}), _constants.IconType.Forbidden, function () {
|
|
197
|
+
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_importIconMapperOld, _constants.IconType.Forbidden, function () {
|
|
206
198
|
return Promise.resolve().then(function () {
|
|
207
199
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphForbidden" */'@atlaskit/icon/glyph/lock-filled'));
|
|
208
200
|
});
|
|
@@ -238,11 +230,11 @@ var importIconMapperOld = (_importIconMapperOld = {}, (0, _defineProperty2.defau
|
|
|
238
230
|
return Promise.resolve().then(function () {
|
|
239
231
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphCritical" */'@atlaskit/icon-priority/glyph/priority-critical'));
|
|
240
232
|
});
|
|
241
|
-
}),
|
|
233
|
+
}), _constants.IconType.PriorityHigh, function () {
|
|
242
234
|
return Promise.resolve().then(function () {
|
|
243
235
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphHigh" */'@atlaskit/icon-priority/glyph/priority-high'));
|
|
244
236
|
});
|
|
245
|
-
}), _constants.IconType.PriorityHighest, function () {
|
|
237
|
+
}), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_importIconMapperOld, _constants.IconType.PriorityHighest, function () {
|
|
246
238
|
return Promise.resolve().then(function () {
|
|
247
239
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphHighest" */'@atlaskit/icon-priority/glyph/priority-highest'));
|
|
248
240
|
});
|
|
@@ -278,11 +270,11 @@ var importIconMapperOld = (_importIconMapperOld = {}, (0, _defineProperty2.defau
|
|
|
278
270
|
return Promise.resolve().then(function () {
|
|
279
271
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphProgrammingLanguage" */'@atlaskit/icon/glyph/code'));
|
|
280
272
|
});
|
|
281
|
-
}),
|
|
273
|
+
}), _constants.IconType.Subscriber, function () {
|
|
282
274
|
return Promise.resolve().then(function () {
|
|
283
275
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphSubscriber" */'@atlaskit/icon/glyph/people'));
|
|
284
276
|
});
|
|
285
|
-
}), _constants.IconType.SubTasksProgress, function () {
|
|
277
|
+
}), (0, _defineProperty2.default)(_importIconMapperOld, _constants.IconType.SubTasksProgress, function () {
|
|
286
278
|
return Promise.resolve().then(function () {
|
|
287
279
|
return _interopRequireWildcard(require( /* webpackChunkName: "glyphSubtaskProgress" */'@atlaskit/icon/glyph/subtask'));
|
|
288
280
|
});
|
|
@@ -309,12 +301,12 @@ var importIcon = function importIcon(importFn) {
|
|
|
309
301
|
}
|
|
310
302
|
}); // Because we're using dynamic loading here, TS will not be able to infer the type.
|
|
311
303
|
};
|
|
312
|
-
var AtlaskitIcon = function AtlaskitIcon(
|
|
313
|
-
var icon =
|
|
314
|
-
label =
|
|
315
|
-
testId =
|
|
316
|
-
|
|
317
|
-
size =
|
|
304
|
+
var AtlaskitIcon = function AtlaskitIcon(_ref3) {
|
|
305
|
+
var icon = _ref3.icon,
|
|
306
|
+
label = _ref3.label,
|
|
307
|
+
testId = _ref3.testId,
|
|
308
|
+
_ref3$size = _ref3.size,
|
|
309
|
+
size = _ref3$size === void 0 ? _constants.SmartLinkSize.Medium : _ref3$size;
|
|
318
310
|
var DocumentIcon = (0, _platformFeatureFlags.fg)('platform-smart-card-icon-migration') ? _pageIcon.default : _.default;
|
|
319
311
|
var BlogIcon = (0, _platformFeatureFlags.fg)('platform-smart-card-icon-migration') ? _blogIcon.default : _2.default;
|
|
320
312
|
|
|
@@ -334,6 +326,12 @@ var AtlaskitIcon = function AtlaskitIcon(_ref4) {
|
|
|
334
326
|
}, (0, _platformFeatureFlags.fg)('platform-smart-card-icon-migration') && {
|
|
335
327
|
size: size
|
|
336
328
|
}));
|
|
329
|
+
case _constants.IconType.LiveDocument:
|
|
330
|
+
return /*#__PURE__*/_react.default.createElement(_liveDocumentIcon.default, {
|
|
331
|
+
label: label || 'live-doc',
|
|
332
|
+
testId: testId,
|
|
333
|
+
size: size
|
|
334
|
+
});
|
|
337
335
|
}
|
|
338
336
|
var importFn = getIconImportFn(icon, size);
|
|
339
337
|
if (!importFn) {
|
|
@@ -1,6 +1,4 @@
|
|
|
1
1
|
/* index.tsx generated by @compiled/babel-plugin v0.36.0 */
|
|
2
|
-
/* eslint-disable @atlaskit/design-system/consistent-css-prop-usage */
|
|
3
|
-
/* eslint-disable @atlaskit/ui-styling-standard/no-unsafe-values */
|
|
4
2
|
"use strict";
|
|
5
3
|
|
|
6
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
@@ -17,6 +15,8 @@ Object.defineProperty(exports, "getContainerStyles", {
|
|
|
17
15
|
});
|
|
18
16
|
require("./index.compiled.css");
|
|
19
17
|
var _runtime = require("@compiled/react/runtime");
|
|
18
|
+
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
19
|
+
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
20
20
|
var _react = _interopRequireWildcard(require("react"));
|
|
21
21
|
var _reactMagneticDi = require("react-magnetic-di");
|
|
22
22
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
@@ -28,11 +28,16 @@ var _flexible = require("../../../../utils/flexible");
|
|
|
28
28
|
var _hoverCardControl = _interopRequireDefault(require("./hover-card-control"));
|
|
29
29
|
var _indexOld = _interopRequireWildcard(require("./indexOld"));
|
|
30
30
|
var _layeredLink = _interopRequireDefault(require("./layered-link"));
|
|
31
|
-
|
|
32
|
-
|
|
31
|
+
var _excluded = ["containerSize"];
|
|
32
|
+
/* eslint-disable @atlaskit/design-system/consistent-css-prop-usage */
|
|
33
|
+
/* eslint-disable @atlaskit/ui-styling-standard/no-unsafe-values */
|
|
33
34
|
/**
|
|
34
35
|
* Eventually these exports should be removed on FF clean up bandicoots-compiled-migration-smartcard
|
|
35
36
|
*/
|
|
37
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
38
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
39
|
+
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; }
|
|
40
|
+
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) { (0, _defineProperty2.default)(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; }
|
|
36
41
|
var getChildrenOptions = exports.getChildrenOptions = function getChildrenOptions(children, context) {
|
|
37
42
|
var options = {};
|
|
38
43
|
if ((0, _utils.isFlexUiPreviewPresent)(context)) {
|
|
@@ -55,18 +60,31 @@ var getChildrenOptions = exports.getChildrenOptions = function getChildrenOption
|
|
|
55
60
|
var renderChildren = function renderChildren(children, containerSize, containerTheme, status, retry, onClick) {
|
|
56
61
|
return _react.default.Children.map(children, function (child) {
|
|
57
62
|
if ( /*#__PURE__*/_react.default.isValidElement(child) && (0, _flexible.isFlexibleUiBlock)(child)) {
|
|
58
|
-
var blockSize = child.props.size;
|
|
59
|
-
var size = blockSize || containerSize;
|
|
60
63
|
if ((0, _flexible.isFlexibleUiTitleBlock)(child)) {
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
64
|
+
if ((0, _flexible.isStyleCacheProvider)(child)) {
|
|
65
|
+
return updateChildren(child, {
|
|
66
|
+
onClick: onClick,
|
|
67
|
+
retry: retry,
|
|
68
|
+
containerSize: containerSize,
|
|
69
|
+
status: status,
|
|
70
|
+
theme: containerTheme
|
|
71
|
+
});
|
|
72
|
+
} else {
|
|
73
|
+
var _blockSize = child.props.size;
|
|
74
|
+
var _size = _blockSize || containerSize;
|
|
75
|
+
return /*#__PURE__*/_react.default.cloneElement(child, {
|
|
76
|
+
// @ts-expect-error
|
|
77
|
+
onClick: onClick,
|
|
78
|
+
retry: retry,
|
|
79
|
+
size: _size,
|
|
80
|
+
status: status,
|
|
81
|
+
theme: containerTheme
|
|
82
|
+
});
|
|
83
|
+
}
|
|
69
84
|
}
|
|
85
|
+
var blockSize = child.props.size;
|
|
86
|
+
var size = blockSize || containerSize;
|
|
87
|
+
|
|
70
88
|
// @ts-expect-error
|
|
71
89
|
return /*#__PURE__*/_react.default.cloneElement(child, {
|
|
72
90
|
size: size,
|
|
@@ -75,6 +93,25 @@ var renderChildren = function renderChildren(children, containerSize, containerT
|
|
|
75
93
|
}
|
|
76
94
|
});
|
|
77
95
|
};
|
|
96
|
+
var updateChildren = function updateChildren(node, _ref) {
|
|
97
|
+
var containerSize = _ref.containerSize,
|
|
98
|
+
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
99
|
+
var updatedChildren = _react.default.Children.map(node.props.children, function (child) {
|
|
100
|
+
if ( /*#__PURE__*/_react.default.isValidElement(child) && (0, _flexible.isFlexibleUiTitleBlock)(child)) {
|
|
101
|
+
var _ref2 = child.props,
|
|
102
|
+
blockSize = _ref2.size;
|
|
103
|
+
var size = blockSize || containerSize;
|
|
104
|
+
return /*#__PURE__*/_react.default.cloneElement(child, _objectSpread(_objectSpread({}, props), {}, {
|
|
105
|
+
size: size
|
|
106
|
+
}));
|
|
107
|
+
} else {
|
|
108
|
+
return child;
|
|
109
|
+
}
|
|
110
|
+
});
|
|
111
|
+
return /*#__PURE__*/_react.default.cloneElement(node, {
|
|
112
|
+
children: updatedChildren
|
|
113
|
+
});
|
|
114
|
+
};
|
|
78
115
|
var getTitleBlockProps = function getTitleBlockProps(children) {
|
|
79
116
|
var block = _react.default.Children.toArray(children).find(function (child) {
|
|
80
117
|
return (0, _flexible.isFlexibleUiTitleBlock)(child);
|
|
@@ -84,13 +121,13 @@ var getTitleBlockProps = function getTitleBlockProps(children) {
|
|
|
84
121
|
}
|
|
85
122
|
};
|
|
86
123
|
var getLayeredLink = function getLayeredLink(testId, context, children, onClick) {
|
|
87
|
-
var
|
|
88
|
-
title =
|
|
89
|
-
|
|
90
|
-
url =
|
|
91
|
-
var
|
|
92
|
-
target =
|
|
93
|
-
text =
|
|
124
|
+
var _ref3 = context || {},
|
|
125
|
+
title = _ref3.title,
|
|
126
|
+
_ref3$url = _ref3.url,
|
|
127
|
+
url = _ref3$url === void 0 ? '' : _ref3$url;
|
|
128
|
+
var _ref4 = getTitleBlockProps(children) || {},
|
|
129
|
+
target = _ref4.anchorTarget,
|
|
130
|
+
text = _ref4.text;
|
|
94
131
|
return /*#__PURE__*/_react.default.createElement(_layeredLink.default, {
|
|
95
132
|
onClick: onClick,
|
|
96
133
|
target: target,
|
|
@@ -218,29 +255,29 @@ var previewOnRightStyleMap = {
|
|
|
218
255
|
* @internal
|
|
219
256
|
* @see Block
|
|
220
257
|
*/
|
|
221
|
-
var ContainerNew = function ContainerNew(
|
|
222
|
-
var children =
|
|
223
|
-
|
|
224
|
-
clickableContainer =
|
|
225
|
-
|
|
226
|
-
hideBackground =
|
|
227
|
-
|
|
228
|
-
hideElevation =
|
|
229
|
-
|
|
230
|
-
hidePadding =
|
|
231
|
-
onClick =
|
|
232
|
-
retry =
|
|
233
|
-
|
|
234
|
-
showHoverPreview =
|
|
235
|
-
hoverPreviewOptions =
|
|
236
|
-
actionOptions =
|
|
237
|
-
|
|
238
|
-
size =
|
|
239
|
-
status =
|
|
240
|
-
|
|
241
|
-
testId =
|
|
242
|
-
|
|
243
|
-
theme =
|
|
258
|
+
var ContainerNew = function ContainerNew(_ref5) {
|
|
259
|
+
var children = _ref5.children,
|
|
260
|
+
_ref5$clickableContai = _ref5.clickableContainer,
|
|
261
|
+
clickableContainer = _ref5$clickableContai === void 0 ? false : _ref5$clickableContai,
|
|
262
|
+
_ref5$hideBackground = _ref5.hideBackground,
|
|
263
|
+
hideBackground = _ref5$hideBackground === void 0 ? false : _ref5$hideBackground,
|
|
264
|
+
_ref5$hideElevation = _ref5.hideElevation,
|
|
265
|
+
hideElevation = _ref5$hideElevation === void 0 ? false : _ref5$hideElevation,
|
|
266
|
+
_ref5$hidePadding = _ref5.hidePadding,
|
|
267
|
+
hidePadding = _ref5$hidePadding === void 0 ? false : _ref5$hidePadding,
|
|
268
|
+
onClick = _ref5.onClick,
|
|
269
|
+
retry = _ref5.retry,
|
|
270
|
+
_ref5$showHoverPrevie = _ref5.showHoverPreview,
|
|
271
|
+
showHoverPreview = _ref5$showHoverPrevie === void 0 ? false : _ref5$showHoverPrevie,
|
|
272
|
+
hoverPreviewOptions = _ref5.hoverPreviewOptions,
|
|
273
|
+
actionOptions = _ref5.actionOptions,
|
|
274
|
+
_ref5$size = _ref5.size,
|
|
275
|
+
size = _ref5$size === void 0 ? _constants.SmartLinkSize.Medium : _ref5$size,
|
|
276
|
+
status = _ref5.status,
|
|
277
|
+
_ref5$testId = _ref5.testId,
|
|
278
|
+
testId = _ref5$testId === void 0 ? 'smart-links-container' : _ref5$testId,
|
|
279
|
+
_ref5$theme = _ref5.theme,
|
|
280
|
+
theme = _ref5$theme === void 0 ? _constants.SmartLinkTheme.Link : _ref5$theme;
|
|
244
281
|
var padding = hidePadding ? '0rem' : getPadding(size);
|
|
245
282
|
var gap = getGap(size);
|
|
246
283
|
var context = (0, _react.useContext)(_flexibleUiContext.FlexibleUiContext);
|
|
@@ -20,7 +20,7 @@ var _excluded = ["href", "children", "checkSafety", "onClick", "testId", "isLink
|
|
|
20
20
|
_excluded2 = ["isLinkSafe", "showSafetyWarningModal"];
|
|
21
21
|
var PACKAGE_DATA = {
|
|
22
22
|
packageName: "@atlaskit/smart-card",
|
|
23
|
-
packageVersion: "34.10.
|
|
23
|
+
packageVersion: "34.10.6",
|
|
24
24
|
componentName: 'linkUrl'
|
|
25
25
|
};
|
|
26
26
|
var Anchor = (0, _click.withLinkClickedEvent)('a');
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import LiveDocumentIcon from '@atlaskit/icon-lab/core/page-live-doc';
|
|
2
|
+
import { renderIconTile } from './utils';
|
|
3
|
+
const LiveDocumentIconWithColor = renderIconTile(LiveDocumentIcon, 'magentaBold');
|
|
4
|
+
LiveDocumentIconWithColor.displayName = 'LiveDocumentIconWithColor';
|
|
5
|
+
export default LiveDocumentIconWithColor;
|
|
@@ -33,7 +33,7 @@ export const renderIconTile = (Icon, appearance, LegacyIcon) => {
|
|
|
33
33
|
icon: Icon,
|
|
34
34
|
size: transformSmartLinkSizeToIconTileSize(size)
|
|
35
35
|
}, props, {
|
|
36
|
-
LEGACY_fallbackComponent: /*#__PURE__*/React.createElement(LegacyIcon, props)
|
|
36
|
+
LEGACY_fallbackComponent: LegacyIcon && /*#__PURE__*/React.createElement(LegacyIcon, props)
|
|
37
37
|
}));
|
|
38
38
|
};
|
|
39
39
|
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { IconTile } from '@atlaskit/icon';
|
|
2
3
|
import DocumentIconOld from '@atlaskit/icon-file-type/glyph/document/16';
|
|
3
4
|
import FileIconOld from '@atlaskit/icon-file-type/glyph/generic/16';
|
|
4
5
|
import PresentationIconOld from '@atlaskit/icon-file-type/glyph/presentation/16';
|
|
@@ -136,8 +137,11 @@ const documentTypeToIcon = (type, opts) => {
|
|
|
136
137
|
const digitalDocumentToIcon = opts => {
|
|
137
138
|
var _opts$provider;
|
|
138
139
|
if ((_opts$provider = opts.provider) !== null && _opts$provider !== void 0 && _opts$provider.id && isConfluenceGenerator(opts.provider.id)) {
|
|
139
|
-
return /*#__PURE__*/React.createElement(
|
|
140
|
+
return /*#__PURE__*/React.createElement(IconTile, {
|
|
141
|
+
icon: LiveDocumentIcon,
|
|
140
142
|
label: "live-doc",
|
|
143
|
+
appearance: "magentaBold",
|
|
144
|
+
shape: "square",
|
|
141
145
|
testId: "live-doc-icon"
|
|
142
146
|
});
|
|
143
147
|
} else {
|
|
@@ -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: "34.10.
|
|
5
|
+
packageVersion: "34.10.6"
|
|
6
6
|
};
|
|
7
7
|
export let TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
8
8
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -72,7 +72,6 @@ export const isFlexibleUiElement = node => {
|
|
|
72
72
|
return false;
|
|
73
73
|
};
|
|
74
74
|
export const isFlexibleUiTitleBlock = node => {
|
|
75
|
-
var _node$type3;
|
|
76
75
|
if (!fg('bandicoots-compiled-migration-smartcard')) {
|
|
77
76
|
return /*#__PURE__*/React.isValidElement(node) && node.type === TitleBlock;
|
|
78
77
|
}
|
|
@@ -82,7 +81,7 @@ export const isFlexibleUiTitleBlock = node => {
|
|
|
82
81
|
if (node.type === TitleBlock) {
|
|
83
82
|
return true;
|
|
84
83
|
}
|
|
85
|
-
if (
|
|
84
|
+
if (isStyleCacheProvider(node)) {
|
|
86
85
|
// Component wrapped with compiled at runtime, check for children
|
|
87
86
|
let isChildrenValid = true;
|
|
88
87
|
React.Children.map(node.props.children, child => {
|
|
@@ -102,6 +101,10 @@ export const isFlexibleUiTitleBlock = node => {
|
|
|
102
101
|
}
|
|
103
102
|
return false;
|
|
104
103
|
};
|
|
104
|
+
export const isStyleCacheProvider = node => {
|
|
105
|
+
var _node$type3;
|
|
106
|
+
return typeof node.type !== 'string' && ((_node$type3 = node.type) === null || _node$type3 === void 0 ? void 0 : _node$type3.name) === 'StyleCacheProvider' && node.props.children;
|
|
107
|
+
};
|
|
105
108
|
export const isFlexibleUiPreviewBlock = node => {
|
|
106
109
|
var _node$type4;
|
|
107
110
|
if (!fg('bandicoots-compiled-migration-smartcard')) {
|