@synerise/ds-code-area 1.1.10 → 1.1.11
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 +16 -310
- package/README.md +18 -22
- package/dist/CodeArea.d.ts +1 -1
- package/dist/CodeArea.styles.d.ts +1 -1
- package/dist/CodeArea.styles.js +1 -1
- package/dist/CodeArea.types.d.ts +5 -6
- package/dist/components/BottomBar.d.ts +2 -2
- package/dist/components/CodeAreaEditor.d.ts +1 -1
- package/dist/components/CodeAreaEditor.js +6 -4
- package/dist/components/CodeAreaEditorRaw.d.ts +1 -1
- package/dist/components/CodeAreaEditorRaw.js +3 -4
- package/dist/components/ContentAbove.d.ts +1 -1
- package/dist/components/ContentBelow.d.ts +2 -2
- package/dist/components/FullscreenHeader.d.ts +3 -3
- package/dist/index.d.ts +1 -1
- package/dist/utils/getCharCount.js +3 -1
- package/dist/utils/getDefaultTexts.d.ts +1 -1
- package/package.json +11 -11
package/CHANGELOG.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
-
## [1.1.
|
|
6
|
+
## [1.1.11](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.10...@synerise/ds-code-area@1.1.11) (2025-07-01)
|
|
7
7
|
|
|
8
8
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
9
9
|
|
|
@@ -11,7 +11,7 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
## [1.1.
|
|
14
|
+
## [1.1.10](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.9...@synerise/ds-code-area@1.1.10) (2025-06-26)
|
|
15
15
|
|
|
16
16
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
17
17
|
|
|
@@ -19,7 +19,7 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
## [1.1.
|
|
22
|
+
## [1.1.9](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.8...@synerise/ds-code-area@1.1.9) (2025-06-24)
|
|
23
23
|
|
|
24
24
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
25
25
|
|
|
@@ -27,612 +27,318 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
|
|
27
27
|
|
|
28
28
|
|
|
29
29
|
|
|
30
|
-
## [1.1.
|
|
30
|
+
## [1.1.8](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.7...@synerise/ds-code-area@1.1.8) (2025-06-12)
|
|
31
31
|
|
|
32
32
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
33
33
|
|
|
34
|
+
## [1.1.7](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.6...@synerise/ds-code-area@1.1.7) (2025-06-11)
|
|
34
35
|
|
|
35
|
-
|
|
36
|
-
|
|
36
|
+
**Note:** Version bump only for package @synerise/ds-code-area
|
|
37
37
|
|
|
38
38
|
## [1.1.6](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.5...@synerise/ds-code-area@1.1.6) (2025-06-05)
|
|
39
39
|
|
|
40
40
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
41
41
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
42
|
## [1.1.5](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.4...@synerise/ds-code-area@1.1.5) (2025-06-03)
|
|
47
43
|
|
|
48
44
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
49
45
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
46
|
## [1.1.4](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.3...@synerise/ds-code-area@1.1.4) (2025-05-26)
|
|
55
47
|
|
|
56
48
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
57
49
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
50
|
## [1.1.3](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.2...@synerise/ds-code-area@1.1.3) (2025-05-19)
|
|
63
51
|
|
|
64
52
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
65
53
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
54
|
## [1.1.2](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.1...@synerise/ds-code-area@1.1.2) (2025-05-07)
|
|
71
55
|
|
|
72
56
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
73
57
|
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
58
|
## [1.1.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.0...@synerise/ds-code-area@1.1.1) (2025-04-24)
|
|
79
59
|
|
|
80
60
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
81
61
|
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
62
|
# [1.1.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.0.7...@synerise/ds-code-area@1.1.0) (2025-04-16)
|
|
87
63
|
|
|
88
|
-
|
|
89
64
|
### Features
|
|
90
65
|
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
66
|
+
- **form-field:** add form-field component ([7f6b191](https://github.com/Synerise/synerise-design/commit/7f6b191132a3b0d694c21fb4d649f4deea6acb89))
|
|
96
67
|
|
|
97
68
|
## [1.0.7](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.0.6...@synerise/ds-code-area@1.0.7) (2025-04-08)
|
|
98
69
|
|
|
99
|
-
|
|
100
70
|
### Bug Fixes
|
|
101
71
|
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
72
|
+
- **code-area:** allow component wrapper to have variable height ([7a15e3b](https://github.com/Synerise/synerise-design/commit/7a15e3b8622af0eb625e866fda8a7a3f041a2e40))
|
|
107
73
|
|
|
108
74
|
## [1.0.6](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.0.5...@synerise/ds-code-area@1.0.6) (2025-04-04)
|
|
109
75
|
|
|
110
76
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
111
77
|
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
78
|
## [1.0.5](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.0.4...@synerise/ds-code-area@1.0.5) (2025-04-02)
|
|
117
79
|
|
|
118
80
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
119
81
|
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
82
|
## [1.0.4](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.0.3...@synerise/ds-code-area@1.0.4) (2025-04-01)
|
|
125
83
|
|
|
126
84
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
127
85
|
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
86
|
## [1.0.3](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.0.2...@synerise/ds-code-area@1.0.3) (2025-03-31)
|
|
133
87
|
|
|
134
88
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
135
89
|
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
90
|
## [1.0.2](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.0.1...@synerise/ds-code-area@1.0.2) (2025-03-26)
|
|
141
91
|
|
|
142
92
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
143
93
|
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
94
|
## [1.0.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.0.0...@synerise/ds-code-area@1.0.1) (2025-03-18)
|
|
149
95
|
|
|
150
96
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
151
97
|
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
98
|
## [0.6.3](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.6.2...@synerise/ds-code-area@0.6.3) (2025-03-13)
|
|
157
99
|
|
|
158
|
-
|
|
159
100
|
### Bug Fixes
|
|
160
101
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
102
|
+
- **code-area:** test colorize ([e52a589](https://github.com/Synerise/synerise-design/commit/e52a5898b6ca86da350445002e8e77aaa92b68ac))
|
|
166
103
|
|
|
167
104
|
## [0.6.2](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.6.1...@synerise/ds-code-area@0.6.2) (2025-03-10)
|
|
168
105
|
|
|
169
106
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
170
107
|
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
108
|
## [0.6.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.6.0...@synerise/ds-code-area@0.6.1) (2025-03-04)
|
|
176
109
|
|
|
177
110
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
178
111
|
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
112
|
# [0.6.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.5.9...@synerise/ds-code-area@0.6.0) (2025-03-03)
|
|
184
113
|
|
|
185
|
-
|
|
186
114
|
### Features
|
|
187
115
|
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
116
|
+
- **code-area:** pass loader config via prop ([20d5bd2](https://github.com/Synerise/synerise-design/commit/20d5bd2e624a67c1a00111730b56819317970b0e))
|
|
193
117
|
|
|
194
118
|
## [0.5.9](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.5.8...@synerise/ds-code-area@0.5.9) (2025-02-27)
|
|
195
119
|
|
|
196
120
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
197
121
|
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
122
|
## [0.5.8](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.5.7...@synerise/ds-code-area@0.5.8) (2025-02-27)
|
|
203
123
|
|
|
204
124
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
205
125
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
126
|
## [0.5.7](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.5.6...@synerise/ds-code-area@0.5.7) (2025-02-20)
|
|
211
127
|
|
|
212
128
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
213
129
|
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
130
|
## [0.5.6](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.5.5...@synerise/ds-code-area@0.5.6) (2025-02-18)
|
|
219
131
|
|
|
220
132
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
221
133
|
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
134
|
## [0.5.5](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.5.4...@synerise/ds-code-area@0.5.5) (2025-02-17)
|
|
227
135
|
|
|
228
136
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
229
137
|
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
138
|
## [0.5.4](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.5.3...@synerise/ds-code-area@0.5.4) (2025-02-14)
|
|
235
139
|
|
|
236
140
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
237
141
|
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
142
|
## [0.5.3](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.5.2...@synerise/ds-code-area@0.5.3) (2025-02-14)
|
|
243
143
|
|
|
244
144
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
245
145
|
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
146
|
## [0.5.2](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.5.1...@synerise/ds-code-area@0.5.2) (2025-02-07)
|
|
251
147
|
|
|
252
148
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
253
149
|
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
150
|
## [0.5.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.5.0...@synerise/ds-code-area@0.5.1) (2025-02-04)
|
|
259
151
|
|
|
260
152
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
261
153
|
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
154
|
# [0.5.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.4.4...@synerise/ds-code-area@0.5.0) (2025-01-29)
|
|
267
155
|
|
|
268
|
-
|
|
269
156
|
### Features
|
|
270
157
|
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
158
|
+
- antd@4.24 react@18 ([d97a667](https://github.com/Synerise/synerise-design/commit/d97a667b1f33aed3177e1851de3b6f60be2d46a6))
|
|
276
159
|
|
|
277
160
|
## [0.4.4](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.4.3...@synerise/ds-code-area@0.4.4) (2025-01-21)
|
|
278
161
|
|
|
279
162
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
280
163
|
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
164
|
## [0.4.3](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.4.2...@synerise/ds-code-area@0.4.3) (2025-01-15)
|
|
286
165
|
|
|
287
166
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
288
167
|
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
168
|
## [0.4.2](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.4.1...@synerise/ds-code-area@0.4.2) (2024-12-16)
|
|
294
169
|
|
|
295
170
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
296
171
|
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
172
|
## [0.4.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.4.0...@synerise/ds-code-area@0.4.1) (2024-12-13)
|
|
302
173
|
|
|
303
174
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
304
175
|
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
176
|
# [0.4.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.3.4...@synerise/ds-code-area@0.4.0) (2024-12-11)
|
|
310
177
|
|
|
311
|
-
|
|
312
178
|
### Features
|
|
313
179
|
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
180
|
+
- **code-area:** switch monaco library ([c0d4ef6](https://github.com/Synerise/synerise-design/commit/c0d4ef68e26e791e99b4086b9847cbb524505af1))
|
|
319
181
|
|
|
320
182
|
## [0.3.4](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.3.3...@synerise/ds-code-area@0.3.4) (2024-12-04)
|
|
321
183
|
|
|
322
184
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
323
185
|
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
186
|
## [0.3.3](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.3.2...@synerise/ds-code-area@0.3.3) (2024-11-29)
|
|
329
187
|
|
|
330
188
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
331
189
|
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
190
|
## [0.3.2](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.3.1...@synerise/ds-code-area@0.3.2) (2024-11-28)
|
|
337
191
|
|
|
338
192
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
339
193
|
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
194
|
## [0.3.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.3.0...@synerise/ds-code-area@0.3.1) (2024-11-21)
|
|
345
195
|
|
|
346
|
-
|
|
347
196
|
### Bug Fixes
|
|
348
197
|
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
198
|
+
- **core:** onError fn types ([c34bdfe](https://github.com/Synerise/synerise-design/commit/c34bdfe9da898d7999c605f9fbcbba4716dfb6d4))
|
|
354
199
|
|
|
355
200
|
# [0.3.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.2.0...@synerise/ds-code-area@0.3.0) (2024-11-12)
|
|
356
201
|
|
|
357
|
-
|
|
358
202
|
### Features
|
|
359
203
|
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
204
|
+
- **code-area:** readonly and fullscreenlabel prop support ([553b36c](https://github.com/Synerise/synerise-design/commit/553b36c2e3efe4037d67eeb08d106318cd2d8b08))
|
|
365
205
|
|
|
366
206
|
# [0.2.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.32...@synerise/ds-code-area@0.2.0) (2024-11-12)
|
|
367
207
|
|
|
368
|
-
|
|
369
208
|
### Features
|
|
370
209
|
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
210
|
+
- **core:** reactintl bumped and onerror intlprovider ([08f4558](https://github.com/Synerise/synerise-design/commit/08f4558757a55c63db55767fff9fc6714728d26b))
|
|
376
211
|
|
|
377
212
|
## [0.1.32](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.31...@synerise/ds-code-area@0.1.32) (2024-10-29)
|
|
378
213
|
|
|
379
214
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
380
215
|
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
216
|
## [0.1.31](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.30...@synerise/ds-code-area@0.1.31) (2024-10-28)
|
|
386
217
|
|
|
387
218
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
388
219
|
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
220
|
## [0.1.30](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.29...@synerise/ds-code-area@0.1.30) (2024-10-23)
|
|
394
221
|
|
|
395
222
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
396
223
|
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
224
|
## [0.1.29](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.28...@synerise/ds-code-area@0.1.29) (2024-10-14)
|
|
402
225
|
|
|
403
226
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
404
227
|
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
228
|
## [0.1.28](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.27...@synerise/ds-code-area@0.1.28) (2024-10-01)
|
|
410
229
|
|
|
411
230
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
412
231
|
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
232
|
## [0.1.27](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.26...@synerise/ds-code-area@0.1.27) (2024-09-26)
|
|
418
233
|
|
|
419
234
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
420
235
|
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
236
|
## [0.1.26](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.25...@synerise/ds-code-area@0.1.26) (2024-09-17)
|
|
426
237
|
|
|
427
238
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
428
239
|
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
240
|
## [0.1.25](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.24...@synerise/ds-code-area@0.1.25) (2024-09-13)
|
|
434
241
|
|
|
435
242
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
436
243
|
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
244
|
## [0.1.24](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.23...@synerise/ds-code-area@0.1.24) (2024-09-11)
|
|
442
245
|
|
|
443
246
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
444
247
|
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
248
|
## [0.1.23](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.22...@synerise/ds-code-area@0.1.23) (2024-09-03)
|
|
450
249
|
|
|
451
250
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
452
251
|
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
252
|
## [0.1.22](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.21...@synerise/ds-code-area@0.1.22) (2024-08-30)
|
|
458
253
|
|
|
459
254
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
460
255
|
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
256
|
## [0.1.21](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.20...@synerise/ds-code-area@0.1.21) (2024-08-27)
|
|
466
257
|
|
|
467
258
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
468
259
|
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
260
|
## [0.1.20](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.19...@synerise/ds-code-area@0.1.20) (2024-08-19)
|
|
474
261
|
|
|
475
262
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
476
263
|
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
264
|
## [0.1.19](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.18...@synerise/ds-code-area@0.1.19) (2024-08-06)
|
|
482
265
|
|
|
483
266
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
484
267
|
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
268
|
## [0.1.18](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.17...@synerise/ds-code-area@0.1.18) (2024-07-31)
|
|
490
269
|
|
|
491
270
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
492
271
|
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
272
|
## [0.1.17](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.16...@synerise/ds-code-area@0.1.17) (2024-07-26)
|
|
498
273
|
|
|
499
274
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
500
275
|
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
276
|
## [0.1.16](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.15...@synerise/ds-code-area@0.1.16) (2024-07-15)
|
|
506
277
|
|
|
507
278
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
508
279
|
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
280
|
## [0.1.15](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.14...@synerise/ds-code-area@0.1.15) (2024-07-05)
|
|
514
281
|
|
|
515
282
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
516
283
|
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
284
|
## [0.1.14](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.13...@synerise/ds-code-area@0.1.14) (2024-07-02)
|
|
522
285
|
|
|
523
286
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
524
287
|
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
288
|
## [0.1.13](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.12...@synerise/ds-code-area@0.1.13) (2024-06-27)
|
|
530
289
|
|
|
531
290
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
532
291
|
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
292
|
## [0.1.12](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.11...@synerise/ds-code-area@0.1.12) (2024-06-24)
|
|
538
293
|
|
|
539
294
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
540
295
|
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
296
|
## [0.1.11](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.10...@synerise/ds-code-area@0.1.11) (2024-06-21)
|
|
546
297
|
|
|
547
298
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
548
299
|
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
300
|
## [0.1.10](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.9...@synerise/ds-code-area@0.1.10) (2024-06-05)
|
|
554
301
|
|
|
555
302
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
556
303
|
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
304
|
## [0.1.9](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.8...@synerise/ds-code-area@0.1.9) (2024-05-29)
|
|
562
305
|
|
|
563
306
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
564
307
|
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
308
|
## [0.1.8](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.7...@synerise/ds-code-area@0.1.8) (2024-05-23)
|
|
570
309
|
|
|
571
310
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
572
311
|
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
312
|
## [0.1.7](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.6...@synerise/ds-code-area@0.1.7) (2024-05-23)
|
|
578
313
|
|
|
579
314
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
580
315
|
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
316
|
## [0.1.6](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.5...@synerise/ds-code-area@0.1.6) (2024-05-16)
|
|
586
317
|
|
|
587
318
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
588
319
|
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
320
|
## [0.1.5](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.4...@synerise/ds-code-area@0.1.5) (2024-05-10)
|
|
594
321
|
|
|
595
322
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
596
323
|
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
324
|
## [0.1.4](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.3...@synerise/ds-code-area@0.1.4) (2024-05-08)
|
|
602
325
|
|
|
603
326
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
604
327
|
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
328
|
## [0.1.3](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.2...@synerise/ds-code-area@0.1.3) (2024-05-08)
|
|
610
329
|
|
|
611
330
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
612
331
|
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
332
|
## [0.1.2](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.1...@synerise/ds-code-area@0.1.2) (2024-04-29)
|
|
618
333
|
|
|
619
334
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
620
335
|
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
336
|
## [0.1.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@0.1.0...@synerise/ds-code-area@0.1.1) (2024-04-25)
|
|
626
337
|
|
|
627
338
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
628
339
|
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
340
|
# 0.1.0 (2024-04-17)
|
|
634
341
|
|
|
635
|
-
|
|
636
342
|
### Features
|
|
637
343
|
|
|
638
|
-
|
|
344
|
+
- **code-area:** new component ([2a94d6e](https://github.com/Synerise/synerise-design/commit/2a94d6ea3c830f803fbd10b00ae009d5e20575e2))
|
package/README.md
CHANGED
|
@@ -14,7 +14,7 @@ yarn add @synerise/ds-code-area
|
|
|
14
14
|
```
|
|
15
15
|
|
|
16
16
|
To have syntax validation you need to follow the integration instructions here:
|
|
17
|
-
https://github.com/microsoft/monaco-editor/blob/main/docs/integrate-esm.md
|
|
17
|
+
https://github.com/microsoft/monaco-editor/blob/main/docs/integrate-esm.md
|
|
18
18
|
|
|
19
19
|
## Usage
|
|
20
20
|
|
|
@@ -41,16 +41,15 @@ const syntaxOptions = [
|
|
|
41
41
|
|
|
42
42
|
```
|
|
43
43
|
|
|
44
|
-
|
|
45
44
|
## API
|
|
46
45
|
|
|
47
46
|
| Property | Description | Type | Default |
|
|
48
|
-
|
|
47
|
+
| --------------------------- | -------------------------------------------------------------- | ------------------------------------------------------- | ------- |
|
|
49
48
|
| label | label above editor | `ReactNode` | - |
|
|
50
49
|
| fullscreenLabel | label above editor in fullscreen mode (defaults to label prop) | `ReactNode` | - |
|
|
51
50
|
| description | description below editor | `ReactNode` | - |
|
|
52
51
|
| counter | limit character count | `{ limit: number; placement?: 'bottom' | 'top'; }` | - |
|
|
53
|
-
| errorText | error message to show below editor
|
|
52
|
+
| errorText | error message to show below editor (also adds "error styles") | `ReactNode` | - |
|
|
54
53
|
| syntaxOptions | array of available syntaxes | `CodeAreaSyntaxOption[]` | - |
|
|
55
54
|
| currentSyntax | current syntax of editor value | `CodeAreaSyntax` | - |
|
|
56
55
|
| allowFullscreen | renders fullscreen mode button | `boolean` | - |
|
|
@@ -66,31 +65,28 @@ const syntaxOptions = [
|
|
|
66
65
|
| texts | customise displayed texts | `CodeAreaTexts` | - |
|
|
67
66
|
| getPopupContainer | customise where fullscreen layer is rendered into | getPopupContainer (@synerise/ds-utils) | - |
|
|
68
67
|
|
|
69
|
-
|
|
70
68
|
### CodeAreaTexts
|
|
71
69
|
|
|
72
70
|
Customisable user-facing labels
|
|
73
71
|
|
|
74
|
-
| Property
|
|
75
|
-
|
|
|
76
|
-
| fullscreen
|
|
77
|
-
| closeFullscreen
|
|
78
|
-
| fullscreenTitle
|
|
79
|
-
|
|
80
|
-
|
|
72
|
+
| Property | Description | Type | Default |
|
|
73
|
+
| --------------- | --------------------------------------------------- | ----------- | ------- |
|
|
74
|
+
| fullscreen | fullscreen button label | `ReactNode` | - |
|
|
75
|
+
| closeFullscreen | close fullscreen button label | `ReactNode` | - |
|
|
76
|
+
| fullscreenTitle | used in fullscreen mode if no `label` prop provided | `ReactNode` | - |
|
|
81
77
|
|
|
82
78
|
### CodeAreaSyntaxOption
|
|
83
79
|
|
|
84
80
|
At least one syntax option must be provided.
|
|
85
81
|
|
|
86
|
-
| Property
|
|
87
|
-
|
|
|
88
|
-
| language
|
|
89
|
-
| label
|
|
82
|
+
| Property | Description | Type | Default |
|
|
83
|
+
| -------- | ----------------------------------- | ---------------- | ------- |
|
|
84
|
+
| language | language of editor `value` | `CodeAreaSyntax` | - |
|
|
85
|
+
| label | optional user-friendly display name | `string` | - |
|
|
90
86
|
|
|
91
87
|
### CodeAreaSyntax
|
|
92
88
|
|
|
93
|
-
See list of languages supported by monaco here: https://github.com/microsoft/monaco-editor/tree/main/src/basic-languages.
|
|
89
|
+
See list of languages supported by monaco here: https://github.com/microsoft/monaco-editor/tree/main/src/basic-languages.
|
|
94
90
|
|
|
95
91
|
```js
|
|
96
92
|
CodeAreaSyntax = 'json' | 'html' | 'css' | 'typescript' | 'javascript' | string;
|
|
@@ -100,8 +96,8 @@ CodeAreaSyntax = 'json' | 'html' | 'css' | 'typescript' | 'javascript' | string;
|
|
|
100
96
|
|
|
101
97
|
Props passed to `renderAdditionalDescription()` and `renderFooterContent()`.
|
|
102
98
|
|
|
103
|
-
| Property
|
|
104
|
-
|
|
|
105
|
-
| isFullscreen
|
|
106
|
-
| count
|
|
107
|
-
| isValid
|
|
99
|
+
| Property | Description | Type | Default |
|
|
100
|
+
| ------------ | ---------------------------- | --------- | ------- |
|
|
101
|
+
| isFullscreen | is fullscreen mode on or off | `boolean` | - |
|
|
102
|
+
| count | current character count | `number` | - |
|
|
103
|
+
| isValid | is editor value valid | `boolean` | - |
|
package/dist/CodeArea.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { CodeAreaProps } from './CodeArea.types';
|
|
2
|
+
import { type CodeAreaProps } from './CodeArea.types';
|
|
3
3
|
declare const CodeArea: ({ getPopupContainer, onFullscreenChange, ...codeAreaProps }: CodeAreaProps) => React.JSX.Element;
|
|
4
4
|
export default CodeArea;
|
|
@@ -19,7 +19,7 @@ export declare const ContentBelow: import("styled-components").StyledComponent<"
|
|
|
19
19
|
isEmpty?: boolean | undefined;
|
|
20
20
|
}, never>;
|
|
21
21
|
export declare const ContentAbove: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
22
|
-
export declare const SyntaxTitle: import("styled-components").StyledComponent<({ size, className, children, ellipsis }: {
|
|
22
|
+
export declare const SyntaxTitle: import("styled-components").StyledComponent<({ size, className, children, ellipsis, }: {
|
|
23
23
|
size?: import("@synerise/ds-typography").TextSize | undefined;
|
|
24
24
|
ellipsis?: import("@synerise/ds-typography/dist/Ellipsis").EllipsisProps | undefined;
|
|
25
25
|
children?: import("react").ReactNode;
|
package/dist/CodeArea.styles.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import styled, { css } from 'styled-components';
|
|
2
|
-
import {
|
|
2
|
+
import { Text, Title } from '@synerise/ds-typography';
|
|
3
3
|
var FlexRow = styled.div.withConfig({
|
|
4
4
|
displayName: "CodeAreastyles__FlexRow",
|
|
5
5
|
componentId: "sc-svoej2-0"
|
package/dist/CodeArea.types.d.ts
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import type
|
|
1
|
+
import type { editor } from 'monaco-editor/esm/vs/editor/editor.api';
|
|
2
|
+
import type { CSSProperties, ReactNode } from 'react';
|
|
2
3
|
import type { EditorProps, loader } from '@monaco-editor/react';
|
|
3
|
-
import type {
|
|
4
|
-
import type { TooltipProps } from 'antd/lib/tooltip';
|
|
5
|
-
import TooltipExtendedProps from '@synerise/ds-tooltip/dist/Tooltip.types';
|
|
4
|
+
import type { TooltipProps } from '@synerise/ds-tooltip';
|
|
6
5
|
export type CodeAreaSyntax = 'json' | 'html' | 'css' | 'typescript' | 'javascript' | string;
|
|
7
6
|
export type CodeAreaSyntaxOption<SyntaxName extends CodeAreaSyntax = CodeAreaSyntax> = {
|
|
8
7
|
language: SyntaxName;
|
|
@@ -31,7 +30,7 @@ export type CodeAreaCommonProps<SyntaxName extends CodeAreaSyntax = CodeAreaSynt
|
|
|
31
30
|
defaultValue?: string;
|
|
32
31
|
readOnly?: boolean;
|
|
33
32
|
tooltip?: ReactNode;
|
|
34
|
-
tooltipProps?:
|
|
33
|
+
tooltipProps?: TooltipProps;
|
|
35
34
|
style?: CSSProperties;
|
|
36
35
|
zIndex?: string | number;
|
|
37
36
|
/**
|
|
@@ -62,7 +61,7 @@ export type CodeAreaProps<SyntaxName extends CodeAreaSyntax = CodeAreaSyntax> =
|
|
|
62
61
|
export type CodeAreaEditorRawProps<SyntaxName extends CodeAreaSyntax = CodeAreaSyntax> = CodeAreaCommonProps<SyntaxName> & {
|
|
63
62
|
isValid: boolean;
|
|
64
63
|
isSyntaxSelectVisible?: boolean;
|
|
65
|
-
onDidChangeMarkers?: (markers:
|
|
64
|
+
onDidChangeMarkers?: (markers: editor.IMarker[]) => void;
|
|
66
65
|
counterLimit?: number;
|
|
67
66
|
count?: number;
|
|
68
67
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React, { ReactNode } from 'react';
|
|
2
|
-
import { CodeAreaTexts } from '../CodeArea.types';
|
|
1
|
+
import React, { type ReactNode } from 'react';
|
|
2
|
+
import { type CodeAreaTexts } from '../CodeArea.types';
|
|
3
3
|
type BottomBarProps = {
|
|
4
4
|
texts: CodeAreaTexts;
|
|
5
5
|
allowFullscreen?: boolean;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { CodeAreaEditorProps } from '../CodeArea.types';
|
|
2
|
+
import { type CodeAreaEditorProps } from '../CodeArea.types';
|
|
3
3
|
export declare const CodeAreaEditor: ({ renderAdditionalDescription, description, errorText, style, zIndex, className, counter, fullscreenLabel, tooltip, label, tooltipProps, height, ...props }: CodeAreaEditorProps) => React.JSX.Element;
|
|
4
4
|
export default CodeAreaEditor;
|
|
@@ -4,12 +4,14 @@ function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t =
|
|
|
4
4
|
import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react';
|
|
5
5
|
import { FormFieldLabel } from '@synerise/ds-form-field';
|
|
6
6
|
import { useResizeObserver } from '@synerise/ds-utils';
|
|
7
|
-
import { getCharCount } from '../utils/getCharCount';
|
|
8
|
-
import { ContentAbove, ContentBelow, FullscreenHeader } from './index';
|
|
9
|
-
import { CodeAreaEditorRaw } from './CodeAreaEditorRaw';
|
|
10
7
|
import * as S from '../CodeArea.styles';
|
|
11
|
-
import { getDefaultTexts } from '../utils/getDefaultTexts';
|
|
12
8
|
import { calculateRequiredSpace } from '../utils/calculateRequiredSpace';
|
|
9
|
+
import { getCharCount } from '../utils/getCharCount';
|
|
10
|
+
import { getDefaultTexts } from '../utils/getDefaultTexts';
|
|
11
|
+
import { CodeAreaEditorRaw } from './CodeAreaEditorRaw';
|
|
12
|
+
import { ContentAbove } from './ContentAbove';
|
|
13
|
+
import { ContentBelow } from './ContentBelow';
|
|
14
|
+
import { FullscreenHeader } from './FullscreenHeader';
|
|
13
15
|
export var CodeAreaEditor = function CodeAreaEditor(_ref) {
|
|
14
16
|
var renderAdditionalDescription = _ref.renderAdditionalDescription,
|
|
15
17
|
description = _ref.description,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { CodeAreaEditorRawProps } from '../CodeArea.types';
|
|
2
|
+
import { type CodeAreaEditorRawProps } from '../CodeArea.types';
|
|
3
3
|
export declare const CodeAreaEditorRaw: ({ onMount, beforeMount, options, errorText, texts, allowFullscreen, toggleFullscreen, renderFooterContent, isFullscreen, count, counterLimit, onChange, isValid, onDidChangeMarkers, isSyntaxSelectVisible, syntaxOptions, currentSyntax, readOnly, onSyntaxChange, loaderConfig, ...props }: CodeAreaEditorRawProps) => React.JSX.Element;
|
|
4
4
|
export default CodeAreaEditorRaw;
|
|
@@ -3,13 +3,13 @@ function _extends() { return _extends = Object.assign ? Object.assign.bind() : f
|
|
|
3
3
|
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }
|
|
4
4
|
import React, { useCallback, useEffect, useMemo, useRef } from 'react';
|
|
5
5
|
import Editor, { loader } from '@monaco-editor/react';
|
|
6
|
-
import Loader from '@synerise/ds-loader';
|
|
7
6
|
import { InlineSelect } from '@synerise/ds-inline-edit';
|
|
7
|
+
import Loader from '@synerise/ds-loader';
|
|
8
8
|
import { NOOP, useResizeObserver } from '@synerise/ds-utils';
|
|
9
|
-
import
|
|
9
|
+
import * as S from '../CodeArea.styles';
|
|
10
10
|
import { DS_MONACO_THEME, DS_MONACO_THEME_NAME, MONACO_DEFAULT_OPTIONS, TRIGGER_SOURCE } from '../constants';
|
|
11
|
+
import { getDefaultTexts } from '../utils/getDefaultTexts';
|
|
11
12
|
import { AriaContainer } from './AriaContainer';
|
|
12
|
-
import * as S from '../CodeArea.styles';
|
|
13
13
|
import { BottomBar } from './BottomBar';
|
|
14
14
|
export var CodeAreaEditorRaw = function CodeAreaEditorRaw(_ref) {
|
|
15
15
|
var onMount = _ref.onMount,
|
|
@@ -132,7 +132,6 @@ export var CodeAreaEditorRaw = function CodeAreaEditorRaw(_ref) {
|
|
|
132
132
|
if (editorRef.current) {
|
|
133
133
|
var _editorRef$current, _monacoRef$current;
|
|
134
134
|
var currentModel = (_editorRef$current = editorRef.current) == null ? void 0 : _editorRef$current.getModel();
|
|
135
|
-
// eslint-disable-next-line no-unused-expressions
|
|
136
135
|
currentModel && ((_monacoRef$current = monacoRef.current) == null ? void 0 : _monacoRef$current.editor.setModelLanguage(currentModel, currentSyntax));
|
|
137
136
|
}
|
|
138
137
|
}, [currentSyntax]);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React, { ReactNode } from 'react';
|
|
2
|
-
import { CodeAreaProps } from '../CodeArea.types';
|
|
1
|
+
import React, { type ReactNode } from 'react';
|
|
2
|
+
import { type CodeAreaProps } from '../CodeArea.types';
|
|
3
3
|
export declare const ContentBelow: React.ForwardRefExoticComponent<Pick<CodeAreaProps<string>, "description" | "errorText"> & {
|
|
4
4
|
additionalDescription?: ReactNode;
|
|
5
5
|
counter?: ReactNode;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import React, { ReactNode } from 'react';
|
|
2
|
-
import { CodeAreaTexts } from '../CodeArea.types';
|
|
1
|
+
import React, { type ReactNode } from 'react';
|
|
2
|
+
import { type CodeAreaTexts } from '../CodeArea.types';
|
|
3
3
|
type FullscreenHeaderProps = {
|
|
4
4
|
label?: ReactNode;
|
|
5
5
|
texts: CodeAreaTexts;
|
|
6
6
|
onClick: () => void;
|
|
7
7
|
};
|
|
8
|
-
export declare const FullscreenHeader: ({ label, texts, onClick }: FullscreenHeaderProps) => React.JSX.Element;
|
|
8
|
+
export declare const FullscreenHeader: ({ label, texts, onClick, }: FullscreenHeaderProps) => React.JSX.Element;
|
|
9
9
|
export {};
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export { default } from './CodeArea';
|
|
2
|
-
export type { CodeAreaProps, CodeAreaTexts, CodeAreaSyntaxOption, CodeAreaSyntax } from './CodeArea.types';
|
|
2
|
+
export type { CodeAreaProps, CodeAreaTexts, CodeAreaSyntaxOption, CodeAreaSyntax, } from './CodeArea.types';
|
|
3
3
|
export * from './CodeArea.styles';
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
export var getCharCount = function getCharCount(value, limit) {
|
|
2
|
-
if (limit && value && value.toString().length > limit)
|
|
2
|
+
if (limit && value && value.toString().length > limit) {
|
|
3
|
+
return undefined;
|
|
4
|
+
}
|
|
3
5
|
return value ? value.toString().length : 0;
|
|
4
6
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { CodeAreaTexts } from '../CodeArea.types';
|
|
1
|
+
import { type CodeAreaTexts } from '../CodeArea.types';
|
|
2
2
|
export declare const getDefaultTexts: (texts?: Partial<CodeAreaTexts>) => CodeAreaTexts;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@synerise/ds-code-area",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.11",
|
|
4
4
|
"description": "CodeArea UI Component for the Synerise Design System",
|
|
5
5
|
"license": "ISC",
|
|
6
6
|
"repository": "Synerise/synerise-design",
|
|
@@ -35,15 +35,15 @@
|
|
|
35
35
|
"types": "dist/index.d.ts",
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@monaco-editor/react": "4.4.6",
|
|
38
|
-
"@synerise/ds-button": "^1.4.
|
|
39
|
-
"@synerise/ds-core": "^1.4.
|
|
40
|
-
"@synerise/ds-form-field": "^1.1.
|
|
41
|
-
"@synerise/ds-icon": "^1.5.
|
|
42
|
-
"@synerise/ds-inline-edit": "^1.0.
|
|
43
|
-
"@synerise/ds-loader": "^1.0.
|
|
44
|
-
"@synerise/ds-tooltip": "^1.1.
|
|
45
|
-
"@synerise/ds-typography": "^1.0.
|
|
46
|
-
"@synerise/ds-utils": "^1.3.
|
|
38
|
+
"@synerise/ds-button": "^1.4.2",
|
|
39
|
+
"@synerise/ds-core": "^1.4.1",
|
|
40
|
+
"@synerise/ds-form-field": "^1.1.8",
|
|
41
|
+
"@synerise/ds-icon": "^1.5.4",
|
|
42
|
+
"@synerise/ds-inline-edit": "^1.0.17",
|
|
43
|
+
"@synerise/ds-loader": "^1.0.6",
|
|
44
|
+
"@synerise/ds-tooltip": "^1.1.12",
|
|
45
|
+
"@synerise/ds-typography": "^1.0.13",
|
|
46
|
+
"@synerise/ds-utils": "^1.3.1"
|
|
47
47
|
},
|
|
48
48
|
"peerDependencies": {
|
|
49
49
|
"@synerise/ds-core": "*",
|
|
@@ -55,5 +55,5 @@
|
|
|
55
55
|
"devDependencies": {
|
|
56
56
|
"monaco-editor": "0.34.1"
|
|
57
57
|
},
|
|
58
|
-
"gitHead": "
|
|
58
|
+
"gitHead": "4512641033ba3581a3df208143c547fcfed45895"
|
|
59
59
|
}
|