Skip to content

Commit 87a1c40

Browse files
committed
more macros
1 parent f767030 commit 87a1c40

File tree

14 files changed

+26
-26
lines changed

14 files changed

+26
-26
lines changed

files/en-us/web/css/reference/values/basic-shape/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ The parameters common across the syntax of some basic shape functions include:
8888

8989
The `<basic-shape-rect>` type, a subset of the `<basic-shape>` type, represents the basic-shape functions limited to creating rectangles, including {{cssxref("basic-shape/inset","inset()")}}, {{cssxref("basic-shape/rect","rect()")}}, and {{cssxref("basic-shape/xywh","xywh()")}}.
9090

91-
The [`polygon()`](/en-US/docs/Web/CSS/Reference/Values/basic-shape/polygon), [`path()`](/en-US/docs/Web/CSS/Reference/Values/basic-shape/path), and {{cssxref("shape()")}} functions can also be used to create rectangles, but are not limited to only four-sided, right-angled shapes.
91+
The {{cssxref("polygon()")}}, {{cssxref("path()")}}, and {{cssxref("shape()")}} functions can also be used to create rectangles, but are not limited to only four-sided, right-angled shapes.
9292

9393
#### Syntax for rectangles by container insets
9494

files/en-us/web/css/reference/values/calc-size/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ sidebar: cssref
1010

1111
{{seecompattable}}
1212

13-
The **`calc-size()`** [CSS](/en-US/docs/Web/CSS) [function](/en-US/docs/Web/CSS/Reference/Values/Functions) allows you to perform calculations on [intrinsic size](/en-US/docs/Glossary/Intrinsic_Size) values such as `auto`, {{cssxref("fit-content")}}, and {{cssxref("max-content")}}; this is not supported by the regular {{cssxref("calc()")}} function.
13+
The **`calc-size()`** [CSS](/en-US/docs/Web/CSS) [function](/en-US/docs/Web/CSS/Reference/Values/Functions) allows you to perform calculations on {{glossary("intrinsic size")}} values such as `auto`, {{cssxref("fit-content")}}, and {{cssxref("max-content")}}; this is not supported by the regular {{cssxref("calc()")}} function.
1414

15-
`calc-size()` return values can also be [interpolated](/en-US/docs/Glossary/Interpolation), enabling size keyword values to be used in [animations](/en-US/docs/Web/CSS/Guides/Animations) and [transitions](/en-US/docs/Web/CSS/Guides/Transitions). In effect, including `calc-size()` in a property value automatically applies [`interpolate-size: allow-keywords`](/en-US/docs/Web/CSS/Reference/Properties/interpolate-size) to the selection.
15+
`calc-size()` return values can also be {{glossary("interpolated")}}, enabling size keyword values to be used in [animations](/en-US/docs/Web/CSS/Guides/Animations) and [transitions](/en-US/docs/Web/CSS/Guides/Transitions). In effect, including `calc-size()` in a property value automatically applies [`interpolate-size: allow-keywords`](/en-US/docs/Web/CSS/Reference/Properties/interpolate-size) to the selection.
1616

1717
Note however that `interpolate-size` is inherited, therefore applying it to an element enables interpolation of intrinsic size keywords for every property applied to that element and its children. As a result, `interpolate-size` is the preferred solution for enabling intrinsic size animations. You should only use `calc-size()` to enable intrinsic size animations if they also require calculations.
1818

