@symbo.ls/preview 2.7.12 → 2.7.13
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
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@symbo.ls/preview",
|
|
3
3
|
"description": "",
|
|
4
4
|
"author": "symbo.ls",
|
|
5
|
-
"version": "2.7.
|
|
5
|
+
"version": "2.7.13",
|
|
6
6
|
"main": "src/app.js",
|
|
7
7
|
"scripts": {
|
|
8
8
|
"link:all": "yarn link smbls domql css-in-props @symbo.ls/icons @symbo.ls/config @symbo.ls/components @symbo.ls/scratch @symbo.ls/playground @symbo.ls/utils @symbo.ls/init @symbo.ls/config-default @domql/router @domql/utils @domql/router",
|
|
@@ -19,7 +19,7 @@ export const Personalize = {
|
|
|
19
19
|
HeaderHeading: {
|
|
20
20
|
props: { margin: '- - D1 -' },
|
|
21
21
|
Caption: { text: `Let's personalize your Symbols` },
|
|
22
|
-
H1: { text: ({ state }) => `Hi ${state.userName || ''}` }
|
|
22
|
+
H1: { text: ({ state }) => `Hi ${(state.userName && state.userName.split(' ')[0]) || ''}` }
|
|
23
23
|
},
|
|
24
24
|
|
|
25
25
|
ColumnParagraphs: {
|
|
@@ -27,7 +27,8 @@ const iconMap = {
|
|
|
27
27
|
const getTypeProp = (key, prop, library, defaultValue) => {
|
|
28
28
|
const { TYPOGRAPHY } = library
|
|
29
29
|
if (!TYPOGRAPHY) return
|
|
30
|
-
|
|
30
|
+
let styles = TYPOGRAPHY.styles
|
|
31
|
+
if (!styles) styles = TYPOGRAPHY.styles = {}
|
|
31
32
|
if (!styles[key]) styles[key] = {}
|
|
32
33
|
return styles[key][prop] ||
|
|
33
34
|
styles[prop] ||
|
|
@@ -54,7 +55,7 @@ const getCollectionFromArray = (arr, s) => {
|
|
|
54
55
|
const { __projectSystem } = s
|
|
55
56
|
const { TYPOGRAPHY } = __projectSystem
|
|
56
57
|
if (!TYPOGRAPHY) return
|
|
57
|
-
const
|
|
58
|
+
const styles = TYPOGRAPHY.styles || {}
|
|
58
59
|
return arr.map((v, k) => {
|
|
59
60
|
const result = getTypeStyle(v, __projectSystem)
|
|
60
61
|
return {
|
|
@@ -87,7 +88,8 @@ export const tagsCollection = (el, s) => {
|
|
|
87
88
|
const { __projectSystem } = s
|
|
88
89
|
const { TYPOGRAPHY } = __projectSystem
|
|
89
90
|
if (!TYPOGRAPHY) return
|
|
90
|
-
|
|
91
|
+
let styles = TYPOGRAPHY.styles
|
|
92
|
+
if (!styles) styles = TYPOGRAPHY.styles = {}
|
|
91
93
|
if (!styles.body) styles.body = {}
|
|
92
94
|
el.removeContent()
|
|
93
95
|
|