Skip to content

Commit

Permalink
fix: datatable error rendering (#494)
Browse files Browse the repository at this point in the history
  • Loading branch information
NateWaldschmidt authored May 6, 2024
1 parent 320c159 commit c70c417
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 7 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# CHANGELOG

## v2.0.54

- Fixes the `DataTable` error rendering

## v2.0.53

- Fixes the `IconButton` test ID
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@lob/ui-components",
"version": "2.0.53",
"version": "2.0.54",
"engines": {
"node": ">=20.2.0",
"npm": ">=10.2.0"
Expand Down
9 changes: 5 additions & 4 deletions src/components/DataTable/DataTable.vue
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,11 @@
: undefined
"
>
<!-- For some reason, if this is not explicit it fails. -->
<template v-if="loading !== true" #empty>
<Alert v-if="error" variant="error">{{ error }}</Alert>
<Alert v-else variant="info">No results</Alert>
<template #empty>
<template v-if="!loading">
<Alert v-if="error" variant="error">{{ error }}</Alert>
<Alert v-else variant="info">No results</Alert>
</template>
</template>

<template #loading>
Expand Down

0 comments on commit c70c417

Please sign in to comment.