Skip to content
This repository has been archived by the owner on Feb 2, 2025. It is now read-only.

Commit

Permalink
Merge pull request #274 from TrueBlocks/develop
Browse files Browse the repository at this point in the history
Merges in changes for datastore worker
  • Loading branch information
tjayrush authored May 30, 2022
2 parents 2669557 + 9b28ca4 commit 7c5780c
Show file tree
Hide file tree
Showing 69 changed files with 2,165 additions and 909 deletions.
16 changes: 16 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="refresh" content="7; url='http://localhost:1234'" />
</head>
<body bgcolor="black">
<center>
<p>
<br><br>
<h1><font color="white"><p color="white">TrueBlocks Account Explorer</font></h1>
<img src="loading.gif">
<p>
<font size="+1" color="orangeyellow">Please wait while we load the world's<br>only truly-decentralized <font color="white">Account Explorer</font></font>
</center>
</body>
</html>
1 change: 1 addition & 0 deletions jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,6 @@ module.exports = {
'@components/(.*)': ['<rootDir>/src/ui/components/$1'],
'@hooks/(.*)': ['<rootDir>/src/ui/hooks/$1'],
'@modules/(.*)': ['<rootDir>/src/ui/modules/$1'],
'@sdk': ['<rootDir>/src/sdk/generated_ts'],
},
};
Binary file added loading.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"homepage": "./",
"private": true,
"scripts": {
"start": "concurrently 'yarn develop:ui' 'open http://localhost:1234'",
"start": "concurrently 'yarn develop:ui' 'open index.html'",
"compile:ui": "webpack --mode production",
"develop:ui": "webpack serve --mode development --port 1234",
"compile:electron": "tsc -p tsconfig_electron.json",
Expand Down Expand Up @@ -67,6 +67,7 @@
"antd": "^4.14.0",
"browserslist": "^4.19.1",
"classnames": "^2.3.0",
"comlink": "^4.3.1",
"dayjs": "^1.10.6",
"dotenv": "^8.2.0",
"dotenv-safe": "^8.2.0",
Expand Down
4 changes: 2 additions & 2 deletions src/sdk/generated_ts/paths/blocks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ export function getBlocks(
topic?: topic[],
count?: boolean,
cache?: boolean,
list?: blknum,
listCount?: blknum,
list?: number,
listCount?: number,
chain: string,
noHeader?: boolean,
fmt?: string,
Expand Down
7 changes: 5 additions & 2 deletions src/sdk/generated_ts/paths/chunks.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
import * as ApiCallers from "../lib/api_callers";
import { blknum, PinnedChunk, Manifest } from "../types";
import { blknum, address, PinnedChunk, Manifest } from "../types";

export function getChunks(
parameters?: {
mode: 'stats' | 'pins' | 'blooms' | 'index' | 'addresses' | 'appearances',
blocks?: blknum[],
extract?: 'stats' | 'pins' | 'blooms' | 'index' | 'header' | 'addresses' | 'appearances',
addrs?: address[],
check?: boolean,
belongs?: boolean,
chain: string,
noHeader?: boolean,
fmt?: string,
Expand Down
4 changes: 2 additions & 2 deletions src/sdk/generated_ts/paths/export.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as ApiCallers from "../lib/api_callers";
import { address, topic, fourbyte, Appearance, Reconciliation, Transaction, Receipt, Log, Trace } from "../types";
import { address, topic, fourbyte, Appearance, Reconciliation, ListStats, Transaction, Receipt, Log, Trace } from "../types";

export function getExport(
parameters?: {
Expand Down Expand Up @@ -40,7 +40,7 @@ export function getExport(
},
options?: RequestInit,
) {
return ApiCallers.fetch<Appearance[] | Reconciliation[] | Transaction[] | Receipt[] | Log[] | Trace[]>(
return ApiCallers.fetch<Appearance[] | Reconciliation[] | ListStats[] | Transaction[] | Receipt[] | Log[] | Trace[]>(
{
endpoint: '/export', method: 'get', parameters, options,
},
Expand Down
19 changes: 3 additions & 16 deletions src/sdk/generated_ts/paths/monitors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ export function getMonitors(
parameters?: {
addrs: address[],
clean?: boolean,
delete?: boolean,
undelete?: boolean,
remove?: boolean,
chain: string,
noHeader?: boolean,
fmt?: string,
Expand All @@ -24,19 +27,3 @@ export function getMonitors(
},
);
}
export function deleteMonitors(
parameters?: {
addrs: address[],
delete?: boolean,
undelete?: boolean,
remove?: boolean,
chain: string,
},
options?: RequestInit,
) {
return ApiCallers.fetch<never>(
{
endpoint: '/monitors', method: 'delete', parameters, options,
},
);
}
21 changes: 4 additions & 17 deletions src/sdk/generated_ts/paths/names.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as ApiCallers from "../lib/api_callers";
import { Name, address } from "../types";
import { Name } from "../types";

export function getNames(
parameters?: {
Expand All @@ -13,6 +13,9 @@ export function getNames(
addr?: boolean,
collections?: boolean,
tags?: boolean,
delete?: boolean,
undelete?: boolean,
remove?: boolean,
chain: string,
noHeader?: boolean,
fmt?: string,
Expand All @@ -32,19 +35,3 @@ export function getNames(
},
);
}
export function deleteNames(
parameters?: {
addrs: address[],
delete?: boolean,
undelete?: boolean,
remove?: boolean,
chain: string,
},
options?: RequestInit,
) {
return ApiCallers.fetch<never>(
{
endpoint: '/names', method: 'delete', parameters, options,
},
);
}
2 changes: 0 additions & 2 deletions src/sdk/generated_ts/paths/scrape.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,8 @@ import { PinnedChunk, Manifest } from "../types";
export function getScrape(
parameters?: {
modes: string[],
action?: 'toggle' | 'run' | 'restart' | 'pause' | 'quit',
sleep?: number,
pin?: boolean,
publish?: boolean,
blockCnt?: number,
chain: string,
noHeader?: boolean,
Expand Down
6 changes: 3 additions & 3 deletions src/sdk/generated_ts/paths/when.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import * as ApiCallers from "../lib/api_callers";
import { blknum, DatedBlock } from "../types";
import { DatedBlock } from "../types";

export function getWhen(
parameters?: {
blocks?: blknum[],
timestamps?: boolean,
blocks?: string[],
list?: boolean,
timestamps?: boolean,
chain: string,
noHeader?: boolean,
fmt?: string,
Expand Down
2 changes: 1 addition & 1 deletion src/sdk/generated_ts/types/block.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ export type Block = {
transactions: Transaction[]
baseFeePerGas: wei
finalized: boolean
unclesCnt: number
unclesCnt: uint64
}
4 changes: 2 additions & 2 deletions src/sdk/generated_ts/types/cache.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { uint64, CacheItem } from "../types";
import { uint64, CacheEntry } from "../types";

export type Cache = {
type: string
path: string
nFiles: uint64
nFolders: uint64
sizeInBytes: uint64
items: CacheItem[]
items: CacheEntry[]
}
6 changes: 6 additions & 0 deletions src/sdk/generated_ts/types/cacheEntry.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import { address } from "../types";

export type CacheEntry = {
address: address
name: string
}
5 changes: 2 additions & 3 deletions src/sdk/generated_ts/types/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ export * from './monitor'
export * from './appearance'
export * from './reconciliation'
export * from './name'
export * from './listStats'
export * from './block'
export * from './transaction'
export * from './receipt'
export * from './log'
export * from './articulatedLog'
export * from './trace'
export * from './traceAction'
export * from './traceResult'
Expand All @@ -17,11 +17,10 @@ export * from './result'
export * from './token'
export * from './status'
export * from './cache'
export * from './cacheItem'
export * from './pinnedChunk'
export * from './manifest'
export * from './chain'
export * from './cacheEntry'
export * from './function'
export * from './parameter'
export * from './quote'
export * from './listStats'
6 changes: 3 additions & 3 deletions src/sdk/generated_ts/types/listStats.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { address } from "../types";
import { address, uint64 } from "../types";

export type ListStats = {
address: address
nRecords: number
fileSize: number
nRecords: uint64
fileSize: uint64
}
4 changes: 2 additions & 2 deletions src/sdk/generated_ts/types/log.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { blknum, timestamp, address, topic, bytes, ArticulatedLog } from "../types";
import { blknum, timestamp, address, topic, bytes, Function } from "../types";

export type Log = {
blockNumber: blknum
Expand All @@ -8,6 +8,6 @@ export type Log = {
address: address
topics: topic[]
data: bytes
articulatedLog: ArticulatedLog
articulatedLog: Function
compressedLog: string
}
5 changes: 2 additions & 3 deletions src/sdk/generated_ts/types/monitor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,9 @@ export type Monitor = {
address: address
name: string
isCustom: boolean
deleted: boolean
symbol: string
source: string
decimals: number
decimals: uint64
isContract: boolean
isValid: boolean
deleted: boolean
}
4 changes: 2 additions & 2 deletions src/sdk/generated_ts/types/status.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { timestamp, Cache, Chain } from "../types";
import { timestamp, Chain, Cache } from "../types";

export type Status = {
clientVersion: string
Expand All @@ -18,6 +18,6 @@ export type Status = {
hasEskey: boolean
hasPinkey: boolean
ts: timestamp
caches: Cache[]
chains: Chain[]
caches: Cache[]
}
6 changes: 3 additions & 3 deletions src/sdk/generated_ts/types/transaction.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { hash, gas, blknum, uint64, timestamp, address, wei, bytes, Receipt, Reconciliation, Function } from "../types";
import { gas, hash, blknum, uint64, timestamp, address, wei, bytes, Receipt, Reconciliation, Function, date } from "../types";

export type Transaction = {
hash: hash
gasPrice: gas
hash: hash
blockHash: hash
blockNumber: blknum
transactionIndex: blknum
Expand All @@ -21,5 +21,5 @@ export type Transaction = {
finalized: boolean
extraData: string
isError: boolean
date: string
date: date
}
Loading

0 comments on commit 7c5780c

Please sign in to comment.