qsh-webview-sdk 2.3.3 → 2.3.5
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/index.d.ts +42 -7
- package/dist/qsh-webview-sdk.es.js +1231 -1081
- package/dist/qsh-webview-sdk.es.js.map +1 -1
- package/dist/qsh-webview-sdk.umd.js +1 -1
- package/dist/qsh-webview-sdk.umd.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -234,21 +234,31 @@ declare namespace UniWebView {
|
|
|
234
234
|
/** 各 kind 对应的 payload(按需传字段) */
|
|
235
235
|
interface ShareUniversalPayloadWeb {
|
|
236
236
|
title: string;
|
|
237
|
-
|
|
237
|
+
description: string;
|
|
238
238
|
imageUrl: string;
|
|
239
|
-
/**
|
|
240
|
-
|
|
241
|
-
|
|
239
|
+
/** 分享点击后进入的最终业务页面路径 */
|
|
240
|
+
targetPath: string;
|
|
241
|
+
/** App 微信图文卡片点击使用的公网链接 */
|
|
242
|
+
shareLink: string;
|
|
242
243
|
}
|
|
243
244
|
|
|
244
245
|
interface ShareUniversalPayloadText {
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
246
|
+
title?: string;
|
|
247
|
+
description: string;
|
|
248
|
+
imageUrl?: string;
|
|
249
|
+
/** 分享点击后进入的最终业务页面路径 */
|
|
250
|
+
targetPath: string;
|
|
251
|
+
/** App 微信图文卡片点击使用的公网链接 */
|
|
252
|
+
shareLink: string;
|
|
248
253
|
}
|
|
249
254
|
|
|
250
255
|
interface ShareUniversalPayloadImage {
|
|
251
256
|
imageUrl: string;
|
|
257
|
+
/** 分享点击后进入的最终业务页面路径 */
|
|
258
|
+
targetPath: string;
|
|
259
|
+
/** App 微信图文卡片点击使用的公网链接 */
|
|
260
|
+
shareLink: string;
|
|
261
|
+
title?: string;
|
|
252
262
|
}
|
|
253
263
|
|
|
254
264
|
type ShareUniversalPayload =
|
|
@@ -279,6 +289,30 @@ declare namespace UniWebView {
|
|
|
279
289
|
complete?: () => void;
|
|
280
290
|
}
|
|
281
291
|
|
|
292
|
+
interface ShareMiniProgramCardPayload {
|
|
293
|
+
title: string;
|
|
294
|
+
imageUrl: string;
|
|
295
|
+
/** 目标小程序页面路径,必须是 /pages/... 形式 */
|
|
296
|
+
targetPath: string;
|
|
297
|
+
/** 目标小程序 appid */
|
|
298
|
+
appid: string;
|
|
299
|
+
/** 小程序环境版本 */
|
|
300
|
+
envVersion?: "release" | "trial" | "develop";
|
|
301
|
+
/** 兜底网页链接,供 App 微信通道必要时使用 */
|
|
302
|
+
fallbackWebUrl?: string;
|
|
303
|
+
/** 小程序卡片描述 */
|
|
304
|
+
description?: string;
|
|
305
|
+
/** 预留:若宿主 App 通道需要,也可传 shareLink */
|
|
306
|
+
shareLink?: string;
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
interface ShareMiniProgramCardOptions {
|
|
310
|
+
payload: ShareMiniProgramCardPayload;
|
|
311
|
+
success?: (res: ShareResult) => void;
|
|
312
|
+
fail?: (error: any) => void;
|
|
313
|
+
complete?: () => void;
|
|
314
|
+
}
|
|
315
|
+
|
|
282
316
|
interface BluetoothOptions {
|
|
283
317
|
success?: (res: any) => void;
|
|
284
318
|
fail?: (error: any) => void;
|
|
@@ -438,6 +472,7 @@ declare namespace UniWebView {
|
|
|
438
472
|
|
|
439
473
|
/** 定向分享模块:仅 H5 -> 宿主 WebView */
|
|
440
474
|
shareDirected(options: ShareDirectedOptions): Promise<ShareResult> | void;
|
|
475
|
+
shareMiniProgramCard(options: ShareMiniProgramCardOptions): Promise<ShareResult> | void;
|
|
441
476
|
shareDirectedAsync(
|
|
442
477
|
options: Omit<ShareDirectedOptions, "success" | "fail" | "complete">,
|
|
443
478
|
): Promise<ShareResult>;
|