@atlaskit/editor-plugin-text-formatting 1.7.0 → 1.7.2
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/.eslintrc.js +5 -5
- package/CHANGELOG.md +258 -244
- package/LICENSE.md +6 -8
- package/dist/cjs/pm-plugins/input-rule.js +2 -1
- package/dist/cjs/ui/Toolbar/index.js +3 -1
- package/dist/es2019/pm-plugins/input-rule.js +3 -2
- package/dist/es2019/ui/Toolbar/index.js +3 -1
- package/dist/esm/pm-plugins/input-rule.js +3 -2
- package/dist/esm/ui/Toolbar/index.js +3 -1
- package/dist/types/plugin.d.ts +1 -4
- package/dist/types/ui/Toolbar/hooks/formatting-icons.d.ts +1 -1
- package/dist/types-ts4.5/ui/Toolbar/hooks/formatting-icons.d.ts +1 -1
- package/docs/0-intro.tsx +9 -6
- package/package.json +9 -5
- package/report.api.md +19 -20
package/.eslintrc.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
module.exports = {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
rules: {
|
|
3
|
+
'@typescript-eslint/consistent-type-imports': 'warn',
|
|
4
|
+
'no-duplicate-imports': 'off',
|
|
5
|
+
'@typescript-eslint/no-duplicate-imports': 'error',
|
|
6
|
+
},
|
|
7
7
|
};
|
package/CHANGELOG.md
CHANGED
|
@@ -1,604 +1,618 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-text-formatting
|
|
2
2
|
|
|
3
|
+
## 1.7.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 1.7.1
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#105074](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/105074)
|
|
14
|
+
[`546eb6455635`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/546eb6455635) -
|
|
15
|
+
[ux] ED-23044 - The inlineCards with URL should be simplified to url when them are wrapped to
|
|
16
|
+
inline codemark
|
|
17
|
+
|
|
3
18
|
## 1.7.0
|
|
4
19
|
|
|
5
20
|
### Minor Changes
|
|
6
21
|
|
|
7
|
-
-
|
|
8
|
-
|
|
9
|
-
|
|
22
|
+
- [#101406](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/101406)
|
|
23
|
+
[`6daffd65aec4`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/6daffd65aec4) -
|
|
24
|
+
[ED-23298] Extract primary toolbar components to editor plugin to allow for custom ordering
|
|
10
25
|
|
|
11
26
|
### Patch Changes
|
|
12
27
|
|
|
13
|
-
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
-
|
|
28
|
+
- [#102478](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/102478)
|
|
29
|
+
[`3378951608b0`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/3378951608b0) -
|
|
30
|
+
[ED-23332] Update adf-schema package to 36.10.1
|
|
31
|
+
- Updated dependencies
|
|
17
32
|
|
|
18
33
|
## 1.6.1
|
|
19
34
|
|
|
20
35
|
### Patch Changes
|
|
21
36
|
|
|
22
|
-
-
|
|
23
|
-
|
|
24
|
-
|
|
37
|
+
- [#101524](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/101524)
|
|
38
|
+
[`4821570088e6`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/4821570088e6) -
|
|
39
|
+
ED-23362 Bump ADF schema to version 36.8.1 and add support for adf validation and transformation
|
|
25
40
|
|
|
26
41
|
## 1.6.0
|
|
27
42
|
|
|
28
43
|
### Minor Changes
|
|
29
44
|
|
|
30
|
-
-
|
|
31
|
-
|
|
32
|
-
|
|
45
|
+
- [#100553](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/100553)
|
|
46
|
+
[`e0c2a4b9c8ae`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/e0c2a4b9c8ae) -
|
|
47
|
+
[ED-23157] Clear background color (= highlights) when clearing the formatting on a selection
|
|
33
48
|
|
|
34
49
|
### Patch Changes
|
|
35
50
|
|
|
36
|
-
-
|
|
51
|
+
- Updated dependencies
|
|
37
52
|
|
|
38
53
|
## 1.5.0
|
|
39
54
|
|
|
40
55
|
### Minor Changes
|
|
41
56
|
|
|
42
|
-
-
|
|
43
|
-
|
|
44
|
-
|
|
57
|
+
- [#99579](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/99579)
|
|
58
|
+
[`f222af5687e9`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/f222af5687e9) -
|
|
59
|
+
Bump adf-schema to 36.3.0 and adf-schema-json to 1.14.0
|
|
45
60
|
|
|
46
61
|
### Patch Changes
|
|
47
62
|
|
|
48
|
-
-
|
|
63
|
+
- Updated dependencies
|
|
49
64
|
|
|
50
65
|
## 1.4.7
|
|
51
66
|
|
|
52
67
|
### Patch Changes
|
|
53
68
|
|
|
54
|
-
-
|
|
69
|
+
- Updated dependencies
|
|
55
70
|
|
|
56
71
|
## 1.4.6
|
|
57
72
|
|
|
58
73
|
### Patch Changes
|
|
59
74
|
|
|
60
|
-
-
|
|
61
|
-
|
|
62
|
-
|
|
75
|
+
- [#97599](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/97599)
|
|
76
|
+
[`32c3130b08fe`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/32c3130b08fe) -
|
|
77
|
+
[ED-22282] Bump adf-schema to 36.1.0
|
|
63
78
|
|
|
64
79
|
## 1.4.5
|
|
65
80
|
|
|
66
81
|
### Patch Changes
|
|
67
82
|
|
|
68
|
-
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
83
|
+
- [#97698](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/97698)
|
|
84
|
+
[`1c7b378c0d3b`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/1c7b378c0d3b) -
|
|
85
|
+
[HOT-108999] We had an incident where the cursor jumps back a character in table headers for any
|
|
86
|
+
language triggering composition on an empty line.This was fixed in a patch bump of
|
|
87
|
+
prosemirror-view. https://github.com/ProseMirror/prosemirror-view/compare/1.33.4...1.33.5
|
|
73
88
|
|
|
74
89
|
## 1.4.4
|
|
75
90
|
|
|
76
91
|
### Patch Changes
|
|
77
92
|
|
|
78
|
-
-
|
|
93
|
+
- Updated dependencies
|
|
79
94
|
|
|
80
95
|
## 1.4.3
|
|
81
96
|
|
|
82
97
|
### Patch Changes
|
|
83
98
|
|
|
84
|
-
-
|
|
85
|
-
|
|
86
|
-
|
|
99
|
+
- [#96237](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/96237)
|
|
100
|
+
[`0401e7b5a88e`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/0401e7b5a88e) -
|
|
101
|
+
[ED-23102] Bump ADF schema to version 35.12.2
|
|
87
102
|
|
|
88
103
|
## 1.4.2
|
|
89
104
|
|
|
90
105
|
### Patch Changes
|
|
91
106
|
|
|
92
|
-
-
|
|
93
|
-
|
|
94
|
-
|
|
107
|
+
- [#94901](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/94901)
|
|
108
|
+
[`da964fcdc828`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/da964fcdc828) -
|
|
109
|
+
[ED-23097] Bump ADF schema to version 35.12.1
|
|
95
110
|
|
|
96
111
|
## 1.4.1
|
|
97
112
|
|
|
98
113
|
### Patch Changes
|
|
99
114
|
|
|
100
|
-
-
|
|
101
|
-
|
|
102
|
-
|
|
115
|
+
- [#93689](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/93689)
|
|
116
|
+
[`5ba5d2b4a9ac`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/5ba5d2b4a9ac) -
|
|
117
|
+
Updating adf-schema version to 35.10.0
|
|
103
118
|
|
|
104
119
|
## 1.4.0
|
|
105
120
|
|
|
106
121
|
### Minor Changes
|
|
107
122
|
|
|
108
|
-
-
|
|
109
|
-
|
|
110
|
-
|
|
123
|
+
- [#91934](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/91934)
|
|
124
|
+
[`b76a78c6a199`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/b76a78c6a199) -
|
|
125
|
+
bumped editor-prosemirror version to 4.0.0
|
|
111
126
|
|
|
112
127
|
### Patch Changes
|
|
113
128
|
|
|
114
|
-
-
|
|
129
|
+
- Updated dependencies
|
|
115
130
|
|
|
116
131
|
## 1.3.5
|
|
117
132
|
|
|
118
133
|
### Patch Changes
|
|
119
134
|
|
|
120
|
-
-
|
|
121
|
-
|
|
122
|
-
|
|
135
|
+
- [#92426](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/92426)
|
|
136
|
+
[`32c76c7c225c`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/32c76c7c225c) -
|
|
137
|
+
Bump adf-schema to 35.9.2 to support table alignment options
|
|
123
138
|
|
|
124
139
|
## 1.3.4
|
|
125
140
|
|
|
126
141
|
### Patch Changes
|
|
127
142
|
|
|
128
|
-
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
-
|
|
143
|
+
- [#91106](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/91106)
|
|
144
|
+
[`b6ffa30186b9`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/b6ffa30186b9) -
|
|
145
|
+
Bump ADF-schema package to version 35.0.0
|
|
146
|
+
- Updated dependencies
|
|
132
147
|
|
|
133
148
|
## 1.3.3
|
|
134
149
|
|
|
135
150
|
### Patch Changes
|
|
136
151
|
|
|
137
|
-
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
152
|
+
- [#86724](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/86724)
|
|
153
|
+
[`718a9aa2424d`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/718a9aa2424d) -
|
|
154
|
+
[ED-22607] Remove references to maxFrames for multi bodied extensions and bump adf-schema from
|
|
155
|
+
35.7.0 to 35.8.0
|
|
141
156
|
|
|
142
157
|
## 1.3.2
|
|
143
158
|
|
|
144
159
|
### Patch Changes
|
|
145
160
|
|
|
146
|
-
-
|
|
147
|
-
|
|
148
|
-
|
|
161
|
+
- [#81777](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/81777)
|
|
162
|
+
[`c6d7a5378751`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/c6d7a5378751) -
|
|
163
|
+
Bump adf-schema to 35.7.0
|
|
149
164
|
|
|
150
165
|
## 1.3.1
|
|
151
166
|
|
|
152
167
|
### Patch Changes
|
|
153
168
|
|
|
154
|
-
-
|
|
155
|
-
|
|
156
|
-
|
|
169
|
+
- [#83116](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/83116)
|
|
170
|
+
[`8d4e99057fe0`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/8d4e99057fe0) -
|
|
171
|
+
Upgrade Typescript from `4.9.5` to `5.4.2`
|
|
157
172
|
|
|
158
173
|
## 1.3.0
|
|
159
174
|
|
|
160
175
|
### Minor Changes
|
|
161
176
|
|
|
162
|
-
-
|
|
163
|
-
|
|
164
|
-
|
|
177
|
+
- [#82499](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/82499)
|
|
178
|
+
[`cbd66fd38b62`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/cbd66fd38b62) -
|
|
179
|
+
Add option to disable strikethrough on text-formatting via disableStrikethrough.
|
|
165
180
|
|
|
166
181
|
### Patch Changes
|
|
167
182
|
|
|
168
|
-
-
|
|
183
|
+
- Updated dependencies
|
|
169
184
|
|
|
170
185
|
## 1.2.4
|
|
171
186
|
|
|
172
187
|
### Patch Changes
|
|
173
188
|
|
|
174
|
-
-
|
|
175
|
-
|
|
176
|
-
|
|
189
|
+
- [#78492](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/78492)
|
|
190
|
+
[`3b0b93acfd19`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/3b0b93acfd19) -
|
|
191
|
+
[ux] [CAMPTASKS-123] faulty formatting state for inline nodes
|
|
177
192
|
|
|
178
193
|
## 1.2.3
|
|
179
194
|
|
|
180
195
|
### Patch Changes
|
|
181
196
|
|
|
182
|
-
-
|
|
183
|
-
|
|
184
|
-
|
|
197
|
+
- [#80679](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/80679)
|
|
198
|
+
[`104eb9443b7e`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/104eb9443b7e) -
|
|
199
|
+
ED-22553 Updating adf-schema version to 35.6.0
|
|
185
200
|
|
|
186
201
|
## 1.2.2
|
|
187
202
|
|
|
188
203
|
### Patch Changes
|
|
189
204
|
|
|
190
|
-
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
-
|
|
205
|
+
- [#78224](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/78224)
|
|
206
|
+
[`6b4c9dd4ad34`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/6b4c9dd4ad34) -
|
|
207
|
+
ED-22219: adf-schema updated to 35.5.2
|
|
208
|
+
- Updated dependencies
|
|
194
209
|
|
|
195
210
|
## 1.2.1
|
|
196
211
|
|
|
197
212
|
### Patch Changes
|
|
198
213
|
|
|
199
|
-
-
|
|
200
|
-
|
|
201
|
-
|
|
214
|
+
- [#75482](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/75482)
|
|
215
|
+
[`18b5a6fb910a`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/18b5a6fb910a) - #
|
|
216
|
+
MAJOR CHANGE to `@atlaskit/prosemirror-input-rules` package.
|
|
202
217
|
|
|
203
|
-
|
|
218
|
+
## WHY?
|
|
204
219
|
|
|
205
|
-
|
|
220
|
+
Removing editor-common dependencies from prosemirror-input-rules package.
|
|
206
221
|
|
|
207
|
-
|
|
222
|
+
This makes it easier for editor updates because it simplifies our dependency graph.
|
|
208
223
|
|
|
209
|
-
|
|
224
|
+
## WHAT and HOW?
|
|
210
225
|
|
|
211
|
-
|
|
212
|
-
|
|
226
|
+
These are no longer available via `@atlaskit/prosemirror-input-rules` but are available from
|
|
227
|
+
`@atlaskit/editor-common/types`:
|
|
213
228
|
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
229
|
+
- InputRuleWrapper
|
|
230
|
+
- InputRuleHandler
|
|
231
|
+
- OnHandlerApply
|
|
232
|
+
- createRule
|
|
218
233
|
|
|
219
|
-
|
|
220
|
-
|
|
234
|
+
These have changed from a `SafePlugin` to a `SafePluginSpec`. In order to update your code you
|
|
235
|
+
need to instantiate a `SafePlugin` (ie. `new SafePlugin(createPlugin( ... ))`).
|
|
221
236
|
|
|
222
|
-
|
|
237
|
+
`SafePlugin` exists in `@atlaskit/editor-common/safe-plugin`.
|
|
223
238
|
|
|
224
|
-
|
|
225
|
-
|
|
239
|
+
- createPlugin
|
|
240
|
+
- createInputRulePlugin
|
|
226
241
|
|
|
227
|
-
-
|
|
242
|
+
- Updated dependencies
|
|
228
243
|
|
|
229
244
|
## 1.2.0
|
|
230
245
|
|
|
231
246
|
### Minor Changes
|
|
232
247
|
|
|
233
|
-
-
|
|
234
|
-
|
|
235
|
-
|
|
248
|
+
- [#75020](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/75020)
|
|
249
|
+
[`56d9ebc6e467`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/56d9ebc6e467) -
|
|
250
|
+
[ux] ECA11Y-206: Separators fix
|
|
236
251
|
|
|
237
252
|
## 1.1.0
|
|
238
253
|
|
|
239
254
|
### Minor Changes
|
|
240
255
|
|
|
241
|
-
-
|
|
242
|
-
|
|
243
|
-
|
|
256
|
+
- [#73123](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/73123)
|
|
257
|
+
[`9fd7b5a5e323`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/9fd7b5a5e323) -
|
|
258
|
+
ECA11Y-206: added role group and aria labels
|
|
244
259
|
|
|
245
260
|
### Patch Changes
|
|
246
261
|
|
|
247
|
-
-
|
|
262
|
+
- Updated dependencies
|
|
248
263
|
|
|
249
264
|
## 1.0.1
|
|
250
265
|
|
|
251
266
|
### Patch Changes
|
|
252
267
|
|
|
253
|
-
-
|
|
268
|
+
- Updated dependencies
|
|
254
269
|
|
|
255
270
|
## 1.0.0
|
|
256
271
|
|
|
257
272
|
### Major Changes
|
|
258
273
|
|
|
259
|
-
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
274
|
+
- [#72386](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/72386)
|
|
275
|
+
[`0c52b0be40c1`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/0c52b0be40c1) -
|
|
276
|
+
This changeset exists to bump all editor plugins that currently don't have a major version. This
|
|
277
|
+
is to address an issue with Jira plugin consumption.
|
|
263
278
|
|
|
264
279
|
### Patch Changes
|
|
265
280
|
|
|
266
|
-
-
|
|
281
|
+
- Updated dependencies
|
|
267
282
|
|
|
268
283
|
## 0.4.26
|
|
269
284
|
|
|
270
285
|
### Patch Changes
|
|
271
286
|
|
|
272
|
-
-
|
|
273
|
-
|
|
274
|
-
|
|
287
|
+
- [#68572](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/68572)
|
|
288
|
+
[`15d407fe5143`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/15d407fe5143) -
|
|
289
|
+
Upgrading @atlaskit/editor-prosemirror dependency
|
|
275
290
|
|
|
276
291
|
## 0.4.25
|
|
277
292
|
|
|
278
293
|
### Patch Changes
|
|
279
294
|
|
|
280
|
-
-
|
|
281
|
-
|
|
282
|
-
|
|
295
|
+
- [#70152](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/70152)
|
|
296
|
+
[`53ed3673df28`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/53ed3673df28) -
|
|
297
|
+
Updating adf-schema version to 35.5.1
|
|
283
298
|
|
|
284
299
|
## 0.4.24
|
|
285
300
|
|
|
286
301
|
### Patch Changes
|
|
287
302
|
|
|
288
|
-
-
|
|
303
|
+
- Updated dependencies
|
|
289
304
|
|
|
290
305
|
## 0.4.23
|
|
291
306
|
|
|
292
307
|
### Patch Changes
|
|
293
308
|
|
|
294
|
-
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
-
|
|
309
|
+
- [#67557](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/67557)
|
|
310
|
+
[`124d0c6d5286`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/124d0c6d5286) -
|
|
311
|
+
Migrating block-type, text-color, and text-formatting to use useSharedPluginState rather than
|
|
312
|
+
WithPluginState. Removing unused option on default preset. Adding formattingIsPresent prop to
|
|
313
|
+
TextFormattingState.
|
|
314
|
+
- Updated dependencies
|
|
300
315
|
|
|
301
316
|
## 0.4.22
|
|
302
317
|
|
|
303
318
|
### Patch Changes
|
|
304
319
|
|
|
305
|
-
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
-
|
|
320
|
+
- [#65031](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/65031)
|
|
321
|
+
[`a00094111b5a`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/a00094111b5a) -
|
|
322
|
+
ED-21609 Update adf-schema to 35.3.0
|
|
323
|
+
- Updated dependencies
|
|
309
324
|
|
|
310
325
|
## 0.4.21
|
|
311
326
|
|
|
312
327
|
### Patch Changes
|
|
313
328
|
|
|
314
|
-
-
|
|
315
|
-
|
|
316
|
-
|
|
329
|
+
- [#62165](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/62165)
|
|
330
|
+
[`b44ac0968d79`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/b44ac0968d79) -
|
|
331
|
+
[ED-21562] Bump @atlaskit/adf-schema to 35.2.0 for border mark update
|
|
317
332
|
|
|
318
333
|
## 0.4.20
|
|
319
334
|
|
|
320
335
|
### Patch Changes
|
|
321
336
|
|
|
322
|
-
-
|
|
323
|
-
|
|
324
|
-
|
|
337
|
+
- [#60808](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/60808)
|
|
338
|
+
[`f509a21be124`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/f509a21be124) -
|
|
339
|
+
ED-21506: @atlaskit/adf-schema upgraded to 35.1.1 to support renderer for MBE
|
|
325
340
|
|
|
326
341
|
## 0.4.19
|
|
327
342
|
|
|
328
343
|
### Patch Changes
|
|
329
344
|
|
|
330
|
-
-
|
|
331
|
-
|
|
332
|
-
|
|
345
|
+
- [#58246](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/58246)
|
|
346
|
+
[`a381b2599716`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/a381b2599716) -
|
|
347
|
+
ED-21371 Update adf-schema to 35.1.0
|
|
333
348
|
|
|
334
349
|
## 0.4.18
|
|
335
350
|
|
|
336
351
|
### Patch Changes
|
|
337
352
|
|
|
338
|
-
-
|
|
353
|
+
- Updated dependencies
|
|
339
354
|
|
|
340
355
|
## 0.4.17
|
|
341
356
|
|
|
342
357
|
### Patch Changes
|
|
343
358
|
|
|
344
|
-
-
|
|
345
|
-
|
|
346
|
-
|
|
359
|
+
- [#59147](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/59147)
|
|
360
|
+
[`f12e489f23b0`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/f12e489f23b0) -
|
|
361
|
+
Re-build and deploy packages to NPM to resolve React/Compiled not found error (HOT-106483).
|
|
347
362
|
|
|
348
363
|
## 0.4.16
|
|
349
364
|
|
|
350
365
|
### Patch Changes
|
|
351
366
|
|
|
352
|
-
-
|
|
353
|
-
|
|
354
|
-
|
|
367
|
+
- [#58763](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/58763)
|
|
368
|
+
[`0fdbd64522bf`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/0fdbd64522bf) -
|
|
369
|
+
update ADF schema
|
|
355
370
|
|
|
356
371
|
## 0.4.15
|
|
357
372
|
|
|
358
373
|
### Patch Changes
|
|
359
374
|
|
|
360
|
-
-
|
|
361
|
-
|
|
362
|
-
|
|
375
|
+
- [#56790](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/56790)
|
|
376
|
+
[`ff577a7969d4`](https://bitbucket.org/atlassian/atlassian-frontend/commits/ff577a7969d4) -
|
|
377
|
+
ED-21266: Updated @atlaskit/adf-schema to 34.0.1
|
|
363
378
|
|
|
364
379
|
## 0.4.14
|
|
365
380
|
|
|
366
381
|
### Patch Changes
|
|
367
382
|
|
|
368
|
-
-
|
|
369
|
-
|
|
370
|
-
|
|
383
|
+
- [#43417](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/43417)
|
|
384
|
+
[`3f3c17f0273`](https://bitbucket.org/atlassian/atlassian-frontend/commits/3f3c17f0273) - ED-20971
|
|
385
|
+
Upgrade adf-schema package to ^34.0.0
|
|
371
386
|
|
|
372
387
|
## 0.4.13
|
|
373
388
|
|
|
374
389
|
### Patch Changes
|
|
375
390
|
|
|
376
|
-
-
|
|
391
|
+
- Updated dependencies
|
|
377
392
|
|
|
378
393
|
## 0.4.12
|
|
379
394
|
|
|
380
395
|
### Patch Changes
|
|
381
396
|
|
|
382
|
-
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
-
|
|
397
|
+
- [#43379](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/43379)
|
|
398
|
+
[`482c025520d`](https://bitbucket.org/atlassian/atlassian-frontend/commits/482c025520d) - ED-20763
|
|
399
|
+
Upgrade ADF schema version to 33.2.3 for MBE nodes.
|
|
400
|
+
- Updated dependencies
|
|
386
401
|
|
|
387
402
|
## 0.4.11
|
|
388
403
|
|
|
389
404
|
### Patch Changes
|
|
390
405
|
|
|
391
|
-
-
|
|
392
|
-
|
|
393
|
-
|
|
406
|
+
- [#42770](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/42770)
|
|
407
|
+
[`c7a6a824958`](https://bitbucket.org/atlassian/atlassian-frontend/commits/c7a6a824958) - Extract
|
|
408
|
+
code-block plugin from editor-core as `@atlaskit/editor-plugin-code-block`.
|
|
394
409
|
|
|
395
410
|
## 0.4.10
|
|
396
411
|
|
|
397
412
|
### Patch Changes
|
|
398
413
|
|
|
399
|
-
-
|
|
400
|
-
|
|
401
|
-
|
|
414
|
+
- [#42570](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/42570)
|
|
415
|
+
[`d7ff4d590d7`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d7ff4d590d7) -
|
|
416
|
+
ED-20023: Adding check for undefined item in dropdown menu
|
|
402
417
|
|
|
403
418
|
## 0.4.9
|
|
404
419
|
|
|
405
420
|
### Patch Changes
|
|
406
421
|
|
|
407
|
-
-
|
|
422
|
+
- Updated dependencies
|
|
408
423
|
|
|
409
424
|
## 0.4.8
|
|
410
425
|
|
|
411
426
|
### Patch Changes
|
|
412
427
|
|
|
413
|
-
-
|
|
414
|
-
|
|
415
|
-
|
|
428
|
+
- [#41634](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/41634)
|
|
429
|
+
[`e7cd20932b9`](https://bitbucket.org/atlassian/atlassian-frontend/commits/e7cd20932b9) - on
|
|
430
|
+
windows, toggles mark when the capslock is on
|
|
416
431
|
|
|
417
432
|
## 0.4.7
|
|
418
433
|
|
|
419
434
|
### Patch Changes
|
|
420
435
|
|
|
421
|
-
-
|
|
422
|
-
|
|
423
|
-
|
|
436
|
+
- [#39749](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/39749)
|
|
437
|
+
[`e6b69f455c3`](https://bitbucket.org/atlassian/atlassian-frontend/commits/e6b69f455c3) - Connect
|
|
438
|
+
yarn changeset to packages, upgrade adf-schema
|
|
424
439
|
|
|
425
440
|
## 0.4.6
|
|
426
441
|
|
|
427
442
|
### Patch Changes
|
|
428
443
|
|
|
429
|
-
-
|
|
444
|
+
- Updated dependencies
|
|
430
445
|
|
|
431
446
|
## 0.4.5
|
|
432
447
|
|
|
433
448
|
### Patch Changes
|
|
434
449
|
|
|
435
|
-
-
|
|
436
|
-
|
|
437
|
-
|
|
450
|
+
- [#39984](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/39984)
|
|
451
|
+
[`37c62369dae`](https://bitbucket.org/atlassian/atlassian-frontend/commits/37c62369dae) - NO-ISSUE
|
|
452
|
+
Import doc builder types from editor-common
|
|
438
453
|
|
|
439
454
|
## 0.4.4
|
|
440
455
|
|
|
441
456
|
### Patch Changes
|
|
442
457
|
|
|
443
|
-
-
|
|
458
|
+
- Updated dependencies
|
|
444
459
|
|
|
445
460
|
## 0.4.3
|
|
446
461
|
|
|
447
462
|
### Patch Changes
|
|
448
463
|
|
|
449
|
-
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
-
|
|
453
|
-
|
|
464
|
+
- [#39481](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/39481)
|
|
465
|
+
[`aeb5c9a01e8`](https://bitbucket.org/atlassian/atlassian-frontend/commits/aeb5c9a01e8) - Delete
|
|
466
|
+
adf-schema from AFE and rely on npm package for adf-schema
|
|
467
|
+
- [`4b4dcfe0bba`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4b4dcfe0bba) - Delete
|
|
468
|
+
adf-schema, use published version
|
|
454
469
|
|
|
455
470
|
## 0.4.2
|
|
456
471
|
|
|
457
472
|
### Patch Changes
|
|
458
473
|
|
|
459
|
-
-
|
|
460
|
-
|
|
461
|
-
|
|
474
|
+
- [#39628](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/39628)
|
|
475
|
+
[`1b66c23221e`](https://bitbucket.org/atlassian/atlassian-frontend/commits/1b66c23221e) - Fix
|
|
476
|
+
missing analytics parameter in media plugin.
|
|
462
477
|
|
|
463
478
|
## 0.4.1
|
|
464
479
|
|
|
465
480
|
### Patch Changes
|
|
466
481
|
|
|
467
|
-
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
482
|
+
- [#39304](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/39304)
|
|
483
|
+
[`6acf9830b36`](https://bitbucket.org/atlassian/atlassian-frontend/commits/6acf9830b36) - Update
|
|
484
|
+
feature flags plugin (@atlaskit/editor-plugin-feature-flags) to use a named export rather than
|
|
485
|
+
default export to match other plugins.
|
|
471
486
|
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
487
|
+
```ts
|
|
488
|
+
// Before
|
|
489
|
+
import featureFlagsPlugin from '@atlaskit/editor-plugin-feature-flags';
|
|
475
490
|
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
491
|
+
// After
|
|
492
|
+
import { featureFlagsPlugin } from '@atlaskit/editor-plugin-feature-flags';
|
|
493
|
+
```
|
|
479
494
|
|
|
480
495
|
## 0.4.0
|
|
481
496
|
|
|
482
497
|
### Minor Changes
|
|
483
498
|
|
|
484
|
-
-
|
|
485
|
-
|
|
486
|
-
|
|
499
|
+
- [#39325](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/39325)
|
|
500
|
+
[`ad3c5c21079`](https://bitbucket.org/atlassian/atlassian-frontend/commits/ad3c5c21079) - Updating
|
|
501
|
+
all plugins with minor version to correct issue with semver.
|
|
487
502
|
|
|
488
503
|
### Patch Changes
|
|
489
504
|
|
|
490
|
-
-
|
|
505
|
+
- Updated dependencies
|
|
491
506
|
|
|
492
507
|
## 0.3.2
|
|
493
508
|
|
|
494
509
|
### Patch Changes
|
|
495
510
|
|
|
496
|
-
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
`NextEditorPlugin`.
|
|
511
|
+
- [#39010](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/39010)
|
|
512
|
+
[`8467bdcdf4f`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8467bdcdf4f) - Removing
|
|
513
|
+
`dependencies` prop from PluginInjectionAPI and changing signature of `NextEditorPlugin`.
|
|
500
514
|
|
|
501
|
-
|
|
515
|
+
Previously a `NextEditorPlugin` would be consumed as so:
|
|
502
516
|
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
517
|
+
```ts
|
|
518
|
+
const plugin: NextEditorPlugin< ... > = (config, api) => {
|
|
519
|
+
// Can use api like so:
|
|
520
|
+
api.dependencies.core.actions.execute( ... )
|
|
521
|
+
return { ... }
|
|
522
|
+
}
|
|
523
|
+
```
|
|
510
524
|
|
|
511
|
-
|
|
512
|
-
|
|
525
|
+
Now these have become named parameters like so and the `pluginInjectionAPI` is used without the
|
|
526
|
+
`dependencies` prop:
|
|
513
527
|
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
528
|
+
```ts
|
|
529
|
+
const plugin: NextEditorPlugin< ... > = ({ config, api }) => {
|
|
530
|
+
// Can use api like so:
|
|
531
|
+
api.core.actions.execute( ... )
|
|
532
|
+
return { ... }
|
|
533
|
+
}
|
|
534
|
+
```
|
|
521
535
|
|
|
522
|
-
-
|
|
536
|
+
- Updated dependencies
|
|
523
537
|
|
|
524
538
|
## 0.3.1
|
|
525
539
|
|
|
526
540
|
### Patch Changes
|
|
527
541
|
|
|
528
|
-
-
|
|
529
|
-
|
|
530
|
-
|
|
542
|
+
- [#39177](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/39177)
|
|
543
|
+
[`24e27147cbd`](https://bitbucket.org/atlassian/atlassian-frontend/commits/24e27147cbd) - Added
|
|
544
|
+
atlaskit docs to all existing plugins.
|
|
531
545
|
|
|
532
546
|
## 0.3.0
|
|
533
547
|
|
|
534
548
|
### Minor Changes
|
|
535
549
|
|
|
536
|
-
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
550
|
+
- [#39023](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/39023)
|
|
551
|
+
[`4795a87a349`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4795a87a349) -
|
|
552
|
+
Migrating some actions of `editor-plugin-list` to commands. Adding sharedState for
|
|
553
|
+
`editor-plugin-text-formatting`.
|
|
540
554
|
|
|
541
555
|
## 0.2.5
|
|
542
556
|
|
|
543
557
|
### Patch Changes
|
|
544
558
|
|
|
545
|
-
-
|
|
546
|
-
|
|
547
|
-
|
|
559
|
+
- [#38976](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/38976)
|
|
560
|
+
[`33cb07de05f`](https://bitbucket.org/atlassian/atlassian-frontend/commits/33cb07de05f) - change
|
|
561
|
+
adf-schema to fixed versioning
|
|
548
562
|
|
|
549
563
|
## 0.2.4
|
|
550
564
|
|
|
551
565
|
### Patch Changes
|
|
552
566
|
|
|
553
|
-
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
-
|
|
567
|
+
- [#38808](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/38808)
|
|
568
|
+
[`967f4819f58`](https://bitbucket.org/atlassian/atlassian-frontend/commits/967f4819f58) -
|
|
569
|
+
Introduce core plugin that is always injected into the pluginInjectionApi. This has a new action
|
|
570
|
+
`execute` that replaces the existing `executeCommand` that was called from the
|
|
571
|
+
`pluginInjectionApi`.
|
|
572
|
+
- Updated dependencies
|
|
559
573
|
|
|
560
574
|
## 0.2.3
|
|
561
575
|
|
|
562
576
|
### Patch Changes
|
|
563
577
|
|
|
564
|
-
-
|
|
565
|
-
|
|
566
|
-
|
|
578
|
+
- [#38577](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/38577)
|
|
579
|
+
[`f12aff135b6`](https://bitbucket.org/atlassian/atlassian-frontend/commits/f12aff135b6) - Extract
|
|
580
|
+
Composition Plugin
|
|
567
581
|
|
|
568
582
|
## 0.2.2
|
|
569
583
|
|
|
570
584
|
### Patch Changes
|
|
571
585
|
|
|
572
|
-
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
-
|
|
586
|
+
- [#38495](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/38495)
|
|
587
|
+
[`24fc3925d73`](https://bitbucket.org/atlassian/atlassian-frontend/commits/24fc3925d73) - Add a
|
|
588
|
+
new hook called `usePreset` accesed via `@atlaskit/editor-core/use-preset`. This hook can be used
|
|
589
|
+
to safely access state and commands from outside the editor using `EditorContext`.
|
|
590
|
+
- Updated dependencies
|
|
577
591
|
|
|
578
592
|
## 0.2.1
|
|
579
593
|
|
|
580
594
|
### Patch Changes
|
|
581
595
|
|
|
582
|
-
-
|
|
583
|
-
|
|
584
|
-
|
|
596
|
+
- [#38679](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/38679)
|
|
597
|
+
[`5365e42ef97`](https://bitbucket.org/atlassian/atlassian-frontend/commits/5365e42ef97) - cleaned
|
|
598
|
+
up more of the \* as keymaps imports to enable better tree-shaking
|
|
585
599
|
|
|
586
600
|
## 0.2.0
|
|
587
601
|
|
|
588
602
|
### Minor Changes
|
|
589
603
|
|
|
590
|
-
-
|
|
591
|
-
|
|
592
|
-
|
|
604
|
+
- [#38497](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/38497)
|
|
605
|
+
[`43c51e0a282`](https://bitbucket.org/atlassian/atlassian-frontend/commits/43c51e0a282) -
|
|
606
|
+
[ED-19431] Migrate all text-formatting plugin actions over to plugin commands
|
|
593
607
|
|
|
594
608
|
### Patch Changes
|
|
595
609
|
|
|
596
|
-
-
|
|
610
|
+
- Updated dependencies
|
|
597
611
|
|
|
598
612
|
## 0.1.1
|
|
599
613
|
|
|
600
614
|
### Patch Changes
|
|
601
615
|
|
|
602
|
-
-
|
|
603
|
-
|
|
604
|
-
|
|
616
|
+
- [#38544](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/38544)
|
|
617
|
+
[`f3728ec49ab`](https://bitbucket.org/atlassian/atlassian-frontend/commits/f3728ec49ab) - NO-ISSUE
|
|
618
|
+
Switched analytics plugin to prod dependency to avoid type issues in CI
|
package/LICENSE.md
CHANGED
|
@@ -1,13 +1,11 @@
|
|
|
1
1
|
Copyright 2023 Atlassian Pty Ltd
|
|
2
2
|
|
|
3
|
-
Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
|
|
5
|
-
You may obtain a copy of the License at
|
|
3
|
+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in
|
|
4
|
+
compliance with the License. You may obtain a copy of the License at
|
|
6
5
|
|
|
7
6
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
8
7
|
|
|
9
|
-
Unless required by applicable law or agreed to in writing, software
|
|
10
|
-
distributed
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
limitations under the License.
|
|
8
|
+
Unless required by applicable law or agreed to in writing, software distributed under the License is
|
|
9
|
+
distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
10
|
+
implied. See the License for the specific language governing permissions and limitations under the
|
|
11
|
+
License.
|
|
@@ -20,6 +20,7 @@ var _analytics = require("@atlaskit/editor-common/analytics");
|
|
|
20
20
|
var _mark = require("@atlaskit/editor-common/mark");
|
|
21
21
|
var _safePlugin = require("@atlaskit/editor-common/safe-plugin");
|
|
22
22
|
var _utils = require("@atlaskit/editor-common/utils");
|
|
23
|
+
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
23
24
|
var _prosemirrorInputRules = require("@atlaskit/prosemirror-input-rules");
|
|
24
25
|
var _ValidCombinations;
|
|
25
26
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
@@ -95,7 +96,7 @@ function addMark(markType, schema, char) {
|
|
|
95
96
|
return null;
|
|
96
97
|
}
|
|
97
98
|
if (markType.name === 'code') {
|
|
98
|
-
(0, _mark.transformSmartCharsMentionsAndEmojis)(tr.mapping.map(start), tr.mapping.map(end), tr);
|
|
99
|
+
(0, _platformFeatureFlags.getBooleanFF)('platform.editor.simplify-inline-cards-in-code-blocks_jw6t1') ? (0, _mark.transformNonTextNodesToText)(tr.mapping.map(start), tr.mapping.map(end), tr) : (0, _mark.transformSmartCharsMentionsAndEmojis)(tr.mapping.map(start), tr.mapping.map(end), tr);
|
|
99
100
|
}
|
|
100
101
|
var mappedStart = tr.mapping.map(start);
|
|
101
102
|
var mappedEnd = tr.mapping.map(end);
|
|
@@ -127,7 +127,9 @@ var ToolbarFormatting = function ToolbarFormatting(_ref) {
|
|
|
127
127
|
(0, _react2.jsx)("span", {
|
|
128
128
|
css: _styles.buttonGroupStyle
|
|
129
129
|
}, (0, _react2.jsx)("div", {
|
|
130
|
-
role: "group"
|
|
130
|
+
role: "group"
|
|
131
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
132
|
+
,
|
|
131
133
|
className: 'js-text-format-wrap',
|
|
132
134
|
"aria-label": labelTextFormat
|
|
133
135
|
}, message && (0, _react2.jsx)(_ui.Announcer, {
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
2
|
-
import { transformSmartCharsMentionsAndEmojis } from '@atlaskit/editor-common/mark';
|
|
2
|
+
import { transformNonTextNodesToText, transformSmartCharsMentionsAndEmojis } from '@atlaskit/editor-common/mark';
|
|
3
3
|
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
4
4
|
import { createRule, inputRuleWithAnalytics } from '@atlaskit/editor-common/utils';
|
|
5
|
+
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
5
6
|
import { createPlugin, leafNodeReplacementCharacter } from '@atlaskit/prosemirror-input-rules';
|
|
6
7
|
var ValidAutoformatChars = /*#__PURE__*/function (ValidAutoformatChars) {
|
|
7
8
|
ValidAutoformatChars["STRONG"] = "__";
|
|
@@ -83,7 +84,7 @@ function addMark(markType, schema, char) {
|
|
|
83
84
|
return null;
|
|
84
85
|
}
|
|
85
86
|
if (markType.name === 'code') {
|
|
86
|
-
transformSmartCharsMentionsAndEmojis(tr.mapping.map(start), tr.mapping.map(end), tr);
|
|
87
|
+
getBooleanFF('platform.editor.simplify-inline-cards-in-code-blocks_jw6t1') ? transformNonTextNodesToText(tr.mapping.map(start), tr.mapping.map(end), tr) : transformSmartCharsMentionsAndEmojis(tr.mapping.map(start), tr.mapping.map(end), tr);
|
|
87
88
|
}
|
|
88
89
|
const mappedStart = tr.mapping.map(start);
|
|
89
90
|
const mappedEnd = tr.mapping.map(end);
|
|
@@ -114,7 +114,9 @@ const ToolbarFormatting = ({
|
|
|
114
114
|
jsx("span", {
|
|
115
115
|
css: buttonGroupStyle
|
|
116
116
|
}, jsx("div", {
|
|
117
|
-
role: "group"
|
|
117
|
+
role: "group"
|
|
118
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
119
|
+
,
|
|
118
120
|
className: 'js-text-format-wrap',
|
|
119
121
|
"aria-label": labelTextFormat
|
|
120
122
|
}, message && jsx(Announcer, {
|
|
@@ -11,9 +11,10 @@ var _ValidCombinations;
|
|
|
11
11
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
12
12
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
13
13
|
import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
14
|
-
import { transformSmartCharsMentionsAndEmojis } from '@atlaskit/editor-common/mark';
|
|
14
|
+
import { transformNonTextNodesToText, transformSmartCharsMentionsAndEmojis } from '@atlaskit/editor-common/mark';
|
|
15
15
|
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
16
16
|
import { createRule, inputRuleWithAnalytics } from '@atlaskit/editor-common/utils';
|
|
17
|
+
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
17
18
|
import { createPlugin, leafNodeReplacementCharacter } from '@atlaskit/prosemirror-input-rules';
|
|
18
19
|
var ValidAutoformatChars = /*#__PURE__*/function (ValidAutoformatChars) {
|
|
19
20
|
ValidAutoformatChars["STRONG"] = "__";
|
|
@@ -86,7 +87,7 @@ function addMark(markType, schema, char) {
|
|
|
86
87
|
return null;
|
|
87
88
|
}
|
|
88
89
|
if (markType.name === 'code') {
|
|
89
|
-
transformSmartCharsMentionsAndEmojis(tr.mapping.map(start), tr.mapping.map(end), tr);
|
|
90
|
+
getBooleanFF('platform.editor.simplify-inline-cards-in-code-blocks_jw6t1') ? transformNonTextNodesToText(tr.mapping.map(start), tr.mapping.map(end), tr) : transformSmartCharsMentionsAndEmojis(tr.mapping.map(start), tr.mapping.map(end), tr);
|
|
90
91
|
}
|
|
91
92
|
var mappedStart = tr.mapping.map(start);
|
|
92
93
|
var mappedEnd = tr.mapping.map(end);
|
|
@@ -119,7 +119,9 @@ var ToolbarFormatting = function ToolbarFormatting(_ref) {
|
|
|
119
119
|
jsx("span", {
|
|
120
120
|
css: buttonGroupStyle
|
|
121
121
|
}, jsx("div", {
|
|
122
|
-
role: "group"
|
|
122
|
+
role: "group"
|
|
123
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
124
|
+
,
|
|
123
125
|
className: 'js-text-format-wrap',
|
|
124
126
|
"aria-label": labelTextFormat
|
|
125
127
|
}, message && jsx(Announcer, {
|
package/dist/types/plugin.d.ts
CHANGED
|
@@ -4,10 +4,7 @@ import type { PrimaryToolbarPlugin } from '@atlaskit/editor-plugin-primary-toolb
|
|
|
4
4
|
import type { ToggleMarkEditorCommand } from './commands';
|
|
5
5
|
export type TextFormattingPlugin = NextEditorPlugin<'textFormatting', {
|
|
6
6
|
pluginConfiguration: TextFormattingOptions | undefined;
|
|
7
|
-
dependencies: [
|
|
8
|
-
OptionalPlugin<AnalyticsPlugin>,
|
|
9
|
-
OptionalPlugin<PrimaryToolbarPlugin>
|
|
10
|
-
];
|
|
7
|
+
dependencies: [OptionalPlugin<AnalyticsPlugin>, OptionalPlugin<PrimaryToolbarPlugin>];
|
|
11
8
|
commands: {
|
|
12
9
|
toggleSuperscript: ToggleMarkEditorCommand;
|
|
13
10
|
toggleSubscript: ToggleMarkEditorCommand;
|
|
@@ -13,5 +13,5 @@ type Props = {
|
|
|
13
13
|
textFormattingState: TextFormattingState | undefined;
|
|
14
14
|
iconTypeList: IconTypes[];
|
|
15
15
|
};
|
|
16
|
-
export declare const useHasFormattingActived: ({ iconTypeList, textFormattingState
|
|
16
|
+
export declare const useHasFormattingActived: ({ iconTypeList, textFormattingState }: Props) => boolean;
|
|
17
17
|
export {};
|
|
@@ -13,5 +13,5 @@ type Props = {
|
|
|
13
13
|
textFormattingState: TextFormattingState | undefined;
|
|
14
14
|
iconTypeList: IconTypes[];
|
|
15
15
|
};
|
|
16
|
-
export declare const useHasFormattingActived: ({ iconTypeList, textFormattingState
|
|
16
|
+
export declare const useHasFormattingActived: ({ iconTypeList, textFormattingState }: Props) => boolean;
|
|
17
17
|
export {};
|
package/docs/0-intro.tsx
CHANGED
|
@@ -8,15 +8,18 @@ import { token } from '@atlaskit/tokens';
|
|
|
8
8
|
export default md`
|
|
9
9
|
|
|
10
10
|
${createEditorUseOnlyNotice('Editor Plugin Text Formatting', [
|
|
11
|
-
|
|
11
|
+
{ name: 'Editor Core', link: '/packages/editor/editor-core' },
|
|
12
12
|
])}
|
|
13
13
|
|
|
14
14
|
|
|
15
|
-
${
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
15
|
+
${
|
|
16
|
+
(
|
|
17
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
18
|
+
<div style={{ marginTop: token('space.100', '8px') }}>
|
|
19
|
+
<AtlassianInternalWarning />
|
|
20
|
+
</div>
|
|
21
|
+
)
|
|
22
|
+
}
|
|
20
23
|
|
|
21
24
|
This package includes the text formatting plugin used by \`@atlaskit/editor-core\`.
|
|
22
25
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-text-formatting",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.2",
|
|
4
4
|
"description": "Text-formatting plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -33,13 +33,14 @@
|
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"@atlaskit/adf-schema": "^36.10.7",
|
|
36
|
-
"@atlaskit/editor-common": "^
|
|
36
|
+
"@atlaskit/editor-common": "^82.0.0",
|
|
37
37
|
"@atlaskit/editor-plugin-analytics": "^1.2.0",
|
|
38
38
|
"@atlaskit/editor-plugin-primary-toolbar": "^1.1.0",
|
|
39
39
|
"@atlaskit/editor-prosemirror": "4.0.1",
|
|
40
|
-
"@atlaskit/editor-shared-styles": "^2.
|
|
40
|
+
"@atlaskit/editor-shared-styles": "^2.12.0",
|
|
41
41
|
"@atlaskit/editor-tables": "^2.7.0",
|
|
42
42
|
"@atlaskit/icon": "^22.3.0",
|
|
43
|
+
"@atlaskit/platform-feature-flags": "^0.2.5",
|
|
43
44
|
"@atlaskit/prosemirror-input-rules": "^3.1.0",
|
|
44
45
|
"@babel/runtime": "^7.0.0",
|
|
45
46
|
"@emotion/react": "^11.7.1",
|
|
@@ -52,7 +53,6 @@
|
|
|
52
53
|
"@atlaskit/editor-plugin-composition": "^1.1.0",
|
|
53
54
|
"@atlaskit/editor-plugin-decorations": "^1.1.0",
|
|
54
55
|
"@atlaskit/editor-plugin-feature-flags": "^1.1.0",
|
|
55
|
-
"@atlassian/atlassian-frontend-prettier-config-1.0.0": "npm:@atlassian/atlassian-frontend-prettier-config@1.0.0",
|
|
56
56
|
"@testing-library/react": "^12.1.5",
|
|
57
57
|
"typescript": "~5.4.2"
|
|
58
58
|
},
|
|
@@ -89,5 +89,9 @@
|
|
|
89
89
|
]
|
|
90
90
|
}
|
|
91
91
|
},
|
|
92
|
-
"
|
|
92
|
+
"platform-feature-flags": {
|
|
93
|
+
"platform.editor.simplify-inline-cards-in-code-blocks_jw6t1": {
|
|
94
|
+
"type": "boolean"
|
|
95
|
+
}
|
|
96
|
+
}
|
|
93
97
|
}
|
package/report.api.md
CHANGED
|
@@ -2,7 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
## API Report File for "@atlaskit/editor-plugin-text-formatting"
|
|
4
4
|
|
|
5
|
-
> Do not edit this file. This report is auto-generated using
|
|
5
|
+
> Do not edit this file. This report is auto-generated using
|
|
6
|
+
> [API Extractor](https://api-extractor.com/).
|
|
6
7
|
> [Learn more about API reports](https://hello.atlassian.net/wiki/spaces/UR/pages/1825484529/Package+API+Reports)
|
|
7
8
|
|
|
8
9
|
### Table of contents
|
|
@@ -25,30 +26,28 @@ import type { TextFormattingState } from '@atlaskit/editor-common/types';
|
|
|
25
26
|
|
|
26
27
|
// @public (undocumented)
|
|
27
28
|
export type TextFormattingPlugin = NextEditorPlugin<
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
29
|
+
'textFormatting',
|
|
30
|
+
{
|
|
31
|
+
pluginConfiguration: TextFormattingOptions | undefined;
|
|
32
|
+
dependencies: [OptionalPlugin<typeof analyticsPlugin>];
|
|
33
|
+
commands: {
|
|
34
|
+
toggleSuperscript: ToggleMarkEditorCommand;
|
|
35
|
+
toggleSubscript: ToggleMarkEditorCommand;
|
|
36
|
+
toggleStrike: ToggleMarkEditorCommand;
|
|
37
|
+
toggleCode: ToggleMarkEditorCommand;
|
|
38
|
+
toggleUnderline: ToggleMarkEditorCommand;
|
|
39
|
+
toggleEm: ToggleMarkEditorCommand;
|
|
40
|
+
toggleStrong: ToggleMarkEditorCommand;
|
|
41
|
+
};
|
|
42
|
+
sharedState: TextFormattingState | undefined;
|
|
43
|
+
}
|
|
43
44
|
>;
|
|
44
45
|
|
|
45
46
|
// @public
|
|
46
47
|
export const textFormattingPlugin: TextFormattingPlugin;
|
|
47
48
|
|
|
48
49
|
// @public (undocumented)
|
|
49
|
-
export type ToggleMarkEditorCommand = (
|
|
50
|
-
inputMethod: InputMethodBasic,
|
|
51
|
-
) => EditorCommand;
|
|
50
|
+
export type ToggleMarkEditorCommand = (inputMethod: InputMethodBasic) => EditorCommand;
|
|
52
51
|
|
|
53
52
|
// (No @packageDocumentation comment for this package)
|
|
54
53
|
```
|
|
@@ -61,7 +60,7 @@ export type ToggleMarkEditorCommand = (
|
|
|
61
60
|
|
|
62
61
|
```json
|
|
63
62
|
{
|
|
64
|
-
|
|
63
|
+
"react": "^16.8.0"
|
|
65
64
|
}
|
|
66
65
|
```
|
|
67
66
|
|