=
*
* @example
* ```typescript
- * import { open } from 'tauri-plugin-shell-api';
+ * import { open } from '@tauri-apps/plugin-shell';
* // opens the given URL on the default browser:
* await open('https://github.com/tauri-apps/tauri');
* // opens the given URL using `firefox`:
diff --git a/plugins/shell/package.json b/plugins/shell/package.json
index b6025864..42ab5b33 100644
--- a/plugins/shell/package.json
+++ b/plugins/shell/package.json
@@ -1,5 +1,5 @@
{
- "name": "tauri-plugin-shell-api",
+ "name": "@tauri-apps/plugin-shell",
"version": "0.0.0",
"license": "MIT or APACHE-2.0",
"authors": [
diff --git a/plugins/sql/README.md b/plugins/sql/README.md
index 153d23dd..f6658668 100644
--- a/plugins/sql/README.md
+++ b/plugins/sql/README.md
@@ -53,7 +53,7 @@ fn main() {
Afterwards all the plugin's APIs are available through the JavaScript guest bindings:
```javascript
-import Database from "tauri-plugin-sql-api";
+import Database from "@tauri-apps/plugin-sql";
// sqlite. The path is relative to `tauri::api::path::BaseDirectory::App`.
const db = await Database.load("sqlite:test.db");
diff --git a/plugins/sql/package.json b/plugins/sql/package.json
index a5607cd6..e67a9398 100644
--- a/plugins/sql/package.json
+++ b/plugins/sql/package.json
@@ -1,5 +1,5 @@
{
- "name": "tauri-plugin-sql-api",
+ "name": "@tauri-apps/plugin-sql",
"version": "0.0.0",
"description": "Interface with SQL databases",
"license": "MIT or APACHE-2.0",
diff --git a/plugins/store/README.md b/plugins/store/README.md
index cc63ab7e..c8411112 100644
--- a/plugins/store/README.md
+++ b/plugins/store/README.md
@@ -51,7 +51,7 @@ fn main() {
Afterwards all the plugin's APIs are available through the JavaScript guest bindings:
```javascript
-import { Store } from "tauri-plugin-store-api";
+import { Store } from "@tauri-apps/plugin-store";
const store = new Store(".settings.dat");
diff --git a/plugins/store/package.json b/plugins/store/package.json
index 02e5d230..7f48475f 100644
--- a/plugins/store/package.json
+++ b/plugins/store/package.json
@@ -1,5 +1,5 @@
{
- "name": "tauri-plugin-store-api",
+ "name": "@tauri-apps/plugin-store",
"version": "0.0.0",
"description": "Simple, persistent key-value store.",
"license": "MIT or APACHE-2.0",
diff --git a/plugins/stronghold/README.md b/plugins/stronghold/README.md
index b57bd2d9..52b22a87 100644
--- a/plugins/stronghold/README.md
+++ b/plugins/stronghold/README.md
@@ -55,7 +55,7 @@ fn main() {
Afterwards all the plugin's APIs are available through the JavaScript guest bindings:
```javascript
-import { Stronghold, Location } from "tauri-plugin-stronghold-api";
+import { Stronghold, Location } from "@tauri-apps/plugin-stronghold";
// TODO
```
diff --git a/plugins/stronghold/package.json b/plugins/stronghold/package.json
index 254a3925..371b27c8 100644
--- a/plugins/stronghold/package.json
+++ b/plugins/stronghold/package.json
@@ -1,5 +1,5 @@
{
- "name": "tauri-plugin-stronghold-api",
+ "name": "@tauri-apps/plugin-stronghold",
"version": "0.0.0",
"description": "Store secrets and keys using the IOTA Stronghold encrypted database.",
"license": "MIT or APACHE-2.0",
diff --git a/plugins/updater/README.md b/plugins/updater/README.md
index d618b606..842af4d9 100644
--- a/plugins/updater/README.md
+++ b/plugins/updater/README.md
@@ -51,7 +51,7 @@ fn main() {
Afterwards all the plugin's APIs are available through the JavaScript guest bindings:
```javascript
-import * as updater from "tauri-plugin-updater-api";
+import * as updater from "@tauri-apps/plugin-updater";
```
## Contributing
diff --git a/plugins/updater/package.json b/plugins/updater/package.json
index 5f907a64..1589e979 100644
--- a/plugins/updater/package.json
+++ b/plugins/updater/package.json
@@ -1,5 +1,5 @@
{
- "name": "tauri-plugin-updater-api",
+ "name": "@tauri-apps/plugin-updater",
"version": "0.0.0",
"license": "MIT or APACHE-2.0",
"authors": [
diff --git a/plugins/upload/README.md b/plugins/upload/README.md
index a7e387ee..d451a8d6 100644
--- a/plugins/upload/README.md
+++ b/plugins/upload/README.md
@@ -51,7 +51,7 @@ fn main() {
Afterwards all the plugin's APIs are available through the JavaScript guest bindings:
```javascript
-import { upload } from 'tauri-plugin-upload-api'
+import { upload } from '@tauri-apps/plugin-upload'
upload(
'https://example.com/file-upload'
diff --git a/plugins/upload/package.json b/plugins/upload/package.json
index acd01d42..afa43371 100644
--- a/plugins/upload/package.json
+++ b/plugins/upload/package.json
@@ -1,5 +1,5 @@
{
- "name": "tauri-plugin-upload-api",
+ "name": "@tauri-apps/plugin-upload",
"version": "0.0.0",
"description": "Upload files from disk to a remote server over HTTP.",
"license": "MIT or APACHE-2.0",
diff --git a/plugins/websocket/README.md b/plugins/websocket/README.md
index 1e2aa98e..0971d6ff 100644
--- a/plugins/websocket/README.md
+++ b/plugins/websocket/README.md
@@ -51,7 +51,7 @@ fn main() {
Afterwards all the plugin's APIs are available through the JavaScript guest bindings:
```javascript
-import { WebSocket } from "tauri-plugin-websocket-api";
+import { WebSocket } from "@tauri-apps/plugin-websocket";
const ws = await WebSocket.connect("wss://example.com");
diff --git a/plugins/websocket/examples/svelte-app/package.json b/plugins/websocket/examples/svelte-app/package.json
index d5885cd6..5f1f5511 100644
--- a/plugins/websocket/examples/svelte-app/package.json
+++ b/plugins/websocket/examples/svelte-app/package.json
@@ -22,7 +22,7 @@
},
"dependencies": {
"@tauri-apps/cli": "^2.0.0-alpha.8",
- "tauri-plugin-websocket-api": "link:../../"
+ "@tauri-apps/plugin-websocket": "link:../../"
},
"type": "module"
}
diff --git a/plugins/websocket/examples/svelte-app/src/routes/+page.svelte b/plugins/websocket/examples/svelte-app/src/routes/+page.svelte
index 26e53cb0..d41d6389 100644
--- a/plugins/websocket/examples/svelte-app/src/routes/+page.svelte
+++ b/plugins/websocket/examples/svelte-app/src/routes/+page.svelte
@@ -1,35 +1,44 @@
-
-
-
+
+
+
{@html response}
diff --git a/plugins/websocket/package.json b/plugins/websocket/package.json
index dab28b37..e9b9f5c3 100644
--- a/plugins/websocket/package.json
+++ b/plugins/websocket/package.json
@@ -1,5 +1,5 @@
{
- "name": "tauri-plugin-websocket-api",
+ "name": "@tauri-apps/plugin-websocket",
"version": "0.0.0",
"license": "MIT or APACHE-2.0",
"authors": [
diff --git a/plugins/window-state/README.md b/plugins/window-state/README.md
index ef99f245..97848cd2 100644
--- a/plugins/window-state/README.md
+++ b/plugins/window-state/README.md
@@ -62,7 +62,7 @@ app.save_window_state(StateFlags::all()); // will save the state of all open win
or through Javascript
```javascript
-import { saveWindowState, StateFlags } from "tauri-plugin-window-state-api";
+import { saveWindowState, StateFlags } from "@tauri-apps/plugin-window-state";
saveWindowState(StateFlags.ALL);
```
@@ -79,7 +79,10 @@ window.restore_state(StateFlags::all()); // will restore the windows state from
or through Javascript
```javascript
-import { restoreStateCurrent, StateFlags } from "tauri-plugin-window-state-api";
+import {
+ restoreStateCurrent,
+ StateFlags,
+} from "@tauri-apps/plugin-window-state";
restoreStateCurrent(StateFlags.ALL);
```
diff --git a/plugins/window-state/package.json b/plugins/window-state/package.json
index f7938586..c564eca3 100644
--- a/plugins/window-state/package.json
+++ b/plugins/window-state/package.json
@@ -1,5 +1,5 @@
{
- "name": "tauri-plugin-window-state-api",
+ "name": "@tauri-apps/plugin-window-state",
"version": "0.0.0",
"description": "Save window positions and sizes and restore them when the app is reopened.",
"license": "MIT or APACHE-2.0",
diff --git a/plugins/window/README.md b/plugins/window/README.md
index 00257ccc..1a47b706 100644
--- a/plugins/window/README.md
+++ b/plugins/window/README.md
@@ -51,7 +51,7 @@ fn main() {
Afterwards all the plugin's APIs are available through the JavaScript guest bindings:
```javascript
-import * as tauriWindow from "tauri-plugin-window-api";
+import * as tauriWindow from "@tauri-apps/plugin-window";
```
## Contributing
diff --git a/plugins/window/guest-js/index.ts b/plugins/window/guest-js/index.ts
index 6a3a1585..b330314b 100644
--- a/plugins/window/guest-js/index.ts
+++ b/plugins/window/guest-js/index.ts
@@ -54,7 +54,7 @@
*
* Events can be listened to using `appWindow.listen`:
* ```typescript
- * import { appWindow } from "tauri-plugin-window-api";
+ * import { appWindow } from "@tauri-apps/window";
* appWindow.listen("my-window-event", ({ event, payload }) => { });
* ```
*
@@ -144,7 +144,7 @@ class PhysicalSize {
* Converts the physical size to a logical one.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const factor = await appWindow.scaleFactor();
* const size = await appWindow.innerSize();
* const logical = size.toLogical(factor);
@@ -190,7 +190,7 @@ class PhysicalPosition {
* Converts the physical position to a logical one.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const factor = await appWindow.scaleFactor();
* const position = await appWindow.innerPosition();
* const logical = position.toLogical(factor);
@@ -319,7 +319,8 @@ class WebviewWindowHandle {
/** The window label. It is a unique identifier for the window, can be used to reference it later. */
label: WindowLabel;
/** Local event listeners. */
- listeners: Record>>;
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
+ listeners: Record>>;
constructor(label: WindowLabel) {
this.label = label;
@@ -332,7 +333,7 @@ class WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const unlisten = await appWindow.listen('state-changed', (event) => {
* console.log(`Got error: ${payload}`);
* });
@@ -365,7 +366,7 @@ class WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const unlisten = await appWindow.once('initialized', (event) => {
* console.log(`Window initialized!`);
* });
@@ -394,7 +395,7 @@ class WebviewWindowHandle {
* Emits an event to the backend, tied to the webview window.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.emit('window-loaded', { loggedIn: true, token: 'authToken' });
* ```
*
@@ -440,7 +441,7 @@ class WindowManager extends WebviewWindowHandle {
* The scale factor that can be used to map physical pixels to logical pixels.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const factor = await appWindow.scaleFactor();
* ```
*
@@ -456,7 +457,7 @@ class WindowManager extends WebviewWindowHandle {
* The position of the top-left hand corner of the window's client area relative to the top-left hand corner of the desktop.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const position = await appWindow.innerPosition();
* ```
*
@@ -472,7 +473,7 @@ class WindowManager extends WebviewWindowHandle {
* The position of the top-left hand corner of the window relative to the top-left hand corner of the desktop.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const position = await appWindow.outerPosition();
* ```
*
@@ -489,7 +490,7 @@ class WindowManager extends WebviewWindowHandle {
* The client area is the content of the window, excluding the title bar and borders.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const size = await appWindow.innerSize();
* ```
*
@@ -509,7 +510,7 @@ class WindowManager extends WebviewWindowHandle {
* These dimensions include the title bar and borders. If you don't want that (and you usually don't), use inner_size instead.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const size = await appWindow.outerSize();
* ```
*
@@ -528,7 +529,7 @@ class WindowManager extends WebviewWindowHandle {
* Gets the window's current fullscreen state.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const fullscreen = await appWindow.isFullscreen();
* ```
*
@@ -544,7 +545,7 @@ class WindowManager extends WebviewWindowHandle {
* Gets the window's current minimized state.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const minimized = await appWindow.isMinimized();
* ```
*
@@ -560,7 +561,7 @@ class WindowManager extends WebviewWindowHandle {
* Gets the window's current maximized state.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const maximized = await appWindow.isMaximized();
* ```
*
@@ -576,7 +577,7 @@ class WindowManager extends WebviewWindowHandle {
* Gets the window's current decorated state.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const decorated = await appWindow.isDecorated();
* ```
*
@@ -592,7 +593,7 @@ class WindowManager extends WebviewWindowHandle {
* Gets the window's current resizable state.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const resizable = await appWindow.isResizable();
* ```
*
@@ -608,7 +609,7 @@ class WindowManager extends WebviewWindowHandle {
* Gets the window's current visible state.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const visible = await appWindow.isVisible();
* ```
*
@@ -624,7 +625,7 @@ class WindowManager extends WebviewWindowHandle {
* Gets the window's current title.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const title = await appWindow.title();
* ```
*
@@ -645,7 +646,7 @@ class WindowManager extends WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* const theme = await appWindow.theme();
* ```
*
@@ -663,7 +664,7 @@ class WindowManager extends WebviewWindowHandle {
* Centers the window.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.center();
* ```
*
@@ -690,7 +691,7 @@ class WindowManager extends WebviewWindowHandle {
* - **Linux:** Urgency levels have the same effect.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.requestUserAttention();
* ```
*
@@ -719,7 +720,7 @@ class WindowManager extends WebviewWindowHandle {
* Updates the window resizable flag.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setResizable(false);
* ```
*
@@ -737,7 +738,7 @@ class WindowManager extends WebviewWindowHandle {
* Sets the window title.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setTitle('Tauri');
* ```
*
@@ -755,7 +756,7 @@ class WindowManager extends WebviewWindowHandle {
* Maximizes the window.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.maximize();
* ```
*
@@ -771,7 +772,7 @@ class WindowManager extends WebviewWindowHandle {
* Unmaximizes the window.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.unmaximize();
* ```
*
@@ -787,7 +788,7 @@ class WindowManager extends WebviewWindowHandle {
* Toggles the window maximized state.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.toggleMaximize();
* ```
*
@@ -803,7 +804,7 @@ class WindowManager extends WebviewWindowHandle {
* Minimizes the window.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.minimize();
* ```
*
@@ -819,7 +820,7 @@ class WindowManager extends WebviewWindowHandle {
* Unminimizes the window.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.unminimize();
* ```
*
@@ -835,7 +836,7 @@ class WindowManager extends WebviewWindowHandle {
* Sets the window visibility to true.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.show();
* ```
*
@@ -851,7 +852,7 @@ class WindowManager extends WebviewWindowHandle {
* Sets the window visibility to false.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.hide();
* ```
*
@@ -867,7 +868,7 @@ class WindowManager extends WebviewWindowHandle {
* Closes the window.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.close();
* ```
*
@@ -883,7 +884,7 @@ class WindowManager extends WebviewWindowHandle {
* Whether the window should have borders and bars.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setDecorations(false);
* ```
*
@@ -910,7 +911,7 @@ class WindowManager extends WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setShadow(false);
* ```
*
@@ -929,7 +930,7 @@ class WindowManager extends WebviewWindowHandle {
* Whether the window should always be on top of other windows.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setAlwaysOnTop(true);
* ```
*
@@ -947,7 +948,7 @@ class WindowManager extends WebviewWindowHandle {
* Prevents the window contents from being captured by other apps.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setContentProtected(true);
* ```
*
@@ -966,7 +967,7 @@ class WindowManager extends WebviewWindowHandle {
* Resizes the window with a new inner size.
* @example
* ```typescript
- * import { appWindow, LogicalSize } from 'tauri-plugin-window-api';
+ * import { appWindow, LogicalSize } from '@tauri-apps/window';
* await appWindow.setSize(new LogicalSize(600, 500));
* ```
*
@@ -996,7 +997,7 @@ class WindowManager extends WebviewWindowHandle {
* Sets the window minimum inner size. If the `size` argument is not provided, the constraint is unset.
* @example
* ```typescript
- * import { appWindow, PhysicalSize } from 'tauri-plugin-window-api';
+ * import { appWindow, PhysicalSize } from '@tauri-apps/window';
* await appWindow.setMinSize(new PhysicalSize(600, 500));
* ```
*
@@ -1030,7 +1031,7 @@ class WindowManager extends WebviewWindowHandle {
* Sets the window maximum inner size. If the `size` argument is undefined, the constraint is unset.
* @example
* ```typescript
- * import { appWindow, LogicalSize } from 'tauri-plugin-window-api';
+ * import { appWindow, LogicalSize } from '@tauri-apps/window';
* await appWindow.setMaxSize(new LogicalSize(600, 500));
* ```
*
@@ -1064,7 +1065,7 @@ class WindowManager extends WebviewWindowHandle {
* Sets the window outer position.
* @example
* ```typescript
- * import { appWindow, LogicalPosition } from 'tauri-plugin-window-api';
+ * import { appWindow, LogicalPosition } from '@tauri-apps/window';
* await appWindow.setPosition(new LogicalPosition(600, 500));
* ```
*
@@ -1099,7 +1100,7 @@ class WindowManager extends WebviewWindowHandle {
* Sets the window fullscreen state.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setFullscreen(true);
* ```
*
@@ -1117,7 +1118,7 @@ class WindowManager extends WebviewWindowHandle {
* Bring the window to front and focus.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setFocus();
* ```
*
@@ -1133,7 +1134,7 @@ class WindowManager extends WebviewWindowHandle {
* Sets the window icon.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setIcon('/tauri/awesome.png');
* ```
*
@@ -1162,7 +1163,7 @@ class WindowManager extends WebviewWindowHandle {
* - **macOS:** Unsupported.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setSkipTaskbar(true);
* ```
*
@@ -1188,7 +1189,7 @@ class WindowManager extends WebviewWindowHandle {
* - **macOS:** This locks the cursor in a fixed location, which looks visually awkward.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setCursorGrab(true);
* ```
*
@@ -1212,7 +1213,7 @@ class WindowManager extends WebviewWindowHandle {
* outside of the window.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setCursorVisible(false);
* ```
*
@@ -1230,7 +1231,7 @@ class WindowManager extends WebviewWindowHandle {
* Modifies the cursor icon of the window.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setCursorIcon('help');
* ```
*
@@ -1248,7 +1249,7 @@ class WindowManager extends WebviewWindowHandle {
* Changes the position of the cursor in window coordinates.
* @example
* ```typescript
- * import { appWindow, LogicalPosition } from 'tauri-plugin-window-api';
+ * import { appWindow, LogicalPosition } from '@tauri-apps/window';
* await appWindow.setCursorPosition(new LogicalPosition(600, 300));
* ```
*
@@ -1284,7 +1285,7 @@ class WindowManager extends WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.setIgnoreCursorEvents(true);
* ```
*
@@ -1302,7 +1303,7 @@ class WindowManager extends WebviewWindowHandle {
* Starts dragging the window.
* @example
* ```typescript
- * import { appWindow } from 'tauri-plugin-window-api';
+ * import { appWindow } from '@tauri-apps/window';
* await appWindow.startDragging();
* ```
*
@@ -1321,7 +1322,7 @@ class WindowManager extends WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from "tauri-plugin-window-api";
+ * import { appWindow } from "@tauri-apps/window";
* const unlisten = await appWindow.onResized(({ payload: size }) => {
* console.log('Window resized', size);
* });
@@ -1347,7 +1348,7 @@ class WindowManager extends WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from "tauri-plugin-window-api";
+ * import { appWindow } from "@tauri-apps/window";
* const unlisten = await appWindow.onMoved(({ payload: position }) => {
* console.log('Window moved', position);
* });
@@ -1373,7 +1374,7 @@ class WindowManager extends WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from "tauri-plugin-window-api";
+ * import { appWindow } from "@tauri-apps/window";
* import { confirm } from '@tauri-apps/api/dialog';
* const unlisten = await appWindow.onCloseRequested(async (event) => {
* const confirmed = await confirm('Are you sure?');
@@ -1412,7 +1413,7 @@ class WindowManager extends WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from "tauri-plugin-window-api";
+ * import { appWindow } from "@tauri-apps/window";
* const unlisten = await appWindow.onFocusChanged(({ payload: focused }) => {
* console.log('Focus changed, window is focused? ' + focused);
* });
@@ -1454,7 +1455,7 @@ class WindowManager extends WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from "tauri-plugin-window-api";
+ * import { appWindow } from "@tauri-apps/window";
* const unlisten = await appWindow.onScaleChanged(({ payload }) => {
* console.log('Scale changed', payload.scaleFactor, payload.size);
* });
@@ -1482,7 +1483,7 @@ class WindowManager extends WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from "tauri-plugin-window-api";
+ * import { appWindow } from "@tauri-apps/window";
* const unlisten = await appWindow.onMenuClicked(({ payload: menuId }) => {
* console.log('Menu clicked: ' + menuId);
* });
@@ -1507,7 +1508,7 @@ class WindowManager extends WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from "tauri-plugin-window-api";
+ * import { appWindow } from "@tauri-apps/window";
* const unlisten = await appWindow.onFileDropEvent((event) => {
* if (event.payload.type === 'hover') {
* console.log('User hovering', event.payload.paths);
@@ -1563,7 +1564,7 @@ class WindowManager extends WebviewWindowHandle {
*
* @example
* ```typescript
- * import { appWindow } from "tauri-plugin-window-api";
+ * import { appWindow } from "@tauri-apps/window";
* const unlisten = await appWindow.onThemeChanged(({ payload: theme }) => {
* console.log('New theme: ' + theme);
* });
@@ -1647,7 +1648,7 @@ class WebviewWindow extends WindowManager {
* Creates a new WebviewWindow.
* @example
* ```typescript
- * import { WebviewWindow } from 'tauri-plugin-window-api';
+ * import { WebviewWindow } from '@tauri-apps/window';
* const webview = new WebviewWindow('my-label', {
* url: 'https://github.com/tauri-apps/tauri'
* });
@@ -1681,7 +1682,7 @@ class WebviewWindow extends WindowManager {
* Gets the WebviewWindow for the webview associated with the given label.
* @example
* ```typescript
- * import { WebviewWindow } from 'tauri-plugin-window-api';
+ * import { WebviewWindow } from '@tauri-apps/window';
* const mainWindow = WebviewWindow.getByLabel('main');
* ```
*
@@ -1850,7 +1851,7 @@ function mapPhysicalSize(m: PhysicalSize): PhysicalSize {
* Returns `null` if current monitor can't be detected.
* @example
* ```typescript
- * import { currentMonitor } from 'tauri-plugin-window-api';
+ * import { currentMonitor } from '@tauri-apps/window';
* const monitor = currentMonitor();
* ```
*
@@ -1867,7 +1868,7 @@ async function currentMonitor(): Promise {
* Returns `null` if it can't identify any monitor as a primary one.
* @example
* ```typescript
- * import { primaryMonitor } from 'tauri-plugin-window-api';
+ * import { primaryMonitor } from '@tauri-apps/window';
* const monitor = primaryMonitor();
* ```
*
@@ -1883,7 +1884,7 @@ async function primaryMonitor(): Promise {
* Returns the list of all the monitors available on the system.
* @example
* ```typescript
- * import { availableMonitors } from 'tauri-plugin-window-api';
+ * import { availableMonitors } from '@tauri-apps/window';
* const monitors = availableMonitors();
* ```
*
diff --git a/plugins/window/package.json b/plugins/window/package.json
index 6e564693..53ceec55 100644
--- a/plugins/window/package.json
+++ b/plugins/window/package.json
@@ -1,5 +1,5 @@
{
- "name": "tauri-plugin-window-api",
+ "name": "@tauri-apps/plugin-window",
"version": "0.0.0",
"license": "MIT or APACHE-2.0",
"authors": [
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 2305976a..15858968 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -61,43 +61,43 @@ importers:
'@zerodevx/svelte-json-view':
specifier: 0.2.1
version: 0.2.1
- tauri-plugin-app-api:
+ '@tauri-apps/plugin-app':
specifier: 0.0.0
version: link:../../plugins/app
- tauri-plugin-cli-api:
+ '@tauri-apps/plugin-cli':
specifier: 0.0.0
version: link:../../plugins/cli
- tauri-plugin-clipboard-api:
+ '@tauri-apps/plugin-clipboard':
specifier: 0.0.0
version: link:../../plugins/clipboard
- tauri-plugin-dialog-api:
+ '@tauri-apps/plugin-dialog':
specifier: 0.0.0
version: link:../../plugins/dialog
- tauri-plugin-fs-api:
+ '@tauri-apps/plugin-fs':
specifier: 0.0.0
version: link:../../plugins/fs
- tauri-plugin-global-shortcut-api:
+ '@tauri-apps/plugin-global-shortcut':
specifier: 0.0.0
version: link:../../plugins/global-shortcut
- tauri-plugin-http-api:
+ '@tauri-apps/plugin-http':
specifier: 0.0.0
version: link:../../plugins/http
- tauri-plugin-notification-api:
+ '@tauri-apps/plugin-notification':
specifier: 0.0.0
version: link:../../plugins/notification
- tauri-plugin-os-api:
+ '@tauri-apps/plugin-os':
specifier: 0.0.0
version: link:../../plugins/os
- tauri-plugin-process-api:
+ '@tauri-apps/plugin-process':
specifier: 0.0.0
version: link:../../plugins/process
- tauri-plugin-shell-api:
+ '@tauri-apps/plugin-shell':
specifier: 0.0.0
version: link:../../plugins/shell
- tauri-plugin-updater-api:
+ '@tauri-apps/plugin-updater':
specifier: 0.0.0
version: link:../../plugins/updater
- tauri-plugin-window-api:
+ '@tauri-apps/plugin-window':
specifier: 0.0.0
version: link:../../plugins/window
devDependencies:
@@ -354,7 +354,7 @@ importers:
'@tauri-apps/cli':
specifier: ^2.0.0-alpha.8
version: 2.0.0-alpha.8
- tauri-plugin-websocket-api:
+ '@tauri-apps/plugin-websocket':
specifier: link:../../
version: link:../..
devDependencies:
diff --git a/shared/template/package.json b/shared/template/package.json
index e62c3c9f..77b7a603 100644
--- a/shared/template/package.json
+++ b/shared/template/package.json
@@ -1,5 +1,5 @@
{
- "name": "tauri-plugin-{{name}}-api",
+ "name": "@tauri-apps/plugin-{{name}}",
"version": "0.0.0",
"license": "MIT or APACHE-2.0",
"authors": [