Skip to content

Commit 74d7244

Browse files
committed
Improves graph search UX
1 parent 11e769a commit 74d7244

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/webviews/apps/shared/components/search/search-box.ts

+4-1
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ export class GlSearchBox extends GlElement {
159159
resultsLoaded = false;
160160

161161
get hasResults() {
162-
return this.total > 1;
162+
return this.total >= 1;
163163
}
164164

165165
@query('gl-search-input')
@@ -227,6 +227,9 @@ export class GlSearchBox extends GlElement {
227227
}
228228

229229
private get resultsHtml() {
230+
if (!this.value) {
231+
return html`<span class="count"></span>`;
232+
}
230233
if (this.searching) {
231234
return html`<gl-tooltip hoist placement="top" class="count"
232235
><code-icon icon="loading" modifier="spin"></code-icon><span slot="content">Searching...</span>

0 commit comments

Comments
 (0)