This is a bit inconvenient, but you can get the amount the page was scrolled by looking at the offset of the root frame.
Since this is animated into position, the question becomes "when." What I found works when an event with a GotFocused text field is fired, subscribes to the LayoutUpdated event, and when LayoutUpdated is fired, take the offset from there. If you have not subscribed to this event, you can unsubscribe from the LostFocus event. Thus, when you move, you will get changes.
double lastOffset = 0; private void TextBox_GotFocus(object sender, RoutedEventArgs e) { LayoutUpdated += MyControl_LayoutUpdated; } private void MyControl_LayoutUpdated(object sender, EventArgs e) {
After this offset, you can change your controls as needed. You can either reduce the height of the control by this amount, or if you have something small on top, such as a heading, you can apply TranslateTransform by reverse biasing to just push it down.
Deeko source share