I was wondering whether it is possible to fill a parent button with a radio button and remove the default radio button styling, keeping the radio button functionality for the button.
<button>
<input type='radio' />
</button>
I was wondering whether it is possible to fill a parent button with a radio button and remove the default radio button styling, keeping the radio button functionality for the button.
<button>
<input type='radio' />
</button>
Hopping this is the desired behavior, this is my solution:
button input[type="radio"] {
/* Add if not using autoprefixer */
-webkit-appearance: none;
appearance: none;
/* For iOS < 15 to remove gradient background */
background-color: #fff;
/* Not removed via appearance */
margin: 0;
width:100px;
}
<button>
<input type='radio' />
</button>