fixed #1101
This commit is contained in:
parent
f1f0206c70
commit
b8adf5cf2d
5 changed files with 20281 additions and 33 deletions
|
@ -27,7 +27,7 @@ module.exports = merge(webpackBaseConfig, {
|
||||||
resolve: {
|
resolve: {
|
||||||
alias: {
|
alias: {
|
||||||
iview: '../../src/index',
|
iview: '../../src/index',
|
||||||
// vue: 'vue/dist/vue.js'
|
// vue: 'vue/dist/vue.esm.js'
|
||||||
vue: 'vue/dist/vue.runtime.js'
|
vue: 'vue/dist/vue.runtime.js'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -1,32 +1,12 @@
|
||||||
<template>
|
<template>
|
||||||
<div style="margin: 100px;">
|
<div>
|
||||||
<Poptip
|
<Poptip trigger="focus" title="提示标题" content="提示内容">
|
||||||
confirm
|
<i-input placeholder="输入框的 focus"></i-input>
|
||||||
title="您确认删除这条内容吗?"
|
|
||||||
@on-ok="ok"
|
|
||||||
@on-cancel="cancel">
|
|
||||||
<Button>删除</Button>
|
|
||||||
</Poptip>
|
|
||||||
<Poptip
|
|
||||||
confirm
|
|
||||||
title="Are you sure delete this task?"
|
|
||||||
@on-ok="ok"
|
|
||||||
@on-cancel="cancel"
|
|
||||||
ok-text="yes"
|
|
||||||
cancel-text="no">
|
|
||||||
<Button>国际化</Button>
|
|
||||||
</Poptip>
|
</Poptip>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
methods: {
|
|
||||||
ok () {
|
|
||||||
this.$Message.info('点击了确定');
|
|
||||||
},
|
|
||||||
cancel () {
|
|
||||||
this.$Message.info('点击了取消');
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
20266
package-lock.json
generated
Normal file
20266
package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load diff
|
@ -88,13 +88,13 @@
|
||||||
"sinon-chai": "^2.8.0",
|
"sinon-chai": "^2.8.0",
|
||||||
"style-loader": "^0.13.1",
|
"style-loader": "^0.13.1",
|
||||||
"url-loader": "^0.5.7",
|
"url-loader": "^0.5.7",
|
||||||
"vue": "^2.2.1",
|
"vue": "^2.3.3",
|
||||||
"vue-hot-reload-api": "^1.3.3",
|
"vue-hot-reload-api": "^1.3.3",
|
||||||
"vue-html-loader": "^1.2.3",
|
"vue-html-loader": "^1.2.3",
|
||||||
"vue-loader": "^11.0.0",
|
"vue-loader": "^11.0.0",
|
||||||
"vue-router": "^2.2.1",
|
"vue-router": "^2.2.1",
|
||||||
"vue-style-loader": "^1.0.0",
|
"vue-style-loader": "^1.0.0",
|
||||||
"vue-template-compiler": "^2.2.1",
|
"vue-template-compiler": "^2.3.3",
|
||||||
"webpack": "^2.2.1",
|
"webpack": "^2.2.1",
|
||||||
"webpack-dev-server": "^2.4.1",
|
"webpack-dev-server": "^2.4.1",
|
||||||
"webpack-merge": "^3.0.0"
|
"webpack-merge": "^3.0.0"
|
||||||
|
|
|
@ -198,12 +198,14 @@
|
||||||
}
|
}
|
||||||
// if trigger and children is input or textarea,listen focus & blur event
|
// if trigger and children is input or textarea,listen focus & blur event
|
||||||
if (this.trigger === 'focus') {
|
if (this.trigger === 'focus') {
|
||||||
const $children = this.getInputChildren();
|
this.isInput = true;
|
||||||
if ($children) {
|
this.$nextTick(() => {
|
||||||
$children.addEventListener('focus', this.handleFocus, false);
|
const $children = this.getInputChildren();
|
||||||
$children.addEventListener('blur', this.handleBlur, false);
|
if ($children) {
|
||||||
this.isInput = true;
|
$children.addEventListener('focus', this.handleFocus, false);
|
||||||
}
|
$children.addEventListener('blur', this.handleBlur, false);
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
beforeDestroy () {
|
beforeDestroy () {
|
||||||
|
|
Loading…
Add table
Reference in a new issue