Skip to content

Instantly share code, notes, and snippets.

//==== SCSS mixin to create CSS triangles
//==== Examples:
//==== @include triangle ("up", #fff, 10px, 20px);
//==== @include triangle("up", #000, 20px);
@mixin triangle ($direction: "down", $color: #000, $width: 20px, $height: $width ) {
width: 0;
height: 0;
border-left: #{setTriangleSide($direction, "left", $width, $height, $color)};
border-right: #{setTriangleSide($direction, "right", $width, $height, $color)};
border-bottom: #{setTriangleSide($direction, "down", $width, $height, $color)};
@whroman
whroman / batchPaths.js
Last active August 29, 2015 14:00
DRY up your file-include-intensive scripts with batchPaths.js. Use cases include Grunt and Gulp task declarations.
var batchPaths = function() {
var _prefix = '';
var _suffix = '';
// _all (Array)
// Populated by calling batchPaths.add(Array).
var _all = [];
// Method: prefix
// Args: toPrefix (String)
@whroman
whroman / extendDatePrototype.js
Created May 1, 2014 00:01
Extending Javascript's Date.prototype
Date.prototype.getDayofYear = function(){
var d= new Date(this.getFullYear(), 0, 0);
return Math.floor((this-d)/8.64e+7);
}
Date.prototype.addDays = function (n) {
var year = this.getFullYear();
var month = this.getMonth();
var date = this.getDate() + n;
newDate = new Date(year, month, date);
javascript: (function() {
var root = $(document.getElementsByTagName('html'));
var watchers = [];
var attributes = [];
var attributes_with_values = [];
var elements = [];
var elements_per_attr = [];
var scopes = [];
@whroman
whroman / gist:5bf82bf2c517db7a0dec
Created November 30, 2015 21:25
Fahrschule Passer Script
App.data.currentSet.attributes.sd.each(function (model) {
var attrs = model.attributes.question.attributes;
model.set({
a1: attrs.answer1_value,
a2: attrs.answer2_value,
a3: attrs.answer3_value,
answered: true
});
});
@whroman
whroman / insertionSort.js
Created January 4, 2016 18:59
Javascript Array Insertion Sort
var insertionSort = function () {
var sortedArray = [];
var argLen = arguments.length;
while (argLen--) { sortedArray = sortedArray.concat(arguments[argLen]); }
var newArr = [];
newArr.push(sortedArray[0]);
sortedArray.slice(1, sortedArray.length).forEach(function (itemToSort) {
var iter = newArr.length - 1;
for (iter; iter >= 0; iter--) {
if (itemToSort > newArr[iter]) {
var numOfFeedItems = 0;
var removeRightCol = function () {
var rightCol = document.getElementById("rightCol");
if (rightCol && rightCol.remove) rightCol.remove();
var content = document.getElementById("contentArea");
content.setAttribute("style", "width: 100%");
};
#set editing-mode vi
#set keymap vi
# If there is any text in front of the cursor then up and down
# do history search, otherwise up and down do normal history prev/next.
"\e[B": history-search-forward
"\e[A": history-search-backward
# allow the use of the Home/End keys
"\e[1~": beginning-of-line

UHU - The All-Purpose Adhesive

Whether porcelain, wood, metal, glass, ceramics, plexiglass, felt, cork, fabric, cardboard, paper - UHU All-Purpose Adhesive simply bonds everything. UHU All Purpose Adhesive is ideal for household repairs, creative crafts, school and office. Not suitable for styrofoam.

Application Note

Apply thinly on one side, pat down and perhaps readjust - done. For hard materials spread onto both splices (dry and free of grease), let dry, spread thinly again and press together.

Netzgesellschaft - Ablesung der Gaszähler

Sehr geehrte Kundin, sehr geehrter Kunde,

als Ihr zuständiger Netzbetreiber erheben wir einmal jährlich Ihren Zählerstand für Gas, damit Ihr jeweiliger Energielieferant eine Verbrauchsabrechnung erstellen kann.

Bitte teile Sie uns Ihren Zählerstand vor dem Ablesetermin ganz bequem online unter www.nbb-ablesung.de mit oder...

ermöglichen Sie unseren Mitarbeitern im oben genannten Zeitraum den Zutritt zum Zahler Halten Sie bitte hierfür Ihre Zählernummer, die Postleitzahl sowie den aktuellen Zählerstand bereit. Unter der Rufnummer 030 20 179 179 nehmen wir Ihren Zählerstand sich telefonisch entgegen.