@tarojs/taro-h5 3.5.7 → 3.6.0-canary.1

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.
@@ -1,3 +1,3 @@
1
1
  export declare const scanCode: (options?: Partial<{
2
2
  needResult: number;
3
- }>) => Promise<any>;
3
+ }>, ...args: any[]) => Promise<any>;
@@ -1,2 +1,2 @@
1
1
  import Taro from '@tarojs/api';
2
- export declare const getLocation: (options?: Partial<Taro.getLocation.Option>) => Promise<Taro.getLocation.SuccessCallbackResult>;
2
+ export declare const getLocation: (options?: Partial<Taro.getLocation.Option>, ...args: any[]) => Promise<Taro.getLocation.SuccessCallbackResult>;
@@ -3,7 +3,7 @@ export declare const startLocationUpdateBackground: (option?: {}, ...args: any[]
3
3
  export declare const startLocationUpdate: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
4
4
  export declare const openLocation: (options?: Partial<{
5
5
  scale: number;
6
- }>) => Promise<any>;
6
+ }>, ...args: any[]) => Promise<any>;
7
7
  export declare const onLocationChangeError: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
8
8
  export declare const onLocationChange: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
9
9
  export declare const offLocationChangeError: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
@@ -269,7 +269,7 @@ declare const makePhoneCall: typeof Taro.makePhoneCall;
269
269
  // 扫码
270
270
  declare const scanCode: (options?: Partial<{
271
271
  needResult: number;
272
- }>) => Promise<any>;
272
+ }>, ...args: any[]) => Promise<any>;
273
273
  // 屏幕
274
274
  declare const setVisualEffectOnCapture: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
275
275
  declare const setScreenBrightness: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
@@ -318,12 +318,12 @@ declare const startLocationUpdateBackground: (option?: {}, ...args: any[]) => Pr
318
318
  declare const startLocationUpdate: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
319
319
  declare const openLocation: (options?: Partial<{
320
320
  scale: number;
321
- }>) => Promise<any>;
321
+ }>, ...args: any[]) => Promise<any>;
322
322
  declare const onLocationChangeError: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
323
323
  declare const onLocationChange: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
324
324
  declare const offLocationChangeError: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
325
325
  declare const offLocationChange: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
326
- declare const getLocation: (options?: Partial<Taro.getLocation.Option>) => Promise<Taro.getLocation.SuccessCallbackResult>;
326
+ declare const getLocation: (options?: Partial<Taro.getLocation.Option>, ...args: any[]) => Promise<Taro.getLocation.SuccessCallbackResult>;
327
327
  declare const choosePoi: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
328
328
  declare const getFuzzyLocation: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
329
329
  /**
package/dist/index.cjs.js CHANGED
@@ -281,7 +281,7 @@ function permanentlyNotSupport(name = '') {
281
281
  }
282
282
  function processOpenApi({ name, defaultOptions, standardMethod, formatOptions = options => options, formatResult = res => res }) {
283
283
  const notSupported = weixinCorpSupport(name);
284
- return (options = {}) => {
284
+ return (options = {}, ...args) => {
285
285
  var _a;
286
286
  // @ts-ignore
287
287
  const targetApi = (_a = window === null || window === void 0 ? void 0 : window.wx) === null || _a === void 0 ? void 0 : _a[name];
@@ -307,7 +307,7 @@ function processOpenApi({ name, defaultOptions, standardMethod, formatOptions =
307
307
  return standardMethod(opts);
308
308
  }
309
309
  else {
310
- return notSupported();
310
+ return notSupported(options, ...args);
311
311
  }
312
312
  };
313
313
  }