Skip to content

Instantly share code, notes, and snippets.

@sharpmachine
sharpmachine / call.js
Last active August 29, 2015 14:22
Angular service for US States
{
key: 'state',
type: 'select',
templateOptions: {
label: 'State',
// Call our state service to get a list
// of states
options: usState.getUsStates()
},
hideExpression: '!model.email'
@sharpmachine
sharpmachine / call.html
Created July 7, 2015 00:29
Angular Telephone Format Filter
<span>{{ phoneNumber | tel }}</span>
@sharpmachine
sharpmachine / selectAllGood.js
Last active October 23, 2015 21:01
This script creates a checkbox option for users to select all the answers in the good column
var firstRadio = $('.tdNsgAnswerContainer:first-child input[type="radio"]');
var selectAllGood = [
'<div class="NsgQuestionContainer" style="padding-left: 20.8em">',
'<label>',
'<input type="checkbox" id="selectAllGood">',
'Select All Good',
'</label>',
'</div>'
].join(' ');
@sharpmachine
sharpmachine / commands
Created August 26, 2016 19:30
Batch rename commands
rename directories
for file in $(git ls-files | grep nsg- | sed -e 's/\(nsg-[^/]*\).*/\1/' | uniq); git mv $file $(echo $file | sed -e 's/nsg-//') -vn
rename files
for file in $(git ls-files | grep nsg- | uniq); git mv $file $(echo $file | sed -e 's/nsg-//') -vn
@sharpmachine
sharpmachine / hopscotch.min.css
Created February 17, 2017 18:15
Fix for hopscotch css errors
.animated{-webkit-animation-fill-mode:both;-moz-animation-fill-mode:both;-ms-animation-fill-mode:both;-o-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:1s;-moz-animation-duration:1s;-ms-animation-duration:1s;-o-animation-duration:1s;animation-duration:1s}@-webkit-keyframes fadeInUp{0%{opacity:0;-webkit-transform:translateY(20px)}100%{opacity:1;-webkit-transform:translateY(0)}}@-moz-keyframes fadeInUp{0%{opacity:0;-moz-transform:translateY(20px)}100%{opacity:1;-moz-transform:translateY(0)}}@-o-keyframes fadeInUp{0%{opacity:0;-o-transform:translateY(20px)}100%{opacity:1;-o-transform:translateY(0)}}@keyframes fadeInUp{0%{opacity:0;transform:translateY(20px)}100%{opacity:1;transform:translateY(0)}}.fade-in-up{-webkit-animation-name:fadeInUp;-moz-animation-name:fadeInUp;-o-animation-name:fadeInUp;animation-name:fadeInUp}@-webkit-keyframes fadeInDown{0%{opacity:0;-webkit-transform:translateY(-20px)}100%{opacity:1;-webkit-transform:translateY(0)}}@-moz-keyframes fadeInDown{0%{opacity:0;
@sharpmachine
sharpmachine / index.js
Created February 28, 2017 18:35
iisexpress-proxy
#!/usr/bin/env node
process.env['NODE_TLS_REJECT_UNAUTHORIZED'] = '0';
var os = require('os'),
proxy = require('http-proxy'),
pkg = require('./package'),
fs = require('fs');
@sharpmachine
sharpmachine / connecting.json
Created January 25, 2020 16:34
Connection Animation
{"v":"5.6.1","fr":30,"ip":0,"op":48,"w":375,"h":812,"nm":"Comp 1","ddd":0,"assets":[],"layers":[{"ddd":0,"ind":1,"ty":4,"nm":"Shape Layer 3","sr":1,"ks":{"o":{"a":1,"k":[{"i":{"x":[0.833],"y":[0.833]},"o":{"x":[0.167],"y":[0.167]},"t":16,"s":[20]},{"i":{"x":[0.833],"y":[0.833]},"o":{"x":[0.167],"y":[0.167]},"t":20,"s":[20]},{"i":{"x":[0.833],"y":[0.833]},"o":{"x":[0.167],"y":[0.167]},"t":24,"s":[80]},{"t":40,"s":[20]}],"ix":11},"r":{"a":0,"k":0,"ix":10},"p":{"a":0,"k":[210,450.5,0],"ix":2},"a":{"a":0,"k":[0,0,0],"ix":1},"s":{"a":1,"k":[{"i":{"x":[0.833,0.833,0.833],"y":[0.833,0.833,0.833]},"o":{"x":[0.167,0.167,0.167],"y":[0.167,0.167,0.167]},"t":16,"s":[100,100,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.833,0.833,0.833]},"o":{"x":[0.167,0.167,0.167],"y":[0.167,0.167,0.167]},"t":24,"s":[120,120,100]},{"t":32,"s":[100,100,100]}],"ix":6}},"ao":0,"shapes":[{"ty":"gr","it":[{"d":1,"ty":"el","s":{"a":0,"k":[10,10],"ix":2},"p":{"a":0,"k":[0,0],"ix":3},"nm":"Ellipse Path 1","mn":"ADBE Vector Shape - Ellipse","hd":fa