@boneframework/native-components 1.0.57 → 1.0.58
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/components/{Animation.tsx → Animation.native.tsx} +3 -11
- package/components/Animation.web.tsx +24 -0
- package/components/ListItemSwipable.tsx +2 -2
- package/package.json +3 -2
- package/screens/MapScreen.web.tsx +17 -6
- package/screens/RegisterScreen.tsx +1 -1
- package/screens/WelcomeScreen.tsx +1 -1
|
@@ -1,22 +1,14 @@
|
|
|
1
1
|
import React, {useRef} from 'react';
|
|
2
|
+
// import { DotLottie } from '@lottiefiles/dotlottie-react-native';
|
|
2
3
|
import LottieView from "lottie-react-native";
|
|
3
4
|
|
|
4
|
-
import { Platform } from 'react-native';
|
|
5
|
-
import { DotLottie as DotLottieNative } from '@lottiefiles/dotlottie-react-native';
|
|
6
|
-
import { DotLottie as DotLottieWeb } from '@lottiefiles/dotlottie-react';
|
|
7
|
-
|
|
8
|
-
const DotLottie = Platform.select({
|
|
9
|
-
ios: DotLottieNative,
|
|
10
|
-
android: DotLottieNative,
|
|
11
|
-
default: DotLottieWeb as any,
|
|
12
|
-
});
|
|
13
|
-
|
|
14
5
|
function Animation({source, style = {}, onAnimationFinish = () => {}, autoPlay = true, loop = true, speed = 1.5}) {
|
|
15
6
|
|
|
16
7
|
const lottieRef = useRef(null);
|
|
17
8
|
|
|
9
|
+
|
|
18
10
|
return(
|
|
19
|
-
<
|
|
11
|
+
<LottieView
|
|
20
12
|
source={source}
|
|
21
13
|
autoPlay={autoPlay}
|
|
22
14
|
loop={loop}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import React, {useRef} from 'react';
|
|
2
|
+
import DotLottie, {} from '@lottiefiles/dotlottie-react';
|
|
3
|
+
|
|
4
|
+
function Animation({source, style = {}, onAnimationFinish = () => {}, autoPlay = true, loop = true, speed = 1.5}) {
|
|
5
|
+
|
|
6
|
+
const lottieRef = useRef<DotLottie>(null);
|
|
7
|
+
|
|
8
|
+
// @todo: Fix web DotLottie usage
|
|
9
|
+
// <DotLottie
|
|
10
|
+
// source={source}
|
|
11
|
+
// autoPlay={autoPlay}
|
|
12
|
+
// loop={loop}
|
|
13
|
+
// style={style}
|
|
14
|
+
// speed={speed}
|
|
15
|
+
// onAnimationFinish={onAnimationFinish}
|
|
16
|
+
// ref={lottieRef}
|
|
17
|
+
// />
|
|
18
|
+
|
|
19
|
+
return(<></>
|
|
20
|
+
|
|
21
|
+
);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export default Animation;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import {StyleSheet, TouchableHighlight, View} from "react-native";
|
|
3
|
-
import Swipeable from 'react-native-gesture-handler/
|
|
3
|
+
import Swipeable from 'react-native-gesture-handler/ReanimatedSwipeable';
|
|
4
4
|
|
|
5
5
|
import Image from '../components/Image'
|
|
6
6
|
import Text from '../components/Text'
|
|
7
7
|
import {MaterialCommunityIcons} from "@expo/vector-icons";
|
|
8
8
|
import useStyle from "../hooks/useStyle";
|
|
9
|
-
import useColors from
|
|
9
|
+
import useColors from "../hooks/useColors";
|
|
10
10
|
|
|
11
11
|
function ListItemSwipable({title, subtitle, image, IconComponent, onPress, renderRightActions, displayCheverons, titleStyle, subtitleStyle}) {
|
|
12
12
|
const colors = useColors();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@boneframework/native-components",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.58",
|
|
4
4
|
"description": "Expo React Native Components for Bone Framework",
|
|
5
5
|
"main": "src/Bone.ts",
|
|
6
6
|
"scripts": {
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"access": "public"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@lottiefiles/dotlottie-react": "^0.
|
|
32
|
+
"@lottiefiles/dotlottie-react": "^0.13.5",
|
|
33
33
|
"@lottiefiles/dotlottie-react-native": "^0.7.1",
|
|
34
34
|
"@react-native-async-storage/async-storage": "^2.2.0",
|
|
35
35
|
"@react-native-community/datetimepicker": "^8.5.1",
|
|
@@ -50,6 +50,7 @@
|
|
|
50
50
|
"formik": "^2.4.9",
|
|
51
51
|
"jwt-decode": "^4.0.0",
|
|
52
52
|
"lottie-react-native": "^7.3.4",
|
|
53
|
+
"pigeon-maps": "^0.22.1",
|
|
53
54
|
"react": "19.1.0",
|
|
54
55
|
"react-native-gesture-handler": "^2.29.1",
|
|
55
56
|
"react-native-maps": "^1.26.19",
|
|
@@ -1,12 +1,23 @@
|
|
|
1
|
-
import React from 'react';
|
|
1
|
+
import React, { useState } from 'react';
|
|
2
2
|
import {StyleSheet, Text, View} from "react-native";
|
|
3
|
+
import { Map } from 'pigeon-maps';
|
|
3
4
|
|
|
4
5
|
function MapScreen(props) {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
const [center, setCenter] = useState([50.879, 4.6997])
|
|
7
|
+
const [zoom, setZoom] = useState(11)
|
|
8
|
+
|
|
9
|
+
return (
|
|
10
|
+
<View style={styles.container}>
|
|
11
|
+
<Map style={styles.map}
|
|
12
|
+
center={center}
|
|
13
|
+
zoom={zoom}
|
|
14
|
+
onBoundsChanged={({ center, zoom }) => {
|
|
15
|
+
setCenter(center)
|
|
16
|
+
setZoom(zoom)
|
|
17
|
+
}}
|
|
18
|
+
/>
|
|
19
|
+
</View>
|
|
20
|
+
)
|
|
10
21
|
}
|
|
11
22
|
|
|
12
23
|
const styles = StyleSheet.create({
|
|
@@ -51,7 +51,7 @@ function RegisterScreen({postRegisterUrl, backgroundSource = null, logoSource =
|
|
|
51
51
|
<TouchableOpacity style={styles.cancelButton} onPress={onClose}>
|
|
52
52
|
<Icon size={75} name={'chevron-left'} />
|
|
53
53
|
</TouchableOpacity>
|
|
54
|
-
<Image style={styles.logo} source={
|
|
54
|
+
<Image style={styles.logo} source={logoSource} />
|
|
55
55
|
|
|
56
56
|
<Form
|
|
57
57
|
initialValues={{ email: ''}}
|
|
@@ -59,7 +59,7 @@ function WelcomeScreen({
|
|
|
59
59
|
<Background imageSource={backgroundSource} blurRadius={10} style={styles.background} gradientColors={colors.bgGradient}>
|
|
60
60
|
<ActivityIndicator visible={isLoading} type={'overlay'} />
|
|
61
61
|
<View style={styles.logoContainer}>
|
|
62
|
-
<Image style={styles.logo} source={
|
|
62
|
+
<Image style={styles.logo} source={logoSource} />
|
|
63
63
|
<Text style={styles.tagline}>{ title }</Text>
|
|
64
64
|
</View>
|
|
65
65
|
<View style={styles.buttonContainer}>
|