How to customize the Shimmer using the custom view property in the .NET MAUI Shimmer (SfShimmer)?
The Syncfusion® .NET MAUI Shimmer (SfShimmer) supports the customization of shimmer using the CustomView property. This article explains how to customize the Shimmer using the CustomView property.
XAML
Initialize the Shimmer and the CustomView property.
<shimmer:SfShimmer>
<shimmer:SfShimmer.CustomView>
</shimmer:SfShimmer.CustomView>
</shimmer:SfShimmer>
XAML
Customize the Shimmer with the help of the BoxView class.
<BoxView Grid.Row="0"
Grid.ColumnSpan="2"
HorizontalOptions="Start"
WidthRequest="250" />
<BoxView Grid.Row="1"
Grid.ColumnSpan="2"/>
<BoxView Grid.Row="2"
Grid.RowSpan="3" />
<BoxView Grid.Row="2"
Grid.Column="1"
HeightRequest="20"
HorizontalOptions="Start"
VerticalOptions="Start"
WidthRequest="100" />
<BoxView Grid.Row="3"
Grid.Column="1"
HeightRequest="10"
HorizontalOptions="Start"
VerticalOptions="Start"
WidthRequest="100" />
<BoxView Grid.Row="4"
Grid.Column="1"
HeightRequest="10"
HorizontalOptions="Start"
VerticalOptions="Start"
WidthRequest="100" />
<BoxView Grid.Row="5"
Grid.Column="1"
HeightRequest="10"
HorizontalOptions="Start"
VerticalOptions="Start"
WidthRequest="100" />
<BoxView Grid.Row="6"
Grid.ColumnSpan="2"
HeightRequest="10"
HorizontalOptions="Start"
VerticalOptions="Start"
WidthRequest="190" />
<BoxView Grid.Row="7"
Grid.ColumnSpan="2"
HeightRequest="10"
HorizontalOptions="Start"
VerticalOptions="Start"
WidthRequest="170" />
Download the complete sample on GitHub
Output:
Conclusion
I hope you enjoyed learning how to customize the shimmer using the CustomView property in .NET MAUI Shimmer (SfShimmer).
Refer to our .NET MAUI Shimmer’s feature tour page for its other groundbreaking feature representations. You can also explore our .NET MAUI Shimmer documentation to understand how to present and manipulate data.
For current customers, check out our .NET MAUI components from the License and Downloads page. If you are new to Syncfusion®, try our 30-day free trial to check out our .NET MAUI Shimmer and other .NET MAUI components.
Please let us know in the following comments section if you have any queries or require clarifications. Contact us through our support forums, Direct-Trac, or feedback portal. We are always happy to assist you!