@atlaskit/editor-core 228.1.8 → 228.1.10
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/composable-editor/editor-internal-compiled.js +1 -1
- package/dist/cjs/ui/Addon/ClickAreaBlock/clickAreaBlock-compiled.js +1 -1
- package/dist/cjs/ui/Appearance/Chromeless-compiled.js +1 -1
- package/dist/cjs/ui/Appearance/Comment/Comment-compiled.js +1 -1
- package/dist/cjs/ui/Appearance/Comment/FixedToolbar-compiled.js +1 -1
- package/dist/cjs/ui/Appearance/Comment/StickyToolbar-compiled.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/BeforeWrapper-compiled.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/CustomToolbarWrapper-compiled.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/FullPage-compiled.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/FullPageContentArea-compiled.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/FullPageToolbarNext.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/MainToolbar-compiled.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/MainToolbarWrapper-compiled.js +1 -1
- package/dist/cjs/ui/ChromeCollapsed/ChromeCollapsed-compiled.js +1 -1
- package/dist/cjs/ui/ContextPanel/index-compiled.js +1 -1
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer-compiled.js +1 -1
- package/dist/cjs/ui/PluginSlot/PluginSlot-compiled.js +1 -1
- package/dist/cjs/ui/Toolbar/ToolbarComponentsWrapper-compiled.js +1 -1
- package/dist/cjs/ui/Toolbar/ToolbarPortal.js +1 -1
- package/dist/cjs/ui/Toolbar/ToolbarSizeDetectorWrapper-compiled.js +1 -1
- package/dist/cjs/ui/WithFlash/withFlash-compiled.js +1 -1
- package/dist/cjs/ui/quick-insert/ExtensionQuickInsertIcon.js +15 -0
- package/dist/cjs/ui/quick-insert/ExtensionQuickInsertMenuItem.js +3 -0
- package/dist/cjs/ui/quick-insert/getExtensionQuickInsertPreviewImageUrls.js +31 -0
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/composable-editor/editor-internal-compiled.js +1 -1
- package/dist/es2019/ui/Addon/ClickAreaBlock/clickAreaBlock-compiled.js +1 -1
- package/dist/es2019/ui/Appearance/Chromeless-compiled.js +1 -1
- package/dist/es2019/ui/Appearance/Comment/Comment-compiled.js +1 -1
- package/dist/es2019/ui/Appearance/Comment/FixedToolbar-compiled.js +1 -1
- package/dist/es2019/ui/Appearance/Comment/StickyToolbar-compiled.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/BeforeWrapper-compiled.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/CustomToolbarWrapper-compiled.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/FullPage-compiled.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/FullPageContentArea-compiled.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/FullPageToolbarNext.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/MainToolbar-compiled.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/MainToolbarWrapper-compiled.js +1 -1
- package/dist/es2019/ui/ChromeCollapsed/ChromeCollapsed-compiled.js +1 -1
- package/dist/es2019/ui/ContextPanel/index-compiled.js +1 -1
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer-compiled.js +1 -1
- package/dist/es2019/ui/PluginSlot/PluginSlot-compiled.js +1 -1
- package/dist/es2019/ui/Toolbar/ToolbarComponentsWrapper-compiled.js +1 -1
- package/dist/es2019/ui/Toolbar/ToolbarPortal.js +1 -1
- package/dist/es2019/ui/Toolbar/ToolbarSizeDetectorWrapper-compiled.js +1 -1
- package/dist/es2019/ui/WithFlash/withFlash-compiled.js +1 -1
- package/dist/es2019/ui/quick-insert/ExtensionQuickInsertIcon.js +15 -0
- package/dist/es2019/ui/quick-insert/ExtensionQuickInsertMenuItem.js +3 -0
- package/dist/es2019/ui/quick-insert/getExtensionQuickInsertPreviewImageUrls.js +23 -0
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/composable-editor/editor-internal-compiled.js +1 -1
- package/dist/esm/ui/Addon/ClickAreaBlock/clickAreaBlock-compiled.js +1 -1
- package/dist/esm/ui/Appearance/Chromeless-compiled.js +1 -1
- package/dist/esm/ui/Appearance/Comment/Comment-compiled.js +1 -1
- package/dist/esm/ui/Appearance/Comment/FixedToolbar-compiled.js +1 -1
- package/dist/esm/ui/Appearance/Comment/StickyToolbar-compiled.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/BeforeWrapper-compiled.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/CustomToolbarWrapper-compiled.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/FullPage-compiled.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/FullPageContentArea-compiled.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/FullPageToolbarNext.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/MainToolbar-compiled.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/MainToolbarWrapper-compiled.js +1 -1
- package/dist/esm/ui/ChromeCollapsed/ChromeCollapsed-compiled.js +1 -1
- package/dist/esm/ui/ContextPanel/index-compiled.js +1 -1
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer-compiled.js +1 -1
- package/dist/esm/ui/PluginSlot/PluginSlot-compiled.js +1 -1
- package/dist/esm/ui/Toolbar/ToolbarComponentsWrapper-compiled.js +1 -1
- package/dist/esm/ui/Toolbar/ToolbarPortal.js +1 -1
- package/dist/esm/ui/Toolbar/ToolbarSizeDetectorWrapper-compiled.js +1 -1
- package/dist/esm/ui/WithFlash/withFlash-compiled.js +1 -1
- package/dist/esm/ui/quick-insert/ExtensionQuickInsertIcon.js +15 -0
- package/dist/esm/ui/quick-insert/ExtensionQuickInsertMenuItem.js +3 -0
- package/dist/esm/ui/quick-insert/getExtensionQuickInsertPreviewImageUrls.js +25 -0
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/ui/quick-insert/ExtensionQuickInsertIcon.d.ts +2 -1
- package/dist/types/ui/quick-insert/getExtensionQuickInsertPreviewImageUrls.d.ts +7 -0
- package/package.json +8 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,20 @@
|
|
|
1
1
|
# @atlaskit/editor-core
|
|
2
2
|
|
|
3
|
+
## 228.1.10
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`1ed24b2754939`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/1ed24b2754939) -
|
|
8
|
+
Show theme-aware previews for supported Embed app slash commands and branded Figma and Amplitude
|
|
9
|
+
icons behind the `platform_editor_slash_command` experiment.
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
12
|
+
## 228.1.9
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- Updated dependencies
|
|
17
|
+
|
|
3
18
|
## 228.1.8
|
|
4
19
|
|
|
5
20
|
### Patch Changes
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* editor-internal-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* editor-internal-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `editor-internal.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* Chromeless-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* Chromeless-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `Chromeless.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* FixedToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* FixedToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `Toolbar.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* BeforeWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* BeforeWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `BeforeWrapper.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* CustomToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* CustomToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `CustomToolbarWrapper.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* FullPage-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* FullPage-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `FullPage.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* MainToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* MainToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `MainToolbar.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* MainToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* MainToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `MainToolbarWrapper.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* EditorContentContainer-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* EditorContentContainer-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
"use strict";
|
|
3
3
|
|
|
4
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* ToolbarComponentsWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* ToolbarComponentsWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `ToolbarInner.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* ToolbarSizeDetectorWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* ToolbarSizeDetectorWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `ToolbarWithSizeDetector.tsx`.
|
|
@@ -15,6 +15,10 @@ var _carousel = _interopRequireDefault(require("@atlaskit/icon-lab/core/carousel
|
|
|
15
15
|
var _tableOfContent = _interopRequireDefault(require("@atlaskit/icon-lab/core/table-of-content"));
|
|
16
16
|
var _template = _interopRequireDefault(require("@atlaskit/icon-lab/core/template"));
|
|
17
17
|
var lazyExtensionIconCache = new WeakMap();
|
|
18
|
+
var brandedSlashCommandIconUrls = {
|
|
19
|
+
amplitude: 'https://dam-cdn.atl.orangelogic.com/AssetLink/730r6bie0211kg6obni4343y4g1wv6n5.svg',
|
|
20
|
+
figma: 'https://dam-cdn.atl.orangelogic.com/AssetLink/68t3023r7347271te7qw370k2pk37rgb.svg'
|
|
21
|
+
};
|
|
18
22
|
var whiteboardQuickInsertItemKeys = new Set(['whiteboard-extension:create-whiteboard', 'whiteboard-extension:create-diagram', 'whiteboard-extension:create-flowchart', 'whiteboard-extension:create-brainstorming', 'whiteboard-extension:create-retrospective', 'whiteboard-extension:create-roadmap']);
|
|
19
23
|
var quickInsertItemIcons = {
|
|
20
24
|
'toc:toc': _tableOfContent.default,
|
|
@@ -88,7 +92,9 @@ var createLazyExtensionIcon = function createLazyExtensionIcon(getIcon) {
|
|
|
88
92
|
var ExtensionQuickInsertIcon = exports.ExtensionQuickInsertIcon = function ExtensionQuickInsertIcon(_ref2) {
|
|
89
93
|
var getIcon = _ref2.getIcon,
|
|
90
94
|
itemKey = _ref2.itemKey,
|
|
95
|
+
itemTitle = _ref2.itemTitle,
|
|
91
96
|
label = _ref2.label;
|
|
97
|
+
var brandedIconUrl = brandedSlashCommandIconUrls[itemTitle.toLowerCase()];
|
|
92
98
|
var Icon = _react.default.useMemo(function () {
|
|
93
99
|
var quickInsertItemIcon = quickInsertItemIcons[itemKey];
|
|
94
100
|
if (quickInsertItemIcon) {
|
|
@@ -99,6 +105,15 @@ var ExtensionQuickInsertIcon = exports.ExtensionQuickInsertIcon = function Exten
|
|
|
99
105
|
}
|
|
100
106
|
return getIcon ? createLazyExtensionIcon(getIcon) : _apps.default;
|
|
101
107
|
}, [getIcon, itemKey]);
|
|
108
|
+
if (brandedIconUrl) {
|
|
109
|
+
return /*#__PURE__*/_react.default.createElement("img", {
|
|
110
|
+
alt: "",
|
|
111
|
+
"aria-hidden": "true",
|
|
112
|
+
height: 24,
|
|
113
|
+
src: brandedIconUrl,
|
|
114
|
+
width: 24
|
|
115
|
+
});
|
|
116
|
+
}
|
|
102
117
|
return /*#__PURE__*/_react.default.createElement(Icon, {
|
|
103
118
|
label: label
|
|
104
119
|
});
|
|
@@ -10,6 +10,7 @@ var _menuItem = require("@atlaskit/editor-common/quick-insert/menu-item");
|
|
|
10
10
|
var _useQuickInsertContext = require("@atlaskit/editor-common/quick-insert/use-quick-insert-context");
|
|
11
11
|
var _executeExtensionQuickInsertItem = require("./executeExtensionQuickInsertItem");
|
|
12
12
|
var _ExtensionQuickInsertIcon = require("./ExtensionQuickInsertIcon");
|
|
13
|
+
var _getExtensionQuickInsertPreviewImageUrls = require("./getExtensionQuickInsertPreviewImageUrls");
|
|
13
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); }
|
|
14
15
|
var ExtensionQuickInsertMenuItem = exports.ExtensionQuickInsertMenuItem = function ExtensionQuickInsertMenuItem(_ref) {
|
|
15
16
|
var apiRef = _ref.apiRef,
|
|
@@ -41,10 +42,12 @@ var ExtensionQuickInsertMenuItem = exports.ExtensionQuickInsertMenuItem = functi
|
|
|
41
42
|
iconBefore: /*#__PURE__*/_react.default.createElement(_ExtensionQuickInsertIcon.ExtensionQuickInsertIcon, {
|
|
42
43
|
getIcon: item.icon,
|
|
43
44
|
itemKey: item.key,
|
|
45
|
+
itemTitle: item.title,
|
|
44
46
|
label: ""
|
|
45
47
|
}),
|
|
46
48
|
isDisabled: isOffline,
|
|
47
49
|
onSelect: onSelect,
|
|
50
|
+
previewImageUrls: (0, _getExtensionQuickInsertPreviewImageUrls.getExtensionQuickInsertPreviewImageUrls)(item),
|
|
48
51
|
title: item.title
|
|
49
52
|
});
|
|
50
53
|
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.getExtensionQuickInsertPreviewImageUrls = void 0;
|
|
7
|
+
var previewImageUrlsByTitle = {
|
|
8
|
+
amplitude: {
|
|
9
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
|
|
10
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
|
|
11
|
+
},
|
|
12
|
+
dropbox: {
|
|
13
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
|
|
14
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
|
|
15
|
+
},
|
|
16
|
+
figma: {
|
|
17
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
|
|
18
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
|
|
19
|
+
},
|
|
20
|
+
'google drive': {
|
|
21
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y01wj4t58w86byx86l6k81a22axud131.png',
|
|
22
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/wi413m0837rjykg23r6y0256b7377185.png'
|
|
23
|
+
},
|
|
24
|
+
iframe: {
|
|
25
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
|
|
26
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
var getExtensionQuickInsertPreviewImageUrls = exports.getExtensionQuickInsertPreviewImageUrls = function getExtensionQuickInsertPreviewImageUrls(item) {
|
|
30
|
+
return previewImageUrlsByTitle[item.title.toLowerCase()];
|
|
31
|
+
};
|
|
@@ -6,4 +6,4 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.version = exports.name = void 0;
|
|
7
7
|
var name = exports.name = "@atlaskit/editor-core";
|
|
8
8
|
// eslint-disable-next-line @atlaskit/volt-strict-mode/no-multiple-exports
|
|
9
|
-
var version = exports.version = "228.1.
|
|
9
|
+
var version = exports.version = "228.1.9";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* editor-internal-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* editor-internal-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `editor-internal.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* clickAreaBlock-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* clickAreaBlock-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import "./clickAreaBlock-compiled.compiled.css";
|
|
4
4
|
import * as React from 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* Chromeless-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* Chromeless-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `Chromeless.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* Comment-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* Comment-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `Comment.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* FixedToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* FixedToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `Toolbar.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* StickyToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* StickyToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `Toolbar.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* BeforeWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* BeforeWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `BeforeWrapper.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* CustomToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* CustomToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `CustomToolbarWrapper.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* FullPage-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* FullPage-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `FullPage.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* FullPageContentArea-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* FullPageContentArea-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import "./FullPageContentArea-compiled.compiled.css";
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React, { useImperativeHandle, useRef } from 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* FullPageToolbarNext.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* FullPageToolbarNext.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import "./FullPageToolbarNext.compiled.css";
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React, { useCallback, useMemo } from 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* MainToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* MainToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `MainToolbar.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* MainToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* MainToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `MainToolbarWrapper.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* ChromeCollapsed-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* ChromeCollapsed-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import "./ChromeCollapsed-compiled.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* EditorContentContainer-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* EditorContentContainer-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
// oxlint-disable-next-line typescript-eslint/triple-slash-reference
|
|
3
3
|
/// <reference path="../../types/compiled-shims.d.ts" />
|
|
4
4
|
// TODO: EDITOR-6833 - Expected across this entire file, future violations are expected. Will try to remove them later after fully migration
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* PluginSlot-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* PluginSlot-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import "./PluginSlot-compiled.compiled.css";
|
|
4
4
|
import * as React from 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* ToolbarComponentsWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* ToolbarComponentsWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `ToolbarInner.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* ToolbarSizeDetectorWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* ToolbarSizeDetectorWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `ToolbarWithSizeDetector.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* withFlash-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* withFlash-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
import "./withFlash-compiled.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
@@ -6,6 +6,10 @@ import CarouselIcon from '@atlaskit/icon-lab/core/carousel';
|
|
|
6
6
|
import TableOfContentIcon from '@atlaskit/icon-lab/core/table-of-content';
|
|
7
7
|
import TemplateIcon from '@atlaskit/icon-lab/core/template';
|
|
8
8
|
const lazyExtensionIconCache = new WeakMap();
|
|
9
|
+
const brandedSlashCommandIconUrls = {
|
|
10
|
+
amplitude: 'https://dam-cdn.atl.orangelogic.com/AssetLink/730r6bie0211kg6obni4343y4g1wv6n5.svg',
|
|
11
|
+
figma: 'https://dam-cdn.atl.orangelogic.com/AssetLink/68t3023r7347271te7qw370k2pk37rgb.svg'
|
|
12
|
+
};
|
|
9
13
|
const whiteboardQuickInsertItemKeys = new Set(['whiteboard-extension:create-whiteboard', 'whiteboard-extension:create-diagram', 'whiteboard-extension:create-flowchart', 'whiteboard-extension:create-brainstorming', 'whiteboard-extension:create-retrospective', 'whiteboard-extension:create-roadmap']);
|
|
10
14
|
const quickInsertItemIcons = {
|
|
11
15
|
'toc:toc': TableOfContentIcon,
|
|
@@ -50,8 +54,10 @@ const createLazyExtensionIcon = getIcon => {
|
|
|
50
54
|
export const ExtensionQuickInsertIcon = ({
|
|
51
55
|
getIcon,
|
|
52
56
|
itemKey,
|
|
57
|
+
itemTitle,
|
|
53
58
|
label
|
|
54
59
|
}) => {
|
|
60
|
+
const brandedIconUrl = brandedSlashCommandIconUrls[itemTitle.toLowerCase()];
|
|
55
61
|
const Icon = React.useMemo(() => {
|
|
56
62
|
const quickInsertItemIcon = quickInsertItemIcons[itemKey];
|
|
57
63
|
if (quickInsertItemIcon) {
|
|
@@ -62,6 +68,15 @@ export const ExtensionQuickInsertIcon = ({
|
|
|
62
68
|
}
|
|
63
69
|
return getIcon ? createLazyExtensionIcon(getIcon) : AppsIcon;
|
|
64
70
|
}, [getIcon, itemKey]);
|
|
71
|
+
if (brandedIconUrl) {
|
|
72
|
+
return /*#__PURE__*/React.createElement("img", {
|
|
73
|
+
alt: "",
|
|
74
|
+
"aria-hidden": "true",
|
|
75
|
+
height: 24,
|
|
76
|
+
src: brandedIconUrl,
|
|
77
|
+
width: 24
|
|
78
|
+
});
|
|
79
|
+
}
|
|
65
80
|
return /*#__PURE__*/React.createElement(Icon, {
|
|
66
81
|
label: label
|
|
67
82
|
});
|
|
@@ -3,6 +3,7 @@ import { QuickInsertMenuItem } from '@atlaskit/editor-common/quick-insert/menu-i
|
|
|
3
3
|
import { useQuickInsertContext } from '@atlaskit/editor-common/quick-insert/use-quick-insert-context';
|
|
4
4
|
import { executeExtensionQuickInsertItem } from './executeExtensionQuickInsertItem';
|
|
5
5
|
import { ExtensionQuickInsertIcon } from './ExtensionQuickInsertIcon';
|
|
6
|
+
import { getExtensionQuickInsertPreviewImageUrls } from './getExtensionQuickInsertPreviewImageUrls';
|
|
6
7
|
export const ExtensionQuickInsertMenuItem = ({
|
|
7
8
|
apiRef,
|
|
8
9
|
createAnalyticsEvent,
|
|
@@ -36,10 +37,12 @@ export const ExtensionQuickInsertMenuItem = ({
|
|
|
36
37
|
iconBefore: /*#__PURE__*/React.createElement(ExtensionQuickInsertIcon, {
|
|
37
38
|
getIcon: item.icon,
|
|
38
39
|
itemKey: item.key,
|
|
40
|
+
itemTitle: item.title,
|
|
39
41
|
label: ""
|
|
40
42
|
}),
|
|
41
43
|
isDisabled: isOffline,
|
|
42
44
|
onSelect: onSelect,
|
|
45
|
+
previewImageUrls: getExtensionQuickInsertPreviewImageUrls(item),
|
|
43
46
|
title: item.title
|
|
44
47
|
});
|
|
45
48
|
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
const previewImageUrlsByTitle = {
|
|
2
|
+
amplitude: {
|
|
3
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
|
|
4
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
|
|
5
|
+
},
|
|
6
|
+
dropbox: {
|
|
7
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
|
|
8
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
|
|
9
|
+
},
|
|
10
|
+
figma: {
|
|
11
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
|
|
12
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
|
|
13
|
+
},
|
|
14
|
+
'google drive': {
|
|
15
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y01wj4t58w86byx86l6k81a22axud131.png',
|
|
16
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/wi413m0837rjykg23r6y0256b7377185.png'
|
|
17
|
+
},
|
|
18
|
+
iframe: {
|
|
19
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
|
|
20
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
|
|
21
|
+
}
|
|
22
|
+
};
|
|
23
|
+
export const getExtensionQuickInsertPreviewImageUrls = item => previewImageUrlsByTitle[item.title.toLowerCase()];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* editor-internal-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* editor-internal-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `editor-internal.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* clickAreaBlock-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* clickAreaBlock-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
4
|
var _excluded = ["children"];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* Chromeless-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* Chromeless-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `Chromeless.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* Comment-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* Comment-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
4
4
|
import "./Comment-compiled.compiled.css";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* FixedToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* FixedToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `Toolbar.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* StickyToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* StickyToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
3
3
|
import "./StickyToolbar-compiled.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* BeforeWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* BeforeWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `BeforeWrapper.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* CustomToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* CustomToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `CustomToolbarWrapper.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* FullPage-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* FullPage-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `FullPage.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* FullPageContentArea-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* FullPageContentArea-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import "./FullPageContentArea-compiled.compiled.css";
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React, { useImperativeHandle, useRef } from 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* FullPageToolbarNext.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* FullPageToolbarNext.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import "./FullPageToolbarNext.compiled.css";
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React, { useCallback, useMemo } from 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* MainToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* MainToolbar-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `MainToolbar.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* MainToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* MainToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `MainToolbarWrapper.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* ChromeCollapsed-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* ChromeCollapsed-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _objectDestructuringEmpty from "@babel/runtime/helpers/objectDestructuringEmpty";
|
|
3
3
|
import _extends from "@babel/runtime/helpers/extends";
|
|
4
4
|
import "./ChromeCollapsed-compiled.compiled.css";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* index-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* index-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
4
|
var _excluded = ["children", "customWidth", "visible"],
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* EditorContentContainer-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* EditorContentContainer-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
import "./EditorContentContainer-compiled.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* PluginSlot-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* PluginSlot-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
4
|
var _excluded = ["children"];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* ToolbarComponentsWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* ToolbarComponentsWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `ToolbarInner.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* ToolbarSizeDetectorWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* ToolbarSizeDetectorWrapper-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
4
|
* Used via `componentWithCondition` in `ToolbarWithSizeDetector.tsx`.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* withFlash-compiled.tsx generated by @compiled/babel-plugin v3.0.
|
|
1
|
+
/* withFlash-compiled.tsx generated by @compiled/babel-plugin v3.0.2 */
|
|
2
2
|
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
3
3
|
import _createClass from "@babel/runtime/helpers/createClass";
|
|
4
4
|
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
@@ -8,6 +8,10 @@ import CarouselIcon from '@atlaskit/icon-lab/core/carousel';
|
|
|
8
8
|
import TableOfContentIcon from '@atlaskit/icon-lab/core/table-of-content';
|
|
9
9
|
import TemplateIcon from '@atlaskit/icon-lab/core/template';
|
|
10
10
|
var lazyExtensionIconCache = new WeakMap();
|
|
11
|
+
var brandedSlashCommandIconUrls = {
|
|
12
|
+
amplitude: 'https://dam-cdn.atl.orangelogic.com/AssetLink/730r6bie0211kg6obni4343y4g1wv6n5.svg',
|
|
13
|
+
figma: 'https://dam-cdn.atl.orangelogic.com/AssetLink/68t3023r7347271te7qw370k2pk37rgb.svg'
|
|
14
|
+
};
|
|
11
15
|
var whiteboardQuickInsertItemKeys = new Set(['whiteboard-extension:create-whiteboard', 'whiteboard-extension:create-diagram', 'whiteboard-extension:create-flowchart', 'whiteboard-extension:create-brainstorming', 'whiteboard-extension:create-retrospective', 'whiteboard-extension:create-roadmap']);
|
|
12
16
|
var quickInsertItemIcons = {
|
|
13
17
|
'toc:toc': TableOfContentIcon,
|
|
@@ -81,7 +85,9 @@ var createLazyExtensionIcon = function createLazyExtensionIcon(getIcon) {
|
|
|
81
85
|
export var ExtensionQuickInsertIcon = function ExtensionQuickInsertIcon(_ref2) {
|
|
82
86
|
var getIcon = _ref2.getIcon,
|
|
83
87
|
itemKey = _ref2.itemKey,
|
|
88
|
+
itemTitle = _ref2.itemTitle,
|
|
84
89
|
label = _ref2.label;
|
|
90
|
+
var brandedIconUrl = brandedSlashCommandIconUrls[itemTitle.toLowerCase()];
|
|
85
91
|
var Icon = React.useMemo(function () {
|
|
86
92
|
var quickInsertItemIcon = quickInsertItemIcons[itemKey];
|
|
87
93
|
if (quickInsertItemIcon) {
|
|
@@ -92,6 +98,15 @@ export var ExtensionQuickInsertIcon = function ExtensionQuickInsertIcon(_ref2) {
|
|
|
92
98
|
}
|
|
93
99
|
return getIcon ? createLazyExtensionIcon(getIcon) : AppsIcon;
|
|
94
100
|
}, [getIcon, itemKey]);
|
|
101
|
+
if (brandedIconUrl) {
|
|
102
|
+
return /*#__PURE__*/React.createElement("img", {
|
|
103
|
+
alt: "",
|
|
104
|
+
"aria-hidden": "true",
|
|
105
|
+
height: 24,
|
|
106
|
+
src: brandedIconUrl,
|
|
107
|
+
width: 24
|
|
108
|
+
});
|
|
109
|
+
}
|
|
95
110
|
return /*#__PURE__*/React.createElement(Icon, {
|
|
96
111
|
label: label
|
|
97
112
|
});
|
|
@@ -3,6 +3,7 @@ import { QuickInsertMenuItem } from '@atlaskit/editor-common/quick-insert/menu-i
|
|
|
3
3
|
import { useQuickInsertContext } from '@atlaskit/editor-common/quick-insert/use-quick-insert-context';
|
|
4
4
|
import { executeExtensionQuickInsertItem } from './executeExtensionQuickInsertItem';
|
|
5
5
|
import { ExtensionQuickInsertIcon } from './ExtensionQuickInsertIcon';
|
|
6
|
+
import { getExtensionQuickInsertPreviewImageUrls } from './getExtensionQuickInsertPreviewImageUrls';
|
|
6
7
|
export var ExtensionQuickInsertMenuItem = function ExtensionQuickInsertMenuItem(_ref) {
|
|
7
8
|
var apiRef = _ref.apiRef,
|
|
8
9
|
createAnalyticsEvent = _ref.createAnalyticsEvent,
|
|
@@ -33,10 +34,12 @@ export var ExtensionQuickInsertMenuItem = function ExtensionQuickInsertMenuItem(
|
|
|
33
34
|
iconBefore: /*#__PURE__*/React.createElement(ExtensionQuickInsertIcon, {
|
|
34
35
|
getIcon: item.icon,
|
|
35
36
|
itemKey: item.key,
|
|
37
|
+
itemTitle: item.title,
|
|
36
38
|
label: ""
|
|
37
39
|
}),
|
|
38
40
|
isDisabled: isOffline,
|
|
39
41
|
onSelect: onSelect,
|
|
42
|
+
previewImageUrls: getExtensionQuickInsertPreviewImageUrls(item),
|
|
40
43
|
title: item.title
|
|
41
44
|
});
|
|
42
45
|
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
var previewImageUrlsByTitle = {
|
|
2
|
+
amplitude: {
|
|
3
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
|
|
4
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
|
|
5
|
+
},
|
|
6
|
+
dropbox: {
|
|
7
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
|
|
8
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
|
|
9
|
+
},
|
|
10
|
+
figma: {
|
|
11
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
|
|
12
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
|
|
13
|
+
},
|
|
14
|
+
'google drive': {
|
|
15
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y01wj4t58w86byx86l6k81a22axud131.png',
|
|
16
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/wi413m0837rjykg23r6y0256b7377185.png'
|
|
17
|
+
},
|
|
18
|
+
iframe: {
|
|
19
|
+
dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
|
|
20
|
+
light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
|
|
21
|
+
}
|
|
22
|
+
};
|
|
23
|
+
export var getExtensionQuickInsertPreviewImageUrls = function getExtensionQuickInsertPreviewImageUrls(item) {
|
|
24
|
+
return previewImageUrlsByTitle[item.title.toLowerCase()];
|
|
25
|
+
};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { MenuItem } from '@atlaskit/editor-common/extensions';
|
|
3
|
-
export declare const ExtensionQuickInsertIcon: ({ getIcon, itemKey, label, }: {
|
|
3
|
+
export declare const ExtensionQuickInsertIcon: ({ getIcon, itemKey, itemTitle, label, }: {
|
|
4
4
|
getIcon?: MenuItem['icon'];
|
|
5
5
|
itemKey: string;
|
|
6
|
+
itemTitle: string;
|
|
6
7
|
label: string;
|
|
7
8
|
}) => React.JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { MenuItem } from '@atlaskit/editor-common/extensions';
|
|
2
|
+
type PreviewImageUrls = {
|
|
3
|
+
dark: string;
|
|
4
|
+
light: string;
|
|
5
|
+
};
|
|
6
|
+
export declare const getExtensionQuickInsertPreviewImageUrls: (item: Pick<MenuItem, 'title'>) => PreviewImageUrls | undefined;
|
|
7
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-core",
|
|
3
|
-
"version": "228.1.
|
|
3
|
+
"version": "228.1.10",
|
|
4
4
|
"description": "A package contains Atlassian editor core functionality",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"@atlaskit/icon-lab": "^7.9.0",
|
|
66
66
|
"@atlaskit/link": "^5.1.0",
|
|
67
67
|
"@atlaskit/media-card": "^81.12.0",
|
|
68
|
-
"@atlaskit/mention": "^29.
|
|
68
|
+
"@atlaskit/mention": "^29.2.0",
|
|
69
69
|
"@atlaskit/platform-feature-experiments": "^0.3.0",
|
|
70
70
|
"@atlaskit/platform-feature-flags": "^2.2.0",
|
|
71
71
|
"@atlaskit/platform-feature-flags-react": "^1.2.0",
|
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
"@atlaskit/react-compiler-gating": "^0.2.0",
|
|
75
75
|
"@atlaskit/react-ufo": "^7.10.0",
|
|
76
76
|
"@atlaskit/task-decision": "^21.10.0",
|
|
77
|
-
"@atlaskit/tmp-editor-statsig": "^
|
|
77
|
+
"@atlaskit/tmp-editor-statsig": "^197.0.0",
|
|
78
78
|
"@atlaskit/tokens": "^17.0.0",
|
|
79
79
|
"@atlaskit/tooltip": "^24.3.0",
|
|
80
80
|
"@atlaskit/width-detector": "^7.2.0",
|
|
@@ -92,8 +92,8 @@
|
|
|
92
92
|
"uuid": "^11.1.1"
|
|
93
93
|
},
|
|
94
94
|
"peerDependencies": {
|
|
95
|
-
"@atlaskit/editor-common": "^122.
|
|
96
|
-
"@atlaskit/link-provider": "^5.
|
|
95
|
+
"@atlaskit/editor-common": "^122.9.0",
|
|
96
|
+
"@atlaskit/link-provider": "^5.7.0",
|
|
97
97
|
"@atlaskit/media-core": "^38.2.0",
|
|
98
98
|
"react": "^18.2.0 || ^19.2.0",
|
|
99
99
|
"react-dom": "^18.2.0 || ^19.2.0",
|
|
@@ -141,8 +141,8 @@
|
|
|
141
141
|
"@atlaskit/editor-synced-block-renderer": "^16.0.0",
|
|
142
142
|
"@atlaskit/editor-test-helpers": "workspace:^",
|
|
143
143
|
"@atlaskit/form": "^17.2.0",
|
|
144
|
-
"@atlaskit/link-provider": "^5.
|
|
145
|
-
"@atlaskit/linking-common": "^12.
|
|
144
|
+
"@atlaskit/link-provider": "^5.7.0",
|
|
145
|
+
"@atlaskit/linking-common": "^12.3.0",
|
|
146
146
|
"@atlaskit/logo": "^23.0.0",
|
|
147
147
|
"@atlaskit/media-core": "^38.2.0",
|
|
148
148
|
"@atlaskit/media-integration-test-helpers": "workspace:^",
|
|
@@ -166,7 +166,7 @@
|
|
|
166
166
|
"@atlassian/a11y-jest-testing": "^0.17.0",
|
|
167
167
|
"@atlassian/a11y-playwright-testing": "^0.12.0",
|
|
168
168
|
"@atlassian/adf-schema-json": "^1.35.0",
|
|
169
|
-
"@atlassian/editor-rovo-bridge": "^
|
|
169
|
+
"@atlassian/editor-rovo-bridge": "^17.0.0",
|
|
170
170
|
"@atlassian/experiment-test-utils": "^0.2.0",
|
|
171
171
|
"@atlassian/feature-flags-test-utils": "^1.3.0",
|
|
172
172
|
"@atlassian/search-client": "^3.0.0",
|