Skip to content

Commit

Permalink
adjust animation url fallback placeholder value
Browse files Browse the repository at this point in the history
  • Loading branch information
hvthhien committed May 24, 2024
1 parent 674aac3 commit 86fc450
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions contracts/FeralfileArtworkV4_2.sol
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,12 @@ contract FeralfileExhibitionV4_2 is FeralfileExhibitionV4_1 {
return tokenPlaceholderAnimationURI;
}

return _buildIframe(Base64.encode(parameters), artworkFileURI);
return string(
abi.encodePacked(
"data:text/html;base64,",
_buildIframe(Base64.encode(parameters), artworkFileURI)
)
);
}

/// @notice _buildImageURI returns the image url
Expand Down Expand Up @@ -182,7 +187,7 @@ contract FeralfileExhibitionV4_2 is FeralfileExhibitionV4_1 {
abi.encodePacked(
"{\"name\":\"", tokenName,
"\", \"external_url\":\"https://feralfile.com\", \"image\":\"", _buildImageURI(tokenInfo.imageURI),
"\", \"animation_url\":\"data:text/html;base64,", _buildAnimationURI(tokenInfo.parameters),
"\", \"animation_url\":\"", _buildAnimationURI(tokenInfo.parameters),
"\"}"
)
);
Expand Down

0 comments on commit 86fc450

Please sign in to comment.