@@ -136,7 +136,7 @@ Commas in Function Arguments</h4>
136
136
For example, the grammar of the ''random-item()'' function is:
137
137
138
138
<pre>
139
- random-item( <<random-caching-options >> , [<<declaration-value>>?] # )
139
+ random-item( <<random-value-sharing >> , [<<declaration-value>>?] # )
140
140
</pre>
141
141
142
142
The ''#'' indicates comma-separated repetitions,
@@ -1991,28 +1991,28 @@ Generating a Random Numeric Value: the ''random()'' function</h3>
1991
1991
optionally limiting the possible values to a step between those limits:
1992
1992
1993
1993
<pre class=prod>
1994
- <random()> = random( <<random-caching-options >> ? , <<calc-sum>> , <<calc-sum>> , <<calc-sum>> ? )
1994
+ <random()> = random( <<random-value-sharing >> ? , <<calc-sum>> , <<calc-sum>> , <<calc-sum>> ? )
1995
1995
1996
- <dfn><<random-caching-options >></dfn> = <dfn value for="random()|<random-caching-options >">auto</dfn> | [ <<dashed-ident>> || <dfn value for="random()|<random-caching-options >">match-element</dfn> ] | <<number [0,1]>>
1996
+ <dfn><<random-value-sharing >></dfn> = <dfn value for="random()|<random-value-sharing >">auto</dfn> | [ <<dashed-ident>> || <dfn value for="random()|<random-value-sharing >">match-element</dfn> ] | <<number [0,1]>>
1997
1997
</pre>
1998
1998
1999
1999
Its arguments are:
2000
2000
2001
2001
<dl>
2002
- : <css> <<random-caching-options >> </css>
2003
- :: The optional <<random-caching-options >>
2002
+ : <css> <<random-value-sharing >> </css>
2003
+ :: The optional <<random-value-sharing >>
2004
2004
controls whether a given ''random()'' function
2005
2005
resolves similarly or differently to other [=random functions=] on the page.
2006
2006
See [[#random-caching]] for details.
2007
2007
2008
- If <<random-caching-options >> is omitted or specified as ''random()/auto'' ,
2008
+ If <<random-value-sharing >> is omitted or specified as ''random()/auto'' ,
2009
2009
''random()'' functions on different properties,
2010
- and multiple ''random()'' functions within a sinlge property,
2010
+ and multiple ''random()'' functions within a single property,
2011
2011
will resolve to different random values,
2012
2012
and will have different values on every element
2013
2013
styled with that property.
2014
2014
2015
- Providing <<random-caching-options >> makes it "less random":
2015
+ Providing <<random-value-sharing >> makes it "less random":
2016
2016
2017
2017
* two ''random()'' functions on an element with the same <<dashed-ident>>
2018
2018
will use the same random value.
@@ -2173,7 +2173,7 @@ Generating a Random Numeric Value: the ''random()'' function</h3>
2173
2173
If a ''random()'' function can't be [=simplify a calculation tree|simplified=]
2174
2174
by [=computed value=] time,
2175
2175
then it computes to its maximally-simplified form,
2176
- but with its <<random-caching-options >> set to its [=random base value=] .
2176
+ but with its <<random-value-sharing >> set to its [=random base value=] .
2177
2177
2178
2178
<div class=example>
2179
2179
For example, given the declaration ''width: random(50%, 100%)'' ,
@@ -2234,19 +2234,19 @@ Picking a Random Item From a List: the ''random-item()'' function</h3>
2234
2234
from among its list of items.
2235
2235
2236
2236
<pre class=prod>
2237
- <random-item()> = random-item( <<random-caching-options >> , [ <<declaration-value>> ? ]# )
2237
+ <random-item()> = random-item( <<random-value-sharing >> , [ <<declaration-value>> ? ]# )
2238
2238
</pre>
2239
2239
2240
- The <em> required</em> <<random-caching-options >>
2240
+ The <em> required</em> <<random-value-sharing >>
2241
2241
is interpreted identically to ''random()'' .
2242
2242
(See [[#random-caching]] for details.)
2243
2243
2244
- Note: The <<random-caching-options >> argument is required in ''random-item()'' ,
2244
+ Note: The <<random-value-sharing >> argument is required in ''random-item()'' ,
2245
2245
but optional in ''random()'' ,
2246
2246
both for parsing reasons
2247
2247
(it's impossible to tell whether ''random-item(--foo, --bar, --baz)''
2248
2248
has three <<declaration-value>> arguments
2249
- or two and a <<random-caching-options >> argument),
2249
+ or two and a <<random-value-sharing >> argument),
2250
2250
and because accidentally associating the random generation of ''random-item()'' functions together
2251
2251
is much easier to do accidentally,
2252
2252
since only the number of arguments is used to distinguish instances.
@@ -2297,7 +2297,7 @@ Evaluating Random Values</h3>
2297
2297
2298
2298
2299
2299
<h3 id=random-caching>
2300
- Caching Random Values: the <<random-caching-options >> value</h3>
2300
+ Caching Random Values: the <<random-value-sharing >> value</h3>
2301
2301
2302
2302
In a programming language like JavaScript,
2303
2303
there's a clear temporal ordering to code,
@@ -2324,7 +2324,7 @@ Caching Random Values: the <<random-caching-options>> value</h3>
2324
2324
* Each instance of a [=random function=] in styles
2325
2325
has an associated <dfn>random base value</dfn> .
2326
2326
2327
- If the [=random function's=] <<random-caching-options >> is a <<number>> ,
2327
+ If the [=random function's=] <<random-value-sharing >> is a <<number>> ,
2328
2328
the [=random base value=] is that number.
2329
2329
2330
2330
Otherwise, the [=random base value=] is a pseudo-random real number between 0 and 1,
@@ -2347,15 +2347,15 @@ Caching Random Values: the <<random-caching-options>> value</h3>
2347
2347
2348
2348
* A [=random caching key=] is a [=tuple=] of:
2349
2349
1. A [=string=] name: the value of the <<dashed-ident>> ,
2350
- if specified in <<random-caching-options >> ;
2350
+ if specified in <<random-value-sharing >> ;
2351
2351
or else a string of the form <code> "PROPERTY N"</code> ,
2352
2352
where PROPERTY is the name of the property the [=random function=] is used in
2353
2353
(<em> before</em> shorthand expansion, if relevant),
2354
2354
and N is the index of the [=random function=]
2355
2355
among other [=random functions=] in the same property value.
2356
2356
2357
2357
2. An element ID identifying the element the style is being applied to,
2358
- or null if ''random()/match-element'' is specified in <<random-caching-options >> .
2358
+ or null if ''random()/match-element'' is specified in <<random-value-sharing >> .
2359
2359
3. A document ID identifying the {{Document}} the styles are from.
2360
2360
2361
2361
The "element ID" and "document ID" must have the same lifetimes and equivalence
@@ -2466,13 +2466,13 @@ Caching Random Values: the <<random-caching-options>> value</h3>
2466
2466
(or even recognized *as* a ''random()'' function)
2467
2467
in ''--size'' ,
2468
2468
so the default rules for an omitted <<dashed-ident>>
2469
- in the <<random-caching-options >> isn't applied.
2469
+ in the <<random-value-sharing >> isn't applied.
2470
2470
Instead, it's evaluated when it's substituted into 'width' and 'height' ,
2471
2471
so each gets a distinct [=random caching key=] ,
2472
2472
and this ends up defining a random <em> rectangle</em> ,
2473
2473
rather than a square.
2474
2474
2475
- Similarly, a ''match-element'' in the <<random-caching-options >>
2475
+ Similarly, a ''match-element'' in the <<random-value-sharing >>
2476
2476
won't determine its "element identifier"
2477
2477
until substitution actually happens,
2478
2478
which might be <em> after</em> '--size' has inherited through multiple elements,
0 commit comments