Made dashboard not load up login by default

This commit is contained in:
Pitu 2017-01-17 17:24:20 -03:00
parent 2b95f62396
commit e466f85a4e
3 changed files with 2 additions and 14 deletions

View File

@ -26,19 +26,6 @@
<section id='dashboard' class="section">
<!--<div id="auth" class="container">
<div class="columns">
<div class="column"></div>
<div class="column">
<p class="control has-addons has-addons-centered">
<input id='token' class="input is-danger" type="text" placeholder="Your admin token">
<a id='tokenSubmit' class="button is-danger">Check</a>
</p>
</div>
<div class="column"></div>
</div>
</div>-->
<div id="panel" class="container">
<h1 class="title">Dashboard</h1>
<h2 class="subtitle">A simple <strong>dashboard</strong>, to sort your uploaded stuff</h2>

View File

@ -81,7 +81,7 @@ img.logo { height: 200px; margin-top: 20px; }
PANEL
------------------ */
section#dashboard { display: none }
section#auth, section#dashboard { display: none }
section#auth input { background: rgba(0, 0, 0, 0); }
section#auth input, section#auth a {
border-left: 0px;

View File

@ -5,6 +5,7 @@ panel.token = localStorage.admintoken;
panel.preparePage = function(){
if(!panel.token){
document.getElementById('auth').style.display = 'flex';
document.getElementById('tokenSubmit').addEventListener('click', function(){
panel.verifyToken(document.getElementById('token').value);
});