Merge pull request #451 from sxlmnwb/master

i18n update add en in ping-pub/explorer #1
This commit is contained in:
ping 2023-06-21 09:46:07 +08:00 committed by GitHub
commit 79dbdf7b6d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
15 changed files with 295 additions and 157 deletions

View File

@ -206,7 +206,7 @@ function selected(route: any, nav: NavLink) {
</div>
<div class="px-2">
<div class="px-4 text-sm pt-2 text-gray-400 pb-2 uppercase">
Sponsors
{{ $t('module.sponsors') }}
</div>
<a
href="https://osmosis.zone"
@ -239,7 +239,7 @@ function selected(route: any, nav: NavLink) {
</div>
</a>
<div class="px-4 text-sm pt-2 text-gray-400 pb-2 uppercase">Links</div>
<div class="px-4 text-sm pt-2 text-gray-400 pb-2 uppercase">{{ $t('module.links') }}</div>
<a
href="https://twitter.com/ping_pub"
target="_blank"

View File

@ -138,7 +138,7 @@ function updateEvent() {
</div>
<!-- content -->
<div class="flex flex-1 flex-col truncate pl-4">
<h2 class="text-sm card-title">Address:</h2>
<h2 class="text-sm card-title">{{ $t('account.address') }}:</h2>
<span class="text-xs truncate"> {{ address }}</span>
</div>
</div>
@ -147,14 +147,14 @@ function updateEvent() {
<!-- Assets -->
<div class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow">
<div class="flex justify-between">
<h2 class="card-title mb-4">Assets</h2>
<h2 class="card-title mb-4">{{ $t('account.assets') }}</h2>
<!-- button -->
<div class="flex justify-end mb-4 pr-5">
<label
for="send"
class="btn btn-primary btn-sm mr-2"
@click="dialog.open('send', {}, updateEvent)"
>Send</label
>{{ $t('account.btn_send') }}</label
>
<label
for="transfer"
@ -168,7 +168,7 @@ function updateEvent() {
updateEvent
)
"
>transfer</label
>{{ $t('account.btn_transfer') }}</label
>
</div>
</div>
@ -319,7 +319,7 @@ function updateEvent() {
</div>
</div>
<div class="mt-4 text-lg font-semibold mr-5 pl-5 border-t pt-4 text-right">
Total Value: ${{ totalValue }}
{{ $t('account.total_value') }}: ${{ totalValue }}
</div>
</div>
</div>
@ -328,19 +328,19 @@ function updateEvent() {
<!-- Delegations -->
<div class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow">
<div class="flex justify-between">
<h2 class="card-title mb-4">Delegations</h2>
<h2 class="card-title mb-4">{{ $t('account.delegations') }}</h2>
<div class="flex justify-end mb-4">
<label
for="delegate"
class="btn btn-primary btn-sm mr-2"
@click="dialog.open('delegate', {}, updateEvent)"
>Delegate</label
>{{ $t('account.btn_delegate') }}</label
>
<label
for="withdraw"
class="btn btn-primary btn-sm"
@click="dialog.open('withdraw', {}, updateEvent)"
>Withdraw</label
>{{ $t('account.btn_withdraw') }}</label
>
</div>
</div>
@ -348,14 +348,14 @@ function updateEvent() {
<table class="table w-full text-sm table-zebra">
<thead>
<tr>
<th class="py-3">Validator</th>
<th class="py-3">Delegation</th>
<th class="py-3">Rewards</th>
<th class="py-3">Action</th>
<th class="py-3">{{ $t('account.validator') }}</th>
<th class="py-3">{{ $t('account.delegation') }}</th>
<th class="py-3">{{ $t('account.rewards') }}</th>
<th class="py-3">{{ $t('account.action') }}</th>
</tr>
</thead>
<tbody class="text-sm">
<tr v-if="delegations.length === 0"><td colspan="10"><div class="text-center">No Delegations</div></td></tr>
<tr v-if="delegations.length === 0"><td colspan="10"><div class="text-center">{{ $t('account.no_delegations') }}</div></td></tr>
<tr v-for="(v, index) in delegations" :key="index">
<td class="text-caption text-primary py-3">
<RouterLink
@ -392,7 +392,7 @@ function updateEvent() {
updateEvent
)
"
>delegate</label
>{{ $t('account.btn_delegate') }}</label
>
<label
for="redelegate"
@ -406,7 +406,7 @@ function updateEvent() {
updateEvent
)
"
>Redelegate</label
>{{ $t('account.btn_redelegate') }}</label
>
<label
for="unbond"
@ -420,7 +420,7 @@ function updateEvent() {
updateEvent
)
"
>Unbond</label
>{{ $t('account.btn_unbond') }}</label
>
</div>
</td>
@ -435,15 +435,15 @@ function updateEvent() {
class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow"
v-if="unbonding && unbonding.length > 0"
>
<h2 class="card-title mb-4">Unbonding Delegations</h2>
<h2 class="card-title mb-4">{{ $t('account.unbonding_delegations') }}</h2>
<div class="overflow-x-auto">
<table class="table text-sm w-full">
<thead>
<tr>
<th class="py-3">Creation Height</th>
<th class="py-3">Initial Balance</th>
<th class="py-3">Balance</th>
<th class="py-3">Completion Time</th>
<th class="py-3">{{ $t('account.creation_height') }}</th>
<th class="py-3">{{ $t('account.initial_balance') }}</th>
<th class="py-3">{{ $t('account.balance') }}</th>
<th class="py-3">{{ $t('account.completion_time') }}</th>
</tr>
</thead>
<tbody class="text-sm" v-for="(v, index) in unbonding" :key="index">
@ -494,19 +494,19 @@ function updateEvent() {
<!-- Transactions -->
<div class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow">
<h2 class="card-title mb-4">Transactions</h2>
<h2 class="card-title mb-4">{{ $t('account.transactions') }}</h2>
<div class="overflow-x-auto">
<table class="table w-full text-sm">
<thead>
<tr>
<th class="py-3">Height</th>
<th class="py-3">Hash</th>
<th class="py-3">Messages</th>
<th class="py-3">Time</th>
<th class="py-3">{{ $t('account.height') }}</th>
<th class="py-3">{{ $t('account.hash') }}</th>
<th class="py-3">{{ $t('account.messages') }}</th>
<th class="py-3">{{ $t('account.time') }}</th>
</tr>
</thead>
<tbody class="text-sm">
<tr v-if="txs.length === 0"><td colspan="10"><div class="text-center">No Transactions</div></td></tr>
<tr v-if="txs.length === 0"><td colspan="10"><div class="text-center">{{ $t('account.no_transactions') }}</div></td></tr>
<tr v-for="(v, index) in txs" :key="index">
<td class="text-sm py-3">
<RouterLink :to="`/${chain}/block/${v.height}`" class="text-primary dark:invert">{{
@ -538,9 +538,9 @@ function updateEvent() {
<!-- Account -->
<div class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow">
<h2 class="card-title mb-4">Account</h2>
<h2 class="card-title mb-4">{{ $t('account.acc') }}</h2>
<DynamicComponent :value="account" />
</div>
</div>
<div v-else class="text-no text-sm">Account does not exists on chain</div>
<div v-else class="text-no text-sm">{{ $t('account.error') }}</div>
</template>

View File

@ -57,11 +57,11 @@ function showPubkey(v: any) {
<table class="table table-compact">
<thead>
<tr>
<td>Type</td>
<td>Address</td>
<td>Account Number</td>
<td>Sequence</td>
<td>Public Key</td>
<td>{{ $t('account.type') }}</td>
<td>{{ $t('account.address') }}</td>
<td>{{ $t('account.acc_num') }}</td>
<td>{{ $t('account.sequence') }}</td>
<td>{{ $t('account.pub_key') }}</td>
</tr>
</thead>
<tr v-for="acc in accounts">

View File

@ -66,36 +66,36 @@ onBeforeRouteUpdate(async (to, from, next) => {
<div v-if="remainingBlocks > 0">
<div class="text-primary font-bold text-lg my-10">#{{ target }}</div>
<Countdown :time="estimateTime" css="md:!text-5xl font-sans md:mx-5" />
<div class="my-5">Estimated Time: <span class="text-xl font-bold">{{ format.toLocaleDate(estimateDate) }}</span>
<div class="my-5">{{ $t('block.estimated_time') }}: <span class="text-xl font-bold">{{ format.toLocaleDate(estimateDate) }}</span>
</div>
<div class="pt-10 flex justify-center">
<table class="table w-max rounded-lg bg-base-100">
<tbody>
<tr class="hover cursor-pointer" @click="edit = !edit">
<td>Countdown For Block:</td>
<td>{{ $t('block.countdown_for_block') }}:</td>
<td class="text-right"><span class="md:!ml-40">{{ target }}</span></td>
</tr>
<tr v-if="edit">
<td colspan="2" class="text-center">
<h3 class="text-lg font-bold">Input A New Target Block Number</h3>
<h3 class="text-lg font-bold">{{ $t('block.countdown_for_block_input') }}</h3>
<p class="py-4">
<div class="join">
<input class="input input-bordered join-item" v-model="newHeight" type="number" />
<button class="btn btn-primary join-item" @click="updateTarget()">Update</button>
<button class="btn btn-primary join-item" @click="updateTarget()">{{ $t('block.btn_update') }}</button>
</div>
</p>
</td>
</tr>
<tr>
<td>Current Height:</td>
<td>{{ $t('block.current_height') }}:</td>
<td class="text-right">#{{ store.latest?.block?.header.height }}</td>
</tr>
<tr>
<td>Remaining Blocks:</td>
<td>{{ $t('block.remaining_blocks') }}:</td>
<td class="text-right">{{ remainingBlocks }}</td>
</tr>
<tr>
<td>Average Block Time:</td>
<td>{{ $t('block.average_block_time') }}:</td>
<td class="text-right">{{ (store.blocktime / 1000).toFixed(1) }}s</td>
</tr>
</tbody>
@ -125,17 +125,17 @@ onBeforeRouteUpdate(async (to, from, next) => {
</div>
<div class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow">
<h2 class="card-title flex flex-row justify-between">Block Header</h2>
<h2 class="card-title flex flex-row justify-between">{{ $t('block.block_header') }}</h2>
<DynamicComponent :value="current.block?.header" />
</div>
<div class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow">
<h2 class="card-title flex flex-row justify-between">Transactions</h2>
<h2 class="card-title flex flex-row justify-between">{{ $t('account.transactions') }}</h2>
<TxsElement :value="current.block?.data?.txs" />
</div>
<div class="bg-base-100 px-4 pt-3 pb-4 rounded shadow">
<h2 class="card-title flex flex-row justify-between">Last Commit</h2>
<h2 class="card-title flex flex-row justify-between">{{ $t('block.last_commit') }}</h2>
<DynamicComponent :value="current.block?.last_commit" />
</div>
</div>

View File

@ -19,12 +19,12 @@ const list = computed(() => {
<div>
<div class="tabs tabs-boxed bg-transparent mb-4">
<a class="tab text-gray-400 uppercase" :class="{ 'tab-active': tab === 'blocks' }"
@click="tab = 'blocks'">Recent</a>
@click="tab = 'blocks'">{{ $t('block.recent') }}</a>
<RouterLink class="tab text-gray-400 uppercase"
:to="`/${chain}/block/${Number(base.latest?.block?.header.height||0) + 10000}`"
>Future</RouterLink>
>{{ $t('block.future') }}</RouterLink>
<a class="tab text-gray-400 uppercase" :class="{ 'tab-active': tab === 'transactions' }"
@click="tab = 'transactions'">Transactions</a>
@click="tab = 'transactions'">{{ $t('account.transactions') }}</a>
</div>
<div v-show="tab === 'blocks'" class="grid xl:!grid-cols-6 md:!grid-cols-4 grid-cols-1 gap-3">
@ -53,10 +53,10 @@ const list = computed(() => {
<table class="table w-full table-compact">
<thead class="bg-base-200">
<tr>
<th style="position: relative; z-index: 2;">Height</th>
<th style="position: relative; z-index: 2;">Hash</th>
<th>Messages</th>
<th>Fees</th>
<th style="position: relative; z-index: 2;">{{ $t('account.height') }}</th>
<th style="position: relative; z-index: 2;">{{ $t('account.hash') }}</th>
<th>{{ $t('account.messages') }}</th>
<th>{{ $t('block.fees') }}</th>
</tr>
</thead>
<tbody>
@ -83,7 +83,7 @@ const list = computed(() => {
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
d="M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"></path>
</svg>
<span>Only show txs in recent blocks</span>
<span>{{ $t('block.only_tx') }}</span>
</div>
</div>
</div>

View File

@ -170,7 +170,7 @@ async function update() {
{{ item?.address }}/consensus_state
</option>
</select>
<button class="btn btn-primary" @click="onChange">Monitor</button>
<button class="btn btn-primary" @click="onChange">{{ $t('consensus.monitor') }}</button>
</label>
</div>
<div v-if="httpstatus !== 200" class="text-error mt-1">
@ -185,13 +185,13 @@ async function update() {
>
<div class="text-sm mb-1 flex flex-col truncate">
<h4 class="text-lg font-semibold text-main">{{ rate }}</h4>
<span class="text-md">Onboard Rate</span>
<span class="text-md">{{ $t('consensus.onboard_rate') }}</span>
</div>
<div class="avatar placeholder">
<div
class="bg-rose-100 text-neutral-content rounded-full w-12 h-12"
>
<span class="text-2xl text-error font-semibold">O</span>
<span class="text-2xl text-error font-semibold">{{ $t('consensus.o') }}</span>
</div>
</div>
</div>
@ -201,13 +201,13 @@ async function update() {
>
<div class="text-sm mb-1 flex flex-col truncate">
<h4 class="text-lg font-semibold text-main">{{ height }}</h4>
<span class="text-md">Height</span>
<span class="text-md">{{ $t('account.height') }}</span>
</div>
<div class="avatar placeholder">
<div
class="bg-green-100 text-neutral-content rounded-full w-12 h-12"
>
<span class="text-2xl text-success font-semibold">H</span>
<span class="text-2xl text-success font-semibold">{{ $t('consensus.h') }}</span>
</div>
</div>
</div>
@ -217,13 +217,13 @@ async function update() {
>
<div class="text-sm mb-1 flex flex-col truncate">
<h4 class="text-lg font-semibold text-main">{{ round }}</h4>
<span class="text-md">Round</span>
<span class="text-md">{{ $t('consensus.round') }}</span>
</div>
<div class="avatar placeholder">
<div
class="bg-violet-100 text-neutral-content rounded-full w-12 h-12"
>
<span class="text-2xl text-primary font-semibold">R</span>
<span class="text-2xl text-primary font-semibold">{{ $t('consensus.r') }}</span>
</div>
</div>
</div>
@ -233,13 +233,13 @@ async function update() {
>
<div class="text-sm mb-1 flex flex-col truncate">
<h4 class="text-lg font-semibold text-main">{{ step }}</h4>
<span class="text-md">Step</span>
<span class="text-md">{{ $t('consensus.step') }}</span>
</div>
<div class="avatar placeholder">
<div
class="bg-blue-100 text-neutral-content rounded-full w-12 h-12"
>
<span class="text-2xl text-info font-semibold">S</span>
<span class="text-2xl text-info font-semibold">{{ $t('consensus.s') }}</span>
</div>
</div>
</div>
@ -252,10 +252,10 @@ async function update() {
>
<div class="flex flex-1 flex-col truncate">
<h2 class="text-sm card-title text-error mb-6">
Updated at {{ newTime || '' }}
{{ $t('consensus.updated_at') }} {{ newTime || '' }}
</h2>
<div v-for="item in roundState.height_vote_set" :key="item.round">
<div class="text-xs mb-1">Round: {{ item.round }}</div>
<div class="text-xs mb-1">{{ $t('consensus.round') }}: {{ item.round }}</div>
<div class="text-xs break-words">{{ item.prevotes_bit_array }}</div>
<div class="flex flex-wrap py-6">
@ -277,21 +277,21 @@ async function update() {
<div class="flex flex-col md:!flex-row">
<div class="flex mr-1 mb-1">
<div class="px-4 w-[34px] h-6 rounded-lg bg-primary"></div>
<span class="mx-1">Proposer Signed</span>
<span class="mx-1">{{ $t('consensus.proposer_sign') }}</span>
</div>
<div class="flex mr-1 mb-1">
<div class="px-4 w-[34px] h-6 rounded-lg bg-warning"></div>
<span class="mx-1">Proposer Not Signed</span>
<span class="mx-1">{{ $t('consensus.proposer_not_sign') }}</span>
</div>
<div class="flex mr-1 mb-1">
<div class="px-4 w-[34px] h-6 rounded-lg bg-success"></div>
<span class="mx-1">Signed</span>
<span class="mx-1">{{ $t('consensus.sign') }}</span>
</div>
<div class="flex mr-1 mb-1">
<div class="px-4 w-[34px] h-6 rounded-lg bg-gray-700"></div>
<span class="mx-1">Not Signed</span>
<span class="mx-1">{{ $t('consensus.not_sign') }}</span>
</div>
</div>
</div>
@ -304,17 +304,15 @@ async function update() {
class="drop-shadow-md px-4 pt-2 pb-2"
style="box-shadow: rgba(0, 207, 232, 0.4) 0px 6px 15px -7px"
>
<h2 class="text-base font-semibold">Tips</h2>
<h2 class="text-base font-semibold">{{ $t('consensus.tips') }}</h2>
</div>
<div class="px-4 py-4">
<ul style="list-style-type: disc" class="pl-8">
<li>
This tool is useful for validators to monitor who is onboard during
an upgrade
{{ $t('consensus.tips_description_1') }}
</li>
<li>
If you want to change the default rpc endpoint. make sure that
"https" and "CORS" are enabled on your server.
{{ $t('consensus.tips_description_2') }}
</li>
</ul>
</div>

View File

@ -113,14 +113,14 @@ const result = ref('');
<div>
<div class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow">
<h2 class="card-title truncate w-full">
Contract List of Code: {{ props.code_id }}
{{ $t('cosmwasm.contract_list_code') }}: {{ props.code_id }}
</h2>
<div class="overflow-x-auto">
<table class="table table-compact w-full mt-4">
<thead>
<tr>
<th style="position: relative; z-index: 2">Contract List</th>
<th>Actions</th>
<th style="position: relative; z-index: 2">{{ $t('cosmwasm.contract_list') }}</th>
<th>{{ $t('account.action') }}</th>
</tr>
</thead>
<tbody>
@ -135,34 +135,34 @@ const result = ref('');
@click="showInfo(v)"
for="modal-contract-detail"
class="btn btn-primary btn-xs text-xs mr-2"
>Contract</label
>{{ $t('cosmwasm.btn_contract') }}</label
>
<label
@click="showFunds(v)"
for="modal-contract-funds"
class="btn btn-primary btn-xs text-xs mr-2"
>Funds</label
>{{ $t('cosmwasm.btn_funds') }}</label
>
<label
class="btn btn-primary btn-xs text-xs mr-2"
for="modal-contract-states"
@click="showState(v)"
>
States
{{ $t('cosmwasm.btn_states') }}
</label>
<label
for="modal-contract-query"
class="btn btn-primary btn-xs text-xs mr-2"
@click="showQuery(v)"
>
Query
{{ $t('cosmwasm.btn_query') }}
</label>
<label
for="wasm_execute_contract"
class="btn btn-primary btn-xs text-xs"
@click="dialog.open('wasm_execute_contract', { contract: v })"
>
Execute
{{ $t('cosmwasm.btn_execute') }}
</label>
</td>
</tr>
@ -182,7 +182,7 @@ const result = ref('');
codeId: props.code_id,
})
"
>Instantiate Contract</label
>{{ $t('cosmwasm.instantiate_contract') }}</label
>
</div>
</div>
@ -193,7 +193,7 @@ const result = ref('');
<label class="modal-box !w-11/12 !max-w-5xl relative p-2" for="">
<div>
<div class="flex items-center justify-between px-3 pt-2">
<div class="text-lg">Contract Detail</div>
<div class="text-lg">{{ $t('cosmwasm.contract_detail') }}</div>
<label
@click="infoDialog = false"
for="modal-contract-detail"
@ -213,7 +213,7 @@ const result = ref('');
<label class="modal-box relative p-2" for="">
<div>
<div class="flex items-center justify-between px-3 pt-2">
<div class="text-lg">Contract Balances</div>
<div class="text-lg">{{ $t('cosmwasm.contract_balances') }}</div>
<label
for="modal-contract-funds"
class="btn btn-sm btn-circle"
@ -224,7 +224,7 @@ const result = ref('');
<li v-for="b in balances.balances" >
<a class="flex justify-between"><span>{{ format.formatToken(b) }}</span> {{ b.amount }} </a>
</li>
<li v-if="balances.pagination?.total === '0'" class="my-10 text-center"> No Escrowed Assets</li>
<li v-if="balances.pagination?.total === '0'" class="my-10 text-center">{{ $t('cosmwasm.no_escrowed_assets') }}</li>
</ul>
</div>
</label>
@ -235,7 +235,7 @@ const result = ref('');
<label class="modal-box !w-11/12 !max-w-5xl" for="">
<div>
<div class="flex items-center justify-between px-3 pt-2 mb-4">
<div class="text-lg">Contract States</div>
<div class="text-lg">{{ $t('cosmwasm.contract_states') }}</div>
<label
for="modal-contract-states"
class="btn btn-sm btn-circle"
@ -271,7 +271,7 @@ const result = ref('');
<label class="modal-box !w-11/12 !max-w-5xl" for="">
<div>
<div class="flex items-center justify-between px-3 pt-2 mb-4">
<div class="text-lg font-semibold">Query Contract</div>
<div class="text-lg font-semibold">{{ $t('cosmwasm.query_contract') }}</div>
<label
for="modal-contract-query"
class="btn btn-sm btn-circle"
@ -315,7 +315,7 @@ const result = ref('');
class="btn btn-primary px-4 text-white"
@click="queryContract()"
>
Query Contract
{{ $t('cosmwasm.query_contract') }}
</button>
</div>
</div>

View File

@ -24,15 +24,15 @@ pageload(1)
</script>
<template>
<div class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow">
<h2 class="card-title truncate w-full">Cosmos Wasm Smart Contracts</h2>
<h2 class="card-title truncate w-full">{{ $t('cosmwasm.title') }}</h2>
<div class="overflow-x-auto">
<table class="table table-compact w-full mt-4 text-sm">
<thead>
<tr>
<th>Code Id</th>
<th>Code Hash</th>
<th>Creator</th>
<th>Permissions</th>
<th>{{ $t('cosmwasm.code_id') }}</th>
<th>{{ $t('cosmwasm.code_hash') }}</th>
<th>{{ $t('cosmwasm.creator') }}</th>
<th>{{ $t('cosmwasm.permissions') }}</th>
</tr>
</thead>
<tbody>
@ -55,9 +55,7 @@ pageload(1)
</table>
<div class="flex justify-between">
<PaginationBar :limit="pageRequest.limit" :total="codes.pagination?.total" :callback="pageload" />
<label for="wasm_store_code" class="btn btn-primary my-5" @click="dialog.open('wasm_store_code', {})">Upload
Smart
Contract</label>
<label for="wasm_store_code" class="btn btn-primary my-5" @click="dialog.open('wasm_store_code', {})">{{ $t('cosmwasm.btn_up_sc') }}</label>
</div>
</div>
</div>

View File

@ -198,7 +198,7 @@ function pageload(p: number) {
<div class="gap-4 mb-4 grid lg:!!grid-cols-3 auto-rows-max">
<!-- flex-1 -->
<div class="bg-base-100 px-4 pt-3 pb-4 rounded shadow">
<h2 class="card-title mb-1">Tally</h2>
<h2 class="card-title mb-1">{{ $t('gov.tally') }}</h2>
<div class="mb-1" v-for="(item, index) of processList" :key="index">
<label class="block text-sm mb-1">{{ item.name }}</label>
<div class="h-5 w-full relative">
@ -225,32 +225,32 @@ function pageload(p: number) {
for="vote"
class="btn btn-primary float-right btn-sm mx-1"
@click="dialog.open('vote', { proposal_id })"
>Vote</label
>{{ $t('gov.btn_vote') }}</label
>
<label
for="deposit"
class="btn btn-primary float-right btn-sm mx-1"
@click="dialog.open('deposit', { proposal_id })"
>Deposit</label
>{{ $t('gov.btn_deposit') }}</label
>
</div>
</div>
<div class="bg-base-100 px-4 pt-3 pb-5 rounded shadow lg:!!col-span-2">
<h2 class="card-title">Timeline</h2>
<h2 class="card-title">{{ $t('gov.timeline') }}</h2>
<div class="px-1">
<div class="flex items-center mb-4 mt-2">
<div class="w-2 h-2 rounded-full bg-error mr-3"></div>
<div class="text-base flex-1 text-main">
Submited at: {{ format.toDay(proposal.submit_time) }}
{{ $t('gov.submit_at') }}: {{ format.toDay(proposal.submit_time) }}
</div>
<div class="text-sm">{{ shortTime(proposal.submit_time) }}</div>
</div>
<div class="flex items-center mb-4">
<div class="w-2 h-2 rounded-full bg-primary mr-3"></div>
<div class="text-base flex-1 text-main">
Deposited at:
{{ $t('gov.deposited_at') }}:
{{
format.toDay(
proposal.status === 'PROPOSAL_STATUS_DEPOSIT_PERIOD'
@ -273,7 +273,7 @@ function pageload(p: number) {
<div class="flex items-center">
<div class="w-2 h-2 rounded-full bg-yes mr-3"></div>
<div class="text-base flex-1 text-main">
Voting start from {{ format.toDay(proposal.voting_start_time) }}
{{ $t('gov.vote_start_from') }} {{ format.toDay(proposal.voting_start_time) }}
</div>
<div class="text-sm">
{{ shortTime(proposal.voting_start_time) }}
@ -287,14 +287,14 @@ function pageload(p: number) {
<div class="flex items-center mb-1">
<div class="w-2 h-2 rounded-full bg-success mr-3"></div>
<div class="text-base flex-1 text-main">
Voting end {{ format.toDay(proposal.voting_end_time) }}
{{ $t('gov.vote_end') }} {{ format.toDay(proposal.voting_end_time) }}
</div>
<div class="text-sm">
{{ shortTime(proposal.voting_end_time) }}
</div>
</div>
<div class="pl-5 text-sm">
Current Status: {{ proposal.status }}
{{ $t('gov.current_status') }}: {{ proposal.status }}
</div>
</div>
@ -307,7 +307,7 @@ function pageload(p: number) {
<div class="flex items-center">
<div class="w-2 h-2 rounded-full bg-warning mr-3"></div>
<div class="text-base flex-1 text-main">
Upgrade Plan:
{{ $t('gov.upgrade_plan') }}:
<span v-if="Number(proposal.content?.plan?.height || '0') > 0">
(EST)</span
>
@ -328,7 +328,7 @@ function pageload(p: number) {
</div>
<div class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow">
<h2 class="card-title">Votes</h2>
<h2 class="card-title">{{ $t('gov.votes') }}</h2>
<div class="overflow-x-auto">
<table class="table w-full table-zebra">
<tbody>

View File

@ -33,10 +33,10 @@ function page(p: number) {
<template>
<div>
<div class="tabs tabs-boxed bg-transparent mb-4 text-center">
<a class="tab text-gray-400 uppercase" :class="{ 'tab-active': tab === '2' }" @click="changeTab('2')">Voting</a>
<a class="tab text-gray-400 uppercase" :class="{ 'tab-active': tab === '3' }" @click="changeTab('3')">Passed</a>
<a class="tab text-gray-400 uppercase" :class="{ 'tab-active': tab === '2' }" @click="changeTab('2')">{{ $t('gov.voting') }}</a>
<a class="tab text-gray-400 uppercase" :class="{ 'tab-active': tab === '3' }" @click="changeTab('3')">{{ $t('gov.passed') }}</a>
<a class="tab text-gray-400 uppercase" :class="{ 'tab-active': tab === '4' }"
@click="changeTab('4')">Rejected</a>
@click="changeTab('4')">{{ $t('gov.rejected') }}</a>
</div>
<ProposalListItem :proposals="store?.proposals[tab]" />
<PaginationBar :total="store?.proposals[tab]?.pagination?.total" :limit="pageRequest.limit" :callback="page" />

View File

@ -39,10 +39,10 @@ function pageload(p: number) {
<div>
<div class="bg-base-100 px-4 pt-3 pb-4 rounded shadow">
<div class="flex flex-wrap gap-4 items-center">
<h2 class="card-title py-4">IBC Connections</h2>
<h2 class="card-title py-4">{{ $t('ibc.title') }}</h2>
<div class="tabs tabs-boxed">
<a class="tab" :class="{ 'tab-active': tab === 'registry' }" @click="tab = 'registry'">Registry</a>
<a class="tab" :class="{ 'tab-active': tab === 'favorite' }" @click="tab = 'favorite'">Favorite</a>
<a class="tab" :class="{ 'tab-active': tab === 'registry' }" @click="tab = 'registry'">{{ $t('ibc.registry') }}</a>
<a class="tab" :class="{ 'tab-active': tab === 'favorite' }" @click="tab = 'favorite'">{{ $t('module.favorite') }}</a>
</div>
</div>
<div>
@ -52,10 +52,10 @@ function pageload(p: number) {
</div>
<div v-show="tab === 'favorite'" class="flex flex-wrap gap-1 p-4 ">
<div class="join border border-primary">
<button class="join-item px-2">Connection Id:</button>
<button class="join-item px-2">{{ $t('ibc.connection_id') }}:</button>
<input v-model="ibcStore.connectionId" type=number class="input input-bordered w-40 join-item" min="0"
:max="pageResponse.total || 0" :placeholder="`0~${pageResponse.total}`" />
<button class="join-item btn btn-primary" @click="ibcStore.showConnection()">apply</button>
<button class="join-item btn btn-primary" @click="ibcStore.showConnection()">{{ $t('ibc.btn_apply') }}</button>
</div>
</div>
</div>

View File

@ -94,18 +94,18 @@ function color(v: string) {
</div>
<div class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow">
<h2 class="card-title mb-4 overflow-hidden">IBC Client <span class="ml-2 text-sm">{{
<h2 class="card-title mb-4 overflow-hidden">{{ $t('ibc.title_2') }}<span class="ml-2 text-sm">{{
clientState.client_state?.['@type'] }}</span></h2>
<div class="overflow-x-auto grid grid-cols-1 md:grid-cols-2 gap-4">
<table class="table table-sm capitalize">
<thead class="bg-base-200">
<tr>
<td colspan="3">Trust Parameters</td>
<td colspan="3">{{ $t('ibc.trust_parameters') }}</td>
</tr>
</thead>
<tbody>
<tr>
<td class="w-52">trust level:</td>
<td class="w-52">{{ $t('ibc.trust_level') }}:</td>
<td>
{{ clientState.client_state?.trust_level?.numerator }}/{{
clientState.client_state?.trust_level?.denominator
@ -113,23 +113,23 @@ function color(v: string) {
</td>
</tr>
<tr>
<td class="w-52">trusting period:</td>
<td class="w-52">{{ $t('ibc.trusting_period') }}:</td>
<td>{{ formatSeconds(clientState.client_state?.trusting_period) }}</td>
</tr>
<tr>
<td class="w-52">unbonding period:</td>
<td class="w-52">{{ $t('ibc.unbonding_period') }}:</td>
<td>{{ formatSeconds(clientState.client_state?.unbonding_period) }}</td>
</tr>
<tr>
<td class="w-52">max clock drift:</td>
<td class="w-52">{{ $t('ibc.max_clock_drift') }}:</td>
<td>{{ formatSeconds(clientState.client_state?.max_clock_drift) }}</td>
</tr>
<tr>
<td class="w-52">frozen height:</td>
<td class="w-52">{{ $t('ibc.frozen_height') }}:</td>
<td>{{ clientState.client_state?.frozen_height }}</td>
</tr>
<tr>
<td class="w-52">latest height:</td>
<td class="w-52">{{ $t('ibc.latest_height') }}:</td>
<td>{{ clientState.client_state?.latest_height }}</td>
</tr>
</tbody>
@ -137,24 +137,24 @@ function color(v: string) {
<table class="table table-sm text-sm w-full capitalize">
<thead class="bg-base-200">
<tr>
<td colspan="2">Upgrade Parameters</td>
<td colspan="2">{{ $t('ibc.upgrade_parameters') }}</td>
</tr>
</thead>
<tbody>
<tr>
<td colspan="2">
<div class="flex justify-between"><span>allow update after expiry:</span> <span>{{
<div class="flex justify-between"><span>{{ $t('ibc.allow_update_after_expiry') }}:</span> <span>{{
clientState.client_state?.allow_update_after_expiry }}</span></div>
</td>
</tr>
<tr>
<td colspan="2">
<div class="flex justify-between"><span>allow update after misbehaviour: </span> <span>{{
<div class="flex justify-between"><span>{{ $t('ibc.allow_update_after_misbehaviour') }}: </span> <span>{{
clientState.client_state?.allow_update_after_misbehaviour }}</span></div>
</td>
</tr>
<tr>
<td class="w-52">upgrade path:</td>
<td class="w-52">{{ $t('ibc.upgrade_path') }}:</td>
<td class="text-right">{{ clientState.client_state?.upgrade_path.join(', ') }}</td>
</tr>
</tbody>
@ -163,27 +163,27 @@ function color(v: string) {
</div>
</div>
<div class="bg-base-100 px-4 pt-3 pb-4 rounded mb-4 shadow overflow-hidden">
<h2 class="card-title">Channels</h2>
<h2 class="card-title">{{ $t('ibc.channels') }}</h2>
<div class="overflow-auto">
<table class="table w-full mt-4">
<thead>
<tr>
<th>Txs</th>
<th style="position: relative; z-index: 2">Channel Id</th>
<th>Port Id</th>
<th>State</th>
<th>Counterparty</th>
<th>Hops</th>
<th>Version</th>
<th>Ordering</th>
<th>{{ $t('ibc.txs') }}</th>
<th style="position: relative; z-index: 2">{{ $t('ibc.channel_id') }}</th>
<th>{{ $t('ibc.port_id') }}</th>
<th>{{ $t('ibc.state') }}</th>
<th>{{ $t('ibc.counterparty') }}</th>
<th>{{ $t('ibc.hops') }}</th>
<th>{{ $t('ibc.version') }}</th>
<th>{{ $t('ibc.ordering') }}</th>
</tr>
</thead>
<tbody>
<tr v-for="v in ibcStore.registryChannels">
<td>
<div class="flex gap-1">
<label class="btn btn-xs" @click="fetchSendingTxs(v[ibcStore.sourceField].channel_id, v[ibcStore.sourceField].port_id)">Out</label>
<label class="btn btn-xs" @click="fetchRecevingTxs(v[ibcStore.sourceField].channel_id, v[ibcStore.sourceField].port_id)">In</label>
<label class="btn btn-xs" @click="fetchSendingTxs(v[ibcStore.sourceField].channel_id, v[ibcStore.sourceField].port_id)">{{ $t('ibc.btn_out') }}</label>
<label class="btn btn-xs" @click="fetchRecevingTxs(v[ibcStore.sourceField].channel_id, v[ibcStore.sourceField].port_id)">{{ $t('ibc.btn_in') }}</label>
</div>
</td>
<td>
@ -196,8 +196,8 @@ function color(v: string) {
<tr v-for="v in channels">
<td>
<div class="flex gap-1">
<label class="btn btn-xs" @click="fetchSendingTxs(v.channel_id, v.port_id)">Out</label>
<label class="btn btn-xs" @click="fetchRecevingTxs(v.channel_id, v.port_id)">In</label>
<label class="btn btn-xs" @click="fetchSendingTxs(v.channel_id, v.port_id)">{{ $t('ibc.btn_out') }}</label>
<label class="btn btn-xs" @click="fetchRecevingTxs(v.channel_id, v.port_id)">{{ $t('ibc.btn_in') }}</label>
</div>
</td>
<td>

View File

@ -5,17 +5,17 @@ import misc404 from '@/assets/images/pages/404.png';
<template>
<div class="pt-10">
<div class="text-center">
<div class="text-8xl font-semibold text-main">404</div>
<div class="text-xl font-bold my-2">Page Not Found</div>
<div class="text-8xl font-semibold text-main">{{ $t('pages.title_all') }}</div>
<div class="text-xl font-bold my-2">{{ $t('pages.tag_all') }}</div>
<div class="text-base">
We couldn't find the page you are looking for.
{{ $t('pages.description_all') }}
</div>
</div>
<!-- 👉 Image -->
<div class="misc-avatar w-full text-center">
<RouterLink to="/" class="btn no-underline btn-primary mt-4">
Back to Home
{{ $t('pages.btn_index') }}
</RouterLink>
<img :src="misc404" alt="Coming Soon" class="mx-auto h-[400px] mt-10" />
</div>

View File

@ -48,17 +48,17 @@ const chainStore = useBlockchain()
</svg>
</div>
<h1 class="text-primary dark:invert text-3xl md:!text-6xl font-bold">
Ping Dashboard
{{ $t('pages.title') }}
</h1>
<div class="badge badge-primary badge-outline dark:invert mt-1 text-sm md:!mt-8">
Beta
{{ $t('pages.tag') }}
</div>
</div>
<div class="text-center text-base">
<p class="mb-1">
{{ $t('index.slogan') }}
{{ $t('pages.slogan') }}
</p>
<h2 class="mb-6">Cosmos Ecosystem Blockchains 🚀</h2>
<h2 class="mb-6">{{ $t('pages.description') }}</h2>
</div>
<div
v-if="dashboard.status !== LoadingStatus.Loaded"
@ -69,7 +69,7 @@ const chainStore = useBlockchain()
<div class="flex items-center rounded-lg bg-base-100 border border-gray-200 dark:border-gray-700 mt-10">
<Icon icon="mdi:magnify" class="text-2xl text-gray-400 ml-3"/>
<input :placeholder="$t('index.search_placeholder')" class="px-4 h-10 bg-transparent flex-1 outline-none text-base" v-model="keywords" />
<input :placeholder="$t('pages.search_placeholder')" class="px-4 h-10 bg-transparent flex-1 outline-none text-base" v-model="keywords" />
<div class="px-4 text-base hidden md:!block">{{ chains.length }}/{{ dashboard.length }}</div>
</div>

View File

@ -12,15 +12,157 @@
"ibc": "IBC",
"consensus": "Consensus",
"supply": "Supply",
"account": "Accounts"
"account": "Accounts",
"ecosystem": "Ecosystem",
"favorite": "Favorite",
"add_to_favorite": "Add to favorite",
"all_blockchains": "All Blockchain",
"sponsors": "Sponsors",
"links": "Links"
},
"index": {
"pages": {
"title": "Ping Dashboard",
"title_all": "404",
"tag": "Beta",
"tag_all": "Page Not Found",
"slogan": "Ping Dashboard is not just an explorer but also a wallet and more ... 🛠",
"description": "Cosmos Ecosystem Blockchains 🚀",
"search_placeholder": "Search Chain",
"add_to_favorite": "Add to favorite"
"description_all": "We couldn't find the page you are looking for.",
"btn_index": "Back to Home"
},
"Ecosystem": "Ecosystem",
"All Blockchains": "All Blockchain",
"Favorite": "Favorite"
"account": {
"type": "Type",
"address": "Address",
"acc": "Account",
"acc_num": "Account Number",
"sequence": "Sequence",
"pub_key": "Public Key",
"assets": "Assets",
"btn_send": "Send",
"btn_transfer": "Transfer",
"total_value": "Total Value",
"delegations": "Delegations",
"no_delegations": "No Delegations",
"btn_delegate": "Delegate",
"btn_redelegate": "Redelegate",
"btn_withdraw": "Withdraw",
"btn_unbond": "Unbond",
"validator": "Validator",
"delegation": "Delegation",
"rewards": "Rewards",
"action": "Action",
"unbonding_delegations": "Unbonding Delegations",
"creation_height": "Creation Height",
"initial_balance": "Initial Balance",
"balance": "Balance",
"completion_time": "Completion Time",
"transactions": "Transactions",
"no_transactions": "No Transactions",
"height": "Height",
"hash": "Hash",
"messages": "Messages",
"time": "Time",
"error": "Account does not exists on chain"
},
"block": {
"estimated_time": "Estimated Time",
"countdown_for_block": "Countdown For Block",
"countdown_for_block_input": "Input A New Target Block Number",
"btn_update": "Update",
"current_height": "Current Height",
"remaining_blocks": "Remaining Blocks",
"average_block_time": "Average Block Time",
"block_header": "Block Header",
"last_commit": "Last Commit",
"recent": "Recent",
"future": "Future",
"fees": "Fees",
"only_tx": "Only show txs in recent blocks"
},
"consensus": {
"monitor": "Monitor",
"onboard_rate": "Onboard Rate",
"o": "O",
"h": "H",
"r": "R",
"s": "S",
"round": "Round",
"step": "Step",
"updated_at": "Updated at",
"proposer_sign": "Proposer Signed",
"proposer_not_sign": "Proposer Not Signed",
"sign": "Signed",
"not_sign": "Not Signed",
"tips": "Tips",
"tips_description_1": "This tool is useful for validators to monitor who is onboard during an upgrade",
"tips_description_2": "If you want to change the default rpc endpoint. make sure that `https` and `CORS` are enabled on your server."
},
"cosmwasm": {
"title": "Cosmos Wasm Smart Contracts",
"code_id": "Code Id",
"code_hash": "Code Hash",
"creator": "Creator",
"permissions": "Permissions",
"btn_up_sc": "Upload Smart Contract",
"contract_list_code": "Contract List of Code",
"contract_list": "Contract List",
"btn_contract": "Contract",
"btn_funds": "Funds",
"btn_states": "States",
"btn_fees": "Fees",
"btn_query": "Query",
"btn_execute": "Execute",
"instantiate_contract": "Instantiate Contract",
"contract_detail": "Contract Detail",
"contract_balances": "Contract Balances",
"no_escrowed_assets": "No Escrowed Assets",
"contract_states": "Contract States",
"query_contract": "Query Contract"
},
"gov": {
"voting": "Voting",
"passed": "Passed",
"rejected": "Rejected",
"tally": "Tally",
"btn_vote": "Vote",
"btn_deposit": "Deposit",
"timeline": "Timeline",
"submit_at": "Submited at",
"deposited_at": "Deposited at",
"vote_start_from": "Voting start from",
"vote_end": "Voting end",
"current_status": "Current Status",
"upgrade_plan": "Upgrade Plan",
"votes": "Votes"
},
"ibc": {
"title": "IBC Connections",
"title_2": "IBC Client",
"registry": "Registry",
"connection_id": "Connection Id",
"btn_apply": "Apply",
"trust_parameters": "Trust Parameters",
"trust_level": "Trust level",
"trusting_period": "Trusting period",
"unbonding_period": "Unbonding period",
"max_clock_drift": "Max clock drift",
"frozen_height": "Frozen height",
"latest_height": "Latest height",
"upgrade_parameters": "Upgrade Parameters",
"allow_update_after_expiry": "Allow update after expiry",
"allow_update_after_misbehaviour": "Allow update after misbehaviour",
"upgrade_path": "Upgrade path",
"channels": "Channels",
"txs": "Txs",
"channel_id": "Channel Id",
"port_id": "Port Id",
"state": "State",
"counterparty": "Counterparty",
"hops": "Hops",
"version": "Version",
"ordering": "Ordering",
"btn_out": "Out",
"btn_in": "In"
}
}