cmv/cmv-app

Direction widget issues on mobile browsers

jefferson3 opened this issue · 1 comments

How often can you reproduce it?

  • Always
  • Sometimes
  • Rarely
  • Unable
  • I didn’t try

Description:

When using any version of CMV on a mobile device the Directions widget will not honor the right-click menu option for "Directions from here" and "Directions to here". Instead it will use the last tapped location on the map regardless of if you tap and hold elsewhere. If you haven't tapped on the map previously it will just do nothing.

Steps to reproduce:

  1. Go to https://demo.cmv.io/ from a mobile device (not a simulator as that doesn't fully represent the mobile experience).
  2. Open the Directions widget in the sidebar to activate.
  3. Close sidebar to view map.
  4. Tap and hold on map and choose one of the directions options

The above will result in no action happening in the Directions widget.

  1. Tap on the map (don't hold)
  2. Tap and hold on map in another location and choose one of the directions options

This will result in the directions widget using the location of step 5, not step 6 like it should.

Expected results:

It should be passing the tap and hold location to the Directions widget.

Actual results:

It either does nothing if the user has not tapped on the map yet, or it uses the last location of a map tap, not the tap and hold location that it should.

I also just noticed that this is the same for the "Identify here" option being passed to the identify widget. Seems to be anything in the right-click/tap-hold menu on mobile devices.

Environment:

Software Version
CMV Version current versions of master and develop
Browser Chrome, Firefox
Operating system Android P, Q

@jefferson3 Thanks for reporting and providing the steps to duplicate. This is definitely a bug. It may be a better approach to use the location of the Menu above the map instead of the clicked point on the map.