Datasette UI plugin for editing and inserting rows
Project description
datasette-write-ui
A Datasette plugin that adds UI elements to edit, insert, or delete rows in SQLite tables.
Installation
This plugin requires the alpha version of Datasette 1.0. You can install it with:
pip install datasette==1.0a3
After that, you can install this plugin in the same environment as Datasette.
datasette install datasette-write-ui
Usage
Once installed, the new UI elements will appear on the table page. You'll need special permission in order to see them. The easiest way is to use the root user, or otherwise use a custom actor.
If you actor has the insert-row permissions, you'll see the "Insert new row" button at the bottom of the page.
If your actor has the update-row permissions, you'll see a new "Edit row" option in a new menu on each row.
If your actor has the delete-row permissions, you'll see a new "Delete row" option in a new menu on each row.
Development
To set up this plugin locally, first checkout the code. Then create a new virtual environment:
cd datasette-write-ui
python3 -m venv venv
source venv/bin/activate
Now install the dependencies and test dependencies:
pip install -e '.[test]'
To install the JavaScript build dependencies, run this:
npm install
You can use the Just command runner to build the TypeScript to minified JavaScript like this:
just js
To run the tests:
pytest
Project details
Release history Release notifications | RSS feed
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 datasette_write_ui-0.0.1a14.tar.gz.
File metadata
- Download URL: datasette_write_ui-0.0.1a14.tar.gz
- Upload date:
- Size: 16.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1262640194248ddc28af6f00acb53bcd846ab670d84f4b1e6b9c8133f2e04563
|
|
| MD5 |
a6ec45bc733dc67916ca0406be10ed24
|
|
| BLAKE2b-256 |
3e73755fedfd41836008bb3d6337d919a387453a0a38fb92925dad49b538b197
|
File details
Details for the file datasette_write_ui-0.0.1a14-py3-none-any.whl.
File metadata
- Download URL: datasette_write_ui-0.0.1a14-py3-none-any.whl
- Upload date:
- Size: 17.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fa68b77d7690c024c117e8be2dda2cbd3e8e0852da90dab44c55a2b65ea96def
|
|
| MD5 |
9605c6cde269fb73cc54f82377e9f1f7
|
|
| BLAKE2b-256 |
76d75a81541009701ce990844186f48ed9a1202b0bef9e0b950c7c7c621b8950
|