This file contains hidden or 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
angular.module('app').filter("words", function() { | |
return function(input, words) { | |
if (isNaN(words)) return input; | |
if (words<=0) return ''; | |
if(input) { | |
var inputWords = input.split(/\s+/); | |
if (inputWords.length > words) { | |
input = inputWords.slice(0, words).join(' ') + '...'; | |
} | |
} |
This file contains hidden or 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
angular.module('app').filter('characters', function () { | |
return function(input, chars) { | |
if (isNaN(chars)) return input; | |
if (chars <= 0) return ''; | |
if(input && input.length >= chars) { | |
input = input.substring(0, chars); | |
var lastspace = input.lastIndexOf(' '); | |
//get last space | |
if (lastspace !== -1) { | |
input = input.substr(0, lastspace); |
This file contains hidden or 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
/** | |
* Reset | |
*/ | |
* { | |
-webkit-box-sizing: border-box; | |
-moz-box-sizing: border-box; | |
box-sizing: border-box; | |
} | |
html, body { |
This file contains hidden or 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
# | |
# Wide-open CORS config for nginx | |
# | |
location / { | |
if ($request_method = 'OPTIONS') { | |
add_header 'Access-Control-Allow-Origin' '*'; | |
# |
This file contains hidden or 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
(function (window, Element, undefined) { | |
'use strict'; | |
var prefix = '', | |
eventPrefix, | |
vendors = { Webkit: 'webkit', Moz: '', O: 'o', ms: 'MS' }, | |
document = window.document, | |
testEl = document.createElement('div'), | |
supportedTransforms = /^((translate|rotate|scale)(X|Y|Z|3d)?|matrix(3d)?|perspective|skew(X|Y)?)$/i, | |
transform, |
This file contains hidden or 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
/* | |
* Vanilla JS - Touch Gestures | |
* @version 0.1 | |
* @inspired QuoJS - http://quojs.tapquo.com | |
* | |
* Supported Gestures: singleTap, doubleTap, hold, | |
* swipe, swiping, swipeLeft, swipeRight, swipeUp, swipeDown, | |
* rotate, rotating, rotateLeft, rotateRight, pinch, pinching, | |
* pinchIn, pinchOut, | |
* drag, dragLeft, dragRight, dragUp, dragDown |
This file contains hidden or 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
// Zepto.js | |
// (c) 2010-2012 Thomas Fuchs | |
// Zepto.js may be freely distributed under the MIT license. | |
(function ($, undefined) { | |
var prefix = '', eventPrefix, endEventName, endAnimationName, | |
vendors = { Webkit: 'webkit', Moz: '', O: 'o', ms: 'MS' }, | |
document = window.document, testEl = document.createElement('div'), docElem = document.documentElement, | |
supportedTransforms = /^((translate|rotate|scale)(X|Y|Z|3d)?|matrix(3d)?|perspective|skew(X|Y)?)$/i, | |
transform, | |
transitionProperty, transitionDuration, transitionTiming, |
This file contains hidden or 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 only screen and (min-device-width: 800px) and (orientation: portrait) { | |
#device:after { | |
content: "Nexus 7 - portrait - firefox"; | |
} | |
} | |
@media screen and (min-device-width : 602px) and (orientation: portrait) { | |
#device:after { | |
content: "Nexus 7 - portrait - chrome"; | |
} | |
} |
This file contains hidden or 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
jQuery Touch Gestures ported from QUOjs | |
@see http://quojs.tapquo.com/ | |
Version 1.1 | |
-- @add singleTap event | |
-- @fix doubleTap event | |
-- @fix hold event |
This file contains hidden or 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
/**********************************************/ | |
/* | |
/* enlightened Theme for Chrome DevTools by Vincent Mac | |
/* Forked from mnml Theme for Chrome DevTools by Michael P. Pfeiffer | |
/* | |
/**********************************************/ | |
#-webkit-web-inspector #main { | |
background-color: #1d1f21 !important; | |
} | |
#-webkit-web-inspector tr { |