feat(client): 翻訳をIndexedDBに保存・プッシュ通知を翻訳 (#6396)
* wip * tabun ok * better msg * oops * fix lint * Update gulpfile.ts Co-authored-by: Acid Chicken (硫酸鶏) <root@acid-chicken.com> * Update src/client/scripts/set-i18n-contexts.ts Co-authored-by: Acid Chicken (硫酸鶏) <root@acid-chicken.com> * refactor Co-authored-by: acid-chicken <root@acid-chicken.com> * ✨ * wip * fix lint * たぶんおk * fix flush * Translate Notification * remove console.log * fix * add notifications * remove san * wip * ok * ✌️ * Update src/prelude/array.ts Co-authored-by: Acid Chicken (硫酸鶏) <root@acid-chicken.com> * wip * i18n refactor * Update init.ts * ✌️ Co-authored-by: Acid Chicken (硫酸鶏) <root@acid-chicken.com> Co-authored-by: syuilo <syuilotan@yahoo.co.jp>
This commit is contained in:
parent
11141c878c
commit
3963ed8ff7
143 changed files with 290 additions and 433 deletions
|
@ -63,12 +63,9 @@
|
|||
import Vue from 'vue';
|
||||
import { faInfoCircle } from '@fortawesome/free-solid-svg-icons';
|
||||
import { version } from '../config';
|
||||
import i18n from '../i18n';
|
||||
import MkLink from '../components/link.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkLink
|
||||
},
|
||||
|
|
|
@ -25,12 +25,9 @@
|
|||
import Vue from 'vue';
|
||||
import { faInfoCircle } from '@fortawesome/free-solid-svg-icons';
|
||||
import { version } from '../config';
|
||||
import i18n from '../i18n';
|
||||
import MkInstanceStats from '../components/instance-stats.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('instance') as string
|
||||
|
|
|
@ -21,13 +21,10 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faCheck, faBroadcastTower } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../i18n';
|
||||
import MkPagination from '../components/ui/pagination.vue';
|
||||
import MkButton from '../components/ui/button.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('announcements') as string
|
||||
|
|
|
@ -23,11 +23,9 @@
|
|||
|
||||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import i18n from '../i18n';
|
||||
import MkButton from '../components/ui/button.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
components: {
|
||||
MkButton
|
||||
},
|
||||
|
|
|
@ -30,12 +30,10 @@
|
|||
|
||||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import i18n from '../i18n';
|
||||
import XForm from './auth.form.vue';
|
||||
import MkSignin from '../components/signin.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
components: {
|
||||
XForm,
|
||||
MkSignin,
|
||||
|
|
|
@ -19,7 +19,6 @@ import Vue from 'vue';
|
|||
import { faFileAlt } from '@fortawesome/free-solid-svg-icons'
|
||||
import MarkdownIt from 'markdown-it';
|
||||
import MarkdownItAnchor from 'markdown-it-anchor';
|
||||
import i18n from '../i18n';
|
||||
import { url, lang } from '../config';
|
||||
import MkLink from '../components/link.vue';
|
||||
|
||||
|
@ -32,8 +31,6 @@ markdown.use(MarkdownItAnchor, {
|
|||
});
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.title,
|
||||
|
|
|
@ -57,13 +57,10 @@
|
|||
import Vue from 'vue';
|
||||
import { faChartLine, faPlus, faHashtag, faRocket } from '@fortawesome/free-solid-svg-icons';
|
||||
import { faBookmark, faCommentAlt } from '@fortawesome/free-regular-svg-icons';
|
||||
import i18n from '../i18n';
|
||||
import XUserList from '../components/user-list.vue';
|
||||
import MkContainer from '../components/ui/container.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('explore') as string
|
||||
|
|
|
@ -5,11 +5,8 @@
|
|||
|
||||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import i18n from '../i18n';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
created() {
|
||||
const acct = new URL(location.href).searchParams.get('acct');
|
||||
if (acct == null) return;
|
||||
|
|
|
@ -20,12 +20,9 @@ import XSigninDialog from '../components/signin-dialog.vue';
|
|||
import XSignupDialog from '../components/signup-dialog.vue';
|
||||
import MkButton from '../components/ui/button.vue';
|
||||
import XNotes from '../components/notes.vue';
|
||||
import i18n from '../i18n';
|
||||
import { host } from '../config';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkButton,
|
||||
XNotes,
|
||||
|
|
|
@ -25,10 +25,8 @@ import { faLock } from '@fortawesome/free-solid-svg-icons';
|
|||
import MkButton from '../components/ui/button.vue';
|
||||
import MkInput from '../components/ui/input.vue';
|
||||
import { host } from '../config';
|
||||
import i18n from '../i18n';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkButton,
|
||||
|
|
|
@ -28,14 +28,11 @@
|
|||
import Vue from 'vue';
|
||||
import { faBroadcastTower, faPlus } from '@fortawesome/free-solid-svg-icons';
|
||||
import { faSave, faTrashAlt } from '@fortawesome/free-regular-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkInput from '../../components/ui/input.vue';
|
||||
import MkTextarea from '../../components/ui/textarea.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('announcements') as string
|
||||
|
|
|
@ -120,7 +120,6 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import Chart from 'chart.js';
|
||||
import i18n from '../../i18n';
|
||||
import { faTimes, faCrosshairs, faCloudDownloadAlt, faCloudUploadAlt, faUsers, faPencilAlt, faFileImage, faDatabase, faTrafficLight, faLongArrowAltUp, faLongArrowAltDown, faMinusCircle, faTrashAlt } from '@fortawesome/free-solid-svg-icons';
|
||||
import XWindow from '../../components/window.vue';
|
||||
import MkUsersDialog from '../../components/users-dialog.vue';
|
||||
|
@ -141,8 +140,6 @@ const alpha = hex => {
|
|||
};
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XWindow,
|
||||
MkSelect,
|
||||
|
|
|
@ -62,7 +62,6 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faGlobe, faCircle, faExchangeAlt, faCaretDown, faCaretUp, faTrafficLight } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkInput from '../../components/ui/input.vue';
|
||||
import MkSelect from '../../components/ui/select.vue';
|
||||
|
@ -70,8 +69,6 @@ import MkPagination from '../../components/ui/pagination.vue';
|
|||
import MkInstanceInfo from './federation.instance.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('federation') as string
|
||||
|
|
|
@ -107,7 +107,6 @@ import MkButton from '../../components/ui/button.vue';
|
|||
import MkSelect from '../../components/ui/select.vue';
|
||||
import MkInput from '../../components/ui/input.vue';
|
||||
import { version, url } from '../../config';
|
||||
import i18n from '../../i18n';
|
||||
|
||||
const alpha = (hex, a) => {
|
||||
const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex)!;
|
||||
|
@ -118,8 +117,6 @@ const alpha = (hex, a) => {
|
|||
};
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('instance') as string
|
||||
|
|
|
@ -25,7 +25,6 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import Chart from 'chart.js';
|
||||
import i18n from '../../i18n';
|
||||
|
||||
const alpha = (hex, a) => {
|
||||
const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex)!;
|
||||
|
@ -36,8 +35,6 @@ const alpha = (hex, a) => {
|
|||
};
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
props: {
|
||||
domain: {
|
||||
required: true
|
||||
|
|
|
@ -21,13 +21,10 @@
|
|||
import Vue from 'vue';
|
||||
import { faExchangeAlt } from '@fortawesome/free-solid-svg-icons';
|
||||
import { faTrashAlt } from '@fortawesome/free-regular-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import XQueue from './queue.queue.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: `${this.$t('jobQueue')} | ${this.$t('instance')}`
|
||||
|
|
|
@ -28,13 +28,10 @@
|
|||
import Vue from 'vue';
|
||||
import { faPlus, faProjectDiagram } from '@fortawesome/free-solid-svg-icons';
|
||||
import { faSave, faTrashAlt } from '@fortawesome/free-regular-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkInput from '../../components/ui/input.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('relays') as string
|
||||
|
|
|
@ -210,12 +210,9 @@ import MkSwitch from '../../components/ui/switch.vue';
|
|||
import MkInfo from '../../components/ui/info.vue';
|
||||
import MkUserSelect from '../../components/user-select.vue';
|
||||
import { url } from '../../config';
|
||||
import i18n from '../../i18n';
|
||||
import getAcct from '../../../misc/acct/render';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('instance') as string
|
||||
|
|
|
@ -39,12 +39,9 @@ import { faTimes, faBookmark, faKey, faSync, faMicrophoneSlash, faExternalLinkSq
|
|||
import { faSnowflake, faTrashAlt, faBookmark as farBookmark } from '@fortawesome/free-regular-svg-icons';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkSwitch from '../../components/ui/switch.vue';
|
||||
import i18n from '../../i18n';
|
||||
import Progress from '../../scripts/loading';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkButton,
|
||||
MkSwitch,
|
||||
|
|
|
@ -42,14 +42,11 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faUser, faUsers, faComments, faPlus } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import getAcct from '../../../misc/acct/render';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkUserSelect from '../../components/user-select.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkButton
|
||||
},
|
||||
|
|
|
@ -27,12 +27,10 @@ import Vue from 'vue';
|
|||
import { faPaperPlane, faPhotoVideo, faLaughSquint } from '@fortawesome/free-solid-svg-icons';
|
||||
import insertTextAtCursor from 'insert-text-at-cursor';
|
||||
import * as autosize from 'autosize';
|
||||
import i18n from '../../i18n';
|
||||
import { formatTimeString } from '../../../misc/format-time-string';
|
||||
import { selectFile } from '../../scripts/select-file';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
components: {
|
||||
XUploader: () => import('../../components/uploader.vue').then(m => m.default),
|
||||
},
|
||||
|
|
|
@ -38,13 +38,11 @@
|
|||
|
||||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import i18n from '../../i18n';
|
||||
import { parse } from '../../../mfm/parse';
|
||||
import { unique } from '../../../prelude/array';
|
||||
import MkUrlPreview from '../../components/url-preview.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
components: {
|
||||
MkUrlPreview
|
||||
},
|
||||
|
|
|
@ -37,7 +37,6 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faArrowCircleDown, faFlag, faUsers, faInfoCircle } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import XList from '../../components/date-separated-list.vue';
|
||||
import XMessage from './messaging-room.message.vue';
|
||||
import XForm from './messaging-room.form.vue';
|
||||
|
@ -45,8 +44,6 @@ import { url } from '../../config';
|
|||
import parseAcct from '../../../misc/acct/parse';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XMessage,
|
||||
XForm,
|
||||
|
|
|
@ -40,12 +40,10 @@
|
|||
|
||||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import i18n from '../i18n';
|
||||
import MkSignin from '../components/signin.vue';
|
||||
import MkButton from '../components/ui/button.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
components: {
|
||||
MkSignin,
|
||||
MkButton,
|
||||
|
|
|
@ -48,7 +48,6 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faSave, faTrash } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkInput from '../../components/ui/input.vue';
|
||||
import MkTextarea from '../../components/ui/textarea.vue';
|
||||
|
@ -58,8 +57,6 @@ import MkUserSelect from '../../components/user-select.vue';
|
|||
import getAcct from '../../../misc/acct/render';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkButton, MkInput, MkTextarea, MkSelect, MkSwitch
|
||||
},
|
||||
|
|
|
@ -41,14 +41,11 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faTimes, faUsers } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import Progress from '../../scripts/loading';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkUserSelect from '../../components/user-select.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.group ? `${this.group.name} | ${this.$t('manageGroups')}` : this.$t('manageGroups')
|
||||
|
|
|
@ -40,14 +40,11 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faTimes, faListUl } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import Progress from '../../scripts/loading';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkUserSelect from '../../components/user-select.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.list ? `${this.list.name} | ${this.$t('manageLists')}` : this.$t('manageLists')
|
||||
|
|
|
@ -65,7 +65,6 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faLock } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import { hostname } from '../../config';
|
||||
import { byteify, hexify, stringify } from '../../scripts/2fa';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
|
@ -74,7 +73,6 @@ import MkInput from '../../components/ui/input.vue';
|
|||
import MkSwitch from '../../components/ui/switch.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
components: {
|
||||
MkButton, MkInfo, MkInput, MkSwitch
|
||||
},
|
||||
|
|
|
@ -13,12 +13,10 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faKey, faSyncAlt } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkInput from '../../components/ui/input.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
components: {
|
||||
MkButton, MkInput
|
||||
},
|
||||
|
|
|
@ -13,12 +13,9 @@ import Vue from 'vue';
|
|||
import { faCloud, faFolderOpen } from '@fortawesome/free-solid-svg-icons';
|
||||
import { faClock, faEyeSlash, faTrashAlt } from '@fortawesome/free-regular-svg-icons';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import i18n from '../../i18n';
|
||||
import { selectDriveFolder } from '../../scripts/select-drive-folder';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkButton,
|
||||
},
|
||||
|
|
|
@ -21,12 +21,9 @@ import Vue from 'vue';
|
|||
import { faDownload, faUpload, faBoxes } from '@fortawesome/free-solid-svg-icons';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkSelect from '../../components/ui/select.vue';
|
||||
import i18n from '../../i18n';
|
||||
import { apiUrl } from '../../config';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkButton,
|
||||
MkSelect,
|
||||
|
|
|
@ -29,13 +29,10 @@
|
|||
import Vue from 'vue';
|
||||
import { faShareAlt } from '@fortawesome/free-solid-svg-icons';
|
||||
import { faTwitter, faDiscord, faGithub } from '@fortawesome/free-brands-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
import { apiUrl } from '../../config';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkButton
|
||||
},
|
||||
|
|
|
@ -34,11 +34,8 @@
|
|||
import Vue from 'vue';
|
||||
import { faBan } from '@fortawesome/free-solid-svg-icons';
|
||||
import MkPagination from '../../components/ui/pagination.vue';
|
||||
import i18n from '../../i18n';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkPagination,
|
||||
},
|
||||
|
|
|
@ -24,11 +24,8 @@ import Vue from 'vue';
|
|||
import { faLock } from '@fortawesome/free-solid-svg-icons';
|
||||
import MkSelect from '../../components/ui/select.vue';
|
||||
import MkSwitch from '../../components/ui/switch.vue';
|
||||
import i18n from '../../i18n';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkSelect,
|
||||
MkSwitch,
|
||||
|
|
|
@ -62,13 +62,10 @@ import MkButton from '../../components/ui/button.vue';
|
|||
import MkInput from '../../components/ui/input.vue';
|
||||
import MkTextarea from '../../components/ui/textarea.vue';
|
||||
import MkSwitch from '../../components/ui/switch.vue';
|
||||
import i18n from '../../i18n';
|
||||
import { host } from '../../config';
|
||||
import { selectFile } from '../../scripts/select-file';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkButton,
|
||||
MkInput,
|
||||
|
|
|
@ -21,13 +21,10 @@ import { faUndo } from '@fortawesome/free-solid-svg-icons';
|
|||
import MkInput from '../../components/ui/input.vue';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkReactionPicker from '../../components/reaction-picker.vue';
|
||||
import i18n from '../../i18n';
|
||||
import { emojiRegexWithCustom } from '../../../misc/emoji-regex';
|
||||
import { defaultSettings } from '../../store';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkInput,
|
||||
MkButton,
|
||||
|
|
|
@ -11,11 +11,8 @@
|
|||
import Vue from 'vue';
|
||||
import { faLock } from '@fortawesome/free-solid-svg-icons';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import i18n from '../../i18n';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkButton,
|
||||
},
|
||||
|
|
|
@ -15,11 +15,8 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faExclamationTriangle } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../i18n';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('notFound') as string
|
||||
|
|
|
@ -29,14 +29,12 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faChevronUp, faChevronDown } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../i18n';
|
||||
import Progress from '../scripts/loading';
|
||||
import XNote from '../components/note.vue';
|
||||
import XNotes from '../components/notes.vue';
|
||||
import MkRemoteCaution from '../components/remote-caution.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('note') as string
|
||||
|
|
|
@ -40,15 +40,12 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faBolt } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
import MkSelect from '../../../components/ui/select.vue';
|
||||
import MkInput from '../../../components/ui/input.vue';
|
||||
import MkSwitch from '../../../components/ui/switch.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer, MkSelect, MkInput, MkSwitch
|
||||
},
|
||||
|
|
|
@ -13,13 +13,10 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faPaintBrush, faMagic } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
import MkInput from '../../../components/ui/input.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer, MkInput
|
||||
},
|
||||
|
|
|
@ -13,13 +13,10 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faBolt, faMagic } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
import MkInput from '../../../components/ui/input.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer, MkInput
|
||||
},
|
||||
|
|
|
@ -28,13 +28,10 @@
|
|||
import Vue from 'vue';
|
||||
import { v4 as uuid } from 'uuid';
|
||||
import { faPlus, faQuestion } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
import MkSelect from '../../../components/ui/select.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer, MkSelect
|
||||
},
|
||||
|
|
|
@ -17,14 +17,11 @@
|
|||
import Vue from 'vue';
|
||||
import { faPencilAlt } from '@fortawesome/free-solid-svg-icons';
|
||||
import { faImage, faFolderOpen } from '@fortawesome/free-regular-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
import MkFileThumbnail from '../../../components/drive-file-thumbnail.vue';
|
||||
import { selectDriveFile } from '../../../scripts/select-drive-file';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer, MkFileThumbnail
|
||||
},
|
||||
|
|
|
@ -13,13 +13,10 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faBolt, faMagic } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
import MkInput from '../../../components/ui/input.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer, MkInput
|
||||
},
|
||||
|
|
|
@ -13,15 +13,12 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faPaperPlane } from '@fortawesome/free-regular-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
import MkTextarea from '../../../components/ui/textarea.vue';
|
||||
import MkInput from '../../../components/ui/input.vue';
|
||||
import MkSwitch from '../../../components/ui/switch.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer, MkTextarea, MkInput, MkSwitch
|
||||
},
|
||||
|
|
|
@ -14,13 +14,11 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faBolt, faMagic } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
import MkTextarea from '../../../components/ui/textarea.vue';
|
||||
import MkInput from '../../../components/ui/input.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
components: {
|
||||
XContainer, MkTextarea, MkInput
|
||||
},
|
||||
|
|
|
@ -21,12 +21,9 @@ import Vue from 'vue';
|
|||
import { v4 as uuid } from 'uuid';
|
||||
import { faPlus, faPencilAlt } from '@fortawesome/free-solid-svg-icons';
|
||||
import { faStickyNote } from '@fortawesome/free-regular-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer
|
||||
},
|
||||
|
|
|
@ -13,14 +13,11 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faBolt, faMagic } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
import MkSwitch from '../../../components/ui/switch.vue';
|
||||
import MkInput from '../../../components/ui/input.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer, MkSwitch, MkInput
|
||||
},
|
||||
|
|
|
@ -13,13 +13,10 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faBolt, faMagic } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
import MkInput from '../../../components/ui/input.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer, MkInput
|
||||
},
|
||||
|
|
|
@ -11,12 +11,9 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faAlignLeft } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer
|
||||
},
|
||||
|
|
|
@ -13,14 +13,11 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faBolt, faMagic } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
import MkTextarea from '../../../components/ui/textarea.vue';
|
||||
import MkInput from '../../../components/ui/input.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer, MkTextarea, MkInput
|
||||
},
|
||||
|
|
|
@ -11,12 +11,9 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faAlignLeft } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../../../i18n';
|
||||
import XContainer from '../page-editor.container.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer
|
||||
},
|
||||
|
|
|
@ -28,11 +28,8 @@
|
|||
import Vue from 'vue';
|
||||
import { faBars, faAngleUp, faAngleDown } from '@fortawesome/free-solid-svg-icons';
|
||||
import { faTrashAlt } from '@fortawesome/free-regular-svg-icons';
|
||||
import i18n from '../../i18n';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
props: {
|
||||
expanded: {
|
||||
type: Boolean,
|
||||
|
|
|
@ -59,14 +59,11 @@
|
|||
import Vue from 'vue';
|
||||
import { faPencilAlt, faPlug } from '@fortawesome/free-solid-svg-icons';
|
||||
import { v4 as uuid } from 'uuid';
|
||||
import i18n from '../../i18n';
|
||||
import XContainer from './page-editor.container.vue';
|
||||
import MkTextarea from '../../components/ui/textarea.vue';
|
||||
import { isLiteralBlock, funcDefs, blockDefs } from '../../scripts/hpml/index';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XContainer, MkTextarea
|
||||
},
|
||||
|
|
|
@ -91,7 +91,6 @@ import PrismEditor from 'vue-prism-editor';
|
|||
import { faICursor, faPlus, faMagic, faCog, faCode, faExternalLinkSquareAlt } from '@fortawesome/free-solid-svg-icons';
|
||||
import { faSave, faStickyNote, faTrashAlt } from '@fortawesome/free-regular-svg-icons';
|
||||
import { v4 as uuid } from 'uuid';
|
||||
import i18n from '../../i18n';
|
||||
import XVariable from './page-editor.script-block.vue';
|
||||
import XBlocks from './page-editor.blocks.vue';
|
||||
import MkTextarea from '../../components/ui/textarea.vue';
|
||||
|
@ -107,8 +106,6 @@ import { collectPageVars } from '../../scripts/collect-page-vars';
|
|||
import { selectDriveFile } from '../../scripts/select-drive-file';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XDraggable, XVariable, XBlocks, MkTextarea, MkContainer, MkButton, MkSelect, MkSwitch, MkInput, PrismEditor
|
||||
},
|
||||
|
|
|
@ -28,14 +28,12 @@
|
|||
import Vue from 'vue';
|
||||
import { faPlus, faEdit } from '@fortawesome/free-solid-svg-icons';
|
||||
import { faStickyNote, faHeart } from '@fortawesome/free-regular-svg-icons';
|
||||
import i18n from '../i18n';
|
||||
import MkPagePreview from '../components/page-preview.vue';
|
||||
import MkPagination from '../components/ui/pagination.vue';
|
||||
import MkButton from '../components/ui/button.vue';
|
||||
import MkContainer from '../components/ui/container.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
components: {
|
||||
MkPagePreview, MkPagination, MkButton, MkContainer
|
||||
},
|
||||
|
|
|
@ -99,8 +99,8 @@ import MkRadio from '../../components/ui/radio.vue';
|
|||
import MkRange from '../../components/ui/range.vue';
|
||||
import XTheme from './theme.vue';
|
||||
import XSidebar from './sidebar.vue';
|
||||
import i18n from '../../i18n';
|
||||
import { langs } from '../../config';
|
||||
import { clientDb, set } from '../../db';
|
||||
|
||||
const sounds = [
|
||||
null,
|
||||
|
@ -120,8 +120,6 @@ const sounds = [
|
|||
];
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('settings') as string
|
||||
|
@ -228,9 +226,23 @@ export default Vue.extend({
|
|||
|
||||
watch: {
|
||||
lang() {
|
||||
const dialog = this.$root.dialog({
|
||||
type: 'waiting',
|
||||
iconOnly: true
|
||||
});
|
||||
|
||||
localStorage.setItem('lang', this.lang);
|
||||
localStorage.removeItem('locale');
|
||||
location.reload();
|
||||
|
||||
return set('_version_', `changeLang-${(new Date()).toJSON()}`, clientDb.i18n)
|
||||
.then(() => location.reload())
|
||||
.catch(() => {
|
||||
dialog.close();
|
||||
this.$root.dialog({
|
||||
type: 'error',
|
||||
iconOnly: true,
|
||||
autoClose: true
|
||||
});
|
||||
});
|
||||
},
|
||||
|
||||
fontSize() {
|
||||
|
|
|
@ -19,12 +19,9 @@ import Vue from 'vue';
|
|||
import { faListUl, faSave, faRedo } from '@fortawesome/free-solid-svg-icons';
|
||||
import MkButton from '../../components/ui/button.vue';
|
||||
import MkTextarea from '../../components/ui/textarea.vue';
|
||||
import i18n from '../../i18n';
|
||||
import { defaultDeviceUserSettings } from '../../store';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkButton,
|
||||
MkTextarea,
|
||||
|
|
|
@ -87,14 +87,11 @@ import MkButton from '../../components/ui/button.vue';
|
|||
import MkSelect from '../../components/ui/select.vue';
|
||||
import MkSwitch from '../../components/ui/switch.vue';
|
||||
import MkTextarea from '../../components/ui/textarea.vue';
|
||||
import i18n from '../../i18n';
|
||||
import { Theme, builtinThemes, applyTheme, validateTheme } from '../../theme';
|
||||
import { selectFile } from '../../scripts/select-file';
|
||||
import { isDeviceDarkmode } from '../../scripts/is-device-darkmode';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkInput,
|
||||
MkButton,
|
||||
|
|
|
@ -59,7 +59,6 @@
|
|||
|
||||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import i18n from '../../i18n';
|
||||
import { Room } from '../../scripts/room/room';
|
||||
import parseAcct from '../../../misc/acct/parse';
|
||||
import XPreview from './preview.vue';
|
||||
|
@ -74,8 +73,6 @@ import { selectFile } from '../../scripts/select-file';
|
|||
let room: Room;
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
XPreview,
|
||||
MkButton,
|
||||
|
|
|
@ -28,14 +28,11 @@ import "prismjs";
|
|||
import 'prismjs/themes/prism-okaidia.css';
|
||||
import PrismEditor from 'vue-prism-editor';
|
||||
import { AiScript, parse, utils, values } from '@syuilo/aiscript';
|
||||
import i18n from '../i18n';
|
||||
import MkContainer from '../components/ui/container.vue';
|
||||
import MkButton from '../components/ui/button.vue';
|
||||
import { createAiScriptEnv } from '../scripts/create-aiscript-env';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('scratchpad') as string
|
||||
|
|
|
@ -18,13 +18,10 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import { faShareAlt } from '@fortawesome/free-solid-svg-icons';
|
||||
import i18n from '../i18n';
|
||||
import PostFormDialog from '../components/post-form-dialog.vue';
|
||||
import MkButton from '../components/ui/button.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
metaInfo() {
|
||||
return {
|
||||
title: this.$t('share') as string
|
||||
|
|
|
@ -19,13 +19,10 @@
|
|||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import parseAcct from '../../../misc/acct/parse';
|
||||
import i18n from '../../i18n';
|
||||
import MkFollowButton from '../../components/follow-button.vue';
|
||||
import MkPagination from '../../components/ui/pagination.vue';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
|
||||
components: {
|
||||
MkPagination,
|
||||
MkFollowButton,
|
||||
|
|
|
@ -14,11 +14,9 @@
|
|||
|
||||
<script lang="ts">
|
||||
import Vue from 'vue';
|
||||
import i18n from '../../i18n';
|
||||
import { getStaticImageUrl } from '../../scripts/get-static-image-url';
|
||||
|
||||
export default Vue.extend({
|
||||
i18n,
|
||||
props: ['user'],
|
||||
data() {
|
||||
return {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue