From b5c319b2c716fd383b99f203b5d05106e21936a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=8A=E3=81=95=E3=82=80=E3=81=AE=E3=81=B2=E3=81=A8?= <46447427+samunohito@users.noreply.github.com> Date: Sat, 16 Dec 2023 08:56:26 +0900 Subject: [PATCH 01/17] =?UTF-8?q?fix(frontend):=20test=E3=81=8C=E8=90=BD?= =?UTF-8?q?=E3=81=A1=E3=82=8B=E3=81=AE=E3=82=92=E4=BF=AE=E6=AD=A3=20(#1267?= =?UTF-8?q?9)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/frontend/package.json | 5 +++-- packages/frontend/test/home.test.ts | 5 +++-- pnpm-lock.yaml | 7 +++++++ 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/packages/frontend/package.json b/packages/frontend/package.json index 4cf4779563..4d0139f252 100644 --- a/packages/frontend/package.json +++ b/packages/frontend/package.json @@ -26,8 +26,8 @@ "@tabler/icons-webfont": "2.44.0", "@vitejs/plugin-vue": "4.5.2", "@vue/compiler-sfc": "3.3.11", - "astring": "1.8.6", "aiscript-vscode": "github:aiscript-dev/aiscript-vscode#v0.0.6", + "astring": "1.8.6", "broadcast-channel": "6.0.0", "browser-image-resizer": "github:misskey-dev/browser-image-resizer#v2.2.1-misskey.3", "buraha": "0.0.1", @@ -56,8 +56,8 @@ "punycode": "2.3.1", "rollup": "4.9.0", "sanitize-html": "2.11.0", - "shiki": "0.14.6", "sass": "1.69.5", + "shiki": "0.14.6", "strict-event-emitter-types": "2.0.0", "textarea-caret": "3.1.0", "three": "0.159.0", @@ -116,6 +116,7 @@ "eslint-plugin-vue": "9.19.2", "fast-glob": "3.3.2", "happy-dom": "10.0.3", + "intersection-observer": "0.12.2", "micromatch": "4.0.5", "msw": "1.3.2", "msw-storybook-addon": "1.10.0", diff --git a/packages/frontend/test/home.test.ts b/packages/frontend/test/home.test.ts index 6d38b7e526..094ea071b9 100644 --- a/packages/frontend/test/home.test.ts +++ b/packages/frontend/test/home.test.ts @@ -3,13 +3,14 @@ * SPDX-License-Identifier: AGPL-3.0-only */ -import { describe, test, assert, afterEach } from 'vitest'; -import { render, cleanup, type RenderResult } from '@testing-library/vue'; +import { afterEach, assert, describe, test } from 'vitest'; +import { cleanup, render, type RenderResult } from '@testing-library/vue'; import './init'; import type * as Misskey from 'misskey-js'; import { directives } from '@/directives/index.js'; import { components } from '@/components/index.js'; import XHome from '@/pages/user/home.vue'; +import 'intersection-observer'; describe('XHome', () => { const renderHome = (user: Partial): RenderResult => { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 7c0bc470b0..5319acf932 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -944,6 +944,9 @@ importers: happy-dom: specifier: 10.0.3 version: 10.0.3 + intersection-observer: + specifier: 0.12.2 + version: 0.12.2 micromatch: specifier: 4.0.5 version: 4.0.5 @@ -12996,6 +12999,10 @@ packages: side-channel: 1.0.4 dev: true + /intersection-observer@0.12.2: + resolution: {integrity: sha512-7m1vEcPCxXYI8HqnL8CKI6siDyD+eIWSwgB3DZA+ZTogxk9I4CDnj4wilt9x/+/QbHI4YG5YZNmC6458/e9Ktg==} + dev: true + /invariant@2.2.4: resolution: {integrity: sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==} dependencies: From 617ff00a45ccf54c7d61d2623d977f542b688451 Mon Sep 17 00:00:00 2001 From: FineArchs <133759614+FineArchs@users.noreply.github.com> Date: Sat, 16 Dec 2023 08:57:45 +0900 Subject: [PATCH 02/17] =?UTF-8?q?Fix:=20AiScript=E3=81=AE`readline`?= =?UTF-8?q?=E3=81=8C=E4=B8=8D=E6=AD=A3=E3=81=AA=E5=80=A4=E3=82=92=E8=BF=94?= =?UTF-8?q?=E3=81=99=E3=81=93=E3=81=A8=E3=81=8C=E3=81=82=E3=82=8B=E5=95=8F?= =?UTF-8?q?=E9=A1=8C=E3=82=92=E4=BF=AE=E6=AD=A3=20(#12675)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix input bug * Update CHANGELOG.md --- CHANGELOG.md | 1 + packages/frontend/src/pages/flash/flash.vue | 8 ++------ 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 599bd463fd..bba587cbd3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -67,6 +67,7 @@ - Fix: セキュリティ向上のためAiScriptの`Mk:apiExternal`を無効化 - Fix: ノート中の絵文字をタップして「リアクションする」からリアクションした際にリアクションサウンドが鳴らない不具合を修正 - Fix: ノート中のリアクションの表示を微調整 #12650 +- Fix: AiScriptの`readline`が不正な値を返すことがある問題を修正 ### Server - Enhance: MFM `$[ruby ]` が他ソフトウェアと連合されるように diff --git a/packages/frontend/src/pages/flash/flash.vue b/packages/frontend/src/pages/flash/flash.vue index 0ac95ca282..8c5188a1e9 100644 --- a/packages/frontend/src/pages/flash/flash.vue +++ b/packages/frontend/src/pages/flash/flash.vue @@ -165,12 +165,8 @@ async function run() { return new Promise(ok => { os.inputText({ title: q, - }).then(({ canceled, result: a }) => { - if (canceled) { - ok(''); - } else { - ok(a); - } + }).then(({ result: a }) => { + ok(a ?? ''); }); }); }, From 1260e8b74b2e83eb70a650bfe07ce45e8ee95b62 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sat, 16 Dec 2023 08:58:03 +0900 Subject: [PATCH 03/17] chore(deps): bump actions/upload-artifact from 2 to 4 (#12670) Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 2 to 4. - [Release notes](https://github.com/actions/upload-artifact/releases) - [Commits](https://github.com/actions/upload-artifact/compare/v2...v4) --- updated-dependencies: - dependency-name: actions/upload-artifact dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/get-api-diff.yml | 4 ++-- .github/workflows/report-api-diff.yml | 2 +- .github/workflows/test-frontend.yml | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/get-api-diff.yml b/.github/workflows/get-api-diff.yml index 75a458424e..9dc812061b 100644 --- a/.github/workflows/get-api-diff.yml +++ b/.github/workflows/get-api-diff.yml @@ -54,7 +54,7 @@ jobs: - name: Copy API.json run: cp packages/backend/built/api.json ${{ matrix.api-json-name }} - name: Upload Artifact - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: api-artifact path: ${{ matrix.api-json-name }} @@ -67,7 +67,7 @@ jobs: PR_NUMBER: ${{ github.event.number }} run: | echo "$PR_NUMBER" > ./pr_number - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: name: api-artifact path: pr_number diff --git a/.github/workflows/report-api-diff.yml b/.github/workflows/report-api-diff.yml index 2868d6cc09..309516772f 100644 --- a/.github/workflows/report-api-diff.yml +++ b/.github/workflows/report-api-diff.yml @@ -56,7 +56,7 @@ jobs: - name: Echo full diff run: cat ./api-full.json.diff - name: Upload full diff to Artifact - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: api-artifact path: | diff --git a/.github/workflows/test-frontend.yml b/.github/workflows/test-frontend.yml index 50c225189d..e5c461e6d1 100644 --- a/.github/workflows/test-frontend.yml +++ b/.github/workflows/test-frontend.yml @@ -108,12 +108,12 @@ jobs: wait-on: 'http://localhost:61812' headed: true browser: ${{ matrix.browser }} - - uses: actions/upload-artifact@v2 + - uses: actions/upload-artifact@v4 if: failure() with: name: ${{ matrix.browser }}-cypress-screenshots path: cypress/screenshots - - uses: actions/upload-artifact@v2 + - uses: actions/upload-artifact@v4 if: always() with: name: ${{ matrix.browser }}-cypress-videos From 3e256eee2cc8a0a7b93084b82bad61e0af9d6689 Mon Sep 17 00:00:00 2001 From: shiosyakeyakini Date: Sat, 16 Dec 2023 09:00:32 +0900 Subject: [PATCH 04/17] =?UTF-8?q?Fix(backend):=20JSONSchema=E3=81=AB?= =?UTF-8?q?=E4=B8=8D=E8=B6=B3=E3=81=97=E3=81=A6=E3=81=84=E3=82=8B=E3=83=91?= =?UTF-8?q?=E3=83=A9=E3=83=A1=E3=83=BC=E3=82=BF=E3=82=92=E8=BF=BD=E5=8A=A0?= =?UTF-8?q?=20(#12680)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Fix(backend): JSONSchemaに不足しているパラメータを追加 * nullable:falseに修正 --------- Co-authored-by: sorairo --- packages/backend/src/models/json-schema/user.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/packages/backend/src/models/json-schema/user.ts b/packages/backend/src/models/json-schema/user.ts index c6b96b85f0..7a3ca58269 100644 --- a/packages/backend/src/models/json-schema/user.ts +++ b/packages/backend/src/models/json-schema/user.ts @@ -74,6 +74,14 @@ export const packedUserLiteSchema = { format: 'url', nullable: false, optional: false, }, + offsetX: { + type: 'number', + nullable: false, optional: true, + }, + offsetY: { + type: 'number', + nullable: false, optional: true, + }, }, }, }, From 9f49b9f4d2081effeccde27ed34a65bfc0f11c28 Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 16 Dec 2023 10:58:44 +0900 Subject: [PATCH 05/17] =?UTF-8?q?fix(backend):=20HTTP=20Digest=E3=83=98?= =?UTF-8?q?=E3=83=83=E3=83=80=E3=81=AE=E3=82=A2=E3=83=AB=E3=82=B4=E3=83=AA?= =?UTF-8?q?=E3=82=BA=E3=83=A0=E9=83=A8=E5=88=86=E3=81=AB=E5=A4=A7=E6=96=87?= =?UTF-8?q?=E5=AD=97=E3=81=AE"SHA-256"=E3=81=97=E3=81=8B=E4=BD=BF=E3=81=88?= =?UTF-8?q?=E3=81=AA=E3=81=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fix #12678 --- CHANGELOG.md | 1 + packages/backend/src/server/ActivityPubServerService.ts | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bba587cbd3..ee8cbb69bc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -86,6 +86,7 @@ - Fix: 「みつける」が年越し時に壊れる問題を修正 - Fix: アカウントをブロックした際に、自身のユーザーのページでノートが相手に表示される問題を修正 - Fix: モデレーションログがモデレーターは閲覧できないように修正 +- Fix: HTTP Digestヘッダのアルゴリズム部分に大文字の"SHA-256"しか使えない ## 2023.11.1 diff --git a/packages/backend/src/server/ActivityPubServerService.ts b/packages/backend/src/server/ActivityPubServerService.ts index 380cdfc34c..2bc7e1136a 100644 --- a/packages/backend/src/server/ActivityPubServerService.ts +++ b/packages/backend/src/server/ActivityPubServerService.ts @@ -138,7 +138,7 @@ export class ActivityPubServerService { return; } - const algo = match[1]; + const algo = match[1].toUpperCase(); const digestValue = match[2]; if (algo !== 'SHA-256') { From 390602837bf85a01e0c2f91deb3bab6770a87f0d Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 16 Dec 2023 11:56:58 +0900 Subject: [PATCH 06/17] enhance(frontend): tweak user home page --- packages/frontend/src/pages/user/home.vue | 12 +---- .../src/pages/user/index.timeline.vue | 48 ++++++++++--------- packages/frontend/src/pages/user/index.vue | 4 +- 3 files changed, 31 insertions(+), 33 deletions(-) diff --git a/packages/frontend/src/pages/user/home.vue b/packages/frontend/src/pages/user/home.vue index a0163bfc68..a87e03e761 100644 --- a/packages/frontend/src/pages/user/home.vue +++ b/packages/frontend/src/pages/user/home.vue @@ -136,9 +136,8 @@ SPDX-License-Identifier: AGPL-3.0-only
-
{{ i18n.ts.featured }}
- +
@@ -193,6 +192,7 @@ function calcAge(birthdate: string): number { const XFiles = defineAsyncComponent(() => import('./index.files.vue')); const XActivity = defineAsyncComponent(() => import('./index.activity.vue')); +const XTimeline = defineAsyncComponent(() => import('./index.timeline.vue')); const props = withDefaults(defineProps<{ user: Misskey.entities.UserDetailed; @@ -219,14 +219,6 @@ watch(moderationNote, async () => { await os.api('admin/update-user-note', { userId: props.user.id, text: moderationNote.value }); }); -const pagination = { - endpoint: 'users/featured-notes' as const, - limit: 10, - params: computed(() => ({ - userId: props.user.id, - })), -}; - const style = computed(() => { if (props.user.bannerUrl == null) return {}; return { diff --git a/packages/frontend/src/pages/user/index.timeline.vue b/packages/frontend/src/pages/user/index.timeline.vue index 6cf5bcf91f..e5a0f49e3d 100644 --- a/packages/frontend/src/pages/user/index.timeline.vue +++ b/packages/frontend/src/pages/user/index.timeline.vue @@ -4,18 +4,17 @@ SPDX-License-Identifier: AGPL-3.0-only --> From 776eea736a2607c62145c01b48a8271dd355f006 Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 16 Dec 2023 17:37:50 +0900 Subject: [PATCH 16/17] enhance(frontend): tweak avatar decoration setting ui --- locales/index.d.ts | 1 + locales/ja-JP.yml | 1 + ...n.vue => avatar-decoration.decoration.vue} | 0 ...ialog.vue => avatar-decoration.dialog.vue} | 0 ...r-decoration.vue => avatar-decoration.vue} | 77 ++++++++++++------- .../frontend/src/pages/settings/profile.vue | 28 ++++--- packages/frontend/src/router.ts | 4 + 7 files changed, 68 insertions(+), 43 deletions(-) rename packages/frontend/src/pages/settings/{profile.avatar-decoration.decoration.vue => avatar-decoration.decoration.vue} (100%) rename packages/frontend/src/pages/settings/{profile.avatar-decoration.dialog.vue => avatar-decoration.dialog.vue} (100%) rename packages/frontend/src/pages/settings/{profile.avatar-decoration.vue => avatar-decoration.vue} (58%) diff --git a/locales/index.d.ts b/locales/index.d.ts index c8a7b4c70d..cd15bd968f 100644 --- a/locales/index.d.ts +++ b/locales/index.d.ts @@ -1183,6 +1183,7 @@ export interface Locale { "remainingN": string; "overwriteContentConfirm": string; "seasonalScreenEffect": string; + "decorate": string; "_announcement": { "forExistingUsers": string; "forExistingUsersDescription": string; diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index 25a734ef4f..5537db9d56 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -1180,6 +1180,7 @@ reloadRequiredToApplySettings: "設定の反映にはリロードが必要です remainingN: "残り: {n}" overwriteContentConfirm: "現在の内容に上書きされますがよろしいですか?" seasonalScreenEffect: "季節に応じた画面の演出" +decorate: "デコる" _announcement: forExistingUsers: "既存ユーザーのみ" diff --git a/packages/frontend/src/pages/settings/profile.avatar-decoration.decoration.vue b/packages/frontend/src/pages/settings/avatar-decoration.decoration.vue similarity index 100% rename from packages/frontend/src/pages/settings/profile.avatar-decoration.decoration.vue rename to packages/frontend/src/pages/settings/avatar-decoration.decoration.vue diff --git a/packages/frontend/src/pages/settings/profile.avatar-decoration.dialog.vue b/packages/frontend/src/pages/settings/avatar-decoration.dialog.vue similarity index 100% rename from packages/frontend/src/pages/settings/profile.avatar-decoration.dialog.vue rename to packages/frontend/src/pages/settings/avatar-decoration.dialog.vue diff --git a/packages/frontend/src/pages/settings/profile.avatar-decoration.vue b/packages/frontend/src/pages/settings/avatar-decoration.vue similarity index 58% rename from packages/frontend/src/pages/settings/profile.avatar-decoration.vue rename to packages/frontend/src/pages/settings/avatar-decoration.vue index 8579acfed8..6551fc917e 100644 --- a/packages/frontend/src/pages/settings/profile.avatar-decoration.vue +++ b/packages/frontend/src/pages/settings/avatar-decoration.vue @@ -4,51 +4,56 @@ SPDX-License-Identifier: AGPL-3.0-only -->