Compare commits

...

6 Commits

Author SHA1 Message Date
tamaina b6790a4320 chore: update pnpm to 8.6.10 2023-07-27 03:23:47 +00:00
woxtu cb0fa9a8ab
Use promises API (#11351) 2023-07-27 09:04:19 +09:00
猫ロキP@deflis 5083458071
refactor: forkでデフォルトのノート文字数を変更した場合、E2Eテストが落ちる問題を修正する (#11366)
* forkでデフォルトのノート文字数を変更した場合このテストが落ちる問題を修正する

* 文字数についてのコメントを追加しておく
2023-07-27 09:00:48 +09:00
setaria 78b502bcab
URL取得変数を関数に変更 #11392 (#11393) 2023-07-27 09:00:22 +09:00
syuilo 324d18983a
New Crowdin updates (#11389)
* New translations ja-JP.yml (French)

* New translations ja-JP.yml (English)

* New translations ja-JP.yml (Uzbek)

* New translations ja-JP.yml (Uzbek)

* New translations ja-JP.yml (Indonesian)

* New translations ja-JP.yml (Uzbek)

* New translations ja-JP.yml (Hungarian)

* New translations ja-JP.yml (Italian)

* New translations ja-JP.yml (Hungarian)

* New translations ja-JP.yml (Uzbek)

* New translations ja-JP.yml (Uzbek)

* New translations ja-JP.yml (Portuguese)
2023-07-27 08:57:34 +09:00
kabo2468 71b016b293
fix: PhotoSwipeによるクライアントのメモリリークの解消 (#11395)
* Destroy PhotoSwipe on unmounted

* Update CHANGELOG.md
2023-07-27 06:44:16 +09:00
15 changed files with 272 additions and 58 deletions

View File

@ -16,9 +16,11 @@
### Client ### Client
- リストTLで、ユーザーが追加・削除されてもTLを初期化しないように - リストTLで、ユーザーが追加・削除されてもTLを初期化しないように
- URL取得変数を関数に変更 CURRENT_URL -> Mk:url()
- Fix: モバイル表示のときページ下部がナビゲーションバーに隠れる問題を修正 - Fix: モバイル表示のときページ下部がナビゲーションバーに隠れる問題を修正
- Fix: 一部モーダルダイアログでスクロールできない問題を修正 - Fix: 一部モーダルダイアログでスクロールできない問題を修正
- Fix: Selecting all emojis in Custom emoji is impossible - Fix: Selecting all emojis in Custom emoji is impossible
- Fix: PhotoSwipeによるメモリリークの修正
### Server ### Server
- Fix: APIのオフセットが壊れていたせいで「もっと見る」でもっと見れない問題を修正 - Fix: APIのオフセットが壊れていたせいで「もっと見る」でもっと見れない問題を修正

View File

@ -1042,7 +1042,7 @@ vertical: "Vertical"
horizontal: "Horizontal" horizontal: "Horizontal"
position: "Position" position: "Position"
serverRules: "Server rules" serverRules: "Server rules"
pleaseConfirmBelowBeforeSignup: "Please confirm the below before signing up." pleaseConfirmBelowBeforeSignup: "To register on this server, you must review and agree to the following:"
pleaseAgreeAllToContinue: "You must agree to all above fields to continue." pleaseAgreeAllToContinue: "You must agree to all above fields to continue."
continue: "Continue" continue: "Continue"
preservedUsernames: "Reserved usernames" preservedUsernames: "Reserved usernames"
@ -1999,7 +1999,7 @@ _deck:
introduction: "Create the perfect interface for you by arranging columns freely!" introduction: "Create the perfect interface for you by arranging columns freely!"
introduction2: "Click on the + on the right of the screen to add new colums whenever you want." introduction2: "Click on the + on the right of the screen to add new colums whenever you want."
widgetsIntroduction: "Please select \"Edit widgets\" in the column menu and add a widget." widgetsIntroduction: "Please select \"Edit widgets\" in the column menu and add a widget."
useSimpleUiForNonRootPages: "Use simple UI for navigated pages" useSimpleUiForNonRootPages: "Use simplified UI to navigated pages"
_columns: _columns:
main: "Main" main: "Main"
widgets: "Widgets" widgets: "Widgets"

View File

@ -83,7 +83,7 @@ noLists: "Vous navez aucune liste"
note: "Note" note: "Note"
notes: "Notes" notes: "Notes"
following: "Abonnements" following: "Abonnements"
followers: "Abonné·e·s" followers: "Abonnés"
followsYou: "Vous suit" followsYou: "Vous suit"
createList: "Créer une liste" createList: "Créer une liste"
manageLists: "Gérer les listes" manageLists: "Gérer les listes"
@ -122,7 +122,7 @@ reaction: "Réactions"
reactions: "Réactions" reactions: "Réactions"
reactionSetting: "Réactions à afficher dans le sélecteur de réactions" reactionSetting: "Réactions à afficher dans le sélecteur de réactions"
reactionSettingDescription2: "Déplacer pour réorganiser, cliquer pour effacer, utiliser « + » pour ajouter." reactionSettingDescription2: "Déplacer pour réorganiser, cliquer pour effacer, utiliser « + » pour ajouter."
rememberNoteVisibility: "Activer l'option \" se souvenir de la visibilité des notes \" vous permet de réutiliser automatiquement la visibilité utilisée lors de la publication de votre note précédente." rememberNoteVisibility: "Se souvenir de la visibilité des notes"
attachCancel: "Supprimer le fichier attaché" attachCancel: "Supprimer le fichier attaché"
markAsSensitive: "Marquer comme sensible" markAsSensitive: "Marquer comme sensible"
unmarkAsSensitive: "Supprimer le marquage comme sensible" unmarkAsSensitive: "Supprimer le marquage comme sensible"

View File

@ -1 +1,103 @@
--- ---
_lang_: "Japán"
monthAndDay: "{month}.{day}."
search: "Keresés"
notifications: "Értesítések"
username: "Felhasználónév"
password: "Jelszó"
forgotPassword: "Elfelejtett jelszó"
ok: "OK"
gotIt: "Rendben"
cancel: "Mégse"
noThankYou: "Nem, köszönöm"
enterUsername: "Felhasználónév megadása"
renotedBy: "{user} Renotolta"
noNotes: "Nincs Note"
noNotifications: "Nincs értesítés"
instance: "Szerver"
settings: "Beállítások"
notificationSettings: "Értesítés beállításai"
basicSettings: "Alapbeállítás"
otherSettings: "Egyéb beállítások"
openInWindow: "Megnyitás ablakban"
profile: "Saját profil"
timeline: "Idővonal"
noAccountDescription: "Nincs leírás"
login: "Bejelentkezés"
loggingIn: "Belépés"
logout: "Kijelentkezés"
signup: "Regisztráció"
uploading: "Feltöltés"
save: "Mentés"
users: "Felhasználók"
addUser: "Felhasználó hozzáadása"
favorite: "Kedvencek"
favorites: "Kedvencek"
unfavorite: "Törlés a kedvencek közül."
favorited: "Kedvencek közé rakva."
alreadyFavorited: "Már a kedvencek között van."
cantFavorite: "Nem sikerült a kedvencek közé rakni."
pin: "Rögzítés"
unpin: "Rögzítés feloldása"
copyContent: "Tartalom másolása"
copyLink: "Hivatkozás Másolása"
delete: "Törlés"
deleteAndEdit: "Törlés és szerkesztés"
deleteAndEditConfirm: "Biztosan törlöd ezt a jegyzetet és újrafogalmazza? Így eveszíted az összes reakciót, renote-ot és választ."
addToList: "Hozzáadás a listákhoz"
privacy: "Adatvédelem"
makeFollowManuallyApprove: "Csak jóváhagyással követhetnek"
defaultNoteVisibility: "Alapértelmezett láthatóság"
follow: "Követés"
followRequest: "Követés kérése"
followRequests: "Követési kérések"
unfollow: "Követés visszavonása"
followRequestPending: "Függőben levő követési kérés"
enterEmoji: "Írj egy emoji-t"
renote: "Renote"
unrenote: "Renote visszavonása"
renoted: "Renotolva"
cantRenote: "Nem lehet Renotolni"
cantReRenote: "A Renote nem renotálható"
quote: "Idézet"
inChannelRenote: "Csak csatornán bellüli Renote"
inChannelQuote: "Csak csatornán bellüli idézet"
pinnedNote: "Csatolt jegyzet"
pinned: "Rögzítés"
you: "Te"
clickToShow: "Kattints ide"
sensitive: "Érzékeny"
add: "Hozzáad"
reaction: "Reakciók"
reactions: "Reakciók"
instances: "Szerver"
remove: "Törlés"
pinnedNotes: "Csatolt jegyzet"
smtpUser: "Felhasználónév"
smtpPass: "Jelszó"
user: "Felhasználók"
searchByGoogle: "Keresés"
_theme:
keys:
renote: "Renote"
_sfx:
notification: "Értesítések"
_2fa:
renewTOTPCancel: "Nem, köszönöm"
_widgets:
profile: "Saját profil"
notifications: "Értesítések"
timeline: "Idővonal"
_profile:
username: "Felhasználónév"
_notification:
_types:
renote: "Renote"
quote: "Idézet"
reaction: "Reakciók"
_actions:
renote: "Renote"
_deck:
_columns:
notifications: "Értesítések"
tl: "Idővonal"

View File

@ -49,11 +49,15 @@ delete: "Hapus"
deleteAndEdit: "Hapus dan sunting" deleteAndEdit: "Hapus dan sunting"
deleteAndEditConfirm: "Apakah kamu yakin ingin menghapus note ini dan menyuntingnya? Kamu akan kehilangan semua reaksi, renote dan balasan di note ini." deleteAndEditConfirm: "Apakah kamu yakin ingin menghapus note ini dan menyuntingnya? Kamu akan kehilangan semua reaksi, renote dan balasan di note ini."
addToList: "Tambahkan ke daftar" addToList: "Tambahkan ke daftar"
addToAntenna: "Tambahkan ke Antena"
sendMessage: "Kirim pesan" sendMessage: "Kirim pesan"
copyRSS: "Salin RSS" copyRSS: "Salin RSS"
copyUsername: "Salin nama pengguna" copyUsername: "Salin nama pengguna"
copyUserId: "Salin ID pengguna" copyUserId: "Salin ID pengguna"
copyNoteId: "Salin ID catatan" copyNoteId: "Salin ID catatan"
copyFileId: "Salin Berkas"
copyFolderId: "Salin Folder"
copyProfileUrl: "Salin Alamat Web Profil"
searchUser: "Cari pengguna" searchUser: "Cari pengguna"
reply: "Balas" reply: "Balas"
loadMore: "Selebihnya" loadMore: "Selebihnya"
@ -313,6 +317,7 @@ copyUrl: "Salin tautan"
rename: "Ubah nama" rename: "Ubah nama"
avatar: "Avatar" avatar: "Avatar"
banner: "Banner" banner: "Banner"
displayOfSensitiveMedia: "Tampilkan media NSFW"
whenServerDisconnected: "Ketika kehilangan koneksi dengan peladen" whenServerDisconnected: "Ketika kehilangan koneksi dengan peladen"
disconnectedFromServer: "Terputus koneksi dari peladen" disconnectedFromServer: "Terputus koneksi dari peladen"
reload: "Muat ulang" reload: "Muat ulang"
@ -1066,6 +1071,11 @@ installed: "Terpasang"
branding: "Merek" branding: "Merek"
enableServerMachineStats: "Tampilkan informasi mesin peladen menjadi publik" enableServerMachineStats: "Tampilkan informasi mesin peladen menjadi publik"
enableIdenticonGeneration: "Nyalakan pembuatan Identicon per pengguna" enableIdenticonGeneration: "Nyalakan pembuatan Identicon per pengguna"
turnOffToImprovePerformance: "Matikan untuk tingkatkan performa."
createInviteCode: "Buat kode undangan"
inviteCodeCreated: "Kode undangan dibuat"
inviteLimitExceeded: "Kamu telah mencapai jumlah maksimum kode undangan yang dapat dibuat."
expirationDate: "Tanggal kedaluwarsa"
_initialAccountSetting: _initialAccountSetting:
accountCreated: "Akun kamu telah sukses dibuat!" accountCreated: "Akun kamu telah sukses dibuat!"
letsStartAccountSetup: "Untuk pemula, ayo atur profilmu dulu." letsStartAccountSetup: "Untuk pemula, ayo atur profilmu dulu."

View File

@ -621,10 +621,10 @@ smtpHost: "Server remoto"
smtpPort: "Porta" smtpPort: "Porta"
smtpUser: "Nome utente" smtpUser: "Nome utente"
smtpPass: "Password" smtpPass: "Password"
emptyToDisableSmtpAuth: "Lasciare il nome utente e la password vuoti per disabilitare la verifica SMTP" emptyToDisableSmtpAuth: "Lasciare i campi vuoti se non c'è autenticazione SMTP"
smtpSecure: "Usare la porta SSL/TLS implicito per le connessioni SMTP" smtpSecure: "Usare SSL/TLS implicito per le connessioni SMTP"
smtpSecureInfo: "Disabilitare quando è attivo STARTTLS." smtpSecureInfo: "Disabilitare quando è attivo STARTTLS."
testEmail: "Testa la consegna di posta elettronica" testEmail: "Verifica il funzionamento"
wordMute: "Filtri parole" wordMute: "Filtri parole"
regexpError: "errore regex" regexpError: "errore regex"
regexpErrorDescription: "Si è verificato un errore nell'espressione regolare alla riga {line} della parola muta {tab}:" regexpErrorDescription: "Si è verificato un errore nell'espressione regolare alla riga {line} della parola muta {tab}:"
@ -1091,6 +1091,9 @@ usedAt: "Usato alle"
unused: "Inutilizzato" unused: "Inutilizzato"
used: "Utilizzato" used: "Utilizzato"
expired: "Scaduto" expired: "Scaduto"
doYouAgree: "Sei d'accordo?"
beSureToReadThisAsItIsImportant: "Si prega di leggere attentamente perché è importante."
iHaveReadXCarefullyAndAgree: "Ho letto accuratamente \"{x}\" e sono d'accordo."
_initialAccountSetting: _initialAccountSetting:
accountCreated: "Il tuo profilo è stato creato!" accountCreated: "Il tuo profilo è stato creato!"
letsStartAccountSetup: "Per iniziare, impostiamo il tuo profilo." letsStartAccountSetup: "Per iniziare, impostiamo il tuo profilo."
@ -1444,7 +1447,7 @@ _sensitiveMediaDetection:
_emailUnavailable: _emailUnavailable:
used: "Email già in uso" used: "Email già in uso"
format: "Formato email non valido" format: "Formato email non valido"
disposable: "Email non riutilizzabile" disposable: "Indirizzo email non utilizzabile"
mx: "Server email non corretto" mx: "Server email non corretto"
smtp: "Il server email non risponde" smtp: "Il server email non risponde"
_ffVisibility: _ffVisibility:

View File

@ -713,6 +713,8 @@ pageLikedCount: "Número de curtidas recebidas nas suas páginas"
contact: "Contato" contact: "Contato"
useSystemFont: "Utilizar a fonte padrão do sistema" useSystemFont: "Utilizar a fonte padrão do sistema"
clips: "Clipe" clips: "Clipe"
experimentalFeatures: "Funcionalidades Experimentais"
experimental: "Experimental"
duplicate: "Duplicar" duplicate: "Duplicar"
left: "Esquerda" left: "Esquerda"
wide: "Largo" wide: "Largo"

View File

@ -1,7 +1,7 @@
--- ---
_lang_: "O'zbek tili" _lang_: "O'zbek tili"
headlineMisskey: "Qaydlar tarmog'i" headlineMisskey: "Qaydlar tarmog'i"
introMisskey: "Xush kelibsiz! Misskey ochiq kodli, markazlashmagan mikroblogging xizmati.\nO'zingizni fikrlaringizni atrofingizdagilar bilan ulashish uchun \"Qaydlar\" yarating. 📡\nUstiga-ustak, \"Reaktsiyalar\" yordamida siz boshqalarning xatlari haqidagi o'zingizni xissiyotlaringizni tez ravishda bildiring. 👍\nQani, yangi dunyoni kashf qilaylik! 🚀" introMisskey: "Xush kelibsiz! Misskey ochiq kodli, markazlashmagan mikroblogging xizmati.\nO'zingizni fikrlaringizni atrofingizdagilar bilan ulashish uchun \"Qaydlar\" yarating. 📡\nUstiga-ustak, \"Reaktsiyalar\" yordamida siz boshqalarning xatlari haqidagi o'zingizni xissiyotlaringizni bildiring. 👍\nQani, yangi dunyoni kashf qilaylik! 🚀"
poweredByMisskeyDescription: "{name} ochiq manbali <b>Misskey</b>(\"Misskey instance\" deb ataladi) platformasi tomonidan qurilgan servislardan biri. " poweredByMisskeyDescription: "{name} ochiq manbali <b>Misskey</b>(\"Misskey instance\" deb ataladi) platformasi tomonidan qurilgan servislardan biri. "
monthAndDay: "{day}/{month}" monthAndDay: "{day}/{month}"
search: "Izlash" search: "Izlash"
@ -17,10 +17,10 @@ noThankYou: "Hozir emas"
enterUsername: "Foydalanuvchini nomini kiriting" enterUsername: "Foydalanuvchini nomini kiriting"
renotedBy: "{user} tomonidan qayta qayd etildi" renotedBy: "{user} tomonidan qayta qayd etildi"
noNotes: "Qaydlar mavjud emas" noNotes: "Qaydlar mavjud emas"
noNotifications: "Xabarnomalar mavjud emas" noNotifications: "Xabarlar mavjud emas"
instance: "Server" instance: "Server"
settings: "Sozalamalar" settings: "Sozlamalar"
notificationSettings: "Xabarnomalar sozlamalari" notificationSettings: "Xabarnoma sozlamalari"
basicSettings: "Asosiy sozlamalar" basicSettings: "Asosiy sozlamalar"
otherSettings: "Qoshimcha sozlamalar" otherSettings: "Qoshimcha sozlamalar"
openInWindow: "Yangi oynada ochish" openInWindow: "Yangi oynada ochish"
@ -36,18 +36,18 @@ save: "Saqlash"
users: "Foydalanuvchilar" users: "Foydalanuvchilar"
addUser: "Foydalanuvchi qo'shish" addUser: "Foydalanuvchi qo'shish"
favorite: "Sevimli" favorite: "Sevimli"
favorites: "Sevimli" favorites: "Sevimlilar"
unfavorite: "Sevimlidan chiqarish" unfavorite: "Sevimlidan chiqarish"
favorited: "sevimli" favorited: "sevimli"
alreadyFavorited: "allaqachon sevimlilar orasida" alreadyFavorited: "allaqachon sevimlilar orasida"
cantFavorite: "sevimlilarga qo'shib bo'lmadi" cantFavorite: "sevimlilarga qo'shib bo'lmadi"
pin: "Profilga qadab qo'yish" pin: "Profilga qadab qo'yish"
unpin: "Profildan olib tashlash" unpin: "Profildan olib tashlash"
copyContent: "Tarkibini nusxalash" copyContent: "kontentni nusxalash"
copyLink: "Havolani nuxalash" copyLink: "Havolani nuxalash"
delete: "O'chirib tashlash" delete: "O'chirib tashlash"
deleteAndEdit: "O'chirish va tahrirlash" deleteAndEdit: "O'chirish va tahrirlash"
deleteAndEditConfirm: "O'chirib, tahrirlamoqchiligingizga ishonchingiz komilmi? Siz bu qaydga tegishli barcha reaktsiyalar, qayta qaydlar va javoblarni yo'qotasiz." deleteAndEditConfirm: "O'chirib, tahrirlamoqchiligingizga ishonchingiz komilmi? Siz bu qaydga tegishli barcha reaktsiyalar va javoblarni yo'qotasiz."
addToList: "Royxatga qoshish" addToList: "Royxatga qoshish"
addToAntenna: "Antennaga qo'shish" addToAntenna: "Antennaga qo'shish"
sendMessage: "Xabar yuborish" sendMessage: "Xabar yuborish"
@ -74,7 +74,7 @@ import: "Import"
export: "Eksport" export: "Eksport"
files: "Fayllar" files: "Fayllar"
download: "Yuklab olish" download: "Yuklab olish"
driveFileDeleteConfirm: "\"{name}\" o'chirib tashlamoqchimisiz? Buni ishlatadihan kontentni hammasidan o'chadi" driveFileDeleteConfirm: "\"{name}\" o'chirib tashlamoqchimisiz? Ushbu fayldan foydalanadigan har qanday kontent ham oʻchiriladi."
unfollowConfirm: "{name}ga obunani bekor qilmoqchimisiz?" unfollowConfirm: "{name}ga obunani bekor qilmoqchimisiz?"
exportRequested: "Eksport so'raldi. Bu ozgina vaqt olishi mumkin. Tugatilgandan so'ng sizning Diskingizga qo'shiladi" exportRequested: "Eksport so'raldi. Bu ozgina vaqt olishi mumkin. Tugatilgandan so'ng sizning Diskingizga qo'shiladi"
importRequested: "Import so'raldi. Bu ozgina vaqt olishi mumkin." importRequested: "Import so'raldi. Bu ozgina vaqt olishi mumkin."
@ -91,7 +91,7 @@ error: "Xato"
somethingHappened: "Xatolik yuz berdi" somethingHappened: "Xatolik yuz berdi"
retry: "Qayta urinib ko'rish" retry: "Qayta urinib ko'rish"
pageLoadError: "Sahifani yuklayotganda xatolik yuz berdi" pageLoadError: "Sahifani yuklayotganda xatolik yuz berdi"
pageLoadErrorDescription: "Buni odatda tarmoq muammolari yoki browser keshi keltirib chiqaradi. Keshni tozalab, keyinroq urinib ko'ring" pageLoadErrorDescription: "Buni odatda tarmoq muammolarni yoki browser keshi keltirib chiqaradi. Keshni tozalab, keyinroq urinib ko'ring"
serverIsDead: "Server javob bermayabdi. Iltimos kuting va keyinroq urinib ko'ring" serverIsDead: "Server javob bermayabdi. Iltimos kuting va keyinroq urinib ko'ring"
youShouldUpgradeClient: "Iltimos, ushbu sahifani ko'rish uchun sahifani yangilang." youShouldUpgradeClient: "Iltimos, ushbu sahifani ko'rish uchun sahifani yangilang."
enterListName: "Ro'yxatga nom kiriting" enterListName: "Ro'yxatga nom kiriting"
@ -101,18 +101,18 @@ defaultNoteVisibility: "Standart ko'rinish"
follow: "Obuna bolish" follow: "Obuna bolish"
followRequest: "Obuna bo'lish uchun ruxsat olish" followRequest: "Obuna bo'lish uchun ruxsat olish"
followRequests: "Obuna bo'lmoqchilar" followRequests: "Obuna bo'lmoqchilar"
unfollow: "obunani bker qilish" unfollow: "obunani bekor qilish"
followRequestPending: "obuna bo'lishga ruxsat kutilmoqda" followRequestPending: "obuna bo'lishga ruxsat kutilmoqda"
enterEmoji: "Emojini kiriting" enterEmoji: "Emojini kiriting"
renote: "Qayta qaydetish" renote: "Qayta qayd etish"
unrenote: "Qayta qayd etishni bekor qilish" unrenote: "Qayta qayd etishni bekor qilish"
renoted: "Qayta qaydetildi" renoted: "Qayta qayd etildi"
cantRenote: "Qyta qayd etish mumkin emas" cantRenote: "Qayta qayd etish mumkin emas"
cantReRenote: "Repostni qayta joylashtirish mumkin emas." cantReRenote: "Repostni qayta joylashtirish mumkin emas."
quote: "Iqtibos keltirish" quote: "Iqtibos keltirish"
inChannelRenote: "Faqat kanalga qayta qayd etish" inChannelRenote: "Faqat kanalga qayta qayd etish"
inChannelQuote: "Kanaldagi eslatmalar" inChannelQuote: "Kanaldagi eslatmalar"
pinnedNote: "Qadanlgan qayd" pinnedNote: "Qadalgan qayd"
pinned: "Profilga qadab qo'yish" pinned: "Profilga qadab qo'yish"
you: "Siz" you: "Siz"
clickToShow: "Ko'rsatish uchun bosing" clickToShow: "Ko'rsatish uchun bosing"
@ -120,7 +120,7 @@ sensitive: "Sezuvchan"
add: "Qo'shish" add: "Qo'shish"
reaction: "Reaktsiyalar" reaction: "Reaktsiyalar"
reactions: "Reaktsiyalar" reactions: "Reaktsiyalar"
reactionSetting: "Reaksiyalar ro'yxatingiz " reactionSetting: "Reaksiyalar ro'yxati"
reactionSettingDescription2: "Qayta tartiblash uchun ushlab turib siljiting, oʻchirish uchun bosing, qoʻshish uchun “+” tugmasini bosing." reactionSettingDescription2: "Qayta tartiblash uchun ushlab turib siljiting, oʻchirish uchun bosing, qoʻshish uchun “+” tugmasini bosing."
rememberNoteVisibility: "Qaydning ko'rinish sozlamarini eslab qolish" rememberNoteVisibility: "Qaydning ko'rinish sozlamarini eslab qolish"
attachCancel: "Qo'shimchani olib tashlash" attachCancel: "Qo'shimchani olib tashlash"
@ -159,10 +159,10 @@ cacheRemoteFilesDescription: "Ushbu sozlama o'chirilgan bo'lsa tashqi fayllar be
cacheRemoteSensitiveFiles: "Tashqi fayllarni keshlash" cacheRemoteSensitiveFiles: "Tashqi fayllarni keshlash"
cacheRemoteSensitiveFilesDescription: "Bu sozlama oʻchiq boʻlsa, \"barcha ko'rishi mumkin bo'lmagan\" fayllar keshlashsiz toʻgʻridan-toʻgʻri masofaviy serverdan yuklanadi." cacheRemoteSensitiveFilesDescription: "Bu sozlama oʻchiq boʻlsa, \"barcha ko'rishi mumkin bo'lmagan\" fayllar keshlashsiz toʻgʻridan-toʻgʻri masofaviy serverdan yuklanadi."
flagAsBot: "Ushbu akkauntni bot sifatida belgilash" flagAsBot: "Ushbu akkauntni bot sifatida belgilash"
flagAsBotDescription: "Agar bu akkaunt bot tomonidan boshqaralayotgan bo'ls, bu sozlamani yoqing. Sozlama yoqilganda, boshqa foydalanuvchilar uchun belgi sifatida ishlaydi, va Misskey ichki tizimlari bu akkauntni bot ekanini biladi." flagAsBotDescription: "Agar bu akkaunt bot tomonidan boshqaralayotgan bo'lsa, bu sozlamani yoqing. Sozlama yoqilganda, boshqa foydalanuvchilar uchun belgi sifatida ishlaydi, va Misskey ichki tizimlari bu akkauntni bot ekanini biladi."
flagAsCat: "Bu akkauntni mushuk sifatida belgilash" flagAsCat: "Bu akkauntni mushuk sifatida belgilash"
flagAsCatDescription: "Ushbu akkauntni mushuk sifatida belgilash uchun ushbu sozlamani yoqing." flagAsCatDescription: "Ushbu akkauntni mushuk sifatida belgilash uchun ushbu sozlamani yoqing."
flagShowTimelineReplies: "Javbolarni xronogoliya bo'yicha ko'rsatish" flagShowTimelineReplies: "Javoblarni xronogoliya bo'yicha ko'rsatish"
flagShowTimelineRepliesDescription: "Bu parametr yoqilganda, lentada foydalanuvchi xabarlariga javob berilgan xabarlar ham ko'rinadi" flagShowTimelineRepliesDescription: "Bu parametr yoqilganda, lentada foydalanuvchi xabarlariga javob berilgan xabarlar ham ko'rinadi"
autoAcceptFollowed: "Obunachilarni avtomatik ravishda qabul qilish" autoAcceptFollowed: "Obunachilarni avtomatik ravishda qabul qilish"
addAccount: "Akkaunt qo'shish" addAccount: "Akkaunt qo'shish"
@ -177,6 +177,7 @@ searchWith: "Izlash: {q}"
youHaveNoLists: "Sizda hech qanday ro'yxatlar mavjud emas" youHaveNoLists: "Sizda hech qanday ro'yxatlar mavjud emas"
followConfirm: "{name} ga obuna bo'lmoqchimisiz?" followConfirm: "{name} ga obuna bo'lmoqchimisiz?"
proxyAccount: "Proksi hisob" proxyAccount: "Proksi hisob"
proxyAccountDescription: "Proksi-hisob qaydnomasi - bu ma'lum shartlar ostida foydalanuvchi uchun masofaviy kuzatuvchi sifatida ishlaydigan hisob. Misol uchun, foydalanuvchi uzoq foydalanuvchini roʻyxatga qoʻyganda, roʻyxatdagi foydalanuvchini hech kim kuzatib turmasa, faoliyat serverga yetkazilmaydi, shuning uchun biz proksi hisobi ularning oʻrniga ularni kuzatishini xohlaymiz."
host: "Host" host: "Host"
selectUser: "Foydalanuvchini tanlang" selectUser: "Foydalanuvchini tanlang"
recipient: "Qabul qiluvchi" recipient: "Qabul qiluvchi"
@ -206,8 +207,11 @@ instanceInfo: "Instans haqida ma'lumot"
statistics: "Statistika" statistics: "Statistika"
clearQueue: "Navbatni tozalash" clearQueue: "Navbatni tozalash"
clearQueueConfirmTitle: "Navbatni tozalamoqchimisiz?" clearQueueConfirmTitle: "Navbatni tozalamoqchimisiz?"
clearQueueConfirmText: "Yetkazib berilmagan xabarlar yetkazilmaydi. Odatda buni qilish shart emas."
clearCachedFiles: "Keshni tozalash" clearCachedFiles: "Keshni tozalash"
clearCachedFilesConfirm: "Barcha keshlangan masofaviy fayllar oʻchirilsinmi?"
blockedInstances: "Bloklangan serverlar" blockedInstances: "Bloklangan serverlar"
blockedInstancesDescription: "Bloklanmoqchi bo'lgan serverlaringiz hostlarini yangi qatorlar bilan ajrating. Bloklangan server bu server bilan ozaro aloqada bolmaydi. Subdomenlar ham bloklangan."
muteAndBlock: "Ovozsiz va Bloklangan" muteAndBlock: "Ovozsiz va Bloklangan"
mutedUsers: "Ovozsiz foydalanuvchilar" mutedUsers: "Ovozsiz foydalanuvchilar"
blockedUsers: "Bloklangan foydalanuvchilar" blockedUsers: "Bloklangan foydalanuvchilar"
@ -223,12 +227,16 @@ default: "Odatiy"
defaultValueIs: "Sukut bo'yicha: {value}" defaultValueIs: "Sukut bo'yicha: {value}"
noCustomEmojis: "Emojilar mavjud emas" noCustomEmojis: "Emojilar mavjud emas"
noJobs: "Vazifalar yo'q" noJobs: "Vazifalar yo'q"
federating: "Ittifoqdosh"
blocked: "Bloklangan" blocked: "Bloklangan"
suspended: "To'xtatilgan" suspended: "To'xtatilgan"
all: "Barcha" all: "Barcha"
subscribing: "Obuna bo'lish" subscribing: "Obuna bo'lish"
publishing: "Yuborilmoqda" publishing: "Yuborilmoqda"
notResponding: "Javob bermayapti" notResponding: "Javob bermayapti"
instanceFollowing: "server obuna bo'ladi"
instanceFollowers: "server obunachisi"
instanceUsers: "server foydalanuvchisi"
changePassword: "Parolni ozgartirish" changePassword: "Parolni ozgartirish"
security: "Xavfsizlik" security: "Xavfsizlik"
retypedNotMatch: "Maydonlar mos kelmayapti" retypedNotMatch: "Maydonlar mos kelmayapti"
@ -237,6 +245,7 @@ newPassword: "Yangi parol"
newPasswordRetype: "Yangi parolni boshqatdan tering" newPasswordRetype: "Yangi parolni boshqatdan tering"
attachFile: "Fayl biriktirish" attachFile: "Fayl biriktirish"
more: "Ko'proq!" more: "Ko'proq!"
featured: "ta'kidlash"
noSuchUser: "Foydalanuvchi topilmadi" noSuchUser: "Foydalanuvchi topilmadi"
lookup: "So'rov" lookup: "So'rov"
announcements: "Bildirishnomalar" announcements: "Bildirishnomalar"
@ -250,9 +259,13 @@ saved: "Saqlandi"
messaging: "Suhbat" messaging: "Suhbat"
upload: "Yuklash" upload: "Yuklash"
keepOriginalUploading: "Asl rasmni saqlang" keepOriginalUploading: "Asl rasmni saqlang"
fromUrl: "URL dan"
uploadFromUrlDescription: "Yuklamoqchi bo'lgan faylingizga havola" uploadFromUrlDescription: "Yuklamoqchi bo'lgan faylingizga havola"
uploadFromUrlRequested: "yuklab olish so'ralgan"
uploadFromUrlMayTakeTime: "Yuklash tugallanishi uchun biroz vaqt ketishi mumkin."
explore: "Ko'rib chiqish" explore: "Ko'rib chiqish"
messageRead: "Oqildi" messageRead: "Oqildi"
noMoreHistory: "Buning ortida hech qanday hikoya yo'q"
startMessaging: "Yangi suhbatni boshlash" startMessaging: "Yangi suhbatni boshlash"
nUsersRead: "{n} tomonidan o'qildi" nUsersRead: "{n} tomonidan o'qildi"
agreeTo: "Men {0} ga roziman" agreeTo: "Men {0} ga roziman"
@ -276,6 +289,7 @@ light: "Yorug'"
dark: "Qorongʻi" dark: "Qorongʻi"
lightThemes: "Yorug rang sxemasi" lightThemes: "Yorug rang sxemasi"
darkThemes: "Qorong'i rang sxemasi" darkThemes: "Qorong'i rang sxemasi"
syncDeviceDarkMode: "Qurilmangizning qorongi rejimi bilan sinxronlashtiring"
drive: "Disk" drive: "Disk"
fileName: "Fayl nomi" fileName: "Fayl nomi"
selectFile: "Faylni tanlang" selectFile: "Faylni tanlang"
@ -292,11 +306,14 @@ emptyDrive: "Diskingiz bo'sh"
emptyFolder: "Ushbu papka bo'sh" emptyFolder: "Ushbu papka bo'sh"
unableToDelete: "O'chirilmadi" unableToDelete: "O'chirilmadi"
inputNewFileName: "Yangi fayl nomini kiriting" inputNewFileName: "Yangi fayl nomini kiriting"
inputNewDescription: "Iltimos, yangi sarlavha kiriting."
inputNewFolderName: "Yangi papka nomini kiriting" inputNewFolderName: "Yangi papka nomini kiriting"
hasChildFilesOrFolders: "Bu papka boʻsh emas va uni oʻchirib boʻlmaydi."
copyUrl: "Bog'lamadan nusxa olish" copyUrl: "Bog'lamadan nusxa olish"
rename: "Qayta nomlash" rename: "Qayta nomlash"
avatar: "Avatar" avatar: "Avatar"
banner: "Banner" banner: "Banner"
whenServerDisconnected: "server bilan aloqa uzilganda"
disconnectedFromServer: "Server bilan ulanish uzulib qoldi" disconnectedFromServer: "Server bilan ulanish uzulib qoldi"
reload: "Yangilash" reload: "Yangilash"
doNothing: "E'tiborsiz qoldirish" doNothing: "E'tiborsiz qoldirish"
@ -327,10 +344,12 @@ registration: "Ro'yxatdan o'tish"
enableRegistration: "Ro'yxatdan o'tishni yoqing" enableRegistration: "Ro'yxatdan o'tishni yoqing"
invite: "Taklif qilish" invite: "Taklif qilish"
inMb: "Megabaytlarda" inMb: "Megabaytlarda"
iconUrl: "Ikonkaning URL manzili (masalan: favicon)"
backgroundImageUrl: "Fon rasmi URL manzili"
basicInfo: "Asosiy ma'lumot" basicInfo: "Asosiy ma'lumot"
pinnedUsers: "Qadalgan foydalanuvchilar" pinnedUsers: "Qadalgan foydalanuvchilar"
pinnedPages: "Qadalgan Sahifalar" pinnedPages: "Qadalgan Sahifalar"
pinnedNotes: "Qadanlgan qayd" pinnedNotes: "Qadalgan qayd"
hcaptcha: "hCaptcha" hcaptcha: "hCaptcha"
enableHcaptcha: "hCaptchani yoqish" enableHcaptcha: "hCaptchani yoqish"
hcaptchaSiteKey: "Sayt kaliti" hcaptchaSiteKey: "Sayt kaliti"
@ -345,7 +364,12 @@ antennas: "Antennalar"
manageAntennas: "Antennalarni boshqarish" manageAntennas: "Antennalarni boshqarish"
name: "Ism" name: "Ism"
antennaSource: "Antenna manbai" antennaSource: "Antenna manbai"
antennaKeywords: "Kalit so'zni qabul qilish"
notifyAntenna: "Yangi qaydlar haqida menga xabar bering"
connectedTo: "Quyidagi akkountlarga ulangan"
silence: "Sukunat" silence: "Sukunat"
popularUsers: "Mashhur foydalanuvchilar."
recentlyRegisteredUsers: "Yaqinda ro'yxatdan o'tgan foydalanuvchilar"
exploreUsersCount: "{count} ta foydalanuvchi bor" exploreUsersCount: "{count} ta foydalanuvchi bor"
popularTags: "Ommabop teglar" popularTags: "Ommabop teglar"
userList: "Ro'yxatlar" userList: "Ro'yxatlar"
@ -357,20 +381,56 @@ token: "Tasdiqlash"
totp: "Autentifikatsiya ilovasi" totp: "Autentifikatsiya ilovasi"
totpDescription: "Bir martalik parollarni kiritish uchun autentifikatsiya ilovasidan foydalaning" totpDescription: "Bir martalik parollarni kiritish uchun autentifikatsiya ilovasidan foydalaning"
moderator: "Moderator" moderator: "Moderator"
nUsersMentioned: "{n} tomonidan chop etilgan"
resetPassword: "Parolni tiklash" resetPassword: "Parolni tiklash"
share: "Yuborish" share: "Yuborish"
notFound: "Topilmadi" notFound: "Topilmadi"
uploadFolder: "Jildni yuklash" uploadFolder: "Jildni yuklash"
cacheClear: "Keshni tozalash" cacheClear: "Keshni tozalash"
markAsReadAllTalkMessages: "Barcha suhbatlarni o'qilgan deb belgilang"
help: "Yordam" help: "Yordam"
inputMessageHere: "Xabar kiriting" inputMessageHere: "Xabar kiriting"
close: "Yopish" close: "Yopish"
invites: "Taklif qilish" invites: "Taklif qilish"
members: "A'zolar" members: "A'zolar"
transfer: "topshiriq"
title: "Sarlavha" title: "Sarlavha"
text: "Matn" text: "Matn"
enable: "Yoqish" enable: "Yoqish"
next: "Keyingisi"
retype: "Qayta kiriting"
onlyOneFileCanBeAttached: "Faqat bitta faylni biriktirish mumkin"
signinRequired: "Davom etishdan oldin ro'yhatdan o'tishingiz yoki tizimga kirishingiz kerak"
invitations: "Taklif qilish" invitations: "Taklif qilish"
invitationCode: "taklif qilish kodi"
checking: "Tekshirilmoqda"
available: "Mavjud"
unavailable: "Mavjud emas"
usernameInvalidFormat: "Siz a~z, A~Z, 0~9, _ dan foydalanishingiz mumkin"
tooShort: "Juda qisqa"
tooLong: "juda uzun"
weakPassword: "Zaif parol"
normalPassword: "Oddiy parol"
strongPassword: "Kuchli parol"
passwordMatched: "Mos keldi"
passwordNotMatched: "mos kelmadi"
signinWith: "{x} bilan tizimga kirish"
signinFailed: "Tizimga kirishda xatolik yuz berdi. Iltimos, foydalanuvchi nomingiz va parolingizni tekshiring."
or: "yoki"
language: "til"
aboutX: "{x} haqida"
showNoteActionsOnlyHover: "Eslatma amallarini faqat sichqonchani olib borganda korsatish"
noHistory: "Tarix yo'q"
signinHistory: "kirish tarixi"
category: "kategoriya"
tags: "teg"
docSource: "Ushbu hujjatning manbasi"
createAccount: "Akkaunt yaratish"
existingAccount: "mavjud akkaunt"
regenerate: "regeneratsiya"
fontSize: "shrift hajmi"
limitTo: "{x} gacha"
noFollowRequests: "obuna uchun so'rov yo'q"
dashboard: "Boshqaruv paneli" dashboard: "Boshqaruv paneli"
local: "Mahalliy" local: "Mahalliy"
total: "Jami" total: "Jami"
@ -379,17 +439,46 @@ dayOverDayChanges: "Kecha bo'lgan o'zgarishlar"
appearance: "Tasgqi ko'rinish" appearance: "Tasgqi ko'rinish"
clientSettings: "Klient sozlamalari" clientSettings: "Klient sozlamalari"
accountSettings: "Profil sozlamalari" accountSettings: "Profil sozlamalari"
promotion: "rag'batlantirish"
promote: "targ'ib qilish"
numberOfDays: "kunlar soni"
hideThisNote: "bu eslatmani yashiring"
showFeaturedNotesInTimeline: "Tanlangan qaydlarni Timelineda ko'rsatish"
objectStorageBaseUrl: "Asosiy URL"
objectStorageRegion: "Mintaqa"
objectStorageUseSSL: "SSL dan foydalaning"
sounds: "Tovushlar" sounds: "Tovushlar"
sound: "ovoz" sound: "ovoz"
none: "Hechnima" none: "Hechnima"
volume: "Ovoz balandligi" volume: "Ovoz balandligi"
details: "Batafsil" details: "Batafsil"
output: "Chiqish" output: "Chiqish"
deleteAllFiles: "barcha fayllarni o'chirish"
deleteAllFilesConfirm: "Barcha fayllar oʻchirilsinmi?"
userSuspended: "Bu foydalanuvchi muzlatilgan."
yourAccountSuspendedTitle: "akkaunt muzlatilgan"
yourAccountSuspendedDescription: "Ushbu akkaunt serverning xizmat ko'rsatish shartlarini buzish kabi sabablarga ko'ra to'xtatilgan. Tafsilotlar uchun administratoringizga murojaat qiling. Iltimos, yangi akkaunt yaratmang."
tokenRevoked: "token yaroqsiz"
tokenRevokedDescription: "Kirish tokeningizni muddati tugagan. Iltimos, qaytadan kiring."
accountDeleted: "akkaunt o'chirildi"
accountDeletedDescription: "Bu akkaunt oʻchirildi."
menu: "Menyu" menu: "Menyu"
divider: "Ajratrmoq" divider: "Ajratrmoq"
addItem: "Element qo'shish" addItem: "Element qo'shish"
serviceworkerInfo: "bildirishnomalar uchun yoqilgan bo'lishi kerak."
deletedNote: "Oʻchirilgan post"
themeEditor: "Rang sxemasi muharriri" themeEditor: "Rang sxemasi muharriri"
describeFile: "sarlavha qo'shing"
enterFileDescription: "sarlavha kiriting"
author: "muallif"
leaveConfirm: "Sizda saqlanmagan oʻzgarishlar bor. Bekor qilinsinmi?"
useBlurEffectForModal: "Modal uchun xiralashtirish effektidan foydalaning"
width: "kengligi"
height: "balandligi"
large: "Katta"
small: "kichik"
enableAll: "Yoqish" enableAll: "Yoqish"
disableAll: "hammasini o'chirib qo'ying"
edit: "Tahrirlash" edit: "Tahrirlash"
email: "Email" email: "Email"
smtpHost: "Host" smtpHost: "Host"
@ -464,7 +553,7 @@ _theme:
navBg: "Yon panel foni" navBg: "Yon panel foni"
navFg: "Yon panel matni" navFg: "Yon panel matni"
mention: "Murojat" mention: "Murojat"
renote: "Qayta qaydetish" renote: "Qayta qayd etish"
divider: "Ajratrmoq" divider: "Ajratrmoq"
accentDarken: "Urg'u (Qoraytirilgan)" accentDarken: "Urg'u (Qoraytirilgan)"
accentLighten: "Urg'u (Yoritilgan)" accentLighten: "Urg'u (Yoritilgan)"
@ -473,6 +562,10 @@ _sfx:
note: "Qaydlar" note: "Qaydlar"
notification: "Xabarnomalar" notification: "Xabarnomalar"
chat: "Suhbat" chat: "Suhbat"
_ago:
minutesAgo: "{n} daqiqa oldin"
hoursAgo: "{n} soat oldin"
daysAgo: "{n} kun oldin"
_2fa: _2fa:
renewTOTPCancel: "Hozir emas" renewTOTPCancel: "Hozir emas"
_permissions: _permissions:
@ -606,7 +699,7 @@ _notification:
all: "Barchasi" all: "Barchasi"
follow: "Obuna bolish" follow: "Obuna bolish"
mention: "Murojat" mention: "Murojat"
renote: "Qayta qaydetish" renote: "Qayta qayd etish"
quote: "Iqtibos keltirish" quote: "Iqtibos keltirish"
reaction: "Reaktsiyalar" reaction: "Reaktsiyalar"
receiveFollowRequest: "Qabul qilingan kuzatuv so'rovlari" receiveFollowRequest: "Qabul qilingan kuzatuv so'rovlari"

View File

@ -6,7 +6,7 @@
"type": "git", "type": "git",
"url": "https://github.com/misskey-dev/misskey.git" "url": "https://github.com/misskey-dev/misskey.git"
}, },
"packageManager": "pnpm@8.6.9", "packageManager": "pnpm@8.6.10",
"workspaces": [ "workspaces": [
"packages/frontend", "packages/frontend",
"packages/backend", "packages/backend",

View File

@ -1,6 +1,5 @@
import * as fs from 'node:fs'; import * as fs from 'node:fs';
import * as stream from 'node:stream'; import * as stream from 'node:stream/promises';
import * as util from 'node:util';
import { Inject, Injectable } from '@nestjs/common'; import { Inject, Injectable } from '@nestjs/common';
import ipaddr from 'ipaddr.js'; import ipaddr from 'ipaddr.js';
import chalk from 'chalk'; import chalk from 'chalk';
@ -14,7 +13,6 @@ import { StatusError } from '@/misc/status-error.js';
import { LoggerService } from '@/core/LoggerService.js'; import { LoggerService } from '@/core/LoggerService.js';
import type Logger from '@/logger.js'; import type Logger from '@/logger.js';
const pipeline = util.promisify(stream.pipeline);
import { bindThis } from '@/decorators.js'; import { bindThis } from '@/decorators.js';
@Injectable() @Injectable()
@ -102,7 +100,7 @@ export class DownloadService {
}); });
try { try {
await pipeline(req, fs.createWriteStream(path)); await stream.pipeline(req, fs.createWriteStream(path));
} catch (e) { } catch (e) {
if (e instanceof Got.HTTPError) { if (e instanceof Got.HTTPError) {
throw new StatusError(`${e.response.statusCode} ${e.response.statusMessage}`, e.response.statusCode, e.response.statusMessage); throw new StatusError(`${e.response.statusCode} ${e.response.statusMessage}`, e.response.statusCode, e.response.statusMessage);
@ -129,7 +127,7 @@ export class DownloadService {
// write content at URL to temp file // write content at URL to temp file
await this.downloadUrl(url, path); await this.downloadUrl(url, path);
const text = await util.promisify(fs.readFile)(path, 'utf8'); const text = await fs.promises.readFile(path, 'utf8');
return text; return text;
} finally { } finally {

View File

@ -1,8 +1,7 @@
import * as fs from 'node:fs'; import * as fs from 'node:fs';
import * as crypto from 'node:crypto'; import * as crypto from 'node:crypto';
import { join } from 'node:path'; import { join } from 'node:path';
import * as stream from 'node:stream'; import * as stream from 'node:stream/promises';
import * as util from 'node:util';
import { Injectable } from '@nestjs/common'; import { Injectable } from '@nestjs/common';
import { FSWatcher } from 'chokidar'; import { FSWatcher } from 'chokidar';
import * as fileType from 'file-type'; import * as fileType from 'file-type';
@ -16,8 +15,6 @@ import { createTempDir } from '@/misc/create-temp.js';
import { AiService } from '@/core/AiService.js'; import { AiService } from '@/core/AiService.js';
import { bindThis } from '@/decorators.js'; import { bindThis } from '@/decorators.js';
const pipeline = util.promisify(stream.pipeline);
export type FileInfo = { export type FileInfo = {
size: number; size: number;
md5: string; md5: string;
@ -371,8 +368,7 @@ export class FileInfoService {
*/ */
@bindThis @bindThis
public async getFileSize(path: string): Promise<number> { public async getFileSize(path: string): Promise<number> {
const getStat = util.promisify(fs.stat); return (await fs.promises.stat(path)).size;
return (await getStat(path)).size;
} }
/** /**
@ -381,7 +377,7 @@ export class FileInfoService {
@bindThis @bindThis
private async calcHash(path: string): Promise<string> { private async calcHash(path: string): Promise<string> {
const hash = crypto.createHash('md5').setEncoding('hex'); const hash = crypto.createHash('md5').setEncoding('hex');
await pipeline(fs.createReadStream(path), hash); await stream.pipeline(fs.createReadStream(path), hash);
return hash.read(); return hash.read();
} }

View File

@ -1,7 +1,6 @@
import { randomUUID } from 'node:crypto'; import { randomUUID } from 'node:crypto';
import { pipeline } from 'node:stream';
import * as fs from 'node:fs'; import * as fs from 'node:fs';
import { promisify } from 'node:util'; import * as stream from 'node:stream/promises';
import { Inject, Injectable } from '@nestjs/common'; import { Inject, Injectable } from '@nestjs/common';
import { DI } from '@/di-symbols.js'; import { DI } from '@/di-symbols.js';
import { getIpHash } from '@/misc/get-ip-hash.js'; import { getIpHash } from '@/misc/get-ip-hash.js';
@ -21,8 +20,6 @@ import type { FastifyRequest, FastifyReply } from 'fastify';
import type { OnApplicationShutdown } from '@nestjs/common'; import type { OnApplicationShutdown } from '@nestjs/common';
import type { IEndpointMeta, IEndpoint } from './endpoints.js'; import type { IEndpointMeta, IEndpoint } from './endpoints.js';
const pump = promisify(pipeline);
const accessDenied = { const accessDenied = {
message: 'Access denied.', message: 'Access denied.',
code: 'ACCESS_DENIED', code: 'ACCESS_DENIED',
@ -138,7 +135,7 @@ export class ApiCallService implements OnApplicationShutdown {
} }
const [path] = await createTemp(); const [path] = await createTemp();
await pump(multipartData.file, fs.createWriteStream(path)); await stream.pipeline(multipartData.file, fs.createWriteStream(path));
const fields = {} as Record<string, unknown>; const fields = {} as Record<string, unknown>;
for (const [k, v] of Object.entries(multipartData.fields)) { for (const [k, v] of Object.entries(multipartData.fields)) {

View File

@ -5,6 +5,7 @@ import { Note } from '@/models/entities/Note.js';
import { signup, post, uploadUrl, startServer, initTestDb, api, uploadFile } from '../utils.js'; import { signup, post, uploadUrl, startServer, initTestDb, api, uploadFile } from '../utils.js';
import type { INestApplicationContext } from '@nestjs/common'; import type { INestApplicationContext } from '@nestjs/common';
import type * as misskey from 'misskey-js'; import type * as misskey from 'misskey-js';
import { MAX_NOTE_TEXT_LENGTH } from '@/const.js';
describe('Note', () => { describe('Note', () => {
let app: INestApplicationContext; let app: INestApplicationContext;
@ -164,7 +165,7 @@ describe('Note', () => {
test('文字数ぎりぎりで怒られない', async () => { test('文字数ぎりぎりで怒られない', async () => {
const post = { const post = {
text: '!'.repeat(3000), text: '!'.repeat(MAX_NOTE_TEXT_LENGTH), // 3000文字
}; };
const res = await api('/notes/create', post, alice); const res = await api('/notes/create', post, alice);
assert.strictEqual(res.status, 200); assert.strictEqual(res.status, 200);
@ -172,7 +173,7 @@ describe('Note', () => {
test('文字数オーバーで怒られる', async () => { test('文字数オーバーで怒られる', async () => {
const post = { const post = {
text: '!'.repeat(3001), text: '!'.repeat(MAX_NOTE_TEXT_LENGTH + 1), // 3001文字
}; };
const res = await api('/notes/create', post, alice); const res = await api('/notes/create', post, alice);
assert.strictEqual(res.status, 400); assert.strictEqual(res.status, 400);

View File

@ -58,7 +58,7 @@ async function getClientWidthWithCache(targetEl: HTMLElement, containerEl: HTMLE
</script> </script>
<script lang="ts" setup> <script lang="ts" setup>
import { onMounted, shallowRef } from 'vue'; import { onMounted, onUnmounted, shallowRef } from 'vue';
import * as misskey from 'misskey-js'; import * as misskey from 'misskey-js';
import PhotoSwipeLightbox from 'photoswipe/lightbox'; import PhotoSwipeLightbox from 'photoswipe/lightbox';
import PhotoSwipe from 'photoswipe'; import PhotoSwipe from 'photoswipe';
@ -82,12 +82,19 @@ const gallery = shallowRef<HTMLDivElement>();
const pswpZIndex = os.claimZIndex('middle'); const pswpZIndex = os.claimZIndex('middle');
document.documentElement.style.setProperty('--mk-pswp-root-z-index', pswpZIndex.toString()); document.documentElement.style.setProperty('--mk-pswp-root-z-index', pswpZIndex.toString());
const count = $computed(() => props.mediaList.filter(media => previewable(media)).length); const count = $computed(() => props.mediaList.filter(media => previewable(media)).length);
let lightbox: PhotoSwipeLightbox | null;
const popstateHandler = (): void => {
if (lightbox.pswp && lightbox.pswp.isOpen === true) {
lightbox.pswp.close();
}
};
/** /**
* アスペクト比をmediaListWithOneImageAppearanceに基づいていい感じに調整する * アスペクト比をmediaListWithOneImageAppearanceに基づいていい感じに調整する
* aspect-ratioではなくheightを使う * aspect-ratioではなくheightを使う
*/ */
async function calcAspectRatio() { async function calcAspectRatio() {
if (!gallery.value || !root.value) return; if (!gallery.value || !root.value) return;
let img = props.mediaList[0]; let img = props.mediaList[0];
@ -137,7 +144,7 @@ const count = $computed(() => props.mediaList.filter(media => previewable(media)
onMounted(() => { onMounted(() => {
calcAspectRatio(); calcAspectRatio();
const lightbox = new PhotoSwipeLightbox({ lightbox = new PhotoSwipeLightbox({
dataSource: props.mediaList dataSource: props.mediaList
.filter(media => { .filter(media => {
if (media.type === 'image/svg+xml') return true; // svgwebpublicpngtrue if (media.type === 'image/svg+xml') return true; // svgwebpublicpngtrue
@ -221,12 +228,7 @@ onMounted(() => {
lightbox.init(); lightbox.init();
window.addEventListener('popstate', () => { window.addEventListener('popstate', popstateHandler);
if (lightbox.pswp && lightbox.pswp.isOpen === true) {
lightbox.pswp.close();
return;
}
});
lightbox.on('beforeOpen', () => { lightbox.on('beforeOpen', () => {
history.pushState(null, '', '#pswp'); history.pushState(null, '', '#pswp');
@ -239,6 +241,12 @@ onMounted(() => {
}); });
}); });
onUnmounted(() => {
window.removeEventListener('popstate', popstateHandler);
lightbox?.destroy();
lightbox = null;
});
const previewable = (file: misskey.entities.DriveFile): boolean => { const previewable = (file: misskey.entities.DriveFile): boolean => {
if (file.type === 'image/svg+xml') return true; // svgwebpublic/thumbnailpngtrue if (file.type === 'image/svg+xml') return true; // svgwebpublic/thumbnailpngtrue
// FILE_TYPE_BROWSERSAFE // FILE_TYPE_BROWSERSAFE

View File

@ -11,7 +11,6 @@ export function createAiScriptEnv(opts) {
USER_NAME: $i ? values.STR($i.name) : values.NULL, USER_NAME: $i ? values.STR($i.name) : values.NULL,
USER_USERNAME: $i ? values.STR($i.username) : values.NULL, USER_USERNAME: $i ? values.STR($i.username) : values.NULL,
CUSTOM_EMOJIS: utils.jsToVal(customEmojis.value), CUSTOM_EMOJIS: utils.jsToVal(customEmojis.value),
CURRENT_URL: values.STR(window.location.href),
'Mk:dialog': values.FN_NATIVE(async ([title, text, type]) => { 'Mk:dialog': values.FN_NATIVE(async ([title, text, type]) => {
await os.alert({ await os.alert({
type: type ? type.value : 'info', type: type ? type.value : 'info',
@ -48,5 +47,8 @@ export function createAiScriptEnv(opts) {
utils.assertString(key); utils.assertString(key);
return utils.jsToVal(JSON.parse(miLocalStorage.getItem(`aiscript:${opts.storageKey}:${key.value}`))); return utils.jsToVal(JSON.parse(miLocalStorage.getItem(`aiscript:${opts.storageKey}:${key.value}`)));
}), }),
'Mk:url': values.FN_NATIVE(() => {
return values.STR(window.location.href);
}),
}; };
} }