Merge pull request #507 from ReedSun/bug-fix-wxc-result-ducument
[!] wxc-result: fix error document link
diff --git a/CHANGELOG.md b/CHANGELOG.md
index b82d7fd..b383bdc 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,11 @@
# Change Log
+## 0.8.5
+- [!] wxc-dialog: 文档上补充上 `show` 参数
+- [!] wxc-mask: 修正了单击“关闭”按钮和单击“覆盖”之间不一致行为的错误
+- [+] wxc-pan-item: 使用元素前添加判断
+
+
## 0.8.4
- [+] [wxc-lightbox](https://apache.github.io/incubator-weex-ui/#/cn/packages/wxc-lightbox/) add `show-indicator` param to show indicator
@@ -8,7 +14,7 @@
- [+] [wxc-loading](https://apache.github.io/incubator-weex-ui/#/packages/wxc-slider-bar/) add `block-color` param.
## 0.8.0
-- [!]From alibaba/weex-ui to [apcahe/incubator-weex-ui](https://github.com/apache/incubator-weex-ui)
+- [!]From alibaba/weex-ui to [apcahe/incubator-weex-ui](https://github.com/apache/incubator-weex-ui)
## 0.7.1
- [+] [wxc-slider-bar](https://apache.github.io/incubator-weex-ui/#/packages/wxc-slider-bar/) add `wxcSliderBarTouchEnd` event.
diff --git a/CHANGELOG_cn.md b/CHANGELOG_cn.md
index 948cd34..bbe0b6e 100644
--- a/CHANGELOG_cn.md
+++ b/CHANGELOG_cn.md
@@ -1,5 +1,10 @@
# 升级日志
+## 0.8.5
+- [!] wxc-dialog: supplement missing parameters ` show` in document
+- [!] wxc-mask: fix bug that inconsistent behavior between clicking close button and clicking overlay
+- [+] wxc-pan-item: add judgment before using element
+
## 0.8.4
- [+] [wxc-lightbox](https://apache.github.io/incubator-weex-ui/#/cn/packages/wxc-lightbox/) 增加 `show-indicator` 参数控制是否显示indicator
@@ -8,7 +13,7 @@
- [+] [wxc-loading](https://apache.github.io/incubator-weex-ui/#/cn/packages/wxc-slider-bar/) 增加 `block-color` 参数用于覆盖原有滑块颜色.
## 0.8.0
-- [!]从 alibaba/weex-ui 迁移到 [apcahe/incubator-weex-ui](https://github.com/apache/incubator-weex-ui)
+- [!]从 alibaba/weex-ui 迁移到 [apcahe/incubator-weex-ui](https://github.com/apache/incubator-weex-ui)
## 0.7.1
diff --git a/package.json b/package.json
index 78bf5cc..02585d7 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "weex-ui",
- "version": "0.8.4",
+ "version": "0.8.5",
"description": "A rich interaction, lightweight, high performance UI library based on Weex",
"main": "index.js",
"lib": "vue",
diff --git a/packages/wxc-dialog/README.md b/packages/wxc-dialog/README.md
index 21a5b13..980fcae 100644
--- a/packages/wxc-dialog/README.md
+++ b/packages/wxc-dialog/README.md
@@ -72,6 +72,7 @@
| Prop | Type | Required | Default | Description |
|-------------|------------|--------|-----|-----|
+| show | `Boolean` | `N` | `false` | Whether the dialog is show or not |
| title | `String` | `Y` | `-` | title (only transparent) |
| content | `String` | `N` | `-`| content |
| left | `Number` |`N`| `0` | move left distance |
diff --git a/packages/wxc-dialog/README_cn.md b/packages/wxc-dialog/README_cn.md
index 570528a..ee59555 100644
--- a/packages/wxc-dialog/README_cn.md
+++ b/packages/wxc-dialog/README_cn.md
@@ -72,6 +72,7 @@
| Prop | Type | Required | Default | Description |
|-------------|------------|--------|-----|-----|
+| show | `Boolean` | `N` | `false` | 对话框是否可见 |
| title | `String` | `Y` | `-` | 标题 |
| left | `Number` |`N`| `0` | 向左移动距离 |
| content | `String` | `N` | `-`| 内容说明描述 |
diff --git a/packages/wxc-mask/index.vue b/packages/wxc-mask/index.vue
index a6b9cb0..6a1a545 100644
--- a/packages/wxc-mask/index.vue
+++ b/packages/wxc-mask/index.vue
@@ -22,7 +22,8 @@
<template>
<div class="container">
- <wxc-overlay :show="show && hasOverlay"
+ <wxc-overlay ref="overlay"
+ :show="show && hasOverlay"
v-if="show"
v-bind="mergeOverlayCfg"
:can-auto-close="overlayCanClose"
@@ -191,7 +192,10 @@
},
methods: {
closeIconClicked () {
- this.appearMask(false);
+ this.$refs.overlay.appearOverlay(false);
+ if (!this.overlayCanClose) {
+ this.appearMask(false);
+ }
},
wxcOverlayBodyClicking () {
if (this.hasAnimation) {
diff --git a/packages/wxc-pan-item/index.vue b/packages/wxc-pan-item/index.vue
index d301c0d..a24e425 100644
--- a/packages/wxc-pan-item/index.vue
+++ b/packages/wxc-pan-item/index.vue
@@ -63,10 +63,12 @@
setTimeout(() => {
if (this.supportAndroid && this.needSlider) {
const element = this.$refs['wxc-pan-item'];
- Binding.prepare && Binding.prepare({
- anchor: element.ref,
- eventType: 'pan'
- });
+ if (element) {
+ Binding.prepare && Binding.prepare({
+ anchor: element.ref,
+ eventType: 'pan'
+ });
+ }
}
}, 300)
},