Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Update to fix the Instagram Section for Focal—premium Shopify theme
<script>
window.addEventListener("DOMContentLoaded",function(){var a=function(a){var e=new Date(1e3*a.created_time),t=e.getMonth(),n=e.getDate(),i=e.getFullYear(),r=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];return a.created_time=r[t]+" "+n+", "+i,!0},e=function(e){var t={% raw %}'<div class="instagram-fix grid__cell 1/2 1/3--handheld-and-up 1/'+e.attr("data-images-per-row")+'--lap-and-up"><div class="instagram__image-wrapper" style="background-image: url({{image}})"><a href="{{link}}" target="_blank"><div class="instagram__overlay"><p class="instagram__caption">{{caption}}</p><time class="instagram__date">{{model.created_time}}</time></div></a></div></div>'{% endraw %};new Instafeed({get:"user",userId:"self",accessToken:e.attr("data-access-token"),sortBy:"most-recent",limit:e.attr("data-limit-images"),resolution:"standard_resolution",template:t,filter:$.proxy(a)}).run()};$(".index-module__instagram[data-access-token]").each(function(a,t){e($(t))})});
</script>
<style>
.instagram__image-wrapper {
background-size: cover;
background-position: center;
}
.instagram__image-wrapper > a {
display: block;
padding-bottom: 100%;
}
.instagram__image--placeholder {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
.instafeed .grid__cell:not(.instagram-fix) {
display: none !important;
}
</style>
@bakura10

This comment has been minimized.

Copy link
Owner Author

commented Jan 12, 2018

For installation instructions, please refer to the documentation: http://support.maestrooo.com/article/155-update-to-fix-the-instagram-section-for-focal.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.