@blocklet/ui-react 2.13.2 → 2.13.4
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.
|
@@ -137,9 +137,11 @@ export default function UserMetadataComponent({
|
|
|
137
137
|
};
|
|
138
138
|
}
|
|
139
139
|
if (phone && typeof phone === "object") {
|
|
140
|
+
const { country: phoneCountry = "", phoneNumber = "" } = phone;
|
|
141
|
+
const detectedCountry = !phoneCountry ? detectCountryFromPhone(phoneNumber) || "" : phoneCountry;
|
|
140
142
|
return {
|
|
141
|
-
country:
|
|
142
|
-
phone:
|
|
143
|
+
country: detectedCountry,
|
|
144
|
+
phone: phoneNumber || ""
|
|
143
145
|
};
|
|
144
146
|
}
|
|
145
147
|
return {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@blocklet/ui-react",
|
|
3
|
-
"version": "2.13.
|
|
3
|
+
"version": "2.13.4",
|
|
4
4
|
"description": "Some useful front-end web components that can be used in Blocklets.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react",
|
|
@@ -34,11 +34,11 @@
|
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"@abtnode/constant": "^1.16.42",
|
|
36
36
|
"@abtnode/util": "^1.16.42",
|
|
37
|
-
"@arcblock/bridge": "^2.13.
|
|
38
|
-
"@arcblock/react-hooks": "^2.13.
|
|
39
|
-
"@arcblock/ws": "^1.20.
|
|
37
|
+
"@arcblock/bridge": "^2.13.4",
|
|
38
|
+
"@arcblock/react-hooks": "^2.13.4",
|
|
39
|
+
"@arcblock/ws": "^1.20.1",
|
|
40
40
|
"@blocklet/constant": "^1.16.42",
|
|
41
|
-
"@blocklet/did-space-react": "^1.0.
|
|
41
|
+
"@blocklet/did-space-react": "^1.0.48",
|
|
42
42
|
"@iconify-icons/logos": "^1.2.36",
|
|
43
43
|
"@iconify-icons/material-symbols": "^1.2.58",
|
|
44
44
|
"@iconify-icons/tabler": "^1.2.95",
|
|
@@ -94,5 +94,5 @@
|
|
|
94
94
|
"jest": "^29.7.0",
|
|
95
95
|
"unbuild": "^2.0.0"
|
|
96
96
|
},
|
|
97
|
-
"gitHead": "
|
|
97
|
+
"gitHead": "c41220412330b6bc0cd20482261c501beb7ddd34"
|
|
98
98
|
}
|
|
@@ -175,9 +175,12 @@ export default function UserMetadataComponent({
|
|
|
175
175
|
};
|
|
176
176
|
}
|
|
177
177
|
if (phone && typeof phone === 'object') {
|
|
178
|
+
const { country: phoneCountry = '', phoneNumber = '' } = phone as UserPhoneProps;
|
|
179
|
+
const detectedCountry = !phoneCountry ? detectCountryFromPhone(phoneNumber) || '' : phoneCountry;
|
|
180
|
+
|
|
178
181
|
return {
|
|
179
|
-
country:
|
|
180
|
-
phone:
|
|
182
|
+
country: detectedCountry,
|
|
183
|
+
phone: phoneNumber || '',
|
|
181
184
|
};
|
|
182
185
|
}
|
|
183
186
|
|