From 299921d0b0e6cd6852e83256fa416e6f2b729b83 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=B2=E3=81=9F=E3=82=8A=E3=82=93?= Date: Wed, 2 Oct 2024 10:58:15 +0900 Subject: [PATCH] Merge pull request #37 from lqvp/master MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit アカウント作成時のデフォルトを変更 --- DIFFERENCE.md | 12 ------------ packages/backend/migration/1000000000000-Init.js | 2 +- .../backend/migration/1606191203881-no-crawle.js | 2 +- .../backend/migration/1607353487793-isExplorable.js | 2 +- .../1618639857000-user-hide-online-status.js | 2 +- .../1697683129062-feat-auto-reject-follow-request.js | 2 +- .../backend/migration/1702718871541-ffVisibility.js | 4 ++-- .../src/components/MkUserSetupDialog.Privacy.vue | 7 ++++--- packages/frontend/src/store.ts | 4 ++-- 9 files changed, 13 insertions(+), 24 deletions(-) diff --git a/DIFFERENCE.md b/DIFFERENCE.md index d0fb6f5e26..6365923051 100755 --- a/DIFFERENCE.md +++ b/DIFFERENCE.md @@ -1,20 +1,8 @@ # DIFFRENCE ## 2024.9.0-yami-1.3.1 ## Client -<<<<<<< HEAD -<<<<<<< HEAD -- フォロー/フォロワー/アナウンス/みつける/Play/ギャラリー/チャンネル/TLのページをログイン必須に -======= -- フォロー/フォロワー/アナウンス/みつける/Play/ギャラリー/チャンネル/TL/ユーザー/ノートのページをログイン必須に -<<<<<<< HEAD ->>>>>>> 06558e71bc (fix conflict) -======= -- hideReactionUsersをデフォルトで有効に(未ログインユーザーからリアクションしたユーザーを隠せます) ->>>>>>> 22e307ca5b (hideReactionUsersをtrueへ) -======= - フォロー/フォロワー/アナウンス/みつける/Play/ギャラリー/チャンネル/TL/ユーザー/ノートのページをログイン必須に - hideReactionUsersをデフォルトで有効に(未ログインユーザーからリアクションしたユーザーを隠せます) ->>>>>>> 806ccc706a (Merge pull request #43 from lqvp/master) ## 2024.9.0-yami-1.3.0 ## Feat diff --git a/packages/backend/migration/1000000000000-Init.js b/packages/backend/migration/1000000000000-Init.js index c06885fd40..4d4a3d5b2d 100755 --- a/packages/backend/migration/1000000000000-Init.js +++ b/packages/backend/migration/1000000000000-Init.js @@ -25,7 +25,7 @@ export class Init1000000000000 { await queryRunner.query(`CREATE UNIQUE INDEX "IDX_c55b2b7c284d9fef98026fc88e" ON "drive_file" ("webpublicAccessKey") `); await queryRunner.query(`CREATE INDEX "IDX_e5848eac4940934e23dbc17581" ON "drive_file" ("uri") `); await queryRunner.query(`CREATE INDEX "IDX_bb90d1956dafc4068c28aa7560" ON "drive_file" ("folderId") `); - await queryRunner.query(`CREATE TABLE "user" ("id" character varying(32) NOT NULL, "createdAt" TIMESTAMP WITH TIME ZONE NOT NULL, "updatedAt" TIMESTAMP WITH TIME ZONE, "lastFetchedAt" TIMESTAMP WITH TIME ZONE, "username" character varying(128) NOT NULL, "usernameLower" character varying(128) NOT NULL, "name" character varying(128), "followersCount" integer NOT NULL DEFAULT 0, "followingCount" integer NOT NULL DEFAULT 0, "notesCount" integer NOT NULL DEFAULT 0, "avatarId" character varying(32), "bannerId" character varying(32), "tags" character varying(128) array NOT NULL DEFAULT '{}'::varchar[], "avatarUrl" character varying(512), "bannerUrl" character varying(512), "avatarColor" character varying(32), "bannerColor" character varying(32), "isSuspended" boolean NOT NULL DEFAULT false, "isSilenced" boolean NOT NULL DEFAULT false, "isLocked" boolean NOT NULL DEFAULT false, "isBot" boolean NOT NULL DEFAULT false, "isCat" boolean NOT NULL DEFAULT false, "isAdmin" boolean NOT NULL DEFAULT false, "isModerator" boolean NOT NULL DEFAULT false, "isVerified" boolean NOT NULL DEFAULT false, "emojis" character varying(128) array NOT NULL DEFAULT '{}'::varchar[], "host" character varying(128), "inbox" character varying(512), "sharedInbox" character varying(512), "featured" character varying(512), "uri" character varying(512), "token" character(16), CONSTRAINT "UQ_a854e557b1b14814750c7c7b0c9" UNIQUE ("token"), CONSTRAINT "REL_58f5c71eaab331645112cf8cfa" UNIQUE ("avatarId"), CONSTRAINT "REL_afc64b53f8db3707ceb34eb28e" UNIQUE ("bannerId"), CONSTRAINT "PK_cace4a159ff9f2512dd42373760" PRIMARY KEY ("id"))`); + await queryRunner.query(`CREATE TABLE "user" ("id" character varying(32) NOT NULL, "createdAt" TIMESTAMP WITH TIME ZONE NOT NULL, "updatedAt" TIMESTAMP WITH TIME ZONE, "lastFetchedAt" TIMESTAMP WITH TIME ZONE, "username" character varying(128) NOT NULL, "usernameLower" character varying(128) NOT NULL, "name" character varying(128), "followersCount" integer NOT NULL DEFAULT 0, "followingCount" integer NOT NULL DEFAULT 0, "notesCount" integer NOT NULL DEFAULT 0, "avatarId" character varying(32), "bannerId" character varying(32), "tags" character varying(128) array NOT NULL DEFAULT '{}'::varchar[], "avatarUrl" character varying(512), "bannerUrl" character varying(512), "avatarColor" character varying(32), "bannerColor" character varying(32), "isSuspended" boolean NOT NULL DEFAULT false, "isSilenced" boolean NOT NULL DEFAULT false, "isLocked" boolean NOT NULL DEFAULT true, "isBot" boolean NOT NULL DEFAULT false, "isCat" boolean NOT NULL DEFAULT false, "isAdmin" boolean NOT NULL DEFAULT false, "isModerator" boolean NOT NULL DEFAULT false, "isVerified" boolean NOT NULL DEFAULT false, "emojis" character varying(128) array NOT NULL DEFAULT '{}'::varchar[], "host" character varying(128), "inbox" character varying(512), "sharedInbox" character varying(512), "featured" character varying(512), "uri" character varying(512), "token" character(16), CONSTRAINT "UQ_a854e557b1b14814750c7c7b0c9" UNIQUE ("token"), CONSTRAINT "REL_58f5c71eaab331645112cf8cfa" UNIQUE ("avatarId"), CONSTRAINT "REL_afc64b53f8db3707ceb34eb28e" UNIQUE ("bannerId"), CONSTRAINT "PK_cace4a159ff9f2512dd42373760" PRIMARY KEY ("id"))`); await queryRunner.query(`CREATE INDEX "IDX_e11e649824a45d8ed01d597fd9" ON "user" ("createdAt") `); await queryRunner.query(`CREATE INDEX "IDX_80ca6e6ef65fb9ef34ea8c90f4" ON "user" ("updatedAt") `); await queryRunner.query(`CREATE INDEX "IDX_a27b942a0d6dcff90e3ee9b5e8" ON "user" ("usernameLower") `); diff --git a/packages/backend/migration/1606191203881-no-crawle.js b/packages/backend/migration/1606191203881-no-crawle.js index af04566eaa..0a757a2fca 100755 --- a/packages/backend/migration/1606191203881-no-crawle.js +++ b/packages/backend/migration/1606191203881-no-crawle.js @@ -8,7 +8,7 @@ export class noCrawle1606191203881 { this.name = 'noCrawle1606191203881'; } async up(queryRunner) { - await queryRunner.query(`ALTER TABLE "user_profile" ADD "noCrawle" boolean NOT NULL DEFAULT false`); + await queryRunner.query(`ALTER TABLE "user_profile" ADD "noCrawle" boolean NOT NULL DEFAULT true`); await queryRunner.query(`COMMENT ON COLUMN "user_profile"."noCrawle" IS 'Whether reject index by crawler.'`); } async down(queryRunner) { diff --git a/packages/backend/migration/1607353487793-isExplorable.js b/packages/backend/migration/1607353487793-isExplorable.js index e07fe6c306..8332d9a692 100755 --- a/packages/backend/migration/1607353487793-isExplorable.js +++ b/packages/backend/migration/1607353487793-isExplorable.js @@ -8,7 +8,7 @@ export class isExplorable1607353487793 { this.name = 'isExplorable1607353487793'; } async up(queryRunner) { - await queryRunner.query(`ALTER TABLE "user" ADD "isExplorable" boolean NOT NULL DEFAULT true`); + await queryRunner.query(`ALTER TABLE "user" ADD "isExplorable" boolean NOT NULL DEFAULT false`); await queryRunner.query(`COMMENT ON COLUMN "user"."isExplorable" IS 'Whether the User is explorable.'`); await queryRunner.query(`CREATE INDEX "IDX_d5a1b83c7cab66f167e6888188" ON "user" ("isExplorable") `); } diff --git a/packages/backend/migration/1618639857000-user-hide-online-status.js b/packages/backend/migration/1618639857000-user-hide-online-status.js index 2012962742..221b8c6eed 100755 --- a/packages/backend/migration/1618639857000-user-hide-online-status.js +++ b/packages/backend/migration/1618639857000-user-hide-online-status.js @@ -8,7 +8,7 @@ export class userHideOnlineStatus1618639857000 { this.name = 'userHideOnlineStatus1618639857000'; } async up(queryRunner) { - await queryRunner.query(`ALTER TABLE "user" ADD "hideOnlineStatus" boolean NOT NULL DEFAULT false`); + await queryRunner.query(`ALTER TABLE "user" ADD "hideOnlineStatus" boolean NOT NULL DEFAULT true`); } async down(queryRunner) { await queryRunner.query(`ALTER TABLE "user" DROP COLUMN "hideOnlineStatus"`); diff --git a/packages/backend/migration/1697683129062-feat-auto-reject-follow-request.js b/packages/backend/migration/1697683129062-feat-auto-reject-follow-request.js index a41ea57856..f35ea28113 100644 --- a/packages/backend/migration/1697683129062-feat-auto-reject-follow-request.js +++ b/packages/backend/migration/1697683129062-feat-auto-reject-follow-request.js @@ -2,7 +2,7 @@ export class FeatAutoRejectFollowRequest1697683129062 { name = 'FeatAutoRejectFollowRequest1697683129062' async up(queryRunner) { - await queryRunner.query(`ALTER TABLE "user_profile" ADD "autoRejectFollowRequest" boolean NOT NULL DEFAULT false`); + await queryRunner.query(`ALTER TABLE "user_profile" ADD "autoRejectFollowRequest" boolean NOT NULL DEFAULT true`); } async down(queryRunner) { diff --git a/packages/backend/migration/1702718871541-ffVisibility.js b/packages/backend/migration/1702718871541-ffVisibility.js index 164af00f25..4962816787 100755 --- a/packages/backend/migration/1702718871541-ffVisibility.js +++ b/packages/backend/migration/1702718871541-ffVisibility.js @@ -12,8 +12,8 @@ export class ffVisibility1702718871541 { await queryRunner.query(`CREATE CAST ("public"."user_profile_ffvisibility_enum" AS "public"."user_profile_followingvisibility_enum") WITH INOUT AS ASSIGNMENT`); await queryRunner.query(`CREATE TYPE "public"."user_profile_followersVisibility_enum" AS ENUM('public', 'followers', 'private')`); await queryRunner.query(`CREATE CAST ("public"."user_profile_ffvisibility_enum" AS "public"."user_profile_followersVisibility_enum") WITH INOUT AS ASSIGNMENT`); - await queryRunner.query(`ALTER TABLE "user_profile" ADD "followingVisibility" "public"."user_profile_followingvisibility_enum" NOT NULL DEFAULT 'public'`); - await queryRunner.query(`ALTER TABLE "user_profile" ADD "followersVisibility" "public"."user_profile_followersVisibility_enum" NOT NULL DEFAULT 'public'`); + await queryRunner.query(`ALTER TABLE "user_profile" ADD "followingVisibility" "public"."user_profile_followingvisibility_enum" NOT NULL DEFAULT 'private'`); + await queryRunner.query(`ALTER TABLE "user_profile" ADD "followersVisibility" "public"."user_profile_followersVisibility_enum" NOT NULL DEFAULT 'private'`); await queryRunner.query(`UPDATE "user_profile" SET "followingVisibility" = "ffVisibility"`); await queryRunner.query(`UPDATE "user_profile" SET "followersVisibility" = "ffVisibility"`); await queryRunner.query(`DROP CAST ("public"."user_profile_ffvisibility_enum" AS "public"."user_profile_followersVisibility_enum")`); diff --git a/packages/frontend/src/components/MkUserSetupDialog.Privacy.vue b/packages/frontend/src/components/MkUserSetupDialog.Privacy.vue index bc998d6158..0a037ffa31 100755 --- a/packages/frontend/src/components/MkUserSetupDialog.Privacy.vue +++ b/packages/frontend/src/components/MkUserSetupDialog.Privacy.vue @@ -43,9 +43,10 @@ import MkInfo from '@/components/MkInfo.vue'; import MkFolder from '@/components/MkFolder.vue'; import { misskeyApi } from '@/scripts/misskey-api.js'; -const isLocked = ref(false); -const hideOnlineStatus = ref(false); -const noCrawle = ref(false); +const isLocked = ref(true); +const hideOnlineStatus = ref(true); +const noCrawle = ref(true); +const preventAiLearning = ref(true); watch([isLocked, hideOnlineStatus, noCrawle], () => { misskeyApi('i/update', { diff --git a/packages/frontend/src/store.ts b/packages/frontend/src/store.ts index e2c839939f..618cc98421 100755 --- a/packages/frontend/src/store.ts +++ b/packages/frontend/src/store.ts @@ -115,7 +115,7 @@ export const defaultStore = markRaw(new Storage('base', { }, defaultNoteLocalOnly: { where: 'account', - default: false, + default: true, }, uploadFolder: { where: 'account', @@ -143,7 +143,7 @@ export const defaultStore = markRaw(new Storage('base', { }, reactionAcceptance: { where: 'account', - default: 'nonSensitiveOnly' as 'likeOnly' | 'likeOnlyForRemote' | 'nonSensitiveOnly' | 'nonSensitiveOnlyForLocalLikeOnlyForRemote' | null, + default: 'likeOnly' as 'likeOnly' | 'likeOnlyForRemote' | 'nonSensitiveOnly' | 'nonSensitiveOnlyForLocalLikeOnlyForRemote' | null, }, like: { where: 'account',