@xyo-network/react-chain-blockchain 1.3.6 → 1.3.7
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/dist/browser/index.mjs +38 -31
- package/dist/browser/index.mjs.map +1 -1
- package/dist/types/components/block/table/cell/TransactionCount.d.ts.map +1 -1
- package/package.json +31 -30
- package/src/components/block/table/cell/TransactionCount.tsx +17 -2
- package/src/components/transactions/TransactionCountChip.tsx +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TransactionCount.d.ts","sourceRoot":"","sources":["../../../../../../src/components/block/table/cell/TransactionCount.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;
|
|
1
|
+
{"version":3,"file":"TransactionCount.d.ts","sourceRoot":"","sources":["../../../../../../src/components/block/table/cell/TransactionCount.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AAEvC,OAAO,KAAkB,MAAM,OAAO,CAAA;AAKtC,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAA;AAEzD,MAAM,WAAW,mCAAoC,SAAQ,mBAAmB;CAAG;AAEnF,MAAM,WAAW,8BAA8B;IAC7C,KAAK,EAAE,IAAI,CAAA;IACX,YAAY,EAAE,MAAM,CAAA;CACrB;AAED,eAAO,MAAM,8BAA8B,EAAE,KAAK,CAAC,EAAE,CAAC,mCAAmC,CAyCxF,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "http://json.schemastore.org/package.json",
|
|
3
3
|
"name": "@xyo-network/react-chain-blockchain",
|
|
4
|
-
"version": "1.3.
|
|
4
|
+
"version": "1.3.7",
|
|
5
5
|
"description": "XYO Layer One React SDK Blockchain",
|
|
6
6
|
"homepage": "https://xylabs.com",
|
|
7
7
|
"bugs": {
|
|
@@ -43,33 +43,33 @@
|
|
|
43
43
|
"@xylabs/exists": "^4.8.7",
|
|
44
44
|
"@xylabs/hex": "^4.8.7",
|
|
45
45
|
"@xylabs/promise": "^4.8.7",
|
|
46
|
-
"@xylabs/react-animation": "^6.2.
|
|
47
|
-
"@xylabs/react-error": "^6.2.
|
|
48
|
-
"@xylabs/react-flexbox": "^6.2.
|
|
49
|
-
"@xylabs/react-identicon": "^6.2.
|
|
50
|
-
"@xylabs/react-promise": "^6.2.
|
|
51
|
-
"@xylabs/react-quick-tip-button": "^6.2.
|
|
52
|
-
"@xyo-network/account": "^3.13
|
|
53
|
-
"@xyo-network/api-models": "^3.13
|
|
54
|
-
"@xyo-network/archivist-model": "^3.13
|
|
55
|
-
"@xyo-network/boundwitness-builder": "^3.13
|
|
56
|
-
"@xyo-network/boundwitness-model": "^3.13
|
|
57
|
-
"@xyo-network/bridge-http": "^3.13
|
|
58
|
-
"@xyo-network/chain-ethereum": "^1.3.
|
|
59
|
-
"@xyo-network/chain-protocol": "^1.3.
|
|
60
|
-
"@xyo-network/chain-services": "^1.3.
|
|
61
|
-
"@xyo-network/module-model": "^3.13
|
|
62
|
-
"@xyo-network/payload-builder": "^3.13
|
|
63
|
-
"@xyo-network/payload-model": "^3.13
|
|
64
|
-
"@xyo-network/react-boundwitness-plugin": "^5.2.
|
|
65
|
-
"@xyo-network/react-chain-blockies": "^1.3.
|
|
66
|
-
"@xyo-network/react-event": "^5.2.
|
|
67
|
-
"@xyo-network/react-payload-raw-info": "^5.2.
|
|
68
|
-
"@xyo-network/react-payload-table": "^5.2.
|
|
69
|
-
"@xyo-network/react-shared": "^5.2.
|
|
70
|
-
"@xyo-network/react-table": "^5.2.
|
|
71
|
-
"@xyo-network/xl1-model": "^1.3.
|
|
72
|
-
"@xyo-network/xl1-protocol": "^1.3.
|
|
46
|
+
"@xylabs/react-animation": "^6.2.11",
|
|
47
|
+
"@xylabs/react-error": "^6.2.11",
|
|
48
|
+
"@xylabs/react-flexbox": "^6.2.11",
|
|
49
|
+
"@xylabs/react-identicon": "^6.2.11",
|
|
50
|
+
"@xylabs/react-promise": "^6.2.11",
|
|
51
|
+
"@xylabs/react-quick-tip-button": "^6.2.11",
|
|
52
|
+
"@xyo-network/account": "^3.14.13",
|
|
53
|
+
"@xyo-network/api-models": "^3.14.13",
|
|
54
|
+
"@xyo-network/archivist-model": "^3.14.13",
|
|
55
|
+
"@xyo-network/boundwitness-builder": "^3.14.13",
|
|
56
|
+
"@xyo-network/boundwitness-model": "^3.14.13",
|
|
57
|
+
"@xyo-network/bridge-http": "^3.14.13",
|
|
58
|
+
"@xyo-network/chain-ethereum": "^1.3.7",
|
|
59
|
+
"@xyo-network/chain-protocol": "^1.3.7",
|
|
60
|
+
"@xyo-network/chain-services": "^1.3.7",
|
|
61
|
+
"@xyo-network/module-model": "^3.14.13",
|
|
62
|
+
"@xyo-network/payload-builder": "^3.14.13",
|
|
63
|
+
"@xyo-network/payload-model": "^3.14.13",
|
|
64
|
+
"@xyo-network/react-boundwitness-plugin": "^5.2.5",
|
|
65
|
+
"@xyo-network/react-chain-blockies": "^1.3.7",
|
|
66
|
+
"@xyo-network/react-event": "^5.2.5",
|
|
67
|
+
"@xyo-network/react-payload-raw-info": "^5.2.5",
|
|
68
|
+
"@xyo-network/react-payload-table": "^5.2.5",
|
|
69
|
+
"@xyo-network/react-shared": "^5.2.5",
|
|
70
|
+
"@xyo-network/react-table": "^5.2.5",
|
|
71
|
+
"@xyo-network/xl1-model": "^1.3.7",
|
|
72
|
+
"@xyo-network/xl1-protocol": "^1.3.7"
|
|
73
73
|
},
|
|
74
74
|
"devDependencies": {
|
|
75
75
|
"@emotion/react": "^11.14.0",
|
|
@@ -82,8 +82,9 @@
|
|
|
82
82
|
"@xylabs/hex": "^4.8.7",
|
|
83
83
|
"@xylabs/ts-scripts-yarn3": "^6.3.5",
|
|
84
84
|
"@xylabs/tsconfig-react": "^6.3.5",
|
|
85
|
-
"@xyo-network/archivist-memory": "^3.13
|
|
86
|
-
"@xyo-network/chain-utils": "^1.3.
|
|
85
|
+
"@xyo-network/archivist-memory": "^3.14.13",
|
|
86
|
+
"@xyo-network/chain-utils": "^1.3.7",
|
|
87
|
+
"knip": "^5.50.5",
|
|
87
88
|
"react": "^19.1.0",
|
|
88
89
|
"react-dom": "^19.1.0",
|
|
89
90
|
"react-router-dom": "^7.5.2",
|
|
@@ -3,9 +3,11 @@ import {
|
|
|
3
3
|
Link, TableCell, Tooltip,
|
|
4
4
|
} from '@mui/material'
|
|
5
5
|
import type { Hash } from '@xylabs/hex'
|
|
6
|
-
import
|
|
6
|
+
import { isTransactionBoundWitness } from '@xyo-network/xl1-model'
|
|
7
|
+
import React, { useMemo } from 'react'
|
|
7
8
|
|
|
8
9
|
import { useTxsFromBlock } from '../../../../hooks/useTxsFromBlock.ts'
|
|
10
|
+
import { TransactionCountChip } from '../../../transactions/index.ts'
|
|
9
11
|
import { useLinkedBlockItem } from './hooks/index.ts'
|
|
10
12
|
import type { BlockTableCellProps } from './lib/index.ts'
|
|
11
13
|
|
|
@@ -20,6 +22,7 @@ export const BlockTransactionCountTableCell: React.FC<BlockTransactionCountTable
|
|
|
20
22
|
block, linked, ...props
|
|
21
23
|
}) => {
|
|
22
24
|
const [transactions, error] = useTxsFromBlock(block)
|
|
25
|
+
const txHashes = useMemo(() => transactions?.map(([,hash]) => hash), [transactions])
|
|
23
26
|
|
|
24
27
|
const data: BlockTransactionCountEventData | undefined = (block && transactions !== undefined)
|
|
25
28
|
? {
|
|
@@ -40,7 +43,19 @@ export const BlockTransactionCountTableCell: React.FC<BlockTransactionCountTable
|
|
|
40
43
|
</Tooltip>
|
|
41
44
|
)
|
|
42
45
|
: null}
|
|
43
|
-
{linked
|
|
46
|
+
{linked
|
|
47
|
+
? (
|
|
48
|
+
<Link onClick={handleClick} sx={{ cursor: 'pointer' }}>
|
|
49
|
+
<TransactionCountChip
|
|
50
|
+
transactions={txHashes}
|
|
51
|
+
/>
|
|
52
|
+
</Link>
|
|
53
|
+
)
|
|
54
|
+
: (
|
|
55
|
+
<TransactionCountChip
|
|
56
|
+
transactions={txHashes}
|
|
57
|
+
/>
|
|
58
|
+
)}
|
|
44
59
|
</span>
|
|
45
60
|
</TableCell>
|
|
46
61
|
)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import CompareArrowsIcon from '@mui/icons-material/CompareArrows'
|
|
2
2
|
import type { ChipProps } from '@mui/material'
|
|
3
3
|
import { Chip, Icon } from '@mui/material'
|
|
4
4
|
import type { Hash } from '@xylabs/hex'
|
|
@@ -20,10 +20,10 @@ export const TransactionCountChip: React.FC<TransactionCountChipProps> = ({
|
|
|
20
20
|
<Chip
|
|
21
21
|
avatar={(
|
|
22
22
|
<Icon>
|
|
23
|
-
<
|
|
23
|
+
<CompareArrowsIcon />
|
|
24
24
|
</Icon>
|
|
25
25
|
)}
|
|
26
|
-
label={
|
|
26
|
+
label={label}
|
|
27
27
|
title={transactions ? `Block contains ${transactions.length} transactions` : undefined}
|
|
28
28
|
sx={{
|
|
29
29
|
display: 'inline-flex', alignItems: 'center', justifyContent: 'center', ...sx,
|