lianyue 7 years ago
parent ba5274c0a2
commit a969e16bc0

@ -13,6 +13,8 @@
display: inline-block; display: inline-block;
} }
.file-uploads.file-uploads-html4 input[type="file"], .file-uploads.file-uploads-html5 label { .file-uploads.file-uploads-html4 input[type="file"], .file-uploads.file-uploads-html5 label {
/* background fix ie click */
background: #fff;
opacity: 0; opacity: 0;
font-size: 20em; font-size: 20em;
z-index: 1; z-index: 1;
@ -25,6 +27,8 @@
height: 100%; height: 100%;
} }
.file-uploads.file-uploads-html5 input[type="file"], .file-uploads.file-uploads-html4 label { .file-uploads.file-uploads-html5 input[type="file"], .file-uploads.file-uploads-html4 label {
/* background fix ie click */
background: rgba(255, 255, 255, 0);
overflow: hidden; overflow: hidden;
position: fixed; position: fixed;
width: 1px; width: 1px;

@ -15,8 +15,11 @@
export default { export default {
methods: { methods: {
change(e) { change(e) {
this.$destroy()
this.$parent.addInputFile(e.target) this.$parent.addInputFile(e.target)
e.target.value = ''
if (!e.target.files) {
// ie9 fix #219
this.$destroy()
// eslint-disable-next-line // eslint-disable-next-line
new this.constructor({ new this.constructor({
parent: this.$parent, parent: this.$parent,
@ -24,5 +27,6 @@ export default {
}) })
} }
} }
}
} }
</script> </script>

Loading…
Cancel
Save