├── .github └── FUNDING.yml ├── LICENSE ├── README.md ├── app ├── models │ └── user.js └── routes.js ├── config ├── database.js └── passport.js ├── package-lock.json ├── package.json ├── public ├── assets │ ├── css │ │ ├── fontawesome-all.min.css │ │ ├── images │ │ │ ├── arrow.svg │ │ │ ├── ie │ │ │ │ └── banner-overlay.png │ │ │ └── overlay.png │ │ ├── main.css │ │ └── noscript.css │ ├── js │ │ ├── breakpoints.min.js │ │ ├── browser.min.js │ │ ├── jquery.dropotron.min.js │ │ ├── jquery.min.js │ │ ├── jquery.scrollex.min.js │ │ ├── jquery.scrolly.min.js │ │ ├── main.js │ │ └── util.js │ ├── sass │ │ ├── libs │ │ │ ├── _breakpoints.scss │ │ │ ├── _functions.scss │ │ │ ├── _html-grid.scss │ │ │ ├── _mixins.scss │ │ │ ├── _vars.scss │ │ │ └── _vendor.scss │ │ ├── main.scss │ │ └── noscript.scss │ └── webfonts │ │ ├── fa-brands-400.eot │ │ ├── fa-brands-400.svg │ │ ├── fa-brands-400.ttf │ │ ├── fa-brands-400.woff │ │ ├── fa-brands-400.woff2 │ │ ├── fa-regular-400.eot │ │ ├── fa-regular-400.svg │ │ ├── fa-regular-400.ttf │ │ ├── fa-regular-400.woff │ │ ├── fa-regular-400.woff2 │ │ ├── fa-solid-900.eot │ │ ├── fa-solid-900.svg │ │ ├── fa-solid-900.ttf │ │ ├── fa-solid-900.woff │ │ └── fa-solid-900.woff2 ├── images │ ├── banner.jpg │ ├── cabin.jpg │ ├── mountain1.jpg │ ├── mountain2.jpg │ ├── mountain3.jpg │ ├── palm1.jpeg │ ├── palm2.jpg │ ├── palm3.jpg │ ├── pic01.jpg │ ├── pic02.jpg │ ├── pic03.jpg │ ├── pic04.jpg │ ├── pic05.jpg │ ├── pic06.jpg │ ├── pic07.jpg │ └── pic08.jpg ├── img │ └── savage21.jpg ├── main.js └── style.css ├── server.js └── views ├── connect-local.ejs ├── index.ejs ├── login.ejs ├── profile.ejs └── signup.ejs /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | # These are supported funding model platforms 2 | 3 | github: CharlesCreativeContent 4 | patreon: # Replace with a single Patreon username 5 | open_collective: # Replace with a single Open Collective username 6 | ko_fi: # Replace with a single Ko-fi username 7 | tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel 8 | community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry 9 | liberapay: # Replace with a single Liberapay username 10 | issuehunt: # Replace with a single IssueHunt username 11 | otechie: # Replace with a single Otechie username 12 | lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry 13 | custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2'] 14 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2018 RC 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Travel Web-Application: Visit Here 2 | 3 | Travelara.org 4 | 5 | 6 | Platform to help build momentous milestones along with your friends and family! Travelara makes Dream Trips a Reality! 7 | 8 | 9 | ## Tech used: ![HTML5 BADGE](https://img.shields.io/static/v1?label=|&message=HTML5&color=23555f&style=plastic&logo=html5)![CSS BADGE](https://img.shields.io/static/v1?label=|&message=CSS3&color=285f65&style=plastic&logo=css3)![SASS BADGE](https://img.shields.io/static/v1?label=|&message=SASS&color=2b625f&style=plastic&logo=sass)![BOOTSTRAP BADGE](https://img.shields.io/static/v1?label=|&message=BOOTSTRAP&color=316c5e&style=plastic&logo=bootstrap)![JAVASCRIPT BADGE](https://img.shields.io/static/v1?label=|&message=JAVASCRIPT&color=3c7f5d&style=plastic&logo=javascript)![EXPRESS BADGE](https://img.shields.io/static/v1?label=|&message=EXPRESS&color=bbb111&style=plastic&logo=express)![MONGODB BADGE](https://img.shields.io/static/v1?label=|&message=MONGO-DB&color=cdd148&style=plastic&logo=mongodb) 10 | 11 | 12 | ## Optimizations 13 | One of the first thing I would optimize is the UX of how someone schedules a vacation and would love to add chatgpt plugins to be able to populate a price page for hotels and flights. I would also work on the scalability of the API used. Lastly I would make it so that a person can swipe with friends in real time. 14 | 15 | ## Lessons Learned 16 | 17 | Utilized callback functions in the server to try and build a modular and scalable backend. Through this I learned , how to effectively simplify backend routes into independent functions 18 | 19 | ## Demo Login 20 | 21 | 22 | Demo Email: demo@demo.com 23 | 24 | Demo password: demo 25 | 26 | 27 | ## Installation 28 | 29 | 1. Clone repo 30 | 2. run `npm install` 31 | 3. update DATABASE_URL in config/database 32 | 33 | ## Usage 34 | 35 | 1. run `node server.js` 36 | 2. Navigate to `localhost:8080` 37 | 38 | ## More Projects 39 | 40 | 41 | 42 | 43 | 50 | 57 | 64 | 65 |
44 | Rigley 2: Flappy Bug 45 |
46 | 47 | Rigley 2: Flappy Bug 48 | 49 |
51 | Matching Card Game 52 |
53 | 54 | Matching Card Game 55 | 56 |
58 | Portfolio 59 |
60 | 61 | Portfolio 62 | 63 |
66 | -------------------------------------------------------------------------------- /app/models/user.js: -------------------------------------------------------------------------------- 1 | // load the things we need 2 | var mongoose = require('mongoose'); 3 | var bcrypt = require('bcrypt-nodejs'); 4 | 5 | // define the schema for our user model 6 | var userSchema = mongoose.Schema({ 7 | 8 | local : { 9 | email : String, 10 | password : String 11 | }, 12 | facebook : { 13 | id : String, 14 | token : String, 15 | name : String, 16 | email : String 17 | }, 18 | twitter : { 19 | id : String, 20 | token : String, 21 | displayName : String, 22 | username : String 23 | }, 24 | google : { 25 | id : String, 26 | token : String, 27 | email : String, 28 | name : String 29 | } 30 | 31 | }); 32 | 33 | // generating a hash 34 | userSchema.methods.generateHash = function(password) { 35 | return bcrypt.hashSync(password, bcrypt.genSaltSync(8), null); 36 | }; 37 | 38 | // checking if password is valid 39 | userSchema.methods.validPassword = function(password) { 40 | return bcrypt.compareSync(password, this.local.password); 41 | }; 42 | 43 | // create the model for users and expose it to our app 44 | module.exports = mongoose.model('User', userSchema); 45 | -------------------------------------------------------------------------------- /app/routes.js: -------------------------------------------------------------------------------- 1 | var https = require('https'); 2 | var qs = require("querystring"); 3 | module.exports = function(app, passport, db) { 4 | 5 | // normal routes =============================================================== 6 | 7 | // show the home page (will also have our login links) 8 | app.get('/', function(req, res) { 9 | res.render('index.ejs'); 10 | }); 11 | 12 | // PROFILE SECTION ========================= 13 | app.get('/profile', isLoggedIn, function(req, res) { 14 | db.collection('messages').find().toArray((err, result) => { 15 | if (err) return console.log(err) 16 | 17 | //I will make my search queries to Groupon kinda like this, when they send me an APIKey// 18 | // https.get(`https://Groupon`, (resp) => { 19 | // let data = ''; 20 | // resp.on('data', (obj) => { 21 | // data += obj; 22 | // }); 23 | // resp.on('end', () => { 24 | // console.log('') 25 | // console.log('This is all the Groupon data as an object that I will render to the client',JSON.parse(data)) 26 | // }); 27 | // }).on("error", (err) => { 28 | // console.log("Error: " + err.message); 29 | // }); 30 | 31 | //Around here I will make my search queries to FourSquare// 32 | https.get(`https://api.foursquare.com/v2/venues/search?client_id=CRK3M3QSQ4SSNTAJ34HBSHLYURAPOYHYQ0PVJHKTSNCPIYC2&client_secret=ZRZQNU3GQY3FXA4L2ASD5G03AF0RS34CAATEIMBJHJZWLJUZ&ll=40.74224,-73.99386&v=20200901`, (resp) => { 33 | let data = ''; 34 | resp.on('data', (obj) => { 35 | data += obj; 36 | }); 37 | resp.on('end', () => { 38 | console.log('') 39 | console.log('This is all the FourSquare data as an object that I will render to the client',JSON.parse(data)) 40 | }); 41 | }).on("error", (err) => { 42 | console.log("Error: " + err.message); 43 | }); 44 | 45 | //I Couldnt get the AIRBNB query to work Server side because Airbnb doesnt provide access unless through third party// 46 | //In This case I'm using Rapid API. I might have to keep this query client side if I can't find an alternative// 47 | 48 | //Around Here I will make my search queries to AirBnB// 49 | // var options = { 50 | // "method": "GET", 51 | // "hostname": "https://mashvisor-api.p.rapidapi.com", 52 | // "port": 8080, 53 | // "path": '/airbnb-property/top-reviewed', 54 | // "headers": { 55 | // "x-rapidapi-key": "3ae1d00c97msh298612aebb81230p11684djsn405007844583", 56 | // "content-type": "application/x-www-form-urlencoded", 57 | // "useQueryString": 'page=1&city=Los%20Angeles&reviews_count=30&zip_code=91342&state=CA' 58 | // } 59 | // }; 60 | // 61 | // https.get(options, function (respo) { 62 | // var chunks = ''; 63 | // 64 | // respo.on("data", function (chunk) { 65 | // chunks+=chuck; 66 | // }); 67 | // console.log(chunks) 68 | // respo.on("end", function () { 69 | // console.log(chunks) 70 | // var body = Buffer.concat(chunks); 71 | // console.log(body.toString()); 72 | // }); 73 | // }).on("error", (err) => { 74 | // console.log("Error: " + err.message); 75 | // }); 76 | 77 | res.render('profile.ejs', { 78 | user : req.user, 79 | messages: result 80 | }) 81 | }) 82 | }); 83 | 84 | // LOGOUT ============================== 85 | app.get('/logout', function(req, res) { 86 | req.logout(); 87 | res.redirect('/'); 88 | }); 89 | 90 | // message board routes =============================================================== 91 | 92 | app.post('/messages', (req, res) => { 93 | db.collection('messages').save({name: req.body.name, msg: req.body.msg, thumbUp: 0, thumbDown:0}, (err, result) => { 94 | if (err) return console.log(err) 95 | console.log('saved to database') 96 | res.redirect('/profile') 97 | }) 98 | }) 99 | 100 | app.put('/messages', (req, res) => { 101 | db.collection('messages') 102 | .findOneAndUpdate({name: req.body.name, msg: req.body.msg}, { 103 | $set: { 104 | thumbUp:req.body.thumbUp + 1 105 | } 106 | }, { 107 | sort: {_id: -1}, 108 | upsert: true 109 | }, (err, result) => { 110 | if (err) return res.send(err) 111 | res.send(result) 112 | }) 113 | }) 114 | 115 | app.put('/nomessages', (req, res) => { 116 | db.collection('messages') 117 | .findOneAndUpdate({name: req.body.name, msg: req.body.msg}, { 118 | $set: { 119 | thumbUp:!req.body.thumbUp?0:req.body.thumbUp-1 120 | } 121 | }, { 122 | sort: {_id: -1}, 123 | upsert: true 124 | }, (err, result) => { 125 | if (err) return res.send(err) 126 | res.send(result) 127 | }) 128 | }) 129 | 130 | app.delete('/messages', (req, res) => { 131 | db.collection('messages').findOneAndDelete({name: req.body.name, msg: req.body.msg}, (err, result) => { 132 | if (err) return res.send(500, err) 133 | res.send('Message deleted!') 134 | }) 135 | }) 136 | 137 | // ============================================================================= 138 | // AUTHENTICATE (FIRST LOGIN) ================================================== 139 | // ============================================================================= 140 | 141 | // locally -------------------------------- 142 | // LOGIN =============================== 143 | // show the login form 144 | app.get('/login', function(req, res) { 145 | res.render('login.ejs', { message: req.flash('loginMessage') }); 146 | }); 147 | 148 | // process the login form 149 | app.post('/login', passport.authenticate('local-login', { 150 | successRedirect : '/profile', // redirect to the secure profile section 151 | failureRedirect : '/login', // redirect back to the signup page if there is an error 152 | failureFlash : true // allow flash messages 153 | })); 154 | 155 | // SIGNUP ================================= 156 | // show the signup form 157 | app.get('/signup', function(req, res) { 158 | res.render('signup.ejs', { message: req.flash('signupMessage') }); 159 | }); 160 | 161 | // process the signup form 162 | app.post('/signup', passport.authenticate('local-signup', { 163 | successRedirect : '/profile', // redirect to the secure profile section 164 | failureRedirect : '/signup', // redirect back to the signup page if there is an error 165 | failureFlash : true // allow flash messages 166 | })); 167 | 168 | // ============================================================================= 169 | // UNLINK ACCOUNTS ============================================================= 170 | // ============================================================================= 171 | // used to unlink accounts. for social accounts, just remove the token 172 | // for local account, remove email and password 173 | // user account will stay active in case they want to reconnect in the future 174 | 175 | // local ----------------------------------- 176 | app.get('/unlink/local', isLoggedIn, function(req, res) { 177 | var user = req.user; 178 | user.local.email = undefined; 179 | user.local.password = undefined; 180 | user.save(function(err) { 181 | res.redirect('/profile'); 182 | }); 183 | }); 184 | 185 | }; 186 | 187 | // route middleware to ensure user is logged in 188 | function isLoggedIn(req, res, next) { 189 | if (req.isAuthenticated()) 190 | return next(); 191 | 192 | res.redirect('/'); 193 | } 194 | -------------------------------------------------------------------------------- /config/database.js: -------------------------------------------------------------------------------- 1 | // config/database.js 2 | module.exports = { 3 | 4 | 'url' : 'mongodb+srv://shawn:shawnpassword@cluster0.ml67f.mongodb.net/demo?retryWrites=true&w=majority', // looks like mongodb://:@mongo.onmodulus.net:27017/Mikha4ot 5 | 'dbName': 'demo' 6 | }; 7 | -------------------------------------------------------------------------------- /config/passport.js: -------------------------------------------------------------------------------- 1 | // config/passport.js 2 | 3 | // load all the things we need 4 | var LocalStrategy = require('passport-local').Strategy; 5 | 6 | // load up the user model 7 | var User = require('../app/models/user'); 8 | 9 | // expose this function to our app using module.exports 10 | module.exports = function(passport) { 11 | 12 | // ========================================================================= 13 | // passport session setup ================================================== 14 | // ========================================================================= 15 | // required for persistent login sessions 16 | // passport needs ability to serialize and unserialize users out of session 17 | 18 | // used to serialize the user for the session 19 | passport.serializeUser(function(user, done) { 20 | done(null, user.id); 21 | }); 22 | 23 | // used to deserialize the user 24 | passport.deserializeUser(function(id, done) { 25 | User.findById(id, function(err, user) { 26 | done(err, user); 27 | }); 28 | }); 29 | 30 | // ========================================================================= 31 | // LOCAL SIGNUP ============================================================ 32 | // ========================================================================= 33 | // we are using named strategies since we have one for login and one for signup 34 | // by default, if there was no name, it would just be called 'local' 35 | 36 | passport.use('local-signup', new LocalStrategy({ 37 | // by default, local strategy uses username and password, we will override with email 38 | usernameField : 'email', 39 | passwordField : 'password', 40 | passReqToCallback : true // allows us to pass back the entire request to the callback 41 | }, 42 | function(req, email, password, done) { 43 | 44 | // find a user whose email is the same as the forms email 45 | // we are checking to see if the user trying to login already exists 46 | User.findOne({ 'local.email' : email }, function(err, user) { 47 | // if there are any errors, return the error 48 | if (err) 49 | return done(err); 50 | 51 | // check to see if theres already a user with that email 52 | if (user) { 53 | return done(null, false, req.flash('signupMessage', 'That email is already taken.')); 54 | } else { 55 | 56 | // if there is no user with that email 57 | // create the user 58 | var newUser = new User(); 59 | 60 | // set the user's local credentials 61 | newUser.local.email = email; 62 | newUser.local.password = newUser.generateHash(password); // use the generateHash function in our user model 63 | 64 | // save the user 65 | newUser.save(function(err) { 66 | if (err) 67 | throw err; 68 | return done(null, newUser); 69 | }); 70 | } 71 | 72 | }); 73 | 74 | })); 75 | 76 | // ========================================================================= 77 | // LOCAL LOGIN ============================================================= 78 | // ========================================================================= 79 | // we are using named strategies since we have one for login and one for signup 80 | // by default, if there was no name, it would just be called 'local' 81 | 82 | passport.use('local-login', new LocalStrategy({ 83 | // by default, local strategy uses username and password, we will override with email 84 | usernameField : 'email', 85 | passwordField : 'password', 86 | passReqToCallback : true // allows us to pass back the entire request to the callback 87 | }, 88 | function(req, email, password, done) { // callback with email and password from our form 89 | 90 | // find a user whose email is the same as the forms email 91 | // we are checking to see if the user trying to login already exists 92 | User.findOne({ 'local.email' : email }, function(err, user) { 93 | // if there are any errors, return the error before anything else 94 | if (err) 95 | return done(err); 96 | 97 | // if no user is found, return the message 98 | if (!user) 99 | return done(null, false, req.flash('loginMessage', 'No user found.')); // req.flash is the way to set flashdata using connect-flash 100 | 101 | // if the user is found but the password is wrong 102 | if (!user.validPassword(password)) 103 | return done(null, false, req.flash('loginMessage', 'Oops! Wrong password.')); // create the loginMessage and save it to session as flashdata 104 | 105 | // all is well, return successful user 106 | return done(null, user); 107 | }); 108 | 109 | })); 110 | 111 | }; 112 | -------------------------------------------------------------------------------- /package-lock.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "node-authentication", 3 | "requires": true, 4 | "lockfileVersion": 1, 5 | "dependencies": { 6 | "accepts": { 7 | "version": "1.3.7", 8 | "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz", 9 | "integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==", 10 | "requires": { 11 | "mime-types": "~2.1.24", 12 | "negotiator": "0.6.2" 13 | } 14 | }, 15 | "array-flatten": { 16 | "version": "1.1.1", 17 | "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", 18 | "integrity": "sha1-ml9pkFGx5wczKPKgCJaLZOopVdI=" 19 | }, 20 | "base64url": { 21 | "version": "3.0.1", 22 | "resolved": "https://registry.npmjs.org/base64url/-/base64url-3.0.1.tgz", 23 | "integrity": "sha512-ir1UPr3dkwexU7FdV8qBBbNDRUhMmIekYMFZfi+C/sLNnRESKPl23nB9b2pltqfOQNnGzsDdId90AEtG5tCx4A==" 24 | }, 25 | "basic-auth": { 26 | "version": "2.0.1", 27 | "resolved": "https://registry.npmjs.org/basic-auth/-/basic-auth-2.0.1.tgz", 28 | "integrity": "sha512-NF+epuEdnUYVlGuhaxbbq+dvJttwLnGY+YixlXlME5KpQ5W3CnXA5cVTneY3SPbPDRkcjMbifrwmFYcClgOZeg==", 29 | "requires": { 30 | "safe-buffer": "5.1.2" 31 | } 32 | }, 33 | "bcrypt-nodejs": { 34 | "version": "0.0.3", 35 | "resolved": "https://registry.npmjs.org/bcrypt-nodejs/-/bcrypt-nodejs-0.0.3.tgz", 36 | "integrity": "sha1-xgkX8m3CNWYVZsaBBhwwPCsohCs=" 37 | }, 38 | "bl": { 39 | "version": "2.2.1", 40 | "resolved": "https://registry.npmjs.org/bl/-/bl-2.2.1.tgz", 41 | "integrity": "sha512-6Pesp1w0DEX1N550i/uGV/TqucVL4AM/pgThFSN/Qq9si1/DF9aIHs1BxD8V/QU0HoeHO6cQRTAuYnLPKq1e4g==", 42 | "requires": { 43 | "readable-stream": "^2.3.5", 44 | "safe-buffer": "^5.1.1" 45 | } 46 | }, 47 | "bluebird": { 48 | "version": "3.5.1", 49 | "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.5.1.tgz", 50 | "integrity": "sha512-MKiLiV+I1AA596t9w1sQJ8jkiSr5+ZKi0WKrYGUn6d1Fx+Ij4tIj+m2WMQSGczs5jZVxV339chE8iwk6F64wjA==" 51 | }, 52 | "body-parser": { 53 | "version": "1.19.0", 54 | "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz", 55 | "integrity": "sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw==", 56 | "requires": { 57 | "bytes": "3.1.0", 58 | "content-type": "~1.0.4", 59 | "debug": "2.6.9", 60 | "depd": "~1.1.2", 61 | "http-errors": "1.7.2", 62 | "iconv-lite": "0.4.24", 63 | "on-finished": "~2.3.0", 64 | "qs": "6.7.0", 65 | "raw-body": "2.4.0", 66 | "type-is": "~1.6.17" 67 | } 68 | }, 69 | "bson": { 70 | "version": "1.1.3", 71 | "resolved": "https://registry.npmjs.org/bson/-/bson-1.1.3.tgz", 72 | "integrity": "sha512-TdiJxMVnodVS7r0BdL42y/pqC9cL2iKynVwA0Ho3qbsQYr428veL3l7BQyuqiw+Q5SqqoT0m4srSY/BlZ9AxXg==" 73 | }, 74 | "bytes": { 75 | "version": "3.1.0", 76 | "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz", 77 | "integrity": "sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg==" 78 | }, 79 | "connect-flash": { 80 | "version": "0.1.1", 81 | "resolved": "https://registry.npmjs.org/connect-flash/-/connect-flash-0.1.1.tgz", 82 | "integrity": "sha1-2GMPJtlaf4UfmVax6MxnMvO2qjA=" 83 | }, 84 | "content-disposition": { 85 | "version": "0.5.3", 86 | "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.3.tgz", 87 | "integrity": "sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g==", 88 | "requires": { 89 | "safe-buffer": "5.1.2" 90 | } 91 | }, 92 | "content-type": { 93 | "version": "1.0.4", 94 | "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz", 95 | "integrity": "sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA==" 96 | }, 97 | "cookie": { 98 | "version": "0.4.0", 99 | "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz", 100 | "integrity": "sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg==" 101 | }, 102 | "cookie-parser": { 103 | "version": "1.4.5", 104 | "resolved": "https://registry.npmjs.org/cookie-parser/-/cookie-parser-1.4.5.tgz", 105 | "integrity": "sha512-f13bPUj/gG/5mDr+xLmSxxDsB9DQiTIfhJS/sqjrmfAWiAN+x2O4i/XguTL9yDZ+/IFDanJ+5x7hC4CXT9Tdzw==", 106 | "requires": { 107 | "cookie": "0.4.0", 108 | "cookie-signature": "1.0.6" 109 | } 110 | }, 111 | "cookie-signature": { 112 | "version": "1.0.6", 113 | "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz", 114 | "integrity": "sha1-4wOogrNCzD7oylE6eZmXNNqzriw=" 115 | }, 116 | "core-util-is": { 117 | "version": "1.0.2", 118 | "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", 119 | "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" 120 | }, 121 | "debug": { 122 | "version": "2.6.9", 123 | "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", 124 | "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", 125 | "requires": { 126 | "ms": "2.0.0" 127 | } 128 | }, 129 | "denque": { 130 | "version": "1.4.1", 131 | "resolved": "https://registry.npmjs.org/denque/-/denque-1.4.1.tgz", 132 | "integrity": "sha512-OfzPuSZKGcgr96rf1oODnfjqBFmr1DVoc/TrItj3Ohe0Ah1C5WX5Baquw/9U9KovnQ88EqmJbD66rKYUQYN1tQ==" 133 | }, 134 | "depd": { 135 | "version": "1.1.2", 136 | "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", 137 | "integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak=" 138 | }, 139 | "destroy": { 140 | "version": "1.0.4", 141 | "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz", 142 | "integrity": "sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA=" 143 | }, 144 | "ee-first": { 145 | "version": "1.1.1", 146 | "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", 147 | "integrity": "sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=" 148 | }, 149 | "ejs": { 150 | "version": "2.5.9", 151 | "resolved": "https://registry.npmjs.org/ejs/-/ejs-2.5.9.tgz", 152 | "integrity": "sha512-GJCAeDBKfREgkBtgrYSf9hQy9kTb3helv0zGdzqhM7iAkW8FA/ZF97VQDbwFiwIT8MQLLOe5VlPZOEvZAqtUAQ==" 153 | }, 154 | "encodeurl": { 155 | "version": "1.0.2", 156 | "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", 157 | "integrity": "sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k=" 158 | }, 159 | "escape-html": { 160 | "version": "1.0.3", 161 | "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", 162 | "integrity": "sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg=" 163 | }, 164 | "etag": { 165 | "version": "1.8.1", 166 | "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", 167 | "integrity": "sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc=" 168 | }, 169 | "express": { 170 | "version": "4.17.1", 171 | "resolved": "https://registry.npmjs.org/express/-/express-4.17.1.tgz", 172 | "integrity": "sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g==", 173 | "requires": { 174 | "accepts": "~1.3.7", 175 | "array-flatten": "1.1.1", 176 | "body-parser": "1.19.0", 177 | "content-disposition": "0.5.3", 178 | "content-type": "~1.0.4", 179 | "cookie": "0.4.0", 180 | "cookie-signature": "1.0.6", 181 | "debug": "2.6.9", 182 | "depd": "~1.1.2", 183 | "encodeurl": "~1.0.2", 184 | "escape-html": "~1.0.3", 185 | "etag": "~1.8.1", 186 | "finalhandler": "~1.1.2", 187 | "fresh": "0.5.2", 188 | "merge-descriptors": "1.0.1", 189 | "methods": "~1.1.2", 190 | "on-finished": "~2.3.0", 191 | "parseurl": "~1.3.3", 192 | "path-to-regexp": "0.1.7", 193 | "proxy-addr": "~2.0.5", 194 | "qs": "6.7.0", 195 | "range-parser": "~1.2.1", 196 | "safe-buffer": "5.1.2", 197 | "send": "0.17.1", 198 | "serve-static": "1.14.1", 199 | "setprototypeof": "1.1.1", 200 | "statuses": "~1.5.0", 201 | "type-is": "~1.6.18", 202 | "utils-merge": "1.0.1", 203 | "vary": "~1.1.2" 204 | } 205 | }, 206 | "express-session": { 207 | "version": "1.17.0", 208 | "resolved": "https://registry.npmjs.org/express-session/-/express-session-1.17.0.tgz", 209 | "integrity": "sha512-t4oX2z7uoSqATbMfsxWMbNjAL0T5zpvcJCk3Z9wnPPN7ibddhnmDZXHfEcoBMG2ojKXZoCyPMc5FbtK+G7SoDg==", 210 | "requires": { 211 | "cookie": "0.4.0", 212 | "cookie-signature": "1.0.6", 213 | "debug": "2.6.9", 214 | "depd": "~2.0.0", 215 | "on-headers": "~1.0.2", 216 | "parseurl": "~1.3.3", 217 | "safe-buffer": "5.2.0", 218 | "uid-safe": "~2.1.5" 219 | }, 220 | "dependencies": { 221 | "depd": { 222 | "version": "2.0.0", 223 | "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", 224 | "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==" 225 | }, 226 | "safe-buffer": { 227 | "version": "5.2.0", 228 | "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz", 229 | "integrity": "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==" 230 | } 231 | } 232 | }, 233 | "finalhandler": { 234 | "version": "1.1.2", 235 | "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz", 236 | "integrity": "sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA==", 237 | "requires": { 238 | "debug": "2.6.9", 239 | "encodeurl": "~1.0.2", 240 | "escape-html": "~1.0.3", 241 | "on-finished": "~2.3.0", 242 | "parseurl": "~1.3.3", 243 | "statuses": "~1.5.0", 244 | "unpipe": "~1.0.0" 245 | } 246 | }, 247 | "forwarded": { 248 | "version": "0.1.2", 249 | "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.1.2.tgz", 250 | "integrity": "sha1-mMI9qxF1ZXuMBXPozszZGw/xjIQ=" 251 | }, 252 | "fresh": { 253 | "version": "0.5.2", 254 | "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", 255 | "integrity": "sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac=" 256 | }, 257 | "http-errors": { 258 | "version": "1.7.2", 259 | "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.7.2.tgz", 260 | "integrity": "sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg==", 261 | "requires": { 262 | "depd": "~1.1.2", 263 | "inherits": "2.0.3", 264 | "setprototypeof": "1.1.1", 265 | "statuses": ">= 1.5.0 < 2", 266 | "toidentifier": "1.0.0" 267 | } 268 | }, 269 | "iconv-lite": { 270 | "version": "0.4.24", 271 | "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", 272 | "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", 273 | "requires": { 274 | "safer-buffer": ">= 2.1.2 < 3" 275 | } 276 | }, 277 | "inherits": { 278 | "version": "2.0.3", 279 | "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", 280 | "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" 281 | }, 282 | "ipaddr.js": { 283 | "version": "1.9.1", 284 | "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", 285 | "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==" 286 | }, 287 | "isarray": { 288 | "version": "1.0.0", 289 | "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", 290 | "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" 291 | }, 292 | "kareem": { 293 | "version": "2.3.1", 294 | "resolved": "https://registry.npmjs.org/kareem/-/kareem-2.3.1.tgz", 295 | "integrity": "sha512-l3hLhffs9zqoDe8zjmb/mAN4B8VT3L56EUvKNqLFVs9YlFA+zx7ke1DO8STAdDyYNkeSo1nKmjuvQeI12So8Xw==" 296 | }, 297 | "lodash": { 298 | "version": "4.17.20", 299 | "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", 300 | "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==" 301 | }, 302 | "media-typer": { 303 | "version": "0.3.0", 304 | "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", 305 | "integrity": "sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g=" 306 | }, 307 | "memory-pager": { 308 | "version": "1.5.0", 309 | "resolved": "https://registry.npmjs.org/memory-pager/-/memory-pager-1.5.0.tgz", 310 | "integrity": "sha512-ZS4Bp4r/Zoeq6+NLJpP+0Zzm0pR8whtGPf1XExKLJBAczGMnSi3It14OiNCStjQjM6NU1okjQGSxgEZN8eBYKg==", 311 | "optional": true 312 | }, 313 | "merge-descriptors": { 314 | "version": "1.0.1", 315 | "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", 316 | "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E=" 317 | }, 318 | "method-override": { 319 | "version": "2.3.10", 320 | "resolved": "https://registry.npmjs.org/method-override/-/method-override-2.3.10.tgz", 321 | "integrity": "sha1-49r41d7hDdLc59SuiNYrvud0drQ=", 322 | "requires": { 323 | "debug": "2.6.9", 324 | "methods": "~1.1.2", 325 | "parseurl": "~1.3.2", 326 | "vary": "~1.1.2" 327 | } 328 | }, 329 | "methods": { 330 | "version": "1.1.2", 331 | "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", 332 | "integrity": "sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4=" 333 | }, 334 | "mime": { 335 | "version": "1.6.0", 336 | "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", 337 | "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==" 338 | }, 339 | "mime-db": { 340 | "version": "1.43.0", 341 | "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.43.0.tgz", 342 | "integrity": "sha512-+5dsGEEovYbT8UY9yD7eE4XTc4UwJ1jBYlgaQQF38ENsKR3wj/8q8RFZrF9WIZpB2V1ArTVFUva8sAul1NzRzQ==" 343 | }, 344 | "mime-types": { 345 | "version": "2.1.26", 346 | "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.26.tgz", 347 | "integrity": "sha512-01paPWYgLrkqAyrlDorC1uDwl2p3qZT7yl806vW7DvDoxwXi46jsjFbg+WdwotBIk6/MbEhO/dh5aZ5sNj/dWQ==", 348 | "requires": { 349 | "mime-db": "1.43.0" 350 | } 351 | }, 352 | "mongodb": { 353 | "version": "3.5.5", 354 | "resolved": "https://registry.npmjs.org/mongodb/-/mongodb-3.5.5.tgz", 355 | "integrity": "sha512-GCjDxR3UOltDq00Zcpzql6dQo1sVry60OXJY3TDmFc2SWFY6c8Gn1Ardidc5jDirvJrx2GC3knGOImKphbSL3A==", 356 | "requires": { 357 | "bl": "^2.2.0", 358 | "bson": "^1.1.1", 359 | "denque": "^1.4.1", 360 | "require_optional": "^1.0.1", 361 | "safe-buffer": "^5.1.2", 362 | "saslprep": "^1.0.0" 363 | } 364 | }, 365 | "mongoose": { 366 | "version": "5.9.5", 367 | "resolved": "https://registry.npmjs.org/mongoose/-/mongoose-5.9.5.tgz", 368 | "integrity": "sha512-2kMNZCZRWCMtww4f//CwdGH6BjO3+9/c3YdsC6nbzdJVyl8+GRtNfgrKUge3226VZXXLJa6LwxXN2K8/Dh4irg==", 369 | "requires": { 370 | "bson": "~1.1.1", 371 | "kareem": "2.3.1", 372 | "mongodb": "3.5.5", 373 | "mongoose-legacy-pluralize": "1.0.2", 374 | "mpath": "0.6.0", 375 | "mquery": "3.2.2", 376 | "ms": "2.1.2", 377 | "regexp-clone": "1.0.0", 378 | "safe-buffer": "5.1.2", 379 | "sift": "7.0.1", 380 | "sliced": "1.0.1" 381 | }, 382 | "dependencies": { 383 | "ms": { 384 | "version": "2.1.2", 385 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", 386 | "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" 387 | } 388 | } 389 | }, 390 | "mongoose-legacy-pluralize": { 391 | "version": "1.0.2", 392 | "resolved": "https://registry.npmjs.org/mongoose-legacy-pluralize/-/mongoose-legacy-pluralize-1.0.2.tgz", 393 | "integrity": "sha512-Yo/7qQU4/EyIS8YDFSeenIvXxZN+ld7YdV9LqFVQJzTLye8unujAWPZ4NWKfFA+RNjh+wvTWKY9Z3E5XM6ZZiQ==" 394 | }, 395 | "morgan": { 396 | "version": "1.9.1", 397 | "resolved": "https://registry.npmjs.org/morgan/-/morgan-1.9.1.tgz", 398 | "integrity": "sha512-HQStPIV4y3afTiCYVxirakhlCfGkI161c76kKFca7Fk1JusM//Qeo1ej2XaMniiNeaZklMVrh3vTtIzpzwbpmA==", 399 | "requires": { 400 | "basic-auth": "~2.0.0", 401 | "debug": "2.6.9", 402 | "depd": "~1.1.2", 403 | "on-finished": "~2.3.0", 404 | "on-headers": "~1.0.1" 405 | } 406 | }, 407 | "mpath": { 408 | "version": "0.6.0", 409 | "resolved": "https://registry.npmjs.org/mpath/-/mpath-0.6.0.tgz", 410 | "integrity": "sha512-i75qh79MJ5Xo/sbhxrDrPSEG0H/mr1kcZXJ8dH6URU5jD/knFxCVqVC/gVSW7GIXL/9hHWlT9haLbCXWOll3qw==" 411 | }, 412 | "mquery": { 413 | "version": "3.2.2", 414 | "resolved": "https://registry.npmjs.org/mquery/-/mquery-3.2.2.tgz", 415 | "integrity": "sha512-XB52992COp0KP230I3qloVUbkLUxJIu328HBP2t2EsxSFtf4W1HPSOBWOXf1bqxK4Xbb66lfMJ+Bpfd9/yZE1Q==", 416 | "requires": { 417 | "bluebird": "3.5.1", 418 | "debug": "3.1.0", 419 | "regexp-clone": "^1.0.0", 420 | "safe-buffer": "5.1.2", 421 | "sliced": "1.0.1" 422 | }, 423 | "dependencies": { 424 | "debug": { 425 | "version": "3.1.0", 426 | "resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz", 427 | "integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==", 428 | "requires": { 429 | "ms": "2.0.0" 430 | } 431 | } 432 | } 433 | }, 434 | "ms": { 435 | "version": "2.0.0", 436 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", 437 | "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" 438 | }, 439 | "negotiator": { 440 | "version": "0.6.2", 441 | "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz", 442 | "integrity": "sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw==" 443 | }, 444 | "oauth": { 445 | "version": "0.9.15", 446 | "resolved": "https://registry.npmjs.org/oauth/-/oauth-0.9.15.tgz", 447 | "integrity": "sha1-vR/vr2hslrdUda7VGWQS/2DPucE=" 448 | }, 449 | "on-finished": { 450 | "version": "2.3.0", 451 | "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz", 452 | "integrity": "sha1-IPEzZIGwg811M3mSoWlxqi2QaUc=", 453 | "requires": { 454 | "ee-first": "1.1.1" 455 | } 456 | }, 457 | "on-headers": { 458 | "version": "1.0.2", 459 | "resolved": "https://registry.npmjs.org/on-headers/-/on-headers-1.0.2.tgz", 460 | "integrity": "sha512-pZAE+FJLoyITytdqK0U5s+FIpjN0JP3OzFi/u8Rx+EV5/W+JTWGXG8xFzevE7AjBfDqHv/8vL8qQsIhHnqRkrA==" 461 | }, 462 | "parseurl": { 463 | "version": "1.3.3", 464 | "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", 465 | "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==" 466 | }, 467 | "passport": { 468 | "version": "0.3.2", 469 | "resolved": "https://registry.npmjs.org/passport/-/passport-0.3.2.tgz", 470 | "integrity": "sha1-ndAJ+RXo/glbASSgG4+C2gdRAQI=", 471 | "requires": { 472 | "passport-strategy": "1.x.x", 473 | "pause": "0.0.1" 474 | } 475 | }, 476 | "passport-facebook": { 477 | "version": "2.1.1", 478 | "resolved": "https://registry.npmjs.org/passport-facebook/-/passport-facebook-2.1.1.tgz", 479 | "integrity": "sha1-w50LUq5NWRYyRaTiGnubYyEwMxE=", 480 | "requires": { 481 | "passport-oauth2": "1.x.x" 482 | } 483 | }, 484 | "passport-google-oauth": { 485 | "version": "1.0.0", 486 | "resolved": "https://registry.npmjs.org/passport-google-oauth/-/passport-google-oauth-1.0.0.tgz", 487 | "integrity": "sha1-ZfUGMxkq0GJ6GLCJYAdxCdhOt20=", 488 | "requires": { 489 | "passport-google-oauth1": "1.x.x", 490 | "passport-google-oauth20": "1.x.x" 491 | } 492 | }, 493 | "passport-google-oauth1": { 494 | "version": "1.0.0", 495 | "resolved": "https://registry.npmjs.org/passport-google-oauth1/-/passport-google-oauth1-1.0.0.tgz", 496 | "integrity": "sha1-r3SoA99R7GRvZqRNgigr5vEI4Mw=", 497 | "requires": { 498 | "passport-oauth1": "1.x.x" 499 | } 500 | }, 501 | "passport-google-oauth20": { 502 | "version": "1.0.0", 503 | "resolved": "https://registry.npmjs.org/passport-google-oauth20/-/passport-google-oauth20-1.0.0.tgz", 504 | "integrity": "sha1-O5YOih1w0dvnlGFcgnxoxAOSpdA=", 505 | "requires": { 506 | "passport-oauth2": "1.x.x" 507 | } 508 | }, 509 | "passport-local": { 510 | "version": "1.0.0", 511 | "resolved": "https://registry.npmjs.org/passport-local/-/passport-local-1.0.0.tgz", 512 | "integrity": "sha1-H+YyaMkudWBmJkN+O5BmYsFbpu4=", 513 | "requires": { 514 | "passport-strategy": "1.x.x" 515 | } 516 | }, 517 | "passport-oauth1": { 518 | "version": "1.1.0", 519 | "resolved": "https://registry.npmjs.org/passport-oauth1/-/passport-oauth1-1.1.0.tgz", 520 | "integrity": "sha1-p96YiiEfnPRoc3cTDqdN8ycwyRg=", 521 | "requires": { 522 | "oauth": "0.9.x", 523 | "passport-strategy": "1.x.x", 524 | "utils-merge": "1.x.x" 525 | } 526 | }, 527 | "passport-oauth2": { 528 | "version": "1.5.0", 529 | "resolved": "https://registry.npmjs.org/passport-oauth2/-/passport-oauth2-1.5.0.tgz", 530 | "integrity": "sha512-kqBt6vR/5VlCK8iCx1/KpY42kQ+NEHZwsSyt4Y6STiNjU+wWICG1i8ucc1FapXDGO15C5O5VZz7+7vRzrDPXXQ==", 531 | "requires": { 532 | "base64url": "3.x.x", 533 | "oauth": "0.9.x", 534 | "passport-strategy": "1.x.x", 535 | "uid2": "0.0.x", 536 | "utils-merge": "1.x.x" 537 | } 538 | }, 539 | "passport-strategy": { 540 | "version": "1.0.0", 541 | "resolved": "https://registry.npmjs.org/passport-strategy/-/passport-strategy-1.0.0.tgz", 542 | "integrity": "sha1-tVOaqPwiWj0a0XlHbd8ja0QPUuQ=" 543 | }, 544 | "passport-twitter": { 545 | "version": "1.0.4", 546 | "resolved": "https://registry.npmjs.org/passport-twitter/-/passport-twitter-1.0.4.tgz", 547 | "integrity": "sha1-AaeZ4fdgvy3knyul+6MigvGJMtc=", 548 | "requires": { 549 | "passport-oauth1": "1.x.x", 550 | "xtraverse": "0.1.x" 551 | } 552 | }, 553 | "path-to-regexp": { 554 | "version": "0.1.7", 555 | "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", 556 | "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=" 557 | }, 558 | "pause": { 559 | "version": "0.0.1", 560 | "resolved": "https://registry.npmjs.org/pause/-/pause-0.0.1.tgz", 561 | "integrity": "sha1-HUCLP9t2kjuVQ9lvtMnf1TXZy10=" 562 | }, 563 | "process-nextick-args": { 564 | "version": "2.0.1", 565 | "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", 566 | "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" 567 | }, 568 | "proxy-addr": { 569 | "version": "2.0.6", 570 | "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.6.tgz", 571 | "integrity": "sha512-dh/frvCBVmSsDYzw6n926jv974gddhkFPfiN8hPOi30Wax25QZyZEGveluCgliBnqmuM+UJmBErbAUFIoDbjOw==", 572 | "requires": { 573 | "forwarded": "~0.1.2", 574 | "ipaddr.js": "1.9.1" 575 | } 576 | }, 577 | "qs": { 578 | "version": "6.7.0", 579 | "resolved": "https://registry.npmjs.org/qs/-/qs-6.7.0.tgz", 580 | "integrity": "sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ==" 581 | }, 582 | "random-bytes": { 583 | "version": "1.0.0", 584 | "resolved": "https://registry.npmjs.org/random-bytes/-/random-bytes-1.0.0.tgz", 585 | "integrity": "sha1-T2ih3Arli9P7lYSMMDJNt11kNgs=" 586 | }, 587 | "range-parser": { 588 | "version": "1.2.1", 589 | "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", 590 | "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==" 591 | }, 592 | "raw-body": { 593 | "version": "2.4.0", 594 | "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.4.0.tgz", 595 | "integrity": "sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q==", 596 | "requires": { 597 | "bytes": "3.1.0", 598 | "http-errors": "1.7.2", 599 | "iconv-lite": "0.4.24", 600 | "unpipe": "1.0.0" 601 | } 602 | }, 603 | "readable-stream": { 604 | "version": "2.3.7", 605 | "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", 606 | "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", 607 | "requires": { 608 | "core-util-is": "~1.0.0", 609 | "inherits": "~2.0.3", 610 | "isarray": "~1.0.0", 611 | "process-nextick-args": "~2.0.0", 612 | "safe-buffer": "~5.1.1", 613 | "string_decoder": "~1.1.1", 614 | "util-deprecate": "~1.0.1" 615 | } 616 | }, 617 | "regexp-clone": { 618 | "version": "1.0.0", 619 | "resolved": "https://registry.npmjs.org/regexp-clone/-/regexp-clone-1.0.0.tgz", 620 | "integrity": "sha512-TuAasHQNamyyJ2hb97IuBEif4qBHGjPHBS64sZwytpLEqtBQ1gPJTnOaQ6qmpET16cK14kkjbazl6+p0RRv0yw==" 621 | }, 622 | "require_optional": { 623 | "version": "1.0.1", 624 | "resolved": "https://registry.npmjs.org/require_optional/-/require_optional-1.0.1.tgz", 625 | "integrity": "sha512-qhM/y57enGWHAe3v/NcwML6a3/vfESLe/sGM2dII+gEO0BpKRUkWZow/tyloNqJyN6kXSl3RyyM8Ll5D/sJP8g==", 626 | "requires": { 627 | "resolve-from": "^2.0.0", 628 | "semver": "^5.1.0" 629 | } 630 | }, 631 | "resolve-from": { 632 | "version": "2.0.0", 633 | "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-2.0.0.tgz", 634 | "integrity": "sha1-lICrIOlP+h2egKgEx+oUdhGWa1c=" 635 | }, 636 | "safe-buffer": { 637 | "version": "5.1.2", 638 | "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", 639 | "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" 640 | }, 641 | "safer-buffer": { 642 | "version": "2.1.2", 643 | "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", 644 | "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" 645 | }, 646 | "saslprep": { 647 | "version": "1.0.3", 648 | "resolved": "https://registry.npmjs.org/saslprep/-/saslprep-1.0.3.tgz", 649 | "integrity": "sha512-/MY/PEMbk2SuY5sScONwhUDsV2p77Znkb/q3nSVstq/yQzYJOH/Azh29p9oJLsl3LnQwSvZDKagDGBsBwSooag==", 650 | "optional": true, 651 | "requires": { 652 | "sparse-bitfield": "^3.0.3" 653 | } 654 | }, 655 | "semver": { 656 | "version": "5.7.1", 657 | "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", 658 | "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" 659 | }, 660 | "send": { 661 | "version": "0.17.1", 662 | "resolved": "https://registry.npmjs.org/send/-/send-0.17.1.tgz", 663 | "integrity": "sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg==", 664 | "requires": { 665 | "debug": "2.6.9", 666 | "depd": "~1.1.2", 667 | "destroy": "~1.0.4", 668 | "encodeurl": "~1.0.2", 669 | "escape-html": "~1.0.3", 670 | "etag": "~1.8.1", 671 | "fresh": "0.5.2", 672 | "http-errors": "~1.7.2", 673 | "mime": "1.6.0", 674 | "ms": "2.1.1", 675 | "on-finished": "~2.3.0", 676 | "range-parser": "~1.2.1", 677 | "statuses": "~1.5.0" 678 | }, 679 | "dependencies": { 680 | "ms": { 681 | "version": "2.1.1", 682 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", 683 | "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==" 684 | } 685 | } 686 | }, 687 | "serve-static": { 688 | "version": "1.14.1", 689 | "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.14.1.tgz", 690 | "integrity": "sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg==", 691 | "requires": { 692 | "encodeurl": "~1.0.2", 693 | "escape-html": "~1.0.3", 694 | "parseurl": "~1.3.3", 695 | "send": "0.17.1" 696 | } 697 | }, 698 | "setprototypeof": { 699 | "version": "1.1.1", 700 | "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.1.tgz", 701 | "integrity": "sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw==" 702 | }, 703 | "sift": { 704 | "version": "7.0.1", 705 | "resolved": "https://registry.npmjs.org/sift/-/sift-7.0.1.tgz", 706 | "integrity": "sha512-oqD7PMJ+uO6jV9EQCl0LrRw1OwsiPsiFQR5AR30heR+4Dl7jBBbDLnNvWiak20tzZlSE1H7RB30SX/1j/YYT7g==" 707 | }, 708 | "sliced": { 709 | "version": "1.0.1", 710 | "resolved": "https://registry.npmjs.org/sliced/-/sliced-1.0.1.tgz", 711 | "integrity": "sha1-CzpmK10Ewxd7GSa+qCsD+Dei70E=" 712 | }, 713 | "sparse-bitfield": { 714 | "version": "3.0.3", 715 | "resolved": "https://registry.npmjs.org/sparse-bitfield/-/sparse-bitfield-3.0.3.tgz", 716 | "integrity": "sha1-/0rm5oZWBWuks+eSqzM004JzyhE=", 717 | "optional": true, 718 | "requires": { 719 | "memory-pager": "^1.0.2" 720 | } 721 | }, 722 | "statuses": { 723 | "version": "1.5.0", 724 | "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", 725 | "integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow=" 726 | }, 727 | "string_decoder": { 728 | "version": "1.1.1", 729 | "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", 730 | "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", 731 | "requires": { 732 | "safe-buffer": "~5.1.0" 733 | } 734 | }, 735 | "toidentifier": { 736 | "version": "1.0.0", 737 | "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz", 738 | "integrity": "sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==" 739 | }, 740 | "type-is": { 741 | "version": "1.6.18", 742 | "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz", 743 | "integrity": "sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==", 744 | "requires": { 745 | "media-typer": "0.3.0", 746 | "mime-types": "~2.1.24" 747 | } 748 | }, 749 | "uid-safe": { 750 | "version": "2.1.5", 751 | "resolved": "https://registry.npmjs.org/uid-safe/-/uid-safe-2.1.5.tgz", 752 | "integrity": "sha512-KPHm4VL5dDXKz01UuEd88Df+KzynaohSL9fBh096KWAxSKZQDI2uBrVqtvRM4rwrIrRRKsdLNML/lnaaVSRioA==", 753 | "requires": { 754 | "random-bytes": "~1.0.0" 755 | } 756 | }, 757 | "uid2": { 758 | "version": "0.0.3", 759 | "resolved": "https://registry.npmjs.org/uid2/-/uid2-0.0.3.tgz", 760 | "integrity": "sha1-SDEm4Rd03y9xuLY53NeZw3YWK4I=" 761 | }, 762 | "unpipe": { 763 | "version": "1.0.0", 764 | "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", 765 | "integrity": "sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw=" 766 | }, 767 | "util-deprecate": { 768 | "version": "1.0.2", 769 | "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", 770 | "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" 771 | }, 772 | "utils-merge": { 773 | "version": "1.0.1", 774 | "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", 775 | "integrity": "sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM=" 776 | }, 777 | "vary": { 778 | "version": "1.1.2", 779 | "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", 780 | "integrity": "sha1-IpnwLG3tMNSllhsLn3RSShj2NPw=" 781 | }, 782 | "xmldom": { 783 | "version": "0.1.31", 784 | "resolved": "https://registry.npmjs.org/xmldom/-/xmldom-0.1.31.tgz", 785 | "integrity": "sha512-yS2uJflVQs6n+CyjHoaBmVSqIDevTAWrzMmjG1Gc7h1qQ7uVozNhEPJAwZXWyGQ/Gafo3fCwrcaokezLPupVyQ==" 786 | }, 787 | "xtraverse": { 788 | "version": "0.1.0", 789 | "resolved": "https://registry.npmjs.org/xtraverse/-/xtraverse-0.1.0.tgz", 790 | "integrity": "sha1-t0G60BjveNip0ug63gB7P3lZxzI=", 791 | "requires": { 792 | "xmldom": "0.1.x" 793 | } 794 | } 795 | } 796 | } 797 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "node-authentication", 3 | "main": "server.js", 4 | "dependencies": { 5 | "bcrypt-nodejs": "latest", 6 | "body-parser": "^1.18.3", 7 | "connect-flash": "~0.1.1", 8 | "cookie-parser": "~1.4.3", 9 | "ejs": "~2.5.2", 10 | "express": "^4.16.4", 11 | "express-session": "^1.15.6", 12 | "lodash": "^4.17.20", 13 | "method-override": "~2.3.6", 14 | "mongodb": "^3.3.4", 15 | "mongoose": ">=5.7.5", 16 | "morgan": "^1.9.1", 17 | "mpath": ">=0.5.1", 18 | "passport": "~0.3.2", 19 | "passport-facebook": "~2.1.1", 20 | "passport-google-oauth": "~1.0.0", 21 | "passport-local": "~1.0.0", 22 | "passport-twitter": "~1.0.4" 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /public/assets/css/images/arrow.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /public/assets/css/images/ie/banner-overlay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/css/images/ie/banner-overlay.png -------------------------------------------------------------------------------- /public/assets/css/images/overlay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/css/images/overlay.png -------------------------------------------------------------------------------- /public/assets/css/noscript.css: -------------------------------------------------------------------------------- 1 | /* 2 | Landed by HTML5 UP 3 | html5up.net | @ajlkn 4 | Free for personal and commercial use under the CCA 3.0 license (html5up.net/license) 5 | */ 6 | 7 | /* Loader */ 8 | 9 | body.landing.is-preload:before { 10 | display: none; 11 | } 12 | 13 | body.landing.is-preload:after { 14 | display: none; 15 | } -------------------------------------------------------------------------------- /public/assets/js/breakpoints.min.js: -------------------------------------------------------------------------------- 1 | /* breakpoints.js v1.0 | @ajlkn | MIT licensed */ 2 | var breakpoints=function(){"use strict";function e(e){t.init(e)}var t={list:null,media:{},events:[],init:function(e){t.list=e,window.addEventListener("resize",t.poll),window.addEventListener("orientationchange",t.poll),window.addEventListener("load",t.poll),window.addEventListener("fullscreenchange",t.poll)},active:function(e){var n,a,s,i,r,d,c;if(!(e in t.media)){if(">="==e.substr(0,2)?(a="gte",n=e.substr(2)):"<="==e.substr(0,2)?(a="lte",n=e.substr(2)):">"==e.substr(0,1)?(a="gt",n=e.substr(1)):"<"==e.substr(0,1)?(a="lt",n=e.substr(1)):"!"==e.substr(0,1)?(a="not",n=e.substr(1)):(a="eq",n=e),n&&n in t.list)if(i=t.list[n],Array.isArray(i)){if(r=parseInt(i[0]),d=parseInt(i[1]),isNaN(r)){if(isNaN(d))return;c=i[1].substr(String(d).length)}else c=i[0].substr(String(r).length);if(isNaN(r))switch(a){case"gte":s="screen";break;case"lte":s="screen and (max-width: "+d+c+")";break;case"gt":s="screen and (min-width: "+(d+1)+c+")";break;case"lt":s="screen and (max-width: -1px)";break;case"not":s="screen and (min-width: "+(d+1)+c+")";break;default:s="screen and (max-width: "+d+c+")"}else if(isNaN(d))switch(a){case"gte":s="screen and (min-width: "+r+c+")";break;case"lte":s="screen";break;case"gt":s="screen and (max-width: -1px)";break;case"lt":s="screen and (max-width: "+(r-1)+c+")";break;case"not":s="screen and (max-width: "+(r-1)+c+")";break;default:s="screen and (min-width: "+r+c+")"}else switch(a){case"gte":s="screen and (min-width: "+r+c+")";break;case"lte":s="screen and (max-width: "+d+c+")";break;case"gt":s="screen and (min-width: "+(d+1)+c+")";break;case"lt":s="screen and (max-width: "+(r-1)+c+")";break;case"not":s="screen and (max-width: "+(r-1)+c+"), screen and (min-width: "+(d+1)+c+")";break;default:s="screen and (min-width: "+r+c+") and (max-width: "+d+c+")"}}else s="("==i.charAt(0)?"screen and "+i:i;t.media[e]=!!s&&s}return t.media[e]!==!1&&window.matchMedia(t.media[e]).matches},on:function(e,n){t.events.push({query:e,handler:n,state:!1}),t.active(e)&&n()},poll:function(){var e,n;for(e=0;e0:!!("ontouchstart"in window),e.mobile="wp"==e.os||"android"==e.os||"ios"==e.os||"bb"==e.os}};return e.init(),e}();!function(e,n){"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?module.exports=n():e.browser=n()}(this,function(){return browser}); 3 | -------------------------------------------------------------------------------- /public/assets/js/jquery.dropotron.min.js: -------------------------------------------------------------------------------- 1 | /* jquery.dropotron.js v1.4.3 | (c) @ajlkn | github.com/ajlkn/jquery.dropotron | MIT licensed */ 2 | !function(e){e.fn.disableSelection_dropotron=function(){return e(this).css("user-select","none").css("-khtml-user-select","none").css("-moz-user-select","none").css("-o-user-select","none").css("-webkit-user-select","none")},e.fn.dropotron=function(t){if(0==this.length)return e(this);if(this.length>1)for(var o=0;o0&&t.add(n).on("mouseleave",function(e){window.clearTimeout(c),c=window.setTimeout(function(){t.trigger("doCollapse")},o.hideDelay)}),t.disableSelection_dropotron().hide().addClass(o.menuClass).css("position","absolute").on("mouseenter",function(e){window.clearTimeout(c)}).on("doExpand",function(){if(t.is(":visible"))return!1;window.clearTimeout(c),s.each(function(){var t=e(this);e.contains(t.get(0),n.get(0))||t.trigger("doCollapse")});var i,a,d,f,u=n.offset(),p=n.position(),h=(n.parent().position(),n.outerWidth()),g=t.outerWidth(),v=t.css("z-index")==o.baseZIndex;if(v){switch(i=o.detach?u:p,f=i.top+n.outerHeight()+o.globalOffsetY,a=o.alignment,t.removeClass("left").removeClass("right").removeClass("center"),o.alignment){case"right":d=i.left-g+h,0>d&&(d=i.left,a="left");break;case"center":d=i.left-Math.floor((g-h)/2),0>d?(d=i.left,a="left"):d+g>l.width()&&(d=i.left-g+h,a="right");break;case"left":default:d=i.left,d+g>l.width()&&(d=i.left-g+h,a="right")}t.addClass(a)}else switch("relative"==n.css("position")||"absolute"==n.css("position")?(f=o.offsetY,d=-1*p.left):(f=p.top+o.offsetY,d=0),o.alignment){case"right":d+=-1*n.parent().outerWidth()+o.offsetX;break;case"center":case"left":default:d+=n.parent().outerWidth()+o.offsetX}navigator.userAgent.match(/MSIE ([0-9]+)\./)&&RegExp.$1<8&&(d+=o.IEOffsetX,f+=o.IEOffsetY),t.css("left",d+"px").css("top",f+"px").css("opacity","0.01").show();var C=!1;switch(d="relative"==n.css("position")||"absolute"==n.css("position")?-1*p.left:0,t.offset().left<0?(d+=n.parent().outerWidth()-o.offsetX,C=!0):t.offset().left+g>l.width()&&(d+=-1*n.parent().outerWidth()-o.offsetX,C=!0),C&&t.css("left",d+"px"),t.hide().css("opacity","1"),o.mode){case"zoom":r=!0,n.addClass(o.openerActiveClass),t.animate({width:"toggle",height:"toggle"},o.speed,o.easing,function(){r=!1});break;case"slide":r=!0,n.addClass(o.openerActiveClass),t.animate({height:"toggle"},o.speed,o.easing,function(){r=!1});break;case"fade":if(r=!0,v&&!o.noOpenerFade){var C;C="slow"==o.speed?80:"fast"==o.speed?40:Math.floor(o.speed/2),n.fadeTo(C,.01,function(){n.addClass(o.openerActiveClass),n.fadeTo(o.speed,1),t.fadeIn(o.speed,function(){r=!1})})}else n.addClass(o.openerActiveClass),n.fadeTo(o.speed,1),t.fadeIn(o.speed,function(){r=!1});break;case"instant":default:n.addClass(o.openerActiveClass),t.show()}return!1}).on("doCollapse",function(){return t.is(":visible")?(t.hide(),n.removeClass(o.openerActiveClass),t.find("."+o.openerActiveClass).removeClass(o.openerActiveClass),t.find("ul").hide(),!1):!1}).on("doToggle",function(e){return t.is(":visible")?t.trigger("doCollapse"):t.trigger("doExpand"),!1}),n.disableSelection_dropotron().addClass("opener").css("cursor","pointer").on("click touchend",function(e){r||(e.preventDefault(),e.stopPropagation(),t.trigger("doToggle"))}),"hover"==o.expandMode&&n.hover(function(e){r||(d=window.setTimeout(function(){t.trigger("doExpand")},o.hoverDelay))},function(e){window.clearTimeout(d)})}),s.find("a").css("display","block").on("click touchend",function(t){r||e(this).attr("href").length<1&&t.preventDefault()}),n.find("li").css("white-space","nowrap").each(function(){var t=e(this),o=t.children("a"),s=t.children("ul"),i=o.attr("href");o.on("click touchend",function(e){0==i.length||"#"==i?e.preventDefault():e.stopPropagation()}),o.length>0&&0==s.length&&t.on("click touchend",function(e){r||(n.trigger("doCollapseAll"),e.stopPropagation())})}),n.children("li").each(function(){var t,n=e(this),s=n.children("ul");if(s.length>0){o.detach&&(o.cloneOnDetach&&(t=s.clone(),t.attr("class","").hide().appendTo(s.parent())),s.detach().appendTo(i));for(var a=o.baseZIndex,l=1,r=s;r.length>0;l++)r.css("z-index",a++),o.submenuClassPrefix&&r.addClass(o.submenuClassPrefix+(a-1-o.baseZIndex)),r=r.find("> li > ul")}}),l.on("scroll",function(){n.trigger("doCollapseAll")}).on("keypress",function(e){r||27!=e.keyCode||(e.preventDefault(),n.trigger("doCollapseAll"))}),a.on("click touchend",function(){r||n.trigger("doCollapseAll")})}}(jQuery); 3 | -------------------------------------------------------------------------------- /public/assets/js/jquery.scrollex.min.js: -------------------------------------------------------------------------------- 1 | /* jquery.scrollex v0.2.1 | (c) @ajlkn | github.com/ajlkn/jquery.scrollex | MIT licensed */ 2 | !function(t){function e(t,e,n){return"string"==typeof t&&("%"==t.slice(-1)?t=parseInt(t.substring(0,t.length-1))/100*e:"vh"==t.slice(-2)?t=parseInt(t.substring(0,t.length-2))/100*n:"px"==t.slice(-2)&&(t=parseInt(t.substring(0,t.length-2)))),t}var n=t(window),i=1,o={};n.on("scroll",function(){var e=n.scrollTop();t.map(o,function(t){window.clearTimeout(t.timeoutId),t.timeoutId=window.setTimeout(function(){t.handler(e)},t.options.delay)})}).on("load",function(){n.trigger("scroll")}),jQuery.fn.scrollex=function(l){var s=t(this);if(0==this.length)return s;if(this.length>1){for(var r=0;r=i&&o>=t};break;case"bottom":h=function(t,e,n,i,o){return n>=i&&o>=n};break;case"middle":h=function(t,e,n,i,o){return e>=i&&o>=e};break;case"top-only":h=function(t,e,n,i,o){return i>=t&&n>=i};break;case"bottom-only":h=function(t,e,n,i,o){return n>=o&&o>=t};break;default:case"default":h=function(t,e,n,i,o){return n>=i&&o>=t}}return c=function(t){var i,o,l,s,r,a,u=this.state,h=!1,c=this.$element.offset();i=n.height(),o=t+i/2,l=t+i,s=this.$element.outerHeight(),r=c.top+e(this.options.top,s,i),a=c.top+s-e(this.options.bottom,s,i),h=this.test(t,o,l,r,a),h!=u&&(this.state=h,h?this.options.enter&&this.options.enter.apply(this.element):this.options.leave&&this.options.leave.apply(this.element)),this.options.scroll&&this.options.scroll.apply(this.element,[(o-r)/(a-r)])},p={id:a,options:u,test:h,handler:c,state:null,element:this,$element:s,timeoutId:null},o[a]=p,s.data("_scrollexId",p.id),p.options.initialize&&p.options.initialize.apply(this),s},jQuery.fn.unscrollex=function(){var e=t(this);if(0==this.length)return e;if(this.length>1){for(var n=0;n1){for(o=0;o ul').dropotron({ 39 | alignment: 'right', 40 | hideDelay: 350 41 | }); 42 | 43 | // Nav. 44 | 45 | // Title Bar. 46 | $( 47 | '
' + 48 | '' + 49 | '' + $('#logo').html() + '' + 50 | '
' 51 | ) 52 | .appendTo($body); 53 | 54 | // Panel. 55 | $( 56 | '' 61 | ) 62 | .appendTo($body) 63 | .panel({ 64 | delay: 500, 65 | hideOnClick: true, 66 | hideOnSwipe: true, 67 | resetScroll: true, 68 | resetForms: true, 69 | side: 'left', 70 | target: $body, 71 | visibleClass: 'navPanel-visible' 72 | }); 73 | 74 | // Parallax. 75 | // Disabled on IE (choppy scrolling) and mobile platforms (poor performance). 76 | if (browser.name == 'ie' 77 | || browser.mobile) { 78 | 79 | $.fn._parallax = function() { 80 | 81 | return $(this); 82 | 83 | }; 84 | 85 | } 86 | else { 87 | 88 | $.fn._parallax = function() { 89 | 90 | $(this).each(function() { 91 | 92 | var $this = $(this), 93 | on, off; 94 | 95 | on = function() { 96 | 97 | $this 98 | .css('background-position', 'center 0px'); 99 | 100 | $window 101 | .on('scroll._parallax', function() { 102 | 103 | var pos = parseInt($window.scrollTop()) - parseInt($this.position().top); 104 | 105 | $this.css('background-position', 'center ' + (pos * -0.15) + 'px'); 106 | 107 | }); 108 | 109 | }; 110 | 111 | off = function() { 112 | 113 | $this 114 | .css('background-position', ''); 115 | 116 | $window 117 | .off('scroll._parallax'); 118 | 119 | }; 120 | 121 | breakpoints.on('<=medium', off); 122 | breakpoints.on('>medium', on); 123 | 124 | }); 125 | 126 | return $(this); 127 | 128 | }; 129 | 130 | $window 131 | .on('load resize', function() { 132 | $window.trigger('scroll'); 133 | }); 134 | 135 | } 136 | 137 | // Spotlights. 138 | var $spotlights = $('.spotlight'); 139 | 140 | $spotlights 141 | ._parallax() 142 | .each(function() { 143 | 144 | var $this = $(this), 145 | on, off; 146 | 147 | on = function() { 148 | 149 | var top, bottom, mode; 150 | 151 | // Use main 's src as this spotlight's background. 152 | $this.css('background-image', 'url("' + $this.find('.image.main > img').attr('src') + '")'); 153 | 154 | // Side-specific scrollex tweaks. 155 | if ($this.hasClass('top')) { 156 | 157 | mode = 'top'; 158 | top = '-20%'; 159 | bottom = 0; 160 | 161 | } 162 | else if ($this.hasClass('bottom')) { 163 | 164 | mode = 'bottom-only'; 165 | top = 0; 166 | bottom = '20%'; 167 | 168 | } 169 | else { 170 | 171 | mode = 'middle'; 172 | top = 0; 173 | bottom = 0; 174 | 175 | } 176 | 177 | // Add scrollex. 178 | $this.scrollex({ 179 | mode: mode, 180 | top: top, 181 | bottom: bottom, 182 | initialize: function(t) { $this.addClass('inactive'); }, 183 | terminate: function(t) { $this.removeClass('inactive'); }, 184 | enter: function(t) { $this.removeClass('inactive'); }, 185 | 186 | // Uncomment the line below to "rewind" when this spotlight scrolls out of view. 187 | 188 | //leave: function(t) { $this.addClass('inactive'); }, 189 | 190 | }); 191 | 192 | }; 193 | 194 | off = function() { 195 | 196 | // Clear spotlight's background. 197 | $this.css('background-image', ''); 198 | 199 | // Remove scrollex. 200 | $this.unscrollex(); 201 | 202 | }; 203 | 204 | breakpoints.on('<=medium', off); 205 | breakpoints.on('>medium', on); 206 | 207 | }); 208 | 209 | // Wrappers. 210 | var $wrappers = $('.wrapper'); 211 | 212 | $wrappers 213 | .each(function() { 214 | 215 | var $this = $(this), 216 | on, off; 217 | 218 | on = function() { 219 | 220 | $this.scrollex({ 221 | top: 250, 222 | bottom: 0, 223 | initialize: function(t) { $this.addClass('inactive'); }, 224 | terminate: function(t) { $this.removeClass('inactive'); }, 225 | enter: function(t) { $this.removeClass('inactive'); }, 226 | 227 | // Uncomment the line below to "rewind" when this wrapper scrolls out of view. 228 | 229 | //leave: function(t) { $this.addClass('inactive'); }, 230 | 231 | }); 232 | 233 | }; 234 | 235 | off = function() { 236 | $this.unscrollex(); 237 | }; 238 | 239 | breakpoints.on('<=medium', off); 240 | breakpoints.on('>medium', on); 241 | 242 | }); 243 | 244 | // Banner. 245 | var $banner = $('#banner'); 246 | 247 | $banner 248 | ._parallax(); 249 | 250 | })(jQuery); -------------------------------------------------------------------------------- /public/assets/js/util.js: -------------------------------------------------------------------------------- 1 | (function($) { 2 | 3 | /** 4 | * Generate an indented list of links from a nav. Meant for use with panel(). 5 | * @return {jQuery} jQuery object. 6 | */ 7 | $.fn.navList = function() { 8 | 9 | var $this = $(this); 10 | $a = $this.find('a'), 11 | b = []; 12 | 13 | $a.each(function() { 14 | 15 | var $this = $(this), 16 | indent = Math.max(0, $this.parents('li').length - 1), 17 | href = $this.attr('href'), 18 | target = $this.attr('target'); 19 | 20 | b.push( 21 | '' + 26 | '' + 27 | $this.text() + 28 | '' 29 | ); 30 | 31 | }); 32 | 33 | return b.join(''); 34 | 35 | }; 36 | 37 | /** 38 | * Panel-ify an element. 39 | * @param {object} userConfig User config. 40 | * @return {jQuery} jQuery object. 41 | */ 42 | $.fn.panel = function(userConfig) { 43 | 44 | // No elements? 45 | if (this.length == 0) 46 | return $this; 47 | 48 | // Multiple elements? 49 | if (this.length > 1) { 50 | 51 | for (var i=0; i < this.length; i++) 52 | $(this[i]).panel(userConfig); 53 | 54 | return $this; 55 | 56 | } 57 | 58 | // Vars. 59 | var $this = $(this), 60 | $body = $('body'), 61 | $window = $(window), 62 | id = $this.attr('id'), 63 | config; 64 | 65 | // Config. 66 | config = $.extend({ 67 | 68 | // Delay. 69 | delay: 0, 70 | 71 | // Hide panel on link click. 72 | hideOnClick: false, 73 | 74 | // Hide panel on escape keypress. 75 | hideOnEscape: false, 76 | 77 | // Hide panel on swipe. 78 | hideOnSwipe: false, 79 | 80 | // Reset scroll position on hide. 81 | resetScroll: false, 82 | 83 | // Reset forms on hide. 84 | resetForms: false, 85 | 86 | // Side of viewport the panel will appear. 87 | side: null, 88 | 89 | // Target element for "class". 90 | target: $this, 91 | 92 | // Class to toggle. 93 | visibleClass: 'visible' 94 | 95 | }, userConfig); 96 | 97 | // Expand "target" if it's not a jQuery object already. 98 | if (typeof config.target != 'jQuery') 99 | config.target = $(config.target); 100 | 101 | // Panel. 102 | 103 | // Methods. 104 | $this._hide = function(event) { 105 | 106 | // Already hidden? Bail. 107 | if (!config.target.hasClass(config.visibleClass)) 108 | return; 109 | 110 | // If an event was provided, cancel it. 111 | if (event) { 112 | 113 | event.preventDefault(); 114 | event.stopPropagation(); 115 | 116 | } 117 | 118 | // Hide. 119 | config.target.removeClass(config.visibleClass); 120 | 121 | // Post-hide stuff. 122 | window.setTimeout(function() { 123 | 124 | // Reset scroll position. 125 | if (config.resetScroll) 126 | $this.scrollTop(0); 127 | 128 | // Reset forms. 129 | if (config.resetForms) 130 | $this.find('form').each(function() { 131 | this.reset(); 132 | }); 133 | 134 | }, config.delay); 135 | 136 | }; 137 | 138 | // Vendor fixes. 139 | $this 140 | .css('-ms-overflow-style', '-ms-autohiding-scrollbar') 141 | .css('-webkit-overflow-scrolling', 'touch'); 142 | 143 | // Hide on click. 144 | if (config.hideOnClick) { 145 | 146 | $this.find('a') 147 | .css('-webkit-tap-highlight-color', 'rgba(0,0,0,0)'); 148 | 149 | $this 150 | .on('click', 'a', function(event) { 151 | 152 | var $a = $(this), 153 | href = $a.attr('href'), 154 | target = $a.attr('target'); 155 | 156 | if (!href || href == '#' || href == '' || href == '#' + id) 157 | return; 158 | 159 | // Cancel original event. 160 | event.preventDefault(); 161 | event.stopPropagation(); 162 | 163 | // Hide panel. 164 | $this._hide(); 165 | 166 | // Redirect to href. 167 | window.setTimeout(function() { 168 | 169 | if (target == '_blank') 170 | window.open(href); 171 | else 172 | window.location.href = href; 173 | 174 | }, config.delay + 10); 175 | 176 | }); 177 | 178 | } 179 | 180 | // Event: Touch stuff. 181 | $this.on('touchstart', function(event) { 182 | 183 | $this.touchPosX = event.originalEvent.touches[0].pageX; 184 | $this.touchPosY = event.originalEvent.touches[0].pageY; 185 | 186 | }) 187 | 188 | $this.on('touchmove', function(event) { 189 | 190 | if ($this.touchPosX === null 191 | || $this.touchPosY === null) 192 | return; 193 | 194 | var diffX = $this.touchPosX - event.originalEvent.touches[0].pageX, 195 | diffY = $this.touchPosY - event.originalEvent.touches[0].pageY, 196 | th = $this.outerHeight(), 197 | ts = ($this.get(0).scrollHeight - $this.scrollTop()); 198 | 199 | // Hide on swipe? 200 | if (config.hideOnSwipe) { 201 | 202 | var result = false, 203 | boundary = 20, 204 | delta = 50; 205 | 206 | switch (config.side) { 207 | 208 | case 'left': 209 | result = (diffY < boundary && diffY > (-1 * boundary)) && (diffX > delta); 210 | break; 211 | 212 | case 'right': 213 | result = (diffY < boundary && diffY > (-1 * boundary)) && (diffX < (-1 * delta)); 214 | break; 215 | 216 | case 'top': 217 | result = (diffX < boundary && diffX > (-1 * boundary)) && (diffY > delta); 218 | break; 219 | 220 | case 'bottom': 221 | result = (diffX < boundary && diffX > (-1 * boundary)) && (diffY < (-1 * delta)); 222 | break; 223 | 224 | default: 225 | break; 226 | 227 | } 228 | 229 | if (result) { 230 | 231 | $this.touchPosX = null; 232 | $this.touchPosY = null; 233 | $this._hide(); 234 | 235 | return false; 236 | 237 | } 238 | 239 | } 240 | 241 | // Prevent vertical scrolling past the top or bottom. 242 | if (($this.scrollTop() < 0 && diffY < 0) 243 | || (ts > (th - 2) && ts < (th + 2) && diffY > 0)) { 244 | 245 | event.preventDefault(); 246 | event.stopPropagation(); 247 | 248 | } 249 | 250 | }); 251 | 252 | // Event: Prevent certain events inside the panel from bubbling. 253 | $this.on('click touchend touchstart touchmove', function(event) { 254 | event.stopPropagation(); 255 | }); 256 | 257 | // Event: Hide panel if a child anchor tag pointing to its ID is clicked. 258 | $this.on('click', 'a[href="#' + id + '"]', function(event) { 259 | 260 | event.preventDefault(); 261 | event.stopPropagation(); 262 | 263 | config.target.removeClass(config.visibleClass); 264 | 265 | }); 266 | 267 | // Body. 268 | 269 | // Event: Hide panel on body click/tap. 270 | $body.on('click touchend', function(event) { 271 | $this._hide(event); 272 | }); 273 | 274 | // Event: Toggle. 275 | $body.on('click', 'a[href="#' + id + '"]', function(event) { 276 | 277 | event.preventDefault(); 278 | event.stopPropagation(); 279 | 280 | config.target.toggleClass(config.visibleClass); 281 | 282 | }); 283 | 284 | // Window. 285 | 286 | // Event: Hide on ESC. 287 | if (config.hideOnEscape) 288 | $window.on('keydown', function(event) { 289 | 290 | if (event.keyCode == 27) 291 | $this._hide(event); 292 | 293 | }); 294 | 295 | return $this; 296 | 297 | }; 298 | 299 | /** 300 | * Apply "placeholder" attribute polyfill to one or more forms. 301 | * @return {jQuery} jQuery object. 302 | */ 303 | $.fn.placeholder = function() { 304 | 305 | // Browser natively supports placeholders? Bail. 306 | if (typeof (document.createElement('input')).placeholder != 'undefined') 307 | return $(this); 308 | 309 | // No elements? 310 | if (this.length == 0) 311 | return $this; 312 | 313 | // Multiple elements? 314 | if (this.length > 1) { 315 | 316 | for (var i=0; i < this.length; i++) 317 | $(this[i]).placeholder(); 318 | 319 | return $this; 320 | 321 | } 322 | 323 | // Vars. 324 | var $this = $(this); 325 | 326 | // Text, TextArea. 327 | $this.find('input[type=text],textarea') 328 | .each(function() { 329 | 330 | var i = $(this); 331 | 332 | if (i.val() == '' 333 | || i.val() == i.attr('placeholder')) 334 | i 335 | .addClass('polyfill-placeholder') 336 | .val(i.attr('placeholder')); 337 | 338 | }) 339 | .on('blur', function() { 340 | 341 | var i = $(this); 342 | 343 | if (i.attr('name').match(/-polyfill-field$/)) 344 | return; 345 | 346 | if (i.val() == '') 347 | i 348 | .addClass('polyfill-placeholder') 349 | .val(i.attr('placeholder')); 350 | 351 | }) 352 | .on('focus', function() { 353 | 354 | var i = $(this); 355 | 356 | if (i.attr('name').match(/-polyfill-field$/)) 357 | return; 358 | 359 | if (i.val() == i.attr('placeholder')) 360 | i 361 | .removeClass('polyfill-placeholder') 362 | .val(''); 363 | 364 | }); 365 | 366 | // Password. 367 | $this.find('input[type=password]') 368 | .each(function() { 369 | 370 | var i = $(this); 371 | var x = $( 372 | $('
') 373 | .append(i.clone()) 374 | .remove() 375 | .html() 376 | .replace(/type="password"/i, 'type="text"') 377 | .replace(/type=password/i, 'type=text') 378 | ); 379 | 380 | if (i.attr('id') != '') 381 | x.attr('id', i.attr('id') + '-polyfill-field'); 382 | 383 | if (i.attr('name') != '') 384 | x.attr('name', i.attr('name') + '-polyfill-field'); 385 | 386 | x.addClass('polyfill-placeholder') 387 | .val(x.attr('placeholder')).insertAfter(i); 388 | 389 | if (i.val() == '') 390 | i.hide(); 391 | else 392 | x.hide(); 393 | 394 | i 395 | .on('blur', function(event) { 396 | 397 | event.preventDefault(); 398 | 399 | var x = i.parent().find('input[name=' + i.attr('name') + '-polyfill-field]'); 400 | 401 | if (i.val() == '') { 402 | 403 | i.hide(); 404 | x.show(); 405 | 406 | } 407 | 408 | }); 409 | 410 | x 411 | .on('focus', function(event) { 412 | 413 | event.preventDefault(); 414 | 415 | var i = x.parent().find('input[name=' + x.attr('name').replace('-polyfill-field', '') + ']'); 416 | 417 | x.hide(); 418 | 419 | i 420 | .show() 421 | .focus(); 422 | 423 | }) 424 | .on('keypress', function(event) { 425 | 426 | event.preventDefault(); 427 | x.val(''); 428 | 429 | }); 430 | 431 | }); 432 | 433 | // Events. 434 | $this 435 | .on('submit', function() { 436 | 437 | $this.find('input[type=text],input[type=password],textarea') 438 | .each(function(event) { 439 | 440 | var i = $(this); 441 | 442 | if (i.attr('name').match(/-polyfill-field$/)) 443 | i.attr('name', ''); 444 | 445 | if (i.val() == i.attr('placeholder')) { 446 | 447 | i.removeClass('polyfill-placeholder'); 448 | i.val(''); 449 | 450 | } 451 | 452 | }); 453 | 454 | }) 455 | .on('reset', function(event) { 456 | 457 | event.preventDefault(); 458 | 459 | $this.find('select') 460 | .val($('option:first').val()); 461 | 462 | $this.find('input,textarea') 463 | .each(function() { 464 | 465 | var i = $(this), 466 | x; 467 | 468 | i.removeClass('polyfill-placeholder'); 469 | 470 | switch (this.type) { 471 | 472 | case 'submit': 473 | case 'reset': 474 | break; 475 | 476 | case 'password': 477 | i.val(i.attr('defaultValue')); 478 | 479 | x = i.parent().find('input[name=' + i.attr('name') + '-polyfill-field]'); 480 | 481 | if (i.val() == '') { 482 | i.hide(); 483 | x.show(); 484 | } 485 | else { 486 | i.show(); 487 | x.hide(); 488 | } 489 | 490 | break; 491 | 492 | case 'checkbox': 493 | case 'radio': 494 | i.attr('checked', i.attr('defaultValue')); 495 | break; 496 | 497 | case 'text': 498 | case 'textarea': 499 | i.val(i.attr('defaultValue')); 500 | 501 | if (i.val() == '') { 502 | i.addClass('polyfill-placeholder'); 503 | i.val(i.attr('placeholder')); 504 | } 505 | 506 | break; 507 | 508 | default: 509 | i.val(i.attr('defaultValue')); 510 | break; 511 | 512 | } 513 | }); 514 | 515 | }); 516 | 517 | return $this; 518 | 519 | }; 520 | 521 | /** 522 | * Moves elements to/from the first positions of their respective parents. 523 | * @param {jQuery} $elements Elements (or selector) to move. 524 | * @param {bool} condition If true, moves elements to the top. Otherwise, moves elements back to their original locations. 525 | */ 526 | $.prioritize = function($elements, condition) { 527 | 528 | var key = '__prioritize'; 529 | 530 | // Expand $elements if it's not already a jQuery object. 531 | if (typeof $elements != 'jQuery') 532 | $elements = $($elements); 533 | 534 | // Step through elements. 535 | $elements.each(function() { 536 | 537 | var $e = $(this), $p, 538 | $parent = $e.parent(); 539 | 540 | // No parent? Bail. 541 | if ($parent.length == 0) 542 | return; 543 | 544 | // Not moved? Move it. 545 | if (!$e.data(key)) { 546 | 547 | // Condition is false? Bail. 548 | if (!condition) 549 | return; 550 | 551 | // Get placeholder (which will serve as our point of reference for when this element needs to move back). 552 | $p = $e.prev(); 553 | 554 | // Couldn't find anything? Means this element's already at the top, so bail. 555 | if ($p.length == 0) 556 | return; 557 | 558 | // Move element to top of parent. 559 | $e.prependTo($parent); 560 | 561 | // Mark element as moved. 562 | $e.data(key, $p); 563 | 564 | } 565 | 566 | // Moved already? 567 | else { 568 | 569 | // Condition is true? Bail. 570 | if (condition) 571 | return; 572 | 573 | $p = $e.data(key); 574 | 575 | // Move element back to its original location (using our placeholder). 576 | $e.insertAfter($p); 577 | 578 | // Unmark element as moved. 579 | $e.removeData(key); 580 | 581 | } 582 | 583 | }); 584 | 585 | }; 586 | 587 | })(jQuery); -------------------------------------------------------------------------------- /public/assets/sass/libs/_breakpoints.scss: -------------------------------------------------------------------------------- 1 | // breakpoints.scss v1.0 | @ajlkn | MIT licensed */ 2 | 3 | // Vars. 4 | 5 | /// Breakpoints. 6 | /// @var {list} 7 | $breakpoints: () !global; 8 | 9 | // Mixins. 10 | 11 | /// Sets breakpoints. 12 | /// @param {map} $x Breakpoints. 13 | @mixin breakpoints($x: ()) { 14 | $breakpoints: $x !global; 15 | } 16 | 17 | /// Wraps @content in a @media block targeting a specific orientation. 18 | /// @param {string} $orientation Orientation. 19 | @mixin orientation($orientation) { 20 | @media screen and (orientation: #{$orientation}) { 21 | @content; 22 | } 23 | } 24 | 25 | /// Wraps @content in a @media block using a given query. 26 | /// @param {string} $query Query. 27 | @mixin breakpoint($query: null) { 28 | 29 | $breakpoint: null; 30 | $op: null; 31 | $media: null; 32 | 33 | // Determine operator, breakpoint. 34 | 35 | // Greater than or equal. 36 | @if (str-slice($query, 0, 2) == '>=') { 37 | 38 | $op: 'gte'; 39 | $breakpoint: str-slice($query, 3); 40 | 41 | } 42 | 43 | // Less than or equal. 44 | @elseif (str-slice($query, 0, 2) == '<=') { 45 | 46 | $op: 'lte'; 47 | $breakpoint: str-slice($query, 3); 48 | 49 | } 50 | 51 | // Greater than. 52 | @elseif (str-slice($query, 0, 1) == '>') { 53 | 54 | $op: 'gt'; 55 | $breakpoint: str-slice($query, 2); 56 | 57 | } 58 | 59 | // Less than. 60 | @elseif (str-slice($query, 0, 1) == '<') { 61 | 62 | $op: 'lt'; 63 | $breakpoint: str-slice($query, 2); 64 | 65 | } 66 | 67 | // Not. 68 | @elseif (str-slice($query, 0, 1) == '!') { 69 | 70 | $op: 'not'; 71 | $breakpoint: str-slice($query, 2); 72 | 73 | } 74 | 75 | // Equal. 76 | @else { 77 | 78 | $op: 'eq'; 79 | $breakpoint: $query; 80 | 81 | } 82 | 83 | // Build media. 84 | @if ($breakpoint and map-has-key($breakpoints, $breakpoint)) { 85 | 86 | $a: map-get($breakpoints, $breakpoint); 87 | 88 | // Range. 89 | @if (type-of($a) == 'list') { 90 | 91 | $x: nth($a, 1); 92 | $y: nth($a, 2); 93 | 94 | // Max only. 95 | @if ($x == null) { 96 | 97 | // Greater than or equal (>= 0 / anything) 98 | @if ($op == 'gte') { 99 | $media: 'screen'; 100 | } 101 | 102 | // Less than or equal (<= y) 103 | @elseif ($op == 'lte') { 104 | $media: 'screen and (max-width: ' + $y + ')'; 105 | } 106 | 107 | // Greater than (> y) 108 | @elseif ($op == 'gt') { 109 | $media: 'screen and (min-width: ' + ($y + 1) + ')'; 110 | } 111 | 112 | // Less than (< 0 / invalid) 113 | @elseif ($op == 'lt') { 114 | $media: 'screen and (max-width: -1px)'; 115 | } 116 | 117 | // Not (> y) 118 | @elseif ($op == 'not') { 119 | $media: 'screen and (min-width: ' + ($y + 1) + ')'; 120 | } 121 | 122 | // Equal (<= y) 123 | @else { 124 | $media: 'screen and (max-width: ' + $y + ')'; 125 | } 126 | 127 | } 128 | 129 | // Min only. 130 | @else if ($y == null) { 131 | 132 | // Greater than or equal (>= x) 133 | @if ($op == 'gte') { 134 | $media: 'screen and (min-width: ' + $x + ')'; 135 | } 136 | 137 | // Less than or equal (<= inf / anything) 138 | @elseif ($op == 'lte') { 139 | $media: 'screen'; 140 | } 141 | 142 | // Greater than (> inf / invalid) 143 | @elseif ($op == 'gt') { 144 | $media: 'screen and (max-width: -1px)'; 145 | } 146 | 147 | // Less than (< x) 148 | @elseif ($op == 'lt') { 149 | $media: 'screen and (max-width: ' + ($x - 1) + ')'; 150 | } 151 | 152 | // Not (< x) 153 | @elseif ($op == 'not') { 154 | $media: 'screen and (max-width: ' + ($x - 1) + ')'; 155 | } 156 | 157 | // Equal (>= x) 158 | @else { 159 | $media: 'screen and (min-width: ' + $x + ')'; 160 | } 161 | 162 | } 163 | 164 | // Min and max. 165 | @else { 166 | 167 | // Greater than or equal (>= x) 168 | @if ($op == 'gte') { 169 | $media: 'screen and (min-width: ' + $x + ')'; 170 | } 171 | 172 | // Less than or equal (<= y) 173 | @elseif ($op == 'lte') { 174 | $media: 'screen and (max-width: ' + $y + ')'; 175 | } 176 | 177 | // Greater than (> y) 178 | @elseif ($op == 'gt') { 179 | $media: 'screen and (min-width: ' + ($y + 1) + ')'; 180 | } 181 | 182 | // Less than (< x) 183 | @elseif ($op == 'lt') { 184 | $media: 'screen and (max-width: ' + ($x - 1) + ')'; 185 | } 186 | 187 | // Not (< x and > y) 188 | @elseif ($op == 'not') { 189 | $media: 'screen and (max-width: ' + ($x - 1) + '), screen and (min-width: ' + ($y + 1) + ')'; 190 | } 191 | 192 | // Equal (>= x and <= y) 193 | @else { 194 | $media: 'screen and (min-width: ' + $x + ') and (max-width: ' + $y + ')'; 195 | } 196 | 197 | } 198 | 199 | } 200 | 201 | // String. 202 | @else { 203 | 204 | // Missing a media type? Prefix with "screen". 205 | @if (str-slice($a, 0, 1) == '(') { 206 | $media: 'screen and ' + $a; 207 | } 208 | 209 | // Otherwise, use as-is. 210 | @else { 211 | $media: $a; 212 | } 213 | 214 | } 215 | 216 | } 217 | 218 | // Output. 219 | @media #{$media} { 220 | @content; 221 | } 222 | 223 | } -------------------------------------------------------------------------------- /public/assets/sass/libs/_functions.scss: -------------------------------------------------------------------------------- 1 | /// Removes a specific item from a list. 2 | /// @author Hugo Giraudel 3 | /// @param {list} $list List. 4 | /// @param {integer} $index Index. 5 | /// @return {list} Updated list. 6 | @function remove-nth($list, $index) { 7 | 8 | $result: null; 9 | 10 | @if type-of($index) != number { 11 | @warn "$index: #{quote($index)} is not a number for `remove-nth`."; 12 | } 13 | @else if $index == 0 { 14 | @warn "List index 0 must be a non-zero integer for `remove-nth`."; 15 | } 16 | @else if abs($index) > length($list) { 17 | @warn "List index is #{$index} but list is only #{length($list)} item long for `remove-nth`."; 18 | } 19 | @else { 20 | 21 | $result: (); 22 | $index: if($index < 0, length($list) + $index + 1, $index); 23 | 24 | @for $i from 1 through length($list) { 25 | 26 | @if $i != $index { 27 | $result: append($result, nth($list, $i)); 28 | } 29 | 30 | } 31 | 32 | } 33 | 34 | @return $result; 35 | 36 | } 37 | 38 | /// Gets a value from a map. 39 | /// @author Hugo Giraudel 40 | /// @param {map} $map Map. 41 | /// @param {string} $keys Key(s). 42 | /// @return {string} Value. 43 | @function val($map, $keys...) { 44 | 45 | @if nth($keys, 1) == null { 46 | $keys: remove-nth($keys, 1); 47 | } 48 | 49 | @each $key in $keys { 50 | $map: map-get($map, $key); 51 | } 52 | 53 | @return $map; 54 | 55 | } 56 | 57 | /// Gets a duration value. 58 | /// @param {string} $keys Key(s). 59 | /// @return {string} Value. 60 | @function _duration($keys...) { 61 | @return val($duration, $keys...); 62 | } 63 | 64 | /// Gets a font value. 65 | /// @param {string} $keys Key(s). 66 | /// @return {string} Value. 67 | @function _font($keys...) { 68 | @return val($font, $keys...); 69 | } 70 | 71 | /// Gets a misc value. 72 | /// @param {string} $keys Key(s). 73 | /// @return {string} Value. 74 | @function _misc($keys...) { 75 | @return val($misc, $keys...); 76 | } 77 | 78 | /// Gets a palette value. 79 | /// @param {string} $keys Key(s). 80 | /// @return {string} Value. 81 | @function _palette($keys...) { 82 | @return val($palette, $keys...); 83 | } 84 | 85 | /// Gets a size value. 86 | /// @param {string} $keys Key(s). 87 | /// @return {string} Value. 88 | @function _size($keys...) { 89 | @return val($size, $keys...); 90 | } -------------------------------------------------------------------------------- /public/assets/sass/libs/_html-grid.scss: -------------------------------------------------------------------------------- 1 | // html-grid.scss v1.0 | @ajlkn | MIT licensed */ 2 | 3 | // Mixins. 4 | 5 | /// Initializes the current element as an HTML grid. 6 | /// @param {mixed} $gutters Gutters (either a single number to set both column/row gutters, or a list to set them individually). 7 | /// @param {mixed} $suffix Column class suffix (optional; either a single suffix or a list). 8 | @mixin html-grid($gutters: 1.5em, $suffix: '') { 9 | 10 | // Initialize. 11 | $cols: 12; 12 | $multipliers: 0, 0.25, 0.5, 1, 1.50, 2.00; 13 | $unit: 100% / $cols; 14 | 15 | // Suffixes. 16 | $suffixes: null; 17 | 18 | @if (type-of($suffix) == 'list') { 19 | $suffixes: $suffix; 20 | } 21 | @else { 22 | $suffixes: ($suffix); 23 | } 24 | 25 | // Gutters. 26 | $guttersCols: null; 27 | $guttersRows: null; 28 | 29 | @if (type-of($gutters) == 'list') { 30 | 31 | $guttersCols: nth($gutters, 1); 32 | $guttersRows: nth($gutters, 2); 33 | 34 | } 35 | @else { 36 | 37 | $guttersCols: $gutters; 38 | $guttersRows: 0; 39 | 40 | } 41 | 42 | // Row. 43 | display: flex; 44 | flex-wrap: wrap; 45 | box-sizing: border-box; 46 | align-items: stretch; 47 | 48 | // Columns. 49 | > * { 50 | box-sizing: border-box; 51 | } 52 | 53 | // Gutters. 54 | &.gtr-uniform { 55 | > * { 56 | > :last-child { 57 | margin-bottom: 0; 58 | } 59 | } 60 | } 61 | 62 | // Alignment. 63 | &.aln-left { 64 | justify-content: flex-start; 65 | } 66 | 67 | &.aln-center { 68 | justify-content: center; 69 | } 70 | 71 | &.aln-right { 72 | justify-content: flex-end; 73 | } 74 | 75 | &.aln-top { 76 | align-items: flex-start; 77 | } 78 | 79 | &.aln-middle { 80 | align-items: center; 81 | } 82 | 83 | &.aln-bottom { 84 | align-items: flex-end; 85 | } 86 | 87 | // Step through suffixes. 88 | @each $suffix in $suffixes { 89 | 90 | // Suffix. 91 | @if ($suffix != '') { 92 | $suffix: '-' + $suffix; 93 | } 94 | @else { 95 | $suffix: ''; 96 | } 97 | 98 | // Row. 99 | 100 | // Important. 101 | > .imp#{$suffix} { 102 | order: -1; 103 | } 104 | 105 | // Columns, offsets. 106 | @for $i from 1 through $cols { 107 | > .col-#{$i}#{$suffix} { 108 | width: $unit * $i; 109 | } 110 | 111 | > .off-#{$i}#{$suffix} { 112 | margin-left: $unit * $i; 113 | } 114 | } 115 | 116 | // Step through multipliers. 117 | @each $multiplier in $multipliers { 118 | 119 | // Gutters. 120 | $class: null; 121 | 122 | @if ($multiplier != 1) { 123 | $class: '.gtr-' + ($multiplier * 100); 124 | } 125 | 126 | &#{$class} { 127 | margin-top: ($guttersRows * $multiplier * -1); 128 | margin-left: ($guttersCols * $multiplier * -1); 129 | 130 | > * { 131 | padding: ($guttersRows * $multiplier) 0 0 ($guttersCols * $multiplier); 132 | } 133 | 134 | // Uniform. 135 | &.gtr-uniform { 136 | margin-top: $guttersCols * $multiplier * -1; 137 | 138 | > * { 139 | padding-top: $guttersCols * $multiplier; 140 | } 141 | } 142 | 143 | } 144 | 145 | } 146 | 147 | } 148 | 149 | } -------------------------------------------------------------------------------- /public/assets/sass/libs/_mixins.scss: -------------------------------------------------------------------------------- 1 | /// Makes an element's :before pseudoelement a FontAwesome icon. 2 | /// @param {string} $content Optional content value to use. 3 | /// @param {string} $category Optional category to use. 4 | /// @param {string} $where Optional pseudoelement to target (before or after). 5 | @mixin icon($content: false, $category: regular, $where: before) { 6 | 7 | text-decoration: none; 8 | 9 | &:#{$where} { 10 | 11 | @if $content { 12 | content: $content; 13 | } 14 | 15 | -moz-osx-font-smoothing: grayscale; 16 | -webkit-font-smoothing: antialiased; 17 | display: inline-block; 18 | font-style: normal; 19 | font-variant: normal; 20 | text-rendering: auto; 21 | line-height: 1; 22 | text-transform: none !important; 23 | 24 | @if ($category == brands) { 25 | font-family: 'Font Awesome 5 Brands'; 26 | } 27 | @elseif ($category == solid) { 28 | font-family: 'Font Awesome 5 Free'; 29 | font-weight: 900; 30 | } 31 | @else { 32 | font-family: 'Font Awesome 5 Free'; 33 | font-weight: 400; 34 | } 35 | 36 | } 37 | 38 | } 39 | 40 | /// Applies padding to an element, taking the current element-margin value into account. 41 | /// @param {mixed} $tb Top/bottom padding. 42 | /// @param {mixed} $lr Left/right padding. 43 | /// @param {list} $pad Optional extra padding (in the following order top, right, bottom, left) 44 | /// @param {bool} $important If true, adds !important. 45 | @mixin padding($tb, $lr, $pad: (0,0,0,0), $important: null) { 46 | 47 | @if $important { 48 | $important: '!important'; 49 | } 50 | 51 | $x: 0.1em; 52 | 53 | @if unit(_size(element-margin)) == 'rem' { 54 | $x: 0.1rem; 55 | } 56 | 57 | padding: ($tb + nth($pad,1)) ($lr + nth($pad,2)) max($x, $tb - _size(element-margin) + nth($pad,3)) ($lr + nth($pad,4)) #{$important}; 58 | 59 | } 60 | 61 | /// Encodes a SVG data URL so IE doesn't choke (via codepen.io/jakob-e/pen/YXXBrp). 62 | /// @param {string} $svg SVG data URL. 63 | /// @return {string} Encoded SVG data URL. 64 | @function svg-url($svg) { 65 | 66 | $svg: str-replace($svg, '"', '\''); 67 | $svg: str-replace($svg, '%', '%25'); 68 | $svg: str-replace($svg, '<', '%3C'); 69 | $svg: str-replace($svg, '>', '%3E'); 70 | $svg: str-replace($svg, '&', '%26'); 71 | $svg: str-replace($svg, '#', '%23'); 72 | $svg: str-replace($svg, '{', '%7B'); 73 | $svg: str-replace($svg, '}', '%7D'); 74 | $svg: str-replace($svg, ';', '%3B'); 75 | 76 | @return url("data:image/svg+xml;charset=utf8,#{$svg}"); 77 | 78 | } -------------------------------------------------------------------------------- /public/assets/sass/libs/_vars.scss: -------------------------------------------------------------------------------- 1 | // Misc. 2 | $misc: ( 3 | z-index-base: 10000, 4 | z-index-overlay: 100000, 5 | max-spotlight: 20 6 | ); 7 | 8 | // Duration. 9 | $duration: ( 10 | navPanel: 0.5s, 11 | transition: 0.2s, 12 | landing-fadein: 1.5s 13 | ); 14 | 15 | // Size. 16 | $size: ( 17 | border-radius: 4px, 18 | element-height: 3em, 19 | element-margin: 2em, 20 | navPanel: 275px, 21 | container-width: 70em 22 | ); 23 | 24 | // Font. 25 | $font: ( 26 | family: ('Roboto', Helvetica, sans-serif), 27 | family-fixed: ('Courier New', monospace), 28 | weight: 100, 29 | weight-bold: 300 30 | ); 31 | 32 | // Palette. 33 | $palette: ( 34 | bg: #1c1d26, 35 | bg-transparent: rgba(23,24,32,0.95), 36 | fg-bold: #ffffff, 37 | fg: rgba(255,255,255,0.75), 38 | fg-light: rgba(255,255,255,0.5), 39 | fg-lighter: rgba(255,255,255,0.15), 40 | border: rgba(255,255,255,0.3), 41 | border-bg: rgba(255,255,255,0.075), 42 | border2: rgba(255,255,255,0.5), 43 | border2-bg: rgba(255,255,255,0.25), 44 | accent1: #e44c65, 45 | accent2: #272833, 46 | accent2-transparent:rgba(39,40,51,0.965), 47 | accent3: #5480f1, 48 | accent4: #39c088 49 | ); -------------------------------------------------------------------------------- /public/assets/sass/libs/_vendor.scss: -------------------------------------------------------------------------------- 1 | // vendor.scss v1.0 | @ajlkn | MIT licensed */ 2 | 3 | // Vars. 4 | 5 | /// Vendor prefixes. 6 | /// @var {list} 7 | $vendor-prefixes: ( 8 | '-moz-', 9 | '-webkit-', 10 | '-ms-', 11 | '' 12 | ); 13 | 14 | /// Properties that should be vendorized. 15 | /// Data via caniuse.com, github.com/postcss/autoprefixer, and developer.mozilla.org 16 | /// @var {list} 17 | $vendor-properties: ( 18 | 19 | // Animation. 20 | 'animation', 21 | 'animation-delay', 22 | 'animation-direction', 23 | 'animation-duration', 24 | 'animation-fill-mode', 25 | 'animation-iteration-count', 26 | 'animation-name', 27 | 'animation-play-state', 28 | 'animation-timing-function', 29 | 30 | // Appearance. 31 | 'appearance', 32 | 33 | // Backdrop filter. 34 | 'backdrop-filter', 35 | 36 | // Background image options. 37 | 'background-clip', 38 | 'background-origin', 39 | 'background-size', 40 | 41 | // Box sizing. 42 | 'box-sizing', 43 | 44 | // Clip path. 45 | 'clip-path', 46 | 47 | // Filter effects. 48 | 'filter', 49 | 50 | // Flexbox. 51 | 'align-content', 52 | 'align-items', 53 | 'align-self', 54 | 'flex', 55 | 'flex-basis', 56 | 'flex-direction', 57 | 'flex-flow', 58 | 'flex-grow', 59 | 'flex-shrink', 60 | 'flex-wrap', 61 | 'justify-content', 62 | 'order', 63 | 64 | // Font feature. 65 | 'font-feature-settings', 66 | 'font-language-override', 67 | 'font-variant-ligatures', 68 | 69 | // Font kerning. 70 | 'font-kerning', 71 | 72 | // Fragmented borders and backgrounds. 73 | 'box-decoration-break', 74 | 75 | // Grid layout. 76 | 'grid-column', 77 | 'grid-column-align', 78 | 'grid-column-end', 79 | 'grid-column-start', 80 | 'grid-row', 81 | 'grid-row-align', 82 | 'grid-row-end', 83 | 'grid-row-start', 84 | 'grid-template-columns', 85 | 'grid-template-rows', 86 | 87 | // Hyphens. 88 | 'hyphens', 89 | 'word-break', 90 | 91 | // Masks. 92 | 'mask', 93 | 'mask-border', 94 | 'mask-border-outset', 95 | 'mask-border-repeat', 96 | 'mask-border-slice', 97 | 'mask-border-source', 98 | 'mask-border-width', 99 | 'mask-clip', 100 | 'mask-composite', 101 | 'mask-image', 102 | 'mask-origin', 103 | 'mask-position', 104 | 'mask-repeat', 105 | 'mask-size', 106 | 107 | // Multicolumn. 108 | 'break-after', 109 | 'break-before', 110 | 'break-inside', 111 | 'column-count', 112 | 'column-fill', 113 | 'column-gap', 114 | 'column-rule', 115 | 'column-rule-color', 116 | 'column-rule-style', 117 | 'column-rule-width', 118 | 'column-span', 119 | 'column-width', 120 | 'columns', 121 | 122 | // Object fit. 123 | 'object-fit', 124 | 'object-position', 125 | 126 | // Regions. 127 | 'flow-from', 128 | 'flow-into', 129 | 'region-fragment', 130 | 131 | // Scroll snap points. 132 | 'scroll-snap-coordinate', 133 | 'scroll-snap-destination', 134 | 'scroll-snap-points-x', 135 | 'scroll-snap-points-y', 136 | 'scroll-snap-type', 137 | 138 | // Shapes. 139 | 'shape-image-threshold', 140 | 'shape-margin', 141 | 'shape-outside', 142 | 143 | // Tab size. 144 | 'tab-size', 145 | 146 | // Text align last. 147 | 'text-align-last', 148 | 149 | // Text decoration. 150 | 'text-decoration-color', 151 | 'text-decoration-line', 152 | 'text-decoration-skip', 153 | 'text-decoration-style', 154 | 155 | // Text emphasis. 156 | 'text-emphasis', 157 | 'text-emphasis-color', 158 | 'text-emphasis-position', 159 | 'text-emphasis-style', 160 | 161 | // Text size adjust. 162 | 'text-size-adjust', 163 | 164 | // Text spacing. 165 | 'text-spacing', 166 | 167 | // Transform. 168 | 'transform', 169 | 'transform-origin', 170 | 171 | // Transform 3D. 172 | 'backface-visibility', 173 | 'perspective', 174 | 'perspective-origin', 175 | 'transform-style', 176 | 177 | // Transition. 178 | 'transition', 179 | 'transition-delay', 180 | 'transition-duration', 181 | 'transition-property', 182 | 'transition-timing-function', 183 | 184 | // Unicode bidi. 185 | 'unicode-bidi', 186 | 187 | // User select. 188 | 'user-select', 189 | 190 | // Writing mode. 191 | 'writing-mode', 192 | 193 | ); 194 | 195 | /// Values that should be vendorized. 196 | /// Data via caniuse.com, github.com/postcss/autoprefixer, and developer.mozilla.org 197 | /// @var {list} 198 | $vendor-values: ( 199 | 200 | // Cross fade. 201 | 'cross-fade', 202 | 203 | // Element function. 204 | 'element', 205 | 206 | // Filter function. 207 | 'filter', 208 | 209 | // Flexbox. 210 | 'flex', 211 | 'inline-flex', 212 | 213 | // Grab cursors. 214 | 'grab', 215 | 'grabbing', 216 | 217 | // Gradients. 218 | 'linear-gradient', 219 | 'repeating-linear-gradient', 220 | 'radial-gradient', 221 | 'repeating-radial-gradient', 222 | 223 | // Grid layout. 224 | 'grid', 225 | 'inline-grid', 226 | 227 | // Image set. 228 | 'image-set', 229 | 230 | // Intrinsic width. 231 | 'max-content', 232 | 'min-content', 233 | 'fit-content', 234 | 'fill', 235 | 'fill-available', 236 | 'stretch', 237 | 238 | // Sticky position. 239 | 'sticky', 240 | 241 | // Transform. 242 | 'transform', 243 | 244 | // Zoom cursors. 245 | 'zoom-in', 246 | 'zoom-out', 247 | 248 | ); 249 | 250 | // Functions. 251 | 252 | /// Removes a specific item from a list. 253 | /// @author Hugo Giraudel 254 | /// @param {list} $list List. 255 | /// @param {integer} $index Index. 256 | /// @return {list} Updated list. 257 | @function remove-nth($list, $index) { 258 | 259 | $result: null; 260 | 261 | @if type-of($index) != number { 262 | @warn "$index: #{quote($index)} is not a number for `remove-nth`."; 263 | } 264 | @else if $index == 0 { 265 | @warn "List index 0 must be a non-zero integer for `remove-nth`."; 266 | } 267 | @else if abs($index) > length($list) { 268 | @warn "List index is #{$index} but list is only #{length($list)} item long for `remove-nth`."; 269 | } 270 | @else { 271 | 272 | $result: (); 273 | $index: if($index < 0, length($list) + $index + 1, $index); 274 | 275 | @for $i from 1 through length($list) { 276 | 277 | @if $i != $index { 278 | $result: append($result, nth($list, $i)); 279 | } 280 | 281 | } 282 | 283 | } 284 | 285 | @return $result; 286 | 287 | } 288 | 289 | /// Replaces a substring within another string. 290 | /// @author Hugo Giraudel 291 | /// @param {string} $string String. 292 | /// @param {string} $search Substring. 293 | /// @param {string} $replace Replacement. 294 | /// @return {string} Updated string. 295 | @function str-replace($string, $search, $replace: '') { 296 | 297 | $index: str-index($string, $search); 298 | 299 | @if $index { 300 | @return str-slice($string, 1, $index - 1) + $replace + str-replace(str-slice($string, $index + str-length($search)), $search, $replace); 301 | } 302 | 303 | @return $string; 304 | 305 | } 306 | 307 | /// Replaces a substring within each string in a list. 308 | /// @param {list} $strings List of strings. 309 | /// @param {string} $search Substring. 310 | /// @param {string} $replace Replacement. 311 | /// @return {list} Updated list of strings. 312 | @function str-replace-all($strings, $search, $replace: '') { 313 | 314 | @each $string in $strings { 315 | $strings: set-nth($strings, index($strings, $string), str-replace($string, $search, $replace)); 316 | } 317 | 318 | @return $strings; 319 | 320 | } 321 | 322 | // Mixins. 323 | 324 | /// Wraps @content in vendorized keyframe blocks. 325 | /// @param {string} $name Name. 326 | @mixin keyframes($name) { 327 | 328 | @-moz-keyframes #{$name} { @content; } 329 | @-webkit-keyframes #{$name} { @content; } 330 | @-ms-keyframes #{$name} { @content; } 331 | @keyframes #{$name} { @content; } 332 | 333 | } 334 | 335 | /// Vendorizes a declaration's property and/or value(s). 336 | /// @param {string} $property Property. 337 | /// @param {mixed} $value String/list of value(s). 338 | @mixin vendor($property, $value) { 339 | 340 | // Determine if property should expand. 341 | $expandProperty: index($vendor-properties, $property); 342 | 343 | // Determine if value should expand (and if so, add '-prefix-' placeholder). 344 | $expandValue: false; 345 | 346 | @each $x in $value { 347 | @each $y in $vendor-values { 348 | @if $y == str-slice($x, 1, str-length($y)) { 349 | 350 | $value: set-nth($value, index($value, $x), '-prefix-' + $x); 351 | $expandValue: true; 352 | 353 | } 354 | } 355 | } 356 | 357 | // Expand property? 358 | @if $expandProperty { 359 | @each $vendor in $vendor-prefixes { 360 | #{$vendor}#{$property}: #{str-replace-all($value, '-prefix-', $vendor)}; 361 | } 362 | } 363 | 364 | // Expand just the value? 365 | @elseif $expandValue { 366 | @each $vendor in $vendor-prefixes { 367 | #{$property}: #{str-replace-all($value, '-prefix-', $vendor)}; 368 | } 369 | } 370 | 371 | // Neither? Treat them as a normal declaration. 372 | @else { 373 | #{$property}: #{$value}; 374 | } 375 | 376 | } -------------------------------------------------------------------------------- /public/assets/sass/main.scss: -------------------------------------------------------------------------------- 1 | @import 'libs/vars'; 2 | @import 'libs/functions'; 3 | @import 'libs/mixins'; 4 | @import 'libs/vendor'; 5 | @import 'libs/breakpoints'; 6 | @import 'libs/html-grid'; 7 | @import url('fontawesome-all.min.css'); 8 | @import url("https://fonts.googleapis.com/css?family=Roboto:100,300,100italic,300italic"); 9 | 10 | /* 11 | Landed by HTML5 UP 12 | html5up.net | @ajlkn 13 | Free for personal and commercial use under the CCA 3.0 license (html5up.net/license) 14 | */ 15 | 16 | // Breakpoints. 17 | 18 | @include breakpoints(( 19 | xlarge: ( 1281px, 1680px ), 20 | large: ( 981px, 1280px ), 21 | medium: ( 737px, 980px ), 22 | small: ( 481px, 736px ), 23 | xsmall: ( null, 480px ), 24 | )); 25 | 26 | // Mixins. 27 | 28 | @mixin line-icon($bg: _palette(bg), $fg: _palette(fg-bold)) { 29 | @include icon; 30 | $size: 1px; 31 | 32 | &:before { 33 | color: $bg !important; 34 | text-shadow: $size 0 0 $fg, 35 | ($size * -1) 0 0 $fg, 36 | 0 $size 0 $fg, 37 | 0 ($size * -1) 0 $fg; 38 | } 39 | } 40 | 41 | $size-wrapper-pad-tb: 6em; 42 | $size-wrapper-pad-lr: 3em; 43 | 44 | // Reset. 45 | // Based on meyerweb.com/eric/tools/css/reset (v2.0 | 20110126 | License: public domain) 46 | 47 | html, body, div, span, applet, object, 48 | iframe, h1, h2, h3, h4, h5, h6, p, blockquote, 49 | pre, a, abbr, acronym, address, big, cite, 50 | code, del, dfn, em, img, ins, kbd, q, s, samp, 51 | small, strike, strong, sub, sup, tt, var, b, 52 | u, i, center, dl, dt, dd, ol, ul, li, fieldset, 53 | form, label, legend, table, caption, tbody, 54 | tfoot, thead, tr, th, td, article, aside, 55 | canvas, details, embed, figure, figcaption, 56 | footer, header, hgroup, menu, nav, output, ruby, 57 | section, summary, time, mark, audio, video { 58 | margin: 0; 59 | padding: 0; 60 | border: 0; 61 | font-size: 100%; 62 | font: inherit; 63 | vertical-align: baseline; 64 | } 65 | 66 | article, aside, details, figcaption, figure, 67 | footer, header, hgroup, menu, nav, section { 68 | display: block; 69 | } 70 | 71 | body { 72 | line-height: 1; 73 | } 74 | 75 | ol, ul { 76 | list-style:none; 77 | } 78 | 79 | blockquote, q { 80 | quotes: none; 81 | 82 | &:before, 83 | &:after { 84 | content: ''; 85 | content: none; 86 | } 87 | } 88 | 89 | table { 90 | border-collapse: collapse; 91 | border-spacing: 0; 92 | } 93 | 94 | body { 95 | -webkit-text-size-adjust: none; 96 | } 97 | 98 | mark { 99 | background-color: transparent; 100 | color: inherit; 101 | } 102 | 103 | input::-moz-focus-inner { 104 | border: 0; 105 | padding: 0; 106 | } 107 | 108 | input, select, textarea { 109 | -moz-appearance: none; 110 | -webkit-appearance: none; 111 | -ms-appearance: none; 112 | appearance: none; 113 | } 114 | 115 | /* Basic */ 116 | 117 | // Set box model to border-box. 118 | // Based on css-tricks.com/inheriting-box-sizing-probably-slightly-better-best-practice 119 | html { 120 | box-sizing: border-box; 121 | } 122 | 123 | *, *:before, *:after { 124 | box-sizing: inherit; 125 | } 126 | 127 | html, body { 128 | background: _palette(bg); 129 | } 130 | 131 | body { 132 | 133 | // Stops initial animations until page loads. 134 | &.is-preload { 135 | *, *:before, *:after { 136 | @include vendor('animation', 'none !important'); 137 | @include vendor('transition', 'none !important'); 138 | } 139 | } 140 | 141 | } 142 | 143 | body, input, select, textarea { 144 | color: _palette(fg); 145 | font-family: _font(family); 146 | font-size: 15pt; 147 | font-weight: _font(weight); 148 | line-height: 1.75em; 149 | } 150 | 151 | a { 152 | @include vendor('transition', ('border-color #{_duration(transition)} ease-in-out', 'color #{_duration(transition)} ease-in-out')); 153 | border-bottom: dotted 1px; 154 | color: _palette(accent1); 155 | text-decoration: none; 156 | 157 | &:hover { 158 | color: _palette(accent1) !important; 159 | border-bottom-color: transparent; 160 | } 161 | } 162 | 163 | strong, b { 164 | color: _palette(fg-bold); 165 | font-weight: _font(weight-bold); 166 | } 167 | 168 | em, i { 169 | font-style: italic; 170 | } 171 | 172 | p { 173 | margin: 0 0 _size(element-margin) 0; 174 | } 175 | 176 | h1, h2, h3, h4, h5, h6 { 177 | color: _palette(fg-bold); 178 | font-weight: _font(weight-bold); 179 | line-height: 1em; 180 | margin: 0 0 (_size(element-margin) * 0.5) 0; 181 | 182 | a { 183 | color: inherit; 184 | border: 0; 185 | } 186 | } 187 | 188 | h2 { 189 | font-size: 2em; 190 | line-height: 1.5em; 191 | letter-spacing: -0.025em; 192 | } 193 | 194 | h3 { 195 | font-size: 1.35em; 196 | line-height: 1.5em; 197 | } 198 | 199 | h4 { 200 | font-size: 1.1em; 201 | line-height: 1.5em; 202 | } 203 | 204 | h5 { 205 | font-size: 0.9em; 206 | line-height: 1.5em; 207 | } 208 | 209 | h6 { 210 | font-size: 0.7em; 211 | line-height: 1.5em; 212 | } 213 | 214 | sub { 215 | font-size: 0.8em; 216 | position: relative; 217 | top: 0.5em; 218 | } 219 | 220 | sup { 221 | font-size: 0.8em; 222 | position: relative; 223 | top: -0.5em; 224 | } 225 | 226 | hr { 227 | border: 0; 228 | border-bottom: solid 1px _palette(border); 229 | margin: (_size(element-margin) * 1.5) 0; 230 | 231 | &.major { 232 | margin: (_size(element-margin) * 2) 0; 233 | } 234 | } 235 | 236 | blockquote { 237 | border-left: solid 4px _palette(border); 238 | font-style: italic; 239 | margin: 0 0 _size(element-margin) 0; 240 | padding: 0.5em 0 0.5em 2em; 241 | } 242 | 243 | code { 244 | background: _palette(border-bg); 245 | border-radius: _size(border-radius); 246 | font-family: _font(family-fixed); 247 | font-size: 0.9em; 248 | margin: 0 0.25em; 249 | padding: 0.25em 0.65em; 250 | } 251 | 252 | pre { 253 | -webkit-overflow-scrolling: touch; 254 | font-family: _font(family-fixed); 255 | font-size: 0.9em; 256 | margin: 0 0 _size(element-margin) 0; 257 | 258 | code { 259 | display: block; 260 | line-height: 1.75em; 261 | padding: 1em 1.5em; 262 | overflow-x: auto; 263 | } 264 | } 265 | 266 | .align-left { 267 | text-align: left; 268 | } 269 | 270 | .align-center { 271 | text-align: center; 272 | } 273 | 274 | .align-right { 275 | text-align: right; 276 | } 277 | 278 | /* Loader */ 279 | 280 | // Spinner 281 | 282 | @include keyframes('spinner-show') { 283 | 0% { opacity: 0; } 284 | 100% { opacity: 1; } 285 | } 286 | 287 | @include keyframes('spinner-hide') { 288 | 0% { color: _palette(fg-lighter); z-index: _misc(z-index-overlay) + 1; @include vendor('transform', 'scale(1) rotate(0deg)'); } 289 | 99% { color: _palette(bg); z-index: _misc(z-index-overlay) + 1; @include vendor('transform', 'scale(0.5) rotate(360deg)'); } 290 | 100% { color: _palette(bg); z-index: -1; @include vendor('transform', 'scale(0.5) rotate(360deg)'); } 291 | } 292 | 293 | @include keyframes('spinner-rotate') { 294 | 0% { @include vendor('transform', 'scale(1) rotate(0deg)'); } 295 | 100% { @include vendor('transform', 'scale(1) rotate(360deg)'); } 296 | } 297 | 298 | // Overlay 299 | 300 | @include keyframes('overlay-hide') { 301 | 0% { opacity: 1; z-index: _misc(z-index-overlay); } 302 | 15% { opacity: 1; z-index: _misc(z-index-overlay); } 303 | 99% { opacity: 0; z-index: _misc(z-index-overlay); } 304 | 100% { opacity: 0; z-index: -1; } 305 | } 306 | 307 | body.landing { 308 | @include icon(false, solid); 309 | 310 | // Spinner (inactive) 311 | 312 | &:before { 313 | @include vendor('animation', ('spinner-show 1.5s 1 0.25s ease forwards', 'spinner-hide 0.25s ease-in-out forwards !important')); 314 | @include vendor('transform-origin', '50% 50%'); 315 | 316 | color: _palette(fg-lighter); 317 | content: '\f1ce'; 318 | cursor: default; 319 | display: block; 320 | font-size: 2em; 321 | height: 2em; 322 | left: 50%; 323 | line-height: 2em; 324 | margin: -1em 0 0 -1em; 325 | opacity: 0; 326 | position: fixed; 327 | text-align: center; 328 | top: 50%; 329 | width: 2em; 330 | z-index: -1; 331 | } 332 | 333 | // Overlay (inactive) 334 | 335 | &:after { 336 | @include vendor('animation', 'overlay-hide #{_duration(landing-fadein)} ease-in forwards !important'); 337 | background: _palette(bg); 338 | content: ''; 339 | display: block; 340 | height: 100%; 341 | left: 0; 342 | opacity: 0; 343 | position: fixed; 344 | top: 0; 345 | width: 100%; 346 | z-index: -1; 347 | } 348 | 349 | &.is-preload { 350 | 351 | // Spinner (active) 352 | 353 | &:before { 354 | @include vendor('animation', ('spinner-show 1.5s 1 0.25s ease forwards', 'spinner-rotate 0.75s infinite linear !important')); 355 | z-index: _misc(z-index-overlay) + 1; 356 | } 357 | 358 | // Overlay (active) 359 | 360 | &:after { 361 | @include vendor('animation', 'none !important'); 362 | opacity: 1; 363 | z-index: _misc(z-index-overlay); 364 | } 365 | 366 | } 367 | } 368 | 369 | @media (-webkit-min-device-pixel-ratio: 2) { 370 | body.landing:before { 371 | line-height: 2.025em; 372 | } 373 | } 374 | 375 | /* Container */ 376 | 377 | .container { 378 | margin: 0 auto; 379 | max-width: calc(100% - #{_size(element-margin) * 2}); 380 | width: _size(container-width); 381 | 382 | &.xsmall { 383 | width: (_size(container-width) * 0.25); 384 | } 385 | 386 | &.small { 387 | width: (_size(container-width) * 0.5); 388 | } 389 | 390 | &.medium { 391 | width: (_size(container-width) * 0.75); 392 | } 393 | 394 | &.large { 395 | width: (_size(container-width) * 1.25); 396 | } 397 | 398 | &.xlarge { 399 | width: (_size(container-width) * 1.5); 400 | } 401 | 402 | &.max { 403 | width: 100%; 404 | } 405 | 406 | @include breakpoint('<=large') { 407 | width: 90%; 408 | max-width: 100%; 409 | } 410 | 411 | @include breakpoint('<=medium') { 412 | width: 100% !important; 413 | } 414 | } 415 | 416 | /* Row */ 417 | 418 | .row { 419 | @include html-grid(2.5em); 420 | 421 | @include breakpoint('<=xlarge') { 422 | @include html-grid(2.5em, 'xlarge'); 423 | } 424 | 425 | @include breakpoint('<=large') { 426 | @include html-grid(2.5em, 'large'); 427 | } 428 | 429 | @include breakpoint('<=medium') { 430 | @include html-grid(2.5em, 'medium'); 431 | } 432 | 433 | @include breakpoint('<=small') { 434 | @include html-grid(2.5em, 'small'); 435 | } 436 | 437 | @include breakpoint('<=xsmall') { 438 | @include html-grid(2.5em, 'xsmall'); 439 | } 440 | } 441 | 442 | /* Section/Article */ 443 | 444 | section, article { 445 | &.special { 446 | text-align: center; 447 | } 448 | } 449 | 450 | header { 451 | p { 452 | color: _palette(fg-bold); 453 | position: relative; 454 | margin: 0 0 (_size(element-margin) * 0.75) 0; 455 | } 456 | 457 | h2 + p { 458 | font-size: 1.25em; 459 | margin-top: (_size(element-margin) * -0.5); 460 | line-height: 1.75em; 461 | } 462 | 463 | h3 + p { 464 | font-size: 1.1em; 465 | margin-top: (_size(element-margin) * -0.4); 466 | line-height: 1.75em; 467 | } 468 | 469 | h4 + p, 470 | h5 + p, 471 | h6 + p { 472 | font-size: 0.9em; 473 | margin-top: (_size(element-margin) * -0.3); 474 | line-height: 1.5em; 475 | } 476 | 477 | &.major { 478 | margin: 0 0 (_size(element-margin) * 2) 0; 479 | position: relative; 480 | text-align: center; 481 | 482 | &:after { 483 | background: _palette(accent1); 484 | content: ''; 485 | display: inline-block; 486 | height: 0.2em; 487 | max-width: 20em; 488 | width: 75%; 489 | } 490 | } 491 | } 492 | 493 | footer { 494 | &.major { 495 | margin: (_size(element-margin) * 2) 0 0 0; 496 | } 497 | } 498 | 499 | /* Form */ 500 | 501 | form { 502 | margin: 0 0 _size(element-margin) 0; 503 | 504 | &.cta { 505 | max-width: 35em; 506 | margin-left: auto; 507 | margin-right: auto; 508 | } 509 | } 510 | 511 | label { 512 | color: _palette(fg-bold); 513 | display: block; 514 | font-size: 0.9em; 515 | font-weight: _font(weight-bold); 516 | margin: 0 0 (_size(element-margin) * 0.5) 0; 517 | } 518 | 519 | input[type="text"], 520 | input[type="password"], 521 | input[type="email"], 522 | select, 523 | textarea { 524 | @include vendor('appearance', 'none'); 525 | @include vendor('transition', 'border-color #{_duration(transition)} ease-in-out'); 526 | background: transparent; 527 | border-radius: _size(border-radius); 528 | border: solid 1px _palette(border); 529 | color: inherit; 530 | display: block; 531 | outline: 0; 532 | padding: 0 1em; 533 | text-decoration: none; 534 | width: 100%; 535 | 536 | &:invalid { 537 | box-shadow: none; 538 | } 539 | 540 | &:focus { 541 | border-color: _palette(accent1); 542 | } 543 | } 544 | 545 | select { 546 | background-image: svg-url(""); 547 | background-size: 1.25rem; 548 | background-repeat: no-repeat; 549 | background-position: calc(100% - 1rem) center; 550 | height: _size(element-height); 551 | padding-right: _size(element-height); 552 | text-overflow: ellipsis; 553 | 554 | option { 555 | color: _palette(fg-bold); 556 | background: _palette(bg); 557 | } 558 | 559 | &:focus { 560 | &::-ms-value { 561 | background-color: transparent; 562 | } 563 | } 564 | 565 | &::-ms-expand { 566 | display: none; 567 | } 568 | } 569 | 570 | input[type="text"], 571 | input[type="password"], 572 | input[type="email"], 573 | select { 574 | height: _size(element-height); 575 | } 576 | 577 | textarea { 578 | padding: 0.75em 1em; 579 | } 580 | 581 | input[type="checkbox"], 582 | input[type="radio"], { 583 | @include vendor('appearance', 'none'); 584 | display: block; 585 | float: left; 586 | margin-right: -2em; 587 | opacity: 0; 588 | width: 1em; 589 | z-index: -1; 590 | 591 | & + label { 592 | @include icon(false, solid); 593 | color: _palette(fg); 594 | cursor: pointer; 595 | display: inline-block; 596 | font-size: 1em; 597 | font-weight: _font(weight); 598 | padding-left: (_size(element-height) * 0.6) + 0.75em; 599 | padding-right: 0.75em; 600 | position: relative; 601 | 602 | &:before { 603 | border-radius: _size(border-radius); 604 | border: solid 1px _palette(border); 605 | content: ''; 606 | display: inline-block; 607 | font-size: 0.8em; 608 | height: (_size(element-height) * 0.75); 609 | left: 0; 610 | line-height: (_size(element-height) * 0.75); 611 | position: absolute; 612 | text-align: center; 613 | top: 0; 614 | width: (_size(element-height) * 0.75); 615 | } 616 | } 617 | 618 | &:checked + label { 619 | &:before { 620 | background: _palette(border2-bg); 621 | color: _palette(fg-bold); 622 | content: '\f00c'; 623 | } 624 | } 625 | 626 | &:focus + label { 627 | &:before { 628 | border-color: _palette(accent1); 629 | } 630 | } 631 | } 632 | 633 | input[type="checkbox"] { 634 | & + label { 635 | &:before { 636 | border-radius: _size(border-radius); 637 | } 638 | } 639 | } 640 | 641 | input[type="radio"] { 642 | & + label { 643 | &:before { 644 | border-radius: 100%; 645 | } 646 | } 647 | } 648 | 649 | ::-webkit-input-placeholder { 650 | color: _palette(fg-light) !important; 651 | opacity: 1.0; 652 | } 653 | 654 | :-moz-placeholder { 655 | color: _palette(fg-light) !important; 656 | opacity: 1.0; 657 | } 658 | 659 | ::-moz-placeholder { 660 | color: _palette(fg-light) !important; 661 | opacity: 1.0; 662 | } 663 | 664 | :-ms-input-placeholder { 665 | color: _palette(fg-light) !important; 666 | opacity: 1.0; 667 | } 668 | 669 | /* Box */ 670 | 671 | .box { 672 | border-radius: _size(border-radius); 673 | border: solid 1px _palette(border); 674 | margin-bottom: _size(element-margin); 675 | padding: 1.5em; 676 | 677 | > :last-child, 678 | > :last-child > :last-child, 679 | > :last-child > :last-child > :last-child { 680 | margin-bottom: 0; 681 | } 682 | 683 | &.alt { 684 | border: 0; 685 | border-radius: 0; 686 | padding: 0; 687 | } 688 | } 689 | 690 | /* Icon */ 691 | 692 | .icon { 693 | @include icon; 694 | border-bottom: none; 695 | position: relative; 696 | 697 | > .label { 698 | display: none; 699 | } 700 | 701 | &:before { 702 | line-height: inherit; 703 | } 704 | 705 | &.solid { 706 | &:before { 707 | font-weight: 900 !important; 708 | } 709 | } 710 | 711 | &.brands { 712 | &:before { 713 | font-family: 'Font Awesome 5 Brands' !important; 714 | } 715 | } 716 | 717 | &.alt { 718 | @include line-icon; 719 | } 720 | 721 | &.major { 722 | background: _palette(accent2); 723 | border-radius: 100%; 724 | cursor: default; 725 | display: inline-block; 726 | height: 6em; 727 | line-height: 5.65em; 728 | margin: 0 0 _size(element-margin) 0; 729 | text-align: center; 730 | width: 6em; 731 | 732 | &:before { 733 | font-size: 2.25em; 734 | } 735 | 736 | &.alt { 737 | @include line-icon(_palette(accent2)); 738 | } 739 | } 740 | } 741 | 742 | /* Image */ 743 | 744 | .image { 745 | border-radius: _size(border-radius); 746 | border: 0; 747 | display: inline-block; 748 | position: relative; 749 | overflow: hidden; 750 | 751 | &:before { 752 | content: ''; 753 | display: block; 754 | position: absolute; 755 | left: 0; 756 | top: 0; 757 | background-image: url('images/overlay.png'); 758 | width: 100%; 759 | height: 100%; 760 | z-index: 1; 761 | } 762 | 763 | img { 764 | border-radius: _size(border-radius); 765 | display: block; 766 | } 767 | 768 | &.left { 769 | float: left; 770 | margin: 0 1.5em 1em 0; 771 | top: 0.25em; 772 | } 773 | 774 | &.right { 775 | float: right; 776 | margin: 0 0 1em 1.5em; 777 | top: 0.25em; 778 | } 779 | 780 | &.left, 781 | &.right { 782 | max-width: 40%; 783 | 784 | img { 785 | width: 100%; 786 | } 787 | } 788 | 789 | &.fit { 790 | display: block; 791 | margin: 0 0 _size(element-margin) 0; 792 | width: 100%; 793 | 794 | img { 795 | width: 100%; 796 | } 797 | } 798 | } 799 | 800 | /* List */ 801 | 802 | ol { 803 | list-style: decimal; 804 | margin: 0 0 _size(element-margin) 0; 805 | padding-left: 1.25em; 806 | 807 | li { 808 | padding-left: 0.25em; 809 | } 810 | } 811 | 812 | ul { 813 | list-style: disc; 814 | margin: 0 0 _size(element-margin) 0; 815 | padding-left: 1em; 816 | 817 | li { 818 | padding-left: 0.5em; 819 | } 820 | 821 | &.alt { 822 | list-style: none; 823 | padding-left: 0; 824 | 825 | li { 826 | border-top: solid 1px _palette(border); 827 | padding: 0.5em 0; 828 | 829 | &:first-child { 830 | border-top: 0; 831 | padding-top: 0; 832 | } 833 | } 834 | } 835 | 836 | } 837 | 838 | dl { 839 | margin: 0 0 _size(element-margin) 0; 840 | } 841 | 842 | /* Icons */ 843 | 844 | ul.icons { 845 | cursor: default; 846 | list-style: none; 847 | padding-left: 0; 848 | 849 | li { 850 | display: inline-block; 851 | height: 2.5em; 852 | line-height: 2.5em; 853 | padding: 0 0.5em; 854 | 855 | .icon { 856 | font-size: 0.8em; 857 | 858 | &:before { 859 | font-size: 2em; 860 | } 861 | } 862 | } 863 | } 864 | 865 | /* Actions */ 866 | 867 | ul.actions { 868 | @include vendor('display', 'flex'); 869 | cursor: default; 870 | list-style: none; 871 | margin-left: (_size(element-margin) * -0.5); 872 | padding-left: 0; 873 | 874 | li { 875 | padding: 0 0 0 (_size(element-margin) * 0.5); 876 | vertical-align: middle; 877 | } 878 | 879 | &.special { 880 | @include vendor('justify-content', 'center'); 881 | width: 100%; 882 | margin-left: 0; 883 | 884 | li { 885 | &:first-child { 886 | padding-left: 0; 887 | } 888 | } 889 | } 890 | 891 | &.stacked { 892 | @include vendor('flex-direction', 'column'); 893 | margin-left: 0; 894 | 895 | li { 896 | padding: (_size(element-margin) * 0.65) 0 0 0; 897 | 898 | &:first-child { 899 | padding-top: 0; 900 | } 901 | } 902 | } 903 | 904 | &.fit { 905 | width: calc(100% + #{_size(element-margin) * 0.5}); 906 | 907 | li { 908 | @include vendor('flex-grow', '1'); 909 | @include vendor('flex-shrink', '1'); 910 | width: 100%; 911 | 912 | > * { 913 | width: 100%; 914 | } 915 | } 916 | 917 | &.stacked { 918 | width: 100%; 919 | } 920 | } 921 | 922 | @include breakpoint('<=xsmall') { 923 | &:not(.fixed) { 924 | @include vendor('flex-direction', 'column'); 925 | margin-left: 0; 926 | width: 100% !important; 927 | 928 | li { 929 | @include vendor('flex-grow', '1'); 930 | @include vendor('flex-shrink', '1'); 931 | padding: (_size(element-margin) * 0.5) 0 0 0; 932 | text-align: center; 933 | width: 100%; 934 | 935 | > * { 936 | width: 100%; 937 | } 938 | 939 | &:first-child { 940 | padding-top: 0; 941 | } 942 | 943 | input[type="submit"], 944 | input[type="reset"], 945 | input[type="button"], 946 | button, 947 | .button { 948 | width: 100%; 949 | 950 | &.icon { 951 | &:before { 952 | margin-left: -0.5em; 953 | } 954 | } 955 | } 956 | } 957 | } 958 | } 959 | } 960 | 961 | /* Table */ 962 | 963 | .table-wrapper { 964 | -webkit-overflow-scrolling: touch; 965 | overflow-x: auto; 966 | } 967 | 968 | table { 969 | margin: 0 0 _size(element-margin) 0; 970 | width: 100%; 971 | 972 | tbody { 973 | tr { 974 | border: solid 1px _palette(border); 975 | border-left: 0; 976 | border-right: 0; 977 | 978 | &:nth-child(2n + 1) { 979 | background-color: _palette(border-bg); 980 | } 981 | } 982 | } 983 | 984 | td { 985 | padding: 0.75em 0.75em; 986 | } 987 | 988 | th { 989 | color: _palette(fg-bold); 990 | font-size: 0.9em; 991 | font-weight: _font(weight-bold); 992 | padding: 0 0.75em 0.75em 0.75em; 993 | text-align: left; 994 | } 995 | 996 | thead { 997 | border-bottom: solid 1px _palette(border); 998 | } 999 | 1000 | tfoot { 1001 | border-top: solid 1px _palette(border); 1002 | } 1003 | 1004 | &.alt { 1005 | border-collapse: separate; 1006 | 1007 | tbody { 1008 | tr { 1009 | td { 1010 | border: solid 1px _palette(border); 1011 | border-left-width: 0; 1012 | border-top-width: 0; 1013 | 1014 | &:first-child { 1015 | border-left-width: 1px; 1016 | } 1017 | } 1018 | 1019 | &:first-child { 1020 | td { 1021 | border-top-width: 1px; 1022 | } 1023 | } 1024 | } 1025 | } 1026 | 1027 | thead { 1028 | border-bottom: 0; 1029 | } 1030 | 1031 | tfoot { 1032 | border-top: 0; 1033 | } 1034 | } 1035 | } 1036 | 1037 | /* Button */ 1038 | 1039 | input[type="submit"], 1040 | input[type="reset"], 1041 | input[type="button"], 1042 | .button { 1043 | @include vendor('appearance', 'none'); 1044 | @include vendor('transition', ('background-color #{_duration(transition)} ease-in-out', 'color #{_duration(transition)} ease-in-out', 'box-shadow #{_duration(transition)} ease-in-out')); 1045 | background-color: transparent; 1046 | border-radius: _size(border-radius); 1047 | border: 0; 1048 | box-shadow: inset 0 0 0 1px _palette(border); 1049 | color: _palette(fg-bold) !important; 1050 | cursor: pointer; 1051 | display: inline-block; 1052 | font-weight: _font(weight-bold); 1053 | height: _size(element-height); 1054 | line-height: _size(element-height); 1055 | padding: 0 2.25em; 1056 | text-align: center; 1057 | text-decoration: none; 1058 | white-space: nowrap; 1059 | 1060 | &:hover, &:active { 1061 | box-shadow: inset 0 0 0 1px _palette(accent1); 1062 | color: _palette(accent1) !important; 1063 | } 1064 | 1065 | &:active { 1066 | background-color: transparentize(_palette(accent1), 0.85); 1067 | } 1068 | 1069 | &.icon { 1070 | &:before { 1071 | margin-right: 0.5em; 1072 | } 1073 | } 1074 | 1075 | &.fit { 1076 | width: 100%; 1077 | } 1078 | 1079 | &.small { 1080 | font-size: 0.8em; 1081 | } 1082 | 1083 | &.large { 1084 | font-size: 1.35em; 1085 | } 1086 | 1087 | &.primary { 1088 | background-color: _palette(accent1); 1089 | box-shadow: none; 1090 | color: _palette(fg-bold) !important; 1091 | 1092 | &:hover { 1093 | background-color: lighten(_palette(accent1), 5); 1094 | } 1095 | 1096 | &:active { 1097 | background-color: darken(_palette(accent1), 5); 1098 | } 1099 | } 1100 | 1101 | &.disabled, 1102 | &:disabled { 1103 | background-color: _palette(border) !important; 1104 | box-shadow: none !important; 1105 | color: _palette(fg-bold) !important; 1106 | cursor: default; 1107 | opacity: 0.25; 1108 | } 1109 | } 1110 | 1111 | /* Goto Next */ 1112 | 1113 | .goto-next { 1114 | border: 0; 1115 | bottom: 0; 1116 | display: block; 1117 | height: 5em; 1118 | left: 50%; 1119 | margin: 0 0 0 -5em; 1120 | overflow: hidden; 1121 | position: absolute; 1122 | text-indent: 10em; 1123 | white-space: nowrap; 1124 | width: 10em; 1125 | z-index: 1; 1126 | 1127 | &:before { 1128 | background-image: url('images/arrow.svg'); 1129 | background-position: center center; 1130 | background-repeat: no-repeat; 1131 | background-size: contain; 1132 | content: ''; 1133 | display: block; 1134 | height: 1.5em; 1135 | left: 50%; 1136 | margin: -0.75em 0 0 -1em; 1137 | position: absolute; 1138 | top: 50%; 1139 | width: 2em; 1140 | z-index: 1; 1141 | } 1142 | } 1143 | 1144 | /* Spotlight */ 1145 | 1146 | .spotlight { 1147 | background-attachment: fixed; 1148 | background-position: center center; 1149 | background-size: cover; 1150 | box-shadow: 0 0.25em 0.5em 0 rgba(0,0,0,0.25); 1151 | height: 100vh; 1152 | overflow: hidden; 1153 | position: relative; 1154 | 1155 | // Force spotlights to stack in reverse order (needed for our box 1156 | // shadows to overlap stuff in the right direction). 1157 | @for $i from 1 through _misc(max-spotlight) { 1158 | &:nth-last-of-type(#{$i}) { 1159 | z-index: #{$i}; 1160 | } 1161 | } 1162 | 1163 | &:before { 1164 | background-image: url('images/overlay.png'); 1165 | content: ''; 1166 | display: block; 1167 | height: 100%; 1168 | left: 0; 1169 | top: 0; 1170 | width: 100%; 1171 | } 1172 | 1173 | .image.main { 1174 | display: none; 1175 | 1176 | img { 1177 | position: relative; 1178 | } 1179 | } 1180 | 1181 | .content { 1182 | @include vendor('transform', 'translate(0,0)'); 1183 | @include vendor('transition', 'transform 1s ease, opacity 1s ease'); 1184 | background: _palette(bg-transparent); 1185 | border-style: solid; 1186 | opacity: 1; 1187 | position: absolute; 1188 | } 1189 | 1190 | .goto-next { 1191 | @include vendor('transform', 'translate(0,0)'); 1192 | @include vendor('transition', 'transform 0.75s ease, opacity 1s ease-in'); 1193 | @include vendor('transition-delay', '0.5s'); 1194 | opacity: 1; 1195 | } 1196 | 1197 | &.top, &.bottom { 1198 | .content { 1199 | left: 0; 1200 | padding: ($size-wrapper-pad-tb * 0.85) 0 (($size-wrapper-pad-tb * 0.85) - _size(element-margin)) 0; 1201 | width: 100%; 1202 | } 1203 | } 1204 | 1205 | &.top { 1206 | .content { 1207 | border-bottom-width: 0.35em; 1208 | top: 0; 1209 | } 1210 | } 1211 | 1212 | &.bottom { 1213 | .content { 1214 | border-top-width: 0.35em; 1215 | bottom: 0; 1216 | } 1217 | } 1218 | 1219 | &.left, &.right { 1220 | .content { 1221 | height: 101%; 1222 | padding: $size-wrapper-pad-tb $size-wrapper-pad-lr; 1223 | top: 0; 1224 | width: 28em; 1225 | } 1226 | } 1227 | 1228 | &.left { 1229 | .content { 1230 | border-right-width: 0.35em; 1231 | left: 0; 1232 | } 1233 | } 1234 | 1235 | &.right { 1236 | .content { 1237 | border-left-width: 0.35em; 1238 | right: 0; 1239 | } 1240 | } 1241 | 1242 | &.style1 { 1243 | .content { 1244 | border-color: _palette(accent1); 1245 | } 1246 | } 1247 | 1248 | &.style2 { 1249 | .content { 1250 | border-color: _palette(accent3); 1251 | } 1252 | } 1253 | 1254 | &.style3 { 1255 | .content { 1256 | border-color: _palette(accent4); 1257 | } 1258 | } 1259 | 1260 | &.inactive { 1261 | .content { 1262 | opacity: 0; 1263 | } 1264 | 1265 | .goto-next { 1266 | @include vendor('transform', 'translate(0,1.5em)'); 1267 | opacity: 0; 1268 | } 1269 | 1270 | &.top { 1271 | .content { 1272 | @include vendor('transform', 'translate(0,-5em)'); 1273 | } 1274 | } 1275 | 1276 | &.bottom { 1277 | .content { 1278 | @include vendor('transform', 'translate(0,5em)'); 1279 | } 1280 | } 1281 | 1282 | &.left { 1283 | .content { 1284 | @include vendor('transform', 'translate(-5em,0)'); 1285 | } 1286 | } 1287 | 1288 | &.right { 1289 | .content { 1290 | @include vendor('transform', 'translate(5em,0)'); 1291 | } 1292 | } 1293 | } 1294 | } 1295 | 1296 | body.is-touch { 1297 | .spotlight { 1298 | background-attachment: scroll; 1299 | } 1300 | } 1301 | 1302 | /* Wrapper */ 1303 | 1304 | .wrapper { 1305 | padding: $size-wrapper-pad-tb 0 ($size-wrapper-pad-tb - _size(element-margin)) 0; 1306 | 1307 | &.style1 { 1308 | } 1309 | 1310 | &.style2 { 1311 | background: _palette(accent1); 1312 | 1313 | input[type="text"], 1314 | input[type="password"], 1315 | input[type="email"], 1316 | select, 1317 | textarea { 1318 | &:focus { 1319 | border-color: _palette(border2); 1320 | } 1321 | } 1322 | 1323 | input[type="submit"], 1324 | input[type="reset"], 1325 | input[type="button"], 1326 | .button { 1327 | &:hover, &:active { 1328 | background-color: _palette(border-bg) !important; 1329 | box-shadow: inset 0 0 0 1px _palette(border2) !important; 1330 | color: _palette(fg-bold) !important; 1331 | } 1332 | 1333 | &:active { 1334 | background-color: _palette(border2-bg) !important; 1335 | } 1336 | 1337 | &.primary { 1338 | background-color: _palette(fg-bold); 1339 | color: _palette(accent1) !important; 1340 | 1341 | &:hover, &:active { 1342 | background-color: _palette(border-bg) !important; 1343 | box-shadow: inset 0 0 0 1px _palette(border2) !important; 1344 | color: _palette(fg-bold) !important; 1345 | } 1346 | 1347 | &:active { 1348 | background-color: _palette(border2-bg) !important; 1349 | } 1350 | } 1351 | } 1352 | } 1353 | 1354 | &.fade-down { 1355 | > .container { 1356 | @include vendor('transform', 'translate(0,0)'); 1357 | @include vendor('transition', 'transform 1s ease, opacity 1s ease'); 1358 | opacity: 1; 1359 | } 1360 | 1361 | &.inactive { 1362 | > .container { 1363 | @include vendor('transform', 'translate(0,-1em)'); 1364 | opacity: 0; 1365 | } 1366 | } 1367 | } 1368 | 1369 | &.fade-up { 1370 | > .container { 1371 | @include vendor('transform', 'translate(0,0)'); 1372 | @include vendor('transition', 'transform 1s ease, opacity 1s ease'); 1373 | opacity: 1; 1374 | } 1375 | 1376 | &.inactive { 1377 | > .container { 1378 | @include vendor('transform', 'translate(0,1em)'); 1379 | opacity: 0; 1380 | } 1381 | } 1382 | } 1383 | 1384 | &.fade { 1385 | > .container { 1386 | @include vendor('transition', 'opacity 1s ease'); 1387 | opacity: 1; 1388 | } 1389 | 1390 | &.inactive { 1391 | > .container { 1392 | opacity: 0; 1393 | } 1394 | } 1395 | } 1396 | } 1397 | 1398 | /* Dropotron */ 1399 | 1400 | .dropotron { 1401 | background: _palette(accent2-transparent); 1402 | border-radius: _size(border-radius); 1403 | box-shadow: 0 0.075em 0.35em 0 rgba(0,0,0,0.125); 1404 | list-style: none; 1405 | margin-top: calc(-0.25em + 1px); 1406 | min-width: 12em; 1407 | padding: 0.25em 0; 1408 | 1409 | > li { 1410 | border-top: solid 1px rgba(255,255,255,0.035); 1411 | padding: 0; 1412 | 1413 | a, span { 1414 | border: 0; 1415 | color: _palette(fg); 1416 | display: block; 1417 | padding: 0.1em 1em; 1418 | text-decoration: none; 1419 | } 1420 | 1421 | &:first-child { 1422 | border-top: 0; 1423 | } 1424 | 1425 | &.active { 1426 | > a, > span { 1427 | color: _palette(accent1); 1428 | } 1429 | } 1430 | } 1431 | 1432 | &.level-0 { 1433 | font-size: 0.8em; 1434 | margin-top: 1em; 1435 | 1436 | &:before { 1437 | @include vendor('transform', 'rotate(45deg)'); 1438 | background: _palette(accent2); 1439 | content: ''; 1440 | display: block; 1441 | height: 1em; 1442 | position: absolute; 1443 | right: 1.5em; 1444 | top: -0.5em; 1445 | width: 1em; 1446 | } 1447 | } 1448 | } 1449 | 1450 | body.landing { 1451 | .dropotron { 1452 | &.level-0 { 1453 | margin-top: 0; 1454 | } 1455 | } 1456 | } 1457 | 1458 | /* Header */ 1459 | 1460 | #page-wrapper { 1461 | padding-top: 3.5em; 1462 | } 1463 | 1464 | #header { 1465 | background: _palette(accent2-transparent); 1466 | box-shadow: 0 0 0.25em 0 rgba(0,0,0,0.25); 1467 | cursor: default; 1468 | height: 3.5em; 1469 | left: 0; 1470 | line-height: 3.5em; 1471 | position: fixed; 1472 | top: 0; 1473 | width: 100%; 1474 | z-index: 100; 1475 | 1476 | h1 { 1477 | height: inherit; 1478 | left: 1.25em; 1479 | line-height: inherit; 1480 | margin: 0; 1481 | position: absolute; 1482 | top: 0; 1483 | } 1484 | 1485 | nav { 1486 | position: absolute; 1487 | right: 1em; 1488 | top: 0; 1489 | 1490 | ul { 1491 | margin: 0; 1492 | 1493 | li { 1494 | display: inline-block; 1495 | margin-left: 1em; 1496 | 1497 | a, span { 1498 | border: 0; 1499 | color: inherit; 1500 | display: inline-block; 1501 | height: inherit; 1502 | line-height: inherit; 1503 | outline: 0; 1504 | 1505 | &.button { 1506 | height: 2em; 1507 | line-height: 2em; 1508 | padding: 0 1.25em; 1509 | } 1510 | 1511 | &:not(.button):before { 1512 | margin-right: 0.5em; 1513 | } 1514 | } 1515 | 1516 | &.active { 1517 | > a, > span { 1518 | color: _palette(accent1); 1519 | } 1520 | } 1521 | 1522 | > ul { 1523 | display: none; 1524 | } 1525 | } 1526 | } 1527 | } 1528 | } 1529 | 1530 | body.landing { 1531 | #page-wrapper { 1532 | padding-top: 0; 1533 | } 1534 | 1535 | #header { 1536 | background: transparent; 1537 | box-shadow: none; 1538 | position: absolute; 1539 | } 1540 | } 1541 | 1542 | /* Banner */ 1543 | 1544 | #banner { 1545 | background-attachment: fixed; 1546 | background-color: _palette(accent2); 1547 | background-image: url('../../images/banner.jpg'); 1548 | background-position: center center; 1549 | background-size: cover; 1550 | box-shadow: 0 0.25em 0.5em 0 rgba(0,0,0,0.25); 1551 | min-height: 100vh; 1552 | position: relative; 1553 | text-align: center; 1554 | z-index: (_misc(max-spotlight) + 1); 1555 | 1556 | &:before { 1557 | content: ''; 1558 | display: inline-block; 1559 | height: 100vh; 1560 | vertical-align: middle; 1561 | width: 1%; 1562 | } 1563 | 1564 | &:after { 1565 | @include vendor('background-image', ('linear-gradient(top, #{_palette(bg-transparent)}, #{_palette(bg-transparent)})', 'url("images/overlay.png");')); 1566 | content: ''; 1567 | display: block; 1568 | height: 100%; 1569 | left: 0; 1570 | position: absolute; 1571 | top: 0; 1572 | width: 100%; 1573 | } 1574 | 1575 | .content { 1576 | display: inline-block; 1577 | margin-right: 1%; 1578 | max-width: 95%; 1579 | padding: $size-wrapper-pad-tb; 1580 | position: relative; 1581 | text-align: right; 1582 | vertical-align: middle; 1583 | z-index: 1; 1584 | 1585 | header { 1586 | display: inline-block; 1587 | vertical-align: middle; 1588 | 1589 | h2 { 1590 | font-size: 2.5em; 1591 | margin: 0; 1592 | } 1593 | 1594 | p { 1595 | margin: (_size(element-margin) * 0.25) 0 0 0; 1596 | top: 0; 1597 | } 1598 | } 1599 | 1600 | .image { 1601 | border-radius: 100%; 1602 | display: inline-block; 1603 | height: 18em; 1604 | margin-left: 3em; 1605 | vertical-align: middle; 1606 | width: 18em; 1607 | 1608 | img { 1609 | border-radius: 100%; 1610 | display: block; 1611 | width: 100%; 1612 | } 1613 | } 1614 | } 1615 | } 1616 | 1617 | body.is-touch { 1618 | #banner { 1619 | background-attachment: scroll; 1620 | } 1621 | } 1622 | 1623 | /* Footer */ 1624 | 1625 | #footer { 1626 | background: _palette(accent2); 1627 | padding: $size-wrapper-pad-tb 0; 1628 | text-align: center; 1629 | 1630 | .icons { 1631 | .icon { 1632 | &.alt { 1633 | @include line-icon(_palette(accent2), _palette(fg-light)); 1634 | } 1635 | } 1636 | } 1637 | 1638 | .copyright { 1639 | color: _palette(fg-light); 1640 | font-size: 0.8em; 1641 | line-height: 1em; 1642 | margin: 2em 0 0 0; 1643 | padding: 0; 1644 | text-align: center; 1645 | 1646 | li { 1647 | border-left: solid 1px _palette(border); 1648 | display: inline-block; 1649 | list-style: none; 1650 | margin-left: 1.5em; 1651 | padding-left: 1.5em; 1652 | 1653 | &:first-child { 1654 | border-left: 0; 1655 | margin-left: 0; 1656 | padding-left: 0; 1657 | } 1658 | 1659 | a { 1660 | color: inherit; 1661 | } 1662 | } 1663 | } 1664 | } 1665 | 1666 | /* XLarge */ 1667 | 1668 | @include breakpoint('<=xlarge') { 1669 | 1670 | /* Basic */ 1671 | 1672 | body, input, select, textarea { 1673 | font-size: 13pt; 1674 | } 1675 | 1676 | } 1677 | 1678 | /* Large */ 1679 | 1680 | @include breakpoint('<=large') { 1681 | 1682 | $size-wrapper-pad-tb: 4.5em; 1683 | $size-wrapper-pad-lr: 2.5em; 1684 | 1685 | /* Basic */ 1686 | 1687 | body, input, select, textarea { 1688 | font-size: 11.5pt; 1689 | } 1690 | 1691 | /* Spotlight */ 1692 | 1693 | .spotlight { 1694 | &.top { 1695 | .content { 1696 | padding: ($size-wrapper-pad-tb * 0.85) 0 (($size-wrapper-pad-tb * 0.85) - _size(element-margin)) 0; 1697 | } 1698 | } 1699 | 1700 | &.bottom { 1701 | .content { 1702 | padding: ($size-wrapper-pad-tb * 0.85) 0 (($size-wrapper-pad-tb * 1.1) - _size(element-margin)) 0; 1703 | } 1704 | } 1705 | 1706 | &.left, &.right { 1707 | .content { 1708 | padding: $size-wrapper-pad-tb $size-wrapper-pad-lr; 1709 | width: 25em; 1710 | } 1711 | } 1712 | } 1713 | 1714 | /* Wrapper */ 1715 | 1716 | .wrapper { 1717 | padding: $size-wrapper-pad-tb 0 ($size-wrapper-pad-tb - _size(element-margin)) 0; 1718 | } 1719 | 1720 | /* Dropotron */ 1721 | 1722 | .dropotron { 1723 | &.level-0 { 1724 | font-size: 1em; 1725 | } 1726 | } 1727 | 1728 | /* Banner */ 1729 | 1730 | #banner { 1731 | .content { 1732 | padding: $size-wrapper-pad-tb; 1733 | } 1734 | } 1735 | 1736 | /* Footer */ 1737 | 1738 | #footer { 1739 | padding: $size-wrapper-pad-tb 0; 1740 | } 1741 | 1742 | } 1743 | 1744 | /* Medium */ 1745 | 1746 | @include breakpoint('<=medium') { 1747 | 1748 | $size-wrapper-pad-tb: 4.5em; 1749 | $size-wrapper-pad-lr: 2.5em; 1750 | 1751 | /* Basic */ 1752 | 1753 | body, input, select, textarea { 1754 | font-size: 12pt; 1755 | } 1756 | 1757 | /* Spotlight */ 1758 | 1759 | .spotlight { 1760 | background-attachment: scroll; 1761 | height: auto; 1762 | 1763 | .image.main { 1764 | display: block; 1765 | margin: 0; 1766 | max-height: 40vh; 1767 | overflow: hidden; 1768 | } 1769 | 1770 | .content { 1771 | background-color: _palette(bg); 1772 | border-width: 0 !important; 1773 | border-top-width: 0.35em !important; 1774 | bottom: auto !important; 1775 | left: auto !important; 1776 | padding: $size-wrapper-pad-tb $size-wrapper-pad-lr ($size-wrapper-pad-tb - _size(element-margin)) $size-wrapper-pad-lr !important; 1777 | position: relative; 1778 | right: auto !important; 1779 | text-align: center; 1780 | top: auto !important; 1781 | width: 100% !important; 1782 | 1783 | ul.actions { 1784 | @include vendor('justify-content', 'center'); 1785 | width: 100%; 1786 | margin-left: 0; 1787 | 1788 | li { 1789 | &:first-child { 1790 | padding-left: 0; 1791 | } 1792 | } 1793 | } 1794 | } 1795 | 1796 | .goto-next { 1797 | display: none; 1798 | } 1799 | } 1800 | 1801 | /* Wrapper */ 1802 | 1803 | .wrapper { 1804 | padding: $size-wrapper-pad-tb $size-wrapper-pad-lr ($size-wrapper-pad-tb - _size(element-margin)) $size-wrapper-pad-lr; 1805 | } 1806 | 1807 | /* Banner */ 1808 | 1809 | #banner { 1810 | background-attachment: scroll; 1811 | 1812 | .goto-next { 1813 | height: 7em; 1814 | } 1815 | 1816 | .content { 1817 | padding: ($size-wrapper-pad-tb * 2) 0; 1818 | text-align: center; 1819 | 1820 | header { 1821 | display: block; 1822 | margin: 0 0 _size(element-margin) 0; 1823 | text-align: center; 1824 | } 1825 | 1826 | .image { 1827 | margin: 0; 1828 | } 1829 | } 1830 | } 1831 | 1832 | /* Footer */ 1833 | 1834 | #footer { 1835 | padding: $size-wrapper-pad-tb 0; 1836 | } 1837 | 1838 | } 1839 | 1840 | /* Small */ 1841 | 1842 | #navPanel, #titleBar { 1843 | display: none; 1844 | } 1845 | 1846 | @include breakpoint('<=small') { 1847 | 1848 | $size-wrapper-pad-tb: 3.25em; 1849 | $size-wrapper-pad-lr: 1.5em; 1850 | 1851 | /* Basic */ 1852 | 1853 | html, body { 1854 | overflow-x: hidden; 1855 | } 1856 | 1857 | body, input, select, textarea { 1858 | font-size: 12pt; 1859 | } 1860 | 1861 | h2 { 1862 | font-size: 1.5em; 1863 | } 1864 | 1865 | h3 { 1866 | font-size: 1.2em; 1867 | } 1868 | 1869 | h4 { 1870 | font-size: 1em; 1871 | } 1872 | 1873 | /* Section/Article */ 1874 | 1875 | header { 1876 | p { 1877 | br { 1878 | display: none; 1879 | } 1880 | } 1881 | 1882 | h2 + p { 1883 | font-size: 1em; 1884 | } 1885 | 1886 | h3 + p { 1887 | font-size: 1em; 1888 | } 1889 | 1890 | h4 + p, 1891 | h5 + p, 1892 | h6 + p { 1893 | font-size: 0.9em; 1894 | } 1895 | 1896 | &.major { 1897 | margin: 0 0 _size(element-margin) 0; 1898 | } 1899 | } 1900 | 1901 | /* Goto Next */ 1902 | 1903 | .goto-next { 1904 | &:before { 1905 | height: 0.8em; 1906 | margin: -0.4em 0 0 -0.6em; 1907 | width: 1.2em; 1908 | } 1909 | } 1910 | 1911 | /* Spotlight */ 1912 | 1913 | .spotlight { 1914 | box-shadow: 0 0.125em 0.5em 0 rgba(0,0,0,0.25); 1915 | 1916 | .image.main { 1917 | max-height: 60vh; 1918 | } 1919 | 1920 | .content { 1921 | border-top-width: 0.2em !important; 1922 | padding: $size-wrapper-pad-tb $size-wrapper-pad-lr ($size-wrapper-pad-tb - _size(element-margin)) $size-wrapper-pad-lr !important; 1923 | } 1924 | } 1925 | 1926 | /* Wrapper */ 1927 | 1928 | .wrapper { 1929 | padding: $size-wrapper-pad-tb $size-wrapper-pad-lr ($size-wrapper-pad-tb - _size(element-margin)) $size-wrapper-pad-lr; 1930 | } 1931 | 1932 | /* Header */ 1933 | 1934 | #header { 1935 | display: none; 1936 | } 1937 | 1938 | /* Banner */ 1939 | 1940 | #banner { 1941 | box-shadow: 0 0.125em 0.5em 0 rgba(0,0,0,0.25); 1942 | min-height: calc(100vh - 44px); 1943 | 1944 | &:before { 1945 | height: calc(100vh - 44px); 1946 | } 1947 | 1948 | .content { 1949 | padding: ($size-wrapper-pad-tb * 1.25) $size-wrapper-pad-lr ($size-wrapper-pad-tb * 1.5) $size-wrapper-pad-lr; 1950 | 1951 | header { 1952 | h2 { 1953 | font-size: 1.5em; 1954 | } 1955 | } 1956 | 1957 | .image { 1958 | height: 9em; 1959 | width: 9em; 1960 | } 1961 | } 1962 | } 1963 | 1964 | /* Nav */ 1965 | 1966 | #page-wrapper { 1967 | @include vendor('backface-visibility', 'hidden'); 1968 | @include vendor('transition', 'transform #{_duration(navPanel)} ease'); 1969 | padding-bottom: 1px; 1970 | padding-top: 44px !important; 1971 | } 1972 | 1973 | #titleBar { 1974 | @include vendor('backface-visibility', 'hidden'); 1975 | @include vendor('transition', 'transform #{_duration(navPanel)} ease'); 1976 | display: block; 1977 | height: 44px; 1978 | left: 0; 1979 | position: fixed; 1980 | top: 0; 1981 | width: 100%; 1982 | z-index: _misc(z-index-base) + 1; 1983 | background: _palette(accent2); 1984 | box-shadow: 0 0.125em 0.125em 0 rgba(0,0,0,0.125); 1985 | 1986 | .title { 1987 | color: _palette(fg-bold); 1988 | display: block; 1989 | font-weight: _font(weight-bold); 1990 | height: 44px; 1991 | line-height: 44px; 1992 | text-align: center; 1993 | 1994 | a { 1995 | color: inherit; 1996 | border: 0; 1997 | } 1998 | } 1999 | 2000 | .toggle { 2001 | @include icon(false, solid); 2002 | height: 60px; 2003 | left: 0; 2004 | position: absolute; 2005 | top: 0; 2006 | width: 90px; 2007 | outline: 0; 2008 | border: 0; 2009 | 2010 | &:before { 2011 | background: _palette(accent1); 2012 | color: _palette(fg-light); 2013 | content: '\f0c9'; 2014 | display: block; 2015 | font-size: 18px; 2016 | height: 44px; 2017 | left: 0; 2018 | line-height: 44px; 2019 | position: absolute; 2020 | text-align: center; 2021 | top: 0; 2022 | width: 54px; 2023 | } 2024 | } 2025 | } 2026 | 2027 | #navPanel { 2028 | @include vendor('backface-visibility', 'hidden'); 2029 | @include vendor('transform', 'translateX(#{_size(navPanel) * -1})'); 2030 | @include vendor('transition', ('transform #{_duration(navPanel)} ease')); 2031 | display: block; 2032 | height: 100%; 2033 | left: 0; 2034 | overflow-y: auto; 2035 | position: fixed; 2036 | top: 0; 2037 | width: _size(navPanel); 2038 | z-index: _misc(z-index-base) + 2; 2039 | background: darken(_palette(bg), 2); 2040 | padding: 0.75em 1.25em; 2041 | 2042 | .link { 2043 | border: 0; 2044 | border-top: solid 1px transparentize(_palette(border), 0.25); 2045 | color: _palette(fg); 2046 | display: block; 2047 | height: 3em; 2048 | line-height: 3em; 2049 | text-decoration: none; 2050 | 2051 | &:hover { 2052 | color: inherit !important; 2053 | } 2054 | 2055 | &:first-child { 2056 | border-top: 0; 2057 | } 2058 | 2059 | &.depth-0 { 2060 | color: _palette(fg-bold); 2061 | font-weight: _font(weight-bold); 2062 | } 2063 | 2064 | .indent-1 { display: inline-block; width: 1.25em; } 2065 | .indent-2 { display: inline-block; width: 2.5em; } 2066 | .indent-3 { display: inline-block; width: 3.75em; } 2067 | .indent-4 { display: inline-block; width: 5em; } 2068 | .indent-5 { display: inline-block; width: 6.25em; } 2069 | } 2070 | } 2071 | 2072 | body { 2073 | &.navPanel-visible { 2074 | #page-wrapper { 2075 | @include vendor('transform', 'translateX(#{_size(navPanel)})'); 2076 | } 2077 | 2078 | #titleBar { 2079 | @include vendor('transform', 'translateX(#{_size(navPanel)})'); 2080 | } 2081 | 2082 | #navPanel { 2083 | @include vendor('transform', 'translateX(0)'); 2084 | } 2085 | } 2086 | } 2087 | 2088 | /* Footer */ 2089 | 2090 | #footer { 2091 | padding: $size-wrapper-pad-tb $size-wrapper-pad-lr; 2092 | } 2093 | 2094 | } 2095 | 2096 | /* XSmall */ 2097 | 2098 | @include breakpoint('<=xsmall') { 2099 | 2100 | $size-wrapper-pad-tb: 3em; 2101 | $size-wrapper-pad-lr: 1.25em; 2102 | 2103 | /* Basic */ 2104 | 2105 | html, body { 2106 | min-width: 320px; 2107 | } 2108 | 2109 | body, input, select, textarea { 2110 | font-size: 12pt; 2111 | } 2112 | 2113 | /* Button */ 2114 | 2115 | input[type="submit"], 2116 | input[type="reset"], 2117 | input[type="button"], 2118 | .button { 2119 | padding: 0; 2120 | } 2121 | 2122 | /* Spotlight */ 2123 | 2124 | .spotlight { 2125 | .image.main { 2126 | max-height: 50vh; 2127 | } 2128 | 2129 | .content { 2130 | padding: $size-wrapper-pad-tb $size-wrapper-pad-lr ($size-wrapper-pad-tb - _size(element-margin)) $size-wrapper-pad-lr !important; 2131 | } 2132 | } 2133 | 2134 | /* Wrapper */ 2135 | 2136 | .wrapper { 2137 | padding: $size-wrapper-pad-tb $size-wrapper-pad-lr ($size-wrapper-pad-tb - _size(element-margin)) $size-wrapper-pad-lr; 2138 | } 2139 | 2140 | /* Banner */ 2141 | 2142 | #banner { 2143 | .content { 2144 | padding: $size-wrapper-pad-tb ($size-wrapper-pad-lr * 1.25) ($size-wrapper-pad-tb * 1.75) ($size-wrapper-pad-lr * 1.25); 2145 | } 2146 | } 2147 | 2148 | /* Footer */ 2149 | 2150 | #footer { 2151 | padding: $size-wrapper-pad-tb $size-wrapper-pad-lr; 2152 | 2153 | .copyright { 2154 | line-height: inherit; 2155 | 2156 | li { 2157 | border-left: 0; 2158 | display: block; 2159 | margin: 0; 2160 | padding: 0; 2161 | } 2162 | } 2163 | } 2164 | 2165 | } -------------------------------------------------------------------------------- /public/assets/sass/noscript.scss: -------------------------------------------------------------------------------- 1 | @import 'libs/vars'; 2 | @import 'libs/functions'; 3 | @import 'libs/mixins'; 4 | @import 'libs/vendor'; 5 | @import 'libs/breakpoints'; 6 | @import 'libs/html-grid'; 7 | 8 | /* 9 | Landed by HTML5 UP 10 | html5up.net | @ajlkn 11 | Free for personal and commercial use under the CCA 3.0 license (html5up.net/license) 12 | */ 13 | 14 | /* Loader */ 15 | 16 | body.landing { 17 | 18 | &.is-preload { 19 | 20 | // Spinner (active) 21 | 22 | &:before { 23 | display: none; 24 | } 25 | 26 | // Overlay (active) 27 | 28 | &:after { 29 | display: none; 30 | } 31 | 32 | } 33 | } -------------------------------------------------------------------------------- /public/assets/webfonts/fa-brands-400.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-brands-400.eot -------------------------------------------------------------------------------- /public/assets/webfonts/fa-brands-400.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-brands-400.ttf -------------------------------------------------------------------------------- /public/assets/webfonts/fa-brands-400.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-brands-400.woff -------------------------------------------------------------------------------- /public/assets/webfonts/fa-brands-400.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-brands-400.woff2 -------------------------------------------------------------------------------- /public/assets/webfonts/fa-regular-400.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-regular-400.eot -------------------------------------------------------------------------------- /public/assets/webfonts/fa-regular-400.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-regular-400.ttf -------------------------------------------------------------------------------- /public/assets/webfonts/fa-regular-400.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-regular-400.woff -------------------------------------------------------------------------------- /public/assets/webfonts/fa-regular-400.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-regular-400.woff2 -------------------------------------------------------------------------------- /public/assets/webfonts/fa-solid-900.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-solid-900.eot -------------------------------------------------------------------------------- /public/assets/webfonts/fa-solid-900.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-solid-900.ttf -------------------------------------------------------------------------------- /public/assets/webfonts/fa-solid-900.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-solid-900.woff -------------------------------------------------------------------------------- /public/assets/webfonts/fa-solid-900.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/assets/webfonts/fa-solid-900.woff2 -------------------------------------------------------------------------------- /public/images/banner.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/banner.jpg -------------------------------------------------------------------------------- /public/images/cabin.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/cabin.jpg -------------------------------------------------------------------------------- /public/images/mountain1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/mountain1.jpg -------------------------------------------------------------------------------- /public/images/mountain2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/mountain2.jpg -------------------------------------------------------------------------------- /public/images/mountain3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/mountain3.jpg -------------------------------------------------------------------------------- /public/images/palm1.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/palm1.jpeg -------------------------------------------------------------------------------- /public/images/palm2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/palm2.jpg -------------------------------------------------------------------------------- /public/images/palm3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/palm3.jpg -------------------------------------------------------------------------------- /public/images/pic01.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/pic01.jpg -------------------------------------------------------------------------------- /public/images/pic02.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/pic02.jpg -------------------------------------------------------------------------------- /public/images/pic03.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/pic03.jpg -------------------------------------------------------------------------------- /public/images/pic04.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/pic04.jpg -------------------------------------------------------------------------------- /public/images/pic05.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/pic05.jpg -------------------------------------------------------------------------------- /public/images/pic06.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/pic06.jpg -------------------------------------------------------------------------------- /public/images/pic07.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/pic07.jpg -------------------------------------------------------------------------------- /public/images/pic08.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/images/pic08.jpg -------------------------------------------------------------------------------- /public/img/savage21.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/CharlesCreativeContent/Demo-Day/5edaca7e552d2687131152ccfd3a63de716f6ab0/public/img/savage21.jpg -------------------------------------------------------------------------------- /public/main.js: -------------------------------------------------------------------------------- 1 | 2 | var trash = document.getElementsByClassName("fa-trash"); 3 | 4 | 5 | Array.from(trash).forEach(function(element) { 6 | element.addEventListener('click', function(){ 7 | const name = this.parentNode.parentNode.childNodes[1].innerText 8 | const msg = this.parentNode.parentNode.childNodes[3].innerText 9 | fetch('messages', { 10 | method: 'delete', 11 | headers: { 12 | 'Content-Type': 'application/json' 13 | }, 14 | body: JSON.stringify({ 15 | 'name': name, 16 | 'msg': msg 17 | }) 18 | }).then(function (response) { 19 | window.location.reload() 20 | }) 21 | }); 22 | }); 23 | 24 | //Will Move this server side if I can, but AIRBNB is making it hard to make a query directly from the server // 25 | //More Notes in routes.js // 26 | fetch("https://mashvisor-api.p.rapidapi.com/airbnb-property/top-reviewed?page=1&city=Los%20Angeles&reviews_count=30&zip_code=91342&state=CA", { 27 | "method": "GET", 28 | "headers": { 29 | "x-rapidapi-host": "mashvisor-api.p.rapidapi.com", 30 | "x-rapidapi-key": "3ae1d00c97msh298612aebb81230p11684djsn405007844583" 31 | } 32 | }) 33 | .then(response => response.json()) 34 | .then(data => { 35 | console.log("Couldn't get everything into the Server yet, hoping I will figure it out Soon. More Notes in routes.js") 36 | console.log(data.content.list) 37 | data.content.list.forEach(x=>{ 38 | let listItem = document.createElement('li') 39 | let title = document.createElement('h4') 40 | let titleContent = document.createTextNode(`${x.name}`) 41 | title.appendChild(titleContent) 42 | listItem.appendChild(title) 43 | let address = document.createElement('h6') 44 | let addressContent = document.createTextNode(`${x.address} | ${x.star_rating}`) 45 | address.appendChild(addressContent) 46 | let star = document.createElement('i') 47 | star.classList = "fa fa-star" 48 | address.appendChild(star) 49 | listItem.appendChild(address) 50 | let image = document.createElement('img') 51 | image.src = x.picture_url 52 | listItem.appendChild(image) 53 | let img2 = document.createElement('img') 54 | img2.src = x.map_image_url 55 | listItem.appendChild(img2) 56 | let description = document.createElement('p') 57 | let desContent = document.createTextNode(`${x.summary}`) 58 | description.appendChild(desContent) 59 | listItem.appendChild(description) 60 | document.querySelector('ol').appendChild(listItem) 61 | }) 62 | }) 63 | -------------------------------------------------------------------------------- /public/style.css: -------------------------------------------------------------------------------- 1 | body{ 2 | padding-top:80px; 3 | word-wrap:break-word; 4 | } 5 | img{ 6 | height: 200px; 7 | } 8 | -------------------------------------------------------------------------------- /server.js: -------------------------------------------------------------------------------- 1 | // server.js 2 | 3 | // set up ====================================================================== 4 | // get all the tools we need 5 | var express = require('express'); 6 | var app = express(); 7 | var port = process.env.PORT || 8080; 8 | const MongoClient = require('mongodb').MongoClient 9 | var mongoose = require('mongoose'); 10 | var passport = require('passport'); 11 | var flash = require('connect-flash'); 12 | 13 | var morgan = require('morgan'); 14 | var cookieParser = require('cookie-parser'); 15 | var bodyParser = require('body-parser'); 16 | var session = require('express-session'); 17 | 18 | 19 | var configDB = require('./config/database.js'); 20 | 21 | var db 22 | 23 | // configuration =============================================================== 24 | mongoose.connect(configDB.url, (err, database) => { 25 | if (err) return console.log(err) 26 | db = database 27 | require('./app/routes.js')(app, passport, db); 28 | }); // connect to our database 29 | 30 | //app.listen(port, () => { 31 | // MongoClient.connect(configDB.url, { useNewUrlParser: true }, (error, client) => { 32 | // if(error) { 33 | // throw error; 34 | // } 35 | // db = client.db(configDB.dbName); 36 | // console.log("Connected to `" + configDB.dbName + "`!"); 37 | // require('./app/routes.js')(app, passport, db); 38 | // }); 39 | //}); 40 | 41 | require('./config/passport')(passport); // pass passport for configuration 42 | 43 | // set up our express application 44 | app.use(morgan('dev')); // log every request to the console 45 | app.use(cookieParser()); // read cookies (needed for auth) 46 | app.use(bodyParser.json()); // get information from html forms 47 | app.use(bodyParser.urlencoded({ extended: true })); 48 | app.use(express.static('public')) 49 | 50 | app.set('view engine', 'ejs'); // set up ejs for templating 51 | 52 | // required for passport 53 | app.use(session({ 54 | secret: 'rcbootcamp2019a', // session secret 55 | resave: true, 56 | saveUninitialized: true 57 | })); 58 | app.use(passport.initialize()); 59 | app.use(passport.session()); // persistent login sessions 60 | app.use(flash()); // use connect-flash for flash messages stored in session 61 | 62 | 63 | // routes ====================================================================== 64 | //require('./app/routes.js')(app, passport, db); // load our routes and pass in our app and fully configured passport 65 | 66 | // launch ====================================================================== 67 | app.listen(port); 68 | console.log('The magic happens on port ' + port); 69 | -------------------------------------------------------------------------------- /views/connect-local.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 21 Savage Fan Site 5 | 6 | 7 | 8 | 9 | 10 |
11 |
12 | 13 |

