From f5efa42ccd5af18f0a974c8dab034d5546f4690e Mon Sep 17 00:00:00 2001 From: Zeeshan Tamboli Date: Mon, 19 Sep 2022 14:06:58 +0530 Subject: [PATCH] [TextField] Fix conflict with `Bootstrap` even when label is not defined (#34343) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: MichaƂ Dudak --- packages/mui-material/src/OutlinedInput/NotchedOutline.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/mui-material/src/OutlinedInput/NotchedOutline.js b/packages/mui-material/src/OutlinedInput/NotchedOutline.js index ee0949e109263d..f043b51fce5c70 100644 --- a/packages/mui-material/src/OutlinedInput/NotchedOutline.js +++ b/packages/mui-material/src/OutlinedInput/NotchedOutline.js @@ -21,6 +21,7 @@ const NotchedOutlineRoot = styled('fieldset')({ const NotchedOutlineLegend = styled('legend')(({ ownerState, theme }) => ({ float: 'unset', // Fix conflict with bootstrap + width: 'auto', // Fix conflict with bootstrap overflow: 'hidden', // Fix Horizontal scroll when label too long ...(!ownerState.withLabel && { padding: 0, @@ -32,7 +33,6 @@ const NotchedOutlineLegend = styled('legend')(({ ownerState, theme }) => ({ }), ...(ownerState.withLabel && { display: 'block', // Fix conflict with normalize.css and sanitize.css - width: 'auto', // Fix conflict with bootstrap padding: 0, height: 11, // sync with `lineHeight` in `legend` styles fontSize: '0.75em',