From b938b0de45e382cf77c6f9ec7c83c3fc03b38253 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ot=C3=A1vio=20Stasiak?= <91474186+OtavioStasiak@users.noreply.github.com> Date: Wed, 8 Jan 2025 13:04:23 -0300 Subject: [PATCH] chore(a11y): CreateChannelView (#6014) Co-authored-by: OtavioStasiak --- app/i18n/locales/ar.json | 3 ++ app/i18n/locales/bn-IN.json | 5 ++- app/i18n/locales/cs.json | 5 ++- app/i18n/locales/de.json | 5 ++- app/i18n/locales/en.json | 5 ++- app/i18n/locales/es.json | 3 ++ app/i18n/locales/fi.json | 5 ++- app/i18n/locales/fr.json | 3 ++ app/i18n/locales/hi-IN.json | 5 ++- app/i18n/locales/hu.json | 5 ++- app/i18n/locales/it.json | 3 ++ app/i18n/locales/ja.json | 3 ++ app/i18n/locales/nl.json | 3 ++ app/i18n/locales/pt-BR.json | 5 ++- app/i18n/locales/pt-PT.json | 3 ++ app/i18n/locales/ru.json | 5 ++- app/i18n/locales/sl-SI.json | 3 ++ app/i18n/locales/sv.json | 5 ++- app/i18n/locales/ta-IN.json | 5 ++- app/i18n/locales/te-IN.json | 2 +- app/i18n/locales/tr.json | 3 ++ app/i18n/locales/zh-CN.json | 3 ++ app/i18n/locales/zh-TW.json | 3 ++ .../RoomSettings/SwitchItem.tsx | 39 ++++++++++--------- .../RoomSettings/SwitchItemEncrypted.test.tsx | 18 +-------- .../RoomSettings/SwitchItemEncrypted.tsx | 5 +-- .../RoomSettings/SwitchItemReadOnly.tsx | 7 +--- .../RoomSettings/SwitchItemType.tsx | 5 +-- .../CreateChannelView/RoomSettings/index.tsx | 26 ++++++++----- app/views/CreateChannelView/index.tsx | 6 ++- e2e/tests/team/01-createteam.spec.ts | 1 + 31 files changed, 115 insertions(+), 82 deletions(-) diff --git a/app/i18n/locales/ar.json b/app/i18n/locales/ar.json index 00a341af2b..1ef1436ce9 100644 --- a/app/i18n/locales/ar.json +++ b/app/i18n/locales/ar.json @@ -50,7 +50,9 @@ "Change_Language": "تغيير اللغة", "Change_language_loading": "تغيير اللغة", "changing_avatar": "تغيير الصورة الرمزية", + "Channel_hint_private": "لا يمكن للناس الانضمام إلا من خلال دعوتهم", "Channel_Name": "اسم القناة", + "Channel_Read_Only_Hint": "يمكن لمالكي القنوات فقط إرسال رسائل جديدة", "Channels": "قنوات", "Chat_closed_by_agent": "المندوب أغلق المحادثة", "Chats": "الرسائل", @@ -336,6 +338,7 @@ "Read_External_Permission": "صلاحية قراءة الوسائط", "Read_External_Permission_Message": "يحتاج Rocket.chat للوصول إلى الصور والملفات الموجودة على الجهاز", "Read_Only": "قراءة فقط", + "Read_only_hint": "يمكن لمالكي القنوات فقط إرسال رسائل جديدة", "Read_Receipt": "قراءة المستلم", "Receive_Group_Mentions": "تلقي إشارات المجموعة", "Receive_Group_Mentions_Info": "تلقي @all و @here للإشعارات", diff --git a/app/i18n/locales/bn-IN.json b/app/i18n/locales/bn-IN.json index f12a89f616..60a00caf57 100644 --- a/app/i18n/locales/bn-IN.json +++ b/app/i18n/locales/bn-IN.json @@ -94,9 +94,10 @@ "Channel_hint_encrypted": "শেষ হতে শেষ এনক্রিপ্টেড চ্যানেল। এনক্রিপ্টেড চ্যানেলে অনুসন্ধান কাজ করবে না এবং বিজ্ঞপ্তিগুলি বার্তা সামগ্রী প্রদর্শন করতে পারে না।", "Channel_hint_encrypted_not_available": "পাবলিক চ্যানেলের জন্য উপলব্ধ নয়", "Channel_hint_not_read_only": "চ্যানেলের সমস্ত ব্যবহারকারী নতুন বার্তা লেখতে পারবে", - "Channel_hint_private": "শোধার্থী ব্যবহারকারী এই চ্যানেলে অ্যাক্সেস পাওয়া যাবে", + "Channel_hint_private": "মানুষ কেবল আমন্ত্রণের মাধ্যমে যোগ দিতে পারে", "Channel_hint_public": "সবাই এই চ্যানেলে অ্যাক্সেস পাবে", "Channel_Name": "চ্যানেল নাম", + "Channel_Read_Only_Hint": "শুধুমাত্র চ্যানেলের মালিকরা নতুন বার্তা পাঠাতে পারেন", "Channels": "চ্যানেলগুলি", "Chat_closed_by_agent": "এজেন্ট দ্বারা চ্যাট বন্ধ করা হয়েছে", "Chat_is_on_hold": "এই চ্যাটটি অসক্রিয়তার কারণে হোল্ডে আছে", @@ -512,7 +513,7 @@ "Read_External_Permission": "মিডিয়া অনুমতি পড়া", "Read_External_Permission_Message": "Rocket.Chat আপনার ডিভাইসে ফটো, মিডিয়া এবং ফাইল অ্যাক্সেস করতে পারে", "Read_Only": "শুধুমাত্র পড়া", - "Read_only_hint": "শুধুমাত্র অনুমোদিত ব্যবহারকারীরা নতুন বার্তা লেখতে পারবে", + "Read_only_hint": "কেবল চ্যানেল মালিকরা নতুন বার্তা প্রেরণ করতে পারেন", "Read_Receipt": "পড়া স্বীকৃতি", "Receive_Group_Mentions": "গ্রুপ উল্লেখ প্রাপ্ত করুন", "Receive_Group_Mentions_Info": "@all এবং @here উল্লেখ প্রাপ্ত করুন", diff --git a/app/i18n/locales/cs.json b/app/i18n/locales/cs.json index 048c17581d..0251ba0546 100644 --- a/app/i18n/locales/cs.json +++ b/app/i18n/locales/cs.json @@ -100,9 +100,10 @@ "Channel_hint_encrypted": "End to end šifrovaný kanál. Vyhledávání nebude fungovat se šifrovanými kanály a oznámení nemusí zobrazovat obsah zpráv.", "Channel_hint_encrypted_not_available": "Není k dispozici pro veřejné kanály", "Channel_hint_not_read_only": "Všichni uživatelé v kanálu mohou psát nové zprávy", - "Channel_hint_private": "K tomuto kanálu mají přístup pouze pozvaní uživatelé", + "Channel_hint_private": "Lidé se mohou připojit pouze tím, že byli pozváni", "Channel_hint_public": "K tomuto kanálu má přístup každý", "Channel_Name": "Název kanálu", + "Channel_Read_Only_Hint": "Pouze majitelé kanálů mohou odesílat nové zprávy", "Channels": "Kanály", "Chat_closed_by_agent": "Chat uzavřen agentem", "Chat_is_on_hold": "Tento chat je pozastaven z důvodu nečinnosti", @@ -556,7 +557,7 @@ "Read_External_Permission": "Povolení ke čtení médií", "Read_External_Permission_Message": "Rocket.Chat potřebuje přístup k fotografiím, médiím a souborům ve vašem zařízení", "Read_Only": "Pouze ke čtení", - "Read_only_hint": "Pouze oprávnění uživatelé mohou psát nové zprávy", + "Read_only_hint": "Pouze majitelé kanálů mohou odesílat nové zprávy", "Read_Receipt": "Potvrzení o přečtení", "Receive_Group_Mentions": "Přijímat zmínky o skupině", "Receive_Group_Mentions_Info": "Přijímat @všechny a @zde zmínky", diff --git a/app/i18n/locales/de.json b/app/i18n/locales/de.json index ae953aa96b..130da2bd26 100644 --- a/app/i18n/locales/de.json +++ b/app/i18n/locales/de.json @@ -89,9 +89,10 @@ "Channel_hint_encrypted": "Ende-zu-Ende verschlüsselter Kanal. Die Suche funktioniert nicht mit verschlüsselten Channels. In Benachrichtigungen wird der Inhalt der Nachricht möglicherweise nicht angezeigt.", "Channel_hint_encrypted_not_available": "Nicht verfügbar in öffentlichen Kanälen", "Channel_hint_not_read_only": "Alle Nutzer im Kanal können neue Nachrichten schreiben", - "Channel_hint_private": "Nur eingeladene Nutzer können auf diesen Kanal zugreifen", + "Channel_hint_private": "Menschen können nur dann durch eingeladen werden", "Channel_hint_public": "Jeder kann auf diesen Kanal zugreifen", "Channel_Name": "Channel-Name", + "Channel_Read_Only_Hint": "Nur Kanalbesitzer können neue Nachrichten senden", "Channels": "Channels", "Chat_closed_by_agent": "Chat durch den Agenten geschlossen", "Chat_is_on_hold": "Dieser Chat ist aufgrund von Inaktivität in der Warteschleife", @@ -499,7 +500,7 @@ "Read_External_Permission": "Lese-Zugriff auf Medien", "Read_External_Permission_Message": "Rocket.Chat benötigt Zugriff auf Ihre Fotos, Medien und Dateien auf Ihrem Gerät", "Read_Only": "Schreibgeschützt", - "Read_only_hint": "Nur autorisierte Benutzer können neue Nachrichten schreiben", + "Read_only_hint": "Nur Kanalbesitzer können neue Nachrichten senden", "Read_Receipt": "Lesebestätigung", "Receive_Group_Mentions": "Gruppen-Benachrichtigungen erhalten", "Receive_Group_Mentions_Info": "@all- und @here-Erwähnungen empfangen", diff --git a/app/i18n/locales/en.json b/app/i18n/locales/en.json index cbf8d069eb..13032915b8 100644 --- a/app/i18n/locales/en.json +++ b/app/i18n/locales/en.json @@ -101,9 +101,10 @@ "Channel_hint_encrypted": "End to end encrypted channel. Search will not work with encrypted channels and notifications may not show the messages content.", "Channel_hint_encrypted_not_available": "Not available for public channels", "Channel_hint_not_read_only": "All users in the channel can write new messages", - "Channel_hint_private": "Only invited users can access this channel", + "Channel_hint_private": "People can only join by being invited", "Channel_hint_public": "Everyone can access this channel", "Channel_Name": "Channel name", + "Channel_Read_Only_Hint": "Only channel owners can send new messages", "Channels": "Channels", "Chat_closed_by_agent": "Chat closed by agent", "Chat_is_on_hold": "This chat is on hold due to inactivity", @@ -580,7 +581,7 @@ "Read_External_Permission": "Read media permission", "Read_External_Permission_Message": "Rocket.Chat needs to access photos, media, and files on your device", "Read_Only": "Read only", - "Read_only_hint": "Only authorized users can write new messages", + "Read_only_hint": "Only channel owners can send new messages", "Read_Receipt": "Read receipt", "Receive_Group_Mentions": "Receive group mentions", "Receive_Group_Mentions_Info": "Receive @all and @here mentions", diff --git a/app/i18n/locales/es.json b/app/i18n/locales/es.json index f470c6d6c5..aa797a1a1a 100644 --- a/app/i18n/locales/es.json +++ b/app/i18n/locales/es.json @@ -43,7 +43,9 @@ "Certificate_password": "Contraseña del certificado", "Change_Language": "Cambiar idioma", "changing_avatar": "cambiando avatar", + "Channel_hint_private": "La gente solo puede unirse al ser invitado", "Channel_Name": "Nombre sala", + "Channel_Read_Only_Hint": "Solo los propietarios de canales pueden enviar nuevos mensajes", "Channels": "Salas", "Chats": "Chats", "Choose": "Seleccionar", @@ -200,6 +202,7 @@ "Reactions_are_disabled": "Las reacciones están desactivadas", "Reactions_are_enabled": "Las reacciones están activadas", "Read_Only": "Sólo lectura ", + "Read_only_hint": "Solo los propietarios de canales pueden enviar nuevos mensajes", "Read_Receipt": "Comprobante de lectura", "Receive_Group_Mentions": "Recibir menciones de grupo", "Receive_Group_Mentions_Info": "Recibir menciones @all y @here", diff --git a/app/i18n/locales/fi.json b/app/i18n/locales/fi.json index 85e55a5b2e..b318f52a9a 100644 --- a/app/i18n/locales/fi.json +++ b/app/i18n/locales/fi.json @@ -79,9 +79,10 @@ "Channel_hint_encrypted": "Täysin salattu kanava. Haku ei toimi salatuilla kanavilla eikä viestien sisältö välttämättä näy ilmoituksissa.", "Channel_hint_encrypted_not_available": "Ei käytettävissä julkisilla kanavilla", "Channel_hint_not_read_only": "Kaikki kanavan käyttäjät voivat kirjoittaa uusia viestejä", - "Channel_hint_private": "Vain kutsutuilla käyttäjillä on pääsy tälle kanavalle", + "Channel_hint_private": "Ihmiset voivat liittyä vain kutsumalla", "Channel_hint_public": "Kaikilla on pääsy tälle kanavalle", "Channel_Name": "Kanavan nimi", + "Channel_Read_Only_Hint": "Vain kanavanomistajat voivat lähettää uusia viestejä", "Channels": "Kanavat", "Chat_closed_by_agent": "Agentti sulki keskustelun", "Chat_is_on_hold": "Tämä keskustelu on pidossa käyttämättömyyden vuoksi", @@ -474,7 +475,7 @@ "Read_External_Permission": "Median lukuoikeus", "Read_External_Permission_Message": "Rocket.Chat tarvitsee pääsyn laitteesi valokuviin, mediaan ja tiedostoihin", "Read_Only": "Vain luku", - "Read_only_hint": "Vain valtuutetut käyttäjät voivat kirjoittaa uusia viestejä", + "Read_only_hint": "Vain kanavanomistajat voivat lähettää uusia viestejä", "Read_Receipt": "Lukukuittaus", "Receive_Group_Mentions": "Vastaanota ryhmämainintoja", "Receive_Group_Mentions_Info": "Vastaanota @all- ja @here-maininnat", diff --git a/app/i18n/locales/fr.json b/app/i18n/locales/fr.json index 2371afb8e9..44bf597aa8 100644 --- a/app/i18n/locales/fr.json +++ b/app/i18n/locales/fr.json @@ -59,7 +59,9 @@ "Change_Language": "Changer la langue", "Change_language_loading": "Changement de la langue.", "changing_avatar": "changer d'avatar", + "Channel_hint_private": "Les gens ne peuvent se joindre qu'en étant invité", "Channel_Name": "Nom du canal", + "Channel_Read_Only_Hint": "Seuls les propriétaires de canaux peuvent envoyer de nouveaux messages", "Channels": "Canaux", "Chat_closed_by_agent": "Chat fermé par l'agent", "Chat_is_on_hold": "Ce chat est attente pour cause d'inactivité", @@ -433,6 +435,7 @@ "Read_External_Permission": "Permission de lecture des fichiers", "Read_External_Permission_Message": "Rocket.Chat doit accéder aux photos, aux médias et aux fichiers sur votre appareil", "Read_Only": "Lecture seule", + "Read_only_hint": "Seuls les propriétaires de canaux peuvent envoyer de nouveaux messages", "Read_Receipt": "Accusé de réception", "Receive_Group_Mentions": "Recevoir des mentions de groupe", "Receive_Group_Mentions_Info": "Recevoir des mentions @all et @here", diff --git a/app/i18n/locales/hi-IN.json b/app/i18n/locales/hi-IN.json index 324c7b373b..63f1cd376b 100644 --- a/app/i18n/locales/hi-IN.json +++ b/app/i18n/locales/hi-IN.json @@ -94,9 +94,10 @@ "Channel_hint_encrypted": "एंड टू एंड एन्क्रिप्टेड चैनल। एंक्रिप्शन चैनल के साथ खोज काम नहीं करेगा और सूचनाएं संदेश की सामग्री नहीं दिखा सकती हैं।", "Channel_hint_encrypted_not_available": "सार्वजनिक चैनलों के लिए उपलब्ध नहीं", "Channel_hint_not_read_only": "चैनल में सभी उपयोगकर्ताएं नए संदेश लिख सकती हैं", - "Channel_hint_private": "केवल आमंत्रित उपयोगकर्ता इस चैनल तक पहुँच सकते हैं", + "Channel_hint_private": "लोग केवल आमंत्रित किए जाने पर ही जुड़ सकते हैं", "Channel_hint_public": "हर कोई इस चैनल तक पहुँच सकता है", "Channel_Name": "चैनल का नाम", + "Channel_Read_Only_Hint": "केवल चैनल के मालिक नए संदेश भेज सकते हैं", "Channels": "चैनल्स", "Chat_closed_by_agent": "एजेंट ने चैट बंद कर दी है", "Chat_is_on_hold": "इस चैट को गतिहीनता के कारण होल्ड पर है", @@ -512,7 +513,7 @@ "Read_External_Permission": "मीडिया अनुमति पठन", "Read_External_Permission_Message": "रॉकेट.चैट को आपके डिवाइस पर फ़ोटो, मीडिया और फ़ाइल तक पहुंच की आवश्यकता है", "Read_Only": "केवल पठन", - "Read_only_hint": "केवल अधिकृत उपयोगकर्ताएं नए संदेश लिख सकती हैं", + "Read_only_hint": "केवल चैनल के मालिक केवल नए संदेश भेज सकते हैं", "Read_Receipt": "पठन प्राप्ति", "Receive_Group_Mentions": "समूह उल्लेख प्राप्त करें", "Receive_Group_Mentions_Info": "@all और @here उल्लेख प्राप्त करें", diff --git a/app/i18n/locales/hu.json b/app/i18n/locales/hu.json index d295ce6a79..9a75fca5c9 100644 --- a/app/i18n/locales/hu.json +++ b/app/i18n/locales/hu.json @@ -94,9 +94,10 @@ "Channel_hint_encrypted": "Végponttól végpontig titkosított csatorna. A keresés nem működik titkosított csatornákon, és az értesítések nem mutatják az üzenetek tartalmát.", "Channel_hint_encrypted_not_available": "Nem érhető el nyilvános csatornáknál", "Channel_hint_not_read_only": "A csatorna minden felhasználója írhat új üzeneteket", - "Channel_hint_private": "Csak a meghívott felhasználók férhetnek hozzá ehhez a csatornához", + "Channel_hint_private": "Az emberek csak meghívással csatlakozhatnak", "Channel_hint_public": "Mindenki hozzáférhet ehhez a csatornához", "Channel_Name": "Csatorna neve", + "Channel_Read_Only_Hint": "Csak a csatornatulajdonosok küldhetnek új üzeneteket", "Channels": "Csatornák", "Chat_closed_by_agent": "A csevegést az ügyintéző lezárta", "Chat_is_on_hold": "Ez a csevegés várakoztatva van inaktivitás miatt", @@ -513,7 +514,7 @@ "Read_External_Permission": "Médiaengedély olvasása", "Read_External_Permission_Message": "A Rocket.Chat-nek hozzá kell férnie a készülékén lévő fényképekhez, médiához és fájlokhoz", "Read_Only": "Csak olvasható", - "Read_only_hint": "Csak az engedélyezett felhasználók írhatnak új üzeneteket", + "Read_only_hint": "Csak a csatornatulajdonosok küldhetnek új üzeneteket", "Read_Receipt": "Olvassa el a nyugtát", "Receive_Group_Mentions": "Csoportos említések fogadása", "Receive_Group_Mentions_Info": "Az @all és @here említések fogadása", diff --git a/app/i18n/locales/it.json b/app/i18n/locales/it.json index 59eaba5a13..d339f769bd 100644 --- a/app/i18n/locales/it.json +++ b/app/i18n/locales/it.json @@ -55,7 +55,9 @@ "Change_Language": "Cambia lingua", "Change_language_loading": "Cambiando la lingua.", "changing_avatar": "cambio avatar", + "Channel_hint_private": "Le persone possono unirsi solo essendo invitati", "Channel_Name": "Nome canale", + "Channel_Read_Only_Hint": "Solo i proprietari di canali possono inviare nuovi messaggi", "Channels": "Canali", "Chat_closed_by_agent": "Chat chiusa dall'agente", "Chat_started": "Chat avviata", @@ -371,6 +373,7 @@ "Read_External_Permission": "Permesso di Lettura della Memoria", "Read_External_Permission_Message": "Rocket.Chat deve accedere alle foto, media, e documenti sul tuo dispositivo", "Read_Only": "Sola lettura", + "Read_only_hint": "Solo i proprietari di canali possono inviare nuovi messaggi", "Read_Receipt": "Conferma di lettura", "Receive_Group_Mentions": "Ricevi menzioni di gruppo", "Receive_Group_Mentions_Info": "Ricevi menzioni @all e @here", diff --git a/app/i18n/locales/ja.json b/app/i18n/locales/ja.json index 67e3833f29..03f525044d 100644 --- a/app/i18n/locales/ja.json +++ b/app/i18n/locales/ja.json @@ -49,7 +49,9 @@ "Change_Language": "言語を変更", "Change_language_loading": "言語の変更", "changing_avatar": "アバターを変更", + "Channel_hint_private": "人々は招待されることによってのみ参加することができます", "Channel_Name": "チャンネル名", + "Channel_Read_Only_Hint": "チャネル所有者のみが新しいメッセージを送信できます", "Channels": "チャンネル", "Chat_closed_by_agent": "エージェントが閉じたチャット", "Chats": "チャット", @@ -289,6 +291,7 @@ "Reactions_are_disabled": "リアクションは無効化されています", "Reactions_are_enabled": "リアクションは有効化されています", "Read_Only": "読み取り専用", + "Read_only_hint": "チャネル所有者のみが新しいメッセージを送信できます", "Read_Receipt": "レシートを見る", "Receive_Group_Mentions": "グループの通知を受け取る", "Receive_Group_Mentions_Info": "@all と @here の通知を受け取る", diff --git a/app/i18n/locales/nl.json b/app/i18n/locales/nl.json index f9d395c377..8e32140bee 100644 --- a/app/i18n/locales/nl.json +++ b/app/i18n/locales/nl.json @@ -59,7 +59,9 @@ "Change_Language": "Taal veranderen", "Change_language_loading": "Taal veranderen", "changing_avatar": "avatar aan het veranderen", + "Channel_hint_private": "Mensen kunnen alleen meedoen door uitgenodigd te worden", "Channel_Name": "Kanaal naam", + "Channel_Read_Only_Hint": "Alleen kanaaleigenaren kunnen nieuwe berichten verzenden", "Channels": "Kanalen", "Chat_closed_by_agent": "Chat gesloten door agent", "Chat_is_on_hold": "Deze chat staat in de wacht wegens inactiviteit", @@ -433,6 +435,7 @@ "Read_External_Permission": "Lees toestemming voor media", "Read_External_Permission_Message": "Rocket.Chat heeft toegang nodig tot foto's, media en bestanden op je apparaat", "Read_Only": "Alleen lezen", + "Read_only_hint": "Alleen kanaaleigenaren kunnen nieuwe berichten verzenden", "Read_Receipt": "Leesbevestiging", "Receive_Group_Mentions": "Groepsvermeldingen ontvangen", "Receive_Group_Mentions_Info": "Ontvang @all en @here vermeldingen", diff --git a/app/i18n/locales/pt-BR.json b/app/i18n/locales/pt-BR.json index eda5249a56..4acd6c77cd 100644 --- a/app/i18n/locales/pt-BR.json +++ b/app/i18n/locales/pt-BR.json @@ -99,9 +99,10 @@ "Channel_hint_encrypted": "Canal criptografado de ponta a ponta. A pesquisa não funcionará com canais criptografados e as notificações podem não mostrar o conteúdo das mensagens.", "Channel_hint_encrypted_not_available": "Indisponível para canais públicos", "Channel_hint_not_read_only": "Todos usuários no canal podem enviar mensagens novas", - "Channel_hint_private": "Apenas usuários convidados podem acessar este canal", + "Channel_hint_private": "As pessoas só podem entrar por meio de convite", "Channel_hint_public": "Todos podem acessar este canal", "Channel_Name": "Nome do canal", + "Channel_Read_Only_Hint": "Apenas os proprietários do canal podem enviar novas mensagens", "Channels": "Canais", "Chat_closed_by_agent": "Conversa fechada por agente", "Chat_is_on_hold": "Esta conversa está em espera devido à inatividade", @@ -565,7 +566,7 @@ "Read_External_Permission": "Permissão de acesso à arquivos", "Read_External_Permission_Message": "Rocket.Chat precisa acessar fotos, mídia e arquivos no seu dispositivo", "Read_Only": "Somente leitura", - "Read_only_hint": "Somente usuários autorizados podem escrever novas mensagens", + "Read_only_hint": "Somente os proprietários do canal podem enviar novas mensagens", "Read_Receipt": "Lida por", "Receive_Group_Mentions": "Receber menções de grupo", "Receive_Group_Mentions_Info": "Receber menções @all e @here", diff --git a/app/i18n/locales/pt-PT.json b/app/i18n/locales/pt-PT.json index cf8a59e888..71b1243345 100644 --- a/app/i18n/locales/pt-PT.json +++ b/app/i18n/locales/pt-PT.json @@ -47,7 +47,9 @@ "Certificate_password": "Senha do Certificado", "Change_language_loading": "Mudança de idioma.", "changing_avatar": "a alterar avatar", + "Channel_hint_private": "As pessoas só podem se juntar ao ser convidadas", "Channel_Name": "Nome do Canal", + "Channel_Read_Only_Hint": "Somente os proprietários de canais podem enviar novas mensagens", "Channels": "Canais", "Chat_closed_by_agent": "Chat fechado por agente", "Chats": "Chats", @@ -307,6 +309,7 @@ "Read_External_Permission": "Permissão de leitura da média", "Read_External_Permission_Message": "Rocket.Chat precisa acessar fotos, média e arquivos em seu dispositivo", "Read_Only": "Só de Leitura", + "Read_only_hint": "Somente os proprietários do canal podem enviar novas mensagens", "Read_Receipt": "Recibos de leitura", "Register": "Registar", "Remove_someone_from_room": "Remover alguém da sala", diff --git a/app/i18n/locales/ru.json b/app/i18n/locales/ru.json index 8a94cef348..40ae58fa22 100644 --- a/app/i18n/locales/ru.json +++ b/app/i18n/locales/ru.json @@ -75,9 +75,10 @@ "Channel_hint_encrypted": "Канал со сквозным шифрованием. Поиск не будет работать в зашифрованных каналах, а уведомления могут не отображать содержание сообщений.", "Channel_hint_encrypted_not_available": "Недоступно для публичных каналов", "Channel_hint_not_read_only": "Все пользователи канала могут писать новые сообщения", - "Channel_hint_private": "Только приглашенные пользователи могут получить доступ к этому каналу", + "Channel_hint_private": "Люди могут присоединиться только к приглашению", "Channel_hint_public": "У всех есть доступ к этому каналу", "Channel_Name": "Название канала", + "Channel_Read_Only_Hint": "Только владельцы каналов могут отправлять новые сообщения", "Channels": "Каналы", "Chat_closed_by_agent": "Чат закрыт агентом", "Chat_is_on_hold": "Этот чат находится в режиме удержания из-за неактивности", @@ -464,7 +465,7 @@ "Read_External_Permission": "Разрешение на Чтение Медиа", "Read_External_Permission_Message": "Rocket.Chat необходим доступ к фотографиям, медиа и другим файлам на вашем устройстве", "Read_Only": "Только для чтения", - "Read_only_hint": "Только авторизованные пользователи могут писать новые сообщения", + "Read_only_hint": "Только владельцы каналов могут отправлять новые сообщения", "Read_Receipt": "Уведомление о прочтении", "Receive_Group_Mentions": "Получать групповые уведомления", "Receive_Group_Mentions_Info": "Получать @all и @here уведомления", diff --git a/app/i18n/locales/sl-SI.json b/app/i18n/locales/sl-SI.json index 8ef2c1c9dc..fb241ee567 100644 --- a/app/i18n/locales/sl-SI.json +++ b/app/i18n/locales/sl-SI.json @@ -63,7 +63,9 @@ "Change_Language": "Spremeni jezik", "Change_language_loading": "Spreminjanje jezika.", "changing_avatar": "spreminjanje avatarja", + "Channel_hint_private": "Ljudje se lahko pridružijo samo z vabilom", "Channel_Name": "Ime kanala", + "Channel_Read_Only_Hint": "Samo lastniki kanala lahko pošiljajo nova sporočila", "Channels": "Kanali", "Chat_closed_by_agent": "Klepet je zaprl agent", "Chat_is_on_hold": "Ta klepet zaradi neaktivnosti ni na voljo", @@ -445,6 +447,7 @@ "Read_External_Permission": "Dovoljenje za branje medija", "Read_External_Permission_Message": "Rocket.Chat potrebuje dostop do fotografij, medijev in datotek v vaši napravi", "Read_Only": "Le branje", + "Read_only_hint": "Samo lastniki kanalov lahko pošljejo nova sporočila", "Read_Receipt": "Preberite potrdilo", "Receive_Group_Mentions": "Prejemajte omembe skupine", "Receive_Group_Mentions_Info": "Prejemate @all in @Here omembe", diff --git a/app/i18n/locales/sv.json b/app/i18n/locales/sv.json index 4a8192bfef..a95e37ff71 100644 --- a/app/i18n/locales/sv.json +++ b/app/i18n/locales/sv.json @@ -79,9 +79,10 @@ "Channel_hint_encrypted": "End-to-end-krypterad kanal. Sökfunktionen fungerar inte med krypterade kanaler och innehållet i meddelanden kanske inte visas.", "Channel_hint_encrypted_not_available": "Inte tillgängligt för offentliga kanaler", "Channel_hint_not_read_only": "Alla användare i kanalen kan skriva meddelanden", - "Channel_hint_private": "Endast inbjudna användare kan öppna kanalen", + "Channel_hint_private": "Människor kan bara gå med genom att bli inbjudna", "Channel_hint_public": "Alla kan öppna kanalen", "Channel_Name": "Kanalnamn", + "Channel_Read_Only_Hint": "Endast kanalägare kan skicka nya meddelanden", "Channels": "Kanaler", "Chat_closed_by_agent": "Chatten stängdes av agenten", "Chat_is_on_hold": "Den här chatten är parkerad på grund av inaktivitet", @@ -473,7 +474,7 @@ "Read_External_Permission": "Behörighet att läsa media", "Read_External_Permission_Message": "Rocket.Chat behöver åtkomst till foton, media och filer på enheten", "Read_Only": "Skrivskyddat", - "Read_only_hint": "Endast behöriga användare kan skriva nya meddelanden", + "Read_only_hint": "Endast kanalägare kan skicka nya meddelanden", "Read_Receipt": "Läskvitto", "Receive_Group_Mentions": "Ta emot gruppomnämnanden", "Receive_Group_Mentions_Info": "Ta emot omnämnanden av typen @all och @here", diff --git a/app/i18n/locales/ta-IN.json b/app/i18n/locales/ta-IN.json index 68242e1b12..564a82cc5b 100644 --- a/app/i18n/locales/ta-IN.json +++ b/app/i18n/locales/ta-IN.json @@ -94,9 +94,10 @@ "Channel_hint_encrypted": "இறுதியாக குழுவிகள் குழுவிகள் குறியாகிவிடப்பட்டுள்ளன. குறியீடுகளுடன் தேடல் செய்ய முடியாது மற்றும் அறிவிப்புகள் செய்தி உள்ளடக்கங்களைக் காட்டாது.", "Channel_hint_encrypted_not_available": "பொது சேனல்களுக்கு கிடைக்காது", "Channel_hint_not_read_only": "சேனலிலுள்ள அனைத்து பயனர்களும் புதிய செய்திகளை எழுதலாம்", - "Channel_hint_private": "அழைக்கப்பட்ட பயனர்கள் மட்டும் இந்த சேனலுக்கு அணுகலாம்", + "Channel_hint_private": "மக்கள் அழைப்பின் மூலம் மட்டும் சேர முடியும்", "Channel_hint_public": "அனைத்து பயனர்களும் இந்த சேனலுக்கு அணுகலாம்", "Channel_Name": "சேனலின் பெயர்", + "Channel_Read_Only_Hint": "சேனல் உரிமையாளர்கள் மட்டுமே புதிய செய்திகளை அனுப்ப முடியும்", "Channels": "சேனல்கள்", "Chat_closed_by_agent": "ஏஜென்ட் மூடிய உரையாடல்", "Chat_is_on_hold": "இந்த உரையாடல் செயலற்றது ஆகின்று உள்ளது", @@ -512,7 +513,7 @@ "Read_External_Permission": "மீடியா அனுமதி", "Read_External_Permission_Message": "ராக்கெட்.சேட் உங்கள் கருவியில் புகைப்படங்கள், மீடியா மற்றும் கோப்புகளுக்கு அணுகல் பெற விரும்புகின்றது", "Read_Only": "மட்டுமே படிக்க முடியும்", - "Read_only_hint": "அனுமதிக்கப்பட்ட பயனர்கள் மட்டும் புதிய செய்திகளை எழுதலாம்", + "Read_only_hint": "சேனல் உரிமையாளர்கள் மட்டுமே புதிய செய்திகளை அனுப்ப முடியும்", "Read_Receipt": "படித்த ரசீது", "Receive_Group_Mentions": "குழு குறிப்புகளைப் பெறு", "Receive_Group_Mentions_Info": "@all மற்றும் @here குறிப்புகளைப் பெறு", diff --git a/app/i18n/locales/te-IN.json b/app/i18n/locales/te-IN.json index 3b112edb1c..2a6a67e799 100644 --- a/app/i18n/locales/te-IN.json +++ b/app/i18n/locales/te-IN.json @@ -512,7 +512,7 @@ "Read_External_Permission": "మీడియా అనుమతి", "Read_External_Permission_Message": "రాకెట్.చాట్ మీ పరికరాల్లో ఫోటోలను, మీడియాను మరియు ఫైళ్లను ప్రవేశించాలి", "Read_Only": "కేవలం చదవడానికి", - "Read_only_hint": "కొనసాగించిన వాడాలు మాత్రమే కొత్త సందేశాలను రాయగలరు", + "Read_only_hint": "ఛానెల్ యజమానులు మాత్రమే క్రొత్త సందేశాలను పంపగలరు", "Read_Receipt": "చదవడానికి సాక్షాత్కారం", "Receive_Group_Mentions": "గ్రూప్ స్మరణలు స్వీకరించు", "Receive_Group_Mentions_Info": "@all మరియు @here స్మరణలు స్వీకరించు", diff --git a/app/i18n/locales/tr.json b/app/i18n/locales/tr.json index 59f29c5a16..4f333898b6 100644 --- a/app/i18n/locales/tr.json +++ b/app/i18n/locales/tr.json @@ -49,7 +49,9 @@ "Change_Language": "Dili değiştir", "Change_language_loading": "Dil değiştiriliyor", "changing_avatar": "profil fotoğrafı değiştirme", + "Channel_hint_private": "İnsanlar sadece davet edilerek katılabilir", "Channel_Name": "Kanal Adı", + "Channel_Read_Only_Hint": "Yalnızca kanal sahipleri yeni mesajlar gönderebilir", "Channels": "Kanallar", "Chat_closed_by_agent": "Sohbet temsilci tarafından kapatıldı", "Chats": "Sohbetler", @@ -354,6 +356,7 @@ "Read_External_Permission": "Medya Okuma İzni ", "Read_External_Permission_Message": "Rocket.Chat'in cihazınızdaki fotoğraflara, medyaya ve dosyalara erişmesi gerekiyor", "Read_Only": "Yazma Kısıtlı", + "Read_only_hint": "Yalnızca kanal sahipleri yeni mesajlar gönderebilir", "Read_Receipt": "Okundu Bilgisi", "Receive_Group_Mentions": "Grup Bahsetmelerini Al", "Receive_Group_Mentions_Info": "Grup bahsetmelerini al", diff --git a/app/i18n/locales/zh-CN.json b/app/i18n/locales/zh-CN.json index 3a0ac18fe7..5f60924648 100644 --- a/app/i18n/locales/zh-CN.json +++ b/app/i18n/locales/zh-CN.json @@ -49,7 +49,9 @@ "Change_Language": "切换语言", "Change_language_loading": "切换语言", "changing_avatar": "更改头像", + "Channel_hint_private": "人们只能被邀请加入", "Channel_Name": "频道名", + "Channel_Read_Only_Hint": "只有频道所有者可以发送新消息", "Channels": "频道", "Chat_closed_by_agent": "聊天已被客服关闭", "Chats": "聊天", @@ -337,6 +339,7 @@ "Read_External_Permission": "读取媒体权限", "Read_External_Permission_Message": "Rocket.Chat 需要存取您装置上的相片、多媒体及文件", "Read_Only": "只读", + "Read_only_hint": "只有频道所有者可以发送新消息", "Read_Receipt": "查看已读人员", "Receive_Group_Mentions": "接收群组提及", "Receive_Group_Mentions_Info": "接收@all和@here提及", diff --git a/app/i18n/locales/zh-TW.json b/app/i18n/locales/zh-TW.json index c68e117b02..171115bf76 100644 --- a/app/i18n/locales/zh-TW.json +++ b/app/i18n/locales/zh-TW.json @@ -49,7 +49,9 @@ "Change_Language": "切換語言", "Change_language_loading": "切換語言", "changing_avatar": "更改大頭貼", + "Channel_hint_private": "人們只能被邀請加入", "Channel_Name": "頻道名稱", + "Channel_Read_Only_Hint": "只有頻道所有者可以發送新消息", "Channels": "頻道", "Chat_closed_by_agent": "聊天已被客服關閉", "Chats": "聊天", @@ -354,6 +356,7 @@ "Read_External_Permission": "讀取媒體權限", "Read_External_Permission_Message": "Rocket.Chat 需要存取您裝置上的相片、多媒體及檔案", "Read_Only": "唯讀", + "Read_only_hint": "只有頻道所有者可以發送新消息", "Read_Receipt": "查看已讀人員", "Receive_Group_Mentions": "接收群組提及", "Receive_Group_Mentions_Info": "接收@all和@here提及", diff --git a/app/views/CreateChannelView/RoomSettings/SwitchItem.tsx b/app/views/CreateChannelView/RoomSettings/SwitchItem.tsx index 14de43d2b5..cd14ee5abc 100644 --- a/app/views/CreateChannelView/RoomSettings/SwitchItem.tsx +++ b/app/views/CreateChannelView/RoomSettings/SwitchItem.tsx @@ -1,5 +1,5 @@ import React from 'react'; -import { StyleSheet, Text, View, SwitchProps, Pressable } from 'react-native'; +import { StyleSheet, Text, View, SwitchProps } from 'react-native'; import I18n from '../../../i18n'; import { useTheme } from '../../../theme'; @@ -12,19 +12,20 @@ const styles = StyleSheet.create({ alignItems: 'center', justifyContent: 'space-between', flexDirection: 'row', - maxHeight: 80, - marginBottom: 12 + maxHeight: 80 }, switchTextContainer: { flex: 1, marginRight: 8 }, label: { - fontSize: 14, + fontSize: 16, + lineHeight: 24, ...sharedStyles.textMedium }, hint: { fontSize: 14, + lineHeight: 20, ...sharedStyles.textRegular } }); @@ -40,21 +41,21 @@ export const SwitchItem = ({ id, value, label, hint, onValueChange, disabled = f const { colors } = useTheme(); return ( - onValueChange(!value)} - accessible - accessibilityLabel={`${I18n.t(label)}, ${value ? I18n.t('Enabled') : I18n.t('Disabled')}, ${I18n.t(hint)}`} - accessibilityRole='switch'> - - - {I18n.t(label)} - - {I18n.t(hint)} - - - + + + {I18n.t(label)} + + {I18n.t(hint)} + - + + ); }; diff --git a/app/views/CreateChannelView/RoomSettings/SwitchItemEncrypted.test.tsx b/app/views/CreateChannelView/RoomSettings/SwitchItemEncrypted.test.tsx index a5f536d5ab..7eeefe93de 100644 --- a/app/views/CreateChannelView/RoomSettings/SwitchItemEncrypted.test.tsx +++ b/app/views/CreateChannelView/RoomSettings/SwitchItemEncrypted.test.tsx @@ -45,7 +45,7 @@ describe('SwitchItemEncrypted', () => { const component = screen.queryByTestId(testEncrypted.testSwitchID); expect(component).toBeTruthy(); }); - + it('should change value of switch', () => { render( { expect(onPressMock).toHaveReturnedWith({ value: !testEncrypted.encrypted }); } }); - - it('label when encrypted and isTeam are false and is a public channel', () => { - render( - testEncrypted.onValueChangeEncrypted(value)} - type={testEncrypted.type} - /> - ); - const component = screen.queryByTestId(testEncrypted.testLabelID); - expect(component?.props.children).toBe(i18n.t('Channel_hint_encrypted_not_available')); - }); - + it('label when encrypted and isTeam are true and is a private team', () => { testEncrypted.isTeam = true; testEncrypted.type = true; diff --git a/app/views/CreateChannelView/RoomSettings/SwitchItemEncrypted.tsx b/app/views/CreateChannelView/RoomSettings/SwitchItemEncrypted.tsx index 9cc277c652..c575220dc1 100644 --- a/app/views/CreateChannelView/RoomSettings/SwitchItemEncrypted.tsx +++ b/app/views/CreateChannelView/RoomSettings/SwitchItemEncrypted.tsx @@ -28,12 +28,9 @@ export const SwitchItemEncrypted = ({ if (isTeam && !type) { hint = 'Team_hint_encrypted_not_available'; } - if (!isTeam && type) { + if (!isTeam) { hint = 'Channel_hint_encrypted'; } - if (!isTeam && !type) { - hint = 'Channel_hint_encrypted_not_available'; - } return ( void; broadcast: boolean; }) => { - let hint = ''; - if (readOnly) { + let hint = 'Read_only_hint'; + if (isTeam && readOnly) { hint = 'Read_only_hint'; } if (isTeam && !readOnly) { hint = 'Team_hint_not_read_only'; } - if (!isTeam && !readOnly) { - hint = 'Channel_hint_not_read_only'; - } return ( diff --git a/app/views/CreateChannelView/RoomSettings/index.tsx b/app/views/CreateChannelView/RoomSettings/index.tsx index 74fffbe9a5..8d04517499 100644 --- a/app/views/CreateChannelView/RoomSettings/index.tsx +++ b/app/views/CreateChannelView/RoomSettings/index.tsx @@ -1,4 +1,5 @@ import React, { useCallback, useState } from 'react'; +import { StyleSheet, View } from 'react-native'; import { UseFormSetValue } from 'react-hook-form'; import { useAppSelector } from '../../../lib/hooks'; @@ -9,6 +10,13 @@ import { SwitchItemReadOnly } from './SwitchItemReadOnly'; import { SwitchItemEncrypted } from './SwitchItemEncrypted'; import { IFormData } from '..'; +const styles = StyleSheet.create({ + container: { + gap: 12, + paddingVertical: 12 + } +}); + export const RoomSettings = ({ isTeam, setValue, @@ -66,13 +74,20 @@ export const RoomSettings = ({ const isDisabled = [createChannelPermission, createPrivateChannelPermission].filter(r => r === true).length <= 1; return ( - <> + + - - + ); }; diff --git a/app/views/CreateChannelView/index.tsx b/app/views/CreateChannelView/index.tsx index 2e8b9d7cb2..3bb9cf3611 100644 --- a/app/views/CreateChannelView/index.tsx +++ b/app/views/CreateChannelView/index.tsx @@ -30,7 +30,7 @@ const styles = StyleSheet.create({ }, containerTextInput: { paddingHorizontal: 16, - marginTop: 16 + marginTop: 32 }, containerStyle: { marginBottom: 16 @@ -53,7 +53,8 @@ const styles = StyleSheet.create({ paddingHorizontal: 16 }, buttonCreate: { - margin: 16 + marginTop: 32, + marginHorizontal: 16 } }); @@ -148,6 +149,7 @@ const CreateChannelView = () => { { describe('Usage', () => { it('should create private team', async () => { await element(by.id('create-channel-name')).replaceText(teamName); + await element(by.id('create-channel-name')).tapReturnKey(); await waitFor(element(by.id('create-channel-submit'))) .toExist() .withTimeout(2000);