sqlite-hub 1.2.0 → 1.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +113 -71
- package/bin/sqlite-hub.js +723 -116
- package/docs/API.md +152 -0
- package/docs/CLI.md +249 -0
- package/docs/CLI_API_PARITY.md +61 -0
- package/docs/changelog.md +149 -0
- package/docs/guidelines/AGENTS.md +32 -0
- package/docs/guidelines/DESIGN.md +55 -0
- package/docs/shortkeys.md +27 -0
- package/docs/todo.md +4 -0
- package/examples/api/generate-types.js +52 -0
- package/frontend/assets/mockups/backups_1_1920.webp +0 -0
- package/frontend/assets/mockups/backups_2_create_backup_modal_1920.webp +0 -0
- package/frontend/assets/mockups/backups_3_edit_backup_modal_1920.webp +0 -0
- package/frontend/assets/mockups/backups_4_restore_backup_modal_1920.webp +0 -0
- package/frontend/assets/mockups/backups_5_delete_backup_modal_1920.webp +0 -0
- package/frontend/assets/mockups/charts_1_1920.webp +0 -0
- package/frontend/assets/mockups/charts_2_query_detail_1920.webp +0 -0
- package/frontend/assets/mockups/charts_3_create_query_chart_modal_1920.webp +0 -0
- package/frontend/assets/mockups/charts_4_edit_query_chart_modal_1920.webp +0 -0
- package/frontend/assets/mockups/charts_5_delete_query_chart_modal_1920.webp +0 -0
- package/frontend/assets/mockups/charts_6_copy_column_modal_1920.webp +0 -0
- package/frontend/assets/mockups/connections_1_1920.webp +0 -0
- package/frontend/assets/mockups/connections_2_create_connection_modal_1920.webp +0 -0
- package/frontend/assets/mockups/connections_3_open_connection_modal_1920.webp +0 -0
- package/frontend/assets/mockups/data_1_1920.webp +0 -0
- package/frontend/assets/mockups/data_2_roweditor_1920.webp +0 -0
- package/frontend/assets/mockups/data_3_data_export_modal_1920.webp +0 -0
- package/frontend/assets/mockups/documents_1_1920.webp +0 -0
- package/frontend/assets/mockups/documents_2_document_insert_table_modal_1920.webp +0 -0
- package/frontend/assets/mockups/documents_3_document_insert_note_modal_1920.webp +0 -0
- package/frontend/assets/mockups/media_tagging_queue_1_1920.webp +0 -0
- package/frontend/assets/mockups/media_tagging_setup_1_1920.webp +0 -0
- package/frontend/assets/mockups/media_tagging_setup_2_create_media_tagging_tag_table_modal_1920.webp +0 -0
- package/frontend/assets/mockups/media_tagging_setup_3_create_media_tagging_mapping_table_modal_1920.webp +0 -0
- package/frontend/assets/mockups/overview_1_1920.webp +0 -0
- package/frontend/assets/mockups/settings_1_1920.webp +0 -0
- package/frontend/assets/mockups/sql_editor_1_1920.webp +0 -0
- package/frontend/assets/mockups/sql_editor_2_query_detail_1920.webp +0 -0
- package/frontend/assets/mockups/sql_editor_3_query_export_modal_1920.webp +0 -0
- package/frontend/assets/mockups/structure_1_1920.webp +0 -0
- package/frontend/assets/mockups/structure_2_generate_types_modal_1920.webp +0 -0
- package/frontend/assets/mockups/structure_3_generate_types_modal_1920.webp +0 -0
- package/frontend/assets/mockups/table_designer_1_1920.webp +0 -0
- package/frontend/assets/mockups/table_designer_2_table_designer_constraints_modal_1920.webp +0 -0
- package/frontend/js/api.js +63 -0
- package/frontend/js/app.js +310 -10
- package/frontend/js/components/connectionCard.js +4 -2
- package/frontend/js/components/emptyState.js +4 -4
- package/frontend/js/components/generateTypesDropdown.js +33 -0
- package/frontend/js/components/metricCard.js +1 -1
- package/frontend/js/components/modal.js +555 -21
- package/frontend/js/components/pageHeader.js +1 -1
- package/frontend/js/components/queryHistoryDetail.js +3 -3
- package/frontend/js/components/queryHistoryHeader.js +1 -1
- package/frontend/js/components/queryHistoryPanel.js +1 -1
- package/frontend/js/components/rowEditorPanel.js +13 -3
- package/frontend/js/components/sidebar.js +41 -7
- package/frontend/js/components/topNav.js +2 -14
- package/frontend/js/router.js +38 -6
- package/frontend/js/store.js +870 -8
- package/frontend/js/utils/inputClear.js +36 -0
- package/frontend/js/utils/syntheticData.js +240 -0
- package/frontend/js/views/backups.js +581 -37
- package/frontend/js/views/charts.js +9 -9
- package/frontend/js/views/connections.js +2 -2
- package/frontend/js/views/data.js +17 -1
- package/frontend/js/views/documents.js +3 -3
- package/frontend/js/views/editor.js +6 -6
- package/frontend/js/views/logs.js +339 -0
- package/frontend/js/views/mediaTagging.js +7 -5
- package/frontend/js/views/overview.js +3 -3
- package/frontend/js/views/settings.js +80 -30
- package/frontend/js/views/structure.js +12 -1
- package/frontend/js/views/tableAdvisor.js +385 -0
- package/frontend/js/views/tableDesigner.js +6 -0
- package/frontend/styles/base.css +1 -40
- package/frontend/styles/components.css +258 -232
- package/frontend/styles/structure-graph.css +32 -68
- package/frontend/styles/tailwind.css +8 -4
- package/frontend/styles/tailwind.generated.css +1 -1
- package/frontend/styles/tokens.css +28 -21
- package/frontend/styles/views.css +102 -261
- package/package.json +18 -2
- package/server/routes/backups.js +18 -2
- package/server/routes/data.js +45 -0
- package/server/routes/externalApi.js +321 -2
- package/server/routes/logs.js +127 -0
- package/server/routes/structure.js +22 -0
- package/server/server.js +3 -0
- package/server/services/databaseCommandService.js +59 -0
- package/server/services/sqlite/backupDiff.js +914 -0
- package/server/services/sqlite/backupService.js +77 -1
- package/server/services/sqlite/dataBrowserService.js +36 -0
- package/server/services/sqlite/introspection.js +226 -22
- package/server/services/sqlite/structureService.js +7 -0
- package/server/services/sqlite/syntheticDataGenerator.js +728 -0
- package/server/services/sqlite/tableAdvisor.js +790 -0
- package/server/services/storage/appStateStore.js +773 -169
- package/server/services/typeGenerationService.js +663 -0
- package/tailwind.config.cjs +0 -1
- package/.github/funding.yml +0 -2
- package/.github/workflows/ci.yml +0 -36
- package/database.sqlite +0 -0
- package/frontend/assets/mockups/charts_1_bars_1200.webp +0 -0
- package/frontend/assets/mockups/charts_2_pie_1200.webp +0 -0
- package/frontend/assets/mockups/charts_3_scatter_plot_1200.webp +0 -0
- package/frontend/assets/mockups/connections_1200.webp +0 -0
- package/frontend/assets/mockups/data_1_1200.webp +0 -0
- package/frontend/assets/mockups/data_2_row_editor_1200.webp +0 -0
- package/frontend/assets/mockups/documents_1200.webp +0 -0
- package/frontend/assets/mockups/media_tagging_1_setup_1200.webp +0 -0
- package/frontend/assets/mockups/media_tagging_2_tagging_queue_1200.webp +0 -0
- package/frontend/assets/mockups/media_tagging_3_media_viewer_1200.webp +0 -0
- package/frontend/assets/mockups/overview_1200.webp +0 -0
- package/frontend/assets/mockups/settings_1200.webp +0 -0
- package/frontend/assets/mockups/sql_editor_1_1200.webp +0 -0
- package/frontend/assets/mockups/sql_editor_2_query_details_1200.webp +0 -0
- package/frontend/assets/mockups/sql_editor_3_export_column_1200.webp +0 -0
- package/frontend/assets/mockups/sql_editor_4_export_column_as_markdown_1200.webp +0 -0
- package/frontend/assets/mockups/sql_editor_5_export_query_result_1200.webp +0 -0
- package/frontend/assets/mockups/structure_1_1200.webp +0 -0
- package/frontend/assets/mockups/structure_2_inspector_1200.webp +0 -0
- package/frontend/assets/mockups/table_designer_1_1200.webp +0 -0
- package/frontend/assets/mockups/table_designer_2_checks_1200.webp +0 -0
- package/tests/api-token-auth.test.js +0 -279
- package/tests/backup-manager.test.js +0 -140
- package/tests/backups-view.test.js +0 -70
- package/tests/charts-height-preset-storage.test.js +0 -60
- package/tests/charts-route-state.test.js +0 -144
- package/tests/check-constraint-options.test.js +0 -90
- package/tests/cli-args.test.js +0 -113
- package/tests/cli-service-delegation.test.js +0 -140
- package/tests/connection-removal.test.js +0 -52
- package/tests/connections-file-dialog-route.test.js +0 -89
- package/tests/copy-column-modal.test.js +0 -131
- package/tests/database-command-service.test.js +0 -174
- package/tests/database-documents.test.js +0 -85
- package/tests/documents-view.test.js +0 -132
- package/tests/dropdown-button.test.js +0 -101
- package/tests/email-preview.test.js +0 -89
- package/tests/export-blob.test.js +0 -99
- package/tests/export-filenames.test.js +0 -38
- package/tests/file-path-preview.test.js +0 -165
- package/tests/form-controls.test.js +0 -34
- package/tests/json-preview.test.js +0 -49
- package/tests/local-request-security.test.js +0 -85
- package/tests/markdown-documents.test.js +0 -103
- package/tests/native-file-dialog.test.js +0 -105
- package/tests/query-editor.test.js +0 -28
- package/tests/query-history-detail.test.js +0 -37
- package/tests/query-history-header.test.js +0 -30
- package/tests/query-results-truncation.test.js +0 -20
- package/tests/risky-sql.test.js +0 -30
- package/tests/row-editor-json.test.js +0 -82
- package/tests/row-editor-null-values.test.js +0 -184
- package/tests/row-editor-timestamp-preview.test.js +0 -192
- package/tests/security-paths.test.js +0 -84
- package/tests/settings-api-tokens-route.test.js +0 -97
- package/tests/settings-metadata.test.js +0 -114
- package/tests/settings-view.test.js +0 -108
- package/tests/sql-formatter.test.js +0 -173
- package/tests/sql-highlight.test.js +0 -38
- package/tests/sql-identifier-safety.test.js +0 -171
- package/tests/sql-result-limit.test.js +0 -66
- package/tests/structure-view.test.js +0 -60
- package/tests/table-designer-v2-unique-constraints.test.js +0 -78
- package/tests/table-scroll-state.test.js +0 -70
- package/tests/text-cell-stats.test.js +0 -38
package/README.md
CHANGED
|
@@ -1,11 +1,32 @@
|
|
|
1
1
|
# sqlite-hub ⚡️
|
|
2
2
|
|
|
3
|
-
[](./frontend/assets/mockups/overview_1_1920.webp)
|
|
4
4
|
|
|
5
5
|
A focused local-first app for browsing, editing, and querying SQLite databases.
|
|
6
6
|
|
|
7
7
|
SQLite Hub is built for developers and technical users who want a clean SQLite workflow without heavy database clients, cloud layers, or dashboard noise.
|
|
8
8
|
|
|
9
|
+
## Install
|
|
10
|
+
|
|
11
|
+
### Homebrew
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
brew tap oliverjessner/tap
|
|
15
|
+
brew install sqlite-hub
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
### NPM
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
npm install -g sqlite-hub
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
## Alternative port
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
sqlite-hub --port:4174
|
|
28
|
+
```
|
|
29
|
+
|
|
9
30
|
## Why SQLite Hub?
|
|
10
31
|
|
|
11
32
|
Many database tools are powerful, but feel oversized when all you want is to inspect a local SQLite file, edit a few rows, and run a query fast.
|
|
@@ -18,6 +39,8 @@ SQLite Hub keeps that workflow sharp:
|
|
|
18
39
|
- inspect database health, storage metrics, and schema connectivity from one overview
|
|
19
40
|
- filter, sort, page through, and export table data
|
|
20
41
|
- inspect schema, structure, and relationships
|
|
42
|
+
- analyze individual tables with a deterministic local advisor
|
|
43
|
+
- generate TypeScript, Rust, Kotlin, or Swift types from table schemas
|
|
21
44
|
- edit records in place with typed value previews and an SQL diff preview before saving
|
|
22
45
|
- export tables and query results as CSV, TSV, Markdown, JSON, Parquet, or duplicate them as a table
|
|
23
46
|
- copy result columns with formatting, headers, first-10 previews, TXT export, and Markdown todo export
|
|
@@ -32,45 +55,48 @@ SQLite Hub keeps that workflow sharp:
|
|
|
32
55
|
|
|
33
56
|
## Features
|
|
34
57
|
|
|
35
|
-
###
|
|
58
|
+
### Structure view
|
|
36
59
|
|
|
37
|
-
[](./frontend/assets/mockups/structure_1_1920.webp)
|
|
38
61
|
|
|
39
|
-
|
|
62
|
+
Inspect tables, views, indexes, triggers, columns, declared types, primary keys, nullability, foreign keys, and DDL without losing pace. The searchable object list and relationship graph support fit, relayout, selection clearing, direct navigation to table data, and a hideable inspector/sidebar. Clicking a relationship edge opens a join preview with the mapped columns and a copyable SQL `JOIN` snippet.
|
|
40
63
|
|
|
41
|
-
|
|
64
|
+
### Generate Types
|
|
42
65
|
|
|
43
|
-
|
|
66
|
+
<p>
|
|
67
|
+
<a href="./frontend/assets/mockups/structure_2_generate_types_modal_1920.webp"><img src="./frontend/assets/mockups/structure_2_generate_types_modal_1920.webp" alt="SQLite Hub generate types for selected table" width="49%"></a>
|
|
68
|
+
<a href="./frontend/assets/mockups/structure_3_generate_types_modal_1920.webp"><img src="./frontend/assets/mockups/structure_3_generate_types_modal_1920.webp" alt="SQLite Hub generate types for all tables" width="49%"></a>
|
|
69
|
+
</p>
|
|
44
70
|
|
|
45
|
-
|
|
71
|
+
Generate application types directly from the Structure toolbar for the selected table or for every table in the database. The `Generate Types` dropdown lets you choose `Selected table` or `All tables`; the preview modal supports TypeScript, Rust, Kotlin, and Swift. When all tables are selected, SQLite Hub creates one generated file per table.
|
|
46
72
|
|
|
47
|
-
|
|
48
|
-
- largest tables by row count and estimated size
|
|
49
|
-
- database path, modification time, SQLite version, page size, freelist count, and encoding
|
|
50
|
-
- schema-map statistics for foreign-key links, connected clusters, and isolated tables
|
|
51
|
-
- integrity and quick-check results, access mode, user version, and schema version
|
|
52
|
-
- shortcuts to the SQL Editor, Structure view, and the database location in Finder
|
|
73
|
+
Type generation uses SQLite's declared column types plus schema constraints such as primary keys, foreign keys, `NOT NULL`, generated columns, defaults, and simple `CHECK (... IN (...))` value sets.
|
|
53
74
|
|
|
54
|
-
|
|
75
|
+
The same generator is available through the [CLI](./docs/CLI.md) and [local API](./docs/API.md) for automation.
|
|
55
76
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
</p>
|
|
77
|
+
### Table Advisor
|
|
78
|
+
|
|
79
|
+
The Table Advisor analyzes one table at a time and produces a deterministic, local health report. It does not call an external service; the result is derived from SQLite schema metadata, indexes, foreign keys, row counts, and column profiles from the active database.
|
|
60
80
|
|
|
61
|
-
|
|
81
|
+
For each table, SQLite Hub calculates a score, lists findings by severity, shows the evidence behind each finding, and includes copyable SQL suggestions where a direct fix is useful. The advisor can flag missing primary keys, foreign-key-like columns without constraints, join/filter columns without indexes, likely-unique values without a UNIQUE index, enum-like columns that could use a `CHECK` constraint, mostly-null columns, empty strings mixed with nullable text, timestamp columns that need defaults or update logic, and generic column names that hide intent.
|
|
62
82
|
|
|
63
83
|
### Data browser
|
|
64
84
|
|
|
65
|
-
[](./frontend/assets/mockups/data_1_1920.webp)
|
|
86
|
+
|
|
87
|
+
Scan rows, sort columns, move through local data quickly, and export full tables as CSV, TSV, Markdown, JSON, or Parquet.
|
|
66
88
|
|
|
67
|
-
|
|
89
|
+
Use `Generate` in the Data browser to create local synthetic test rows from the current table schema. The generator respects required columns, foreign keys, simple `CHECK` constraints, and shows a preview before insertion.
|
|
90
|
+
|
|
91
|
+
The Data browser also supports duplicating exports as a new table, searchable and hideable table navigation, page sizes up to 250 rows, and advanced filters with column/operator/value controls. Text filters support case-insensitive `contains`, `not contains`, and exact `equals` matching.
|
|
68
92
|
|
|
69
93
|
Wide tables keep their horizontal scroll position when sorting causes the grid to re-render. Cells use compact previews for long values, BLOBs, and detected file paths, while exports retain complete BLOB content.
|
|
70
94
|
|
|
95
|
+
[](./frontend/assets/mockups/data_3_data_export_modal_1920.webp)
|
|
96
|
+
|
|
71
97
|
### Row editing
|
|
72
98
|
|
|
73
|
-
[](./frontend/assets/mockups/data_2_roweditor_1920.webp)
|
|
74
100
|
|
|
75
101
|
Open one record, edit it in place, preview the generated SQL and changed values, then commit or delete the row with confirmation. SQLite Hub only enables row edits when it can target a stable primary-key or rowid identity safely.
|
|
76
102
|
|
|
@@ -87,40 +113,37 @@ The Row Editor adds contextual previews without changing the stored raw value:
|
|
|
87
113
|
|
|
88
114
|
### SQL editor
|
|
89
115
|
|
|
90
|
-
[](./frontend/assets/mockups/sql_editor_1_1920.webp)
|
|
91
117
|
|
|
92
|
-
Write queries in a syntax-highlighted editor, execute them with the Run button or `Shift + Enter`, format SQL with the editor Format button, inspect results in the same workflow, and export result sets as CSV, TSV, Markdown, JSON, Parquet, or duplicate them as a table.
|
|
118
|
+
Write queries in a syntax-highlighted editor, execute them with the Run button or `Shift + Enter`, format SQL with the editor Format button, inspect results in the same workflow, and export result sets as CSV, TSV, Markdown, JSON, Parquet, or duplicate them as a table.
|
|
93
119
|
|
|
94
|
-
|
|
120
|
+
Query drafts survive reloads, query history can be searched and saved, and direct single-table `SELECT` results can be edited or deleted from the result grid when a stable row identity is available.
|
|
95
121
|
|
|
96
|
-
[](./frontend/assets/mockups/sql_editor_3_query_export_modal_1920.webp)
|
|
97
123
|
|
|
98
124
|
Result column menus include copy actions for a full column, a column with header, or the first 10 values. The same modal can preview the output, copy it, export it as TXT, or turn a column into Markdown todo items.
|
|
99
125
|
|
|
100
|
-
<p>
|
|
101
|
-
<a href="./frontend/assets/mockups/sql_editor_3_export_column_1200.webp"><img src="./frontend/assets/mockups/sql_editor_3_export_column_1200.webp" alt="SQLite Hub copy column dialog" width="49%"></a>
|
|
102
|
-
<a href="./frontend/assets/mockups/sql_editor_4_export_column_as_markdown_1200.webp"><img src="./frontend/assets/mockups/sql_editor_4_export_column_as_markdown_1200.webp" alt="SQLite Hub Markdown todo export" width="49%"></a>
|
|
103
|
-
</p>
|
|
104
|
-
|
|
105
126
|
The bottom panel keeps separate tabs for:
|
|
106
127
|
|
|
107
128
|
- Results
|
|
108
129
|
- Performance, including execution time, statement count, returned rows, affected rows, and serialized result memory size
|
|
109
130
|
- Messages, including the executed query and statement updates/errors
|
|
110
131
|
|
|
111
|
-
Potentially destructive statements are tracked in query history, and SQLite Hub keeps the active result tab instead of forcing you back to Results after every execution.
|
|
132
|
+
Potentially destructive statements are tracked in query history, and SQLite Hub keeps the active result tab instead of forcing you back to Results after every execution.
|
|
133
|
+
|
|
134
|
+
Multi-statement SQL is reported statement by statement, including returned rows, affected rows, truncation warnings, executed SQL, errors, timing, and serialized result size.
|
|
112
135
|
|
|
113
136
|
### Query history
|
|
114
137
|
|
|
115
|
-
[](./frontend/assets/mockups/sql_editor_2_query_detail_1920.webp)
|
|
116
139
|
|
|
117
140
|
SQLite Hub stores query history per database. You can browse recent and saved tabs, search SQL, titles, and notes, assign titles and notes, mark useful queries as saved, delete history entries, load older entries, re-run previous queries, reopen them in the editor, and execute saved queries from the CLI.
|
|
118
141
|
|
|
119
142
|
### Documents
|
|
120
143
|
|
|
121
|
-
[](./frontend/assets/mockups/documents_1_1920.webp)
|
|
122
145
|
|
|
123
|
-
Documents are local Markdown notes scoped to the active database. SQLite Hub creates a document folder per database
|
|
146
|
+
Documents are local Markdown notes scoped to the active database. SQLite Hub creates a document folder per database. You can import `.md` files, export the current document as Markdown.
|
|
124
147
|
|
|
125
148
|
The preview supports regular Markdown, ordered and unordered lists, tables, code blocks, links, and clickable task-list checkboxes. Documents can also pull context from saved SQL Editor queries:
|
|
126
149
|
|
|
@@ -128,56 +151,64 @@ The preview supports regular Markdown, ordered and unordered lists, tables, code
|
|
|
128
151
|
- Insert Note opens saved queries that have notes and inserts the selected note directly into the document.
|
|
129
152
|
- Markdown Todo column exports from query results can create a new document without embedding the original SQL query.
|
|
130
153
|
|
|
154
|
+
<p>
|
|
155
|
+
<a href="./frontend/assets/mockups/documents_2_document_insert_table_modal_1920.webp"><img src="./frontend/assets/mockups/documents_2_document_insert_table_modal_1920.webp" alt="SQLite Hub insert saved query table into a document" width="49%"></a>
|
|
156
|
+
<a href="./frontend/assets/mockups/documents_3_document_insert_note_modal_1920.webp"><img src="./frontend/assets/mockups/documents_3_document_insert_note_modal_1920.webp" alt="SQLite Hub insert saved query note into a document" width="49%"></a>
|
|
157
|
+
</p>
|
|
158
|
+
|
|
131
159
|
### Charts
|
|
132
160
|
|
|
133
|
-
[](./frontend/assets/mockups/charts_1_1920.webp)
|
|
134
162
|
|
|
135
163
|
Create bar, line, pie/donut, and scatter charts from chartable `SELECT` query-history entries. Charts can be saved per query, edited, deleted, resized, reopened later, rendered from live query results, and exported as PNG. Chart configuration supports compatible column selection, sorting, labels, legends, line smoothing, scatter series, and optional scatter point sizing.
|
|
136
164
|
|
|
137
165
|
<p>
|
|
138
|
-
<a href="./frontend/assets/mockups/
|
|
139
|
-
<a href="./frontend/assets/mockups/
|
|
166
|
+
<a href="./frontend/assets/mockups/charts_2_query_detail_1920.webp"><img src="./frontend/assets/mockups/charts_2_query_detail_1920.webp" alt="SQLite Hub chart query detail drawer" width="49%"></a>
|
|
167
|
+
<a href="./frontend/assets/mockups/charts_3_create_query_chart_modal_1920.webp"><img src="./frontend/assets/mockups/charts_3_create_query_chart_modal_1920.webp" alt="SQLite Hub create chart modal" width="49%"></a>
|
|
168
|
+
</p>
|
|
169
|
+
|
|
170
|
+
<p>
|
|
171
|
+
<a href="./frontend/assets/mockups/charts_4_edit_query_chart_modal_1920.webp"><img src="./frontend/assets/mockups/charts_4_edit_query_chart_modal_1920.webp" alt="SQLite Hub edit chart modal" width="49%"></a>
|
|
172
|
+
<a href="./frontend/assets/mockups/charts_5_delete_query_chart_modal_1920.webp"><img src="./frontend/assets/mockups/charts_5_delete_query_chart_modal_1920.webp" alt="SQLite Hub delete chart modal" width="49%"></a>
|
|
140
173
|
</p>
|
|
141
174
|
|
|
175
|
+
[](./frontend/assets/mockups/charts_6_copy_column_modal_1920.webp)
|
|
176
|
+
|
|
142
177
|
### Table Designer
|
|
143
178
|
|
|
144
|
-
[](./frontend/assets/mockups/table_designer_1_1920.webp)
|
|
145
180
|
|
|
146
181
|
Create and edit SQLite tables from the UI. The Table Designer includes a searchable table list, validation and migration warnings, and controls for column names, SQLite types, `NOT NULL`, `UNIQUE`, primary keys, SQL defaults, foreign-key tables/columns, and check constraints. Existing composite unique constraints are surfaced as schema metadata.
|
|
147
182
|
|
|
148
183
|
CSV files can seed a new table draft and optionally fill the created table with imported rows. Every change produces a copyable live SQL preview that can be hidden or shown before the schema operation is applied.
|
|
149
184
|
|
|
150
|
-
[](./frontend/assets/mockups/table_designer_2_table_designer_constraints_modal_1920.webp)
|
|
151
186
|
|
|
152
187
|
### Media Tagging
|
|
153
188
|
|
|
154
|
-
[](./frontend/assets/mockups/media_tagging_setup_1_1920.webp)
|
|
155
190
|
|
|
156
191
|
Configure a media table, path/status columns, tag table, mapping table, and the SQL queries that drive tagged and untagged queues. SQLite Hub can create the default tag and mapping tables, validate the setup, reset default queries, and preview image, video, and audio assets from paths scoped to the active database directory.
|
|
157
192
|
|
|
158
|
-
The queue supports tag search, tag creation/removal, parent tags, copying tags from the previous item, applying selected tags, skipping items, resetting skipped items, rotating visual media, hiding/showing media details, and opening the current row in Data or Structure. `Shift + Enter` applies the selected tags and advances to the next item.
|
|
159
|
-
|
|
160
193
|
<p>
|
|
161
|
-
<a href="./frontend/assets/mockups/
|
|
162
|
-
<a href="./frontend/assets/mockups/
|
|
194
|
+
<a href="./frontend/assets/mockups/media_tagging_setup_2_create_media_tagging_tag_table_modal_1920.webp"><img src="./frontend/assets/mockups/media_tagging_setup_2_create_media_tagging_tag_table_modal_1920.webp" alt="SQLite Hub create media tagging tag table modal" width="49%"></a>
|
|
195
|
+
<a href="./frontend/assets/mockups/media_tagging_setup_3_create_media_tagging_mapping_table_modal_1920.webp"><img src="./frontend/assets/mockups/media_tagging_setup_3_create_media_tagging_mapping_table_modal_1920.webp" alt="SQLite Hub create media tagging mapping table modal" width="49%"></a>
|
|
163
196
|
</p>
|
|
164
197
|
|
|
165
|
-
|
|
198
|
+
The queue supports tag search, tag creation/removal, parent tags, copying tags from the previous item, applying selected tags, skipping items, resetting skipped items, rotating visual media, hiding/showing media details, and opening the current row in Data or Structure. `Shift + Enter` applies the selected tags and advances to the next item.
|
|
166
199
|
|
|
167
|
-
SQLite Hub
|
|
200
|
+
[](./frontend/assets/mockups/media_tagging_queue_1_1920.webp)
|
|
168
201
|
|
|
169
202
|
### Settings
|
|
170
203
|
|
|
171
|
-
[](./frontend/assets/mockups/settings_1_1920.webp)
|
|
174
205
|
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
The active database footer in the sidebar opens a quick-pick panel with the five most recent databases, so you can switch databases without going back to the Connections view.
|
|
206
|
+
The Settings view reports the installed SQLite Hub version and the actual SQLite runtime version used to execute queries.
|
|
178
207
|
|
|
179
208
|
### Backup Manager
|
|
180
209
|
|
|
210
|
+
[](./frontend/assets/mockups/backups_1_1920.webp)
|
|
211
|
+
|
|
181
212
|
Create verified local backups of the active SQLite database, review backup metadata, edit backup notes, download backup files, restore verified backups, and delete managed backups from the Backups view. SQLite Hub stores backup files under its local app-state backup directory by connection id and keeps a `manifest.json` beside each database's backup files. Each backup is created through SQLite's backup API, hashed with SHA-256, and verified with `PRAGMA quick_check` before it is marked as verified.
|
|
182
213
|
|
|
183
214
|
SQLite Hub also proposes a safety backup before operations that can be hard to undo:
|
|
@@ -189,41 +220,52 @@ SQLite Hub also proposes a safety backup before operations that can be hard to u
|
|
|
189
220
|
|
|
190
221
|
The safety dialog lets you create the backup and continue, continue without creating one, or cancel the operation.
|
|
191
222
|
|
|
192
|
-
|
|
223
|
+
<p>
|
|
224
|
+
<a href="./frontend/assets/mockups/backups_2_create_backup_modal_1920.webp"><img src="./frontend/assets/mockups/backups_2_create_backup_modal_1920.webp" alt="SQLite Hub create backup modal" width="49%"></a>
|
|
225
|
+
<a href="./frontend/assets/mockups/backups_3_edit_backup_modal_1920.webp"><img src="./frontend/assets/mockups/backups_3_edit_backup_modal_1920.webp" alt="SQLite Hub edit backup modal" width="49%"></a>
|
|
226
|
+
</p>
|
|
193
227
|
|
|
194
|
-
|
|
228
|
+
<p>
|
|
229
|
+
<a href="./frontend/assets/mockups/backups_4_restore_backup_modal_1920.webp"><img src="./frontend/assets/mockups/backups_4_restore_backup_modal_1920.webp" alt="SQLite Hub restore backup modal" width="49%"></a>
|
|
230
|
+
<a href="./frontend/assets/mockups/backups_5_delete_backup_modal_1920.webp"><img src="./frontend/assets/mockups/backups_5_delete_backup_modal_1920.webp" alt="SQLite Hub delete backup modal" width="49%"></a>
|
|
231
|
+
</p>
|
|
195
232
|
|
|
196
|
-
|
|
233
|
+
### Overview
|
|
197
234
|
|
|
198
|
-
|
|
235
|
+
The database overview combines operational and schema information for the active database:
|
|
199
236
|
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
237
|
+
- file size, page count, table/view counts, index/trigger counts, journal mode, and foreign-key status
|
|
238
|
+
- largest tables by row count and estimated size
|
|
239
|
+
- database path, modification time, SQLite version, page size, freelist count, and encoding
|
|
240
|
+
- schema-map statistics for foreign-key links, connected clusters, and isolated tables
|
|
241
|
+
- integrity and quick-check results, access mode, user version, and schema version
|
|
242
|
+
- shortcuts to the SQL Editor, Structure view, and the database location in Finder
|
|
204
243
|
|
|
205
|
-
###
|
|
244
|
+
### Connections
|
|
206
245
|
|
|
207
|
-
|
|
208
|
-
npm install -g sqlite-hub
|
|
209
|
-
```
|
|
246
|
+
[](./frontend/assets/mockups/connections_1_1920.webp)
|
|
210
247
|
|
|
211
|
-
|
|
248
|
+
Recent connections show file size, modification time, last-opened time, and access mode. Connections can be activated, relabeled, moved to another path, opened read-only, assigned a PNG/JPG/WEBP icon, reset to the default icon, or removed from the recent-connections registry without deleting the database file.
|
|
212
249
|
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
250
|
+
<p>
|
|
251
|
+
<a href="./frontend/assets/mockups/connections_2_create_connection_modal_1920.webp"><img src="./frontend/assets/mockups/connections_2_create_connection_modal_1920.webp" alt="SQLite Hub create connection modal" width="49%"></a>
|
|
252
|
+
<a href="./frontend/assets/mockups/connections_3_open_connection_modal_1920.webp"><img src="./frontend/assets/mockups/connections_3_open_connection_modal_1920.webp" alt="SQLite Hub open connection modal" width="49%"></a>
|
|
253
|
+
</p>
|
|
254
|
+
|
|
255
|
+
### Local-first
|
|
256
|
+
|
|
257
|
+
Built around local SQLite files, not hosted dashboards or team complexity. The server binds explicitly to the IPv4 loopback interface, and API middleware rejects foreign hosts and cross-origin mutations while still allowing same-origin browser and local CLI requests.
|
|
216
258
|
|
|
217
259
|
## CLI
|
|
218
260
|
|
|
219
261
|
SQLite Hub ships with a built-in CLI for starting the app, inspecting imported
|
|
220
262
|
databases, executing raw or saved SQL, exporting query results, exporting single
|
|
221
|
-
rows as JSON, and working with Markdown documents. See the
|
|
263
|
+
rows as JSON, generating schema types, and working with Markdown documents. See the
|
|
222
264
|
[CLI documentation](./docs/CLI.md) for commands, flags, and examples.
|
|
223
265
|
|
|
224
266
|
## API
|
|
225
267
|
|
|
226
|
-
SQLite Hub also provides a local JSON API for app info, database metadata, tables, saved queries, exports, and
|
|
268
|
+
SQLite Hub also provides a local JSON API for app info, database metadata, tables, saved queries, exports, documents, and schema type generation. `/api/v1/info` returns the same app/version status as `sqlite-hub --info`; database data is protected by database-specific API itokens created in Settings. See the [API documentation](./docs/API.md) for authentication, endpoints, and examples.
|
|
227
269
|
|
|
228
270
|
## Changelog
|
|
229
271
|
|