From 6b9eead0abfe8b35fcd083d9f7270e2f668628b2 Mon Sep 17 00:00:00 2001 From: jazzari Date: Mon, 17 Apr 2023 15:13:37 -0300 Subject: [PATCH 1/7] fix: search placeholder in index.haml view #13095 --- app/views/posts/index.haml | 3 ++- config/locales/en.yml | 3 ++- config/locales/es.yml | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/app/views/posts/index.haml b/app/views/posts/index.haml index 4f814cda..1a12e405 100644 --- a/app/views/posts/index.haml +++ b/app/views/posts/index.haml @@ -49,7 +49,8 @@ - next if param == 'q' %input{ type: 'hidden', name: param, value: value } .form-group.flex-grow-0.m-0 - %input.form-control.border.border-magenta{ type: 'search', placeholder: 'Buscar', name: 'q', value: @filter_params[:q] } + .label.sr-only t('.search') + %input.form-control.border.border-magenta{ type: 'search', placeholder: t('.search'), name: 'q', value: @filter_params[:q] } %input.sr-only{ type: 'submit' } - if @site.locales.size > 1 diff --git a/config/locales/en.yml b/config/locales/en.yml index 3ddf681d..163d6021 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -544,7 +544,8 @@ en: remove_filter: 'Back' remove_filter_help: 'Remove the filter: %{filter}' categories: 'Everything' - index: 'Posts' + index: + search: 'search' edit: 'Edit' preview: btn: 'Preliminary version' diff --git a/config/locales/es.yml b/config/locales/es.yml index 01f1085c..b67db8ca 100644 --- a/config/locales/es.yml +++ b/config/locales/es.yml @@ -552,7 +552,8 @@ es: filter: 'Filtrar' remove_filter: 'Volver' remove_filter_help: 'Quitar este filtro: %{filter}' - index: 'Artículos' + index: + search: 'buscar' edit: 'Editar' preview: btn: 'Versión preliminar' From fcbed5003e28953a90d1ac317b5016dd012f74a9 Mon Sep 17 00:00:00 2001 From: jazzari Date: Mon, 17 Apr 2023 16:15:09 -0300 Subject: [PATCH 2/7] fix: add missing sign = in view #13095 --- app/views/posts/index.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/posts/index.haml b/app/views/posts/index.haml index 1a12e405..ac2932f8 100644 --- a/app/views/posts/index.haml +++ b/app/views/posts/index.haml @@ -49,7 +49,7 @@ - next if param == 'q' %input{ type: 'hidden', name: param, value: value } .form-group.flex-grow-0.m-0 - .label.sr-only t('.search') + .label.sr-only = t('.search') %input.form-control.border.border-magenta{ type: 'search', placeholder: t('.search'), name: 'q', value: @filter_params[:q] } %input.sr-only{ type: 'submit' } From 19bf8fb8bf682381db1815a8f8836cdd564ffae9 Mon Sep 17 00:00:00 2001 From: jazzari Date: Mon, 17 Apr 2023 16:37:10 -0300 Subject: [PATCH 3/7] fix: capitalization en yml & fix in view #13095 --- app/views/posts/index.haml | 2 +- config/locales/en.yml | 2 +- config/locales/es.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/views/posts/index.haml b/app/views/posts/index.haml index ac2932f8..bceb0a24 100644 --- a/app/views/posts/index.haml +++ b/app/views/posts/index.haml @@ -49,7 +49,7 @@ - next if param == 'q' %input{ type: 'hidden', name: param, value: value } .form-group.flex-grow-0.m-0 - .label.sr-only = t('.search') + .label.sr-only= t('.search') %input.form-control.border.border-magenta{ type: 'search', placeholder: t('.search'), name: 'q', value: @filter_params[:q] } %input.sr-only{ type: 'submit' } diff --git a/config/locales/en.yml b/config/locales/en.yml index 163d6021..64f596d7 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -545,7 +545,7 @@ en: remove_filter_help: 'Remove the filter: %{filter}' categories: 'Everything' index: - search: 'search' + search: 'Search' edit: 'Edit' preview: btn: 'Preliminary version' diff --git a/config/locales/es.yml b/config/locales/es.yml index b67db8ca..6ad61228 100644 --- a/config/locales/es.yml +++ b/config/locales/es.yml @@ -553,7 +553,7 @@ es: remove_filter: 'Volver' remove_filter_help: 'Quitar este filtro: %{filter}' index: - search: 'buscar' + search: 'Buscar' edit: 'Editar' preview: btn: 'Versión preliminar' From 219c0f4fb6837808e415cff5142cae5921bf2916 Mon Sep 17 00:00:00 2001 From: jazzari Date: Mon, 17 Apr 2023 16:47:09 -0300 Subject: [PATCH 4/7] fix: label tag in view #13095 --- app/views/posts/index.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/posts/index.haml b/app/views/posts/index.haml index bceb0a24..62760e85 100644 --- a/app/views/posts/index.haml +++ b/app/views/posts/index.haml @@ -49,7 +49,7 @@ - next if param == 'q' %input{ type: 'hidden', name: param, value: value } .form-group.flex-grow-0.m-0 - .label.sr-only= t('.search') + %label.sr-only= t('.search') %input.form-control.border.border-magenta{ type: 'search', placeholder: t('.search'), name: 'q', value: @filter_params[:q] } %input.sr-only{ type: 'submit' } From 85f959071912af407bb707cf4956d6211b88f673 Mon Sep 17 00:00:00 2001 From: jazzari Date: Mon, 17 Apr 2023 17:49:39 -0300 Subject: [PATCH 5/7] fix label in view #13095 --- app/views/posts/index.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/posts/index.haml b/app/views/posts/index.haml index 62760e85..d1a4f84d 100644 --- a/app/views/posts/index.haml +++ b/app/views/posts/index.haml @@ -49,7 +49,7 @@ - next if param == 'q' %input{ type: 'hidden', name: param, value: value } .form-group.flex-grow-0.m-0 - %label.sr-only= t('.search') + %label{for: 'q'}.sr-only= t('.search') %input.form-control.border.border-magenta{ type: 'search', placeholder: t('.search'), name: 'q', value: @filter_params[:q] } %input.sr-only{ type: 'submit' } From 6921a33f61ecd38c6726f9af7f3371e5d4d6009c Mon Sep 17 00:00:00 2001 From: jazzari Date: Mon, 17 Apr 2023 17:59:35 -0300 Subject: [PATCH 6/7] fix: add id to input in view #13095 --- app/views/posts/index.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/posts/index.haml b/app/views/posts/index.haml index d1a4f84d..60cc6245 100644 --- a/app/views/posts/index.haml +++ b/app/views/posts/index.haml @@ -50,7 +50,7 @@ %input{ type: 'hidden', name: param, value: value } .form-group.flex-grow-0.m-0 %label{for: 'q'}.sr-only= t('.search') - %input.form-control.border.border-magenta{ type: 'search', placeholder: t('.search'), name: 'q', value: @filter_params[:q] } + %input#q.form-control.border.border-magenta{ type: 'search', placeholder: t('.search'), name: 'q', value: @filter_params[:q] } %input.sr-only{ type: 'submit' } - if @site.locales.size > 1 From fbc822ba5ddda3d92a1b50f887756f75618819c6 Mon Sep 17 00:00:00 2001 From: jazzari Date: Mon, 17 Apr 2023 20:02:00 -0300 Subject: [PATCH 7/7] fix: attributes on label in view #13095 --- app/views/posts/index.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/posts/index.haml b/app/views/posts/index.haml index 60cc6245..9159d5e7 100644 --- a/app/views/posts/index.haml +++ b/app/views/posts/index.haml @@ -49,7 +49,7 @@ - next if param == 'q' %input{ type: 'hidden', name: param, value: value } .form-group.flex-grow-0.m-0 - %label{for: 'q'}.sr-only= t('.search') + %label.sr-only{for: 'q'}= t('.search') %input#q.form-control.border.border-magenta{ type: 'search', placeholder: t('.search'), name: 'q', value: @filter_params[:q] } %input.sr-only{ type: 'submit' }