Created
November 20, 2017 15:11
-
-
Save mdunbavan/a712dbdf8fee618beee96504543760d4 to your computer and use it in GitHub Desktop.
Raw html from within script tag
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
{% raw %} | |
<script type="text/html" id="hit-template-inner"> | |
<span class="hit bg Grid-fill product--hover db" style="background-image:url({{frontImage}});"> | |
<div class="block db"> | |
<div class="absolute top-1 left-1 share-hover link z-2"> | |
<svg class="share-icon absolute" width="19" height="18"> | |
<use class="no-barba" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/dist/images/icons.svg#share_icon"></use> | |
</svg> | |
<ul class="ma0 pa0 mb4 list share-list relative"> | |
<li class="dib v-top mw2"> | |
<div class="icon icon--kudos_icon"> | |
<a class="share twitter" href="https://twitter.com/share?url={{{url}}}&text={{{ title }}}&hashtags=test"> | |
<svg width="100%" height="20"> | |
<use class="no-barba" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/dist/images/icons.svg#twitter_logo"></use> | |
</svg> | |
</a> | |
</div> | |
</li> | |
<li class="dib v-top mw2"> | |
<div class="icon icon--kudos_icon"> | |
<a class="share facebook" href="https://www.facebook.com/sharer.php?u={{{ url }}}"> | |
<svg width="100%" height="20"> | |
<use class="no-barba" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/dist/images/icons.svg#facebook_logo"></use> | |
</svg> | |
</a> | |
</div> | |
</li> | |
<li class="dib v-top mw2"> | |
<div class="icon icon--kudos_icon"> | |
<a class="share pinterest" href="http://pinterest.com/pin/create/button/?url={{{ url }}}&media={{ frontImage }}&description={{{ title }}}"> | |
<svg width="100%" height="20"> | |
<use class="no-barba" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/dist/images/icons.svg#pinterest_logo"></use> | |
</svg> | |
</a> | |
</div> | |
</li> | |
</ul> | |
</div> | |
<a href="#" class="absolute bottom-1 left-1 link gray z-2 quickView--button"> | |
<span style="display: none;" class="product-data">{{{quickViewJson}}}</span> | |
<svg class="v-mid" width="19" height="18"> | |
<use class="no-barba" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/dist/images/icons.svg#colour_icon"></use> | |
</svg> | |
<span class="v-mid">({{{ variantsAmount }}})</span> | |
</a> | |
{% endraw %} | |
{% if craft.like.isLike(product.id) %} | |
<a href="/index.php?p=actions/like/add&id={% raw %}{{{id}}}{% endraw %}" data-id="{% raw %}{{{id}}}{% endraw %}" class="absolute top-1 right-1 z-2 addFavourite--button productAdded"> | |
<div style="right: 40px;" class="absolute top-0 dib pa3 bg-white black status"></div> | |
<div class="svg-status"> | |
<svg width="19" height="18"> | |
<use class="no-barba" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/dist/images/icons.svg#favourite_icon_added"></use> | |
</svg> | |
</div> | |
</a> | |
{% else %} | |
<a href="/index.php?p=actions/like/remove&id={% raw %}{{{id}}}{% endraw %}" data-id="{% raw %}{{{id}}}{% endraw %}" class="absolute top-1 right-1 z-2 addFavourite--button"> | |
<div style="right: 40px;" class="absolute top-0 dib pa3 bg-white black status"></div> | |
<div class="svg-status"> | |
<svg width="19" height="18"> | |
<use class="no-barba" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="/dist/images/icons.svg#favourite_icon"></use> | |
</svg> | |
</div> | |
</a> | |
{% endif %} | |
{% raw %} | |
<a href="{{{url}}}" style="display: block;width: 100%;height: 100%;position: absolute;left: 0;top: 0;z-index: 1;"></a> | |
</div> | |
</span> | |
<div class="mv2 lh-copy"> | |
<p class="text-product">{{{title}}}<br> | |
{{{brand}}} | |
for {{{designer}}}<br> | |
</p> | |
<p> | |
{{{price}}} | |
</div> | |
</script> | |
{% endraw %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment