Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Firefox/layout/base/tests/   (Browser von der Mozilla Stiftung Version 136.0.1©)  Datei vom 10.2.2025 mit Größe 1 kB image not shown  

Quelle  file_dynamic_toolbar_max_height.html   Sprache: HTML

 
 products/Sources/formale Sprachen/C/Firefox/layout/base/tests/file_dynamic_toolbar_max_height.html


<!doctype html>
<meta charset=utf-8>
<meta name="viewport" content="width=device-width,minimum-scale=1,initial-scale=1">
<title>Tests metrics with dynamic toolbar</title>
<script>
const ok = opener.ok.bind(opener);
const is = opener.is.bind(opener);
const original_finish = opener.SimpleTest.finish;
const SimpleTest = opener.SimpleTest;
const add_task = opener.add_task;
SimpleTest.finish = function finish() {
  self.close();
  original_finish();
}
</script>
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css">
<style>
html {
  scrollbar-width: none;
}
#percent {
  position: absolute;
  height: 100%;
}
#vh {
  position: absolute;
  height: 100vh;
}
</style>
<div id="percent"></div>
<div id="vh"></div>
<script>
'use strict';

SpecialPowers.DOMWindowUtils.setDynamicToolbarMaxHeight(0);

let percentHeight = getComputedStyle(percent).height;
let vhHeight = getComputedStyle(vh).height;
is(percentHeight, vhHeight,
   "%-units and vh-units should be the same when the dynamic toolbar max " +
   "height is zero");

SpecialPowers.DOMWindowUtils.setDynamicToolbarMaxHeight(50);

percentHeight = getComputedStyle(percent).height;
vhHeight = getComputedStyle(vh).height;
is(parseInt(percentHeight) + 50, parseInt(vhHeight),
   "vh units should be 50px greater than %-units");
is(document.documentElement.clientHeight, parseInt(percentHeight),
   "documentElement.clientHeight should equal to %-units");
ok(matchMedia(`(height: ${percentHeight})`).matches,
   "Media Queries' height is not including the dynamic toolbar max height");

SimpleTest.finish();

</script>

Messung V0.5
C=89 H=86 G=87

¤ Dauer der Verarbeitung: 0.4 Sekunden  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.