Skip to content

Instantly share code, notes, and snippets.

View tobaco's full-sized avatar

Torsten Baldes tobaco

View GitHub Profile
@tobaco
tobaco / darkmode.css
Created February 27, 2023 09:29
Simple darkmode
<style>
@media (prefers-color-scheme: dark) {
body {
filter: invert(100%) hue-rotate(.5turn);
background-color: rgb(199, 206, 204) !important;
}
img:not(.logo__img),
.emoji,
iframe{
@tobaco
tobaco / purge_cf.php
Created January 24, 2022 11:53 — forked from Greg-Boggs/purge_cf.php
PHP code to Purge Cloudflare Cache
<?php
// Replace EMAIL/API_KEY/ZONE_ID with your details.
// Zone ID is on the dashboard for the domain in the bottom right.
// Api keys are generated from the account settings. You must give cache purge permissions
// Place this script on your webserver and point a Github Webhook at it, and you'll clear
// the Cloudflare cache every time you do a push to GH.
try {
$head = [];
$head[] = 'Content-Type: application/json';
@tobaco
tobaco / wach-und-wichtig.js
Created March 3, 2021 08:38 — forked from marco79cgn/wach-und-wichtig.js
iOS widget, das die neueste Folge des radioeins Podcasts "Wach & Wichtig" anzeigt und abspielt (für die Scriptable.app)
// Wach und Wichtig Podcast Widget
//
// Copyright (C) 2020 by marco79 <marco79cgn@gmail.com>
//
// Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted.
//
// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
// INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER
// IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
body {
font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
"Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans",
"Droid Sans", "Helvetica Neue", sans-serif;
}
@tobaco
tobaco / dabblet.css
Created November 16, 2017 07:20 — forked from LeaVerou/dabblet.css
Two column <dl> with two lines of CSS! Thank you Grid Layout!
/**
* Two column <dl> with two lines of CSS! Thank you Grid Layout!
* Limitation: Breaks if we have multiple consecutive <dt>s or <dd>s
*/
dl {
display: grid;
grid-template: auto / 10em 1fr;
}
@tobaco
tobaco / dabblet.css
Created June 3, 2016 09:40 — forked from LeaVerou/dabblet.css
Emulating caret-color in WebKit/Blink
/**
* Emulating caret-color in WebKit/Blink
* Warning: NON-STANDARD. Your text will be shown with the caret color in Firefox, despite the @supports.
*/
@keyframes rainbow {
9% { color: yellow }
27% { color: orange }
45% { color: lime }
63% { color: aqua }
@tobaco
tobaco / SassMeister-input.scss
Created December 1, 2014 15:07
Generated by SassMeister.com.
// ----
// Sass (v3.4.7)
// Compass (v1.0.1)
// ----
@mixin frankly_trans(
$property: all,
$time: .3s,
$ease: out
) {
@tobaco
tobaco / dabblet.css
Created November 9, 2014 15:43
Pounding heart animation
/* Pounding heart animation */
@keyframes pound {
0% { opacity: 0;}
20% { opacity: 0.2 }
85% { opacity: 0;}
100% { transform: scale(2); opacity: 0 }
}
.heart {
@tobaco
tobaco / SassMeister-input.scss
Created September 30, 2014 12:35
Generated by SassMeister.com.
// ----
// Sass (v3.4.4)
// Compass (v1.0.1)
// ----
$modules: () !default;
@mixin exports($name) {
@if (not index($modules, $name)) {
$modules: append($modules, $name);
@content;
@tobaco
tobaco / README
Created June 13, 2013 09:50 — forked from gmyx/README
Drop in replace functions for setTimeout() & setInterval() that
make use of requestAnimationFrame() for performance where available
http://www.joelambert.co.uk
Copyright 2011, Joe Lambert.
Free to use under the MIT license.
http://www.opensource.org/licenses/mit-license.php