Commit graph

49 commits

Author SHA1 Message Date
Nenad Vujicic
c816efc386 Compacted repeated "Results" into one sentence
Fixes #5065. Removed "Results from" from search results.
2024-08-30 01:54:08 +02:00
Tom Hughes
271384e683 Simplify handling of geocoder URLs
This avoids having to build them in multiple places and also
ensures we link to what was actually searched rather than some
random string from the locale file.
2024-06-25 17:57:38 +01:00
Nenad Vujicic
839d203d51 Added link to nominatim results in searching results
Fixes #3205. Added caching of nominatim URL query parameters in sources global variable (as parameters parameter) in GeocoderController#search for both direct and reverse geocoding. In app/views/geocoder/search.html.erb added displaying cached URL as forwarding link when clicked on "OpenStreetMap Nominatim" label. Updated GeocoderControllerTest to check only name (latlng, osm_nominatim, osm_nominatim_reverse) parameter of new sources variable.
2024-06-19 15:44:56 +02:00
Anton Khorev
adabb735fc Use Bootstrap actionable items in search results lists 2024-04-27 04:17:04 +03:00
Anton Khorev
62ba143c3c Remove some search/directions custom css 2023-10-20 16:58:59 +03:00
Andy Allan
aebac722c2 Rework geocoder titles to avoid raw html in translations 2023-04-02 10:14:00 +01:00
Anton Khorev
28060080e8 Replace spinners in html.erb templates 2022-11-01 00:08:41 +03:00
Andy Allan
c8f0a81eb7 Rework sidebar to use padding on the sidebar_content div
This saves every header, list, paragraph etc having to sort out their own padding. The couple of instances where we want edge-to-edge can be acheived using the negative margin spacing utilities.

The padding is based on $spacer so that it can be adjusted automatically via bootstrap configuration.

