@tauri-apps/plugin-clipboard-manager 2.0.0-rc.2 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +10 -2
- package/dist-js/index.cjs +15 -0
- package/dist-js/index.d.ts +15 -0
- package/dist-js/index.js +15 -0
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -2,9 +2,17 @@
|
|
|
2
2
|
|
|
3
3
|
Read and write to the system clipboard.
|
|
4
4
|
|
|
5
|
+
| Platform | Supported |
|
|
6
|
+
| -------- | --------- |
|
|
7
|
+
| Linux | ✓ |
|
|
8
|
+
| Windows | ✓ |
|
|
9
|
+
| macOS | ✓ |
|
|
10
|
+
| Android | ✓ |
|
|
11
|
+
| iOS | ✓ |
|
|
12
|
+
|
|
5
13
|
## Install
|
|
6
14
|
|
|
7
|
-
_This plugin requires a Rust version of at least **1.
|
|
15
|
+
_This plugin requires a Rust version of at least **1.78**_
|
|
8
16
|
|
|
9
17
|
There are three general methods of installation that we can recommend.
|
|
10
18
|
|
|
@@ -18,7 +26,7 @@ Install the Core plugin by adding the following to your `Cargo.toml` file:
|
|
|
18
26
|
|
|
19
27
|
```toml
|
|
20
28
|
[dependencies]
|
|
21
|
-
tauri-plugin-clipboard-manager = "2.0.0
|
|
29
|
+
tauri-plugin-clipboard-manager = "2.0.0"
|
|
22
30
|
# alternatively with Git:
|
|
23
31
|
tauri-plugin-clipboard-manager = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" }
|
|
24
32
|
```
|
package/dist-js/index.cjs
CHANGED
|
@@ -44,6 +44,11 @@ async function readText() {
|
|
|
44
44
|
}
|
|
45
45
|
/**
|
|
46
46
|
* Writes image buffer to the clipboard.
|
|
47
|
+
*
|
|
48
|
+
* #### Platform-specific
|
|
49
|
+
*
|
|
50
|
+
* - **Android / iOS:** Not supported.
|
|
51
|
+
*
|
|
47
52
|
* @example
|
|
48
53
|
* ```typescript
|
|
49
54
|
* import { writeImage } from '@tauri-apps/plugin-clipboard-manager';
|
|
@@ -67,6 +72,11 @@ async function writeImage(image$1) {
|
|
|
67
72
|
}
|
|
68
73
|
/**
|
|
69
74
|
* Gets the clipboard content as Uint8Array image.
|
|
75
|
+
*
|
|
76
|
+
* #### Platform-specific
|
|
77
|
+
*
|
|
78
|
+
* - **Android / iOS:** Not supported.
|
|
79
|
+
*
|
|
70
80
|
* @example
|
|
71
81
|
* ```typescript
|
|
72
82
|
* import { readImage } from '@tauri-apps/plugin-clipboard-manager';
|
|
@@ -82,6 +92,11 @@ async function readImage() {
|
|
|
82
92
|
}
|
|
83
93
|
/**
|
|
84
94
|
* * Writes HTML or fallbacks to write provided plain text to the clipboard.
|
|
95
|
+
*
|
|
96
|
+
* #### Platform-specific
|
|
97
|
+
*
|
|
98
|
+
* - **Android / iOS:** Not supported.
|
|
99
|
+
*
|
|
85
100
|
* @example
|
|
86
101
|
* ```typescript
|
|
87
102
|
* import { writeHtml, readHtml } from '@tauri-apps/plugin-clipboard-manager';
|
package/dist-js/index.d.ts
CHANGED
|
@@ -27,6 +27,11 @@ declare function writeText(text: string, opts?: {
|
|
|
27
27
|
declare function readText(): Promise<string>;
|
|
28
28
|
/**
|
|
29
29
|
* Writes image buffer to the clipboard.
|
|
30
|
+
*
|
|
31
|
+
* #### Platform-specific
|
|
32
|
+
*
|
|
33
|
+
* - **Android / iOS:** Not supported.
|
|
34
|
+
*
|
|
30
35
|
* @example
|
|
31
36
|
* ```typescript
|
|
32
37
|
* import { writeImage } from '@tauri-apps/plugin-clipboard-manager';
|
|
@@ -46,6 +51,11 @@ declare function readText(): Promise<string>;
|
|
|
46
51
|
declare function writeImage(image: string | Image | Uint8Array | ArrayBuffer | number[]): Promise<void>;
|
|
47
52
|
/**
|
|
48
53
|
* Gets the clipboard content as Uint8Array image.
|
|
54
|
+
*
|
|
55
|
+
* #### Platform-specific
|
|
56
|
+
*
|
|
57
|
+
* - **Android / iOS:** Not supported.
|
|
58
|
+
*
|
|
49
59
|
* @example
|
|
50
60
|
* ```typescript
|
|
51
61
|
* import { readImage } from '@tauri-apps/plugin-clipboard-manager';
|
|
@@ -59,6 +69,11 @@ declare function writeImage(image: string | Image | Uint8Array | ArrayBuffer | n
|
|
|
59
69
|
declare function readImage(): Promise<Image>;
|
|
60
70
|
/**
|
|
61
71
|
* * Writes HTML or fallbacks to write provided plain text to the clipboard.
|
|
72
|
+
*
|
|
73
|
+
* #### Platform-specific
|
|
74
|
+
*
|
|
75
|
+
* - **Android / iOS:** Not supported.
|
|
76
|
+
*
|
|
62
77
|
* @example
|
|
63
78
|
* ```typescript
|
|
64
79
|
* import { writeHtml, readHtml } from '@tauri-apps/plugin-clipboard-manager';
|
package/dist-js/index.js
CHANGED
|
@@ -42,6 +42,11 @@ async function readText() {
|
|
|
42
42
|
}
|
|
43
43
|
/**
|
|
44
44
|
* Writes image buffer to the clipboard.
|
|
45
|
+
*
|
|
46
|
+
* #### Platform-specific
|
|
47
|
+
*
|
|
48
|
+
* - **Android / iOS:** Not supported.
|
|
49
|
+
*
|
|
45
50
|
* @example
|
|
46
51
|
* ```typescript
|
|
47
52
|
* import { writeImage } from '@tauri-apps/plugin-clipboard-manager';
|
|
@@ -65,6 +70,11 @@ async function writeImage(image) {
|
|
|
65
70
|
}
|
|
66
71
|
/**
|
|
67
72
|
* Gets the clipboard content as Uint8Array image.
|
|
73
|
+
*
|
|
74
|
+
* #### Platform-specific
|
|
75
|
+
*
|
|
76
|
+
* - **Android / iOS:** Not supported.
|
|
77
|
+
*
|
|
68
78
|
* @example
|
|
69
79
|
* ```typescript
|
|
70
80
|
* import { readImage } from '@tauri-apps/plugin-clipboard-manager';
|
|
@@ -80,6 +90,11 @@ async function readImage() {
|
|
|
80
90
|
}
|
|
81
91
|
/**
|
|
82
92
|
* * Writes HTML or fallbacks to write provided plain text to the clipboard.
|
|
93
|
+
*
|
|
94
|
+
* #### Platform-specific
|
|
95
|
+
*
|
|
96
|
+
* - **Android / iOS:** Not supported.
|
|
97
|
+
*
|
|
83
98
|
* @example
|
|
84
99
|
* ```typescript
|
|
85
100
|
* import { writeHtml, readHtml } from '@tauri-apps/plugin-clipboard-manager';
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tauri-apps/plugin-clipboard-manager",
|
|
3
|
-
"version": "2.0.0
|
|
4
|
-
"license": "MIT
|
|
3
|
+
"version": "2.0.0",
|
|
4
|
+
"license": "MIT OR Apache-2.0",
|
|
5
5
|
"authors": [
|
|
6
6
|
"Tauri Programme within The Commons Conservancy"
|
|
7
7
|
],
|
|
@@ -24,6 +24,6 @@
|
|
|
24
24
|
"LICENSE"
|
|
25
25
|
],
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@tauri-apps/api": "^2.0.0
|
|
27
|
+
"@tauri-apps/api": "^2.0.0"
|
|
28
28
|
}
|
|
29
29
|
}
|