Parcourir la source

Handle webkit

master
Roderic Day il y a 5 ans
Parent
révision
5b26f9a4fb
1 fichiers modifiés avec 3 ajouts et 2 suppressions
  1. +3
    -2
      pico.js

+ 3
- 2
pico.js Voir le fichier

@@ -36,7 +36,7 @@ State.unseen = 0
listen('post', () => {State.unseen += !document.hasFocus(); updateTitle()})
listen('focus', () => {State.unseen = 0; updateTitle()})
const updateTitle = () => {
document.title = `Pico.Chat` + (State.unseen ? ` (${State.unseen})` : ``)
document.title = `pico.chat` + (State.unseen ? ` (${State.unseen})` : ``)
}

/*
@@ -120,7 +120,8 @@ const scrollIntoView = (vnode) => {
vnode.dom.scrollIntoView()
}
const toggleFullscreen = (el) => (event) => {
document.fullscreenElement ? document.exitFullscreen() : el.requestFullscreen()
const requestFullscreen = (el.requestFullscreen || el.webkitRequestFullscreen).bind(el)
document.fullscreenElement ? document.exitFullscreen() : requestFullscreen()
}
const prettyTime = (ts) => {
const dt = new Date(ts)

Chargement…
Annuler
Enregistrer