data-dex icon indicating copy to clipboard operation
data-dex copied to clipboard

Check if extra assets is an image and valid (200 check) when minting

Open damienen opened this issue 1 year ago • 0 comments

As we support only 1 extra asset for now and it is used to store an extra image, let's do the following:

Acceptance Criteria:

When user enters the extra asset,

  • check if it's a valid media file .png .jpeg .jpg .gif .svg .mov .mp4 .webm (check meme-types for this as per this list : https://docs.multiversx.com/tokens/nft-tokens/#supported-media-types)
  • When they enter the URL in the box, make sure it's a valid URL (https:// etc)
  • When they enter the URL in the box, render a small preview of the file inline or in another way, so the user can "see it" to verify it's the right file and to prevent bad input
  • If it's an image make sure it's more than 600 (H) and 600 (W). Recommended is 800 X 800
  • If it's an image make sure the H and W are "Square" (i.e. 800 X 800, 900 X 900 etc)
  • Change "Extra asset URL" to be "Extra Media Asset URL"
  • have an "?" popup... image

When clicked, it should say: Each Data NFT comes with a unique 'generative image' based on the data signature, but you can also add an extra media asset that will appear when a user views your Data NFT. This way you can personalize your Data NFT! A media file such as .png, .gif of 800px X 800px resolution is recommended.

damienen avatar Apr 16 '24 07:04 damienen