pixelfed/public/js/portfolio.js

2 lines
44 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/*! For license information please see portfolio.js.LICENSE.txt */
"use strict";(self.webpackChunkpixelfed=self.webpackChunkpixelfed||[]).push([[1336],{2508:(t,e,r)=>{function n(t){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n(t)}function o(){o=function(){return e};var t,e={},r=Object.prototype,s=r.hasOwnProperty,i=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},c=a.iterator||"@@iterator",l=a.asyncIterator||"@@asyncIterator",u=a.toStringTag||"@@toStringTag";function d(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{d({},"")}catch(t){d=function(t,e,r){return t[e]=r}}function f(t,e,r,n){var o=e&&e.prototype instanceof b?e:b,s=Object.create(o.prototype),a=new I(n||[]);return i(s,"_invoke",{value:j(t,r,a)}),s}function h(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=f;var p="suspendedStart",v="suspendedYield",m="executing",g="completed",y={};function b(){}function _(){}function w(){}var x={};d(x,c,(function(){return this}));var C=Object.getPrototypeOf,k=C&&C(C(R([])));k&&k!==r&&s.call(k,c)&&(x=k);var S=w.prototype=b.prototype=Object.create(x);function P(t){["next","throw","return"].forEach((function(e){d(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(o,i,a,c){var l=h(t[o],t,i);if("throw"!==l.type){var u=l.arg,d=u.value;return d&&"object"==n(d)&&s.call(d,"__await")?e.resolve(d.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(d).then((function(t){u.value=t,a(u)}),(function(t){return r("throw",t,a,c)}))}c(l.arg)}var o;i(this,"_invoke",{value:function(t,n){function s(){return new e((function(e,o){r(t,n,e,o)}))}return o=o?o.then(s,s):s()}})}function j(e,r,n){var o=p;return function(s,i){if(o===m)throw new Error("Generator is already running");if(o===g){if("throw"===s)throw i;return{value:t,done:!0}}for(n.method=s,n.arg=i;;){var a=n.delegate;if(a){var c=O(a,n);if(c){if(c===y)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=g,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=m;var l=h(e,r,n);if("normal"===l.type){if(o=n.done?g:v,l.arg===y)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=g,n.method="throw",n.arg=l.arg)}}}function O(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,O(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),y;var s=h(o,e.iterator,r.arg);if("throw"===s.type)return r.method="throw",r.arg=s.arg,r.delegate=null,y;var i=s.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,y):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y)}function E(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function T(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function I(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(E,this),this.reset(!0)}function R(e){if(e||""===e){var r=e[c];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(s.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(n(e)+" is not iterable")}return _.prototype=w,i(S,"constructor",{value:w,configurable:!0}),i(w,"constructor",{value:_,configurable:!0}),_.displayName=d(w,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===_||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,w):(t.__proto__=w,d(t,u,"GeneratorFunction")),t.prototype=Object.create(S),t},e.awrap=function(t){return{__await:t}},P(L.prototype),d(L.prototype,l,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,n,o,s){void 0===s&&(s=Promise);var i=new L(f(t,r,n,o),s);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},P(S),d(S,u,"Generator"),d(S,c,(function(){return this})),d(S,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=R,I.prototype={constructor:I,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(T),!e)for(var r in this)"t"===r.charAt(0)&&s.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function n(n,o){return a.type="throw",a.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=s.call(i,"catchLoc"),l=s.call(i,"finallyLoc");if(c&&l){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!l)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc<=this.prev&&s.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var o=n;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=e&&e<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=t,i.arg=e,o?(this.method="next",this.next=o.finallyLoc,y):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),T(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;T(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:R(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y}},e}function s(t,e,r,n,o,s,i){try{var a=t[s](i),c=a.value}catch(t){return void r(t)}a.done?e(c):Promise.resolve(c).then(n,o)}r.r(e),r.d(e,{default:()=>i});const i={props:["initialData"],data:function(){return{loading:!0,isAuthed:void 0,user:void 0,settings:void 0,post:void 0,profile:void 0,settingsUrl:window._portfolio.path+"/settings"}},mounted:function(){var t=JSON.parse(this.initialData);this.post=t.post,this.profile=t.profile,this.isAuthed=t.authed,this.fetchUser()},methods:{fetchUser:function(){var t,e=this;return(t=o().mark((function t(){return o().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!e.isAuthed){t.next=3;break}return t.next=3,axios.get("/api/v1/accounts/verify_credentials").then((function(t){e.user=t.data})).catch((function(t){}));case 3:return t.next=5,axios.get("/api/portfolio/account/settings.json",{params:{id:e.profile.id}}).then((function(t){e.settings=t.data,t.data.hasOwnProperty("background_color")&&e.updateCssVariable("--body-bg",t.data.background_color),t.data.hasOwnProperty("text_color")&&(e.updateCssVariable("--text-color",t.data.text_color),e.updateCssVariable("--link-color",t.data.text_color))})).then((function(){setTimeout((function(){e.loading=!1}),500)}));case 5:case"end":return t.stop()}}),t)})),function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){s(i,n,o,a,c,"next",t)}function c(t){s(i,n,o,a,c,"throw",t)}a(void 0)}))})()},profileUrl:function(){return"https://".concat(window._portfolio.domain).concat(window._portfolio.path,"/").concat(this.profile.username)},postUrl:function(t){return"/".concat(this.profile.username,"/").concat(t.id)},formatDate:function(t){return new Date(t).toLocaleDateString(void 0,{weekday:"short",year:"numeric",month:"long",day:"numeric"})},updateCssVariable:function(t,e){document.querySelector(":root").style.setProperty(t,e)}}}},46418:(t,e,r)=>{r.r(e),r.d(e,{default:()=>c});r(4155),r(4570);var n=r(19755);function o(t){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},o(t)}function s(){s=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,i=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},c=a.iterator||"@@iterator",l=a.asyncIterator||"@@asyncIterator",u=a.toStringTag||"@@toStringTag";function d(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{d({},"")}catch(t){d=function(t,e,r){return t[e]=r}}function f(t,e,r,n){var o=e&&e.prototype instanceof b?e:b,s=Object.create(o.prototype),a=new I(n||[]);return i(s,"_invoke",{value:j(t,r,a)}),s}function h(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=f;var p="suspendedStart",v="suspendedYield",m="executing",g="completed",y={};function b(){}function _(){}function w(){}var x={};d(x,c,(function(){return this}));var C=Object.getPrototypeOf,k=C&&C(C(R([])));k&&k!==r&&n.call(k,c)&&(x=k);var S=w.prototype=b.prototype=Object.create(x);function P(t){["next","throw","return"].forEach((function(e){d(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(s,i,a,c){var l=h(t[s],t,i);if("throw"!==l.type){var u=l.arg,d=u.value;return d&&"object"==o(d)&&n.call(d,"__await")?e.resolve(d.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(d).then((function(t){u.value=t,a(u)}),(function(t){return r("throw",t,a,c)}))}c(l.arg)}var s;i(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return s=s?s.then(o,o):o()}})}function j(e,r,n){var o=p;return function(s,i){if(o===m)throw new Error("Generator is already running");if(o===g){if("throw"===s)throw i;return{value:t,done:!0}}for(n.method=s,n.arg=i;;){var a=n.delegate;if(a){var c=O(a,n);if(c){if(c===y)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=g,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=m;var l=h(e,r,n);if("normal"===l.type){if(o=n.done?g:v,l.arg===y)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=g,n.method="throw",n.arg=l.arg)}}}function O(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,O(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),y;var s=h(o,e.iterator,r.arg);if("throw"===s.type)return r.method="throw",r.arg=s.arg,r.delegate=null,y;var i=s.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,y):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y)}function E(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function T(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function I(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(E,this),this.reset(!0)}function R(e){if(e||""===e){var r=e[c];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var s=-1,i=function r(){for(;++s<e.length;)if(n.call(e,s))return r.value=e[s],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(o(e)+" is not iterable")}return _.prototype=w,i(S,"constructor",{value:w,configurable:!0}),i(w,"constructor",{value:_,configurable:!0}),_.displayName=d(w,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===_||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,w):(t.__proto__=w,d(t,u,"GeneratorFunction")),t.prototype=Object.create(S),t},e.awrap=function(t){return{__await:t}},P(L.prototype),d(L.prototype,l,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,n,o,s){void 0===s&&(s=Promise);var i=new L(f(t,r,n,o),s);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},P(S),d(S,u,"Generator"),d(S,c,(function(){return this})),d(S,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=R,I.prototype={constructor:I,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(T),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return a.type="throw",a.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var s=this.tryEntries.length-1;s>=0;--s){var i=this.tryEntries[s],a=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),l=n.call(i,"finallyLoc");if(c&&l){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!l)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var s=o;break}}s&&("break"===t||"continue"===t)&&s.tryLoc<=e&&e<=s.finallyLoc&&(s=null);var i=s?s.completion:{};return i.type=t,i.arg=e,s?(this.method="next",this.next=s.finallyLoc,y):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),T(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;T(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:R(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y}},e}function i(t,e,r,n,o,s,i){try{var a=t[s](i),c=a.value}catch(t){return void r(t)}a.done?e(c):Promise.resolve(c).then(n,o)}function a(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var s=t.apply(e,r);function a(t){i(s,n,o,a,c,"next",t)}function c(t){i(s,n,o,a,c,"throw",t)}a(void 0)}))}}const c={props:["initialData"],data:function(){return{loading:!0,user:void 0,profile:void 0,settings:void 0,feed:[],albumIndex:0,settingsUrl:window._portfolio.path+"/settings"}},mounted:function(){var t=JSON.parse(this.initialData);this.profile=t.profile,this.fetchUser()},methods:{fetchUser:function(){var t=this;return a(s().mark((function e(){return s().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return axios.get("/api/v1/accounts/verify_credentials").then((function(e){t.user=e.data})).catch((function(t){})),e.next=3,axios.get("/api/portfolio/account/settings.json",{params:{id:t.profile.id}}).then((function(e){t.settings=e.data,e.data.hasOwnProperty("background_color")&&t.updateCssVariable("--body-bg",e.data.background_color),e.data.hasOwnProperty("text_color")&&(t.updateCssVariable("--text-color",e.data.text_color),t.updateCssVariable("--link-color",e.data.text_color))})).then((function(){t.fetchFeed()}));case 3:case"end":return e.stop()}}),e)})))()},fetchFeed:function(){var t=this;return a(s().mark((function e(){return s().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:axios.get("/api/portfolio/"+t.profile.id+"/feed").then((function(e){t.feed=e.data.filter((function(t){return["photo","photo:album"].includes(t.pf_type)}))})).then((function(){t.setAlbumSlide()})).then((function(){setTimeout((function(){t.loading=!1}),500)})).then((function(){"masonry"===t.settings.profile_layout&&setTimeout((function(){t.initMasonry()}),500)})).then((function(){setTimeout((function(){t.bootIntersectors()}),500)})).catch((function(e){t.loading=!1}));case 1:case"end":return e.stop()}}),e)})))()},postUrl:function(t){return"".concat(window._portfolio.path,"/").concat(this.profile.username,"/").concat(t.id)},albumPrev:function(){if(0!==this.albumIndex){if(1===this.albumIndex){this.albumIndex--;var t=new URL(window.location);return t.searchParams.delete("slide"),void window.history.pushState({},"",t)}this.albumIndex--;var e=new URL(window.location);e.searchParams.set("slide",this.albumIndex+1),window.history.pushState({},"",e)}},albumNext:function(){if(this.albumIndex!==this.feed.length-1){this.albumIndex++;var t=new URL(window.location);t.searchParams.set("slide",this.albumIndex+1),window.history.pushState({},"",t)}},setAlbumSlide:function(){var t=new URL(window.location);if(t.searchParams.has("slide")){var e=Number.parseInt(t.searchParams.get("slide"));if(Number.isNaN(e))return;if(e<=0)return;if(e>this.feed.length)return;this.albumIndex=t.searchParams.get("slide")-1}},initMasonry:function(){n('[data-fancybox="recent"]').fancybox({gutter:20,modal:!1})},updateCssVariable:function(t,e){document.querySelector(":root").style.setProperty(t,e)},bootIntersectors:function(){var t=[].slice.call(document.querySelectorAll("img.img-placeholder"));if("IntersectionObserver"in window){var e=new IntersectionObserver((function(t,r){t.forEach((function(t){if(t.isIntersecting){var r=t.target;r.src=r.dataset.src,r.style.zIndex=2,r.classList.remove("img-placeholder"),e.unobserve(r)}}))}));t.forEach((function(t){e.observe(t)}))}else t.forEach((function(t){t.src=t.dataset.src,t.style.zIndex=2}))}}}},11109:(t,e,r)=>{r.r(e),r.d(e,{default:()=>n});const n={data:function(){return{loading:!0,tabIndex:"Configure",tabs:["Configure","Customize","View Portfolio"],user:void 0,settings:void 0,recentPostsLoaded:!1,rpStart:0,recentPosts:[],recentPostsPage:void 0,selectedRecentPosts:[],isSavingCurated:!1,canSaveCurated:!1,customizeSettings:[],skipWatch:!1,profileSourceOptions:[{value:null,text:"Please select an option",disabled:!0},{value:"recent",text:"Most recent posts"}],profileLayoutOptions:[{value:null,text:"Please select an option",disabled:!0},{value:"grid",text:"Grid"},{value:"masonry",text:"Masonry"},{value:"album",text:"Album"}],profileLayoutColorSchemeOptions:[{value:null,text:"Please select an option",disabled:!0},{value:"light",text:"Light mode"},{value:"dark",text:"Dark mode"},{value:"custom",text:"Custom color scheme",disabled:!0}],profileLayoutFeedOrder:[{value:"oldest",text:"Oldest first"},{value:"recent",text:"Recent first"}]}},computed:{prevClass:function(){return 0===this.rpStart?"fa fa-arrow-circle-left fa-3x text-dark":"fa fa-arrow-circle-left fa-3x text-muted cursor-pointer"},nextClass:function(){return this.rpStart>this.recentPosts.length-9?"fa fa-arrow-circle-right fa-3x text-dark":"fa fa-arrow-circle-right fa-3x text-muted cursor-pointer"}},watch:{settings:{deep:!0,immediate:!0,handler:function(t,e){this.loading||this.skipWatch||(e.show_timestamp||(this.settings.show_link=!1),this.updateSettings())}}},mounted:function(){this.fetchUser()},methods:{fetchUser:function(){var t=this;axios.get("/api/v1/accounts/verify_credentials").then((function(e){t.user=e.data,e.data.statuses_count>0?t.profileSourceOptions=[{value:null,text:"Please select an option",disabled:!0},{value:"recent",text:"Most recent posts"},{value:"custom",text:"Curated posts"}]:setTimeout((function(){t.settings.active=!1,t.settings.profile_source="recent",t.tabIndex="Configure"}),1e3)})),axios.post(this.apiPath("/api/portfolio/self/settings.json")).then((function(e){t.settings=e.data,t.updateTabs(),e.data.metadata&&e.data.metadata.posts&&(t.selectedRecentPosts=e.data.metadata.posts),"dark"!=e.data.color_scheme&&("light"===e.data.color_scheme?t.updateBackgroundColor("#ffffff"):(e.data.hasOwnProperty("background_color")&&t.updateBackgroundColor(e.data.background_color),e.data.hasOwnProperty("text_color")&&t.updateTextColor(e.data.text_color)))})).then((function(){t.initCustomizeSettings()})).then((function(){var e=new URL(window.location);if(e.searchParams.has("tab")){var r=e.searchParams.get("tab");-1!==("custom"===t.settings.profile_source?["curate","customize","share"]:["customize","share"]).indexOf(r)&&t.toggleTab(r.slice(0,1).toUpperCase()+r.slice(1))}})).then((function(){setTimeout((function(){t.loading=!1}),500)}))},apiPath:function(t){return t},toggleTab:function(t){if("Curate"!==t||this.recentPostsLoaded||this.loadRecentPosts(),this.tabIndex=t,this.rpStart=0,"Configure"==t){var e=new URL(window.location);e.searchParams.delete("tab"),window.history.pushState({},"",e)}else{if("View Portfolio"==t)return this.tabIndex="Configure",void(window.location.href="https://".concat(window._portfolio.domain).concat(window._portfolio.path,"/").concat(this.user.username));var r=new URL(window.location);r.searchParams.set("tab",t.toLowerCase()),window.history.pushState({},"",r)}},updateTabs:function(){"custom"===this.settings.profile_source?this.tabs=["Configure","Curate","Customize","View Portfolio"]:this.tabs=["Configure","Customize","View Portfolio"]},updateSettings:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.skipWatch||axios.post(this.apiPath("/api/portfolio/self/update-settings.json"),this.settings).then((function(r){t.updateTabs(),e||t.$bvToast.toast("Your settings have been successfully updated!",{variant:"dark",title:"Settings Updated",autoHideDelay:2e3,appendToast:!1})}))},loadRecentPosts:function(){var t=this;axios.get("/api/v1/accounts/"+this.user.id+"/statuses?only_media=1&media_types=photo&limit=100&_pe=1").then((function(e){e.data.length&&(t.recentPosts=e.data.filter((function(t){return["photo","photo:album"].includes(t.pf_type)&&"public"===t.visibility})))})).then((function(){setTimeout((function(){t.recentPostsLoaded=!0}),500)}))},toggleRecentPost:function(t){if(-1==this.selectedRecentPosts.indexOf(t)){if(100===this.selectedRecentPosts.length)return;this.selectedRecentPosts.push(t)}else this.selectedRecentPosts=this.selectedRecentPosts.filter((function(e){return e!==t}));this.canSaveCurated=!0},recentPostsPrev:function(){0!==this.rpStart&&(this.rpStart=this.rpStart-9)},recentPostsNext:function(){this.rpStart>this.recentPosts.length-9||(this.rpStart=this.rpStart+9)},clearSelected:function(){this.selectedRecentPosts=[]},saveCurated:function(){var t,e=this;this.isSavingCurated=!0,null===(t=event.currentTarget)||void 0===t||t.blur(),axios.post("/api/portfolio/self/curated.json",{ids:this.selectedRecentPosts}).then((function(t){e.isSavingCurated=!1,e.$bvToast.toast("Your curated posts have been updated!",{variant:"dark",title:"Portfolio Updated",autoHideDelay:2e3,appendToast:!1})})).catch((function(t){e.isSavingCurated=!1,e.$bvToast.toast("An error occured while attempting to update your portfolio, please try again later and contact an admin if this problem persists.",{variant:"dark",title:"Error",autoHideDelay:2e3,appendToast:!1})}))},initCustomizeSettings:function(){this.customizeSettings=[{title:"Post Settings",items:[{label:"Show Captions",model:"show_captions"},{label:"Show License",model:"show_license"},{label:"Show Location",model:"show_location"},{label:"Show Timestamp",model:"show_timestamp"},{label:"Link to Post",description:"Add link to timestamp to view the original post url, requires show timestamp to be enabled",model:"show_link",requiredWithTrue:"show_timestamp"}]},{title:"Profile Settings",items:[{label:"Show Avatar",model:"show_avatar"},{label:"Show Bio",model:"show_bio"},{label:"Show View Profile Button",model:"show_profile_button"},{label:"Enable RSS Feed",description:"Enable your RSS feed with the 10 most recent portfolio items",model:"rss_enabled"},{label:"Show RSS Feed Button",model:"show_rss_button",requiredWithTrue:"rss_enabled"}]}]},updateBackgroundColor:function(t){var e=this;this.skipWatch=!0,document.querySelector(":root").style.setProperty("--body-bg",t),"#000000"!==t&&"#ffffff"!==t&&(this.settings.color_scheme="custom"),this.$nextTick((function(){e.skipWatch=!1}))},updateTextColor:function(t){var e=this;this.skipWatch=!0,document.querySelector(":root").style.setProperty("--text-color",t),"#d4d4d8"!==t&&(this.settings.color_scheme="custom"),this.$nextTick((function(){e.skipWatch=!1}))},resetBackgroundColor:function(){var t=this;this.skipWatch=!0,this.$nextTick((function(){t.updateBackgroundColor("#000000"),t.settings.color_scheme="dark",t.settings.background_color="#000000",t.updateSettings(!0),setTimeout((function(){t.skipWatch=!1}),1e3)}))},resetTextColor:function(){var t=this;this.skipWatch=!0,this.$nextTick((function(){t.updateTextColor("#d4d4d8"),t.settings.color_scheme="dark",t.settings.text_color="#d4d4d8",t.updateSettings(!0),setTimeout((function(){t.skipWatch=!1}),1e3)}))},updateColorScheme:function(t){"light"===t&&this.updateBackgroundColor("#ffffff"),"dark"===t&&this.updateBackgroundColor("#000000")},getPreviewUrl:function(t){var e=t.media_attachments[0];return e?e.preview_url&&!e.preview_url.endsWith("/no-preview.png")?e.preview_url:e.url:"/storage/no-preview.png"}}}},49659:(t,e,r)=>{r.r(e),r.d(e,{render:()=>n,staticRenderFns:()=>o});var n=function(){var t=this,e=t._self._c;return e("div",[t.loading?e("div",{staticClass:"container"},[e("div",{staticClass:"d-flex justify-content-center align-items-center",staticStyle:{height:"100vh"}},[e("b-spinner")],1)]):e("div",[e("div",{staticClass:"container mb-5"},[e("div",{staticClass:"row mt-3"},[e("div",{staticClass:"col-12 mb-4"},[e("div",{staticClass:"d-flex justify-content-center"},[e("img",{staticClass:"img-fluid mb-4",staticStyle:{"max-height":"80vh","object-fit":"contain"},attrs:{src:t.post.media_attachments[0].url}})])]),t._v(" "),e("div",{staticClass:"col-12 mb-4"},[t.settings.show_captions&&t.post.content_text?e("p",[t._v(t._s(t.post.content_text))]):t._e(),t._v(" "),e("div",{staticClass:"d-md-flex justify-content-between align-items-center"},[e("p",{staticClass:"small"},[t._v("by "),e("a",{staticClass:"font-weight-bold link-color",attrs:{href:t.profileUrl()}},[t._v("@"+t._s(t.profile.username))])]),t._v(" "),t.settings.show_license&&t.post.media_attachments[0].license?e("p",{staticClass:"small"},[t._v("Licensed under "+t._s(t.post.media_attachments[0].license.title))]):t._e(),t._v(" "),t.settings.show_location&&t.post.place?e("p",{staticClass:"small text-muted"},[t._v(t._s(t.post.place.name)+", "+t._s(t.post.place.country))]):t._e(),t._v(" "),t.settings.show_timestamp?e("p",{staticClass:"small"},[t.settings.show_link?e("a",{staticClass:"font-weight-bold link-color",staticStyle:{"z-index":"2"},attrs:{href:t.post.url}},[t._v("\n "+t._s(t.formatDate(t.post.created_at))+"\n ")]):e("span",{staticClass:"user-select-none"},[t._v("\n "+t._s(t.formatDate(t.post.created_at))+"\n ")])]):t._e()])])])]),t._v(" "),e("div",{staticClass:"container"},[e("div",{staticClass:"row"},[e("div",{staticClass:"col-12"},[e("div",{staticClass:"d-flex fixed-bottom p-3 justify-content-between align-items-center"},[t.user?e("a",{staticClass:"logo-mark logo-mark-sm mb-0 p-1",attrs:{href:"/"}},[e("span",{staticClass:"text-gradient-primary"},[t._v("portfolio")])]):e("span",{staticClass:"logo-mark logo-mark-sm mb-0 p-1"},[e("span",{staticClass:"text-gradient-primary"},[t._v("portfolio")])]),t._v(" "),t.user&&t.user.id===t.profile.id?e("p",{staticClass:"text-center mb-0"},[e("a",{staticClass:"text-muted",attrs:{href:t.settingsUrl}},[e("i",{staticClass:"far fa-cog fa-lg"})])]):t._e()])])])])])])},o=[]},58279:(t,e,r)=>{r.r(e),r.d(e,{render:()=>n,staticRenderFns:()=>o});var n=function(){var t=this,e=t._self._c;return e("div",{staticClass:"w-100 h-100"},[t.loading?e("div",{staticClass:"container"},[e("div",{staticClass:"d-flex justify-content-center align-items-center",staticStyle:{height:"100vh"}},[e("b-spinner")],1)]):e("div",{staticClass:"container"},[e("div",{staticClass:"row py-5"},[e("div",{staticClass:"col-12"},[e("div",{staticClass:"d-flex align-items-center flex-column"},[t.settings.show_avatar?e("img",{staticClass:"rounded-circle shadow",attrs:{src:t.profile.avatar,width:"60",height:"60",onerror:"this.src='/storage/avatars/default.png?v=0';this.onerror=null;"}}):t._e(),t._v(" "),e("div",{staticClass:"py-3 text-center",staticStyle:{"max-width":"60%"}},[e("h1",{staticClass:"font-weight-bold"},[t._v(t._s(t.profile.username))]),t._v(" "),t.settings.show_bio?e("p",{staticClass:"font-weight-light mb-0 text-break"},[t._v(t._s(t.profile.note_text))]):t._e()]),t._v(" "),t.settings.show_profile_button||t.settings.rss_enabled&&t.settings.show_rss_button?e("div",{staticClass:"pb-3 text-center d-flex flex-column flex-sm-row",staticStyle:{"max-width":"60%",gap:"1rem"}},[t.settings.show_profile_button?e("a",{staticClass:"btn btn-outline-primary btn-custom-color",attrs:{href:t.profile.url,target:"_blank"}},[t._v("\n \t\tView Profile\n \t")]):t._e(),t._v(" "),t.settings.rss_enabled&&t.settings.show_rss_button?e("a",{staticClass:"btn btn-outline-primary btn-custom-color",attrs:{href:t.settings.rss_feed_url,target:"_blank"}},[e("i",{staticClass:"far fa-rss"}),t._v("   RSS\n \t")]):t._e()]):t._e()])])]),t._v(" "),e("div",{staticClass:"container mb-5 pb-5"},[e("div",{class:["masonry"===t.settings.profile_layout?"card-columns":"row"],attrs:{id:"portContainer"}},["grid"===t.settings.profile_layout?t._l(t.feed,(function(r,n){return e("div",{staticClass:"col-12 col-md-4 mb-1 p-1"},[e("div",{staticClass:"square"},[e("a",{attrs:{href:t.postUrl(r)}},[e("div",{staticClass:"lazy-img"},[e("blur-hash-canvas",{staticClass:"square-content pr-1",attrs:{width:"32",height:"32",hash:r.media_attachments[0].blurhash}}),t._v(" "),e("img",{staticClass:"square-content pr-1 img-placeholder",staticStyle:{overflow:"hidden","object-fit":"cover","z-index":"-1"},attrs:{src:"","data-src":r.media_attachments[0].url,width:"100%",height:"300",loading:"lazy"}})],1)])])])})):"album"===t.settings.profile_layout?e("div",{staticClass:"col-12 mb-1 p-1"},[e("div",{staticClass:"d-flex justify-content-center"},[e("p",{staticClass:"text-color font-weight-bold"},[t._v(t._s(t.albumIndex+1)+" "),e("span",{staticClass:"font-weight-light"},[t._v("/")]),t._v(" "+t._s(t.feed.length))])]),t._v(" "),e("div",{staticClass:"d-flex justify-content-between align-items-center"},[0===t.albumIndex?e("span",[e("i",{staticClass:"fa fa-arrow-circle-left fa-3x text-color-lighter"})]):e("a",{attrs:{href:"#"},on:{click:function(e){return e.preventDefault(),t.albumPrev()}}},[e("i",{staticClass:"fa fa-arrow-circle-left fa-3x text-color"})]),t._v(" "),e("transition",{attrs:{name:"slide-fade"}},[e("a",{key:t.albumIndex,staticClass:"mx-4",attrs:{href:t.postUrl(t.feed[t.albumIndex])}},[e("img",{staticClass:"user-select-none",staticStyle:{height:"60vh",overflow:"hidden","object-fit":"contain"},attrs:{src:t.feed[t.albumIndex].media_attachments[0].url,width:"100%",draggable:!1}})])]),t._v(" "),t.albumIndex===t.feed.length-1?e("span",[e("i",{staticClass:"fa fa-arrow-circle-right fa-3x text-color-lighter"})]):e("a",{attrs:{href:"#"},on:{click:function(e){return e.preventDefault(),t.albumNext()}}},[e("i",{staticClass:"fa fa-arrow-circle-right fa-3x text-color"})])],1)]):"masonry"===t.settings.profile_layout?e("div",{staticClass:"col-12 p-0 m-0"},t._l(t.feed,(function(r,n){return e("div",{staticClass:"p-1"},[e("a",{attrs:{href:t.postUrl(r),"data-fancybox":"recent","data-src":r.media_attachments[0].url,"data-width":r.media_attachments[0].width,"data-height":r.media_attachments[0].height}},[e("img",{staticClass:"user-select-none",staticStyle:{overflow:"hidden","object-fit":"contain"},attrs:{src:r.media_attachments[0].url,width:"100%",draggable:!1}})])])})),0):t._e()],2)]),t._v(" "),e("div",{staticClass:"d-flex fixed-bottom p-3 justify-content-between align-items-center"},[t.user?e("a",{staticClass:"logo-mark logo-mark-sm mb-0 p-1",attrs:{href:"/"}},[e("span",{staticClass:"text-gradient-primary"},[t._v("portfolio")])]):e("span",{staticClass:"logo-mark logo-mark-sm mb-0 p-1"},[e("span",{staticClass:"text-gradient-primary"},[t._v("portfolio")])]),t._v(" "),t.user&&t.user.id==t.profile.id?e("p",{staticClass:"text-center mb-0"},[e("a",{staticClass:"link-color",attrs:{href:t.settingsUrl}},[e("i",{staticClass:"far fa-cog fa-lg"})])]):t._e()])])])},o=[]},2256:(t,e,r)=>{r.r(e),r.d(e,{render:()=>n,staticRenderFns:()=>o});var n=function(){var t=this,e=t._self._c;return e("div",{staticClass:"portfolio-settings px-3"},[t.loading?e("div",{staticClass:"d-flex justify-content-center align-items-center py-5"},[e("b-spinner",{attrs:{variant:"primary"}})],1):e("div",{staticClass:"row justify-content-center mb-5 pb-5"},[e("div",{staticClass:"col-12 col-md-8 bg-dark py-2 rounded"},[e("ul",{staticClass:"nav nav-pills nav-fill"},t._l(t.tabs,(function(r,n){return e("li",{staticClass:"nav-item",class:{disabled:0!==n&&!t.settings.active}},[0===n||t.settings.active?e("a",{staticClass:"nav-link",class:{active:r===t.tabIndex},attrs:{href:"#"},on:{click:function(e){return e.preventDefault(),t.toggleTab(r)}}},[t._v(t._s(r))]):e("span",{staticClass:"nav-link"},[t._v(t._s(r))])])})),0)]),t._v(" "),e("transition",{attrs:{name:"slide-fade"}},["Configure"===t.tabIndex?e("div",{key:"0",staticClass:"col-12 col-md-8 bg-dark mt-3 py-2 rounded"},[t.user.statuses_count?t._e():e("div",{staticClass:"alert alert-danger"},[e("p",{staticClass:"mb-0 small font-weight-bold"},[t._v("You don't have any public posts, once you share public posts you can enable your portfolio.")])]),t._v(" "),e("div",{staticClass:"d-flex justify-content-between align-items-center py-2"},[e("div",{staticClass:"setting-label"},[e("p",{staticClass:"lead mb-0"},[t._v("Portfolio Enabled")]),t._v(" "),e("p",{staticClass:"small mb-0 text-muted"},[t._v("You must enable your portfolio before you or anyone can view it.")])]),t._v(" "),e("div",{staticClass:"setting-switch mt-n1"},[e("b-form-checkbox",{attrs:{name:"check-button",size:"lg",switch:"",disabled:!t.user.statuses_count},model:{value:t.settings.active,callback:function(e){t.$set(t.settings,"active",e)},expression:"settings.active"}})],1)]),t._v(" "),e("hr"),t._v(" "),e("div",{staticClass:"d-flex justify-content-between align-items-center py-2"},[e("div",{staticClass:"setting-label",staticStyle:{"max-width":"50%"}},[e("p",{staticClass:"mb-0"},[t._v("Portfolio Source")]),t._v(" "),e("p",{staticClass:"small mb-0 text-muted"},[t._v("Choose how you want to populate your portfolio, select Most Recent posts to automatically update your portfolio with recent posts or Curated Posts to select specific posts for your portfolio.")])]),t._v(" "),e("div",{staticClass:"ml-3"},[e("b-form-select",{attrs:{options:t.profileSourceOptions,disabled:!t.user.statuses_count},model:{value:t.settings.profile_source,callback:function(e){t.$set(t.settings,"profile_source",e)},expression:"settings.profile_source"}})],1)])]):"Curate"===t.tabIndex?e("div",{key:"1",staticClass:"col-12 col-md-8 mt-3 py-2 px-0"},[t.recentPostsLoaded?[e("div",{staticClass:"mt-n2 mb-4"},[e("p",{staticClass:"text-muted small"},[t._v("Select up to 100 photos from your 100 most recent posts. You can only select public photo posts, videos are not supported at this time.")]),t._v(" "),e("div",{staticClass:"d-flex align-items-center justify-content-between"},[e("p",{staticClass:"font-weight-bold mb-0"},[t._v("Selected "+t._s(t.selectedRecentPosts.length)+"/100")]),t._v(" "),e("div",[e("button",{staticClass:"btn btn-link font-weight-bold mr-3 text-decoration-none",attrs:{disabled:!t.selectedRecentPosts.length},on:{click:t.clearSelected}},[t._v("\n Clear selected\n ")]),t._v(" "),e("button",{staticClass:"btn btn-primary py-0 font-weight-bold",staticStyle:{width:"150px"},attrs:{disabled:!t.canSaveCurated},on:{click:function(e){return t.saveCurated()}}},[t.isSavingCurated?e("b-spinner",{attrs:{small:""}}):[t._v("Save")]],2)])])]),t._v(" "),e("div",{staticClass:"d-flex justify-content-between align-items-center"},[e("span",{on:{click:t.recentPostsPrev}},[e("i",{class:t.prevClass})]),t._v(" "),e("div",{staticClass:"row flex-grow-1 mx-2"},t._l(t.recentPosts.slice(t.rpStart,t.rpStart+9),(function(r,n){return e("div",{staticClass:"col-12 col-md-4 mb-1 p-1"},[e("div",{staticClass:"square user-select-none",on:{click:function(e){return e.preventDefault(),t.toggleRecentPost(r.id)}}},[e("transition",{attrs:{name:"fade"}},[e("img",{key:r.id,staticClass:"square-content pr-1",staticStyle:{overflow:"hidden","object-fit":"cover"},attrs:{src:t.getPreviewUrl(r),width:"100%",height:"300",draggable:!1,loading:"lazy",onerror:"this.src='/storage/no-preview.png';this.onerror=null;"}})]),t._v(" "),-1!==t.selectedRecentPosts.indexOf(r.id)?e("div",{staticStyle:{position:"absolute",right:"-5px",bottom:"-5px"}},[e("div",{staticClass:"selected-badge"},[t._v(t._s(t.selectedRecentPosts.indexOf(r.id)+1))])]):t._e()],1)])})),0),t._v(" "),e("span",{on:{click:function(e){return t.recentPostsNext()}}},[e("i",{class:t.nextClass})])])]:e("div",{staticClass:"d-flex align-items-center justify-content-center py-5 my-5"},[e("div",{staticClass:"text-center"},[e("div",{staticClass:"spinner-border",attrs:{role:"status"}},[e("span",{staticClass:"sr-only"},[t._v("Loading...")])]),t._v(" "),e("p",{staticClass:"text-muted"},[t._v("Loading recent posts...")])])])],2):"Customize"===t.tabIndex?e("div",{key:"2",staticClass:"col-12 mt-3 py-2"},[e("div",{staticClass:"row"},[e("div",{staticClass:"col-12 col-md-6"},t._l(t.customizeSettings,(function(r){return e("div",{staticClass:"card bg-dark mb-5"},[e("div",{staticClass:"card-header"},[t._v(t._s(r.title))]),t._v(" "),e("div",{staticClass:"list-group bg-dark"},t._l(r.items,(function(r){return e("div",{staticClass:"list-group-item"},[e("div",{staticClass:"d-flex justify-content-between align-items-center py-2"},[e("div",{staticClass:"setting-label"},[e("p",{staticClass:"mb-0"},[t._v(t._s(r.label))]),t._v(" "),r.description?e("p",{staticClass:"small text-muted mb-0"},[t._v(t._s(r.description))]):t._e()]),t._v(" "),e("div",{staticClass:"setting-switch mt-n1"},[e("b-form-checkbox",{attrs:{name:"check-button",size:"lg",switch:"",disabled:r.requiredWithTrue&&!t.settings[r.requiredWithTrue]},model:{value:t.settings[r.model],callback:function(e){t.$set(t.settings,r.model,e)},expression:"settings[item.model]"}})],1)])])})),0)])})),0),t._v(" "),e("div",{staticClass:"col-12 col-md-6"},[e("div",{staticClass:"card bg-dark mb-5"},[e("div",{staticClass:"card-header"},[t._v("Portfolio")]),t._v(" "),e("div",{staticClass:"list-group bg-dark"},[e("div",{staticClass:"list-group-item"},[e("div",{staticClass:"d-flex justify-content-between align-items-center py-2"},[e("div",{staticClass:"setting-label"},[e("p",{staticClass:"mb-0"},[t._v("Layout")])]),t._v(" "),e("div",[e("b-form-select",{attrs:{options:t.profileLayoutOptions},model:{value:t.settings.profile_layout,callback:function(e){t.$set(t.settings,"profile_layout",e)},expression:"settings.profile_layout"}})],1)])]),t._v(" "),"custom"===t.settings.profile_source?e("div",{staticClass:"list-group-item"},[e("div",{staticClass:"d-flex justify-content-between align-items-center py-2"},[e("div",{staticClass:"setting-label"},[e("p",{staticClass:"mb-0"},[t._v("Order")])]),t._v(" "),e("div",[e("b-form-select",{attrs:{options:t.profileLayoutFeedOrder},model:{value:t.settings.feed_order,callback:function(e){t.$set(t.settings,"feed_order",e)},expression:"settings.feed_order"}})],1)])]):t._e(),t._v(" "),e("div",{staticClass:"list-group-item"},[e("div",{staticClass:"d-flex justify-content-between align-items-center py-2"},[e("div",{staticClass:"setting-label"},[e("p",{staticClass:"mb-0"},[t._v("Color Scheme")])]),t._v(" "),e("div",[e("b-form-select",{attrs:{options:t.profileLayoutColorSchemeOptions,disabled:"custom"===t.settings.color_scheme},on:{change:t.updateColorScheme},model:{value:t.settings.color_scheme,callback:function(e){t.$set(t.settings,"color_scheme",e)},expression:"settings.color_scheme"}})],1)])]),t._v(" "),e("div",{staticClass:"list-group-item"},[e("div",{staticClass:"d-flex justify-content-between align-items-center py-2"},[e("div",{staticClass:"setting-label"},[e("p",{staticClass:"mb-0"},[t._v("Background Color")])]),t._v(" "),e("b-col",{attrs:{sm:"2"}},[e("b-form-input",{attrs:{debounce:"1000",type:"color"},on:{change:t.updateBackgroundColor},model:{value:t.settings.background_color,callback:function(e){t.$set(t.settings,"background_color",e)},expression:"settings.background_color"}}),t._v(" "),["#000000",null].includes(t.settings.background_color)?t._e():e("b-button",{attrs:{variant:"link"},on:{click:t.resetBackgroundColor}},[t._v("\n\t\t \t\t\tReset\n\t\t \t\t")])],1)],1)]),t._v(" "),e("div",{staticClass:"list-group-item"},[e("div",{staticClass:"d-flex justify-content-between align-items-center py-2"},[e("div",{staticClass:"setting-label"},[e("p",{staticClass:"mb-0"},[t._v("Text Color")])]),t._v(" "),e("b-col",{attrs:{sm:"2"}},[e("b-form-input",{attrs:{debounce:"1000",type:"color"},on:{change:t.updateTextColor},model:{value:t.settings.text_color,callback:function(e){t.$set(t.settings,"text_color",e)},expression:"settings.text_color"}}),t._v(" "),["#d4d4d8",null].includes(t.settings.text_color)?t._e():e("b-button",{attrs:{variant:"link"},on:{click:t.resetTextColor}},[t._v("\n\t\t \t\t\tReset\n\t\t \t\t")])],1)],1)])])])])])]):"Share"===t.tabIndex?e("div",{key:"0",staticClass:"col-12 col-md-8 bg-dark mt-3 py-2 rounded"},[e("div",{staticClass:"py-2"},[e("p",{staticClass:"text-muted"},[t._v("Portfolio URL")]),t._v(" "),e("p",{staticClass:"lead mb-0"},[e("a",{attrs:{href:t.settings.url}},[t._v(t._s(t.settings.url))])])])]):t._e()])],1)])},o=[]},9209:(t,e,r)=>{r.r(e);var n=r(70538),o=r(25518),s=r(74870),i=r.n(s);r(86368);window.Vue=n.default,n.default.use(o.default),n.default.use(i()),n.default.component("portfolio-post",r(15414).default),n.default.component("portfolio-profile",r(93324).default),n.default.component("portfolio-settings",r(8662).default)},15414:(t,e,r)=>{r.r(e),r.d(e,{default:()=>i});var n=r(11731),o=r(82945),s={};for(const t in o)"default"!==t&&(s[t]=()=>o[t]);r.d(e,s);const i=(0,r(51900).default)(o.default,n.render,n.staticRenderFns,!1,null,null,null).exports},93324:(t,e,r)=>{r.r(e),r.d(e,{default:()=>i});var n=r(43296),o=r(53100),s={};for(const t in o)"default"!==t&&(s[t]=()=>o[t]);r.d(e,s);const i=(0,r(51900).default)(o.default,n.render,n.staticRenderFns,!1,null,null,null).exports},8662:(t,e,r)=>{r.r(e),r.d(e,{default:()=>i});var n=r(62600),o=r(97953),s={};for(const t in o)"default"!==t&&(s[t]=()=>o[t]);r.d(e,s);const i=(0,r(51900).default)(o.default,n.render,n.staticRenderFns,!1,null,null,null).exports},82945:(t,e,r)=>{r.r(e),r.d(e,{default:()=>s});var n=r(2508),o={};for(const t in n)"default"!==t&&(o[t]=()=>n[t]);r.d(e,o);const s=n.default},53100:(t,e,r)=>{r.r(e),r.d(e,{default:()=>s});var n=r(46418),o={};for(const t in n)"default"!==t&&(o[t]=()=>n[t]);r.d(e,o);const s=n.default},97953:(t,e,r)=>{r.r(e),r.d(e,{default:()=>s});var n=r(11109),o={};for(const t in n)"default"!==t&&(o[t]=()=>n[t]);r.d(e,o);const s=n.default},11731:(t,e,r)=>{r.r(e);var n=r(49659),o={};for(const t in n)"default"!==t&&(o[t]=()=>n[t]);r.d(e,o)},43296:(t,e,r)=>{r.r(e);var n=r(58279),o={};for(const t in n)"default"!==t&&(o[t]=()=>n[t]);r.d(e,o)},62600:(t,e,r)=>{r.r(e);var n=r(2256),o={};for(const t in n)"default"!==t&&(o[t]=()=>n[t]);r.d(e,o)}},t=>{t.O(0,[8898],(()=>{return e=9209,t(t.s=e);var e}));t.O()}]);