Skip to main content

A multi-select button group

Project description

streamlit-toggle-button-set

A button can be used to group related options (multi-select & single select), inspired by React Material UI.

Installation instructions

pip install streamlit-toggle-button-set

Usage instructions

alt text

import streamlit as st
from toggle_button_set import toggle_button_set

outcome = toggle_button_set(
    button_list=['a', 'b', '1', '2'],
    default=['a', '1'],
    color="primary",
    size="large",
    exclusive=False,
    use_container_width=False
)

st.write(outcome)

Arguments

Required:

  • button_list

Optional:

  • default = [] - must be a subset of button_list, these options are automatically selected upon boot.
  • color = "standard" - The color of the button when it is selected, options includes 'standard', 'primary', 'secondary', 'error', 'info', 'success' and 'warning'.
  • size = "medium" - The size of the component, options includes 'small', 'medium' and 'large'.
  • exclusive = False - forces only one item to be selected from button_list.
  • use_container_width = False - will make the component take up the full width of its container.
  • key = None - optional key

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

streamlit-toggle-button-set-0.0.6.tar.gz (553.8 kB view details)

Uploaded Source

Built Distribution

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

streamlit_toggle_button_set-0.0.6-py3-none-any.whl (1.1 MB view details)

Uploaded Python 3

File details

Details for the file streamlit-toggle-button-set-0.0.6.tar.gz.

File metadata

File hashes

Hashes for streamlit-toggle-button-set-0.0.6.tar.gz
Algorithm Hash digest
SHA256 09636b6f9bb952afabe37ea7cf7abe094d4b6680d39184661bc61c2761a3fc9a
MD5 9272a7c3eddec7c13ea387c281d69ad9
BLAKE2b-256 f96af662f0f5e277e26e8ed3ee45089508ebf0b74ac363eb71c4331392599175

See more details on using hashes here.

File details

Details for the file streamlit_toggle_button_set-0.0.6-py3-none-any.whl.

File metadata

File hashes

Hashes for streamlit_toggle_button_set-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 05b88cc2d4476dba6f4afb9291d651ba9ec77321e11d99e93c2ac0ed652eaebb
MD5 ac9e527ece103292cb0f9f182b6409b6
BLAKE2b-256 5d7793671153686074d6123385d9482da93a7c82ac6f0b910050e19fe38375ec

See more details on using hashes here.

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