@symbo.ls/atoms 2.11.325 → 2.11.332

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/Block.js CHANGED
@@ -1,6 +1,6 @@
1
1
  'use strict'
2
2
 
3
- import { isUndefined } from '@domql/utils'
3
+ import { isUndefined, isString } from '@domql/utils'
4
4
 
5
5
  import {
6
6
  getSpacingBasedOnRatio,
@@ -71,7 +71,7 @@ export const Block = {
71
71
  const [minHeight, minWidth] = props.heightRange.split(' ')
72
72
  return {
73
73
  ...deps.transformSize('minHeight', minHeight),
74
- ...deps.transformSize('minHeight', minWidth || minHeight)
74
+ ...deps.transformSize('minWidth', minWidth || minHeight)
75
75
  }
76
76
  },
77
77
 
@@ -80,7 +80,7 @@ export const Block = {
80
80
  const [maxHeight, maxWidth] = props.heightRange.split(' ')
81
81
  return {
82
82
  ...deps.transformSize('maxHeight', maxHeight),
83
- ...deps.transformSize('maxHeight', maxWidth || maxHeight)
83
+ ...deps.transformSize('maxWidth', maxWidth || maxHeight)
84
84
  }
85
85
  },
86
86
 
@@ -105,7 +105,7 @@ export const Block = {
105
105
  }
106
106
  },
107
107
  paddingBlock: ({ props, deps }) => {
108
- if (typeof props.paddingBlock !== 'string') return
108
+ if (!isString(props.paddingBlock)) return
109
109
  const [paddingBlockStart, paddingBlockEnd] = props.paddingBlock.split(' ')
110
110
  return {
111
111
  ...deps.transformSize('paddingBlockStart', paddingBlockStart),
package/Collection.js CHANGED
@@ -6,7 +6,11 @@ import { isString, isNot, isArray, isObject, isObjectLike, deepClone, deepCloneW
6
6
  export const Collection = {
7
7
  define: {
8
8
  $collection: (param, el, state) => {
9
- if (!param) return
9
+ const { __ref: ref } = el
10
+ const children = isArray(el.props?.children)
11
+
12
+ if (children) param = children
13
+ else if (!param) return
10
14
 
11
15
  if (isString(param)) {
12
16
  if (param === 'state') param = state.parse()
@@ -15,7 +19,6 @@ export const Collection = {
15
19
  if (isState(param)) param = param.parse()
16
20
  if (isNot(param)('array', 'object')) return
17
21
 
18
- const { __ref: ref } = el
19
22
  param = deepClone(param)
20
23
 
21
24
  if (ref.__collectionCache) {
package/Theme.js CHANGED
@@ -143,7 +143,7 @@ export const Theme = {
143
143
  const globalTheme = deps.getSystemTheme(element)
144
144
  if (!props.backgroundImage) return
145
145
  return ({
146
- boxShadow: deps.transformShadow(props.backgroundImage, globalTheme)
146
+ boxShadow: deps.transformShadow(props.shadow, globalTheme)
147
147
  })
148
148
  },
149
149
 
package/Timing.js CHANGED
@@ -5,6 +5,7 @@ import {
5
5
  splitTransition,
6
6
  transformDuration
7
7
  } from '@symbo.ls/scratch'
8
+
8
9
  import { isUndefined } from 'smbls'
9
10
 
10
11
  export const Timing = {
package/package.json CHANGED
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "name": "@symbo.ls/atoms",
3
- "version": "2.11.325",
3
+ "version": "2.11.332",
4
4
  "main": "index.js",
5
5
  "license": "MIT",
6
- "gitHead": "0ac8322ab9267498fbdcde2ade499be5e79b0478",
6
+ "gitHead": "5a8120f35d72a396dacf5f679a751e4475a81b2a",
7
7
  "dependencies": {
8
8
  "@domql/state": "latest",
9
9
  "@domql/utils": "latest",