From 0044d83801fd261e586143b0442102fabf9106cb Mon Sep 17 00:00:00 2001 From: syuilo Date: Tue, 17 Nov 2020 14:59:15 +0900 Subject: [PATCH] nanka iroiro (#6847) * wip * wip * wip * wip * Update ja-JP.yml * wip * wip * wip --- locales/ja-JP.yml | 3 + .../1605585339718-instance-pinned-pages.ts | 14 ++ src/client/components/notes.vue | 2 +- src/client/components/tab.vue | 30 ++-- .../components/taskmanager.api-window.vue | 5 +- src/client/components/taskmanager.vue | 7 +- src/client/pages/channel.vue | 2 +- src/client/pages/channels.vue | 40 ++--- src/client/pages/instance/emojis.vue | 5 +- src/client/pages/instance/settings.vue | 54 ++++--- src/client/pages/my-groups/index.vue | 6 +- src/client/pages/note.vue | 75 ++++++++-- src/client/pages/page-editor/page-editor.vue | 4 +- src/client/pages/page.vue | 2 +- src/client/pages/pages.vue | 24 ++- src/client/pages/settings/mute-block.vue | 5 +- src/client/pages/settings/word-mute.vue | 5 +- src/client/pages/welcome.entrance.block.vue | 141 ++++++++++++++++++ src/client/pages/welcome.entrance.vue | 85 +++++++---- src/client/pages/welcome.vue | 14 +- src/client/router.ts | 6 +- src/client/sidebar.ts | 3 +- src/client/ui/visitor.vue | 20 ++- src/models/entities/meta.ts | 5 + src/models/repositories/page.ts | 3 +- src/server/api/endpoints/admin/update-meta.ts | 8 + src/server/api/endpoints/meta.ts | 89 +++++------ src/server/api/endpoints/notes/clips.ts | 54 +++++++ src/server/api/endpoints/pages/featured.ts | 29 ++++ src/server/web/index.ts | 1 + 30 files changed, 558 insertions(+), 183 deletions(-) create mode 100644 migration/1605585339718-instance-pinned-pages.ts create mode 100644 src/client/pages/welcome.entrance.block.vue create mode 100644 src/server/api/endpoints/notes/clips.ts create mode 100644 src/server/api/endpoints/pages/featured.ts diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index ab540c6a4d..a3f2a82ed3 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -316,6 +316,8 @@ bannerUrl: "バナー画像のURL" basicInfo: "基本情報" pinnedUsers: "ピン留めユーザー" pinnedUsersDescription: "「みつける」ページなどにピン留めしたいユーザーを改行で区切って記述します。" +pinnedPages: "ピン留めページ" +pinnedPagesDescription: "インスタンスのトップページにピン留めしたいページのパスを改行で区切って記述します。" hcaptcha: "hCaptcha" enableHcaptcha: "hCaptchaを有効にする" hcaptchaSiteKey: "サイトキー" @@ -1117,6 +1119,7 @@ _pages: unlike: "いいね解除" my: "自分のページ" liked: "いいねしたページ" + featured: "人気" inspector: "インスペクター" contents: "コンテンツ" content: "ページブロック" diff --git a/migration/1605585339718-instance-pinned-pages.ts b/migration/1605585339718-instance-pinned-pages.ts new file mode 100644 index 0000000000..2f0ebab235 --- /dev/null +++ b/migration/1605585339718-instance-pinned-pages.ts @@ -0,0 +1,14 @@ +import {MigrationInterface, QueryRunner} from "typeorm"; + +export class instancePinnedPages1605585339718 implements MigrationInterface { + name = 'instancePinnedPages1605585339718' + + public async up(queryRunner: QueryRunner): Promise { + await queryRunner.query(`ALTER TABLE "meta" ADD "pinnedPages" character varying(512) array NOT NULL DEFAULT '{"/announcements", "/featured", "/channels", "/pages", "/explore", "/games/reversi", "/about-misskey"}'::varchar[]`); + } + + public async down(queryRunner: QueryRunner): Promise { + await queryRunner.query(`ALTER TABLE "meta" DROP COLUMN "pinnedPages"`); + } + +} diff --git a/src/client/components/notes.vue b/src/client/components/notes.vue index f2ea7e929b..649e7c4cf6 100644 --- a/src/client/components/notes.vue +++ b/src/client/components/notes.vue @@ -8,7 +8,7 @@
- diff --git a/src/client/components/tab.vue b/src/client/components/tab.vue index 7278c74d9a..aca4d32a22 100644 --- a/src/client/components/tab.vue +++ b/src/client/components/tab.vue @@ -1,26 +1,32 @@ - - - diff --git a/src/client/pages/instance/emojis.vue b/src/client/pages/instance/emojis.vue index dcd12edc91..01ea0d7f82 100644 --- a/src/client/pages/instance/emojis.vue +++ b/src/client/pages/instance/emojis.vue @@ -1,7 +1,10 @@