Commit graph

78 commits

Author SHA1 Message Date
Andy Allan
a9a00acf68 Fix italic font styles
This was missed during the bootstrap 5 upgrade
2022-08-03 19:49:46 +01:00
Andy Allan
934d81aa55 Bootstrap 5: Replace all form-group classes with mb-3 2022-07-20 14:42:57 +01:00
Tom Hughes
cbcc7dc49f Fix some rubocop Naming/PredicateName warnings 2022-03-03 22:47:55 +00:00
Andy Allan
675f72fe35 Use flex grid to position changeset discussion subscribe button
This avoids needing any floats. Also remove buttons class from two
locations, since there is a min-width on that class and it affects
the button styling negatively for standalone buttons
2021-11-24 12:24:16 +00:00
Andy Allan
300cd884ec Use flex grid instead of floating to position changeset element paging nav
This works much better when either the heading or the paging is long.

The heading was moved into the partial to avoid repetitive grid definitions
2021-11-24 12:07:49 +00:00
Andy Allan
2b84452222 Remove custom margins on sidebar headings
Margin-top in particular is best avoided. The removal of some top
margins required a few corresponding changes to add bottom margins
to other features, mostly done by converting bare text strings to
live within paragraphs.
2021-11-03 18:16:38 +00:00
Tom Hughes
1bc1905248 Restore browse-section class to changeset view
Fixes #3234
2021-06-25 20:26:51 +01: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
Tom Hughes
01b84a8107 Merge remote-tracking branch 'upstream/pull/3125' 2021-03-10 14:55:58 +00:00
Andy Allan
38ad8fbc36 Use login_path instead of explicit controller and actions
This makes future refactoring easier.
2021-03-10 14:31:55 +00:00
Andy Allan
926576881f Remove final uses of the deemphasize class 2021-03-03 15:51:11 +00:00
Andy Allan
8ee31df2a0 Rework changeset comments form to use bootstrap styling 2021-02-10 10:55:41 +00:00
Andy Allan
78b9d92207 Prefer keyword arguments when method has optional boolean arguments 2020-11-12 11:24:44 +00:00
Tom Hughes
e9ad6d852c Merge remote-tracking branch 'upstream/pull/2901' 2020-10-21 20:51:03 +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
2559226be3 Avoid various uses of html_safe
We can avoid using `html_safe` in various circumstances, through alternative approaches like i18n keys ending in `_html` or using `safe_join` to avoid converting via unsafe string types.

The `_html` keys approach only work for ActionView helper version of `t`, not the base `I18n.t` method.
2020-10-21 15:43:14 +02:00
Andy Allan
a988ad6f51 Style changeset descriptions with italics on browse pages
Alternative to #580

This reworks changeset descriptions to use italics instead of header
elements, in order to make them more like quotes.

Care has been taken to make sure that there is still a header element
as the first element of the common details partial, in order to make
the history pages look right (where the partial appears multiple times).
2020-09-16 18:51:20 +02:00
Tom Hughes
c24c2e481c Merge remote-tracking branch 'upstream/pull/2667' 2020-08-05 21:50:08 +01:00
Andy Allan
1977e66ace Use bootstrap text-muted in place of custom deemphasze class
This avoids changing anything related to forms, since they will be
switched over to bootstrap separately.
2020-07-08 18:30:15 +02:00
Andy Allan
627f2493fa Refactor away from global form control styling
This enables forms to be converted one-by-one to bootstrap. Without this
refactoring, these global styles interfere with form control styling from
bootstrap.

The rearrangement of the search and directions styling is to solve CSS selector specitivity issues.
2020-07-01 17:23:02 +02:00
Tom Hughes
a13b40ace9 Fix new erblint warnings 2020-06-11 19:44:22 +01:00
Andy Allan
b8c1bbb4f8 Remove unnecessary h() calls on model attributes
These were necessary in the rails 2.x era, but not now.
2020-03-18 14:33:30 +01:00
Andy Allan
e22b9c35f5 Remove list styling from various sidebar lists 2020-01-30 13:14:53 +01:00
Andy Allan
65c3c2a915 Remove list style reset, and add overrides where necessary
This allows the bootstrap list typography to work without being overridden. It also means
that lists look like normal lists by default, instead of needing to be recreated from
scratch each time. Only the cases where padding and discs are unwanted need to have
custom CSS.
2020-01-15 17:16:11 +01:00
Andy Allan
827123a8f6 Rework changeset descriptions to use h6 tags, and refactor changeset lists to use list-group-flush
The descriptions are probably best not as a header, but still needs to be something more prominent than surrounding text.
2020-01-08 16:04:45 +01:00
Andy Allan
3167e6b4bb Use friendly_date_ago helper for chnagesets
Refs #2255
2019-06-19 18:04:08 +02:00
Tom Hughes
7ce40eeb38 erblint: use consistent spacing in HTML tags 2019-03-28 00:30:48 +00:00
Tom Hughes
49da87fb6d erblint: remove leading blank lines 2019-03-28 00:29:04 +00:00
Tom Hughes
3af16f6337 erblint: fix remaining single quoted strings 2019-03-27 16:15:19 +00:00
Andy Allan
74b91c0e3e erblint: Add or remove curly braces around hash parameters as required 2019-03-27 10:30:48 +01:00
Andy Allan
3c410bcd7e Whitespace fixes for browse erb files 2019-03-26 20:23:35 +00:00
Andy Allan
1778fa3d9c Move the api methods from changesets_controller into the api namespaced controller 2019-02-24 12:18:31 +01:00
Andy Allan
8a2df0e0b5 More resourceful routing for nodes, ways, relations and changesets controllers 2019-01-16 13:10:11 +01:00
Andy Allan
252b9ef08a Pluralize changesets controller 2018-11-14 10:34:28 +01:00
Andy Allan
3ec67ea2d3 Rename user_controller to users_controller 2018-10-03 15:31:10 +02:00
Tom Hughes
5a2d2f97ce Update changeset browse view for renaming of changeset#list to changeset#index 2018-09-09 12:36:34 +01:00
Andy Allan
e1c62f1bf2 Remove if_user and similar methods
Rather than hiding features based on CSS, just avoid including them
in the output. Fixes #1862
2018-05-16 13:05:20 +08:00
Andy Allan
5bed217823 Use lazy translations where possible 2018-04-25 14:10:59 +08:00
Andy Allan
9f84c6f46e Use user_path links. Fixes #1785 2018-03-21 11:33:45 +08:00
mmd-osm
965123372d Added explanation about discussions on open changesets
Closes #1705
2017-12-18 21:19:35 +00:00
Andy Allan
c819bec8b7 Use a current_user helper for accessing the logged in user in all views. 2017-07-27 10:07:51 +01:00
Simon Legner
f3fa97fc63 Wrap user name in bdi to provide a separate RTL context
Fixes #1179
Closes #1183
2016-03-14 21:20:03 +00:00
Tom Hughes
18b8fc60bb Add rel=nofollow to links to tagless nodes in browse pages 2015-12-20 00:19:16 +00:00
Tom Hughes
316ebb7570 Don't pass ActiveRecord objects to find and exists? 2015-01-10 12:41:16 +00:00
Łukasz Gurdek
14ac1babc2 Changeset discussions
Add support for commenting on changesets with RSS feeds and email
notification of comments to other commenters and people that have
chosen to subscribe to a changeset.
2014-10-23 21:24:51 +01:00
Tom Hughes
5da273027f Isolate object names from the database with a <bdi> tag
Fixes #743
2014-05-18 17:24:38 +01:00
Tom Hughes
5c53bb78ab Don't linkify comments in the changeset list
It's confusing to make links in comments active in the changeset list
as the rest of the comment is an active link to the changeset.

We do want to make them active in the changeset view however, so add
linkification to the comment there.

Fixes https://trac.openstreetmap.org/ticket/5061
2013-12-08 13:11:48 +00:00
John Firebaugh
954261fb1c Restore prev/next changeset by user links 2013-11-22 12:17:27 -08:00
Aaron Lidman
f45437f836 Reorder changeset detail lists
Nodes, ways, relations -> Ways, relations, nodes
2013-11-18 16:24:25 -08:00
John Firebaugh
9dd230d0bc Refactor browse templates 2013-11-12 13:22:55 -08:00