@symbo.ls/preview 0.0.71 → 0.0.72

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": "",
5
- "version": "0.0.71",
5
+ "version": "0.0.72",
6
6
  "repository": "https://github.com/rackai/editor",
7
7
  "main": "src/index.js",
8
8
  "scripts": {
package/src/app.js CHANGED
@@ -1,9 +1,10 @@
1
1
  'use strict'
2
2
 
3
3
  import './config'
4
+ import style from './style'
4
5
 
5
6
  import { router } from '@domql/router'
6
- import { openModal } from '@symbo.ls/components'
7
+ import { Flex, openModal } from '@symbo.ls/components'
7
8
 
8
9
  import { state } from './state'
9
10
  import {
@@ -31,19 +32,10 @@ Object.keys(DesignSystem.routes).map(route => {
31
32
 
32
33
  const App = {
33
34
  key: 'app',
34
- extend: [Sync],
35
+ extend: Flex,
35
36
 
36
37
  state,
37
-
38
- props: {
39
- theme: 'document',
40
- boxSize: '100% 100%',
41
- position: 'absolute',
42
- top: '0',
43
- left: '0',
44
- flexFlow: 'column',
45
- flexAlign: 'center flex-start'
46
- },
38
+ props: style,
47
39
 
48
40
  define: { routes: param => param },
49
41
  routes: {
@@ -55,9 +47,7 @@ const App = {
55
47
  ...SUB_ROUTES
56
48
  },
57
49
 
58
- content: {
59
- props: { position: 'relative' }
60
- },
50
+ content: {},
61
51
 
62
52
  Modal: {},
63
53
 
@@ -1,5 +1,8 @@
1
1
  'use strict'
2
2
 
3
+ import { router } from '@domql/router'
4
+ import { HeaderInitial, HeaderOfMember } from '@symbo.ls/components'
5
+
3
6
  export const Header = {
4
7
  props: {
5
8
  position: 'sticky',
@@ -12,6 +15,23 @@ export const Header = {
12
15
  width: '100%'
13
16
  }
14
17
  }
18
+ }
19
+
20
+ export const HeaderOnRouter = {
21
+ extend: Header,
22
+ props: { width: '100%' },
15
23
 
16
- // define: { isFloating: param => param }
24
+ define: { routes: param => param },
25
+ routes: {
26
+ '/': HeaderInitial,
27
+ '/*': HeaderOfMember
28
+ },
29
+
30
+ on: {
31
+ render: element => {
32
+ const { pathname, hash } = window.location
33
+ const url = pathname + hash
34
+ router(element, url, {}, { updateState: false })
35
+ }
36
+ }
17
37
  }
@@ -54,16 +54,26 @@ export const DisabledPage = {
54
54
  }
55
55
  },
56
56
 
57
- H3: {
58
- margin: 'auto auto 0',
59
- padding: 'C1',
60
- color: 'black',
61
- width: '100%',
62
- maxWidth: 'J-default',
63
- text: 'Custom library will come up',
64
- animation: 'fadeInUpShort',
65
- animationDuration: 'G',
66
- animationDelay: 'G'
57
+ message: {
58
+ props: {
59
+ animation: 'fadeInUpShort',
60
+ animationDuration: 'G',
61
+ animationDelay: 'G',
62
+ margin: 'auto auto 0',
63
+ padding: 'C1 E C',
64
+ color: 'black',
65
+ width: '100%',
66
+ maxWidth: 'K-default'
67
+ },
68
+
69
+ H3: 'Custom library will come up soon',
70
+ P: {
71
+ text: 'Meanwhile, please check the components page',
72
+ margin: 'X 0 0',
73
+ animation: 'fadeInUpShort',
74
+ animationDuration: 'G',
75
+ animationDelay: 'G2'
76
+ }
67
77
  }
68
78
  }
69
79
  }
package/src/index.js CHANGED
@@ -3,7 +3,6 @@
3
3
  import './config'
4
4
  import DOM from 'domql'
5
5
  import SYMBOLS_CONF from '@symbo.ls/config'
6
- import style from './style'
7
6
 
8
7
  import 'smbls'
9
8
  import * as smbls from '@symbo.ls/components'
@@ -14,6 +13,7 @@ import { DesignSystem, Library } from './pages' // eslint-disable-line
14
13
  import { router, lastLevel } from '@domql/router'
15
14
 
16
15
  import { context } from './state'
16
+ import { Sync } from './sync'
17
17
 
18
18
  smbls.init({ verbose: false, ...SYMBOLS_CONF })
19
19
 
@@ -25,29 +25,12 @@ DOM.define({
25
25
 
26
26
  // export default DOM.create(App, DevFocus, 'app', { TODO: try this
27
27
  const app = DOM.create({
28
- extend: App,
29
- style,
28
+ // extend: [Sync, App],
29
+ extend: [App],
30
30
 
31
- Header: {
32
- props: {},
31
+ HeaderOnRouter: {},
33
32
 
34
- define: { routes: param => param },
35
- routes: {
36
- '/': smbls.HeaderInitial,
37
- '/*': smbls.HeaderOfMember
38
- },
39
-
40
- on: {
41
- render: element => {
42
- const { pathname, hash } = window.location
43
- const url = pathname + hash
44
- router(element, url, {}, { updateState: false })
45
- }
46
- }
47
- },
48
- routes: {
49
- // '/': Library
50
- }
33
+ routes: {}
51
34
  }, undefined, 'app', {
52
35
  extend: [smbls.Box],
53
36
  components: { ...smbls, ...components },
@@ -26,7 +26,6 @@ export const Spaces = {
26
26
  }
27
27
  },
28
28
  stateUpdated: (el, s, changes) => {
29
- console.log(s)
30
29
  s.systemUpdate({ SPACING: { base: s.base, ratio: s.ratio } }, { preventUpdate: true })
31
30
  }
32
31
  }
package/src/style.js CHANGED
@@ -1,11 +1,20 @@
1
1
  'use strict'
2
2
 
3
3
  export default {
4
+ theme: 'document',
5
+ boxSize: '100% 100%',
6
+ position: 'absolute',
7
+ top: '0',
8
+ left: '0',
9
+ flow: 'column',
10
+ align: 'center flex-start',
11
+ overflow: 'hidden auto',
4
12
  boxSizing: 'border-box',
5
- overflow: 'hidden',
6
- overflowY: 'auto',
7
13
  cursor: 'default',
8
- 'button, a': {
9
- cursor: 'default'
10
- }
14
+ style: {
15
+ 'button, a': {
16
+ cursor: 'default'
17
+ }
18
+ },
19
+ content: { position: 'relative' }
11
20
  }