@atlaskit/editor-plugin-expand 7.0.8 → 7.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 +20 -0
- package/dist/cjs/legacyExpand/nodeviews/index.js +3 -3
- package/dist/cjs/singlePlayerExpand/node-views/index.js +3 -3
- package/dist/cjs/ui/ExpandBlockMenuItem.js +2 -2
- package/dist/es2019/legacyExpand/nodeviews/index.js +1 -1
- package/dist/es2019/singlePlayerExpand/node-views/index.js +1 -1
- package/dist/es2019/ui/ExpandBlockMenuItem.js +2 -2
- package/dist/esm/legacyExpand/nodeviews/index.js +1 -1
- package/dist/esm/singlePlayerExpand/node-views/index.js +1 -1
- package/dist/esm/ui/ExpandBlockMenuItem.js +2 -2
- package/package.json +9 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,25 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-expand
|
|
2
2
|
|
|
3
|
+
## 7.1.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [`0ac75e0d28c72`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/0ac75e0d28c72) -
|
|
8
|
+
Migrate @atlaskit/editor-prosemirror/history to @atlaskit/prosemirror-history package
|
|
9
|
+
|
|
10
|
+
### Patch Changes
|
|
11
|
+
|
|
12
|
+
- Updated dependencies
|
|
13
|
+
|
|
14
|
+
## 7.0.9
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- [`26917199e153a`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/26917199e153a) -
|
|
19
|
+
ED-29473 Add inputMethod attribute for block menu opened and switch inputMethod and triggeredFrom
|
|
20
|
+
attributes for element converted event
|
|
21
|
+
- Updated dependencies
|
|
22
|
+
|
|
3
23
|
## 7.0.8
|
|
4
24
|
|
|
5
25
|
### Patch Changes
|
|
@@ -16,10 +16,10 @@ var _selection = require("@atlaskit/editor-common/selection");
|
|
|
16
16
|
var _styles = require("@atlaskit/editor-common/styles");
|
|
17
17
|
var _ui = require("@atlaskit/editor-common/ui");
|
|
18
18
|
var _utils = require("@atlaskit/editor-common/utils");
|
|
19
|
-
var _history = require("@atlaskit/editor-prosemirror/history");
|
|
20
19
|
var _model = require("@atlaskit/editor-prosemirror/model");
|
|
21
20
|
var _state = require("@atlaskit/editor-prosemirror/state");
|
|
22
21
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
22
|
+
var _prosemirrorHistory = require("@atlaskit/prosemirror-history");
|
|
23
23
|
var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
|
|
24
24
|
var _commands = require("../commands");
|
|
25
25
|
var _ExpandIconButton = require("../ui/ExpandIconButton");
|
|
@@ -405,7 +405,7 @@ var ExpandNodeView = exports.ExpandNodeView = /*#__PURE__*/function () {
|
|
|
405
405
|
var _this$view0 = _this.view,
|
|
406
406
|
state = _this$view0.state,
|
|
407
407
|
dispatch = _this$view0.dispatch;
|
|
408
|
-
(0,
|
|
408
|
+
(0, _prosemirrorHistory.undo)(state, dispatch);
|
|
409
409
|
event.preventDefault();
|
|
410
410
|
return;
|
|
411
411
|
});
|
|
@@ -413,7 +413,7 @@ var ExpandNodeView = exports.ExpandNodeView = /*#__PURE__*/function () {
|
|
|
413
413
|
var _this$view1 = _this.view,
|
|
414
414
|
state = _this$view1.state,
|
|
415
415
|
dispatch = _this$view1.dispatch;
|
|
416
|
-
(0,
|
|
416
|
+
(0, _prosemirrorHistory.redo)(state, dispatch);
|
|
417
417
|
event.preventDefault();
|
|
418
418
|
return;
|
|
419
419
|
});
|
|
@@ -16,10 +16,10 @@ var _expand = require("@atlaskit/editor-common/expand");
|
|
|
16
16
|
var _selection = require("@atlaskit/editor-common/selection");
|
|
17
17
|
var _styles = require("@atlaskit/editor-common/styles");
|
|
18
18
|
var _utils = require("@atlaskit/editor-common/utils");
|
|
19
|
-
var _history = require("@atlaskit/editor-prosemirror/history");
|
|
20
19
|
var _model = require("@atlaskit/editor-prosemirror/model");
|
|
21
20
|
var _state = require("@atlaskit/editor-prosemirror/state");
|
|
22
21
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
22
|
+
var _prosemirrorHistory = require("@atlaskit/prosemirror-history");
|
|
23
23
|
var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
|
|
24
24
|
var _commands = require("../commands");
|
|
25
25
|
var _ExpandButton = require("../ui/ExpandButton");
|
|
@@ -359,7 +359,7 @@ var ExpandNodeView = exports.ExpandNodeView = /*#__PURE__*/function () {
|
|
|
359
359
|
var _this$view9 = _this.view,
|
|
360
360
|
state = _this$view9.state,
|
|
361
361
|
dispatch = _this$view9.dispatch;
|
|
362
|
-
(0,
|
|
362
|
+
(0, _prosemirrorHistory.undo)(state, dispatch);
|
|
363
363
|
event.preventDefault();
|
|
364
364
|
return;
|
|
365
365
|
});
|
|
@@ -367,7 +367,7 @@ var ExpandNodeView = exports.ExpandNodeView = /*#__PURE__*/function () {
|
|
|
367
367
|
var _this$view0 = _this.view,
|
|
368
368
|
state = _this$view0.state,
|
|
369
369
|
dispatch = _this$view0.dispatch;
|
|
370
|
-
(0,
|
|
370
|
+
(0, _prosemirrorHistory.redo)(state, dispatch);
|
|
371
371
|
event.preventDefault();
|
|
372
372
|
return;
|
|
373
373
|
});
|
|
@@ -32,8 +32,8 @@ var ExpandBlockMenuItem = function ExpandBlockMenuItem(_ref) {
|
|
|
32
32
|
}, [selection]);
|
|
33
33
|
var handleClick = function handleClick(event) {
|
|
34
34
|
var _api$blockMenu;
|
|
35
|
-
var
|
|
36
|
-
var
|
|
35
|
+
var triggeredFrom = event.nativeEvent instanceof KeyboardEvent || event.nativeEvent.detail === 0 ? _analytics.INPUT_METHOD.KEYBOARD : _analytics.INPUT_METHOD.MOUSE;
|
|
36
|
+
var inputMethod = _analytics.INPUT_METHOD.BLOCK_MENU;
|
|
37
37
|
api === null || api === void 0 || api.core.actions.execute(api === null || api === void 0 || (_api$blockMenu = api.blockMenu) === null || _api$blockMenu === void 0 ? void 0 : _api$blockMenu.commands.formatNode(nodeName, {
|
|
38
38
|
inputMethod: inputMethod,
|
|
39
39
|
triggeredFrom: triggeredFrom
|
|
@@ -6,10 +6,10 @@ import { GapCursorSelection, RelativeSelectionPos, Side } from '@atlaskit/editor
|
|
|
6
6
|
import { expandClassNames } from '@atlaskit/editor-common/styles';
|
|
7
7
|
import { expandMessages } from '@atlaskit/editor-common/ui';
|
|
8
8
|
import { closestElement, isEmptyNode } from '@atlaskit/editor-common/utils';
|
|
9
|
-
import { redo, undo } from '@atlaskit/editor-prosemirror/history';
|
|
10
9
|
import { DOMSerializer } from '@atlaskit/editor-prosemirror/model';
|
|
11
10
|
import { NodeSelection, Selection } from '@atlaskit/editor-prosemirror/state';
|
|
12
11
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
12
|
+
import { redo, undo } from '@atlaskit/prosemirror-history';
|
|
13
13
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
14
14
|
import { deleteExpandAtPos, setSelectionInsideExpand, toggleExpandExpanded, updateExpandTitle } from '../commands';
|
|
15
15
|
import { ExpandIconButton } from '../ui/ExpandIconButton';
|
|
@@ -6,10 +6,10 @@ import { expandedState, isExpandCollapsed } from '@atlaskit/editor-common/expand
|
|
|
6
6
|
import { GapCursorSelection, RelativeSelectionPos, Side } from '@atlaskit/editor-common/selection';
|
|
7
7
|
import { expandClassNames } from '@atlaskit/editor-common/styles';
|
|
8
8
|
import { closestElement, isEmptyNode } from '@atlaskit/editor-common/utils';
|
|
9
|
-
import { redo, undo } from '@atlaskit/editor-prosemirror/history';
|
|
10
9
|
import { DOMSerializer } from '@atlaskit/editor-prosemirror/model';
|
|
11
10
|
import { NodeSelection, Selection } from '@atlaskit/editor-prosemirror/state';
|
|
12
11
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
12
|
+
import { redo, undo } from '@atlaskit/prosemirror-history';
|
|
13
13
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
14
14
|
import { deleteExpand, setSelectionInsideExpand, toggleExpandExpanded, updateExpandTitle } from '../commands';
|
|
15
15
|
import { ExpandButton } from '../ui/ExpandButton';
|
|
@@ -25,8 +25,8 @@ const ExpandBlockMenuItem = ({
|
|
|
25
25
|
}, [selection]);
|
|
26
26
|
const handleClick = event => {
|
|
27
27
|
var _api$blockMenu;
|
|
28
|
-
const
|
|
29
|
-
const
|
|
28
|
+
const triggeredFrom = event.nativeEvent instanceof KeyboardEvent || event.nativeEvent.detail === 0 ? INPUT_METHOD.KEYBOARD : INPUT_METHOD.MOUSE;
|
|
29
|
+
const inputMethod = INPUT_METHOD.BLOCK_MENU;
|
|
30
30
|
api === null || api === void 0 ? void 0 : api.core.actions.execute(api === null || api === void 0 ? void 0 : (_api$blockMenu = api.blockMenu) === null || _api$blockMenu === void 0 ? void 0 : _api$blockMenu.commands.formatNode(nodeName, {
|
|
31
31
|
inputMethod,
|
|
32
32
|
triggeredFrom
|
|
@@ -10,10 +10,10 @@ import { GapCursorSelection, RelativeSelectionPos, Side } from '@atlaskit/editor
|
|
|
10
10
|
import { expandClassNames } from '@atlaskit/editor-common/styles';
|
|
11
11
|
import { expandMessages } from '@atlaskit/editor-common/ui';
|
|
12
12
|
import { closestElement, isEmptyNode } from '@atlaskit/editor-common/utils';
|
|
13
|
-
import { redo, undo } from '@atlaskit/editor-prosemirror/history';
|
|
14
13
|
import { DOMSerializer } from '@atlaskit/editor-prosemirror/model';
|
|
15
14
|
import { NodeSelection, Selection } from '@atlaskit/editor-prosemirror/state';
|
|
16
15
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
16
|
+
import { redo, undo } from '@atlaskit/prosemirror-history';
|
|
17
17
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
18
18
|
import { deleteExpandAtPos, setSelectionInsideExpand, toggleExpandExpanded, updateExpandTitle } from '../commands';
|
|
19
19
|
import { ExpandIconButton } from '../ui/ExpandIconButton';
|
|
@@ -8,10 +8,10 @@ import { expandedState, isExpandCollapsed } from '@atlaskit/editor-common/expand
|
|
|
8
8
|
import { GapCursorSelection, RelativeSelectionPos, Side } from '@atlaskit/editor-common/selection';
|
|
9
9
|
import { expandClassNames } from '@atlaskit/editor-common/styles';
|
|
10
10
|
import { closestElement, isEmptyNode } from '@atlaskit/editor-common/utils';
|
|
11
|
-
import { redo, undo } from '@atlaskit/editor-prosemirror/history';
|
|
12
11
|
import { DOMSerializer } from '@atlaskit/editor-prosemirror/model';
|
|
13
12
|
import { NodeSelection, Selection } from '@atlaskit/editor-prosemirror/state';
|
|
14
13
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
14
|
+
import { redo, undo } from '@atlaskit/prosemirror-history';
|
|
15
15
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
16
16
|
import { deleteExpand, setSelectionInsideExpand, toggleExpandExpanded, updateExpandTitle } from '../commands';
|
|
17
17
|
import { ExpandButton } from '../ui/ExpandButton';
|
|
@@ -23,8 +23,8 @@ var ExpandBlockMenuItem = function ExpandBlockMenuItem(_ref) {
|
|
|
23
23
|
}, [selection]);
|
|
24
24
|
var handleClick = function handleClick(event) {
|
|
25
25
|
var _api$blockMenu;
|
|
26
|
-
var
|
|
27
|
-
var
|
|
26
|
+
var triggeredFrom = event.nativeEvent instanceof KeyboardEvent || event.nativeEvent.detail === 0 ? INPUT_METHOD.KEYBOARD : INPUT_METHOD.MOUSE;
|
|
27
|
+
var inputMethod = INPUT_METHOD.BLOCK_MENU;
|
|
28
28
|
api === null || api === void 0 || api.core.actions.execute(api === null || api === void 0 || (_api$blockMenu = api.blockMenu) === null || _api$blockMenu === void 0 ? void 0 : _api$blockMenu.commands.formatNode(nodeName, {
|
|
29
29
|
inputMethod: inputMethod,
|
|
30
30
|
triggeredFrom: triggeredFrom
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-expand",
|
|
3
|
-
"version": "7.0
|
|
3
|
+
"version": "7.1.0",
|
|
4
4
|
"description": "Expand plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -34,19 +34,19 @@
|
|
|
34
34
|
"@atlaskit/editor-plugin-analytics": "^6.1.0",
|
|
35
35
|
"@atlaskit/editor-plugin-block-menu": "^4.0.0",
|
|
36
36
|
"@atlaskit/editor-plugin-decorations": "^6.1.0",
|
|
37
|
-
"@atlaskit/editor-plugin-editor-disabled": "^6.
|
|
37
|
+
"@atlaskit/editor-plugin-editor-disabled": "^6.1.0",
|
|
38
38
|
"@atlaskit/editor-plugin-editor-viewmode": "^8.0.0",
|
|
39
39
|
"@atlaskit/editor-plugin-local-id": "^4.1.0",
|
|
40
|
-
"@atlaskit/editor-plugin-selection": "^6.
|
|
40
|
+
"@atlaskit/editor-plugin-selection": "^6.1.0",
|
|
41
41
|
"@atlaskit/editor-plugin-selection-marker": "^6.2.0",
|
|
42
42
|
"@atlaskit/editor-prosemirror": "7.0.0",
|
|
43
43
|
"@atlaskit/editor-shared-styles": "^3.6.0",
|
|
44
44
|
"@atlaskit/editor-tables": "^2.9.0",
|
|
45
45
|
"@atlaskit/editor-toolbar": "^0.14.0",
|
|
46
|
-
"@atlaskit/icon": "^28.
|
|
47
|
-
"@atlaskit/icon-lab": "^5.
|
|
46
|
+
"@atlaskit/icon": "^28.5.0",
|
|
47
|
+
"@atlaskit/icon-lab": "^5.10.0",
|
|
48
48
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
49
|
-
"@atlaskit/tmp-editor-statsig": "^13.
|
|
49
|
+
"@atlaskit/tmp-editor-statsig": "^13.6.0",
|
|
50
50
|
"@atlaskit/tokens": "^6.4.0",
|
|
51
51
|
"@atlaskit/tooltip": "^20.5.0",
|
|
52
52
|
"@babel/runtime": "^7.0.0",
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"w3c-keyname": "^2.1.8"
|
|
56
56
|
},
|
|
57
57
|
"peerDependencies": {
|
|
58
|
-
"@atlaskit/editor-common": "^110.
|
|
58
|
+
"@atlaskit/editor-common": "^110.10.0",
|
|
59
59
|
"react": "^18.2.0",
|
|
60
60
|
"react-dom": "^18.2.0",
|
|
61
61
|
"react-intl-next": "npm:react-intl@^5.18.1"
|
|
@@ -66,8 +66,9 @@
|
|
|
66
66
|
"@atlaskit/editor-plugin-guideline": "^6.0.0",
|
|
67
67
|
"@atlaskit/editor-plugin-quick-insert": "^6.0.0",
|
|
68
68
|
"@atlaskit/editor-plugin-table": "^15.0.0",
|
|
69
|
-
"@atlaskit/editor-plugin-type-ahead": "^6.
|
|
69
|
+
"@atlaskit/editor-plugin-type-ahead": "^6.4.0",
|
|
70
70
|
"@atlaskit/editor-plugin-width": "^7.0.0",
|
|
71
|
+
"@atlaskit/prosemirror-history": "^0.2.0",
|
|
71
72
|
"@testing-library/react": "^13.4.0",
|
|
72
73
|
"react-test-renderer": "^18.2.0"
|
|
73
74
|
},
|