Add Local Account

14 | 15 | <% if (message.length > 0) { %> 16 |
<%= message %>
17 | <% } %> 18 | 19 | 20 |
21 |
22 | 23 | 24 |
25 |
26 | 27 | 28 |
29 | 30 | 31 |
32 | 33 |
34 | 35 |

Go back to profile

36 | 37 | 38 |
39 |
40 | 41 | 42 | -------------------------------------------------------------------------------- /views/index.ejs: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 9 | Lucid Dream Vacations 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 29 | 30 | 31 | 42 | 43 | 44 |
45 | 46 |
47 |
48 |
49 |
50 |
51 |

Unmacthed Quality

52 |
53 |

All reviews are 5 stars, we have no unhappy customers. We are absolutely the best!
You Can Believe Us, We wouldn't lie to you!

54 | 55 |
56 |
57 |

Some Stuff about our Amazingness!

58 |
59 |
60 |

Save Time and Money

61 |

You will reclaim those countless wasted hours researching or talking to a travel agent. If our unmatched quality isn't a selling point for you, maybe saving time and money is!

62 |
63 |
64 |
65 |
66 | Next 67 |
68 | 69 | 70 |
71 | 72 |
73 |
74 |

Something goes here, but I'm to tired to make something up

75 |

Imagine you are on a mountain, looking out of the window of your log cabin, sipping on some hot coco with 2 marshmellows!

