i18n.ts
This commit is contained in:
parent
7af5562b5a
commit
f0bb08de15
2 changed files with 9 additions and 9 deletions
|
@ -6,7 +6,7 @@
|
||||||
<textarea
|
<textarea
|
||||||
ref="textEl"
|
ref="textEl"
|
||||||
v-model="text"
|
v-model="text"
|
||||||
:placeholder="i18n.locale.inputMessageHere"
|
:placeholder="i18n.ts.inputMessageHere"
|
||||||
@keydown="onKeydown"
|
@keydown="onKeydown"
|
||||||
@compositionupdate="onCompositionUpdate"
|
@compositionupdate="onCompositionUpdate"
|
||||||
@paste="onPaste"
|
@paste="onPaste"
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
<div class="buttons">
|
<div class="buttons">
|
||||||
<button class="_button" @click="chooseFile"><i class="fas fa-photo-video"></i></button>
|
<button class="_button" @click="chooseFile"><i class="fas fa-photo-video"></i></button>
|
||||||
<button class="_button" @click="insertEmoji"><i class="fas fa-laugh-squint"></i></button>
|
<button class="_button" @click="insertEmoji"><i class="fas fa-laugh-squint"></i></button>
|
||||||
<button class="send _button" :disabled="!canSend || sending" :title="i18n.locale.send" @click="send">
|
<button class="send _button" :disabled="!canSend || sending" :title="i18n.ts.send" @click="send">
|
||||||
<template v-if="!sending"><i class="fas fa-paper-plane"></i></template><template v-if="sending"><i class="fas fa-spinner fa-pulse fa-fw"></i></template>
|
<template v-if="!sending"><i class="fas fa-paper-plane"></i></template><template v-if="sending"><i class="fas fa-spinner fa-pulse fa-fw"></i></template>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
@ -78,7 +78,7 @@ async function onPaste(e: ClipboardEvent) {
|
||||||
if (items[0].kind == 'file') {
|
if (items[0].kind == 'file') {
|
||||||
os.alert({
|
os.alert({
|
||||||
type: 'error',
|
type: 'error',
|
||||||
text: i18n.locale.onlyOneFileCanBeAttached
|
text: i18n.ts.onlyOneFileCanBeAttached
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -107,7 +107,7 @@ function onDrop(e: DragEvent): void {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
os.alert({
|
os.alert({
|
||||||
type: 'error',
|
type: 'error',
|
||||||
text: i18n.locale.onlyOneFileCanBeAttached
|
text: i18n.ts.onlyOneFileCanBeAttached
|
||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -133,7 +133,7 @@ function onCompositionUpdate() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function chooseFile(e: MouseEvent) {
|
function chooseFile(e: MouseEvent) {
|
||||||
selectFile(e.currentTarget ?? e.target, i18n.locale.selectFile).then(selectedFile => {
|
selectFile(e.currentTarget ?? e.target, i18n.ts.selectFile).then(selectedFile => {
|
||||||
file = selectedFile;
|
file = selectedFile;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,7 +10,7 @@
|
||||||
<template #empty>
|
<template #empty>
|
||||||
<div class="_fullinfo">
|
<div class="_fullinfo">
|
||||||
<img src="https://xn--931a.moe/assets/info.jpg" class="_ghost"/>
|
<img src="https://xn--931a.moe/assets/info.jpg" class="_ghost"/>
|
||||||
<div>{{ i18n.locale.noMessagesYet }}</div>
|
<div>{{ i18n.ts.noMessagesYet }}</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -23,7 +23,7 @@
|
||||||
</div>
|
</div>
|
||||||
<footer>
|
<footer>
|
||||||
<div v-if="typers.length > 0" class="typers">
|
<div v-if="typers.length > 0" class="typers">
|
||||||
<I18n :src="i18n.locale.typingUsers" text-tag="span" class="users">
|
<I18n :src="i18n.ts.typingUsers" text-tag="span" class="users">
|
||||||
<template #users>
|
<template #users>
|
||||||
<b v-for="user in typers" :key="user.id" class="user">{{ user.username }}</b>
|
<b v-for="user in typers" :key="user.id" class="user">{{ user.username }}</b>
|
||||||
</template>
|
</template>
|
||||||
|
@ -32,7 +32,7 @@
|
||||||
</div>
|
</div>
|
||||||
<transition :name="animation ? 'fade' : ''">
|
<transition :name="animation ? 'fade' : ''">
|
||||||
<div class="new-message" v-show="showIndicator">
|
<div class="new-message" v-show="showIndicator">
|
||||||
<button class="_buttonPrimary" @click="onIndicatorClick"><i class="fas fa-fw fa-arrow-circle-down"></i>{{ i18n.locale.newMessageExists }}</button>
|
<button class="_buttonPrimary" @click="onIndicatorClick"><i class="fas fa-fw fa-arrow-circle-down"></i>{{ i18n.ts.newMessageExists }}</button>
|
||||||
</div>
|
</div>
|
||||||
</transition>
|
</transition>
|
||||||
<XForm v-if="!fetching" ref="formEl" :user="user" :group="group" class="form"/>
|
<XForm v-if="!fetching" ref="formEl" :user="user" :group="group" class="form"/>
|
||||||
|
@ -165,7 +165,7 @@ function onDrop(e: DragEvent): void {
|
||||||
} else if (e.dataTransfer.files.length > 1) {
|
} else if (e.dataTransfer.files.length > 1) {
|
||||||
os.alert({
|
os.alert({
|
||||||
type: 'error',
|
type: 'error',
|
||||||
text: i18n.locale.onlyOneFileCanBeAttached
|
text: i18n.ts.onlyOneFileCanBeAttached
|
||||||
});
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue