계층적으로 콘텐츠를 정리하는 데 적합한 그룹화된 목록을 만들 수 있게 해주는 플러터 패키지입니다. 접을 수 있는 섹션과 스틱 헤더를 지원하며, Sliver 위젯과 원활하게 통합되어 CustomScrollView와 같은 사용자 지정 스크롤 뷰에서 사용하기에 적합합니다. Android, iOS, Web, macOS, Windows, Linux 등 모든 주요 플랫폼을 지원하며 장치 간 일관된 경험을 제공합니다. 최소한의 보일러플레이트 코드로 복잡한 리스트 상호작용을 단순화합니다.
사용 사례
그룹화된 데이터 표시
접을 수 있는 섹션 목록
스티키 헤더 탐색
사용자 정의 스크롤 뷰
동적 콘텐츠 구성
긴 목록을 위한 개선된 사용자 인터페이스
주요 기능
확장 가능/접을 수 있는 섹션
스티키 섹션 헤더
Sliver 위젯 호환성
크로스 플랫폼 지원
필요한 설정 최소화
부드러운 애니메이션
적합한 대상
복잡한 목록을 구축하는 개발자
인터랙티브 레이아웃이 필요한 UI 디자이너
계층적 데이터를 가진 앱
헤더가 있는 스크롤 가능한 인터페이스
모바일 및 웹 애플리케이션
고려 사항
Sliver 위젯에 대한 이해가 필요합니다
매우 큰 데이터 세트에서는 성능에 영향을 줄 수 있습니다
기본 스타일링을 넘어서는 사용자 정의가 제한적
중간 규모의 그룹화된 데이터에 가장 적합
간단한 평면 목록에 권장되지 않습니다
원본 README
연결된 소스 저장소의 README 원문 스냅샷입니다. 최신 내용은 저장소에서 확인하세요.
sticky_and_expandable_list
Flutter implementation of sticky headers and expandable list.Support use it in a CustomScrollView.
Build a grouped list, which support expand/collapse section and sticky header.
Use it with CustomScrollView、SliverAppBar.
Listen the scroll offset of current sticky header, current sticky header index and switching header index.
Only use one list widget, so it supports large data and a normal memory usage.
More section customization support, you can return a new section widget by sectionBuilder, to customize background,expand/collapse animation, section layout, and so on.
In the pubspec.yaml of your flutter project, add the following dependency:
dependencies:sticky_and_expandable_list:^1.1.3
Basic Usage
sectionList is a custom data source for ExpandableListView.
We should create a model list to store the information of each section, the model must implement ExpandableListSection.