Make log viewer mobile-friendly
This commit is contained in:
parent
ab2760fb28
commit
99dcba1d80
|
@ -1,5 +1,19 @@
|
|||
<div id="app"></div>
|
||||
<style>
|
||||
.mobile #app {
|
||||
font-size: 2em;
|
||||
}
|
||||
|
||||
.mobile #app input {
|
||||
font-size: 1em;
|
||||
padding: 0.3em;
|
||||
}
|
||||
|
||||
.messages {
|
||||
padding-left: 1em;
|
||||
padding-right: 1em;
|
||||
}
|
||||
|
||||
.messages li {
|
||||
list-style-type: none;
|
||||
font-family: monospace;
|
||||
|
@ -223,4 +237,9 @@ const view = (state, actions) => ijk("nodeName", "attributes", "children")(
|
|||
|
||||
const main = hyperapp.app(state, actions, view, document.getElementById("app"))
|
||||
main.connect()
|
||||
|
||||
// Detect mobile devices
|
||||
if ("onorientationchange" in window) {
|
||||
document.documentElement.classList.add("mobile")
|
||||
}
|
||||
</script>
|
Loading…
Reference in New Issue