Small client updates

This commit is contained in:
Linus Miller 2016-09-15 14:56:26 +02:00
parent 583abc5004
commit ddc1d5bf5a
2 changed files with 3 additions and 5 deletions

View File

@ -4,8 +4,8 @@ import './process'
import Timer from './components/Timer'
// request permission on page load
document.addEventListener('DOMContentLoaded', () => {
$(() => {
// request permission on page load
if (!Notification) {
alert('Desktop notifications not available in your browser. Try Chromium, Chrome or Firefox.')
return
@ -13,9 +13,7 @@ document.addEventListener('DOMContentLoaded', () => {
if (Notification.permission !== 'granted')
Notification.requestPermission()
})
$(() => {
const timer = $('.timer')
Timer.render().replace(timer).getWidget()

View File

@ -1,5 +1,5 @@
import markoWidgets from 'marko-widgets'
import template from './template.marko.js'
import template from './template.marko'
import timeFilter from '../../util/time-filter'