@atlaskit/editor-plugin-tasks-and-decisions 15.1.14 → 15.2.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
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-tasks-and-decisions
|
|
2
2
|
|
|
3
|
+
## 15.2.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [`4b43e68ec0c47`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/4b43e68ec0c47) -
|
|
8
|
+
Clean up feature gate platform_editor_toolbar_task_list_analytics. Task list toolbar analytics are
|
|
9
|
+
now always tracked.
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- Updated dependencies
|
|
14
|
+
|
|
15
|
+
## 15.1.15
|
|
16
|
+
|
|
17
|
+
### Patch Changes
|
|
18
|
+
|
|
19
|
+
- Updated dependencies
|
|
20
|
+
|
|
3
21
|
## 15.1.14
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
|
@@ -12,7 +12,6 @@ var _lists = require("@atlaskit/editor-common/lists");
|
|
|
12
12
|
var _transforms = require("@atlaskit/editor-common/transforms");
|
|
13
13
|
var _state = require("@atlaskit/editor-prosemirror/state");
|
|
14
14
|
var _utils = require("@atlaskit/editor-prosemirror/utils");
|
|
15
|
-
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
16
15
|
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; }
|
|
17
16
|
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; }
|
|
18
17
|
var toggleTaskList = exports.toggleTaskList = function toggleTaskList(editorAnalyticsAPI) {
|
|
@@ -40,22 +39,20 @@ var toggleTaskList = exports.toggleTaskList = function toggleTaskList(editorAnal
|
|
|
40
39
|
// Insert the empty list at the current selection
|
|
41
40
|
var insertTr = (0, _utils.safeInsert)(emptyList)(tr);
|
|
42
41
|
if (insertTr !== tr) {
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
})(insertTr);
|
|
58
|
-
}
|
|
42
|
+
// Fire INSERT analytics event when creating a new task list
|
|
43
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 || editorAnalyticsAPI.attachAnalyticsEvent({
|
|
44
|
+
action: _analytics.ACTION.INSERTED,
|
|
45
|
+
actionSubject: _analytics.ACTION_SUBJECT.DOCUMENT,
|
|
46
|
+
actionSubjectId: _analytics.ACTION_SUBJECT_ID.ACTION,
|
|
47
|
+
eventType: _analytics.EVENT_TYPE.TRACK,
|
|
48
|
+
attributes: {
|
|
49
|
+
inputMethod: inputMethod,
|
|
50
|
+
listLocalId: listLocalId,
|
|
51
|
+
listSize: 1,
|
|
52
|
+
localId: itemLocalId,
|
|
53
|
+
position: 0
|
|
54
|
+
}
|
|
55
|
+
})(insertTr);
|
|
59
56
|
|
|
60
57
|
// Set cursor inside the new task item
|
|
61
58
|
var insertPos = insertTr.selection.$from.pos;
|
|
@@ -75,20 +72,19 @@ var toggleTaskList = exports.toggleTaskList = function toggleTaskList(editorAnal
|
|
|
75
72
|
tr: tr
|
|
76
73
|
};
|
|
77
74
|
var resultTr = (0, _transforms.transformBetweenListTypes)(context);
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
}
|
|
75
|
+
|
|
76
|
+
// Fire CONVERTED analytics event when transforming a list to task list
|
|
77
|
+
if (resultTr && resultTr.docChanged) {
|
|
78
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 || editorAnalyticsAPI.attachAnalyticsEvent({
|
|
79
|
+
action: _analytics.ACTION.CONVERTED,
|
|
80
|
+
actionSubject: _analytics.ACTION_SUBJECT.LIST,
|
|
81
|
+
actionSubjectId: _analytics.ACTION_SUBJECT_ID.FORMAT_LIST_BULLET,
|
|
82
|
+
eventType: _analytics.EVENT_TYPE.TRACK,
|
|
83
|
+
attributes: _objectSpread(_objectSpread({}, (0, _lists.getCommonListAnalyticsAttributes)(tr)), {}, {
|
|
84
|
+
transformedFrom: transformedFrom,
|
|
85
|
+
inputMethod: inputMethod
|
|
86
|
+
})
|
|
87
|
+
})(resultTr);
|
|
92
88
|
}
|
|
93
89
|
return resultTr;
|
|
94
90
|
}
|
|
@@ -105,18 +101,16 @@ var toggleTaskList = exports.toggleTaskList = function toggleTaskList(editorAnal
|
|
|
105
101
|
if (_resultTr && _resultTr.docChanged && targetType !== 'paragraph') {
|
|
106
102
|
var _transformedFrom = _analytics.ACTION_SUBJECT_ID.FORMAT_LIST_BULLET;
|
|
107
103
|
var targetListType = targetType === 'bulletList' ? _analytics.ACTION_SUBJECT_ID.FORMAT_LIST_BULLET : _analytics.ACTION_SUBJECT_ID.FORMAT_LIST_NUMBER;
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
})(_resultTr);
|
|
119
|
-
}
|
|
104
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 || editorAnalyticsAPI.attachAnalyticsEvent({
|
|
105
|
+
action: _analytics.ACTION.CONVERTED,
|
|
106
|
+
actionSubject: _analytics.ACTION_SUBJECT.LIST,
|
|
107
|
+
actionSubjectId: targetListType,
|
|
108
|
+
eventType: _analytics.EVENT_TYPE.TRACK,
|
|
109
|
+
attributes: _objectSpread(_objectSpread({}, (0, _lists.getCommonListAnalyticsAttributes)(tr)), {}, {
|
|
110
|
+
transformedFrom: _transformedFrom,
|
|
111
|
+
inputMethod: inputMethod
|
|
112
|
+
})
|
|
113
|
+
})(_resultTr);
|
|
120
114
|
}
|
|
121
115
|
return _resultTr;
|
|
122
116
|
}
|
|
@@ -133,21 +127,19 @@ var toggleTaskList = exports.toggleTaskList = function toggleTaskList(editorAnal
|
|
|
133
127
|
var listLocalIdFromNode = (_listNode$attrs$local = listNode === null || listNode === void 0 || (_listNode$attrs = listNode.attrs) === null || _listNode$attrs === void 0 ? void 0 : _listNode$attrs.localId) !== null && _listNode$attrs$local !== void 0 ? _listNode$attrs$local : _adfSchema.uuid.generate();
|
|
134
128
|
var listSizeFromNode = (_listNode$childCount = listNode === null || listNode === void 0 ? void 0 : listNode.childCount) !== null && _listNode$childCount !== void 0 ? _listNode$childCount : 0;
|
|
135
129
|
var localIdFromNode = (_listNode$firstChild$ = listNode === null || listNode === void 0 || (_listNode$firstChild = listNode.firstChild) === null || _listNode$firstChild === void 0 || (_listNode$firstChild = _listNode$firstChild.attrs) === null || _listNode$firstChild === void 0 ? void 0 : _listNode$firstChild.localId) !== null && _listNode$firstChild$ !== void 0 ? _listNode$firstChild$ : _adfSchema.uuid.generate();
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
})(_resultTr2);
|
|
150
|
-
}
|
|
130
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 || editorAnalyticsAPI.attachAnalyticsEvent({
|
|
131
|
+
action: _analytics.ACTION.INSERTED,
|
|
132
|
+
actionSubject: _analytics.ACTION_SUBJECT.DOCUMENT,
|
|
133
|
+
actionSubjectId: _analytics.ACTION_SUBJECT_ID.ACTION,
|
|
134
|
+
eventType: _analytics.EVENT_TYPE.TRACK,
|
|
135
|
+
attributes: {
|
|
136
|
+
inputMethod: inputMethod,
|
|
137
|
+
listLocalId: listLocalIdFromNode,
|
|
138
|
+
listSize: listSizeFromNode,
|
|
139
|
+
localId: localIdFromNode,
|
|
140
|
+
position: 0
|
|
141
|
+
}
|
|
142
|
+
})(_resultTr2);
|
|
151
143
|
}
|
|
152
144
|
return _resultTr2;
|
|
153
145
|
}
|
|
@@ -4,7 +4,6 @@ import { getCommonListAnalyticsAttributes } from '@atlaskit/editor-common/lists'
|
|
|
4
4
|
import { transformBetweenListTypes, transformToTaskList, transformTaskListToBlockNodes, isBulletOrOrderedList, isTaskList, getFormattedNode } from '@atlaskit/editor-common/transforms';
|
|
5
5
|
import { TextSelection } from '@atlaskit/editor-prosemirror/state';
|
|
6
6
|
import { safeInsert } from '@atlaskit/editor-prosemirror/utils';
|
|
7
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
7
|
export const toggleTaskList = editorAnalyticsAPI => (targetType = 'paragraph') => {
|
|
9
8
|
return ({
|
|
10
9
|
tr
|
|
@@ -35,22 +34,20 @@ export const toggleTaskList = editorAnalyticsAPI => (targetType = 'paragraph') =
|
|
|
35
34
|
// Insert the empty list at the current selection
|
|
36
35
|
const insertTr = safeInsert(emptyList)(tr);
|
|
37
36
|
if (insertTr !== tr) {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
})(insertTr);
|
|
53
|
-
}
|
|
37
|
+
// Fire INSERT analytics event when creating a new task list
|
|
38
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 ? void 0 : editorAnalyticsAPI.attachAnalyticsEvent({
|
|
39
|
+
action: ACTION.INSERTED,
|
|
40
|
+
actionSubject: ACTION_SUBJECT.DOCUMENT,
|
|
41
|
+
actionSubjectId: ACTION_SUBJECT_ID.ACTION,
|
|
42
|
+
eventType: EVENT_TYPE.TRACK,
|
|
43
|
+
attributes: {
|
|
44
|
+
inputMethod,
|
|
45
|
+
listLocalId,
|
|
46
|
+
listSize: 1,
|
|
47
|
+
localId: itemLocalId,
|
|
48
|
+
position: 0
|
|
49
|
+
}
|
|
50
|
+
})(insertTr);
|
|
54
51
|
|
|
55
52
|
// Set cursor inside the new task item
|
|
56
53
|
const insertPos = insertTr.selection.$from.pos;
|
|
@@ -71,21 +68,20 @@ export const toggleTaskList = editorAnalyticsAPI => (targetType = 'paragraph') =
|
|
|
71
68
|
tr
|
|
72
69
|
};
|
|
73
70
|
const resultTr = transformBetweenListTypes(context);
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
}
|
|
71
|
+
|
|
72
|
+
// Fire CONVERTED analytics event when transforming a list to task list
|
|
73
|
+
if (resultTr && resultTr.docChanged) {
|
|
74
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 ? void 0 : editorAnalyticsAPI.attachAnalyticsEvent({
|
|
75
|
+
action: ACTION.CONVERTED,
|
|
76
|
+
actionSubject: ACTION_SUBJECT.LIST,
|
|
77
|
+
actionSubjectId: ACTION_SUBJECT_ID.FORMAT_LIST_BULLET,
|
|
78
|
+
eventType: EVENT_TYPE.TRACK,
|
|
79
|
+
attributes: {
|
|
80
|
+
...getCommonListAnalyticsAttributes(tr),
|
|
81
|
+
transformedFrom,
|
|
82
|
+
inputMethod
|
|
83
|
+
}
|
|
84
|
+
})(resultTr);
|
|
89
85
|
}
|
|
90
86
|
return resultTr;
|
|
91
87
|
}
|
|
@@ -102,19 +98,17 @@ export const toggleTaskList = editorAnalyticsAPI => (targetType = 'paragraph') =
|
|
|
102
98
|
if (resultTr && resultTr.docChanged && targetType !== 'paragraph') {
|
|
103
99
|
const transformedFrom = ACTION_SUBJECT_ID.FORMAT_LIST_BULLET;
|
|
104
100
|
const targetListType = targetType === 'bulletList' ? ACTION_SUBJECT_ID.FORMAT_LIST_BULLET : ACTION_SUBJECT_ID.FORMAT_LIST_NUMBER;
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
})(resultTr);
|
|
117
|
-
}
|
|
101
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 ? void 0 : editorAnalyticsAPI.attachAnalyticsEvent({
|
|
102
|
+
action: ACTION.CONVERTED,
|
|
103
|
+
actionSubject: ACTION_SUBJECT.LIST,
|
|
104
|
+
actionSubjectId: targetListType,
|
|
105
|
+
eventType: EVENT_TYPE.TRACK,
|
|
106
|
+
attributes: {
|
|
107
|
+
...getCommonListAnalyticsAttributes(tr),
|
|
108
|
+
transformedFrom,
|
|
109
|
+
inputMethod
|
|
110
|
+
}
|
|
111
|
+
})(resultTr);
|
|
118
112
|
}
|
|
119
113
|
return resultTr;
|
|
120
114
|
}
|
|
@@ -133,21 +127,19 @@ export const toggleTaskList = editorAnalyticsAPI => (targetType = 'paragraph') =
|
|
|
133
127
|
const listLocalIdFromNode = (_listNode$attrs$local = listNode === null || listNode === void 0 ? void 0 : (_listNode$attrs = listNode.attrs) === null || _listNode$attrs === void 0 ? void 0 : _listNode$attrs.localId) !== null && _listNode$attrs$local !== void 0 ? _listNode$attrs$local : uuid.generate();
|
|
134
128
|
const listSizeFromNode = (_listNode$childCount = listNode === null || listNode === void 0 ? void 0 : listNode.childCount) !== null && _listNode$childCount !== void 0 ? _listNode$childCount : 0;
|
|
135
129
|
const localIdFromNode = (_listNode$firstChild$ = listNode === null || listNode === void 0 ? void 0 : (_listNode$firstChild = listNode.firstChild) === null || _listNode$firstChild === void 0 ? void 0 : (_listNode$firstChild$2 = _listNode$firstChild.attrs) === null || _listNode$firstChild$2 === void 0 ? void 0 : _listNode$firstChild$2.localId) !== null && _listNode$firstChild$ !== void 0 ? _listNode$firstChild$ : uuid.generate();
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
})(resultTr);
|
|
150
|
-
}
|
|
130
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 ? void 0 : editorAnalyticsAPI.attachAnalyticsEvent({
|
|
131
|
+
action: ACTION.INSERTED,
|
|
132
|
+
actionSubject: ACTION_SUBJECT.DOCUMENT,
|
|
133
|
+
actionSubjectId: ACTION_SUBJECT_ID.ACTION,
|
|
134
|
+
eventType: EVENT_TYPE.TRACK,
|
|
135
|
+
attributes: {
|
|
136
|
+
inputMethod,
|
|
137
|
+
listLocalId: listLocalIdFromNode,
|
|
138
|
+
listSize: listSizeFromNode,
|
|
139
|
+
localId: localIdFromNode,
|
|
140
|
+
position: 0
|
|
141
|
+
}
|
|
142
|
+
})(resultTr);
|
|
151
143
|
}
|
|
152
144
|
return resultTr;
|
|
153
145
|
}
|
|
@@ -7,7 +7,6 @@ import { getCommonListAnalyticsAttributes } from '@atlaskit/editor-common/lists'
|
|
|
7
7
|
import { transformBetweenListTypes, transformToTaskList, transformTaskListToBlockNodes, isBulletOrOrderedList, isTaskList, getFormattedNode } from '@atlaskit/editor-common/transforms';
|
|
8
8
|
import { TextSelection } from '@atlaskit/editor-prosemirror/state';
|
|
9
9
|
import { safeInsert } from '@atlaskit/editor-prosemirror/utils';
|
|
10
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
11
10
|
export var toggleTaskList = function toggleTaskList(editorAnalyticsAPI) {
|
|
12
11
|
return function () {
|
|
13
12
|
var targetType = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'paragraph';
|
|
@@ -33,22 +32,20 @@ export var toggleTaskList = function toggleTaskList(editorAnalyticsAPI) {
|
|
|
33
32
|
// Insert the empty list at the current selection
|
|
34
33
|
var insertTr = safeInsert(emptyList)(tr);
|
|
35
34
|
if (insertTr !== tr) {
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
})(insertTr);
|
|
51
|
-
}
|
|
35
|
+
// Fire INSERT analytics event when creating a new task list
|
|
36
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 || editorAnalyticsAPI.attachAnalyticsEvent({
|
|
37
|
+
action: ACTION.INSERTED,
|
|
38
|
+
actionSubject: ACTION_SUBJECT.DOCUMENT,
|
|
39
|
+
actionSubjectId: ACTION_SUBJECT_ID.ACTION,
|
|
40
|
+
eventType: EVENT_TYPE.TRACK,
|
|
41
|
+
attributes: {
|
|
42
|
+
inputMethod: inputMethod,
|
|
43
|
+
listLocalId: listLocalId,
|
|
44
|
+
listSize: 1,
|
|
45
|
+
localId: itemLocalId,
|
|
46
|
+
position: 0
|
|
47
|
+
}
|
|
48
|
+
})(insertTr);
|
|
52
49
|
|
|
53
50
|
// Set cursor inside the new task item
|
|
54
51
|
var insertPos = insertTr.selection.$from.pos;
|
|
@@ -68,20 +65,19 @@ export var toggleTaskList = function toggleTaskList(editorAnalyticsAPI) {
|
|
|
68
65
|
tr: tr
|
|
69
66
|
};
|
|
70
67
|
var resultTr = transformBetweenListTypes(context);
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
}
|
|
68
|
+
|
|
69
|
+
// Fire CONVERTED analytics event when transforming a list to task list
|
|
70
|
+
if (resultTr && resultTr.docChanged) {
|
|
71
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 || editorAnalyticsAPI.attachAnalyticsEvent({
|
|
72
|
+
action: ACTION.CONVERTED,
|
|
73
|
+
actionSubject: ACTION_SUBJECT.LIST,
|
|
74
|
+
actionSubjectId: ACTION_SUBJECT_ID.FORMAT_LIST_BULLET,
|
|
75
|
+
eventType: EVENT_TYPE.TRACK,
|
|
76
|
+
attributes: _objectSpread(_objectSpread({}, getCommonListAnalyticsAttributes(tr)), {}, {
|
|
77
|
+
transformedFrom: transformedFrom,
|
|
78
|
+
inputMethod: inputMethod
|
|
79
|
+
})
|
|
80
|
+
})(resultTr);
|
|
85
81
|
}
|
|
86
82
|
return resultTr;
|
|
87
83
|
}
|
|
@@ -98,18 +94,16 @@ export var toggleTaskList = function toggleTaskList(editorAnalyticsAPI) {
|
|
|
98
94
|
if (_resultTr && _resultTr.docChanged && targetType !== 'paragraph') {
|
|
99
95
|
var _transformedFrom = ACTION_SUBJECT_ID.FORMAT_LIST_BULLET;
|
|
100
96
|
var targetListType = targetType === 'bulletList' ? ACTION_SUBJECT_ID.FORMAT_LIST_BULLET : ACTION_SUBJECT_ID.FORMAT_LIST_NUMBER;
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
})(_resultTr);
|
|
112
|
-
}
|
|
97
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 || editorAnalyticsAPI.attachAnalyticsEvent({
|
|
98
|
+
action: ACTION.CONVERTED,
|
|
99
|
+
actionSubject: ACTION_SUBJECT.LIST,
|
|
100
|
+
actionSubjectId: targetListType,
|
|
101
|
+
eventType: EVENT_TYPE.TRACK,
|
|
102
|
+
attributes: _objectSpread(_objectSpread({}, getCommonListAnalyticsAttributes(tr)), {}, {
|
|
103
|
+
transformedFrom: _transformedFrom,
|
|
104
|
+
inputMethod: inputMethod
|
|
105
|
+
})
|
|
106
|
+
})(_resultTr);
|
|
113
107
|
}
|
|
114
108
|
return _resultTr;
|
|
115
109
|
}
|
|
@@ -126,21 +120,19 @@ export var toggleTaskList = function toggleTaskList(editorAnalyticsAPI) {
|
|
|
126
120
|
var listLocalIdFromNode = (_listNode$attrs$local = listNode === null || listNode === void 0 || (_listNode$attrs = listNode.attrs) === null || _listNode$attrs === void 0 ? void 0 : _listNode$attrs.localId) !== null && _listNode$attrs$local !== void 0 ? _listNode$attrs$local : uuid.generate();
|
|
127
121
|
var listSizeFromNode = (_listNode$childCount = listNode === null || listNode === void 0 ? void 0 : listNode.childCount) !== null && _listNode$childCount !== void 0 ? _listNode$childCount : 0;
|
|
128
122
|
var localIdFromNode = (_listNode$firstChild$ = listNode === null || listNode === void 0 || (_listNode$firstChild = listNode.firstChild) === null || _listNode$firstChild === void 0 || (_listNode$firstChild = _listNode$firstChild.attrs) === null || _listNode$firstChild === void 0 ? void 0 : _listNode$firstChild.localId) !== null && _listNode$firstChild$ !== void 0 ? _listNode$firstChild$ : uuid.generate();
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
})(_resultTr2);
|
|
143
|
-
}
|
|
123
|
+
editorAnalyticsAPI === null || editorAnalyticsAPI === void 0 || editorAnalyticsAPI.attachAnalyticsEvent({
|
|
124
|
+
action: ACTION.INSERTED,
|
|
125
|
+
actionSubject: ACTION_SUBJECT.DOCUMENT,
|
|
126
|
+
actionSubjectId: ACTION_SUBJECT_ID.ACTION,
|
|
127
|
+
eventType: EVENT_TYPE.TRACK,
|
|
128
|
+
attributes: {
|
|
129
|
+
inputMethod: inputMethod,
|
|
130
|
+
listLocalId: listLocalIdFromNode,
|
|
131
|
+
listSize: listSizeFromNode,
|
|
132
|
+
localId: localIdFromNode,
|
|
133
|
+
position: 0
|
|
134
|
+
}
|
|
135
|
+
})(_resultTr2);
|
|
144
136
|
}
|
|
145
137
|
return _resultTr2;
|
|
146
138
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-tasks-and-decisions",
|
|
3
|
-
"version": "15.
|
|
3
|
+
"version": "15.2.0",
|
|
4
4
|
"description": "Tasks and decisions plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -33,22 +33,22 @@
|
|
|
33
33
|
"@atlaskit/editor-plugin-type-ahead": "^13.0.0",
|
|
34
34
|
"@atlaskit/editor-prosemirror": "^8.0.0",
|
|
35
35
|
"@atlaskit/editor-shared-styles": "^4.0.0",
|
|
36
|
-
"@atlaskit/editor-toolbar": "^2.
|
|
36
|
+
"@atlaskit/editor-toolbar": "^2.2.0",
|
|
37
37
|
"@atlaskit/editor-toolbar-model": "^1.1.0",
|
|
38
38
|
"@atlaskit/heading": "^6.2.0",
|
|
39
|
-
"@atlaskit/icon": "^
|
|
39
|
+
"@atlaskit/icon": "^37.0.0",
|
|
40
40
|
"@atlaskit/platform-feature-flags": "^2.0.0",
|
|
41
|
-
"@atlaskit/primitives": "^20.
|
|
41
|
+
"@atlaskit/primitives": "^20.6.0",
|
|
42
42
|
"@atlaskit/prosemirror-input-rules": "^4.0.0",
|
|
43
43
|
"@atlaskit/task-decision": "^21.4.0",
|
|
44
|
-
"@atlaskit/tmp-editor-statsig": "^124.
|
|
45
|
-
"@atlaskit/tokens": "^15.
|
|
44
|
+
"@atlaskit/tmp-editor-statsig": "^124.1.0",
|
|
45
|
+
"@atlaskit/tokens": "^15.6.0",
|
|
46
46
|
"@babel/runtime": "^7.0.0",
|
|
47
47
|
"@compiled/react": "^0.20.0",
|
|
48
48
|
"bind-event-listener": "^3.0.0"
|
|
49
49
|
},
|
|
50
50
|
"peerDependencies": {
|
|
51
|
-
"@atlaskit/editor-common": "^116.
|
|
51
|
+
"@atlaskit/editor-common": "^116.26.0",
|
|
52
52
|
"react": "^18.2.0",
|
|
53
53
|
"react-dom": "^18.2.0",
|
|
54
54
|
"react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
|
|
@@ -100,9 +100,6 @@
|
|
|
100
100
|
"platform_editor_element_browser_analytic": {
|
|
101
101
|
"type": "boolean"
|
|
102
102
|
},
|
|
103
|
-
"platform_editor_toolbar_task_list_analytics": {
|
|
104
|
-
"type": "boolean"
|
|
105
|
-
},
|
|
106
103
|
"platform_editor_markdown_compatible_toolbar": {
|
|
107
104
|
"type": "boolean"
|
|
108
105
|
}
|