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/html/element/i | |
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/html/element/i')
-rw-r--r-- | files/zh-cn/web/html/element/i/index.html | 127 |
1 files changed, 127 insertions, 0 deletions
diff --git a/files/zh-cn/web/html/element/i/index.html b/files/zh-cn/web/html/element/i/index.html new file mode 100644 index 0000000000..f2f858af56 --- /dev/null +++ b/files/zh-cn/web/html/element/i/index.html @@ -0,0 +1,127 @@ +--- +title: <i> +slug: Web/HTML/Element/i +translation_of: Web/HTML/Element/i +--- +<h2 id="概述">概述</h2> + +<p><strong>HTML元素 <code><i></code></strong> 用于表现因某些原因需要区分普通文本的一系列文本。例如技术术语、外文短语或是小说中人物的思想活动等,它的内容通常以斜体显示。</p> + +<ul class="htmlelt"> + <li><dfn><a href="/en-US/docs/Web/HTML/Content_categories">Content catergories</a></dfn> <a href="/en-US/docs/Web/HTML/Content_categories#Flow_content">Flow content</a>, <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Content_categories#Phrasing_content">phrasing content</a>, palpable content.</li> + <li><dfn>允许量</dfn> <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Content_categories#Phrasing_content">phrasing content</a>.</li> + <li><dfn>标签忽略</dfn> {{no_tag_omission}}</li> + <li><dfn>Permitted parent elements</dfn> Any element that accepts <a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Content_categories#Phrasing_content">phrasing content</a>.</li> + <li><dfn>DOM interface</dfn> {{domxref("HTMLElement")}} Up to Gecko 1.9.2 (Firefox 4) inclusive, Firefox implements the {{domxref("HTMLSpanElement")}} interface for this element.</li> +</ul> + +<h2 id="属性">属性</h2> + +<p>该元素只包含 <a href="/en-US/docs/Web/HTML/Global_attributes">全局属性</a>。</p> + +<h2 id="示例">示例</h2> + +<pre class="brush: html"><p>The Latin phrase <i class="latin">Veni, vidi, vici</i> is often +mentioned in music, art, and literature</p> +</pre> + +<h3 id="Result" name="Result">效果</h3> + +<p>The Latin phrase <em>Veni, vidi, vici</em> is often mentioned in music, art, and literature</p> + +<h2 id="注释">注释</h2> + +<p>在较早版本的 HTML 技术参数声明中,<code><i></code> 标签只是一个用于将文本显示为斜体的表示性元素,很像 {{HTMLElement("b")}} 标签被用来将文本显示为粗体。情况不再是这样了,因为这些标签现在定义了更多的语义而不只是排版外观。<code><i></code> 标签应表现一系列带有不同语义的文本,它的典型样式显示为斜体。这意味着浏览器通常任会将内容显示为斜体,但是,根据定义,不再是必须的。</p> + +<p>该元素只在没有更适合的语义元素表示时使用。例如:</p> + +<ul> + <li>使用 {{HTMLElement("em")}} 表示强调或重读。</li> + <li>使用 {{HTMLElement("strong")}} 表示重要性。</li> + <li>使用 {{HTMLElement("mark")}} 表示相关性。</li> + <li>使用 {{HTMLElement("cite")}} 标记著作名,如一本书、剧本或是一首歌。</li> + <li>使用 {{HTMLElement("dfn")}} 标记术语的定义实例。</li> +</ul> + +<p>使用<strong>class</strong>属性用来识别为何使用该元素是一个很好的办法,这样的话,如果该表示以后需要改变,就可以有选择性地改变样式表。</p> + +<h2 id="Specifications" name="Specifications">技术参数</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>{{SpecName('HTML WHATWG', 'text-level-semantics.html#the-i-element', '<i>')}}</td> + <td>{{Spec2('HTML WHATWG')}}</td> + <td> </td> + </tr> + <tr> + <td>{{SpecName('HTML5 W3C', 'text-level-semantics.html#the-i-element', '<i>')}}</td> + <td>{{Spec2('HTML5 W3C')}}</td> + <td> </td> + </tr> + <tr> + <td>{{SpecName('HTML4.01', 'present/graphics.html#h-15.2.1', '<b>')}}</td> + <td>{{Spec2('HTML4.01')}}</td> + <td> </td> + </tr> + </tbody> +</table> + +<h2 id="Browser_compatibility" name="Browser_compatibility">浏览器兼容性</h2> + +<div>{{CompatibilityTable}}</div> + +<div id="compat-desktop"> +<table class="compat-table"> + <tbody> + <tr> + <th>Feature</th> + <th>Chrome</th> + <th>Firefox (Gecko)</th> + <th>Internet Explorer</th> + <th>Opera</th> + <th>Safari (WebKit)</th> + </tr> + <tr> + <td>Basic support</td> + <td>1.0</td> + <td>{{CompatVersionUnknown}}</td> + <td>{{CompatVersionUnknown}}</td> + <td>{{CompatVersionUnknown}}</td> + <td>{{CompatVersionUnknown}}</td> + </tr> + </tbody> +</table> +</div> + +<div id="compat-mobile"> +<table class="compat-table"> + <tbody> + <tr> + <th>Feature</th> + <th>Android</th> + <th>Firefox Mobile (Gecko)</th> + <th>IE Phone</th> + <th>Opera Mobile</th> + <th>Safari Mobile</th> + </tr> + <tr> + <td>Basic support</td> + <td>{{CompatVersionUnknown}}</td> + <td>{{CompatVersionUnknown}}</td> + <td>{{CompatVersionUnknown}}</td> + <td>{{CompatVersionUnknown}}</td> + <td>{{CompatVersionUnknown}}</td> + </tr> + </tbody> +</table> +</div> + +<p>{{HTMLRef}}</p> |