Just for fun.
Inspired by CSS Tricks web dev merit badges
- Validated in EPUBCheck on the first try (courtesy Wendy Reid)
- Approved by Ace (courtesy Marisa Demeglio)
- Made an EPUB3 file
- Made a fixed-layout EPUB
Just for fun.
Inspired by CSS Tricks web dev merit badges
Now online @ https://jaypanoz.github.io/epubcheck-messages/
Github repo: https://github.com/JayPanoz/epubcheck-messages
javascript:(function()%7Bvar%20nightEnabled%20%3D%20document.head.querySelector(%22%23my-night-style%22)%3Bif%20(nightEnabled)%20%7Bdocument.head.removeChild(nightEnabled)%3B%7D%20else%20%7Bvar%20nightStyle%20%3D%20document.createElement(%22style%22)%3BnightStyle.id%20%3D%20%22my-night-style%22%3BnightStyle.textContent%20%3D%20%22html%20%7Bfilter%3A%20invert(100%25)%20hue-rotate(180deg)%3B%7D%20img%2C%20svg%20%7Bfilter%3A%20invert(100%25)%20hue-rotate(180deg)%20!important%3B%7D%20video%20%7Bfilter%3A%20invert(100%25)%20hue-rotate(180deg)%20!important%3B%7D%22%3Bdocument.head.appendChild(nightStyle)%3B%7D%7D)() | |
Converted using Mr Coles’ Bookmarklet Creator: https://mrcoles.com/bookmarklet/ |
/* unvisited link */ | |
a:link { | |
color: initial; | |
} | |
/* visited link */ | |
a:visited { | |
color: initial; | |
} |
// This is now its own package @ https://github.com/rodebert/epubtype-to-aria | |
// Please check Rodebert’s repo for a better and more up-to-date version | |
"use strict"; | |
// Get all the elements with epub:type | |
// Since querySelectorAll can’t be used with XHTML attributes, | |
// we create an array in which we’ll push elements with an epub:type attribute | |
var epubTypes = []; |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Test</title> | |
<style type="text/css" id="styles"> | |
html, body {margin: 0; padding: 0;} | |
.main { | |
box-sizing: border-box; | |
display: flex; |
There is a proposal for user agent properties. To sum things up, browsers would expose user settings so that you can use them in your CSS.
For instance:
body {
font-size: const(user-font-size);
font-family: const(user-font-family);
/* And so on and so forth… */
}
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>fonts</key> | |
<dict> | |
<key>STIX</key> | |
<dict> | |
<key>charMap</key> | |
<dict> |
/* Dauwhe’s magical mystery Reading System | |
A quick and dirty proto to implement https://twitter.com/dauwhe/status/877533923567390721 | |
This is the future of ebooks’ default stylesheet | |
#TrollingIsMyFuel | |
*/ | |
r(function() { | |
var style = document.createElement("style"); | |
style.id = "ImSorryDaveImAfraidICanDoThat"; |