New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@zag-js/toggle-group

Package Overview
Dependencies
Maintainers
1
Versions
579
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@zag-js/toggle-group - npm Package Compare versions

Comparing version 1.1.0 to 1.2.0

13

dist/index.js

@@ -281,9 +281,10 @@ 'use strict';

setValue({ context, event, prop }) {
if (!event.value) return;
const value = context.get("value");
let next = Array.from(value);
if (prop("multiple")) {
next = next.includes(event.value) ? utils.remove(next, event.value) : utils.add(next, event.value);
utils.ensureProps(event, ["value"]);
let next = context.get("value");
if (utils.isArray(event.value)) {
next = event.value;
} else if (prop("multiple")) {
next = utils.addOrRemove(next, event.value);
} else {
next = utils.isEqual(value, [event.value]) ? [] : [event.value];
next = utils.isEqual(next, [event.value]) ? [] : [event.value];
}

@@ -290,0 +291,0 @@ context.set("value", next);

{
"name": "@zag-js/toggle-group",
"version": "1.1.0",
"version": "1.2.0",
"description": "Core logic for the toggle widget implemented as a state machine",

@@ -29,7 +29,7 @@ "keywords": [

"dependencies": {
"@zag-js/anatomy": "1.1.0",
"@zag-js/dom-query": "1.1.0",
"@zag-js/utils": "1.1.0",
"@zag-js/core": "1.1.0",
"@zag-js/types": "1.1.0"
"@zag-js/anatomy": "1.2.0",
"@zag-js/dom-query": "1.2.0",
"@zag-js/utils": "1.2.0",
"@zag-js/core": "1.2.0",
"@zag-js/types": "1.2.0"
},

@@ -36,0 +36,0 @@ "devDependencies": {

Sorry, the diff of this file is not supported yet

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