better text in case of early stopped search
Massimo Melina committed
Jan 9, 2022 at 12:46 UTC
3cbe687064402df027effc3d7ce1363c6b0d046a
1 file changed
+1
-1
frontend/src/BrowseFiles.ts
+1
-1
@@ -32,7 +32,7 @@ function FilesList() {
32
const filter = snap.listFilter > '' && new RegExp(_.escapeRegExp(snap.listFilter),'i')
33
let n = 0 // if I try to use directly the state as counter I get a "too many re-renders" error
34
const ret = h('ul', { className: 'dir' },
35
- !list.length ? (!loading && 'Nothing here')
35
+ !list.length ? (!loading && (snap.stoppedSearch ? 'Stopped before finding anything' : 'Nothing here'))
36
: list.map((entry: DirEntry) =>
37
h(File, { key: entry.n, hidden: filter && !filter.test(entry.n) || !++n, ...entry })),
38
loading && h(Spinner))