From 6b676a928d3e167c98f2a1854a432adf5c125d65 Mon Sep 17 00:00:00 2001 From: yupix Date: Sun, 10 Mar 2024 17:31:39 +0900 Subject: [PATCH 01/87] =?UTF-8?q?enhance(backend):=20antennas/update?= =?UTF-8?q?=E3=81=AE=E5=BF=85=E9=A0=88=E9=A0=85=E7=9B=AE=E3=82=92antennaId?= =?UTF-8?q?=E3=81=AE=E3=81=BF=E3=81=AB=20(#13542)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * refactor: antennas/updateの必須項目を最小限に * fix: userListIdがnullにできない --- CHANGELOG.md | 2 +- .../server/api/endpoints/antennas/update.ts | 12 +++++++----- packages/misskey-js/src/autogen/types.ts | 18 +++++++++--------- 3 files changed, 17 insertions(+), 15 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index be621e1ebd..8c5f05dbe5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -26,7 +26,7 @@ - Fix: カスタム絵文字の画像読み込みに失敗した際はテキストではなくダミー画像を表示 #13487 ### Server -- +- Enhance: エンドポイント`antennas/update`の必須項目を`antennaId`のみに ## 2024.3.0 diff --git a/packages/backend/src/server/api/endpoints/antennas/update.ts b/packages/backend/src/server/api/endpoints/antennas/update.ts index 459729f61f..76a34924a0 100644 --- a/packages/backend/src/server/api/endpoints/antennas/update.ts +++ b/packages/backend/src/server/api/endpoints/antennas/update.ts @@ -67,7 +67,7 @@ export const paramDef = { withFile: { type: 'boolean' }, notify: { type: 'boolean' }, }, - required: ['antennaId', 'name', 'src', 'keywords', 'excludeKeywords', 'users', 'caseSensitive', 'withReplies', 'withFile', 'notify'], + required: ['antennaId'], } as const; @Injectable() @@ -83,8 +83,10 @@ export default class extends Endpoint { // eslint- private globalEventService: GlobalEventService, ) { super(meta, paramDef, async (ps, me) => { - if (ps.keywords.flat().every(x => x === '') && ps.excludeKeywords.flat().every(x => x === '')) { - throw new Error('either keywords or excludeKeywords is required.'); + if (ps.keywords && ps.excludeKeywords) { + if (ps.keywords.flat().every(x => x === '') && ps.excludeKeywords.flat().every(x => x === '')) { + throw new Error('either keywords or excludeKeywords is required.'); + } } // Fetch the antenna const antenna = await this.antennasRepository.findOneBy({ @@ -98,7 +100,7 @@ export default class extends Endpoint { // eslint- let userList; - if (ps.src === 'list' && ps.userListId) { + if ((ps.src === 'list' || antenna.src === 'list') && ps.userListId) { userList = await this.userListsRepository.findOneBy({ id: ps.userListId, userId: me.id, @@ -112,7 +114,7 @@ export default class extends Endpoint { // eslint- await this.antennasRepository.update(antenna.id, { name: ps.name, src: ps.src, - userListId: userList ? userList.id : null, + userListId: ps.userListId !== undefined ? userList ? userList.id : null : undefined, keywords: ps.keywords, excludeKeywords: ps.excludeKeywords, users: ps.users, diff --git a/packages/misskey-js/src/autogen/types.ts b/packages/misskey-js/src/autogen/types.ts index 41c3f50135..be3e86bd78 100644 --- a/packages/misskey-js/src/autogen/types.ts +++ b/packages/misskey-js/src/autogen/types.ts @@ -9925,19 +9925,19 @@ export type operations = { 'application/json': { /** Format: misskey:id */ antennaId: string; - name: string; + name?: string; /** @enum {string} */ - src: 'home' | 'all' | 'users' | 'list' | 'users_blacklist'; + src?: 'home' | 'all' | 'users' | 'list' | 'users_blacklist'; /** Format: misskey:id */ userListId?: string | null; - keywords: string[][]; - excludeKeywords: string[][]; - users: string[]; - caseSensitive: boolean; + keywords?: string[][]; + excludeKeywords?: string[][]; + users?: string[]; + caseSensitive?: boolean; localOnly?: boolean; - withReplies: boolean; - withFile: boolean; - notify: boolean; + withReplies?: boolean; + withFile?: boolean; + notify?: boolean; }; }; }; From e23e2f4ae9368754e4eadcd0afaa2bb1f984ba6a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=8B=E3=81=A3=E3=81=93=E3=81=8B=E3=82=8A?= <67428053+kakkokari-gtyih@users.noreply.github.com> Date: Tue, 12 Mar 2024 12:09:26 +0900 Subject: [PATCH 02/87] Fix Changelog --- CHANGELOG.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8c5f05dbe5..9c2a32aa56 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,7 +12,7 @@ - Fix: 周年の実績が閏年を考慮しない問題を修正 ### Server -- +- Enhance: エンドポイント`antennas/update`の必須項目を`antennaId`のみに ## 2024.3.1 @@ -26,7 +26,7 @@ - Fix: カスタム絵文字の画像読み込みに失敗した際はテキストではなくダミー画像を表示 #13487 ### Server -- Enhance: エンドポイント`antennas/update`の必須項目を`antennaId`のみに +- ## 2024.3.0 From b280faa8e72c29036ef65af7fd8949538ab43dbd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=8B=E3=81=A3=E3=81=93=E3=81=8B=E3=82=8A?= <67428053+kakkokari-gtyih@users.noreply.github.com> Date: Tue, 12 Mar 2024 13:48:14 +0900 Subject: [PATCH 03/87] =?UTF-8?q?enhance(frontend):=20=E5=90=84=E3=82=B5?= =?UTF-8?q?=E3=83=BC=E3=83=90=E3=83=BC=E3=81=AFMisskey=E3=82=92=E5=88=A9?= =?UTF-8?q?=E7=94=A8=E3=81=97=E3=81=9F=E3=82=B5=E3=83=BC=E3=83=93=E3=82=B9?= =?UTF-8?q?=E3=81=A7=E3=81=82=E3=82=8B=E3=81=93=E3=81=A8=E3=82=92=E5=BC=B7?= =?UTF-8?q?=E8=AA=BF=20(#13559)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * ロゴ周りを追加 * 調整 --------- Co-authored-by: uboar <10250330+uboar@users.noreply.github.com> --- .../frontend/src/pages/welcome.entrance.a.vue | 27 ++++++++++++++----- 1 file changed, 20 insertions(+), 7 deletions(-) diff --git a/packages/frontend/src/pages/welcome.entrance.a.vue b/packages/frontend/src/pages/welcome.entrance.a.vue index 89bb010dd6..6c05aad24f 100644 --- a/packages/frontend/src/pages/welcome.entrance.a.vue +++ b/packages/frontend/src/pages/welcome.entrance.a.vue @@ -9,7 +9,10 @@ SPDX-License-Identifier: AGPL-3.0-only
- +
+
Powered by
+ +
@@ -113,14 +116,24 @@ misskeyApiGet('federation/instances', { opacity: 0.5; } - > .misskey { + > .logo-wrapper { position: fixed; - top: 42px; - left: 42px; - width: 140px; + top: 36px; + left: 36px; + flex: auto; + color: #fff; + user-select: none; + pointer-events: none; - @media (max-width: 450px) { - width: 130px; + > .powered-by { + margin-bottom: 2px; + } + + > .misskey { + width: 140px; + @media (max-width: 450px) { + width: 130px; + } } } From 6d9c234cb6d3ddfaa3266255e7c305b329a556b6 Mon Sep 17 00:00:00 2001 From: anatawa12 Date: Tue, 12 Mar 2024 13:50:24 +0900 Subject: [PATCH 04/87] fix: URL preview popup for local URL appears in the upper left corner (#13555) --- CHANGELOG.md | 1 + packages/frontend/src/components/MkLink.vue | 4 ++-- packages/frontend/src/components/global/MkA.vue | 8 ++++++-- packages/frontend/src/components/global/MkUrl.vue | 2 +- 4 files changed, 10 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9c2a32aa56..83d0a3f7d2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ - Enhance: リアクション受け入れが「いいねのみ」の場合はリアクション絵文字一覧を表示しないように - Fix: 一部のページ内リンクが正しく動作しない問題を修正 - Fix: 周年の実績が閏年を考慮しない問題を修正 +- Fix: ローカルURLのプレビューポップアップが左上に表示される ### Server - Enhance: エンドポイント`antennas/update`の必須項目を`antennaId`のみに diff --git a/packages/frontend/src/components/MkLink.vue b/packages/frontend/src/components/MkLink.vue index a5abbeceac..3f7aba2fe4 100644 --- a/packages/frontend/src/components/MkLink.vue +++ b/packages/frontend/src/components/MkLink.vue @@ -29,13 +29,13 @@ const self = props.url.startsWith(local); const attr = self ? 'to' : 'href'; const target = self ? null : '_blank'; -const el = ref(); +const el = ref(); useTooltip(el, (showing) => { os.popup(defineAsyncComponent(() => import('@/components/MkUrlPreviewPopup.vue')), { showing, url: props.url, - source: el.value, + source: el.value instanceof HTMLElement ? el.value : el.value?.$el, }, {}, 'closed'); }); diff --git a/packages/frontend/src/components/global/MkA.vue b/packages/frontend/src/components/global/MkA.vue index 61d7ac17d9..1ba7cb2022 100644 --- a/packages/frontend/src/components/global/MkA.vue +++ b/packages/frontend/src/components/global/MkA.vue @@ -4,13 +4,13 @@ SPDX-License-Identifier: AGPL-3.0-only --> + + diff --git a/packages/frontend/src/components/page/page.note.vue b/packages/frontend/src/components/page/page.note.vue index 7b56494a6e..b5ba407806 100644 --- a/packages/frontend/src/components/page/page.note.vue +++ b/packages/frontend/src/components/page/page.note.vue @@ -4,9 +4,9 @@ SPDX-License-Identifier: AGPL-3.0-only --> @@ -32,3 +32,10 @@ onMounted(() => { }); }); + + diff --git a/packages/frontend/src/components/page/page.text.vue b/packages/frontend/src/components/page/page.text.vue index 81a4c4fa93..61247b381f 100644 --- a/packages/frontend/src/components/page/page.text.vue +++ b/packages/frontend/src/components/page/page.text.vue @@ -4,7 +4,7 @@ SPDX-License-Identifier: AGPL-3.0-only --> -
{{ i18n.ts._2fa.step2 }}
{{ i18n.ts._2fa.step2Click }}
- +
{{ i18n.ts._2fa.step2 }}
+
+ + +
{{ i18n.ts.launchApp }}
+
@@ -177,8 +181,14 @@ function allDone() { transform: translateX(-50px); } -.qr { +.qrRoot { + display: block; + margin: 0 auto; width: 200px; max-width: 100%; } + +.qr { + width: 100%; +} From b96d9c6973b1c861306fdb9f51256cee5325a2b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=8B=E3=81=A3=E3=81=93=E3=81=8B=E3=82=8A?= <67428053+kakkokari-gtyih@users.noreply.github.com> Date: Sat, 30 Mar 2024 16:02:03 +0900 Subject: [PATCH 37/87] =?UTF-8?q?fix/enhance(frontend):=20=E6=98=A0?= =?UTF-8?q?=E5=83=8F=E3=83=BB=E9=9F=B3=E5=A3=B0=E5=91=A8=E3=82=8A=E3=81=AE?= =?UTF-8?q?=E6=94=B9=E4=BF=AE=20(#13206)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * enhance(frontend): 映像・音声周りの改修 * fix * fix design * fix lint * キーボードショートカットを整備 * Update Changelog * fix * feat: ループ再生 * ネイティブの動作と同期されるように * Update Changelog * key指定を消す --- CHANGELOG.md | 3 + locales/index.d.ts | 18 +++ locales/ja-JP.yml | 7 + .../frontend/src/components/MkMediaAudio.vue | 112 ++++++++++++++- .../frontend/src/components/MkMediaVideo.vue | 131 +++++++++++++++++- packages/frontend/src/components/MkMenu.vue | 91 +++++++++++- .../src/components/MkSwitch.button.vue | 13 +- .../frontend/src/pages/settings/general.vue | 2 + packages/frontend/src/scripts/keycode.ts | 1 + packages/frontend/src/store.ts | 4 + packages/frontend/src/types/menu.ts | 10 +- 11 files changed, 373 insertions(+), 19 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5963549cc6..ebf9320129 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -19,6 +19,9 @@ - Enhance: ページのデザインを変更 - Enhance: 2要素認証(ワンタイムパスワード)の入力欄を改善 - Enhance: 「今日誕生日のフォロー中ユーザー」ウィジェットを手動でリロードできるように +- Enhance: 映像・音声の再生にブラウザのネイティブプレイヤーを使用できるように +- Enhance: 映像・音声の再生メニューに「再生速度」「ループ再生」「ピクチャインピクチャ」を追加 +- Enhance: 映像・音声の再生にキーボードショートカットが使えるように - Fix: 一部のページ内リンクが正しく動作しない問題を修正 - Fix: 周年の実績が閏年を考慮しない問題を修正 - Fix: ローカルURLのプレビューポップアップが左上に表示される diff --git a/locales/index.d.ts b/locales/index.d.ts index 428cf9135c..3dbe46c7b2 100644 --- a/locales/index.d.ts +++ b/locales/index.d.ts @@ -4932,6 +4932,10 @@ export interface Locale extends ILocale { * アプリを起動 */ "launchApp": string; + /** + * 動画・音声の再生にブラウザのUIを使用する + */ + "useNativeUIForVideoAudioPlayer": string; "_bubbleGame": { /** * 遊び方 @@ -9834,6 +9838,20 @@ export interface Locale extends ILocale { */ "summaryProxyDescription2": string; }; + "_mediaControls": { + /** + * ピクチャインピクチャ + */ + "pip": string; + /** + * 再生速度 + */ + "playbackRate": string; + /** + * ループ再生 + */ + "loop": string; + }; } declare const locales: { [lang: string]: Locale; diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index 9e76e420c3..aa765d1310 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -1229,6 +1229,7 @@ notUsePleaseLeaveBlank: "使用しない場合は空欄にしてください" useTotp: "ワンタイムパスワードを使う" useBackupCode: "バックアップコードを使う" launchApp: "アプリを起動" +useNativeUIForVideoAudioPlayer: "動画・音声の再生にブラウザのUIを使用する" _bubbleGame: howToPlay: "遊び方" @@ -2619,3 +2620,9 @@ _urlPreviewSetting: summaryProxy: "プレビューを生成するプロキシのエンドポイント" summaryProxyDescription: "Misskey本体ではなく、サマリープロキシを使用してプレビューを生成します。" summaryProxyDescription2: "プロキシには下記パラメータがクエリ文字列として連携されます。プロキシ側がこれらをサポートしない場合、設定値は無視されます。" + +_mediaControls: + pip: "ピクチャインピクチャ" + playbackRate: "再生速度" + loop: "ループ再生" + \ No newline at end of file diff --git a/packages/frontend/src/components/MkMediaAudio.vue b/packages/frontend/src/components/MkMediaAudio.vue index 96c9b9fd66..5d2edf467e 100644 --- a/packages/frontend/src/components/MkMediaAudio.vue +++ b/packages/frontend/src/components/MkMediaAudio.vue @@ -5,11 +5,15 @@ SPDX-License-Identifier: AGPL-3.0-only