@datapos/datapos-tool-csv-parse 0.0.122 → 0.0.123
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.
|
@@ -3475,8 +3475,8 @@ class ni {
|
|
|
3475
3475
|
* Parse text.
|
|
3476
3476
|
*/
|
|
3477
3477
|
async parseText(e, r) {
|
|
3478
|
-
const n = ti(e), {
|
|
3479
|
-
return {
|
|
3478
|
+
const n = ti(e), { parsedRecords: i, valueDelimiterId: o } = await ri(e, r);
|
|
3479
|
+
return { parsedRecords: i, recordDelimiterId: n, valueDelimiterId: o };
|
|
3480
3480
|
}
|
|
3481
3481
|
}
|
|
3482
3482
|
function Kn(t) {
|
|
@@ -3546,7 +3546,7 @@ async function ri(t, e) {
|
|
|
3546
3546
|
});
|
|
3547
3547
|
} catch {
|
|
3548
3548
|
}
|
|
3549
|
-
return {
|
|
3549
|
+
return { parsedRecords: o, valueDelimiterId: r ?? "," };
|
|
3550
3550
|
}
|
|
3551
3551
|
export {
|
|
3552
3552
|
ni as Tool
|
|
@@ -5,11 +5,13 @@ import { RetrieveRecordsOptions, RetrieveRecordsSummary } from '@datapos/datapos
|
|
|
5
5
|
* Parse text configuration.
|
|
6
6
|
*/
|
|
7
7
|
interface ParseTextConfig {
|
|
8
|
-
|
|
8
|
+
parsedRecords: ParsingRecord[];
|
|
9
9
|
recordDelimiterId: RecordDelimiterId;
|
|
10
10
|
valueDelimiterId: ValueDelimiterId;
|
|
11
11
|
}
|
|
12
|
-
/**
|
|
12
|
+
/**
|
|
13
|
+
* Tool.
|
|
14
|
+
*/
|
|
13
15
|
declare class Tool {
|
|
14
16
|
/**
|
|
15
17
|
* Parse stream.
|