Skip to content

mostafa-elabady/ExpandableListView.Xamarin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ExpandableListView.Xamarin

Xamarin forms example for ExpandableListView without any renderers

The idea is very simple, I have a ListView with HasUnevenRows="True" and the ViewCell is CollapsibleControl (A custom ContentView)

<local:CollapsibleControl Title="{Binding Title}" Subtitle="{Binding SubTitle}" SubtitleTextColor="White"
                          HorizontalOptions="Fill" VerticalOptions="Fill">
                          
                <local:CollapsibleControl.ExpandedView>
                  <Grid HorizontalOptions="Fill" VerticalOptions="Fill" Padding="12" BackgroundColor="#e2e2e2">
                    <Grid.RowDefinitions>
                      <RowDefinition Height="Auto"/>
                      <RowDefinition Height="Auto"/>
                    </Grid.RowDefinitions>
                    <Label Grid.Row="0" Text="Details text " FontSize="Small" TextColor="{StaticResource DarkColor}"/>
                    <Label Grid.Row="1" Text="Details text  2 " FontSize="Small" TextColor="{StaticResource DarkColor}"/>
                  </Grid>
                </local:CollapsibleControl.ExpandedView>
                
              </local:CollapsibleControl>

The CollapsibleControl consists of title, subtitle, epand icon, collapse icon, and a frame for the ExpandedView.

Screen shots

Alt text

TODO

  1. Add animation for showing and hiding the content.

About

Xamarin forms example for ExpandableListView without any renderer

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages