@solar-taro/ui-vant 1.0.3 → 1.1.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.
Files changed (56) hide show
  1. package/CHANGELOG.md +21 -1
  2. package/index10.js +65 -63
  3. package/index103.js +1 -1
  4. package/index104.js +1 -1
  5. package/index105.js +6 -17
  6. package/index106.js +17 -4
  7. package/index107.js +4 -4
  8. package/index108.js +4 -3
  9. package/index109.js +3 -3
  10. package/index110.js +3 -14
  11. package/index111.js +14 -7
  12. package/index112.js +8 -6
  13. package/index113.js +5 -5
  14. package/index114.js +5 -5
  15. package/index115.js +5 -5
  16. package/index116.js +5 -5
  17. package/index117.js +5 -6
  18. package/index121.js +3 -3
  19. package/index122.js +3 -9
  20. package/index123.js +9 -5
  21. package/index124.js +5 -4
  22. package/index125.js +4 -5
  23. package/index126.js +5 -3
  24. package/index17.js +1 -1
  25. package/index18.js +1 -1
  26. package/index19.js +1 -1
  27. package/index20.js +1 -1
  28. package/index21.js +1 -1
  29. package/index22.js +1 -1
  30. package/index24.js +1 -1
  31. package/index26.js +1 -1
  32. package/index40.js +3 -3
  33. package/index52.js +1 -1
  34. package/index62.js +6 -6
  35. package/index67.js +1 -1
  36. package/index69.js +1 -1
  37. package/index71.js +6 -6
  38. package/index73.js +5 -5
  39. package/index79.js +3 -3
  40. package/index8.js +125 -126
  41. package/index80.js +13 -4
  42. package/index81.js +5 -4
  43. package/index82.js +3 -4
  44. package/index83.js +3 -3
  45. package/index84.js +4 -4
  46. package/index85.js +4 -15
  47. package/index86.js +3 -2
  48. package/index87.js +4 -13
  49. package/index88.js +12 -2
  50. package/index89.js +1 -1
  51. package/index97.js +2 -2
  52. package/list/index.vue.d.ts +1 -1
  53. package/opper-controller/index.vue.d.ts +8 -4
  54. package/package.json +2 -1
  55. package/plugin.d.ts +1 -1
  56. package/selector/index.vue.d.ts +3 -1
package/index20.js CHANGED
@@ -1,4 +1,4 @@
1
- import f from "./index8.js";
1
+ import f from "./index5.js";
2
2
  export {
3
3
  f as default
4
4
  };
package/index21.js CHANGED
@@ -1,4 +1,4 @@
1
- import f from "./index7.js";
1
+ import f from "./index8.js";
2
2
  export {
3
3
  f as default
4
4
  };
package/index22.js CHANGED
@@ -1,4 +1,4 @@
1
- import f from "./index9.js";
1
+ import f from "./index7.js";
2
2
  export {
3
3
  f as default
4
4
  };
package/index24.js CHANGED
@@ -1,4 +1,4 @@
1
- import f from "./index11.js";
1
+ import f from "./index9.js";
2
2
  export {
3
3
  f as default
4
4
  };
