Display all badges on all services, including the ones that are undefined
All checks were successful
continuous-integration/drone/pr Build is passing
All checks were successful
continuous-integration/drone/pr Build is passing
This commit is contained in:
parent
e411796241
commit
bf4b4e2770
|
@ -6,7 +6,7 @@ status:
|
|||
css_class: "positive"
|
||||
|
||||
partial:
|
||||
name: Delvis
|
||||
name: delvis
|
||||
description: Tjenesten lever delvist op til det badget dækker over. Dog i en sådan grad at vi mener det er værd at fremhæve.
|
||||
css_class: "partial"
|
||||
|
||||
|
@ -15,3 +15,8 @@ status:
|
|||
description: Tjenesten lever ikke op til det badget dækker over.
|
||||
css_class: "negative"
|
||||
|
||||
none:
|
||||
name: uoplyst
|
||||
description: Dette badge er udefineret for denne tjeneste. Dette skyldes sansynligvis, at vi mangler en klar redegørelse.
|
||||
css_class: "none"
|
||||
|
||||
|
|
|
@ -327,6 +327,11 @@ dl.dl-services,
|
|||
border: 5px solid #cc4;
|
||||
}
|
||||
|
||||
.badge-status-none {
|
||||
@extend .badge-status;
|
||||
border: 5px solid #888;
|
||||
}
|
||||
|
||||
@media(max-width:1000px) {
|
||||
:root {
|
||||
--base-grid : 40px;
|
||||
|
|
|
@ -11,15 +11,17 @@
|
|||
{{ range $translated_badges.badges.active_badges }}
|
||||
|
||||
{{- $badge := index $translated_badges.badges.badges . }}
|
||||
{{- $status := index $page_params.service_badges . -}}
|
||||
<div class="badge-icon badge-status-{{ $status }}">
|
||||
{{- $status_name := default "none" (index $page_params.service_badges .) -}}
|
||||
{{- $status := index $translated_badges.status.status $status_name -}}
|
||||
|
||||
<div class="badge-icon badge-status-{{ $status_name }}">
|
||||
{{ $svg := printf "static/static/img/badges/%s" $badge.icon }}
|
||||
{{ $svg | readFile | safeHTML }}
|
||||
</div>
|
||||
|
||||
<div class="badge-name">
|
||||
{{ title $badge.name }}<br>
|
||||
= {{ i18n ($status | printf "service_badges_status_%s") }}
|
||||
= {{ $status.name }}
|
||||
</div>
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue