Hello!
I am currently in the process of migrating our widgets to the new web components.
While migrating the Sketch Widget, I ran into an issue. I do not see any option anymore to set the SketchValueOptions. We use the valueOptions to change the units for the tooltip to nautical-miles like this:
This only works with SceneViews, but we use a MapView.
I could not find any unit options that only apply to the sketch component directly.
Could you please help me out there?
The documentation doesn't explain this very well, but all the properties and functions of a Widget should still be accessible in a Component through JavaScript. You just need to use the document.getElementById() method to capture the DOM node of the Component. That DOM node is for all practical purposes the Widget.
const sketchWidget = document.getElementById('sketchComponentId')
sketchWidget.valueOptions = myValueOptions
Hello @Insa_bel ,
We are adding this prop to Sketch component in the 5.2 release. We were making some modifications to the SketchValueOptions. I apologize for the inconvenience this has brought for not having this available sooner.
Thanks,
Jose