ado-sync 0.1.22 → 0.1.24
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 +7 -9
- package/dist/parsers/excel.d.ts +16 -16
- package/dist/parsers/excel.js +132 -58
- package/dist/parsers/excel.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -17,7 +17,7 @@ Local files ado-sync Azure DevOps
|
|
|
17
17
|
.csv files ── push ──► (push-only)
|
|
18
18
|
.xlsx files ── push ──► (push-only)
|
|
19
19
|
write ID back
|
|
20
|
-
@tc:12345 /
|
|
20
|
+
@tc:12345 / col A (csv/xlsx)
|
|
21
21
|
```
|
|
22
22
|
|
|
23
23
|
On the **first push** of a scenario, a new Test Case is created in Azure DevOps and its ID is written back into the local file as a tag or comment. Every subsequent push uses that ID to update the existing Test Case. Pulling fetches the latest title and steps from Azure and overwrites the local file.
|
|
@@ -334,7 +334,7 @@ After a scenario is pushed for the first time, ado-sync writes the Azure Test Ca
|
|
|
334
334
|
| Format | Writeback location |
|
|
335
335
|
|--------|--------------------|
|
|
336
336
|
| Gherkin | `@tc:12345` tag above the `Scenario:` line |
|
|
337
|
-
| Markdown |
|
|
337
|
+
| Markdown | `@tc:12345` tag after the `### heading` |
|
|
338
338
|
| CSV | Numeric ID in column A of the matching title row |
|
|
339
339
|
| Excel | Numeric ID in cell A of the matching title row |
|
|
340
340
|
|
|
@@ -368,11 +368,11 @@ For `Scenario Outline`, a **single** parametrized Test Case is created in Azure
|
|
|
368
368
|
|
|
369
369
|
### Markdown
|
|
370
370
|
|
|
371
|
-
The ID
|
|
371
|
+
The ID tag is inserted on the line immediately after the `### heading`:
|
|
372
372
|
|
|
373
373
|
```markdown
|
|
374
374
|
### 1. Login (happy path)
|
|
375
|
-
|
|
375
|
+
@tc:1042
|
|
376
376
|
|
|
377
377
|
Assumption: Fresh browser session.
|
|
378
378
|
|
|
@@ -388,8 +388,6 @@ Expected results:
|
|
|
388
388
|
---
|
|
389
389
|
```
|
|
390
390
|
|
|
391
|
-
The comment is invisible when the Markdown is rendered.
|
|
392
|
-
|
|
393
391
|
### Custom prefix
|
|
394
392
|
|
|
395
393
|
Change the `sync.tagPrefix` in your config to use a different prefix:
|
|
@@ -400,7 +398,7 @@ Change the `sync.tagPrefix` in your config to use a different prefix:
|
|
|
400
398
|
|
|
401
399
|
Result:
|
|
402
400
|
- Gherkin: `@azure:1042`
|
|
403
|
-
- Markdown:
|
|
401
|
+
- Markdown: `@azure:1042`
|
|
404
402
|
|
|
405
403
|
> **Warning:** Changing the prefix on an existing project means all existing ID tags will no longer be recognised. Do a project-wide find-and-replace on the old prefix before changing it.
|
|
406
404
|
|
|
@@ -449,7 +447,7 @@ Add a `<!-- tags: -->` HTML comment anywhere inside a scenario block to assign t
|
|
|
449
447
|
|
|
450
448
|
```markdown
|
|
451
449
|
### Login with valid credentials
|
|
452
|
-
|
|
450
|
+
@tc:1042
|
|
453
451
|
<!-- tags: @smoke, @regression -->
|
|
454
452
|
|
|
455
453
|
Steps:
|
|
@@ -644,7 +642,7 @@ Tags matching a configured `links` prefix are turned into Azure DevOps work item
|
|
|
644
642
|
|
|
645
643
|
```markdown
|
|
646
644
|
### User can add items to cart
|
|
647
|
-
|
|
645
|
+
@tc:1042
|
|
648
646
|
<!-- tags: @story:555, @bug:789 -->
|
|
649
647
|
```
|
|
650
648
|
|
package/dist/parsers/excel.d.ts
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Excel (.xlsx) test spec parser.
|
|
3
3
|
*
|
|
4
|
-
* Reads the Azure DevOps / SpecSync xlsx export format.
|
|
5
|
-
* by this toolchain use a custom non-standard structure (no shared strings,
|
|
6
|
-
* inline strings for rich-text step cells), so we parse the raw XML directly
|
|
7
|
-
* using JSZip (already a transitive dependency) instead of a heavyweight xlsx
|
|
8
|
-
* library that may not handle this format.
|
|
4
|
+
* Reads the Azure DevOps / SpecSync xlsx export format.
|
|
9
5
|
*
|
|
10
|
-
* Cell types
|
|
11
|
-
* t="
|
|
12
|
-
* t="
|
|
13
|
-
* t="
|
|
6
|
+
* Cell types handled:
|
|
7
|
+
* t="s" → shared string; <v> holds an index into xl/sharedStrings.xml
|
|
8
|
+
* t="str" → formula-result string in <v>
|
|
9
|
+
* t="n" / none → number in <v>
|
|
10
|
+
* t="inlineStr"→ rich text in <is><r><t>…</t></r></is>; concat all <t> runs
|
|
14
11
|
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
12
|
+
* Rows in xlsx are sparse — empty cells are omitted. We restore correct column
|
|
13
|
+
* positions using the cell reference attribute (r="C5" → col index 2).
|
|
14
|
+
*
|
|
15
|
+
* ID writeback rewrites the xlsx XML in place (updates or inserts the ID cell
|
|
16
|
+
* on the matching title row).
|
|
17
17
|
*/
|
|
18
18
|
import { LinkConfig, ParsedTest } from '../types';
|
|
19
19
|
export declare function parseExcelFile(filePath: string, tagPrefix: string, linkConfigs?: LinkConfig[]): Promise<ParsedTest[]>;
|
|
@@ -21,10 +21,10 @@ export declare function parseExcelFile(filePath: string, tagPrefix: string, link
|
|
|
21
21
|
* Write (or update) the TC ID in column A of the matching title row in an xlsx file.
|
|
22
22
|
*
|
|
23
23
|
* Strategy:
|
|
24
|
-
* 1. Load the xlsx zip.
|
|
25
|
-
* 2.
|
|
26
|
-
* 3.
|
|
27
|
-
*
|
|
28
|
-
*
|
|
24
|
+
* 1. Load the xlsx zip and shared strings.
|
|
25
|
+
* 2. Find the row where col C (Title) matches and col D (Test Step) is empty.
|
|
26
|
+
* 3. If col A cell exists, replace its value; if it's missing (sparse row),
|
|
27
|
+
* insert a new numeric cell at the start of the row.
|
|
28
|
+
* 4. Repack and write.
|
|
29
29
|
*/
|
|
30
30
|
export declare function writebackExcel(filePath: string, title: string, id: number): Promise<void>;
|
package/dist/parsers/excel.js
CHANGED
|
@@ -2,19 +2,19 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* Excel (.xlsx) test spec parser.
|
|
4
4
|
*
|
|
5
|
-
* Reads the Azure DevOps / SpecSync xlsx export format.
|
|
6
|
-
* by this toolchain use a custom non-standard structure (no shared strings,
|
|
7
|
-
* inline strings for rich-text step cells), so we parse the raw XML directly
|
|
8
|
-
* using JSZip (already a transitive dependency) instead of a heavyweight xlsx
|
|
9
|
-
* library that may not handle this format.
|
|
5
|
+
* Reads the Azure DevOps / SpecSync xlsx export format.
|
|
10
6
|
*
|
|
11
|
-
* Cell types
|
|
12
|
-
* t="
|
|
13
|
-
* t="
|
|
14
|
-
* t="
|
|
7
|
+
* Cell types handled:
|
|
8
|
+
* t="s" → shared string; <v> holds an index into xl/sharedStrings.xml
|
|
9
|
+
* t="str" → formula-result string in <v>
|
|
10
|
+
* t="n" / none → number in <v>
|
|
11
|
+
* t="inlineStr"→ rich text in <is><r><t>…</t></r></is>; concat all <t> runs
|
|
15
12
|
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
13
|
+
* Rows in xlsx are sparse — empty cells are omitted. We restore correct column
|
|
14
|
+
* positions using the cell reference attribute (r="C5" → col index 2).
|
|
15
|
+
*
|
|
16
|
+
* ID writeback rewrites the xlsx XML in place (updates or inserts the ID cell
|
|
17
|
+
* on the matching title row).
|
|
18
18
|
*/
|
|
19
19
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
20
20
|
if (k2 === undefined) k2 = k;
|
|
@@ -64,28 +64,73 @@ function detectNsPrefix(xml) {
|
|
|
64
64
|
const m = xml.match(/xmlns(?::(\w+))?="http:\/\/schemas\.openxmlformats\.org\/spreadsheetml\/2006\/main"/);
|
|
65
65
|
return m?.[1] ? `${m[1]}:` : '';
|
|
66
66
|
}
|
|
67
|
-
/**
|
|
68
|
-
function
|
|
69
|
-
|
|
67
|
+
/** Unescape XML entities. */
|
|
68
|
+
function unescapeXml(s) {
|
|
69
|
+
return s
|
|
70
|
+
.replace(/</g, '<')
|
|
71
|
+
.replace(/>/g, '>')
|
|
72
|
+
.replace(/&/g, '&')
|
|
73
|
+
.replace(/"/g, '"')
|
|
74
|
+
.replace(/'/g, "'");
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* Parse xl/sharedStrings.xml into a lookup array.
|
|
78
|
+
* Each <si> element is one entry; rich-text runs (<r><t>…</t></r>) are concatenated.
|
|
79
|
+
*/
|
|
80
|
+
function parseSharedStrings(xml) {
|
|
81
|
+
const strings = [];
|
|
82
|
+
const siRe = /<si[^>]*>([\s\S]*?)<\/si>/g;
|
|
83
|
+
let m;
|
|
84
|
+
while ((m = siRe.exec(xml)) !== null) {
|
|
85
|
+
const tRe = /<t[^>]*>([\s\S]*?)<\/t>/g;
|
|
86
|
+
const parts = [];
|
|
87
|
+
let tm;
|
|
88
|
+
while ((tm = tRe.exec(m[1])) !== null) {
|
|
89
|
+
parts.push(unescapeXml(tm[1]));
|
|
90
|
+
}
|
|
91
|
+
strings.push(parts.join(''));
|
|
92
|
+
}
|
|
93
|
+
return strings;
|
|
94
|
+
}
|
|
95
|
+
/** Convert column letter(s) to 0-based index: A→0, B→1, Z→25, AA→26. */
|
|
96
|
+
function colLetterToIndex(letters) {
|
|
97
|
+
let n = 0;
|
|
98
|
+
for (const ch of letters.toUpperCase()) {
|
|
99
|
+
n = n * 26 + (ch.charCodeAt(0) - 64);
|
|
100
|
+
}
|
|
101
|
+
return n - 1;
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* Extract the text value from a single <c> element, resolving shared strings.
|
|
105
|
+
* cellXml: the full <c …>…</c> XML string.
|
|
106
|
+
*/
|
|
107
|
+
function cellValue(cellXml, nsPrefix, sharedStrings) {
|
|
108
|
+
// inlineStr: <ns:is> containing <ns:r><ns:t>…</ns:t></ns:r> runs
|
|
70
109
|
const isMatch = cellXml.match(new RegExp(`<${nsPrefix}is>([\\s\\S]*?)<\\/${nsPrefix}is>`));
|
|
71
110
|
if (isMatch) {
|
|
72
111
|
const tRe = new RegExp(`<${nsPrefix}t[^>]*>([\\s\\S]*?)<\\/${nsPrefix}t>`, 'g');
|
|
73
112
|
const parts = [];
|
|
74
113
|
let m;
|
|
75
114
|
while ((m = tRe.exec(isMatch[1])) !== null) {
|
|
76
|
-
parts.push(m[1]
|
|
115
|
+
parts.push(unescapeXml(m[1]));
|
|
77
116
|
}
|
|
78
117
|
return parts.join('');
|
|
79
118
|
}
|
|
80
|
-
// plain value in <v>
|
|
81
119
|
const vMatch = cellXml.match(new RegExp(`<${nsPrefix}v>([\\s\\S]*?)<\\/${nsPrefix}v>`));
|
|
82
|
-
if (vMatch)
|
|
83
|
-
return
|
|
120
|
+
if (!vMatch)
|
|
121
|
+
return '';
|
|
122
|
+
// Shared string: t="s"
|
|
123
|
+
if (/\bt="s"/.test(cellXml)) {
|
|
124
|
+
const idx = parseInt(vMatch[1], 10);
|
|
125
|
+
return sharedStrings[idx] ?? '';
|
|
84
126
|
}
|
|
85
|
-
return
|
|
127
|
+
return unescapeXml(vMatch[1]);
|
|
86
128
|
}
|
|
87
|
-
/**
|
|
88
|
-
|
|
129
|
+
/**
|
|
130
|
+
* Parse all rows from the sheet XML into string[][] with correct column positions.
|
|
131
|
+
* Uses the cell reference attribute (r="C5") to fill sparse rows correctly.
|
|
132
|
+
*/
|
|
133
|
+
function parseSheetXml(xml, sharedStrings) {
|
|
89
134
|
const nsPrefix = detectNsPrefix(xml);
|
|
90
135
|
const rowRe = new RegExp(`<${nsPrefix}row([^>]*)>([\\s\\S]*?)<\\/${nsPrefix}row>`, 'g');
|
|
91
136
|
const cellRe = new RegExp(`<${nsPrefix}c([^>]*)>([\\s\\S]*?)<\\/${nsPrefix}c>`, 'g');
|
|
@@ -93,12 +138,25 @@ function parseSheetXml(xml) {
|
|
|
93
138
|
let rowMatch;
|
|
94
139
|
while ((rowMatch = rowRe.exec(xml)) !== null) {
|
|
95
140
|
const rowContent = rowMatch[2];
|
|
96
|
-
const
|
|
141
|
+
const cellData = [];
|
|
97
142
|
let cellMatch;
|
|
98
143
|
while ((cellMatch = cellRe.exec(rowContent)) !== null) {
|
|
99
|
-
|
|
144
|
+
const attrs = cellMatch[1];
|
|
145
|
+
// r="C5" → extract column letters "C"
|
|
146
|
+
const refMatch = attrs.match(/\br="([A-Z]+)\d+"/i);
|
|
147
|
+
const colIdx = refMatch ? colLetterToIndex(refMatch[1]) : cellData.length;
|
|
148
|
+
const value = cellValue(cellMatch[0], nsPrefix, sharedStrings);
|
|
149
|
+
cellData.push({ colIdx, value });
|
|
150
|
+
}
|
|
151
|
+
if (cellData.length === 0)
|
|
152
|
+
continue; // skip fully empty rows
|
|
153
|
+
// Build dense row array: fill gaps with empty strings
|
|
154
|
+
const maxColIdx = Math.max(...cellData.map((c) => c.colIdx));
|
|
155
|
+
const row = new Array(maxColIdx + 1).fill('');
|
|
156
|
+
for (const { colIdx, value } of cellData) {
|
|
157
|
+
row[colIdx] = value;
|
|
100
158
|
}
|
|
101
|
-
rows.push(
|
|
159
|
+
rows.push(row);
|
|
102
160
|
}
|
|
103
161
|
return rows;
|
|
104
162
|
}
|
|
@@ -106,18 +164,22 @@ function parseSheetXml(xml) {
|
|
|
106
164
|
async function parseExcelFile(filePath, tagPrefix, linkConfigs) {
|
|
107
165
|
const buffer = fs.readFileSync(filePath);
|
|
108
166
|
const zip = await jszip_1.default.loadAsync(buffer);
|
|
109
|
-
//
|
|
167
|
+
// Load shared strings table (present in most xlsx files)
|
|
168
|
+
const ssEntry = zip.file('xl/sharedStrings.xml');
|
|
169
|
+
const sharedStrings = ssEntry
|
|
170
|
+
? parseSharedStrings(await ssEntry.async('string'))
|
|
171
|
+
: [];
|
|
172
|
+
// Find the worksheet XML
|
|
110
173
|
const sheetEntry = zip.file('xl/worksheets/sheet.xml') ??
|
|
111
174
|
zip.file('xl/worksheets/sheet1.xml');
|
|
112
175
|
if (!sheetEntry)
|
|
113
176
|
throw new Error(`No worksheet found in ${filePath}`);
|
|
114
177
|
const xml = await sheetEntry.async('string');
|
|
115
|
-
// Strip BOM if present
|
|
116
178
|
const cleanXml = xml.startsWith('\uFEFF') ? xml.slice(1) : xml;
|
|
117
|
-
const rawRows = parseSheetXml(cleanXml);
|
|
179
|
+
const rawRows = parseSheetXml(cleanXml, sharedStrings);
|
|
118
180
|
const rows = rawRows.map((cells, idx) => ({
|
|
119
181
|
cells: cells.concat(Array(Math.max(0, 9 - cells.length)).fill('')),
|
|
120
|
-
rowIndex: idx + 1,
|
|
182
|
+
rowIndex: idx + 1,
|
|
121
183
|
}));
|
|
122
184
|
return (0, tabular_1.parseTabularRows)(rows, filePath, tagPrefix, linkConfigs);
|
|
123
185
|
}
|
|
@@ -126,11 +188,11 @@ async function parseExcelFile(filePath, tagPrefix, linkConfigs) {
|
|
|
126
188
|
* Write (or update) the TC ID in column A of the matching title row in an xlsx file.
|
|
127
189
|
*
|
|
128
190
|
* Strategy:
|
|
129
|
-
* 1. Load the xlsx zip.
|
|
130
|
-
* 2.
|
|
131
|
-
* 3.
|
|
132
|
-
*
|
|
133
|
-
*
|
|
191
|
+
* 1. Load the xlsx zip and shared strings.
|
|
192
|
+
* 2. Find the row where col C (Title) matches and col D (Test Step) is empty.
|
|
193
|
+
* 3. If col A cell exists, replace its value; if it's missing (sparse row),
|
|
194
|
+
* insert a new numeric cell at the start of the row.
|
|
195
|
+
* 4. Repack and write.
|
|
134
196
|
*/
|
|
135
197
|
async function writebackExcel(filePath, title, id) {
|
|
136
198
|
const buffer = fs.readFileSync(filePath);
|
|
@@ -140,6 +202,8 @@ async function writebackExcel(filePath, title, id) {
|
|
|
140
202
|
null;
|
|
141
203
|
if (!sheetKey)
|
|
142
204
|
throw new Error(`No worksheet found in ${filePath}`);
|
|
205
|
+
const ssEntry = zip.file('xl/sharedStrings.xml');
|
|
206
|
+
const sharedStrings = ssEntry ? parseSharedStrings(await ssEntry.async('string')) : [];
|
|
143
207
|
let xml = await zip.file(sheetKey).async('string');
|
|
144
208
|
const hasBom = xml.startsWith('\uFEFF');
|
|
145
209
|
if (hasBom)
|
|
@@ -147,38 +211,48 @@ async function writebackExcel(filePath, title, id) {
|
|
|
147
211
|
const nsPrefix = detectNsPrefix(xml);
|
|
148
212
|
const TITLE_STRIP_RE = /^(Scenario Outline|Scenario)\s*:\s*/i;
|
|
149
213
|
const normalise = (s) => s.replace(TITLE_STRIP_RE, '').trim();
|
|
150
|
-
|
|
151
|
-
const rowRe = new RegExp(`(<${nsPrefix}row[^>]*>)([\\s\\S]*?)(<\\/${nsPrefix}row>)`, 'g');
|
|
214
|
+
const rowRe = new RegExp(`(<${nsPrefix}row([^>]*)>)([\\s\\S]*?)(<\\/${nsPrefix}row>)`, 'g');
|
|
152
215
|
let updated = false;
|
|
153
|
-
const newXml = xml.replace(rowRe, (_full, open, content, close) => {
|
|
216
|
+
const newXml = xml.replace(rowRe, (_full, open, rowAttrs, content, close) => {
|
|
154
217
|
if (updated)
|
|
155
218
|
return open + content + close;
|
|
156
|
-
//
|
|
157
|
-
const
|
|
158
|
-
const
|
|
159
|
-
|
|
219
|
+
// Collect all cells with their column index
|
|
220
|
+
const cellMatches = [...content.matchAll(new RegExp(`(<${nsPrefix}c([^>]*)>)([\\s\\S]*?)(<\\/${nsPrefix}c>)`, 'g'))];
|
|
221
|
+
const getCellAtCol = (colLetter) => {
|
|
222
|
+
const targetIdx = colLetterToIndex(colLetter);
|
|
223
|
+
return cellMatches.find((m) => {
|
|
224
|
+
const refMatch = m[2].match(/\br="([A-Z]+)\d+"/i);
|
|
225
|
+
return refMatch ? colLetterToIndex(refMatch[1]) === targetIdx : false;
|
|
226
|
+
});
|
|
227
|
+
};
|
|
228
|
+
const titleMatch = getCellAtCol('C');
|
|
229
|
+
const stepMatch = getCellAtCol('D');
|
|
230
|
+
const idMatch = getCellAtCol('A');
|
|
231
|
+
const titleVal = titleMatch ? cellValue(titleMatch[0], nsPrefix, sharedStrings) : '';
|
|
232
|
+
const stepVal = stepMatch ? cellValue(stepMatch[0], nsPrefix, sharedStrings) : '';
|
|
233
|
+
const idVal = idMatch ? cellValue(idMatch[0], nsPrefix, sharedStrings) : '';
|
|
234
|
+
if (!titleVal || stepVal || idVal)
|
|
235
|
+
return open + content + close;
|
|
236
|
+
if (normalise(titleVal) !== title)
|
|
160
237
|
return open + content + close;
|
|
161
|
-
|
|
162
|
-
const
|
|
163
|
-
const
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
.replace(new RegExp(`(<${nsPrefix}c)([^>]*t="str")`), `$1 t="n"`)
|
|
170
|
-
.replace(new RegExp(`<${nsPrefix}v>[^<]*<\\/${nsPrefix}v>`), `<${nsPrefix}v>${id}</${nsPrefix}v>`);
|
|
171
|
-
const newContent = content.replace(firstCellFull, numericCell);
|
|
172
|
-
updated = true;
|
|
173
|
-
return open + newContent + close;
|
|
238
|
+
// Extract row number from the row's r attribute or first cell reference
|
|
239
|
+
const rowNumMatch = rowAttrs.match(/\br="(\d+)"/);
|
|
240
|
+
const rowNum = rowNumMatch ? rowNumMatch[1] : '1';
|
|
241
|
+
const numericCellXml = `<${nsPrefix}c r="A${rowNum}" t="n"><${nsPrefix}v>${id}</${nsPrefix}v></${nsPrefix}c>`;
|
|
242
|
+
let newContent;
|
|
243
|
+
if (idMatch) {
|
|
244
|
+
// Replace existing (empty) A cell
|
|
245
|
+
newContent = content.replace(idMatch[0], numericCellXml);
|
|
174
246
|
}
|
|
175
|
-
|
|
247
|
+
else {
|
|
248
|
+
// Insert new A cell at start of row content
|
|
249
|
+
newContent = numericCellXml + content;
|
|
250
|
+
}
|
|
251
|
+
updated = true;
|
|
252
|
+
return open + newContent + close;
|
|
176
253
|
});
|
|
177
254
|
zip.file(sheetKey, (hasBom ? '\uFEFF' : '') + newXml);
|
|
178
|
-
const outBuffer = await zip.generateAsync({
|
|
179
|
-
type: 'nodebuffer',
|
|
180
|
-
compression: 'DEFLATE',
|
|
181
|
-
});
|
|
255
|
+
const outBuffer = await zip.generateAsync({ type: 'nodebuffer', compression: 'DEFLATE' });
|
|
182
256
|
fs.writeFileSync(filePath, outBuffer);
|
|
183
257
|
}
|
|
184
258
|
//# sourceMappingURL=excel.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"excel.js","sourceRoot":"","sources":["../../src/parsers/excel.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;GAgBG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"excel.js","sourceRoot":"","sources":["../../src/parsers/excel.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;GAgBG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA8HH,wCAgCC;AAcD,wCA2EC;AArPD,uCAAyB;AACzB,kDAA0B;AAG1B,uCAAyD;AAEzD,iFAAiF;AAEjF,6EAA6E;AAC7E,SAAS,cAAc,CAAC,GAAW;IACjC,MAAM,CAAC,GAAG,GAAG,CAAC,KAAK,CAAC,qFAAqF,CAAC,CAAC;IAC3G,OAAO,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC;AAClC,CAAC;AAED,6BAA6B;AAC7B,SAAS,WAAW,CAAC,CAAS;IAC5B,OAAO,CAAC;SACL,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC;SACrB,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC;SACrB,OAAO,CAAC,QAAQ,EAAE,GAAG,CAAC;SACtB,OAAO,CAAC,SAAS,EAAE,GAAG,CAAC;SACvB,OAAO,CAAC,SAAS,EAAE,GAAG,CAAC,CAAC;AAC7B,CAAC;AAED;;;GAGG;AACH,SAAS,kBAAkB,CAAC,GAAW;IACrC,MAAM,OAAO,GAAa,EAAE,CAAC;IAC7B,MAAM,IAAI,GAAG,4BAA4B,CAAC;IAC1C,IAAI,CAAyB,CAAC;IAC9B,OAAO,CAAC,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC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