build: switch from yarn to npm to manage js dependencies and move js contents to root
yarn v1 is being deprecated and starts to have some issues Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
40
src/components/Group/GroupSection.vue
Normal file
40
src/components/Group/GroupSection.vue
Normal file
@@ -0,0 +1,40 @@
|
||||
<template>
|
||||
<section
|
||||
class="flex flex-col mb-3 border-2"
|
||||
:class="{
|
||||
'border-mbz-purple': privateSection,
|
||||
'border-yellow-1': !privateSection,
|
||||
}"
|
||||
>
|
||||
<div class="flex items-stretch py-3 px-1 bg-yellow-1 text-violet-title">
|
||||
<div class="flex flex-1 gap-1">
|
||||
<o-icon :icon="icon" custom-size="36" />
|
||||
<h2 class="text-2xl font-medium mt-0">{{ title }}</h2>
|
||||
</div>
|
||||
<router-link class="self-center" :to="route">{{
|
||||
t("View all")
|
||||
}}</router-link>
|
||||
</div>
|
||||
<div class="flex-1">
|
||||
<slot></slot>
|
||||
</div>
|
||||
<div class="flex justify-end p-2">
|
||||
<slot name="create"></slot>
|
||||
</div>
|
||||
</section>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { useI18n } from "vue-i18n";
|
||||
|
||||
withDefaults(
|
||||
defineProps<{
|
||||
title: string;
|
||||
icon: string;
|
||||
privateSection?: boolean;
|
||||
route: { name: string; params: { preferredUsername: string } };
|
||||
}>(),
|
||||
{ privateSection: true }
|
||||
);
|
||||
const { t } = useI18n({ useScope: "global" });
|
||||
</script>
|
||||
Reference in New Issue
Block a user