mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-17 15:28:04 +08:00
* Restore ESLint and Prettier autoformatting * Fix formatting and lints in web files * Hacky fix to eslint crash * Fix remaining lints * Add lint-fix script --------- Co-authored-by: 0hypercube <0hypercube@gmail.com>
10 lines
379 B
TypeScript
10 lines
379 B
TypeScript
import { type Editor } from "@graphite/wasm-communication/editor";
|
|
import { TriggerVisitLink } from "@graphite/wasm-communication/messages";
|
|
|
|
export function createHyperlinkManager(editor: Editor) {
|
|
// Subscribe to process backend event
|
|
editor.subscriptions.subscribeJsMessage(TriggerVisitLink, async (triggerOpenLink) => {
|
|
window.open(triggerOpenLink.url, "_blank");
|
|
});
|
|
}
|