mirror of
https://gitee.com/ElemeFE/element.git
synced 2024-12-01 11:47:41 +08:00
Merge pull request #405 from Leopoldthecoder/master
add lock modifier on loading
This commit is contained in:
commit
576c21afea
@ -1,5 +1,13 @@
|
||||
## 更新日志
|
||||
|
||||
### 1.0.0-rc.8(待发布)
|
||||
|
||||
*2016-XX-XX*
|
||||
|
||||
#### 非兼容性更新
|
||||
|
||||
- 全屏 Loading 现在默认不再锁定屏幕滚动。如果需要的话,可添加 `lock` 修饰符
|
||||
|
||||
### 1.0.0-rc.7
|
||||
|
||||
*2016-10-13*
|
||||
|
@ -57,14 +57,14 @@
|
||||
|
||||
页面数据加载时显示。
|
||||
|
||||
:::demo 当需要全屏遮罩时,可使用`fullscreen`修饰符(此时遮罩会插入至 body 上)
|
||||
:::demo 当需要全屏遮罩时,可使用`fullscreen`修饰符(此时遮罩会插入至 body 上)。此时若需要锁定屏幕的滚动,可以使用`lock`修饰符。
|
||||
|
||||
```html
|
||||
<template>
|
||||
<el-button
|
||||
type="primary"
|
||||
@click.native="openFullScreen"
|
||||
v-loading.fullscreen="fullscreenLoading">
|
||||
v-loading.fullscreen.lock="fullscreenLoading">
|
||||
显示整页加载,3 秒后消失
|
||||
</el-button>
|
||||
</template>
|
||||
|
@ -68,7 +68,7 @@ exports.install = Vue => {
|
||||
if (directive.originalPosition !== 'absolute') {
|
||||
parent.style.position = 'relative';
|
||||
}
|
||||
if (binding.modifiers.fullscreen) {
|
||||
if (binding.modifiers.fullscreen && binding.modifiers.lock) {
|
||||
parent.style.overflow = 'hidden';
|
||||
}
|
||||
directive.mask.style.display = 'block';
|
||||
|
Loading…
Reference in New Issue
Block a user