2if (!defined(
'ISLOADEDBYSTEELSHEET')) {
3 die(
'Must be call by steelsheet');
12 font-weight: 700 !important;
16 vertical-align: baseline;
17 border-radius: .25rem;
18 transition: color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;
21 border-color: rgba(255,255,255,0);
22 box-sizing: border-box;
29.tabBar .arearef .statusref .badge-status, .tabBar .arearefnobottom .statusref .badge-status {
34@media only screen and (max-width: 767px)
36 .tabBar .arearef .statusref .badge-status, .tabBar .arearefnobottom .statusref .badge-status {
42.badge-pill, .tabs .badge {
45 border-radius: 0.25rem;
52 vertical-align: text-top;
55a.badge:focus, a.badge:hover {
56 text-decoration: none;
59.liste_titre .badge:not(.nochangebackground) {
60 background-color: <?php print $badgeSecondary; ?>;
65 padding: 2px 7px 2px 7px;
66 background-color: #e4e4e4;
75 color: #fff !important;
76 background-color: <?php print $badgePrimary; ?>;
78a.badge-primary.focus, a.badge-primary:focus {
80 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgePrimary, 0.5); ?>;
82a.badge-primary:focus, a.badge-primary:hover {
83 color: #fff !important;
84 background-color: <?php print
colorDarker($badgePrimary, 10); ?>;
88.badge-secondary, .tabs .badge {
89 color: #fff !important;
90 background-color: <?php print $badgeSecondary; ?>;
92a.badge-secondary.focus, a.badge-secondary:focus {
94 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeSecondary, 0.5); ?>;
96a.badge-secondary:focus, a.badge-secondary:hover {
97 color: #fff !important;
98 background-color: <?php print
colorDarker($badgeSecondary, 10); ?>;
103 color: #fff !important;
104 background-color: <?php print $badgeSuccess; ?>;
106a.badge-success.focus, a.badge-success:focus {
108 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeSuccess, 0.5); ?>;
110a.badge-success:focus, a.badge-success:hover {
111 color: #fff !important;
112 background-color: <?php print
colorDarker($badgeSuccess, 10); ?>;
117 color: #fff !important;
118 background-color: <?php print $badgeDanger; ?>;
120a.badge-danger.focus, a.badge-danger:focus {
122 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeDanger, 0.5); ?>;
124a.badge-danger:focus, a.badge-danger:hover {
125 color: #fff !important;
126 background-color: <?php print
colorDarker($badgeDanger, 10); ?>;
131 color: #fff !important;
132 background-color: <?php print $badgeWarning; ?>;
134a.badge-warning.focus, a.badge-warning:focus {
136 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeWarning, 0.5); ?>;
138a.badge-warning:focus, a.badge-warning:hover {
139 color: #212529 !important;
140 background-color: <?php print
colorDarker($badgeWarning, 10); ?>;
144body[
class*=
"colorblind-"] .badge-warning {
145 background-color: <?php print $colorblind_deuteranopes_badgeWarning; ?>;
147body[
class*=
"colorblind-"] a.badge-warning.focus,body[
class^=
"colorblind-"] a.badge-warning:focus {
148 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($colorblind_deuteranopes_badgeWarning, 0.5); ?>;
150body[
class*=
"colorblind-"] a.badge-warning:focus, a.badge-warning:hover {
151 background-color: <?php print
colorDarker($colorblind_deuteranopes_badgeWarning, 10); ?>;
156 color: #fff !important;
157 background-color: <?php print $badgeInfo; ?>;
159a.badge-info.focus, a.badge-info:focus {
161 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeInfo, 0.5); ?>;
163a.badge-info:focus, a.badge-info:hover {
164 color: #fff !important;
165 background-color: <?php print
colorDarker($badgeInfo, 10); ?>;
170 color: #212529 !important;
171 background-color: <?php print $badgeLight; ?>;
173a.badge-light.focus, a.badge-light:focus {
175 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeLight, 0.5); ?>;
177a.badge-light:focus, a.badge-light:hover {
178 color: #212529 !important;
179 background-color: <?php print
colorDarker($badgeLight, 10); ?>;
184 color: #fff !important;
185 background-color: <?php print $badgeDark; ?>;
187a.badge-dark.focus, a.badge-dark:focus {
189 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeDark, 0.5); ?>;
191a.badge-dark:focus, a.badge-dark:hover {
192 color: #fff !important;
193 background-color: <?php print
colorDarker($badgeDark, 10); ?>;
197@media only screen and (max-width: 570px)
199 span.badge.badge-status {
202 text-overflow: ellipsis;
209for ($i = 0; $i <= 10; $i++) {
211 _createStatusBadgeCss($i,
'',
"STATUS".$i);
214 _createStatusBadgeCss($i,
'colorblind_deuteranopes_',
"COLORBLIND STATUS".$i,
'body[class*="colorblind-"] ');
217_createStatusBadgeCss(
'1b',
'',
"STATUS1b");
218_createStatusBadgeCss(
'4b',
'',
"STATUS4b");
230function _createStatusBadgeCss($statusName, $statusVarNamePrefix =
'', $commentLabel =
'', $cssPrefix =
'')
233 global ${$statusVarNamePrefix.
'badgeStatus'.$statusName}, ${$statusVarNamePrefix.
'badgeStatus_textColor'.$statusName};
235 if (!empty(${$statusVarNamePrefix.
'badgeStatus'.$statusName})) {
236 print
"\n/* ".strtoupper($commentLabel).
" */\n";
238 $thisBadgeBackgroundColor = $thisBadgeBorderColor = ${$statusVarNamePrefix.
'badgeStatus'.$statusName};
240 $TBadgeBorderOnly = array(
'0',
'1b',
'3',
'4b',
'5',
'7',
'10');
241 $thisBadgeTextColor =
colorIsLight(${$statusVarNamePrefix.
'badgeStatus'.$statusName}) ?
'#212529' :
'#ffffff';
243 if (!empty(${$statusVarNamePrefix.
'badgeStatus_textColor'.$statusName})) {
244 $thisBadgeTextColor = ${$statusVarNamePrefix.
'badgeStatus_textColor'.$statusName};
247 if (in_array((
string) $statusName, $TBadgeBorderOnly)) {
248 $thisBadgeTextColor =
'#212529';
249 $thisBadgeBackgroundColor =
"";
252 if (in_array((
string) $statusName, array(
'0',
'5',
'9'))) {
253 $thisBadgeTextColor =
'#999999';
255 if (in_array((
string) $statusName, array(
'6'))) {
256 $thisBadgeTextColor =
'#777777';
259 print $cssPrefix.
".badge-status".$statusName.
" {\n";
260 print
" color: ".$thisBadgeTextColor.
" !important;\n";
261 if (in_array((
string) $statusName, $TBadgeBorderOnly)) {
262 print
" border-color: ".$thisBadgeBorderColor.
" !important;\n";
264 print
" background-color: ".$thisBadgeBackgroundColor.
" !important;\n";
267 print $cssPrefix.
".font-status".$statusName.
" {\n";
268 print
" color: ".$thisBadgeBackgroundColor.
" !important;\n";
271 print $cssPrefix.
".badge-status".$statusName.
".focus, ".$cssPrefix.
".badge-status".$statusName.
":focus {\n";
272 print
" outline: 0;\n";
273 print
" box-shadow: 0 0 0 0.2rem ".colorHexToRgb($thisBadgeBackgroundColor, 0.5).
" !important;\n";
276 print $cssPrefix.
".badge-status".$statusName.
":focus, ".$cssPrefix.
".badge-status".$statusName.
":hover {\n";
277 print
" color: ".$thisBadgeTextColor.
" !important;\n";
279 if (in_array((
string) $statusName, $TBadgeBorderOnly)) {
280 print
" border-color: ".colorDarker($thisBadgeBorderColor, 10).
" !important;\n";
colorHexToRgb($hex, $alpha=false, $returnArray=false)
colorDarker($hex, $percent)
colorIsLight($stringcolor)
Return true if the color is light.