From 9a110dee28ae2ef12ee014b98fda6bae6ee48edb Mon Sep 17 00:00:00 2001 From: YujiSoftware Date: Wed, 2 Mar 2022 20:22:51 +0900 Subject: Migrate to Compat macro (zh-cn) --- .../repeating-linear-gradient()/index.html | 139 +-------------------- 1 file changed, 1 insertion(+), 138 deletions(-) (limited to 'files/zh-cn/web/css/gradient/repeating-linear-gradient()') diff --git a/files/zh-cn/web/css/gradient/repeating-linear-gradient()/index.html b/files/zh-cn/web/css/gradient/repeating-linear-gradient()/index.html index c4dd9fc55d..007a1eb361 100644 --- a/files/zh-cn/web/css/gradient/repeating-linear-gradient()/index.html +++ b/files/zh-cn/web/css/gradient/repeating-linear-gradient()/index.html @@ -160,144 +160,7 @@ where <side-or-corner> = [left | right] || [top | bottom]

浏览器兼容性

-
{{CompatibilityTable}}
- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FeatureFirefox (Gecko)ChromeInternet ExplorerOperaSafari
Basic support (on {{cssxref("background")}} and {{cssxref("background-image")}}){{CompatGeckoDesktop("1.9.2")}}{{property_prefix("-moz")}}[3]
- {{CompatGeckoDesktop("16")}}[5]
10.0 (534.16){{property_prefix("-webkit")}} [2][3]10.0 [1]11.10{{property_prefix("-o")}} [3]5.1{{property_prefix("-webkit")}}[2][3]
On {{cssxref("border-radius")}}{{CompatGeckoDesktop("29")}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}
On any other property that accept {{cssxref("<image>")}}{{CompatNo}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}
Legacy webkit syntax{{non-standard_inline}}{{CompatNo}}3{{property_prefix("-webkit")}} [2]{{CompatNo}}{{CompatNo}}4.0{{property_prefix("-webkit")}}[2]
Legacy from syntax (without to){{non-standard_inline}}{{CompatGeckoDesktop("1.9.2")}}{{property_prefix("-moz")}}[4]
- Removed in {{CompatGeckoDesktop("16")}}[7]
10.0 (534.16){{property_prefix("-webkit")}} [2]10.011.10{{property_prefix("-o")}}[4]5.1{{property_prefix("-webkit")}}[2]
to syntax{{CompatGeckoDesktop("10")}}{{property_prefix("-moz")}}[4]
- {{CompatGeckoDesktop("16")}}
26.010.011.60{{property_prefix("-o")}}[4]
- Presto 2.12 will remove the prefix.
{{CompatNo}}
Interpolation hints/gradient midpoints (a percent without a color){{CompatGeckoDesktop("36")}}40{{CompatUnknown}}27{{CompatVersionUnknown}}[6]
Unitless 0 for <angle>{{CompatGeckoDesktop("46")}}{{property_prefix("-webkit")}}[8]
- {{CompatNo}}[9]
{{CompatVersionUnknown}}Edge 12{{CompatVersionUnknown}}{{CompatVersionUnknown}}
-
- -
- - - - - - - - - - - - - - - - - - - -
FeatureFirefox (Gecko)ChromeInternet ExplorerOpera (Presto)Safari
Basic support{{CompatGeckoMobile("1.9.2")}}{{property_prefix("-moz")}}[3]
- {{CompatGeckoMobile("16")}}[5]
-

16{{property_prefix("-webkit")}}
- 26

-
10{{CompatVersionUnknown}}{{CompatVersionUnknown}}[6]
-
- -

[1] Internet Explorer 5.5 through 9.0 supports proprietary filter: progid:DXImageTransform.Microsoft.Gradient() filter.

- -

[2] WebKit since 528 supports the legacy -webkit-gradient(linear,…) function. As of WebKit 534.16, it also supports the standard gradient syntax. Unlike in Gecko, in legacy WebKit you cannot specify both a position and angle in -webkit-linear-gradient(). You can achieve the same effect by offsetting the color stops.

- -

[3] Gecko, Opera & Webkit considers {{cssxref("<angle>")}} to start to the right, instead of the top. I.e. it considered an angle of 0deg as a direction indicator pointing to the right. This is different from the latest specification where an angle of 0deg as a direction indicator points to the top. Since Firefox 42, the prefixed version of gradients can be disabled by setting layout.css.prefixes.gradients to false.

- -

[4] Firefox 3.6 and Opera 11.10 implemented, prefixed, an early syntax where the starting corner or side was indicated without the to keyword, and effectively considered as a from position. The to syntax has been added in Firefox 10 and Opera 11.60 , at first without removing the deprecated syntax and translation between the two is trivial:

- -
-moz-repeating-linear-gradient(to top left, blue, red);
- -

is the same as:

- -
-moz-repeating-linear-gradient(bottom right, blue, red);
- -

The legacy syntax, without to, is planned to go away when the prefix is removed.

- -

[5] Before Firefox 36, Gecko didn't apply gradient on the pre-multiplied color space, leading to shade of grey unexpectedly appearing when used with transparency.

- -

[6] {{webkitbug(1074056)}}.

- -

[7] In addition to the unprefixed support using the standard syntax, Gecko 44.0 {{geckoRelease("44.0")}} added support for a -webkit prefixed version of the function using the legacy 'from' syntax for web compatibility reasons behind the preference layout.css.prefixes.webkit, defaulting to false. Since Gecko 49.0 {{geckoRelease("49.0")}} the preference defaults to true.

- -

[8] In -webkit-linear-gradient function (handled below), Gecko accept unitless 0 for angles, to match webkit/blink,See {{bug("1239153")}}.

- -

[9] See {{bug("1363292")}}.

+{{Compat("css.types.image.gradient.repeating-linear-gradient")}}

了解更多

-- cgit v1.2.3-54-g00ecf