@abtnode/ux 1.8.30 → 1.8.32
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/lib/blocklet/util.js +8 -2
- package/lib/locales/en.js +2 -0
- package/lib/locales/zh.js +2 -0
- package/lib/team/passports/trusted-issuer.js +2 -2
- package/package.json +12 -12
package/lib/blocklet/util.js
CHANGED
|
@@ -7,6 +7,7 @@ exports.downloadExportedSource = downloadExportedSource;
|
|
|
7
7
|
exports.genExportedMeta = genExportedMeta;
|
|
8
8
|
exports.getLaunchURL = exports.getLaunchAgreementUrl = void 0;
|
|
9
9
|
exports.getNameByTitle = getNameByTitle;
|
|
10
|
+
exports.getServerUrl = void 0;
|
|
10
11
|
var _cloneDeep = _interopRequireDefault(require("lodash/cloneDeep"));
|
|
11
12
|
var _pickBy = _interopRequireDefault(require("lodash/pickBy"));
|
|
12
13
|
var _jszip = _interopRequireDefault(require("jszip"));
|
|
@@ -95,10 +96,15 @@ async function downloadExportedSource(meta) {
|
|
|
95
96
|
});
|
|
96
97
|
});
|
|
97
98
|
}
|
|
99
|
+
const getServerUrl = function getServerUrl(info) {
|
|
100
|
+
let encodeURI = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
101
|
+
const adminPath = process.env.NODE_ENV === 'production' ? info.routing.adminPath : '';
|
|
102
|
+
return encodeURI ? encodeURIComponent((0, _urlJoin.default)(window.location.origin, adminPath)) : (0, _urlJoin.default)(window.location.origin, adminPath);
|
|
103
|
+
};
|
|
104
|
+
exports.getServerUrl = getServerUrl;
|
|
98
105
|
const getLaunchURL = function getLaunchURL(meta, info) {
|
|
99
106
|
let encodeURI = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
|
|
100
|
-
const
|
|
101
|
-
const serverUrl = encodeURI ? encodeURIComponent((0, _urlJoin.default)(window.location.origin, adminPath)) : (0, _urlJoin.default)(window.location.origin, adminPath);
|
|
107
|
+
const serverUrl = getServerUrl(info, encodeURI);
|
|
102
108
|
const metaUrl = (0, _urlJoin.default)(info === null || info === void 0 ? void 0 : info.blockletRegistry, "/api/blocklets/".concat(meta.did, "/blocklet.json"));
|
|
103
109
|
return {
|
|
104
110
|
serverUrl,
|
package/lib/locales/en.js
CHANGED
|
@@ -265,11 +265,13 @@ module.exports = {
|
|
|
265
265
|
errorMessage: 'Error Message:'
|
|
266
266
|
},
|
|
267
267
|
blocklet: {
|
|
268
|
+
external: 'External',
|
|
268
269
|
notFound: 'Blocklet not found on this server, maybe it has been deleted',
|
|
269
270
|
installFromMarket: 'Install New Blocklets',
|
|
270
271
|
installFromUrl: 'Install From Url',
|
|
271
272
|
installFromCreate: 'Create Blocklet',
|
|
272
273
|
installedAt: 'Installed At',
|
|
274
|
+
internal: 'Internal',
|
|
273
275
|
startedAt: 'Started At',
|
|
274
276
|
stoppedAt: 'Stopped At',
|
|
275
277
|
urlEmptyTip: 'No Access URL, ',
|
package/lib/locales/zh.js
CHANGED
|
@@ -271,11 +271,13 @@ module.exports = {
|
|
|
271
271
|
errorMessage: '错误信息:'
|
|
272
272
|
},
|
|
273
273
|
blocklet: {
|
|
274
|
+
external: '外部',
|
|
274
275
|
notFound: '应用没有找到,可能已经被删除',
|
|
275
276
|
installFromMarket: '从应用商店安装',
|
|
276
277
|
installFromUrl: '通过 URL 安装',
|
|
277
278
|
installFromCreate: '创建基石程序',
|
|
278
279
|
installedAt: '安装时间',
|
|
280
|
+
internal: '内部',
|
|
279
281
|
startedAt: '启动时间',
|
|
280
282
|
stoppedAt: '停止时间',
|
|
281
283
|
urlEmptyTip: '无访问地址,',
|
|
@@ -105,7 +105,7 @@ function TrustedIssuer(_ref) {
|
|
|
105
105
|
onSuccess();
|
|
106
106
|
} catch (err) {
|
|
107
107
|
setLoading(false);
|
|
108
|
-
_toast.default.error(
|
|
108
|
+
_toast.default.error((0, _util.formatError)(err));
|
|
109
109
|
}
|
|
110
110
|
};
|
|
111
111
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Dialog.default, {
|
|
@@ -132,7 +132,7 @@ function TrustedIssuer(_ref) {
|
|
|
132
132
|
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_Button.default, {
|
|
133
133
|
onClick: () => configTrustedPassports(),
|
|
134
134
|
color: "primary",
|
|
135
|
-
disabled: !canSave(issuerDid, mappings) || loading,
|
|
135
|
+
disabled: !canSave(issuerDid, mappings) || !remark || loading,
|
|
136
136
|
variant: "contained",
|
|
137
137
|
autoFocus: true,
|
|
138
138
|
"data-cy": "save-mapping",
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"publishConfig": {
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
|
-
"version": "1.8.
|
|
6
|
+
"version": "1.8.32",
|
|
7
7
|
"description": "UX components shared across abtnode packages",
|
|
8
8
|
"main": "lib/index.js",
|
|
9
9
|
"files": [
|
|
@@ -21,17 +21,17 @@
|
|
|
21
21
|
"author": "linchen <linchen1987@foxmail.com> (http://github.com/linchen1987)",
|
|
22
22
|
"license": "MIT",
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@abtnode/auth": "1.8.
|
|
25
|
-
"@abtnode/constant": "1.8.
|
|
26
|
-
"@abtnode/util": "1.8.
|
|
27
|
-
"@arcblock/did-connect": "^2.4.
|
|
24
|
+
"@abtnode/auth": "1.8.32",
|
|
25
|
+
"@abtnode/constant": "1.8.32",
|
|
26
|
+
"@abtnode/util": "1.8.32",
|
|
27
|
+
"@arcblock/did-connect": "^2.4.47",
|
|
28
28
|
"@arcblock/did-motif": "^1.1.10",
|
|
29
|
-
"@arcblock/icons": "^2.4.
|
|
30
|
-
"@arcblock/terminal": "^2.4.
|
|
31
|
-
"@arcblock/ux": "^2.4.
|
|
32
|
-
"@blocklet/constant": "1.8.
|
|
33
|
-
"@blocklet/launcher-layout": "^1.9.
|
|
34
|
-
"@blocklet/meta": "1.8.
|
|
29
|
+
"@arcblock/icons": "^2.4.47",
|
|
30
|
+
"@arcblock/terminal": "^2.4.47",
|
|
31
|
+
"@arcblock/ux": "^2.4.47",
|
|
32
|
+
"@blocklet/constant": "1.8.32",
|
|
33
|
+
"@blocklet/launcher-layout": "^1.9.7",
|
|
34
|
+
"@blocklet/meta": "1.8.32",
|
|
35
35
|
"@emotion/react": "^11.10.4",
|
|
36
36
|
"@emotion/styled": "^11.10.4",
|
|
37
37
|
"@material-table/core": "^0.2.48",
|
|
@@ -73,5 +73,5 @@
|
|
|
73
73
|
"@babel/preset-react": "^7.18.6",
|
|
74
74
|
"babel-plugin-inline-react-svg": "^1.1.2"
|
|
75
75
|
},
|
|
76
|
-
"gitHead": "
|
|
76
|
+
"gitHead": "8502244aeda5926b3433c1dd9142e63233e3c23c"
|
|
77
77
|
}
|