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

@symbo.ls/atoms

Package Overview
Dependencies
Maintainers
0
Versions
218
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@symbo.ls/atoms - npm Package Compare versions

Comparing version 2.11.475 to 2.11.477

Hgroup.js

50

Collection.js
'use strict'
import { isState, getChildStateInKey } from '@domql/state'
import { isString, isNot, isArray, isObject, isObjectLike, exec, deepClone, addAdditionalExtend } from '@domql/utils'
import { isString, isNumber, isNot, isArray, isObject, isObjectLike, exec, deepClone, addAdditionalExtend } from '@domql/utils'

@@ -10,30 +10,30 @@ export const Collection = {

const { __ref: ref } = el
const { children, childrenAs, childExtends } = (el.props || {})
const childrenExec = children && exec(children, el, state)
const { children: childrenProps, childrenAs, childExtends } = (el.props || {})
const children = childrenProps && exec(childrenProps, el, state)
if (isArray(childrenExec)) {
param = deepClone(childrenExec)
if (childrenAs) param = param.map(v => ({ extend: childExtends, [childrenAs]: v }))
} else if (isObject(childrenExec)) {
if (childrenExec.$$typeof) return el.call('renderReact', childrenExec, el)
param = deepClone(childrenExec)
param = Object.keys(param).map(v => {
const val = param[v]
return addAdditionalExtend(v, val)
})
el.removeContent()
el.content = {
extend: childExtends,
props: {
childProps: el.props && el.props.childProps
if (children) {
if (isObject(children)) {
if (children.$$typeof) return el.call('renderReact', children, el)
param = deepClone(children)
param = Object.keys(param).map(v => {
const val = param[v]
return addAdditionalExtend(v, val)
})
} else if (isArray(children)) {
param = deepClone(children)
if (childrenAs) {
param = param.map(v => ({
extend: childExtends,
[childrenAs]: v
}))
}
} else if (isString(children) || isNumber(children)) {
el.removeContent()
el.content = { text: param }
return
}
return
} else if (childrenExec) {
el.removeContent()
el.content = { text: param }
return
}
if (!param) return
const filterReact = param.filter(v => !v.$$typeof)

@@ -43,4 +43,3 @@ if (filterReact.length !== param.length) {

el.call('renderReact', extractedReactComponents, el)
}
param = filterReact
} param = filterReact

@@ -72,2 +71,3 @@ if (isString(param)) {

props: {
ignoreChildProps: true,
childProps: el.props && el.props.childProps

@@ -74,0 +74,0 @@ }

{
"name": "@symbo.ls/atoms",
"version": "2.11.475",
"version": "2.11.477",
"main": "index.js",
"license": "MIT",
"gitHead": "d2198b5f44d161e2cf0dd8a9d88a5301192bcb02",
"gitHead": "47546f8e3e61900fb07e92c3faf7abf2bce919ae",
"dependencies": {

@@ -8,0 +8,0 @@ "@domql/state": "^2.5.0",

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