{"id":28955657,"url":"https://github.com/cvaniak/textuallistviewunofficial","last_synced_at":"2025-06-23T20:09:14.572Z","repository":{"id":47166801,"uuid":"461427359","full_name":"Cvaniak/TextualListViewUnofficial","owner":"Cvaniak","description":"Unofficial Textual List View for Widgets that supports scrolling. Short and dirty hack to use while waiting for official ListView.","archived":false,"fork":false,"pushed_at":"2022-02-22T15:39:47.000Z","size":5501,"stargazers_count":10,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2023-03-10T19:35:58.832Z","etag":null,"topics":["listview","rich","scroll","scrollable","textual","widgets"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Cvaniak.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-02-20T08:28:33.000Z","updated_at":"2022-12-07T12:20:29.000Z","dependencies_parsed_at":"2022-08-02T13:46:00.301Z","dependency_job_id":null,"html_url":"https://github.com/Cvaniak/TextualListViewUnofficial","commit_stats":null,"previous_names":[],"tags_count":null,"template":null,"template_full_name":null,"purl":"pkg:github/Cvaniak/TextualListViewUnofficial","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cvaniak%2FTextualListViewUnofficial","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cvaniak%2FTextualListViewUnofficial/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cvaniak%2FTextualListViewUnofficial/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cvaniak%2FTextualListViewUnofficial/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Cvaniak","download_url":"https://codeload.github.com/Cvaniak/TextualListViewUnofficial/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cvaniak%2FTextualListViewUnofficial/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261548742,"owners_count":23175497,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["listview","rich","scroll","scrollable","textual","widgets"],"created_at":"2025-06-23T20:09:07.483Z","updated_at":"2025-06-23T20:09:14.560Z","avatar_url":"https://github.com/Cvaniak.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Unofficial [Textual](https://github.com/Textualize) List View (Scrollable list of widgets)\nWhile waiting for [ticket](https://github.com/Textualize/textual/projects/1#card-66941810) (also mentioned [here](https://github.com/Textualize/textual/discussions/196)) and official `ListView`, you can use this dirty version that allows you to scroll thrue list of widgets.  \n\n## Demo\n![Image](./documentation/demo.gif)\n\n## Installation\nThis is not pip package but you can install this with pip:\n```bash\npip3 install git+https://github.com/Cvaniak/TextualListViewUnofficial.git \n```\n\n## Usage\nThen in code you can use it this way:\n```python\nfrom ck_widgets_lv import ListViewUo\n\nclass TestListView(App):\n    async def on_mount(self, event: events.Mount) -\u003e None:\n        await self.view.dock(ListViewUo([Placeholder(height=10) for _ in range(20)]))\n\nif __name__ == \"__main__\":\n    TestListView.run()\n```\n\nor more complex example (from gif demo above):\n```python3 \nfrom textual.widgets import Placeholder\nfrom textual.widget import Widget\nfrom textual.events import Message\nfrom textual.app import App\nfrom textual import events\n\nfrom ck_widgets_lv import ListViewUo\n\nif __name__ == \"__main__\":\n    from textual.widgets import Footer\n\n    class DeleteStatus(Message):\n        def __init__(self, sender: Widget):\n            super().__init__(sender)\n            self.to_delete = sender\n\n    class DeletablePlaceholder(Placeholder):\n        async def on_click(self, event: events.Click) -\u003e None:\n            await self.emit(DeleteStatus(self))\n\n    class TestListView(App):\n        async def action_add(self) -\u003e None:\n            await self.list_view.add_widget(DeletablePlaceholder(height=10))\n            self.refresh()\n\n        async def action_add_index_2(self) -\u003e None:\n            await self.list_view.add_widget(DeletablePlaceholder(height=10), index=2)\n            self.refresh()\n\n        async def action_remove(self) -\u003e None:\n            await self.list_view.remove_widget_by_index()\n            self.refresh()\n\n        async def action_remove_index_2(self) -\u003e None:\n            await self.list_view.remove_widget_by_index(index=2)\n            self.refresh()\n\n        async def on_load(self, _: events.Load) -\u003e None:\n            await self.bind(\"a\", \"add()\", \"Add Widget\")\n            await self.bind(\"s\", \"add_index_2()\", \"Add Widget in index 2\")\n            await self.bind(\"r\", \"remove()\", \"Remove Widget\")\n            await self.bind(\"e\", \"remove_index_2()\", \"Remove Widget in index 2\")\n            await self.bind(\"Click Widget\", \"_()\", \"To delete it\")\n\n        async def on_mount(self, event: events.Mount) -\u003e None:\n            self.list_view = ListViewUo(\n                [DeletablePlaceholder(height=10) for _ in range(7)]\n            )\n\n            await self.view.dock(Footer(), edge=\"bottom\")\n            await self.view.dock(self.list_view)\n\n        async def handle_delete_status(self, message: DeleteStatus):\n            await self.list_view.remove_widget(message.to_delete)\n\n    TestListView.run()\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcvaniak%2Ftextuallistviewunofficial","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcvaniak%2Ftextuallistviewunofficial","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcvaniak%2Ftextuallistviewunofficial/lists"}