ordering-ui-react-native 0.22.41-release → 0.22.42-release

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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ordering-ui-react-native",
3
- "version": "0.22.41-release",
3
+ "version": "0.22.42-release",
4
4
  "description": "Reusable components made in react native",
5
5
  "main": "src/index.tsx",
6
6
  "author": "ordering.inc",
@@ -185,14 +185,16 @@ const MapViewComponent = (props: MapViewParams) => {
185
185
  size={50}
186
186
  color={theme.colors.primary}
187
187
  />
188
- <View style={styles.view}>
189
- <OIcon
190
- style={styles.image}
191
- src={{ uri: customer ? marker?.customer?.photo : marker?.business?.logo }}
192
- width={25}
193
- height={25}
194
- />
195
- </View>
188
+ {(!!marker?.customer?.photo || !!marker?.business?.logo) && (
189
+ <View style={styles.view}>
190
+ <OIcon
191
+ style={styles.image}
192
+ src={{ uri: customer ? marker?.customer?.photo : marker?.business?.logo }}
193
+ width={25}
194
+ height={25}
195
+ />
196
+ </View>
197
+ )}
196
198
  <Callout
197
199
  onPress={() => !!orderIds && orderIds.toString().includes(',') ? onNavigationRedirect('Orders') : onNavigationRedirect('OrderDetails', { order: marker })}
198
200
  >
@@ -213,8 +215,8 @@ const MapViewComponent = (props: MapViewParams) => {
213
215
  {((customer && marker?.customer?.city?.address_notes) || !customer) && (
214
216
  <OText>{customer ? marker?.customer?.city?.address_notes : marker?.business?.city?.name}</OText>
215
217
  )}
216
- {((customer && marker?.business?.zipcode) || (!customer && marker?.business?.zipcode)) && (
217
- <OText>{customer ? marker?.customer?.zipcode : marker?.business?.zipcode}</OText>
218
+ {((customer && !!marker?.business?.zipcode) || (!customer && !!marker?.business?.zipcode)) && (
219
+ <OText>{customer ? marker?.customer?.zipcode ?? '' : marker?.business?.zipcode ?? ''}</OText>
218
220
  )}
219
221
  {customer && !!marker?.customer?.internal_number && (
220
222
  <OText>{marker?.customer?.internal_number}</OText>