Skip to content

Instantly share code, notes, and snippets.

View edwardhorsford's full-sized avatar

Ed Horsford edwardhorsford

View GitHub Profile
#!/usr/bin/env python
# Demo a brightened luminance-only inversion on 8-bit images
from skimage import io
import numpy as np
from sys import argv
# RGB <-> YCoCg-R almost straight from Wikipedia
<div class="grid-row">
<div class="available-languages">
<ul>
<li class="translation">
<span>English</span>
</li>
<li class="translation last">
<a lang="cy" hreflang="cy" href="/dechrau">Cymraeg</a>
</li>
</ul>
@roc
roc / today.md
Last active May 2, 2016 14:09
Show a calendar with today's date highlighted
cal | GREP_COLOR='1;32' grep -w -A4 -B6 --color "$(date +%e)"

Alias with

alias today="cal | GREP_COLOR='1;32' grep -w -A4 -B6 --color "$(date +%e)"
# or add to .aliases file
(echo ""; echo alias cal | GREP_COLOR='1;32' grep -w -A4 -B6 --color "$(date +%e)"') >> ~/.aliases
@p3t3r67x0
p3t3r67x0 / pseudo_elements.md
Last active January 16, 2024 01:17
A CSS pseudo-element is used to style specified parts of an element. In some cases you can style native HTML controls with vendor specific pseudo-elements. Here you will find an list of cross browser specific pseudo-element selectors.

Styling native elements

Native HTML controls are a challenge to style. You can style any element in the web platform that uses Shadow DOM with a pseudo element ::pseudo-element or the /deep/ path selector.

video::webkit-media-controls-timeline {
  background-color: lime;
}

video /deep/ input[type=range] {