Skip to content

Commit

Permalink
Fixes for font palette tests (#32815)
Browse files Browse the repository at this point in the history
  • Loading branch information
drott committed Feb 11, 2022
1 parent 1acb71d commit 1c96e26
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 13 deletions.
10 changes: 2 additions & 8 deletions css/css-fonts/font-palette-modify-notref.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,13 @@
src: url("resources/COLR-palettes-test-font.ttf") format("truetype");
}

@font-palette-values MyPalette {
@font-palette-values --MyPalette {
font-family: "COLR-test-font";
base-palette: 1;
}

@font-palette-values MyPalette2 {
font-family: "COLR-test-font";
base-palette: 0;
override-color: 1 #00FF00;
}
</style>
</head>
<body>
<div id="target" style="font: 48px 'COLR-test-font'; font-palette: MyPalette;">A</div>
<div id="target" style="font: 48px 'COLR-test-font'; font-palette: --MyPalette;">A</div>
</body>
</html>
3 changes: 2 additions & 1 deletion css/css-fonts/font-palette-modify.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@
@font-palette-values --MyPalette2 {
font-family: "COLR-test-font";
base-palette: 0;
override-colors: 1 #00FF00;
/* Glyph 'A' uses palette indices 3 and 7. */
override-colors: 3 #00FF00;
}
</style>
</head>
Expand Down
4 changes: 2 additions & 2 deletions css/css-fonts/font-palette-remove-notref.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@
src: url("resources/COLR-palettes-test-font.ttf") format("truetype");
}

@font-palette-values MyPalette {
@font-palette-values --MyPalette {
font-family: "COLR-test-font";
base-palette: 1;
}
</style>
</head>
<body>
<div id="target" style="font: 48px 'COLR-test-font'; font-palette: MyPalette;">A</div>
<div id="target" style="font: 48px 'COLR-test-font'; font-palette: --MyPalette;">A</div>
</body>
</html>
4 changes: 2 additions & 2 deletions css/css-fonts/palette-values-rule-delete-notref.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@
src: url("resources/COLR-palettes-test-font.ttf") format("truetype");
}

@font-palette-values MyPalette {
@font-palette-values --MyPalette {
font-family: "COLR-test-font";
base-palette: 1;
}
</style>
</head>
<body>
<div style="font: 48px 'COLR-test-font'; font-palette: MyPalette;">A</div>
<div style="font: 48px 'COLR-test-font'; font-palette: --MyPalette;">A</div>
</body>
</html>

0 comments on commit 1c96e26

Please sign in to comment.