Add improvements for small screens

This commit is contained in:
Christoph Wiechert
2017-05-08 23:40:01 +02:00
parent 63042cb9c2
commit b843776cc9
2 changed files with 13 additions and 2 deletions

View File

@@ -12,6 +12,7 @@ Simple open source self-hosted file sharing solution.
It's an alternative to paid services like Dropbox, WeTransfer. It's an alternative to paid services like Dropbox, WeTransfer.
* No accounts, no logins * No accounts, no logins
* Mobile friendly responsive interface
* Supports many and very big files (Streams ftw) * Supports many and very big files (Streams ftw)
* Resumable up- and downloads ([tus.io](https://tus.io)) * Resumable up- and downloads ([tus.io](https://tus.io))
* Set an expire-time for your upload bucket * Set an expire-time for your upload bucket

View File

@@ -1,9 +1,9 @@
<template lang="pug"> <template lang="pug">
.upload-app .upload-app#uploadApp
.btn-group(style='position: absolute; top: 15px; right: 15px;') .btn-group(style='position: absolute; top: 15px; right: 15px;')
a.btn.btn-sm.btn-info(@click='newSession()', title='New Upload') a.btn.btn-sm.btn-info(@click='newSession()', title='New Upload')
i.fa.fa-fw.fa-cloud-upload i.fa.fa-fw.fa-cloud-upload
| new upload span.hidden-xs new upload
.alert.alert-danger(v-show="error") .alert.alert-danger(v-show="error")
strong strong
i.fa.fa-exclamation-triangle i.fa.fa-exclamation-triangle
@@ -69,6 +69,16 @@
} }
}, },
watch: {
state: function(val) {
if(val === 'uploaded' || val === 'uploadError') {
const el = document.getElementById('uploadApp');
if(!el || !el.scrollIntoView) return;
el.scrollIntoView(true);
}
}
},
methods: { methods: {
newSession() { newSession() {
if(!confirm('Create a new upload session?')) return; if(!confirm('Create a new upload session?')) return;