@atlaskit/editor-plugin-block-type 3.0.10 → 3.0.11

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,12 @@
1
1
  # @atlaskit/editor-plugin-block-type
2
2
 
3
+ ## 3.0.11
4
+
5
+ ### Patch Changes
6
+
7
+ - [#60534](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/60534) [`191a38f1ea23`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/191a38f1ea23) - ED-20966 Use blockQuoteWithList PMNode when 'allow-list-in-blockquote' FF is enabled
8
+ - Updated dependencies
9
+
3
10
  ## 3.0.10
4
11
 
5
12
  ### Patch Changes
@@ -20,6 +20,7 @@ var _messages = require("@atlaskit/editor-common/messages");
20
20
  var _quickInsert = require("@atlaskit/editor-common/quick-insert");
21
21
  var _types = require("@atlaskit/editor-common/types");
22
22
  var _withPluginState = require("@atlaskit/editor-common/with-plugin-state");
23
+ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
23
24
  var _commands = require("./commands");
24
25
  var _blockType = require("./commands/block-type");
25
26
  var _inputRule = _interopRequireDefault(require("./pm-plugins/input-rule"));
@@ -107,12 +108,13 @@ var blockTypePlugin = exports.blockTypePlugin = function blockTypePlugin(_ref3)
107
108
  return {
108
109
  name: 'blockType',
109
110
  nodes: function nodes() {
111
+ var blockquoteNode = (0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-list-in-blockquote') ? _adfSchema.blockquoteWithList : _adfSchema.blockquote;
110
112
  var nodes = [{
111
113
  name: 'heading',
112
114
  node: _adfSchema.heading
113
115
  }, {
114
116
  name: 'blockquote',
115
- node: _adfSchema.blockquote
117
+ node: blockquoteNode
116
118
  }, {
117
119
  name: 'hardBreak',
118
120
  node: _adfSchema.hardBreak
@@ -1,11 +1,12 @@
1
1
  import React from 'react';
2
- import { blockquote, hardBreak, heading } from '@atlaskit/adf-schema';
2
+ import { blockquote, blockquoteWithList, hardBreak, heading } from '@atlaskit/adf-schema';
3
3
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
4
4
  import { keymap, toggleBlockQuote, tooltip } from '@atlaskit/editor-common/keymaps';
5
5
  import { blockTypeMessages as messages } from '@atlaskit/editor-common/messages';
6
6
  import { IconHeading, IconQuote } from '@atlaskit/editor-common/quick-insert';
7
7
  import { ToolbarSize } from '@atlaskit/editor-common/types';
8
8
  import { WithPluginState } from '@atlaskit/editor-common/with-plugin-state';
9
+ import { getBooleanFF } from '@atlaskit/platform-feature-flags';
9
10
  import { setBlockTypeWithAnalytics } from './commands';
10
11
  import { insertBlockQuoteWithAnalytics } from './commands/block-type';
11
12
  import inputRulePlugin from './pm-plugins/input-rule';
@@ -91,12 +92,13 @@ const blockTypePlugin = ({
91
92
  }) => ({
92
93
  name: 'blockType',
93
94
  nodes() {
95
+ const blockquoteNode = getBooleanFF('platform.editor.allow-list-in-blockquote') ? blockquoteWithList : blockquote;
94
96
  const nodes = [{
95
97
  name: 'heading',
96
98
  node: heading
97
99
  }, {
98
100
  name: 'blockquote',
99
- node: blockquote
101
+ node: blockquoteNode
100
102
  }, {
101
103
  name: 'hardBreak',
102
104
  node: hardBreak
@@ -1,12 +1,13 @@
1
1
  import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
2
2
  import React from 'react';
3
- import { blockquote, hardBreak, heading } from '@atlaskit/adf-schema';
3
+ import { blockquote, blockquoteWithList, hardBreak, heading } from '@atlaskit/adf-schema';
4
4
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
5
5
  import { keymap, toggleBlockQuote, tooltip } from '@atlaskit/editor-common/keymaps';
6
6
  import { blockTypeMessages as messages } from '@atlaskit/editor-common/messages';
7
7
  import { IconHeading, IconQuote } from '@atlaskit/editor-common/quick-insert';
8
8
  import { ToolbarSize } from '@atlaskit/editor-common/types';
9
9
  import { WithPluginState } from '@atlaskit/editor-common/with-plugin-state';
10
+ import { getBooleanFF } from '@atlaskit/platform-feature-flags';
10
11
  import { setBlockTypeWithAnalytics } from './commands';
11
12
  import { insertBlockQuoteWithAnalytics } from './commands/block-type';
12
13
  import inputRulePlugin from './pm-plugins/input-rule';
@@ -94,12 +95,13 @@ var blockTypePlugin = function blockTypePlugin(_ref3) {
94
95
  return {
95
96
  name: 'blockType',
96
97
  nodes: function nodes() {
98
+ var blockquoteNode = getBooleanFF('platform.editor.allow-list-in-blockquote') ? blockquoteWithList : blockquote;
97
99
  var nodes = [{
98
100
  name: 'heading',
99
101
  node: heading
100
102
  }, {
101
103
  name: 'blockquote',
102
- node: blockquote
104
+ node: blockquoteNode
103
105
  }, {
104
106
  name: 'hardBreak',
105
107
  node: hardBreak
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-block-type",
3
- "version": "3.0.10",
3
+ "version": "3.0.11",
4
4
  "description": "BlockType plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -38,15 +38,16 @@
38
38
  },
39
39
  "dependencies": {
40
40
  "@atlaskit/adf-schema": "^35.1.1",
41
- "@atlaskit/editor-common": "^76.26.0",
41
+ "@atlaskit/editor-common": "^76.27.0",
42
42
  "@atlaskit/editor-plugin-analytics": "^0.4.0",
43
43
  "@atlaskit/editor-prosemirror": "1.1.0",
44
44
  "@atlaskit/editor-shared-styles": "^2.8.0",
45
45
  "@atlaskit/editor-tables": "^2.3.0",
46
46
  "@atlaskit/icon": "^22.0.0",
47
+ "@atlaskit/platform-feature-flags": "^0.2.5",
47
48
  "@atlaskit/prosemirror-input-rules": "^2.4.0",
48
49
  "@atlaskit/theme": "^12.6.0",
49
- "@atlaskit/tokens": "^1.29.0",
50
+ "@atlaskit/tokens": "^1.30.0",
50
51
  "@babel/runtime": "^7.0.0",
51
52
  "@emotion/react": "^11.7.1"
52
53
  },
@@ -105,5 +106,10 @@
105
106
  ]
106
107
  }
107
108
  },
108
- "prettier": "@atlassian/atlassian-frontend-prettier-config-1.0.0"
109
+ "prettier": "@atlassian/atlassian-frontend-prettier-config-1.0.0",
110
+ "platform-feature-flags": {
111
+ "platform.editor.allow-list-in-blockquote": {
112
+ "type": "boolean"
113
+ }
114
+ }
109
115
  }