This also means that we can remove many (mis-)uses of the browse-section class, which is only supposed to be for cases where there are multiple browse-sections in sequence (e.g. multiple nodes in the node history browse pages).
2021-06-16 15:45:58 +01:00
Andy Allan
c233bec67b Use flexbox to position the close icon on the sidebars
This ensures that the text and the close icon don't overlap, regardless
of the length of the title. The title div grows to use all available
space, while ensuring the text breaks if necessary to prevent it from
pushing the close icon offscreen.
2020-10-21 17:11:28 +02:00
Andy Allan
94008d9059 Fix remaining unstyled buttons by moving to bootstrap buttons 2020-08-19 14:54:36 +02:00
Andy Allan
a3795cddbb Move the search results to use list-group-flush 2020-01-16 12:39:13 +01:00
Andy Allan
8dba8cd4a0 Use _html suffix to avoid using raw when displaying translated strings
This is safer than raw, since any user input is still escaped.
2020-01-02 17:13:41 +01:00
Sam Jenkins
42345cb9b7 Include any current search terms in the page title
Fixes #2336
Closes #2347
2019-08-14 18:58:08 +01:00
Tom Hughes
ecd81eadbe erblint: use parentheses for nested function calls 2019-03-27 18:55:48 +00:00
Tom Hughes
3af16f6337 erblint: fix remaining single quoted strings 2019-03-27 16:15:19 +00:00
Andy Allan
4dd0a74a3b Whitespace fixes to various erb files 2019-03-26 20:23:35 +00:00
Tom Hughes
fdd4361d5b Remove some inline styles 2018-05-16 20:27:35 +01:00
Andy Allan
5bed217823 Use lazy translations where possible 2018-04-25 14:10:59 +08:00
Tom Hughes
80d27a7fae Sanitise parameters used in URL generation 2017-06-02 20:27:07 +01:00
Aaron Lidman
b2a82f501d Float the close icon, closes #40 2013-11-08 12:01:20 -08:00
Aaron Lidman
e7d200c4a6 Sidebar close reverts to 'view' state 2013-11-06 16:59:14 -08:00
Eden Halperin
537d72b0f6 responsive secondary pages and fixed map 2013-11-06 12:57:21 -05:00
Eden Halperin
080236a242 narrower sidebar, transparent minimized state, cleaned up search results 2013-11-05 10:17:58 -08:00
John Firebaugh
8530e3eedb AJAXy changeset history 2013-10-13 14:46:09 -07:00
John Firebaugh
35458c0096 Convert search to pushState 2013-10-13 14:46:08 -07:00
John Firebaugh
a01195f149 Sidebar work 2013-10-13 14:45:58 -07:00
John Firebaugh
aaeca5b534 Use reverse geocoders for any lat/lon queries
This simplifies the implementation, allows code sharing with
"Where am I?", and produces friendlier results for lat/lon
searches (actual reverse geocode results rather than a raw
lat/lon display).
2013-10-13 19:30:38 +01:00
Paul Sladen
25645ed51a Tighten white space usage for geocode "View details" link 2013-09-11 21:47:30 +01:00
Tom Hughes
e84b2bd22f Replace some inline javascript with a UJS solution 2013-05-06 11:09:17 +01:00
Saman Bemel-Benrud
b02844b42f Cleanup followup
Tighter copy on node list for to decrease the chance of an ugly line
break (need better fix here so the line break is smoother). Just changed
also part of way %{related_ways} to part of way %{related_ways}. This
needs a better fix to make line breaks indent properly, but this should
at least help a little (issue #185).

Properly positioned 'nearby users' block on user page to be in the left
column (issue #184).

Removed deemphasized class from search results (issue #181) lighter
highlight yellow on changesets page.
2013-01-16 21:31:05 +00:00
Saman Bemel-Benrud
a36f3558dd Site cleanup
I set out to do a quick and dirty typography overhaul to make things
more consistent and a bit cleaner, but I kept running into things I
didn't like, so this lead me down something of a rabbit hole of design
tweaks to the OSM site.

Goals here are to have better content hierarchy, better vertical
rhythm, more consistent UI, cleaner markup with less tables, all while
keeping the basics pretty much intact. There are a lot of things I
didn't touch even though they need to be updated (lots of tables where
stuff shouldn't be tables, mostly).

Basic overview of changes:

I added a new persistent header that helps segment pages. It's now
a lot easier to know what you're looking at. The header has a page
title, a description, plus a submenu of actions.

There is now a pattern of 20px/10px margins and padding for more
rhythm and breathing room throughout the site.

I know there are other problems here or things I've missed - would
love another set of eyes to look over this! I am still getting comfortable
working on the site - it's my first time ever digging into a ruby or rails
so I'm not familiar with the templating language yet.
2013-01-14 21:27:08 +00:00
Tom Hughes
13289d4041 Switch from Prototype to jQuery 2011-11-26 00:22:31 +00:00
Tom Hughes
22594361d5 Mark some strings that shouldn't be escaped as raw 2011-11-14 09:42:41 +00:00
Tom Hughes
7b37f4cb62 Use link_to and form_tag instead of link_to_remote and form_remote_tag 2011-11-14 09:42:40 +00:00
Tom Hughes
a4b1c178c9 Escape geocoder errors. Closes #2892. 2010-04-19 14:28:03 +01:00
Tom Hughes
4f23e718b4 Add a "More results" link to Nominatim search results. 2010-01-06 00:30:29 +00:00
Tom Hughes
e19c04c7a7 Pass the viewbox to nominatim when possible. 2009-11-10 14:37:46 +00:00
Tom Hughes
639a994c9b Experimental support for reverse geocoding using the new geocoder. 2009-10-30 11:12:55 +00:00
Tom Hughes
06b2d278ea Make the search box load each set of results separately so that one
service being slow doesn't delay the response from others.
2009-07-02 16:12:38 +00:00
Tom Hughes
2e2f212472 Rename views to rails 2 style names. 2009-06-09 20:50:14 +00:00
Andy Allan
c451aa915c i18n geocoder results 2009-05-31 13:12:21 +00:00
Tom Hughes
d2bd78627e More search improvements - a "Where am I?" link that does a reverse
search, and various cleanups to the previous changes.
2007-08-24 18:53:30 +00:00
Tom Hughes
034982a12f If a search only finds one result then jump straight to it instead of
opening a list of results.
2007-08-24 17:38:36 +00:00
Tom Hughes
bb43a46bab Only use the actual name that matched as the link, which helps to highlight it. 2007-08-07 23:51:02 +00:00
Tom Hughes
eb6114617c Add an explicit message when no results are found for a given source. 2007-08-07 23:25:35 +00:00
Tom Hughes
3bae3e6881 Remove old geocoder views and add new one. 2007-08-07 17:14:27 +00:00
Tom Hughes
f7f2b7482d Add the search boxes to the edit page. 2007-06-12 16:51:12 +00:00
Nick Black
a4f4714d0e added a marker to show a location on the map 2007-05-01 13:26:27 +00:00
Nick Black
b6ae16bc83 geocoder stuff - views 2007-05-01 13:24:44 +00:00