diff options
Diffstat (limited to 'files/zh-cn/web/api')
-rw-r--r-- | files/zh-cn/web/api/resizeobserverentry/index.html | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/files/zh-cn/web/api/resizeobserverentry/index.html b/files/zh-cn/web/api/resizeobserverentry/index.html index e3aa5fede9..f5ab911eb8 100644 --- a/files/zh-cn/web/api/resizeobserverentry/index.html +++ b/files/zh-cn/web/api/resizeobserverentry/index.html @@ -29,7 +29,7 @@ translation_of: Web/API/ResizeObserverEntry <p>以下示例通过观察box的宽度变化从而改变其边框圆角半径。</p> -<pre class="brush: js">const resizeOserver = new ResizeObserver(entries => { +<pre class="brush: js">const resizeObserver = new ResizeObserver(entries => { for (let entry of entries) { entry.target.style.borderRadius = Math.max(0, 250 - entry.contentRect.width) + 'px'; } |