@xyo-network/react-chain-blockchain 1.3.13 → 1.3.15
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/README.md +11 -1
- package/dist/browser/index.mjs +3 -16
- package/dist/browser/index.mjs.map +1 -1
- package/dist/types/stories/index.d.ts +0 -1
- package/dist/types/stories/index.d.ts.map +1 -1
- package/package.json +9 -9
- package/src/components/block/BlockHeadingFlexbox.stories.tsx +1 -6
- package/src/components/block/table/Ex.stories.tsx +1 -1
- package/src/components/block/table/cell/TransactionCount.tsx +1 -1
- package/src/components/block/table/row/TableRow.stories.tsx +1 -1
- package/src/stories/ChainArchivistDecorator.tsx +1 -1
- package/src/stories/ChainArchivistDelayedInsertDecorator.tsx +1 -1
- package/src/stories/index.ts +0 -1
- package/dist/types/stories/buildRandomBlockchain.d.ts +0 -4
- package/dist/types/stories/buildRandomBlockchain.d.ts.map +0 -1
- package/src/stories/buildRandomBlockchain.ts +0 -17
package/README.md
CHANGED
|
@@ -1,6 +1,16 @@
|
|
|
1
|
+
# @xyo-network/react-chain-blockchain
|
|
2
|
+
|
|
1
3
|
[![logo][]](https://xyo.network)
|
|
2
4
|
|
|
3
|
-
|
|
5
|
+
Version: 1.3.13
|
|
6
|
+
|
|
7
|
+
XYO Layer One React SDK Blockchain
|
|
8
|
+
|
|
9
|
+
## Documentation
|
|
10
|
+
|
|
11
|
+
[TypeDoc Generated Documentation](https://gitbook.xyo.network/xyo-data-lab/xyo-reference/package-documentation/xyo-network__react-chain-blockchain)
|
|
12
|
+
|
|
13
|
+
Part of [sdk-xyo-client-js](https://www.npmjs.com/package/@xyo-network/sdk-xyo-client-js)
|
|
4
14
|
|
|
5
15
|
## License
|
|
6
16
|
|
package/dist/browser/index.mjs
CHANGED
|
@@ -2126,25 +2126,13 @@ var TransferBuilderFlexbox = /* @__PURE__ */ __name(({ onBuild, ...props }) => /
|
|
|
2126
2126
|
...props
|
|
2127
2127
|
}), "TransferBuilderFlexbox");
|
|
2128
2128
|
|
|
2129
|
-
// src/stories/buildRandomBlockchain.ts
|
|
2130
|
-
import { Account as Account2 } from "@xyo-network/account";
|
|
2131
|
-
import { buildRandomChain } from "@xyo-network/chain-protocol";
|
|
2132
|
-
var buildRandomBlockChain = /* @__PURE__ */ __name(async (blockCount = 10) => {
|
|
2133
|
-
const initialBlockProducer = await Account2.random();
|
|
2134
|
-
const blocks = await buildRandomChain(initialBlockProducer, blockCount);
|
|
2135
|
-
return blocks;
|
|
2136
|
-
}, "buildRandomBlockChain");
|
|
2137
|
-
var buildRandomBlockChainBlocksOnly = /* @__PURE__ */ __name(async (blockCount = 10) => {
|
|
2138
|
-
const chain = await buildRandomChain(await Account2.random(), blockCount);
|
|
2139
|
-
return chain;
|
|
2140
|
-
}, "buildRandomBlockChainBlocksOnly");
|
|
2141
|
-
|
|
2142
2129
|
// src/stories/ChainArchivistDecorator.tsx
|
|
2143
2130
|
import { CircularProgress } from "@mui/material";
|
|
2144
2131
|
import { usePromise as usePromise7 } from "@xylabs/react-promise";
|
|
2145
2132
|
import { MemoryArchivist } from "@xyo-network/archivist-memory";
|
|
2146
2133
|
import { ArchivistConfigSchema } from "@xyo-network/archivist-model";
|
|
2147
2134
|
import { flattenHydratedBlocks } from "@xyo-network/chain-protocol";
|
|
2135
|
+
import { buildRandomBlockChain } from "@xyo-network/react-chain-shared";
|
|
2148
2136
|
import React45, { useEffect as useEffect5 } from "react";
|
|
2149
2137
|
var ChainArchivistDecorator = /* @__PURE__ */ __name((Story, context) => {
|
|
2150
2138
|
const [randomBlockChain] = usePromise7(async () => await buildRandomBlockChain(), []);
|
|
@@ -2195,11 +2183,12 @@ import { usePromise as usePromise8 } from "@xylabs/react-promise";
|
|
|
2195
2183
|
import { MemoryArchivist as MemoryArchivist2 } from "@xyo-network/archivist-memory";
|
|
2196
2184
|
import { ArchivistConfigSchema as ArchivistConfigSchema2 } from "@xyo-network/archivist-model";
|
|
2197
2185
|
import { flattenHydratedBlock } from "@xyo-network/chain-protocol";
|
|
2186
|
+
import { buildRandomBlockChain as buildRandomBlockChain2 } from "@xyo-network/react-chain-shared";
|
|
2198
2187
|
import React46, { useEffect as useEffect6, useState as useState19 } from "react";
|
|
2199
2188
|
var chainArchivistRef;
|
|
2200
2189
|
var ChainArchivistDelayedInsertDecorator = /* @__PURE__ */ __name((Story, context) => {
|
|
2201
2190
|
const [firstBlock, setFirstBlock] = useState19();
|
|
2202
|
-
const [randomBlockChain] = usePromise8(async () => await
|
|
2191
|
+
const [randomBlockChain] = usePromise8(async () => await buildRandomBlockChain2(), []);
|
|
2203
2192
|
const [chainArchivist] = usePromise8(async () => {
|
|
2204
2193
|
if (chainArchivistRef) {
|
|
2205
2194
|
return chainArchivistRef;
|
|
@@ -2336,8 +2325,6 @@ export {
|
|
|
2336
2325
|
XyoAddressTextField,
|
|
2337
2326
|
blockProducer,
|
|
2338
2327
|
buildBlockChainRenderComponent,
|
|
2339
|
-
buildRandomBlockChain,
|
|
2340
|
-
buildRandomBlockChainBlocksOnly,
|
|
2341
2328
|
payloadCountsFromBlock,
|
|
2342
2329
|
resolveDefinedHead,
|
|
2343
2330
|
useAnchorElement,
|