@atlaskit/editor-plugin-insert-block 8.3.2 → 8.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/dist/cjs/ui/toolbar-components.js +115 -150
- package/dist/es2019/ui/toolbar-components.js +110 -143
- package/dist/esm/ui/toolbar-components.js +115 -150
- package/package.json +3 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-insert-block
|
|
2
2
|
|
|
3
|
+
## 8.3.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`6431f5f6492ae`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/6431f5f6492ae) -
|
|
8
|
+
Remove unused platform_editor_toolbar_aifc_ga_blockers feature gate
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
|
|
3
11
|
## 8.3.2
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -279,166 +279,131 @@ var getToolbarComponents = exports.getToolbarComponents = function getToolbarCom
|
|
|
279
279
|
});
|
|
280
280
|
};
|
|
281
281
|
};
|
|
282
|
-
|
|
283
|
-
|
|
282
|
+
components.push({
|
|
283
|
+
type: _toolbar.INSERT_GROUP.type,
|
|
284
|
+
key: "".concat(_toolbar.INSERT_GROUP.key, "-none"),
|
|
285
|
+
parents: [{
|
|
286
|
+
type: _toolbar.INSERT_BLOCK_SECTION.type,
|
|
287
|
+
key: _toolbar.INSERT_BLOCK_SECTION.key,
|
|
288
|
+
rank: _toolbar.INSERT_BLOCK_SECTION_RANK[_toolbar.INSERT_GROUP.key]
|
|
289
|
+
}],
|
|
290
|
+
component: function component(_ref3) {
|
|
291
|
+
var children = _ref3.children;
|
|
292
|
+
return /*#__PURE__*/_react.default.createElement(_editorToolbar.Show, {
|
|
293
|
+
below: "sm"
|
|
294
|
+
}, /*#__PURE__*/_react.default.createElement(_editorToolbar.ToolbarButtonGroup, null, children));
|
|
295
|
+
}
|
|
296
|
+
});
|
|
297
|
+
components.push({
|
|
298
|
+
type: _toolbar.INSERT_BUTTON.type,
|
|
299
|
+
key: _toolbar.INSERT_BUTTON.key,
|
|
300
|
+
parents: [{
|
|
284
301
|
type: _toolbar.INSERT_GROUP.type,
|
|
285
302
|
key: "".concat(_toolbar.INSERT_GROUP.key, "-none"),
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
}
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
303
|
+
rank: _toolbar.INSERT_GROUP_RANK[_toolbar.INSERT_BUTTON.key]
|
|
304
|
+
}],
|
|
305
|
+
component: createInsertButtonComponent(null)
|
|
306
|
+
});
|
|
307
|
+
components.push({
|
|
308
|
+
type: _toolbar.INSERT_GROUP.type,
|
|
309
|
+
key: "".concat(_toolbar.INSERT_GROUP.key, "-sm"),
|
|
310
|
+
parents: [{
|
|
311
|
+
type: _toolbar.INSERT_BLOCK_SECTION.type,
|
|
312
|
+
key: _toolbar.INSERT_BLOCK_SECTION.key,
|
|
313
|
+
rank: _toolbar.INSERT_BLOCK_SECTION_RANK[_toolbar.INSERT_GROUP.key]
|
|
314
|
+
}],
|
|
315
|
+
component: function component(_ref4) {
|
|
316
|
+
var children = _ref4.children;
|
|
317
|
+
return /*#__PURE__*/_react.default.createElement(_editorToolbar.Show, {
|
|
318
|
+
only: "sm"
|
|
319
|
+
}, /*#__PURE__*/_react.default.createElement(_editorToolbar.ToolbarButtonGroup, null, children));
|
|
320
|
+
}
|
|
321
|
+
});
|
|
322
|
+
components.push({
|
|
323
|
+
type: _toolbar.INSERT_BUTTON.type,
|
|
324
|
+
key: _toolbar.INSERT_BUTTON.key,
|
|
325
|
+
parents: [{
|
|
309
326
|
type: _toolbar.INSERT_GROUP.type,
|
|
310
327
|
key: "".concat(_toolbar.INSERT_GROUP.key, "-sm"),
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
}
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
328
|
+
rank: _toolbar.INSERT_GROUP_RANK[_toolbar.INSERT_BUTTON.key]
|
|
329
|
+
}],
|
|
330
|
+
component: createInsertButtonComponent('sm')
|
|
331
|
+
});
|
|
332
|
+
components.push({
|
|
333
|
+
type: _toolbar.INSERT_GROUP.type,
|
|
334
|
+
key: "".concat(_toolbar.INSERT_GROUP.key, "-md"),
|
|
335
|
+
parents: [{
|
|
336
|
+
type: _toolbar.INSERT_BLOCK_SECTION.type,
|
|
337
|
+
key: _toolbar.INSERT_BLOCK_SECTION.key,
|
|
338
|
+
rank: _toolbar.INSERT_BLOCK_SECTION_RANK[_toolbar.INSERT_GROUP.key]
|
|
339
|
+
}],
|
|
340
|
+
component: function component(_ref5) {
|
|
341
|
+
var children = _ref5.children;
|
|
342
|
+
return /*#__PURE__*/_react.default.createElement(_editorToolbar.Show, {
|
|
343
|
+
only: "md"
|
|
344
|
+
}, /*#__PURE__*/_react.default.createElement(_editorToolbar.ToolbarButtonGroup, null, children));
|
|
345
|
+
}
|
|
346
|
+
});
|
|
347
|
+
components.push({
|
|
348
|
+
type: _toolbar.INSERT_BUTTON.type,
|
|
349
|
+
key: _toolbar.INSERT_BUTTON.key,
|
|
350
|
+
parents: [{
|
|
334
351
|
type: _toolbar.INSERT_GROUP.type,
|
|
335
352
|
key: "".concat(_toolbar.INSERT_GROUP.key, "-md"),
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
}
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
353
|
+
rank: _toolbar.INSERT_GROUP_RANK[_toolbar.INSERT_BUTTON.key]
|
|
354
|
+
}],
|
|
355
|
+
component: createInsertButtonComponent('md')
|
|
356
|
+
});
|
|
357
|
+
components.push({
|
|
358
|
+
type: _toolbar.INSERT_GROUP.type,
|
|
359
|
+
key: "".concat(_toolbar.INSERT_GROUP.key, "-lg"),
|
|
360
|
+
parents: [{
|
|
361
|
+
type: _toolbar.INSERT_BLOCK_SECTION.type,
|
|
362
|
+
key: _toolbar.INSERT_BLOCK_SECTION.key,
|
|
363
|
+
rank: _toolbar.INSERT_BLOCK_SECTION_RANK[_toolbar.INSERT_GROUP.key]
|
|
364
|
+
}],
|
|
365
|
+
component: function component(_ref6) {
|
|
366
|
+
var children = _ref6.children;
|
|
367
|
+
return /*#__PURE__*/_react.default.createElement(_editorToolbar.Show, {
|
|
368
|
+
only: "lg"
|
|
369
|
+
}, /*#__PURE__*/_react.default.createElement(_editorToolbar.ToolbarButtonGroup, null, children));
|
|
370
|
+
}
|
|
371
|
+
});
|
|
372
|
+
components.push({
|
|
373
|
+
type: _toolbar.INSERT_BUTTON.type,
|
|
374
|
+
key: _toolbar.INSERT_BUTTON.key,
|
|
375
|
+
parents: [{
|
|
359
376
|
type: _toolbar.INSERT_GROUP.type,
|
|
360
377
|
key: "".concat(_toolbar.INSERT_GROUP.key, "-lg"),
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
}
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
378
|
+
rank: _toolbar.INSERT_GROUP_RANK[_toolbar.INSERT_BUTTON.key]
|
|
379
|
+
}],
|
|
380
|
+
component: createInsertButtonComponent('lg')
|
|
381
|
+
});
|
|
382
|
+
components.push({
|
|
383
|
+
type: _toolbar.INSERT_GROUP.type,
|
|
384
|
+
key: "".concat(_toolbar.INSERT_GROUP.key, "-xl"),
|
|
385
|
+
parents: [{
|
|
386
|
+
type: _toolbar.INSERT_BLOCK_SECTION.type,
|
|
387
|
+
key: _toolbar.INSERT_BLOCK_SECTION.key,
|
|
388
|
+
rank: _toolbar.INSERT_BLOCK_SECTION_RANK[_toolbar.INSERT_GROUP.key]
|
|
389
|
+
}],
|
|
390
|
+
component: function component(_ref7) {
|
|
391
|
+
var children = _ref7.children;
|
|
392
|
+
return /*#__PURE__*/_react.default.createElement(_editorToolbar.Show, {
|
|
393
|
+
only: "xl"
|
|
394
|
+
}, /*#__PURE__*/_react.default.createElement(_editorToolbar.ToolbarButtonGroup, null, children));
|
|
395
|
+
}
|
|
396
|
+
});
|
|
397
|
+
components.push({
|
|
398
|
+
type: _toolbar.INSERT_BUTTON.type,
|
|
399
|
+
key: _toolbar.INSERT_BUTTON.key,
|
|
400
|
+
parents: [{
|
|
384
401
|
type: _toolbar.INSERT_GROUP.type,
|
|
385
402
|
key: "".concat(_toolbar.INSERT_GROUP.key, "-xl"),
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
}],
|
|
391
|
-
component: function component(_ref7) {
|
|
392
|
-
var children = _ref7.children;
|
|
393
|
-
return /*#__PURE__*/_react.default.createElement(_editorToolbar.Show, {
|
|
394
|
-
only: "xl"
|
|
395
|
-
}, /*#__PURE__*/_react.default.createElement(_editorToolbar.ToolbarButtonGroup, null, children));
|
|
396
|
-
}
|
|
397
|
-
});
|
|
398
|
-
components.push({
|
|
399
|
-
type: _toolbar.INSERT_BUTTON.type,
|
|
400
|
-
key: _toolbar.INSERT_BUTTON.key,
|
|
401
|
-
parents: [{
|
|
402
|
-
type: _toolbar.INSERT_GROUP.type,
|
|
403
|
-
key: "".concat(_toolbar.INSERT_GROUP.key, "-xl"),
|
|
404
|
-
rank: _toolbar.INSERT_GROUP_RANK[_toolbar.INSERT_BUTTON.key]
|
|
405
|
-
}],
|
|
406
|
-
component: createInsertButtonComponent('xl')
|
|
407
|
-
});
|
|
408
|
-
} else {
|
|
409
|
-
components.push({
|
|
410
|
-
type: _toolbar.INSERT_GROUP.type,
|
|
411
|
-
key: _toolbar.INSERT_GROUP.key,
|
|
412
|
-
parents: [{
|
|
413
|
-
type: _toolbar.INSERT_BLOCK_SECTION.type,
|
|
414
|
-
key: _toolbar.INSERT_BLOCK_SECTION.key,
|
|
415
|
-
rank: _toolbar.INSERT_BLOCK_SECTION_RANK[_toolbar.INSERT_GROUP.key]
|
|
416
|
-
}]
|
|
417
|
-
});
|
|
418
|
-
components.push({
|
|
419
|
-
type: _toolbar.INSERT_BUTTON.type,
|
|
420
|
-
key: _toolbar.INSERT_BUTTON.key,
|
|
421
|
-
parents: [{
|
|
422
|
-
type: _toolbar.INSERT_GROUP.type,
|
|
423
|
-
key: _toolbar.INSERT_GROUP.key,
|
|
424
|
-
rank: _toolbar.INSERT_GROUP_RANK[_toolbar.INSERT_BUTTON.key]
|
|
425
|
-
}],
|
|
426
|
-
component: function component() {
|
|
427
|
-
return /*#__PURE__*/_react.default.createElement(_InsertButton.InsertButton, {
|
|
428
|
-
api: api,
|
|
429
|
-
toolbarConfig: config,
|
|
430
|
-
showElementBrowserLink: options.showElementBrowserLink,
|
|
431
|
-
tableSelectorSupported: options.tableSelectorSupported,
|
|
432
|
-
onInsertBlockType: onInsertBlockType,
|
|
433
|
-
nativeStatusSupported: options.nativeStatusSupported,
|
|
434
|
-
horizontalRuleEnabled: options.horizontalRuleEnabled,
|
|
435
|
-
expandEnabled: options.allowExpand,
|
|
436
|
-
insertMenuItems: options.insertMenuItems,
|
|
437
|
-
numberOfButtons: 7 // TODO: ED-28759 - Default to 7 buttons - Remove this once we have a proper way to do toolbar responsiveness
|
|
438
|
-
});
|
|
439
|
-
}
|
|
440
|
-
});
|
|
441
|
-
}
|
|
403
|
+
rank: _toolbar.INSERT_GROUP_RANK[_toolbar.INSERT_BUTTON.key]
|
|
404
|
+
}],
|
|
405
|
+
component: createInsertButtonComponent('xl')
|
|
406
|
+
});
|
|
442
407
|
}
|
|
443
408
|
return components;
|
|
444
409
|
};
|
|
@@ -254,159 +254,126 @@ export const getToolbarComponents = ({
|
|
|
254
254
|
numberOfButtons: 0
|
|
255
255
|
});
|
|
256
256
|
};
|
|
257
|
-
|
|
258
|
-
|
|
257
|
+
components.push({
|
|
258
|
+
type: INSERT_GROUP.type,
|
|
259
|
+
key: `${INSERT_GROUP.key}-none`,
|
|
260
|
+
parents: [{
|
|
261
|
+
type: INSERT_BLOCK_SECTION.type,
|
|
262
|
+
key: INSERT_BLOCK_SECTION.key,
|
|
263
|
+
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
264
|
+
}],
|
|
265
|
+
component: ({
|
|
266
|
+
children
|
|
267
|
+
}) => /*#__PURE__*/React.createElement(Show, {
|
|
268
|
+
below: "sm"
|
|
269
|
+
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children))
|
|
270
|
+
});
|
|
271
|
+
components.push({
|
|
272
|
+
type: INSERT_BUTTON.type,
|
|
273
|
+
key: INSERT_BUTTON.key,
|
|
274
|
+
parents: [{
|
|
259
275
|
type: INSERT_GROUP.type,
|
|
260
276
|
key: `${INSERT_GROUP.key}-none`,
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
277
|
+
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
278
|
+
}],
|
|
279
|
+
component: createInsertButtonComponent(null)
|
|
280
|
+
});
|
|
281
|
+
components.push({
|
|
282
|
+
type: INSERT_GROUP.type,
|
|
283
|
+
key: `${INSERT_GROUP.key}-sm`,
|
|
284
|
+
parents: [{
|
|
285
|
+
type: INSERT_BLOCK_SECTION.type,
|
|
286
|
+
key: INSERT_BLOCK_SECTION.key,
|
|
287
|
+
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
288
|
+
}],
|
|
289
|
+
component: ({
|
|
290
|
+
children
|
|
291
|
+
}) => /*#__PURE__*/React.createElement(Show, {
|
|
292
|
+
only: "sm"
|
|
293
|
+
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children))
|
|
294
|
+
});
|
|
295
|
+
components.push({
|
|
296
|
+
type: INSERT_BUTTON.type,
|
|
297
|
+
key: INSERT_BUTTON.key,
|
|
298
|
+
parents: [{
|
|
283
299
|
type: INSERT_GROUP.type,
|
|
284
300
|
key: `${INSERT_GROUP.key}-sm`,
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
301
|
+
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
302
|
+
}],
|
|
303
|
+
component: createInsertButtonComponent('sm')
|
|
304
|
+
});
|
|
305
|
+
components.push({
|
|
306
|
+
type: INSERT_GROUP.type,
|
|
307
|
+
key: `${INSERT_GROUP.key}-md`,
|
|
308
|
+
parents: [{
|
|
309
|
+
type: INSERT_BLOCK_SECTION.type,
|
|
310
|
+
key: INSERT_BLOCK_SECTION.key,
|
|
311
|
+
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
312
|
+
}],
|
|
313
|
+
component: ({
|
|
314
|
+
children
|
|
315
|
+
}) => /*#__PURE__*/React.createElement(Show, {
|
|
316
|
+
only: "md"
|
|
317
|
+
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children))
|
|
318
|
+
});
|
|
319
|
+
components.push({
|
|
320
|
+
type: INSERT_BUTTON.type,
|
|
321
|
+
key: INSERT_BUTTON.key,
|
|
322
|
+
parents: [{
|
|
307
323
|
type: INSERT_GROUP.type,
|
|
308
324
|
key: `${INSERT_GROUP.key}-md`,
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
325
|
+
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
326
|
+
}],
|
|
327
|
+
component: createInsertButtonComponent('md')
|
|
328
|
+
});
|
|
329
|
+
components.push({
|
|
330
|
+
type: INSERT_GROUP.type,
|
|
331
|
+
key: `${INSERT_GROUP.key}-lg`,
|
|
332
|
+
parents: [{
|
|
333
|
+
type: INSERT_BLOCK_SECTION.type,
|
|
334
|
+
key: INSERT_BLOCK_SECTION.key,
|
|
335
|
+
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
336
|
+
}],
|
|
337
|
+
component: ({
|
|
338
|
+
children
|
|
339
|
+
}) => /*#__PURE__*/React.createElement(Show, {
|
|
340
|
+
only: "lg"
|
|
341
|
+
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children))
|
|
342
|
+
});
|
|
343
|
+
components.push({
|
|
344
|
+
type: INSERT_BUTTON.type,
|
|
345
|
+
key: INSERT_BUTTON.key,
|
|
346
|
+
parents: [{
|
|
331
347
|
type: INSERT_GROUP.type,
|
|
332
348
|
key: `${INSERT_GROUP.key}-lg`,
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
349
|
+
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
350
|
+
}],
|
|
351
|
+
component: createInsertButtonComponent('lg')
|
|
352
|
+
});
|
|
353
|
+
components.push({
|
|
354
|
+
type: INSERT_GROUP.type,
|
|
355
|
+
key: `${INSERT_GROUP.key}-xl`,
|
|
356
|
+
parents: [{
|
|
357
|
+
type: INSERT_BLOCK_SECTION.type,
|
|
358
|
+
key: INSERT_BLOCK_SECTION.key,
|
|
359
|
+
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
360
|
+
}],
|
|
361
|
+
component: ({
|
|
362
|
+
children
|
|
363
|
+
}) => /*#__PURE__*/React.createElement(Show, {
|
|
364
|
+
only: "xl"
|
|
365
|
+
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children))
|
|
366
|
+
});
|
|
367
|
+
components.push({
|
|
368
|
+
type: INSERT_BUTTON.type,
|
|
369
|
+
key: INSERT_BUTTON.key,
|
|
370
|
+
parents: [{
|
|
355
371
|
type: INSERT_GROUP.type,
|
|
356
372
|
key: `${INSERT_GROUP.key}-xl`,
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
}],
|
|
362
|
-
component: ({
|
|
363
|
-
children
|
|
364
|
-
}) => /*#__PURE__*/React.createElement(Show, {
|
|
365
|
-
only: "xl"
|
|
366
|
-
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children))
|
|
367
|
-
});
|
|
368
|
-
components.push({
|
|
369
|
-
type: INSERT_BUTTON.type,
|
|
370
|
-
key: INSERT_BUTTON.key,
|
|
371
|
-
parents: [{
|
|
372
|
-
type: INSERT_GROUP.type,
|
|
373
|
-
key: `${INSERT_GROUP.key}-xl`,
|
|
374
|
-
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
375
|
-
}],
|
|
376
|
-
component: createInsertButtonComponent('xl')
|
|
377
|
-
});
|
|
378
|
-
} else {
|
|
379
|
-
components.push({
|
|
380
|
-
type: INSERT_GROUP.type,
|
|
381
|
-
key: INSERT_GROUP.key,
|
|
382
|
-
parents: [{
|
|
383
|
-
type: INSERT_BLOCK_SECTION.type,
|
|
384
|
-
key: INSERT_BLOCK_SECTION.key,
|
|
385
|
-
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
386
|
-
}]
|
|
387
|
-
});
|
|
388
|
-
components.push({
|
|
389
|
-
type: INSERT_BUTTON.type,
|
|
390
|
-
key: INSERT_BUTTON.key,
|
|
391
|
-
parents: [{
|
|
392
|
-
type: INSERT_GROUP.type,
|
|
393
|
-
key: INSERT_GROUP.key,
|
|
394
|
-
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
395
|
-
}],
|
|
396
|
-
component: () => /*#__PURE__*/React.createElement(InsertButton, {
|
|
397
|
-
api: api,
|
|
398
|
-
toolbarConfig: config,
|
|
399
|
-
showElementBrowserLink: options.showElementBrowserLink,
|
|
400
|
-
tableSelectorSupported: options.tableSelectorSupported,
|
|
401
|
-
onInsertBlockType: onInsertBlockType,
|
|
402
|
-
nativeStatusSupported: options.nativeStatusSupported,
|
|
403
|
-
horizontalRuleEnabled: options.horizontalRuleEnabled,
|
|
404
|
-
expandEnabled: options.allowExpand,
|
|
405
|
-
insertMenuItems: options.insertMenuItems,
|
|
406
|
-
numberOfButtons: 7 // TODO: ED-28759 - Default to 7 buttons - Remove this once we have a proper way to do toolbar responsiveness
|
|
407
|
-
})
|
|
408
|
-
});
|
|
409
|
-
}
|
|
373
|
+
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
374
|
+
}],
|
|
375
|
+
component: createInsertButtonComponent('xl')
|
|
376
|
+
});
|
|
410
377
|
}
|
|
411
378
|
return components;
|
|
412
379
|
};
|
|
@@ -272,166 +272,131 @@ export var getToolbarComponents = function getToolbarComponents(_ref) {
|
|
|
272
272
|
});
|
|
273
273
|
};
|
|
274
274
|
};
|
|
275
|
-
|
|
276
|
-
|
|
275
|
+
components.push({
|
|
276
|
+
type: INSERT_GROUP.type,
|
|
277
|
+
key: "".concat(INSERT_GROUP.key, "-none"),
|
|
278
|
+
parents: [{
|
|
279
|
+
type: INSERT_BLOCK_SECTION.type,
|
|
280
|
+
key: INSERT_BLOCK_SECTION.key,
|
|
281
|
+
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
282
|
+
}],
|
|
283
|
+
component: function component(_ref3) {
|
|
284
|
+
var children = _ref3.children;
|
|
285
|
+
return /*#__PURE__*/React.createElement(Show, {
|
|
286
|
+
below: "sm"
|
|
287
|
+
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children));
|
|
288
|
+
}
|
|
289
|
+
});
|
|
290
|
+
components.push({
|
|
291
|
+
type: INSERT_BUTTON.type,
|
|
292
|
+
key: INSERT_BUTTON.key,
|
|
293
|
+
parents: [{
|
|
277
294
|
type: INSERT_GROUP.type,
|
|
278
295
|
key: "".concat(INSERT_GROUP.key, "-none"),
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
}
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
296
|
+
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
297
|
+
}],
|
|
298
|
+
component: createInsertButtonComponent(null)
|
|
299
|
+
});
|
|
300
|
+
components.push({
|
|
301
|
+
type: INSERT_GROUP.type,
|
|
302
|
+
key: "".concat(INSERT_GROUP.key, "-sm"),
|
|
303
|
+
parents: [{
|
|
304
|
+
type: INSERT_BLOCK_SECTION.type,
|
|
305
|
+
key: INSERT_BLOCK_SECTION.key,
|
|
306
|
+
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
307
|
+
}],
|
|
308
|
+
component: function component(_ref4) {
|
|
309
|
+
var children = _ref4.children;
|
|
310
|
+
return /*#__PURE__*/React.createElement(Show, {
|
|
311
|
+
only: "sm"
|
|
312
|
+
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children));
|
|
313
|
+
}
|
|
314
|
+
});
|
|
315
|
+
components.push({
|
|
316
|
+
type: INSERT_BUTTON.type,
|
|
317
|
+
key: INSERT_BUTTON.key,
|
|
318
|
+
parents: [{
|
|
302
319
|
type: INSERT_GROUP.type,
|
|
303
320
|
key: "".concat(INSERT_GROUP.key, "-sm"),
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
}
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
321
|
+
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
322
|
+
}],
|
|
323
|
+
component: createInsertButtonComponent('sm')
|
|
324
|
+
});
|
|
325
|
+
components.push({
|
|
326
|
+
type: INSERT_GROUP.type,
|
|
327
|
+
key: "".concat(INSERT_GROUP.key, "-md"),
|
|
328
|
+
parents: [{
|
|
329
|
+
type: INSERT_BLOCK_SECTION.type,
|
|
330
|
+
key: INSERT_BLOCK_SECTION.key,
|
|
331
|
+
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
332
|
+
}],
|
|
333
|
+
component: function component(_ref5) {
|
|
334
|
+
var children = _ref5.children;
|
|
335
|
+
return /*#__PURE__*/React.createElement(Show, {
|
|
336
|
+
only: "md"
|
|
337
|
+
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children));
|
|
338
|
+
}
|
|
339
|
+
});
|
|
340
|
+
components.push({
|
|
341
|
+
type: INSERT_BUTTON.type,
|
|
342
|
+
key: INSERT_BUTTON.key,
|
|
343
|
+
parents: [{
|
|
327
344
|
type: INSERT_GROUP.type,
|
|
328
345
|
key: "".concat(INSERT_GROUP.key, "-md"),
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
}
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
346
|
+
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
347
|
+
}],
|
|
348
|
+
component: createInsertButtonComponent('md')
|
|
349
|
+
});
|
|
350
|
+
components.push({
|
|
351
|
+
type: INSERT_GROUP.type,
|
|
352
|
+
key: "".concat(INSERT_GROUP.key, "-lg"),
|
|
353
|
+
parents: [{
|
|
354
|
+
type: INSERT_BLOCK_SECTION.type,
|
|
355
|
+
key: INSERT_BLOCK_SECTION.key,
|
|
356
|
+
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
357
|
+
}],
|
|
358
|
+
component: function component(_ref6) {
|
|
359
|
+
var children = _ref6.children;
|
|
360
|
+
return /*#__PURE__*/React.createElement(Show, {
|
|
361
|
+
only: "lg"
|
|
362
|
+
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children));
|
|
363
|
+
}
|
|
364
|
+
});
|
|
365
|
+
components.push({
|
|
366
|
+
type: INSERT_BUTTON.type,
|
|
367
|
+
key: INSERT_BUTTON.key,
|
|
368
|
+
parents: [{
|
|
352
369
|
type: INSERT_GROUP.type,
|
|
353
370
|
key: "".concat(INSERT_GROUP.key, "-lg"),
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
}
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
371
|
+
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
372
|
+
}],
|
|
373
|
+
component: createInsertButtonComponent('lg')
|
|
374
|
+
});
|
|
375
|
+
components.push({
|
|
376
|
+
type: INSERT_GROUP.type,
|
|
377
|
+
key: "".concat(INSERT_GROUP.key, "-xl"),
|
|
378
|
+
parents: [{
|
|
379
|
+
type: INSERT_BLOCK_SECTION.type,
|
|
380
|
+
key: INSERT_BLOCK_SECTION.key,
|
|
381
|
+
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
382
|
+
}],
|
|
383
|
+
component: function component(_ref7) {
|
|
384
|
+
var children = _ref7.children;
|
|
385
|
+
return /*#__PURE__*/React.createElement(Show, {
|
|
386
|
+
only: "xl"
|
|
387
|
+
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children));
|
|
388
|
+
}
|
|
389
|
+
});
|
|
390
|
+
components.push({
|
|
391
|
+
type: INSERT_BUTTON.type,
|
|
392
|
+
key: INSERT_BUTTON.key,
|
|
393
|
+
parents: [{
|
|
377
394
|
type: INSERT_GROUP.type,
|
|
378
395
|
key: "".concat(INSERT_GROUP.key, "-xl"),
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
}],
|
|
384
|
-
component: function component(_ref7) {
|
|
385
|
-
var children = _ref7.children;
|
|
386
|
-
return /*#__PURE__*/React.createElement(Show, {
|
|
387
|
-
only: "xl"
|
|
388
|
-
}, /*#__PURE__*/React.createElement(ToolbarButtonGroup, null, children));
|
|
389
|
-
}
|
|
390
|
-
});
|
|
391
|
-
components.push({
|
|
392
|
-
type: INSERT_BUTTON.type,
|
|
393
|
-
key: INSERT_BUTTON.key,
|
|
394
|
-
parents: [{
|
|
395
|
-
type: INSERT_GROUP.type,
|
|
396
|
-
key: "".concat(INSERT_GROUP.key, "-xl"),
|
|
397
|
-
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
398
|
-
}],
|
|
399
|
-
component: createInsertButtonComponent('xl')
|
|
400
|
-
});
|
|
401
|
-
} else {
|
|
402
|
-
components.push({
|
|
403
|
-
type: INSERT_GROUP.type,
|
|
404
|
-
key: INSERT_GROUP.key,
|
|
405
|
-
parents: [{
|
|
406
|
-
type: INSERT_BLOCK_SECTION.type,
|
|
407
|
-
key: INSERT_BLOCK_SECTION.key,
|
|
408
|
-
rank: INSERT_BLOCK_SECTION_RANK[INSERT_GROUP.key]
|
|
409
|
-
}]
|
|
410
|
-
});
|
|
411
|
-
components.push({
|
|
412
|
-
type: INSERT_BUTTON.type,
|
|
413
|
-
key: INSERT_BUTTON.key,
|
|
414
|
-
parents: [{
|
|
415
|
-
type: INSERT_GROUP.type,
|
|
416
|
-
key: INSERT_GROUP.key,
|
|
417
|
-
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
418
|
-
}],
|
|
419
|
-
component: function component() {
|
|
420
|
-
return /*#__PURE__*/React.createElement(InsertButton, {
|
|
421
|
-
api: api,
|
|
422
|
-
toolbarConfig: config,
|
|
423
|
-
showElementBrowserLink: options.showElementBrowserLink,
|
|
424
|
-
tableSelectorSupported: options.tableSelectorSupported,
|
|
425
|
-
onInsertBlockType: onInsertBlockType,
|
|
426
|
-
nativeStatusSupported: options.nativeStatusSupported,
|
|
427
|
-
horizontalRuleEnabled: options.horizontalRuleEnabled,
|
|
428
|
-
expandEnabled: options.allowExpand,
|
|
429
|
-
insertMenuItems: options.insertMenuItems,
|
|
430
|
-
numberOfButtons: 7 // TODO: ED-28759 - Default to 7 buttons - Remove this once we have a proper way to do toolbar responsiveness
|
|
431
|
-
});
|
|
432
|
-
}
|
|
433
|
-
});
|
|
434
|
-
}
|
|
396
|
+
rank: INSERT_GROUP_RANK[INSERT_BUTTON.key]
|
|
397
|
+
}],
|
|
398
|
+
component: createInsertButtonComponent('xl')
|
|
399
|
+
});
|
|
435
400
|
}
|
|
436
401
|
return components;
|
|
437
402
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-insert-block",
|
|
3
|
-
"version": "8.3.
|
|
3
|
+
"version": "8.3.3",
|
|
4
4
|
"description": "Insert block plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"@atlaskit/editor-plugin-panel": "^9.0.0",
|
|
49
49
|
"@atlaskit/editor-plugin-placeholder-text": "^8.0.0",
|
|
50
50
|
"@atlaskit/editor-plugin-primary-toolbar": "^8.0.0",
|
|
51
|
-
"@atlaskit/editor-plugin-quick-insert": "^7.
|
|
51
|
+
"@atlaskit/editor-plugin-quick-insert": "^7.2.0",
|
|
52
52
|
"@atlaskit/editor-plugin-rule": "^7.0.0",
|
|
53
53
|
"@atlaskit/editor-plugin-status": "^8.1.0",
|
|
54
54
|
"@atlaskit/editor-plugin-table": "^17.3.0",
|
|
@@ -64,7 +64,7 @@
|
|
|
64
64
|
"@atlaskit/icon-lab": "^5.15.0",
|
|
65
65
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
66
66
|
"@atlaskit/theme": "^21.0.0",
|
|
67
|
-
"@atlaskit/tmp-editor-statsig": "^20.
|
|
67
|
+
"@atlaskit/tmp-editor-statsig": "^20.3.0",
|
|
68
68
|
"@atlaskit/tokens": "^11.0.0",
|
|
69
69
|
"@babel/runtime": "^7.0.0",
|
|
70
70
|
"@emotion/react": "^11.7.1",
|
|
@@ -120,9 +120,6 @@
|
|
|
120
120
|
}
|
|
121
121
|
},
|
|
122
122
|
"platform-feature-flags": {
|
|
123
|
-
"platform_editor_toolbar_aifc_ga_blockers": {
|
|
124
|
-
"type": "boolean"
|
|
125
|
-
},
|
|
126
123
|
"platform_editor_toolbar_responsive_fixes": {
|
|
127
124
|
"type": "boolean"
|
|
128
125
|
},
|