From 18c5e600d09d6084fac3025928abdec3ea6e37ba Mon Sep 17 00:00:00 2001 From: allo Date: Wed, 16 Feb 2022 11:51:29 +0800 Subject: mv to .md for css.properties.filter --- files/zh-cn/web/css/filter/index.html | 875 ---------------------------------- files/zh-cn/web/css/filter/index.md | 875 ++++++++++++++++++++++++++++++++++ 2 files changed, 875 insertions(+), 875 deletions(-) delete mode 100644 files/zh-cn/web/css/filter/index.html create mode 100644 files/zh-cn/web/css/filter/index.md diff --git a/files/zh-cn/web/css/filter/index.html b/files/zh-cn/web/css/filter/index.html deleted file mode 100644 index 27fe11b599..0000000000 --- a/files/zh-cn/web/css/filter/index.html +++ /dev/null @@ -1,875 +0,0 @@ ---- -title: filter -slug: Web/CSS/filter -tags: - - CSS - - SVG - - SVG Filter - - filter -translation_of: Web/CSS/filter ---- -

{{CSSRef}}

- -

filter CSS属性将模糊或颜色偏移等图形效果应用于元素。滤镜通常用于调整图像,背景和边框的渲染。

- -

CSS 标准里包含了一些已实现预定义效果的函数。你也可以参考一个 SVG 滤镜,通过一个 URL 链接到 SVG 滤镜元素(SVG filter element)。

- -
{{EmbedInteractiveExample("pages/css/filter.html")}}
- - - -

语法

- -
/* URL to SVG filter */
-filter: url("filters.svg#filter-id");
-
-/* <filter-function> values */
-filter: blur(5px);
-filter: brightness(0.4);
-filter: contrast(200%);
-filter: drop-shadow(16px 16px 20px blue);
-filter: grayscale(50%);
-filter: hue-rotate(90deg);
-filter: invert(75%);
-filter: opacity(25%);
-filter: saturate(30%);
-filter: sepia(60%);
-
-/* Multiple filters */
-filter: contrast(175%) brightness(3%);
-
-/* Use no filter */
-filter: none;
-
-/* Global values */
-filter: inherit;
-filter: initial;
-filter: unset;
- -

设置一种函数,方法如下:

- -
filter: <filter-function> [<filter-function>]* | none
-
- -

给SVG元素 {{SVGElement("filter")}} 引用滤镜, 如下:

