NativeBase icon indicating copy to clipboard operation
NativeBase copied to clipboard

Docs: How to position multiple buttons on the same line?

Open lukewlms opened this issue 9 years ago • 6 comments

react-native, react and native-base version

RN: 0.44.9 React: 15.0.27 Native Base 2.3.0

Expected behaviour

Docs show how buttons are put on same or different lines

Actual behaviour

Example in docs has some buttons on same line, but code doesn't match buttons and there's no indication of how to get them on the same line. (E.g. the Icon Buttons example image shows several more buttons than are in the example code, and some are on the same line, but there's no code difference for these buttons.)

lukewlms avatar Jul 25 '17 16:07 lukewlms

How would you position any other element in the same line?

sankhadeeproy007 avatar Jul 25 '17 17:07 sankhadeeproy007

Thanks - with flexDirection:

      <View style={{flexDirection: "row"}}>

However, is there a Native Base way to do it, or am I expected to use View here?

Per https://github.com/GeekyAnts/NativeBase/issues/1004, Content is apparently supposed to be one-per-page, and Container causes whatever it wraps to take up the vertical space of one full screen, so without restyling it can't be used for layout like this.

lukewlms avatar Jul 25 '17 19:07 lukewlms

There is no NativeBase way of aligning elements. You can use View with flex for that.

sankhadeeproy007 avatar Jul 26 '17 05:07 sankhadeeproy007

@sankhadeeproy007 ok, thank you very much for the responses.

lukewlms avatar Jul 26 '17 16:07 lukewlms

How to add 3 buttons below the table??

Manik1987-commit avatar Apr 17 '20 06:04 Manik1987-commit

Hi @Manik1987-commit , please explain a little bit more.

hanykumar avatar Apr 17 '20 07:04 hanykumar