@atlaskit/editor-plugin-list 3.1.1 → 3.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,11 @@
1
1
  # @atlaskit/editor-plugin-list
2
2
 
3
+ ## 3.1.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [#65603](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/65603) [`ac8d4b09e18e`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/ac8d4b09e18e) - ED-21609 Node nesting: Use the new nodespec for list and panel when respective FF's are enabled
8
+
3
9
  ## 3.1.1
4
10
 
5
11
  ### Patch Changes
@@ -11,6 +11,7 @@ var _analytics = require("@atlaskit/editor-common/analytics");
11
11
  var _keymaps = require("@atlaskit/editor-common/keymaps");
12
12
  var _messages = require("@atlaskit/editor-common/messages");
13
13
  var _quickInsert = require("@atlaskit/editor-common/quick-insert");
14
+ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
14
15
  var _commands = require("./commands");
15
16
  var _inputRules = _interopRequireDefault(require("./pm-plugins/input-rules"));
16
17
  var _keymap = _interopRequireDefault(require("./pm-plugins/keymap"));
@@ -53,6 +54,7 @@ var listPlugin = exports.listPlugin = function listPlugin(_ref) {
53
54
  return _main.pluginKey.getState(editorState);
54
55
  },
55
56
  nodes: function nodes() {
57
+ var listItemNode = (0, _platformFeatureFlags.getBooleanFF)('platform.editor.allow-action-in-list') ? _adfSchema.listItemWithTask : _adfSchema.listItem;
56
58
  return [{
57
59
  name: 'bulletList',
58
60
  node: _adfSchema.bulletList
@@ -61,7 +63,7 @@ var listPlugin = exports.listPlugin = function listPlugin(_ref) {
61
63
  node: _adfSchema.orderedListWithOrder
62
64
  }, {
63
65
  name: 'listItem',
64
- node: _adfSchema.listItem
66
+ node: listItemNode
65
67
  }];
66
68
  },
67
69
  pmPlugins: function pmPlugins() {
@@ -1,9 +1,10 @@
1
1
  import React from 'react';
2
- import { bulletList, listItem, orderedListWithOrder } from '@atlaskit/adf-schema';
2
+ import { bulletList, listItem, listItemWithTask, orderedListWithOrder } 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 { toggleBulletList, toggleOrderedList, tooltip } from '@atlaskit/editor-common/keymaps';
5
5
  import { listMessages as messages } from '@atlaskit/editor-common/messages';
6
6
  import { IconList, IconListNumber } from '@atlaskit/editor-common/quick-insert';
7
+ import { getBooleanFF } from '@atlaskit/platform-feature-flags';
7
8
  import { indentList, outdentList, toggleBulletList as toggleBulletListCommand, toggleOrderedList as toggleOrderedListCommand } from './commands';
8
9
  import inputRulePlugin from './pm-plugins/input-rules';
9
10
  import keymapPlugin from './pm-plugins/keymap';
@@ -46,6 +47,7 @@ export const listPlugin = ({
46
47
  return listPluginKey.getState(editorState);
47
48
  },
48
49
  nodes() {
50
+ const listItemNode = getBooleanFF('platform.editor.allow-action-in-list') ? listItemWithTask : listItem;
49
51
  return [{
50
52
  name: 'bulletList',
51
53
  node: bulletList
@@ -54,7 +56,7 @@ export const listPlugin = ({
54
56
  node: orderedListWithOrder
55
57
  }, {
56
58
  name: 'listItem',
57
- node: listItem
59
+ node: listItemNode
58
60
  }];
59
61
  },
60
62
  pmPlugins() {
@@ -1,9 +1,10 @@
1
1
  import React from 'react';
2
- import { bulletList, listItem, orderedListWithOrder } from '@atlaskit/adf-schema';
2
+ import { bulletList, listItem, listItemWithTask, orderedListWithOrder } 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 { toggleBulletList, toggleOrderedList, tooltip } from '@atlaskit/editor-common/keymaps';
5
5
  import { listMessages as messages } from '@atlaskit/editor-common/messages';
6
6
  import { IconList, IconListNumber } from '@atlaskit/editor-common/quick-insert';
7
+ import { getBooleanFF } from '@atlaskit/platform-feature-flags';
7
8
  import { indentList, outdentList as _outdentList, toggleBulletList as toggleBulletListCommand, toggleOrderedList as toggleOrderedListCommand } from './commands';
8
9
  import inputRulePlugin from './pm-plugins/input-rules';
9
10
  import keymapPlugin from './pm-plugins/keymap';
@@ -47,6 +48,7 @@ export var listPlugin = function listPlugin(_ref) {
47
48
  return listPluginKey.getState(editorState);
48
49
  },
49
50
  nodes: function nodes() {
51
+ var listItemNode = getBooleanFF('platform.editor.allow-action-in-list') ? listItemWithTask : listItem;
50
52
  return [{
51
53
  name: 'bulletList',
52
54
  node: bulletList
@@ -55,7 +57,7 @@ export var listPlugin = function listPlugin(_ref) {
55
57
  node: orderedListWithOrder
56
58
  }, {
57
59
  name: 'listItem',
58
- node: listItem
60
+ node: listItemNode
59
61
  }];
60
62
  },
61
63
  pmPlugins: function pmPlugins() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-list",
3
- "version": "3.1.1",
3
+ "version": "3.1.2",
4
4
  "description": "List plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -33,7 +33,7 @@
33
33
  },
34
34
  "dependencies": {
35
35
  "@atlaskit/adf-schema": "^35.3.0",
36
- "@atlaskit/editor-common": "^76.35.0",
36
+ "@atlaskit/editor-common": "^76.36.0",
37
37
  "@atlaskit/editor-plugin-analytics": "^0.4.0",
38
38
  "@atlaskit/editor-plugin-feature-flags": "^1.0.0",
39
39
  "@atlaskit/editor-prosemirror": "1.1.0",
@@ -92,6 +92,9 @@
92
92
  "platform-feature-flags": {
93
93
  "platform.editor.ordered-list-auto-join-improvements_mrlv5": {
94
94
  "type": "boolean"
95
+ },
96
+ "platform.editor.allow-action-in-list": {
97
+ "type": "boolean"
95
98
  }
96
99
  }
97
100
  }