[openstreetmap/openstreetmap-website] add "edit" button to mobile version (#2233)
Andy Allan
notifications at github.com
Mon May 20 09:49:44 UTC 2024
I'm sure I've mentioned it elsewhere, but for clarity there is no "mobile version" of the website. The layout of the website (and in this case, the appearance of the edit button) is based on the screen width, so the edit button can appear on mobile devices with wide screens, and it can be hidden on desktops when the browser window is narrow. We also have three different layouts, not just two.
So the choice is at what screen width do we want to show the edit menu, and perhaps what items to we want to show on the edit menu for different widths.
I should also note here that although the layout is based on the screen width, it's also (currently) affected by the language that you are using, since [the different page layouts are currently based on ensuring that the wider menus fit too](https://github.com/openstreetmap/openstreetmap-website/blob/514836a4979b655796190d60aa4bda22f9cdc7f9/app/assets/javascripts/application.js#L77-L87). Finally your username also plays a part, since it's also shown in the top menu - you can give yourself a very long username, and the edit menu will show up only on very wide screens! The exact width at which we transition from the one-column layout (for small screens) to the compact-menu layout is therefore different for different people. I'd like to decouple these at some point, so that the layout is based on screen width directly, and only the menus are based on the menu width.
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/issues/2233#issuecomment-2120090303
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/issues/2233/2120090303 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20240520/cb915218/attachment.htm>
More information about the rails-dev
mailing list