fix(recursive-list): explicitly type restProps

This commit is contained in:
Eric Y Liu 2021-07-03 13:59:00 -07:00
commit 3428df49ce
3 changed files with 5 additions and 2 deletions

View file

@ -7898,7 +7898,7 @@
"ts": "interface RecursiveListNode { text?: string; href?: string; html?: string; }"
}
],
"rest_props": { "type": "InlineComponent", "name": "svelte:component" }
"rest_props": { "type": "Element", "name": "ul | ol" }
},
{
"moduleName": "Row",

View file

@ -1,6 +1,7 @@
<script>
/**
* @typedef {{ text?: string; href?: string; html?: string; }} RecursiveListNode
* @restProps {ul | ol}
*/
/**

View file

@ -7,7 +7,9 @@ export interface RecursiveListNode {
html?: string;
}
export interface RecursiveListProps {
export interface RecursiveListProps
extends svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["ul"]>,
svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["ol"]> {
/**
* Specify the children to render
* @default []