openmct/platform/commonUI/general/res/sass/_limits.scss
Charles Hacskaylo a8856c0612 [Frontend] Platform-specific mods to limits
vista#54
Refactor limits into multiple classes, separating
upr/lwr from red/yellow;
Modded SineWaveLimitCapability accordingly;
Normalized upr/lwr glyphs;
(cherry picked from commit a26d71b)
2015-10-27 11:43:28 -07:00

49 lines
1.3 KiB
SCSS

@mixin limitGlyph($iconColor, $glyph: $glyphLimit) {
&:before {
color: $iconColor;
content: $glyph;
font-family: symbolsfont;
display: inline;
margin-right: $interiorMarginSm;
}
}
/*[class*="s-limit"] {
//white-space: nowrap;
&:before {
display: inline-block;
font-family: symbolsfont;
font-size: 0.75em;
font-style: normal !important;
margin-right: $interiorMarginSm;
vertical-align: middle;
}
}*/
.s-limit-red { background: $colorLimitRedBg !important; }
.s-limit-yellow { background: $colorLimitYellowBg !important; }
// Handle limit when applied to a tr
tr[class*="s-limit"] {
&.s-limit-red td:first-child {
@include limitGlyph($colorLimitRedIc);
}
&.s-limit-yellow td:first-child {
@include limitGlyph($colorLimitYellowIc);
}
&.s-limit-upr td:first-child:before { content:$glyphLimitUpr; }
&.s-limit-lwr td:first-child:before { content:$glyphLimitLwr; }
}
// Handle limit when applied directly to a non-tr element
:not(tr)[class*="s-limit"] {
&.s-limit-red {
@include limitGlyph($colorLimitRedIc);
}
&.s-limit-yellow {
@include limitGlyph($colorLimitYellowIc);
}
&.s-limit-upr:before { content:$glyphLimitUpr; }
&.s-limit-lwr:before { content:$glyphLimitLwr; }
}