• documentation
  • examples
  • about
  • FAQ
  • journal
  • Gitlab

Supported feature of the W3C specifications

written on Sep 3, 2019

CSS Paged Media Module Level 3

W3C Working Draft 14 March 2013

Editor’s Draft, 9 November 2017

@page rules
Size size: <length>{1,2} ; HTML PDF
size: A5 | A4 | A3 | B5 | B4 | letter | legal | ledger ; HTML PDF
size: portrait | landscape ; HTML PDF
Marks marks: none | [ crop || cross ] ; HTML Screenshot
Bleed bleed: <length> ; HTML screenshot
Margins margin: <length>{1,2} ; HTML PDF
margin-top: <length> ;
margin-bottom: <length> ;
margin-left: <length> ;
margin-right: <length> ;
HTML PDF
margin-inside: <length> ;
margin-outside: <length> ;
no
Background background-color: ... ; HTML PDF
background-image: url(<url>) ; HTML PDF
background-size: ... ;
background-repeat: ... ;
background-position: ... ;
HTML PDF
Page selectors
Spread @page :left { }
@page :right { }
HTML PDF
First page @page :first { } HTML PDF
Blank page @page :blank { } HTML PDF
nth page @page :nth(n) { } HTML PDF
Margin boxes
Default HTML PDF
Styles bakground: ... ;
color: ... ;
border:... ;
HTML PDF
Text alignment text-align: left | center | right ; HTML PDF
Vertical alignment vertical-align: top | middle | bottom ;
or align-items: flex-start | center | flex-end ;
HTML PDF
Computed ... in progress
Page-based counters
counter for page content : counter(page) ; HTML PDF
content : counter(pages) ; HTML PDF
Named page
named @page @page <name> { }
section { page: <name> }
HTML PDF
Page group
page group @page <name> { }
section { page: <name> }
HTML PDF
Page selectors for page group
Spread @page <name>:left { }
@page <name>:left { }
HTML PDF
First page @page <name>:first { } HTML PDF
Blank page @page <name>:blank { } issue#30
nth page @page <name>:nth(n) { } issue#29

CSS Fragmentation Module Level 3

W3C Candidate Recommendation, 9 February 2017

Breaks Between Boxes
Breaks before break-before: avoid-page | avoid ; no
break-before: page ; HTML PDF
break-before: left ; HTML PDF
break-before: right ; HTML PDF
break-before: recto ; HTML PDF
break-before: verso ; HTML PDF
break-before: column | region; ?
Breaks after break-after: avoid-page | avoid ; no
break-after: page ; HTML PDF
break-after: left ; HTML PDF
break-after: right ; HTML PDF
break-after: recto ; HTML PDF
break-after: verso ; HTML PDF
break-after: column | region ; ?
Avoid breaks inside break-inside: avoid ; HTML PDF
break-inside: avoid-page ; no
break-inside: avoid-column; ?
break-inside: avoid-region ; ?
Breaks Between Lines
Orphans orphans: <integer> ; Chrome and blink browsers supports orphans out of the box. Firefox doen't. Check support from caniuse.com
Widows widows: <integer> ; Chrome and blink browsers supports widows out of the box. Firefox doen't. Check support from caniuse.com
Fragmented Borders and Backgrounds
box-decorations box-decoration-break: slice | clone ; no

CSS Generated Content for Paged Media Module

W3C Working Draft, 13 May 2014

Named strings
String-set() on elements string-set: [[<custom-ident> <content-list>][, <custom-ident> <content-list>]* ]
<content-list>= <string> HTML PDF
content(text) HTML PDF
content(before) Issue#45
content(after) Issue#45
content(first-letter) Issue#45
counter() no
counters() no
attr(<identifier>) no
String in margin-boxes content: string( <custom-ident> [ , [ <keyword>] ]? )
<keyword>= first Pending merge request
start Pending merge request
last Pending merge request
first-except HTML PDF
Running elements
Running value on elements position: running(<custom-ident>) ; HTML PDF
Element value in margin boxes content: element(...) ;
element( <custom-ident> [ , <keyword> ]? )
HTML PDF
<keyword>= first no
start no
last no
first-except no
Footnotes
Footnotes area @footnote{ float: bottom ; } no
Footnote element .note { float: footnote ; } no
Footnote type footnote-display: block | inline | compact ; no
Rendering footnotes footnote-policy: auto | line | block ; no
Footnotes counters ::footnote-call { }
::footnote-call { content: counter(footnote
[, <counter-style>, <string>] ; }
no
::footnote-marker { }
::footnote-marker { content: counter(footnote
[, <counter-style>, <string>] ; }
no
Reset footnotes @page { counter-reset: footnote ; } no
Leaders
leaders content : leader(<type>) ; no
<type>= dotted no
solid no
space no
<string> no
Cross-references
Counter type content: target-counter(attr(href url), page) ;
target-counter( <url> , <custom-ident> [ , <counter-style> ]? )
HTML
+ Issue#46
PDF
target-counters( <url> , <custom-ident> [ , <counter-style> ]? ) no
Text type content: target-content(attr(href)) ;
target-text( <url> [ , <keyword> ]? )
<keyword>= content HTML PDF
before HTML
after HTML
first-letter HTML
PDF bookmarks
Bookmarks bookmark-level: <integer> ; no
bookmark-label: <content-list> no
bookmark-state: open | close ; no
Generated Content in Margin Boxes W3C specifications for printing

Paged.js is maintained by the nice folks at Coko.