mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2025-12-23 10:11:54 +00:00
* wasm: do the async initialization only once This allows the rest of the app to access wasm synchronously. This allows removing of a global. * provide the wasm via vue provide/inject. There's still code directly accessing the wasm. That will be changed later. * MenuBarInput: use injected wasm instead of the global instance * Let the App handle event listeners * move stateful modules into state/ * state/fullscreen: create per instance * App: load the initial document list on mount. This got lost a few commits ago. Now it's back. * state/dialog: create per instance * util/input: remove dependency on global dialog instance * state/documents: create per instance * reponse-handler: move into EditorWasm * comingSoon: move into dialog * wasm: allow instantiating multiple editors * input handlers: do not look at canvases outside the mounted App * input: listen on the container instead of the window when possible * - removed proxy from wasm-loader - integrated with js-dispatcher - state functions to classes - integrated some upstream changes * fix errors caused by merge * Getting closer: - added global state to track all instances - fix fullscreen close trigger - wasm-loader is statefull - panic across instanes * - fix outline while using editor - removed circular import rule - added editorInstance to js message constructor * - changed input handler to a class - still need a better way of handeling it in App.vue * - fixed single instance of inputManager to weakmap * - fix no-explicit-any in a few places - removed global state from input.ts * simplified two long lines * removed global state * removed $data from App * add mut self to functions in api.rs * Update Workspace.vue remove outdated import * fixed missing import * Changes throughout code review; note this causes some bugs to be fixed in a later commit * PR review round 1 * - fix coming soon bugs - changed folder structure * moved declaration to .d.ts * - changed from classes to functions - moved decs back to app.vue * removed need to export js function to rust * changed folder structure * fixed indentation breaking multiline strings * Fix eslint rule to whitelist @/../ * Simplify strip-indents implementation * replace type assertions with better annotations or proper runtime checks * Small tweaks and code rearranging improvements after second code review pass * maybe fix mouse events * Add back preventDefault for mouse scroll * code review round 2 * Comment improvements * -removed runtime checks - fixed layers not showing * - extened proxy to cover classes - stopped multiple panics from logging - Stop wasm-bindgen from mut ref counting our struct * cleaned up messageConstructors exports * Fix input and fullscreen regressions Co-authored-by: Max Fisher <maxmfishernj@gmail.com> Co-authored-by: mfish33 <32677537+mfish33@users.noreply.github.com> Co-authored-by: Keavon Chambers <keavon@keavon.com>
503 lines
12 KiB
TOML
503 lines
12 KiB
TOML
# This file is automatically @generated by Cargo.
|
|
# It is not intended for manual editing.
|
|
version = 3
|
|
|
|
[[package]]
|
|
name = "aho-corasick"
|
|
version = "0.7.18"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "1e37cfd5e7657ada45f742d6e99ca5788580b5c529dc78faf11ece6dc702656f"
|
|
dependencies = [
|
|
"memchr",
|
|
]
|
|
|
|
[[package]]
|
|
name = "arrayvec"
|
|
version = "0.5.2"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "23b62fc65de8e4e7f52534fb52b0f3ed04746ae267519eef2a83941e8085068b"
|
|
|
|
[[package]]
|
|
name = "atty"
|
|
version = "0.2.14"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "d9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8"
|
|
dependencies = [
|
|
"hermit-abi",
|
|
"libc",
|
|
"winapi",
|
|
]
|
|
|
|
[[package]]
|
|
name = "bitflags"
|
|
version = "1.3.2"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a"
|
|
|
|
[[package]]
|
|
name = "bumpalo"
|
|
version = "3.8.0"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "8f1e260c3a9040a7c19a12468758f4c16f31a81a1fe087482be9570ec864bb6c"
|
|
|
|
[[package]]
|
|
name = "cfg-if"
|
|
version = "1.0.0"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"
|
|
|
|
[[package]]
|
|
name = "console_error_panic_hook"
|
|
version = "0.1.7"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "a06aeb73f470f66dcdbf7223caeebb85984942f22f1adb2a088cf9668146bbbc"
|
|
dependencies = [
|
|
"cfg-if",
|
|
"wasm-bindgen",
|
|
]
|
|
|
|
[[package]]
|
|
name = "env_logger"
|
|
version = "0.8.4"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "a19187fea3ac7e84da7dacf48de0c45d63c6a76f9490dae389aead16c243fce3"
|
|
dependencies = [
|
|
"atty",
|
|
"humantime",
|
|
"log",
|
|
"regex",
|
|
"termcolor",
|
|
]
|
|
|
|
[[package]]
|
|
name = "glam"
|
|
version = "0.17.3"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "e01732b97afd8508eee3333a541b9f7610f454bb818669e66e90f5f57c93a776"
|
|
dependencies = [
|
|
"serde",
|
|
]
|
|
|
|
[[package]]
|
|
name = "graphite-charcoal"
|
|
version = "0.1.0"
|
|
|
|
[[package]]
|
|
name = "graphite-editor"
|
|
version = "0.1.0"
|
|
dependencies = [
|
|
"bitflags",
|
|
"env_logger",
|
|
"glam",
|
|
"graphite-graphene",
|
|
"graphite-proc-macros",
|
|
"kurbo",
|
|
"log",
|
|
"rand_chacha",
|
|
"serde",
|
|
"spin",
|
|
"thiserror",
|
|
]
|
|
|
|
[[package]]
|
|
name = "graphite-graphene"
|
|
version = "0.1.0"
|
|
dependencies = [
|
|
"glam",
|
|
"kurbo",
|
|
"log",
|
|
"serde",
|
|
"serde_json",
|
|
]
|
|
|
|
[[package]]
|
|
name = "graphite-proc-macros"
|
|
version = "0.1.0"
|
|
dependencies = [
|
|
"graphite-editor",
|
|
"proc-macro2",
|
|
"quote",
|
|
"syn",
|
|
]
|
|
|
|
[[package]]
|
|
name = "graphite-wasm"
|
|
version = "0.1.0"
|
|
dependencies = [
|
|
"graphite-editor",
|
|
"graphite-graphene",
|
|
"js-sys",
|
|
"log",
|
|
"serde",
|
|
"wasm-bindgen",
|
|
"wasm-bindgen-test",
|
|
]
|
|
|
|
[[package]]
|
|
name = "hermit-abi"
|
|
version = "0.1.19"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33"
|
|
dependencies = [
|
|
"libc",
|
|
]
|
|
|
|
[[package]]
|
|
name = "humantime"
|
|
version = "2.1.0"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4"
|
|
|
|
[[package]]
|
|
name = "itoa"
|
|
version = "0.4.8"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "b71991ff56294aa922b450139ee08b3bfc70982c6b2c7562771375cf73542dd4"
|
|
|
|
[[package]]
|
|
name = "js-sys"
|
|
version = "0.3.55"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "7cc9ffccd38c451a86bf13657df244e9c3f37493cce8e5e21e940963777acc84"
|
|
dependencies = [
|
|
"wasm-bindgen",
|
|
]
|
|
|
|
[[package]]
|
|
name = "kurbo"
|
|
version = "0.8.1"
|
|
source = "git+https://github.com/GraphiteEditor/kurbo.git#d3d469d91bd42d6f9665e48e5d56dce66a7e183c"
|
|
dependencies = [
|
|
"arrayvec",
|
|
"serde",
|
|
]
|
|
|
|
[[package]]
|
|
name = "lazy_static"
|
|
version = "1.4.0"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646"
|
|
|
|
[[package]]
|
|
name = "libc"
|
|
version = "0.2.106"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "a60553f9a9e039a333b4e9b20573b9e9b9c0bb3a11e201ccc48ef4283456d673"
|
|
|
|
[[package]]
|
|
name = "lock_api"
|
|
version = "0.4.5"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "712a4d093c9976e24e7dbca41db895dabcbac38eb5f4045393d17a95bdfb1109"
|
|
dependencies = [
|
|
"scopeguard",
|
|
]
|
|
|
|
[[package]]
|
|
name = "log"
|
|
version = "0.4.14"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "51b9bbe6c47d51fc3e1a9b945965946b4c44142ab8792c50835a980d362c2710"
|
|
dependencies = [
|
|
"cfg-if",
|
|
]
|
|
|
|
[[package]]
|
|
name = "memchr"
|
|
version = "2.4.1"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "308cc39be01b73d0d18f82a0e7b2a3df85245f84af96fdddc5d202d27e47b86a"
|
|
|
|
[[package]]
|
|
name = "ppv-lite86"
|
|
version = "0.2.15"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "ed0cfbc8191465bed66e1718596ee0b0b35d5ee1f41c5df2189d0fe8bde535ba"
|
|
|
|
[[package]]
|
|
name = "proc-macro2"
|
|
version = "1.0.32"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "ba508cc11742c0dc5c1659771673afbab7a0efab23aa17e854cbab0837ed0b43"
|
|
dependencies = [
|
|
"unicode-xid",
|
|
]
|
|
|
|
[[package]]
|
|
name = "quote"
|
|
version = "1.0.10"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "38bc8cc6a5f2e3655e0899c1b848643b2562f853f114bfec7be120678e3ace05"
|
|
dependencies = [
|
|
"proc-macro2",
|
|
]
|
|
|
|
[[package]]
|
|
name = "rand_chacha"
|
|
version = "0.3.1"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88"
|
|
dependencies = [
|
|
"ppv-lite86",
|
|
"rand_core",
|
|
]
|
|
|
|
[[package]]
|
|
name = "rand_core"
|
|
version = "0.6.3"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "d34f1408f55294453790c48b2f1ebbb1c5b4b7563eb1f418bcfcfdbb06ebb4e7"
|
|
|
|
[[package]]
|
|
name = "regex"
|
|
version = "1.5.4"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "d07a8629359eb56f1e2fb1652bb04212c072a87ba68546a04065d525673ac461"
|
|
dependencies = [
|
|
"aho-corasick",
|
|
"memchr",
|
|
"regex-syntax",
|
|
]
|
|
|
|
[[package]]
|
|
name = "regex-syntax"
|
|
version = "0.6.25"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "f497285884f3fcff424ffc933e56d7cbca511def0c9831a7f9b5f6153e3cc89b"
|
|
|
|
[[package]]
|
|
name = "ryu"
|
|
version = "1.0.5"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "71d301d4193d031abdd79ff7e3dd721168a9572ef3fe51a1517aba235bd8f86e"
|
|
|
|
[[package]]
|
|
name = "scoped-tls"
|
|
version = "1.0.0"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "ea6a9290e3c9cf0f18145ef7ffa62d68ee0bf5fcd651017e586dc7fd5da448c2"
|
|
|
|
[[package]]
|
|
name = "scopeguard"
|
|
version = "1.1.0"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd"
|
|
|
|
[[package]]
|
|
name = "serde"
|
|
version = "1.0.130"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "f12d06de37cf59146fbdecab66aa99f9fe4f78722e3607577a5375d66bd0c913"
|
|
dependencies = [
|
|
"serde_derive",
|
|
]
|
|
|
|
[[package]]
|
|
name = "serde_derive"
|
|
version = "1.0.130"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "d7bc1a1ab1961464eae040d96713baa5a724a8152c1222492465b54322ec508b"
|
|
dependencies = [
|
|
"proc-macro2",
|
|
"quote",
|
|
"syn",
|
|
]
|
|
|
|
[[package]]
|
|
name = "serde_json"
|
|
version = "1.0.68"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "0f690853975602e1bfe1ccbf50504d67174e3bcf340f23b5ea9992e0587a52d8"
|
|
dependencies = [
|
|
"itoa",
|
|
"ryu",
|
|
"serde",
|
|
]
|
|
|
|
[[package]]
|
|
name = "spin"
|
|
version = "0.9.2"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "511254be0c5bcf062b019a6c89c01a664aa359ded62f78aa72c6fc137c0590e5"
|
|
dependencies = [
|
|
"lock_api",
|
|
]
|
|
|
|
[[package]]
|
|
name = "syn"
|
|
version = "1.0.81"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "f2afee18b8beb5a596ecb4a2dce128c719b4ba399d34126b9e4396e3f9860966"
|
|
dependencies = [
|
|
"proc-macro2",
|
|
"quote",
|
|
"unicode-xid",
|
|
]
|
|
|
|
[[package]]
|
|
name = "termcolor"
|
|
version = "1.1.2"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "2dfed899f0eb03f32ee8c6a0aabdb8a7949659e3466561fc0adf54e26d88c5f4"
|
|
dependencies = [
|
|
"winapi-util",
|
|
]
|
|
|
|
[[package]]
|
|
name = "thiserror"
|
|
version = "1.0.30"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "854babe52e4df1653706b98fcfc05843010039b406875930a70e4d9644e5c417"
|
|
dependencies = [
|
|
"thiserror-impl",
|
|
]
|
|
|
|
[[package]]
|
|
name = "thiserror-impl"
|
|
version = "1.0.30"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "aa32fd3f627f367fe16f893e2597ae3c05020f8bba2666a4e6ea73d377e5714b"
|
|
dependencies = [
|
|
"proc-macro2",
|
|
"quote",
|
|
"syn",
|
|
]
|
|
|
|
[[package]]
|
|
name = "unicode-xid"
|
|
version = "0.2.2"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "8ccb82d61f80a663efe1f787a51b16b5a51e3314d6ac365b08639f52387b33f3"
|
|
|
|
[[package]]
|
|
name = "wasm-bindgen"
|
|
version = "0.2.78"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "632f73e236b219150ea279196e54e610f5dbafa5d61786303d4da54f84e47fce"
|
|
dependencies = [
|
|
"cfg-if",
|
|
"serde",
|
|
"serde_json",
|
|
"wasm-bindgen-macro",
|
|
]
|
|
|
|
[[package]]
|
|
name = "wasm-bindgen-backend"
|
|
version = "0.2.78"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "a317bf8f9fba2476b4b2c85ef4c4af8ff39c3c7f0cdfeed4f82c34a880aa837b"
|
|
dependencies = [
|
|
"bumpalo",
|
|
"lazy_static",
|
|
"log",
|
|
"proc-macro2",
|
|
"quote",
|
|
"syn",
|
|
"wasm-bindgen-shared",
|
|
]
|
|
|
|
[[package]]
|
|
name = "wasm-bindgen-futures"
|
|
version = "0.4.28"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "8e8d7523cb1f2a4c96c1317ca690031b714a51cc14e05f712446691f413f5d39"
|
|
dependencies = [
|
|
"cfg-if",
|
|
"js-sys",
|
|
"wasm-bindgen",
|
|
"web-sys",
|
|
]
|
|
|
|
[[package]]
|
|
name = "wasm-bindgen-macro"
|
|
version = "0.2.78"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "d56146e7c495528bf6587663bea13a8eb588d39b36b679d83972e1a2dbbdacf9"
|
|
dependencies = [
|
|
"quote",
|
|
"wasm-bindgen-macro-support",
|
|
]
|
|
|
|
[[package]]
|
|
name = "wasm-bindgen-macro-support"
|
|
version = "0.2.78"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "7803e0eea25835f8abdc585cd3021b3deb11543c6fe226dcd30b228857c5c5ab"
|
|
dependencies = [
|
|
"proc-macro2",
|
|
"quote",
|
|
"syn",
|
|
"wasm-bindgen-backend",
|
|
"wasm-bindgen-shared",
|
|
]
|
|
|
|
[[package]]
|
|
name = "wasm-bindgen-shared"
|
|
version = "0.2.78"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "0237232789cf037d5480773fe568aac745bfe2afbc11a863e97901780a6b47cc"
|
|
|
|
[[package]]
|
|
name = "wasm-bindgen-test"
|
|
version = "0.3.28"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "96f1aa7971fdf61ef0f353602102dbea75a56e225ed036c1e3740564b91e6b7e"
|
|
dependencies = [
|
|
"console_error_panic_hook",
|
|
"js-sys",
|
|
"scoped-tls",
|
|
"wasm-bindgen",
|
|
"wasm-bindgen-futures",
|
|
"wasm-bindgen-test-macro",
|
|
]
|
|
|
|
[[package]]
|
|
name = "wasm-bindgen-test-macro"
|
|
version = "0.3.28"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "6006f79628dfeb96a86d4db51fbf1344cd7fd8408f06fc9aa3c84913a4789688"
|
|
dependencies = [
|
|
"proc-macro2",
|
|
"quote",
|
|
]
|
|
|
|
[[package]]
|
|
name = "web-sys"
|
|
version = "0.3.55"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "38eb105f1c59d9eaa6b5cdc92b859d85b926e82cb2e0945cd0c9259faa6fe9fb"
|
|
dependencies = [
|
|
"js-sys",
|
|
"wasm-bindgen",
|
|
]
|
|
|
|
[[package]]
|
|
name = "winapi"
|
|
version = "0.3.9"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419"
|
|
dependencies = [
|
|
"winapi-i686-pc-windows-gnu",
|
|
"winapi-x86_64-pc-windows-gnu",
|
|
]
|
|
|
|
[[package]]
|
|
name = "winapi-i686-pc-windows-gnu"
|
|
version = "0.4.0"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6"
|
|
|
|
[[package]]
|
|
name = "winapi-util"
|
|
version = "0.1.5"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178"
|
|
dependencies = [
|
|
"winapi",
|
|
]
|
|
|
|
[[package]]
|
|
name = "winapi-x86_64-pc-windows-gnu"
|
|
version = "0.4.0"
|
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
|