diff options
author | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:40:17 -0500 |
---|---|---|
committer | Peter Bengtsson <mail@peterbe.com> | 2020-12-08 14:40:17 -0500 |
commit | 33058f2b292b3a581333bdfb21b8f671898c5060 (patch) | |
tree | 51c3e392513ec574331b2d3f85c394445ea803c6 /files/zh-cn/web/css/initial_value | |
parent | 8b66d724f7caf0157093fb09cfec8fbd0c6ad50a (diff) | |
download | translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.gz translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.tar.bz2 translated-content-33058f2b292b3a581333bdfb21b8f671898c5060.zip |
initial commit
Diffstat (limited to 'files/zh-cn/web/css/initial_value')
-rw-r--r-- | files/zh-cn/web/css/initial_value/index.html | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/files/zh-cn/web/css/initial_value/index.html b/files/zh-cn/web/css/initial_value/index.html new file mode 100644 index 0000000000..7b74d8ccc3 --- /dev/null +++ b/files/zh-cn/web/css/initial_value/index.html @@ -0,0 +1,51 @@ +--- +title: 初始值 +slug: Web/CSS/initial_value +tags: + - CSS + - Reference +translation_of: Web/CSS/initial_value +--- +<div>{{cssref}}</div> + +<p><a href="/zh-CN/docs/Web/CSS">CSS</a>属性的<strong>初始值</strong>是其默认值,如其定义表中所列。 初始值的使用取决于属性是否被继承:</p> + +<ul> + <li>对于<a href="/en-US/docs/CSS/inheritance#Inherited_properties" title="en/CSS/inheritance#Inherited_properties">继承属性</a>,初始值只能被用于没有指定值的<strong>根元素</strong>上。</li> + <li>对于<a href="/en-US/docs/CSS/inheritance#Non-inherited_properties" title="en/CSS/inheritance#Non-inherited_properties">非继承属性</a>,初始值可以被用于<strong>任意</strong>没有指定值的元素上。</li> +</ul> + +<div class="note"> +<p><strong>注意:</strong>你可以使用 <code><a href="/en-US/docs/CSS/initial" title="en/CSS/initial">initial</a></code> 关键词明确指定初始值。</p> +</div> + +<h2 id="规范">规范</h2> + +<table class="standard-table"> + <thead> + <tr> + <th scope="col">Specification</th> + <th scope="col">Status</th> + <th scope="col">Comment</th> + </tr> + </thead> + <tbody> + <tr> + <td><a href="https://drafts.csswg.org/css-cascade-4/#initial-values">CSS Cascade 4</a></td> + <td></td> + <td>Formal definition.</td> + </tr> + <tr> + <td>{{SpecName("CSS2.1", "cascade.html#specified-value", "initial value")}}</td> + <td>{{Spec2("CSS2.1")}}</td> + <td>Implicit definition.</td> + </tr> + </tbody> +</table> + +<h2 id="参见">参见</h2> + +<ul> + <li>{{cssxref("initial")}}</li> + <li>{{CSS_key_concepts}}</li> +</ul> |