@atlaskit/editor-plugin-expand 3.0.1 → 3.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 +17 -0
- package/dist/cjs/legacyExpand/plugin.js +3 -1
- package/dist/cjs/singlePlayerExpand/plugin.js +3 -1
- package/dist/es2019/legacyExpand/plugin.js +4 -2
- package/dist/es2019/singlePlayerExpand/plugin.js +4 -2
- package/dist/esm/legacyExpand/plugin.js +4 -2
- package/dist/esm/singlePlayerExpand/plugin.js +4 -2
- package/package.json +9 -9
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,22 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-expand
|
|
2
2
|
|
|
3
|
+
## 3.1.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#120472](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/120472)
|
|
8
|
+
[`4758d7dd443dd`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/4758d7dd443dd) -
|
|
9
|
+
[ux] ED-26766 update adf-schema from 47.2.1 to 47.6.0 and adf-schema-json from 1.27.0 to 1.31.0
|
|
10
|
+
and feature gated the usage of new prosemirror nodes in blockTypePlugin, expandPlugin, listPlugin
|
|
11
|
+
and panelPlugin as the new defaults of these nodes support nesting of extensions
|
|
12
|
+
- [#120472](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/120472)
|
|
13
|
+
[`73c800ab5f2fc`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/73c800ab5f2fc) -
|
|
14
|
+
ED-26766 update adf-schema from 47.2.1 to 47.6.0 and adf-schema-json from 1.27.0 to 1.31.0
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- Updated dependencies
|
|
19
|
+
|
|
3
20
|
## 3.0.1
|
|
4
21
|
|
|
5
22
|
### Patch Changes
|
|
@@ -12,6 +12,7 @@ var _messages = require("@atlaskit/editor-common/messages");
|
|
|
12
12
|
var _quickInsert = require("@atlaskit/editor-common/quick-insert");
|
|
13
13
|
var _utils = require("@atlaskit/editor-common/utils");
|
|
14
14
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
15
|
+
var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
|
|
15
16
|
var _commands = require("./commands");
|
|
16
17
|
var _keymap = require("./pm-plugins/keymap");
|
|
17
18
|
var _main = require("./pm-plugins/main");
|
|
@@ -27,6 +28,7 @@ var expandPlugin = exports.expandPlugin = function expandPlugin(_ref) {
|
|
|
27
28
|
// Jira is pulling it in through platform feature flags, from a feature gate
|
|
28
29
|
var isNestingExpandsSchemaChanged = (0, _platformFeatureFlags.fg)('platform_editor_nested_expand_in_expand_adf_change') || (0, _platformFeatureFlags.fg)('platform_editor_nest_nested_expand_in_expand_jira');
|
|
29
30
|
var isNestingExpandsSupported = (api === null || api === void 0 || (_api$featureFlags = api.featureFlags) === null || _api$featureFlags === void 0 || (_api$featureFlags = _api$featureFlags.sharedState.currentState()) === null || _api$featureFlags === void 0 ? void 0 : _api$featureFlags.nestedExpandInExpandEx) || (0, _platformFeatureFlags.fg)('platform_editor_nest_nested_expand_in_expand_jira');
|
|
31
|
+
var nestedExpandNode = (0, _experiments.editorExperiment)('platform_editor_nested_non_bodied_macros', 'test') ? _adfSchema.nestedExpand : _adfSchema.nestedExpandWithoutNonBodiedMacros;
|
|
30
32
|
return {
|
|
31
33
|
name: 'expand',
|
|
32
34
|
nodes: function nodes() {
|
|
@@ -35,7 +37,7 @@ var expandPlugin = exports.expandPlugin = function expandPlugin(_ref) {
|
|
|
35
37
|
node: isNestingExpandsSchemaChanged ? _adfSchema.expandWithNestedExpand : _adfSchema.expand
|
|
36
38
|
}, {
|
|
37
39
|
name: 'nestedExpand',
|
|
38
|
-
node:
|
|
40
|
+
node: nestedExpandNode
|
|
39
41
|
}];
|
|
40
42
|
},
|
|
41
43
|
actions: {
|
|
@@ -12,6 +12,7 @@ var _messages = require("@atlaskit/editor-common/messages");
|
|
|
12
12
|
var _quickInsert = require("@atlaskit/editor-common/quick-insert");
|
|
13
13
|
var _utils = require("@atlaskit/editor-common/utils");
|
|
14
14
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
15
|
+
var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
|
|
15
16
|
var _commands = require("./commands");
|
|
16
17
|
var _keymap = require("./pm-plugins/keymap");
|
|
17
18
|
var _main = require("./pm-plugins/main");
|
|
@@ -27,6 +28,7 @@ var expandPlugin = exports.expandPlugin = function expandPlugin(_ref) {
|
|
|
27
28
|
// Jira is pulling it in through platform feature flags, from a feature gate
|
|
28
29
|
var isNestingExpandsSchemaChanged = (0, _platformFeatureFlags.fg)('platform_editor_nested_expand_in_expand_adf_change') || (0, _platformFeatureFlags.fg)('platform_editor_nest_nested_expand_in_expand_jira');
|
|
29
30
|
var isNestingExpandsSupported = (api === null || api === void 0 || (_api$featureFlags = api.featureFlags) === null || _api$featureFlags === void 0 || (_api$featureFlags = _api$featureFlags.sharedState.currentState()) === null || _api$featureFlags === void 0 ? void 0 : _api$featureFlags.nestedExpandInExpandEx) || (0, _platformFeatureFlags.fg)('platform_editor_nest_nested_expand_in_expand_jira');
|
|
31
|
+
var nestedExpandNode = (0, _experiments.editorExperiment)('platform_editor_nested_non_bodied_macros', 'test') ? _adfSchema.nestedExpand : _adfSchema.nestedExpandWithoutNonBodiedMacros;
|
|
30
32
|
return {
|
|
31
33
|
name: 'expand',
|
|
32
34
|
nodes: function nodes() {
|
|
@@ -35,7 +37,7 @@ var expandPlugin = exports.expandPlugin = function expandPlugin(_ref) {
|
|
|
35
37
|
node: isNestingExpandsSchemaChanged ? _adfSchema.expandWithNestedExpand : _adfSchema.expand
|
|
36
38
|
}, {
|
|
37
39
|
name: 'nestedExpand',
|
|
38
|
-
node:
|
|
40
|
+
node: nestedExpandNode
|
|
39
41
|
}];
|
|
40
42
|
},
|
|
41
43
|
actions: {
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { expand, expandWithNestedExpand, nestedExpand } from '@atlaskit/adf-schema';
|
|
2
|
+
import { expand, expandWithNestedExpand, nestedExpand, nestedExpandWithoutNonBodiedMacros } 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 { toolbarInsertBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
5
5
|
import { IconExpand } from '@atlaskit/editor-common/quick-insert';
|
|
6
6
|
import { createWrapSelectionTransaction } from '@atlaskit/editor-common/utils';
|
|
7
7
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
|
+
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
8
9
|
import { createExpandNode, insertExpand, insertExpandWithInputMethod } from './commands';
|
|
9
10
|
import { expandKeymap } from './pm-plugins/keymap';
|
|
10
11
|
import { createPlugin } from './pm-plugins/main';
|
|
@@ -21,6 +22,7 @@ export let expandPlugin = ({
|
|
|
21
22
|
// Jira is pulling it in through platform feature flags, from a feature gate
|
|
22
23
|
const isNestingExpandsSchemaChanged = fg('platform_editor_nested_expand_in_expand_adf_change') || fg('platform_editor_nest_nested_expand_in_expand_jira');
|
|
23
24
|
const isNestingExpandsSupported = (api === null || api === void 0 ? void 0 : (_api$featureFlags = api.featureFlags) === null || _api$featureFlags === void 0 ? void 0 : (_api$featureFlags$sha = _api$featureFlags.sharedState.currentState()) === null || _api$featureFlags$sha === void 0 ? void 0 : _api$featureFlags$sha.nestedExpandInExpandEx) || fg('platform_editor_nest_nested_expand_in_expand_jira');
|
|
25
|
+
const nestedExpandNode = editorExperiment('platform_editor_nested_non_bodied_macros', 'test') ? nestedExpand : nestedExpandWithoutNonBodiedMacros;
|
|
24
26
|
return {
|
|
25
27
|
name: 'expand',
|
|
26
28
|
nodes() {
|
|
@@ -29,7 +31,7 @@ export let expandPlugin = ({
|
|
|
29
31
|
node: isNestingExpandsSchemaChanged ? expandWithNestedExpand : expand
|
|
30
32
|
}, {
|
|
31
33
|
name: 'nestedExpand',
|
|
32
|
-
node:
|
|
34
|
+
node: nestedExpandNode
|
|
33
35
|
}];
|
|
34
36
|
},
|
|
35
37
|
actions: {
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { expand, expandWithNestedExpand, nestedExpand } from '@atlaskit/adf-schema';
|
|
2
|
+
import { expand, expandWithNestedExpand, nestedExpand, nestedExpandWithoutNonBodiedMacros } 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 { toolbarInsertBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
5
5
|
import { IconExpand } from '@atlaskit/editor-common/quick-insert';
|
|
6
6
|
import { createWrapSelectionTransaction } from '@atlaskit/editor-common/utils';
|
|
7
7
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
|
+
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
8
9
|
import { createExpandNode, insertExpand, insertExpandWithInputMethod } from './commands';
|
|
9
10
|
import { expandKeymap } from './pm-plugins/keymap';
|
|
10
11
|
import { createPlugin } from './pm-plugins/main';
|
|
@@ -21,6 +22,7 @@ export let expandPlugin = ({
|
|
|
21
22
|
// Jira is pulling it in through platform feature flags, from a feature gate
|
|
22
23
|
const isNestingExpandsSchemaChanged = fg('platform_editor_nested_expand_in_expand_adf_change') || fg('platform_editor_nest_nested_expand_in_expand_jira');
|
|
23
24
|
const isNestingExpandsSupported = (api === null || api === void 0 ? void 0 : (_api$featureFlags = api.featureFlags) === null || _api$featureFlags === void 0 ? void 0 : (_api$featureFlags$sha = _api$featureFlags.sharedState.currentState()) === null || _api$featureFlags$sha === void 0 ? void 0 : _api$featureFlags$sha.nestedExpandInExpandEx) || fg('platform_editor_nest_nested_expand_in_expand_jira');
|
|
25
|
+
const nestedExpandNode = editorExperiment('platform_editor_nested_non_bodied_macros', 'test') ? nestedExpand : nestedExpandWithoutNonBodiedMacros;
|
|
24
26
|
return {
|
|
25
27
|
name: 'expand',
|
|
26
28
|
nodes() {
|
|
@@ -29,7 +31,7 @@ export let expandPlugin = ({
|
|
|
29
31
|
node: isNestingExpandsSchemaChanged ? expandWithNestedExpand : expand
|
|
30
32
|
}, {
|
|
31
33
|
name: 'nestedExpand',
|
|
32
|
-
node:
|
|
34
|
+
node: nestedExpandNode
|
|
33
35
|
}];
|
|
34
36
|
},
|
|
35
37
|
actions: {
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { expand, expandWithNestedExpand, nestedExpand } from '@atlaskit/adf-schema';
|
|
2
|
+
import { expand, expandWithNestedExpand, nestedExpand, nestedExpandWithoutNonBodiedMacros } 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 { toolbarInsertBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
5
5
|
import { IconExpand } from '@atlaskit/editor-common/quick-insert';
|
|
6
6
|
import { createWrapSelectionTransaction } from '@atlaskit/editor-common/utils';
|
|
7
7
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
|
+
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
8
9
|
import { createExpandNode, insertExpand, insertExpandWithInputMethod } from './commands';
|
|
9
10
|
import { expandKeymap } from './pm-plugins/keymap';
|
|
10
11
|
import { createPlugin } from './pm-plugins/main';
|
|
@@ -21,6 +22,7 @@ export var expandPlugin = function expandPlugin(_ref) {
|
|
|
21
22
|
// Jira is pulling it in through platform feature flags, from a feature gate
|
|
22
23
|
var isNestingExpandsSchemaChanged = fg('platform_editor_nested_expand_in_expand_adf_change') || fg('platform_editor_nest_nested_expand_in_expand_jira');
|
|
23
24
|
var isNestingExpandsSupported = (api === null || api === void 0 || (_api$featureFlags = api.featureFlags) === null || _api$featureFlags === void 0 || (_api$featureFlags = _api$featureFlags.sharedState.currentState()) === null || _api$featureFlags === void 0 ? void 0 : _api$featureFlags.nestedExpandInExpandEx) || fg('platform_editor_nest_nested_expand_in_expand_jira');
|
|
25
|
+
var nestedExpandNode = editorExperiment('platform_editor_nested_non_bodied_macros', 'test') ? nestedExpand : nestedExpandWithoutNonBodiedMacros;
|
|
24
26
|
return {
|
|
25
27
|
name: 'expand',
|
|
26
28
|
nodes: function nodes() {
|
|
@@ -29,7 +31,7 @@ export var expandPlugin = function expandPlugin(_ref) {
|
|
|
29
31
|
node: isNestingExpandsSchemaChanged ? expandWithNestedExpand : expand
|
|
30
32
|
}, {
|
|
31
33
|
name: 'nestedExpand',
|
|
32
|
-
node:
|
|
34
|
+
node: nestedExpandNode
|
|
33
35
|
}];
|
|
34
36
|
},
|
|
35
37
|
actions: {
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { expand, expandWithNestedExpand, nestedExpand } from '@atlaskit/adf-schema';
|
|
2
|
+
import { expand, expandWithNestedExpand, nestedExpand, nestedExpandWithoutNonBodiedMacros } 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 { toolbarInsertBlockMessages as messages } from '@atlaskit/editor-common/messages';
|
|
5
5
|
import { IconExpand } from '@atlaskit/editor-common/quick-insert';
|
|
6
6
|
import { createWrapSelectionTransaction } from '@atlaskit/editor-common/utils';
|
|
7
7
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
|
+
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
8
9
|
import { createExpandNode, insertExpand, insertExpandWithInputMethod } from './commands';
|
|
9
10
|
import { expandKeymap } from './pm-plugins/keymap';
|
|
10
11
|
import { createPlugin } from './pm-plugins/main';
|
|
@@ -21,6 +22,7 @@ export var expandPlugin = function expandPlugin(_ref) {
|
|
|
21
22
|
// Jira is pulling it in through platform feature flags, from a feature gate
|
|
22
23
|
var isNestingExpandsSchemaChanged = fg('platform_editor_nested_expand_in_expand_adf_change') || fg('platform_editor_nest_nested_expand_in_expand_jira');
|
|
23
24
|
var isNestingExpandsSupported = (api === null || api === void 0 || (_api$featureFlags = api.featureFlags) === null || _api$featureFlags === void 0 || (_api$featureFlags = _api$featureFlags.sharedState.currentState()) === null || _api$featureFlags === void 0 ? void 0 : _api$featureFlags.nestedExpandInExpandEx) || fg('platform_editor_nest_nested_expand_in_expand_jira');
|
|
25
|
+
var nestedExpandNode = editorExperiment('platform_editor_nested_non_bodied_macros', 'test') ? nestedExpand : nestedExpandWithoutNonBodiedMacros;
|
|
24
26
|
return {
|
|
25
27
|
name: 'expand',
|
|
26
28
|
nodes: function nodes() {
|
|
@@ -29,7 +31,7 @@ export var expandPlugin = function expandPlugin(_ref) {
|
|
|
29
31
|
node: isNestingExpandsSchemaChanged ? expandWithNestedExpand : expand
|
|
30
32
|
}, {
|
|
31
33
|
name: 'nestedExpand',
|
|
32
|
-
node:
|
|
34
|
+
node: nestedExpandNode
|
|
33
35
|
}];
|
|
34
36
|
},
|
|
35
37
|
actions: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-expand",
|
|
3
|
-
"version": "3.0
|
|
3
|
+
"version": "3.1.0",
|
|
4
4
|
"description": "Expand plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -33,10 +33,10 @@
|
|
|
33
33
|
".": "./src/index.ts"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@atlaskit/adf-schema": "^47.
|
|
36
|
+
"@atlaskit/adf-schema": "^47.6.0",
|
|
37
37
|
"@atlaskit/button": "^21.1.0",
|
|
38
|
-
"@atlaskit/editor-common": "^100.
|
|
39
|
-
"@atlaskit/editor-plugin-analytics": "^2.
|
|
38
|
+
"@atlaskit/editor-common": "^100.5.0",
|
|
39
|
+
"@atlaskit/editor-plugin-analytics": "^2.1.0",
|
|
40
40
|
"@atlaskit/editor-plugin-decorations": "^2.0.0",
|
|
41
41
|
"@atlaskit/editor-plugin-editor-disabled": "^2.0.0",
|
|
42
42
|
"@atlaskit/editor-plugin-editor-viewmode": "^3.0.0",
|
|
@@ -47,8 +47,8 @@
|
|
|
47
47
|
"@atlaskit/editor-tables": "^2.9.0",
|
|
48
48
|
"@atlaskit/icon": "^24.1.0",
|
|
49
49
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
50
|
-
"@atlaskit/tmp-editor-statsig": "^3.
|
|
51
|
-
"@atlaskit/tokens": "^4.
|
|
50
|
+
"@atlaskit/tmp-editor-statsig": "^3.4.0",
|
|
51
|
+
"@atlaskit/tokens": "^4.3.0",
|
|
52
52
|
"@atlaskit/tooltip": "^20.0.0",
|
|
53
53
|
"@babel/runtime": "^7.0.0",
|
|
54
54
|
"@emotion/react": "^11.7.1",
|
|
@@ -62,11 +62,11 @@
|
|
|
62
62
|
},
|
|
63
63
|
"devDependencies": {
|
|
64
64
|
"@atlaskit/analytics-next": "^11.0.0",
|
|
65
|
-
"@atlaskit/editor-plugin-content-insertion": "^2.
|
|
65
|
+
"@atlaskit/editor-plugin-content-insertion": "^2.1.0",
|
|
66
66
|
"@atlaskit/editor-plugin-guideline": "^2.0.0",
|
|
67
67
|
"@atlaskit/editor-plugin-quick-insert": "^2.0.0",
|
|
68
|
-
"@atlaskit/editor-plugin-table": "^10.
|
|
69
|
-
"@atlaskit/editor-plugin-type-ahead": "^2.
|
|
68
|
+
"@atlaskit/editor-plugin-table": "^10.3.0",
|
|
69
|
+
"@atlaskit/editor-plugin-type-ahead": "^2.1.0",
|
|
70
70
|
"@atlaskit/editor-plugin-width": "^3.0.0",
|
|
71
71
|
"@testing-library/react": "^13.4.0",
|
|
72
72
|
"react-test-renderer": "^18.2.0",
|