@tarojs/taro 3.5.0-canary.1 → 3.5.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.
Files changed (109) hide show
  1. package/html.css +50 -14
  2. package/html5.css +167 -64
  3. package/index.js +3 -4
  4. package/package.json +21 -11
  5. package/types/api/ad/index.d.ts +2 -2
  6. package/types/api/ai/face.d.ts +133 -0
  7. package/types/api/ai/visionkit.d.ts +303 -0
  8. package/types/api/base/crypto.d.ts +90 -0
  9. package/types/api/base/debug.d.ts +152 -13
  10. package/types/api/base/env.d.ts +2 -1
  11. package/types/api/base/index.d.ts +11 -3
  12. package/types/api/base/performance.d.ts +195 -0
  13. package/types/api/base/system.d.ts +541 -103
  14. package/types/api/base/update.d.ts +60 -8
  15. package/types/api/base/weapp/app-event.d.ts +99 -37
  16. package/types/api/base/weapp/life-cycle.d.ts +142 -2
  17. package/types/api/canvas/index.d.ts +151 -137
  18. package/types/api/cloud/index.d.ts +17 -2
  19. package/types/api/data-analysis/index.d.ts +1 -1
  20. package/types/api/device/accelerometer.d.ts +6 -6
  21. package/types/api/device/accessibility.d.ts +26 -0
  22. package/types/api/device/battery.d.ts +2 -2
  23. package/types/api/device/{ble.d.ts → bluetooth-ble.d.ts} +228 -62
  24. package/types/api/device/bluetooth-peripheral.d.ts +430 -0
  25. package/types/api/device/bluetooth.d.ts +67 -2
  26. package/types/api/device/calendar.d.ts +88 -0
  27. package/types/api/device/clipboard.d.ts +2 -2
  28. package/types/api/device/compass.d.ts +3 -3
  29. package/types/api/device/contact.d.ts +74 -50
  30. package/types/api/device/gyroscope.d.ts +6 -6
  31. package/types/api/device/iBeacon.d.ts +33 -19
  32. package/types/api/{ui → device}/keyboard.d.ts +1 -1
  33. package/types/api/device/{performance.d.ts → memory.d.ts} +5 -5
  34. package/types/api/device/motion.d.ts +3 -3
  35. package/types/api/device/network.d.ts +56 -15
  36. package/types/api/device/nfc.d.ts +1089 -13
  37. package/types/api/device/phone.d.ts +1 -1
  38. package/types/api/device/scan.d.ts +1 -1
  39. package/types/api/device/screen.d.ts +42 -14
  40. package/types/api/device/vibrate.d.ts +6 -2
  41. package/types/api/device/wifi.d.ts +44 -9
  42. package/types/api/ext/index.d.ts +2 -2
  43. package/types/api/files/index.d.ts +392 -205
  44. package/types/api/framework/index.d.ts +5 -4
  45. package/types/api/location/index.d.ts +156 -53
  46. package/types/api/media/audio.d.ts +629 -38
  47. package/types/api/media/background-audio.d.ts +9 -9
  48. package/types/api/media/camera.d.ts +41 -22
  49. package/types/api/media/editor.d.ts +22 -2
  50. package/types/api/media/image.d.ts +64 -35
  51. package/types/api/media/live.d.ts +66 -6
  52. package/types/api/media/map.d.ts +474 -54
  53. package/types/api/media/media-recorder.d.ts +92 -0
  54. package/types/api/media/recorder.d.ts +21 -21
  55. package/types/api/media/video-decoder.d.ts +117 -0
  56. package/types/api/media/video-processing.d.ts +11 -7
  57. package/types/api/media/video.d.ts +47 -18
  58. package/types/api/media/voip.d.ts +290 -0
  59. package/types/api/{open-api/navigate.d.ts → navigate/index.d.ts} +65 -27
  60. package/types/api/network/download.d.ts +61 -19
  61. package/types/api/network/request.d.ts +129 -41
  62. package/types/api/network/tcp.d.ts +181 -0
  63. package/types/api/network/udp.d.ts +154 -83
  64. package/types/api/network/upload.d.ts +55 -28
  65. package/types/api/network/websocket.d.ts +20 -19
  66. package/types/api/open-api/address.d.ts +1 -1
  67. package/types/api/open-api/authorize.d.ts +42 -3
  68. package/types/api/open-api/channels.d.ts +178 -0
  69. package/types/api/open-api/facial.d.ts +3 -0
  70. package/types/api/open-api/favorites.d.ts +100 -0
  71. package/types/api/open-api/group.d.ts +59 -0
  72. package/types/api/open-api/invoice.d.ts +2 -2
  73. package/types/api/open-api/license-plate.d.ts +27 -0
  74. package/types/api/open-api/login.d.ts +21 -0
  75. package/types/api/open-api/redpackage.d.ts +24 -0
  76. package/types/api/open-api/settings.d.ts +82 -17
  77. package/types/api/open-api/soter.d.ts +2 -2
  78. package/types/api/open-api/subscribe-message.d.ts +89 -4
  79. package/types/api/open-api/user-info.d.ts +56 -19
  80. package/types/api/open-api/werun.d.ts +33 -6
  81. package/types/api/payment/index.d.ts +119 -0
  82. package/types/api/route/index.d.ts +18 -14
  83. package/types/api/share/index.d.ts +192 -9
  84. package/types/api/storage/index.d.ts +38 -92
  85. package/types/api/swan/index.d.ts +1 -1
  86. package/types/api/ui/animation.d.ts +105 -155
  87. package/types/api/ui/background.d.ts +4 -2
  88. package/types/api/ui/custom-component.d.ts +1 -1
  89. package/types/api/ui/fonts.d.ts +27 -31
  90. package/types/api/ui/interaction.d.ts +6 -6
  91. package/types/api/ui/menu.d.ts +1 -1
  92. package/types/api/ui/navigation-bar.d.ts +6 -5
  93. package/types/api/ui/pull-down-refresh.d.ts +2 -2
  94. package/types/api/ui/scroll.d.ts +75 -7
  95. package/types/api/ui/sticky.d.ts +4 -4
  96. package/types/api/ui/tab-bar.d.ts +8 -8
  97. package/types/api/ui/window.d.ts +22 -2
  98. package/types/api/worker/index.d.ts +9 -1
  99. package/types/api/wxml/index.d.ts +116 -112
  100. package/types/compile.d.ts +57 -6
  101. package/types/global.d.ts +142 -111
  102. package/types/taro.api.d.ts +79 -62
  103. package/types/taro.component.d.ts +21 -65
  104. package/types/taro.config.d.ts +31 -0
  105. package/types/taro.extend.d.ts +31 -18
  106. package/types/taro.hooks.d.ts +55 -3
  107. package/types/taro.lifecycle.d.ts +21 -14
  108. package/LICENSE +0 -21
  109. package/types/api/open-api/payment.d.ts +0 -61
