@synerise/ds-code-area 1.1.10 → 1.1.12
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 +19 -305
- 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.12](https://github.com/Synerise/synerise-design/compare/@synerise/ds-code-area@1.1.11...@synerise/ds-code-area@1.1.12) (2025-07-08)
|
|
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.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)
|
|
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.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)
|
|
23
23
|
|
|
24
24
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
25
25
|
|
|
@@ -27,7 +27,7 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
|
|
27
27
|
|
|
28
28
|
|
|
29
29
|
|
|
30
|
-
## [1.1.
|
|
30
|
+
## [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)
|
|
31
31
|
|
|
32
32
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
33
33
|
|
|
@@ -35,604 +35,318 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
|
|
35
35
|
|
|
36
36
|
|
|
37
37
|
|
|
38
|
-
## [1.1.
|
|
38
|
+
## [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)
|
|
39
39
|
|
|
40
40
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
41
41
|
|
|
42
|
+
## [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)
|
|
42
43
|
|
|
44
|
+
**Note:** Version bump only for package @synerise/ds-code-area
|
|
43
45
|
|
|
46
|
+
## [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)
|
|
44
47
|
|
|
48
|
+
**Note:** Version bump only for package @synerise/ds-code-area
|
|
45
49
|
|
|
46
50
|
## [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
51
|
|
|
48
52
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
49
53
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
54
|
## [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
55
|
|
|
56
56
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
57
57
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
58
|
## [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
59
|
|
|
64
60
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
65
61
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
62
|
## [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
63
|
|
|
72
64
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
73
65
|
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
66
|
## [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
67
|
|
|
80
68
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
81
69
|
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
70
|
# [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
71
|
|
|
88
|
-
|
|
89
72
|
### Features
|
|
90
73
|
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
74
|
+
- **form-field:** add form-field component ([7f6b191](https://github.com/Synerise/synerise-design/commit/7f6b191132a3b0d694c21fb4d649f4deea6acb89))
|
|
96
75
|
|
|
97
76
|
## [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
77
|
|
|
99
|
-
|
|
100
78
|
### Bug Fixes
|
|
101
79
|
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
80
|
+
- **code-area:** allow component wrapper to have variable height ([7a15e3b](https://github.com/Synerise/synerise-design/commit/7a15e3b8622af0eb625e866fda8a7a3f041a2e40))
|
|
107
81
|
|
|
108
82
|
## [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
83
|
|
|
110
84
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
111
85
|
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
86
|
## [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
87
|
|
|
118
88
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
119
89
|
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
90
|
## [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
91
|
|
|
126
92
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
127
93
|
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
94
|
## [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
95
|
|
|
134
96
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
135
97
|
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
98
|
## [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
99
|
|
|
142
100
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
143
101
|
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
102
|
## [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
103
|
|
|
150
104
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
151
105
|
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
106
|
## [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
107
|
|
|
158
|
-
|
|
159
108
|
### Bug Fixes
|
|
160
109
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
110
|
+
- **code-area:** test colorize ([e52a589](https://github.com/Synerise/synerise-design/commit/e52a5898b6ca86da350445002e8e77aaa92b68ac))
|
|
166
111
|
|
|
167
112
|
## [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
113
|
|
|
169
114
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
170
115
|
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
116
|
## [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
117
|
|
|
177
118
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
178
119
|
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
120
|
# [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
121
|
|
|
185
|
-
|
|
186
122
|
### Features
|
|
187
123
|
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
124
|
+
- **code-area:** pass loader config via prop ([20d5bd2](https://github.com/Synerise/synerise-design/commit/20d5bd2e624a67c1a00111730b56819317970b0e))
|
|
193
125
|
|
|
194
126
|
## [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
127
|
|
|
196
128
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
197
129
|
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
130
|
## [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
131
|
|
|
204
132
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
205
133
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
134
|
## [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
135
|
|
|
212
136
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
213
137
|
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
138
|
## [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
139
|
|
|
220
140
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
221
141
|
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
142
|
## [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
143
|
|
|
228
144
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
229
145
|
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
146
|
## [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
147
|
|
|
236
148
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
237
149
|
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
150
|
## [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
151
|
|
|
244
152
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
245
153
|
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
154
|
## [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
155
|
|
|
252
156
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
253
157
|
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
158
|
## [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
159
|
|
|
260
160
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
261
161
|
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
162
|
# [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
163
|
|
|
268
|
-
|
|
269
164
|
### Features
|
|
270
165
|
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
166
|
+
- antd@4.24 react@18 ([d97a667](https://github.com/Synerise/synerise-design/commit/d97a667b1f33aed3177e1851de3b6f60be2d46a6))
|
|
276
167
|
|
|
277
168
|
## [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
169
|
|
|
279
170
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
280
171
|
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
172
|
## [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
173
|
|
|
287
174
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
288
175
|
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
176
|
## [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
177
|
|
|
295
178
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
296
179
|
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
180
|
## [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
181
|
|
|
303
182
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
304
183
|
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
184
|
# [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
185
|
|
|
311
|
-
|
|
312
186
|
### Features
|
|
313
187
|
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
188
|
+
- **code-area:** switch monaco library ([c0d4ef6](https://github.com/Synerise/synerise-design/commit/c0d4ef68e26e791e99b4086b9847cbb524505af1))
|
|
319
189
|
|
|
320
190
|
## [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
191
|
|
|
322
192
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
323
193
|
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
194
|
## [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
195
|
|
|
330
196
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
331
197
|
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
198
|
## [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
199
|
|
|
338
200
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
339
201
|
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
202
|
## [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
203
|
|
|
346
|
-
|
|
347
204
|
### Bug Fixes
|
|
348
205
|
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
206
|
+
- **core:** onError fn types ([c34bdfe](https://github.com/Synerise/synerise-design/commit/c34bdfe9da898d7999c605f9fbcbba4716dfb6d4))
|
|
354
207
|
|
|
355
208
|
# [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
209
|
|
|
357
|
-
|
|
358
210
|
### Features
|
|
359
211
|
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
212
|
+
- **code-area:** readonly and fullscreenlabel prop support ([553b36c](https://github.com/Synerise/synerise-design/commit/553b36c2e3efe4037d67eeb08d106318cd2d8b08))
|
|
365
213
|
|
|
366
214
|
# [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
215
|
|
|
368
|
-
|
|
369
216
|
### Features
|
|
370
217
|
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
218
|
+
- **core:** reactintl bumped and onerror intlprovider ([08f4558](https://github.com/Synerise/synerise-design/commit/08f4558757a55c63db55767fff9fc6714728d26b))
|
|
376
219
|
|
|
377
220
|
## [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
221
|
|
|
379
222
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
380
223
|
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
224
|
## [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
225
|
|
|
387
226
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
388
227
|
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
228
|
## [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
229
|
|
|
395
230
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
396
231
|
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
232
|
## [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
233
|
|
|
403
234
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
404
235
|
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
236
|
## [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
237
|
|
|
411
238
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
412
239
|
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
240
|
## [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
241
|
|
|
419
242
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
420
243
|
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
244
|
## [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
245
|
|
|
427
246
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
428
247
|
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
248
|
## [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
249
|
|
|
435
250
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
436
251
|
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
252
|
## [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
253
|
|
|
443
254
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
444
255
|
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
256
|
## [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
257
|
|
|
451
258
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
452
259
|
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
260
|
## [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
261
|
|
|
459
262
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
460
263
|
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
264
|
## [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
265
|
|
|
467
266
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
468
267
|
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
268
|
## [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
269
|
|
|
475
270
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
476
271
|
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
272
|
## [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
273
|
|
|
483
274
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
484
275
|
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
276
|
## [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
277
|
|
|
491
278
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
492
279
|
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
280
|
## [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
281
|
|
|
499
282
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
500
283
|
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
284
|
## [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
285
|
|
|
507
286
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
508
287
|
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
288
|
## [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
289
|
|
|
515
290
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
516
291
|
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
292
|
## [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
293
|
|
|
523
294
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
524
295
|
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
296
|
## [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
297
|
|
|
531
298
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
532
299
|
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
300
|
## [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
301
|
|
|
539
302
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
540
303
|
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
304
|
## [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
305
|
|
|
547
306
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
548
307
|
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
308
|
## [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
309
|
|
|
555
310
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
556
311
|
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
312
|
## [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
313
|
|
|
563
314
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
564
315
|
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
316
|
## [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
317
|
|
|
571
318
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
572
319
|
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
320
|
## [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
321
|
|
|
579
322
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
580
323
|
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
324
|
## [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
325
|
|
|
587
326
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
588
327
|
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
328
|
## [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
329
|
|
|
595
330
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
596
331
|
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
332
|
## [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
333
|
|
|
603
334
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
604
335
|
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
336
|
## [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
337
|
|
|
611
338
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
612
339
|
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
340
|
## [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
341
|
|
|
619
342
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
620
343
|
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
344
|
## [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
345
|
|
|
627
346
|
**Note:** Version bump only for package @synerise/ds-code-area
|
|
628
347
|
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
348
|
# 0.1.0 (2024-04-17)
|
|
634
349
|
|
|
635
|
-
|
|
636
350
|
### Features
|
|
637
351
|
|
|
638
|
-
|
|
352
|
+
- **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.12",
|
|
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.3",
|
|
39
|
+
"@synerise/ds-core": "^1.4.2",
|
|
40
|
+
"@synerise/ds-form-field": "^1.1.9",
|
|
41
|
+
"@synerise/ds-icon": "^1.5.4",
|
|
42
|
+
"@synerise/ds-inline-edit": "^1.0.18",
|
|
43
|
+
"@synerise/ds-loader": "^1.0.6",
|
|
44
|
+
"@synerise/ds-tooltip": "^1.1.12",
|
|
45
|
+
"@synerise/ds-typography": "^1.0.14",
|
|
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": "8db1900bf3f7b0782c834ff82f628199530cd934"
|
|
59
59
|
}
|