-
Notifications
You must be signed in to change notification settings - Fork 11.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add IERC4906 interface and use in ERC721 (#4012)
Co-authored-by: Francisco Giordano <fg@frang.io>
- Loading branch information
Showing
5 changed files
with
42 additions
and
2 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'openzeppelin-solidity': minor | ||
--- | ||
|
||
`IERC4906`: Add an interface for ERC-4906 that is now Final. |
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,5 @@ | ||
--- | ||
'openzeppelin-solidity': minor | ||
--- | ||
|
||
`ERC721URIStorage`: Emit ERC-4906 `MetadataUpdate` in `_setTokenURI`. |
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,19 @@ | ||
// SPDX-License-Identifier: MIT | ||
|
||
pragma solidity ^0.8.0; | ||
|
||
import "./IERC165.sol"; | ||
import "./IERC721.sol"; | ||
|
||
/// @title EIP-721 Metadata Update Extension | ||
interface IERC4906 is IERC165, IERC721 { | ||
/// @dev This event emits when the metadata of a token is changed. | ||
/// So that the third-party platforms such as NFT market could | ||
/// timely update the images and related attributes of the NFT. | ||
event MetadataUpdate(uint256 _tokenId); | ||
|
||
/// @dev This event emits when the metadata of a range of tokens is changed. | ||
/// So that the third-party platforms such as NFT market could | ||
/// timely update the images and related attributes of the NFTs. | ||
event BatchMetadataUpdate(uint256 _fromTokenId, uint256 _toTokenId); | ||
} |
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