Support SQLite

This commit is contained in:
1ilit
2024-01-31 17:00:15 +02:00
parent a31e60cf0d
commit 6985eb2fdc
2 changed files with 100 additions and 0 deletions

View File

@@ -45,6 +45,7 @@ import {
dataURItoBlob,
jsonToMySQL,
jsonToPostgreSQL,
jsonToSQLite
} from "../utils";
import {
AreaContext,
@@ -978,6 +979,21 @@ export default function ControlPanel({
}));
},
},
{
SQLite: () => {
setVisible(MODAL.CODE);
const src = jsonToSQLite({
tables: tables,
references: relationships,
types: types,
});
setExportData((prev) => ({
...prev,
data: src,
extension: "sql",
}));
},
},
{ DBML: () => { } },
],
function: () => { },