[zh] fixes

This commit is contained in:
Avris 2021-02-06 20:37:47 +01:00
parent dfcd0329b8
commit 232afe3b21
5 changed files with 67 additions and 65 deletions

View File

@ -7,56 +7,58 @@
<span class="higher"><T>title</T></span>
</nuxt-link>
</h1>
<div v-if="config.locale === 'zh'" class="btn-group m-2">
<button v-for="(display, code) in {traditional: '繁體', simplified: '简体'}"
:class="'btn btn-sm ' + (spelling === code ? 'btn-secondary disabled' : 'btn-outline-secondary')"
:disabled="spelling === code"
@click="setSpelling(code)"
>
{{display}}
</button>
</div>
<!--
<Dropdown v-if="Object.keys(locales).length > 1" btnClass="btn-outline-secondary btn-sm">
<template v-slot:toggle>
<Icon v="language"/>
{{locales[config.locale].name}}
</template>
<div>
<div v-if="config.locale === 'zh'" class="btn-group m-2">
<button v-for="(display, code) in {traditional: '繁體', simplified: '简体'}"
:class="'btn btn-sm ' + (spelling === code ? 'btn-secondary disabled' : 'btn-outline-secondary')"
:disabled="spelling === code"
@click="setSpelling(code)"
>
{{display}}
</button>
</div>
<Dropdown v-if="Object.keys(locales).length > 1" btnClass="btn-outline-secondary btn-sm" class="d-inline-block">
<template v-slot:toggle>
<Icon v="language"/>
{{locales[config.locale].name}}
</template>
<template v-slot:menu>
<li v-for="(options, locale) in locales" :key="locale" v-if="locale !== config.locale">
<a :href="options.url" class="dropdown-item">
{{options.name}}
</a>
</li>
<li class="dropdown-divider"></li>
<li>
<LocaleLink locale="en" link="/blog/creating-new-language-version" class="dropdown-item small">
<Icon v="plus"/>
<T>localise.shorter</T>
</LocaleLink>
</li>
</template>
</Dropdown>
-->
<div class="btn-group">
<a v-for="(options, locale) in locales" :key="locale"
:href="options.url"
:class="'btn btn-sm ' + (locale === config.locale ? 'btn-secondary disabled' : 'btn-outline-secondary')"
:disabled="locale === config.locale"
>
{{options.name}}
</a>
<LocaleLink locale="en" link="/blog/creating-new-language-version" class="btn btn-sm btn-outline-secondary">
<Icon v="plus"/>
</LocaleLink>
<template v-slot:menu>
<li v-for="(options, locale) in locales" :key="locale" v-if="locale !== config.locale">
<a :href="options.url" class="dropdown-item">
{{options.name}}
</a>
</li>
<li class="dropdown-divider"></li>
<li>
<LocaleLink locale="en" link="/blog/creating-new-language-version" class="dropdown-item small">
<Icon v="plus"/>
<T>localise.shorter</T>
</LocaleLink>
</li>
</template>
</Dropdown>
<!--
<div class="btn-group">
<a v-for="(options, locale) in locales" :key="locale"
:href="options.url"
:class="'btn btn-sm ' + (locale === config.locale ? 'btn-secondary disabled' : 'btn-outline-secondary')"
:disabled="locale === config.locale"
>
{{options.name}}
</a>
<LocaleLink locale="en" link="/blog/creating-new-language-version" class="btn btn-sm btn-outline-secondary">
<Icon v="plus"/>
</LocaleLink>
</div>
-->
</div>
</div>
<div class="d-block d-md-none">
<div class="btn-group-vertical btn-block nav-custom mb-2">
<nuxt-link v-for="link in links" :key="link.link" :to="link.link" :class="`btn btn-sm ${isActiveRoute(link) ? 'active' : ''}`">
<Icon :v="link.icon"/>
{{ link.textLong || link.text }}
<Spelling>{{ link.textLong || link.text }}</Spelling>
</nuxt-link>
</div>
</div>
@ -70,7 +72,7 @@
<div class="btn-group-vertical btn-block nav-custom nav-custom-left mb-2">
<nuxt-link v-for="link in links" :key="link.link" :to="link.link" :class="`btn btn-sm ${isActiveRoute(link) ? 'active' : ''}`">
<Icon :v="link.icon"/>
{{ link.textLong || link.text }}
<Spelling>{{ link.textLong || link.text }}</Spelling>
</nuxt-link>
</div>
</div>
@ -80,7 +82,7 @@
<nuxt-link v-for="link in links" :key="link.link" :to="link.link" :class="`btn btn-sm ${isActiveRoute(link) ? 'active' : ''}`">
<Icon :v="link.icon" size="1.6"/>
<br/>
<span class="text-nowrap">{{ link.text }}</span>
<span class="text-nowrap"><Spelling>{{ link.text }}</Spelling></span>
</nuxt-link>
</div>
</div>

