haxeui / haxeui-html5

The HTML5 backend of the HaxeUI framework -
http://haxeui.org
MIT License
28 stars 14 forks source link

Mouseover on native checkbox throws Uncaught TypeError #27

Closed ArgosOz closed 3 years ago

ArgosOz commented 6 years ago

This is a custom component.

<hbox id="hboxRight"> 
        <checkbox native="true" selected="true"/>
        <label text="Native checkbox" style="margin-left:-6px; margin-top:2px; "/>        
</hbox>

Expected Behavior

No error.

Current Behavior

Throws an Uncaught TypeError: Cannot read property 'addClass' of null onMouseOver. Throws an Uncaught TypeError: Cannot read property 'removeClass' of null onMouseOut.

Steps to Reproduce (for bugs)

Edit: Add -debug flag and rebuild the project using build-html5.hxml. Go bin directory and open the index.html, activate devtools then move your mouse pointer over the checkbox.

Test app / minimal test case

Here is the example project to reproduce the error: HaxeUI.zip

Your Environment

ianharrigan commented 6 years ago

I couldnt actually reproduce this, but i have made a number of changes to optionboxes and checkboxes that i think will fix this - can you retest and close as appropriate?

Cheers.

PS: checkbox comes with its own label control, so you dont need to create one: <checkbox text="Native" ... ... /> (same with optionbox)