@dpuse/dpuse-shared 0.3.863 → 0.3.867
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/README.md +30 -84
- package/dist/dpuse-shared.es.js +1473 -0
- package/dist/dpuse-shared.es.js.map +1 -0
- package/dist/types/src/index.d.ts +24 -0
- package/package.json +10 -110
- package/dist/componentConfig.schema-DT3mO5rS.js +0 -416
- package/dist/componentConfig.schema-DT3mO5rS.js.map +0 -1
- package/dist/dpuse-shared-component.es.js +0 -53
- package/dist/dpuse-shared-component.es.js.map +0 -1
- package/dist/dpuse-shared-componentConnection.es.js +0 -0
- package/dist/dpuse-shared-componentContext.es.js +0 -0
- package/dist/dpuse-shared-componentContextModel.es.js +0 -0
- package/dist/dpuse-shared-componentContextModelDimension.es.js +0 -0
- package/dist/dpuse-shared-componentContextModelDimensionHierarchy.es.js +0 -0
- package/dist/dpuse-shared-componentContextModelEntity.es.js +0 -0
- package/dist/dpuse-shared-componentContextModelEntityDataItem.es.js +0 -0
- package/dist/dpuse-shared-componentContextModelEntityEvent.es.js +0 -0
- package/dist/dpuse-shared-componentContextModelEntityPrimaryMeasure.es.js +0 -0
- package/dist/dpuse-shared-componentContextModelSecondaryMeasure.es.js +0 -0
- package/dist/dpuse-shared-componentDataView.es.js +0 -18
- package/dist/dpuse-shared-componentDataView.es.js.map +0 -1
- package/dist/dpuse-shared-componentEventQuery.es.js +0 -0
- package/dist/dpuse-shared-componentModule.es.js +0 -0
- package/dist/dpuse-shared-componentModuleConnector.es.js +0 -182
- package/dist/dpuse-shared-componentModuleConnector.es.js.map +0 -1
- package/dist/dpuse-shared-componentModuleCookbook.es.js +0 -11
- package/dist/dpuse-shared-componentModuleCookbook.es.js.map +0 -1
- package/dist/dpuse-shared-componentModuleEngine.es.js +0 -0
- package/dist/dpuse-shared-componentModulePresenter.es.js +0 -15
- package/dist/dpuse-shared-componentModulePresenter.es.js.map +0 -1
- package/dist/dpuse-shared-componentModuleTool.es.js +0 -29
- package/dist/dpuse-shared-componentModuleTool.es.js.map +0 -1
- package/dist/dpuse-shared-componentPresentation.es.js +0 -0
- package/dist/dpuse-shared-componentRecipe.es.js +0 -0
- package/dist/dpuse-shared-encoding.es.js +0 -467
- package/dist/dpuse-shared-encoding.es.js.map +0 -1
- package/dist/dpuse-shared-errors.es.js +0 -150
- package/dist/dpuse-shared-errors.es.js.map +0 -1
- package/dist/dpuse-shared-locale.es.js +0 -28
- package/dist/dpuse-shared-locale.es.js.map +0 -1
- package/dist/dpuse-shared-utilities.es.js +0 -109
- package/dist/dpuse-shared-utilities.es.js.map +0 -1
- package/dist/label-DexpXrnC.js +0 -19
- package/dist/label-DexpXrnC.js.map +0 -1
- package/dist/moduleConfig.schema-aYmFWSrn.js +0 -22
- package/dist/moduleConfig.schema-aYmFWSrn.js.map +0 -1
|
@@ -1,467 +0,0 @@
|
|
|
1
|
-
import "./label-DexpXrnC.js";
|
|
2
|
-
//#region src/encoding/index.ts
|
|
3
|
-
var e = {
|
|
4
|
-
arabic: {
|
|
5
|
-
id: "arabic",
|
|
6
|
-
label: {
|
|
7
|
-
en: "Arabic",
|
|
8
|
-
es: "Árabe"
|
|
9
|
-
}
|
|
10
|
-
},
|
|
11
|
-
baltic: {
|
|
12
|
-
id: "baltic",
|
|
13
|
-
label: {
|
|
14
|
-
en: "Baltic",
|
|
15
|
-
es: "Báltico"
|
|
16
|
-
}
|
|
17
|
-
},
|
|
18
|
-
celtic: {
|
|
19
|
-
id: "celtic",
|
|
20
|
-
label: {
|
|
21
|
-
en: "Celtic",
|
|
22
|
-
es: "Celta"
|
|
23
|
-
}
|
|
24
|
-
},
|
|
25
|
-
centralEuropean: {
|
|
26
|
-
id: "centralEuropean",
|
|
27
|
-
label: {
|
|
28
|
-
en: "Central European",
|
|
29
|
-
es: "Centroeuropeo"
|
|
30
|
-
}
|
|
31
|
-
},
|
|
32
|
-
chineseSimplified: {
|
|
33
|
-
id: "chineseSimplified",
|
|
34
|
-
label: {
|
|
35
|
-
en: "Chinese Simplified",
|
|
36
|
-
es: "Chino simplificado"
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
chineseTraditional: {
|
|
40
|
-
id: "chineseTraditional",
|
|
41
|
-
label: {
|
|
42
|
-
en: "Chinese Traditional",
|
|
43
|
-
es: "Chino tradicional"
|
|
44
|
-
}
|
|
45
|
-
},
|
|
46
|
-
cyrillic: {
|
|
47
|
-
id: "cyrillic",
|
|
48
|
-
label: {
|
|
49
|
-
en: "Cyrillic",
|
|
50
|
-
es: "Cirílico"
|
|
51
|
-
}
|
|
52
|
-
},
|
|
53
|
-
greek: {
|
|
54
|
-
id: "greek",
|
|
55
|
-
label: {
|
|
56
|
-
en: "Greek",
|
|
57
|
-
es: "Griego"
|
|
58
|
-
}
|
|
59
|
-
},
|
|
60
|
-
hebrew: {
|
|
61
|
-
id: "hebrew",
|
|
62
|
-
label: {
|
|
63
|
-
en: "Hebrew",
|
|
64
|
-
es: "Hebreo"
|
|
65
|
-
}
|
|
66
|
-
},
|
|
67
|
-
japanese: {
|
|
68
|
-
id: "japanese",
|
|
69
|
-
label: {
|
|
70
|
-
en: "Japanese",
|
|
71
|
-
es: "Japonés"
|
|
72
|
-
}
|
|
73
|
-
},
|
|
74
|
-
korean: {
|
|
75
|
-
id: "korean",
|
|
76
|
-
label: {
|
|
77
|
-
en: "Korean",
|
|
78
|
-
es: "Coreano"
|
|
79
|
-
}
|
|
80
|
-
},
|
|
81
|
-
nordic: {
|
|
82
|
-
id: "nordic",
|
|
83
|
-
label: {
|
|
84
|
-
en: "Nordic",
|
|
85
|
-
es: "Nórdico"
|
|
86
|
-
}
|
|
87
|
-
},
|
|
88
|
-
other: {
|
|
89
|
-
id: "other",
|
|
90
|
-
label: {
|
|
91
|
-
en: "Other",
|
|
92
|
-
es: "Otro"
|
|
93
|
-
}
|
|
94
|
-
},
|
|
95
|
-
romanian: {
|
|
96
|
-
id: "romanian",
|
|
97
|
-
label: {
|
|
98
|
-
en: "Romanian",
|
|
99
|
-
es: "Rumano"
|
|
100
|
-
}
|
|
101
|
-
},
|
|
102
|
-
southernEuropean: {
|
|
103
|
-
id: "southernEuropean",
|
|
104
|
-
label: {
|
|
105
|
-
en: "Southern European",
|
|
106
|
-
es: "Europeo meridional"
|
|
107
|
-
}
|
|
108
|
-
},
|
|
109
|
-
thai: {
|
|
110
|
-
id: "thai",
|
|
111
|
-
label: {
|
|
112
|
-
en: "Thai",
|
|
113
|
-
es: "Tailandés"
|
|
114
|
-
}
|
|
115
|
-
},
|
|
116
|
-
turkish: {
|
|
117
|
-
id: "turkish",
|
|
118
|
-
label: {
|
|
119
|
-
en: "Turkish",
|
|
120
|
-
es: "Turco"
|
|
121
|
-
}
|
|
122
|
-
},
|
|
123
|
-
unicode16: {
|
|
124
|
-
id: "unicode16",
|
|
125
|
-
label: {
|
|
126
|
-
en: "Unicode 16",
|
|
127
|
-
es: "Unicode 16"
|
|
128
|
-
}
|
|
129
|
-
},
|
|
130
|
-
unicode32: {
|
|
131
|
-
id: "unicode32",
|
|
132
|
-
label: {
|
|
133
|
-
en: "Unicode 32",
|
|
134
|
-
es: "Unicode 32"
|
|
135
|
-
}
|
|
136
|
-
},
|
|
137
|
-
vietnamese: {
|
|
138
|
-
id: "vietnamese",
|
|
139
|
-
label: {
|
|
140
|
-
en: "Vietnamese",
|
|
141
|
-
es: "Vietnamita"
|
|
142
|
-
}
|
|
143
|
-
},
|
|
144
|
-
western: {
|
|
145
|
-
id: "western",
|
|
146
|
-
label: {
|
|
147
|
-
en: "Western",
|
|
148
|
-
es: "Occidental"
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
|
-
}, t = {
|
|
152
|
-
ascii: {
|
|
153
|
-
id: "ascii",
|
|
154
|
-
groupId: null,
|
|
155
|
-
isDetectable: !1,
|
|
156
|
-
isDecodable: !0
|
|
157
|
-
},
|
|
158
|
-
big5: {
|
|
159
|
-
id: "big5",
|
|
160
|
-
groupId: "chineseTraditional",
|
|
161
|
-
isDetectable: !0,
|
|
162
|
-
isDecodable: !0
|
|
163
|
-
},
|
|
164
|
-
"euc-jp": {
|
|
165
|
-
id: "euc-jp",
|
|
166
|
-
groupId: "japanese",
|
|
167
|
-
isDetectable: !0,
|
|
168
|
-
isDecodable: !0
|
|
169
|
-
},
|
|
170
|
-
"euc-kr": {
|
|
171
|
-
id: "euc-kr",
|
|
172
|
-
groupId: "korean",
|
|
173
|
-
isDetectable: !0,
|
|
174
|
-
isDecodable: !0
|
|
175
|
-
},
|
|
176
|
-
gb18030: {
|
|
177
|
-
id: "gb18030",
|
|
178
|
-
groupId: "chineseSimplified",
|
|
179
|
-
isDetectable: !0,
|
|
180
|
-
isDecodable: !0
|
|
181
|
-
},
|
|
182
|
-
gbk: {
|
|
183
|
-
id: "gbk",
|
|
184
|
-
groupId: "chineseSimplified",
|
|
185
|
-
isDetectable: !1,
|
|
186
|
-
isDecodable: !0
|
|
187
|
-
},
|
|
188
|
-
ibm866: {
|
|
189
|
-
id: "ibm866",
|
|
190
|
-
groupId: "cyrillic",
|
|
191
|
-
isDetectable: !1,
|
|
192
|
-
isDecodable: !0
|
|
193
|
-
},
|
|
194
|
-
"iso-2022-cn": {
|
|
195
|
-
id: "iso-2022-cn",
|
|
196
|
-
groupId: "chineseSimplified",
|
|
197
|
-
isDetectable: !0,
|
|
198
|
-
isDecodable: !1
|
|
199
|
-
},
|
|
200
|
-
"iso-2022-jp": {
|
|
201
|
-
id: "iso-2022-jp",
|
|
202
|
-
groupId: "japanese",
|
|
203
|
-
isDetectable: !0,
|
|
204
|
-
isDecodable: !0
|
|
205
|
-
},
|
|
206
|
-
"iso-2022-kr": {
|
|
207
|
-
id: "iso-2022-kr",
|
|
208
|
-
groupId: "korean",
|
|
209
|
-
isDetectable: !0,
|
|
210
|
-
isDecodable: !1
|
|
211
|
-
},
|
|
212
|
-
"iso-8859-1": {
|
|
213
|
-
id: "iso-8859-1",
|
|
214
|
-
groupId: "western",
|
|
215
|
-
isDetectable: !0,
|
|
216
|
-
isDecodable: !0
|
|
217
|
-
},
|
|
218
|
-
"iso-8859-2": {
|
|
219
|
-
id: "iso-8859-2",
|
|
220
|
-
groupId: "centralEuropean",
|
|
221
|
-
isDetectable: !0,
|
|
222
|
-
isDecodable: !0
|
|
223
|
-
},
|
|
224
|
-
"iso-8859-3": {
|
|
225
|
-
id: "iso-8859-3",
|
|
226
|
-
groupId: "southernEuropean",
|
|
227
|
-
isDetectable: !1,
|
|
228
|
-
isDecodable: !0
|
|
229
|
-
},
|
|
230
|
-
"iso-8859-4": {
|
|
231
|
-
id: "iso-8859-4",
|
|
232
|
-
groupId: "baltic",
|
|
233
|
-
isDetectable: !1,
|
|
234
|
-
isDecodable: !0
|
|
235
|
-
},
|
|
236
|
-
"iso-8859-5": {
|
|
237
|
-
id: "iso-8859-5",
|
|
238
|
-
groupId: "cyrillic",
|
|
239
|
-
isDetectable: !0,
|
|
240
|
-
isDecodable: !0
|
|
241
|
-
},
|
|
242
|
-
"iso-8859-6": {
|
|
243
|
-
id: "iso-8859-6",
|
|
244
|
-
groupId: "arabic",
|
|
245
|
-
isDetectable: !0,
|
|
246
|
-
isDecodable: !0
|
|
247
|
-
},
|
|
248
|
-
"iso-8859-7": {
|
|
249
|
-
id: "iso-8859-7",
|
|
250
|
-
groupId: "greek",
|
|
251
|
-
isDetectable: !0,
|
|
252
|
-
isDecodable: !0
|
|
253
|
-
},
|
|
254
|
-
"iso-8859-8": {
|
|
255
|
-
id: "iso-8859-8",
|
|
256
|
-
groupId: "hebrew",
|
|
257
|
-
isDetectable: !0,
|
|
258
|
-
isDecodable: !0
|
|
259
|
-
},
|
|
260
|
-
"iso-8859-9": {
|
|
261
|
-
id: "iso-8859-9",
|
|
262
|
-
groupId: "turkish",
|
|
263
|
-
isDetectable: !0,
|
|
264
|
-
isDecodable: !0
|
|
265
|
-
},
|
|
266
|
-
"iso-8859-10": {
|
|
267
|
-
id: "iso-8859-10",
|
|
268
|
-
groupId: "nordic",
|
|
269
|
-
isDetectable: !1,
|
|
270
|
-
isDecodable: !0
|
|
271
|
-
},
|
|
272
|
-
"iso-8859-11": {
|
|
273
|
-
id: "iso-8859-11",
|
|
274
|
-
groupId: "thai",
|
|
275
|
-
isDetectable: !1,
|
|
276
|
-
isDecodable: !0
|
|
277
|
-
},
|
|
278
|
-
"iso-8859-13": {
|
|
279
|
-
id: "iso-8859-13",
|
|
280
|
-
groupId: "baltic",
|
|
281
|
-
isDetectable: !1,
|
|
282
|
-
isDecodable: !0
|
|
283
|
-
},
|
|
284
|
-
"iso-8859-14": {
|
|
285
|
-
id: "iso-8859-14",
|
|
286
|
-
groupId: "celtic",
|
|
287
|
-
isDetectable: !1,
|
|
288
|
-
isDecodable: !0
|
|
289
|
-
},
|
|
290
|
-
"iso-8859-15": {
|
|
291
|
-
id: "iso-8859-15",
|
|
292
|
-
groupId: "western",
|
|
293
|
-
isDetectable: !1,
|
|
294
|
-
isDecodable: !0
|
|
295
|
-
},
|
|
296
|
-
"iso-8859-16": {
|
|
297
|
-
id: "iso-8859-16",
|
|
298
|
-
groupId: "romanian",
|
|
299
|
-
isDetectable: !1,
|
|
300
|
-
isDecodable: !0
|
|
301
|
-
},
|
|
302
|
-
"koi8-r": {
|
|
303
|
-
id: "koi8-r",
|
|
304
|
-
groupId: "cyrillic",
|
|
305
|
-
isDetectable: !0,
|
|
306
|
-
isDecodable: !0
|
|
307
|
-
},
|
|
308
|
-
"koi8-u": {
|
|
309
|
-
id: "koi8-u",
|
|
310
|
-
groupId: "cyrillic",
|
|
311
|
-
isDetectable: !1,
|
|
312
|
-
isDecodable: !0
|
|
313
|
-
},
|
|
314
|
-
latin1: {
|
|
315
|
-
id: "latin1",
|
|
316
|
-
groupId: "western",
|
|
317
|
-
isDetectable: !1,
|
|
318
|
-
isDecodable: !0
|
|
319
|
-
},
|
|
320
|
-
macintosh: {
|
|
321
|
-
id: "macintosh",
|
|
322
|
-
groupId: "western",
|
|
323
|
-
isDetectable: !1,
|
|
324
|
-
isDecodable: !0
|
|
325
|
-
},
|
|
326
|
-
shift_jis: {
|
|
327
|
-
id: "shift_jis",
|
|
328
|
-
groupId: "japanese",
|
|
329
|
-
isDetectable: !0,
|
|
330
|
-
isDecodable: !0
|
|
331
|
-
},
|
|
332
|
-
"tis-620": {
|
|
333
|
-
id: "tis-620",
|
|
334
|
-
groupId: "thai",
|
|
335
|
-
isDetectable: !1,
|
|
336
|
-
isDecodable: !0
|
|
337
|
-
},
|
|
338
|
-
"utf-16": {
|
|
339
|
-
id: "utf-16",
|
|
340
|
-
groupId: "unicode16",
|
|
341
|
-
isDetectable: !1,
|
|
342
|
-
isDecodable: !0
|
|
343
|
-
},
|
|
344
|
-
"utf-16be": {
|
|
345
|
-
id: "utf-16be",
|
|
346
|
-
groupId: "unicode16",
|
|
347
|
-
isDetectable: !0,
|
|
348
|
-
isDecodable: !0
|
|
349
|
-
},
|
|
350
|
-
"utf-16le": {
|
|
351
|
-
id: "utf-16le",
|
|
352
|
-
groupId: "unicode16",
|
|
353
|
-
isDetectable: !0,
|
|
354
|
-
isDecodable: !0
|
|
355
|
-
},
|
|
356
|
-
"utf-32be": {
|
|
357
|
-
id: "utf-32be",
|
|
358
|
-
groupId: "unicode32",
|
|
359
|
-
isDetectable: !0,
|
|
360
|
-
isDecodable: !1
|
|
361
|
-
},
|
|
362
|
-
"utf-32le": {
|
|
363
|
-
id: "utf-32le",
|
|
364
|
-
groupId: "unicode32",
|
|
365
|
-
isDetectable: !0,
|
|
366
|
-
isDecodable: !1
|
|
367
|
-
},
|
|
368
|
-
"utf-8": {
|
|
369
|
-
id: "utf-8",
|
|
370
|
-
groupId: null,
|
|
371
|
-
isDetectable: !0,
|
|
372
|
-
isDecodable: !0
|
|
373
|
-
},
|
|
374
|
-
"windows-1250": {
|
|
375
|
-
id: "windows-1250",
|
|
376
|
-
groupId: "centralEuropean",
|
|
377
|
-
isDetectable: !0,
|
|
378
|
-
isDecodable: !0
|
|
379
|
-
},
|
|
380
|
-
"windows-1251": {
|
|
381
|
-
id: "windows-1251",
|
|
382
|
-
groupId: "cyrillic",
|
|
383
|
-
isDetectable: !0,
|
|
384
|
-
isDecodable: !0
|
|
385
|
-
},
|
|
386
|
-
"windows-1252": {
|
|
387
|
-
id: "windows-1252",
|
|
388
|
-
groupId: "western",
|
|
389
|
-
isDetectable: !0,
|
|
390
|
-
isDecodable: !0
|
|
391
|
-
},
|
|
392
|
-
"windows-1253": {
|
|
393
|
-
id: "windows-1253",
|
|
394
|
-
groupId: "greek",
|
|
395
|
-
isDetectable: !0,
|
|
396
|
-
isDecodable: !0
|
|
397
|
-
},
|
|
398
|
-
"windows-1254": {
|
|
399
|
-
id: "windows-1254",
|
|
400
|
-
groupId: "turkish",
|
|
401
|
-
isDetectable: !0,
|
|
402
|
-
isDecodable: !0
|
|
403
|
-
},
|
|
404
|
-
"windows-1255": {
|
|
405
|
-
id: "windows-1255",
|
|
406
|
-
groupId: "hebrew",
|
|
407
|
-
isDetectable: !0,
|
|
408
|
-
isDecodable: !0
|
|
409
|
-
},
|
|
410
|
-
"windows-1256": {
|
|
411
|
-
id: "windows-1256",
|
|
412
|
-
groupId: "arabic",
|
|
413
|
-
isDetectable: !0,
|
|
414
|
-
isDecodable: !0
|
|
415
|
-
},
|
|
416
|
-
"windows-1257": {
|
|
417
|
-
id: "windows-1257",
|
|
418
|
-
groupId: "baltic",
|
|
419
|
-
isDetectable: !1,
|
|
420
|
-
isDecodable: !0
|
|
421
|
-
},
|
|
422
|
-
"windows-1258": {
|
|
423
|
-
id: "windows-1258",
|
|
424
|
-
groupId: "vietnamese",
|
|
425
|
-
isDetectable: !1,
|
|
426
|
-
isDecodable: !0
|
|
427
|
-
},
|
|
428
|
-
"windows-874": {
|
|
429
|
-
id: "windows-874",
|
|
430
|
-
groupId: "thai",
|
|
431
|
-
isDetectable: !1,
|
|
432
|
-
isDecodable: !0
|
|
433
|
-
},
|
|
434
|
-
"x-mac-cyrillic": {
|
|
435
|
-
id: "x-mac-cyrillic",
|
|
436
|
-
groupId: "cyrillic",
|
|
437
|
-
isDetectable: !1,
|
|
438
|
-
isDecodable: !0
|
|
439
|
-
},
|
|
440
|
-
"x-user-defined": {
|
|
441
|
-
id: "x-user-defined",
|
|
442
|
-
groupId: "other",
|
|
443
|
-
isDetectable: !1,
|
|
444
|
-
isDecodable: !0
|
|
445
|
-
}
|
|
446
|
-
}, n = e, r = t;
|
|
447
|
-
function i(e) {
|
|
448
|
-
return Object.hasOwn(r, e);
|
|
449
|
-
}
|
|
450
|
-
function a(e = "en") {
|
|
451
|
-
return Array.from(Object.values(r), ({ groupId: t, id: n, isDecodable: r, isDetectable: i }) => {
|
|
452
|
-
let a = t == null ? "" : o(t, e);
|
|
453
|
-
return {
|
|
454
|
-
id: n,
|
|
455
|
-
groupLabel: a,
|
|
456
|
-
label: a ? `${a} (${n})` : n,
|
|
457
|
-
isDetectable: i,
|
|
458
|
-
isDecodable: r
|
|
459
|
-
};
|
|
460
|
-
}).toSorted((t, n) => t.groupLabel.localeCompare(n.groupLabel, e) || t.label.localeCompare(n.label, e));
|
|
461
|
-
}
|
|
462
|
-
function o(e, t) {
|
|
463
|
-
let r = n[e].label;
|
|
464
|
-
return r[t] ?? r.en ?? e;
|
|
465
|
-
}
|
|
466
|
-
//#endregion
|
|
467
|
-
export { n as ENCODING_GROUP_CONFIG_MAP, r as ENCODING_TYPE_CONFIG_MAP, a as getEncodingTypeConfigs, i as isEncodingTypeId };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"dpuse-shared-encoding.es.js","names":[],"sources":["../src/encoding/index.ts"],"sourcesContent":["// ── DPUse Framework\nimport { DEFAULT_LOCALE_ID, type LocaleId, type LocaleLabel } from '@/locale/label';\n\n// ── Types ────────────────────────────────────────────────────────────────────────────────────────────────────────────\n\ntype EncodingGroupId = keyof typeof ENCODING_GROUP_CONFIG_DATA;\ntype EncodingTypeId = keyof typeof ENCODING_TYPE_CONFIG_DATA;\n\ninterface EncodingGroupConfig {\n id: EncodingGroupId;\n label: LocaleLabel;\n}\n\ninterface EncodingTypeConfig {\n id: EncodingTypeId;\n groupId: EncodingGroupId | null; // Null for encodings that belong to no group, e.g. 'ascii' and 'utf-8'.\n isDetectable: boolean;\n isDecodable: boolean;\n}\nexport interface EncodingTypeConfigLocalised {\n id: EncodingTypeId;\n groupLabel: string;\n label: string;\n isDetectable: boolean;\n isDecodable: boolean;\n}\n\nexport interface EncodingDetectionConfig {\n id: EncodingTypeId;\n confidenceLevel: number | undefined;\n}\n\n// ── Constants ────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nconst ENCODING_GROUP_CONFIG_DATA = {\n arabic: { id: 'arabic', label: { en: 'Arabic', es: 'Árabe' } },\n baltic: { id: 'baltic', label: { en: 'Baltic', es: 'Báltico' } },\n celtic: { id: 'celtic', label: { en: 'Celtic', es: 'Celta' } },\n centralEuropean: { id: 'centralEuropean', label: { en: 'Central European', es: 'Centroeuropeo' } },\n chineseSimplified: { id: 'chineseSimplified', label: { en: 'Chinese Simplified', es: 'Chino simplificado' } },\n chineseTraditional: { id: 'chineseTraditional', label: { en: 'Chinese Traditional', es: 'Chino tradicional' } },\n cyrillic: { id: 'cyrillic', label: { en: 'Cyrillic', es: 'Cirílico' } },\n greek: { id: 'greek', label: { en: 'Greek', es: 'Griego' } },\n hebrew: { id: 'hebrew', label: { en: 'Hebrew', es: 'Hebreo' } },\n japanese: { id: 'japanese', label: { en: 'Japanese', es: 'Japonés' } },\n korean: { id: 'korean', label: { en: 'Korean', es: 'Coreano' } },\n nordic: { id: 'nordic', label: { en: 'Nordic', es: 'Nórdico' } },\n other: { id: 'other', label: { en: 'Other', es: 'Otro' } },\n romanian: { id: 'romanian', label: { en: 'Romanian', es: 'Rumano' } },\n southernEuropean: { id: 'southernEuropean', label: { en: 'Southern European', es: 'Europeo meridional' } },\n thai: { id: 'thai', label: { en: 'Thai', es: 'Tailandés' } },\n turkish: { id: 'turkish', label: { en: 'Turkish', es: 'Turco' } },\n unicode16: { id: 'unicode16', label: { en: 'Unicode 16', es: 'Unicode 16' } },\n unicode32: { id: 'unicode32', label: { en: 'Unicode 32', es: 'Unicode 32' } },\n vietnamese: { id: 'vietnamese', label: { en: 'Vietnamese', es: 'Vietnamita' } },\n western: { id: 'western', label: { en: 'Western', es: 'Occidental' } }\n} as const satisfies Record<string, { id: string; label: LocaleLabel }>;\n\nconst ENCODING_TYPE_CONFIG_DATA = {\n ascii: { id: 'ascii', groupId: null, isDetectable: false, isDecodable: true },\n big5: { id: 'big5', groupId: 'chineseTraditional', isDetectable: true, isDecodable: true },\n 'euc-jp': { id: 'euc-jp', groupId: 'japanese', isDetectable: true, isDecodable: true },\n 'euc-kr': { id: 'euc-kr', groupId: 'korean', isDetectable: true, isDecodable: true },\n gb18030: { id: 'gb18030', groupId: 'chineseSimplified', isDetectable: true, isDecodable: true },\n gbk: { id: 'gbk', groupId: 'chineseSimplified', isDetectable: false, isDecodable: true },\n ibm866: { id: 'ibm866', groupId: 'cyrillic', isDetectable: false, isDecodable: true },\n 'iso-2022-cn': { id: 'iso-2022-cn', groupId: 'chineseSimplified', isDetectable: true, isDecodable: false },\n 'iso-2022-jp': { id: 'iso-2022-jp', groupId: 'japanese', isDetectable: true, isDecodable: true },\n 'iso-2022-kr': { id: 'iso-2022-kr', groupId: 'korean', isDetectable: true, isDecodable: false },\n 'iso-8859-1': { id: 'iso-8859-1', groupId: 'western', isDetectable: true, isDecodable: true },\n 'iso-8859-2': { id: 'iso-8859-2', groupId: 'centralEuropean', isDetectable: true, isDecodable: true },\n 'iso-8859-3': { id: 'iso-8859-3', groupId: 'southernEuropean', isDetectable: false, isDecodable: true },\n 'iso-8859-4': { id: 'iso-8859-4', groupId: 'baltic', isDetectable: false, isDecodable: true },\n 'iso-8859-5': { id: 'iso-8859-5', groupId: 'cyrillic', isDetectable: true, isDecodable: true },\n 'iso-8859-6': { id: 'iso-8859-6', groupId: 'arabic', isDetectable: true, isDecodable: true },\n 'iso-8859-7': { id: 'iso-8859-7', groupId: 'greek', isDetectable: true, isDecodable: true },\n 'iso-8859-8': { id: 'iso-8859-8', groupId: 'hebrew', isDetectable: true, isDecodable: true },\n 'iso-8859-9': { id: 'iso-8859-9', groupId: 'turkish', isDetectable: true, isDecodable: true },\n 'iso-8859-10': { id: 'iso-8859-10', groupId: 'nordic', isDetectable: false, isDecodable: true },\n 'iso-8859-11': { id: 'iso-8859-11', groupId: 'thai', isDetectable: false, isDecodable: true },\n 'iso-8859-13': { id: 'iso-8859-13', groupId: 'baltic', isDetectable: false, isDecodable: true },\n 'iso-8859-14': { id: 'iso-8859-14', groupId: 'celtic', isDetectable: false, isDecodable: true },\n 'iso-8859-15': { id: 'iso-8859-15', groupId: 'western', isDetectable: false, isDecodable: true },\n 'iso-8859-16': { id: 'iso-8859-16', groupId: 'romanian', isDetectable: false, isDecodable: true },\n 'koi8-r': { id: 'koi8-r', groupId: 'cyrillic', isDetectable: true, isDecodable: true },\n 'koi8-u': { id: 'koi8-u', groupId: 'cyrillic', isDetectable: false, isDecodable: true },\n latin1: { id: 'latin1', groupId: 'western', isDetectable: false, isDecodable: true },\n macintosh: { id: 'macintosh', groupId: 'western', isDetectable: false, isDecodable: true },\n shift_jis: { id: 'shift_jis', groupId: 'japanese', isDetectable: true, isDecodable: true },\n 'tis-620': { id: 'tis-620', groupId: 'thai', isDetectable: false, isDecodable: true },\n 'utf-16': { id: 'utf-16', groupId: 'unicode16', isDetectable: false, isDecodable: true },\n 'utf-16be': { id: 'utf-16be', groupId: 'unicode16', isDetectable: true, isDecodable: true },\n 'utf-16le': { id: 'utf-16le', groupId: 'unicode16', isDetectable: true, isDecodable: true },\n 'utf-32be': { id: 'utf-32be', groupId: 'unicode32', isDetectable: true, isDecodable: false },\n 'utf-32le': { id: 'utf-32le', groupId: 'unicode32', isDetectable: true, isDecodable: false },\n 'utf-8': { id: 'utf-8', groupId: null, isDetectable: true, isDecodable: true },\n 'windows-1250': { id: 'windows-1250', groupId: 'centralEuropean', isDetectable: true, isDecodable: true },\n 'windows-1251': { id: 'windows-1251', groupId: 'cyrillic', isDetectable: true, isDecodable: true },\n 'windows-1252': { id: 'windows-1252', groupId: 'western', isDetectable: true, isDecodable: true },\n 'windows-1253': { id: 'windows-1253', groupId: 'greek', isDetectable: true, isDecodable: true },\n 'windows-1254': { id: 'windows-1254', groupId: 'turkish', isDetectable: true, isDecodable: true },\n 'windows-1255': { id: 'windows-1255', groupId: 'hebrew', isDetectable: true, isDecodable: true },\n 'windows-1256': { id: 'windows-1256', groupId: 'arabic', isDetectable: true, isDecodable: true },\n 'windows-1257': { id: 'windows-1257', groupId: 'baltic', isDetectable: false, isDecodable: true },\n 'windows-1258': { id: 'windows-1258', groupId: 'vietnamese', isDetectable: false, isDecodable: true },\n 'windows-874': { id: 'windows-874', groupId: 'thai', isDetectable: false, isDecodable: true },\n 'x-mac-cyrillic': { id: 'x-mac-cyrillic', groupId: 'cyrillic', isDetectable: false, isDecodable: true },\n 'x-user-defined': { id: 'x-user-defined', groupId: 'other', isDetectable: false, isDecodable: true }\n} as const satisfies Record<string, { id: string; groupId: keyof typeof ENCODING_GROUP_CONFIG_DATA | null; isDetectable: boolean; isDecodable: boolean }>;\n\nexport const ENCODING_GROUP_CONFIG_MAP = ENCODING_GROUP_CONFIG_DATA as Record<EncodingGroupId, EncodingGroupConfig>;\nexport const ENCODING_TYPE_CONFIG_MAP = ENCODING_TYPE_CONFIG_DATA as Record<EncodingTypeId, EncodingTypeConfig>;\n\n// ── Actions ──────────────────────────────────────────────────────────────────────────────────────────────────────────\n\n// Narrows a name from outside the app, such as one reported by encoding detection, to a known encoding id. Check with\n// this once where the name arrives, so everything after it works with 'EncodingTypeId'.\nexport function isEncodingTypeId(value: string): value is EncodingTypeId {\n return Object.hasOwn(ENCODING_TYPE_CONFIG_MAP, value);\n}\n\nexport function getEncodingTypeConfigs(localeId: LocaleId = DEFAULT_LOCALE_ID): EncodingTypeConfigLocalised[] {\n const encodingTypeConfigs: EncodingTypeConfigLocalised[] = Array.from(Object.values(ENCODING_TYPE_CONFIG_MAP), ({ groupId, id, isDecodable, isDetectable }) => {\n const groupLabel = groupId == null ? '' : resolveGroupLabel(groupId, localeId);\n return { id, groupLabel, label: groupLabel ? `${groupLabel} (${id})` : id, isDetectable, isDecodable };\n });\n return encodingTypeConfigs.toSorted((left, right) => left.groupLabel.localeCompare(right.groupLabel, localeId) || left.label.localeCompare(right.label, localeId));\n}\n\n// ── Helpers ──────────────────────────────────────────────────────────────────────────────────────────────────────────\n\nfunction resolveGroupLabel(groupId: EncodingGroupId, localeId: LocaleId): string {\n const labels = ENCODING_GROUP_CONFIG_MAP[groupId].label;\n return labels[localeId] ?? labels[DEFAULT_LOCALE_ID] ?? groupId;\n}\n"],"mappings":";;AAkCA,IAAM,IAA6B;CAC/B,QAAQ;EAAE,IAAI;EAAU,OAAO;GAAE,IAAI;GAAU,IAAI;EAAQ;CAAE;CAC7D,QAAQ;EAAE,IAAI;EAAU,OAAO;GAAE,IAAI;GAAU,IAAI;EAAU;CAAE;CAC/D,QAAQ;EAAE,IAAI;EAAU,OAAO;GAAE,IAAI;GAAU,IAAI;EAAQ;CAAE;CAC7D,iBAAiB;EAAE,IAAI;EAAmB,OAAO;GAAE,IAAI;GAAoB,IAAI;EAAgB;CAAE;CACjG,mBAAmB;EAAE,IAAI;EAAqB,OAAO;GAAE,IAAI;GAAsB,IAAI;EAAqB;CAAE;CAC5G,oBAAoB;EAAE,IAAI;EAAsB,OAAO;GAAE,IAAI;GAAuB,IAAI;EAAoB;CAAE;CAC9G,UAAU;EAAE,IAAI;EAAY,OAAO;GAAE,IAAI;GAAY,IAAI;EAAW;CAAE;CACtE,OAAO;EAAE,IAAI;EAAS,OAAO;GAAE,IAAI;GAAS,IAAI;EAAS;CAAE;CAC3D,QAAQ;EAAE,IAAI;EAAU,OAAO;GAAE,IAAI;GAAU,IAAI;EAAS;CAAE;CAC9D,UAAU;EAAE,IAAI;EAAY,OAAO;GAAE,IAAI;GAAY,IAAI;EAAU;CAAE;CACrE,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secret|token/i, r = [
|
|
3
|
-
[/\b(Bearer|Basic) +[\w.~+/=-]+/gi, (e, n) => `${n} ${t}`],
|
|
4
|
-
[/(?<![\w-])([\w-]+)(["']?[ \t]*[:=][ \t]*["']?)([^\s"'&,;}?#]+)/g, (e, r, i, a) => n.test(r) && !/^(?:Basic|Bearer)$/i.test(a) ? `${r}${i}${t}` : e],
|
|
5
|
-
[/\beyJ[\w-]+\.[\w-]+\.[\w-]*/g, () => t],
|
|
6
|
-
[/\b(?:sk-|xaat-|xapt-|sl\.)[\w-]{16,}/g, () => t],
|
|
7
|
-
[/(?<![\w.+-])[\w.+-]+@[\w-]+\.[\w.-]+/g, () => t]
|
|
8
|
-
], i = class extends Error {
|
|
9
|
-
data;
|
|
10
|
-
locator;
|
|
11
|
-
constructor(e, t, n, r) {
|
|
12
|
-
super(e, r), this.name = "DPUseError", this.data = n, this.locator = t;
|
|
13
|
-
}
|
|
14
|
-
}, a = class extends i {
|
|
15
|
-
constructor(e, t, n, r) {
|
|
16
|
-
super(e, t, n, r), this.name = "AppError";
|
|
17
|
-
}
|
|
18
|
-
}, o = class extends i {
|
|
19
|
-
constructor(e, t, n, r) {
|
|
20
|
-
super(e, t, n, r), this.name = "APIError";
|
|
21
|
-
}
|
|
22
|
-
}, s = class extends i {
|
|
23
|
-
constructor(e, t, n, r) {
|
|
24
|
-
super(e, t, n, r), this.name = "EngineError";
|
|
25
|
-
}
|
|
26
|
-
}, c = class extends i {
|
|
27
|
-
constructor(e, t, n, r) {
|
|
28
|
-
super(e, t, n, r), this.name = "ConnectorError";
|
|
29
|
-
}
|
|
30
|
-
}, l = class extends i {
|
|
31
|
-
constructor(e, t, n, r) {
|
|
32
|
-
super(e, t, n, r), this.name = "FetchError";
|
|
33
|
-
}
|
|
34
|
-
};
|
|
35
|
-
async function u(e, t, n) {
|
|
36
|
-
let r = ` - ${e.statusText}`, i = `${t} Response status '${String(e.status)}${e.statusText ? r : ""}' received.`, a;
|
|
37
|
-
try {
|
|
38
|
-
a = await e.text();
|
|
39
|
-
} catch (e) {
|
|
40
|
-
a = `<body unavailable: ${p(e).message}>`;
|
|
41
|
-
}
|
|
42
|
-
return new l(i, n, { body: x(a) });
|
|
43
|
-
}
|
|
44
|
-
function d(e) {
|
|
45
|
-
return e.map((e) => e.message).join(" ");
|
|
46
|
-
}
|
|
47
|
-
function f(e) {
|
|
48
|
-
try {
|
|
49
|
-
e();
|
|
50
|
-
} catch {}
|
|
51
|
-
}
|
|
52
|
-
function p(e) {
|
|
53
|
-
if (e instanceof Error) return e;
|
|
54
|
-
if (typeof e == "string") return Error(e);
|
|
55
|
-
if (typeof e == "number" || typeof e == "boolean" || typeof e == "bigint") return Error(String(e));
|
|
56
|
-
if (typeof e == "symbol") return Error(e.description ?? "Unknown error");
|
|
57
|
-
if (typeof e == "object") try {
|
|
58
|
-
return Error(JSON.stringify(e));
|
|
59
|
-
} catch {
|
|
60
|
-
return /* @__PURE__ */ Error("Unknown error");
|
|
61
|
-
}
|
|
62
|
-
return /* @__PURE__ */ Error("Unknown error");
|
|
63
|
-
}
|
|
64
|
-
function m(e) {
|
|
65
|
-
let t = /* @__PURE__ */ new Set(), n = [], r = p(e);
|
|
66
|
-
for (; r != null && !t.has(r);) {
|
|
67
|
-
t.add(r);
|
|
68
|
-
let [e, i] = S(r);
|
|
69
|
-
/(?:\.{3}|[.!?])$/.test(e.message) || (e.message += "."), n.push(v(e)), r = i;
|
|
70
|
-
}
|
|
71
|
-
return n;
|
|
72
|
-
}
|
|
73
|
-
function h(e) {
|
|
74
|
-
let t;
|
|
75
|
-
for (let n of e.toReversed()) {
|
|
76
|
-
let e = _(n, t);
|
|
77
|
-
n.stack !== void 0 && (e.stack = n.stack), t = e;
|
|
78
|
-
}
|
|
79
|
-
return t ?? /* @__PURE__ */ Error("No error to unserialise.");
|
|
80
|
-
}
|
|
81
|
-
function g(e) {
|
|
82
|
-
let t;
|
|
83
|
-
try {
|
|
84
|
-
t = JSON.stringify(e);
|
|
85
|
-
} catch {
|
|
86
|
-
t = typeof e == "symbol" ? e.description ?? "Unknown error" : typeof e == "bigint" ? e.toString() : "Unknown error";
|
|
87
|
-
}
|
|
88
|
-
return t === "" && (t = "Unknown error"), t;
|
|
89
|
-
}
|
|
90
|
-
function _(e, t) {
|
|
91
|
-
switch (e.name) {
|
|
92
|
-
case "APIError": return new o(e.message, e.locator, e.data, { cause: t });
|
|
93
|
-
case "AppError": return new a(e.message, e.locator, e.data, { cause: t });
|
|
94
|
-
case "ConnectorError": return new c(e.message, e.locator, e.data, { cause: t });
|
|
95
|
-
case "EngineError": return new s(e.message, e.locator, e.data, { cause: t });
|
|
96
|
-
case "FetchError": return new l(e.message, e.locator, e.data, { cause: t });
|
|
97
|
-
default: {
|
|
98
|
-
let n = e.name;
|
|
99
|
-
return new class extends Error {
|
|
100
|
-
name = n;
|
|
101
|
-
}(e.message, { cause: t });
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
function v(e) {
|
|
106
|
-
let { data: t, message: n, stack: r } = e;
|
|
107
|
-
return {
|
|
108
|
-
...e,
|
|
109
|
-
data: t === void 0 ? void 0 : b(t, /* @__PURE__ */ new WeakSet(), 0),
|
|
110
|
-
message: y(n),
|
|
111
|
-
stack: r === void 0 ? void 0 : y(r)
|
|
112
|
-
};
|
|
113
|
-
}
|
|
114
|
-
function y(e) {
|
|
115
|
-
let t = e;
|
|
116
|
-
for (let [e, n] of r) t = t.replaceAll(e, (e, ...t) => n(e, ...t));
|
|
117
|
-
return t;
|
|
118
|
-
}
|
|
119
|
-
function b(e, r, i) {
|
|
120
|
-
return typeof e == "string" ? y(e) : typeof e != "object" || !e ? e : i >= 10 ? t : r.has(e) ? "[Circular]" : (r.add(e), Array.isArray(e) ? e.map((e) => b(e, r, i + 1)) : Object.fromEntries(Object.entries(e).map(([e, a]) => [e, a != null && n.test(e) ? t : b(a, r, i + 1)])));
|
|
121
|
-
}
|
|
122
|
-
function x(t) {
|
|
123
|
-
if (t != null && t !== "") return t.length > e ? `${t.slice(0, e)}... [truncated]` : t;
|
|
124
|
-
}
|
|
125
|
-
function S(e) {
|
|
126
|
-
let t = e.cause == null ? null : p(e.cause);
|
|
127
|
-
if (e instanceof i) return [{
|
|
128
|
-
data: e.data,
|
|
129
|
-
locator: e.locator,
|
|
130
|
-
message: e.message,
|
|
131
|
-
name: e.name,
|
|
132
|
-
stack: e.stack
|
|
133
|
-
}, t];
|
|
134
|
-
let n = Object.fromEntries(Object.entries(e).filter(([e]) => e !== "cause"));
|
|
135
|
-
return e.name ? [{
|
|
136
|
-
data: n,
|
|
137
|
-
locator: "",
|
|
138
|
-
message: e.message,
|
|
139
|
-
name: e.name,
|
|
140
|
-
stack: e.stack
|
|
141
|
-
}, t] : [{
|
|
142
|
-
data: n,
|
|
143
|
-
locator: "",
|
|
144
|
-
message: g(e),
|
|
145
|
-
name: "Error",
|
|
146
|
-
stack: void 0
|
|
147
|
-
}, null];
|
|
148
|
-
}
|
|
149
|
-
//#endregion
|
|
150
|
-
export { o as APIError, a as AppError, c as ConnectorError, s as EngineError, l as FetchError, u as buildFetchError, d as concatenateSerialisedErrorMessages, f as ignoreErrors, p as normalizeToError, m as serialiseError, h as unserialiseError };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"dpuse-shared-errors.es.js","names":[],"sources":["../src/errors/index.ts"],"sourcesContent":["// ── Types ────────────────────────────────────────────────────────────────────────────────────────────────────────────\n\n// Serializable representation of an error; used for transporting errors across api and worker boundaries\nexport interface SerialisedError {\n data: Record<string, unknown> | undefined;\n locator: string; // Error locator 'package.module.method'\n message: string; // Human-readable error message\n name: string; // Error class or type name\n stack: string | undefined; // Stack trace if available\n}\n\n// ── Constants ───────────────────────────────────────────────────────────────────────────────────────────────────────\n\nconst RESPONSE_ERROR_BODY_LIMIT = 2048;\n\n// Redaction — serialised errors are shown in the browser and stored in Axiom, so secrets and email addresses are masked\n// first. Best effort: it catches the common shapes, not every possible secret.\nconst REDACTED = '[REDACTED]';\nconst REDACTION_MAX_DEPTH = 10; // Deeper 'data' is replaced whole rather than walked.\nconst SECRET_KEY_PATTERN = /api[-_]?key|authori[sz]ation|cookie|credential|passw(?:or)?d|private[-_]?key|secret|token/i; // A 'data' field whose name matches has its whole value masked.\n// Each pattern is anchored to the start of a word, so it runs in linear time even over a long response body.\nconst SECRET_TEXT_PATTERNS: [RegExp, (match: string, ...groups: string[]) => string][] = [\n [/\\b(Bearer|Basic) +[\\w.~+/=-]+/gi, (_match, scheme) => `${scheme} ${REDACTED}`], // Authorisation header values.\n // Any 'name: value' or 'name=value' pair, in JSON, query strings, form bodies or headers; masked when the name looks\n // secret. A bare 'Basic' or 'Bearer' value is the scheme left by the pattern above, whose token is already masked.\n [\n /(?<![\\w-])([\\w-]+)([\"']?[ \\t]*[:=][ \\t]*[\"']?)([^\\s\"'&,;}?#]+)/g,\n (match, name, separator, value) => (SECRET_KEY_PATTERN.test(name) && !/^(?:Basic|Bearer)$/i.test(value) ? `${name}${separator}${REDACTED}` : match)\n ],\n [/\\beyJ[\\w-]+\\.[\\w-]+\\.[\\w-]*/g, () => REDACTED], // JSON web tokens.\n [/\\b(?:sk-|xaat-|xapt-|sl\\.)[\\w-]{16,}/g, () => REDACTED], // Known token prefixes: OpenAI, Anthropic, Axiom, Dropbox.\n [/(?<![\\w.+-])[\\w.+-]+@[\\w-]+\\.[\\w.-]+/g, () => REDACTED] // Email addresses.\n];\n\n// ── Errors ───────────────────────────────────────────────────────────────────────────────────────────────────────────\n\n// Base class for all DPUse errors; includes a locator for the error; never thrown directly\nclass DPUseError extends Error {\n readonly data: Record<string, unknown> | undefined;\n readonly locator: string; // Error locator 'package.module.method'\n constructor(message: string, locator: string, data?: Record<string, unknown>, options?: ErrorOptions) {\n super(message, options);\n this.name = 'DPUseError';\n this.data = data;\n this.locator = locator;\n }\n}\n\n// Thrown when an app (studio/assistant) error occurs\nexport class AppError extends DPUseError {\n constructor(message: string, locator: string, data?: Record<string, unknown>, options?: ErrorOptions) {\n super(message, locator, data, options);\n this.name = 'AppError';\n }\n}\n\n// Thrown when an API request fails\nexport class APIError extends DPUseError {\n constructor(message: string, locator: string, data?: Record<string, unknown>, options?: ErrorOptions) {\n super(message, locator, data, options);\n this.name = 'APIError';\n }\n}\n\n// Thrown when an engine request fails\nexport class EngineError extends DPUseError {\n constructor(message: string, locator: string, data?: Record<string, unknown>, options?: ErrorOptions) {\n super(message, locator, data, options);\n this.name = 'EngineError';\n }\n}\n\n// Thrown when an connector operation fails; will always be wrapped in an engine error\nexport class ConnectorError extends DPUseError {\n constructor(message: string, locator: string, data?: Record<string, unknown>, options?: ErrorOptions) {\n super(message, locator, data, options);\n this.name = 'ConnectorError';\n }\n}\n\n// Thrown when an HTTP request fails; may include a sanitized portion of the response body for diagnostic purposes\nexport class FetchError extends DPUseError {\n constructor(message: string, locator: string, data?: Record<string, unknown>, options?: ErrorOptions) {\n super(message, locator, data, options);\n this.name = 'FetchError';\n }\n}\n\n// ── Actions ──────────────────────────────────────────────────────────────────────────────────────────────────────────\n\n// Builds a fetch error from an HTTP response; includes a text copy of the response body\nexport async function buildFetchError(response: { status: number; statusText: string; text: () => Promise<string> }, message: string, locator: string): Promise<FetchError> {\n const responseStatusStuff = ` - ${response.statusText}`;\n const fetchMessage = `${message} Response status '${String(response.status)}${response.statusText ? responseStatusStuff : ''}' received.`;\n let bodyText: string;\n try {\n bodyText = await response.text();\n } catch (error) {\n const normalised = normalizeToError(error);\n bodyText = `<body unavailable: ${normalised.message}>`;\n }\n return new FetchError(fetchMessage, locator, { body: sanitizeResponseErrorBody(bodyText) });\n}\n\n// Concatenates serialized error messages into a single string\nexport function concatenateSerialisedErrorMessages(serialisedErrors: SerialisedError[]): string {\n return serialisedErrors.map((serialisedError) => serialisedError.message).join(' ');\n}\n\n// Ignore best-effort cleanup errors to keep teardown noise-free\nexport function ignoreErrors(action: () => void): void {\n try {\n action();\n } catch {\n // Intentionally ignore errors\n }\n}\n\n// Normalizes an unknown thrown value into an error\nexport function normalizeToError(value: unknown): Error {\n if (value instanceof Error) return value;\n if (typeof value === 'string') return new Error(value);\n if (typeof value === 'number' || typeof value === 'boolean' || typeof value === 'bigint') return new Error(String(value));\n if (typeof value === 'symbol') return new Error(value.description ?? 'Unknown error');\n if (typeof value === 'object') {\n try {\n return new Error(JSON.stringify(value));\n } catch {\n return new Error('Unknown error');\n }\n }\n return new Error('Unknown error');\n}\n\n// Serializes an error and its cause chain into a array of serialised error objects;\n// errors are ordered from outermost to root cause;\n// cycles in the cause chain are safely ignored;\n// messages are normalized to end with punctuation;\n// secrets and email addresses in messages, stacks and data are redacted\nexport function serialiseError(error?: unknown): SerialisedError[] {\n const seenCauses = new Set();\n const serialisedErrors: SerialisedError[] = [];\n let cause: Error | null = normalizeToError(error);\n while (cause != null && !seenCauses.has(cause)) {\n seenCauses.add(cause);\n const [serialisedError, nextCause] = serialiseSingleError(cause);\n if (!/(?:\\.{3}|[.!?])$/.test(serialisedError.message)) serialisedError.message += '.';\n serialisedErrors.push(redactSerialisedError(serialisedError));\n cause = nextCause;\n }\n return serialisedErrors;\n}\n\n// Unserialises an array of serialised error objects back into an error with a cause chain;\n// reconstructs the appropriate error class based on serialized properties;\n// chains errors from outermost to root cause using the `cause` option;\n// returns a placeholder error if the input array is empty\nexport function unserialiseError(serialisedErrors: SerialisedError[]): Error {\n // Build the error chain from root cause (end) to outermost (start)\n let rebuiltError: Error | undefined;\n for (const serialised of serialisedErrors.toReversed()) {\n const error = reconstructError(serialised, rebuiltError);\n if (serialised.stack !== undefined) error.stack = serialised.stack; // Restore stack trace if available\n rebuiltError = error;\n }\n return rebuiltError ?? new Error('No error to unserialise.');\n}\n\n// ── Helpers ──────────────────────────────────────────────────────────────────────────────────────────────────────────\n\n// Builds a fallback message for non-error throwables\nfunction buildFallbackMessage(cause: unknown): string {\n let fallbackMessage: string;\n try {\n fallbackMessage = JSON.stringify(cause);\n } catch {\n if (typeof cause === 'symbol') fallbackMessage = cause.description ?? 'Unknown error';\n else if (typeof cause === 'bigint') fallbackMessage = cause.toString();\n else fallbackMessage = 'Unknown error';\n }\n if (fallbackMessage === '') fallbackMessage = 'Unknown error';\n return fallbackMessage;\n}\n\nfunction reconstructError(serialised: SerialisedError, cause: Error | undefined): Error {\n switch (serialised.name) {\n case 'APIError':\n return new APIError(serialised.message, serialised.locator, serialised.data, { cause });\n case 'AppError':\n return new AppError(serialised.message, serialised.locator, serialised.data, { cause });\n case 'ConnectorError':\n return new ConnectorError(serialised.message, serialised.locator, serialised.data, { cause });\n case 'EngineError':\n return new EngineError(serialised.message, serialised.locator, serialised.data, { cause });\n case 'FetchError':\n return new FetchError(serialised.message, serialised.locator, serialised.data, { cause });\n default: {\n const name = serialised.name;\n return new (class extends Error {\n override name = name;\n })(serialised.message, { cause });\n }\n }\n}\n\nfunction redactSerialisedError(serialisedError: SerialisedError): SerialisedError {\n const { data, message, stack } = serialisedError;\n return {\n ...serialisedError,\n data: data === undefined ? undefined : (redactValue(data, new WeakSet(), 0) as Record<string, unknown>),\n message: redactText(message),\n stack: stack === undefined ? undefined : redactText(stack)\n };\n}\n\nfunction redactText(text: string): string {\n let redactedText = text;\n for (const [pattern, replacement] of SECRET_TEXT_PATTERNS)\n redactedText = redactedText.replaceAll(pattern, (match: string, ...groups: string[]) => replacement(match, ...groups));\n return redactedText;\n}\n\n// Walks 'data', masking any field whose name looks secret and any secret found in text.\nfunction redactValue(value: unknown, seen: WeakSet<object>, depth: number): unknown {\n if (typeof value === 'string') return redactText(value);\n if (typeof value !== 'object' || value === null) return value;\n if (depth >= REDACTION_MAX_DEPTH) return REDACTED;\n if (seen.has(value)) return '[Circular]';\n seen.add(value);\n return Array.isArray(value)\n ? value.map((item) => redactValue(item, seen, depth + 1))\n : Object.fromEntries(\n Object.entries(value).map(([key, entryValue]) => [key, entryValue != null && SECRET_KEY_PATTERN.test(key) ? REDACTED : redactValue(entryValue, seen, depth + 1)])\n );\n}\n\n// Sanitizes a response body; limits body size to avoid excessive payloads when logging\nfunction sanitizeResponseErrorBody(body?: string): string | undefined {\n if (body == null || body === '') return undefined;\n return body.length > RESPONSE_ERROR_BODY_LIMIT ? `${body.slice(0, RESPONSE_ERROR_BODY_LIMIT)}... [truncated]` : body;\n}\n\nfunction serialiseSingleError(cause: Error): [SerialisedError, Error | null] {\n const nextCause = cause.cause == null ? null : normalizeToError(cause.cause);\n if (cause instanceof DPUseError) {\n return [{ data: cause.data, locator: cause.locator, message: cause.message, name: cause.name, stack: cause.stack }, nextCause];\n }\n const customProperties = Object.fromEntries(Object.entries(cause).filter(([k]) => k !== 'cause'));\n return cause.name\n ? [{ data: customProperties, locator: '', message: cause.message, name: cause.name, stack: cause.stack }, nextCause]\n : [{ data: customProperties, locator: '', message: buildFallbackMessage(cause), name: 'Error', stack: undefined }, null];\n}\n"],"mappings":";AAaA,IAAM,IAA4B,MAI5B,IAAW,cAEX,IAAqB,8FAErB,IAAmF;CACrF,CAAC,oCAAoC,GAAQ,MAAW,GAAG,EAAO,GAAG,GAAU;CAG/E,CACI,oEACC,GAAO,GAAM,GAAW,MAAW,EAAmB,KAAK,CAAI,KAAK,CAAC,sBAAsB,KAAK,CAAK,IAAI,GAAG,IAAO,IAAY,MAAa,CACjJ;CACA,CAAC,sCAAsC,CAAQ;CAC/C,CAAC,+CAA+C,CAAQ;CACxD,CAAC,+CAA+C,CAAQ;AAC5D,GAKM,IAAN,cAAyB,MAAM;CAC3B;CACA;CACA,YAAY,GAAiB,GAAiB,GAAgC,GAAwB;EAIlG,AAHA,MAAM,GAAS,CAAO,GACtB,KAAK,OAAO,cACZ,KAAK,OAAO,GACZ,KAAK,UAAU;CACnB;AACJ,GAGa,IAAb,cAA8B,EAAW;CACrC,YAAY,GAAiB,GAAiB,GAAgC,GAAwB;EAElG,AADA,MAAM,GAAS,GAAS,GAAM,CAAO,GACrC,KAAK,OAAO;CAChB;AACJ,GAGa,IAAb,cAA8B,EAAW;CACrC,YAAY,GAAiB,GAAiB,GAAgC,GAAwB;EAElG,AADA,MA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