templates/explorer/asset-detail.html.twig line 1

  1. {% extends 'base.html.twig' %}
  2. {% block title %}Marketplace{% endblock %}
  3. {% block body %}
  4.     <div id="crate-contents" style="display: none; padding-top: 15%;">
  5.         <div class="grid-container">
  6.             <div class="grid-x grid-padding-x grid-padding-y crate-contents align-center">
  7.                 <div class="small-12 medium-4 cell">
  8.                     <img class="crate" src="{{ asset("/build/images/web/front-crate.png") }}" />
  9.                 </div>
  10.             </div>
  11.             <div class="grid-x">
  12.                 <div class="small-12 cell">
  13.                     <p style="font-size: .9em; text-align: center;">Please note that it may take up to 5 minutes for the NFT to process and show in your inventory.</p>
  14.                     <button id="close-crate-contents" class="button" style="display: none;">Close</button>
  15.                 </div>
  16.             </div>
  17.         </div>
  18.     </div>
  19. <div class="grid-container">
  20.     <div class="grid-x grid-padding-y grid-padding-x">
  21.         <div class="small-12 cell" style="text-align: center;">
  22.             <h1 style="margin-top: 75px;">Asset Detail</h1>
  23.         </div>
  24.         <div class="small-12 medium-offset-1 cell">
  25.             <div class="small-12 cell">
  26.                 {{ wo_render_breadcrumbs() }}
  27.             </div>
  28.         </div>
  29.         {% if assetMetadata.nftHub.isMinted is same as(null) and assetMetadata.nftHub.scriptMint is same as(true) %}
  30.             <div class="small-12 medium-10 medium-offset-1 end cell">
  31.                 <p style="text-align: center; font-size: .9em; background: #c4510f; padding: 10px; border-radius: 3px; font-weight: bold;">This asset is currently being processed on the blockchain. It will be available in your inventory in approximately 10 minutes.</p>
  32.             </div>
  33.         {% endif %}
  34.         <div class="small-12 medium-3 medium-offset-1 cell">
  35.             {% include 'explorer/includes/asset-card.html.twig' with {'nftMetadata': assetMetadata, 'app': app} %}
  36.             {#            <div style="background: #13161d; padding: 50px; text-align: center; border-radius: 10px;">#}
  37. {#                <div class="grid-x grid-padding-x grid-padding-y">#}
  38. {#                    <div class="small-12 cell">#}
  39. {#                        <div style="position: relative; height: 150px;">#}
  40. {#                            <img src="{{ assetMetadata.imageUrl }}" />#}
  41. {#                        </div>#}
  42. {#                    </div>#}
  43. {#                    <div class="small-4 cell">#}
  44. {#                        <p><span class="nft-detail-label">L</span><br />#}
  45. {#                            <span class="nft-detail-text">{{ assetMetadata.statStar }}</span></p>#}
  46. {#                    </div>#}
  47. {#                    <div class="small-4 cell">#}
  48. {#                        <p><span class="nft-detail-label">D</span><br />#}
  49. {#                            <span class="nft-detail-text">{{ assetMetadata.statRectangle }}</span></p>#}
  50. {#                    </div>#}
  51. {#                    <div class="small-4 cell">#}
  52. {#                        <p><span class="nft-detail-label">T</span><br />#}
  53. {#                            <span class="nft-detail-text">{{ assetMetadata.statCircle }}</span></p>#}
  54. {#                    </div>#}
  55. {#                </div>#}
  56. {#            </div>#}
  57.             {% if assetMetadata.template.genus.id != 3 %}
  58.             <div class="grid-container" style="background: #252534; padding: 15px 0 20px 0; text-align: center; border-radius: 10px; margin-top: 15px;">
  59.                 <div class="grid-x">
  60.                     <div class="small-12 cell">
  61.                         <div style="margin-bottom: 15px; display: block;">
  62.                         <span data-tooltip tabindex="1" title="Stat comparison for {{ assetMetadata.name}} across ALL NFT Collection Series. Note that these ranges are pulled from all existing {{ assetMetadata.name }} NFTs and do not represent actual minimum and maximum potential values." class="family-orgovan">Stat Comparison</span>
  63.                         </div>
  64.                     </div>
  65.                     <div class="small-12 cell">
  66.                         <div class="grid-container">
  67.                             <div class="grid-x grid-margin-y">
  68.                                 <div class="small-1 cell" style="text-align: center; font-size: .8em; font-weight: bold; color: dodgerblue">
  69.                                     <span data-tooltip tabindex="1" title="Overall Score. Note that the Overall Score is calculated using all stats, including the Additional Stats listed below.">S</span>
  70.                                 </div>
  71.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  72.                                     {{ nftMinMaxStats.minScore|number_format(0,'.',',') }}
  73.                                 </div>
  74.                                 {% if (nftMinMaxStats.maxScore - nftMinMaxStats.minScore) > 0 %}
  75.                                     {% set scorePercent = (assetMetadata.score - nftMinMaxStats.minScore) / (nftMinMaxStats.maxScore - nftMinMaxStats.minScore) %}
  76.                                 {% endif %}
  77.                                 <div class="small-7 cell">
  78.                                     <div style="background: #333; border-radius: 3px; height: 12px; margin-top: 3px;">
  79.                                         <div style="height:12px; width: 5px; border-radius: 2px;
  80.                                         {% if nftMinMaxStats.maxScore == assetMetadata.score %}
  81.                                                 width: 100%;
  82.                                         {% else %}
  83.                                                 width: {{ scorePercent * 100 }}%;
  84.                                                 float: left;
  85.                                         {% endif %}
  86.                                                 background: goldenrod;">
  87.                                         </div>
  88.                                     </div>
  89.                                 </div>
  90.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  91.                                     {{ nftMinMaxStats.maxScore|number_format(0,'.',',') }}
  92.                                 </div>
  93.                             </div>
  94.                         </div>
  95.                         <div class="grid-container">
  96.                             <div class="grid-x grid-margin-y">
  97.                                 <div class="small-1 cell" style="text-align: center; font-size: .8em; font-weight: bold; color: dodgerblue">
  98.                                     <span data-tooltip tabindex="1" title="Luck">L</span>
  99.                                 </div>
  100.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  101.                                     {{ nftMinMaxStats.minStar }}
  102.                                 </div>
  103.                                 {% if (nftMinMaxStats.maxStar - nftMinMaxStats.minStar) > 0 %}
  104. {#                                    {% set luckStat = (assetMetadata.nftMetadataquest.progress > assetMetadata.nftMetadataquest.goal) ? assetMetadata.statStar + assetMetadata.nftMetadataQuest.statStarMod : assetMetadata.statStar %}#}
  105. {#                                    {% set starPercent = (luckStat - nftMinMaxStats.minStar) / (luckStat - nftMinMaxStats.minStar) %}#}
  106.                                     {% set starPercent = (assetMetadata.statStar - nftMinMaxStats.minStar) / (nftMinMaxStats.maxStar - nftMinMaxStats.minStar) %}
  107.                                 {% endif %}
  108.                                 <div class="small-7 cell">
  109.                                     <div style="background: #333; border-radius: 3px; height: 12px; margin-top:3px">
  110.                                         <div style="height:12px; width: 5px; border-radius: 2px;
  111.                                         {% if nftMinMaxStats.maxStar == assetMetadata.statStar %}
  112.                                                 width: 100%;
  113.                                         {% else %}
  114.                                                 width: {{ starPercent * 100 }}%;
  115.                                                 float: left;
  116.                                         {% endif %}
  117.                                                 background: dodgerblue;">
  118.                                         </div>
  119.                                     </div>
  120.                                 </div>
  121.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  122.                                     {{ nftMinMaxStats.maxStar }}
  123.                                 </div>
  124.                             </div>
  125.                         </div>
  126.                         <div class="grid-container">
  127.                             <div class="grid-x grid-margin-y">
  128.                                 <div class="small-1 cell" style="text-align: center; font-size: .8em; font-weight: bold; color: dodgerblue">
  129.                                     <span data-tooltip tabindex="1" title="Distance">D</span>
  130.                                 </div>
  131. {#                                <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">#}
  132. {#                                    {{ assetMetadata.statRectangle }}#}
  133. {#                                </div>#}
  134.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  135.                                     {{ nftMinMaxStats.minRectangle }}
  136.                                 </div>
  137.                                 {% if (nftMinMaxStats.maxRectangle - nftMinMaxStats.minRectangle) > 0 %}
  138.                                     {% set rectanglePercent = (assetMetadata.statRectangle - nftMinMaxStats.minRectangle) / (nftMinMaxStats.maxRectangle - nftMinMaxStats.minRectangle) %}
  139.                                 {% endif %}
  140.                                 <div class="small-7 cell">
  141.                                     <div style="background: #333; border-radius: 3px; height: 12px; margin-top: 3px;">
  142.                                         <div style="height:12px; width: 5px; border-radius: 2px;
  143.                                         {% if nftMinMaxStats.maxRectangle == assetMetadata.statRectangle %}
  144.                                                 width: 100%;
  145.                                         {% else %}
  146.                                                 width: {{ rectanglePercent * 100 }}%;
  147.                                                 float: left;
  148.                                         {% endif %}
  149.                                                 background: dodgerblue;">
  150.                                         </div>
  151.                                     </div>
  152.                                 </div>
  153.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  154.                                     {{ nftMinMaxStats.maxRectangle }}
  155.                                 </div>
  156.                             </div>
  157.                         </div>
  158.                         <div class="grid-container">
  159.                             <div class="grid-x grid-margin-y">
  160.                                 <div class="small-1 cell" style="text-align: center; font-size: .8em; font-weight: bold; color: dodgerblue">
  161.                                     <span data-tooltip tabindex="1" title="Tension">T</span>
  162.                                 </div>
  163.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  164.                                     {{ nftMinMaxStats.minCircle }}
  165.                                 </div>
  166.                                 {% if (nftMinMaxStats.maxCircle - nftMinMaxStats.minCircle) > 0 %}
  167.                                     {% set circlePercent = (assetMetadata.statCircle - nftMinMaxStats.minCircle) / (nftMinMaxStats.maxCircle - nftMinMaxStats.minCircle) %}
  168.                                 {% endif %}
  169.                                 <div class="small-7 cell">
  170.                                     <div style="background: #333; border-radius: 3px; height: 12px; margin-top: 3px;">
  171.                                         <div style="height:12px; width: 5px; border-radius: 2px;
  172.                                         {% if nftMinMaxStats.maxCircle == assetMetadata.statCircle %}
  173.                                             width: 100%;
  174.                                         {% else %}
  175.                                                 width: {{ circlePercent * 100 }}%;
  176.                                                 float: left;
  177.                                         {% endif %}
  178.                                                 background: dodgerblue;">
  179.                                         </div>
  180.                                     </div>
  181.                                 </div>
  182.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  183.                                     {{ nftMinMaxStats.maxCircle }}
  184.                                 </div>
  185.                             </div>
  186.                         </div>
  187.                     </div>
  188.                 </div>
  189.             </div>
  190.             <div class="grid-container" style="background: #252534; padding: 15px 0 20px 0; text-align: center; border-radius: 10px; margin-top: 15px;">
  191.                 <div class="grid-x">
  192.                     <div class="small-12 cell">
  193.                         <div style="margin-bottom: 15px; display: block;">
  194.                             <span data-tooltip tabindex="1" title="These are additional stats tied to this NFT. These stats are not yet used in game, but are planned for future updates." class="family-orgovan">Additional Stats</span>
  195.                         </div>
  196.                     </div>
  197.                     <div class="small-12 cell">
  198.                         <div class="grid-container">
  199.                             <div class="grid-x grid-margin-y">
  200.                                 <div class="small-1 cell" style="text-align: center; font-size: .8em; font-weight: bold; color: dodgerblue">
  201.                                     <svg style="filter: invert(88%) sepia(13%) saturate(0%) hue-rotate(347deg) brightness(91%) contrast(93%);" clip-rule="evenodd" fill-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="2" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="m21 4c0-.478-.379-1-1-1h-16c-.62 0-1 .519-1 1v16c0 .621.52 1 1 1h16c.478 0 1-.379 1-1z" fill-rule="nonzero"/></svg>                                </div>
  202.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  203.                                     {{ nftMinMaxStats.minSquare }}
  204.                                 </div>
  205.                                 {% if (nftMinMaxStats.maxSquare - nftMinMaxStats.minSquare) > 0 %}
  206.                                     {% set squarePercent = (assetMetadata.statSquare - nftMinMaxStats.minSquare) / (nftMinMaxStats.maxSquare - nftMinMaxStats.minSquare) %}
  207.                                 {% endif %}
  208.                                 <div class="small-7 cell">
  209.                                     <div style="background: #333; border-radius: 3px; height: 12px; margin-top:3px">
  210.                                         <div style="height:12px; width: 5px; border-radius: 2px;
  211.                                         {% if nftMinMaxStats.maxSquare == assetMetadata.statSquare %}
  212.                                                 width: 100%;
  213.                                         {% else %}
  214.                                                 width: {{ squarePercent * 100 }}%;
  215.                                                 float: left;
  216.                                         {% endif %}
  217.                                                 background: dodgerblue;">
  218.                                         </div>
  219.                                     </div>
  220.                                 </div>
  221.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  222.                                     {{ nftMinMaxStats.maxSquare }}
  223.                                 </div>
  224.                             </div>
  225.                         </div>
  226.                         <div class="grid-container">
  227.                             <div class="grid-x grid-margin-y">
  228.                                 <div class="small-1 cell" style="text-align: center; font-size: .8em; font-weight: bold; color: dodgerblue">
  229.                                     <svg style="filter: invert(88%) sepia(13%) saturate(0%) hue-rotate(347deg) brightness(91%) contrast(93%);" clip-rule="evenodd" fill-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="2" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="m11.262 2.306c.196-.196.461-.306.738-.306s.542.11.738.306c1.917 1.917 7.039 7.039 8.956 8.956.196.196.306.461.306.738s-.11.542-.306.738c-1.917 1.917-7.039 7.039-8.956 8.956-.196.196-.461.306-.738.306s-.542-.11-.738-.306c-1.917-1.917-7.039-7.039-8.956-8.956-.196-.196-.306-.461-.306-.738s.11-.542.306-.738c1.917-1.917 7.039-7.039 8.956-8.956z" fill-rule="nonzero"/></svg>                                </div>
  230.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  231.                                     {{ nftMinMaxStats.minDiamond }}
  232.                                 </div>
  233.                                 {% if (nftMinMaxStats.maxDiamond - nftMinMaxStats.minDiamond) > 0 %}
  234.                                     {% set diamondPercent = (assetMetadata.statDiamond - nftMinMaxStats.minDiamond) / (nftMinMaxStats.maxDiamond - nftMinMaxStats.minDiamond) %}
  235.                                 {% endif %}
  236.                                 <div class="small-7 cell">
  237.                                     <div style="background: #333; border-radius: 3px; height: 12px; margin-top: 3px;">
  238.                                         <div style="height:12px; width: 5px; border-radius: 2px;
  239.                                         {% if nftMinMaxStats.maxDiamond == assetMetadata.statDiamond %}
  240.                                                 width: 100%;
  241.                                         {% else %}
  242.                                                 width: {{ diamondPercent * 100 }}%;
  243.                                                 float: left;
  244.                                         {% endif %}
  245.                                                 background: dodgerblue;">
  246.                                         </div>
  247.                                     </div>
  248.                                 </div>
  249.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  250.                                     {{ nftMinMaxStats.maxDiamond }}
  251.                                 </div>
  252.                             </div>
  253.                         </div>
  254.                         <div class="grid-container">
  255.                             <div class="grid-x grid-margin-y">
  256.                                 <div class="small-1 cell" style="text-align: center; font-size: .8em; font-weight: bold; color: dodgerblue">
  257.                                     <svg style="filter: invert(88%) sepia(13%) saturate(0%) hue-rotate(347deg) brightness(91%) contrast(93%);" clip-rule="evenodd" fill-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="2" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="m2.095 19.882 9.248-16.5c.133-.237.384-.384.657-.384.272 0 .524.147.656.384l9.248 16.5c.064.115.096.241.096.367 0 .385-.309.749-.752.749h-18.496c-.44 0-.752-.36-.752-.749 0-.126.031-.252.095-.367z" fill-rule="nonzero"/></svg>
  258.                                 </div>
  259.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  260.                                     {{ nftMinMaxStats.minTriangle }}
  261.                                 </div>
  262.                                 {% if (nftMinMaxStats.maxTriangle - nftMinMaxStats.minTriangle) > 0 %}
  263.                                     {% set trianglePercent = (assetMetadata.statTriangle - nftMinMaxStats.minTriangle) / (nftMinMaxStats.maxTriangle - nftMinMaxStats.minTriangle) %}
  264.                                 {% endif %}
  265.                                 <div class="small-7 cell">
  266.                                     <div style="background: #333; border-radius: 3px; height: 12px; margin-top: 3px;">
  267.                                         <div style="height:12px; width: 5px; border-radius: 2px;
  268.                                         {% if nftMinMaxStats.maxTriangle == assetMetadata.statTriangle %}
  269.                                                 width: 100%;
  270.                                         {% else %}
  271.                                                 width: {{ trianglePercent * 100 }}%;
  272.                                                 float: left;
  273.                                         {% endif %}
  274.                                                 background: dodgerblue;">
  275.                                         </div>
  276.                                     </div>
  277.                                 </div>
  278.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  279.                                     {{ nftMinMaxStats.maxTriangle }}
  280.                                 </div>
  281.                             </div>
  282.                         </div>
  283.                         <div class="grid-container">
  284.                             <div class="grid-x grid-margin-y">
  285.                                 <div class="small-1 cell" style="text-align: center; font-size: .8em; font-weight: bold; color: dodgerblue">
  286.                                     <svg style="filter: invert(88%) sepia(13%) saturate(0%) hue-rotate(347deg) brightness(91%) contrast(93%);" clip-rule="evenodd" fill-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="2" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="m12 5.72c-2.624-4.517-10-3.198-10 2.461 0 3.725 4.345 7.727 9.303 12.54.194.189.446.283.697.283s.503-.094.697-.283c4.977-4.831 9.303-8.814 9.303-12.54 0-5.678-7.396-6.944-10-2.461z" fill-rule="nonzero"/></svg>
  287.                                 </div>
  288.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  289.                                     {{ nftMinMaxStats.minHeart }}
  290.                                 </div>
  291.                                 {% if (nftMinMaxStats.maxHeart - nftMinMaxStats.minHeart) > 0 %}
  292.                                     {% set heartPercent = (assetMetadata.statHeart - nftMinMaxStats.minHeart) / (nftMinMaxStats.maxHeart - nftMinMaxStats.minHeart) %}
  293.                                 {% endif %}
  294.                                 <div class="small-7 cell">
  295.                                     <div style="background: #333; border-radius: 3px; height: 12px; margin-top: 3px;">
  296.                                         <div style="height:12px; width: 5px; border-radius: 2px;
  297.                                         {% if nftMinMaxStats.maxHeart == assetMetadata.statHeart %}
  298.                                                 width: 100%;
  299.                                         {% else %}
  300.                                                 width: {{ heartPercent * 100 }}%;
  301.                                                 float: left;
  302.                                         {% endif %}
  303.                                                 background: dodgerblue;">
  304.                                         </div>
  305.                                     </div>
  306.                                 </div>
  307.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  308.                                     {{ nftMinMaxStats.maxHeart }}
  309.                                 </div>
  310.                             </div>
  311.                         </div>
  312.                         <div class="grid-container">
  313.                             <div class="grid-x grid-margin-y">
  314.                                 <div class="small-1 cell" style="text-align: center; font-size: .8em; font-weight: bold; color: dodgerblue">
  315.                                     <svg style="filter: invert(88%) sepia(13%) saturate(0%) hue-rotate(347deg) brightness(91%) contrast(93%);" clip-rule="evenodd" fill-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="2" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="m22.005 15.728c0 .266-.106.52-.293.707-1 1-4.272 4.272-5.272 5.272-.187.188-.442.293-.707.293-1.414 0-6.042 0-7.457 0-.265 0-.519-.105-.707-.293-1-1-4.271-4.272-5.271-5.272-.188-.187-.293-.441-.293-.707 0-1.414 0-6.042 0-7.456 0-.266.105-.52.293-.707 1-1 4.271-4.272 5.271-5.272.188-.188.442-.293.707-.293h7.457c.265 0 .52.105.707.293 1 1 4.272 4.272 5.272 5.272.187.187.293.441.293.707z" fill-rule="nonzero"/></svg>                                </div>
  316.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  317.                                     {{ nftMinMaxStats.minOctagon }}
  318.                                 </div>
  319.                                 {% if (nftMinMaxStats.maxOctagon - nftMinMaxStats.minOctagon) > 0 %}
  320.                                     {% set octagonPercent = (assetMetadata.statOctagon - nftMinMaxStats.minOctagon) / (nftMinMaxStats.maxOctagon - nftMinMaxStats.minOctagon) %}
  321.                                 {% endif %}
  322.                                 <div class="small-7 cell">
  323.                                     <div style="background: #333; border-radius: 3px; height: 12px; margin-top: 3px;">
  324.                                         <div style="height:12px; width: 5px; border-radius: 2px;
  325.                                         {% if nftMinMaxStats.maxOctagon == assetMetadata.statOctagon %}
  326.                                                 width: 100%;
  327.                                         {% else %}
  328.                                                 width: {{ octagonPercent * 100 }}%;
  329.                                                 float: left;
  330.                                         {% endif %}
  331.                                                 background: dodgerblue;">
  332.                                         </div>
  333.                                     </div>
  334.                                 </div>
  335.                                 <div class="small-2 cell" style="text-align: center; font-size: .8em; font-weight: bold;">
  336.                                     {{ nftMinMaxStats.maxOctagon }}
  337.                                 </div>
  338.                             </div>
  339.                         </div>
  340.                     </div>
  341.                 </div>
  342.             </div>
  343.             {% endif %} {# if assetMetadata.template.genus.id != 3 #}
  344. {#            <div style="text-align: center;">#}
  345. {#                <div class="grid-x grid-padding-x grid-padding-y">#}
  346. {#                    <div class="small-12 cell">#}
  347. {#                        {% if marketItem == true %}#}
  348. {#                            <p style="padding: 20px; text-align: center;"><img height="25" width="25" src="{{ asset('build/images/web/tfuel-logo.svg') }}" style="vertical-align: top;" /> <span style="font-size: 2em; font-weight: bold; color: #ffa50d; ">{{ marketItem.price|number_format(2,'.',',') }}</span></p>#}
  349. {#                            {% if app.user is not null#}
  350. {#                                and app.user.activeWallet == marketItem.seller %}#}
  351. {#                                #}{# Show Cancel Button #}
  352. {#                                <button class="button initiateMarketCancel" data-open="initiateMarketCancel-{{ marketItem.id }}" style="width: 100%; font-weight: bold; font-size: 1.1em;">Cancel</button>#}
  353. {#                                {% include 'marketplace/modals/createMarketCancel.html.twig' with {'marketItem': marketItem, 'app': app } %}#}
  354. {#                            {% elseif app.user is not null %}#}
  355. {#                                #}{# Show Buy Button #}
  356. {#                                <button class="button initiateMarketSale" data-open="initiateMarketSale-{{ marketItem.id }}" style="width: 100%; padding: 15px 50px; font-weight: bold; font-size: 1.1em;">Buy</button>#}
  357. {#                                {% include 'marketplace/modals/createMarketSale.html.twig' with {'marketItem': marketItem, 'app': app } %}#}
  358. {#                            {% else %}#}
  359. {#                                #}{# Show Buy Button but direct towards login #}
  360. {#                                <a href="{{ path('app_login') }}" class="button" style="width: 100%; padding: 15px 50px; font-weight: bold; font-size: 1.1em;">Buy</a>#}
  361. {#                            {% endif %}#}
  362. {#                        {% elseif marketItem == false %}#}
  363. {#                            {% if app.user is not null#}
  364. {#                                and app.user.activeWallet is defined#}
  365. {#                                and app.user.activeWallet.isApprovedForAllMarket is same as(true)#}
  366. {#                                and app.user.activeWallet == assetMetadata.nftHub.thetaWallet#}
  367. {#                            %}#}
  368. {#                                <a class="button gold-button initiateMarketCreateItem" style="margin-top: 10px; font-weight: bold; font-size: 1.1em;" href="#" data-open="createMarketItem-{{ assetMetadata.id }}">Sell</a>#}
  369. {#                                {% include 'marketplace/modals/createMarketItem.html.twig' with {'assetMetadata': assetMetadata, 'app': app } %}#}
  370. {#                            {% elseif app.user.activeWallet.address is defined#}
  371. {#                                and app.user.activeWallet.address == assetMetadata.nftHub.thetaWallet.address#}
  372. {#                            %}#}
  373. {#                                #}{# If User has not given Marketplace contract permissions to handle NFT tokens we must ask for that first #}
  374. {#                                #}{# include both Approval and Sell modals so that we can immediately show the Sell button after Approval #}
  375. {#                                <a class="button gold-button initiateMarketCreateItem" style="margin-top: 10px; font-weight: bold; font-size: 1.1em; display: none;" href="#" data-open="createMarketItem-{{ assetMetadata.id }}">Sell</a>#}
  376. {#                                {% include 'marketplace/modals/setApprovalForAll.html.twig' with {'assetMetadata': assetMetadata, 'app': app} %}#}
  377. {#                                {% include 'marketplace/modals/createMarketItem.html.twig' with {'assetMetadata': assetMetadata, 'app': app, 'hideSellButton': true } %}#}
  378. {#                            {% endif %}#}
  379. {#                        {% endif %}#}
  380. {#                    </div>#}
  381. {#                </div>#}
  382. {#            </div>#}
  383.                 <div class="grid-x" style="margin: 5px;">
  384.                     <div class="small-12 cell">
  385.                         {# Show Open Crate if current User owns the crate #}
  386.                         {% if app.user and app.user.activeWallet is defined and app.user.activeWallet == assetMetadata.nftHub.thetaWallet %}
  387.                             {# If the crate is still in minting process show disabled Open Crate button #}
  388.                             {% if assetMetadata.nftHub.crateActionLog is not same as(null) and assetMetadata.nftHub.isMinted is same as(null) %}
  389.                                 <button class="button orange-button initiateOpenCrate {{ app.user.walletExtension == 1 ? 'ext-theta' : 'ext-meta' }}" style="width: 100%; height: 50px; margin-top: 10px; background-color: darkslateblue; font-weight: bold; font-size: .8em; color: #fff;" data-open="openCrate-{{ assetMetadata.nftHub.id }}" disabled>Open Crate</button>
  390.                             {# If the crate is not opened show Open Crate button #}
  391.                             {% elseif assetMetadata.nftHub.crateActionLog is not same as(null) and assetMetadata.nftHub.crateActionLog.isOpened is same as(null) %}
  392.                                 <button class="button orange-button initiateOpenCrate {{ app.user.walletExtension == 1 ? 'ext-theta' : 'ext-meta' }}" style="width: 100%; height: 50px; margin-top: 10px; background-color: darkslateblue; font-weight: bold; font-size: .8em; color: #fff;" data-open="openCrate-{{ assetMetadata.nftHub.id }}">Open Crate</button>
  393.                                 {% include 'crate/modals/openCrate.html.twig' with {'assetMetadata': assetMetadata, 'app': app} %}
  394.                             {% endif %}
  395.                         {% endif %}
  396.                         {# If the crate is opened show details #}
  397.                         {% if assetMetadata.nftHub.crateActionLog is not same as(null) and assetMetadata.nftHub.crateActionLog.isOpened is same as(true) %}
  398.                             <p style="font-size: .8em; padding: 10px; background: #c4510f; border-radius: 3px;">
  399.                                 Crate opened by <strong>{{ assetMetadata.nftHub.crateActionLog.openedBy.user.username is defined ? assetMetadata.nftHub.crateActionLog.openedBy.user.username : assetMetadata.nftHub.crateActionLog.openedBy.address|slice(0,6 ) ~ '...' ~ assetMetadata.nftHub.crateActionLog.openedBy.address|slice(38,42) }}</strong>
  400.                                 on {{ assetMetadata.nftHub.crateActionLog.initiateOpenAt|date }}</p>
  401.                         {% endif %}
  402.                     </div>
  403.                 </div>
  404.         </div>
  405.         <div class="small-12 medium-7 end cell">
  406.             <div class="grid-container" style="background: #252534; padding: 50px; border-radius: 10px;">
  407.                 <div class="grid-x">
  408.                     <div class="small-12 cell">
  409.                         <p><span class="nft-detail-label">Name</span><br />
  410.                             <span class="nft-detail-text">{{ assetMetadata.name }}</span></p>
  411.                     </div>
  412.                     <div class="small-12 medium-12 cell">
  413.                         <p><span class="nft-detail-label">Series</span><br />
  414.                             <span class="nft-detail-text">{{ assetMetadata.nftCollection.name }} {{ assetMetadata.nftCollection.series }}</span></p>
  415.                     </div>
  416.                     <div class="small-12 medium-4 cell">
  417.                         <p><span class="nft-detail-label">Mint number</span><br />
  418.                             <span class="nft-detail-text"><span class="highlight">#{{ assetHub.nftMetadata.mint }}</span> of {{ totalMinted }}</span></p>
  419.                     </div>
  420.                     <div class="small-12 medium-3 end cell">
  421.                         <p><span class="nft-detail-label">Token Id</span><br />
  422.                             <span class="nft-detail-text">{{ assetMetadata.nftHub.id }}</span></p>
  423.                     </div>
  424.                     <div class="small-12 medium-3 cell">
  425.                         <p><span class="nft-detail-label">Wear</span><br />
  426.                         {% if assetMetadata.template.genus.id != 3 %}
  427.                             <span class="nft-detail-text">{{ assetMetadata.wear }}</span></p>
  428.                         {% else %}
  429.                             N/A
  430.                         {% endif %}
  431.                     </div>
  432.                     <div class="small-12 medium-2 cell">
  433.                         <p><span class="nft-detail-label">Weight</span><br />
  434.                         {% if assetMetadata.template.genus.id != 3 %}
  435.                             <span class="nft-detail-text">{{ assetMetadata.weight }}</span></p>
  436.                         {% else %}
  437.                             N/A
  438.                         {% endif %}
  439.                     </div>
  440.                     <div class="small-12 medium-4 cell">
  441.                         {% if assetMetadata.template.tier == 0 %}
  442.                             {% set tier = 'Old' %}
  443.                         {% elseif assetMetadata.template.tier == 1 %}
  444.                             {% set tier = 'Fodder' %}
  445.                         {% elseif assetMetadata.template.tier == 2 %}
  446.                             {% set tier = 'Common' %}
  447.                         {% elseif assetMetadata.template.tier == 3 %}
  448.                             {% set tier = 'Uncommon' %}
  449.                         {% elseif assetMetadata.template.tier == 4 %}
  450.                             {% set tier = 'Rare' %}
  451.                         {% elseif assetMetadata.template.tier == 5 %}
  452.                             {% set tier = 'Epic' %}
  453.                         {% elseif assetMetadata.template.tier == 6 %}
  454.                             {% set tier = 'Legendary' %}
  455.                         {% elseif assetMetadata.template.tier == 7 %}
  456.                             {% set tier = 'Extreme' %}
  457.                         {% elseif assetMetadata.template.tier == 100 %}
  458.                             {% set tier = 'Promotional' %}
  459.                         {% endif %}
  460.                         <p><span class="nft-detail-label">Tier</span><br />
  461.                         {% if assetMetadata.template.genus.id != 3 %}
  462.                             <span class="nft-detail-text">{{ tier }}</span></p>
  463.                         {% else %}
  464.                             N/A
  465.                         {% endif %}
  466.                     </div>
  467.                     <div class="small-12 medium-4 cell">
  468.                         <p><span class="nft-detail-label">Grade</span><br />
  469.                             {% if assetMetadata.template.genus.id != 3 %}
  470.                                 <span class="nft-detail-text">{{ assetMetadata.grade }}</span></p>
  471.                             {% else %}
  472.                                 N/A
  473.                             {% endif %}
  474.                     </div>
  475.                     <div class="small-12 medium-4 end cell">
  476.                         <p><span class="nft-detail-label">Score</span><br />
  477.                         {% if assetMetadata.template.genus.id != 3 %}
  478.                             <span class="nft-detail-text" style="color: goldenrod">{{ assetMetadata.score|number_format(2,'.',',') }}</span></p>
  479.                         {% else %}
  480.                             N/A
  481.                         {% endif %}
  482.                     </div>
  483.                     <div class="small-12 cell">
  484.                         <p><span class="nft-detail-label">School of Magic</span><br />
  485.                         <span class="nft-detail-text">{{ assetMetadata.schoolOfMagic.name is defined ? assetMetadata.schoolOfMagic.name : 'N/A' }}</span></p>
  486.                     </div>
  487.                     <div class="small-12 cell">
  488.                         <p><span class="nft-detail-label">Description</span><br />
  489.                             <span class="nft-detail-text">{{ assetMetadata.description }}</span></p>
  490.                     </div>
  491.                     <div class="small-12 cell">
  492.                         <p><span class="nft-detail-label">Created</span><br />
  493.                             <span class="nft-detail-text">{{ assetMetadata.createdAt|date() }}</span></p>
  494.                     </div>
  495.                     <div class="small-12 cell">
  496.                         <p><span class="nft-detail-label">Owner</span><br />
  497.                             {% if assetMetadata.nftHub.activeMarketItem is not empty %}
  498.                                 {% if assetMetadata.nftHub.activeMarketItem|first.seller.user.username is defined %}
  499.                                     <span class="nft-detail-text"><span class="highlight"><a href="{{ path('user_profile', { userId: assetMetadata.nftHub.activeMarketItem|first.seller.user.id, domain: app_domain }) }}">{{ assetMetadata.nftHub.activeMarketItem|first.seller.user.username is defined ? assetMetadata.nftHub.activeMarketItem|first.seller.user.username : ''}} ({{ assetMetadata.nftHub.activeMarketItem|first.seller.address|slice(0,6) }}...{{ assetMetadata.nftHub.activeMarketItem|first.seller.address|slice(38,42) }})</a></span></span></p>
  500.                                 {% elseif assetMetadata.nftHub.activeMarketItem|first.seller.address is defined %}
  501.                                     <a href="https://explorer.thetatoken.org/account/{{ assetMetadata.nftHub.activeMarketItem|first.seller.address }}" target="_blank">{{ assetMetadata.nftHub.activeMarketItem|first.seller.address }}</a>
  502.                                 {% endif %}
  503.                             {% else %}
  504.                                 {% if assetHub.thetaWallet.user.username is defined %}
  505.                                 <span class="nft-detail-text"><span class="highlight"><a href="{{ path('user_profile', { userId: assetHub.thetaWallet.user.id, domain: app_domain }) }}">{{ assetHub.thetaWallet.user.username is defined ? assetHub.thetaWallet.user.username : ''}} ({{ assetHub.thetaWallet.address|slice(0,6) }}...{{ assetHub.thetaWallet.address|slice(38,42) }})</a></span></span></p>
  506.                                 {% elseif assetHub.thetaWallet.address is defined %}
  507.                                     <a href="https://explorer.thetatoken.org/account/{{ assetHub.thetaWallet.address }}" target="_blank">{{ assetHub.thetaWallet.address }}</a>
  508.                                 {% endif %}
  509.                             {% endif %}
  510.                     </div>
  511.                     <div class="small-12 cell">
  512.                         <p><span class="nft-detail-label">IPFS URL</span><br />
  513.                             <span class="nft-detail-text" style="font-size: .8em;"><a href="{{ assetMetadata.nftHub.ipfsUrl }}">{{ assetMetadata.nftHub.ipfsUrl }}</a></span></p>
  514.                     </div>
  515.                     <div class="small-12 cell">
  516.                         <p><span class="nft-detail-label">QUEST DETAIL</span><br />
  517.                         {% if assetMetadata.template.genus.id != 3 %}
  518.                             Progress: {{ assetMetadata.nftMetadataQuest.progress }}
  519.                             Goal: {{ assetMetadata.nftMetadataQuest.goal }}
  520.                         {% else %}
  521.                             N/A
  522.                         {% endif %}
  523.                     </div>
  524.                 </div>
  525.             </div>
  526.             <div class="grid-container" style="margin-top: 15px; background: #252534; padding: 35px 50px; border-radius: 10px;">
  527.                 <div class="grid-x">
  528.                     <div class="small-12 cell">
  529.                         <h2>Transfer History</h2>
  530.                     </div>
  531.                     <div class="small-12 cell">
  532.                     {% for transfer in assetTransferHistory %}
  533.                         <div class="grid-container" style="padding: 3px 0;">
  534.                             <div class="grid-x">
  535.                                 <div class="small-12 medium-4 cell">
  536.                                     {{ transfer.timestamp|date() }}
  537.                                 </div>
  538.                                 <div class="small-12 medium-8 cell">
  539.                                     {% if transfer.fromAddress == '0x0000000000000000000000000000000000000000' or transfer.fromAddress == '0xC0DF07Ae87912a7Df9798e68d18cBD77E3Da8BCf' or transfer.fromAddress == '0xBF05F3330ba6fF8bb4dCE16c4A8a1D8B23DeD398'
  540.                                         or transfer.fromAddress == '0x3Fc3FE7C34F1aD2D4cA86219eF1b67af9aA7aBD4'%}
  541.                                         {% if transfer.fromAddress == '0x0000000000000000000000000000000000000000' %}
  542.                                             Genesis
  543.                                         {% elseif transfer.fromAddress == '0xC0DF07Ae87912a7Df9798e68d18cBD77E3Da8BCf' or transfer.fromAddress == '0x3Fc3FE7C34F1aD2D4cA86219eF1b67af9aA7aBD4' %}
  544.                                             <a href="https://explorer.thetatoken.org/account/{{ transfer.fromAddress }}" target="_blank">Marketplace</a>
  545.                                         {% elseif transfer.fromAddress == '0xBF05F3330ba6fF8bb4dCE16c4A8a1D8B23DeD398' %}
  546.                                             Minter
  547.                                         {% endif %}
  548.                                     {% else %}
  549.                                         <a href="{{ path('user_profile_wallet_address', { walletAddress: transfer.fromAddress }) }}">{{ transfer.fromAddress|slice(0,6) }}...{{ transfer.fromAddress|slice(38,42)}}</a>
  550.                                     {% endif %}
  551.                                     <svg xmlns="http://www.w3.org/2000/svg" width="23.828" height="14.769" style=" margin: 0 5px; filter: invert(96%) sepia(78%) saturate(2%) hue-rotate(181deg) brightness(111%) contrast(100%);"><path d="m13.616 2.828 2.585 2.586H0v4h16.143l-2.527 2.526 2.828 2.829 7.384-7.384L16.444 0l-2.828 2.828z"/></svg>
  552.                                     {% if transfer.toAddress == '0x0000000000000000000000000000000000000000' or transfer.toAddress == '0xC0DF07Ae87912a7Df9798e68d18cBD77E3Da8BCf' or transfer.toAddress == '0xBF05F3330ba6fF8bb4dCE16c4A8a1D8B23DeD398'
  553.                                         or transfer.toAddress == '0x3Fc3FE7C34F1aD2D4cA86219eF1b67af9aA7aBD4'%}
  554.                                         {% if transfer.toAddress == '0x0000000000000000000000000000000000000000' %}
  555.                                             Genesis
  556.                                         {% elseif transfer.toAddress == '0xC0DF07Ae87912a7Df9798e68d18cBD77E3Da8BCf' or transfer.toAddress == '0x3Fc3FE7C34F1aD2D4cA86219eF1b67af9aA7aBD4' %}
  557.                                             <a href="https://explorer.thetatoken.org/account/{{ transfer.toAddress }}" target="_blank">Marketplace</a>
  558.                                         {% elseif transfer.toAddress == '0xBF05F3330ba6fF8bb4dCE16c4A8a1D8B23DeD398' %}
  559.                                             Minter
  560.                                         {% endif %}
  561.                                     {% else %}
  562.                                         <a href="{{ path('user_profile_wallet_address', { walletAddress: transfer.toAddress }) }}">{{ transfer.toAddress|slice(0,6) }}...{{ transfer.toAddress|slice(38,42)}}</a>
  563.                                     {% endif %}
  564.                                 </div>
  565.                             </div>
  566.                         </div>
  567.                     {% endfor %}
  568.                     </div>
  569.                 </div>
  570.             </div>
  571.             <div class="grid-container" style="margin-top: 15px; background: #252534; padding: 35px 50px; border-radius: 10px;">
  572.                 <div class="grid-x">
  573.                     <div class="small-12 cell">
  574.                         <h2>Market History</h2>
  575.                     </div>
  576.                     <div class="small-12 cell">
  577.                     {% if assetMarketHistory|length == 0 %}
  578.                             <p>No market sales exist for this asset.</p>
  579.                     {% else %}
  580.                         {% for transfer in assetMarketHistory %}
  581.                             {% if transfer.price > 0 %}
  582.                             <div class="grid-container" style="padding: 3px 0;">
  583.                                 <div class="grid-x">
  584.                                     <div class="small-12 medium-4 cell">
  585.                                         {{ transfer.updatedAt|date() }}
  586.                                     </div>
  587.                                     <div class="small-12 medium-8 cell">
  588.                                         <img alt="" height="20" width="20" src="{{ asset('build/images/web/tfuel-logo.svg') }}" style="vertical-align: top;" /> <strong><span style="color: #ffa50d">{{ transfer.price|number_format(2,'.',',') }}</span></strong>
  589.                                     </div>
  590.                                 </div>
  591.                             </div>
  592.                             {% endif %}
  593.                         {% endfor %}
  594.                     {% endif %}
  595.                     </div>
  596.                 </div>
  597.             </div>
  598.             <div class="grid-container" style="margin-top: 15px; background: #252534; padding: 35px 50px; border-radius: 10px;">
  599.                 <div class="grid-x">
  600.                     <div class="small-12 cell">
  601.                         <h2 id="asset-offers">Offers</h2>
  602.                     </div>
  603.                     <div class="small-12 cell">
  604.                         {% if assetMetadata.nftHub.activeMarketOffers|length == 0 %}
  605.                             <p>No offers exist for this asset.</p>
  606.                         {% else %}
  607.                             {% for offer in assetMetadata.nftHub.activeMarketOffers %}
  608.                                 <div class="grid-container" style="padding: 3px 0;">
  609.                                     <div class="grid-x">
  610.                                         <div class="small-12 medium-5 cell">
  611.                                             {% if offer.bidder.user.username is defined %}
  612.                                                 <span class="nft-detail-text"><span class="highlight"><a href="{{ path('user_profile', { userId: offer.bidder.user.id, domain: app_domain }) }}">{{ offer.bidder.user.username is defined ? offer.bidder.user.username : ''}} ({{ offer.bidder.address|slice(0,6) }}...{{ offer.bidder.address|slice(38,42) }})</a></span></span></p>
  613.                                             {% elseif offer.bidder.address is defined %}
  614.                                                 <a href="https://explorer.thetatoken.org/account/{{ offer.bidder.address }}" target="_blank">{{ offer.bidder.address|slice(0,6) }}...{{ offer.bidder.address|slice(38,42) }}</a>
  615.                                             {% endif %}
  616.                                         </div>
  617.                                         <div class="small-12 medium-4 cell">
  618.                                             <img alt="" height="20" width="20" src="{{ asset('build/images/web/tfuel-logo.svg') }}" style="vertical-align: top;" /> <strong><span style="color: #ffa50d">{{ offer.price|number_format(2,'.',',') }}</span></strong>
  619.                                         </div>
  620.                                         <div class="small-12 medium-3 cell">
  621.                                             {# If the current User is the owner of this item, we need to show Accept Offer buttons #}
  622.                                             {# However, they can only accept if this item is not actively listed in the market #}
  623.                                             {# They also need to have approved market permissions #}
  624.                                             {# If Main Token #}
  625.                                             {% if assetMetadata.nftHub.nftContract.id == 1 %}
  626.                                                 {% if app.user.activeWallet and app.user.activeWallet.isApprovedForAllMarket2 is same as(false) %}
  627.                                                     <button class="button initiateAcceptMarketOffer {{ app.user.walletExtension == 1 ? 'ext-theta' : 'ext-meta' }}" data-open="acceptMarketOffer-{{ offer.id }}" style="display: none;">Accept Offer</button>
  628.                                                     {% include 'marketplace/modals/setApprovalForAll.html.twig' with {'assetMetadata': assetMetadata, 'app': app, 'buttonText': 'Accept Offer'} %}
  629.                                                     {% include 'marketplace/modals/acceptMarketOffer.html.twig' with {'marketOffer' : offer, 'assetMetadata' : assetMetadata, 'app': app } %}
  630.                                                 {% elseif assetMetadata.nftHub.activeMarketItem is not empty and app.user.activeWallet == assetMetadata.nftHub.activeMarketItem|first.seller %}
  631.                                                     <button class="button initiateAcceptMarketOffer"
  632.                                                             data-open="conflict-cancelMarketItem-{{ assetMetadata.nftHub.activeMarketItem|first.id }}"
  633.                                                             style="width: 100%; font-size: .8em; font-weight: bold;">Accept Offer
  634.                                                     </button>
  635.                                                     <div class="reveal" id="conflict-cancelMarketItem-{{ assetMetadata.nftHub.activeMarketItem|first.id }}" data-reveal
  636.                                                          style="text-align: center; background: #1f1f29; border-radius: 15px; border: none;">
  637.                                                         <h1>Active Market Exists</h1>
  638.                                                         <img height="100" width="100" src="{{ asset('build/images/web/warning.svg') }}" />
  639.                                                         <p>You must cancel your Market listing for this item before you can accept an Offer.</p>
  640.                                                         <button class="close-button" data-close aria-label="Close modal" type="button">
  641.                                                             <span aria-hidden="true">&times;</span>
  642.                                                         </button>
  643.                                                     </div>
  644.                                                 {% else %}
  645.                                                     {% if (app.user and app.user.activeWallet is defined) and app.user.activeWallet == assetMetadata.nftHub.thetaWallet %}
  646.                                                         <button class="button initiateAcceptMarketOffer {{ app.user.walletExtension == 1 ? 'ext-theta' : 'ext-meta' }}" data-open="acceptMarketOffer-{{ offer.id }}">Accept Offer</button>
  647.                                                         {% include 'marketplace/modals/acceptMarketOffer.html.twig' with {'marketOffer' : offer, 'assetMetadata' : assetMetadata, 'app': app } %}
  648.                                                     {% endif %}
  649.                                                 {% endif %}
  650.                                             {% elseif assetMetadata.nftHub.nftContract.id == 4 %}
  651.                                                 {# If Crate Token #}
  652.                                                 {% if app.user.activeWallet and app.user.activeWallet.isApprovedForAllMarketCrate is same as(false) %}
  653.                                                     <button class="button initiateAcceptMarketOffer {{ app.user.walletExtension == 1 ? 'ext-theta' : 'ext-meta' }}" data-open="acceptMarketOffer-{{ offer.id }}" style="display: none;">Accept Offer</button>
  654.                                                     {% include 'marketplace/modals/setApprovalForAll.html.twig' with {'assetMetadata': assetMetadata, 'app': app, 'buttonText': 'Accept Offer'} %}
  655.                                                     {% include 'marketplace/modals/acceptMarketOffer.html.twig' with {'marketOffer' : offer, 'assetMetadata' : assetMetadata, 'app': app } %}
  656.                                                 {% elseif assetMetadata.nftHub.activeMarketItem is not empty and app.user.activeWallet == assetMetadata.nftHub.activeMarketItem|first.seller %}
  657.                                                     <button class="button initiateAcceptMarketOffer"
  658.                                                             data-open="conflict-cancelMarketItem-{{ assetMetadata.nftHub.activeMarketItem|first.id }}"
  659.                                                             style="width: 100%; font-size: .8em; font-weight: bold;">Accept Offer
  660.                                                     </button>
  661.                                                     <div class="reveal" id="conflict-cancelMarketItem-{{ assetMetadata.nftHub.activeMarketItem|first.id }}" data-reveal
  662.                                                          style="text-align: center; background: #1f1f29; border-radius: 15px; border: none;">
  663.                                                         <h1>Active Market Exists</h1>
  664.                                                         <img height="100" width="100" src="{{ asset('build/images/web/warning.svg') }}" />
  665.                                                         <p>You must cancel your Market listing for this item before you can accept an Offer.</p>
  666.                                                         <button class="close-button" data-close aria-label="Close modal" type="button">
  667.                                                             <span aria-hidden="true">&times;</span>
  668.                                                         </button>
  669.                                                     </div>
  670.                                                 {% else %}
  671.                                                     {% if (app.user and app.user.activeWallet is defined) and app.user.activeWallet == assetMetadata.nftHub.thetaWallet %}
  672.                                                         <button class="button initiateAcceptMarketOffer {{ app.user.walletExtension == 1 ? 'ext-theta' : 'ext-meta' }}" data-open="acceptMarketOffer-{{ offer.id }}">Accept Offer</button>
  673.                                                         {% include 'marketplace/modals/acceptMarketOffer.html.twig' with {'marketOffer' : offer, 'assetMetadata' : assetMetadata, 'app': app } %}
  674.                                                     {% endif %}
  675.                                                 {% endif %}
  676.                                             {% endif %}
  677.                                         </div>
  678.                                     </div>
  679.                                 </div>
  680.                             {% endfor %}
  681.                         {% endif %}
  682.                     </div>
  683.                 </div>
  684.             </div>
  685.         </div>
  686.     </div>
  687. </div>
  688. {% endblock %}