@rdlabo/capacitor-brotherprint 2.0.0-0 → 2.0.0-3

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/dist/docs.json CHANGED
@@ -42,6 +42,144 @@
42
42
  "docs": "",
43
43
  "complexTypes": [],
44
44
  "slug": "searchbleprinter"
45
+ },
46
+ {
47
+ "name": "addListener",
48
+ "signature": "(eventName: 'onPrint', listenerFunc: () => void) => PluginListenerHandle",
49
+ "parameters": [
50
+ {
51
+ "name": "eventName",
52
+ "docs": "",
53
+ "type": "'onPrint'"
54
+ },
55
+ {
56
+ "name": "listenerFunc",
57
+ "docs": "",
58
+ "type": "() => void"
59
+ }
60
+ ],
61
+ "returns": "PluginListenerHandle",
62
+ "tags": [],
63
+ "docs": "",
64
+ "complexTypes": [
65
+ "PluginListenerHandle"
66
+ ],
67
+ "slug": "addlisteneronprint"
68
+ },
69
+ {
70
+ "name": "addListener",
71
+ "signature": "(eventName: 'onBLEAvailable', listenerFunc: () => void) => PluginListenerHandle",
72
+ "parameters": [
73
+ {
74
+ "name": "eventName",
75
+ "docs": "",
76
+ "type": "'onBLEAvailable'"
77
+ },
78
+ {
79
+ "name": "listenerFunc",
80
+ "docs": "",
81
+ "type": "() => void"
82
+ }
83
+ ],
84
+ "returns": "PluginListenerHandle",
85
+ "tags": [],
86
+ "docs": "",
87
+ "complexTypes": [
88
+ "PluginListenerHandle"
89
+ ],
90
+ "slug": "addlisteneronbleavailable"
91
+ },
92
+ {
93
+ "name": "addListener",
94
+ "signature": "(eventName: 'onBLEAvailable', listenerFunc: () => void) => PluginListenerHandle",
95
+ "parameters": [
96
+ {
97
+ "name": "eventName",
98
+ "docs": "",
99
+ "type": "'onBLEAvailable'"
100
+ },
101
+ {
102
+ "name": "listenerFunc",
103
+ "docs": "",
104
+ "type": "() => void"
105
+ }
106
+ ],
107
+ "returns": "PluginListenerHandle",
108
+ "tags": [],
109
+ "docs": "",
110
+ "complexTypes": [
111
+ "PluginListenerHandle"
112
+ ],
113
+ "slug": "addlisteneronbleavailable"
114
+ },
115
+ {
116
+ "name": "addListener",
117
+ "signature": "(eventName: 'onIpAddressAvailable', listenerFunc: (info: { ipAddressList: string[]; }) => void) => PluginListenerHandle",
118
+ "parameters": [
119
+ {
120
+ "name": "eventName",
121
+ "docs": "",
122
+ "type": "'onIpAddressAvailable'"
123
+ },
124
+ {
125
+ "name": "listenerFunc",
126
+ "docs": "",
127
+ "type": "(info: { ipAddressList: string[]; }) => void"
128
+ }
129
+ ],
130
+ "returns": "PluginListenerHandle",
131
+ "tags": [],
132
+ "docs": "",
133
+ "complexTypes": [
134
+ "PluginListenerHandle"
135
+ ],
136
+ "slug": "addlisteneronipaddressavailable"
137
+ },
138
+ {
139
+ "name": "addListener",
140
+ "signature": "(eventName: 'onPrintFailedCommunication', listenerFunc: (info: { value: string; }) => void) => PluginListenerHandle",
141
+ "parameters": [
142
+ {
143
+ "name": "eventName",
144
+ "docs": "",
145
+ "type": "'onPrintFailedCommunication'"
146
+ },
147
+ {
148
+ "name": "listenerFunc",
149
+ "docs": "",
150
+ "type": "(info: { value: string; }) => void"
151
+ }
152
+ ],
153
+ "returns": "PluginListenerHandle",
154
+ "tags": [],
155
+ "docs": "",
156
+ "complexTypes": [
157
+ "PluginListenerHandle"
158
+ ],
159
+ "slug": "addlisteneronprintfailedcommunication"
160
+ },
161
+ {
162
+ "name": "addListener",
163
+ "signature": "(eventName: 'onPrintError', listenerFunc: (info: { value: string; }) => void) => PluginListenerHandle",
164
+ "parameters": [
165
+ {
166
+ "name": "eventName",
167
+ "docs": "",
168
+ "type": "'onPrintError'"
169
+ },
170
+ {
171
+ "name": "listenerFunc",
172
+ "docs": "",
173
+ "type": "(info: { value: string; }) => void"
174
+ }
175
+ ],
176
+ "returns": "PluginListenerHandle",
177
+ "tags": [],
178
+ "docs": "",
179
+ "complexTypes": [
180
+ "PluginListenerHandle"
181
+ ],
182
+ "slug": "addlisteneronprinterror"
45
183
  }
