@datapos/datapos-shared 0.3.430 → 0.3.432
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.
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
const
|
|
2
|
-
ascii:
|
|
3
|
-
big5:
|
|
1
|
+
const a = { id: "ascii", groupLabel: "", label: "ascii", isDetectable: !1, isDecodable: !0 }, s = { id: "big5", groupLabel: "Chinese Traditional", label: "Chinese Traditional (big5)", isDetectable: !0, isDecodable: !0 }, o = { id: "gb18030", groupLabel: "Chinese Simplified", label: "Chinese Simplified (gb18030)", isDetectable: !0, isDecodable: !0 }, t = { id: "gbk", groupLabel: "Chinese Simplified", label: "Chinese Simplified (gbk)", isDetectable: !1, isDecodable: !0 }, b = { id: "ibm866", groupLabel: "Cyrillic", label: "Cyrillic (ibm866)", isDetectable: !1, isDecodable: !0 }, r = { id: "latin1", groupLabel: "Western", label: "Western (latin1)", isDetectable: !1, isDecodable: !0 }, c = { id: "macintosh", groupLabel: "Western", label: "Western (macintosh)", isDetectable: !1, isDecodable: !0 }, u = { id: "shift_jis", groupLabel: "Japanese", label: "Japanese (shift_jis)", isDetectable: !0, isDecodable: !0 }, d = { id: "utf16", groupLabel: "Unicode 16", label: "Unicode 16 (utf16)", isDetectable: !1, isDecodable: !0 }, n = { id: "utf16be", groupLabel: "Unicode 16", label: "Unicode 16 (utf16be)", isDetectable: !0, isDecodable: !0 }, D = { id: "utf16le", groupLabel: "Unicode 16", label: "Unicode 16 (utf16le)", isDetectable: !0, isDecodable: !0 }, p = { id: "utf32be", groupLabel: "Unicode 32", label: "Unicode 32 (utf32be)", isDetectable: !0, isDecodable: !1 }, g = { id: "utf32le", groupLabel: "Unicode 32", label: "Unicode 32 (utf32le)", isDetectable: !0, isDecodable: !1 }, w = { id: "utf8", groupLabel: "", label: "utf8", isDetectable: !0, isDecodable: !0 }, f = {
|
|
2
|
+
ascii: a,
|
|
3
|
+
big5: s,
|
|
4
4
|
"euc-jp": { id: "euc-jp", groupLabel: "Japanese", label: "Japanese (euc-jp)", isDetectable: !0, isDecodable: !0 },
|
|
5
5
|
"euc-kr": { id: "euc-kr", groupLabel: "Korean", label: "Korean (euc-kr)", isDetectable: !0, isDecodable: !0 },
|
|
6
|
-
gb18030:
|
|
7
|
-
gbk:
|
|
8
|
-
ibm866:
|
|
6
|
+
gb18030: o,
|
|
7
|
+
gbk: t,
|
|
8
|
+
ibm866: b,
|
|
9
9
|
"iso-2022-cn": { id: "iso-2022-cn", groupLabel: "Japanese", label: "Japanese (iso-2022-cn)", isDetectable: !0, isDecodable: !1 },
|
|
10
10
|
"iso-2022-jp": { id: "iso-2022-jp", groupLabel: "Japanese", label: "Japanese (iso-2022-jp)", isDetectable: !0, isDecodable: !0 },
|
|
11
11
|
"iso-2022-kr": { id: "iso-2022-kr", groupLabel: "Korean", label: "Korean (iso-2022-kr)", isDetectable: !0, isDecodable: !1 },
|
|
@@ -26,16 +26,16 @@ const s = { id: "ascii", groupLabel: "", label: "ascii", isDetectable: !1, isDec
|
|
|
26
26
|
"iso-8859-16": { id: "iso-8859-16", groupLabel: "Romanian", label: "Romanian (iso-8859-16)", isDetectable: !1, isDecodable: !0 },
|
|
27
27
|
"kOi8-r": { id: "koi8-r", groupLabel: "Cyrillic", label: "Cyrillic (koi8-r)", isDetectable: !0, isDecodable: !0 },
|
|
28
28
|
"kOi8-u": { id: "koi8-u", groupLabel: "Cyrillic", label: "Cyrillic (koi8-u)", isDetectable: !1, isDecodable: !0 },
|
|
29
|
-
latin1:
|
|
30
|
-
macintosh:
|
|
31
|
-
shift_jis:
|
|
29
|
+
latin1: r,
|
|
30
|
+
macintosh: c,
|
|
31
|
+
shift_jis: u,
|
|
32
32
|
"tis-620": { id: "tis-620", groupLabel: "Thai", label: "Thai (tis-620)", isDetectable: !1, isDecodable: !0 },
|
|
33
|
-
utf16:
|
|
34
|
-
utf16be:
|
|
35
|
-
utf16le:
|
|
36
|
-
utf32be:
|
|
37
|
-
utf32le:
|
|
38
|
-
utf8:
|
|
33
|
+
utf16: d,
|
|
34
|
+
utf16be: n,
|
|
35
|
+
utf16le: D,
|
|
36
|
+
utf32be: p,
|
|
37
|
+
utf32le: g,
|
|
38
|
+
utf8: w,
|
|
39
39
|
"windows-1250": { id: "windows-1250", groupLabel: "Central European", label: "Central European (windows-1250)", isDetectable: !0, isDecodable: !0 },
|
|
40
40
|
"windows-1251": { id: "windows-1251", groupLabel: "Cyrillic", label: "Cyrillic (windows-1251)", isDetectable: !0, isDecodable: !0 },
|
|
41
41
|
"windows-1252": { id: "windows-1252", groupLabel: "Western", label: "Western (windows-1252)", isDetectable: !0, isDecodable: !0 },
|
|
@@ -48,14 +48,14 @@ const s = { id: "ascii", groupLabel: "", label: "ascii", isDetectable: !1, isDec
|
|
|
48
48
|
"windows-874": { id: "windows-874", groupLabel: "Thai", label: "Thai (windows-874)", isDetectable: !1, isDecodable: !0 },
|
|
49
49
|
"x-mac-cyrillic": { id: "x-mac-cyrillic", groupLabel: "Cyrillic", label: "Cyrillic (x-mac-cyrillic)", isDetectable: !1, isDecodable: !0 },
|
|
50
50
|
"x-user-defined": { id: "x-user-defined", groupLabel: "Other", label: "Other (x-user-defined)", isDetectable: !1, isDecodable: !0 }
|
|
51
|
-
};
|
|
51
|
+
}, L = f;
|
|
52
52
|
function h(C = "en") {
|
|
53
|
-
const i = []
|
|
54
|
-
for (const [, e] of Object.entries(
|
|
55
|
-
|
|
53
|
+
const i = [];
|
|
54
|
+
for (const [, e] of Object.entries(L))
|
|
55
|
+
i.push({ ...e, label: e.label || e.id });
|
|
56
56
|
return i.toSorted((e, l) => e.groupLabel.localeCompare(l.groupLabel) || e.label.localeCompare(l.label));
|
|
57
57
|
}
|
|
58
58
|
export {
|
|
59
|
-
L as
|
|
59
|
+
L as encodingConfigMap,
|
|
60
60
|
h as getEncodingConfigs
|
|
61
61
|
};
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Encoding.
|
|
3
3
|
*/
|
|
4
|
-
/**
|
|
5
|
-
|
|
4
|
+
/**
|
|
5
|
+
* Encoding configuration.
|
|
6
|
+
*/
|
|
7
|
+
interface EncodingConfig {
|
|
6
8
|
id: string;
|
|
7
9
|
confidenceLevel: number | undefined;
|
|
8
10
|
}
|
|
@@ -16,9 +18,9 @@ interface EncodingTypeConfig {
|
|
|
16
18
|
isDetectable: boolean;
|
|
17
19
|
isDecodable: boolean;
|
|
18
20
|
}
|
|
21
|
+
declare const encodingConfigMap: Record<string, EncodingTypeConfig>;
|
|
19
22
|
/**
|
|
20
23
|
* Get encoding configurations.
|
|
21
24
|
*/
|
|
22
25
|
declare function getEncodingConfigs(localeId?: string): EncodingTypeConfig[];
|
|
23
|
-
export {
|
|
24
|
-
export { type Encoding, type EncodingTypeConfig, getEncodingConfigs };
|
|
26
|
+
export { type EncodingConfig, encodingConfigMap, type EncodingTypeConfig, getEncodingConfigs };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { ConnectionConfig } from '../component/connector/connection';
|
|
2
|
+
import { ConnectorOperationOptions } from '../component/connector';
|
|
2
3
|
import { EncodingTypeConfig } from '../encoding';
|
|
3
4
|
import { ModuleConfig } from '../component/module';
|
|
4
5
|
import { ToolConfig } from '../component/tool';
|
|
5
|
-
import { ConnectorOperationOptions } from '../component/connector';
|
|
6
6
|
import { ContextCallbackData, ContextConfig, ContextOperationOptions } from '../component/context';
|
|
7
7
|
import { DataViewContentAuditConfig, DataViewPreviewConfig, ValueDelimiterId } from '../component/dataView';
|
|
8
8
|
/** Engine runtime interface. */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@datapos/datapos-shared",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.432",
|
|
4
4
|
"description": "A library containing common constants, types and utilities used across all Data Positioning projects.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Jonathan Terrell <terrell.jm@gmail.com>",
|