diff --git a/site/client/app/app.js b/site/client/app/app.js index 790d8d3..ee3091e 100644 --- a/site/client/app/app.js +++ b/site/client/app/app.js @@ -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') } }); diff --git a/site/client/app/components/landing.js b/site/client/app/components/landing.js deleted file mode 100644 index b7e1699..0000000 --- a/site/client/app/components/landing.js +++ /dev/null @@ -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); - } - -}; \ No newline at end of file diff --git a/site/client/app/components/navigation.js b/site/client/app/components/navigation.js new file mode 100644 index 0000000..9bce8fc --- /dev/null +++ b/site/client/app/components/navigation.js @@ -0,0 +1,5 @@ +module.exports = { + + template: require('../views/navigation.html') + +}; \ No newline at end of file diff --git a/site/client/app/routes.js b/site/client/app/routes.js index d300cce..1c39c52 100644 --- a/site/client/app/routes.js +++ b/site/client/app/routes.js @@ -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 }) } } \ No newline at end of file diff --git a/site/client/app/views/landing.html b/site/client/app/views/landing.html deleted file mode 100644 index 7013383..0000000 --- a/site/client/app/views/landing.html +++ /dev/null @@ -1,31 +0,0 @@ - - -
-
- Gwent - -

- Play The Witcher Gwent Card-Game online!
- Play with randomly generated teams, or build your own! -

