Add link to help page to related list selector component
This commit is contained in:
@@ -12,7 +12,11 @@
|
||||
<%= f.text_field :related_sdg_list,
|
||||
class: "input",
|
||||
placeholder: t("sdg.related_list_selector.placeholder"),
|
||||
label: t("sdg.related_list_selector.hint"),
|
||||
hint: sanitize(t("sdg.related_list_selector.hint",
|
||||
link: link_to(t("sdg.related_list_selector.help.text"),
|
||||
sdg_help_path,
|
||||
title: t("shared.target_blank"),
|
||||
target: "_blank"))),
|
||||
data: { "suggestions-list": sdg_related_suggestions,
|
||||
"remove-tag-text": t("sdg.related_list_selector.remove_tag") } %>
|
||||
</div>
|
||||
|
||||
@@ -7,6 +7,7 @@ en:
|
||||
name: Name
|
||||
email: Email
|
||||
description: Description
|
||||
related_sdg_list: Goals and Targets
|
||||
activerecord:
|
||||
models:
|
||||
activity:
|
||||
|
||||
@@ -461,7 +461,8 @@ en:
|
||||
goal_list: "You can choose one or several SDGs aligned with your %{record}"
|
||||
help:
|
||||
title: "Which SDGs and targets are aligned with my %{record}?"
|
||||
hint: "You can introduce the code of a specific goal/target or a text to find one"
|
||||
text: "SDG help page"
|
||||
hint: You can introduce the code of a specific goal/target or a text to find one. For more information visit the %{link}.
|
||||
placeholder: "Write a goal or target code or description"
|
||||
remove_tag: "Remove"
|
||||
title: "Sustainable Development Goals and Targets"
|
||||
|
||||
@@ -7,6 +7,7 @@ es:
|
||||
name: Nombre
|
||||
email: Email
|
||||
description: Descripción
|
||||
related_sdg_list: Objetivos y Metas
|
||||
activerecord:
|
||||
models:
|
||||
activity:
|
||||
|
||||
@@ -461,7 +461,8 @@ es:
|
||||
goal_list: "Puedes seleccionar uno o varios ODS con los que se alinea tu %{record}"
|
||||
help:
|
||||
title: "¿Qué ODS y metas se alinean con mi %{record}?"
|
||||
hint: "Puedes introducir el código de un objetivo/meta específico o un texto para encontrar uno"
|
||||
text: "página de ayuda de ODS"
|
||||
hint: Puedes introducir el código de un objetivo/meta específico o un texto para encontrar uno. Para más información visita la %{link}.
|
||||
placeholder: "Escribe las etiquetas que desees"
|
||||
remove_tag: "Eliminar"
|
||||
title: "Objetivos de Desarrollo Sostenible y Metas"
|
||||
|
||||
@@ -305,17 +305,17 @@ describe "SDG Relations", :js do
|
||||
create(:sdg_local_target, code: "1.1.1")
|
||||
visit sdg_management_edit_legislation_process_path(process)
|
||||
|
||||
fill_in "You can introduce the code of a specific goal/target or a text to find one", with: "3"
|
||||
fill_in "Goals and Targets", with: "3"
|
||||
within(".amsify-list") { find(:css, "[data-val='3']").click }
|
||||
|
||||
within(".amsify-suggestags-input-area") { expect(page).to have_content "SDG3" }
|
||||
|
||||
fill_in "You can introduce the code of a specific goal/target or a text to find one", with: "1.1"
|
||||
fill_in "Goals and Targets", with: "1.1"
|
||||
within(".amsify-list") { find(:css, "[data-val='1.1']").click }
|
||||
|
||||
within(".amsify-suggestags-input-area") { expect(page).to have_content "1.1" }
|
||||
|
||||
fill_in "You can introduce the code of a specific goal/target or a text to find one", with: "1.1.1"
|
||||
fill_in "Goals and Targets", with: "1.1.1"
|
||||
within(".amsify-list") { find(:css, "[data-val='1.1.1']").click }
|
||||
|
||||
within(".amsify-suggestags-input-area") { expect(page).to have_content "1.1.1" }
|
||||
@@ -333,7 +333,7 @@ describe "SDG Relations", :js do
|
||||
process = create(:legislation_process, title: "SDG process")
|
||||
|
||||
visit sdg_management_edit_legislation_process_path(process)
|
||||
fill_in "You can introduce the code of a specific goal/target or a text to find one", with: "tag nonexistent,"
|
||||
fill_in "Goals and Targets", with: "tag nonexistent,"
|
||||
|
||||
within(".amsify-suggestags-input-area") { expect(page).not_to have_content "tag nonexistent" }
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user