filepond-plugin-file-rename
Advanced tools
Comparing version 1.1.0 to 1.1.1
/* | ||
* FilePondPluginFileRename 1.1.0 | ||
* FilePondPluginFileRename 1.1.1 | ||
* Licensed under MIT, https://opensource.org/licenses/MIT | ||
* Please visit https://pqina.nl/filepond for details. | ||
*/ | ||
/* eslint-disable */ | ||
var plugin$1 = ({ addFilter, utils }) => { | ||
@@ -65,4 +67,6 @@ // get quick reference to Type utils | ||
if (typeof navigator !== 'undefined' && document) { | ||
// plugin has loaded | ||
const isBrowser = | ||
typeof window !== 'undefined' && typeof window.document !== 'undefined'; | ||
if (isBrowser && document) { | ||
document.dispatchEvent( | ||
@@ -69,0 +73,0 @@ new CustomEvent('FilePond:pluginloaded', { detail: plugin$1 }) |
/* | ||
* FilePondPluginFileRename 1.1.0 | ||
* FilePondPluginFileRename 1.1.1 | ||
* Licensed under MIT, https://opensource.org/licenses/MIT | ||
* Please visit https://pqina.nl/filepond for details. | ||
*/ | ||
var plugin$1=({addFilter:e,utils:n})=>{const{Type:t,renameFile:i,isFile:o,getExtensionFromFilename:a,getFilenameWithoutExtension:l}=n;return e("LOAD_FILE",(e,{query:n})=>new Promise((t,u)=>{const m=n("GET_ALLOW_FILE_RENAME"),s=n("GET_FILE_RENAME_FUNCTION");if(!o(e)||!m||!s)return void t(e);const E=s({name:e.name,basename:l(e.name),extension:`.${a(e.name)}`}),F=n=>{t(i(e,n))};"string"!=typeof E?E.then(F):F(E)})),{options:{allowFileRename:[!0,t.BOOLEAN],fileRenameFunction:[null,t.FUNCTION]}}};"undefined"!=typeof navigator&&document&&document.dispatchEvent(new CustomEvent("FilePond:pluginloaded",{detail:plugin$1}));export default plugin$1; | ||
/* eslint-disable */ | ||
var plugin$1=({addFilter:e,utils:n})=>{const{Type:i,renameFile:t,isFile:o,getExtensionFromFilename:l,getFilenameWithoutExtension:s}=n;return e("LOAD_FILE",(e,{query:n})=>new Promise((i,a)=>{const d=n("GET_ALLOW_FILE_RENAME"),u=n("GET_FILE_RENAME_FUNCTION");if(!o(e)||!d||!u)return void i(e);const m=u({name:e.name,basename:s(e.name),extension:`.${l(e.name)}`}),r=n=>{i(t(e,n))};"string"!=typeof m?m.then(r):r(m)})),{options:{allowFileRename:[!0,i.BOOLEAN],fileRenameFunction:[null,i.FUNCTION]}}};const isBrowser="undefined"!=typeof window&&void 0!==window.document;isBrowser&&document&&document.dispatchEvent(new CustomEvent("FilePond:pluginloaded",{detail:plugin$1}));export default plugin$1; |
/* | ||
* FilePondPluginFileRename 1.1.0 | ||
* FilePondPluginFileRename 1.1.1 | ||
* Licensed under MIT, https://opensource.org/licenses/MIT | ||
* Please visit https://pqina.nl/filepond for details. | ||
*/ | ||
/* eslint-disable */ | ||
(function(global, factory) { | ||
@@ -75,4 +77,6 @@ typeof exports === 'object' && typeof module !== 'undefined' | ||
if (typeof navigator !== 'undefined' && document) { | ||
// plugin has loaded | ||
var isBrowser = | ||
typeof window !== 'undefined' && typeof window.document !== 'undefined'; | ||
if (isBrowser && document) { | ||
document.dispatchEvent( | ||
@@ -79,0 +83,0 @@ new CustomEvent('FilePond:pluginloaded', { detail: plugin$1 }) |
/* | ||
* FilePondPluginFileRename 1.1.0 | ||
* FilePondPluginFileRename 1.1.1 | ||
* Licensed under MIT, https://opensource.org/licenses/MIT | ||
* Please visit https://pqina.nl/filepond for details. | ||
*/ | ||
!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n():"function"==typeof define&&define.amd?define(n):e.FilePondPluginFileRename=n()}(this,function(){"use strict";var e=function(e){var n=e.addFilter,t=e.utils,i=t.Type,o=t.renameFile,u=t.isFile,a=t.getExtensionFromFilename,r=t.getFilenameWithoutExtension;return n("LOAD_FILE",function(e,n){var t=n.query;return new Promise(function(n,i){var d=t("GET_ALLOW_FILE_RENAME"),l=t("GET_FILE_RENAME_FUNCTION");if(!u(e)||!d||!l)return void n(e);var f=l({name:e.name,basename:r(e.name),extension:"."+a(e.name)}),m=function(t){n(o(e,t))};return"string"==typeof f?void m(f):void f.then(m)})}),{options:{allowFileRename:[!0,i.BOOLEAN],fileRenameFunction:[null,i.FUNCTION]}}};return"undefined"!=typeof navigator&&document&&document.dispatchEvent(new CustomEvent("FilePond:pluginloaded",{detail:e})),e}); | ||
/* eslint-disable */ | ||
!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n():"function"==typeof define&&define.amd?define(n):e.FilePondPluginFileRename=n()}(this,function(){"use strict";var e=function(e){var n=e.addFilter,i=e.utils,t=i.Type,l=i.renameFile,m=i.isFile,r=i.getExtensionFromFilename,f=i.getFilenameWithoutExtension;return n("LOAD_FILE",function(d,e){var a=e.query;return new Promise(function(n,e){var i=a("GET_ALLOW_FILE_RENAME"),t=a("GET_FILE_RENAME_FUNCTION");if(m(d)&&i&&t){var o=t({name:d.name,basename:f(d.name),extension:"."+r(d.name)}),u=function(e){n(l(d,e))};"string"!=typeof o?o.then(u):u(o)}else n(d)})}),{options:{allowFileRename:[!0,t.BOOLEAN],fileRenameFunction:[null,t.FUNCTION]}}};return"undefined"!=typeof window&&void 0!==window.document&&document&&document.dispatchEvent(new CustomEvent("FilePond:pluginloaded",{detail:e})),e}); |
{ | ||
"name": "filepond-plugin-file-rename", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"description": "File Rename Plugin for FilePond", | ||
@@ -16,4 +16,4 @@ "homepage": "https://pqina.nl/filepond", | ||
"peerDependencies": { | ||
"filepond": "^1.8.0" | ||
"filepond": ">=1.8.x <4.x" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
8318
150