Comments (9)
@vogelino thanks, this looks great!
I have two comments:
Link
const OSM_PUMP_EDITOR_URL =
https://mapcomplete.osm.be/theme?z=14&lat=52.51486&lon=13.44662&userlayout=https%3A%2F%2Ftordans.github.io%2FMapComplete-ThemeHelper%2FOSM-Berlin-Themes%2Fman_made-walter_well-status-checker%2Ftheme.json&language=de#node`;`
The URL has the lat/lon/zoom hard coded which will make the map jump and reload data AFAIK.
Do you have access to the those map props inside the panel? We could then do something like…
const mapCompleteURL = ({lat, lon, zoom, nodeId}) => {
const mapcompleteUrl ='https://mapcomplete.osm.be/theme'
const params = new URLSearchParams()
params.set('userlayout', 'https://tordans.github.io/MapComplete-ThemeHelper/OSM-Berlin-Themes/man_made-walter_well-status-checker/theme.json')
params.set('lat', lat)
params.set('lon', lon)
params.set('z', zoom)
params.set('language', 'de')
const selectedPump = `#node/${nodeId}`
return `${mapcompleteUrl}?${params.toString()}${selectedPump}
}
Wording
OpenStreetMap PumpenInfos bearbeiten
I think we can focus this a bit more on the operational status of the pump, since this theme will only allow editing those fields to keep it simple.
How about
Status in OpenStreetMap aktualisieren
or
Status und check in OpenStreetMap aktualisieren
Ping @SupaplexOSM FYI
from giessdenkiez-de.
Hi @tordans. I changed the wording and ported your URL function to our code. However, wenn encoding the latitude and longitude into the URL, the OSM page doesn't load the pumps initially when opened via link but does when entered in the browser search bar. I cannot figure out why this happens. When omitting the lat/lng/zoom, the page loads correctly when opened by zoom. Any idea why this happens?
PS: This PR #466 includes the changes
from giessdenkiez-de.
Hey @tordans Thank you for your editor. We will discuss internally how to handle this.
from giessdenkiez-de.
Hi @tordans! Great editor! This will make it way easier for people to contribute to better pump information! Thx a lot!
I created a PR #461 based on your comment but with a slightly different UX. Instead of double clicking (Which is IMHO not very intuitive), the tooltip can be stuck by clicking once on a pump. This way the new link "Edit this OSM info" in the tooltip can be reached.
Let me know what you think! :)
Screen.Recording.2022-06-23.at.17.08.12.mov
from giessdenkiez-de.
@tordans thx for your feedback. These are very good points.
I think we do have those coordinates at this point and we should be able to encode them into the url as suggested.
I also agree with your wording feedback and I root for the first suggestion. @Esshahn what do you think?
I will take care of it next week but feel free to do a PR against staging if you wish us to accelerate the process.
Have a nice weekend!
from giessdenkiez-de.
I tested with https://mapcomplete.osm.be/theme.html?userlayout=https%3A%2F%2Ftordans.github.io%2FMapComplete-ThemeHelper%2FOSM-Berlin-Themes%2Fman_made-walter_well-status-checker%2Ftheme.json&language=de#node/5907103888 and it looks like, the lat/lng is not needed at all. I think MapComplete does a lookup of the node first (or early on during render) and then moves the map to this lat/lng right away.
So it look like this is all we need, right (AKA the PR is fine this way)? — I might be missing something …
from giessdenkiez-de.
PS: Is the staging URL public so I could test it there (later)?
from giessdenkiez-de.
Cool! I see it the same way. Yes the PR is fine. Here is the URL: https://deploy-preview-462--giessdenkiez.netlify.app/
from giessdenkiez-de.
FYI, I just twittered about this https://twitter.com/osmberlin/status/1546020018856534016.
And this OSMCha list shows all edits made with the editor. RSS
from giessdenkiez-de.
Related Issues (20)
- [Suggestion] Option to show all adopted trees in the map HOT 2
- [Bug] Homepage is always loading twice: first loading, then login, then again loading; this takes a lot of time and wastes resources HOT 2
- [Verbesserungsvorschlag] Feedback Link (github) besser platzieren HOT 1
- [Verbesserungsvorschlag] Laufende Wässerungssumme über 7 und über 30 Tage anzeigen HOT 2
- Test new DB with NextJs version of the App HOT 3
- Test new DB on Vercel Preview HOT 2
- Update Material UI 4 to 5 HOT 1
- Browserslist: caniuse-lite is outdated.
- Remove project from Netlify HOT 2
- Remove maintenance banner from frontend
- Update docs (Next.js instead of CRA) HOT 1
- function getWatered is not used? HOT 3
- Initial map settings should be dynamic
- Env variables in tests should not be hidden if possible HOT 2
- Use Supabase Storage feature for serving (semi-)static data
- Ordering of list of last waterings should be fixed HOT 2
- Bug: Blue location circle prevents from clicking on an underlying tree
- semantic-release is not altering the package.json
- DWD Harvester action is failing HOT 2
- Reintroduce Link to OSM water well editor HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from giessdenkiez-de.