Describe the bug
when creating the observer like
<div use:reveal={{ transition: "fly", debug: true, ref: "a", threshold: 0.2, marginBottom: 100, marginTop: 100 }}>
the lib options (transition, x, debug, ref, ...) are correctly used, but the Observer options (threshold, marginBottom, ...) are ignored.
This is I guess due to passing config.observer
directly in createObserver()
instead of creating an object with the user's parameters.
Changing the Observer options through the API (setObserverThreshold, setObserverRootMargin, ...) works fine.
Reproduction
<div use:reveal={{ transition: "fly", debug: true, ref: "a", threshold: 0.2, marginBottom: 100, marginTop: 100 }}>
the applied threshold will be the default 0.6 instead of the desired 0.2. Same for margins and root.
System Info
this is not system-dependant
Severity
Serious, but I can work around it
Additional Information
No response