Skip to main content

A Google Navigation Bar control for Flet based on Aurélien Salomon's design.

Project description

FletGNavBar 🌟

Custom Google Navigation Bar (GNav) control for Flet apps, built on Flutter's google_nav_bar package.

PyPI Version Flutter Package License Build Status


Features

  • Fully compatible with Flet.
  • Supports tabs with icons, labels, and optional badges.
  • Customizable colors, active/inactive states, ripple, and hover effects.
  • Works on desktop, web, and mobile targets.

Installation

Git dependency

Add to your pyproject.toml:

dependencies = [
  "flet_gnav_bar @ git+https://github.com/pro-grammer-SD/flet_gnav_bar",
  "flet>=0.28.3",
]

PyPI dependency

If published on PyPI:

dependencies = [
  "flet_gnav_bar",
  "flet>=0.28.3",
]

Build your app:

flet build macos -v

Example Usage

import flet as ft
from flet_gnav_bar import FletGNavBar, FletGNavBarButton

def main(page: ft.Page):
    gnav = FletGNavBar(
        selected_index=0,
        tabs=[
            FletGNavBarButton(name="Home", icon_name="home", color="#2FB14F", badge="5"),
            FletGNavBarButton(name="Search", icon_name="search", color="#118DA3"),
            FletGNavBarButton(name="Profile", icon_name="user", color="#E6E21F", badge="!")
        ]
    )

    gnav.on_change = lambda _: print("Selected index:", gnav.selected_index)
    page.add(gnav)

ft.app(target=main)

Documentation

Full documentation is available here.


Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

flet_gnav_bar-0.0.2.tar.gz (6.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

flet_gnav_bar-0.0.2-py3-none-any.whl (8.2 kB view details)

Uploaded Python 3

File details

Details for the file flet_gnav_bar-0.0.2.tar.gz.

File metadata

  • Download URL: flet_gnav_bar-0.0.2.tar.gz
  • Upload date:
  • Size: 6.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for flet_gnav_bar-0.0.2.tar.gz
Algorithm Hash digest
SHA256 3a83d8992666dded7d7b3e2125eea7d6eb616c1fd71a5b2fa542fbc737dbc7a1
MD5 8991e738f615dd11f7751e3fac986dbf
BLAKE2b-256 52ed7c31fcacc204905e778ecc2078ae70035c89bff71743ccfaff6fbb11b5ac

See more details on using hashes here.

Provenance

The following attestation bundles were made for flet_gnav_bar-0.0.2.tar.gz:

Publisher: python-publish.yml on pro-grammer-SD/flet_gnav_bar

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file flet_gnav_bar-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: flet_gnav_bar-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 8.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for flet_gnav_bar-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 41d67a308287c71fd2a38b689b51294764c700b1f6e8061c35f3006bc5ddc58f
MD5 0a7c00a7589ad33ef90a8c7ab495f64b
BLAKE2b-256 57e2abd66aa4d79c0f3ae9c64288c7f4666b7024c357fce1d49e5cb9140cd8a9

See more details on using hashes here.

Provenance

The following attestation bundles were made for flet_gnav_bar-0.0.2-py3-none-any.whl:

Publisher: python-publish.yml on pro-grammer-SD/flet_gnav_bar

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page