File: bounded-sizes-reftest.tentative.html

package info (click to toggle)
firefox 144.0-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 4,637,504 kB
  • sloc: cpp: 7,576,692; javascript: 6,430,831; ansic: 3,748,119; python: 1,398,978; xml: 628,810; asm: 438,679; java: 186,194; sh: 63,212; makefile: 19,159; objc: 13,086; perl: 12,986; yacc: 4,583; cs: 3,846; pascal: 3,448; lex: 1,720; ruby: 1,003; exp: 762; php: 436; lisp: 258; awk: 247; sql: 66; sed: 53; csh: 10
file content (72 lines) | stat: -rw-r--r-- 2,275 bytes parent folder | download | duplicates (10)
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
<!DOCTYPE html>
<meta charset=utf-8>
<link rel="match" href="bounded-sizes-reftest-ref.html">
<link rel="help" href="https://github.com/WICG/PEPC/blob/main/explainer.md#locking-the-pepc-style">
<body>
  <div>
    The permission element should have some limits for the min/max-width/height:
    <ul>
    <li>min-width should be sufficient to fit the element text (depends on user agent implementation)</li>
    <li>max-width should be at most 3x min-width</li>
    <li>min-height should be sufficient to fit the element text (1em)</li>
    <li>max-height should be at most 3x min-height</li>
    <li>padding-left/top only work with width/height: auto and are at most 5em/1em</li>
    <li>padding-right/bottom are copied over from padding-left/top in this case</li>
    </ul>
  </div>

<style>
  #id1 {
    font-size: 10px;
    min-height: 1px;
    max-height: 100px;
    border: 0px;

    /* These values are extreme enough that they should be out of bounds for any implementation */
    min-width: 10px;
    max-width: 1000px;

    /* This element will be as tiny as possible */
    width: 1px;
    height: 1px;
  }
  #id2 {
    font-size: 10px;
    min-height: 1px;
    max-height: 100px;
    border: 0px;

    /* These values are extreme enough that they should be out of bounds for any implementation */
    min-width: 10px;
    max-width: 1000px;

    /* This element will be as large as possible */
    width: 1000px;
    height: 1000px;
  }
  #id3 {
    font-size: 10px;
    width: auto;
    height: auto;
    border: 0px;

    /* There is a slight misalignment of the text (by 1px) when using
       padding vs using width/height. Since this test's purpose is to
       check that the bounds are identical, the color and background-color
       are set to the same value to cover the slight text misalignment */
    color:black;
    background-color: black;
    border: 1em solid darkmagenta;

    /* Only padding-top and padding-left are taken into account */
    padding-top: 5px;
    padding-left: 1000px;
    padding-bottom: 1px;
    padding-right: 1px;
  }
</style>

<div><permission id="id1" type="geolocation"></permission></div>
<div><permission id="id2" type="camera"></permission></div>
<div><permission id="id3" type="microphone"></permission></div>
</body>