Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Propose flexible custom style from caller #7

Closed
Kudo opened this issue Dec 2, 2015 · 2 comments
Closed

Propose flexible custom style from caller #7

Kudo opened this issue Dec 2, 2015 · 2 comments

Comments

@Kudo
Copy link

Kudo commented Dec 2, 2015

There is a bug facebook/react-native#3233 for Android RN that set padding on Text will have unexpected result.
So my segmented control text did not vertically centered.

Currently SegmentedControls' design is not flexible enough. For example, if I want to set fontSize for the text, there is no way to do that.
Do you consider to accept style prop and let caller to decide the style?
Something like MapView style prop and caller sample .

If you don't mind for the design changes, I can take some time to propose a PR. Thanks.

@ArnaudRinquin
Copy link
Owner

Thanks to #8 from @johanneshilden, you can now use the SegementedControl renderOption prop to override the default which just uses Text.

@Kudo
Copy link
Author

Kudo commented Dec 29, 2015

The solution works fine for me. Thanks @ArnaudRinquin @johanneshilden

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants