wip fix
This commit is contained in:
parent
da56d8d4bb
commit
bce86b5881
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"name": "db",
|
"name": "db",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@prisma/client": "^5.7.1",
|
"@prisma/client": "^5.8.1",
|
||||||
"prisma": "^5.7.1"
|
"prisma": "^5.8.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -225,6 +225,7 @@ model site {
|
||||||
is_deleted Boolean @default(false)
|
is_deleted Boolean @default(false)
|
||||||
responsive String @default("all")
|
responsive String @default("all")
|
||||||
npm_cache String @default(" ") @db.VarChar
|
npm_cache String @default(" ") @db.VarChar
|
||||||
|
code_mode String @default("old") @db.VarChar(5)
|
||||||
code code[]
|
code code[]
|
||||||
component_site component_site[]
|
component_site component_site[]
|
||||||
npm_site npm_site[]
|
npm_site npm_site[]
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,9 @@
|
||||||
import { validate } from "uuid";
|
import { validate } from "uuid";
|
||||||
import { ESite } from "../../../../web/src/nova/ed/logic/ed-global";
|
import { ESite } from "../../../../web/src/nova/ed/logic/ed-global";
|
||||||
import { SAction } from "../actions";
|
import { SAction } from "../actions";
|
||||||
|
import { prepCode } from "../editor/code/prep-code";
|
||||||
import { activity } from "../entity/activity";
|
import { activity } from "../entity/activity";
|
||||||
import { SyncConnection } from "../type";
|
import { SyncConnection } from "../type";
|
||||||
import { prepCode } from "../editor/code/prep-code";
|
|
||||||
import { docs } from "../entity/docs";
|
|
||||||
import { snapshot } from "../entity/snapshot";
|
|
||||||
|
|
||||||
export const site_load: SAction["site"]["load"] = async function (
|
export const site_load: SAction["site"]["load"] = async function (
|
||||||
this: SyncConnection,
|
this: SyncConnection,
|
||||||
|
|
@ -40,10 +38,10 @@ export const site_load: SAction["site"]["load"] = async function (
|
||||||
config: config as ESite["config"],
|
config: config as ESite["config"],
|
||||||
domain: site.domain,
|
domain: site.domain,
|
||||||
js: site.js || "",
|
js: site.js || "",
|
||||||
responsive: site.responsive,
|
responsive: site.responsive as ESite["responsive"],
|
||||||
js_compiled: site.js_compiled || "",
|
js_compiled: site.js_compiled || "",
|
||||||
layout: { id: layout?.id || "", snapshot: null },
|
layout: { id: layout?.id || "", snapshot: null, meta: undefined },
|
||||||
code: { snapshot: null },
|
code: { snapshot: null, mode: site.code_mode as "old" | "vsc" },
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -25,6 +25,7 @@ export const EmptySite = {
|
||||||
},
|
},
|
||||||
code: {
|
code: {
|
||||||
snapshot: null as null | Uint8Array,
|
snapshot: null as null | Uint8Array,
|
||||||
|
mode: "old" as "old" | "vsc",
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue