Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: replace algoexplorer #15

Merged
merged 3 commits into from
Jul 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ To interact with this message board you need to send ***0*** (ZERO) Algo transac

This app is currently ***set to testnet***.

The specific address is controlled by Hash: [K22E7O64EMVMBVPUQ53VVXN2U4WCYL7XN6PHOYMNNEBSNM6RMMKJZ3OAMI](https://testnet.algoexplorer.io/address/K22E7O64EMVMBVPUQ53VVXN2U4WCYL7XN6PHOYMNNEBSNM6RMMKJZ3OAMI). Once again, do NOT send any Algo. Specify 0 (ZERO) Algo.
The specific address is controlled by Hash: [K22E7O64EMVMBVPUQ53VVXN2U4WCYL7XN6PHOYMNNEBSNM6RMMKJZ3OAMI](https://testnet.explorer.perawallet.app/address/K22E7O64EMVMBVPUQ53VVXN2U4WCYL7XN6PHOYMNNEBSNM6RMMKJZ3OAMI). Once again, do NOT send any Algo. Specify 0 (ZERO) Algo.

At this stage of the project we are making use of the Algorand indexer's API, which has note-prefix search functionality. In the future something more advanced could be made (e.g. by fiddling with the PostgreSQL, depositing the notes into Elasticsearch, putting it behind a RedisDB Cache) but for now we just make the best of the API available.

Expand Down
8 changes: 4 additions & 4 deletions src/Replies.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,11 @@ function Replies() {
return (
<div>
<Main pad="large">
<Heading><Text><a href={'https://testnet.algoexplorer.io/tx/' + originalTxId}>{originalTxId}</a></Text></Heading>
<Heading><Text><a href={'http://testnet.explorer.perawallet.app/tx/' + originalTxId}>{originalTxId}</a></Text></Heading>
{defineBody(originalTx['note'])}
<Text>Fee: {originalTx['fee']}</Text>
<Text>Block: <a href={'https://testnet.algoexplorer.io/block/' + originalTx['confirmed-round']}>{originalTx['confirmed-round']}</a></Text>
<Text>Sender: <a href={'https://testnet.algoexplorer.io/address/' + originalTx['sender']}>{getShortenedBase32(originalTx['sender'])}</a></Text>
<Text>Block: <a href={'http://testnet.explorer.perawallet.app/block/' + originalTx['confirmed-round']}>{originalTx['confirmed-round']}</a></Text>
<Text>Sender: <a href={'http://testnet.explorer.perawallet.app/address/' + originalTx['sender']}>{getShortenedBase32(originalTx['sender'])}</a></Text>
</Main>

<Page kind="narrow">
Expand All @@ -76,4 +76,4 @@ function Replies() {
)
}

export default Replies;
export default Replies;
4 changes: 2 additions & 2 deletions src/TxCard.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ const TxCard = ({ id, sender, fee, confirmedRound, body }) => {
<CardBody pad="medium"><Box>{body}</Box></CardBody>
<CardFooter pad={{ horizontal: "small" }} background="light-2">
<Text>Fee: {fee}</Text>
<Text>Id: <a href={'https://testnet.algoexplorer.io/tx/' + id}>{getShortenedBase32(id)}</a></Text>
<Text>Id: <a href={'https://testnet.explorer.perawallet.app/tx/' + id}>{getShortenedBase32(id)}</a></Text>
<Text><Link to={`/replies/${id}`}>See Replies</Link></Text>
<Text>Block: <a href={'https://testnet.algoexplorer.io/block/' + confirmedRound}>{confirmedRound}</a></Text>
<Text>Block: <a href={'https://testnet.explorer.perawallet.app/block/' + confirmedRound}>{confirmedRound}</a></Text>
</CardFooter>
</Card>
)
Expand Down
Loading