Files
stpweb/vue/src/components/util/Modal.vue
T
adamf 3da49f4b24
Test and deploy / test (push) Successful in 1m39s
Test and deploy / deploy (push) Successful in 26s
Refactor frontend overlays
2026-10-15 12:40:56 +01:00

31 lines
683 B
Vue

<script setup>
import OverlayShell from "./OverlayShell.vue";
// Popup modal: a dimmed backdrop over the page with the content floated on top.
const open = defineModel({ type: Boolean, default: false });
const props = defineProps({
maxWidth: { type: String, default: "420px" },
});
</script>
<template>
<OverlayShell v-model="open" title="Dialog" backdrop close-on-backdrop>
<div class="modal bdr-1" :style="{ maxWidth: props.maxWidth }">
<slot />
</div>
</OverlayShell>
</template>
<style scoped>
.modal {
box-sizing: border-box;
background-color: var(--color-surface);
padding: 16px;
width: 100%;
max-height: 90vh;
overflow-y: auto;
}
</style>