BigW Consortium Gitlab

Commit cf65abd8 by Dennis Tang

no search results state

parent 53e27b8c
......@@ -73,6 +73,9 @@ export default {
searchPlaceholderText() {
return s__('ClusterIntegration|Search machine types');
},
noSearchResultsText() {
return s__('ClusterIntegration|No machine types matched your search');
},
},
created() {
eventHub.$on('zoneSelected', this.fetchMachineTypes);
......@@ -135,6 +138,9 @@ export default {
/>
<div class="dropdown-content">
<ul>
<li v-show="!results.length">
<span class="menu-item">{{ noSearchResultsText }}</span>
</li>
<li
v-for="result in results"
:key="result.id"
......
......@@ -57,6 +57,9 @@ export default {
results() {
return this.projects.filter(item => item.name.toLowerCase().indexOf(this.searchQuery) > -1);
},
noSearchResultsText() {
return s__('ClusterIntegration|No projects matched your search');
},
toggleText() {
if (this.isLoading) {
return s__('ClusterIntegration|Fetching projects');
......@@ -155,6 +158,9 @@ export default {
/>
<div class="dropdown-content">
<ul>
<li v-show="!results.length">
<span class="menu-item">{{ noSearchResultsText }}</span>
</li>
<li
v-for="result in results"
:key="result.project_number"
......
......@@ -67,6 +67,9 @@ export default {
searchPlaceholderText() {
return s__('ClusterIntegration|Search zones');
},
noSearchResultsText() {
return s__('ClusterIntegration|No zones matched your search');
},
},
created() {
eventHub.$on('projectSelected', this.fetchZones);
......@@ -120,6 +123,9 @@ export default {
/>
<div class="dropdown-content">
<ul>
<li v-show="!results.length">
<span class="menu-item">{{ noSearchResultsText }}</span>
</li>
<li
v-for="result in results"
:key="result.id"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment