-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PB-375: Added drawing to the report a problem #805
Conversation
Passing run #1958 ↗︎Details:
Review all test suite changes for PR #805 ↗︎ |
693a148
to
18c8477
Compare
42e0253
to
4379851
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, did not check the code, but only the test link.
Two minor things:
- when clicking on "Draw on the map" as a first action after clicking on "report a problem", i.e. the text field is still empty, sometimes the app does not switch into the drawing mode but is stuck and complains "Report message can not be empty.". Sometimes it switches into the drawing mode, but the red focus and message still shortly appears.
- Perhaps the text "indicate the appropriate location on the map" is not optimal, as it is not always about a certain location. Maybe something like "Please create the drawing you want to attach" or similar might be better. Picky, I know, sorry! 😉
@hansmannj for the first point regarding field validation I propose to do it in a separate PR as we should change the field validation behaviour globally not only here. The issue is that we validate the field on typing and focus out. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor detail, otherwise looking good!
return !!store.state.layers.systemLayers.find( | ||
(l) => l.id === store.state.drawing.temporaryKmlId | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could be switched to return store.state.layers.systemlayers.some(...)
if the goal is to have a boolean return value
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🥇
LGTM. thanks!
We can discuss e.g. in the refinement tomorrow.
I'd suggest to update the text to "Please create the drawing you want to attach", as the reported problem is not necessarily limitid to one single point, but referring to the whole drawing.
This is needed for the future report a problem that will open the drawing mode and were we don't want to loose the form values (the form is in the menu header).
For this I made the drawing online configurable, which means that the drawing is either online saved (kml backend) and added to the active layers, or local and added to the system layers.
4c5a50f
to
7241d4d
Compare
Avoid overflow in the drawing title which would make the text outside of the header. Currently the header height is fixed which has some issues in the placement of elements.
Note with normal size it works good and on mobile the title is anyway not displayed.
Test link