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

@nozbe/zacs

Package Overview
Dependencies
Maintainers
8
Versions
44
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nozbe/zacs - npm Package Compare versions

Comparing version 1.1.0-12 to 1.1.0-13

2

package.json
{
"name": "@nozbe/zacs",
"version": "1.1.0-12",
"version": "1.1.0-13",
"description": "Zero Abstraction Cost Styling (for React DOM and React Native)",

@@ -5,0 +5,0 @@ "main": "src/index.js",

@@ -761,5 +761,14 @@ /* eslint-disable no-use-before-define */

properties.forEach(property => {
if (t.isSpreadElement(property.node)) {
const spreadArg = property.get('argument')
if (!t.isObjectExpression(spreadArg.node)) {
throw spreadArg.buildCodeFrameError("Spread element in a ZACS StyleSheet must be a simple object literal, like so: `{ height: 100, ...{ width: 200 } }`. Other syntaxes, like `...styles` are not allowed.")
}
validateStyleset(t, spreadArg)
return
}
if (!isPlainObjectProperty(t, property.node, true)) {
throw property.buildCodeFrameError(
'ZACS StyleSheets style attributes must be simple strings, like so: `{ backgroundColor: \'red\', height: 100 }`. Other syntaxes, like `[propName]:`, `...styles` are not allowed.',
'ZACS StyleSheets style attributes must be simple strings, like so: `{ backgroundColor: \'red\', height: 100 }`. Other syntaxes, like `[propName]:` are not allowed.',
)

@@ -855,2 +864,6 @@ }

function encodeCSSStyle(property, spaces = ' ') {
if (property.type === 'SpreadElement') {
return encodeCSSStyles(property.argument, spaces)
}
const { value } = property

@@ -907,2 +920,7 @@

styleset.value.properties.forEach(property => {
if (property.type === 'SpreadElement') {
pushFromInner(property.argument)
return
}
const key = property.key.name

@@ -909,0 +927,0 @@ if (key === 'web' || key === 'css') {

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