@abtnode/ux 1.16.30-beta-b80c7bcd → 1.16.30-beta-5d9c2c41

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.
@@ -28,7 +28,6 @@ import Toast from '@arcblock/ux/lib/Toast';
28
28
  import Confirm from '../confirm';
29
29
  import { useNodeContext } from '../contexts/node';
30
30
  import { formatError, isDownloading, sleep } from '../util';
31
- import joinUrlKeepSearch from '../util/join-url-keep-search';
32
31
  import Icons from './icons';
33
32
  import { getServerUrl } from './util';
34
33
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
@@ -86,14 +85,6 @@ export default function BlockletActions({
86
85
  const {
87
86
  inService
88
87
  } = node;
89
- const handleOpenDashboard = () => {
90
- const mountPoint = `/${blocklet.mountPoint || '/'}`.replace(/\/+/g, '/');
91
- const href = getComponentUrl?.({
92
- mountPoint,
93
- blocklet
94
- });
95
- window.open(joinUrlKeepSearch(href, '.well-known/service/admin'));
96
- };
97
88
  const createHandler = (action, fn, requireUserConfirm = false) => async () => {
98
89
  const onConfirm = async params => {
99
90
  onStart({
@@ -362,52 +353,15 @@ export default function BlockletActions({
362
353
  }, isDownloading(blocklet.status) ? cancelDownloadAction : removeAction, {
363
354
  separator: true
364
355
  }, !inService ? {
365
- action: 'dashboard',
366
- icon: ({
367
- style,
368
- ...restProps
369
- }) => /*#__PURE__*/_jsx(Icons.Dashboard, {
370
- ...restProps,
371
- style: {
372
- ...style,
373
- width: '26px',
374
- height: '26px',
375
- paddingRight: '3px'
376
- }
377
- }),
378
- name: t('sidebar.dashboard'),
379
- handler: handleOpenDashboard,
380
- disabled: disableStart || blocklet.status !== 'running'
381
- } : null, {
382
- separator: true
383
- }, {
384
- onlyInMenu: true,
385
- action: 'config',
386
- icon: Icons.Config,
387
- name: t('common.config'),
388
- handler: () => {
389
- navigate(`/blocklets/${blocklet.meta.did}/configuration`);
390
- },
391
- disabled: isDownloading(blocklet.status)
392
- }, {
393
- onlyInMenu: true,
394
- action: 'team',
395
- icon: Icons.Group,
396
- name: t('common.manageTeam'),
397
- handler: () => {
398
- navigate(`/blocklets/${blocklet.meta.did}/members`);
399
- },
400
- disabled: isDownloading(blocklet.status)
401
- }, {
402
356
  onlyInMenu: true,
403
- action: 'log',
404
- icon: Icons.Log,
405
- name: t('common.log'),
357
+ action: 'overview',
358
+ icon: Icons.Overview,
359
+ name: t('common.overview'),
406
360
  handler: () => {
407
- navigate(`/logs/blocklet-${blocklet.meta.did}`);
361
+ navigate(`/blocklets/${blocklet.meta.did}/overview`);
408
362
  },
409
363
  disabled: isDownloading(blocklet.status)
410
- }].filter(Boolean);
364
+ } : null].filter(Boolean);
411
365
  if (variant === 'menu') {
412
366
  return /*#__PURE__*/_jsxs(Div, {
413
367
  "data-cy": "blocklet-actions",
@@ -108,8 +108,8 @@ export default function ComponentCell({
108
108
  children: [/*#__PURE__*/_jsxs(Box, {
109
109
  pl: 2,
110
110
  width: {
111
- xs: 300,
112
- md: 400
111
+ xs: 250,
112
+ sm: 400
113
113
  },
114
114
  display: "flex",
115
115
  alignItems: "center",
@@ -118,6 +118,9 @@ export default function ComponentCell({
118
118
  ancestors: ancestors
119
119
  }), /*#__PURE__*/_jsxs(Box, {
120
120
  ml: "16px",
121
+ sx: {
122
+ minWidth: 0
123
+ },
121
124
  children: [/*#__PURE__*/_jsxs(Box, {
122
125
  className: "component-header",
123
126
  onClick: () => setComponentInfo(blocklet),
@@ -330,6 +333,10 @@ export const StyledComponentRow = styled(Box)`
330
333
  cursor: pointer;
331
334
  }
332
335
  .component-name {
336
+ min-width: 0;
337
+ overflow: hidden;
338
+ text-overflow: ellipsis;
339
+ white-space: nowrap;
333
340
  color: #222;
334
341
  font-size: 16px;
335
342
  }
@@ -64,12 +64,19 @@ export default function OptionalComponentCell({
64
64
  style: {
65
65
  flex: 1
66
66
  }
67
- }), /*#__PURE__*/_jsx(Button, {
68
- onClick: handleOpen,
69
- startIcon: /*#__PURE__*/_jsx(Icon, {
70
- icon: "ph:download-simple-bold"
71
- }),
72
- children: t('common.install')
67
+ }), /*#__PURE__*/_jsx(Box, {
68
+ sx: {
69
+ minWidth: 100,
70
+ display: 'flex',
71
+ justifyContent: 'flex-end'
72
+ },
73
+ children: /*#__PURE__*/_jsx(Button, {
74
+ onClick: handleOpen,
75
+ startIcon: /*#__PURE__*/_jsx(Icon, {
76
+ icon: "ph:download-simple-bold"
77
+ }),
78
+ children: t('common.install')
79
+ })
73
80
  })]
74
81
  }), /*#__PURE__*/_jsx(Line, {
75
82
  class: "line"
@@ -109,6 +116,7 @@ const StyledDiv = styled(StyledComponentRow)`
109
116
  flex-direction: row;
110
117
  justify-content: flex-start;
111
118
  align-items: center;
119
+ min-width: 0;
112
120
  }
113
121
  .component-logo {
114
122
  width: 40px;
@@ -118,6 +126,8 @@ const StyledDiv = styled(StyledComponentRow)`
118
126
  overflow: hidden;
119
127
  }
120
128
  .component-header {
129
+ flex: 1;
130
+ min-width: 0;
121
131
  opacity: 0.5;
122
132
  margin-left: 12px;
123
133
  display: flex;
@@ -126,6 +136,7 @@ const StyledDiv = styled(StyledComponentRow)`
126
136
  cursor: pointer;
127
137
  }
128
138
  .component-name {
139
+ flex: 1;
129
140
  opacity: 0.5;
130
141
  color: #222;
131
142
  font-size: 16px;
@@ -8,6 +8,7 @@ import Log from '@mui/icons-material/Receipt';
8
8
  import Group from '@mui/icons-material/Group';
9
9
  import Cancel from '@mui/icons-material/NotInterested';
10
10
  import Dashboard from '@arcblock/icons/lib/Dashboard';
11
+ import Overview from '@mui/icons-material/ViewInAr';
11
12
  export default {
12
13
  Start,
13
14
  Stop,
@@ -18,5 +19,6 @@ export default {
18
19
  Log,
19
20
  Group,
20
21
  Cancel,
21
- Dashboard
22
+ Dashboard,
23
+ Overview
22
24
  };
@@ -1,6 +1,6 @@
1
1
  import React, { useState } from 'react';
2
2
  import { CircularProgress, IconButton, ListItemIcon, ListItemText, Menu, MenuItem } from '@mui/material';
3
- import MoreVertIcon from '@mui/icons-material/MoreVert';
3
+ import MoreHorizIcon from '@mui/icons-material/MoreHoriz';
4
4
  import { useLocaleContext } from '@arcblock/ux/lib/Locale/context';
5
5
  import ArrowOutwardIcon from '@mui/icons-material/ArrowOutward';
6
6
  import PropTypes from 'prop-types';
@@ -70,7 +70,7 @@ function SpaceItemAction({
70
70
  ...rest,
71
71
  children: loading || spaceGateway?.loading ? /*#__PURE__*/_jsx(CircularProgress, {
72
72
  size: "24px"
73
- }) : /*#__PURE__*/_jsx(MoreVertIcon, {})
73
+ }) : /*#__PURE__*/_jsx(MoreHorizIcon, {})
74
74
  }), /*#__PURE__*/_jsxs(Menu, {
75
75
  id: "simple-menu",
76
76
  anchorEl: anchorEl,
@@ -1,4 +1,4 @@
1
- import { Box, CircularProgress, Typography } from '@mui/material';
1
+ import { Box, CircularProgress, Grid, Typography } from '@mui/material';
2
2
  import React from 'react';
3
3
  import { useLocaleContext } from '@arcblock/ux/lib/Locale/context';
4
4
  import toast from '@arcblock/ux/lib/Toast';
@@ -84,16 +84,25 @@ function Connected() {
84
84
  display: "flex",
85
85
  justifyContent: "center",
86
86
  children: /*#__PURE__*/_jsx(CircularProgress, {})
87
- }) : spaceGateways.map(x => {
88
- return /*#__PURE__*/_jsx(SpaceItem, {
89
- style: {
90
- marginTop: '12px'
91
- },
92
- spaceGateway: x,
93
- connected: spaceGatewayIsSelected(x),
94
- onDelete: onDeleteGateway,
95
- onBackupNow: onBackupNow
96
- }, x.endpoint);
87
+ }) : /*#__PURE__*/_jsx(Grid, {
88
+ container: true,
89
+ spacing: 1,
90
+ children: spaceGateways.map(x => {
91
+ return /*#__PURE__*/_jsx(Grid, {
92
+ item: true,
93
+ xs: 12,
94
+ md: 6,
95
+ children: /*#__PURE__*/_jsx(SpaceItem, {
96
+ style: {
97
+ marginTop: '12px'
98
+ },
99
+ spaceGateway: x,
100
+ connected: spaceGatewayIsSelected(x),
101
+ onDelete: onDeleteGateway,
102
+ onBackupNow: onBackupNow
103
+ }, x.endpoint)
104
+ });
105
+ })
97
106
  })
98
107
  }), /*#__PURE__*/_jsx(SpacesBackupRecords, {
99
108
  sx: {
@@ -1,4 +1,4 @@
1
- import { Box, Chip, LinearProgress, Typography, useMediaQuery } from '@mui/material';
1
+ import { Box, LinearProgress, Typography, useMediaQuery } from '@mui/material';
2
2
  import React, { useEffect, useState } from 'react';
3
3
  import Button from '@arcblock/ux/lib/Button';
4
4
  import { useLocaleContext } from '@arcblock/ux/lib/Locale/context';
@@ -66,7 +66,7 @@ import { useBlockletStorageContext } from '../../contexts/blocklet-storage';
66
66
  * onBackupNow: () => Promise<void>,
67
67
  * }} { spaceGateway, connected,, onDelete, onBackupNow }
68
68
  */
69
- import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
69
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
70
70
  function SpaceItem({
71
71
  spaceGateway,
72
72
  connected,
@@ -253,80 +253,67 @@ function SpaceItem({
253
253
  // eslint-disable-next-line react-hooks/exhaustive-deps
254
254
  }, [backupProgress]);
255
255
  return /*#__PURE__*/_jsxs(BoxContainer, {
256
- style: {
257
- position: 'relative'
256
+ sx: {
257
+ backgroundColor: connected ? '#F0FDFF' : 'inherit',
258
+ '&:hover': {
259
+ backgroundColor: connected ? '#F0FDFF' : '#FBFBFB'
260
+ },
261
+ borderRadius: '8px'
258
262
  },
263
+ display: "flex",
264
+ flexDirection: "column",
265
+ padding: "4px 20px 12px",
266
+ ...rest,
259
267
  children: [/*#__PURE__*/_jsxs(Box, {
260
- sx: {
261
- backgroundColor: connected ? '#F0FDFF' : 'inherit',
262
- '&:hover': {
263
- backgroundColor: connected ? '#F0FDFF' : '#FBFBFB'
264
- },
265
- borderRadius: '8px'
266
- },
267
268
  display: "flex",
268
- padding: "12px 20px",
269
- ...rest,
270
- children: [/*#__PURE__*/_jsx(Box, {
271
- display: "flex",
272
- children: /*#__PURE__*/_jsx(PreviewSpaceNft, {
273
- alt: spaceGateway.did,
274
- src: getSpaceNftDisplayUrlFromEndpoint(spaceGateway.endpoint)
275
- })
276
- }), /*#__PURE__*/_jsxs(Box, {
277
- className: "spaces-info",
278
- display: "flex",
279
- flexGrow: (!isMobile || !shouldDisplayBackupProgress) && 1,
280
- minWidth: "180px",
281
- flexDirection: shouldDisplayBackupProgress ? 'row' : 'column',
282
- sx: {
283
- marginLeft: '20px',
284
- padding: '0px 0px'
285
- },
286
- children: [/*#__PURE__*/_jsxs(Box, {
287
- className: "spaces-info",
288
- display: "flex",
289
- maxWidth: "360px",
290
- alignItems: "center",
291
- children: [/*#__PURE__*/_jsx(Typography, {
292
- color: connected ? 'primary' : 'inherit',
293
- fontSize: "1rem",
294
- fontWeight: "bold",
295
- children: spaceGateway.name
296
- }), shouldDisplayConnected && /*#__PURE__*/_jsx(Chip, {
297
- label: /*#__PURE__*/_jsxs(_Fragment, {
298
- children: [/*#__PURE__*/_jsx(SpacesConnected, {
299
- style: {
300
- marginRight: '4px'
301
- }
302
- }), t('storage.spaces.connected.tag')]
303
- }),
304
- variant: "outlined",
305
- size: "small",
269
+ alignItems: "center",
270
+ children: [/*#__PURE__*/_jsxs(Box, {
271
+ flex: 1,
272
+ children: [shouldDisplayConnected && /*#__PURE__*/_jsxs(Typography, {
273
+ color: "primary",
274
+ fontSize: 14,
275
+ children: [/*#__PURE__*/_jsx(SpacesConnected, {
306
276
  style: {
307
- marginLeft: '20px',
308
- fontWeight: 'bold'
277
+ marginRight: '8px'
309
278
  }
310
- }), shouldDisplayReconnectNow && /*#__PURE__*/_jsx(Chip, {
311
- label: /*#__PURE__*/_jsxs(_Fragment, {
312
- children: [/*#__PURE__*/_jsx(SpaceDisconnected, {
313
- style: {
314
- marginRight: '4px'
315
- }
316
- }), t('storage.spaces.disconnected.tag')]
317
- }),
318
- variant: "outlined",
319
- size: "small",
279
+ }), t('storage.spaces.connected.tag')]
280
+ }), shouldDisplayReconnectNow && /*#__PURE__*/_jsxs(Typography, {
281
+ color: "error",
282
+ fontSize: 14,
283
+ children: [/*#__PURE__*/_jsx(SpaceDisconnected, {
320
284
  style: {
321
- marginLeft: '20px',
322
- fontWeight: 'bold'
285
+ marginRight: '8px'
323
286
  }
324
- })]
287
+ }), t('storage.spaces.disconnected.tag')]
288
+ })]
289
+ }), /*#__PURE__*/_jsx(SpaceItemAction, {
290
+ sx: {
291
+ padding: '4px'
292
+ },
293
+ spaceGateway: spaceGateway,
294
+ connected: connected,
295
+ onDelete: onDelete,
296
+ onConnect: onConnect,
297
+ enableSwitchToSpace: backupProgress?.completed || isEmpty(backupProgress?.message),
298
+ backupInProgress: shouldDisplayBackupProgress
299
+ })]
300
+ }), /*#__PURE__*/_jsxs(Box, {
301
+ display: "flex",
302
+ children: [/*#__PURE__*/_jsxs(Box, {
303
+ display: "flex",
304
+ flexDirection: "column",
305
+ flex: "1",
306
+ minWidth: 0,
307
+ children: [/*#__PURE__*/_jsx(Typography, {
308
+ className: "spaces-name",
309
+ fontSize: "1rem",
310
+ fontWeight: "bold",
311
+ children: spaceGateway.name
325
312
  }), /*#__PURE__*/_jsx(Box, {
326
313
  className: "spaces-address",
327
314
  display: shouldDisplayBackupProgress ? 'none' : 'flex',
328
315
  color: "#9397A1",
329
- marginTop: "8px",
316
+ marginTop: "4px",
330
317
  children: /*#__PURE__*/_jsx(Typography, {
331
318
  sx: {
332
319
  display: 'inline-flex',
@@ -342,107 +329,99 @@ function SpaceItem({
342
329
  did: spaceGateway.did
343
330
  })
344
331
  })
345
- })]
346
- }), /*#__PURE__*/_jsxs(Box, {
347
- className: "spaces-backup",
348
- display: "flex",
349
- alignItems: "center",
350
- flex: isMobile && shouldDisplayBackupProgress && 1,
351
- children: [shouldDisplayBackupButton && /*#__PURE__*/_jsxs(Box, {
352
- className: "backup-strategy",
332
+ }), /*#__PURE__*/_jsxs(Box, {
333
+ className: "spaces-backup",
353
334
  display: "flex",
354
335
  alignItems: "center",
355
- width: "100%",
356
- children: [/*#__PURE__*/_jsx(Button, {
357
- variant: "contained",
358
- size: "small",
359
- onClick: _onBackupNow,
360
- children: t('storage.spaces.strategy.backupNow')
361
- }), enableDebug && /*#__PURE__*/_jsx(SwitchControl, {
362
- name: "enable-auto-backup",
363
- title: "coming soon",
364
- disabled: true,
365
- labelProps: {
366
- label: /*#__PURE__*/_jsx(Typography, {
367
- sx: {
368
- marginRight: '8px',
369
- fontSize: '16px'
370
- },
371
- children: /*#__PURE__*/_jsx("span", {
372
- children: t('storage.spaces.strategy.autoBackup')
336
+ marginTop: "8px",
337
+ flex: 1,
338
+ children: [shouldDisplayBackupButton && /*#__PURE__*/_jsxs(Box, {
339
+ className: "backup-strategy",
340
+ display: "flex",
341
+ alignItems: "center",
342
+ minWidth: "72px",
343
+ children: [/*#__PURE__*/_jsx(Button, {
344
+ variant: "contained",
345
+ size: "small",
346
+ onClick: _onBackupNow,
347
+ children: t('storage.spaces.strategy.backupNow')
348
+ }), enableDebug && /*#__PURE__*/_jsx(SwitchControl, {
349
+ name: "enable-auto-backup",
350
+ title: "coming soon",
351
+ disabled: true,
352
+ labelProps: {
353
+ label: /*#__PURE__*/_jsx(Typography, {
354
+ sx: {
355
+ marginRight: '8px',
356
+ fontSize: '16px'
357
+ },
358
+ children: /*#__PURE__*/_jsx("span", {
359
+ children: t('storage.spaces.strategy.autoBackup')
360
+ })
373
361
  })
374
- })
375
- },
376
- style: {
377
- marginLeft: '64px'
378
- }
379
- })]
380
- }), shouldDisplayBackupProgress && /*#__PURE__*/_jsxs(Box, {
381
- className: "backup-progress",
382
- display: "flex",
383
- flexDirection: "column",
384
- alignItems: "center",
385
- minWidth: !isMobile && '640px',
386
- marginLeft: isMobile && '16px',
387
- width: isMobile && '360px',
388
- marginRight: "auto",
389
- alignSelf: "flex-end",
390
- children: [/*#__PURE__*/_jsx(Typography, {
391
- color: "primary",
392
- children: backupProgress?.message
393
- }), /*#__PURE__*/_jsxs(Box, {
394
- sx: {
395
- display: 'flex',
396
- alignItems: 'center'
397
- },
398
- width: "100%",
399
- children: [/*#__PURE__*/_jsx(Box, {
400
- sx: {
401
- width: '100%',
402
- mr: 1
403
362
  },
404
- children: /*#__PURE__*/_jsx(LinearProgress, {
405
- color: "primary",
406
- variant: "determinate",
407
- value: backupProgress?.progress
408
- })
409
- }), /*#__PURE__*/_jsx(Box, {
363
+ style: {
364
+ marginLeft: '64px'
365
+ }
366
+ })]
367
+ }), shouldDisplayBackupProgress && /*#__PURE__*/_jsxs(Box, {
368
+ className: "backup-progress",
369
+ display: "flex",
370
+ flexDirection: "column",
371
+ alignItems: "center",
372
+ marginLeft: isMobile && '16px',
373
+ width: "90%",
374
+ marginRight: "auto",
375
+ alignSelf: "flex-end",
376
+ children: [/*#__PURE__*/_jsx(Typography, {
377
+ color: "primary",
378
+ children: backupProgress?.message
379
+ }), /*#__PURE__*/_jsxs(Box, {
410
380
  sx: {
411
- maxWidth: '100%'
381
+ display: 'flex',
382
+ alignItems: 'center'
412
383
  },
413
- children: /*#__PURE__*/_jsxs(Typography, {
414
- variant: "body2",
415
- color: "text.secondary",
416
- children: [backupProgress?.progress, "%"]
417
- })
384
+ width: "100%",
385
+ children: [/*#__PURE__*/_jsx(Box, {
386
+ sx: {
387
+ width: '100%',
388
+ mr: 1
389
+ },
390
+ children: /*#__PURE__*/_jsx(LinearProgress, {
391
+ color: "primary",
392
+ variant: "determinate",
393
+ value: backupProgress?.progress
394
+ })
395
+ }), /*#__PURE__*/_jsx(Box, {
396
+ sx: {
397
+ maxWidth: '100%'
398
+ },
399
+ children: /*#__PURE__*/_jsxs(Typography, {
400
+ variant: "body2",
401
+ color: "text.secondary",
402
+ children: [backupProgress?.progress, "%"]
403
+ })
404
+ })]
418
405
  })]
406
+ }), shouldDisplayReconnectNow && /*#__PURE__*/_jsx(Box, {
407
+ className: "backup-strategy",
408
+ display: "flex",
409
+ alignItems: "center",
410
+ minWidth: "72px",
411
+ children: /*#__PURE__*/_jsx(Button, {
412
+ color: "error",
413
+ variant: "contained",
414
+ size: "small",
415
+ onClick: onConnect,
416
+ children: t('storage.spaces.disconnected.reconnectNow')
417
+ })
419
418
  })]
420
- }), shouldDisplayReconnectNow && /*#__PURE__*/_jsx(Box, {
421
- className: "backup-strategy",
422
- display: "flex",
423
- alignItems: "center",
424
- width: "100%",
425
- children: /*#__PURE__*/_jsx(Button, {
426
- color: "error",
427
- variant: "contained",
428
- size: "small",
429
- onClick: onConnect,
430
- children: t('storage.spaces.disconnected.reconnectNow')
431
- })
432
- }), /*#__PURE__*/_jsx(SpaceItemAction, {
433
- sx: {
434
- marginLeft: '16px',
435
- marginRight: '16px',
436
- alignItems: 'flex-end',
437
- justifyItems: 'flex-end'
438
- },
439
- spaceGateway: spaceGateway,
440
- connected: connected,
441
- onDelete: onDelete,
442
- onConnect: onConnect,
443
- enableSwitchToSpace: backupProgress?.completed || isEmpty(backupProgress?.message),
444
- backupInProgress: shouldDisplayBackupProgress
445
419
  })]
420
+ }), /*#__PURE__*/_jsx(PreviewSpaceNft, {
421
+ alt: spaceGateway.did,
422
+ src: getSpaceNftDisplayUrlFromEndpoint(spaceGateway.endpoint),
423
+ width: "72px",
424
+ height: "72px"
446
425
  })]
447
426
  }), /*#__PURE__*/_jsx(DidConnect, {
448
427
  forceConnected: false,
@@ -486,6 +465,11 @@ SpaceItem.defaultProps = {
486
465
  onBackupNow: () => undefined
487
466
  };
488
467
  const BoxContainer = styled(Box)`
468
+ box-sizing: border-box;
469
+ position: relative;
470
+ min-height: 136px;
471
+ border: 1px solid #f8f8f8;
472
+
489
473
  .selected-container {
490
474
  position: absolute;
491
475
  right: 0px;
@@ -538,5 +522,14 @@ const BoxContainer = styled(Box)`
538
522
  visibility: visible;
539
523
  }
540
524
  }
525
+
526
+ .spaces {
527
+ &-name {
528
+ margin-right: 12px;
529
+ white-space: nowrap;
530
+ overflow: hidden;
531
+ text-overflow: ellipsis;
532
+ }
533
+ }
541
534
  `;
542
535
  export default SpaceItem;
@@ -204,7 +204,9 @@ EmptySpacesNFT.defaultProps = {
204
204
  };
205
205
  function PreviewSpaceNft({
206
206
  src,
207
- alt
207
+ alt,
208
+ width,
209
+ height
208
210
  }) {
209
211
  const [showEmptySpaceNFT, setShowEmptySpaceNFT] = useState(false);
210
212
  const [open, setOpen] = useState(false);
@@ -222,8 +224,8 @@ function PreviewSpaceNft({
222
224
  },
223
225
  alt: alt,
224
226
  src: src,
225
- width: "58px",
226
- height: "58px",
227
+ width: width,
228
+ height: height,
227
229
  onError: () => setShowEmptySpaceNFT(true),
228
230
  onClick: handleOpen
229
231
  }),
@@ -278,6 +280,12 @@ function PreviewSpaceNft({
278
280
  }
279
281
  PreviewSpaceNft.propTypes = {
280
282
  src: string.isRequired,
281
- alt: string.isRequired
283
+ alt: string.isRequired,
284
+ width: string,
285
+ height: string
286
+ };
287
+ PreviewSpaceNft.defaultProps = {
288
+ width: '58px',
289
+ height: '58px'
282
290
  };
283
291
  export default PreviewSpaceNft;
package/lib/locales/ar.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: 'تثبيت على هذا الخادم'
748
748
  },
749
749
  titleValidationError: 'يجب أن يكون طول العنوان على الأقل 3 أحرف',
750
- descriptionValidationError: 'يجب أن تكون طول الوصف بين 3 و 160 حرفًا',
750
+ descriptionValidationError: 'يجب أن تكون طول الوصف بين 3 و 80 حرفًا',
751
751
  whyNeedAppPid: 'إذا تم نقل تطبيقك، فإن DID الدائم هو DID الذي تم إنشاؤه عند تثبيت Blocklet هذا في الأصل.'
752
752
  },
753
753
  dashboard: {
package/lib/locales/de.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: 'Auf diesem Server installieren'
748
748
  },
749
749
  titleValidationError: 'Die Länge des Titels muss mindestens 3 Zeichen betragen',
750
- descriptionValidationError: 'Die Beschreibungslänge muss zwischen 3 und 160 Zeichen liegen',
750
+ descriptionValidationError: 'Beschreibungslänge muss zwischen 3 und 80 Zeichen liegen',
751
751
  whyNeedAppPid: 'Wenn Ihre Anwendung migriert wurde, ist die permanente DID die DID, die bei der ursprünglichen Installation dieses Blocklets generiert wurde.'
752
752
  },
753
753
  dashboard: {
package/lib/locales/en.js CHANGED
@@ -358,8 +358,8 @@ export default {
358
358
  installFromMarket: 'Install New Blocklets',
359
359
  installFromUrl: 'Install From Url',
360
360
  installFromCreate: 'Create Blocklet',
361
- titleValidationError: 'Title length must be between 3 and 40 characters',
362
- descriptionValidationError: 'Description length must be between 3 and 160 characters',
361
+ titleValidationError: 'Title length must be between 3 and 20 characters',
362
+ descriptionValidationError: 'Description length must be between 3 and 80 characters',
363
363
  installFromDiskBackup: 'Restore from this server',
364
364
  installedAt: 'Installed At',
365
365
  internal: 'Internal',
package/lib/locales/es.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: 'Instalar en este servidor'
748
748
  },
749
749
  titleValidationError: 'La longitud del título debe ser de al menos 3 caracteres',
750
- descriptionValidationError: 'La longitud de la descripción debe estar entre 3 y 160 caracteres',
750
+ descriptionValidationError: 'La longitud de la descripción debe estar entre 3 y 80 caracteres',
751
751
  whyNeedAppPid: 'Si se ha migrado su aplicación, el DID permanente es el DID generado cuando este Blocklet se instaló originalmente.'
752
752
  },
753
753
  dashboard: {
package/lib/locales/fr.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: 'Installer sur ce serveur'
748
748
  },
749
749
  titleValidationError: "La longueur du titre doit être d'au moins 3 caractères",
750
- descriptionValidationError: 'La longueur de la description doit être comprise entre 3 et 160 caractères',
750
+ descriptionValidationError: 'La longueur de la description doit être comprise entre 3 et 80 caractères',
751
751
  whyNeedAppPid: "Si votre application a été migrée, le DID permanent est le DID généré lors de l'installation initiale de ce Blocklet."
752
752
  },
753
753
  dashboard: {
package/lib/locales/hi.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: 'इस सर्वर पर स्थापित करें'
748
748
  },
749
749
  titleValidationError: 'शीर्षक की लंबाई कम से कम 3 अक्षर होनी चाहिए',
750
- descriptionValidationError: 'विवरण की लंबाई 3 और 160 वर्णों के बीच होनी चाहिए',
750
+ descriptionValidationError: 'विवरण लंबाई 3 और 80 वर्णों के बीच होना चाहिए',
751
751
  whyNeedAppPid: 'अगर आपका एप्लीकेशन माइग्रेट कर दिया गया है, तो परमानेंट DID वही DID है जो उस समय जनरेट की गई थी जब पहली बार यह ब्लॉकलेट इंस्टॉल किया गया था।'
752
752
  },
753
753
  dashboard: {
Binary file
package/lib/locales/id.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: 'Pasang ke server ini'
748
748
  },
749
749
  titleValidationError: 'Panjang judul harus setidaknya 3 karakter',
750
- descriptionValidationError: 'Panjang deskripsi harus antara 3 dan 160 karakter.',
750
+ descriptionValidationError: 'Panjang deskripsi harus antara 3 dan 80 karakter',
751
751
  whyNeedAppPid: 'Jika aplikasi Anda telah dimigrasikan, DID permanen adalah DID yang dihasilkan saat Blocklet ini pertama kali dipasang'
752
752
  },
753
753
  dashboard: {
package/lib/locales/ja.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: 'このサーバーにインストール'
748
748
  },
749
749
  titleValidationError: 'タイトルの長さは最低3文字以上である必要があります',
750
- descriptionValidationError: '説明の長さは3から160文字の間でなければなりません',
750
+ descriptionValidationError: '説明の長さは3〜80文字の間でなければなりません',
751
751
  whyNeedAppPid: 'アプリケーションが移行されている場合、永続的な DID はこの Blocklet が最初にインストールされたときに生成された DID です。'
752
752
  },
753
753
  dashboard: {
package/lib/locales/ko.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: '이 서버에 설치'
748
748
  },
749
749
  titleValidationError: '제목 길이는 최소 3자 이상이어야 합니다',
750
- descriptionValidationError: '설명 길이는 3에서 160자 사이여야 합니다',
750
+ descriptionValidationError: '설명 길이는 3에서 80 자여야합니다.',
751
751
  whyNeedAppPid: '애플리케이션이 마이그레이션된 경우 영구 DID는 이 Blocklet이 처음 설치되었을 때 생성된 DID입니다.'
752
752
  },
753
753
  dashboard: {
package/lib/locales/pt.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: 'Instale neste servidor'
748
748
  },
749
749
  titleValidationError: 'O comprimento do título deve ter pelo menos 3 caracteres',
750
- descriptionValidationError: 'O comprimento da descrição deve estar entre 3 e 160 caracteres.',
750
+ descriptionValidationError: 'O comprimento da descrição deve estar entre 3 e 80 caracteres',
751
751
  whyNeedAppPid: 'Se o seu aplicativo foi migrado, o DID permanente é o DID gerado quando este Blocklet foi instalado originalmente'
752
752
  },
753
753
  dashboard: {
package/lib/locales/ru.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: 'Установить на этот сервер'
748
748
  },
749
749
  titleValidationError: 'Длина заголовка должна быть не менее 3 символов',
750
- descriptionValidationError: 'Длина описания должна быть от 3 до 160 символов',
750
+ descriptionValidationError: 'Длина описания должна быть от 3 до 80 символов',
751
751
  whyNeedAppPid: 'Если ваше приложение перенесено, постоянный DID — это DID, созданный при первоначальной установке этого Blocklet.'
752
752
  },
753
753
  dashboard: {
package/lib/locales/th.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: 'ติดตั้งลงในเซิร์ฟเวอร์นี้'
748
748
  },
749
749
  titleValidationError: 'ความยาวของชื่อต้องมีอย่างน้อย 3 ตัวอักษร',
750
- descriptionValidationError: 'ความยาวคำอธิบายต้องอยู่ระหว่าง 3 ถึง 160 ตัวอักษร.',
750
+ descriptionValidationError: 'ความยาวของคำอธิบายต้องอยู่ระหว่าง 3 และ 80 ตัวอักษร',
751
751
  whyNeedAppPid: 'หากแอปพลิเคชันของคุณได้รับการโยกย้ายมา DID ถาวรคือ DID ที่สร้างขึ้นเมื่อติดตั้ง Blocklet นี้เริ่มแรก'
752
752
  },
753
753
  dashboard: {
package/lib/locales/vi.js CHANGED
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: 'Cài đặt vào máy chủ này'
748
748
  },
749
749
  titleValidationError: 'Độ dài tiêu đề phải ít nhất 3 ký tự',
750
- descriptionValidationError: 'Chiều dài mô tả phải từ 3 đến 160tự.',
750
+ descriptionValidationError: 'Độ dài mô tả phải từ 3 đến 80tự',
751
751
  whyNeedAppPid: 'Nếu ứng dụng của bạn đã được di chuyển, DID vĩnh viễn là DID được tạo khi Blocklet này được cài đặt ban đầu'
752
752
  },
753
753
  dashboard: {
@@ -747,7 +747,7 @@ export default {
747
747
  installToThisServer: '安裝至此伺服器'
748
748
  },
749
749
  titleValidationError: '標題長度必須至少為3到40個字符',
750
- descriptionValidationError: '描述長度必須介於3到160個字符之間',
750
+ descriptionValidationError: '描述長度必須介於3到80個字元之間',
751
751
  whyNeedAppPid: '如果已遷移您的應用程式,永久 DID 是最初安裝此 Blocklet 時產生的 DID。'
752
752
  },
753
753
  dashboard: {
package/lib/locales/zh.js CHANGED
@@ -748,7 +748,7 @@ export default {
748
748
  installToThisServer: '安装到此服务器'
749
749
  },
750
750
  titleValidationError: '标题长度必须至少为3到40个字符',
751
- descriptionValidationError: '描述长度必须在3到160个字符之间'
751
+ descriptionValidationError: '描述长度必须介于3到80个字符之间'
752
752
  },
753
753
  dashboard: {
754
754
  nodeDid: '节点地址',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abtnode/ux",
3
- "version": "1.16.30-beta-b80c7bcd",
3
+ "version": "1.16.30-beta-5d9c2c41",
4
4
  "description": "UX components shared across abtnode packages",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -25,25 +25,25 @@
25
25
  "author": "linchen <linchen1987@foxmail.com> (http://github.com/linchen1987)",
26
26
  "license": "Apache-2.0",
27
27
  "dependencies": {
28
- "@abtnode/auth": "1.16.30-beta-b80c7bcd",
29
- "@abtnode/constant": "1.16.30-beta-b80c7bcd",
30
- "@abtnode/util": "1.16.30-beta-b80c7bcd",
28
+ "@abtnode/auth": "1.16.30-beta-5d9c2c41",
29
+ "@abtnode/constant": "1.16.30-beta-5d9c2c41",
30
+ "@abtnode/util": "1.16.30-beta-5d9c2c41",
31
31
  "@ahooksjs/use-url-state": "^3.5.1",
32
- "@arcblock/did": "^1.18.128",
33
- "@arcblock/did-connect": "^2.10.14",
32
+ "@arcblock/did": "^1.18.130",
33
+ "@arcblock/did-connect": "^2.10.21",
34
34
  "@arcblock/did-motif": "^1.1.13",
35
- "@arcblock/icons": "^2.10.14",
36
- "@arcblock/nft-display": "2.10.14",
37
- "@arcblock/react-hooks": "^2.10.14",
38
- "@arcblock/terminal": "^2.10.14",
39
- "@arcblock/ux": "^2.10.14",
40
- "@blocklet/constant": "1.16.30-beta-b80c7bcd",
41
- "@blocklet/js-sdk": "1.16.30-beta-b80c7bcd",
42
- "@blocklet/launcher-layout": "2.3.40",
43
- "@blocklet/list": "^0.13.14",
44
- "@blocklet/meta": "1.16.30-beta-b80c7bcd",
45
- "@blocklet/ui-react": "^2.10.14",
46
- "@blocklet/uploader": "0.1.20",
35
+ "@arcblock/icons": "^2.10.21",
36
+ "@arcblock/nft-display": "2.10.21",
37
+ "@arcblock/react-hooks": "^2.10.21",
38
+ "@arcblock/terminal": "^2.10.21",
39
+ "@arcblock/ux": "^2.10.21",
40
+ "@blocklet/constant": "1.16.30-beta-5d9c2c41",
41
+ "@blocklet/js-sdk": "1.16.30-beta-5d9c2c41",
42
+ "@blocklet/launcher-layout": "2.10.21",
43
+ "@blocklet/list": "^0.13.18",
44
+ "@blocklet/meta": "1.16.30-beta-5d9c2c41",
45
+ "@blocklet/ui-react": "^2.10.21",
46
+ "@blocklet/uploader": "0.1.21",
47
47
  "@emotion/react": "^11.10.4",
48
48
  "@emotion/styled": "^11.10.4",
49
49
  "@iconify-icons/logos": "^1.2.36",
@@ -56,7 +56,7 @@
56
56
  "@mui/styles": "^5.15.11",
57
57
  "@mui/x-date-pickers": "^6.19.0",
58
58
  "@mui/x-tree-view": "^6.17.0",
59
- "@ocap/client": "1.18.128",
59
+ "@ocap/client": "1.18.130",
60
60
  "@uiw/react-markdown-preview": "^5.1.1",
61
61
  "ahooks": "^3.7.8",
62
62
  "axios": "^1.7.2",
@@ -108,5 +108,5 @@
108
108
  "jest": "^29.7.0",
109
109
  "jest-environment-jsdom": "^29.7.0"
110
110
  },
111
- "gitHead": "9d68833290b1a59357b7c362018416b82b5d1503"
111
+ "gitHead": "d9227f08e11c1d82969880b30b2a2e3639e88def"
112
112
  }