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

Feat/radio button customize styling #1092

Merged
merged 3 commits into from
Jan 3, 2021

Conversation

ckuijjer
Copy link
Contributor

@ckuijjer ckuijjer commented Dec 20, 2020

Description

The style property on the RadioButton component was applied to both the <Container /> component wrapping the radio button and label, and to the radio button itself. This made customizing the styling of the component less possible.

I simply added style to the destructuring in the render function, removing it from ...others and not being applied to the <Container />. An option would be to also allow styling the container, by adding a containerStyle prop, just like in the code for the CheckBox.

Two commits, one solely for the prettier format and the 2nd containing the change

Changelog

  • Added containerStyle prop to RadioButton to allow passing different styles to the container and the button

@ethanshar
Copy link
Collaborator

Hi @ckuijjer
Thanks for submitting a PR.
Regarding your change, I suggest adding a dedicated containerStyle prop for those who still want to style the whole component container.

@ethanshar ethanshar merged commit 8f20379 into wix:master Jan 3, 2021
@ckuijjer ckuijjer deleted the feat/radio-button-customize-styling branch January 3, 2021 12:56
M-i-k-e-l added a commit that referenced this pull request Jan 3, 2021
…-logic

* master:
  Fix lint error
  cleanup eslintrc file
  Infra/useDidUpdate (#1112)
  Support UI presets for Incubator.TextField and set a 'default' preset (#1111)
  Fix lint issues
  fix radioButton lint errors and generate types
  Fix/imageSource deprecation (#1115)
  Typescript/tab controller move to function component (#1098)
  Feat/radio button customize styling (#1092)
  bug fixes for TabBar refactor (#1106)
  Update ios target to 11
  prettify file
  Fix icon size in badges example screen (#1104)
  icon prop - fix type to be both number and object. (#1086)
  enable eslint on both ts and js files (#1101)
  fix eslint (#1107)

# Conflicts:
#	demo/src/screens/componentScreens/FaderScreen.tsx
#	src/components/fader/index.tsx
#	src/components/tabController/FadedScrollView.tsx
#	src/components/tabController/TabBar.tsx
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

Successfully merging this pull request may close these issues.

None yet

2 participants