├── .babelrc.js ├── .eslintrc.json ├── .github ├── ISSUE_TEMPLATE │ ├── bug_report.md │ └── feature_request.md └── workflows │ └── codeql-analysis.yml ├── .gitignore ├── .npmignore ├── .travis.yml ├── LICENSE ├── SECURITY.md ├── dist └── vue-dropify.umd.min.js ├── package.json ├── postcss.config.js ├── readme.md ├── src └── Dropify.vue └── webpack.config.js /.babelrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: ['@babel/preset-env'], 3 | } -------------------------------------------------------------------------------- /.eslintrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "env": { 3 | "browser": true, 4 | "es6": true 5 | }, 6 | "extends": "plugin:vue/essential", 7 | "globals": { 8 | "Atomics": "readonly", 9 | "SharedArrayBuffer": "readonly" 10 | }, 11 | "parserOptions": { 12 | "ecmaVersion": 2018, 13 | "sourceType": "module" 14 | }, 15 | "plugins": [ 16 | "vue" 17 | ], 18 | "rules": { 19 | } 20 | } -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/bug_report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug report 3 | about: Create a report to help us improve 4 | title: '' 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | **Describe the bug** 11 | A clear and concise description of what the bug is. 12 | 13 | **To Reproduce**(optional) 14 | Steps to reproduce the behavior: 15 | 1. Go to '...' 16 | 2. Click on '....' 17 | 3. Scroll down to '....' 18 | 4. See error 19 | 20 | **Screenshots** (optional) 21 | If applicable, add screenshots to help explain your problem. 22 | 23 | **Additional context** 24 | Add any other context about the problem here. 25 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature_request.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Feature request 3 | about: Suggest an idea for this project 4 | title: '' 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | **Is your feature request related to a problem? Please describe.** 11 | A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] 12 | 13 | **Describe the solution you'd like** 14 | A clear and concise description of what you want to happen. 15 | 16 | **Describe alternatives you've considered** 17 | A clear and concise description of any alternative solutions or features you've considered. 18 | 19 | **Additional context** 20 | Add any other context or screenshots about the feature request here. 21 | -------------------------------------------------------------------------------- /.github/workflows/codeql-analysis.yml: -------------------------------------------------------------------------------- 1 | # For most projects, this workflow file will not need changing; you simply need 2 | # to commit it to your repository. 3 | # 4 | # You may wish to alter this file to override the set of languages analyzed, 5 | # or to provide custom queries or build logic. 6 | name: "CodeQL" 7 | 8 | on: 9 | push: 10 | branches: [master] 11 | pull_request: 12 | # The branches below must be a subset of the branches above 13 | branches: [master] 14 | schedule: 15 | - cron: '0 21 * * 4' 16 | 17 | jobs: 18 | analyze: 19 | name: Analyze 20 | runs-on: ubuntu-latest 21 | 22 | strategy: 23 | fail-fast: false 24 | matrix: 25 | # Override automatic language detection by changing the below list 26 | # Supported options are ['csharp', 'cpp', 'go', 'java', 'javascript', 'python'] 27 | language: ['javascript'] 28 | # Learn more... 29 | # https://docs.github.com/en/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#overriding-automatic-language-detection 30 | 31 | steps: 32 | - name: Checkout repository 33 | uses: actions/checkout@v2 34 | with: 35 | # We must fetch at least the immediate parents so that if this is 36 | # a pull request then we can checkout the head. 37 | fetch-depth: 2 38 | 39 | # If this run was triggered by a pull request event, then checkout 40 | # the head of the pull request instead of the merge commit. 41 | - run: git checkout HEAD^2 42 | if: ${{ github.event_name == 'pull_request' }} 43 | 44 | # Initializes the CodeQL tools for scanning. 45 | - name: Initialize CodeQL 46 | uses: github/codeql-action/init@v1 47 | with: 48 | languages: ${{ matrix.language }} 49 | # If you wish to specify custom queries, you can do so here or in a config file. 50 | # By default, queries listed here will override any specified in a config file. 51 | # Prefix the list here with "+" to use these queries and those in the config file. 52 | # queries: ./path/to/local/query, your-org/your-repo/queries@main 53 | 54 | # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). 55 | # If this step fails, then you should remove it and run the build manually (see below) 56 | - name: Autobuild 57 | uses: github/codeql-action/autobuild@v1 58 | 59 | # ℹ️ Command-line programs to run using the OS shell. 60 | # 📚 https://git.io/JvXDl 61 | 62 | # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines 63 | # and modify them (or add more) to build your code if your project 64 | # uses a compiled language 65 | 66 | #- run: | 67 | # make bootstrap 68 | # make release 69 | 70 | - name: Perform CodeQL Analysis 71 | uses: github/codeql-action/analyze@v1 72 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules/ 2 | package-lock.json 3 | vue.config.js -------------------------------------------------------------------------------- /.npmignore: -------------------------------------------------------------------------------- 1 | dist/demo.html 2 | dist/*.umd.* 3 | dist/*.map 4 | .travis.yml 5 | .gitignore 6 | postcss.config.js 7 | .eslintrc.json 8 | .babelrc.js -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: node_js -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 Anas El Alami 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /SECURITY.md: -------------------------------------------------------------------------------- 1 | # Security Policy 2 | 3 | ## Supported Versions 4 | 5 | Use this section to tell people about which versions of your project are 6 | currently being supported with security updates. 7 | 8 | | Version | Supported | 9 | | ------- | ------------------ | 10 | | 5.1.x | :white_check_mark: | 11 | | 5.0.x | :x: | 12 | | 4.0.x | :white_check_mark: | 13 | | < 4.0 | :x: | 14 | 15 | ## Reporting a Vulnerability 16 | 17 | Use this section to tell people how to report a vulnerability. 18 | 19 | Tell them where to go, how often they can expect to get an update on a 20 | reported vulnerability, what to expect if the vulnerability is accepted or 21 | declined, etc. 22 | -------------------------------------------------------------------------------- /dist/vue-dropify.umd.min.js: -------------------------------------------------------------------------------- 1 | (function(t,e){"object"===typeof exports&&"object"===typeof module?module.exports=e():"function"===typeof define&&define.amd?define([],e):"object"===typeof exports?exports["vue-dropify"]=e():t["vue-dropify"]=e()})("undefined"!==typeof self?self:this,(function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s="fb15")}({"00ee":function(t,e,n){var r=n("b622"),i=r("toStringTag"),o={};o[i]="z",t.exports="[object z]"===String(o)},"0366":function(t,e,n){var r=n("1c0b");t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 0:return function(){return t.call(e)};case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,i){return t.call(e,n,r,i)}}return function(){return t.apply(e,arguments)}}},"057f":function(t,e,n){var r=n("fc6a"),i=n("241c").f,o={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],c=function(t){try{return i(t)}catch(e){return a.slice()}};t.exports.f=function(t){return a&&"[object Window]"==o.call(t)?c(t):i(r(t))}},"06cf":function(t,e,n){var r=n("83ab"),i=n("d1e7"),o=n("5c6c"),a=n("fc6a"),c=n("c04e"),u=n("5135"),s=n("0cfb"),f=Object.getOwnPropertyDescriptor;e.f=r?f:function(t,e){if(t=a(t),e=c(e,!0),s)try{return f(t,e)}catch(n){}if(u(t,e))return o(!i.f.call(t,e),t[e])}},"07ac":function(t,e,n){var r=n("23e7"),i=n("6f53").values;r({target:"Object",stat:!0},{values:function(t){return i(t)}})},"0cfb":function(t,e,n){var r=n("83ab"),i=n("d039"),o=n("cc12");t.exports=!r&&!i((function(){return 7!=Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},"0d3b":function(t,e,n){var r=n("d039"),i=n("b622"),o=n("c430"),a=i("iterator");t.exports=!r((function(){var t=new URL("b?a=1&b=2&c=3","http://a"),e=t.searchParams,n="";return t.pathname="c%20d",e.forEach((function(t,r){e["delete"]("b"),n+=r+t})),o&&!t.toJSON||!e.sort||"http://a/c%20d?a=1&c=3"!==t.href||"3"!==e.get("c")||"a=1"!==String(new URLSearchParams("?a=1"))||!e[a]||"a"!==new URL("https://a@b").username||"b"!==new URLSearchParams(new URLSearchParams("a=b")).get("a")||"xn--e1aybc"!==new URL("http://тест").host||"#%D0%B1"!==new URL("http://a#б").hash||"a1c3"!==n||"x"!==new URL("http://x",void 0).host}))},"159b":function(t,e,n){var r=n("da84"),i=n("fdbc"),o=n("17c2"),a=n("9112");for(var c in i){var u=r[c],s=u&&u.prototype;if(s&&s.forEach!==o)try{a(s,"forEach",o)}catch(f){s.forEach=o}}},"17c2":function(t,e,n){"use strict";var r=n("b727").forEach,i=n("a640"),o=n("ae40"),a=i("forEach"),c=o("forEach");t.exports=a&&c?[].forEach:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}},"19aa":function(t,e){t.exports=function(t,e,n){if(!(t instanceof e))throw TypeError("Incorrect "+(n?n+" ":"")+"invocation");return t}},"1be4":function(t,e,n){var r=n("d066");t.exports=r("document","documentElement")},"1c0b":function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t}},"1c7e":function(t,e,n){var r=n("b622"),i=r("iterator"),o=!1;try{var a=0,c={next:function(){return{done:!!a++}},return:function(){o=!0}};c[i]=function(){return this},Array.from(c,(function(){throw 2}))}catch(u){}t.exports=function(t,e){if(!e&&!o)return!1;var n=!1;try{var r={};r[i]=function(){return{next:function(){return{done:n=!0}}}},t(r)}catch(u){}return n}},"1cdc":function(t,e,n){var r=n("342f");t.exports=/(iphone|ipod|ipad).*applewebkit/i.test(r)},"1d80":function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}},"1dde":function(t,e,n){var r=n("d039"),i=n("b622"),o=n("2d00"),a=i("species");t.exports=function(t){return o>=51||!r((function(){var e=[],n=e.constructor={};return n[a]=function(){return{foo:1}},1!==e[t](Boolean).foo}))}},2266:function(t,e,n){var r=n("825a"),i=n("e95a"),o=n("50c4"),a=n("0366"),c=n("35a1"),u=n("9bdd"),s=function(t,e){this.stopped=t,this.result=e},f=t.exports=function(t,e,n,f,l){var p,d,h,v,g,y,m,b=a(e,n,f?2:1);if(l)p=t;else{if(d=c(t),"function"!=typeof d)throw TypeError("Target is not iterable");if(i(d)){for(h=0,v=o(t.length);v>h;h++)if(g=f?b(r(m=t[h])[0],m[1]):b(t[h]),g&&g instanceof s)return g;return new s(!1)}p=d.call(t)}y=p.next;while(!(m=y.call(p)).done)if(g=u(p,b,m.value,f),"object"==typeof g&&g&&g instanceof s)return g;return new s(!1)};f.stop=function(t){return new s(!0,t)}},"23cb":function(t,e,n){var r=n("a691"),i=Math.max,o=Math.min;t.exports=function(t,e){var n=r(t);return n<0?i(n+e,0):o(n,e)}},"23e7":function(t,e,n){var r=n("da84"),i=n("06cf").f,o=n("9112"),a=n("6eeb"),c=n("ce4e"),u=n("e893"),s=n("94ca");t.exports=function(t,e){var n,f,l,p,d,h,v=t.target,g=t.global,y=t.stat;if(f=g?r:y?r[v]||c(v,{}):(r[v]||{}).prototype,f)for(l in e){if(d=e[l],t.noTargetGet?(h=i(f,l),p=h&&h.value):p=f[l],n=s(g?l:v+(y?".":"#")+l,t.forced),!n&&void 0!==p){if(typeof d===typeof p)continue;u(d,p)}(t.sham||p&&p.sham)&&o(d,"sham",!0),a(f,l,d,t)}}},"241c":function(t,e,n){var r=n("ca84"),i=n("7839"),o=i.concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return r(t,o)}},"24fb":function(t,e,n){"use strict";function r(t,e){var n=t[1]||"",r=t[3];if(!r)return n;if(e&&"function"===typeof btoa){var o=i(r),a=r.sources.map((function(t){return"/*# sourceURL=".concat(r.sourceRoot||"").concat(t," */")}));return[n].concat(a).concat([o]).join("\n")}return[n].join("\n")}function i(t){var e=btoa(unescape(encodeURIComponent(JSON.stringify(t)))),n="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(e);return"/*# ".concat(n," */")}t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var n=r(e,t);return e[2]?"@media ".concat(e[2]," {").concat(n,"}"):n})).join("")},e.i=function(t,n,r){"string"===typeof t&&(t=[[null,t,""]]);var i={};if(r)for(var o=0;o4)return t;for(n=[],r=0;r1&&"0"==i.charAt(0)&&(o=T.test(i)?16:8,i=i.slice(8==o?1:2)),""===i)a=0;else{if(!(10==o?I:8==o?U:M).test(i))return t;a=parseInt(i,o)}n.push(a)}for(r=0;r=A(256,5-e))return null}else if(a>255)return null;for(c=n.pop(),r=0;r6)return;r=0;while(p()){if(i=null,r>0){if(!("."==p()&&r<4))return;l++}if(!C.test(p()))return;while(C.test(p())){if(o=parseInt(p(),10),null===i)i=o;else{if(0==i)return;i=10*i+o}if(i>255)return;l++}u[s]=256*u[s]+i,r++,2!=r&&4!=r||s++}if(4!=r)return;break}if(":"==p()){if(l++,!p())return}else if(p())return;u[s++]=e}else{if(null!==f)return;l++,s++,f=s}}if(null!==f){a=s-f,s=7;while(0!=s&&a>0)c=u[s],u[s--]=u[f+a-1],u[f+--a]=c}else if(8!=s)return;return u},V=function(t){for(var e=null,n=1,r=null,i=0,o=0;o<8;o++)0!==t[o]?(i>n&&(e=r,n=i),r=null,i=0):(null===r&&(r=o),++i);return i>n&&(e=r,n=i),e},G=function(t){var e,n,r,i;if("number"==typeof t){for(e=[],n=0;n<4;n++)e.unshift(t%256),t=O(t/256);return e.join(".")}if("object"==typeof t){for(e="",r=V(t),n=0;n<8;n++)i&&0===t[n]||(i&&(i=!1),r===n?(e+=n?":":"::",i=!0):(e+=t[n].toString(16),n<7&&(e+=":")));return"["+e+"]"}return t},W={},H=p({},W,{" ":1,'"':1,"<":1,">":1,"`":1}),J=p({},H,{"#":1,"?":1,"{":1,"}":1}),X=p({},J,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),Y=function(t,e){var n=h(t,0);return n>32&&n<127&&!l(e,t)?t:encodeURIComponent(t)},K={ftp:21,file:null,http:80,https:443,ws:80,wss:443},Z=function(t){return l(K,t.scheme)},Q=function(t){return""!=t.username||""!=t.password},tt=function(t){return!t.host||t.cannotBeABaseURL||"file"==t.scheme},et=function(t,e){var n;return 2==t.length&&P.test(t.charAt(0))&&(":"==(n=t.charAt(1))||!e&&"|"==n)},nt=function(t){var e;return t.length>1&&et(t.slice(0,2))&&(2==t.length||"/"===(e=t.charAt(2))||"\\"===e||"?"===e||"#"===e)},rt=function(t){var e=t.path,n=e.length;!n||"file"==t.scheme&&1==n&&et(e[0],!0)||e.pop()},it=function(t){return"."===t||"%2e"===t.toLowerCase()},ot=function(t){return t=t.toLowerCase(),".."===t||"%2e."===t||".%2e"===t||"%2e%2e"===t},at={},ct={},ut={},st={},ft={},lt={},pt={},dt={},ht={},vt={},gt={},yt={},mt={},bt={},wt={},xt={},St={},jt={},Ot={},At={},kt={},Lt=function(t,e,n,i){var o,a,c,u,s=n||at,f=0,p="",h=!1,v=!1,g=!1;n||(t.scheme="",t.username="",t.password="",t.host=null,t.port=null,t.path=[],t.query=null,t.fragment=null,t.cannotBeABaseURL=!1,e=e.replace(B,"")),e=e.replace(D,""),o=d(e);while(f<=o.length){switch(a=o[f],s){case at:if(!a||!P.test(a)){if(n)return L;s=ut;continue}p+=a.toLowerCase(),s=ct;break;case ct:if(a&&(R.test(a)||"+"==a||"-"==a||"."==a))p+=a.toLowerCase();else{if(":"!=a){if(n)return L;p="",s=ut,f=0;continue}if(n&&(Z(t)!=l(K,p)||"file"==p&&(Q(t)||null!==t.port)||"file"==t.scheme&&!t.host))return;if(t.scheme=p,n)return void(Z(t)&&K[t.scheme]==t.port&&(t.port=null));p="","file"==t.scheme?s=bt:Z(t)&&i&&i.scheme==t.scheme?s=st:Z(t)?s=dt:"/"==o[f+1]?(s=ft,f++):(t.cannotBeABaseURL=!0,t.path.push(""),s=Ot)}break;case ut:if(!i||i.cannotBeABaseURL&&"#"!=a)return L;if(i.cannotBeABaseURL&&"#"==a){t.scheme=i.scheme,t.path=i.path.slice(),t.query=i.query,t.fragment="",t.cannotBeABaseURL=!0,s=kt;break}s="file"==i.scheme?bt:lt;continue;case st:if("/"!=a||"/"!=o[f+1]){s=lt;continue}s=ht,f++;break;case ft:if("/"==a){s=vt;break}s=jt;continue;case lt:if(t.scheme=i.scheme,a==r)t.username=i.username,t.password=i.password,t.host=i.host,t.port=i.port,t.path=i.path.slice(),t.query=i.query;else if("/"==a||"\\"==a&&Z(t))s=pt;else if("?"==a)t.username=i.username,t.password=i.password,t.host=i.host,t.port=i.port,t.path=i.path.slice(),t.query="",s=At;else{if("#"!=a){t.username=i.username,t.password=i.password,t.host=i.host,t.port=i.port,t.path=i.path.slice(),t.path.pop(),s=jt;continue}t.username=i.username,t.password=i.password,t.host=i.host,t.port=i.port,t.path=i.path.slice(),t.query=i.query,t.fragment="",s=kt}break;case pt:if(!Z(t)||"/"!=a&&"\\"!=a){if("/"!=a){t.username=i.username,t.password=i.password,t.host=i.host,t.port=i.port,s=jt;continue}s=vt}else s=ht;break;case dt:if(s=ht,"/"!=a||"/"!=p.charAt(f+1))continue;f++;break;case ht:if("/"!=a&&"\\"!=a){s=vt;continue}break;case vt:if("@"==a){h&&(p="%40"+p),h=!0,c=d(p);for(var y=0;y65535)return E;t.port=Z(t)&&w===K[t.scheme]?null:w,p=""}if(n)return;s=St;continue}return E}p+=a;break;case bt:if(t.scheme="file","/"==a||"\\"==a)s=wt;else{if(!i||"file"!=i.scheme){s=jt;continue}if(a==r)t.host=i.host,t.path=i.path.slice(),t.query=i.query;else if("?"==a)t.host=i.host,t.path=i.path.slice(),t.query="",s=At;else{if("#"!=a){nt(o.slice(f).join(""))||(t.host=i.host,t.path=i.path.slice(),rt(t)),s=jt;continue}t.host=i.host,t.path=i.path.slice(),t.query=i.query,t.fragment="",s=kt}}break;case wt:if("/"==a||"\\"==a){s=xt;break}i&&"file"==i.scheme&&!nt(o.slice(f).join(""))&&(et(i.path[0],!0)?t.path.push(i.path[0]):t.host=i.host),s=jt;continue;case xt:if(a==r||"/"==a||"\\"==a||"?"==a||"#"==a){if(!n&&et(p))s=jt;else if(""==p){if(t.host="",n)return;s=St}else{if(u=q(t,p),u)return u;if("localhost"==t.host&&(t.host=""),n)return;p="",s=St}continue}p+=a;break;case St:if(Z(t)){if(s=jt,"/"!=a&&"\\"!=a)continue}else if(n||"?"!=a)if(n||"#"!=a){if(a!=r&&(s=jt,"/"!=a))continue}else t.fragment="",s=kt;else t.query="",s=At;break;case jt:if(a==r||"/"==a||"\\"==a&&Z(t)||!n&&("?"==a||"#"==a)){if(ot(p)?(rt(t),"/"==a||"\\"==a&&Z(t)||t.path.push("")):it(p)?"/"==a||"\\"==a&&Z(t)||t.path.push(""):("file"==t.scheme&&!t.path.length&&et(p)&&(t.host&&(t.host=""),p=p.charAt(0)+":"),t.path.push(p)),p="","file"==t.scheme&&(a==r||"?"==a||"#"==a))while(t.path.length>1&&""===t.path[0])t.path.shift();"?"==a?(t.query="",s=At):"#"==a&&(t.fragment="",s=kt)}else p+=Y(a,J);break;case Ot:"?"==a?(t.query="",s=At):"#"==a?(t.fragment="",s=kt):a!=r&&(t.path[0]+=Y(a,W));break;case At:n||"#"!=a?a!=r&&("'"==a&&Z(t)?t.query+="%27":t.query+="#"==a?"%23":Y(a,W)):(t.fragment="",s=kt);break;case kt:a!=r&&(t.fragment+=Y(a,H));break}f++}},_t=function(t){var e,n,r=f(this,_t,"URL"),i=arguments.length>1?arguments[1]:void 0,a=String(t),c=S(r,{type:"URL"});if(void 0!==i)if(i instanceof _t)e=j(i);else if(n=Lt(e={},String(i)),n)throw TypeError(n);if(n=Lt(c,a,null,e),n)throw TypeError(n);var u=c.searchParams=new w,s=x(u);s.updateSearchParams(c.query),s.updateURL=function(){c.query=String(u)||null},o||(r.href=Pt.call(r),r.origin=Rt.call(r),r.protocol=Ct.call(r),r.username=Tt.call(r),r.password=Ut.call(r),r.host=It.call(r),r.hostname=Mt.call(r),r.port=zt.call(r),r.pathname=Ft.call(r),r.search=Bt.call(r),r.searchParams=Dt.call(r),r.hash=qt.call(r))},Et=_t.prototype,Pt=function(){var t=j(this),e=t.scheme,n=t.username,r=t.password,i=t.host,o=t.port,a=t.path,c=t.query,u=t.fragment,s=e+":";return null!==i?(s+="//",Q(t)&&(s+=n+(r?":"+r:"")+"@"),s+=G(i),null!==o&&(s+=":"+o)):"file"==e&&(s+="//"),s+=t.cannotBeABaseURL?a[0]:a.length?"/"+a.join("/"):"",null!==c&&(s+="?"+c),null!==u&&(s+="#"+u),s},Rt=function(){var t=j(this),e=t.scheme,n=t.port;if("blob"==e)try{return new URL(e.path[0]).origin}catch(r){return"null"}return"file"!=e&&Z(t)?e+"://"+G(t.host)+(null!==n?":"+n:""):"null"},Ct=function(){return j(this).scheme+":"},Tt=function(){return j(this).username},Ut=function(){return j(this).password},It=function(){var t=j(this),e=t.host,n=t.port;return null===e?"":null===n?G(e):G(e)+":"+n},Mt=function(){var t=j(this).host;return null===t?"":G(t)},zt=function(){var t=j(this).port;return null===t?"":String(t)},Ft=function(){var t=j(this),e=t.path;return t.cannotBeABaseURL?e[0]:e.length?"/"+e.join("/"):""},Bt=function(){var t=j(this).query;return t?"?"+t:""},Dt=function(){return j(this).searchParams},qt=function(){var t=j(this).fragment;return t?"#"+t:""},Nt=function(t,e){return{get:t,set:e,configurable:!0,enumerable:!0}};if(o&&u(Et,{href:Nt(Pt,(function(t){var e=j(this),n=String(t),r=Lt(e,n);if(r)throw TypeError(r);x(e.searchParams).updateSearchParams(e.query)})),origin:Nt(Rt),protocol:Nt(Ct,(function(t){var e=j(this);Lt(e,String(t)+":",at)})),username:Nt(Tt,(function(t){var e=j(this),n=d(String(t));if(!tt(e)){e.username="";for(var r=0;rn)e.push(arguments[n++]);return w[++b]=function(){("function"==typeof t?t:Function(t)).apply(void 0,e)},r(b),b},v=function(t){delete w[t]},"process"==u(g)?r=function(t){g.nextTick(j(t))}:m&&m.now?r=function(t){m.now(j(t))}:y&&!p?(i=new y,o=i.port2,i.port1.onmessage=O,r=s(o.postMessage,o,1)):!a.addEventListener||"function"!=typeof postMessage||a.importScripts||c(A)||"file:"===d.protocol?r=x in l("script")?function(t){f.appendChild(l("script"))[x]=function(){f.removeChild(this),S(t)}}:function(t){setTimeout(j(t),0)}:(r=A,a.addEventListener("message",O,!1))),t.exports={set:h,clear:v}},"2d00":function(t,e,n){var r,i,o=n("da84"),a=n("342f"),c=o.process,u=c&&c.versions,s=u&&u.v8;s?(r=s.split("."),i=r[0]+r[1]):a&&(r=a.match(/Edge\/(\d+)/),(!r||r[1]>=74)&&(r=a.match(/Chrome\/(\d+)/),r&&(i=r[1]))),t.exports=i&&+i},"342f":function(t,e,n){var r=n("d066");t.exports=r("navigator","userAgent")||""},"35a1":function(t,e,n){var r=n("f5df"),i=n("3f8c"),o=n("b622"),a=o("iterator");t.exports=function(t){if(void 0!=t)return t[a]||t["@@iterator"]||i[r(t)]}},"37e8":function(t,e,n){var r=n("83ab"),i=n("9bf2"),o=n("825a"),a=n("df75");t.exports=r?Object.defineProperties:function(t,e){o(t);var n,r=a(e),c=r.length,u=0;while(c>u)i.f(t,n=r[u++],e[n]);return t}},"3bbe":function(t,e,n){var r=n("861d");t.exports=function(t){if(!r(t)&&null!==t)throw TypeError("Can't set "+String(t)+" as a prototype");return t}},"3ca3":function(t,e,n){"use strict";var r=n("6547").charAt,i=n("69f3"),o=n("7dd0"),a="String Iterator",c=i.set,u=i.getterFor(a);o(String,"String",(function(t){c(this,{type:a,string:String(t),index:0})}),(function(){var t,e=u(this),n=e.string,i=e.index;return i>=n.length?{value:void 0,done:!0}:(t=r(n,i),e.index+=t.length,{value:t,done:!1})}))},"3f8c":function(t,e){t.exports={}},4160:function(t,e,n){"use strict";var r=n("23e7"),i=n("17c2");r({target:"Array",proto:!0,forced:[].forEach!=i},{forEach:i})},"428f":function(t,e,n){var r=n("da84");t.exports=r},"44ad":function(t,e,n){var r=n("d039"),i=n("c6b6"),o="".split;t.exports=r((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==i(t)?o.call(t,""):Object(t)}:Object},"44d2":function(t,e,n){var r=n("b622"),i=n("7c73"),o=n("9bf2"),a=r("unscopables"),c=Array.prototype;void 0==c[a]&&o.f(c,a,{configurable:!0,value:i(null)}),t.exports=function(t){c[a][t]=!0}},"44de":function(t,e,n){var r=n("da84");t.exports=function(t,e){var n=r.console;n&&n.error&&(1===arguments.length?n.error(t):n.error(t,e))}},4840:function(t,e,n){var r=n("825a"),i=n("1c0b"),o=n("b622"),a=o("species");t.exports=function(t,e){var n,o=r(t).constructor;return void 0===o||void 0==(n=r(o)[a])?e:i(n)}},4930:function(t,e,n){var r=n("d039");t.exports=!!Object.getOwnPropertySymbols&&!r((function(){return!String(Symbol())}))},"499e":function(t,e,n){"use strict";function r(t,e){for(var n=[],r={},i=0;in.parts.length&&(r.parts.length=n.parts.length)}else{var a=[];for(i=0;if)if(c=u[f++],c!=c)return!0}else for(;s>f;f++)if((t||f in u)&&u[f]===n)return t||f||0;return!t&&-1}};t.exports={includes:a(!0),indexOf:a(!1)}},"4de4":function(t,e,n){"use strict";var r=n("23e7"),i=n("b727").filter,o=n("1dde"),a=n("ae40"),c=o("filter"),u=a("filter");r({target:"Array",proto:!0,forced:!c||!u},{filter:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},"4df4":function(t,e,n){"use strict";var r=n("0366"),i=n("7b0b"),o=n("9bdd"),a=n("e95a"),c=n("50c4"),u=n("8418"),s=n("35a1");t.exports=function(t){var e,n,f,l,p,d,h=i(t),v="function"==typeof this?this:Array,g=arguments.length,y=g>1?arguments[1]:void 0,m=void 0!==y,b=s(h),w=0;if(m&&(y=r(y,g>2?arguments[2]:void 0,2)),void 0==b||v==Array&&a(b))for(e=c(h.length),n=new v(e);e>w;w++)d=m?y(h[w],w):h[w],u(n,w,d);else for(l=b.call(h),p=l.next,n=new v;!(f=p.call(l)).done;w++)d=m?o(l,y,[f.value,w],!0):f.value,u(n,w,d);return n.length=w,n}},"50c4":function(t,e,n){var r=n("a691"),i=Math.min;t.exports=function(t){return t>0?i(r(t),9007199254740991):0}},5135:function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},5692:function(t,e,n){var r=n("c430"),i=n("c6cd");(t.exports=function(t,e){return i[t]||(i[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.6.5",mode:r?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},"56ef":function(t,e,n){var r=n("d066"),i=n("241c"),o=n("7418"),a=n("825a");t.exports=r("Reflect","ownKeys")||function(t){var e=i.f(a(t)),n=o.f;return n?e.concat(n(t)):e}},"5c6c":function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},"5fb2":function(t,e,n){"use strict";var r=2147483647,i=36,o=1,a=26,c=38,u=700,s=72,f=128,l="-",p=/[^\0-\u007E]/,d=/[.\u3002\uFF0E\uFF61]/g,h="Overflow: input needs wider integers to process",v=i-o,g=Math.floor,y=String.fromCharCode,m=function(t){var e=[],n=0,r=t.length;while(n=55296&&i<=56319&&n>1,t+=g(t/e);t>v*a>>1;r+=i)t=g(t/v);return g(r+(v+1)*t/(t+c))},x=function(t){var e=[];t=m(t);var n,c,u=t.length,p=f,d=0,v=s;for(n=0;n=p&&cg((r-d)/O))throw RangeError(h);for(d+=(j-p)*O,p=j,n=0;nr)throw RangeError(h);if(c==p){for(var A=d,k=i;;k+=i){var L=k<=v?o:k>=v+a?a:k-v;if(Af){var d,h=s(arguments[f++]),v=l?o(h).concat(l(h)):o(h),g=v.length,y=0;while(g>y)d=v[y++],r&&!p.call(h,d)||(n[d]=h[d])}return n}:f},6547:function(t,e,n){var r=n("a691"),i=n("1d80"),o=function(t){return function(e,n){var o,a,c=String(i(e)),u=r(n),s=c.length;return u<0||u>=s?t?"":void 0:(o=c.charCodeAt(u),o<55296||o>56319||u+1===s||(a=c.charCodeAt(u+1))<56320||a>57343?t?c.charAt(u):o:t?c.slice(u,u+2):a-56320+(o-55296<<10)+65536)}};t.exports={codeAt:o(!1),charAt:o(!0)}},"65f0":function(t,e,n){var r=n("861d"),i=n("e8b5"),o=n("b622"),a=o("species");t.exports=function(t,e){var n;return i(t)&&(n=t.constructor,"function"!=typeof n||n!==Array&&!i(n.prototype)?r(n)&&(n=n[a],null===n&&(n=void 0)):n=void 0),new(void 0===n?Array:n)(0===e?0:e)}},"69f3":function(t,e,n){var r,i,o,a=n("7f9a"),c=n("da84"),u=n("861d"),s=n("9112"),f=n("5135"),l=n("f772"),p=n("d012"),d=c.WeakMap,h=function(t){return o(t)?i(t):r(t,{})},v=function(t){return function(e){var n;if(!u(e)||(n=i(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return n}};if(a){var g=new d,y=g.get,m=g.has,b=g.set;r=function(t,e){return b.call(g,t,e),e},i=function(t){return y.call(g,t)||{}},o=function(t){return m.call(g,t)}}else{var w=l("state");p[w]=!0,r=function(t,e){return s(t,w,e),e},i=function(t){return f(t,w)?t[w]:{}},o=function(t){return f(t,w)}}t.exports={set:r,get:i,has:o,enforce:h,getterFor:v}},"6eeb":function(t,e,n){var r=n("da84"),i=n("9112"),o=n("5135"),a=n("ce4e"),c=n("8925"),u=n("69f3"),s=u.get,f=u.enforce,l=String(String).split("String");(t.exports=function(t,e,n,c){var u=!!c&&!!c.unsafe,s=!!c&&!!c.enumerable,p=!!c&&!!c.noTargetGet;"function"==typeof n&&("string"!=typeof e||o(n,"name")||i(n,"name",e),f(n).source=l.join("string"==typeof e?e:"")),t!==r?(u?!p&&t[e]&&(s=!0):delete t[e],s?t[e]=n:i(t,e,n)):s?t[e]=n:a(e,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&s(this).source||c(this)}))},"6f53":function(t,e,n){var r=n("83ab"),i=n("df75"),o=n("fc6a"),a=n("d1e7").f,c=function(t){return function(e){var n,c=o(e),u=i(c),s=u.length,f=0,l=[];while(s>f)n=u[f++],r&&!a.call(c,n)||l.push(t?[n,c[n]]:c[n]);return l}};t.exports={entries:c(!0),values:c(!1)}},7418:function(t,e){e.f=Object.getOwnPropertySymbols},"746f":function(t,e,n){var r=n("428f"),i=n("5135"),o=n("e538"),a=n("9bf2").f;t.exports=function(t){var e=r.Symbol||(r.Symbol={});i(e,t)||a(e,t,{value:o.f(t)})}},7839:function(t,e){t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},"7b0b":function(t,e,n){var r=n("1d80");t.exports=function(t){return Object(r(t))}},"7c73":function(t,e,n){var r,i=n("825a"),o=n("37e8"),a=n("7839"),c=n("d012"),u=n("1be4"),s=n("cc12"),f=n("f772"),l=">",p="<",d="prototype",h="script",v=f("IE_PROTO"),g=function(){},y=function(t){return p+h+l+t+p+"/"+h+l},m=function(t){t.write(y("")),t.close();var e=t.parentWindow.Object;return t=null,e},b=function(){var t,e=s("iframe"),n="java"+h+":";return e.style.display="none",u.appendChild(e),e.src=String(n),t=e.contentWindow.document,t.open(),t.write(y("document.F=Object")),t.close(),t.F},w=function(){try{r=document.domain&&new ActiveXObject("htmlfile")}catch(e){}w=r?m(r):b();var t=a.length;while(t--)delete w[d][a[t]];return w()};c[v]=!0,t.exports=Object.create||function(t,e){var n;return null!==t?(g[d]=i(t),n=new g,g[d]=null,n[v]=t):n=w(),void 0===e?n:o(n,e)}},"7dd0":function(t,e,n){"use strict";var r=n("23e7"),i=n("9ed3"),o=n("e163"),a=n("d2bb"),c=n("d44e"),u=n("9112"),s=n("6eeb"),f=n("b622"),l=n("c430"),p=n("3f8c"),d=n("ae93"),h=d.IteratorPrototype,v=d.BUGGY_SAFARI_ITERATORS,g=f("iterator"),y="keys",m="values",b="entries",w=function(){return this};t.exports=function(t,e,n,f,d,x,S){i(n,e,f);var j,O,A,k=function(t){if(t===d&&R)return R;if(!v&&t in E)return E[t];switch(t){case y:return function(){return new n(this,t)};case m:return function(){return new n(this,t)};case b:return function(){return new n(this,t)}}return function(){return new n(this)}},L=e+" Iterator",_=!1,E=t.prototype,P=E[g]||E["@@iterator"]||d&&E[d],R=!v&&P||k(d),C="Array"==e&&E.entries||P;if(C&&(j=o(C.call(new t)),h!==Object.prototype&&j.next&&(l||o(j)===h||(a?a(j,h):"function"!=typeof j[g]&&u(j,g,w)),c(j,L,!0,!0),l&&(p[L]=w))),d==m&&P&&P.name!==m&&(_=!0,R=function(){return P.call(this)}),l&&!S||E[g]===R||u(E,g,R),p[e]=R,d)if(O={values:k(m),keys:x?R:k(y),entries:k(b)},S)for(A in O)(v||_||!(A in E))&&s(E,A,O[A]);else r({target:e,proto:!0,forced:v||_},O);return O}},"7f9a":function(t,e,n){var r=n("da84"),i=n("8925"),o=r.WeakMap;t.exports="function"===typeof o&&/native code/.test(i(o))},"825a":function(t,e,n){var r=n("861d");t.exports=function(t){if(!r(t))throw TypeError(String(t)+" is not an object");return t}},"83ab":function(t,e,n){var r=n("d039");t.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},8418:function(t,e,n){"use strict";var r=n("c04e"),i=n("9bf2"),o=n("5c6c");t.exports=function(t,e,n){var a=r(e);a in t?i.f(t,a,o(0,n)):t[a]=n}},"861d":function(t,e){t.exports=function(t){return"object"===typeof t?null!==t:"function"===typeof t}},8875:function(t,e,n){var r,i,o;(function(n,a){i=[],r=a,o="function"===typeof r?r.apply(e,i):r,void 0===o||(t.exports=o)})("undefined"!==typeof self&&self,(function(){function t(){var e=Object.getOwnPropertyDescriptor(document,"currentScript");if(!e&&"currentScript"in document&&document.currentScript)return document.currentScript;if(e&&e.get!==t&&document.currentScript)return document.currentScript;try{throw new Error}catch(d){var n,r,i,o=/.*at [^(]*\((.*):(.+):(.+)\)$/gi,a=/@([^@]*):(\d+):(\d+)\s*$/gi,c=o.exec(d.stack)||a.exec(d.stack),u=c&&c[1]||!1,s=c&&c[2]||!1,f=document.location.href.replace(document.location.hash,""),l=document.getElementsByTagName("script");u===f&&(n=document.documentElement.outerHTML,r=new RegExp("(?:[^\\n]+?\\n){0,"+(s-2)+"}[^<]* 332 | 476 | -------------------------------------------------------------------------------- /webpack.config.js: -------------------------------------------------------------------------------- 1 | const VueLoaderPlugin = require('vue-loader/lib/plugin'); 2 | 3 | module.exports = { 4 | entry: './src/Dropify.vue', 5 | output:{ 6 | filename:'vue-dropify.js' 7 | }, 8 | module: { 9 | rules: [ 10 | { test: /\.js$/, use: 'babel-loader' }, 11 | { test: /\.vue$/, use: 'vue-loader' }, 12 | { test: /\.css$/, use: ['vue-style-loader', 'css-loader']}, 13 | ] 14 | }, 15 | plugins: [ 16 | new VueLoaderPlugin(), 17 | ] 18 | }; 19 | --------------------------------------------------------------------------------