-
Notifications
You must be signed in to change notification settings - Fork 2
/
ms-high-contrast-media-query.html
58 lines (52 loc) · 1.8 KB
/
ms-high-contrast-media-query.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<!DOCTYPE html>
<html lang="en">
<head>
<title>MS High Contrast Media Query Test</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
@media all and (-ms-high-contrast) {
.mshc:after {
content: ' MATCHED';
}
}
@media all and (-ms-high-contrast: none) {
.mshc-none:after {
content: ' MATCHED';
}
}
@media all and (-ms-high-contrast: active) {
.mshc-active:after {
content: ' MATCHED';
}
}
@media all and (-ms-high-contrast: white-on-black) {
.mshc-white-on-black:after {
content: ' MATCHED';
}
}
@media all and (-ms-high-contrast: black-on-white) {
.mshc-black-on-white:after {
content: ' MATCHED';
}
}
@media all and (-ms-high-contrast: none), (-ms-high-contrast: active) {
.mshc-none-or-active:after {
content: ' MATCHED';
}
}
</style>
</head>
<body>
<main role="main">
<h1>MS High Contrast Media Query Test</h1>
<p>A test page for various ways to use the <code>-ms-high-contrast</code> media query.</p>
<p class="mshc"><code>@media all and (-ms-high-contrast)</code></p>
<p class="mshc-none"><code>@media all and (-ms-high-contrast: none)</code></p>
<p class="mshc-active"><code>@media all and (-ms-high-contrast: active)</code></p>
<p class="mshc-white-on-black"><code>@media all and (-ms-high-contrast: white-on-black)</code></p>
<p class="mshc-black-on-white"><code>@media all and (-ms-high-contrast: black-on-white)</code></p>
<p class="mshc-none-or-active"><code>@media all and (-ms-high-contrast: none), (-ms-high-contrast: active)</code></p>
</main>
</body>
</html>