Describe the bug
Hello! It seems there is an issue with dynamic option updates.
Setting Fancybox.getInstance().getOptions().dragToClose = false after the instance is already initialized does not take effect. Even if I modify the options object of an active instance, the dragging behavior persists.
It looks like the dragToClose event listeners are attached during the initial setup phase and are not re-evaluated or updated when the options object is modified at runtime.
Expected behavior:
The instance should reflect the changes made via getOptions() or provide an update() method to re-bind event listeners based on the new configuration. Or tell me how to turn it on dynamically.
Reproduction
Open a Fancybox instance.
Execute Fancybox.getInstance().getOptions().dragToClose = false; in the console.
Observe that the gallery can still be closed by dragging.
Additional context
No response
Describe the bug
Hello! It seems there is an issue with dynamic option updates.
Setting Fancybox.getInstance().getOptions().dragToClose = false after the instance is already initialized does not take effect. Even if I modify the options object of an active instance, the dragging behavior persists.
It looks like the dragToClose event listeners are attached during the initial setup phase and are not re-evaluated or updated when the options object is modified at runtime.
Expected behavior:
The instance should reflect the changes made via getOptions() or provide an update() method to re-bind event listeners based on the new configuration. Or tell me how to turn it on dynamically.
Reproduction
Open a Fancybox instance.
Execute Fancybox.getInstance().getOptions().dragToClose = false; in the console.
Observe that the gallery can still be closed by dragging.
Additional context
No response