Commit b10ab47a64b81da1eb367b7a017167ae66d6d12e

Authored by Georg Hopp
1 parent 1c5a0bed

wasm not part of workspace and others

1 1 Cargo.lock
2 2 **/*.rs.bk
3 3
4   -/target
  4 +**/target
5 5 /pkg
6 6 /static/ui/
... ...
1 1 [workspace]
2   -members = [ "server", "ui" ]
3   -default-members = [ "server" ]
  2 +members = [ "common", "server" ]
4 3
5 4 [profile.release]
6 5 lto = true
... ...
... ... @@ -11,6 +11,10 @@
11 11 padding-left: 5px;
12 12 }
13 13
  14 +.upload > div > button {
  15 + float: right;
  16 +}
  17 +
14 18 .upload > ul {
15 19 max-height: 15em;
16 20 width: calc(100% - 10px);
... ...
  1 +[alias]
  2 +check-lib = ["check", "--lib"]
  3 +
  4 +[build]
  5 +target = "wasm32-unknown-unknown"
... ...
... ... @@ -2,12 +2,13 @@
2 2 name = "artshop-frontend"
3 3 version = "0.0.0"
4 4 authors = ["Georg Hopp <georg@steffers.org>"]
5   -workspace = ".."
6 5 edition = "2018"
7 6 description = "WASM client with mogwai components"
8 7 repository = "https://gitlab.weird-web-workers.org/rust/artshop"
9 8 license = "GPL-3.0-or-later"
10 9
  10 +[workspace]
  11 +
11 12 [lib]
12 13 crate-type = ["cdylib", "rlib"]
13 14
... ... @@ -20,6 +21,7 @@ console_log = "^0.1"
20 21 js-sys = "^0.3"
21 22 #katex = { version = "0.4", default-features = false, features = ["wasm-js"] }
22 23 log = "^0.4"
  24 +mogwai = "^0.5"
23 25 pulldown-cmark = "0.9"
24 26 serde = { version = "^1.0", features = ["derive"] }
25 27 serde_json = "^1.0"
... ... @@ -33,9 +35,6 @@ wee_alloc = { version = "0.4.2", optional = true }
33 35 # code size when deploying.
34 36 console_error_panic_hook = { version = "0.1.6", optional = true }
35 37
36   -[dependencies.mogwai]
37   -version = "^0.5"
38   -
39 38 [dependencies.web-sys]
40 39 version = "^0.3"
41 40 features = [
... ...
... ... @@ -12,7 +12,15 @@ pub(crate) async fn new() -> Component<Dom> {
12 12 let (tx_toggle, rx_toggle) = broadcast::bounded(1);
13 13 let (tx_patches, rx_patches) = mpmc::bounded(1);
14 14
15   - let view = markdown_view(tx_logic.clone(), rx_toggle, rx_patches, tx_dom);
16   - let logic = markdown_logic(rx_logic, tx_logic, tx_toggle, tx_patches, rx_dom);
  15 + let view = markdown_view( tx_logic.clone()
  16 + , rx_toggle
  17 + , rx_patches
  18 + , tx_dom );
  19 + let logic = markdown_logic( rx_logic
  20 + , tx_logic
  21 + , tx_toggle
  22 + , tx_patches
  23 + , rx_dom );
  24 +
17 25 Component::from(view).with_logic(logic)
18 26 }
... ...
... ... @@ -49,6 +49,7 @@ pub(super) fn upload_view( tx_logic: broadcast::Sender<UploadLogic>
49 49 </div>
50 50 <ul patch:children=rx_previews>
51 51 </ul>
  52 + <p>"Click on preview to "<em>"deselect"</em>"."</p>
52 53 </div>
53 54 }
54 55 }
... ...
1   -extern crate js_sys;
2   -
3 1 mod api;
4 2 mod data;
5 3 mod error;
... ...
Please register or login to post a comment