Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save mathiasbynens/436928 to your computer and use it in GitHub Desktop.
Save mathiasbynens/436928 to your computer and use it in GitHub Desktop.
Awesomify the Safari Reader UI bookmarklet
// This works when used from the console with the Reader document open, but fails when used as a bookmarklet. Any ideas?
// See http://mathiasbynens.be/notes/safari-reader-html
javascript:(function(d){var s=d.createElement('style');s.appendChild(d.createTextNode('#background{background:#f773b5 url(http://i.imgur.com/bB7aD.jpg)}h1.title,.page{font-family:"Comic Sans MS"!important}h1.title{color:#f773b5}.page{background:rgba(255,255,255,.9);-webkit-animation-name:f;-webkit-animation-duration:5s;-webkit-animation-iteration-count:infinite;-webkit-animation-timing-function:linear}@-webkit-keyframes f{0%{-webkit-transform:rotate(0) scale(1)}25%{-webkit-transform:rotate(-4deg) scale(.95)}50%{-webkit-transform:rotate(0) scale(1)}75%{-webkit-transform:rotate(4deg) scale(.95)}100%{-webkit-transform:rotate(0) scale(1)}}'));d.head.appendChild(s)})(document)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment