<script setup>
// Copyright 2024 FlexCDN root@flexcdn.cn. All rights reserved. Official site: https://flexcdn.cn .

import ctxRef from "@/utils/ctx_ref.js"
import Context from "./list.js"
import ListMenu from "./@list_menu.vue"
import DefinitionTable from "@/components/common/DefinitionTable.vue";
import CardView from "@/components/common/CardView.vue";
import CardRow from "@/components/common/CardRow.vue";

const ctx = ctxRef(new Context())

</script>

<template>
	<ListMenu :ctx="ctx" active-tab="index"></ListMenu>

	<CardView>
		<CardRow>
			<template #name>名称</template>
			<template #value>
				{{ctx.list.name}}
			</template>
		</CardRow>
		<CardRow>
			<template #name>类型</template>
			<template #value>
				{{ctx.list.typeName}}
			</template>
		</CardRow>
		<CardRow>
			<template #name>全局有效</template>
			<template #value>
				<span v-if="ctx.list.isGlobal" class="green">Y</span>
				<span v-else class="disabled">N</span>
			</template>
		</CardRow>
		<CardRow>
			<template #name>备注</template>
			<template #value>
				<span v-if="ctx.list.description.length > 0">{{ctx.list.description}}</span>
				<span v-else class="disabled">-</span>
			</template>
		</CardRow>
	</CardView>
</template>

<style lang="postcss" scoped>
</style>