View File

@ -2,23 +2,23 @@
<span>
<strong v-if="opinion === 1">
<img src="../node_modules/@fortawesome/fontawesome-pro/svgs/solid/heart.svg" :aria-label="$t('profile.opinion.yes')" class="icon"/>
<nuxt-link v-if="link" :to="link">{{ word }}</nuxt-link>
<span v-else>{{ word }}</span>
<nuxt-link v-if="link" :to="link"><Spelling>{{ word }}</Spelling></nuxt-link>
<span v-else><Spelling>{{ word }}</Spelling></span>
</strong>
<span v-else-if="opinion === 2">
<Icon v="grin-tongue" :aria-label="$t('profile.opinion.jokingly')"/>
<nuxt-link v-if="link" :to="link">{{ word }}</nuxt-link>
<span v-else>{{ word }}</span>
<nuxt-link v-if="link" :to="link"><Spelling>{{ word }}</Spelling></nuxt-link>
<span v-else><Spelling>{{ word }}</Spelling></span>
</span>
<span v-else-if="opinion === 0">
<Icon v="thumbs-up" :aria-label="$t('profile.opinion.meh')"/>
<nuxt-link v-if="link" :to="link">{{ word }}</nuxt-link>
<span v-else>{{ word }}</span>
<nuxt-link v-if="link" :to="link"><Spelling>{{ word }}</Spelling></nuxt-link>
<span v-else><Spelling>{{ word }}</Spelling></span>
</span>
<span v-else-if="opinion === -1" class="text-muted small">
<Icon v="thumbs-down" :aria-label="$t('profile.opinion.no')"/>
<nuxt-link v-if="link" :to="link">{{ word }}</nuxt-link>
<span v-else>{{ word }}</span>
<nuxt-link v-if="link" :to="link"><Spelling>{{ word }}</Spelling></nuxt-link>
<span v-else><Spelling>{{ word }}</Spelling></span>
</span>
</span>
</template>

View File

@ -40,7 +40,7 @@ sources:
mergePronouns: {}
nouns:
enabled: true
enabled: false
route: 'dictionary'
collapsable: false
plurals: true

View File

@ -364,8 +364,8 @@ profile:
description: '傳記'
names: '名字'
pronouns: '代詞'
pronounsInfo: '您可以輸入代詞(例如“他”或“他/你”)或鏈接(例如“ http://zh.pronouns.page/佢”
pronounsNotFound: '我們找不到這個代詞的鏈接"
pronounsInfo: '您可以輸入代詞(例如“他”或“他/你”)或鏈接(例如“ http://zh.pronouns.page/佢”'
pronounsNotFound: '我們找不到這個代詞的鏈接'
words: '詞匯'
birthday: '嵗'
birthdayInfo: '我們不發布您的生日,只發布計算出的年齡。'
@ -423,16 +423,16 @@ confirm:
terms:
header: '服務條款'
lastUpdate: '最近更新時間'
consent: "通過註冊,您正在接受 {/terms=服務條款}.'
consent: '通過註冊,您正在接受 {/terms=服務條款}.'
admin:
header: '管理面板'
user:
user: '帳戶'
email: '電郵地址'
roles: '角色'
profiles: '個人資料'
confirmRole: 'Are you sure you want to switch @%username%''s role to "%role%"?'
header: '管理面板'
user:
user: '帳戶'
email: '電郵地址'
roles: '角色'
profiles: '個人資料'
confirmRole: 'Are you sure you want to switch @%username%''s role to "%role%"?'
table:
empty: '空……'

View File

@ -33,7 +33,7 @@
<section v-if="profile.age ||profile.description.trim().length">
<p v-for="line in profile.description.split('\n')" class="mb-1">
{{ line }}
<Spelling>{{ line }}</Spelling>
</p>
<p v-if="profile.age">
<Icon v="birthday-cake"/>