virtual sample : create static vue component and tabs system
This commit is contained in:
parent
3d62eb029e
commit
733a79c302
2 changed files with 14 additions and 5 deletions
1
src/components/project/virtual-sample/Static.vue
Normal file
1
src/components/project/virtual-sample/Static.vue
Normal file
|
|
@ -0,0 +1 @@
|
|||
<template>vue static</template>
|
||||
|
|
@ -14,18 +14,25 @@
|
|||
<button
|
||||
class="btn btn--transparent | font-serif"
|
||||
data-icon="cursor"
|
||||
aria-pressed="true"
|
||||
:aria-pressed="activeTab === 'dynamic' ? true : false"
|
||||
@click="activeTab = 'dynamic'"
|
||||
>
|
||||
<span>Vue Dynamique</span>
|
||||
</button>
|
||||
<button class="btn btn--transparent | font-serif" data-icon="image">
|
||||
<button
|
||||
@click="activeTab = 'static'"
|
||||
class="btn btn--transparent | font-serif"
|
||||
data-icon="image"
|
||||
:aria-pressed="activeTab === 'static' ? true : false"
|
||||
>
|
||||
<span>Vue statique</span>
|
||||
</button>
|
||||
</div>
|
||||
<h2 class="font-serif text-lg">Titre du rendu</h2>
|
||||
</template>
|
||||
|
||||
<Dynamic />
|
||||
<Dynamic v-if="activeTab === 'dynamic'" />
|
||||
<Static v-if="activeTab === 'static'" />
|
||||
|
||||
<template #footer>
|
||||
<button
|
||||
|
|
@ -66,8 +73,8 @@
|
|||
import { storeToRefs } from "pinia";
|
||||
import Dialog from "primevue/dialog";
|
||||
import Dynamic from "./Dynamic.vue";
|
||||
import { computed, ref } from "vue";
|
||||
import { usePageStore } from "../../../stores/page";
|
||||
import Static from "./Static.vue";
|
||||
import { ref } from "vue";
|
||||
import { useDialogStore } from "../../../stores/dialog";
|
||||
|
||||
const { file } = defineProps({
|
||||
|
|
@ -79,6 +86,7 @@ const { comments } = storeToRefs(useDialogStore());
|
|||
// Variables
|
||||
const isOpen = ref(true);
|
||||
const isCommentsOpen = ref(false);
|
||||
const activeTab = ref("dynamic");
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue