-
Notifications
You must be signed in to change notification settings - Fork 4
fix: match inputs with figma styles #261
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -83,7 +83,10 @@ const SearchInput = ({ term, onSearch, placeholder = "Search...", debounced }) = | |||||||||||||||||||
| "& .MuiOutlinedInput-root": { | ||||||||||||||||||||
| height: "36px", | ||||||||||||||||||||
| paddingX: 1 | ||||||||||||||||||||
| }, | ||||||||||||||||||||
| }, | ||||||||||||||||||||
| "& .MuiOutlinedInput-root .MuiOutlinedInput-notchedOutline": { borderColor: "rgba(0, 0, 0, 0.23)" }, | ||||||||||||||||||||
| "& .MuiOutlinedInput-root:hover .MuiOutlinedInput-notchedOutline": { borderColor: "rgba(0, 0, 0, 0.23)" }, | ||||||||||||||||||||
| "& .MuiOutlinedInput-root.Mui-focused .MuiOutlinedInput-notchedOutline": { borderColor: "primary.main" } | ||||||||||||||||||||
|
Comment on lines
+87
to
+89
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Border-state overrides conflict with the centralized theme contract. At Line 87-89, Suggested fix sx={{
"& .MuiOutlinedInput-root": {
height: "36px",
paddingX: 1
- },
- "& .MuiOutlinedInput-root .MuiOutlinedInput-notchedOutline": { borderColor: "rgba(0, 0, 0, 0.23)" },
- "& .MuiOutlinedInput-root:hover .MuiOutlinedInput-notchedOutline": { borderColor: "rgba(0, 0, 0, 0.23)" },
- "& .MuiOutlinedInput-root.Mui-focused .MuiOutlinedInput-notchedOutline": { borderColor: "primary.main" }
+ }
}}📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||
| }} | ||||||||||||||||||||
| /> | ||||||||||||||||||||
| ); | ||||||||||||||||||||
|
|
||||||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,49 @@ | ||
| /** | ||
| * Copyright 2026 OpenStack Foundation | ||
| * Licensed under the Apache License, Version 2.0 (the "License"); | ||
| * you may not use this file except in compliance with the License. | ||
| * You may obtain a copy of the License at | ||
| * http://www.apache.org/licenses/LICENSE-2.0 | ||
| * Unless required by applicable law or agreed to in writing, software | ||
| * distributed under the License is distributed on an "AS IS" BASIS, | ||
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| * */ | ||
|
|
||
| import { createTheme } from "@mui/material/styles"; | ||
| import KeyboardArrowDownIcon from "@mui/icons-material/KeyboardArrowDown"; | ||
|
|
||
| const uiCoreThemeOverrides = { | ||
| components: { | ||
| MuiOutlinedInput: { | ||
| styleOverrides: { | ||
| notchedOutline: { | ||
| borderColor: "#000" | ||
| }, | ||
| root: { | ||
| "&:hover .MuiOutlinedInput-notchedOutline": { | ||
| borderColor: "#000" | ||
| }, | ||
| "&.Mui-focused .MuiOutlinedInput-notchedOutline": { | ||
| borderColor: "#000" | ||
| } | ||
| } | ||
| } | ||
| }, | ||
| MuiSelect: { | ||
| defaultProps: { | ||
| IconComponent: KeyboardArrowDownIcon | ||
| }, | ||
| styleOverrides: { | ||
| icon: { | ||
| fontSize: "24px", | ||
| width: "24px", | ||
| height: "24px" | ||
| } | ||
| } | ||
| } | ||
| } | ||
| }; | ||
|
|
||
| export const CustomThemeBase = createTheme(uiCoreThemeOverrides); | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think we need to createTheme in uicore, just export the definitions and let the client app use it as they need. Also please name it MuiBaseCustomTheme |
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@smarcet another example, we need to standarize these colors and use one in the color palette or use a custom one set on CustomTheme. If for some reason we don't want to do that because is too specific, then we should use one of the definitions gray[500] or something. In this particular case @priscila-moneo looks like this color is the default for border color on outline variant so I don't understand why are you overriding with that same color
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The override is intentional. The outlined variant default border color was changed to #000, but according to the current Figma designs, the Search input should keep using the previous border color instead of inheriting the new default. That's why the color is explicitly set here.


Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consistency is key in design systems. We should check with design team and see which one should be used and if it's differentiated by input type categorize that difference so it can be referenced the same way by all input types of that category.