(window.webpackJsonp=window.webpackJsonp||[]).push([[14],{11:function(t,e,n){t.exports=n("v6kC")},"9tPo":function(t,e){t.exports=function(t){var e="undefined"!=typeof window&&window.location;if(!e)throw new Error("fixUrls requires window.location");if(!t||"string"!=typeof t)return t;var n=e.protocol+"//"+e.host,r=n+e.pathname.replace(/\/[^\/]*$/,"/");return t.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi,(function(t,e){var o,i=e.trim().replace(/^"(.*)"$/,(function(t,e){return e})).replace(/^'(.*)'$/,(function(t,e){return e}));return/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/|\s*$)/i.test(i)?t:(o=0===i.indexOf("//")?i:0===i.indexOf("/")?n+i:r+i.replace(/^\.\//,""),"url("+JSON.stringify(o)+")")}))}},I1BE:function(t,e){t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var n=function(t,e){var n=t[1]||"",r=t[3];if(!r)return n;if(e&&"function"==typeof btoa){var o=(s=r,"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(s))))+" */"),i=r.sources.map((function(t){return"/*# sourceURL="+r.sourceRoot+t+" */"}));return[n].concat(i).concat([o]).join("\n")}var s;return[n].join("\n")}(e,t);return e[2]?"@media "+e[2]+"{"+n+"}":n})).join("")},e.i=function(t,n){"string"==typeof t&&(t=[[null,t,""]]);for(var r={},o=0;o=0&&f.splice(e,1)}function m(t){var e=document.createElement("style");if(void 0===t.attrs.type&&(t.attrs.type="text/css"),void 0===t.attrs.nonce){var r=function(){0;return n.nc}();r&&(t.attrs.nonce=r)}return y(e,t.attrs),h(t,e),e}function y(t,e){Object.keys(e).forEach((function(n){t.setAttribute(n,e[n])}))}function g(t,e){var n,r,o,i;if(e.transform&&t.css){if(!(i="function"==typeof e.transform?e.transform(t.css):e.transform.default(t.css)))return function(){};t.css=i}if(e.singleton){var s=l++;n=u||(u=m(e)),r=C.bind(null,n,s,!1),o=C.bind(null,n,s,!0)}else t.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(n=function(t){var e=document.createElement("link");return void 0===t.attrs.type&&(t.attrs.type="text/css"),t.attrs.rel="stylesheet",y(e,t.attrs),h(t,e),e}(e),r=S.bind(null,n,e),o=function(){b(n),n.href&&URL.revokeObjectURL(n.href)}):(n=m(e),r=x.bind(null,n),o=function(){b(n)});return r(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;r(t=e)}else o()}}t.exports=function(t,e){if("undefined"!=typeof DEBUG&&DEBUG&&"object"!=typeof document)throw new Error("The style-loader cannot be used in a non-browser environment");(e=e||{}).attrs="object"==typeof e.attrs?e.attrs:{},e.singleton||"boolean"==typeof e.singleton||(e.singleton=s()),e.insertInto||(e.insertInto="head"),e.insertAt||(e.insertAt="bottom");var n=v(t,e);return p(n,e),function(t){for(var r=[],o=0;o0&&!this.paused&&!this.ended&&this.readyState>2)}});var r={data:function(){return{loading:!0,version:1,loops:[],tab:"new"}},mounted:function(){var t=this;axios.get("/api/v2/loops").then((function(e){t.loops=e.data,t.loading=!1}))},methods:{videoSrc:function(t){return t.media_attachments[0].url},posterSrc:function(t){return t.media_attachments[0].preview_url},setTab:function(t){this.tab=t},toggleVideo:function(t,e){var n=e.target;$("video").each((function(){n.src!=$(this)[0].src&&$(this)[0].pause()})),n.playing?n.pause():n.play()},incrementLoop:function(t){},timestamp:function(t){return new Date(t.created_at).toLocaleDateString()},getTitle:function(t){return(t.content?t.content:"Untitled").trim()},truncate:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:15;return _.truncate(t,{length:e})}}},o=(n("ZmVo"),n("KHd+")),i=Object(o.a)(r,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"w-100 h-100"},[t.loading?n("div",{staticClass:"d-flex justify-content-center align-items-center",staticStyle:{"min-height":"400px"}},[n("img",{attrs:{src:"/img/pixelfed-icon-grey.svg"}})]):n("div",[n("div",{staticClass:"mb-4"},[n("p",{staticClass:"text-center"},[n("a",{class:["new"==t.tab?"btn font-weight-bold py-0 btn-success":"btn font-weight-bold py-0 btn-outline-success"],attrs:{href:"#"},on:{click:function(e){return e.preventDefault(),t.setTab("new")}}},[t._v("New")]),t._v(" "),n("a",{class:["about"==t.tab?"btn font-weight-bold py-0 btn-success":"btn font-weight-bold py-0 btn-outline-success"],attrs:{href:"#"},on:{click:function(e){return e.preventDefault(),t.setTab("about")}}},[t._v("About")])])]),t._v(" "),"about"!=t.tab?n("div",{staticClass:"row loops-container"},t._l(t.loops,(function(e,r){return n("div",{staticClass:"col-12 col-md-4 mb-3"},[n("div",{staticClass:"card border border-success"},[n("div",{staticClass:"embed-responsive embed-responsive-1by1"},[n("video",{staticClass:"embed-responsive-item",attrs:{src:t.videoSrc(e),preload:"none",width:"100%",height:"100%",loop:"",poster:t.posterSrc(e)},on:{click:function(n){return t.toggleVideo(e,n)}}})]),t._v(" "),n("div",{staticClass:"card-body"},[n("p",{staticClass:"username font-weight-bolder lead d-flex justify-content-between"},[n("a",{attrs:{href:e.account.url,title:e.account.acct}},[t._v(t._s(t.truncate(e.account.acct)))]),t._v(" "),n("a",{attrs:{href:e.url}},[t._v(t._s(t.timestamp(e)))])]),t._v(" "),n("p",{staticClass:"small text-muted text-truncate",domProps:{innerHTML:t._s(t.getTitle(e))}}),t._v(" "),n("div",{staticClass:"small text-muted d-flex justify-content-between mb-0"},[n("span",[t._v(t._s(e.favourites_count)+" Likes")]),t._v(" "),n("span",[t._v(t._s(e.reblogs_count)+" Shares")]),t._v(" "),n("span",[t._v(t._s(e.reply_count)+" Comments")])])])])])})),0):n("div",{staticClass:"col-12"},[t._m(0)])])])}),[function(){var t=this.$createElement,e=this._self._c||t;return e("div",{staticClass:"card"},[e("div",{staticClass:"card-body"},[e("p",{staticClass:"lead text-center mb-0"},[this._v("Loops are an exciting new way to explore short videos on Pixelfed.")])])])}],!1,null,null,null);e.default=i.exports},iXJE:function(t,e,n){var r=n("LsAn");"string"==typeof r&&(r=[[t.i,r,""]]);var o={hmr:!0,transform:void 0,insertInto:void 0};n("aET+")(r,o);r.locals&&(t.exports=r.locals)},v6kC:function(t,e,n){Vue.component("loops-component",n("i8Ta").default)}},[[11,0]]]);