@xyo-network/react-chain-blockchain 1.3.18 → 1.3.19

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.
Files changed (39) hide show
  1. package/dist/browser/index.mjs +29 -26
  2. package/dist/browser/index.mjs.map +1 -1
  3. package/dist/types/components/transactions/submit/SubmitChain.d.ts.map +1 -1
  4. package/dist/types/context/analyzer/Provider.d.ts.map +1 -1
  5. package/dist/types/context/analyzer/context.d.ts +22 -2
  6. package/dist/types/context/analyzer/context.d.ts.map +1 -1
  7. package/dist/types/context/analyzer/state.d.ts +3 -3
  8. package/dist/types/context/analyzer/state.d.ts.map +1 -1
  9. package/dist/types/context/analyzer/use.d.ts +8 -1
  10. package/dist/types/context/analyzer/use.d.ts.map +1 -1
  11. package/dist/types/context/chain/Context.d.ts +19 -2
  12. package/dist/types/context/chain/Context.d.ts.map +1 -1
  13. package/dist/types/context/chain/State.d.ts +3 -3
  14. package/dist/types/context/chain/State.d.ts.map +1 -1
  15. package/dist/types/context/chain/use.d.ts +7 -1
  16. package/dist/types/context/chain/use.d.ts.map +1 -1
  17. package/dist/types/context/polling/context.d.ts +16 -2
  18. package/dist/types/context/polling/context.d.ts.map +1 -1
  19. package/dist/types/context/polling/state.d.ts +3 -3
  20. package/dist/types/context/polling/state.d.ts.map +1 -1
  21. package/dist/types/context/polling/use.d.ts +6 -1
  22. package/dist/types/context/polling/use.d.ts.map +1 -1
  23. package/dist/types/hooks/chain-iterator/useChainIteratorParams.d.ts +1 -3
  24. package/dist/types/hooks/chain-iterator/useChainIteratorParams.d.ts.map +1 -1
  25. package/package.json +43 -43
  26. package/src/components/block/table/Ex.stories.tsx +2 -2
  27. package/src/components/transactions/submit/SubmitChain.tsx +23 -21
  28. package/src/context/analyzer/Provider.tsx +3 -2
  29. package/src/context/analyzer/context.ts +1 -1
  30. package/src/context/analyzer/state.ts +3 -3
  31. package/src/context/analyzer/use.ts +1 -1
  32. package/src/context/chain/Context.ts +1 -1
  33. package/src/context/chain/Provider.tsx +1 -1
  34. package/src/context/chain/State.ts +3 -3
  35. package/src/context/chain/use.ts +1 -1
  36. package/src/context/polling/Provider.tsx +1 -1
  37. package/src/context/polling/context.ts +1 -1
  38. package/src/context/polling/state.ts +3 -3
  39. package/src/context/polling/use.ts +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"SubmitChain.d.ts","sourceRoot":"","sources":["../../../../../src/components/transactions/submit/SubmitChain.tsx"],"names":[],"mappings":"AAeA,OAAO,KAAmB,MAAM,OAAO,CAAA;AAQvC,eAAO,MAAM,sBAAsB,EAAE,KAAK,CAAC,EA6D1C,CAAA"}
