Commit graph

66 commits

Author SHA1 Message Date
Andy Allan
f3a4443120 Remove unusual margins and line-height from comments
This allows them to follow normal conventions used elsewhere, as
well as removing some custom css.
2023-09-13 13:18:30 +01:00
Anton Khorev
d69ae84963 Add color keys to note tables 2023-08-17 19:26:26 +03:00
Anton Khorev
a4b8a91821 Use Bootstrap highlight class in note tables 2023-08-10 21:16:26 +03:00
Andy Allan
c276625e7f Refactor to use submit_tag helper
This is more readable than interpolating into element attributes
2023-02-01 17:24:48 +00:00
Andy Allan
a88da1d71a Refactor translation strings for notes
These aren't used by any javascript code, so don't need to be in
the `javascripts` key.
2023-02-01 17:24:48 +00:00
Andy Allan
9bb8dd739a Use data attributes to pass alternative button labels
This allows the text to be defined in the html partials, instead
of looking up the i18n via javascript.
2023-02-01 17:24:47 +00:00
Andy Allan
9748ce301c Move browse#note to notes#show
This allows a more resourceful routing approach.
2023-02-01 17:13:41 +00:00
Andy Allan
b5046fdcd0 Move browse#new_note to notes#new
This allows a more resourceful routing approach.
2023-02-01 17:13:41 +00:00
Andy Allan
75749cc540 Convert remaining heading titles to use h1
This makes them consistent with all the other pages that use h1
in the `content_for :heading` sections
2021-11-11 15:12:23 +00:00
Harry Wood
de8ee536b1 Display no notes message when empty
Display a 'No notes' message when there are no notes to display, rather than an empty table with pagination features.
2021-04-09 19:21:09 +01:00
Andy Allan
41d6f19a6b Rename the notes#mine action to index 2020-07-08 18:43:30 +02:00
Andy Allan
055a976051 Remove custom table styling
This removes the custom table styling code, and move to using bootstrap table styling for almost all remaining tables.
2020-04-01 12:29:01 +02:00
Andy Allan
13f0591605 Wrap table header rows in thead 2019-12-11 17:22:23 +01:00
Andy Allan
220ad92766 Use friendly_date_ago for notes display
Refs #2255
2019-06-19 18:04:08 +02:00
Andy Allan
22c1be4db7 Set image dimensions in order to avoid a reflow after the page is drawn by the browser 2019-03-27 18:05:44 +01:00
Andy Allan
a5f4124681 Refactor notes#mine to simplify code 2019-03-27 18:04:44 +01: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
b4dbf6233c Move the notes api methods into a controller in the api namespace 2019-02-28 17:12:28 +01:00
Andy Allan
686fee43bf Use full list of osm xml root attributes in builder templates 2019-01-09 14:15:39 +01:00
Andy Allan
252b9ef08a Pluralize changesets controller 2018-11-14 10:34:28 +01:00
Andy Allan
dfa2fd7d3d Rename note to notes in i18n lookups
Enables lazy translation lookups for most cases. Additionally, rename
keys for notes.description.* to notes.comment.* to match partial
name.
2018-04-25 14:56:20 +08:00
Andy Allan
9f84c6f46e Use user_path links. Fixes #1785 2018-03-21 11:33:45 +08:00
Tom Hughes
fe1e28b4f4 Fix more parameter sanitisation issues and add tests 2017-06-29 20:52:57 +01:00
Andy Allan
396f2e28dd Rework coordinates to avoid scientific formatting of small numbers. Fixes #1509 2017-06-23 14:03:57 +01:00
Tom Hughes
425f3f309b Use created at for RSS format with note#show
This matches other formats and is also what the tests expect.
2017-02-20 08:50:56 +00:00
Tom Hughes
34c473f503 Use only_path instead of setting an explicit host 2016-11-24 20:33:36 +00:00
Andy Allan
1e3a35f971 Add missing xmlns:dc for notes rss 2016-11-24 17:47:16 +00:00
Andy Allan
968447595b Use dc:creator for note RSS feeds
The author tag is reserved for email addresses
2016-10-29 17:14:56 +02:00
Andy Allan
38e12759ea Rubocop autofixes. 2016-09-07 11:07:42 +01:00
Markus Heidelberg
166dc76ae9 Make notes GPX valid and add useful official elements
The "creator" attribute is required and "extensions" is the correct
name of this element.