package/index26.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { ref as i } from "vue";
2
- import { takeUntilDestroyed as s } from "./index117.js";
2
+ import { takeUntilDestroyed as s } from "./index105.js";
3
3
  function a(e, o) {
4
4
  const t = i(o);
5
5
  return (typeof e == "function" ? e() : e).pipe(s()).subscribe((r) => {
package/index40.js CHANGED
@@ -1,6 +1,6 @@
1
- import t from "./index86.js";
2
- import e from "./index87.js";
3
- import o from "./index88.js";
1
+ import t from "./index79.js";
2
+ import e from "./index80.js";
3
+ import o from "./index81.js";
4
4
  var i = "[object Null]", f = "[object Undefined]", r = t ? t.toStringTag : void 0;
5
5
  function m(n) {
6
6
  return n == null ? n === void 0 ? f : i : r && r in Object(n) ? e(n) : o(n);
package/index52.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import a from "./index59.js";
2
- import e from "./index79.js";
2
+ import e from "./index82.js";
3
3
  var s = Object.prototype, n = s.hasOwnProperty;
4
4
  function f(r) {
5
5
  if (!a(r))
package/index62.js CHANGED
@@ -1,9 +1,9 @@
1
- import r from "./index105.js";
2
- import a from "./index106.js";
3
- import p from "./index107.js";
4
- import s from "./index108.js";
5
- import i from "./index109.js";
6
- import m from "./index110.js";
1
+ import r from "./index106.js";
2
+ import a from "./index107.js";
3
+ import p from "./index108.js";
4
+ import s from "./index109.js";
5
+ import i from "./index110.js";
6
+ import m from "./index111.js";
7
7
  function t(o) {
8
8
  var e = this.__data__ = new r(o);
9
9
  this.size = e.size;
package/index67.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import m from "./index56.js";
2
- import r from "./index111.js";
2
+ import r from "./index112.js";
3
3
  function f(o, t) {
4
4
  return m(o, r(o), t);
5
5
  }
package/index69.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import t from "./index102.js";
2
- import o from "./index111.js";
2
+ import o from "./index112.js";
3
3
  import r from "./index50.js";
4
4
  function f(e) {
5
5
  return t(e, r, o);
package/index71.js CHANGED
@@ -1,10 +1,10 @@
1
- import e from "./index80.js";
2
- import a from "./index81.js";
3
- import o from "./index82.js";
4
- import i from "./index83.js";
5
- import n from "./index84.js";
1
+ import e from "./index83.js";
2
+ import a from "./index84.js";
3
+ import o from "./index85.js";
4
+ import i from "./index86.js";
5
+ import n from "./index87.js";
6
6
  import S from "./index40.js";
7
- import t from "./index85.js";
7
+ import t from "./index88.js";
8
8
  var g = "[object Map]", j = "[object Object]", f = "[object Promise]", u = "[object Set]", w = "[object WeakMap]", b = "[object DataView]", T = t(e), C = t(a), M = t(o), d = t(i), v = t(n), r = S;
9
9
  (e && r(new e(new ArrayBuffer(1))) != b || a && r(new a()) != g || o && r(o.resolve()) != f || i && r(new i()) != u || n && r(new n()) != w) && (r = function(m) {
10
10
  var c = S(m), p = c == j ? m.constructor : void 0, s = p ? t(p) : "";
package/index73.js CHANGED
@@ -1,8 +1,8 @@
1
- import o from "./index112.js";
2
- import n from "./index113.js";
3
- import c from "./index114.js";
4
- import g from "./index115.js";
5
- import i from "./index116.js";
1
+ import o from "./index113.js";
2
+ import n from "./index114.js";
3
+ import c from "./index115.js";
4
+ import g from "./index116.js";
5
+ import i from "./index117.js";
6
6
  var s = "[object Boolean]", u = "[object Date]", T = "[object Map]", b = "[object Number]", l = "[object RegExp]", m = "[object Set]", y = "[object String]", f = "[object Symbol]", p = "[object ArrayBuffer]", j = "[object DataView]", A = "[object Float32Array]", w = "[object Float64Array]", d = "[object Int8Array]", B = "[object Int16Array]", x = "[object Int32Array]", C = "[object Uint8Array]", S = "[object Uint8ClampedArray]", U = "[object Uint16Array]", v = "[object Uint32Array]";
7
7
  function R(a, t, r) {
8
8
  var e = a.constructor;
package/index79.js CHANGED
@@ -1,5 +1,5 @@
1
- import e from "./index92.js";
2
- var t = e(Object.keys, Object);
1
+ import o from "./index38.js";
2
+ var m = o.Symbol;
3
3
  export {
4
- t as default
4
+ m as default
5
5
  };
package/index8.js CHANGED
@@ -1,95 +1,95 @@
1
- import { defineComponent as H, ref as E, computed as J, watch as Q, onUnmounted as X, unref as Y, createElementVNode as Z, toDisplayString as ee, vShow as oe, withDirectives as te, normalizeClass as ne, createTextVNode as se, openBlock as ie, createElementBlock as re, renderList as ce, Fragment as le, withCtx as ae, createVNode as ue } from "vue";
2
- import { isOpperDevice as de } from "@opper/core";
3
- import { BluetoothLowEnergeDevice as pe } from "@opper/wx";
4
- import { checkBluetooth as L, bluetoothService as f, vibrator as ve, overlay as r, withLoading as me } from "@solar-taro/core";
5
- import { getSystemInfo as fe, openSetting as we } from "@tarojs/taro";
6
- import { filter as he, switchMap as w, combineLatest as be, of as $, map as I, catchError as B, tap as V, timer as ge, takeUntil as D, finalize as O, from as ye } from "rxjs";
7
- import { useObservable as A } from "./index26.js";
8
- import _e from "./index6.js";
9
- import { dialog as De } from "./index15.js";
10
- import { useDestroyed as z } from "./index27.js";
11
- const c = Y, t = Z, p = ee, ke = oe, Ce = te, j = ne, xe = se, h = ie, b = re, Se = ce, Ne = le, Ee = ae, $e = ue, Ie = { class: "sun-opper-controller" }, Be = ["show"], Oe = { key: 0 }, Te = { class: "sun-opper-controller-device" }, Me = { class: "sun-opper-controller-device-header" }, Pe = { class: "sun-opper-controller-device-name" }, Re = { class: "sun-opper-controller-device-infos" }, Le = { class: "sun-opper-controller-device-info" }, Ve = { class: "color-secondary" }, Ae = { class: "sun-opper-controller-device-info" }, ze = { class: "color-secondary" }, je = { class: "sun-opper-controller-device-info" }, Fe = { class: "color-secondary" }, Ue = { class: "sun-opper-controller-device-info" }, qe = { class: "color-secondary" }, Ke = { class: "van-button-container" }, We = { key: 1 }, Ge = ["title", "label", "onTap"], He = { class: "van-button-container" }, Je = ["show"], ro = /* @__PURE__ */ H({
1
+ import { defineComponent as Q, ref as I, computed as X, watch as Y, onUnmounted as Z, unref as ee, createElementVNode as oe, toDisplayString as te, vShow as ne, withDirectives as se, normalizeClass as ie, createTextVNode as re, Fragment as ce, openBlock as le, createElementBlock as ae, renderList as ue, withCtx as de, createVNode as pe } from "vue";
2
+ import { isOpperDevice as ve } from "@opper/core";
3
+ import { BluetoothLowEnergeDevice as me } from "@opper/wx";
4
+ import { checkBluetooth as A, bluetoothService as w, vibrator as fe, overlay as r, withLoading as we } from "@solar-taro/core";
5
+ import { getSystemInfo as he, openSetting as ge } from "@tarojs/taro";
6
+ import { filter as z, switchMap as m, combineLatest as ye, of as E, map as $, catchError as D, tap as B, timer as be, takeUntil as N, finalize as O, from as _e } from "rxjs";
7
+ import { useObservable as j } from "./index26.js";
8
+ import De from "./index6.js";
9
+ import { dialog as Ce } from "./index15.js";
10
+ import { useDestroyed as F } from "./index27.js";
11
+ const c = ee, t = oe, p = te, Se = ne, ke = se, U = ie, xe = re, T = ce, h = le, g = ae, Ie = ue, Ee = de, $e = pe, Be = { class: "sun-opper-controller" }, Ne = ["show"], Oe = { class: "sun-opper-controller-device" }, Te = { class: "sun-opper-controller-device-header" }, Me = { class: "sun-opper-controller-device-name" }, Pe = { class: "sun-opper-controller-device-infos" }, Re = { class: "sun-opper-controller-device-info" }, Le = { class: "color-secondary" }, Ve = { class: "sun-opper-controller-device-info" }, Ae = { class: "color-secondary" }, ze = { class: "sun-opper-controller-device-info" }, je = { class: "color-secondary" }, Fe = { class: "sun-opper-controller-device-info" }, Ue = { class: "color-secondary" }, qe = { class: "van-button-container" }, Ke = ["title", "label", "onTap"], We = { class: "van-button-container" }, Ge = ["show"], so = /* @__PURE__ */ Q({
12
12
  __name: "index",
13
13
  props: {
14
14
  show: { type: Boolean, default: !1 },
15
- autoconnect: {},
15
+ mac: {},
16
+ deviceId: {},
16
17
  opper: {}
17
18
  },
18
19
  emits: ["update:show", "connect", "disconnect"],
19
- setup(F, { emit: U }) {
20
- const v = F, k = U, i = v.opper, C = z(), x = z(), a = E({}), u = E(!1), T = A(() => i.connected), g = E(!1), M = J(() => Object.values(a.value)), d = A(() => i.connected.pipe(
21
- he(Boolean),
22
- w(() => {
20
+ setup(q, { emit: K }) {
21
+ const v = q, C = K, i = v.opper, M = F(), S = F(), a = I({}), u = I(!1), P = j(() => i.connected), y = I(!1), R = X(() => Object.values(a.value)), d = j(() => i.connected.pipe(
22
+ z(Boolean),
23
+ m(() => {
23
24
  const n = i.device;
24
- return be({
25
- id: $(n.id),
25
+ return ye({
26
+ id: E(n.id),
26
27
  name: n.name,
27
28
  version: n.firmwareRevision,
28
29
  accuracy: i.accuracyChange,
29
30
  volt: i.batteryChange.pipe(
30
- I(([e]) => e)
31
+ $(([e]) => e)
31
32
  ),
32
33
  charging: i.batteryChange.pipe(
33
- I(([, e]) => !!e)
34
+ $(([, e]) => !!e)
34
35
  ),
35
36
  serialNumber: n.serialNumber
36
37
  });
37
38
  })
38
- ), {}), q = [
39
+ ), {}), W = [
39
40
  { id: 1, name: "断开连接" },
40
41
  { id: 2, name: "断开连接并关机", color: "var(--color-danger)" }
41
42
  ];
42
- let S = !1;
43
- function N() {
44
- if (!L()) return;
43
+ let k = !1;
44
+ function x() {
45
+ if (!A()) return;
45
46
  let n = null;
46
- u.value = !0, f.openAdapter().pipe(
47
- B((e) => {
47
+ u.value = !0, w.openAdapter().pipe(
48
+ D((e) => {
48
49
  var o, l;
49
50
  if ((l = (o = e.errMsg) == null ? void 0 : o.includes) != null && l.call(o, "already"))
50
- return $(null);
51
+ return E(null);
51
52
  throw e;
52
53
  }),
53
- w(
54
- () => f.startDevicesDiscovery({
54
+ m(
55
+ () => w.startDevicesDiscovery({
55
56
  allowDuplicatesKey: !0,
56
57
  powerLevel: "high"
57
58
  })
58
59
  ),
59
- V(
60
- () => ge(0, 1250).pipe(
61
- D(x)
62
- ).subscribe(() => ve.short())
60
+ B(
61
+ () => be(0, 1250).pipe(
62
+ N(S)
63
+ ).subscribe(() => fe.short())
63
64
  ),
64
- w(() => f.devicesChange),
65
- I((e) => e.filter((o) => de({
65
+ m(() => w.devicesChange),
66
+ $((e) => e.filter((o) => ve({
66
67
  id: o.deviceId,
67
- localName: o.localName,
68
68
  name: o.name
69
69
  }))),
70
- D(x),
71
- B((e) => {
70
+ N(S),
71
+ D((e) => {
72
72
  var o, l, s;
73
73
  throw e.errno === 103 ? r.modal("温馨提示", "请先授予小程序蓝牙与位置权限").then(() => {
74
- we();
75
- }) : (l = (o = e.errMsg) == null ? void 0 : o.includes) != null && l.call(o, "permission") ? r.tips("请先授予微信蓝牙与位置权限") : (s = e.errMsg) != null && s.includes("frequently") ? r.tips("操作频繁,请稍后再试") : r.tips(e.errMsg), m(), e;
74
+ ge();
75
+ }) : (l = (o = e.errMsg) == null ? void 0 : o.includes) != null && l.call(o, "permission") ? r.tips("请先授予微信蓝牙与位置权限") : (s = e.errMsg) != null && s.includes("frequently") ? r.tips("操作频繁,请稍后再试") : r.tips(e.errMsg), f(), e;
76
76
  }),
77
77
  O(() => {
78
- u.value = !1, a.value = {}, f.stopDevicesDiscovery().subscribe();
78
+ u.value = !1, a.value = {}, w.stopDevicesDiscovery().subscribe();
79
79
  })
80
80
  ).subscribe((e) => {
81
- const o = v.autoconnect;
81
+ const o = v.mac || v.deviceId;
82
82
  if (o) {
83
83
  const s = o.slice(-5).replace(":", ""), _ = e.find(
84
- (R) => R.deviceId === v.autoconnect || // 由于 iOS 的 deviceId 不是 MAC,但是蓝牙名字上有 MAC 后四位,这里通过比对 MAC 来选择设备
85
- R.name.endsWith(s)
84
+ (V) => V.deviceId === o || // 由于 iOS 的 deviceId 不是 MAC,但是蓝牙名字上有 MAC 后四位,这里通过比对 MAC 来选择设备
85
+ V.name.endsWith(s)
86
86
  );
87
87
  if (_)
88
- return y(_.deviceId);
88
+ return b(_.deviceId);
89
89
  }
90
90
  if (e.length === 1) {
91
- if (n != null || (n = Date.now()), Date.now() - n > 3e3)
92
- return y(e[0].deviceId);
91
+ if (n != null || (n = Date.now()), Date.now() - n > 5e3)
92
+ return b(e[0].deviceId);
93
93
  } else e.length > 1 && (n = null);
94
94
  Object.keys(a.value).forEach((s) => {
95
95
  a.value[s].recommended = !1, Date.now() - a.value[s].discoveryTime > 5e3 && delete a.value[s];
@@ -100,173 +100,172 @@ const c = Y, t = Z, p = ee, ke = oe, Ce = te, j = ne, xe = se, h = ie, b = re, S
100
100
  l && (l.recommended = !0);
101
101
  });
102
102
  }
103
- function m() {
104
- x.next();
103
+ function f() {
104
+ S.next();
105
105
  }
106
- function y(n) {
107
- S || (r.loading("正在连接"), S = !0, C.next(), i.connect(new pe(n)).pipe(
108
- D(C),
109
- O(() => S = !1)
110
- ).subscribe({
111
- next: () => {
112
- m();
113
- },
114
- error: (e) => {
115
- e.errCode === 10003 ? r.tips("连接超时,请重试") : (r.tips(`连接失败,原因:${e.errCode}:${e.errMsg}`), console.error("连接失败", e));
116
- }
117
- }), i.device.connectedChange.pipe(
118
- D(C)
119
- ).subscribe((e) => {
120
- e ? (k("connect", n), setTimeout(P, 600)) : k("disconnect", n), e ? r.success("连接成功") : r.error("连接断开");
106
+ function b(n) {
107
+ k || (r.loading("正在连接"), k = !0, M.next(), i.connect(new me(n)).pipe(
108
+ B(() => {
109
+ f(), C("connect", n), r.success("连接成功"), setTimeout(L, 600);
110
+ }),
111
+ D((e) => {
112
+ throw e.errCode === 10003 ? r.tips("连接超时,请重试") : r.tips(`连接失败:${e.errCode}:${e.errMsg}`), e;
113
+ }),
114
+ O(() => k = !1),
115
+ m(() => i.connected.pipe(z((e) => !e))),
116
+ // 监听断开
117
+ N(M)
118
+ ).subscribe(() => {
119
+ C("disconnect", n), r.error("连接断开");
121
120
  }));
122
121
  }
123
- function K() {
124
- L() && (u.value = !0, f.openAdapter().pipe(
122
+ function G(n) {
123
+ A() && (u.value = !0, w.openAdapter().pipe(
125
124
  O(() => {
126
125
  u.value = !1;
127
126
  })
128
127
  ).subscribe(() => {
129
- y(v.autoconnect);
128
+ b(n);
130
129
  }));
131
130
  }
132
- function W() {
131
+ function H() {
133
132
  i.disconnect().pipe(
134
- me("正在断开")
133
+ we("正在断开")
135
134
  ).subscribe();
136
135
  }
137
- function G({ detail: n }) {
136
+ function J({ detail: n }) {
138
137
  switch (n.id) {
139
138
  case 1:
140
- W();
139
+ H();
141
140
  break;
142
141
  case 2:
143
- ye(De.confirm("温馨提示", "您确定要关闭设备电源吗?")).pipe(
144
- V(() => r.loading("正在关机")),
145
- w(() => i.shutdown()),
146
- B(() => $(null)),
142
+ _e(Ce.confirm("温馨提示", "您确定要关闭设备电源吗?")).pipe(
143
+ B(() => r.loading("正在关机")),
144
+ m(() => i.shutdown()),
145
+ D(() => E(null)),
147
146
  // 关机后距离信号丢失还有一段时间,这里主动断开连接,改进用户体验
148
- w(() => i.disconnect())
147
+ m(() => i.disconnect())
149
148
  ).subscribe(() => {
150
149
  r.success("设备已关机");
151
150
  });
152
151
  break;
153
152
  }
154
153
  }
155
- function P() {
156
- k("update:show", !1);
154
+ function L() {
155
+ C("update:show", !1);
157
156
  }
158
- return Q(() => v.show, async (n) => {
157
+ return Y(() => v.show, async (n) => {
159
158
  if (n) {
160
- if (!T.value)
161
- if (v.autoconnect) {
162
- const { platform: e } = await fe();
163
- e === "ios" ? N() : K();
159
+ if (!P.value)
160
+ if (v.mac) {
161
+ const { platform: e } = await he();
162
+ e === "ios" ? x() : G(v.mac);
164
163
  } else
165
- N();
164
+ x();
166
165
  } else
167
- u.value && m();
168
- }), X(() => {
169
- m();
170
- }), (n, e) => (h(), b("view", Ie, [
166
+ u.value && f();
167
+ }), Z(() => {
168
+ f();
169
+ }), (n, e) => (h(), g("view", Be, [
171
170
  t("van-action-sheet", {
172
171
  show: n.show,
173
172
  title: "OPPER",
174
173
  "close-on-click-overlay": !0,
175
- onClose: e[2] || (e[2] = (o) => P())
174
+ onClose: e[2] || (e[2] = (o) => L())
176
175
  }, [
177
- c(T) ? (h(), b("block", Oe, [
178
- t("view", Te, [
179
- t("view", Me, [
176
+ c(P) ? (h(), g(T, { key: 0 }, [
177
+ t("view", Oe, [
178
+ t("view", Te, [
180
179
  e[7] || (e[7] = t("view", { class: "sun-opper-controller-device-title" }, "设备已连接", -1)),
181
- t("view", Pe, [
180
+ t("view", Me, [
182
181
  xe(p(c(d).name || "OPPER") + " ", 1),
183
182
  t("view", {
184
- class: j(c(d).charging ? "color-success" : "color-primary")
183
+ class: U(c(d).charging ? "color-success" : "color-primary")
185
184
  }, [
186
185
  e[6] || (e[6] = t("van-icon", {
187
186
  "class-prefix": "iconfont",
188
187
  name: "lightning"
189
188
  }, null, -1)),
190
- Ce(t("text", null, p(c(d).volt) + "%", 513), [
191
- [ke, c(d).volt]
189
+ ke(t("text", null, p(c(d).volt) + "%", 513), [
190
+ [Se, c(d).volt]
192
191
  ])
193
192
  ], 2)
194
193
  ])
195
194
  ]),
196
- t("view", Re, [
197
- t("view", Le, [
195
+ t("view", Pe, [
196
+ t("view", Re, [
198
197
  e[8] || (e[8] = t("view", { class: "color-gray" }, "设备号", -1)),
199
- t("view", Ve, p(c(d).id), 1)
198
+ t("view", Le, p(c(d).id), 1)
200
199
  ]),
201
- t("view", Ae, [
200
+ t("view", Ve, [
202
201
  e[9] || (e[9] = t("view", { class: "color-gray" }, "秤台精度", -1)),
203
- t("view", ze, p(c(d).accuracy || 1) + "克", 1)
202
+ t("view", Ae, p(c(d).accuracy || 1) + "克", 1)
204
203
  ]),
205
- t("view", je, [
204
+ t("view", ze, [
206
205
  e[10] || (e[10] = t("view", { class: "color-gray" }, "固件版本", -1)),
207
- t("view", Fe, p(c(d).version), 1)
206
+ t("view", je, p(c(d).version), 1)
208
207
  ]),
209
- t("view", Ue, [
208
+ t("view", Fe, [
210
209
  e[11] || (e[11] = t("view", { class: "color-gray" }, "序列号", -1)),
211
- t("view", qe, p(c(d).serialNumber), 1)
210
+ t("view", Ue, p(c(d).serialNumber), 1)
212
211
  ])
213
212
  ])
214
213
  ]),
215
- t("view", Ke, [
214
+ t("view", qe, [
216
215
  t("van-button", {
217
216
  type: "danger",
218
217
  round: "true",
219
218
  block: "true",
220
- onTap: e[0] || (e[0] = (o) => g.value = !0)
219
+ onTap: e[0] || (e[0] = (o) => y.value = !0)
221
220
  }, " 断开连接 ", 32)
222
221
  ])
223
- ])) : (h(), b("block", We, [
224
- $e(c(_e), {
222
+ ], 64)) : (h(), g(T, { key: 1 }, [
223
+ $e(c(De), {
225
224
  class: "sun-opper-controller-device-list",
226
225
  refresher: !1,
227
- data: M.value,
226
+ data: R.value,
228
227
  loading: u.value,
229
228
  "loading-text": "正在扫描",
230
229
  "empty-type": "search",
231
230
  "empty-text": "暂无设备"
232
231
  }, {
233
232
  default: Ee(() => [
234
- (h(!0), b(Ne, null, Se(M.value, (o) => (h(), b("van-cell", {
233
+ (h(!0), g(T, null, Ie(R.value, (o) => (h(), g("van-cell", {
235
234
  key: o.deviceId,
236
- title: o.localName || o.name,
235
+ title: o.name,
237
236
  label: o.deviceId,
238
237
  size: "large",
239
238
  clickable: !0,
240
- onTap: (l) => y(o.deviceId)
239
+ onTap: (l) => b(o.deviceId)
241
240
  }, [
242
241
  t("text", {
243
- class: j({ "color-success": o.recommended })
242
+ class: U({ "color-success": o.recommended })
244
243
  }, p(o.RSSI) + "dBm", 3)
245
- ], 40, Ge))), 128))
244
+ ], 40, Ke))), 128))
246
245
  ]),
247
246
  _: 1
248
247
  }, 8, ["data", "loading"]),
249
- t("view", He, [
248
+ t("view", We, [
250
249
  t("van-button", {
251
250
  type: "primary",
252
251
  round: "true",
253
252
  block: "true",
254
- onTap: e[1] || (e[1] = (o) => u.value ? m() : N())
253
+ onTap: e[1] || (e[1] = (o) => u.value ? f() : x())
255
254
  }, p(u.value ? "停止扫描" : "扫描 OPPER 设备"), 33)
256
255
  ])
257
- ]))
258
- ], 40, Be),
256
+ ], 64))
257
+ ], 40, Ne),
259
258
  t("van-action-sheet", {
260
- show: g.value,
261
- actions: q,
259
+ show: y.value,
260
+ actions: W,
262
261
  "cancel-text": "取消",
263
- onSelect: e[3] || (e[3] = (o) => G(o)),
264
- onCancel: e[4] || (e[4] = (o) => g.value = !1),
265
- onClose: e[5] || (e[5] = (o) => g.value = !1)
266
- }, null, 40, Je)
262
+ onSelect: e[3] || (e[3] = (o) => J(o)),
263
+ onCancel: e[4] || (e[4] = (o) => y.value = !1),
264
+ onClose: e[5] || (e[5] = (o) => y.value = !1)
265
+ }, null, 40, Ge)
267
266
  ]));
268
267
  }
269
268
  });
270
269
  export {
271
- ro as default
270
+ so as default
272
271
  };
package/index80.js CHANGED
@@ -1,6 +1,15 @@
1
- import t from "./index104.js";
2
- import a from "./index38.js";
3
- var e = t(a, "DataView");
1
+ import e from "./index79.js";
2
+ var o = Object.prototype, c = o.hasOwnProperty, f = o.toString, r = e ? e.toStringTag : void 0;
3
+ function p(t) {
4
+ var a = c.call(t, r), n = t[r];
5
+ try {
6
+ t[r] = void 0;
7
+ var i = !0;
8
+ } catch {
9
+ }
10
+ var g = f.call(t);
11
+ return i && (a ? t[r] = n : delete t[r]), g;
12
+ }
4
13
  export {
5
- e as default
14
+ p as default
6
15
  };
package/index81.js CHANGED
@@ -1,6 +1,7 @@
1
- import o from "./index104.js";
2
- import r from "./index38.js";
3
- var p = o(r, "Map");
1
+ var o = Object.prototype, r = o.toString;
2
+ function e(t) {
3
+ return r.call(t);
4
+ }
4
5
  export {
5
- p as default
6
+ e as default
6
7
  };
package/index82.js CHANGED
@@ -1,6 +1,5 @@
1
- import o from "./index104.js";
2
- import r from "./index38.js";
3
- var m = o(r, "Promise");
1
+ import e from "./index92.js";
2
+ var t = e(Object.keys, Object);
4
3
  export {
5
- m as default
4
+ t as default
6
5
  };
package/index83.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import t from "./index104.js";
2
- import o from "./index38.js";
3
- var a = t(o, "Set");
2
+ import a from "./index38.js";
3
+ var e = t(a, "DataView");
4
4
  export {
5
- a as default
5
+ e as default
6
6
  };
package/index84.js CHANGED
@@ -1,6 +1,6 @@
1
- import a from "./index104.js";
2
- import o from "./index38.js";
3
- var e = a(o, "WeakMap");
1
+ import o from "./index104.js";
2
+ import r from "./index38.js";
3
+ var p = o(r, "Map");
4
4
  export {
5
- e as default
5
+ p as default
6
6
  };
package/index85.js CHANGED
@@ -1,17 +1,6 @@
1
- var o = Function.prototype, n = o.toString;
2
- function e(t) {
3
- if (t != null) {
4
- try {
5
- return n.call(t);
6
- } catch {
7
- }
8
- try {
9
- return t + "";
10
- } catch {
11
- }
12
- }
13
- return "";
14
- }
1
+ import o from "./index104.js";
2
+ import r from "./index38.js";
3
+ var m = o(r, "Promise");
15
4
  export {
16
- e as default
5
+ m as default
17
6
  };
package/index86.js CHANGED
@@ -1,5 +1,6 @@
1
+ import t from "./index104.js";
1
2
  import o from "./index38.js";
2
- var m = o.Symbol;
3
+ var a = t(o, "Set");
3
4
  export {
4
- m as default
5
+ a as default
5
6
  };