diff options
author | Peter Bengtsson <mail@peterbe.com> | 2021-07-16 16:27:00 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-17 04:27:00 +0800 |
commit | b9afb23d12dcae1e09f8d04c72143c5ddaa34aea (patch) | |
tree | f6c20844119bcaf0131ad4a037e0245577927f2c /files/zh-cn/conflicting/web/api/node/getrootnode | |
parent | 1aa671566c3a990ec2df9a46137471d624b6f7ff (diff) | |
download | translated-content-b9afb23d12dcae1e09f8d04c72143c5ddaa34aea.tar.gz translated-content-b9afb23d12dcae1e09f8d04c72143c5ddaa34aea.tar.bz2 translated-content-b9afb23d12dcae1e09f8d04c72143c5ddaa34aea.zip |
delete conflicting/orphaned docs (zh-CN) (#1412)
* delete conflicting docs (zh-CN)
* and redirects
* do orphaned as well
* fix
* remove more orphans
* revert orphaned docs that can identify origin
* move orphaned docs to current loc
* adjust slug path
* fix redirect change from rebase
Co-authored-by: Irvin <irvinfly@gmail.com>
Diffstat (limited to 'files/zh-cn/conflicting/web/api/node/getrootnode')
-rw-r--r-- | files/zh-cn/conflicting/web/api/node/getrootnode/index.html | 116 |
1 files changed, 0 insertions, 116 deletions
diff --git a/files/zh-cn/conflicting/web/api/node/getrootnode/index.html b/files/zh-cn/conflicting/web/api/node/getrootnode/index.html deleted file mode 100644 index ea5deb0b98..0000000000 --- a/files/zh-cn/conflicting/web/api/node/getrootnode/index.html +++ /dev/null @@ -1,116 +0,0 @@ ---- -title: Node.rootNode -slug: conflicting/Web/API/Node/getRootNode -tags: - - API - - DOM - - Node - - Property - - Reference - - rootNode -translation_of: Web/API/Node/getRootNode -translation_of_original: Web/API/Node/rootNode -original_slug: Web/API/Node/rootNode ---- -<p>{{deprecated_header}}{{APIRef("DOM")}}{{SeeCompatTable}}</p> - -<p><code><strong>Node.rootNode</strong></code> 是 {{domxref("Node")}} 的一个只读属性, 返回该节点所在 DOM 数的根节点(最高节点). 此属性是通过 {{domxref("Node.parentNode")}} 属性循环查找直到找到根节点.</p> - -<div class="warning"> -<p><strong>注意</strong>: 由于某种原因, 此属性已经被 {{domxref("Node.getRootNode()")}} 方法替代.</p> -</div> - -<h2 id="Syntax" name="Syntax">语法</h2> - -<pre><var>rootNode</var> = <em>node</em>.rootNode; -</pre> - -<h3 id="返回值"> 返回值</h3> - -<p>返回 {{domxref("Node")}} 对象.</p> - -<h2 id="Example" name="Example">样例</h2> - -<p>下面是输出<code>body</code>的根节点样例:</p> - -<pre class="brush: js">console.log(document.body.rootNode);</pre> - -<h2 id="Notes" name="Notes">参考</h2> - -<p></p><p>Gecko内核的浏览器会在源代码中标签内部有空白符的地方插入一个文本结点到文档中.因此,使用诸如 - <a href="/zh-CN/docs/Web/API/Node/firstChild" title="Node.firstChild 只读属性返回树中节点的第一个子节点,如果节点是无子节点,则返回 null。"><code>Node.firstChild</code></a> 和 <a href="/zh-CN/docs/Web/API/Node/previousSibling" title="返回当前节点的前一个兄弟节点,没有则返回null."><code>Node.previousSibling</code></a> 之类的方法可能会引用到一个空白符文本节点, - 而不是使用者所预期得到的节点.</p> - - <p>详情请参见 <a class="new" href="/zh-CN/docs/Whitespace_in_the_DOM" rel="nofollow">DOM 中的空白符</a> - 和<a class="external" href="http://www.w3.org/DOM/faq.html#emptytext" rel="noopener">W3C DOM 3 FAQ: 为什么一些文本节点是空的</a>.</p><p></p> - -<h2 id="浏览器兼容性">浏览器兼容性</h2> - -<p>{{CompatibilityTable}}</p> - -<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</th> - </tr> - <tr> - <td>Basic support</td> - <td>{{CompatNo}}<sup>[1]</sup></td> - <td>{{CompatNo}}<sup>[1]</sup></td> - <td>{{CompatUnknown}}</td> - <td>{{CompatNo}}</td> - <td>{{CompatUnknown}}</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 Mobile</th> - <th>Opera Mobile</th> - <th>Safari Mobile</th> - </tr> - <tr> - <td>Basic support</td> - <td>{{CompatUnknown}}</td> - <td>{{CompatNo}}<sup>[1]</sup></td> - <td>{{CompatUnknown}}</td> - <td>{{CompatNo}}<sup>[1]</sup></td> - <td>{{CompatUnknown}}</td> - </tr> - </tbody> -</table> -</div> - -<p>[1] 此属性已经废弃, 使用{{domxref("Node.getRootNode()")}} 方法替代.</p> - -<h2 id="规范">规范</h2> - -<table class="standard-table"> - <thead> - <tr> - <th scope="col">规范</th> - <th scope="col">样式</th> - <th scope="col">备注</th> - </tr> - </thead> - <tbody> - <tr> - <td>{{SpecName('DOM WHATWG', '#dom-node-rootnode', 'Node.rootNode')}}</td> - <td>{{Spec2('DOM WHATWG')}}</td> - <td>初始定义</td> - </tr> - </tbody> -</table> |