Skip to content

Commit 59cdc2a

Browse files
committed
add cncf-landscape shortcode for training page
1 parent 0ae3099 commit 59cdc2a

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

content/en/training/_index.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,6 @@ <h2>Kubernetes Training Partners</h2>
112112
</center>
113113
</div>
114114
<div class="main-section landscape-section">
115-
<iframe src="https://landscape.cncf.io/category=kubernetes-training-partner&format=logo-mode&grouping=category&embed=yes" frameborder="0" id="landscape" scrolling="no"></iframe>
116-
<script src="https://landscape.cncf.io/iframeResizer.js"></script>
115+
{{< cncf-landscape helpers=false category="kubernetes-training-partner" >}}
117116
</div>
118117
</div>

layouts/shortcodes/cncf-landscape.html

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,11 @@
5757
</script>
5858
{{- end -}}
5959
<div id="frameHolder">
60-
<iframe frameborder="0" id="landscape" scrolling="no" src="" style="width: 1px; min-width: 100%" title="CNCF Landscape"></iframe>
60+
{{ if ( .Get "category" ) }}
61+
<iframe frameborder="0" id="landscape" scrolling="no" src="https://landscape.cncf.io/category={{ .Get "category" }}&format=logo-mode&grouping=category&embed=yes"></iframe>
62+
{{ else }}
63+
<iframe frameborder="0" id="landscape" scrolling="no" src="https://landscape.cncf.io/format=logo-mode;embed=yes" style="width: 1px; min-width: 100%" title="CNCF Landscape"></iframe>
64+
{{ end }}
6165
<script src="https://landscape.cncf.io/iframeResizer.js"></script>
6266
</div>
6367
{{- end -}}

0 commit comments

Comments
 (0)