consistency

This commit is contained in:
Ell 2022-09-28 14:11:49 +02:00
parent 90c6b55ad7
commit 29f9df9165
4 changed files with 12 additions and 12 deletions

View file

@ -106,7 +106,7 @@ export function displayTracker(tracker: Tracker, element: HTMLElement, getSectio
.setButtonText("Copy as table")
.onClick(() => navigator.clipboard.writeText(createMarkdownTable(tracker, settings)));
new ButtonComponent(buttons)
.setButtonText("Copy as csv")
.setButtonText("Copy as CSV")
.onClick(() => navigator.clipboard.writeText(createCsv(tracker, settings)));
}
@ -185,7 +185,7 @@ function createMarkdownTable(tracker: Tracker, settings: SimpleTimeTrackerSettin
function createCsv(tracker: Tracker, settings: SimpleTimeTrackerSettings): string {
let ret = "";
for (let entry of tracker.entries)
ret += createTableRow(entry, settings).join(settings.csvSeparator) + "\n";
ret += createTableRow(entry, settings).join(settings.csvDelimiter) + "\n";
return ret;
}

View file

@ -1,4 +1,4 @@
{
"timestampFormat": "YY-MM-DD hh:mm:ss",
"csvSeparator": ","
}
"csvDelimiter": ","
}

File diff suppressed because one or more lines are too long

View file

@ -6,11 +6,11 @@ These are the notes for my cool project. There's so much left to do! I wish I ha
```
```
Think about project;22-09-27 09:09:37;22-09-27 09:59:48;50m 11s
Create project note;22-09-27 10:00:10;22-09-27 10:00:15;5s
Work on project;22-09-27 10:00:30;22-09-27 10:08:21;7m 51s
Segment 4;22-09-28 01:27:24;22-09-28 01:27:29;5s
Segment 5;22-09-28 01:28:15;22-09-28 01:28:18;3s
Think about project,22-09-27 09:09:37,22-09-27 09:59:48,50m 11s
Create project note,22-09-27 10:00:10,22-09-27 10:00:15,5s
Work on project,22-09-27 10:00:30,22-09-27 10:08:21,7m 51s
Segment 4,22-09-28 01:27:24,22-09-28 01:27:29,5s
Segment 5,22-09-28 01:28:15,22-09-28 01:28:18,3s
```