Skip to main content

A drag-and-drop Kanban board component for Streamlit

Project description

streamlit-kanban

A drag-and-drop Kanban board component for Streamlit. Move cards between columns, add and edit cards with tags and priority levels, and get the full board state back as JSON.

Kanban screenshot

Features

  • Drag-and-drop cards between columns (native HTML5, no external DnD lib)
  • Click any card to edit title, tag, and priority
  • Add cards to any column
  • Color-coded tag and priority badges
  • Progress bar tracking Done / Total
  • Export board state as JSON
  • Zero runtime dependencies beyond Streamlit

Installation

pip install streamlit-kanban

Quickstart

import streamlit as st
from streamlit_kanban import st_kanban

columns = [
    {
        "id": "todo",
        "title": "To Do",
        "color": "#6366f1",
        "cards": [
            {"id": "c1", "title": "Write tests",    "tag": "Dev",    "priority": "high"},
            {"id": "c2", "title": "Update docs",    "tag": "Docs",   "priority": "low"},
        ],
    },
    {
        "id": "in-progress",
        "title": "In Progress",
        "color": "#f59e0b",
        "cards": [
            {"id": "c3", "title": "Build auth flow", "tag": "Dev", "priority": "high"},
        ],
    },
    {
        "id": "done",
        "title": "Done",
        "color": "#10b981",
        "cards": [],
    },
]

st.title("My Project Board")

if "board" not in st.session_state:
    st.session_state.board = columns

result = st_kanban(st.session_state.board, key="kanban")

if result:
    st.session_state.board = result

API

st_kanban(columns, key=None)
Parameter Type Description
columns list[dict] Column definitions (see schema below)
key str Streamlit widget key

Returns: Updated columns list on any interaction, None on first render.

Column schema

{
    "id":    str,          # unique identifier
    "title": str,          # display name
    "color": str,          # hex accent color for the column dot
    "cards": [
        {
            "id":       str,   # unique card id
            "title":    str,   # card text
            "tag":      str,   # e.g. "Dev", "Design", "Bug"
            "priority": str,   # "high" | "medium" | "low"
        }
    ]
}

Development

git clone https://github.com/RhythrosaLabs/streamlit-kanban
cd streamlit-kanban

# Frontend
cd streamlit_kanban/frontend
npm install
npm start          # dev server on :3001

# Python (separate terminal)
cd ../..
pip install -e .
# In streamlit_kanban/__init__.py, set _RELEASE = False
streamlit run example.py

License

MIT

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_kanban-0.1.0.tar.gz (407.0 kB view details)

Uploaded Source

Built Distribution

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

streamlit_kanban-0.1.0-py3-none-any.whl (409.3 kB view details)

Uploaded Python 3

File details

Details for the file streamlit_kanban-0.1.0.tar.gz.

File metadata

  • Download URL: streamlit_kanban-0.1.0.tar.gz
  • Upload date:
  • Size: 407.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for streamlit_kanban-0.1.0.tar.gz
Algorithm Hash digest
SHA256 c76777244bad81843788aa4a5f7b53aba53945dc71a865e60fb9ba2dc6e4fcff
MD5 26aa653dd322641992b30e785f20606e
BLAKE2b-256 f8f9f6c30983878fd17e4876c43d28e8cc0719540762e32ca407d8ae6d4a5dbb

See more details on using hashes here.

File details

Details for the file streamlit_kanban-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for streamlit_kanban-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9e4b549234d4835151a46e50e6a13b14869e2c1f8a5f9e936acac2504f4bcb1b
MD5 f70133d5115573424df5b6632abc1876
BLAKE2b-256 3fc9c8884feabcb638611539d6e22683e85b68fb85561c37476a5f9237ea3723

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