Files
cloudron-box/dashboard/src/components/Section.vue
T

63 lines
927 B
Vue
Raw Normal View History

<script>
export default {
name: 'Section',
props: {
title: String,
}
};
</script>
2025-01-17 12:24:48 +01:00
<template>
2025-02-10 16:11:36 +01:00
<div class="section">
2025-01-17 14:02:05 +01:00
<h2 class="section-header">
2025-01-17 12:24:48 +01:00
{{ title }}
2025-01-28 13:55:05 +01:00
<div><slot name="header-buttons"></slot></div>
2025-01-17 14:02:05 +01:00
</h2>
2025-01-17 12:24:48 +01:00
<hr class="section-divider"/>
<div class="section-body">
2025-01-17 14:02:05 +01:00
<slot></slot>
2025-01-17 12:24:48 +01:00
</div>
</div>
</template>
<style scoped>
2025-02-10 16:11:36 +01:00
.section {
margin-bottom: 50px;
}
2025-01-17 12:24:48 +01:00
.section-header {
2025-01-17 15:12:26 +01:00
display: flex;
flex-wrap: wrap;
justify-content: space-between;
align-items: center;
gap: 5px;
2025-01-17 14:02:05 +01:00
padding-left: 15px;
padding-right: 15px;
2025-02-10 16:11:36 +01:00
margin-top: 10px;
2025-01-17 12:24:48 +01:00
}
.section-divider {
border-color: #d8dee4;
border-width: 1px;
margin-top: 10px;
margin-bottom: 10px;
}
2025-01-17 14:02:05 +01:00
@media (prefers-color-scheme: dark) {
.section-divider {
border-color: #495057;
}
}
2025-01-17 12:24:48 +01:00
.section-body {
position: relative;
margin-bottom: 15px;
padding: 10px 15px;
border-radius: 10px;
}
</style>