File tree Expand file tree Collapse file tree 1 file changed +7
-10
lines changed
packages/anu-vue/src/components/table Expand file tree Collapse file tree 1 file changed +7
-10
lines changed Original file line number Diff line number Diff line change @@ -68,7 +68,7 @@ const tableProps = {
68
68
/**
69
69
* Text to render when no row is available
70
70
*/
71
- noResultsText : {
71
+ noDataText : {
72
72
type : String ,
73
73
default : 'No matching results found!!' ,
74
74
} ,
@@ -348,17 +348,16 @@ export const ATable = defineComponent({
348
348
} )
349
349
350
350
return ( ) => {
351
- // TODO: There should be no data as well and it should be rendered only when data is filtered and there's no resulting rows
352
- // 👉 No results
353
- const noResultsTr = < tr >
351
+ // 👉 No Data
352
+ const noDataTr = < tr >
354
353
< td
355
354
class = "em:px-[1.15rem] em:h-14 whitespace-nowrap text-center font-medium"
356
355
colspan = { _columns . value . length }
357
356
>
358
- { slots . noResults
359
- ? slots . noResults ( )
357
+ { slots [ 'no-data' ]
358
+ ? slots [ 'no-data' ] ( )
360
359
: < span >
361
- { props . noResultsText }
360
+ { props . noDataText }
362
361
</ span > }
363
362
</ td >
364
363
</ tr >
@@ -368,8 +367,6 @@ export const ATable = defineComponent({
368
367
text via default text just above the table
369
368
370
369
Later on, we will merge both default slots and will pass as single slot content to card
371
-
372
- TODO(refactor): Use variant group here
373
370
*/
374
371
const table = < div class = "overflow-x-auto" >
375
372
< table class = "a-table-table overflow-x-auto w-full max-w-full" >
@@ -432,7 +429,7 @@ export const ATable = defineComponent({
432
429
}
433
430
</ tr >
434
431
} )
435
- : noResultsTr
432
+ : noDataTr
436
433
}
437
434
</ tbody >
438
435
</ table >
You can’t perform that action at this time.
0 commit comments