A <select>
dropdown in Webflow may show white text on a white background when focused if form field styles or browser defaults conflict. Here’s how to fix that by properly adjusting focus and text color styles in Webflow.
1. Set Base Styling for the Select Field
- Select the
<select>
field on the canvas. - In the right panel under Style, set:
- Background color to a visible color (e.g., light gray or white).
- Text color to black or your desired legible color.
- Border and border radius as needed for aesthetic.
2. Apply Styling to the Focus State
- With the same
<select>
element selected, go to the States dropdown (top-right of the Style panel) and choose Focused. - Set the Text color and Background color again here (focused state may override normal state).
- For example: white background and black text.
- Check other properties like outline, shadow, or border in this state that might hide the field or text.
3. Confirm Styling Is Not Inherited or Overridden
- Make sure no parent elements apply conflicting font or background styling.
- If using combo classes, check whether any style from a different state or combo class is overriding your focus settings.
- Use Webflow’s Navigator and Style Manager to trace and confirm no conflicting styles are applied.
4. Test in Multiple Browsers
- Browser defaults may override styles, especially for select elements.
- Publish the site and test in major browsers like Chrome, Firefox, and Safari.
- If Safari still shows white-on-white, set system font fallback or consider using a custom dropdown (see below).
5. Consider a Custom Dropdown (Optional Advanced Fix)
- Web browsers limit the styling of native
<select>
elements. - For full control, use Webflow’s custom dropdown component:
- Add a
Dropdown
component from the Add panel (instead of a select field). - Customize with full styling and interactions.
- Use custom JavaScript (outside Webflow’s native tools) to sync with forms if needed.
Summary
To avoid white-on-white select field issues on focus, set text and background colors explicitly for both the normal and focus states of the <select>
field in Webflow’s Style panel. If browser limitations persist, consider replacing the native select field with a custom dropdown component for full styling control.