From 93af695f08ba0cd76210a6f965c2424b1c0745f0 Mon Sep 17 00:00:00 2001 From: Noah Loomans Date: Wed, 7 Sep 2016 11:37:07 +0200 Subject: add made by field --- app.js | 2 ++ public/stylesheets/hello.css | 23 +++++++++++++++++++++++ routes/hello.js | 9 +++++++++ views/hello.jade | 9 +++++++++ views/index.jade | 8 ++++++-- views/layout.jade | 3 +-- 6 files changed, 50 insertions(+), 4 deletions(-) create mode 100644 public/stylesheets/hello.css create mode 100644 routes/hello.js create mode 100644 views/hello.jade diff --git a/app.js b/app.js index a0d0071..af0092a 100644 --- a/app.js +++ b/app.js @@ -7,6 +7,7 @@ const bodyParser = require('body-parser') const routes = require('./routes/index') const meetingpointProxy = require('./routes/meetingpointProxy') const getUserIndex = require('./routes/getUserIndex') +const hello = require('./routes/hello') const app = express() @@ -23,6 +24,7 @@ app.use(express.static(path.join(__dirname, 'public'))) app.use('/', routes) app.use('/meetingpointProxy', meetingpointProxy) app.use('/getUserIndex', getUserIndex) +app.use('/hello', hello) // catch 404 and forward to error handler app.use(function (req, res, next) { diff --git a/public/stylesheets/hello.css b/public/stylesheets/hello.css new file mode 100644 index 0000000..edcbc92 --- /dev/null +++ b/public/stylesheets/hello.css @@ -0,0 +1,23 @@ +* { + box-sizing: border-box; +} + +html, body { + margin: 0; + font-family: 'Roboto', sans-serif; + display: flex; + flex-direction: column; + justify-content: center; + text-align: center; + width: 100vw; + height: 100vh; + color: gray; +} + +.ideas { + font-size: 0.8em; +} + +a { + color: #3f51b5; +} diff --git a/routes/hello.js b/routes/hello.js new file mode 100644 index 0000000..6356b98 --- /dev/null +++ b/routes/hello.js @@ -0,0 +1,9 @@ +var express = require('express') +var router = express.Router() + +/* GET home page. */ +router.get('/', function (req, res, next) { + res.render('hello') +}) + +module.exports = router diff --git a/views/hello.jade b/views/hello.jade new file mode 100644 index 0000000..c2247c6 --- /dev/null +++ b/views/hello.jade @@ -0,0 +1,9 @@ +extends layout + +block head + link(rel='stylesheet', href='/stylesheets/hello.css') + +block content + p.madeby Gemaakt door Noah Loomans + p.ideas Heb je ideen om dit te verbeteren? Mail me op  + a(href='mailto:noah.loomans+roostermml@hetcml.nl') noah.loomans+roostermml@hetcml.nl diff --git a/views/index.jade b/views/index.jade index d4fd5af..dae679f 100644 --- a/views/index.jade +++ b/views/index.jade @@ -1,15 +1,19 @@ extends layout +block head + link(rel='stylesheet', href='/stylesheets/style.css') + script(async, defer, src='/javascripts/dest/main.js') + block content form#search .input-wrapper input(type='text', placeholder='Search', autofocus) .autocomplete-wrapper ul.autocomplete - #search-space-filler #week-selector + #search-space-filler .week-wrapper input(type='button', value='Vorige') span.current Loading... input(type='button', value='Volgende') - iframe#schedule + iframe(src='/hello')#schedule diff --git a/views/layout.jade b/views/layout.jade index 6d6d4f9..18c4a91 100644 --- a/views/layout.jade +++ b/views/layout.jade @@ -4,9 +4,8 @@ html title Metis Rooster meta(name='theme-color',content='#F44336') meta(name='viewport', content='width=device-width, initial-scale=1') - link(rel='stylesheet', href='/stylesheets/style.css') - script(async, defer, src='/javascripts/dest/main.js') link(href='https://fonts.googleapis.com/css?family=Roboto' rel='stylesheet') + block head body block content script. -- cgit v1.1