Open xarvic opened 1 year ago
Please rebase on master
so we can pass the CI without unrelated clippy errors. Also please run cargo fmt
.
Additionally, please give a short description of what the purpose of the ViewportHeader
widget is. I see that there is an example, which is excellent. I'll check that out when we pass CI.
@xStrom i edited the description of the ViewportHeader widget and also improved the example.
Add functionality based on the
ViewContextChanged
lifecycle event, which provides widgets with information about the viewport.The
ViewportHeader
widget has a header child and a content child and moves the header over the content if this helps to keep the header inside the viewport. This way the header widget sticks to the border of the viewport. For an example this is useful if you have multiple large widgets in a scroll view and always want to know which element you are currently looking at.ScrollToView
request also work, since theViewportHeader
widget intercept and transforms the requests.The Align widget gains the ability to only consider its visible part for aligning its child.