PageSourceSearch

https://stiften.dk/assets/1790063100/kodus/debate/js/debate.js

js stiften.dk collected 2026-09-24 17:21:21 UTC 43,522 bytes, 1 lines download raw bytes

vendor: 5,644 bytes, line 1
1!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define("debate",[],e):"object"==typeof exports?exports.debate=e():t.debate=e()}(self,(()=>(()=>{"use strict";var t={d:(e,n)=>{for(var i in n)t.o(n,i)&&!t.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:n[i]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r:t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};t.r(e),t.d(e,{initDebate:()=>Ue});var n,i,r,o,l,u={},a=[],s=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i;function _(t,e){for(var n in e)t[n]=e[n];return t}function c(t){var e=t.parentNode;e&&e.removeChild(t)}function d(t,e,i){var r,o,l,u={};for(l in e)"key"==l?r=e[l]:"ref"==l?o=e[l]:u[l]=e[l];if(arguments.length>2&&(u.children=arguments.length>3?n.call(arguments,2):i),"function"==typeof t&&null!=t.defaultProps)for(l in t.defaultProps)void 0===u[l]&&(u[l]=t.defaultProps[l]);return f(t,u,r,o,null)}function f(t,e,n,o,l){var u={type:t,props:e,key:n,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:null==l?++r:l};return null==l&&null!=i.vnode&&i.vnode(u),u}function h(t){return t.children}function v(t,e){this.props=t,this.context=e}function p(t,e){if(null==e)return t.__?p(t.__,t.__.__k.indexOf(t)+1):null;for(var n;e<t.__k.length;e++)if(null!=(n=t.__k[e])&&null!=n.__e)return n.__e;return"function"==typeof t.type?p(t):null}function m(t){var e,n;if(null!=(t=t.__)&&null!=t.__c){for(t.__e=t.__c.base=null,e=0;e<t.__k.length;e++)if(null!=(n=t.__k[e])&&null!=n.__e){t.__e=t.__c.base=n.__e;break}return m(t)}}function b(t){(!t.__d&&(t.__d=!0)&&o.push(t)&&!g.__r++||l!==i.debounceRendering)&&((l=i.debounceRendering)||setTimeout)(g)}function g(){for(var t;g.__r=o.length;)t=o.sort((function(t,e){return t.__v.__b-e.__v.__b})),o=[],t.some((function(t){var e,n,i,r,o,l;t.__d&&(o=(r=(e=t).__v).__e,(l=e.__P)&&(n=[],(i=_({},r)).__v=r.__v+1,x(l,r,i,e.__n,void 0!==l.ownerSVGElement,null!=r.__h?[o]:null,n,null==o?p(r):o,r.__h),U(n,r),r.__e!=o&&m(r)))}))}function C(t,e,n,i,r,o,l,s,_,c){var d,v,m,b,g,C,k,N=i&&i.__k||a,L=N.length;for(n.__k=[],d=0;d<e.length;d++)if(null!=(b=n.__k[d]=null==(b=e[d])||"boolean"==typeof b?null:"string"==typeof b||"number"==typeof b||"bigint"==typeof b?f(null,b,null,null,b):Array.isArray(b)?f(h,{children:b},null,null,null):b.__b>0?f(b.type,b.props,b.key,b.ref?b.ref:null,b.__v):b)){if(b.__=n,b.__b=n.__b+1,null===(m=N[d])||m&&b.key==m.key&&b.type===m.type)N[d]=void 0;else for(v=0;v<L;v++){if((m=N[v])&&b.key==m.key&&b.type===m.type){N[v]=void 0;break}m=null}x(t,b,m=m||u,r,o,l,s,_,c),g=b.__e,(v=b.ref)&&m.ref!=v&&(k||(k=[]),m.ref&&k.push(m.ref,null,b),k.push(v,b.__c||g,b)),null!=g?(null==C&&(C=g),"function"==typeof b.type&&b.__k===m.__k?b.__d=_=y(b,_,t):_=w(t,b,m,N,g,_),"function"==typeof n.type&&(n.__d=_)):_&&m.__e==_&&_.parentNode!=t&&(_=p(m))}for(n.__e=C,d=L;d--;)null!=N[d]&&H(N[d],N[d]);if(k)for(d=0;d<k.length;d++)T(k[d],k[++d],k[++d])}function y(t,e,n){for(var i,r=t.__k,o=0;r&&o<r.length;o++)(i=r[o])&&(i.__=t,e="function"==typeof i.type?y(i,e,n):w(n,i,i,r,i.__e,e));return e}function w(t,e,n,i,r,o){var l,u,a;if(void 0!==e.__d)l=e.__d,e.__d=void 0;else if(null==n||r!=o||null==r.parentNode)t:if(null==o||o.parentNode!==t)t.appendChild(r),l=null;else{for(u=o,a=0;(u=u.nextSibling)&&a<i.length;a+=1)if(u==r)break t;t.insertBefore(r,o),l=o}return void 0!==l?l:r.nextSibling}function k(t,e,n){"-"===e[0]?t.setProperty(e,n):t[e]=null==n?"":"number"!=typeof n||s.test(e)?n:n+"px"}function N(t,e,n,i,r){var o;t:if("style"===e)if("string"==typeof n)t.style.cssText=n;else{if("string"==typeof i&&(t.style.cssText=i=""),i)for(e in i)n&&e in n||k(t.style,e,"");if(n)for(e in n)i&&n[e]===i[e]||k(t.style,e,n[e])}else if("o"===e[0]&&"n"===e[1])o=e!==(e=e.replace(/Capture$/,"")),e=e.toLowerCase()in t?e.toLowerCase().slice(2):e.slice(2),t.l||(t.l={}),t.l[e+o]=n,n?i||t.addEventListener(e,o?S:L,o):t.removeEventListener(e,o?S:L,o);else if("dangerouslySetInnerHTML"!==e){if(r)e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("href"!==e&&"list"!==e&&"form"!==e&&"tabIndex"!==e&&"download"!==e&&e in t)try{t[e]=null==n?"":n;break t}catch(t){}"function"==typeof n||(null==n||!1===n&&-1==e.indexOf("-")?t.removeAttribute(e):t.setAttribute(e,n))}}function L(t){this.l[t.type+!1](i.event?i.event(t):t)}function S(t){this.l[t.type+!0](i.event?i.event(t):t)}function x(t,e,r,o,l,a,s,d,f){var m,b,g,y,w,k,L,S,x,U,T,H,E,V,j,$=e.type;if(void 0!==e.constructor)return null;null!=r.__h&&(f=r.__h,d=e.__e=r.__e,e.__h=null,a=[d]),(m=i.__b)&&m(e);try{t:if("function"==typeof $){if(S=e.props,x=(m=$.contextType)&&o[m.__c],U=m?x?x.props.value:m.__:o,r.__c?L=(b=e.__c=r.__c).__=b.__E:("prototype"in $&&$.prototype.render?e.__c=b=new $(S,U):(e.__c=b=new v(S,U),b.constructor=$,b.render=M),x&&x.sub(b),b.props=S,b.state||(b.state={}),b.context=U,b.__n=o,g=b.__d=!0,b.__h=[],b._sb=[]),null==b.__s&&(b.__s=b.state),null!=$.getDerivedStateFromProps&&(b.__s==b.state&&(b.__s=_({},b.__s)),_(b.__s,$.getDerivedStateFromProps(S,b.__s))),y=b.props,w=b.state,g)null==$.getDerivedStateFromProps&&null!=b.componentWillMount&&b.componentWillMount(),null!=b.componentDidMount&&b.__h.push(b.componentDidMount);else{if(null==$.getDerivedStateFromProps&&S!==y&&null!=b.componentWillReceiveProps&&b.componentWillReceiveProps(S,U),!b.__e&&null!=b.shouldComponentUpdate&&!1===b.shouldComponentUpdate(S,b.__s,U)||e.__v===r.__v){for(b.props=S,b.state=b.__s,e.__v!==r.__v&&(b.__d=!1),b.__v=e,e.__e=r.__e,e.__k=r.__k,e.__k.forEac
1h((function(t){t&&(t.__=e)})),T=0;T<b._sb.length;T++)b.__h.push(b._sb[T]);b._sb=[],b.__h.length&&s.push(b);break t}null!=b.componentWillUpdate&&b.componentWillUpdate(S,b.__s,U),null!=b.componentDidUpdate&&b.__h.push((function(){b.componentDidUpdate(y,w,k)}))}if(b.context=U,b.props=S,b.__v=e,b.__P=t,H=i.__r,E=0,"prototype"in $&&$.prototype.render){for(b.state=b.__s,b.__d=!1,H&&H(e),m=b.render(b.props,b.state,b.context),V=0;V<b._sb.length;V++)b.__h.push(b._sb[V]);b._sb=[]}else do{b.__d=!1,H&&H(e),m=b.render(b.props,b.state,b.context),b.state=b.__s}while(b.__d&&++E<25);b.state=b.__s,null!=b.getChildContext&&(o=_(_({},o),b.getChildContext())),g||null==b.getSnapshotBeforeUpdate||(k=b.getSnapshotBeforeUpdate(y,w)),j=null!=m&&m.type===h&&null==m.key?m.props.children:m,C(t,Array.isArray(j)?j:[j],e,r,o,l,a,s,d,f),b.base=e.__e,e.__h=null,b.__h.length&&s.push(b),L&&(b.__E=b.__=null),b.__e=!1}else null==a&&e.__v===r.__v?(e.__k=r.__k,e.__e=r.__e):e.__e=function(t,e,i,r,o,l,a,s){var _,d,f,h=i.props,v=e.props,m=e.type,b=0;if("svg"===m&&(o=!0),null!=l)for(;b<l.length;b++)if((_=l[b])&&"setAttribute"in _==!!m&&(m?_.localName===m:3===_.nodeType)){t=_,l[b]=null;break}if(null==t){if(null===m)return document.createTextNode(v);t=o?document.createElementNS("http://www.w3.org/2000/svg",m):document.createElement(m,v.is&&v),l=null,s=!1}if(null===m)h===v||s&&t.data===v||(t.data=v);else{if(l=l&&n.call(t.childNodes),d=(h=i.props||u).dangerouslySetInnerHTML,f=v.dangerouslySetInnerHTML,!s){if(null!=l)for(h={},b=0;b<t.attributes.length;b++)h[t.attributes[b].name]=t.attributes[b].value;(f||d)&&(f&&(d&&f.__html==d.__html||f.__html===t.innerHTML)||(t.innerHTML=f&&f.__html||""))}if(function(t,e,n,i,r){var o;for(o in n)"children"===o||"key"===o||o in e||N(t,o,null,n[o],i);for(o in e)r&&"function"!=typeof e[o]||"children"===o||"key"===o||"value"===o||"checked"===o||n[o]===e[o]||N(t,o,e[o],n[o],i)}(t,v,h,o,s),f)e.__k=[];else if(b=e.props.children,C(t,Array.isArray(b)?b:[b],e,i,r,o&&"foreignObject"!==m,l,a,l?l[0]:i.__k&&p(i,0),s),null!=l)for(b=l.length;b--;)null!=l[b]&&c(l[b]);s||("value"in v&&void 0!==(b=v.value)&&(b!==t.value||"progress"===m&&!b||"option"===m&&b!==h.value)&&N(t,"value",b,h.value,!1),"checked"in v&&void 0!==(b=v.checked)&&b!==t.checked&&N(t,"checked",b,h.checked,!1))}return t}(r.__e,e,r,o,l,a,s,f);(m=i.diffed)&&m(e)}catch(t){e.__v=null,(f||null!=a)&&(e.__e=d,e.__h=!!f,a[a.indexOf(d)]=null),i.__e(t,e,r)}}function U(t,e){i.__c&&i.__c(e,t),t.some((function(e){try{t=e.__h,e.__h=[],t.some((function(t){t.call(e)}))}catch(t){i.__e(t,e.__v)}}))}function T(t,e,n){try{"function"==typeof t?t(e):t.current=e}catch(t){i.__e(t,n)}}function H(t,e,n){var r,o;if(i.unmount&&i.unmount(t),(r=t.ref)&&(r.current&&r.current!==t.__e||T(r,null,e)),null!=(r=t.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(t){i.__e(t,e)}r.base=r.__P=null,t.__c=void 0}if(r=t.__k)for(o=0;o<r.length;o++)r[o]&&H(r[o],e,n||"function"!=typeof t.type);n||null==t.__e||c(t.__e),t.__=t.__e=t.__d=void 0}function M(t,e,n){return this.constructor(t,n)}n=a.slice,i={__e:function(t,e,n,i){for(var r,o,l;e=e.__;)if((r=e.__c)&&!r.__)try{if((o=r.constructor)&&null!=o.getDerivedStateFromError&&(r.setState(o.getDerivedStateFromError(t)),l=r.__d),null!=r.componentDidCatch&&(r.componentDidCatch(t,i||{}),l=r.__d),l)return r.__E=r}catch(e){t=e}throw t}},r=0,v.prototype.setState=function(t,e){var n;n=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=_({},this.state),"function"==typeof t&&(t=t(_({},n),this.props)),t&&_(n,t),null!=t&&this.__v&&(e&&this._sb.push(e),b(this))},v.prototype.forceUpdate=function(t){this.__v&&(this.__e=!0,t&&this.__h.push(t),b(this))},v.prototype.render=h,o=[],g.__r=0;var E,V,j,$,I=0,D=[],A=[],P=i.__b,B=i.__r,Z=i.diffed,O=i.__c,F=i.unmount;function G(t,e){i.__h&&i.__h(V,t,I||e),I=0;var n=V.__H||(V.__H={__:[],__h:[]});return t>=n.__.length&&n.__.push({__V:A}),n.__[t]}function W(t){return I=1,function(t,e){var n=G(E++,2);if(n.t=t,!n.__c&&(n.__=[nt(void 0,e),function(t){var e=n.__N?n.__N[0]:n.__[0],i=n.t(e,t);e!==i&&(n.__N=[i,n.__[1]],n.__c.setState({}))}],n.__c=V,!V.u)){V.u=!0;var i=V.shouldComponentUpdate;V.shouldComponentUpdate=function(t,e,r){if(!n.__c.__H)return!0;var o=n.__c.__H.__.filter((function(t){return t.__c}));if(o.every((function(t){return!t.__N})))return!i||i.call(this,t,e,r);var l=!1;return o.forEach((function(t){if(t.__N){var e=t.__[0];t.__=t.__N,t.__N=void 0,e!==t.__[0]&&(l=!0)}})),!(!l&&n.__c.props===t)&&(!i||i.call(this,t,e,r))}}return n.__N||n.__}(nt,t)}function z(t,e){var n=G(E++,3);!i.__s&&et(n.__H,e)&&(n.__=t,n.i=e,V.__H.__h.push(n))}function q(t){return I=5,R((function(){return{current:t}}),[])}function R(t,e){var n=G(E++,7);return et(n.__H,e)?(n.__V=t(),n.i=e,n.__h=t,n.__V):n.__}function J(t,e){return I=8,R((function(){return t}),e)}function X(){for(var t;t=D.shift();)if(t.__P&&t.__H)try{t.__H.__h.forEach(Y),t.__H.__h.forEach(tt),t.__H.__h=[]}catch(e){t.__H.__h=[],i.__e(e,t.__v)}}i.__b=function(t){V=null,P&&P(t)},i.__r=function(t){B&&B(t),E=0;var e=(V=t.__c).__H;e&&(j===V?(e.__h=[],V.__h=[],e.__.forEach((function(t){t.__N&&(t.__=t.__N),t.__V=A,t.__N=t.i=void 0}))):(e.__h.forEach(Y),e.__h.forEach(tt),e.__h=[])),j=V},i.diffed=function(t){Z&&Z(t);var e=t.__c;e&&e.__H&&(e.__H.__h.length&&(1!==D.push(e)&&$===i.requestAnimationFrame||(($=i.requestAnimationFrame)||Q)(X)),e.__H.__.forEach((function(t){t.i&&(t.__H=t.i),t.__V!==A&&(t.__=t.__V),t.i=void 0,t.__V=A}))),j=V=null},i.__c=function(t,e){e.some((function(t){try{t.__h.forEach(Y),t.__h=t.__h.filter((function(t){return!t.__||tt(t)}))}catch(n){e.some((function(t){t.__h&&(t.__h=[])})),e=[],i.__e(n,t.__v)}})),O&&O(t,e)},i.unmount=function(t){F&&F(t);var e,n=t.__c;n&&n.__H&&(n.__H.__.forEach((function(t){try{Y(t)}catch(t){e=t}})),n.__H=void 0,e&&i.__e(e,n.__v))};var K="function"==typeof requestAnimationFrame;function Q(t){var e,n=function(){clearTimeout(i),K&&cancelAnimationFrame(e),setTimeout(t)},i=setTimeout(n,100);K&&(e=requestAnimationFrame(n))}function Y(t){var e=V,n=t.__c;"function"==typeof n&&(t.__c=void 0,n()),V=e}function tt(t){var e=V;t.__c=t.__(),V=e}function et(t,e){return!t||t.length!==e.length||e.some((function(e,n){return e!==t[n]}))}function nt(t,e){return"function"==typeof e?e(t):e}function it(){throw new Error("Cycle detected")}function rt(){if(st>1)st--;else{for(var t,e=!1;void 0!==at;){var n=at;for(at=void 0,_t++;void 0!==n;){var i=n.o;if(n.o=void 0,n.f&=-3,!(8&n.f)&&vt(n))try{n.c()}catch(n){e||(t=n,e=!0)}n=i}}if(_t=0,st--,e)throw t}}function ot(t){if(st>0)return t();st++;try{return t()}finally{rt()}}var lt,ut=void 0,at=void 0,st=0,_t=0,ct=0;function dt(t){if(void 0!==ut){var e=t.n;if(void 0===e||e.t!==ut)return e={i:0,S:t,p:ut.s,n:void 0,t:ut,e:void 0,x:void 0,r:e},void 0!==ut.s&&(ut.s.n=e),ut.s=e,t.n=e,32&ut.f&&t.S(e),e;if(-1===e.i)return e.i=0,void 0!==e.n&&(e.n.p=e.p,void 0!==e.p&&(e.p.n=e.n),e.p=ut.s,e.n=void 0,ut.s.n=e,ut.s=e),e}}function ft(t){this.v=t,this.i=0,this.n=void 0,this.t=void 0}function ht(t){return new ft(t)}function vt(t){for(var e=t.s;void 0!==e;
1e=e.n)if(e.S.i!==e.i||!e.S.h()||e.S.i!==e.i)return!0;return!1}function pt(t){for(var e=t.s;void 0!==e;e=e.n){var n=e.S.n;if(void 0!==n&&(e.r=n),e.S.n=e,e.i=-1,void 0===e.n){t.s=e;break}}}function mt(t){for(var e=t.s,n=void 0;void 0!==e;){var i=e.p;-1===e.i?(e.S.U(e),void 0!==i&&(i.n=e.n),void 0!==e.n&&(e.n.p=i)):n=e,e.S.n=e.r,void 0!==e.r&&(e.r=void 0),e=i}t.s=n}function bt(t){ft.call(this,void 0),this.x=t,this.s=void 0,this.g=ct-1,this.f=4}function gt(t){var e=t.u;if(t.u=void 0,"function"==typeof e){st++;var n=ut;ut=void 0;try{e()}catch(e){throw t.f&=-2,t.f|=8,Ct(t),e}finally{ut=n,rt()}}}function Ct(t){for(var e=t.s;void 0!==e;e=e.n)e.S.U(e);t.x=void 0,t.s=void 0,gt(t)}function yt(t){if(ut!==this)throw new Error("Out-of-order effect");mt(this),ut=t,this.f&=-2,8&this.f&&Ct(this),rt()}function wt(t){this.x=t,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32}function kt(t){var e=new wt(t);try{e.c()}catch(t){throw e.d(),t}return e.d.bind(e)}function Nt(t,e){i[t]=e.bind(null,i[t]||function(){})}function Lt(t){lt&&lt(),lt=t&&t.S()}function St(t){var e=this,n=t.data,i=function(t){return R((function(){return ht(t)}),[])}(n);i.value=n;var r=R((function(){for(var t=e.__v;t=t.__;)if(t.__c){t.__c.__$f|=4;break}return e.__$u.c=function(){e.base.data=r.peek()},new bt((function(){var t=i.value.value;return 0===t?0:!0===t?"":t||""}))}),[]);return r.value}function xt(t,e,n,i){var r=e in t&&void 0===t.ownerSVGElement,o=ht(n);return{o:function(t,e){o.value=t,i=e},d:kt((function(){var n=o.value.value;i[e]!==n&&(i[e]=n,r?t[e]=n:n?t.setAttribute(e,n):t.removeAttribute(e))}))}}ft.prototype.h=function(){return!0},ft.prototype.S=function(t){this.t!==t&&void 0===t.e&&(t.x=this.t,void 0!==this.t&&(this.t.e=t),this.t=t)},ft.prototype.U=function(t){if(void 0!==this.t){var e=t.e,n=t.x;void 0!==e&&(e.x=n,t.e=void 0),void 0!==n&&(n.e=e,t.x=void 0),t===this.t&&(this.t=n)}},ft.prototype.subscribe=function(t){var e=this;return kt((function(){var n=e.value,i=32&this.f;this.f&=-33;try{t(n)}finally{this.f|=i}}))},ft.prototype.valueOf=function(){return this.value},ft.prototype.toString=function(){return this.value+""},ft.prototype.peek=function(){return this.v},Object.defineProperty(ft.prototype,"value",{get:function(){var t=dt(this);return void 0!==t&&(t.i=this.i),this.v},set:function(t){if(t!==this.v){_t>100&&it(),this.v=t,this.i++,ct++,st++;try{for(var e=this.t;void 0!==e;e=e.x)e.t.N()}finally{rt()}}}}),(bt.prototype=new ft).h=function(){if(this.f&=-3,1&this.f)return!1;if(32==(36&this.f))return!0;if(this.f&=-5,this.g===ct)return!0;if(this.g=ct,this.f|=1,this.i>0&&!vt(this))return this.f&=-2,!0;var t=ut;try{pt(this),ut=this;var e=this.x();(16&this.f||this.v!==e||0===this.i)&&(this.v=e,this.f&=-17,this.i++)}catch(t){this.v=t,this.f|=16,this.i++}return ut=t,mt(this),this.f&=-2,!0},bt.prototype.S=function(t){if(void 0===this.t){this.f|=36;for(var e=this.s;void 0!==e;e=e.n)e.S.S(e)}ft.prototype.S.call(this,t)},bt.prototype.U=function(t){if(void 0!==this.t&&(ft.prototype.U.call(this,t),void 0===this.t)){this.f&=-33;for(var e=this.s;void 0!==e;e=e.n)e.S.U(e)}},bt.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var t=this.t;void 0!==t;t=t.x)t.t.N()}},bt.prototype.peek=function(){if(this.h()||it(),16&this.f)throw this.v;return this.v},Object.defineProperty(bt.prototype,"value",{get:function(){1&this.f&&it();var t=dt(this);if(this.h(),void 0!==t&&(t.i=this.i),16&this.f)throw this.v;return this.v}}),wt.prototype.c=function(){var t=this.S();try{8&this.f||void 0===this.x||(this.u=this.x())}finally{t()}},wt.prototype.S=function(){1&this.f&&it(),this.f|=1,this.f&=-9,gt(this),pt(this),st++;var t=ut;return ut=this,yt.bind(this,t)},wt.prototype.N=function(){2&this.f||(this.f|=2,this.o=at,at=this)},wt.prototype.d=function(){this.f|=8,1&this.f||Ct(this)},St.displayName="_st",Object.defineProperties(ft.prototype,{constructor:{configurable:!0,value:void 0},type:{configurable:!0,value:St},props:{configurable:!0,get:function(){return{data:this}}},__b:{configurable:!0,value:1}}),Nt("__b",(function(t,e){if("string"==typeof e.type){var n,i=e.props;for(var r in i)if("children"!==r){var o=i[r];o instanceof ft&&(n||(e.__np=n={}),n[r]=o,i[r]=o.peek())}}t(e)})),Nt("__r",(function(t,e){Lt();var n,i,r=e.__c;r&&(r.__$f&=-2,void 0===(n=r.__$u)&&(r.__$u=(kt((function(){i=this})),i.c=function(){r.__$f|=1,r.setState({})},n=i))),Lt(n),t(e)})),Nt("__e",(function(t,e,n,i){Lt(),t(e,n,i)})),Nt("diffed",(function(t,e){var n;if(Lt(),"string"==typeof e.type&&(n=e.__e)){var i=e.__np,r=e.props;if(i){var o=n.U;if(o)for(var l in o){var u=o[l];void 0===u||l in i||(u.d(),o[l]=void 0)}else n.U=o={};for(var a in i){var s=o[a],_=i[a];void 0===s?(s=xt(n,a,_,r),o[a]=s):s.o(_,r)}}}t(e)})),Nt("unmount",(function(t,e){if("string"==typeof e.type){var n=e.__e;if(n){var i=n.U;if(i)for(var r in n.U=void 0,i){var o=i[r];o&&o.d()}}}else{var l=e.__c;if(l){var u=l.__$u;u&&(l.__$u=void 0,u.d())}}t(e)})),Nt("__h",(function(t,e,n,i){i<3&&(e.__$f|=2),t(e,n,i)})),v.prototype.shouldComponentUpdate=function(t,e){var n=this.__$u;if(!(n&&void 0!==n.s||4&this.__$f))return!0;
1if(3&this.__$f)return!0;for(var i in e)return!0;for(var r in t)if("__source"!==r&&t[r]!==this.props[r])return!0;for(var o in this.props)if(!(o in t))return!0;return!1};const Ut=ht({closed:!1,debateUuid:"",contributionsCount:0,guidelineUrl:"",isAllLoaded:!1}),Tt=()=>d("svg",{width:"24",height:"25",viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg"},d("path",{d:"M12 23C9.21523 23 6.54451 21.8938 4.57538 19.9246C2.60625 17.9555 1.5 15.2848 1.5 12.5C1.5 9.71523 2.60625 7.04451 4.57538 5.07538C6.54451 3.10625 9.21523 2 12 2C14.7848 2 17.4555 3.10625 19.4246 5.07538C21.3938 7.04451 22.5 9.71523 22.5 12.5C22.5 15.2848 21.3938 17.9555 19.4246 19.9246C17.4555 21.8938 14.7848 23 12 23ZM12 24.5C15.1826 24.5 18.2348 23.2357 20.4853 20.9853C22.7357 18.7348 24 15.6826 24 12.5C24 9.3174 22.7357 6.26516 20.4853 4.01472C18.2348 1.76428 15.1826 0.5 12 0.5C8.8174 0.5 5.76516 1.76428 3.51472 4.01472C1.26428 6.26516 0 9.3174 0 12.5C0 15.6826 1.26428 18.7348 3.51472 20.9853C5.76516 23.2357 8.8174 24.5 12 24.5Z",fill:"currentColor"}),d("path",{d:"M13.3949 10.382L9.95993 10.8125L9.83693 11.3825L10.5119 11.507C10.9529 11.612 11.0399 11.771 10.9439 12.2105L9.83693 17.4125C9.54593 18.758 9.99443 19.391 11.0489 19.391C11.8664 19.391 12.8159 19.013 13.2464 18.494L13.3784 17.87C13.0784 18.134 12.6404 18.239 12.3494 18.239C11.9369 18.239 11.7869 17.9495 11.8934 17.4395L13.3949 10.382ZM13.4999 7.25C13.4999 7.64782 13.3419 8.02936 13.0606 8.31066C12.7793 8.59196 12.3978 8.75 11.9999 8.75C11.6021 8.75 11.2206 8.59196 10.9393 8.31066C10.658 8.02936 10.4999 7.64782 10.4999 7.25C10.4999 6.85218 10.658 6.47064 10.9393 6.18934C11.2206 5.90804 11.6021 5.75 11.9999 5.75C12.3978 5.75 12.7793 5.90804 13.0606 6.18934C13.3419 6.47064 13.4999 6.85218 13.4999 7.25Z",fill:"currentColor"})),Ht=({reversed:t=!1})=>d("a",{className:"guideline-link"+(t?" guideline-link--reversed":""),target:"_blank",href:Ut.value.guidelineUrl,rel:"noreferrer"},d("span",null,"Guidelines for debat"),d(Tt,null)),Mt=()=>d("div",{className:"introduction"},d("div",{className:"introduction__header"},d("h3",{className:"introduction__title"},"Deltag i debatten"),d(Ht,null)),d("div",{className:"introduction__text"},d("p",null,"Log ind eller opret bruger for at deltage. Læs vores"," ",d("a",{href:Ut.value.guidelineUrl,target:"_blank",rel:"noreferrer"},"privatlivspolitik og retningslinjer")," ","– og hold den gode tone."),d(Ht,null))),Et=ht({uuid:"",firstName:"",lastName:"",isLoggedIn:!1}),Vt=()=>Ut.value.closed,jt=({title:t,description:e,link:n,children:i})=>d("div",{className:"contribution-overlay"},t&&d("h4",{className:"contribution-overlay__title"},t),e&&d("p",{className:"contribution-overlay__description"},e),n&&d("a",{href:n.href,target:n.target??"_blank",className:"contribution-form__submit contribution-overlay__button",rel:"noreferrer"},n.label),i),$t=()=>{const{firstName:t,lastName:e}=Et.value;return d("div",{className:"contribution-form"},d("div",{className:"contribution-form__wrapper contribution-form--closed"},d("form",{action:"#",className:"contribution-form__form"},d("h4",{className:"contribution-form__author"},t," ",e),d("label",{className:"contribution-form__label"},d("div",{className:"contribution-form__label-info"},d("span",null,"Baggrundsinfo (valgfrit)"),d("span",{className:"contribution-form__counter"},"0/75"))),d("label",{className:"contribution-form__label"},d("div",{className:"contribution-form__label-info"},d("span",{className:"contribution-form__counter"},"0/1000")))),d(jt,{title:"Debatten er lukket for nye indlæg",description:"Debatten for artiklen her er blevet lukket af redaktionen."})))},It=t=>{const{uuid:e,content:n,background:i,parentUuid:r}=t;return{uuid:e,parentUuid:r,unixTimestamp:(o=new Date,o.getTime()/1e3),contentCharCount:n.length,backgroundCharCount:i.length};var o},Dt=(t,e)=>{document.dispatchEvent(new CustomEvent(t,{detail:e}))},At=t=>Dt("debate.createContribution",It(t)),Pt=t=>Dt("debate.updateContribution",It(t)),Bt=({contributions:t,users:e})=>t.map((t=>{const{firstName:n,lastName:i,status:r,verified:o}=e.find((e=>e.uuid===t.userUuid));return{...t,user:{firstName:n,lastName:i,status:r,verified:o}}})),Zt=ht([]),Ot=t=>{Zt.value=[...Zt.value,...Bt(t)]},Ft=Zt,Gt=(t,e,n=void 0)=>fetch(e,{method:t,body:n,mode:"same-origin",headers:{"Content-Type":"application/json",Accept:"application/json"}}),Wt=ht({getDebateUrl:"",getUserUrl:"",getContributionsUrl:"",getContributionChildrenUrl:"",createContributionUrl:"",updateContributionUrl:"",selfServiceUrl:""}),zt=t=>Gt("POST",Wt.value.createContributionUrl,JSON.stringify({...t,debateUuid:Ut.value.debateUuid})).then((t=>{if(!t.ok)throw console.error("couldn't create contribution"),t.json();return t.json()})),qt=()=>d("svg",{width:"24",height:"24",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},d("path",{d:"M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z",fill:"currentColor"})),Rt=()=>d("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},d("path",{d:"M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"})),Jt=()=>{const[t,e]=W(!1);return{isLoading:t,setIsLoading:e,loadUntil:async t=>{e(!0);const n=await t();return e(!1),n}}},Xt=(t,e)=>{if(!Array.isArray(e)||0===e.length)return t;const n=new RegExp(`(?<![\\wæøå]+)(${e.join("|")})(?![\\wæøå]+)`,"gmi");return t.replaceAll(n,(t=>`<span class="marked">${t.trim()}</span>`))},Kt=()=>d("svg",{class:"spinner",viewBox:"0 0 50 50"},d("circle",{class:"path",cx:"25",cy:"25",r:"20",fill:"none",strokeWidth:"5"})),Qt=t=>{const e=document.createElement("div");return e.innerText=t,e.textContent=t,e.innerHTML},Yt=Qt,te=t=>{const e=document.createElement("textarea");return e.innerHTML=t,e.value},ee="Indlægget må ikke indeholde ord markeret med rødt.\nSe guidelines for debat.",ne="Dit ord indeholder mere end 40 karakterer og du k
1an derfor ikke poste dit indlæg.",ie=({title:t,defaults:e={background:"",content:"",parentUuid:null},onSubmit:n,onClose:i})=>{const{firstName:r,lastName:o}=Et.value,{loadUntil:l,isLoading:u}=Jt(),[a,s]=W({...e}),{error:_,showError:c,renderError:f}=((t=3e3,e=100)=>{const n=[{opacity:"0",transform:"translateX(100%)"},{opacity:"1",transform:"translateX(0)"}],i={duration:e,iterations:1,composite:"replace"},[r,o]=W(null),l=q(null),u=()=>{null!==l.current&&l.current.animate(n.reverse(),i).finished.then((()=>{null!==l.current&&(l.current.style.opacity="0",o(null))}))};z((()=>{if(null===r||null===l.current)return;let e=null;return l.current.animate(n,i).finished.then((()=>{null!==l.current&&(l.current.style.opacity="1",l.current.style.transform="translateX(0)",0!==t&&(e=setTimeout((()=>{u()}),t)))})),()=>{e&&clearTimeout(e)}}),[r]);const a=J((()=>r&&d("div",{className:"error",ref:l,style:{animationDuration:`${Math.floor(t/1e3)}s`}},d("div",{className:"error__icon"},d(Rt,null)),d("div",{className:"error__content"},r),d("button",{className:"error__close",type:"button",onClick:u},d(qt,null)))),[r]);return{error:r,showError:t=>{o(t)},renderError:a}})(1e4),[h,v]=W([]),p=Boolean(e.contributionUuid),m=()=>{s(e)},b=q(null),g=q(null),C=t=>{const e=t.currentTarget,n=e.name,{maxLength:i}=e;"content"===n&&b.current&&(b.current.scrollTop=t.currentTarget.scrollTop,b.current.scrollLeft=t.currentTarget.scrollLeft),"background"===n&&g.current&&(g.current.scrollTop=t.currentTarget.scrollTop,g.current.scrollLeft=t.currentTarget.scrollLeft),s((t=>e.value.length>i?t:{...t,[n]:e.value}))};return d("div",{className:"contribution-form"},Boolean(t)&&d("div",{className:"contribution-form__top"},t),d("div",{className:"contribution-form__wrapper"},d("form",{action:"#",className:"contribution-form__form",onSubmit:async t=>{t.preventDefault(),u||null!==_||(""!==a.content.trim()?await l((()=>n(a).then(m).catch((async t=>{const e=await t,n=e.message.split("|").map((t=>"blacklist"===t?ee:"long_word"===t?ne:e.message)).join("\n");c(n),v(e.data)})))):c("Indlægget må ikke være tomt"))}},f(),p&&d("button",{className:"contribution-form__close-button",type:"button",onClick:i},d(qt,null)),d("div",{className:"contribution-form__author"},r," ",o),d("label",{className:"contribution-form__label"},d("div",{className:"contribution-form__label-info"},d("span",null,"Baggrundsinfo (valgfrit)"),d("span",{className:"contribution-form__counter"},a.background.length,"/",75)),d("div",{className:"contribution-form__input-wrapper"},d("input",{className:"contribution-form__input",type:"text",name:"background",maxLength:75,placeholder:"Din baggrund for at bidrage til debatten...",value:te(a.background),onInput:C,onScroll:t=>{null!==g.current&&(g.current.scrollLeft=t.currentTarget.scrollLeft)}}),d("div",{ref:g,className:"contribution-form__input-highlight",dangerouslySetInnerHTML:{__html:Xt(Qt(a.background),h)}}))),d("label",{className:"contribution-form__label"},d("div",{className:"contribution-form__label-info"},d("span",{class:"contribution-form__counter"},a.content.length,"/",1e3)),d("div",{className:"contribution-form__input-wrapper"},d("textarea",{className:"contribution-form__input",name:"content",placeholder:"Skriv her....",maxLength:1e3,value:a.content,onInput:C,rows:3,onScroll:t=>{null!==b.current&&(b.current.scrollTop=t.currentTarget.scrollTop,b.current.scrollLeft=t.currentTarget.scrollLeft)}}),d("div",{ref:b,className:"contribution-form__textarea-highlight",dangerouslySetInnerHTML:{__html:Xt(Qt(a.content),h)}}))),d("div",{className:"contribution-form__actions"},d(Ht,{reversed:!0}),d("button",{disabled:u||!!_,type:"submit",className:"contribution-form__submit"+(u?" contribution-form__submit--loading":"")},p?"Opdatér indlæg":"Opret indlæg",d("span",{className:"loader"},u&&d(Kt,null)))))))},re=()=>!Et.value.firstName||!Et.value.lastName,oe=(t,e=1,n=10)=>Gt("GET",`${Wt.value.getContributionsUrl}${t}?page=${e}&pageSize=${n}`).then((t=>t.json())),le=()=>d("svg",{class:"reply-icon",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},d("path",{d:"M10 9V5L3 12L10 19V14.9C15 14.9 18.5 16.5 21 20C20 15 17 10 10 9Z",fill:"currentColor"}));var ue=(t=>(t.active="active",t.inactive="inactive",t))(ue||{});const ae=ue;var se=(t=>(t.active="active",t.deactivated="deactivated",t.cleansed="cleansed",t))(se||{});const _e=se,ce=()=>d("svg",{width:"19",height:"19",viewBox:"0 0 19 19",fill:"none",xmlns:"http://www.w3.org/2000/svg"},d("path",{d:"M3.95833 15.0419H5.06667L11.8948 8.21377L10.7865 7.10544L3.95833 13.9336V15.0419ZM15.2792 7.06585L11.9146 3.74085L14.151 1.50439L17.4958 4.84919L15.2792 7.06585ZM2.375 16.6252V13.2606L10.7667 4.86898L14.1312 8.23356L5.73958 16.6252H2.375ZM11.3406 7.6596L10.7865 7.10544L11.8948 8.21377L11.3406 7.6596Z",fill:"currentColor"})),de=t=>{const e=Math.floor(((new Date).getTime()-t)/1e3);return e/86400>1?(t=>{const[e,n]=new Intl.DateTimeFormat("tr-TR",{hour:"2-digit",minute:"2-digit",day:"2-digit",month:"2-digit",year:"2-digit"}).format(t).split(" ");return`${n} ${e}`})(new Date(t)):(t=>{let e=t/3600;return e>1?`${Math.floor(e)} timer`:(e=t/60,`${Math.floor(e)} min.`)})(e)},fe=()=>
1d("svg",{width:"30",height:"22",viewBox:"0 0 30 22",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg"},d("path",{d:"M22.4 11L17.6667 6.26671L19.5667 4.40004L22.4 7.23337L28.0667 1.56671L29.9334 3.46671L22.4 11ZM11 11C9.53337 11 8.27782 10.4778 7.23337 9.43337C6.18893 8.38893 5.66671 7.13337 5.66671 5.66671C5.66671 4.20004 6.18893 2.94448 7.23337 1.90004C8.27782 0.855596 9.53337 0.333374 11 0.333374C12.4667 0.333374 13.7223 0.855596 14.7667 1.90004C15.8111 2.94448 16.3334 4.20004 16.3334 5.66671C16.3334 7.13337 15.8111 8.38893 14.7667 9.43337C13.7223 10.4778 12.4667 11 11 11ZM0.333374 21.6667V17.9334C0.333374 17.1778 0.527818 16.4834 0.916707 15.85C1.3056 15.2167 1.82226 14.7334 2.46671 14.4C3.84448 13.7111 5.24448 13.1945 6.66671 12.85C8.08893 12.5056 9.53337 12.3334 11 12.3334C12.4667 12.3334 13.9111 12.5056 15.3334 12.85C16.7556 13.1945 18.1556 13.7111 19.5334 14.4C20.1778 14.7334 20.6945 15.2167 21.0834 15.85C21.4723 16.4834 21.6667 17.1778 21.6667 17.9334V21.6667H0.333374ZM3.00004 19H19V17.9334C19 17.6889 18.9389 17.4667 18.8167 17.2667C18.6945 17.0667 18.5334 16.9111 18.3334 16.8C17.1334 16.2 15.9223 15.75 14.7 15.45C13.4778 15.15 12.2445 15 11 15C9.75559 15 8.52226 15.15 7.30004 15.45C6.07782 15.75 4.86671 16.2 3.66671 16.8C3.46671 16.9111 3.3056 17.0667 3.18337 17.2667C3.06115 17.4667 3.00004 17.6889 3.00004 17.9334V19ZM11 8.33337C11.7334 8.33337 12.3611 8.07226 12.8834 7.55004C13.4056 7.02782 13.6667 6.40004 13.6667 5.66671C13.6667 4.93337 13.4056 4.3056 12.8834 3.78337C12.3611 3.26115 11.7334 3.00004 11 3.00004C10.2667 3.00004 9.63893 3.26115 9.11671 3.78337C8.59448 4.3056 8.33337 4.93337 8.33337 5.66671C8.33337 6.40004 8.59448 7.02782 9.11671 7.55004C9.63893 8.07226 10.2667 8.33337 11 8.33337Z",fill:"currentColor"})),he=t=>{const{background:e,created:n,fullName:i,modified:r,userUuid:o,isDeactivated:l,setIsEditing:u,isVerified:a}=t,s=Et.value.uuid===o,[_,c]=W(de(1e3*n));return z((()=>{const t=setInterval((()=>c(de(1e3*n))),6e4);return()=>{clearInterval(t)}}),[]),d("div",{className:"contribution__header"+(a?" contribution__header--verified":"")},a&&d("picture",{className:"contribution__verified-icon"},d(fe,null)),d("div",{className:"contribution__author"+(s?" contribution__author--owner":"")},i,d("span",{className:"contribution__background",dangerouslySetInnerHTML:{__html:Yt(e)}})),d("div",{className:"contribution__date"},_,r&&" (redigeret)"),d("div",{className:"contribution__actions"},s&&!l&&d("button",{type:"button",className:"contribution__header-action",onClick:()=>u(!0)},d(ce,null)),!1))},ve=()=>d("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},d("g",{clipPath:"url(#clip0_35_2263)"},d("path",{d:"M6.89627 12.6039V8.37109H5.30897C4.888 8.37109 4.48426 8.53833 4.18659 8.836C3.88891 9.13368 3.72168 9.53741 3.72168 9.95839V19.4821C3.72247 19.5804 3.7506 19.6765 3.80294 19.7597C3.85527 19.8429 3.92973 19.9098 4.01797 19.953C4.10299 19.9917 4.19672 20.0072 4.28965 19.9979C4.38258 19.9886 4.4714 19.9549 4.54707 19.9001L7.27192 17.8949H14.383C14.5835 17.9008 14.7831 17.8655 14.9695 17.7911C15.1558 17.7168 15.3249 17.605 15.4663 17.4626C15.6076 17.3202 15.7182 17.1504 15.7913 16.9635C15.8643 16.7767 15.8983 16.5768 15.8909 16.3763V15.7785H10.0709C9.2289 15.7785 8.42143 15.444 7.82608 14.8486C7.23073 14.2533 6.89627 13.4458 6.89627 12.6039Z",fill:"currentColor"}),d("path",{d:"M19.0654 4.66602H10.0707C9.64972 4.66602 9.24598 4.83325 8.94831 5.13092C8.65063 5.4286 8.4834 5.83233 8.4834 6.25331V12.6025C8.4834 13.0235 8.65063 13.4272 8.94831 13.7249C9.24598 14.0225 9.64972 14.1898 10.0707 14.1898H17.24L19.7691 16.1527C19.8442 16.2083 19.9328 16.243 20.0257 16.2532C20.1187 16.2634 20.2127 16.2488 20.2981 16.2109C20.3882 16.168 20.4643 16.1006 20.5176 16.0163C20.571 15.9321 20.5995 15.8345 20.5997 15.7347V6.25331C20.6 5.84134 20.44 5.44542 20.1537 5.14922C19.8674 4.85302 19.4771 4.67975 19.0654 4.66602Z",fill:"currentColor"})),d("defs",null,d("clipPath",{id:"clip0_35_2263"},d("rect",{width:"24",height:"24",fill:"white"})))),pe=t=>t.replaceAll(/((http|https):\/\/[\w?=&.\\/-;#~%-]+(?![\w\s?&.\\/;#~%"=-]*>))/gi,'<a target="_blank" href="$1">$1</a>'),me=({content:t})=>{const e=t.split(" ").slice(0,50),n=e.length===t.split(" ").length,[i,r]=W(n),o=e.join(" ");return d("div",{className:"contribution__content"},i&&d("p",{dangerouslySetInnerHTML:{__html:pe(Yt(t)).trim()}}),!i&&d("p",null,Yt(o.trim()),"... ",d("button",{className:"contribution__read-more",type:"button",onClick:()=>r(!0)},"Læs mere")))},be=()=>Gt("GET",Wt.value.getUserUrl).then((t=>{if(!t.ok)throw console.error("couldn't fetch user"),new Error;return t.json()})).catch((()=>Et.value)),ge=({contribution:t,child:e})=>{const[n,i]=W(t),{content:r,created:o,background:l,modified:u,childrenCount:a,userUuid:s,uuid:_,status:c,user:f}=n,[v,p]=W([]),[m,b]=W(!1),[g,C]=W(!1),{isLoading:y,loadUntil:w}=Jt(),k=c===ae.inactive||f.status===_e.deactivated||f.status===_e.cleansed;return d(h,null,g&&d(ie,{defaults:{content:r,background:l,contributionUuid:_},onSubmit:async t=>{return(e=t,Gt("PUT",Wt.value.updateContributionUrl,JSON.stringify({...e,userUuid:Et.value.uuid,debateUuid:Ut.value.debateUuid})).then((t=>{if(!t.ok)throw console.error("couldn't update contribution"),t.json();return t.json()}))).then((t=>(Pt(t.contribution),i(Bt({contributions:[t.contribution],users:[t.user]})[0]),C(!1),!0)));var e},onClose:()=>C(!1)}),!g&&d("div",{className:"contribution "+(k?"contribution--overlay":""),"data-uuid":_},d(he,{background:l,created:o,fullName:`${f.firstName||""} ${f.lastName||""}`,modified:u,userUuid:s,setIsEditing:C,isDeactivated:k||Vt(),isVerified:f.verified}),!k&&d(me,{content:r}),!e&&d("div",{className:"contribution__footer"},d("button",{type:"button",className:"reply-button",onClick:()=>{y||w((async()=>
1{if(a>0&&0===v.length){const e=await(t=_,Gt("GET",Wt.value.getContributionChildrenUrl.replace("<uuid>",t)).then((t=>{if(!t.ok)throw console.error("couldn't fetch contribution children"),new Error;return t.json()})));p(Bt(e))}var t;b((t=>!t)),Et.value=await be()}))},disabled:!Et.value.isLoggedIn||Vt()&&0===a||k&&0===a},a>0&&d(y?Kt:ve,null),0===a&&!k&&d(le,null),d("span",null,a>0&&`${a} svar`,!k&&a<=0&&"Svar"))),k&&d(jt,{title:"Indlæg er blevet slettet",description:"Indlægget er blevet fjernet på brugerens anmodning eller af en moderator."})),!e&&m&&d("div",{className:"contribution-children"},v.map((t=>d(ge,{key:t.uuid,contribution:t,child:!0}))),!Vt()&&!k&&d(ie,{title:"Svar i tråden",onSubmit:async t=>zt(t).then((t=>{var e;return At(t.contributions[0]),e=t,ot((()=>{Ut.value.contributionsCount+=1})),i((t=>({...t,childrenCount:t.childrenCount+1}))),p((t=>[...t,...Bt(e)])),!0})),defaults:{background:"",content:"",parentUuid:_}})))},Ce=ge,ye=()=>d("svg",{className:"down-arrow-icon",width:"24",height:"24",viewBox:"0 0 24 24"},d("path",{d:"M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z",fill:"currentColor"})),we=()=>d("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},d("path",{d:"M11 13H5V11H11V5H13V11H19V13H13V19H11V13Z",fill:"currentColor"})),ke=({onClick:t})=>d("div",{className:"join-debate"},d("p",{className:"join-debate__description"},"Deltag i debatten ved at tilføje dit indlæg."),d("button",{type:"button",className:"contribution-list__action-button",onClick:t},d(we,null)," Tilføj indlæg")),Ne=({onClickShowContributionFormButton:t,showContributionFormButton:e})=>{const n=!Et.value.isLoggedIn||re()?1:2,{debateUuid:i,contributionsCount:r}=Ut.value,o=R((()=>Ft.value.map((t=>t.childrenCount+1)).reduce(((t,e)=>t+e),0)<r),[Ut.value.contributionsCount,Ft.value.length]),l=Et.value.isLoggedIn&&!Ut.value.isAllLoaded&&o,u=J((()=>{oe(i,1,1e4).then((e=>{e.contributions.splice(0,n),Ot(e),Ut.value.isAllLoaded=!0,t()}))}),[]);return z((()=>{0!==Ut.value.contributionsCount&&oe(i,1,n).then((t=>{Ot(t),Ut.value.contributionsCount=t.contributionsCount}))}),[]),d("div",{className:"contribution-list"},d("div",{className:"contribution-list__header"},d("div",{className:"contribution-list__count"},r>0&&`${r} indlæg`,0===r&&"Vær den første til at skrive et indlæg ")),Ft.value.map((t=>d(Ce,{key:t.uuid,contribution:t}))),(e||l)&&d("div",{className:"contribution-list__actions"+(l!==e?" contribution-list__actions--centered":"")},l&&d("button",{className:"contribution-list__action-button "+(Vt()?"contributions-list__action-button--no-bottom-padding":""),type:"button",onClick:u},d(ye,null),d("span",null,"Indlæs flere indlæg")),e&&d(ke,{onClick:t})))},Le=()=>d("svg",{xmlns:"http://www.w3.org/2000/svg",width:"19",height:"19",viewBox:"0 0 19 19",fill:"none"},d("g",{"clip-path":"url(#clip0_35_1563)"},d("path",{d:"M1.29182 9.02027V15.8194H4.17032L4.31567 15.8365C6.98802 16.4597 8.75882 16.9091 9.64137 17.1874C10.8137 17.557 11.2507 17.6472 12.0458 17.7004C12.6405 17.7413 13.316 17.5123 13.6238 17.1988C13.7938 17.0259 13.9211 16.6706 13.9715 16.1196C13.9819 16.0041 14.0232 15.8935 14.0911 15.7994C14.1589 15.7053 14.2508 15.6311 14.3572 15.5848C14.5937 15.4822 14.7904 15.315 14.9547 15.0718C15.1067 14.8495 15.2055 14.4353 15.2236 13.8358C15.2267 13.7256 15.258 13.618 15.3143 13.5233C15.3707 13.4285 15.4503 13.3497 15.5456 13.2943C16.0985 12.9742 16.3721 12.6132 16.4291 12.1895C16.4918 11.7211 16.3398 11.1939 15.9418 10.5935C15.8484 10.4527 15.8136 10.281 15.8448 10.1149C15.876 9.94886 15.9708 9.80153 16.109 9.70427C16.4899 9.43637 16.6989 9.06397 16.7512 8.53577C16.8348 7.69407 16.298 7.07182 15.083 6.94737C14.0008 6.84034 12.9082 6.93144 11.8587 7.21622C11.7396 7.24733 11.6142 7.24379 11.497 7.20602C11.3799 7.16825 11.276 7.09782 11.1976 7.00301C11.1192 6.9082 11.0694 6.79296 11.0543 6.67085C11.0391 6.54874 11.0591 6.42484 11.112 6.31372C11.587 5.30862 11.8511 4.47927 11.9128 3.83707C11.9936 2.98492 11.7969 2.36742 11.3371 1.85822C10.9885 1.47252 10.4308 1.25212 10.2218 1.29772C9.94632 1.35662 9.76677 1.51622 9.53307 2.07482C9.39532 2.40542 9.32882 2.68662 9.21482 3.34307C9.10557 3.96627 9.04572 4.24747 8.92127 4.61607C8.54602 5.73327 7.62547 6.89132 6.38952 7.69027C5.5233 8.24955 4.58452 8.68746 3.59937 8.99177C3.53782 9.01074 3.47377 9.02035 3.40937 9.02027H1.29182ZM1.25192 17.1143C0.945067 17.1228 0.669567 17.0544 0.438717 16.8929C0.144217 16.6868 0.00551662 16.3619 0.00266662 15.9876L0.00551662 9.03072C-0.0267834 8.66022 0.0824666 8.32012 0.340867 8.06742C0.583117 7.82992 
10.899467 7.71782 1.23387 7.72542H3.30962C4.14928 7.45787 4.94981 7.08029 5.69032 6.60252C6.68592 5.95842 7.41932 5.03502 7.69957 4.20282C7.79552 3.91592 7.84682 3.67842 7.94372 3.11982C8.07482 2.37027 8.15652 2.02162 8.34462 1.57322C8.73412 0.640317 9.24522 0.184317 9.95012 0.0313675C10.6436 -0.118733 11.6535 0.281217 12.2919 0.988017C12.9996 1.77082 13.3122 2.75027 13.1963 3.96057C13.1469 4.48117 13.0025 5.06352 12.765 5.71237C13.5761 5.59416 14.3986 5.5763 15.2141 5.65917C17.1207 5.85392 18.1914 7.09557 18.0356 8.66497C17.9672 9.34137 17.7221 9.91612 17.305 10.3674C17.6556 11.0428 17.7952 11.7107 17.7078 12.3624C17.6071 13.1129 17.1891 13.738 16.4937 14.2234C16.4396 14.8818 16.2885 15.4071 16.0206 15.8004C15.8095 16.1182 15.5341 16.3881 15.2122 16.5927C15.1096 17.2425 14.8939 17.7508 14.5415 18.108C13.9572 18.7027 12.9132 19.057 11.9594 18.9924C11.054 18.9316 10.5182 18.8214 9.25472 18.4224C8.42157 18.1593 6.69637 17.7223 4.09622 17.1143H1.25192ZM2.86787 8.72482C2.86762 8.63982 2.88414 8.55562 2.91649 8.47702C2.94885 8.39842 2.99639 8.32698 3.0564 8.2668C3.11641 8.20661 3.18771 8.15885 3.26621 8.12627C3.34471 8.09369 3.42887 8.07692 3.51387 8.07692C3.5987 8.07717 3.68266 8.09412 3.76094 8.12682C3.83922 8.15951 3.91029 8.2073 3.9701 8.26747C4.02991 8.32763 4.07729 8.39899 4.10952 8.47746C4.14175 8.55593 4.15822 8.63998 4.15797 8.72482V16.0189C4.15809 16.1038 4.14151 16.1878 4.10916 16.2662C4.07681 16.3446 4.02933 16.4159 3.96943 16.476C3.90953 16.5361 3.83839 16.5837 3.76006 16.6163C3.68173 16.6489 3.59775 16.6657 3.51292 16.6659C3.42808 16.6657 3.3441 16.6489 3.26578 16.6163C3.18745 16.5837 3.1163 16.5361 3.0564 16.476C2.99651 16.4159 2.94903 16.3446 2.91668 16.2662C2.88433 16.1878 2.86774 16.1038 2.86787 16.0189V8.72482Z",fill:"currentColor"})),d("defs",null,d("clipPath",{id:"clip0_35_1563"},d("rect",{width:"19",height:"19",fill:"currentColor"})))),Se=()=>d("div",{className:"contribution missing-full-name"},d(jt,{title:"For at deltage i debatten, skal du være registreret med dit fulde navn",link:{label:"Gå til Selvbetjening",href:Wt.value.selfServiceUrl}},d("p",{className:"contribution-overlay__description contribution-overlay__description--light"},"Når du har udfyldt dit navn i Selvbetjening, skal du genindlæse denne side eller klikke herunder"),d("a",{href:window.location.href,type:"button",className:"contribution-form__submit contribution-overlay__button contribution-overlay__button--neutral contribution-overlay__button--with-icon",rel:"noreferrer"},"Jeg har udfyldt mit navn ",d(Le,null)))),xe=()=>{const[t,e]=W(""),[n,i]=W(!1);z((()=>{""!==t&&document.querySelector(`[data-uuid="${t}"]`)?.scrollIntoView({behavior:"smooth"})}),[t]);const r=Ft.value.length>0?"Tilføj indlæg i debatten":void 0,o=!n&&!Vt()&&Et.value.isLoggedIn,l=n&&!Vt()&&Et.value.isLoggedIn&&re(),u=n&&!Vt()&&!re();return d(h,null,d(Mt,null),d(Ne,{onClickShowContributionFormButton:async()=>{Et.value=await be(),i(!0)},showContributionFormButton:o}),u&&d(ie,{onSubmit:t=>zt(t).then((t=>{if(At(t.contributions[0]),!Et.value.uuid){const e=t.users.at(0);e&&(Et.value={...Et.value,uuid:e.uuid})}return Ut.value.isAllLoaded?(Ot(t),Ut.value.contributionsCount+=1,!0):oe(Ut.value.debateUuid,1,1e4).then((n=>(ot((()=>{Ut.value.contributionsCount+=1,Ut.value.isAllLoaded=!0,Ft.value=Bt(n),e(t.contributions[0].uuid)})),!0)))})),title:r}),Vt()&&d($t,null),l&&d(Se,null))},Ue=async()=>{const t=document.querySelector("[data-debate]");if(!t)return;const e=new IntersectionObserver(((e,r)=>{e.forEach((e=>{e.isIntersecting&&((async t=>{Wt.value=t.dataset;const e=await Gt("GET",Wt.value.getDebateUrl).then((t=>{if(!t.ok)throw console.error("couldn't fetch debate."),new Error;return t.json()}));var r,o,l,a,s,_;e.closed&&0===e.contributionsCount||""===e.guidelineUrl||(ot((()=>{Ut.value={...Ut.value,...e},Et.value={...Et.value,isLoggedIn:e.isLoggedIn,uuid:e.uuid}})),r=d(xe,null),o=t,i.__&&i.__(r,o),s=(a="function"==typeof l)?null:l&&l.__k||o.__k,_=[],x(o,r=(!a&&l||o).__k=d(h,null,[r]),s||u,u,void 0!==o.ownerSVGElement,!a&&l?[l]:s?null:o.firstChild?n.call(o.childNodes):null,_,!a&&l?l:s?s.__e:o.firstChild,a),U(_,r))})(t),r.disconnect())}
1))}));e.observe(t)};return e})()));

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.