Взгляните на это удивительное Видео от Xamarin. Формы, объясняющие, как работают анимации, А вот документация
Но вот что вам нужно do:
1º - добавление события Clicked к кнопке и идентификатора для метки
<Button Clicked="OnButtonClicked" />
<Label x:Name="labelAnimated">
2º - в OnButtonClicked в CodeBehind добавьте анимацию
//Make the method async so you won't block the UI
async void OnButtonClicked(object sender, EventArgs args)
{
await labelAnimated.TranslateTo (-100, 0, 1000); // Move image left
await labelAnimated.TranslateTo (-100, -100, 1000); // Move image up <- you are looking for this one
await labelAnimated.TranslateTo (100, 100, 2000); // Move image diagonally down and right
await labelAnimated.TranslateTo (0, 100, 1000); // Move image left
await labelAnimated.TranslateTo (0, 0, 1000); // Move image up
}
Теперь, чтобы достичь того, что вы искали, я сделал это так:
<Grid>
<Grid x:Name="ContentThatWillBeShifted">
//Any type of content you want, Label, Buttons, Images (in the example used images and a label)
</Grid>
<Grid>
//This Content is Overlapping the other content
<StackLayout BackgroundColor="Blue">
<Button Clicked="OnButtonClicked">
</StackLayout>
</Grid>
</Grid>
async void OnButtonClicked(object sender, EventArgs args)
{
await ContentThatWillBeShifted.TranslateTo(0, 200, 1000, Easing.BounceOut);
}
Результат: