react-native-boxes 1.0.5 → 1.0.7
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/dist/demo.js +78 -77
- package/dist/demo.js.map +1 -1
- package/package.json +1 -1
- package/src/demo.tsx +296 -295
package/dist/demo.js
CHANGED
|
@@ -43,7 +43,6 @@ function DemoScreen({ navigation }) {
|
|
|
43
43
|
const theme = (0, react_1.useContext)(_1.ThemeContext);
|
|
44
44
|
console.log('Rendering');
|
|
45
45
|
const btnIcon = (<FontAwesome_1.default name='google' size={theme.dimens.icon.md} color={theme.colors.invert.text}/>);
|
|
46
|
-
const insets = (0, react_native_safe_area_context_1.useSafeAreaInsets)();
|
|
47
46
|
const [loading, setLoading] = (0, react_1.useState)(false);
|
|
48
47
|
const [alert, setBs] = (0, react_1.useState)(`In this version, the icon used is always 'chevron-right' even when expanded.`);
|
|
49
48
|
const [bottomsheetVisible, setbottomsheetVisible] = (0, react_1.useState)(false);
|
|
@@ -62,14 +61,15 @@ function DemoScreen({ navigation }) {
|
|
|
62
61
|
forceUpdate();
|
|
63
62
|
}, [selectedTheme]);
|
|
64
63
|
const [, forceUpdate] = (0, react_1.useReducer)(x => x + 1, 0);
|
|
65
|
-
return (<
|
|
64
|
+
return (<react_native_safe_area_context_1.SafeAreaProvider>
|
|
65
|
+
<_1.VBox style={{
|
|
66
66
|
backgroundColor: theme.colors.background,
|
|
67
67
|
padding: 0,
|
|
68
68
|
paddingBottom: bottomBarHeight,
|
|
69
69
|
margin: 0,
|
|
70
70
|
height: '100%'
|
|
71
71
|
}}>
|
|
72
|
-
|
|
72
|
+
<_1.SimpleToolbar title="Demo" homeIcon={(0, utils_1.ReactWrapper)(<Image_1.Icon color={theme.colors.invert.text} name="plus"/>)} options={[
|
|
73
73
|
{
|
|
74
74
|
id: 'test',
|
|
75
75
|
icon: 'gear',
|
|
@@ -79,26 +79,26 @@ function DemoScreen({ navigation }) {
|
|
|
79
79
|
{
|
|
80
80
|
id: 'test2',
|
|
81
81
|
icon: (0, utils_1.ReactWrapper)(<_1.PressableView>
|
|
82
|
-
|
|
82
|
+
<Image_1.Avatar style={{
|
|
83
83
|
margin: 0,
|
|
84
84
|
height: theme.dimens?.icon?.md * 1.25,
|
|
85
85
|
width: theme.dimens?.icon?.md * 1.25,
|
|
86
86
|
}} iconUrl="https://avatars.githubusercontent.com/u/16799797?v=4"/>
|
|
87
|
-
|
|
87
|
+
</_1.PressableView>),
|
|
88
88
|
onClick: (id) => {
|
|
89
89
|
}
|
|
90
90
|
}
|
|
91
91
|
]}/>
|
|
92
|
-
|
|
92
|
+
<Box_1.default automaticallyAdjustKeyboardInsets={true} keyboardShouldPersistTaps={'handled'} style={{
|
|
93
93
|
flexGrow: 1,
|
|
94
94
|
}} nestedScrollEnabled={true} showsHorizontalScrollIndicator={false} showsVerticalScrollIndicator={false}>
|
|
95
95
|
|
|
96
|
-
|
|
96
|
+
<_1.Center style={{
|
|
97
97
|
flexDirection: 'row',
|
|
98
98
|
padding: 20
|
|
99
99
|
}}>
|
|
100
100
|
|
|
101
|
-
|
|
101
|
+
<Image_1.Avatar onPress={() => {
|
|
102
102
|
setbottomsheetVisible(true);
|
|
103
103
|
}} style={{
|
|
104
104
|
borderColor: theme.colors.success,
|
|
@@ -107,8 +107,8 @@ function DemoScreen({ navigation }) {
|
|
|
107
107
|
color: theme.colors.success,
|
|
108
108
|
size: theme.dimens.icon.lg
|
|
109
109
|
}}/>
|
|
110
|
-
|
|
111
|
-
|
|
110
|
+
<_1.Center>
|
|
111
|
+
<Image_1.Avatar style={{
|
|
112
112
|
borderWidth: theme.dimens.space.sm,
|
|
113
113
|
width: 100,
|
|
114
114
|
height: 100,
|
|
@@ -120,102 +120,102 @@ function DemoScreen({ navigation }) {
|
|
|
120
120
|
color: theme.colors.success,
|
|
121
121
|
size: theme.dimens.icon.lg
|
|
122
122
|
}} iconUrl='https://cdn.truelancer.com/user-picture/307510-5c1f11bad82e9.jpg'/>
|
|
123
|
-
|
|
124
|
-
|
|
123
|
+
<_1.Subtitle>{mText}</_1.Subtitle>
|
|
124
|
+
</_1.Center>
|
|
125
125
|
|
|
126
|
-
|
|
126
|
+
<Image_1.Avatar style={{
|
|
127
127
|
borderColor: theme.colors.success,
|
|
128
128
|
color: theme.colors.success
|
|
129
129
|
}} onPress={() => {
|
|
130
130
|
setbottomsheetVisible(true);
|
|
131
131
|
}} iconText='SN'/>
|
|
132
|
-
|
|
133
|
-
|
|
132
|
+
</_1.Center>
|
|
133
|
+
<_1.Expand title='Message Alert' initialExpand={false} style={{
|
|
134
134
|
backgroundColor: theme.colors.forground
|
|
135
135
|
}} titleBackgroundColor={theme.colors.forground}>
|
|
136
|
-
|
|
137
|
-
|
|
136
|
+
<_1.VBox>
|
|
137
|
+
<Message_1.AlertMessage text={alert} onDismiss={() => {
|
|
138
138
|
react_native_1.LayoutAnimation.configureNext(react_native_1.LayoutAnimation.Presets.easeInEaseOut);
|
|
139
139
|
setAlert('');
|
|
140
140
|
}}/>
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
141
|
+
<Message_1.AlertMessage text='Critial Message' type='critical'/>
|
|
142
|
+
<Message_1.AlertMessage text='Success' type='success'/>
|
|
143
|
+
<Message_1.AlertMessage text='Warning Message' type='warning'/>
|
|
144
|
+
</_1.VBox>
|
|
145
145
|
|
|
146
|
-
|
|
147
|
-
|
|
146
|
+
</_1.Expand>
|
|
147
|
+
<_1.Expand style={{
|
|
148
148
|
padding: 0,
|
|
149
149
|
borderWidth: 0.1,
|
|
150
150
|
borderColor: '#DCDCDC'
|
|
151
151
|
}} duration={200} title='In this version, the icon used is always chevron-right even when expanded. In this version, the icon used is always chevron-right even when expanded.' initialExpand={false} iconPosition='right'>
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
152
|
+
<_1.VBox>
|
|
153
|
+
<_1.Title>Text A</_1.Title>
|
|
154
|
+
<_1.Subtitle>Text A Text A Text AText A Text AText A</_1.Subtitle>
|
|
155
|
+
<_1.TextView>Text A</_1.TextView>
|
|
156
|
+
<_1.Caption>Text Caption</_1.Caption>
|
|
157
|
+
</_1.VBox>
|
|
158
|
+
</_1.Expand>
|
|
159
|
+
<_1.Expand title='Inputs'>
|
|
160
160
|
|
|
161
|
-
|
|
162
|
-
|
|
161
|
+
<_1.VBox>
|
|
162
|
+
<_1.TextInputView style={{
|
|
163
163
|
fontFamily: theme.fonts.Bold
|
|
164
164
|
}} initialText={mText} value={mText} onChangeText={t => setMText(t)}/>
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
165
|
+
<_1.CompositeTextInputView onChangeText={t => setMText(t)} placeholder='A test' initialText='Test'/>
|
|
166
|
+
<_1.CompositeTextInputView inputMode='decimal' icon={"close"} style={{}} alertTextColor={theme.colors.warning} placeholder='Enter your name' initialText='Test' value={mText} onChangeText={t => setMText(t)}/>
|
|
167
|
+
<_1.CompositeTextInputView style={{}} placeholder='Enter number' alertText={mText?.indexOf("@") > -1 ? '' : 'Please enter @ or else I am gonna come down at your place and mess you up buddy !'} initialText='Test' value={mText} onChangeText={t => setMText(t)}/>
|
|
168
|
+
</_1.VBox>
|
|
169
|
+
</_1.Expand>
|
|
170
170
|
|
|
171
|
-
|
|
171
|
+
<_1.Expand iconStyle={{
|
|
172
172
|
name: 'chevron-right',
|
|
173
173
|
color: 'red'
|
|
174
174
|
}} title='Buttons' initialExpand={false}>
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
175
|
+
<_1.VBox style={{}}>
|
|
176
|
+
<_1.VBox>
|
|
177
|
+
<_1.ButtonView icon={btnIcon} style={{}}>Button Icon</_1.ButtonView>
|
|
178
178
|
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
179
|
+
<_1.ButtonView style={{}}>Button Text</_1.ButtonView>
|
|
180
|
+
</_1.VBox>
|
|
181
|
+
<_1.RightIconButton text='Click Me Icon' icon={btnIcon}>
|
|
182
|
+
</_1.RightIconButton>
|
|
183
183
|
|
|
184
|
-
|
|
185
|
-
|
|
184
|
+
<_1.Center>
|
|
185
|
+
<_1.LoadingButton onPress={(e) => {
|
|
186
186
|
setLoading(!loading);
|
|
187
187
|
}} loading={loading} text='Click Me'/>
|
|
188
188
|
|
|
189
|
-
|
|
189
|
+
<_1.ButtonView underlayColor={theme.colors.transparent} style={{
|
|
190
190
|
color: theme.colors.accent,
|
|
191
191
|
backgroundColor: theme.colors.transparent,
|
|
192
192
|
}}>Tertiary button</_1.ButtonView>
|
|
193
193
|
|
|
194
|
-
|
|
194
|
+
</_1.Center>
|
|
195
195
|
|
|
196
|
-
|
|
197
|
-
|
|
196
|
+
<_1.Expand title='Nested expand'>
|
|
197
|
+
<_1.HBox style={{
|
|
198
198
|
justifyContent: 'center',
|
|
199
199
|
}}>
|
|
200
|
-
|
|
200
|
+
<_1.LoadingButton style={{
|
|
201
201
|
width: 'auto'
|
|
202
202
|
}} onPress={(e) => {
|
|
203
203
|
setLoading(!loading);
|
|
204
204
|
}} loading={loading} text='Click Me left'/>
|
|
205
|
-
|
|
205
|
+
<_1.LoadingButton loaderStyle='transparent' style={{
|
|
206
206
|
width: 'auto'
|
|
207
207
|
}} onPress={(e) => {
|
|
208
208
|
setLoading(!loading);
|
|
209
209
|
}} loading={loading} text='Click Me right'/>
|
|
210
|
-
|
|
211
|
-
|
|
210
|
+
</_1.HBox>
|
|
211
|
+
</_1.Expand>
|
|
212
212
|
|
|
213
|
-
|
|
214
|
-
|
|
213
|
+
</_1.VBox>
|
|
214
|
+
</_1.Expand>
|
|
215
215
|
|
|
216
216
|
|
|
217
217
|
|
|
218
|
-
|
|
218
|
+
<_1.ButtonView underlayColor={theme.colors.transparent} style={{
|
|
219
219
|
color: theme.colors.accent,
|
|
220
220
|
backgroundColor: theme.colors.transparent,
|
|
221
221
|
}} onPress={() => {
|
|
@@ -223,7 +223,7 @@ function DemoScreen({ navigation }) {
|
|
|
223
223
|
}}>{selectedTheme ? 'Light' : 'Dark'}</_1.ButtonView>
|
|
224
224
|
|
|
225
225
|
|
|
226
|
-
|
|
226
|
+
<_1.ButtonView underlayColor={theme.colors.transparent} style={{
|
|
227
227
|
color: theme.colors.accent,
|
|
228
228
|
backgroundColor: theme.colors.transparent,
|
|
229
229
|
}} onPress={() => {
|
|
@@ -231,8 +231,8 @@ function DemoScreen({ navigation }) {
|
|
|
231
231
|
}}>Show Sheet</_1.ButtonView>
|
|
232
232
|
|
|
233
233
|
|
|
234
|
-
|
|
235
|
-
|
|
234
|
+
</Box_1.default>
|
|
235
|
+
<_1.BottomNavBar style={{
|
|
236
236
|
borderTopLeftRadius: theme.dimens.space.md,
|
|
237
237
|
borderTopRightRadius: theme.dimens.space.md,
|
|
238
238
|
}} onSelect={setSelectedBottomBarId} selectedId={selectedBottombarId} options={[
|
|
@@ -255,7 +255,7 @@ function DemoScreen({ navigation }) {
|
|
|
255
255
|
id: 'profile',
|
|
256
256
|
title: 'Profile',
|
|
257
257
|
icon: (0, utils_1.ReactWrapper)(<_1.PressableView>
|
|
258
|
-
|
|
258
|
+
<Image_1.Avatar onPress={() => {
|
|
259
259
|
setSelectedBottomBarId('profile');
|
|
260
260
|
}} style={{
|
|
261
261
|
borderColor: selectedBottombarId == 'profile' ?
|
|
@@ -266,36 +266,37 @@ function DemoScreen({ navigation }) {
|
|
|
266
266
|
}}
|
|
267
267
|
// iconName='user'
|
|
268
268
|
iconUrl="https://avatars.githubusercontent.com/u/16799797?v=4"/>
|
|
269
|
-
|
|
269
|
+
</_1.PressableView>)
|
|
270
270
|
}
|
|
271
271
|
]} onDimens={(w, h) => {
|
|
272
272
|
setBottombarHeight(h);
|
|
273
273
|
console.log("bottomBarHeight", h);
|
|
274
274
|
}}/>
|
|
275
275
|
|
|
276
|
-
|
|
276
|
+
<Modal_1.BottomSheet title="About" visible={bottomsheetVisible} onDismiss={() => {
|
|
277
277
|
setbottomsheetVisible(false);
|
|
278
278
|
}}>
|
|
279
|
-
|
|
279
|
+
<_1.TextView>Dinosaurs are a diverse group of reptiles of the clade Dinosauria. They first appeared during the Triassic period, between 243 and 233.23 million years ago, although the exact origin and timing of the evolution of dinosaurs is a subject of active research.</_1.TextView>
|
|
280
280
|
|
|
281
|
-
|
|
282
|
-
|
|
281
|
+
<_1.TextView>Dinosaurs are a diverse group of reptiles of the clade Dinosauria. They first appeared during the Triassic period, between 243 and 233.23 million years ago, although the exact origin and timing of the evolution of dinosaurs is a subject of active research.</_1.TextView>
|
|
282
|
+
<_1.Expand title='Types' initialExpand={false} style={{
|
|
283
283
|
padding: 0,
|
|
284
284
|
backgroundColor: theme.colors.forground
|
|
285
285
|
}} titleBackgroundColor={theme.colors.forground}>
|
|
286
|
-
|
|
287
|
-
|
|
286
|
+
<_1.VBox>
|
|
287
|
+
<Message_1.AlertMessage text={alert} onDismiss={() => {
|
|
288
288
|
react_native_1.LayoutAnimation.configureNext(react_native_1.LayoutAnimation.Presets.easeInEaseOut);
|
|
289
289
|
setAlert('');
|
|
290
290
|
}}/>
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
291
|
+
<Message_1.AlertMessage text='Tyrannosaurus rex' type='critical'/>
|
|
292
|
+
<Message_1.AlertMessage text='Spinosaurus' type='success'/>
|
|
293
|
+
<Message_1.AlertMessage text='Ankylosaurs' type='warning'/>
|
|
294
|
+
</_1.VBox>
|
|
295
295
|
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
296
|
+
</_1.Expand>
|
|
297
|
+
</Modal_1.BottomSheet>
|
|
298
|
+
</_1.VBox>
|
|
299
|
+
</react_native_safe_area_context_1.SafeAreaProvider>);
|
|
299
300
|
}
|
|
300
301
|
exports.DemoScreen = DemoScreen;
|
|
301
302
|
//# sourceMappingURL=demo.js.map
|
package/dist/demo.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":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QAC9B,CAAC,CAAC,CACF;UAAA,CAAC,WAAQ,CAAC,gQAAgQ,EAAE,WAAQ,CAEpR;;UAAA,CAAC,WAAQ,CAAC,gQAAgQ,EAAE,WAAQ,CACpR;UAAA,CAAC,SAAM,CAAC,KAAK,CAAC,OAAO,CAAC,aAAa,CAAC,CAAC,KAAK,CAAC,CACzC,KAAK,CAAC,CAAC;YACL,OAAO,EAAE,CAAC;YACV,eAAe,EAAE,KAAK,CAAC,MAAM,CAAC,SAAS;SACxC,CAAC,CACF,oBAAoB,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC,SAAS,CAAC,CAE7C;YAAA,CAAC,OAAI,CACH;cAAA,CAAC,sBAAY,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,CAAC,SAAS,CAAC,CAAC,GAAG,EAAE;YACzC,8BAAe,CAAC,aAAa,CAAC,8BAAe,CAAC,OAAO,CAAC,aAAa,CAAC,CAAC;YACrE,QAAQ,CAAC,EAAE,CAAC,CAAA;QACd,CAAC,CAAC,EACF;cAAA,CAAC,sBAAY,CAAC,IAAI,CAAC,mBAAmB,CAAC,IAAI,CAAC,UAAU,EACtD;cAAA,CAAC,sBAAY,CAAC,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,SAAS,EAC/C;cAAA,CAAC,sBAAY,CAAC,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,SAAS,EACjD;YAAA,EAAE,OAAI,CAER;;UAAA,EAAE,SAAM,CACV;QAAA,EAAE,mBAAW,CACf;MAAA,EAAE,OAAI,CACR;IAAA,EAAE,iDAAgB,CAAC,CACpB,CAAC;AACJ,CAAC;AA9WD,gCA8WC"}
|
package/package.json
CHANGED
package/src/demo.tsx
CHANGED
|
@@ -3,7 +3,7 @@ import * as React from 'react'
|
|
|
3
3
|
import { LayoutAnimation, SafeAreaView } from 'react-native';
|
|
4
4
|
import { BottomNavBar, ButtonView, Caption, Center, CompositeTextInputView, Expand, HBox, LoadingButton, PressableView, RightIconButton, SimpleToolbar, Subtitle, TextInputView, TextView, Theme, ThemeContext, Title, VBox } from '.';
|
|
5
5
|
import FontAwesome from '@expo/vector-icons/FontAwesome';
|
|
6
|
-
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
6
|
+
import { SafeAreaProvider, useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
7
7
|
import { AlertMessage } from './Message';
|
|
8
8
|
import { BottomSheet } from './Modal';
|
|
9
9
|
import { Avatar, Icon } from './Image';
|
|
@@ -22,7 +22,6 @@ export function DemoScreen({ navigation }: DemoScreenProps) {
|
|
|
22
22
|
const btnIcon = (<FontAwesome name='google'
|
|
23
23
|
size={theme.dimens.icon.md}
|
|
24
24
|
color={theme.colors.invert.text} />)
|
|
25
|
-
const insets = useSafeAreaInsets();
|
|
26
25
|
const [loading, setLoading] = useState(false)
|
|
27
26
|
const [alert, setBs] = useState(`In this version, the icon used is always 'chevron-right' even when expanded.`)
|
|
28
27
|
const [bottomsheetVisible, setbottomsheetVisible] = useState(false)
|
|
@@ -44,340 +43,342 @@ export function DemoScreen({ navigation }: DemoScreenProps) {
|
|
|
44
43
|
const [, forceUpdate] = useReducer(x => x + 1, 0);
|
|
45
44
|
|
|
46
45
|
return (
|
|
47
|
-
<
|
|
48
|
-
|
|
49
|
-
backgroundColor: theme.colors.background,
|
|
50
|
-
padding: 0,
|
|
51
|
-
paddingBottom: bottomBarHeight,
|
|
52
|
-
margin: 0,
|
|
53
|
-
height: '100%'
|
|
54
|
-
}} >
|
|
55
|
-
<SimpleToolbar
|
|
56
|
-
title="Demo"
|
|
57
|
-
homeIcon={
|
|
58
|
-
ReactWrapper(<Icon color={theme.colors.invert.text} name="plus" />)
|
|
59
|
-
}
|
|
60
|
-
options={[
|
|
61
|
-
{
|
|
62
|
-
id: 'test',
|
|
63
|
-
icon: 'gear',
|
|
64
|
-
onClick: (id) => {
|
|
65
|
-
}
|
|
66
|
-
},
|
|
67
|
-
{
|
|
68
|
-
id: 'test2',
|
|
69
|
-
icon: ReactWrapper(<PressableView>
|
|
70
|
-
<Avatar
|
|
71
|
-
style={{
|
|
72
|
-
margin: 0,
|
|
73
|
-
height: theme.dimens?.icon?.md * 1.25,
|
|
74
|
-
width: theme.dimens?.icon?.md * 1.25,
|
|
75
|
-
}}
|
|
76
|
-
iconUrl="https://avatars.githubusercontent.com/u/16799797?v=4" />
|
|
77
|
-
</PressableView>),
|
|
78
|
-
onClick: (id) => {
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
]} />
|
|
82
|
-
<KeyboardAvoidingScrollView
|
|
83
|
-
automaticallyAdjustKeyboardInsets={true}
|
|
84
|
-
keyboardShouldPersistTaps={'handled'}
|
|
46
|
+
<SafeAreaProvider>
|
|
47
|
+
<VBox
|
|
85
48
|
style={{
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
49
|
+
backgroundColor: theme.colors.background,
|
|
50
|
+
padding: 0,
|
|
51
|
+
paddingBottom: bottomBarHeight,
|
|
52
|
+
margin: 0,
|
|
53
|
+
height: '100%'
|
|
54
|
+
}} >
|
|
55
|
+
<SimpleToolbar
|
|
56
|
+
title="Demo"
|
|
57
|
+
homeIcon={
|
|
58
|
+
ReactWrapper(<Icon color={theme.colors.invert.text} name="plus" />)
|
|
59
|
+
}
|
|
60
|
+
options={[
|
|
61
|
+
{
|
|
62
|
+
id: 'test',
|
|
63
|
+
icon: 'gear',
|
|
64
|
+
onClick: (id) => {
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
id: 'test2',
|
|
69
|
+
icon: ReactWrapper(<PressableView>
|
|
70
|
+
<Avatar
|
|
71
|
+
style={{
|
|
72
|
+
margin: 0,
|
|
73
|
+
height: theme.dimens?.icon?.md * 1.25,
|
|
74
|
+
width: theme.dimens?.icon?.md * 1.25,
|
|
75
|
+
}}
|
|
76
|
+
iconUrl="https://avatars.githubusercontent.com/u/16799797?v=4" />
|
|
77
|
+
</PressableView>),
|
|
78
|
+
onClick: (id) => {
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
]} />
|
|
82
|
+
<KeyboardAvoidingScrollView
|
|
83
|
+
automaticallyAdjustKeyboardInsets={true}
|
|
84
|
+
keyboardShouldPersistTaps={'handled'}
|
|
85
|
+
style={{
|
|
86
|
+
flexGrow: 1,
|
|
87
|
+
}}
|
|
88
|
+
nestedScrollEnabled={true}
|
|
89
|
+
showsHorizontalScrollIndicator={false}
|
|
90
|
+
showsVerticalScrollIndicator={false}
|
|
91
|
+
>
|
|
92
92
|
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
93
|
+
<Center style={{
|
|
94
|
+
flexDirection: 'row',
|
|
95
|
+
padding: 20
|
|
96
|
+
}}>
|
|
97
97
|
|
|
98
|
-
<Avatar
|
|
99
|
-
onPress={() => {
|
|
100
|
-
setbottomsheetVisible(true)
|
|
101
|
-
}}
|
|
102
|
-
style={{
|
|
103
|
-
borderColor: theme.colors.success,
|
|
104
|
-
}}
|
|
105
|
-
iconNameProps={{
|
|
106
|
-
name: 'user',
|
|
107
|
-
color: theme.colors.success,
|
|
108
|
-
size: theme.dimens.icon.lg
|
|
109
|
-
}}
|
|
110
|
-
/>
|
|
111
|
-
<Center>
|
|
112
98
|
<Avatar
|
|
113
|
-
style={{
|
|
114
|
-
borderWidth: theme.dimens.space.sm,
|
|
115
|
-
width: 100,
|
|
116
|
-
height: 100,
|
|
117
|
-
borderColor: theme.colors.success
|
|
118
|
-
}}
|
|
119
|
-
iconText='SN'
|
|
120
99
|
onPress={() => {
|
|
121
100
|
setbottomsheetVisible(true)
|
|
122
101
|
}}
|
|
102
|
+
style={{
|
|
103
|
+
borderColor: theme.colors.success,
|
|
104
|
+
}}
|
|
123
105
|
iconNameProps={{
|
|
124
106
|
name: 'user',
|
|
125
107
|
color: theme.colors.success,
|
|
126
108
|
size: theme.dimens.icon.lg
|
|
127
109
|
}}
|
|
128
|
-
|
|
129
|
-
<
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
<AlertMessage text={alert} onDismiss={() => {
|
|
150
|
-
LayoutAnimation.configureNext(LayoutAnimation.Presets.easeInEaseOut);
|
|
151
|
-
setAlert('')
|
|
152
|
-
}} />
|
|
153
|
-
<AlertMessage text='Critial Message' type='critical' />
|
|
154
|
-
<AlertMessage text='Success' type='success' />
|
|
155
|
-
<AlertMessage text='Warning Message' type='warning' />
|
|
156
|
-
</VBox>
|
|
157
|
-
|
|
158
|
-
</Expand>
|
|
159
|
-
<Expand
|
|
160
|
-
style={{
|
|
161
|
-
padding: 0,
|
|
162
|
-
borderWidth: 0.1,
|
|
163
|
-
borderColor: '#DCDCDC'
|
|
164
|
-
}}
|
|
165
|
-
duration={200}
|
|
166
|
-
title='In this version, the icon used is always chevron-right even when expanded. In this version, the icon used is always chevron-right even when expanded.'
|
|
167
|
-
initialExpand={false} iconPosition='right'>
|
|
168
|
-
<VBox>
|
|
169
|
-
<Title>Text A</Title>
|
|
170
|
-
<Subtitle>Text A Text A Text AText A Text AText A</Subtitle>
|
|
171
|
-
<TextView>Text A</TextView>
|
|
172
|
-
<Caption>Text Caption</Caption>
|
|
173
|
-
</VBox>
|
|
174
|
-
</Expand>
|
|
175
|
-
<Expand title='Inputs'>
|
|
110
|
+
/>
|
|
111
|
+
<Center>
|
|
112
|
+
<Avatar
|
|
113
|
+
style={{
|
|
114
|
+
borderWidth: theme.dimens.space.sm,
|
|
115
|
+
width: 100,
|
|
116
|
+
height: 100,
|
|
117
|
+
borderColor: theme.colors.success
|
|
118
|
+
}}
|
|
119
|
+
iconText='SN'
|
|
120
|
+
onPress={() => {
|
|
121
|
+
setbottomsheetVisible(true)
|
|
122
|
+
}}
|
|
123
|
+
iconNameProps={{
|
|
124
|
+
name: 'user',
|
|
125
|
+
color: theme.colors.success,
|
|
126
|
+
size: theme.dimens.icon.lg
|
|
127
|
+
}}
|
|
128
|
+
iconUrl='https://cdn.truelancer.com/user-picture/307510-5c1f11bad82e9.jpg' />
|
|
129
|
+
<Subtitle>{mText}</Subtitle>
|
|
130
|
+
</Center>
|
|
176
131
|
|
|
177
|
-
|
|
178
|
-
<TextInputView
|
|
179
|
-
style={{
|
|
180
|
-
fontFamily: theme.fonts.Bold
|
|
181
|
-
}}
|
|
182
|
-
initialText={mText}
|
|
183
|
-
value={mText}
|
|
184
|
-
onChangeText={t => setMText(t)} />
|
|
185
|
-
<CompositeTextInputView
|
|
186
|
-
onChangeText={t => setMText(t)}
|
|
187
|
-
placeholder='A test'
|
|
188
|
-
initialText='Test' />
|
|
189
|
-
<CompositeTextInputView
|
|
190
|
-
inputMode='decimal'
|
|
191
|
-
icon={"close"}
|
|
132
|
+
<Avatar
|
|
192
133
|
style={{
|
|
134
|
+
borderColor: theme.colors.success,
|
|
135
|
+
color: theme.colors.success
|
|
193
136
|
}}
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
initialText='Test'
|
|
197
|
-
value={mText}
|
|
198
|
-
onChangeText={t => setMText(t)} />
|
|
199
|
-
<CompositeTextInputView
|
|
200
|
-
style={{
|
|
137
|
+
onPress={() => {
|
|
138
|
+
setbottomsheetVisible(true)
|
|
201
139
|
}}
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
}}>
|
|
219
|
-
<VBox >
|
|
220
|
-
<ButtonView
|
|
221
|
-
icon={btnIcon}
|
|
222
|
-
style={{
|
|
223
|
-
}}>Button Icon</ButtonView>
|
|
224
|
-
|
|
225
|
-
<ButtonView style={{
|
|
226
|
-
}}>Button Text</ButtonView>
|
|
140
|
+
iconText='SN' />
|
|
141
|
+
</Center>
|
|
142
|
+
<Expand title='Message Alert' initialExpand={false}
|
|
143
|
+
style={{
|
|
144
|
+
backgroundColor: theme.colors.forground
|
|
145
|
+
}}
|
|
146
|
+
titleBackgroundColor={theme.colors.forground}
|
|
147
|
+
>
|
|
148
|
+
<VBox>
|
|
149
|
+
<AlertMessage text={alert} onDismiss={() => {
|
|
150
|
+
LayoutAnimation.configureNext(LayoutAnimation.Presets.easeInEaseOut);
|
|
151
|
+
setAlert('')
|
|
152
|
+
}} />
|
|
153
|
+
<AlertMessage text='Critial Message' type='critical' />
|
|
154
|
+
<AlertMessage text='Success' type='success' />
|
|
155
|
+
<AlertMessage text='Warning Message' type='warning' />
|
|
227
156
|
</VBox>
|
|
228
|
-
<RightIconButton
|
|
229
|
-
text='Click Me Icon'
|
|
230
|
-
icon={btnIcon}>
|
|
231
|
-
</RightIconButton>
|
|
232
157
|
|
|
233
|
-
|
|
234
|
-
|
|
158
|
+
</Expand>
|
|
159
|
+
<Expand
|
|
160
|
+
style={{
|
|
161
|
+
padding: 0,
|
|
162
|
+
borderWidth: 0.1,
|
|
163
|
+
borderColor: '#DCDCDC'
|
|
164
|
+
}}
|
|
165
|
+
duration={200}
|
|
166
|
+
title='In this version, the icon used is always chevron-right even when expanded. In this version, the icon used is always chevron-right even when expanded.'
|
|
167
|
+
initialExpand={false} iconPosition='right'>
|
|
168
|
+
<VBox>
|
|
169
|
+
<Title>Text A</Title>
|
|
170
|
+
<Subtitle>Text A Text A Text AText A Text AText A</Subtitle>
|
|
171
|
+
<TextView>Text A</TextView>
|
|
172
|
+
<Caption>Text Caption</Caption>
|
|
173
|
+
</VBox>
|
|
174
|
+
</Expand>
|
|
175
|
+
<Expand title='Inputs'>
|
|
235
176
|
|
|
236
|
-
|
|
237
|
-
|
|
177
|
+
<VBox>
|
|
178
|
+
<TextInputView
|
|
179
|
+
style={{
|
|
180
|
+
fontFamily: theme.fonts.Bold
|
|
238
181
|
}}
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
<
|
|
243
|
-
|
|
182
|
+
initialText={mText}
|
|
183
|
+
value={mText}
|
|
184
|
+
onChangeText={t => setMText(t)} />
|
|
185
|
+
<CompositeTextInputView
|
|
186
|
+
onChangeText={t => setMText(t)}
|
|
187
|
+
placeholder='A test'
|
|
188
|
+
initialText='Test' />
|
|
189
|
+
<CompositeTextInputView
|
|
190
|
+
inputMode='decimal'
|
|
191
|
+
icon={"close"}
|
|
192
|
+
style={{
|
|
193
|
+
}}
|
|
194
|
+
alertTextColor={theme.colors.warning}
|
|
195
|
+
placeholder='Enter your name'
|
|
196
|
+
initialText='Test'
|
|
197
|
+
value={mText}
|
|
198
|
+
onChangeText={t => setMText(t)} />
|
|
199
|
+
<CompositeTextInputView
|
|
244
200
|
style={{
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
201
|
+
}}
|
|
202
|
+
placeholder='Enter number'
|
|
203
|
+
alertText={mText?.indexOf("@") > -1 ? '' : 'Please enter @ or else I am gonna come down at your place and mess you up buddy !'}
|
|
204
|
+
initialText='Test'
|
|
205
|
+
value={mText}
|
|
206
|
+
onChangeText={t => setMText(t)} />
|
|
207
|
+
</VBox>
|
|
208
|
+
</Expand>
|
|
248
209
|
|
|
249
|
-
|
|
210
|
+
<Expand
|
|
211
|
+
iconStyle={{
|
|
212
|
+
name: 'chevron-right',
|
|
213
|
+
color: 'red'
|
|
214
|
+
}}
|
|
215
|
+
title='Buttons'
|
|
216
|
+
initialExpand={false}>
|
|
217
|
+
<VBox style={{
|
|
218
|
+
}}>
|
|
219
|
+
<VBox >
|
|
220
|
+
<ButtonView
|
|
221
|
+
icon={btnIcon}
|
|
222
|
+
style={{
|
|
223
|
+
}}>Button Icon</ButtonView>
|
|
224
|
+
|
|
225
|
+
<ButtonView style={{
|
|
226
|
+
}}>Button Text</ButtonView>
|
|
227
|
+
</VBox>
|
|
228
|
+
<RightIconButton
|
|
229
|
+
text='Click Me Icon'
|
|
230
|
+
icon={btnIcon}>
|
|
231
|
+
</RightIconButton>
|
|
250
232
|
|
|
251
|
-
|
|
252
|
-
<HBox style={{
|
|
253
|
-
justifyContent: 'center',
|
|
254
|
-
}}>
|
|
233
|
+
<Center>
|
|
255
234
|
<LoadingButton
|
|
256
|
-
|
|
257
|
-
width: 'auto'
|
|
258
|
-
}}
|
|
235
|
+
|
|
259
236
|
onPress={(e) => {
|
|
260
237
|
setLoading(!loading)
|
|
261
238
|
}}
|
|
262
239
|
loading={loading}
|
|
263
|
-
text='Click Me
|
|
264
|
-
|
|
265
|
-
|
|
240
|
+
text='Click Me' />
|
|
241
|
+
|
|
242
|
+
<ButtonView
|
|
243
|
+
underlayColor={theme.colors.transparent}
|
|
266
244
|
style={{
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
setLoading(!loading)
|
|
271
|
-
}}
|
|
272
|
-
loading={loading}
|
|
273
|
-
text='Click Me right' />
|
|
274
|
-
</HBox>
|
|
275
|
-
</Expand>
|
|
245
|
+
color: theme.colors.accent,
|
|
246
|
+
backgroundColor: theme.colors.transparent,
|
|
247
|
+
}}>Tertiary button</ButtonView>
|
|
276
248
|
|
|
277
|
-
|
|
278
|
-
</Expand>
|
|
249
|
+
</Center>
|
|
279
250
|
|
|
251
|
+
<Expand title='Nested expand'>
|
|
252
|
+
<HBox style={{
|
|
253
|
+
justifyContent: 'center',
|
|
254
|
+
}}>
|
|
255
|
+
<LoadingButton
|
|
256
|
+
style={{
|
|
257
|
+
width: 'auto'
|
|
258
|
+
}}
|
|
259
|
+
onPress={(e) => {
|
|
260
|
+
setLoading(!loading)
|
|
261
|
+
}}
|
|
262
|
+
loading={loading}
|
|
263
|
+
text='Click Me left' />
|
|
264
|
+
<LoadingButton
|
|
265
|
+
loaderStyle='transparent'
|
|
266
|
+
style={{
|
|
267
|
+
width: 'auto'
|
|
268
|
+
}}
|
|
269
|
+
onPress={(e) => {
|
|
270
|
+
setLoading(!loading)
|
|
271
|
+
}}
|
|
272
|
+
loading={loading}
|
|
273
|
+
text='Click Me right' />
|
|
274
|
+
</HBox>
|
|
275
|
+
</Expand>
|
|
280
276
|
|
|
277
|
+
</VBox>
|
|
278
|
+
</Expand>
|
|
281
279
|
|
|
282
|
-
<ButtonView
|
|
283
|
-
underlayColor={theme.colors.transparent}
|
|
284
|
-
style={{
|
|
285
|
-
color: theme.colors.accent,
|
|
286
|
-
backgroundColor: theme.colors.transparent,
|
|
287
|
-
}}
|
|
288
|
-
onPress={() => {
|
|
289
|
-
setSelectedTheme(!selectedTheme)
|
|
290
|
-
}}>{selectedTheme ? 'Light' : 'Dark'}</ButtonView>
|
|
291
280
|
|
|
292
281
|
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
282
|
+
<ButtonView
|
|
283
|
+
underlayColor={theme.colors.transparent}
|
|
284
|
+
style={{
|
|
285
|
+
color: theme.colors.accent,
|
|
286
|
+
backgroundColor: theme.colors.transparent,
|
|
287
|
+
}}
|
|
288
|
+
onPress={() => {
|
|
289
|
+
setSelectedTheme(!selectedTheme)
|
|
290
|
+
}}>{selectedTheme ? 'Light' : 'Dark'}</ButtonView>
|
|
302
291
|
|
|
303
292
|
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
{
|
|
314
|
-
id: 'home',
|
|
315
|
-
title: 'Home',
|
|
316
|
-
icon: 'home'
|
|
317
|
-
},
|
|
318
|
-
{
|
|
319
|
-
id: 'create',
|
|
320
|
-
title: 'Create',
|
|
321
|
-
icon: 'plus'
|
|
322
|
-
},
|
|
323
|
-
{
|
|
324
|
-
id: 'search',
|
|
325
|
-
title: 'Search',
|
|
326
|
-
icon: 'search'
|
|
327
|
-
},
|
|
328
|
-
{
|
|
329
|
-
id: 'profile',
|
|
330
|
-
title: 'Profile',
|
|
331
|
-
icon: ReactWrapper(<PressableView>
|
|
332
|
-
<Avatar
|
|
333
|
-
onPress={() => {
|
|
334
|
-
setSelectedBottomBarId('profile')
|
|
335
|
-
}}
|
|
336
|
-
style={{
|
|
337
|
-
borderColor: selectedBottombarId == 'profile' ?
|
|
338
|
-
theme.colors.accent : theme.colors.caption,
|
|
339
|
-
margin: 0,
|
|
340
|
-
height: theme.dimens?.icon?.md,
|
|
341
|
-
width: theme.dimens?.icon?.md,
|
|
342
|
-
}}
|
|
343
|
-
// iconName='user'
|
|
344
|
-
iconUrl="https://avatars.githubusercontent.com/u/16799797?v=4"
|
|
345
|
-
/>
|
|
346
|
-
</PressableView>)
|
|
347
|
-
}
|
|
348
|
-
]}
|
|
349
|
-
onDimens={(w, h) => {
|
|
350
|
-
setBottombarHeight(h)
|
|
351
|
-
console.log("bottomBarHeight", h)
|
|
352
|
-
}} />
|
|
293
|
+
<ButtonView
|
|
294
|
+
underlayColor={theme.colors.transparent}
|
|
295
|
+
style={{
|
|
296
|
+
color: theme.colors.accent,
|
|
297
|
+
backgroundColor: theme.colors.transparent,
|
|
298
|
+
}}
|
|
299
|
+
onPress={() => {
|
|
300
|
+
setbottomsheetVisible(true)
|
|
301
|
+
}}>Show Sheet</ButtonView>
|
|
353
302
|
|
|
354
|
-
<BottomSheet
|
|
355
|
-
title="About"
|
|
356
|
-
visible={bottomsheetVisible} onDismiss={() => {
|
|
357
|
-
setbottomsheetVisible(false)
|
|
358
|
-
}} >
|
|
359
|
-
<TextView>Dinosaurs are a diverse group of reptiles of the clade Dinosauria. They first appeared during the Triassic period, between 243 and 233.23 million years ago, although the exact origin and timing of the evolution of dinosaurs is a subject of active research.</TextView>
|
|
360
303
|
|
|
361
|
-
|
|
362
|
-
<
|
|
304
|
+
</KeyboardAvoidingScrollView>
|
|
305
|
+
<BottomNavBar
|
|
363
306
|
style={{
|
|
364
|
-
|
|
365
|
-
|
|
307
|
+
borderTopLeftRadius: theme.dimens.space.md,
|
|
308
|
+
borderTopRightRadius: theme.dimens.space.md,
|
|
366
309
|
}}
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
310
|
+
onSelect={setSelectedBottomBarId}
|
|
311
|
+
selectedId={selectedBottombarId}
|
|
312
|
+
options={[
|
|
313
|
+
{
|
|
314
|
+
id: 'home',
|
|
315
|
+
title: 'Home',
|
|
316
|
+
icon: 'home'
|
|
317
|
+
},
|
|
318
|
+
{
|
|
319
|
+
id: 'create',
|
|
320
|
+
title: 'Create',
|
|
321
|
+
icon: 'plus'
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
id: 'search',
|
|
325
|
+
title: 'Search',
|
|
326
|
+
icon: 'search'
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
id: 'profile',
|
|
330
|
+
title: 'Profile',
|
|
331
|
+
icon: ReactWrapper(<PressableView>
|
|
332
|
+
<Avatar
|
|
333
|
+
onPress={() => {
|
|
334
|
+
setSelectedBottomBarId('profile')
|
|
335
|
+
}}
|
|
336
|
+
style={{
|
|
337
|
+
borderColor: selectedBottombarId == 'profile' ?
|
|
338
|
+
theme.colors.accent : theme.colors.caption,
|
|
339
|
+
margin: 0,
|
|
340
|
+
height: theme.dimens?.icon?.md,
|
|
341
|
+
width: theme.dimens?.icon?.md,
|
|
342
|
+
}}
|
|
343
|
+
// iconName='user'
|
|
344
|
+
iconUrl="https://avatars.githubusercontent.com/u/16799797?v=4"
|
|
345
|
+
/>
|
|
346
|
+
</PressableView>)
|
|
347
|
+
}
|
|
348
|
+
]}
|
|
349
|
+
onDimens={(w, h) => {
|
|
350
|
+
setBottombarHeight(h)
|
|
351
|
+
console.log("bottomBarHeight", h)
|
|
352
|
+
}} />
|
|
353
|
+
|
|
354
|
+
<BottomSheet
|
|
355
|
+
title="About"
|
|
356
|
+
visible={bottomsheetVisible} onDismiss={() => {
|
|
357
|
+
setbottomsheetVisible(false)
|
|
358
|
+
}} >
|
|
359
|
+
<TextView>Dinosaurs are a diverse group of reptiles of the clade Dinosauria. They first appeared during the Triassic period, between 243 and 233.23 million years ago, although the exact origin and timing of the evolution of dinosaurs is a subject of active research.</TextView>
|
|
360
|
+
|
|
361
|
+
<TextView>Dinosaurs are a diverse group of reptiles of the clade Dinosauria. They first appeared during the Triassic period, between 243 and 233.23 million years ago, although the exact origin and timing of the evolution of dinosaurs is a subject of active research.</TextView>
|
|
362
|
+
<Expand title='Types' initialExpand={false}
|
|
363
|
+
style={{
|
|
364
|
+
padding: 0,
|
|
365
|
+
backgroundColor: theme.colors.forground
|
|
366
|
+
}}
|
|
367
|
+
titleBackgroundColor={theme.colors.forground}
|
|
368
|
+
>
|
|
369
|
+
<VBox>
|
|
370
|
+
<AlertMessage text={alert} onDismiss={() => {
|
|
371
|
+
LayoutAnimation.configureNext(LayoutAnimation.Presets.easeInEaseOut);
|
|
372
|
+
setAlert('')
|
|
373
|
+
}} />
|
|
374
|
+
<AlertMessage text='Tyrannosaurus rex' type='critical' />
|
|
375
|
+
<AlertMessage text='Spinosaurus' type='success' />
|
|
376
|
+
<AlertMessage text='Ankylosaurs' type='warning' />
|
|
377
|
+
</VBox>
|
|
378
378
|
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
379
|
+
</Expand>
|
|
380
|
+
</BottomSheet>
|
|
381
|
+
</VBox>
|
|
382
|
+
</SafeAreaProvider>
|
|
382
383
|
);
|
|
383
384
|
}
|