Skip to content

Commit 05c6521

Browse files
Update single.html
1 parent eb9c707 commit 05c6521

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

layouts/operate/single.html

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,38 +14,38 @@ <h1>
1414
{{ end }}
1515
{{ .Title }}</h1>
1616
{{ with .Params.description }}<p class="text-lg -mt-5 mb-10">{{ . | markdownify }}</p>{{ end }}
17-
{{ if .Params.categories }}
17+
{{ if .Params.categories }}
1818
<div class="post-categories" style="display: table;">
1919
<table style="border-collapse: separate; border-spacing: 0; background-color: #ffffff;">
2020
<thead>
2121
<tr>
2222
{{ $visibleCategories := slice }}
2323
{{ range .Params.categories }}
2424
{{ if not (in (slice "docs" "operate" "integrate" "develop") .) }}
25-
{{ $visibleCategories = append $visibleCategories . }}
25+
{{ $visibleCategories = $visibleCategories | append (slice .) }} <!-- Corrected Append -->
2626
{{ end }}
2727
{{ end }}
2828
{{ range $index, $element := $visibleCategories }}
2929
{{ $displayName := $element }}
3030
{{ $color := "#ffffff" }} <!-- Default background color (white) -->
3131
{{ if eq $element "rs" }}
3232
{{ $displayName = "Redis Enterprise Software" }}
33-
{{ $color = "#DCFF1E" }} <!-- Yellow background for Redis Enterprise Software -->
33+
{{ $color = "#DCFF1E" }}
3434
{{ else if eq $element "rc" }}
3535
{{ $displayName = "Redis Cloud" }}
36-
{{ $color = "#80DBFF" }} <!-- Blue background for Redis Cloud -->
36+
{{ $color = "#80DBFF" }}
3737
{{ else if eq $element "kubernetes" }}
3838
{{ $displayName = "Redis Enterprise for Kubernetes" }}
39-
{{ $color = "#8A99A0" }} <!-- Light grey background for Kubernetes -->
39+
{{ $color = "#8A99A0" }}
4040
{{ else if eq $element "oss" }}
4141
{{ $displayName = "Redis Source Available" }}
42-
{{ $color = "#C795E3" }} <!-- Purple background for Redis Source Available -->
42+
{{ $color = "#C795E3" }}
4343
{{ else if eq $element "stack" }}
4444
{{ $displayName = "Redis Stack" }}
45-
{{ $color = "#49859C" }} <!-- Medium blue background for Redis Stack -->
45+
{{ $color = "#49859C" }}
4646
{{ else if eq $element "redisinsight" }}
4747
{{ $displayName = "Redis Insight" }}
48-
{{ $color = "#FD4439" }} <!-- Red background for Redis Insight -->
48+
{{ $color = "#FD4439" }}
4949
{{ end }}
5050
<th style="border: 1px solid #ccc; padding: 8px; text-align: left; font-weight: normal; background-color: {{ $color }}; {{ if eq $index 0 }}border-top-left-radius: 10px; border-bottom-left-radius: 10px;{{ end }}{{ if eq $index (sub (len $visibleCategories) 1) }}border-top-right-radius: 10px; border-bottom-right-radius: 10px;{{ end }}">
5151
{{ $displayName }}
@@ -64,6 +64,7 @@ <h1>
6464

6565

6666

67+
6768
<!-- In-page banner -->
6869
{{ if .Params.bannerText }}
6970
<!-- Banner params are in the current page's front matter -->

0 commit comments

Comments
 (0)