<!--
Alert bars
Contient les différentes barre d'alertes qui s'affichent selon certains cas...
-->

<template>
  <main>
    <client-only><LayoutAlertBarEnv></LayoutAlertBarEnv></client-only>
    <LayoutAlertBarSwitchUser></LayoutAlertBarSwitchUser>
    <client-only><LayoutAlertBarCotisation v-if="isCmf && $can('manage', 'cotisation')"></LayoutAlertBarCotisation></client-only>
    <LayoutAlertBarSwitchYear></LayoutAlertBarSwitchYear>
    <LayoutAlertBarSuperAdmin></LayoutAlertBarSuperAdmin>
  </main>
</template>

<script lang="ts">
import { defineComponent, useContext } from '@nuxtjs/composition-api'
import {$organizationProfile} from "~/services/profile/organizationProfile";

export default defineComponent({
  setup () {
    const { store } = useContext()
    const organizationProfile = $organizationProfile(store)
    return {
      isCmf: organizationProfile.isCmf(),
    }
  }
})
</script>

<style scoped>

</style>
