<!-- components/CustomNavBar.vue -->
<template>
  <view class="custom-navbar">
    <text>{{ localizedTitle }}</text>
  </view>
</template>

<script>
import { computed } from 'vue'
import { useI18n } from 'vue-i18n'

export default {
  props: ['pageKey'],
  setup(props) {
    const { t } = useI18n()
    const localizedTitle = computed(() => t(`pages.${props.pageKey}`))
    
    return { localizedTitle }
  }
}
</script>