files/en-us/web/css/reference/values/calc/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ For a full explanation of typed arithmetic in CSS, along with examples, see [Usi
119119

120120
### Support for computing color channels in relative colors
121121

122-
The `calc()` function can be used to manipulate color channels directly within the context of [relative colors](/en-US/docs/Web/CSS/Guides/Colors/Using_relative_colors). This allows for dynamic adjustments of color channels in color models such as {{cssxref("rgb()")}}, {{cssxref("hsl()")}}, and [`lch()`](/en-US/docs/Web/CSS/Reference/Values/color_value/lch).
122+
The `calc()` function can be used to manipulate color channels directly within the context of [relative colors](/en-US/docs/Web/CSS/Guides/Colors/Using_relative_colors). This allows for dynamic adjustments of color channels in color models such as {{cssxref("rgb()")}}, {{cssxref("hsl()")}}, and {{cssxref("lch()")}}.
123123

124124
The relative color syntax defines several color-channel keywords, each of which represents the value of the color channel as a {{cssxref("&lt;number&gt;")}} (see [Channel values resolve to `<number>` values](/en-US/docs/Web/CSS/Guides/Colors/Using_relative_colors#channel_values_resolve_to_number_values) for more information). The `calc()` function can use these color-channel keywords to perform dynamic adjustments on the color channels, for example, `calc(r + 10)`.
125125

files/en-us/web/css/reference/values/color-interpolation-method/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ spec-urls: https://drafts.csswg.org/css-color/#interpolation-space
77
sidebar: cssref
88
---
99

10-
The **`<color-interpolation-method>`** [CSS](/en-US/docs/Web/CSS) [data type](/en-US/docs/Web/CSS/Reference/Values/Data_types) represents the [color space](/en-US/docs/Glossary/Color_space) used for interpolation between {{CSSXref("&lt;color&gt;")}} values. It can be used to override the default interpolation color space for color-related functional notations such as {{CSSXref("color_value/color-mix", "color-mix()")}} and {{cssxref("linear-gradient()")}}.
10+
The **`<color-interpolation-method>`** [CSS](/en-US/docs/Web/CSS) [data type](/en-US/docs/Web/CSS/Reference/Values/Data_types) represents the {{glossary("color space")}} used for interpolation between {{CSSXref("&lt;color&gt;")}} values. It can be used to override the default interpolation color space for color-related functional notations such as {{CSSXref("color_value/color-mix", "color-mix()")}} and {{cssxref("linear-gradient()")}}.
1111

1212
When interpolating `<color>` values, the interpolation color space defaults to Oklab.
1313

files/en-us/web/css/reference/values/color_value/hsl/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -398,7 +398,7 @@ div.legacyHSLA {
398398
## See also
399399

400400
- {{CSSXref("&lt;hue&gt;")}} data type
401-
- [`lch()`](/en-US/docs/Web/CSS/Reference/Values/color_value/lch) and [`hwb()`](/en-US/docs/Web/CSS/Reference/Values/color_value/hwb) color functions
401+
- {{cssxref("lch()")}} and {{cssxref("hwb()")}} color functions
402402
- [Hue interpolation in `color-mix()`](/en-US/docs/Web/CSS/Reference/Values/color_value/color-mix#using_hue_interpolation_in_color-mix)
403403
- [List of all color notations](/en-US/docs/Web/CSS/Reference/Values/color_value)
404404
- [Color format converter tool](/en-US/docs/Web/CSS/Guides/Colors/Color_format_converter)

files/en-us/web/css/reference/values/dashed-function/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ The markup features a {{htmlelement("p")}} containing some text content:
3838

3939
#### CSS
4040

41-
In our styles, we first define the CSS custom function. The function is called `--transparent` and accepts two parameters: a color and a numeric alpha channel value. Inside the function body, we use [relative color syntax](/en-US/docs/Web/CSS/Guides/Colors/Using_relative_colors) to transform the passed color into an [`oklch()`](/en-US/docs/Web/CSS/Reference/Values/color_value/oklch) color with an alpha channel equal to the passed alpha value; this becomes the function's `result`:
41+
In our styles, we first define the CSS custom function. The function is called `--transparent` and accepts two parameters: a color and a numeric alpha channel value. Inside the function body, we use [relative color syntax](/en-US/docs/Web/CSS/Guides/Colors/Using_relative_colors) to transform the passed color into an {{cssxref("oklch()")}} color with an alpha channel equal to the passed alpha value; this becomes the function's `result`:
4242

4343
```css live-sample___basic-example
4444
@function --transparent(--color <color>, --alpha <number>) {

files/en-us/web/css/reference/values/hue/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ sidebar: cssref
1212
---
1313

1414
The **`<hue>`** [CSS](/en-US/docs/Web/CSS) [data type](/en-US/docs/Web/CSS/Reference/Values/Data_types) represents the hue angle of a color.
15-
It is used in the color functions that accept hue expressed as a single value, specifically {{cssxref("hsl()")}}, [`hwb()`](/en-US/docs/Web/CSS/Reference/Values/color_value/hwb), [`lch()`](/en-US/docs/Web/CSS/Reference/Values/color_value/lch), and [`oklch()`](/en-US/docs/Web/CSS/Reference/Values/color_value/oklch) functional notations.
15+
It is used in the color functions that accept hue expressed as a single value, specifically {{cssxref("hsl()")}}, {{cssxref("hwb()")}}, {{cssxref("lch()")}}, and {{cssxref("oklch()")}} functional notations.
1616

1717
## Syntax
1818

files/en-us/web/css/reference/values/revert-layer/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ sidebar: cssref
88

99
The **`revert-layer`** [CSS-wide keyword](/en-US/docs/Web/CSS/Reference/Values/Data_types#css-wide_keywords) rolls back the value of a property in a {{cssxref("@layer", "cascade layer")}} to the value of the property in a CSS rule matching the element in a previous cascade layer. The value of a property with this keyword is recalculated as if no rules were specified on the target element in the current cascade layer.
1010

11-
If there is no other cascade layer to revert to for the matching CSS rule, the property value rolls back to the [computed value](/en-US/docs/Web/CSS/Guides/Cascade/Property_value_processing#computed_value) derived from the current layer. Furthermore, if there is no matching CSS rule in the current layer, the property value for the element rolls back to the style defined in a previous [style origin](/en-US/docs/Glossary/Style_origin).
11+
If there is no other cascade layer to revert to for the matching CSS rule, the property value rolls back to the [computed value](/en-US/docs/Web/CSS/Guides/Cascade/Property_value_processing#computed_value) derived from the current layer. Furthermore, if there is no matching CSS rule in the current layer, the property value for the element rolls back to the style defined in a previous {{glossary("style origin")}}.
1212

1313
This keyword can be applied to any CSS property, including the CSS shorthand property {{cssxref("all")}}.
1414

files/en-us/web/css/reference/values/transform-function/index.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -39,15 +39,15 @@ The `<transform-function>` data type is specified using one of the transformatio
3939

4040
### Scaling (resizing)
4141

42-
- [`scale()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/scale)
42+
- {{cssxref("scale()")}}
4343
- : Scales an element up or down on the 2D plane.
4444
- [`scale3d()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/scale3d)
4545
- : Scales an element up or down in 3D space.
46-
- [`scaleX()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/scaleX)
46+
- {{cssxref("scaleX()")}}
4747
- : Scales an element up or down horizontally.
48-
- [`scaleY()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/scaleY)
48+
- {{cssxref("scaleY()")}}
4949
- : Scales an element up or down vertically.
50-
- [`scaleZ()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/scaleZ)
50+
- {{cssxref("scaleZ()")}}
5151
- : Scales an element up or down along the z-axis.
5252

5353
### Skewing (distortion)
@@ -63,13 +63,13 @@ The `<transform-function>` data type is specified using one of the transformatio
6363

6464
- [`translate()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/translate)
6565
- : Translates an element on the 2D plane.
66-
- [`translate3d()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/translate3d)
66+
- {{cssxref("translate3d()")}}
6767
- : Translates an element in 3D space.
68-
- [`translateX()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/translateX)
68+
- {{cssxref("translateX()")}}
6969
- : Translates an element horizontally.
70-
- [`translateY()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/translateY)
70+
- {{cssxref("translateY()")}}
7171
- : Translates an element vertically.
72-
- [`translateZ()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/translateZ)
72+
- {{cssxref("translateZ()")}}
7373
- : Translates an element along the z-axis.
7474

7575
## Description

files/en-us/web/css/reference/values/transform-function/scale3d/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -224,8 +224,8 @@ div {
224224

225225
- {{cssxref("transform")}}
226226
- {{cssxref("&lt;transform-function&gt;")}}
227-
- [`scaleZ()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/scaleZ)
228-
- [`translate3d()`](/en-US/docs/Web/CSS/Reference/Values/transform-function/translate3d)
227+
- {{cssxref("scaleZ()")}}
228+
- {{cssxref("translate3d()")}}
229229
- {{cssxref("rotate3d()")}}
230230
- Individual transform properties:
231231
- {{cssxref("translate")}}

0 commit comments

Comments
 (0)