-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add bindings for VisualViewport
#3931
Add bindings for VisualViewport
#3931
Conversation
@DanielleHuisman I noticed |
@rustwasm How does this look to you? |
In the meanwhile, I'll use a fork. But I'm not clear on the syntax. What do I write in |
I've answered my own question. First Attempt (Not Enough)If one only specifies the git repository of a fork in
SolutionInstead as recommend (see links at bottom), the With that in mind, here is how I use my fork of [package]
name = "project-name"
version = "0.1.0"
edition = "2021"
[dependencies]
console_error_panic_hook = "0.1.7"
wasm-bindgen = { version = "0.2.92" }
web-sys = { version = "0.3.69", features = [
"Document",
"Element",
"VisualViewport",
"Window",
] }
[patch.crates-io]
wasm-bindgen = { git = "https://github.com/xpe/wasm-bindgen", branch = "feature/visual-viewport" }
web-sys = { git = "https://github.com/xpe/wasm-bindgen", branch = "feature/visual-viewport" } Relevant docs and issues |
@Liamolucko @daxpedda I'm not sure who the maintainers are, but I see that you both are recent active contributors, so I thought it might be wise to reach out. Could you help @DanielleHuisman and I get this PR merged? Much appreciated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Could you add a changelog entry?
1c049eb
to
544c0e1
Compare
I added a changelog entry. Hope it's all good now :) |
Add bindings for
VisualViewport
(MDN, specification).I think the comment about
SameObject
abovewindow.screen
might also apply towindow.visualViewport
. For now, I just copied the IDL from the specification.