From 39b55e11df7edc2befb8e03f41d4e0e72c6e1403 Mon Sep 17 00:00:00 2001 From: decabeza Date: Mon, 15 Jan 2018 21:21:24 +0100 Subject: [PATCH 1/8] changes text and makes bigger link to delete a marker on a map --- app/assets/stylesheets/layout.scss | 19 +++++++++++++++++++ app/helpers/map_locations_helper.rb | 2 +- config/locales/es/budgets.yml | 2 +- config/locales/es/general.yml | 2 +- 4 files changed, 22 insertions(+), 3 deletions(-) diff --git a/app/assets/stylesheets/layout.scss b/app/assets/stylesheets/layout.scss index e47ba0343..b5a3b794d 100644 --- a/app/assets/stylesheets/layout.scss +++ b/app/assets/stylesheets/layout.scss @@ -22,6 +22,7 @@ // 20. Documents // 21. Related content // 22. Images +// 23. Maps // // 01. Global styles @@ -2511,3 +2512,21 @@ table { .images .button { margin-top: $line-height / 2; } + +// 23. Maps +// ----------------- + +.location-map-remove-marker { + border-bottom: 1px dotted #cf2a0e; + color: $delete; + display: inline-block; + margin-top: $line-height / 2; + + &:hover, + &:active, + &:focus { + border-bottom: 1px solid #cf2a0e; + color: #cf2a0e; + text-decoration: none; + } +} diff --git a/app/helpers/map_locations_helper.rb b/app/helpers/map_locations_helper.rb index ae45e7c1d..e20d5e21a 100644 --- a/app/helpers/map_locations_helper.rb +++ b/app/helpers/map_locations_helper.rb @@ -34,7 +34,7 @@ module MapLocationsHelper end def map_location_remove_marker(map_location, text) - content_tag :div, class: "text-right" do + content_tag :div, class: "margin-bottom" do content_tag :a, id: map_location_remove_marker_link_id(map_location), href: "#", diff --git a/config/locales/es/budgets.yml b/config/locales/es/budgets.yml index 258f394d6..5bc0c0e63 100644 --- a/config/locales/es/budgets.yml +++ b/config/locales/es/budgets.yml @@ -59,7 +59,7 @@ es: tags_placeholder: "Escribe las etiquetas que desees separadas por una coma (',')" map_location: "Ubicación en el mapa" map_location_instructions: "Navega por el mapa hasta la ubicación y coloca el marcador." - map_remove_marker: "Eliminar el marcador" + map_remove_marker: "Eliminar marcador en el mapa" location: "Información adicional de la ubicación" index: title: Presupuestos participativos diff --git a/config/locales/es/general.yml b/config/locales/es/general.yml index cf497ae9d..41d148541 100644 --- a/config/locales/es/general.yml +++ b/config/locales/es/general.yml @@ -338,7 +338,7 @@ es: tags_placeholder: "Escribe las etiquetas que desees separadas por una coma (',')" map_location: "Ubicación en el mapa" map_location_instructions: "Navega por el mapa hasta la ubicación y coloca el marcador." - map_remove_marker: "Eliminar el marcador" + map_remove_marker: "Eliminar marcador en el mapa" map_skip_checkbox: "Esta propuesta no tiene una ubicación concreta o no la conozco." index: featured_proposals: Destacadas From 97bf00817ca798a92bc65fb6f8a2dc17a64d75db Mon Sep 17 00:00:00 2001 From: decabeza Date: Mon, 15 Jan 2018 21:21:44 +0100 Subject: [PATCH 2/8] fixes js class name --- app/assets/javascripts/map.js.coffee | 2 +- app/helpers/map_locations_helper.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/assets/javascripts/map.js.coffee b/app/assets/javascripts/map.js.coffee index 797232c4f..28ac34f29 100644 --- a/app/assets/javascripts/map.js.coffee +++ b/app/assets/javascripts/map.js.coffee @@ -83,4 +83,4 @@ App.Map = toogleMap: -> $('.map').toggle() - $('.location-map-remove-marker-button').toggle() \ No newline at end of file + $('.js-location-map-remove-marker').toggle() \ No newline at end of file diff --git a/app/helpers/map_locations_helper.rb b/app/helpers/map_locations_helper.rb index e20d5e21a..85b02e28c 100644 --- a/app/helpers/map_locations_helper.rb +++ b/app/helpers/map_locations_helper.rb @@ -38,7 +38,7 @@ module MapLocationsHelper content_tag :a, id: map_location_remove_marker_link_id(map_location), href: "#", - class: "location-map-remove-marker-button delete" do + class: "js-location-map-remove-marker location-map-remove-marker" do text end end From 2763f65c7daab1887d0d832b683ba5ebb0794d65 Mon Sep 17 00:00:00 2001 From: decabeza Date: Mon, 15 Jan 2018 21:24:06 +0100 Subject: [PATCH 3/8] updates texts on new budget investment form --- config/locales/en/activerecord.yml | 2 +- config/locales/es/activerecord.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/config/locales/en/activerecord.yml b/config/locales/en/activerecord.yml index 39d0e022a..c0b16dedb 100644 --- a/config/locales/en/activerecord.yml +++ b/config/locales/en/activerecord.yml @@ -118,7 +118,7 @@ en: heading_id: "Heading" title: "Title" location: "Location" - organization_name: "If you are proposing in the name of a collective/organization, write its name" + organization_name: "If you are proposing in the name of a collective/organization, or on behalf of more people, write its name" image: "Proposal descriptive image" image_title: "Image title" budget/investment/milestone: diff --git a/config/locales/es/activerecord.yml b/config/locales/es/activerecord.yml index 18296b7bf..522ecefa9 100644 --- a/config/locales/es/activerecord.yml +++ b/config/locales/es/activerecord.yml @@ -113,7 +113,7 @@ es: external_url: "Enlace a documentación adicional" location: "Ubicación" administrator_id: "Administrador" - organization_name: "Si estás proponiendo en nombre de una organización o colectivo, escribe su nombre" + organization_name: "Si estás proponiendo en nombre de una organización o colectivo, o en nombre de más gente, escribe su nombre" image: "Imagen descriptiva de la propuesta de inversión" image_title: "Título de la imagen" budget/heading: From 9f93f11e907d1cdde4d3687966bb160449605a01 Mon Sep 17 00:00:00 2001 From: decabeza Date: Mon, 15 Jan 2018 21:30:42 +0100 Subject: [PATCH 4/8] changes organization name on budget investment show --- config/locales/en/budgets.yml | 2 +- config/locales/es/budgets.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/config/locales/en/budgets.yml b/config/locales/en/budgets.yml index a0fd28cac..fce3a3ff9 100644 --- a/config/locales/en/budgets.yml +++ b/config/locales/en/budgets.yml @@ -104,7 +104,7 @@ en: unfeasibility_explanation: Unfeasibility explanation code_html: 'Investment project code: %{code}' location_html: 'Location: %{location}' - organization_name_html: 'Organization: %{name}' + organization_name_html: 'Proposed on behalf of: %{name}' share: Share title: Investment project supports: Supports diff --git a/config/locales/es/budgets.yml b/config/locales/es/budgets.yml index 5bc0c0e63..c00b5b714 100644 --- a/config/locales/es/budgets.yml +++ b/config/locales/es/budgets.yml @@ -104,7 +104,7 @@ es: unfeasibility_explanation: Informe de inviabilidad code_html: 'Código propuesta de gasto: %{code}' location_html: 'Ubicación: %{location}' - organization_name_html: 'Organización: %{name}' + organization_name_html: 'Propuesto en nombre de: %{name}' share: Compartir title: Proyecto de inversión supports: Apoyos From 8d0563e949a8b4630c47703d308800f5fb73e213 Mon Sep 17 00:00:00 2001 From: decabeza Date: Mon, 15 Jan 2018 21:33:48 +0100 Subject: [PATCH 5/8] fixes wrap text on investment projects with long titles --- app/assets/stylesheets/participation.scss | 1 + 1 file changed, 1 insertion(+) diff --git a/app/assets/stylesheets/participation.scss b/app/assets/stylesheets/participation.scss index bc8633ec9..606de72f3 100644 --- a/app/assets/stylesheets/participation.scss +++ b/app/assets/stylesheets/participation.scss @@ -339,6 +339,7 @@ .topic-show, .milestone-content { + h1, p { word-wrap: break-word; } From efa15b2a7174d1bac2733ebe29972192a0c914b0 Mon Sep 17 00:00:00 2001 From: decabeza Date: Mon, 15 Jan 2018 21:38:58 +0100 Subject: [PATCH 6/8] fixes a11y color contrast on map zoom control --- app/assets/stylesheets/layout.scss | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/app/assets/stylesheets/layout.scss b/app/assets/stylesheets/layout.scss index b5a3b794d..6ab56b14d 100644 --- a/app/assets/stylesheets/layout.scss +++ b/app/assets/stylesheets/layout.scss @@ -2530,3 +2530,10 @@ table { text-decoration: none; } } + +.leaflet-bar a { + + &.leaflet-disabled { + color: #525252 !important; + } +} From 8d469c10043b8fe8d004f0de5dab212af3eb11f9 Mon Sep 17 00:00:00 2001 From: decabeza Date: Mon, 15 Jan 2018 21:40:56 +0100 Subject: [PATCH 7/8] fixes lint scss warnings --- app/assets/stylesheets/layout.scss | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/app/assets/stylesheets/layout.scss b/app/assets/stylesheets/layout.scss index 6ab56b14d..854d6b1e6 100644 --- a/app/assets/stylesheets/layout.scss +++ b/app/assets/stylesheets/layout.scss @@ -2428,10 +2428,6 @@ table { margin-bottom: 0 !important; padding: $line-height / 2; - &:first-child { - border-top: 1px solid $border; - } - @include breakpoint(medium) { .score-actions { @@ -2440,6 +2436,10 @@ table { } } + &:first-child { + border-top: 1px solid $border; + } + &:hover { background: #f9f9f9; @@ -2479,8 +2479,8 @@ table { position: relative; text-decoration: none; - &.score-positive:before, - &.score-negative:before { + &.score-positive::before, + &.score-negative::before { font-family: 'icons'; left: 0; position: absolute; @@ -2489,7 +2489,7 @@ table { &.score-positive { color: $color-success; - &:before { + &::before { color: $color-success; content: '\6c'; } @@ -2498,7 +2498,7 @@ table { &.score-negative { color: $color-alert; - &:before { + &::before { color: $color-alert; content: '\76'; } From 0114286e6c4f9ae17b4f1ad819a71bd56f3224b3 Mon Sep 17 00:00:00 2001 From: decabeza Date: Tue, 16 Jan 2018 11:30:58 +0100 Subject: [PATCH 8/8] adds class to improve table on mobile version --- app/views/admin/budget_investments/_investments.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/admin/budget_investments/_investments.html.erb b/app/views/admin/budget_investments/_investments.html.erb index 55ccf7f30..a60e2ac11 100644 --- a/app/views/admin/budget_investments/_investments.html.erb +++ b/app/views/admin/budget_investments/_investments.html.erb @@ -4,7 +4,7 @@ <% if @investments.any? %>

<%= page_entries_info @investments %>

- +
<%= t("admin.budget_investments.index.table_id") %>