Skip to content
This repository was archived by the owner on Jul 17, 2020. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# Logs
logs
*.log
npm-debug.log*

# Runtime data
pids
*.pid
*.seed

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# nyc test coverage
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# node-waf configuration
.lock-wscript

# Compiled binary addons (http://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules
jspm_packages

# Optional npm cache directory
.npm

# Optional REPL history
.node_repl_history
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,5 @@ npm run dev
## QQ群

<a target="_blank" href="http://shang.qq.com/wpa/qunwpa?idkey=c735b2b5e7d83d2043584e78d1c9d0475f6064e82701ec01ed28e7aa163946ea"><img border="0" src="http://pub.idqqimg.com/wpa/images/group.png" alt="vue.js" title="vue.js"></a>

## Mask更新
8 changes: 5 additions & 3 deletions example/modules/DialogView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
<a href="javascript:;" class="weui_btn weui_btn_primary" v-on:click="showAlert=true;">点击弹出Dialog Alert</a>
<a href="javascript:;" class="weui_btn weui_btn_primary" v-on:click="showConfirm=true;">点击弹出Dialog Confirm</a>
</div>

<mask :is-show.sync="showAlert"></mask>
<mask :is-show.sync="showConfirm"></mask>
<Dialog :show.sync="showAlert"></Dialog>

<Dialog :show.sync="showConfirm" type="confirm" title="弹窗标题">
Expand All @@ -23,12 +24,13 @@
<script>

import Dialog from './../../src/Dialog.vue'
import Mask from './../../src/Mask.vue'

export default {
name: 'DialogView',
components: {
Dialog
// Button
Dialog,
Mask
},
data() {
return {
Expand Down
4 changes: 0 additions & 4 deletions example/modules/IndexView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,3 @@ export default {
}
}
</script>

<style lang="stylus">

</style>
3 changes: 1 addition & 2 deletions src/Dialog.vue
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<template>

<div :class="'weui_dialog_' + type" v-show="show">
<div class="weui_mask"></div>

<div class="weui_dialog">
<div class="weui_dialog_hd">
<strong class="weui_dialog_title">{{title}}</strong>
Expand All @@ -25,7 +25,6 @@
</template>

<script>

export default {
name: 'Dialog',
props: {
Expand Down
3 changes: 1 addition & 2 deletions src/Mask.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<div class="weui_mask_transition" :class="{weui_fade_toggle:isShow}" id="mask" v-show="isShow" v-on:click="close()"></div>
<div class="weui_mask_transition" transition="maskts" :class="{weui_fade_toggle:isShow}" id="mask" v-show="isShow" v-on:click="close()"></div>
</template>

<script>
Expand All @@ -23,5 +23,4 @@ export default {
<style lang="less">

@import "./style/widget/weui_tips/weui_mask";

</style>
9 changes: 7 additions & 2 deletions src/style/widget/weui_tips/weui_mask.less
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
}

.weui_mask_transition{
display: none;
position: fixed;
z-index: 1;
width: 100%;
Expand All @@ -32,4 +31,10 @@
}
.weui_fade_toggle{
background: rgba(0,0,0,.6);
}
}
.maskts{
background: rgba(0, 0, 0, .5);
}
.maskts-leave, .maskts-enter{
background: rgba(0, 0, 0, .0);
}