Commit 64be6ad5 by wong.peiyi

过滤显示

parent 15062dfb
Showing with 14 additions and 5 deletions
......@@ -21,6 +21,7 @@ import {
ScrollView,
TouchableWithoutFeedback,
Modal,
Platform,
} from 'react-native'
import * as R from 'ramda'
import {
......@@ -42,7 +43,7 @@ import {
second_text_color,
first_text_color,
} from '../../../base/BaseStyle'
import { isIphoneX } from "../../../utils/Utils";
import { isIphoneX } from '../../../utils/Utils'
const PropTypes = require('prop-types')
export default class ChoolseFilter extends Component {
......@@ -98,7 +99,15 @@ export default class ChoolseFilter extends Component {
activeOpacity={1}
></TouchableOpacity>
<View style={styles.mask}></View>
<View style={isIphoneX() ? [styles.searchContent, {top: 48 + 58 + pxSize(36)}] : styles.searchContent}>
<View
style={
Platform.OS === 'ios'
? isIphoneX()
? [styles.searchContent, { top: 48 + 58 + pxSize(36) }]
: [styles.searchContent, { top: 20 + 58 + pxSize(36) }]
: styles.searchContent
}
>
<ScrollView style={styles.scrollView}>
{filterData &&
filterData.map(item => {
......@@ -124,7 +133,7 @@ export default class ChoolseFilter extends Component {
} else {
onCallback && onCallback(item.field, option.value)
}
this.setState({ visible: !visible})
this.setState({ visible: !visible })
}}
>
<Text
......@@ -200,7 +209,7 @@ const styles = StyleSheet.create({
borderColor: '#E1F1FE',
borderWidth: 1,
padding: 3,
borderRadius: 4
borderRadius: 4,
},
filterBtn: {
height: pxSize(36),
......@@ -228,7 +237,7 @@ const styles = StyleSheet.create({
width: Width(),
height: Height(),
zIndex: 99,
top: 0
top: 0,
},
mask: {
position: 'absolute',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment