CSS support
Every standard CSS property, at-rule, selector and value type, and whether PdfPecker draws it. Of the 599 properties below, PdfPecker supports 309, supports 26 in part and leaves out 152. Another 112 are for scrolling, animation and interaction, which have no effect on a printed page, so PdfPecker ignores them on purpose. HTML and CSS support explains how the supported features behave, and Limitations describes the gaps.
A declaration PdfPecker does not support is dropped like any unknown property: the rest of the rule still applies and the conversion does not fail. The property list is the standards-track properties in MDN's browser compatibility data, grouped by the specification that defines them, plus the paged media properties PdfPecker reads. Property names link to MDN.
Properties
Box model and sizing
| Property | PdfPecker | Notes |
|---|---|---|
aspect-ratio |
✓ Yes | |
block-ellipsis |
✕ No | Use the line-clamp shorthand. |
block-size |
✓ Yes | |
box-sizing |
✓ Yes | |
column-width |
✓ Yes | |
contain |
✕ No | Layout is the same without it. |
contain-intrinsic-block-size |
✕ No | Only matters with content-visibility. |
contain-intrinsic-height |
✕ No | Only matters with content-visibility. |
contain-intrinsic-inline-size |
✕ No | Only matters with content-visibility. |
contain-intrinsic-size |
✕ No | Only matters with content-visibility. |
contain-intrinsic-width |
✕ No | Only matters with content-visibility. |
content-visibility |
✕ No | Content is drawn even when set to hidden. |
continue |
✕ No | Use the line-clamp shorthand. |
display |
✓ Yes | block, inline, inline-block, flow-root, flex, grid, list-item, contents, none, every table value, two-value forms and -webkit-box. |
frame-sizing |
✕ No | Iframes are not loaded. |
height |
✓ Yes | |
inline-size |
✓ Yes | |
line-clamp |
✓ Yes | Also -webkit-line-clamp with display: -webkit-box. |
margin |
✓ Yes | |
margin-block |
✓ Yes | |
margin-block-end |
✓ Yes | |
margin-block-start |
✓ Yes | |
margin-bottom |
✓ Yes | |
margin-inline |
✓ Yes | |
margin-inline-end |
✓ Yes | |
margin-inline-start |
✓ Yes | |
margin-left |
✓ Yes | |
margin-right |
✓ Yes | |
margin-top |
✓ Yes | |
margin-trim |
✕ No | |
max-block-size |
✓ Yes | |
max-height |
✓ Yes | |
max-inline-size |
✓ Yes | |
max-lines |
✕ No | Use the line-clamp shorthand. |
max-size |
✕ No | Newer shorthand; use max-width and max-height. |
max-width |
✓ Yes | |
min-block-size |
✓ Yes | |
min-height |
✓ Yes | |
min-inline-size |
✓ Yes | |
min-size |
✕ No | Newer shorthand; use min-width and min-height. |
min-width |
✓ Yes | |
order |
✓ Yes | |
overflow |
✓ Yes | auto and scroll clip like hidden, since paper cannot scroll. |
overflow-block |
✕ No | Only the media feature of that name is answered. |
overflow-clip-margin |
✕ No | |
overflow-inline |
✕ No | Only the media feature of that name is answered. |
overflow-x |
✓ Yes | As overflow. |
overflow-y |
✓ Yes | As overflow. |
padding |
✓ Yes | |
padding-block |
✓ Yes | |
padding-block-end |
✓ Yes | |
padding-block-start |
✓ Yes | |
padding-bottom |
✓ Yes | |
padding-inline |
✓ Yes | |
padding-inline-end |
✓ Yes | |
padding-inline-start |
✓ Yes | |
padding-left |
✓ Yes | |
padding-right |
✓ Yes | |
padding-top |
✓ Yes | |
reading-flow |
– No effect | Only changes keyboard focus order. |
reading-order |
– No effect | Only changes keyboard focus order. |
scroll-axis-lock |
– No effect | |
scroll-behavior |
– No effect | |
scroll-marker-group |
– No effect | |
scroll-target-group |
– No effect | |
scrollbar-gutter |
– No effect | |
size |
✓ Yes | The @page descriptor: A4, Letter, landscape or any length. |
text-overflow |
✓ Yes | ellipsis, clip and strings. |
visibility |
✓ Yes | |
width |
✓ Yes | Also min-content, max-content and fit-content. |
Borders, outlines and shadows
Backgrounds and images
| Property | PdfPecker | Notes |
|---|---|---|
background |
✓ Yes | Several layers, gradients and images. |
background-attachment |
– No effect | Paper does not scroll; fixed, local and scroll draw the same. |
background-clip |
✓ Yes | Also text and -webkit-background-clip. |
background-color |
✓ Yes | |
background-image |
✓ Yes | |
background-origin |
✓ Yes | |
background-position |
✓ Yes | |
background-position-x |
✓ Yes | |
background-position-y |
✓ Yes | |
background-repeat |
✓ Yes | |
background-repeat-x |
✕ No | Use background-repeat. |
background-repeat-y |
✕ No | Use background-repeat. |
background-size |
✓ Yes | |
image-orientation |
✕ No | EXIF rotation of JPEG images is not applied. |
image-rendering |
✕ No | Images are left to the PDF viewer, which smooths them. |
object-fit |
✓ Yes | |
object-position |
✓ Yes | |
object-view-box |
✕ No |
Positioning, floats and shapes
| Property | PdfPecker | Notes |
|---|---|---|
anchor-name |
✕ No | Anchor positioning is not supported. |
anchor-scope |
✕ No | Anchor positioning is not supported. |
bottom |
✓ Yes | |
clear |
✓ Yes | |
float |
✓ Yes | Also inline-start, inline-end and footnote. |
inset |
✓ Yes | |
inset-block |
✓ Yes | |
inset-block-end |
✓ Yes | |
inset-block-start |
✓ Yes | |
inset-inline |
✓ Yes | |
inset-inline-end |
✓ Yes | |
inset-inline-start |
✓ Yes | |
left |
✓ Yes | |
overlay |
– No effect | Only for dialogs and popovers in the top layer. |
position |
✓ Yes | fixed repeats on every page; sticky is drawn as relative, as in Chrome print. |
position-anchor |
✕ No | Anchor positioning is not supported. |
position-area |
✕ No | Anchor positioning is not supported. |
position-try |
✕ No | Anchor positioning is not supported. |
position-try-fallbacks |
✕ No | Anchor positioning is not supported. |
position-try-order |
✕ No | Anchor positioning is not supported. |
position-visibility |
✕ No | Anchor positioning is not supported. |
right |
✓ Yes | |
shape-image-threshold |
✓ Yes | |
shape-margin |
✓ Yes | |
shape-outside |
✓ Yes | Basic shapes, boxes and images; SVG images fall back to the margin box. |
top |
✓ Yes | |
z-index |
✓ Yes |
Flexbox, grid and alignment
| Property | PdfPecker | Notes |
|---|---|---|
align-content |
✓ Yes | |
align-items |
✓ Yes | |
align-self |
✓ Yes | |
fit-tolerance |
✕ No | |
flex |
✓ Yes | |
flex-basis |
✓ Yes | |
flex-direction |
✓ Yes | |
flex-flow |
✓ Yes | |
flex-grow |
✓ Yes | |
flex-line-count |
✕ No | |
flex-shrink |
✓ Yes | |
flex-wrap |
✓ Yes | |
grid |
✕ No | The grid shorthand is not expanded; use grid-template and grid-auto-flow. @supports wrongly reports it as supported. |
grid-area |
✓ Yes | |
grid-auto-columns |
✓ Yes | |
grid-auto-flow |
✓ Yes | Including dense. |
grid-auto-rows |
✓ Yes | |
grid-column |
✓ Yes | |
grid-column-end |
✓ Yes | |
grid-column-start |
✓ Yes | |
grid-row |
✓ Yes | |
grid-row-end |
✓ Yes | |
grid-row-start |
✓ Yes | |
grid-template |
✓ Yes | |
grid-template-areas |
✓ Yes | |
grid-template-columns |
✓ Yes | repeat(), minmax(), fit-content(), named lines and subgrid (horizontal writing modes). |
grid-template-rows |
✓ Yes | As grid-template-columns. |
justify-content |
✓ Yes | |
justify-items |
✓ Yes | |
justify-self |
✓ Yes | |
place-content |
✓ Yes | |
place-items |
✓ Yes | |
place-self |
✓ Yes |
Multi-column and gap rules
| Property | PdfPecker | Notes |
|---|---|---|
column-count |
✓ Yes | |
column-fill |
✓ Yes | |
column-gap |
✓ Yes | |
column-height |
✕ No | |
column-rule |
✓ Yes | Between columns of a multi-column box. |
column-rule-break |
✕ No | Gap decorations beyond column-rule are not supported. |
column-rule-color |
✓ Yes | |
column-rule-inset |
✕ No | Gap decorations beyond column-rule are not supported. |
column-rule-inset-cap |
✕ No | Gap decorations beyond column-rule are not supported. |
column-rule-inset-cap-end |
✕ No | Gap decorations beyond column-rule are not supported. |
column-rule-inset-cap-start |
✕ No | Gap decorations beyond column-rule are not supported. |
column-rule-inset-end |
✕ No | Gap decorations beyond column-rule are not supported. |
column-rule-inset-junction |
✕ No | Gap decorations beyond column-rule are not supported. |
column-rule-inset-junction-end |
✕ No | Gap decorations beyond column-rule are not supported. |
column-rule-inset-junction-start |
✕ No | Gap decorations beyond column-rule are not supported. |
column-rule-inset-start |
✕ No | Gap decorations beyond column-rule are not supported. |
column-rule-style |
✓ Yes | |
column-rule-visibility-items |
✕ No | Gap decorations beyond column-rule are not supported. |
column-rule-width |
✓ Yes | |
column-span |
✓ Yes | all works on direct children of the multi-column box. |
column-wrap |
✕ No | |
columns |
✓ Yes | |
gap |
✓ Yes | |
row-gap |
✓ Yes | |
row-rule |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-break |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-color |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-inset |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-inset-cap |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-inset-cap-end |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-inset-cap-start |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-inset-end |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-inset-junction |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-inset-junction-end |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-inset-junction-start |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-inset-start |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-style |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-visibility-items |
✕ No | Gap decorations beyond column-rule are not supported. |
row-rule-width |
✕ No | Gap decorations beyond column-rule are not supported. |
rule |
✕ No | Gap decorations beyond column-rule are not supported. |
rule-break |
✕ No | Gap decorations beyond column-rule are not supported. |
rule-color |
✕ No | Gap decorations beyond column-rule are not supported. |
rule-inset |
✕ No | Gap decorations beyond column-rule are not supported. |
rule-inset-cap |
✕ No | Gap decorations beyond column-rule are not supported. |
rule-inset-end |
✕ No | Gap decorations beyond column-rule are not supported. |
rule-inset-junction |
✕ No | Gap decorations beyond column-rule are not supported. |
rule-inset-start |
✕ No | Gap decorations beyond column-rule are not supported. |
rule-overlap |
✕ No | Gap decorations beyond column-rule are not supported. |
rule-style |
✕ No | Gap decorations beyond column-rule are not supported. |
rule-visibility-items |
✕ No | Gap decorations beyond column-rule are not supported. |
rule-width |
✕ No | Gap decorations beyond column-rule are not supported. |
Fonts
| Property | PdfPecker | Notes |
|---|---|---|
font |
✓ Yes | |
font-family |
✓ Yes | Bundled fonts, @font-face and fonts you register. |
font-feature-settings |
½ Partly | Contextual GSUB lookups are skipped. |
font-kerning |
✓ Yes | |
font-language-override |
✕ No | |
font-optical-sizing |
✓ Yes | |
font-palette |
✕ No | |
font-size |
✓ Yes | |
font-size-adjust |
✓ Yes | |
font-stretch |
✓ Yes | |
font-style |
✓ Yes | |
font-synthesis |
✓ Yes | |
font-synthesis-position |
✓ Yes | |
font-synthesis-small-caps |
✓ Yes | |
font-synthesis-style |
✓ Yes | |
font-synthesis-weight |
✓ Yes | |
font-variant |
½ Partly | Contextual OpenType substitutions are skipped; small caps are synthesized when the font lacks them. |
font-variant-alternates |
✕ No | |
font-variant-caps |
½ Partly | Small caps synthesized when the font has no smcp feature. |
font-variant-east-asian |
✓ Yes | |
font-variant-emoji |
✕ No | |
font-variant-ligatures |
½ Partly | Contextual alternates are skipped. |
font-variant-numeric |
✓ Yes | |
font-variant-position |
✓ Yes | |
font-variation-settings |
✓ Yes | |
font-weight |
✓ Yes | |
font-width |
✕ No | New name for font-stretch, which works. |
Text, lines and writing modes
| Property | PdfPecker | Notes |
|---|---|---|
alignment-baseline |
✓ Yes | In SVG text. |
baseline-shift |
✕ No | |
baseline-source |
✕ No | |
direction |
✓ Yes | |
dominant-baseline |
✓ Yes | In SVG text. |
glyph-orientation-vertical |
✕ No | |
hanging-punctuation |
✕ No | |
hyphenate-character |
✓ Yes | |
hyphenate-limit-chars |
✓ Yes | |
hyphenate-limit-lines |
✕ No | |
hyphens |
✓ Yes | Built-in dictionaries for many languages, chosen by lang. |
initial-letter |
✓ Yes | On ::first-letter, as in Chrome; not in vertical writing modes. |
letter-spacing |
✓ Yes | |
line-break |
✓ Yes | |
line-height |
✓ Yes | |
math-depth |
✕ No | MathML is not laid out. |
math-shift |
✕ No | MathML is not laid out. |
math-style |
✕ No | MathML is not laid out. |
overflow-wrap |
✓ Yes | |
ruby-align |
✕ No | Ruby annotations are not laid out. |
ruby-overhang |
✕ No | Ruby annotations are not laid out. |
ruby-position |
✕ No | Ruby annotations are not laid out. |
tab-size |
✓ Yes | |
text-align |
✓ Yes | Right-to-left and bidi lines justify at spaces only. |
text-align-last |
✓ Yes | |
text-autospace |
✕ No | |
text-box |
✕ No | |
text-box-edge |
✕ No | |
text-box-trim |
✕ No | |
text-combine-upright |
✕ No | |
text-fit |
✕ No | |
text-indent |
✓ Yes | |
text-justify |
✓ Yes | inter-character spreads CJK text. |
text-orientation |
✕ No | No upright CJK in vertical text. |
text-spacing-trim |
½ Partly | normal, space-all, space-first and trim-start; needs a font with the halt feature. |
text-transform |
✓ Yes | |
text-wrap |
✓ Yes | balance (up to six lines), pretty and stable. |
text-wrap-mode |
✓ Yes | |
text-wrap-style |
✓ Yes | As text-wrap. |
unicode-bidi |
✓ Yes | |
vertical-align |
✓ Yes | Keywords, lengths and percentages. |
-webkit-text-fill-color |
✓ Yes | |
-webkit-text-stroke |
✓ Yes | Text stays selectable text. |
-webkit-text-stroke-color |
✓ Yes | |
-webkit-text-stroke-width |
✓ Yes | |
white-space |
✓ Yes | |
white-space-collapse |
✕ No | Use white-space. |
white-space-trim |
✕ No | |
word-break |
✓ Yes | |
word-spacing |
✓ Yes | |
wrap-inside |
✕ No | |
writing-mode |
½ Partly | Vertical modes are drawn as turned horizontal text, as Chrome does for Latin; CJK is not set upright. |
Text decoration
| Property | PdfPecker | Notes |
|---|---|---|
text-decoration |
✓ Yes | |
text-decoration-color |
✓ Yes | |
text-decoration-inset |
✕ No | |
text-decoration-line |
✓ Yes | |
text-decoration-skip |
✕ No | Use text-decoration-skip-ink. |
text-decoration-skip-ink |
✓ Yes | |
text-decoration-skip-spaces |
✕ No | |
text-decoration-style |
✓ Yes | Wavy and dashed lines differ a little from Chrome. |
text-decoration-thickness |
✓ Yes | |
text-emphasis |
✕ No | |
text-emphasis-color |
✕ No | |
text-emphasis-position |
✕ No | |
text-emphasis-style |
✕ No | |
text-shadow |
✓ Yes | |
text-underline-offset |
✓ Yes | |
text-underline-position |
✕ No |
Colour, effects and masks
| Property | PdfPecker | Notes |
|---|---|---|
backdrop-filter |
✓ Yes | The backdrop is a 144 dpi raster; up to 64 per document. Also -webkit-backdrop-filter. |
background-blend-mode |
✓ Yes | |
clip |
✕ No | Deprecated; use clip-path. |
clip-path |
✓ Yes | Basic shapes, reference boxes and url(#id). |
clip-rule |
✓ Yes | |
color |
✓ Yes | Every colour syntax; wide-gamut colours are mapped to sRGB. |
color-adjust |
– No effect | Backgrounds always print, as with exact. |
color-interpolation-filters |
✓ Yes | |
color-scheme |
– No effect | Pages are always light, as in print. |
dynamic-range-limit |
– No effect | |
filter |
✓ Yes | blur() and drop-shadow() are rasterized at 144 dpi; the rest stay vector. |
flood-color |
✓ Yes | |
flood-opacity |
✓ Yes | |
forced-color-adjust |
– No effect | |
isolation |
✓ Yes | |
lighting-color |
✓ Yes | |
mask |
✓ Yes | Soft masks on HTML and SVG; text stays text. Also -webkit-mask. |
mask-border |
✕ No | |
mask-border-outset |
✕ No | |
mask-border-repeat |
✕ No | |
mask-border-slice |
✕ No | |
mask-border-source |
✕ No | |
mask-border-width |
✕ No | |
mask-clip |
✓ Yes | |
mask-composite |
✓ Yes | |
mask-image |
✓ Yes | |
mask-mode |
✓ Yes | |
mask-origin |
✓ Yes | |
mask-position |
✓ Yes | |
mask-repeat |
✓ Yes | |
mask-size |
✓ Yes | |
mask-type |
✓ Yes | |
mix-blend-mode |
✓ Yes | |
opacity |
✓ Yes | |
print-color-adjust |
– No effect | Backgrounds always print, as with exact. |
Transforms and motion paths
| Property | PdfPecker | Notes |
|---|---|---|
backface-visibility |
½ Partly | Drawn as Chrome print does. |
offset |
✕ No | Motion paths are not supported. |
offset-anchor |
✕ No | |
offset-distance |
✕ No | |
offset-path |
✕ No | |
offset-position |
✕ No | |
offset-rotate |
✕ No | |
perspective |
½ Partly | Flattened; perspective boxes stay parallelograms. |
perspective-origin |
½ Partly | Flattened with perspective. |
rotate |
✓ Yes | 3D axes are flattened. |
scale |
✓ Yes | |
transform |
½ Partly | 2D is exact; 3D functions are flattened because PDF is affine. |
transform-box |
✕ No | |
transform-origin |
✓ Yes | |
transform-style |
½ Partly | preserve-3d is flattened. |
translate |
✓ Yes |
Lists, counters and generated content
| Property | PdfPecker | Notes |
|---|---|---|
content |
½ Partly | Strings, attr(), counters, quotes, string(), target-counter(), target-text() and leader(). Images in content (url(), gradients) are not drawn. |
counter-increment |
✓ Yes | |
counter-reset |
✓ Yes | |
counter-set |
✓ Yes | |
list-style |
✓ Yes | |
list-style-image |
✓ Yes | |
list-style-position |
✓ Yes | |
list-style-type |
✓ Yes | Every Counter Styles 3 style and @counter-style. |
quotes |
✓ Yes | Including auto by lang. |
Tables
| Property | PdfPecker | Notes |
|---|---|---|
border-collapse |
✓ Yes | Collapsed-border conflicts can differ from Chrome in rare cases. |
border-spacing |
✓ Yes | |
caption-side |
✓ Yes | |
empty-cells |
✓ Yes | |
table-layout |
✓ Yes |
Paged media and breaks
| Property | PdfPecker | Notes |
|---|---|---|
bookmark-label |
✕ No | PDF bookmarks come from headings through PdfOptions instead. |
bookmark-level |
✕ No | PDF bookmarks come from headings through PdfOptions instead. |
bookmark-state |
✕ No | |
box-decoration-break |
½ Partly | Only for inline boxes, not for blocks split across pages. |
break-after |
✓ Yes | |
break-before |
✓ Yes | |
break-inside |
✓ Yes | |
footnote-display |
½ Partly | compact is drawn inline. |
footnote-policy |
½ Partly | block acts like line. |
orphans |
✓ Yes | |
page |
✓ Yes | Named pages with their own @page size and margins. |
page-break-after |
✓ Yes | |
page-break-before |
✓ Yes | |
page-break-inside |
✓ Yes | |
-pdfpecker-scale-to-fit |
✓ Yes | PdfPecker’s own property: shrink fits text of any length into a fixed-size box. |
position: running() |
✕ No | Use string-set or the sticky header and footer instead. |
string-set |
✓ Yes | Running headers with string(). |
widows |
✓ Yes |
SVG properties
| Property | PdfPecker | Notes |
|---|---|---|
color-interpolation |
✕ No | |
cx |
½ Partly | Read from the SVG attribute, not from CSS. |
cy |
½ Partly | Read from the SVG attribute, not from CSS. |
d |
½ Partly | Read from the SVG attribute, not from CSS. |
fill |
✓ Yes | |
fill-opacity |
✓ Yes | |
fill-rule |
✓ Yes | |
marker |
✓ Yes | |
marker-end |
✓ Yes | |
marker-mid |
✓ Yes | |
marker-start |
✓ Yes | |
paint-order |
✓ Yes | On SVG and on HTML text with -webkit-text-stroke. |
path-length |
✕ No | |
pointer-events |
– No effect | |
r |
½ Partly | Read from the SVG attribute, not from CSS. |
rx |
½ Partly | Read from the SVG attribute, not from CSS. |
ry |
½ Partly | Read from the SVG attribute, not from CSS. |
shape-rendering |
– No effect | |
stop-color |
½ Partly | From the attribute or the stop’s style attribute, not from style sheets. |
stop-opacity |
½ Partly | From the attribute or the stop’s style attribute, not from style sheets. |
stroke |
✓ Yes | |
stroke-color |
✕ No | Use stroke. |
stroke-dasharray |
✓ Yes | |
stroke-dashoffset |
✓ Yes | |
stroke-linecap |
✓ Yes | |
stroke-linejoin |
✓ Yes | |
stroke-miterlimit |
✓ Yes | |
stroke-opacity |
✓ Yes | |
stroke-width |
✓ Yes | |
text-anchor |
✓ Yes | In SVG text. |
text-rendering |
– No effect | Kerning and ligatures follow font-kerning and font-variant. |
vector-effect |
✕ No | |
x |
½ Partly | Read from the SVG attribute, not from CSS. |
y |
½ Partly | Read from the SVG attribute, not from CSS. |
Cascade, variables and containers
| Property | PdfPecker | Notes |
|---|---|---|
all |
✓ Yes | |
container |
½ Partly | Size queries and style(--custom); no scroll-state(). |
container-name |
✓ Yes | |
container-type |
✓ Yes | |
--* |
✓ Yes | Custom properties (--*) and var() anywhere, @property too. |
interpolate-size |
– No effect | Only affects animations. |
Prefixed and legacy names
| Property | PdfPecker | Notes |
|---|---|---|
grid-column-gap |
✓ Yes | Read as column-gap. |
grid-gap |
✓ Yes | Read as gap. |
grid-row-gap |
✓ Yes | Read as row-gap. |
-moz-tab-size |
✓ Yes | Read as tab-size. |
-webkit-backdrop-filter |
✓ Yes | Read as backdrop-filter. |
-webkit-background-clip |
✓ Yes | Read as background-clip. |
-webkit-box-decoration-break |
✓ Yes | Read as box-decoration-break. |
-webkit-hyphenate-character |
✓ Yes | Read as hyphenate-character. |
-webkit-hyphens |
✓ Yes | Read as hyphens. |
-webkit-line-clamp |
✓ Yes | Read as line-clamp. |
-webkit-mask |
✓ Yes | Read as mask, and every -webkit-mask-* longhand. |
-webkit-writing-mode |
✓ Yes | Read as writing-mode. |
word-wrap |
✓ Yes | Read as overflow-wrap. |
Interaction, animation and scrolling
At-rules
| At-rule | PdfPecker | Notes |
|---|---|---|
@charset |
✓ Yes | |
@import |
✓ Yes | With layer(), supports() and media queries. Remote files load only through your ResourceResolver. |
@media |
✓ Yes | print and all match, screen does not. Page width, height, aspect-ratio, orientation, ranges, and/or/not, plus resolution, color, prefers-color-scheme (light), hover and pointer (none), overflow-block (paged) and more. |
@supports |
✓ Yes | Property tests, selector(), font-format() and font-tech(). |
@layer |
✓ Yes | Including the !important reversal. |
@container |
½ Partly | Size queries and style(--custom); no scroll-state(). |
@property |
✓ Yes | syntax, inherits and initial-value. |
@font-face |
½ Partly | src (url(), local(), format()), font-weight and font-stretch ranges, font-style, unicode-range. font-display is accepted; size-adjust and the metric overrides are ignored. |
@counter-style |
✓ Yes | Every system and descriptor. |
@page |
✓ Yes | size, margins, backgrounds, :first, :left, :right, :blank, named pages and all 16 margin boxes. marks, bleed and page-orientation are ignored. |
@footnote |
✓ Yes | The footnote area inside @page. |
@namespace |
½ Partly | Accepted and ignored; HTML needs no namespaces. |
CSS nesting (&) |
✓ Yes | |
@scope |
✕ No | Rules inside are skipped. |
@font-feature-values |
✕ No | |
@font-palette-values |
✕ No | |
@custom-media |
✕ No | |
@function |
✕ No | |
@position-try |
✕ No | Anchor positioning is not supported. |
@keyframes |
– No effect | No animations on paper. |
@starting-style |
– No effect | Only used for transitions. |
@view-transition |
– No effect | |
@document |
✕ No | Obsolete Firefox rule. |
Selectors
A rule whose selector PdfPecker cannot parse is skipped as a whole, as browsers do. Interaction states are parsed and never match, as in Chrome's print output.
| Selector | PdfPecker | Notes |
|---|---|---|
| Type, class, id and universal (*) | ✓ Yes | |
| Attribute: [a], =, ~=, |=, ^=, $=, *= and the i and s flags | ✓ Yes | |
| Combinators: descendant, >, + and ~ | ✓ Yes | |
| Nesting selector & | ✓ Yes | |
:root |
✓ Yes | |
:empty |
✓ Yes | |
:first-child, :last-child, :only-child |
✓ Yes | |
:nth-child(), :nth-last-child() |
✓ Yes | Including An+B of S. |
:first-of-type, :last-of-type, :only-of-type, :nth-of-type(), :nth-last-of-type() |
✓ Yes | |
:not(), :is(), :where() |
✓ Yes | Complex selector lists; :is() and :where() are forgiving. Also :matches() and :-webkit-any(). |
:has() |
✓ Yes | Relative selectors; :has() cannot nest inside :has(), as the spec says. |
:lang() |
✓ Yes | |
:dir() |
✓ Yes | From the dir attribute. |
:link, :any-link |
✓ Yes | |
:scope |
✓ Yes | Matches the root. |
:defined |
✓ Yes | |
:checked, :default |
✓ Yes | |
:disabled, :enabled |
✓ Yes | |
:required, :optional |
✓ Yes | |
:read-only, :read-write |
✓ Yes | |
:placeholder-shown |
✓ Yes | |
::before, ::after |
✓ Yes | |
::marker |
✓ Yes | |
::first-letter |
✓ Yes | With initial-letter for drop caps. |
::first-line |
✓ Yes | |
::placeholder |
✓ Yes | On text fields and textareas. |
::footnote-call, ::footnote-marker |
✓ Yes | From CSS Generated Content for Paged Media. |
@page :first, :left, :right, :blank |
✓ Yes | |
:valid, :invalid |
✕ No | Rules with them are skipped. |
:in-range, :out-of-range |
✕ No | Rules with them are skipped. |
:open |
✕ No | Use [open] for details elements. |
:heading, :heading() |
✕ No | |
:state(), :host, :host(), :host-context(), ::part(), ::slotted() |
✕ No | No shadow DOM: scripts do not run. |
::details-content |
✕ No | |
::checkmark, ::picker(), ::picker-icon |
✕ No | |
| Column combinator || and :nth-col() | ✕ No | |
| Namespace selector ns|E | ✕ No | |
:hover, :active, :focus, :focus-visible, :focus-within, :visited, :target |
– No effect | Parsed, never match, as in Chrome print. |
:indeterminate, :autofill, :user-valid, :user-invalid, :fullscreen, :modal, :popover-open, :playing, :paused |
– No effect | Parsed, never match. |
::selection, ::highlight(), ::spelling-error, ::grammar-error, ::target-text, ::search-text |
– No effect | Nothing is selected on paper. |
::backdrop, ::file-selector-button, ::cue, ::view-transition-*, ::scroll-marker, ::scroll-button() |
– No effect |
Units, colours and functions
| Value | PdfPecker | Notes |
|---|---|---|
| px, pt, pc, in, cm, mm, Q, % | ✓ Yes | |
| em, rem | ✓ Yes | |
| ex, ch, cap, ic, lh and rex, rch, rcap, ric, rlh | ✓ Yes | Measured from the font. |
| vw, vh, vmin, vmax, vi, vb and the sv*, lv*, dv* sets | ✓ Yes | The viewport is the page content area. |
| cqw, cqh, cqi, cqb, cqmin, cqmax | ✓ Yes | |
| fr | ✓ Yes | In grid tracks. |
| deg, rad, grad, turn | ✓ Yes | |
| dpi, dpcm, dppx | ✓ Yes | In media queries. |
| s, ms, Hz, kHz | – No effect | Only used by animations and speech. |
| Named colours, hex (3, 4, 6, 8 digits), currentColor, transparent | ✓ Yes | |
| rgb(), rgba(), hsl(), hsla(), hwb() | ✓ Yes | |
| lab(), lch(), oklab(), oklch(), color() | ✓ Yes | Wide-gamut colours are mapped to sRGB. |
| color-mix(), relative colours (from) | ✓ Yes | |
| light-dark() | ✓ Yes | Takes the light colour. |
| contrast-color() | ✕ No | |
| Device CMYK and spot colours (device-cmyk()) | ✕ No | Colours are written as RGB. |
| calc(), min(), max(), clamp() | ✓ Yes | |
| round(), mod(), rem(), abs(), sign() | ✓ Yes | |
| sin(), cos(), tan(), asin(), acos(), atan(), atan2() | ✓ Yes | |
| pow(), sqrt(), hypot(), log(), exp() | ✓ Yes | |
| calc-size(), progress(), random(), sibling-index(), sibling-count(), if() | ✕ No | |
| var() and custom properties | ✓ Yes | Anywhere, in shorthands and inside math. |
| env() | ✕ No | |
| attr() | ½ Partly | In content only; no typed attr() in other properties. |
| url() | ✓ Yes | Data URIs, local files and, through your ResourceResolver, remote files. Not drawn in content. |
| linear-gradient(), radial-gradient(), conic-gradient() and repeating forms | ✓ Yes | Drawn as PDF shadings. |
| image-set() | ✕ No | Not drawn as a background; use url(). |
| cross-fade(), element(), paint() | ✕ No | |
| counter(), counters(), symbols() | ✓ Yes | |
| string(), content(), target-counter(), target-text(), leader() | ✓ Yes | Paged media functions. |
| target-counters() | ✕ No | |
| anchor(), anchor-size() | ✕ No | |
| Basic shapes: inset(), circle(), ellipse(), polygon(), path() | ✓ Yes | In clip-path and shape-outside. |
| xywh(), rect(), shape(), ray(), superellipse() | ✕ No | |
| repeat(), minmax(), fit-content() | ✓ Yes | In grid tracks. |
| Transform functions: translate, scale, rotate, skew, matrix | ✓ Yes | |
| 3D transform functions and perspective() | ½ Partly | Flattened, because PDF is affine. |
| Filter functions: blur, brightness, contrast, drop-shadow, grayscale, hue-rotate, invert, opacity, saturate, sepia, url() | ✓ Yes | blur and drop-shadow are rasterized at 144 dpi. |
| inherit, initial, unset, revert, revert-layer | ✓ Yes | Also on shorthands. |
| !important | ✓ Yes |