Add Modal and Table components: implement modal functionality and table structure with props
This commit is contained in:
1 parent
cb0c87a4ca
commit
111a3cc677
2 files changed
+82
No files matched your search
@@ -0,0 +1,40 @@
|
||||
<script setup lang="ts">
|
||||
const open = defineModel("open")
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<Transition>
|
||||
<div class="modal-container" v-show="open" @click="open = false">
|
||||
<Card @click.stop>
|
||||
<slot />
|
||||
</Card>
|
||||
</div>
|
||||
</Transition>
|
||||
</template>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.modal-container {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 10;
|
||||
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
|
||||
backdrop-filter: blur(10px);
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.v-enter-active,
|
||||
.v-leave-active {
|
||||
transition: opacity 0.2s ease;
|
||||
}
|
||||
|
||||
.v-enter-from,
|
||||
.v-leave-to {
|
||||
opacity: 0;
|
||||
}
|
||||
</style>
|
||||
Reference in new issue
Block a user