offline/online events: yes
expired timers: fire immediately
active timers: fire on time
| <!doctype html> | |
| <title>Retina Images with CSS content</title> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" /> | |
| <style> | |
| @media all and (-webkit-device-pixel-ratio: 1.5) { | |
| /* e. g. android hi res devices | |
| see: http://developer.android.com/guide/webapps/targeting.html#DensityCSS | |
| */ | |
| #people9 { content: url(//lorempixum.com/300/225/people/9/); } |
| //quick and dirty, does not consider all function params and this yet | |
| Array.prototype.find = function (predicate) { | |
| return this.reduce(function(prev, cur){return predicate(cur) ? cur : prev }) | |
| } |
| <?xml version='1.0'?> | |
| <!DOCTYPE fontconfig SYSTEM '/etc/fonts/fonts.dtd'> | |
| <fontconfig> | |
| <match target="font"> | |
| <edit name="hintstyle" mode="assign"> | |
| <const>hintslight</const> | |
| </edit> | |
| </match> | |
| </fontconfig> |
| <!doctype html> | |
| <title>draw grayscale ramp</title> | |
| <meta name="viewport" content="width=device-width"> | |
| <style> | |
| .ramp { | |
| height: 300px; | |
| position: relative; | |
| } | |
| .ramp > div { | |
| position: absolute; |
| <!doctype html> | |
| <title>gradient gray alpha</title> | |
| <meta name="viewport" content="width=device-width"> | |
| <style> | |
| .gradient { | |
| width: 768px; | |
| height: 300px; | |
| background-image: linear-gradient(to right, rgba(0, 0, 0, 0.5), rgb(128, 128, 128)); | |
| } | |
| </style> |
| FROM ubuntu:precise | |
| RUN echo -n "foreign-architecture armhf" > /etc/dpkg/dpkg.cfg.d/multiarch | |
| RUN sed -i 's/deb /deb [arch=amd64,i386] /g' /etc/apt/sources.list | |
| RUN sed -i 's/deb-src /#deb-src /g' /etc/apt/sources.list | |
| RUN echo "deb [arch=armhf] http://ports.ubuntu.com/ precise main" >> /etc/apt/sources.list | |
| RUN echo "deb [arch=armhf] http://ports.ubuntu.com/ precise-security main" >> /etc/apt/sources.list | |
| RUN echo "deb [arch=armhf] http://ports.ubuntu.com/ precise-updates main" >> /etc/apt/sources.list | |
| RUN apt-get update | |
| RUN apt-get install -y gcc-arm-linux-gnueabihf libasound2:armhf libasound2-dev:armhf portaudio19-dev:armhf | |
| RUN apt-get install -y gcc g++ git curl pkg-config libprotoc-dev file make |
| FROM ubuntu:trusty | |
| RUN dpkg --add-architecture armhf | |
| RUN sed -i 's/deb /deb [arch=amd64,i386] /g' /etc/apt/sources.list | |
| RUN sed -i 's/deb-src /#deb-src /g' /etc/apt/sources.list | |
| RUN echo "deb [arch=armhf] http://ports.ubuntu.com/ trusty main" >> /etc/apt/sources.list | |
| RUN echo "deb [arch=armhf] http://ports.ubuntu.com/ trusty-security main" >> /etc/apt/sources.list | |
| RUN echo "deb [arch=armhf] http://ports.ubuntu.com/ trusty-updates main" >> /etc/apt/sources.list | |
| RUN apt-get -y update | |
| RUN apt-get install -y gcc-arm-linux-gnueabihf libasound2:armhf libasound2-dev:armhf | |
| RUN apt-get install -y gcc g++ git curl pkg-config libprotoc-dev file |
| <!doctype html> | |
| <title>Web embeds</title> | |
| <h2>Youtube</h2> | |
| <iframe width="560" height="315" src="https://www.youtube.com/embed/dQw4w9WgXcQ" frameborder="0" allowfullscreen></iframe> | |
| <h2>Twitter</h2> | |
| <blockquote class="twitter-tweet" data-cards="hidden" data-lang="en"><p lang="en" dir="ltr">"No one is born hating another person because of the color of his skin or his background or his religion..." <a href="https://t.co/InZ58zkoAm">pic.twitter.com/InZ58zkoAm</a></p>— Barack Obama (@BarackObama) <a href="https://twitter.com/BarackObama/status/896523232098078720">August 13, 2017</a></blockquote> | |
| <script async src="//platform.twitter.com/widgets.js" charset="utf-8"></script> |
| <!doctype html> | |
| <meta name="viewport" content="initial-scale=1"> | |
| <h1>safari touchmove event preventDefault</h1> | |
| <div style="width: 300px; height: 300px; background: green"></div> | |
| <h2>works</h2> | |
| <pre> | |
| document.addEventListener("touchmove", (e) => e.preventDefault()) | |
| </pre> | |
| <h2>works</h2> | |
| <pre> |