Validated with SAXCount from the xerces-c package:

$ SAXCount -v=always -n -s -f notes.gpx

Original error messages:

    Error at file /home/markus/notes.gpx, line 2, char 171
      Message: no declaration found for element 'gpx'

    Error at file /home/markus/notes.gpx, line 2, char 171
      Message: attribute 'version' is not declared for element 'gpx'

After adding the "xmlns" attribute:

    Error at file /home/markus/notes.gpx, line 2, char 213
      Message: missing required attribute 'creator'

    Error at file /home/markus/notes.gpx, line 18, char 14
      Message: no declaration found for element 'extension'

    Error at file /home/markus/notes.gpx, line 26, char 7
      Message: element 'extension' is not allowed for content model '(ele?,time?,magvar?,geoidheight?,name?,cmt?,desc?,src?,link*,sym?,type?,fix?,sat?,hdop?,vdop?,pdop?,ageofdgpsdata?,dgpsid?,extensions?)'

The current errors now are caused by the missing XML schema for the
extensions.

Also add the time, name and link elements.
2015-08-10 19:11:18 +01:00
Tom Hughes
a34935df9b Fix a missing translation 2015-07-23 14:23:23 +01:00
Tom Hughes
6886a149b2 Use correct translation for new notes in RSS feed 2015-07-23 13:50:28 +01:00
Tom Hughes
965fb0b3ae Revert "Fix off-by-one error in user notes list"
This reverts commit 706454ae35.
2014-07-26 10:34:57 +01:00
Toby Murray
706454ae35 Fix off-by-one error in user notes list 2014-07-24 22:30:36 +01:00
Kai Krueger
f3d5a215ad Return "action" of a note comment in the xml formatting to
This fixes #360
2013-07-29 21:23:47 +01:00
Tom Hughes
d6d366ad2b Report reopened notes properly in the RSS feed 2013-07-03 17:42:04 +01:00
Tom Hughes
5efe07f164 Use note.closed? in a consistent way 2013-06-11 18:26:54 +01:00
Tom Hughes
1d7719e01c Make note metadata consistent in the GPX output format 2013-06-11 18:23:52 +01:00
Tom Hughes
d74d4f8d19 Add a reopen API call for notes 2013-06-10 18:52:50 +01:00
Tom Hughes
80f48e812f Make user links in note API responses use the main server name 2013-05-28 22:26:46 +01:00
Tom Hughes
fa95768ae3 Use dc:creator instead of author for the author's name
Unfortunately the braindead RSS speciifcation requires author to
be an email address, so we have to use Dublin Core metadata to
report the author name instead.
2013-05-24 09:16:28 +01:00
Tom Hughes
692d57744f Add comment numbers to GUIDs to make them unique 2013-05-24 09:11:59 +01:00
Tom Hughes
42b3f961a6 Use CDATA for note descriptions in the RSS feed 2013-05-07 11:30:13 +01:00
Tom Hughes
621cb8a1ef Fix double escaping of date markup in note feed 2013-05-07 11:23:56 +01:00
Tom Hughes
5dda4196d5 Rework the generation of descriptions in the notes RSS feed 2013-04-26 19:34:32 +01:00
Tom Hughes
6e33cf0871 Fix exception with GPX and RSS notes#index when no notes are found 2013-04-24 19:17:13 +01:00
Tom Hughes
273ae4c729 Wrap XML notes responses in an <osm> wrapper 2013-04-24 18:18:20 +01:00
Tom Hughes
36bd2468e0 Fix exeption in GeoRSS formatting for notes 2013-04-24 10:20:35 +01:00
Tom Hughes
925bd812a2 Fix exception with XML notes#index when no notes are found 2013-04-24 09:41:08 +01:00