Skip to content

Commit 92da490

Browse files
authored
feat(ui): insert message "no tests found" in ui (#7366)
1 parent 191ef9e commit 92da490

File tree

2 files changed

+14
-11
lines changed

2 files changed

+14
-11
lines changed

packages/ui/client/components/ProgressBar.vue

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,10 @@ import { explorerTree } from '~/composables/explorer'
44
55
const { width } = useWindowSize()
66
const classes = computed(() => {
7-
// if there are no files, then in progress and gray
8-
if (explorerTree.summary.files === 0) {
9-
return '!bg-gray-4 !dark:bg-gray-7 in-progress'
10-
}
11-
else if (!finished.value) {
12-
return 'in-progress'
13-
}
14-
15-
return null
7+
return [
8+
explorerTree.summary.files === 0 && '!bg-gray-4 !dark:bg-gray-7',
9+
!finished.value && 'in-progress',
10+
].filter(Boolean).join(' ')
1611
})
1712
1813
const widthPass = computed(() => {
Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,18 @@
1+
<script setup lang="ts">
2+
import { finished } from '~/composables/client/state'
3+
import { explorerTree } from '~/composables/explorer'
4+
</script>
5+
16
<template>
27
<div gap-0 flex="~ col gap-4" h-full justify-center items-center>
3-
<!-- <div bg-header rounded-lg p="y4 x2"> -->
8+
<template v-if="explorerTree.summary.files === 0 && finished">
9+
<div class="text-gray-5">
10+
No tests found
11+
</div>
12+
</template>
413
<section aria-labelledby="tests" m="y-4 x-2">
514
<TestsEntry />
615
</section>
716
<TestFilesEntry />
8-
<!-- </div> -->
917
</div>
1018
</template>

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy