-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
And some style tweaks.
- Loading branch information
Showing
15 changed files
with
934 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
{ | ||
"env": { | ||
"browser": true, | ||
"es2021": true | ||
}, | ||
"extends": [ | ||
"standard" | ||
], | ||
"parserOptions": { | ||
"ecmaVersion": 12, | ||
"sourceType": "module" | ||
}, | ||
"rules": { | ||
"indent": ["error", 4], | ||
"semi": ["error", "always"] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
import '../css/app.less'; | ||
|
||
import './timezone-converter'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
(function () { | ||
document.body.querySelectorAll('time').forEach(function (timeEl) { | ||
// Show the UTC time as the tooltip. | ||
timeEl.title = 'UTC time: ' + timeEl.innerText; | ||
// Convert to local browser time for actual display. | ||
const date = new Date(Date.parse(timeEl.dateTime)); | ||
const options = { | ||
timeZoneName: 'long', | ||
year: 'numeric', | ||
month: 'long', | ||
day: 'numeric', | ||
weekday: 'long', | ||
hour: 'numeric', | ||
minute: 'numeric' | ||
}; | ||
timeEl.innerText = date.toLocaleString([], options) + '.'; | ||
}); | ||
}()); |
Oops, something went wrong.