-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'dev' into feat/nova-visualizer/randomize-amplitude
- Loading branch information
Showing
4 changed files
with
74 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 37 additions & 0 deletions
37
client/src/app/components/nova/address/section/anchor/AnchorStateSection.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import { AnchorOutput, FeatureType, StateMetadataFeature } from "@iota/sdk-wasm-nova/web"; | ||
import React from "react"; | ||
import DataToggle from "~/app/components/DataToggle"; | ||
|
||
interface AnchorStateSectionProps { | ||
/** | ||
* The Anchor Output | ||
*/ | ||
readonly output: AnchorOutput | null; | ||
} | ||
|
||
const AnchorStateSection: React.FC<AnchorStateSectionProps> = ({ output }) => { | ||
const stateMetadata = output?.features?.find((feature) => feature.type === FeatureType.StateMetadata) as StateMetadataFeature; | ||
|
||
return ( | ||
<div className="section"> | ||
<div className="section--data"> | ||
<div> | ||
<div className="label">State Index</div> | ||
<div className="value row middle margin-t-t"> | ||
<span className="margin-r-t">{output?.stateIndex}</span> | ||
</div> | ||
</div> | ||
{Object.entries(stateMetadata.entries).map(([key, value], index) => ( | ||
<div key={index}> | ||
<div className="label margin-t-m">{key}</div> | ||
<div className="value row middle margin-t-t"> | ||
<DataToggle sourceData={value} withSpacedHex={true} /> | ||
</div> | ||
</div> | ||
))} | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default AnchorStateSection; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
#!/bin/bash | ||
SDK_DIR="iota-sdk" | ||
TARGET_COMMIT="257bcff80bf0336f571f9a226ebde1acd8974104" | ||
TARGET_COMMIT="fc9f0f56bb5cfc146993e53aa9656ded220734e1" | ||
|
||
if [ ! -d "$SDK_DIR" ]; then | ||
git clone -b 2.0 [email protected]:iotaledger/iota-sdk.git | ||
|
@@ -35,5 +35,3 @@ rm package.json.bak | |
echo "Building wasm bindings" | ||
yarn | ||
yarn build | ||
|
||
|