feat(i18n): 添加交易相关的本地化支持,包括订单确认、撤单和交易方式等翻译

This commit is contained in:
2026-01-14 03:45:38 +07:00
parent 09cdfa0be8
commit 33391afc0a
7 changed files with 101 additions and 43 deletions

View File

@@ -4,15 +4,16 @@ import type { PropType } from "vue";
type Active = "buy" | "sell";
const active = defineModel<Active>("active", { type: String as PropType<Active>, default: "buy" });
const { t } = useI18n();
</script>
<template>
<div class="container">
<div class="btn" :class="[active === 'buy' && 'buy']" @click="active = 'buy'">
买入
{{ t('trade.buy') }}
</div>
<div class="btn" :class="[active === 'sell' && 'sell']" @click="active = 'sell'">
卖出
{{ t('trade.sell') }}
</div>
</div>
</template>