diff --git a/frontend/src/components/UnsafeAlert.js b/frontend/src/components/UnsafeAlert.js index 109d7dc5..da8136fd 100644 --- a/frontend/src/components/UnsafeAlert.js +++ b/frontend/src/components/UnsafeAlert.js @@ -36,14 +36,17 @@ class UnsafeAlert extends Component { render() { console.log('1111') const { t, i18n} = this.props; - + + // If alert is hidden return null + if (!this.state.show){return null} + // Show selfhosted notice if (this.state.isSelfhosted){ return(
- this.setState({show:false})}>{t("Hide")}} + this.setState({show:false})}>{t("Hide")}} > {t("You are self-hosting RoboSats")} {t("RoboSats is served from your own node granting you the strongest security and privacy.")} @@ -54,7 +57,7 @@ class UnsafeAlert extends Component { } // Show unsafe alert - if (!this.safe_urls.includes(this.getHost()) & this.state.show & !this.state.isSelfhosted){ + if (!this.safe_urls.includes(this.getHost())){ return(
diff --git a/frontend/static/locales/en.json b/frontend/static/locales/en.json index b5a7d9c0..edf27080 100644 --- a/frontend/static/locales/en.json +++ b/frontend/static/locales/en.json @@ -4,6 +4,8 @@ "desktop_unsafe_alert": "Some features are disabled for your protection (e.g. chat) and you will not be able to complete a trade without them. To protect your privacy and fully enable RoboSats, use <1>Tor Browser and visit the <3>Onion site.", "phone_unsafe_alert": "You will not be able to complete a trade. Use <1>Tor Browser and visit the <3>Onion site.", "Hide":"Hide", + "You are self-hosting RoboSats":"You are self-hosting RoboSats", + "RoboSats is served from your own node granting you the strongest security and privacy.":"RoboSats is served from your own node granting you the strongest security and privacy.", "USER GENERATION PAGE - UserGenPage.js": "Landing Page and User Generation", diff --git a/frontend/static/locales/es.json b/frontend/static/locales/es.json index 47cbd56c..9982c8e1 100644 --- a/frontend/static/locales/es.json +++ b/frontend/static/locales/es.json @@ -4,7 +4,9 @@ "desktop_unsafe_alert": "Algunas funciones (como el chat) están deshabilitadas para protegerte y sin ellas no podrás completar un intercambio. Para proteger tu privacidad y habilitar RoboSats por completo, usa el <1>Navegador Tor y visita el <3>sitio cebolla.", "phone_unsafe_alert": "No podrás completar un intercambio. Usa el <1>Navegador Tor y visita el <3>sitio cebolla.", "Hide": "Ocultar", - + "You are self-hosting RoboSats":"Estás hosteando RoboSats", + "RoboSats is served from your own node granting you the strongest security and privacy.":"El cliente RoboSats es servido por tu propio nodo, gozas de la mayor seguridad y privacidad.", + "UserGenPage": "User Generation Page and Landing Page", "Simple and Private LN P2P Exchange": "Intercambio LN P2P Fácil y Privado",