@atlaskit/editor-plugin-list 8.2.5 → 8.2.7
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 +15 -0
- package/dist/cjs/listPlugin.js +4 -6
- package/dist/es2019/listPlugin.js +47 -50
- package/dist/esm/listPlugin.js +2 -6
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,20 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-list
|
|
2
2
|
|
|
3
|
+
## 8.2.7
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`0d661119b4293`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/0d661119b4293) -
|
|
8
|
+
Clean up platform_editor_insertion experiment by shipping control variant. Remove modern TypeAhead
|
|
9
|
+
components and experiment infrastructure while preserving all existing functionality.
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
12
|
+
## 8.2.6
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- Updated dependencies
|
|
17
|
+
|
|
3
18
|
## 8.2.5
|
|
4
19
|
|
|
5
20
|
### Patch Changes
|
package/dist/cjs/listPlugin.js
CHANGED
|
@@ -5,7 +5,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
7
|
exports.listPlugin = void 0;
|
|
8
|
-
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
9
8
|
var _react = _interopRequireDefault(require("react"));
|
|
10
9
|
var _adfSchema = require("@atlaskit/adf-schema");
|
|
11
10
|
var _analytics = require("@atlaskit/editor-common/analytics");
|
|
@@ -14,7 +13,6 @@ var _messages = require("@atlaskit/editor-common/messages");
|
|
|
14
13
|
var _quickInsert = require("@atlaskit/editor-common/quick-insert");
|
|
15
14
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
16
15
|
var _expValEqualsNoExposure = require("@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure");
|
|
17
|
-
var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
|
|
18
16
|
var _commands = require("./pm-plugins/commands");
|
|
19
17
|
var _indentList = require("./pm-plugins/commands/indent-list");
|
|
20
18
|
var _outdentList2 = require("./pm-plugins/commands/outdent-list");
|
|
@@ -24,9 +22,9 @@ var _main = require("./pm-plugins/main");
|
|
|
24
22
|
var _find = require("./pm-plugins/utils/find");
|
|
25
23
|
var _selection = require("./pm-plugins/utils/selection");
|
|
26
24
|
var _ui = require("./ui");
|
|
27
|
-
|
|
28
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } // Ignored via go/ees005
|
|
25
|
+
// Ignored via go/ees005
|
|
29
26
|
// eslint-disable-next-line import/no-named-as-default
|
|
27
|
+
|
|
30
28
|
/*
|
|
31
29
|
Toolbar buttons to bullet and ordered list can be found in
|
|
32
30
|
packages/editor/editor-core/src/plugins/toolbar-lists-indentation/ui/Toolbar.tsx
|
|
@@ -101,7 +99,7 @@ var listPlugin = exports.listPlugin = function listPlugin(_ref) {
|
|
|
101
99
|
}
|
|
102
100
|
}];
|
|
103
101
|
},
|
|
104
|
-
pluginsOptions:
|
|
102
|
+
pluginsOptions: {
|
|
105
103
|
quickInsert: function quickInsert(_ref4) {
|
|
106
104
|
var formatMessage = _ref4.formatMessage;
|
|
107
105
|
return [{
|
|
@@ -152,6 +150,6 @@ var listPlugin = exports.listPlugin = function listPlugin(_ref) {
|
|
|
152
150
|
}
|
|
153
151
|
}];
|
|
154
152
|
}
|
|
155
|
-
}
|
|
153
|
+
}
|
|
156
154
|
};
|
|
157
155
|
};
|
|
@@ -6,7 +6,6 @@ import { listMessages as messages } from '@atlaskit/editor-common/messages';
|
|
|
6
6
|
import { IconList, IconListNumber } from '@atlaskit/editor-common/quick-insert';
|
|
7
7
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
8
|
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
9
|
-
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
10
9
|
import { toggleBulletList as toggleBulletListCommand, toggleOrderedList as toggleOrderedListCommand } from './pm-plugins/commands';
|
|
11
10
|
import { indentList } from './pm-plugins/commands/indent-list';
|
|
12
11
|
import { outdentList } from './pm-plugins/commands/outdent-list';
|
|
@@ -93,55 +92,53 @@ export const listPlugin = ({
|
|
|
93
92
|
}];
|
|
94
93
|
},
|
|
95
94
|
pluginsOptions: {
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
}
|
|
144
|
-
})
|
|
95
|
+
quickInsert: ({
|
|
96
|
+
formatMessage
|
|
97
|
+
}) => {
|
|
98
|
+
return [{
|
|
99
|
+
id: 'unorderedList',
|
|
100
|
+
title: formatMessage(messages.unorderedList),
|
|
101
|
+
description: formatMessage(messages.unorderedListDescription),
|
|
102
|
+
keywords: ['ul', 'unordered'],
|
|
103
|
+
priority: 1100,
|
|
104
|
+
keyshortcut: tooltip(toggleBulletList),
|
|
105
|
+
icon: () => /*#__PURE__*/React.createElement(IconList, null),
|
|
106
|
+
action(insert, state) {
|
|
107
|
+
const tr = insert(state.schema.nodes.bulletList.createChecked({}, state.schema.nodes.listItem.createChecked({}, state.schema.nodes.paragraph.createChecked())));
|
|
108
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 ? void 0 : editorAnalyticsAPI.attachAnalyticsEvent({
|
|
109
|
+
action: ACTION.INSERTED,
|
|
110
|
+
actionSubject: ACTION_SUBJECT.LIST,
|
|
111
|
+
actionSubjectId: ACTION_SUBJECT_ID.FORMAT_LIST_BULLET,
|
|
112
|
+
eventType: EVENT_TYPE.TRACK,
|
|
113
|
+
attributes: {
|
|
114
|
+
inputMethod: INPUT_METHOD.QUICK_INSERT
|
|
115
|
+
}
|
|
116
|
+
})(tr);
|
|
117
|
+
return tr;
|
|
118
|
+
}
|
|
119
|
+
}, {
|
|
120
|
+
id: 'orderedList',
|
|
121
|
+
title: formatMessage(messages.orderedList),
|
|
122
|
+
description: formatMessage(messages.orderedListDescription),
|
|
123
|
+
keywords: ['ol', 'ordered'],
|
|
124
|
+
priority: 1200,
|
|
125
|
+
keyshortcut: tooltip(toggleOrderedList),
|
|
126
|
+
icon: () => /*#__PURE__*/React.createElement(IconListNumber, null),
|
|
127
|
+
action(insert, state) {
|
|
128
|
+
const tr = insert(state.schema.nodes.orderedList.createChecked({}, state.schema.nodes.listItem.createChecked({}, state.schema.nodes.paragraph.createChecked())));
|
|
129
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 ? void 0 : editorAnalyticsAPI.attachAnalyticsEvent({
|
|
130
|
+
action: ACTION.INSERTED,
|
|
131
|
+
actionSubject: ACTION_SUBJECT.LIST,
|
|
132
|
+
actionSubjectId: ACTION_SUBJECT_ID.FORMAT_LIST_NUMBER,
|
|
133
|
+
eventType: EVENT_TYPE.TRACK,
|
|
134
|
+
attributes: {
|
|
135
|
+
inputMethod: INPUT_METHOD.QUICK_INSERT
|
|
136
|
+
}
|
|
137
|
+
})(tr);
|
|
138
|
+
return tr;
|
|
139
|
+
}
|
|
140
|
+
}];
|
|
141
|
+
}
|
|
145
142
|
}
|
|
146
143
|
};
|
|
147
144
|
};
|
package/dist/esm/listPlugin.js
CHANGED
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
|
-
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
1
|
import React from 'react';
|
|
5
2
|
import { bulletList, bulletListWithLocalId, listItem, listItemWithLocalId, orderedListWithOrder, orderedListWithOrderAndLocalId } from '@atlaskit/adf-schema';
|
|
6
3
|
import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
@@ -9,7 +6,6 @@ import { listMessages as messages } from '@atlaskit/editor-common/messages';
|
|
|
9
6
|
import { IconList, IconListNumber } from '@atlaskit/editor-common/quick-insert';
|
|
10
7
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
11
8
|
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
12
|
-
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
13
9
|
import { toggleBulletList as toggleBulletListCommand, toggleOrderedList as toggleOrderedListCommand } from './pm-plugins/commands';
|
|
14
10
|
import { indentList } from './pm-plugins/commands/indent-list';
|
|
15
11
|
import { outdentList as _outdentList } from './pm-plugins/commands/outdent-list';
|
|
@@ -96,7 +92,7 @@ export var listPlugin = function listPlugin(_ref) {
|
|
|
96
92
|
}
|
|
97
93
|
}];
|
|
98
94
|
},
|
|
99
|
-
pluginsOptions:
|
|
95
|
+
pluginsOptions: {
|
|
100
96
|
quickInsert: function quickInsert(_ref4) {
|
|
101
97
|
var formatMessage = _ref4.formatMessage;
|
|
102
98
|
return [{
|
|
@@ -147,6 +143,6 @@ export var listPlugin = function listPlugin(_ref) {
|
|
|
147
143
|
}
|
|
148
144
|
}];
|
|
149
145
|
}
|
|
150
|
-
}
|
|
146
|
+
}
|
|
151
147
|
};
|
|
152
148
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-list",
|
|
3
|
-
"version": "8.2.
|
|
3
|
+
"version": "8.2.7",
|
|
4
4
|
"description": "List plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -35,15 +35,15 @@
|
|
|
35
35
|
"@atlaskit/editor-prosemirror": "7.0.0",
|
|
36
36
|
"@atlaskit/editor-toolbar": "^0.17.0",
|
|
37
37
|
"@atlaskit/icon": "^28.5.0",
|
|
38
|
-
"@atlaskit/insm": "^0.
|
|
38
|
+
"@atlaskit/insm": "^0.2.0",
|
|
39
39
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
40
40
|
"@atlaskit/prosemirror-history": "^0.2.0",
|
|
41
|
-
"@atlaskit/prosemirror-input-rules": "^3.
|
|
42
|
-
"@atlaskit/tmp-editor-statsig": "^13.
|
|
41
|
+
"@atlaskit/prosemirror-input-rules": "^3.6.0",
|
|
42
|
+
"@atlaskit/tmp-editor-statsig": "^13.32.0",
|
|
43
43
|
"@babel/runtime": "^7.0.0"
|
|
44
44
|
},
|
|
45
45
|
"peerDependencies": {
|
|
46
|
-
"@atlaskit/editor-common": "^110.
|
|
46
|
+
"@atlaskit/editor-common": "^110.24.0",
|
|
47
47
|
"react": "^18.2.0",
|
|
48
48
|
"react-intl-next": "npm:react-intl@^5.18.1"
|
|
49
49
|
},
|