From fb0bf95b3d41b08ac9b0e493cb301b8934881ddf Mon Sep 17 00:00:00 2001 From: David Montero Crespo Date: Sat, 9 May 2026 02:01:13 -0300 Subject: [PATCH] feat(landing): translate hero block to 9 locales (Block 1 of 4) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Hero strings now go through `t('landing.hero.*')`: - titleLine1 / titleAccent (split for the gradient span) - subtitle (one paragraph; "19 boards / 48+ parts" stays inside the string so locales can phrase the count naturally) - ctaPrimary / ctaGithub - trustLine (the "no signup / runs in browser / free & open-source" reassurance line — was previously emitting NBSP-wrapped middle dots; the localised versions use plain spaces, which is fine visually) - imageAlt (a11y for the editor screenshot) Internal /editor link now goes through localize() so a Spanish reader clicking the primary CTA stays at /es/editor instead of dropping back to English. Translations are hand-curated for all 8 non-English locales (es, pt-br, it, fr, zh-cn, de, ja, ru). Brand names (Velxio, Arduino, ESP32, Raspberry Pi, GitHub, AGPLv3) preserved as-is. The script arrow "→" is kept in every locale because it carries directional meaning that translates naturally across languages. Block 2 (Boards / supported hardware), Block 3 (features grid), Block 4 (Support / footer copy) and Editor strings still pending. --- frontend/src/i18n/locales/de/common.json | 11 +++++++ frontend/src/i18n/locales/en/common.json | 11 +++++++ frontend/src/i18n/locales/es/common.json | 11 +++++++ frontend/src/i18n/locales/fr/common.json | 11 +++++++ frontend/src/i18n/locales/it/common.json | 11 +++++++ frontend/src/i18n/locales/ja/common.json | 11 +++++++ frontend/src/i18n/locales/pt-br/common.json | 11 +++++++ frontend/src/i18n/locales/ru/common.json | 11 +++++++ frontend/src/i18n/locales/zh-cn/common.json | 11 +++++++ frontend/src/pages/LandingPage.tsx | 32 +++++++++------------ 10 files changed, 113 insertions(+), 18 deletions(-) diff --git a/frontend/src/i18n/locales/de/common.json b/frontend/src/i18n/locales/de/common.json index 4d78ecba..9e5ef6a0 100644 --- a/frontend/src/i18n/locales/de/common.json +++ b/frontend/src/i18n/locales/de/common.json @@ -24,5 +24,16 @@ }, "footer": { "about": "Velxio ist ein kostenloser, quelloffener Schaltungs- und Mikrocontroller-Simulator, der vollständig im Browser läuft. Arduino, ESP32, RP2040 und ATtiny85 mit SPICE-genauer analoger Co-Simulation. Entwickelt für Maker, Studierende und Embedded-Engineers, die durch praktisches Tun lernen. AGPLv3." + }, + "landing": { + "hero": { + "titleLine1": "Arduino, ESP32 und Raspberry Pi.", + "titleAccent": "Direkt in deinem Browser.", + "subtitle": "Code schreiben, Komponenten verkabeln, Run drücken. 19 Boards, 48+ Bauteile, echte CPU-Emulation — ohne Hardware, ohne Installation, ohne Cloud.", + "ctaPrimary": "Simulator kostenlos testen →", + "ctaGithub": "Auf GitHub ansehen", + "trustLine": "Keine Anmeldung · Läuft zu 100% im Browser · Kostenlos und Open Source", + "imageAlt": "Velxio-Editor mit einer Ampelschaltung auf Arduino Uno" + } } } diff --git a/frontend/src/i18n/locales/en/common.json b/frontend/src/i18n/locales/en/common.json index 8251c7b5..57b40a3a 100644 --- a/frontend/src/i18n/locales/en/common.json +++ b/frontend/src/i18n/locales/en/common.json @@ -24,5 +24,16 @@ }, "footer": { "about": "Velxio is a free, open-source circuit and microcontroller simulator that runs entirely in your browser. Arduino, ESP32, RP2040 and ATtiny85, with SPICE-accurate analog co-simulation. Built for makers, students and embedded engineers learning by doing. AGPLv3." + }, + "landing": { + "hero": { + "titleLine1": "Arduino, ESP32 & Raspberry Pi.", + "titleAccent": "Right in your browser.", + "subtitle": "Write code, wire up components, hit run. 19 boards, 48+ parts, real CPU emulation — no hardware, no installation, no cloud.", + "ctaPrimary": "Try Simulator Free →", + "ctaGithub": "View on GitHub", + "trustLine": "No signup required · Runs 100% in your browser · Free & open-source", + "imageAlt": "Velxio editor with Arduino Uno traffic-light circuit" + } } } diff --git a/frontend/src/i18n/locales/es/common.json b/frontend/src/i18n/locales/es/common.json index dc078756..f1518c71 100644 --- a/frontend/src/i18n/locales/es/common.json +++ b/frontend/src/i18n/locales/es/common.json @@ -24,5 +24,16 @@ }, "footer": { "about": "Velxio es un simulador de circuitos y microcontroladores gratuito y de código abierto que se ejecuta enteramente en tu navegador. Arduino, ESP32, RP2040 y ATtiny85, con co-simulación analógica precisa SPICE. Construido para makers, estudiantes e ingenieros embebidos que aprenden haciendo. AGPLv3." + }, + "landing": { + "hero": { + "titleLine1": "Arduino, ESP32 y Raspberry Pi.", + "titleAccent": "Directo en tu navegador.", + "subtitle": "Escribe código, conecta componentes, pulsa run. 19 placas, más de 48 piezas, emulación real de CPU — sin hardware, sin instalación, sin nube.", + "ctaPrimary": "Probar el simulador gratis →", + "ctaGithub": "Ver en GitHub", + "trustLine": "Sin registro · Funciona 100% en tu navegador · Gratuito y de código abierto", + "imageAlt": "Editor de Velxio con un circuito de semáforo en Arduino Uno" + } } } diff --git a/frontend/src/i18n/locales/fr/common.json b/frontend/src/i18n/locales/fr/common.json index 8f4613d4..1f0297ed 100644 --- a/frontend/src/i18n/locales/fr/common.json +++ b/frontend/src/i18n/locales/fr/common.json @@ -24,5 +24,16 @@ }, "footer": { "about": "Velxio est un simulateur de circuits et microcontrôleurs gratuit et open-source qui fonctionne entièrement dans votre navigateur. Arduino, ESP32, RP2040 et ATtiny85, avec co-simulation analogique précise SPICE. Conçu pour les makers, étudiants et ingénieurs embarqués qui apprennent par la pratique. AGPLv3." + }, + "landing": { + "hero": { + "titleLine1": "Arduino, ESP32 et Raspberry Pi.", + "titleAccent": "Directement dans votre navigateur.", + "subtitle": "Écrivez du code, branchez des composants, lancez l'exécution. 19 cartes, plus de 48 pièces, émulation CPU réelle — sans matériel, sans installation, sans cloud.", + "ctaPrimary": "Essayer le simulateur gratuitement →", + "ctaGithub": "Voir sur GitHub", + "trustLine": "Aucune inscription · Fonctionne 100% dans votre navigateur · Gratuit et open-source", + "imageAlt": "Éditeur Velxio avec un circuit de feux tricolores sur Arduino Uno" + } } } diff --git a/frontend/src/i18n/locales/it/common.json b/frontend/src/i18n/locales/it/common.json index be86354f..26b1366f 100644 --- a/frontend/src/i18n/locales/it/common.json +++ b/frontend/src/i18n/locales/it/common.json @@ -24,5 +24,16 @@ }, "footer": { "about": "Velxio è un simulatore di circuiti e microcontrollori gratuito e open-source che funziona interamente nel browser. Arduino, ESP32, RP2040 e ATtiny85, con co-simulazione analogica accurata SPICE. Pensato per maker, studenti e ingegneri embedded che imparano facendo. AGPLv3." + }, + "landing": { + "hero": { + "titleLine1": "Arduino, ESP32 e Raspberry Pi.", + "titleAccent": "Direttamente nel tuo browser.", + "subtitle": "Scrivi il codice, collega i componenti, premi run. 19 schede, oltre 48 componenti, emulazione reale della CPU — senza hardware, senza installazione, senza cloud.", + "ctaPrimary": "Prova il simulatore gratis →", + "ctaGithub": "Vedi su GitHub", + "trustLine": "Nessuna registrazione · Funziona al 100% nel tuo browser · Gratuito e open-source", + "imageAlt": "Editor Velxio con un circuito semaforo su Arduino Uno" + } } } diff --git a/frontend/src/i18n/locales/ja/common.json b/frontend/src/i18n/locales/ja/common.json index 6c93d330..21b4b3fd 100644 --- a/frontend/src/i18n/locales/ja/common.json +++ b/frontend/src/i18n/locales/ja/common.json @@ -24,5 +24,16 @@ }, "footer": { "about": "Velxio は、ブラウザ上で完全に動作する無料のオープンソース回路・マイクロコントローラシミュレータです。Arduino、ESP32、RP2040、ATtiny85 に対応し、SPICE 精度のアナログ協調シミュレーションを備えています。実践を通じて学ぶメイカー、学生、組み込みエンジニアのために作られました。AGPLv3。" + }, + "landing": { + "hero": { + "titleLine1": "Arduino、ESP32、Raspberry Pi。", + "titleAccent": "ブラウザでそのまま。", + "subtitle": "コードを書いて、部品を配線し、実行ボタンを押すだけ。19 種のボード、48 以上のパーツ、本格的な CPU エミュレーション — ハードウェア不要、インストール不要、クラウド不要。", + "ctaPrimary": "無料でシミュレータを試す →", + "ctaGithub": "GitHub で見る", + "trustLine": "登録不要 · ブラウザ内で 100% 動作 · 無料・オープンソース", + "imageAlt": "Arduino Uno の信号機回路を表示している Velxio エディタ" + } } } diff --git a/frontend/src/i18n/locales/pt-br/common.json b/frontend/src/i18n/locales/pt-br/common.json index 64e82c7e..19b3dcb6 100644 --- a/frontend/src/i18n/locales/pt-br/common.json +++ b/frontend/src/i18n/locales/pt-br/common.json @@ -24,5 +24,16 @@ }, "footer": { "about": "Velxio é um simulador de circuitos e microcontroladores gratuito e de código aberto que roda inteiramente no seu navegador. Arduino, ESP32, RP2040 e ATtiny85, com co-simulação analógica precisa SPICE. Feito para makers, estudantes e engenheiros embarcados que aprendem fazendo. AGPLv3." + }, + "landing": { + "hero": { + "titleLine1": "Arduino, ESP32 e Raspberry Pi.", + "titleAccent": "Direto no seu navegador.", + "subtitle": "Escreva código, conecte componentes, aperte run. 19 placas, mais de 48 peças, emulação real de CPU — sem hardware, sem instalação, sem nuvem.", + "ctaPrimary": "Testar o simulador grátis →", + "ctaGithub": "Ver no GitHub", + "trustLine": "Sem cadastro · Roda 100% no seu navegador · Gratuito e de código aberto", + "imageAlt": "Editor Velxio com um circuito de semáforo em Arduino Uno" + } } } diff --git a/frontend/src/i18n/locales/ru/common.json b/frontend/src/i18n/locales/ru/common.json index 8b0eab8e..8cb019ea 100644 --- a/frontend/src/i18n/locales/ru/common.json +++ b/frontend/src/i18n/locales/ru/common.json @@ -24,5 +24,16 @@ }, "footer": { "about": "Velxio — это бесплатный симулятор схем и микроконтроллеров с открытым исходным кодом, работающий полностью в браузере. Поддерживает Arduino, ESP32, RP2040 и ATtiny85 с SPICE-точной аналоговой ко-симуляцией. Создан для мейкеров, студентов и инженеров встраиваемых систем, которые учатся на практике. AGPLv3." + }, + "landing": { + "hero": { + "titleLine1": "Arduino, ESP32 и Raspberry Pi.", + "titleAccent": "Прямо в вашем браузере.", + "subtitle": "Пишите код, подключайте компоненты, запускайте. 19 плат, 48+ деталей, настоящая эмуляция CPU — без оборудования, без установки, без облака.", + "ctaPrimary": "Попробовать симулятор бесплатно →", + "ctaGithub": "Открыть на GitHub", + "trustLine": "Без регистрации · Работает на 100% в браузере · Бесплатно и с открытым кодом", + "imageAlt": "Редактор Velxio с схемой светофора на Arduino Uno" + } } } diff --git a/frontend/src/i18n/locales/zh-cn/common.json b/frontend/src/i18n/locales/zh-cn/common.json index f4c00fa5..8f6496b6 100644 --- a/frontend/src/i18n/locales/zh-cn/common.json +++ b/frontend/src/i18n/locales/zh-cn/common.json @@ -24,5 +24,16 @@ }, "footer": { "about": "Velxio 是一款免费的开源电路和微控制器模拟器,完全在您的浏览器中运行。支持 Arduino、ESP32、RP2040 和 ATtiny85,配备 SPICE 精度的模拟协同仿真。专为通过实践学习的创客、学生和嵌入式工程师打造。AGPLv3。" + }, + "landing": { + "hero": { + "titleLine1": "Arduino、ESP32 和 Raspberry Pi。", + "titleAccent": "就在您的浏览器中。", + "subtitle": "编写代码、连接元件、点击运行。19 款开发板,48+ 元件,真实 CPU 模拟 —— 无需硬件、无需安装、无需云端。", + "ctaPrimary": "免费试用模拟器 →", + "ctaGithub": "在 GitHub 上查看", + "trustLine": "无需注册 · 100% 在浏览器中运行 · 免费且开源", + "imageAlt": "Velxio 编辑器中的 Arduino Uno 红绿灯电路" + } } } diff --git a/frontend/src/pages/LandingPage.tsx b/frontend/src/pages/LandingPage.tsx index 8f587c35..2e69756d 100644 --- a/frontend/src/pages/LandingPage.tsx +++ b/frontend/src/pages/LandingPage.tsx @@ -12,6 +12,7 @@ import { useTranslation } from 'react-i18next'; import { useAuthStore } from '../store/useAuthStore'; import { trackVisitGitHub, trackClickCTA } from '../utils/analytics'; import { AppHeader } from '../components/layout/AppHeader'; +import { useLocalizedHref } from '../i18n/useLocalizedNavigate'; import { useSEO } from '../utils/useSEO'; import { getSeoMeta } from '../seoRoutes'; import raspberryPi3Svg from '../assets/Raspberry_Pi_3_illustration.svg'; @@ -746,6 +747,7 @@ const UserMenu: React.FC = () => { /* ── Component ────────────────────────────────────────── */ export const LandingPage: React.FC = () => { const { t } = useTranslation(); + const localize = useLocalizedHref(); useSEO({ ...getSeoMeta('/')!, jsonLd: { @@ -812,23 +814,19 @@ export const LandingPage: React.FC = () => {

- Arduino, ESP32 & Raspberry Pi. + {t('landing.hero.titleLine1')}
- Right in your browser. + {t('landing.hero.titleAccent')}

-

- Write code, wire up components, hit run. - 19 boards, 48+ parts, real CPU emulation — - no hardware, no installation, no cloud. -

+

{t('landing.hero.subtitle')}

trackClickCTA('landing', '/editor')} > - Try Simulator Free → + {t('landing.hero.ctaPrimary')} { className="cta-secondary" > - View on GitHub + {t('landing.hero.ctaGithub')}
-

- No signup required · Runs 100% in your browser · Free & open-source -

+

{t('landing.hero.trustLine')}

@@ -851,7 +847,7 @@ export const LandingPage: React.FC = () => { Velxio editor with Arduino Uno traffic-light circuit { GitHub - Docs - Examples - Editor - About + Docs + Examples + Editor + About

{t('footer.about')}