chore: run lint

This commit is contained in:
Eric Liu 2024-11-30 10:39:34 -08:00
commit 765ffc88eb
3 changed files with 23 additions and 20 deletions

View file

@ -3235,10 +3235,7 @@
"ts": "interface DataTableCell<\n Row = DataTableRow,\n> {\n key:\n | DataTableKey<Row>\n | (string & {});\n value: DataTableValue;\n display?: (\n item: DataTableValue,\n row: DataTableRow,\n ) => DataTableValue;\n}\n"
}
],
"generics": [
"Row",
"Row extends DataTableRow = DataTableRow"
],
"generics": ["Row", "Row extends DataTableRow = DataTableRow"],
"rest_props": {
"type": "Element",
"name": "div"
@ -18066,4 +18063,4 @@
}
}
]
}
}

View file

@ -39,10 +39,10 @@
$: source = `https://github.com/carbon-design-system/carbon-components-svelte/tree/master/${component.filePath}`;
$: forwarded_events = component.events.filter(
(event) => event.type === "forwarded"
(event) => event.type === "forwarded",
);
$: dispatched_events = component.events.filter(
(event) => event.type === "dispatched"
(event) => event.type === "dispatched",
);
</script>
@ -116,20 +116,20 @@
>
<svelte:component
this={AsyncPreviewTypeScript}
type="inline"
code={typeMap[type]}
/>
</div>
type="inline"
code={typeMap[type]}
/>
</div>
{:else}
<div
style="display: inline-flex; max-width: 220px; word-break: break-word;"
>
<svelte:component
this={AsyncPreviewTypeScript}
type="inline"
code={type}
/>
</div>
type="inline"
code={type}
/>
</div>
{/if}
</div>
{/each}
@ -145,10 +145,16 @@
</div>
{/each}
{/if}
<div style:margin-top="var(--cds-layout-02)" style:margin-bottom="var(--cds-spacing-03)">
<div
style:margin-top="var(--cds-layout-02)"
style:margin-bottom="var(--cds-spacing-03)"
>
<strong>Default value</strong>
</div>
<div style:margin-bottom="var(--cds-layout-01)" style:max-width="85%">
<div
style:margin-bottom="var(--cds-layout-01)"
style:max-width="85%"
>
{#if prop.value === undefined}
<em>undefined</em>
{:else}

View file

@ -5,11 +5,11 @@ import { format } from "prettier";
import plugin from "prettier/plugins/typescript";
const formatTypeScript = async (value) => {
return await format(value, {
parser: "typescript",
return await format(value, {
parser: "typescript",
plugins: [plugin],
printWidth: 40, // Force breaking onto new lines
bracketSameLine: false
bracketSameLine: false,
});
};