- -
- -
- - - -
- - -
-
- - or - - Play as guest - - -
-
-
diff --git a/site/client/app/views/lobby.html b/site/client/app/views/lobby.html index f0b2493..09ff912 100644 --- a/site/client/app/views/lobby.html +++ b/site/client/app/views/lobby.html @@ -1,9 +1,11 @@
- Gwent + Gwent + +
- + blaa
diff --git a/site/client/app/views/navigation.html b/site/client/app/views/navigation.html new file mode 100644 index 0000000..875830d --- /dev/null +++ b/site/client/app/views/navigation.html @@ -0,0 +1,7 @@ + diff --git a/site/client/assets/sass/_inner.scss b/site/client/assets/sass/_inner.scss index 4911f82..aa12417 100644 --- a/site/client/assets/sass/_inner.scss +++ b/site/client/assets/sass/_inner.scss @@ -3,7 +3,27 @@ body.inner { background-size: cover; } +.logo-medium { + float: left; +} + .container-inner { width: 100%; padding: 40px; +} + +main { + float: left; + width: 70%; + padding: 20px; + height: calc(100vh - 300px); + min-height: 400px; + + background: -moz-linear-gradient(top, rgba(8,13,20,1) 17%, rgba(8,13,20,0.65) 46%, rgba(239,239,239,0) 100%); + background: -webkit-gradient(linear, left top, left bottom, color-stop(17%,rgba(8,13,20,1)), color-stop(46%,rgba(8,13,20,0.65)), color-stop(100%,rgba(239,239,239,0))); + background: -webkit-linear-gradient(top, rgba(8,13,20,1) 17%,rgba(8,13,20,0.65) 46%,rgba(239,239,239,0) 100%); + background: -o-linear-gradient(top, rgba(8,13,20,1) 17%,rgba(8,13,20,0.65) 46%,rgba(239,239,239,0) 100%); + background: -ms-linear-gradient(top, rgba(8,13,20,1) 17%,rgba(8,13,20,0.65) 46%,rgba(239,239,239,0) 100%); + background: linear-gradient(to bottom, rgba(8,13,20,1) 17%,rgba(8,13,20,0.65) 46%,rgba(239,239,239,0) 100%); + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#080d14', endColorstr='#00efefef',GradientType=0 ); } \ No newline at end of file diff --git a/site/client/assets/sass/_landing.scss b/site/client/assets/sass/_landing.scss index 4621c97..9aeeafd 100644 --- a/site/client/assets/sass/_landing.scss +++ b/site/client/assets/sass/_landing.scss @@ -3,6 +3,15 @@ body.landing { background-size: cover; } +.icon-guest-load { + background: url(../img/guest-load.gif) #ca5a07 no-repeat; + width: 16px; + height: 16px; + float: right; + margin: 5px -7px 0 7px; + display: none; +} + .wrap-landing { max-width: 900px; margin: 0 auto; diff --git a/site/client/assets/sass/_nav.scss b/site/client/assets/sass/_nav.scss new file mode 100644 index 0000000..65a03be --- /dev/null +++ b/site/client/assets/sass/_nav.scss @@ -0,0 +1,36 @@ +nav { + float: left; + margin: 30px 0 0 0; + clear: both; + + ul { + float: left; + margin: 0; + } + + li { + float: left; + } + + a { + color: #8798ac; + text-shadow: 0 0 10px rgba(255, 255, 255, 0.6); + font-size: 19px; + text-transform: uppercase; + font-weight: 300; + padding: 12px 25px; + float: left; + + @include transition(color); + + &:hover { + color: #c5cfda; + } + + &.active { + color: $main; + text-shadow: none; + background: rgba(#080d14, .9); + } + } +} \ No newline at end of file diff --git a/site/client/assets/sass/app.scss b/site/client/assets/sass/app.scss index 7c54197..eefc324 100644 --- a/site/client/assets/sass/app.scss +++ b/site/client/assets/sass/app.scss @@ -9,4 +9,5 @@ 'modal', 'form', 'landing', -'inner'; \ No newline at end of file +'inner', +'nav'; \ No newline at end of file diff --git a/site/client/views/app.blade.php b/site/client/views/app.blade.php index c5d2fb3..aa3623e 100644 --- a/site/client/views/app.blade.php +++ b/site/client/views/app.blade.php @@ -12,12 +12,29 @@ - + - + @yield('content') + + \ No newline at end of file diff --git a/site/client/views/inner.blade.php b/site/client/views/inner.blade.php new file mode 100644 index 0000000..2db5a65 --- /dev/null +++ b/site/client/views/inner.blade.php @@ -0,0 +1,11 @@ +@extends('app') + +@section('content') + + @if($type == 'server') + + @else + + @endif + +@stop \ No newline at end of file diff --git a/site/client/views/landing.blade.php b/site/client/views/landing.blade.php new file mode 100644 index 0000000..2988c4d --- /dev/null +++ b/site/client/views/landing.blade.php @@ -0,0 +1,37 @@ +@extends('app') + +@section('content') + + + +
+
+ Gwent + +

+ Play The Witcher Gwent Card-Game online!
+ Play with randomly generated teams, or build your own! +

+ +
+ +
+ + + +
+ + +
+
+ + or + + Play as guest + + +
+
+
+ +@stop \ No newline at end of file diff --git a/site/client/views/partials/modals/login.blade.php b/site/client/views/partials/modals/login.blade.php deleted file mode 100644 index 0c5fd21..0000000 --- a/site/client/views/partials/modals/login.blade.php +++ /dev/null @@ -1,17 +0,0 @@ - \ No newline at end of file diff --git a/site/public/assets/img/load.gif b/site/public/assets/img/action-load.gif similarity index 100% rename from site/public/assets/img/load.gif rename to site/public/assets/img/action-load.gif diff --git a/site/public/assets/img/guest-load.gif b/site/public/assets/img/guest-load.gif new file mode 100644 index 0000000..07052d5 Binary files /dev/null and b/site/public/assets/img/guest-load.gif differ diff --git a/site/server/app/Exceptions/Handler.php b/site/server/app/Exceptions/Handler.php index 89d9fc2..75bb3d4 100755 --- a/site/server/app/Exceptions/Handler.php +++ b/site/server/app/Exceptions/Handler.php @@ -42,7 +42,7 @@ public function render($request, Exception $e) { if($e instanceof NotFoundHttpException) { - //return redirect('/'); + return redirect('/'); } return parent::render($request, $e); diff --git a/site/server/app/Http/routes.php b/site/server/app/Http/routes.php index 31f7f10..0e1ab5e 100755 --- a/site/server/app/Http/routes.php +++ b/site/server/app/Http/routes.php @@ -1,5 +1,16 @@ withSection('inner') + ->withType('server'); + }); + get('/', function() { - return view('app'); + if(Auth::check()) { + return redirect('/lobby'); + } + + return view('landing') + ->withSection('landing'); }); \ No newline at end of file