2if (!defined(
'ISLOADEDBYSTEELSHEET')) {
3 die(
'Must be call by steelsheet');
12 display:
inline-block;
15 font-weight: 700 !important;
19 vertical-align: baseline;
20 border-radius: .25rem;
21 transition: color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;
24 border-color: rgba(255,255,255,0);
25 box-sizing: border-box;
32.tabBar .arearef .statusref .badge-
status, .tabBar .arearefnobottom .statusref .badge-
status {
37@media only screen and (max-width: 767px)
39 .tabBar .arearef .statusref .badge-
status, .tabBar .arearefnobottom .statusref .badge-
status {
45.badge-pill, .tabs .badge {
48 border-radius: 0.25rem;
55 vertical-align: unset;
58a.badge:focus, a.badge:hover {
59 text-decoration: none;
62.liste_titre .badge:not(.nochangebackground) {
63 background-color: <?php print $badgeSecondary; ?>;
68 padding: 2px 7px 2px 7px;
69 background-color: #e4e4e4;
78 color: #fff !important;
79 background-color: <?php print $badgePrimary; ?>;
81a.badge-primary.focus, a.badge-primary:focus {
83 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgePrimary, 0.5); ?>;
85a.badge-primary:focus, a.badge-primary:hover {
86 color: #fff !important;
87 background-color: <?php print
colorDarker($badgePrimary, 10); ?>;
91.badge-secondary, .tabs .badge {
92 color: #fff !important;
93 background-color: <?php print $badgeSecondary; ?>;
95a.badge-secondary.focus, a.badge-secondary:focus {
97 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeSecondary, 0.5); ?>;
99a.badge-secondary:focus, a.badge-secondary:hover {
100 color: #fff !important;
101 background-color: <?php print
colorDarker($badgeSecondary, 10); ?>;
106 color: #fff !important;
107 background-color: <?php print $badgeSuccess; ?>;
109a.badge-success.focus, a.badge-success:focus {
111 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeSuccess, 0.5); ?>;
113a.badge-success:focus, a.badge-success:hover {
114 color: #fff !important;
115 background-color: <?php print
colorDarker($badgeSuccess, 10); ?>;
120 color: #fff !important;
121 background-color: <?php print $badgeDanger; ?>;
123a.badge-danger.focus, a.badge-danger:focus {
125 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeDanger, 0.5); ?>;
127a.badge-danger:focus, a.badge-danger:hover {
128 color: #fff !important;
129 background-color: <?php print
colorDarker($badgeDanger, 10); ?>;
134 color: #fff !important;
135 background-color: <?php print $badgeWarning; ?>;
137a.badge-warning.focus, a.badge-warning:focus {
139 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeWarning, 0.5); ?>;
141a.badge-warning:focus, a.badge-warning:hover {
142 color: #212529 !important;
143 background-color: <?php print
colorDarker($badgeWarning, 10); ?>;
147body[
class*=
"colorblind-"] .badge-warning {
148 background-color: <?php print $colorblind_deuteranopes_badgeWarning; ?>;
150body[
class*=
"colorblind-"] a.badge-warning.focus,body[
class^=
"colorblind-"] a.badge-warning:focus {
151 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($colorblind_deuteranopes_badgeWarning, 0.5); ?>;
153body[
class*=
"colorblind-"] a.badge-warning:focus, a.badge-warning:hover {
154 background-color: <?php print
colorDarker($colorblind_deuteranopes_badgeWarning, 10); ?>;
159 color: #fff !important;
160 background-color: <?php print $badgeInfo; ?>;
162a.badge-info.focus, a.badge-info:focus {
164 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeInfo, 0.5); ?>;
166a.badge-info:focus, a.badge-info:hover {
167 color: #fff !important;
168 background-color: <?php print
colorDarker($badgeInfo, 10); ?>;
173 color: #212529 !important;
174 background-color: <?php print $badgeLight; ?>;
176a.badge-light.focus, a.badge-light:focus {
178 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeLight, 0.5); ?>;
180a.badge-light:focus, a.badge-light:hover {
181 color: #212529 !important;
182 background-color: <?php print
colorDarker($badgeLight, 10); ?>;
187 color: #fff !important;
188 background-color: <?php print $badgeDark; ?>;
190a.badge-dark.focus, a.badge-dark:focus {
192 box-shadow: 0 0 0 0.2rem <?php print
colorHexToRgb($badgeDark, 0.5); ?>;
194a.badge-dark:focus, a.badge-dark:hover {
195 color: #fff !important;
196 background-color: <?php print
colorDarker($badgeDark, 10); ?>;
200@media only screen and (max-width: 570px)
205 text-overflow: ellipsis;
212for ($i = 0; $i <= 10; $i++) {
214 _createStatusBadgeCss($i,
'',
"STATUS".$i);
217 _createStatusBadgeCss($i,
'colorblind_deuteranopes_',
"COLORBLIND STATUS".$i,
'body[class*="colorblind-"] ');
220_createStatusBadgeCss(
'1b',
'',
"STATUS1b");
221_createStatusBadgeCss(
'4b',
'',
"STATUS4b");
232function _createStatusBadgeCss($statusName, $statusVarNamePrefix =
'', $commentLabel =
'', $cssPrefix =
'')
234 global ${$statusVarNamePrefix.
'badgeStatus'.$statusName}, ${$statusVarNamePrefix.
'badgeStatus_textColor'.$statusName};
236 if (!empty(${$statusVarNamePrefix.
'badgeStatus'.$statusName})) {
237 print
"\n/* ".strtoupper($commentLabel).
" */\n";
239 $thisBadgeBackgroundColor = $thisBadgeBorderColor = ${$statusVarNamePrefix.
'badgeStatus'.$statusName};
242 $TBadgeBorderOnly = array(
'0',
'1b',
'3',
'4b',
'5',
'7',
'10');
243 $thisBadgeTextColor =
colorIsLight(${$statusVarNamePrefix.
'badgeStatus'.$statusName}) ?
'#212529' :
'#ffffff';
245 if (!empty(${$statusVarNamePrefix.
'badgeStatus_textColor'.$statusName})) {
246 $thisBadgeTextColor = ${$statusVarNamePrefix.
'badgeStatus_textColor'.$statusName};
249 if (in_array((
string) $statusName, $TBadgeBorderOnly)) {
250 $thisBadgeTextColor =
'#212529';
251 $thisBadgeBackgroundColor =
"#fff";
254 if (in_array((
string) $statusName, array(
'0',
'5',
'9'))) {
255 $thisBadgeTextColor =
'#999999';
257 if (in_array((
string) $statusName, array(
'6'))) {
258 $thisBadgeTextColor =
'#777777';
262 print $cssPrefix.
".badge-status".$statusName.
" {\n";
263 print
" color: ".$thisBadgeTextColor.
" !important;\n";
264 if (in_array((
string) $statusName, $TBadgeBorderOnly)) {
265 print
" border-color: ".$thisBadgeBorderColor.
" !important;\n";
267 if ($thisBadgeBackgroundColor !=
'') {
268 print
" background-color: ".$thisBadgeBackgroundColor.
" !important;\n";
272 print $cssPrefix.
".font-status".$statusName.
" {\n";
273 if ($thisBadgeBackgroundColor !=
'') {
274 print
" color: ".$thisBadgeBackgroundColor.
" !important;\n";
279 print $cssPrefix.
".badge-status".$statusName.
".focus, ".$cssPrefix.
".badge-status".$statusName.
":focus {\n";
280 print
" outline: 0;\n";
281 print
" box-shadow: 0 0 0 0.2rem ".colorHexToRgb($thisBadgeBackgroundColor, 0.5).
" !important;\n";
284 print $cssPrefix.
".badge-status".$statusName.
":focus, ".$cssPrefix.
".badge-status".$statusName.
":hover {\n";
285 print
" color: ".$thisBadgeTextColor.
" !important;\n";
287 if (in_array((
string) $statusName, $TBadgeBorderOnly)) {
288 print
" border-color: ".colorDarker($thisBadgeBorderColor, 10).
" !important;\n";
print $langs trans("AuditedSecurityEvents").'</strong >< span class="opacitymedium"></span >< br > status
colorHexToRgb($hex, $alpha=false, $returnArray=false)
colorDarker($hex, $percent)
colorIsLight($stringcolor)
Return true if the color is light.