Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'master' of https://github.com/jmagnusson/the-olumpics

  • Loading branch information...
commit cb43376e996f46cf46a5be634242706b011d506c 2 parents a3e32ea + 9c9b402
Alexander Hansson AlexxHansson authored
6 gui/app/index.html
View
@@ -9,6 +9,7 @@
<!-- <meta http-equiv="X-UA-Compatible" content="IE=edge"> -->
<title>The Olumpics</title>
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css">
+ <link rel="stylesheet" href='//fonts.googleapis.com/css?family=Roboto+Slab:400,100&subset=latin,latin-ext'>
<link rel="stylesheet" type="text/css" href="styles/main.css">
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
@@ -16,10 +17,7 @@
<!-- Place favicon.ico and apple-touch-icon.png in the root directory -->
</head>
<body>
- <!--[if lt IE 8]>
- <p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
- <![endif]-->
- <h1>The Olumpics</h1>
+ <div class="container-fluid" id="app"></div>
<script src="scripts/app.js"></script>
</body>
</html>
4 gui/app/scripts/index.coffee
View
@@ -3,9 +3,13 @@ $ = require('jquery')
io = require('socket.io-client')
queryString = require('query-string')
fs = require('fs')
+startTmpl = fs.readFileSync(__dirname + '/templates/start.html')
+waitTmpl = fs.readFileSync(__dirname + '/templates/wait.html')
chooseCharacterTmpl = fs.readFileSync(__dirname + '/templates/choose-character.html')
$app = $('#app')
+$app.html(_.template(startTmpl))
+
gameId = parseInt(queryString.parse(window.location.search).game, 10)
userId = null
socket = io.connect('http://194.47.154.230:8080')
11 gui/app/scripts/templates/choose-character.html
View
@@ -0,0 +1,11 @@
+<ul class="inline-list row">
+ <li class="col-sm-4 character-card">
+ Char 1
+ </li>
+ <li class="col-sm-4 character-card">
+ Char 2
+ </li>
+ <li class="col-sm-4 character-card">
+ Char 3
+ </li>
+</ul>
7 gui/app/scripts/templates/start.html
View
@@ -0,0 +1,7 @@
+<div class="row">
+ <div class="col-sm-12 text-center">
+ <h1><small>The</small> O<strong class="text-yellow">lump</strong>ics</h1>
+ <hr>
+ <p class="font-size-small"><a href="#" class="btn btn-lg btn-warning">Battle!</a></p>
+ </div>
+</div>
10 gui/app/scripts/templates/wait.html
View
@@ -0,0 +1,10 @@
+<div class="row">
+ <div class="col-sm-12 text-center">
+ <h1><small>The</small> O<strong class="text-yellow">lump</strong>ics</h1>
+ <hr>
+ <p class="font-size-small">Send this link to your enemies<br><input type="text" value="http://olumpi.cs/3490823409234uq304934"></p>
+ <hr>
+ <p>Waiting for other player to connect&hellip;</p>
+ <p><span class="spin font-size-large">&mdash;</span></p>
+ </div>
+</div>
4 gui/app/styles/_character.scss
View
@@ -0,0 +1,4 @@
+
+.character-card {
+ border: 1px solid rgb(240,240,0);
+}
31 gui/app/styles/_general.scss
View
@@ -0,0 +1,31 @@
+
+body {
+ background-color: rgb(30,60,60);
+ color: rgb(250,250,250);
+
+ font-family: 'Roboto Slab', serif;
+ font-weight: 100;
+ font-size: $font-size-base;
+}
+
+h1, h2, h3, h4, h5, h6 {
+ font-size: $font-size-large;
+ font-weight: 100;
+ margin-top: 1em;
+ margin-bottom: .5em;
+
+ small {
+ font-weight: 100;
+ color: inherit;
+ display: block;
+ }
+}
+
+input[type='text'] {
+ background: rgb(60,90,90);
+ color: rgb(250,250,250);
+ border: rgb(0,30,30);
+ border-radius: 1em;
+ padding: .5em;
+ margin: .5em auto;
+}
15 gui/app/styles/_utils.scss
View
@@ -0,0 +1,15 @@
+
+.text-yellow { color: rgb(200,200,0); }
+
+.font-size-small { font-size: $font-size-small; }
+.font-size-base { font-size: $font-size-base; }
+.font-size-large { font-size: $font-size-large; }
+
+@keyframes spin {
+ from { transform: rotate(0deg); }
+ to { transform: rotate(360deg); }
+}
+.spin {
+ display: inline-block;
+ animation: spin 1s linear infinite;
+}
3  gui/app/styles/_variables.scss
View
@@ -0,0 +1,3 @@
+$font-size-small: 3vh;
+$font-size-base: 6vh;
+$font-size-large: 9vh;
3  gui/app/styles/main.scss
View
@@ -1 +1,4 @@
+@import "variables";
+@import "utils";
@import "general";
+@import "character";
Please sign in to comment.
Something went wrong with that request. Please try again.