| 1 | <template> |
| 2 | <div class="flex flex-col gap-2"> |
| 3 | <template v-if="assets.length"> |
| 4 | <AlertAssetItem v-for="asset of assets" :key="asset.id" :asset embedded /> |
| 5 | </template> |
| 6 | <template v-else> |
| 7 | <n-empty description="No assets found" class="h-48 justify-center" /> |
| 8 | </template> |
| 9 | </div> |
| 10 | </template> |
| 11 | |
| 12 | <script setup lang="ts"> |
| 13 | import type { AlertAsset } from "@/types/incidentManagement/alerts.d" |
| 14 | import { NEmpty } from "naive-ui" |
| 15 | import { toRefs } from "vue" |
| 16 | import AlertAssetItem from "./AlertAsset.vue" |
| 17 | |
| 18 | const props = defineProps<{ assets: AlertAsset[] }>() |
| 19 | const { assets } = toRefs(props) |
| 20 | </script> |