Skip to main content

A Streamlit component to edit a list of items.

Project description

streamlit-editable-list

A Streamlit component to edit a list of entries, made of several inputs.

Installation instructions

pip install streamlit-editable-list

Usage instructions

import streamlit as st

from streamlit_editable_list import editable_list

input_params = [
    {
        "type": "text",
        "placeholder": "Enter text",
        "value": "",
    },
    {
        "type": "number",
        "placeholder": "Enter number",
        "value": 0,
    },
    {
        "list": "countries",
        "placeholder": "Select country",
        "value": "",
        "options": ["Switzerland", "France", "Germany"],
    }
]

initial_data = [
    ["Hello", 1, "Switzerland"],
    ["World", 2, "France"],
]

new_data = editable_list(initial_data, input_params)

For use inside a Streamlit form, the auto_save option can be set to True:

new_data = editable_list(initial_data, input_params, auto_save=True)

The Python data will be updated each time the user leaves an input field.

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_editable_list-0.0.5.tar.gz (455.1 kB view details)

Uploaded Source

Built Distribution

streamlit_editable_list-0.0.5-py3-none-any.whl (459.4 kB view details)

Uploaded Python 3

File details

Details for the file streamlit_editable_list-0.0.5.tar.gz.

File metadata

File hashes

Hashes for streamlit_editable_list-0.0.5.tar.gz
Algorithm Hash digest
SHA256 51878639f4a57b1341819191d664439b317d66bfaa50433cf98c804652a64c08
MD5 26c43063391b60e8982efd85931b07ae
BLAKE2b-256 28ce46f44e1f057caa8d304d8faf23fea3ee7f9837dc9280139c51f879b32a4a

See more details on using hashes here.

File details

Details for the file streamlit_editable_list-0.0.5-py3-none-any.whl.

File metadata

File hashes

Hashes for streamlit_editable_list-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 c0f3424b662ffcd61ef1b15cedda293a684754ae5810407fa69b72c14a027c2f
MD5 c31f28751a8c1f7e86403bc42948cdcf
BLAKE2b-256 ce011df031de8410d3e978e47ce06a76a00280cd38fcc0b12bc62b02d04a0aa6

See more details on using hashes here.

Supported by

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