@compsych/mobile-ui 1.0.20 → 1.0.21
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
|
@@ -211,7 +211,8 @@ export function ServiceCard({
|
|
|
211
211
|
v.elevated && ELEVATION,
|
|
212
212
|
fullWidth && { alignSelf: 'stretch' as const },
|
|
213
213
|
isRow ? styles.rowRoot : styles.colRoot,
|
|
214
|
-
!isRow && { gap: s.gap },
|
|
214
|
+
!isRow && variant !== 'image' && { gap: s.gap },
|
|
215
|
+
variant === 'image' && { justifyContent: 'space-between' },
|
|
215
216
|
style,
|
|
216
217
|
];
|
|
217
218
|
|
|
@@ -294,13 +295,12 @@ export function ServiceCard({
|
|
|
294
295
|
resizeMode="cover"
|
|
295
296
|
accessible={false}
|
|
296
297
|
/>
|
|
297
|
-
<
|
|
298
|
+
<LinearGradient
|
|
299
|
+
colors={['rgba(0,0,0,0.4)', 'rgba(0,0,0,0.05)', 'rgba(0,0,0,0.5)']}
|
|
300
|
+
locations={[0.012, 0.268, 1]}
|
|
298
301
|
style={[
|
|
299
302
|
{ position: 'absolute', top: 0, left: 0, right: 0, bottom: 0 },
|
|
300
|
-
{
|
|
301
|
-
borderRadius: s.borderRadius,
|
|
302
|
-
backgroundColor: 'rgba(0,0,0,0.30)',
|
|
303
|
-
},
|
|
303
|
+
{ borderRadius: s.borderRadius },
|
|
304
304
|
]}
|
|
305
305
|
pointerEvents="none"
|
|
306
306
|
/>
|
|
@@ -311,10 +311,14 @@ export function ServiceCard({
|
|
|
311
311
|
{renderedIcon}
|
|
312
312
|
</View>
|
|
313
313
|
)}
|
|
314
|
-
{
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
314
|
+
<View style={styles.imageBottom}>
|
|
315
|
+
<View style={{ flex: 1 }}>{textBlock}</View>
|
|
316
|
+
{onPress && ChevronRight && (
|
|
317
|
+
<View style={styles.imageArrowButton}>
|
|
318
|
+
<ChevronRight size={16} color={cr.surface.surface.sysOnSurface} strokeWidth={1.5} />
|
|
319
|
+
</View>
|
|
320
|
+
)}
|
|
321
|
+
</View>
|
|
318
322
|
{children}
|
|
319
323
|
</>
|
|
320
324
|
);
|
|
@@ -398,6 +402,21 @@ const styles = StyleSheet.create({
|
|
|
398
402
|
alignItems: 'center',
|
|
399
403
|
gap: 12,
|
|
400
404
|
},
|
|
405
|
+
imageBottom: {
|
|
406
|
+
flexDirection: 'row',
|
|
407
|
+
alignItems: 'flex-end',
|
|
408
|
+
width: '100%',
|
|
409
|
+
gap: 16,
|
|
410
|
+
},
|
|
411
|
+
imageArrowButton: {
|
|
412
|
+
width: 32,
|
|
413
|
+
height: 32,
|
|
414
|
+
borderRadius: 999,
|
|
415
|
+
backgroundColor: '#ffffff',
|
|
416
|
+
alignItems: 'center',
|
|
417
|
+
justifyContent: 'center',
|
|
418
|
+
flexShrink: 0,
|
|
419
|
+
},
|
|
401
420
|
rowTextBlock: {
|
|
402
421
|
flex: 1,
|
|
403
422
|
minWidth: 0,
|