Add search to Textual SelectionList.
Project description
Searchable SelectionList
Add search to Textual's SelectionList.
- Selectable items can be filtered by substring.
- Select one or multiple items.
- Search is case-insensitive.
- Title and description can be customized.
Installation
pip install textual-searchable-selectionlist
Usage
from textual_searchable_selectionlist.options import SelectionStrategy
from textual_searchable_selectionlist.select import select, select_enum
selected = select(
['John', 'Jane', 'James'],
selection_strategy=SelectionStrategy.MULTIPLE,
search_title='Select people',
)
# Enums
# class Color(Enum):
# RED = 'red'
# GREEN = 'green'
#
# selected_colors = select_enum(Color, selection_strategy=SelectionStrategy.ONE)
Testing
There are currently no automated tests. Manual testing can be done by running:
python tests/manual/searchable_selection_list_select.py
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file textual_searchable_selectionlist-0.0.3.tar.gz.
File metadata
- Download URL: textual_searchable_selectionlist-0.0.3.tar.gz
- Upload date:
- Size: 20.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: python-requests/2.32.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a213116422175be6b54a604ffa5685d4ec3bef38251cf3a9703109a94b28e6c0
|
|
| MD5 |
d72a4d3c18730f257e714fe9a6c4a0f7
|
|
| BLAKE2b-256 |
62ab88f6557c3cf5267bbda4c84139162502a3b16a58f1bc63f20c85fb8bd1d4
|
File details
Details for the file textual_searchable_selectionlist-0.0.3-py2.py3-none-any.whl.
File metadata
- Download URL: textual_searchable_selectionlist-0.0.3-py2.py3-none-any.whl
- Upload date:
- Size: 9.1 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: python-requests/2.32.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1b4dddf7bb51af72ef2bc866df5885657e404e3f7b275bda24d1fb55da8e178a
|
|
| MD5 |
a56fc13469e34fdf776b83568599ca91
|
|
| BLAKE2b-256 |
d1ead7962586c141883dec3dacd7c5c30a77e550f6fd89e753c82b260442f0d4
|