@wox-launcher/wox-plugin 0.0.65 → 0.0.66

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/types/index.d.ts +14 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wox-launcher/wox-plugin",
3
- "version": "0.0.65",
3
+ "version": "0.0.66",
4
4
  "description": "All nodejs plugin for Wox should use types in this package",
5
5
  "repository": {
6
6
  "type": "git",
package/types/index.d.ts CHANGED
@@ -11,6 +11,13 @@ export interface Selection {
11
11
  FilePaths: string[]
12
12
  }
13
13
 
14
+ export interface QueryEnv {
15
+ /**
16
+ * Active window title when user query
17
+ */
18
+ ActiveWindowTitle: string
19
+ }
20
+
14
21
  export interface Query {
15
22
  /**
16
23
  * By default, Wox will only pass input query to plugin.
@@ -50,12 +57,19 @@ export interface Query {
50
57
  */
51
58
  Selection: Selection
52
59
 
60
+ /**
61
+ * Additional query environment data
62
+ * expose more context env data to plugin, E.g. plugin A only show result when active window title is "Chrome"
63
+ */
64
+ Env: QueryEnv
65
+
53
66
  /**
54
67
  * Whether current query is global query
55
68
  */
56
69
  IsGlobalQuery(): boolean
57
70
  }
58
71
 
72
+
59
73
  export interface Result {
60
74
  Id?: string
61
75
  Title: string