Hi All,
In Measurement Widget - click event is firing on "Clear" button even if button is in disable state.
I observed that (jimu-state-disabled) class is only changing element's colour but not preventing any user interaction.
Because of this behaviour, widget is allowing to clear\disable measurement result without finishing drawing (double click on map).
Steps:
1) Select line option on tool.
2) Start drawing line, clink on map
3) Move mouse cursor directly to clear button and click
4) Again click on map.
How can I disable click event when "jimu-state-disabled" class is applied?
One way to check class name and stop code execution but looking for best approach to handle this.
Any help would be appreciated
Regards,
Prashant
Solved! Go to Solution.
Prashant,
You just need to modify the jimu-state-disabled css rule in the apps jimu-theme.css.
.jimu-btn.jimu-state-disabled{
background-color: #adadad;
color: #d8d8d8;
pointer-events: none;
}
Prashant,
You just need to modify the jimu-state-disabled css rule in the apps jimu-theme.css.
.jimu-btn.jimu-state-disabled{
background-color: #adadad;
color: #d8d8d8;
pointer-events: none;
}