I am trying to add elevation so that I can add a effect share below but right now my code isn’t adding that effect. I have even tried linear-gradient
to add such effect in view
but still not able to achieve it.
code:
<code> <TextInput
placeholder={placeholder}
style={[currentStyles.input, currentStyles.txt, style]}
onBlur={onBlur}
onChangeText={onChange}
value={value}
/>
</View>
</code>
<code> <TextInput
placeholder={placeholder}
style={[currentStyles.input, currentStyles.txt, style]}
onBlur={onBlur}
onChangeText={onChange}
value={value}
/>
</View>
</code>
<TextInput
placeholder={placeholder}
style={[currentStyles.input, currentStyles.txt, style]}
onBlur={onBlur}
onChangeText={onChange}
value={value}
/>
</View>
stlying:
<code>inputView: {
backgroundColor: "#00000040", // Transparent to show gradient
height: pixelSizeHorizontal(60),
paddingHorizontal: pixelSizeHorizontal(10),
shadowColor: "#747474",
shadowOffset: { width: 5, height: 0 },
shadowOpacity: 0.8,
shadowRadius: 0.1,
elevation: 24,
borderRadius: 10,
},
input: {
marginTop: pixelSizeVertical(10),
height: pixelSizeHorizontal(45),
},
</code>
<code>inputView: {
backgroundColor: "#00000040", // Transparent to show gradient
height: pixelSizeHorizontal(60),
paddingHorizontal: pixelSizeHorizontal(10),
shadowColor: "#747474",
shadowOffset: { width: 5, height: 0 },
shadowOpacity: 0.8,
shadowRadius: 0.1,
elevation: 24,
borderRadius: 10,
},
input: {
marginTop: pixelSizeVertical(10),
height: pixelSizeHorizontal(45),
},
</code>
inputView: {
backgroundColor: "#00000040", // Transparent to show gradient
height: pixelSizeHorizontal(60),
paddingHorizontal: pixelSizeHorizontal(10),
shadowColor: "#747474",
shadowOffset: { width: 5, height: 0 },
shadowOpacity: 0.8,
shadowRadius: 0.1,
elevation: 24,
borderRadius: 10,
},
input: {
marginTop: pixelSizeVertical(10),
height: pixelSizeHorizontal(45),
},
How can add below shared effect in view
that wraps TextInput
?