76 |
77 |

Your so close to the vacation you could probably taste it!

78 | 81 |
82 | Next 83 |
84 | 85 | 86 |
87 | 88 |
89 |
90 |

That crisp mountain air!

91 |

If you weren't seeing it with your own eyes, you'd probably think it was photoshopped.

92 |
93 |

Something Witty!

94 | 97 |
98 | Next 99 |
100 | 101 | 102 |
103 |
104 |
105 |

Happy Customers!

106 |

Don't take our word for it! Here's some reviews

107 |
108 |
109 |
110 |
111 | 112 |

Santa Clause

113 |

"Lucid is awesome and the man who made it will be on my nice list forever"

114 |
115 |
116 | 117 |

Jesus Christ

118 |

"Lucid is beyond compare. I booked a 3-day vacation so amazing, I was walking on water!"

119 |
120 |
121 | 122 |

Shawn's Mom

123 |

"Lucid is by far the best app I have ever used and I'm not saying that just because he paid me!"

124 |
125 |
126 | 127 |

Some Random Guy We definitely didn't pay

128 |

"I don't know how I survived so long without Lucid. Would definitely give this 5 stars!"

129 |
130 |
131 | 132 |

Leon Noel

133 |

"This Demo-Day Project is so amazing that I'm going to give Shawn 50 leon points! You 360 Slam Dunked It!"

134 |
135 |
136 | 137 |

Another Guy We also Didn't Pay

138 |

"If I was being payed would I say 'Lucid is the future and better than any app in existence'? Exactly!"

139 |
140 |
141 |
142 | 147 |
148 |
149 | 150 | 151 |
152 |
153 |
154 |

This is our Contact Sheet

155 |

Fill it out. Or don't we already have your information anyway

156 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 | 166 | 167 | 180 | 181 |
182 | 183 | 184 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | 193 | 194 | 195 | -------------------------------------------------------------------------------- /views/login.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 21 Savage Fan Site 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
14 |
15 | 16 |

Login

17 | 18 | <% if (message.length > 0) { %> 19 |
<%= message %>
20 | <% } %> 21 | 22 | 23 |
24 |
25 | 26 | 27 |
28 |
29 | 30 | 31 |
32 | 33 | 34 |
35 | 36 |
37 | 38 |

Need an account? Signup

39 |

Or go home.

40 | 41 | 42 |
43 |
44 | 45 | 46 | -------------------------------------------------------------------------------- /views/profile.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 21 Savage Fan Site 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
14 | 15 | 19 |
    20 | 21 |
    22 |
    23 |

    Messages

    24 |
      25 | <% for(var i=0; i 26 |
    • 27 | <%= messages[i].name %> 28 | <%= messages[i].msg %> 29 | <%= messages[i].thumbUp %> 30 | 31 | 32 | 33 |
    • 34 | <% } %> 35 |
    36 | 37 |

    Add a message

    38 | <% if (user.local.email) { %> 39 |
    40 | 41 | 42 | 43 |
    44 |
    45 | <% } %> 46 | 47 |
    48 |
    49 | 50 | 51 | 52 | 53 | 54 | 60 | -------------------------------------------------------------------------------- /views/signup.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 21 Savage Fan Site 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |
    14 |
    15 | 16 |

    Signup

    17 | 18 | <% if (message.length > 0) { %> 19 |
    <%= message %>
    20 | <% } %> 21 | 22 | 23 |
    24 |
    25 | 26 | 27 |
    28 |
    29 | 30 | 31 |
    32 | 33 | 34 |
    35 | 36 |
    37 | 38 |

    Already have an account? Login

    39 |

    Or go home.

    40 | 41 |
    42 |
    43 | 44 | 45 | --------------------------------------------------------------------------------