Skip to content

Commit c6a1334

Browse files
committed
remove csv etc
1 parent 06ca7ae commit c6a1334

File tree

3 files changed

+1
-50
lines changed

3 files changed

+1
-50
lines changed

packages/compiler/src/md.ts

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -373,24 +373,6 @@ function groupMarkdown(group: ElementGroup, variables: Variable[], vegaScope: Ve
373373
addSpec('number', numberSpec, false);
374374
break;
375375
}
376-
case 'csv': {
377-
const { variableId, content } = element;
378-
const csvContent = Array.isArray(content) ? content.join('\n') : content;
379-
mdElements.push(tickWrap(`csv ${variableId}`, csvContent));
380-
break;
381-
}
382-
case 'tsv': {
383-
const { variableId, content } = element;
384-
const tsvContent = Array.isArray(content) ? content.join('\n') : content;
385-
mdElements.push(tickWrap(`tsv ${variableId}`, tsvContent));
386-
break;
387-
}
388-
case 'dsv': {
389-
const { variableId, delimiter, content } = element;
390-
const dsvContent = Array.isArray(content) ? content.join('\n') : content;
391-
mdElements.push(tickWrap(`dsv delimiter:${delimiter} ${variableId}`, dsvContent));
392-
break;
393-
}
394376
case 'json': {
395377
const { variableId, content } = element;
396378
const jsonContent = JSON.stringify(content, null, defaultJsonIndent);
@@ -407,7 +389,7 @@ function groupMarkdown(group: ElementGroup, variables: Variable[], vegaScope: Ve
407389
} else {
408390
yamlContent = yaml.dump(content, { indent: defaultJsonIndent });
409391
}
410-
mdElements.push(tickWrap(`yaml value ${variableId}`, trimTrailingNewline(yamlContent)));
392+
mdElements.push(tickWrap(`yaml ${variableId}`, trimTrailingNewline(yamlContent)));
411393
break;
412394
}
413395
default: {

packages/compiler/src/validate/element.ts

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -190,15 +190,6 @@ export async function validateElement(element: PageElement, groupIndex: number,
190190
errors.push(...validateInputElementWithVariableId(element));
191191
break;
192192
}
193-
case 'csv':
194-
case 'tsv':
195-
case 'dsv': {
196-
errors.push(...validateVariableID(element.variableId));
197-
if (element.type === 'dsv' && !element.delimiter) {
198-
errors.push('DSV element must have a delimiter property');
199-
}
200-
break;
201-
}
202193
case 'json':
203194
case 'yaml': {
204195
errors.push(...validateVariableID(element.variableId));

packages/schema-doc/src/inline-data.ts

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -4,25 +4,6 @@
44
*/
55
import { VariableID, ElementBase } from './common.js';
66

7-
export interface CsvElement extends ElementBase {
8-
type: 'csv';
9-
variableId: VariableID;
10-
content: string | string[] | string[][];
11-
}
12-
13-
export interface TsvElement extends ElementBase {
14-
type: 'tsv';
15-
variableId: VariableID;
16-
content: string | string[] | string[][];
17-
}
18-
19-
export interface DsvElement extends ElementBase {
20-
type: 'dsv';
21-
variableId: VariableID;
22-
delimiter: string;
23-
content: string | string[] | string[][];
24-
}
25-
267
export interface JsonValueElement extends ElementBase {
278
type: 'json';
289
variableId: VariableID;
@@ -36,8 +17,5 @@ export interface YamlValueElement extends ElementBase {
3617
}
3718

3819
export type InlineDataElement =
39-
| CsvElement
40-
| TsvElement
41-
| DsvElement
4220
| JsonValueElement
4321
| YamlValueElement;

0 commit comments

Comments
 (0)