Skip to content

Instantly share code, notes, and snippets.

Adam Schwartz adamschwartz

Block or report user

Report or block adamschwartz

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
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
View matter-js-compound-body-set-part-position.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 ampersand-logo.html
<svg viewBox="0 0 912 166">
<defs>
<linearGradient x1="50%" y1="0%" x2="7.09834099%" y2="100%" id="ampersand-logo-gradient">
<stop stop-color="#f69259" offset="0%"></stop>
<stop stop-color="#f16975" offset="100%"></stop>
</linearGradient>
</defs>
<path d="M229.060522,129.685867 L241.919592,129.685867 L199.908427,22.4295349 L189.460432,22.4295349 L147.230078,129.685867 L159.796896,129.685867 L172.948218,95.7116203 L215.763075,95.7116203 L229.060522,129.685867 Z M211.890742,84.5329971 L177.331992,84.5329971 L189.89881,51.4355049 C191.895861,45.8340191 193.430182,40.6952591 194.501772,36.0192337 C196.206572,42.1078025 197.862666,47.2465625 199.470049,51.4355049 L211.890742,84.5329971 Z M355.458081,129.685867 L367.586522,129.685867 L367.586522,77.4458961 C367.586522,67.2170906 365.333747,59.7768538 360.828204,55.1251812 C356.322662,50.4735131 349.539987,48.1476746 340.480187,48.1476746 C334.683861,48.1476746 329.520753,49.3653865 324.990853,51.8008194 C320.460954,54.2362523 317.00264,57.
View github-revert-dark-header.css
.header.header-dark {
color: #333;
background-color: #f5f5f5;
border-bottom: 1px solid #e5e5e5
}
.header-dark .read-only-mode-banner {
background-color: #f8e45f;
border-bottom-color: #f6dc2e
}
View magic-8-ball.html
<head>
<style>
@import url('https://fonts.googleapis.com/css?family=Oswald');
html {
font-family: 'Oswald', sans-serif;
font-size: 16px;
}
.surface {
You can’t perform that action at this time.