amotify 0.2.125 → 0.2.127

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.
@@ -6,22 +6,17 @@ import $$ from 'jmini'
6
6
 
7
7
  import {
8
8
  Config,
9
- ReactElement,
10
9
  Row,
10
+ Card,
11
11
  useRouterEffect,
12
12
  LaunchReactApp,
13
- RootViewController,
14
- FAI,
15
- Column,
16
13
  Input,
17
14
  Box,
18
- Span,
15
+ Anchor,
19
16
  pageRouter,
20
- Img,
21
- Text,
22
- Sheet,
23
17
  Button,
24
- Tooltips
18
+ Plate,
19
+ Column,
25
20
  } from 'amotify'
26
21
 
27
22
  import '../../dist/@styles/style.css'
@@ -32,70 +27,62 @@ import {
32
27
 
33
28
  let Test = () => {
34
29
  return <Box>
30
+ <Plate padding={ 4 }>
31
+ <Column>
32
+ <Card>
33
+ Hello World
34
+ </Card>
35
+ <Card.Border>
36
+ Hello World
37
+ </Card.Border>
38
+ <Card.Cloud>
39
+ Hello World
40
+ </Card.Cloud>
41
+ <Card.Plain>
42
+ Hello World
43
+ </Card.Plain>
44
+ <Card.Shadow>
45
+ Hello World
46
+ </Card.Shadow>
47
+ </Column>
48
+ </Plate>
35
49
  {/* <DesignBook
36
50
  /> */}
37
- <Row.Center
38
- flexCenter
39
- padding={ 3 }
40
- gap={ 3 }
41
- backgroundColor='layer.0'
51
+
52
+ {/* <Row.Center
53
+ padding={ 2 }
42
54
  >
43
- <Input.Select
44
- options={ [
45
- { value: 'AAA',label: 'AAA' },
46
- { value: 'BBB',label: 'BBB' },
47
- { value: 'CCC',label: 'CCC' },
48
- ] }
49
- />
50
- <Input.Select
51
- SelectorMode='legacy'
52
- options={ [
53
- { value: 'AAA',label: 'AAA' },
54
- { value: 'BBB',label: 'BBB' },
55
- { value: 'CCC',label: 'CCC' },
56
- ] }
57
- name='test'
58
- form='test'
59
- required
60
- onUpdateValidValue={ value => {
61
- console.log( value )
62
- } }
63
- onUpdateValue={ value => {
64
- console.log( value )
65
- } }
66
- />
67
- <Button.Prime
68
- submitOption={ {
69
- formName: 'test',
70
- callback: form => {
71
- console.log( form )
72
- }
73
- } }
55
+ <a href='#section1'>
56
+ #Section1
57
+ </a>
58
+ <a href='#section2'>
59
+ #Section2
60
+ </a>
61
+ <Anchor.Prime
62
+ href='#section1'
74
63
  >
75
- Submit
76
- </Button.Prime>
77
-
78
- {/* <Box
79
- ssSquare={ 12 }
80
- backgroundColor='layer.0'
81
- />
82
- <Box
83
- ssSquare={ 12 }
84
- backgroundColor='layer.1'
85
- />
86
- <Box
87
- ssSquare={ 12 }
88
- backgroundColor='layer.2'
89
- />
90
- <Box
91
- ssSquare={ 12 }
92
- backgroundColor='layer.3'
93
- />
94
- <Box
95
- ssSquare={ 12 }
96
- backgroundColor='cloud'
97
- /> */}
64
+ #Section1
65
+ </Anchor.Prime>
66
+ <Anchor.Prime
67
+ href='#section2'
68
+ >
69
+ #Section2
70
+ </Anchor.Prime>
98
71
  </Row.Center>
72
+ <Box
73
+ id='section1'
74
+ backgroundColor='posi'
75
+ height={ 'viewHeight' }
76
+ >
77
+ #section1
78
+ </Box>
79
+ <Box
80
+ id='section2'
81
+ backgroundColor='nega'
82
+ height={ 'viewHeight' }
83
+ >
84
+ #section2
85
+ </Box> */}
99
86
  </Box>
100
87
  }
101
88
 
