Files
docker-docs/layouts/_shortcodes/summary-bar.html
T
Craig Osterhout b34003b104 ai-gov: rearrange and feedback (#26412)
<!--Delete sections as needed -->

## Description

Rearrange AI Gov section and apply internal feedback.

https://deploy-preview-26412--docsdocker.netlify.app/ai/governance/

## Related issues or tickets

https://docs-review-portal.internal.tools/comments?build_id=18

## Reviews

<!-- Notes for reviewers here -->
<!-- List applicable reviews (optionally @tag reviewers) -->

- [ ] Technical review
- [ ] Editorial review
- [ ] Product review

---------

Signed-off-by: Craig Osterhout <craig.osterhout@docker.com>
2026-11-03 10:30:14 -08:00

88 lines
2.6 KiB
HTML

{{ $featureName := .Get "feature_name" }}
{{ $feature := index hugo.Data.summary $featureName }}
{{ if not $feature }}
{{ errorf "[summary-bar] invalid feature: %s %v" $featureName .Position }}
{{ end }}
{{ if $feature }}
{{ $subscriptionIcons := dict
"Business" "building-office"
"Team" "user-group"
"Pro" "user-plus"
"Personal" "user"
"Available to all" "globe-alt"
"Docker Hardened Images Enterprise" "/icons/dhi.svg"
"Docker Hardened Images Select or Enterprise" "/icons/dhi.svg"
"Docker Offload" "cloud"
"AI Governance" "lock-closed"
}}
{{ $availabilityIcons := dict
"Experimental" "beaker"
"Beta" "bolt"
"Early Access" "rocket-launch"
"GA" "check-circle"
"Retired" "archive-box"
}}
{{ $requiresIcon := "arrow-down-circle" }}
{{ $forIcons := dict
"Administrators" "shield-check"
"Individuals" "user-circle"
}}
<div class="not-prose summary-bar">
{{ with $feature.subscription }}
<div class="flex flex-wrap gap-1">
<span class="font-bold">Subscription:</span>
{{ range . }}
<span>{{ . }}</span>
<span class="icon-svg icon-sm">
{{ $icon := index $subscriptionIcons . }}
{{ if $icon }}
{{ partialCached "icon" $icon $icon }}
{{ else }}
{{ partialCached "icon" "question-mark-circle" "question-mark-circle" }}
{{ end }}
</span>
{{ end }}
</div>
{{ end }}
{{ with $feature.availability }}
{{ $availabilityText := . }}
<div class="flex flex-wrap gap-1">
<span class="font-bold">Availability:</span>
<span>
{{ $availabilityText }}
{{ range $key, $icon := $availabilityIcons }}
{{ if in $availabilityText $key }}
<span class="icon-svg icon-sm">{{ partialCached "icon" $icon $icon }}</span>
{{ end }}
{{ end }}
</span>
</div>
{{ end }}
{{ with $feature.requires }}
<div class="flex flex-wrap gap-1">
<span class="font-bold">Requires:</span>
<span>{{ . | markdownify }}</span>
<span class="icon-svg icon-sm">
{{ partialCached "icon" $requiresIcon $requiresIcon }}
</span>
</div>
{{ end }}
{{ with $feature.for }}
<div class="flex flex-wrap gap-1">
<span class="font-bold">For:</span>
<span>{{ . }}</span>
{{ with index $forIcons . }}
<span class="icon-svg icon-sm">
{{ partialCached "icon" . . }}
</span>
{{ end }}
</div>
{{ end }}
</div>
{{ end }}