Skip to content

Commit

Permalink
refactor(JImg): provide default fallbacks
Browse files Browse the repository at this point in the history
Signed-off-by: Fernando Fernández <[email protected]>
  • Loading branch information
ferferga committed Sep 4, 2024
1 parent 29eb742 commit 5f9e355
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 10 deletions.
8 changes: 0 additions & 8 deletions frontend/src/components/Item/Identify/IdentifyResults.vue
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,6 @@
<JImg
:src="item.ImageUrl"
once>
<template #loading>
<VProgressCircular indeterminate />
</template>
<template #error>
<VIcon>
<IMdiImageBrokenVariant />
</VIcon>
</template>
<VIcon>
<IMdiImage />
</VIcon>
Expand Down
10 changes: 8 additions & 2 deletions frontend/src/components/lib/JImg.vue
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,16 @@
name="placeholder" />
<slot
v-else-if="loading"
name="loading" />
name="loading">
<VProgressCircular indeterminate />
</slot>
<slot
v-else-if="error"
name="error" />
name="error">
<VIcon>
<IMdiImageBrokenVariant />
</VIcon>
</slot>
</template>
</JTransition>
</template>
Expand Down

0 comments on commit 5f9e355

Please sign in to comment.