atk4 / ui

Robust and easy to use PHP Framework for Web Apps
https://atk4-ui.readthedocs.io
MIT License
440 stars 105 forks source link

Fix Lookup initial change detection #2092

Closed mkrecek234 closed 8 months ago

mkrecek234 commented 1 year ago

fix #2020

mvorisek commented 1 year ago

canLeave feature needs Behat tests

mkrecek234 commented 1 year ago

Would be nice to have behat tests for canLeave (but then for ALL form controls which is an overkill for this PR to merge) - this should not prevent merging this. If you read FUI documentation, it is clear that lookup was wrongly initialized before which is fixed now. Would be welcomed if you could contribute it if you consider it compulsory here

mkrecek234 commented 11 months ago

@atk4/trusted-maintainers Can someone help providing the tests that @mvorisek requests for this PR to merge? This is a simple bug introduced which is fixed by the above PR. Very annoying as forms today will always prevent to be left when a lookup control is present. Thank you contributors!

mvorisek commented 8 months ago

The change looks correct:

docs: https://github.com/fomantic/Fomantic-UI/blob/2.9.3/src/definitions/modules/dropdown.js#L2687 (and https://fomantic-ui.com/modules/dropdown.html#behavior)

@mkrecek234 did you manage to get Behat working locally as discussed on Discord?

mkrecek234 commented 8 months ago

Unfortunately no time, @mvorisek - but can confirm that the change is 100% correct, fixing the issue correctly and according to Fomantic UI specs.

mvorisek commented 8 months ago

I have merged it, it does not worsen coverage but be aware it can break anytime as no tests.