33 lines
959 B
Vue
33 lines
959 B
Vue
<template>
|
|
<TableComponent :loading="configMaps == null" v-for="configMaps in [repo.get().value]">
|
|
<div class="resource-container config-map-container">
|
|
<div class="header">
|
|
<p>Name</p>
|
|
<p>Namespace</p>
|
|
<p>Entries</p>
|
|
<p>Aktionen</p>
|
|
</div>
|
|
<ConfigMapComponent v-for="configMap, index in configMaps" :config-map="configMap" class="resource" :class="{ even: index % 2 }"></ConfigMapComponent>
|
|
</div>
|
|
</TableComponent>
|
|
</template>
|
|
|
|
<script setup lang="ts">
|
|
import type { ConfigMap } from '~/classes/ConfigMap';
|
|
import { ResourceRepo } from '~/classes/repo/ResourceRepo';
|
|
|
|
const repo = ResourceRepo.init<ConfigMap>();
|
|
onMounted(() => {
|
|
repo.listen("config-maps");
|
|
});
|
|
onUnmounted(() => {
|
|
repo.clear();
|
|
});
|
|
</script>
|
|
|
|
<style scoped>
|
|
.config-map-container {
|
|
display: grid;
|
|
grid-template-columns: 1fr 1fr 1fr auto;
|
|
}
|
|
</style> |