From 87d0f56dc75cdc5e29cef7a3cd41f41a998f9649 Mon Sep 17 00:00:00 2001 From: tamaina Date: Mon, 6 Mar 2023 01:17:13 +0000 Subject: [PATCH 1/5] =?UTF-8?q?fix=20correctFilename=20ext=E3=81=8C.?= =?UTF-8?q?=E3=81=8B=E3=82=89=E5=A7=8B=E3=81=BE=E3=82=8B=E5=A0=B4=E5=90=88?= =?UTF-8?q?=E3=82=82=E8=80=83=E6=85=AE=E3=81=99=E3=82=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/backend/src/misc/correct-filename.ts | 2 +- packages/backend/test/unit/misc/others.ts | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/backend/src/misc/correct-filename.ts b/packages/backend/src/misc/correct-filename.ts index 8dcce6df75..3357d8c1bd 100644 --- a/packages/backend/src/misc/correct-filename.ts +++ b/packages/backend/src/misc/correct-filename.ts @@ -1,7 +1,7 @@ // 与えられた拡張子とファイル名が一致しているかどうかを確認し、 // 一致していない場合は拡張子を付与して返す export function correctFilename(filename: string, ext: string | null) { - const dotExt = ext ? `.${ext}` : '.unknown'; + const dotExt = ext ? ext.startsWith('.') ? ext : `.${ext}` : '.unknown'; if (filename.endsWith(dotExt)) { return filename; } diff --git a/packages/backend/test/unit/misc/others.ts b/packages/backend/test/unit/misc/others.ts index 8241d3078d..c476aef33b 100644 --- a/packages/backend/test/unit/misc/others.ts +++ b/packages/backend/test/unit/misc/others.ts @@ -21,6 +21,9 @@ describe('misc:correct-filename', () => { test('with same ext', () => { expect(correctFilename('filename.jpg', 'jpg')).toBe('filename.jpg'); }); + test('.ext', () => { + expect(correctFilename('filename.jpg', '.jpg')).toBe('filename.jpg'); + }); test('with different ext', () => { expect(correctFilename('filename.webp', 'jpg')).toBe('filename.webp.jpg'); }); From 6bb11492fa3c8de2189085541eb36f9268587320 Mon Sep 17 00:00:00 2001 From: tamaina Date: Mon, 6 Mar 2023 01:31:44 +0000 Subject: [PATCH 2/5] update CHANGELOG.md --- CHANGELOG.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e0db634aab..543d1a8aa9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,10 +10,11 @@ x You should also include the user name that made the change. --> -## 13.9.2 (2023/03/05) +## 13.9.2 (2023/03/06) ### Improvements - クリップ、チャンネルページに共有ボタンを追加 +- チャンネルでタイムライン上部に投稿フォームを表示するかどうかのオプションを追加 - ドライブの「URLからアップロード」で、content-dispositionのfilenameがあればそれをファイル名に - Identiconがローカルとリモートで同じになるように - これまでのIdenticonは異なる画像になります From b719f6cd1c57dad42ccd13539d1f860f0db0be31 Mon Sep 17 00:00:00 2001 From: syuilo Date: Mon, 6 Mar 2023 10:32:36 +0900 Subject: [PATCH 3/5] New Crowdin updates (#10223) * New translations ja-JP.yml (Thai) * New translations ja-JP.yml (Chinese Simplified) * New translations ja-JP.yml (Italian) * New translations ja-JP.yml (Italian) --- locales/it-IT.yml | 3 +++ locales/th-TH.yml | 1 + locales/zh-CN.yml | 4 ++++ 3 files changed, 8 insertions(+) diff --git a/locales/it-IT.yml b/locales/it-IT.yml index ca1702585b..d5638aeb62 100644 --- a/locales/it-IT.yml +++ b/locales/it-IT.yml @@ -506,6 +506,7 @@ objectStorageSetPublicRead: "Imposta \"visibilità pubblica\" al momento di cari serverLogs: "Log del server" deleteAll: "Cancella cronologia" showFixedPostForm: "Visualizzare la finestra di pubblicazione in cima alla timeline" +showFixedPostFormInChannel: "Per i canali, mostra il modulo di pubblicazione in cima alla timeline" newNoteRecived: "Vedi le nuove note" sounds: "Impostazioni suoni" sound: "Impostazioni suoni" @@ -955,7 +956,9 @@ exploreOtherServers: "Trova altre istanze" letsLookAtTimeline: "Sbircia la timeline" disableFederationWarn: "Disabilita la federazione. Questo cambiamento non rende le pubblicazioni private. Di solito non è necessario abilitare questa opzione." invitationRequiredToRegister: "L'accesso a questo nodo è solo ad invito. Devi inserire un codice d'invito valido. Puoi richiedere un codice all'amministratore." +emailNotSupported: "L'istanza non supporta l'invio di email" postToTheChannel: "Pubblica sul canale" +cannotBeChangedLater: "Non sarà più modificabile" _achievements: earnedAt: "Data di conseguimento" _types: diff --git a/locales/th-TH.yml b/locales/th-TH.yml index 4511f1a40f..cf33e6642b 100644 --- a/locales/th-TH.yml +++ b/locales/th-TH.yml @@ -958,6 +958,7 @@ disableFederationWarn: "การดำเนินการนี้ถ้า invitationRequiredToRegister: "อินสแตนซ์นี้เป็นแบบรับเชิญเท่านั้น คุณต้องป้อนรหัสเชิญที่ถูกต้องถึงจะลงทะเบียนได้นะค่ะ" emailNotSupported: "อินสแตนซ์นี้ไม่รองรับการส่งอีเมลนะค่ะ" postToTheChannel: "โพสต์ลงช่อง" +cannotBeChangedLater: "สิ่งนี้ไม่สามารถเปลี่ยนแปลงได้ในภายหลังนะ" _achievements: earnedAt: "ได้รับเมื่อ" _types: diff --git a/locales/zh-CN.yml b/locales/zh-CN.yml index c1dd2a5daa..7798582db8 100644 --- a/locales/zh-CN.yml +++ b/locales/zh-CN.yml @@ -506,6 +506,7 @@ objectStorageSetPublicRead: "上传时设置为public-read" serverLogs: "服务器日志" deleteAll: "全部删除" showFixedPostForm: "在时间线顶部显示发帖框" +showFixedPostFormInChannel: "在时间线顶部显示发帖对话框(频道)" newNoteRecived: "有新的帖子" sounds: "提示音" sound: "提示音" @@ -955,6 +956,9 @@ exploreOtherServers: "探索其他服务器" letsLookAtTimeline: "时间线" disableFederationWarn: "联合被禁用。 禁用它并不能使帖子变成私人的。 在大多数情况下,这个选项不需要被启用。" invitationRequiredToRegister: "此服务器目前只允许拥有邀请码的人注册。" +emailNotSupported: "此服务器不支持发送邮件" +postToTheChannel: "发布到频道" +cannotBeChangedLater: "之后不能再更改。" _achievements: earnedAt: "达成时间" _types: From 6778111891a2810be42f1b83a1b119ff00795a55 Mon Sep 17 00:00:00 2001 From: tamaina Date: Mon, 6 Mar 2023 02:04:53 +0000 Subject: [PATCH 4/5] update CHANGELOG.md --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 543d1a8aa9..424eeaf00f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,7 @@ You should also include the user name that made the change. ### Improvements - クリップ、チャンネルページに共有ボタンを追加 - チャンネルでタイムライン上部に投稿フォームを表示するかどうかのオプションを追加 +- ブラウザでメディアプロキシ(/proxy)からファイルを保存した際に、なるべくオリジナルのファイル名を継承するように - ドライブの「URLからアップロード」で、content-dispositionのfilenameがあればそれをファイル名に - Identiconがローカルとリモートで同じになるように - これまでのIdenticonは異なる画像になります From 7852815fc3e6f617d947b40fa9ecc18e11f612ec Mon Sep 17 00:00:00 2001 From: tamaina Date: Mon, 6 Mar 2023 02:08:06 +0000 Subject: [PATCH 5/5] update CHANGELOG.md --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 424eeaf00f..30264e75e6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -24,6 +24,7 @@ You should also include the user name that made the change. ### Bugfixes - ロールの権限で「一般ユーザー」のロールがいきなり設定できない問題を修正 - ユーザーページのバッジ表示を適切に折り返すように @arrow2nd +- macOSでDev Containerが動作しない問題を修正 @RyotaK ## 13.9.1 (2023/03/03)