@abtnode/ux 1.16.6-beta-4562aa60 → 1.16.6-beta-4ea1eb90
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.
|
@@ -30,6 +30,20 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
|
30
30
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
31
31
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
32
32
|
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
33
|
+
const getDescription = (data, t) => {
|
|
34
|
+
let {
|
|
35
|
+
description
|
|
36
|
+
} = data;
|
|
37
|
+
if (Object.values(_constant.CHAIN_PROP_MAP).includes(data.key)) {
|
|
38
|
+
description = "".concat(data.description, " (").concat(t('blocklet.config.sharedToAllComponents'), ")");
|
|
39
|
+
}
|
|
40
|
+
return description && /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
41
|
+
style: {
|
|
42
|
+
marginLeft: 12
|
|
43
|
+
},
|
|
44
|
+
children: description
|
|
45
|
+
});
|
|
46
|
+
};
|
|
33
47
|
function ComponentEnvironment(_ref) {
|
|
34
48
|
let {
|
|
35
49
|
blocklet,
|
|
@@ -141,7 +155,7 @@ function ComponentEnvironment(_ref) {
|
|
|
141
155
|
const sharedConfigObj = (0, _util.getSharedConfigObj)(blocklet, ancestors);
|
|
142
156
|
const missingRequiredConfigs = (0, _util.getComponentMissingConfigs)(blocklet, ancestors);
|
|
143
157
|
const configs = componentConfigs.map(x => _objectSpread(_objectSpread({}, x), {}, {
|
|
144
|
-
value: sharedConfigObj[x.key] || x.value
|
|
158
|
+
value: Object.values(_constant.CHAIN_PROP_MAP).includes(x.key) && Object.keys(sharedConfigObj).includes(x.key) ? sharedConfigObj[x.key] : sharedConfigObj[x.key] || x.value
|
|
145
159
|
}));
|
|
146
160
|
const hasBWAConfig = configs.some(x => x.key && x.key.startsWith('BWA_'));
|
|
147
161
|
const action = {
|
|
@@ -224,12 +238,7 @@ function ComponentEnvironment(_ref) {
|
|
|
224
238
|
placeholder: t('blocklet.config.environment.value'),
|
|
225
239
|
margin: "dense",
|
|
226
240
|
autoFocus: true
|
|
227
|
-
}), rowData
|
|
228
|
-
style: {
|
|
229
|
-
marginLeft: 12
|
|
230
|
-
},
|
|
231
|
-
children: rowData.description
|
|
232
|
-
})]
|
|
241
|
+
}), getDescription(rowData, t)]
|
|
233
242
|
});
|
|
234
243
|
}
|
|
235
244
|
}];
|
|
@@ -74,7 +74,10 @@ const SpaceConnector = /*#__PURE__*/(0, _react.forwardRef)((_ref, ref) => {
|
|
|
74
74
|
} = (0, _react.useContext)(_context.LocaleContext);
|
|
75
75
|
/** @type {{ blocklet: import('@abtnode/client').BlockletState }} */
|
|
76
76
|
const {
|
|
77
|
-
blocklet
|
|
77
|
+
blocklet,
|
|
78
|
+
actions: {
|
|
79
|
+
refreshBlocklet
|
|
80
|
+
}
|
|
78
81
|
} = (0, _blocklet.useBlockletContext)();
|
|
79
82
|
const [gatewayUrl, setGatewayUrl] = (0, _react.useState)('');
|
|
80
83
|
const spaceProps = (0, _react.useMemo)(() => {
|
|
@@ -116,6 +119,7 @@ const SpaceConnector = /*#__PURE__*/(0, _react.forwardRef)((_ref, ref) => {
|
|
|
116
119
|
open: false
|
|
117
120
|
}));
|
|
118
121
|
onConnect === null || onConnect === void 0 ? void 0 : onConnect();
|
|
122
|
+
refreshBlocklet();
|
|
119
123
|
}, 3000);
|
|
120
124
|
};
|
|
121
125
|
const [authorizeConnect, setAuthorizeConnect] = (0, _react.useState)({
|
package/lib/blocklet/storage.js
CHANGED
|
@@ -44,17 +44,14 @@ function useBackupProgress(_ref) {
|
|
|
44
44
|
completed: false
|
|
45
45
|
});
|
|
46
46
|
const node = (0, _node.useNodeContext)();
|
|
47
|
-
const
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
});
|
|
54
|
-
|
|
55
|
-
webSocketClient.off(_constant.BlockletEvents.backupProgress);
|
|
56
|
-
};
|
|
57
|
-
}, [appDid, webSocketClient]);
|
|
47
|
+
const {
|
|
48
|
+
ws: {
|
|
49
|
+
useSubscription
|
|
50
|
+
}
|
|
51
|
+
} = node;
|
|
52
|
+
useSubscription(_constant.BlockletEvents.backupProgress, data => {
|
|
53
|
+
setProgress(preValue => _objectSpread(_objectSpread({}, preValue), data));
|
|
54
|
+
}, [appDid]);
|
|
58
55
|
return progress;
|
|
59
56
|
}
|
|
60
57
|
function Storage() {
|
|
@@ -162,7 +159,7 @@ function Storage() {
|
|
|
162
159
|
},
|
|
163
160
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.LinearProgress, {
|
|
164
161
|
color: "primary",
|
|
165
|
-
variant: "
|
|
162
|
+
variant: "determinate",
|
|
166
163
|
value: progress === null || progress === void 0 ? void 0 : progress.progress
|
|
167
164
|
})
|
|
168
165
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_Box.default, {
|
package/lib/locales/en.js
CHANGED
|
@@ -424,7 +424,8 @@ module.exports = {
|
|
|
424
424
|
appDidChangeTipL2: 'The DID domain name of the application will change, and the original domain name will become invalid',
|
|
425
425
|
appSkChangeTip: 'You are changing application secret key',
|
|
426
426
|
walletTypeTitle: 'Update Wallet Type',
|
|
427
|
-
appSkTitle: 'Update Application Secret Key'
|
|
427
|
+
appSkTitle: 'Update Application Secret Key',
|
|
428
|
+
sharedToAllComponents: 'Will be shared to all components'
|
|
428
429
|
},
|
|
429
430
|
overview: {
|
|
430
431
|
source: 'Source',
|
|
@@ -661,6 +662,7 @@ module.exports = {
|
|
|
661
662
|
dialog: 'Click on "confirm" to install the update. Blocklet Server will enter maintenance mode until the update is completed and return to production mode automatically.',
|
|
662
663
|
confirm: 'Upgrade',
|
|
663
664
|
switchLabel: 'Auto Update Check',
|
|
665
|
+
enableBetaRelease: 'Enable Beta Release',
|
|
664
666
|
setup: 'Preparing the upgrade',
|
|
665
667
|
installing: 'Installing Blocklet Server v{version}',
|
|
666
668
|
restarting: 'Restarting Blocklet Server',
|
package/lib/locales/zh.js
CHANGED
|
@@ -429,7 +429,8 @@ module.exports = {
|
|
|
429
429
|
appDidChangeTipL2: '应用的 DID 域名会发生变化,原域名将会失效',
|
|
430
430
|
appSkChangeTip: '你正在修改应用私钥',
|
|
431
431
|
walletTypeTitle: '修改钱包类型',
|
|
432
|
-
appSkTitle: '修改应用私钥'
|
|
432
|
+
appSkTitle: '修改应用私钥',
|
|
433
|
+
sharedToAllComponents: '将共享给所有组件'
|
|
433
434
|
},
|
|
434
435
|
overview: {
|
|
435
436
|
source: '来源',
|
|
@@ -661,6 +662,7 @@ module.exports = {
|
|
|
661
662
|
dialog: '点击 “确认” 安装更新。节点将进入维护模式,直到更新完成并自动返回生产模式。',
|
|
662
663
|
confirm: '升级',
|
|
663
664
|
switchLabel: '自动更新检查',
|
|
665
|
+
enableBetaRelease: '允许安装测试版',
|
|
664
666
|
setup: '准备升级中',
|
|
665
667
|
installing: '安装节点新版本(v{version})',
|
|
666
668
|
restarting: '重新启动节点',
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"publishConfig": {
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
|
-
"version": "1.16.6-beta-
|
|
6
|
+
"version": "1.16.6-beta-4ea1eb90",
|
|
7
7
|
"description": "UX components shared across abtnode packages",
|
|
8
8
|
"main": "lib/index.js",
|
|
9
9
|
"files": [
|
|
@@ -22,20 +22,20 @@
|
|
|
22
22
|
"author": "linchen <linchen1987@foxmail.com> (http://github.com/linchen1987)",
|
|
23
23
|
"license": "MIT",
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@abtnode/auth": "1.16.6-beta-
|
|
26
|
-
"@abtnode/constant": "1.16.6-beta-
|
|
27
|
-
"@abtnode/util": "1.16.6-beta-
|
|
28
|
-
"@arcblock/did-connect": "^2.5.
|
|
25
|
+
"@abtnode/auth": "1.16.6-beta-4ea1eb90",
|
|
26
|
+
"@abtnode/constant": "1.16.6-beta-4ea1eb90",
|
|
27
|
+
"@abtnode/util": "1.16.6-beta-4ea1eb90",
|
|
28
|
+
"@arcblock/did-connect": "^2.5.29",
|
|
29
29
|
"@arcblock/did-motif": "^1.1.10",
|
|
30
|
-
"@arcblock/icons": "^2.5.
|
|
31
|
-
"@arcblock/react-hooks": "^2.5.
|
|
32
|
-
"@arcblock/terminal": "^2.5.
|
|
33
|
-
"@arcblock/ux": "^2.5.
|
|
34
|
-
"@blocklet/constant": "1.16.6-beta-
|
|
35
|
-
"@blocklet/launcher-layout": "2.0.
|
|
30
|
+
"@arcblock/icons": "^2.5.29",
|
|
31
|
+
"@arcblock/react-hooks": "^2.5.29",
|
|
32
|
+
"@arcblock/terminal": "^2.5.29",
|
|
33
|
+
"@arcblock/ux": "^2.5.29",
|
|
34
|
+
"@blocklet/constant": "1.16.6-beta-4ea1eb90",
|
|
35
|
+
"@blocklet/launcher-layout": "2.0.32",
|
|
36
36
|
"@blocklet/list": "^0.11.18",
|
|
37
|
-
"@blocklet/meta": "1.16.6-beta-
|
|
38
|
-
"@blocklet/ui-react": "^2.5.
|
|
37
|
+
"@blocklet/meta": "1.16.6-beta-4ea1eb90",
|
|
38
|
+
"@blocklet/ui-react": "^2.5.29",
|
|
39
39
|
"@emotion/react": "^11.10.4",
|
|
40
40
|
"@emotion/styled": "^11.10.4",
|
|
41
41
|
"@iconify/react": "^4.0.0",
|
|
@@ -90,5 +90,5 @@
|
|
|
90
90
|
"@babel/preset-react": "^7.18.6",
|
|
91
91
|
"babel-plugin-inline-react-svg": "^1.1.2"
|
|
92
92
|
},
|
|
93
|
-
"gitHead": "
|
|
93
|
+
"gitHead": "0f0f63b552a88343a3f8e0d434b47c3bca6a75b9"
|
|
94
94
|
}
|