Skip to content

Commit 50a5183

Browse files
removed iso time string
1 parent d2c2a4a commit 50a5183

File tree

2 files changed

+0
-22
lines changed

2 files changed

+0
-22
lines changed

src/widget/views/index.hbs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
<svg xmlns="http://www.w3.org/2000/svg" width="800" height="{{ height }}" viewBox="0 0 800 {{ height }}">
22
<style>
3-
.bracket {
4-
fill: red;
5-
}
6-
73
.key {
84
fill: #9cdcfe;
95
}

src/widget/widget.service.ts

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -28,23 +28,6 @@ export class WidgetService {
2828
});
2929
}
3030

31-
toIsoString(date: Date) {
32-
const tzo = -new Date(new Date().toLocaleString("en-US", { timeZone: process.env.DATETIME_TIMEZONE })).getTimezoneOffset();
33-
const dif = tzo >= 0 ? '+' : '-';
34-
const pad = (num: number) => {
35-
return (num < 10 ? '0' : '') + num;
36-
};
37-
38-
return date.getFullYear() +
39-
'-' + pad(date.getMonth() + 1) +
40-
'-' + pad(date.getDate()) +
41-
'T' + pad(date.getHours()) +
42-
':' + pad(date.getMinutes()) +
43-
':' + pad(date.getSeconds()) +
44-
dif + pad(Math.floor(Math.abs(tzo) / 60)) +
45-
':' + pad(Math.abs(tzo) % 60);
46-
}
47-
4831
generate_indexes(count: number) {
4932
const array = [];
5033
for (let index = 1; index <= count; index++) {
@@ -120,7 +103,6 @@ export class WidgetService {
120103
time: this.getTime(),
121104
tz: process.env.DATETIME_TIMEZONE,
122105
date: this.getDate(),
123-
iso: this.toIsoString(new Date())
124106
},
125107
activity: activity && activity.activities.length !== 0 ? {
126108
file: activity.activities[0].file ?? 'Idling',

0 commit comments

Comments
 (0)