-
Notifications
You must be signed in to change notification settings - Fork 751
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
[WASM] Element with bottom or right margin in ScrollViewer
cannot be scrolled to the end
#7000
Comments
…by putting the Content in an empty Border that serves as a wrapper. ScrollContentPresenter.ArrangeOverride has been updated to check for this workaround and test for a custom ViewPort accordingly.
…by putting the Content in an empty Border that serves as a wrapper. ScrollContentPresenter.ArrangeOverride has been updated to check for this workaround and test for a custom ViewPort accordingly.
…by putting the Content in an empty Border that serves as a wrapper. ScrollContentPresenter.ArrangeOverride has been updated to check for this workaround and test for a custom ViewPort accordingly.
Yeah, just ran into this as well on WASM, think it's the same as #6443. It can be reproduced in the Uno Playground Textblock example too. Just add I can confirm the same workaround of putting a blank border around the StackPanel in the Uno Playground also shows the correct expected behavior. |
Investigated the issue today with @agneszitte-nventive ... this is actually an expected behavior of browser: neither the padding of the scrolling parent element nor margin of the child is taken in consideration by the browser when it computes extents (https://stackoverflow.com/questions/11695354/css-right-margin-does-not-work-inside-a-div-with-overflow-scroll). To fix this issue we do have to insert a wrapping element. This could be a "managed element" injected dynamically by the SV like the Another solution would be to inject a "DOM only" Note: This bug will be fixed by #8210 for top and left margin. The issue remain valid only for right and bottom margins on WASM! For those cases, the workaround remains valid.
|
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
#8210 related PR in order for the content margin to be taken into consideration for Skia entirely and top|left margin for WASM. (Note for WASM: bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed for this issue. Referring to @dr1rrb details above. You can use the easy workaround of surrounding the element with a Border without margin inside the SrollViewer until then.) |
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
…r Skia and WASM. (Note for WASM; bottom or right margin in ScrollViewer cannot be scrolled to the end still need to be fixed with issue #7000)
Note for contributorsThese changes will need to be updated when this bottom/right margin issue is fixed for WASM (comments with details left in the code).
(cc @jeromelaban / @dr1rrb ) |
ScrollViewer
cannot be scrolled to the end
Simple repro for this - http://playground.platform.uno/#88b23fc2 |
Current behavior
If you put an element with a bottom or right margin as
Content
of aScrollViewer
, then the element won't be fully scrollable.Expected behavior
🙃
How to reproduce it (as minimally and precisely as possible)
We cannot see the bottom and right borders.
Workaround
Surround the element with a
Border
without margin:Works on UWP/WinUI
Yes
Environment
Uno.UI / Uno.UI.WebAssembly / Uno.UI.Skia
NuGet package version(s)
3.10.0-dev.632
Affected platforms
WebAssembly
Skia (WPF), Skia (GTK on Linux/macOS/Windows), Skia (Tizen)IDE
No response
IDE version
No response
Relevant plugins
No response
Anything else we need to know?
Most probably also affects macOS
Work on Android
Not validated on iOS
The text was updated successfully, but these errors were encountered: