react-native-radar 3.8.4 → 3.8.5

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.
@@ -18,7 +18,7 @@ android {
18
18
  minSdkVersion 16
19
19
  targetSdkVersion 31
20
20
  versionCode 1
21
- versionName '3.8.2'
21
+ versionName '3.8.6'
22
22
  }
23
23
  lintOptions {
24
24
  abortOnError false
@@ -45,5 +45,5 @@ repositories {
45
45
 
46
46
  dependencies {
47
47
  api 'com.facebook.react:react-native:+'
48
- api 'io.radar:sdk:3.8.5'
48
+ api 'io.radar:sdk:3.8.6'
49
49
  }
@@ -78,9 +78,13 @@ public class RNRadarModule extends ReactContextBaseJavaModule implements Permiss
78
78
  }
79
79
 
80
80
  @ReactMethod
81
- public void initialize(String publishableKey) {
82
- Radar.initialize(getReactApplicationContext(), publishableKey);
83
- Radar.setReceiver(receiver);
81
+ public void initialize(String publishableKey, boolean fraud) {
82
+ if (fraud) {
83
+ Radar.initialize(getReactApplicationContext(), publishableKey, receiver, Radar.RadarLocationServicesProvider.GOOGLE, fraud);
84
+ } else {
85
+ Radar.initialize(getReactApplicationContext(), publishableKey);
86
+ Radar.setReceiver(receiver);
87
+ }
84
88
  }
85
89
 
86
90
  @ReactMethod
package/ios/RNRadar.m CHANGED
@@ -91,7 +91,7 @@ RCT_EXPORT_MODULE();
91
91
  }
92
92
  }
93
93
 
94
- RCT_EXPORT_METHOD(initialize:(NSString *)publishableKey) {
94
+ RCT_EXPORT_METHOD(initialize:(NSString *)publishableKey fraud:(BOOL)fraud) {
95
95
  [Radar initializeWithPublishableKey:publishableKey];
96
96
  }
97
97
 
@@ -6,8 +6,8 @@ if (!NativeModules.RNRadar && (Platform.OS === 'ios' || Platform.OS === 'android
6
6
 
7
7
  const eventEmitter = new NativeEventEmitter(NativeModules.RNRadar);
8
8
 
9
- const initialize = (publishableKey) => {
10
- NativeModules.RNRadar.initialize(publishableKey);
9
+ const initialize = (publishableKey, fraud) => {
10
+ NativeModules.RNRadar.initialize(publishableKey, fraud);
11
11
  };
12
12
 
13
13
  const setLogLevel = (level) => {
@@ -44,6 +44,7 @@ const autocompleteUI = ({ options = {} }) => {
44
44
  const timerRef = useRef(null);
45
45
  const textInputRef = useRef(null);
46
46
 
47
+
47
48
  const config = { ...defaultAutocompleteOptions, ...options };
48
49
  const style = config.style || {};
49
50
 
@@ -171,7 +172,7 @@ const autocompleteUI = ({ options = {} }) => {
171
172
  style.modalInputContainer
172
173
  ),
173
174
  resultList: StyleSheet.compose(defaultStyles.resultList, style.resultList),
174
- resultItem: StyleSheet.compose(defaultStyles.resultItem, style.resultItem),
175
+ resultItem: StyleSheet.compose({...defaultStyles.resultItem, pressedBackgroundColor: '#F6FAFC'}, style.resultItem),
175
176
  addressContainer: StyleSheet.compose(
176
177
  defaultStyles.addressContainer,
177
178
  style.addressContainer
package/js/ui/map.jsx CHANGED
@@ -66,17 +66,29 @@ const RadarMap = ({ mapOptions, children }) => {
66
66
  >
67
67
  <MapLibreGL.CircleLayer
68
68
  id="user-location-inner"
69
- style={styles.userLocation.pulse}
69
+ style={{
70
+ circleRadius: 15,
71
+ circleColor: '#000257',
72
+ circleOpacity: 0.2,
73
+ circlePitchAlignment: 'map',
74
+ }}
70
75
  />
71
76
  <MapLibreGL.CircleLayer
72
77
  id="user-location-middle"
73
- style={styles.userLocation.background}
78
+ style={{
79
+ circleRadius: 9,
80
+ circleColor: '#fff',
81
+ circlePitchAlignment: 'map',
82
+ }}
74
83
  />
75
84
  <MapLibreGL.CircleLayer
76
85
  id="user-location-outer"
77
- style={styles.userLocation.foreground}
86
+ style={{
87
+ circleRadius: 6,
88
+ circleColor: '#000257',
89
+ circlePitchAlignment: 'map',
90
+ }}
78
91
  />
79
-
80
92
  </MapLibreGL.ShapeSource>
81
93
  );
82
94
 
package/js/ui/styles.js CHANGED
@@ -62,7 +62,6 @@ const styles = StyleSheet.create({
62
62
  paddingHorizontal: 16,
63
63
  fontSize: 12,
64
64
  backgroundColor: 'white',
65
- pressedBackgroundColor: '#F6FAFC',
66
65
  },
67
66
  addressContainer: {
68
67
  flexDirection: 'row',
@@ -121,24 +120,6 @@ const styles = StyleSheet.create({
121
120
  height: 50,
122
121
  resizeMode: 'contain',
123
122
  },
124
- userLocation: {
125
- pulse: {
126
- circleRadius: 15,
127
- circleColor: '#000257',
128
- circleOpacity: 0.2,
129
- circlePitchAlignment: 'map',
130
- },
131
- background: {
132
- circleRadius: 9,
133
- circleColor: '#fff',
134
- circlePitchAlignment: 'map',
135
- },
136
- foreground: {
137
- circleRadius: 6,
138
- circleColor: '#000257',
139
- circlePitchAlignment: 'map',
140
- },
141
- },
142
123
  });
143
124
 
144
125
  export default styles;
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "React Native module for Radar, the leading geofencing and location tracking platform",
4
4
  "homepage": "https://radar.com",
5
5
  "license": "Apache-2.0",
6
- "version": "3.8.4",
6
+ "version": "3.8.5",
7
7
  "main": "js/index.js",
8
8
  "files": [
9
9
  "android",