✨ feat (patient): set dynamic title for patient pages
This commit is contained in:
@@ -5,6 +5,12 @@ const useIdFunction = () => useId()
|
||||
|
||||
const textDirection = useTextDirection({ initialValue: 'ltr' })
|
||||
const dir = computed(() => (textDirection.value === 'rtl' ? 'rtl' : 'ltr'))
|
||||
|
||||
useHead({
|
||||
// as a string,
|
||||
// where `%s` is replaced with the title
|
||||
titleTemplate: '%s - RSSA',
|
||||
})
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
||||
@@ -18,10 +18,10 @@ const { setOpenMobile } = useSidebar()
|
||||
<template>
|
||||
<SidebarMenu>
|
||||
<SidebarMenuItem>
|
||||
<SidebarMenuButton as-child :tooltip="item.title" :size="size">
|
||||
<SidebarMenuButton as-child :tooltip="item.title" :size="size" class="">
|
||||
<NuxtLink
|
||||
:to="item.link"
|
||||
class="group flex items-center gap-3 rounded-lg px-3 py-3 text-sm font-medium transition-all duration-200"
|
||||
class="group flex items-center gap-3 rounded-lg px-3 py-4 text-sm font-medium transition-all duration-200"
|
||||
active-class="bg-primary text-white"
|
||||
@click="setOpenMobile(false)"
|
||||
>
|
||||
|
||||
@@ -5,10 +5,14 @@ import { PAGE_PERMISSIONS } from '~/lib/page-permission'
|
||||
definePageMeta({
|
||||
middleware: ['rbac'],
|
||||
roles: ['doctor', 'nurse', 'admisi', 'pharmacy', 'billing', 'management'],
|
||||
pageTitle: 'Patient',
|
||||
title: 'Tambah Pasien',
|
||||
contentFrame: 'cf-full-width',
|
||||
})
|
||||
|
||||
useHead({
|
||||
title: () => useRoute().meta.title,
|
||||
})
|
||||
|
||||
const roleAccess: PagePermission = PAGE_PERMISSIONS['/patient']
|
||||
|
||||
const { checkRole, hasCreateAccess } = useRBAC()
|
||||
|
||||
@@ -5,10 +5,14 @@ import { PAGE_PERMISSIONS } from '~/lib/page-permission'
|
||||
definePageMeta({
|
||||
middleware: ['rbac'],
|
||||
roles: ['doctor', 'nurse', 'admisi', 'pharmacy', 'billing', 'management'],
|
||||
pageTitle: 'Patient',
|
||||
title: 'Daftar Pasien',
|
||||
contentFrame: 'cf-full-width',
|
||||
})
|
||||
|
||||
useHead({
|
||||
title: () => useRoute().meta.title,
|
||||
})
|
||||
|
||||
const roleAccess: PagePermission = PAGE_PERMISSIONS['/patient']
|
||||
|
||||
const { checkRole, hasReadAccess } = useRBAC()
|
||||
|
||||
Reference in New Issue
Block a user