@atlaskit/editor-plugin-media 6.0.2 → 6.1.0
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 +19 -0
- package/dist/cjs/mediaPlugin.js +1 -1
- package/dist/cjs/ui/toolbar/index.js +1 -2
- package/dist/es2019/mediaPlugin.js +1 -1
- package/dist/es2019/ui/toolbar/index.js +1 -2
- package/dist/esm/mediaPlugin.js +1 -1
- package/dist/esm/ui/toolbar/index.js +1 -2
- package/dist/types/types/index.d.ts +1 -0
- package/dist/types-ts4.5/types/index.d.ts +1 -0
- package/package.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-media
|
|
2
2
|
|
|
3
|
+
## 6.1.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [`a498274ad526d`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/a498274ad526d) -
|
|
8
|
+
Allow hiding of the 'Media' quick-insert option using `disableQuickInsert` boolean option
|
|
9
|
+
|
|
10
|
+
### Patch Changes
|
|
11
|
+
|
|
12
|
+
- Updated dependencies
|
|
13
|
+
|
|
14
|
+
## 6.0.3
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- [`db97eb262cc5a`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/db97eb262cc5a) -
|
|
19
|
+
replace platform_editor_toolbar_aifc with separate experiements for jira and confluence
|
|
20
|
+
- Updated dependencies
|
|
21
|
+
|
|
3
22
|
## 6.0.2
|
|
4
23
|
|
|
5
24
|
### Patch Changes
|
package/dist/cjs/mediaPlugin.js
CHANGED
|
@@ -323,7 +323,7 @@ var mediaPlugin = exports.mediaPlugin = function mediaPlugin(_ref3) {
|
|
|
323
323
|
pluginsOptions: {
|
|
324
324
|
quickInsert: function quickInsert(_ref12) {
|
|
325
325
|
var formatMessage = _ref12.formatMessage;
|
|
326
|
-
return (0, _platformFeatureFlags.fg)('platform_editor_add_media_from_url_rollout') ? [] : [{
|
|
326
|
+
return (0, _platformFeatureFlags.fg)('platform_editor_add_media_from_url_rollout') || options !== null && options !== void 0 && options.disableQuickInsert ? [] : [{
|
|
327
327
|
id: 'media',
|
|
328
328
|
title: formatMessage(_messages.toolbarInsertBlockMessages.mediaFiles),
|
|
329
329
|
description: formatMessage(_messages.toolbarInsertBlockMessages.mediaFilesDescription),
|
|
@@ -30,7 +30,6 @@ var _smartLinkCard = _interopRequireDefault(require("@atlaskit/icon/core/smart-l
|
|
|
30
30
|
var _mediaFilmstrip = require("@atlaskit/media-filmstrip");
|
|
31
31
|
var _mediaUi = require("@atlaskit/media-ui");
|
|
32
32
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
33
|
-
var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
|
|
34
33
|
var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
|
|
35
34
|
var _styles = require("../../nodeviews/styles");
|
|
36
35
|
var _altText = require("../../pm-plugins/alt-text");
|
|
@@ -438,7 +437,7 @@ var generateMediaSingleFloatingToolbar = function generateMediaSingleFloatingToo
|
|
|
438
437
|
}
|
|
439
438
|
|
|
440
439
|
// A separator is needed regardless switcher is enabled or not
|
|
441
|
-
if ((0,
|
|
440
|
+
if ((0, _experiments.editorExperiment)('platform_editor_toolbar_aifc', true)) {
|
|
442
441
|
toolbarButtons.push({
|
|
443
442
|
type: 'separator',
|
|
444
443
|
fullHeight: true
|
|
@@ -322,7 +322,7 @@ export const mediaPlugin = ({
|
|
|
322
322
|
pluginsOptions: {
|
|
323
323
|
quickInsert: ({
|
|
324
324
|
formatMessage
|
|
325
|
-
}) => fg('platform_editor_add_media_from_url_rollout') ? [] : [{
|
|
325
|
+
}) => fg('platform_editor_add_media_from_url_rollout') || options !== null && options !== void 0 && options.disableQuickInsert ? [] : [{
|
|
326
326
|
id: 'media',
|
|
327
327
|
title: formatMessage(messages.mediaFiles),
|
|
328
328
|
description: formatMessage(messages.mediaFilesDescription),
|
|
@@ -20,7 +20,6 @@ import SmartLinkCardIcon from '@atlaskit/icon/core/smart-link-card';
|
|
|
20
20
|
import { mediaFilmstripItemDOMSelector } from '@atlaskit/media-filmstrip';
|
|
21
21
|
import { messages } from '@atlaskit/media-ui';
|
|
22
22
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
23
|
-
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
24
23
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
25
24
|
import { MediaSingleNodeSelector } from '../../nodeviews/styles';
|
|
26
25
|
import { getPluginState as getMediaAltTextPluginState } from '../../pm-plugins/alt-text';
|
|
@@ -426,7 +425,7 @@ const generateMediaSingleFloatingToolbar = (state, intl, options, pluginState, m
|
|
|
426
425
|
}
|
|
427
426
|
|
|
428
427
|
// A separator is needed regardless switcher is enabled or not
|
|
429
|
-
if (
|
|
428
|
+
if (editorExperiment('platform_editor_toolbar_aifc', true)) {
|
|
430
429
|
toolbarButtons.push({
|
|
431
430
|
type: 'separator',
|
|
432
431
|
fullHeight: true
|
package/dist/esm/mediaPlugin.js
CHANGED
|
@@ -314,7 +314,7 @@ export var mediaPlugin = function mediaPlugin(_ref3) {
|
|
|
314
314
|
pluginsOptions: {
|
|
315
315
|
quickInsert: function quickInsert(_ref12) {
|
|
316
316
|
var formatMessage = _ref12.formatMessage;
|
|
317
|
-
return fg('platform_editor_add_media_from_url_rollout') ? [] : [{
|
|
317
|
+
return fg('platform_editor_add_media_from_url_rollout') || options !== null && options !== void 0 && options.disableQuickInsert ? [] : [{
|
|
318
318
|
id: 'media',
|
|
319
319
|
title: formatMessage(messages.mediaFiles),
|
|
320
320
|
description: formatMessage(messages.mediaFilesDescription),
|
|
@@ -24,7 +24,6 @@ import SmartLinkCardIcon from '@atlaskit/icon/core/smart-link-card';
|
|
|
24
24
|
import { mediaFilmstripItemDOMSelector } from '@atlaskit/media-filmstrip';
|
|
25
25
|
import { messages } from '@atlaskit/media-ui';
|
|
26
26
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
27
|
-
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
28
27
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
29
28
|
import { MediaSingleNodeSelector } from '../../nodeviews/styles';
|
|
30
29
|
import { getPluginState as getMediaAltTextPluginState } from '../../pm-plugins/alt-text';
|
|
@@ -429,7 +428,7 @@ var generateMediaSingleFloatingToolbar = function generateMediaSingleFloatingToo
|
|
|
429
428
|
}
|
|
430
429
|
|
|
431
430
|
// A separator is needed regardless switcher is enabled or not
|
|
432
|
-
if (
|
|
431
|
+
if (editorExperiment('platform_editor_toolbar_aifc', true)) {
|
|
433
432
|
toolbarButtons.push({
|
|
434
433
|
type: 'separator',
|
|
435
434
|
fullHeight: true
|
|
@@ -43,6 +43,7 @@ export interface MediaPluginOptions {
|
|
|
43
43
|
altTextValidator?: (value: string) => string[];
|
|
44
44
|
customDropzoneContainer?: HTMLElement;
|
|
45
45
|
customMediaPicker?: CustomMediaPicker;
|
|
46
|
+
disableQuickInsert?: boolean;
|
|
46
47
|
editorAppearance?: EditorAppearance;
|
|
47
48
|
editorSelectionAPI?: EditorSelectionAPI;
|
|
48
49
|
enableDownloadButton?: boolean;
|
|
@@ -43,6 +43,7 @@ export interface MediaPluginOptions {
|
|
|
43
43
|
altTextValidator?: (value: string) => string[];
|
|
44
44
|
customDropzoneContainer?: HTMLElement;
|
|
45
45
|
customMediaPicker?: CustomMediaPicker;
|
|
46
|
+
disableQuickInsert?: boolean;
|
|
46
47
|
editorAppearance?: EditorAppearance;
|
|
47
48
|
editorSelectionAPI?: EditorSelectionAPI;
|
|
48
49
|
enableDownloadButton?: boolean;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-media",
|
|
3
|
-
"version": "6.0
|
|
3
|
+
"version": "6.1.0",
|
|
4
4
|
"description": "Media plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"@atlaskit/editor-prosemirror": "7.0.0",
|
|
51
51
|
"@atlaskit/editor-shared-styles": "^3.6.0",
|
|
52
52
|
"@atlaskit/editor-tables": "^2.9.0",
|
|
53
|
-
"@atlaskit/form": "^12.
|
|
53
|
+
"@atlaskit/form": "^12.5.0",
|
|
54
54
|
"@atlaskit/icon": "^28.1.0",
|
|
55
55
|
"@atlaskit/icon-lab": "^5.7.0",
|
|
56
56
|
"@atlaskit/media-card": "^79.5.0",
|
|
@@ -62,11 +62,11 @@
|
|
|
62
62
|
"@atlaskit/media-ui": "^28.6.0",
|
|
63
63
|
"@atlaskit/media-viewer": "^52.4.0",
|
|
64
64
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
65
|
-
"@atlaskit/primitives": "^14.
|
|
65
|
+
"@atlaskit/primitives": "^14.13.0",
|
|
66
66
|
"@atlaskit/textfield": "^8.0.0",
|
|
67
67
|
"@atlaskit/theme": "^20.0.0",
|
|
68
|
-
"@atlaskit/tmp-editor-statsig": "^12.
|
|
69
|
-
"@atlaskit/tokens": "^6.
|
|
68
|
+
"@atlaskit/tmp-editor-statsig": "^12.5.0",
|
|
69
|
+
"@atlaskit/tokens": "^6.2.0",
|
|
70
70
|
"@atlaskit/tooltip": "^20.4.0",
|
|
71
71
|
"@babel/runtime": "^7.0.0",
|
|
72
72
|
"@emotion/react": "^11.7.1",
|
|
@@ -77,7 +77,7 @@
|
|
|
77
77
|
"uuid": "^3.1.0"
|
|
78
78
|
},
|
|
79
79
|
"peerDependencies": {
|
|
80
|
-
"@atlaskit/editor-common": "^108.
|
|
80
|
+
"@atlaskit/editor-common": "^108.5.0",
|
|
81
81
|
"@atlaskit/media-core": "^37.0.0",
|
|
82
82
|
"react": "^18.2.0",
|
|
83
83
|
"react-dom": "^18.2.0",
|