From 530b9afa3e2c9a5ac847bbc8064f68d94794ec90 Mon Sep 17 00:00:00 2001 From: Erialos Date: Thu, 24 Nov 2022 12:17:53 -0700 Subject: [PATCH] governance views updated for multi lang --- .gitignore | 1 + src/lang/locales/en.json | 135 ++++++++++-------- src/views/GovernanceProposalView.vue | 42 +++--- .../governance/ProposalSummaryComponent.vue | 32 ++--- 4 files changed, 116 insertions(+), 94 deletions(-) diff --git a/.gitignore b/.gitignore index 26b88946..85f34b6a 100644 --- a/.gitignore +++ b/.gitignore @@ -32,3 +32,4 @@ yarn-error.log* .yarn/ .yarnrc.yml package-lock.json +yarn.lock diff --git a/src/lang/locales/en.json b/src/lang/locales/en.json index b3e12e36..52e2a4bc 100644 --- a/src/lang/locales/en.json +++ b/src/lang/locales/en.json @@ -2,64 +2,85 @@ "message": { }, - "cosmos": "Cosmos Hub", - "kava": "Kava", - "akash-network": "Akash Decloud", - "iris-network": "IRIS Hub", - "crypto-com-chain": "Crypto.org", - "osmosis": "Osmosis", - "okexchain": "OKEX Chain", - "band-protocol": "Band Protocol", - "terra-luna": "Terra", - "persistence": "Persistence", - "regen": "Regen Network", - "secret": "Secret Network", - "desmos": "Desmos", - "juno": "Juno", - "certik": "Certik", - "sentinel": "Sentinel", - "sifchain": "Sifchain", - "starname": "Starname", - "bitsong": "BitSong", - "e-money": "E-Money", - "omniflix": "OmniFlix", - "likecoin": "LikeCoin", - "stargaze": "Stargaze", - "injective": "Injective Protocal", - "vidulum": "Vidulum", - "kichain": "KI Chain", - "genesisL1": "Genesis L1", - "microtick": "Microtick", - "odin": "ODIN", - "chihuahua": "CHIHUAHUA", - - "staking": "Staking", - "governance": "Governance", - "summary": "Summary", - "blocks": "Blocks / Transactions", - "blockchains": "Blockchains", - "uptime": "Uptime", - "statesync": "State Sync", - "trade": "Trade", - "gravity": "Gravity(WIP)", - "pools": "Pools(WIP)", + "chains": { + "cosmos": "Cosmos Hub", + "kava": "Kava", + "akash-network": "Akash Decloud", + "iris-network": "IRIS Hub", + "crypto-com-chain": "Crypto.org", + "osmosis": "Osmosis", + "okexchain": "OKEX Chain", + "band-protocol": "Band Protocol", + "terra-luna": "Terra", + "persistence": "Persistence", + "regen": "Regen Network", + "secret": "Secret Network", + "desmos": "Desmos", + "juno": "Juno", + "certik": "Certik", + "sentinel": "Sentinel", + "sifchain": "Sifchain", + "starname": "Starname", + "bitsong": "BitSong", + "e-money": "E-Money", + "omniflix": "OmniFlix", + "likecoin": "LikeCoin", + "stargaze": "Stargaze", + "injective": "Injective Protocal", + "vidulum": "Vidulum", + "kichain": "KI Chain", + "genesisL1": "Genesis L1", + "microtick": "Microtick", + "odin": "ODIN", + "chihuahua": "CHIHUAHUA", - "proposal_id": "Proposal ID", - "proposal_type": "Proposal Type", - "proposal_proposer": "Proposer", - "proposal_submit_time": "Submited Time", - "proposal_voting_start_time": "Voting Begin Time", - "proposal_voting_end_time": "Voting End Time", - "proposal_description": "Description", - "proposal_content": "Content", - "proposal_total_deposit": "Total Deposit", - "voting_time": "Voting Time", - "upgrade_time": "Estimated Upgrade Time:", + "gravity": "Gravity(WIP)", + "pools": "Pools(WIP)" + }, - "btn_vote": "Vote", - "btn_deposit": "Deposit", - "btn_detail": "Detail", - "btn_back_list": "Back To List" - + "dashboard": { + "staking": "Staking", + "governance": "Governance", + "summary": "Summary", + "blocks": "Blocks / Transactions", + "blockchains": "Blockchains", + "uptime": "Uptime", + "statesync": "State Sync", + "trade": "Trade" + }, + + "governance-proposal": { + "proposal_id": "Proposal ID", + "proposal_type": "Proposal Type", + "proposal_proposer": "Proposer", + "proposal_submit_time": "Submited Time", + "proposal_voting_start_time": "Voting Begin Time", + "proposal_voting_end_time": "Voting End Time", + "proposal_description": "Description", + "proposal_content": "Content", + "proposal_total_deposit": "Total Deposit", + "proposal_deposits": "Deposits", + "voting_time": "Voting Time", + "upgrade_time": "Estimated Upgrade Time:", + + "btn_vote": "Vote", + "btn_deposit": "Deposit", + "btn_detail": "Detail", + "btn_back_list": "Back To List", + + "proposal_status": "Status", + "proposal_status_deposit": "Deposit", + "proposal_status_voting": "Voting", + "proposal_status_passed": "Passed", + "proposal_status_rejected": "Rejected", + "proposal_status_start_date": "Start Date", + "proposal_status_end_date": "End Date", + "proposal_votes": "Votes", + "proposal_votes_yes": "voted Yes", + "proposal_votes_no": "voted No", + "proposal_votes_nwv": "voted No With Veto", + "proposal_votes_abstain": "voted Abstain", + "proposal_votes_load": "Load More Votes" + } } diff --git a/src/views/GovernanceProposalView.vue b/src/views/GovernanceProposalView.vue index ead05968..3872178c 100644 --- a/src/views/GovernanceProposalView.vue +++ b/src/views/GovernanceProposalView.vue @@ -12,7 +12,7 @@ variant="light-info" class="text-right" > - Deposit + {{$t('governance-proposal.proposal_status_deposit')}} - Voting + {{$t('governance-proposal.proposal_status_voting')}} - Passed + {{$t('governance-proposal.proposal_status_passed')}} - Rejected + {{$t('governance-proposal.proposal_status_rejected')}} {{ proposal.title }} @@ -50,24 +50,24 @@ - {{ $t('proposal_proposer') }} + {{ $t('governance-proposal.proposal_proposer') }} {{ formatAddress(proposer.proposer) }} - {{ $t('proposal_total_deposit') }} + {{ $t('governance-proposal.proposal_total_deposit') }} {{ formatToken(proposal.total_deposit) }} - {{ $t('proposal_submit_time') }} + {{ $t('governance-proposal.proposal_submit_time') }} {{ formatDate(proposal.submit_time) }} - {{ $t('voting_time') }} + {{ $t('governance-proposal.voting_time') }} {{ formatDate(proposal.voting_start_time) }} - {{ formatDate(proposal.voting_end_time) }} @@ -80,7 +80,7 @@ - {{ $t('upgrade_time') }} {{ upgradeTime }} + {{ $t('governance-proposal.upgrade_time') }} {{ upgradeTime }} @@ -91,7 +91,7 @@ - {{ $t('btn_back_list') }} + {{ $t('governance-proposal.btn_back_list') }} - {{ $t('btn_vote') }} + {{ $t('governance-proposal.btn_vote') }} - Votes + {{ $t('governance-proposal.proposal_votes') }} @@ -153,22 +153,22 @@ - {{ percent(proposal.tally.yes) }}% voted Yes + {{ percent(proposal.tally.yes) }}% {{ $t('governance-proposal.proposal_votes_yes') }} - {{ percent(proposal.tally.no) }}% voted No + {{ percent(proposal.tally.no) }}% {{ $t('governance-proposal.proposal_votes_no') }} - {{ percent(proposal.tally.veto) }}% voted No With Veto + {{ percent(proposal.tally.veto) }}% {{ $t('governance-proposal.proposal_votes_nwv') }} - {{ percent(proposal.tally.abstain) }}% voted Abstain + {{ percent(proposal.tally.abstain) }}% {{ $t('governance-proposal.proposal_votes_abstain') }}
- Load More Votes + {{ $t('governance-proposal.proposal_votes_load') }}
@@ -208,7 +208,7 @@ > - Deposits ({{ formatToken(proposal.total_deposit) }}) + {{ $t('governance-proposal.proposal_deposits') }} ({{ formatToken(proposal.total_deposit) }}) @@ -231,7 +231,7 @@ - {{ $t('btn_back_list') }} + {{ $t('governance-proposal.btn_back_list') }} - {{ $t('btn_deposit') }} + {{ $t('governance-proposal.btn_deposit') }} - {{ $t('btn_vote') }} + {{ $t('governance-proposal.btn_vote') }} diff --git a/src/views/components/governance/ProposalSummaryComponent.vue b/src/views/components/governance/ProposalSummaryComponent.vue index 1cf46b7e..37151fc7 100644 --- a/src/views/components/governance/ProposalSummaryComponent.vue +++ b/src/views/components/governance/ProposalSummaryComponent.vue @@ -20,27 +20,27 @@

