@blocklet/ui-react 2.13.59 → 2.13.61

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.
@@ -20,6 +20,7 @@ function Action({
20
20
  session,
21
21
  spaceDid: session.user?.didSpace?.did,
22
22
  spaceGatewayUrl: session.user?.didSpace?.url,
23
+ connectScope: "user",
23
24
  onSuccess: async () => {
24
25
  await refresh();
25
26
  },
@@ -13,7 +13,7 @@ function Connected({ spaceGateway }) {
13
13
  return /* @__PURE__ */ jsxs(Box, { display: "flex", flexDirection: "column", children: [
14
14
  /* @__PURE__ */ jsxs(Box, { display: "flex", flexDirection: "row", alignItems: "center", justifyContent: "space-between", marginBottom: "12px", children: [
15
15
  /* @__PURE__ */ jsx(Typography, { fontSize: "16px", fontWeight: "bold", children: t("storage.spaces.connected.title") }),
16
- !isMobile && /* @__PURE__ */ jsx(DIDSpaceConnect, { session, onSuccess })
16
+ !isMobile && /* @__PURE__ */ jsx(DIDSpaceConnect, { connectScope: "user", session, onSuccess })
17
17
  ] }),
18
18
  /* @__PURE__ */ jsx(Box, { children: spaceGateway && /* @__PURE__ */ jsx(
19
19
  DIDSpaceConnection,
@@ -26,7 +26,7 @@ function Connected({ spaceGateway }) {
26
26
  },
27
27
  spaceGateway.endpoint
28
28
  ) }),
29
- isMobile && /* @__PURE__ */ jsx(Box, { sx: { display: "flex", alignItems: "center", justifyContent: "center", marginTop: 2 }, children: /* @__PURE__ */ jsx(DIDSpaceConnect, { session, onSuccess }) })
29
+ isMobile && /* @__PURE__ */ jsx(Box, { sx: { display: "flex", alignItems: "center", justifyContent: "center", marginTop: 2 }, children: /* @__PURE__ */ jsx(DIDSpaceConnect, { connectScope: "user", session, onSuccess }) })
30
30
  ] });
31
31
  }
32
32
  export default Connected;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blocklet/ui-react",
3
- "version": "2.13.59",
3
+ "version": "2.13.61",
4
4
  "description": "Some useful front-end web components that can be used in Blocklets.",
5
5
  "keywords": [
6
6
  "react",
@@ -34,8 +34,8 @@
34
34
  "dependencies": {
35
35
  "@abtnode/constant": "^1.16.43",
36
36
  "@abtnode/util": "^1.16.43",
37
- "@arcblock/bridge": "^2.13.59",
38
- "@arcblock/react-hooks": "^2.13.59",
37
+ "@arcblock/bridge": "^2.13.61",
38
+ "@arcblock/react-hooks": "^2.13.61",
39
39
  "@arcblock/ws": "^1.20.11",
40
40
  "@blocklet/constant": "^1.16.43",
41
41
  "@blocklet/did-space-react": "^1.0.56",
@@ -94,5 +94,5 @@
94
94
  "jest": "^29.7.0",
95
95
  "unbuild": "^2.0.0"
96
96
  },
97
- "gitHead": "e00efa251020006bdc76353ef6c64212529ebddd"
97
+ "gitHead": "af211a24eb0d7f0b24a3e15b8d7acff49edd7494"
98
98
  }
@@ -28,6 +28,8 @@ function Action({
28
28
  session={session}
29
29
  spaceDid={session.user?.didSpace?.did}
30
30
  spaceGatewayUrl={session.user?.didSpace?.url}
31
+ // @ts-expect-error 待 did-space-react 发版后,移除 connectScope 的类型忽略
32
+ connectScope="user"
31
33
  onSuccess={async () => {
32
34
  await refresh();
33
35
  }}
@@ -19,7 +19,8 @@ function Connected({ spaceGateway }: { spaceGateway: SpaceGateway | undefined })
19
19
  <Typography fontSize="16px" fontWeight="bold">
20
20
  {t('storage.spaces.connected.title')}
21
21
  </Typography>
22
- {!isMobile && <DIDSpaceConnect session={session} onSuccess={onSuccess} />}
22
+ {/* @ts-expect-error did-space-react 发版后,移除 connectScope 的类型忽略 */}
23
+ {!isMobile && <DIDSpaceConnect connectScope="user" session={session} onSuccess={onSuccess} />}
23
24
  </Box>
24
25
  <Box>
25
26
  {spaceGateway && (
@@ -36,7 +37,8 @@ function Connected({ spaceGateway }: { spaceGateway: SpaceGateway | undefined })
36
37
  </Box>
37
38
  {isMobile && (
38
39
  <Box sx={{ display: 'flex', alignItems: 'center', justifyContent: 'center', marginTop: 2 }}>
39
- <DIDSpaceConnect session={session} onSuccess={onSuccess} />
40
+ {/* @ts-expect-error 待 did-space-react 发版后,移除 connectScope 的类型忽略 */}
41
+ <DIDSpaceConnect connectScope="user" session={session} onSuccess={onSuccess} />
40
42
  </Box>
41
43
  )}
42
44
  </Box>