@@ -1,6 +1,8 @@
1
- import * as webpack from 'webpack'
2
- import * as webpackDevServer from 'webpack-dev-server'
1
+ import swc from '@swc/core'
3
2
  export { Current } from '@tarojs/runtime'
3
+ import webpack from 'webpack'
4
+ import webpackDevServer from 'webpack-dev-server'
5
+ import HtmlWebpackPlugin from 'html-webpack-plugin'
4
6
 
5
7
  export const enum TEMPLATE_TYPES {
6
8
  WEAPP = '.wxml',
@@ -110,11 +112,15 @@ export interface ICompileOption {
110
112
  interface Runtime {
111
113
  enableInnerHTML: boolean
112
114
  enableSizeAPIs: boolean
115
+ enableAdjacentHTML: boolean
116
+ enableTemplateContent: boolean
117
+ enableCloneNode: boolean
118
+ enableContains: boolean
119
+ enableMutationObserver: boolean
113
120
  }
114
121
 
115
122
  export interface IMiniAppConfig {
116
123
  appOutput?: boolean
117
- enableSourceMap?: boolean
118
124
  sourceMapType?: string
119
125
  debugReact?: boolean
120
126
  minifyXML?: {
@@ -122,7 +128,6 @@ export interface IMiniAppConfig {
122
128
  }
123
129
 
124
130
  webpackChain?: (chain: any, webpack: any, PARSE_AST_TYPE: any) => void
125
- entry?: webpack.Entry
126
131
  output?: webpack.Output
127
132
  postcss?: IPostcssOption
128
133
  cssLoaderOption?: IOption
@@ -172,11 +177,9 @@ export interface IH5Config {
172
177
 
173
178
  webpackChain?: (chain: any, webpack: any) => void
174
179
 
175
- entry?: webpack.Entry
176
180
  output?: webpack.Output
177
181
  router?: IH5RouterConfig
178
182
  devServer?: webpackDevServer.Configuration
179
- enableSourceMap?: boolean
180
183
  sourceMapType?: 'none' | 'eval' | 'cheap-eval-source-map' | 'cheap-module-eval-source-map' | 'eval-source-map' | 'cheap-source-map' | 'cheap-module-source-map' | 'inline-cheap-source-map' | 'inline-cheap-module-source-map' | 'source-map' | 'inline-source-map' | 'hidden-source-map' | 'nosources-source-map'
181
184
  enableExtract?: boolean
182
185
  transformOnly?: boolean
@@ -194,6 +197,7 @@ export interface IH5Config {
194
197
  useHtmlComponents?: boolean
195
198
 
196
199
  postcss?: IPostcssOption
200
+ htmlPluginOption?: HtmlWebpackPlugin.Options
197
201
  }
198
202
 
199
203
  type FeatureItem = {
@@ -352,7 +356,40 @@ export interface IManifestConfig extends ITaroManifestConfig {
352
356
 
353
357
  export type PluginItem = string | [string, object]
354
358
 
359
+ interface ICache {
360
+ enable?: boolean
361
+ buildDependencies?: Record<string, any>
362
+ name?: string
363
+ }
364
+
365
+ type CompilerTypes = 'webpack4' | 'webpack5'
366
+ interface IPrebundle {
367
+ enable?: boolean
368
+ timings?: boolean
369
+ cacheDir?: string
370
+ force?: boolean
371
+ include?: string[]
372
+ exclude?: string[]
373
+ esbuild?: Record<string, any>
374
+ swc?: swc.Config
375
+ webpack?: {
376
+ provide?: any[]
377
+ }
378
+ }
379
+ interface ICompiler {
380
+ type: CompilerTypes
381
+ prebundle: IPrebundle
382
+ }
383
+ type Compiler = CompilerTypes | ICompiler
384
+
385
+ interface ILogger {
386
+ quiet: boolean
387
+ stats: boolean
388
+ }
389
+
355
390
  export interface IProjectBaseConfig {
391
+ isWatch?: boolean
392
+ port?: number
356
393
  projectName?: string
357
394
  date?: string
358
395
  designWidth?: number
@@ -364,14 +401,28 @@ export interface IProjectBaseConfig {
364
401
  alias?: IOption
365
402
  defineConstants?: IOption
366
403
  copy?: ICopyOptions
404
+ jsMinimizer?: 'terser' | 'esbuild'
405
+ cssMinimizer?: 'csso' | 'esbuild' | 'parcelCss'
367
406
  csso?: TogglableOptions
368
407
  terser?: TogglableOptions
408
+ esbuild?: Record<'minify', TogglableOptions>
369
409
  uglify?: TogglableOptions
370
410
  sass?: ISassOptions
371
411
  plugins?: PluginItem[]
372
412
  presets?: PluginItem[]
373
413
  baseLevel?: number
374
414
  framework?: string
415
+ frameworkExts?: string[]
416
+ compiler?: Compiler
417
+ cache?: ICache
418
+ logger?: ILogger
419
+ enableSourceMap?: boolean
420
+ /** hooks */
421
+ modifyWebpackChain?: HookModifyWebpackChain
422
+ modifyMiniConfigs?: (configMap) => Promise<any>
423
+ modifyBuildAssets?: (assets, plugin?) => Promise<any>
424
+ onWebpackChainReady?: (webpackChain: Chain) => Promise<any>
425
+ onBuildFinish?: (res: { error, stats, isWatch }) => Promise<any>
375
426
  }
376
427
 
377
428
  export interface IProjectConfig extends IProjectBaseConfig {
package/types/global.d.ts CHANGED
@@ -99,55 +99,55 @@ declare namespace TaroGeneral {
99
99
  */
100
100
  interface AdErrCode {
101
101
  /**
102
- * @abnormal 后端接口调用失败
102
+ * @illustrate 后端接口调用失败
103
103
  * @reason 该项错误不是开发者的异常情况
104
104
  * @solution 一般情况下忽略一段时间即可恢复。
105
105
  */
106
106
  1000
107
107
  /**
108
- * @abnormal 参数错误
108
+ * @illustrate 参数错误
109
109
  * @reason 使用方法错误
110
110
  * @solution 可以前往 developers.weixin.qq.com 确认具体教程(小程序和小游戏分别有各自的教程,可以在顶部选项中,“设计”一栏的右侧进行切换。
111
111
  */
112
112
  1001
113
113
  /**
114
- * @abnormal 广告单元无效
114
+ * @illustrate 广告单元无效
115
115
  * @reason 可能是拼写错误、或者误用了其他APP的广告ID
116
116
  * @solution 请重新前往 mp.weixin.qq.com 确认广告位ID。
117
117
  */
118
118
  1002
119
119
  /**
120
- * @abnormal 内部错误
120
+ * @illustrate 内部错误
121
121
  * @reason 该项错误不是开发者的异常情况
122
122
  * @solution 一般情况下忽略一段时间即可恢复。
123
123
  */
124
124
  1003
125
125
  /**
126
- * @abnormal 无合适的广告
126
+ * @illustrate 无合适的广告
127
127
  * @reason 广告不是每一次都会出现,这次没有出现可能是由于该用户不适合浏览广告
128
128
  * @solution 属于正常情况,且开发者需要针对这种情况做形态上的兼容。
129
129
  */
130
130
  1004
131
131
  /**
132
- * @abnormal 广告组件审核中
132
+ * @illustrate 广告组件审核中
133
133
  * @reason 你的广告正在被审核,无法展现广告
134
134
  * @solution 请前往 mp.weixin.qq.com 确认审核状态,且开发者需要针对这种情况做形态上的兼容。
135
135
  */
136
136
  1005
137
137
  /**
138
- * @abnormal 广告组件被驳回
138
+ * @illustrate 广告组件被驳回
139
139
  * @reason 你的广告审核失败,无法展现广告
140
140
  * @solution 请前往 mp.weixin.qq.com 确认审核状态,且开发者需要针对这种情况做形态上的兼容。
141
141
  */
142
142
  1006
143
143
  /**
144
- * @abnormal 广告组件被封禁
144
+ * @illustrate 广告组件被封禁
145
145
  * @reason 你的广告能力已经被封禁,封禁期间无法展现广告
146
146
  * @solution 请前往 mp.weixin.qq.com 确认小程序广告封禁状态。
147
147
  */
148
148
  1007
149
149
  /**
150
- * @abnormal 广告单元已关闭
150
+ * @illustrate 广告单元已关闭
151
151
  * @reason 该广告位的广告能力已经被关闭
152
152
  * @solution 请前往 mp.weixin.qq.com 重新打开对应广告位的展现。
153
153
  */
@@ -156,196 +156,227 @@ declare namespace TaroGeneral {
156
156
  }
157
157
  /** 蓝牙错误码 */
158
158
  interface BluetoothErrCode {
159
- /** 正常
160
- * @abnormal ok
159
+ /** ok
160
+ * @illustrate 正常
161
161
  */
162
162
  0
163
- /** 未初始化蓝牙适配器
164
- * @abnormal not init
163
+ /** not init
164
+ * @illustrate 未初始化蓝牙适配器
165
165
  */
166
166
  10000
167
- /** 当前蓝牙适配器不可用
168
- * @abnormal not available
167
+ /** not available
168
+ * @illustrate 当前蓝牙适配器不可用
169
169
  */
170
170
  10001
171
- /** 没有找到指定设备
172
- * @abnormal no device
171
+ /** no device
172
+ * @illustrate 没有找到指定设备
173
173
  */
174
174
  10002
175
- /** 连接失败
176
- * @abnormal connection fail
175
+ /** connection fail
176
+ * @illustrate 连接失败
177
177
  */
178
178
  10003
179
- /** 没有找到指定服务
180
- * @abnormal no service
179
+ /** no service
180
+ * @illustrate 没有找到指定服务
181
181
  */
182
182
  10004
183
- /** 没有找到指定特征值
184
- * @abnormal no characteristic
183
+ /** no characteristic
184
+ * @illustrate 没有找到指定特征值
185
185
  */
186
186
  10005
187
- /** 当前连接已断开
188
- * @abnormal no connection
187
+ /** no connection
188
+ * @illustrate 当前连接已断开
189
189
  */
190
190
  10006
191
- /** 当前特征值不支持此操作
192
- * @abnormal property not support
191
+ /** property not support
192
+ * @illustrate 当前特征值不支持此操作
193
193
  */
194
194
  10007
195
- /** 其余所有系统上报的异常
196
- * @abnormal system error
195
+ /** system error
196
+ * @illustrate 其余所有系统上报的异常
197
197
  */
198
198
  10008
199
- /** Android 系统特有,系统版本低于 4.3 不支持 BLE
200
- * @abnormal system not support
199
+ /** system not support
200
+ * @illustrate Android 系统特有,系统版本低于 4.3 不支持 BLE
201
201
  */
202
202
  10009
203
- /** 连接超时
204
- * @abnormal operate time out
203
+ /** operate time out
204
+ * @illustrate 连接超时
205
205
  */
206
206
  10012
207
- /** 连接 deviceId 为空或者是格式不正确
208
- * @abnormal invalid_data
207
+ /** invalid_data
208
+ * @illustrate 连接 deviceId 为空或者是格式不正确
209
209
  */
210
210
  10013
211
211
  }
212
212
  /** iBeacon 错误码 */
213
213
  interface IBeaconErrCode {
214
- /** 正常
215
- * @abnormal ok
214
+ /** ok
215
+ * @illustrate 正常
216
216
  */
217
217
  0
218
- /** 系统或设备不支持
219
- * @abnormal unsupport
218
+ /** nonsupport
219
+ * @illustrate 系统或设备不支持
220
220
  */
221
221
  11000
222
- /** 蓝牙服务不可用
223
- * @abnormal bluetooth service unavailable
222
+ /** bluetooth service unavailable
223
+ * @illustrate 蓝牙服务不可用
224
224
  */
225
225
  11001
226
- /** 位置服务不可用
227
- * @abnormal location service unavailable
226
+ /** location service unavailable
227
+ * @illustrate 位置服务不可用
228
228
  */
229
229
  11002
230
- /** 已经开始搜索
231
- * @abnormal already start
230
+ /** already start
231
+ * @illustrate 已经开始搜索
232
232
  */
233
233
  11003
234
- /** 还未开始搜索
235
- * @abnormal not startBeaconDiscovery
234
+ /** not startBeaconDiscovery
235
+ * @illustrate 还未开始搜索
236
236
  */
237
237
  11004
238
- /** 系统错误
239
- * @abnormal system error
238
+ /** system error
239
+ * @illustrate 系统错误
240
240
  */
241
241
  11005
242
- /** 参数不正确
243
- * @abnormal invalid data
242
+ /** invalid data
243
+ * @illustrate 参数不正确
244
244
  */
245
245
  11006
246
246
  }
247
247
  /** WIFI 错误码 */
248
248
  interface WifiErrCode {
249
- /** 正常
250
- * @abnormal ok
249
+ /** ok
250
+ * @illustrate 正常
251
251
  */
252
252
  0
253
- /** 未先调用 `startWifi` 接口
254
- * @abnormal not init
253
+ /** not init
254
+ * @illustrate 未先调用 `startWifi` 接口
255
255
  */
256
256
  12000
257
- /** 当前系统不支持相关能力
258
- * @abnormal system not support
257
+ /** system not support
258
+ * @illustrate 当前系统不支持相关能力
259
259
  */
260
260
  12001
261
- /** 密码错误
262
- * @abnormal password error Wi-Fi
261
+ /** password error Wi-Fi
262
+ * @illustrate 密码错误
263
263
  */
264
264
  12002
265
- /** 连接超时
266
- * @abnormal connection timeout
265
+ /** connection timeout
266
+ * @illustrate 连接超时
267
267
  */
268
268
  12003
269
- /** 重复连接 Wi-Fi
270
- * @abnormal duplicate request
269
+ /** duplicate request
270
+ * @illustrate 重复连接 Wi-Fi
271
271
  */
272
272
  12004
273
- /** Android 特有,未打开 Wi-Fi 开关
274
- * @abnormal wifi not turned on
273
+ /** wifi not turned on
274
+ * @illustrate Android 特有,未打开 Wi-Fi 开关
275
275
  */
276
276
  12005
277
- /** Android 特有,未打开 GPS 定位开关
278
- * @abnormal wifi not turned on
277
+ /** gps not turned on
278
+ * @illustrate Android 特有,未打开 GPS 定位开关
279
279
  */
280
280
  12006
281
- /** 用户拒绝授权链接 Wi-Fi
282
- * @abnormal user denied
281
+ /** user denied
282
+ * @illustrate 用户拒绝授权链接 Wi-Fi
283
283
  */
284
284
  12007
285
- /** 无效 SSID
286
- * @abnormal invalid SSID
285
+ /** invalid SSID
286
+ * @illustrate 无效 SSID
287
287
  */
288
288
  12008
289
- /** 系统运营商配置拒绝连接 Wi-Fi
290
- * @abnormal system config err
289
+ /** system config err
290
+ * @illustrate 系统运营商配置拒绝连接 Wi-Fi
291
291
  */
292
292
  12009
293
- /** 系统其他错误,需要在 errmsg 打印具体的错误原因
294
- * @abnormal system internal error
293
+ /** system internal error
294
+ * @illustrate 系统其他错误,需要在 errmsg 打印具体的错误原因
295
295
  */
296
296
  12010
297
- /** 应用在后台无法配置 Wi-Fi
298
- * @abnormal weapp in background
297
+ /** weapp in background
298
+ * @illustrate 应用在后台无法配置 Wi-Fi
299
299
  */
300
300
  12011
301
- /** 系统保存的 Wi-Fi 配置过期,建议忘记 Wi-Fi 后重试
302
- * @abnormal wifi config may be expired
301
+ /** wifi config may be expired
302
+ * @illustrate 系统保存的 Wi-Fi 配置过期,建议忘记 Wi-Fi 后重试
303
303
  */
304
304
  12013
305
305
  }
306
306
  /** NFC 错误码 */
307
307
  interface NFCErrCode {
308
- /** 正常
309
- * @abnormal ok
308
+ /** ok
309
+ * @illustrate 正常
310
310
  */
311
311
  0
312
- /** 当前设备不支持NFC */
312
+ /** @illustrate 当前设备不支持 NFC */
313
313
  13000
314
- /** 当前设备支持NFC,但系统NFC开关未开启 */
314
+ /** @illustrate 当前设备支持 NFC,但系统 NFC 开关未开启 */
315
315
  13001
316
- /** 当前设备支持NFC,但不支持HCE */
316
+ /** @illustrate 当前设备支持 NFC,但不支持 HCE */
317
317
  13002
318
- /** AID列表参数格式错误 */
318
+ /** @illustrate AID 列表参数格式错误 */
319
319
  13003
320
- /** 未设置微信为默认NFC支付应用 */
320
+ /** @illustrate 未设置微信为默认 NFC 支付应用 */
321
321
  13004
322
- /** 返回的指令不合法 */
322
+ /** @illustrate 返回的指令不合法 */
323
323
  13005
324
- /** 注册AID失败 */
324
+ /** @illustrate 注册 AID 失败 */
325
325
  13006
326
- }
327
-
328
- /** 启动参数 */
329
- interface LaunchOptionsApp {
330
- /** 启动小程序的路径 */
331
- path: string
332
- /** 启动小程序的 query 参数 */
333
- query: IAnyObject
334
- /** 来源信息。从另一个小程序、公众号或 App 进入小程序时返回。否则返回 `{}`。(参见后文注意) */
335
- referrerInfo: LaunchOptionsApp.ReferrerInfo
336
- /** 启动小程序的[场景值](https://developers.weixin.qq.com/miniprogram/dev/framework/app-service/scene.html) */
337
- scene: number
338
- /** shareTicket,详见[获取更多转发信息](https://developers.weixin.qq.com/miniprogram/dev/framework/open-ability/share.html) */
339
- shareTicket: string
340
- }
341
-
342
- namespace LaunchOptionsApp {
343
- interface ReferrerInfo {
344
- /** 来源小程序、公众号或 App 的 appId */
345
- appId: string
346
- /** 来源小程序传过来的数据,scene=1037或1038时支持 */
347
- extraData: IAnyObject
348
- }
326
+ /** @illustrate 未知错误 */
327
+ 13010
328
+ /** user is not authorized
329
+ * @illustrate 用户未授权
330
+ */
331
+ 13019
332
+ /** invalid parameter
333
+ * @illustrate 参数无效
334
+ */
335
+ 13011
336
+ /** parse NdefMessage failed
337
+ * @illustrate 将参数解析为 NdefMessage 失败
338
+ */
339
+ 13012
340
+ /** NFC tag has not been discovered
341
+ * @illustrate 未扫描到NFC标签
342
+ */
343
+ 13013
344
+ /** invalid tech
345
+ * @illustrate 无效的标签技术
346
+ */
347
+ 13014
348
+ /** unavailable tech
349
+ * @illustrate 从标签上获取对应技术失败
350
+ */
351
+ 13015
352
+ /** connect fail
353
+ * @illustrate 连接失败
354
+ */
355
+ 13016
356
+ /** system internal error
357
+ * @illustrate 相关读写操作失败
358
+ */
359
+ 13017
360
+ /** NFC discovery has not started
361
+ * @illustrate 尝试在未开始 NFC 扫描时停止 NFC 扫描
362
+ */
363
+ 13018
364
+ /** NFC discovery already started
365
+ * @illustrate 已经开始 NFC 扫描
366
+ */
367
+ 13021
368
+ /** Tech already connected
369
+ * @illustrate 标签已经连接
370
+ */
371
+ 13022
372
+ /** Tech has not connected
373
+ * @illustrate 尝试在未连接标签时断开连接
374
+ */
375
+ 13023
376
+ /** function not support
377
+ * @illustrate 当前标签技术不支持该功能
378
+ */
379
+ 13024
349
380
  }
350
381
 
351
382
  // Events