Skip to content

Commit

Permalink
feat: add translated content
Browse files Browse the repository at this point in the history
  • Loading branch information
deandreamatias committed Jul 24, 2024
1 parent 4c68c6d commit 3e28692
Show file tree
Hide file tree
Showing 5 changed files with 222 additions and 28 deletions.
39 changes: 39 additions & 0 deletions lib/l10n/app_en.arb
Original file line number Diff line number Diff line change
@@ -1,4 +1,43 @@
{
"@@locale": "en",
"who_title": "Who I am",
"who_is_mobile": "Mobile Developer",
"who_communities": "Member of communities",
"who_writer": "Writer",
"who_podcast": "Podcast fan",
"who_football": "Football player",
"who_secondary_football": "with low skills",
"who_nationality": "Spanish/Uruguayan",
"who_secondary_nationality": "and a little bit of Brazilian",
"who_family": "Husband",
"who_pets": "Cat tutor",
"what_title": "What I do",
"what_mobile": "Mobile applications",
"what_secondary_mobile": "mainly with Flutter",
"what_contribute": "Contribution to open source projects",
"what_videos": "Participation in videos",
"what_writing": "Writing articles and thoughts",
"what_podcast": "Podcast listener and creator",
"what_languages": "I am fluent in Spanish, Portuguese and moderately English",
"what_pets": "Picture with my cats",
"where_title": "Where I do it",
"where_live": "I live in Valencia, Spain",
"where_work": "I work remotely for Multiplica Talent",
"where_contribute": "GitHub and StackOverflow",
"where_videos": "YouTube (playlists)",
"where_communities": "Comunidades",
"where_community_brazil_tech": "Brazil Tech Expats",
"where_community_flutter": "Flutter Spain",
"where_community_vlc_tech": "VLC Tech",
"where_community_podcast": "Hoje Tem (Telegram)",
"where_writing": "Medium",
"where_podcast": "Anchor and Spotify",
"where_football": "OndaFC",
"where_family_and_pets": "Bluesky",
"when_title": "When I do",
"when_age": "Every year. Currently {age} years old",
"when_work": "Monday to Friday",
"when_balance": "All days looking for the balance between work and personal life",
"homeHeaderTitle": "Hi, I'm Matias de Andrea",
"homeHeaderSubtitle": "a creative and dynamic developer.\nI really like to work with mobile applications, developing UI/UX and software",
"skillsTitle": "My most loved technologies and tools are",
Expand Down
39 changes: 39 additions & 0 deletions lib/l10n/app_es.arb
Original file line number Diff line number Diff line change
@@ -1,4 +1,43 @@
{
"@@locale": "es",
"who_title": "Quién soy",
"who_is_mobile": "Desarrollador de aplicaciones móviles",
"who_communities": "Miembro de comunidades",
"who_writer": "Escritor",
"who_podcast": "Fan de podcasts",
"who_football": "Jugador de fútbol",
"who_secondary_football": "con pocas habilidades",
"who_nationality": "Español/Uruguayo",
"who_secondary_nationality": "y un poco brasileño",
"who_family": "Esposo",
"who_pets": "Tutor de gatos",
"what_title": "Qué hago",
"what_mobile": "Aplicaciones móviles",
"what_secondary_mobile": "principalmente con Flutter",
"what_contribute": "Contribución a proyectos de código abierto",
"what_videos": "Participación en videos",
"what_writing": "Escribir artículos y reflexiones",
"what_podcast": "Oyente y creador de podcasts",
"what_languages": "Hablo español, portugués y medianamente inglés",
"what_pets": "Foto con mis gatos",
"where_title": "Dónde lo hago",
"where_live": "Vivo en Valencia, España",
"where_work": "Trabajo remotamente para Multiplica Talent",
"where_contribute": "GitHub y StackOverflow",
"where_videos": "YouTube (listas de reproducción)",
"where_communities": "Comunidades",
"where_community_brazil_tech": "Brazil Tech Expats",
"where_community_flutter": "Flutter España",
"where_community_vlc_tech": "VLC Tech",
"where_community_podcast": "Hoje Tem (Telegram)",
"where_writing": "Medium",
"where_podcast": "Anchor y Spotify",
"where_football": "OndaFC",
"where_family_and_pets": "Bluesky",
"when_title": "Cuándo lo hago",
"when_age": "Cada año. Actualmente tengo {age} años",
"when_work": "De lunes a viernes",
"when_balance": "Todos los días buscando el equilibrio entre el trabajo y la vida personal",
"homeHeaderTitle": "Hola, soy Matias de Andrea",
"homeHeaderSubtitle": "un desarrollador creativo y dinámico. Me encanta trabajar con aplicaciones móviles, desarrollando el UI/UX y el software",
"skillsTitle": "Mis herramientas preferidas son",
Expand Down
39 changes: 39 additions & 0 deletions lib/l10n/app_pt.arb
Original file line number Diff line number Diff line change
@@ -1,4 +1,43 @@
{
"@@locale": "pt",
"who_title": "Quem sou eu",
"who_is_mobile": "Desenvolvedor de aplicativos móveis",
"who_communities": "Membro de comunidades",
"who_writer": "Escritor",
"who_podcast": "Fã de podcasts",
"who_football": "Jogador de futebol",
"who_secondary_football": "com poucas habilidades",
"who_nationality": "Espanhol/Uruguaio",
"who_secondary_nationality": "e um pouco brasileiro",
"who_family": "Marido",
"who_pets": "Tutor de gatos",
"what_title": "O que eu faço",
"what_mobile": "Aplicativos móveis",
"what_secondary_mobile": "principalmente com Flutter",
"what_contribute": "Contribuição para projetos de código aberto",
"what_videos": "Participação em vídeos",
"what_writing": "Escrever artigos e relfexões",
"what_podcast": "Ouvinte e criador de podcasts",
"what_languages": "Falo espanhol, português e medianamente inglês",
"what_pets": "Foto com meus gatos",
"where_title": "Onde eu faço",
"where_live": "Moro em Valencia, Espanha",
"where_work": "Trabalho remotamente para Multiplica Talent",
"where_contribute": "GitHub e StackOverflow",
"where_videos": "YouTube (playlists)",
"where_communities": "Comunidades",
"where_community_brazil_tech": "Brazil Tech Expats",
"where_community_flutter": "Flutter Espanha",
"where_community_vlc_tech": "VLC Tech",
"where_community_podcast": "Hoje Tem (Telegram)",
"where_writing": "Medium",
"where_podcast": "Anchor e Spotify",
"where_football": "OndaFC",
"where_family_and_pets": "Bluesky",
"when_title": "Quando eu faço",
"when_age": "Todos os anos. Atualmente tenho {age} anos",
"when_work": "De segunda a sexta-feira",
"when_balance": "Todos os dias buscando o equilíbrio entre o trabalho e a vida pessoal",
"homeHeaderTitle": "Olá, sou Matias de Andrea",
"homeHeaderSubtitle": "um desenvolvedor criativo e dinâmico. Gosto muito de trabalhar com aplicações móveis, desenvolvendo o UI/UX e o software",
"skillsTitle": "Minhas ferramentas favoritas são",
Expand Down
131 changes: 104 additions & 27 deletions lib/ui/views/home.dart
Original file line number Diff line number Diff line change
Expand Up @@ -33,33 +33,7 @@ class HomeViewState extends State<HomeView> {
(BuildContext context, SizingInformation sizingInformation) {
switch (sizingInformation.deviceScreenType) {
case DeviceScreenType.desktop:
return Row(
mainAxisSize: MainAxisSize.min,
children: <Widget>[
Column(
mainAxisSize: MainAxisSize.min,
children: <Widget>[
HeaderWidget(
title:
AppLocalizations.of(context)!.homeHeaderTitle,
subtitle: AppLocalizations.of(context)!
.homeHeaderSubtitle,
image: Urls.profile,
key: const Key(Urls.profile),
),
const LanguagesWidget(),
],
),
const Column(
mainAxisSize: MainAxisSize.min,
children: <Widget>[
GithubWidget(),
SkillsWidget(),
ContactWidget(),
],
)
],
);
return const _LargeContent();
default:
return SingleChildScrollView(
padding: const EdgeInsets.all(16.0),
Expand Down Expand Up @@ -96,3 +70,106 @@ class HomeViewState extends State<HomeView> {
);
}
}

class _LargeContent extends StatelessWidget {
const _LargeContent();

@override
Widget build(BuildContext context) {
return Row(
mainAxisSize: MainAxisSize.min,
children: <Widget>[
Flexible(
child: ColumnContent(
title: AppLocalizations.of(context)!.who_title,
content: [
AppLocalizations.of(context)!.who_is_mobile,
AppLocalizations.of(context)!.who_communities,
AppLocalizations.of(context)!.who_writer,
AppLocalizations.of(context)!.who_podcast,
AppLocalizations.of(context)!.who_football,
AppLocalizations.of(context)!.who_secondary_football,
AppLocalizations.of(context)!.who_nationality,
AppLocalizations.of(context)!.who_secondary_nationality,
AppLocalizations.of(context)!.who_family,
AppLocalizations.of(context)!.who_pets,
],
),
),
Flexible(
child: ColumnContent(
title: AppLocalizations.of(context)!.what_title,
content: [
AppLocalizations.of(context)!.what_mobile,
AppLocalizations.of(context)!.what_contribute,
AppLocalizations.of(context)!.what_videos,
AppLocalizations.of(context)!.what_writing,
AppLocalizations.of(context)!.what_podcast,
AppLocalizations.of(context)!.what_languages,
AppLocalizations.of(context)!.what_pets,
],
),
),
Flexible(
child: ColumnContent(
title: AppLocalizations.of(context)!.where_title,
content: [
AppLocalizations.of(context)!.where_live,
AppLocalizations.of(context)!.where_work,
AppLocalizations.of(context)!.where_contribute,
AppLocalizations.of(context)!.where_videos,
AppLocalizations.of(context)!.where_communities,
AppLocalizations.of(context)!.where_writing,
AppLocalizations.of(context)!.where_podcast,
AppLocalizations.of(context)!.where_football,
AppLocalizations.of(context)!.where_family_and_pets,
],
),
),
Flexible(
child: ColumnContent(
title: AppLocalizations.of(context)!.when_title,
content: [
AppLocalizations.of(context)!.when_age(29),
AppLocalizations.of(context)!.when_work,
AppLocalizations.of(context)!.when_balance,
],
),
),
],
);
}
}

class ColumnContent extends StatelessWidget {
final String title;
final List<String> content;
const ColumnContent({
super.key,
required this.title,
this.content = const [],
});

@override
Widget build(BuildContext context) {
return Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Align(
alignment: Alignment.topCenter,
child: Text(
title,
textAlign: TextAlign.center,
maxLines: 1,
),
),
for (final String item in content)
Padding(padding: const EdgeInsets.all(8.0), child: Text(item)),
],
),
);
}
}
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ dependencies:
sdk: flutter
google_fonts: ^6.2.1
intl: ^0.19.0
responsive_builder: ^0.7.0
responsive_builder: ^0.7.1
url_launcher: ^6.3.0

dev_dependencies:
Expand Down

0 comments on commit 3e28692

Please sign in to comment.