@@ -100,14 +100,18 @@ const tertiaryPillStyle = {
100100 } ,
101101} ;
102102
103- // Alert severity surface: a gradient from the severity colour at 3% (left) fading to bg-2 (right)
104- // over a bg-2 base, plus the full colour + a 20% tint behind/inside the icon box.
103+ // Alert severity surface: a gradient from the severity colour (left) fading to the base (right),
104+ // plus the full colour + a 20% tint behind/inside the icon box. Light: 3% over bg-2. Dark: the
105+ // tint is lifted to 5% over bgp-2 (#18181B) so it stays visible against the darker canvas.
105106const alertSeverityStyle = ( color : string ) : CSSObject => ( {
106107 background : `linear-gradient(90deg, color-mix(in srgb, ${ color } 3%, transparent) 0%, ${ figVars [ 'bg-2' ] } 100%), ${ figVars [ 'bg-2' ] } ` ,
107108 '.MuiAlert-icon' : {
108109 color,
109110 backgroundColor : `color-mix(in srgb, ${ color } 20%, transparent)` ,
110111 } ,
112+ ...darkScheme ( {
113+ background : `linear-gradient(90deg, color-mix(in srgb, ${ color } 5%, transparent) 0%, ${ figVars [ 'bgp-2' ] } 100%), ${ figVars [ 'bgp-2' ] } ` ,
114+ } ) ,
111115} ) ;
112116
113117// Shared box geometry for the custom selection-control icons (checkbox + radio).
@@ -1063,7 +1067,7 @@ export function getThemedComponents(theme: AppTheme) {
10631067 display : 'flex' ,
10641068 alignItems : 'center' ,
10651069 justifyContent : 'center' ,
1066- borderRadius : '0.5rem ' ,
1070+ borderRadius : '0.75rem ' ,
10671071 boxShadow : `inset 0 0 0 1px ${ figVars [ 'border-0' ] } ` ,
10681072 opacity : 1 ,
10691073 '.MuiSvgIcon-root' : {
@@ -1102,6 +1106,23 @@ export function getThemedComponents(theme: AppTheme) {
11021106 background : 'transparent' ,
11031107 } ,
11041108 } ,
1109+ // Small size (`data-size="small"`): a tighter 2rem icon box with a 0.8rem icon, and
1110+ // 0.75rem / 135% message text. Everything else (radius, gradient, colours) is inherited.
1111+ '&[data-size="small"]' : {
1112+ '.MuiAlert-icon' : {
1113+ width : '2rem' ,
1114+ height : '2rem' ,
1115+ padding : '0.53125rem 0.5rem 0.46875rem 0.5rem' ,
1116+ borderRadius : '0.625rem' ,
1117+ '.MuiSvgIcon-root' : {
1118+ fontSize : '0.8rem' ,
1119+ } ,
1120+ } ,
1121+ '.MuiAlert-message' : {
1122+ fontSize : '0.75rem' ,
1123+ lineHeight : '1.0125rem' ,
1124+ } ,
1125+ } ,
11051126 } ,
11061127 } ,
11071128 defaultProps : {
0 commit comments