From 13725f040bca346a7b35b832f36f4e86c5da11e4 Mon Sep 17 00:00:00 2001 From: taehoon Date: Thu, 7 Feb 2019 03:05:59 -0500 Subject: Add avatar crop popup --- .eslintrc.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to '.eslintrc.js') diff --git a/.eslintrc.js b/.eslintrc.js index 8e6549e5..32842d3c 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -10,8 +10,14 @@ module.exports = { plugins: [ 'html' ], + globals: { + 'FileReader': false, + 'Element': false, + 'FormData': false, + 'XMLHttpRequest': false + }, // add your custom rules here - 'rules': { + rules: { // allow paren-less arrow functions 'arrow-parens': 0, // allow async-await -- cgit v1.2.3-70-g09d2 From 546ba9eba98041ef1c097541a734c73c4917070e Mon Sep 17 00:00:00 2001 From: taehoon Date: Fri, 8 Feb 2019 12:13:23 -0500 Subject: Revert eslintrc changes --- .eslintrc.js | 6 ------ src/components/image_cropper/image_cropper.js | 4 ++-- 2 files changed, 2 insertions(+), 8 deletions(-) (limited to '.eslintrc.js') diff --git a/.eslintrc.js b/.eslintrc.js index 32842d3c..800f9a4f 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -10,12 +10,6 @@ module.exports = { plugins: [ 'html' ], - globals: { - 'FileReader': false, - 'Element': false, - 'FormData': false, - 'XMLHttpRequest': false - }, // add your custom rules here rules: { // allow paren-less arrow functions diff --git a/src/components/image_cropper/image_cropper.js b/src/components/image_cropper/image_cropper.js index d919827f..b2580240 100644 --- a/src/components/image_cropper/image_cropper.js +++ b/src/components/image_cropper/image_cropper.js @@ -5,7 +5,7 @@ import 'cropperjs/dist/cropper.css' const ImageCropper = { props: { trigger: { - type: [String, Element], + type: [String, window.Element], required: true }, cropperOptions: { @@ -74,7 +74,7 @@ const ImageCropper = { readFile () { const fileInput = this.$refs.input if (fileInput.files != null && fileInput.files[0] != null) { - let reader = new FileReader() + let reader = new window.FileReader() reader.onload = (e) => { this.dataUrl = e.target.result } -- cgit v1.2.3-70-g09d2