diff --git a/assets/js/registrySearch.js b/assets/js/registrySearch.js index d91c590585a3..c1a9055d5adf 100644 --- a/assets/js/registrySearch.js +++ b/assets/js/registrySearch.js @@ -129,6 +129,10 @@ function executeSearch(searchQuery) { document.querySelector('#input-s').value = searchQuery; document.querySelector('#default-body').style.display = 'none'; document.querySelector('#search-results').innerHTML = ''; + let categoryElement = document.getElementById('categories-section'); + if (categoryElement) { + categoryElement.classList.add('d-none'); + } document.getElementById('search-loading').style.display = 'block'; const run = function (searchQuery) { @@ -210,6 +214,11 @@ function setInput(key, value) { // Filters items based on language and component filters function updateFilters() { + let element = document.getElementById('default-body'); + element.classList.remove('d-none'); + let categoryElement = document.getElementById('categories-section'); + categoryElement.classList.add('d-none'); + let allItems = [...document.getElementsByClassName('registry-entry')]; if (selectedComponent === 'all' && selectedLanguage === 'all') { allItems.forEach((element) => element.classList.remove('d-none')); diff --git a/assets/scss/_registry.scss b/assets/scss/_registry.scss index 06ed0693de9f..376b191c990d 100644 --- a/assets/scss/_registry.scss +++ b/assets/scss/_registry.scss @@ -10,6 +10,7 @@ &.badge-#{$component} { color: white; background-color: $color; + color: white; } } diff --git a/content/en/ecosystem/registry/_index.md b/content/en/ecosystem/registry/_index.md index 0b671e5499d2..488d156a3173 100644 --- a/content/en/ecosystem/registry/_index.md +++ b/content/en/ecosystem/registry/_index.md @@ -33,4 +33,6 @@ weight: 20 {{< ecosystem/registry/search-form >}} +{{< ecosystem/registry/categories>}} + {{< /blocks/section >}} diff --git a/layouts/partials/ecosystem/registry/category.html b/layouts/partials/ecosystem/registry/category.html new file mode 100644 index 000000000000..ec373f1b5dd2 --- /dev/null +++ b/layouts/partials/ecosystem/registry/category.html @@ -0,0 +1,243 @@ +
+ + by + {{ range $index, $author := $entry.authors -}} + {{ if $index }}, {{ end }} + {{ if eq $author.name "OpenTelemetry Authors" -}} + 🔠{{ $author.name }} 🔠+ {{ else if isset $author "url" }} + {{ $href := printf "href=%q" $author.url | safeHTMLAttr -}} + {{ $author.name }} + {{ else -}} + {{ $author.name -}} + {{ end }} + {{ end }} + +
+{{ (partial .installTemplate .) | markdownify -}} +
+ {{ end -}} + {{- end -}} +