Skip to content

Commit 67aca47

Browse files
author
litherum
committed
[css-fonts-4] Add initial text for font-min-size and font-max-size
1 parent 6e64bc7 commit 67aca47

1 file changed

Lines changed: 39 additions & 5 deletions

File tree

css-fonts-4/Overview.bs

Lines changed: 39 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -679,6 +679,45 @@ at least as dark as its predecessor. Only values between 1 - 999 are valid, and
679679
</pre>
680680
</div>
681681

682+
<h3 id="font-min-max-size-prop">Minimum and maximum font size: the 'font-min-size' and 'font-max-size' properties</h3>
683+
684+
<pre class="propdef">
685+
Name: font-min-size
686+
Value: <<absolute-size>> | <<relative-size>> | <<length-percentage>>
687+
Initial: 0px
688+
Applies to: all elements
689+
Inherited: yes
690+
Percentages: refer to parent element's font size
691+
Computed value: absolute length
692+
Media: visual
693+
Animatable: As <<length>>
694+
</pre>
695+
696+
<pre class="propdef">
697+
Name: font-max-size
698+
Value: <<absolute-size>> | <<relative-size>> | <<length-percentage>> | infinity
699+
Initial: infinity
700+
Applies to: all elements
701+
Inherited: yes
702+
Percentages: refer to parent element's font size
703+
Computed value: absolute length
704+
Media: visual
705+
Animatable: As <<length>>
706+
</pre>
707+
708+
These two properties allow a website or user to require an element's font size to be clamped within the range
709+
supplied with these two properties. If the computed value 'font-size' is outside the bounds created by 'font-min-size'
710+
and 'font-max-size', the use value of 'font-size' is clamped to the values specified in these two properties.
711+
712+
Some user agents provide a nonstandard mapping between the computed value of 'font-size' and the used value of 'font-size'.
713+
The interaction of those nonstandard algorithms with 'font-min-size' or 'font-max-size' is explicitly undefined.
714+
715+
If the 'font-min-size' property is computed to be larger than the 'font-max-size' property, then the two properties are ignored.
716+
717+
Users with accessibility preferences may set this in a user-agent style sheet to force websites' text to become larger.
718+
719+
These two properties have no effect on the computed value of 'font-size'.
720+
682721
<h3 id="font-size-adjust-prop">Relative sizing: the 'font-size-adjust' property</h3>
683722

684723
TODO: Migrate this from level 3.
@@ -1753,11 +1792,6 @@ at least as dark as its predecessor. Only values between 1 - 999 are valid, and
17531792

17541793
Issue: Import from level 3
17551794

1756-
<h2 id="min-max-font-size">Minimum and maximum <code>font-size</code></h2>
1757-
1758-
<p>Define new properties to control the minimum and maximum font-size,
1759-
<code>min-font-size</code> and <code>max-font-size</code>.</p>
1760-
17611795
<h2 id="emoji-fallback">Font fallback for emoji codepoints</h2>
17621796

17631797
<p>Many codepoints supported by emoji fonts overlap with codepoints supported

0 commit comments

Comments
 (0)