Skip to content

Instantly share code, notes, and snippets.

Adam Schwartz adamschwartz

View GitHub Profile
View --color-rgb-varying-opacity-example.html
<!doctype html>
<meta charset="utf-8">
<meta name="viewport" content="initial-scale=1, width=device-width">
<style visible>
:root { --color-rgb: 8, 10, 60 }
</style>
<style>
View ios-safari-box-shadow-circle-bug-repro.html
<title>iOS Safari bug: incorrect rendering of box-shadow on 19.2px square element with 50% border-radius</title>
<meta charset="utf-8">
<meta name="viewport" content="initial-scale=1, width=device-width">
<style>
html {
font-size: 16px;
}
@adamschwartz
adamschwartz / plink-plonk.js
Created Feb 19, 2020 — forked from tomhicks/plink-plonk.js
Listen to your web pages
View plink-plonk.js
@adamschwartz
adamschwartz / pre-2020-google-search-results.css
Last active Mar 10, 2020
Stylesheet for pre-2020 Google Search results page styles
View pre-2020-google-search-results.css
#search .r {
position: relative;
}
#search .r > a[ping] {
text-decoration: none;
}
#search .r > a[ping] > div > img[height="16"][width="16"],
#search .r > a[ping] + div > div > img[height="16"][width="16"] {
View scroll-overflow-proof-of-concept.html
<!DOCTYPE html>
<html>
<head>
<title>&shy;</title>
<meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width">
<style>
* {
box-sizing: border-box;
}
View subdomain-input.html
<form>
<div prefix-editor suffix=".adamschwartz.com" spellcheck="false" autocomplete="false">
<input type="text">
</div>
</form>
<script>
(() => {
const editorEl = document.querySelector('[prefix-editor]')
const inputEl = editorEl.querySelector('input')
@adamschwartz
adamschwartz / rainbow-donut-spinner.html
Created Aug 12, 2017
Single-element rainbow donut spinner
View rainbow-donut-spinner.html
<style>
:root {
--background: #000;
--rainbow-1: #e91e63;
--rainbow-2: #9c27b0;
--rainbow-3: #3f51b5;
--rainbow-4: #2196f3;
--rainbow-5: #00bcd4;
--rainbow-6: #4caf50;
--rainbow-7: #cddc39;
View matter-js-fix-compound-body-hull-after-part-position-change.html
<body>
<script src="https://cdnjs.cloudflare.com/ajax/libs/matter-js/0.12.0/matter.js"></script>
<script>
const Engine = Matter.Engine
const Render = Matter.Render
const Runner = Matter.Runner
const MouseConstraint = Matter.MouseConstraint
const Mouse = Matter.Mouse
const World = Matter.World
View matter-js-compound-body-set-position-then-set-parts.html
<body>
<script src="https://cdnjs.cloudflare.com/ajax/libs/matter-js/0.12.0/matter.js"></script>
<script>
const Engine = Matter.Engine
const Render = Matter.Render
const Runner = Matter.Runner
const MouseConstraint = Matter.MouseConstraint
const Mouse = Matter.Mouse
const World = Matter.World
You can’t perform that action at this time.