@atlaskit/editor-plugin-insert-block 1.3.2 → 1.3.3
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 +189 -182
- package/dist/cjs/ui/ElementBrowser/InsertMenu.js +2 -1
- package/dist/cjs/ui/ToolbarInsertBlock/index.js +28 -16
- package/dist/es2019/ui/ElementBrowser/InsertMenu.js +2 -1
- package/dist/es2019/ui/ToolbarInsertBlock/index.js +28 -16
- package/dist/esm/ui/ElementBrowser/InsertMenu.js +2 -1
- package/dist/esm/ui/ToolbarInsertBlock/index.js +28 -16
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,491 +1,498 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-insert-block
|
|
2
2
|
|
|
3
|
+
## 1.3.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#103091](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/103091)
|
|
8
|
+
[`736512792df6`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/736512792df6) -
|
|
9
|
+
Fix analytics inputMethod bug for inserting a macro
|
|
10
|
+
|
|
3
11
|
## 1.3.2
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
6
14
|
|
|
7
|
-
-
|
|
15
|
+
- Updated dependencies
|
|
8
16
|
|
|
9
17
|
## 1.3.1
|
|
10
18
|
|
|
11
19
|
### Patch Changes
|
|
12
20
|
|
|
13
|
-
-
|
|
21
|
+
- Updated dependencies
|
|
14
22
|
|
|
15
23
|
## 1.3.0
|
|
16
24
|
|
|
17
25
|
### Minor Changes
|
|
18
26
|
|
|
19
|
-
-
|
|
20
|
-
|
|
21
|
-
|
|
27
|
+
- [#98283](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/98283)
|
|
28
|
+
[`291c762e17a0`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/291c762e17a0) -
|
|
29
|
+
[ED-22802] Introduce insertBlock.actions.toggleAdditionalMenu API
|
|
22
30
|
|
|
23
31
|
### Patch Changes
|
|
24
32
|
|
|
25
|
-
-
|
|
33
|
+
- Updated dependencies
|
|
26
34
|
|
|
27
35
|
## 1.2.5
|
|
28
36
|
|
|
29
37
|
### Patch Changes
|
|
30
38
|
|
|
31
|
-
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
-
|
|
39
|
+
- [#97698](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/97698)
|
|
40
|
+
[`1c7b378c0d3b`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/1c7b378c0d3b) -
|
|
41
|
+
[HOT-108999] We had an incident where the cursor jumps back a character in table headers for any
|
|
42
|
+
language triggering composition on an empty line.This was fixed in a patch bump of
|
|
43
|
+
prosemirror-view. https://github.com/ProseMirror/prosemirror-view/compare/1.33.4...1.33.5
|
|
44
|
+
- Updated dependencies
|
|
37
45
|
|
|
38
46
|
## 1.2.4
|
|
39
47
|
|
|
40
48
|
### Patch Changes
|
|
41
49
|
|
|
42
|
-
-
|
|
50
|
+
- Updated dependencies
|
|
43
51
|
|
|
44
52
|
## 1.2.3
|
|
45
53
|
|
|
46
54
|
### Patch Changes
|
|
47
55
|
|
|
48
|
-
-
|
|
56
|
+
- Updated dependencies
|
|
49
57
|
|
|
50
58
|
## 1.2.2
|
|
51
59
|
|
|
52
60
|
### Patch Changes
|
|
53
61
|
|
|
54
|
-
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
-
|
|
62
|
+
- [#92968](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/92968)
|
|
63
|
+
[`f33e18f5cfa8`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/f33e18f5cfa8) -
|
|
64
|
+
[ux] [ED-22585] - Made sure that table buttons do not render if they are not visible
|
|
65
|
+
- Updated dependencies
|
|
58
66
|
|
|
59
67
|
## 1.2.1
|
|
60
68
|
|
|
61
69
|
### Patch Changes
|
|
62
70
|
|
|
63
|
-
-
|
|
64
|
-
|
|
65
|
-
|
|
71
|
+
- [#94316](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/94316)
|
|
72
|
+
[`35fd5ed8e1d7`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/35fd5ed8e1d7) -
|
|
73
|
+
Upgrading internal dependency `bind-event-listener` to `@^3.0.0`
|
|
66
74
|
|
|
67
75
|
## 1.2.0
|
|
68
76
|
|
|
69
77
|
### Minor Changes
|
|
70
78
|
|
|
71
|
-
-
|
|
72
|
-
|
|
73
|
-
|
|
79
|
+
- [#91934](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/91934)
|
|
80
|
+
[`b76a78c6a199`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/b76a78c6a199) -
|
|
81
|
+
bumped editor-prosemirror version to 4.0.0
|
|
74
82
|
|
|
75
83
|
### Patch Changes
|
|
76
84
|
|
|
77
|
-
-
|
|
85
|
+
- Updated dependencies
|
|
78
86
|
|
|
79
87
|
## 1.1.9
|
|
80
88
|
|
|
81
89
|
### Patch Changes
|
|
82
90
|
|
|
83
|
-
-
|
|
84
|
-
|
|
85
|
-
|
|
91
|
+
- [#85055](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/85055)
|
|
92
|
+
[`0eb5901fd1e7`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/0eb5901fd1e7) -
|
|
93
|
+
Fix the editor not focusing after inserting an emoji from the toolbar.
|
|
86
94
|
|
|
87
95
|
## 1.1.8
|
|
88
96
|
|
|
89
97
|
### Patch Changes
|
|
90
98
|
|
|
91
|
-
-
|
|
92
|
-
|
|
93
|
-
|
|
99
|
+
- [#83116](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/83116)
|
|
100
|
+
[`8d4e99057fe0`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/8d4e99057fe0) -
|
|
101
|
+
Upgrade Typescript from `4.9.5` to `5.4.2`
|
|
94
102
|
|
|
95
103
|
## 1.1.7
|
|
96
104
|
|
|
97
105
|
### Patch Changes
|
|
98
106
|
|
|
99
|
-
-
|
|
107
|
+
- Updated dependencies
|
|
100
108
|
|
|
101
109
|
## 1.1.6
|
|
102
110
|
|
|
103
111
|
### Patch Changes
|
|
104
112
|
|
|
105
|
-
-
|
|
106
|
-
|
|
107
|
-
|
|
113
|
+
- [#81852](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/81852)
|
|
114
|
+
[`c784155d4ad6`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/c784155d4ad6) -
|
|
115
|
+
React 18 types for editor-plugin-insert-block
|
|
108
116
|
|
|
109
117
|
## 1.1.5
|
|
110
118
|
|
|
111
119
|
### Patch Changes
|
|
112
120
|
|
|
113
|
-
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
121
|
+
- [#80518](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/80518)
|
|
122
|
+
[`e0d5e8fd9495`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/e0d5e8fd9495) -
|
|
123
|
+
Migrates some style calls to a slightly different object syntax and other minor cleanup around
|
|
124
|
+
eslint rules.
|
|
117
125
|
|
|
118
126
|
## 1.1.4
|
|
119
127
|
|
|
120
128
|
### Patch Changes
|
|
121
129
|
|
|
122
|
-
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
-
|
|
130
|
+
- [#76323](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/76323)
|
|
131
|
+
[`5beb55a40496`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/5beb55a40496) -
|
|
132
|
+
updated EXTRA_SPACE_EXCLUDING_ELEMENTLIST to fix single item scroll issue
|
|
133
|
+
- Updated dependencies
|
|
126
134
|
|
|
127
135
|
## 1.1.3
|
|
128
136
|
|
|
129
137
|
### Patch Changes
|
|
130
138
|
|
|
131
|
-
-
|
|
139
|
+
- Updated dependencies
|
|
132
140
|
|
|
133
141
|
## 1.1.2
|
|
134
142
|
|
|
135
143
|
### Patch Changes
|
|
136
144
|
|
|
137
|
-
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
145
|
+
- [#77599](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/77599)
|
|
146
|
+
[`a7b1a6b762eb`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/a7b1a6b762eb) -
|
|
147
|
+
[ux] Table picker popup displays text using column x rows pattern and table picker button uses
|
|
148
|
+
label column by row.
|
|
141
149
|
|
|
142
150
|
## 1.1.1
|
|
143
151
|
|
|
144
152
|
### Patch Changes
|
|
145
153
|
|
|
146
|
-
-
|
|
154
|
+
- Updated dependencies
|
|
147
155
|
|
|
148
156
|
## 1.1.0
|
|
149
157
|
|
|
150
158
|
### Minor Changes
|
|
151
159
|
|
|
152
|
-
-
|
|
153
|
-
|
|
154
|
-
|
|
160
|
+
- [#72122](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/72122)
|
|
161
|
+
[`c3186450404a`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/c3186450404a) -
|
|
162
|
+
Breaking change:
|
|
155
163
|
|
|
156
|
-
|
|
164
|
+
## WHAT?:
|
|
157
165
|
|
|
158
|
-
|
|
166
|
+
Removing feature flags:
|
|
159
167
|
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
168
|
+
- singleLayout
|
|
169
|
+
- newInsertionBehaviour
|
|
170
|
+
- interactiveExpand
|
|
171
|
+
- findReplace
|
|
172
|
+
- findReplaceMatchCase
|
|
173
|
+
- extendFloatingToolbar
|
|
166
174
|
|
|
167
|
-
|
|
175
|
+
## WHY?:
|
|
168
176
|
|
|
169
|
-
|
|
170
|
-
|
|
177
|
+
Because the flags and props are unused/by default active. Removing them will reduce our
|
|
178
|
+
maintenance burden
|
|
171
179
|
|
|
172
|
-
|
|
180
|
+
## HOW to update your code:
|
|
173
181
|
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
opted out of the behaviours. If you do have an issue please reach out to #help-editor.
|
|
182
|
+
- If you were using the feature flag - the behaviour is now default and you can remove the flags
|
|
183
|
+
- If you were not using the feature flag - the behaviour is now default.
|
|
184
|
+
- If you have opted out of using the feature flag - we have been careful to ensure no-one has
|
|
185
|
+
opted out of the behaviours. If you do have an issue please reach out to #help-editor.
|
|
179
186
|
|
|
180
187
|
### Patch Changes
|
|
181
188
|
|
|
182
|
-
-
|
|
189
|
+
- Updated dependencies
|
|
183
190
|
|
|
184
191
|
## 1.0.1
|
|
185
192
|
|
|
186
193
|
### Patch Changes
|
|
187
194
|
|
|
188
|
-
-
|
|
189
|
-
|
|
190
|
-
|
|
195
|
+
- [#72440](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/72440)
|
|
196
|
+
[`eee41a9f4bda`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/eee41a9f4bda) -
|
|
197
|
+
[ux] Ensures that when a table is inserted via popup, the table has a blinking cursor.
|
|
191
198
|
|
|
192
199
|
## 1.0.0
|
|
193
200
|
|
|
194
201
|
### Major Changes
|
|
195
202
|
|
|
196
|
-
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
203
|
+
- [#72386](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/72386)
|
|
204
|
+
[`0c52b0be40c1`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/0c52b0be40c1) -
|
|
205
|
+
This changeset exists to bump all editor plugins that currently don't have a major version. This
|
|
206
|
+
is to address an issue with Jira plugin consumption.
|
|
200
207
|
|
|
201
208
|
### Patch Changes
|
|
202
209
|
|
|
203
|
-
-
|
|
210
|
+
- Updated dependencies
|
|
204
211
|
|
|
205
212
|
## 0.3.6
|
|
206
213
|
|
|
207
214
|
### Patch Changes
|
|
208
215
|
|
|
209
|
-
-
|
|
210
|
-
|
|
211
|
-
|
|
216
|
+
- [#72081](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/72081)
|
|
217
|
+
[`4487160917d2`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/4487160917d2) -
|
|
218
|
+
[ux] ED-22052: adds button type attribute to non atlaskit button instances
|
|
212
219
|
|
|
213
220
|
## 0.3.5
|
|
214
221
|
|
|
215
222
|
### Patch Changes
|
|
216
223
|
|
|
217
|
-
-
|
|
218
|
-
|
|
219
|
-
|
|
224
|
+
- [#68572](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/68572)
|
|
225
|
+
[`15d407fe5143`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/15d407fe5143) -
|
|
226
|
+
Upgrading @atlaskit/editor-prosemirror dependency
|
|
220
227
|
|
|
221
228
|
## 0.3.4
|
|
222
229
|
|
|
223
230
|
### Patch Changes
|
|
224
231
|
|
|
225
|
-
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
-
|
|
232
|
+
- [#71128](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/71128)
|
|
233
|
+
[`d8b202a941c9`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/d8b202a941c9) -
|
|
234
|
+
[ux] When the Right Arrow is pressed and the selection reaches the last row of the default popup,
|
|
235
|
+
the grid should expand
|
|
236
|
+
- Updated dependencies
|
|
230
237
|
|
|
231
238
|
## 0.3.3
|
|
232
239
|
|
|
233
240
|
### Patch Changes
|
|
234
241
|
|
|
235
|
-
-
|
|
236
|
-
|
|
237
|
-
|
|
242
|
+
- [#70300](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/70300)
|
|
243
|
+
[`9622d585a805`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/9622d585a805) -
|
|
244
|
+
[ux] decreased popup size when wrapping selection with arrowRight
|
|
238
245
|
|
|
239
246
|
## 0.3.2
|
|
240
247
|
|
|
241
248
|
### Patch Changes
|
|
242
249
|
|
|
243
|
-
-
|
|
250
|
+
- Updated dependencies
|
|
244
251
|
|
|
245
252
|
## 0.3.1
|
|
246
253
|
|
|
247
254
|
### Patch Changes
|
|
248
255
|
|
|
249
|
-
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
-
|
|
256
|
+
- [#68670](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/68670)
|
|
257
|
+
[`801899ef02f2`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/801899ef02f2) -
|
|
258
|
+
[ux] Added accessibility via keyboard for arrows left, right, up and down
|
|
259
|
+
- Updated dependencies
|
|
253
260
|
|
|
254
261
|
## 0.3.0
|
|
255
262
|
|
|
256
263
|
### Minor Changes
|
|
257
264
|
|
|
258
|
-
-
|
|
259
|
-
|
|
260
|
-
|
|
265
|
+
- [#68790](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/68790)
|
|
266
|
+
[`c6d8affc52d1`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/c6d8affc52d1) -
|
|
267
|
+
Support maybeAdd plugins in usePreset. Add typing support for universal preset.
|
|
261
268
|
|
|
262
|
-
|
|
269
|
+
Now when using the editor API with the universal preset
|
|
263
270
|
|
|
264
271
|
### Patch Changes
|
|
265
272
|
|
|
266
|
-
-
|
|
273
|
+
- Updated dependencies
|
|
267
274
|
|
|
268
275
|
## 0.2.27
|
|
269
276
|
|
|
270
277
|
### Patch Changes
|
|
271
278
|
|
|
272
|
-
-
|
|
279
|
+
- Updated dependencies
|
|
273
280
|
|
|
274
281
|
## 0.2.26
|
|
275
282
|
|
|
276
283
|
### Patch Changes
|
|
277
284
|
|
|
278
|
-
-
|
|
279
|
-
|
|
280
|
-
|
|
285
|
+
- [#63634](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/63634)
|
|
286
|
+
[`669b7038b354`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/669b7038b354) -
|
|
287
|
+
chenged aria-label text
|
|
281
288
|
|
|
282
289
|
## 0.2.25
|
|
283
290
|
|
|
284
291
|
### Patch Changes
|
|
285
292
|
|
|
286
|
-
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
-
|
|
293
|
+
- [#67703](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/67703)
|
|
294
|
+
[`d5303cb0f0cb`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/d5303cb0f0cb) -
|
|
295
|
+
When a table is inserted via the table selector popup, an analytics event should be sent with the
|
|
296
|
+
totalRowCount and totalColumnCount and the input method picker. Removed ASCII and TYPEAHEAD
|
|
297
|
+
inputMethod from table selector command.
|
|
298
|
+
- Updated dependencies
|
|
292
299
|
|
|
293
300
|
## 0.2.24
|
|
294
301
|
|
|
295
302
|
### Patch Changes
|
|
296
303
|
|
|
297
|
-
-
|
|
304
|
+
- Updated dependencies
|
|
298
305
|
|
|
299
306
|
## 0.2.23
|
|
300
307
|
|
|
301
308
|
### Patch Changes
|
|
302
309
|
|
|
303
|
-
-
|
|
310
|
+
- Updated dependencies
|
|
304
311
|
|
|
305
312
|
## 0.2.22
|
|
306
313
|
|
|
307
314
|
### Patch Changes
|
|
308
315
|
|
|
309
|
-
-
|
|
316
|
+
- Updated dependencies
|
|
310
317
|
|
|
311
318
|
## 0.2.21
|
|
312
319
|
|
|
313
320
|
### Patch Changes
|
|
314
321
|
|
|
315
|
-
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
-
|
|
322
|
+
- [#67051](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/67051)
|
|
323
|
+
[`08b5bd90a149`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/08b5bd90a149) -
|
|
324
|
+
[ux] The table selector popup should gradually expand to 10 x 10 rows when hovered
|
|
325
|
+
- Updated dependencies
|
|
319
326
|
|
|
320
327
|
## 0.2.20
|
|
321
328
|
|
|
322
329
|
### Patch Changes
|
|
323
330
|
|
|
324
|
-
-
|
|
325
|
-
|
|
326
|
-
|
|
331
|
+
- [#67238](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/67238)
|
|
332
|
+
[`40533849b2ec`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/40533849b2ec) -
|
|
333
|
+
[ED-21835] Change EditorAPI type to always union with undefined
|
|
327
334
|
|
|
328
335
|
## 0.2.19
|
|
329
336
|
|
|
330
337
|
### Patch Changes
|
|
331
338
|
|
|
332
|
-
-
|
|
333
|
-
|
|
334
|
-
|
|
339
|
+
- [#65874](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/65874)
|
|
340
|
+
[`282862992d2a`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/282862992d2a) -
|
|
341
|
+
[ux] added popup to table selector button using mouse movement
|
|
335
342
|
|
|
336
343
|
## 0.2.18
|
|
337
344
|
|
|
338
345
|
### Patch Changes
|
|
339
346
|
|
|
340
|
-
-
|
|
347
|
+
- Updated dependencies
|
|
341
348
|
|
|
342
349
|
## 0.2.17
|
|
343
350
|
|
|
344
351
|
### Patch Changes
|
|
345
352
|
|
|
346
|
-
-
|
|
353
|
+
- Updated dependencies
|
|
347
354
|
|
|
348
355
|
## 0.2.16
|
|
349
356
|
|
|
350
357
|
### Patch Changes
|
|
351
358
|
|
|
352
|
-
-
|
|
359
|
+
- Updated dependencies
|
|
353
360
|
|
|
354
361
|
## 0.2.15
|
|
355
362
|
|
|
356
363
|
### Patch Changes
|
|
357
364
|
|
|
358
|
-
-
|
|
359
|
-
|
|
360
|
-
|
|
365
|
+
- [#65802](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/65802)
|
|
366
|
+
[`438ead060875`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/438ead060875) -
|
|
367
|
+
Ensure all editor plugins are marked as singletons
|
|
361
368
|
|
|
362
369
|
## 0.2.14
|
|
363
370
|
|
|
364
371
|
### Patch Changes
|
|
365
372
|
|
|
366
|
-
-
|
|
373
|
+
- Updated dependencies
|
|
367
374
|
|
|
368
375
|
## 0.2.13
|
|
369
376
|
|
|
370
377
|
### Patch Changes
|
|
371
378
|
|
|
372
|
-
-
|
|
379
|
+
- Updated dependencies
|
|
373
380
|
|
|
374
381
|
## 0.2.12
|
|
375
382
|
|
|
376
383
|
### Patch Changes
|
|
377
384
|
|
|
378
|
-
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
-
|
|
385
|
+
- [#64152](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/64152)
|
|
386
|
+
[`4bc51e1731ba`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/4bc51e1731ba) -
|
|
387
|
+
[ux] Added a table selector button to the full page toolbar and button styles
|
|
388
|
+
- Updated dependencies
|
|
382
389
|
|
|
383
390
|
## 0.2.11
|
|
384
391
|
|
|
385
392
|
### Patch Changes
|
|
386
393
|
|
|
387
|
-
-
|
|
394
|
+
- Updated dependencies
|
|
388
395
|
|
|
389
396
|
## 0.2.10
|
|
390
397
|
|
|
391
398
|
### Patch Changes
|
|
392
399
|
|
|
393
|
-
-
|
|
400
|
+
- Updated dependencies
|
|
394
401
|
|
|
395
402
|
## 0.2.9
|
|
396
403
|
|
|
397
404
|
### Patch Changes
|
|
398
405
|
|
|
399
|
-
-
|
|
406
|
+
- Updated dependencies
|
|
400
407
|
|
|
401
408
|
## 0.2.8
|
|
402
409
|
|
|
403
410
|
### Patch Changes
|
|
404
411
|
|
|
405
|
-
-
|
|
412
|
+
- Updated dependencies
|
|
406
413
|
|
|
407
414
|
## 0.2.7
|
|
408
415
|
|
|
409
416
|
### Patch Changes
|
|
410
417
|
|
|
411
|
-
-
|
|
418
|
+
- Updated dependencies
|
|
412
419
|
|
|
413
420
|
## 0.2.6
|
|
414
421
|
|
|
415
422
|
### Patch Changes
|
|
416
423
|
|
|
417
|
-
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
-
|
|
424
|
+
- [#61337](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/61337)
|
|
425
|
+
[`2d827c1d6c40`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/2d827c1d6c40) -
|
|
426
|
+
Remove emojiProvider property from the sharedState of the emoji plugin. This avoids a performance
|
|
427
|
+
degradation if the provider is not memoised. It can still be retrieved via the provider factory if
|
|
428
|
+
required internally.
|
|
429
|
+
- Updated dependencies
|
|
423
430
|
|
|
424
431
|
## 0.2.5
|
|
425
432
|
|
|
426
433
|
### Patch Changes
|
|
427
434
|
|
|
428
|
-
-
|
|
429
|
-
|
|
430
|
-
|
|
435
|
+
- [#60612](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/60612)
|
|
436
|
+
[`7edc766361a2`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/7edc766361a2) -
|
|
437
|
+
Created an EditorCommad on table plugin to insert a table of custom size
|
|
431
438
|
|
|
432
439
|
## 0.2.4
|
|
433
440
|
|
|
434
441
|
### Patch Changes
|
|
435
442
|
|
|
436
|
-
-
|
|
443
|
+
- Updated dependencies
|
|
437
444
|
|
|
438
445
|
## 0.2.3
|
|
439
446
|
|
|
440
447
|
### Patch Changes
|
|
441
448
|
|
|
442
|
-
-
|
|
449
|
+
- Updated dependencies
|
|
443
450
|
|
|
444
451
|
## 0.2.2
|
|
445
452
|
|
|
446
453
|
### Patch Changes
|
|
447
454
|
|
|
448
|
-
-
|
|
455
|
+
- Updated dependencies
|
|
449
456
|
|
|
450
457
|
## 0.2.1
|
|
451
458
|
|
|
452
459
|
### Patch Changes
|
|
453
460
|
|
|
454
|
-
-
|
|
461
|
+
- Updated dependencies
|
|
455
462
|
|
|
456
463
|
## 0.2.0
|
|
457
464
|
|
|
458
465
|
### Minor Changes
|
|
459
466
|
|
|
460
|
-
-
|
|
461
|
-
|
|
462
|
-
|
|
467
|
+
- [#43507](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/43507)
|
|
468
|
+
[`a9695768de6`](https://bitbucket.org/atlassian/atlassian-frontend/commits/a9695768de6) -
|
|
469
|
+
Extracted insert block plugin code from editor-core to @atlaskit/editor-plugin-insert-block
|
|
463
470
|
|
|
464
471
|
## 0.1.1
|
|
465
472
|
|
|
466
473
|
### Patch Changes
|
|
467
474
|
|
|
468
|
-
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
475
|
+
- [#43646](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/43646)
|
|
476
|
+
[`d43f8e9402f`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d43f8e9402f) - Make
|
|
477
|
+
feature flags plugin optional in all plugins including:
|
|
478
|
+
|
|
479
|
+
- analytics
|
|
480
|
+
- base
|
|
481
|
+
- card
|
|
482
|
+
- code-block
|
|
483
|
+
- expand
|
|
484
|
+
- extension
|
|
485
|
+
- floating-toolbar
|
|
486
|
+
- hyperlink
|
|
487
|
+
- insert-block
|
|
488
|
+
- layout
|
|
489
|
+
- layout
|
|
490
|
+
- list
|
|
491
|
+
- media
|
|
492
|
+
- paste
|
|
493
|
+
- rule
|
|
494
|
+
- table
|
|
495
|
+
- tasks-and-decisions
|
|
496
|
+
|
|
497
|
+
We already treat it as optional in the plugins, so this is just ensuring that the plugin is not
|
|
498
|
+
mandatory to be added to the preset.
|
|
@@ -10,6 +10,7 @@ var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/h
|
|
|
10
10
|
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
|
|
11
11
|
var _react = require("react");
|
|
12
12
|
var _react2 = require("@emotion/react");
|
|
13
|
+
var _analytics = require("@atlaskit/editor-common/analytics");
|
|
13
14
|
var _elementBrowser = require("@atlaskit/editor-common/element-browser");
|
|
14
15
|
var _quickInsert = require("@atlaskit/editor-common/quick-insert");
|
|
15
16
|
var _uiReact = require("@atlaskit/editor-common/ui-react");
|
|
@@ -63,7 +64,7 @@ var InsertMenu = function InsertMenu(_ref) {
|
|
|
63
64
|
if (!editorView.hasFocus()) {
|
|
64
65
|
editorView.focus();
|
|
65
66
|
}
|
|
66
|
-
pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$q = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q === void 0 || _pluginInjectionApi$q.actions.insertItem(item)(editorView.state, editorView.dispatch);
|
|
67
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$q = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q === void 0 || _pluginInjectionApi$q.actions.insertItem(item, _analytics.INPUT_METHOD.TOOLBAR)(editorView.state, editorView.dispatch);
|
|
67
68
|
}, [editorView, toggleVisiblity, pluginInjectionApi]);
|
|
68
69
|
var getItems = (0, _react.useCallback)(function (query, category) {
|
|
69
70
|
var result;
|
|
@@ -242,27 +242,35 @@ var ToolbarInsertBlock = exports.ToolbarInsertBlock = /*#__PURE__*/function (_Re
|
|
|
242
242
|
return Boolean(pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$m2 = pluginInjectionApi.mention) === null || _pluginInjectionApi$m2 === void 0 || (_pluginInjectionApi$m2 = _pluginInjectionApi$m2.actions) === null || _pluginInjectionApi$m2 === void 0 ? void 0 : _pluginInjectionApi$m2.openTypeAhead(inputMethod));
|
|
243
243
|
});
|
|
244
244
|
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "insertTable", function (inputMethod) {
|
|
245
|
-
var _pluginInjectionApi$t, _pluginInjectionApi$t2, _pluginInjectionApi$t3, _pluginInjectionApi$t4;
|
|
246
245
|
var _this$props2 = _this.props,
|
|
247
246
|
pluginInjectionApi = _this$props2.pluginInjectionApi,
|
|
248
247
|
editorView = _this$props2.editorView;
|
|
249
248
|
var state = editorView.state,
|
|
250
249
|
dispatch = editorView.dispatch;
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
250
|
+
|
|
251
|
+
// workaround to solve race condition where cursor is not placed correctly inside table
|
|
252
|
+
queueMicrotask(function () {
|
|
253
|
+
var _pluginInjectionApi$t, _pluginInjectionApi$t2, _pluginInjectionApi$t3;
|
|
254
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$t = pluginInjectionApi.table) === null || _pluginInjectionApi$t === void 0 || (_pluginInjectionApi$t2 = (_pluginInjectionApi$t3 = _pluginInjectionApi$t.actions).insertTable) === null || _pluginInjectionApi$t2 === void 0 || _pluginInjectionApi$t2.call(_pluginInjectionApi$t3, {
|
|
255
|
+
action: _analytics.ACTION.INSERTED,
|
|
256
|
+
actionSubject: _analytics.ACTION_SUBJECT.DOCUMENT,
|
|
257
|
+
actionSubjectId: _analytics.ACTION_SUBJECT_ID.TABLE,
|
|
258
|
+
attributes: {
|
|
259
|
+
inputMethod: inputMethod
|
|
260
|
+
},
|
|
261
|
+
eventType: _analytics.EVENT_TYPE.TRACK
|
|
262
|
+
})(state, dispatch);
|
|
263
|
+
});
|
|
260
264
|
});
|
|
261
265
|
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "insertTableWithSize", function (inputMethod, rowsCount, colsCount) {
|
|
262
266
|
return function () {
|
|
263
|
-
var _pluginInjectionApi$c3, _pluginInjectionApi$t5;
|
|
264
267
|
var pluginInjectionApi = _this.props.pluginInjectionApi;
|
|
265
|
-
|
|
268
|
+
|
|
269
|
+
// workaround to solve race condition where cursor is not placed correctly inside table
|
|
270
|
+
queueMicrotask(function () {
|
|
271
|
+
var _pluginInjectionApi$c3, _pluginInjectionApi$t4;
|
|
272
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$c3 = pluginInjectionApi.core) === null || _pluginInjectionApi$c3 === void 0 || _pluginInjectionApi$c3.actions.execute(pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$t4 = pluginInjectionApi.table) === null || _pluginInjectionApi$t4 === void 0 ? void 0 : _pluginInjectionApi$t4.commands.insertTableWithSize(rowsCount, colsCount, _analytics.INPUT_METHOD.PICKER));
|
|
273
|
+
});
|
|
266
274
|
};
|
|
267
275
|
});
|
|
268
276
|
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "createDate", function (inputMethod) {
|
|
@@ -318,14 +326,14 @@ var ToolbarInsertBlock = exports.ToolbarInsertBlock = /*#__PURE__*/function (_Re
|
|
|
318
326
|
});
|
|
319
327
|
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "insertTaskDecision", function (name, inputMethod) {
|
|
320
328
|
return function () {
|
|
321
|
-
var _pluginInjectionApi$
|
|
329
|
+
var _pluginInjectionApi$t5, _pluginInjectionApi$t6;
|
|
322
330
|
var _this$props7 = _this.props,
|
|
323
331
|
_this$props7$editorVi = _this$props7.editorView,
|
|
324
332
|
state = _this$props7$editorVi.state,
|
|
325
333
|
dispatch = _this$props7$editorVi.dispatch,
|
|
326
334
|
pluginInjectionApi = _this$props7.pluginInjectionApi;
|
|
327
335
|
var listType = name === 'action' ? 'taskList' : 'decisionList';
|
|
328
|
-
return (_pluginInjectionApi$
|
|
336
|
+
return (_pluginInjectionApi$t5 = pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$t6 = pluginInjectionApi.taskDecision) === null || _pluginInjectionApi$t6 === void 0 ? void 0 : _pluginInjectionApi$t6.actions.insertTaskDecision(listType, inputMethod)(state, dispatch)) !== null && _pluginInjectionApi$t5 !== void 0 ? _pluginInjectionApi$t5 : false;
|
|
329
337
|
};
|
|
330
338
|
});
|
|
331
339
|
(0, _defineProperty2.default)((0, _assertThisInitialized2.default)(_this), "insertHorizontalRule", function (inputMethod) {
|
|
@@ -667,7 +675,9 @@ var ToolbarInsertBlock = exports.ToolbarInsertBlock = /*#__PURE__*/function (_Re
|
|
|
667
675
|
isTableSelectorOpen: isTableSelectorOpen,
|
|
668
676
|
isButtonDisabled: (_tableButton = tableButton) === null || _tableButton === void 0 ? void 0 : _tableButton.isDisabled
|
|
669
677
|
})
|
|
670
|
-
}, isTableButtonVisible && (0, _react2.jsx)(_uiMenu.ToolbarButton
|
|
678
|
+
}, isTableButtonVisible && (0, _react2.jsx)(_uiMenu.ToolbarButton
|
|
679
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
680
|
+
, {
|
|
671
681
|
className: "table-toolbar-btn",
|
|
672
682
|
item: tableButton,
|
|
673
683
|
ref: this.tableButtonRef,
|
|
@@ -682,7 +692,9 @@ var ToolbarInsertBlock = exports.ToolbarInsertBlock = /*#__PURE__*/function (_Re
|
|
|
682
692
|
"aria-haspopup": tableButton ? tableButton['aria-haspopup'] : undefined,
|
|
683
693
|
"aria-keyshortcuts": tableButton ? tableButton['aria-keyshortcuts'] : undefined,
|
|
684
694
|
onItemClick: this.insertToolbarMenuItem
|
|
685
|
-
}), isTableButtonVisible && (0, _react2.jsx)(_uiMenu.ToolbarButton
|
|
695
|
+
}), isTableButtonVisible && (0, _react2.jsx)(_uiMenu.ToolbarButton
|
|
696
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
697
|
+
, {
|
|
686
698
|
className: "table-selector-toolbar-btn",
|
|
687
699
|
item: tableSelectorButton,
|
|
688
700
|
testId: String((_tableSelectorButton = tableSelectorButton) === null || _tableSelectorButton === void 0 ? void 0 : _tableSelectorButton.content),
|
|
@@ -3,6 +3,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
3
3
|
|
|
4
4
|
import { useCallback, useState } from 'react';
|
|
5
5
|
import { css, jsx } from '@emotion/react';
|
|
6
|
+
import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
6
7
|
import { ELEMENT_ITEM_HEIGHT, ElementBrowser } from '@atlaskit/editor-common/element-browser';
|
|
7
8
|
import { IconCode, IconDate, IconDecision, IconDivider, IconExpand, IconPanel, IconQuote, IconStatus } from '@atlaskit/editor-common/quick-insert';
|
|
8
9
|
import { withReactEditorViewOuterListeners as withOuterListeners } from '@atlaskit/editor-common/ui-react';
|
|
@@ -46,7 +47,7 @@ const InsertMenu = ({
|
|
|
46
47
|
if (!editorView.hasFocus()) {
|
|
47
48
|
editorView.focus();
|
|
48
49
|
}
|
|
49
|
-
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$q = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q === void 0 ? void 0 : _pluginInjectionApi$q.actions.insertItem(item)(editorView.state, editorView.dispatch);
|
|
50
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$q = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q === void 0 ? void 0 : _pluginInjectionApi$q.actions.insertItem(item, INPUT_METHOD.TOOLBAR)(editorView.state, editorView.dispatch);
|
|
50
51
|
}, [editorView, toggleVisiblity, pluginInjectionApi]);
|
|
51
52
|
const getItems = useCallback((query, category) => {
|
|
52
53
|
let result;
|
|
@@ -246,7 +246,6 @@ export class ToolbarInsertBlock extends React.PureComponent {
|
|
|
246
246
|
return Boolean(pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$m2 = pluginInjectionApi.mention) === null || _pluginInjectionApi$m2 === void 0 ? void 0 : (_pluginInjectionApi$m3 = _pluginInjectionApi$m2.actions) === null || _pluginInjectionApi$m3 === void 0 ? void 0 : _pluginInjectionApi$m3.openTypeAhead(inputMethod));
|
|
247
247
|
});
|
|
248
248
|
_defineProperty(this, "insertTable", inputMethod => {
|
|
249
|
-
var _pluginInjectionApi$t, _pluginInjectionApi$t2, _pluginInjectionApi$t3, _pluginInjectionApi$t4;
|
|
250
249
|
const {
|
|
251
250
|
pluginInjectionApi,
|
|
252
251
|
editorView
|
|
@@ -255,22 +254,31 @@ export class ToolbarInsertBlock extends React.PureComponent {
|
|
|
255
254
|
state,
|
|
256
255
|
dispatch
|
|
257
256
|
} = editorView;
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
257
|
+
|
|
258
|
+
// workaround to solve race condition where cursor is not placed correctly inside table
|
|
259
|
+
queueMicrotask(() => {
|
|
260
|
+
var _pluginInjectionApi$t, _pluginInjectionApi$t2, _pluginInjectionApi$t3;
|
|
261
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$t = pluginInjectionApi.table) === null || _pluginInjectionApi$t === void 0 ? void 0 : (_pluginInjectionApi$t2 = (_pluginInjectionApi$t3 = _pluginInjectionApi$t.actions).insertTable) === null || _pluginInjectionApi$t2 === void 0 ? void 0 : _pluginInjectionApi$t2.call(_pluginInjectionApi$t3, {
|
|
262
|
+
action: ACTION.INSERTED,
|
|
263
|
+
actionSubject: ACTION_SUBJECT.DOCUMENT,
|
|
264
|
+
actionSubjectId: ACTION_SUBJECT_ID.TABLE,
|
|
265
|
+
attributes: {
|
|
266
|
+
inputMethod
|
|
267
|
+
},
|
|
268
|
+
eventType: EVENT_TYPE.TRACK
|
|
269
|
+
})(state, dispatch);
|
|
270
|
+
});
|
|
267
271
|
});
|
|
268
272
|
_defineProperty(this, "insertTableWithSize", (inputMethod, rowsCount, colsCount) => () => {
|
|
269
|
-
var _pluginInjectionApi$c3, _pluginInjectionApi$t5;
|
|
270
273
|
const {
|
|
271
274
|
pluginInjectionApi
|
|
272
275
|
} = this.props;
|
|
273
|
-
|
|
276
|
+
|
|
277
|
+
// workaround to solve race condition where cursor is not placed correctly inside table
|
|
278
|
+
queueMicrotask(() => {
|
|
279
|
+
var _pluginInjectionApi$c3, _pluginInjectionApi$t4;
|
|
280
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$c3 = pluginInjectionApi.core) === null || _pluginInjectionApi$c3 === void 0 ? void 0 : _pluginInjectionApi$c3.actions.execute(pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$t4 = pluginInjectionApi.table) === null || _pluginInjectionApi$t4 === void 0 ? void 0 : _pluginInjectionApi$t4.commands.insertTableWithSize(rowsCount, colsCount, INPUT_METHOD.PICKER));
|
|
281
|
+
});
|
|
274
282
|
});
|
|
275
283
|
_defineProperty(this, "createDate", inputMethod => {
|
|
276
284
|
var _pluginInjectionApi$c4, _pluginInjectionApi$d, _pluginInjectionApi$d2;
|
|
@@ -330,7 +338,7 @@ export class ToolbarInsertBlock extends React.PureComponent {
|
|
|
330
338
|
return true;
|
|
331
339
|
});
|
|
332
340
|
_defineProperty(this, "insertTaskDecision", (name, inputMethod) => () => {
|
|
333
|
-
var _pluginInjectionApi$
|
|
341
|
+
var _pluginInjectionApi$t5, _pluginInjectionApi$t6;
|
|
334
342
|
const {
|
|
335
343
|
editorView: {
|
|
336
344
|
state,
|
|
@@ -339,7 +347,7 @@ export class ToolbarInsertBlock extends React.PureComponent {
|
|
|
339
347
|
pluginInjectionApi
|
|
340
348
|
} = this.props;
|
|
341
349
|
const listType = name === 'action' ? 'taskList' : 'decisionList';
|
|
342
|
-
return (_pluginInjectionApi$
|
|
350
|
+
return (_pluginInjectionApi$t5 = pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$t6 = pluginInjectionApi.taskDecision) === null || _pluginInjectionApi$t6 === void 0 ? void 0 : _pluginInjectionApi$t6.actions.insertTaskDecision(listType, inputMethod)(state, dispatch)) !== null && _pluginInjectionApi$t5 !== void 0 ? _pluginInjectionApi$t5 : false;
|
|
343
351
|
});
|
|
344
352
|
_defineProperty(this, "insertHorizontalRule", inputMethod => {
|
|
345
353
|
var _pluginInjectionApi$r, _pluginInjectionApi$r2;
|
|
@@ -702,7 +710,9 @@ export class ToolbarInsertBlock extends React.PureComponent {
|
|
|
702
710
|
isTableSelectorOpen,
|
|
703
711
|
isButtonDisabled: (_tableButton = tableButton) === null || _tableButton === void 0 ? void 0 : _tableButton.isDisabled
|
|
704
712
|
})
|
|
705
|
-
}, isTableButtonVisible && jsx(ToolbarButton
|
|
713
|
+
}, isTableButtonVisible && jsx(ToolbarButton
|
|
714
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
715
|
+
, {
|
|
706
716
|
className: "table-toolbar-btn",
|
|
707
717
|
item: tableButton,
|
|
708
718
|
ref: this.tableButtonRef,
|
|
@@ -717,7 +727,9 @@ export class ToolbarInsertBlock extends React.PureComponent {
|
|
|
717
727
|
"aria-haspopup": tableButton ? tableButton['aria-haspopup'] : undefined,
|
|
718
728
|
"aria-keyshortcuts": tableButton ? tableButton['aria-keyshortcuts'] : undefined,
|
|
719
729
|
onItemClick: this.insertToolbarMenuItem
|
|
720
|
-
}), isTableButtonVisible && jsx(ToolbarButton
|
|
730
|
+
}), isTableButtonVisible && jsx(ToolbarButton
|
|
731
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
732
|
+
, {
|
|
721
733
|
className: "table-selector-toolbar-btn",
|
|
722
734
|
item: tableSelectorButton,
|
|
723
735
|
testId: String((_tableSelectorButton = tableSelectorButton) === null || _tableSelectorButton === void 0 ? void 0 : _tableSelectorButton.content),
|
|
@@ -6,6 +6,7 @@ var _excluded = ["children"];
|
|
|
6
6
|
|
|
7
7
|
import { useCallback, useState } from 'react';
|
|
8
8
|
import { css, jsx } from '@emotion/react';
|
|
9
|
+
import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
9
10
|
import { ELEMENT_ITEM_HEIGHT, ElementBrowser } from '@atlaskit/editor-common/element-browser';
|
|
10
11
|
import { IconCode, IconDate, IconDecision, IconDivider, IconExpand, IconPanel, IconQuote, IconStatus } from '@atlaskit/editor-common/quick-insert';
|
|
11
12
|
import { withReactEditorViewOuterListeners as withOuterListeners } from '@atlaskit/editor-common/ui-react';
|
|
@@ -57,7 +58,7 @@ var InsertMenu = function InsertMenu(_ref) {
|
|
|
57
58
|
if (!editorView.hasFocus()) {
|
|
58
59
|
editorView.focus();
|
|
59
60
|
}
|
|
60
|
-
pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$q = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q === void 0 || _pluginInjectionApi$q.actions.insertItem(item)(editorView.state, editorView.dispatch);
|
|
61
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$q = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q === void 0 || _pluginInjectionApi$q.actions.insertItem(item, INPUT_METHOD.TOOLBAR)(editorView.state, editorView.dispatch);
|
|
61
62
|
}, [editorView, toggleVisiblity, pluginInjectionApi]);
|
|
62
63
|
var getItems = useCallback(function (query, category) {
|
|
63
64
|
var result;
|
|
@@ -232,27 +232,35 @@ export var ToolbarInsertBlock = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
232
232
|
return Boolean(pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$m2 = pluginInjectionApi.mention) === null || _pluginInjectionApi$m2 === void 0 || (_pluginInjectionApi$m2 = _pluginInjectionApi$m2.actions) === null || _pluginInjectionApi$m2 === void 0 ? void 0 : _pluginInjectionApi$m2.openTypeAhead(inputMethod));
|
|
233
233
|
});
|
|
234
234
|
_defineProperty(_assertThisInitialized(_this), "insertTable", function (inputMethod) {
|
|
235
|
-
var _pluginInjectionApi$t, _pluginInjectionApi$t2, _pluginInjectionApi$t3, _pluginInjectionApi$t4;
|
|
236
235
|
var _this$props2 = _this.props,
|
|
237
236
|
pluginInjectionApi = _this$props2.pluginInjectionApi,
|
|
238
237
|
editorView = _this$props2.editorView;
|
|
239
238
|
var state = editorView.state,
|
|
240
239
|
dispatch = editorView.dispatch;
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
240
|
+
|
|
241
|
+
// workaround to solve race condition where cursor is not placed correctly inside table
|
|
242
|
+
queueMicrotask(function () {
|
|
243
|
+
var _pluginInjectionApi$t, _pluginInjectionApi$t2, _pluginInjectionApi$t3;
|
|
244
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$t = pluginInjectionApi.table) === null || _pluginInjectionApi$t === void 0 || (_pluginInjectionApi$t2 = (_pluginInjectionApi$t3 = _pluginInjectionApi$t.actions).insertTable) === null || _pluginInjectionApi$t2 === void 0 || _pluginInjectionApi$t2.call(_pluginInjectionApi$t3, {
|
|
245
|
+
action: ACTION.INSERTED,
|
|
246
|
+
actionSubject: ACTION_SUBJECT.DOCUMENT,
|
|
247
|
+
actionSubjectId: ACTION_SUBJECT_ID.TABLE,
|
|
248
|
+
attributes: {
|
|
249
|
+
inputMethod: inputMethod
|
|
250
|
+
},
|
|
251
|
+
eventType: EVENT_TYPE.TRACK
|
|
252
|
+
})(state, dispatch);
|
|
253
|
+
});
|
|
250
254
|
});
|
|
251
255
|
_defineProperty(_assertThisInitialized(_this), "insertTableWithSize", function (inputMethod, rowsCount, colsCount) {
|
|
252
256
|
return function () {
|
|
253
|
-
var _pluginInjectionApi$c3, _pluginInjectionApi$t5;
|
|
254
257
|
var pluginInjectionApi = _this.props.pluginInjectionApi;
|
|
255
|
-
|
|
258
|
+
|
|
259
|
+
// workaround to solve race condition where cursor is not placed correctly inside table
|
|
260
|
+
queueMicrotask(function () {
|
|
261
|
+
var _pluginInjectionApi$c3, _pluginInjectionApi$t4;
|
|
262
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$c3 = pluginInjectionApi.core) === null || _pluginInjectionApi$c3 === void 0 || _pluginInjectionApi$c3.actions.execute(pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$t4 = pluginInjectionApi.table) === null || _pluginInjectionApi$t4 === void 0 ? void 0 : _pluginInjectionApi$t4.commands.insertTableWithSize(rowsCount, colsCount, INPUT_METHOD.PICKER));
|
|
263
|
+
});
|
|
256
264
|
};
|
|
257
265
|
});
|
|
258
266
|
_defineProperty(_assertThisInitialized(_this), "createDate", function (inputMethod) {
|
|
@@ -308,14 +316,14 @@ export var ToolbarInsertBlock = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
308
316
|
});
|
|
309
317
|
_defineProperty(_assertThisInitialized(_this), "insertTaskDecision", function (name, inputMethod) {
|
|
310
318
|
return function () {
|
|
311
|
-
var _pluginInjectionApi$
|
|
319
|
+
var _pluginInjectionApi$t5, _pluginInjectionApi$t6;
|
|
312
320
|
var _this$props7 = _this.props,
|
|
313
321
|
_this$props7$editorVi = _this$props7.editorView,
|
|
314
322
|
state = _this$props7$editorVi.state,
|
|
315
323
|
dispatch = _this$props7$editorVi.dispatch,
|
|
316
324
|
pluginInjectionApi = _this$props7.pluginInjectionApi;
|
|
317
325
|
var listType = name === 'action' ? 'taskList' : 'decisionList';
|
|
318
|
-
return (_pluginInjectionApi$
|
|
326
|
+
return (_pluginInjectionApi$t5 = pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$t6 = pluginInjectionApi.taskDecision) === null || _pluginInjectionApi$t6 === void 0 ? void 0 : _pluginInjectionApi$t6.actions.insertTaskDecision(listType, inputMethod)(state, dispatch)) !== null && _pluginInjectionApi$t5 !== void 0 ? _pluginInjectionApi$t5 : false;
|
|
319
327
|
};
|
|
320
328
|
});
|
|
321
329
|
_defineProperty(_assertThisInitialized(_this), "insertHorizontalRule", function (inputMethod) {
|
|
@@ -657,7 +665,9 @@ export var ToolbarInsertBlock = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
657
665
|
isTableSelectorOpen: isTableSelectorOpen,
|
|
658
666
|
isButtonDisabled: (_tableButton = tableButton) === null || _tableButton === void 0 ? void 0 : _tableButton.isDisabled
|
|
659
667
|
})
|
|
660
|
-
}, isTableButtonVisible && jsx(ToolbarButton
|
|
668
|
+
}, isTableButtonVisible && jsx(ToolbarButton
|
|
669
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
670
|
+
, {
|
|
661
671
|
className: "table-toolbar-btn",
|
|
662
672
|
item: tableButton,
|
|
663
673
|
ref: this.tableButtonRef,
|
|
@@ -672,7 +682,9 @@ export var ToolbarInsertBlock = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
672
682
|
"aria-haspopup": tableButton ? tableButton['aria-haspopup'] : undefined,
|
|
673
683
|
"aria-keyshortcuts": tableButton ? tableButton['aria-keyshortcuts'] : undefined,
|
|
674
684
|
onItemClick: this.insertToolbarMenuItem
|
|
675
|
-
}), isTableButtonVisible && jsx(ToolbarButton
|
|
685
|
+
}), isTableButtonVisible && jsx(ToolbarButton
|
|
686
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
687
|
+
, {
|
|
676
688
|
className: "table-selector-toolbar-btn",
|
|
677
689
|
item: tableSelectorButton,
|
|
678
690
|
testId: String((_tableSelectorButton = tableSelectorButton) === null || _tableSelectorButton === void 0 ? void 0 : _tableSelectorButton.content),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-insert-block",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.3",
|
|
4
4
|
"description": "Insert block plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
".": "./src/index.ts"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@atlaskit/editor-common": "^81.
|
|
36
|
+
"@atlaskit/editor-common": "^81.1.0",
|
|
37
37
|
"@atlaskit/editor-plugin-analytics": "^1.2.0",
|
|
38
38
|
"@atlaskit/editor-plugin-block-type": "^3.4.0",
|
|
39
39
|
"@atlaskit/editor-plugin-code-block": "^1.3.0",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"@atlaskit/editor-plugin-image-upload": "^1.1.0",
|
|
46
46
|
"@atlaskit/editor-plugin-layout": "^1.2.0",
|
|
47
47
|
"@atlaskit/editor-plugin-media": "^1.20.0",
|
|
48
|
-
"@atlaskit/editor-plugin-mentions": "^1.
|
|
48
|
+
"@atlaskit/editor-plugin-mentions": "^1.5.0",
|
|
49
49
|
"@atlaskit/editor-plugin-panel": "^1.2.0",
|
|
50
50
|
"@atlaskit/editor-plugin-placeholder-text": "^1.2.0",
|
|
51
51
|
"@atlaskit/editor-plugin-quick-insert": "^1.1.0",
|