[TextField] Shouldn't `OutlinedInput` have its plain border styling set by theme?

Open
#32,990 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
38/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
javascript, react
Domain
design, frontend

Research direction

Start in packages/mui-material/src/OutlinedInput/OutlinedInput.js at the linked border styling. Read how the plain border currently selects values from theme.palette.mode, then determine which standard palette values should support custom themes. Done means the plain OutlinedInput border is theme-driven rather than hardcoded, with the relevant behavior verified.

Written by the indexing model from the issue text.

Description

discussion scope: text field
Duplicates
  • I have searched the existing issues
Latest version
  • I have tested the latest version
Summary 💡

The OutlinedInput hardcodes the plain (not selected, not hovered) border to one of two values, depending on if it is light or dark theme.

    theme.palette.mode === 'light' ? 'rgba(0, 0, 0, 0.23)' : 'rgba(255, 255, 255, 0.23)';

Code link.

Shouldn't this be based on standard palette values?

Examples 🌈

No response

Motivation 🔦

Ease of use when using custom themes.

Dominant language
JavaScript
Stars
99.1k
Forks
32.5k
Avg merge
2d 17h
Merged PRs (30d)
106

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from mui/material-ui

All issues in mui/material-ui

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.