add cncf-landscape shortcode for training page

pull/24014/head
Arhell 2020-10-30 02:07:55 +02:00
parent 0ae30992c6
commit 59cdc2aaec
2 changed files with 6 additions and 3 deletions

View File

@ -112,7 +112,6 @@ class: training
</center>
</div>
<div class="main-section landscape-section">
<iframe src="https://landscape.cncf.io/category=kubernetes-training-partner&format=logo-mode&grouping=category&embed=yes" frameborder="0" id="landscape" scrolling="no"></iframe>
<script src="https://landscape.cncf.io/iframeResizer.js"></script>
{{< cncf-landscape helpers=false category="kubernetes-training-partner" >}}
</div>
</div>

View File

@ -57,7 +57,11 @@ document.addEventListener("DOMContentLoaded", function () {
</script>
{{- end -}}
<div id="frameHolder">
<iframe frameborder="0" id="landscape" scrolling="no" src="" style="width: 1px; min-width: 100%" title="CNCF Landscape"></iframe>
{{ if ( .Get "category" ) }}
<iframe frameborder="0" id="landscape" scrolling="no" src="https://landscape.cncf.io/category={{ .Get "category" }}&format=logo-mode&grouping=category&embed=yes"></iframe>
{{ else }}
<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>
{{ end }}
<script src="https://landscape.cncf.io/iframeResizer.js"></script>
</div>
{{- end -}}