Add test for @page/@import/@charset/@namespace/@font-face

pull/2995/head
Christian Kaisermann 6 years ago
parent 6a388a9f86
commit 22b7d86c27

@ -0,0 +1,3 @@
<style>
@charset "utf-8";
</style>

@ -0,0 +1 @@
@font-face{font-family:MyHelvetica;src:local('Helvetica Neue Bold'), local('HelveticaNeue-Bold'), url(MgOpenModernaBold.ttf);font-weight:bold}

@ -0,0 +1,7 @@
<style>
@font-face {
font-family: MyHelvetica;
src: local('Helvetica Neue Bold'), local('HelveticaNeue-Bold'), url(MgOpenModernaBold.ttf);
font-weight: bold;
}
</style>

@ -0,0 +1 @@
@import 'custom.css';@import "common.css" screen;@import url(chrome://communicator/skin/);@import url(fineprint.css) print;@import url(landscape.css) screen and (orientation:landscape);@import url(red.css) (min-width:400px);

@ -0,0 +1,8 @@
<style>
@import 'custom.css';
@import "common.css" screen;
@import url(chrome://communicator/skin/);
@import url(fineprint.css) print;
@import url(landscape.css) screen and (orientation:landscape);
@import url(red.css) (min-width:400px);
</style>

@ -0,0 +1 @@
@namespace url(http://www.w3.org/1999/xhtml);@namespace svg url(http://www.w3.org/2000/svg);a{color:blue}svg|a{color:green}*|a{color:red}

@ -0,0 +1,19 @@
<style>
@namespace url(http://www.w3.org/1999/xhtml);
@namespace svg url(http://www.w3.org/2000/svg);
/* This matches all XHTML <a> elements, as XHTML is the default unprefixed namespace */
:global(a) {
color: blue;
}
/* This matches all SVG <a> elements */
:global(svg|a) {
color: green;
}
/* This matches both XHTML and SVG <a> elements */
:global(*|a) {
color: red;
}
</style>

@ -0,0 +1 @@
@page vertical{size:A4 portrait;@top-center{content:"Vertical"}}@page :right{@top-center{content:"Preliminary edition"}@bottom-center{content:counter(page)}}@page :first{color:green;font-size:20pt;@top-left{content:"foo";color:blue}@top-right{content:"bar"}}

@ -0,0 +1,32 @@
<style>
@page vertical {
size: A4 portrait;
@top-center {
content: "Vertical";
}
}
@page :right {
@top-center {
content: "Preliminary edition";
}
@bottom-center {
content: counter(page);
}
}
@page :first {
color: green;
font-size: 20pt;
@top-left {
content: "foo";
color: blue;
}
@top-right {
content: "bar";
}
}
</style>

@ -0,0 +1 @@
@page{margin:1cm;size:A4;bleed:7pt}

@ -0,0 +1,7 @@
<style>
@page{
margin: 1cm;
size: A4;
bleed: 7pt;
}
</style>
Loading…
Cancel
Save