@blocklet/ui-react 2.10.80 → 2.10.82

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.
@@ -40,7 +40,7 @@ export default function UserSessions({
40
40
  let data = user?.userSessions || [];
41
41
  try {
42
42
  if (!data && session.user) {
43
- data = await client.userSession.getUserSessionsByMyself();
43
+ data = await client.userSession.getMyLoginSessions();
44
44
  }
45
45
  const ipIndexList = data?.map((x, index) => [index, x.lastLoginIp]).filter((x) => !!x[1]);
46
46
  const ipList = ipIndexList?.map((x) => x[1]);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blocklet/ui-react",
3
- "version": "2.10.80",
3
+ "version": "2.10.82",
4
4
  "description": "Some useful front-end web components that can be used in Blocklets.",
5
5
  "keywords": [
6
6
  "react",
@@ -32,8 +32,8 @@
32
32
  "url": "https://github.com/ArcBlock/ux/issues"
33
33
  },
34
34
  "dependencies": {
35
- "@arcblock/bridge": "^2.10.80",
36
- "@arcblock/react-hooks": "^2.10.80",
35
+ "@arcblock/bridge": "^2.10.82",
36
+ "@arcblock/react-hooks": "^2.10.82",
37
37
  "@blocklet/did-space-react": "^0.5.77",
38
38
  "@iconify-icons/logos": "^1.2.36",
39
39
  "@iconify-icons/material-symbols": "^1.2.58",
@@ -80,5 +80,5 @@
80
80
  "jest": "^29.7.0",
81
81
  "unbuild": "^2.0.0"
82
82
  },
83
- "gitHead": "976d92032b34a09e08f77fd94e946ca96c0572ed"
83
+ "gitHead": "25840ab8e0b037d16ef4fa8ead378ff81db95c46"
84
84
  }
@@ -52,7 +52,8 @@ export default function UserSessions({
52
52
  let data = (user?.userSessions || []) as (UserSession & { ipRegion?: string })[];
53
53
  try {
54
54
  if (!data && session.user) {
55
- data = await client.userSession.getUserSessionsByMyself();
55
+ // 依赖新版 js-sdk
56
+ data = await client.userSession.getMyLoginSessions();
56
57
  }
57
58
  // FIXME: @zhanghan 优化获取 IP 信息的处理逻辑
58
59
  const ipIndexList = data?.map((x, index) => [index, x.lastLoginIp] as [number, string]).filter((x) => !!x[1]);