feat: enhance timeline event display with localization support
Some checks failed
lotteryfront CI / build (push) Has been cancelled
Some checks failed
lotteryfront CI / build (push) Has been cancelled
- Updated the TicketOrderDetailScreen to utilize localized labels for timeline events, improving user experience across different languages. - Added new timeline event translations in English, Nepali, and Chinese to support the updated display logic.
This commit is contained in:
@@ -412,10 +412,9 @@ export function TicketOrderDetailScreen({ ticketNo }: { ticketNo: string }) {
|
||||
<div className="mt-2 space-y-2">
|
||||
{timeline.map((row) => (
|
||||
<div key={row.code} className="flex items-start justify-between gap-3 rounded-lg bg-white px-3 py-2">
|
||||
<div className="min-w-0">
|
||||
<p className="text-xs font-bold text-[#32518d]">{row.label}</p>
|
||||
<p className="mt-0.5 font-mono text-[11px] text-slate-500">{row.code}</p>
|
||||
</div>
|
||||
<p className="min-w-0 text-xs font-bold text-[#32518d]">
|
||||
{t(`orders.timelineEvent.${row.code}`, { defaultValue: row.label })}
|
||||
</p>
|
||||
<p className="shrink-0 font-mono text-[11px] text-slate-500">
|
||||
{formatPlayerInstant(row.time)}
|
||||
</p>
|
||||
|
||||
@@ -537,6 +537,13 @@
|
||||
"matchPendingDraw": "Waiting for draw results. Winning status cannot be determined yet.",
|
||||
"matchPendingSettlement": "Draw results are published. Winning status will show after settlement.",
|
||||
"timeline": "Timeline",
|
||||
"timelineEvent": {
|
||||
"placed": "Bet placed",
|
||||
"deducted": "Stake deducted",
|
||||
"draw_published": "Draw results published",
|
||||
"settlement_started": "Settlement started",
|
||||
"settled": "Settled"
|
||||
},
|
||||
"settledAt": "Settled at {{time}}",
|
||||
"viewDraw": "View this draw",
|
||||
"backToOrders": "Back to My Bets",
|
||||
|
||||
@@ -536,6 +536,13 @@
|
||||
"matchPendingDraw": "ड्र पर्खँदैछ। जित-नजित अझै निर्धारण गर्न मिल्दैन।",
|
||||
"matchPendingSettlement": "ड्र नतिजा प्रकाशित भयो। सेटल पछि जित-नजित देखाइनेछ।",
|
||||
"timeline": "समयरेखा",
|
||||
"timelineEvent": {
|
||||
"placed": "बेट राखियो",
|
||||
"deducted": "रकम कटियो",
|
||||
"draw_published": "ड्र नतिजा प्रकाशित",
|
||||
"settlement_started": "सेटल सुरु",
|
||||
"settled": "सेटल भयो"
|
||||
},
|
||||
"settledAt": "सेटल समय {{time}}",
|
||||
"viewDraw": "यो ड्र हेर्नुहोस्",
|
||||
"backToOrders": "मेरा बेटमा फर्कनुहोस्",
|
||||
|
||||
@@ -536,6 +536,13 @@
|
||||
"matchPendingDraw": "待开奖,暂不能判断是否中奖。",
|
||||
"matchPendingSettlement": "已开奖,等待系统结算后显示中奖结果。",
|
||||
"timeline": "时间线",
|
||||
"timelineEvent": {
|
||||
"placed": "已下注",
|
||||
"deducted": "已扣款",
|
||||
"draw_published": "开奖结果已发布",
|
||||
"settlement_started": "结算开始",
|
||||
"settled": "已结算"
|
||||
},
|
||||
"settledAt": "结算时间 {{time}}",
|
||||
"viewDraw": "查看本期开奖",
|
||||
"backToOrders": "返回我的注单",
|
||||
|
||||
Reference in New Issue
Block a user