Skip to content

Commit

Permalink
nico rebuild for modify README
Browse files Browse the repository at this point in the history
  • Loading branch information
afc163 committed Oct 18, 2012
1 parent 65aee33 commit 1529343
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
5 changes: 2 additions & 3 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ <h2>演示</h2>
<ul>
<li><a href="./examples/">各类定位演示</a></li>
</ul><h2 id="toc_0">定位原理</h2>
<p>这个组件的定位原理是,通过两个对象分别描述定位元素及其定位点,然后将其定位点重合。</p>
<p><code>Position</code> 组件的定位原理是,通过两个对象分别描述定位元素及其定位点,然后将其定位点重合。</p>
<p>比如有目标元素 a 和基准元素 b ,先设定 a 的定位点为左上角,b 的定位点为中央。则分别描述为 { element: a, x: 0, y: 0 } 和 { element: b, x: &#39;50%&#39;, y: &#39;50%&#39; },然后将 a 的左上角定位到 b 的中央,就完成了定位。</p>

<h2 id="toc_1">使用说明</h2>
Expand Down Expand Up @@ -124,8 +124,7 @@ <h2 id="toc_5">最佳实践</h2>
<h2 id="toc_6">注意事项</h2>

<ul>
<li>IE8 下,当文档流中定位元素在基准元素的相邻前方时,基准元素有可能会因为未 reflow
而导致 margin-top 失效,所以要尽量避免定位元素与基准元素相邻并在其之前。</li>
<li>IE8 下,当文档流中定位元素在基准元素的相邻前方时,基准元素有可能会因为未 reflow 而导致 margin-top 失效,所以要尽量避免定位元素与基准元素相邻并在其之前。</li>
</ul>


Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"tag": "utility",
"homepage": "http://aralejs.org/position/",
"description": "简单实用的定位工具,将一个 DOM 节点相对于另一个 DOM 节点进行定位操作。",
"author": "pianyou <xingmin.zhu@alipay.com>",
"author": "偏右 <xingmin.zhu@alipay.com>",
"repository": {
"type": "git",
"url": "https://github.com/aralejs/position.git"
Expand Down

0 comments on commit 1529343

Please sign in to comment.