fix. gameData 개별 속성 구조분해
This commit is contained in:
@@ -26,12 +26,12 @@ const {
|
||||
setPreregist,
|
||||
} = usePreregist()
|
||||
|
||||
const { gameData } = storeToRefs(gameDataStore)
|
||||
const { gameId, gameName } = storeToRefs(gameDataStore)
|
||||
const { sendLog } = useAnalytics()
|
||||
|
||||
// Constants
|
||||
const stoveCs = runtimeConfig.public.stoveCs
|
||||
const customerServiceUrl = `${stoveCs}/${gameData.value?.game_id}`
|
||||
const customerServiceUrl = `${stoveCs}/${gameId.value}`
|
||||
|
||||
/**
|
||||
* 번역 함수 (Props로 전달받은 tm 또는 key 반환)
|
||||
@@ -57,8 +57,7 @@ const errorMessages = computed<Record<number, string>>(() => ({
|
||||
const tmWithGameName = (key: string): string => {
|
||||
const text = tm(key)
|
||||
if (typeof text === 'string' && text.includes('%게임명%')) {
|
||||
const gameName = gameData.value?.game_name ?? ''
|
||||
return text.replace(/%게임명%/g, gameName)
|
||||
return text.replace(/%게임명%/g, gameName.value)
|
||||
}
|
||||
return text
|
||||
}
|
||||
@@ -375,7 +374,7 @@ defineExpose({
|
||||
<h3
|
||||
class="text-xl font-bold leading-[30px] tracking-[-0.6px] text-[#ebebeb] md:text-2xl md:leading-[34px] md:tracking-[-0.72px]"
|
||||
>
|
||||
{{ gameData?.game_name }}
|
||||
{{ gameName }}
|
||||
</h3>
|
||||
<p
|
||||
class="text-[13px] font-normal leading-[22px] tracking-[-0.325px] text-[#ebebeb] md:text-[15px] md:leading-6 md:tracking-[-0.45px]"
|
||||
|
||||
Reference in New Issue
Block a user