@atlaskit/editor-plugin-media 6.0.3 → 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 CHANGED
@@ -1,5 +1,16 @@
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
+
3
14
  ## 6.0.3
4
15
 
5
16
  ### Patch Changes
@@ -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),
@@ -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),
@@ -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),
@@ -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",
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.4.0",
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",
@@ -77,7 +77,7 @@
77
77
  "uuid": "^3.1.0"
78
78
  },
79
79
  "peerDependencies": {
80
- "@atlaskit/editor-common": "^108.3.0",
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",