FEATURE: Add `selectTag`, `tags`, and `categories` to plugin outlet. (#38)

This commit is contained in:
Jordan Vidrine 2021-03-23 08:50:44 -05:00 committed by GitHub
parent f61de2d871
commit a5bd6954c0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 1 deletions

View File

@ -7,6 +7,10 @@ export default Controller.extend({
this.indexController.send("updateSelectedCategories", category);
return false;
},
updateSelectedTags(tag) {
this.indexController.send("updateSelectedTags", tag);
return false;
},
performSearch(term) {
this.indexController.send("performSearch", term);
return false;

View File

@ -1,5 +1,5 @@
<div class="docs">
{{plugin-outlet name="before-docs-search" args=(hash selectCategory=(action "updateSelectedCategories") tags=indexController.tags )}}
{{plugin-outlet name="before-docs-search" args=(hash selectCategory=(action "updateSelectedCategories") selectTag=(action "updateSelectedTags") tags=indexController.tags categories=indexController.categories )}}
{{docs-search
searchTerm=(readonly indexController.searchTerm)
onSearch=(action "performSearch")