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

bulkjs

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bulkjs - npm Package Compare versions

Comparing version 0.1.1 to 0.1.4

.eslintrc.json

28

bulk.js

@@ -8,3 +8,2 @@ /*global require, module */

var isSelectedAll = false;
var selected = [];

@@ -18,4 +17,4 @@ var source = [];

mark: function(item_uuid, event) {
if (isSelectedAll) {
isSelectedAll = false;
if (selected.indexOf(item_uuid) > -1) {
return;
}

@@ -25,8 +24,4 @@

if (source.length == selected.length) {
isSelectedAll = true;
}
if (opts.update) {
opts.update(scope, event, 'mark');
opts.update(scope, event, "mark");
}

@@ -36,22 +31,19 @@ },

selected = selected.filter(filter);
isSelectedAll = false;
if (opts.update) {
opts.update(scope, event, 'unmark');
opts.update(scope, event, "unmark");
}
},
markAll: function(event) {
isSelectedAll = true;
selected = source.map(opts.toId);
if (opts.update) {
opts.update(scope, event, 'markAll');
opts.update(scope, event, "markAll");
}
},
cleanAll: function(event) {
isSelectedAll = false;
selected = [];
if (opts.update) {
opts.update(scope, event, 'cleanAll');
opts.update(scope, event, "cleanAll");
}

@@ -71,6 +63,6 @@ },

toogleAll: function(event) {
if (!isSelectedAll) {
this.markAll(event, 'markAll');
if (!this.all()) {
this.markAll(event, "markAll");
} else {
this.cleanAll(event, 'cleanAll');
this.cleanAll(event, "cleanAll");
}

@@ -85,3 +77,3 @@ },

all: function() {
return isSelectedAll;
return source.length == selected.length;
},

@@ -88,0 +80,0 @@ count: function() {

{
"name": "bulkjs",
"version": "0.1.1",
"version": "0.1.4",
"description": "manager for multiple selection.",

@@ -5,0 +5,0 @@ "main": "bulk.js",

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