-
Notifications
You must be signed in to change notification settings - Fork 31
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
ICS721 v2: cw721 v19 with creator and onchain extensioms (aka metadata) #103
Merged
taitruong
merged 21 commits into
public-awesome:main
from
arkprotocol:onchain_metadata_v19
Aug 17, 2024
Merged
Changes from all commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
7adef9f
use latest cw721 v19
taitruong a18f866
update workspace-optimizer v0.16.0
taitruong 088d43b
add cw721_metadata_onchain_v0.19.0.wasm for tests
taitruong 4cfad8b
fix go tests
taitruong e82d03c
retrieve collection data
taitruong d97600b
clippy
taitruong 6b124ed
instantiate nft contract with collection data
taitruong 5b5f60c
use cw721 admin as creator
taitruong 4087a78
ts-relayer: instantiate with collection info
taitruong bc52478
fix
taitruong 915e997
update lib bech32 v0.11
taitruong ef5a3c4
assert escrowed collection data on chain B is properly set
taitruong 3a6d97f
update cw-nfts lib
taitruong cfe65dc
rename
taitruong dcdc99c
transfer onchain metadata in case NFT is on home chain
taitruong eb1af4d
mint with onchain metadata
taitruong 667dd69
test v017 and v018 on receive nft
taitruong 96d2d20
ts-relayer test: transfer NFT v16
taitruong 5b6b6d4
ts-relayer test: mint nft with onchain metadata and check it is trans…
taitruong c80be3c
fix ts-relayer test
taitruong 2d08afe
use admin for payment address
taitruong File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
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
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
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,23 +1,5 @@ | ||
use cosmwasm_schema::cw_serde; | ||
use cosmwasm_std::ContractInfoResponse; | ||
use sg721_base::msg::CollectionInfoResponse; | ||
|
||
pub const STARGAZE_ICON_PLACEHOLDER: &str = | ||
"ipfs://bafkreie5vwrm5zts4wiq6ebtopmztgl5qzyl4uszyllgwpaizyc5w2uycm"; | ||
|
||
/// Collection data provided by the (source) cw721 contract. This is pass as optional class data during interchain transfer to target chain. | ||
/// ICS721 on target chain is free to use this data or not. Lik in case of `sg721-base` it uses owner for defining creator in collection info. | ||
#[cw_serde] | ||
pub struct SgCollectionData { | ||
// CW721 specific props, copied from ics721::state::CollectionData | ||
pub owner: Option<String>, | ||
pub contract_info: Option<ContractInfoResponse>, | ||
pub name: String, | ||
pub symbol: String, | ||
pub num_tokens: Option<u64>, | ||
/// SG721 specific collection info | ||
pub collection_info: Option<CollectionInfoResponse>, | ||
} | ||
|
||
#[derive(Default)] | ||
pub struct SgIcs721Contract {} |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here sg-ics721 overrides default implementation and gets collection data from sg721-base via
CollectionInfo
query.