@@ -106,11 +93,11 @@ $$.scope( () => {
106
93
 
107
94
  Config.launch( {
108
95
  appRoot: root,
109
- roundness: 3,
96
+ roundness: 4,
110
97
 
111
98
  themeColor: $$.localStrage.get( 'prf.themeColor' ) || 'battery',
112
- // darkMode: $$.getLocalStrageData( 'prf.darkMode' ) || 'dark'
113
- // darkMode: 'dark'
99
+ // darkMode: $$.getLocalStrageData( 'prf.darkMode' ) || 'dark',
100
+ // darkMode: 'dark',
114
101
  // darkMode: 'dim'
115
102
  } )
116
103
 
@@ -118,7 +105,13 @@ $$.scope( () => {
118
105
  let useLocation = ReactRouterDOM.useLocation()
119
106
  let useNavigate = ReactRouterDOM.useNavigate()
120
107
  useEffect( () => {
121
- pageRouter.setPushEffect( ( url ) => {
108
+ pageRouter.setPushEffect( url => {
109
+ if ( url.match( /^#/ ) ) {
110
+ console.log( url )
111
+ console.log( window.location.pathname )
112
+ // useNavigate( url )
113
+ return
114
+ }
122
115
  useNavigate( url )
123
116
  } )
124
117
  pageRouter.setBackEffect( () => {
@@ -1141,17 +1141,14 @@ const Buttons = {
1141
1141
  <Button.Prime>
1142
1142
  Button.Prime
1143
1143
  </Button.Prime>
1144
- Button.Button.Prime
1145
1144
  </>,<>
1146
1145
  <Button.Sub>
1147
1146
  Button.Sub
1148
1147
  </Button.Sub>
1149
- Button.Button.Sub
1150
1148
  </>,<>
1151
1149
  <Button.Border>
1152
1150
  Button.Border
1153
1151
  </Button.Border>
1154
- Button.Button.Border
1155
1152
  </>
1156
1153
  ] }
1157
1154
  />
@@ -1264,7 +1261,7 @@ const Shadows = {
1264
1261
  let Cell = ( p: Box.DefaultInput ) => {
1265
1262
  return <Box
1266
1263
  flexCenter
1267
- ssCardBox={ 'layer' }
1264
+ ssCardBox={ 'plain' }
1268
1265
  textAlign={ 'center' }
1269
1266
  padding={ 2 }
1270
1267
  { ...p }
@@ -2054,13 +2051,14 @@ text5`}
2054
2051
  </>
2055
2052
  }
2056
2053
  const Styling = () => {
2057
- const SheetContent = ( type: Sheet.Sheet,index?: number ) => {
2054
+ const SheetContent = ( type: Sheet.Sheet,index?: number,opt?: Partial<Sheet.Input> ) => {
2058
2055
  let sheetID = 'testModal' + index
2059
2056
  Sheet.open( {
2060
2057
  type,
2061
2058
  sheetID: sheetID,
2062
2059
  size: 'S',
2063
2060
  padding: 2,
2061
+ ...opt,
2064
2062
  content: <Sheet.Body padding={ 1 }>
2065
2063
  <Box padding={ 2 }>
2066
2064
  Content { index || 0 }
@@ -2309,7 +2307,9 @@ const Styling = () => {
2309
2307
  </Button.Border>
2310
2308
  <Button.Border
2311
2309
  onClick={ () => {
2312
- SheetContent( 'drawer.bottom' )
2310
+ SheetContent( 'drawer.bottom',10,{
2311
+ size: 'R'
2312
+ } )
2313
2313
  } }
2314
2314
  >
2315
2315
  Drawer Bottom
@@ -2322,7 +2322,6 @@ const Styling = () => {
2322
2322
  Drawer Right
2323
2323
  </Button.Border>
2324
2324
 
2325
-
2326
2325
  <Button.Border
2327
2326
  onClick={ ( event ) => {
2328
2327
  Tooltips.open( {
@@ -2399,7 +2398,6 @@ const Tables = {
2399
2398
  let styles: StyleTags.Properties = {}
2400
2399
 
2401
2400
  if ( args.isHeader ) {
2402
- console.log( 'AAA' )
2403
2401
  styles = {
2404
2402
  ...styles,
2405
2403
  backgroundColor: 'cloud'