46
184
  ],
47
185
  "properties": []
@@ -97,6 +235,22 @@
97
235
  "type": "string | undefined"
98
236
  }
99
237
  ]
238
+ },
239
+ {
240
+ "name": "PluginListenerHandle",
241
+ "slug": "pluginlistenerhandle",
242
+ "docs": "",
243
+ "tags": [],
244
+ "methods": [],
245
+ "properties": [
246
+ {
247
+ "name": "remove",
248
+ "tags": [],
249
+ "docs": "",
250
+ "complexTypes": [],
251
+ "type": "() => Promise<void>"
252
+ }
253
+ ]
100
254
  }
101
255
  ],
102
256
  "enums": [],
@@ -1,9 +1,22 @@
1
+ import { PluginListenerHandle } from '@capacitor/core';
1
2
  export interface BrotherPrintPlugin {
2
3
  printImage(options: BrotherPrintOptions): Promise<{
3
4
  value: boolean;
4
5
  }>;
5
6
  searchWiFiPrinter(): Promise<void>;
6
7
  searchBLEPrinter(): Promise<void>;
8
+ addListener(eventName: 'onPrint', listenerFunc: () => void): PluginListenerHandle;
9
+ addListener(eventName: 'onBLEAvailable', listenerFunc: () => void): PluginListenerHandle;
10
+ addListener(eventName: 'onBLEAvailable', listenerFunc: () => void): PluginListenerHandle;
11
+ addListener(eventName: 'onIpAddressAvailable', listenerFunc: (info: {
12
+ ipAddressList: string[];
13
+ }) => void): PluginListenerHandle;
14
+ addListener(eventName: 'onPrintFailedCommunication', listenerFunc: (info: {
15
+ value: string;
16
+ }) => void): PluginListenerHandle;
17
+ addListener(eventName: 'onPrintError', listenerFunc: (info: {
18
+ value: string;
19
+ }) => void): PluginListenerHandle;
7
20
  }
8
21
  export interface BrotherPrintOptions {
9
22
  encodedImage: string;
@@ -1 +1 @@
1
- {"version":3,"file":"definitions.js","sourceRoot":"","sources":["../../src/definitions.ts"],"names":[],"mappings":"","sourcesContent":["export interface BrotherPrintPlugin {\n printImage(options: BrotherPrintOptions): Promise<{ value: boolean }>;\n searchWiFiPrinter(): Promise<void>;\n searchBLEPrinter(): Promise<void>;\n}\n\nexport interface BrotherPrintOptions {\n encodedImage: string;\n printerType: 'QL-820NWB' | 'QL-800';\n numberOfCopies: number;\n labelNameIndex: 16 | 38;\n ipAddress?: string;\n localName?: string;\n}\n"]}
1
+ {"version":3,"file":"definitions.js","sourceRoot":"","sources":["../../src/definitions.ts"],"names":[],"mappings":"","sourcesContent":["import { PluginListenerHandle } from '@capacitor/core';\n\nexport interface BrotherPrintPlugin {\n printImage(options: BrotherPrintOptions): Promise<{ value: boolean }>;\n searchWiFiPrinter(): Promise<void>;\n searchBLEPrinter(): Promise<void>;\n\n addListener(\n eventName: 'onPrint',\n listenerFunc: () => void,\n ): PluginListenerHandle;\n\n addListener(\n eventName: 'onBLEAvailable',\n listenerFunc: () => void,\n ): PluginListenerHandle;\n\n addListener(\n eventName: 'onBLEAvailable',\n listenerFunc: () => void,\n ): PluginListenerHandle;\n\n addListener(\n eventName: 'onIpAddressAvailable',\n listenerFunc: (info: { ipAddressList: string[] }) => void,\n ): PluginListenerHandle;\n\n addListener(\n eventName: 'onPrintFailedCommunication',\n listenerFunc: (info: { value: string }) => void,\n ): PluginListenerHandle;\n\n addListener(\n eventName: 'onPrintError',\n listenerFunc: (info: { value: string }) => void,\n ): PluginListenerHandle;\n}\n\nexport interface BrotherPrintOptions {\n encodedImage: string;\n printerType: 'QL-820NWB' | 'QL-800';\n numberOfCopies: number;\n labelNameIndex: 16 | 38;\n ipAddress?: string;\n localName?: string;\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rdlabo/capacitor-brotherprint",
3
- "version": "2.0.0-0",
3
+ "version": "2.0.0-3",
4
4
  "description": "Capacitor plugin for Brother Print SDK",
5
5
  "main": "dist/plugin.js",
6
6
  "module": "dist/esm/index.js",