fix js paths

This commit is contained in:
Jonas Kruckenberg 2022-11-13 21:07:28 +01:00
parent 355febf927
commit e431dc89a8
7 changed files with 14 additions and 14 deletions

View file

@ -80,7 +80,7 @@ pub async fn hide() -> crate::Result<()> {
mod inner { mod inner {
use wasm_bindgen::{prelude::wasm_bindgen, JsValue}; use wasm_bindgen::{prelude::wasm_bindgen, JsValue};
#[wasm_bindgen(module = "/dist/app.js")] #[wasm_bindgen(module = "/src/app.js")]
extern "C" { extern "C" {
#[wasm_bindgen(catch)] #[wasm_bindgen(catch)]
pub async fn getName() -> Result<JsValue, JsValue>; pub async fn getName() -> Result<JsValue, JsValue>;

View file

@ -36,7 +36,7 @@ pub async fn write_text(text: &str) -> crate::Result<()> {
mod inner { mod inner {
use wasm_bindgen::{prelude::wasm_bindgen, JsValue}; use wasm_bindgen::{prelude::wasm_bindgen, JsValue};
#[wasm_bindgen(module = "/dist/clipboard.js")] #[wasm_bindgen(module = "/src/clipboard.js")]
extern "C" { extern "C" {
#[wasm_bindgen(catch)] #[wasm_bindgen(catch)]
pub async fn readText() -> Result<JsValue, JsValue>; pub async fn readText() -> Result<JsValue, JsValue>;

View file

@ -144,7 +144,7 @@ mod inner {
JsValue, JsValue,
}; };
#[wasm_bindgen(module = "/dist/event.js")] #[wasm_bindgen(module = "/src/event.js")]
extern "C" { extern "C" {
#[wasm_bindgen(catch)] #[wasm_bindgen(catch)]
pub async fn emit(event: &str, payload: JsValue) -> Result<(), JsValue>; pub async fn emit(event: &str, payload: JsValue) -> Result<(), JsValue>;

View file

@ -55,7 +55,7 @@ mod inner {
JsValue, JsValue,
}; };
#[wasm_bindgen(module = "/dist/mocks.js")] #[wasm_bindgen(module = "/src/mocks.js")]
extern "C" { extern "C" {
#[wasm_bindgen(variadic)] #[wasm_bindgen(variadic)]
pub fn mockWindows(current: &str, rest: JsValue); pub fn mockWindows(current: &str, rest: JsValue);

View file

@ -10,7 +10,7 @@ pub fn relaunch() {
mod inner { mod inner {
use wasm_bindgen::prelude::wasm_bindgen; use wasm_bindgen::prelude::wasm_bindgen;
#[wasm_bindgen(module = "/dist/process.js")] #[wasm_bindgen(module = "/src/process.js")]
extern "C" { extern "C" {
pub fn exit(exitCode: u32); pub fn exit(exitCode: u32);
pub fn relaunch(); pub fn relaunch();

View file

@ -95,7 +95,7 @@ pub async fn transform_callback<T: DeserializeOwned>(
mod inner { mod inner {
use wasm_bindgen::{prelude::wasm_bindgen, JsValue}; use wasm_bindgen::{prelude::wasm_bindgen, JsValue};
#[wasm_bindgen(module = "/dist/tauri.js")] #[wasm_bindgen(module = "/src/tauri.js")]
extern "C" { extern "C" {
#[wasm_bindgen(catch)] #[wasm_bindgen(catch)]
pub async fn convertFileSrc( pub async fn convertFileSrc(

View file

@ -626,7 +626,7 @@ mod inner {
JsValue, JsValue,
}; };
#[wasm_bindgen(module = "/dist/window.js")] #[wasm_bindgen(module = "/src/window.js")]
extern "C" { extern "C" {
#[derive(Debug, Clone, PartialEq)] #[derive(Debug, Clone, PartialEq)]
pub type LogicalPosition; pub type LogicalPosition;
@ -642,7 +642,7 @@ mod inner {
pub fn set_y(this: &LogicalPosition, y: u32); pub fn set_y(this: &LogicalPosition, y: u32);
} }
#[wasm_bindgen(module = "/dist/window.js")] #[wasm_bindgen(module = "/src/window.js")]
extern "C" { extern "C" {
#[derive(Debug, Clone, PartialEq)] #[derive(Debug, Clone, PartialEq)]
pub type PhysicalPosition; pub type PhysicalPosition;
@ -660,7 +660,7 @@ mod inner {
pub fn set_y(this: &PhysicalPosition, y: u32); pub fn set_y(this: &PhysicalPosition, y: u32);
} }
#[wasm_bindgen(module = "/dist/window.js")] #[wasm_bindgen(module = "/src/window.js")]
extern "C" { extern "C" {
#[derive(Debug, Clone, PartialEq)] #[derive(Debug, Clone, PartialEq)]
pub type LogicalSize; pub type LogicalSize;
@ -676,7 +676,7 @@ mod inner {
pub fn set_height(this: &LogicalSize, height: u32); pub fn set_height(this: &LogicalSize, height: u32);
} }
#[wasm_bindgen(module = "/dist/window.js")] #[wasm_bindgen(module = "/src/window.js")]
extern "C" { extern "C" {
#[derive(Debug, Clone, PartialEq)] #[derive(Debug, Clone, PartialEq)]
pub type PhysicalSize; pub type PhysicalSize;
@ -694,7 +694,7 @@ mod inner {
pub fn set_height(this: &PhysicalSize, height: u32); pub fn set_height(this: &PhysicalSize, height: u32);
} }
#[wasm_bindgen(module = "/dist/window.js")] #[wasm_bindgen(module = "/src/window.js")]
extern "C" { extern "C" {
#[derive(Debug, Clone, PartialEq)] #[derive(Debug, Clone, PartialEq)]
pub type WebviewWindowHandle; pub type WebviewWindowHandle;
@ -720,7 +720,7 @@ mod inner {
) -> Result<(), JsValue>; ) -> Result<(), JsValue>;
} }
#[wasm_bindgen(module = "/dist/window.js")] #[wasm_bindgen(module = "/src/window.js")]
extern "C" { extern "C" {
#[wasm_bindgen(extends = WebviewWindowHandle)] #[wasm_bindgen(extends = WebviewWindowHandle)]
#[derive(Debug, Clone, PartialEq)] #[derive(Debug, Clone, PartialEq)]
@ -855,7 +855,7 @@ mod inner {
pub async fn startDragging(this: &WindowManager) -> Result<(), JsValue>; pub async fn startDragging(this: &WindowManager) -> Result<(), JsValue>;
} }
#[wasm_bindgen(module = "/dist/window.js")] #[wasm_bindgen(module = "/src/window.js")]
extern "C" { extern "C" {
#[wasm_bindgen(extends = WindowManager)] #[wasm_bindgen(extends = WindowManager)]
#[derive(Debug, Clone, PartialEq)] #[derive(Debug, Clone, PartialEq)]
@ -866,7 +866,7 @@ mod inner {
pub fn getByLabel(label: &str) -> Option<WebviewWindow>; pub fn getByLabel(label: &str) -> Option<WebviewWindow>;
} }
#[wasm_bindgen(module = "/dist/window.js")] #[wasm_bindgen(module = "/src/window.js")]
extern "C" { extern "C" {
pub fn getCurrent() -> WebviewWindow; pub fn getCurrent() -> WebviewWindow;
pub fn getAll() -> Vec<WebviewWindow>; pub fn getAll() -> Vec<WebviewWindow>;