tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

negation-002.html (1266B)


      1 <!doctype html>
      2 <html>
      3 <head>
      4 	<title>Test: It is invalid to mix "and" and "or" and "not" at the same level of a media query.</title>
      5 	<link rel="author" title="Romain Menke" href="https://github.com/romainmenke">
      6 	<link rel="help" href="https://www.w3.org/TR/mediaqueries-4/#media-conditions">
      7 	<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
      8 	<meta name="assert" content="Test passes if invalid combinations with 'not' do not apply.">
      9 	<style>
     10 		div {
     11 			background-color: red;
     12 			height: 25px;
     13 			width: 100px;
     14 		}
     15 
     16 		@media ((color) and (color)) {
     17 			/* Only green when the browser supports the general syntax */
     18 			div {
     19 				background-color: green;
     20 			}
     21 		}
     22 
     23 		@media (not (monochrome) and (color)) {
     24 			.test1 { background: red; }
     25 		}
     26 		@media (not (monochrome) or (color)) {
     27 			.test2 { background: red; }
     28 		}
     29 		@media ((color) and not (monochrome)) {
     30 			.test3 { background: red; }
     31 		}
     32 		@media ((color) or not (monochrome)) {
     33 			.test4 { background: red; }
     34 		}
     35 </style>
     36 </head>
     37 <body>
     38 	<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
     39 	<div class="test1"></div>
     40 	<div class="test2"></div>
     41 	<div class="test3"></div>
     42 	<div class="test4"></div>
     43 </body>
     44 </html>