1
+ {"version":3,"file":"SubmitChain.d.ts","sourceRoot":"","sources":["../../../../../src/components/transactions/submit/SubmitChain.tsx"],"names":[],"mappings":"AAeA,OAAO,KAAmB,MAAM,OAAO,CAAA;AAQvC,eAAO,MAAM,sBAAsB,EAAE,KAAK,CAAC,EA+D1C,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"Provider.d.ts","sourceRoot":"","sources":["../../../../src/context/analyzer/Provider.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAA;AAC9C,OAAO,KAEN,MAAM,OAAO,CAAA;AAGd,OAAO,KAAK,EAAE,cAAc,EAAuB,MAAM,YAAY,CAAA;AAErE,MAAM,WAAW,2BAA4B,SAAQ,iBAAiB;IACpE,SAAS,CAAC,EAAE,cAAc,CAAA;CAC3B;AAED,eAAO,MAAM,sBAAsB,EAAE,KAAK,CAAC,EAAE,CAAC,2BAA2B,CA0BxE,CAAA"}
1
+ {"version":3,"file":"Provider.d.ts","sourceRoot":"","sources":["../../../../src/context/analyzer/Provider.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAA;AAC9C,OAAO,KAEN,MAAM,OAAO,CAAA;AAGd,OAAO,KAAK,EAAE,cAAc,EAAuB,MAAM,YAAY,CAAA;AAErE,MAAM,WAAW,2BAA4B,SAAQ,iBAAiB;IACpE,SAAS,CAAC,EAAE,cAAc,CAAA;CAC3B;AAED,eAAO,MAAM,sBAAsB,EAAE,KAAK,CAAC,EAAE,CAAC,2BAA2B,CA0BxE,CAAA"}
@@ -1,3 +1,23 @@
1
- import type { ChainAnalyzersState } from './state.ts';
2
- export declare const ChainAnalyzersContext: import("react").Context<ChainAnalyzersState & import("@xyo-network/react-shared").ContextExState>;
1
+ export declare const ChainAnalyzersContext: import("react").Context<({
2
+ addAnalyzers: (analyzers: import("./state.ts").ChainAnalyzers) => void;
3
+ analyzers: import("./state.ts").ChainAnalyzers;
4
+ onBlock: (block: import("@xyo-network/xl1-protocol").HydratedBlock) => Promise<void>;
5
+ statsUpdated: number;
6
+ } & {
7
+ provided: true;
8
+ }) | (import("@xylabs/react-shared").FixedValues<import("@xylabs/react-shared").ProvidedContextExState<{
9
+ addAnalyzers: (analyzers: import("./state.ts").ChainAnalyzers) => void;
10
+ analyzers: import("./state.ts").ChainAnalyzers;
11
+ onBlock: (block: import("@xyo-network/xl1-protocol").HydratedBlock) => Promise<void>;
12
+ statsUpdated: number;
13
+ }>, never> & {
14
+ provided: false;
15
+ }) | (import("@xylabs/react-shared").FixedValues<import("@xylabs/react-shared").NotProvidedContextExState<{
16
+ addAnalyzers: (analyzers: import("./state.ts").ChainAnalyzers) => void;
17
+ analyzers: import("./state.ts").ChainAnalyzers;
18
+ onBlock: (block: import("@xyo-network/xl1-protocol").HydratedBlock) => Promise<void>;
19
+ statsUpdated: number;
20
+ }>, never> & {
21
+ provided: false;
22
+ })>;
3
23
  //# sourceMappingURL=context.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../../src/context/analyzer/context.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAA;AAErD,eAAO,MAAM,qBAAqB,mGAAyC,CAAA"}
1
+ {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../../src/context/analyzer/context.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;GAAyC,CAAA"}
@@ -1,11 +1,11 @@
1
- import type { ContextExState } from '@xyo-network/react-shared';
1
+ import type { ContextExState } from '@xylabs/react-shared';
2
2
  import type { ChainAnalyzer, HydratedBlock } from '@xyo-network/xl1-protocol';
3
3
  export type ChainAnalyzerIds = 'producers';
4
4
  export type ChainAnalyzers = Record<ChainAnalyzerIds, ChainAnalyzer>;
5
- export interface ChainAnalyzersState extends ContextExState {
5
+ export type ChainAnalyzersState = ContextExState<{
6
6
  addAnalyzers: (analyzers: ChainAnalyzers) => void;
7
7
  analyzers: ChainAnalyzers;
8
8
  onBlock: (block: HydratedBlock) => Promise<void>;
9
9
  statsUpdated: number;
10
- }
10
+ }>;
11
11
  //# sourceMappingURL=state.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../../../src/context/analyzer/state.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAA;AAC/D,OAAO,KAAK,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAA;AAE7E,MAAM,MAAM,gBAAgB,GAAG,WAAW,CAAA;AAE1C,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,gBAAgB,EAAE,aAAa,CAAC,CAAA;AAEpE,MAAM,WAAW,mBAAoB,SAAQ,cAAc;IACzD,YAAY,EAAE,CAAC,SAAS,EAAE,cAAc,KAAK,IAAI,CAAA;IACjD,SAAS,EAAE,cAAc,CAAA;IACzB,OAAO,EAAE,CAAC,KAAK,EAAE,aAAa,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;IAChD,YAAY,EAAE,MAAM,CAAA;CACrB"}
1
+ {"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../../../src/context/analyzer/state.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAC1D,OAAO,KAAK,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAA;AAE7E,MAAM,MAAM,gBAAgB,GAAG,WAAW,CAAA;AAE1C,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,gBAAgB,EAAE,aAAa,CAAC,CAAA;AAEpE,MAAM,MAAM,mBAAmB,GAAG,cAAc,CAAC;IAC/C,YAAY,EAAE,CAAC,SAAS,EAAE,cAAc,KAAK,IAAI,CAAA;IACjD,SAAS,EAAE,cAAc,CAAA;IACzB,OAAO,EAAE,CAAC,KAAK,EAAE,aAAa,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;IAChD,YAAY,EAAE,MAAM,CAAA;CACrB,CAAC,CAAA"}
@@ -1,3 +1,10 @@
1
1
  import type { ChainAnalyzersState } from './state.ts';
2
- export declare const useChainAnalyzersContext: (required?: boolean) => Omit<ChainAnalyzersState, "provided">;
2
+ export declare const useChainAnalyzersContext: (required?: boolean) => Omit<{
3
+ addAnalyzers: (analyzers: import("./state.ts").ChainAnalyzers) => void;
4
+ analyzers: import("./state.ts").ChainAnalyzers;
5
+ onBlock: (block: import("@xyo-network/xl1-protocol").HydratedBlock) => Promise<void>;
6
+ statsUpdated: number;
7
+ } & {
8
+ provided: true;
9
+ }, "provided"> | Omit<import("@xylabs/react-shared").NotProvidedContextExState<ChainAnalyzersState>, "provided">;
3
10
  //# sourceMappingURL=use.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"use.d.ts","sourceRoot":"","sources":["../../../../src/context/analyzer/use.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAA;AAErD,eAAO,MAAM,wBAAwB,GAAI,kBAAgB,0CAAyF,CAAA"}
1
+ {"version":3,"file":"use.d.ts","sourceRoot":"","sources":["../../../../src/context/analyzer/use.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAA;AAErD,eAAO,MAAM,wBAAwB,GAAI,kBAAgB;;;;;;;gHAAyF,CAAA"}
@@ -1,3 +1,20 @@
1
- import type { ChainInfoState } from './State.ts';
2
- export declare const ChainInfoContext: import("react").Context<ChainInfoState & import("@xyo-network/react-shared").ContextExState>;
1
+ export declare const ChainInfoContext: import("react").Context<({
2
+ chainArchivist?: import("@xyo-network/archivist-model").ArchivistInstance;
3
+ chainInformation?: import("@xyo-network/xl1-protocol").ChainInformation;
4
+ chainIterator?: import("@xyo-network/xl1-protocol").ChainBlockNumberIterator;
5
+ } & {
6
+ provided: true;
7
+ }) | (import("@xylabs/react-shared").FixedValues<import("@xylabs/react-shared").ProvidedContextExState<{
8
+ chainArchivist?: import("@xyo-network/archivist-model").ArchivistInstance;
9
+ chainInformation?: import("@xyo-network/xl1-protocol").ChainInformation;
10
+ chainIterator?: import("@xyo-network/xl1-protocol").ChainBlockNumberIterator;
11
+ }>, never> & {
12
+ provided: false;
13
+ }) | (import("@xylabs/react-shared").FixedValues<import("@xylabs/react-shared").NotProvidedContextExState<{
14
+ chainArchivist?: import("@xyo-network/archivist-model").ArchivistInstance;
15
+ chainInformation?: import("@xyo-network/xl1-protocol").ChainInformation;
16
+ chainIterator?: import("@xyo-network/xl1-protocol").ChainBlockNumberIterator;
17
+ }>, never> & {
18
+ provided: false;
19
+ })>;
3
20
  //# sourceMappingURL=Context.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Context.d.ts","sourceRoot":"","sources":["../../../../src/context/chain/Context.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAA;AAEhD,eAAO,MAAM,gBAAgB,8FAAoC,CAAA"}
1
+ {"version":3,"file":"Context.d.ts","sourceRoot":"","sources":["../../../../src/context/chain/Context.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;GAAoC,CAAA"}
@@ -1,9 +1,9 @@
1
+ import type { ContextExState } from '@xylabs/react-shared';
1
2
  import type { ArchivistInstance } from '@xyo-network/archivist-model';
2
- import type { ContextExState } from '@xyo-network/react-shared';
3
3
  import type { ChainBlockNumberIterator, ChainInformation } from '@xyo-network/xl1-protocol';
4
- export interface ChainInfoState extends ContextExState {
4
+ export type ChainInfoState = ContextExState<{
5
5
  chainArchivist?: ArchivistInstance;
6
6
  chainInformation?: ChainInformation;
7
7
  chainIterator?: ChainBlockNumberIterator;
8
- }
8
+ }>;
9
9
  //# sourceMappingURL=State.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"State.d.ts","sourceRoot":"","sources":["../../../../src/context/chain/State.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAA;AACrE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAA;AAC/D,OAAO,KAAK,EAAE,wBAAwB,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAA;AAE3F,MAAM,WAAW,cAAe,SAAQ,cAAc;IACpD,cAAc,CAAC,EAAE,iBAAiB,CAAA;IAClC,gBAAgB,CAAC,EAAE,gBAAgB,CAAA;IACnC,aAAa,CAAC,EAAE,wBAAwB,CAAA;CACzC"}
1
+ {"version":3,"file":"State.d.ts","sourceRoot":"","sources":["../../../../src/context/chain/State.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAC1D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAA;AACrE,OAAO,KAAK,EAAE,wBAAwB,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAA;AAE3F,MAAM,MAAM,cAAc,GAAG,cAAc,CAAC;IAC1C,cAAc,CAAC,EAAE,iBAAiB,CAAA;IAClC,gBAAgB,CAAC,EAAE,gBAAgB,CAAA;IACnC,aAAa,CAAC,EAAE,wBAAwB,CAAA;CACzC,CAAC,CAAA"}
@@ -1,3 +1,9 @@
1
1
  import type { ChainInfoState } from './State.ts';
2
- export declare const useChainInfo: (required?: boolean) => Omit<ChainInfoState, "provided">;
2
+ export declare const useChainInfo: (required?: boolean) => Omit<{
3
+ chainArchivist?: import("@xyo-network/archivist-model").ArchivistInstance;
4
+ chainInformation?: import("@xyo-network/xl1-protocol").ChainInformation;
5
+ chainIterator?: import("@xyo-network/xl1-protocol").ChainBlockNumberIterator;
6
+ } & {
7
+ provided: true;
8
+ }, "provided"> | Omit<import("@xylabs/react-shared").NotProvidedContextExState<ChainInfoState>, "provided">;
3
9
  //# sourceMappingURL=use.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"use.d.ts","sourceRoot":"","sources":["../../../../src/context/chain/use.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAA;AAEhD,eAAO,MAAM,YAAY,GAAI,kBAAgB,qCAA2E,CAAA"}
1
+ {"version":3,"file":"use.d.ts","sourceRoot":"","sources":["../../../../src/context/chain/use.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAA;AAEhD,eAAO,MAAM,YAAY,GAAI,kBAAgB;;;;;;2GAA2E,CAAA"}
@@ -1,3 +1,17 @@
1
- import type { ChainPollingState } from './state.ts';
2
- export declare const ChainPollingContext: import("react").Context<ChainPollingState & import("@xyo-network/react-shared").ContextExState>;
1
+ export declare const ChainPollingContext: import("react").Context<({
2
+ pollingState?: import("./state.ts").PollingState;
3
+ updatePollingState?: (newState: import("./state.ts").PollingState) => void;
4
+ } & {
5
+ provided: true;
6
+ }) | (import("@xylabs/react-shared").FixedValues<import("@xylabs/react-shared").ProvidedContextExState<{
7
+ pollingState?: import("./state.ts").PollingState;
8
+ updatePollingState?: (newState: import("./state.ts").PollingState) => void;
9
+ }>, never> & {
10
+ provided: false;
11
+ }) | (import("@xylabs/react-shared").FixedValues<import("@xylabs/react-shared").NotProvidedContextExState<{
12
+ pollingState?: import("./state.ts").PollingState;
13
+ updatePollingState?: (newState: import("./state.ts").PollingState) => void;
14
+ }>, never> & {
15
+ provided: false;
16
+ })>;
3
17
  //# sourceMappingURL=context.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../../src/context/polling/context.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAEnD,eAAO,MAAM,mBAAmB,iGAAuC,CAAA"}
1
+ {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../../src/context/polling/context.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;GAAuC,CAAA"}
@@ -1,7 +1,7 @@
1
- import type { ContextExState } from '@xyo-network/react-shared';
1
+ import type { ContextExState } from '@xylabs/react-shared';
2
2
  export type PollingState = 'paused' | 'running';
3
- export interface ChainPollingState extends ContextExState {
3
+ export type ChainPollingState = ContextExState<{
4
4
  pollingState?: PollingState;
5
5
  updatePollingState?: (newState: PollingState) => void;
6
- }
6
+ }>;
7
7
  //# sourceMappingURL=state.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../../../src/context/polling/state.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAA;AAE/D,MAAM,MAAM,YAAY,GAAG,QAAQ,GAAG,SAAS,CAAA;AAE/C,MAAM,WAAW,iBAAkB,SAAQ,cAAc;IACvD,YAAY,CAAC,EAAE,YAAY,CAAA;IAC3B,kBAAkB,CAAC,EAAE,CAAC,QAAQ,EAAE,YAAY,KAAK,IAAI,CAAA;CACtD"}
1
+ {"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../../../src/context/polling/state.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAE1D,MAAM,MAAM,YAAY,GAAG,QAAQ,GAAG,SAAS,CAAA;AAE/C,MAAM,MAAM,iBAAiB,GAAG,cAAc,CAAC;IAC7C,YAAY,CAAC,EAAE,YAAY,CAAA;IAC3B,kBAAkB,CAAC,EAAE,CAAC,QAAQ,EAAE,YAAY,KAAK,IAAI,CAAA;CACtD,CAAC,CAAA"}
@@ -1,2 +1,7 @@
1
- export declare const useChainPollingContext: (required?: boolean) => Omit<import("./state.ts").ChainPollingState & import("@xyo-network/react-shared").ContextExState, "provided">;
1
+ export declare const useChainPollingContext: (required?: boolean) => Omit<{
2
+ pollingState?: import("./state.ts").PollingState;
3
+ updatePollingState?: (newState: import("./state.ts").PollingState) => void;
4
+ } & {
5
+ provided: true;
6
+ }, "provided"> | Omit<import("@xylabs/react-shared").NotProvidedContextExState<import("./state.ts").ChainPollingState>, "provided">;
2
7
  //# sourceMappingURL=use.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"use.d.ts","sourceRoot":"","sources":["../../../../src/context/polling/use.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,sBAAsB,GAAI,kBAAgB,kHAAgE,CAAA"}
1
+ {"version":3,"file":"use.d.ts","sourceRoot":"","sources":["../../../../src/context/polling/use.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,sBAAsB,GAAI,kBAAgB;;;;;mIAAgE,CAAA"}
@@ -12,9 +12,7 @@ export declare const useChainIteratorParams: ({ chainArchivist, chainInformation
12
12
  config: import("@xyo-network/module-model").AnyConfigSchema<import("@xyo-network/archivist-model").ArchivistConfig>;
13
13
  ephemeralQueryAccountEnabled?: boolean;
14
14
  moduleIdentifierTransformers?: import("@xyo-network/module-model").ModuleIdentifierTransformer[];
15
- privateChildren?: import("@xyo-network/module-model").ModuleInstance[];
16
- publicChildren?: import("@xyo-network/module-model").ModuleInstance[];
17
- } & import("@xyo-network/archivist-model").ArchivistParamFields & object, import("@xyo-network/archivist-model").ArchivistModuleEventData, import("@xyo-network/payload-model").Payload>;
15
+ } & import("@xyo-network/module-model").ModuleChildrenParams & import("@xyo-network/archivist-model").ArchivistParamFields & object, import("@xyo-network/archivist-model").ArchivistModuleEventData, import("@xyo-network/payload-model").Payload>;
18
16
  chainInformation: import("@xyo-network/xl1-protocol").ChainInformation;
19
17
  head: import("@xylabs/object").DeepRestrictToStringKeys<import("@xyo-network/payload-model").SchemaFields & import("@xyo-network/payload-model").PayloadFields & {
20
18
  schema: string;
@@ -1 +1 @@
1
- {"version":3,"file":"useChainIteratorParams.d.ts","sourceRoot":"","sources":["../../../../src/hooks/chain-iterator/useChainIteratorParams.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,IAAI,EAAU,MAAM,aAAa,CAAA;AAE/C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAA;AAEjE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAA;AAGlE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAA;AAE9D,eAAO,MAAM,kBAAkB,GAAU,MAAM,IAAI,EAAE,gBAAgB,aAAa,iFAajF,CAAA;AAED,eAAO,MAAM,sBAAsB,GAAI,6CAEpC,kBAAkB;;;;;;;;;;;;;;;;;;;;8FAcpB,CAAA"}
1
+ {"version":3,"file":"useChainIteratorParams.d.ts","sourceRoot":"","sources":["../../../../src/hooks/chain-iterator/useChainIteratorParams.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,IAAI,EAAU,MAAM,aAAa,CAAA;AAE/C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAA;AAEjE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAA;AAGlE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAA;AAE9D,eAAO,MAAM,kBAAkB,GAAU,MAAM,IAAI,EAAE,gBAAgB,aAAa,iFAajF,CAAA;AAED,eAAO,MAAM,sBAAsB,GAAI,6CAEpC,kBAAkB;;;;;;;;;;;;;;;;;;8FAcpB,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.18",
4
+ "version": "1.3.19",
5
5
  "description": "XYO Layer One React SDK Blockchain",
6
6
  "homepage": "https://xylabs.com",
7
7
  "bugs": {
@@ -37,40 +37,40 @@
37
37
  "package-cycle": "echo Nothing to do"
38
38
  },
39
39
  "dependencies": {
40
- "@xylabs/assert": "^4.9.4",
41
- "@xylabs/axios": "^4.9.4",
42
- "@xylabs/eth-address": "^4.9.4",
43
- "@xylabs/exists": "^4.9.4",
44
- "@xylabs/hex": "^4.9.4",
45
- "@xylabs/promise": "^4.9.4",
46
- "@xylabs/react-animation": "^6.2.19",
47
- "@xylabs/react-error": "^6.2.19",
48
- "@xylabs/react-flexbox": "^6.2.19",
49
- "@xylabs/react-identicon": "^6.2.19",
50
- "@xylabs/react-promise": "^6.2.19",
51
- "@xylabs/react-quick-tip-button": "^6.2.19",
52
- "@xylabs/react-theme": "^6.2.19",
53
- "@xyo-network/account": "^3.14.18",
54
- "@xyo-network/archivist-model": "^3.14.18",
55
- "@xyo-network/boundwitness-builder": "^3.14.18",
56
- "@xyo-network/boundwitness-model": "^3.14.18",
57
- "@xyo-network/bridge-http": "^3.14.18",
58
- "@xyo-network/chain-analyze": "^1.3.18",
59
- "@xyo-network/chain-protocol": "^1.3.18",
60
- "@xyo-network/chain-services": "^1.3.18",
61
- "@xyo-network/chain-wrappers": "^1.3.18",
62
- "@xyo-network/module-model": "^3.14.18",
63
- "@xyo-network/payload-builder": "^3.14.18",
64
- "@xyo-network/payload-model": "^3.14.18",
65
- "@xyo-network/react-boundwitness-plugin": "^5.2.8",
66
- "@xyo-network/react-chain-blockies": "^1.3.18",
67
- "@xyo-network/react-event": "^5.2.8",
68
- "@xyo-network/react-payload-raw-info": "^5.2.8",
69
- "@xyo-network/react-payload-table": "^5.2.8",
70
- "@xyo-network/react-shared": "^5.2.8",
71
- "@xyo-network/react-table": "^5.2.8",
72
- "@xyo-network/xl1-protocol": "^1.3.12",
73
- "@xyo-network/xl1-protocol-sdk": "^1.3.18"
40
+ "@xylabs/assert": "^4.9.15",
41
+ "@xylabs/axios": "^4.9.15",
42
+ "@xylabs/eth-address": "^4.9.15",
43
+ "@xylabs/exists": "^4.9.15",
44
+ "@xylabs/hex": "^4.9.15",
45
+ "@xylabs/promise": "^4.9.15",
46
+ "@xylabs/react-animation": "^6.3.1",
47
+ "@xylabs/react-error": "^6.3.1",
48
+ "@xylabs/react-flexbox": "^6.3.1",
49
+ "@xylabs/react-identicon": "^6.3.1",
50
+ "@xylabs/react-promise": "^6.3.1",
51
+ "@xylabs/react-quick-tip-button": "^6.3.1",
52
+ "@xylabs/react-theme": "^6.3.1",
53
+ "@xyo-network/account": "^3.15.5",
54
+ "@xyo-network/archivist-model": "^3.15.5",
55
+ "@xyo-network/boundwitness-builder": "^3.15.5",
56
+ "@xyo-network/boundwitness-model": "^3.15.5",
57
+ "@xyo-network/bridge-http": "^3.15.5",
58
+ "@xyo-network/chain-analyze": "^1.3.19",
59
+ "@xyo-network/chain-protocol": "^1.3.19",
60
+ "@xyo-network/chain-services": "^1.3.19",
61
+ "@xyo-network/chain-wrappers": "^1.3.19",
62
+ "@xyo-network/module-model": "^3.15.5",
63
+ "@xyo-network/payload-builder": "^3.15.5",
64
+ "@xyo-network/payload-model": "^3.15.5",
65
+ "@xyo-network/react-boundwitness-plugin": "^5.3.2",
66
+ "@xyo-network/react-chain-blockies": "^1.3.19",
67
+ "@xyo-network/react-event": "^5.3.2",
68
+ "@xyo-network/react-payload-raw-info": "^5.3.2",
69
+ "@xyo-network/react-payload-table": "^5.3.2",
70
+ "@xyo-network/react-shared": "^5.3.2",
71
+ "@xyo-network/react-table": "^5.3.2",
72
+ "@xyo-network/xl1-protocol": "^1.3.13",
73
+ "@xyo-network/xl1-protocol-sdk": "^1.3.19"
74
74
  },
75
75
  "devDependencies": {
76
76
  "@emotion/react": "^11.14.0",
@@ -78,16 +78,16 @@
78
78
  "@mui/icons-material": "^7.1.0",
79
79
  "@mui/material": "^7.1.0",
80
80
  "@storybook/react": "^8.6.12",
81
- "@types/react": "^19.1.3",
82
- "@xylabs/delay": "^4.9.4",
83
- "@xylabs/hex": "^4.9.4",
81
+ "@types/react": "^19.1.4",
82
+ "@xylabs/delay": "^4.9.15",
83
+ "@xylabs/hex": "^4.9.15",
84
84
  "@xylabs/ts-scripts-yarn3": "^6.5.5",
85
85
  "@xylabs/tsconfig-react": "^6.5.5",
86
- "@xyo-network/api-models": "^3.14.18",
87
- "@xyo-network/archivist-memory": "^3.14.18",
88
- "@xyo-network/chain-ethereum": "^1.3.18",
89
- "@xyo-network/chain-utils": "^1.3.18",
90
- "@xyo-network/react-chain-shared": "^1.3.18",
86
+ "@xyo-network/api-models": "^3.15.5",
87
+ "@xyo-network/archivist-memory": "^3.15.5",
88
+ "@xyo-network/chain-ethereum": "^1.3.19",
89
+ "@xyo-network/chain-utils": "^1.3.19",
90
+ "@xyo-network/react-chain-shared": "^1.3.19",
91
91
  "knip": "^5.55.1",
92
92
  "react": "^19.1.0",
93
93
  "react-dom": "^19.1.0",
@@ -3,7 +3,7 @@ import {
3
3
  } from '@mui/material'
4
4
  import type { Meta, StoryFn } from '@storybook/react'
5
5
  import { buildRandomBlockChain } from '@xyo-network/react-chain-shared'
6
- import type { Event } from '@xyo-network/react-event'
6
+ import type { Event, EventNoun } from '@xyo-network/react-event'
7
7
  import { useEvent } from '@xyo-network/react-event'
8
8
  import React, { useState } from 'react'
9
9
 
@@ -22,7 +22,7 @@ const Template: StoryFn<typeof BlockchainTableEx> = args => <BlockchainTableEx {
22
22
  const TemplateLinked: StoryFn<typeof BlockchainTableEx> = (args) => {
23
23
  const [event, setEvent] = useState<Event>()
24
24
  const [ref] = useEvent<HTMLTableElement>((noun, verb, data) => setEvent({
25
- noun, verb, data,
25
+ noun: noun as EventNoun, verb, data,
26
26
  }))
27
27
  return (
28
28
  <>
@@ -22,33 +22,35 @@ const BETA_PENDING_TRANSACTIONS_ARCHIVIST = 'https://beta.api.chain.xyo.network/
22
22
  const defaultNetwork = new URL(BETA_PENDING_TRANSACTIONS_ARCHIVIST)
23
23
 
24
24
  export const SubmitChainTransaction: React.FC = () => {
25
- const [network, setNetwork] = useState<URL>(defaultNetwork)
25
+ const [network, setNetwork] = useState<URL | undefined>(defaultNetwork)
26
26
  const [result, setResult] = useState<ModuleQueryResult>()
27
27
  const [error, setError] = useState<Error>()
28
28
 
29
29
  const onSubmitTx = async (chainTx: TransactionBoundWitnessFields) => {
30
- const randomAccount = await Account.random()
31
- const [transactionBoundWitness] = await buildTransaction(
32
- chainTx.chain,
33
- [],
34
- [],
35
- randomAccount,
36
- chainTx.nbf,
37
- chainTx.exp,
38
- )
30
+ if (network) {
31
+ const randomAccount = await Account.random()
32
+ const [transactionBoundWitness] = await buildTransaction(
33
+ chainTx.chain,
34
+ [],
35
+ [],
36
+ randomAccount,
37
+ chainTx.nbf,
38
+ chainTx.exp,
39
+ )
39
40
 
40
- const insertQuery = new PayloadBuilder({ schema: ArchivistInsertQuerySchema }).build()
41
- const [queryBoundWitness] = await new QueryBoundWitnessBuilder()
42
- .payloads([transactionBoundWitness as Payload])
43
- .query(insertQuery)
44
- .signer(randomAccount)
45
- .build()
41
+ const insertQuery = new PayloadBuilder({ schema: ArchivistInsertQuerySchema }).build()
42
+ const [queryBoundWitness] = await new QueryBoundWitnessBuilder()
43
+ .payloads([transactionBoundWitness as Payload])
44
+ .query(insertQuery)
45
+ .signer(randomAccount)
46
+ .build()
46
47
 
47
- const response = await axios.post<ApiEnvelope<ModuleQueryResult>>(network.href, [queryBoundWitness, [insertQuery, transactionBoundWitness, chainTx]])
48
- if (response.data.errors.length > 0) {
49
- setError(new Error(response.data.errors.map(e => e.message).join('\n')))
50
- } else {
51
- setResult(response.data.data)
48
+ const response = await axios.post<ApiEnvelope<ModuleQueryResult>>(network.href, [queryBoundWitness, [insertQuery, transactionBoundWitness, chainTx]])
49
+ if (response.data.errors.length > 0) {
50
+ setError(new Error(response.data.errors.map(e => e.message).join('\n')))
51
+ } else {
52
+ setResult(response.data.data)
53
+ }
52
54
  }
53
55
  }
54
56
 
@@ -1,3 +1,4 @@
1
+ import { isUndefined } from '@xylabs/typeof'
1
2
  import type { HydratedBlock } from '@xyo-network/xl1-protocol'
2
3
  import type { PropsWithChildren } from 'react'
3
4
  import React, {
@@ -18,7 +19,7 @@ export const ChainAnalyzersProvider: React.FC<ChainAnalyzersProviderProps> = ({
18
19
  const analyzers = useMemo(() => ({ ...analyzersProp, ...analyzersState }), [analyzersProp])
19
20
 
20
21
  const addAnalyzers: ChainAnalyzersState['addAnalyzers'] = useCallback((analyzers: ChainAnalyzersState['analyzers']) => {
21
- if (!analyzers) return
22
+ if (isUndefined(analyzers)) return
22
23
  setAnalyzersState(prev => ({ ...prev, ...analyzers }))
23
24
  }, [])
24
25
 
@@ -30,7 +31,7 @@ export const ChainAnalyzersProvider: React.FC<ChainAnalyzersProviderProps> = ({
30
31
  }
31
32
  }, [analyzers])
32
33
 
33
- const value = useMemo(() => ({
34
+ const value: ChainAnalyzersState = useMemo(() => ({
34
35
  analyzers, addAnalyzers, onBlock, statsUpdated, provided: true,
35
36
  }), [analyzers, addAnalyzers, onBlock, statsUpdated])
36
37
 
@@ -1,4 +1,4 @@
1
- import { createContextEx } from '@xyo-network/react-shared'
1
+ import { createContextEx } from '@xylabs/react-shared'
2
2
 
3
3
  import type { ChainAnalyzersState } from './state.ts'
4
4
 
@@ -1,13 +1,13 @@
1
- import type { ContextExState } from '@xyo-network/react-shared'
1
+ import type { ContextExState } from '@xylabs/react-shared'
2
2
  import type { ChainAnalyzer, HydratedBlock } from '@xyo-network/xl1-protocol'
3
3
 
4
4
  export type ChainAnalyzerIds = 'producers'
5
5
 
6
6
  export type ChainAnalyzers = Record<ChainAnalyzerIds, ChainAnalyzer>
7
7
 
8
- export interface ChainAnalyzersState extends ContextExState {
8
+ export type ChainAnalyzersState = ContextExState<{
9
9
  addAnalyzers: (analyzers: ChainAnalyzers) => void
10
10
  analyzers: ChainAnalyzers
11
11
  onBlock: (block: HydratedBlock) => Promise<void>
12
12
  statsUpdated: number
13
- }
13
+ }>
@@ -1,4 +1,4 @@
1
- import { useContextEx } from '@xyo-network/react-shared'
1
+ import { useContextEx } from '@xylabs/react-shared'
2
2
 
3
3
  import { ChainAnalyzersContext } from './context.ts'
4
4
  import type { ChainAnalyzersState } from './state.ts'
@@ -1,4 +1,4 @@
1
- import { createContextEx } from '@xyo-network/react-shared'
1
+ import { createContextEx } from '@xylabs/react-shared'
2
2
 
3
3
  import type { ChainInfoState } from './State.ts'
4
4
 
@@ -36,7 +36,7 @@ export const ChainInfoProvider: React.FC<ChainInfoProviderProps> = ({
36
36
  updateChainIterator(chainIteratorProp)
37
37
  }, [chainIteratorProp])
38
38
 
39
- const chainState = useMemo(() => ({
39
+ const chainState: ChainInfoState = useMemo(() => ({
40
40
  chainArchivist,
41
41
  chainInformation,
42
42
  chainIterator,
@@ -1,9 +1,9 @@
1
+ import type { ContextExState } from '@xylabs/react-shared'
1
2
  import type { ArchivistInstance } from '@xyo-network/archivist-model'
2
- import type { ContextExState } from '@xyo-network/react-shared'
3
3
  import type { ChainBlockNumberIterator, ChainInformation } from '@xyo-network/xl1-protocol'
4
4
 
5
- export interface ChainInfoState extends ContextExState {
5
+ export type ChainInfoState = ContextExState<{
6
6
  chainArchivist?: ArchivistInstance
7
7
  chainInformation?: ChainInformation
8
8
  chainIterator?: ChainBlockNumberIterator
9
- }
9
+ }>
@@ -1,4 +1,4 @@
1
- import { useContextEx } from '@xyo-network/react-shared'
1
+ import { useContextEx } from '@xylabs/react-shared'
2
2
 
3
3
  import { ChainInfoContext } from './Context.ts'
4
4
  import type { ChainInfoState } from './State.ts'
@@ -17,7 +17,7 @@ export const ChainPollingProvider: React.FC<ChainPollingProviderProps> = ({ chil
17
17
  setPollingState(newPollingState)
18
18
  }, [])
19
19
 
20
- const value = useMemo<ChainPollingState>(() => ({
20
+ const value: ChainPollingState = useMemo(() => ({
21
21
  pollingState,
22
22
  provided: true,
23
23
  updatePollingState,
@@ -1,4 +1,4 @@
1
- import { createContextEx } from '@xyo-network/react-shared'
1
+ import { createContextEx } from '@xylabs/react-shared'
2
2
 
3
3
  import type { ChainPollingState } from './state.ts'
4
4
 
@@ -1,8 +1,8 @@
1
- import type { ContextExState } from '@xyo-network/react-shared'
1
+ import type { ContextExState } from '@xylabs/react-shared'
2
2
 
3
3
  export type PollingState = 'paused' | 'running'
4
4
 
5
- export interface ChainPollingState extends ContextExState {
5
+ export type ChainPollingState = ContextExState<{
6
6
  pollingState?: PollingState
7
7
  updatePollingState?: (newState: PollingState) => void
8
- }
8
+ }>
@@ -1,4 +1,4 @@
1
- import { useContextEx } from '@xyo-network/react-shared'
1
+ import { useContextEx } from '@xylabs/react-shared'
2
2
 
3
3
  import { ChainPollingContext } from './context.ts'
4
4