atasmohammadi / react-native-multiple-select-list

Multiple select list with search bar
74 stars 46 forks source link

Other Components Shifted Upward & Out of Screen #17

Open imwaykul opened 5 years ago

imwaykul commented 5 years ago

I love the multiselect search bar!

But for some reason when I added it, everything else above it got shifted out of the screen. I can't seem to find a way to fix it or change it..

Code for the return function of "render":

`return(

  <View style={styles4.container}>

      <StatusBar

        barStyle="light-content"

        backgroundColor="#20B2AA"

      />

      <Text style={styles4.welcome2}>

        Who's Going Along With You?

      </Text>

      <CustomMultiPicker

      options={items}

      search={true} // should show search bar?

      multiple={true} //

      placeholder={"Search"}

      placeholderTextColor={'#757575'}

      returnValue={"label"} // label or value

      callback={(res)=>{ console.log(res) }} // callback, array of selected items

      rowBackgroundColor={"#eee"}

      rowHeight={40}

      rowRadius={50}

      iconColor={"#00a2dd"}

      iconSize={20}

      selectedIconName={"ios-checkmark-circle-outline"}

      unselectedIconName={"ios-radio-button-off"}

      scrollViewHeight={150}

      selected={[1,2]} // list of options which are selected by default
      />

  <Button
         buttonStyle = {styles4.button}

         title="Next"

         onPress= {this.nextPage}

  />
  </View>

  );`

In this case, I cannot see "Something Something Cool Header"

yocheved-check-in commented 3 years ago

I love the multiselect search bar!

But for some reason when I added it, everything else above it got shifted out of the screen. I can't seem to find a way to fix it or change it..

Code for the return function of "render":

`return(

  <View style={styles4.container}>

      <StatusBar

        barStyle="light-content"

        backgroundColor="#20B2AA"

      />

      <Text style={styles4.welcome2}>

        Who's Going Along With You?

      </Text>

      <CustomMultiPicker

      options={items}

      search={true} // should show search bar?

      multiple={true} //

      placeholder={"Search"}

      placeholderTextColor={'#757575'}

      returnValue={"label"} // label or value

      callback={(res)=>{ console.log(res) }} // callback, array of selected items

      rowBackgroundColor={"#eee"}

      rowHeight={40}

      rowRadius={50}

      iconColor={"#00a2dd"}

      iconSize={20}

      selectedIconName={"ios-checkmark-circle-outline"}

      unselectedIconName={"ios-radio-button-off"}

      scrollViewHeight={150}

      selected={[1,2]} // list of options which are selected by default
      />

  <Button
         buttonStyle = {styles4.button}

         title="Next"

         onPress= {this.nextPage}

  />
  </View>

  );`

In this case, I cannot see "Something Something Cool Header"

Did you found a solution?