This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var eventName = "visibilitychange"; | |
if (document.webkitHidden != undefined) { | |
eventName = "webkitvisibilitychange"; | |
} else if (document.mozHidden != undefined) { | |
eventName = "mozvisibilitychange"; | |
} else if (document.msHidden != undefined) { | |
eventName = "msvisibilitychange"; | |
} else if (document.hidden != undefined) { | |
} else { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Handlebars.registerHelper('eachYear', function(options) { | |
var data = ''; | |
var d = new Date(); // Get user current date | |
var year = d.year; // Get year from date created; | |
for(var x = 1922; x <= year; x++) { | |
data = data + '<option value="' + x + '">' + x + '</option>'; | |
} | |
return data; | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var FormView = Backbone.View.extend({ | |
//No numbers validation | |
nonumbers: function(e){ | |
var a = []; | |
var k = e.which; | |
if(window.Modernizr.IE && (window.Modernizr.lessIE9)) | |
{ | |
var k=e.keyCode? e.keyCode : e.charCode; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Reference: | |
// http://compass-style.org/help/tutorials/spriting/ | |
// http://compass-style.org/help/tutorials/spriting/customization-options/ | |
// Import Compass utility for sprites | |
@import 'compass/utilities/sprites'; | |
// Set spacing | |
$icon-sprite-spacing: 5px; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*global define*/ | |
define([ | |
'jquery', | |
'underscore', | |
'backbone', | |
'models/YourModel' | |
], function($, _, Backbone, YourModel) { | |
'use strict'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@include keyframes(bounce-around) { | |
0% { | |
transform: rotateZ(0deg) translate3d(0,10%,0) rotateZ(0deg); | |
} | |
100% { | |
transform: rotateZ(360deg) translate3d(0,10%,0) rotateZ(-360deg); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
var Backbone = require('backbone'); | |
var Marionette = require('backbone.marionette'); | |
var $ = require('jquery'); | |
var templateHelpers = require('../../../common/helpers/HandlebarsHelpers'); | |
var template = require('../templates/PostCardTemplate.hbs'); | |
module.exports = Backbone.Marionette.ItemView.extend({ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Media query ranges | |
$small-range: (0em, 40em); | |
$medium-range: (40.063em, 63.938em); | |
$large-range: (64em, 89.938em); | |
$xlarge-range: (90em, 119.938em); | |
$xxlarge-range: (120em, 99999999em); | |
// Media query operators | |
$screen: "only screen"; | |
$landscape: " and (orientation: landscape)"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var path = require('path'); | |
var webpack = require('webpack'); | |
var autoprefixer = require('autoprefixer'); | |
var CopyWebpackPlugin = require('copy-webpack-plugin'); | |
var ExtractTextPlugin = require('extract-text-webpack-plugin'); | |
module.exports = { | |
context: path.resolve(__dirname, 'client'), | |
devtool: 'source-map', | |
entry: ['webpack/hot/dev-server', './scripts/app.js'], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var path = require('path'); | |
var webpack = require('webpack'); | |
var autoprefixer = require('autoprefixer'); | |
var CopyWebpackPlugin = require('copy-webpack-plugin'); | |
var ExtractTextPlugin = require('extract-text-webpack-plugin'); | |
module.exports = { | |
context: path.resolve(__dirname, 'client'), | |
devtool: 'source-map', | |
entry: ['./scripts/app.js'], |
OlderNewer