fix i18n
This commit is contained in:
commit
23d02372b9
7 changed files with 19 additions and 15 deletions
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "calckey",
|
"name": "calckey",
|
||||||
"version": "12.119.0-calc.12.6",
|
"version": "12.119.0-calc.12.7",
|
||||||
"codename": "aqua",
|
"codename": "aqua",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
|
|
@ -74,7 +74,7 @@ export default defineComponent({
|
||||||
},
|
},
|
||||||
async rename(file) {
|
async rename(file) {
|
||||||
const { canceled, result } = await os.inputText({
|
const { canceled, result } = await os.inputText({
|
||||||
title: this.i18n.ts.enterFileName,
|
title: i18n.ts.enterFileName,
|
||||||
default: file.name,
|
default: file.name,
|
||||||
allowEmpty: false,
|
allowEmpty: false,
|
||||||
});
|
});
|
||||||
|
@ -90,9 +90,9 @@ export default defineComponent({
|
||||||
|
|
||||||
async describe(file) {
|
async describe(file) {
|
||||||
os.popup(defineAsyncComponent(() => import('@/components/MkMediaCaption.vue')), {
|
os.popup(defineAsyncComponent(() => import('@/components/MkMediaCaption.vue')), {
|
||||||
title: this.i18n.ts.describeFile,
|
title: i18n.ts.describeFile,
|
||||||
input: {
|
input: {
|
||||||
placeholder: this.i18n.ts.inputNewDescription,
|
placeholder: i18n.ts.inputNewDescription,
|
||||||
default: file.comment !== null ? file.comment : '',
|
default: file.comment !== null ? file.comment : '',
|
||||||
},
|
},
|
||||||
image: file,
|
image: file,
|
||||||
|
@ -113,19 +113,19 @@ export default defineComponent({
|
||||||
showFileMenu(file, ev: MouseEvent) {
|
showFileMenu(file, ev: MouseEvent) {
|
||||||
if (this.menu) return;
|
if (this.menu) return;
|
||||||
this.menu = os.popupMenu([{
|
this.menu = os.popupMenu([{
|
||||||
text: this.i18n.ts.renameFile,
|
text: i18n.ts.renameFile,
|
||||||
icon: 'ph-cursor-text-bold ph-lg',
|
icon: 'ph-cursor-text-bold ph-lg',
|
||||||
action: () => { this.rename(file); },
|
action: () => { this.rename(file); },
|
||||||
}, {
|
}, {
|
||||||
text: file.isSensitive ? this.i18n.ts.unmarkAsSensitive : this.i18n.ts.markAsSensitive,
|
text: file.isSensitive ? i18n.ts.unmarkAsSensitive : i18n.ts.markAsSensitive,
|
||||||
icon: file.isSensitive ? 'ph-eye-slash-bold ph-lg' : 'ph-eye-bold ph-lg',
|
icon: file.isSensitive ? 'ph-eye-slash-bold ph-lg' : 'ph-eye-bold ph-lg',
|
||||||
action: () => { this.toggleSensitive(file); },
|
action: () => { this.toggleSensitive(file); },
|
||||||
}, {
|
}, {
|
||||||
text: this.i18n.ts.describeFile,
|
text: i18n.ts.describeFile,
|
||||||
icon: 'ph-cursor-text-bold ph-lg',
|
icon: 'ph-cursor-text-bold ph-lg',
|
||||||
action: () => { this.describe(file); },
|
action: () => { this.describe(file); },
|
||||||
}, {
|
}, {
|
||||||
text: this.i18n.ts.attachCancel,
|
text: i18n.ts.attachCancel,
|
||||||
icon: 'ph-circle-wavy-warning-bold ph-lg',
|
icon: 'ph-circle-wavy-warning-bold ph-lg',
|
||||||
action: () => { this.detachMedia(file.id); },
|
action: () => { this.detachMedia(file.id); },
|
||||||
}], ev.currentTarget ?? ev.target).then(() => this.menu = null);
|
}], ev.currentTarget ?? ev.target).then(() => this.menu = null);
|
||||||
|
|
|
@ -216,7 +216,7 @@ export default defineComponent({
|
||||||
methods: {
|
methods: {
|
||||||
async changeType() {
|
async changeType() {
|
||||||
const { canceled, result: type } = await os.select({
|
const { canceled, result: type } = await os.select({
|
||||||
title: this.i18n.ts._pages.selectType,
|
title: i18n.ts._pages.selectType,
|
||||||
groupedItems: this.getScriptBlockList(this.getExpectedType ? this.getExpectedType() : null)
|
groupedItems: this.getScriptBlockList(this.getExpectedType ? this.getExpectedType() : null)
|
||||||
});
|
});
|
||||||
if (canceled) return;
|
if (canceled) return;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<template>
|
<template>
|
||||||
<MkContainer :max-height="300" :foldable="true">
|
<MkContainer id="photos-container" :max-height="300" :foldable="true">
|
||||||
<template #header><i class="ph-image-bold ph-lg" style="margin-right: 0.5em;"></i>{{ i18n.ts.images }}</template>
|
<template #header><i class="ph-image-bold ph-lg" style="margin-right: 0.5em;"></i>{{ i18n.ts.images }}</template>
|
||||||
<div class="ujigsodd">
|
<div class="ujigsodd">
|
||||||
<MkLoading v-if="fetching"/>
|
<MkLoading v-if="fetching"/>
|
||||||
|
@ -73,6 +73,10 @@ onMounted(() => {
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
#photos-container {
|
||||||
|
--stickyTop: 0;
|
||||||
|
}
|
||||||
|
|
||||||
.ujigsodd {
|
.ujigsodd {
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
|
|
||||||
|
|
|
@ -110,13 +110,13 @@ export default defineComponent({
|
||||||
os.pageWindow('/about');
|
os.pageWindow('/about');
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
text: this.i18n.ts.aboutMisskey,
|
text: i18n.ts.aboutMisskey,
|
||||||
icon: 'ph-info-bold ph-lg',
|
icon: 'ph-info-bold ph-lg',
|
||||||
action: () => {
|
action: () => {
|
||||||
os.pageWindow('/about-calckey');
|
os.pageWindow('/about-calckey');
|
||||||
}
|
}
|
||||||
}, null, {
|
}, null, {
|
||||||
text: this.i18n.ts.help,
|
text: i18n.ts.help,
|
||||||
icon: 'ph-question-bold ph-lg',
|
icon: 'ph-question-bold ph-lg',
|
||||||
action: () => {
|
action: () => {
|
||||||
window.open(`https://misskey-hub.net/help.md`, '_blank');
|
window.open(`https://misskey-hub.net/help.md`, '_blank');
|
||||||
|
|
|
@ -130,13 +130,13 @@ export default defineComponent({
|
||||||
os.pageWindow('/about');
|
os.pageWindow('/about');
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
text: this.i18n.ts.aboutMisskey,
|
text: i18n.ts.aboutMisskey,
|
||||||
icon: 'ph-info-bold ph-lg',
|
icon: 'ph-info-bold ph-lg',
|
||||||
action: () => {
|
action: () => {
|
||||||
os.pageWindow('/about-calckey');
|
os.pageWindow('/about-calckey');
|
||||||
}
|
}
|
||||||
}, null, {
|
}, null, {
|
||||||
text: this.i18n.ts.help,
|
text: i18n.ts.help,
|
||||||
icon: 'ph-question-bold ph-lg',
|
icon: 'ph-question-bold ph-lg',
|
||||||
action: () => {
|
action: () => {
|
||||||
window.open(`https://misskey-hub.net/help.md`, '_blank');
|
window.open(`https://misskey-hub.net/help.md`, '_blank');
|
||||||
|
|
|
@ -23,7 +23,7 @@ class SwLang {
|
||||||
public i18n: Promise<I18n<any>> | null = null;
|
public i18n: Promise<I18n<any>> | null = null;
|
||||||
|
|
||||||
public fetchLocale() {
|
public fetchLocale() {
|
||||||
return this.i18n = this._fetch();
|
return i18n = this._fetch();
|
||||||
}
|
}
|
||||||
|
|
||||||
private async _fetch() {
|
private async _fetch() {
|
||||||
|
|
Loading…
Reference in a new issue