@atlaskit/editor-plugin-mentions 1.5.1 → 1.6.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 +8 -0
- package/dist/cjs/analytics.js +3 -2
- package/dist/cjs/type-ahead/index.js +3 -2
- package/dist/es2019/analytics.js +3 -2
- package/dist/es2019/type-ahead/index.js +3 -2
- package/dist/esm/analytics.js +3 -2
- package/dist/esm/type-ahead/index.js +3 -2
- package/dist/types/analytics.d.ts +1 -1
- package/dist/types-ts4.5/analytics.d.ts +1 -1
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-mentions
|
|
2
2
|
|
|
3
|
+
## 1.6.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#108100](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/108100)
|
|
8
|
+
[`c854f5415176c`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/c854f5415176c) -
|
|
9
|
+
Add localId to mentionTypeahead click event attributes
|
|
10
|
+
|
|
3
11
|
## 1.5.1
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
package/dist/cjs/analytics.js
CHANGED
|
@@ -95,7 +95,7 @@ var buildTypeAheadInviteItemClickedPayload = exports.buildTypeAheadInviteItemCli
|
|
|
95
95
|
userRole: userRole
|
|
96
96
|
});
|
|
97
97
|
};
|
|
98
|
-
var buildTypeAheadInsertedPayload = exports.buildTypeAheadInsertedPayload = function buildTypeAheadInsertedPayload(duration, upKeyCount, downKeyCount, sessionId, insertType, mention, mentionList, query, contextIdentifierProvider, taskListId, taskItemId) {
|
|
98
|
+
var buildTypeAheadInsertedPayload = exports.buildTypeAheadInsertedPayload = function buildTypeAheadInsertedPayload(duration, upKeyCount, downKeyCount, sessionId, insertType, mention, mentionLocalId, mentionList, query, contextIdentifierProvider, taskListId, taskItemId) {
|
|
99
99
|
var _extractAttributesFro3 = extractAttributesFromQuery(query),
|
|
100
100
|
queryLength = _extractAttributesFro3.queryLength,
|
|
101
101
|
spaceInQuery = _extractAttributesFro3.spaceInQuery;
|
|
@@ -115,7 +115,8 @@ var buildTypeAheadInsertedPayload = exports.buildTypeAheadInsertedPayload = func
|
|
|
115
115
|
memberCount: (0, _utils.isTeamType)(mention.userType) && mention.context ? mention.context.memberCount : null,
|
|
116
116
|
includesYou: (0, _utils.isTeamType)(mention.userType) && mention.context ? mention.context.includesYou : null,
|
|
117
117
|
taskListId: taskListId,
|
|
118
|
-
taskItemId: taskItemId
|
|
118
|
+
taskItemId: taskItemId,
|
|
119
|
+
localId: mentionLocalId
|
|
119
120
|
});
|
|
120
121
|
if (contextIdentifierProvider) {
|
|
121
122
|
analyticsPayload.containerId = contextIdentifierProvider.containerId || undefined;
|
|
@@ -315,7 +315,8 @@ var createTypeAheadConfig = exports.createTypeAheadConfig = function createTypeA
|
|
|
315
315
|
taskItemId = taskItem.node.attrs.localId;
|
|
316
316
|
}
|
|
317
317
|
}
|
|
318
|
-
|
|
318
|
+
var mentionLocalId = (0, _uuid.default)();
|
|
319
|
+
fireEvent((0, _analytics.buildTypeAheadInsertedPayload)(pickerElapsedTime, stats.keyCount.arrowUp, stats.keyCount.arrowDown, sessionId, mode, item.mention, mentionLocalId, sourceListItem.map(function (x) {
|
|
319
320
|
return x.mention;
|
|
320
321
|
}), query, contextIdentifierProvider, taskListId, taskItemId));
|
|
321
322
|
sessionId = (0, _uuid.default)();
|
|
@@ -334,7 +335,7 @@ var createTypeAheadConfig = exports.createTypeAheadConfig = function createTypeA
|
|
|
334
335
|
id: id,
|
|
335
336
|
accessLevel: accessLevel,
|
|
336
337
|
userType: userType === 'DEFAULT' ? null : userType,
|
|
337
|
-
localId:
|
|
338
|
+
localId: mentionLocalId
|
|
338
339
|
});
|
|
339
340
|
var space = schema.text(' ');
|
|
340
341
|
return insert(_model.Fragment.from([mentionNode, space]));
|
package/dist/es2019/analytics.js
CHANGED
|
@@ -82,7 +82,7 @@ export const buildTypeAheadInviteItemClickedPayload = (duration, upKeyCount, dow
|
|
|
82
82
|
userRole
|
|
83
83
|
});
|
|
84
84
|
};
|
|
85
|
-
export const buildTypeAheadInsertedPayload = (duration, upKeyCount, downKeyCount, sessionId, insertType, mention, mentionList, query, contextIdentifierProvider, taskListId, taskItemId) => {
|
|
85
|
+
export const buildTypeAheadInsertedPayload = (duration, upKeyCount, downKeyCount, sessionId, insertType, mention, mentionLocalId, mentionList, query, contextIdentifierProvider, taskListId, taskItemId) => {
|
|
86
86
|
const {
|
|
87
87
|
queryLength,
|
|
88
88
|
spaceInQuery
|
|
@@ -103,7 +103,8 @@ export const buildTypeAheadInsertedPayload = (duration, upKeyCount, downKeyCount
|
|
|
103
103
|
memberCount: isTeamType(mention.userType) && mention.context ? mention.context.memberCount : null,
|
|
104
104
|
includesYou: isTeamType(mention.userType) && mention.context ? mention.context.includesYou : null,
|
|
105
105
|
taskListId,
|
|
106
|
-
taskItemId
|
|
106
|
+
taskItemId,
|
|
107
|
+
localId: mentionLocalId
|
|
107
108
|
});
|
|
108
109
|
if (contextIdentifierProvider) {
|
|
109
110
|
analyticsPayload.containerId = contextIdentifierProvider.containerId || undefined;
|
|
@@ -301,7 +301,8 @@ export const createTypeAheadConfig = ({
|
|
|
301
301
|
taskItemId = taskItem.node.attrs.localId;
|
|
302
302
|
}
|
|
303
303
|
}
|
|
304
|
-
|
|
304
|
+
const mentionLocalId = uuid();
|
|
305
|
+
fireEvent(buildTypeAheadInsertedPayload(pickerElapsedTime, stats.keyCount.arrowUp, stats.keyCount.arrowDown, sessionId, mode, item.mention, mentionLocalId, sourceListItem.map(x => x.mention), query, contextIdentifierProvider, taskListId, taskItemId));
|
|
305
306
|
sessionId = uuid();
|
|
306
307
|
if (mentionProvider && isTeamType(userType)) {
|
|
307
308
|
return insert(buildNodesForTeamMention(schema, item.mention, mentionProvider, sanitizePrivateContent));
|
|
@@ -318,7 +319,7 @@ export const createTypeAheadConfig = ({
|
|
|
318
319
|
id,
|
|
319
320
|
accessLevel,
|
|
320
321
|
userType: userType === 'DEFAULT' ? null : userType,
|
|
321
|
-
localId:
|
|
322
|
+
localId: mentionLocalId
|
|
322
323
|
});
|
|
323
324
|
const space = schema.text(' ');
|
|
324
325
|
return insert(Fragment.from([mentionNode, space]));
|
package/dist/esm/analytics.js
CHANGED
|
@@ -88,7 +88,7 @@ export var buildTypeAheadInviteItemClickedPayload = function buildTypeAheadInvit
|
|
|
88
88
|
userRole: userRole
|
|
89
89
|
});
|
|
90
90
|
};
|
|
91
|
-
export var buildTypeAheadInsertedPayload = function buildTypeAheadInsertedPayload(duration, upKeyCount, downKeyCount, sessionId, insertType, mention, mentionList, query, contextIdentifierProvider, taskListId, taskItemId) {
|
|
91
|
+
export var buildTypeAheadInsertedPayload = function buildTypeAheadInsertedPayload(duration, upKeyCount, downKeyCount, sessionId, insertType, mention, mentionLocalId, mentionList, query, contextIdentifierProvider, taskListId, taskItemId) {
|
|
92
92
|
var _extractAttributesFro3 = extractAttributesFromQuery(query),
|
|
93
93
|
queryLength = _extractAttributesFro3.queryLength,
|
|
94
94
|
spaceInQuery = _extractAttributesFro3.spaceInQuery;
|
|
@@ -108,7 +108,8 @@ export var buildTypeAheadInsertedPayload = function buildTypeAheadInsertedPayloa
|
|
|
108
108
|
memberCount: isTeamType(mention.userType) && mention.context ? mention.context.memberCount : null,
|
|
109
109
|
includesYou: isTeamType(mention.userType) && mention.context ? mention.context.includesYou : null,
|
|
110
110
|
taskListId: taskListId,
|
|
111
|
-
taskItemId: taskItemId
|
|
111
|
+
taskItemId: taskItemId,
|
|
112
|
+
localId: mentionLocalId
|
|
112
113
|
});
|
|
113
114
|
if (contextIdentifierProvider) {
|
|
114
115
|
analyticsPayload.containerId = contextIdentifierProvider.containerId || undefined;
|
|
@@ -303,7 +303,8 @@ export var createTypeAheadConfig = function createTypeAheadConfig(_ref6) {
|
|
|
303
303
|
taskItemId = taskItem.node.attrs.localId;
|
|
304
304
|
}
|
|
305
305
|
}
|
|
306
|
-
|
|
306
|
+
var mentionLocalId = uuid();
|
|
307
|
+
fireEvent(buildTypeAheadInsertedPayload(pickerElapsedTime, stats.keyCount.arrowUp, stats.keyCount.arrowDown, sessionId, mode, item.mention, mentionLocalId, sourceListItem.map(function (x) {
|
|
307
308
|
return x.mention;
|
|
308
309
|
}), query, contextIdentifierProvider, taskListId, taskItemId));
|
|
309
310
|
sessionId = uuid();
|
|
@@ -322,7 +323,7 @@ export var createTypeAheadConfig = function createTypeAheadConfig(_ref6) {
|
|
|
322
323
|
id: id,
|
|
323
324
|
accessLevel: accessLevel,
|
|
324
325
|
userType: userType === 'DEFAULT' ? null : userType,
|
|
325
|
-
localId:
|
|
326
|
+
localId: mentionLocalId
|
|
326
327
|
});
|
|
327
328
|
var space = schema.text(' ');
|
|
328
329
|
return insert(Fragment.from([mentionNode, space]));
|
|
@@ -8,5 +8,5 @@ export declare const buildAnalyticsPayload: (actionSubject: string, action: stri
|
|
|
8
8
|
export declare const buildTypeAheadCancelPayload: (duration: number, upKeyCount: number, downKeyCount: number, sessionId: string, query?: string) => GasPayload;
|
|
9
9
|
export declare const buildTypeAheadInviteItemViewedPayload: (sessionId: string, contextIdentifierProvider?: ContextIdentifierProvider, userRole?: UserRole) => GasPayload;
|
|
10
10
|
export declare const buildTypeAheadInviteItemClickedPayload: (duration: number, upKeyCount: number, downKeyCount: number, sessionId: string, insertType: SelectItemMode, query?: string, contextIdentifierProvider?: ContextIdentifierProvider, userRole?: UserRole) => GasPayload;
|
|
11
|
-
export declare const buildTypeAheadInsertedPayload: (duration: number, upKeyCount: number, downKeyCount: number, sessionId: string, insertType: SelectItemMode, mention: MentionDescription, mentionList?: MentionDescription[], query?: string, contextIdentifierProvider?: ContextIdentifierProvider, taskListId?: string, taskItemId?: string) => GasPayload;
|
|
11
|
+
export declare const buildTypeAheadInsertedPayload: (duration: number, upKeyCount: number, downKeyCount: number, sessionId: string, insertType: SelectItemMode, mention: MentionDescription, mentionLocalId: string, mentionList?: MentionDescription[], query?: string, contextIdentifierProvider?: ContextIdentifierProvider, taskListId?: string, taskItemId?: string) => GasPayload;
|
|
12
12
|
export declare const buildTypeAheadRenderedPayload: (duration: number, userIds: Array<string> | null, query: string, teams: TeamInfoAttrAnalytics[] | null) => GasPayload;
|
|
@@ -8,5 +8,5 @@ export declare const buildAnalyticsPayload: (actionSubject: string, action: stri
|
|
|
8
8
|
export declare const buildTypeAheadCancelPayload: (duration: number, upKeyCount: number, downKeyCount: number, sessionId: string, query?: string) => GasPayload;
|
|
9
9
|
export declare const buildTypeAheadInviteItemViewedPayload: (sessionId: string, contextIdentifierProvider?: ContextIdentifierProvider, userRole?: UserRole) => GasPayload;
|
|
10
10
|
export declare const buildTypeAheadInviteItemClickedPayload: (duration: number, upKeyCount: number, downKeyCount: number, sessionId: string, insertType: SelectItemMode, query?: string, contextIdentifierProvider?: ContextIdentifierProvider, userRole?: UserRole) => GasPayload;
|
|
11
|
-
export declare const buildTypeAheadInsertedPayload: (duration: number, upKeyCount: number, downKeyCount: number, sessionId: string, insertType: SelectItemMode, mention: MentionDescription, mentionList?: MentionDescription[], query?: string, contextIdentifierProvider?: ContextIdentifierProvider, taskListId?: string, taskItemId?: string) => GasPayload;
|
|
11
|
+
export declare const buildTypeAheadInsertedPayload: (duration: number, upKeyCount: number, downKeyCount: number, sessionId: string, insertType: SelectItemMode, mention: MentionDescription, mentionLocalId: string, mentionList?: MentionDescription[], query?: string, contextIdentifierProvider?: ContextIdentifierProvider, taskListId?: string, taskItemId?: string) => GasPayload;
|
|
12
12
|
export declare const buildTypeAheadRenderedPayload: (duration: number, userIds: Array<string> | null, query: string, teams: TeamInfoAttrAnalytics[] | null) => GasPayload;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-mentions",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"description": "Mentions plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -35,15 +35,15 @@
|
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@atlaskit/adf-schema": "^36.10.7",
|
|
37
37
|
"@atlaskit/analytics-gas-types": "^5.1.0",
|
|
38
|
-
"@atlaskit/editor-common": "^82.
|
|
38
|
+
"@atlaskit/editor-common": "^82.1.0",
|
|
39
39
|
"@atlaskit/editor-plugin-analytics": "^1.2.0",
|
|
40
40
|
"@atlaskit/editor-plugin-context-identifier": "^1.1.0",
|
|
41
41
|
"@atlaskit/editor-plugin-type-ahead": "^1.2.0",
|
|
42
42
|
"@atlaskit/editor-prosemirror": "4.0.1",
|
|
43
43
|
"@atlaskit/icon": "^22.3.0",
|
|
44
|
-
"@atlaskit/mention": "^23.
|
|
44
|
+
"@atlaskit/mention": "^23.2.0",
|
|
45
45
|
"@atlaskit/platform-feature-flags": "^0.2.5",
|
|
46
|
-
"@atlaskit/theme": "^12.
|
|
46
|
+
"@atlaskit/theme": "^12.9.0",
|
|
47
47
|
"@atlaskit/tokens": "^1.49.0",
|
|
48
48
|
"@babel/runtime": "^7.0.0",
|
|
49
49
|
"@emotion/react": "^11.7.1",
|