@tarojs/taro-h5 3.6.7-alpha.0 → 3.6.7-alpha.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.
- package/dist/api/ad/index.js +2 -2
- package/dist/api/ad/index.js.map +1 -1
- package/dist/api/ai/facial.js +3 -3
- package/dist/api/ai/facial.js.map +1 -1
- package/dist/api/ai/visual.js +2 -2
- package/dist/api/ai/visual.js.map +1 -1
- package/dist/api/alipay/index.js +1 -1
- package/dist/api/alipay/index.js.map +1 -1
- package/dist/api/base/crypto.js +1 -1
- package/dist/api/base/crypto.js.map +1 -1
- package/dist/api/base/debug.js +3 -3
- package/dist/api/base/debug.js.map +1 -1
- package/dist/api/base/performance.js +2 -2
- package/dist/api/base/performance.js.map +1 -1
- package/dist/api/base/system.js +2 -2
- package/dist/api/base/system.js.map +1 -1
- package/dist/api/base/update.js +2 -2
- package/dist/api/base/update.js.map +1 -1
- package/dist/api/base/weapp/app-event.js +5 -5
- package/dist/api/base/weapp/app-event.js.map +1 -1
- package/dist/api/canvas/index.js +1 -1
- package/dist/api/canvas/index.js.map +1 -1
- package/dist/api/data-analysis/index.js +4 -4
- package/dist/api/data-analysis/index.js.map +1 -1
- package/dist/api/device/accelerometer.js +1 -1
- package/dist/api/device/accelerometer.js.map +1 -1
- package/dist/api/device/accessibility.js +1 -1
- package/dist/api/device/accessibility.js.map +1 -1
- package/dist/api/device/battery.js +1 -1
- package/dist/api/device/battery.js.map +1 -1
- package/dist/api/device/bluetooth-ble.js +16 -16
- package/dist/api/device/bluetooth-ble.js.map +1 -1
- package/dist/api/device/bluetooth-peripheral.js +3 -3
- package/dist/api/device/bluetooth-peripheral.js.map +1 -1
- package/dist/api/device/bluetooth.js +13 -13
- package/dist/api/device/bluetooth.js.map +1 -1
- package/dist/api/device/calendar.d.ts +3 -2
- package/dist/api/device/calendar.js +142 -3
- package/dist/api/device/calendar.js.map +1 -1
- package/dist/api/device/compass.js +1 -1
- package/dist/api/device/compass.js.map +1 -1
- package/dist/api/device/contact.js +2 -2
- package/dist/api/device/contact.js.map +1 -1
- package/dist/api/device/crypto.js +1 -1
- package/dist/api/device/crypto.js.map +1 -1
- package/dist/api/device/gyroscope.js +4 -4
- package/dist/api/device/gyroscope.js.map +1 -1
- package/dist/api/device/iBeacon.js +7 -7
- package/dist/api/device/iBeacon.js.map +1 -1
- package/dist/api/device/keyboard.js +4 -4
- package/dist/api/device/keyboard.js.map +1 -1
- package/dist/api/device/memory.js +2 -2
- package/dist/api/device/memory.js.map +1 -1
- package/dist/api/device/motion.js +1 -1
- package/dist/api/device/motion.js.map +1 -1
- package/dist/api/device/network.js +3 -3
- package/dist/api/device/network.js.map +1 -1
- package/dist/api/device/nfc.js +7 -7
- package/dist/api/device/nfc.js.map +1 -1
- package/dist/api/device/scan.js +1 -1
- package/dist/api/device/scan.js.map +1 -1
- package/dist/api/device/screen.js +6 -6
- package/dist/api/device/screen.js.map +1 -1
- package/dist/api/device/wifi.js +12 -12
- package/dist/api/device/wifi.js.map +1 -1
- package/dist/api/ext/index.js +2 -2
- package/dist/api/ext/index.js.map +1 -1
- package/dist/api/files/index.js +8 -8
- package/dist/api/files/index.js.map +1 -1
- package/dist/api/index.js +7 -2
- package/dist/api/index.js.map +1 -1
- package/dist/api/location/getLocation.js +1 -1
- package/dist/api/location/getLocation.js.map +1 -1
- package/dist/api/location/index.js +10 -10
- package/dist/api/location/index.js.map +1 -1
- package/dist/api/media/audio/index.js +8 -8
- package/dist/api/media/audio/index.js.map +1 -1
- package/dist/api/media/background-audio/index.js +8 -8
- package/dist/api/media/background-audio/index.js.map +1 -1
- package/dist/api/media/camera.js +1 -1
- package/dist/api/media/camera.js.map +1 -1
- package/dist/api/media/image/chooseImage.d.ts +1 -0
- package/dist/api/media/image/chooseImage.js +28 -71
- package/dist/api/media/image/chooseImage.js.map +1 -1
- package/dist/api/media/image/index.d.ts +4 -3
- package/dist/api/media/image/index.js +8 -9
- package/dist/api/media/image/index.js.map +1 -1
- package/dist/api/media/image/saveImageToPhotosAlbum.d.ts +3 -0
- package/dist/api/media/image/saveImageToPhotosAlbum.js +30 -0
- package/dist/api/media/image/saveImageToPhotosAlbum.js.map +1 -0
- package/dist/api/media/index.js +2 -2
- package/dist/api/media/live.js +2 -2
- package/dist/api/media/live.js.map +1 -1
- package/dist/api/media/map.js +1 -1
- package/dist/api/media/map.js.map +1 -1
- package/dist/api/media/media-recorder.js +1 -1
- package/dist/api/media/media-recorder.js.map +1 -1
- package/dist/api/media/recorder.js +3 -3
- package/dist/api/media/recorder.js.map +1 -1
- package/dist/api/media/video/chooseMedia.d.ts +6 -0
- package/dist/api/media/video/chooseMedia.js +208 -0
- package/dist/api/media/video/chooseMedia.js.map +1 -0
- package/dist/api/media/video/chooseVideo.d.ts +7 -0
- package/dist/api/media/video/chooseVideo.js +44 -0
- package/dist/api/media/video/chooseVideo.js.map +1 -0
- package/dist/api/media/video/getVideoInfo.d.ts +3 -0
- package/dist/api/media/video/getVideoInfo.js +63 -0
- package/dist/api/media/video/getVideoInfo.js.map +1 -0
- package/dist/api/media/video/index.d.ts +5 -8
- package/dist/api/media/video/index.js +8 -67
- package/dist/api/media/video/index.js.map +1 -1
- package/dist/api/media/video/saveVideoToPhotosAlbum.d.ts +3 -0
- package/dist/api/media/video/saveVideoToPhotosAlbum.js +30 -0
- package/dist/api/media/video/saveVideoToPhotosAlbum.js.map +1 -0
- package/dist/api/media/video-decoder.js +1 -1
- package/dist/api/media/video-decoder.js.map +1 -1
- package/dist/api/media/video-processing.js +1 -1
- package/dist/api/media/video-processing.js.map +1 -1
- package/dist/api/media/voip.js +14 -14
- package/dist/api/media/voip.js.map +1 -1
- package/dist/api/navigate/index.js +5 -5
- package/dist/api/navigate/index.js.map +1 -1
- package/dist/api/network/mdns.js +10 -10
- package/dist/api/network/mdns.js.map +1 -1
- package/dist/api/network/tcp.js +1 -1
- package/dist/api/network/tcp.js.map +1 -1
- package/dist/api/network/udp.js +1 -1
- package/dist/api/network/udp.js.map +1 -1
- package/dist/api/open-api/account.js +1 -1
- package/dist/api/open-api/account.js.map +1 -1
- package/dist/api/open-api/address.js +1 -1
- package/dist/api/open-api/address.js.map +1 -1
- package/dist/api/open-api/authorize.js +2 -2
- package/dist/api/open-api/authorize.js.map +1 -1
- package/dist/api/open-api/card.js +2 -2
- package/dist/api/open-api/card.js.map +1 -1
- package/dist/api/open-api/channels-live.js +6 -6
- package/dist/api/open-api/channels-live.js.map +1 -1
- package/dist/api/open-api/customer-service.js +1 -1
- package/dist/api/open-api/customer-service.js.map +1 -1
- package/dist/api/open-api/facial.js +4 -4
- package/dist/api/open-api/facial.js.map +1 -1
- package/dist/api/open-api/favorites.js +3 -3
- package/dist/api/open-api/favorites.js.map +1 -1
- package/dist/api/open-api/group.js +1 -1
- package/dist/api/open-api/group.js.map +1 -1
- package/dist/api/open-api/invoice.js +2 -2
- package/dist/api/open-api/invoice.js.map +1 -1
- package/dist/api/open-api/license-plate.js +1 -1
- package/dist/api/open-api/license-plate.js.map +1 -1
- package/dist/api/open-api/login.js +3 -3
- package/dist/api/open-api/login.js.map +1 -1
- package/dist/api/open-api/red-package.js +1 -1
- package/dist/api/open-api/red-package.js.map +1 -1
- package/dist/api/open-api/settings.js +2 -2
- package/dist/api/open-api/settings.js.map +1 -1
- package/dist/api/open-api/soter.js +3 -3
- package/dist/api/open-api/soter.js.map +1 -1
- package/dist/api/open-api/subscribe-message.js +2 -2
- package/dist/api/open-api/subscribe-message.js.map +1 -1
- package/dist/api/open-api/user-info.js +2 -2
- package/dist/api/open-api/user-info.js.map +1 -1
- package/dist/api/open-api/werun.js +2 -2
- package/dist/api/open-api/werun.js.map +1 -1
- package/dist/api/payment/index.js +2 -2
- package/dist/api/payment/index.js.map +1 -1
- package/dist/api/qq/index.js +1 -1
- package/dist/api/qq/index.js.map +1 -1
- package/dist/api/share/index.d.ts +10 -0
- package/dist/api/share/index.js +21 -11
- package/dist/api/share/index.js.map +1 -1
- package/dist/api/storage/background-fetch.js +4 -4
- package/dist/api/storage/background-fetch.js.map +1 -1
- package/dist/api/storage/index.js +2 -2
- package/dist/api/storage/index.js.map +1 -1
- package/dist/api/swan/index.js +21 -21
- package/dist/api/swan/index.js.map +1 -1
- package/dist/api/taro.js +1 -1
- package/dist/api/taro.js.map +1 -1
- package/dist/api/ui/background.js +2 -2
- package/dist/api/ui/background.js.map +1 -1
- package/dist/api/ui/interaction/index.d.ts +1 -1
- package/dist/api/ui/interaction/index.js +4 -4
- package/dist/api/ui/interaction/index.js.map +1 -1
- package/dist/api/ui/menu.js +1 -1
- package/dist/api/ui/menu.js.map +1 -1
- package/dist/api/ui/navigation-bar/index.js +3 -3
- package/dist/api/ui/navigation-bar/index.js.map +1 -1
- package/dist/api/ui/sticky.js +1 -1
- package/dist/api/ui/sticky.js.map +1 -1
- package/dist/api/ui/window.js +2 -2
- package/dist/api/ui/window.js.map +1 -1
- package/dist/api/worker/index.js +1 -1
- package/dist/api/worker/index.js.map +1 -1
- package/dist/api/wxml/IntersectionObserver.d.ts +1 -1
- package/dist/api/wxml/IntersectionObserver.js +0 -1
- package/dist/api/wxml/IntersectionObserver.js.map +1 -1
- package/dist/api/wxml/MediaQueryObserver.d.ts +1 -1
- package/dist/api/wxml/MediaQueryObserver.js.map +1 -1
- package/dist/index.cjs.d.ts +24 -11
- package/dist/index.cjs.js +2262 -1853
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.d.ts +24 -11
- package/dist/index.esm.js +2241 -1851
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +7 -2
- package/dist/index.js.map +1 -1
- package/dist/utils/helper.d.ts +2 -0
- package/dist/utils/helper.js +11 -0
- package/dist/utils/helper.js.map +1 -0
- package/dist/utils/index.d.ts +1 -0
- package/dist/utils/index.js +1 -0
- package/dist/utils/index.js.map +1 -1
- package/package.json +7 -6
package/dist/api/ad/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
3
|
// 广告
|
|
4
|
-
const createRewardedVideoAd = temporarilyNotSupport('createRewardedVideoAd');
|
|
5
|
-
const createInterstitialAd = temporarilyNotSupport('createInterstitialAd');
|
|
4
|
+
const createRewardedVideoAd = /* @__PURE__ */ temporarilyNotSupport('createRewardedVideoAd');
|
|
5
|
+
const createInterstitialAd = /* @__PURE__ */ temporarilyNotSupport('createInterstitialAd');
|
|
6
6
|
|
|
7
7
|
export { createInterstitialAd, createRewardedVideoAd };
|
|
8
8
|
//# sourceMappingURL=index.js.map
|
package/dist/api/ad/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/api/ad/index.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 广告\nexport const createRewardedVideoAd = temporarilyNotSupport('createRewardedVideoAd')\nexport const createInterstitialAd = temporarilyNotSupport('createInterstitialAd')\n"],"names":[],"mappings":";;AAEA;
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/api/ad/index.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 广告\nexport const createRewardedVideoAd = /* @__PURE__ */ temporarilyNotSupport('createRewardedVideoAd')\nexport const createInterstitialAd = /* @__PURE__ */ temporarilyNotSupport('createInterstitialAd')\n"],"names":[],"mappings":";;AAEA;AACa,MAAA,qBAAqB,mBAAmB,qBAAqB,CAAC,uBAAuB,EAAC;AACtF,MAAA,oBAAoB,mBAAmB,qBAAqB,CAAC,sBAAsB;;;;"}
|
package/dist/api/ai/facial.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
3
|
// 人脸识别
|
|
4
|
-
const stopFaceDetect = temporarilyNotSupport('stopFaceDetect');
|
|
5
|
-
const initFaceDetect = temporarilyNotSupport('initFaceDetect');
|
|
6
|
-
const faceDetect = temporarilyNotSupport('faceDetect');
|
|
4
|
+
const stopFaceDetect = /* @__PURE__ */ temporarilyNotSupport('stopFaceDetect');
|
|
5
|
+
const initFaceDetect = /* @__PURE__ */ temporarilyNotSupport('initFaceDetect');
|
|
6
|
+
const faceDetect = /* @__PURE__ */ temporarilyNotSupport('faceDetect');
|
|
7
7
|
|
|
8
8
|
export { faceDetect, initFaceDetect, stopFaceDetect };
|
|
9
9
|
//# sourceMappingURL=facial.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"facial.js","sources":["../../../src/api/ai/facial.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 人脸识别\nexport const stopFaceDetect = temporarilyNotSupport('stopFaceDetect')\nexport const initFaceDetect = temporarilyNotSupport('initFaceDetect')\nexport const faceDetect = temporarilyNotSupport('faceDetect')\n"],"names":[],"mappings":";;AAEA;
|
|
1
|
+
{"version":3,"file":"facial.js","sources":["../../../src/api/ai/facial.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 人脸识别\nexport const stopFaceDetect = /* @__PURE__ */ temporarilyNotSupport('stopFaceDetect')\nexport const initFaceDetect = /* @__PURE__ */ temporarilyNotSupport('initFaceDetect')\nexport const faceDetect = /* @__PURE__ */ temporarilyNotSupport('faceDetect')\n"],"names":[],"mappings":";;AAEA;AACa,MAAA,cAAc,mBAAmB,qBAAqB,CAAC,gBAAgB,EAAC;AACxE,MAAA,cAAc,mBAAmB,qBAAqB,CAAC,gBAAgB,EAAC;AACxE,MAAA,UAAU,mBAAmB,qBAAqB,CAAC,YAAY;;;;"}
|
package/dist/api/ai/visual.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
3
|
// 判断支持版本
|
|
4
|
-
const isVKSupport = temporarilyNotSupport('isVKSupport');
|
|
4
|
+
const isVKSupport = /* @__PURE__ */ temporarilyNotSupport('isVKSupport');
|
|
5
5
|
// 视觉算法
|
|
6
|
-
const createVKSession = temporarilyNotSupport('createVKSession');
|
|
6
|
+
const createVKSession = /* @__PURE__ */ temporarilyNotSupport('createVKSession');
|
|
7
7
|
|
|
8
8
|
export { createVKSession, isVKSupport };
|
|
9
9
|
//# sourceMappingURL=visual.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"visual.js","sources":["../../../src/api/ai/visual.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 判断支持版本\nexport const isVKSupport = temporarilyNotSupport('isVKSupport')\n\n// 视觉算法\nexport const createVKSession = temporarilyNotSupport('createVKSession')\n"],"names":[],"mappings":";;AAEA;
|
|
1
|
+
{"version":3,"file":"visual.js","sources":["../../../src/api/ai/visual.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 判断支持版本\nexport const isVKSupport = /* @__PURE__ */ temporarilyNotSupport('isVKSupport')\n\n// 视觉算法\nexport const createVKSession = /* @__PURE__ */ temporarilyNotSupport('createVKSession')\n"],"names":[],"mappings":";;AAEA;AACa,MAAA,WAAW,mBAAmB,qBAAqB,CAAC,aAAa,EAAC;AAE/E;AACa,MAAA,eAAe,mBAAmB,qBAAqB,CAAC,iBAAiB;;;;"}
|
package/dist/api/alipay/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
3
|
// AliPay
|
|
4
|
-
const getOpenUserInfo = temporarilyNotSupport('getOpenUserInfo');
|
|
4
|
+
const getOpenUserInfo = /* @__PURE__ */ temporarilyNotSupport('getOpenUserInfo');
|
|
5
5
|
|
|
6
6
|
export { getOpenUserInfo };
|
|
7
7
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/api/alipay/index.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// AliPay\nexport const getOpenUserInfo = temporarilyNotSupport('getOpenUserInfo')\n"],"names":[],"mappings":";;AAEA;
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/api/alipay/index.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// AliPay\nexport const getOpenUserInfo = /* @__PURE__ */ temporarilyNotSupport('getOpenUserInfo')\n"],"names":[],"mappings":";;AAEA;AACa,MAAA,eAAe,mBAAmB,qBAAqB,CAAC,iBAAiB;;;;"}
|
package/dist/api/base/crypto.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
3
|
// 加密
|
|
4
|
-
const getUserCryptoManager = temporarilyNotSupport('getUserCryptoManager');
|
|
4
|
+
const getUserCryptoManager = /* @__PURE__ */ temporarilyNotSupport('getUserCryptoManager');
|
|
5
5
|
|
|
6
6
|
export { getUserCryptoManager };
|
|
7
7
|
//# sourceMappingURL=crypto.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"crypto.js","sources":["../../../src/api/base/crypto.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 加密\nexport const getUserCryptoManager = temporarilyNotSupport('getUserCryptoManager')\n"],"names":[],"mappings":";;AAEA;
|
|
1
|
+
{"version":3,"file":"crypto.js","sources":["../../../src/api/base/crypto.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 加密\nexport const getUserCryptoManager = /* @__PURE__ */ temporarilyNotSupport('getUserCryptoManager')\n"],"names":[],"mappings":";;AAEA;AACa,MAAA,oBAAoB,mBAAmB,qBAAqB,CAAC,sBAAsB;;;;"}
|
package/dist/api/base/debug.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
|
-
const setEnableDebug = temporarilyNotSupport('setEnableDebug');
|
|
4
|
-
const getRealtimeLogManager = temporarilyNotSupport('getRealtimeLogManager');
|
|
5
|
-
const getLogManager = temporarilyNotSupport('getLogManager');
|
|
3
|
+
const setEnableDebug = /* @__PURE__ */ temporarilyNotSupport('setEnableDebug');
|
|
4
|
+
const getRealtimeLogManager = /* @__PURE__ */ temporarilyNotSupport('getRealtimeLogManager');
|
|
5
|
+
const getLogManager = /* @__PURE__ */ temporarilyNotSupport('getLogManager');
|
|
6
6
|
|
|
7
7
|
export { getLogManager, getRealtimeLogManager, setEnableDebug };
|
|
8
8
|
//# sourceMappingURL=debug.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"debug.js","sources":["../../../src/api/base/debug.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\nexport const setEnableDebug = temporarilyNotSupport('setEnableDebug')\nexport const getRealtimeLogManager = temporarilyNotSupport('getRealtimeLogManager')\nexport const getLogManager = temporarilyNotSupport('getLogManager')\n"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"debug.js","sources":["../../../src/api/base/debug.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\nexport const setEnableDebug = /* @__PURE__ */ temporarilyNotSupport('setEnableDebug')\nexport const getRealtimeLogManager = /* @__PURE__ */ temporarilyNotSupport('getRealtimeLogManager')\nexport const getLogManager = /* @__PURE__ */ temporarilyNotSupport('getLogManager')\n"],"names":[],"mappings":";;AAEa,MAAA,cAAc,mBAAmB,qBAAqB,CAAC,gBAAgB,EAAC;AACxE,MAAA,qBAAqB,mBAAmB,qBAAqB,CAAC,uBAAuB,EAAC;AACtF,MAAA,aAAa,mBAAmB,qBAAqB,CAAC,eAAe;;;;"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
3
|
// 性能
|
|
4
|
-
const reportPerformance = temporarilyNotSupport('reportPerformance');
|
|
5
|
-
const getPerformance = temporarilyNotSupport('getPerformance');
|
|
4
|
+
const reportPerformance = /* @__PURE__ */ temporarilyNotSupport('reportPerformance');
|
|
5
|
+
const getPerformance = /* @__PURE__ */ temporarilyNotSupport('getPerformance');
|
|
6
6
|
|
|
7
7
|
export { getPerformance, reportPerformance };
|
|
8
8
|
//# sourceMappingURL=performance.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"performance.js","sources":["../../../src/api/base/performance.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 性能\nexport const reportPerformance = temporarilyNotSupport('reportPerformance')\nexport const getPerformance = temporarilyNotSupport('getPerformance')\n"],"names":[],"mappings":";;AAEA;
|
|
1
|
+
{"version":3,"file":"performance.js","sources":["../../../src/api/base/performance.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 性能\nexport const reportPerformance = /* @__PURE__ */ temporarilyNotSupport('reportPerformance')\nexport const getPerformance = /* @__PURE__ */ temporarilyNotSupport('getPerformance')\n"],"names":[],"mappings":";;AAEA;AACa,MAAA,iBAAiB,mBAAmB,qBAAqB,CAAC,mBAAmB,EAAC;AAC9E,MAAA,cAAc,mBAAmB,qBAAqB,CAAC,gBAAgB;;;;"}
|
package/dist/api/base/system.js
CHANGED
|
@@ -4,9 +4,9 @@ import { temporarilyNotSupport } from '../../utils/index.js';
|
|
|
4
4
|
import { MethodHandler } from '../../utils/handler.js';
|
|
5
5
|
|
|
6
6
|
/** 跳转系统蓝牙设置页 */
|
|
7
|
-
const openSystemBluetoothSetting = temporarilyNotSupport('openSystemBluetoothSetting');
|
|
7
|
+
const openSystemBluetoothSetting = /* @__PURE__ */ temporarilyNotSupport('openSystemBluetoothSetting');
|
|
8
8
|
/** 跳转系统微信授权管理页 */
|
|
9
|
-
const openAppAuthorizeSetting = temporarilyNotSupport('openAppAuthorizeSetting');
|
|
9
|
+
const openAppAuthorizeSetting = /* @__PURE__ */ temporarilyNotSupport('openAppAuthorizeSetting');
|
|
10
10
|
/** 获取窗口信息 */
|
|
11
11
|
const getWindowInfo = () => {
|
|
12
12
|
const info = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"system.js","sources":["../../../src/api/base/system.ts"],"sourcesContent":["import Taro from '@tarojs/api'\nimport { getMobileDetect } from '@tarojs/router/dist/utils/navigate'\n\nimport { temporarilyNotSupport } from '../../utils'\nimport { MethodHandler } from '../../utils/handler'\n\n/** 跳转系统蓝牙设置页 */\nexport const openSystemBluetoothSetting = temporarilyNotSupport('openSystemBluetoothSetting')\n\n/** 跳转系统微信授权管理页 */\nexport const openAppAuthorizeSetting = temporarilyNotSupport('openAppAuthorizeSetting')\n\n/** 获取窗口信息 */\nexport const getWindowInfo: typeof Taro.getWindowInfo = () => {\n const info: ReturnType<typeof Taro.getWindowInfo> = {\n /** 设备像素比 */\n pixelRatio: window.devicePixelRatio,\n /** 屏幕宽度,单位px */\n screenWidth: window.screen.width,\n /** 屏幕高度,单位px */\n screenHeight: window.screen.height,\n /** 可使用窗口宽度,单位px */\n windowWidth: document.documentElement.clientWidth,\n /** 可使用窗口高度,单位px */\n windowHeight: document.documentElement.clientHeight,\n /** 状态栏的高度,单位px */\n statusBarHeight: NaN,\n /** 在竖屏正方向下的安全区域 */\n safeArea: {\n bottom: 0,\n height: 0,\n left: 0,\n right: 0,\n top: 0,\n width: 0\n }\n }\n\n return info\n}\n\n/** 获取设备设置 */\nexport const getSystemSetting: typeof Taro.getSystemSetting = () => {\n const isLandscape = window.screen.width >= window.screen.height\n const info: ReturnType<typeof Taro.getSystemSetting> = {\n /** 蓝牙的系统开关 */\n bluetoothEnabled: false,\n /** 地理位置的系统开关 */\n locationEnabled: false,\n /** Wi-Fi 的系统开关 */\n wifiEnabled: false,\n /** 设备方向 */\n deviceOrientation: isLandscape ? 'landscape' : 'portrait'\n }\n\n return info\n}\n\n/** 获取设备设置 */\nexport const getDeviceInfo: typeof Taro.getDeviceInfo = () => {\n const md = getMobileDetect()\n\n const info: ReturnType<typeof Taro.getDeviceInfo> = {\n /** 应用二进制接口类型(仅 Android 支持) */\n abi: '',\n /** 设备二进制接口类型(仅 Android 支持) */\n deviceAbi: '',\n /** 设备性能等级(仅Android小游戏)。取值为:-2 或 0(该设备无法运行小游戏),-1(性能未知),>=1(设备性能值,该值越高,设备性能越好,目前最高不到50) */\n benchmarkLevel: -1,\n /** 设备品牌 */\n brand: md.mobile() || '',\n /** 设备型号 */\n model: md.mobile() || '',\n /** 操作系统及版本 */\n system: md.os(),\n /** 客户端平台 */\n platform: navigator.platform,\n /** 设备二进制接口类型(仅 Android 支持) */\n CPUType: '',\n }\n\n return info\n}\n\n/** 获取微信APP基础信息 */\nexport const getAppBaseInfo: typeof Taro.getAppBaseInfo = () => {\n let isDarkMode = false\n if (window.matchMedia?.('(prefers-color-scheme: dark)').matches) {\n isDarkMode = true\n }\n\n const info: ReturnType<typeof Taro.getAppBaseInfo> = {\n /** 客户端基础库版本 */\n SDKVersion: '',\n /** 是否已打开调试。可通过右上角菜单或 [Taro.setEnableDebug](/docs/apis/base/debug/setEnableDebug) 打开调试。 */\n enableDebug: process.env.NODE_ENV !== 'production',\n /** 当前小程序运行的宿主环境 */\n // host: { appId: '' },\n /** 微信设置的语言 */\n language: navigator.language,\n /** 微信版本号 */\n version: '',\n /** 系统当前主题,取值为light或dark,全局配置\"darkmode\":true时才能获取,否则为 undefined (不支持小游戏) */\n theme: isDarkMode ? 'dark' : 'light'\n }\n\n return info\n}\n\n/** 获取微信APP授权设置 */\nexport const getAppAuthorizeSetting: typeof Taro.getAppAuthorizeSetting = () => {\n const info: ReturnType<typeof Taro.getAppAuthorizeSetting> = {\n /** 允许微信使用相册的开关(仅 iOS 有效) */\n albumAuthorized: 'not determined',\n /** 允许微信使用蓝牙的开关(仅 iOS 有效) */\n bluetoothAuthorized: 'not determined',\n /** 允许微信使用摄像头的开关 */\n cameraAuthorized: 'not determined',\n /** 允许微信使用定位的开关 */\n locationAuthorized: 'not determined',\n /** 定位准确度。true 表示模糊定位,false 表示精确定位(仅 iOS 有效) */\n locationReducedAccuracy: false,\n /** 允许微信使用麦克风的开关 */\n microphoneAuthorized: 'not determined',\n /** 允许微信通知的开关 */\n notificationAuthorized: 'not determined',\n /** 允许微信通知带有提醒的开关(仅 iOS 有效) */\n notificationAlertAuthorized: 'not determined',\n /** 允许微信通知带有标记的开关(仅 iOS 有效) */\n notificationBadgeAuthorized: 'not determined',\n /** 允许微信通知带有声音的开关(仅 iOS 有效) */\n notificationSoundAuthorized: 'not determined',\n /** 允许微信使用日历的开关 */\n phoneCalendarAuthorized: 'not determined'\n }\n\n return info\n}\n\n/** 获取设备设置 */\nexport const getSystemInfoSync: typeof Taro.getSystemInfoSync = () => {\n const windowInfo = getWindowInfo()\n const systemSetting = getSystemSetting()\n const deviceInfo: Taro.getDeviceInfo.Result = getDeviceInfo()\n const appBaseInfo = getAppBaseInfo()\n const appAuthorizeSetting = getAppAuthorizeSetting()\n delete deviceInfo.abi\n\n const info: ReturnType<typeof Taro.getSystemInfoSync> = {\n ...windowInfo,\n ...systemSetting,\n ...deviceInfo,\n ...appBaseInfo,\n /** 用户字体大小(单位px)。以微信客户端「我-设置-通用-字体大小」中的设置为准 */\n fontSizeSetting: NaN,\n /** 允许微信使用相册的开关(仅 iOS 有效) */\n albumAuthorized: appAuthorizeSetting.albumAuthorized === 'authorized',\n /** 允许微信使用摄像头的开关 */\n cameraAuthorized: appAuthorizeSetting.cameraAuthorized === 'authorized',\n /** 允许微信使用定位的开关 */\n locationAuthorized: appAuthorizeSetting.locationAuthorized === 'authorized',\n /** 允许微信使用麦克风的开关 */\n microphoneAuthorized: appAuthorizeSetting.microphoneAuthorized === 'authorized',\n /** 允许微信通知的开关 */\n notificationAuthorized: appAuthorizeSetting.notificationAuthorized === 'authorized',\n /** 允许微信通知带有提醒的开关(仅 iOS 有效) */\n notificationAlertAuthorized: appAuthorizeSetting.notificationAlertAuthorized === 'authorized',\n /** 允许微信通知带有标记的开关(仅 iOS 有效) */\n notificationBadgeAuthorized: appAuthorizeSetting.notificationBadgeAuthorized === 'authorized',\n /** 允许微信通知带有声音的开关(仅 iOS 有效) */\n notificationSoundAuthorized: appAuthorizeSetting.notificationSoundAuthorized === 'authorized',\n /** 允许微信使用日历的开关 */\n phoneCalendarAuthorized: appAuthorizeSetting.phoneCalendarAuthorized === 'authorized',\n /** `true` 表示模糊定位,`false` 表示精确定位,仅 iOS 支持 */\n locationReducedAccuracy: appAuthorizeSetting.locationReducedAccuracy,\n /** 小程序当前运行环境 */\n environment: ''\n }\n\n return info\n}\n\n/** 获取系统信息 */\nexport const getSystemInfoAsync: typeof Taro.getSystemInfoAsync = async (options = {}) => {\n const { success, fail, complete } = options\n const handle = new MethodHandler({ name: 'getSystemInfoAsync', success, fail, complete })\n\n try {\n const info = await getSystemInfoSync()\n return handle.success(info)\n } catch (error) {\n return handle.fail({\n errMsg: error\n })\n }\n}\n\n/** 获取系统信息 */\nexport const getSystemInfo: typeof Taro.getSystemInfo = async (options = {}) => {\n const { success, fail, complete } = options\n const handle = new MethodHandler({ name: 'getSystemInfo', success, fail, complete })\n\n try {\n const info = await getSystemInfoSync()\n return handle.success(info)\n } catch (error) {\n return handle.fail({\n errMsg: error\n })\n }\n}\n"],"names":[],"mappings":";;;;;AAMA;MACa,0BAA0B,GAAG,qBAAqB,CAAC,4BAA4B,EAAC;AAE7F;MACa,uBAAuB,GAAG,qBAAqB,CAAC,yBAAyB,EAAC;AAEvF;AACO,MAAM,aAAa,GAA8B,MAAK;AAC3D,IAAA,MAAM,IAAI,GAA0C;;QAElD,UAAU,EAAE,MAAM,CAAC,gBAAgB;;AAEnC,QAAA,WAAW,EAAE,MAAM,CAAC,MAAM,CAAC,KAAK;;AAEhC,QAAA,YAAY,EAAE,MAAM,CAAC,MAAM,CAAC,MAAM;;AAElC,QAAA,WAAW,EAAE,QAAQ,CAAC,eAAe,CAAC,WAAW;;AAEjD,QAAA,YAAY,EAAE,QAAQ,CAAC,eAAe,CAAC,YAAY;;AAEnD,QAAA,eAAe,EAAE,GAAG;;AAEpB,QAAA,QAAQ,EAAE;AACR,YAAA,MAAM,EAAE,CAAC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AAO,CAAC,IAAI,CAAC,CAAA;AAC5B,KAAA;AAAC,IAAA,OAAO,KAAK,EAAE;QACd,OAAO,MAAM,CAAC,IAAI,CAAC;AACjB,YAAA,MAAM,EAAE,KAAK;AACd,SAAA,CAAC,CAAA;AACH,KAAA;AACH,CAAC,EAAA;AAED;MACa,aAAa,GAA8B,CAAO,OAAO,GAAG,EAAE,KAAI,SAAA,CAAA,KAAA,CAAA,EAAA,KAAA,CAAA,EAAA,KAAA,CAAA,EAAA,aAAA;IAC7E,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,GAAG,OAAO,CAAA;AAC3C,IAAA,MAAM,MAAM,GAAG,IAAI,aAAa,CAAC,EAAE,IAAI,EAAE,eAAe,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAA;IAEpF,IAAI;AACF,QAAA,MAAM,IAAI,GAAG,MAAM,iBAAiB,EAAE,CAAA;AACtC,QAAA,OAAO,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,CAAA;AAC5B,KAAA;AAAC,IAAA,OAAO,KAAK,EAAE;QACd,OAAO,MAAM,CAAC,IAAI,CAAC;AACjB,YAAA,MAAM,EAAE,KAAK;AACd,SAAA,CAAC,CAAA;AACH,KAAA;AACH,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"system.js","sources":["../../../src/api/base/system.ts"],"sourcesContent":["import Taro from '@tarojs/api'\nimport { getMobileDetect } from '@tarojs/router/dist/utils/navigate'\n\nimport { temporarilyNotSupport } from '../../utils'\nimport { MethodHandler } from '../../utils/handler'\n\n/** 跳转系统蓝牙设置页 */\nexport const openSystemBluetoothSetting = /* @__PURE__ */ temporarilyNotSupport('openSystemBluetoothSetting')\n\n/** 跳转系统微信授权管理页 */\nexport const openAppAuthorizeSetting = /* @__PURE__ */ temporarilyNotSupport('openAppAuthorizeSetting')\n\n/** 获取窗口信息 */\nexport const getWindowInfo: typeof Taro.getWindowInfo = () => {\n const info: ReturnType<typeof Taro.getWindowInfo> = {\n /** 设备像素比 */\n pixelRatio: window.devicePixelRatio,\n /** 屏幕宽度,单位px */\n screenWidth: window.screen.width,\n /** 屏幕高度,单位px */\n screenHeight: window.screen.height,\n /** 可使用窗口宽度,单位px */\n windowWidth: document.documentElement.clientWidth,\n /** 可使用窗口高度,单位px */\n windowHeight: document.documentElement.clientHeight,\n /** 状态栏的高度,单位px */\n statusBarHeight: NaN,\n /** 在竖屏正方向下的安全区域 */\n safeArea: {\n bottom: 0,\n height: 0,\n left: 0,\n right: 0,\n top: 0,\n width: 0\n }\n }\n\n return info\n}\n\n/** 获取设备设置 */\nexport const getSystemSetting: typeof Taro.getSystemSetting = () => {\n const isLandscape = window.screen.width >= window.screen.height\n const info: ReturnType<typeof Taro.getSystemSetting> = {\n /** 蓝牙的系统开关 */\n bluetoothEnabled: false,\n /** 地理位置的系统开关 */\n locationEnabled: false,\n /** Wi-Fi 的系统开关 */\n wifiEnabled: false,\n /** 设备方向 */\n deviceOrientation: isLandscape ? 'landscape' : 'portrait'\n }\n\n return info\n}\n\n/** 获取设备设置 */\nexport const getDeviceInfo: typeof Taro.getDeviceInfo = () => {\n const md = getMobileDetect()\n\n const info: ReturnType<typeof Taro.getDeviceInfo> = {\n /** 应用二进制接口类型(仅 Android 支持) */\n abi: '',\n /** 设备二进制接口类型(仅 Android 支持) */\n deviceAbi: '',\n /** 设备性能等级(仅Android小游戏)。取值为:-2 或 0(该设备无法运行小游戏),-1(性能未知),>=1(设备性能值,该值越高,设备性能越好,目前最高不到50) */\n benchmarkLevel: -1,\n /** 设备品牌 */\n brand: md.mobile() || '',\n /** 设备型号 */\n model: md.mobile() || '',\n /** 操作系统及版本 */\n system: md.os(),\n /** 客户端平台 */\n platform: navigator.platform,\n /** 设备二进制接口类型(仅 Android 支持) */\n CPUType: '',\n }\n\n return info\n}\n\n/** 获取微信APP基础信息 */\nexport const getAppBaseInfo: typeof Taro.getAppBaseInfo = () => {\n let isDarkMode = false\n if (window.matchMedia?.('(prefers-color-scheme: dark)').matches) {\n isDarkMode = true\n }\n\n const info: ReturnType<typeof Taro.getAppBaseInfo> = {\n /** 客户端基础库版本 */\n SDKVersion: '',\n /** 是否已打开调试。可通过右上角菜单或 [Taro.setEnableDebug](/docs/apis/base/debug/setEnableDebug) 打开调试。 */\n enableDebug: process.env.NODE_ENV !== 'production',\n /** 当前小程序运行的宿主环境 */\n // host: { appId: '' },\n /** 微信设置的语言 */\n language: navigator.language,\n /** 微信版本号 */\n version: '',\n /** 系统当前主题,取值为light或dark,全局配置\"darkmode\":true时才能获取,否则为 undefined (不支持小游戏) */\n theme: isDarkMode ? 'dark' : 'light'\n }\n\n return info\n}\n\n/** 获取微信APP授权设置 */\nexport const getAppAuthorizeSetting: typeof Taro.getAppAuthorizeSetting = () => {\n const info: ReturnType<typeof Taro.getAppAuthorizeSetting> = {\n /** 允许微信使用相册的开关(仅 iOS 有效) */\n albumAuthorized: 'not determined',\n /** 允许微信使用蓝牙的开关(仅 iOS 有效) */\n bluetoothAuthorized: 'not determined',\n /** 允许微信使用摄像头的开关 */\n cameraAuthorized: 'not determined',\n /** 允许微信使用定位的开关 */\n locationAuthorized: 'not determined',\n /** 定位准确度。true 表示模糊定位,false 表示精确定位(仅 iOS 有效) */\n locationReducedAccuracy: false,\n /** 允许微信使用麦克风的开关 */\n microphoneAuthorized: 'not determined',\n /** 允许微信通知的开关 */\n notificationAuthorized: 'not determined',\n /** 允许微信通知带有提醒的开关(仅 iOS 有效) */\n notificationAlertAuthorized: 'not determined',\n /** 允许微信通知带有标记的开关(仅 iOS 有效) */\n notificationBadgeAuthorized: 'not determined',\n /** 允许微信通知带有声音的开关(仅 iOS 有效) */\n notificationSoundAuthorized: 'not determined',\n /** 允许微信使用日历的开关 */\n phoneCalendarAuthorized: 'not determined'\n }\n\n return info\n}\n\n/** 获取设备设置 */\nexport const getSystemInfoSync: typeof Taro.getSystemInfoSync = () => {\n const windowInfo = getWindowInfo()\n const systemSetting = getSystemSetting()\n const deviceInfo: Taro.getDeviceInfo.Result = getDeviceInfo()\n const appBaseInfo = getAppBaseInfo()\n const appAuthorizeSetting = getAppAuthorizeSetting()\n delete deviceInfo.abi\n\n const info: ReturnType<typeof Taro.getSystemInfoSync> = {\n ...windowInfo,\n ...systemSetting,\n ...deviceInfo,\n ...appBaseInfo,\n /** 用户字体大小(单位px)。以微信客户端「我-设置-通用-字体大小」中的设置为准 */\n fontSizeSetting: NaN,\n /** 允许微信使用相册的开关(仅 iOS 有效) */\n albumAuthorized: appAuthorizeSetting.albumAuthorized === 'authorized',\n /** 允许微信使用摄像头的开关 */\n cameraAuthorized: appAuthorizeSetting.cameraAuthorized === 'authorized',\n /** 允许微信使用定位的开关 */\n locationAuthorized: appAuthorizeSetting.locationAuthorized === 'authorized',\n /** 允许微信使用麦克风的开关 */\n microphoneAuthorized: appAuthorizeSetting.microphoneAuthorized === 'authorized',\n /** 允许微信通知的开关 */\n notificationAuthorized: appAuthorizeSetting.notificationAuthorized === 'authorized',\n /** 允许微信通知带有提醒的开关(仅 iOS 有效) */\n notificationAlertAuthorized: appAuthorizeSetting.notificationAlertAuthorized === 'authorized',\n /** 允许微信通知带有标记的开关(仅 iOS 有效) */\n notificationBadgeAuthorized: appAuthorizeSetting.notificationBadgeAuthorized === 'authorized',\n /** 允许微信通知带有声音的开关(仅 iOS 有效) */\n notificationSoundAuthorized: appAuthorizeSetting.notificationSoundAuthorized === 'authorized',\n /** 允许微信使用日历的开关 */\n phoneCalendarAuthorized: appAuthorizeSetting.phoneCalendarAuthorized === 'authorized',\n /** `true` 表示模糊定位,`false` 表示精确定位,仅 iOS 支持 */\n locationReducedAccuracy: appAuthorizeSetting.locationReducedAccuracy,\n /** 小程序当前运行环境 */\n environment: ''\n }\n\n return info\n}\n\n/** 获取系统信息 */\nexport const getSystemInfoAsync: typeof Taro.getSystemInfoAsync = async (options = {}) => {\n const { success, fail, complete } = options\n const handle = new MethodHandler({ name: 'getSystemInfoAsync', success, fail, complete })\n\n try {\n const info = await getSystemInfoSync()\n return handle.success(info)\n } catch (error) {\n return handle.fail({\n errMsg: error\n })\n }\n}\n\n/** 获取系统信息 */\nexport const getSystemInfo: typeof Taro.getSystemInfo = async (options = {}) => {\n const { success, fail, complete } = options\n const handle = new MethodHandler({ name: 'getSystemInfo', success, fail, complete })\n\n try {\n const info = await getSystemInfoSync()\n return handle.success(info)\n } catch (error) {\n return handle.fail({\n errMsg: error\n })\n }\n}\n"],"names":[],"mappings":";;;;;AAMA;AACa,MAAA,0BAA0B,mBAAmB,qBAAqB,CAAC,4BAA4B,EAAC;AAE7G;AACa,MAAA,uBAAuB,mBAAmB,qBAAqB,CAAC,yBAAyB,EAAC;AAEvG;AACO,MAAM,aAAa,GAA8B,MAAK;AAC3D,IAAA,MAAM,IAAI,GAA0C;;QAElD,UAAU,EAAE,MAAM,CAAC,gBAAgB;;AAEnC,QAAA,WAAW,EAAE,MAAM,CAAC,MAAM,CAAC,KAAK;;AAEhC,QAAA,YAAY,EAAE,MAAM,CAAC,MAAM,CAAC,MAAM;;AAElC,QAAA,WAAW,EAAE,QAAQ,CAAC,eAAe,CAAC,WAAW;;AAEjD,QAAA,YAAY,EAAE,QAAQ,CAAC,eAAe,CAAC,YAAY;;AAEnD,QAAA,eAAe,EAAE,GAAG;;AAEpB,QAAA,QAAQ,EAAE;AACR,YAAA,MAAM,EAAE,CAAC;AACT,YAAA,MAAM,EAAE,CAAC;AACT,YAAA,IAAI,EAAE,CAAC;AACP,YAAA,KAAK,EAAE,CAAC;AACR,YAAA,GAAG,EAAE,CAAC;AACN,YAAA,KAAK,EAAE,CAAC;AACT,SAAA;KACF,CAAA;AAED,IAAA,OAAO,IAAI,CAAA;AACb,EAAC;AAED;AACO,MAAM,gBAAgB,GAAiC,MAAK;AACjE,IAAA,MAAM,WAAW,GAAG,MAAM,CAAC,MAAM,CAAC,KAAK,IAAI,MAAM,CAAC,MAAM,CAAC,MAAM,CAAA;AAC/D,IAAA,MAAM,IAAI,GAA6C;;AAErD,Q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AAC3C,IAAA,MAAM,MAAM,GAAG,IAAI,aAAa,CAAC,EAAE,IAAI,EAAE,eAAe,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAA;IAEpF,IAAI;AACF,QAAA,MAAM,IAAI,GAAG,MAAM,iBAAiB,EAAE,CAAA;AACtC,QAAA,OAAO,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,CAAA;AAC5B,KAAA;AAAC,IAAA,OAAO,KAAK,EAAE;QACd,OAAO,MAAM,CAAC,IAAI,CAAC;AACjB,YAAA,MAAM,EAAE,KAAK;AACd,SAAA,CAAC,CAAA;AACH,KAAA;AACH,CAAC;;;;"}
|
package/dist/api/base/update.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
3
|
// 更新
|
|
4
|
-
const updateWeChatApp = temporarilyNotSupport('updateWeChatApp');
|
|
5
|
-
const getUpdateManager = temporarilyNotSupport('getUpdateManager');
|
|
4
|
+
const updateWeChatApp = /* @__PURE__ */ temporarilyNotSupport('updateWeChatApp');
|
|
5
|
+
const getUpdateManager = /* @__PURE__ */ temporarilyNotSupport('getUpdateManager');
|
|
6
6
|
|
|
7
7
|
export { getUpdateManager, updateWeChatApp };
|
|
8
8
|
//# sourceMappingURL=update.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"update.js","sources":["../../../src/api/base/update.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 更新\nexport const updateWeChatApp = temporarilyNotSupport('updateWeChatApp')\nexport const getUpdateManager = temporarilyNotSupport('getUpdateManager')\n"],"names":[],"mappings":";;AAEA;
|
|
1
|
+
{"version":3,"file":"update.js","sources":["../../../src/api/base/update.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 更新\nexport const updateWeChatApp = /* @__PURE__ */ temporarilyNotSupport('updateWeChatApp')\nexport const getUpdateManager = /* @__PURE__ */ temporarilyNotSupport('getUpdateManager')\n"],"names":[],"mappings":";;AAEA;AACa,MAAA,eAAe,mBAAmB,qBAAqB,CAAC,iBAAiB,EAAC;AAC1E,MAAA,gBAAgB,mBAAmB,qBAAqB,CAAC,kBAAkB;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import Taro from '@tarojs/api';
|
|
2
|
-
import
|
|
2
|
+
import isNil from 'lodash-es/isNil';
|
|
3
3
|
import { parse } from 'query-string';
|
|
4
4
|
import { temporarilyNotSupport } from '../../../utils/index.js';
|
|
5
5
|
import { CallbackManager } from '../../../utils/handler.js';
|
|
@@ -80,8 +80,8 @@ const onError = callback => {
|
|
|
80
80
|
window.addEventListener('error', errorListener);
|
|
81
81
|
}
|
|
82
82
|
};
|
|
83
|
-
const onAudioInterruptionEnd = temporarilyNotSupport('onAudioInterruptionEnd');
|
|
84
|
-
const onAudioInterruptionBegin = temporarilyNotSupport('onAudioInterruptionBegin');
|
|
83
|
+
const onAudioInterruptionEnd = /* @__PURE__ */ temporarilyNotSupport('onAudioInterruptionEnd');
|
|
84
|
+
const onAudioInterruptionBegin = /* @__PURE__ */ temporarilyNotSupport('onAudioInterruptionBegin');
|
|
85
85
|
const onAppShow = callback => {
|
|
86
86
|
appShowCallbackManager.add(callback);
|
|
87
87
|
if (appShowCallbackManager.count() === 1) {
|
|
@@ -122,8 +122,8 @@ const offError = callback => {
|
|
|
122
122
|
window.removeEventListener('error', errorListener);
|
|
123
123
|
}
|
|
124
124
|
};
|
|
125
|
-
const offAudioInterruptionEnd = temporarilyNotSupport('offAudioInterruptionEnd');
|
|
126
|
-
const offAudioInterruptionBegin = temporarilyNotSupport('offAudioInterruptionBegin');
|
|
125
|
+
const offAudioInterruptionEnd = /* @__PURE__ */ temporarilyNotSupport('offAudioInterruptionEnd');
|
|
126
|
+
const offAudioInterruptionBegin = /* @__PURE__ */ temporarilyNotSupport('offAudioInterruptionBegin');
|
|
127
127
|
const offAppShow = callback => {
|
|
128
128
|
appShowCallbackManager.remove(callback);
|
|
129
129
|
if (appShowCallbackManager.count() === 0) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app-event.js","sources":["../../../../src/api/base/weapp/app-event.ts"],"sourcesContent":["import Taro from '@tarojs/api'\nimport { isNil } from 'lodash-es'\nimport { parse } from 'query-string'\n\nimport { temporarilyNotSupport } from '../../../utils'\nimport { CallbackManager } from '../../../utils/handler'\n\nconst unhandledRejectionCallbackManager = new CallbackManager<[Taro.onUnhandledRejection.Result]>()\nconst themeChangeCallbackManager = new CallbackManager<[Taro.onThemeChange.Result]>()\nconst pageNotFoundCallbackManager = new CallbackManager<[Taro.onPageNotFound.Result]>()\nconst errorCallbackManager = new CallbackManager<Parameters<Taro.onError.Callback>>()\nconst appShowCallbackManager = new CallbackManager<[Taro.onAppShow.CallbackResult]>()\nconst appHideCallbackManager = new CallbackManager<[Taro.onAppShow.CallbackResult]>()\n\nconst unhandledRejectionListener = (res: PromiseRejectionEvent) => {\n unhandledRejectionCallbackManager.trigger(res)\n}\n\nlet themeMatchMedia: MediaQueryList | null = null\nconst themeChangeListener = (res: MediaQueryListEvent) => {\n themeChangeCallbackManager.trigger({\n theme: res.matches ? 'dark' : 'light'\n })\n}\n\nconst pageNotFoundListener = (res: Taro.onPageNotFound.Result) => {\n pageNotFoundCallbackManager.trigger(res)\n}\n\nconst errorListener = (res: ErrorEvent) => {\n // @ts-ignore\n errorCallbackManager.trigger(res.stack || res.message || res)\n}\n\nconst getApp = () => {\n const path = Taro.Current.page?.path\n return {\n /** 小程序切前台的路径 */\n path: path?.substring(0, path.indexOf('?')) || '',\n /** 小程序切前台的 query 参数 */\n query: parse(location.search),\n /** 来源信息。 */\n referrerInfo: {},\n /** 小程序切前台的[场景值](https://developers.weixin.qq.com/miniprogram/dev/framework/app-service/scene.html) */\n scene: 0,\n /** shareTicket,详见[获取更多转发信息](https://developers.weixin.qq.com/miniprogram/dev/framework/open-ability/share.html) */\n shareTicket: ''\n }\n}\n\nconst appShowListener = () => {\n if (document.visibilityState !== 'hidden') {\n appShowCallbackManager.trigger(getApp())\n }\n}\n\nconst appHideListener = () => {\n if (document.visibilityState === 'hidden') {\n appHideCallbackManager.trigger(getApp())\n }\n}\n\n// 应用级事件\nexport const onUnhandledRejection: typeof Taro.onUnhandledRejection = callback => {\n unhandledRejectionCallbackManager.add(callback)\n if (unhandledRejectionCallbackManager.count() === 1) {\n window.addEventListener('unhandledrejection', unhandledRejectionListener)\n }\n}\n\nexport const onThemeChange: typeof Taro.onThemeChange = callback => {\n themeChangeCallbackManager.add(callback)\n if (themeChangeCallbackManager.count() === 1) {\n if (isNil(themeMatchMedia)) {\n themeMatchMedia = window.matchMedia('(prefers-color-scheme: light)')\n }\n themeMatchMedia.addEventListener('change', themeChangeListener)\n }\n}\n\nexport const onPageNotFound: typeof Taro.onPageNotFound = callback => {\n pageNotFoundCallbackManager.add(callback)\n if (pageNotFoundCallbackManager.count() === 1) {\n Taro.eventCenter.on('__taroRouterNotFound', pageNotFoundListener)\n }\n}\n\nexport const onError: typeof Taro.onError = callback => {\n errorCallbackManager.add(callback)\n if (errorCallbackManager.count() === 1) {\n window.addEventListener('error', errorListener)\n }\n}\n\nexport const onAudioInterruptionEnd = temporarilyNotSupport('onAudioInterruptionEnd')\nexport const onAudioInterruptionBegin = temporarilyNotSupport('onAudioInterruptionBegin')\n\nexport const onAppShow: typeof Taro.onAppShow = callback => {\n appShowCallbackManager.add(callback)\n if (appShowCallbackManager.count() === 1) {\n window.addEventListener('visibilitychange', appShowListener)\n }\n}\n\nexport const onAppHide: typeof Taro.onAppHide = callback => {\n appHideCallbackManager.add(callback)\n if (appHideCallbackManager.count() === 1) {\n window.addEventListener('visibilitychange', appHideListener)\n }\n}\n\nexport const offUnhandledRejection: typeof Taro.offUnhandledRejection = callback => {\n unhandledRejectionCallbackManager.remove(callback)\n if (unhandledRejectionCallbackManager.count() === 0) {\n window.removeEventListener('unhandledrejection', unhandledRejectionListener)\n }\n}\n\nexport const offThemeChange: typeof Taro.offThemeChange = callback => {\n themeChangeCallbackManager.remove(callback)\n if (themeChangeCallbackManager.count() === 0) {\n if (isNil(themeMatchMedia)) {\n themeMatchMedia = window.matchMedia('(prefers-color-scheme: light)')\n }\n themeMatchMedia.removeEventListener('change', themeChangeListener)\n themeMatchMedia = null\n }\n}\n\nexport const offPageNotFound: typeof Taro.offPageNotFound = callback => {\n pageNotFoundCallbackManager.remove(callback)\n if (pageNotFoundCallbackManager.count() === 0) {\n Taro.eventCenter.off('__taroRouterNotFound', pageNotFoundListener)\n }\n}\n\nexport const offError: typeof Taro.offError = callback => {\n errorCallbackManager.remove(callback)\n if (errorCallbackManager.count() === 0) {\n window.removeEventListener('error', errorListener)\n }\n}\n\nexport const offAudioInterruptionEnd = temporarilyNotSupport('offAudioInterruptionEnd')\nexport const offAudioInterruptionBegin = temporarilyNotSupport('offAudioInterruptionBegin')\n\nexport const offAppShow: typeof Taro.offAppShow = callback => {\n appShowCallbackManager.remove(callback)\n if (appShowCallbackManager.count() === 0) {\n window.removeEventListener('visibilitychange', appShowListener)\n }\n}\n\nexport const offAppHide: typeof Taro.offAppHide = callback => {\n appHideCallbackManager.remove(callback)\n if (appHideCallbackManager.count() === 0) {\n window.removeEventListener('visibilitychange', appHideListener)\n }\n}\n"],"names":[],"mappings":";;;;;;AAOA,MAAM,iCAAiC,GAAG,IAAI,eAAe,EAAsC,CAAA;AACnG,MAAM,0BAA0B,GAAG,IAAI,eAAe,EAA+B,CAAA;AACrF,MAAM,2BAA2B,GAAG,IAAI,eAAe,EAAgC,CAAA;AACvF,MAAM,oBAAoB,GAAG,IAAI,eAAe,EAAqC,CAAA;AACrF,MAAM,sBAAsB,GAAG,IAAI,eAAe,EAAmC,CAAA;AACrF,MAAM,sBAAsB,GAAG,IAAI,eAAe,EAAmC,CAAA;AAErF,MAAM,0BAA0B,GAAG,CAAC,GAA0B,KAAI;AAChE,IAAA,iCAAiC,CAAC,OAAO,CAAC,GAAG,C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AAC,EAAE;AACxC,QAAA,MAAM,CAAC,mBAAmB,CAAC,kBAAkB,EAAE,eAAe,CAAC,CAAA;AAChE,KAAA;AACH;;;;"}
|
|
1
|
+
{"version":3,"file":"app-event.js","sources":["../../../../src/api/base/weapp/app-event.ts"],"sourcesContent":["import Taro from '@tarojs/api'\nimport isNil from 'lodash-es/isNil'\nimport { parse } from 'query-string'\n\nimport { temporarilyNotSupport } from '../../../utils'\nimport { CallbackManager } from '../../../utils/handler'\n\nconst unhandledRejectionCallbackManager = new CallbackManager<[Taro.onUnhandledRejection.Result]>()\nconst themeChangeCallbackManager = new CallbackManager<[Taro.onThemeChange.Result]>()\nconst pageNotFoundCallbackManager = new CallbackManager<[Taro.onPageNotFound.Result]>()\nconst errorCallbackManager = new CallbackManager<Parameters<Taro.onError.Callback>>()\nconst appShowCallbackManager = new CallbackManager<[Taro.onAppShow.CallbackResult]>()\nconst appHideCallbackManager = new CallbackManager<[Taro.onAppShow.CallbackResult]>()\n\nconst unhandledRejectionListener = (res: PromiseRejectionEvent) => {\n unhandledRejectionCallbackManager.trigger(res)\n}\n\nlet themeMatchMedia: MediaQueryList | null = null\nconst themeChangeListener = (res: MediaQueryListEvent) => {\n themeChangeCallbackManager.trigger({\n theme: res.matches ? 'dark' : 'light'\n })\n}\n\nconst pageNotFoundListener = (res: Taro.onPageNotFound.Result) => {\n pageNotFoundCallbackManager.trigger(res)\n}\n\nconst errorListener = (res: ErrorEvent) => {\n // @ts-ignore\n errorCallbackManager.trigger(res.stack || res.message || res)\n}\n\nconst getApp = () => {\n const path = Taro.Current.page?.path\n return {\n /** 小程序切前台的路径 */\n path: path?.substring(0, path.indexOf('?')) || '',\n /** 小程序切前台的 query 参数 */\n query: parse(location.search),\n /** 来源信息。 */\n referrerInfo: {},\n /** 小程序切前台的[场景值](https://developers.weixin.qq.com/miniprogram/dev/framework/app-service/scene.html) */\n scene: 0,\n /** shareTicket,详见[获取更多转发信息](https://developers.weixin.qq.com/miniprogram/dev/framework/open-ability/share.html) */\n shareTicket: ''\n }\n}\n\nconst appShowListener = () => {\n if (document.visibilityState !== 'hidden') {\n appShowCallbackManager.trigger(getApp())\n }\n}\n\nconst appHideListener = () => {\n if (document.visibilityState === 'hidden') {\n appHideCallbackManager.trigger(getApp())\n }\n}\n\n// 应用级事件\nexport const onUnhandledRejection: typeof Taro.onUnhandledRejection = callback => {\n unhandledRejectionCallbackManager.add(callback)\n if (unhandledRejectionCallbackManager.count() === 1) {\n window.addEventListener('unhandledrejection', unhandledRejectionListener)\n }\n}\n\nexport const onThemeChange: typeof Taro.onThemeChange = callback => {\n themeChangeCallbackManager.add(callback)\n if (themeChangeCallbackManager.count() === 1) {\n if (isNil(themeMatchMedia)) {\n themeMatchMedia = window.matchMedia('(prefers-color-scheme: light)')\n }\n themeMatchMedia.addEventListener('change', themeChangeListener)\n }\n}\n\nexport const onPageNotFound: typeof Taro.onPageNotFound = callback => {\n pageNotFoundCallbackManager.add(callback)\n if (pageNotFoundCallbackManager.count() === 1) {\n Taro.eventCenter.on('__taroRouterNotFound', pageNotFoundListener)\n }\n}\n\nexport const onError: typeof Taro.onError = callback => {\n errorCallbackManager.add(callback)\n if (errorCallbackManager.count() === 1) {\n window.addEventListener('error', errorListener)\n }\n}\n\nexport const onAudioInterruptionEnd = /* @__PURE__ */ temporarilyNotSupport('onAudioInterruptionEnd')\nexport const onAudioInterruptionBegin = /* @__PURE__ */ temporarilyNotSupport('onAudioInterruptionBegin')\n\nexport const onAppShow: typeof Taro.onAppShow = callback => {\n appShowCallbackManager.add(callback)\n if (appShowCallbackManager.count() === 1) {\n window.addEventListener('visibilitychange', appShowListener)\n }\n}\n\nexport const onAppHide: typeof Taro.onAppHide = callback => {\n appHideCallbackManager.add(callback)\n if (appHideCallbackManager.count() === 1) {\n window.addEventListener('visibilitychange', appHideListener)\n }\n}\n\nexport const offUnhandledRejection: typeof Taro.offUnhandledRejection = callback => {\n unhandledRejectionCallbackManager.remove(callback)\n if (unhandledRejectionCallbackManager.count() === 0) {\n window.removeEventListener('unhandledrejection', unhandledRejectionListener)\n }\n}\n\nexport const offThemeChange: typeof Taro.offThemeChange = callback => {\n themeChangeCallbackManager.remove(callback)\n if (themeChangeCallbackManager.count() === 0) {\n if (isNil(themeMatchMedia)) {\n themeMatchMedia = window.matchMedia('(prefers-color-scheme: light)')\n }\n themeMatchMedia.removeEventListener('change', themeChangeListener)\n themeMatchMedia = null\n }\n}\n\nexport const offPageNotFound: typeof Taro.offPageNotFound = callback => {\n pageNotFoundCallbackManager.remove(callback)\n if (pageNotFoundCallbackManager.count() === 0) {\n Taro.eventCenter.off('__taroRouterNotFound', pageNotFoundListener)\n }\n}\n\nexport const offError: typeof Taro.offError = callback => {\n errorCallbackManager.remove(callback)\n if (errorCallbackManager.count() === 0) {\n window.removeEventListener('error', errorListener)\n }\n}\n\nexport const offAudioInterruptionEnd = /* @__PURE__ */ temporarilyNotSupport('offAudioInterruptionEnd')\nexport const offAudioInterruptionBegin = /* @__PURE__ */ temporarilyNotSupport('offAudioInterruptionBegin')\n\nexport const offAppShow: typeof Taro.offAppShow = callback => {\n appShowCallbackManager.remove(callback)\n if (appShowCallbackManager.count() === 0) {\n window.removeEventListener('visibilitychange', appShowListener)\n }\n}\n\nexport const offAppHide: typeof Taro.offAppHide = callback => {\n appHideCallbackManager.remove(callback)\n if (appHideCallbackManager.count() === 0) {\n window.removeEventListener('visibilitychange', appHideListener)\n }\n}\n"],"names":[],"mappings":";;;;;;AAOA,MAAM,iCAAiC,GAAG,IAAI,eAAe,EAAsC,CAAA;AACnG,MAAM,0BAA0B,GAAG,IAAI,eAAe,EAA+B,CAAA;AACrF,MAAM,2BAA2B,GAAG,IAAI,eAAe,EAAgC,CAAA;AACvF,MAAM,oBAAoB,GAAG,IAAI,eAAe,EAAqC,CAAA;AACrF,MAAM,sBAAsB,GAAG,IAAI,eAAe,EAAmC,CAAA;AACrF,MAAM,sBAAsB,GAAG,IAAI,eAAe,EAAmC,CAAA;AAErF,MAAM,0BAA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C3D,IAAA,sBAAsB,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAA;AACvC,IAAA,IAAI,sBAAsB,CAAC,KAAK,EAAE,KAAK,CAAC,EAAE;AACxC,QAAA,MAAM,CAAC,mBAAmB,CAAC,kBAAkB,EAAE,eAAe,CAAC,CAAA;AAChE,KAAA;AACH;;;;"}
|
package/dist/api/canvas/index.js
CHANGED
|
@@ -6,7 +6,7 @@ export { canvasGetImageData } from './canvasGetImageData.js';
|
|
|
6
6
|
|
|
7
7
|
// 画布
|
|
8
8
|
/** 创建离屏 canvas 实例 */
|
|
9
|
-
const createOffscreenCanvas = temporarilyNotSupport('createOffscreenCanvas');
|
|
9
|
+
const createOffscreenCanvas = /* @__PURE__ */ temporarilyNotSupport('createOffscreenCanvas');
|
|
10
10
|
|
|
11
11
|
export { createOffscreenCanvas };
|
|
12
12
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/api/canvas/index.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\r\n\r\n// 画布\r\n\r\n/** 创建离屏 canvas 实例 */\r\nexport const createOffscreenCanvas = temporarilyNotSupport('createOffscreenCanvas')\r\n\r\n/** 创建 canvas 的绘图上下文 CanvasContext 对象 */\r\nexport * from './createCanvasContext'\r\n\r\n/** 把当前画布指定区域的内容导出生成指定大小的图片 */\r\nexport * from './canvasToTempFilePath'\r\n\r\n/** 将像素数据绘制到画布 */\r\nexport * from './canvasPutImageData'\r\n\r\n/** 获取 canvas 区域隐含的像素数据 */\r\nexport * from './canvasGetImageData'\r\n"],"names":[],"mappings":";;;;;;AAEA;AAEA;
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/api/canvas/index.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\r\n\r\n// 画布\r\n\r\n/** 创建离屏 canvas 实例 */\r\nexport const createOffscreenCanvas = /* @__PURE__ */ temporarilyNotSupport('createOffscreenCanvas')\r\n\r\n/** 创建 canvas 的绘图上下文 CanvasContext 对象 */\r\nexport * from './createCanvasContext'\r\n\r\n/** 把当前画布指定区域的内容导出生成指定大小的图片 */\r\nexport * from './canvasToTempFilePath'\r\n\r\n/** 将像素数据绘制到画布 */\r\nexport * from './canvasPutImageData'\r\n\r\n/** 获取 canvas 区域隐含的像素数据 */\r\nexport * from './canvasGetImageData'\r\n"],"names":[],"mappings":";;;;;;AAEA;AAEA;AACa,MAAA,qBAAqB,mBAAmB,qBAAqB,CAAC,uBAAuB;;;;"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
|
-
const reportMonitor = temporarilyNotSupport('reportMonitor');
|
|
4
|
-
const reportAnalytics = temporarilyNotSupport('reportAnalytics');
|
|
5
|
-
const reportEvent = temporarilyNotSupport('reportEvent');
|
|
6
|
-
const getExptInfoSync = temporarilyNotSupport('getExptInfoSync');
|
|
3
|
+
const reportMonitor = /* @__PURE__ */ temporarilyNotSupport('reportMonitor');
|
|
4
|
+
const reportAnalytics = /* @__PURE__ */ temporarilyNotSupport('reportAnalytics');
|
|
5
|
+
const reportEvent = /* @__PURE__ */ temporarilyNotSupport('reportEvent');
|
|
6
|
+
const getExptInfoSync = /* @__PURE__ */ temporarilyNotSupport('getExptInfoSync');
|
|
7
7
|
|
|
8
8
|
export { getExptInfoSync, reportAnalytics, reportEvent, reportMonitor };
|
|
9
9
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/api/data-analysis/index.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\nexport const reportMonitor = temporarilyNotSupport('reportMonitor')\nexport const reportAnalytics = temporarilyNotSupport('reportAnalytics')\nexport const reportEvent = temporarilyNotSupport('reportEvent')\nexport const getExptInfoSync = temporarilyNotSupport('getExptInfoSync')\n"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/api/data-analysis/index.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\nexport const reportMonitor = /* @__PURE__ */ temporarilyNotSupport('reportMonitor')\nexport const reportAnalytics = /* @__PURE__ */ temporarilyNotSupport('reportAnalytics')\nexport const reportEvent = /* @__PURE__ */ temporarilyNotSupport('reportEvent')\nexport const getExptInfoSync = /* @__PURE__ */ temporarilyNotSupport('getExptInfoSync')\n"],"names":[],"mappings":";;AAEa,MAAA,aAAa,mBAAmB,qBAAqB,CAAC,eAAe,EAAC;AACtE,MAAA,eAAe,mBAAmB,qBAAqB,CAAC,iBAAiB,EAAC;AAC1E,MAAA,WAAW,mBAAmB,qBAAqB,CAAC,aAAa,EAAC;AAClE,MAAA,eAAe,mBAAmB,qBAAqB,CAAC,iBAAiB;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"accelerometer.js","sources":["../../../src/api/device/accelerometer.ts"],"sourcesContent":["import Taro from '@tarojs/api'\r\nimport
|
|
1
|
+
{"version":3,"file":"accelerometer.js","sources":["../../../src/api/device/accelerometer.ts"],"sourcesContent":["import Taro from '@tarojs/api'\r\nimport throttle from 'lodash-es/throttle'\r\n\r\nimport { CallbackManager, MethodHandler } from '../../utils/handler'\r\n\r\nconst callbackManager = new CallbackManager()\r\nlet devicemotionListener\r\n\r\n/**\r\n * 停止监听加速度数据。\r\n */\r\nexport const stopAccelerometer: typeof Taro.stopAccelerometer = ({ success, fail, complete } = {}) => {\r\n const res: Partial<TaroGeneral.CallbackResult> = {}\r\n const handle = new MethodHandler({ name: 'stopAccelerometer', success, fail, complete })\r\n try {\r\n window.removeEventListener('devicemotion', devicemotionListener, true)\r\n return handle.success(res)\r\n } catch (e) {\r\n res.errMsg = e.message\r\n return handle.fail(res)\r\n }\r\n}\r\n\r\nconst INTERVAL_MAP = {\r\n game: {\r\n interval: 20,\r\n frequency: 50\r\n },\r\n ui: {\r\n interval: 60,\r\n frequency: 16.67\r\n },\r\n normal: {\r\n interval: 200,\r\n frequency: 5\r\n }\r\n}\r\n\r\n/**\r\n * 开始监听加速度数据。\r\n */\r\nexport const startAccelerometer: typeof Taro.startAccelerometer = ({ interval = 'normal', success, fail, complete } = {}) => {\r\n const handle = new MethodHandler({ name: 'startAccelerometer', success, fail, complete })\r\n try {\r\n if (window.DeviceMotionEvent) {\r\n const intervalObj = INTERVAL_MAP[interval]\r\n if (devicemotionListener) {\r\n stopAccelerometer()\r\n }\r\n devicemotionListener = throttle((evt: DeviceMotionEvent) => {\r\n callbackManager.trigger({\r\n x: evt.acceleration?.x || 0,\r\n y: evt.acceleration?.y || 0,\r\n z: evt.acceleration?.z || 0\r\n })\r\n }, intervalObj.interval)\r\n window.addEventListener('devicemotion', devicemotionListener, true)\r\n } else {\r\n throw new Error('accelerometer is not supported')\r\n }\r\n return handle.success()\r\n } catch (e) {\r\n return handle.fail({ errMsg: e.message })\r\n }\r\n}\r\n\r\n/**\r\n * 监听加速度数据事件。频率根据 Taro.startAccelerometer() 的 interval 参数。可使用 Taro.stopAccelerometer() 停止监听。\r\n */\r\nexport const onAccelerometerChange: typeof Taro.onAccelerometerChange = callback => {\r\n callbackManager.add(callback)\r\n}\r\n\r\n/**\r\n * 取消监听加速度数据事件,参数为空,则取消所有的事件监听\r\n */\r\nexport const offAccelerometerChange: typeof Taro.offAccelerometerChange = callback => {\r\n callbackManager.remove(callback)\r\n}\r\n"],"names":[],"mappings":";;;AAKA,MAAM,eAAe,GAAG,IAAI,eAAe,EAAE,CAAA;AAC7C,IAAI,oBAAoB,CAAA;AAExB;;AAEG;AACI,MAAM,iBAAiB,GAAkC,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,GAAG,EAAE,KAAI;IACnG,MAAM,GAAG,GAAwC,EAAE,CAAA;AACnD,IAAA,MAAM,MAAM,GAAG,IAAI,aAAa,CAAC,EAAE,IAAI,EAAE,mBAAmB,EAAE,OAAO,EAAE,IAAI,EAAE,Q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2
|
|
|
3
3
|
// 无障碍
|
|
4
|
-
const checkIsOpenAccessibility = temporarilyNotSupport('checkIsOpenAccessibility');
|
|
4
|
+
const checkIsOpenAccessibility = /* @__PURE__ */ temporarilyNotSupport('checkIsOpenAccessibility');
|
|
5
5
|
|
|
6
6
|
export { checkIsOpenAccessibility };
|
|
7
7
|
//# sourceMappingURL=accessibility.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"accessibility.js","sources":["../../../src/api/device/accessibility.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 无障碍\nexport const checkIsOpenAccessibility = temporarilyNotSupport('checkIsOpenAccessibility')\n"],"names":[],"mappings":";;AAEA;
|
|
1
|
+
{"version":3,"file":"accessibility.js","sources":["../../../src/api/device/accessibility.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 无障碍\nexport const checkIsOpenAccessibility = /* @__PURE__ */ temporarilyNotSupport('checkIsOpenAccessibility')\n"],"names":[],"mappings":";;AAEA;AACa,MAAA,wBAAwB,mBAAmB,qBAAqB,CAAC,0BAA0B;;;;"}
|
|
@@ -4,7 +4,7 @@ import { MethodHandler } from '../../utils/handler.js';
|
|
|
4
4
|
|
|
5
5
|
// 电量
|
|
6
6
|
// Note: 浏览器标准下不支持,其他实现方案不准确,不建议开发者使用
|
|
7
|
-
const getBatteryInfoSync = permanentlyNotSupport('getBatteryInfoSync');
|
|
7
|
+
const getBatteryInfoSync = /* @__PURE__ */ permanentlyNotSupport('getBatteryInfoSync');
|
|
8
8
|
const getBatteryInfo = ({ success, fail, complete } = {}) => __awaiter(void 0, void 0, void 0, function* () {
|
|
9
9
|
var _a;
|
|
10
10
|
const handle = new MethodHandler({ name: 'getBatteryInfo', success, fail, complete });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"battery.js","sources":["../../../src/api/device/battery.ts"],"sourcesContent":["import Taro from '@tarojs/api'\n\nimport { permanentlyNotSupport } from '../../utils'\nimport { MethodHandler } from '../../utils/handler'\n\n// 电量\n\n// Note: 浏览器标准下不支持,其他实现方案不准确,不建议开发者使用\nexport const getBatteryInfoSync = permanentlyNotSupport('getBatteryInfoSync')\n\nexport const getBatteryInfo: typeof Taro.getBatteryInfo = async ({ success, fail, complete } = {}) => {\n const handle = new MethodHandler({ name: 'getBatteryInfo', success, fail, complete })\n try {\n // @ts-ignore\n const battery = await navigator.getBattery?.()\n return handle.success({\n isCharging: battery.charging,\n level: Number(battery.level || 0) * 100\n })\n } catch (error) {\n return handle.fail({\n errMsg: error?.message || error\n })\n }\n}\n"],"names":[],"mappings":";;;;AAKA;AAEA;
|
|
1
|
+
{"version":3,"file":"battery.js","sources":["../../../src/api/device/battery.ts"],"sourcesContent":["import Taro from '@tarojs/api'\n\nimport { permanentlyNotSupport } from '../../utils'\nimport { MethodHandler } from '../../utils/handler'\n\n// 电量\n\n// Note: 浏览器标准下不支持,其他实现方案不准确,不建议开发者使用\nexport const getBatteryInfoSync = /* @__PURE__ */ permanentlyNotSupport('getBatteryInfoSync')\n\nexport const getBatteryInfo: typeof Taro.getBatteryInfo = async ({ success, fail, complete } = {}) => {\n const handle = new MethodHandler({ name: 'getBatteryInfo', success, fail, complete })\n try {\n // @ts-ignore\n const battery = await navigator.getBattery?.()\n return handle.success({\n isCharging: battery.charging,\n level: Number(battery.level || 0) * 100\n })\n } catch (error) {\n return handle.fail({\n errMsg: error?.message || error\n })\n }\n}\n"],"names":[],"mappings":";;;;AAKA;AAEA;AACa,MAAA,kBAAkB,mBAAmB,qBAAqB,CAAC,oBAAoB,EAAC;AAEtF,MAAM,cAAc,GAA+B,CAAO,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,GAAG,EAAE,KAAI,SAAA,CAAA,KAAA,CAAA,EAAA,KAAA,CAAA,EAAA,KAAA,CAAA,EAAA,aAAA;;AACnG,IAAA,MAAM,MAAM,GAAG,IAAI,aAAa,CAAC,EAAE,IAAI,EAAE,gBAAgB,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAA;IACrF,IAAI;;QAEF,MAAM,OAAO,GAAG,OAAM,CAAA,EAAA,GAAA,SAAS,CAAC,UAAU,MAAI,IAAA,IAAA,EAAA,KAAA,KAAA,CAAA,GAAA,KAAA,CAAA,GAAA,EAAA,CAAA,IAAA,CAAA,SAAA,CAAA,CAAA,CAAA;QAC9C,OAAO,MAAM,CAAC,OAAO,CAAC;YACpB,UAAU,EAAE,OAAO,CAAC,QAAQ;YAC5B,KAAK,EAAE,MAAM,CAAC,OAAO,CAAC,KAAK,IAAI,CAAC,CAAC,GAAG,GAAG;AACxC,SAAA,CAAC,CAAA;AACH,KAAA;AAAC,IAAA,OAAO,KAAK,EAAE;QACd,OAAO,MAAM,CAAC,IAAI,CAAC;YACjB,MAAM,EAAE,CAAA,KAAK,KAAL,IAAA,IAAA,KAAK,uBAAL,KAAK,CAAE,OAAO,KAAI,KAAK;AAChC,SAAA,CAAC,CAAA;AACH,KAAA;AACH,CAAC;;;;"}
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
3
|
// 蓝牙-低功耗中心设备
|
|
4
|
-
const writeBLECharacteristicValue = temporarilyNotSupport('writeBLECharacteristicValue');
|
|
5
|
-
const setBLEMTU = temporarilyNotSupport('setBLEMTU');
|
|
6
|
-
const readBLECharacteristicValue = temporarilyNotSupport('readBLECharacteristicValue');
|
|
7
|
-
const onBLEMTUChange = temporarilyNotSupport('onBLEMTUChange');
|
|
8
|
-
const onBLEConnectionStateChange = temporarilyNotSupport('onBLEConnectionStateChange');
|
|
9
|
-
const onBLECharacteristicValueChange = temporarilyNotSupport('onBLECharacteristicValueChange');
|
|
10
|
-
const offBLEMTUChange = temporarilyNotSupport('offBLEMTUChange');
|
|
11
|
-
const offBLEConnectionStateChange = temporarilyNotSupport('offBLEConnectionStateChange');
|
|
12
|
-
const offBLECharacteristicValueChange = temporarilyNotSupport('offBLECharacteristicValueChange');
|
|
13
|
-
const notifyBLECharacteristicValueChange = temporarilyNotSupport('notifyBLECharacteristicValueChange');
|
|
14
|
-
const getBLEMTU = temporarilyNotSupport('getBLEMTU');
|
|
15
|
-
const getBLEDeviceServices = temporarilyNotSupport('getBLEDeviceServices');
|
|
16
|
-
const getBLEDeviceRSSI = temporarilyNotSupport('getBLEDeviceRSSI');
|
|
17
|
-
const getBLEDeviceCharacteristics = temporarilyNotSupport('getBLEDeviceCharacteristics');
|
|
18
|
-
const createBLEConnection = temporarilyNotSupport('createBLEConnection');
|
|
19
|
-
const closeBLEConnection = temporarilyNotSupport('closeBLEConnection');
|
|
4
|
+
const writeBLECharacteristicValue = /* @__PURE__ */ temporarilyNotSupport('writeBLECharacteristicValue');
|
|
5
|
+
const setBLEMTU = /* @__PURE__ */ temporarilyNotSupport('setBLEMTU');
|
|
6
|
+
const readBLECharacteristicValue = /* @__PURE__ */ temporarilyNotSupport('readBLECharacteristicValue');
|
|
7
|
+
const onBLEMTUChange = /* @__PURE__ */ temporarilyNotSupport('onBLEMTUChange');
|
|
8
|
+
const onBLEConnectionStateChange = /* @__PURE__ */ temporarilyNotSupport('onBLEConnectionStateChange');
|
|
9
|
+
const onBLECharacteristicValueChange = /* @__PURE__ */ temporarilyNotSupport('onBLECharacteristicValueChange');
|
|
10
|
+
const offBLEMTUChange = /* @__PURE__ */ temporarilyNotSupport('offBLEMTUChange');
|
|
11
|
+
const offBLEConnectionStateChange = /* @__PURE__ */ temporarilyNotSupport('offBLEConnectionStateChange');
|
|
12
|
+
const offBLECharacteristicValueChange = /* @__PURE__ */ temporarilyNotSupport('offBLECharacteristicValueChange');
|
|
13
|
+
const notifyBLECharacteristicValueChange = /* @__PURE__ */ temporarilyNotSupport('notifyBLECharacteristicValueChange');
|
|
14
|
+
const getBLEMTU = /* @__PURE__ */ temporarilyNotSupport('getBLEMTU');
|
|
15
|
+
const getBLEDeviceServices = /* @__PURE__ */ temporarilyNotSupport('getBLEDeviceServices');
|
|
16
|
+
const getBLEDeviceRSSI = /* @__PURE__ */ temporarilyNotSupport('getBLEDeviceRSSI');
|
|
17
|
+
const getBLEDeviceCharacteristics = /* @__PURE__ */ temporarilyNotSupport('getBLEDeviceCharacteristics');
|
|
18
|
+
const createBLEConnection = /* @__PURE__ */ temporarilyNotSupport('createBLEConnection');
|
|
19
|
+
const closeBLEConnection = /* @__PURE__ */ temporarilyNotSupport('closeBLEConnection');
|
|
20
20
|
|
|
21
21
|
export { closeBLEConnection, createBLEConnection, getBLEDeviceCharacteristics, getBLEDeviceRSSI, getBLEDeviceServices, getBLEMTU, notifyBLECharacteristicValueChange, offBLECharacteristicValueChange, offBLEConnectionStateChange, offBLEMTUChange, onBLECharacteristicValueChange, onBLEConnectionStateChange, onBLEMTUChange, readBLECharacteristicValue, setBLEMTU, writeBLECharacteristicValue };
|
|
22
22
|
//# sourceMappingURL=bluetooth-ble.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bluetooth-ble.js","sources":["../../../src/api/device/bluetooth-ble.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 蓝牙-低功耗中心设备\nexport const writeBLECharacteristicValue = temporarilyNotSupport('writeBLECharacteristicValue')\nexport const setBLEMTU = temporarilyNotSupport('setBLEMTU')\nexport const readBLECharacteristicValue = temporarilyNotSupport('readBLECharacteristicValue')\nexport const onBLEMTUChange = temporarilyNotSupport('onBLEMTUChange')\nexport const onBLEConnectionStateChange = temporarilyNotSupport('onBLEConnectionStateChange')\nexport const onBLECharacteristicValueChange = temporarilyNotSupport('onBLECharacteristicValueChange')\nexport const offBLEMTUChange = temporarilyNotSupport('offBLEMTUChange')\nexport const offBLEConnectionStateChange = temporarilyNotSupport('offBLEConnectionStateChange')\nexport const offBLECharacteristicValueChange = temporarilyNotSupport('offBLECharacteristicValueChange')\nexport const notifyBLECharacteristicValueChange = temporarilyNotSupport('notifyBLECharacteristicValueChange')\nexport const getBLEMTU = temporarilyNotSupport('getBLEMTU')\nexport const getBLEDeviceServices = temporarilyNotSupport('getBLEDeviceServices')\nexport const getBLEDeviceRSSI = temporarilyNotSupport('getBLEDeviceRSSI')\nexport const getBLEDeviceCharacteristics = temporarilyNotSupport('getBLEDeviceCharacteristics')\nexport const createBLEConnection = temporarilyNotSupport('createBLEConnection')\nexport const closeBLEConnection = temporarilyNotSupport('closeBLEConnection')\n"],"names":[],"mappings":";;AAEA;
|
|
1
|
+
{"version":3,"file":"bluetooth-ble.js","sources":["../../../src/api/device/bluetooth-ble.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 蓝牙-低功耗中心设备\nexport const writeBLECharacteristicValue = /* @__PURE__ */ temporarilyNotSupport('writeBLECharacteristicValue')\nexport const setBLEMTU = /* @__PURE__ */ temporarilyNotSupport('setBLEMTU')\nexport const readBLECharacteristicValue = /* @__PURE__ */ temporarilyNotSupport('readBLECharacteristicValue')\nexport const onBLEMTUChange = /* @__PURE__ */ temporarilyNotSupport('onBLEMTUChange')\nexport const onBLEConnectionStateChange = /* @__PURE__ */ temporarilyNotSupport('onBLEConnectionStateChange')\nexport const onBLECharacteristicValueChange = /* @__PURE__ */ temporarilyNotSupport('onBLECharacteristicValueChange')\nexport const offBLEMTUChange = /* @__PURE__ */ temporarilyNotSupport('offBLEMTUChange')\nexport const offBLEConnectionStateChange = /* @__PURE__ */ temporarilyNotSupport('offBLEConnectionStateChange')\nexport const offBLECharacteristicValueChange = /* @__PURE__ */ temporarilyNotSupport('offBLECharacteristicValueChange')\nexport const notifyBLECharacteristicValueChange = /* @__PURE__ */ temporarilyNotSupport('notifyBLECharacteristicValueChange')\nexport const getBLEMTU = /* @__PURE__ */ temporarilyNotSupport('getBLEMTU')\nexport const getBLEDeviceServices = /* @__PURE__ */ temporarilyNotSupport('getBLEDeviceServices')\nexport const getBLEDeviceRSSI = /* @__PURE__ */ temporarilyNotSupport('getBLEDeviceRSSI')\nexport const getBLEDeviceCharacteristics = /* @__PURE__ */ temporarilyNotSupport('getBLEDeviceCharacteristics')\nexport const createBLEConnection = /* @__PURE__ */ temporarilyNotSupport('createBLEConnection')\nexport const closeBLEConnection = /* @__PURE__ */ temporarilyNotSupport('closeBLEConnection')\n"],"names":[],"mappings":";;AAEA;AACa,MAAA,2BAA2B,mBAAmB,qBAAqB,CAAC,6BAA6B,EAAC;AAClG,MAAA,SAAS,mBAAmB,qBAAqB,CAAC,WAAW,EAAC;AAC9D,MAAA,0BAA0B,mBAAmB,qBAAqB,CAAC,4BAA4B,EAAC;AAChG,MAAA,cAAc,mBAAmB,qBAAqB,CAAC,gBAAgB,EAAC;AACxE,MAAA,0BAA0B,mBAAmB,qBAAqB,CAAC,4BAA4B,EAAC;AAChG,MAAA,8BAA8B,mBAAmB,qBAAqB,CAAC,gCAAgC,EAAC;AACxG,MAAA,eAAe,mBAAmB,qBAAqB,CAAC,iBAAiB,EAAC;AAC1E,MAAA,2BAA2B,mBAAmB,qBAAqB,CAAC,6BAA6B,EAAC;AAClG,MAAA,+BAA+B,mBAAmB,qBAAqB,CAAC,iCAAiC,EAAC;AAC1G,MAAA,kCAAkC,mBAAmB,qBAAqB,CAAC,oCAAoC,EAAC;AAChH,MAAA,SAAS,mBAAmB,qBAAqB,CAAC,WAAW,EAAC;AAC9D,MAAA,oBAAoB,mBAAmB,qBAAqB,CAAC,sBAAsB,EAAC;AACpF,MAAA,gBAAgB,mBAAmB,qBAAqB,CAAC,kBAAkB,EAAC;AAC5E,MAAA,2BAA2B,mBAAmB,qBAAqB,CAAC,6BAA6B,EAAC;AAClG,MAAA,mBAAmB,mBAAmB,qBAAqB,CAAC,qBAAqB,EAAC;AAClF,MAAA,kBAAkB,mBAAmB,qBAAqB,CAAC,oBAAoB;;;;"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
3
|
// 蓝牙-低功耗外围设备
|
|
4
|
-
const onBLEPeripheralConnectionStateChanged = temporarilyNotSupport('onBLEPeripheralConnectionStateChanged');
|
|
5
|
-
const offBLEPeripheralConnectionStateChanged = temporarilyNotSupport('offBLEPeripheralConnectionStateChanged');
|
|
6
|
-
const createBLEPeripheralServer = temporarilyNotSupport('createBLEPeripheralServer');
|
|
4
|
+
const onBLEPeripheralConnectionStateChanged = /* @__PURE__ */ temporarilyNotSupport('onBLEPeripheralConnectionStateChanged');
|
|
5
|
+
const offBLEPeripheralConnectionStateChanged = /* @__PURE__ */ temporarilyNotSupport('offBLEPeripheralConnectionStateChanged');
|
|
6
|
+
const createBLEPeripheralServer = /* @__PURE__ */ temporarilyNotSupport('createBLEPeripheralServer');
|
|
7
7
|
|
|
8
8
|
export { createBLEPeripheralServer, offBLEPeripheralConnectionStateChanged, onBLEPeripheralConnectionStateChanged };
|
|
9
9
|
//# sourceMappingURL=bluetooth-peripheral.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bluetooth-peripheral.js","sources":["../../../src/api/device/bluetooth-peripheral.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 蓝牙-低功耗外围设备\nexport const onBLEPeripheralConnectionStateChanged = temporarilyNotSupport('onBLEPeripheralConnectionStateChanged')\nexport const offBLEPeripheralConnectionStateChanged = temporarilyNotSupport('offBLEPeripheralConnectionStateChanged')\nexport const createBLEPeripheralServer = temporarilyNotSupport('createBLEPeripheralServer')\n"],"names":[],"mappings":";;AAEA;
|
|
1
|
+
{"version":3,"file":"bluetooth-peripheral.js","sources":["../../../src/api/device/bluetooth-peripheral.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 蓝牙-低功耗外围设备\nexport const onBLEPeripheralConnectionStateChanged = /* @__PURE__ */ temporarilyNotSupport('onBLEPeripheralConnectionStateChanged')\nexport const offBLEPeripheralConnectionStateChanged = /* @__PURE__ */ temporarilyNotSupport('offBLEPeripheralConnectionStateChanged')\nexport const createBLEPeripheralServer = /* @__PURE__ */ temporarilyNotSupport('createBLEPeripheralServer')\n"],"names":[],"mappings":";;AAEA;AACa,MAAA,qCAAqC,mBAAmB,qBAAqB,CAAC,uCAAuC,EAAC;AACtH,MAAA,sCAAsC,mBAAmB,qBAAqB,CAAC,wCAAwC,EAAC;AACxH,MAAA,yBAAyB,mBAAmB,qBAAqB,CAAC,2BAA2B;;;;"}
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { temporarilyNotSupport } from '../../utils/index.js';
|
|
2
2
|
|
|
3
3
|
// 蓝牙-通用
|
|
4
|
-
const stopBluetoothDevicesDiscovery = temporarilyNotSupport('stopBluetoothDevicesDiscovery');
|
|
5
|
-
const startBluetoothDevicesDiscovery = temporarilyNotSupport('startBluetoothDevicesDiscovery');
|
|
6
|
-
const openBluetoothAdapter = temporarilyNotSupport('openBluetoothAdapter');
|
|
7
|
-
const onBluetoothDeviceFound = temporarilyNotSupport('onBluetoothDeviceFound');
|
|
8
|
-
const onBluetoothAdapterStateChange = temporarilyNotSupport('onBluetoothAdapterStateChange');
|
|
9
|
-
const offBluetoothDeviceFound = temporarilyNotSupport('offBluetoothDeviceFound');
|
|
10
|
-
const offBluetoothAdapterStateChange = temporarilyNotSupport('offBluetoothAdapterStateChange');
|
|
11
|
-
const makeBluetoothPair = temporarilyNotSupport('makeBluetoothPair');
|
|
12
|
-
const isBluetoothDevicePaired = temporarilyNotSupport('isBluetoothDevicePaired');
|
|
13
|
-
const getConnectedBluetoothDevices = temporarilyNotSupport('getConnectedBluetoothDevices');
|
|
14
|
-
const getBluetoothDevices = temporarilyNotSupport('getBluetoothDevices');
|
|
15
|
-
const getBluetoothAdapterState = temporarilyNotSupport('getBluetoothAdapterState');
|
|
16
|
-
const closeBluetoothAdapter = temporarilyNotSupport('closeBluetoothAdapter');
|
|
4
|
+
const stopBluetoothDevicesDiscovery = /* @__PURE__ */ temporarilyNotSupport('stopBluetoothDevicesDiscovery');
|
|
5
|
+
const startBluetoothDevicesDiscovery = /* @__PURE__ */ temporarilyNotSupport('startBluetoothDevicesDiscovery');
|
|
6
|
+
const openBluetoothAdapter = /* @__PURE__ */ temporarilyNotSupport('openBluetoothAdapter');
|
|
7
|
+
const onBluetoothDeviceFound = /* @__PURE__ */ temporarilyNotSupport('onBluetoothDeviceFound');
|
|
8
|
+
const onBluetoothAdapterStateChange = /* @__PURE__ */ temporarilyNotSupport('onBluetoothAdapterStateChange');
|
|
9
|
+
const offBluetoothDeviceFound = /* @__PURE__ */ temporarilyNotSupport('offBluetoothDeviceFound');
|
|
10
|
+
const offBluetoothAdapterStateChange = /* @__PURE__ */ temporarilyNotSupport('offBluetoothAdapterStateChange');
|
|
11
|
+
const makeBluetoothPair = /* @__PURE__ */ temporarilyNotSupport('makeBluetoothPair');
|
|
12
|
+
const isBluetoothDevicePaired = /* @__PURE__ */ temporarilyNotSupport('isBluetoothDevicePaired');
|
|
13
|
+
const getConnectedBluetoothDevices = /* @__PURE__ */ temporarilyNotSupport('getConnectedBluetoothDevices');
|
|
14
|
+
const getBluetoothDevices = /* @__PURE__ */ temporarilyNotSupport('getBluetoothDevices');
|
|
15
|
+
const getBluetoothAdapterState = /* @__PURE__ */ temporarilyNotSupport('getBluetoothAdapterState');
|
|
16
|
+
const closeBluetoothAdapter = /* @__PURE__ */ temporarilyNotSupport('closeBluetoothAdapter');
|
|
17
17
|
|
|
18
18
|
export { closeBluetoothAdapter, getBluetoothAdapterState, getBluetoothDevices, getConnectedBluetoothDevices, isBluetoothDevicePaired, makeBluetoothPair, offBluetoothAdapterStateChange, offBluetoothDeviceFound, onBluetoothAdapterStateChange, onBluetoothDeviceFound, openBluetoothAdapter, startBluetoothDevicesDiscovery, stopBluetoothDevicesDiscovery };
|
|
19
19
|
//# sourceMappingURL=bluetooth.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bluetooth.js","sources":["../../../src/api/device/bluetooth.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 蓝牙-通用\nexport const stopBluetoothDevicesDiscovery = temporarilyNotSupport('stopBluetoothDevicesDiscovery')\nexport const startBluetoothDevicesDiscovery = temporarilyNotSupport('startBluetoothDevicesDiscovery')\nexport const openBluetoothAdapter = temporarilyNotSupport('openBluetoothAdapter')\nexport const onBluetoothDeviceFound = temporarilyNotSupport('onBluetoothDeviceFound')\nexport const onBluetoothAdapterStateChange = temporarilyNotSupport('onBluetoothAdapterStateChange')\nexport const offBluetoothDeviceFound = temporarilyNotSupport('offBluetoothDeviceFound')\nexport const offBluetoothAdapterStateChange = temporarilyNotSupport('offBluetoothAdapterStateChange')\nexport const makeBluetoothPair = temporarilyNotSupport('makeBluetoothPair')\nexport const isBluetoothDevicePaired = temporarilyNotSupport('isBluetoothDevicePaired')\nexport const getConnectedBluetoothDevices = temporarilyNotSupport('getConnectedBluetoothDevices')\nexport const getBluetoothDevices = temporarilyNotSupport('getBluetoothDevices')\nexport const getBluetoothAdapterState = temporarilyNotSupport('getBluetoothAdapterState')\nexport const closeBluetoothAdapter = temporarilyNotSupport('closeBluetoothAdapter')\n"],"names":[],"mappings":";;AAEA;
|
|
1
|
+
{"version":3,"file":"bluetooth.js","sources":["../../../src/api/device/bluetooth.ts"],"sourcesContent":["import { temporarilyNotSupport } from '../../utils'\n\n// 蓝牙-通用\nexport const stopBluetoothDevicesDiscovery = /* @__PURE__ */ temporarilyNotSupport('stopBluetoothDevicesDiscovery')\nexport const startBluetoothDevicesDiscovery = /* @__PURE__ */ temporarilyNotSupport('startBluetoothDevicesDiscovery')\nexport const openBluetoothAdapter = /* @__PURE__ */ temporarilyNotSupport('openBluetoothAdapter')\nexport const onBluetoothDeviceFound = /* @__PURE__ */ temporarilyNotSupport('onBluetoothDeviceFound')\nexport const onBluetoothAdapterStateChange = /* @__PURE__ */ temporarilyNotSupport('onBluetoothAdapterStateChange')\nexport const offBluetoothDeviceFound = /* @__PURE__ */ temporarilyNotSupport('offBluetoothDeviceFound')\nexport const offBluetoothAdapterStateChange = /* @__PURE__ */ temporarilyNotSupport('offBluetoothAdapterStateChange')\nexport const makeBluetoothPair = /* @__PURE__ */ temporarilyNotSupport('makeBluetoothPair')\nexport const isBluetoothDevicePaired = /* @__PURE__ */ temporarilyNotSupport('isBluetoothDevicePaired')\nexport const getConnectedBluetoothDevices = /* @__PURE__ */ temporarilyNotSupport('getConnectedBluetoothDevices')\nexport const getBluetoothDevices = /* @__PURE__ */ temporarilyNotSupport('getBluetoothDevices')\nexport const getBluetoothAdapterState = /* @__PURE__ */ temporarilyNotSupport('getBluetoothAdapterState')\nexport const closeBluetoothAdapter = /* @__PURE__ */ temporarilyNotSupport('closeBluetoothAdapter')\n"],"names":[],"mappings":";;AAEA;AACa,MAAA,6BAA6B,mBAAmB,qBAAqB,CAAC,+BAA+B,EAAC;AACtG,MAAA,8BAA8B,mBAAmB,qBAAqB,CAAC,gCAAgC,EAAC;AACxG,MAAA,oBAAoB,mBAAmB,qBAAqB,CAAC,sBAAsB,EAAC;AACpF,MAAA,sBAAsB,mBAAmB,qBAAqB,CAAC,wBAAwB,EAAC;AACxF,MAAA,6BAA6B,mBAAmB,qBAAqB,CAAC,+BAA+B,EAAC;AACtG,MAAA,uBAAuB,mBAAmB,qBAAqB,CAAC,yBAAyB,EAAC;AAC1F,MAAA,8BAA8B,mBAAmB,qBAAqB,CAAC,gCAAgC,EAAC;AACxG,MAAA,iBAAiB,mBAAmB,qBAAqB,CAAC,mBAAmB,EAAC;AAC9E,MAAA,uBAAuB,mBAAmB,qBAAqB,CAAC,yBAAyB,EAAC;AAC1F,MAAA,4BAA4B,mBAAmB,qBAAqB,CAAC,8BAA8B,EAAC;AACpG,MAAA,mBAAmB,mBAAmB,qBAAqB,CAAC,qBAAqB,EAAC;AAClF,MAAA,wBAAwB,mBAAmB,qBAAqB,CAAC,0BAA0B,EAAC;AAC5F,MAAA,qBAAqB,mBAAmB,qBAAqB,CAAC,uBAAuB;;;;"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
declare const
|
|
1
|
+
import Taro from '@tarojs/api';
|
|
2
|
+
declare const addPhoneRepeatCalendar: typeof Taro.addPhoneRepeatCalendar;
|
|
3
|
+
declare const addPhoneCalendar: typeof Taro.addPhoneCalendar;
|
|
3
4
|
export { addPhoneRepeatCalendar, addPhoneCalendar };
|