- Status + {{$t('governance-proposal.proposal_status')}}

- Deposit + {{$t('governance-proposal.proposal_status_deposit')}} - Voting + {{$t('governance-proposal.proposal_status_voting')}} - Passed + {{$t('governance-proposal.proposal_status_passed')}} - Rejected + {{$t('governance-proposal.proposal_status_rejected')}} {{ p.status }}

- Start Date + {{$t('governance-proposal.proposal_status_start_date')}}

{{ formatDate(p.voting_start_time) }} @@ -48,7 +48,7 @@

- End Date + {{$t('governance-proposal.proposal_status_end_date')}}

{{ formatDate(p.voting_end_time) }} @@ -56,7 +56,7 @@

- Deposit + {{$t('governance-proposal.proposal_status_deposit')}}

{{ formatToken(p.total_deposit) || '-' }} @@ -119,22 +119,22 @@ - {{ percent(p.tally.yes) }}% voted Yes + {{ percent(p.tally.yes) }}% {{ $t('governance-proposal.proposal_votes_yes') }} - {{ percent(p.tally.no) }}% voted No + {{ percent(p.tally.no) }}% {{ $t('governance-proposal.proposal_votes_no') }} - {{ percent(p.tally.veto) }}% voted No With Veto + {{ percent(p.tally.veto) }}% {{ $t('governance-proposal.proposal_votes_nwv') }} - {{ percent(p.tally.abstain) }}% voted Abstain + {{ percent(p.tally.abstain) }}% {{ $t('governance-proposal.proposal_votes_abstain') }}
@@ -148,7 +148,7 @@ :href="`./gov/${p.id}`" variant="outline-primary" > - {{ $t('btn_detail') }} + {{ $t('governance-proposal.btn_detail') }} - {{ $t('btn_deposit') }} + {{ $t('governance-proposal.btn_deposit') }} - {{ $t('btn_vote') }} + {{ $t('governance-proposal.btn_vote') }}
@@ -242,7 +242,7 @@ export default { } -