@atlaskit/editor-core 229.1.1 → 229.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,28 @@
1
1
  # @atlaskit/editor-core
2
2
 
3
+ ## 229.1.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [`fc5f24d3c4d3f`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/fc5f24d3c4d3f) -
8
+ [ux] Add hover previews for Other slash-menu items behind `platform_editor_slash_command`.
9
+ - [`fc26bfc51dd5c`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/fc26bfc51dd5c) -
10
+ Add sparse block-control surface anchors, intersection-driven candidates, and explicit visibility
11
+ invalidation for registry-backed block controls. Expose registration change subscriptions from the
12
+ UI control registry model, and refresh cached visibility from suggestion and collapse transaction
13
+ metadata. Under `platform_editor_block_control_migration`, use native node-anchor identity across
14
+ Editor and Block Controls, and route expand keyboard focus through the shared Block Controls
15
+ command. Preserve Show Diff visibility checks in both migration cohorts so block controls stay
16
+ hidden while a diff is displayed. Keep the block menu closed when a migrated layout-column handle
17
+ opens the layout menu, and close the layout menu when the selection moves away from its selected
18
+ columns.
19
+ - [`64a76a7487e96`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/64a76a7487e96) -
20
+ Add block template hover previews keyed by stable snippet IDs behind
21
+ platform_editor_slash_command, including the legacy Confluence provider path and the direct
22
+ extension renderer used by the slash menu. Unknown snippet IDs remain without a preview. Use the
23
+ supplied highest-quality light and dark preview assets for all 21 supported block templates.
24
+ - Updated dependencies
25
+
3
26
  ## 229.1.1
4
27
 
5
28
  ### Patch Changes
