mirror of
https://github.com/exane/not-gwent-online
synced 2025-11-08 09:08:40 +00:00
change landing view rendering to php
This commit is contained in:
@@ -15,8 +15,8 @@ var app = new Vue({
|
||||
},
|
||||
|
||||
components: {
|
||||
landing: require('./components/landing'),
|
||||
lobby: require('./components/lobby')
|
||||
lobby: require('./components/lobby'),
|
||||
navigation: require('./components/navigation')
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
module.exports = {
|
||||
|
||||
template: require('../views/landing.html'),
|
||||
|
||||
components: {
|
||||
login: require('./modals/login')
|
||||
},
|
||||
|
||||
ready: function() {
|
||||
setTimeout(function() {
|
||||
$('.container-form-landing').addClass('active')
|
||||
}, 400);
|
||||
}
|
||||
|
||||
};
|
||||
5
site/client/app/components/navigation.js
Normal file
5
site/client/app/components/navigation.js
Normal file
@@ -0,0 +1,5 @@
|
||||
module.exports = {
|
||||
|
||||
template: require('../views/navigation.html')
|
||||
|
||||
};
|
||||
@@ -4,25 +4,18 @@ var router = new Router();
|
||||
module.exports = {
|
||||
|
||||
init: function(app) {
|
||||
router.on('/', function() {
|
||||
app.view = 'landing';
|
||||
app.section = 'landing';
|
||||
});
|
||||
|
||||
router.on('/lobby', function() {
|
||||
app.view = 'lobby';
|
||||
app.section = 'inner';
|
||||
});
|
||||
|
||||
this.configure();
|
||||
router.init('/');
|
||||
router.init();
|
||||
},
|
||||
|
||||
configure: function() {
|
||||
router.configure({
|
||||
notfound: function() {
|
||||
router.setRoute('/')
|
||||
}
|
||||
html5history: true
|
||||
})
|
||||
}
|
||||
}
|
||||
@@ -1,31 +0,0 @@
|
||||
<login></login>
|
||||
|
||||
<section class="container-landing">
|
||||
<div class="wrap-landing">
|
||||
<img src="assets/img/logo-big.png" width="243" height="85" alt="Gwent" class="logo-big">
|
||||
|
||||
<p class="teaser-landing">
|
||||
Play The Witcher Gwent Card-Game online!<br>
|
||||
Play with randomly generated teams, or build your own!
|
||||
</p>
|
||||
|
||||
<div class="container-form-landing">
|
||||
|
||||
<form class="form-session">
|
||||
<input type="text" placeholder="Username" class="field-session" autofocus>
|
||||
<input type="password" placeholder="Password" class="field-session">
|
||||
|
||||
<div class="wrap-btn-action btn-register-action">
|
||||
<input type="submit" value="Register" class="btn-action">
|
||||
<i class="icon-load"></i>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<span class="choose">or</span>
|
||||
|
||||
<a href="#/lobby" class="btn-second btn-guest">Play as guest</a>
|
||||
<a href="#" class="btn-none btn-login" v-on="click: modal = true">Login</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -1,9 +1,11 @@
|
||||
<section class="container-inner">
|
||||
|
||||
<a href="#/lobby"><img src="assets/img/logo-medium.png" width="148" height="46" alt="Gwent" class="logo-medium"></a>
|
||||
<a href="./lobby"><img src="assets/img/logo-medium.png" width="148" height="46" alt="Gwent" class="logo-medium"></a>
|
||||
|
||||
<navigation></navigation>
|
||||
|
||||
<main>
|
||||
|
||||
blaa
|
||||
</main>
|
||||
|
||||
</section>
|
||||
|
||||
7
site/client/app/views/navigation.html
Normal file
7
site/client/app/views/navigation.html
Normal file
@@ -0,0 +1,7 @@
|
||||
<nav>
|
||||
<ul>
|
||||
<li><a href="#/lobby" class="active">Lobby</a></li>
|
||||
<li><a href="#">Deck Builder</a></li>
|
||||
<li><a href="#">Highscore</a></li>
|
||||
</ul>
|
||||
</nav>
|
||||
Reference in New Issue
Block a user