Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

inter-mediator-plugin-jqueryfileupload

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

inter-mediator-plugin-jqueryfileupload - npm Package Compare versions

Comparing version 1.2.4 to 1.3.0

.github/workflows/node.js.yml

25

index.js

@@ -27,2 +27,3 @@ /*

multiFileInPostOnly: false,
fileExtRequirements: null, // or ['csv']

@@ -170,2 +171,13 @@ instanciate: function (targetNode) {

return function (e, data) {
if (IMParts_Catalog.jquery_fileupload.fileExtRequirements) {
let hasMatchExt = false
for (const ext of IMParts_Catalog.jquery_fileupload.fileExtRequirements) {
if (new RegExp(`\.(${ext})$/i`).test(data.files[0].name)) {
hasMatchExt = true
}
}
if (!hasMatchExt) {
return
}
}
$('#' + idValue + '-filename').text(data.files[0].name)

@@ -290,6 +302,17 @@ $('#' + idValue + '-filenamearea').css('display', 'block')

let targetFile = data.files[0], sign, another, previewNode
if (IMParts_Catalog.jquery_fileupload.fileExtRequirements) {
let hasMatchExt = false
for (const ext of IMParts_Catalog.jquery_fileupload.fileExtRequirements) {
if (new RegExp(`\.(${ext})$/i`).test(targetFile.name)) {
hasMatchExt = true
}
}
if (!hasMatchExt) {
return
}
}
$('#' + idValue + '-filenamearea').css('display', 'block')
if (!Array.isArray(IMParts_Catalog.jquery_fileupload.values[idValue])) {
const fnStr = $('#' + idValue + '-filename').text()
if(fnStr){
if (fnStr) {
$('#' + idValue + '-filename').text(`${fnStr}, ${targetFile.name}`)

@@ -296,0 +319,0 @@ } else {

7

package.json
{
"name": "inter-mediator-plugin-jqueryfileupload",
"version": "1.2.4",
"version": "1.3.0",
"description": "INTER-Mediator plug-in to use the JQuery FileUpload.",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
"test": "node_modules/jest/bin/jest.js test.js"
},

@@ -18,2 +18,5 @@ "repository": {

],
"devDependencies": {
"jest": ">=26.6.3"
},
"dependencies": {

@@ -20,0 +23,0 @@ },

@@ -1,2 +0,2 @@

# inter-mediator-plugin-jqueryfileupload
# inter-mediator-plugin-jqueryfileupload [![Build Status](https://github.com/INTER-Mediator/inter-mediator-plugin-jqueryfileupload/actions/workflows/node.js.yml/badge.svg)](https://github.com/INTER-Mediator/inter-mediator-plugin-jqueryfileupload/actions/workflows/node.js.yml)
INTER-Mediator plug-in to use the JQuery FileUpload.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc