<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">(window.webpackJsonp=window.webpackJsonp||[]).push([[603],{1250:function(e,t){document.addEventListener("DOMContentLoaded",(function(){var e=0,t=function(){return(new Date).getTime()+e++},n=function(e){return"["+e+"]$1"},a=function(e){return"_"+e+"_$1"},o=function(e,o){e.preventDefault(),e.stopPropagation();var r=o,i=r.getAttribute("data-association"),s=r.getAttribute("data-associations"),c=r.getAttribute("data-association-insertion-template"),l=r.getAttribute("data-association-insertion-method")||r.getAttribute("data-association-insertion-position")||"before",d=r.getAttribute("data-association-insertion-node"),u=r.getAttribute("data-association-insertion-traversal"),m=parseInt(r.getAttribute("data-count"),10),f=new RegExp("\\[new_"+i+"\\](.*?\\s)","g"),p=new RegExp("_new_"+i+"_(\\w*)","g"),g=t(),v=c.replace(f,n(g)),h=[],b=e;for(v===c&amp;&amp;(f=new RegExp("\\[new_"+s+"\\](.*?\\s)","g"),p=new RegExp("_new_"+s+"_(\\w*)","g"),v=c.replace(f,n(g))),h=[v=v.replace(p,a(g))],m=isNaN(m)?1:Math.max(m,1),m-=1;m;)g=t(),v=(v=c.replace(f,n(g))).replace(p,a(g)),h.push(v),m-=1;var _=function(e,t,n){return e?"function"==typeof e?(t&amp;&amp;console.warn("association-insertion-traversal is ignored, because association-insertion-node is given as a function."),e(n)):"string"==typeof e?t?n[t](e):"this"===e?n:document.querySelector(e):void 0:n.parentNode}(d,u,r);_&amp;&amp;0!==_.length||console.warn("Couldn't find the element to insert the template. Make sure your `data-association-insertion-*` on `link_to_add_association` is correct."),h.forEach((function(e,t){var n=e,a=new CustomEvent("cocoon:before-insert",{bubbles:!0,cancelable:!0,detail:[n,b]});if(_.dispatchEvent(a),!a.defaultPrevented){var o={before:"beforebegin",prepend:"afterbegin",append:"beforeend",after:"afterend"},r=o[l],i=_.insertAdjacentHTML(r,n);r===o.before?i=_.previousElementSibling:r===o.prepend?i=_.firstElementChild:r===o.append?i=_.lastElementChild:r===o.after&amp;&amp;(i=_.nextElementSibling);var s=new CustomEvent("cocoon:after-insert",{bubbles:!0,detail:[n,b,i]});_.dispatchEvent(s)}}))},r=function(e,t){var n=t,a=n.getAttribute("data-wrapper-class")||"nested-fields",o=n.closest("."+a),r=o.parentNode,i=e;e.preventDefault(),e.stopPropagation();var s=new CustomEvent("cocoon:before-remove",{bubbles:!0,cancelable:!0,detail:[o,i]});if(r.dispatchEvent(s),!s.defaultPrevented){var c=r.getAttribute("data-remove-timeout")||0;setTimeout((function(){if(n.classList.contains("dynamic"))(a=o).parentElement.removeChild(a);else{(function(e,t){var n=e.previousElementSibling;if(!t)return n;for(;n;){if(n.matches(t))return n;n=n.previousElementSibling}}(n,"input[type=hidden]")).value="1",o.style.display="none";for(var e=o.querySelectorAll("input[required]"),t=0;t&lt;e.length;t++)e[t].removeAttribute("required")}var a,s=new CustomEvent("cocoon:after-remove",{bubbles:!0,detail:[o,i]});r.dispatchEvent(s)}),c)}};document.addEventListener("click",(function(e){for(var t=e.target;t&amp;&amp;t!==this;t=t.parentNode){if(t.matches(".add_fields"))return void o(e,t);if(t.matches(".remove_fields"))return void r(e,t)}}),!1);var i=function(){for(var e=document.querySelectorAll(".remove_fields.existing.destroyed"),t=0;t&lt;e.length;t++){var n=e[t],a=n.getAttribute("data-wrapper-class")||"nested-fields";n.closest("."+a).style.display="none"}};document.addEventListener("page:load",i),document.addEventListener("turbolinks:load",i),document.addEventListener("turbo:load",i),i()}))},1377:function(e,t,n){"use strict";n.r(t);var a=n(0),o=n(82),r=n.n(o),i=(n(36),n(183),n(128)),s=(n(149),n(1380)),c=n(7),l=n(49),d=n(136),u=n(158),m=n(65),f=n(60);var p=n(102),g=n(161),v=n(57);n(1250);Object(u.a)();const h=Object(c.d)({usernameTaken:{id:"username.taken",defaultMessage:"That username is taken. Try another"},passwordExceedsLength:{id:"password_confirmation.exceeds_maxlength",defaultMessage:"Password confirmation exceeds the maximum password length"},passwordDoesNotMatch:{id:"password_confirmation.mismatching",defaultMessage:"Password confirmation does not match"}});function b(){var e;const{messages:t}=Object(p.b)(),o=document.documentElement.lang,c=new Intl.DateTimeFormat(o,{year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric"}),u=new Intl.DateTimeFormat(o,{year:"numeric",month:"short",day:"numeric"}),g=new Intl.DateTimeFormat(o,{timeStyle:"short"}),v=(e,n)=&gt;{let a,{id:r,defaultMessage:i}=e;r&amp;&amp;(a=t[r]),a||(a=i);return new s.a(a,o).format(n)};document.querySelectorAll(".emojify").forEach((e=&gt;{e.innerHTML=Object(f.c)(e.innerHTML)})),document.querySelectorAll("time.formatted").forEach((e=&gt;{const t=new Date(e.dateTime),n=c.format(t);e.title=n,e.textContent=n}));const b=new s.a(null!==(e=t["relative_format.today"])&amp;&amp;void 0!==e?e:"Today at {time}",o);document.querySelectorAll("time.relative-formatted").forEach((e=&gt;{const t=new Date(e.dateTime);let n;if((e=&gt;{const t=new Date;return e.getDate()===t.getDate()&amp;&amp;e.getMonth()===t.getMonth()&amp;&amp;e.getFullYear()===t.getFullYear()})(t)){const e=g.format(t);n=b.format({time:e})}else n=u.format(t);e.title=n,e.textContent=n})),document.querySelectorAll("time.time-ago").forEach((e=&gt;{const t=new Date(e.dateTime),n=new Date,a=e.dateTime.includes("T");e.title=a?c.format(t):u.format(t),e.textContent=Object(m.b)({formatMessage:v,formatDate:(e,t)=&gt;new Intl.DateTimeFormat(o,t).format(e)},t,n.getTime(),n.getFullYear(),a)}));const _=document.querySelectorAll("[data-component]");_.length&gt;0&amp;&amp;n.e(440).then(n.bind(null,1636)).then((e=&gt;{let{default:t}=e;_.forEach((e=&gt;{Array.from(e.children).forEach((t=&gt;{e.removeChild(t)}))}));const n=document.createElement("div");return Object(i.createRoot)(n).render(Object(a.a)(t,{locale:o,components:_})),document.body.appendChild(n),!0})).catch((e=&gt;{console.error(e)})),l.a.delegate(document,"input#user_account_attributes_username","input",r()((e=&gt;{let{target:t}=e;t instanceof HTMLInputElement&amp;&amp;(t.value&amp;&amp;t.value.length&gt;0?d.a.get("/api/v1/accounts/lookup",{params:{acct:t.value}}).then((()=&gt;(t.setCustomValidity(v(h.usernameTaken)),!0))).catch((()=&gt;{t.setCustomValidity("")})):t.setCustomValidity(""))}),500,{leading:!1,trailing:!0})),l.a.delegate(document,"#user_password,#user_password_confirmation","input",(()=&gt;{const e=document.querySelector("input#user_password"),t=document.querySelector("input#user_password_confirmation");t&amp;&amp;e&amp;&amp;(t.value&amp;&amp;t.value.length&gt;e.maxLength?t.setCustomValidity(v(h.passwordExceedsLength)):e.value&amp;&amp;e.value!==t.value?t.setCustomValidity(v(h.passwordDoesNotMatch)):t.setCustomValidity(""))})),l.a.delegate(document,"button.status__content__spoiler-link","click",(function(){var e;if(!(this instanceof HTMLButtonElement))return;const n=null===(e=this.parentNode)||void 0===e?void 0:e.parentNode;var a,r;n instanceof HTMLDivElement&amp;&amp;n.classList.contains(".status__content")&amp;&amp;("expanded"===n.dataset.spoiler?(n.dataset.spoiler="folded",this.textContent=new s.a(null!==(a=t["status.show_more"])&amp;&amp;void 0!==a?a:"Show more",o).format()):(n.dataset.spoiler="expanded",this.textContent=new s.a(null!==(r=t["status.show_less"])&amp;&amp;void 0!==r?r:"Show less",o).format()))})),document.querySelectorAll("button.status__content__spoiler-link").forEach((e=&gt;{var n,a,r;const i=null===(n=e.parentNode)||void 0===n?void 0:n.parentNode;if(!(i instanceof HTMLDivElement&amp;&amp;i.classList.contains(".status__content")))return;const c="expanded"===i.dataset.spoiler?null!==(a=t["status.show_less"])&amp;&amp;void 0!==a?a:"Show less":null!==(r=t["status.show_more"])&amp;&amp;void 0!==r?r:"Show more";e.textContent=new s.a(c,o).format()}))}l.a.delegate(document,"#edit_profile input[type=file]","change",(e=&gt;{let{target:t}=e;if(!(t instanceof HTMLInputElement))return;const n=document.querySelector(`img#${t.id}-preview`);if(!n)return;let a;t.files&amp;&amp;(a=t.files[0]);const o=a?URL.createObjectURL(a):n.dataset.originalSrc;o&amp;&amp;(n.src=o)})),l.a.delegate(document,".input-copy input","click",(e=&gt;{let{target:t}=e;t instanceof HTMLInputElement&amp;&amp;(t.focus(),t.select(),t.setSelectionRange(0,t.value.length))})),l.a.delegate(document,".input-copy button","click",(e=&gt;{var t;let{target:n}=e;if(!(n instanceof HTMLButtonElement))return;const a=null===(t=n.parentNode)||void 0===t?void 0:t.querySelector(".input-copy__wrapper input");if(!a)return;const o=a.readOnly;a.readOnly=!1,a.focus(),a.select(),a.setSelectionRange(0,a.value.length);try{if(document.execCommand("copy")){a.blur();const e=n.parentElement;if(!e)return;e.classList.add("copied"),setTimeout((()=&gt;{e.classList.remove("copied")}),700)}}catch(e){console.error(e)}a.readOnly=o}));const _=()=&gt;{const e=document.querySelector(".sidebar ul"),t=document.querySelector("a.sidebar__toggle__icon");e&amp;&amp;t&amp;&amp;(e.classList.contains("visible")?(document.body.style.overflow="",t.setAttribute("aria-expanded","false")):(document.body.style.overflow="hidden",t.setAttribute("aria-expanded","true")),t.classList.toggle("active"),e.classList.toggle("visible"))};l.a.delegate(document,".sidebar__toggle__icon","click",(()=&gt;{_()})),l.a.delegate(document,".sidebar__toggle__icon","keydown",(e=&gt;{" "!==e.key&amp;&amp;"Enter"!==e.key||(e.preventDefault(),_())})),l.a.delegate(document,"img.custom-emoji","mouseover",(e=&gt;{let{target:t}=e;t instanceof HTMLImageElement&amp;&amp;t.dataset.original&amp;&amp;(t.src=t.dataset.original)})),l.a.delegate(document,"img.custom-emoji","mouseout",(e=&gt;{let{target:t}=e;t instanceof HTMLImageElement&amp;&amp;t.dataset.static&amp;&amp;(t.src=t.dataset.static)}));l.a.delegate(document,"#account_statuses_cleanup_policy_enabled","change",(e=&gt;{let{target:t}=e;t instanceof HTMLInputElement&amp;&amp;t.form&amp;&amp;t.form.querySelectorAll("input:not([type=hidden], #account_statuses_cleanup_policy_enabled), select").forEach((e=&gt;{((e,t)=&gt;{e.disabled=t;const n=e.closest(".with_label");if(n){n.classList.toggle("disabled",e.disabled);const t="checkbox"===e.type&amp;&amp;n.querySelector('input[type=hidden][value="0"]');t&amp;&amp;(t.disabled=e.disabled)}})(e,!t.checked)}))})),l.a.delegate(document,"#registration_new_user,#new_user","submit",(()=&gt;{["user_website","user_confirm_password","registration_user_website","registration_user_confirm_password"].forEach((e=&gt;{const t=document.querySelector(`input#${e}`);t&amp;&amp;(t.value="")}))})),Object(g.a)().then(p.c).then((function(){Object(v.a)(b).catch((e=&gt;{console.error(e)}))})).then((function(){return/KAIOS/.test(navigator.userAgent)?n.e(439).then(n.bind(null,1637)).then((e=&gt;{e.register()})):Promise.resolve()})).catch((e=&gt;{console.error(e)}))}},[[1377,0]]]);
//# sourceMappingURL=public-a329cb3c31bd3bc90a5f.chunk.js.map</pre></body></html>