File tree Expand file tree Collapse file tree 3 files changed +9
-3
lines changed
themes/geekboot/layouts/partials Expand file tree Collapse file tree 3 files changed +9
-3
lines changed Original file line number Diff line number Diff line change 11{{/* Pass a schema and find the currently active version and return a dict of (version: < version > , schema: < schema > ) */}}
22{{ $version := "" }}
33{{ $schema := dict }}
4+ {{ $deprecated := false }}
45
56{{ range .versions }}
67 {{ if index . "storage" }}
78 {{ $version = .name }}
89 {{ $schema = .schema }}
10+ {{ $deprecated = .deprecated }}
911 {{ else if (and (index . "served") (not $version)) }}
1012 {{ $version = .name }}
1113 {{ $schema = .schema }}
14+ {{ $deprecated = .deprecated }}
1215 {{ end }}
1316{{ end }}
1417
1518{{ return (dict "version" $version
16- "schema" $schema)
19+ "schema" $schema
20+ "deprecated" $deprecated)
1721}}
1822
1923
Original file line number Diff line number Diff line change 22{{ $group := .group }}
33{{ $kind := .kind }}
44{{ $version := .version }}
5+ {{ $deprecated := .deprecated }}
56{{ $bigName := partial "apiBuilder/checkBigName" $kind }}
67
78{{/* Collapse/Expand Button and Kind name */}}
1112
1213 {{/* CRD name text */}}
1314 < button class ="crd-root collapsed align-middle " data-bs-toggle ="collapse " data-bs-target ="#{{$kind}} " type ="button " aria-expanded ="false " aria-controls ="{{$kind}} ">
14- < span class ="align-middle {{ $kind }} "> < a class ="expansion-link " name ="{{ $kind }} "> {{ $kind }}</ a > </ span >
15+ < span class ="align-middle {{ $kind }} "> < a class ="expansion-link " name ="{{ $kind }} "> {{ $kind }}{{ if $deprecated }} (deprecated){{ end }} </ a > </ span >
1516 </ button >
1617</ div >
1718
Original file line number Diff line number Diff line change 2727 {{ $versionAndSchema := partial "apiBuilder/getVersionAndSchema" $crdContent.spec }}
2828 {{ $schema := $versionAndSchema.schema.openAPIV3Schema }}
2929 {{ $version := $versionAndSchema.version }}
30+ {{ $deprecated := $versionAndSchema.deprecated }}
3031 {{ $description := $schema.description }}
3132
3233 {{/* The div containing the entire CRD information including the Expand All/Collapse All row */}}
3334 < div class ="crd-root-row crd-container row align-middle bigName-row " data-kind ="{{ $kind }} " data-group ="{{ $group }}-{{ $kind}} " data-version ="{{ $version }}-{{ $kind }} ">
3435
3536 {{/* generate the GKV line to expand/collapse the CRD data */}}
36- {{ partial "apiBuilder/printGKVExpander" (dict "group" $group "version" $version "kind" $kind) }}
37+ {{ partial "apiBuilder/printGKVExpander" (dict "group" $group "version" $version "kind" $kind "deprecated" $deprecated ) }}
3738
3839
3940 {{/* The container to show/hide with information related to the CRD */}}
You can’t perform that action at this time.
0 commit comments