RowModel Types
aliyss opened this issue Β· comments
Hi! π
Firstly, thanks for your work on this project! π
In my opinion the types I'm using seem to be working.
I'm not sure about the id. Afaik it can be a string too.
label is defined in the README but missing in the interface.
height works fine without providing it. So I will assume it's optional.
Aliyss
Here is the diff that solved my problem:
diff --git a/node_modules/svelte-gantt/types/core/row.d.ts b/node_modules/svelte-gantt/types/core/row.d.ts
index a2469e2..5e65ca3 100644
--- a/node_modules/svelte-gantt/types/core/row.d.ts
+++ b/node_modules/svelte-gantt/types/core/row.d.ts
@@ -1,9 +1,10 @@
export interface RowModel {
- id: number;
+ id: number | string;
+ label: string;
classes?: string | string[];
contentHtml?: string;
enableDragging?: boolean;
- height: number;
+ height?: number;
/** Child rows in expandable tree */
children?: RowModel[];
/** Content of row header, html string */
Basically your issue is a pull request ? π I'll look into it and integrate it asap