ourzora / nft-components

NFT Rendering Components
GNU General Public License v3.0
100 stars 36 forks source link

Utilize new media properties from NFTObject in RenderRequest #140

Open neokry opened 2 years ago

neokry commented 2 years ago

New. media properties in NFTObject allow us to use mediaEncodings from Zora API

media?: {
    mimeType?: string;
    source: MEDIA_SOURCES;
    image?: MediaObject;
    large?: MediaObject;
    poster?: MediaObject;
    thumbnail?: MediaObject;
    // backwards compatibility
    content?: MediaObject;
  };

We should be surfacing these new properties in RenderRequest so they can be used in renderers. Current RenderRequest only surfaces these properties:

 media: {
    // from zora content uri
    content?: MediaUriType;
    image?: MediaUriType;
    // from metadata.animation_url
    animation?: MediaUriType;
  };