Skip to content

Instantly share code, notes, and snippets.

View signalwerk's full-sized avatar
💫
on the r͢oad

Stefan Huber signalwerk

💫
on the r͢oad
View GitHub Profile
@signalwerk
signalwerk / dabblet.css
Last active August 29, 2015 13:57
graceful degradation
/**
* graceful degradation
*/
/* background: #7b1270;*/
@import url(https://fonts.googleapis.com/css?family=Open+Sans:400);
html {
font-family: "Open Sans", sans-serif;
min-height: 100%;
}
@signalwerk
signalwerk / dabblet.css
Last active August 29, 2015 13:57
The first commented line is your dabblet’s title
/**
* CSS & HTML separate
*/
h1 {
color: red;
font-size: 30px;
}
@signalwerk
signalwerk / dabblet.css
Created May 23, 2014 12:44
Struktur und Inhalt
/**
* Struktur und Inhalt
*/
h1 {
font-weight: bold;
color: #24588d;
}
p {
font-weight: normal;
}
@signalwerk
signalwerk / keybase.md
Last active April 26, 2024 10:27
Keybase – Proof of my identity

Keybase proof

I hereby claim:

  • I am signalwerk on github.
  • I am signalwerk (https://keybase.io/signalwerk) on keybase.
  • I have a public key whose fingerprint is B52A AFA4 B9B5 8F42 FEC0 6C7C D218 AA33 B5BC CBED

To claim this, I am signing this object:

@signalwerk
signalwerk / ANSIColors.js
Last active April 26, 2024 14:54 — forked from shanimal/ANSIColors.js
ANSIColors
export const ANSIColors = {
reset: "\033[0m",
hicolor: "\033[1m",
underline: "\033[4m",
inverse: "\033[7m",
// foreground colors
black: "\033[30m",
red: "\033[31m",
green: "\033[32m",
yellow: "\033[33m",
@signalwerk
signalwerk / warmly.sh
Last active February 12, 2019 13:53 — forked from thomasfr/warmly.sh
A wget based easy poor man`s cache warmer script – See Line 4 for run from Terminal
#!/bin/bash
# RUN
# WARMLY_WGET_LOGFILE=~/warmly.log bash <(curl -# -L http://bit.ly/signalwerk-warmly) https://xyz.com
# warmly.sh
# A wget based, easy, poor man`s cache warmer script
# https://gist.github.com/thomasfr/7926314
@signalwerk
signalwerk / normalise.css
Last active July 11, 2024 22:26
simple normalise css
/* inspiration
- https://alligator.io/css/minimal-css-reset/
- [Kevin Powell](https://youtu.be/cCAtD_BAHNw) [Gist](https://gist.github.com/Lego2012/7b7956734f2ab4a95fd0c311cd8bbe95)
*/
@import url("https://fonts.signalwerk.ch/css/latest/family=Work+Sans:ital,wght@0,100..900;1,100..900.css");
:root {
--color-green: #006984;
--color-blue: #0054a2;
@signalwerk
signalwerk / random.js
Created May 23, 2019 13:25
Pseudorandom number generator (PRNG)
// 1993 Park-Miller linear congruential generator (LCG)
// https://en.wikipedia.org/wiki/Lehmer_random_number_generator
// Source: https://gist.github.com/blixt/f17b47c62508be59987b
// usage:
// let rand = LCG(42);
// rand() → 0.000944073311984539
// rand() → 0.5713628428056836
// rand() → 0.2557850731536746
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Black smearing</title>
<link href="https://fonts.googleapis.com/css?family=Work+Sans:100" rel="stylesheet">
<style>
html {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Ubuntu, "Helvetica Neue", sans-serif;
@signalwerk
signalwerk / menu.js
Created June 10, 2020 15:19
set menu items to active based on children
// this is the original menu-structure
let menu = {
children: [
{ path: "/node/1", title: "Title 1" },
{
path: "/node/2",
title: "Title 2",
children: [
{ path: "/node/21", title: "Title 2.1" },
{ path: "/node/22", title: "Title 2.2" }