|
16 | 16 | @refresh="emittedRefresh = $event"
|
17 | 17 | @has-content="hasContent = $event"
|
18 | 18 | >
|
19 |
| - <!-- Prevent hydration issues, data is fetched no matter what --> |
20 |
| - <BrowserOnly> |
21 |
| - <Table |
22 |
| - :nodes="mapNodes(content)" |
23 |
| - :refresh="refreshData" |
24 |
| - :class="tableClass" |
25 |
| - v-bind="{ |
26 |
| - ...tableProps, |
27 |
| - theme, |
28 |
| - modalProps: { |
29 |
| - invertTheme: true, |
30 |
| - class: modalClass ?? tableClass, |
31 |
| - ...tableProps?.modalProps, |
32 |
| - }, |
33 |
| - }" |
34 |
| - > |
35 |
| - <template v-if="$slots.headActions" #headActions> |
36 |
| - <div class="flx --flxRow --flx-start-center --gap-10 --gap:md"> |
37 |
| - <slot |
38 |
| - name="headActions" |
39 |
| - v-bind="{ hasContent, refreshData }" |
40 |
| - ></slot> |
41 |
| - </div> |
42 |
| - </template> |
43 |
| - <template v-if="$slots.tableChildren" #default="tableChildrenScope"> |
44 |
| - <slot |
45 |
| - name="tableChildren" |
46 |
| - v-bind="{ ...tableChildrenScope, hasContent, refreshData }" |
47 |
| - ></slot> |
48 |
| - </template> |
49 |
| - </Table> |
50 |
| - </BrowserOnly> |
| 19 | + <Table |
| 20 | + :key="JSON.stringify({ url, defaults, length: content?.length })" |
| 21 | + :nodes="mapNodes(content)" |
| 22 | + :refresh="refreshData" |
| 23 | + :class="tableClass" |
| 24 | + v-bind="{ |
| 25 | + ...tableProps, |
| 26 | + theme, |
| 27 | + modalProps: { |
| 28 | + invertTheme: true, |
| 29 | + class: modalClass ?? tableClass, |
| 30 | + ...tableProps?.modalProps, |
| 31 | + }, |
| 32 | + }" |
| 33 | + > |
| 34 | + <template v-if="$slots.headActions" #headActions> |
| 35 | + <div class="flx --flxRow --flx-start-center --gap-10 --gap:md"> |
| 36 | + <slot name="headActions" v-bind="{ hasContent, refreshData }"></slot> |
| 37 | + </div> |
| 38 | + </template> |
| 39 | + <template v-if="$slots.tableChildren" #default="tableChildrenScope"> |
| 40 | + <slot |
| 41 | + name="tableChildren" |
| 42 | + v-bind="{ ...tableChildrenScope, hasContent, refreshData }" |
| 43 | + ></slot> |
| 44 | + </template> |
| 45 | + </Table> |
51 | 46 | </PaginationContent>
|
52 | 47 | </div>
|
53 | 48 | </BaseErrorBoundary>
|
|
60 | 55 | import type { iTableProps } from "@open-xamu-co/ui-components-vue";
|
61 | 56 |
|
62 | 57 | import BaseErrorBoundary from "../base/ErrorBoundary.vue";
|
63 |
| - import BrowserOnly from "../base/BrowserOnly.vue"; |
64 | 58 | import Table from "../table/Simple.vue";
|
65 | 59 | import PaginationContent from "./Content.vue";
|
66 | 60 |
|
|
0 commit comments