@@ -7,6 +7,7 @@ Object.defineProperty(exports, "__esModule", {
7
7
  exports.createPMPlugins = createPMPlugins;
8
8
  var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
9
9
  var _legacyRankPlugins = require("@atlaskit/editor-common/legacy-rank-plugins");
10
+ var _isExperimentEnabled = require("@atlaskit/platform-feature-experiments/is-experiment-enabled");
10
11
  var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
11
12
  var _editorNativeAnchorSupportPlugin = require("./editorNativeAnchorSupportPlugin");
12
13
  var _editorStateNotificationPlugin = require("./editorStateNotificationPlugin");
@@ -29,7 +30,7 @@ function createPMPlugins(config) {
29
30
  }).filter(function (plugin) {
30
31
  return typeof plugin !== 'undefined';
31
32
  });
32
- if ((0, _expValEquals.expValEquals)('platform_editor_native_anchor_with_dnd', 'isEnabled', true)) {
33
+ if ((0, _expValEquals.expValEquals)('platform_editor_native_anchor_with_dnd', 'isEnabled', true) || (0, _isExperimentEnabled.isExperimentEnabled)('platform_editor_block_control_migration')) {
33
34
  pmPlugins.push((0, _editorNativeAnchorSupportPlugin.createEditorNativeAnchorSupportPlugin)(config.schema));
34
35
  }
35
36
  if (config.onEditorStateUpdated !== undefined) {
@@ -6,11 +6,31 @@ Object.defineProperty(exports, "__esModule", {
6
6
  });
7
7
  exports.getExtensionQuickInsertPreviewImageUrls = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
9
+ var _snippetPreviewImageUrls = require("@atlaskit/editor-common/quick-insert/snippet-preview-image-urls");
10
+ var _isExperimentEnabled = require("@atlaskit/platform-feature-experiments/is-experiment-enabled");
9
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; }
10
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) { (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; }
11
- var googleDrivePreviewImageUrls = {
12
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y01wj4t58w86byx86l6k81a22axud131.png',
13
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/wi413m0837rjykg23r6y0256b7377185.png'
13
+ var embedPreviewImageUrlsByKey = {
14
+ 'third-party-quick-insert-embeds:third-party-embed-amplitude': {
15
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
16
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
17
+ },
18
+ 'dropbox:item': {
19
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
20
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
21
+ },
22
+ 'third-party-quick-insert-embeds:third-party-embed-figma': {
23
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
24
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
25
+ },
26
+ 'third-party-quick-insert-embeds:third-party-embed-google-drive': {
27
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y01wj4t58w86byx86l6k81a22axud131.png',
28
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/wi413m0837rjykg23r6y0256b7377185.png'
29
+ },
30
+ 'iframe:iframe': {
31
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
32
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
33
+ }
14
34
  };
15
35
  var dataAndChartsPreviewImageUrlsByKey = {
16
36
  'quick-insert-assets-menu-item': {
@@ -118,7 +138,157 @@ var dataAndChartsPreviewImageUrlsByKey = {
118
138
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/o2kexap23ijq8jeqhpvi8lgc51dex3wj.png'
119
139
  }
120
140
  };
121
- var previewImageUrlsByKey = _objectSpread(_objectSpread({}, dataAndChartsPreviewImageUrlsByKey), {}, {
141
+ var otherPreviewImageUrlsByKey = {
142
+ 'excerpt:excerpt': {
143
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/1h408wk0e4x6efhby84hbc583nx5b0b5.png',
144
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0j5s4a60jjbrq3yoa7kfnkft28403127.png'
145
+ },
146
+ 'excerpt-include:excerpt-include': {
147
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/dg718ggxcx60dj7ng86fpqmwbv7vauny.png',
148
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y373d21g768gmvjao5db38kw4460m72r.png'
149
+ },
150
+ 'include:include': {
151
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/s12155hkaoc81aa0eh58y54402s8t346.png',
152
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/61yskd00re82i80b8r6pfxp60pi4852s.png'
153
+ },
154
+ 'jirachart:jirachart': {
155
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/30g82ea1p64616h40s110ysud47dnof6.png',
156
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/114de8qe6dy877s65xh1a2dil1r86x73.png'
157
+ },
158
+ 'jira:jira': {
159
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/8ttib573524136b5lffq3a1go05x507d.png',
160
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pdnn81xj6e8v56nye6rnft3rd4yhnc05.png'
161
+ },
162
+ 'portfolioforjiraplan:portfolioforjiraplan': {
163
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/24g0yt8c54671463162f5q455qcki3id.png',
164
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/c2hy8b245yg1dt2776ol5sx57n045nv0.png'
165
+ },
166
+ 'opsgenie-incident-timeline-eu-macro:opsgenie-incident-timeline-eu-macro': {
167
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qo0u146811738ixd6l13nud48pv57510.png',
168
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qnq1bn07a3k0v4m10hoi487p837obx53.png'
169
+ },
170
+ 'sharelinks-urlmacro:sharelinks-urlmacro': {
171
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0028h1741o411uw4qi8icbg138kus32e.png',
172
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/myhw531c3748qn4ro51vf450vk0qg481.png'
173
+ },
174
+ 'toc-zone:toc-zone': {
175
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/1p16277ig16wc6kelloa542k33b18mm2.png',
176
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/s4q2ap8q4135r0r3i1tym1d5koxdonb1.png'
177
+ },
178
+ 'viewpdf:viewpdf': {
179
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/jt685rp527nfo8jqp6o5o0r31l3rpfux.png',
180
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/30u3v86x652ah52ruhqj1ap0s0ve4ey2.png'
181
+ },
182
+ 'viewxls:viewxls': {
183
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/b11p6ksb8r6j6g2604p67ab53f23u6f5.png',
184
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/r426m140lbp7gs2gxbe015e21kf23j8l.png'
185
+ },
186
+ 'gadget:activity stream': {
187
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v3a1rvva7gxr874o5qah5k61365hod5.png',
188
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/nh7404rduyw5tbne4143426evuk7hvg8.png'
189
+ },
190
+ 'gadget:agile wallboard gadget': {
191
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/n611u81ca8fkyv5nk6cl6j1081e805tr.png',
192
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/3o7vtt14rtpe3sna7mras6oih86nssb6.png'
193
+ },
194
+ 'gadget:assigned to me': {
195
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/d72jy2r18q6v06s13k2f6x3fymrr4on7.png',
196
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/5c62343jh3411ido38440xx0007cx6ls.png'
197
+ },
198
+ 'gadget:average age chart': {
199
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/i53kn1igq64m5dip4eg1030j15yd7xxe.png',
200
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/t136146lvs3x60456gnsghtv730uaftn.png'
201
+ },
202
+ 'gadget:average number of times in status': {
203
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u4v77u1lwcy5g08y047q33dbiv42dkit.png',
204
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/16v2eq2c1df0mrf2jo6xic526527nfh1.png'
205
+ },
206
+ 'gadget:days remaining in sprint gadget': {
207
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/805320gvqd6cbr23yrv271oas2u061s5.png',
208
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/41j35y64652g06uru332kt2a0pk77j03.png'
209
+ },
210
+ 'gadget:filter results': {
211
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/w0n60p750b2275k226gri2j6i366jt0e.png',
212
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/j706ug0u5nk40i1lhrt05j63grc36x0u.png'
213
+ },
214
+ 'gadget:heat map': {
215
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qoepx85h21t4u00cht35nc3ssl4i72j5.png',
216
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/w574xrh77oxbmb18f0ro1bd80x417426.png'
217
+ },
218
+ 'gadget:issues in progress': {
219
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/666u7h3tp16ad4k8u24d4u1155n1v7hg.png',
220
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/go2d8b1qs7h07b17326lx8r8p28jm011.png'
221
+ },
222
+ 'gadget:jira issues calendar': {
223
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/13o0sk45vlf25x1m3w14gsy146k25b14.png',
224
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/j23063ot2a014a2a51y6i0o1keo0kanr.png'
225
+ },
226
+ 'gadget:jira road map': {
227
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/h6u3kb7116jr12w3f586stmc850827h3.png',
228
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/q23v3a23018y2856kew3fsork63bg6p2.png'
229
+ },
230
+ 'gadget:labels gadget': {
231
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7u8gpvv82s3e2833204nm6m1k3301c46.png',
232
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/42hjlte7y364o8y4e5udkl11o22a2ac3.png'
233
+ },
234
+ 'gadget:pie chart': {
235
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v4b6d7to551136834oe1a0xx66n7mv5e.png',
236
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pdq60d803b655il4x3m0co608guc56ub.png'
237
+ },
238
+ 'gadget:quick links': {
239
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/onlh3rc6p0qj15rsysxa3ep5b183hk40.png',
240
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/k51qkw636t010l5h1vrs05c7i073y0xp.png'
241
+ },
242
+ 'gadget:recently created chart': {
243
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/t5in18tcubtbr18yv1gr0ap26x7d6bh3.png',
244
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/ia4jrrsg4mw8tu0gtj88d2yr5w6s20fm.png'
245
+ },
246
+ 'gadget:resolution time': {
247
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/3dek0066jn31qfkk2l2hn011um087y72.png',
248
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/msw0hn3462vvai4l4jkp50xcm87741j6.png'
249
+ },
250
+ 'gadget:sprint burndown gadget': {
251
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2qqrp3vl4rv2p443566826jadj38rfrj.png',
252
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qic3bcq5sqhd7r00qpj3i6240n3uw3fp.png'
253
+ },
254
+ 'gadget:sprint health gadget': {
255
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/uoqla656675p5wwc3a8v824768lip528.png',
256
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pnngo5y00g18eos4je3r20ga0c666c68.png'
257
+ },
258
+ 'gadget:time since chart': {
259
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/f7g8053ww4deogfid2h2pj2nw6n8582u.png',
260
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/20wj0kb8mjjj7in0hu62j4ska17ug5s3.png'
261
+ },
262
+ 'gadget:time to first response': {
263
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/l4cy50n75hr166cpohxpd3h5038e8sl7.png',
264
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/8kkdphd2l3gb7w06dboc82rmtm86xk7r.png'
265
+ },
266
+ 'gadget:two dimensional filter statistics': {
267
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/6s1x266h56m7p4q758jem2k03hbu15gb.png',
268
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/hjt70wg3tds43ev34nxv1r7l50170f4l.png'
269
+ },
270
+ 'gadget:version report': {
271
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2143nj51e834657316q5n5j6kbq3h3m7.png',
272
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/rgi5il8d845k40f65w0f8a678c1rf51q.png'
273
+ },
274
+ 'gadget:voted work items': {
275
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0n262m847lgjj174x658ps04k6j513r6.png',
276
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/rcn6qrr638k1v5y6xrw8g512f2530244.png'
277
+ },
278
+ 'gadget:watched issues': {
279
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v418o500l40ga5gtq6m23x5t17k47wbe.png',
280
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/mv0w504r53gvkx38g3y74pd65k5hktop.png'
281
+ },
282
+ 'gadget:work item statistics': {
283
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4315hi70mlh4eqbn6215p10s4il7os34.png',
284
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/l3120n2755pw6r2o2q24tmsgu6658533.png'
285
+ },
286
+ 'gadget:workload pie chart': {
287
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v5j8p100viey44g61cdc61d53465gda5.png',
288
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/84tce4xo2nqe0712oil1f08n5160a11v.png'
289
+ }
290
+ };
291
+ var previewImageUrlsByKey = _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, dataAndChartsPreviewImageUrlsByKey), embedPreviewImageUrlsByKey), otherPreviewImageUrlsByKey), {}, {
122
292
  'profile-picture:profile-picture': {
123
293
  dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/35rb2mbxc2dt8p7op8u8lyss5h220428.png',
124
294
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4o3lpe2eh4nlakav375621i73do50kyx.png'
@@ -147,24 +317,6 @@ var previewImageUrlsByKey = _objectSpread(_objectSpread({}, dataAndChartsPreview
147
317
  dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4u6tb8343dv71eotl5462nydlq3544ut.png',
148
318
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/k177s112506n0bn788227s0ig45nko57.png'
149
319
  },
150
- 'third-party-quick-insert-embeds:third-party-embed-amplitude': {
151
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
152
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
153
- },
154
- 'dropbox:item': {
155
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
156
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
157
- },
158
- 'third-party-quick-insert-embeds:third-party-embed-figma': {
159
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
160
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
161
- },
162
- 'third-party-quick-insert-embeds:third-party-embed-google-drive': googleDrivePreviewImageUrls,
163
- 'google-drive:item': googleDrivePreviewImageUrls,
164
- 'iframe:iframe': {
165
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
166
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
167
- },
168
320
  'anchor:anchor': {
169
321
  dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/5f440bb8m37yig3u77s6c8200re8mto0.png',
170
322
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y42w6i56fk22vb3g5120d43qfwte8a78.png'
@@ -202,27 +354,12 @@ var previewImageUrlsByKey = _objectSpread(_objectSpread({}, dataAndChartsPreview
202
354
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v8eyy0fvu61fb8a4b4teea4pjs7g2842.png'
203
355
  }
204
356
  });
205
- var previewImageUrlsByTitle = {
206
- amplitude: {
207
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
208
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
209
- },
210
- dropbox: {
211
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
212
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
213
- },
214
- figma: {
215
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
216
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
217
- },
218
- 'google drive': googleDrivePreviewImageUrls,
219
- iframe: {
220
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
221
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
222
- }
223
- };
224
357
  var getExtensionQuickInsertPreviewImageUrls = exports.getExtensionQuickInsertPreviewImageUrls = function getExtensionQuickInsertPreviewImageUrls(item) {
225
- var _ref, _ref2, _ref3;
358
+ var _item$key, _ref, _ref2, _dataAndChartsPreview;
359
+ var snippetKeyPrefix = 'snippet-extension:snippet-';
360
+ if ((_item$key = item.key) !== null && _item$key !== void 0 && _item$key.startsWith(snippetKeyPrefix)) {
361
+ return (0, _isExperimentEnabled.isExperimentEnabled)('platform_editor_slash_command') ? (0, _snippetPreviewImageUrls.getSnippetPreviewImageUrls)(item.key.slice(snippetKeyPrefix.length)) : undefined;
362
+ }
226
363
  var normalizedTitle = item.title.toLowerCase();
227
- return (_ref = (_ref2 = (_ref3 = item.key ? previewImageUrlsByKey[item.key] : undefined) !== null && _ref3 !== void 0 ? _ref3 : item.extensionKey === 'gadget' ? dataAndChartsPreviewImageUrlsByKey["".concat(item.extensionKey, ":").concat(normalizedTitle)] : undefined) !== null && _ref2 !== void 0 ? _ref2 : item.extensionKey ? dataAndChartsPreviewImageUrlsByKey[item.extensionKey] : undefined) !== null && _ref !== void 0 ? _ref : previewImageUrlsByTitle[normalizedTitle];
364
+ return (_ref = (_ref2 = item.key ? previewImageUrlsByKey[item.key] : undefined) !== null && _ref2 !== void 0 ? _ref2 : item.extensionKey === 'gadget' ? (_dataAndChartsPreview = dataAndChartsPreviewImageUrlsByKey["".concat(item.extensionKey, ":").concat(normalizedTitle)]) !== null && _dataAndChartsPreview !== void 0 ? _dataAndChartsPreview : otherPreviewImageUrlsByKey["".concat(item.extensionKey, ":").concat(normalizedTitle)] : undefined) !== null && _ref !== void 0 ? _ref : item.extensionKey ? dataAndChartsPreviewImageUrlsByKey[item.extensionKey] : undefined;
228
365
  };
@@ -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 = "229.1.0";
9
+ var version = exports.version = "229.1.1";
@@ -1,4 +1,5 @@
1
1
  import { sortByOrder } from '@atlaskit/editor-common/legacy-rank-plugins';
2
+ import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
2
3
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
3
4
  import { createEditorNativeAnchorSupportPlugin } from './editorNativeAnchorSupportPlugin';
4
5
  import { createEditorStateNotificationPlugin } from './editorStateNotificationPlugin';
@@ -20,7 +21,7 @@ export function createPMPlugins(config) {
20
21
  featureFlags: config.featureFlags || {},
21
22
  getIntl: config.getIntl
22
23
  })).filter(plugin => typeof plugin !== 'undefined');
23
- if (expValEquals('platform_editor_native_anchor_with_dnd', 'isEnabled', true)) {
24
+ if (expValEquals('platform_editor_native_anchor_with_dnd', 'isEnabled', true) || isExperimentEnabled('platform_editor_block_control_migration')) {
24
25
  pmPlugins.push(createEditorNativeAnchorSupportPlugin(config.schema));
25
26
  }
26
27
  if (config.onEditorStateUpdated !== undefined) {
@@ -1,6 +1,26 @@
1
- const googleDrivePreviewImageUrls = {
2
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y01wj4t58w86byx86l6k81a22axud131.png',
3
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/wi413m0837rjykg23r6y0256b7377185.png'
1
+ import { getSnippetPreviewImageUrls } from '@atlaskit/editor-common/quick-insert/snippet-preview-image-urls';
2
+ import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
3
+ const embedPreviewImageUrlsByKey = {
4
+ 'third-party-quick-insert-embeds:third-party-embed-amplitude': {
5
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
6
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
7
+ },
8
+ 'dropbox:item': {
9
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
10
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
11
+ },
12
+ 'third-party-quick-insert-embeds:third-party-embed-figma': {
13
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
14
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
15
+ },
16
+ 'third-party-quick-insert-embeds:third-party-embed-google-drive': {
17
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y01wj4t58w86byx86l6k81a22axud131.png',
18
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/wi413m0837rjykg23r6y0256b7377185.png'
19
+ },
20
+ 'iframe:iframe': {
21
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
22
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
23
+ }
4
24
  };
5
25
  const dataAndChartsPreviewImageUrlsByKey = {
6
26
  'quick-insert-assets-menu-item': {
@@ -108,8 +128,160 @@ const dataAndChartsPreviewImageUrlsByKey = {
108
128
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/o2kexap23ijq8jeqhpvi8lgc51dex3wj.png'
109
129
  }
110
130
  };
131
+ const otherPreviewImageUrlsByKey = {
132
+ 'excerpt:excerpt': {
133
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/1h408wk0e4x6efhby84hbc583nx5b0b5.png',
134
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0j5s4a60jjbrq3yoa7kfnkft28403127.png'
135
+ },
136
+ 'excerpt-include:excerpt-include': {
137
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/dg718ggxcx60dj7ng86fpqmwbv7vauny.png',
138
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y373d21g768gmvjao5db38kw4460m72r.png'
139
+ },
140
+ 'include:include': {
141
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/s12155hkaoc81aa0eh58y54402s8t346.png',
142
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/61yskd00re82i80b8r6pfxp60pi4852s.png'
143
+ },
144
+ 'jirachart:jirachart': {
145
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/30g82ea1p64616h40s110ysud47dnof6.png',
146
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/114de8qe6dy877s65xh1a2dil1r86x73.png'
147
+ },
148
+ 'jira:jira': {
149
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/8ttib573524136b5lffq3a1go05x507d.png',
150
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pdnn81xj6e8v56nye6rnft3rd4yhnc05.png'
151
+ },
152
+ 'portfolioforjiraplan:portfolioforjiraplan': {
153
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/24g0yt8c54671463162f5q455qcki3id.png',
154
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/c2hy8b245yg1dt2776ol5sx57n045nv0.png'
155
+ },
156
+ 'opsgenie-incident-timeline-eu-macro:opsgenie-incident-timeline-eu-macro': {
157
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qo0u146811738ixd6l13nud48pv57510.png',
158
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qnq1bn07a3k0v4m10hoi487p837obx53.png'
159
+ },
160
+ 'sharelinks-urlmacro:sharelinks-urlmacro': {
161
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0028h1741o411uw4qi8icbg138kus32e.png',
162
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/myhw531c3748qn4ro51vf450vk0qg481.png'
163
+ },
164
+ 'toc-zone:toc-zone': {
165
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/1p16277ig16wc6kelloa542k33b18mm2.png',
166
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/s4q2ap8q4135r0r3i1tym1d5koxdonb1.png'
167
+ },
168
+ 'viewpdf:viewpdf': {
169
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/jt685rp527nfo8jqp6o5o0r31l3rpfux.png',
170
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/30u3v86x652ah52ruhqj1ap0s0ve4ey2.png'
171
+ },
172
+ 'viewxls:viewxls': {
173
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/b11p6ksb8r6j6g2604p67ab53f23u6f5.png',
174
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/r426m140lbp7gs2gxbe015e21kf23j8l.png'
175
+ },
176
+ 'gadget:activity stream': {
177
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v3a1rvva7gxr874o5qah5k61365hod5.png',
178
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/nh7404rduyw5tbne4143426evuk7hvg8.png'
179
+ },
180
+ 'gadget:agile wallboard gadget': {
181
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/n611u81ca8fkyv5nk6cl6j1081e805tr.png',
182
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/3o7vtt14rtpe3sna7mras6oih86nssb6.png'
183
+ },
184
+ 'gadget:assigned to me': {
185
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/d72jy2r18q6v06s13k2f6x3fymrr4on7.png',
186
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/5c62343jh3411ido38440xx0007cx6ls.png'
187
+ },
188
+ 'gadget:average age chart': {
189
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/i53kn1igq64m5dip4eg1030j15yd7xxe.png',
190
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/t136146lvs3x60456gnsghtv730uaftn.png'
191
+ },
192
+ 'gadget:average number of times in status': {
193
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u4v77u1lwcy5g08y047q33dbiv42dkit.png',
194
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/16v2eq2c1df0mrf2jo6xic526527nfh1.png'
195
+ },
196
+ 'gadget:days remaining in sprint gadget': {
197
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/805320gvqd6cbr23yrv271oas2u061s5.png',
198
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/41j35y64652g06uru332kt2a0pk77j03.png'
199
+ },
200
+ 'gadget:filter results': {
201
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/w0n60p750b2275k226gri2j6i366jt0e.png',
202
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/j706ug0u5nk40i1lhrt05j63grc36x0u.png'
203
+ },
204
+ 'gadget:heat map': {
205
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qoepx85h21t4u00cht35nc3ssl4i72j5.png',
206
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/w574xrh77oxbmb18f0ro1bd80x417426.png'
207
+ },
208
+ 'gadget:issues in progress': {
209
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/666u7h3tp16ad4k8u24d4u1155n1v7hg.png',
210
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/go2d8b1qs7h07b17326lx8r8p28jm011.png'
211
+ },
212
+ 'gadget:jira issues calendar': {
213
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/13o0sk45vlf25x1m3w14gsy146k25b14.png',
214
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/j23063ot2a014a2a51y6i0o1keo0kanr.png'
215
+ },
216
+ 'gadget:jira road map': {
217
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/h6u3kb7116jr12w3f586stmc850827h3.png',
218
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/q23v3a23018y2856kew3fsork63bg6p2.png'
219
+ },
220
+ 'gadget:labels gadget': {
221
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7u8gpvv82s3e2833204nm6m1k3301c46.png',
222
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/42hjlte7y364o8y4e5udkl11o22a2ac3.png'
223
+ },
224
+ 'gadget:pie chart': {
225
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v4b6d7to551136834oe1a0xx66n7mv5e.png',
226
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pdq60d803b655il4x3m0co608guc56ub.png'
227
+ },
228
+ 'gadget:quick links': {
229
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/onlh3rc6p0qj15rsysxa3ep5b183hk40.png',
230
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/k51qkw636t010l5h1vrs05c7i073y0xp.png'
231
+ },
232
+ 'gadget:recently created chart': {
233
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/t5in18tcubtbr18yv1gr0ap26x7d6bh3.png',
234
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/ia4jrrsg4mw8tu0gtj88d2yr5w6s20fm.png'
235
+ },
236
+ 'gadget:resolution time': {
237
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/3dek0066jn31qfkk2l2hn011um087y72.png',
238
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/msw0hn3462vvai4l4jkp50xcm87741j6.png'
239
+ },
240
+ 'gadget:sprint burndown gadget': {
241
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2qqrp3vl4rv2p443566826jadj38rfrj.png',
242
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qic3bcq5sqhd7r00qpj3i6240n3uw3fp.png'
243
+ },
244
+ 'gadget:sprint health gadget': {
245
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/uoqla656675p5wwc3a8v824768lip528.png',
246
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pnngo5y00g18eos4je3r20ga0c666c68.png'
247
+ },
248
+ 'gadget:time since chart': {
249
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/f7g8053ww4deogfid2h2pj2nw6n8582u.png',
250
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/20wj0kb8mjjj7in0hu62j4ska17ug5s3.png'
251
+ },
252
+ 'gadget:time to first response': {
253
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/l4cy50n75hr166cpohxpd3h5038e8sl7.png',
254
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/8kkdphd2l3gb7w06dboc82rmtm86xk7r.png'
255
+ },
256
+ 'gadget:two dimensional filter statistics': {
257
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/6s1x266h56m7p4q758jem2k03hbu15gb.png',
258
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/hjt70wg3tds43ev34nxv1r7l50170f4l.png'
259
+ },
260
+ 'gadget:version report': {
261
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2143nj51e834657316q5n5j6kbq3h3m7.png',
262
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/rgi5il8d845k40f65w0f8a678c1rf51q.png'
263
+ },
264
+ 'gadget:voted work items': {
265
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0n262m847lgjj174x658ps04k6j513r6.png',
266
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/rcn6qrr638k1v5y6xrw8g512f2530244.png'
267
+ },
268
+ 'gadget:watched issues': {
269
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v418o500l40ga5gtq6m23x5t17k47wbe.png',
270
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/mv0w504r53gvkx38g3y74pd65k5hktop.png'
271
+ },
272
+ 'gadget:work item statistics': {
273
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4315hi70mlh4eqbn6215p10s4il7os34.png',
274
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/l3120n2755pw6r2o2q24tmsgu6658533.png'
275
+ },
276
+ 'gadget:workload pie chart': {
277
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v5j8p100viey44g61cdc61d53465gda5.png',
278
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/84tce4xo2nqe0712oil1f08n5160a11v.png'
279
+ }
280
+ };
111
281
  const previewImageUrlsByKey = {
112
282
  ...dataAndChartsPreviewImageUrlsByKey,
283
+ ...embedPreviewImageUrlsByKey,
284
+ ...otherPreviewImageUrlsByKey,
113
285
  'profile-picture:profile-picture': {
114
286
  dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/35rb2mbxc2dt8p7op8u8lyss5h220428.png',
115
287
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4o3lpe2eh4nlakav375621i73do50kyx.png'
@@ -138,24 +310,6 @@ const previewImageUrlsByKey = {
138
310
  dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4u6tb8343dv71eotl5462nydlq3544ut.png',
139
311
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/k177s112506n0bn788227s0ig45nko57.png'
140
312
  },
141
- 'third-party-quick-insert-embeds:third-party-embed-amplitude': {
142
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
143
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
144
- },
145
- 'dropbox:item': {
146
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
147
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
148
- },
149
- 'third-party-quick-insert-embeds:third-party-embed-figma': {
150
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
151
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
152
- },
153
- 'third-party-quick-insert-embeds:third-party-embed-google-drive': googleDrivePreviewImageUrls,
154
- 'google-drive:item': googleDrivePreviewImageUrls,
155
- 'iframe:iframe': {
156
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
157
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
158
- },
159
313
  'anchor:anchor': {
160
314
  dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/5f440bb8m37yig3u77s6c8200re8mto0.png',
161
315
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y42w6i56fk22vb3g5120d43qfwte8a78.png'
@@ -193,27 +347,12 @@ const previewImageUrlsByKey = {
193
347
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v8eyy0fvu61fb8a4b4teea4pjs7g2842.png'
194
348
  }
195
349
  };
196
- const previewImageUrlsByTitle = {
197
- amplitude: {
198
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
199
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
200
- },
201
- dropbox: {
202
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
203
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
204
- },
205
- figma: {
206
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
207
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
208
- },
209
- 'google drive': googleDrivePreviewImageUrls,
210
- iframe: {
211
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
212
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
213
- }
214
- };
215
350
  export const getExtensionQuickInsertPreviewImageUrls = item => {
216
- var _ref, _ref2, _ref3;
351
+ var _item$key, _ref, _ref2, _dataAndChartsPreview;
352
+ const snippetKeyPrefix = 'snippet-extension:snippet-';
353
+ if ((_item$key = item.key) !== null && _item$key !== void 0 && _item$key.startsWith(snippetKeyPrefix)) {
354
+ return isExperimentEnabled('platform_editor_slash_command') ? getSnippetPreviewImageUrls(item.key.slice(snippetKeyPrefix.length)) : undefined;
355
+ }
217
356
  const normalizedTitle = item.title.toLowerCase();
218
- return (_ref = (_ref2 = (_ref3 = item.key ? previewImageUrlsByKey[item.key] : undefined) !== null && _ref3 !== void 0 ? _ref3 : item.extensionKey === 'gadget' ? dataAndChartsPreviewImageUrlsByKey[`${item.extensionKey}:${normalizedTitle}`] : undefined) !== null && _ref2 !== void 0 ? _ref2 : item.extensionKey ? dataAndChartsPreviewImageUrlsByKey[item.extensionKey] : undefined) !== null && _ref !== void 0 ? _ref : previewImageUrlsByTitle[normalizedTitle];
357
+ return (_ref = (_ref2 = item.key ? previewImageUrlsByKey[item.key] : undefined) !== null && _ref2 !== void 0 ? _ref2 : item.extensionKey === 'gadget' ? (_dataAndChartsPreview = dataAndChartsPreviewImageUrlsByKey[`${item.extensionKey}:${normalizedTitle}`]) !== null && _dataAndChartsPreview !== void 0 ? _dataAndChartsPreview : otherPreviewImageUrlsByKey[`${item.extensionKey}:${normalizedTitle}`] : undefined) !== null && _ref !== void 0 ? _ref : item.extensionKey ? dataAndChartsPreviewImageUrlsByKey[item.extensionKey] : undefined;
219
358
  };
@@ -1,3 +1,3 @@
1
1
  export const name = "@atlaskit/editor-core";
2
2
  // eslint-disable-next-line @atlaskit/volt-strict-mode/no-multiple-exports
3
- export const version = "229.1.0";
3
+ export const version = "229.1.1";
@@ -1,5 +1,6 @@
1
1
  import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
2
2
  import { sortByOrder } from '@atlaskit/editor-common/legacy-rank-plugins';
3
+ import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
3
4
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
4
5
  import { createEditorNativeAnchorSupportPlugin } from './editorNativeAnchorSupportPlugin';
5
6
  import { createEditorStateNotificationPlugin } from './editorStateNotificationPlugin';
@@ -22,7 +23,7 @@ export function createPMPlugins(config) {
22
23
  }).filter(function (plugin) {
23
24
  return typeof plugin !== 'undefined';
24
25
  });
25
- if (expValEquals('platform_editor_native_anchor_with_dnd', 'isEnabled', true)) {
26
+ if (expValEquals('platform_editor_native_anchor_with_dnd', 'isEnabled', true) || isExperimentEnabled('platform_editor_block_control_migration')) {
26
27
  pmPlugins.push(createEditorNativeAnchorSupportPlugin(config.schema));
27
28
  }
28
29
  if (config.onEditorStateUpdated !== undefined) {
@@ -1,9 +1,29 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  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; }
3
3
  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; }
4
- var googleDrivePreviewImageUrls = {
5
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y01wj4t58w86byx86l6k81a22axud131.png',
6
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/wi413m0837rjykg23r6y0256b7377185.png'
4
+ import { getSnippetPreviewImageUrls } from '@atlaskit/editor-common/quick-insert/snippet-preview-image-urls';
5
+ import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
6
+ var embedPreviewImageUrlsByKey = {
7
+ 'third-party-quick-insert-embeds:third-party-embed-amplitude': {
8
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
9
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
10
+ },
11
+ 'dropbox:item': {
12
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
13
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
14
+ },
15
+ 'third-party-quick-insert-embeds:third-party-embed-figma': {
16
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
17
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
18
+ },
19
+ 'third-party-quick-insert-embeds:third-party-embed-google-drive': {
20
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y01wj4t58w86byx86l6k81a22axud131.png',
21
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/wi413m0837rjykg23r6y0256b7377185.png'
22
+ },
23
+ 'iframe:iframe': {
24
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
25
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
26
+ }
7
27
  };
8
28
  var dataAndChartsPreviewImageUrlsByKey = {
9
29
  'quick-insert-assets-menu-item': {
@@ -111,7 +131,157 @@ var dataAndChartsPreviewImageUrlsByKey = {
111
131
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/o2kexap23ijq8jeqhpvi8lgc51dex3wj.png'
112
132
  }
113
133
  };
114
- var previewImageUrlsByKey = _objectSpread(_objectSpread({}, dataAndChartsPreviewImageUrlsByKey), {}, {
134
+ var otherPreviewImageUrlsByKey = {
135
+ 'excerpt:excerpt': {
136
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/1h408wk0e4x6efhby84hbc583nx5b0b5.png',
137
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0j5s4a60jjbrq3yoa7kfnkft28403127.png'
138
+ },
139
+ 'excerpt-include:excerpt-include': {
140
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/dg718ggxcx60dj7ng86fpqmwbv7vauny.png',
141
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y373d21g768gmvjao5db38kw4460m72r.png'
142
+ },
143
+ 'include:include': {
144
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/s12155hkaoc81aa0eh58y54402s8t346.png',
145
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/61yskd00re82i80b8r6pfxp60pi4852s.png'
146
+ },
147
+ 'jirachart:jirachart': {
148
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/30g82ea1p64616h40s110ysud47dnof6.png',
149
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/114de8qe6dy877s65xh1a2dil1r86x73.png'
150
+ },
151
+ 'jira:jira': {
152
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/8ttib573524136b5lffq3a1go05x507d.png',
153
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pdnn81xj6e8v56nye6rnft3rd4yhnc05.png'
154
+ },
155
+ 'portfolioforjiraplan:portfolioforjiraplan': {
156
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/24g0yt8c54671463162f5q455qcki3id.png',
157
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/c2hy8b245yg1dt2776ol5sx57n045nv0.png'
158
+ },
159
+ 'opsgenie-incident-timeline-eu-macro:opsgenie-incident-timeline-eu-macro': {
160
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qo0u146811738ixd6l13nud48pv57510.png',
161
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qnq1bn07a3k0v4m10hoi487p837obx53.png'
162
+ },
163
+ 'sharelinks-urlmacro:sharelinks-urlmacro': {
164
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0028h1741o411uw4qi8icbg138kus32e.png',
165
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/myhw531c3748qn4ro51vf450vk0qg481.png'
166
+ },
167
+ 'toc-zone:toc-zone': {
168
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/1p16277ig16wc6kelloa542k33b18mm2.png',
169
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/s4q2ap8q4135r0r3i1tym1d5koxdonb1.png'
170
+ },
171
+ 'viewpdf:viewpdf': {
172
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/jt685rp527nfo8jqp6o5o0r31l3rpfux.png',
173
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/30u3v86x652ah52ruhqj1ap0s0ve4ey2.png'
174
+ },
175
+ 'viewxls:viewxls': {
176
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/b11p6ksb8r6j6g2604p67ab53f23u6f5.png',
177
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/r426m140lbp7gs2gxbe015e21kf23j8l.png'
178
+ },
179
+ 'gadget:activity stream': {
180
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v3a1rvva7gxr874o5qah5k61365hod5.png',
181
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/nh7404rduyw5tbne4143426evuk7hvg8.png'
182
+ },
183
+ 'gadget:agile wallboard gadget': {
184
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/n611u81ca8fkyv5nk6cl6j1081e805tr.png',
185
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/3o7vtt14rtpe3sna7mras6oih86nssb6.png'
186
+ },
187
+ 'gadget:assigned to me': {
188
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/d72jy2r18q6v06s13k2f6x3fymrr4on7.png',
189
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/5c62343jh3411ido38440xx0007cx6ls.png'
190
+ },
191
+ 'gadget:average age chart': {
192
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/i53kn1igq64m5dip4eg1030j15yd7xxe.png',
193
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/t136146lvs3x60456gnsghtv730uaftn.png'
194
+ },
195
+ 'gadget:average number of times in status': {
196
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u4v77u1lwcy5g08y047q33dbiv42dkit.png',
197
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/16v2eq2c1df0mrf2jo6xic526527nfh1.png'
198
+ },
199
+ 'gadget:days remaining in sprint gadget': {
200
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/805320gvqd6cbr23yrv271oas2u061s5.png',
201
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/41j35y64652g06uru332kt2a0pk77j03.png'
202
+ },
203
+ 'gadget:filter results': {
204
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/w0n60p750b2275k226gri2j6i366jt0e.png',
205
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/j706ug0u5nk40i1lhrt05j63grc36x0u.png'
206
+ },
207
+ 'gadget:heat map': {
208
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qoepx85h21t4u00cht35nc3ssl4i72j5.png',
209
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/w574xrh77oxbmb18f0ro1bd80x417426.png'
210
+ },
211
+ 'gadget:issues in progress': {
212
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/666u7h3tp16ad4k8u24d4u1155n1v7hg.png',
213
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/go2d8b1qs7h07b17326lx8r8p28jm011.png'
214
+ },
215
+ 'gadget:jira issues calendar': {
216
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/13o0sk45vlf25x1m3w14gsy146k25b14.png',
217
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/j23063ot2a014a2a51y6i0o1keo0kanr.png'
218
+ },
219
+ 'gadget:jira road map': {
220
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/h6u3kb7116jr12w3f586stmc850827h3.png',
221
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/q23v3a23018y2856kew3fsork63bg6p2.png'
222
+ },
223
+ 'gadget:labels gadget': {
224
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7u8gpvv82s3e2833204nm6m1k3301c46.png',
225
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/42hjlte7y364o8y4e5udkl11o22a2ac3.png'
226
+ },
227
+ 'gadget:pie chart': {
228
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v4b6d7to551136834oe1a0xx66n7mv5e.png',
229
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pdq60d803b655il4x3m0co608guc56ub.png'
230
+ },
231
+ 'gadget:quick links': {
232
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/onlh3rc6p0qj15rsysxa3ep5b183hk40.png',
233
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/k51qkw636t010l5h1vrs05c7i073y0xp.png'
234
+ },
235
+ 'gadget:recently created chart': {
236
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/t5in18tcubtbr18yv1gr0ap26x7d6bh3.png',
237
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/ia4jrrsg4mw8tu0gtj88d2yr5w6s20fm.png'
238
+ },
239
+ 'gadget:resolution time': {
240
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/3dek0066jn31qfkk2l2hn011um087y72.png',
241
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/msw0hn3462vvai4l4jkp50xcm87741j6.png'
242
+ },
243
+ 'gadget:sprint burndown gadget': {
244
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2qqrp3vl4rv2p443566826jadj38rfrj.png',
245
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/qic3bcq5sqhd7r00qpj3i6240n3uw3fp.png'
246
+ },
247
+ 'gadget:sprint health gadget': {
248
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/uoqla656675p5wwc3a8v824768lip528.png',
249
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/pnngo5y00g18eos4je3r20ga0c666c68.png'
250
+ },
251
+ 'gadget:time since chart': {
252
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/f7g8053ww4deogfid2h2pj2nw6n8582u.png',
253
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/20wj0kb8mjjj7in0hu62j4ska17ug5s3.png'
254
+ },
255
+ 'gadget:time to first response': {
256
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/l4cy50n75hr166cpohxpd3h5038e8sl7.png',
257
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/8kkdphd2l3gb7w06dboc82rmtm86xk7r.png'
258
+ },
259
+ 'gadget:two dimensional filter statistics': {
260
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/6s1x266h56m7p4q758jem2k03hbu15gb.png',
261
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/hjt70wg3tds43ev34nxv1r7l50170f4l.png'
262
+ },
263
+ 'gadget:version report': {
264
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2143nj51e834657316q5n5j6kbq3h3m7.png',
265
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/rgi5il8d845k40f65w0f8a678c1rf51q.png'
266
+ },
267
+ 'gadget:voted work items': {
268
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/0n262m847lgjj174x658ps04k6j513r6.png',
269
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/rcn6qrr638k1v5y6xrw8g512f2530244.png'
270
+ },
271
+ 'gadget:watched issues': {
272
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v418o500l40ga5gtq6m23x5t17k47wbe.png',
273
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/mv0w504r53gvkx38g3y74pd65k5hktop.png'
274
+ },
275
+ 'gadget:work item statistics': {
276
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4315hi70mlh4eqbn6215p10s4il7os34.png',
277
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/l3120n2755pw6r2o2q24tmsgu6658533.png'
278
+ },
279
+ 'gadget:workload pie chart': {
280
+ dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v5j8p100viey44g61cdc61d53465gda5.png',
281
+ light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/84tce4xo2nqe0712oil1f08n5160a11v.png'
282
+ }
283
+ };
284
+ var previewImageUrlsByKey = _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, dataAndChartsPreviewImageUrlsByKey), embedPreviewImageUrlsByKey), otherPreviewImageUrlsByKey), {}, {
115
285
  'profile-picture:profile-picture': {
116
286
  dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/35rb2mbxc2dt8p7op8u8lyss5h220428.png',
117
287
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4o3lpe2eh4nlakav375621i73do50kyx.png'
@@ -140,24 +310,6 @@ var previewImageUrlsByKey = _objectSpread(_objectSpread({}, dataAndChartsPreview
140
310
  dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/4u6tb8343dv71eotl5462nydlq3544ut.png',
141
311
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/k177s112506n0bn788227s0ig45nko57.png'
142
312
  },
143
- 'third-party-quick-insert-embeds:third-party-embed-amplitude': {
144
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
145
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
146
- },
147
- 'dropbox:item': {
148
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
149
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
150
- },
151
- 'third-party-quick-insert-embeds:third-party-embed-figma': {
152
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
153
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
154
- },
155
- 'third-party-quick-insert-embeds:third-party-embed-google-drive': googleDrivePreviewImageUrls,
156
- 'google-drive:item': googleDrivePreviewImageUrls,
157
- 'iframe:iframe': {
158
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
159
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
160
- },
161
313
  'anchor:anchor': {
162
314
  dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/5f440bb8m37yig3u77s6c8200re8mto0.png',
163
315
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/y42w6i56fk22vb3g5120d43qfwte8a78.png'
@@ -195,27 +347,12 @@ var previewImageUrlsByKey = _objectSpread(_objectSpread({}, dataAndChartsPreview
195
347
  light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/v8eyy0fvu61fb8a4b4teea4pjs7g2842.png'
196
348
  }
197
349
  });
198
- var previewImageUrlsByTitle = {
199
- amplitude: {
200
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/7v8shu6n3wd15644f3ys785628dkt632.png',
201
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/2r34o120k40e0us4w66oqpud63o4lef4.png'
202
- },
203
- dropbox: {
204
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/83f1773ur08qm4t3bqaabpwb173313tg.png',
205
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/37v2dk5n1ltwc82j1w76dv1tyr8puwq0.png'
206
- },
207
- figma: {
208
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/svedc2lju60bgq3r43kfmi7213wj46as.png',
209
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/u80s30071b4c10vdjr5rw0uje8cu2pk7.png'
210
- },
211
- 'google drive': googleDrivePreviewImageUrls,
212
- iframe: {
213
- dark: 'https://dam-cdn.atl.orangelogic.com/AssetLink/77p6d5rb343gue8580bacbl0xf82u5jv.png',
214
- light: 'https://dam-cdn.atl.orangelogic.com/AssetLink/72a0j8eddxg82rnp8j48bipi8sq8g0ke.png'
215
- }
216
- };
217
350
  export var getExtensionQuickInsertPreviewImageUrls = function getExtensionQuickInsertPreviewImageUrls(item) {
218
- var _ref, _ref2, _ref3;
351
+ var _item$key, _ref, _ref2, _dataAndChartsPreview;
352
+ var snippetKeyPrefix = 'snippet-extension:snippet-';
353
+ if ((_item$key = item.key) !== null && _item$key !== void 0 && _item$key.startsWith(snippetKeyPrefix)) {
354
+ return isExperimentEnabled('platform_editor_slash_command') ? getSnippetPreviewImageUrls(item.key.slice(snippetKeyPrefix.length)) : undefined;
355
+ }
219
356
  var normalizedTitle = item.title.toLowerCase();
220
- return (_ref = (_ref2 = (_ref3 = item.key ? previewImageUrlsByKey[item.key] : undefined) !== null && _ref3 !== void 0 ? _ref3 : item.extensionKey === 'gadget' ? dataAndChartsPreviewImageUrlsByKey["".concat(item.extensionKey, ":").concat(normalizedTitle)] : undefined) !== null && _ref2 !== void 0 ? _ref2 : item.extensionKey ? dataAndChartsPreviewImageUrlsByKey[item.extensionKey] : undefined) !== null && _ref !== void 0 ? _ref : previewImageUrlsByTitle[normalizedTitle];
357
+ return (_ref = (_ref2 = item.key ? previewImageUrlsByKey[item.key] : undefined) !== null && _ref2 !== void 0 ? _ref2 : item.extensionKey === 'gadget' ? (_dataAndChartsPreview = dataAndChartsPreviewImageUrlsByKey["".concat(item.extensionKey, ":").concat(normalizedTitle)]) !== null && _dataAndChartsPreview !== void 0 ? _dataAndChartsPreview : otherPreviewImageUrlsByKey["".concat(item.extensionKey, ":").concat(normalizedTitle)] : undefined) !== null && _ref !== void 0 ? _ref : item.extensionKey ? dataAndChartsPreviewImageUrlsByKey[item.extensionKey] : undefined;
221
358
  };
@@ -1,3 +1,3 @@
1
1
  export var name = "@atlaskit/editor-core";
2
2
  // eslint-disable-next-line @atlaskit/volt-strict-mode/no-multiple-exports
3
- export var version = "229.1.0";
3
+ export var version = "229.1.1";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-core",
3
- "version": "229.1.1",
3
+ "version": "229.1.2",
4
4
  "description": "A package contains Atlassian editor core functionality",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -47,7 +47,7 @@
47
47
  "@atlaskit/analytics-next": "^12.5.0",
48
48
  "@atlaskit/analytics-next-stable-react-context": "1.0.1",
49
49
  "@atlaskit/browser-apis": "^1.2.0",
50
- "@atlaskit/button": "^25.3.0",
50
+ "@atlaskit/button": "^25.4.0",
51
51
  "@atlaskit/css": "^1.1.0",
52
52
  "@atlaskit/editor-json-transformer": "^9.8.0",
53
53
  "@atlaskit/editor-plugin-block-menu": "^18.0.0",
@@ -96,7 +96,7 @@
96
96
  "uuid": "^11.1.1"
97
97
  },
98
98
  "peerDependencies": {
99
- "@atlaskit/editor-common": "^123.2.0",
99
+ "@atlaskit/editor-common": "^123.3.0",
100
100
  "@atlaskit/link-provider": "^5.7.0",
101
101
  "@atlaskit/media-core": "^38.2.0",
102
102
  "react": "^18.2.0 || ^19.2.0",