- -
filter: url(file.svg#filter-element-id)
- -

插值

- -

如果起始和结束过滤器都有一个不含 {{cssxref("<url>")}} 的相同长度的函数列表,则会根据其指定的规则对其每个过滤器函数进行插值。如果它们的长度不同,较长列表中确实的等效过滤器函数将使用空白的值添加到较短列表的尾部,然后所有的过滤器函数根据其特定的规则插值。如果一个过滤器是none则会使用过滤器函数的默认值替换函数列表,然后根据特定的规则进行插值,否则使用离散插值。

- -

函数

- -

使用 CSS 滤镜属性,你需要设定下面某一函数的值。如果该值无效,函数返回 none。除特殊说明外,函数的值如果接受百分比值(如 34%),那么该函数也接受小数值(如0.34)。

- -

当单个 filter 属性具有两个或多个函数时,其结果将与将两个或多个 filter 属性分别应用于相同的函数时的结果不同

- -

SVG filter

- -

url()

- -

获取指向SVG过滤器的URI,该 SVG filter 可以嵌入到外部XML文件中。

- -
filter: url(resources.svg#c1)
- -

Filter 函数

- -

blur()

- -

{{cssxref("filter-function/blur", "blur()")}} 函数将高斯模糊应用于输入图像。radius 定义了高斯函数的标准偏差值,或者屏幕上有多少像素相互融合,因此,较大的值将产生更多的模糊。若没有设置值,默认为0。该参数可以指定为 CSS 长度,但不接受百分比值。

- -
filter: blur(5px)
-
- -
<svg style="position: absolute; top: -99999px" xmlns="http://www.w3.org/2000/svg">
-  <filter id="svgBlur" x="-5%" y="-5%" width="110%" height="110%">
-    <feGaussianBlur in="SourceGraphic" stdDeviation="5"/>
-  </filter>
-</svg>
- -

{{EmbedLiveSample('blur_example','100%','236px','','', 'no-codepen')}}

- -

brightness()

- -

{{cssxref("filter-function/brightness", "brightness()")}} 函数将线性乘法器应用于输入图像,使其看起来或多或少地变得明亮。值为 0% 将创建全黑图像。值为 100% 会使输入保持不变。其他值是效果的线性乘数。如果值大于 100% 提供更明亮的结果。若没有设置值,默认为 1

- -
filter: brightness(2)
- -
<svg style="position: absolute; top: -99999px" xmlns="http://www.w3.org/2000/svg">
-  <filter id="brightness">
-    <feComponentTransfer>
-      <feFuncR type="linear" slope="[amount]"/>
-      <feFuncG type="linear" slope="[amount]"/>
-      <feFuncB type="linear" slope="[amount]"/>
-    </feComponentTransfer>
-  </filter>
-</svg>
- -

{{EmbedLiveSample('brightness_example','100%','231px','','', 'no-codepen')}}

- -

contrast()

- -

{{cssxref("filter-function/contrast", "contrast()")}} 函数可调整输入图像的对比度。值是 0% 的话,图像会全黑。值是 100%,图像不变。值可以超过 100%,意味着会运用更低的对比。若没有设置值,默认是 1

- -
filter: contrast(200%)
-
- -
<svg height="0" xmlns="http://www.w3.org/2000/svg">
-  <filter id="contrast">
-    <feComponentTransfer>
-      <feFuncR type="linear" slope="[amount]" intercept="-(0.5 * [amount]) + 0.5"/>
-      <feFuncG type="linear" slope="[amount]" intercept="-(0.5 * [amount]) + 0.5"/>
-      <feFuncB type="linear" slope="[amount]" intercept="-(0.5 * [amount]) + 0.5"/>
-    </feComponentTransfer>
-  </filter>
-</svg>
-
- - - -

{{EmbedLiveSample('contrast_example','100%','203px','','', 'no-codepen')}}

- -

drop-shadow()

- -

{{cssxref("filter-function/drop-shadow", "drop-shadow()")}} 函数对输入图像应用阴影效果。阴影可以设置模糊度的,以特定颜色画出的遮罩图的偏移版本,最终合成在图像下面。 函数接受<shadow>(在CSS3背景中定义)类型的值,除了 inset 和 spread 关键字。该函数与已有的 {{cssxref("box-shadow")}} 属性很相似;不同之处在于,通过滤镜,一些浏览器为了更好的性能会提供硬件加速。<shadow> 参数如下:

- -
-
<offset-x> <offset-y> (必须)
-
这是设置阴影偏移量的两个 {{cssxref("<length>")}} 值。 <offset-x> 设定水平方向距离,负值会使阴影出现在元素左边。 <offset-y>设定垂直距离,负值会使阴影出现在元素上方。查看 {{cssxref("<length>")}} 了解可能的单位.
- 如果两个值都是 0, 则阴影出现在元素正后面 (如果设置了 <blur-radius> 且/或 <spread-radius> 也会有模糊效果).
-
<blur-radius> (可选)
-
这是第三个 {{cssxref("<length>")}} 值。值越大,越模糊,所以阴影可以变得更大或更淡。不允许负值。若未设定,默认是 0 (则阴影的边界很锐利)。
-
<color> (可选)
-
查看 {{cssxref("<color>")}} 了解该值可能的关键字和标记。若未设定,颜色值基于浏览器 —— 通常是 {{cssxref("<color>")}} 属性的值,但请注意,在这种情况下,Safari 当前会绘制透明阴影。在 Gecko (Firefox), Presto (Opera) 和 Trident (Internet Explorer) 中, 会应用 {{cssxref("<color>")}} 属性的值。另外,如果颜色值省略,WebKit 中阴影是透明的。
-
- -
filter: drop-shadow(16px 16px 10px black)
- -
<svg style="position: absolute; top: -999999px" xmlns="http://www.w3.org/2000/svg">
- <filter id="drop-shadow">
-    <feGaussianBlur in="SourceAlpha" stdDeviation="[radius]"/>
-    <feOffset dx="[offset-x]" dy="[offset-y]" result="offsetblur"/>
-    <feFlood flood-color="[color]"/>
-    <feComposite in2="offsetblur" operator="in"/>
-    <feMerge>
-      <feMergeNode/>
-      <feMergeNode in="SourceGraphic"/>
-    </feMerge>
-  </filter>
-</svg>
- -

{{EmbedLiveSample('shadow_example','100%','300px','','', 'no-codepen')}}

- -

grayscale()

- -

{{cssxref("filter-function/grayscale", "grayscale()")}}  函数将改变输入图像灰度。amount 的值定义了转换的比例。值为 100% 则完全转为灰度图像,值为 0% 图像无变化。值在 0%100% 之间,则是效果的线性乘数。若未设置值,默认是 0

- -
filter: grayscale(100%)
- - - -

{{EmbedLiveSample('grayscale_example','100%','209px','','', 'no-codepen')}}

- -

hue-rotate()

- -

{{cssxref("filter-function/hue-rotate", "hue-rotate()")}} 函数在输入图像上应用色相旋转。angle 一值设定图像会被调整的色环角度值。值为 0deg,则图像无变化。若值未设置值,默认为 0deg。该值虽然没有最大值,超过 360deg 的值相当于又绕一圈。

- -
filter: hue-rotate(90deg)
- -
<svg style="position: absolute; top: -999999px" xmlns="http://www.w3.org/2000/svg">
-  <filter id="svgHueRotate" >
-    <feColorMatrix type="hueRotate" values="[angle]" />
-  <filter />
-</svg>
- - - -

{{EmbedLiveSample('huerotate_example','100%','221px','','', 'no-codepen')}}

- -

invert()

- -

{{cssxref("filter-function/invert", "invert()")}} 函数反转输入图像。amount 的值定义转换的比例。100% 的价值是完全反转。值为 0% 则图像无变化。值在 0%100% 之间,则是效果的线性乘数。 若值未设置值,默认为 0

- -
filter: invert(100%)
- - - -

{{EmbedLiveSample('invert_example','100%','407px','','', 'no-codepen')}}

- -

opacity()

- -

{{cssxref("filter-function/opacity", "opacity()")}}  转化图像的透明程度。amount 的值定义转换的比例。值为 0% 则是完全透明,值为 100% 则图像无变化。值在 0%100% 之间,则是效果的线性乘数。也相当于图像样本乘以数量。 若值未设置,值默认是1。该函数与已有的 opacity 属性很相似,不同之处在于通过 filter,一些浏览器为了提升性能会提供硬件加速。

- -
filter: opacity(50%)
- - - -

{{EmbedLiveSample('opacity_example','100%','210px','','', 'no-codepen')}}

- -

saturate()

- -

{{cssxref("filter-function/saturate", "saturate()")}} 函数转换图像饱和度。amount 的值定义转换的比例。值为 0% 则是完全不饱和,值为 100% 则图像无变化。其他值是效果的线性乘数。超过 100% 则有更高的饱和度。 若未设置值,默认为 1

- -
filter: saturate(200%)
- - - -

{{EmbedLiveSample('saturate_example','100%','332px','','', 'no-codepen')}}

- -

sepia()

- -

 {{cssxref("filter-function/sepia", "sepia()")}} 函数将图像转换为深褐色。amount 的值定义转换的比例。值为 100% 则完全是深褐色的,值为 0% 图像无变化。值在 0%100% 之间,值是效果的线性乘数。若未设置,值默认是 0

- -
filter: sepia(100%)
- - - -

{{EmbedLiveSample('sepia_example','100%','229px','','', 'no-codepen')}}

- -

复合函数

- -

你可以组合任意数量的函数来控制渲染。下面的例子可以增强图像的对比度和亮度。

- -
filter: contrast(175%) brightness(3%)
- - - -

{{EmbedLiveSample('combination_example','100%','209px','','', 'no-codepen')}}

- -

正式定义

- -

{{cssinfo}}

- -

形式语法

- -{{csssyntax}} - -

示例

- -

应用 filter 功能

- -

下面显示了使用预定义功能的示例。有关特定示例,请参见每个功能。

- -
.mydiv { filter: grayscale(50%) }
-
-/* gray all images by 50% and blur by 10px */
-img {
-  filter: grayscale(0.5) blur(10px);
-}
- -

应用 SVG filter

- -

将 URL 函数与 SVG 资源一起使用的示例如下:

- -
.target { filter: url(#c1); }
-
-.mydiv { filter: url(commonfilters.xml#large-blur) }
-
- -

规范

- - - - - - - - - - - - - - - - -
SpecificationStatusComment
{{ SpecName('Filters 1.0', '#FilterProperty', 'filter') }}{{ Spec2('Filters 1.0') }}Initial definition.
- -

浏览器兼容性

- -

{{Compat("css.properties.filter")}}

- -

查看更多

- - diff --git a/files/zh-cn/web/css/filter/index.md b/files/zh-cn/web/css/filter/index.md new file mode 100644 index 0000000000..27fe11b599 --- /dev/null +++ b/files/zh-cn/web/css/filter/index.md @@ -0,0 +1,875 @@ +--- +title: filter +slug: Web/CSS/filter +tags: + - CSS + - SVG + - SVG Filter + - filter +translation_of: Web/CSS/filter +--- +

{{CSSRef}}

+ +

filter CSS属性将模糊或颜色偏移等图形效果应用于元素。滤镜通常用于调整图像,背景和边框的渲染。

+ +

CSS 标准里包含了一些已实现预定义效果的函数。你也可以参考一个 SVG 滤镜,通过一个 URL 链接到 SVG 滤镜元素(SVG filter element)。

+ +
{{EmbedInteractiveExample("pages/css/filter.html")}}
+ + + +

语法

+ +
/* URL to SVG filter */
+filter: url("filters.svg#filter-id");
+
+/* <filter-function> values */
+filter: blur(5px);
+filter: brightness(0.4);
+filter: contrast(200%);
+filter: drop-shadow(16px 16px 20px blue);
+filter: grayscale(50%);
+filter: hue-rotate(90deg);
+filter: invert(75%);
+filter: opacity(25%);
+filter: saturate(30%);
+filter: sepia(60%);
+
+/* Multiple filters */
+filter: contrast(175%) brightness(3%);
+
+/* Use no filter */
+filter: none;
+
+/* Global values */
+filter: inherit;
+filter: initial;
+filter: unset;
+ +

设置一种函数,方法如下:

+ +
filter: <filter-function> [<filter-function>]* | none
+
+ +

给SVG元素 {{SVGElement("filter")}} 引用滤镜, 如下:

+ +
filter: url(file.svg#filter-element-id)
+ +

插值

+ +

如果起始和结束过滤器都有一个不含 {{cssxref("<url>")}} 的相同长度的函数列表,则会根据其指定的规则对其每个过滤器函数进行插值。如果它们的长度不同,较长列表中确实的等效过滤器函数将使用空白的值添加到较短列表的尾部,然后所有的过滤器函数根据其特定的规则插值。如果一个过滤器是none则会使用过滤器函数的默认值替换函数列表,然后根据特定的规则进行插值,否则使用离散插值。

+ +

函数

+ +

使用 CSS 滤镜属性,你需要设定下面某一函数的值。如果该值无效,函数返回 none。除特殊说明外,函数的值如果接受百分比值(如 34%),那么该函数也接受小数值(如0.34)。

+ +

当单个 filter 属性具有两个或多个函数时,其结果将与将两个或多个 filter 属性分别应用于相同的函数时的结果不同

+ +

SVG filter

+ +

url()

+ +

获取指向SVG过滤器的URI,该 SVG filter 可以嵌入到外部XML文件中。

+ +
filter: url(resources.svg#c1)
+ +

Filter 函数

+ +

blur()

+ +

{{cssxref("filter-function/blur", "blur()")}} 函数将高斯模糊应用于输入图像。radius 定义了高斯函数的标准偏差值,或者屏幕上有多少像素相互融合,因此,较大的值将产生更多的模糊。若没有设置值,默认为0。该参数可以指定为 CSS 长度,但不接受百分比值。

+ +
filter: blur(5px)
+
+ +
<svg style="position: absolute; top: -99999px" xmlns="http://www.w3.org/2000/svg">
+  <filter id="svgBlur" x="-5%" y="-5%" width="110%" height="110%">
+    <feGaussianBlur in="SourceGraphic" stdDeviation="5"/>
+  </filter>
+</svg>
+ +

{{EmbedLiveSample('blur_example','100%','236px','','', 'no-codepen')}}

+ +

brightness()

+ +

{{cssxref("filter-function/brightness", "brightness()")}} 函数将线性乘法器应用于输入图像,使其看起来或多或少地变得明亮。值为 0% 将创建全黑图像。值为 100% 会使输入保持不变。其他值是效果的线性乘数。如果值大于 100% 提供更明亮的结果。若没有设置值,默认为 1

+ +
filter: brightness(2)
+ +
<svg style="position: absolute; top: -99999px" xmlns="http://www.w3.org/2000/svg">
+  <filter id="brightness">
+    <feComponentTransfer>
+      <feFuncR type="linear" slope="[amount]"/>
+      <feFuncG type="linear" slope="[amount]"/>
+      <feFuncB type="linear" slope="[amount]"/>
+    </feComponentTransfer>
+  </filter>
+</svg>
+ +

{{EmbedLiveSample('brightness_example','100%','231px','','', 'no-codepen')}}

+ +

contrast()

+ +

{{cssxref("filter-function/contrast", "contrast()")}} 函数可调整输入图像的对比度。值是 0% 的话,图像会全黑。值是 100%,图像不变。值可以超过 100%,意味着会运用更低的对比。若没有设置值,默认是 1

+ +
filter: contrast(200%)
+
+ +
<svg height="0" xmlns="http://www.w3.org/2000/svg">
+  <filter id="contrast">
+    <feComponentTransfer>
+      <feFuncR type="linear" slope="[amount]" intercept="-(0.5 * [amount]) + 0.5"/>
+      <feFuncG type="linear" slope="[amount]" intercept="-(0.5 * [amount]) + 0.5"/>
+      <feFuncB type="linear" slope="[amount]" intercept="-(0.5 * [amount]) + 0.5"/>
+    </feComponentTransfer>
+  </filter>
+</svg>
+
+ + + +

{{EmbedLiveSample('contrast_example','100%','203px','','', 'no-codepen')}}

+ +

drop-shadow()

+ +

{{cssxref("filter-function/drop-shadow", "drop-shadow()")}} 函数对输入图像应用阴影效果。阴影可以设置模糊度的,以特定颜色画出的遮罩图的偏移版本,最终合成在图像下面。 函数接受<shadow>(在CSS3背景中定义)类型的值,除了 inset 和 spread 关键字。该函数与已有的 {{cssxref("box-shadow")}} 属性很相似;不同之处在于,通过滤镜,一些浏览器为了更好的性能会提供硬件加速。<shadow> 参数如下:

+ +
+
<offset-x> <offset-y> (必须)
+
这是设置阴影偏移量的两个 {{cssxref("<length>")}} 值。 <offset-x> 设定水平方向距离,负值会使阴影出现在元素左边。 <offset-y>设定垂直距离,负值会使阴影出现在元素上方。查看 {{cssxref("<length>")}} 了解可能的单位.
+ 如果两个值都是 0, 则阴影出现在元素正后面 (如果设置了 <blur-radius> 且/或 <spread-radius> 也会有模糊效果).
+
<blur-radius> (可选)
+
这是第三个 {{cssxref("<length>")}} 值。值越大,越模糊,所以阴影可以变得更大或更淡。不允许负值。若未设定,默认是 0 (则阴影的边界很锐利)。
+
<color> (可选)
+
查看 {{cssxref("<color>")}} 了解该值可能的关键字和标记。若未设定,颜色值基于浏览器 —— 通常是 {{cssxref("<color>")}} 属性的值,但请注意,在这种情况下,Safari 当前会绘制透明阴影。在 Gecko (Firefox), Presto (Opera) 和 Trident (Internet Explorer) 中, 会应用 {{cssxref("<color>")}} 属性的值。另外,如果颜色值省略,WebKit 中阴影是透明的。
+
+ +
filter: drop-shadow(16px 16px 10px black)
+ +
<svg style="position: absolute; top: -999999px" xmlns="http://www.w3.org/2000/svg">
+ <filter id="drop-shadow">
+    <feGaussianBlur in="SourceAlpha" stdDeviation="[radius]"/>
+    <feOffset dx="[offset-x]" dy="[offset-y]" result="offsetblur"/>
+    <feFlood flood-color="[color]"/>
+    <feComposite in2="offsetblur" operator="in"/>
+    <feMerge>
+      <feMergeNode/>
+      <feMergeNode in="SourceGraphic"/>
+    </feMerge>
+  </filter>
+</svg>
+ +

{{EmbedLiveSample('shadow_example','100%','300px','','', 'no-codepen')}}

+ +

grayscale()

+ +

{{cssxref("filter-function/grayscale", "grayscale()")}}  函数将改变输入图像灰度。amount 的值定义了转换的比例。值为 100% 则完全转为灰度图像,值为 0% 图像无变化。值在 0%100% 之间,则是效果的线性乘数。若未设置值,默认是 0

+ +
filter: grayscale(100%)
+ + + +

{{EmbedLiveSample('grayscale_example','100%','209px','','', 'no-codepen')}}

+ +

hue-rotate()

+ +

{{cssxref("filter-function/hue-rotate", "hue-rotate()")}} 函数在输入图像上应用色相旋转。angle 一值设定图像会被调整的色环角度值。值为 0deg,则图像无变化。若值未设置值,默认为 0deg。该值虽然没有最大值,超过 360deg 的值相当于又绕一圈。

+ +
filter: hue-rotate(90deg)
+ +
<svg style="position: absolute; top: -999999px" xmlns="http://www.w3.org/2000/svg">
+  <filter id="svgHueRotate" >
+    <feColorMatrix type="hueRotate" values="[angle]" />
+  <filter />
+</svg>
+ + + +

{{EmbedLiveSample('huerotate_example','100%','221px','','', 'no-codepen')}}

+ +

invert()

+ +

{{cssxref("filter-function/invert", "invert()")}} 函数反转输入图像。amount 的值定义转换的比例。100% 的价值是完全反转。值为 0% 则图像无变化。值在 0%100% 之间,则是效果的线性乘数。 若值未设置值,默认为 0

+ +
filter: invert(100%)
+ + + +

{{EmbedLiveSample('invert_example','100%','407px','','', 'no-codepen')}}

+ +

opacity()

+ +

{{cssxref("filter-function/opacity", "opacity()")}}  转化图像的透明程度。amount 的值定义转换的比例。值为 0% 则是完全透明,值为 100% 则图像无变化。值在 0%100% 之间,则是效果的线性乘数。也相当于图像样本乘以数量。 若值未设置,值默认是1。该函数与已有的 opacity 属性很相似,不同之处在于通过 filter,一些浏览器为了提升性能会提供硬件加速。

+ +
filter: opacity(50%)
+ + + +

{{EmbedLiveSample('opacity_example','100%','210px','','', 'no-codepen')}}

+ +

saturate()

+ +

{{cssxref("filter-function/saturate", "saturate()")}} 函数转换图像饱和度。amount 的值定义转换的比例。值为 0% 则是完全不饱和,值为 100% 则图像无变化。其他值是效果的线性乘数。超过 100% 则有更高的饱和度。 若未设置值,默认为 1

+ +
filter: saturate(200%)
+ + + +

{{EmbedLiveSample('saturate_example','100%','332px','','', 'no-codepen')}}

+ +

sepia()

+ +

 {{cssxref("filter-function/sepia", "sepia()")}} 函数将图像转换为深褐色。amount 的值定义转换的比例。值为 100% 则完全是深褐色的,值为 0% 图像无变化。值在 0%100% 之间,值是效果的线性乘数。若未设置,值默认是 0

+ +
filter: sepia(100%)
+ + + +

{{EmbedLiveSample('sepia_example','100%','229px','','', 'no-codepen')}}

+ +

复合函数

+ +

你可以组合任意数量的函数来控制渲染。下面的例子可以增强图像的对比度和亮度。

+ +
filter: contrast(175%) brightness(3%)
+ + + +

{{EmbedLiveSample('combination_example','100%','209px','','', 'no-codepen')}}

+ +

正式定义

+ +

{{cssinfo}}

+ +

形式语法

+ +{{csssyntax}} + +

示例

+ +

应用 filter 功能

+ +

下面显示了使用预定义功能的示例。有关特定示例,请参见每个功能。

+ +
.mydiv { filter: grayscale(50%) }
+
+/* gray all images by 50% and blur by 10px */
+img {
+  filter: grayscale(0.5) blur(10px);
+}
+ +

应用 SVG filter

+ +

将 URL 函数与 SVG 资源一起使用的示例如下:

+ +
.target { filter: url(#c1); }
+
+.mydiv { filter: url(commonfilters.xml#large-blur) }
+
+ +

规范

+ + + + + + + + + + + + + + + + +
SpecificationStatusComment
{{ SpecName('Filters 1.0', '#FilterProperty', 'filter') }}{{ Spec2('Filters 1.0') }}Initial definition.
+ +

浏览器兼容性

+ +

{{Compat("css.properties.filter")}}

+ +

查看更多

+ + -- cgit v1.2.3-54-g00ecf