Buscar pacotes, repositórios e categorias de apps

Capa de easy_sticky_header
Detalhes do pacotev1.1.1

easy_sticky_header

Um cabeçalho colado fácil de usar e poderoso para qualquer widget que suporte rolagem.

AndroidiOSWebmacOSWindowsLinux
Downloads em 30 dias
5,6 mil
Curtidas
56
Pontos Pub
160

Instalar pacote

flutter pub add easy_sticky_header

Visão geral do pacote

Orientação gerada a partir de informações públicas. Apenas para referência.

easy_sticky_header é um pacote Flutter que oferece uma maneira simples e flexível de implementar cabeçalhos fixos em widgets roláveis. Ele mantém automaticamente os cabeçalhos visíveis no topo durante o rolagem, melhorando a experiência do usuário em listas ou grades com conteúdo agrupado. Projetado para facilitar o uso, integra-se perfeitamente ao ListView, Scrollable e outros componentes roláveis em todas as principais plataformas. O pacote suporta widgets personalizados de cabeçalho e transições suaves, tornando-o ideal para aplicativos que exigem exibições estruturadas de dados roláveis.

Casos de uso

  • Visualizações de lista agrupadas
  • Painéis navegáveis
  • Listagens de categorias de produtos
  • Seções de conteúdo dinâmico
  • linhas do tempo do perfil do usuário

Principais recursos

  • Colagem automática de cabeçalho
  • widgets de cabeçalho personalizáveis
  • Animações de transição suave
  • Compatibilidade multiplataforma
  • Configuração mínima necessária
  • Suporta scrolláveis aninhados

Indicado para

  • Desenvolvedores construindo interfaces com rolagem
  • Aplicativos com conteúdo categorizado
  • Designers procurando comportamento de cabeçalho limpo
  • Projetos que precisam de layouts responsivos
  • Equipes que priorizam a velocidade de desenvolvimento

Considerações

  • Pode afetar o desempenho com listas muito grandes
  • Requer manipulação cuidadosa em rolagens aninhadas complexas
  • Personalização limitada para animações avançadas
  • Não otimizado para conteúdo de cabeçalho altamente dinâmico
  • Mais adequado para designs de cabeçalho estáticos ou semi-estáticos

README original

Snapshot do README original do repositório-fonte vinculado. Consulte o repositório para o conteúdo mais recente.

easy_sticky_header

platform pub license issues commits

English | 中文

An easy-to-use and powerful sticky header for any widget that supports scrolling.

Features

  • Support widget for horizontal or vertical scrolling
  • Support widget for reverse scrolling
  • Allow dynamic building of header widget and support custom transition animation
  • Header widget can dynamically change stickiness
  • Support jumping to the header widget of the specified index
  • Support header widget grouping
  • Support infinite list

Usage

Add dependency:

dependencies:
  easy_sticky_header: ^1.1.1

Import package:

import 'package:easy_sticky_header/easy_sticky_header.dart';

Example:

class Example extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return StickyHeader(
      child: ListView.builder(
        itemCount: 100,
        itemBuilder: (context, index) {
          // Custom header widget.
          if (index % 3 == 0) {
            return StickyContainerWidget(
              index: index,
              child: Container(
                color: Color.fromRGBO(Random().nextInt(256),
                    Random().nextInt(256), Random().nextInt(256), 1),
                padding: const EdgeInsets.only(left: 16.0),
                alignment: Alignment.centerLeft,
                width: double.infinity,
                height: 50,
                child: Text(
                  'Header #$index',
                  style: const TextStyle(
                    color: Colors.white,
                    fontSize: 16,
                  ),
                ),
              ),
            );
          }
          // Custom item widget.
          return Container(
            width: double.infinity,
            height: 80,
            color: Colors.white,
          );
        },
      ),
    );
  }
}

For more features, please go to the example project to see the details.

Screenshots

screenshot1 screenshot2 screenshot3
screenshot4 screenshot5 screenshot6
screenshot7 screenshot8 screenshot9

Contribution

You are welcome to contribute here 😄!

You can open an issue, if you find a bug, or want a new feature.

You can open up a PR, if you fixed a bug or implemented a new feature.

License

MIT License

Copyright (c) 2022 crasowas

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

Categorias

Repositório-fonte

Projetos que usam este pacote

Ainda não há dados.