mirror of
https://github.com/Ellpeck/ObsidianSimpleTimeTracker.git
synced 2024-11-28 12:08:34 +01:00
fix: Change collapsed field from number to boolean
This commit is contained in:
parent
f308679bd2
commit
c587f83890
1 changed files with 2 additions and 2 deletions
|
@ -10,7 +10,7 @@ export interface Entry {
|
||||||
startTime: string;
|
startTime: string;
|
||||||
endTime: string;
|
endTime: string;
|
||||||
subEntries: Entry[];
|
subEntries: Entry[];
|
||||||
collapsed?: number;
|
collapsed?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function saveTracker(tracker: Tracker, app: App, fileName: string, section: MarkdownSectionInformation): Promise<void> {
|
export async function saveTracker(tracker: Tracker, app: App, fileName: string, section: MarkdownSectionInformation): Promise<void> {
|
||||||
|
@ -328,7 +328,7 @@ function addEditableTableRow(tracker: Tracker, entry: Entry, table: HTMLTableEle
|
||||||
if (entry.collapsed) {
|
if (entry.collapsed) {
|
||||||
delete entry.collapsed;
|
delete entry.collapsed;
|
||||||
} else {
|
} else {
|
||||||
entry.collapsed = 1;
|
entry.collapsed = true;
|
||||||
}
|
}
|
||||||
await saveTracker(tracker, this.app, getFile(), getSectionInfo());
|
await saveTracker(tracker, this.app, getFile(), getSectionInfo());
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue