diff --git a/Cargo.lock b/Cargo.lock index b9fb98654..36bd121b6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1157,6 +1157,15 @@ dependencies = [ "zip 9.1.1", ] +[[package]] +name = "craft-web-host" +version = "0.1.0" +source = "git+https://github.com/storytold/craft-libs?rev=2e2312ddaf21bc3d85cd3395d0955c7d239306f6#2e2312ddaf21bc3d85cd3395d0955c7d239306f6" +dependencies = [ + "wasm-bindgen", + "web-sys", +] + [[package]] name = "craft-window" version = "0.1.0" @@ -2121,6 +2130,7 @@ name = "figcraft-web" version = "0.15.0" dependencies = [ "base64 0.22.1", + "craft-web-host", "eframe", "egui", "figcraft-collab-net", diff --git a/apps/figcraft-web/Cargo.toml b/apps/figcraft-web/Cargo.toml index 15f98bee5..7f0b4ded5 100644 --- a/apps/figcraft-web/Cargo.toml +++ b/apps/figcraft-web/Cargo.toml @@ -19,6 +19,8 @@ figcraft-format = { workspace = true } figcraft-ui-egui = { workspace = true } figcraft-collab-net = { workspace = true } figcraft-text = { workspace = true } +# The host messages (storytold/craft-libs): one contract and one bridge for the web builds. +craft-web-host = { git = "https://github.com/storytold/craft-libs", rev = "2e2312ddaf21bc3d85cd3395d0955c7d239306f6", version = "0.1.0" } base64 = { workspace = true } egui = { workspace = true } log = { workspace = true } diff --git a/apps/figcraft-web/src/host.rs b/apps/figcraft-web/src/host.rs index 5ed0f683a..1000c1490 100644 --- a/apps/figcraft-web/src/host.rs +++ b/apps/figcraft-web/src/host.rs @@ -1,23 +1,21 @@ //! Host modes: a page that runs FigCraft (as an `