smbls 0.13.5 → 0.13.6
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/package.json +3 -2
- package/src/Box.js +2 -2
- package/src/Icon.js +1 -6
- package/src/Interaction.js +2 -1
- package/src/Media.js +1 -1
- package/src/XYZ.js +7 -0
- package/src/index.js +1 -0
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "UI Library built on Scratch and DOMQL",
|
|
4
4
|
"private": false,
|
|
5
5
|
"author": "symbo.ls",
|
|
6
|
-
"version": "0.13.
|
|
6
|
+
"version": "0.13.6",
|
|
7
7
|
"repository": "https://github.com/symbo-ls/smbls",
|
|
8
8
|
"main": "src/index.js",
|
|
9
9
|
"files": [
|
|
@@ -23,7 +23,8 @@
|
|
|
23
23
|
"dependencies": {
|
|
24
24
|
"@domql/utils": "latest",
|
|
25
25
|
"@symbo.ls/init": "latest",
|
|
26
|
-
"@symbo.ls/scratch": "latest"
|
|
26
|
+
"@symbo.ls/scratch": "latest",
|
|
27
|
+
"@symbo.ls/utils": "latest"
|
|
27
28
|
},
|
|
28
29
|
"devDependencies": {
|
|
29
30
|
"@babel/core": "^7.11.5",
|
package/src/Box.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict'
|
|
2
2
|
|
|
3
|
-
import { Shape, Position, Theme, Block, Text, Overflow, Transition, Transform, Responsive, Interaction } from '.'
|
|
3
|
+
import { Shape, Position, Theme, Block, Text, Overflow, Transition, Transform, Responsive, Interaction, XYZ } from '.'
|
|
4
4
|
|
|
5
5
|
const PropsCSS = {
|
|
6
6
|
class: {
|
|
@@ -9,5 +9,5 @@ const PropsCSS = {
|
|
|
9
9
|
}
|
|
10
10
|
|
|
11
11
|
export const Box = {
|
|
12
|
-
extend: [Shape, Position, Theme, Block, Text, Overflow, Transition, Transform, Responsive, PropsCSS, Interaction]
|
|
12
|
+
extend: [Shape, Position, Theme, Block, Text, Overflow, Transition, Transform, Responsive, PropsCSS, Interaction, XYZ]
|
|
13
13
|
}
|
package/src/Icon.js
CHANGED
|
@@ -3,12 +3,7 @@
|
|
|
3
3
|
import { SVG } from '.'
|
|
4
4
|
|
|
5
5
|
import { ICONS } from '@symbo.ls/scratch'
|
|
6
|
-
|
|
7
|
-
function camelize (str) {
|
|
8
|
-
return str.replace(/(?:^\w|[A-Z]|\b\w)/g, function (word, index) {
|
|
9
|
-
return index === 0 ? word.toLowerCase() : word.toUpperCase()
|
|
10
|
-
}).replace(/\s+/g, '')
|
|
11
|
-
}
|
|
6
|
+
import { camelize } from '@symbo.ls/utils'
|
|
12
7
|
|
|
13
8
|
export const Icon = {
|
|
14
9
|
extend: SVG,
|
package/src/Interaction.js
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
export const Interaction = {
|
|
4
4
|
class: {
|
|
5
|
-
|
|
5
|
+
pointerEvents: ({ props }) => props.pointerEvents && ({ pointerEvents: props.pointerEvents }),
|
|
6
|
+
cursor: ({ props }) => props.cursor && ({ cursor: props.cursor })
|
|
6
7
|
}
|
|
7
8
|
}
|
package/src/Media.js
CHANGED
|
@@ -119,7 +119,7 @@ export const initUpdate = element => {
|
|
|
119
119
|
for (const key in props) {
|
|
120
120
|
const setter = keySetters[key.slice(0, 1)]
|
|
121
121
|
if (key === 'theme') {
|
|
122
|
-
props.update({ themeModifier: globalTheme }, { preventRecursive: true, ignoreInitUpdate: true })
|
|
122
|
+
props.update({ themeModifier: `@${globalTheme}` }, { preventRecursive: true, ignoreInitUpdate: true })
|
|
123
123
|
} else if (key === 'true') applyTrueProps(props[key], CLASS_NAMES, element)
|
|
124
124
|
|
|
125
125
|
if (setter) setter(key, props[key], CLASS_NAMES, element)
|
package/src/XYZ.js
ADDED