PageSourceSearch

https://www.geonames.org/main-N3KJLTUN.js

js geonames.org collected 2026-10-01 07:10:11 UTC 895,957 bytes, 112 lines download raw bytes

1import{a as U,b as oe,c as is,e as wt}from"./chunk-6MDQTQU3.js";function Mu(e,n){return Object.is(e,n)}var ot=null,os=!1,Pu=1,rn=Symbol("SIGNAL");function fe(e){let n=ot;return ot=e,n}function Du(){return ot}var Ir={version:0,lastCleanEpoch:0,dirty:!1,producerNode:void 0,producerLastReadVersion:void 0,producerIndexOfThis:void 0,nextProducerIndex:0,liveConsumerNode:void 0,liveConsumerIndexOfThis:void 0,consumerAllowSignalWrites:!1,consumerIsAlwaysLive:!1,kind:"unknown",producerMustRecompute:()=>!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{}};function Tr(e){if(os)throw new Error("");if(ot===null)return;ot.consumerOnSignalRead(e);let n=ot.nextProducerIndex++;if(ls(ot),n<ot.producerNode.length&&ot.producerNode[n]!==e&&Dr(ot)){let t=ot.producerNode[n];ss(t,ot.producerIndexOfThis[n])}ot.producerNode[n]!==e&&(ot.producerNode[n]=e,ot.producerIndexOfThis[n]=Dr(ot)?Kh(e,ot,n):0),ot.producerLastReadVersion[n]=e.version}function Jh(){Pu++}function Iu(e){if(!(Dr(e)&&!e.dirty)&&!(!e.dirty&&e.lastCleanEpoch===Pu)){if(!e.producerMustRecompute(e)&&!ku(e)){Eu(e);return}e.producerRecomputeValue(e),Eu(e)}}function Tu(e){if(e.liveConsumerNode===void 0)return;let n=os;os=!0;try{for(let t of e.liveConsumerNode)t.dirty||b1(t)}finally{os=n}}function Ou(){return ot?.consumerAllowSignalWrites!==!1}function b1(e){e.dirty=!0,Tu(e),e.consumerMarkedDirty?.(e)}function Eu(e){e.dirty=!1,e.lastCleanEpoch=Pu}function as(e){return e&&(e.nextProducerIndex=0),fe(e)}function Nu(e,n){if(fe(n),!(!e||e.producerNode===void 0||e.producerIndexOfThis===void 0||e.producerLastReadVersion===void 0)){if(Dr(e))for(let t=e.nextProducerIndex;t<e.producerNode.length;t++)ss(e.producerNode[t],e.producerIndexOfThis[t]);for(;e.producerNode.length>e.nextProducerIndex;)e.producerNode.pop(),e.producerLastReadVersion.pop(),e.producerIndexOfThis.pop()}}function ku(e){ls(e);for(let n=0;n<e.producerNode.length;n++){let t=e.producerNode[n],i=e.producerLastReadVersion[n];if(i!==t.version||(Iu(t),i!==t.version))return!0}return!1}function Au(e){if(ls(e),Dr(e))for(let n=0;n<e.producerNode.length;n++)ss(e.producerNode[n],e.producerIndexOfThis[n]);e.producerNode.length=e.producerLastReadVersion.length=e.producerIndexOfThis.length=0,e.liveConsumerNode&&(e.liveConsumerNode.length=e.liveConsumerIndexOfThis.length=0)}function Kh(e,n,t){if(Yh(e),e.liveConsumerNode.length===0&&Zh(e))for(let i=0;i<e.producerNode.length;i++)e.producerIndexOfThis[i]=Kh(e.producerNode[i],e,i);return e.liveConsumerIndexOfThis.push(t),e.liveConsumerNode.push(n)-1}function ss(e,n){if(Yh(e),e.liveConsumerNode.length===1&&Zh(e))for(let i=0;i<e.producerNode.length;i++)ss(e.producerNode[i],e.producerIndexOfThis[i]);let t=e.liveConsumerNode.length-1;if(e.liveConsumerNode[n]=e.liveConsumerNode[t],e.liveConsumerIndexOfThis[n]=e.liveConsumerIndexOfThis[t],e.liveConsumerNode.length--,e.liveConsumerIndexOfThis.length--,n<e.liveConsumerNode.length){let i=e.liveConsumerIndexOfThis[n],o=e.liveConsumerNode[n];ls(o),o.producerIndexOfThis[i]=n}}function Dr(e){return e.consumerIsAlwaysLive||(e?.liveConsumerNode?.length??0)>0}function ls(e){e.producerNode??=[],e.producerIndexOfThis??=[],e.producerLastReadVersion??=[]}function Yh(e){e.liveConsumerNode??=[],e.liveConsumerIndexOfThis??=[]}function Zh(e){return e.producerNode!==void 0}function Ru(e,n){let t=Object.create(x1);t.computation=e,n!==void 0&&(t.equal=n);let i=()=>{if(Iu(t),Tr(t),t.value===rs)throw t.error;return t.value};return i[rn]=t,i}var Su=Symbol("UNSET"),wu=Symbol("COMPUTING"),rs=Symbol("ERRORED"),x1=oe(U({},Ir),{value:Su,dirty:!0,error:null,equal:Mu,kind:"computed",producerMustRecompute(e){return e.value===Su||e.value===wu},producerRecomputeValue(e){if(e.value===wu)throw new Error("Detected cycle in computations.");let n=e.value;e.value=wu;let t=as(e),i,o=!1;try{i=e.computation(),fe(null),o=n!==Su&&n!==rs&&i!==rs&&e.equal(n,i)}catch(r){i=rs,e.error=r}finally{Nu(e,t)}if(o){e.value=n;return}e.value=i,e.version++}});function S1(){throw new Error}var Qh=S1;function Xh(e){Qh(e)}function Fu(e){Qh=e}var w1=null;function Lu(e,n){let t=Object.create(cs);t.value=e,n!==void 0&&(t.equal=n);let i=()=>(Tr(t),t.value);return i[rn]=t,i}function Or(e,n){Ou()||Xh(e),e.equal(e.value,n)||(e.value=n,E1(e))}function Vu(e,n){Ou()||Xh(e),Or(e,n(e.value))}var cs=oe(U({},Ir),{equal:Mu,value:void 0,kind:"signal"});function E1(e){e.version++,Jh(),Tu(e),w1?.()}function Uu(e){let n=fe(null);try{return e()}finally{fe(n)}}var ju;function Nr(){return ju}function Yn(e){let n=ju;return ju=e,n}var ds=Symbol("NotFound");function se(e){return typeof e=="function"}function yo(e){let t=e(i=>{Error.call(i),i.stack=new Error().stack});return t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t}var us=yo(e=>function(t){e(this),this.message=t?`${t.length} errors occurred during unsubscription:
2${t.map((i,o)=>`${o+1}) ${i.toString()}`).join(`
3  `)}`:"",this.name="UnsubscriptionError",this.errors=t});function kr(e,n){if(e){let t=e.indexOf(n);0<=t&&e.splice(t,1)}}var Qe=class e{constructor(n){this.initialTeardown=n,this.closed=!1,this._parentage=null,this._finalizers=null}
vendor: 10,585 bytes, line 3
3unsubscribe(){let n;if(!this.closed){this.closed=!0;let{_parentage:t}=this;if(t)if(this._parentage=null,Array.isArray(t))for(let r of t)r.remove(this);else t.remove(this);let{initialTeardown:i}=this;if(se(i))try{i()}catch(r){n=r instanceof us?r.errors:[r]}let{_finalizers:o}=this;if(o){this._finalizers=null;for(let r of o)try{eg(r)}catch(c){n=n??[],c instanceof us?n=[...n,...c.errors]:n.push(c)}}if(n)throw new us(n)}}add(n){var t;if(n&&n!==this)if(this.closed)eg(n);else{if(n instanceof e){if(n.closed||n._hasParent(this))return;n._addParent(this)}(this._finalizers=(t=this._finalizers)!==null&&t!==void 0?t:[]).push(n)}}_hasParent(n){let{_parentage:t}=this;return t===n||Array.isArray(t)&&t.includes(n)}_addParent(n){let{_parentage:t}=this;this._parentage=Array.isArray(t)?(t.push(n),t):t?[t,n]:n}_removeParent(n){let{_parentage:t}=this;t===n?this._parentage=null:Array.isArray(t)&&kr(t,n)}remove(n){let{_finalizers:t}=this;t&&kr(t,n),n instanceof e&&n._removeParent(this)}};Qe.EMPTY=(()=>{let e=new Qe;return e.closed=!0,e})();var Bu=Qe.EMPTY;function ms(e){return e instanceof Qe||e&&"closed"in e&&se(e.remove)&&se(e.add)&&se(e.unsubscribe)}function eg(e){se(e)?e():e.unsubscribe()}var fn={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1};var bo={setTimeout(e,n,...t){let{delegate:i}=bo;return i?.setTimeout?i.setTimeout(e,n,...t):setTimeout(e,n,...t)},clearTimeout(e){let{delegate:n}=bo;return(n?.clearTimeout||clearTimeout)(e)},delegate:void 0};function ps(e){bo.setTimeout(()=>{let{onUnhandledError:n}=fn;if(n)n(e);else throw e})}function Ar(){}var tg=Hu("C",void 0,void 0);function ng(e){return Hu("E",void 0,e)}function ig(e){return Hu("N",e,void 0)}function Hu(e,n,t){return{kind:e,value:n,error:t}}var Li=null;function xo(e){if(fn.useDeprecatedSynchronousErrorHandling){let n=!Li;if(n&&(Li={errorThrown:!1,error:null}),e(),n){let{errorThrown:t,error:i}=Li;if(Li=null,t)throw i}}else e()}function og(e){fn.useDeprecatedSynchronousErrorHandling&&Li&&(Li.errorThrown=!0,Li.error=e)}var Vi=class extends Qe{constructor(n){super(),this.isStopped=!1,n?(this.destination=n,ms(n)&&n.add(this)):this.destination=O1}static create(n,t,i){return new hn(n,t,i)}next(n){this.isStopped?zu(ig(n),this):this._next(n)}error(n){this.isStopped?zu(ng(n),this):(this.isStopped=!0,this._error(n))}complete(){this.isStopped?zu(tg,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(n){this.destination.next(n)}_error(n){try{this.destination.error(n)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}},I1=Function.prototype.bind;function $u(e,n){return I1.call(e,n)}var Gu=class{constructor(n){this.partialObserver=n}next(n){let{partialObserver:t}=this;if(t.next)try{t.next(n)}catch(i){fs(i)}}error(n){let{partialObserver:t}=this;if(t.error)try{t.error(n)}catch(i){fs(i)}else fs(n)}complete(){let{partialObserver:n}=this;if(n.complete)try{n.complete()}catch(t){fs(t)}}},hn=class extends Vi{constructor(n,t,i){super();let o;if(se(n)||!n)o={next:n??void 0,error:t??void 0,complete:i??void 0};else{let r;this&&fn.useDeprecatedNextContext?(r=Object.create(n),r.unsubscribe=()=>this.unsubscribe(),o={next:n.next&&$u(n.next,r),error:n.error&&$u(n.error,r),complete:n.complete&&$u(n.complete,r)}):o=n}this.destination=new Gu(o)}};function fs(e){fn.useDeprecatedSynchronousErrorHandling?og(e):ps(e)}function T1(e){throw e}function zu(e,n){let{onStoppedNotification:t}=fn;t&&bo.setTimeout(()=>t(e,n))}var O1={closed:!0,next:Ar,error:T1,complete:Ar};var So=typeof Symbol=="function"&&Symbol.observable||"@@observable";function Et(e){return e}function Wu(...e){return qu(e)}function qu(e){return e.length===0?Et:e.length===1?e[0]:function(t){return e.reduce((i,o)=>o(i),t)}}var ye=(()=>{class e{constructor(t){t&&(this._subscribe=t)}lift(t){let i=new e;return i.source=this,i.operator=t,i}subscribe(t,i,o){let r=k1(t)?t:new hn(t,i,o);return xo(()=>{let{operator:c,source:u}=this;r.add(c?c.call(r,u):u?this._subscribe(r):this._trySubscribe(r))}),r}_trySubscribe(t){try{return this._subscribe(t)}catch(i){t.error(i)}}forEach(t,i){return i=rg(i),new i((o,r)=>{let c=new hn({next:u=>{try{t(u)}catch(m){r(m),c.unsubscribe()}},error:r,complete:o});this.subscribe(c)})}_subscribe(t){var i;return(i=this.source)===null||i===void 0?void 0:i.subscribe(t)}[So](){return this}pipe(...t){return qu(t)(this)}toPromise(t){return t=rg(t),new t((i,o)=>{let r;this.subscribe(c=>r=c,c=>o(c),()=>i(r))})}}return e.create=n=>new e(n),e})();function rg(e){var n;return(n=e??fn.Promise)!==null&&n!==void 0?n:Promise}function N1(e){return e&&se(e.next)&&se(e.error)&&se(e.complete)}function k1(e){return e&&e instanceof Vi||N1(e)&&ms(e)}function Ju(e){return se(e?.lift)}function ge(e){return n=>{if(Ju(n))return n.lift(function(t){try{return e(t,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}function Ce(e,n,t,i,o){return new Ku(e,n,t,i,o)}var Ku=class extends Vi{constructor(n,t,i,o,r,c){super(n),this.onFinalize=r,this.shouldUnsubscribe=c,this._next=t?function(u){try{t(u)}catch(m){n.error(m)}}:super._next,this._error=o?function(u){try{o(u)}catch(m){n.error(m)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(u){n.error(u)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var n;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){let{closed:t}=this;super.unsubscribe(),!t&&((n=this.onFinalize)===null||n===void 0||n.call(this))}}};function wo(){return ge((e,n)=>{let t=null;e._refCount++;let i=Ce(n,void 0,void 0,void 0,()=>{if(!e||e._refCount<=0||0<--e._refCount){t=null;return}let o=e._connection,r=t;t=null,o&&(!r||o===r)&&o.unsubscribe(),n.unsubscribe()});e.subscribe(i),i.closed||(t=e.connect())})}var Eo=class extends ye{constructor(n,t){super(),this.source=n,this.subjectFactory=t,this._subject=null,this._refCount=0,this._connection=null,Ju(n)&&(this.lift=n.lift)}_subscribe(n){return this.getSubject().subscribe(n)}getSubject(){let n=this._subject;return(!n||n.isStopped)&&(this._subject=this.subjectFactory()),this._subject}_teardown(){this._refCount=0;let{_connection:n}=this;this._subject=this._connection=null,n?.unsubscribe()}connect(){let n=this._connection;if(!n){n=this._connection=new Qe;let t=this.getSubject();n.add(this.source.subscribe(Ce(t,void 0,()=>{this._teardown(),t.complete()},i=>{this._teardown(),t.error(i)},()=>this._teardown()))),n.closed&&(this._connection=null,n=Qe.EMPTY)}return n}refCount(){return wo()(this)}};var ag=yo(e=>function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});var Ue=(()=>{class e extends ye{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(t){let i=new hs(this,this);return i.operator=t,i}_throwIfClosed(){if(this.closed)throw new ag}next(t){xo(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(let i of this.currentObservers)i.next(t)}})}error(t){xo(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=t;let{observers:i}=this;for(;i.length;)i.shift().error(t)}})}complete(){xo(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;let{observers:t}=this;for(;t.length;)t.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var t;return((t=this.observers)===null||t===void 0?void 0:t.length)>0}_trySubscribe(t){return this._throwIfClosed(),super._trySubscribe(t)}_subscribe(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)}_innerSubscribe(t){let{hasError:i,isStopped:o,observers:r}=this;return i||o?Bu:(this.currentObservers=null,r.push(t),new Qe(()=>{this.currentObservers=null,kr(r,t)}))}_checkFinalizedStatuses(t){let{hasError:i,thrownError:o,isStopped:r}=this;i?t.error(o):r&&t.complete()}asObservable(){let t=new ye;return t.source=this,t}}return e.create=(n,t)=>new hs(n,t),e})(),hs=class extends Ue{constructor(n,t){super(),this.destination=n,this.source=t}next(n){var t,i;(i=(t=this.destination)===null||t===void 0?void 0:t.next)===null||i===void 0||i.call(t,n)}error(n){var t,i;(i=(t=this.destination)===null||t===void 0?void 0:t.error)===null||i===void 0||i.call(t,n)}complete(){var n,t;(t=(n=this.destination)===null||n===void 0?void 0:n.complete)===null||t===void 0||t.call(n)}_subscribe(n){var t,i;return(i=(t=this.source)===null||t===void 0?void 0:t.subscribe(n))!==null&&i!==void 0?i:Bu}};var ft=class extends Ue{constructor(n){super(),this._value=n}get value(){return this.getValue()}_subscribe(n){let t=super._subscribe(n);return!t.closed&&n.next(this._value),t}getValue(){let{hasError:n,thrownError:t,_value:i}=this;if(n)throw t;return this._throwIfClosed(),i}next(n){super.next(this._value=n)}};var Yu={now(){return(Yu.delegate||Date).now()},delegate:void 0};var gs=class extends Ue{constructor(n=1/0,t=1/0,i=Yu){super(),this._bufferSize=n,this._windowTime=t,this._timestampProvider=i,this._buffer=[],this._infiniteTimeWindow=!0,this._infiniteTimeWindow=t===1/0,this._bufferSize=Math.max(1,n),this._windowTime=Math.max(1,t)}next(n){let{isStopped:t,_buffer:i,_infiniteTimeWindow:o,_timestampProvider:r,_windowTime:c}=this;t||(i.push(n),!o&&i.push(r.now()+c)),this._trimBuffer(),super.next(n)}_subscribe(n){this._throwIfClosed(),this._trimBuffer();let t=this._innerSubscribe(n),{_infiniteTimeWindow:i,_buffer:o}=this,r=o.slice();for(let c=0;c<r.length&&!n.closed;c+=i?1:2)n.next(r[c]);return this._checkFinalizedStatuses(n),t}_trimBuffer(){let{_bufferSize:n,_timestampProvider:t,_buffer:i,_infiniteTimeWindow:o}=this,r=(o?1:2)*n;if(n<1/0&&r<i.length&&i.splice(0,i.length-r),!o){let c=t.now(),u=0;for(let m=1;m<i.length&&i[m]<=c;m+=2)u=m;u&&i.splice(0,u+1)}}};var Tt=new ye(e=>e.complete());function sg(e){return e&&se(e.schedule)}function lg(e){return e[e.length-1]}function Cs(e){return se(lg(e))?e.pop():void 0}function gi(e){return sg(lg(e))?e.pop():void 0}function dg(e,n,t,i){function o(r){return r instanceof t?r:new t(function(c){c(r)})}return new(t||(t=Promise))(function(r,c){function u(C){try{f(i.next(C))}catch(b){c(b)}}function m(C){try{f(i.throw(C))}catch(b){c(b)}}function f(C){C.done?r(C.value):o(C.value).then(u,m)}f((i=i.apply(e,n||[])).next())})}function cg(e){var n=typeof Symbol=="function"&&Symbol.iterator,t=n&&e[n],i=0;if(t)return t.call(e);
vendor: 4,609 bytes, line 3
3if(e&&typeof e.length=="number")return{next:function(){return e&&i>=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")}function Ui(e){return this instanceof Ui?(this.v=e,this):new Ui(e)}function ug(e,n,t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var i=t.apply(e,n||[]),o,r=[];return o=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),u("next"),u("throw"),u("return",c),o[Symbol.asyncIterator]=function(){return this},o;function c(x){return function(D){return Promise.resolve(D).then(x,b)}}function u(x,D){i[x]&&(o[x]=function(V){return new Promise(function(q,te){r.push([x,V,q,te])>1||m(x,V)})},D&&(o[x]=D(o[x])))}function m(x,D){try{f(i[x](D))}catch(V){P(r[0][3],V)}}function f(x){x.value instanceof Ui?Promise.resolve(x.value.v).then(C,b):P(r[0][2],x)}function C(x){m("next",x)}function b(x){m("throw",x)}function P(x,D){x(D),r.shift(),r.length&&m(r[0][0],r[0][1])}}function mg(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=e[Symbol.asyncIterator],t;return n?n.call(e):(e=typeof cg=="function"?cg(e):e[Symbol.iterator](),t={},i("next"),i("throw"),i("return"),t[Symbol.asyncIterator]=function(){return this},t);function i(r){t[r]=e[r]&&function(c){return new Promise(function(u,m){c=e[r](c),o(u,m,c.done,c.value)})}}function o(r,c,u,m){Promise.resolve(m).then(function(f){r({value:f,done:u})},c)}}var _s=e=>e&&typeof e.length=="number"&&typeof e!="function";function vs(e){return se(e?.then)}function ys(e){return se(e[So])}function bs(e){return Symbol.asyncIterator&&se(e?.[Symbol.asyncIterator])}function xs(e){return new TypeError(`You provided ${e!==null&&typeof e=="object"?"an invalid object":`'${e}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}function A1(){return typeof Symbol!="function"||!Symbol.iterator?"@@iterator":Symbol.iterator}var Ss=A1();function ws(e){return se(e?.[Ss])}function Es(e){return ug(this,arguments,function*(){let t=e.getReader();try{for(;;){let{value:i,done:o}=yield Ui(t.read());if(o)return yield Ui(void 0);yield yield Ui(i)}}finally{t.releaseLock()}})}function Ms(e){return se(e?.getReader)}function Je(e){if(e instanceof ye)return e;if(e!=null){if(ys(e))return R1(e);if(_s(e))return F1(e);if(vs(e))return L1(e);if(bs(e))return pg(e);if(ws(e))return V1(e);if(Ms(e))return U1(e)}throw xs(e)}function R1(e){return new ye(n=>{let t=e[So]();if(se(t.subscribe))return t.subscribe(n);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}function F1(e){return new ye(n=>{for(let t=0;t<e.length&&!n.closed;t++)n.next(e[t]);n.complete()})}function L1(e){return new ye(n=>{e.then(t=>{n.closed||(n.next(t),n.complete())},t=>n.error(t)).then(null,ps)})}function V1(e){return new ye(n=>{for(let t of e)if(n.next(t),n.closed)return;n.complete()})}function pg(e){return new ye(n=>{j1(e,n).catch(t=>n.error(t))})}function U1(e){return pg(Es(e))}function j1(e,n){var t,i,o,r;return dg(this,void 0,void 0,function*(){try{for(t=mg(e);i=yield t.next(),!i.done;){let c=i.value;if(n.next(c),n.closed)return}}catch(c){o={error:c}}finally{try{i&&!i.done&&(r=t.return)&&(yield r.call(t))}finally{if(o)throw o.error}}n.complete()})}function Ot(e,n,t,i=0,o=!1){let r=n.schedule(function(){t(),o?e.add(this.schedule(null,i)):this.unsubscribe()},i);if(e.add(r),!o)return r}function Ps(e,n=0){return ge((t,i)=>{t.subscribe(Ce(i,o=>Ot(i,e,()=>i.next(o),n),()=>Ot(i,e,()=>i.complete(),n),o=>Ot(i,e,()=>i.error(o),n)))})}function Ds(e,n=0){return ge((t,i)=>{i.add(e.schedule(()=>t.subscribe(i),n))})}function fg(e,n){return Je(e).pipe(Ds(n),Ps(n))}function hg(e,n){return Je(e).pipe(Ds(n),Ps(n))}function gg(e,n){return new ye(t=>{let i=0;return n.schedule(function(){i===e.length?t.complete():(t.next(e[i++]),t.closed||this.schedule())})})}function Cg(e,n){return new ye(t=>{let i;return Ot(t,n,()=>{i=e[Ss](),Ot(t,n,()=>{let o,r;try{({value:o,done:r}=i.next())}catch(c){t.error(c);return}r?t.complete():t.next(o)},0,!0)}),()=>se(i?.return)&&i.return()})}function Is(e,n){if(!e)throw new Error("Iterable cannot be null");return new ye(t=>{Ot(t,n,()=>{let i=e[Symbol.asyncIterator]();Ot(t,n,()=>{i.next().then(o=>{o.done?t.complete():t.next(o.value)})},0,!0)})})}function _g(e,n){return Is(Es(e),n)}function vg(e,n){if(e!=null){if(ys(e))return fg(e,n);if(_s(e))return gg(e,n);if(vs(e))return hg(e,n);if(bs(e))return Is(e,n);if(ws(e))return Cg(e,n);if(Ms(e))return _g(e,n)}throw xs(e)}
vendor: 4,524 bytes, line 3
3function ze(e,n){return n?vg(e,n):Je(e)}function Q(...e){let n=gi(e);return ze(e,n)}function zt(e,n){let t=se(e)?e:()=>e,i=o=>o.error(t());return new ye(n?o=>n.schedule(i,0,o):i)}function Zu(e){return!!e&&(e instanceof ye||se(e.lift)&&se(e.subscribe))}var gn=yo(e=>function(){e(this),this.name="EmptyError",this.message="no elements in sequence"});function vt(e,n){let t=typeof n=="object";return new Promise((i,o)=>{let r=new hn({next:c=>{i(c),r.unsubscribe()},error:o,complete:()=>{t?i(n.defaultValue):o(new gn)}});e.subscribe(r)})}function N(e,n){return ge((t,i)=>{let o=0;t.subscribe(Ce(i,r=>{i.next(e.call(n,r,o++))}))})}var{isArray:B1}=Array;function H1(e,n){return B1(n)?e(...n):e(n)}function Ts(e){return N(n=>H1(e,n))}var{isArray:$1}=Array,{getPrototypeOf:z1,prototype:G1,keys:W1}=Object;function Os(e){if(e.length===1){let n=e[0];if($1(n))return{args:n,keys:null};if(q1(n)){let t=W1(n);return{args:t.map(i=>n[i]),keys:t}}}return{args:e,keys:null}}function q1(e){return e&&typeof e=="object"&&z1(e)===G1}function Ns(e,n){return e.reduce((t,i,o)=>(t[i]=n[o],t),{})}function Ci(...e){let n=gi(e),t=Cs(e),{args:i,keys:o}=Os(e);if(i.length===0)return ze([],n);let r=new ye(J1(i,n,o?c=>Ns(o,c):Et));return t?r.pipe(Ts(t)):r}function J1(e,n,t=Et){return i=>{yg(n,()=>{let{length:o}=e,r=new Array(o),c=o,u=o;for(let m=0;m<o;m++)yg(n,()=>{let f=ze(e[m],n),C=!1;f.subscribe(Ce(i,b=>{r[m]=b,C||(C=!0,u--),u||i.next(t(r.slice()))},()=>{--c||i.complete()}))},i)},i)}}function yg(e,n,t){e?Ot(t,e,n):n()}function bg(e,n,t,i,o,r,c,u){let m=[],f=0,C=0,b=!1,P=()=>{b&&!m.length&&!f&&n.complete()},x=V=>f<i?D(V):m.push(V),D=V=>{r&&n.next(V),f++;let q=!1;Je(t(V,C++)).subscribe(Ce(n,te=>{o?.(te),r?x(te):n.next(te)},()=>{q=!0},void 0,()=>{if(q)try{for(f--;m.length&&f<i;){let te=m.shift();c?Ot(n,c,()=>D(te)):D(te)}P()}catch(te){n.error(te)}}))};return e.subscribe(Ce(n,x,()=>{b=!0,P()})),()=>{u?.()}}function rt(e,n,t=1/0){return se(n)?rt((i,o)=>N((r,c)=>n(i,r,o,c))(Je(e(i,o))),t):(typeof n=="number"&&(t=n),ge((i,o)=>bg(i,o,e,t)))}function xg(e=1/0){return rt(Et,e)}function Sg(){return xg(1)}function Mo(...e){return Sg()(ze(e,gi(e)))}function ks(e){return new ye(n=>{Je(e()).subscribe(n)})}function Rr(...e){let n=Cs(e),{args:t,keys:i}=Os(e),o=new ye(r=>{let{length:c}=t;if(!c){r.complete();return}let u=new Array(c),m=c,f=c;for(let C=0;C<c;C++){let b=!1;Je(t[C]).subscribe(Ce(r,P=>{b||(b=!0,f--),u[C]=P},()=>m--,void 0,()=>{(!m||!b)&&(f||r.next(i?Ns(i,u):u),r.complete())}))}});return n?o.pipe(Ts(n)):o}function Gt(e,n){return ge((t,i)=>{let o=0;t.subscribe(Ce(i,r=>e.call(n,r,o++)&&i.next(r)))})}function Ze(e){return ge((n,t)=>{let i=null,o=!1,r;i=n.subscribe(Ce(t,void 0,void 0,c=>{r=Je(e(c,Ze(e)(n))),i?(i.unsubscribe(),i=null,r.subscribe(t)):o=!0})),o&&(i.unsubscribe(),i=null,r.subscribe(t))})}function wg(e,n,t,i,o){return(r,c)=>{let u=t,m=n,f=0;r.subscribe(Ce(c,C=>{let b=f++;m=u?e(m,C,b):(u=!0,C),i&&c.next(m)},o&&(()=>{u&&c.next(m),c.complete()})))}}function _i(e,n){return se(n)?rt(e,n,1):rt(e,1)}function vi(e){return ge((n,t)=>{let i=!1;n.subscribe(Ce(t,o=>{i=!0,t.next(o)},()=>{i||t.next(e),t.complete()}))})}function Zn(e){return e<=0?()=>Tt:ge((n,t)=>{let i=0;n.subscribe(Ce(t,o=>{++i<=e&&(t.next(o),e<=i&&t.complete())}))})}function Qu(e,n=Et){return e=e??K1,ge((t,i)=>{let o,r=!0;t.subscribe(Ce(i,c=>{let u=n(c);(r||!e(o,u))&&(r=!1,o=u,i.next(c))}))})}function K1(e,n){return e===n}function As(e=Y1){return ge((n,t)=>{let i=!1;n.subscribe(Ce(t,o=>{i=!0,t.next(o)},()=>i?t.complete():t.error(e())))})}function Y1(){return new gn}function ji(e){return ge((n,t)=>{try{n.subscribe(t)}finally{t.add(e)}})}function Qn(e,n){let t=arguments.length>=2;return i=>i.pipe(e?Gt((o,r)=>e(o,r,i)):Et,Zn(1),t?vi(n):As(()=>new gn))}function Po(e){return e<=0?()=>Tt:ge((n,t)=>{let i=[];n.subscribe(Ce(t,o=>{i.push(o),e<i.length&&i.shift()},()=>{for(let o of i)t.next(o);t.complete()},void 0,()=>{i=null}))})}function Xu(e,n){let t=arguments.length>=2;return i=>i.pipe(e?Gt((o,r)=>e(o,r,i)):Et,Po(1),t?vi(n):As(()=>new gn))}function em(e,n){return ge(wg(e,n,arguments.length>=2,!0))}function Eg(e={}){let{connector:n=()=>new Ue,resetOnError:t=!0,resetOnComplete:i=!0,resetOnRefCountZero:o=!0}=e;return r=>{let c,u,m,f=0,C=!1,b=!1,P=()=>{u?.unsubscribe(),u=void 0},x=()=>{P(),c=m=void 0,C=b=!1},D=()=>{let V=c;x(),V?.unsubscribe()};return ge((V,q)=>{f++,!b&&!C&&P();let te=m=m??n();q.add(()=>{f--,f===0&&!b&&!C&&(u=tm(D,o))}),te.subscribe(q),!c&&f>0&&(c=new hn({next:Ie=>te.next(Ie),error:Ie=>{b=!0,P(),u=tm(x,t,Ie),te.error(Ie)}
3,complete:()=>{C=!0,P(),u=tm(x,i),te.complete()}}),Je(V).subscribe(c))})(r)}}function tm(e,n,...t){if(n===!0){e();return}if(n===!1)return;let i=new hn({next:()=>{i.unsubscribe(),e()}});return Je(n(...t)).subscribe(i)}function Xn(e,n,t){let i,o=!1;return e&&typeof e=="object"?{bufferSize:i=1/0,windowTime:n=1/0,refCount:o=!1,scheduler:t}=e:i=e??1/0,Eg({connector:()=>new gs(i,n,t),resetOnError:!0,resetOnComplete:!1,resetOnRefCountZero:o})}function nm(...e){let n=gi(e);return ge((t,i)=>{(n?Mo(e,t,n):Mo(e,t)).subscribe(i)})}function be(e,n){return ge((t,i)=>{let o=null,r=0,c=!1,u=()=>c&&!o&&i.complete();t.subscribe(Ce(i,m=>{o?.unsubscribe();let f=0,C=r++;Je(e(m,C)).subscribe(o=Ce(i,b=>i.next(n?n(m,b,C,f++):b),()=>{o=null,u()}))},()=>{c=!0,u()}))})}function im(e){return ge((n,t)=>{Je(e).subscribe(Ce(t,()=>t.complete(),Ar)),!t.closed&&n.subscribe(t)})}function xe(e,n,t){let i=se(e)||n||t?{next:e,error:n,complete:t}:e;return i?ge((o,r)=>{var c;(c=i.subscribe)===null||c===void 0||c.call(i);let u=!0;o.subscribe(Ce(r,m=>{var f;(f=i.next)===null||f===void 0||f.call(i,m),r.next(m)},()=>{var m;u=!1,(m=i.complete)===null||m===void 0||m.call(i),r.complete()},m=>{var f;u=!1,(f=i.error)===null||f===void 0||f.call(i,m),r.error(m)},()=>{var m,f;u&&((m=i.unsubscribe)===null||m===void 0||m.call(i)),(f=i.finalize)===null||f===void 0||f.call(i)}))}):Et}var lm={JSACTION:"jsaction"},cm={JSACTION:"__jsaction",OWNER:"__owner"},Ig={};function Z1(e){return e[cm.JSACTION]}function Mg(e,n){e[cm.JSACTION]=n}function Q1(e){return Ig[e]}function X1(e,n){Ig[e]=n}var ne={CLICK:"click",CLICKMOD:"clickmod",DBLCLICK:"dblclick",FOCUS:"focus",FOCUSIN:"focusin",BLUR:"blur",FOCUSOUT:"focusout",SUBMIT:"submit",KEYDOWN:"keydown",KEYPRESS:"keypress",KEYUP:"keyup",MOUSEOVER:"mouseover",MOUSEOUT:"mouseout",MOUSEENTER:"mouseenter",MOUSELEAVE:"mouseleave",POINTEROVER:"pointerover",POINTEROUT:"pointerout",POINTERENTER:"pointerenter",POINTERLEAVE:"pointerleave",ERROR:"error",LOAD:"load",TOUCHSTART:"touchstart",TOUCHEND:"touchend",TOUCHMOVE:"touchmove",TOGGLE:"toggle"},ex=[ne.MOUSEENTER,ne.MOUSELEAVE,"pointerenter","pointerleave"],U9=[ne.CLICK,ne.DBLCLICK,ne.FOCUSIN,ne.FOCUSOUT,ne.KEYDOWN,ne.KEYUP,ne.KEYPRESS,ne.MOUSEOVER,ne.MOUSEOUT,ne.SUBMIT,ne.TOUCHSTART,ne.TOUCHEND,ne.TOUCHMOVE,"touchcancel","auxclick","change","compositionstart","compositionupdate","compositionend","beforeinput","input","select","copy","cut","paste","mousedown","mouseup","wheel","contextmenu","dragover","dragenter","dragleave","drop","dragstart","dragend","pointerdown","pointermove","pointerup","pointercancel","pointerover","pointerout","gotpointercapture","lostpointercapture","ended","loadedmetadata","pagehide","pageshow","visibilitychange","beforematch"],tx=[ne.FOCUS,ne.BLUR,ne.ERROR,ne.LOAD,ne.TOGGLE],dm=e=>tx.indexOf(e)>=0;function nx(e){return e===ne.MOUSEENTER?ne.MOUSEOVER:e===ne.MOUSELEAVE?ne.MOUSEOUT:e===ne.POINTERENTER?ne.POINTEROVER:e===ne.POINTERLEAVE?ne.POINTEROUT:e}function ix(e,n,t,i){let o=!1;dm(n)&&(o=!0);let r=typeof i=="boolean"?{capture:o,passive:i}:o;return e.addEventListener(n,t,r),{eventType:n,handler:t,capture:o,passive:i}}function ox(e,n){if(e.removeEventListener){let t=typeof n.passive=="boolean"?{capture:n.capture}:n.capture;e.removeEventListener(n.eventType,n.handler,t)}else e.detachEvent&&e.detachEvent(`on${n.eventType}`,n.handler)}function rx(e){e.preventDefault?e.preventDefault():e.returnValue=!1}var Pg=typeof navigator<"u"&&/Macintosh/.test(navigator.userAgent);function ax(e){return e.which===2||e.which==null&&e.button===4}function sx(e){return Pg&&e.metaKey||!Pg&&e.ctrlKey||ax(e)||e.shiftKey}function lx(e,n,t){let i=e.relatedTarget;return(e.type===ne.MOUSEOVER&&n===ne.MOUSEENTER||e.type===ne.MOUSEOUT&&n===ne.MOUSELEAVE||e.type===ne.POINTEROVER&&n===ne.POINTERENTER||e.type===ne.POINTEROUT&&n===ne.POINTERLEAVE)&&(!i||i!==t&&!t.contains(i))}function cx(e,n){let t={};for(let i in e){if(i==="srcElement"||i==="target")continue;let o=i,r=e[o];typeof r!="function"&&(t[o]=r)}return e.type===ne.MOUSEOVER?t.type=ne.MOUSEENTER:e.type===ne.MOUSEOUT?t.type=ne.MOUSELEAVE:e.type===ne.POINTEROVER?t.type=ne.POINTERENTER:t.type=ne.POINTERLEAVE,t.target=t.srcElement=n,t.bubbles=!1,t._originalEvent=e,t}var dx=typeof navigator<"u"&&/iPhone|iPad|iPod/.test(navigator.userAgent),Vs=class{element;handlerInfos=[];constructor(n){this.element=n}
3addEventListener(n,t,i){dx&&(this.element.style.cursor="pointer"),this.handlerInfos.push(ix(this.element,n,t(this.element),i))}cleanUp(){for(let n=0;n<this.handlerInfos.length;n++)ox(this.element,this.handlerInfos[n]);this.handlerInfos=[]}},ux={EVENT_ACTION_SEPARATOR:":"};function yi(e){return e.eventType}function um(e,n){e.eventType=n}function Fs(e){return e.event}function Tg(e,n){e.event=n}function Og(e){return e.targetElement}function Ng(e,n){e.targetElement=n}function kg(e){return e.eic}function mx(e,n){e.eic=n}function px(e){return e.timeStamp}function fx(e,n){e.timeStamp=n}function Ls(e){return e.eia}function Ag(e,n,t){e.eia=[n,t]}function om(e){e.eia=void 0}function Rs(e){return e[1]}function hx(e){return e.eirp}function Rg(e,n){e.eirp=n}function Fg(e){return e.eir}function Lg(e,n){e.eir=n}function Vg(e){return{eventType:e.eventType,event:e.event,targetElement:e.targetElement,eic:e.eic,eia:e.eia,timeStamp:e.timeStamp,eirp:e.eirp,eiack:e.eiack,eir:e.eir}}function gx(e,n,t,i,o,r,c,u){return{eventType:e,event:n,targetElement:t,eic:i,timeStamp:o,eia:r,eirp:c,eiack:u}}var rm=class e{eventInfo;constructor(n){this.eventInfo=n}getEventType(){return yi(this.eventInfo)}setEventType(n){um(this.eventInfo,n)}getEvent(){return Fs(this.eventInfo)}setEvent(n){Tg(this.eventInfo,n)}getTargetElement(){return Og(this.eventInfo)}setTargetElement(n){Ng(this.eventInfo,n)}getContainer(){return kg(this.eventInfo)}setContainer(n){mx(this.eventInfo,n)}getTimestamp(){return px(this.eventInfo)}setTimestamp(n){fx(this.eventInfo,n)}getAction(){let n=Ls(this.eventInfo);if(n)return{name:n[0],element:n[1]}}setAction(n){if(!n){om(this.eventInfo);return}Ag(this.eventInfo,n.name,n.element)}getIsReplay(){return hx(this.eventInfo)}setIsReplay(n){Rg(this.eventInfo,n)}getResolved(){return Fg(this.eventInfo)}setResolved(n){Lg(this.eventInfo,n)}clone(){return new e(Vg(this.eventInfo))}},Cx={},_x=/\s*;\s*/,vx=ne.CLICK,am=class{a11yClickSupport=!1;clickModSupport=!0;syntheticMouseEventSupport;updateEventInfoForA11yClick=void 0;preventDefaultForA11yClick=void 0;populateClickOnlyAction=void 0;constructor({syntheticMouseEventSupport:n=!1,clickModSupport:t=!0}={}){this.syntheticMouseEventSupport=n,this.clickModSupport=t}resolveEventType(n){this.clickModSupport&&yi(n)===ne.CLICK&&sx(Fs(n))?um(n,ne.CLICKMOD):this.a11yClickSupport&&this.updateEventInfoForA11yClick(n)}resolveAction(n){Fg(n)||(this.populateAction(n,Og(n)),Lg(n,!0))}resolveParentAction(n){let t=Ls(n),i=t&&Rs(t);om(n);let o=i&&this.getParentNode(i);o&&this.populateAction(n,o)}populateAction(n,t){let i=t;for(;i&&i!==kg(n)&&(i.nodeType===Node.ELEMENT_NODE&&this.populateActionOnElement(i,n),!Ls(n));)i=this.getParentNode(i);let o=Ls(n);if(o&&(this.a11yClickSupport&&this.preventDefaultForA11yClick(n),this.syntheticMouseEventSupport&&(yi(n)===ne.MOUSEENTER||yi(n)===ne.MOUSELEAVE||yi(n)===ne.POINTERENTER||yi(n)===ne.POINTERLEAVE)))if(lx(Fs(n),yi(n),Rs(o))){let r=cx(Fs(n),Rs(o));Tg(n,r),Ng(n,Rs(o))}else om(n)}getParentNode(n){let t=n[cm.OWNER];if(t)return t;let i=n.parentNode;return i?.nodeName==="#document-fragment"?i?.host??null:i}populateActionOnElement(n,t){let i=this.parseActions(n),o=i[yi(t)];o!==void 0&&Ag(t,o,n),this.a11yClickSupport&&this.populateClickOnlyAction(n,t,i)}parseActions(n){let t=Z1(n);if(!t){let i=n.getAttribute(lm.JSACTION);if(!i)t=Cx,Mg(n,t);else{if(t=Q1(i),!t){t={};let o=i.split(_x);for(let r=0;r<o.length;r++){let c=o[r];if(!c)continue;let u=c.indexOf(ux.EVENT_ACTION_SEPARATOR),m=u!==-1,f=m?c.substr(0,u).trim():vx,C=m?c.substr(u+1).trim():c;t[f]=C}X1(i,t)}Mg(n,t)}}return t}addA11yClickSupport(n,t,i){this.a11yClickSupport=!0,this.updateEventInfoForA11yClick=n,this.preventDefaultForA11yClick=t,this.populateClickOnlyAction=i}},Ug=(function(e){return e[e.I_AM_THE_JSACTION_FRAMEWORK=0]="I_AM_THE_JSACTION_FRAMEWORK",e})(Ug||{}),sm=class{dispatchDelegate;actionResolver;eventReplayer;eventReplayScheduled=!1;replayEventInfoWrappers=[];constructor(n,{actionResolver:t,eventReplayer:i}={}){this.dispatchDelegate=n,this.actionResolver=t,this.eventReplayer=i}dispatch(n){let t=new rm(n);this.actionResolver?.resolveEventType(n),this.actionResolver?.resolveAction(n);let i=t.getAction();if(i&&yx(i.element,t)&&rx(t.getEvent()),this.eventReplayer&&t.getIsReplay()){this.scheduleEventInfoWrapperReplay(t);return}this.dispatchDelegate(t)}scheduleEventInfoWrapperReplay(n){this.replayEventInfoWrappers.push(n),!this.eventReplayScheduled&&(this.eventReplayScheduled=!0,Promise.resolve().then(()=>{this.eventReplayScheduled=!1,this.eventReplayer(this.replayEventInfoWrappers)}))}};function yx(e,n){return e.tagName==="A"&&(n.getEventType()===ne.CLICK||n.getEventType()===ne.CLICKMOD)}var jg=Symbol.for("propagationStopped"),mm={REPLAY:101};var bx="`preventDefault` called during event replay.";var xx="`composedPath` called during event replay.",Us=class{dispatchDelegate;clickModSupport;actionResolver;dispatcher;constructor(n,t=!0){this.dispatchDelegate=n,this.clickModSupport=t,this.actionResolver=new am({clickModSupport:t}),this.dispatcher=new sm(i=>{this.dispatchToDelegate(i)},{actionResolver:this.actionResolver})}dispatch(n){this.dispatcher.dispatch(n)}dispatchToDelegate(n){for(n.getIsReplay()&&Ex(n),Sx(n);n.getAction();){if(Mx(n),dm(n.getEventType())&&n.getAction().element!==n.getTargetElement()||(this.dispatchDelegate(n.getEvent(),n.getAction().name),wx(n)))return;this.actionResolver.resolveParentAction(n.eventInfo)}}};function Sx(e){let n=e.getEvent(),t=e.getEvent().stopPropagation.bind(n),i=()=>{n[jg]=!0,t()};Bi(n,"stopPropagation",i),Bi(n,"stopImmediatePropagation",i)}function wx(e){return!!e.getEvent()[jg]}function Ex(e){let n=e.getEvent(),t=e.getTargetElement(),i=n.preventDefault.bind(n);Bi(n,"target",t),Bi(n,"eventPhase",mm.REPLAY),Bi(n,"preventDefault",()=>{throw i(),new Error(bx+"")}),Bi(n,"composedPath",()=>{throw new Error(xx+"")})}function Mx(e){let n=e.getEvent(),t=e.getAction()?.element;t&&Bi(n,"currentTarget",t,{configurable:!0})}function Bi(e,n,t,{configurable:i=!1}={}){Object.defineProperty(e,n,{value:t,configurable:i})}function Bg(e,n){e.ecrd(t=>{n.dispatch(t)},Ug.I_AM_THE_JSACTION_FRAMEWORK)}function Px(e){return e?.q??[]}function Dx(e){e&&(Dg(e.c,e.et,e.h),Dg(e.c,e.etc,e.h,!0))}function Dg(e,n,t,i){for(let o=0;o<n.length;o++)e.removeEventListener(n[o],t,i)}var Ix=!1,Hg=(()=>{class e{static MOUSE_SPECIAL_SUPPORT=Ix;containerManager;eventHandlers={};browserEventTypeToExtraEventTypes={};dispatcher=null;queuedEventInfos=[];constructor(t){this.containerManager=t}handleEvent(t,i,o){let r=gx(t,i,i.target,o,Date.now());this.handleEventInfo(r)}handleEventInfo(t){if(!this.dispatcher){Rg(t,!0),this.queuedEventInfos?.push(t);return}this.dispatcher(t)}addEvent(t,i,o){if(t in this.eventHandlers||!this.containerManager||!e.MOUSE_SPECIAL_SUPPORT&&ex.indexOf(t)>=0)return;let r=(u,m,f)=>{this.handleEvent(u,m,f)};this.eventHandlers[t]=r;let c=nx(i||t);if(c!==t){let u=this.browserEventTypeToExtraEventTypes[c]||[];u.push(t),this.browserEventTypeToExtraEventTypes[c]=u}this.containerManager.addEventListener(c,u=>m=>{r(t,m,u)}
3,o)}replayEarlyEvents(t=window._ejsa){t&&(this.replayEarlyEventInfos(t.q),Dx(t),delete window._ejsa)}replayEarlyEventInfos(t){for(let i=0;i<t.length;i++){let o=t[i],r=this.getEventTypesForBrowserEventType(o.eventType);for(let c=0;c<r.length;c++){let u=Vg(o);um(u,r[c]),this.handleEventInfo(u)}}}getEventTypesForBrowserEventType(t){let i=[];return this.eventHandlers[t]&&i.push(t),this.browserEventTypeToExtraEventTypes[t]&&i.push(...this.browserEventTypeToExtraEventTypes[t]),i}handler(t){return this.eventHandlers[t]}cleanUp(){this.containerManager?.cleanUp(),this.containerManager=null,this.eventHandlers={},this.browserEventTypeToExtraEventTypes={},this.dispatcher=null,this.queuedEventInfos=[]}registerDispatcher(t,i){this.ecrd(t,i)}ecrd(t,i){if(this.dispatcher=t,this.queuedEventInfos?.length){for(let o=0;o<this.queuedEventInfos.length;o++)this.handleEventInfo(this.queuedEventInfos[o]);this.queuedEventInfos=null}}}return e})();function $g(e,n=window){return Px(n._ejsas?.[e])}function pm(e,n=window){n._ejsas&&(n._ejsas[e]=void 0)}var B0="https://angular.dev/best-practices/security#preventing-cross-site-scripting-xss",J=class extends Error{code;constructor(n,t){super(Np(n,t)),this.code=n}};function Tx(e){return`NG0${Math.abs(e)}`}function Np(e,n){return`${Tx(e)}${n?": "+n:""}`}var H0=Symbol("InputSignalNode#UNSET"),Ox=oe(U({},cs),{transformFn:void 0,applyValueToInputSignal(e,n){Or(e,n)}});function $0(e,n){let t=Object.create(Ox);t.value=e,t.transformFn=n?.transform;function i(){if(Tr(t),t.value===H0){let o=null;throw new J(-950,o)}return t.value}return i[rn]=t,i}function wl(e){return{toString:e}.toString()}var bi=globalThis;function Ae(e){for(let n in e)if(e[n]===Ae)return n;throw Error("Could not find renamed property on target object.")}function Nx(e,n){for(let t in n)n.hasOwnProperty(t)&&!e.hasOwnProperty(t)&&(e[t]=n[t])}function At(e){if(typeof e=="string")return e;if(Array.isArray(e))return`[${e.map(At).join(", ")}]`;if(e==null)return""+e;let n=e.overriddenName||e.name;if(n)return`${n}`;let t=e.toString();if(t==null)return""+t;let i=t.indexOf(`
4`);return i>=0?t.slice(0,i):t}function km(e,n){return e?n?`${e} ${n}`:e:n||""}var kx=Ae({__forward_ref__:Ae});function Ft(e){return e.__forward_ref__=Ft,e.toString=function(){return At(this())},e}function Mt(e){return z0(e)?e():e}function z0(e){return typeof e=="function"&&e.hasOwnProperty(kx)&&e.__forward_ref__===Ft}function O(e){return{token:e.token,providedIn:e.providedIn||null,factory:e.factory,value:void 0}}function Ei(e){return{providers:e.providers||[],imports:e.imports||[]}}function El(e){return zg(e,W0)||zg(e,q0)}function G0(e){return El(e)!==null}function zg(e,n){return e.hasOwnProperty(n)?e[n]:null}function Ax(e){let n=e&&(e[W0]||e[q0]);return n||null}function Gg(e){return e&&(e.hasOwnProperty(Wg)||e.hasOwnProperty(Rx))?e[Wg]:null}var W0=Ae({\u0275prov:Ae}),Wg=Ae({\u0275inj:Ae}),q0=Ae({ngInjectableDef:Ae}),Rx=Ae({ngInjectorDef:Ae}),K=class{_desc;ngMetadataName="InjectionToken";\u0275prov;constructor(n,t){this._desc=n,this.\u0275prov=void 0,typeof t=="number"?this.__NG_ELEMENT_ID__=t:t!==void 0&&(this.\u0275prov=O({token:this,providedIn:t.providedIn||"root",factory:t.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}};function J0(e){return e&&!!e.\u0275providers}var Fx=Ae({\u0275cmp:Ae}),Lx=Ae({\u0275dir:Ae}),Vx=Ae({\u0275pipe:Ae}),Ux=Ae({\u0275mod:Ae}),Qs=Ae({\u0275fac:Ae}),Ur=Ae({__NG_ELEMENT_ID__:Ae}),qg=Ae({__NG_ENV_ID__:Ae});function ei(e){return typeof e=="string"?e:e==null?"":String(e)}function jx(e){return typeof e=="function"?e.name||e.toString():typeof e=="object"&&e!=null&&typeof e.type=="function"?e.type.name||e.type.toString():ei(e)}function K0(e,n){throw new J(-200,e)}function kp(e,n){throw new J(-201,!1)}var de=(function(e){return e[e.Default=0]="Default",e[e.Host=1]="Host",e[e.Self=2]="Self",e[e.SkipSelf=4]="SkipSelf",e[e.Optional=8]="Optional",e})(de||{}),Am;function Y0(){return Am}function Nt(e){let n=Am;return Am=e,n}function Z0(e,n,t){let i=El(e);if(i&&i.providedIn=="root")return i.value===void 0?i.value=i.factory():i.value;if(t&de.Optional)return null;if(n!==void 0)return n;kp(e,"Injector")}var Bx={},$i=Bx,Hx="__NG_DI_FLAG__",Xs=class{injector;constructor(n){this.injector=n}retrieve(n,t){let i=t;return this.injector.get(n,i.optional?ds:$i,i)}},el="ngTempTokenPath",$x="ngTokenPath",zx=/\n/gm,Gx="\u0275",Jg="__source";function Wx(e,n=de.Default){if(Nr()===void 0)throw new J(-203,!1);if(Nr()===null)return Z0(e,void 0,n);{let t=Nr(),i;
4return t instanceof Xs?i=t.injector:i=t,i.get(e,n&de.Optional?null:void 0,n)}}function re(e,n=de.Default){return(Y0()||Wx)(Mt(e),n)}function h(e,n=de.Default){return re(e,Ml(n))}function Ml(e){return typeof e>"u"||typeof e=="number"?e:0|(e.optional&&8)|(e.host&&1)|(e.self&&2)|(e.skipSelf&&4)}function Rm(e){let n=[];for(let t=0;t<e.length;t++){let i=Mt(e[t]);if(Array.isArray(i)){if(i.length===0)throw new J(900,!1);let o,r=de.Default;for(let c=0;c<i.length;c++){let u=i[c],m=qx(u);typeof m=="number"?m===-1?o=u.token:r|=m:o=u}n.push(re(o,r))}else n.push(re(i))}return n}function qx(e){return e[Hx]}function Jx(e,n,t,i){let o=e[el];throw n[Jg]&&o.unshift(n[Jg]),e.message=Kx(`
5`+e.message,o,t,i),e[$x]=o,e[el]=null,e}function Kx(e,n,t,i=null){e=e&&e.charAt(0)===`
6`&&e.charAt(1)==Gx?e.slice(2):e;let o=At(n);if(Array.isArray(n))o=n.map(At).join(" -> ");else if(typeof n=="object"){let r=[];for(let c in n)if(n.hasOwnProperty(c)){let u=n[c];r.push(c+":"+(typeof u=="string"?JSON.stringify(u):At(u)))}o=`{${r.join(", ")}}`}return`${t}${i?"("+i+")":""}[${o}]: ${e.replace(zx,`
7  `)}`}function Gi(e,n){let t=e.hasOwnProperty(Qs);return t?e[Qs]:null}function Yx(e,n,t){if(e.length!==n.length)return!1;for(let i=0;i<e.length;i++){let o=e[i],r=n[i];if(t&&(o=t(o),r=t(r)),r!==o)return!1}return!0}function Zx(e){return e.flat(Number.POSITIVE_INFINITY)}function Ap(e,n){e.forEach(t=>Array.isArray(t)?Ap(t,n):n(t))}function Q0(e,n,t){n>=e.length?e.push(t):e.splice(n,0,t)}function tl(e,n){return n>=e.length-1?e.pop():e.splice(n,1)[0]}function Qx(e,n,t,i){let o=e.length;if(o==n)e.push(t,i);
7else if(o===1)e.push(i,e[0]),e[0]=t;else{for(o--,e.push(e[o-1],e[o]);o>n;){let r=o-2;e[o]=e[r],o--}e[n]=t,e[n+1]=i}}function Rp(e,n,t){let i=Yr(e,n);return i>=0?e[i|1]=t:(i=~i,Qx(e,i,n,t)),i}function fm(e,n){let t=Yr(e,n);if(t>=0)return e[t|1]}function Yr(e,n){return Xx(e,n,1)}function Xx(e,n,t){let i=0,o=e.length>>t;for(;o!==i;){let r=i+(o-i>>1),c=e[r<<t];if(n===c)return r<<t;c>n?o=r:i=r+1}return~(o<<t)}var Wi={},kt=[],Si=new K(""),X0=new K("",-1),eC=new K(""),nl=class{get(n,t=$i){if(t===$i){let i=new Error(`NullInjectorError: No provider for ${At(n)}!`);throw i.name="NullInjectorError",i}return t}};function tC(e,n){let t=e[Ux]||null;if(!t&&n===!0)throw new Error(`Type ${At(e)} does not have '\u0275mod' property.`);return t}function qi(e){return e[Fx]||null}function nC(e){return e[Lx]||null}function iC(e){return e[Vx]||null}function Mi(e){return{\u0275providers:e}}function eS(...e){return{\u0275providers:Fp(!0,e),\u0275fromNgModule:!0}}function Fp(e,...n){let t=[],i=new Set,o,r=c=>{t.push(c)};return Ap(n,c=>{let u=c;Fm(u,r,[],i)&&(o||=[],o.push(u))}),o!==void 0&&oC(o,r),t}function oC(e,n){for(let t=0;t<e.length;t++){let{ngModule:i,providers:o}=e[t];Lp(o,r=>{n(r,i)})}}function Fm(e,n,t,i){if(e=Mt(e),!e)return!1;let o=null,r=Gg(e),c=!r&&qi(e);if(!r&&!c){let m=e.ngModule;if(r=Gg(m),r)o=m;else return!1}else{if(c&&!c.standalone)return!1;o=e}let u=i.has(o);if(c){if(u)return!1;if(i.add(o),c.dependencies){let m=typeof c.dependencies=="function"?c.dependencies():c.dependencies;for(let f of m)Fm(f,n,t,i)}}else if(r){if(r.imports!=null&&!u){i.add(o);let f;Ap(r.imports,C=>{Fm(C,n,t,i)&&(f||=[],f.push(C))}),f!==void 0&&oC(f,n)}if(!u){let f=Gi(o)||(()=>new o);n({provide:o,useFactory:f,deps:kt},o),n({provide:eC,useValue:o,multi:!0},o),n({provide:Si,useValue:()=>re(o),multi:!0},o)}let m=r.providers;if(m!=null&&!u){let f=e;Lp(m,C=>{n(C,f)})}}else return!1;return o!==e&&e.providers!==void 0}function Lp(e,n){for(let t of e)J0(t)&&(t=t.\u0275providers),Array.isArray(t)?Lp(t,n):n(t)}var tS=Ae({provide:String,useValue:Ae});function rC(e){return e!==null&&typeof e=="object"&&tS in e}function nS(e){return!!(e&&e.useExisting)}function iS(e){return!!(e&&e.useFactory)}function Lo(e){return typeof e=="function"}function oS(e){return!!e.useClass}var Pl=new K(""),zs={},Kg={},hm;function Vp(){return hm===void 0&&(hm=new nl),hm}var yt=class{},jr=class extends yt{parent;source;scopes;records=new Map;_ngOnDestroyHooks=new Set;_onDestroyHooks=[];get destroyed(){return this._destroyed}_destroyed=!1;injectorDefTypes;constructor(n,t,i,o){super(),this.parent=t,this.source=i,this.scopes=o,Vm(n,c=>this.processProvider(c)),this.records.set(X0,Do(void 0,this)),o.has("environment")&&this.records.set(yt,Do(void 0,this));let r=this.records.get(Pl);r!=null&&typeof r.value=="string"&&this.scopes.add(r.value),this.injectorDefTypes=new Set(this.get(eC,kt,de.Self))}retrieve(n,t){let i=t;return this.get(n,i.optional?ds:$i,i)}destroy(){Lr(this),this._destroyed=!0;let n=fe(null);try{for(let i of this._ngOnDestroyHooks)i.ngOnDestroy();let t=this._onDestroyHooks;this._onDestroyHooks=[];for(let i of t)i()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),fe(n)}}onDestroy(n){return Lr(this),this._onDestroyHooks.push(n),()=>this.removeOnDestroy(n)}runInContext(n){Lr(this);let t=Yn(this),i=Nt(void 0),o;try{return n()}finally{Yn(t),Nt(i)}}get(n,t=$i,i=de.Default){if(Lr(this),n.hasOwnProperty(qg))return n[qg](this);i=Ml(i);let o,r=Yn(this),c=Nt(void 0);try{if(!(i&de.SkipSelf)){let m=this.records.get(n);if(m===void 0){let f=cS(n)&&El(n);f&&this.injectableDefInScope(f)?m=Do(Lm(n),zs):m=null,this.records.set(n,m)}if(m!=null)return this.hydrate(n,m,i)}let u=i&de.Self?Vp():this.parent;return t=i&de.Optional&&t===$i?null:t,u.get(n,t)}catch(u){if(u.name==="NullInjectorError"){if((u[el]=u[el]||[]).unshift(At(n)),r)throw u;return Jx(u,n,"R3InjectorError",this.source)}else throw u}finally{Nt(c),Yn(r)}}resolveInjectorInitializers(){let n=fe(null),t=Yn(this),i=Nt(void 0),o;try{let r=this.get(Si,kt,de.Self);for(let c of r)c()}finally{Yn(t),Nt(i),fe(n)}}toString(){let n=[],t=this.records;for(let i of t.keys())n.push(At(i));return`R3Injector[${n.join(", ")}]`}processProvider(n){n=Mt(n);let t=Lo(n)?n:Mt(n&&n.provide),i=aS(n);if(!Lo(n)&&n.multi===!0){let o=this.records.get(t);o||(o=Do(void 0,zs,!0),o.factory=()=>Rm(o.multi),this.records.set(t,o)),t=n,o.multi.push(n)}this.records.set(t,i)}hydrate(n,t,i){let o=fe(null);try{return t.value===Kg?K0(At(n)):t.value===zs&&(t.value=Kg,t.value=t.factory(void 0,i)),typeof t.value=="object"&&t.value&&lS(t.value)&&this._ngOnDestroyHooks.add(t.value),t.value}finally{fe(o)}}injectableDefInScope(n){if(!n.providedIn)return!1;let t=Mt(n.providedIn);return typeof t=="string"?t==="any"||this.scopes.has(t):this.injectorDefTypes.has(t)}removeOnDestroy(n){let t=this._onDestroyHooks.indexOf(n);t!==-1&&this._onDestroyHooks.splice(t,1)}};function Lm(e){let n=El(e),t=n!==null?n.factory:Gi(e);if(t!==null)return t;
vendor: 5,080 bytes, line 7
7if(e instanceof K)throw new J(204,!1);if(e instanceof Function)return rS(e);throw new J(204,!1)}function rS(e){if(e.length>0)throw new J(204,!1);let t=Ax(e);return t!==null?()=>t.factory(e):()=>new e}function aS(e){if(rC(e))return Do(void 0,e.useValue);{let n=aC(e);return Do(n,zs)}}function aC(e,n,t){let i;if(Lo(e)){let o=Mt(e);return Gi(o)||Lm(o)}else if(rC(e))i=()=>Mt(e.useValue);else if(iS(e))i=()=>e.useFactory(...Rm(e.deps||[]));else if(nS(e))i=(o,r)=>re(Mt(e.useExisting),r!==void 0&&r&de.Optional?de.Optional:void 0);else{let o=Mt(e&&(e.useClass||e.provide));if(sS(e))i=()=>new o(...Rm(e.deps));else return Gi(o)||Lm(o)}return i}function Lr(e){if(e.destroyed)throw new J(205,!1)}function Do(e,n,t=!1){return{factory:e,value:n,multi:t?[]:void 0}}function sS(e){return!!e.deps}function lS(e){return e!==null&&typeof e=="object"&&typeof e.ngOnDestroy=="function"}function cS(e){return typeof e=="function"||typeof e=="object"&&e instanceof K}function Vm(e,n){for(let t of e)Array.isArray(t)?Vm(t,n):t&&J0(t)?Vm(t.\u0275providers,n):n(t)}function Kt(e,n){let t;e instanceof jr?(Lr(e),t=e):t=new Xs(e);let i,o=Yn(t),r=Nt(void 0);try{return n()}finally{Yn(o),Nt(r)}}function sC(){return Y0()!==void 0||Nr()!=null}function lC(e){if(!sC())throw new J(-203,!1)}function dS(e){return typeof e=="function"}var qt=0,ie=1,ae=2,lt=3,vn=4,Sn=5,bn=6,il=7,st=8,Tn=9,ni=10,Fe=11,Br=12,Yg=13,zo=14,Jt=15,Ji=16,Io=17,ii=18,Dl=19,cC=20,xi=21,gm=22,ol=23,an=24,ko=25,Ge=26,dC=1,oi=6,ri=7,rl=8,Vo=9,ht=10;function yn(e){return Array.isArray(e)&&typeof e[dC]=="object"}function Rn(e){return Array.isArray(e)&&e[dC]===!0}function Up(e){return(e.flags&4)!==0}function eo(e){return e.componentOffset>-1}function Il(e){return(e.flags&1)===1}function On(e){return!!e.template}function Hr(e){return(e[ae]&512)!==0}function to(e){return(e[ae]&256)===256}var Um=class{previousValue;currentValue;firstChange;constructor(n,t,i){this.previousValue=n,this.currentValue=t,this.firstChange=i}isFirstChange(){return this.firstChange}};function uC(e,n,t,i){n!==null?n.applyValueToInputSignal(n,i):e[t]=i}var ct=(()=>{let e=()=>mC;return e.ngInherit=!0,e})();function mC(e){return e.type.prototype.ngOnChanges&&(e.setInput=mS),uS}function uS(){let e=fC(this),n=e?.current;if(n){let t=e.previous;if(t===Wi)e.previous=n;else for(let i in n)t[i]=n[i];e.current=null,this.ngOnChanges(n)}}function mS(e,n,t,i,o){let r=this.declaredInputs[i],c=fC(e)||pS(e,{previous:Wi,current:null}),u=c.current||(c.current={}),m=c.previous,f=m[r];u[r]=new Um(f&&f.currentValue,t,m===Wi),uC(e,n,o,t)}var pC="__ngSimpleChanges__";function fC(e){return e[pC]||null}function pS(e,n){return e[pC]=n}var Zg=null;var Ee=function(e,n=null,t){Zg?.(e,n,t)},fS="svg",hS="math";function xn(e){for(;Array.isArray(e);)e=e[qt];return e}function hC(e,n){return xn(n[e])}function wn(e,n){return xn(n[e.index])}function Zr(e,n){return e.data[n]}function gC(e,n){return e[n]}function gS(e,n,t,i){t>=e.data.length&&(e.data[t]=null,e.blueprint[t]=null),n[t]=i}function Nn(e,n){let t=n[e];return yn(t)?t:t[qt]}function CS(e){return(e[ae]&4)===4}function jp(e){return(e[ae]&128)===128}function _S(e){return Rn(e[lt])}function wi(e,n){return n==null?null:e[n]}function CC(e){e[Io]=0}function _C(e){e[ae]&1024||(e[ae]|=1024,jp(e)&&Qr(e))}function vS(e,n){for(;e>0;)n=n[zo],e--;return n}function Tl(e){return!!(e[ae]&9216||e[an]?.dirty)}function jm(e){e[ni].changeDetectionScheduler?.notify(8),e[ae]&64&&(e[ae]|=1024),Tl(e)&&Qr(e)}function Qr(e){e[ni].changeDetectionScheduler?.notify(0);let n=Ki(e);for(;n!==null&&!(n[ae]&8192||(n[ae]|=8192,!jp(n)));)n=Ki(n)}function vC(e,n){if(to(e))throw new J(911,!1);e[xi]===null&&(e[xi]=[]),e[xi].push(n)}function yS(e,n){if(e[xi]===null)return;let t=e[xi].indexOf(n);t!==-1&&e[xi].splice(t,1)}function Ki(e){let n=e[lt];return Rn(n)?n[lt]:n}function Bp(e){return e[il]??=[]}function Hp(e){return e.cleanup??=[]}function bS(e,n,t,i){let o=Bp(n);o.push(t),e.firstCreatePass&&Hp(e).push(i,o.length-1)}var ue={lFrame:DC(null),bindingsEnabled:!0,skipHydrationRootTNode:null};var Bm=!1;function xS(){return ue.lFrame.elementDepthCount}function SS(){ue.lFrame.elementDepthCount++}function wS(){ue.lFrame.elementDepthCount--}function $p(){return ue.bindingsEnabled}function Xr(){return ue.skipHydrationRootTNode!==null}function ES(e){return ue.skipHydrationRootTNode===e}function MS(e){ue.skipHydrationRootTNode=e}function PS(){ue.skipHydrationRootTNode=null}function he(){return ue.lFrame.lView}function Xe(){return ue.lFrame.tView}function S(e){return ue.lFrame.contextLView=e,e[st]}function w(e){return ue.lFrame.contextLView=null,e}function Pt(){let e=yC();for(;e!==null&&e.type===64;)e=e.parent;return e}function yC(){return ue.lFrame.currentTNode}function DS(){let e=ue.lFrame,n=e.currentTNode;return e.isParent?n:n.parent}function no(e,n){let t=ue.lFrame;t.currentTNode=e,t.isParent=n}function zp(){return ue.lFrame.isParent}function bC(){ue.lFrame.isParent=!1}function IS(){return ue.lFrame.contextLView}function xC(){return Bm}function Qg(e){let n=Bm;return Bm=e,n}function SC(){let e=ue.lFrame,n=e.bindingRootIndex;
vendor: 8,229 bytes, line 7
7return n===-1&&(n=e.bindingRootIndex=e.tView.bindingStartIndex),n}function wC(){return ue.lFrame.bindingIndex}function TS(e){return ue.lFrame.bindingIndex=e}function Go(){return ue.lFrame.bindingIndex++}function Ol(e){let n=ue.lFrame,t=n.bindingIndex;return n.bindingIndex=n.bindingIndex+e,t}function OS(){return ue.lFrame.inI18n}function NS(e,n){let t=ue.lFrame;t.bindingIndex=t.bindingRootIndex=e,Hm(n)}function kS(){return ue.lFrame.currentDirectiveIndex}function Hm(e){ue.lFrame.currentDirectiveIndex=e}function AS(e){let n=ue.lFrame.currentDirectiveIndex;return n===-1?null:e[n]}function EC(){return ue.lFrame.currentQueryIndex}function Gp(e){ue.lFrame.currentQueryIndex=e}function RS(e){let n=e[ie];return n.type===2?n.declTNode:n.type===1?e[Sn]:null}function MC(e,n,t){if(t&de.SkipSelf){let o=n,r=e;for(;o=o.parent,o===null&&!(t&de.Host);)if(o=RS(r),o===null||(r=r[zo],o.type&10))break;if(o===null)return!1;n=o,e=r}let i=ue.lFrame=PC();return i.currentTNode=n,i.lView=e,!0}function Wp(e){let n=PC(),t=e[ie];ue.lFrame=n,n.currentTNode=t.firstChild,n.lView=e,n.tView=t,n.contextLView=e,n.bindingIndex=t.bindingStartIndex,n.inI18n=!1}function PC(){let e=ue.lFrame,n=e===null?null:e.child;return n===null?DC(e):n}function DC(e){let n={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:e,child:null,inI18n:!1};return e!==null&&(e.child=n),n}function IC(){let e=ue.lFrame;return ue.lFrame=e.parent,e.currentTNode=null,e.lView=null,e}var TC=IC;function qp(){let e=IC();e.isParent=!0,e.tView=null,e.selectedIndex=-1,e.contextLView=null,e.elementDepthCount=0,e.currentDirectiveIndex=-1,e.currentNamespace=null,e.bindingRootIndex=-1,e.bindingIndex=-1,e.currentQueryIndex=0}function FS(e){return(ue.lFrame.contextLView=vS(e,ue.lFrame.contextLView))[st]}function Fn(){return ue.lFrame.selectedIndex}function Yi(e){ue.lFrame.selectedIndex=e}function Jp(){let e=ue.lFrame;return Zr(e.tView,e.selectedIndex)}function Kp(){return ue.lFrame.currentNamespace}var OC=!0;function Nl(){return OC}function Pi(e){OC=e}function LS(e,n,t){let{ngOnChanges:i,ngOnInit:o,ngDoCheck:r}=n.type.prototype;if(i){let c=mC(n);(t.preOrderHooks??=[]).push(e,c),(t.preOrderCheckHooks??=[]).push(e,c)}o&&(t.preOrderHooks??=[]).push(0-e,o),r&&((t.preOrderHooks??=[]).push(e,r),(t.preOrderCheckHooks??=[]).push(e,r))}function Yp(e,n){for(let t=n.directiveStart,i=n.directiveEnd;t<i;t++){let r=e.data[t].type.prototype,{ngAfterContentInit:c,ngAfterContentChecked:u,ngAfterViewInit:m,ngAfterViewChecked:f,ngOnDestroy:C}=r;c&&(e.contentHooks??=[]).push(-t,c),u&&((e.contentHooks??=[]).push(t,u),(e.contentCheckHooks??=[]).push(t,u)),m&&(e.viewHooks??=[]).push(-t,m),f&&((e.viewHooks??=[]).push(t,f),(e.viewCheckHooks??=[]).push(t,f)),C!=null&&(e.destroyHooks??=[]).push(t,C)}}function Gs(e,n,t){NC(e,n,3,t)}function Ws(e,n,t,i){(e[ae]&3)===t&&NC(e,n,t,i)}function Cm(e,n){let t=e[ae];(t&3)===n&&(t&=16383,t+=1,e[ae]=t)}function NC(e,n,t,i){let o=i!==void 0?e[Io]&65535:0,r=i??-1,c=n.length-1,u=0;for(let m=o;m<c;m++)if(typeof n[m+1]=="number"){if(u=n[m],i!=null&&u>=i)break}else n[m]<0&&(e[Io]+=65536),(u<r||r==-1)&&(VS(e,t,n,m),e[Io]=(e[Io]&4294901760)+m+2),m++}function Xg(e,n){Ee(4,e,n);let t=fe(null);try{n.call(e)}finally{fe(t),Ee(5,e,n)}}function VS(e,n,t,i){let o=t[i]<0,r=t[i+1],c=o?-t[i]:t[i],u=e[c];o?e[ae]>>14<e[Io]>>16&&(e[ae]&3)===n&&(e[ae]+=16384,Xg(u,r)):Xg(u,r)}var Ao=-1,Zi=class{factory;injectImpl;resolving=!1;canSeeViewProviders;multi;componentProviders;index;providerFactory;constructor(n,t,i){this.factory=n,this.canSeeViewProviders=t,this.injectImpl=i}};function US(e){return(e.flags&8)!==0}function jS(e){return(e.flags&16)!==0}function BS(e,n,t){let i=0;for(;i<t.length;){let o=t[i];if(typeof o=="number"){if(o!==0)break;i++;let r=t[i++],c=t[i++],u=t[i++];e.setAttribute(n,c,u,r)}else{let r=o,c=t[++i];HS(r)?e.setProperty(n,r,c):e.setAttribute(n,r,c),i++}}return i}function kC(e){return e===3||e===4||e===6}function HS(e){return e.charCodeAt(0)===64}function Uo(e,n){if(!(n===null||n.length===0))if(e===null||e.length===0)e=n.slice();else{let t=-1;for(let i=0;i<n.length;i++){let o=n[i];typeof o=="number"?t=o:t===0||(t===-1||t===2?e0(e,t,o,null,n[++i]):e0(e,t,o,null,null))}}return e}function e0(e,n,t,i,o){let r=0,c=e.length;if(n===-1)c=-1;else for(;r<e.length;){let u=e[r++];if(typeof u=="number"){if(u===n){c=-1;break}else if(u>n){c=r-1;break}}}for(;r<e.length;){let u=e[r];if(typeof u=="number")break;if(u===t){o!==null&&(e[r+1]=o);return}r++,o!==null&&r++}c!==-1&&(e.splice(c,0,n),r=c+1),e.splice(r++,0,t),o!==null&&e.splice(r++,0,o)}function AC(e){return e!==Ao}function al(e){return e&32767}function $S(e){return e>>16}function sl(e,n){let t=$S(e),i=n;for(;t>0;)i=i[zo],t--;return i}var $m=!0;function ll(e){let n=$m;return $m=e,n}var zS=256,RC=zS-1,FC=5,GS=0,In={};function WS(e,n,t){let i;typeof t=="string"?i=t.charCodeAt(0)||0:t.hasOwnProperty(Ur)&&(i=t[Ur]),i==null&&(i=t[Ur]=GS++);let o=i&RC,r=1<<o;n.data[e+(o>>FC)]|=r}function cl(e,n){let t=LC(e,n);if(t!==-1)return t;let i=n[ie];i.firstCreatePass&&(e.injectorIndex=n.length,_m(i.data,e),_m(n,null),_m(i.blueprint,null));let o=Zp(e,n),r=e.injectorIndex;if(AC(o)){let c=al(o),u=sl(o,n),m=u[ie].data;for(let f=0;f<8;f++)n[r+f]=u[c+f]|m[c+f]}return n[r+8]=o,r}function _m(e,n){e.push(0,0,0,0,0,0,0,0,n)}function LC(e,n){return e.injectorIndex===-1||e.parent&&e.parent.injectorIndex===e.injectorIndex||n[e.injectorIndex+8]===null?-1:e.injectorIndex}function Zp(e,n){if(e.parent&&e.parent.injectorIndex!==-1)return e.parent.injectorIndex;let t=0,i=null,o=n;for(;o!==null;){if(i=HC(o),i===null)return Ao;if(t++,o=o[zo],i.injectorIndex!==-1)return i.injectorIndex|t<<16}return Ao}function zm(e,n,t){WS(e,n,t)}function qS(e,n){if(n==="class")return e.classes;if(n==="style")return e.styles;let t=e.attrs;if(t){let i=t.length,o=0;for(;o<i;){let r=t[o];if(kC(r))break;if(r===0)o=o+2;else if(typeof r=="number")for(o++;o<i&&typeof t[o]=="string";)o++;else{if(r===n)return t[o+1];o=o+2}}}return null}function VC(e,n,t){if(t&de.Optional||e!==void 0)return e;kp(n,"NodeInjector")}function UC(e,n,t,i){if(t&de.Optional&&i===void 0&&(i=null),(t&(de.Self|de.Host))===0){let o=e[Tn],r=Nt(void 0);try{return o?o.get(n,i,t&de.Optional):Z0(n,i,t&de.Optional)}finally{Nt(r)}}return VC(i,n,t)}function jC(e,n,t,i=de.Default,o){if(e!==null){if(n[ae]&2048&&!(i&de.Self)){let c=ZS(e,n,t,i,In);if(c!==In)return c}let r=BC(e,n,t,i,In);if(r!==In)return r}return UC(n,t,i,o)}function BC(e,n,t,i,o){let r=KS(t);if(typeof r=="function"){if(!MC(n,e,i))return i&de.Host?VC(o,t,i):UC(n,t,i,o);try{let c;if(c=r(i),c==null&&!(i&de.Optional))kp(t);else return c}finally{TC()}}else if(typeof r=="number"){let c=null,u=LC(e,n),m=Ao,f=i&de.Host?n[Jt][Sn]:null;for((u===-1||i&de.SkipSelf)&&(m=u===-1?Zp(e,n):n[u+8],m===Ao||!n0(i,!1)?u=-1:(c=n[ie],u=al(m),n=sl(m,n)));u!==-1;){let C=n[ie];if(t0(r,u,C.data)){let b=JS(u,n,t,c,i,f);if(b!==In)return b}m=n[u+8],m!==Ao&&n0(i,n[ie].data[u+8]===f)&&t0(r,u,n)?(c=C,u=al(m),n=sl(m,n)):u=-1}}return o}function JS(e,n,t,i,o,r){let c=n[ie],u=c.data[e+8],m=i==null?eo(u)&&$m:i!=c&&(u.type&3)!==0,f=o&de.Host&&r===u,C=qs(u,c,t,m,f);return C!==null?$r(n,c,C,u,o):In}function qs(e,n,t,i,o){let r=e.providerIndexes,c=n.data,u=r&1048575,m=e.directiveStart,f=e.directiveEnd,C=r>>20,b=i?u:u+C,P=o?u+C:f;for(let x=b;x<P;x++){let D=c[x];if(x<m&&t===D||x>=m&&D.type===t)return x}if(o){let x=c[m];if(x&&On(x)&&x.type===t)return m}return null}function $r(e,n,t,i,o){let r=e[t],c=n.data;if(r instanceof Zi){let u=r;u.resolving&&K0(jx(c[t]));let m=ll(u.canSeeViewProviders);u.resolving=!0;let f,C=u.injectImpl?Nt(u.injectImpl):null,b=MC(e,i,de.Default);try{r=e[t]=u.factory(void 0,o,c,e,i),n.firstCreatePass&&t>=i.directiveStart&&LS(t,c[t],n)}finally{C!==null&&Nt(C),ll(m),u.resolving=!1,TC()}}return r}function KS(e){if(typeof e=="string")return e.charCodeAt(0)||0;let n=e.hasOwnProperty(Ur)?e[Ur]:void 0;return typeof n=="number"?n>=0?n&RC:YS:n}function t0(e,n,t){let i=1<<e;return!!(t[n+(e>>FC)]&i)}function n0(e,n){return!(e&de.Self)&&!(e&de.Host&&n)}var zi=class{_tNode;_lView;constructor(n,t){this._tNode=n,this._lView=t}
7get(n,t,i){return jC(this._tNode,this._lView,n,Ml(i),t)}};function YS(){return new zi(Pt(),he())}function Yt(e){return wl(()=>{let n=e.prototype.constructor,t=n[Qs]||Gm(n),i=Object.prototype,o=Object.getPrototypeOf(e.prototype).constructor;for(;o&&o!==i;){let r=o[Qs]||Gm(o);if(r&&r!==t)return r;o=Object.getPrototypeOf(o)}return r=>new r})}function Gm(e){return z0(e)?()=>{let n=Gm(Mt(e));return n&&n()}:Gi(e)}function ZS(e,n,t,i,o){let r=e,c=n;for(;r!==null&&c!==null&&c[ae]&2048&&!Hr(c);){let u=BC(r,c,t,i|de.Self,In);if(u!==In)return u;let m=r.parent;if(!m){let f=c[cC];if(f){let C=f.get(t,In,i);if(C!==In)return C}m=HC(c),c=c[zo]}r=m}return o}function HC(e){let n=e[ie],t=n.type;return t===2?n.declTNode:t===1?e[Sn]:null}function Qp(e){return qS(Pt(),e)}function i0(e,n=null,t=null,i){let o=$C(e,n,t,i);return o.resolveInjectorInitializers(),o}function $C(e,n=null,t=null,i,o=new Set){let r=[t||kt,eS(e)];return i=i||(typeof e=="object"?void 0:At(e)),new jr(r,n||Vp(),i||null,o)}var sn=class e{static THROW_IF_NOT_FOUND=$i;static NULL=new nl;static create(n,t){if(Array.isArray(n))return i0({name:""},t,n,"");{let i=n.name??"";return i0({name:i},n.parent,n.providers,i)}}static \u0275prov=O({token:e,providedIn:"any",factory:()=>re(X0)});static __NG_ELEMENT_ID__=-1};var QS=new K("");QS.__NG_ELEMENT_ID__=e=>{let n=Pt();if(n===null)throw new J(204,!1);if(n.type&2)return n.value;if(e&de.Optional)return null;throw new J(204,!1)};var zC=!1,io=(()=>{class e{static __NG_ELEMENT_ID__=XS;static __NG_ENV_ID__=t=>t}return e})(),Wm=class extends io{_lView;constructor(n){super(),this._lView=n}onDestroy(n){let t=this._lView;return to(t)?(n(),()=>{}):(vC(t,n),()=>yS(t,n))}};function XS(){return new Wm(he())}var Qi=class{},kl=new K("",{providedIn:"root",factory:()=>!1});var GC=new K(""),WC=new K(""),Ln=(()=>{class e{taskId=0;pendingTasks=new Set;get _hasPendingTasks(){return this.hasPendingTasks.value}hasPendingTasks=new ft(!1);add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);let t=this.taskId++;return this.pendingTasks.add(t),t}has(t){return this.pendingTasks.has(t)}remove(t){this.pendingTasks.delete(t),this.pendingTasks.size===0&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static \u0275prov=O({token:e,providedIn:"root",factory:()=>new e})}return e})(),ew=(()=>{class e{internalPendingTasks=h(Ln);scheduler=h(Qi);add(){let t=this.internalPendingTasks.add();return()=>{this.internalPendingTasks.has(t)&&(this.scheduler.notify(11),this.internalPendingTasks.remove(t))}}run(t){return wt(this,null,function*(){let i=this.add();try{return yield t()}finally{i()}})}static \u0275prov=O({token:e,providedIn:"root",factory:()=>new e})}return e})(),qm=class extends Ue{__isAsync;destroyRef=void 0;pendingTasks=void 0;constructor(n=!1){super(),this.__isAsync=n,sC()&&(this.destroyRef=h(io,{optional:!0})??void 0,this.pendingTasks=h(Ln,{optional:!0})??void 0)}emit(n){let t=fe(null);try{super.next(n)}finally{fe(t)}}subscribe(n,t,i){let o=n,r=t||(()=>null),c=i;if(n&&typeof n=="object"){let m=n;o=m.next?.bind(m),r=m.error?.bind(m),c=m.complete?.bind(m)}this.__isAsync&&(r=this.wrapInTimeout(r),o&&(o=this.wrapInTimeout(o)),c&&(c=this.wrapInTimeout(c)));let u=super.subscribe({next:o,error:r,complete:c});return n instanceof Qe&&n.add(u),u}wrapInTimeout(n){return t=>{let i=this.pendingTasks?.add();setTimeout(()=>{try{n(t)}finally{i!==void 0&&this.pendingTasks?.remove(i)}})}}},je=qm;function dl(...e){}function qC(e){let n,t;function i(){e=dl;try{t!==void 0&&typeof cancelAnimationFrame=="function"&&cancelAnimationFrame(t),n!==void 0&&clearTimeout(n)}catch{}}return n=setTimeout(()=>{e(),i()}),typeof requestAnimationFrame=="function"&&(t=requestAnimationFrame(()=>{e(),i()})),()=>i()}function o0(e){return queueMicrotask(()=>e()),()=>{e=dl}}var Xp="isAngularZone",ul=Xp+"_ID",tw=0,Ke=class e{hasPendingMacrotasks=!1;hasPendingMicrotasks=!1;isStable=!0;onUnstable=new je(!1);onMicrotaskEmpty=new je(!1);onStable=new je(!1);onError=new je(!1);constructor(n){let{enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:i=!1,shouldCoalesceRunChangeDetection:o=!1,scheduleInRootZone:r=zC}=n;
vendor: 4,341 bytes, line 7
7if(typeof Zone>"u")throw new J(908,!1);Zone.assertZonePatched();let c=this;c._nesting=0,c._outer=c._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(c._inner=c._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(c._inner=c._inner.fork(Zone.longStackTraceZoneSpec)),c.shouldCoalesceEventChangeDetection=!o&&i,c.shouldCoalesceRunChangeDetection=o,c.callbackScheduled=!1,c.scheduleInRootZone=r,ow(c)}static isInAngularZone(){return typeof Zone<"u"&&Zone.current.get(Xp)===!0}static assertInAngularZone(){if(!e.isInAngularZone())throw new J(909,!1)}static assertNotInAngularZone(){if(e.isInAngularZone())throw new J(909,!1)}run(n,t,i){return this._inner.run(n,t,i)}runTask(n,t,i,o){let r=this._inner,c=r.scheduleEventTask("NgZoneEvent: "+o,n,nw,dl,dl);try{return r.runTask(c,t,i)}finally{r.cancelTask(c)}}runGuarded(n,t,i){return this._inner.runGuarded(n,t,i)}runOutsideAngular(n){return this._outer.run(n)}},nw={};function ef(e){if(e._nesting==0&&!e.hasPendingMicrotasks&&!e.isStable)try{e._nesting++,e.onMicrotaskEmpty.emit(null)}finally{if(e._nesting--,!e.hasPendingMicrotasks)try{e.runOutsideAngular(()=>e.onStable.emit(null))}finally{e.isStable=!0}}}function iw(e){if(e.isCheckStableRunning||e.callbackScheduled)return;e.callbackScheduled=!0;function n(){qC(()=>{e.callbackScheduled=!1,Jm(e),e.isCheckStableRunning=!0,ef(e),e.isCheckStableRunning=!1})}e.scheduleInRootZone?Zone.root.run(()=>{n()}):e._outer.run(()=>{n()}),Jm(e)}function ow(e){let n=()=>{iw(e)},t=tw++;e._inner=e._inner.fork({name:"angular",properties:{[Xp]:!0,[ul]:t,[ul+t]:!0},onInvokeTask:(i,o,r,c,u,m)=>{if(rw(m))return i.invokeTask(r,c,u,m);try{return r0(e),i.invokeTask(r,c,u,m)}finally{(e.shouldCoalesceEventChangeDetection&&c.type==="eventTask"||e.shouldCoalesceRunChangeDetection)&&n(),a0(e)}},onInvoke:(i,o,r,c,u,m,f)=>{try{return r0(e),i.invoke(r,c,u,m,f)}finally{e.shouldCoalesceRunChangeDetection&&!e.callbackScheduled&&!aw(m)&&n(),a0(e)}},onHasTask:(i,o,r,c)=>{i.hasTask(r,c),o===r&&(c.change=="microTask"?(e._hasPendingMicrotasks=c.microTask,Jm(e),ef(e)):c.change=="macroTask"&&(e.hasPendingMacrotasks=c.macroTask))},onHandleError:(i,o,r,c)=>(i.handleError(r,c),e.runOutsideAngular(()=>e.onError.emit(c)),!1)})}function Jm(e){e._hasPendingMicrotasks||(e.shouldCoalesceEventChangeDetection||e.shouldCoalesceRunChangeDetection)&&e.callbackScheduled===!0?e.hasPendingMicrotasks=!0:e.hasPendingMicrotasks=!1}function r0(e){e._nesting++,e.isStable&&(e.isStable=!1,e.onUnstable.emit(null))}function a0(e){e._nesting--,ef(e)}var Km=class{hasPendingMicrotasks=!1;hasPendingMacrotasks=!1;isStable=!0;onUnstable=new je;onMicrotaskEmpty=new je;onStable=new je;onError=new je;run(n,t,i){return n.apply(t,i)}runGuarded(n,t,i){return n.apply(t,i)}runOutsideAngular(n){return n()}runTask(n,t,i,o){return n.apply(t,i)}};function rw(e){return JC(e,"__ignore_ng_zone__")}function aw(e){return JC(e,"__scheduler_tick__")}function JC(e,n){return!Array.isArray(e)||e.length!==1?!1:e[0]?.data?.[n]===!0}var kn=class{_console=console;handleError(n){this._console.error("ERROR",n)}},sw=new K("",{providedIn:"root",factory:()=>{let e=h(Ke),n=h(kn);return t=>e.runOutsideAngular(()=>n.handleError(t))}});function s0(e,n){return $0(e,n)}function lw(e){return $0(H0,e)}var KC=(s0.required=lw,s0);function cw(){return Wo(Pt(),he())}function Wo(e,n){return new Lt(wn(e,n))}var Lt=(()=>{class e{nativeElement;constructor(t){this.nativeElement=t}static __NG_ELEMENT_ID__=cw}return e})();function dw(e){return e instanceof Lt?e.nativeElement:e}function uw(e){return typeof e=="function"&&e[rn]!==void 0}function E(e,n){let t=Lu(e,n?.equal),i=t[rn];return t.set=o=>Or(i,o),t.update=o=>Vu(i,o),t.asReadonly=mw.bind(t),t}function mw(){let e=this[rn];if(e.readonlyFn===void 0){let n=()=>this();n[rn]=e,e.readonlyFn=n}return e.readonlyFn}function YC(e){return uw(e)&&typeof e.set=="function"}function pw(){return this._results[Symbol.iterator]()}var Ym=class{_emitDistinctChangesOnly;dirty=!0;_onDirty=void 0;_results=[];_changesDetected=!1;_changes=void 0;length=0;first=void 0;last=void 0;get changes(){return this._changes??=new Ue}constructor(n=!1){this._emitDistinctChangesOnly=n}get(n){return this._results[n]}map(n){return this._results.map(n)}filter(n){return this._results.filter(n)}find(n){return this._results.find(n)}reduce(n,t){return this._results.reduce(n,t)}
7forEach(n){this._results.forEach(n)}some(n){return this._results.some(n)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(n,t){this.dirty=!1;let i=Zx(n);(this._changesDetected=!Yx(this._results,i,t))&&(this._results=i,this.length=i.length,this.last=i[this.length-1],this.first=i[0])}notifyOnChanges(){this._changes!==void 0&&(this._changesDetected||!this._emitDistinctChangesOnly)&&this._changes.next(this)}onDirty(n){this._onDirty=n}setDirty(){this.dirty=!0,this._onDirty?.()}destroy(){this._changes!==void 0&&(this._changes.complete(),this._changes.unsubscribe())}[Symbol.iterator]=pw},fw="ngSkipHydration",hw="ngskiphydration";function ZC(e){let n=e.mergedAttrs;if(n===null)return!1;for(let t=0;t<n.length;t+=2){let i=n[t];if(typeof i=="number")return!1;if(typeof i=="string"&&i.toLowerCase()===hw)return!0}return!1}function QC(e){return e.hasAttribute(fw)}function ml(e){return(e.flags&128)===128}function gw(e){if(ml(e))return!0;let n=e.parent;for(;n;){if(ml(e)||ZC(n))return!0;n=n.parent}return!1}var XC=(function(e){return e[e.OnPush=0]="OnPush",e[e.Default=1]="Default",e})(XC||{}),e_=new Map,Cw=0;function _w(){return Cw++}function vw(e){e_.set(e[Dl],e)}function Zm(e){e_.delete(e[Dl])}var l0="__ngContext__";function qo(e,n){yn(n)?(e[l0]=n[Dl],vw(n)):e[l0]=n}function t_(e){return i_(e[Br])}function n_(e){return i_(e[vn])}function i_(e){for(;e!==null&&!Rn(e);)e=e[vn];return e}var Qm;function o_(e){Qm=e}function Al(){if(Qm!==void 0)return Qm;if(typeof document<"u")return document;throw new J(210,!1)}var ti=new K("",{providedIn:"root",factory:()=>yw}),yw="ng",tf=new K(""),Zt=new K("",{providedIn:"platform",factory:()=>"unknown"});var nf=new K("",{providedIn:"root",factory:()=>Al().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function bw(){let e=new Jo;return e.store=xw(Al(),h(ti)),e}var Jo=(()=>{class e{static \u0275prov=O({token:e,providedIn:"root",factory:bw});store={};onSerializeCallbacks={};get(t,i){return this.store[t]!==void 0?this.store[t]:i}set(t,i){this.store[t]=i}remove(t){delete this.store[t]}hasKey(t){return this.store.hasOwnProperty(t)}get isEmpty(){return Object.keys(this.store).length===0}onSerialize(t,i){this.onSerializeCallbacks[t]=i}toJson(){for(let t in this.onSerializeCallbacks)if(this.onSerializeCallbacks.hasOwnProperty(t))try{this.store[t]=this.onSerializeCallbacks[t]()}catch(i){console.warn("Exception in onSerialize callback: ",i)}return JSON.stringify(this.store).replace(/</g,"\\u003C")}}return e})();function xw(e,n){let t=e.getElementById(n+"-state");if(t?.textContent)try{return JSON.parse(t.textContent)}catch(i){console.warn("Exception while restoring TransferState for app "+n,i)}return{}}var r_="h",a_="b",Sw="f",ww="n",Ew="e",Mw="t",of="c",s_="x",pl="r",Pw="i",Dw="n",l_="d";var Iw="di",Tw="s",Ow="p";var js=new K(""),c_=!1,d_=new K("",{providedIn:"root",factory:()=>c_});var u_=new K(""),Nw=!1,kw=new K(""),c0=new K("",{providedIn:"root",factory:()=>new Map}),rf=(function(e){return e[e.CHANGE_DETECTION=0]="CHANGE_DETECTION",e[e.AFTER_NEXT_RENDER=1]="AFTER_NEXT_RENDER",e})(rf||{}),Ko=new K(""),d0=new Set;function Vn(e){d0.has(e)||(d0.add(e),performance?.mark?.("mark_feature_usage",{detail:{feature:e}}))}var m_=(()=>{class e{view;node;constructor(t,i){this.view=t,this.node=i}static __NG_ELEMENT_ID__=Aw}return e})();function Aw(){return new m_(he(),Pt())}var To=(function(e){return e[e.EarlyRead=0]="EarlyRead",e[e.Write=1]="Write",e[e.MixedReadWrite=2]="MixedReadWrite",e[e.Read=3]="Read",e})(To||{}),p_=(()=>{class e{impl=null;execute(){this.impl?.execute()}static \u0275prov=O({token:e,providedIn:"root",factory:()=>new e})}return e})(),Rw=[To.EarlyRead,To.Write,To.MixedReadWrite,To.Read],Fw=(()=>{class e{ngZone=h(Ke);scheduler=h(Qi);errorHandler=h(kn,{optional:!0});sequences=new Set;deferredRegistrations=new Set;executing=!1;constructor(){h(Ko,{optional:!0})}execute(){let t=this.sequences.size>0;t&&Ee(16),this.executing=!0;for(let i of Rw)for(let o of this.sequences)if(!(o.erroredOrDestroyed||!o.hooks[i]))try{o.pipelinedValue=this.ngZone.runOutsideAngular(()=>this.maybeTrace(()=>{let r=o.hooks[i];return r(o.pipelinedValue)},o.snapshot))}catch(r){o.erroredOrDestroyed=!0,this.errorHandler?.handleError(r)}this.executing=!1;for(let i of this.sequences)i.afterRun(),i.once&&(this.sequences.delete(i),i.destroy());for(let i of this.deferredRegistrations)this.sequences.add(i);this.deferredRegistrations.size>0&&this.scheduler.notify(7),this.deferredRegistrations.clear(),t&&Ee(17)}register(t){let{view:i}=t;i!==void 0?((i[ko]??=[]).push(t),Qr(i),i[ae]|=8192):this.executing?this.deferredRegistrations.add(t):this.addSequence(t)}addSequence(t){this.sequences.add(t),this.scheduler.notify(7)}unregister(t){this.executing&&this.sequences.has(t)?(t.erroredOrDestroyed=!0,t.pipelinedValue=void 0,t.once=!0):(this.sequences.delete(t),this.deferredRegistrations.delete(t))}maybeTrace(t,i){return i?i.run(rf.AFTER_NEXT_RENDER,t):t()}static \u0275prov=O({token:e,providedIn:"root",factory:()=>new e})}return e})(),Xm=class{impl;hooks;view;once;snapshot;erroredOrDestroyed=!1;pipelinedValue=void 0;unregisterOnDestroy;constructor(n,t,i,o,r,c=null){this.impl=n,this.hooks=t,this.view=i,this.once=o,this.snapshot=c,this.unregisterOnDestroy=r?.onDestroy(()=>this.destroy())}afterRun(){this.erroredOrDestroyed=!1,this.pipelinedValue=void 0,this.snapshot?.dispose(),this.snapshot=null}destroy(){this.impl.unregister(this),this.unregisterOnDestroy?.();let n=this.view?.[ko];n&&(this.view[ko]=n.filter(t=>t!==this))}};function af(e,n){!n?.injector&&lC(af);let t=n?.injector??h(sn);return Vn("NgAfterNextRender"),Vw(e,t,n,!0)}function Lw(e,n){if(e instanceof Function){let t=[void 0,void 0,void 0,void 0];return t[n]=e,t}else return[e.earlyRead,e.write,e.mixedReadWrite,e.read]}function Vw(e,n,t,i){let o=n.get(p_);o.impl??=n.get(Fw);let r=n.get(Ko,null,{optional:!0}),c=t?.phase??To.MixedReadWrite,u=t?.manualCleanup!==!0?n.get(io):null,m=n.get(m_,null,{optional:!0}),f=new Xm(o.impl,Lw(e,c),m?.view,i,u,r?.snapshot(null));return o.impl.register(f),f}var Wt=(function(e){return e[e.NOT_STARTED=0]="NOT_STARTED",e[e.IN_PROGRESS=1]="IN_PROGRESS",e[e.COMPLETE=2]="COMPLETE",e[e.FAILED=3]="FAILED",e})(Wt||{}),u0=0,Uw=1,at=(function(e){return e[e.Placeholder=0]="Placeholder",e[e.Loading=1]="Loading",e[e.Complete=2]="Complete",e[e.Error=3]="Error",e})(at||{});var jw=0,Rl=1;var Bw=4,Hw=5;var $w=7,Ro=8,zw=9,f_=(function(e){return e[e.Manual=0]="Manual",e[e.Playthrough=1]="Playthrough",e})(f_||{});function Js(e,n){let t=Ww(e),i=n[t];if(i!==null){for(let o of i)o();n[t]=null}}function Gw(e){Js(1,e),Js(0,e),Js(2,e)}function Ww(e){let n=Bw;return e===1?n=Hw:e===2&&(n=zw),n}function h_(e){return e+1}function ea(e,n){let t=e[ie],i=h_(n.index);return e[i]}function Fl(e,n){let t=h_(n.index);return e.data[t]}function qw(e,n,t){let i=n[ie],o=Fl(i,t);switch(e){case at.Complete:return o.primaryTmplIndex;case at.Loading:return o.loadingTmplIndex;case at.Error:return o.errorTmplIndex;case at.Placeholder:return o.placeholderTmplIndex;default:return null}}function m0(e,n){return n===at.Placeholder?e.placeholderBlockConfig?.[u0]??null:n===at.Loading?e.loadingBlockConfig?.[u0]??null:null}function Jw(e){return e.loadingBlockConfig?.[Uw]??null}function p0(e,n){if(!e||e.length===0)return n;let t=new Set(e);for(let i of n)t.add(i);return e.length===t.size?e:Array.from(t)}function Kw(e,n){let t=n.primaryTmplIndex+Ge;return Zr(e,t)}var Ll="ngb";var Yw=(e,n,t)=>{let i=e,o=i.__jsaction_fns??new Map,r=o.get(n)??[];r.push(t),o.set(n,r),i.__jsaction_fns=o},Zw=(e,n)=>{let t=e,i=t.getAttribute(Ll)??"",o=n.get(i)??new Set;o.has(t)||o.add(t),n.set(i,o)};var Qw=e=>{e.removeAttribute(lm.JSACTION),e.removeAttribute(Ll),e.__jsaction_fns=void 0},Xw=new K("",{providedIn:"root",factory:()=>({})});function g_(e,n){let t=n?.__jsaction_fns?.get(e.type);if(!(!t||!n?.isConnected))for(let i of t)i(e)}var ep=new Map;
7function eE(e,n){return ep.set(e,n),()=>ep.delete(e)}var f0=!1,C_=(e,n,t,i)=>{};function tE(e,n,t,i){C_(e,n,t,i)}function nE(){f0||(C_=(e,n,t,i)=>{let o=e[Tn].get(ti);ep.get(o)?.(n,t,i)},f0=!0)}var sf=new K("");var iE="__nghData__",__=iE,oE="__nghDeferData__",rE=oE,vm="ngh",aE="nghm",v_=()=>null;function sE(e,n,t=!1){let i=e.getAttribute(vm);if(i==null)return null;let[o,r]=i.split("|");if(i=t?r:o,!i)return null;let c=r?`|${r}`:"",u=t?o:c,m={};if(i!==""){let C=n.get(Jo,null,{optional:!0});C!==null&&(m=C.get(__,[])[Number(i)])}let f={data:m,firstChild:e.firstChild??null};return t&&(f.firstChild=e,Vl(f,0,e.nextSibling)),u?e.setAttribute(vm,u):e.removeAttribute(vm),f}function lE(){v_=sE}function y_(e,n,t=!1){return v_(e,n,t)}function cE(e){let n=e._lView;return n[ie].type===2?null:(Hr(n)&&(n=n[Ge]),n)}function dE(e){return e.textContent?.replace(/\s/gm,"")}function uE(e){let n=Al(),t=n.createNodeIterator(e,NodeFilter.SHOW_COMMENT,{acceptNode(r){let c=dE(r);return c==="ngetn"||c==="ngtns"?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_REJECT}}),i,o=[];for(;i=t.nextNode();)o.push(i);for(let r of o)r.textContent==="ngetn"?r.replaceWith(n.createTextNode("")):r.remove()}function Vl(e,n,t){e.segmentHeads??={},e.segmentHeads[n]=t}function tp(e,n){return e.segmentHeads?.[n]??null}function mE(e){return e.get(kw,!1,{optional:!0})}function pE(e,n){let t=e.data,i=t[Ew]?.[n]??null;return i===null&&t[of]?.[n]&&(i=lf(e,n)),i}function b_(e,n){return e.data[of]?.[n]??null}function lf(e,n){let t=b_(e,n)??[],i=0;for(let o of t)i+=o[pl]*(o[s_]??1);return i}function fE(e){if(typeof e.disconnectedNodes>"u"){let n=e.data[l_];e.disconnectedNodes=n?new Set(n):null}return e.disconnectedNodes}function ta(e,n){if(typeof e.disconnectedNodes>"u"){let t=e.data[l_];e.disconnectedNodes=t?new Set(t):null}return!!fE(e)?.has(n)}function hE(e,n){let t=n.get(sf),o=n.get(Jo).get(rE,{}),r=!1,c=e,u=null,m=[];for(;!r&&c;){r=t.has(c);let f=t.hydrating.get(c);if(u===null&&f!=null){u=f.promise;break}m.unshift(c),c=o[c][Ow]}return{parentBlockPromise:u,hydrationQueue:m}}function ym(e){return!!e&&e.nodeType===Node.COMMENT_NODE&&e.textContent?.trim()===aE}function h0(e){for(;e&&e.nodeType===Node.TEXT_NODE;)e=e.previousSibling;return e}function gE(e){for(let i of e.body.childNodes)if(ym(i))return;let n=h0(e.body.previousSibling);if(ym(n))return;let t=h0(e.head.lastChild);if(!ym(t))throw new J(-507,!1)}function x_(e,n){let t=e.contentQueries;if(t!==null){let i=fe(null);try{for(let o=0;o<t.length;o+=2){let r=t[o],c=t[o+1];if(c!==-1){let u=e.data[c];Gp(r),u.contentQueries(2,n[c],c)}}}finally{fe(i)}}}function np(e,n,t){Gp(0);let i=fe(null);try{n(e,t)}finally{fe(i)}}function cf(e,n,t){if(Up(n)){let i=fe(null);try{let o=n.directiveStart,r=n.directiveEnd;for(let c=o;c<r;c++){let u=e.data[c];if(u.contentQueries){let m=t[c];u.contentQueries(1,m,c)}}}finally{fe(i)}}}var An=(function(e){return e[e.Emulated=0]="Emulated",e[e.None=2]="None",e[e.ShadowDom=3]="ShadowDom",e})(An||{});var Bs;function CE(){if(Bs===void 0&&(Bs=null,bi.trustedTypes))try{Bs=bi.trustedTypes.createPolicy("angular#unsafe-bypass",{createHTML:e=>e,createScript:e=>e,createScriptURL:e=>e})}catch{}return Bs}function g0(e){return CE()?.createScriptURL(e)||e}var fl=class{changingThisBreaksApplicationSecurity;constructor(n){this.changingThisBreaksApplicationSecurity=n}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${B0})`}};function na(e){return e instanceof fl?e.changingThisBreaksApplicationSecurity:e}function df(e,n){let t=_E(e);if(t!=null&&t!==n){if(t==="ResourceURL"&&n==="URL")return!0;throw new Error(`Required a safe ${n}, got a ${t} (see ${B0})`)}return t===n}function _E(e){return e instanceof fl&&e.getTypeName()||null}var vE=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:\/?#]*(?:[\/?#]|$))/i;function S_(e){return e=String(e),e.match(vE)?e:"unsafe:"+e}var yE=/^>|^->|<!--|-->|--!>|<!-$/g,bE=/(<|>)/g,xE="\u200B$1\u200B";function SE(e){return e.replace(yE,n=>n.replace(bE,xE))}function w_(e,n){return e.createText(n)}function wE(e,n,t){e.setValue(n,t)}function E_(e,n){return e.createComment(SE(n))}function uf(e,n,t){return e.createElement(n,t)}function hl(e,n,t,i,o){e.insertBefore(n,t,i,o)}function M_(e,n,t){e.appendChild(n,t)}function C0(e,n,t,i,o){i!==null?hl(e,n,t,i,o):M_(e,n,t)}function mf(e,n,t){e.removeChild(null,n,t)}function P_(e){e.textContent=""}function EE(e,n,t){e.setAttribute(n,"style",t)}function ME(e,n,t){t===""?e.removeAttribute(n,"class"):e.setAttribute(n,"class",t)}function D_(e,n,t){let{mergedAttrs:i,classes:o,styles:r}=t;i!==null&&BS(e,n,i),o!==null&&ME(e,n,o),r!==null&&EE(e,n,r)}var Ul=(function(e){return e[e.NONE=0]="NONE",e[e.HTML=1]="HTML",e[e.STYLE=2]="STYLE",e[e.SCRIPT=3]="SCRIPT",e[e.URL=4]="URL",e[e.RESOURCE_URL=5]="RESOURCE_URL",e[e.ATTRIBUTE_NO_BINDING=6]="ATTRIBUTE_NO_BINDING",e})(Ul||{});function Y(e){let n=T_();return n?n.sanitize(Ul.URL,e)||"":df(e,"URL")?na(e):S_(ei(e))}function PE(e){let n=T_();if(n)return g0(n.sanitize(Ul.RESOURCE_URL,e)||"");if(df(e,"ResourceURL"))return g0(na(e));throw new J(904,!1)}var DE={embed:{src:!0},frame:{src:!0},iframe:{src:!0},media:{src:!0},base:{href:!0},link:{href:!0},object:{data:!0,codebase:!0}};function IE(e,n){return DE[e.toLowerCase()]?.[n.toLowerCase()]===!0?PE:Y}function I_(e,n,t){return IE(n,t)(e)}function TE(e){if(e.toLowerCase().startsWith("on"))throw new J(306,!1)}
vendor: 15,276 bytes, line 7
7function T_(){let e=he();return e&&e[ni].sanitizer}function O_(e){return e.ownerDocument}function OE(e){return e.ownerDocument.body}function N_(e){return e instanceof Function?e():e}function NE(e,n,t){let i=e.length;for(;;){let o=e.indexOf(n,t);if(o===-1)return o;if(o===0||e.charCodeAt(o-1)<=32){let r=n.length;if(o+r===i||e.charCodeAt(o+r)<=32)return o}t=o+1}}var k_="ng-template";function kE(e,n,t,i){let o=0;if(i){for(;o<n.length&&typeof n[o]=="string";o+=2)if(n[o]==="class"&&NE(n[o+1].toLowerCase(),t,0)!==-1)return!0}else if(pf(e))return!1;if(o=n.indexOf(1,o),o>-1){let r;for(;++o<n.length&&typeof(r=n[o])=="string";)if(r.toLowerCase()===t)return!0}return!1}function pf(e){return e.type===4&&e.value!==k_}function AE(e,n,t){let i=e.type===4&&!t?k_:e.value;return n===i}function RE(e,n,t){let i=4,o=e.attrs,r=o!==null?VE(o):0,c=!1;for(let u=0;u<n.length;u++){let m=n[u];if(typeof m=="number"){if(!c&&!Cn(i)&&!Cn(m))return!1;if(c&&Cn(m))continue;c=!1,i=m|i&1;continue}if(!c)if(i&4){if(i=2|i&1,m!==""&&!AE(e,m,t)||m===""&&n.length===1){if(Cn(i))return!1;c=!0}}else if(i&8){if(o===null||!kE(e,o,m,t)){if(Cn(i))return!1;c=!0}}else{let f=n[++u],C=FE(m,o,pf(e),t);if(C===-1){if(Cn(i))return!1;c=!0;continue}if(f!==""){let b;if(C>r?b="":b=o[C+1].toLowerCase(),i&2&&f!==b){if(Cn(i))return!1;c=!0}}}}return Cn(i)||c}function Cn(e){return(e&1)===0}function FE(e,n,t,i){if(n===null)return-1;let o=0;if(i||!t){let r=!1;for(;o<n.length;){let c=n[o];if(c===e)return o;if(c===3||c===6)r=!0;else if(c===1||c===2){let u=n[++o];for(;typeof u=="string";)u=n[++o];continue}else{if(c===4)break;if(c===0){o+=4;continue}}o+=r?1:2}return-1}else return UE(n,e)}function LE(e,n,t=!1){for(let i=0;i<n.length;i++)if(RE(e,n[i],t))return!0;return!1}function VE(e){for(let n=0;n<e.length;n++){let t=e[n];if(kC(t))return n}return e.length}function UE(e,n){let t=e.indexOf(4);if(t>-1)for(t++;t<e.length;){let i=e[t];if(typeof i=="number")return-1;if(i===n)return t;t++}return-1}function _0(e,n){return e?":not("+n.trim()+")":n}function jE(e){let n=e[0],t=1,i=2,o="",r=!1;for(;t<e.length;){let c=e[t];if(typeof c=="string")if(i&2){let u=e[++t];o+="["+c+(u.length>0?'="'+u+'"':"")+"]"}else i&8?o+="."+c:i&4&&(o+=" "+c);else o!==""&&!Cn(c)&&(n+=_0(r,o),o=""),i=c,r=r||!Cn(i);t++}return o!==""&&(n+=_0(r,o)),n}function BE(e){return e.map(jE).join(",")}function HE(e){let n=[],t=[],i=1,o=2;for(;i<e.length;){let r=e[i];if(typeof r=="string")o===2?r!==""&&n.push(r,e[++i]):o===8&&t.push(r);else{if(!Cn(o))break;o=r}i++}return t.length&&n.push(1,...t),n}var Vt={};function ff(e,n,t,i,o,r,c,u,m,f,C){let b=Ge+i,P=b+o,x=$E(b,P),D=typeof f=="function"?f():f;return x[ie]={type:e,blueprint:x,template:t,queries:null,viewQuery:u,declTNode:n,data:x.slice().fill(null,b),bindingStartIndex:b,expandoStartIndex:P,hostBindingOpCodes:null,firstCreatePass:!0,firstUpdatePass:!0,staticViewQueries:!1,staticContentQueries:!1,preOrderHooks:null,preOrderCheckHooks:null,contentHooks:null,contentCheckHooks:null,viewHooks:null,viewCheckHooks:null,destroyHooks:null,cleanup:null,contentQueries:null,components:null,directiveRegistry:typeof r=="function"?r():r,pipeRegistry:typeof c=="function"?c():c,firstChild:null,schemas:m,consts:D,incompleteFirstPass:!1,ssrId:C}}function $E(e,n){let t=[];for(let i=0;i<n;i++)t.push(i<e?null:Vt);return t}function zE(e){let n=e.tView;return n===null||n.incompleteFirstPass?e.tView=ff(1,null,e.template,e.decls,e.vars,e.directiveDefs,e.pipeDefs,e.viewQuery,e.schemas,e.consts,e.id):n}function hf(e,n,t,i,o,r,c,u,m,f,C){let b=n.blueprint.slice();return b[qt]=o,b[ae]=i|4|128|8|64|1024,(f!==null||e&&e[ae]&2048)&&(b[ae]|=2048),CC(b),b[lt]=b[zo]=e,b[st]=t,b[ni]=c||e&&e[ni],b[Fe]=u||e&&e[Fe],b[Tn]=m||e&&e[Tn]||null,b[Sn]=r,b[Dl]=_w(),b[bn]=C,b[cC]=f,b[Jt]=n.type==2?e[Jt]:b,b}function GE(e,n,t){let i=wn(n,e),o=zE(t),r=e[ni].rendererFactory,c=gf(e,hf(e,o,null,A_(t),i,n,null,r.createRenderer(i,t),null,null,null));return e[n.index]=c}function A_(e){let n=16;return e.signals?n=4096:e.onPush&&(n=64),n}function R_(e,n,t,i){if(t===0)return-1;let o=n.length;for(let r=0;r<t;r++)n.push(i),e.blueprint.push(i),e.data.push(null);return o}function gf(e,n){return e[Br]?e[Yg][vn]=n:e[Br]=n,e[Yg]=n,n}function d(e=1){F_(Xe(),he(),Fn()+e,!1)}function F_(e,n,t,i){if(!i)if((n[ae]&3)===3){let r=e.preOrderCheckHooks;r!==null&&Gs(n,r,t)}else{let r=e.preOrderHooks;r!==null&&Ws(n,r,0,t)}Yi(t)}var jl=(function(e){return e[e.None=0]="None",e[e.SignalBased=1]="SignalBased",e[e.HasDecoratorInputTransform=2]="HasDecoratorInputTransform",e})(jl||{});function ip(e,n,t,i){let o=fe(null);try{let[r,c,u]=e.inputs[t],m=null;(c&jl.SignalBased)!==0&&(m=n[r][rn]),m!==null&&m.transformFn!==void 0?i=m.transformFn(i):u!==null&&(i=u.call(n,i)),e.setInput!==null?e.setInput(n,m,i,t,r):uC(n,m,r,i)}finally{fe(o)}}function L_(e,n,t,i,o){let r=Fn(),c=i&2;try{Yi(-1),c&&n.length>Ge&&F_(e,n,Ge,!1),Ee(c?2:0,o),t(i,o)}finally{Yi(r),Ee(c?3:1,o)}}function Bl(e,n,t){QE(e,n,t),(t.flags&64)===64&&XE(e,n,t)}function Cf(e,n,t=wn){let i=n.localNames;if(i!==null){let o=n.index+1;for(let r=0;r<i.length;r+=2){let c=i[r+1],u=c===-1?t(n,e):e[c];e[o++]=u}}}function WE(e,n,t,i){let r=i.get(d_,c_)||t===An.ShadowDom,c=e.selectRootElement(n,r);if(c?.tagName?.toLowerCase()==="script")throw new J(905,!1);return qE(c),c}function qE(e){V_(e)}var V_=()=>null;function JE(e){QC(e)?P_(e):uE(e)}function KE(){V_=JE}function YE(e){return e==="class"?"className":e==="for"?"htmlFor":e==="formaction"?"formAction":e==="innerHtml"?"innerHTML":e==="readonly"?"readOnly":e==="tabindex"?"tabIndex":e}function U_(e,n,t,i,o,r,c,u){if(!u&&yf(n,e,t,i,o)){eo(n)&&ZE(t,n.index);return}if(n.type&3){let m=wn(n,t);i=YE(i),o=c!=null?c(o,n.value||"",i):o,r.setProperty(m,i,o)}else n.type&12}function ZE(e,n){let t=Nn(n,e);t[ae]&16||(t[ae]|=64)}function QE(e,n,t){let i=t.directiveStart,o=t.directiveEnd;eo(t)&&GE(n,t,e.data[i+t.componentOffset]),e.firstCreatePass||cl(t,n);let r=t.initialInputs;for(let c=i;c<o;c++){let u=e.data[c],m=$r(n,e,c,t);if(qo(m,n),r!==null&&iM(n,c-i,m,u,t,r),On(u)){let f=Nn(t.index,n);f[st]=$r(n,e,c,t)}}}function XE(e,n,t){let i=t.directiveStart,o=t.directiveEnd,r=t.index,c=kS();try{Yi(r);for(let u=i;u<o;u++){let m=e.data[u],f=n[u];Hm(u),(m.hostBindings!==null||m.hostVars!==0||m.hostAttrs!==null)&&eM(m,f)}}finally{Yi(-1),Hm(c)}}function eM(e,n){e.hostBindings!==null&&e.hostBindings(1,n)}function _f(e,n){let t=e.directiveRegistry,i=null;if(t)for(let o=0;o<t.length;o++){let r=t[o];LE(n,r.selectors,!1)&&(i??=[],On(r)?i.unshift(r):i.push(r))}return i}function tM(e,n,t,i,o,r){n[ie].firstUpdatePass&&TE(t);let c=wn(e,n);nM(n[Fe],c,r,e.value,t,i,o)}function nM(e,n,t,i,o,r,c){if(r==null)e.removeAttribute(n,o,t);else{let u=c==null?ei(r):c(r,i||"",o);e.setAttribute(n,o,u,t)}}function iM(e,n,t,i,o,r){let c=r[n];if(c!==null)for(let u=0;u<c.length;u+=2){let m=c[u],f=c[u+1];ip(i,t,m,f)}}function vf(e,n){let t=e[Tn],i=t?t.get(kn,null):null;i&&i.handleError(n)}function yf(e,n,t,i,o){let r=e.inputs?.[i],c=e.hostDirectiveInputs?.[i],u=!1;if(c)for(let m=0;m<c.length;m+=2){let f=c[m],C=c[m+1],b=n.data[f];ip(b,t[f],C,o),u=!0}if(r)for(let m of r){let f=t[m],C=n.data[m];ip(C,f,i,o),u=!0}return u}function oM(e,n){let t=Nn(n,e),i=t[ie];rM(i,t);let o=t[qt];o!==null&&t[bn]===null&&(t[bn]=y_(o,t[Tn])),Ee(18),bf(i,t,t[st]),Ee(19,t[st])}function rM(e,n){for(let t=n.length;t<e.blueprint.length;t++)n.push(e.blueprint[t])}function bf(e,n,t){Wp(n);try{let i=e.viewQuery;i!==null&&np(1,i,t);let o=e.template;o!==null&&L_(e,n,o,1,t),e.firstCreatePass&&(e.firstCreatePass=!1),n[ii]?.finishViewCreation(e),e.staticContentQueries&&x_(e,n),e.staticViewQueries&&np(2,e.viewQuery,t);let r=e.components;r!==null&&aM(n,r)}catch(i){throw e.firstCreatePass&&(e.incompleteFirstPass=!0,e.firstCreatePass=!1),i}finally{n[ae]&=-5,qp()}}function aM(e,n){for(let t=0;t<n.length;t++)oM(e,n[t])}function ia(e,n,t,i){let o=fe(null);try{let r=n.tView,u=e[ae]&4096?4096:16,m=hf(e,r,t,u,null,n,null,null,i?.injector??null,i?.embeddedViewInjector??null,i?.dehydratedView??null),f=e[n.index];m[Ji]=f;let C=e[ii];return C!==null&&(m[ii]=C.createEmbeddedView(r)),bf(r,m,t),m}finally{fe(o)}}function jo(e,n){return!n||n.firstChild===null||ml(e)}var sM;function xf(e,n){return sM(e,n)}var ai=(function(e){return e[e.Important=1]="Important",e[e.DashCase=2]="DashCase",e})(ai||{});function Yo(e){return(e.flags&32)===32}function Oo(e,n,t,i,o){if(i!=null){let r,c=!1;Rn(i)?r=i:yn(i)&&(c=!0,i=i[qt]);let u=xn(i);e===0&&t!==null?o==null?M_(n,t,u):hl(n,t,u,o||null,!0):e===1&&t!==null?hl(n,t,u,o||null,!0):e===2?mf(n,u,c):e===3&&n.destroyNode(u),r!=null&&vM(n,e,r,t,o)}}function lM(e,n){j_(e,n),n[qt]=null,n[Sn]=null}function cM(e,n,t,i,o,r){i[qt]=o,i[Sn]=n,zl(e,i,t,1,o,r)}function j_(e,n){n[ni].changeDetectionScheduler?.notify(9),zl(e,n,n[Fe],2,null,null)}function dM(e){let n=e[Br];if(!n)return bm(e[ie],e);for(;n;){let t=null;if(yn(n))t=n[Br];else{let i=n[ht];i&&(t=i)}if(!t){for(;n&&!n[vn]&&n!==e;)yn(n)&&bm(n[ie],n),n=n[lt];n===null&&(n=e),yn(n)&&bm(n[ie],n),t=n&&n[vn]}n=t}}function Sf(e,n){let t=e[Vo],i=t.indexOf(n);t.splice(i,1)}function Hl(e,n){if(to(n))return;let t=n[Fe];t.destroyNode&&zl(e,n,t,3,null,null),dM(n)}function bm(e,n){if(to(n))return;let t=fe(null);try{n[ae]&=-129,n[ae]|=256,n[an]&&Au(n[an]),mM(e,n),uM(e,n),n[ie].type===1&&n[Fe].destroy();let i=n[Ji];if(i!==null&&Rn(n[lt])){i!==n[lt]&&Sf(i,n);let o=n[ii];o!==null&&o.detachView(e)}Zm(n)}finally{fe(t)}}function uM(e,n){let t=e.cleanup,i=n[il];if(t!==null)for(let c=0;c<t.length-1;c+=2)if(typeof t[c]=="string"){let u=t[c+3];u>=0?i[u]():i[-u].unsubscribe(),c+=2}else{let u=i[t[c+1]];t[c].call(u)}i!==null&&(n[il]=null);let o=n[xi];if(o!==null){n[xi]=null;for(let c=0;c<o.length;c++){let u=o[c];u()}}let r=n[ol];if(r!==null){n[ol]=null;for(let c of r)c.destroy()}}function mM(e,n){let t;if(e!=null&&(t=e.destroyHooks)!=null)for(let i=0;i<t.length;i+=2){let o=n[t[i]];if(!(o instanceof Zi)){let r=t[i+1];if(Array.isArray(r))for(let c=0;c<r.length;c+=2){let u=o[r[c]],m=r[c+1];Ee(4,u,m);try{m.call(u)}finally{Ee(5,u,m)}}else{Ee(4,o,r);try{r.call(o)}finally{Ee(5,o,r)}}}}}function pM(e,n,t){return fM(e,n.parent,t)}function fM(e,n,t){let i=n;for(;i!==null&&i.type&168;)n=i,i=n.parent;if(i===null)return t[qt];if(eo(i)){let{encapsulation:o}=e.data[i.directiveStart+i.componentOffset];if(o===An.None||o===An.Emulated)return null}return wn(i,t)}function hM(e,n,t){return CM(e,n,t)}function gM(e,n,t){return e.type&40?wn(e,t):null}var CM=gM,v0;function $l(e,n,t,i){let o=pM(e,i,n),r=n[Fe],c=i.parent||n[Sn],u=hM(c,i,n);if(o!=null)if(Array.isArray(t))for(let m=0;m<t.length;m++)C0(r,o,t[m],u,!1);else C0(r,o,t,u,!1);v0!==void 0&&v0(r,i,n,t,o)}function Vr(e,n){if(n!==null){let t=n.type;if(t&3)return wn(n,e);if(t&4)return op(-1,e[n.index]);if(t&8){let i=n.child;if(i!==null)return Vr(e,i);{let o=e[n.index];return Rn(o)?op(-1,o):xn(o)}}else{if(t&128)return Vr(e,n.next);if(t&32)return xf(n,e)()||xn(e[n.index]);{let i=B_(e,n);if(i!==null){if(Array.isArray(i))return i[0];let o=Ki(e[Jt]);return Vr(o,i)}else return Vr(e,n.next)}}}return null}function B_(e,n){if(n!==null){let i=e[Jt][Sn],o=n.projection;return i.projection[o]}return null}function op(e,n){let t=ht+e+1;if(t<n.length){let i=n[t],o=i[ie].firstChild;if(o!==null)return Vr(i,o)}return n[ri]}function wf(e,n,t,i,o,r,c){for(;t!=null;){if(t.type===128){t=t.next;continue}let u=i[t.index],m=t.type;if(c&&n===0&&(u&&qo(xn(u),i),t.flags|=2),!Yo(t))if(m&8)wf(e,n,t.child,i,o,r,!1),Oo(n,e,o,u,r);else if(m&32){let f=xf(t,i),C;for(;C=f();)Oo(n,e,o,C,r);Oo(n,e,o,u,r)}else m&16?_M(e,n,i,t,o,r):Oo(n,e,o,u,r);t=c?t.projectionNext:t.next}}function zl(e,n,t,i,o,r){wf(t,i,e.firstChild,n,o,r,!1)}function _M(e,n,t,i,o,r){let c=t[Jt],m=c[Sn].projection[i.projection];if(Array.isArray(m))for(let f=0;f<m.length;f++){let C=m[f];Oo(n,e,o,C,r)}else{let f=m,C=c[lt];ml(i)&&(f.flags|=128),wf(e,n,f,C,o,r,!0)}}function vM(e,n,t,i,o){let r=t[ri],c=xn(t);r!==c&&Oo(n,e,i,r,o);for(let u=ht;u<t.length;u++){let m=t[u];zl(m[ie],m,e,n,i,r)}}function yM(e,n,t,i,o){if(n)o?e.addClass(t,i):e.removeClass(t,i);else{let r=i.indexOf("-")===-1?void 0:ai.DashCase;o==null?e.removeStyle(t,i,r):(typeof o=="string"&&o.endsWith("!important")&&(o=o.slice(0,-10),r|=ai.Important),e.setStyle(t,i,o,r))}}function gl(e,n,t,i,o=!1){for(;t!==null;){if(t.type===128){t=o?t.projectionNext:t.next;continue}let r=n[t.index];r!==null&&i.push(xn(r)),Rn(r)&&bM(r,i);let c=t.type;if(c&8)gl(e,n,t.child,i);else if(c&32){let u=xf(t,n),m;for(;m=u();)i.push(m)}else if(c&16){let u=B_(n,t);if(Array.isArray(u))i.push(...u);else{let m=Ki(n[Jt]);gl(m[ie],m,u,i,!0)}}t=o?t.projectionNext:t.next}return i}function bM(e,n){for(let t=ht;t<e.length;t++){let i=e[t],o=i[ie].firstChild;o!==null&&gl(i[ie],i,o,n)}e[ri]!==e[qt]&&n.push(e[ri])}function H_(e){if(e[ko]!==null){for(let n of e[ko])n.impl.addSequence(n);e[ko].length=0}}var $_=[];function xM(e){return e[an]??SM(e)}function SM(e){let n=$_.pop()??Object.create(EM);return n.lView=e,n}function wM(e){e.lView[an]!==e&&(e.lView=null,$_.push(e))}var EM=oe(U({},Ir),{consumerIsAlwaysLive:!0,kind:"template",consumerMarkedDirty:e=>{Qr(e.lView)},consumerOnSignalRead(){this.lView[an]=this}});function MM(e){let n=e[an]??Object.create(PM);return n.lView=e,n}var PM=oe(U({},Ir),{consumerIsAlwaysLive:!0,kind:"template",consumerMarkedDirty:e=>{let n=Ki(e.lView);for(;n&&!z_(n[ie]);)n=Ki(n);n&&_C(n)},consumerOnSignalRead(){this.lView[an]=this}});function z_(e){return e.type!==2}function G_(e){if(e[ol]===null)return;let n=!0;for(;n;){let t=!1;for(let i of e[ol])i.dirty&&(t=!0,i.zone===null||Zone.current===i.zone?i.run():i.zone.run(()=>i.run()));n=t&&!!(e[ae]&8192)}}var DM=100;function W_(e,n=!0,t=0){let o=e[ni].rendererFactory,r=!1;r||o.begin?.();try{IM(e,t)}catch(c){throw n&&vf(e,c),c}finally{r||o.end?.()}}function IM(e,n){let t=xC();try{Qg(!0),rp(e,n);let i=0;for(;Tl(e);){if(i===DM)throw new J(103,!1);i++,rp(e,1)}}finally{Qg(t)}}function TM(e,n,t,i){if(to(n))return;let o=n[ae],r=!1,c=!1;Wp(n);let u=!0,m=null,f=null;r||(z_(e)?(f=xM(n),m=as(f)):Du()===null?(u=!1,f=MM(n),m=as(f)):n[an]&&(Au(n[an]),n[an]=null));try{CC(n),TS(e.bindingStartIndex),t!==null&&L_(e,n,t,2,i);let C=(o&3)===3;if(!r)if(C){let x=e.preOrderCheckHooks;x!==null&&Gs(n,x,null)}else{let x=e.preOrderHooks;x!==null&&Ws(n,x,0,null),Cm(n,0)}if(c||OM(n),G_(n),q_(n,0),e.contentQueries!==null&&x_(e,n),!r)if(C){let x=e.contentCheckHooks;x!==null&&Gs(n,x)}else{let x=e.contentHooks;x!==null&&Ws(n,x,1),Cm(n,1)}kM(e,n);let b=e.components;b!==null&&K_(n,b,0);let P=e.viewQuery;if(P!==null&&np(2,P,i),!r)if(C){let x=e.viewCheckHooks;x!==null&&Gs(n,x)}else{let x=e.viewHooks;x!==null&&Ws(n,x,2),Cm(n,2)}if(e.firstUpdatePass===!0&&(e.firstUpdatePass=!1),n[gm]){for(let x of n[gm])x();n[gm]=null}r||(H_(n),n[ae]&=-73)}catch(C){throw r||Qr(n),C}finally{f!==null&&(Nu(f,m),u&&wM(f)),qp()}}function q_(e,n){for(let t=t_(e);t!==null;t=n_(t))for(let i=ht;i<t.length;i++){let o=t[i];J_(o,n)}}function OM(e){for(let n=t_(e);n!==null;n=n_(n)){if(!(n[ae]&2))continue;let t=n[Vo];for(let i=0;i<t.length;i++){let o=t[i];_C(o)}}}function NM(e,n,t){Ee(18);let i=Nn(n,e);J_(i,t),Ee(19,i[st])}function J_(e,n){jp(e)&&rp(e,n)}function rp(e,n){let i=e[ie],o=e[ae],r=e[an],c=!!(n===0&&o&16);if(c||=!!(o&64&&n===0),c||=!!(o&1024),c||=!!(r?.dirty&&ku(r)),c||=!1,r&&(r.dirty=!1),e[ae]&=-9217,c)TM(i,e,i.template,e[st]);
7else if(o&8192){G_(e),q_(e,1);let u=i.components;u!==null&&K_(e,u,1),H_(e)}}function K_(e,n,t){for(let i=0;i<n.length;i++)NM(e,n[i],t)}function kM(e,n){let t=e.hostBindingOpCodes;if(t!==null)try{for(let i=0;i<t.length;i++){let o=t[i];if(o<0)Yi(~o);else{let r=o,c=t[++i],u=t[++i];NS(c,r);let m=n[r];Ee(24,m),u(2,m),Ee(25,m)}}}finally{Yi(-1)}}function Gl(e,n){let t=xC()?64:1088;for(e[ni].changeDetectionScheduler?.notify(n);e;){e[ae]|=t;let i=Ki(e);if(Hr(e)&&!i)return e;e=i}return null}function Y_(e,n,t,i){return[e,!0,0,n,null,i,null,t,null,null]}function Z_(e,n){let t=ht+n;if(t<e.length)return e[t]}function oa(e,n,t,i=!0){let o=n[ie];if(AM(o,n,e,t),i){let c=op(t,e),u=n[Fe],m=u.parentNode(e[ri]);m!==null&&cM(o,e[Sn],u,n,m,c)}let r=n[bn];r!==null&&r.firstChild!==null&&(r.firstChild=null)}function Ef(e,n){let t=zr(e,n);return t!==void 0&&Hl(t[ie],t),t}function zr(e,n){if(e.length<=ht)return;let t=ht+n,i=e[t];if(i){let o=i[Ji];o!==null&&o!==e&&Sf(o,i),n>0&&(e[t-1][vn]=i[vn]);let r=tl(e,ht+n);lM(i[ie],i);let c=r[ii];c!==null&&c.detachView(r[ie]),i[lt]=null,i[vn]=null,i[ae]&=-129}return i}function AM(e,n,t,i){let o=ht+i,r=t.length;i>0&&(t[o-1][vn]=n),i<r-ht?(n[vn]=t[o],Q0(t,ht+i,n)):(t.push(n),n[vn]=null),n[lt]=t;let c=n[Ji];c!==null&&t!==c&&Q_(c,n);let u=n[ii];u!==null&&u.insertView(e),jm(n),n[ae]|=128}function Q_(e,n){let t=e[Vo],i=n[lt];if(yn(i))e[ae]|=2;else{let o=i[lt][Jt];n[Jt]!==o&&(e[ae]|=2)}t===null?e[Vo]=[n]:t.push(n)}var Gr=class{_lView;_cdRefInjectingView;notifyErrorHandler;_appRef=null;_attachedToViewContainer=!1;get rootNodes(){let n=this._lView,t=n[ie];return gl(t,n,t.firstChild,[])}constructor(n,t,i=!0){this._lView=n,this._cdRefInjectingView=t,this.notifyErrorHandler=i}get context(){return this._lView[st]}set context(n){this._lView[st]=n}get destroyed(){return to(this._lView)}destroy(){if(this._appRef)this._appRef.detachView(this);else if(this._attachedToViewContainer){let n=this._lView[lt];if(Rn(n)){let t=n[rl],i=t?t.indexOf(this):-1;i>-1&&(zr(n,i),tl(t,i))}this._attachedToViewContainer=!1}Hl(this._lView[ie],this._lView)}onDestroy(n){vC(this._lView,n)}markForCheck(){Gl(this._cdRefInjectingView||this._lView,4)}detach(){this._lView[ae]&=-129}reattach(){jm(this._lView),this._lView[ae]|=128}detectChanges(){this._lView[ae]|=1024,W_(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new J(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null;let n=Hr(this._lView),t=this._lView[Ji];t!==null&&!n&&Sf(t,this._lView),j_(this._lView[ie],this._lView)}attachToAppRef(n){if(this._attachedToViewContainer)throw new J(902,!1);this._appRef=n;let t=Hr(this._lView),i=this._lView[Ji];i!==null&&!t&&Q_(i,this._lView),jm(this._lView)}};var Wr=(()=>{class e{static __NG_ELEMENT_ID__=LM}return e})(),RM=Wr,FM=class extends RM{_declarationLView;_declarationTContainer;elementRef;constructor(n,t,i){super(),this._declarationLView=n,this._declarationTContainer=t,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(n,t){return this.createEmbeddedViewImpl(n,t)}createEmbeddedViewImpl(n,t,i){let o=ia(this._declarationLView,this._declarationTContainer,n,{embeddedViewInjector:t,dehydratedView:i});return new Gr(o)}};function LM(){return Wl(Pt(),he())}function Wl(e,n){return e.type&4?new FM(n,e,Wo(e,n)):null}function ql(e,n,t,i,o){let r=e.data[n];if(r===null)r=VM(e,n,t,i,o),OS()&&(r.flags|=32);else if(r.type&64){r.type=t,r.value=i,r.attrs=o;let c=DS();r.injectorIndex=c===null?-1:c.injectorIndex}return no(r,!0),r}function VM(e,n,t,i,o){let r=yC(),c=zp(),u=c?r:r&&r.parent,m=e.data[n]=jM(e,u,t,n,i,o);return UM(e,m,r,c),m}function UM(e,n,t,i){e.firstChild===null&&(e.firstChild=n),t!==null&&(i?t.child==null&&n.parent!==null&&(t.child=n):t.next===null&&(t.next=n,n.prev=t))}function jM(e,n,t,i,o,r){let c=n?n.injectorIndex:-1,u=0;return Xr()&&(u|=128),{type:t,index:i,insertBeforeIndex:null,injectorIndex:c,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:u,providerIndexes:0,value:o,namespace:Kp(),attrs:r,mergedAttrs:null,localNames:null,initialInputs:null,inputs:null,hostDirectiveInputs:null,outputs:null,hostDirectiveOutputs:null,directiveToIndex:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:n,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}var BM=new RegExp(`^(\\d+)*(${a_}|${r_})*(.*)`);function HM(e){let n=e.match(BM),[t,i,o,r]=n,c=i?parseInt(i,10):o,u=[];for(let[m,f,C]of r.matchAll(/(f|n)(\d*)/g)){let b=parseInt(C,10)||1;u.push(f,b)}return[c,...u]}function $M(e){return!e.prev&&e.parent?.type===8}function xm(e){return e.index-Ge}function zM(e,n){let t=e.i18nNodes;if(t)return t.get(n)}function Jl(e,n,t,i){let o=xm(i),r=zM(e,o);if(r===void 0){let c=e.data[Dw];if(c?.[o])r=WM(c[o],t);else if(n.firstChild===i)r=e.firstChild;else{let u=i.prev===null,m=i.prev??i.parent;if($M(i)){let f=xm(i.parent);r=tp(e,f)}else{let f=wn(m,t);if(u)r=f.firstChild;else{let C=xm(m),b=tp(e,C);if(m.type===2&&b){let x=lf(e,C)+1;r=Kl(x,b)}else r=f.nextSibling}}}}return r}function Kl(e,n){let t=n;for(let i=0;i<e;i++)t=t.nextSibling;return t}function GM(e,n){let t=e;for(let i=0;i<n.length;i+=2){let o=n[i],r=n[i+1];for(let c=0;c<r;c++)switch(o){case Sw:t=t.firstChild;break;case ww:t=t.nextSibling;break}}return t}function WM(e,n){let[t,...i]=HM(e),o;if(t===r_)o=n[Jt][qt];else if(t===a_)o=OE(n[Jt][qt]);else{let r=Number(t);o=xn(n[r+Ge])}return GM(o,i)}var qM=!1;function JM(e){qM=e}function KM(e){let n=e[bn];if(n){let{i18nNodes:t,dehydratedIcuData:i}=n;if(t&&i){let o=e[Fe];for(let r of i.values())YM(o,t,r)}n.i18nNodes=void 0,n.dehydratedIcuData=void 0}}function YM(e,n,t){for(let i of t.node.cases[t.case]){let o=n.get(i.index-Ge);o&&mf(e,o,!1)}}function X_(e){let n=e[oi]??[],i=e[lt][Fe],o=[];for(let r of n)r.data[Iw]!==void 0?o.push(r):ev(r,i);e[oi]=o}function ZM(e){let{lContainer:n}=e,t=n[oi];if(t===null)return;let o=n[lt][Fe];for(let r of t)ev(r,o)}function ev(e,n){let t=0,i=e.firstChild;if(i){let o=e.data[pl];for(;t<o;){let r=i.nextSibling;mf(n,i,!1),i=r,t++}}}function Yl(e){X_(e);let n=e[qt];yn(n)&&Cl(n);for(let t=ht;t<e.length;t++)Cl(e[t])}function Cl(e){KM(e);let n=e[ie];for(let t=Ge;t<n.bindingStartIndex;t++)if(Rn(e[t])){let i=e[t];Yl(i)}else yn(e[t])&&Cl(e[t])}function tv(e){let n=e._views;for(let t of n){let i=cE(t);i!==null&&i[qt]!==null&&(yn(i)?Cl(i):Yl(i))}}function QM(e,n,t,i){e!==null&&(t.cleanup(n),Yl(e.lContainer),tv(i))}function XM(e,n){let t=[];for(let i of n)for(let o=0;o<(i[s_]??1);o++){let r={data:i,firstChild:null};i[pl]>0&&(r.firstChild=e,e=Kl(i[pl],e)),t.push(r)}return[e,t]}var nv=()=>null;function eP(e,n){let t=e[oi];return!n||t===null||t.length===0?null:t[0].data[Pw]===n?t.shift():(X_(e),null)}function tP(){nv=eP}function qr(e,n){return nv(e,n)}var nP=class{},iv=class{}
7,ap=class{resolveComponentFactory(n){throw Error(`No component factory found for ${At(n)}.`)}},Zl=class{static NULL=new ap},Bo=class{},Ut=(()=>{class e{destroyNode=null;static __NG_ELEMENT_ID__=()=>iP()}return e})();function iP(){let e=he(),n=Pt(),t=Nn(n.index,e);return(yn(t)?t:e)[Fe]}var oP=(()=>{class e{static \u0275prov=O({token:e,providedIn:"root",factory:()=>null})}return e})();var Sm={},Fo=class{injector;parentInjector;constructor(n,t){this.injector=n,this.parentInjector=t}get(n,t,i){i=Ml(i);let o=this.injector.get(n,Sm,i);return o!==Sm||t===Sm?o:this.parentInjector.get(n,t,i)}};function sp(e,n,t){let i=t?e.styles:null,o=t?e.classes:null,r=0;if(n!==null)for(let c=0;c<n.length;c++){let u=n[c];if(typeof u=="number")r=u;else if(r==1)o=km(o,u);else if(r==2){let m=u,f=n[++c];i=km(i,m+": "+f+";")}}t?e.styles=i:e.stylesWithoutHost=i,t?e.classes=o:e.classesWithoutHost=o}function me(e,n=de.Default){let t=he();if(t===null)return re(e,n);let i=Pt();return jC(i,t,Mt(e),n)}function Mf(e,n,t,i,o){let r=i===null?null:{"":-1},c=o(e,t);if(c!==null){let u,m=null,f=null,C=aP(c);C===null?u=c:[u,m,f]=C,cP(e,n,t,u,r,m,f)}r!==null&&i!==null&&rP(t,i,r)}function rP(e,n,t){let i=e.localNames=[];for(let o=0;o<n.length;o+=2){let r=t[n[o+1]];if(r==null)throw new J(-301,!1);i.push(n[o],r)}}function aP(e){let n=null,t=!1;for(let c=0;c<e.length;c++){let u=e[c];if(c===0&&On(u)&&(n=u),u.findHostDirectiveDefs!==null){t=!0;break}}if(!t)return null;let i=null,o=null,r=null;for(let c of e)c.findHostDirectiveDefs!==null&&(i??=[],o??=new Map,r??=new Map,sP(c,i,r,o)),c===n&&(i??=[],i.push(c));return i!==null?(i.push(...n===null?e:e.slice(1)),[i,o,r]):null}function sP(e,n,t,i){let o=n.length;e.findHostDirectiveDefs(e,n,i),t.set(e,[o,n.length-1])}function lP(e,n,t){n.componentOffset=t,(e.components??=[]).push(n.index)}function cP(e,n,t,i,o,r,c){let u=i.length,m=!1;for(let P=0;P<u;P++){let x=i[P];!m&&On(x)&&(m=!0,lP(e,t,P)),zm(cl(t,n),e,x.type)}hP(t,e.data.length,u);for(let P=0;P<u;P++){let x=i[P];x.providersResolver&&x.providersResolver(x)}let f=!1,C=!1,b=R_(e,n,u,null);u>0&&(t.directiveToIndex=new Map);for(let P=0;P<u;P++){let x=i[P];if(t.mergedAttrs=Uo(t.mergedAttrs,x.hostAttrs),uP(e,t,n,b,x),fP(b,x,o),c!==null&&c.has(x)){let[V,q]=c.get(x);t.directiveToIndex.set(x.type,[b,V+t.directiveStart,q+t.directiveStart])}else(r===null||!r.has(x))&&t.directiveToIndex.set(x.type,b);x.contentQueries!==null&&(t.flags|=4),(x.hostBindings!==null||x.hostAttrs!==null||x.hostVars!==0)&&(t.flags|=64);let D=x.type.prototype;!f&&(D.ngOnChanges||D.ngOnInit||D.ngDoCheck)&&((e.preOrderHooks??=[]).push(t.index),f=!0),!C&&(D.ngOnChanges||D.ngDoCheck)&&((e.preOrderCheckHooks??=[]).push(t.index),C=!0),b++}dP(e,t,r)}function dP(e,n,t){for(let i=n.directiveStart;i<n.directiveEnd;i++){let o=e.data[i];if(t===null||!t.has(o))y0(0,n,o,i),y0(1,n,o,i),x0(n,i,!1);else{let r=t.get(o);b0(0,n,r,i),b0(1,n,r,i),x0(n,i,!0)}}}function y0(e,n,t,i){let o=e===0?t.inputs:t.outputs;for(let r in o)if(o.hasOwnProperty(r)){let c;e===0?c=n.inputs??={}:c=n.outputs??={},c[r]??=[],c[r].push(i),ov(n,r)}}function b0(e,n,t,i){let o=e===0?t.inputs:t.outputs;for(let r in o)if(o.hasOwnProperty(r)){let c=o[r],u;e===0?u=n.hostDirectiveInputs??={}:u=n.hostDirectiveOutputs??={},u[c]??=[],u[c].push(i,r),ov(n,c)}}function ov(e,n){n==="class"?e.flags|=8:n==="style"&&(e.flags|=16)}function x0(e,n,t){let{attrs:i,inputs:o,hostDirectiveInputs:r}=e;if(i===null||!t&&o===null||t&&r===null||pf(e)){e.initialInputs??=[],e.initialInputs.push(null);return}let c=null,u=0;for(;u<i.length;){let m=i[u];if(m===0){u+=4;continue}else if(m===5){u+=2;continue}else if(typeof m=="number")break;if(!t&&o.hasOwnProperty(m)){let f=o[m];for(let C of f)if(C===n){c??=[],c.push(m,i[u+1]);break}}else if(t&&r.hasOwnProperty(m)){let f=r[m];for(let C=0;C<f.length;C+=2)if(f[C]===n){c??=[],c.push(f[C+1],i[u+1]);break}}u+=2}e.initialInputs??=[],e.initialInputs.push(c)}function uP(e,n,t,i,o){e.data[i]=o;let r=o.factory||(o.factory=Gi(o.type,!0)),c=new Zi(r,On(o),me);e.blueprint[i]=c,t[i]=c,mP(e,n,i,R_(e,t,o.hostVars,Vt),o)}function mP(e,n,t,i,o){let r=o.hostBindings;if(r){let c=e.hostBindingOpCodes;c===null&&(c=e.hostBindingOpCodes=[]);let u=~n.index;pP(c)!=u&&c.push(u),c.push(t,i,r)}}function pP(e){let n=e.length;for(;n>0;){let t=e[--n];if(typeof t=="number"&&t<0)return t}return 0}function fP(e,n,t){if(t){if(n.exportAs)for(let i=0;i<n.exportAs.length;i++)t[n.exportAs[i]]=e;On(n)&&(t[""]=e)}}function hP(e,n,t){e.flags|=1,e.directiveStart=n,e.directiveEnd=n+t,e.providerIndexes=n}function rv(e,n,t,i,o,r,c,u){let m=n.consts,f=wi(m,c),C=ql(n,e,2,i,f);return r&&Mf(n,t,C,wi(m,u),o),C.mergedAttrs=Uo(C.mergedAttrs,C.attrs),C.attrs!==null&&sp(C,C.attrs,!1),C.mergedAttrs!==null&&sp(C,C.mergedAttrs,!0),n.queries!==null&&n.queries.elementStart(n,C),C}function av(e,n){Yp(e,n),Up(n)&&e.queries.elementEnd(n)}var _l=class extends Zl{ngModule;constructor(n){super(),this.ngModule=n}resolveComponentFactory(n){let t=qi(n);return new Jr(t,this.ngModule)}};function gP(e){return Object.keys(e).map(n=>{let[t,i,o]=e[n],r={propName:t,templateName:n,isSignal:(i&jl.SignalBased)!==0};return o&&(r.transform=o),r})}function CP(e){return Object.keys(e).map(n=>({propName:e[n],templateName:n}))}function _P(e,n,t){let i=n instanceof yt?n:n?.injector;return i&&e.getStandaloneInjector!==null&&(i=e.getStandaloneInjector(i)||i),i?new Fo(t,i):t}function vP(e){let n=e.get(Bo,null);if(n===null)throw new J(407,!1);let t=e.get(oP,null),i=e.get(Qi,null);return{rendererFactory:n,sanitizer:t,changeDetectionScheduler:i}}function yP(e,n){let t=(e.selectors[0][0]||"div").toLowerCase();return uf(n,t,t==="svg"?fS:t==="math"?hS:null)}var Jr=class extends iv{componentDef;ngModule;selector;componentType;ngContentSelectors;isBoundToModule;cachedInputs=null;cachedOutputs=null;get inputs(){return this.cachedInputs??=gP(this.componentDef.inputs),this.cachedInputs}get outputs(){return this.cachedOutputs??=CP(this.componentDef.outputs),this.cachedOutputs}constructor(n,t){super(),this.componentDef=n,this.ngModule=t,this.componentType=n.type,this.selector=BE(n.selectors),this.ngContentSelectors=n.ngContentSelectors??[],this.isBoundToModule=!!t}create(n,t,i,o){Ee(22);let r=fe(null);try{let c=this.componentDef,u=i?["ng-version","19.2.25"]:HE(this.componentDef.selectors[0]),m=ff(0,null,null,1,0,null,null,null,null,[u],null),f=_P(c,o||this.ngModule,n),C=vP(f),b=C.rendererFactory.createRenderer(null,c),P=i?WE(b,i,c.encapsulation,f):yP(c,b),x=hf(null,m,null,512|A_(c),null,null,C,b,f,null,y_(P,f,!0));x[Ge]=P,Wp(x);let D=null;try{let V=rv(Ge,m,x,"#host",()=>[this.componentDef],!0,0);P&&(D_(b,P,V),qo(P,x)),Bl(m,x,V),cf(m,V,x),av(m,V),t!==void 0&&bP(V,this.ngContentSelectors,t),D=Nn(V.index,x),x[st]=D[st],bf(m,x,null)}catch(V){throw D!==null&&Zm(D),Zm(x),V}finally{Ee(23),qp()}return new lp(this.componentType,x)}finally{fe(r)}}},lp=class extends nP{_rootLView;instance;hostView;changeDetectorRef;componentType;location;previousInputValues=null;_tNode;constructor(n,t){super(),this._rootLView=t,this._tNode=Zr(t[ie],Ge),this.location=Wo(this._tNode,t),this.instance=Nn(this._tNode.index,t)[st],this.hostView=this.changeDetectorRef=new Gr(t,void 0,!1),this.componentType=n}setInput(n,t){let i=this._tNode;if(this.previousInputValues??=new Map,this.previousInputValues.has(n)&&Object.is(this.previousInputValues.get(n),t))return;let o=this._rootLView,r=yf(i,o[ie],o,n,t);this.previousInputValues.set(n,t);let c=Nn(i.index,o);Gl(c,1)}get injector(){return new zi(this._tNode,this._rootLView)}destroy(){this.hostView.destroy()}onDestroy(n){this.hostView.onDestroy(n)}};function bP(e,n,t){let i=e.projection=[];for(let o=0;o<n.length;o++){let r=t[o];i.push(r!=null&&r.length?Array.from(r):null)}}var oo=(()=>{class e{static __NG_ELEMENT_ID__=xP}return e})();function xP(){let e=Pt();return lv(e,he())}var SP=oo,sv=class extends SP{_lContainer;_hostTNode;_hostLView;constructor(n,t,i){super(),this._lContainer=n,this._hostTNode=t,this._hostLView=i}
vendor: 4,716 bytes, line 7
7get element(){return Wo(this._hostTNode,this._hostLView)}get injector(){return new zi(this._hostTNode,this._hostLView)}get parentInjector(){let n=Zp(this._hostTNode,this._hostLView);if(AC(n)){let t=sl(n,this._hostLView),i=al(n),o=t[ie].data[i+8];return new zi(o,t)}else return new zi(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(n){let t=S0(this._lContainer);return t!==null&&t[n]||null}get length(){return this._lContainer.length-ht}createEmbeddedView(n,t,i){let o,r;typeof i=="number"?o=i:i!=null&&(o=i.index,r=i.injector);let c=qr(this._lContainer,n.ssrId),u=n.createEmbeddedViewImpl(t||{},r,c);return this.insertImpl(u,o,jo(this._hostTNode,c)),u}createComponent(n,t,i,o,r){let c=n&&!dS(n),u;if(c)u=t;else{let D=t||{};u=D.index,i=D.injector,o=D.projectableNodes,r=D.environmentInjector||D.ngModuleRef}let m=c?n:new Jr(qi(n)),f=i||this.parentInjector;if(!r&&m.ngModule==null){let V=(c?f:this.parentInjector).get(yt,null);V&&(r=V)}let C=qi(m.componentType??{}),b=qr(this._lContainer,C?.id??null),P=b?.firstChild??null,x=m.create(f,o,P,r);return this.insertImpl(x.hostView,u,jo(this._hostTNode,b)),x}insert(n,t){return this.insertImpl(n,t,!0)}insertImpl(n,t,i){let o=n._lView;if(_S(o)){let u=this.indexOf(n);if(u!==-1)this.detach(u);else{let m=o[lt],f=new sv(m,m[Sn],m[lt]);f.detach(f.indexOf(n))}}let r=this._adjustIndex(t),c=this._lContainer;return oa(c,o,r,i),n.attachToViewContainerRef(),Q0(wm(c),r,n),n}move(n,t){return this.insert(n,t)}indexOf(n){let t=S0(this._lContainer);return t!==null?t.indexOf(n):-1}remove(n){let t=this._adjustIndex(n,-1),i=zr(this._lContainer,t);i&&(tl(wm(this._lContainer),t),Hl(i[ie],i))}detach(n){let t=this._adjustIndex(n,-1),i=zr(this._lContainer,t);return i&&tl(wm(this._lContainer),t)!=null?new Gr(i):null}_adjustIndex(n,t=0){return n??this.length+t}};function S0(e){return e[rl]}function wm(e){return e[rl]||(e[rl]=[])}function lv(e,n){let t,i=n[e.index];return Rn(i)?t=i:(t=Y_(i,n,null,e),n[e.index]=t,gf(n,t)),cv(t,n,e,i),new sv(t,e,n)}function wP(e,n){let t=e[Fe],i=t.createComment(""),o=wn(n,e),r=t.parentNode(o);return hl(t,r,i,t.nextSibling(o),!1),i}var cv=dv,Pf=()=>!1;function EP(e,n,t){return Pf(e,n,t)}function dv(e,n,t,i){if(e[ri])return;let o;t.type&8?o=xn(i):o=wP(n,t),e[ri]=o}function MP(e,n,t){if(e[ri]&&e[oi])return!0;let i=t[bn],o=n.index-Ge;if(!i||gw(n)||ta(i,o))return!1;let c=tp(i,o),u=i.data[of]?.[o],[m,f]=XM(c,u);return e[ri]=m,e[oi]=f,!0}function PP(e,n,t,i){Pf(e,t,n)||dv(e,n,t,i)}function DP(){cv=PP,Pf=MP}var cp=class e{queryList;matches=null;constructor(n){this.queryList=n}clone(){return new e(this.queryList)}setDirty(){this.queryList.setDirty()}},dp=class e{queries;constructor(n=[]){this.queries=n}createEmbeddedView(n){let t=n.queries;if(t!==null){let i=n.contentQueries!==null?n.contentQueries[0]:t.length,o=[];for(let r=0;r<i;r++){let c=t.getByIndex(r),u=this.queries[c.indexInDeclarationView];o.push(u.clone())}return new e(o)}return null}insertView(n){this.dirtyQueriesWithMatches(n)}detachView(n){this.dirtyQueriesWithMatches(n)}finishViewCreation(n){this.dirtyQueriesWithMatches(n)}dirtyQueriesWithMatches(n){for(let t=0;t<this.queries.length;t++)Df(n,t).matches!==null&&this.queries[t].setDirty()}},up=class{flags;read;predicate;constructor(n,t,i=null){this.flags=t,this.read=i,typeof n=="string"?this.predicate=FP(n):this.predicate=n}},mp=class e{queries;constructor(n=[]){this.queries=n}elementStart(n,t){for(let i=0;i<this.queries.length;i++)this.queries[i].elementStart(n,t)}elementEnd(n){for(let t=0;t<this.queries.length;t++)this.queries[t].elementEnd(n)}embeddedTView(n){let t=null;for(let i=0;i<this.length;i++){let o=t!==null?t.length:0,r=this.getByIndex(i).embeddedTView(n,o);r&&(r.indexInDeclarationView=i,t!==null?t.push(r):t=[r])}return t!==null?new e(t):null}template(n,t){for(let i=0;i<this.queries.length;i++)this.queries[i].template(n,t)}getByIndex(n){return this.queries[n]}get length(){return this.queries.length}track(n){this.queries.push(n)}},pp=class e{metadata;matches=null;indexInDeclarationView=-1;crossesNgTemplate=!1;_declarationNodeIndex;_appliesToNextNode=!0;constructor(n,t=-1){this.metadata=n,this._declarationNodeIndex=t}elementStart(n,t){this.isApplyingToNode(t)&&this.matchTNode(n,t)}elementEnd(n){this._declarationNodeIndex===n.index&&(this._appliesToNextNode=!1)}template(n,t){this.elementStart(n,t)}embeddedTView(n,t){return this.isApplyingToNode(n)?(this.crossesNgTemplate=!0,this.addMatch(-n.index,t),new e(this.metadata)):null}isApplyingToNode(n){if(this._appliesToNextNode&&(this.metadata.flags&1)!==1){let t=this._declarationNodeIndex,i=n.parent;for(;i!==null&&i.type&8&&i.index!==t;)i=i.parent;return t===(i!==null?i.index:-1)}return this._appliesToNextNode}
vendor: 5,052 bytes, line 7
7matchTNode(n,t){let i=this.metadata.predicate;if(Array.isArray(i))for(let o=0;o<i.length;o++){let r=i[o];this.matchTNodeWithReadOption(n,t,IP(t,r)),this.matchTNodeWithReadOption(n,t,qs(t,n,r,!1,!1))}else i===Wr?t.type&4&&this.matchTNodeWithReadOption(n,t,-1):this.matchTNodeWithReadOption(n,t,qs(t,n,i,!1,!1))}matchTNodeWithReadOption(n,t,i){if(i!==null){let o=this.metadata.read;if(o!==null)if(o===Lt||o===oo||o===Wr&&t.type&4)this.addMatch(t.index,-2);else{let r=qs(t,n,o,!1,!1);r!==null&&this.addMatch(t.index,r)}else this.addMatch(t.index,i)}}addMatch(n,t){this.matches===null?this.matches=[n,t]:this.matches.push(n,t)}};function IP(e,n){let t=e.localNames;if(t!==null){for(let i=0;i<t.length;i+=2)if(t[i]===n)return t[i+1]}return null}function TP(e,n){return e.type&11?Wo(e,n):e.type&4?Wl(e,n):null}function OP(e,n,t,i){return t===-1?TP(n,e):t===-2?NP(e,n,i):$r(e,e[ie],t,n)}function NP(e,n,t){if(t===Lt)return Wo(n,e);if(t===Wr)return Wl(n,e);if(t===oo)return lv(n,e)}function uv(e,n,t,i){let o=n[ii].queries[i];if(o.matches===null){let r=e.data,c=t.matches,u=[];for(let m=0;c!==null&&m<c.length;m+=2){let f=c[m];if(f<0)u.push(null);else{let C=r[f];u.push(OP(n,C,c[m+1],t.metadata.read))}}o.matches=u}return o.matches}function fp(e,n,t,i){let o=e.queries.getByIndex(t),r=o.matches;if(r!==null){let c=uv(e,n,o,t);for(let u=0;u<r.length;u+=2){let m=r[u];if(m>0)i.push(c[u/2]);else{let f=r[u+1],C=n[-m];for(let b=ht;b<C.length;b++){let P=C[b];P[Ji]===P[lt]&&fp(P[ie],P,f,i)}if(C[Vo]!==null){let b=C[Vo];for(let P=0;P<b.length;P++){let x=b[P];fp(x[ie],x,f,i)}}}}}return i}function kP(e,n){return e[ii].queries[n].queryList}function AP(e,n,t){let i=new Ym((t&4)===4);return bS(e,n,i,i.destroy),(n[ii]??=new dp).queries.push(new cp(i))-1}function RP(e,n,t){let i=Xe();return i.firstCreatePass&&(LP(i,new up(e,n,t),-1),(n&2)===2&&(i.staticViewQueries=!0)),AP(i,he(),n)}function FP(e){return e.split(",").map(n=>n.trim())}function LP(e,n,t){e.queries===null&&(e.queries=new mp),e.queries.track(new pp(n,t))}function Df(e,n){return e.queries.getByIndex(n)}function VP(e,n){let t=e[ie],i=Df(t,n);return i.crossesNgTemplate?fp(t,e,n,[]):uv(t,e,i,n)}var Ho=class{},If=class{};var hp=class extends Ho{ngModuleType;_parent;_bootstrapComponents=[];_r3Injector;instance;destroyCbs=[];componentFactoryResolver=new _l(this);constructor(n,t,i,o=!0){super(),this.ngModuleType=n,this._parent=t;let r=tC(n);this._bootstrapComponents=N_(r.bootstrap),this._r3Injector=$C(n,t,[{provide:Ho,useValue:this},{provide:Zl,useValue:this.componentFactoryResolver},...i],At(n),new Set(["environment"])),o&&this.resolveInjectorInitializers()}resolveInjectorInitializers(){this._r3Injector.resolveInjectorInitializers(),this.instance=this._r3Injector.get(this.ngModuleType)}get injector(){return this._r3Injector}destroy(){let n=this._r3Injector;!n.destroyed&&n.destroy(),this.destroyCbs.forEach(t=>t()),this.destroyCbs=null}onDestroy(n){this.destroyCbs.push(n)}},gp=class extends If{moduleType;constructor(n){super(),this.moduleType=n}create(n){return new hp(this.moduleType,n,[])}};var vl=class extends Ho{injector;componentFactoryResolver=new _l(this);instance=null;constructor(n){super();let t=new jr([...n.providers,{provide:Ho,useValue:this},{provide:Zl,useValue:this.componentFactoryResolver}],n.parent||Vp(),n.debugName,new Set(["environment"]));this.injector=t,n.runEnvironmentInitializers&&t.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(n){this.injector.onDestroy(n)}};function ra(e,n,t=null){return new vl({providers:e,parent:n,debugName:t,runEnvironmentInitializers:!0}).injector}var UP=(()=>{class e{_injector;cachedInjectors=new Map;constructor(t){this._injector=t}getOrCreateStandaloneInjector(t){if(!t.standalone)return null;if(!this.cachedInjectors.has(t)){let i=Fp(!1,t.type),o=i.length>0?ra([i],this._injector,`Standalone[${t.type.name}]`):null;this.cachedInjectors.set(t,o)}return this.cachedInjectors.get(t)}ngOnDestroy(){try{for(let t of this.cachedInjectors.values())t!==null&&t.destroy()}finally{this.cachedInjectors.clear()}}static \u0275prov=O({token:e,providedIn:"environment",factory:()=>new e(re(yt))})}return e})();function k(e){return wl(()=>{let n=mv(e),t=oe(U({},n),{decls:e.decls,vars:e.vars,template:e.template,consts:e.consts||null,ngContentSelectors:e.ngContentSelectors,onPush:e.changeDetection===XC.OnPush,directiveDefs:null,pipeDefs:null,dependencies:n.standalone&&e.dependencies||null,getStandaloneInjector:n.standalone?o=>o.get(UP).getOrCreateStandaloneInjector(t):null,getExternalStyles:null,signals:e.signals??!1,data:e.data||{},encapsulation:e.encapsulation||An.Emulated,styles:e.styles||kt,_:null,schemas:e.schemas||null,tView:null,id:""});n.standalone&&Vn("NgStandalone"),pv(t);let i=e.dependencies;return t.directiveDefs=w0(i,!1),t.pipeDefs=w0(i,!0),t.id=zP(t),t})}function jP(e){return qi(e)||nC(e)}function BP(e){return e!==null}function Di(e){return wl(()=>({type:e.type,bootstrap:e.bootstrap||kt,declarations:e.declarations||kt,imports:e.imports||kt,exports:e.exports||kt,transitiveCompileScopes:null,
7schemas:e.schemas||null,id:e.id||null}))}function HP(e,n){if(e==null)return Wi;let t={};for(let i in e)if(e.hasOwnProperty(i)){let o=e[i],r,c,u,m;Array.isArray(o)?(u=o[0],r=o[1],c=o[2]??r,m=o[3]||null):(r=o,c=o,u=jl.None,m=null),t[r]=[i,u,m],n[r]=c}return t}function $P(e){if(e==null)return Wi;let n={};for(let t in e)e.hasOwnProperty(t)&&(n[e[t]]=t);return n}function Le(e){return wl(()=>{let n=mv(e);return pv(n),n})}function Tf(e){return{type:e.type,name:e.name,factory:null,pure:e.pure!==!1,standalone:e.standalone??!0,onDestroy:e.type.prototype.ngOnDestroy||null}}function mv(e){let n={};return{type:e.type,providersResolver:null,factory:null,hostBindings:e.hostBindings||null,hostVars:e.hostVars||0,hostAttrs:e.hostAttrs||null,contentQueries:e.contentQueries||null,declaredInputs:n,inputConfig:e.inputs||Wi,exportAs:e.exportAs||null,standalone:e.standalone??!0,signals:e.signals===!0,selectors:e.selectors||kt,viewQuery:e.viewQuery||null,features:e.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:HP(e.inputs,n),outputs:$P(e.outputs),debugInfo:null}}function pv(e){e.features?.forEach(n=>n(e))}function w0(e,n){if(!e)return null;let t=n?iC:jP;return()=>(typeof e=="function"?e():e).map(i=>t(i)).filter(BP)}function zP(e){let n=0,t=typeof e.consts=="function"?"":e.consts,i=[e.selectors,e.ngContentSelectors,e.hostVars,e.hostAttrs,t,e.vars,e.decls,e.encapsulation,e.standalone,e.signals,e.exportAs,JSON.stringify(e.inputs),JSON.stringify(e.outputs),Object.getOwnPropertyNames(e.type.prototype),!!e.contentQueries,!!e.viewQuery];for(let r of i.join("|"))n=Math.imul(31,n)+r.charCodeAt(0)<<0;return n+=2147483648,"c"+n}function GP(e){return Object.getPrototypeOf(e.prototype).constructor}function bt(e){let n=GP(e.type),t=!0,i=[e];for(;n;){let o;if(On(e))o=n.\u0275cmp||n.\u0275dir;else{if(n.\u0275cmp)throw new J(903,!1);o=n.\u0275dir}if(o){if(t){i.push(o);let c=e;c.inputs=Em(e.inputs),c.declaredInputs=Em(e.declaredInputs),c.outputs=Em(e.outputs);let u=o.hostBindings;u&&YP(e,u);let m=o.viewQuery,f=o.contentQueries;if(m&&JP(e,m),f&&KP(e,f),WP(e,o),Nx(e.outputs,o.outputs),On(o)&&o.data.animation){let C=e.data;C.animation=(C.animation||[]).concat(o.data.animation)}}let r=o.features;if(r)for(let c=0;c<r.length;c++){let u=r[c];u&&u.ngInherit&&u(e),u===bt&&(t=!1)}}n=Object.getPrototypeOf(n)}qP(i)}function WP(e,n){for(let t in n.inputs){if(!n.inputs.hasOwnProperty(t)||e.inputs.hasOwnProperty(t))continue;let i=n.inputs[t];i!==void 0&&(e.inputs[t]=i,e.declaredInputs[t]=n.declaredInputs[t])}}function qP(e){let n=0,t=null;for(let i=e.length-1;i>=0;i--){let o=e[i];o.hostVars=n+=o.hostVars,o.hostAttrs=Uo(o.hostAttrs,t=Uo(t,o.hostAttrs))}}function Em(e){return e===Wi?{}:e===kt?[]:e}function JP(e,n){let t=e.viewQuery;t?e.viewQuery=(i,o)=>{n(i,o),t(i,o)}:e.viewQuery=n}function KP(e,n){let t=e.contentQueries;t?e.contentQueries=(i,o,r)=>{n(i,o,r),t(i,o,r)}:e.contentQueries=n}function YP(e,n){let t=e.hostBindings;t?e.hostBindings=(i,o)=>{n(i,o),t(i,o)}:e.hostBindings=n}function fv(e,n,t){return e[n]=t}function ln(e,n,t){let i=e[n];return Object.is(i,t)?!1:(e[n]=t,!0)}function Of(e,n,t,i){let o=ln(e,n,t);return ln(e,n+1,i)||o}function ZP(e,n,t,i,o){let r=Of(e,n,t,i);return ln(e,n+2,o)||r}function QP(e,n,t,i,o,r,c,u,m){let f=n.consts,C=ql(n,e,4,c||null,u||null);$p()&&Mf(n,t,C,wi(f,m),_f),C.mergedAttrs=Uo(C.mergedAttrs,C.attrs),Yp(n,C);let b=C.tView=ff(2,C,i,o,r,n.directiveRegistry,n.pipeRegistry,null,n.schemas,f,null);return n.queries!==null&&(n.queries.template(n,C),b.queries=n.queries.embeddedTView(C)),C}function Cp(e,n,t,i,o,r,c,u,m,f){let C=t+Ge,b=n.firstCreatePass?QP(C,n,e,i,o,r,c,u,m):n.data[C];no(b,!1);let P=hv(n,e,b,t);Nl()&&$l(n,e,P,b),qo(P,e);let x=Y_(P,e,P,b);return e[C]=x,gf(e,x),EP(x,b,e),Il(b)&&Bl(n,e,b),m!=null&&Cf(e,b,f),b}function y(e,n,t,i,o,r,c,u){let m=he(),f=Xe(),C=wi(f.consts,r);return Cp(m,f,e,n,t,i,o,C,c,u),y}var hv=gv;function gv(e,n,t,i){return Pi(!0),n[Fe].createComment("")}function XP(e,n,t,i){let o=n[bn],r=!o||Xr()||Yo(t)||ta(o,i);if(Pi(r),r)return gv(e,n);let c=o.data[Mw]?.[i]??null;c!==null&&t.tView!==null&&t.tView.ssrId===null&&(t.tView.ssrId=c);let u=Jl(o,e,n,t);Vl(o,i,u);let m=lf(o,i);return Kl(m,u)}function e2(){hv=XP}var t2=(()=>{class e{cachedInjectors=new Map;getOrCreateInjector(t,i,o,r){if(!this.cachedInjectors.has(t)){let c=o.length>0?ra(o,i,r):null;this.cachedInjectors.set(t,c)}return this.cachedInjectors.get(t)}ngOnDestroy(){try{for(let t of this.cachedInjectors.values())t!==null&&t.destroy()}finally{this.cachedInjectors.clear()}}static \u0275prov=O({token:e,providedIn:"environment",factory:()=>new e})}return e})();
7var n2=new K("");function Mm(e,n,t){return e.get(t2).getOrCreateInjector(n,e,t,"")}function i2(e,n,t){if(e instanceof Fo){let o=e.injector,r=e.parentInjector,c=Mm(r,n,t);return new Fo(o,c)}let i=e.get(yt);if(i!==e){let o=Mm(i,n,t);return new Fo(e,o)}return Mm(e,n,t)}function No(e,n,t,i=!1){let o=t[lt],r=o[ie];if(to(o))return;let c=ea(o,n),u=c[Rl],m=c[$w];if(!(m!==null&&e<m)&&E0(u,e)&&E0(c[jw]??-1,e)){let f=Fl(r,n),b=!i&&!0&&(Jw(f)!==null||m0(f,at.Loading)!==null||m0(f,at.Placeholder))?a2:r2;try{b(e,c,t,n,o)}catch(P){vf(o,P)}}}function o2(e,n){let t=e[oi]?.findIndex(o=>o.data[Tw]===n[Rl])??-1;return{dehydratedView:t>-1?e[oi][t]:null,dehydratedViewIx:t}}function r2(e,n,t,i,o){Ee(20);let r=qw(e,o,i);if(r!==null){n[Rl]=e;let c=o[ie],u=r+Ge,m=Zr(c,u),f=0;Ef(t,f);let C;if(e===at.Complete){let D=Fl(c,i),V=D.providers;V&&V.length>0&&(C=i2(o[Tn],D,V))}let{dehydratedView:b,dehydratedViewIx:P}=o2(t,n),x=ia(o,m,null,{injector:C,dehydratedView:b});if(oa(t,x,f,jo(m,b)),Gl(x,2),P>-1&&t[oi]?.splice(P,1),(e===at.Complete||e===at.Error)&&Array.isArray(n[Ro])){for(let D of n[Ro])D();n[Ro]=null}}Ee(21)}function E0(e,n){return e<n}function M0(e,n,t){e.loadingPromise.then(()=>{e.loadingState===Wt.COMPLETE?No(at.Complete,n,t):e.loadingState===Wt.FAILED&&No(at.Error,n,t)})}var a2=null;var Nf=(()=>{class e{log(t){console.log(t)}warn(t){console.warn(t)}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"platform"})}return e})();var Cv=new K("");var s2=(()=>{class e{static \u0275prov=O({token:e,providedIn:"root",factory:()=>new _p})}return e})(),_p=class{queuedEffectCount=0;queues=new Map;schedule(n){this.enqueue(n)}remove(n){let t=n.zone,i=this.queues.get(t);i.has(n)&&(i.delete(n),this.queuedEffectCount--)}enqueue(n){let t=n.zone;this.queues.has(t)||this.queues.set(t,new Set);let i=this.queues.get(t);i.has(n)||(this.queuedEffectCount++,i.add(n))}flush(){for(;this.queuedEffectCount>0;)for(let[n,t]of this.queues)n===null?this.flushQueue(t):n.run(()=>this.flushQueue(t))}flushQueue(n){for(let t of n)n.delete(t),this.queuedEffectCount--,t.run()}};function ro(e){return!!e&&typeof e.then=="function"}function _v(e){return!!e&&typeof e.subscribe=="function"}var l2=new K("");var vv=(()=>{class e{resolve;reject;initialized=!1;done=!1;donePromise=new Promise((t,i)=>{this.resolve=t,this.reject=i});appInits=h(l2,{optional:!0})??[];injector=h(sn);constructor(){}runInitializers(){if(this.initialized)return;let t=[];for(let o of this.appInits){let r=Kt(this.injector,o);if(ro(r))t.push(r);else if(_v(r)){let c=new Promise((u,m)=>{r.subscribe({complete:u,error:m})});t.push(c)}}let i=()=>{this.done=!0,this.resolve()};Promise.all(t).then(()=>{i()}).catch(o=>{this.reject(o)}),t.length===0&&i(),this.initialized=!0}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),ao=new K("");function c2(){Fu(()=>{throw new J(600,!1)})}function d2(e){return e.isBoundToModule}var u2=10;var Rt=(()=>{class e{_runningTick=!1;_destroyed=!1;_destroyListeners=[];_views=[];internalErrorHandler=h(sw);afterRenderManager=h(p_);zonelessEnabled=h(kl);
7rootEffectScheduler=h(s2);dirtyFlags=0;tracingSnapshot=null;externalTestViews=new Set;afterTick=new Ue;get allViews(){return[...this.externalTestViews.keys(),...this._views]}get destroyed(){return this._destroyed}componentTypes=[];components=[];isStable=h(Ln).hasPendingTasks.pipe(N(t=>!t));constructor(){h(Ko,{optional:!0})}whenStable(){let t;return new Promise(i=>{t=this.isStable.subscribe({next:o=>{o&&i()}})}).finally(()=>{t.unsubscribe()})}_injector=h(yt);_rendererFactory=null;get injector(){return this._injector}bootstrap(t,i){return this.bootstrapImpl(t,i)}bootstrapImpl(t,i,o=sn.NULL){Ee(10);let r=t instanceof iv;if(!this._injector.get(vv).done){let x="";throw new J(405,x)}let u;r?u=t:u=this._injector.get(Zl).resolveComponentFactory(t),this.componentTypes.push(u.componentType);let m=d2(u)?void 0:this._injector.get(Ho),f=i||u.selector,C=u.create(o,[],f,m),b=C.location.nativeElement,P=C.injector.get(Cv,null);return P?.registerApplication(b),C.onDestroy(()=>{this.detachView(C.hostView),Ks(this.components,C),P?.unregisterApplication(b)}),this._loadComponent(C),Ee(11,C),C}tick(){this.zonelessEnabled||(this.dirtyFlags|=1),this._tick()}_tick(){Ee(12),this.tracingSnapshot!==null?this.tracingSnapshot.run(rf.CHANGE_DETECTION,this.tickImpl):this.tickImpl()}tickImpl=()=>{if(this._runningTick)throw new J(101,!1);let t=fe(null);try{this._runningTick=!0,this.synchronize()}catch(i){this.internalErrorHandler(i)}finally{this._runningTick=!1,this.tracingSnapshot?.dispose(),this.tracingSnapshot=null,fe(t),this.afterTick.next(),Ee(13)}};synchronize(){this._rendererFactory===null&&!this._injector.destroyed&&(this._rendererFactory=this._injector.get(Bo,null,{optional:!0}));let t=0;for(;this.dirtyFlags!==0&&t++<u2;)Ee(14),this.synchronizeOnce(),Ee(15)}synchronizeOnce(){if(this.dirtyFlags&16&&(this.dirtyFlags&=-17,this.rootEffectScheduler.flush()),this.dirtyFlags&7){let t=!!(this.dirtyFlags&1);this.dirtyFlags&=-8,this.dirtyFlags|=8;for(let{_lView:i,notifyErrorHandler:o}of this.allViews)m2(i,o,t,this.zonelessEnabled);if(this.dirtyFlags&=-5,this.syncDirtyFlagsWithViews(),this.dirtyFlags&23)return}else this._rendererFactory?.begin?.(),this._rendererFactory?.end?.();this.dirtyFlags&8&&(this.dirtyFlags&=-9,this.afterRenderManager.execute()),this.syncDirtyFlagsWithViews()}syncDirtyFlagsWithViews(){if(this.allViews.some(({_lView:t})=>Tl(t))){this.dirtyFlags|=2;return}else this.dirtyFlags&=-8}attachView(t){let i=t;this._views.push(i),i.attachToAppRef(this)}detachView(t){let i=t;Ks(this._views,i),i.detachFromAppRef()}_loadComponent(t){this.attachView(t.hostView),this.tick(),this.components.push(t),this._injector.get(ao,[]).forEach(o=>o(t))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(t=>t()),this._views.slice().forEach(t=>t.destroy())}finally{this._destroyed=!0,this._views=[],this._destroyListeners=[]}}onDestroy(t){return this._destroyListeners.push(t),()=>Ks(this._destroyListeners,t)}destroy(){if(this._destroyed)throw new J(406,!1);let t=this._injector;t.destroy&&!t.destroyed&&t.destroy()}get viewCount(){return this._views.length}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();function Ks(e,n){let t=e.indexOf(n);t>-1&&e.splice(t,1)}function m2(e,n,t,i){if(!t&&!Tl(e))return;W_(e,n,t&&!i?0:1)}function p2(e,n,t){let i=n[Tn],o=n[ie];if(e.loadingState!==Wt.NOT_STARTED)return e.loadingPromise??Promise.resolve();let r=ea(n,t),c=Kw(o,e);e.loadingState=Wt.IN_PROGRESS,Js(1,r);let u=e.dependencyResolverFn,m=i.get(ew).add();return u?(e.loadingPromise=Promise.allSettled(u()).then(f=>{let C=!1,b=[],P=[];for(let x of f)if(x.status==="fulfilled"){let D=x.value,V=qi(D)||nC(D);if(V)b.push(V);else{let q=iC(D);q&&P.push(q)}}else{C=!0;break}if(C){if(e.loadingState=Wt.FAILED,e.errorTmplIndex===null){let D=new J(-750,!1);vf(n,D)}}else{e.loadingState=Wt.COMPLETE;let x=c.tView;if(b.length>0){x.directiveRegistry=p0(x.directiveRegistry,b);let D=b.map(q=>q.type),V=Fp(!1,...D);e.providers=V}P.length>0&&(x.pipeRegistry=p0(x.pipeRegistry,P))}}),e.loadingPromise.finally(()=>{e.loadingPromise=null,m()}
7)):(e.loadingPromise=Promise.resolve().then(()=>{e.loadingPromise=null,e.loadingState=Wt.COMPLETE,m()}),e.loadingPromise)}function f2(e,n){return n[Tn].get(n2,null,{optional:!0})?.behavior!==f_.Manual}function h2(e,n,t){let i=n[ie],o=n[t.index];if(!f2(e,n))return;let r=ea(n,t),c=Fl(i,t);switch(Gw(r),c.loadingState){case Wt.NOT_STARTED:No(at.Loading,t,o),p2(c,n,t),c.loadingState===Wt.IN_PROGRESS&&M0(c,t,o);break;case Wt.IN_PROGRESS:No(at.Loading,t,o),M0(c,t,o);break;case Wt.COMPLETE:No(at.Complete,t,o);break;case Wt.FAILED:No(at.Error,t,o);break;default:}}function g2(e,n,t){return wt(this,null,function*(){let i=e.get(sf);if(i.hydrating.has(n))return;let{parentBlockPromise:r,hydrationQueue:c}=hE(n,e);if(c.length===0)return;r!==null&&c.shift(),v2(i,c),r!==null&&(yield r);let u=c[0];i.has(u)?yield P0(e,c,t):i.awaitParentBlock(u,()=>wt(null,null,function*(){return yield P0(e,c,t)}))})}function P0(e,n,t){return wt(this,null,function*(){let i=e.get(sf),o=i.hydrating,r=e.get(Ln),c=r.add();for(let m=0;m<n.length;m++){let f=n[m],C=i.get(f);if(C!=null){if(yield b2(C),yield y2(e),C2(C)){ZM(C),D0(n.slice(m),i);break}o.get(f).resolve()}else{_2(m,n,i),D0(n.slice(m),i);break}}let u=n[n.length-1];yield o.get(u)?.promise,r.remove(c),t&&t(n),QM(i.get(u),n,i,e.get(Rt))})}function C2(e){return ea(e.lView,e.tNode)[Rl]===at.Error}function _2(e,n,t){let i=e-1,o=i>-1?t.get(n[i]):null;o&&Yl(o.lContainer)}function D0(e,n){let t=n.hydrating;for(let i in e)t.get(i)?.reject();n.cleanup(e)}function v2(e,n){for(let t of n)e.hydrating.set(t,Promise.withResolvers())}function y2(e){return new Promise(n=>af(n,{injector:e}))}function b2(e){return wt(this,null,function*(){let{tNode:n,lView:t}=e,i=ea(t,n);return new Promise(o=>{x2(i,o),h2(2,t,n)})})}function x2(e,n){Array.isArray(e[Ro])||(e[Ro]=[]),e[Ro].push(n)}function _e(e,n,t,i){let o=he(),r=Go();if(ln(o,r,n)){let c=Xe(),u=Jp();tM(u,o,e,n,t,i)}return _e}function S2(e,n,t,i){return ln(e,Go(),t)?n+ei(t)+i:Vt}function w2(e,n,t,i,o,r){let c=wC(),u=Of(e,c,t,o);return Ol(2),u?n+ei(t)+i+ei(o)+r:Vt}function E2(e,n,t,i,o,r,c,u){let m=wC(),f=ZP(e,m,t,o,c);return Ol(3),f?n+ei(t)+i+ei(o)+r+ei(c)+u:Vt}function Hs(e,n){return e<<17|n<<2}function Xi(e){return e>>17&32767}function M2(e){return(e&2)==2}function P2(e,n){return e&131071|n<<17}function vp(e){return e|2}function $o(e){return(e&131068)>>2}function Pm(e,n){return e&-131069|n<<2}function D2(e){return(e&1)===1}function yp(e){return e|1}function I2(e,n,t,i,o,r){let c=r?n.classBindings:n.styleBindings,u=Xi(c),m=$o(c);e[i]=t;let f=!1,C;if(Array.isArray(t)){let b=t;C=b[1],(C===null||Yr(b,C)>0)&&(f=!0)}else C=t;if(o)if(m!==0){let P=Xi(e[u+1]);e[i+1]=Hs(P,u),P!==0&&(e[P+1]=Pm(e[P+1],i)),e[u+1]=P2(e[u+1],i)}else e[i+1]=Hs(u,0),u!==0&&(e[u+1]=Pm(e[u+1],i)),u=i;else e[i+1]=Hs(m,0),u===0?u=i:e[m+1]=Pm(e[m+1],i),m=i;f&&(e[i+1]=vp(e[i+1])),I0(e,C,i,!0),I0(e,C,i,!1),T2(n,C,e,i,r),c=Hs(u,m),r?n.classBindings=c:n.styleBindings=c}function T2(e,n,t,i,o){let r=o?e.residualClasses:e.residualStyles;r!=null&&typeof n=="string"&&Yr(r,n)>=0&&(t[i+1]=yp(t[i+1]))}function I0(e,n,t,i){let o=e[t+1],r=n===null,c=i?Xi(o):$o(o),u=!1;for(;c!==0&&(u===!1||r);){let m=e[c],f=e[c+1];O2(m,n)&&(u=!0,e[c+1]=i?yp(f):vp(f)),c=i?Xi(f):$o(f)}u&&(e[t+1]=i?vp(o):yp(o))}function O2(e,n){return e===null||n==null||(Array.isArray(e)?e[1]:e)===n?!0:Array.isArray(e)&&typeof n=="string"?Yr(e,n)>=0:!1}var _n={textEnd:0,key:0,keyEnd:0,value:0,valueEnd:0};function N2(e){return e.substring(_n.key,_n.keyEnd)}function k2(e){return A2(e),yv(e,bv(e,0,_n.textEnd))}function yv(e,n){let t=_n.textEnd;return t===n?-1:(n=_n.keyEnd=R2(e,_n.key=n,t),bv(e,n,t))}function A2(e){_n.key=0,_n.keyEnd=0,_n.value=0,_n.valueEnd=0,_n.textEnd=e.length}function bv(e,n,t){for(;n<t&&e.charCodeAt(n)<=32;)n++;return n}function R2(e,n,t){for(;n<t&&e.charCodeAt(n)>32;)n++;return n}function v(e,n,t){let i=he(),o=Go();if(ln(i,o,n)){let r=Xe(),c=Jp();U_(r,c,i,e,n,i[Fe],t,!1)}return v}function bp(e,n,t,i,o){yf(n,e,t,o?"class":"style",i)}function Te(e,n,t){return xv(e,n,t,!1),Te}function pe(e,n){return xv(e,n,null,!0),pe}function aa(e){L2($2,F2,e,!0)}function F2(e,n){for(let t=k2(n);t>=0;t=yv(n,t))Rp(e,N2(n),!0)}function xv(e,n,t,i){let o=he(),r=Xe(),c=Ol(2);if(r.firstUpdatePass&&wv(r,e,c,i),n!==Vt&&ln(o,c,n)){let u=r.data[Fn()];
vendor: 7,111 bytes, line 7
7Ev(r,u,o,o[Fe],e,o[c+1]=G2(n,t),i,c)}}function L2(e,n,t,i){let o=Xe(),r=Ol(2);o.firstUpdatePass&&wv(o,null,r,i);let c=he();if(t!==Vt&&ln(c,r,t)){let u=o.data[Fn()];if(Mv(u,i)&&!Sv(o,r)){let m=i?u.classesWithoutHost:u.stylesWithoutHost;m!==null&&(t=km(m,t||"")),bp(o,u,c,t,i)}else z2(o,u,c,c[Fe],c[r+1],c[r+1]=H2(e,n,t),i,r)}}function Sv(e,n){return n>=e.expandoStartIndex}function wv(e,n,t,i){let o=e.data;if(o[t+1]===null){let r=o[Fn()],c=Sv(e,t);Mv(r,i)&&n===null&&!c&&(n=!1),n=V2(o,r,n,i),I2(o,r,n,t,c,i)}}function V2(e,n,t,i){let o=AS(e),r=i?n.residualClasses:n.residualStyles;if(o===null)(i?n.classBindings:n.styleBindings)===0&&(t=Dm(null,e,n,t,i),t=Kr(t,n.attrs,i),r=null);else{let c=n.directiveStylingLast;if(c===-1||e[c]!==o)if(t=Dm(o,e,n,t,i),r===null){let m=U2(e,n,i);m!==void 0&&Array.isArray(m)&&(m=Dm(null,e,n,m[1],i),m=Kr(m,n.attrs,i),j2(e,n,i,m))}else r=B2(e,n,i)}return r!==void 0&&(i?n.residualClasses=r:n.residualStyles=r),t}function U2(e,n,t){let i=t?n.classBindings:n.styleBindings;if($o(i)!==0)return e[Xi(i)]}function j2(e,n,t,i){let o=t?n.classBindings:n.styleBindings;e[Xi(o)]=i}function B2(e,n,t){let i,o=n.directiveEnd;for(let r=1+n.directiveStylingLast;r<o;r++){let c=e[r].hostAttrs;i=Kr(i,c,t)}return Kr(i,n.attrs,t)}function Dm(e,n,t,i,o){let r=null,c=t.directiveEnd,u=t.directiveStylingLast;for(u===-1?u=t.directiveStart:u++;u<c&&(r=n[u],i=Kr(i,r.hostAttrs,o),r!==e);)u++;return e!==null&&(t.directiveStylingLast=u),i}function Kr(e,n,t){let i=t?1:2,o=-1;if(n!==null)for(let r=0;r<n.length;r++){let c=n[r];typeof c=="number"?o=c:o===i&&(Array.isArray(e)||(e=e===void 0?[]:["",e]),Rp(e,c,t?!0:n[++r]))}return e===void 0?null:e}function H2(e,n,t){if(t==null||t==="")return kt;let i=[],o=na(t);if(Array.isArray(o))for(let r=0;r<o.length;r++)e(i,o[r],!0);else if(typeof o=="object")for(let r in o)o.hasOwnProperty(r)&&e(i,r,o[r]);else typeof o=="string"&&n(i,o);return i}function $2(e,n,t){let i=String(n);i!==""&&!i.includes(" ")&&Rp(e,i,t)}function z2(e,n,t,i,o,r,c,u){o===Vt&&(o=kt);let m=0,f=0,C=0<o.length?o[0]:null,b=0<r.length?r[0]:null;for(;C!==null||b!==null;){let P=m<o.length?o[m+1]:void 0,x=f<r.length?r[f+1]:void 0,D=null,V;C===b?(m+=2,f+=2,P!==x&&(D=b,V=x)):b===null||C!==null&&C<b?(m+=2,D=C):(f+=2,D=b,V=x),D!==null&&Ev(e,n,t,i,D,V,c,u),C=m<o.length?o[m]:null,b=f<r.length?r[f]:null}}function Ev(e,n,t,i,o,r,c,u){if(!(n.type&3))return;let m=e.data,f=m[u+1],C=D2(f)?T0(m,n,t,o,$o(f),c):void 0;if(!yl(C)){yl(r)||M2(f)&&(r=T0(m,null,t,o,u,c));let b=hC(Fn(),t);yM(i,c,b,o,r)}}function T0(e,n,t,i,o,r){let c=n===null,u;for(;o>0;){let m=e[o],f=Array.isArray(m),C=f?m[1]:m,b=C===null,P=t[o+1];P===Vt&&(P=b?kt:void 0);let x=b?fm(P,i):C===i?P:void 0;if(f&&!yl(x)&&(x=fm(m,i)),yl(x)&&(u=x,c))return u;let D=e[o+1];o=c?Xi(D):$o(D)}if(n!==null){let m=r?n.residualClasses:n.residualStyles;m!=null&&(u=fm(m,i))}return u}function yl(e){return e!==void 0}function G2(e,n){return e==null||e===""||(typeof n=="string"?e=e+n:typeof e=="object"&&(e=At(na(e)))),e}function Mv(e,n){return(e.flags&(n?8:16))!==0}var xp=class{destroy(n){}updateValue(n,t){}swap(n,t){let i=Math.min(n,t),o=Math.max(n,t),r=this.detach(o);if(o-i>1){let c=this.detach(i);this.attach(i,r),this.attach(o,c)}else this.attach(i,r)}move(n,t){this.attach(t,this.detach(n))}};function Im(e,n,t,i,o){return e===t&&Object.is(n,i)?1:Object.is(o(e,n),o(t,i))?-1:0}function W2(e,n,t){let i,o,r=0,c=e.length-1,u=void 0;if(Array.isArray(n)){let m=n.length-1;for(;r<=c&&r<=m;){let f=e.at(r),C=n[r],b=Im(r,f,r,C,t);if(b!==0){b<0&&e.updateValue(r,C),r++;continue}let P=e.at(c),x=n[m],D=Im(c,P,m,x,t);if(D!==0){D<0&&e.updateValue(c,x),c--,m--;continue}let V=t(r,f),q=t(c,P),te=t(r,C);if(Object.is(te,q)){let Ie=t(m,x);Object.is(Ie,V)?(e.swap(r,c),e.updateValue(c,x),m--,c--):e.move(c,r),e.updateValue(r,C),r++;continue}if(i??=new bl,o??=N0(e,r,c,t),Sp(e,i,r,te))e.updateValue(r,C),r++,c++;else if(o.has(te))i.set(V,e.detach(r)),c--;else{let Ie=e.create(r,n[r]);e.attach(r,Ie),r++,c++}}for(;r<=m;)O0(e,i,t,r,n[r]),r++}else if(n!=null){let m=n[Symbol.iterator](),f=m.next();for(;!f.done&&r<=c;){let C=e.at(r),b=f.value,P=Im(r,C,r,b,t);if(P!==0)P<0&&e.updateValue(r,b),r++,f=m.next();else{i??=new bl,o??=N0(e,r,c,t);let x=t(r,b);if(Sp(e,i,r,x))e.updateValue(r,b),r++,c++,f=m.next();else if(!o.has(x))e.attach(r,e.create(r,b)),r++,c++,f=m.next();else{let D=t(r,C);i.set(D,e.detach(r)),c--}}}for(;!f.done;)O0(e,i,t,e.length,f.value),f=m.next()}for(;r<=c;)e.destroy(e.detach(c--));i?.forEach(m=>{e.destroy(m)})}function Sp(e,n,t,i){return n!==void 0&&n.has(i)?(e.attach(t,n.get(i)),n.delete(i),!0):!1}function O0(e,n,t,i,o){if(Sp(e,n,i,t(i,o)))e.updateValue(i,o);else{let r=e.create(i,o);e.attach(i,r)}}function N0(e,n,t,i){let o=new Set;for(let r=n;r<=t;r++)o.add(i(r,e.at(r)));return o}var bl=class{kvMap=new Map;_vMap=void 0;has(n){return this.kvMap.has(n)}delete(n){if(!this.has(n))return!1;let t=this.kvMap.get(n);return this._vMap!==void 0&&this._vMap.has(t)?(this.kvMap.set(n,this._vMap.get(t)),this._vMap.delete(t)):this.kvMap.delete(n),!0}get(n){return this.kvMap.get(n)}set(n,t){if(this.kvMap.has(n)){let i=this.kvMap.get(n);this._vMap===void 0&&(this._vMap=new Map);let o=this._vMap;for(;o.has(i);)i=o.get(i);o.set(i,t)}else this.kvMap.set(n,t)}forEach(n){for(let[t,i]of this.kvMap)if(n(i,t),this._vMap!==void 0){let o=this._vMap;for(;o.has(i);)i=o.get(i),n(i,t)}}};function _(e,n){Vn("NgControlFlow");let t=he(),i=Go(),o=t[i]!==Vt?t[i]:-1,r=o!==-1?xl(t,Ge+o):void 0,c=0;if(ln(t,i,e)){let u=fe(null);try{if(r!==void 0&&Ef(r,c),e!==-1){let m=Ge+e,f=xl(t,m),C=Pp(t[ie],m),b=qr(f,C.tView.ssrId),P=ia(t,C,n,{dehydratedView:b});oa(f,P,c,jo(C,b))}}finally{fe(u)}}else if(r!==void 0){let u=Z_(r,c);u!==void 0&&(u[st]=n)}}var wp=class{lContainer;$implicit;$index;constructor(n,t,i){this.lContainer=n,this.$implicit=t,this.$index=i}get $count(){return this.lContainer.length-ht}};function sa(e){return e}function Re(e,n){return n}var Ep=class{hasEmptyBlock;trackByFn;liveCollection;constructor(n,t,i){this.hasEmptyBlock=n,this.trackByFn=t,this.liveCollection=i}};function I(e,n,t,i,o,r,c,u,m,f,C,b,P){Vn("NgControlFlow");let x=he(),D=Xe(),V=m!==void 0,q=he(),te=u?c.bind(q[Jt][st]):c,Ie=new Ep(V,te);q[Ge+e]=Ie,Cp(x,D,e+1,n,t,i,o,wi(D.consts,r)),V&&Cp(x,D,e+2,m,f,C,b,wi(D.consts,P))}var Mp=class extends xp{lContainer;hostLView;templateTNode;operationsCounter=void 0;needsIndexUpdate=!1;constructor(n,t,i){super(),this.lContainer=n,this.hostLView=t,this.templateTNode=i}get length(){return this.lContainer.length-ht}at(n){return this.getLView(n)[st].$implicit}attach(n,t){let i=t[bn];this.needsIndexUpdate||=n!==this.length,oa(this.lContainer,t,n,jo(this.templateTNode,i))}detach(n){return this.needsIndexUpdate||=n!==this.length-1,q2(this.lContainer,n)}create(n,t){let i=qr(this.lContainer,this.templateTNode.tView.ssrId),o=ia(this.hostLView,this.templateTNode,new wp(this.lContainer,t,n),{dehydratedView:i});return this.operationsCounter?.recordCreate(),o}destroy(n){Hl(n[ie],n),this.operationsCounter?.recordDestroy()}updateValue(n,t){this.getLView(n)[st].$implicit=t}reset(){this.needsIndexUpdate=!1,this.operationsCounter?.reset()}
7updateIndexes(){if(this.needsIndexUpdate)for(let n=0;n<this.length;n++)this.getLView(n)[st].$index=n}getLView(n){return J2(this.lContainer,n)}};function T(e){let n=fe(null),t=Fn();try{let i=he(),o=i[ie],r=i[t],c=t+1,u=xl(i,c);if(r.liveCollection===void 0){let f=Pp(o,c);r.liveCollection=new Mp(u,i,f)}else r.liveCollection.reset();let m=r.liveCollection;if(W2(m,e,r.trackByFn),m.updateIndexes(),r.hasEmptyBlock){let f=Go(),C=m.length===0;if(ln(i,f,C)){let b=t+2,P=xl(i,b);if(C){let x=Pp(o,b),D=qr(P,x.tView.ssrId),V=ia(i,x,void 0,{dehydratedView:D});oa(P,V,0,jo(x,D))}else Ef(P,0)}}}finally{fe(n)}}function xl(e,n){return e[n]}function q2(e,n){return zr(e,n)}function J2(e,n){return Z_(e,n)}function Pp(e,n){return Zr(e,n)}function l(e,n,t,i){let o=he(),r=Xe(),c=Ge+e,u=o[Fe],m=r.firstCreatePass?rv(c,r,o,n,_f,$p(),t,i):r.data[c],f=Pv(r,o,m,u,n,e);o[c]=f;let C=Il(m);return no(m,!0),D_(u,f,m),!Yo(m)&&Nl()&&$l(r,o,f,m),(xS()===0||C)&&qo(f,o),SS(),C&&(Bl(r,o,m),cf(r,m,o)),i!==null&&Cf(o,m),l}function a(){let e=Pt();zp()?bC():(e=e.parent,no(e,!1));let n=e;ES(n)&&PS(),wS();let t=Xe();return t.firstCreatePass&&av(t,n),n.classesWithoutHost!=null&&US(n)&&bp(t,n,he(),n.classesWithoutHost,!0),n.stylesWithoutHost!=null&&jS(n)&&bp(t,n,he(),n.stylesWithoutHost,!1),a}function j(e,n,t,i){return l(e,n,t,i),a(),j}var Pv=(e,n,t,i,o,r)=>(Pi(!0),uf(i,o,Kp()));function K2(e,n,t,i,o,r){let c=n[bn],u=!c||Xr()||Yo(t)||ta(c,r);if(Pi(u),u)return uf(i,o,Kp());let m=Jl(c,e,n,t);return b_(c,r)&&Vl(c,r,m.nextSibling),c&&(ZC(t)||QC(m))&&eo(t)&&(MS(t),P_(m)),m}function Y2(){Pv=K2}function Z2(e,n,t,i,o){let r=n.consts,c=wi(r,i),u=ql(n,e,8,"ng-container",c);c!==null&&sp(u,c,!0);let m=wi(r,o);return $p()&&Mf(n,t,u,m,_f),u.mergedAttrs=Uo(u.mergedAttrs,u.attrs),n.queries!==null&&n.queries.elementStart(n,u),u}function Dv(e,n,t){let i=he(),o=Xe(),r=e+Ge,c=o.firstCreatePass?Z2(r,o,i,n,t):o.data[r];no(c,!0);let u=Tv(o,i,c,e);return i[r]=u,Nl()&&$l(o,i,u,c),qo(u,i),Il(c)&&(Bl(o,i,c),cf(o,c,i)),t!=null&&Cf(i,c),Dv}function Iv(){let e=Pt(),n=Xe();return zp()?bC():(e=e.parent,no(e,!1)),n.firstCreatePass&&(Yp(n,e),Up(e)&&n.queries.elementEnd(e)),Iv}function Ii(e,n,t){return Dv(e,n,t),Iv(),Ii}var Tv=(e,n,t,i)=>(Pi(!0),E_(n[Fe],""));function Q2(e,n,t,i){let o,r=n[bn],c=!r||Xr()||ta(r,i)||Yo(t);if(Pi(c),c)return E_(n[Fe],"");let u=Jl(r,e,n,t),m=pE(r,i);return Vl(r,i,u),o=Kl(m,u),o}function X2(){Tv=Q2}function $(){return he()}var Hi=void 0;function eD(e){let n=Math.floor(Math.abs(e)),t=e.toString().replace(/^[^.]*\.?/,"").length;return n===1&&t===0?1:5}var tD=["en",[["a","p"],["AM","PM"],Hi],[["AM","PM"],Hi,Hi],[["S","M","T","W","T","F","S"],["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],["Su","Mo","Tu","We","Th","Fr","Sa"]],Hi,[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],["January","February","March","April","May","June","July","August","September","October","November","December"]],Hi,[["B","A"],["BC","AD"],["Before Christ","Anno Domini"]],0,[6,0],["M/d/yy","MMM d, y","MMMM d, y","EEEE, MMMM d, y"],["h:mm a","h:mm:ss a","h:mm:ss a z","h:mm:ss a zzzz"],["{1}, {0}",Hi,"{1} 'at' {0}",Hi],[".",",",";","%","+","-","E","\xD7","\u2030","\u221E","NaN",":"],["#,##0.###","#,##0%","\xA4#,##0.00","#E0"],"USD","$","US Dollar",{},"ltr",eD],Tm={};function Qt(e){let n=nD(e),t=k0(n);if(t)return t;let i=n.split("-")[0];if(t=k0(i),t)return t;if(i==="en")return tD;throw new J(701,!1)}function k0(e){return e in Tm||(Tm[e]=bi.ng&&bi.ng.common&&bi.ng.common.locales&&bi.ng.common.locales[e]),Tm[e]}var Ye=(function(e){return e[e.LocaleId=0]="LocaleId",e[e.DayPeriodsFormat=1]="DayPeriodsFormat",e[e.DayPeriodsStandalone=2]="DayPeriodsStandalone",e[e.DaysFormat=3]="DaysFormat",e[e.DaysStandalone=4]="DaysStandalone",e[e.MonthsFormat=5]="MonthsFormat",e[e.MonthsStandalone=6]="MonthsStandalone",e[e.Eras=7]="Eras",e[e.FirstDayOfWeek=8]="FirstDayOfWeek",e[e.WeekendRange=9]="WeekendRange",e[e.DateFormat=10]="DateFormat",e[e.TimeFormat=11]="TimeFormat",e[e.DateTimeFormat=12]="DateTimeFormat",e[e.NumberSymbols=13]="NumberSymbols",e[e.NumberFormats=14]="NumberFormats",e[e.CurrencyCode=15]="CurrencyCode",e[e.CurrencySymbol=16]="CurrencySymbol",e[e.CurrencyName=17]="CurrencyName",e[e.Currencies=18]="Currencies",e[e.Directionality=19]="Directionality",e[e.PluralCase=20]="PluralCase",e[e.ExtraData=21]="ExtraData",e})(Ye||{});function nD(e){return e.toLowerCase().replace(/_/g,"-")}var Sl="en-US";var iD=Sl;function oD(e){typeof e=="string"&&(iD=e.toLowerCase().replace(/_/g,"-"))}function A0(e,n,t){return function i(o){if(o===Function)return t;let r=eo(e)?Nn(e.index,n):n;Gl(r,5);let c=n[st],u=R0(n,c,t,o),m=i.__ngNextListenerFn__;for(;m;)u=R0(n,c,m,o)&&u,m=m.__ngNextListenerFn__;return u}}function R0(e,n,t,i){let o=fe(null);try{return Ee(6,n,t),t(i)!==!1}catch(r){return rD(e,r),!1}finally{Ee(7,n,t),fe(o)}}function rD(e,n){let t=e[Tn],i=t?t.get(kn,null):null;i&&i.handleError(n)}function F0(e,n,t,i,o,r){let c=n[t],u=n[ie],f=u.data[t].outputs[i],C=c[f],b=u.firstCreatePass?Hp(u):null,P=Bp(n),x=C.subscribe(r),D=P.length;P.push(r,x),b&&b.push(o,e.index,D,-(D+1))}function M(e,n,t,i){let o=he(),r=Xe(),c=Pt();return Ov(r,o,o[Fe],c,e,n,i),M}function aD(e,n,t,i){let o=e.cleanup;if(o!=null)for(let r=0;r<o.length-1;r+=2){let c=o[r];
7if(c===t&&o[r+1]===i){let u=n[il],m=o[r+2];return u.length>m?u[m]:null}typeof c=="string"&&(r+=2)}return null}function Ov(e,n,t,i,o,r,c){let u=Il(i),f=e.firstCreatePass?Hp(e):null,C=Bp(n),b=!0;if(i.type&3||c){let P=wn(i,n),x=c?c(P):P,D=C.length,V=c?te=>c(xn(te[i.index])):i.index,q=null;if(!c&&u&&(q=aD(e,n,o,i.index)),q!==null){let te=q.__ngLastListenerFn__||q;te.__ngNextListenerFn__=r,q.__ngLastListenerFn__=r,b=!1}else{r=A0(i,n,r),tE(n,x,o,r);let te=t.listen(x,o,r);C.push(r,te),f&&f.push(o,V,D,D+1)}}else r=A0(i,n,r);if(b){let P=i.outputs?.[o],x=i.hostDirectiveOutputs?.[o];if(x&&x.length)for(let D=0;D<x.length;D+=2){let V=x[D],q=x[D+1];F0(i,n,V,q,o,r)}if(P&&P.length)for(let D of P)F0(i,n,D,o,o,r)}}function p(e=1){return FS(e)}function kf(e,n,t){RP(e,n,t)}function Ql(e){let n=he(),t=Xe(),i=EC();Gp(i+1);let o=Df(t,i);if(e.dirty&&CS(n)===((o.metadata.flags&2)===2)){if(o.matches===null)e.reset([]);else{let r=VP(n,i);e.reset(r,dw),e.notifyOnChanges()}return!0}return!1}function Xl(){return kP(he(),EC())}function so(e){let n=IS();return gC(n,Ge+e)}function s(e,n=""){let t=he(),i=Xe(),o=e+Ge,r=i.firstCreatePass?ql(i,o,1,n,null):i.data[o],c=Nv(i,t,r,n,e);t[o]=c,Nl()&&$l(i,t,c,r),no(r,!1)}var Nv=(e,n,t,i,o)=>(Pi(!0),w_(n[Fe],i));function sD(e,n,t,i,o){let r=n[bn],c=!r||Xr()||Yo(t)||ta(r,o);return Pi(c),c?w_(n[Fe],i):Jl(r,e,n,t)}function lD(){Nv=sD}function g(e){return A("",e,""),g}function A(e,n,t){let i=he(),o=S2(i,e,n,t);return o!==Vt&&Af(i,Fn(),o),A}function le(e,n,t,i,o){let r=he(),c=w2(r,e,n,t,i,o);return c!==Vt&&Af(r,Fn(),c),le}function gt(e,n,t,i,o,r,c){let u=he(),m=E2(u,e,n,t,i,o,r,c);return m!==Vt&&Af(u,Fn(),m),gt}function Af(e,n,t){let i=hC(n,e);wE(e[Fe],i,t)}function R(e,n,t){YC(n)&&(n=n());let i=he(),o=Go();if(ln(i,o,n)){let r=Xe(),c=Jp();U_(r,c,i,e,n,i[Fe],t,!1)}return R}function L(e,n){let t=YC(e);return t&&e.set(n),t}function F(e,n){let t=he(),i=Xe(),o=Pt();return Ov(i,t,t[Fe],o,e,n),F}function cD(e,n,t){let i=Xe();if(i.firstCreatePass){let o=On(e);Dp(t,i.data,i.blueprint,o,!0),Dp(n,i.data,i.blueprint,o,!1)}}function Dp(e,n,t,i,o){if(e=Mt(e),Array.isArray(e))for(let r=0;r<e.length;r++)Dp(e[r],n,t,i,o);else{let r=Xe(),c=he(),u=Pt(),m=Lo(e)?e:Mt(e.provide),f=aC(e),C=u.providerIndexes&1048575,b=u.directiveStart,P=u.providerIndexes>>20;if(Lo(e)||!e.multi){let x=new Zi(f,o,me),D=Nm(m,n,o?C:C+P,b);D===-1?(zm(cl(u,c),r,m),Om(r,e,n.length),n.push(m),u.directiveStart++,u.directiveEnd++,o&&(u.providerIndexes+=1048576),t.push(x),c.push(x)):(t[D]=x,c[D]=x)}else{let x=Nm(m,n,C+P,b),D=Nm(m,n,C,C+P),V=x>=0&&t[x],q=D>=0&&t[D];if(o&&!q||!o&&!V){zm(cl(u,c),r,m);let te=mD(o?uD:dD,t.length,o,i,f);!o&&q&&(t[D].providerFactory=te),Om(r,e,n.length,0),n.push(m),u.directiveStart++,u.directiveEnd++,o&&(u.providerIndexes+=1048576),t.push(te),c.push(te)}else{let te=kv(t[o?D:x],f,!o&&i);Om(r,e,x>-1?x:D,te)}!o&&i&&q&&t[D].componentProviders++}}}function Om(e,n,t,i){let o=Lo(n),r=oS(n);if(o||r){let m=(r?Mt(n.useClass):n).prototype.ngOnDestroy;if(m){let f=e.destroyHooks||(e.destroyHooks=[]);if(!o&&n.multi){let C=f.indexOf(t);C===-1?f.push(t,[i,m]):f[C+1].push(i,m)}else f.push(t,m)}}}function kv(e,n,t){return t&&e.componentProviders++,e.multi.push(n)-1}function Nm(e,n,t,i){for(let o=t;o<i;o++)if(n[o]===e)return o;return-1}function dD(e,n,t,i,o){return Ip(this.multi,[])}function uD(e,n,t,i,o){let r=this.multi,c;if(this.providerFactory){let u=this.providerFactory.componentProviders,m=$r(i,i[ie],this.providerFactory.index,o);c=m.slice(0,u),Ip(r,c);for(let f=u;f<m.length;f++)c.push(m[f])}else c=[],Ip(r,c);return c}function Ip(e,n){for(let t=0;t<e.length;t++){let i=e[t];n.push(i())}return n}function mD(e,n,t,i,o){let r=new Zi(e,t,me);return r.multi=[],r.index=n,r.componentProviders=0,kv(r,o,i&&!t),r}function cn(e,n=[]){return t=>{t.providersResolver=(i,o)=>cD(i,o?o(e):e,n)}}function Av(e,n,t,i){return pD(he(),SC(),e,n,t,i)}function Rv(e,n){let t=e[n];return t===Vt?void 0:t}function pD(e,n,t,i,o,r){let c=n+t;return ln(e,c,o)?fv(e,c+1,r?i.call(r,o):i(o)):Rv(e,c+1)}function fD(e,n,t,i,o,r,c){let u=n+t;return Of(e,u,o,r)?fv(e,u+2,c?i.call(c,o,r):i(o,r)):Rv(e,u+2)}function Be(e,n){let t=Xe(),i,o=e+Ge;t.firstCreatePass?(i=hD(n,t.pipeRegistry),t.data[o]=i,i.onDestroy&&(t.destroyHooks??=[]).push(o,i.onDestroy)):i=t.data[o];let r=i.factory||(i.factory=Gi(i.type,!0)),c,u=Nt(me);try{let m=ll(!1),f=r();return ll(m),gS(t,he(),o,f),f}finally{Nt(u)}}function hD(e,n){if(n)for(let t=n.length-1;t>=0;t--){let i=n[t];if(e===i.name)return i}}function He(e,n,t,i){let o=e+Ge,r=he(),c=gC(r,o);return gD(r,o)?fD(r,SC(),n,c.transform,t,i,c):c.transform(t,i)}function gD(e,n){return e[ie].data[n].pure}function Zo(e,n){return Wl(e,n)}var Tp=class{ngModuleFactory;componentFactories;constructor(n,t){this.ngModuleFactory=n,this.componentFactories=t}},Fv=(()=>{class e{compileModuleSync(t){return new gp(t)}compileModuleAsync(t){return Promise.resolve(this.compileModuleSync(t))}compileModuleAndAllComponentsSync(t){let i=this.compileModuleSync(t),o=tC(t),r=N_(o.declarations).reduce((c,u)=>{let m=qi(u);return m&&c.push(new Jr(m)),c},[]);return new Tp(i,r)}compileModuleAndAllComponentsAsync(t){return Promise.resolve(this.compileModuleAndAllComponentsSync(t))}clearCache(){}clearCacheFor(t){}getModuleId(t){}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();
7var CD=(()=>{class e{zone=h(Ke);changeDetectionScheduler=h(Qi);applicationRef=h(Rt);_onMicrotaskEmptySubscription;initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.changeDetectionScheduler.runningTick||this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),_D=new K("",{factory:()=>!1});function Lv({ngZoneFactory:e,ignoreChangesOutsideZone:n,scheduleInRootZone:t}){return e??=()=>new Ke(oe(U({},Uv()),{scheduleInRootZone:t})),[{provide:Ke,useFactory:e},{provide:Si,multi:!0,useFactory:()=>{let i=h(CD,{optional:!0});return()=>i.initialize()}},{provide:Si,multi:!0,useFactory:()=>{let i=h(vD);return()=>{i.initialize()}}},n===!0?{provide:GC,useValue:!0}:[],{provide:WC,useValue:t??zC}]}function Vv(e){let n=e?.ignoreChangesOutsideZone,t=e?.scheduleInRootZone,i=Lv({ngZoneFactory:()=>{let o=Uv(e);return o.scheduleInRootZone=t,o.shouldCoalesceEventChangeDetection&&Vn("NgZone_CoalesceEvent"),new Ke(o)},ignoreChangesOutsideZone:n,scheduleInRootZone:t});return Mi([{provide:_D,useValue:!0},{provide:kl,useValue:!1},i])}function Uv(e){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:e?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:e?.runCoalescing??!1}}var vD=(()=>{class e{subscription=new Qe;initialized=!1;zone=h(Ke);pendingTasks=h(Ln);initialize(){if(this.initialized)return;this.initialized=!0;let t=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(t=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Ke.assertNotInAngularZone(),queueMicrotask(()=>{t!==null&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(t),t=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Ke.assertInAngularZone(),t??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();var yD=(()=>{class e{appRef=h(Rt);taskService=h(Ln);ngZone=h(Ke);zonelessEnabled=h(kl);tracing=h(Ko,{optional:!0});disableScheduling=h(GC,{optional:!0})??!1;zoneIsDefined=typeof Zone<"u"&&!!Zone.root.run;schedulerTickApplyArgs=[{data:{__scheduler_tick__:!0}}];subscriptions=new Qe;angularZoneId=this.zoneIsDefined?this.ngZone._inner?.get(ul):null;scheduleInRootZone=!this.zonelessEnabled&&this.zoneIsDefined&&(h(WC,{optional:!0})??!1);cancelScheduledCallback=null;useMicrotaskScheduler=!1;runningTick=!1;pendingRenderTaskId=null;constructor(){this.subscriptions.add(this.appRef.afterTick.subscribe(()=>{this.runningTick||this.cleanup()})),this.subscriptions.add(this.ngZone.onUnstable.subscribe(()=>{this.runningTick||this.cleanup()})),this.disableScheduling||=!this.zonelessEnabled&&(this.ngZone instanceof Km||!this.zoneIsDefined)}notify(t){if(!this.zonelessEnabled&&t===5)return;let i=!1;switch(t){case 0:{this.appRef.dirtyFlags|=2;break}case 3:case 2:case 4:case 5:case 1:{this.appRef.dirtyFlags|=4;break}case 6:{this.appRef.dirtyFlags|=2,i=!0;break}case 12:{this.appRef.dirtyFlags|=16,i=!0;break}case 13:{this.appRef.dirtyFlags|=2,i=!0;break}case 11:{i=!0;break}default:this.appRef.dirtyFlags|=8}if(this.appRef.tracingSnapshot=this.tracing?.snapshot(this.appRef.tracingSnapshot)??null,!this.shouldScheduleTick(i))return;let o=this.useMicrotaskScheduler?o0:qC;this.pendingRenderTaskId=this.taskService.add(),this.scheduleInRootZone?this.cancelScheduledCallback=Zone.root.run(()=>o(()=>this.tick())):this.cancelScheduledCallback=this.ngZone.runOutsideAngular(()=>o(()=>this.tick()))}shouldScheduleTick(t){return!(this.disableScheduling&&!t||this.appRef.destroyed||this.pendingRenderTaskId!==null||this.runningTick||this.appRef._runningTick||!this.zonelessEnabled&&this.zoneIsDefined&&Zone.current.get(ul+this.angularZoneId))}tick(){if(this.runningTick||this.appRef.destroyed)return;if(this.appRef.dirtyFlags===0){this.cleanup();return}!this.zonelessEnabled&&this.appRef.dirtyFlags&7&&(this.appRef.dirtyFlags|=1);let t=this.taskService.add();try{this.ngZone.run(()=>{this.runningTick=!0,this.appRef._tick()},void 0,this.schedulerTickApplyArgs)}catch(i){throw this.taskService.remove(t),i}finally{this.cleanup()}
7this.useMicrotaskScheduler=!0,o0(()=>{this.useMicrotaskScheduler=!1,this.taskService.remove(t)})}ngOnDestroy(){this.subscriptions.unsubscribe(),this.cleanup()}cleanup(){if(this.runningTick=!1,this.cancelScheduledCallback?.(),this.cancelScheduledCallback=null,this.pendingRenderTaskId!==null){let t=this.pendingRenderTaskId;this.pendingRenderTaskId=null,this.taskService.remove(t)}}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();function bD(){return typeof $localize<"u"&&$localize.locale||Sl}var la=new K("",{providedIn:"root",factory:()=>h(la,de.Optional|de.SkipSelf)||bD()});var Op=new K(""),xD=new K("");function Fr(e){return!e.moduleRef}function SD(e){let n=Fr(e)?e.r3Injector:e.moduleRef.injector,t=n.get(Ke);return t.run(()=>{Fr(e)?e.r3Injector.resolveInjectorInitializers():e.moduleRef.resolveInjectorInitializers();let i=n.get(kn,null),o;if(t.runOutsideAngular(()=>{o=t.onError.subscribe({next:r=>{i.handleError(r)}})}),Fr(e)){let r=()=>n.destroy(),c=e.platformInjector.get(Op);c.add(r),n.onDestroy(()=>{o.unsubscribe(),c.delete(r)})}else{let r=()=>e.moduleRef.destroy(),c=e.platformInjector.get(Op);c.add(r),e.moduleRef.onDestroy(()=>{Ks(e.allPlatformModules,e.moduleRef),o.unsubscribe(),c.delete(r)})}return ED(i,t,()=>{let r=n.get(vv);return r.runInitializers(),r.donePromise.then(()=>{let c=n.get(la,Sl);if(oD(c||Sl),!n.get(xD,!0))return Fr(e)?n.get(Rt):(e.allPlatformModules.push(e.moduleRef),e.moduleRef);if(Fr(e)){let m=n.get(Rt);return e.rootComponent!==void 0&&m.bootstrap(e.rootComponent),m}else return wD(e.moduleRef,e.allPlatformModules),e.moduleRef})})})}function wD(e,n){let t=e.injector.get(Rt);if(e._bootstrapComponents.length>0)e._bootstrapComponents.forEach(i=>t.bootstrap(i));else if(e.instance.ngDoBootstrap)e.instance.ngDoBootstrap(t);else throw new J(-403,!1);n.push(e)}function ED(e,n,t){try{let i=t();return ro(i)?i.catch(o=>{throw n.runOutsideAngular(()=>e.handleError(o)),o}):i}catch(i){throw n.runOutsideAngular(()=>e.handleError(i)),i}}var Ys=null;function MD(e=[],n){return sn.create({name:n,providers:[{provide:Pl,useValue:"platform"},{provide:Op,useValue:new Set([()=>Ys=null])},...e]})}function PD(e=[]){if(Ys)return Ys;let n=MD(e);return Ys=n,c2(),DD(n),n}function DD(e){let n=e.get(tf,null);Kt(e,()=>{n?.forEach(t=>t())})}var Qo=(()=>{class e{static __NG_ELEMENT_ID__=ID}return e})();function ID(e){return TD(Pt(),he(),(e&16)===16)}function TD(e,n,t){if(eo(e)&&!t){let i=Nn(e.index,n);return new Gr(i,i)}else if(e.type&175){let i=n[Jt];return new Gr(i,n)}return null}function jv(e){let{rootComponent:n,appProviders:t,platformProviders:i,platformRef:o}=e;Ee(8);try{let r=o?.injector??PD(i),c=[Lv({}),{provide:Qi,useExisting:yD},...t||[]],u=new vl({providers:c,parent:r,debugName:"",runEnvironmentInitializers:!1});return SD({r3Injector:u.injector,platformInjector:r,rootComponent:n})}catch(r){return Promise.reject(r)}finally{Ee(9)}}var $s=new WeakSet,L0="",Zs=[];function V0(e){return e.get(u_,Nw)}function Bv(){let e=[{provide:u_,useFactory:()=>{let n=!0;{let t=h(ti);n=!!window._ejsas?.[t]}return n&&Vn("NgEventReplay"),n}}];return e.push({provide:Si,useValue:()=>{let n=h(Rt),{injector:t}=n;if(!$s.has(n)){let i=h(c0);if(V0(t)){nE();let o=t.get(ti),r=eE(o,(c,u,m)=>{c.nodeType===Node.ELEMENT_NODE&&(Yw(c,u,m),Zw(c,i))});n.onDestroy(r)}}},multi:!0},{provide:ao,useFactory:()=>{let n=h(Rt),{injector:t}=n;return()=>{!V0(t)||$s.has(n)||($s.add(n),n.onDestroy(()=>{$s.delete(n);{let i=t.get(ti);pm(i)}}),n.whenStable().then(()=>{if(n.destroyed)return;let i=t.get(Xw);OD(i,t);let o=t.get(c0);o.get(L0)?.forEach(Qw),o.delete(L0);let r=i.instance;mE(t)?n.onDestroy(()=>r.cleanUp()):r.cleanUp()}))}},multi:!0}),e}var OD=(e,n)=>{let t=n.get(ti),i=window._ejsas[t],o=e.instance=new Hg(new Vs(i.c));for(let u of i.et)o.addEvent(u);for(let u of i.etc)o.addEvent(u);let r=$g(t);o.replayEarlyEventInfos(r),pm(t);let c=new Us(u=>{ND(n,u,u.currentTarget)});Bg(o,c)};function ND(e,n,t){let i=(t&&t.getAttribute(Ll))??"";/d\d+/.test(i)?kD(i,e,n,t):n.eventPhase===mm.REPLAY&&g_(n,t)}function kD(e,n,t,i){Zs.push({event:t,currentTarget:i}),g2(n,e,AD)}function AD(e){let n=[...Zs],t=new Set(e);Zs=[];
7for(let{event:i,currentTarget:o}of n){let r=o.getAttribute(Ll);t.has(r)?g_(i,o):Zs.push({event:i,currentTarget:o})}}var U0=!1;function RD(){U0||(U0=!0,lE(),Y2(),lD(),X2(),e2(),DP(),tP(),KE())}function FD(e){return e.whenStable()}function Hv(){let e=[{provide:js,useFactory:()=>{let n=!0;return n=!!h(Jo,{optional:!0})?.get(__,null),n&&Vn("NgHydration"),n}},{provide:Si,useValue:()=>{JM(!1),h(js)&&(gE(Al()),RD())},multi:!0}];return e.push({provide:d_,useFactory:()=>h(js)},{provide:ao,useFactory:()=>{if(h(js)){let n=h(Rt);return()=>{FD(n).then(()=>{n.destroyed||tv(n)})}}return()=>{}},multi:!0}),Mi(e)}function lo(e){return typeof e=="boolean"?e:e!=null&&e!=="false"}function si(e){return Uu(e)}function G(e,n){return Ru(e,n?.equal)}var j0=class{[rn];constructor(n){this[rn]=n}destroy(){this[rn].destroy()}};var $e=new K("");var Gv=null;function Xt(){return Gv}function Rf(e){Gv??=e}var ca=class{},Ff=(()=>{class e{historyGo(t){throw new Error("")}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:()=>h(Wv),providedIn:"platform"})}return e})();var Wv=(()=>{class e extends Ff{_location;_history;_doc=h($e);constructor(){super(),this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return Xt().getBaseHref(this._doc)}onPopState(t){let i=Xt().getGlobalEventTarget(this._doc,"window");return i.addEventListener("popstate",t,!1),()=>i.removeEventListener("popstate",t)}onHashChange(t){let i=Xt().getGlobalEventTarget(this._doc,"window");return i.addEventListener("hashchange",t,!1),()=>i.removeEventListener("hashchange",t)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(t){this._location.pathname=t}pushState(t,i,o){this._history.pushState(t,i,o)}replaceState(t,i,o){this._history.replaceState(t,i,o)}forward(){this._history.forward()}back(){this._history.back()}historyGo(t=0){this._history.go(t)}getState(){return this._history.state}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:()=>new e,providedIn:"platform"})}return e})();function qv(e,n){return e?n?e.endsWith("/")?n.startsWith("/")?e+n.slice(1):e+n:n.startsWith("/")?e+n:`${e}/${n}`:e:n}function $v(e){let n=e.search(/#|\?|$/);return e[n-1]==="/"?e.slice(0,n-1)+e.slice(n):e}function Ti(e){return e&&e[0]!=="?"?`?${e}`:e}var Xo=(()=>{class e{historyGo(t){throw new Error("")}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:()=>h(Kv),providedIn:"root"})}return e})(),Jv=new K(""),Kv=(()=>{class e extends Xo{_platformLocation;_baseHref;_removeListenerFns=[];constructor(t,i){super(),this._platformLocation=t,this._baseHref=i??this._platformLocation.getBaseHrefFromDOM()??h($e).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(t){this._removeListenerFns.push(this._platformLocation.onPopState(t),this._platformLocation.onHashChange(t))}getBaseHref(){return this._baseHref}prepareExternalUrl(t){return qv(this._baseHref,t)}path(t=!1){let i=this._platformLocation.pathname+Ti(this._platformLocation.search),o=this._platformLocation.hash;return o&&t?`${i}${o}`:i}pushState(t,i,o,r){let c=this.prepareExternalUrl(o+Ti(r));this._platformLocation.pushState(t,i,c)}replaceState(t,i,o,r){let c=this.prepareExternalUrl(o+Ti(r));this._platformLocation.replaceState(t,i,c)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(t=0){this._platformLocation.historyGo?.(t)}static \u0275fac=function(i){return new(i||e)(re(Ff),re(Jv,8))};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),er=(()=>{class e{_subject=new Ue;_basePath;_locationStrategy;_urlChangeListeners=[];_urlChangeSubscription=null;constructor(t){this._locationStrategy=t;let i=this._locationStrategy.getBaseHref();this._basePath=UD($v(zv(i))),this._locationStrategy.onPopState(o=>{this._subject.next({url:this.path(!0),pop:!0,state:o.state,type:o.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(t=!1){return this.normalize(this._locationStrategy.path(t))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(t,i=""){return this.path()==this.normalize(t+Ti(i))}normalize(t){return e.stripTrailingSlash(VD(this._basePath,zv(t)))}prepareExternalUrl(t){return t&&t[0]!=="/"&&(t="/"+t),this._locationStrategy.prepareExternalUrl(t)}
vendor: 2,544 bytes, line 7
7go(t,i="",o=null){this._locationStrategy.pushState(o,"",t,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+Ti(i)),o)}replaceState(t,i="",o=null){this._locationStrategy.replaceState(o,"",t,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+Ti(i)),o)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(t=0){this._locationStrategy.historyGo?.(t)}onUrlChange(t){return this._urlChangeListeners.push(t),this._urlChangeSubscription??=this.subscribe(i=>{this._notifyUrlChangeListeners(i.url,i.state)}),()=>{let i=this._urlChangeListeners.indexOf(t);this._urlChangeListeners.splice(i,1),this._urlChangeListeners.length===0&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(t="",i){this._urlChangeListeners.forEach(o=>o(t,i))}subscribe(t,i,o){return this._subject.subscribe({next:t,error:i??void 0,complete:o??void 0})}static normalizeQueryParams=Ti;static joinWithSlash=qv;static stripTrailingSlash=$v;static \u0275fac=function(i){return new(i||e)(re(Xo))};static \u0275prov=O({token:e,factory:()=>LD(),providedIn:"root"})}return e})();function LD(){return new er(re(Xo))}function VD(e,n){if(!e||!n.startsWith(e))return n;let t=n.substring(e.length);return t===""||["/",";","?","#"].includes(t[0])?t:n}function zv(e){return e.replace(/\/index.html$/,"")}function UD(e){if(new RegExp("^(https?:)?//").test(e)){let[,t]=e.split(/\/\/[^\/]+/);return t}return e}var Hf=(function(e){return e[e.Decimal=0]="Decimal",e[e.Percent=1]="Percent",e[e.Currency=2]="Currency",e[e.Scientific=3]="Scientific",e})(Hf||{});var xt=(function(e){return e[e.Format=0]="Format",e[e.Standalone=1]="Standalone",e})(xt||{}),Oe=(function(e){return e[e.Narrow=0]="Narrow",e[e.Abbreviated=1]="Abbreviated",e[e.Wide=2]="Wide",e[e.Short=3]="Short",e})(Oe||{}),jt=(function(e){return e[e.Short=0]="Short",e[e.Medium=1]="Medium",e[e.Long=2]="Long",e[e.Full=3]="Full",e})(jt||{}),Bt={Decimal:0,Group:1,List:2,PercentSign:3,PlusSign:4,MinusSign:5,Exponential:6,SuperscriptingExponent:7,PerMille:8,Infinity:9,NaN:10,TimeSeparator:11,CurrencyDecimal:12,CurrencyGroup:13};function Qv(e){return Qt(e)[Ye.LocaleId]}function Xv(e,n,t){let i=Qt(e),o=[i[Ye.DayPeriodsFormat],i[Ye.DayPeriodsStandalone]],r=dn(o,n);return dn(r,t)}function ey(e,n,t){let i=Qt(e),o=[i[Ye.DaysFormat],i[Ye.DaysStandalone]],r=dn(o,n);return dn(r,t)}function ty(e,n,t){let i=Qt(e),o=[i[Ye.MonthsFormat],i[Ye.MonthsStandalone]],r=dn(o,n);return dn(r,t)}function ny(e,n){let i=Qt(e)[Ye.Eras];return dn(i,n)}
vendor: 16,953 bytes, line 7
7function da(e,n){let t=Qt(e);return dn(t[Ye.DateFormat],n)}function ua(e,n){let t=Qt(e);return dn(t[Ye.TimeFormat],n)}function ma(e,n){let i=Qt(e)[Ye.DateTimeFormat];return dn(i,n)}function Un(e,n){let t=Qt(e),i=t[Ye.NumberSymbols][n];if(typeof i>"u"){if(n===Bt.CurrencyDecimal)return t[Ye.NumberSymbols][Bt.Decimal];if(n===Bt.CurrencyGroup)return t[Ye.NumberSymbols][Bt.Group]}return i}function iy(e,n){return Qt(e)[Ye.NumberFormats][n]}function oy(e){if(!e[Ye.ExtraData])throw new Error(`Missing extra locale data for the locale "${e[Ye.LocaleId]}". Use "registerLocaleData" to load new data. See the "I18n guide" on angular.io to know more.`)}function ry(e){let n=Qt(e);return oy(n),(n[Ye.ExtraData][2]||[]).map(i=>typeof i=="string"?Lf(i):[Lf(i[0]),Lf(i[1])])}function ay(e,n,t){let i=Qt(e);oy(i);let o=[i[Ye.ExtraData][0],i[Ye.ExtraData][1]],r=dn(o,n)||[];return dn(r,t)||[]}function dn(e,n){for(let t=n;t>-1;t--)if(typeof e[t]<"u")return e[t];throw new Error("Locale data API: locale data undefined")}function Lf(e){let[n,t]=e.split(":");return{hours:+n,minutes:+t}}var jD=/^(\d{4,})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/,ec={},BD=/((?:[^BEGHLMOSWYZabcdhmswyz']+)|(?:'(?:[^']|'')*')|(?:G{1,5}|y{1,4}|Y{1,4}|M{1,5}|L{1,5}|w{1,2}|W{1}|d{1,2}|E{1,6}|c{1,6}|a{1,5}|b{1,5}|B{1,5}|h{1,2}|H{1,2}|m{1,2}|s{1,2}|S{1,3}|z{1,4}|Z{1,5}|O{1,4}))([\s\S]*)/;function sy(e,n,t,i){let o=YD(e);n=li(t,n)||n;let c=[],u;for(;n;)if(u=BD.exec(n),u){c=c.concat(u.slice(1));let C=c.pop();if(!C)break;n=C}else{c.push(n);break}let m=o.getTimezoneOffset();i&&(m=cy(i,m),o=KD(o,i));let f="";return c.forEach(C=>{let b=qD(C);f+=b?b(o,t,m):C==="''"?"'":C.replace(/(^'|'$)/g,"").replace(/''/g,"'")}),f}function rc(e,n,t){let i=new Date(0);return i.setFullYear(e,n,t),i.setHours(0,0,0),i}function li(e,n){let t=Qv(e);if(ec[t]??={},ec[t][n])return ec[t][n];let i="";switch(n){case"shortDate":i=da(e,jt.Short);break;case"mediumDate":i=da(e,jt.Medium);break;case"longDate":i=da(e,jt.Long);break;case"fullDate":i=da(e,jt.Full);break;case"shortTime":i=ua(e,jt.Short);break;case"mediumTime":i=ua(e,jt.Medium);break;case"longTime":i=ua(e,jt.Long);break;case"fullTime":i=ua(e,jt.Full);break;case"short":let o=li(e,"shortTime"),r=li(e,"shortDate");i=tc(ma(e,jt.Short),[o,r]);break;case"medium":let c=li(e,"mediumTime"),u=li(e,"mediumDate");i=tc(ma(e,jt.Medium),[c,u]);break;case"long":let m=li(e,"longTime"),f=li(e,"longDate");i=tc(ma(e,jt.Long),[m,f]);break;case"full":let C=li(e,"fullTime"),b=li(e,"fullDate");i=tc(ma(e,jt.Full),[C,b]);break}return i&&(ec[t][n]=i),i}function tc(e,n){return n&&(e=e.replace(/\{([^}]+)}/g,function(t,i){return n!=null&&i in n?n[i]:t})),e}function En(e,n,t="-",i,o){let r="";(e<0||o&&e<=0)&&(o?e=-e+1:(e=-e,r=t));let c=String(e);for(;c.length<n;)c="0"+c;return i&&(c=c.slice(c.length-n)),r+c}function HD(e,n){return En(e,3).substring(0,n)}function et(e,n,t=0,i=!1,o=!1){return function(r,c){let u=$D(e,r);if((t>0||u>-t)&&(u+=t),e===3)u===0&&t===-12&&(u=12);else if(e===6)return HD(u,n);let m=Un(c,Bt.MinusSign);return En(u,n,m,i,o)}}function $D(e,n){switch(e){case 0:return n.getFullYear();case 1:return n.getMonth();case 2:return n.getDate();case 3:return n.getHours();case 4:return n.getMinutes();case 5:return n.getSeconds();case 6:return n.getMilliseconds();case 7:return n.getDay();default:throw new Error(`Unknown DateType value "${e}".`)}}function Ve(e,n,t=xt.Format,i=!1){return function(o,r){return zD(o,r,e,n,t,i)}}function zD(e,n,t,i,o,r){switch(t){case 2:return ty(n,o,i)[e.getMonth()];case 1:return ey(n,o,i)[e.getDay()];case 0:let c=e.getHours(),u=e.getMinutes();if(r){let f=ry(n),C=ay(n,o,i),b=f.findIndex(P=>{if(Array.isArray(P)){let[x,D]=P,V=c>=x.hours&&u>=x.minutes,q=c<D.hours||c===D.hours&&u<D.minutes;if(x.hours<D.hours){if(V&&q)return!0}else if(V||q)return!0}else if(P.hours===c&&P.minutes===u)return!0;return!1});if(b!==-1)return C[b]}return Xv(n,o,i)[c<12?0:1];case 3:return ny(n,i)[e.getFullYear()<=0?0:1];default:let m=t;throw new Error(`unexpected translation type ${m}`)}}function nc(e){return function(n,t,i){let o=-1*i,r=Un(t,Bt.MinusSign),c=o>0?Math.floor(o/60):Math.ceil(o/60);switch(e){case 0:return(o>=0?"+":"")+En(c,2,r)+En(Math.abs(o%60),2,r);case 1:return"GMT"+(o>=0?"+":"")+En(c,1,r);case 2:return"GMT"+(o>=0?"+":"")+En(c,2,r)+":"+En(Math.abs(o%60),2,r);case 3:return i===0?"Z":(o>=0?"+":"")+En(c,2,r)+":"+En(Math.abs(o%60),2,r);default:throw new Error(`Unknown zone width "${e}"`)}}}var GD=0,oc=4;function WD(e){let n=rc(e,GD,1).getDay();return rc(e,0,1+(n<=oc?oc:oc+7)-n)}function ly(e){let n=e.getDay(),t=n===0?-3:oc-n;return rc(e.getFullYear(),e.getMonth(),e.getDate()+t)}function Vf(e,n=!1){return function(t,i){let o;if(n){let r=new Date(t.getFullYear(),t.getMonth(),1).getDay()-1,c=t.getDate();o=1+Math.floor((c+r)/7)}else{let r=ly(t),c=WD(r.getFullYear()),u=r.getTime()-c.getTime();o=1+Math.round(u/6048e5)}return En(o,e,Un(i,Bt.MinusSign))}}function ic(e,n=!1){return function(t,i){let r=ly(t).getFullYear();return En(r,e,Un(i,Bt.MinusSign),n)}}var Uf={};function qD(e){if(Uf[e])return Uf[e];let n;switch(e){case"G":case"GG":case"GGG":n=Ve(3,Oe.Abbreviated);break;case"GGGG":n=Ve(3,Oe.Wide);break;case"GGGGG":n=Ve(3,Oe.Narrow);break;case"y":n=et(0,1,0,!1,!0);break;case"yy":n=et(0,2,0,!0,!0);break;case"yyy":n=et(0,3,0,!1,!0);break;case"yyyy":n=et(0,4,0,!1,!0);break;case"Y":n=ic(1);break;case"YY":n=ic(2,!0);break;case"YYY":n=ic(3);break;case"YYYY":n=ic(4);break;case"M":case"L":n=et(1,1,1);break;case"MM":case"LL":n=et(1,2,1);break;case"MMM":n=Ve(2,Oe.Abbreviated);break;case"MMMM":n=Ve(2,Oe.Wide);break;case"MMMMM":n=Ve(2,Oe.Narrow);break;case"LLL":n=Ve(2,Oe.Abbreviated,xt.Standalone);break;case"LLLL":n=Ve(2,Oe.Wide,xt.Standalone);break;case"LLLLL":n=Ve(2,Oe.Narrow,xt.Standalone);break;case"w":n=Vf(1);break;case"ww":n=Vf(2);break;case"W":n=Vf(1,!0);break;case"d":n=et(2,1);break;case"dd":n=et(2,2);break;case"c":case"cc":n=et(7,1);break;case"ccc":n=Ve(1,Oe.Abbreviated,xt.Standalone);break;case"cccc":n=Ve(1,Oe.Wide,xt.Standalone);break;case"ccccc":n=Ve(1,Oe.Narrow,xt.Standalone);break;case"cccccc":n=Ve(1,Oe.Short,xt.Standalone);break;case"E":case"EE":case"EEE":n=Ve(1,Oe.Abbreviated);break;case"EEEE":n=Ve(1,Oe.Wide);break;case"EEEEE":n=Ve(1,Oe.Narrow);break;case"EEEEEE":n=Ve(1,Oe.Short);break;case"a":case"aa":case"aaa":n=Ve(0,Oe.Abbreviated);break;case"aaaa":n=Ve(0,Oe.Wide);break;case"aaaaa":n=Ve(0,Oe.Narrow);break;case"b":case"bb":case"bbb":n=Ve(0,Oe.Abbreviated,xt.Standalone,!0);break;case"bbbb":n=Ve(0,Oe.Wide,xt.Standalone,!0);break;case"bbbbb":n=Ve(0,Oe.Narrow,xt.Standalone,!0);break;case"B":case"BB":case"BBB":n=Ve(0,Oe.Abbreviated,xt.Format,!0);break;case"BBBB":n=Ve(0,Oe.Wide,xt.Format,!0);break;case"BBBBB":n=Ve(0,Oe.Narrow,xt.Format,!0);break;case"h":n=et(3,1,-12);break;case"hh":n=et(3,2,-12);break;case"H":n=et(3,1);break;case"HH":n=et(3,2);break;case"m":n=et(4,1);break;case"mm":n=et(4,2);break;case"s":n=et(5,1);break;case"ss":n=et(5,2);break;case"S":n=et(6,1);break;case"SS":n=et(6,2);break;case"SSS":n=et(6,3);break;case"Z":case"ZZ":case"ZZZ":n=nc(0);break;case"ZZZZZ":n=nc(3);break;case"O":case"OO":case"OOO":case"z":case"zz":case"zzz":n=nc(1);break;case"OOOO":case"ZZZZ":case"zzzz":n=nc(2);break;default:return null}return Uf[e]=n,n}function cy(e,n){e=e.replace(/:/g,"");let t=Date.parse("Jan 01, 1970 00:00:00 "+e)/6e4;return isNaN(t)?n:t}function JD(e,n){return e=new Date(e.getTime()),e.setMinutes(e.getMinutes()+n),e}function KD(e,n,t){let o=e.getTimezoneOffset(),r=cy(n,o);return JD(e,-1*(r-o))}function YD(e){if(Yv(e))return e;if(typeof e=="number"&&!isNaN(e))return new Date(e);if(typeof e=="string"){if(e=e.trim(),/^(\d{4}(-\d{1,2}(-\d{1,2})?)?)$/.test(e)){let[o,r=1,c=1]=e.split("-").map(u=>+u);return rc(o,r-1,c)}let t=parseFloat(e);if(!isNaN(e-t))return new Date(t);let i;if(i=e.match(jD))return ZD(i)}let n=new Date(e);if(!Yv(n))throw new Error(`Unable to convert "${e}" into a date`);return n}function ZD(e){let n=new Date(0),t=0,i=0,o=e[8]?n.setUTCFullYear:n.setFullYear,r=e[8]?n.setUTCHours:n.setHours;e[9]&&(t=Number(e[9]+e[10]),i=Number(e[9]+e[11])),o.call(n,Number(e[1]),Number(e[2])-1,Number(e[3]));let c=Number(e[4]||0)-t,u=Number(e[5]||0)-i,m=Number(e[6]||0),f=Math.floor(parseFloat("0."+(e[7]||0))*1e3);return r.call(n,c,u,m,f),n}function Yv(e){return e instanceof Date&&!isNaN(e.valueOf())}var QD=/^(\d+)?\.((\d+)(-(\d+))?)?$/,Zv=22,ac=".",pa="0",XD=";",eI=",",jf="#";function tI(e,n,t,i,o,r,c=!1){let u="",m=!1;if(!isFinite(e))u=Un(t,Bt.Infinity);else{let f=oI(e);c&&(f=iI(f));let C=n.minInt,b=n.minFrac,P=n.maxFrac;if(r){let Ie=r.match(QD);if(Ie===null)throw new Error(`${r} is not a valid digit info`);let Pe=Ie[1],on=Ie[3],vo=Ie[5];Pe!=null&&(C=Bf(Pe)),on!=null&&(b=Bf(on)),vo!=null?P=Bf(vo):on!=null&&b>P&&(P=b);let pn=100;if(C>pn||b>pn||P>pn)throw new J(2306,!1)}rI(f,b,P);let x=f.digits,D=f.integerLen,V=f.exponent,q=[];for(m=x.every(Ie=>!Ie);D<C;D++)x.unshift(0);for(;D<0;D++)x.unshift(0);D>0?q=x.splice(D,x.length):(q=x,x=[0]);let te=[];for(x.length>=n.lgSize&&te.unshift(x.splice(-n.lgSize,x.length).join(""));x.length>n.gSize;)te.unshift(x.splice(-n.gSize,x.length).join(""));x.length&&te.unshift(x.join("")),u=te.join(Un(t,i)),q.length&&(u+=Un(t,o)+q.join("")),V&&(u+=Un(t,Bt.Exponential)+"+"+V)}return e<0&&!m?u=n.negPre+u+n.negSuf:u=n.posPre+u+n.posSuf,u}function dy(e,n,t){let i=iy(n,Hf.Decimal),o=nI(i,Un(n,Bt.MinusSign));return tI(e,o,n,Bt.Group,Bt.Decimal,t)}function nI(e,n="-"){let t={minInt:1,minFrac:0,maxFrac:0,posPre:"",posSuf:"",negPre:"",negSuf:"",gSize:0,lgSize:0},i=e.split(XD),o=i[0],r=i[1],c=o.indexOf(ac)!==-1?o.split(ac):[o.substring(0,o.lastIndexOf(pa)+1),o.substring(o.lastIndexOf(pa)+1)],u=c[0],m=c[1]||"";t.posPre=u.substring(0,u.indexOf(jf));for(let C=0;C<m.length;C++){let b=m.charAt(C);b===pa?t.minFrac=t.maxFrac=C+1:b===jf?t.maxFrac=C+1:t.posSuf+=b}let f=u.split(eI);if(t.gSize=f[1]?f[1].length:0,t.lgSize=f[2]||f[1]?(f[2]||f[1]).length:0,r){let C=o.length-t.posPre.length-t.posSuf.length,b=r.indexOf(jf);t.negPre=r.substring(0,b).replace(/'/g,""),t.negSuf=r.slice(b+C).replace(/'/g,"")}else t.negPre=n+t.posPre,t.negSuf=t.posSuf;return t}function iI(e){if(e.digits[0]===0)return e;let n=e.digits.length-e.integerLen;return e.exponent?e.exponent+=2:(n===0?e.digits.push(0,0):n===1&&e.digits.push(0),e.integerLen+=2),e}function oI(e){let n=Math.abs(e)+"",t=0,i,o,r,c,u;for((o=n.indexOf(ac))>-1&&(n=n.replace(ac,"")),(r=n.search(/e/i))>0?(o<0&&(o=r),o+=+n.slice(r+1),n=n.substring(0,r)):o<0&&(o=n.length),r=0;n.charAt(r)===pa;r++);if(r===(u=n.length))i=[0],o=1;else{for(u--;n.charAt(u)===pa;)u--;for(o-=r,i=[],c=0;r<=u;r++,c++)i[c]=Number(n.charAt(r))}return o>Zv&&(i=i.splice(0,Zv-1),t=o-1,o=1),{digits:i,exponent:t,integerLen:o}}function rI(e,n,t){if(n>t)throw new Error(`The minimum number of digits after fraction (${n}) is higher than the maximum (${t}).`);let i=e.digits,o=i.length-e.integerLen,r=Math.min(Math.max(n,o),t),c=r+e.integerLen,u=i[c];if(c>0){i.splice(Math.max(e.integerLen,c));for(let b=c;b<i.length;b++)i[b]=0}else{o=Math.max(0,o),e.integerLen=1,i.length=Math.max(1,c=r+1),i[0]=0;for(let b=1;b<c;b++)i[b]=0}if(u>=5)if(c-1<0){for(let b=0;b>c;b--)i.unshift(0),e.integerLen++;i.unshift(1),e.integerLen++}else i[c-1]++;for(;o<Math.max(0,r);o++)i.push(0);let m=r!==0,f=n+e.integerLen,C=i.reduceRight(function(b,P,x,D){return P=P+b,D[x]=P<10?P:P-10,m&&(D[x]===0&&x>=f?D.pop():m=!1),P>=10?1:0},0);C&&(i.unshift(C),e.integerLen++)}function Bf(e){let n=parseInt(e);if(isNaN(n))throw new Error("Invalid integer literal when parsing "+e);return n}var co=(()=>{class e{_viewContainerRef;_viewRef=null;ngTemplateOutletContext=null;ngTemplateOutlet=null;ngTemplateOutletInjector=null;constructor(t){this._viewContainerRef=t}ngOnChanges(t){if(this._shouldRecreateView(t)){let i=this._viewContainerRef;if(this._viewRef&&i.remove(i.indexOf(this._viewRef)),!this.ngTemplateOutlet){this._viewRef=null;return}let o=this._createContextForwardProxy();this._viewRef=i.createEmbeddedView(this.ngTemplateOutlet,o,{injector:this.ngTemplateOutletInjector??void 0})}}_shouldRecreateView(t){return!!t.ngTemplateOutlet||!!t.ngTemplateOutletInjector}_createContextForwardProxy(){return new Proxy({},{set:(t,i,o)=>this.ngTemplateOutletContext?Reflect.set(this.ngTemplateOutletContext,i,o):!1,get:(t,i,o)=>{if(this.ngTemplateOutletContext)return Reflect.get(this.ngTemplateOutletContext,i,o)}})}static \u0275fac=function(i){return new(i||e)(me(oo))};static \u0275dir=Le({type:e,selectors:[["","ngTemplateOutlet",""]],inputs:{ngTemplateOutletContext:"ngTemplateOutletContext",ngTemplateOutlet:"ngTemplateOutlet",ngTemplateOutletInjector:"ngTemplateOutletInjector"},features:[ct]})}return e})();function uy(e,n){return new J(2100,!1)}var aI="mediumDate",my=new K(""),py=new K(""),Ct=(()=>{class e{locale;defaultTimezone;defaultOptions;constructor(t,i,o){this.locale=t,this.defaultTimezone=i,this.defaultOptions=o}transform(t,i,o,r){if(t==null||t===""||t!==t)return null;try{let c=i??this.defaultOptions?.dateFormat??aI,u=o??this.defaultOptions?.timezone??this.defaultTimezone??void 0;return sy(t,c,r||this.locale,u)}catch(c){throw uy(e,c.message)}}static \u0275fac=function(i){return new(i||e)(me(la,16),me(my,24),me(py,24))};static \u0275pipe=Tf({name:"date",type:e,pure:!0})}return e})();var $f=(()=>{class e{_locale;constructor(t){this._locale=t}transform(t,i,o){if(!sI(t))return null;o||=this._locale;try{let r=lI(t);return dy(r,o,i)}catch(r){throw uy(e,r.message)}}static \u0275fac=function(i){return new(i||e)(me(la,16))};static \u0275pipe=Tf({name:"number",type:e,pure:!0})}return e})();function sI(e){return!(e==null||e===""||e!==e)}function lI(e){if(typeof e=="string"&&!isNaN(Number(e)-parseFloat(e)))return Number(e);if(typeof e!="number")throw new Error(`${e} is not a number`);return e}function fa(e,n){n=encodeURIComponent(n);for(let t of e.split(";")){let i=t.indexOf("="),[o,r]=i==-1?[t,""]:[t.slice(0,i),t.slice(i+1)];if(o.trim()===n)return decodeURIComponent(r)}return null}var sc="browser",fy="server";function un(e){return e===sc}function lc(e){return e===fy}var uo=class{};var uc=new K(""),qf=(()=>{class e{_zone;_plugins;_eventNameToPlugin=new Map;constructor(t,i){this._zone=i,t.forEach(o=>{o.manager=this}),this._plugins=t.slice().reverse()}addEventListener(t,i,o,r){return this._findPluginFor(i).addEventListener(t,i,o,r)}getZone(){return this._zone}_findPluginFor(t){let i=this._eventNameToPlugin.get(t);if(i)return i;if(i=this._plugins.find(r=>r.supports(t)),!i)throw new J(5101,!1);return this._eventNameToPlugin.set(t,i),i}static \u0275fac=function(i){return new(i||e)(re(uc),re(Ke))};static \u0275prov=O({token:e,factory:e.\u0275fac})}return e})(),ha=class{_doc;constructor(n){this._doc=n}manager},cc="ng-app-id";function hy(e){for(let n of e)n.remove()}function gy(e,n){let t=n.createElement("style");return t.textContent=e,t}function mI(e,n,t,i){let o=e.head?.querySelectorAll(`style[${cc}="${n}"],link[${cc}="${n}"]`);if(o)for(let r of o)r.removeAttribute(cc),r instanceof HTMLLinkElement?i.set(r.href.slice(r.href.lastIndexOf("/")+1),{usage:0,elements:[r]}):r.textContent&&t.set(r.textContent,{usage:0,elements:[r]})}function Gf(e,n){let t=n.createElement("link");return t.setAttribute("rel","stylesheet"),t.setAttribute("href",e),t}var Jf=(()=>{class e{doc;appId;nonce;inline=new Map;external=new Map;hosts=new Set;isServer;constructor(t,i,o,r={}){this.doc=t,this.appId=i,this.nonce=o,this.isServer=lc(r),mI(t,i,this.inline,this.external),this.hosts.add(t.head)}addStyles(t,i){for(let o of t)this.addUsage(o,this.inline,gy);i?.forEach(o=>this.addUsage(o,this.external,Gf))}removeStyles(t,i){for(let o of t)this.removeUsage(o,this.inline);i?.forEach(o=>this.removeUsage(o,this.external))}addUsage(t,i,o){let r=i.get(t);r?r.usage++:i.set(t,{usage:1,elements:[...this.hosts].map(c=>this.addElement(c,o(t,this.doc)))})}removeUsage(t,i){let o=i.get(t);o&&(o.usage--,o.usage<=0&&(hy(o.elements),i.delete(t)))}ngOnDestroy(){for(let[,{elements:t}]of[...this.inline,...this.external])hy(t);this.hosts.clear()}addHost(t){this.hosts.add(t);for(let[i,{elements:o}]of this.inline)o.push(this.addElement(t,gy(i,this.doc)));for(let[i,{elements:o}]of this.external)o.push(this.addElement(t,Gf(i,this.doc)))}removeHost(t){this.hosts.delete(t)}addElement(t,i){return this.nonce&&i.setAttribute("nonce",this.nonce),this.isServer&&i.setAttribute(cc,this.appId),t.appendChild(i)}static \u0275fac=function(i){return new(i||e)(re($e),re(ti),re(nf,8),re(Zt))};static \u0275prov=O({token:e,factory:e.\u0275fac})}return e})(),zf={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/Math/MathML"},Kf=/%COMP%/g;var _y="%COMP%",pI=`_nghost-${_y}`,fI=`_ngcontent-${_y}`,hI=!0,gI=new K("",{providedIn:"root",factory:()=>hI});function CI(e){return fI.replace(Kf,e)}function _I(e){return pI.replace(Kf,e)}
vendor: 5,096 bytes, line 7
7function vy(e,n){return n.map(t=>t.replace(Kf,e))}var Yf=(()=>{class e{eventManager;sharedStylesHost;appId;removeStylesOnCompDestroy;doc;platformId;ngZone;nonce;tracingService;rendererByCompId=new Map;defaultRenderer;platformIsServer;constructor(t,i,o,r,c,u,m,f=null,C=null){this.eventManager=t,this.sharedStylesHost=i,this.appId=o,this.removeStylesOnCompDestroy=r,this.doc=c,this.platformId=u,this.ngZone=m,this.nonce=f,this.tracingService=C,this.platformIsServer=lc(u),this.defaultRenderer=new ga(t,c,m,this.platformIsServer,this.tracingService)}createRenderer(t,i){if(!t||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===An.ShadowDom&&(i=oe(U({},i),{encapsulation:An.Emulated}));let o=this.getOrCreateRenderer(t,i);return o instanceof dc?o.applyToHost(t):o instanceof Ca&&o.applyStyles(),o}getOrCreateRenderer(t,i){let o=this.rendererByCompId,r=o.get(i.id);if(!r){let c=this.doc,u=this.ngZone,m=this.eventManager,f=this.sharedStylesHost,C=this.removeStylesOnCompDestroy,b=this.platformIsServer,P=this.tracingService;switch(i.encapsulation){case An.Emulated:r=new dc(m,f,i,this.appId,C,c,u,b,P);break;case An.ShadowDom:return new Wf(m,f,t,i,c,u,this.nonce,b,P);default:r=new Ca(m,f,i,C,c,u,b,P);break}o.set(i.id,r)}return r}ngOnDestroy(){this.rendererByCompId.clear()}componentReplaced(t){this.rendererByCompId.delete(t)}static \u0275fac=function(i){return new(i||e)(re(qf),re(Jf),re(ti),re(gI),re($e),re(Zt),re(Ke),re(nf),re(Ko,8))};static \u0275prov=O({token:e,factory:e.\u0275fac})}return e})(),ga=class{eventManager;doc;ngZone;platformIsServer;tracingService;data=Object.create(null);throwOnSyntheticProps=!0;constructor(n,t,i,o,r){this.eventManager=n,this.doc=t,this.ngZone=i,this.platformIsServer=o,this.tracingService=r}destroy(){}destroyNode=null;createElement(n,t){return t?this.doc.createElementNS(zf[t]||t,n):this.doc.createElement(n)}createComment(n){return this.doc.createComment(n)}createText(n){return this.doc.createTextNode(n)}appendChild(n,t){(Cy(n)?n.content:n).appendChild(t)}insertBefore(n,t,i){n&&(Cy(n)?n.content:n).insertBefore(t,i)}removeChild(n,t){t.remove()}selectRootElement(n,t){let i=typeof n=="string"?this.doc.querySelector(n):n;if(!i)throw new J(-5104,!1);return t||(i.textContent=""),i}parentNode(n){return n.parentNode}nextSibling(n){return n.nextSibling}setAttribute(n,t,i,o){if(o){t=o+":"+t;let r=zf[o];r?n.setAttributeNS(r,t,i):n.setAttribute(t,i)}else n.setAttribute(t,i)}removeAttribute(n,t,i){if(i){let o=zf[i];o?n.removeAttributeNS(o,t):n.removeAttribute(`${i}:${t}`)}else n.removeAttribute(t)}addClass(n,t){n.classList.add(t)}removeClass(n,t){n.classList.remove(t)}setStyle(n,t,i,o){o&(ai.DashCase|ai.Important)?n.style.setProperty(t,i,o&ai.Important?"important":""):n.style[t]=i}removeStyle(n,t,i){i&ai.DashCase?n.style.removeProperty(t):n.style[t]=""}setProperty(n,t,i){n!=null&&(n[t]=i)}setValue(n,t){n.nodeValue=t}listen(n,t,i,o){if(typeof n=="string"&&(n=Xt().getGlobalEventTarget(this.doc,n),!n))throw new J(5102,!1);let r=this.decoratePreventDefault(i);return this.tracingService?.wrapEventListener&&(r=this.tracingService.wrapEventListener(n,t,r)),this.eventManager.addEventListener(n,t,r,o)}decoratePreventDefault(n){return t=>{if(t==="__ngUnwrap__")return n;(this.platformIsServer?this.ngZone.runGuarded(()=>n(t)):n(t))===!1&&t.preventDefault()}}};function Cy(e){return e.tagName==="TEMPLATE"&&e.content!==void 0}var Wf=class extends ga{sharedStylesHost;hostEl;shadowRoot;constructor(n,t,i,o,r,c,u,m,f){super(n,r,c,m,f),this.sharedStylesHost=t,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);let C=o.styles;C=vy(o.id,C);for(let P of C){let x=document.createElement("style");u&&x.setAttribute("nonce",u),x.textContent=P,this.shadowRoot.appendChild(x)}let b=o.getExternalStyles?.();if(b)for(let P of b){let x=Gf(P,r);u&&x.setAttribute("nonce",u),this.shadowRoot.appendChild(x)}}nodeOrShadowRoot(n){return n===this.hostEl?this.shadowRoot:n}appendChild(n,t){return super.appendChild(this.nodeOrShadowRoot(n),t)}insertBefore(n,t,i){return super.insertBefore(this.nodeOrShadowRoot(n),t,i)}removeChild(n,t){return super.removeChild(null,t)}parentNode(n){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(n)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}},Ca=class extends ga{sharedStylesHost;removeStylesOnCompDestroy;styles;styleUrls;constructor(n,t,i,o,r,c,u,m,f){super(n,r,c,u,m),this.sharedStylesHost=t,this.removeStylesOnCompDestroy=o;let C=i.styles;this.styles=f?vy(f,C):C,this.styleUrls=i.getExternalStyles?.(f)}applyStyles(){this.sharedStylesHost.addStyles(this.styles,this.styleUrls)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles,this.styleUrls)}},dc=class extends Ca{contentAttr;hostAttr;constructor(n,t,i,o,r,c,u,m,f){let C=o+"-"+i.id;super(n,t,i,r,c,u,m,f,C),this.contentAttr=CI(C),this.hostAttr=_I(C)}applyToHost(n){this.applyStyles(),this.setAttribute(n,this.hostAttr,"")}createElement(n,t){let i=super.createElement(n,t);return super.setAttribute(i,this.contentAttr,""),i}};
vendor: 3,937 bytes, lines 7-8
7var mc=class e extends ca{supportsDOMEvents=!0;static makeCurrent(){Rf(new e)}onAndCancel(n,t,i,o){return n.addEventListener(t,i,o),()=>{n.removeEventListener(t,i,o)}}dispatchEvent(n,t){n.dispatchEvent(t)}remove(n){n.remove()}createElement(n,t){return t=t||this.getDefaultDocument(),t.createElement(n)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(n){return n.nodeType===Node.ELEMENT_NODE}isShadowRoot(n){return n instanceof DocumentFragment}getGlobalEventTarget(n,t){return t==="window"?window:t==="document"?n:t==="body"?n.body:null}getBaseHref(n){let t=vI();return t==null?null:yI(t)}resetBaseElement(){_a=null}getUserAgent(){return window.navigator.userAgent}getCookie(n){return fa(document.cookie,n)}},_a=null;function vI(){return _a=_a||document.head.querySelector("base"),_a?_a.getAttribute("href"):null}function yI(e){return new URL(e,document.baseURI).pathname}var bI=(()=>{class e{build(){return new XMLHttpRequest}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac})}return e})(),by=(()=>{class e extends ha{constructor(t){super(t)}supports(t){return!0}addEventListener(t,i,o,r){return t.addEventListener(i,o,r),()=>this.removeEventListener(t,i,o,r)}removeEventListener(t,i,o,r){return t.removeEventListener(i,o,r)}static \u0275fac=function(i){return new(i||e)(re($e))};static \u0275prov=O({token:e,factory:e.\u0275fac})}return e})(),yy=["alt","control","meta","shift"],xI={"\b":"Backspace","	":"Tab","\x7F":"Delete","\x1B":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},SI={alt:e=>e.altKey,control:e=>e.ctrlKey,meta:e=>e.metaKey,shift:e=>e.shiftKey},xy=(()=>{class e extends ha{constructor(t){super(t)}supports(t){return e.parseEventName(t)!=null}addEventListener(t,i,o,r){let c=e.parseEventName(i),u=e.eventCallback(c.fullKey,o,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Xt().onAndCancel(t,c.domEventName,u,r))}static parseEventName(t){let i=t.toLowerCase().split("."),o=i.shift();if(i.length===0||!(o==="keydown"||o==="keyup"))return null;let r=e._normalizeKey(i.pop()),c="",u=i.indexOf("code");if(u>-1&&(i.splice(u,1),c="code."),yy.forEach(f=>{let C=i.indexOf(f);C>-1&&(i.splice(C,1),c+=f+".")}),c+=r,i.length!=0||r.length===0)return null;let m={};return m.domEventName=o,m.fullKey=c,m}static matchEventFullKeyCode(t,i){let o=xI[t.key]||t.key,r="";return i.indexOf("code.")>-1&&(o=t.code,r="code."),o==null||!o?!1:(o=o.toLowerCase(),o===" "?o="space":o==="."&&(o="dot"),yy.forEach(c=>{if(c!==o){let u=SI[c];u(t)&&(r+=c+".")}}),r+=o,r===i)}static eventCallback(t,i,o){return r=>{e.matchEventFullKeyCode(r,t)&&o.runGuarded(()=>i(r))}}static _normalizeKey(t){return t==="esc"?"escape":t}static \u0275fac=function(i){return new(i||e)(re($e))};static \u0275prov=O({token:e,factory:e.\u0275fac})}return e})();function Zf(e,n,t){return jv(U({rootComponent:e,platformRef:t?.platformRef},wI(n)))}function wI(e){return{appProviders:[...II,...e?.providers??[]],platformProviders:DI}}function EI(){mc.makeCurrent()}function MI(){return new kn}function PI(){return o_(document),document}var DI=[{provide:Zt,useValue:sc},{provide:tf,useValue:EI,multi:!0},{provide:$e,useFactory:PI}];var II=[{provide:Pl,useValue:"root"},{provide:kn,useFactory:MI},{provide:uc,useClass:by,multi:!0,deps:[$e]},{provide:uc,useClass:xy,multi:!0,deps:[$e]},Yf,Jf,qf,{provide:Bo,useExisting:Yf},{provide:uo,useClass:bI},[]];var nr=class{},ir=class{},Mn=class e{headers;normalizedNames=new Map;lazyInit;lazyUpdate=null;constructor(n){n?typeof n=="string"?this.lazyInit=()=>{this.headers=new Map,n.split(`
8`).forEach(t=>{let i=t.indexOf(":");if(i>0){let o=t.slice(0,i),r=t.slice(i+1).trim();this.addHeaderEntry(o,r)}})}:typeof Headers<"u"&&n instanceof Headers?(this.headers=new Map,n.forEac
vendor: 9,073 bytes, line 8
8h((t,i)=>{this.addHeaderEntry(i,t)})):this.lazyInit=()=>{this.headers=new Map,Object.entries(n).forEach(([t,i])=>{this.setHeaderEntries(t,i)})}:this.headers=new Map}has(n){return this.init(),this.headers.has(n.toLowerCase())}get(n){this.init();let t=this.headers.get(n.toLowerCase());return t&&t.length>0?t[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(n){return this.init(),this.headers.get(n.toLowerCase())||null}append(n,t){return this.clone({name:n,value:t,op:"a"})}set(n,t){return this.clone({name:n,value:t,op:"s"})}delete(n,t){return this.clone({name:n,value:t,op:"d"})}maybeSetNormalizedName(n,t){this.normalizedNames.has(t)||this.normalizedNames.set(t,n)}init(){this.lazyInit&&(this.lazyInit instanceof e?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(n=>this.applyUpdate(n)),this.lazyUpdate=null))}copyFrom(n){n.init(),Array.from(n.headers.keys()).forEach(t=>{this.headers.set(t,n.headers.get(t)),this.normalizedNames.set(t,n.normalizedNames.get(t))})}clone(n){let t=new e;return t.lazyInit=this.lazyInit&&this.lazyInit instanceof e?this.lazyInit:this,t.lazyUpdate=(this.lazyUpdate||[]).concat([n]),t}applyUpdate(n){let t=n.name.toLowerCase();switch(n.op){case"a":case"s":let i=n.value;if(typeof i=="string"&&(i=[i]),i.length===0)return;this.maybeSetNormalizedName(n.name,t);let o=(n.op==="a"?this.headers.get(t):void 0)||[];o.push(...i),this.headers.set(t,o);break;case"d":let r=n.value;if(!r)this.headers.delete(t),this.normalizedNames.delete(t);else{let c=this.headers.get(t);if(!c)return;c=c.filter(u=>r.indexOf(u)===-1),c.length===0?(this.headers.delete(t),this.normalizedNames.delete(t)):this.headers.set(t,c)}break}}addHeaderEntry(n,t){let i=n.toLowerCase();this.maybeSetNormalizedName(n,i),this.headers.has(i)?this.headers.get(i).push(t):this.headers.set(i,[t])}setHeaderEntries(n,t){let i=(Array.isArray(t)?t:[t]).map(r=>r.toString()),o=n.toLowerCase();this.headers.set(o,i),this.maybeSetNormalizedName(n,o)}forEach(n){this.init(),Array.from(this.normalizedNames.keys()).forEach(t=>n(this.normalizedNames.get(t),this.headers.get(t)))}};var hc=class{encodeKey(n){return Sy(n)}encodeValue(n){return Sy(n)}decodeKey(n){return decodeURIComponent(n)}decodeValue(n){return decodeURIComponent(n)}};function TI(e,n){let t=new Map;return e.length>0&&e.replace(/^\?/,"").split("&").forEach(o=>{let r=o.indexOf("="),[c,u]=r==-1?[n.decodeKey(o),""]:[n.decodeKey(o.slice(0,r)),n.decodeValue(o.slice(r+1))],m=t.get(c)||[];m.push(u),t.set(c,m)}),t}var OI=/%(\d[a-f0-9])/gi,NI={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function Sy(e){return encodeURIComponent(e).replace(OI,(n,t)=>NI[t]??n)}function pc(e){return`${e}`}var ci=class e{map;encoder;updates=null;cloneFrom=null;constructor(n={}){if(this.encoder=n.encoder||new hc,n.fromString){if(n.fromObject)throw new J(2805,!1);this.map=TI(n.fromString,this.encoder)}else n.fromObject?(this.map=new Map,Object.keys(n.fromObject).forEach(t=>{let i=n.fromObject[t],o=Array.isArray(i)?i.map(pc):[pc(i)];this.map.set(t,o)})):this.map=null}has(n){return this.init(),this.map.has(n)}get(n){this.init();let t=this.map.get(n);return t?t[0]:null}getAll(n){return this.init(),this.map.get(n)||null}keys(){return this.init(),Array.from(this.map.keys())}append(n,t){return this.clone({param:n,value:t,op:"a"})}appendAll(n){let t=[];return Object.keys(n).forEach(i=>{let o=n[i];Array.isArray(o)?o.forEach(r=>{t.push({param:i,value:r,op:"a"})}):t.push({param:i,value:o,op:"a"})}),this.clone(t)}set(n,t){return this.clone({param:n,value:t,op:"s"})}delete(n,t){return this.clone({param:n,value:t,op:"d"})}toString(){return this.init(),this.keys().map(n=>{let t=this.encoder.encodeKey(n);return this.map.get(n).map(i=>t+"="+this.encoder.encodeValue(i)).join("&")}).filter(n=>n!=="").join("&")}clone(n){let t=new e({encoder:this.encoder});return t.cloneFrom=this.cloneFrom||this,t.updates=(this.updates||[]).concat(n),t}init(){this.map===null&&(this.map=new Map),this.cloneFrom!==null&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(n=>this.map.set(n,this.cloneFrom.map.get(n))),this.updates.forEach(n=>{switch(n.op){case"a":case"s":let t=(n.op==="a"?this.map.get(n.param):void 0)||[];t.push(pc(n.value)),this.map.set(n.param,t);break;case"d":if(n.value!==void 0){let i=this.map.get(n.param)||[],o=i.indexOf(pc(n.value));o!==-1&&i.splice(o,1),i.length>0?this.map.set(n.param,i):this.map.delete(n.param)}else{this.map.delete(n.param);break}}}),this.cloneFrom=this.updates=null)}};var gc=class{map=new Map;set(n,t){return this.map.set(n,t),this}get(n){return this.map.has(n)||this.map.set(n,n.defaultValue()),this.map.get(n)}delete(n){return this.map.delete(n),this}has(n){return this.map.has(n)}keys(){return this.map.keys()}};function kI(e){switch(e){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}function wy(e){return typeof ArrayBuffer<"u"&&e instanceof ArrayBuffer}function Ey(e){return typeof Blob<"u"&&e instanceof Blob}function My(e){return typeof FormData<"u"&&e instanceof FormData}function AI(e){return typeof URLSearchParams<"u"&&e instanceof URLSearchParams}var va="Content-Type",Cc="Accept",nh="X-Request-URL",Dy="text/plain",Iy="application/json",Ty=`${Iy}, ${Dy}, */*`,tr=class e{url;body=null;headers;context;reportProgress=!1;withCredentials=!1;responseType="json";method;params;urlWithParams;transferCache;constructor(n,t,i,o){this.url=t,this.method=n.toUpperCase();let r;if(kI(this.method)||o?(this.body=i!==void 0?i:null,r=o):r=i,r&&(this.reportProgress=!!r.reportProgress,this.withCredentials=!!r.withCredentials,r.responseType&&(this.responseType=r.responseType),r.headers&&(this.headers=r.headers),r.context&&(this.context=r.context),r.params&&(this.params=r.params),this.transferCache=r.transferCache),this.headers??=new Mn,this.context??=new gc,!this.params)this.params=new ci,this.urlWithParams=t;else{let c=this.params.toString();if(c.length===0)this.urlWithParams=t;else{let u=t.indexOf("?"),m=u===-1?"?":u<t.length-1?"&":"";this.urlWithParams=t+m+c}}}serializeBody(){return this.body===null?null:typeof this.body=="string"||wy(this.body)||Ey(this.body)||My(this.body)||AI(this.body)?this.body:this.body instanceof ci?this.body.toString():typeof this.body=="object"||typeof this.body=="boolean"||Array.isArray(this.body)?JSON.stringify(this.body):this.body.toString()}detectContentTypeHeader(){return this.body===null||My(this.body)?null:Ey(this.body)?this.body.type||null:wy(this.body)?null:typeof this.body=="string"?Dy:this.body instanceof ci?"application/x-www-form-urlencoded;charset=UTF-8":typeof this.body=="object"||typeof this.body=="number"||typeof this.body=="boolean"?Iy:null}clone(n={}){let t=n.method||this.method,i=n.url||this.url,o=n.responseType||this.responseType,r=n.transferCache??this.transferCache,c=n.body!==void 0?n.body:this.body,u=n.withCredentials??this.withCredentials,m=n.reportProgress??this.reportProgress,f=n.headers||this.headers,C=n.params||this.params,b=n.context??this.context;return n.setHeaders!==void 0&&(f=Object.keys(n.setHeaders).reduce((P,x)=>P.set(x,n.setHeaders[x]),f)),n.setParams&&(C=Object.keys(n.setParams).reduce((P,x)=>P.set(x,n.setParams[x]),C)),new e(t,i,c,{params:C,headers:f,context:b,reportProgress:m,responseType:o,withCredentials:u,transferCache:r})}},di=(function(e){return e[e.Sent=0]="Sent",e[e.UploadProgress=1]="UploadProgress",e[e.ResponseHeader=2]="ResponseHeader",e[e.DownloadProgress=3]="DownloadProgress",e[e.Response=4]="Response",e[e.User=5]="User",e})(di||{}),or=class{headers;status;statusText;url;ok;type;constructor(n,t=200,i="OK"){this.headers=n.headers||new Mn,this.status=n.status!==void 0?n.status:t,this.statusText=n.statusText||i,this.url=n.url||null,this.ok=this.status>=200&&this.status<300}},ya=class e extends or{constructor(n={}){super(n)}type=di.ResponseHeader;clone(n={}){return new e({headers:n.headers||this.headers,status:n.status!==void 0?n.status:this.status,statusText:n.statusText||this.statusText,url:n.url||this.url||void 0})}},Oi=class e extends or{body;constructor(n={}){super(n),this.body=n.body!==void 0?n.body:null}type=di.Response;clone(n={}){return new e({body:n.body!==void 0?n.body:this.body,headers:n.headers||this.headers,status:n.status!==void 0?n.status:this.status,statusText:n.statusText||this.statusText,url:n.url||this.url||void 0})}},en=class extends or{name="HttpErrorResponse";message;error;ok=!1;constructor(n){super(n,0,"Unknown Error"),this.status>=200&&this.status<300?this.message=`Http failure during parsing for ${n.url||"(unknown url)"}`:this.message=`Http failure response for ${n.url||"(unknown url)"}: ${n.status} ${n.statusText}`,this.error=n.error||null}},Oy=200,RI=204;function Qf(e,n){return{body:n,headers:e.headers,context:e.context,observe:e.observe,params:e.params,reportProgress:e.reportProgress,responseType:e.responseType,withCredentials:e.withCredentials,transferCache:e.transferCache}}var Z=(()=>{class e{handler;constructor(t){this.handler=t}request(t,i,o={}){let r;if(t instanceof tr)r=t;else{let m;
8o.headers instanceof Mn?m=o.headers:m=new Mn(o.headers);let f;o.params&&(o.params instanceof ci?f=o.params:f=new ci({fromObject:o.params})),r=new tr(t,i,o.body!==void 0?o.body:null,{headers:m,context:o.context,params:f,reportProgress:o.reportProgress,responseType:o.responseType||"json",withCredentials:o.withCredentials,transferCache:o.transferCache})}let c=Q(r).pipe(_i(m=>this.handler.handle(m)));if(t instanceof tr||o.observe==="events")return c;let u=c.pipe(Gt(m=>m instanceof Oi));switch(o.observe||"body"){case"body":switch(r.responseType){case"arraybuffer":return u.pipe(N(m=>{if(m.body!==null&&!(m.body instanceof ArrayBuffer))throw new J(2806,!1);return m.body}));case"blob":return u.pipe(N(m=>{if(m.body!==null&&!(m.body instanceof Blob))throw new J(2807,!1);return m.body}));case"text":return u.pipe(N(m=>{if(m.body!==null&&typeof m.body!="string")throw new J(2808,!1);return m.body}));default:return u.pipe(N(m=>m.body))}case"response":return u;default:throw new J(2809,!1)}}delete(t,i={}){return this.request("DELETE",t,i)}get(t,i={}){return this.request("GET",t,i)}head(t,i={}){return this.request("HEAD",t,i)}jsonp(t,i){return this.request("JSONP",t,{params:new ci().append(i,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(t,i={}){return this.request("OPTIONS",t,i)}patch(t,i,o={}){return this.request("PATCH",t,Qf(o,i))}post(t,i,o={}){return this.request("POST",t,Qf(o,i))}put(t,i,o={}){return this.request("PUT",t,Qf(o,i))}static \u0275fac=function(i){return new(i||e)(re(nr))};static \u0275prov=O({token:e,factory:e.\u0275fac})}return e})(),FI=/^\)\]\}',?\n/;function Py(e){if(e.url)return e.url;let n=nh.toLocaleLowerCase();return e.headers.get(n)}var Ny=new K(""),fc=(()=>{class e{fetchImpl=h(Xf,{optional:!0})?.fetch??((...t)=>globalThis.fetch(...t));ngZone=h(Ke);destroyRef=h(io);destroyed=!1;constructor(){this.destroyRef.onDestroy(()=>{this.destroyed=!0})}handle(t){return new ye(i=>{let o=new AbortController;return this.doRequest(t,o.signal,i).then(eh,r=>i.error(new en({error:r}))),()=>o.abort()})}doRequest(t,i,o){return wt(this,null,function*(){let r=this.createRequestInit(t),c;try{let x=this.ngZone.runOutsideAngular(()=>this.fetchImpl(t.urlWithParams,U({signal:i},r)));LI(x),o.next({type:di.Sent}),c=yield x}catch(x){o.error(new en({error:x,status:x.status??0,statusText:x.statusText,url:t.urlWithParams,headers:x.headers}));return}let u=new Mn(c.headers),m=c.statusText,f=Py(c)??t.urlWithParams,C=c.status,b=null;if(t.reportProgress&&o.next(new ya({headers:u,status:C,statusText:m,url:f})),c.body){let x=c.headers.get("content-length"),D=[],V=c.body.getReader(),q=0,te,Ie,Pe=typeof Zone<"u"&&Zone.current,on=!1;if(yield this.ngZone.runOutsideAngular(()=>wt(this,null,function*(){for(;;){if(this.destroyed){yield V.cancel(),on=!0;break}let{done:pn,value:xu}=yield V.read();if(pn)break;if(D.push(xu),q+=xu.length,t.reportProgress){Ie=t.responseType==="text"?(Ie??"")+(te??=new TextDecoder).decode(xu,{stream:!0}):void 0;let qh=()=>o.next({type:di.DownloadProgress,total:x?+x:void 0,loaded:q,partialText:Ie});Pe?Pe.run(qh):qh()}}})),on){o.complete();return}let vo=this.concatChunks(D,q);try{let pn=c.headers.get(va)??"";b=this.parseBody(t,vo,pn)}catch(pn){o.error(new en({error:pn,headers:new Mn(c.headers),status:c.status,statusText:c.statusText,url:Py(c)??t.urlWithParams}));return}}C===0&&(C=b?Oy:0),C>=200&&C<300?(o.next(new Oi({body:b,headers:u,status:C,statusText:m,url:f})),o.complete()):o.error(new en({error:b,headers:u,status:C,statusText:m,url:f}))})}parseBody(t,i,o){switch(t.responseType){case"json":let r=new TextDecoder().decode(i).replace(FI,"");return r===""?null:JSON.parse(r);case"text":return new TextDecoder().decode(i);case"blob":return new Blob([i],{type:o});case"arraybuffer":return i.buffer}}createRequestInit(t){let i={},o=t.withCredentials?"include":void 0;if(t.headers.forEach((r,c)=>i[r]=c.join(",")),t.headers.has(Cc)||(i[Cc]=Ty),!t.headers.has(va)){let r=t.detectContentTypeHeader();r!==null&&(i[va]=r)}return{body:t.serializeBody(),method:t.method,headers:i,credentials:o}}concatChunks(t,i){let o=new Uint8Array(i),r=0;for(let c of t)o.set(c,r),r+=c.length;return o}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac})}return e})(),Xf=class{};function eh(){}function LI(e){e.then(eh,eh)}function VI(e,n){return n(e)}function UI(e,n,t){return(i,o)=>Kt(t,()=>n(i,r=>e(r,o)))}var ih=new K(""),oh=new K(""),ky=new K("",{providedIn:"root",factory:()=>!0});var _c=(()=>{class e extends nr{backend;injector;chain=null;pendingTasks=h(Ln);contributeToStability=h(ky);constructor(t,i){super(),this.backend=t,this.injector=i}handle(t){if(this.chain===null){let i=Array.from(new Set([...this.injector.get(ih),...this.injector.get(oh,[])])
8);this.chain=i.reduceRight((o,r)=>UI(o,r,this.injector),VI)}if(this.contributeToStability){let i=this.pendingTasks.add();return this.chain(t,o=>this.backend.handle(o)).pipe(ji(()=>this.pendingTasks.remove(i)))}else return this.chain(t,i=>this.backend.handle(i))}static \u0275fac=function(i){return new(i||e)(re(ir),re(yt))};static \u0275prov=O({token:e,factory:e.\u0275fac})}return e})();var jI=/^\)\]\}',?\n/,BI=RegExp(`^${nh}:`,"m");function HI(e){return"responseURL"in e&&e.responseURL?e.responseURL:BI.test(e.getAllResponseHeaders())?e.getResponseHeader(nh):null}var th=(()=>{class e{xhrFactory;constructor(t){this.xhrFactory=t}handle(t){if(t.method==="JSONP")throw new J(-2800,!1);let i=this.xhrFactory;return(i.\u0275loadImpl?ze(i.\u0275loadImpl()):Q(null)).pipe(be(()=>new ye(r=>{let c=i.build();if(c.open(t.method,t.urlWithParams),t.withCredentials&&(c.withCredentials=!0),t.headers.forEach((V,q)=>c.setRequestHeader(V,q.join(","))),t.headers.has(Cc)||c.setRequestHeader(Cc,Ty),!t.headers.has(va)){let V=t.detectContentTypeHeader();V!==null&&c.setRequestHeader(va,V)}if(t.responseType){let V=t.responseType.toLowerCase();c.responseType=V!=="json"?V:"text"}let u=t.serializeBody(),m=null,f=()=>{if(m!==null)return m;let V=c.statusText||"OK",q=new Mn(c.getAllResponseHeaders()),te=HI(c)||t.url;return m=new ya({headers:q,status:c.status,statusText:V,url:te}),m},C=()=>{let{headers:V,status:q,statusText:te,url:Ie}=f(),Pe=null;q!==RI&&(Pe=typeof c.response>"u"?c.responseText:c.response),q===0&&(q=Pe?Oy:0);let on=q>=200&&q<300;if(t.responseType==="json"&&typeof Pe=="string"){let vo=Pe;Pe=Pe.replace(jI,"");try{Pe=Pe!==""?JSON.parse(Pe):null}catch(pn){Pe=vo,on&&(on=!1,Pe={error:pn,text:Pe})}}on?(r.next(new Oi({body:Pe,headers:V,status:q,statusText:te,url:Ie||void 0})),r.complete()):r.error(new en({error:Pe,headers:V,status:q,statusText:te,url:Ie||void 0}))},b=V=>{let{url:q}=f(),te=new en({error:V,status:c.status||0,statusText:c.statusText||"Unknown Error",url:q||void 0});r.error(te)},P=!1,x=V=>{P||(r.next(f()),P=!0);let q={type:di.DownloadProgress,loaded:V.loaded};V.lengthComputable&&(q.total=V.total),t.responseType==="text"&&c.responseText&&(q.partialText=c.responseText),r.next(q)},D=V=>{let q={type:di.UploadProgress,loaded:V.loaded};V.lengthComputable&&(q.total=V.total),r.next(q)};return c.addEventListener("load",C),c.addEventListener("error",b),c.addEventListener("timeout",b),c.addEventListener("abort",b),t.reportProgress&&(c.addEventListener("progress",x),u!==null&&c.upload&&c.upload.addEventListener("progress",D)),c.send(u),r.next({type:di.Sent}),()=>{c.removeEventListener("error",b),c.removeEventListener("abort",b),c.removeEventListener("load",C),c.removeEventListener("timeout",b),t.reportProgress&&(c.removeEventListener("progress",x),u!==null&&c.upload&&c.upload.removeEventListener("progress",D)),c.readyState!==c.DONE&&c.abort()}})))}static \u0275fac=function(i){return new(i||e)(re(uo))};static \u0275prov=O({token:e,factory:e.\u0275fac})}return e})(),Ay=new K(""),$I="XSRF-TOKEN",zI=new K("",{providedIn:"root",factory:()=>$I}),GI="X-XSRF-TOKEN",WI=new K("",{providedIn:"root",factory:()=>GI}),ba=class{},qI=(()=>{class e{doc;cookieName;lastCookieString="";lastToken=null;parseCount=0;constructor(t,i){this.doc=t,this.cookieName=i}getToken(){let t=this.doc.cookie||"";return t!==this.lastCookieString&&(this.parseCount++,this.lastToken=fa(t,this.cookieName),this.lastCookieString=t),this.lastToken}static \u0275fac=function(i){return new(i||e)(re($e),re(zI))};static \u0275prov=O({token:e,factory:e.\u0275fac})}return e})(),JI=/^(?:https?:)?\/\//i;function KI(e,n){if(!h(Ay)||e.method==="GET"||e.method==="HEAD"||JI.test(e.url))return n(e);let t=h(ba).getToken(),i=h(WI);return t!=null&&!e.headers.has(i)&&(e=e.clone({headers:e.headers.set(i,t)})),n(e)}var vc=(function(e){return e[e.Interceptors=0]="Interceptors",e[e.LegacyInterceptors=1]="LegacyInterceptors",e[e.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",e[e.NoXsrfProtection=3]="NoXsrfProtection",e[e.JsonpSupport=4]="JsonpSupport",e[e.RequestsMadeViaParent=5]="RequestsMadeViaParent",e[e.Fetch=6]="Fetch",e})(vc||{});function Ry(e,n){return{\u0275kind:e,\u0275providers:n}}function rh(...e){let n=[Z,th,_c,{provide:nr,useExisting:_c},{provide:ir,useFactory:()=>h(Ny,{optional:!0})??h(th)},{provide:ih,useValue:KI,multi:!0},{provide:Ay,useValue:!0},{provide:ba,useClass:qI}];for(let t of e)n.push(...t.\u0275providers);return Mi(n)}function ah(e){return Ry(vc.Interceptors,e.map(n=>({provide:ih,useValue:n,multi:!0})))}function sh(){return Ry(vc.Fetch,[fc,{provide:Ny,useExisting:fc},{provide:ir,useExisting:fc}])}var YI=new K(""),ZI="b",QI="h",XI="s",eT="st",tT="u",nT="rt",lh=new K(""),iT=["GET","HEAD"];function oT(e,n){let P=h(lh),{isCacheActive:t}=P,i=is(P,["isCacheActive"]),{transferCache:o,method:r}=e;if(!t||o===!1||e.withCredentials||r==="POST"&&!i.includePostRequests&&!o||r!=="POST"&&!iT.includes(r)||!i.includeRequestsWithAuthHeaders&&rT(e)||i.filter?.(e)===!1)return n(e);let c=h(Jo);if(h(YI,{optional:!0}))throw new J(2803,!1);let m=e.url,f=aT(e,m),C=c.get(f,null),b=i.includeHeaders;if(typeof o=="object"&&o.includeHeaders&&(b=o.includeHeaders),C){let{[ZI]:x,[nT]:D,[QI]:V,[XI]:q,[eT]:te,[tT]:Ie}=C,Pe=x;switch(D){case"arraybuffer":Pe=new TextEncoder().encode(x).buffer;break;case"blob":Pe=new Blob([x]);break}let on=new Mn(V);return Q(new Oi({body:Pe,headers:on,status:q,statusText:te,url:Ie}))}return n(e).pipe(xe(x=>{x instanceof Oi}
8))}function rT(e){return e.headers.has("authorization")||e.headers.has("proxy-authorization")||e.headers.has("cookie")}function Fy(e){return[...e.keys()].sort().map(n=>`${n}=${e.getAll(n)}`).join("&")}function aT(e,n){let{params:t,method:i,responseType:o}=e,r=Fy(t),c=e.serializeBody();c instanceof URLSearchParams?c=Fy(c):typeof c!="string"&&(c="");let u=[i,o,n,c,r].join("|"),m=sT(u);return m}function sT(e){let n=0;for(let t of e)n=Math.imul(31,n)+t.charCodeAt(0)<<0;return n+=2147483648,n.toString()}function Ly(e){return[{provide:lh,useFactory:()=>(Vn("NgHttpTransferCache"),U({isCacheActive:!0},e))},{provide:oh,useValue:oT,multi:!0},{provide:ao,multi:!0,useFactory:()=>{let n=h(Rt),t=h(lh);return()=>{n.whenStable().then(()=>{t.isCacheActive=!1})}}}]}var Ni=(()=>{class e{_doc;_dom;constructor(t){this._doc=t,this._dom=Xt()}addTag(t,i=!1){return t?this._getOrCreateElement(t,i):null}addTags(t,i=!1){return t?t.reduce((o,r)=>(r&&o.push(this._getOrCreateElement(r,i)),o),[]):[]}getTag(t){if(!t)return null;let i=this._doc.querySelector(`meta[${t}]`);return i?.nodeName.toLowerCase()==="meta"?i:null}getTags(t){if(!t)return[];let i=this._doc.querySelectorAll(`meta[${t}]`);return i?[].slice.call(i).filter(o=>o.nodeName.toLowerCase()==="meta"):[]}updateTag(t,i){if(!t)return null;i=i||this._parseSelector(t);let o=this.getTag(i);return o?this._setMetaElementAttributes(t,o):this._getOrCreateElement(t,!0)}removeTag(t){this.removeTagElement(this.getTag(t))}removeTagElement(t){t&&this._dom.remove(t)}_getOrCreateElement(t,i=!1){if(!i){let c=this._parseSelector(t),u=this.getTags(c).filter(m=>this._containsAttributes(t,m))[0];if(u!==void 0)return u}let o=this._dom.createElement("meta");return this._setMetaElementAttributes(t,o),this._doc.getElementsByTagName("head")[0].appendChild(o),o}_setMetaElementAttributes(t,i){return Object.keys(t).forEach(o=>i.setAttribute(this._getMetaKeyMap(o),t[o])),i}_parseSelector(t){let i=t.name?"name":"property";return`${i}=${this._escapeSelectorValue(String(t[i]))}`}_escapeSelectorValue(t){return`"${t.replace(/\\/g,"\\\\").replace(/"/g,'\\"')}"`}_containsAttributes(t,i){return Object.keys(t).every(o=>i.getAttribute(this._getMetaKeyMap(o))===t[o])}_getMetaKeyMap(t){return cT[t]||t}static \u0275fac=function(i){return new(i||e)(re($e))};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),cT={httpEquiv:"http-equiv"},H=(()=>{class e{_doc;constructor(t){this._doc=t}getTitle(){return this._doc.title}setTitle(t){this._doc.title=t||""}static \u0275fac=function(i){return new(i||e)(re($e))};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();var yc=(function(e){return e[e.NoHttpTransferCache=0]="NoHttpTransferCache",e[e.HttpTransferCacheOptions=1]="HttpTransferCacheOptions",e[e.I18nSupport=2]="I18nSupport",e[e.EventReplay=3]="EventReplay",e[e.IncrementalHydration=4]="IncrementalHydration",e})(yc||{});function dT(e,n=[],t={}){return{\u0275kind:e,\u0275providers:n}}function Vy(){return dT(yc.EventReplay,Bv())}function Uy(...e){let n=[],t=new Set;for(let{\u0275providers:o,\u0275kind:r}of e)t.add(r),o.length&&n.push(o);let i=t.has(yc.HttpTransferCacheOptions);return Mi([[],Hv(),t.has(yc.NoHttpTransferCache)||i?[]:Ly({}),n])}var ce="primary",Ra=Symbol("RouteTitle"),ph=class{params;constructor(n){this.params=n||{}}has(n){return Object.prototype.hasOwnProperty.call(this.params,n)}get(n){if(this.has(n)){let t=this.params[n];return Array.isArray(t)?t[0]:t}return null}getAll(n){if(this.has(n)){let t=this.params[n];return Array.isArray(t)?t:[t]}return[]}get keys(){return Object.keys(this.params)}};function fo(e){return new ph(e)}function qy(e,n,t){let i=t.path.split("/");if(i.length>e.length||t.pathMatch==="full"&&(n.hasChildren()||i.length<e.length))return null;let o={};for(let r=0;r<i.length;r++){let c=i[r],u=e[r];if(c[0]===":")o[c.substring(1)]=u;else if(c!==u.path)return null}return{consumed:e.slice(0,i.length),posParams:o}}function mT(e,n){if(e.length!==n.length)return!1;for(let t=0;t<e.length;++t)if(!jn(e[t],n[t]))return!1;return!0}function jn(e,n){let t=e?fh(e):void 0,i=n?fh(n):void 0;if(!t||!i||t.length!=i.length)return!1;let o;for(let r=0;r<t.length;r++)if(o=t[r],!Jy(e[o],n[o]))return!1;return!0}function fh(e){return[...Object.keys(e),...Object.getOwnPropertySymbols(e)]}function Jy(e,n){if(Array.isArray(e)&&Array.isArray(n)){if(e.length!==n.length)return!1;let t=[...e].sort(),i=[...n].sort();return t.every((o,r)=>
vendor: 34,409 bytes, line 8
8i[r]===o)}else return e===n}function Ky(e){return e.length>0?e[e.length-1]:null}function Ai(e){return Zu(e)?e:ro(e)?ze(Promise.resolve(e)):Q(e)}var pT={exact:Zy,subset:Qy},Yy={exact:fT,subset:hT,ignored:()=>!0};function jy(e,n,t){return pT[t.paths](e.root,n.root,t.matrixParams)&&Yy[t.queryParams](e.queryParams,n.queryParams)&&!(t.fragment==="exact"&&e.fragment!==n.fragment)}function fT(e,n){return jn(e,n)}function Zy(e,n,t){if(!mo(e.segments,n.segments)||!Sc(e.segments,n.segments,t)||e.numberOfChildren!==n.numberOfChildren)return!1;for(let i in n.children)if(!e.children[i]||!Zy(e.children[i],n.children[i],t))return!1;return!0}function hT(e,n){return Object.keys(n).length<=Object.keys(e).length&&Object.keys(n).every(t=>Jy(e[t],n[t]))}function Qy(e,n,t){return Xy(e,n,n.segments,t)}function Xy(e,n,t,i){if(e.segments.length>t.length){let o=e.segments.slice(0,t.length);return!(!mo(o,t)||n.hasChildren()||!Sc(o,t,i))}else if(e.segments.length===t.length){if(!mo(e.segments,t)||!Sc(e.segments,t,i))return!1;for(let o in n.children)if(!e.children[o]||!Qy(e.children[o],n.children[o],i))return!1;return!0}else{let o=t.slice(0,e.segments.length),r=t.slice(e.segments.length);return!mo(e.segments,o)||!Sc(e.segments,o,i)||!e.children[ce]?!1:Xy(e.children[ce],n,r,i)}}function Sc(e,n,t){return n.every((i,o)=>Yy[t](e[o].parameters,i.parameters))}var Hn=class{root;queryParams;fragment;_queryParamMap;constructor(n=new Se([],{}),t={},i=null){this.root=n,this.queryParams=t,this.fragment=i}get queryParamMap(){return this._queryParamMap??=fo(this.queryParams),this._queryParamMap}toString(){return _T.serialize(this)}},Se=class{segments;children;parent=null;constructor(n,t){this.segments=n,this.children=t,Object.values(t).forEach(i=>i.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return wc(this)}},_t=class{path;parameters;_parameterMap;constructor(n,t){this.path=n,this.parameters=t}get parameterMap(){return this._parameterMap??=fo(this.parameters),this._parameterMap}toString(){return tb(this)}};function gT(e,n){return mo(e,n)&&e.every((t,i)=>jn(t.parameters,n[i].parameters))}function mo(e,n){return e.length!==n.length?!1:e.every((t,i)=>t.path===n[i].path)}function CT(e,n){let t=[];return Object.entries(e.children).forEach(([i,o])=>{i===ce&&(t=t.concat(n(o,i)))}),Object.entries(e.children).forEach(([i,o])=>{i!==ce&&(t=t.concat(n(o,i)))}),t}var Fa=(()=>{class e{static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:()=>new ho,providedIn:"root"})}return e})(),ho=class{parse(n){let t=new gh(n);return new Hn(t.parseRootSegment(),t.parseQueryParams(),t.parseFragment())}serialize(n){let t=`/${xa(n.root,!0)}`,i=bT(n.queryParams),o=typeof n.fragment=="string"?`#${vT(n.fragment)}`:"";return`${t}${i}${o}`}},_T=new ho;function wc(e){return e.segments.map(n=>tb(n)).join("/")}function xa(e,n){if(!e.hasChildren())return wc(e);if(n){let t=e.children[ce]?xa(e.children[ce],!1):"",i=[];return Object.entries(e.children).forEach(([o,r])=>{o!==ce&&i.push(`${o}:${xa(r,!1)}`)}),i.length>0?`${t}(${i.join("//")})`:t}else{let t=CT(e,(i,o)=>o===ce?[xa(e.children[ce],!1)]:[`${o}:${xa(i,!1)}`]);return Object.keys(e.children).length===1&&e.children[ce]!=null?`${wc(e)}/${t[0]}`:`${wc(e)}/(${t.join("//")})`}}function eb(e){return encodeURIComponent(e).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function bc(e){return eb(e).replace(/%3B/gi,";")}function vT(e){return encodeURI(e)}function hh(e){return eb(e).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function Ec(e){return decodeURIComponent(e)}function By(e){return Ec(e.replace(/\+/g,"%20"))}function tb(e){return`${hh(e.path)}${yT(e.parameters)}`}function yT(e){return Object.entries(e).map(([n,t])=>`;${hh(n)}=${hh(t)}`).join("")}function bT(e){let n=Object.entries(e).map(([t,i])=>Array.isArray(i)?i.map(o=>`${bc(t)}=${bc(o)}`).join("&"):`${bc(t)}=${bc(i)}`).filter(t=>t);return n.length?`?${n.join("&")}`:""}var xT=/^[^\/()?;#]+/;function ch(e){let n=e.match(xT);return n?n[0]:""}var ST=/^[^\/()?;=#]+/;function wT(e){let n=e.match(ST);return n?n[0]:""}var ET=/^[^=?&#]+/;function MT(e){let n=e.match(ET);return n?n[0]:""}var PT=/^[^&#]+/;function DT(e){let n=e.match(PT);return n?n[0]:""}var gh=class{url;remaining;constructor(n){this.url=n,this.remaining=n}parseRootSegment(){return this.consumeOptional("/"),this.remaining===""||this.peekStartsWith("?")||this.peekStartsWith("#")?new Se([],{}):new Se([],this.parseChildren())}parseQueryParams(){let n={};if(this.consumeOptional("?"))do this.parseQueryParam(n);while(this.consumeOptional("&"));return n}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(this.remaining==="")return{};this.consumeOptional("/");let n=[];for(this.peekStartsWith("(")||n.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),n.push(this.parseSegment());let t={};this.peekStartsWith("/(")&&(this.capture("/"),t=this.parseParens(!0));let i={};return this.peekStartsWith("(")&&(i=this.parseParens(!1)),(n.length>0||Object.keys(t).length>0)&&(i[ce]=new Se(n,t)),i}parseSegment(){let n=ch(this.remaining);if(n===""&&this.peekStartsWith(";"))throw new J(4009,!1);return this.capture(n),new _t(Ec(n),this.parseMatrixParams())}parseMatrixParams(){let n={};for(;this.consumeOptional(";");)this.parseParam(n);return n}parseParam(n){let t=wT(this.remaining);if(!t)return;this.capture(t);let i="";if(this.consumeOptional("=")){let o=ch(this.remaining);o&&(i=o,this.capture(i))}n[Ec(t)]=Ec(i)}parseQueryParam(n){let t=MT(this.remaining);if(!t)return;this.capture(t);let i="";if(this.consumeOptional("=")){let c=DT(this.remaining);c&&(i=c,this.capture(i))}let o=By(t),r=By(i);if(n.hasOwnProperty(o)){let c=n[o];Array.isArray(c)||(c=[c],n[o]=c),c.push(r)}else n[o]=r}parseParens(n){let t={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){let i=ch(this.remaining),o=this.remaining[i.length];if(o!=="/"&&o!==")"&&o!==";")throw new J(4010,!1);let r;i.indexOf(":")>-1?(r=i.slice(0,i.indexOf(":")),this.capture(r),this.capture(":")):n&&(r=ce);let c=this.parseChildren();t[r]=Object.keys(c).length===1?c[ce]:new Se([],c),this.consumeOptional("//")}return t}peekStartsWith(n){return this.remaining.startsWith(n)}consumeOptional(n){return this.peekStartsWith(n)?(this.remaining=this.remaining.substring(n.length),!0):!1}capture(n){if(!this.consumeOptional(n))throw new J(4011,!1)}};function nb(e){return e.segments.length>0?new Se([],{[ce]:e}):e}function ib(e){let n={};for(let[i,o]of Object.entries(e.children)){let r=ib(o);if(i===ce&&r.segments.length===0&&r.hasChildren())for(let[c,u]of Object.entries(r.children))n[c]=u;else(r.segments.length>0||r.hasChildren())&&(n[i]=r)}let t=new Se(e.segments,n);return IT(t)}function IT(e){if(e.numberOfChildren===1&&e.children[ce]){let n=e.children[ce];return new Se(e.segments.concat(n.segments),n.children)}return e}function ki(e){return e instanceof Hn}function ob(e,n,t=null,i=null){let o=rb(e);return ab(o,n,t,i)}function rb(e){let n;function t(r){let c={};for(let m of r.children){let f=t(m);c[m.outlet]=f}let u=new Se(r.url,c);return r===e&&(n=u),u}let i=t(e.root),o=nb(i);return n??o}function ab(e,n,t,i){let o=e;for(;o.parent;)o=o.parent;if(n.length===0)return dh(o,o,o,t,i);let r=TT(n);if(r.toRoot())return dh(o,o,new Se([],{}),t,i);let c=OT(r,o,e),u=c.processChildren?wa(c.segmentGroup,c.index,r.commands):lb(c.segmentGroup,c.index,r.commands);return dh(o,c.segmentGroup,u,t,i)}function Pc(e){return typeof e=="object"&&e!=null&&!e.outlets&&!e.segmentPath}function Ma(e){return typeof e=="object"&&e!=null&&e.outlets}function dh(e,n,t,i,o){let r={};i&&Object.entries(i).forEach(([m,f])=>{r[m]=Array.isArray(f)?f.map(C=>`${C}`):`${f}`});let c;e===n?c=t:c=sb(e,n,t);let u=nb(ib(c));return new Hn(u,r,o)}function sb(e,n,t){let i={};return Object.entries(e.children).forEach(([o,r])=>{r===n?i[o]=t:i[o]=sb(r,n,t)}),new Se(e.segments,i)}var Dc=class{isAbsolute;numberOfDoubleDots;commands;constructor(n,t,i){if(this.isAbsolute=n,this.numberOfDoubleDots=t,this.commands=i,n&&i.length>0&&Pc(i[0]))throw new J(4003,!1);let o=i.find(Ma);if(o&&o!==Ky(i))throw new J(4004,!1)}toRoot(){return this.isAbsolute&&this.commands.length===1&&this.commands[0]=="/"}};function TT(e){if(typeof e[0]=="string"&&e.length===1&&e[0]==="/")return new Dc(!0,0,e);let n=0,t=!1,i=e.reduce((o,r,c)=>{if(typeof r=="object"&&r!=null){if(r.outlets){let u={};return Object.entries(r.outlets).forEach(([m,f])=>{u[m]=typeof f=="string"?f.split("/"):f}),[...o,{outlets:u}]}if(r.segmentPath)return[...o,r.segmentPath]}return typeof r!="string"?[...o,r]:c===0?(r.split("/").forEach((u,m)=>{m==0&&u==="."||(m==0&&u===""?t=!0:u===".."?n++:u!=""&&o.push(u))}),o):[...o,r]},[]);return new Dc(t,n,i)}var sr=class{segmentGroup;processChildren;index;constructor(n,t,i){this.segmentGroup=n,this.processChildren=t,this.index=i}};function OT(e,n,t){if(e.isAbsolute)return new sr(n,!0,0);if(!t)return new sr(n,!1,NaN);if(t.parent===null)return new sr(t,!0,0);let i=Pc(e.commands[0])?0:1,o=t.segments.length-1+i;return NT(t,o,e.numberOfDoubleDots)}function NT(e,n,t){let i=e,o=n,r=t;for(;r>o;){if(r-=o,i=i.parent,!i)throw new J(4005,!1);o=i.segments.length}return new sr(i,!1,o-r)}function kT(e){return Ma(e[0])?e[0].outlets:{[ce]:e}}function lb(e,n,t){if(e??=new Se([],{}),e.segments.length===0&&e.hasChildren())return wa(e,n,t);let i=AT(e,n,t),o=t.slice(i.commandIndex);if(i.match&&i.pathIndex<e.segments.length){let r=new Se(e.segments.slice(0,i.pathIndex),{});return r.children[ce]=new Se(e.segments.slice(i.pathIndex),e.children),wa(r,0,o)}else return i.match&&o.length===0?new Se(e.segments,{}):i.match&&!e.hasChildren()?Ch(e,n,t):i.match?wa(e,0,o):Ch(e,n,t)}function wa(e,n,t){if(t.length===0)return new Se(e.segments,{});{let i=kT(t),o={};if(Object.keys(i).some(r=>r!==ce)&&e.children[ce]&&e.numberOfChildren===1&&e.children[ce].segments.length===0){let r=wa(e.children[ce],n,t);return new Se(e.segments,r.children)}return Object.entries(i).forEach(([r,c])=>{typeof c=="string"&&(c=[c]),c!==null&&(o[r]=lb(e.children[r],n,c))}),Object.entries(e.children).forEach(([r,c])=>{i[r]===void 0&&(o[r]=c)}),new Se(e.segments,o)}}function AT(e,n,t){let i=0,o=n,r={match:!1,pathIndex:0,commandIndex:0};for(;o<e.segments.length;){if(i>=t.length)return r;let c=e.segments[o],u=t[i];if(Ma(u))break;let m=`${u}`,f=i<t.length-1?t[i+1]:null;if(o>0&&m===void 0)break;if(m&&f&&typeof f=="object"&&f.outlets===void 0){if(!$y(m,f,c))return r;i+=2}else{if(!$y(m,{},c))return r;i++}o++}return{match:!0,pathIndex:o,commandIndex:i}}function Ch(e,n,t){let i=e.segments.slice(0,n),o=0;for(;o<t.length;){let r=t[o];if(Ma(r)){let m=RT(r.outlets);return new Se(i,m)}if(o===0&&Pc(t[0])){let m=e.segments[n];i.push(new _t(m.path,Hy(t[0]))),o++;continue}let c=Ma(r)?r.outlets[ce]:`${r}`,u=o<t.length-1?t[o+1]:null;c&&u&&Pc(u)?(i.push(new _t(c,Hy(u))),o+=2):(i.push(new _t(c,{})),o++)}return new Se(i,{})}function RT(e){let n={};return Object.entries(e).forEach(([t,i])=>{typeof i=="string"&&(i=[i]),i!==null&&(n[t]=Ch(new Se([],{}),0,i))}),n}function Hy(e){let n={};return Object.entries(e).forEach(([t,i])=>n[t]=`${i}`),n}function $y(e,n,t){return e==t.path&&jn(n,t.parameters)}var Mc="imperative",ut=(function(e){return e[e.NavigationStart=0]="NavigationStart",e[e.NavigationEnd=1]="NavigationEnd",e[e.NavigationCancel=2]="NavigationCancel",e[e.NavigationError=3]="NavigationError",e[e.RoutesRecognized=4]="RoutesRecognized",e[e.ResolveStart=5]="ResolveStart",e[e.ResolveEnd=6]="ResolveEnd",e[e.GuardsCheckStart=7]="GuardsCheckStart",e[e.GuardsCheckEnd=8]="GuardsCheckEnd",e[e.RouteConfigLoadStart=9]="RouteConfigLoadStart",e[e.RouteConfigLoadEnd=10]="RouteConfigLoadEnd",e[e.ChildActivationStart=11]="ChildActivationStart",e[e.ChildActivationEnd=12]="ChildActivationEnd",e[e.ActivationStart=13]="ActivationStart",e[e.ActivationEnd=14]="ActivationEnd",e[e.Scroll=15]="Scroll",e[e.NavigationSkipped=16]="NavigationSkipped",e})(ut||{}),nn=class{id;url;constructor(n,t){this.id=n,this.url=t}},go=class extends nn{type=ut.NavigationStart;navigationTrigger;restoredState;constructor(n,t,i="imperative",o=null){super(n,t),this.navigationTrigger=i,this.restoredState=o}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}},$n=class extends nn{urlAfterRedirects;type=ut.NavigationEnd;constructor(n,t,i){super(n,t),this.urlAfterRedirects=i}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}},Ht=(function(e){return e[e.Redirect=0]="Redirect",e[e.SupersededByNewNavigation=1]="SupersededByNewNavigation",e[e.NoDataFromResolver=2]="NoDataFromResolver",e[e.GuardRejected=3]="GuardRejected",e})(Ht||{}),Pa=(function(e){return e[e.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",e[e.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",e})(Pa||{}),Bn=class extends nn{reason;code;type=ut.NavigationCancel;constructor(n,t,i,o){super(n,t),this.reason=i,this.code=o}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}},ui=class extends nn{reason;code;type=ut.NavigationSkipped;constructor(n,t,i,o){super(n,t),this.reason=i,this.code=o}},cr=class extends nn{error;target;type=ut.NavigationError;constructor(n,t,i,o){super(n,t),this.error=i,this.target=o}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}},Da=class extends nn{urlAfterRedirects;state;type=ut.RoutesRecognized;constructor(n,t,i,o){super(n,t),this.urlAfterRedirects=i,this.state=o}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Ic=class extends nn{urlAfterRedirects;state;type=ut.GuardsCheckStart;constructor(n,t,i,o){super(n,t),this.urlAfterRedirects=i,this.state=o}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Tc=class extends nn{urlAfterRedirects;state;shouldActivate;type=ut.GuardsCheckEnd;constructor(n,t,i,o,r){super(n,t),this.urlAfterRedirects=i,this.state=o,this.shouldActivate=r}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}},Oc=class extends nn{urlAfterRedirects;state;type=ut.ResolveStart;constructor(n,t,i,o){super(n,t),this.urlAfterRedirects=i,this.state=o}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Nc=class extends nn{urlAfterRedirects;state;type=ut.ResolveEnd;constructor(n,t,i,o){super(n,t),this.urlAfterRedirects=i,this.state=o}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},kc=class{route;type=ut.RouteConfigLoadStart;constructor(n){this.route=n}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}},Ac=class{route;type=ut.RouteConfigLoadEnd;constructor(n){this.route=n}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}},Rc=class{snapshot;type=ut.ChildActivationStart;constructor(n){this.snapshot=n}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Fc=class{snapshot;type=ut.ChildActivationEnd;constructor(n){this.snapshot=n}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Lc=class{snapshot;type=ut.ActivationStart;constructor(n){this.snapshot=n}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Vc=class{snapshot;type=ut.ActivationEnd;constructor(n){this.snapshot=n}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}};var Ia=class{},dr=class{url;navigationBehaviorOptions;constructor(n,t){this.url=n,this.navigationBehaviorOptions=t}};function FT(e,n){return e.providers&&!e._injector&&(e._injector=ra(e.providers,n,`Route: ${e.path}`)),e._injector??n}function Pn(e){return e.outlet||ce}function LT(e,n){let t=e.filter(i=>Pn(i)===n);return t.push(...e.filter(i=>Pn(i)!==n)),t}function La(e){if(!e)return null;if(e.routeConfig?._injector)return e.routeConfig._injector;for(let n=e.parent;n;n=n.parent){let t=n.routeConfig;if(t?._loadedInjector)return t._loadedInjector;if(t?._injector)return t._injector}return null}var Uc=class{rootInjector;outlet=null;route=null;children;attachRef=null;get injector(){return La(this.route?.snapshot)??this.rootInjector}constructor(n){this.rootInjector=n,this.children=new pr(this.rootInjector)}},pr=(()=>{class e{rootInjector;contexts=new Map;constructor(t){this.rootInjector=t}onChildOutletCreated(t,i){let o=this.getOrCreateContext(t);o.outlet=i,this.contexts.set(t,o)}onChildOutletDestroyed(t){let i=this.getContext(t);i&&(i.outlet=null,i.attachRef=null)}onOutletDeactivated(){let t=this.contexts;return this.contexts=new Map,t}onOutletReAttached(t){this.contexts=t}getOrCreateContext(t){let i=this.getContext(t);return i||(i=new Uc(this.rootInjector),this.contexts.set(t,i)),i}getContext(t){return this.contexts.get(t)||null}static \u0275fac=function(i){return new(i||e)(re(yt))};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),jc=class{_root;constructor(n){this._root=n}get root(){return this._root.value}parent(n){let t=this.pathFromRoot(n);return t.length>1?t[t.length-2]:null}children(n){let t=_h(n,this._root);return t?t.children.map(i=>i.value):[]}firstChild(n){let t=_h(n,this._root);return t&&t.children.length>0?t.children[0].value:null}siblings(n){let t=vh(n,this._root);return t.length<2?[]:t[t.length-2].children.map(o=>o.value).filter(o=>o!==n)}pathFromRoot(n){return vh(n,this._root).map(t=>t.value)}};function _h(e,n){if(e===n.value)return n;for(let t of n.children){let i=_h(e,t);if(i)return i}return null}function vh(e,n){if(e===n.value)return[n];for(let t of n.children){let i=vh(e,t);if(i.length)return i.unshift(n),i}return[]}var tn=class{value;children;constructor(n,t){this.value=n,this.children=t}toString(){return`TreeNode(${this.value})`}};function ar(e){let n={};return e&&e.children.forEach(t=>n[t.value.outlet]=t),n}var Ta=class extends jc{snapshot;constructor(n,t){super(n),this.snapshot=t,Ph(this,n)}toString(){return this.snapshot.toString()}};function cb(e){let n=VT(e),t=new ft([new _t("",{})]),i=new ft({}),o=new ft({}),r=new ft({}),c=new ft(""),u=new ve(t,i,r,c,o,ce,e,n.root);return u.snapshot=n.root,new Ta(new tn(u,[]),n)}function VT(e){let n={},t={},i={},r=new po([],n,i,"",t,ce,e,null,{});return new Oa("",new tn(r,[]))}var ve=class{urlSubject;paramsSubject;queryParamsSubject;fragmentSubject;dataSubject;outlet;component;snapshot;_futureSnapshot;_routerState;_paramMap;_queryParamMap;title;url;params;queryParams;fragment;data;constructor(n,t,i,o,r,c,u,m){this.urlSubject=n,this.paramsSubject=t,this.queryParamsSubject=i,this.fragmentSubject=o,this.dataSubject=r,this.outlet=c,this.component=u,this._futureSnapshot=m,this.title=this.dataSubject?.pipe(N(f=>f[Ra]))??Q(void 0),this.url=n,this.params=t,this.queryParams=i,this.fragment=o,this.data=r}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=this.params.pipe(N(n=>fo(n))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe(N(n=>fo(n))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}};function Bc(e,n,t="emptyOnly"){let i,{routeConfig:o}=e;return n!==null&&(t==="always"||o?.path===""||!n.component&&!n.routeConfig?.loadComponent)?i={params:U(U({},n.params),e.params),data:U(U({},n.data),e.data),resolve:U(U(U(U({},e.data),n.data),o?.data),e._resolvedData)}:i={params:U({},e.params),data:U({},e.data),resolve:U(U({},e.data),e._resolvedData??{})},o&&ub(o)&&(i.resolve[Ra]=o.title),i}var po=class{url;params;queryParams;fragment;data;outlet;component;routeConfig;_resolve;_resolvedData;_routerState;_paramMap;_queryParamMap;get title(){return this.data?.[Ra]}constructor(n,t,i,o,r,c,u,m,f){this.url=n,this.params=t,this.queryParams=i,this.fragment=o,this.data=r,this.outlet=c,this.component=u,this.routeConfig=m,this._resolve=f}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=fo(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=fo(this.queryParams),this._queryParamMap}toString(){let n=this.url.map(i=>i.toString()).join("/"),t=this.routeConfig?this.routeConfig.path:"";return`Route(url:'${n}', path:'${t}')`}},Oa=class extends jc{url;constructor(n,t){super(t),this.url=n,Ph(this,t)}toString(){return db(this._root)}};function Ph(e,n){n.value._routerState=e,n.children.forEach(t=>Ph(e,t))}function db(e){let n=e.children.length>0?` { ${e.children.map(db).join(", ")} } `:"";return`${e.value}${n}`}function uh(e){if(e.snapshot){let n=e.snapshot,t=e._futureSnapshot;e.snapshot=t,jn(n.queryParams,t.queryParams)||e.queryParamsSubject.next(t.queryParams),n.fragment!==t.fragment&&e.fragmentSubject.next(t.fragment),jn(n.params,t.params)||e.paramsSubject.next(t.params),mT(n.url,t.url)||e.urlSubject.next(t.url),jn(n.data,t.data)||e.dataSubject.next(t.data)}else e.snapshot=e._futureSnapshot,e.dataSubject.next(e._futureSnapshot.data)}function yh(e,n){let t=jn(e.params,n.params)&&gT(e.url,n.url),i=!e.parent!=!n.parent;return t&&!i&&(!e.parent||yh(e.parent,n.parent))}function ub(e){return typeof e.title=="string"||e.title===null}var mb=new K(""),Va=(()=>{class e{activated=null;get activatedComponentRef(){return this.activated}_activatedRoute=null;name=ce;activateEvents=new je;deactivateEvents=new je;attachEvents=new je;detachEvents=new je;routerOutletData=KC(void 0);parentContexts=h(pr);location=h(oo);changeDetector=h(Qo);inputBinder=h(Gc,{optional:!0});supportsBindingToComponentInputs=!0;ngOnChanges(t){if(t.name){let{firstChange:i,previousValue:o}=t.name;if(i)return;this.isTrackedInParentContexts(o)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(o)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(t){return this.parentContexts.getContext(t)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;let t=this.parentContexts.getContext(this.name);t?.route&&(t.attachRef?this.attach(t.attachRef,t.route):this.activateWith(t.route,t.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new J(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new J(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new J(4012,!1);this.location.detach();let t=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(t.instance),t}attach(t,i){this.activated=t,this._activatedRoute=i,this.location.insert(t.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(t.instance)}deactivate(){if(this.activated){let t=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(t)}}activateWith(t,i){if(this.isActivated)throw new J(4013,!1);this._activatedRoute=t;let o=this.location,c=t.snapshot.component,u=this.parentContexts.getOrCreateContext(this.name).children,m=new bh(t,u,o.injector,this.routerOutletData);this.activated=o.createComponent(c,{index:o.length,injector:m,environmentInjector:i}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}static \u0275fac=function(i){return new(i||e)};static \u0275dir=Le({type:e,selectors:[["router-outlet"]],inputs:{name:"name",routerOutletData:[1,"routerOutletData"]},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],features:[ct]})}return e})(),bh=class{route;childContexts;parent;outletData;constructor(n,t,i,o){this.route=n,this.childContexts=t,this.parent=i,this.outletData=o}get(n,t){return n===ve?this.route:n===pr?this.childContexts:n===mb?this.outletData:this.parent.get(n,t)}},Gc=new K("");var Dh=(()=>{class e{static \u0275fac=function(i){return new(i||e)};static \u0275cmp=k({type:e,selectors:[["ng-component"]],exportAs:["emptyRouterOutlet"],decls:1,vars:0,template:function(i,o){i&1&&j(0,"router-outlet")},dependencies:[Va],encapsulation:2})}return e})();function Ih(e){let n=e.children&&e.children.map(Ih),t=n?oe(U({},e),{children:n}):U({},e);return!t.component&&!t.loadComponent&&(n||t.loadChildren)&&t.outlet&&t.outlet!==ce&&(t.component=Dh),t}function UT(e,n,t){let i=Na(e,n._root,t?t._root:void 0);return new Ta(i,n)}function Na(e,n,t){if(t&&e.shouldReuseRoute(n.value,t.value.snapshot)){let i=t.value;i._futureSnapshot=n.value;let o=jT(e,n,t);return new tn(i,o)}else{if(e.shouldAttach(n.value)){let r=e.retrieve(n.value);if(r!==null){let c=r.route;return c.value._futureSnapshot=n.value,c.children=n.children.map(u=>Na(e,u)),c}}let i=BT(n.value),o=n.children.map(r=>Na(e,r));return new tn(i,o)}}function jT(e,n,t){return n.children.map(i=>{for(let o of t.children)if(e.shouldReuseRoute(i.value,o.value.snapshot))return Na(e,i,o);return Na(e,i)})}function BT(e){return new ve(new ft(e.url),new ft(e.params),new ft(e.queryParams),new ft(e.fragment),new ft(e.data),e.outlet,e.component,e)}var ur=class{redirectTo;navigationBehaviorOptions;constructor(n,t){this.redirectTo=n,this.navigationBehaviorOptions=t}},pb="ngNavigationCancelingError";function Hc(e,n){let{redirectTo:t,navigationBehaviorOptions:i}=ki(n)?{redirectTo:n,navigationBehaviorOptions:void 0}:n,o=fb(!1,Ht.Redirect);return o.url=t,o.navigationBehaviorOptions=i,o}function fb(e,n){let t=new Error(`NavigationCancelingError: ${e||""}`);return t[pb]=!0,t.cancellationCode=n,t}function HT(e){return hb(e)&&ki(e.url)}function hb(e){return!!e&&e[pb]}var $T=(e,n,t,i)=>N(o=>(new xh(n,o.targetRouterState,o.currentRouterState,t,i).activate(e),o)),xh=class{routeReuseStrategy;futureState;currState;forwardEvent;inputBindingEnabled;constructor(n,t,i,o,r){this.routeReuseStrategy=n,this.futureState=t,this.currState=i,this.forwardEvent=o,this.inputBindingEnabled=r}activate(n){let t=this.futureState._root,i=this.currState?this.currState._root:null;this.deactivateChildRoutes(t,i,n),uh(this.futureState.root),this.activateChildRoutes(t,i,n)}deactivateChildRoutes(n,t,i){let o=ar(t);n.children.forEach(r=>{let c=r.value.outlet;this.deactivateRoutes(r,o[c],i),delete o[c]}),Object.values(o).forEach(r=>{this.deactivateRouteAndItsChildren(r,i)})}deactivateRoutes(n,t,i){let o=n.value,r=t?t.value:null;if(o===r)if(o.component){let c=i.getContext(o.outlet);c&&this.deactivateChildRoutes(n,t,c.children)}else this.deactivateChildRoutes(n,t,i);else r&&this.deactivateRouteAndItsChildren(t,i)}deactivateRouteAndItsChildren(n,t){n.value.component&&this.routeReuseStrategy.shouldDetach(n.value.snapshot)?this.detachAndStoreRouteSubtree(n,t):this.deactivateRouteAndOutlet(n,t)}detachAndStoreRouteSubtree(n,t){let i=t.getContext(n.value.outlet),o=i&&n.value.component?i.children:t,r=ar(n);for(let c of Object.values(r))this.deactivateRouteAndItsChildren(c,o);if(i&&i.outlet){let c=i.outlet.detach(),u=i.children.onOutletDeactivated();this.routeReuseStrategy.store(n.value.snapshot,{componentRef:c,route:n,contexts:u})}}deactivateRouteAndOutlet(n,t){let i=t.getContext(n.value.outlet),o=i&&n.value.component?i.children:t,r=ar(n);for(let c of Object.values(r))this.deactivateRouteAndItsChildren(c,o);i&&(i.outlet&&(i.outlet.deactivate(),i.children.onOutletDeactivated()),i.attachRef=null,i.route=null)}activateChildRoutes(n,t,i){let o=ar(t);n.children.forEach(r=>{this.activateRoutes(r,o[r.value.outlet],i),this.forwardEvent(new Vc(r.value.snapshot))}),n.children.length&&this.forwardEvent(new Fc(n.value.snapshot))}activateRoutes(n,t,i){let o=n.value,r=t?t.value:null;if(uh(o),o===r)if(o.component){let c=i.getOrCreateContext(o.outlet);this.activateChildRoutes(n,t,c.children)}else this.activateChildRoutes(n,t,i);else if(o.component){let c=i.getOrCreateContext(o.outlet);if(this.routeReuseStrategy.shouldAttach(o.snapshot)){let u=this.routeReuseStrategy.retrieve(o.snapshot);this.routeReuseStrategy.store(o.snapshot,null),c.children.onOutletReAttached(u.contexts),c.attachRef=u.componentRef,c.route=u.route.value,c.outlet&&c.outlet.attach(u.componentRef,u.route.value),uh(u.route.value),this.activateChildRoutes(n,null,c.children)}else c.attachRef=null,c.route=o,c.outlet&&c.outlet.activateWith(o,c.injector),this.activateChildRoutes(n,null,c.children)}else this.activateChildRoutes(n,null,i)}},$c=class{path;route;constructor(n){this.path=n,this.route=this.path[this.path.length-1]}},lr=class{component;route;constructor(n,t){this.component=n,this.route=t}};function zT(e,n,t){let i=e._root,o=n?n._root:null;return Sa(i,o,t,[i.value])}function GT(e){let n=e.routeConfig?e.routeConfig.canActivateChild:null;return!n||n.length===0?null:{node:e,guards:n}}function fr(e,n){let t=Symbol(),i=n.get(e,t);return i===t?typeof e=="function"&&!G0(e)?e:n.get(e):i}function Sa(e,n,t,i,o={canDeactivateChecks:[],canActivateChecks:[]}){let r=ar(n);return e.children.forEach(c=>{WT(c,r[c.value.outlet],t,i.concat([c.value]),o),delete r[c.value.outlet]}),Object.entries(r).forEach(([c,u])=>Ea(u,t.getContext(c),o)),o}function WT(e,n,t,i,o={canDeactivateChecks:[],canActivateChecks:[]}){let r=e.value,c=n?n.value:null,u=t?t.getContext(e.value.outlet):null;if(c&&r.routeConfig===c.routeConfig){let m=qT(c,r,r.routeConfig.runGuardsAndResolvers);m?o.canActivateChecks.push(new $c(i)):(r.data=c.data,r._resolvedData=c._resolvedData),r.component?Sa(e,n,u?u.children:null,i,o):Sa(e,n,t,i,o),m&&u&&u.outlet&&u.outlet.isActivated&&o.canDeactivateChecks.push(new lr(u.outlet.component,c))}else c&&Ea(n,u,o),o.canActivateChecks.push(new $c(i)),r.component?Sa(e,null,u?u.children:null,i,o):Sa(e,null,t,i,o);return o}function qT(e,n,t){if(typeof t=="function")return t(e,n);switch(t){case"pathParamsChange":return!mo(e.url,n.url);case"pathParamsOrQueryParamsChange":return!mo(e.url,n.url)||!jn(e.queryParams,n.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!yh(e,n)||!jn(e.queryParams,n.queryParams);default:return!yh(e,n)}}function Ea(e,n,t){let i=ar(e),o=e.value;Object.entries(i).forEach(([r,c])=>{o.component?n?Ea(c,n.children.getContext(r),t):Ea(c,null,t):Ea(c,n,t)}),o.component?n&&n.outlet&&n.outlet.isActivated?t.canDeactivateChecks.push(new lr(n.outlet.component,o)):t.canDeactivateChecks.push(new lr(null,o)):t.canDeactivateChecks.push(new lr(null,o))}function Ua(e){return typeof e=="function"}function JT(e){return typeof e=="boolean"}function KT(e){return e&&Ua(e.canLoad)}function YT(e){return e&&Ua(e.canActivate)}function ZT(e){return e&&Ua(e.canActivateChild)}function QT(e){return e&&Ua(e.canDeactivate)}function XT(e){return e&&Ua(e.canMatch)}function gb(e){return e instanceof gn||e?.name==="EmptyError"}var xc=Symbol("INITIAL_VALUE");function mr(){return be(e=>Ci(e.map(n=>n.pipe(Zn(1),nm(xc)))).pipe(N(n=>{for(let t of n)if(t!==!0){if(t===xc)return xc;if(t===!1||eO(t))return t}return!0}),Gt(n=>n!==xc),Zn(1)))}function eO(e){return ki(e)||e instanceof ur}function tO(e,n){return rt(t=>{let{targetSnapshot:i,currentSnapshot:o,guards:{canActivateChecks:r,canDeactivateChecks:c}}=t;return c.length===0&&r.length===0?Q(oe(U({},t),{guardsResult:!0})):nO(c,i,o,e).pipe(rt(u=>u&&JT(u)?iO(i,r,e,n):Q(u)),N(u=>oe(U({},t),{guardsResult:u})))})}function nO(e,n,t,i){return ze(e).pipe(rt(o=>lO(o.component,o.route,t,n,i)),Qn(o=>o!==!0,!0))}function iO(e,n,t,i){return ze(n).pipe(_i(o=>Mo(rO(o.route.parent,i),oO(o.route,i),sO(e,o.path,t),aO(e,o.route,t))),Qn(o=>o!==!0,!0))}function oO(e,n){return e!==null&&n&&n(new Lc(e)),Q(!0)}function rO(e,n){return e!==null&&n&&n(new Rc(e)),Q(!0)}function aO(e,n,t){let i=n.routeConfig?n.routeConfig.canActivate:null;if(!i||i.length===0)return Q(!0);let o=i.map(r=>ks(()=>{let c=La(n)??t,u=fr(r,c),m=YT(u)?u.canActivate(n,e):Kt(c,()=>u(n,e));return Ai(m).pipe(Qn())}));return Q(o).pipe(mr())}function sO(e,n,t){let i=n[n.length-1],r=n.slice(0,n.length-1).reverse().map(c=>GT(c)).filter(c=>c!==null).map(c=>ks(()=>{let u=c.guards.map(m=>{let f=La(c.node)??t,C=fr(m,f),b=ZT(C)?C.canActivateChild(i,e):Kt(f,()=>C(i,e));return Ai(b).pipe(Qn())});return Q(u).pipe(mr())}));return Q(r).pipe(mr())}function lO(e,n,t,i,o){let r=n&&n.routeConfig?n.routeConfig.canDeactivate:null;if(!r||r.length===0)return Q(!0);let c=r.map(u=>{let m=La(n)??o,f=fr(u,m),C=QT(f)?f.canDeactivate(e,n,t,i):Kt(m,()=>f(e,n,t,i));return Ai(C).pipe(Qn())});return Q(c).pipe(mr())}function cO(e,n,t,i){let o=n.canLoad;if(o===void 0||o.length===0)return Q(!0);let r=o.map(c=>{let u=fr(c,e),m=KT(u)?u.canLoad(n,t):Kt(e,()=>u(n,t));return Ai(m)});return Q(r).pipe(mr(),Cb(i))}function Cb(e){return Wu(xe(n=>{if(typeof n!="boolean")throw Hc(e,n)}),N(n=>n===!0))}function dO(e,n,t,i){let o=n.canMatch;if(!o||o.length===0)return Q(!0);let r=o.map(c=>{let u=fr(c,e),m=XT(u)?u.canMatch(n,t):Kt(e,()=>u(n,t));return Ai(m)});return Q(r).pipe(mr(),Cb(i))}var ka=class{segmentGroup;constructor(n){this.segmentGroup=n||null}},Aa=class extends Error{urlTree;constructor(n){super(),this.urlTree=n}};function rr(e){return zt(new ka(e))}function uO(e){return zt(new J(4e3,!1))}function mO(e){return zt(fb(!1,Ht.GuardRejected))}var Sh=class{urlSerializer;urlTree;
8constructor(n,t){this.urlSerializer=n,this.urlTree=t}lineralizeSegments(n,t){let i=[],o=t.root;for(;;){if(i=i.concat(o.segments),o.numberOfChildren===0)return Q(i);if(o.numberOfChildren>1||!o.children[ce])return uO(`${n.redirectTo}`);o=o.children[ce]}}applyRedirectCommands(n,t,i,o,r){if(typeof t!="string"){let u=t,{queryParams:m,fragment:f,routeConfig:C,url:b,outlet:P,params:x,data:D,title:V}=o,q=Kt(r,()=>u({params:x,data:D,queryParams:m,fragment:f,routeConfig:C,url:b,outlet:P,title:V}));if(q instanceof Hn)throw new Aa(q);t=q}let c=this.applyRedirectCreateUrlTree(t,this.urlSerializer.parse(t),n,i);if(t[0]==="/")throw new Aa(c);return c}applyRedirectCreateUrlTree(n,t,i,o){let r=this.createSegmentGroup(n,t.root,i,o);return new Hn(r,this.createQueryParams(t.queryParams,this.urlTree.queryParams),t.fragment)}createQueryParams(n,t){let i={};return Object.entries(n).forEach(([o,r])=>{if(typeof r=="string"&&r[0]===":"){let u=r.substring(1);i[o]=t[u]}else i[o]=r}),i}createSegmentGroup(n,t,i,o){let r=this.createSegments(n,t.segments,i,o),c={};return Object.entries(t.children).forEach(([u,m])=>{c[u]=this.createSegmentGroup(n,m,i,o)}),new Se(r,c)}createSegments(n,t,i,o){return t.map(r=>r.path[0]===":"?this.findPosParam(n,r,o):this.findOrReturn(r,i))}findPosParam(n,t,i){let o=i[t.path.substring(1)];if(!o)throw new J(4001,!1);return o}findOrReturn(n,t){let i=0;for(let o of t){if(o.path===n.path)return t.splice(i),o;i++}return n}},wh={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function pO(e,n,t,i,o){let r=_b(e,n,t);return r.matched?(i=FT(n,i),dO(i,n,t,o).pipe(N(c=>c===!0?r:U({},wh)))):Q(r)}function _b(e,n,t){if(n.path==="**")return fO(t);if(n.path==="")return n.pathMatch==="full"&&(e.hasChildren()||t.length>0)?U({},wh):{matched:!0,consumedSegments:[],remainingSegments:t,parameters:{},positionalParamSegments:{}};let o=(n.matcher||qy)(t,e,n);if(!o)return U({},wh);let r={};Object.entries(o.posParams??{}).forEach(([u,m])=>{r[u]=m.path});let c=o.consumed.length>0?U(U({},r),o.consumed[o.consumed.length-1].parameters):r;return{matched:!0,consumedSegments:o.consumed,remainingSegments:t.slice(o.consumed.length),parameters:c,positionalParamSegments:o.posParams??{}}}function fO(e){return{matched:!0,parameters:e.length>0?Ky(e).parameters:{},consumedSegments:e,remainingSegments:[],positionalParamSegments:{}}}function zy(e,n,t,i){return t.length>0&&CO(e,t,i)?{segmentGroup:new Se(n,gO(i,new Se(t,e.children))),slicedSegments:[]}:t.length===0&&_O(e,t,i)?{segmentGroup:new Se(e.segments,hO(e,t,i,e.children)),slicedSegments:t}:{segmentGroup:new Se(e.segments,e.children),slicedSegments:t}}function hO(e,n,t,i){let o={};for(let r of t)if(Wc(e,n,r)&&!i[Pn(r)]){let c=new Se([],{});o[Pn(r)]=c}return U(U({},i),o)}function gO(e,n){let t={};t[ce]=n;for(let i of e)if(i.path===""&&Pn(i)!==ce){let o=new Se([],{});t[Pn(i)]=o}return t}function CO(e,n,t){return t.some(i=>Wc(e,n,i)&&Pn(i)!==ce)}function _O(e,n,t){return t.some(i=>Wc(e,n,i))}function Wc(e,n,t){return(e.hasChildren()||n.length>0)&&t.pathMatch==="full"?!1:t.path===""}function vO(e,n,t){return n.length===0&&!e.children[t]}var Eh=class{};function yO(e,n,t,i,o,r,c="emptyOnly"){return new Mh(e,n,t,i,o,c,r).recognize()}var bO=31,Mh=class{injector;configLoader;rootComponentType;config;urlTree;paramsInheritanceStrategy;urlSerializer;applyRedirects;absoluteRedirectCount=0;allowRedirects=!0;constructor(n,t,i,o,r,c,u){this.injector=n,this.configLoader=t,this.rootComponentType=i,this.config=o,this.urlTree=r,this.paramsInheritanceStrategy=c,this.urlSerializer=u,this.applyRedirects=new Sh(this.urlSerializer,this.urlTree)}noMatchError(n){return new J(4002,`'${n.segmentGroup}'`)}recognize(){let n=zy(this.urlTree.root,[],[],this.config).segmentGroup;return this.match(n).pipe(N(({children:t,rootSnapshot:i})=>{let o=new tn(i,t),r=new Oa("",o),c=ob(i,[],this.urlTree.queryParams,this.urlTree.fragment);return c.queryParams=this.urlTree.queryParams,r.url=this.urlSerializer.serialize(c),{state:r,tree:c}}))}match(n){let t=new po([],Object.freeze({}),Object.freeze(U({},this.urlTree.queryParams)),this.urlTree.fragment,Object.freeze({}),ce,this.rootComponentType,null,{});return this.processSegmentGroup(this.injector,this.config,n,ce,t).pipe(N(i=>({children:i,rootSnapshot:t})),Ze(i=>{if(i instanceof Aa)return this.urlTree=i.urlTree,this.match(i.urlTree.root);throw i instanceof ka?this.noMatchError(i):i}))}processSegmentGroup(n,t,i,o,r){return i.segments.length===0&&i.hasChildren()?this.processChildren(n,t,i,r):this.processSegment(n,t,i,i.segments,o,!0,r).pipe(N(c=>c instanceof tn?[c]:[]))}processChildren(n,t,i,o){let r=[];for(let c of Object.keys(i.children))c==="primary"?r.unshift(c):r.push(c);return ze(r).pipe(_i(c=>{let u=i.children[c],m=LT(t,c);return this.processSegmentGroup(n,m,u,c,o)}),em((c,u)=>(c.push(...u),c)),vi(null),Xu(),rt(c=>{if(c===null)return rr(i);let u=vb(c);return xO(u),Q(u)}))}processSegment(n,t,i,o,r,c,u){return ze(t).pipe(_i(m=>this.processSegmentAgainstRoute(m._injector??n,t,m,i,o,r,c,u).pipe(Ze(f=>{if(f instanceof ka)return Q(null);throw f}))),Qn(m=>!!m),Ze(m=>{if(gb(m))return vO(i,o,r)?Q(new Eh):rr(i);throw m}))}processSegmentAgainstRoute(n,t,i,o,r,c,u,m){return Pn(i)!==c&&(c===ce||!Wc(o,r,i))?rr(o):i.redirectTo===void 0?this.matchSegmentAgainstRoute(n,o,i,r,c,m):this.allowRedirects&&u?this.expandSegmentAgainstRouteUsingRedirect(n,o,t,i,r,c,m):rr(o)}expandSegmentAgainstRouteUsingRedirect(n,t,i,o,r,c,u){let{matched:m,parameters:f,consumedSegments:C,positionalParamSegments:b,remainingSegments:P}=_b(t,o,r);if(!m)return rr(t);
8typeof o.redirectTo=="string"&&o.redirectTo[0]==="/"&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>bO&&(this.allowRedirects=!1));let x=new po(r,f,Object.freeze(U({},this.urlTree.queryParams)),this.urlTree.fragment,Gy(o),Pn(o),o.component??o._loadedComponent??null,o,Wy(o)),D=Bc(x,u,this.paramsInheritanceStrategy);x.params=Object.freeze(D.params),x.data=Object.freeze(D.data);let V=this.applyRedirects.applyRedirectCommands(C,o.redirectTo,b,x,n);return this.applyRedirects.lineralizeSegments(o,V).pipe(rt(q=>this.processSegment(n,i,t,q.concat(P),c,!1,u)))}matchSegmentAgainstRoute(n,t,i,o,r,c){let u=pO(t,i,o,n,this.urlSerializer);return i.path==="**"&&(t.children={}),u.pipe(be(m=>m.matched?(n=i._injector??n,this.getChildConfig(n,i,o).pipe(be(({routes:f})=>{let C=i._loadedInjector??n,{parameters:b,consumedSegments:P,remainingSegments:x}=m,D=new po(P,b,Object.freeze(U({},this.urlTree.queryParams)),this.urlTree.fragment,Gy(i),Pn(i),i.component??i._loadedComponent??null,i,Wy(i)),V=Bc(D,c,this.paramsInheritanceStrategy);D.params=Object.freeze(V.params),D.data=Object.freeze(V.data);let{segmentGroup:q,slicedSegments:te}=zy(t,P,x,f);if(te.length===0&&q.hasChildren())return this.processChildren(C,f,q,D).pipe(N(Pe=>new tn(D,Pe)));if(f.length===0&&te.length===0)return Q(new tn(D,[]));let Ie=Pn(i)===r;return this.processSegment(C,f,q,te,Ie?ce:r,!0,D).pipe(N(Pe=>new tn(D,Pe instanceof tn?[Pe]:[])))}))):rr(t)))}getChildConfig(n,t,i){return t.children?Q({routes:t.children,injector:n}):t.loadChildren?t._loadedRoutes!==void 0?Q({routes:t._loadedRoutes,injector:t._loadedInjector}):cO(n,t,i,this.urlSerializer).pipe(rt(o=>o?this.configLoader.loadChildren(n,t).pipe(xe(r=>{t._loadedRoutes=r.routes,t._loadedInjector=r.injector})):mO(t))):Q({routes:[],injector:n})}};function xO(e){e.sort((n,t)=>n.value.outlet===ce?-1:t.value.outlet===ce?1:n.value.outlet.localeCompare(t.value.outlet))}function SO(e){let n=e.value.routeConfig;return n&&n.path===""}function vb(e){let n=[],t=new Set;for(let i of e){if(!SO(i)){n.push(i);continue}let o=n.find(r=>i.value.routeConfig===r.value.routeConfig);o!==void 0?(o.children.push(...i.children),t.add(o)):n.push(i)}for(let i of t){let o=vb(i.children);n.push(new tn(i.value,o))}return n.filter(i=>!t.has(i))}function Gy(e){return e.data||{}}function Wy(e){return e.resolve||{}}function wO(e,n,t,i,o,r){return rt(c=>yO(e,n,t,i,c.extractedUrl,o,r).pipe(N(({state:u,tree:m})=>oe(U({},c),{targetSnapshot:u,urlAfterRedirects:m}))))}function EO(e,n){return rt(t=>{let{targetSnapshot:i,guards:{canActivateChecks:o}}=t;if(!o.length)return Q(t);let r=new Set(o.map(m=>m.route)),c=new Set;for(let m of r)if(!c.has(m))for(let f of yb(m))c.add(f);let u=0;return ze(c).pipe(_i(m=>r.has(m)?MO(m,i,e,n):(m.data=Bc(m,m.parent,e).resolve,Q(void 0))),xe(()=>u++),Po(1),rt(m=>u===c.size?Q(t):Tt))})}function yb(e){let n=e.children.map(t=>yb(t)).flat();return[e,...n]}function MO(e,n,t,i){let o=e.routeConfig,r=e._resolve;return o?.title!==void 0&&!ub(o)&&(r[Ra]=o.title),PO(r,e,n,i).pipe(N(c=>(e._resolvedData=c,e.data=Bc(e,e.parent,t).resolve,null)))}function PO(e,n,t,i){let o=fh(e);if(o.length===0)return Q({});let r={};return ze(o).pipe(rt(c=>DO(e[c],n,t,i).pipe(Qn(),xe(u=>{if(u instanceof ur)throw Hc(new ho,u);r[c]=u}))),Po(1),N(()=>r),Ze(c=>gb(c)?Tt:zt(c)))}function DO(e,n,t,i){let o=La(n)??i,r=fr(e,o),c=r.resolve?r.resolve(n,t):Kt(o,()=>r(n,t));return Ai(c)}function mh(e){return be(n=>{let t=e(n);return t?ze(t).pipe(N(()=>n)):Q(n)})}var Th=(()=>{class e{buildTitle(t){let i,o=t.root;for(;o!==void 0;)i=this.getResolvedTitleForRoute(o)??i,o=o.children.find(r=>r.outlet===ce);return i}getResolvedTitleForRoute(t){return t.data[Ra]}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:()=>h(bb),providedIn:"root"})}return e})(),bb=(()=>{class e extends Th{title;constructor(t){super(),this.title=t}updateTitle(t){let i=this.buildTitle(t);i!==void 0&&this.title.setTitle(i)}static \u0275fac=function(i){return new(i||e)(re(H))};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),ja=new K("",{providedIn:"root",factory:()=>({})}),Ba=new K(""),xb=(()=>{class e{componentLoaders=new WeakMap;childrenLoaders=new WeakMap;onLoadStartListener;onLoadEndListener;compiler=h(Fv);loadComponent(t){if(this.componentLoaders.get(t))return this.componentLoaders.get(t);if(t._loadedComponent)return Q(t._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(t);let i=Ai(t.loadComponent()).pipe(N(wb),xe(r=>{this.onLoadEndListener&&this.onLoadEndListener(t),t._loadedComponent=r}),ji(()=>{this.componentLoaders.delete(t)})),o=new Eo(i,()=>new Ue).pipe(wo());return this.componentLoaders.set(t,o),o}loadChildren(t,i){if(this.childrenLoaders.get(i))return this.childrenLoaders.get(i);if(i._loadedRoutes)return Q({routes:i._loadedRoutes,injector:i._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(i);let r=Sb(i,this.compiler,t,this.onLoadEndListener).pipe(ji(()=>{this.childrenLoaders.delete(i)})),c=new Eo(r,()=>new Ue).pipe(wo());return this.childrenLoaders.set(i,c),c}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();function Sb(e,n,t,i){return Ai(e.loadChildren()).pipe(N(wb),rt(o=>o instanceof If||Array.isArray(o)?Q(o):ze(n.compileModuleAsync(o))),N(o=>{i&&i(e);let r,c,u=!1;return Array.isArray(o)?(c=o,u=!0):(r=o.create(t).injector,c=r.get(Ba,[],{optional:!0,self:!0}).flat()),{routes:c.map(Ih),injector:r}}))}function IO(e){return e&&typeof e=="object"&&"default"in e}function wb(e){return IO(e)?e.default:e}var qc=(()=>{class e{static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:()=>h(TO),providedIn:"root"})}return e})(),TO=(()=>{class e{shouldProcessUrl(t){return!0}extract(t){return t}merge(t,i){return t}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),Eb=new K("");var Mb=new K(""),Pb=(()=>{class e{currentNavigation=null;currentTransition=null;lastSuccessfulNavigation=null;events=new Ue;
8transitionAbortSubject=new Ue;configLoader=h(xb);environmentInjector=h(yt);destroyRef=h(io);urlSerializer=h(Fa);rootContexts=h(pr);location=h(er);inputBindingEnabled=h(Gc,{optional:!0})!==null;titleStrategy=h(Th);options=h(ja,{optional:!0})||{};paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly";urlHandlingStrategy=h(qc);createViewTransition=h(Eb,{optional:!0});navigationErrorHandler=h(Mb,{optional:!0});navigationId=0;get hasRequestedNavigation(){return this.navigationId!==0}transitions;afterPreactivation=()=>Q(void 0);rootComponentType=null;destroyed=!1;constructor(){let t=o=>this.events.next(new kc(o)),i=o=>this.events.next(new Ac(o));this.configLoader.onLoadEndListener=i,this.configLoader.onLoadStartListener=t,this.destroyRef.onDestroy(()=>{this.destroyed=!0})}complete(){this.transitions?.complete()}handleNavigationRequest(t){let i=++this.navigationId;this.transitions?.next(oe(U({},t),{extractedUrl:this.urlHandlingStrategy.extract(t.rawUrl),targetSnapshot:null,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null,id:i}))}setupNavigations(t){return this.transitions=new ft(null),this.transitions.pipe(Gt(i=>i!==null),be(i=>{let o=!1,r=!1;return Q(i).pipe(be(c=>{if(this.navigationId>i.id)return this.cancelNavigationTransition(i,"",Ht.SupersededByNewNavigation),Tt;this.currentTransition=i,this.currentNavigation={id:c.id,initialUrl:c.rawUrl,extractedUrl:c.extractedUrl,targetBrowserUrl:typeof c.extras.browserUrl=="string"?this.urlSerializer.parse(c.extras.browserUrl):c.extras.browserUrl,trigger:c.source,extras:c.extras,previousNavigation:this.lastSuccessfulNavigation?oe(U({},this.lastSuccessfulNavigation),{previousNavigation:null}):null};let u=!t.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl(),m=c.extras.onSameUrlNavigation??t.onSameUrlNavigation;if(!u&&m!=="reload")return this.events.next(new ui(c.id,this.urlSerializer.serialize(c.rawUrl),"",Pa.IgnoredSameUrlNavigation)),c.resolve(!1),Tt;if(this.urlHandlingStrategy.shouldProcessUrl(c.rawUrl))return Q(c).pipe(be(f=>(this.events.next(new go(f.id,this.urlSerializer.serialize(f.extractedUrl),f.source,f.restoredState)),f.id!==this.navigationId?Tt:Promise.resolve(f))),wO(this.environmentInjector,this.configLoader,this.rootComponentType,t.config,this.urlSerializer,this.paramsInheritanceStrategy),xe(f=>{i.targetSnapshot=f.targetSnapshot,i.urlAfterRedirects=f.urlAfterRedirects,this.currentNavigation=oe(U({},this.currentNavigation),{finalUrl:f.urlAfterRedirects});let C=new Da(f.id,this.urlSerializer.serialize(f.extractedUrl),this.urlSerializer.serialize(f.urlAfterRedirects),f.targetSnapshot);this.events.next(C)}));if(u&&this.urlHandlingStrategy.shouldProcessUrl(c.currentRawUrl)){let{id:f,extractedUrl:C,source:b,restoredState:P,extras:x}=c,D=new go(f,this.urlSerializer.serialize(C),b,P);this.events.next(D);let V=cb(this.rootComponentType).snapshot;return this.currentTransition=i=oe(U({},c),{targetSnapshot:V,urlAfterRedirects:C,extras:oe(U({},x),{skipLocationChange:!1,replaceUrl:!1})}),this.currentNavigation.finalUrl=C,Q(i)}else return this.events.next(new ui(c.id,this.urlSerializer.serialize(c.extractedUrl),"",Pa.IgnoredByUrlHandlingStrategy)),c.resolve(!1),Tt}),xe(c=>{let u=new Ic(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects),c.targetSnapshot);this.events.next(u)}),N(c=>(this.currentTransition=i=oe(U({},c),{guards:zT(c.targetSnapshot,c.currentSnapshot,this.rootContexts)}),i)),tO(this.environmentInjector,c=>this.events.next(c)),xe(c=>{if(i.guardsResult=c.guardsResult,c.guardsResult&&typeof c.guardsResult!="boolean")throw Hc(this.urlSerializer,c.guardsResult);let u=new Tc(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects),c.targetSnapshot,!!c.guardsResult);this.events.next(u)}),Gt(c=>c.guardsResult?!0:(this.cancelNavigationTransition(c,"",Ht.GuardRejected),!1)),mh(c=>{if(c.guards.canActivateChecks.length!==0)return Q(c).pipe(xe(u=>{let m=new Oc(u.id,this.urlSerializer.serialize(u.extractedUrl),this.urlSerializer.serialize(u.urlAfterRedirects),u.targetSnapshot);this.events.next(m)}),be(u=>{let m=!1;return Q(u).pipe(EO(this.paramsInheritanceStrategy,this.environmentInjector),xe({next:()=>m=!0,complete:()=>
8{m||this.cancelNavigationTransition(u,"",Ht.NoDataFromResolver)}}))}),xe(u=>{let m=new Nc(u.id,this.urlSerializer.serialize(u.extractedUrl),this.urlSerializer.serialize(u.urlAfterRedirects),u.targetSnapshot);this.events.next(m)}))}),mh(c=>{let u=m=>{let f=[];m.routeConfig?.loadComponent&&!m.routeConfig._loadedComponent&&f.push(this.configLoader.loadComponent(m.routeConfig).pipe(xe(C=>{m.component=C}),N(()=>{})));for(let C of m.children)f.push(...u(C));return f};return Ci(u(c.targetSnapshot.root)).pipe(vi(null),Zn(1))}),mh(()=>this.afterPreactivation()),be(()=>{let{currentSnapshot:c,targetSnapshot:u}=i,m=this.createViewTransition?.(this.environmentInjector,c.root,u.root);return m?ze(m).pipe(N(()=>i)):Q(i)}),N(c=>{let u=UT(t.routeReuseStrategy,c.targetSnapshot,c.currentRouterState);return this.currentTransition=i=oe(U({},c),{targetRouterState:u}),this.currentNavigation.targetRouterState=u,i}),xe(()=>{this.events.next(new Ia)}),$T(this.rootContexts,t.routeReuseStrategy,c=>this.events.next(c),this.inputBindingEnabled),Zn(1),xe({next:c=>{o=!0,this.lastSuccessfulNavigation=this.currentNavigation,this.events.next(new $n(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects))),this.titleStrategy?.updateTitle(c.targetRouterState.snapshot),c.resolve(!0)},complete:()=>{o=!0}}),im(this.transitionAbortSubject.pipe(xe(c=>{throw c}))),ji(()=>{!o&&!r&&this.cancelNavigationTransition(i,"",Ht.SupersededByNewNavigation),this.currentTransition?.id===i.id&&(this.currentNavigation=null,this.currentTransition=null)}),Ze(c=>{if(this.destroyed)return i.resolve(!1),Tt;if(r=!0,hb(c))this.events.next(new Bn(i.id,this.urlSerializer.serialize(i.extractedUrl),c.message,c.cancellationCode)),HT(c)?this.events.next(new dr(c.url,c.navigationBehaviorOptions)):i.resolve(!1);else{let u=new cr(i.id,this.urlSerializer.serialize(i.extractedUrl),c,i.targetSnapshot??void 0);try{let m=Kt(this.environmentInjector,()=>this.navigationErrorHandler?.(u));if(m instanceof ur){let{message:f,cancellationCode:C}=Hc(this.urlSerializer,m);this.events.next(new Bn(i.id,this.urlSerializer.serialize(i.extractedUrl),f,C)),this.events.next(new dr(m.redirectTo,m.navigationBehaviorOptions))}else throw this.events.next(u),c}catch(m){this.options.resolveNavigationPromiseOnError?i.resolve(!1):i.reject(m)}}return Tt}))}))}cancelNavigationTransition(t,i,o){let r=new Bn(t.id,this.urlSerializer.serialize(t.extractedUrl),i,o);this.events.next(r),t.resolve(!1)}isUpdatingInternalState(){return this.currentTransition?.extractedUrl.toString()!==this.currentTransition?.currentUrlTree.toString()}isUpdatedBrowserUrl(){let t=this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(!0))),i=this.currentNavigation?.targetBrowserUrl??this.currentNavigation?.extractedUrl;return t.toString()!==i?.toString()&&!this.currentNavigation?.extras.skipLocationChange}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();function OO(e){return e!==Mc}var Db=(()=>{class e{static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:()=>h(NO),providedIn:"root"})}return e})(),zc=class{shouldDetach(n){return!1}store(n,t){}shouldAttach(n){return!1}retrieve(n){return null}shouldReuseRoute(n,t){return n.routeConfig===t.routeConfig}},NO=(()=>{class e extends zc{static \u0275fac=(()=>{let t;return function(o){return(t||(t=Yt(e)))(o||e)}})();static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})(),Ib=(()=>{class e{urlSerializer=h(Fa);options=h(ja,{optional:!0})||{};canceledNavigationResolution=this.options.canceledNavigationResolution||"replace";location=h(er);urlHandlingStrategy=h(qc);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";currentUrlTree=new Hn;getCurrentUrlTree(){return this.currentUrlTree}rawUrlTree=this.currentUrlTree;getRawUrlTree(){return this.rawUrlTree}createBrowserPath({finalUrl:t,initialUrl:i,targetBrowserUrl:o}){let r=t!==void 0?this.urlHandlingStrategy.merge(t,i):i,c=o??r;return c instanceof Hn?this.urlSerializer.serialize(c):c}commitTransition({targetRouterState:t,finalUrl:i,initialUrl:o}){i&&t?(this.currentUrlTree=i,this.rawUrlTree=this.urlHandlingStrategy.merge(i,o),this.routerState=t):this.rawUrlTree=o}routerState=cb(null);getRouterState(){return this.routerState}stateMemento=this.createStateMemento();updateStateMemento(){this.stateMemento=this.createStateMemento()}createStateMemento(){return{rawUrlTree:this.rawUrlTree,currentUrlTree:this.currentUrlTree,routerState:this.routerState}}resetInternalState({finalUrl:t}){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,t??this.rawUrlTree)}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:()=>h(kO),providedIn:"root"})}return e})(),kO=(()=>{class e extends Ib{currentPageId=0;lastSuccessfulId=-1;restoredState(){return this.location.getState()}get browserPageId(){return this.canceledNavigationResolution!=="computed"?this.currentPageId:this.restoredState()?.\u0275routerPageId??this.currentPageId}registerNonRouterCurrentEntryChangeListener(t){return this.location.subscribe(i=>{i.type==="popstate"&&setTimeout(()=>{t(i.url,i.state,"popstate")})})}handleRouterEvent(t,i){t instanceof go?this.updateStateMemento():t instanceof ui?this.commitTransition(i):t instanceof Da?this.urlUpdateStrategy==="eager"&&(i.extras.skipLocationChange||this.setBrowserUrl(this.createBrowserPath(i),i)):t instanceof Ia?(this.commitTransition(i),this.urlUpdateStrategy==="deferred"&&!i.extras.skipLocationChange&&this.setBrowserUrl(this.createBrowserPath(i),i)):t instanceof Bn&&(t.code===Ht.GuardRejected||t.code===Ht.N
vendor: 4,157 bytes, line 8
8oDataFromResolver)?this.restoreHistory(i):t instanceof cr?this.restoreHistory(i,!0):t instanceof $n&&(this.lastSuccessfulId=t.id,this.currentPageId=this.browserPageId)}setBrowserUrl(t,{extras:i,id:o}){let{replaceUrl:r,state:c}=i;if(this.location.isCurrentPathEqualTo(t)||r){let u=this.browserPageId,m=U(U({},c),this.generateNgRouterState(o,u));this.location.replaceState(t,"",m)}else{let u=U(U({},c),this.generateNgRouterState(o,this.browserPageId+1));this.location.go(t,"",u)}}restoreHistory(t,i=!1){if(this.canceledNavigationResolution==="computed"){let o=this.browserPageId,r=this.currentPageId-o;r!==0?this.location.historyGo(r):this.getCurrentUrlTree()===t.finalUrl&&r===0&&(this.resetInternalState(t),this.resetUrlToCurrentUrlTree())}else this.canceledNavigationResolution==="replace"&&(i&&this.resetInternalState(t),this.resetUrlToCurrentUrlTree())}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.getRawUrlTree()),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(t,i){return this.canceledNavigationResolution==="computed"?{navigationId:t,\u0275routerPageId:i}:{navigationId:t}}static \u0275fac=(()=>{let t;return function(o){return(t||(t=Yt(e)))(o||e)}})();static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();function Oh(e,n){e.events.pipe(Gt(t=>t instanceof $n||t instanceof Bn||t instanceof cr||t instanceof ui),N(t=>t instanceof $n||t instanceof ui?0:(t instanceof Bn?t.code===Ht.Redirect||t.code===Ht.SupersededByNewNavigation:!1)?2:1),Gt(t=>t!==2),Zn(1)).subscribe(()=>{n()})}var AO={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},RO={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"},Dt=(()=>{class e{get currentUrlTree(){return this.stateManager.getCurrentUrlTree()}get rawUrlTree(){return this.stateManager.getRawUrlTree()}disposed=!1;nonRouterCurrentEntryChangeSubscription;console=h(Nf);stateManager=h(Ib);options=h(ja,{optional:!0})||{};pendingTasks=h(Ln);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";navigationTransitions=h(Pb);urlSerializer=h(Fa);location=h(er);urlHandlingStrategy=h(qc);_events=new Ue;get events(){return this._events}get routerState(){return this.stateManager.getRouterState()}navigated=!1;routeReuseStrategy=h(Db);onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore";config=h(Ba,{optional:!0})?.flat()??[];componentInputBindingEnabled=!!h(Gc,{optional:!0});constructor(){this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this).subscribe({error:t=>{this.console.warn(t)}}),this.subscribeToNavigationEvents()}eventsSubscription=new Qe;subscribeToNavigationEvents(){let t=this.navigationTransitions.events.subscribe(i=>{try{let o=this.navigationTransitions.currentTransition,r=this.navigationTransitions.currentNavigation;if(o!==null&&r!==null){if(this.stateManager.handleRouterEvent(i,r),i instanceof Bn&&i.code!==Ht.Redirect&&i.code!==Ht.SupersededByNewNavigation)this.navigated=!0;else if(i instanceof $n)this.navigated=!0;else if(i instanceof dr){let c=i.navigationBehaviorOptions,u=this.urlHandlingStrategy.merge(i.url,o.currentRawUrl),m=U({browserUrl:o.extras.browserUrl,info:o.extras.info,skipLocationChange:o.extras.skipLocationChange,replaceUrl:o.extras.replaceUrl||this.urlUpdateStrategy==="eager"||OO(o.source)},c);this.scheduleNavigation(u,Mc,null,m,{resolve:o.resolve,reject:o.reject,promise:o.promise})}}LO(i)&&this._events.next(i)}catch(o){this.navigationTransitions.transitionAbortSubject.next(o)}});this.eventsSubscription.add(t)}resetRootComponentType(t){this.routerState.root.component=t,this.navigationTransitions.rootComponentType=t}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),Mc,this.stateManager.restoredState())}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((t,i,o)=>{this.navigateToSyncWithBrowser(t,o,i)})}navigateToSyncWithBrowser(t,i,o){let r={replaceUrl:!0}
8,c=o?.navigationId?o:null;if(o){let m=U({},o);delete m.navigationId,delete m.\u0275routerPageId,Object.keys(m).length!==0&&(r.state=m)}let u=this.parseUrl(t);this.scheduleNavigation(u,i,c,r)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(t){this.config=t.map(Ih),this.navigated=!1}ngOnDestroy(){this.dispose()}dispose(){this._events.unsubscribe(),this.navigationTransitions.complete(),this.nonRouterCurrentEntryChangeSubscription&&(this.nonRouterCurrentEntryChangeSubscription.unsubscribe(),this.nonRouterCurrentEntryChangeSubscription=void 0),this.disposed=!0,this.eventsSubscription.unsubscribe()}createUrlTree(t,i={}){let{relativeTo:o,queryParams:r,fragment:c,queryParamsHandling:u,preserveFragment:m}=i,f=m?this.currentUrlTree.fragment:c,C=null;switch(u??this.options.defaultQueryParamsHandling){case"merge":C=U(U({},this.currentUrlTree.queryParams),r);break;case"preserve":C=this.currentUrlTree.queryParams;break;default:C=r||null}C!==null&&(C=this.removeEmptyProps(C));let b;try{let P=o?o.snapshot:this.routerState.snapshot.root;b=rb(P)}catch{(typeof t[0]!="string"||t[0][0]!=="/")&&(t=[]),b=this.currentUrlTree.root}return ab(b,t,C,f??null)}navigateByUrl(t,i={skipLocationChange:!1}){let o=ki(t)?t:this.parseUrl(t),r=this.urlHandlingStrategy.merge(o,this.rawUrlTree);return this.scheduleNavigation(r,Mc,null,i)}navigate(t,i={skipLocationChange:!1}){return FO(t),this.navigateByUrl(this.createUrlTree(t,i),i)}serializeUrl(t){return this.urlSerializer.serialize(t)}parseUrl(t){try{return this.urlSerializer.parse(t)}catch{return this.urlSerializer.parse("/")}}isActive(t,i){let o;if(i===!0?o=U({},AO):i===!1?o=U({},RO):o=i,ki(t))return jy(this.currentUrlTree,t,o);let r=this.parseUrl(t);return jy(this.currentUrlTree,r,o)}removeEmptyProps(t){return Object.entries(t).reduce((i,[o,r])=>(r!=null&&(i[o]=r),i),{})}scheduleNavigation(t,i,o,r,c){if(this.disposed)return Promise.resolve(!1);let u,m,f;c?(u=c.resolve,m=c.reject,f=c.promise):f=new Promise((b,P)=>{u=b,m=P});let C=this.pendingTasks.add();return Oh(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(C))}),this.navigationTransitions.handleNavigationRequest({source:i,restoredState:o,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:t,extras:r,resolve:u,reject:m,promise:f,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),f.catch(b=>Promise.reject(b))}static \u0275fac=function(i){return new(i||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();function FO(e){for(let n=0;n<e.length;n++)if(e[n]==null)throw new J(4008,!1)}function LO(e){return!(e instanceof Ia)&&!(e instanceof dr)}var W=(()=>{class e{router;route;tabIndexAttribute;renderer;el;locationStrategy;href=null;target;queryParams;fragment;queryParamsHandling;state;info;relativeTo;isAnchorElement;subscription;onChanges=new Ue;constructor(t,i,o,r,c,u){this.router=t,this.route=i,this.tabIndexAttribute=o,this.renderer=r,this.el=c,this.locationStrategy=u;let m=c.nativeElement.tagName?.toLowerCase();this.isAnchorElement=m==="a"||m==="area",this.isAnchorElement?this.subscription=t.events.subscribe(f=>{f instanceof $n&&this.updateHref()}):this.setTabIndexIfNotOnNativeEl("0")}preserveFragment=!1;skipLocationChange=!1;replaceUrl=!1;setTabIndexIfNotOnNativeEl(t){this.tabIndexAttribute!=null||this.isAnchorElement||this.applyAttributeValue("tabindex",t)}ngOnChanges(t){this.isAnchorElement&&this.updateHref(),this.onChanges.next(this)}routerLinkInput=null;set routerLink(t){t==null?(this.routerLinkInput=null,this.setTabIndexIfNotOnNativeEl(null)):(ki(t)?this.routerLinkInput=t:this.routerLinkInput=Array.isArray(t)?t:[t],this.setTabIndexIfNotOnNativeEl("0"))}onClick(t,i,o,r,c){let u=this.urlTree;if(u===null||this.isAnchorElement&&(t!==0||i||o||r||c||typeof this.target=="string"&&this.target!="_self"))return!0;let m={skipLocationChange:this.skipLocationChange,replaceUrl:this.replaceUrl,state:this.state,info:this.info};return this.router.navigateByUrl(u,m),!this.isAnchorElement}ngOnDestroy(){this.subscription?.unsubscribe()}updateHref(){let t=this.urlTree;this.href=t!==null&&this.locationStrategy?this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(t)):null;let i=this.href===null?null:I_(this.href,this.el.nativeElement.tagName.toLowerCase(),"href");this.applyAttributeValue("href",i)}applyAttributeValue(t,i){let o=this.renderer,r=this.el.nativeElement;i!==null?o.setAttribute(r,t,i):o.removeAttribute(r,t)}get urlTree(){return this.routerLinkInput===null?null:ki(this.routerLinkInput)?this.routerLinkInput:this.router.createUrlTree(this.routerLinkInput,{relativeTo:this.relativeTo!==void 0?this.relativeTo:this.route,queryParams:this.queryParams,fragment:this.fragment,queryParamsHandling:this.queryParamsHandling,preserveFragment:this.preserveFragment})}static \u0275fac=function(i){return new(i||e)(me(Dt),me(ve),Qp("tabindex"),me(Ut),me(Lt),me(Xo))};static \u0275dir=Le({type:e,selectors:[["","routerLink",""]],hostVars:1,hostBindings:function(i,o){i&1&&M("click",function(c){return o.onClick(c.button,c.ctrlKey,c.shift
8Key,c.altKey,c.metaKey)}),i&2&&_e("target",o.target)},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",state:"state",info:"info",relativeTo:"relativeTo",preserveFragment:[2,"preserveFragment","preserveFragment",lo],skipLocationChange:[2,"skipLocationChange","skipLocationChange",lo],replaceUrl:[2,"replaceUrl","replaceUrl",lo],routerLink:"routerLink"},features:[ct]})}return e})();var UO=new K("");function Nh(e,...n){return Mi([{provide:Ba,multi:!0,useValue:e},[],{provide:ve,useFactory:jO,deps:[Dt]},{provide:ao,multi:!0,useFactory:BO},n.map(t=>t.\u0275providers)])}function jO(e){return e.routerState.root}function BO(){let e=h(sn);return n=>{let t=e.get(Rt);if(n!==t.components[0])return;let i=e.get(Dt),o=e.get(HO);e.get($O)===1&&i.initialNavigation(),e.get(zO,null,de.Optional)?.setUpPreloading(),e.get(UO,null,de.Optional)?.init(),i.resetRootComponentType(t.componentTypes[0]),o.closed||(o.next(),o.complete(),o.unsubscribe())}}var HO=new K("",{factory:()=>new Ue}),$O=new K("",{providedIn:"root",factory:()=>1});var zO=new K("");var mi=[{id:"6255146",name:"Africa"},{id:"6255147",name:"Asia"},{id:"6255148",name:"Europe"},{id:"6255149",name:"North America"},{id:"6255150",name:"South America"},{id:"6255151",name:"Oceania"},{id:"6255152",name:"Antarctica"}],Tb={AF:mi[0],AS:mi[1],EU:mi[2],NA:mi[3],SA:mi[4],OC:mi[5],AN:mi[6]};var tt=class e{getRoots(){return mi}slug(n){return`${(n.asciiName??n.name).toLowerCase().trim().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")}.html`}path(n){return`/${n.id}/${this.slug(n)}`}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var GO=(e,n)=>n.id;function WO(e,n){if(e&1&&(l(0,"li")(1,"a",3),s(2),a()()),e&2){let t=n.$implicit,i=p();d(),v("routerLink",i.places.path(t)),d(),g(t.name)}}var Jc=class e{places=h(tt);title=h(H);meta=h(Ni);roots=this.places.getRoots();constructor(){this.title.setTitle("GeoNames UI \u2014 Browse places by administrative hierarchy"),this.meta.updateTag({name:"description",content:"A GeoNames-style directory of places, browsable by continent, country, and administrative division."})}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-home-page"]],decls:8,vars:0,consts:[[1,"home"],[1,"intro"],[1,"roots"],[3,"routerLink"]],template:function(t,i){t&1&&(l(0,"div",0)(1,"h1"),s(2,"GeoNames UI"),a(),l(3,"p",1),s(4,"Browse the world by administrative hierarchy. Start with a continent:"),a(),l(5,"ul",2),I(6,WO,3,2,"li",null,GO),a()()),t&2&&(d(6),T(i.roots))},dependencies:[W],styles:[".home[_ngcontent-%COMP%]{max-width:800px;margin:0 auto;padding:1rem}.intro[_ngcontent-%COMP%]{color:#555}.roots[_ngcontent-%COMP%]{list-style:none;padding:0}.roots[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{padding:.6rem 0;border-bottom:1px solid #e5e5e5}.roots[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none;font-weight:500;font-size:1.1rem}.roots[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}"]})};var jb=(()=>{class e{_renderer;_elementRef;onChange=t=>{};onTouched=()=>{};constructor(t,i){this._renderer=t,this._elementRef=i}setProperty(t,i){this._renderer.setProperty(this._elementRef.nativeElement,t,i)}registerOnTouched(t){this.onTouched=t}registerOnChange(t){this.onChange=t}setDisabledState(t){this.setProperty("disabled",t)}static \u0275fac=function(i){return new(i||e)(me(Ut),me(Lt))};static \u0275dir=Le({type:e})}return e})(),Ja=(()=>{class e extends jb{static \u0275fac=(()=>{let t;return function(o){return(t||(t=Yt(e)))(o||e)}})();static \u0275dir=Le({type:e,features:[bt]})}return e})(),_r=new K(""),qO={provide:_r,useExisting:Ft(()=>pi),multi:!0},pi=(()=>{class e extends Ja{writeValue(t){this.setProperty("checked",t)}static \u0275fac=(()=>{let t;return function(o){return(t||(t=Yt(e)))(o||e)}})();static \u0275dir=Le({type:e,selectors:[["input","type","checkbox","formControlName",""],["input","type","checkbox","formControl",""],["input","type","checkbox","ngModel",""]],hostBindings:function(i,o){i&1&&M("change",function(c){return o.onChange(c.target.checked)})("blur",function(){return o.onTouched()})},standalone:!1,features:[cn([qO]),bt]})}return e})(),JO={provide:_r,useExisting:Ft(()=>Me),multi:!0};function KO(){let e=Xt()?Xt().getUserAgent():"";return/android (\d+)/.test(e.toLowerCase())}var YO=new K(""),Me=(()=>{class e extends jb{_compositionMode;_composing=!1;constructor(t,i,o){super(t,i),this._compositionMode=o,this._compositionMode==null&&(this._compositionMode=!KO())}writeValue(t){let i=t??"";this.setProperty("value",i)}_handleInput(t){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(t)}
vendor: 4,719 bytes, line 8
8_compositionStart(){this._composing=!0}_compositionEnd(t){this._composing=!1,this._compositionMode&&this.onChange(t)}static \u0275fac=function(i){return new(i||e)(me(Ut),me(Lt),me(YO,8))};static \u0275dir=Le({type:e,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(i,o){i&1&&M("input",function(c){return o._handleInput(c.target.value)})("blur",function(){return o.onTouched()})("compositionstart",function(){return o._compositionStart()})("compositionend",function(c){return o._compositionEnd(c.target.value)})},standalone:!1,features:[cn([JO]),bt]})}return e})();function ZO(e){return e==null||Bb(e)===0}function Bb(e){return e==null?null:Array.isArray(e)||typeof e=="string"?e.length:e instanceof Set?e.size:null}var vr=new K(""),Hb=new K("");function QO(e){return n=>{if(n.value==null||e==null)return null;let t=parseFloat(n.value);return!isNaN(t)&&t<e?{min:{min:e,actual:n.value}}:null}}function XO(e){return n=>{if(n.value==null||e==null)return null;let t=parseFloat(n.value);return!isNaN(t)&&t>e?{max:{max:e,actual:n.value}}:null}}function eN(e){return ZO(e.value)?{required:!0}:null}function tN(e){return n=>{let t=n.value?.length??Bb(n.value);return t!==null&&t>e?{maxlength:{requiredLength:e,actualLength:t}}:null}}function Ob(e){return null}function $b(e){return e!=null}function zb(e){return ro(e)?ze(e):e}function Gb(e){let n={};return e.forEach(t=>{n=t!=null?U(U({},n),t):n}),Object.keys(n).length===0?null:n}function Wb(e,n){return n.map(t=>t(e))}function nN(e){return!e.validate}function qb(e){return e.map(n=>nN(n)?n:t=>n.validate(t))}function iN(e){if(!e)return null;let n=e.filter($b);return n.length==0?null:function(t){return Gb(Wb(t,n))}}function Fh(e){return e!=null?iN(qb(e)):null}function oN(e){if(!e)return null;let n=e.filter($b);return n.length==0?null:function(t){let i=Wb(t,n).map(zb);return Rr(i).pipe(N(Gb))}}function Lh(e){return e!=null?oN(qb(e)):null}function Nb(e,n){return e===null?[n]:Array.isArray(e)?[...e,n]:[e,n]}function rN(e){return e._rawValidators}function aN(e){return e._rawAsyncValidators}function kh(e){return e?Array.isArray(e)?e:[e]:[]}function Yc(e,n){return Array.isArray(e)?e.includes(n):e===n}function kb(e,n){let t=kh(n);return kh(e).forEach(o=>{Yc(t,o)||t.push(o)}),t}function Ab(e,n){return kh(n).filter(t=>!Yc(e,t))}var Zc=class{get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators=[];_rawAsyncValidators=[];_setValidators(n){this._rawValidators=n||[],this._composedValidatorFn=Fh(this._rawValidators)}_setAsyncValidators(n){this._rawAsyncValidators=n||[],this._composedAsyncValidatorFn=Lh(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_onDestroyCallbacks=[];_registerOnDestroy(n){this._onDestroyCallbacks.push(n)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(n=>n()),this._onDestroyCallbacks=[]}reset(n=void 0){this.control&&this.control.reset(n)}hasError(n,t){return this.control?this.control.hasError(n,t):!1}getError(n,t){return this.control?this.control.getError(n,t):null}},Cr=class extends Zc{name;get formDirective(){return null}get path(){return null}},qa=class extends Zc{_parent=null;name=null;valueAccessor=null},Qc=class{_cd;constructor(n){this._cd=n}get isTouched(){return this._cd?.control?._touched?.(),!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return this._cd?.control?._pristine?.(),!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return this._cd?.control?._status?.(),!!this._cd?.control?.valid}
vendor: 19,143 bytes, line 8
8get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return this._cd?._submitted?.(),!!this._cd?.submitted}},sN={"[class.ng-untouched]":"isUntouched","[class.ng-touched]":"isTouched","[class.ng-pristine]":"isPristine","[class.ng-dirty]":"isDirty","[class.ng-valid]":"isValid","[class.ng-invalid]":"isInvalid","[class.ng-pending]":"isPending"},JW=oe(U({},sN),{"[class.ng-submitted]":"isSubmitted"}),Ne=(()=>{class e extends Qc{constructor(t){super(t)}static \u0275fac=function(i){return new(i||e)(me(qa,2))};static \u0275dir=Le({type:e,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(i,o){i&2&&pe("ng-untouched",o.isUntouched)("ng-touched",o.isTouched)("ng-pristine",o.isPristine)("ng-dirty",o.isDirty)("ng-valid",o.isValid)("ng-invalid",o.isInvalid)("ng-pending",o.isPending)},standalone:!1,features:[bt]})}return e})(),mt=(()=>{class e extends Qc{constructor(t){super(t)}static \u0275fac=function(i){return new(i||e)(me(Cr,10))};static \u0275dir=Le({type:e,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(i,o){i&2&&pe("ng-untouched",o.isUntouched)("ng-touched",o.isTouched)("ng-pristine",o.isPristine)("ng-dirty",o.isDirty)("ng-valid",o.isValid)("ng-invalid",o.isInvalid)("ng-pending",o.isPending)("ng-submitted",o.isSubmitted)},standalone:!1,features:[bt]})}return e})();var Ha="VALID",Kc="INVALID",hr="PENDING",$a="DISABLED",Ri=class{},Xc=class extends Ri{value;source;constructor(n,t){super(),this.value=n,this.source=t}},Ga=class extends Ri{pristine;source;constructor(n,t){super(),this.pristine=n,this.source=t}},Wa=class extends Ri{touched;source;constructor(n,t){super(),this.touched=n,this.source=t}},gr=class extends Ri{status;source;constructor(n,t){super(),this.status=n,this.source=t}},Ah=class extends Ri{source;constructor(n){super(),this.source=n}},Rh=class extends Ri{source;constructor(n){super(),this.source=n}};function Jb(e){return(nd(e)?e.validators:e)||null}function lN(e){return Array.isArray(e)?Fh(e):e||null}function Kb(e,n){return(nd(n)?n.asyncValidators:e)||null}function cN(e){return Array.isArray(e)?Lh(e):e||null}function nd(e){return e!=null&&!Array.isArray(e)&&typeof e=="object"}function dN(e,n,t){let i=e.controls;if(!(n?Object.keys(i):i).length)throw new J(1e3,"");if(!i[t])throw new J(1001,"")}function uN(e,n,t){e._forEachChild((i,o)=>{if(t[o]===void 0)throw new J(1002,"")})}var ed=class{_pendingDirty=!1;_hasOwnPendingAsyncValidator=null;_pendingTouched=!1;_onCollectionChange=()=>{};_updateOn;_parent=null;_asyncValidationSubscription;_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators;_rawAsyncValidators;value;constructor(n,t){this._assignValidators(n),this._assignAsyncValidators(t)}get validator(){return this._composedValidatorFn}set validator(n){this._rawValidators=this._composedValidatorFn=n}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(n){this._rawAsyncValidators=this._composedAsyncValidatorFn=n}get parent(){return this._parent}get status(){return si(this.statusReactive)}set status(n){si(()=>this.statusReactive.set(n))}_status=G(()=>this.statusReactive());statusReactive=E(void 0);get valid(){return this.status===Ha}get invalid(){return this.status===Kc}get pending(){return this.status==hr}get disabled(){return this.status===$a}get enabled(){return this.status!==$a}errors;get pristine(){return si(this.pristineReactive)}set pristine(n){si(()=>this.pristineReactive.set(n))}_pristine=G(()=>this.pristineReactive());pristineReactive=E(!0);get dirty(){return!this.pristine}get touched(){return si(this.touchedReactive)}set touched(n){si(()=>this.touchedReactive.set(n))}_touched=G(()=>this.touchedReactive());touchedReactive=E(!1);get untouched(){return!this.touched}_events=new Ue;events=this._events.asObservable();valueChanges;statusChanges;get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(n){this._assignValidators(n)}setAsyncValidators(n){this._assignAsyncValidators(n)}addValidators(n){this.setValidators(kb(n,this._rawValidators))}addAsyncValidators(n){this.setAsyncValidators(kb(n,this._rawAsyncValidators))}removeValidators(n){this.setValidators(Ab(n,this._rawValidators))}removeAsyncValidators(n){this.setAsyncValidators(Ab(n,this._rawAsyncValidators))}hasValidator(n){return Yc(this._rawValidators,n)}hasAsyncValidator(n){return Yc(this._rawAsyncValidators,n)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(n={}){let t=this.touched===!1;this.touched=!0;let i=n.sourceControl??this;this._parent&&!n.onlySelf&&this._parent.markAsTouched(oe(U({},n),{sourceControl:i})),t&&n.emitEvent!==!1&&this._events.next(new Wa(!0,i))}markAllAsTouched(n={}){this.markAsTouched({onlySelf:!0,emitEvent:n.emitEvent,sourceControl:this}),this._forEachChild(t=>t.markAllAsTouched(n))}markAsUntouched(n={}){let t=this.touched===!0;this.touched=!1,this._pendingTouched=!1;let i=n.sourceControl??this;this._forEachChild(o=>{o.markAsUntouched({onlySelf:!0,emitEvent:n.emitEvent,sourceControl:i})}),this._parent&&!n.onlySelf&&this._parent._updateTouched(n,i),t&&n.emitEvent!==!1&&this._events.next(new Wa(!1,i))}markAsDirty(n={}){let t=this.pristine===!0;this.pristine=!1;let i=n.sourceControl??this;this._parent&&!n.onlySelf&&this._parent.markAsDirty(oe(U({},n),{sourceControl:i})),t&&n.emitEvent!==!1&&this._events.next(new Ga(!1,i))}markAsPristine(n={}){let t=this.pristine===!1;this.pristine=!0,this._pendingDirty=!1;let i=n.sourceControl??this;this._forEachChild(o=>{o.markAsPristine({onlySelf:!0,emitEvent:n.emitEvent})}),this._parent&&!n.onlySelf&&this._parent._updatePristine(n,i),t&&n.emitEvent!==!1&&this._events.next(new Ga(!0,i))}markAsPending(n={}){this.status=hr;let t=n.sourceControl??this;n.emitEvent!==!1&&(this._events.next(new gr(this.status,t)),this.statusChanges.emit(this.status)),this._parent&&!n.onlySelf&&this._parent.markAsPending(oe(U({},n),{sourceControl:t}))}disable(n={}){let t=this._parentMarkedDirty(n.onlySelf);this.status=$a,this.errors=null,this._forEachChild(o=>{o.disable(oe(U({},n),{onlySelf:!0}))}),this._updateValue();let i=n.sourceControl??this;n.emitEvent!==!1&&(this._events.next(new Xc(this.value,i)),this._events.next(new gr(this.status,i)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(oe(U({},n),{skipPristineCheck:t}),this),this._onDisabledChange.forEach(o=>o(!0))}enable(n={}){let t=this._parentMarkedDirty(n.onlySelf);this.status=Ha,this._forEachChild(i=>{i.enable(oe(U({},n),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:n.emitEvent}),this._updateAncestors(oe(U({},n),{skipPristineCheck:t}),this),this._onDisabledChange.forEach(i=>i(!1))}_updateAncestors(n,t){this._parent&&!n.onlySelf&&(this._parent.updateValueAndValidity(n),n.skipPristineCheck||this._parent._updatePristine({},t),this._parent._updateTouched({},t))}setParent(n){this._parent=n}getRawValue(){return this.value}updateValueAndValidity(n={}){if(this._setInitialStatus(),this._updateValue(),this.enabled){let i=this._cancelExistingSubscription();this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===Ha||this.status===hr)&&this._runAsyncValidator(i,n.emitEvent)}let t=n.sourceControl??this;n.emitEvent!==!1&&(this._events.next(new Xc(this.value,t)),this._events.next(new gr(this.status,t)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!n.onlySelf&&this._parent.updateValueAndValidity(oe(U({},n),{sourceControl:t}))}_updateTreeValidity(n={emitEvent:!0}){this._forEachChild(t=>t._updateTreeValidity(n)),this.updateValueAndValidity({onlySelf:!0,emitEvent:n.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?$a:Ha}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(n,t){if(this.asyncValidator){this.status=hr,this._hasOwnPendingAsyncValidator={emitEvent:t!==!1};let i=zb(this.asyncValidator(this));this._asyncValidationSubscription=i.subscribe(o=>{this._hasOwnPendingAsyncValidator=null,this.setErrors(o,{emitEvent:t,shouldHaveEmitted:n})})}}_cancelExistingSubscription(){if(this._asyncValidationSubscription){this._asyncValidationSubscription.unsubscribe();let n=this._hasOwnPendingAsyncValidator?.emitEvent??!1;return this._hasOwnPendingAsyncValidator=null,n}return!1}setErrors(n,t={}){this.errors=n,this._updateControlsErrors(t.emitEvent!==!1,this,t.shouldHaveEmitted)}get(n){let t=n;return t==null||(Array.isArray(t)||(t=t.split(".")),t.length===0)?null:t.reduce((i,o)=>i&&i._find(o),this)}getError(n,t){let i=t?this.get(t):this;return i&&i.errors?i.errors[n]:null}hasError(n,t){return!!this.getError(n,t)}get root(){let n=this;for(;n._parent;)n=n._parent;return n}_updateControlsErrors(n,t,i){this.status=this._calculateStatus(),n&&this.statusChanges.emit(this.status),(n||i)&&this._events.next(new gr(this.status,t)),this._parent&&this._parent._updateControlsErrors(n,t,i)}_initObservables(){this.valueChanges=new je,this.statusChanges=new je}_calculateStatus(){return this._allControlsDisabled()?$a:this.errors?Kc:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(hr)?hr:this._anyControlsHaveStatus(Kc)?Kc:Ha}_anyControlsHaveStatus(n){return this._anyControls(t=>t.status===n)}_anyControlsDirty(){return this._anyControls(n=>n.dirty)}_anyControlsTouched(){return this._anyControls(n=>n.touched)}_updatePristine(n,t){let i=!this._anyControlsDirty(),o=this.pristine!==i;this.pristine=i,this._parent&&!n.onlySelf&&this._parent._updatePristine(n,t),o&&this._events.next(new Ga(this.pristine,t))}_updateTouched(n={},t){this.touched=this._anyControlsTouched(),this._events.next(new Wa(this.touched,t)),this._parent&&!n.onlySelf&&this._parent._updateTouched(n,t)}_onDisabledChange=[];_registerOnCollectionChange(n){this._onCollectionChange=n}_setUpdateStrategy(n){nd(n)&&n.updateOn!=null&&(this._updateOn=n.updateOn)}_parentMarkedDirty(n){let t=this._parent&&this._parent.dirty;return!n&&!!t&&!this._parent._anyControlsDirty()}_find(n){return null}_assignValidators(n){this._rawValidators=Array.isArray(n)?n.slice():n,this._composedValidatorFn=lN(this._rawValidators)}_assignAsyncValidators(n){this._rawAsyncValidators=Array.isArray(n)?n.slice():n,this._composedAsyncValidatorFn=cN(this._rawAsyncValidators)}},td=class extends ed{constructor(n,t,i){super(Jb(t),Kb(i,t)),this.controls=n,this._initObservables(),this._setUpdateStrategy(t),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;registerControl(n,t){return this.controls[n]?this.controls[n]:(this.controls[n]=t,t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange),t)}addControl(n,t,i={}){this.registerControl(n,t),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}removeControl(n,t={}){this.controls[n]&&this.controls[n]._registerOnCollectionChange(()=>{}),delete this.controls[n],this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}setControl(n,t,i={}){this.controls[n]&&this.controls[n]._registerOnCollectionChange(()=>{}),delete this.controls[n],t&&this.registerControl(n,t),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}contains(n){return this.controls.hasOwnProperty(n)&&this.controls[n].enabled}setValue(n,t={}){uN(this,!0,n),Object.keys(n).forEach(i=>{dN(this,!0,i),this.controls[i].setValue(n[i],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}patchValue(n,t={}){n!=null&&(Object.keys(n).forEach(i=>{let o=this.controls[i];o&&o.patchValue(n[i],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t))}reset(n={},t={}){this._forEachChild((i,o)=>{i.reset(n?n[o]:null,{onlySelf:!0,emitEvent:t.emitEvent})}),this._updatePristine(t,this),this._updateTouched(t,this),this.updateValueAndValidity(t)}getRawValue(){return this._reduceChildren({},(n,t,i)=>(n[i]=t.getRawValue(),n))}_syncPendingControls(){let n=this._reduceChildren(!1,(t,i)=>i._syncPendingControls()?!0:t);return n&&this.updateValueAndValidity({onlySelf:!0}),n}_forEachChild(n){Object.keys(this.controls).forEach(t=>{let i=this.controls[t];i&&n(i,t)})}_setUpControls(){this._forEachChild(n=>{n.setParent(this),n._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(n){for(let[t,i]of Object.entries(this.controls))if(this.contains(t)&&n(i))return!0;return!1}_reduceValue(){let n={};return this._reduceChildren(n,(t,i,o)=>((i.enabled||this.disabled)&&(t[o]=i.value),t))}_reduceChildren(n,t){let i=n;return this._forEachChild((o,r)=>{i=t(i,o,r)}),i}_allControlsDisabled(){for(let n of Object.keys(this.controls))if(this.controls[n].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(n){return this.controls.hasOwnProperty(n)?this.controls[n]:null}};var Vh=new K("",{providedIn:"root",factory:()=>Uh}),Uh="always";function mN(e,n){return[...n.path,e]}function Yb(e,n,t=Uh){Zb(e,n),n.valueAccessor.writeValue(e.value),(e.disabled||t==="always")&&n.valueAccessor.setDisabledState?.(e.disabled),fN(e,n),gN(e,n),hN(e,n),pN(e,n)}function Rb(e,n){e.forEach(t=>{t.registerOnValidatorChange&&t.registerOnValidatorChange(n)})}function pN(e,n){if(n.valueAccessor.setDisabledState){let t=i=>{n.valueAccessor.setDisabledState(i)};e.registerOnDisabledChange(t),n._registerOnDestroy(()=>{e._unregisterOnDisabledChange(t)})}}function Zb(e,n){let t=rN(e);n.validator!==null?e.setValidators(Nb(t,n.validator)):typeof t=="function"&&e.setValidators([t]);let i=aN(e);n.asyncValidator!==null?e.setAsyncValidators(Nb(i,n.asyncValidator)):typeof i=="function"&&e.setAsyncValidators([i]);let o=()=>e.updateValueAndValidity();Rb(n._rawValidators,o),Rb(n._rawAsyncValidators,o)}function fN(e,n){n.valueAccessor.registerOnChange(t=>{e._pendingValue=t,e._pendingChange=!0,e._pendingDirty=!0,e.updateOn==="change"&&Qb(e,n)})}function hN(e,n){n.valueAccessor.registerOnTouched(()=>{e._pendingTouched=!0,e.updateOn==="blur"&&e._pendingChange&&Qb(e,n),e.updateOn!=="submit"&&e.markAsTouched()})}function Qb(e,n){e._pendingDirty&&e.markAsDirty(),e.setValue(e._pendingValue,{emitModelToViewChange:!1}),n.viewToModelUpdate(e._pendingValue),e._pendingChange=!1}function gN(e,n){let t=(i,o)=>{n.valueAccessor.writeValue(i),o&&n.viewToModelUpdate(i)};e.registerOnChange(t),n._registerOnDestroy(()=>{e._unregisterOnChange(t)})}function CN(e,n){e==null,Zb(e,n)}function _N(e,n){if(!e.hasOwnProperty("model"))return!1;let t=e.model;return t.isFirstChange()?!0:!Object.is(n,t.currentValue)}function vN(e){return Object.getPrototypeOf(e.constructor)===Ja}function yN(e,n){e._syncPendingControls(),n.forEach(t=>{let i=t.control;i.updateOn==="submit"&&i._pendingChange&&(t.viewToModelUpdate(i._pendingValue),i._pendingChange=!1)})}function bN(e,n){if(!n)return null;Array.isArray(n);let t,i,o;return n.forEach(r=>{r.constructor===Me?t=r:vN(r)?i=r:o=r}),o||i||t||null}var xN={provide:Cr,useExisting:Ft(()=>dt)},za=Promise.resolve(),dt=(()=>{class e extends Cr{callSetDisabledState;get submitted(){return si(this.submittedReactive)}_submitted=G(()=>this.submittedReactive());submittedReactive=E(!1);_directives=new Set;form;ngSubmit=new je;options;constructor(t,i,o){super(),this.callSetDisabledState=o,this.form=new td({},Fh(t),Lh(i))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(t){za.then(()=>{let i=this._findContainer(t.path);t.control=i.registerControl(t.name,t.control),Yb(t.control,t,this.callSetDisabledState),t.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(t)})}getControl(t){return this.form.get(t.path)}removeControl(t){za.then(()=>{let i=this._findContainer(t.path);i&&i.removeControl(t.name),this._directives.delete(t)})}addFormGroup(t){za.then(()=>{let i=this._findContainer(t.path),o=new td({});CN(o,t),i.registerControl(t.name,o),o.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(t){za.then(()=>{let i=this._findContainer(t.path);i&&i.removeControl(t.name)})}getFormGroup(t){return this.form.get(t.path)}updateModel(t,i){za.then(()=>{this.form.get(t.path).setValue(i)})}setValue(t){this.control.setValue(t)}onSubmit(t){return this.submittedReactive.set(!0),yN(this.form,this._directives),this.ngSubmit.emit(t),this.form._events.next(new Ah(this.control)),t?.target?.method==="dialog"}onReset(){this.resetForm()}resetForm(t=void 0){this.form.reset(t),this.submittedReactive.set(!1),this.form._events.next(new Rh(this.form))}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.form._updateOn=this.options.updateOn)}_findContainer(t){return t.pop(),t.length?this.form.get(t):this.form}static \u0275fac=function(i){return new(i||e)(me(vr,10),me(Hb,10),me(Vh,8))};static \u0275dir=Le({type:e,selectors:[["form",3,"ngNoForm","",3,"formGroup",""],["ng-form"],["","ngForm",""]],hostBindings:function(i,o){i&1&&M("submit",function(c){return o.onSubmit(c)})("reset",function(){return o.onReset()})},inputs:{options:[0,"ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[cn([xN]),bt]})}return e})();function Fb(e,n){let t=e.indexOf(n);t>-1&&e.splice(t,1)}function Lb(e){return typeof e=="object"&&e!==null&&Object.keys(e).length===2&&"value"in e&&"disabled"in e}var SN=class extends ed{defaultValue=null;_onChange=[];_pendingValue;_pendingChange=!1;constructor(n=null,t,i){super(Jb(t),Kb(i,t)),this._applyFormState(n),this._setUpdateStrategy(t),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),nd(t)&&(t.nonNullable||t.initialValueIsDefault)&&(Lb(n)?this.defaultValue=n.value:this.defaultValue=n)}setValue(n,t={}){this.value=this._pendingValue=n,this._onChange.length&&t.emitModelToViewChange!==!1&&this._onChange.forEach(i=>i(this.value,t.emitViewToModelChange!==!1)),this.updateValueAndValidity(t)}patchValue(n,t={}){this.setValue(n,t)}reset(n=this.defaultValue,t={}){this._applyFormState(n),this.markAsPristine(t),this.markAsUntouched(t),this.setValue(this.value,t),this._pendingChange=!1}_updateValue(){}_anyControls(n){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(n){this._onChange.push(n)}_unregisterOnChange(n){Fb(this._onChange,n)}registerOnDisabledChange(n){this._onDisabledChange.push(n)}_unregisterOnDisabledChange(n){Fb(this._onDisabledChange,n)}_forEachChild(n){}_syncPendingControls(){return this.updateOn==="submit"&&(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),this._pendingChange)?(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),!0):!1}_applyFormState(n){Lb(n)?(this.value=this._pendingValue=n.value,n.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=n}};var wN={provide:qa,useExisting:Ft(()=>De)},Vb=Promise.resolve(),De=(()=>
vendor: 5,071 bytes, line 8
8{class e extends qa{_changeDetectorRef;callSetDisabledState;control=new SN;static ngAcceptInputType_isDisabled;_registered=!1;viewModel;name="";isDisabled;model;options;update=new je;constructor(t,i,o,r,c,u){super(),this._changeDetectorRef=c,this.callSetDisabledState=u,this._parent=t,this._setValidators(i),this._setAsyncValidators(o),this.valueAccessor=bN(this,r)}ngOnChanges(t){if(this._checkForErrors(),!this._registered||"name"in t){if(this._registered&&(this._checkName(),this.formDirective)){let i=t.name.previousValue;this.formDirective.removeControl({name:i,path:this._getPath(i)})}this._setUpControl()}"isDisabled"in t&&this._updateDisabled(t),_N(t,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(t){this.viewModel=t,this.update.emit(t)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!!(this.options&&this.options.standalone)}_setUpStandalone(){Yb(this.control,this,this.callSetDisabledState),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._checkName()}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),!this._isStandalone()&&this.name}_updateValue(t){Vb.then(()=>{this.control.setValue(t,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(t){let i=t.isDisabled.currentValue,o=i!==0&&lo(i);Vb.then(()=>{o&&!this.control.disabled?this.control.disable():!o&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(t){return this._parent?mN(t,this._parent):[t]}static \u0275fac=function(i){return new(i||e)(me(Cr,9),me(vr,10),me(Hb,10),me(_r,10),me(Qo,8),me(Vh,8))};static \u0275dir=Le({type:e,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"],options:[0,"ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],standalone:!1,features:[cn([wN]),bt,ct]})}return e})();var pt=(()=>{class e{static \u0275fac=function(i){return new(i||e)};static \u0275dir=Le({type:e,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""],standalone:!1})}return e})(),EN={provide:_r,useExisting:Ft(()=>jh),multi:!0},jh=(()=>{class e extends Ja{writeValue(t){let i=t??"";this.setProperty("value",i)}registerOnChange(t){this.onChange=i=>{t(i==""?null:parseFloat(i))}}static \u0275fac=(()=>{let t;return function(o){return(t||(t=Yt(e)))(o||e)}})();static \u0275dir=Le({type:e,selectors:[["input","type","number","formControlName",""],["input","type","number","formControl",""],["input","type","number","ngModel",""]],hostBindings:function(i,o){i&1&&M("input",function(c){return o.onChange(c.target.value)})("blur",function(){return o.onTouched()})},standalone:!1,features:[cn([EN]),bt]})}return e})();var MN={provide:_r,useExisting:Ft(()=>mn),multi:!0};function Xb(e,n){return e==null?`${n}`:(n&&typeof n=="object"&&(n="Object"),`${e}: ${n}`.slice(0,50))}function PN(e){return e.split(":")[0]}var mn=(()=>{class e extends Ja{value;_optionMap=new Map;_idCounter=0;set compareWith(t){this._compareWith=t}_compareWith=Object.is;writeValue(t){this.value=t;let i=this._getOptionId(t),o=Xb(i,t);this.setProperty("value",o)}registerOnChange(t){this.onChange=i=>{this.value=this._getOptionValue(i),t(this.value)}}_registerOption(){return(this._idCounter++).toString()}_getOptionId(t){for(let i of this._optionMap.keys())if(this._compareWith(this._optionMap.get(i),t))return i;return null}_getOptionValue(t){let i=PN(t);return this._optionMap.has(i)?this._optionMap.get(i):t}static \u0275fac=(()=>{let t;return function(o){return(t||(t=Yt(e)))(o||e)}})();static \u0275dir=Le({type:e,selectors:[["select","formControlName","",3,"multiple",""],["select","formControl","",3,"multiple",""],["select","ngModel","",3,"multiple",""]],hostBindings:function(i,o){i&1&&M("change",function(c){return o.onChange(c.target.value)})("blur",function(){return o.onTouched()})},inputs:{compareWith:"compareWith"},standalone:!1,features:[cn([MN]),bt]})}return e})(),zn=(()=>{class e{_element;_renderer;_select;id;constructor(t,i,o){this._element=t,this._renderer=i,this._select=o,this._select&&(this.id=this._select._registerOption())}set ngValue(t){this._select!=null&&(this._select._optionMap.set(this.id,t),this._setElementValue(Xb(this.id,t)),this._select.writeValue(this._select.value))}set value(t){this._setElementValue(t),this._select&&this._select.writeValue(this._select.value)}_setElementValue(t){this._renderer.setProperty(this._element.nativeElement,"value",t)}ngOnDestroy(){this._select&&(this._select._optionMap.delete(this.id
8),this._select.writeValue(this._select.value))}static \u0275fac=function(i){return new(i||e)(me(Lt),me(Ut),me(mn,9))};static \u0275dir=Le({type:e,selectors:[["option"]],inputs:{ngValue:"ngValue",value:"value"},standalone:!1})}return e})(),DN={provide:_r,useExisting:Ft(()=>e1),multi:!0};function Ub(e,n){return e==null?`${n}`:(typeof n=="string"&&(n=`'${n}'`),n&&typeof n=="object"&&(n="Object"),`${e}: ${n}`.slice(0,50))}function IN(e){return e.split(":")[0]}var e1=(()=>{class e extends Ja{value;_optionMap=new Map;_idCounter=0;set compareWith(t){this._compareWith=t}_compareWith=Object.is;writeValue(t){this.value=t;let i;if(Array.isArray(t)){let o=t.map(r=>this._getOptionId(r));i=(r,c)=>{r._setSelected(o.indexOf(c.toString())>-1)}}else i=(o,r)=>{o._setSelected(!1)};this._optionMap.forEach(i)}registerOnChange(t){this.onChange=i=>{let o=[],r=i.selectedOptions;if(r!==void 0){let c=r;for(let u=0;u<c.length;u++){let m=c[u],f=this._getOptionValue(m.value);o.push(f)}}else{let c=i.options;for(let u=0;u<c.length;u++){let m=c[u];if(m.selected){let f=this._getOptionValue(m.value);o.push(f)}}}this.value=o,t(o)}}_registerOption(t){let i=(this._idCounter++).toString();return this._optionMap.set(i,t),i}_getOptionId(t){for(let i of this._optionMap.keys())if(this._compareWith(this._optionMap.get(i)._value,t))return i;return null}_getOptionValue(t){let i=IN(t);return this._optionMap.has(i)?this._optionMap.get(i)._value:t}static \u0275fac=(()=>{let t;return function(o){return(t||(t=Yt(e)))(o||e)}})();static \u0275dir=Le({type:e,selectors:[["select","multiple","","formControlName",""],["select","multiple","","formControl",""],["select","multiple","","ngModel",""]],hostBindings:function(i,o){i&1&&M("change",function(c){return o.onChange(c.target)})("blur",function(){return o.onTouched()})},inputs:{compareWith:"compareWith"},standalone:!1,features:[cn([DN]),bt]})}return e})(),Gn=(()=>{class e{_element;_renderer;_select;id;_value;constructor(t,i,o){this._element=t,this._renderer=i,this._select=o,this._select&&(this.id=this._select._registerOption(this))}set ngValue(t){this._select!=null&&(this._value=t,this._setElementValue(Ub(this.id,t)),this._select.writeValue(this._select.value))}set value(t){this._select?(this._value=t,this._setElementValue(Ub(this.id,t)),this._select.writeValue(this._select.value)):this._setElementValue(t)}_setElementValue(t){this._renderer.setProperty(this._element.nativeElement,"value",t)}_setSelected(t){this._renderer.setProperty(this._element.nativeElement,"selected",t)}ngOnDestroy(){this._select&&(this._select._optionMap.delete(this.id),this._select.writeValue(this._select.value))}static \u0275fac=function(i){return new(i||e)(me(Lt),me(Ut),me(e1,9))};static \u0275dir=Le({type:e,selectors:[["option"]],inputs:{ngValue:"ngValue",value:"value"},standalone:!1})}return e})();function TN(e){return typeof e=="number"?e:parseInt(e,10)}function t1(e){return typeof e=="number"?e:parseFloat(e)}var id=(()=>{class e{_validator=Ob;_onChange;_enabled;ngOnChanges(t){if(this.inputName in t){let i=this.normalizeInput(t[this.inputName].currentValue);this._enabled=this.enabled(i),this._validator=this._enabled?this.createValidator(i):Ob,this._onChange&&this._onChange()}}validate(t){return this._validator(t)}registerOnValidatorChange(t){this._onChange=t}enabled(t){return t!=null}static \u0275fac=function(i){return new(i||e)};static \u0275dir=Le({type:e,features:[ct]})}return e})(),ON={provide:vr,useExisting:Ft(()=>Bh),multi:!0},Bh=(()=>{class e extends id{max;inputName="max";normalizeInput=t=>t1(t);createValidator=t=>XO(t);static \u0275fac=(()=>{let t;return function(o){return(t||(t=Yt(e)))(o||e)}})();static \u0275dir=Le({type:e,selectors:[["input","type","number","max","","formControlName",""],["input","type","number","max","","formControl",""],["input","type","number","max","","ngModel",""]],hostVars:1,hostBindings:function(i,o){i&2&&_e("max",o._enabled?o.max:null)},inputs:{max:"max"},standalone:!1,features:[cn([ON]),bt]})}return e})(),NN={provide:vr,useExisting:Ft(()=>Hh),multi:!0},Hh=(()=>{class e extends id{min;inputName="min";normalizeInput=t=>t1(t);createValidator=t=>QO(t);static \u0275fac=(()=>{let t;return function(o){return(t||(t=Yt(e)))(o||e)}})();static \u0275dir=Le({type:e,selectors:[["input","type","number","min","","formControlName",""],["input","type","number","min","","formControl",""],["input","type","number","min","","ngModel",""]],hostVars:1,hostBindings:function(i,o){i&2&&_e("min",o._enabled?o.min:null)},inputs:{min:"min"},standalone:!1,features:[cn([NN]),bt]})}return e})(),kN={provide:vr,useExisting:Ft(()=>Co),multi:!0};var Co=(()=>{class e extends id{required;inputName="required";normalizeInput=lo;createValidator=t=>eN;enabled(t){return t}static \u0275fac=(()=>{let t;return function(o){return(t||(t=Yt(e)))(o||e)}})();static \u0275dir=Le({type:e,selectors:[["","required","","formControlName","",3,"type","checkbox"],["","required","","formControl","",3,"type","checkbox"],["","required","","ngModel","",3,"type","checkbox"]],hostVars:1,hostBindings:function(i,o){i&2&&_e("required",o._enabled?"":null)},inputs:{required:"required"},standalone:!1,features:[cn([kN]),bt]})}return e})();var AN={provide:vr,useExisting:Ft(()=>fi),multi:!0},fi=(()=>{class e extends id{maxlength;inputName="maxlength";normalizeInput=t=>TN(t);createValidator=t=>tN(t);static \u0275fac=(()=>{let t;return function(o){return(t||(t=Yt(e)))(o||e)}})();static \u0275dir=Le({type:e,selectors:[["","maxlength","","formControlName",""],["","maxlength","","formControl",""],["","maxlength","","ngModel",""]],hostVars:1,hostBindings:function(i,o){i&2&&_e("maxlength",o._enabled?o.maxlength:null)},inputs:{maxlength:"maxlength"},standalone:!1,features:[cn([AN]),bt]})}return e})();var RN=(()=>{class e{static \u0275fac=function(i){return new(i||e)};static \u0275mod=Di({type:e});static \u0275inj=Ei({})}return e})();var ke=(()=>{class e{static withConfig(t){return{ngModule:e,providers:[{provide:Vh,useValue:t.callSetDisabledState??Uh}]}}static \u0275fac=function(i){return new(i||e)};static \u0275mod=Di({type:e});static \u0275inj=Ei({imports:[RN]})}return e})();function FN(e){return e&&e.charAt(0).toUpperCase()+e.slice(1)}var yr=class e{http=h(Z);getPlaceView(n){let t=`/api/place?id=${encodeURIComponent(n)}`;return this.http.get(t).pipe(N(i=>this.toPlaceView(i)))}toPlaceView(n){let t={id:String(n.geonameId),name:n.toponymName||n.name,asciiName:n.asciiName,path:new URL(n.url).pathname,featureClass:n.fcl,featureCode:n.fcode,featureLabel:FN(n.fcodeName),countryCode:n.countryCode,countryName:n.countryName,latitude:Number(n.lat),longitude:Number(n.lng),population:n.population||void 0,elevation:n.elevation,srtm3:n.srtm3,astergdem:n.astergdem,gtopo30:n.gtopo30,timezone:n.timezone?.timeZoneId,boundingBox:n.bbox?{north:n.bbox.north,south:n.bbox.south,east:n.bbox.east,west:n.bbox.west}:void 0,hasShape:n.hasShape==="true",adminCode1:n.adminCode1,adminCode2:n.adminCode2,adminCode3:n.adminCode3,adminCode4:n.adminCode4,adminCode5:n.adminCode5,cc2:n.cc2,wikipediaUrl:n.wikipediaURL},i=[],o=n.continentCode?Tb[n.continentCode]:void 0;o&&i.push({id:o.id,name:o.name,featureLabel:"Continent",featureClass:"L",featureCode:"CONT"}
8),n.countryId&&n.countryName&&i.push({id:n.countryId,name:n.countryName,featureLabel:"Country",code:n.countryCode,featureClass:"A"});let r=[[n.adminId1,n.adminName1,"First-order administrative division",n.adminCode1,"ADM1"],[n.adminId2,n.adminName2,"Second-order administrative division",n.adminCode2,"ADM2"],[n.adminId3,n.adminName3,"Third-order administrative division",n.adminCode3,"ADM3"],[n.adminId4,n.adminName4,"Fourth-order administrative division",n.adminCode4,"ADM4"],[n.adminId5,n.adminName5,"Fifth-order administrative division",n.adminCode5,"ADM5"]];for(let[c,u,m,f,C]of r)c&&u&&i.push({id:c,name:u,featureLabel:m,code:f,featureClass:"A",featureCode:C});return{place:t,ancestors:i.filter(c=>c.id!==t.id)}}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};function It(e){if(e.status&&e.status.value>0)throw new Error(e.status.message||"Request failed.")}function St(){return Ze(e=>{if(e instanceof en){let t=e.error?.status?.message;return zt(()=>new Error(t||e.message))}return zt(()=>e)})}var br=class e{http=h(Z);updateFeature(n){return this.http.post("/api/feature/update",n).pipe(N(t=>It(t)),St())}createFeature(n){return this.http.post("/api/feature/create",n).pipe(N(t=>(It(t),t)),St())}moveFeature(n,t,i){return this.http.post("/api/feature/move",{geonameId:n,lat:t,lng:i}).pipe(N(o=>It(o)),St())}deleteFeature(n,t){return this.http.post("/api/feature/delete",{geonameId:n,comment:t}).pipe(N(i=>It(i)),St())}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var od=class e{http=h(Z);getShape(n){let t=`/api/shape?geonameId=${encodeURIComponent(n)}`;return this.http.get(t).pipe(N(i=>i.shapes?.[0]?.geoJson??null))}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var rd=class e{http=h(Z);mapConfig$=this.http.get("/api/map-config").pipe(Xn(1));getMapConfig(){return this.mapConfig$}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};function LN(e){return e&&e.charAt(0).toUpperCase()+e.slice(1)}function VN(e){return[e.cn,e.admn1,e.admn2,e.admn3].filter(Boolean).join(" \xBB ")}var ad=class e{http=h(Z);getNearby(n){let t=new URLSearchParams({lat:String(n.lat),lng:String(n.lng),north:String(n.north),south:String(n.south),east:String(n.east),west:String(n.west)});return n.excludeId&&t.set("id",n.excludeId),n.classes&&t.set("classes",n.classes.join(",")),this.http.get(`/api/nearby-places?${t.toString()}`).pipe(N(i=>(i.markers??[]).map(o=>({id:o.id,name:o.name,path:new URL(o.url).pathname,latitude:Number(o.lat),longitude:Number(o.lng),featureClass:o.fc,featureCode:o.c,featureLabel:o.fcn?LN(o.fcn):void 0,population:o.population?Number(o.population):void 0,countryCode:o.cc,hasShape:o.hasShape==="true",wikipediaUrl:o.wikipediaURL||void 0,elevation:o.elevation?Number(o.elevation):void 0,srtm3:o.srtm3?Number(o.srtm3):void 0,gtopo30:o.gtopo30?Number(o.gtopo30):void 0,breadcrumb:VN(o)||void 0}))))}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var sd=class e{http=h(Z);getArticles(n){let t=new URLSearchParams({lang:n.lang,north:String(n.north),south:String(n.south),east:String(n.east),west:String(n.west)});return this.http.get(`/api/wikipedia-layer?${t.toString()}`).pipe(N(i=>(i.geonames??[]).map(o=>({title:o.title,summary:o.summary,latitude:o.lat,longitude:o.lng,countryCode:o.countryCode,lang:o.lang,wikipediaUrl:o.wikipediaUrl,thumbnailImg:o.thumbnailImg,feature:o.feature,geoNameId:o.geoNameId}))))}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var ld=class e{http=h(Z);getPostalCodes(n){let t=new URLSearchParams({lat:String(n.lat),lng:String(n.lng),radius:String(n.radius),maxRows:String(n.maxRows??200)});return n.isReduced&&t.set("isReduced","true"),this.http.get(`/api/postal-codes-layer?${t.toString()}`).pipe(N(i=>(i.postalCodes??[]).map(o=>({postalCode:o.postalCode,placeName:o.placeName,latitude:o.lat,longitude:o.lng,countryCode:o.countryCode,adminName1:o.adminName1,adminName2:o.adminName2,postalCodeId:o.postalCodeId}))))}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var Wn=class e{http=h(Z);reverse(n,t){let i=new URLSearchParams({lat:String(n),lng:String(t)});return this.http.get(`/api/address/reverse?${i.toString()}`).pipe(N(o=>o.address??null))}reverseUS(n,t){let i=new URLSearchParams({lat:String(n),lng:String(t)});return this.http.get(`/api/address/nearest-us?${i.toString()}`).pipe(N(o=>
8{if(!o.address)return null;let u=o.address,{streetNumber:r}=u,c=is(u,["streetNumber"]);return oe(U({},c),{houseNumber:r})}))}geocode(n,t,i){let o=new URLSearchParams({q:n});return t&&o.set("country",t),i&&o.set("postalcode",i),this.http.get(`/api/address/geocode?${o.toString()}`).pipe(N(r=>r.address??null))}streetNameLookup(n,t){let i=new URLSearchParams({q:n});return t&&i.set("country",t),this.http.get(`/api/address/streets?${i.toString()}`).pipe(N(o=>o.streetNames??[]))}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var cd=class e{http=h(Z);nearbyStreets(n,t){let i=new URLSearchParams({lat:String(n),lng:String(t)});return this.http.get(`/api/address/nearby-streets-osm?${i.toString()}`).pipe(N(o=>o.streetSegment??[]))}nearestIntersection(n,t){let i=new URLSearchParams({lat:String(n),lng:String(t)});return this.http.get(`/api/address/nearest-intersection-osm?${i.toString()}`).pipe(N(o=>o.intersection??null))}nearbyPois(n,t){let i=new URLSearchParams({lat:String(n),lng:String(t)});return this.http.get(`/api/address/nearby-pois-osm?${i.toString()}`).pipe(N(o=>o.poi??[]))}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var qn=[{code:"A",name:"country, state, region"},{code:"H",name:"stream, lake"},{code:"L",name:"parks, area"},{code:"P",name:"city, village"},{code:"R",name:"road, railroad"},{code:"S",name:"spot, building, farm"},{code:"T",name:"mountain, hill, rock"},{code:"U",name:"undersea"},{code:"V",name:"forest, heath"}],Dn={A:{background:"#CA0000",color:"#fff"},H:{background:"#6E6CF2",color:"#fff"},L:{background:"#00F2AE",color:"#fff"},P:{background:"#F2F2F2",color:"#434343"},R:{background:"#F2DE3F",color:"#fff"},S:{background:"#C23FF2",color:"#fff"},T:{background:"#FF776B",color:"#fff"},U:{background:"#777777",color:"#fff"},V:{background:"#5AF23F",color:"#fff"}},hi={A:[{code:"ADM1",name:"first-order administrative division"},{code:"ADM1H",name:"historical first-order administrative division"},{code:"ADM2",name:"second-order administrative division"},{code:"ADM2H",name:"historical second-order administrative division"},{code:"ADM3",name:"third-order administrative division"},{code:"ADM3H",name:"historical third-order administrative division"},{code:"ADM4",name:"fourth-order administrative division"},{code:"ADM4H",name:"historical fourth-order administrative division"},{code:"ADM5",name:"fifth-order administrative division"},{code:"ADM5H",name:"historical fifth-order administrative division"},{code:"ADMD",name:"administrative division"},{code:"ADMDH",name:"historical administrative division"},{code:"ADMS",name:"school district"},{code:"LTER",name:"leased area"},{code:"PCL",name:"political entity"},{code:"PCLD",name:"dependent political entity"},{code:"PCLF",name:"freely associated state"},{code:"PCLH",name:"historical political entity"},{code:"PCLI",name:"independent political entity"},{code:"PCLIX",name:"section of independent political entity"},{code:"PCLS",name:"semi-independent political entity"},{code:"PRSH",name:"parish"},{code:"TERR",name:"territory"},{code:"ZN",name:"zone"},{code:"ZNB",name:"buffer zone"}],H:[{code:"AIRS",name:"seaplane landing area"},{code:"ANCH",name:"anchorage"},{code:"BAY",name:"bay"},{code:"BAYS",name:"bays"},{code:"BGHT",name:"bight(s)"},{code:"BNK",name:"bank(s)"},{code:"BNKR",name:"stream bank"},{code:"BNKX",name:"section of bank"},{code:"BOG",name:"bog(s)"},{code:"CAPG",name:"icecap"},{code:"CHN",name:"channel"},{code:"CHNL",name:"lake channel(s)"},{code:"CHNM",name:"marine channel"},{code:"CHNN",name:"navigation channel"},{code:"CNFL",name:"confluence"},{code:"CNL",name:"canal"},{code:"CNLA",name:"aqueduct"},{code:"CNLB",name:"canal bend"},{code:"CNLD",name:"drainage canal"},{code:"CNLI",name:"irrigation canal"},{code:"CNLN",name:"navigation canal(s)"},{code:"CNLQ",name:"abandoned canal"},{code:"CNLSB",name:"underground irrigation canal(s)"},{code:"CNLX",name:"section of canal"},{code:"COVE",name:"cove(s)"},{code:"CRKT",name:"tidal creek(s)"}
8,{code:"CRNT",name:"current"},{code:"CUTF",name:"cutoff"},{code:"DCK",name:"dock(s)"},{code:"DCKB",name:"docking basin"},{code:"DOMG",name:"icecap dome"},{code:"DPRG",name:"icecap depression"},{code:"DTCH",name:"ditch"},{code:"DTCHD",name:"drainage ditch"},{code:"DTCHI",name:"irrigation ditch"},{code:"DTCHM",name:"ditch mouth(s)"},{code:"ESTY",name:"estuary"},{code:"FISH",name:"fishing area"},{code:"FJD",name:"fjord"},{code:"FJDS",name:"fjords"},{code:"FLLS",name:"waterfall(s)"},{code:"FLLSX",name:"section of waterfall(s)"},{code:"FLTM",name:"mud flat(s)"},{code:"FLTT",name:"tidal flat(s)"},{code:"GLCR",name:"glacier(s)"},{code:"GULF",name:"gulf"},{code:"GYSR",name:"geyser"},{code:"HBR",name:"harbor(s)"},{code:"HBRX",name:"section of harbor"},{code:"INLT",name:"inlet"},{code:"INLTQ",name:"former inlet"},{code:"LBED",name:"lake bed(s)"},{code:"LGN",name:"lagoon"},{code:"LGNS",name:"lagoons"},{code:"LGNX",name:"section of lagoon"},{code:"LK",name:"lake"},{code:"LKC",name:"crater lake"},{code:"LKI",name:"intermittent lake"},{code:"LKN",name:"salt lake"},{code:"LKNI",name:"intermittent salt lake"},{code:"LKO",name:"oxbow lake"},{code:"LKOI",name:"intermittent oxbow lake"},{code:"LKS",name:"lakes"},{code:"LKSB",name:"underground lake"},{code:"LKSC",name:"crater lakes"},{code:"LKSI",name:"intermittent lakes"},{code:"LKSN",name:"salt lakes"},{code:"LKSNI",name:"intermittent salt lakes"},{code:"LKX",name:"section of lake"},{code:"MFGN",name:"salt evaporation ponds"},{code:"MGV",name:"mangrove swamp"},{code:"MOOR",name:"moor(s)"},{code:"MRSH",name:"marsh(es)"},{code:"MRSHN",name:"salt marsh"},{code:"NRWS",name:"narrows"},{code:"OCN",name:"ocean"},{code:"OVF",name:"overfalls"},{code:"PND",name:"pond"},{code:"PNDI",name:"intermittent pond"},{code:"PNDN",name:"salt pond"},{code:"PNDNI",name:"intermittent salt pond(s)"},{code:"PNDS",name:"ponds"},{code:"PNDSF",name:"fishponds"},{code:"PNDSI",name:"intermittent ponds"},{code:"PNDSN",name:"salt ponds"},{code:"POOL",name:"pool(s)"},{code:"POOLI",name:"intermittent pool"},{code:"RCH",name:"reach"},{code:"RDGG",name:"icecap ridge"},{code:"RDST",name:"roadstead"},{code:"RF",name:"reef(s)"},{code:"RFC",name:"coral reef(s)"},{code:"RFX",name:"section of reef"},{code:"RPDS",name:"rapids"},{code:"RSV",name:"reservoir(s)"},{code:"RSVI",name:"intermittent reservoir"}
8,{code:"RSVT",name:"water tank"},{code:"RVN",name:"ravine(s)"},{code:"SBKH",name:"sabkha(s)"},{code:"SD",name:"sound"},{code:"SEA",name:"sea"},{code:"SHOL",name:"shoal(s)"},{code:"SILL",name:"sill"},{code:"SPNG",name:"spring(s)"},{code:"SPNS",name:"sulphur spring(s)"},{code:"SPNT",name:"hot spring(s)"},{code:"STM",name:"stream"},{code:"STMA",name:"anabranch"},{code:"STMB",name:"stream bend"},{code:"STMC",name:"canalized stream"},{code:"STMD",name:"distributary(-ies)"},{code:"STMH",name:"headwaters"},{code:"STMI",name:"intermittent stream"},{code:"STMIX",name:"section of intermittent stream"},{code:"STMM",name:"stream mouth(s)"},{code:"STMQ",name:"abandoned watercourse"},{code:"STMS",name:"streams"},{code:"STMSB",name:"lost river"},{code:"STMX",name:"section of stream"},{code:"STRT",name:"strait"},{code:"SWMP",name:"swamp"},{code:"SYSI",name:"irrigation system"},{code:"TNLC",name:"canal tunnel"},{code:"WAD",name:"wadi"},{code:"WADB",name:"wadi bend"},{code:"WADJ",name:"wadi junction"},{code:"WADM",name:"wadi mouth"},{code:"WADS",name:"wadies"},{code:"WADX",name:"section of wadi"},{code:"WHRL",name:"whirlpool"},{code:"WLL",name:"well"},{code:"WLLQ",name:"abandoned well"},{code:"WLLS",name:"wells"},{code:"WTLD",name:"wetland"},{code:"WTLDI",name:"intermittent wetland"},{code:"WTRC",name:"watercourse"},{code:"WTRH",name:"waterhole(s)"}],L:[{code:"AGRC",name:"agricultural colony"},{code:"AMUS",name:"amusement park"},{code:"AREA",name:"area"},{code:"BSND",name:"drainage basin"},{code:"BSNP",name:"petroleum basin"},{code:"BTL",name:"battlefield"},{code:"CLG",name:"clearing"},{code:"CMN",name:"common"},{code:"CNS",name:"concession area"},{code:"COLF",name:"coalfield"},{code:"CONT",name:"continent"},{code:"CST",name:"coast"},{code:"CTRB",name:"business center"},{code:"DEVH",name:"housing development"},{code:"FLD",name:"field(s)"},{code:"FLDI",name:"irrigated field(s)"},{code:"GASF",name:"gasfield"},{code:"GRAZ",name:"grazing area"},{code:"GVL",name:"gravel area"},{code:"INDS",name:"industrial area"},{code:"LAND",name:"arctic land"},{code:"LCTY",name:"locality"},{code:"MILB",name:"military base"},{code:"MNA",name:"mining area"},{code:"MVA",name:"maneuver area"},{code:"NVB",name:"naval base"},{code:"OAS",name:"oasis(-es)"},{code:"OILF",name:"oilfield"},{code:"PEAT",name:"peat cutting area"},{code:"PRK",name:"park"},{code:"PRT",name:"port"},{code:"QCKS",name:"quicksand"},{code:"RES",name:"reserve"},{code:"RESA",name:"agricultural reserve"},{code:"RESF",name:"forest reserve"},{code:"RESH",name:"hunting reserve"},{code:"RESN",name:"nature reserve"},{code:"RESP",name:"palm tree reserve"},{code:"RESV",name:"reservation"},{code:"RESW",name:"wildlife reserve"},{code:"RGN",name:"region"},{code:"RGNE",name:"economic region"},{code:"RGNH",name:"historical region"},{code:"RGNL",name:"lake region"},{code:"RNGA",name:"artillery range"},{code:"SALT",name:"salt area"},{code:"SNOW",name:"snowfield"},{code:"TRB",name:"tribal area"}],P:[{code:"PPL",name:"populated place"},{code:"PPLA",name:"seat of a first-order administrative division"},{code:"PPLA2",name:"seat of a second-order administrative division"},{code:"PPLA3",name:"seat of a third-order administrative division"},{code:"PPLA4",name:"seat of a fourth-order administrative division"},{code:"PPLA5",name:"seat of a fifth-order administrative division"},{code:"PPLC",name:"capital of a political entity"},{code:"PPLCD",name:"capital of a dependency or special area"},{code:"PPLCH",name:"historical capital of a political entity"},{code:"PPLF",name:"farm village"},{code:"PPLG",name:"seat of government of a political entity"},{code:"PPLH",name:"historical populated place"},{code:"PPLL",name:"populated locality"},{code:"PPLQ",name:"abandoned populated place"},{code:"PPLR",name:"religious populated place"},{code:"PPLS",name:"populated places"},{code:"PPLW",name:"destroyed populated place"},{code:"PPLX",name:"section of populated place"},{code:"STLMT",name:"israeli settlement"}],R:[{code:"CSWY",name:"causeway"},{code:"OILP",name:"oil pipeline"},{code:"PRMN",name:"promenade"},{code:"PTGE",name:"portage"},{code:"RD",name:"road"},{code:"RDA",name:"ancient road"},{code:"RDB",name:"road bend"},{code:"RDCUT",name:"road cut"},{code:"RDJCT",name:"road junction"},{code:"RJCT",name:"railroad junction"},{code:"RR",name:"railroad"},{code:"RRQ",name:"abandoned railroad"},{code:"RTE",name:"caravan route"},{code:"RYD",name:"railroad yard"},{code:"ST",name:"street"},{code:"STKR",name:"stock route"},{code:"TNL",name:"tunnel"},{code:"TNLN",name:"natural tunnel"},{code:"TNLRD",name:"road tunnel"},{code:"TNLRR",name:"railroad tunnel"},{code:"TNLS",name:"tunnels"},{code:"TRL",name:"trail"}
8],S:[{code:"ADMF",name:"administrative facility"},{code:"AGRF",name:"agricultural facility"},{code:"AIRB",name:"airbase"},{code:"AIRF",name:"airfield"},{code:"AIRH",name:"heliport"},{code:"AIRP",name:"airport"},{code:"AIRQ",name:"abandoned airfield"},{code:"AIRT",name:"terminal"},{code:"AMTH",name:"amphitheater"},{code:"ANS",name:"archaeological/prehistoric site"},{code:"AQC",name:"aquaculture facility"},{code:"ARCH",name:"arch"},{code:"ARCHV",name:"archive"},{code:"ART",name:"piece of art"},{code:"ASTR",name:"astronomical station"},{code:"ASYL",name:"asylum"},{code:"ATHF",name:"athletic field"},{code:"ATM",name:"automatic teller machine"},{code:"BANK",name:"bank"},{code:"BCN",name:"beacon"},{code:"BDG",name:"bridge"},{code:"BDGQ",name:"ruined bridge"},{code:"BLDA",name:"apartment building"},{code:"BLDG",name:"building(s)"},{code:"BLDO",name:"office building"},{code:"BP",name:"boundary marker"},{code:"BRKS",name:"barracks"},{code:"BRKW",name:"breakwater"},{code:"BSTN",name:"baling station"},{code:"BTYD",name:"boatyard"},{code:"BUR",name:"burial cave(s)"},{code:"BUSTN",name:"bus station"},{code:"BUSTP",name:"bus stop"},{code:"CARN",name:"cairn"},{code:"CAVE",name:"cave(s)"},{code:"CH",name:"church"},{code:"CMP",name:"camp(s)"},{code:"CMPL",name:"logging camp"},{code:"CMPLA",name:"labor camp"},{code:"CMPMN",name:"mining camp"},{code:"CMPO",name:"oil camp"},{code:"CMPQ",name:"abandoned camp"},{code:"CMPRF",name:"refugee camp"},{code:"CMTY",name:"cemetery"},{code:"COMC",name:"communication center"},{code:"CRRL",name:"corral(s)"},{code:"CSNO",name:"casino"},{code:"CSTL",name:"castle"},{code:"CSTM",name:"customs house"},{code:"CTHSE",name:"courthouse"},{code:"CTRA",name:"atomic center"},{code:"CTRCM",name:"community center"},{code:"CTRF",name:"facility center"},{code:"CTRM",name:"medical center"},{code:"CTRR",name:"religious center"},{code:"CTRS",name:"space center"},{code:"CTYD",name:"courtyard"},{code:"CVNT",name:"convent"},{code:"DAM",name:"dam"},{code:"DAMQ",name:"ruined dam"},{code:"DAMSB",name:"sub-surface dam"},{code:"DARY",name:"dairy"},{code:"DCKD",name:"dry dock"},{code:"DCKY",name:"dockyard"},{code:"DIKE",name:"dike"},{code:"DIP",name:"diplomatic facility"},{code:"DPOF",name:"fuel depot"},{code:"EST",name:"estate(s)"},{code:"ESTO",name:"oil palm plantation"},{code:"ESTR",name:"rubber plantation"},{code:"ESTSG",name:"sugar plantation"},{code:"ESTT",name:"tea plantation"},{code:"ESTX",name:"section of estate"},{code:"FCL",name:"facility"},{code:"FIRE",name:"fire station"},{code:"FNDY",name:"foundry"},{code:"FRM",name:"farm"},{code:"FRMQ",name:"abandoned farm"},{code:"FRMS",name:"farms"},{code:"FRMT",name:"farmstead"},{code:"FT",name:"fort"},{code:"FY",name:"ferry"},{code:"FYT",name:"ferry terminal"},{code:"GATE",name:"gate"},{code:"GDN",name:"garden(s)"},{code:"GHAT",name:"ghat"},{code:"GHSE",name:"guest house"},{code:"GOSP",name:"gas-oil separator plant"},{code:"GOVL",name:"local government office"},{code:"GRVE",name:"grave"},{code:"HERM",name:"hermitage"},{code:"HLT",name:"halting place"},{code:"HMSD",name:"homestead"},{code:"HSE",name:"house(s)"},{code:"HSEC",name:"country house"},{code:"HSP",name:"hospital"},{code:"HSPC",name:"clinic"},{code:"HSPD",name:"dispensary"},{code:"HSPL",name:"leprosarium"},{code:"HSTS",name:"historical site"},{code:"HTL",name:"hotel"},{code:"HUT",name:"hut"},{code:"HUTS",name:"huts"},{code:"INSM",name:"military installation"},{code:"ITTR",name:"research institute"},{code:"JTY",name:"jetty"},{code:"LDNG",name:"landing"},{code:"LEPC",name:"leper colony"},{code:"LIBR",name:"library"},{code:"LNDF",name:"landfill"},{code:"LOCK",name:"lock(s)"},{code:"LTHSE",name:"lighthouse"},{code:"MALL",name:"mall"},{code:"MAR",name:"marina"},{code:"MFG",name:"factory"},{code:"MFGB",name:"brewery"},{code:"MFGC",name:"cannery"},{code:"MFGCU",name:"copper works"},{code:"MFGLM",name:"limekiln"},{code:"MFGM",name:"munitions plant"},{code:"MFGPH",name:"phosphate works"},{code:"MFGQ",name:"abandoned factory"},{code:"MFGSG",name:"sugar refinery"},{code:"MKT",name:"market"},{code:"ML",name:"mill(s)"},{code:"MLM",name:"ore treatment plant"},{code:"MLO",name:"olive oil mill"},{code:"MLSG",name:"sugar mill"},{code:"MLSGQ",name:"former sugar mill"},{code:"MLSW",name:"sawmill"},{code:"MLWND",name:"windmill"},{code:"MLWTR",name:"water mill"},{code:"MN",name:"mine(s)"},{code:"MNAU",name:"gold mine(s)"},{code:"MNC",name:"coal mine(s)"},{code:"MNCR",name:"chrome mine(s)"},{code:"MNCU",name:"copper mine(s)"},{code:"MNFE",name:"iron mine(s)"},{code:"MNMT",name:"monument"},{code:"MNN",name:"salt mine(s)"},{code:"MNQ",name:"abandoned mine"}
8,{code:"MNQR",name:"quarry(-ies)"},{code:"MOLE",name:"mole"},{code:"MSQE",name:"mosque"},{code:"MSSN",name:"mission"},{code:"MSSNQ",name:"abandoned mission"},{code:"MSTY",name:"monastery"},{code:"MTRO",name:"metro station"},{code:"MUS",name:"museum"},{code:"NOV",name:"novitiate"},{code:"NSY",name:"nursery(-ies)"},{code:"OBPT",name:"observation point"},{code:"OBS",name:"observatory"},{code:"OBSR",name:"radio observatory"},{code:"OILJ",name:"oil pipeline junction"},{code:"OILQ",name:"abandoned oil well"},{code:"OILR",name:"oil refinery"},{code:"OILT",name:"tank farm"},{code:"OILW",name:"oil well"},{code:"OPRA",name:"opera house"},{code:"PAL",name:"palace"},{code:"PGDA",name:"pagoda"},{code:"PIER",name:"pier"},{code:"PKLT",name:"parking lot"},{code:"PMPO",name:"oil pumping station"},{code:"PMPW",name:"water pumping station"},{code:"PO",name:"post office"},{code:"PP",name:"police post"},{code:"PPQ",name:"abandoned police post"},{code:"PRKGT",name:"park gate"},{code:"PRKHQ",name:"park headquarters"},{code:"PRN",name:"prison"},{code:"PRNJ",name:"reformatory"},{code:"PRNQ",name:"abandoned prison"},{code:"PS",name:"power station"},{code:"PSH",name:"hydroelectric power station"},{code:"PSN",name:"nuclear power station"},{code:"PSTB",name:"border post"},{code:"PSTC",name:"customs post"},{code:"PSTP",name:"patrol post"},{code:"PYR",name:"pyramid"},{code:"PYRS",name:"pyramids"},{code:"QUAY",name:"quay"},{code:"RDCR",name:"traffic circle"},{code:"RDIN",name:"intersection"},{code:"RECG",name:"golf course"},{code:"RECR",name:"racetrack"},{code:"REST",name:"restaurant"},{code:"RET",name:"store"},{code:"RHSE",name:"resthouse"},{code:"RKRY",name:"rookery"},{code:"RLG",name:"religious site"},{code:"RLGR",name:"retreat"},{code:"RNCH",name:"ranch(es)"},{code:"RSD",name:"railroad siding"},{code:"RSGNL",name:"railroad signal"},{code:"RSRT",name:"resort"},{code:"RSTN",name:"railroad station"},{code:"RSTNQ",name:"abandoned railroad station"},{code:"RSTP",name:"railroad stop"},{code:"RSTPQ",name:"abandoned railroad stop"},{code:"RUIN",name:"ruin(s)"},{code:"SCH",name:"school"},{code:"SCHA",name:"agricultural school"},{code:"SCHC",name:"college"},{code:"SCHL",name:"language school"},{code:"SCHM",name:"military school"},{code:"SCHN",name:"maritime school"},{code:"SCHT",name:"technical school"},{code:"SECP",name:"State Exam Prep Centre"},{code:"SHPF",name:"sheepfold"},{code:"SHRN",name:"shrine"},{code:"SHSE",name:"storehouse"},{code:"SLCE",name:"sluice"},{code:"SNTR",name:"sanatorium"},{code:"SPA",name:"spa"},{code:"SPLY",name:"spillway"},{code:"SQR",name:"square"},{code:"STBL",name:"stable"},{code:"STDM",name:"stadium"},{code:"STNB",name:"scientific research base"},{code:"STNC",name:"coast guard station"},{code:"STNE",name:"experiment station"},{code:"STNF",name:"forest station"},{code:"STNI",name:"inspection station"},{code:"STNM",name:"meteorological station"},{code:"STNR",name:"radio station"},{code:"STNS",name:"satellite station"},{code:"STNW",name:"whaling station"},{code:"STPS",name:"steps"},{code:"SWT",name:"sewage treatment plant"},{code:"SYG",name:"synagogue"},{code:"THTR",name:"theater"},{code:"TMB",name:"tomb(s)"},{code:"TMPL",name:"temple(s)"},{code:"TNKD",name:"cattle dipping tank"},{code:"TOLL",name:"toll gate/barrier"},{code:"TOWR",name:"tower"},{code:"TRAM",name:"tram"},{code:"TRANT",name:"transit terminal"},{code:"TRIG",name:"triangulation station"},{code:"TRMO",name:"oil pipeline terminal"},{code:"TWO",name:"temp work office"},{code:"UNIP",name:"university prep school"},{code:"UNIV",name:"university"},{code:"USGE",name:"united states government establishment"},{code:"VETF",name:"veterinary facility"},{code:"WALL",name:"wall"},{code:"WALLA",name:"ancient wall"},{code:"WEIR",name:"weir(s)"},{code:"WHRF",name:"wharf(-ves)"},{code:"WRCK",name:"wreck"},{code:"WTRW",name:"waterworks"},{code:"ZNF",name:"free trade zone"},{code:"ZOO",name:"zoo"}],T:[{code:"ASPH",name:"asphalt lake"},{code:"ATOL",name:"atoll(s)"},{code:"BAR",name:"bar"},{code:"BCH",name:"beach"},{code:"BCHS",name:"beaches"},{code:"BDLD",name:"badlands"},{code:"BLDR",name:"boulder field"},{code:"BLHL",name:"blowhole(s)"},{code:"BLOW",name:"blowout(s)"},{code:"BNCH",name:"bench"},{code:"BUTE",name:"butte(s)"},{code:"CAPE",name:"cape"},{code:"CFT",name:"cleft(s)"},{code:"CLDA",name:"caldera"},{code:"CLF",name:"cliff(s)"},{code:"CNYN",name:"canyon"},{code:"CONE",name:"cone(s)"},{code:"CRDR",name:"corridor"},{code:"CRQ",name:"cirque"},{code:"CRQS",name:"cirques"},{code:"CRTR",name:"crater(s)"},{code:"CUET",name:"cuesta(s)"},{code:"DLTA",name:"delta"},{code:"DPR",name:"depression(s)"},{code:"DSRT",name:"desert"},{code:"DUNE",name:"dune(s)"},{code:"DVD",name:"divide"},{code:"ERG",name:"sandy desert"},{code:"FAN",name:"fan(s)"},{code:"FORD",name:"ford"},{code:"FSR",name:"fissure"},{code:"GAP",name:"gap"},{code:"GRGE",name:"gorge(s)"},{code:"HDLD",name:"headland"},{code:"HLL",name:"hill"},{code:"HLLS",name:"hills"},{code:"HMCK",name:"hammock(s)"},{code:"HMDA",name:"rock desert"},{code:"INTF",name:"interfluve"},{code:"ISL",name:"island"},{code:"ISLET",name:"islet"},{code:"ISLF",name:"artificial island"},{code:"ISLM",name:"mangrove island"},{code:"ISLS",name:"islands"},{code:"ISLT",name:"land-tied island"},{code:"ISLX",name:"section of island"},{code:"ISTH",name:"isthmus"}
8,{code:"KRST",name:"karst area"},{code:"LAVA",name:"lava area"},{code:"LEV",name:"levee"},{code:"MESA",name:"mesa(s)"},{code:"MND",name:"mound(s)"},{code:"MRN",name:"moraine"},{code:"MT",name:"mountain"},{code:"MTS",name:"mountains"},{code:"NKM",name:"meander neck"},{code:"NTK",name:"nunatak"},{code:"NTKS",name:"nunataks"},{code:"PAN",name:"pan"},{code:"PANS",name:"pans"},{code:"PASS",name:"pass"},{code:"PEN",name:"peninsula"},{code:"PENX",name:"section of peninsula"},{code:"PK",name:"peak"},{code:"PKS",name:"peaks"},{code:"PLAT",name:"plateau"},{code:"PLATX",name:"section of plateau"},{code:"PLDR",name:"polder"},{code:"PLN",name:"plain(s)"},{code:"PLNX",name:"section of plain"},{code:"PROM",name:"promontory(-ies)"},{code:"PT",name:"point"},{code:"PTS",name:"points"},{code:"RDGB",name:"beach ridge"},{code:"RDGE",name:"ridge(s)"},{code:"REG",name:"stony desert"},{code:"RK",name:"rock"},{code:"RKFL",name:"rockfall"},{code:"RKS",name:"rocks"},{code:"SAND",name:"sand area"},{code:"SBED",name:"dry stream bed"},{code:"SCRP",name:"escarpment"},{code:"SDL",name:"saddle"},{code:"SHOR",name:"shore"},{code:"SINK",name:"sinkhole"},{code:"SLID",name:"slide"},{code:"SLP",name:"slope(s)"},{code:"SPIT",name:"spit"},{code:"SPUR",name:"spur(s)"},{code:"TAL",name:"talus slope"},{code:"TRGD",name:"interdune trough(s)"},{code:"TRR",name:"terrace"},{code:"UPLD",name:"upland"},{code:"VAL",name:"valley"},{code:"VALG",name:"hanging valley"},{code:"VALS",name:"valleys"},{code:"VALX",name:"section of valley"},{code:"VLC",name:"volcano"}],U:[{code:"APNU",name:"apron"},{code:"ARCU",name:"arch"},{code:"ARRU",name:"arrugado"},{code:"BDLU",name:"borderland"},{code:"BKSU",name:"banks"},{code:"BNKU",name:"bank"},{code:"BSNU",name:"basin"},{code:"CDAU",name:"cordillera"},{code:"CNSU",name:"canyons"},{code:"CNYU",name:"canyon"},{code:"CRSU",name:"continental rise"},{code:"DEPU",name:"deep"},{code:"EDGU",name:"shelf edge"},{code:"ESCU",name:"escarpment (or scarp)"},{code:"FANU",name:"fan"},{code:"FLTU",name:"flat"},{code:"FRZU",name:"fracture zone"},{code:"FURU",name:"furrow"},{code:"GAPU",name:"gap"},{code:"GLYU",name:"gully"},{code:"HLLU",name:"hill"},{code:"HLSU",name:"hills"},{code:"HOLU",name:"hole"},{code:"KNLU",name:"knoll"},{code:"KNSU",name:"knolls"},{code:"LDGU",name:"ledge"},{code:"LEVU",name:"levee"},{code:"MESU",name:"mesa"},{code:"MNDU",name:"mound"},{code:"MOTU",name:"moat"},{code:"MTU",name:"mountain"},{code:"PKSU",name:"peaks"},{code:"PKU",name:"peak"},{code:"PLNU",name:"plain"},{code:"PLTU",name:"plateau"},{code:"PNLU",name:"pinnacle"},{code:"PRVU",name:"province"},{code:"RDGU",name:"ridge"},{code:"RDSU",name:"ridges"},{code:"RFSU",name:"reefs"},{code:"RFU",name:"reef"},{code:"RISU",name:"rise"},{code:"SCNU",name:"seachannel"},{code:"SCSU",name:"seachannels"},{code:"SDLU",name:"saddle"},{code:"SHFU",name:"shelf"},{code:"SHLU",name:"shoal"},{code:"SHSU",name:"shoals"},{code:"SHVU",name:"shelf valley"},{code:"SILU",name:"sill"},{code:"SLPU",name:"slope"},{code:"SMSU",name:"seamounts"},{code:"SMU",name:"seamount"},{code:"SPRU",name:"spur"},{code:"TERU",name:"terrace"},{code:"TMSU",name:"tablemounts (or guyots)"},{code:"TMTU",name:"tablemount (or guyot)"},{code:"TNGU",name:"tongue"},{code:"TRGU",name:"trough"},{code:"TRNU",name:"trench"},{code:"VALU",name:"valley"},{code:"VLSU",name:"valleys"}],V:[{code:"BUSH",name:"bush(es)"},{code:"CULT",name:"cultivated area"},{code:"FRST",name:"forest(s)"},{code:"FRSTF",name:"fossilized forest"},{code:"GROVE",name:"grove"},{code:"GRSLD",name:"grassland"},{code:"GRVC",name:"coconut grove"},{code:"GRVO",name:"olive grove"},{code:"GRVP",name:"palm grove"},{code:"GRVPN",name:"pine grove"},{code:"HTH",name:"heath"},{code:"MDW",name:"meadow"},{code:"OCH",name:"orchard(s)"},{code:"SCRB",name:"scrubland"},{code:"TREE",name:"tree(s)"},{code:"TUND",name:"tundra"},{code:"VIN",name:"vineyard"},{code:"VINS",name:"vineyards"}]};var Fi=class e{http=h(Z);timezoneIds$=this.http.get("/api/timezones").pipe(N(n=>(n.timezones??[]).map(t=>t.timezoneId)),Xn(1));getTimezoneIds(){return this.timezoneIds$}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};function $h(e,n,t,i){let o=f=>f*Math.PI/180,r=o(t-e),c=o(i-n),u=Math.sin(r/2)**2+Math.cos(o(e))*Math.cos(o(t))*Math.sin(c/2)**2;return 6371*(2*Math.atan2(Math.sqrt(u),Math.sqrt(1-u)))}function dd(e){return e<1?`${Math.round(e*1e3)} m`:`${e.toFixed(e<10?2:1)} km`}var UN=new Set([-32768,-9999]);function _o(e){return e==null||UN.has(e)?void 0:e}function ud(e){if(e.elevation!=null)return`${e.elevation} m`;let n=_o(e.srtm3)??_o(e.astergdem)??_o(e.gtopo30);return n!=null?`ca. ${n} m`:null}var jN=["mapHost"],BN=["mapWrap"],xr=(e,n)=>n.code;function HN(e,n){if(e&1){let t=$();l(0,"button",5),M("click",function(){S(t);let o=p();return w(o.toggleCreateArmed())}),s(1),a()}if(e&2){let t=p();pe("armed",t.createArmed()),d(),A(" ",t.createArmed()?"Click the map to place\u2026":"+ Add place here"," ")}}function $N(e,n){if(e&1){let t=$();l(0,"div",27)(1,"label",28)(2,"input",29),M("change",function(){let o=S(t).$implicit,r=p(4);return w(r.toggleCodeFilter(o.code))}),a(),l(3,"span",30),s(4),a(),l(5,"span",31),s(6),a()(),l(7,"button",32),M("click",function(){let o=S(t).$implicit,r=p(2).$implicit,c=p(2);
8return w(c.isolateCodeFilter(r.code,o.code))}),s(8,"only"),a()()}if(e&2){let t=n.$implicit,i=p(2).$implicit,o=p(2);d(2),v("checked",o.isCodeEnabled(t.code))("disabled",!o.classFilters()[i.code]),d(2),g(t.code),d(2),g(t.name)}}function zN(e,n){if(e&1&&(l(0,"div",21),I(1,$N,9,4,"div",27,xr),a()),e&2){let t=p().$implicit,i=p(2);d(),T(i.featureCodesByClass[t.code])}}function GN(e,n){if(e&1){let t=$();l(0,"div",14)(1,"button",22),M("click",function(){let o=S(t).$implicit,r=p(2);return w(r.toggleClassExpanded(o.code))}),s(2,"\u25B8"),a(),l(3,"label",23)(4,"input",15),M("change",function(){let o=S(t).$implicit,r=p(2);return w(r.toggleClassFilter(o.code))}),a(),l(5,"span",24),s(6),a(),l(7,"span",25),s(8),a()(),l(9,"button",26),M("click",function(){let o=S(t).$implicit,r=p(2);return w(r.isolateClassFilter(o.code))}),s(10,"only"),a()(),y(11,zN,3,0,"div",21)}if(e&2){let t=n.$implicit,i=p(2);d(),pe("expanded",i.expandedClasses()[t.code]),_e("aria-label",(i.expandedClasses()[t.code]?"Collapse":"Expand")+" "+t.name+" feature codes"),d(3),v("checked",i.classFilters()[t.code]),d(),Te("background-color",i.featureClassColors[t.code]==null?null:i.featureClassColors[t.code].background)("color",i.featureClassColors[t.code]==null?null:i.featureClassColors[t.code].color),d(),g(t.code),d(2),g(t.name),d(3),_(i.expandedClasses()[t.code]?11:-1)}}function WN(e,n){if(e&1){let t=$();l(0,"button",34),M("click",function(){let o=S(t).$implicit,r=p(3);return w(r.setWikipediaLang(o))}),s(1),a()}if(e&2){let t=n.$implicit,i=p(3);pe("active",i.wikipediaLang()===t),d(),A(" ",t," ")}}function qN(e,n){if(e&1&&(l(0,"div",19),I(1,WN,2,3,"button",33,Re),a()),e&2){let t=p(2);d(),T(t.wikipediaLangs)}}function JN(e,n){if(e&1){let t=$();l(0,"div",21)(1,"label",27)(2,"input",15),M("change",function(){S(t);let o=p(2);return w(o.togglePostalCodesReduced())}),a(),l(3,"span"),s(4,"Reduced (GB/NL prefix only)"),a()()()}if(e&2){let t=p(2);d(2),v("checked",t.postalCodesReduced())}}function KN(e,n){if(e&1){let t=$();l(0,"div",8)(1,"div",12)(2,"strong"),s(3,"Layers"),a(),l(4,"button",13),M("click",function(){S(t);let o=p();return w(o.toggleLayersPanel())}),s(5,"\xD7"),a()(),l(6,"label",14)(7,"input",15),M("change",function(){S(t);let o=p();return w(o.toggleAllClasses())}),a(),l(8,"span",16),s(9,"GeoNames"),a()(),I(10,GN,12,11,null,null,xr),j(12,"div",17),l(13,"label",14)(14,"input",15),M("change",function(){S(t);let o=p();return w(o.toggleWikipediaLayer())}),a(),l(15,"span",18),s(16,"W"),a(),s(17," Wikipedia "),a(),y(18,qN,3,0,"div",19),l(19,"label",14)(20,"input",15),M("change",function(){S(t);let o=p();return w(o.togglePostalCodesLayer())}),a(),l(21,"span",20),s(22,"PC"),a(),s(23," Postal codes "),a(),y(24,JN,5,1,"div",21),a()}if(e&2){let t=p();d(7),v("checked",t.allClassesEnabled()),d(3),T(t.featureClasses),d(4),v("checked",t.wikipediaEnabled()),d(4),_(t.wikipediaEnabled()?18:-1),d(2),v("checked",t.postalCodesEnabled()),d(4),_(t.postalCodesEnabled()?24:-1)}}function YN(e,n){if(e&1){let t=$();l(0,"div",35)(1,"span",36),s(2),a(),s(3," Click the new position for "),l(4,"strong"),s(5),a(),s(6,"\u2026 "),l(7,"button",37),M("click",function(){S(t);let o=p(2);return w(o.cancelMoveArm())}),s(8,"Cancel"),a()()}if(e&2){let t=p(),i=p();d(),Te("background-color",i.featureClassColors[t.featureClass]==null?null:i.featureClassColors[t.featureClass].background)("color",i.featureClassColors[t.featureClass]==null?null:i.featureClassColors[t.featureClass].color),d(),g(t.featureCode),d(3),g(t.name)}}function ZN(e,n){if(e&1&&y(0,YN,9,6,"div",35),e&2){let t=p();_(t.pendingMove()?-1:0)}}function QN(e,n){if(e&1&&(l(0,"p",41),s(1),a()),e&2){let t=p(2);d(),g(t.moveError())}}function XN(e,n){if(e&1){let t=$();l(0,"div",10)(1,"p"),s(2," Move "),l(3,"span",36),s(4),a(),l(5,"strong"),s(6),a(),s(7),a(),l(8,"div",38)(9,"button",39),M("click",function(){S(t);let o=p();return w(o.confirmPendingMove())}),s(10),a(),l(11,"button",40),M("click",function(){S(t);let o=p();return w(o.cancelPendingMove())}),s(12,"Cancel"),a()(),y(13,QN,2,1,"p",41),a()}if(e&2){let t,i,o,r,c=n,u=p();d(3),Te("background-color",u.featureClassColors[(t=(t=u.moveTarget())==null?null:t.featureClass)!==null&&t!==void 0?t:""]==null?null:u.featureClassColors[(t=t)!==null&&t!==void 0?t:""].background)("color",u.featureClassColors[(i=(i=u.moveTarget())==null?null:i.featureClass)!==null&&i!==void 0?i:""]==null?null:u.featureClassColors[(i=i)!==null&&i!==void 0?i:""].color),d(),g((o=u.moveTarget())==null?null:o.featureCode),d(2),g((r=u.moveTarget())==null?null:r.name),d(),gt(" to ",c.lat.toFixed(5),", ",c.lng.toFixed(5)," \u2014 ",u.pendingDistanceLabel()," away? "),d(2),v("disabled",u.moving()),d(),A(" ",u.moving()?"Moving\u2026":"Confirm move"," "),d(),v("disabled",u.moving()),d(2),_(u.moveError()?13:-1)}}function ek(e,n){if(e&1&&(l(0,"p",11),s(1),a()),e&2){let t=p();d(),g(t.moveSuccess())}}function tk(e,n){e&1&&(l(0,"p"),s(1,"Loading current details\u2026"),a())}function nk(e,n){if(e&1&&(l(0,"option",46),s(1),a()),e&2){let t=n.$implicit;v("value",t.code),d(),le("",t.code," \u2014 ",t.name,"")}}function ik(e,n){if(e&1&&(l(0,"option",46),s(1),a()),e&2){let t=n.$implicit,i=p(3);
8v("value",t.code),d(),A(" ",i.editCodeSortByName?t.name+" ("+t.code+")":t.code+" \u2014 "+t.name," ")}}function ok(e,n){if(e&1&&(l(0,"option",46),s(1),a()),e&2){let t=n.$implicit;v("value",t),d(),g(t)}}function rk(e,n){if(e&1&&(l(0,"p",41),s(1),a()),e&2){let t=p(3);d(),g(t.editSaveError())}}function ak(e,n){if(e&1){let t=$();l(0,"div",42)(1,"label"),s(2,"Name "),l(3,"input",43),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.editForm.name,o)||(r.editForm.name=o),w(o)}),a()(),l(4,"label"),s(5," Feature class "),l(6,"select",44),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.editForm.fclass,o)||(r.editForm.fclass=o),w(o)}),M("ngModelChange",function(){S(t);let o=p(2);return w(o.onEditFeatureClassChange())}),l(7,"option",45),s(8,"select\u2026"),a(),I(9,nk,2,3,"option",46,xr),a()(),l(11,"label")(12,"span",47),s(13," Feature code "),l(14,"button",48),M("click",function(){S(t);let o=p(2);return w(o.toggleEditCodeSort())}),s(15),a()(),l(16,"select",49),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.editForm.c,o)||(r.editForm.c=o),w(o)}),l(17,"option",45),s(18,"select\u2026"),a(),I(19,ik,2,2,"option",46,xr),a()(),l(21,"label"),s(22,"Elevation (m) "),l(23,"input",50),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.editForm.elevation,o)||(r.editForm.elevation=o),w(o)}),a()(),l(24,"label"),s(25,"Population "),l(26,"input",51),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.editForm.population,o)||(r.editForm.population=o),w(o)}),a()(),l(27,"label"),s(28," Timezone "),l(29,"select",52),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.editForm.timezone,o)||(r.editForm.timezone=o),w(o)}),l(30,"option",45),s(31,"select\u2026"),a(),I(32,ok,2,2,"option",46,Re),a()(),l(34,"label"),s(35,"Alternate countries "),l(36,"input",53),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.editForm.cc2,o)||(r.editForm.cc2=o),w(o)}),a()(),l(37,"div",38)(38,"button",39),M("click",function(){S(t);let o=p(2);return w(o.submitEditFeature())}),s(39),a(),l(40,"button",40),M("click",function(){S(t);let o=p(2);return w(o.cancelEditFeature())}),s(41,"Cancel"),a()(),y(42,rk,2,1,"p",41),a()}if(e&2){let t=p(2);d(3),R("ngModel",t.editForm.name),d(3),R("ngModel",t.editForm.fclass),d(3),T(t.featureClasses),d(6),A(" Sort: ",t.editCodeSortByName?"name":"code"," "),d(),R("ngModel",t.editForm.c),v("disabled",!t.editForm.fclass),d(3),T(t.getEditFeatureCodeOptions()),d(4),R("ngModel",t.editForm.elevation),d(3),R("ngModel",t.editForm.population),d(3),R("ngModel",t.editForm.timezone),d(3),T(t.timezoneOptions()),d(4),R("ngModel",t.editForm.cc2),d(2),v("disabled",t.editSaving()),d(),A(" ",t.editSaving()?"Saving\u2026":"Save"," "),d(),v("disabled",t.editSaving()),d(2),_(t.editSaveError()?42:-1)}}function sk(e,n){if(e&1&&(l(0,"div",10)(1,"h3"),s(2),a(),y(3,tk,2,0,"p")(4,ak,43,13,"div",42),a()),e&2){let t=p();d(2),A("Edit ",t.editTargetLabel(),""),d(),_(t.editLoading()?3:4)}}function lk(e,n){if(e&1&&(l(0,"p",11),s(1),a()),e&2){let t=p();d(),g(t.editSaveSuccess())}}function ck(e,n){if(e&1&&(l(0,"option",46),s(1),a()),e&2){let t=n.$implicit;v("value",t.code),d(),le("",t.code," \u2014 ",t.name,"")}}function dk(e,n){if(e&1&&(l(0,"option",46),s(1),a()),e&2){let t=n.$implicit,i=p(2);v("value",t.code),d(),A(" ",i.createCodeSortByName?t.name+" ("+t.code+")":t.code+" \u2014 "+t.name," ")}}function uk(e,n){if(e&1&&(l(0,"option",46),s(1),a()),e&2){let t=n.$implicit;v("value",t),d(),g(t)}}function mk(e,n){if(e&1&&(l(0,"p",41),s(1),a()),e&2){let t=p(2);d(),g(t.createError())}}function pk(e,n){if(e&1){let t=$();l(0,"div",10)(1,"h3"),s(2),a(),l(3,"div",42)(4,"label"),s(5,"Name "),l(6,"input",54),F("ngModelChange",function(o){S(t);let r=p();return L(r.createForm.name,o)||(r.createForm.name=o),w(o)}),a()(),l(7,"label"),s(8," Feature class "),l(9,"select",55),F("ngModelChange",function(o){S(t);let r=p();return L(r.createForm.fclass,o)||(r.createForm.fclass=o),w(o)}),M("ngModelChange",function(){S(t);let o=p();return w(o.onCreateFeatureClassChange())}),l(10,"option",45),s(11,"select\u2026"),a(),I(12,ck,2,3,"option",46,xr),a()(),l(14,"label")(15,"span",47),s(16," Feature code "),l(17,"button",48),M("click",function(){S(t);let o=p();return w(o.toggleCreateCodeSort())}),s(18),a()(),l(19,"select",56),F("ngModelChange",function(o){S(t);let r=p();return L(r.createForm.c,o)||(r.createForm.c=o),w(o)}),l(20,"option",45),s(21,"select\u2026"),a(),I(22,dk,2,2,"option",46,xr),a()(),l(24,"label"),s(25,"Elevation (m) "),l(26,"input",57),F("ngModelChange",function(o){S(t);let r=p();return L(r.createForm.elevation,o)||(r.createForm.elevation=o),w(o)}),a()(),l(27,"label"),s(28,"Population "),l(29,"input",58),F("ngModelChange",function(o){S(t);let r=p();return L(r.createForm.population,o)||(r.createForm.population=o),w(o)}),a()(),l(30,"label"),s(31," Timezone "),l(32,"select",59),F("ngModelChange",function(o){S(t);let r=p();return L(r.createForm.timezone,o)||(r.createForm.timezone=o),w(o)}),l(33,"option",45),s(34,"auto-derived if left blank"),a(),I(35,uk,2,2,"option",46,Re),a()(),l(37,"label"),s(38," Alternate countries "),l(39,"input",60),F("ngModelChange",function(o){S(t);let r=p();return L(r.createForm.cc2,o)||(r.createForm.cc2=o),w(o)}),a()(),l(40,"div",38)(41,"button",39),M("click",function(){S(t);let o=p();
8return w(o.submitCreateFeature())}),s(42),a(),l(43,"button",40),M("click",function(){S(t);let o=p();return w(o.cancelCreateFeature())}),s(44,"Cancel"),a()(),y(45,mk,2,1,"p",41),a()()}if(e&2){let t=p();d(2),le("New place at ",t.createForm.lat,", ",t.createForm.lng,""),d(4),R("ngModel",t.createForm.name),d(3),R("ngModel",t.createForm.fclass),d(3),T(t.featureClasses),d(6),A(" Sort: ",t.createCodeSortByName?"name":"code"," "),d(),R("ngModel",t.createForm.c),v("disabled",!t.createForm.fclass),d(3),T(t.getCreateFeatureCodeOptions()),d(4),R("ngModel",t.createForm.elevation),d(3),R("ngModel",t.createForm.population),d(3),R("ngModel",t.createForm.timezone),d(3),T(t.timezoneOptions()),d(4),R("ngModel",t.createForm.cc2),d(2),v("disabled",t.creating()||!t.createForm.name),d(),A(" ",t.creating()?"Creating\u2026":"Create"," "),d(),v("disabled",t.creating()),d(2),_(t.createError()?45:-1)}}function fk(e,n){if(e&1&&(l(0,"p",11),s(1),a()),e&2){let t=p();d(),g(t.createSuccess())}}function we(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;")}function md(e){return e==="P"?"#4a4a4a":e?Dn[e]?.background:void 0}var nt=class e{latitude;longitude;zoom=9;label="location";popupDescription;featureClass;boundingBox;geonameId;hasShape=!1;shapeGeometry;place;ancestors=[];allowCreate=!0;allowMove=!0;showCenterMarker=!0;autoFetchNearby=!1;initialWikipediaEnabled=!1;onlyFeatureClass;onlyFeatureCode;hideFeatureMarkers=!1;tall=!1;preferRaster=!1;addressLookupEnabled=!1;useUsReverseGeocoder=!1;useOsmReverseGeocoder=!1;addressResult=null;pickPointEnabled=!1;pickedPoint=null;pointPicked=new je;placeMoved=new je;featureEdited=new je;mapHost;mapWrap;platformId=h(Zt);shapeService=h(od);nearbyPlacesService=h(ad);featureService=h(br);remotePlaceService=h(yr);wikipediaLayerService=h(sd);postalCodeLayerService=h(ld);addressService=h(Wn);osmReverseGeocodeService=h(cd);timezoneService=h(Fi);mapConfigService=h(rd);maplibregl;map;useVectorStyles=!1;streetsStyleUrl=null;imageryStyleUrl=null;cachedShapeGeometry=null;marker;pendingMarker;nearbyMarkers=[];clusterGroups=new Map;wikipediaMarkers=[];postalCodeMarkers=[];addressMarker;pickedMarker;addressLookupRequestId=0;nearbyFetchHandle;styleLoadedPollHandle;hoverShapeRequestId=0;featureClasses=qn;featureClassColors=Dn;timezoneOptions=E([]);wikipediaLangs=["en","nl","de","pl","fr","it","es","ru","pt"];createCodeSortByName=!1;featureCodesByClass=hi;layersOpen=E(!1);classFilters=E(Object.fromEntries(qn.map(n=>[n.code,!0])));expandedClasses=E({});codeFilters=E({});wikipediaEnabled=E(!1);wikipediaLang=E("en");postalCodesEnabled=E(!1);postalCodesReduced=E(!0);allClassesEnabled=G(()=>Object.values(this.classFilters()).every(n=>n));createArmed=E(!1);showCreateForm=E(!1);createForm={lat:"",lng:"",name:"",fclass:"",c:"",elevation:"",population:"",timezone:"",cc2:""};creating=E(!1);createError=E(null);createSuccess=E(null);moveTarget=E(null);pendingMove=E(null);moving=E(!1);moveError=E(null);moveSuccess=E(null);editTargetId=E(null);editTargetLabel=E("");editLoading=E(!1);editForm={name:"",fclass:"",c:"",elevation:"",population:"",timezone:"",cc2:""};editCodeSortByName=!1;editSaving=E(!1);editSaveError=E(null);editSaveSuccess=E(null);satelliteEnabled=E(!1);isFullscreen=E(!1);onFullscreenChange=()=>{this.isFullscreen.set(document.fullscreenElement===this.mapWrap?.nativeElement),setTimeout(()=>this.map?.resize(),50)};ngAfterViewInit(){return wt(this,null,function*(){if(!un(this.platformId))return;this.timezoneService.getTimezoneIds().subscribe(u=>this.timezoneOptions.set(u));let n=yield import("./chunk-UX35WUXB.js"),t=n.default??n;this.maplibregl=t;try{let u=yield vt(this.mapConfigService.getMapConfig());this.useVectorStyles=u.vector&&!this.preferRaster,this.streetsStyleUrl=u.streetsStyleUrl,this.imageryStyleUrl=u.imageryStyleUrl}catch{}if(this.hideFeatureMarkers)this.classFilters.set(Object.fromEntries(qn.map(u=>[u.code,!1])));else if(this.onlyFeatureClass&&(this.classFilters.set(Object.fromEntries(qn.map(u=>[u.code,u.code===this.onlyFeatureClass]))),this.onlyFeatureCode)){let u=(hi[this.onlyFeatureClass]??[]).map(m=>m.code);
8this.codeFilters.set(Object.fromEntries(u.map(m=>[m,m===this.onlyFeatureCode])))}let i=this.boundingBox,o=this.useVectorStyles&&this.streetsStyleUrl?this.streetsStyleUrl:{version:8,sources:{streets:{type:"raster",tiles:["https://server.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer/tile/{z}/{y}/{x}"],tileSize:256,attribution:"Esri, HERE, Garmin, USGS, Intermap, INCREMENT P, NRCan, Esri Japan, METI, Esri China (Hong Kong), Esri Korea, Esri (Thailand), NGCC, \xA9 OpenStreetMap contributors, and the GIS User Community"},satellite:{type:"raster",tiles:["https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}"],tileSize:256,attribution:"Esri, Maxar, Earthstar Geographics"}},layers:[{id:"streets",type:"raster",source:"streets"},{id:"satellite",type:"raster",source:"satellite",layout:{visibility:"none"}}]};if(this.map=new t.Map(oe(U({container:this.mapHost.nativeElement,style:o},i?{bounds:[[i.west,i.south],[i.east,i.north]],fitBoundsOptions:{padding:24}}:{center:[this.longitude,this.latitude],zoom:this.zoom}),{attributionControl:{compact:!0}})),this.map.addControl(new t.NavigationControl({showCompass:!1}),"top-right"),this.map.addControl(new t.ScaleControl({maxWidth:100,unit:"metric"}),"bottom-left"),this.showCenterMarker){let u=new t.Popup({offset:25,closeButton:!0}).setHTML(this.popupHtml()),m=md(this.featureClass);this.marker=new t.Marker(m?{color:m}:void 0).setLngLat([this.longitude,this.latitude]).setPopup(u).addTo(this.map),this.marker.togglePopup()}this.pickPointEnabled&&this.pickedPoint&&this.updatePickedMarker(this.pickedPoint),this.mapHost.nativeElement.addEventListener("click",u=>this.onPopupActionClick(u));let r=!1,c=()=>{r||!this.map||(r=!0,this.setupOverlayLayers(i),this.map.on("style.load",()=>this.setupOverlayLayers(i)),this.autoFetchNearby&&this.fetchNearby(),this.initialWikipediaEnabled&&(this.wikipediaEnabled.set(!0),this.fetchWikipedia()))};this.map.on("load",c),this.styleLoadedPollHandle=setInterval(()=>{r?clearInterval(this.styleLoadedPollHandle):this.map?.isStyleLoaded()&&(clearInterval(this.styleLoadedPollHandle),c())},250),this.map.on("moveend",()=>this.scheduleNearbyFetch()),this.map.on("click",u=>this.onMapClick(u)),document.addEventListener("fullscreenchange",this.onFullscreenChange)})}toggleSatellite(){if(!this.map)return;let n=!this.satelliteEnabled();this.satelliteEnabled.set(n),this.useVectorStyles?this.applyVectorBasemap(n):this.applySatelliteVisibility(n)}applyVectorBasemap(n){if(!this.map)return;let t=n?this.imageryStyleUrl:this.streetsStyleUrl;t&&this.map.setStyle(t,{diff:!1})}applySatelliteVisibility(n){if(this.map){if(!this.map.isStyleLoaded()){let t=setInterval(()=>{if(!this.map){clearInterval(t);return}this.map.isStyleLoaded()&&(clearInterval(t),this.applySatelliteVisibility(n))},100);return}this.map.setLayoutProperty("streets","visibility",n?"none":"visible"),this.map.setLayoutProperty("satellite","visibility",n?"visible":"none")}}toggleFullscreen(){document.fullscreenElement?document.exitFullscreen():this.mapWrap.nativeElement.requestFullscreen()}setupOverlayLayers(n){this.map&&(n&&(this.removeLayerAndSource("bbox-outline","bbox"),this.map.addSource("bbox",{type:"geojson",data:{type:"Feature",properties:{},geometry:{type:"Polygon",coordinates:[[[n.west,n.south],[n.east,n.south],[n.east,n.north],[n.west,n.north],[n.west,n.south]]]}}}),this.map.addLayer({id:"bbox-outline",type:"line",source:"bbox",paint:{"line-color":"#1a5fb4","line-width":1.5,"line-dasharray":[2,2]}})),this.shapeGeometry?this.addShapeLayers(this.shapeGeometry):this.hasShape&&this.geonameId&&(this.cachedShapeGeometry?this.addShapeLayers(this.cachedShapeGeometry):this.shapeService.getShape(this.geonameId).subscribe(t=>{t&&(this.cachedShapeGeometry=t,this.addShapeLayers(t))})),this.removeLayerAndSource("hover-shape-fill",void 0),this.removeLayerAndSource("hover-shape-outline","hover-shape"),this.map.addSource("hover-shape",{type:"geojson",data:{type:"FeatureCollection",features:[]}}),this.map.addLayer({id:"hover-shape-fill",type:"fill",source:"hover-shape",paint:{"fill-color":"#fbb4ae","fill-opacity":.35}}),this.map.addLayer({id:"hover-shape-outline",type:"line",source:"hover-shape",paint:{"line-color":"#fbb4ae","line-width":2}}))}addShapeLayers(n){this.map&&(this.removeLayerAndSource("shape-fill",void 0),this.removeLayerAndSource("shape-outline","shape"),this.map.addSource("shape",{type:"geojson",data:{type:"Feature",properties:{},geometry:n}}
8),this.map.addLayer({id:"shape-fill",type:"fill",source:"shape",paint:{"fill-color":"#e08b1a","fill-opacity":.15}}),this.map.addLayer({id:"shape-outline",type:"line",source:"shape",paint:{"line-color":"#e08b1a","line-width":2}}))}removeLayerAndSource(n,t){this.map&&(this.map.getLayer(n)&&this.map.removeLayer(n),t&&this.map.getSource(t)&&this.map.removeSource(t))}showHoverShape(n){if(!this.map)return;let t=++this.hoverShapeRequestId;this.shapeService.getShape(n).subscribe(i=>{if(!i||t!==this.hoverShapeRequestId||!this.map)return;this.map.getSource("hover-shape")?.setData({type:"Feature",properties:{},geometry:i}),this.map.triggerRepaint()})}clearHoverShape(){this.hoverShapeRequestId++,this.map?.getSource("hover-shape")?.setData({type:"FeatureCollection",features:[]}),this.map?.triggerRepaint()}scheduleNearbyFetch(){this.nearbyFetchHandle&&clearTimeout(this.nearbyFetchHandle),this.nearbyFetchHandle=setTimeout(()=>{this.fetchNearby(),this.wikipediaEnabled()&&this.fetchWikipedia(),this.postalCodesEnabled()&&this.fetchPostalCodes()},300)}fetchNearby(){if(!this.map)return;let n=Object.entries(this.classFilters()).filter(([,o])=>o).map(([o])=>o);if(n.length===0){this.clearNearbyMarkers();return}let t=this.map.getBounds(),i=this.map.getCenter();this.nearbyPlacesService.getNearby({lat:i.lat,lng:i.lng,north:t.getNorth(),south:t.getSouth(),east:t.getEast(),west:t.getWest(),excludeId:this.geonameId,classes:n}).subscribe(o=>this.renderNearbyMarkers(o))}toggleLayersPanel(){this.layersOpen.update(n=>!n)}toggleClassFilter(n){let t=!this.classFilters()[n];this.classFilters.update(i=>oe(U({},i),{[n]:t})),t&&this.resetCodeFiltersForClass(n),this.fetchNearby()}toggleAllClasses(){let n=!this.allClassesEnabled();this.classFilters.set(Object.fromEntries(qn.map(t=>[t.code,n]))),n&&this.codeFilters.set({}),this.fetchNearby()}isolateClassFilter(n){this.classFilters.set(Object.fromEntries(qn.map(t=>[t.code,t.code===n]))),this.resetCodeFiltersForClass(n),this.fetchNearby()}toggleClassExpanded(n){this.expandedClasses.update(t=>oe(U({},t),{[n]:!t[n]}))}isCodeEnabled(n){return this.codeFilters()[n]!==!1}toggleCodeFilter(n){this.codeFilters.update(t=>oe(U({},t),{[n]:!this.isCodeEnabled(n)})),this.fetchNearby()}isolateCodeFilter(n,t){this.classFilters.set(Object.fromEntries(qn.map(o=>[o.code,o.code===n])));let i=hi[n]??[];this.codeFilters.update(o=>{let r=U({},o);for(let c of i)r[c.code]=c.code===t;return r}),this.fetchNearby()}resetCodeFiltersForClass(n){let t=new Set((hi[n]??[]).map(i=>i.code));this.codeFilters.update(i=>Object.fromEntries(Object.entries(i).filter(([o])=>!t.has(o))))}toggleWikipediaLayer(){this.wikipediaEnabled.update(n=>!n),this.wikipediaEnabled()?this.fetchWikipedia():this.clearWikipediaMarkers()}setWikipediaLang(n){this.wikipediaLang.set(n),this.wikipediaEnabled()&&this.fetchWikipedia()}fetchWikipedia(){if(!this.map)return;let n=this.map.getBounds();this.wikipediaLayerService.getArticles({lang:this.wikipediaLang(),north:n.getNorth(),south:n.get
8South(),east:n.getEast(),west:n.getWest()}).subscribe(t=>this.renderWikipediaMarkers(t))}renderWikipediaMarkers(n){if(!(!this.map||!this.maplibregl)){this.clearWikipediaMarkers();for(let t of n){let i=t.summary.length>220?`${t.summary.slice(0,220)}\u2026`:t.summary,o=t.thumbnailImg?`<img class="wiki-popup-thumb" src="${we(t.thumbnailImg)}" alt="">`:"",r=`<a href="https://${we(t.wikipediaUrl)}" target="_blank" rel="noopener">${we(t.title)}</a>`,c=new this.maplibregl.Popup({offset:18,closeButton:!0}).setHTML(`<div class="geo-map-popup wiki-popup">${o}<strong>${r}</strong><br>${we(i)}</div>`),u=document.createElement("div");u.className="wiki-marker",u.textContent="W";let m=new this.maplibregl.Marker({element:u}).setLngLat([t.longitude,t.latitude]).setPopup(c).addTo(this.map);this.wikipediaMarkers.push(m)}}}clearWikipediaMarkers(){for(let n of this.wikipediaMarkers)n.remove();this.wikipediaMarkers=[]}togglePostalCodesLayer(){this.postalCodesEnabled.update(n=>!n),this.postalCodesEnabled()?this.fetchPostalCodes():this.clearPostalCodeMarkers()}togglePostalCodesReduced(){this.postalCodesReduced.update(n=>!n),this.postalCodesEnabled()&&this.fetchPostalCodes()}fetchPostalCodes(){if(!this.map)return;let n=this.map.getBounds(),t=this.map.getCenter(),i=n.getNorthEast(),o=Math.min($h(t.lat,t.lng,i.lat,i.lng),30);this.postalCodeLayerService.getPostalCodes({lat:t.lat,lng:t.lng,radius:o,isReduced:this.postalCodesReduced()}).subscribe(r=>this.renderPostalCodeMarkers(r))}renderPostalCodeMarkers(n){if(!(!this.map||!this.maplibregl)){this.clearPostalCodeMarkers();for(let t of n){let i=t.placeName?`, ${we(t.placeName)}`:"",o=[t.adminName2,t.adminName1,t.countryCode].filter(Boolean).join(", "),r=t.postalCodeId?`<div class="popup-actions"><a href="/postal-codes/${t.postalCodeId}" class="popup-edit-btn">Details</a></div>`:"",c=new this.maplibregl.Popup({offset:14,closeButton:!0}).setHTML(`<div class="geo-map-popup postal-popup"><strong>${we(t.postalCode)}</strong>${i}${o?`<div class="popup-breadcrumb">${we(o)}</div>`:""}${r}</div>`),u=document.createElement("div");u.className="postal-marker",u.textContent=t.postalCode;let m=new this.maplibregl.Marker({element:u}).setLngLat([t.longitude,t.latitude]).setPopup(c).addTo(this.map);this.postalCodeMarkers.push(m)}}}clearPostalCodeMarkers(){for(let n of this.postalCodeMarkers)n.remove();this.postalCodeMarkers=[]}renderNearbyMarkers(n){if(!this.map||!this.maplibregl)return;this.clearNearbyMarkers();let t=new Map;for(let i of n){if(i.id===this.geonameId||!this.isCodeEnabled(i.featureCode))continue;let o=`${i.latitude.toFixed(5)},${i.longitude.toFixed(5)}`,r=t.get(o);r?r.push(i):t.set(o,[i])}for(let[i,o]of t)o.length===1?this.addSingleNearbyMarker(o[0]):this.addClusterMarker(i,o)}addSingleNearbyMarker(n){if(!this.map||!this.maplibregl)return;let t=new this.maplibregl.Popup({offset:18,closeButton:!0}).setHTML(this.buildNearbyPopupHtml(n)),i=md(n.featureClass)??"#8a8a8a",o=new this.maplibregl.Marker({color:i,scale:.7}).setLngLat([n.longitude,n.latitude]).setPopup(t).addTo(this.map);if(n.hasShape){let r=o.getElement();r.addEventListener("mouseenter",()=>this.showHoverShape(n.id)),r.addEventListener("mouseleave",()=>this.clearHoverShape())}this.nearbyMarkers.push({id:n.id,marker:o})}addClusterMarker(n,t){if(!this.map||!this.maplibregl)return;this.clusterGroups.set(n,t);let i=document.createElement("div");i.className="cluster-marker",i.style.backgroundColor=md(t[0].featureClass)??"#8a8a8a",i.textContent=String(t.length);let o=new this.maplibregl.Popup({offset:14,closeButton:!0}).setHTML(this.buildClusterListHtml(n,t)),r=new this.maplibregl.Marker({element:i}).setLngLat([t[0].longitude,t[0].latitude]).setPopup(o).addTo(this.map);for(let c of t)this.nearbyMarkers.push({id:c.id,marker:r})}buildNearbyPopupHtml(n){return this.buildRichPopupHtml({id:n.id,name:n.name,featureClass:n.featureClass,featureCode:n.featureCode,featureLabel:n.featureLabel,wikipediaUrl:n.wikipediaUrl,elevation:n.elevation,srtm3:n.srtm3,gtopo30:n.gtopo30,population:n.population,breadcrumbHtml:n.breadcrumb?we(n.breadcrumb):void 0,linkHref:n.path,latitude:n.latitude,longitude:n.longitude})}
8buildClusterListHtml(n,t){let i=t.map((o,r)=>{let c=Dn[o.featureClass],m=`<span class="fclass-badge" style="${c?`background-color:${c.background};color:${c.color}`:""}">${we(o.featureCode)}</span>`,f=o.population?`<span class="cluster-pop">pop. ${o.population.toLocaleString()}</span>`:"";return`
9          <li class="popup-select-row" data-cluster-key="${we(n)}" data-place-index="${r}">
10            ${m} ${we(o.name)} ${f}
11          </li>
12        `}).join("");return`
13      <div class="geo-map-popup cluster-popup">
14        <div class="popup-title"><strong>${t.length} features at this location</strong></div>
15        <ul class="cluster-list">${i}</ul>
16      </div>
17    `}clearNearbyMarkers(){for(let n of new Set(this.nearbyMarkers.map(t=>t.marker)))n.remove();this.nearbyMarkers=[],this.clusterGroups.clear(),this.clearHoverShape()}removeNearbyMarkerById(n){let t=this.nearbyMarkers.findIndex(r=>r.id===n);if(t===-1)return;let{marker:i}=this.nearbyMarkers[t];this.nearbyMarkers.splice(t,1),this.nearbyMarkers.some(r=>r.marker===i)||i.remove()}buildRichPopupHtml(n){let t=Dn[n.featureClass],i=t?`background-color:${t.background};color:${t.color}`:"",o=`<span class="fclass-badge" style="${i}">${we(n.featureClass)}</span>`,r=`<span class="fclass-badge" style="${i}">${we(n.featureCode)}</span>`,c=n.wikipediaUrl?`<a href="https://${we(n.wikipediaUrl)}" target="_blank" rel="noopener" title="Wikipedia article"><img src="https://www.geonames.org/img/20px-Wikipedia-logo.png" alt=""></a> `:"",u=ud(n),m=we(n.name),f=n.linkHref?`<a href="${we(n.linkHref)}">${m}</a>`:m,C=[];n.population&&C.push(`Population ${n.population.toLocaleString()}`),n.cc2&&C.push(`Alternate countries: ${we(n.cc2)}`);let b=this.allowMove?`<button type="button" class="popup-edit-btn" data-edit-id="${we(n.id)}">Edit</button>`:"",P=this.allowMove?`<button
18          type="button"
19          class="popup-move-btn"
20          data-move-id="${we(n.id)}"
21          data-move-name="${we(n.name)}"
22          data-move-fclass="${we(n.featureClass)}"
23          data-move-fcode="${we(n.featureCode)}"
24          data-move-lat="${n.latitude}"
25          data-move-lng="${n.longitude}"
26        >Move</button>`:"";return`
27      <div class="geo-map-popup place-popup">
28        <div class="popup-title">${c}<strong>${f}</strong>${u?` <small>${u}</small>`:""}</div>
29        <div class="popup-badges">${o}${r}${n.featureLabel?` <span class="popup-fcn">${we(n.featureLabel)}</span>`:""}</div>
30        ${n.breadcrumbHtml?`<div class="popup-breadcrumb">${n.breadcrumbHtml}</div>`:""}
31        ${C.length?`<div class="popup-facts">${C.join("<br>")}</div>`:""}
32        <div class="popup-coords">${n.latitude.toFixed(5)}, ${n.longitude.toFixed(5)}</div>
33        ${b||P?`<div class="popup-actions">${b}${P}</div>`:""}
34      </div>
35    `}popupHtml(){let n=this.place;if(!n){let i=`<strong>${we(this.label)}</strong>`,o=this.popupDescription?`<br>${we(this.popupDescription)}`:"";return`<div class="geo-map-popup">${i}${o}</div>`}let t=this.ancestors.filter(i=>i.featureLabel!=="Continent").map(i=>`${we(i.name)}${i.code?`<sup>${we(i.code)}</sup>`:""}`).join(" \xBB ");return this.buildRichPopupHtml({id:n.id,name:n.name,featureClass:n.featureClass,featureCode:n.featureCode,featureLabel:n.featureLabel,wikipediaUrl:n.wikipediaUrl,elevation:n.elevation,srtm3:n.srtm3,astergdem:n.astergdem,gtopo30:n.gtopo30,population:n.population,cc2:n.cc2,breadcrumbHtml:t,latitude:n.latitude,longitude:n.longitude})}toggleCreateArmed(){this.moveTarget.set(null),this.editTargetId.set(null),this.showCreateForm()||(this.clearPendingMarker(),this.pendingMove.set(null)),this.createArmed.update(n=>!n)}onMapClick(n){if(this.pickPointEnabled){this.handlePickPointClick(n);return}if(this.moveTarget()){this.handleMoveClick(n);return}if(this.addressLookupEnabled){this.handleAddressLookupClick(n);return}this.createArmed()&&(this.createArmed.set(!1),this.createForm={lat:n.lngLat.lat.toFixed(5),lng:n.lngLat.lng.toFixed(5),name:"",fclass:"",c:"",elevation:"",population:"",timezone:"",cc2:""},this.showCreateForm.set(!0),this.createError.set(null),this.createSuccess.set(null),this.clearPendingMarker(),this.maplibregl&&this.map&&(this.pendingMarker=new this.maplibregl.Marker({color:"#d32f2f"}).setLngLat([n.lngLat.lng,n.lngLat.lat]).addTo(this.map)))}onCreateFeatureClassChange(){this.createForm.c=""}toggleCreateCodeSort(){this.createCodeSortByName=!this.createCodeSortByName}getCreateFeatureCodeOptions(){return[...hi[this.createForm.fclass]??[]].sort((t,i)=>this.createCodeSortByName?t.name.localeCompare(i.name):t.code.localeCompare(i.code))}
35cancelCreateFeature(){this.showCreateForm.set(!1),this.createError.set(null),this.clearPendingMarker()}submitCreateFeature(){this.creating.set(!0),this.createError.set(null),this.featureService.createFeature({lat:Number(this.createForm.lat),lng:Number(this.createForm.lng),name:this.createForm.name,fclass:this.createForm.fclass,c:this.createForm.c,elevation:this.createForm.elevation,population:this.createForm.population,timezone:this.createForm.timezone,cc2:this.createForm.cc2}).subscribe({next:n=>{this.creating.set(!1),this.showCreateForm.set(!1),this.createSuccess.set(n.comment?`"${n.comment}" has been created.`:"The place has been created."),this.clearPendingMarker(),this.scheduleNearbyFetch()},error:n=>{this.creating.set(!1),this.createError.set(n instanceof Error?n.message:"Could not create this place.")}})}onPopupActionClick(n){let t=n.target,i=t.closest(".popup-select-row");if(i){n.stopPropagation(),this.onClusterRowClick(i);return}let o=t.closest(".popup-edit-btn");if(o){n.stopPropagation();let{editId:P}=o.dataset;P&&this.startEditForFeature(P);return}let r=t.closest(".popup-move-btn");if(!r)return;n.stopPropagation();let{moveId:c,moveName:u,moveFclass:m,moveFcode:f,moveLat:C,moveLng:b}=r.dataset;!c||C===void 0||b===void 0||this.armMove({id:c,name:u??"",featureClass:m??"",featureCode:f??"",latitude:Number(C),longitude:Number(b)})}onClusterRowClick(n){let{clusterKey:t,placeIndex:i}=n.dataset;if(!t||i===void 0)return;let o=this.clusterGroups.get(t)?.[Number(i)];if(!o)return;this.nearbyMarkers.find(c=>c.id===o.id)?.marker.getPopup()?.setHTML(this.buildNearbyPopupHtml(o))}armMove(n){this.createArmed.set(!1),this.editTargetId.set(null),this.clearPendingMarker(),this.pendingMove.set(null),this.moveError.set(null),this.moveSuccess.set(null),this.closeAllPopups(),this.moveTarget.set(n)}cancelMoveArm(){this.moveTarget.set(null),this.clearPendingMarker()}startEditForFeature(n){if(this.moveTarget.set(null),this.createArmed.set(!1),this.editSaveError.set(null),this.editSaveSuccess.set(null),this.closeAllPopups(),this.editTargetId.set(n),n===this.geonameId&&this.place){this.populateEditForm(this.place);return}this.editLoading.set(!0),this.remotePlaceService.getPlaceView(n).subscribe({next:t=>{this.editLoading.set(!1),this.populateEditForm(t.place)},error:()=>{this.editLoading.set(!1),this.editSaveError.set("Could not load this feature for editing.")}})}populateEditForm(n){this.editTargetLabel.set(n.name),this.editForm={name:n.name,fclass:n.featureClass,c:n.featureCode,elevation:n.elevation!=null?String(n.elevation):"",population:n.population!=null?String(n.population):"",timezone:n.timezone??"",cc2:n.cc2??""}}cancelEditFeature(){this.editTargetId.set(null),this.editSaveError.set(null)}onEditFeatureClassChange(){this.editForm.c=""}toggleEditCodeSort(){this.editCodeSortByName=!this.editCodeSortByName}getEditFeatureCodeOptions(){let n=hi[this.editForm.fclass]??[],t=this.editForm.c;return[...t&&!n.some(o=>o.code===t)?[...n,{code:t,name:t}]:n].sort((o,r)=>this.editCodeSortByName?o.name.localeCompare(r.name):o.code.localeCompare(r.code))}submitEditFeature(){let n=this.editTargetId();if(!n)return;this.editSaving.set(!0),this.editSaveError.set(null);let t=U({geonameId:n},this.editForm);this.featureService.updateFeature(t).subscribe({next:()=>{this.editSaving.set(!1),this.editTargetId.set(null),this.editSaveSuccess.set(`"${this.editForm.name}" has been updated.`),n===this.geonameId?(this.place&&(this.place.name=this.editForm.name,this.place.featureClass=this.editForm.fclass,this.place.featureCode=this.editForm.c,this.place.elevation=this.editForm.elevation?Number(this.editForm.elevation):void 0,this.place.population=this.editForm.population?Number(this.editForm.population):void 0,this.place.timezone=this.editForm.timezone||void 0,this.place.cc2=this.editForm.cc2||void 0),this.marker?.getPopup()?.setHTML(this.popupHtml()),this.featureEdited.emit({name:this.editForm.name,featureClass:this.editForm.fclass,featureCode:this.editForm.c,elevation:this.editForm.elevation?Number(this.editForm.elevation):void 0,population:this.editForm.population?Number(this.editForm.population):void 0,timezone:this.editForm.timezone||void 0,cc2:this.editForm.cc2||void 0})):this.removeNearbyMarkerById(n)},error:i=>{this.editSaving.set(!1),this.editSaveError.set(i instanceof Error?i.message:"Could not save these changes.")}})}closeAllPopups(){this.marker?.getPopup()?.remove();for(let n of this.nearbyMarkers)n.marker.getPopup()?.remove()}handleMoveClick(n){let t=this.moveTarget();if(this.pendingMove.set({lat:n.lngLat.lat,lng:n.lngLat.lng}),this.moveError.set(null),this.moveSuccess.set(null),this.clearPendingMarker(),this.maplibregl&&this.map){let i=md(t?.featureClass)??"#d32f2f";this.pendingMarker=new this.maplibregl.Marker({color:i}).setLngLat([n.lngLat.lng,n.lngLat.lat]).addTo(this.map)}}clearPendingMarker(){this.pendingMarker?.remove(),this.pendingMarker=void 0}handlePickPointClick(n){let t={lat:n.lngLat.lat,lng:n.lngLat.lng};
35this.updatePickedMarker(t),this.pointPicked.emit(t)}updatePickedMarker(n){if(!(!this.maplibregl||!this.map)){if(!n){this.pickedMarker?.remove(),this.pickedMarker=void 0;return}this.pickedMarker?this.pickedMarker.setLngLat([n.lng,n.lat]):(this.pickedMarker=new this.maplibregl.Marker({color:"#d32f2f",draggable:!0}).setLngLat([n.lng,n.lat]).addTo(this.map),this.pickedMarker.on("dragend",()=>{let t=this.pickedMarker.getLngLat();this.pointPicked.emit({lat:t.lat,lng:t.lng})}))}}handleAddressLookupClick(n){if(!this.maplibregl||!this.map)return;let{lat:t,lng:i}=n.lngLat,o=++this.addressLookupRequestId;this.addressMarker?.remove();let r=this.useOsmReverseGeocoder?"Looking up nearby streets\u2026":"Looking up address\u2026",c=new this.maplibregl.Popup({offset:25,closeButton:!0}).setHTML(`<div class="geo-map-popup address-popup">${r}</div>`);if(this.addressMarker=new this.maplibregl.Marker({color:"#8a2be2"}).setLngLat([i,t]).setPopup(c).addTo(this.map),this.addressMarker.togglePopup(),this.useOsmReverseGeocoder){this.osmReverseGeocodeService.nearbyStreets(t,i).subscribe({next:m=>{o===this.addressLookupRequestId&&c.setHTML(this.buildOsmStreetsPopupHtml(m))},error:()=>{o===this.addressLookupRequestId&&c.setHTML('<div class="geo-map-popup address-popup">Could not look up streets here.</div>')}});return}(this.useUsReverseGeocoder?this.addressService.reverseUS(t,i):this.addressService.reverse(t,i)).subscribe({next:m=>{o===this.addressLookupRequestId&&c.setHTML(this.buildAddressPopupHtml(m))},error:()=>{o===this.addressLookupRequestId&&c.setHTML('<div class="geo-map-popup address-popup">Could not look up an address here.</div>')}})}buildOsmStreetsPopupHtml(n){if(!n.length)return'<div class="geo-map-popup address-popup">No streets found nearby.</div>';let t=new Map;for(let r of n){let c=r.name?.trim();if(!c)continue;let u=t.get(c),m=r.distance?parseFloat(r.distance):NaN,f=u?.distance?parseFloat(u.distance):NaN;(!u||!isNaN(m)&&(isNaN(f)||m<f))&&t.set(c,r)}let i=[...t.values()].sort((r,c)=>parseFloat(r.distance??"NaN")-parseFloat(c.distance??"NaN")).slice(0,5);return i.length?`
36      <div class="geo-map-popup address-popup">
37        <div class="popup-title"><strong>Nearby streets</strong></div>
38        <ul class="popup-street-list">${i.map(r=>{let c=r.distance?parseFloat(r.distance):NaN,u=isNaN(c)?"":` <span class="popup-coords">(${dd(c)})</span>`;return`<li>${we(r.name??"")}${u}</li>`}).join("")}</ul>
39      </div>
40    `:'<div class="geo-map-popup address-popup">No streets found nearby.</div>'}buildAddressPopupHtml(n){if(!n)return'<div class="geo-map-popup address-popup">No address found nearby.</div>';let t=m=>!!m,i=[n.street,n.houseNumber].filter(t).map(we).join(" "),o=[n.postalcode,n.placename].filter(t).map(we).join(" "),r=[n.adminName2,n.adminName1,n.countryCode].filter(t).map(we).join(", "),c=n.distance?parseFloat(n.distance):NaN,u=isNaN(c)?"":`<div class="popup-coords">${dd(c)} away</div>`;return`
41      <div class="geo-map-popup address-popup">
42        ${i?`<div class="popup-title"><strong>${i}</strong></div>`:""}
43        ${o?`<div class="popup-facts">${o}</div>`:""}
44        ${r?`<div class="popup-breadcrumb">${r}</div>`:""}
45        ${u}
46      </div>
47    `}showAddressResultMarker(n){if(!this.map||!this.maplibregl||(this.addressMarker?.remove(),!n?.lat||!n?.lng))return;let t=new this.maplibregl.Popup({offset:25,closeButton:!0}).setHTML(this.buildAddressPopupHtml(n));this.addressMarker=new this.maplibregl.Marker({color:"#8a2be2"}).setLngLat([Number(n.lng),Number(n.lat)]).setPopup(t).addTo(this.map),this.addressMarker.togglePopup()}pendingDistanceLabel(){let n=this.pendingMove(),t=this.moveTarget();return!n||!t?"":dd($h(t.latitude,t.longitude,n.lat,n.lng))}cancelPendingMove(){this.pendingMove.set(null),this.moveError.set(null),this.clearPendingMarker()}confirmPendingMove(){let n=this.pendingMove(),t=this.moveTarget();!n||!t||(this.moving.set(!0),this.moveError.set(null),this.featureService.moveFeature(t.id,n.lat,n.lng).subscribe({next:()=>{this.moving.set(!1),this.pendingMove.set(null),this.moveSuccess.set(`"${t.name}" has been moved.`),this.clearPendingMarker(),this.moveTarget.set(null),t.id===this.geonameId?(this.marker?.setLngLat([n.lng,n.lat]),this.place&&(this.place.latitude=n.lat,this.place.longitude=n.lng),this.marker?.getPopup()?.setHTML(this.popupHtml()),this.map?.setCenter([n.lng,n.lat]),this.placeMoved.emit(n)):this.removeNearbyMarkerById(t.id)},error:i=>{this.moving.set(!1),this.moveError.set(i instanceof Error?i.message:"Could not move this place.")}}))}ngOnChanges(n){this.map&&((n.latitude||n.longitude)&&(this.map.setCenter([this.longitude,this.latitude]),this.marker?.setLngLat([this.longitude,this.latitude])),(n.label||n.popupDescription||n.place||n.ancestors)&&this.marker?.getPopup()?.setHTML(this.popupHtml()),n.addressResult&&this.showAddressResultMarker(this.addressResult),n.pickedPoint&&this.pickPointEnabled&&this.updatePickedMarker(this.pickedPoint),n.shapeGeometry&&this.shapeGeometry&&this.map.isStyleLoaded()&&this.addShapeLayers(this.shapeGeometry))}ngOnDestroy(){this.nearbyFetchHandle&&clearTimeout(this.nearbyFetchHandle),this.styleLoadedPollHandle&&clearInterval(this.styleLoadedPollHandle),un(this.platformId)&&document.removeEventListener("fullscreenchange",this.onFullscreenChange),this.clearNearbyMarkers(),this.clearWikipediaMarkers(),this.clearPostalCodeMar
47kers(),this.clearPendingMarker(),this.addressMarker?.remove(),this.map?.remove()}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-geo-map"]],viewQuery:function(t,i){if(t&1&&(kf(jN,7),kf(BN,7)),t&2){let o;Ql(o=Xl())&&(i.mapHost=o.first),Ql(o=Xl())&&(i.mapWrap=o.first)}},inputs:{latitude:"latitude",longitude:"longitude",zoom:"zoom",label:"label",popupDescription:"popupDescription",featureClass:"featureClass",boundingBox:"boundingBox",geonameId:"geonameId",hasShape:"hasShape",shapeGeometry:"shapeGeometry",place:"place",ancestors:"ancestors",allowCreate:"allowCreate",allowMove:"allowMove",showCenterMarker:"showCenterMarker",autoFetchNearby:"autoFetchNearby",initialWikipediaEnabled:"initialWikipediaEnabled",onlyFeatureClass:"onlyFeatureClass",onlyFeatureCode:"onlyFeatureCode",hideFeatureMarkers:"hideFeatureMarkers",tall:"tall",preferRaster:"preferRaster",addressLookupEnabled:"addressLookupEnabled",useUsReverseGeocoder:"useUsReverseGeocoder",useOsmReverseGeocoder:"useOsmReverseGeocoder",addressResult:"addressResult",pickPointEnabled:"pickPointEnabled",pickedPoint:"pickedPoint"},outputs:{pointPicked:"pointPicked",placeMoved:"placeMoved",featureEdited:"featureEdited"},features:[ct],decls:21,vars:20,consts:[["mapWrap",""],["mapHost",""],[1,"map-wrap"],["role","img",1,"map-host"],[1,"map-toolbar"],["type","button",1,"create-toggle",3,"click"],["type","button",1,"create-toggle",3,"armed"],["type","button",1,"create-toggle","fullscreen-toggle",3,"click"],[1,"layers-panel"],[1,"overlay-panels"],[1,"create-panel"],[1,"form-success"],[1,"layers-panel-header"],["type","button",1,"layers-close",3,"click"],[1,"layers-row"],["type","checkbox",3,"change","checked"],[1,"layers-section-title"],[1,"layers-divider"],[1,"fclass-swatch","wiki-swatch"],[1,"wiki-lang-row"],[1,"fclass-swatch","postal-swatch"],[1,"code-tree"],["type","button",1,"expand-btn",3,"click"],[1,"layers-row-label"],[1,"fclass-swatch"],[1,"layers-row-name"],["type","button",1,"only-btn",3,"click"],[1,"code-row"],[1,"code-row-label"],["type","checkbox",3,"change","checked","disabled"],[1,"code-label"],[1,"code-name"],["type","button",1,"only-btn","code-only-btn",3,"click"],["type","button",1,"lang-btn",3,"active"],["type","button",1,"lang-btn",3,"click"],[1,"move-armed-banner"],[1,"fclass-badge"],["type","button",3,"click"],[1,"edit-actions"],["type","button",1,"btn-primary",3,"click","disabled"],["type","button",3,"click","disabled"],[1,"form-error"],[1,"edit-form"],["type","text","name","editName",3,"ngModelChange","ngModel"],["name","editFclass",3,"ngModelChange","ngModel"],["value",""],[3,"value"],[1,"label-row"],["type","button",1,"sort-toggle",3,"click"],["name","editCode",3,"ngModelChange","ngModel","disabled"],["type","text","name","editElevation","size","8",3,"ngModelChange","ngModel"],["type","text","name","editPopulation","size","10",3,"ngModelChange","ngModel"],["name","editTimezone",3,"ngModelChange","ngModel"],["type","text","name","editCc2","placeholder","comma separated",3,"ngModelChange","ngModel"],["type","text","name","createName",3,"ngModelChange","ngModel"],["name","createFclass",3,"ngModelChange","ngModel"],["name","createCode",3,"ngModelChange","ngModel","disabled"],["type","text","name","createElevation","size","8",3,"ngModelChange","ngModel"],["type","text","name","createPopulation","size","10",3,"ngModelChange","ngModel"],["name","createTimezone",3,"ngModelChange","ngModel"],["type","text","name","createCc2","placeholder","comma separated",3,"ngModelChange","ngModel"]],template:function(t,i){if(t&1){let o=$();l(0,"div",2,0),j(2,"div",3,1),l(4,"div",4)(5,"button",5),M("click",function(){return S(o),w(i.toggleLayersPanel())}),s(6," \u2630 Layers "),a(),y(7,HN,2,3,"button",6),l(8,"button",5),M("click",function(){return S(o),w(i.toggleSatellite())}),s(9),a(),l(10,"button",7),M("click",function(){return S(o),w(i.toggleFullscreen())}),s(11),a()(),y(12,KN,25,5,"div",8),l(13,"div",9),y(14,ZN,1,1)(15,XN,14,13,"div",10)(16,ek,2,1,"p",11)(17,sk,5,2,"div",10)(18,lk,2,1,"p",11)(19,pk,46,15,"div",10)(20,fk,2,1,"p",11),a()()}if(t&2){let o,r;pe("is-fullscreen",i.isFullscreen())("is-tall",i.tall),d(2),_e("aria-label","Map showing "+i.label),d(3),pe("armed",i.layersOpen()),d(2),_(i.allowCreate?7:-1),d(),pe("armed",i.satelliteEnabled()),d(),A(" ",i.satelliteEnabled()?"Map":"Satellite"," "),d(2),A(" ",i.isFullscreen()?"Exit fullscreen":"Fullscreen"," "),d(),_(i.layersOpen()?12:-1),d(2),_((o=i.moveTarget())?14:-1,o),d(),_((r=i.pendingMove())?15:-1,r),d(),_(i.moveSuccess()?16:-1),d(),_(i.editTargetId()?17:-1),d(),_(i.editSaveSuccess()?18:-1),d(),_(i.showCreateForm()?19:-1),d(),_(i.createSuccess()?20:-1)}},dependencies:[ke,zn,Gn,Me,mn,Ne,De],styles:[".map-wrap[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column}.map-wrap.is-fullscreen[_ngcontent-%COMP%]{width:100vw;height:100vh;background:#fff;padding:.5rem;box-sizing:border-box}.map-host[_ngcontent-%COMP%]{width:100%;height:480px;border-radius:8px;background:#e9ecef;flex-shrink:0}@media(max-width:600px){.map-host[_ngcontent-%COMP%]{height:360px;border-radius:0}}.map-wrap.is-tall[_ngcontent-%COMP%]   .map-host[_ngcontent-%COMP%]{height:70vh}@media(max-width:600px){.map-wrap.is-tall[_ngcontent-%COMP%]   .map-host[_ngcontent-%COMP%]{height:60vh}}.map-wrap.is-fullscreen[_ngcontent-%COMP%]   .map-host[_ngcontent-%COMP%]{flex:1 1 auto;height:auto;border-radius:0}.overlay-panels[_ngcontent-%COMP%]{flex-shrink:0}.map-wrap.is-fullscreen[_ngcontent-%COMP%]   .overlay-panels[_ngcontent-%COMP%]{max-height:40vh;overflow-y:auto}.map-toolbar[_ngcontent-%COMP%]{position:absolute;top:.5rem;left:.5rem;z-index:5;display:flex;gap:.4rem}.create-toggle[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#fff;
47color:#1a5fb4;border-radius:4px;padding:.35rem .7rem;font-size:.8rem;cursor:pointer;box-shadow:0 1px 4px #00000026}.create-toggle.armed[_ngcontent-%COMP%]{background:#1a5fb4;color:#fff}.create-panel[_ngcontent-%COMP%]{margin-top:.75rem;padding:.75rem;background:#f8f9fa;border-radius:8px}.create-panel[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%]{margin:0 0 .5rem;font-size:.95rem}.edit-form[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:.75rem 1rem}.edit-form[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.2rem;font-size:.75rem;color:#666}.edit-form[_ngcontent-%COMP%]   input[type=text][_ngcontent-%COMP%], .edit-form[_ngcontent-%COMP%]   select[_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.3rem .4rem;font-size:.85rem;max-width:16rem}.label-row[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.5rem}.sort-toggle[_ngcontent-%COMP%]{appearance:none;border:none;background:none;color:#1a5fb4;font-size:.7rem;cursor:pointer;padding:0}.sort-toggle[_ngcontent-%COMP%]:hover{text-decoration:underline}.edit-actions[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.4rem}.btn-primary[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.btn-primary[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.edit-actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:not(.btn-primary){appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.form-error[_ngcontent-%COMP%]{flex-basis:100%;color:#b3261e;font-size:.8rem;margin:.3rem 0 0}.fclass-badge[_ngcontent-%COMP%]{display:inline-block;padding:.1rem .4rem;border-radius:3px;font-size:.75rem;font-weight:700;line-height:1.4}.move-armed-banner[_ngcontent-%COMP%]{display:flex;align-items:center;flex-wrap:wrap;gap:.4rem;margin-top:.75rem;padding:.6rem .75rem;background:#fff8e1;border:1px solid #f2d675;border-radius:8px;font-size:.85rem}.move-armed-banner[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.25rem .6rem;font-size:.8rem;cursor:pointer;margin-left:auto}.form-success[_ngcontent-%COMP%]{color:#2e7d32;font-size:.85rem;margin:.5rem 0 0}.layers-panel[_ngcontent-%COMP%]{position:absolute;top:2.7rem;left:.5rem;z-index:6;background:#fff;border-radius:8px;box-shadow:0 2px 10px #0003;padding:.6rem .8rem;font-size:.8rem;max-height:70%;overflow-y:auto;min-width:210px}.layers-panel-header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;margin-bottom:.4rem}.layers-close[_ngcontent-%COMP%]{appearance:none;border:none;background:none;font-size:1.1rem;line-height:1;cursor:pointer;color:#666;padding:0}.layers-section-title[_ngcontent-%COMP%]{font-weight:600;margin-bottom:.2rem;color:#555;font-size:.7rem;text-transform:uppercase;letter-spacing:.03em}.layers-row[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.4rem;padding:.15rem 0;cursor:pointer}.layers-row[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{margin:0}.layers-row-label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.4rem;cursor:pointer;flex:1 1 auto;min-width:0}.layers-row-name[_ngcontent-%COMP%]{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.only-btn[_ngcontent-%COMP%]{appearance:none;border:none;background:none;color:#1a5fb4;font-size:.68rem;cursor:pointer;padding:0 0 0 .3rem;visibility:hidden;flex-shrink:0}.layers-row[_ngcontent-%COMP%]:hover   .only-btn[_ngcontent-%COMP%]{visibility:visible}.only-btn[_ngcontent-%COMP%]:hover{text-decoration:underline}.expand-btn[_ngcontent-%COMP%]{appearance:none;border:none;background:none;color:#999;font-size:.65rem;cursor:pointer;padding:0;width:.9rem;flex-shrink:0;transform:rotate(0);transition:transform .1s ease}.expand-btn.expanded[_ngcontent-%COMP%]{transform:rotate(90deg)}.expand-btn[_ngcontent-%COMP%]:hover{color:#1a5fb4}.code-tree[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.1rem;padding:.1rem 0 .3rem 1.6rem}.code-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.35rem;font-size:.72rem;color:#555;padding:.1rem 0}.code-row-label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.35rem;cursor:pointer;flex:1 1 auto;min-width:0}.code-row[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{margin:0}.code-only-btn[_ngcontent-%COMP%]{padding:0 0 0 .3rem}.code-row[_ngcontent-%COMP%]:hover   .code-only-btn[_ngcontent-%COMP%]{visibility:visible}.code-label[_ngcontent-%COMP%]{font-family:monospace;color:#888;flex-shrink:0}
47.code-name[_ngcontent-%COMP%]{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.fclass-swatch[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:16px;padding:0 .15rem;border-radius:3px;font-size:.65rem;font-weight:700}.wiki-swatch[_ngcontent-%COMP%]{background:#777;color:#fff}.postal-swatch[_ngcontent-%COMP%]{background:#b5651d;color:#fff}.layers-divider[_ngcontent-%COMP%]{border-top:1px solid #eee;margin:.4rem 0}.wiki-lang-row[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:.25rem;margin-top:.3rem;padding-left:1.6rem}.lang-btn[_ngcontent-%COMP%]{appearance:none;border:1px solid #ccc;background:#fff;border-radius:3px;padding:.1rem .4rem;font-size:.7rem;cursor:pointer}.lang-btn.active[_ngcontent-%COMP%]{background:#1a5fb4;border-color:#1a5fb4;color:#fff}"]})};var pd=class e{http=h(Z);getHistory(n){let t=`/api/history?geonameId=${encodeURIComponent(n)}`;return this.http.get(t).pipe(N(i=>i.geoNameHistory??[]))}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var hk=(e,n)=>n.revision;function gk(e,n){e&1&&(l(0,"p",0),s(1,"Loading history\u2026"),a())}function Ck(e,n){e&1&&(l(0,"p",1),s(1,"Could not load history right now."),a())}function _k(e,n){if(e&1&&(l(0,"li")(1,"div",3)(2,"span",4),s(3),Be(4,"date"),a(),l(5,"a",5),s(6),a()(),l(7,"div",6),s(8),a()()),e&2){let t=n.$implicit,i=p(3);d(3),g(He(4,4,t.modificationTime,"MMM d, y, HH:mm:ss")),d(2),v("routerLink",i.userPath(t.userName)),d(),g(t.userName),d(2),g(t.comment)}}function vk(e,n){if(e&1&&(l(0,"ul",2),I(1,_k,9,7,"li",null,hk),a()),e&2){let t=p(2);d(),T(t.entries())}}function yk(e,n){e&1&&(l(0,"p",0),s(1,"No edit history yet."),a())}function bk(e,n){if(e&1&&y(0,vk,3,0,"ul",2)(1,yk,2,0,"p",0),e&2){let t=p();_(t.entries().length?0:1)}}var fd=class e{geonameId;active=!1;historyService=h(pd);state=E("loading");entries=E([]);userPath(n){return`/recent-changes/user/${encodeURIComponent(n)}`}ngOnChanges(n){(n.geonameId||n.active&&this.active)&&this.load()}load(){this.state.set("loading"),this.historyService.getHistory(this.geonameId).subscribe({next:n=>{this.entries.set(n),this.state.set("loaded")},error:()=>{this.state.set("error")}})}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-history-tab"]],inputs:{geonameId:"geonameId",active:"active"},features:[ct],decls:3,vars:1,consts:[[1,"placeholder"],[1,"placeholder","error"],[1,"history-list"],[1,"history-meta"],[1,"history-date"],[1,"history-user",3,"routerLink"],[1,"history-comment"]],template:function(t,i){if(t&1&&y(0,gk,2,0,"p",0)(1,Ck,2,0,"p",1)(2,bk,2,1),t&2){let o;_((o=i.state())==="loading"?0:o==="error"?1:o==="loaded"?2:-1)}},dependencies:[Ct,W],styles:[".placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.history-list[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;border-top:1px solid #e5e5e5}.history-list[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{padding:.65rem .25rem;border-bottom:1px solid #e5e5e5}.history-meta[_ngcontent-%COMP%]{display:flex;justify-content:space-between;gap:1rem;font-size:.8rem;color:#888}.history-user[_ngcontent-%COMP%]{font-weight:500;color:#1a5fb4;text-decoration:none}.history-user[_ngcontent-%COMP%]:hover{text-decoration:underline}.history-comment[_ngcontent-%COMP%]{margin-top:.15rem;font-size:.95rem}@media(max-width:600px){.history-meta[_ngcontent-%COMP%]{flex-direction:column;gap:.1rem}}"]})};var Sr=class e{http=h(Z);getAlternateNames(n){let t=`/api/alternate-names?geonameId=${encodeURIComponent(n)}`;return this.http.get(t).pipe(N(i=>i.geonames??[]))}saveAlternateName(n){return this.http.post("/api/alternate-names/save",n).pipe(N(t=>It(t)),St())}deleteAlternateName(n,t){return this.http.post("/api/alternate-names/delete",{geonameId:n,alternateNameId:t}).pipe(N(i=>It(i)),St())}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var i1=(e,n)=>n.alternateNameId;function xk(e,n){e&1&&(l(0,"p",1),s(1,"Loading alternate names\u2026"),a())}function Sk(e,n){e&1&&(l(0,"p",2),s(1,"Could not load alternate names right now."),a())}function wk(e,n){if(e&1&&(l(0,"p",30),s(1),a()),e&2){let t=p(3);d(),g(t.saveError())}}function Ek(e,n){if(e&1){let t=$();l(0,"td",16)(1,"div",17)(2,"label"),s(3,"Code "),l(4,"input",18),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.form.locale,o)||(r.form.locale=o),w(o)}),a()(),l(5,"label",19),s(6,"Name "),l(7,"input",20),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.form.name,o)||(r.form.name=o),w(o)}),a()(),l(8,"label",21)(9,"input",22),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.form.isOfficialName,o)||(r.form.isOfficialName=o),w(o)}),a(),s(10," official"),a(),l(11,"label",21)(12,"input",23),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.form.isShortName,o)||(r.form.isShortName=o),w(o)}),a(),s(13," short"),a(),l(14,"label",21)(15,"input",24),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.form.isHistoric,o)||(r.form.isHistoric=o),w(o)}),a(),s(16," historic"),a(),l(17,"label",21)(18,"input",25),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.form.isColloquial,o)||(r.form.isColloquial=o),w(o)}),a(),s(19," colloquial"),a(),l(20,"label"),s(21,"From "),l(22,"input",26),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.form.fromIso,o)||(r.form.fromIso=o),w(o)}),a()(),l(23,"label"),s(24,"To "),l(25,"input",27),F("ngModelChange",function(o){S(t);let r=p(2);return L(r.form.toIso,o)||(r.form.toIso=o),w(o)}),a()(),l(26,"div",28)(27,"button",6),M("click",function(){S(t);let o=p(2);
47return w(o.submitForm())}),s(28),a(),l(29,"button",29),M("click",function(){S(t);let o=p(2);return w(o.cancelEdit())}),s(30,"Cancel"),a()(),y(31,wk,2,1,"p",30),a()()}if(e&2){let t=p(2);d(4),R("ngModel",t.form.locale),d(3),R("ngModel",t.form.name),d(2),R("ngModel",t.form.isOfficialName),d(3),R("ngModel",t.form.isShortName),d(3),R("ngModel",t.form.isHistoric),d(3),R("ngModel",t.form.isColloquial),d(4),R("ngModel",t.form.fromIso),d(3),R("ngModel",t.form.toIso),d(2),v("disabled",t.saving()),d(),A(" ",t.saving()?"Saving\u2026":"Save"," "),d(),v("disabled",t.saving()),d(2),_(t.saveError()?31:-1)}}function Mk(e,n){if(e&1&&(l(0,"span",11),s(1),a()),e&2){let t=p(2);d(),g(t.sortDirection()==="asc"?"\u25B2":"\u25BC")}}function Pk(e,n){if(e&1&&(l(0,"span",11),s(1),a()),e&2){let t=p(2);d(),g(t.sortDirection()==="asc"?"\u25B2":"\u25BC")}}function Dk(e,n){if(e&1&&(l(0,"span",11),s(1),a()),e&2){let t=p(2);d(),g(t.sortDirection()==="asc"?"\u25B2":"\u25BC")}}function Ik(e,n){if(e&1&&(l(0,"tr",15),Ii(1,31),a()),e&2){p();let t=so(98);d(),v("ngTemplateOutlet",t)}}function Tk(e,n){if(e&1&&(l(0,"tr",15),Ii(1,31),a()),e&2){p(2);let t=so(98);d(),v("ngTemplateOutlet",t)}}function Ok(e,n){if(e&1&&(l(0,"code"),s(1),a()),e&2){let t=p(2).$implicit;d(),g(t.locale)}}function Nk(e,n){if(e&1&&(l(0,"a",36),s(1),a()),e&2){let t=p(2).$implicit;v("href",t.name,Y),d(),g(t.name)}}function kk(e,n){if(e&1&&(l(0,"a",36),s(1),a()),e&2){let t=p(2).$implicit;v("href","https://www.wikidata.org/wiki/"+t.name,Y),d(),g(t.name)}}function Ak(e,n){if(e&1&&(l(0,"span",37),s(1),a()),e&2){let t=p(2).$implicit;d(),g(t.name)}}function Rk(e,n){e&1&&(l(0,"span",39),s(1,"official"),a())}function Fk(e,n){e&1&&(l(0,"span",39),s(1,"short"),a())}function Lk(e,n){e&1&&(l(0,"span",39),s(1,"colloquial"),a())}function Vk(e,n){if(e&1&&(l(0,"span",42),s(1),a()),e&2){let t=p(3).$implicit,i=p(2);d(),g(i.dateRangeFor(t))}}function Uk(e,n){if(e&1&&(l(0,"span",41),s(1,"historic"),a(),y(2,Vk,2,1,"span",42)),e&2){let t=p(2).$implicit,i=p(2);d(2),_(i.dateRangeFor(t)?2:-1)}}function jk(e,n){if(e&1&&(l(0,"span",30),s(1),a()),e&2){let t=p(5);d(),g(t.deleteError())}}function Bk(e,n){if(e&1){let t=$();l(0,"span",43),s(1," Delete this name? "),l(2,"button",44),M("click",function(){S(t);let o=p(2).$implicit,r=p(2);return w(r.confirmDelete(o))}),s(3),a(),l(4,"button",29),M("click",function(){S(t);let o=p(4);return w(o.cancelDelete())}),s(5,"Cancel"),a()(),y(6,jk,2,1,"span",30)}if(e&2){let t=p(4);d(2),v("disabled",t.deleting()),d(),A(" ",t.deleting()?"Deleting\u2026":"Confirm"," "),d(),v("disabled",t.deleting()),d(2),_(t.deleteError()?6:-1)}}function Hk(e,n){if(e&1){let t=$();l(0,"button",29),M("click",function(){S(t);let o=p(2).$implicit,r=p(2);return w(r.startEdit(o))}),s(1,"Edit"),a(),l(2,"button",29),M("click",function(){S(t);let o=p(2).$implicit,r=p(2);return w(r.startDelete(o))}),s(3,"Delete"),a()}if(e&2){let t=p(4);v("disabled",t.editingId()!==null),d(2),v("disabled",t.editingId()!==null)}}function $k(e,n){if(e&1&&(l(0,"tr")(1,"td",32),y(2,Ok,2,1,"code"),a(),l(3,"td",33)(4,"span",34),s(5),a()(),l(6,"td",35),y(7,Nk,2,2,"a",36)(8,kk,2,2,"a",36)(9,Ak,2,1,"span",37),a(),l(10,"td",38),y(11,Rk,2,0,"span",39)(12,Fk,2,0,"span",39)(13,Lk,2,0,"span",39)(14,Uk,3,1),a(),l(15,"td",40),y(16,Bk,7,4)(17,Hk,4,2),a()()),e&2){let t=p().$implicit,i=p(2);d(2),_(t.locale?2:-1),d(2),v("title",t.displayLocale),d(),g(t.displayLocale),d(2),_(t.locale==="link"?7:t.locale==="wkdt"?8:9),d(4),_(t.isOfficialName?11:-1),d(),_(t.isShortName?12:-1),d(),_(t.isColloquial?13:-1),d(),_(t.isHistoric?14:-1),d(2),_(i.deletingId()===t.alternateNameId?16:17)}}function zk(e,n){if(e&1&&y(0,Tk,2,1,"tr",15)(1,$k,18,9,"tr"),e&2){let t=n.$implicit,i=p(2);_(i.editingId()===t.alternateNameId?0:1)}}function Gk(e,n){e&1&&(l(0,"tr")(1,"td",45),s(2,"No alternate names yet."),a()())}function Wk(e,n){if(e&1){let t=$();l(0,"span",43),s(1),l(2,"button",44),M("click",function(){S(t);let o=p().$implicit,r=p(3);return w(r.confirmDelete(o))}),s(3),a(),l(4,"button",29),M("click",function(){S(t);let o=p(4);return w(o.cancelDelete())}),s(5,"Cancel"),a()()}if(e&2){let t=p().$implicit,i=p(3);d(),A(" Delete ",t.name,"? "),d(),v("disabled",i.deleting()),d(),A(" ",i.deleting()?"Deleting\u2026":"Confirm"," "),d(),v("disabled",i.deleting())}}function qk(e,n){if(e&1){let t=$();s(0),l(1,"button",47),M("click",function(){S(t);let o=p().$implicit,r=p(3);return w(r.startDelete(o))}),s(2,"\xD7"),a()}if(e&2){let t=p().$implicit,i=p(3);A(" ",t.name," "),d(),v("disabled",i.editingId()!==null),_e("aria-label","Delete postal code "+t.name)}}function Jk(e,n){if(e&1&&(l(0,"li"),y(1,Wk,6,4,"span",43)(2,qk,3,3),a()),e&2){let t=n.$implicit,i=p(3);d(),_(i.deletingId()===t.alternateNameId?1:2)}}function Kk(e,n){if(e&1&&(l(0,"p",30),s(1),a()),e&2){let t=p(3);d(),g(t.deleteError())}}function Yk(e,n){if(e&1&&(l(0,"h2"),s(1,"Postal codes"),a(),l(2,"ul",46),I(3,Jk,3,1,"li",null,i1),a(),y(5,Kk,2,1,"p",30)),e&2){let t=p(2);d(3),T(t.postalCodes()),d(2),_(t.deleteError()&&t.deletingId()!==null?5:-1)}}function Zk(e,n){if(e&1){let t=$();l(0,"details",3)(1,"summary"),s(2,"What do these codes mean?"),a(),l(3,"p"),s(4,"The language code refers to the ISO-639-2 and ISO-639-3 codes."),a(),l(5,"ul",4)(6,"li")(7,"code"),s(8,"en"),a(),s(9," (english)"),a(),l(10,"li")(11,"code"),s(12,"fr"),a(),s(13," (french)"),a()(),l(14,"p"),s(15,"The language code may be followed by a hyphen and a country code or a country variant:"),a(),l(16,"ul",4)(17,"li")(18,"code"),s(19,"zh-CN"),a()(),l(20,"li")(21,"code"),s(22,"zh-Hant"),a()()(),l(23,"p"),s(24,"Accepted pseudo language codes:"),a(),l(25,"ul",4)(26,"li")(27,"code"),s(28,"post"),a(),s(29," (postal codes)"),a(),l(30,"li")(31,"code"),s(32,"icao"),a(),s(33,", "),l(34,"code"),s(35,"iata"),a(),s(36,", "),l(37,"code"),s(38,"faac"),a(),s(39,", "),l(40,"code"),s(41,"tcid"),a(),s(42," (airport codes)"),a(),l(43,"li")(44,"code"),s(45,"abbr"),a(),s(46," (abbreviation)"),a(),l(47,"li")(48,"code"),s(49,"link"),a(),s(50," (link to website)"),a(),l(51,"li")(52,"code"),s(53,"phon"),a(),s(54," (phonetics)"),a(),l(55,"li")(56,"code"),s(57,"piny"),a(),s(58," (pinyin)"),a(),l(59,"li")(60,"code"),s(61,"wkdt"),a(),s(62," (wikidataid)"),a(),l(63,"li")(64,"code"),s(65,"unlc"),a(),s(66," (UNLOCODE)"),a(),l(67,"li")(68,"code"),s(69,"nuts"),a(),s(70," (EU NUTS code)"),a(),l(71,"li")(72,"code"),s(73,"lauc"),a(),s(74," (EU LAU code)"),a()(),l(75,"ul",4)(76,"li")(77,"code"),s(78,"p."),a(),s(79," = preferred"),a(),l(80,"li")(81,"code"),s(82,"s."),a(),s(83," = short"),a(),l(84,"li")(85,"code"),s(86,"h."),a(),s(87," = historical"),a(),l(88,"li")(89,"code"),s(90,"c."),a(),s(91," = colloquial"),a()()(),l(92,"h2"),s(93,"Names in other languages"),a(),l(94,"div",5)(95,"button",6),M("click",function(){S(t);let o=p();return w(o.startCreate())}),s(96," + Add name "),a()(),y(97,Ek,32,12,"ng-template",null,0,Zo),l(99,"div",7)(100,"table",8)(101,"thead")(102,"tr")(103,"th",9)(104,"button",10),M("click",function(){S(t);let o=p();return w(o.toggleSort("code"))}),s(105," Code "),y(106,Mk,2,1,"span",11),a()(),l(107,"th",12)(108,"button",10),M("click",function(){S(t);let o=p();return w(o.toggleSort("locale"))}),s(109," Language "),y(110,Pk,2,1,"span",11),a()(),l(111,"th",12)(112,"button",10),M("click",function(){S(t);let o=p();return w(o.toggleSort("name"))}),s(113," Name "),y(114,Dk,2,1,"span",11),a()(),l(115,"th",13),s(116,"Tags"),a(),l(117,"th",14),s(118,"Actions"),a()()(),l(119,"tbody"),y(120,Ik,2,1,"tr",15),I(121,zk,2,1,null,null,i1),y(123,Gk,3,0,"tr"),a()()(),y(124,Yk,6,1)}if(e&2){let t=p();d(95),v("disabled",t.editingId()!==null),d(8),_e("aria-sort",t.sortColumn()==="code"?t.sortDirection()==="asc"?"ascending":"descending":"none"),d(3),_(t.sortColumn()==="code"?106:-1),d(),_e("aria-sort",t.sortColumn()==="locale"?t.sortDirection()==="asc"?"ascending":"descending":"none"),d(3),_(t.sortColumn()==="locale"?110:-1),d(),_e("aria-sort",t.sortColumn()==="name"?t.sortDirection()==="asc"?"ascending":"descending":"none"),d(3),_(t.sortColumn()==="name"?114:-1),d(6),_(t.editingId()==="new"?120:-1),d(),T(t.sortedLanguageNames()),d(2),_(!t.languageNames().length&&t.editingId()!=="new"?123:-1),d(),_(t.postalCodes().length?124:-1)}}
47function n1(){return{locale:"",name:"",isOfficialName:!1,isShortName:!1,isHistoric:!1,isColloquial:!1,fromIso:"",toIso:""}}var hd=class e{geonameId;alternateNamesService=h(Sr);state=E("loading");entries=E([]);sortColumn=E("locale");sortDirection=E("asc");editingId=E(null);form=n1();saving=E(!1);saveError=E(null);deletingId=E(null);deleting=E(!1);deleteError=E(null);languageNames=G(()=>this.entries().filter(n=>n.locale!=="post"));postalCodes=G(()=>this.entries().filter(n=>n.locale==="post"));sortedLanguageNames=G(()=>{let n=this.sortColumn(),t=this.sortDirection()==="asc"?1:-1,i=o=>{switch(n){case"code":return o.locale;case"locale":return o.displayLocale;case"name":return o.name}};return[...this.languageNames()].sort((o,r)=>i(o).localeCompare(i(r))*t)});ngOnChanges(n){n.geonameId&&(this.editingId.set(null),this.deletingId.set(null),this.load())}toggleSort(n){this.sortColumn()===n?this.sortDirection.set(this.sortDirection()==="asc"?"desc":"asc"):(this.sortColumn.set(n),this.sortDirection.set("asc"))}dateRangeFor(n){return n.fromIso&&n.toIso?`${n.fromIso}\u2013${n.toIso}`:n.fromIso?`from ${n.fromIso}`:n.toIso?`until ${n.toIso}`:""}startCreate(){this.editingId.set("new"),this.form=n1(),this.saveError.set(null)}startEdit(n){this.editingId.set(n.alternateNameId),this.form={locale:n.locale,name:n.name,isOfficialName:n.isOfficialName,isShortName:n.isShortName,isHistoric:n.isHistoric,isColloquial:n.isColloquial,fromIso:n.fromIso??"",toIso:n.toIso??""},this.saveError.set(null)}cancelEdit(){this.editingId.set(null),this.saveError.set(null)}submitForm(){let n=this.editingId();if(n===null)return;this.saving.set(!0),this.saveError.set(null);let t={geonameId:this.geonameId,alternateNameId:n==="new"?0:n,alternateName:this.form.name,alternateNameLocale:this.form.locale,isOfficialName:this.form.isOfficialName,isShortName:this.form.isShortName,isHistoric:this.form.isHistoric,isColloquial:this.form.isColloquial,fromIso:this.form.fromIso,toIso:this.form.toIso};this.alternateNamesService.saveAlternateName(t).subscribe({next:()=>{this.saving.set(!1),this.editingId.set(null),this.load()},error:i=>{this.saving.set(!1),this.saveError.set(i?.message??"Could not save this name.")}})}startDelete(n){this.deletingId.set(n.alternateNameId),this.deleteError.set(null)}cancelDelete(){this.deletingId.set(null),this.deleteError.set(null)}confirmDelete(n){this.deleting.set(!0),this.alternateNamesService.deleteAlternateName(this.geonameId,n.alternateNameId).subscribe({next:()=>{this.deleting.set(!1),this.deletingId.set(null),this.load()},error:t=>{this.deleting.set(!1),this.deleteError.set(t?.message??"Could not delete this name.")}})}load(){this.state.set("loading"),this.alternateNamesService.getAlternateNames(this.geonameId).subscribe({next:n=>{this.entries.set(n),this.state.set("loaded")},error:()=>{this.state.set("error")}})}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-alternate-names-tab"]],inputs:{geonameId:"geonameId"},features:[ct],decls:3,vars:1,consts:[["entryForm",""],[1,"placeholder"],[1,"placeholder","error"],[1,"help"],[1,"help-list"],[1,"table-actions"],["type","button",1,"btn-primary",3,"click","disabled"],[1,"table-scroll"],[1,"name-table"],["scope","col",1,"code-col"],["type","button",3,"click"],[1,"sort-arrow"],["scope","col"],["scope","col",1,"tags-col"],["scope","col",1,"actions-col"],[1,"edit-row"],["colspan","5"],[1,"edit-form"],["type","text","name","locale","size","10","placeholder","en, zh-CN\u2026",3,"ngModelChange","ngModel"],[1,"name-field"],["type","text","name","name",3,"ngModelChange","ngModel"],[1,"checkbox"],["type","checkbox","name","isOfficialName",3,"ngModelChange","ngModel"],["type","checkbox","name","isShortName",3,"ngModelChange","ngModel"],["type","checkbox","name","isHistoric",3,"ngModelChange","ngModel"],["type","checkbox","name","isColloquial",3,"ngModelChange","ngModel"],["type","text","name","fromIso","size","8","placeholder","YYYY",3,"ngModelChange","ngModel"],["type","text","name","toIso","size","8","placeholder","YYYY",3,"ngModelChange","ngModel"],[1,"edit-actions"],["type","button",3,"click","disabled"],[1,"form-error"],[3,"ngTemplateOutlet"],[1,"code-col"],[1,"locale"],[1,"locale-text",3,"title"],[1,"name-col"],["target","_blank","rel","noopener noreferrer",1,"name",3,"href"],[1,"name"],[1,"tags-col"],[1,"badge"],[1,"actions-col"],[1,"badge","historic"],[1,"date-range"],[1,"delete-confirm"],["type","button",1,"btn-danger",3,"click","disabled"],["colspan","5",1,"placeholder"],[1,"postal-list"],["type","button","title","Delete",1,"postal-delete",3,"click","disabled"]],template:function(t,i){if(t&1&&y(0,xk,2,0,"p",1)(1,Sk,2,0,"p",2)(2,Zk,125,10),t&2){let o;_((o=i.state())==="loading"?0:o==="error"?1:o==="loaded"?2:-1)}},dependencies:[ke,Me,pi,Ne,De,co],styles:[".placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.help[_ngcontent-%COMP%]{margin-bottom:1.25rem;border:1px solid #e5e5e5;border-radius:8px;padding:.6rem .9rem;font-size:.85rem;color:#555}.help[_ngcontent-%COMP%]   summary[_ngcontent-%COMP%]{cursor:pointer;font-weight:500;
47color:#1a5fb4}.help[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.6rem 0 .3rem}.help-list[_ngcontent-%COMP%]{list-style:none;margin:0 0 .5rem;padding:0;display:flex;flex-wrap:wrap;gap:.4rem 1rem}.help[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:#f0f0f0;border-radius:3px;padding:.05rem .3rem;font-size:.8rem}h2[_ngcontent-%COMP%]{font-size:1.05rem;margin:1.25rem 0 .5rem}h2[_ngcontent-%COMP%]:first-child{margin-top:0}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto}.name-table[_ngcontent-%COMP%]{width:100%;border-collapse:collapse;font-size:.9rem}.name-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .name-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.45rem .5rem;border-bottom:1px solid #e5e5e5;text-align:left;white-space:nowrap}.name-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;color:#777}.name-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n):not(.edit-row){background:#fafbfc}.name-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover:not(.edit-row){background:#eef2f7}.name-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:none;background:none;font:inherit;text-transform:inherit;letter-spacing:inherit;color:inherit;cursor:pointer;padding:0;display:inline-flex;align-items:center;gap:.3rem}.name-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:hover{color:#1a5fb4}.sort-arrow[_ngcontent-%COMP%]{font-size:.65rem}.code-col[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:#f0f0f0;border-radius:3px;padding:.05rem .3rem;font-size:.8rem}.tags-col[_ngcontent-%COMP%]{white-space:normal}.date-range[_ngcontent-%COMP%]{font-size:.75rem;color:#8a6d00;margin-left:.3rem}.locale[_ngcontent-%COMP%]{color:#666}.locale-text[_ngcontent-%COMP%]{display:inline-block;max-width:8rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:bottom}.name-col[_ngcontent-%COMP%]{white-space:normal}.name[_ngcontent-%COMP%]{font-weight:500;white-space:normal;word-break:break-word}a.name[_ngcontent-%COMP%]{color:#1a5fb4}.badge[_ngcontent-%COMP%]{font-size:.7rem;text-transform:uppercase;letter-spacing:.03em;color:#1a5fb4;background:#e8f0fb;border-radius:4px;padding:.1rem .4rem}.badge.historic[_ngcontent-%COMP%]{color:#8a6d00;background:#fbf3d9}.table-actions[_ngcontent-%COMP%]{margin-bottom:.5rem}.actions-col[_ngcontent-%COMP%]{white-space:nowrap}.actions-col[_ngcontent-%COMP%]   button[_ngcontent-%COMP%], .delete-confirm[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.2rem .55rem;font-size:.8rem;cursor:pointer;margin-right:.3rem}.actions-col[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:hover{border-color:#1a5fb4;color:#1a5fb4}.actions-col[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.btn-primary[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.btn-primary[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.actions-col[_ngcontent-%COMP%]   .btn-danger[_ngcontent-%COMP%], .delete-confirm[_ngcontent-%COMP%]   .btn-danger[_ngcontent-%COMP%]{border-color:#b3261e;background:#b3261e;color:#fff}.actions-col[_ngcontent-%COMP%]   .btn-danger[_ngcontent-%COMP%]:hover, .delete-confirm[_ngcontent-%COMP%]   .btn-danger[_ngcontent-%COMP%]:hover{border-color:#8f1e18;background:#8f1e18;color:#fff}.delete-confirm[_ngcontent-%COMP%]{font-size:.85rem;color:#555}.edit-row[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{background:#f8f9fa;white-space:normal}.edit-form[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:center;gap:.6rem 1rem;padding:.5rem 0}.edit-form[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.3rem;font-size:.8rem;color:#555}.edit-form[_ngcontent-%COMP%]   label.checkbox[_ngcontent-%COMP%]{flex-direction:row-reverse}.edit-form[_ngcontent-%COMP%]   input[type=text][_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.25rem .4rem;font-size:.85rem}.name-field[_ngcontent-%COMP%]{flex-grow:1;min-width:10rem}.name-field[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{width:100%}.edit-actions[_ngcontent-%COMP%]{display:flex;gap:.4rem;margin-left:auto}.form-error[_ngcontent-%COMP%]{flex-basis:100%;color:#b3261e;font-size:.8rem;margin:.3rem 0 0}.postal-list[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:.4rem}.postal-list[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.35rem;font-size:.85rem;background:#f8f9fa;border-radius:4px;
47padding:.25rem .55rem}.postal-delete[_ngcontent-%COMP%]{appearance:none;border:none;background:none;color:#999;font-size:.95rem;line-height:1;cursor:pointer;padding:0}.postal-delete[_ngcontent-%COMP%]:hover{color:#b3261e}.postal-delete[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}@media(max-width:600px){.locale-text[_ngcontent-%COMP%]{max-width:4.5rem}.tags-col[_ngcontent-%COMP%]{display:none}.name-col[_ngcontent-%COMP%]{min-width:7rem}.actions-col[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{padding:.2rem .4rem;font-size:.75rem;margin-right:.15rem}}"]})};var gd=class e{http=h(Z);getRelations(n,t){let i=`/api/hierarchy/relations?geonameId=${encodeURIComponent(n)}&isTopDown=${t}`;return this.http.get(i).pipe(N(o=>(o.geonames??[]).map(r=>({hierarchyId:r.hierarchyId,place:{id:String(r.geoName.geoNameId),name:r.geoName.name,featureClass:r.geoName.featureClass,featureCode:r.geoName.featureCode,path:new URL(r.geoName.url).pathname}}))))}createRelation(n,t,i){let o=new URLSearchParams({newPlaceId:n,currentPlaceId:t,isTopDown:String(i)});return this.http.get(`/api/hierarchy/create-relation?${o.toString()}`).pipe(N(r=>It(r)),St())}deleteRelation(n){let t=new URLSearchParams({hierarchyId:n});return this.http.get(`/api/hierarchy/delete-relation?${t.toString()}`).pipe(N(i=>It(i)),St())}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var Qk={ADM1:"adminCode1",ADM2:"adminCode2",ADM3:"adminCode3",ADM4:"adminCode4",ADM5:"adminCode5"},Cd=class e{http=h(Z);getCountries(){return this.http.get("/api/admin-hierarchy/countries").pipe(N(n=>(n.geonames??[]).filter(t=>t.code&&t.name).map(t=>({code:t.code,name:t.name}))))}getAdminOptions(n,t){let i=new URLSearchParams({featureCode:n});t.country&&i.set("country",t.country),t.adminCode1&&i.set("adminCode1",t.adminCode1),t.adminCode2&&i.set("adminCode2",t.adminCode2),t.adminCode3&&i.set("adminCode3",t.adminCode3),t.adminCode4&&i.set("adminCode4",t.adminCode4);let o=Qk[n];return this.http.get(`/api/admin-hierarchy/options?${i.toString()}`).pipe(N(r=>(r.geonames??[]).map(c=>({code:c[o]??"",name:c.name??""}))))}updateCountry(n,t){let i=new URLSearchParams({geonameId:n,country:t});return this.http.get(`/api/admin-hierarchy/update-country?${i.toString()}`).pipe(St())}updateAdminCode(n,t,i){let o=new URLSearchParams({geonameId:n,level:String(t),dottedCode:i});return this.http.get(`/api/admin-hierarchy/update-admin-code?${o.toString()}`).pipe(St())}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};function _d(e){return e.adminCode5||e.adminCode4||e.adminCode3||e.adminCode2||e.adminCode1}var Xk=(e,n)=>n.id,wr=(e,n)=>n.code,eA=(e,n)=>n.hierarchyId;function tA(e,n){if(e&1&&(l(0,"span",8),s(1),a()),e&2){let t=p().$implicit,i=p(2);Te("background-color",i.featureClassColors[t.featureClass]==null?null:i.featureClassColors[t.featureClass].background)("color",i.featureClassColors[t.featureClass]==null?null:i.featureClassColors[t.featureClass].color),d(),g(t.featureCode)}}function nA(e,n){if(e&1&&(l(0,"sup",9),s(1),a()),e&2){let t=p().$implicit;d(),g(t.code)}}function iA(e,n){if(e&1&&(l(0,"li"),j(1,"span",7),l(2,"span",8),s(3),a(),y(4,tA,2,5,"span",12),l(5,"a",13),s(6),a(),y(7,nA,2,1,"sup",9),l(8,"span",10),s(9),a()()),e&2){let t=n.$implicit,i=n.$index,o=p(2);Te("padding-left",i*1.1,"rem"),d(2),Te("background-color",o.featureClassColors[t.featureClass]==null?null:o.featureClassColors[t.featureClass].background)("color",o.featureClassColors[t.featureClass]==null?null:o.featureClassColors[t.featureClass].color),d(),g(t.featureClass),d(),_(t.featureCode?4:-1),d(),v("routerLink",o.pathFor(t)),d(),g(t.name),d(),_(t.code?7:-1),d(2),g(t.featureLabel)}}function oA(e,n){e&1&&(l(0,"sup",9),s(1),a()),e&2&&(d(),g(n))}function rA(e,n){if(e&1&&(l(0,"p",15),s(1),a()),e&2){let t=p(3);d(),g(t.adminSaveSuccess())}}function aA(e,n){if(e&1){let t=$();l(0,"button",14),M("click",function(){S(t);let o=p(2);return w(o.startEditAdmin())}),s(1,"Edit administrative hierarchy"),a(),y(2,rA,2,1,"p",15)}if(e&2){let t=p(2);d(2),_(t.adminSaveSuccess()?2:-1)}}function sA(e,n){e&1&&(l(0,"p",16),s(1,"Loading options\u2026"),a())}function lA(e,n){if(e&1&&(l(0,"option",22),s(1),a()),e&2){let t=n.$implicit;v("value",t.code),d(),le("",t.name," (",t.code,")")}}function cA(e,n){if(e&1&&(l(0,"option",22),s(1),a()),e&2){let t=n.$implicit;v("value",t.code),d(),le("",t.name," (",t.code,")")}}function dA(e,n){if(e&1&&(l(0,"option",22),s(1),a()),e&2){let t=n.$implicit;v("value",t.code),d(),le("",t.name," (",t.code,")")}}function uA(e,n){if(e&1&&(l(0,"option",22),s(1),a()),e&2){let t=n.$implicit;v("value",t.code),d(),le("",t.name," (",t.code,")")}}function mA(e,n){if(e&1&&(l(0,"option",22),s(1),a()),e&2){let t=n.$implicit;v("value",t.code),d(),le("",t.name," (",t.code,")")}}function pA(e,n){if(e&1&&(l(0,"option",22),s(1),a()),e&2){let t=n.$implicit;v("value",t.code),d(),le("",t.name," (",t.code,")")}}function fA(e,n){if(e&1&&(l(0,"p",31),s(1),a()),e&2){let t=p(4);d(),g(t.adminSaveError())}}function hA(e,n){if(e&1){let t=$();l(0,"div",17)(1,"div",18),j(2,"span",7),l(3,"label")(4,"span",19),s(5,"Country"),a(),l(6,"select",20),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.selectedCountry,o)||(r.selectedCountry=o),w(o)}),M("ngModelChange",function(){S(t);let o=p(3);return w(o.onCountryChange())}),l(7,"option",21),s(8,"no country"),a(),I(9,lA,2,3,"option",22,wr),a()()(),l(11,"div",18),j(12,"span",7),l(13,"label")(14,"span",19),s(15,"First-order division "),l(16,"small"),s(17,"(admin1)"),a()(),l(18,"select",23),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.selectedAdm1,o)||(r.selectedAdm1=o),w(o)}),M("ngModelChange",function(){S(t);let o=p(3);return w(o.onAdm1Change())}),l(19,"option",21),s(20,"none"),a(),I(21,cA,2,3,"option",22,wr),a()()(),l(23,"div",18),j(24,"span",7),l(25,"label")(26,"span",19),s(27,"Second-order division "),l(28,"small"),s(29,"(admin2)"),a()(),l(30,"select",24),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.selectedAdm2,o)||(r.selectedAdm2=o),w(o)}),M("ngModelChange",function(){S(t);let o=p(3);return w(o.onAdm2Change())}),l(31,"option",21),s(32,"none"),a(),I(33,dA,2,3,"option",22,wr),a()()(),l(35,"div",18),j(36,"span",7),l(37,"label")(38,"span",19),s(39,"Third-order division "),l(40,"small"),s(41,"(admin3)"),a()(),l(42,"select",25),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.selectedAdm3,o)||(r.selectedAdm3=o),w(o)}),M("ngModelChange",function(){S(t);let o=p(3);return w(o.onAdm3Change())}),l(43,"option",21),s(44,"none"),a(),I(45,uA,2,3,"option",22,wr),a()()(),l(47,"div",18),j(48,"span",7),l(49,"label")(50,"span",19),s(51,"Fourth-order division "),l(52,"small"),s(53,"(admin4)"),a()(),l(54,"select",26),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.selectedAdm4,o)||(r.selectedAdm4=o),w(o)}),M("ngModelChange",function(){S(t);let o=p(3);return w(o.onAdm4Change())}),l(55,"option",21),s(56,"none"),a(),I(57,mA,2,3,"option",22,wr),a()()(),l(59,"div",18),j(60,"span",7),l(61,"label")(62,"span",19),s(63,"Fifth-order division "),l(64,"small"),s(65,"(admin5)"),a()(),l(66,"select",27),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.selectedAdm5,o)||(r.selectedAdm5=o),w(o)}),l(67,"option",21),s(68,"none"),a(),I(69,pA,2,3,"option",22,wr),a()()()(),l(71,"div",28)(72,"button",29),M("click",function(){S(t);let o=p(3);return w(o.saveAdminHierarchy())}),s(73),a(),l(74,"button",30),M("click",function(){S(t);let o=p(3);return w(o.cancelEditAdmin())}),s(75,"Cancel"),a()(),y(76,fA,2,1,"p",31)}if(e&2){let t=p(3);d(6),R("ngModel",t.selectedCountry),d(3),T(t.countryOptions()),d(2),Te("padding-left",1.1,"rem"),d(7),R("ngModel",t.selectedAdm1),v("disabled",!t.selectedCountry),d(3),T(t.adm1Options()),d(2),Te("padding-left",2.2,"rem"),d(7),R("ngModel",t.selectedAdm2),v("disabled",!t.selectedAdm1),d(3),T(t.adm2Options()),d(2),Te("padding-left",3.3,"rem"),d(7),R("ngModel",t.selectedAdm3),v("disabled",!t.selectedAdm2),d(3),T(t.adm3Options()),d(2),Te("padding-left",4.4,"rem"),d(7),R("ngModel",t.selectedAdm4),v("disabled",!t.selectedAdm3),d(3),T(t.adm4Options()),d(2),Te("padding-left",5.5,"rem"),d(7),R("ngModel",t.selectedAdm5),v("disabled",!t.selectedAdm4),d(3),T(t.adm5Options()),d(3),v("disabled",t.adminSaving()),d(),A(" ",t.adminSaving()?"Saving\u2026":"Save"," "),d(),v("disabled",t.adminSaving()),d(2),_(t.adminSaveError()?76:-1)}}function gA(e,n){if(e&1&&(l(0,"div",11),y(1,sA,2,0,"p",16)(2,hA,77,25),a()),e&2){let t=p(2);d(),_(t.adminLoading()?1:2)}}function CA(e,n){if(e&1&&(l(0,"ol",4),I(1,iA,10,12,"li",5,Xk),l(3,"li",6),j(4,"span",7),l(5,"span",8),s(6),a(),l(7,"span",8),s(8),a(),s(9),y(10,oA,2,1,"sup",9),l(11,"span",10),s(12),a()()(),y(13,aA,3,1)(14,gA,3,1,"div",11)),e&2){let t,i=p();d(),T(i.ancestors),d(2),Te("padding-left",i.ancestors.length*1.1,"rem"),d(2),Te("background-color",i.featureClassColors[i.place.featureClass]==null?null:i.featureClassColors[i.place.featureClass].background)("color",i.featureClassColors[i.place.featureClass]==null?null:i.featureClassColors[i.place.featureClass].color),d(),g(i.place.featureClass),d(),Te("background-color",i.featureClassColors[i.place.featureClass]==null?null:i.featureClassColors[i.place.featureClass].background)("color",i.featureClassColors[i.place.featureClass]==null?null:i.featureClassColors[i.place.featureClass].color),d(),g(i.place.featureCode),d(),A(" ",i.place.name," "),d(),_((t=i.currentAdminCode(i.place))?10:-1,t),d(2),g(i.place.featureLabel),d(),_(i.editingAdmin()?14:13)}}function _A(e,n){if(e&1&&Ii(0,3),e&2){p();let t=so(10);v("ngTemplateOutlet",t)}}function vA(e,n){e&1&&(l(0,"p",16),s(1,"Loading\u2026"),a())}function yA(e,n){e&1&&(l(0,"p",33),s(1,"Could not load this right now."),a())}function bA(e,n){if(e&1&&(l(0,"p",31),s(1),a()),e&2){let t=p(4);d(),g(t.relationError())}}function xA(e,n){if(e&1){let t=$();l(0,"tr",37)(1,"td",38)(2,"div",39)(3,"label"),s(4,"GeoNameId "),l(5,"input",40),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.newRelationId,o)||(r.newRelationId=o),w(o)}),a()(),l(6,"div",41)(7,"button",29),M("click",function(){S(t);let o=p(3);return w(o.submitAddRelation())}),s(8),a(),l(9,"button",30),M("click",function(){S(t);let o=p(3);return w(o.cancelAddRelation())}),s(10,"Cancel"),a()(),y(11,bA,2,1,"p",31),a()()()}if(e&2){let t=p(3);d(5),R("ngModel",t.newRelationId),d(2),v("disabled",t.relationSaving()),d(),A(" ",t.relationSaving()?"Saving\u2026":"Save"," "),d(),v("disabled",t.relationSaving()),d(2),_(t.relationError()?11:-1)}}function SA(e,n){if(e&1&&(l(0,"span",31),s(1),a()),e&2){let t=p(5);d(),g(t.deleteError())}}function wA(e,n){if(e&1){let t=$();l(0,"span",44),s(1," Delete this relation? "),l(2,"button",45),M("click",function(){S(t);let o=p().$implicit,r=p(3);return w(r.confirmDeleteRelation(o))}),s(3),a(),l(4,"button",30),M("click",function(){S(t);let o=p(4);return w(o.cancelDeleteRelation())}),s(5,"Cancel"),a()(),y(6,SA,2,1,"span",31)}if(e&2){let t=p(4);d(2),v("disabled",t.relationDeleting()),d(),A(" ",t.relationDeleting()?"Deleting\u2026":"Confirm"," "),d(),v("disabled",t.relationDeleting()),d(2),_(t.deleteError()?6:-1)}}function EA(e,n){if(e&1){let t=$();l(0,"button",30),M("click",function(){S(t);let o=p().$implicit,r=p(3);return w(r.startDeleteRelation(o))}),s(1,"Delete"),a()}if(e&2){let t=p(4);v("disabled",t.addingRelation())}}function MA(e,n){if(e&1&&(l(0,"tr")(1,"td",36)(2,"span",8),s(3),a(),l(4,"code"),s(5),a()(),l(6,"td")(7,"a",13),s(8),a()(),l(9,"td",42),y(10,wA,7,4)(11,EA,2,1,"button",43),a()()),e&2){let t=n.$implicit,i=p(3);d(2),Te("background-color",i.featureClassColors[t.place.featureClass]==null?null:i.featureClassColors[t.place.featureClass].background)("color",i.featureClassColors[t.place.featureClass]==null?null:i.featureClassColors[t.place.featureClass].color),d(),g(t.place.featureClass),d(2),g(t.place.featureCode),d(2),v("routerLink",t.place.path),d(),g(t.place.name),d(2),_(i.deletingHierarchyId()===t.hierarchyId?10:11)}}function PA(e,n){if(e&1&&(l(0,"tr")(1,"td",46),s(2),a()()),e&2){let t=p(3);d(2),A(" No ",t.innerTab()==="children"?"additional child":"additional parent"," relations. ")}}function DA(e,n){if(e&1&&(l(0,"div",34)(1,"table",35)(2,"thead")(3,"tr")(4,"th",36),s(5,"Feature"),a(),l(6,"th"),s(7,"Name"),a(),l(8,"th"),s(9,"Actions"),a()()(),l(10,"tbody"),y(11,xA,12,5,"tr",37),I(12,MA,12,9,"tr",null,eA),y(14,PA,3,1,"tr"),a()()()),e&2){let t=p(2);d(11),_(t.addingRelation()?11:-1),d(),T(t.relations()),d(2),_(!t.relations().length&&!t.addingRelation()?14:-1)}}function IA(e,n){if(e&1){let t=$();l(0,"div",32)(1,"button",29),M("click",function(){S(t);let o=p();return w(o.startAddRelation())}),s(2),a()(),y(3,vA,2,0,"p",16)(4,yA,2,0,"p",33)(5,DA,15,2,"div",34)}if(e&2){let t,i=p();d(),v("disabled",i.addingRelation()),d(),A(" + Add ",i.innerTab()==="children"?"child":"parent"," "),d(),_((t=i.relationsState())==="loading"?3:t==="error"?4
47:t==="loaded"?5:-1)}}var vd=class e{place;ancestors;hierarchyChanged=new je;hierarchyService=h(gd);adminHierarchyService=h(Cd);places=h(tt);featureClassColors=Dn;currentAdminCode=_d;innerTab=E("admin");parentsState=E("idle");childrenState=E("idle");parents=E([]);children=E([]);relationsState=G(()=>this.innerTab()==="children"?this.childrenState():this.parentsState());relations=G(()=>this.innerTab()==="children"?this.children():this.parents());addingRelation=E(!1);newRelationId="";relationSaving=E(!1);relationError=E(null);deletingHierarchyId=E(null);relationDeleting=E(!1);deleteError=E(null);editingAdmin=E(!1);adminLoading=E(!1);adminSaving=E(!1);adminSaveError=E(null);adminSaveSuccess=E(null);countryOptions=E([]);adm1Options=E([]);adm2Options=E([]);adm3Options=E([]);adm4Options=E([]);adm5Options=E([]);selectedCountry="";selectedAdm1="";selectedAdm2="";selectedAdm3="";selectedAdm4="";selectedAdm5="";ngOnChanges(n){n.place&&(this.innerTab.set("admin"),this.parentsState.set("idle"),this.childrenState.set("idle"),this.editingAdmin.set(!1),this.adminSaveSuccess.set(null),this.addingRelation.set(!1),this.deletingHierarchyId.set(null))}selectInnerTab(n){this.innerTab.set(n),this.loadRelationsIfNeeded()}pathFor(n){return this.places.path(n)}loadRelationsIfNeeded(){let n=this.innerTab();if(n==="admin")return;let t=n==="children",i=t?this.childrenState:this.parentsState,o=t?this.children:this.parents;i()==="idle"&&(i.set("loading"),this.hierarchyService.getRelations(this.place.id,t).subscribe({next:r=>{o.set(r),i.set("loaded")},error:()=>i.set("error")}))}reloadRelations(){(this.innerTab()==="children"?this.childrenState:this.parentsState).set("idle"),this.loadRelationsIfNeeded()}startAddRelation(){this.addingRelation.set(!0),this.newRelationId="",this.relationError.set(null)}cancelAddRelation(){this.addingRelation.set(!1),this.relationError.set(null)}submitAddRelation(){let n=this.innerTab()==="children";this.relationSaving.set(!0),this.relationError.set(null),this.hierarchyService.createRelation(this.newRelationId.trim(),this.place.id,n).subscribe({next:()=>{this.relationSaving.set(!1),this.addingRelation.set(!1),this.reloadRelations()},error:t=>{this.relationSaving.set(!1),this.relationError.set(t?.message??"Could not save this relation.")}})}startDeleteRelation(n){this.deletingHierarchyId.set(n.hierarchyId),this.deleteError.set(null)}cancelDeleteRelation(){this.deletingHierarchyId.set(null),this.deleteError.set(null)}confirmDeleteRelation(n){this.relationDeleting.set(!0),this.hierarchyService.deleteRelation(n.hierarchyId).subscribe({next:()=>{this.relationDeleting.set(!1),this.deletingHierarchyId.set(null),this.reloadRelations()},error:t=>{this.relationDeleting.set(!1),this.deleteError.set(t?.message??"Could not delete this relation.")}})}startEditAdmin(){return wt(this,null,function*(){this.editingAdmin.set(!0),this.adminSaveError.set(null),this.adminSaveSuccess.set(null),this.adminLoading.set(!0);try{let n=yield vt(this.adminHierarchyService.getCountries());this.countryOptions.set(n),this.selectedCountry=this.place.countryCode??"";let t=yield vt(this.adminHierarchyService.getAdminOptions("ADM1",{country:this.selectedCountry}));this.adm1Options.set(t),this.selectedAdm1=this.place.adminCode1??"";let i=yield vt(this.adminHierarchyService.getAdminOptions("ADM2",{country:this.selectedCountry,adminCode1:this.selectedAdm1}));this.adm2Options.set(i),this.selectedAdm2=this.place.adminCode2??"";let o=yield vt(this.adminHierarchyService.getAdminOptions("ADM3",{country:this.selectedCountry,adminCode1:this.selectedAdm1,adminCode2:this.selectedAdm2}));this.adm3Options.set(o),this.selectedAdm3=this.place.adminCode3??"";let r=yield vt(this.adminHierarchyService.getAdminOptions("ADM4",{country:this.selectedCountry,adminCode1:this.selectedAdm1,adminCode2:this.selectedAdm2,adminCode3:this.selectedAdm3}));this.adm4Options.set(r),this.selectedAdm4=this.place.adminCode4??"";let c=yield vt(this.adminHierarchyService.getAdminOptions("ADM5",{country:this.selectedCountry,adminCode1:this.selectedAdm1,adminCode2:this.selectedAdm2,adminCode3:this.selectedAdm3,adminCode4:this.selectedAdm4}));this.adm5Options.set(c),this.selectedAdm5=this.place.adminCode5??""}finally{this.adminLoading.set(!1)}})}cancelEditAdmin(){this.editingAdmin.set(!1),this.adminSaveError.set(null),this.adminSaveSuccess.set(null)}onCountryChange(){this.selectedAdm1=this.selectedAdm2=this.selectedAdm3=this.selectedAdm4=this.selectedAdm5="",this.adm2Options.set([]),this.adm3Options.set([]),this.adm4Options.set([]),this.adm5Options.set([]),this.adminHierarchyService.getAdminOptions("ADM1",{country:this.selectedCountry}).subscribe(n=>this.adm1Options.set(n))}onAdm1Change(){this.selectedAdm2=this.selectedAdm3=this.selectedAdm4=this.selectedAdm5="",this.adm3Options.set([]),this.adm4Options.set([]),this.adm5Options.set([]),this.adminHierarchyService.getAdminOptions("ADM2",{country:this.selectedCountry,adminCode1:this.selectedAdm1}).subscribe(n=>this.adm2Options.set(n))}onAdm2Change(){this.selectedAdm3=this.selectedAdm4=this.selectedAdm5="",this.adm4Options.set([]),this.adm5Options.set([]),this.adminHierarchyService.getAdminOptions("ADM3",{country:this.selectedCountry,adminCode1:this.selectedAdm1,adminCode2:this.selectedAdm2}).subscribe(n=>this.adm3Options.set(n))}onAdm3Change(){this.selectedAdm4=this.selectedAdm5="",this.adm5Options.set([]),this.adminHierarchyService.getAdminOptions("ADM4",{country:this.selectedCountry,adminCode1:this.selectedAdm1,adminCode2:this.selectedAdm2,adminCode3:this.selectedAdm3}).subscribe(n=>this.adm4Options.set(n))}onAdm4Change(){this.selectedAdm5="",this.adminHierarchyService.getAdminOptions("ADM5",{country:this.selectedCountry,adminCode1:this.selectedAdm1,adminCode2:this.selectedAdm2,adminCode3:this.selectedAdm3,adminCode4:this.selectedAdm4}).subscribe(n=>this.adm5Options.set(n))}saveAdminHierarchy(){return wt(this,null,function*(){if(this.adminSaveError.set(null),this.adminSaveSuccess.set(null),this.selectedCountry===(this.place.countryCode??"")&&this.selectedAdm1===(this.place.adminCode1??"")&&this.selectedAdm2===(this.place.adminCode2??"")&&this.selectedAdm3===(this.place.adminCode3??"")&&this.selectedAdm4===(this.place.adminCode4??"")&&this.selectedAdm5===(this.place.adminCode5??"")){this.adminSaveError.set("Hierarchy unchanged.");return}let t=[];t[0]=this.selectedCountry,t[1]=this.selectedAdm1?`${t[0]}.${this.selectedAdm1}`:"",t[2]=this.selectedAdm2?`${t[1]}.${this.selectedAdm2}`:"",t[3]=this.selectedAdm3?`${t[2]}.${this.selectedAdm3}`:"",t[4]=this.selectedAdm4?`${t[3]}.${this.selectedAdm4}`:"",t[5]=this.selectedAdm5?`${t[4]}.${this.selectedAdm5}`:"",this.adminSaving.set(!0);try{yield vt(this.adminHierarchyService.updateCountry(this.place.id,t[0])),yield vt(this.adminHierarchyService.updateAdminCode(this.place.id,1,t[1])),yield vt(this.adminHierarchyService.updateAdminCode(this.place.id,2,t[2])),yield vt(this.adminHierarchyService.updateAdminCode(this.place.id,3,t[3])),yield vt(this.adminHierarchyService.updateAdminCode(this.place.id,4,t[4]));let i=yield vt(this.adminHierarchyService.updateAdminCode(this.place.id,5,t[5]
47));It(i),this.place.countryCode=this.selectedCountry,this.place.adminCode1=this.selectedAdm1,this.place.adminCode2=this.selectedAdm2,this.place.adminCode3=this.selectedAdm3,this.place.adminCode4=this.selectedAdm4,this.place.adminCode5=this.selectedAdm5,this.adminSaveSuccess.set("Hierarchy has been updated."),this.editingAdmin.set(!1),this.hierarchyChanged.emit()}catch(i){this.adminSaveError.set(i instanceof Error?i.message:"Could not update the hierarchy.")}finally{this.adminSaving.set(!1)}})}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-hierarchy-tab"]],inputs:{place:"place",ancestors:"ancestors"},outputs:{hierarchyChanged:"hierarchyChanged"},features:[ct],decls:11,vars:7,consts:[["relationsTable",""],["role","tablist",1,"inner-tabs"],["type","button",1,"inner-tab",3,"click"],[3,"ngTemplateOutlet"],[1,"ancestor-list"],[3,"padding-left"],[1,"current"],[1,"tree-dot"],[1,"fclass-badge"],[1,"admin-code"],[1,"meta"],[1,"admin-form"],[1,"fclass-badge",3,"background-color","color"],[3,"routerLink"],["type","button",1,"btn-primary",3,"click"],[1,"form-success"],[1,"placeholder"],[1,"admin-levels"],[1,"admin-level"],[1,"level-label"],["name","country",3,"ngModelChange","ngModel"],["value",""],[3,"value"],["name","adm1",3,"ngModelChange","ngModel","disabled"],["name","adm2",3,"ngModelChange","ngModel","disabled"],["name","adm3",3,"ngModelChange","ngModel","disabled"],["name","adm4",3,"ngModelChange","ngModel","disabled"],["name","adm5",3,"ngModelChange","ngModel","disabled"],[1,"admin-actions"],["type","button",1,"btn-primary",3,"click","disabled"],["type","button",3,"click","disabled"],[1,"form-error"],[1,"table-actions"],[1,"placeholder","error"],[1,"table-scroll"],[1,"relation-table"],[1,"code-col"],[1,"edit-row"],["colspan","3"],[1,"edit-form"],["type","text","name","newRelationId","size","10",3,"ngModelChange","ngModel"],[1,"edit-actions"],[1,"actions-col"],["type","button",3,"disabled"],[1,"delete-confirm"],["type","button",1,"btn-danger",3,"click","disabled"],["colspan","3",1,"placeholder"]],template:function(t,i){if(t&1){let o=$();l(0,"div",1)(1,"button",2),M("click",function(){return S(o),w(i.selectInnerTab("admin"))}),s(2," Administrative hierarchy "),a(),l(3,"button",2),M("click",function(){return S(o),w(i.selectInnerTab("parents"))}),s(4," Parents "),a(),l(5,"button",2),M("click",function(){return S(o),w(i.selectInnerTab("children"))}),s(6," Children "),a()(),y(7,CA,15,16)(8,_A,1,1,"ng-container",3)(9,IA,6,3,"ng-template",null,0,Zo)}t&2&&(d(),pe("active",i.innerTab()==="admin"),d(2),pe("active",i.innerTab()==="parents"),d(2),pe("active",i.innerTab()==="children"),d(2),_(i.innerTab()==="admin"?7:8))},dependencies:[ke,zn,Gn,Me,mn,Ne,De,W,co],styles:[".inner-tabs[_ngcontent-%COMP%]{display:flex;gap:.25rem;border-bottom:1px solid #e5e5e5;margin-bottom:1rem;overflow-x:auto}.inner-tab[_ngcontent-%COMP%]{appearance:none;border:none;background:none;cursor:pointer;font:inherit;font-size:.85rem;color:#555;padding:.5rem .7rem;border-bottom:2px solid transparent;white-space:nowrap}.inner-tab[_ngcontent-%COMP%]:hover{color:#1a5fb4}.inner-tab.active[_ngcontent-%COMP%]{color:#1a5fb4;font-weight:600;border-bottom-color:#1a5fb4}.ancestor-list[_ngcontent-%COMP%]{list-style:none;margin:0 0 1.25rem;padding:0}.ancestor-list[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{display:flex;align-items:baseline;gap:.5rem;padding:.4rem .6rem;border-radius:6px}.tree-dot[_ngcontent-%COMP%]{flex-shrink:0;width:6px;height:6px;border-radius:50%;background:#c3cedb}.ancestor-list[_ngcontent-%COMP%]   li.current[_ngcontent-%COMP%]{font-weight:600;background:#eef4fc;margin-top:.15rem}.ancestor-list[_ngcontent-%COMP%]   li.current[_ngcontent-%COMP%]   .tree-dot[_ngcontent-%COMP%]{width:8px;height:8px;background:#1a5fb4}.ancestor-list[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.ancestor-list[_ngcontent-%COMP%]   .fclass-badge[_ngcontent-%COMP%]{margin-right:0}.ancestor-list[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.meta[_ngcontent-%COMP%]{font-size:.8rem;color:#888}.admin-code[_ngcontent-%COMP%]{font-size:.65rem;color:#999;margin:0 .3rem 0 .15rem;font-weight:400}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.btn-primary[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.btn-primary[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.delete-confirm[_ngcontent-%COMP%]   .btn-danger[_ngcontent-%COMP%]{border-color:#b3261e;background:#b3261e;color:#fff}.admin-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.9rem;margin-top:1rem;padding:.9rem;background:#f8f9fa;border-radius:8px}.admin-levels[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.admin-level[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.6rem}
47.admin-level[_ngcontent-%COMP%]   .tree-dot[_ngcontent-%COMP%]{flex-shrink:0}.admin-form[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.2rem;font-size:.75rem;color:#666}.level-label[_ngcontent-%COMP%]   small[_ngcontent-%COMP%]{color:#999;font-weight:400}.admin-form[_ngcontent-%COMP%]   select[_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.3rem .4rem;font-size:.85rem;min-width:14rem}.admin-form[_ngcontent-%COMP%]   select[_ngcontent-%COMP%]:disabled{background:#eee;color:#aaa;cursor:not-allowed}.admin-actions[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.4rem}.admin-actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:not(.btn-primary){appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.form-error[_ngcontent-%COMP%]{flex-basis:100%;color:#b3261e;font-size:.8rem;margin:.3rem 0 0}.form-success[_ngcontent-%COMP%]{color:#2e7d32;font-size:.85rem;margin:.5rem 0 0}.table-actions[_ngcontent-%COMP%]{margin-bottom:.5rem}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto}.relation-table[_ngcontent-%COMP%]{width:100%;border-collapse:collapse;font-size:.9rem}.relation-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .relation-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.45rem .5rem;border-bottom:1px solid #e5e5e5;text-align:left;white-space:nowrap}.relation-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;color:#777}.relation-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n):not(.edit-row){background:#fafbfc}.relation-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover:not(.edit-row){background:#eef2f7}.code-col[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:#f0f0f0;border-radius:3px;padding:.05rem .3rem;font-size:.8rem}.fclass-badge[_ngcontent-%COMP%]{display:inline-block;padding:.05rem .3rem;border-radius:3px;font-size:.75rem;font-weight:700;margin-right:.25rem}.relation-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none;font-weight:500}.relation-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.actions-col[_ngcontent-%COMP%]   button[_ngcontent-%COMP%], .delete-confirm[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.2rem .55rem;font-size:.8rem;cursor:pointer;margin-right:.3rem}.actions-col[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:hover{border-color:#1a5fb4;color:#1a5fb4}.actions-col[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.delete-confirm[_ngcontent-%COMP%]{font-size:.85rem;color:#555}.edit-row[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{background:#f8f9fa;white-space:normal}.edit-form[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:center;gap:.6rem 1rem;padding:.5rem 0}.edit-form[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.3rem;font-size:.8rem;color:#555}.edit-form[_ngcontent-%COMP%]   input[type=text][_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.25rem .4rem;font-size:.85rem}.edit-actions[_ngcontent-%COMP%]{display:flex;gap:.4rem;margin-left:auto}"]})};var it=class e{http=h(Z);countries$=this.http.get("/api/countries").pipe(Xn(1));getCountries(){return this.countries$}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};function We(e){return e.replace(/ü/gi,"ue").replace(/ö/gi,"oe").replace(/ä/gi,"ae").replace(/ß/g,"ss").normalize("NFD").replace(/[̀-ͯ]/g,"").toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")}function TA(e){return e&&e.charAt(0).toUpperCase()+e.slice(1)}function o1(e){return{id:String(e.geonameId),name:e.toponymName||e.name,featureClass:e.fcl,featureCode:e.fcode,featureLabel:TA(e.fcodeName??""),population:e.population||void 0,countryCode:e.countryCode}}var yd=class e{http=h(Z);getChildren(n){return this.http.get(`/api/hierarchy/children?geonameId=${encodeURIComponent(n)}`).pipe(N(t=>(t.geonames??[]).map(o1)))}getNeighbours(n){return this.http.get(`/api/hierarchy/neighbours?geonameId=${encodeURIComponent(n)}`).pipe(N(t=>(t.geonames??[]).map(o1)))}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var bd=(e,n)=>n.id,r1=(e,n)=>n.code;function OA(e,n){e&1&&(l(0,"p",0),s(1,"Loading place\u2026"),a())}function NA(e,n){e&1&&(l(0,"p",1),s(1,"Could not load this place right now."),a())}function kA(e,n){if(e&1&&(l(0,"sup",6),s(1),a()),e&2){let t=p().$implicit;d(),g(t.code)}}function AA(e,n){if(e&1&&(l(0,"span",4),s(1,"\u203A"),a(),l(2,"a",18),s(3),a(),y(4,kA,2,1,"sup",6)),e&2){let t=n.$implicit,i=p(3);d(2),v("routerLink",i.pathFor(t)),d(),g(t.name),d(),_(t.code?4:-1)}}function RA(e,n){e&1&&(l(0,"sup",6),s(1),a()),e&2&&(d(),g(n))}function FA(e,n){if(e&1&&(l(0,"a",8),j(1,"img",37),a()),e&2){let t=p();v("href","https://"+t.wikipediaUrl,Y)}}function LA(e,n){if(e&1&&(l(0,"a",38),s(1),a()),e&2){let t=p(2);v("routerLink",n),d(),g(t.countryCode)}}function VA(e,n){if(e&1&&s(0),e&2){let t=p(2);A(" ",t.countryCode," ")}}function UA(e,n){if(e&1&&(s(0," \xB7 "),y(1,LA,2,2,"a",38)(2,VA,1,1)),e&2){let t,i=p(),o=p(2);
47d(),_((t=o.countryPath(i.countryCode))?1:2,t)}}function jA(e,n){if(e&1){let t=$();l(0,"button",39),M("click",function(){let o=S(t).$implicit,r=p(3);return w(r.activeTab.set(o.id))}),s(1),a()}if(e&2){let t=n.$implicit,i=p(3);pe("active",i.activeTab()===t.id),v("id","tab-"+t.id),_e("aria-selected",i.activeTab()===t.id)("aria-controls","panel-"+t.id),d(),A(" ",t.label," ")}}function BA(e,n){if(e&1){let t=$();l(0,"button",40),M("click",function(){S(t);let o=p(3);return w(o.startMoveFeature())}),s(1,"Move"),a()}}function HA(e,n){if(e&1&&(l(0,"div",15)(1,"dt"),s(2,"Population"),a(),l(3,"dd"),s(4),a()()),e&2){let t=p();d(4),g(t.population.toLocaleString())}}function $A(e,n){e&1&&(j(0,"br"),l(1,"small",41),s(2),a()),e&2&&(d(2),g(n))}function zA(e,n){if(e&1&&(l(0,"div",15)(1,"dt"),s(2,"Elevation"),a(),l(3,"dd"),s(4),y(5,$A,3,1),a()()),e&2){let t,i=p(),o=p(2);d(4),A(" ",n," "),d(),_((t=o.demElevations(i))?5:-1,t)}}function GA(e,n){if(e&1&&(l(0,"div",15)(1,"dt"),s(2,"Timezone"),a(),l(3,"dd"),s(4),a()()),e&2){let t=p();d(4),g(t.timezone)}}function WA(e,n){if(e&1&&(l(0,"div",15)(1,"dt"),s(2,"Wikipedia"),a(),l(3,"dd")(4,"a",42),j(5,"img",43),s(6," Article "),a()()()),e&2){let t=p();d(4),v("href","https://"+t.wikipediaUrl,Y)}}function qA(e,n){if(e&1&&(l(0,"div",15)(1,"dt"),s(2,"Alternate countries"),a(),l(3,"dd"),s(4),a()()),e&2){let t=p();d(4),g(t.cc2)}}function JA(e,n){if(e&1&&(l(0,"p",49),s(1),a()),e&2){let t=p(4);d(),g(t.moveError())}}function KA(e,n){if(e&1){let t=$();
47l(0,"div",22)(1,"label"),s(2,"Latitude "),l(3,"input",44),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.moveForm.lat,o)||(r.moveForm.lat=o),w(o)}),a()(),l(4,"label"),s(5,"Longitude "),l(6,"input",45),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.moveForm.lng,o)||(r.moveForm.lng=o),w(o)}),a()(),l(7,"div",46)(8,"button",47),M("click",function(){S(t);let o=p(3);return w(o.submitMoveFeature())}),s(9),a(),l(10,"button",48),M("click",function(){S(t);let o=p(3);return w(o.cancelMoveFeature())}),s(11,"Cancel"),a()(),y(12,JA,2,1,"p",49),a()}if(e&2){let t=p(3);d(3),R("ngModel",t.moveForm.lat),d(3),R("ngModel",t.moveForm.lng),d(2),v("disabled",t.moveSaving()),d(),A(" ",t.moveSaving()?"Moving\u2026":"Save"," "),d(),v("disabled",t.moveSaving()),d(2),_(t.moveError()?12:-1)}}function YA(e,n){if(e&1&&(l(0,"p",23),s(1),a()),e&2){let t=p(3);d(),g(t.moveSuccess())}}function ZA(e,n){if(e&1&&(l(0,"p",23),s(1),a()),e&2){let t=p(4);d(),g(t.featureSaveSuccess())}}function QA(e,n){if(e&1){let t=$();l(0,"button",50),M("click",function(){S(t);let o=p(3);return w(o.startEditFeature())}),s(1,"Edit"),a(),y(2,ZA,2,1,"p",23)}if(e&2){let t=p(3);d(2),_(t.featureSaveSuccess()?2:-1)}}function XA(e,n){if(e&1&&(l(0,"option",54),s(1),a()),e&2){let t=n.$implicit;v("value",t.code),d(),le("",t.code," \u2014 ",t.name,"")}}function eR(e,n){if(e&1&&(l(0,"option",54),s(1),a()),e&2){let t=n.$implicit,i=p(4);v("value",t.code),d(),A(" ",i.featureCodeSortByName?t.name+" ("+t.code+")":t.code+" \u2014 "+t.name," ")}}function tR(e,n){if(e&1&&(l(0,"option",54),s(1),a()),e&2){let t=n.$implicit;v("value",t),d(),g(t)}}function nR(e,n){if(e&1&&(l(0,"p",49),s(1),a()),e&2){let t=p(4);d(),g(t.featureSaveError())}}function iR(e,n){if(e&1){let t=$();l(0,"div",24)(1,"label"),s(2,"Name "),l(3,"input",51),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.featureForm.name,o)||(r.featureForm.name=o),w(o)}),a()(),l(4,"label"),s(5," Feature class "),l(6,"select",52),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.featureForm.fclass,o)||(r.featureForm.fclass=o),w(o)}),M("ngModelChange",function(){S(t);let o=p(3);return w(o.onFeatureClassChange())}),l(7,"option",53),s(8,"select\u2026"),a(),I(9,XA,2,3,"option",54,r1),a()(),l(11,"label")(12,"span",55),s(13," Feature code "),l(14,"button",56),M("click",function(){S(t);let o=p(3);return w(o.toggleFeatureCodeSort())}),s(15),a()(),l(16,"select",57),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.featureForm.c,o)||(r.featureForm.c=o),w(o)}),l(17,"option",53),s(18,"select\u2026"),a(),I(19,eR,2,2,"option",54,r1),a()(),l(21,"label"),s(22,"Elevation (m) "),l(23,"input",58),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.featureForm.elevation,o)||(r.featureForm.elevation=o),w(o)}),a()(),l(24,"label"),s(25,"Population "),l(26,"input",59),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.featureForm.population,o)||(r.featureForm.population=o),w(o)}),a()(),l(27,"label"),s(28," Timezone "),l(29,"select",60),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.featureForm.timezone,o)||(r.featureForm.timezone=o),w(o)}),l(30,"option",53),s(31,"select\u2026"),a(),I(32,tR,2,2,"option",54,Re),a()(),l(34,"label"),s(35,"Alternate countries "),l(36,"input",61),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.featureForm.cc2,o)||(r.featureForm.cc2=o),w(o)}),a()(),l(37,"div",46)(38,"button",47),M("click",function(){S(t);let o=p(3);return w(o.submitEditFeature())}),s(39),a(),l(40,"button",48),M("click",function(){S(t);let o=p(3);return w(o.cancelEditFeature())}),s(41,"Cancel"),a()(),y(42,nR,2,1,"p",49),a()}if(e&2){let t=p(3);d(3),R("ngModel",t.featureForm.name),d(3),R("ngModel",t.featureForm.fclass),d(3),T(t.featureClasses),d(6),A(" Sort: ",t.featureCodeSortByName?"name":"code"," "),d(),R("ngModel",t.featureForm.c),v("disabled",!t.featureForm.fclass),d(3),T(t.getFeatureCodeOptions()),d(4),R("ngModel",t.featureForm.elevation),d(3),R("ngModel",t.featureForm.population),d(3),R("ngModel",t.featureForm.timezone),d(3),T(t.timezoneOptions()),d(4),R("ngModel",t.featureForm.cc2),d(2),v("disabled",t.featureSaving()),d(),A(" ",t.featureSaving()?"Saving\u2026":"Save"," "),d(),v("disabled",t.featureSaving()),d(2),_(t.featureSaveError()?42:-1)}}function oR(e,n){if(e&1){let t=$();l(0,"button",62),M("click",function(){S(t);let o=p(3);
47return w(o.startDeleteFeature())}),s(1,"Delete this place"),a()}}function rR(e,n){if(e&1&&(l(0,"p",49),s(1),a()),e&2){let t=p(4);d(),g(t.deleteError())}}function aR(e,n){if(e&1){let t=$();l(0,"div",27)(1,"label"),s(2," Reason for deletion "),l(3,"input",63),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.deleteComment,o)||(r.deleteComment=o),w(o)}),a()(),l(4,"p",64),s(5," This permanently removes the record from GeoNames. Undelete exists, but it's admin-only - not available here. "),a(),l(6,"div",65)(7,"button",66),M("click",function(){S(t);let o=p(3);return w(o.confirmDeleteFeature())}),s(8),a(),l(9,"button",48),M("click",function(){S(t);let o=p(3);return w(o.cancelDeleteFeature())}),s(10,"Cancel"),a()(),y(11,rR,2,1,"p",49),a()}if(e&2){let t=p(3);d(3),R("ngModel",t.deleteComment),d(4),v("disabled",t.deleting()||!t.deleteComment.trim()),d(),A(" ",t.deleting()?"Deleting\u2026":"Confirm delete"," "),d(),v("disabled",t.deleting()),d(2),_(t.deleteError()?11:-1)}}function sR(e,n){e&1&&(l(0,"p",49),s(1,"Could not load places within this division right now."),a())}function lR(e,n){e&1&&(l(0,"p",0),s(1,"Loading\u2026"),a())}function cR(e,n){e&1&&(l(0,"p",0),s(1,"No places found within this division."),a())}function dR(e,n){if(e&1&&(l(0,"span",68),s(1),a()),e&2){let t=p().$implicit;d(),A("pop. ",t.population.toLocaleString(),"")}}function uR(e,n){if(e&1&&(l(0,"li")(1,"span",10),s(2),a(),l(3,"a",18),s(4),a(),y(5,dR,2,1,"span",68),a()),e&2){let t=n.$implicit,i=p(5);d(),Te("background-color",i.featureClassColors[t.featureClass]==null?null:i.featureClassColors[t.featureClass].background)("color",i.featureClassColors[t.featureClass]==null?null:i.featureClassColors[t.featureClass].color),d(),g(t.featureCode),d(),v("routerLink",i.pathFor(t)),d(),g(t.name),d(),_(t.population?5:-1)}}function mR(e,n){if(e&1&&(l(0,"ul",67),I(1,uR,6,8,"li",null,bd),a()),e&2){let t=p(4);d(),T(t.adminChildren())}}function pR(e,n){e&1&&(l(0,"p",49),s(1,"Could not load neighbouring divisions right now."),a())}function fR(e,n){e&1&&(l(0,"p",0),s(1,"Loading\u2026"),a())}function hR(e,n){e&1&&(l(0,"p",0),s(1,"No neighbouring divisions found."),a())}function gR(e,n){if(e&1&&(l(0,"span",68),s(1),a()),e&2){let t=p().$implicit;d(),g(t.countryCode)}}function CR(e,n){if(e&1&&(l(0,"li")(1,"span",10),s(2),a(),l(3,"a",18),s(4),a(),y(5,gR,2,1,"span",68),a()),e&2){let t=n.$implicit,i=p(5);d(),Te("background-color",i.featureClassColors[t.featureClass]==null?null:i.featureClassColors[t.featureClass].background)("color",i.featureClassColors[t.featureClass]==null?null:i.featureClassColors[t.featureClass].color),d(),g(t.featureCode),d(),v("routerLink",i.pathFor(t)),d(),g(t.name),d(),_(t.countryCode?5:-1)}}function _R(e,n){if(e&1&&(l(0,"ul",67),I(1,CR,6,8,"li",null,bd),a()),e&2){let t=p(4);d(),T(t.adminNeighbours())}}function vR(e,n){if(e&1&&(l(0,"div",28)(1,"h2"),s(2,"Places within this division"),a(),y(3,sR,2,0,"p",49)(4,lR,2,0,"p",0)(5,cR,2,0,"p",0)(6,mR,3,0,"ul",67),l(7,"h2"),s(8,"Neighbouring divisions"),a(),y(9,pR,2,0,"p",49)(10,fR,2,0,"p",0)(11,hR,2,0,"p",0)(12,_R,3,0,"ul",67),a()),e&2){let t=p(3);d(3),_(t.adminChildrenState()==="error"?3:t.adminChildrenState()!=="loaded"?4:t.adminChildren().length===0?5:6),d(6),_(t.adminNeighboursState()==="error"?9:t.adminNeighboursState()!=="loaded"?10:t.adminNeighbours().length===0?11:12)}}function yR(e,n){if(e&1){let t=$();l(0,"app-geo-map",69),M("placeMoved",function(o){S(t);let r=p(3);return w(r.onMapMoved(o))})("featureEdited",function(o){S(t);let r=p(3);return w(r.onMapFeatureEdited(o))}),a()}if(e&2){let t=p(),i=p(2);v("latitude",t.latitude)("longitude",t.longitude)("zoom",t.featureClass==="A"?7:12)("label",t.name)("featureClass",t.featureClass)("popupDescription",i.popupDescriptionFor(t))("boundingBox",t.boundingBox)("geonameId",t.id)("hasShape",!!t.hasShape)("place",t)("ancestors",i.ancestors())}}function bR(e,n){if(e&1){let t=$();l(0,"nav",2)(1,"a",3),s(2,"Home"),a(),I(3,AA,5,3,null,null,bd),l(5,"span",4),s(6,"\u203A"),a(),l(7,"span",5),s(8),a(),y(9,RA,2,1,"sup",6),a(),l(10,"header",7)(11,"h1"),s(12),y(13,FA,2,1,"a",8),a(),l(14,"p",9)(15,"span",10),s(16),a(),l(17,"span",10),s(18),a(),s(19),y(20,UA,3,1),a()(),l(21,"div",11),I(22,jA,2,6,"button",12,bd),a(),l(24,"section",13)(25,"dl",14)(26,"div",15)(27,"dt"),s(28,"GeonameId"),a(),l(29,"dd"),s(30),a()(),l(31,"div",15)(32,"dt"),s(33,"Coordinates"),a(),l(34,"dd"),s(35),y(36,BA,2,0,"button",16),a()(),y(37,HA,5,1,"div",15)(38,zA,6,2,"div",15)(39,GA,5,1,"div",15),l(40,"div",15)(41,"dt"),s(42,"Feature code"),a(),l(43,"dd")(44,"span",10),s(45),a(),l(46,"span",10),s(47),a()()(),y(48,WA,7,1,"div",15)(49,qA,5,
471,"div",15),a(),l(50,"p",17),s(51," Permalink: "),l(52,"a",18),s(53),a()(),l(54,"p",19)(55,"a",20),s(56,".kml"),a(),l(57,"a",21),s(58,".rdf"),a()(),y(59,KA,13,6,"div",22)(60,YA,2,1,"p",23)(61,QA,3,1)(62,iR,43,13,"div",24),l(63,"div",25),y(64,oR,2,0,"button",26)(65,aR,12,5,"div",27),a(),y(66,vR,13,2,"div",28),a(),l(67,"section",29),y(68,yR,1,11,"app-geo-map",30),a(),l(69,"section",31)(70,"app-hierarchy-tab",32),M("hierarchyChanged",function(){S(t);let o=p(2);return w(o.refreshAncestors())}),a()(),l(71,"section",33),j(72,"app-history-tab",34),a(),l(73,"section",35),j(74,"app-alternate-names-tab",36),a()}if(e&2){let t,i,o=n,r=p(2);d(3),T(r.ancestors()),d(5),g(o.name),d(),_((t=r.currentAdminCode(o))?9:-1,t),d(3),A(" ",o.name," "),d(),_(o.wikipediaUrl?13:-1),d(2),Te("background-color",r.featureClassColors[o.featureClass]==null?null:r.featureClassColors[o.featureClass].background)("color",r.featureClassColors[o.featureClass]==null?null:r.featureClassColors[o.featureClass].color),d(),g(o.featureClass),d(),Te("background-color",r.featureClassColors[o.featureClass]==null?null:r.featureClassColors[o.featureClass].background)("color",r.featureClassColors[o.featureClass]==null?null:r.featureClassColors[o.featureClass].color),d(),g(o.featureCode),d(),A(" ",o.featureLabel,""),d(),_(o.countryCode?20:-1),d(2),T(r.tabs),d(2),v("hidden",r.activeTab()!=="feature"),d(6),g(o.id),d(5),le(" ",o.latitude.toFixed(5),", ",o.longitude.toFixed(5)," "),d(),_(r.movingFeature()?-1:36),d(),_(o.population?37:-1),d(),_((i=r.primaryElevation(o))?38:-1,i),d(),_(o.timezone?39:-1),d(5),Te("background-color",r.featureClassColors[o.featureClass]==null?null:r.featureClassColors[o.featureClass].background)("color",r.featureClassColors[o.featureClass]==null?null:r.featureClassColors[o.featureClass].color),d(),g(o.featureClass),d(),Te("background-color",r.featureClassColors[o.featureClass]==null?null:r.featureClassColors[o.featureClass].background)("color",r.featureClassColors[o.featureClass]==null?null:r.featureClassColors[o.featureClass].color),d(),g(o.featureCode),d(),_(o.wikipediaUrl?48:-1),d(),_(o.cc2?49:-1),d(3),v("routerLink",o.path),d(),A("https://www.geonames.org",o.path,""),d(2),v("href",r.kmlUrl(o),Y),d(2),v("href",r.rdfUrl(o),Y),d(2),_(r.movingFeature()?59:-1),d(),_(r.moveSuccess()?60:-1),d(),_(r.editingFeature()?62:61),d(3),_(r.confirmingDelete()?65:64),d(2),_(o.featureClass==="A"?66:-1),d(),v("hidden",r.activeTab()!=="map"),d(),_(r.activeTab()==="map"?68:-1),d(),v("hidden",r.activeTab()!=="hierarchy"),d(),v("place",o)("ancestors",r.ancestors()),d(),v("hidden",r.activeTab()!=="history"),d(),v("geonameId",o.id)("active",r.activeTab()==="history"),d(),v("hidden",r.activeTab()!=="alternateNames"),d(),v("geonameId",o.id)}}function xR(e,n){if(e&1&&y(0,bR,75,55),e&2){let t,i=p();_((t=i.place())?0:-1,t)}}var Ka=class e{route=h(ve);router=h(Dt);places=h(tt);remotePlaceService=h(yr);featureService=h(br);adminRelativesService=h(yd);timezoneService=h(Fi);countryInfoService=h(it);title=h(H);meta=h(Ni);renderer=h(Ut);document=h($e);platformId=h(Zt);jsonLdScript;canonicalLink;subscription;confirmingDelete=E(!1);deleteComment="";deleting=E(!1);deleteError=E(null);editingFeature=E(!1);featureForm={name:"",fclass:"",c:"",elevation:"",population:"",timezone:"",cc2:""};featureSaving=E(!1);featureSaveError=E(null);featureSaveSuccess=E(null);featureClasses=qn;featureClassColors=Dn;currentAdminCode=_d;primaryElevation=ud;featureCodeSortByName=!1;timezoneOptions=E([]);movingFeature=E(!1);moveForm={lat:"",lng:""};moveSaving=E(!1);moveError=E(null);moveSuccess=E(null);loadState=E("loading");view=E(null);place=G(()=>this.view()?.place);ancestors=G(()=>this.view()?.ancestors??[]);adminChildren=E([]);adminChildrenState=E("idle");adminNeighbours=E([]);adminNeighboursState=E("idle");tabs=[{id:"feature",label:"Feature"},{id:"map",label:"Map"},{id:"hierarchy",label:"Hierarchy"},{id:"history",label:"History"},{id:"alternateNames",label:"Alternate names"}];activeTab=E("feature");countries=E([]);countryPath(n){let t=n?this.countries().find(i=>i.isoCode===n):void 0;return t?`/countries/${t.isoCode}/${We(t.countryName)}.html`:null}constructor(){this.countryInfoService.getCountries().subscribe({next:n=>this.countries.set(n),error:()=>{}}),un(this.platformId)&&this.timezoneService.getTimezoneIds().subscribe(n=>this.timezoneOptions.set(n)),this.subscription=this.route.paramMap.pipe(N(n=>n.get("id")),Qu(),be(n=>(this.loadState.set("loading"),this.activeTab.set("feature"),this.confirmingDelete.set(!1),this.deleteError.set(null),this.editingFeature.set(!1),this.featureSaveError.set(null),this.featureSaveSuccess.set(null),this.movingFeature.set(!1),this.moveError.set(null),this.moveSuccess.set(null),this.adminChildren.set([]),this.adminChildrenState.set("idle"),this.adminNeighbours.set([]),this.adminNeighboursState.set("idle"),this.remotePlaceService.getPlaceView(n).pipe(Ze(()=>Q(null)))))).subscribe(n=>{n?(this.view.set(n),this.loadState.set("loaded"),this.applySeoTags(n.place,n.ancestors),n.place.featureClass==="A"&&this.loadAdminRelatives(n.place.id)):this.loadState.set("error")})}refreshAncestors(){let n=this.view()?.place.id;n&&this.remotePlaceService.getPlaceView(n).subscribe({next:t=>{this.view.set(t),this.applySeoTags(t.place,t.ancestors)},error:()=>{}})}applySeoTags(n,t){let i=[...t.map(f=>f.name),n.name].join(", "),o=`${n.name}${n.countryName?", "+n.countryName:""}`,r=`${n.name} (${n.featureLabel}
47). ${n.population?"Population "+n.population.toLocaleString()+". ":""}Located in ${i||"the world"}. Coordinates ${n.latitude.toFixed(4)}, ${n.longitude.toFixed(4)}.`;this.title.setTitle(o),this.meta.updateTag({name:"description",content:r}),this.meta.updateTag({property:"og:title",content:o}),this.meta.updateTag({property:"og:description",content:r}),this.meta.updateTag({property:"og:type",content:"place"}),this.meta.updateTag({name:"viewport",content:"width=device-width, initial-scale=1"});let c=U({"@context":"https://schema.org","@type":"Place",name:n.name,description:r,geo:{"@type":"GeoCoordinates",latitude:n.latitude,longitude:n.longitude}},n.population?{additionalProperty:{"@type":"PropertyValue",name:"population",value:n.population}}:{});this.jsonLdScript&&this.renderer.removeChild(this.document.head,this.jsonLdScript);let u=this.renderer.createElement("script");u.type="application/ld+json",u.text=JSON.stringify(c),this.renderer.appendChild(this.document.head,u),this.jsonLdScript=u,this.canonicalLink&&this.renderer.removeChild(this.document.head,this.canonicalLink);let m=this.renderer.createElement("link");m.setAttribute("rel","canonical"),m.setAttribute("href",n.path),this.renderer.appendChild(this.document.head,m),this.canonicalLink=m}pathFor(n){return this.places.path(n)}loadAdminRelatives(n){this.adminChildrenState.set("loading"),this.adminRelativesService.getChildren(n).subscribe({next:t=>{this.adminChildren.set(t),this.adminChildrenState.set("loaded")},error:()=>this.adminChildrenState.set("error")}),this.adminNeighboursState.set("loading"),this.adminRelativesService.getNeighbours(n).subscribe({next:t=>{this.adminNeighbours.set(t),this.adminNeighboursState.set("loaded")},error:()=>this.adminNeighboursState.set("error")})}popupDescriptionFor(n){let t=[n.featureLabel];return n.population&&t.push(`Population ${n.population.toLocaleString()}`),t.join(" \xB7 ")}demElevations(n){let t=[],i=_o(n.srtm3),o=_o(n.astergdem),r=_o(n.gtopo30);return i!=null&&t.push(`SRTM3 ${i} m`),o!=null&&t.push(`ASTER ${o} m`),r!=null&&t.push(`GTOPO30 ${r} m`),t.length?t.join(" \xB7 "):null}kmlUrl(n){let t=n.featureClass==="A"?7:12;return`https://www.geonames.org/kml/${n.latitude.toFixed(5)}_${n.longitude.toFixed(5)}_${t}.kml`}rdfUrl(n){return`https://sws.geonames.org/${n.id}/about.rdf`}startEditFeature(){let n=this.place();n&&(this.featureForm={name:n.name,fclass:n.featureClass,c:n.featureCode,elevation:n.elevation!=null?String(n.elevation):"",population:n.population!=null?String(n.population):"",timezone:n.timezone??"",cc2:n.cc2??""},this.editingFeature.set(!0),this.featureSaveError.set(null),this.featureSaveSuccess.set(null))}cancelEditFeature(){this.editingFeature.set(!1),this.featureSaveError.set(null)}onFeatureClassChange(){this.featureForm.c=""}startMoveFeature(){let n=this.place();n&&(this.moveForm={lat:n.latitude.toFixed(5),lng:n.longitude.toFixed(5)},this.movingFeature.set(!0),this.moveError.set(null),this.moveSuccess.set(null))}
47cancelMoveFeature(){this.movingFeature.set(!1),this.moveError.set(null)}submitMoveFeature(){let n=this.place();if(!n)return;let t=Number(this.moveForm.lat),i=Number(this.moveForm.lng);if(!Number.isFinite(t)||!Number.isFinite(i)){this.moveError.set("Latitude and longitude must be numbers.");return}this.moveSaving.set(!0),this.moveError.set(null),this.featureService.moveFeature(n.id,t,i).subscribe({next:()=>{this.moveSaving.set(!1),this.movingFeature.set(!1),this.moveSuccess.set("Item has been moved."),n.latitude=t,n.longitude=i},error:o=>{this.moveSaving.set(!1),this.moveError.set(o instanceof Error?o.message:"Could not move this place.")}})}onMapMoved(n){let t=this.place();t&&(t.latitude=n.lat,t.longitude=n.lng,this.moveSuccess.set("Item has been moved."))}onMapFeatureEdited(n){let t=this.place();t&&(t.name=n.name,t.featureClass=n.featureClass,t.featureCode=n.featureCode,t.elevation=n.elevation,t.population=n.population,t.timezone=n.timezone,t.cc2=n.cc2,this.featureSaveSuccess.set("Changes have been saved."))}toggleFeatureCodeSort(){this.featureCodeSortByName=!this.featureCodeSortByName}getFeatureCodeOptions(){let n=hi[this.featureForm.fclass]??[],t=this.featureForm.c;return[...t&&!n.some(r=>r.code===t)?[...n,{code:t,name:t}]:n].sort((r,c)=>this.featureCodeSortByName?r.name.localeCompare(c.name):r.code.localeCompare(c.code))}submitEditFeature(){let n=this.place();if(!n)return;this.featureSaving.set(!0),this.featureSaveError.set(null);let t=U({geonameId:n.id},this.featureForm);this.featureService.updateFeature(t).subscribe({next:()=>{this.featureSaving.set(!1),this.editingFeature.set(!1),this.featureSaveSuccess.set("Changes have been saved."),n.name=this.featureForm.name,n.featureClass=this.featureForm.fclass,n.featureCode=this.featureForm.c,n.elevation=this.featureForm.elevation?Number(this.featureForm.elevation):void 0,n.population=this.featureForm.population?Number(this.featureForm.population):void 0,n.timezone=this.featureForm.timezone||void 0},error:i=>{this.featureSaving.set(!1),this.featureSaveError.set(i instanceof Error?i.message:"Could not save these changes.")}})}startDeleteFeature(){this.confirmingDelete.set(!0),this.deleteComment="",this.deleteError.set(null)}cancelDeleteFeature(){this.confirmingDelete.set(!1),this.deleteError.set(null)}confirmDeleteFeature(){let n=this.place();n&&(this.deleting.set(!0),this.deleteError.set(null),this.featureService.deleteFeature(n.id,this.deleteComment.trim()).subscribe({next:()=>{this.deleting.set(!1),this.confirmingDelete.set(!1);let t=this.ancestors(),i=t[t.length-1];this.router.navigateByUrl(i?this.pathFor(i):"/")},error:t=>{this.deleting.set(!1),this.deleteError.set(t instanceof Error?t.message:"Could not delete this place.")}}))}ngOnDestroy(){this.subscription.unsubscribe(),this.jsonLdScript&&this.renderer.removeChild(this.document.head,this.jsonLdScript),this.canonicalLink&&this.renderer.removeChild(this.document.head,this.canonicalLink)}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-place-page"]],decls:3,vars:1,consts:[[1,"placeholder"],[1,"not-found"],["aria-label","Breadcrumb",1,"breadcrumb"],["routerLink","/"],[1,"sep"],[1,"current"],[1,"admin-code"],[1,"place-header"],["target","_blank","rel","noopener noreferrer","title","Wikipedia article",1,"wikipedia-badge",3,"href"],[1,"feature-label"],[1,"fclass-badge"],["role","tablist","aria-label","Place details",1,"tabs"],["type","button","role","tab",1,"tab",3,"active","id"],["id","panel-feature","role","tabpanel","aria-labelledby","tab-feature",3,"hidden"],[1,"facts"],[1,"fact"],["type","button",1,"link-btn"],[1,"permalink"],[3,"routerLink"],[1,"external-links"],["target","_blank","rel","nofollow noopener noreferrer","title","View in Google Earth",3,"href"],["target","_blank","rel","nofollow noopener noreferrer","title","Semantic web",3,"href"],[1,"edit-form","move-form"],[1,"form-success"],[1,"edit-form"],[1,"danger-zone"],["type","button",1,"btn-danger-outline"],[1,"delete-panel"],[1,"admin-relatives"],["id","panel-map","role","tabpanel","aria-labelledby","tab-map",3,"hidden"],[3,"latitude","longitude","zoom","label","featureClass","popupDescription","boundingBox","geonameId","hasShape","place","ancestors"],["id","panel-hierarchy","role","tabpanel","aria-labelledby","tab-hierarchy",3,"hidden"],[3,"hierarchyChanged","place","ancestors"],["id","panel-history","role","tabpanel","aria-labelledby","tab-history",3,"hidden"],[3,"geonameId","active"],["id","panel-alternateNames","role","tabpanel","aria-labelledby","tab-alternateNames",3,"hidden"],[3,"geonameId"],["src","https://www.geonames.org/img/20px-Wikipedia-logo.png","alt","","width","18","height","18"],["title","Country details",1,"country-link",3,"routerLink"],["type","button","role","tab",1,"tab",3,"click","id"],["type","button",1,"link-btn",3,"click"],[1,"dem-elevations"],["target","_blank","rel","noopener noreferrer",1,"wikipedia-link",3,"href"],["src","https://www.geonames.org/img/20px-Wikipedia-logo.png","alt","","width","20","height","20"],["type","text","name","moveLat","size","12",3,"ngModelChange","ngModel"],["type","text","name","moveLng","size","12",3,"ngModelChange","ngModel"],[1,"edit-actions"],["type","button",1,"btn-primary",3,"click","disabled"],["type","button",3,"click","disabled"],[1,"form-error"],["type","button",1,"btn-primary",3,"click"],["type","text","name","featureName",3,"ngModelChange","ngModel"],["name","fclass",3,"ngModelChange","ngModel"],["value",""],[3,"value"],[1,"label-row"],["type","button",1,"sort-toggle",3,"click"],["name","featureCode",3,"ngModelChange","ngModel","disabled"],["type","text","name","elevation","size","8",3,"ngModelChange","ngModel"],["type","text","name","population","size","10",3,"ngModelChange","ngModel"],["name","timezone",3,"ngModelChange","ngModel"],["type","text","name","cc2","placeholder","comma separated",3,"ngModelChange","ngModel"],["type","button",1,"btn-danger-outline",3,"click"],["type","text","name","deleteComment","placeholder","e.g. duplicate, does not exist",3,"ngModelChange","ngModel"],[1,"delete-warning"],[1,"delete-actions"],["type","button",1,"btn-danger",3,"click","disabled"],[1,"relatives-list"],[1,"relative-meta"],[3,"placeMoved","featureEdited","latitude","longitude","zoom","label","featureClass","popupDescription","boundingBox","geonameId","hasShape","place","ancestors"]],template:function(t,i){if(t&1&&y(0,OA,2,0,"p",0)(1,NA,2,0,"p",1)(2,xR,1,1),t&2){let o;_((o=i.loadState())==="loading"?0:o==="error"?1:o==="loaded"?2:-1)}},dependencies:[W,ke,zn,Gn,Me,mn,Ne,De,nt,fd,hd,vd],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}.breadcrumb[_ngcontent-%COMP%]{font-size:.85rem;color:#555;margin-bottom:1rem;overflow-wrap:break-word}
47.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.breadcrumb[_ngcontent-%COMP%]   .sep[_ngcontent-%COMP%]{margin:0 .35rem;color:#999}.breadcrumb[_ngcontent-%COMP%]   .current[_ngcontent-%COMP%]{color:#222;font-weight:600}.breadcrumb[_ngcontent-%COMP%]   .admin-code[_ngcontent-%COMP%]{font-size:.65rem;color:#999;margin-left:.15rem;font-weight:400}.place-header[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{margin:0 0 .15rem;font-size:1.9rem;line-height:1.15}.wikipedia-badge[_ngcontent-%COMP%]{display:inline-flex;align-items:center;vertical-align:middle;margin-left:.45rem;opacity:.75}.wikipedia-badge[_ngcontent-%COMP%]:hover{opacity:1}.wikipedia-badge[_ngcontent-%COMP%]   img[_ngcontent-%COMP%]{display:block}.feature-label[_ngcontent-%COMP%]{margin:0 0 1rem;color:#666;font-size:.95rem;display:flex;align-items:center;flex-wrap:wrap}.fclass-badge[_ngcontent-%COMP%]{display:inline-block;margin-right:.35rem;padding:.1rem .4rem;border-radius:3px;font-size:.75rem;font-weight:700;line-height:1.4}.wikipedia-link[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:.35rem;color:#1a5fb4;text-decoration:none;font-size:1.05rem}.wikipedia-link[_ngcontent-%COMP%]:hover{text-decoration:underline}.permalink[_ngcontent-%COMP%]{margin:0 0 .4rem;font-size:.8rem;color:#999;overflow-wrap:anywhere}.permalink[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.permalink[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.external-links[_ngcontent-%COMP%]{display:flex;gap:.75rem;margin:0 0 1rem;font-size:.8rem}.external-links[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#999;text-decoration:none}.external-links[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{color:#1a5fb4;text-decoration:underline}.tabs[_ngcontent-%COMP%]{display:flex;gap:.25rem;border-bottom:1px solid #e5e5e5;margin-top:1.25rem;overflow-x:auto}.tab[_ngcontent-%COMP%]{appearance:none;border:none;background:none;cursor:pointer;font:inherit;font-size:.9rem;color:#555;padding:.6rem .9rem;border-bottom:2px solid transparent;white-space:nowrap}.tab[_ngcontent-%COMP%]:hover{color:#1a5fb4}.tab.active[_ngcontent-%COMP%]{color:#1a5fb4;font-weight:600;border-bottom-color:#1a5fb4}.facts[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.75rem 1.5rem;margin:1.25rem 0;padding:1rem;background:#f8f9fa;border-radius:8px}.fact[_ngcontent-%COMP%]   dt[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;color:#777}.fact[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]{margin:.1rem 0 0;font-size:1.05rem;font-weight:500}.dem-elevations[_ngcontent-%COMP%]{font-size:.75rem;font-weight:400;color:#888}[role=tabpanel][_ngcontent-%COMP%]{padding-top:1.25rem}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.link-btn[_ngcontent-%COMP%]{appearance:none;border:none;background:none;color:#1a5fb4;font-size:.8rem;cursor:pointer;padding:0;margin-left:.5rem;text-decoration:underline}.move-form[_ngcontent-%COMP%]{max-width:20rem}.btn-primary[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.btn-primary[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.form-success[_ngcontent-%COMP%]{color:#2e7d32;font-size:.85rem;margin:.5rem 0 0}.edit-form[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:.75rem 1rem;margin:1rem 0;padding:.75rem;background:#f8f9fa;border-radius:8px}.edit-form[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.2rem;font-size:.75rem;color:#666}.edit-form[_ngcontent-%COMP%]   input[type=text][_ngcontent-%COMP%], .edit-form[_ngcontent-%COMP%]   select[_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.3rem .4rem;font-size:.85rem;max-width:16rem}.label-row[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.5rem}.sort-toggle[_ngcontent-%COMP%]{appearance:none;border:none;background:none;
47color:#1a5fb4;font-size:.7rem;cursor:pointer;padding:0;text-transform:none}.sort-toggle[_ngcontent-%COMP%]:hover{text-decoration:underline}.edit-actions[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.4rem}.edit-actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:not(.btn-primary){appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.danger-zone[_ngcontent-%COMP%]{margin-top:1.5rem;padding-top:1rem;border-top:1px solid #f0f0f0}.btn-danger-outline[_ngcontent-%COMP%]{appearance:none;border:1px solid #b3261e;background:none;color:#b3261e;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.btn-danger-outline[_ngcontent-%COMP%]:hover{background:#fdecea}.delete-panel[_ngcontent-%COMP%]{max-width:28rem}.delete-panel[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem;font-size:.8rem;color:#555}.delete-panel[_ngcontent-%COMP%]   input[type=text][_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.35rem .5rem;font-size:.9rem}.delete-warning[_ngcontent-%COMP%]{font-size:.8rem;color:#8a6d00;margin:.5rem 0}.delete-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}.btn-danger[_ngcontent-%COMP%]{appearance:none;border:1px solid #b3261e;background:#b3261e;color:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.btn-danger[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.delete-actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:not(.btn-danger){appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.form-error[_ngcontent-%COMP%]{color:#b3261e;font-size:.8rem;margin:.4rem 0 0}.not-found[_ngcontent-%COMP%]{padding:2rem;text-align:center;color:#666}.admin-relatives[_ngcontent-%COMP%]{margin-top:1.5rem;padding-top:1rem;border-top:1px solid #f0f0f0}.admin-relatives[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:.95rem;margin:1.25rem 0 .5rem}.admin-relatives[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]:first-child{margin-top:0}.relatives-list[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0}.relatives-list[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;padding:.4rem 0;border-bottom:1px solid #f0f0f0}.relatives-list[_ngcontent-%COMP%]   .fclass-badge[_ngcontent-%COMP%]{margin-right:0}.relatives-list[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.relatives-list[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.relative-meta[_ngcontent-%COMP%]{margin-left:auto;color:#888;font-size:.8rem}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}.facts[_ngcontent-%COMP%]{grid-template-columns:1fr 1fr;padding:.75rem;gap:.6rem 1rem}.place-header[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{font-size:1.5rem}}.country-link[_ngcontent-%COMP%]{margin-left:.25rem;color:#1a5fb4;text-decoration:none}.country-link[_ngcontent-%COMP%]:hover{text-decoration:underline}"]})};function SR(e){return e&&e.charAt(0).toUpperCase()+e.slice(1)}var xd=class e{http=h(Z);search(n){let t=new URLSearchParams({q:n.q});return n.country&&t.set("country",n.country),this.http.get(`/api/search?${t.toString()}`).pipe(N(i=>(i.markers??[]).map(o=>({id:o.id,name:o.name,path:new URL(o.url).pathname,latitude:Number(o.lat),longitude:Number(o.lng),featureClass:o.fc,featureCode:o.c,featureLabel:SR(o.fcn??""),population:o.population?Number(o.population):void 0,countryCode:o.cc,countryName:o.cn,adminName1:o.admn1||void 0,adminName2:o.admn2||void 0,hasShape:o.hasShape==="true",wikipediaUrl:o.wikipediaURL||void 0}))))}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};function Sd(e){let n=e.trim().match(/^(-?\d{1,3}(?:\.\d+)?)\s*[,\s]\s*(-?\d{1,3}(?:\.\d+)?)$/);if(!n)return null;let t=Number(n[1]),i=Number(n[2]);return Math.abs(t)>90||Math.abs(i)>180?null:{lat:t,lng:i}}function Er(e,n){return`/maps/browse_${e.toFixed(3)}_${n.toFixed(3)}.html`}var wR=(e,n)=>n.id;function ER(e,n){if(e&1&&s(0),e&2){let t=p();A(' Search results for "',t.query(),'" ')}}
47function MR(e,n){e&1&&s(0," Search ")}function PR(e,n){e&1&&(l(0,"p",1),s(1,"Searching\u2026"),a())}function DR(e,n){e&1&&(l(0,"p",2),s(1,"Could not search right now."),a())}function IR(e,n){e&1&&(l(0,"p",1),s(1,"Type a place name into the search box above."),a())}function TR(e,n){if(e&1&&(l(0,"p",1),s(1),a()),e&2){let t=p(2);d(),A('No places found for "',t.query(),'".')}}function OR(e,n){if(e&1&&(l(0,"a",9),j(1,"img",12),a()),e&2){let t=p().$implicit;v("href","https://"+t.wikipediaUrl,Y)}}function NR(e,n){if(e&1&&(l(0,"span",10),s(1),a()),e&2){let t=p().$implicit;d(),g(t.countryCode)}}function kR(e,n){if(e&1&&(l(0,"span"),s(1),a()),e&2){let t=p().$implicit;d(),g(t.featureLabel)}}function AR(e,n){e&1&&(l(0,"span"),s(1),a()),e&2&&(d(),g(n))}function RR(e,n){if(e&1&&(l(0,"span"),s(1),a()),e&2){let t=p().$implicit;d(),A("pop. ",t.population.toLocaleString(),"")}}function FR(e,n){if(e&1&&(l(0,"li",5)(1,"div",6)(2,"span",7),s(3),a(),l(4,"span",7),s(5),a(),l(6,"a",8),s(7),a(),y(8,OR,2,1,"a",9)(9,NR,2,1,"span",10),a(),l(10,"div",11),y(11,kR,2,1,"span")(12,AR,2,1,"span")(13,RR,2,1,"span"),l(14,"span"),s(15),a()()()),e&2){let t,i=n.$implicit,o=p(3);d(2),Te("background-color",o.featureClassColors[i.featureClass]==null?null:o.featureClassColors[i.featureClass].background)("color",o.featureClassColors[i.featureClass]==null?null:o.featureClassColors[i.featureClass].color),d(),g(i.featureClass),d(),Te("background-color",o.featureClassColors[i.featureClass]==null?null:o.featureClassColors[i.featureClass].background)("color",o.featureClassColors[i.featureClass]==null?null:o.featureClassColors[i.featureClass].color),d(),g(i.featureCode),d(),v("routerLink",i.path),d(),g(i.name),d(),_(i.wikipediaUrl?8:-1),d(),_(i.countryCode?9:-1),d(2),_(i.featureLabel?11:-1),d(),_((t=o.locationHint(i))?12:-1,t),d(),_(i.population?13:-1),d(2),le("",i.latitude.toFixed(3),", ",i.longitude.toFixed(3),"")}}function LR(e,n){if(e&1&&(l(0,"p",3),s(1),a(),l(2,"ul",4),I(3,FR,16,19,"li",5,wR),a()),e&2){let t=p(2);d(),le("",t.results().length," result",t.results().length===1?"":"s",""),d(2),T(t.results())}}function VR(e,n){if(e&1&&y(0,IR,2,0,"p",1)(1,TR,2,1,"p",1)(2,LR,5,2),e&2){let t=p();_(t.query()?t.results().length===0?1:2:0)}}var wd=class e{route=h(ve);router=h(Dt);search=h(xd);title=h(H);subscription;featureClassColors=Dn;query=E("");loadState=E("loading");results=E([]);constructor(){this.subscription=this.route.queryParamMap.pipe(be(n=>{let t=n.get("q")??"";this.query.set(t),this.title.setTitle(t?`${t} \u2014 Search \u2014 GeoNames UI`:"Search \u2014 GeoNames UI");let i=Sd(t);return i?(this.router.navigateByUrl(Er(i.lat,i.lng)),Q(null)):t?(this.loadState.set("loading"),this.search.search({q:t,country:n.get("country")??void 0}).pipe(Ze(()=>Q(null)))):(this.loadState.set("loaded"),this.results.set([]),Q(null))})).subscribe(n=>{if(n===null){this.query()&&this.loadState.set("error");return}this.results.set(n),this.loadState.set("loaded")})}locationHint(n){let t=[n.adminName2,n.adminName1,n.countryName].filter(i=>!!i&&i!==n.name);return[...new Set(t)].join(", ")||null}ngOnDestroy(){this.subscription.unsubscribe()}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-search-results"]],decls:7,vars:2,consts:[[1,"search-page"],[1,"placeholder"],[1,"not-found"],[1,"result-count"],[1,"results"],[1,"result"],[1,"result-main"],[1,"fclass-badge"],[1,"result-name",3,"routerLink"],["target","_blank","rel","noopener noreferrer","title","Wikipedia article",1,"wikipedia-badge",3,"href"],[1,"result-country"],[1,"result-meta"],["src","https://www.geonames.org/img/20px-Wikipedia-logo.png","alt","","width","14","height","14"]],template:function(t,i){if(t&1&&(l(0,"div",0)(1,"h1"),y(2,ER,1,1)(3,MR,1,0),a(),y(4,PR,2,0,"p",1)(5,DR,2,0,"p",2)(6,VR,3,1),a()),t&2){let o;d(2),_(i.query()?2:3),d(2),_((o=i.loadState())==="loading"?4:o==="error"?5:o==="loaded"?6:-1)}},dependencies:[W],styles:['.search-page[_ngcontent-%COMP%]{max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{font-size:1.6rem;margin:0 0 1rem;word-break:break-word}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.not-found[_ngcontent-%COMP%]{color:#b3261e}.result-count[_ngcontent-%COMP%]{color:#666;font-size:.85rem;margin:0 0 .75rem}.results[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0}.result[_ngcontent-%COMP%]{padding:.6rem 0;border-bottom:1px solid #eee}.result-main[_ngcontent-%COMP%]{display:flex;align-items:baseline;flex-wrap:wrap;gap:.5rem}.fclass-badge[_ngcontent-%COMP%]{display:inline-block;padding:.1rem .4rem;border-radius:3px;font-size:.7rem;font-weight:700;line-height:1.4}
47.result-name[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none;font-weight:500;font-size:1.05rem}.result-name[_ngcontent-%COMP%]:hover{text-decoration:underline}.result-country[_ngcontent-%COMP%]{color:#555;font-size:.85rem}.wikipedia-badge[_ngcontent-%COMP%]{display:inline-flex;align-items:center;opacity:.75}.wikipedia-badge[_ngcontent-%COMP%]:hover{opacity:1}.wikipedia-badge[_ngcontent-%COMP%]   img[_ngcontent-%COMP%]{display:block}.result-meta[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:0 .6rem;margin-top:.15rem;color:#888;font-size:.8rem}.result-meta[_ngcontent-%COMP%]   span[_ngcontent-%COMP%]:not(:last-child):after{content:"\\b7";margin-left:.6rem;color:#ccc}']})};var zh=["XML","JSON","RDF","CSV","TXT","RSS","KML"],z="http://api.geonames.org",a1=[{name:"astergdem",docHref:"/export/web-services.html#astergdem",formats:{XML:`${z}/astergdem?lat=50.01&lng=10.2&username=demo&style=full&type=XML`,JSON:`${z}/astergdemJSON?formatted=true&lat=50.01&lng=10.2&username=demo&style=full`,TXT:`${z}/astergdem?lat=50.01&lng=10.2&username=demo&style=full`}},{name:"children",docHref:"https://www.geonames.org/export/place-hierarchy.html#children",formats:{XML:`${z}/children?geonameId=3175395&username=demo&style=full`,JSON:`${z}/childrenJSON?formatted=true&geonameId=3175395&username=demo&style=full`}},{name:"contains",docHref:"https://www.geonames.org/export/place-hierarchy.html#contains",formats:{XML:`${z}/contains?geonameId=2746385&username=demo&style=full`,JSON:`${z}/containsJSON?formatted=true&geonameId=2746385&username=demo&style=full`}}
47,{name:"countryCode",docHref:"/export/web-services.html#countrycode",formats:{XML:`${z}/countryCodeXML?lat=47.03&lng=10.2&username=demo&style=full`,JSON:`${z}/countryCodeJSON?formatted=true&lat=47.03&lng=10.2&username=demo&style=full`,TXT:`${z}/countryCode?lat=47.03&lng=10.2&username=demo&style=full`}},{name:"countryInfo",docHref:"/export/web-services.html#countryInfo",formats:{XML:`${z}/countryInfo?lang=it&country=DE&username=demo&style=full`,JSON:`${z}/countryInfoJSON?formatted=true&lang=it&country=DE&username=demo&style=full`,CSV:`${z}/countryInfoCSV?lang=it&country=DE&username=demo&style=full`}},{name:"countrySubdivision",docHref:"/export/web-services.html#countrysubdiv",formats:{XML:`${z}/countrySubdivision?lat=47.03&lng=10.2&username=demo&style=full`,JSON:`${z}/countrySubdivisionJSON?formatted=true&lat=47.03&lng=10.2&username=demo&style=full`}},{name:"earthquakes",docHref:"https://www.geonames.org/export/JSON-webservices.html#earthquakesJSON",formats:{XML:`${z}/earthquakes?north=44.1&south=-9.9&east=-22.4&west=55.2&username=demo&style=full`,JSON:`${z}/earthquakesJSON?formatted=true&north=44.1&south=-9.9&east=-22.4&west=55.2&username=demo&style=full`}},{name:"extendedFindNearby",docHref:"/export/web-services.html#extendedFindNearby",formats:{XML:`${z}/extendedFindNearby?lat=46.2022156980098&lng=6.14569187164307&username=demo&style=full`}},{name:"findNearby",docHref:"/export/web-services.html#findNearby",formats:{XML:`${z}/findNearby?lat=48.865618158309374&lng=2.344207763671875&fclass=P&fcode=PPLA&fcode=PPL&fcode=PPLC&username=demo&style=full`,JSON:`${z}/findNearbyJSON?formatted=true&lat=48.865618158309374&lng=2.344207763671875&fclass=P&fcode=PPLA&fcode=PPL&fcode=PPLC&username=demo&style=full`}},{name:"findNearbyPlaceName",docHref:"/export/web-services.html#findNearbyPlaceName",formats:{XML:`${z}/findNearbyPlaceName?lat=47.3&lng=9&username=demo&style=full`,JSON:`${z}/findNearbyPlaceNameJSON?formatted=true&lat=47.3&lng=9&username=demo&style=full`}},{name:"findNearbyPostalCodes",docHref:"/export/web-services.html#findNearbyPostalCodes",formats:{XML:`${z}/findNearbyPostalCodes?postalcode=8775&country=CH&radius=10&username=demo&style=full`,JSON:`${z}/findNearbyPostalCodesJSON?formatted=true&postalcode=8775&country=CH&radius=10&username=demo&style=full`}},{name:"findNearbyStreets",docHref:"/maps/us-reverse-geocoder.html#findNearbyStreets",formats:{XML:`${z}/findNearbyStreets?lat=37.451&lng=-122.18&username=demo&style=full`,JSON:`${z}/findNearbyStreetsJSON?formatted=true&lat=37.451&lng=-122.18&username=demo&style=full`}},{name:"findNearbyStreetsOSM",docHref:"/maps/osm-reverse-geocoder.html#findNearbyStreetsOSM",formats:{XML:`${z}/findNearbyStreetsOSM?lat=37.451&lng=-122.18&username=demo&style=full`,JSON:`${z}/findNearbyStreetsOSMJSON?formatted=true&lat=37.451&lng=-122.18&username=demo&style=full`}},{name:"findNearByWeather",docHref:"https://www.geonames.org/export/JSON-webservices.html#findNearByWeatherJSON",formats:{XML:`${z}/findNearByWeather?lat=42&lng=-2&username=demo&style=full`,JSON:`${z}/findNearByWeatherJSON?formatted=true&lat=42&lng=-2&username=demo&style=full`}},{name:"findNearbyWikipedia",docHref:"https://www.geonames.org/export/wikipedia-webservice.html#findNearbyWikipedia",formats:{XML:`${z}/findNearbyWikipedia?lat=47&lng=9&username=demo&style=full`,JSON:`${z}/findNearbyWikipediaJSON?formatted=true&lat=47&lng=9&username=demo&style=full`,RSS:`${z}/findNearbyWikipediaRSS?lat=47&lng=9&username=demo&style=full`}},{name:"findNearestAddress",docHref:"/maps/us-reverse-geocoder.html#findNearestAddress",formats:{XML:`${z}/findNearestAddress?lat=37.451&lng=-122.18&username=demo&style=full`,JSON:`${z}/findNearestAddressJSON?formatted=true&lat=37.451&lng=-122.18&username=demo&style=full`}},{name:"findNearestIntersection",docHref:"/maps/us-reverse-geocoder.html#findNearestIntersection",formats:{XML:`${z}/findNearestIntersection?lat=37.451&lng=-122.18&username=demo&style=full`,JSON:`${z}/findNearestIntersectionJSON?formatted=true&lat=37.451&lng=-122.18&username=demo&style=full`}},{name:"findNearestIntersectionOSM",docHref:"/maps/osm-reverse-geocoder.html#findNearestIntersectionOSM",formats:{XML:`${z}/findNearestIntersectionOSM?lat=37.451&lng=-122.18&username=demo&style=full`,JSON:`${z}/findNearestIntersectionOSMJSON?formatted=true&lat=37.451&lng=-122.18&username=demo&style=full`}},{name:"findNearbyPOIsOSM",docHref:"/maps/osm-reverse-geocoder.html#findNearbyPOIsOSM",formats:{XML:`${z}/findNearbyPOIsOSM?lat=37.451&lng=-122.18&username=demo&style=full`,JSON:`${z}/findNearbyPOIsOSMJSON?formatted=true&lat=37.451&lng=-122.18&username=demo&style=full`}},{name:"address",docHref:"/maps/addresses.html#address",formats:{XML:`${z}/address?lat=52.358&lng=4.881&username=demo`,JSON:`${z}/addressJSON?lat=52.358&lng=4.881&username=demo`}},{name:"geoCodeAddress",docHref:"/maps/addresses.html#geoCodeAddress",formats:{XML:`${z}/geoCodeAddress?q=Museumplein+6+amsterdam&username=demo`,JSON:`${z}/geoCodeAddressJSON?q=Museumplein+6+amsterdam&username=demo`}},{name:"streetNameLookup",docHref:"/maps/addresses.html#streetNameLookup",formats:{XML:`${z}/streetNameLookup?q=Museum&country=NL&username=demo`,JSON:`${z}/streetNameLookupJSON?q=Museum&country=NL&username=demo`}},{name:"get",docHref:"/export/web-services.html#get",formats:{XML:`${z}/get?geonameId=6295630&username=demo&style=full`,JSON:`${z}/getJSON?formatted=true&geonameId=6295630&username=demo&style=full`}},{name:"gtopo30",docHref:"/export/web-services.html#gtopo30",formats:{XML:`${z}/gtopo30?lat=47.01&lng=10.2&username=demo&style=full&type=XML`,JSON:`${z}/gtopo30JSON?formatted=true&lat=47.01&lng=10.2&username=demo&style=full`,TXT:`${z}/gtopo30?lat=47.01&lng=10.2&username=demo&style=full`}},{name:"hierarchy",docHref:"https://www.geonames.org/export/place-hierarchy.html#hierarchy",formats:{XML:`${z}/hierarchy?geonameId=2657896&username=demo&style=full`,JSON:`${z}/hierarchyJSON?formatted=true&geonameId=2657896&username=demo&style=full`}},{name:"neighbourhood",docHref:"/export/web-services.html#neighbourhood",formats:{XML:`${z}/neighbourhood?lat=40.78343&lng=-73.96625&username=demo&style=full`,JSON:`${z}/neighbourhoodJSON?formatted=true&lat=40.78343&lng=-73.96625&username=demo&style=full`}},{name:"neighbours",docHref:"https://www.geonames.org/export/place-hierarchy.html#neighbours",formats:{XML:`${z}/neighbours?geonameId=2658434&username=demo&style=full`,JSON:`${z}/neighboursJSON?formatted=true&geonameId=2658434&username=demo&style=full`}},{name:"ocean",docHref:"/export/web-services.html#ocean",formats:{XML:`${z}/ocean?lat=40.78343&lng=-43.96625&username=demo&style=full`,JSON:`${z}/oceanJSON?formatted=true&lat=40.78343&lng=-43.96625&username=demo&style=full`}},{name:"postalCodeCountryInfo",docHref:"/export/web-services.html#postalCodeCountryInfo",formats:{XML:`${z}/postalCodeCountryInfo?username=demo&style=full`,JSON:`${z}/postalCodeCountryInfoJSON?formatted=true&username=demo&style=full`}},{name:"postalCodeLookup",docHref:"/export/web-services.html#postalCodeLookupJSON",formats:{JSON:`${z}/postalCodeLookupJSON?formatted=true&postalcode=6600&country=AT&username=demo&style=full`}},{name:"postalCodeSearch",docHref:"/export/web-services.html#postalCodeSearch",formats:{XML:`${z}/postalCodeSearch?postalcode=9011&maxRows=10&username=demo&style=full`,JSON:`${z}/postalCodeSearchJSON?formatted=true&postalcode=9011&maxRows=10&username=demo&style=full`}},{name:"rssToGeo",docHref:"https://www.geonames.org/rss-to-georss-converter.html",formats:{RSS:`${z}/rssToGeoRSS?feedUrl=http://feeds.reuters.com/reuters/worldNews&username=demo&style=full`,KML:`${z}/rssToGeoRSS?type=kml&feedUrl=http://feeds.reuters.com/reuters/worldNews&username=demo&style=full`}},{name:"search",docHref:"https://www.geonames.org/export/geonames-search.html",formats:{XML:`${z}/search?q=london&maxRows=10&lang=es&username=demo&style=full`,JSON:`${z}/searchJSON?formatted=true&q=london&maxRows=10&lang=es&username=demo&style=full`,RDF:`${z}/searchRDF?q=london&maxRows=10&lang=es&username=demo&style=full`}},{name:"siblings",docHref:"https://www.geonames.org/export/place-hierarchy.html#siblings",formats:{XML:`${z}/siblings?geonameId=3017382&username=demo&style=full`,JSON:`${z}/siblingsJSON?formatted=true&geonameId=3017382&username=demo&style=full`}},{name:"srtm1",docHref:"/export/web-services.html#srtm1",formats:{XML:`${z}/srtm1XML?lat=50.01&lng=10.2&username=demo&style=full`,JSON:`${z}/srtm1JSON?formatted=true&lat=50.01&lng=10.2&username=demo&style=full`,TXT:`${z}/srtm1?lat=50.01&lng=10.2&username=demo&style=full`}},{name:"srtm3",docHref:"/export/web-services.html#srtm3",formats:{XML:`${z}/srtm3XML?lat=50.01&lng=10.2&username=demo&style=full`,JSON:`${z}/srtm3JSON?formatted=true&lat=50.01&lng=10.2&username=demo&style=full`,TXT:`${z}/srtm3?lat=50.01&lng=10.2&username=demo&style=full`}},{name:"timezone",docHref:"/export/web-services.html#timezone",formats:{XML:`${z}/timezone?lat=47.01&lng=10.2&username=demo&style=full`,JSON:`${z}/timezoneJSON?formatted=true&lat=47.01&lng=10.2&username=demo&style=full`}}
47,{name:"weather",docHref:"https://www.geonames.org/export/JSON-webservices.html#weatherJSON",formats:{XML:`${z}/weather?north=44.1&south=-9.9&east=-22.4&west=55.2&username=demo&style=full`,JSON:`${z}/weatherJSON?formatted=true&north=44.1&south=-9.9&east=-22.4&west=55.2&username=demo&style=full`}},{name:"weatherIcao",docHref:"https://www.geonames.org/export/JSON-webservices.html#weatherIcaoJSON",formats:{XML:`${z}/weatherIcao?ICAO=LSZH&username=demo&style=full`,JSON:`${z}/weatherIcaoJSON?formatted=true&ICAO=LSZH&username=demo&style=full`}},{name:"wikipediaBoundingBox",docHref:"https://www.geonames.org/export/wikipedia-webservice.html#wikipediaBoundingBox",formats:{XML:`${z}/wikipediaBoundingBox?north=44.1&south=-9.9&east=-22.4&west=55.2&username=demo&style=full`,JSON:`${z}/wikipediaBoundingBoxJSON?formatted=true&north=44.1&south=-9.9&east=-22.4&west=55.2&username=demo&style=full`}},{name:"wikipediaSearch",docHref:"https://www.geonames.org/export/wikipedia-webservice.html#wikipediaSearch",formats:{XML:`${z}/wikipediaSearch?q=london&maxRows=10&username=demo&style=full`,JSON:`${z}/wikipediaSearchJSON?formatted=true&q=london&maxRows=10&username=demo&style=full`}}];var UR=(e,n)=>n.name;function jR(e,n){if(e&1&&(l(0,"th"),s(1),a()),e&2){let t=n.$implicit;d(),g(t)}}function BR(e,n){if(e&1&&(l(0,"a",4),s(1),a()),e&2){let t=p().$implicit;v("href",n,Y),d(),g(t)}}function HR(e,n){if(e&1&&(l(0,"td"),y(1,BR,2,2,"a",4),a()),e&2){let t,i=n.$implicit,o=p().$implicit;d(),_((t=o.formats[i])?1:-1,t)}}function $R(e,n){if(e&1&&(l(0,"tr")(1,"td",2),s(2),a(),l(3,"td")(4,"a",4),s(5),a()(),I(6,HR,2,1,"td",null,Re),a()),e&2){let t=n.$implicit,i=n.$index,o=p();d(2),g(i+1),d(2),v("href",t.docHref,Y),d(),g(t.name),d(),T(o.formatColumns)}}function zR(e,n){if(e&1&&(l(0,"td"),s(1),a()),e&2){let t=n.$implicit,i=p();d(),g(i.totalsByFormat[t])}}var Ed=class e{title=h(H);formatColumns=zh;rows=a1;totalsByFormat=Object.fromEntries(zh.map(n=>[n,this.rows.filter(t=>t.formats[n]).length]));constructor(){this.title.setTitle("WebServices overview \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-ws-overview"]],decls:23,vars:0,consts:[[1,"table-scroll"],[1,"ws-table"],[1,"num-col"],[1,"ws-note"],["target","_blank","rel","noopener noreferrer",3,"href"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"GeoNames WebServices overview"),a(),l(2,"div",0)(3,"table",1)(4,"thead")(5,"tr"),j(6,"th",2),l(7,"th"),s(8,"WebService"),a(),I(9,jR,2,1,"th",null,Re),a()(),l(11,"tbody"),I(12,$R,8,3,"tr",null,UR),a(),l(14,"tfoot")(15,"tr"),j(16,"td",2),l(17,"td"),s(18,"Total"),a(),I(19,zR,2,1,"td",null,Re),a()()()(),l(21,"p",3),s(22,"Some webservices above (the US/OSM reverse-geocoders and address lookups) are only available for limited regions."),a()),t&2&&(d(9),T(i.formatColumns),d(3),T(i.rows),d(7),T(i.formatColumns))},styles:["[_nghost-%COMP%]{display:block;max-width:900px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.6rem}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto}.ws-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem;white-space:nowrap}.ws-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .ws-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.4rem .6rem;border-bottom:1px solid #eee;text-align:left}.ws-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555;font-weight:600}.ws-table[_ngcontent-%COMP%]   .num-col[_ngcontent-%COMP%]{color:#999;text-align:right;padding-right:.3rem;width:1%}.ws-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.ws-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.ws-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.ws-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-table[_ngcontent-%COMP%]   tfoot[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{font-weight:600;border-top:2px solid #ddd;border-bottom:none}.ws-note[_ngcontent-%COMP%]{margin-top:1rem;
47color:#777;font-size:.8rem}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var X="http://api.geonames.org",s1=[{id:"astergdem",title:"Elevation - ASTER Global Digital Elevation Model V2 (2011)",intro:["A product of METI and NASA. Sample area ca. 30m x 30m, covering latitudes between 83\xB0N and 65\xB0S.","Compared to SRTM3, ASTER GDEM has finer resolution but is unprocessed - it still contains occasional holes and data errors that SRTM3 has had corrected."],urlPattern:`${X}/astergdem?`,parameters:["lat, lng - the coordinate to look up","request method: GET or POST"],result:'A single number giving the elevation in meters. Ocean areas are masked as "no data" and returned as -32768.',examples:[{label:"XML",href:`${X}/astergdem?lat=50.01&lng=10.2&username=demo&style=full&type=XML`},{label:"JSON",href:`${X}/astergdemJSON?formatted=true&lat=50.01&lng=10.2&username=demo&style=full`}],notes:["The plain-text variant also accepts lists of points via the lats/lngs parameters - up to 20 points per call on the free server, 2000 on the premium service."]},{id:"countrycode",title:"CountryCode / reverse geocoding",intro:["The ISO country code for any given point."],urlPattern:`${X}/countryCode?`,parameters:["lat, lng - the coordinate to look up","type - xml or JSON; without it, plain text is returned","lang - language for the country name (used with type=xml/JSON)","radius - buffer in km for the closest country in coastal areas (a positive value expands the area searched, negative reduces it)"],result:"The ISO country code for the point. With type=xml or type=JSON the response also includes the full country name.",examples:[{label:"XML",href:`${X}/countryCodeXML?lat=47.03&lng=10.2&username=demo&style=full`},{label:"JSON",href:`${X}/countryCodeJSON?formatted=true&lat=47.03&lng=10.2&username=demo&style=full`},{label:"TXT",href:`${X}/countryCode?lat=47.03&lng=10.2&username=demo&style=full`}]},{id:"countryInfo",title:"Country Info (bounding box, capital, area, population)",urlPattern:`${X}/countryInfo?`,parameters:["country - ISO country code (optional, default is all countries)","lang - ISO-639-1 language code, e.g. en/de/fr/it/es (optional, default English)"],result:"Capital, population, area in km\xB2, and the bounding box of the mainland (excluding offshore islands).",examples:[{label:"XML",href:`${X}/countryInfo?lang=it&country=DE&username=demo&style=full`},{label:"JSON",href:`${X}/countryInfoJSON?formatted=true&lang=it&country=DE&username=demo&style=full`},{label:"CSV",href:`${X}/countryInfoCSV?lang=it&country=DE&username=demo&style=full`}]},{id:"countrysubdiv",title:"Country Subdivision / reverse geocoding",intro:["The ISO country code and administrative subdivision (state, province, ...) for any given point."],urlPattern:`${X}/countrySubdivision?`,parameters:["lat, lng - the coordinate to look up","lang - default returns names in the local language","radius - buffer in km for the closest country in coastal areas","level - which ADM level to return"],result:"The country and administrative subdivision for the point. Adding radius + maxRows instead returns the closest subdivisions ordered by distance.",examples:[{label:"XML",href:`${X}/countrySubdivision?lat=47.03&lng=10.2&username=demo&style=full`},{label:"JSON",href:`${X}/countrySubdivisionJSON?formatted=true&lat=47.03&lng=10.2&username=demo&style=full`}]},{id:"extendedFindNearby",title:"Extended Find Nearby Toponym / reverse geocoding",intro:["Returns the most detailed information available for a point - a combination of several other services depending on location: address details in the US, the place hierarchy elsewhere, or the ocean name over water."],urlPattern:`${X}/extendedFindNearby?`,parameters:["lat, lng - the coordinate to look up"],result:"The most detailed information available for the given point.",examples:[{label:"XML",href:`${X}/extendedFindNearby?lat=46.2022156980098&lng=6.14569187164307&username=demo&style=full`}]},{id:"findNearby",title:"Find Nearby Toponym / reverse geocoding",urlPattern:`${X}/findNearby?`,parameters:["lat, lng - the coordinate to look up","featureClass, featureCode - may be repeated; prefix a featureCode with '!=' to exclude it","radius - in km (optional)","maxRows - default 10","style - SHORT, MEDIUM, LONG, FULL (default MEDIUM)","localCountry - restrict the search to the local country in border areas (value=true)"],result:"The closest toponym matching the given feature class/code for the point.",examples:[{label:"XML",href:`${X}/findNearby?lat=48.865618158309374&lng=2.344207763671875&fclass=P&fcode=PPLA&fcode=PPL&fcode=PPLC&username=demo&style=full`},{label:"JSON",href:`${X}/findNearbyJSON?formatted=true&lat=48.865618158309374&lng=2.344207763671875&fclass=P&fcode=PPLA&fcode=PPL&fcode=PPLC&username=demo&style=full`}]},{id:"findNearbyPlaceName",title:"Find Nearby Populated Place / reverse geocoding",urlPattern:`${X}/findNearbyPlaceName?`,parameters:["lat, lng - the coordinate to look up","lang - language of the returned 'name' (the pseudo-language 'local' returns it in the local language)","radius - in km (optional)","maxRows - default 10","style - SHORT, MEDIUM, LONG, FULL (default MEDIUM)","localCountry - restrict the search to the local country in border areas","cities - optional filter: 'cities1000', 'cities5000' or 'cities15000'"],result:"The closest populated place (feature class P) for the point; the distance element is in km.",examples:[{label:"XML",href:`${X}/findNearbyPlaceName?lat=47.3&lng=9&username=demo&style=full`},{label:"JSON",href:`${X}/findNearbyPlaceNameJSON?formatted=true&lat=47.3&lng=9&username=demo&style=full`}]},{id:"findNearbyPostalCodes",title:"Find Nearby Postal Codes / reverse geocoding",intro:["Comes in two flavors: pass either a lat/lng, or a postalcode/placename."],urlPattern:`${X}/findNearbyPostalCodes?`,parameters:["lat, lng, radius (km), maxRows (default 5), style, country (default all countries), localCountry, isReduced (only the first part of the code, for GB/NL)","or: postalcode, country, radius (km), maxRows (default 5)","Limits: 30km radius / 500 maxRows on the free service, 160km / 2500 maxRows on the premium service."],result:"Postal codes and places for the query, sorted by distance. For Canada the FSA (first 3 characters of the full code) is returned.",examples:[{label:"XML",href:`${X}/findNearbyPostalCodes?postalcode=8775&country=CH&radius=10&username=demo&style=full`},{label:"JSON",href:`${X}/findNearbyPostalCodesJSON?formatted=true&postalcode=8775&country=CH&radius=10&username=demo&style=full`}]},{id:"get",title:"Get GeoNames Feature for geonameId",urlPattern:`${X}/get?`,parameters:["geonameId - required","lang - optional","style - optional"],result:"The attributes of the GeoNames feature with the given geonameId.",examples:[{label:"XML",href:`${X}/get?geonameId=6295630&username=demo&style=full`},{label:"JSON",href:`${X}/getJSON?formatted=true&geonameId=6295630&username=demo&style=full`}]},{id:"gtopo30",title:"Elevation - GTOPO30",intro:["A global DEM with a horizontal grid spacing of 30 arc-seconds (roughly 1km), derived from several raster and vector topographic sources (USGS)."],urlPattern:`${X}/gtopo30?`,parameters:["lat, lng - the coordinate to look up (sample area ca. 1km x 1km)"],result:'A single number giving the elevation in meters. Ocean areas are masked as "no data" and returned as -9999.',examples:[{label:"XML",href:`${X}/gtopo30?lat=47.01&lng=10.2&username=demo&style=full&type=XML`},{label:"JSON",href:`${X}/gtopo30JSON?formatted=true&lat=47.01&lng=10.2&username=demo&style=full`},{label:"TXT",href:`${X}/gtopo30?lat=47.01&lng=10.2&username=demo&style=full`}]},{id:"neighbourhood",title:"Neighbourhood / reverse geocoding",intro:["Neighbourhoods for US cities. Data provided by Zillow under a CC BY-SA license."],urlPattern:`${X}/neighbourhood?`,parameters:["lat, lng - the coordinate to look up"],result:"The neighbourhood for the given point.",examples:[{label:"XML",href:`${X}/neighbourhood?lat=40.78343&lng=-73.96625&username=demo&style=full`},{label:"JSON",href:`${X}/neighbourhoodJSON?formatted=true&lat=40.78343&lng=-73.96625&username=demo&style=full`}]},{id:"ocean",title:"Ocean / reverse geocoding",intro:["The name of the ocean or sea at a given point."],urlPattern:`${X}/ocean?`,parameters:["lat, lng - the coordinate to look up","radius - optional"],result:"The ocean or sea for the given point.",examples:[{label:"XML",href:`${X}/ocean?lat=40.78343&lng=-43.96625&username=demo&style=full`},{label:"JSON",href:`${X}/oceanJSON?formatted=true&lat=40.78343&lng=-43.96625&username=demo&style=full`}]},{id:"postalCodeCountryInfo",title:"Postal Code Country Info",urlPattern:`${X}/postalCodeCountryInfo?`,result:"The list of countries for which postal-code geocoding is available.",examples:[{label:"XML",href:`${X}/postalCodeCountryInfo?username=demo&style=full`},{label:"JSON",href:`${X}/postalCodeCountryInfoJSON?formatted=true&username=demo&style=full`}]},{id:"postalCodeLookupJSON",title:"Placename Lookup with Postal Code (JSON)",urlPattern:`${X}/postalCodeLookupJSON?`,parameters:["postalcode","country","maxRows - default 20","callback","charset - default 'UTF-8'"],result:"Places for the given postal code, sorted by postalcode then placename. JSON only.",examples:[{label:"JSON",href:`${X}/postalCodeLookupJSON?formatted=true&postalcode=6600&country=AT&username=demo&style=full`}]},{id:"postalCodeSearch",title:"Postal Code Search",intro:["For the US, the first returned zip code is determined from zip-code area shapes; the remaining results (and all results for every other supported country) are based on centroids."],urlPattern:`${X}/postalCodeSearch?`,parameterTable:[{name:"postalcode",value:"string (postalcode or placename required)",description:"postal code"},{name:"postalcode_startsWith",value:"string",description:"the first characters or letters of a postal code"},{name:"placename",value:"string (postalcode or placename required)",description:"matched against placename, postal code, country, admin name (URL-encoded UTF-8)"},{name:"placename_startsWith",value:"string",description:"the first characters of a place name"},{name:"country",value:"ISO-3166 country code (optional)",description:"default is all countries; may be repeated, e.g. country=FR&country=GP"},{name:"countryBias",value:"string",description:"records from this country are listed first"},{name:"maxRows",value:"integer (optional)",description:"maximum rows returned; default 10"},{name:"style",value:"SHORT, MEDIUM, LONG, FULL (optional)",description:"verbosity of the returned document; default MEDIUM"},{name:"operator",value:"AND, OR (optional)",description:"AND requires every term in placename to match, OR any term; default AND"},{name:"charset",value:"string (optional)",description:"encoding of the returned document; default 'UTF8'"},{name:"isReduced",value:"true or false (optional)",description:"default 'false'; when true, only the UK outer code / NL 4 digits are returned"},{name:"east, west, north, south",value:"float (optional)",description:"bounding box - only features inside it are returned"}],result:"A list of postal codes and places matching the placename/postalcode query.",examples:[{label:"XML",href:`${X}/postalCodeSearch?postalcode=9011&maxRows=10&username=demo&style=full`},{label:"JSON",href:`${X}/postalCodeSearchJSON?formatted=true&postalcode=9011&maxRows=10&username=demo&style=full`}]},{id:"srtm1",title:"Elevation - SRTM1",intro:["Sample area ca. 30m x 30m."],urlPattern:`${X}/srtm1?`,parameters:["lat, lng - the coordinate to look up","request method: GET or POST"],result:'A single number giving the elevation in meters. Ocean areas are masked as "no data" and returned as -32768.',examples:[{label:"XML",href:`${X}/srtm1XML?lat=50.01&lng=10.2&username=demo&style=full`},{label:"JSON",href:`${X}/srtm1JSON?formatted=true&lat=50.01&lng=10.2&username=demo&style=full`},{label:"TXT",href:`${X}/srtm1?lat=50.01&lng=10.2&username=demo&style=full`}],notes:["The plain-text variant also accepts lists of points via lats/lngs - up to 20 points per call free, 2000 on the premium service."]},{id:"srtm3",title:"Elevation - SRTM3",intro:["Shuttle Radar Topography Mission data, captured aboard Space Shuttle Endeavour in February 2000, covering land between 60\xB0N and 56\xB0S at roughly 90m (3 arc-second) resolution.","Data voids in the original files have been filled in by CGIAR-CSI."],urlPattern:`${X}/srtm3?`,parameters:["lat, lng - the coordinate to look up","request method: GET or POST"],result:'A single number giving the elevation in meters. Ocean areas are masked as "no data" and returned as -32768.',examples:[{label:"XML",href:`${X}/srtm3XML?lat=50.01&lng=10.2&username=demo&style=full`},{label:"JSON",href:`${X}/srtm3JSON?formatted=true&lat=50.01&lng=10.2&username=demo&style=full`},{label:"TXT",href:`${X}/srtm3?lat=50.01&lng=10.2&username=demo&style=full`}],notes:["The plain-text variant also accepts lists of points via lats/lngs - up to 20 points per call free, 2000 on the premium service."]},{id:"timezone",title:"Timezone",urlPattern:`${X}/timezone?`,parameters:["lat, lng - the coordinate to look up","radius - buffer in km for the closest timezone in coastal areas","lang - language for the country name","date - date to compute sunrise/sunset for"],result:"The timezone at the point, with its GMT offset (1 January) and DST offset (1 July).",examples:[{label:"XML",href:`${X}/timezone?lat=47.01&lng=10.2&username=demo&style=full`},{label:"JSON",href:`${X}/timezoneJSON?formatted=true&lat=47.01&lng=10.2&username=demo&style=full`}],responseFields:[{name:"countryCode",description:"ISO country code"},{name:"countryName",description:"name (language can be set with the lang parameter)"},{name:"timezoneId",description:"the Olson timezone name - sufficient to resolve DST rules in most programming environments"},{name:"time",description:"the local current time"},{name:"sunset",description:"local sunset time"},{name:"sunrise",description:"local sunrise time"},{name:"rawOffset",description:"hours to add to UTC for standard time in this zone (unaffected by DST)"},{name:"gmtOffset",description:"offset to GMT at 1 January (deprecated)"},{name:"dstOffset",description:"offset to GMT at 1 July (deprecated)"}]}];var l1=(e,n)=>n.id,GR=(e,n)=>n.href,c1=(e,n)=>n.name;function WR(e,n){if(e&1&&(l(0,"a",7),s(1),a()),e&2){let t=n.$implicit;v("href","#"+t.id,Y),d(),g(t.title)}}function qR(e,n){if(e&1&&(l(0,"p"),s(1),a()),e&2){let t=n.$implicit;d(),g(t)}}function JR(e,n){if(e&1&&(l(0,"li"),s(1),a()),e&2){let t=n.$implicit;d(),g(t)}}function KR(e,n){if(e&1&&(l(0,"h3"),s(1,"Parameters"),a(),l(2,"ul",20),I(3,JR,2,1,"li",null,Re),a()),e&2){let t=p().$implicit;d(3),T(t.parameters)}}function YR(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),a(),l(3,"td"),s(4),a(),l(5,"td"),s(6),a()()),e&2){let t=n.$implicit;d(2),g(t.name),d(2),g(t.value),d(2),g(t.description)}}function ZR(e,n){if(e&1&&(l(0,"h3"),s(1,"Parameters"),a(),l(2,"div",24)(3,"table",25)(4,"thead")(5,"tr")(6,"th"),s(7,"Parameter"),a(),l(8,"th"),s(9,"Value"),a(),l(10,"th"),s(11,"Description"),a()()(),l(12,"tbody"),I(13,YR,7,3,"tr",null,c1),a()()()),e&2){let t=p().$implicit;d(13),T(t.parameterTable)}}function QR(e,n){if(e&1&&(l(0,"li")(1,"code"),s(2),a(),s(3),a()),e&2){let t=n.$implicit;d(2),g(t.name),d(),A(": ",t.description,"")}}function XR(e,n){if(e&1&&(l(0,"ul",20),I(1,QR,4,2,"li",null,c1),a()),e&2){let t=p().$implicit;d(),T(t.responseFields)}}function e3(e,n){if(e&1&&(l(0,"a",22),s(1),a()),e&2){let t=n.$implicit;v("href",t.href,Y),d(),g(t.label)}}function t3(e,n){if(e&1&&(l(0,"p",23),s(1),a()),e&2){let t=n.$implicit;d(),g(t)}}function n3(e,n){if(e&1&&(l(0,"section",18)(1,"h2"),s(2),a(),I(3,qR,2,1,"p",null,Re),l(5,"dl",19)(6,"dt"),s(7,"Url"),a(),l(8,"dd")(9,"code"),s(10),a()()(),y(11,KR,5,0)(12,ZR,15,0),l(13,"h3"),s(14,"Result"),a(),l(15,"p"),s(16),a(),y(17,XR,3,0,"ul",20),l(18,"h3"),s(19,"Example"),a(),l(20,"p",21),I(21,e3,2,2,"a",22,GR),a(),I(23,t3,2,1,"p",23,Re),a()),e&2){let t=n.$implicit;v("id",t.id),d(2),g(t.title),d(),T(t.intro),d(7),g(t.urlPattern),d(),_(t.parameters?11:-1),d(),_(t.parameterTable?12:-1),d(4),g(t.result),d(),_(t.responseFields?17:-1),d(4),T(t.examples),d(2),T(t.notes)}}var Md=class e{title=h(H);sections=s1;constructor(){this.title.setTitle("GeoNames Web Service Documentation \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};sta
47tic \u0275cmp=k({type:e,selectors:[["app-web-services-doc"]],decls:83,vars:0,consts:[[1,"lead"],[1,"notice"],["href","https://www.geonames.org/login","target","_blank","rel","noopener noreferrer"],["routerLink","/export/ws-overview.html"],["routerLink","/export/credits.html"],["routerLink","/export/webservice-exception.html"],[1,"toc"],[3,"href"],[1,"elsewhere"],["href","https://www.geonames.org/export/place-hierarchy.html#children","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/export/place-hierarchy.html#hierarchy","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/export/place-hierarchy.html#siblings","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/export/place-hierarchy.html#neighbours","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/export/wikipedia-webservice.html#findNearbyWikipedia","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/export/wikipedia-webservice.html#wikipediaSearch","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/export/JSON-webservices.html","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/rss-to-georss-converter.html","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/ontology/documentation.html","target","_blank","rel","noopener noreferrer"],[1,"ws-section",3,"id"],[1,"meta"],[1,"param-list"],[1,"examples"],["target","_blank","rel","noopener noreferrer",3,"href"],[1,"note"],[1,"table-scroll"],[1,"param-table"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"GeoNames Web Service Documentation"),a(),l(2,"p",0),s(3,"GeoNames is mainly using REST webservices."),a(),l(4,"div",1)(5,"strong"),s(6,"Important"),a(),l(7,"ul")(8,"li"),s(9,"Don't use the "),l(10,"code"),s(11,"demo"),a(),s(12," account in your own app or tests - it's only for the sample links on this page. "),l(13,"a",2),s(14,"Register your own free account"),a(),s(15," instead."),a(),l(16,"li"),s(17,"The "),l(18,"code"),s(19,"username"),a(),s(20," parameter is required on every request."),a(),l(21,"li"),s(22,"URL-encode string parameters that contain spaces or special characters."),a(),l(23,"li"),s(24,"Prefer the JSON services from JavaScript - most browsers block cross-origin XML calls to another server."),a(),l(25,"li"),s(26," See also: "),l(27,"a",3),s(28,"all webservices on one table"),a(),s(29,", "),l(30,"a",4),s(31,"credits per request"),a(),s(32,", and "),l(33,"a",5),s(34,"exceptions / error handling"),a(),s(35,". "),a()(),l(36,"strong"),s(37,"Postal code restrictions"),a(),l(38,"ul")(39,"li"),s(40,"Canada, Ireland and Malta: only the first letters of the full postal code (copyright reasons)."),a(),l(41,"li"),s(42,"Argentina: the data file uses 4-digit codes, superseded by a new system in 1999."),a(),l(43,"li"),s(44,"Brazil: only major postal codes are available (codes ending in -000, one per municipality)."),a()()(),l(45,"nav",6)(46,"strong"),s(47,"On this page:"),a(),I(48,WR,2,2,"a",7,l1),a(),l(50,"nav",8)(51,"div")(52,"strong"),s(53,"Place Hierarchy Webservices"),a(),l(54,"a",9),s(55,"Children"),a(),l(56,"a",10),s(57,"Hierarchy"),a(),l(58,"a",11),s(59,"Siblings"),a(),l(60,"a",12),s(61,"Neighbours"),a()(),l(62,"div")(63,"strong"),s(64,"Wikipedia Webservices"),a(),l(65,"a",13),s(66,"Find nearby Wikipedia entries"),a(),l(67,"a",14),s(68,"Wikipedia full text search"),a()(),l(69,"div")(70,"strong"),s(71,"JSON Webservices"),a(),l(72,"a",15),s(73,"Cities and placenames, earthquakes, weather stations"),a()(),l(74,"div")(75,"strong"),s(76,"Other Webservices"),a(),l(77,"a",16),s(78,"RSS to GeoRSS conversion"),a(),l(79,"a",17),s(80,"Semantic Web webservices"),a()()(),I(81,n3,25,7,"section",18,l1)),t&2&&(d(48),T(i.sections),d(33),T(i.sections))},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem}.notice[_ngcontent-%COMP%]{background:#fff8e1;border:1px solid #f2d675;border-radius:8px;padding:.75rem 1rem;font-size:.85rem;margin-bottom:1.25rem}.notice[_ngcontent-%COMP%]   strong[_ngcontent-%COMP%]{display:block;margin:.5rem 0 .25rem;font-size:.8rem;text-transform:uppercase;letter-spacing:.03em;color:#8a6d00}.notice[_ngcontent-%COMP%]   strong[_ngcontent-%COMP%]:first-child{margin-top:0}.notice[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:0 0 .25rem;padding-left:1.2rem}.notice[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.2rem 0}.notice[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:#0000000f;padding:.05rem .3rem;border-radius:3px}.toc[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.15rem;font-size:.8rem;background:#f8f9fa;border-radius:8px;padding:.75rem 1rem;margin-bottom:1rem;max-height:220px;overflow-y:auto}.toc[_ngcontent-%COMP%]   strong[_ngcontent-%COMP%]{margin-bottom:.2rem;font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;
47color:#777}.elsewhere[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.75rem 1.5rem;font-size:.8rem;margin-bottom:1.5rem}.elsewhere[_ngcontent-%COMP%] > div[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.15rem}.elsewhere[_ngcontent-%COMP%]   strong[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;color:#777;margin-bottom:.1rem}a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem;scroll-margin-top:1rem}.ws-section[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%]{font-size:.85rem;text-transform:uppercase;letter-spacing:.03em;color:#777;margin:1rem 0 .4rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.meta[_ngcontent-%COMP%]{margin:.5rem 0;font-size:.85rem}.meta[_ngcontent-%COMP%]   dt[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;color:#777}.meta[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]{margin:.1rem 0 0}.meta[_ngcontent-%COMP%]   code[_ngcontent-%COMP%], .ws-section[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:#f8f9fa;padding:.05rem .35rem;border-radius:3px;font-size:.85em}.param-list[_ngcontent-%COMP%]{margin:0;padding-left:1.2rem;font-size:.88rem}.param-list[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.25rem 0}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto}.param-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.82rem}.param-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .param-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .6rem;border-bottom:1px solid #eee;text-align:left;vertical-align:top}.param-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555}.param-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.param-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.examples[_ngcontent-%COMP%]{display:flex;gap:.6rem}.note[_ngcontent-%COMP%]{color:#777;font-size:.82rem}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}.elsewhere[_ngcontent-%COMP%]{grid-template-columns:1fr}}"]})};var Pd=class e{title=h(H);constructor(){this.title.setTitle("World Capitals Map \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-capitals-map-page"]],decls:11,vars:7,consts:[[1,"page-header"],[1,"page-title-row"],[1,"fclass-badge",2,"background-color","#F2F2F2","color","#434343"],[1,"page-intro"],["label","World capitals","onlyFeatureClass","P","onlyFeatureCode","PPLC",3,"latitude","longitude","zoom","showCenterMarker","autoFetchNearby","tall","preferRaster"]],template:function(t,i){t&1&&(l(0,"header",0)(1,"div",1)(2,"span",2),s(3,"P"),a(),l(4,"span",2),s(5,"PPLC"),a(),l(6,"h1"),s(7,"World Capitals"),a()(),l(8,"p",3),s(9,"National capital cities, shown on the map below."),a()(),j(10,"app-geo-map",4)),t&2&&(d(10),v("latitude",48)("longitude",9)("zoom",4)("showCenterMarker",!1)("autoFetchNearby",!0)("tall",!0)("preferRaster",!0))},dependencies:[nt],styles:[".page-header[_ngcontent-%COMP%]{margin:0 0 1rem}.page-title-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;margin:0 0 .35rem}.page-title-row[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{margin:0;font-size:1.6rem}.fclass-badge[_ngcontent-%COMP%]{display:inline-block;padding:.15rem .45rem;border-radius:4px;font-size:.75rem;font-weight:700;line-height:1.4}.page-intro[_ngcontent-%COMP%]{margin:0;color:#666;font-size:.92rem}"]})};var Dd=class e{title=h(H);constructor(){this.title.setTitle("Wikipedia Articles Map \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-wikipedia-map-page"]],decls:9,vars:8,consts:[[1,"page-header"],[1,"page-title-row"],[1,"wiki-badge"],[1,"page-intro"],["label","Wikipedia articles",3,"latitude","longitude","zoom","showCenterMarker","initialWikipediaEnabled","hideFeatureMarkers","tall","preferRaster"]],template:function(t,i){t&1&&(l(0,"header",0)(1,"div",1)(2,"span",2),s(3,"W"),a(),l(4,"h1"),s(5,"Wikipedia Articles Map"),a()(),l(6,"p",3),s(7,"Geotagged Wikipedia articles near the visible map area. Pan or zoom to explore other regions."),a()(),j(8,"a
47pp-geo-map",4)),t&2&&(d(8),v("latitude",20)("longitude",0)("zoom",2)("showCenterMarker",!1)("initialWikipediaEnabled",!0)("hideFeatureMarkers",!0)("tall",!0)("preferRaster",!0))},dependencies:[nt],styles:[".page-header[_ngcontent-%COMP%]{margin:0 0 1rem}.page-title-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;margin:0 0 .35rem}.page-title-row[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{margin:0;font-size:1.6rem}.wiki-badge[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;min-width:22px;height:22px;padding:0 .3rem;border-radius:4px;font-size:.8rem;font-weight:700;background:#777;color:#fff}.page-intro[_ngcontent-%COMP%]{margin:0;color:#666;font-size:.92rem}"]})};var d1=[{title:"Client Libraries",items:[{label:"Java Client",href:"/source-code/",note:"developed by the GeoNames team"},{label:"pgeocode - Python",href:"https://github.com/symerio/pgeocode"},{label:"Packagist PHP",href:"https://packagist.org/packages/aternus/geonames-client"},{label:"GeoClue-GeoNames - Ubuntu",href:"https://packages.ubuntu.com/bionic/geoclue-geonames"},{label:"ES-GEONAMES transform and load with logstash",href:"https://github.com/panchicore/es-geonames/tree/master/logstash"},{label:"cloudrail",href:"https://cloudrail.com/geonames-api-integration-cloudrail/",note:"Universal API"},{label:"Objective-C",href:"http://www.infinite-loop.dk/developer/ilgeonames/"},{label:"GeoNames Ruby API Wrapper",href:"https://github.com/WaKeMaTTa/geo_names/"},{label:"GeoNames Ruby",href:"http://github.com/elecnix/ruby-geonames",note:"fork from tbcn.ca Ruby Client"},{label:"Drupal Module",href:"http://drupal.org/project/geonames"},{label:"Drupal Project Page",href:"http://geonames.edesign.no/"},{label:"Geocoder - Python",href:"http://geocoder.readthedocs.io/providers/GeoNames.html"},{label:"geopy - Geocoding Toolbox for Python",href:"http://code.google.com/p/geopy/"},{label:"Perl GeoNames Client",href:"https://metacpan.org/pod/Geo::GeoNames"},{label:"Lisp Client",href:"http://code.google.com/p/cl-geonames/"},{label:"Elixir Client",href:"https://github.com/pareeohnos/geonames-elixir"},{label:"Pear PHP",href:"http://pear.php.net/package/Services_GeoNames"},{label:"Leaflet.Geonames",href:"https://github.com/consbio/Leaflet.Geonames"},{label:"Zend Framework PHP",href:"https://github.com/borisguery/bgylibrary/tree/master/library/Bgy/Service"},{label:"SOLMETRA Maps (PHP)",href:"http://www.solmetra.com/en/disp.php/en_products/en_scripts/en_maps"},{label:"Yii (PHP)",href:"http://www.yiiframework.com/extension/egeonameservice/"},{label:"PHP Laravel",href:"https://packagist.org/packages/michaeldrennen/geonames"},{label:"R-Project",href:"http://geonames.r-forge.r-project.org/"},{label:".NET NGeo (source)",href:"https://github.com/danludwig/NGeo"},{label:".NET NGeo (NuGet package)",href:"http://nuget.org/packages/NGeo"},{label:".NET WCF",href:"http://www.codeproject.com/KB/WCF/GeoNames-WCFClient.aspx"},{label:".NET 3.5",href:"http://geonamesdotorgdotnet.codeplex.com/"},{label:"GeoExt",href:"https://trac.geoext.org/wiki/ux/GeonamesSearch"},{label:"GeoNames API for ActionScript 3",href:"http://github.com/tylerchesley/GeoNamesAS3"},{label:"jeoQuery - jQuery for GeoNames",href:"http://tompi.github.com/jeoquery/"},{label:"geocoder for NodeJS",href:"https://github.com/StephanGeorg/geocoder-geonames"},{label:"Geode for NodeJS",href:"https://github.com/jacoblwe20/geode/blob/master/geode.js"},{label:"NodeJS streaming parser",href:"https://github.com/geopipes/geonames-stream"},{label:"nodeJs-geonames-client",href:"https://www.npmjs.org/package/node-geonames-client"},{label:"NodeJs geonames.js library",href:"https://github.com/kinotto/geonames.js"},{label:"Python RDF API client",href:"https://github.com/dsoprea/GeonamesRdf"},{label:"Swift - SimpleGeo",href:"https://github.com/thomashocking/SimpleGeo"}]},{title:"Tools",items:[{label:"GeoNames csv files to shp file converter",href:"http://sourceforge.net/p/topomapcreator/wiki/GeonamesToShapeTool/"},{label:"GeoNames couchbase importer",href:"https://github.com/ermanno-pirotta/geonames-couchbase-importer",note:"by Ermanno Pirotta"},{label:"wiki-place-rank",href:"https://github.com/madelfio/wiki-place-rank"},{label:"Geonames data parser into Shapefile/KML",href:"https://pypi.python.org/pypi/geonames/"}]},{title:"Plugins",items:[{label:"opensearch plugin",href:"javascript:window.external.AddSearchProvider('http://www.geonames.org/opensearch-description.xml');",note:"for Firefox and IE7"},{label:"Mozilla Plugin",href:"http://mycroft.mozdev.org/download.html?name=geonames&category=all&country=all&language=all&submitform=Search&sherlock=yes",note:"by Emilio Gomez Fern
47andez"},{label:"Geocode plugin for Geomajas",href:"http://geomajas.org/plugin/geocoder"},{label:"Bubble.is plugin",href:"https://bubble.is/plugin/geonames-1494481113122x465246193538826240"}]},{title:"Frameworks",items:[{label:"Gisgraphy",href:"http://www.gisgraphy.com/",note:"open source framework for GeoNames data, with importer, geolocalisation and fulltext search"},{label:"NGeoNames",href:"https://github.com/RobThree/NGeoNames",note:".Net package for downloading and parsing GeoNames.org files"}]}];var i3=(e,n)=>n.title,o3=(e,n)=>n.href;function r3(e,n){if(e&1&&(l(0,"span",3),s(1),a()),e&2){let t=p().$implicit;d(),A(" \u2014 ",t.note,"")}}function a3(e,n){if(e&1&&(l(0,"li")(1,"a",2),s(2),a(),y(3,r3,2,1,"span",3),a()),e&2){let t=n.$implicit;d(),v("href",t.href,Y),d(),g(t.label),d(),_(t.note?3:-1)}}function s3(e,n){if(e&1&&(l(0,"section",1)(1,"h2"),s(2),a(),l(3,"ul"),I(4,a3,4,3,"li",null,o3),a()()),e&2){let t=n.$implicit;d(2),g(t.title),d(2),T(t.items)}}var Id=class e{title=h(H);sections=d1;constructor(){this.title.setTitle("GeoNames Webservice Client Libraries \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-client-libraries"]],decls:6,vars:0,consts:[[1,"lead"],[1,"lib-section"],["target","_blank","rel","noopener noreferrer",3,"href"],[1,"note"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"Client Libraries"),a(),l(2,"p",0),s(3,"Client libraries to simplify access to the GeoNames web services exist in a couple of programming languages."),a(),I(4,s3,6,1,"section",1,i3)),t&2&&(d(4),T(i.sections))},styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1.25rem}.lib-section[_ngcontent-%COMP%]{padding:1rem 0;border-top:1px solid #eee}.lib-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.05rem;margin:0 0 .5rem}.lib-section[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:0;padding-left:1.2rem;font-size:.9rem}.lib-section[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.3rem 0}a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.note[_ngcontent-%COMP%]{color:#777;font-size:.85rem}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var u1=(e,n)=>n.credits;function l3(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),a(),l(3,"td"),s(4),a(),l(5,"td"),s(6),a(),l(7,"td"),s(8),a(),l(9,"td"),s(10),a(),l(11,"td")(12,"a",14),s(13,"Buy now"),a()()()),e&2){let t=n.$implicit,i=p();d(2),g(t.credits),d(2),g(t.perHour),d(2),g(t.perDay),d(2),g(t.perWeek),d(2),g(t.price),d(2),v("href",i.orderUrl(t.orderId),Y)}}function c3(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),a(),l(3,"td"),s(4),a(),l(5,"td"),s(6),a(),l(7,"td"),s(8),a(),l(9,"td"),s(10),a(),l(11,"td")(12,"a",14),s(13,"Buy now"),a()()()),e&2){let t=n.$implicit,i=p();d(2),g(t.credits),d(2),g(t.perHour),d(2),g(t.perDay),d(2),g(t.perWeek),d(2),g(t.price),d(2),v("href",i.orderUrl(t.orderId),Y)}}var Td=class e{title=h(H);bestAvailabilityPlans=[{credits:"1 000 000",perHour:"2 000",perDay:"20 000",perWeek:"100 000",price:"250 \u20AC",orderId:5},{credits:"5 000 000",perHour:"10 000",perDay:"100 000",perWeek:"500 000",price:"500 \u20AC",orderId:6}];bestPricePlans=[{credits:"100 000",perHour:"250",perDay:"2 000",perWeek:"10 000",price:"40 \u20AC",orderId:1},{credits:"1 000 000",perHour:"1 000",perDay:"10 000",perWeek:"50 000",price:"80 \u20AC",orderId:2},{credits:"5 000 000",perHour:"10 000",perDay:"100 000",perWeek:"500 000",price:"120 \u20AC",orderId:3},{credits:"12 000 000",perHour:"20 000",perDay:"150 000",perWeek:"500 000",price:"200 \u20AC",orderId:4},{credits:"25 000 000",perHour:"30 000",perDay:"250 000",perWeek:"1 000 000",price:"300 \u20AC",orderId:7}];orderUrl(n){return`https://www.geonames.org/orderpremiumapi/${n}/`}constructor(){this.title.setTitle("GeoNames Premium Web Services \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-commercial-webservices"]],decls:147,vars:0,consts:[[1,"lead"],["routerLink","/products/premium-data.html"],[1,"ws-section"],["routerLink","/export/ws-overview.html"],["routerLink","/export/web-services.html"],["routerLink","/export/client-libraries.html"],[1,"note"],["href","mailto:[email protected]"],["id","A"],[1,"table-scroll"],[1,"param-table"],["id","B"],["routerLink","/export/credits.html"],[1,"notice"],["target","_blank","rel","nofollow noopener noreferrer",1,"buy-btn",3,"href"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"GeoNames Premium Web Services"),a(),l(2,"p",0),s(3,` The GeoNames Premium Webservices are running on faster servers with more RAM and less load to guarantee fast and reliable response time. The commercial web services have higher uptime and failover to other servers in case of hardware defects or software bugs. By entering in a commercial relation with geonames.org you can be sure the services don't disappear one day without notice.
48`),a(),l(4,"p"),s(5," The GeoNames Premium Web Services are the right choice for you if you need fast, reliable response time and 
48you want to be sure the service keeps on running. If you want to implement your own services directly on the data the "),l(6,"a",1),s(7,"Premium Data Subscription"),a(),s(8,` will be your choice.
49`),a(),l(9,"section",2)(10,"h2"),s(11,"Webservice Documentation"),a(),l(12,"ul")(13,"li")(14,"a",3),s(15,"web service overview"),a()(),l(16,"li")(17,"a",4),s(18,"web service documentation"),a()(),l(19,"li")(20,"a",5),s(21,"web service client libraries"),a()()()(),l(22,"section",2)(23,"h2"),s(24,"Advantages of the 'Premium Webservices' over the 'free webservice'"),a(),l(25,"ul")(26,"li"),s(27,"faster response time thanks to better servers with more RAM and less load"),a(),l(28,"li"),s(29,"higher uptime"),a(),l(30,"li"),s(31,"software and data tested on free server before being deployed on commercial server"),a(),l(32,"li"),s(33,"failover to other server for 'Best Availability'"),a(),l(34,"li"),s(35,"support via email"),a(),l(36,"li"),s(37,"https secure connection"),a(),l(38,"li"),s(39,"usage charts"),a(),l(40,"li"),s(41,"guarantee that the web services are kept on running"),a(),l(42,"li"),s(43,"higher max limits for a couple of parameters like maxRows or startRow"),a(),l(44,"li"),s(45,"we know who the users of the commercial services are and can inform them about changes"),a()(),l(46,"p",6),s(47," The commercial services normally use the same data and software as the free services. Updates for data and software are deployed and tested on the free servers before being deployed on the commercial servers. "),a(),l(48,"p"),s(49," Contact Marc Wick ("),l(50,"a",7),s(51,"[email protected]"),a(),s(52,") for further information. "),a()(),l(53,"section",2)(54,"h2"),s(55,"Pricing"),a(),l(56,"p"),s(57," GeoNames offers two web service types, 'Best Availability' is meant for users who depend on the availability of the service for mission critical applications whereas 'Best Price' is for users who don't depend so much on availability. "),a(),l(58,"p"),s(59," For higher availability we recommend to include failover handling on the client side. This means that the client will access one of our failover datacenters if the main domain is unreachable. This way availability of nearly 100% is achievable. (This option is only available for 'Best Availability' Plan.) "),a(),l(60,"p"),s(61," You can anytime upgrade to a higher plan. Your credits will be converted to the higher plan, pro rata temporis of the remaining months. "),a(),l(62,"p",6),s(63," Please ask for a tailor made quote if you need more credits than included in the predefined plans. We will need to know the desired number of credits per day and availability. "),a(),l(64,"h3",8),s(65,"A) Best Availability"),a(),l(66,"p",6),s(67,"99.9% availability, near 100% with client failover, subdomain included. Credits valid for one year."),a(),l(68,"div",9)(69,"table",10)(70,"thead")(71,"tr")(72,"th"),s(73,"Total Credits"),a(),l(74,"th"),s(75,"max credits/hour"),a(),l(76,"th"),s(77,"max credits/day"),a(),l(78,"th"),s(79,"max credits/week"),a(),l(80,"th"),s(81,"price"),a(),j(82,"th"),a()(),l(83,"tbody"),I(84,l3,14,6,"tr",null,u1),a()()(),l(86,"h3",11),s(87,"B) Best Price"),a(),l(88,"p",6),s(89,"99% availability. Credits valid for one year."),a(),l(90,"div",9)(91,"table",10)(92,"thead")(93,"tr")(94,"th"),s(95,"Total Credits"),a(),l(96,"th"),s(97,"max credits/hour"),a(),l(98,"th"),s(99,"max credits/day"),a(),l(100,"th"),s(101,"max credits/week"),a(),l(102,"th"),s(103,"price"),a(),j(104,"th"),a()(),l(105,"tbody"),I(106,c3,14,6,"tr",null,u1),a()()()(),l(108,"section",2)(109,"h2"),s(110,"Credits needed per request"),a(),l(111,"p"),s(112," Most services require one credit per request. Services that consume a lot of resources need more credits, whereas services that require few resources consume less than one credit. You find the table of the services here: "),l(113,"a",12),s(114,"credits per request"),a(),s(115,". "),a()(),l(116,"section",2)(117,"h2"),s(118,"Validity"),a(),l(119,"p"),s(120,"The credits are valid for the period of one year."),a()(),l(121,"section",2)(122,"h2"),s(123,"Terms of Service"),a(),l(124,"p"),s(125," The uptime is measured on a monthly basis and does not include the public internet network availability. If the service does not achieve the above specified uptime in a month the User has the choice to get the money back for the month in question and the remaining months or the Provider will add a free month to the peri
49od of the services. "),a()(),l(126,"section",2)(127,"h2"),s(128,"Authentication and Authorization"),a(),l(129,"p"),s(130," Webservice requests are authenticated and authorized with a username passed as parameter with each request. Optional authentication measures are a token parameter serving as web service 'password' or a range of allowed IP addresses. "),a(),l(131,"p"),s(132," For users who are directly accessing the premium web services from javascript, additional restriction options are available. With the specification of an allowed referrer the service will refuse being accessed from other web sites and it is also possible to limit the number of credits used per IP address. "),a()(),l(133,"section",2)(134,"h2"),s(135,"Monitoring"),a(),l(136,"p"),s(137," Users of the premium web services can monitor the usage of credits on their GeoNames account page. A chart on the account page shows the daily usage of credits. "),a()(),l(138,"section",2)(139,"h2"),s(140,"Account"),a(),l(141,"p"),s(142," The premium web services are associated to a normal GeoNames user account. After signing up with PayPal your account will be setup and you will receive an email with the necessary information. This usually takes a couple of hours. "),a(),l(143,"div",13)(144,"strong"),s(145,"Note"),a(),s(146," Please check your spam folder for the account details if you don't get the email within a couple of minutes. "),a()()),t&2&&(d(84),T(i.bestAvailabilityPlans),d(22),T(i.bestPricePlans))},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem}a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%]{font-size:.9rem;margin:1rem 0 .3rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:.4rem 0;padding-left:1.2rem;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.2rem 0}.note[_ngcontent-%COMP%]{color:#777;font-size:.82rem}.notice[_ngcontent-%COMP%]{background:#fff8e1;border:1px solid #f2d675;border-radius:8px;padding:.75rem 1rem;font-size:.85rem;margin:.75rem 0}.notice[_ngcontent-%COMP%]   strong[_ngcontent-%COMP%]{display:block;margin:0 0 .25rem;font-size:.8rem;text-transform:uppercase;letter-spacing:.03em;color:#8a6d00}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto}.param-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem;margin:.5rem 0 1rem}.param-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .param-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.4rem .7rem;border-bottom:1px solid #eee;text-align:left;white-space:nowrap}.param-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555}.param-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.param-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.buy-btn[_ngcontent-%COMP%]{display:inline-block;appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff!important;border-radius:4px;padding:.3rem .7rem;font-size:.82rem;text-decoration:none!important;white-space:nowrap}.buy-btn[_ngcontent-%COMP%]:hover{background:#164d92}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var Od=class e{route=h(ve);title=h(H);latitude=Number(this.route.snapshot.paramMap.get("lat"));longitude=Number(this.route.snapshot.paramMap.get("lng"));constructor(){this.title.setTitle(`Map \u2014 ${this.latitude}, ${this.longitude} \u2014 GeoNames UI`)}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-browse-map-page"]],decls:6,vars:10,consts:[[1,"page-header"],[1,"page-intro"],["label","Selected location",3,"latitude","longitude","zoom","showCenterMarker","allowCreate","allowMove","autoFetchNearby","tall"]],template:function(t,i){t&1&&(l(0,"header",0)(1,"h1"),s(2,"Map"),a(),l(3,"p",1),s(4),a()(),j(5,"app-geo-map",2)),t&2&&(d(4),le("",i.latitude,", ",i.longitude,""),d(),v("latitude",i.latitude)("longitude",i.longitude)("zoom",12)("showCenterMarker",!0)("allowCreate",!1)("allowMove",!1)("autoFetchNearby",!0)("tall",!0))},dependencies:[nt],styles:[".page-header[_ngcontent-%COMP%]{margin:0 0 1rem}.page-header[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.page-intro[_ngcontent-%COMP%]{margin:0;color:#666;font-size:.92rem}"]})};function m1(e,n){if(e.length!==2||e[0].path!=="maps")return null;let t=e[1].path.match(/^browse_(-?\d+(?:\.\d+)?)_(-?\d+(?:\.\d+)?)\.html$/);return t?{consumed:e,posParams:{lat:new _t(t[1],{}),lng:new _t(t[2],{})}}:null}function p1(e,n){if(e.length!==2||!/^[A-Za-z]{2}$/.test(e[0].path))return null;
49let t=e[1].path.match(/^administrative-division-(.+)\.html$/);return t?{consumed:e,posParams:{cc:new _t(e[0].path,{}),slug:new _t(t[1],{})}}:null}function Nd(e){let n=new RegExp(`^${e}(.+)\\.html$`);return(t,i)=>{if(t.length!==2||!/^[A-Za-z]{2}$/.test(t[0].path))return null;let o=t[1].path.match(n);return o?{consumed:t,posParams:{cc:new _t(t[0].path,{}),slug:new _t(o[1],{})}}:null}}var f1="geonames_ui_user",qe=class e{http=h(Z);platformId=h(Zt);currentUser=E(this.readUserCookie());login(n){return this.http.post("/api/user/login",n).pipe(N(t=>(It(t),{userName:t.userName??n.username,userLevel:t.userLevel,premiumWebservice:t.premiumWebservice})),xe(t=>this.currentUser.set(t)),St())}logout(){return this.http.post("/api/user/logout",{}).pipe(xe(()=>this.currentUser.set(null)))}clearStaleSession(){this.currentUser.set(null),un(this.platformId)&&(document.cookie=`${f1}=; Max-Age=0; path=/`)}readUserCookie(){if(!un(this.platformId))return null;let n=document.cookie.match(new RegExp(`(?:^|; )${f1}=([^;]*)`));if(!n)return null;try{let t=JSON.parse(decodeURIComponent(n[1]));return t?.userName?t:null}catch{return null}}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var d3=(e,n)=>n.locale;function u3(e,n){e&1&&(l(0,"p",0),s(1,"Loading\u2026"),a())}function m3(e,n){e&1&&(l(0,"p",1),s(1,"No subdivision type with this id."),a())}function p3(e,n){e&1&&(l(0,"p",1),s(1,"Could not load this subdivision type right now."),a())}function f3(e,n){if(e&1&&(l(0,"tr")(1,"td",8),s(2),a(),l(3,"th",5),s(4),a(),l(5,"td"),s(6),a()()),e&2){let t=n.$implicit,i=p(4);d(2),g(i.languageNames().get(t.locale)),d(2),A("",t.locale,":"),d(2),g(t.name)}}function h3(e,n){if(e&1&&(l(0,"p",6),s(1,"Defined for country "),l(2,"strong"),s(3),a(),s(4,"."),a()),e&2){let t=p(2);d(3),g(t.countryCode)}}function g3(e,n){if(e&1){let t=$();l(0,"button",9),M("click",function(){S(t);let o=p(4);return w(o.startEdit())}),s(1,"Edit"),a()}}function C3(e,n){if(e&1&&(l(0,"table",4)(1,"tbody")(2,"tr"),j(3,"td"),l(4,"th",5),s(5,"Name:"),a(),l(6,"td"),s(7),a()(),I(8,f3,7,3,"tr",null,d3),a()(),y(10,h3,5,1,"p",6)(11,g3,2,0,"button",7)),e&2){let t=p(),i=p(2);d(7),g(t.name),d(),T(t.names),d(2),_(t.countryCode?10:-1),d(),_(i.canEdit()?11:-1)}}function _3(e,n){if(e&1){let t=$();l(0,"div",14)(1,"input",20),F("ngModelChange",function(o){let r=S(t).$implicit;return L(r.locale,o)||(r.locale=o),w(o)}),a(),l(2,"input",21),F("ngModelChange",function(o){let r=S(t).$implicit;return L(r.name,o)||(r.name=o),w(o)}),a(),l(3,"button",22),M("click",function(){let o=S(t).$index,r=p(4);return w(r.removeRow(o))}),s(4,"\xD7"),a()()}if(e&2){let t=n.$implicit,i=n.$index;d(),v("name","locale"+i),R("ngModel",t.locale),_e("aria-label","Locale "+(i+1)),d(),v("name","name"+i),R("ngModel",t.name),_e("aria-label","Translation "+(i+1)),d(),_e("aria-label","Remove translation "+(i+1))}}function v3(e,n){if(e&1&&(l(0,"p",16),s(1),a()),e&2){let t=p(4);d(),g(t.saveError())}}function y3(e,n){if(e&1){let t=$();l(0,"form",10),M("submit",function(o){return S(t),p(3).save(),w(o.preventDefault())}),l(1,"label",11),s(2," Name "),l(3,"input",12),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.name,o)||(r.form.name=o),w(o)}),a()(),l(4,"div",13),s(5,"Translations"),a(),I(6,_3,5,7,"div",14,sa),l(8,"button",15),M("click",function(){S(t);let o=p(3);return w(o.addRow())}),s(9,"+ add translation"),a(),y(10,v3,2,1,"p",16),l(11,"div",17)(12,"button",18),s(13),a(),l(14,"button",19),M("click",function(){S(t);let o=p(3);return w(o.cancelEdit())}),s(15,"Cancel"),a()()()}if(e&2){let t=p(3);d(3),R("ngModel",t.form.name),d(3),T(t.form.rows),d(4),_(t.saveError()?10:-1),d(2),v("disabled",t.saving()),d(),g(t.saving()?"Saving\u2026":"Save"),d(),v("disabled",t.saving())}}function b3(e,n){if(e&1&&(l(0,"div",2),y(1,C3,12,3)(2,y3,16,5,"form",3),a()),e&2){let t=p(2);d(),_(t.editing()?2:1)}}function x3(e,n){if(e&1&&y(0,b3,3,1,"div",2),e&2){let t,i=p();_((t=i.type())?0:-1,t)}}var kd=class e{route=h(ve);
49http=h(Z);title=h(H);auth=h(qe);state=E("loading");type=E(null);canEdit=G(()=>Number(this.auth.currentUser()?.userLevel)>100);editing=E(!1);saving=E(!1);saveError=E(null);form={name:"",rows:[]};languageNames=G(()=>{let n=new Intl.DisplayNames(["en"],{type:"language",fallback:"code"}),t=new Map;for(let i of this.type()?.names??[])try{t.set(i.locale,n.of(i.locale)??i.locale)}catch{t.set(i.locale,i.locale)}return t});constructor(){this.route.paramMap.pipe(N(n=>n.get("id")??""),xe(()=>{this.state.set("loading"),this.editing.set(!1)}),be(n=>this.http.get(`/api/subdivision-types/${encodeURIComponent(n)}`))).subscribe({next:n=>this.show(n),error:n=>this.state.set(n?.status===404?"not-found":"error")})}startEdit(){let n=this.type();n&&(this.form={name:n.name,rows:n.names.map(t=>U({},t))},this.saveError.set(null),this.editing.set(!0))}cancelEdit(){this.editing.set(!1),this.saveError.set(null)}addRow(){this.form.rows.push({locale:"",name:""})}removeRow(n){this.form.rows.splice(n,1)}save(){let n=this.type();n&&(this.saving.set(!0),this.saveError.set(null),this.http.put(`/api/subdivision-types/${n.typeId}`,{name:this.form.name,names:this.form.rows}).subscribe({next:t=>{this.saving.set(!1),this.editing.set(!1),this.show(t)},error:t=>{this.saving.set(!1),this.saveError.set(t?.status===401?"Sign in to edit this type.":t?.status===403?"Only GeoNames team members can edit subdivision types.":t?.status===400?"Check the values: a name is required, every translation needs a locale and a name, and each locale can appear only once.":"Could not save this type right now.")}}))}show(n){this.type.set(n),this.title.setTitle(`Country Subdivision Type ${n.name} \u2014 GeoNames UI`),this.state.set("loaded")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-subdivision-type-page"]],decls:6,vars:1,consts:[[1,"placeholder"],[1,"placeholder","error"],[1,"type-card"],[1,"edit-form"],[1,"type-table"],["scope","row"],[1,"meta"],["type","button",1,"btn-primary"],[1,"lang"],["type","button",1,"btn-primary",3,"click"],[1,"edit-form",3,"submit"],[1,"main-name"],["type","text","name","mainname","maxlength","100","required","",3,"ngModelChange","ngModel"],[1,"rows-head"],[1,"row"],["type","button",1,"link-btn",3,"click"],[1,"form-error"],[1,"actions"],["type","submit",1,"btn-primary",3,"disabled"],["type","button",3,"click","disabled"],["type","text","maxlength","10","placeholder","locale, e.g. de",1,"locale",3,"ngModelChange","name","ngModel"],["type","text","maxlength","100","placeholder","name",1,"translation",3,"ngModelChange","name","ngModel"],["type","button",1,"remove",3,"click"]],template:function(t,i){if(t&1&&(l(0,"h1"),s(1,"Country Subdivision Type"),a(),y(2,u3,2,0,"p",0)(3,m3,2,0,"p",1)(4,p3,2,0,"p",1)(5,x3,1,1)),t&2){let o;d(2),_((o=i.state())==="loading"?2:o==="not-found"?3:o==="error"?4:o==="loaded"?5:-1)}},dependencies:[ke,pt,Me,Ne,mt,Co,fi,De,dt],styles:["[_nghost-%COMP%]{display:block;max-width:700px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.6rem}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.type-card[_ngcontent-%COMP%]{background:#f8f9fa;border-radius:8px;padding:1rem}.type-table[_ngcontent-%COMP%]{border-collapse:collapse;font-size:.95rem}.type-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%], .type-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{padding:.3rem .8rem .3rem 0;text-align:left;vertical-align:top}.type-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{font-weight:400;color:#777}.type-table[_ngcontent-%COMP%]   .lang[_ngcontent-%COMP%]{color:#555}.meta[_ngcontent-%COMP%]{margin:.75rem 0 0;font-size:.8rem;color:#777}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}.btn-primary[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer;margin-top:.75rem}.btn-primary[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.edit-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.6rem}.edit-form[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.3rem .5rem;font-size:.9rem}
49.main-name[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.2rem;font-size:.75rem;color:#666}.rows-head[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;color:#777}.row[_ngcontent-%COMP%]{display:flex;gap:.4rem;align-items:center}.row[_ngcontent-%COMP%]   .locale[_ngcontent-%COMP%]{width:7rem}.row[_ngcontent-%COMP%]   .translation[_ngcontent-%COMP%]{flex:1;min-width:0}.remove[_ngcontent-%COMP%]{appearance:none;border:none;background:none;color:#999;font-size:1.1rem;cursor:pointer}.remove[_ngcontent-%COMP%]:hover{color:#b3261e}.link-btn[_ngcontent-%COMP%]{appearance:none;border:none;background:none;color:#1a5fb4;font-size:.85rem;cursor:pointer;padding:0;text-align:left;align-self:flex-start}.form-error[_ngcontent-%COMP%]{color:#b3261e;font-size:.8rem;margin:0}.actions[_ngcontent-%COMP%]{display:flex;gap:.4rem}.actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:not(.btn-primary){appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer;margin-top:.75rem}"]})};var Ad=class e{http=h(Z);getByCountry(n){return this.http.get(`/api/administrative-divisions?country=${encodeURIComponent(n)}`)}create(n){return this.http.post("/api/administrative-divisions",n)}update(n,t){return this.http.put(`/api/administrative-divisions/${n}`,t)}delete(n){return this.http.delete(`/api/administrative-divisions/${n}`)}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};function S3(e,n){e&1&&(l(0,"span",1),s(1,"Country details"),a())}function w3(e,n){if(e&1&&(l(0,"a",2),s(1,"Country details"),a()),e&2){let t=p();v("routerLink",t.countryPath())}}function E3(e,n){e&1&&(l(0,"span",1),s(1,"Administrative Division"),a())}function M3(e,n){if(e&1&&(l(0,"a",2),s(1,"Administrative Division"),a()),e&2){let t=p();v("routerLink",t.adminDivisionPath())}}function P3(e,n){e&1&&(l(0,"span",1),s(1,"Feature Statistic"),a())}function D3(e,n){if(e&1&&(l(0,"a",2),s(1,"Feature Statistic"),a()),e&2){let t=p();v("routerLink",t.statisticsPath())}}function I3(e,n){e&1&&(l(0,"span",1),s(1,"Largest Cities"),a())}function T3(e,n){if(e&1&&(l(0,"a",2),s(1,"Largest Cities"),a()),e&2){let t=p();v("routerLink",t.largestCitiesPath())}}function O3(e,n){e&1&&(l(0,"span",1),s(1,"Highest Mountains"),a())}function N3(e,n){if(e&1&&(l(0,"a",2),s(1,"Highest Mountains"),a()),e&2){let t=p();v("routerLink",t.highestMountainsPath())}}function k3(e,n){e&1&&(l(0,"span",1),s(1,"Other Country Names"),a())}function A3(e,n){if(e&1&&(l(0,"a",2),s(1,"Other Country Names"),a()),e&2){let t=p();v("routerLink",t.otherNamesPath())}}var Jn=class e{country;active=null;countryPath(){return`/countries/${this.country.isoCode}/${We(this.country.countryName)}.html`}adminDivisionPath(){return`/${this.country.isoCode}/administrative-division-${We(this.country.countryName)}.html`}statisticsPath(){return`/statistics/${We(this.country.countryName)}.html`}largestCitiesPath(){return`/${this.country.isoCode}/largest-cities-in-${We(this.country.countryName)}.html`}highestMountainsPath(){return`/${this.country.isoCode}/highest-mountains-in-${We(this.country.countryName)}.html`}otherNamesPath(){return`/${this.country.isoCode}/other-names-for-${We(this.country.countryName)}.html`}postalCodesUrl(){return`https://www.geonames.org/postal-codes/postal-codes-${We(this.country.countryName)}.html`}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-country-sub-nav"]],inputs:{country:"country",active:"active"},decls:15,vars:8,consts:[[1,"sub-nav"],[1,"active"],[3,"routerLink"],["target","_blank","rel","noopener noreferrer",1,"ext-link",3,"href"]],template:function(t,i){t&1&&(l(0,"nav",0),y(1,S3,2,0,"span",1)(2,w3,2,1,"a",2)(3,E3,2,0,"span",1)(4,M3,2,1,"a",2)(5,P3,2,0,"span",1)(6,D3,2,1,"a",2)(7,I3,2,0,"span",1)(8,T3,2,1,"a",2)(9,O3,2,0,"span",1)(10,N3,2,1,"a",2)(11,k3,2,0,"span",1)(12,A3,2,1,"a",2),l(13,"a",3),s(14,"Postal codes"),a()()),t&2&&(_e("aria-label","More about "+i.country.countryName),d(),_(i.active==="details"?1:2),d(2),_(i.active==="admin-division"?3:4),d(2),_(i.active==="feature-statistic"?5:6),d(2),_(i.active==="largest-cities"?7:8),d(2),_(i.active==="highe
49st-mountains"?9:10),d(2),_(i.active==="other-names"?11:12),d(2),v("href",i.postalCodesUrl(),Y))},dependencies:[W],styles:['.sub-nav[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:.5rem;margin-top:1.5rem;padding-top:1rem;border-top:1px solid #f0f0f0}.sub-nav[_ngcontent-%COMP%]   a[_ngcontent-%COMP%], .sub-nav[_ngcontent-%COMP%]   .active[_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.35rem .7rem;font-size:.85rem;text-decoration:none}.sub-nav[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#333}.sub-nav[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{border-color:#1a5fb4;color:#1a5fb4}.sub-nav[_ngcontent-%COMP%]   .active[_ngcontent-%COMP%]{border-color:#1a5fb4;background:#1a5fb4;color:#fff;font-weight:600}.ext-link[_ngcontent-%COMP%]:after{content:"\\2197";margin-left:.15rem;font-size:.75rem}']})};var R3=e=>({$implicit:e});function F3(e,n){e&1&&(l(0,"p",1),s(1,"Loading administrative divisions\u2026"),a())}function L3(e,n){e&1&&(l(0,"p",2),s(1,"No country found with this code."),a())}function V3(e,n){e&1&&(l(0,"p",2),s(1,"Could not load the administrative divisions right now."),a())}function U3(e,n){if(e&1&&(l(0,"p",1),s(1),a()),e&2){let t=p();d(),A("No administrative divisions are recorded for ",t.countryName,".")}}function j3(e,n){if(e&1&&Ii(0,9),e&2){let t=n.$implicit;p(3);let i=so(5);v("ngTemplateOutlet",i)("ngTemplateOutletContext",Av(2,R3,t))}}function B3(e,n){if(e&1){let t=$();l(0,"button",15),M("click",function(){S(t);let o=p(4);return w(o.startCreate())}),s(1," insert new subdivision "),a()}if(e&2){let t=p(4);v("disabled",t.editingId()!==null)}}function H3(e,n){if(e&1&&(l(0,"option",25),s(1),a()),e&2){let t=n.$implicit;v("value",t),d(),g(t)}}function $3(e,n){if(e&1&&(l(0,"p",10),s(1),a()),e&2){let t=p(5);d(),g(t.actionError())}}function z3(e,n){if(e&1){let t=$();l(0,"form",16),M("submit",function(o){return S(t),p(4).saveCreate(),w(o.preventDefault())}),l(1,"label"),s(2,"ISO-3166-2 "),l(3,"input",17),F("ngModelChange",function(o){S(t);let r=p(4);return L(r.createForm.iso3166_2,o)||(r.createForm.iso3166_2=o),w(o)}),a()(),l(4,"label"),s(5,"Fips "),l(6,"input",18),F("ngModelChange",function(o){S(t);let r=p(4);return L(r.createForm.fips,o)||(r.createForm.fips=o),w(o)}),a()(),l(7,"label",19),s(8,"Name "),l(9,"input",20),F("ngModelChange",function(o){S(t);let r=p(4);return L(r.createForm.name,o)||(r.createForm.name=o),w(o)}),a()(),l(10,"label"),s(11,"Capital "),l(12,"input",21),F("ngModelChange",function(o){S(t);let r=p(4);return L(r.createForm.capital,o)||(r.createForm.capital=o),w(o)}),a()(),l(13,"label"),s(14,"lang "),l(15,"input",22),F("ngModelChange",function(o){S(t);let r=p(4);return L(r.createForm.languages,o)||(r.createForm.languages=o),w(o)}),a()(),l(16,"label"),s(17," continent "),l(18,"select",23),F("ngModelChange",function(o){S(t);let r=p(4);return L(r.createForm.continentCode,o)||(r.createForm.continentCode=o),w(o)}),l(19,"option",24),s(20,"\u2014"),a(),I(21,H3,2,2,"option",25,Re),a()(),l(23,"label"),s(24,"From "),l(25,"input",26),F("ngModelChange",function(o){S(t);let r=p(4);return L(r.createForm.validFrom,o)||(r.createForm.validFrom=o),w(o)}),a()(),l(26,"label"),s(27,"Till "),l(28,"input",27),F("ngModelChange",function(o){S(t);let r=p(4);return L(r.createForm.validTill,o)||(r.createForm.validTill=o),w(o)}),a()(),l(29,"div",28)(30,"button",29),s(31),a(),l(32,"button",30),M("click",function(){S(t);let o=p(4);return w(o.cancelCreate())}),s(33,"Cancel"),a()(),l(34,"p",31),s(35,"New subdivisions start at level 1 - edit the row afterwards to change the level."),a(),y(36,$3,2,1,"p",10),a()}if(e&2){let t=p(4);d(3),R("ngModel",t.createForm.iso3166_2),d(3),R("ngModel",t.createForm.fips),d(3),R("ngModel",t.createForm.name),d(3),R("ngModel",t.createForm.capital),d(3),R("ngModel",t.createForm.languages),d(3),R("ngModel",t.createForm.continentCode),d(3),T(t.continents),d(4),R("ngModel",t.createForm.validFrom),d(3),R("ngModel",t.createForm.validTill),d(2),v("disabled",t.busy()),d(),g(t.busy()?"Saving\u2026":"Insert"),d(),v("disabled",t.busy()),d(4),_(t.actionError()?36:-1)}}function G3(e,n){if(e&1&&y(0,B3,2,1,"button",13)(1,z3,37,12,"form",14),e&2){let t=p(3);_(t.creating()?1:0)}}function W3(e,n){if(e&1&&(l(0,"p",10),s(1),a()),e&2){let t=p(3);d(),g(t.actionError())}}function q3(e,n){if(e&1&&(l(0,"nav",3)(1,"a",4),s(2,"Home"),a(),l(3,"span",5),s(4,"\u203A"),a(),l(5,"a",6),s(6,"Countries"),a(),l(7,"span",5),s(8,"\u203A"),a(),l(9,"a",7),s(10),a(),l(11,"span",5),s(12,"\u203A"),a(),l(13,"span",8),s(14,"Administrative Division"),a()(),l(15,"h1"),s(16),a(),y(17,U3,2,1,"p",1),I(18,j3,1,4,"ng-container",9,sa),y(20,G3,2,1)(21,W3,2,1,"p",10),j(22,"img",11)(23,"app-country-sub-nav",12)),e&2){let t=n,i=p(2);d(9),v("routerLink",i.countryPath(t)),d(),g(t.countryName),d(6),A("ISO Subentity Codes for ",t.countryName,""),d(),_(i.tables().length?-1:17),d(),T(i.tables()),d(2),_(i.canEdit()?20:-1),d(),_(i.actionError()&&i.editingId()===null&&!i.creating()?21:-1),d(),v("src",i.mapUrl(t),Y)("alt",t.countryName+" borders"),d(),v("country",t)}}function J3(e,n){if(e&1&&y(0,q3,24,9),e&2){let t,i=p();_((t=i.country())?0:-1,t)}}function K3(e,n){if(e&1&&(l(0,"h2"),s(1),a()),e&2){let t=p().$implicit;d(),g(t.title)}}function Y3(e,n){e&1&&(l(0,"th"),s(1,"ISO Region"),a())}function Z3(e,n){e&1&&j(0,"th")}function Q3(e,n){if(e&1&&(l(0,"td"),s(1),a()),e&2){let t=p().$implicit;d(),g(t.isoRegionCode)}}function X3(e,n){if(e&1&&(l(0,"a",7),s(1),a()),e&2){let t=p().$implicit,i=p(2);v("routerLink",i.placePath(t.subdivisionId,t.name)),d(),g(t.name)}}function eF(e,n){if(e&1&&s(0),e&2){let t=p().$implicit;A(" ",t.name," ")}}function tF(e,n){if(e&1&&(l(0,"a",35),j(1,"img",38),a()),e&2){let t=p().$implicit;v("href",t.wikipediaUrl,Y)}}function nF(e,n){if(e&1&&(l(0,"a",7),s(1),a()),e&2){let t=p().$implicit;v("routerLink","/subdivision-types/"+t.typeId),d(),g(t.typeLabel)}}function iF(e,n){if(e&1&&s(0),e&2){let t=p().$implicit;A(" ",t.typeLabel," ")}}function oF(e,n){if(e&1&&(l(0,"a",7),s(1),a()),e&2){let t=p().$implicit,i=p(2);v("routerLink",i.placePath(t.capitalId,t.capital)),d(),g(t.capital)}}function rF(e,n){if(e&1&&s(0),e&2){let t=p().$implicit;A(" ",t.capital," ")}}function aF(e,n){if(e&1){let t=$();s(0," delete? "),l(1,"button",39),M("click",function(){S(t);let o=p(2).$implicit,r=p(2);return w(r.confirmDelete(o))}),s(2,"yes"),a(),s(3,", "),l(4,"button",40),M("click",function(){S(t);let o=p(4);return w(o.deletingId.set(null))}),s(5,"no"),a()}if(e&2){let t=p(4);d(),v("disabled",t.busy()),d(3),v("disabled",t.busy())}}function sF(e,n){if(e&1){let t=$();l(0,"button",40),M("click",function(){S(t);let o=p(2).$implicit,r=p(2);return w(r.startEdit(o))}),s(1,"edit"),a(),s(2,", "),l(3,"button",40),M("click",function(){S(t);let o=p(2).$implicit,r=p(2);return w(r.deletingId.set(o.id))}),s(4,"delete"),a()}if(e&2){let t=p(4);v("disabled",t.editingId()!==null),d(3),v("disabled",t.editingId()!==null)}}function lF(e,n){if(e&1&&(l(0,"td",36),y(1,aF,6,2)(2,sF,5,2),a()),e&2){let t=p().$implicit,i=p(2);d(),_(i.deletingId()===t.id?1:2)}}function cF(e,n){if(e&1&&(l(0,"option",25),s(1),a()),e&2){let t=n.$implicit;v("value",t),d(),g(t)}}function dF(e,n){if(e&1&&(l(0,"p",10),s(1),a()),e&2){let t=p(4);d(),g(t.actionError())}}function uF(e,n){if(e&1){let t=$();l(0,"tr",37)(1,"td")(2,"form",41),M("submit",function(o){return S(t),p(3).save(),w(o.preventDefault())}),l(3,"label"),s(4,"ISO-3166-2 "),l(5,"input",42),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.iso3166_2,o)||(r.form.iso3166_2=o),w(o)}),a()(),l(6,"label"),s(7,"Fips "),l(8,"input",43),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.fips,o)||(r.form.fips=o),w(o)}),a()(),l(9,"label",19),s(10,"Name "),l(11,"input",44),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.name,o)||(r.form.name=o),w(o)}),a()(),l(12,"label"),s(13,"Level "),l(14,"input",45),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.admLevel,o)||(r.form.admLevel=o),w(o)}),a()(),l(15,"label"),s(16,"lang "),l(17,"input",46),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.languages,o)||(r.form.languages=o),w(o)}),a()(),l(18,"label"),s(19," continent "),l(20,"select",47),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.continentCode,o)||(r.form.continentCode=o),w(o)}),l(21,"option",24),s(22,"\u2014"),a(),I(23,cF,2,2,"option",25,Re),a()(),l(25,"label"),s(26,"From "),l(27,"input",48),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.validFrom,o)||(r.form.validFrom=o),w(o)}),a()(),l(28,"label"),s(29,"Till "),l(30,"input",49),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.validTill,o)||(r.form.validTill=o),w(o)}),a()(),l(31,"div",28)(32,"button",29),s(33),a(),l(34,"button",30),M("click",function(){S(t);let o=p(3);return w(o.cancelEdit())}),s(35,"Cancel"),a()(),y(36,dF,2,1,"p",10),a()()()}if(e&2){let t=p(2).$implicit,i=p();d(),_e("colspan",t.showParent?14:13),d(4),R("ngModel",i.form.iso3166_2),d(3),R("ngModel",i.form.fips),d(3),R("ngModel",i.form.name),d(3),R("ngModel",i.form.admLevel),d(3),R("ngModel",i.form.languages),d(3),R("ngModel",i.form.continentCode),d(3),T(i.continents),d(4),R("ngModel",i.form.validFrom),d(3),R("ngModel",i.form.validTill),d(2),v("disabled",i.busy()),d(),g(i.busy()?"Saving\u2026":"Save"),d(),v("disabled",i.busy()),d(2),_(i.actionError()?36:-1)}}function mF(e,n){if(e&1&&(l(0,"tr")(1,"td",34),s(2),a(),l(3,"td"),s(4),a(),y(5,Q3,2,1,"td"),l(6,"td"),s(7),a(),l(8,"td"),s(9),a(),l(10,"td"),y(11,X3,2,2,"a",7)(12,eF,1,1)(13,tF,2,1,"a",35),a(),l(14,"td"),y(15,nF,2,2,"a",7)(16,iF,1,1),a(),l(17,"td"),y(18,oF,2,2,"a",7)(19,rF,1,1),a(),l(20,"td",34),s(21),a(),l(22,"td"),s(23),a(),l(24,"td"),s(25),a(),l(26,"td"),s(27),a(),l(28,"td"),s(29),a(),y(30,lF,3,1,"td",36),a(),y(31,uF,37,13,"tr",37)),e&2){let t=n.$implicit,i=n.$index,o=p().$implicit,r=p();d(2),g(o.start+i),d(2),g(t.iso3166_2),d(),_(o.showParent?5:-1),d(2),g(t.fips),d(),pe("mismatch",r.gnMismatch(t)),d(),g(t.geonamesAdmCode),d(2),_(t.subdivisionId?11:12),d(2),_(t.wikipediaUrl?13:-1),d(2),_(t.typeId&&t.typeLabel?15:16),d(3),_(t.capitalId&&t.capital?18:19),d(3),g(t.population!=null?t.population.toLocaleStr
49ing():""),d(2),g(t.languages),d(2),g(t.continentCode),d(2),g(r.formatDate(t.validFrom)),d(2),g(r.formatDate(t.validTill)),d(),_(r.canEdit()?30:-1),d(),_(r.editingId()===t.id?31:-1)}}function pF(e,n){if(e&1&&(y(0,K3,2,1,"h2"),l(1,"div",32)(2,"table",33)(3,"thead")(4,"tr")(5,"th",34),s(6,"#"),a(),l(7,"th"),s(8,"ISO-3166-2"),a(),y(9,Y3,2,0,"th"),l(10,"th"),s(11,"Fips"),a(),l(12,"th"),s(13,"GN"),a(),l(14,"th"),s(15,"Name of Subdivision"),a(),l(16,"th"),s(17,"Type"),a(),l(18,"th"),s(19,"Capital"),a(),l(20,"th",34),s(21,"Population"),a(),l(22,"th"),s(23,"lang"),a(),l(24,"th"),s(25,"continent"),a(),l(26,"th"),s(27,"From"),a(),l(28,"th"),s(29,"Till"),a(),y(30,Z3,1,0,"th"),a()(),l(31,"tbody"),I(32,mF,32,18,null,null,sa),a()()()),e&2){let t=n.$implicit,i=p();_(t.title?0:-1),d(9),_(t.showParent?9:-1),d(21),_(i.canEdit()?30:-1),d(2),T(t.rows)}}var Rd=class e{route=h(ve);divisions=h(Ad);countryInfo=h(it);places=h(tt);title=h(H);auth=h(qe);state=E("loading");country=E(null);rows=E([]);code="";canEdit=G(()=>Number(this.auth.currentUser()?.userLevel)>100);continents=["AF","AN","AS","EU","NA","OC","SA"];editingId=E(null);deletingId=E(null);busy=E(!1);actionError=E(null);form=this.blankForm();creating=E(!1);createForm=this.blankCreateForm();tables=G(()=>{let n=new Date().toISOString().slice(0,10),t=this.rows(),i=[...new Set(t.map(r=>r.level))].sort((r,c)=>r-c),o=[];for(let r of i){let c=t.filter(f=>f.level===r),u=c.filter(f=>!f.validTill||f.validTill>=n),m=c.filter(f=>!!f.validTill&&f.validTill<n);u.length&&o.push({title:null,showParent:r>1,start:1,rows:u}),m.length&&o.push({title:"no longer exists:",showParent:r>1,start:u.length+1,rows:m})}return o});constructor(){this.route.paramMap.pipe(N(n=>(n.get("cc")??"").toUpperCase()),xe(n=>
49{this.code=n,this.state.set("loading"),this.editingId.set(null),this.deletingId.set(null),this.creating.set(!1),this.actionError.set(null)}),be(n=>Ci([this.countryInfo.getCountries(),this.divisions.getByCountry(n)]).pipe(N(([t,i])=>({cc:n,countries:t,rows:i}))))).subscribe({next:({cc:n,countries:t,rows:i})=>{let o=t.find(r=>r.isoCode===n)??null;if(!o){this.state.set("not-found");return}this.country.set(o),this.rows.set(i),this.title.setTitle(`Administrative Division of ${o.countryName} \u2014 GeoNames UI`),this.state.set("loaded")},error:()=>this.state.set("error")})}startEdit(n){this.form={iso3166_2:n.iso3166_2??"",fips:n.fips??"",name:n.name,admLevel:n.level,validFrom:n.validFrom??"",validTill:n.validTill??"",languages:n.languages??"",continentCode:n.continentCode??""},this.actionError.set(null),this.deletingId.set(null),this.editingId.set(n.id)}startCreate(){this.createForm=this.blankCreateForm(),this.actionError.set(null),this.editingId.set(null),this.deletingId.set(null),this.creating.set(!0)}cancelCreate(){this.creating.set(!1),this.actionError.set(null)}saveCreate(){this.busy.set(!0),this.actionError.set(null),this.divisions.create(oe(U({},this.createForm),{countryCode:this.code})).subscribe({next:()=>{this.busy.set(!1),this.creating.set(!1),this.reload()},error:n=>this.fail(n)})}cancelEdit(){this.editingId.set(null),this.actionError.set(null)}save(){let n=this.editingId();n!==null&&(this.busy.set(!0),this.actionError.set(null),this.divisions.update(n,this.form).subscribe({next:()=>{this.busy.set(!1),this.editingId.set(null),this.reload()},error:t=>this.fail(t)}))}confirmDelete(n){this.busy.set(!0),this.actionError.set(null),this.divisions.delete(n.id).subscribe({next:()=>{this.busy.set(!1),this.deletingId.set(null),this.reload()},error:t=>{this.deletingId.set(null),this.fail(t)}})}reload(){this.divisions.getByCountry(this.code).subscribe(n=>this.rows.set(n))}fail(n){this.busy.set(!1),this.actionError.set(n?.status===401?"Sign in to edit administrative divisions.":n?.status===403?"Only GeoNames team members can edit administrative divisions.":n?.status===409?"Another subdivision of this country already uses that FIPS or GN code.":n?.status===400?"Check the values: a name is required, the level is 0-9, dates are yyyy-MM-dd, fips is at most 3 characters, and the continent must be a valid code.":n?.status===404?"This subdivision no longer exists - reload the page.":"Could not save right now.")}blankCreateForm(){return{countryCode:"",iso3166_2:"",fips:"",name:"",capital:"",validFrom:"",validTill:"",languages:"",continentCode:""}}blankForm(){return{iso3166_2:"",fips:"",name:"",admLevel:1,validFrom:"",validTill:"",languages:"",continentCode:""}}countryPath(n){return`/countries/${n.isoCode}/${We(n.countryName)}.html`}placePath(n,t){return this.places.path({id:String(n),name:t})}gnMismatch(n){return!!n.fips&&n.fips!==n.geonamesAdmCode}mapUrl(n){return`https://img.geonames.org/img/country/400/${n.isoCode}.png`}formatDate(n){return n?n.replace(/-/g,"."):""}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-administrative-division-page"]],decls:6,vars:1,consts:[["tableTpl",""],[1,"placeholder"],[1,"placeholder","error"],["aria-label","Breadcrumb",1,"breadcrumb"],["routerLink","/"],[1,"sep"],["routerLink","/countries"],[3,"routerLink"],[1,"current"],[3,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"form-error"],["loading","lazy",1,"country-map",3,"src","alt"],["active","admin-division",3,"country"],["type","button",1,"link-btn","insert-link",3,"disabled"],[1,"edit-form","create-form"],["type","button",1,"link-btn","insert-link",3,"click","disabled"],[1,"edit-form","create-form",3,"submit"],["type","text","name","c-iso","maxlength","10","size","8",3,"ngModelChange","ngModel"],["type","text","name","c-fips","maxlength","3","size","4",3,"ngModelChange","ngModel"],[1,"grow"],["type","text","name","c-name","maxlength","100","required","",3,"ngModelChange","ngModel"],["type","text","name","c-capital","maxlength","100","size","14",3,"ngModelChange","ngModel"],["type","text","name","c-lang","maxlength","100","size","10",3,"ngModelChange","ngModel"],["name","c-continent",3,"ngModelChange","ngModel"],["value",""],[3,"value"],["type","text","name","c-from","placeholder","yyyy-MM-dd","size","10",3,"ngModelChange","ngModel"],["type","text","name","c-till","placeholder","yyyy-MM-dd","size","10",3,"ngModelChange","ngModel"],[1,"edit-actions"],["type","submit",1,"btn-primary",3,"disabled"],["type","button",3,"click","disabled"],[1,"hint"],[1,"table-scroll"],[1,"division-table"],[1,"num"],["target","_blank","rel","noopener noreferrer","title","Wikipedia article",1,"wikipedia-badge",3,"href"],[1,"actions"],[1,"edit-row"],["src","https://www.geonames.org/img/20px-Wikipedia-logo.png","alt","","width","14","height","14"],["type","button",1,"link-btn","danger",3,"click","disabled"],["type","button",1,"link-btn",3,"click","disabled"],[1,"edit-form",3,"submit"],["type","text","name","iso","maxlength","10","size","8",3,"ngModelChange","ngModel"],["type","text","name","fips","maxlength","3","size","4",3,"ngModelChange","ngModel"],["type","text","name","name","maxlength","100","required","",3,"ngModelChange","ngModel"],["type","number","name","level","min","0","max","9",3,"ngModelChange","ngModel"],["type","text","name","languages","maxlength","100","size","10",3,"ngModelChange","ngModel"],["name","continent",3,"ngModelChange","ngModel"],["type","text","name","from","placeholder","yyyy-MM-dd","size","10",3,"ngModelChange","ngModel"],["type","text","name","till","placeholder","yyyy-MM-dd","size","10",3,"ngModelChange","ngModel"]],template:function(t,i){if(t&1&&y(0,F3,2,0,"p",1)(1,L3,2,0,"p",2)(2,V3,2,0,"p",2)(3,J3,1,1)(4,pF,34,3,"ng-template",null,0,Zo),t&2){let o;_((o=i.state())==="loading"?0:o==="not-found"?1:o==="error"?2:o==="loaded"?3:-1)}},dependencies:[W,co,ke,pt,zn,Gn,Me,jh,mn,Ne,mt,Co,fi,Hh,Bh,De,dt,Jn],styles:["[_nghost-%COMP%]{display:block;max-width:1100px;margin:0 auto;padding:1rem}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.breadcrumb[_ngcontent-%COMP%]{font-size:.85rem;color:#555;margin-bottom:1rem;overflow-wrap:break-word}
49.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.breadcrumb[_ngcontent-%COMP%]   .sep[_ngcontent-%COMP%]{margin:0 .35rem;color:#999}.breadcrumb[_ngcontent-%COMP%]   .current[_ngcontent-%COMP%]{color:#222;font-weight:600}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.6rem}h2[_ngcontent-%COMP%]{margin:1.75rem 0 .5rem;font-size:1.05rem;color:#555}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto;margin-bottom:1rem}.division-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.division-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .division-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .6rem;border-bottom:1px solid #eee;text-align:left;white-space:nowrap}.division-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555}.division-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n):not(.edit-row){background:#fafbfc}.division-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover:not(.edit-row){background:#eef2f7}.division-table[_ngcontent-%COMP%]   .num[_ngcontent-%COMP%]{text-align:right;font-variant-numeric:tabular-nums}.division-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.division-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.mismatch[_ngcontent-%COMP%]{color:#b3261e}.country-map[_ngcontent-%COMP%]{display:block;max-width:100%;height:auto;margin-top:1rem}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}.actions[_ngcontent-%COMP%]{font-size:.8rem}.link-btn[_ngcontent-%COMP%]{appearance:none;border:none;background:none;color:#1a5fb4;font-size:inherit;cursor:pointer;padding:0}.link-btn[_ngcontent-%COMP%]:hover{text-decoration:underline}.link-btn.danger[_ngcontent-%COMP%]{color:#b3261e}.link-btn[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.edit-row[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{background:#f8f9fa;white-space:normal}.edit-form[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:flex-end;gap:.6rem .9rem;padding:.5rem 0}.edit-form[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.2rem;font-size:.72rem;color:#666}.edit-form[_ngcontent-%COMP%]   label.grow[_ngcontent-%COMP%]{flex:1;min-width:12rem}.edit-form[_ngcontent-%COMP%]   input[_ngcontent-%COMP%], .edit-form[_ngcontent-%COMP%]   select[_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.3rem .4rem;font-size:.85rem}.edit-actions[_ngcontent-%COMP%]{display:flex;gap:.4rem}.edit-actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.edit-actions[_ngcontent-%COMP%]   .btn-primary[_ngcontent-%COMP%]{border-color:#1a5fb4;background:#1a5fb4;color:#fff}.form-error[_ngcontent-%COMP%]{flex-basis:100%;margin:.3rem 0 0;color:#b3261e;font-size:.8rem}.insert-link[_ngcontent-%COMP%]{margin-top:.5rem;font-size:.85rem}.create-form[_ngcontent-%COMP%]{margin-top:.75rem;padding:.75rem;background:#f8f9fa;border-radius:8px}.hint[_ngcontent-%COMP%]{flex-basis:100%;margin:0;font-size:.75rem;color:#777}.wikipedia-badge[_ngcontent-%COMP%]{display:inline-flex;align-items:center;margin-left:.3rem;opacity:.75}.wikipedia-badge[_ngcontent-%COMP%]:hover{opacity:1}.wikipedia-badge[_ngcontent-%COMP%]   img[_ngcontent-%COMP%]{display:block}"]})};var Fd=class e{http=h(Z);getLargestCities(n){return this.http.get(`/api/largest-cities?country=${encodeURIComponent(n)}`)}getHighestMountains(n){return this.http.get(`/api/highest-mountains?country=${encodeURIComponent(n)}`)}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var fF=(e,n)=>n.geonameId;function hF(e,n){e&1&&(l(0,"p",0),s(1,"Loading\u2026"),a())}function gF(e,n){e&1&&(l(0,"p",1),s(1,"No country found with this code."),a())}function CF(e,n){e&1&&(l(0,"p",1),s(1,"Could not load this list right now."),a())}function _F(e,n){if(e&1&&(l(0,"p",0),s(1),a()),e&2){let t=p(),i=p(2);d(),le("No ",i.isCities()?"populated places":"mountains"," are recorded for ",t.countryName,".")}}function vF(e,n){if(e&1&&(l(0,"a",12),j(1,"img",13),a()),e&2){let t=p().$implicit;v("href",t.wikipediaUrl,Y)}}
49function yF(e,n){if(e&1&&(l(0,"tr")(1,"td",11),s(2),a(),l(3,"td")(4,"a",6),s(5),a(),y(6,vF,2,1,"a",12),s(7),a(),l(8,"td",11),s(9),a(),l(10,"td")(11,"a",6),s(12),a()()()),e&2){let t=n.$implicit,i=n.$index,o=p(4);d(2),g(i+1),d(2),v("routerLink",o.placePath(t)),d(),g(t.name),d(),_(t.wikipediaUrl?6:-1),d(),A(" , ",t.adminName1," "),d(2),g(o.isCities()?t.value.toLocaleString():t.value+" m"),d(2),v("routerLink",o.browsePath(t)),d(),le("",t.latitude.toFixed(3)," / ",t.longitude.toFixed(3),"")}}function bF(e,n){if(e&1&&(l(0,"div",8)(1,"table",10)(2,"thead")(3,"tr")(4,"th",11),s(5,"#"),a(),l(6,"th"),s(7,"Name"),a(),l(8,"th",11),s(9),a(),l(10,"th"),s(11,"Latitude/Longitude"),a()()(),l(12,"tbody"),I(13,yF,13,9,"tr",null,fF),a()()()),e&2){let t=p(3);d(9),g(t.isCities()?"Population":"Elevation"),d(4),T(t.rows())}}function xF(e,n){if(e&1&&(l(0,"nav",2)(1,"a",3),s(2,"Home"),a(),l(3,"span",4),s(4,"\u203A"),a(),l(5,"a",5),s(6,"Countries"),a(),l(7,"span",4),s(8,"\u203A"),a(),l(9,"a",6),s(10),a(),l(11,"span",4),s(12,"\u203A"),a(),l(13,"span",7),s(14),a()(),l(15,"h1"),s(16),a(),y(17,_F,2,2,"p",0)(18,bF,15,1,"div",8),j(19,"app-country-sub-nav",9)),e&2){let t=n,i=p(2);d(9),v("routerLink",i.countryPath(t)),d(),g(t.countryName),d(4),g(i.isCities()?"Largest Cities":"Highest Mountains"),d(2),g(i.pageTitle()),d(),_(i.rows().length?18:17),d(2),v("country",t)("active",i.isCities()?"largest-cities":"highest-mountains")}}function SF(e,n){if(e&1&&y(0,xF,20,7),e&2){let t,i=p();_((t=i.country())?0:-1,t)}}var Ya=class e{route=h(ve);places=h(Fd);countryInfo=h(it);placesService=h(tt);title=h(H);state=E("loading");country=E(null);kind=E("cities");rows=E([]);isCities=G(()=>this.kind()==="cities");pageTitle=G(()=>{let n=this.country()?.countryName??"";return this.isCities()?`${n} - 10 Largest Cities`:`${n} - Highest Mountains`});constructor(){this.route.data.pipe(N(n=>n.kind),be(n=>this.route.paramMap.pipe(N(t=>({kind:n,cc:(t.get("cc")??"").toUpperCase()})))),xe(()=>this.state.set("loading")),be(({kind:n,cc:t})=>Ci([this.countryInfo.getCountries(),n==="cities"?this.places.getLargestCities(t):this.places.getHighestMountains(t)]).pipe(N(([i,o])=>({kind:n,cc:t,countries:i,rows:o}))))).subscribe({next:({kind:n,cc:t,countries:i,rows:o})=>{this.kind.set(n);let r=i.find(c=>c.isoCode===t)??null;if(!r){this.state.set("not-found");return}this.country.set(r),this.rows.set(o),this.title.setTitle(`${this.pageTitle()} \u2014 GeoNames UI`),this.state.set("loaded")},error:()=>this.state.set("error")})}countryPath(n){return`/countries/${n.isoCode}/${We(n.countryName)}.html`}placePath(n){return this.placesService.path({id:String(n.geonameId),name:n.name})}browsePath(n){return Er(n.latitude,n.longitude)}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-country-places-page"]],decls:4,vars:1,consts:[[1,"placeholder"],[1,"placeholder","error"],["aria-label","Breadcrumb",1,"breadcrumb"],["routerLink","/"],[1,"sep"],["routerLink","/countries"],[3,"routerLink"],[1,"current"],[1,"table-scroll"],[3,"country","active"],[1,"places-table"],[1,"num"],["target","_blank","rel","noopener noreferrer","title","Wikipedia article",1,"wikipedia-badge",3,"href"],["src","https://www.geonames.org/img/20px-Wikipedia-logo.png","alt","","width","14","height","14"]],template:function(t,i){if(t&1&&y(0,hF,2,0,"p",0)(1,gF,2,0,"p",1)(2,CF,2,0,"p",1)(3,SF,1,1),t&2){let o;_((o=i.state())==="loading"?0:o==="not-found"?1:o==="error"?2:o==="loaded"?3:-1)}},dependencies:[W,Jn],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.breadcrumb[_ngcontent-%COMP%]{font-size:.85rem;color:#555;margin-bottom:1rem;overflow-wrap:break-word}.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.breadcrumb[_ngcontent-%COMP%]   .sep[_ngcontent-%COMP%]{margin:0 .35rem;color:#999}.breadcrumb[_ngcontent-%COMP%]   .current[_ngcontent-%COMP%]{color:#222;font-weight:600}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.6rem}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto;margin-bottom:1rem}.places-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.9rem}.places-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .places-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.4rem .7rem;border-bottom:1px solid #eee;text-align:left}.places-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555;font-size:.8rem;text-transform:uppercase;letter-spacing:.03em}.places-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.places-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.places-table[_ngcontent-%COMP%]   .num[_ngcontent-%COMP%]{text-align:right;font-variant-numeric:tabular-nums}.places-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1
49a5fb4;text-decoration:none}.places-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.wikipedia-badge[_ngcontent-%COMP%]{display:inline-flex;align-items:center;margin-left:.3rem;opacity:.75}.wikipedia-badge[_ngcontent-%COMP%]:hover{opacity:1}.wikipedia-badge[_ngcontent-%COMP%]   img[_ngcontent-%COMP%]{display:block}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var wF=(e,n)=>n.alternateNameId;function EF(e,n){e&1&&(l(0,"p",0),s(1,"Loading\u2026"),a())}function MF(e,n){e&1&&(l(0,"p",1),s(1,"No country found with this code."),a())}function PF(e,n){e&1&&(l(0,"p",1),s(1,"Could not load alternate names right now."),a())}function DF(e,n){if(e&1&&(l(0,"p",0),s(1),a()),e&2){let t=p();d(),A("No alternate names are recorded for ",t.countryName,".")}}function IF(e,n){if(e&1&&(l(0,"p",0),s(1),a()),e&2){let t=p();d(),A("No alternate names are recorded for ",t.countryName,".")}}function TF(e,n){if(e&1&&(l(0,"span",12),s(1),a()),e&2){let t=p(4);d(),g(t.sortDirection()==="asc"?"\u25B2":"\u25BC")}}function OF(e,n){if(e&1&&(l(0,"span",12),s(1),a()),e&2){let t=p(4);d(),g(t.sortDirection()==="asc"?"\u25B2":"\u25BC")}}
49function NF(e,n){if(e&1&&(l(0,"span",12),s(1),a()),e&2){let t=p(4);d(),g(t.sortDirection()==="asc"?"\u25B2":"\u25BC")}}function kF(e,n){if(e&1&&(l(0,"a",14),s(1),a()),e&2){let t=p().$implicit;v("href",t.name,Y),d(),g(t.name)}}function AF(e,n){if(e&1&&(l(0,"a",14),s(1),a()),e&2){let t=p().$implicit;v("href","https://www.wikidata.org/wiki/"+t.name,Y),d(),g(t.name)}}function RF(e,n){if(e&1&&s(0),e&2){let t=p().$implicit;A(" ",t.name," ")}}function FF(e,n){if(e&1&&(l(0,"code"),s(1),a()),e&2){let t=p().$implicit;d(),g(t.locale)}}function LF(e,n){if(e&1&&(l(0,"tr")(1,"td",13),y(2,kF,2,2,"a",14)(3,AF,2,2,"a",14)(4,RF,1,1),a(),l(5,"td"),s(6),a(),l(7,"td"),y(8,FF,2,1,"code"),a()()),e&2){let t=n.$implicit;d(2),_(t.locale==="link"?2:t.locale==="wkdt"?3:4),d(4),g(t.displayLocale),d(2),_(t.locale?8:-1)}}function VF(e,n){if(e&1){let t=$();l(0,"div",8)(1,"table",10)(2,"thead")(3,"tr")(4,"th")(5,"button",11),M("click",function(){S(t);let o=p(3);return w(o.toggleSort("name"))}),s(6," Name "),y(7,TF,2,1,"span",12),a()(),l(8,"th")(9,"button",11),M("click",function(){S(t);let o=p(3);return w(o.toggleSort("locale"))}),s(10," Language "),y(11,OF,2,1,"span",12),a()(),l(12,"th")(13,"button",11),M("click",function(){S(t);let o=p(3);return w(o.toggleSort("code"))}),s(14," Language Code "),y(15,NF,2,1,"span",12),a()()()(),l(16,"tbody"),I(17,LF,9,3,"tr",null,wF),a()()()}if(e&2){let t=p(3);d(4),_e("aria-sort",t.sortColumn()==="name"?t.sortDirection()==="asc"?"ascending":"descending":"none"),d(3),_(t.sortColumn()==="name"?7:-1),d(),_e("aria-sort",t.sortColumn()==="locale"?t.sortDirection()==="asc"?"ascending":"descending":"none"),d(3),_(t.sortColumn()==="locale"?11:-1),d(),_e("aria-sort",t.sortColumn()==="code"?t.sortDirection()==="asc"?"ascending":"descending":"none"),d(3),_(t.sortColumn()==="code"?15:-1),d(2),T(t.sortedEntries())}}function UF(e,n){if(e&1&&(l(0,"nav",2)(1,"a",3),s(2,"Home"),a(),l(3,"span",4),s(4,"\u203A"),a(),l(5,"a",5),s(6,"Countries"),a(),l(7,"span",4),s(8,"\u203A"),a(),l(9,"a",6),s(10),a(),l(11,"span",4),s(12,"\u203A"),a(),l(13,"span",7),s(14,"Other Country Names"),a()(),l(15,"h1"),s(16),a(),y(17,DF,2,1,"p",0)(18,IF,2,1,"p",0)(19,VF,19,6,"div",8),j(20,"app-country-sub-nav",9)),e&2){let t=n,i=p(2);d(9),v("routerLink",i.countryPath(t)),d(),g(t.countryName),d(6),A("Alternate Names or Name Variants for ",t.countryName,""),d(),_(t.geonameId?i.sortedEntries().length?19:18:17),d(3),v("country",t)}}function jF(e,n){if(e&1&&y(0,UF,21,5),e&2){let t,i=p();_((t=i.country())?0:-1,t)}}var Ld=class e{route=h(ve);countryInfo=h(it);alternateNames=h(Sr);title=h(H);state=E("loading");country=E(null);entries=E([]);sortColumn=E("locale");sortDirection=E("asc");sortedEntries=G(()=>{let n=this.sortColumn(),t=this.sortDirection()==="asc"?1:-1,i=o=>{switch(n){case"code":return o.locale;case"locale":return o.displayLocale;case"name":return o.name}};return this.entries().filter(o=>o.locale!=="post").sort((o,r)=>i(o).localeCompare(i(r))*t)});constructor(){this.route.paramMap.pipe(N(n=>(n.get("cc")??"").toUpperCase()),xe(()=>this.state.set("loading")),be(n=>this.countryInfo.getCountries().pipe(N(t=>({cc:n,countries:t})))),be(({cc:n,countries:t})=>{let i=t.find(o=>o.isoCode===n)??null;return i?i.geonameId?this.alternateNames.getAlternateNames(String(i.geonameId)).pipe(N(o=>({country:i,entries:o}))):Q({country:i,entries:[]}):Q({country:null,entries:[]})})).subscribe({next:({country:n,entries:t})=>{if(!n){this.state.set("not-found");return}this.country.set(n),this.entries.set(t),this.title.setTitle(`Alternate Names for ${n.countryName} \u2014 GeoNames UI`),this.state.set("loaded")},error:()=>this.state.set("error")})}countryPath(n){return`/countries/${n.isoCode}/${We(n.countryName)}.html`}toggleSort(n){this.sortColumn()===n?this.sortDirection.set(this.sortDirection()==="asc"?"desc":"asc"):(this.sortColumn.set(n),this.sortDirection.set("asc"))}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-other-country-names-page"]],decls:4,vars:1,consts:[[1,"placeholder"],[1,"placeholder","error"],["aria-label","Breadcrumb",1,"breadcrumb"],["routerLink","/"],[1,"sep"],["routerLink","/countries"],[3,"routerLink"],[1,"current"],[1,"table-scroll"],["active","other-names",3,"country"],[1,"names-table"],["type","button",3,"click"],[1,"sort-arrow"],[1,"name-col"],["target","_blank","rel","noopener noreferrer",3,"href"]],template:function(t,i){if(t&1&&y(0,EF,2,0,"p",0)(1,MF,2,0,"p",1)(2,PF,2,0,"p",1)(3,jF,1,1),t&2){let o;_((o=i.state())==="loading"?0:o==="not-found"?1:o==="error"?2:o==="loaded"?3:-1)}},dependencies:[W,Jn],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.breadcrumb[_ngcontent-%COMP%]{font-size:.85rem;color:#555;margin-bottom:1rem;overflow-wrap:break-word}
49.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.breadcrumb[_ngcontent-%COMP%]   .sep[_ngcontent-%COMP%]{margin:0 .35rem;color:#999}.breadcrumb[_ngcontent-%COMP%]   .current[_ngcontent-%COMP%]{color:#222;font-weight:600}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.6rem}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto;margin-bottom:1rem}.names-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.9rem}.names-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .names-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.4rem .7rem;border-bottom:1px solid #eee;text-align:left}.names-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555;font-size:.75rem;text-transform:uppercase;letter-spacing:.03em}.names-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.names-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.names-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:none;background:none;font:inherit;text-transform:inherit;letter-spacing:inherit;color:inherit;cursor:pointer;padding:0;display:inline-flex;align-items:center;gap:.3rem}.names-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:hover{color:#1a5fb4}.sort-arrow[_ngcontent-%COMP%]{font-size:.65rem}.name-col[_ngcontent-%COMP%]{word-break:break-word}.names-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.names-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.names-table[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:#f0f0f0;border-radius:3px;padding:.05rem .3rem;font-size:.8rem}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};function BF(e,n){if(e&1&&(l(0,"li"),s(1),a()),e&2){let t=n.$implicit;d(),g(t)}}var Za=class e{title=h(H);orderUrl="https://www.geonames.org/orderpremiumdata/";sampleUrl="https://download.geonames.org/pd_sample.zip";downloadUrl="https://www.geonames.org/premiumdump/";additionalDataFiles=["airports","bounding boxes for countries, most administrative divisions, some islands, etc for over 5,000,000 features (outer bounding boxes)","countrysubdivisions","dependencies","spot city relation","un-locode-geonameid"];constructor(){this.title.setTitle("GeoNames Premium Data Subscription \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-premium-data"]],decls:91,vars:4,consts:[[1,"lead"],["routerLink","/products/premium-postalcodes.html"],["routerLink","/products/premium-data-polygons.html"],["routerLink","/commercial-webservices.html"],[1,"ws-section"],["target","_blank","rel","nofollow noopener noreferrer",1,"buy-btn",3,"href"],[1,"note"],["target","_blank","rel","noopener noreferrer",3,"href"],["href","mailto:[email protected]"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"Monthly Premium Gazetteer Data Subscription"),a(),l(2,"p",0),s(3,` The GeoNames Monthly Premium Data is a high quality release that has passed a huge number of consistency checks. The modifications and differences to the previous data release have been monitored and verified by members of the GeoNames team. The Monthly Premium Data is an excellent choice for enterprise users. Applications using the Premium Data can reduce their own consistency checks and let the GeoNames team do this job.
50`),a(),l(4,"p"),s(5," The Premium Data Subscription covers the toponyms, the postal code files are available as "),l(6,"a",1),s(7,"optional premium offering"),a(),s(8,". The "),l(9,"a",2),s(10,"polygons"),a(),s(11,` are a separate subscription.
51`),a(),l(12,"p"),s(13," The Premium Data allows you to implement your own code directly on the data, if you are interested in the GeoNames webservices the "),l(14,"a",3),s(15,"premium webservices"),a(),s(16,` are the right choice.
52`),a(),l(17,"section",4)(18,"h2"),s(19,"Price"),a(),l(20,"p"),s(21," The annual subscription to the Premium Data is available for only "),l(22,"strong"),s(23,"840 \u20AC"),a(),s(24," for a 12 month period with 12 releases and can be paid via PayPal or bank transfer. "),a(),l(25,"a",5),s(26,"Buy now"),a()(),l(27,"section",4)(28,"h2"),s(29,"Value for Subscribers"),a(),l(30,"h3"),s(31,"Coherent and Verified Data"),a(),l(32,"p"),s(33," We run a great number of consistency checks to make sure the quality of the data improves from one release to the next and no inconsistencies are added to the data. We also monitor modifications and manually verify changes and updates for relevant toponyms. The monitoring helps us find errors added to the database and remove and fix them before we release the premium dump. "),a(),l(34,"h3"),s(35,"Release Notes and Documentation"),a(),l(36,"p"),s(37," Major data updates are described 
52in the documentation to make sure applications can react accordingly and take the necessary steps. Example: major city changing the main name like Bombay being renamed to Mumbai. "),a(),l(38,"p"),s(39," We recommend that applications read the Release Notes and Documentation for a release before updating their local database with the new data. Major changes like the addition of new countries (like Kosovo) may require modifications to the application. "),a(),l(40,"h3"),s(41,"Additional Datafiles"),a(),l(42,"p"),s(43," Premium Dump users also benefit from additional data files. These additional data files include further information on administrative divisions (iso and other codes), names of the types of administrative divisions or languages spoken in administrative divisions. "),a(),l(44,"ul"),I(45,BF,2,1,"li",null,Re),a(),l(47,"h3"),s(48,"Statistics of Modifications since last Release"),a(),l(49,"p"),s(50,"The monthly release includes statistics of modifications for attributes and countries since the previous premium release."),a(),l(51,"h3"),s(52,"Archive of previous Premium Data Releases"),a(),l(53,"p"),s(54," The monthly premium data files are archived and subscribers have access to the archive. The archive includes all data files, the documentation and the readme. The archive is useful for users who don't want to update their local database on a monthly schedule. With the files and documentation in the archive it is easy and simple to update a local database at any moment. "),a(),l(55,"p",6),s(56," For applications that skip some releases we recommend to read the documentation of the skipped months to be informed about all changes. "),a(),l(57,"h3"),s(58,"Data formats"),a(),l(59,"p"),s(60,"The premium data is available in tabulator separated flat files and in RDF format. The files have the same format as the freely available files."),a(),l(61,"h3"),s(62,"New Datasets"),a(),l(63,"p"),s(64," The proceeds from the Premium Data Dumps help update datasources and adding new datasets to the geonames database more timely and consistently than it would otherwise be possible. "),a()(),l(65,"section",4)(66,"h2"),s(67,"Sample"),a(),l(68,"p"),s(69," A small "),l(70,"a",7),s(71,"sample"),a(),s(72," subset is available. It contains the additional files. The premium extract includes the same files as the free extract in the same format. "),a()(),l(73,"section",4)(74,"h2"),s(75,"Download"),a(),l(76,"p"),s(77," Subscribers to the Premium Data Subscription can "),l(78,"a",7),s(79,"download"),a(),s(80," the data files for all months of their subscription period "),l(81,"a",7),s(82,"here"),a(),s(83,". "),a()(),l(84,"section",4)(85,"h2"),s(86,"Contact"),a(),l(87,"p"),s(88,"Contact: "),l(89,"a",8),s(90,"[email protected]"),a()()()),t&2&&(d(25),v("href",i.orderUrl,Y),d(20),T(i.additionalDataFiles),d(25),v("href",i.sampleUrl,Y),d(8),v("href",i.downloadUrl,Y),d(3),v("href",i.downloadUrl,Y))},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem}a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%]{font-size:.9rem;margin:1rem 0 .3rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:.4rem 0;padding-left:1.2rem;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.2rem 0}.note[_ngcontent-%COMP%]{color:#777;font-size:.82rem}.buy-btn[_ngcontent-%COMP%]{display:inline-block;appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff!important;border-radius:4px;padding:.4rem .9rem;font-size:.88rem;text-decoration:none!important;margin-top:.5rem}.buy-btn[_ngcontent-%COMP%]:hover{background:#164d92}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var Vd=class e{title=h(H);constructor(){this.title.setTitle("GeoNames User Manual \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-manual"]],decls:197,vars:0,consts:[[1,"ws-section"],["routerLink","/recent-changes.html"],["href","https://www.geonames.org/login","target","_blank","rel","noopener noreferrer"],["src","img/manual/feature-panel.png","alt","The Feature tab for S\xE4ntis, showing coordinates, elevation, timezone, feature code and Move/Edit controls",1,"manual-screenshot"],["src","img/manual/edit-form.png","alt","Editing the basic 
52information of S\xE4ntis - name, feature class and code, elevation, population, timezone",1,"manual-screenshot"],["src","img/manual/move-form.png","alt","Moving S\xE4ntis by editing its latitude and longitude directly",1,"manual-screenshot"],[1,"note"],["src","img/manual/alt-name-form.png","alt","Adding the alternate name Cima S\xE4ntis to S\xE4ntis, with code 'it' for Italian",1,"manual-screenshot"],[1,"code-list"],["src","img/manual/add-place-form.png","alt","The new-place-name entry form after pressing 'Add place here' and clicking a map location near S\xE4ntis",1,"manual-screenshot"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"GeoNames User Manual"),a(),l(2,"section",0)(3,"h2"),s(4,"Overview"),a(),l(5,"p"),s(6," GeoNames has a simple edit interface that allows users to edit GeoNames information, move a point and add new place names to the GeoNames database. Open any place's page and use its tabs: the "),l(7,"strong"),s(8,"Feature"),a(),s(9," tab shows detail information about the place and lets you edit it or move it, the "),l(10,"strong"),s(11,"Map"),a(),s(12," tab lets you browse the area and add new places, and the "),l(13,"strong"),s(14,"Alternate names"),a(),s(15," tab lets you edit name variants like 'Big Apple' for 'New York', or 'Nueva York' the Spanish name for 'New York'. The "),l(16,"a",1),s(17,"most recent updates"),a(),s(18," are available as an html page and as an rss feed. "),a(),l(19,"p"),s(20,"In the following we will look at screenshots and cover the following topics:"),a(),l(21,"ul")(22,"li"),s(23,"the user account"),a(),l(24,"li"),s(25,"the Feature tab"),a(),l(26,"li"),s(27,"edit GeoNames basic information"),a(),l(28,"li"),s(29,"move point"),a(),l(30,"li"),s(31,"edit alternate names"),a(),l(32,"li"),s(33,"add a new placename to the GeoNames database"),a()()(),l(34,"section",0)(35,"h2"),s(36,"The GeoNames Account"),a(),l(37,"p"),s(38," In order to modify features and insert new features you will need a GeoNames user account. Use the sign-in form in the top navigation bar, or "),l(39,"a",2),s(40,"create one here"),a(),s(41," if you don't have one yet. "),a()(),l(42,"section",0)(43,"h2"),s(44,"The Feature Tab"),a(),l(45,"p"),s(46,` Every place's page has a Feature tab showing detail information like population, elevation, timezone, feature code and a link to Wikipedia. It also has the "Move" and "Edit" controls to modify the information. `),a(),j(47,"img",3),a(),l(48,"section",0)(49,"h2"),s(50,"Edit GeoNames Basic Information"),a(),l(51,"p"),s(52," Clicking 'Edit' on the Feature tab opens a form pre-filled with the place's current information. In the screenshot below we're about to change the elevation of the mountain 'S\xE4ntis'. "),a(),j(53,"img",4),a(),l(54,"section",0)(55,"h2"),s(56,"Move a Point"),a(),l(57,"p"),s(58," In order to correct the coordinates of a place click 'Move' on the Feature tab. It opens latitude/longitude fields pre-filled with the current position - edit them directly and save. "),a(),j(59,"img",5),l(60,"p",6),s(61," You can also move a place by clicking the 'Move' button in its marker popup on the Map tab, then clicking the new location on the map itself. "),a()(),l(62,"section",0)(63,"h2"),s(64,"Edit Alternate Names"),a(),l(65,"p"),s(66," Alternate names are used to store and display name variants. In the screenshot below we're about to add the Italian name 'Cima S\xE4ntis' on the Alternate names tab. "),a(),j(67,"img",7),l(68,"h3"),s(69,"Guidelines"),a(),l(70,"ul")(71,"li"),s(72,"The main name for the toponym should be a widely accepted international or English name. Local languages are entered as alternate names."),a(),l(73,"li"),s(74," The language code for the alternate names are normally the 2-character ISO 639 language codes, for more exotic languages that do not have a 2-character ISO code the 3-character code is used instead. Some pseudo language codes are used to mark other entries like postal codes, abbreviations or links (see below). "),a(),l(75,"li"),s(76,"The flag 'isPreferred' helps distinguish between several alternate names in the same language. It marks the most commonly used name."),a(),l(77,"li"),s(78,"Proper casing should be used. Upper case only for the first character of a term or for abbreviations."),a(),l(79,"li"),s(80,` Avoid redundancy. Do not add the same name with 'minus' and blanks between terms, only add the more often used spelling variant in this case. (Ex: "La Colle sur Loup" for "La Colle-sur-Loup", it is sufficient to add "La Colle-sur-Loup" as the geonames search engine can handle searches with or without minus.) `),a(),l(81,"li"),s(82,"Use full spelling for 'Sankt' (German), 'Saint' and 'Sainte' (French). The respective abbreviations St. and Ste. are automatically handled by the search engine."),a()(),l(83,"h3"),s(84,"Language Codes"),a(),l(85,"p"),s(86,"The language code is referring to the ISO-639-2 and ISO-639-3 codes. Some examples:"),a(),l(87,"ul",8)(88,"li"),j(89,"code"),s(90," empty language code: a default name generally understood or with unknown language"),a(),l(91,"li")(92,"code"),s(93,"en"),a(),s(94," English"),a(),l(95,"li")(96,"code"),s(97,"fr"),a(),s(98," French"),a(),l(99,"li")(100,"code"),s(101,"he"),a(),s(102," Hebrew"),a(),l(103,"li")(104,"code"),s(105,"uk"),a(),s(106," Ukrainian"),a(),l(107,"li")(108,"code"),s(109,"zh"),a(),s(110," Chinese"),a(),l(111,"li")(112,"code"),s(113,"wuu"),a(),s(114," Simplified Chinese"),a(),l(115,"li")(116,"code"),s(117,"yue"),a(),s(118," Traditional Chinese"),a(),l(119,"li")(120,"code"),s(121,"pny"),a(),s(122," Pinyin Chinese"),a()(),l(123,"h3"),s(124,"Pseudo Codes"),a(),l(125,"ul",8)(126,"li")(127,"code"),s(128,"post"),a(),s(129," for postal codes"),a(),l(130,"li")(131,"code"),s(132,"link"),a(),s(133," for a link to a website, in particular links to the English Wikipedia article, but also links to other languages in Wikipedia or to other websites about the toponym"),a(),l(134,"li")(135,"code"),s(136,"iata"),a(),s(137,", "),l(138,"code"),s(139,"icao"),a(),s(140,", "),l(141,"code"),s(142,"faac"),a(),s(143,", "),l(144,"code"),s(145,"tcid"),a(),s(146," and "),l(147,"code"),s(148,"unlc"),a(),s(149," for the respective airport codes"),a(),l(150,"li")(151,"code"),s(152,"abbr"),a(),s(153," for an abbreviation"),a(),l(154,"li")(155,"code"),s(156,"wkdt"),a(),s(157," wikidata id"),a(),l(158,"li")(159,"code"),s(160,"phon"),a(),s(161," phonetics"),a(),l(162,"li")(163,"code"),s(164,"piny"),a(),s(165," pinyin"),a(),l(166,"li")(167,"code"),s(168,"fr_1793"),a(),s(169," for names used during the French Revolution"),a()()(),l(170,"section",0)(171,"h2"),s(172,"Add a New Placename to the GeoNames Database"),a(),l(173,"p"),s(174,"On a place's Map tab (or any browse map) you find a toolbar above the map with a couple of buttons."),a(),l(175,"p"),s(176," For the creation of new place names go to the location of the new place name and press the '+ Add place here' button. In any case you have to go to the map location of the place to be added to make sure the place does not already exist. "),a(),l(177,"p"),s(178," You don't have to enter country and administrative division in the entry form. This information will automatically be 'reverse geocoded' from the location of the place during the save process. "),a(),l(179,"p"),s(180,"You have to be logged in to add a place name. This restriction helps to prevent vandalism."),a(),l(181,"h3"),s(182,"Guidelines"),a(),l(183,"ul")(184,"li"),s(185,"Make sure the place does not already exist."),a(),l(186,"li"),s(187,"Don't add irrelevant places like your own house. There are other projects for places of only personal interest."),a(),l(188,"li"),s(189,"Find the best feature class and feature code for the new place name."),a(),l(190,"li"),s(191,"The default name of the place name should be the single widely accepted international or English name. Add names in local languages as alternate names."),a()(),l(192,"p"),s(193," As soon as you click the map location for the new place name an entry form opens where you enter the place name, the feature class and the feature code. Optionally you may also add elevation and population. "),a(),j(194,"img",9),l(195,"p",6),s(196,"Country and administrative division are automatically derived from where you place the marker on the map."),a()())},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}
52a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]:first-of-type{border-top:none;padding-top:.5rem}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%]{font-size:.9rem;margin:1rem 0 .3rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:.4rem 0;padding-left:1.2rem;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.25rem 0}.code-list[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:#f8f9fa;padding:.05rem .35rem;border-radius:3px;font-size:.85em;margin-right:.3rem}.note[_ngcontent-%COMP%]{color:#777;font-size:.82rem}.manual-screenshot[_ngcontent-%COMP%]{display:block;max-width:100%;height:auto;margin:.6rem 0;border:1px solid #e5e5e5;border-radius:4px}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var Ud=class e{title=h(H);constructor(){this.title.setTitle("GeoNames Data & Web Services \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-export-overview"]],decls:116,vars:0,consts:[["id","dump",1,"ws-section"],["href","https://download.geonames.org/export/dump","target","_blank","rel","noopener noreferrer"],["href","https://download.geonames.org/export/dump/readme.txt","target","_blank","rel","noopener noreferrer"],["routerLink","/products/premium-data.html"],["href","https://download.geonames.org/export/zip","target","_blank","rel","noopener noreferrer"],["id","ws",1,"ws-section"],["routerLink","/export/ws-overview.html"],["routerLink","/export/web-services.html"],["routerLink","/export/client-libraries.html"],[1,"ws-section"],["href","http://forum.geonames.org","target","_blank","rel","noopener noreferrer"],["href","http://groups.google.com/group/geonames","target","_blank","rel","noopener noreferrer"],["routerLink","/services.html"],["href","https://www.geonames.org/data-sources.html","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/team.html#ambassadors","target","_blank","rel","noopener noreferrer"],["routerLink","/manual.html"],["href","https://www.geonames.org/donations.html","target","_blank","rel","noopener noreferrer"],["id","terms",1,"ws-section"],["routerLink","/export/credits.html"],["routerLink","/export/webservice-exception.html"],["routerLink","/commercial-webservices.html"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"GeoNames Data"),a(),l(2,"section",0)(3,"h2"),s(4,"Data Extract"),a(),l(5,"p"),s(6," A daily GeoNames database extract can be downloaded in the form of a large worldwide text file (allCountries.zip). Additional country files are available for convenience. You find the files on our "),l(7,"a",1),s(8,"download server"),a(),s(9,". Read the "),l(10,"a",2),s(11,"readme.txt"),a(),s(12," for details. A "),l(13,"a",3),s(14,"Premium Data Subscription"),a(),s(15," variant is available for professional users. "),a(),l(16,"p"),s(17," Postal codes are available as a "),l(18,"a",4),s(19,"separate download"),a(),s(20,". "),a()(),l(21,"section",5)(22,"h2"),s(23,"Web Services"),a(),l(24,"p"),s(25,"GeoNames is offering a wide range of sophisticated web services."),a(),l(26,"ul")(27,"li")(28,"a",6),s(29,"web service overview"),a()(),l(30,"li")(31,"a",7),s(32,"web service documentation"),a()(),l(33,"li")(34,"a",8),s(35,"web service client libraries"),a()()()(),l(36,"section",9)(37,"h2"),s(38,"Support"),a(),l(39,"p"),s(40," Free support for GeoNames is provided by the community. The GeoNames team is available for commercial support and consulting: "),a(),l(41,"ul")(42,"li")(43,"a",10),s(44,"GeoNames Forum"),a()(),l(45,"li"),s(46," GeoNames mailing list: "),l(47,"a",11),s(48,"[email protected]"),a()(),l(49,"li")(50,"a",12),s(51,"Commercial Support and Consulting"),a()()()(),l(52,"section",9)(53,"h2"),s(54,"Sources and Contributions"),a(),l(55,"ul")(56,"li")(57,"strong"),s(58,"Sources:"),a(),s(59," GeoNames is aggregating over a hundred different "),l(60,"a",13),s(61,"data sources"),a(),s(62,"."),a(),l(63,"li")(64,"strong"),s(65,"Ambassadors:"),a(),l(66,"a",14),s(67,"GeoNames Ambassadors"),a(),s(68," help in many countries."),a(),l(69,"li")(70,"strong"),s(71,"Wiki:"),a(),s(72," A "),l(73,"a",15),s(74,"wiki"),a(),s(75," allows to view the data and quickly fix errors and add missing places."),a(),l(76,"li")(77,"strong"),s(78,"Donations and 
52Sponsoring:"),a(),s(79," Costs for running GeoNames are covered by "),l(80,"a",16),s(81,"donations and sponsoring"),a(),s(82,"."),a()()(),l(83,"section",17)(84,"h2"),s(85,"Terms and Conditions"),a(),l(86,"ul")(87,"li")(88,"strong"),s(89,"free:"),a(),s(90," GeoNames data is free, the data is available without costs."),a(),l(91,"li")(92,"strong"),s(93,"cc-by licence"),a(),s(94," (creative commons attribution license). You should give credit to GeoNames when using data or web services with a link or another reference to GeoNames."),a(),l(95,"li"),s(96,"commercial usage is allowed"),a(),l(97,"li")(98,"strong"),s(99,"'as is':"),a(),s(100,' The data is provided "as is" without warranty or any representation of accuracy, timeliness or completeness.'),a(),l(101,"li")(102,"strong"),s(103,"10,000 credits"),a(),s(104," daily limit per application (identified by the parameter 'username'), the hourly limit is 1000 credits. A "),l(105,"a",18),s(106,"credit"),a(),s(107," is a web service request hit for most services. An "),l(108,"a",19),s(109,"exception"),a(),s(110," is thrown when the limit is exceeded. "),a(),l(111,"li"),s(112," Service Level Agreement is available for our "),l(113,"a",20),s(114,"premium web services"),a(),s(115,". "),a()()())},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]:first-of-type{border-top:none;padding-top:.5rem}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:.4rem 0;padding-left:1.2rem;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.3rem 0}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var HF=(e,n)=>n.version;function $F(e,n){if(e&1&&(l(0,"a",19),s(1,"rdf"),a()),e&2){let t=p().$implicit;v("href",t.href,Y)}}function zF(e,n){if(e&1&&(l(0,"p"),s(1),a()),e&2){let t=p().$implicit;d(),g(t.notes)}}function GF(e,n){if(e&1&&(l(0,"li")(1,"strong"),s(2),a(),y(3,$F,2,1,"a",19)(4,zF,2,1,"p"),a()),e&2){let t=n.$implicit;d(2),le("",t.date,", Version ",t.version,""),d(),_(t.href?3:-1),d(),_(t.notes?4:-1)}}var jd=class e{title=h(H);versionHistory=[{version:"3.3",date:"2021 July",notes:"PPCLH and PPLH of class P (not A) \u2014 Peter Kleiweg",href:"https://www.geonames.org/ontology/ontology_v3.3.rdf"},{version:"3.2",date:"2019 November",notes:"Elisa Kendall",href:"https://www.geonames.org/ontology/ontology_v3.2.rdf"},{version:"3.1",date:"2012 November",notes:"Added gn:GeonamesFeature, subclass of gn:Feature. Added explicit property gn:geonamesID, mandatory and unique for each gn:GeonamesFeature instance. Deleted owl:FunctionalProperty declarations for properties attached to gn:Feature, replaced by local cardinality restrictions on gn:GeonamesFeature \u2014 so gn:Feature and its properties can be used in the open world for features not necessarily identified in the GeoNames database, or with partial descriptions. Modified equivalent classes and superclasses of geonames:Feature in other vocabularies. Added new feature codes for historical features. Improved metadata.",href:"https://www.geonames.org/ontology/ontology_v3.1.rdf"},{version:"3.0.1",date:"2012 February",notes:"Improved metadata. Changed gn:featureClass and gn:featureCode superproperty from dc:subject to dc:type. Property chain ensuring consistency of feature code and feature class values (OWL 2.0). Indication of new and deprecated feature codes using skos:historyNote. Multilingual labels for codes (Russian, Bulgarian, Swedish and Norwegian). Explicit code values using skos:notation. New types of alternate names (historical, colloquial). Equivalent classes matching feature codes in various ontologies such as schema.org, linkedgeodata.org, dbpedia.org, INSEE ontology are provided in a separate mappings file.",href:"https://www.geonames.org/ontology/ontology_v3.0.1.rdf"},{version:"2.2.1",date:"2010 October",notes:"Restore name properties, subproperties of skos labels.",href:"https://www.geonames.org/ontology/ontology_v2.2.1.rdf"},{version:"2.2",date:"2010 September",notes:"Use skos labels, add URIs for parent admin divisions.",href:"https://www.geonames.org/ontology/ontology_v2.2.rdf"},{version:"2.1",date:"2010 June",notes:"Changed inCountry to countryCode. Added metadata for license information.",href:"https://www.geonames.org/ontology/ontology_v2.1.rdf"},{version:"2.0",date:"2007 Apr 02",notes:"Added isOfficialName, locatedIn, relationships with GEMET concepts.",href:null},{version:"1.2.3",date:"2006 Oct 30",notes:"Added labels for name and alternate names.",href:null},{version:"1.2.2",date:"2006 Oct 25",notes:"Cosmetics.",href:null},{version:"1.2.1",date:"2006 Oct 23",notes:"Linked data document with backlink to main feature.",href:null},{version:"1.2",date:"2006 Oct 21",notes:"New URIs with 303 redirect, linked data (contains, neighbours, nearby).",href:null},{version:"1.0",date:"2006 Oct 14",notes:"",href:null}];rdfExample=`<rdf:RDF
53  xmlns:cc="http://creativecommons.org/ns#"
54  xmlns:dcterms="http://purl.org/dc/terms/"
55  xmlns:foaf="http://xmlns.com/foaf/0.1/"
56  xmlns:gn="https://www.geonames.org/ontology#"
57  xmlns:owl="http://www.w3.org/2002/07/owl#"
58  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
59  xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
60  xmlns:wgs84_pos="http://www.w3.org/2003/01/geo/wgs84_pos#">
61<gn:Feature rdf:about="https://sws.geonames.org/3020251/">
62  <rdfs:isDefinedBy rdf:resource="https://sws.geonames.org/3020251/about.rdf"/>
63  <gn:name>Embrun</gn:name>
64  <gn:alternateName xml:lang="oc">Ambrun</gn:alternateName>
65  <gn:featureClass rdf:resource="https://www.geonames.org/ontology#P"/>
66  <gn:featureCode rdf:resource="https://www.geonames.org/ontology#P.PPL"/>
67  <gn:countryCode>FR</gn:countryCode>
68  <gn:population>7069</gn:population>
69  <gn:postalCode>05200</gn:postalCode>
70  <wgs84_pos:lat>44.56387</wgs84_pos:lat>
71  <wgs84_pos:long>6.49526</wgs84_pos:long>
72  <gn:parentFeature rdf:resource="https://sws.geonames.org/6446638/"/>
73  <gn:parentCountry rdf:resource="https://sws.geonames.org/3017382/"/>
74  <gn:parentADM1 rdf:resource="https://sws.geonames.org/2985244/"/>
75  <gn:parentADM2 rdf:resource="https://sws.geonames.org/3013738/"/>
76  <gn:parentADM3 rdf:resource="https://sws.geonames.org/3016701/"/>
77  <gn:parentADM4 rdf:resource="https://sws.geonames.org/6446638/"/>
78  <gn:nearbyFeatures rdf:resource="https://sws.geonames.org/3020251/nearby.rdf"/>
79  <gn:locationMap rdf:resource="https://www.geonames.org/3020251/embrun.html"/>
80  <gn:wikipediaArticle rdf:resource="https://en.wikipedia.org/wiki/Embrun%2C_Hautes-Alpes"/>
81  <rdfs:seeAlso rdf:resource="http://dbpedia.org/resource/Embrun%2C_Hautes-Alpes"/>
82</gn:Feature>
83<foaf:Document rdf:about="https://sws.geonames.org/3020251/about.rdf">
84  <foaf:primaryTopic rdf:about="https://sws.geonames.org/3020251/"/>
85  <cc:license rdf:resource="https://creativecommons.org/licenses/by/3.0/"/>
86  <cc:attributionURL rdf:resource="https://sws.geonames.org/3020251/"/>
87  <cc:attributionName rdf:datatype="http://www.w3.org/2001/XMLSchema#string">GeoNames</cc:attributionName>
88  <dcterms:created rdf:datatype="http://www.w3.org/2001/XMLSchema#date">2006-01-15</dcterms:created>
89  <dcterms:modified rdf:datatype="http://www.w3.org/2001/XMLSchema#date">2010-04-19</dcterms:modified>
90</foaf:Document>
91</rdf:RDF>`;constructor(){this.title.setTitle("GeoNames Ontology - Geo Semantic Web \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-ontology-documentation"]],decls:124,vars:1,consts:[[1,"ws-section"],["href","https://www.geonames.org/ontology/ontology_v3.3.rdf","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/ontology/mappings_v3.01.rdf","target","_blank","rel","noopener noreferrer"],["href","https://sws.geonames.org/3020251/","target","_blank","rel","noopener noreferrer"],["href","https://sws.geonames.org/3020251/about.rdf","target","_blank","rel","noopener noreferrer"],["href","http://geonames.wordpress.com/2006/10/21/semantic-web-concept-vs-document/","target","_blank","rel","noopener noreferrer"],[1,"rdf-example"],["href","https://sws.geonames.org/3017382/contains.rdf","target","_blank","rel","noopener noreferrer"],["href","https://sws.geonames.org/3017382/neighbours.rdf","target","_blank","rel","noopener noreferrer"],["href","https://sws.geonames.org/6254976/nearby.rdf","target","_blank","rel","noopener noreferrer"],["href","https://sws.geonames.org/6295630/","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/export/geonames-search.html","target","_blank","rel","noopener noreferrer"],["href","https://download.geonames.org/export/dump/","target","_blank","rel","noopener noreferrer"],["href","https://download.geonames.org/all-geonames-rdf.zip","target","_blank","rel","noopener noreferrer"],[1,"note"],["href","https://web.archive.org/web/20080212144050/http://www.geospatialsemanticweb.com/2006/10/14/geonames-ontology-in-owl","target","_blank","rel","noopener noreferrer"],["routerLink","/statistics/total.html"],["href","http://linkeddata.org/","target","_blank","rel","noopener noreferrer"],[1,"version-history"],["target","_blank","rel","noopener noreferrer",1,"version-link",3,"href"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"GeoNames Ontology"),a(),l(2,"section",0)(3,"h2"),s(4,"The Semantic Web"),a(),l(5,"p"),s(6,"The Semantic Web is a project that intends to add computer-processable meaning (semantics) to the World Wide Web."),a(),l(7,"p"),s(8," In Feb 2004, the World Wide Web Consortium released the Resource Description Framework (RDF) and the OWL Web Ontology Language (OWL) as W3C Recommendations. RDF is used to represent information and to exchange knowledge in the Web. OWL is used to publish and share set
91s of terms called ontologies, supporting advanced web search, software agents and knowledge management. "),a()(),l(9,"section",0)(10,"h2"),s(11,"The GeoNames Ontology"),a(),l(12,"p"),s(13," The GeoNames Ontology makes it possible to add geospatial semantic information to the World Wide Web. All over 11 million GeoNames toponyms now have a unique URL with a corresponding RDF web service. Other services describe the relation between toponyms. "),a(),l(14,"p"),s(15," The ontology for GeoNames is available in OWL: "),l(16,"a",1),s(17,"ontology_v3.3.rdf"),a(),s(18,", "),l(19,"a",2),s(20,"mappings"),a(),s(21,". "),a(),l(22,"p"),s(23," GeoNames is using 303 (See Other) redirection to distinguish the Concept (thing as is) from the Document about it. "),a(),l(24,"p"),s(25,"For the town Embrun in France we have these two URIs:"),a(),l(26,"ul")(27,"li"),s(28,"[1] "),l(29,"a",3),s(30,"https://sws.geonames.org/3020251/"),a()(),l(31,"li"),s(32,"[2] "),l(33,"a",4),s(34,"https://sws.geonames.org/3020251/about.rdf"),a()()(),l(35,"p"),s(36," The first URI [1] stands for the town in France. You use this URI if you want to refer to the town. The second URI [2] is the document with the information GeoNames has about Embrun. The GeoNames web server is configured to redirect requests for [1] to [2]. The redirection tells Semantic Web agents that Embrun is not residing on the GeoNames server but that GeoNames has information about it instead. See the blog posting about "),l(37,"a",5),s(38,'"Concept vs. Document"'),a(),s(39," for more information. "),a(),l(40,"h3"),s(41,"Example"),a(),l(42,"p"),s(43,' An example RDF description of a GeoNames "Feature" document, as obtained through the RDF webservice at '),l(44,"a",4),s(45,"https://sws.geonames.org/3020251/about.rdf"),a(),s(46,": "),a(),l(47,"pre",6)(48,"code"),s(49),a()()(),l(50,"section",0)(51,"h2"),s(52,"Linked Data"),a(),l(53,"p"),s(54," The features in the GeoNames Semantic Web are interlinked with each other. Depending on applicability the following documents are available for a feature: "),a(),l(55,"ul")(56,"li"),s(57," The children (countries for a continent, administrative subdivisions for a country, ...). As an example, the children of France: "),l(58,"a",7),s(59,"https://sws.geonames.org/3017382/contains.rdf"),a()(),l(60,"li"),s(61," The neighbours (neighbouring countries). As an example, the neighbours of France: "),l(62,"a",8),s(63,"https://sws.geonames.org/3017382/neighbours.rdf"),a()(),l(64,"li"),s(65," Nearby features. Nearby to the Eiffel Tower are Champ de Mars, Trocad\xE9ro - Palais de Chaillot, ...: "),l(66,"a",9),s(67,"https://sws.geonames.org/6254976/nearby.rdf"),a()()()(),l(68,"section",0)(69,"h2"),s(70,"Entry Points into the GeoNames Semantic Web"),a(),l(71,"p"),s(72,"There are several ways how you can enter the GeoNames Semantic Web:"),a(),l(73,"ul")(74,"li"),s(75,"start from "),l(76,"a",10),s(77,"mother earth"),a(),s(78," and follow the Linked Data links"),a(),l(79,"li"),s(80,"use the "),l(81,"a",11),s(82,"geonames search webservice"),a(),s(83," with the "),l(84,"code"),s(85,"type=rdf"),a(),s(86," parameter option"),a(),l(87,"li")(88,"a",12),s(89,"download the database dump"),a(),s(90,' and construct the url for the features using the pattern "http://sws.geonames.org/geonameId/" '),a(),l(91,"li")(92,"a",13),s(93,"RDF dump"),a(),s(94," with 11,985,741 features and about 182 million RDF triples (2020-02-14). The dump has one RDF document per toponym on every line of the file. "),l(95,"span",14),s(96,"Note: the file is pretty large \u2014 make sure the tool you use to uncompress is able to deal with the size and does not stop after 2GB, an issue that happens with some old (Windows) tool versions."),a()()()(),l(97,"section",0)(98,"h2"),s(99,"Contact"),a(),l(100,"p"),s(101,"Marc Wick (implementation)"),a()(),l(102,"section",0)(103,"h2"),s(104,"More Information"),a(),l(105,"ul")(106,"li")(107,"a",15),s(108,"Harry Chen in the Geospatial Semantic Web Blog"),a(),s(109," describes the key concepts of the GeoNames Ontology. "),a(),l(110,"li")(111,"a",16),s(112,"Overview over GeoNames Feature Codes"),a(),s(113," with number of features per code."),a(),l(114,"li")(115,"a",17),s(116,"More information on Linked Data"),a(),s(117,"."),a()()(),l(118,"section",0)(119,"h2"),s(120,"Version History"),a(),l(121,"ul",18),I(122,GF,5,4,"li",null,HF),a()()),t&2&&(d(49),g(i.rdfExample),d(73),T(i.versionHistory)
91)},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none;word-break:break-word}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]:first-of-type{border-top:none;padding-top:.5rem}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%]{font-size:.9rem;margin:1rem 0 .3rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:.4rem 0;padding-left:1.2rem;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.3rem 0}code[_ngcontent-%COMP%]{background:#f8f9fa;padding:.05rem .35rem;border-radius:3px;font-size:.85em}.rdf-example[_ngcontent-%COMP%]{background:#f8f9fa;border:1px solid #e5e5e5;border-radius:6px;padding:.75rem 1rem;font-size:.75rem;line-height:1.4;overflow-x:auto;white-space:pre}.rdf-example[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:none;padding:0;font-size:inherit}.note[_ngcontent-%COMP%]{display:block;color:#777;font-size:.82rem;margin-top:.2rem}.version-history[_ngcontent-%COMP%]{list-style:none;padding:0}.version-history[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{padding:.5rem 0;border-bottom:1px solid #f0f0f0}.version-link[_ngcontent-%COMP%]{margin-left:.5rem;font-size:.8rem}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}.rdf-example[_ngcontent-%COMP%]{font-size:.68rem}}"]})};var h1=[{code:"AT",name:"Austria",numAddresses:2395351,provider:"National Address Register"},{code:"AU",name:"Australia",numAddresses:15481386,provider:"National Address Register"},{code:"AX",name:"Aland",numAddresses:31265,provider:"National Address Register"},{code:"CC",name:"Cocos [Keeling] Islands",numAddresses:363,provider:"National Address Register"},{code:"CH",name:"Switzerland",numAddresses:3105535,provider:"National Address Register"},{code:"CL",name:"Chile",numAddresses:1850552,provider:"National Address Register"},{code:"CX",name:"Christmas Island",numAddresses:1112,provider:"National Address Register"},{code:"CZ",name:"Czechia",numAddresses:2913321,provider:"National Address Register"},{code:"DK",name:"Denmark",numAddresses:2500538,provider:"National Address Register"},{code:"EE",name:"Estonia",numAddresses:1264183,provider:"National Address Register"},{code:"ES",name:"Spain",numAddresses:11306734,provider:"National Address Register"},{code:"FI",name:"Finland",numAddresses:3488721,provider:"National Address Register"},{code:"FR",name:"France",numAddresses:23922395,provider:"National Address Register"},{code:"GF",name:"French Guiana",numAddresses:60105,provider:"National Address Register"},{code:"GP",name:"Guadeloupe",numAddresses:130680,provider:"National Address Register"},{code:"HK",name:"Hong Kong",numAddresses:178543,provider:"National Address Register"},{code:"IS",name:"Iceland",numAddresses:115659,provider:"National Address Register"},{code:"LU",name:"Luxembourg",numAddresses:166725,provider:"National Address Register"},{code:"MQ",name:"Martinique",numAddresses:100645,provider:"National Address Register"},{code:"NF",name:"Norfolk Island",numAddresses:2162,provider:"National Address Register"},{code:"NL",name:"Netherlands",numAddresses:10124592,provider:"National Address Register"}
91,{code:"NO",name:"Norway",numAddresses:2458623,provider:"National Address Register"},{code:"PL",name:"Poland",numAddresses:7688758,provider:"National Address Register"},{code:"PR",name:"Puerto Rico",numAddresses:491451,provider:"US Census, street segments"},{code:"PT",name:"Portugal",numAddresses:3478540,provider:"National Address Register"},{code:"RE",name:"Reunion",numAddresses:323387,provider:"National Address Register"},{code:"SG",name:"Singapore",numAddresses:141956,provider:"National Address Register"},{code:"SI",name:"Slovenia",numAddresses:559413,provider:"National Address Register"},{code:"SJ",name:"Svalbard and Jan Mayen",numAddresses:797,provider:"National Address Register"},{code:"SK",name:"Slovakia",numAddresses:1218439,provider:"National Address Register"},{code:"US",name:"United States",numAddresses:67371044,provider:"US Census, street segments"},{code:"YT",name:"Mayotte",numAddresses:35399,provider:"National Address Register"}];var WF=(e,n)=>n.code;function qF(e,n){e&1&&(l(0,"p",5),s(1,"No address found for that query."),a())}function JF(e,n){e&1&&(l(0,"p",5),s(1,"Could not search for that address right now."),a())}function KF(e,n){if(e&1&&(l(0,"p",6),s(1),a()),e&2){let t,i=p();d(),gt(" Found: ",(t=i.searchResult())==null?null:t.street,"",(t=i.searchResult())!=null&&t.houseNumber?" "+((t=i.searchResult())==null?null:t.houseNumber):"","",(t=i.searchResult())!=null&&t.placename?", "+((t=i.searchResult())==null?null:t.placename):""," ")}}function YF(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),a(),l(3,"td"),s(4),a(),l(5,"td"),s(6),a(),l(7,"td"),s(8),a()()),e&2){let t=n.$implicit;d(2),g(t.code),d(2),g(t.name),d(2),g(t.numAddresses.toLocaleString()),d(2),g(t.provider)}}var Bd=class e{addressService=h(Wn);title=h(H);countries=h1;latitude=E(52.358);longitude=E(4.881);zoom=E(14);searchQuery="";searchState=E("idle");searchResult=E(null);constructor(){this.title.setTitle("GeoNames Addresses GeoCoding and Reverse GeoCoding \u2014 GeoNames UI")}onSearchSubmit(n){n.preventDefault();let t=this.searchQuery.trim();t&&(this.searchState.set("loading"),this.addressService.geocode(t).subscribe({next:i=>{this.searchResult.set(i),i?.lat&&i?.lng?(this.latitude.set(Number(i.lat)),this.longitude.set(Number(i.lng)),this.zoom.set(16),this.searchState.set("loaded")):this.searchState.set("not-found")},error:()=>this.searchState.set("error")}))}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-addresses-map-page"]],decls:133,vars:12,consts:[[1,"page-header"],[1,"page-intro"],[1,"search-form",3,"submit"],["type","text","name","q","placeholder","Museumplein 6, Amsterdam","aria-label","Search for an address",3,"ngModelChange","ngModel"],["type","submit"],[1,"form-error"],[1,"form-success"],["label","Address lookup",3,"latitude","longitude","zoom","showCenterMarker","allowCreate","allowMove","hideFeatureMarkers","addressLookupEnabled","addressResult","tall"],[1,"ws-section"],["id","address"],[1,"meta"],[1,"note"],["id","geoCodeAddress"],["id","streetNameLookup"],["id","countries"],[1,"table-scroll"],[1,"param-table"]],template:function(t,i){t&1&&(l(0,"header",0)(1,"h1"),s(2,"Addresses GeoCoding and Reverse GeoCoding"),a(),l(3,"p",1),s(4,"Click on the map to reverse-geocode a street address, or search for one below."),a()(),l(5,"form",2),M("submit",function(r){return i.onSearchSubmit(r)}),l(6,"input",3),F("ngModelChange",function(r){return L(i.searchQuery,r)||(i.searchQuery=r),r}),a(),l(7,"button",4),s(8,"Search"),a()(),y(9,qF,2,0,"p",5)(10,JF,2,0,"p",5)(11,KF,2,3,"p",6),j(12,"app-geo-map",7),l(13,"section",8)(14,"h2"),s(15,"Reverse Address Geocoding Webservice"),a(),l(16,"h3",9),s(17,"Find nearest Address"),a(),l(18,"p"),s(19,"Finds the nearest street and address for a given lat/lng pair."),a(),l(20,"dl",10)(21,"dt"),s(22,"Url"),a(),l(23,"dd")(24,"code"),s(25,"api.geonames.org/address?"),a()(),l(26,"dt"),s(27,"Parameters"),a(),l(28,"dd"),s(29,"lat, lng; radius in m (default=100); maxRows (default=1)"),a(),l(30,"dt"),s(31,"Restriction"),a(),l(32,"dd"),s(33,"this webservice is only available for selected countries, see list below."),a(),l(34,"dt"),s(35,"Result"),a(),l(36,"dd"),s(37,"returns the nearest address for the given latitude/longitude."),a(),l(38,"dt"),s(39,"Example"),a(),l(40,"dd")(41,"code"),s(42,"http://api.geonames.org/address?lat=52.358&lng=4.881&username=demo"),a()()(),l(43,"p",11),s(44," Also available in JSON format: "),l(45,"code"),s(46,"http://api.geonames.org/addressJSON?lat=52.358&lng=4.881&username=demo"),a()()(),l(47,"section",8)(48,"h2"),s(49,"Address Geocoding Webservice"),a(),l(50,"h3",12),s(51,"Find lat/lng for Address"),a(),l(52,"p"),s(53,"Returns the location lat/lng for a given address."),a(),l(54,"dl",10)(55,"dt"),s(56,"Url"),a(),l(57,"dd")(58,"code"),s(59,"api.geonames.org/geoCodeAddress?"),a()(),l(60,"dt"),s(61,"Parameters"),a(),l(62,"dd"),s(63,"q (query term, url encoded)"),a(),l(64,"dt"),s(65,"Optional parameters"),a(),l(66,"dd"),s(67,"country (iso countrycode), postalcode"),a(),l(68,"dt"),s(69,"Restriction"),a(),l(70,"dd"),s(71,"this webservice is only available for selected countries, see list below."),a(),l(72,"dt"),s(73,"Example"),a(),l(74,"dd")(75,"code"),s(76,"http://api.geonames.org/geoCodeAddress?q=Museumplein+6+amsterdam&username=demo"),a()()(),l(77,"p",11),s(78," Also available in JSON format: "),l(79,"code"),s(80,"http://api.geonames.org/geoCodeAddressJSON?q=Museumplein+6+amsterdam&username=demo"),a()()(),l(81,"section",8)(82,"h2"),s(83,"Streetname Lookup Webservice"),a(),l(84,"h3",13),s(85,"Autocomplete Streetnames"),a(),l(86,"p"),s(87,"Returns a list of streets which start with the search term."),a(),l(88,"dl",10)(89,"dt"),s(90,"Url"),a(),l(91,"dd")(92,"code"),s(93,"api.geonames.org/street
91NameLookup?"),a()(),l(94,"dt"),s(95,"Parameters"),a(),l(96,"dd"),s(97,"q (query term, url encoded)"),a(),l(98,"dt"),s(99,"Optional parameters"),a(),l(100,"dd"),s(101,"country (iso countrycode), postalcode, adminCode1, adminCode2, adminCode3, isUniqueStreetName (duplicate street names are filtered, the placename will be empty when the same street name occurs at different places)"),a(),l(102,"dt"),s(103,"Restriction"),a(),l(104,"dd"),s(105,"this webservice is only available for selected countries, see list below."),a(),l(106,"dt"),s(107,"Example"),a(),l(108,"dd")(109,"code"),s(110,"http://api.geonames.org/streetNameLookup?q=Museum&username=demo"),a()()(),l(111,"p",11),s(112," Also available in JSON format: "),l(113,"code"),s(114,"http://api.geonames.org/streetNameLookupJSON?q=Museum&username=demo"),a()()(),l(115,"section",8)(116,"h2",14),s(117,"Supported Countries"),a(),l(118,"div",15)(119,"table",16)(120,"thead")(121,"tr")(122,"th"),s(123,"CC"),a(),l(124,"th"),s(125,"Country"),a(),l(126,"th"),s(127,"num Addr/Streets"),a(),l(128,"th"),s(129,"Data Providers"),a()()(),l(130,"tbody"),I(131,YF,9,4,"tr",null,WF),a()()()()),t&2&&(d(6),R("ngModel",i.searchQuery),d(3),_(i.searchState()==="not-found"?9:i.searchState()==="error"?10:i.searchState()==="loaded"&&i.searchResult()?11:-1),d(3),v("latitude",i.latitude())("longitude",i.longitude())("zoom",i.zoom())("showCenterMarker",!1)("allowCreate",!1)("allowMove",!1)("hideFeatureMarkers",!0)("addressLookupEnabled",!0)("addressResult",i.searchResult())("tall",!0),d(119),T(i.countries))},dependencies:[ke,pt,Me,Ne,mt,De,dt,nt],styles:[".page-header[_ngcontent-%COMP%]{margin:0 0 1rem}.page-header[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.page-intro[_ngcontent-%COMP%]{margin:0;color:#666;font-size:.92rem}.search-form[_ngcontent-%COMP%]{display:flex;gap:.5rem;margin:1rem 0;max-width:30rem}.search-form[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{flex:1;border:1px solid #d8d8d8;border-radius:4px;padding:.4rem .6rem;font-size:.9rem}.search-form[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.4rem .9rem;font-size:.9rem;cursor:pointer}.form-error[_ngcontent-%COMP%]{color:#b3261e;font-size:.85rem;margin:.3rem 0 1rem}.form-success[_ngcontent-%COMP%]{color:#2e7d32;font-size:.85rem;margin:.3rem 0 1rem}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee;margin-top:1rem}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%]{font-size:.85rem;text-transform:uppercase;letter-spacing:.03em;color:#777;margin:.5rem 0 .3rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.meta[_ngcontent-%COMP%]{margin:.5rem 0;font-size:.85rem}.meta[_ngcontent-%COMP%]   dt[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;color:#777;margin-top:.4rem}.meta[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]{margin:.1rem 0 0}.meta[_ngcontent-%COMP%]   code[_ngcontent-%COMP%], .note[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:#f8f9fa;padding:.05rem .35rem;border-radius:3px;font-size:.85em;word-break:break-all}.note[_ngcontent-%COMP%]{color:#777;font-size:.82rem}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto}.param-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.param-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .param-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .6rem;border-bottom:1px solid #eee;text-align:left;white-space:nowrap}.param-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555}.param-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.param-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}"]}
91)};var Hd=class e{title=h(H);constructor(){this.title.setTitle("GeoNames Services \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-services"]],decls:60,vars:0,consts:[[1,"lead"],[1,"ws-section"],["routerLink","/products/premium-data.html"],["routerLink","/commercial-webservices.html","fragment","A"],["routerLink","/commercial-webservices.html","fragment","B"],["routerLink","/products/reverse-geocoding-usa.html"],[1,"note"],["href","mailto:[email protected]"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"GeoNames Services"),a(),l(2,"p",0),s(3,` GeoNames data is available under a liberal creative commons attributions licence. For professional users and mission critical applications the GeoNames team is offering commercial services. The revenues generated with the commercial services help to keep the data free and guarantee the continuance and future maintenance of the project.
92`),a(),l(4,"section",1)(5,"h2"),s(6,"Premium Data Subscription"),a(),l(7,"p"),s(8," The "),l(9,"a",2),s(10,"GeoNames Premium Data Subscription"),a(),s(11," is the professional variant of the GeoNames data dump. It has passed a huge number of consistency checks before it is released once per month. "),a()(),l(12,"section",1)(13,"h2"),s(14,"Commercial Web Services"),a(),l(15,"p"),s(16," While the GeoNames free web services are fantastic for prototyping and small applications we recommend the usage of the commercial web services for professional users. The commercial services offer even faster response time and higher availability. They also come with a service level agreement and a guarantee for continuity. "),a(),l(17,"p"),s(18,"The commercial services come in two different plans:"),a(),l(19,"ul")(20,"li")(21,"a",3),s(22,"Best Availability"),a(),s(23,": Focus on high availability. "),a(),l(24,"li")(25,"a",4),s(26,"Best Price"),a(),s(27,": Focus on best price services ratio."),a()()(),l(28,"section",1)(29,"h2"),s(30,"Consulting"),a(),l(31,"p"),s(32,"We have got a lot of experience working with geographical data and you can leverage our expertise for your project."),a(),l(33,"ul")(34,"li")(35,"strong"),s(36,"Data:"),a(),s(37," We can help you find the best data for your application. What kind of data is available for your project? Free vs Commercial data. Quality, accuracy and coverage of datasets. Pros and cons of Point data and Vector/Polygon data. "),a(),l(38,"li")(39,"strong"),s(40,"Application Development:"),a(),s(41," We are available for consulting and contracting for application development in various environments. Namely but not only in: java, postgres/postgis, geospatial databases, javascript, php. "),a()()(),l(42,"section",1)(43,"h2"),s(44,"Products"),a(),l(45,"p"),s(46,"Run GeoNames services on your own server."),a(),l(47,"p"),s(48," We offer a reverse geocoding service on street level. Do you need to know the address or street name for a gps signal? For the US we offer an inexpensive but reliable solution based on US Census street data. "),a(),l(49,"ul")(50,"li")(51,"a",5),s(52,"Reverse geocoding for the US"),a(),s(53,", inexpensive (based on US Census data). "),a()()(),l(54,"section",1)(55,"p",6),s(56,"Contact "),l(57,"a",7),s(58,"[email protected]"),a(),s(59," for further information."),a()())},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem}a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:.4rem 0;padding-left:1.2rem;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.3rem 0}.note[_ngcontent-%COMP%]{color:#777;font-size:.82rem}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};function ZF(e,n){e&1&&(l(0,"p",5),s(1,"No address found for that query."),a())}function QF(e,n){e&1&&(l(0,"p",5),s(1,"Could not search for that address right now."),a())}function XF(e,n){if(e&1&&(l(0,"p",6),s(1),a()),e&2){let t,i=p();d(),gt(" Found: ",(t=i.searchResult())==null?null:t.street,"",(t=i.searchResult())!=null&&t.houseNumber?" "+((t=i.searchResult())==null?null:t.houseNumber):"","",(t=i.searchResult())!=null&&t.placename?", "+((t=i.searchResult())==null?null:t.placename):""," ")}}var Qa=class e{addressService=h(Wn);title=h(H);latitude=E(37.451);longitude=E(-122.18);zoom=E(15);searchQuery="";searchState=E("idle");searchResult=E(null);constructor(){this.title.setTitle("GeoNames US Reverse Geocoder \u2014 GeoNames UI")}onSearchSubmit(n){n.preventDefault();let t=this.searchQuery.trim();t&&(this.searchState.set("loading"),this.addressService.geocode(t).subscribe({next:i=>{this.searchResult.set(i),i?.lat&&i?.lng?(this.latitude.set(Number(i.lat)),this.longitude.set(Number(i.lng)),this.zoom.set(16),this.searchState.set("loaded")):this.searchState.set("not-found")},error:()=>this.searchState.set("error")}))}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-us-reverse-geocoder-page"]],decls:160,vars:13,consts:[[1,"page-header"],[1,"page-intro"],[1,"search-form",3,"submit"],["type","text","name","q","placeholder","775 cherry lane, lansing","aria-label","Search for an address",3,"ngModelChange","ngModel"],["type","submit"],[1,"form-error"],[1,"form-success"],["label","US reverse geocoder",3,"latitude","longitude","zoom","showCenterMarker","allowCreate","allowMove","hideFeatureMarkers","addressLookupEnabled","useUsReverseGeocoder","addressResult","tall"],[1,"map-attribution"],["href","https://legal.here.com/en/terms/serviceterms/us","target","_blank","rel","noopener noreferrer"],[1,"ws-section"],["id","findNearestAddress"],[1,"meta"],[1,"n
92ote"],["id","findNearestIntersection"],["id","findNearbyStreets"],["href","https://www.geonames.org/maps/mtfcc.pdf","target","_blank","rel","noopener noreferrer"],["routerLink","/products/reverse-geocoding-usa.html"],["routerLink","/maps/osm-reverse-geocoder.html"],["routerLink","/export/reverse-geocoding.html"]],template:function(t,i){t&1&&(l(0,"header",0)(1,"h1"),s(2,"US Reverse Geocoder"),a(),l(3,"p",1),s(4,' Click on the map to view the reverse-geocoded street address, or search for one below. Reverse geocoding is provided using the US Census "TIGER Line" data set; forward geocoding uses the general GeoNames geocoder. '),a()(),l(5,"form",2),M("submit",function(r){return i.onSearchSubmit(r)}),l(6,"input",3),F("ngModelChange",function(r){return L(i.searchQuery,r)||(i.searchQuery=r),r}),a(),l(7,"button",4),s(8,"geocode"),a()(),y(9,ZF,2,0,"p",5)(10,QF,2,0,"p",5)(11,XF,2,3,"p",6),j(12,"app-geo-map",7),l(13,"p",8),s(14,"\xA9 1987\u20132026 HERE | "),l(15,"a",9),s(16,"Terms of use"),a()(),l(17,"section",10)(18,"h2"),s(19,"Reverse Geocoding Webservice"),a(),l(20,"h3",11),s(21,"Find nearest Address"),a(),l(22,"p"),s(23,"Finds the nearest street and address for a given lat/lng pair."),a(),l(24,"dl",12)(25,"dt"),s(26,"Url"),a(),l(27,"dd")(28,"code"),s(29,"api.geonames.org/findNearestAddress?"),a()(),l(30,"dt"),s(31,"Parameters"),a(),l(32,"dd"),s(33,"lat, lng (or optionally lats, lngs for an array of lat/lng pairs); radius in km (default=0.2); maxRows (default=1)"),a(),l(34,"dt"),s(35,"Restriction"),a(),l(36,"dd"),s(37,"this webservice is only available for the US."),a(),l(38,"dt"),s(39,"Result"),a(),l(40,"dd"),s(41,' returns the nearest address for the given latitude/longitude; the street number is an "educated guess" using an interpolation of street numbers at the end of a street segment. '),a(),l(42,"dt"),s(43,"Example"),a(),l(44,"dd")(45,"code"),s(46,"http://api.geonames.org/findNearestAddress?lat=37.451&lng=-122.18&username=demo"),a()()(),l(47,"p",13),s(48," Also available in JSON format: "),l(49,"code"),s(50,"http://api.geonames.org/findNearestAddressJSON?lat=37.451&lng=-122.18&username=demo"),a()()(),l(51,"section",10)(52,"h3",14),s(53,"Find nearest Intersection"),a(),l(54,"p"),s(55,"Finds the nearest intersection for a given lat/lng pair."),a(),l(56,"dl",12)(57,"dt"),s(58,"Url"),a(),l(59,"dd")(60,"code"),s(61,"api.geonames.org/findNearestIntersection?"),a()(),l(62,"dt"),s(63,"Parameters"),a(),l(64,"dd"),s(65,"lat, lng; optional: maxRows (number of rows returned), radius (km), filter (only return intersections with streets of a mtfcc equal or higher than the filter)"),a(),l(66,"dt"),s(67,"Restriction"),a(),l(68,"dd"),s(69,"this webservice is only available for the US."),a(),l(70,"dt"),s(71,"Result"),a(),l(72,"dd"),s(73,"returns the nearest intersection for the given latitude/longitude."),a(),l(74,"dt"),s(75,"Example"),a(),l(76,"dd")(77,"code"),s(78,"http://api.geonames.org/findNearestIntersection?lat=37.451&lng=-122.18&username=demo"),a()()(),l(79,"p",13),s(80," Also available in JSON format: "),l(81,"code"),s(82,"http://api.geonames.org/findNearestIntersectionJSON?lat=37.451&lng=-122.18&username=demo"),a()()(),l(83,"section",10)(84,"h3",15),s(85,"Find nearby Streets"),a(),l(86,"p"),s(87,"Finds the nearest street for a given lat/lng pair."),a(),l(88,"dl",12)(89,"dt"),s(90,"Url"),a(),l(91,"dd")(92,"code"),s(93,"api.geonames.org/findNearbyStreets?"),a()(),l(94,"dt"),s(95,"Parameters"),a(),l(96,"dd"),s(97,"lat, lng; optional: maxRows (number of rows returned), radius (km)"),a(),l(98,"dt"),s(99,"Restriction"),a(),l(100,"dd"),s(101,"this webservice is only available for the US."),a(),l(102,"dt"),s(103,"Result"),a(),l(104,"dd"),s(105,"returns the nearest street segments for the given latitude/longitude."),a(),l(106,"dt"),s(107,"Example"),a(),l(108,"dd")(109,"code"),s(110,"http://api.geonames.org/findNearbyStreets?lat=37.451&lng=-122.18&username=demo"),a()()(),l(111,"p",13),s(112," Also available in JSON format: "),l(113,"code"),s(114,"http://api.geonames.org/findNearbyStreetsJSON?lat=37.451&lng=-122.18&username=demo"),a()(),l(115,"p",13),s(116," Returned elements: "),l(117,"code"),s(118,"line"),a(),s(119," (line string of comma-separated lng/lat points), "),l(120,"code"),s(121,"mtfcc"),a(),s(122," ("),l(123,"a",16),s(124,"MAF/TIGER Feature Class Code"),a(),s(125,"), "),l(126,"code"),s(127,"name"),a(),s(128," (street name), "),l(129,"code"),s(130,"fraddl"),a(),s(131,"/"),l(132,"code"),s(133,"fraddr"),a(),s(134," (from address left/right), "),l(135,"code"),s(136,"toaddl"),a(),s(137,"/"),l(138,"code"),s(139,"toaddr"),a(),s(140," (to address left/right). "),a()(),l(141,"section",10)(142,"h2"),s(143,"Install Rever
92se Geocoding on your own Server"),a(),l(144,"p"),s(145," We can help you "),l(146,"a",17),s(147,"install reverse geocoding on your own server"),a(),s(148,". "),a()(),l(149,"section",10)(150,"h2"),s(151,"Other Reverse Geocoding Services"),a(),l(152,"p"),s(153," A "),l(154,"a",18),s(155,"global street level reverse geocoder"),a(),s(156," is available based on OpenStreetMap data. Compared to the US geocoder it is less detailed and uses a more restrictive CC BY-SA license. "),a(),l(157,"p")(158,"a",19),s(159,"More reverse geocoding webservices"),a()()()),t&2&&(d(6),R("ngModel",i.searchQuery),d(3),_(i.searchState()==="not-found"?9:i.searchState()==="error"?10:i.searchState()==="loaded"&&i.searchResult()?11:-1),d(3),v("latitude",i.latitude())("longitude",i.longitude())("zoom",i.zoom())("showCenterMarker",!1)("allowCreate",!1)("allowMove",!1)("hideFeatureMarkers",!0)("addressLookupEnabled",!0)("useUsReverseGeocoder",!0)("addressResult",i.searchResult())("tall",!0))},dependencies:[ke,pt,Me,Ne,mt,De,dt,nt,W],styles:[".page-header[_ngcontent-%COMP%]{margin:0 0 1rem}.page-header[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.page-intro[_ngcontent-%COMP%]{margin:0;color:#666;font-size:.92rem}.search-form[_ngcontent-%COMP%]{display:flex;gap:.5rem;margin:1rem 0;max-width:30rem}.search-form[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{flex:1;border:1px solid #d8d8d8;border-radius:4px;padding:.4rem .6rem;font-size:.9rem}.search-form[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.4rem .9rem;font-size:.9rem;cursor:pointer}.form-error[_ngcontent-%COMP%]{color:#b3261e;font-size:.85rem;margin:.3rem 0 1rem}.form-success[_ngcontent-%COMP%]{color:#2e7d32;font-size:.85rem;margin:.3rem 0 1rem}.map-attribution[_ngcontent-%COMP%]{margin:.3rem 0 0;color:#999;font-size:.75rem}.map-attribution[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:inherit}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee;margin-top:1rem}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%]{font-size:.85rem;text-transform:uppercase;letter-spacing:.03em;color:#777;margin:.5rem 0 .3rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.meta[_ngcontent-%COMP%]{margin:.5rem 0;font-size:.85rem}.meta[_ngcontent-%COMP%]   dt[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;color:#777;margin-top:.4rem}.meta[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]{margin:.1rem 0 0}.meta[_ngcontent-%COMP%]   code[_ngcontent-%COMP%], .note[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:#f8f9fa;padding:.05rem .35rem;border-radius:3px;font-size:.85em;word-break:break-all}.note[_ngcontent-%COMP%]{color:#777;font-size:.82rem}"]})};var Mr=class e{http=h(Z);countries$=this.http.get("/api/statistics/countries").pipe(N(n=>n.filter(t=>t.countryName!==t.countryCode)),Xn(1));getCountries(){return this.countries$}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var eL=(e,n)=>n.countryCode;function tL(e,n){e&1&&(l(0,"p",0),s(1,"Loading statistics\u2026"),a())}function nL(e,n){e&1&&(l(0,"p",1),s(1,"Could not load country statistics right now."),a())}function iL(e,n){if(e&1&&(l(0,"span",6),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function oL(e,n){if(e&1&&(l(0,"span",6),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function rL(e,n){if(e&1&&(l(0,"span",6),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function aL(e,n){if(e&1&&(l(0,"span",6),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function sL(e,n){if(e&1&&(l(0,"span",6),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function lL(e,n){if(e&1&&(l(0,"span",6),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function cL(e,n){if(e&1&&(l(0,"span",6),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function dL(e,n){if(e&1&&(l(0,"tr")(1,"td",4),s(2),a(),l(3,"td"),s(4),a(),l(5,"td")(6,"a",9),s(7),a()(),l(8,"td"),s(9),a(),l(10,"td"),s(11),Be(12,"number"),a(),l(13,"td"),s(14),Be(15,"number"),a(),l(16,"td"),s(17),a(),l(18,"td"),s(19),Be(20,"number"),a()()),e&2){let t=n.$implicit,i=n.$index,o=p(2);
92d(2),g(i+1),d(2),g(t.placeCount.toLocaleString()),d(2),v("routerLink",o.slugFor(t.countryName)),d(),g(t.countryName),d(2),g(t.countryCode),d(2),g(t.areaSqKm!=null?He(12,9,t.areaSqKm,"1.1-1"):""),d(3),g(t.namesPerSqKm!=null?He(15,12,t.namesPerSqKm,"1.3-3"):""),d(3),g(t.population!=null?t.population.toLocaleString():""),d(2),g(t.namesPer1000Inhabitants!=null?He(20,15,t.namesPer1000Inhabitants,"1.3-3"):"")}}function uL(e,n){if(e&1){let t=$();l(0,"div",2)(1,"table",3)(2,"thead")(3,"tr")(4,"th",4),s(5,"#"),a(),l(6,"th")(7,"button",5),M("click",function(){S(t);let o=p();return w(o.sortBy("placeCount"))}),s(8," Names "),y(9,iL,2,1,"span",6),a()(),l(10,"th")(11,"button",5),M("click",function(){S(t);let o=p();return w(o.sortBy("countryName"))}),s(12," Country "),y(13,oL,2,1,"span",6),a()(),l(14,"th")(15,"button",5),M("click",function(){S(t);let o=p();return w(o.sortBy("countryCode"))}),s(16," Country Code "),y(17,rL,2,1,"span",6),a()(),l(18,"th")(19,"button",5),M("click",function(){S(t);let o=p();return w(o.sortBy("areaSqKm"))}),s(20," Area in km\xB2 "),y(21,aL,2,1,"span",6),a()(),l(22,"th")(23,"button",5),M("click",function(){S(t);let o=p();return w(o.sortBy("namesPerSqKm"))}),s(24," Names per km\xB2 "),y(25,sL,2,1,"span",6),a()(),l(26,"th")(27,"button",5),M("click",function(){S(t);let o=p();return w(o.sortBy("population"))}),s(28," Population "),y(29,lL,2,1,"span",6),a()(),l(30,"th")(31,"button",5),M("click",function(){S(t);let o=p();return w(o.sortBy("namesPer1000Inhabitants"))}),s(32," Names per 1000 Inhabitants "),y(33,cL,2,1,"span",6),a()()()(),l(34,"tbody"),I(35,dL,21,18,"tr",null,eL),a(),l(37,"tfoot")(38,"tr",7),j(39,"td"),l(40,"td"),s(41),a(),l(42,"td")(43,"a",8),s(44,"Total"),a()(),j(45,"td"),l(46,"td"),s(47),Be(48,"number"),a(),l(49,"td"),s(50),Be(51,"number"),a(),l(52,"td"),s(53),a(),l(54,"td"),s(55),Be(56,"number"),a()()()()()}if(e&2){let t=p();d(9),_(t.sortColumn()==="placeCount"?9:-1),d(4),_(t.sortColumn()==="countryName"?13:-1),d(4),_(t.sortColumn()==="countryCode"?17:-1),d(4),_(t.sortColumn()==="areaSqKm"?21:-1),d(4),_(t.sortColumn()==="namesPerSqKm"?25:-1),d(4),_(t.sortColumn()==="population"?29:-1),d(4),_(t.sortColumn()==="namesPer1000Inhabitants"?33:-1),d(2),T(t.sortedCountries()),d(6),g(t.totalPlaceCount().toLocaleString()),d(6),g(He(48,12,t.totalAreaSqKm(),"1.1-1")),d(3),g(t.totalNamesPerSqKm()!=null?He(51,15,t.totalNamesPerSqKm(),"1.3-3"):""),d(3),g(t.totalPopulation().toLocaleString()),d(2),g(t.totalNamesPer1000Inhabitants()!=null?He(56,18,t.totalNamesPer1000Inhabitants(),"1.3-3"):"")}}var $d=class e{countryStatistics=h(Mr);title=h(H);state=E("loading");countries=E([]);sortColumn=E("placeCount");sortDescending=E(!0);totalPlaceCount=G(()=>this.countries().reduce((n,t)=>n+t.placeCount,0));totalAreaSqKm=G(()=>this.countries().reduce((n,t)=>n+(t.areaSqKm??0),0));totalPopulation=G(()=>this.countries().reduce((n,t)=>n+(t.population??0),0));totalNamesPerSqKm=G(()=>{let n=this.totalAreaSqKm();return n>0?this.totalPlaceCount()/n:null});totalNamesPer1000Inhabitants=G(()=>{let n=this.totalPopulation();return n>0?this.totalPlaceCount()*1e3/n:null});sortedCountries=G(()=>{let n=this.sortColumn(),t=this.sortDescending()?-1:1;return[...this.countries()].sort((i,o)=>{let r=i[n],c=o[n];return r==null&&c==null?0:r==null?1:c==null?-1:typeof r=="string"||typeof c=="string"?t*String(r).localeCompare(String(c)):t*(r>c?1:r<c?-1:0)})});constructor(){this.title.setTitle("GeoNames Country Statistic \u2014 GeoNames UI"),this.countryStatistics.getCountries().subscribe({next:n=>{this.countries.set(n),this.state.set("loaded")},error:()=>this.state.set("error")})}slugFor(n){return`/statistics/${We(n)}.html`}sortBy(n){this.sortColumn()===n?this.sortDescending.update(t=>!t):(this.sortColumn.set(n),this.sortDescending.set(n!=="countryName"&&n!=="countryCode"))}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-country-statistics-page"]],decls:5,vars:1,consts:[[1,"placeholder"],[1,"not-found"],[1,"table-scroll"],[1,"stats-table"],[1,"rank-col"],["type","button",3,"click"],[1,"sort-arrow"],[1,"total-row"],["routerLink","/statistics/total.html"],[3,"routerLink"]],template:function(t,i){if(t&1&&(l(0,"h1"),s(1,"GeoNames Country Statistic"),a(),y(2,tL,2,0,"p",0)(3,nL,2,0,"p",1)(4,uL,57,21,"div",2)),t&2){let o;d(2),_((o=i.state())==="loading"?2:o==="error"?3:o==="loaded"?4:-1)}},dependencies:[W,$f],styles:["[_nghost-%COMP%]{display:block;max-width:900px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.6rem}.placeholder[_ngcontent-%COMP%], .not-found[_ngcontent-%COMP%]{color:#7
9277;font-size:.9rem}.table-scroll[_ngcontent-%COMP%]{position:relative;max-height:70vh;overflow:auto;scrollbar-width:thin}.stats-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem;font-variant-numeric:tabular-nums}.stats-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .stats-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .6rem;border-bottom:1px solid #eee;text-align:right;white-space:nowrap}.stats-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:nth-child(3), .stats-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:nth-child(3), .stats-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:nth-child(4), .stats-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:nth-child(4){text-align:left}.stats-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{position:sticky;top:0;background:#fff;border-bottom:2px solid #ddd;color:#555}.stats-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n):not(.total-row){background:#fafbfc}.stats-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover:not(.total-row){background:#eef2f7}.stats-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:none;background:none;font:inherit;color:inherit;cursor:pointer;padding:0}.sort-arrow[_ngcontent-%COMP%]{font-size:.7em;margin-left:.15rem}.rank-col[_ngcontent-%COMP%]{color:#999}.stats-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.stats-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.total-row[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{font-weight:600;border-top:2px solid #ddd;border-bottom:none}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var zd=class e{http=h(Z);getTotal(){return this.http.get("/api/statistics/features/total").pipe(N(g1))}getByCountry(n){let t=new URLSearchParams({country:n});return this.http.get(`/api/statistics/features?${t.toString()}`).pipe(N(g1))}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};function g1(e){return e.map(n=>{let t=n.codes.find(i=>i.featureCode==="PCLH");return t?oe(U({},n),{totalCount:n.totalCount-t.count,codes:n.codes.filter(i=>i.featureCode!=="PCLH")}):n})}var mL=(e,n)=>n.featureClass,pL=(e,n)=>n.featureCode;function fL(e,n){if(e&1&&(l(0,"nav",3)(1,"a",4),s(2,"Countries"),a(),s(3," \xBB "),l(4,"span",5),s(5),a(),s(6," \xBB "),a(),l(7,"h1"),s(8),a()),e&2){let t=n;d(5),g(t),d(3),A("Feature Statistic ",t,"")}}function hL(e,n){e&1&&(l(0,"h1"),s(1,"Feature Statistic"),a())}function gL(e,n){e&1&&(l(0,"p",0),s(1,"Loading statistics\u2026"),a())}function CL(e,n){e&1&&(l(0,"p",1),s(1,"No statistics found for that country."),a())}function _L(e,n){e&1&&(l(0,"p",1),s(1,"Could not load feature statistics right now."),a())}function vL(e,n){if(e&1&&(l(0,"span",8),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function yL(e,n){if(e&1&&(l(0,"span",8),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function bL(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),a(),l(3,"td"),s(4),a(),l(5,"td"),s(6),a(),l(7,"td"),s(8),a()()),e&2){let t=n.$implicit,i=p().$implicit;d(2),g(t.count.toLocaleString()),d(2),le("",i.featureClass,".",t.featureCode,""),d(2),g(t.name),d(2),g(t.description)}}function xL(e,n){if(e&1&&(l(0,"tr",9)(1,"td",10),s(2),a()(),I(3,bL,9,5,"tr",null,pL),l(5,"tr",11)(6,"td"),s(7),a(),l(8,"td",12),s(9),a()()),e&2){let t=n.$implicit;d(2),g(t.groupLabel),d(),T(t.codes),d(4),g(t.totalCount.toLocaleString()),d(2),A("Total for ",t.featureClass,"")}}function SL(e,n){if(e&1){let t=$();l(0,"div",2)(1,"table",6)(2,"thead")(3,"tr")(4,"th")(5,"button",7),M("click",function(){S(t);let o=p();return w(o.sortBy("count"))}),s(6," Num. Names "),y(7,vL,2,1,"span",8),a()(),l(8,"th")(9,"button",7),M("click",function(){S(t);let o=p();return w(o.sortBy("featureCode"))}),s(10," Feature Code "),y(11,yL,2,1,"span",8),a()(),l(12,"th"),s(13,"Name"),a(),l(14,"th"),s(15,"Feature Description"),a()()(),l(16,"tbody"),I(17,xL,10,3,null,null,mL),a()()()}if(e&2){let t=p();d(7),_(t.sortColumn()==="count"?7:-1),d(4),_(t.sortColumn()==="featureCode"?11:-1),d(6),T(t.sortedGroups())}}var Xa=class e{route=h(ve);featureStatistics=h(zd);countryStatistics=h(Mr);title=h(H);state=E("loading");groups=E([]);countryName=E(null);sortColumn=E("count");sortDescending=E(!0);sortedGroups=G(()=>
92{let n=this.sortColumn(),t=this.sortDescending()?-1:1;return this.groups().map(i=>oe(U({},i),{codes:[...i.codes].sort((o,r)=>n==="count"?t*(o.count-r.count):t*o.featureCode.localeCompare(r.featureCode))}))});constructor(){let t=this.route.snapshot.paramMap.get("slug")?.replace(/\.html$/,"")??null;if(!t){this.title.setTitle("GeoNames Feature Statistic \u2014 GeoNames UI"),this.featureStatistics.getTotal().subscribe({next:i=>{this.groups.set(i),this.state.set("loaded")},error:()=>this.state.set("error")});return}this.countryStatistics.getCountries().pipe(be(i=>{let o=i.find(r=>We(r.countryName)===t);return o?(this.countryName.set(o.countryName),this.title.setTitle(`GeoNames Feature Statistic ${o.countryName} \u2014 GeoNames UI`),this.featureStatistics.getByCountry(o.countryCode)):Q(null)}),Ze(()=>Q(null))).subscribe(i=>{if(i===null){this.state.set(this.countryName()?"error":"not-found");return}this.groups.set(i),this.state.set("loaded")})}sortBy(n){this.sortColumn()===n?this.sortDescending.update(t=>!t):(this.sortColumn.set(n),this.sortDescending.set(n==="count"))}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-feature-statistics-page"]],decls:6,vars:2,consts:[[1,"placeholder"],[1,"not-found"],[1,"table-scroll"],[1,"breadcrumb"],["routerLink","/statistics"],[1,"current"],[1,"stats-table"],["type","button",3,"click"],[1,"sort-arrow"],[1,"group-row"],["colspan","4"],[1,"total-row"],["colspan","3"]],template:function(t,i){if(t&1&&y(0,fL,9,2)(1,hL,2,0,"h1")(2,gL,2,0,"p",0)(3,CL,2,0,"p",1)(4,_L,2,0,"p",1)(5,SL,19,2,"div",2),t&2){let o,r;_((o=i.countryName())?0:1,o),d(2),_((r=i.state())==="loading"?2:r==="not-found"?3:r==="error"?4:r==="loaded"?5:-1)}},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:900px;margin:0 auto;padding:1rem}.breadcrumb[_ngcontent-%COMP%]{font-size:.85rem;color:#777;margin-bottom:.4rem}.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.breadcrumb[_ngcontent-%COMP%]   .current[_ngcontent-%COMP%]{color:#333}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.6rem}.placeholder[_ngcontent-%COMP%], .not-found[_ngcontent-%COMP%]{color:#777;font-size:.9rem}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto}.stats-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.stats-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .stats-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.3rem .6rem;border-bottom:1px solid #eee;text-align:left}.stats-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:first-child, .stats-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:first-child{text-align:right;font-variant-numeric:tabular-nums;white-space:nowrap}.stats-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555}.stats-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n):not(.group-row):not(.total-row){background:#fafbfc}.stats-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover:not(.group-row):not(.total-row){background:#eef2f7}.stats-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:none;background:none;font:inherit;color:inherit;cursor:pointer;padding:0}.sort-arrow[_ngcontent-%COMP%]{font-size:.7em;margin-left:.15rem}.group-row[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{font-weight:600;background:#f8f9fa;border-bottom:1px solid #e5e5e5}.total-row[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{font-weight:600;border-bottom:2px solid #ddd}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var wL=(e,n)=>n.isoCode;function EL(e,n){e&1&&(l(0,"p",0),s(1,"Loading countries\u2026"),a())}function ML(e,n){e&1&&(l(0,"p",1),s(1,"Could not load country codes right now."),a())}function PL(e,n){if(e&1&&(l(0,"span",5),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function DL(e,n){if(e&1&&(l(0,"span",5),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function IL(e,n){if(e&1&&(l(0,"span",5),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function TL(e,n){if(e&1&&(l(0,"span",5),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function OL(e,n){if(e&1&&(l(0,"span",5),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function NL(e,n){if(e&1&&(l(0,"span",5),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function kL(e,n){if(e&1&&(l(0,"span",5),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function AL(e,n){if(e&1&&(l(0,"span",5),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function RL(e,n){if(e&1&&(l(0,"span",5),s(1),a()),e&2){let t=p(2);d(),g(t.sortDescending()?"\u25BC":"\u25B2")}}function FL(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),a(),l(3,"td"),s(4),a(),l(5,"td"),s(6),a(),l(7,"td"),s(8),a(),l(9,"td")(10,"a",6),s(11),a()(),l(12,"td"),s(13),a(),l(14,"td"),s(15),a(),l(16,"td"),s(17),a(),l(18,"td"),s(19),a()()),e&2){let t=n.$implicit,i=p(2);d(2),g(t.isoCode),d(2),g(t.iso3),d(2),g(t.isoNumeric),d(2),g(t.fips),d(2),v("routerLink",i.countryPath(t)),d(),g(t.countryName),d(2),g(t.capital),d(2),g(t.areaSqKm!=null?t.areaSqKm.toLocaleStr
92ing():""),d(2),g(t.population!=null?t.population.toLocaleString():""),d(2),g(t.continentCode)}}function LL(e,n){if(e&1){let t=$();l(0,"div",2)(1,"table",3)(2,"thead")(3,"tr")(4,"th")(5,"button",4),M("click",function(){S(t);let o=p();return w(o.sortBy("isoCode"))}),s(6," ISO-3166 alpha2 "),y(7,PL,2,1,"span",5),a()(),l(8,"th")(9,"button",4),M("click",function(){S(t);let o=p();return w(o.sortBy("iso3"))}),s(10," ISO-3166 alpha3 "),y(11,DL,2,1,"span",5),a()(),l(12,"th")(13,"button",4),M("click",function(){S(t);let o=p();return w(o.sortBy("isoNumeric"))}),s(14," ISO-3166 numeric "),y(15,IL,2,1,"span",5),a()(),l(16,"th")(17,"button",4),M("click",function(){S(t);let o=p();return w(o.sortBy("fips"))}),s(18," fips "),y(19,TL,2,1,"span",5),a()(),l(20,"th")(21,"button",4),M("click",function(){S(t);let o=p();return w(o.sortBy("countryName"))}),s(22," Country "),y(23,OL,2,1,"span",5),a()(),l(24,"th")(25,"button",4),M("click",function(){S(t);let o=p();return w(o.sortBy("capital"))}),s(26," Capital "),y(27,NL,2,1,"span",5),a()(),l(28,"th")(29,"button",4),M("click",function(){S(t);let o=p();return w(o.sortBy("areaSqKm"))}),s(30," Area in km\xB2 "),y(31,kL,2,1,"span",5),a()(),l(32,"th")(33,"button",4),M("click",function(){S(t);let o=p();return w(o.sortBy("population"))}),s(34," Population "),y(35,AL,2,1,"span",5),a()(),l(36,"th")(37,"button",4),M("click",function(){S(t);let o=p();return w(o.sortBy("continentCode"))}),s(38," Continent "),y(39,RL,2,1,"span",5),a()()()(),l(40,"tbody"),I(41,FL,20,10,"tr",null,wL),a()()()}if(e&2){let t=p();d(7),_(t.sortColumn()==="isoCode"?7:-1),d(4),_(t.sortColumn()==="iso3"?11:-1),d(4),_(t.sortColumn()==="isoNumeric"?15:-1),d(4),_(t.sortColumn()==="fips"?19:-1),d(4),_(t.sortColumn()==="countryName"?23:-1),d(4),_(t.sortColumn()==="capital"?27:-1),d(4),_(t.sortColumn()==="areaSqKm"?31:-1),d(4),_(t.sortColumn()==="population"?35:-1),d(4),_(t.sortColumn()==="continentCode"?39:-1),d(2),T(t.sortedCountries())}}var Gd=class e{countryInfo=h(it);title=h(H);state=E("loading");countries=E([]);sortColumn=E("isoCode");sortDescending=E(!1);sortedCountries=G(()=>{let n=this.sortColumn(),t=this.sortDescending()?-1:1;return[...this.countries()].sort((i,o)=>{let r=i[n],c=o[n];return r==null&&c==null?0:r==null?1:c==null?-1:typeof r=="string"||typeof c=="string"?t*String(r).localeCompare(String(c)):t*(r>c?1:r<c?-1:0)})});constructor(){this.title.setTitle("GeoNames Country Codes \u2014 GeoNames UI"),this.countryInfo.getCountries().subscribe({next:n=>{this.countries.set(n),this.state.set("loaded")},error:()=>this.state.set("error")})}countryPath(n){return`/countries/${n.isoCode}/${We(n.countryName)}.html`}sortBy(n){this.sortColumn()===n?this.sortDescending.update(t=>!t):(this.sortColumn.set(n),this.sortDescending.set(n==="areaSqKm"||n==="population"))}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-country-codes-page"]],decls:5,vars:1,consts:[[1,"placeholder"],[1,"not-found"],[1,"table-scroll"],[1,"stats-table"],["type","button",3,"click"],[1,"sort-arrow"],[3,"routerLink"]],template:function(t,i){if(t&1&&(l(0,"h1"),s(1,"Country Codes"),a(),y(2,EL,2,0,"p",0)(3,ML,2,0,"p",1)(4,LL,43,9,"div",2)),t&2){let o;d(2),_((o=i.state())==="loading"?2:o==="error"?3:o==="loaded"?4:-1)}},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:900px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.6rem}.placeholder[_ngcontent-%COMP%], .not-found[_ngcontent-%COMP%]{color:#777;font-size:.9rem}.table-scroll[_ngcontent-%COMP%]{position:relative;max-height:70vh;overflow:auto;scrollbar-width:thin}.stats-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.stats-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .stats-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .6rem;border-bottom:1px solid #eee;text-align:left;white-space:nowrap}.stats-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:nth-child(7), .stats-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:nth-child(7), .stats-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:nth-child(8), .stats-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]:nth-child(8){text-align:right;font-variant-numeric:tabular-nums}.stats-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{position:sticky;top:0;background:#fff;border-bottom:2px solid #ddd;color:#555}.stats-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.stats-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.stats-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:none;background:none;font:inherit;color:inherit;cursor:pointer;padding:0}.sort-arrow[_ngcontent-%COMP%]{font-size:.7em;margin-left:.15rem}
92.stats-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.stats-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var Wd=class e{http=h(Z);getRecentChanges(n,t){let i=new URLSearchParams({startRow:String(n),maxRows:String(t)});return this.http.get(`/api/recent-changes?${i.toString()}`)}getRecentChangesByUser(n,t,i){let o=new URLSearchParams({startRow:String(t),maxRows:String(i),username:n});return this.http.get(`/api/recent-changes?${o.toString()}`)}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var qd=class e{http=h(Z);get(n){return this.http.get(`/api/users/${encodeURIComponent(n)}`)}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var VL=(e,n)=>n.geonameId+"-"+n.revision+"-"+n.modificationTime;function UL(e,n){e&1&&(l(0,"h1"),s(1),a()),e&2&&(d(),A("Recent Modifications for user ",n,""))}function jL(e,n){e&1&&(l(0,"h1"),s(1,"Recent Updates"),a())}function BL(e,n){if(e&1&&(l(0,"div",0)(1,"span"),s(2),a(),l(3,"a",3),s(4,"web service config"),a(),l(5,"a",3),s(6,"enable ws account"),a(),l(7,"a",4),s(8,"delete account"),a(),l(9,"a",4),s(10,"block account"),a()()),e&2){let t=n,i=p();d(2),le("",t.email," id=",t.userId,""),d(),v("href",i.webServiceConfigUrl(t.userId),Y),d(2),v("href",i.enableWsAccountUrl(t.userId),Y),d(2),v("href",i.deleteAccountUrl(t.userId),Y),d(2),v("href",i.blockAccountUrl(t.userId),Y)}}function HL(e,n){e&1&&(l(0,"p",1),s(1,"Loading recent updates\u2026"),a())}function $L(e,n){e&1&&(l(0,"p",2),s(1,"Could not load recent updates right now."),a())}function zL(e,n){e&1&&(l(0,"th"),s(1,"Undo"),a())}function GL(e,n){if(e&1&&(l(0,"td")(1,"a",9),s(2,"undo"),a()()),e&2){let t=p().$implicit,i=p(2);d(),v("routerLink",i.historyPath(t))}}function WL(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),a(),l(3,"td"),s(4),Be(5,"date"),a(),l(6,"td")(7,"a",9),s(8),a()(),l(9,"td"),s(10),a(),l(11,"td")(12,"a",9),s(13),a()(),l(14,"td"),s(15),a(),l(16,"td",10),s(17),a(),l(18,"td")(19,"a",9),s(20,"history"),a()(),y(21,GL,3,1,"td"),a()),e&2){let t=n.$implicit,i=p(2);d(2),g(i.revisionLabel(t)),d(2),g(He(5,12,t.modificationTime,"yyyy MM dd HH:mm:ss")),d(3),v("routerLink",i.placePath(t)),d(),g(t.name),d(2),g(t.countryCode),d(2),v("routerLink",i.userPath(t.username)),d(),g(t.username),d(2),le("",t.featureClass,".",t.featureCode,""),d(2),g(t.comment),d(2),v("routerLink",i.historyPath(t)),d(2),_(i.showUndoColumn()?21:-1)}}function qL(e,n){if(e&1){let t=$();l(0,"div",5)(1,"table",6)(2,"thead")(3,"tr")(4,"th"),s(5,"Rev"),a(),l(6,"th"),s(7,"Time"),a(),l(8,"th"),s(9,"Name"),a(),l(10,"th"),s(11,"CC"),a(),l(12,"th"),s(13,"Username"),a(),l(14,"th"),s(15,"Feat."),a(),l(16,"th"),s(17,"Comment"),a(),l(18,"th"),s(19,"History"),a(),y(20,zL,2,0,"th"),a()(),l(21,"tbody"),I(22,WL,22,15,"tr",null,VL),a()()(),l(24,"div",7)(25,"button",8),M("click",function(){S(t);let o=p();return w(o.previousPage())}),s(26,"\xAB Previous"),a(),l(27,"button",8),M("click",function(){S(t);let o=p();return w(o.nextPage())}),s(28,"Next \xBB"),a()()}if(e&2){let t=p();d(20),_(t.showUndoColumn()?20:-1),d(2),T(t.changes()),d(3),v("disabled",!t.hasPrevious()),d(2),v("disabled",!t.hasNext())}}var JL=601,KL=611,YL=23,ZL=620,QL={1:"M",2:"U",3:"D",4:"A",5:"I",6:"R",7:"H"},XL=50,es=class e{route=h(ve);recentChanges=h(Wd);places=h(tt);auth=h(qe);userAdmin=h(qd);title=h(H);username=E(null);state=E("loading");changes=E([]);startRow=E(0);pageSize=XL;hasPrevious=G(()=>this.startRow()>0);hasNext=G(()=>this.changes().length===this.pageSize);showUndoColumn=G(()=>{let n=Number(this.auth.currentUser()?.userLevel);return Number.isFinite(n)&&n>10});isGeoNamesTeam=G(()=>Number(this.auth.currentUser()?.userLevel)>100);adminInfo=E(null);constructor(){this.route.paramMap.pipe(N(n=>n.get("username"))).subscribe(n=>{this.username.set(n),this.startRow.set(0),this.title.setTitle(n?`Recent Modifications for user ${n} \u2014 GeoNames UI`:"GeoNames Recent Updates \u2014 GeoNames UI"),this.load(),this.loadAdminInfo(n)})}legacyAccountUrl(n,t){return`https://www.geonames.org/servlet/geonames?srv=${n}&userid=${t}`}webServiceConfigUrl(n){return this.legacyAccountUrl(JL,n)}enableWsAccountUrl(n){return this.legacyAccountUrl(KL,n)}deleteAccountUrl(n){return this.legacyAccountUrl(YL,n)}blockAccountUrl(n){return this.legacyAccountUrl(ZL,n)}loadAdminInfo(n){this.adminInfo.set(null),!(!n||!this.isGeoNamesTeam())&&this.userAdmin.get(n).subscribe({next:t=>this.adminInfo.set(t),error:()=>this.adminInfo.set(null)})}userPath(n){return`/recent-changes/user/${encodeURIComponent(n)}`}load(){this.state.set("loading");let n=this.username();(n?this.recentChanges.getRecentChangesByUser(n,this.startRow(),this.pageSize):this.recentChanges.getRecentChanges(this.startRow(),this.pageSize)).subscribe({next:i=>{this.changes.set(i),this.state.set("loaded")},error:()=>this.state.set("error")})}revisionLabel(n){let t=QL[n.modificationClass];return t?`${n.revision} ${t}`:String(n.revision)}placePath(n){return this.places.path({id:String(n.geonameId),name:n.name})}historyPath(n){return`/history/${n.geonameId}`}nextPage(){this.hasNext()&&(this.startRow.update(n=>n+this.pageSize),this.load())}previousPage(){this.hasPrevious()&&(this.startRow.update(n=>Math.max(0,n-this.pageSize)),this.load())}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-recent-changes-page"]],decls:6,vars:3,consts:[[1,"admin-panel"],[1,"placeholder"],[1,"not-found"],[3,"href"],[1,"danger",3,"href"],[1,"table-scroll"],[1,"changes-table"],[1,"pager"],["type","button",3,"click","disabled"],[3,"routerLink"],[1,"comment"]],template:function(t,i){if(t&1&&y(0,UL,2,1,"h1")(1,jL,2,0,"h1")(2,BL,11,6,"div",0)(3,HL,2,0,"p",1)(4,$L,2,0,"p",2)(5,qL,29,3),t&2){let o,r,c;_((o=i.username())?0:1,o),d(2),_((r=i.adminInfo())?2:-1,r),d(),_((c=i.state())==="loading"?3:c==="error"?4
92:c==="loaded"?5:-1)}},dependencies:[Ct,W],styles:["[_nghost-%COMP%]{display:block;max-width:1000px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.6rem}.placeholder[_ngcontent-%COMP%], .not-found[_ngcontent-%COMP%]{color:#777;font-size:.9rem}.admin-panel[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:center;gap:.4rem 1rem;margin:-.5rem 0 1rem;padding:.5rem .75rem;background:#f8f9fa;border-radius:6px;font-size:.8rem;color:#555}.admin-panel[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.admin-panel[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.admin-panel[_ngcontent-%COMP%]   a.danger[_ngcontent-%COMP%]{color:#b3261e}.table-scroll[_ngcontent-%COMP%]{position:relative;max-height:70vh;overflow:auto;scrollbar-width:thin}.changes-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.changes-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .changes-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .6rem;border-bottom:1px solid #eee;text-align:left;white-space:nowrap}.changes-table[_ngcontent-%COMP%]   td.comment[_ngcontent-%COMP%]{white-space:normal;min-width:220px}.changes-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{position:sticky;top:0;background:#fff;border-bottom:2px solid #ddd;color:#555}.changes-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.changes-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.changes-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.changes-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.pager[_ngcontent-%COMP%]{display:flex;justify-content:space-between;margin-top:.75rem}.pager[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{padding:.35rem .9rem;font-size:.85rem;border:1px solid #ccc;border-radius:4px;background:#f7f7f7;cursor:pointer}.pager[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:hover:not(:disabled){background:#eee}.pager[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:default}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var Jd=class e{title=h(H);constructor(){this.title.setTitle("GeoNames Datasources \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-data-sources"]],decls:230,vars:0,consts:[[1,"source-list"],["href","http://geonames.nga.mil/gns/html/index.html","target","_blank","rel","noopener noreferrer"],["href","http://geonames.usgs.gov/index.html","target","_blank","rel","noopener noreferrer"],["href","http://www.naco.org/","target","_blank","rel","noopener noreferrer"],["href","https://open.canada.ca/data/en/dataset/e27c6eba-3c5d-4051-9db2-082dc6411c2c","target","_blank","rel","noopener noreferrer"],["href","http://www.msss.gouv.qc.ca/","target","_blank","rel","noopener noreferrer"],["href","http://www.cne.org.bo/","target","_blank","rel","noopener noreferrer"],["href","http://www.ibge.gov.br/home/","target","_blank","rel","noopener noreferrer"],["href","http://eros.usgs.gov/#/Find_Data/Products_and_Data_Available/gtopo30_info","target","_blank","rel","noopener noreferrer"],["href","http://www2.jpl.nasa.gov/srtm/","target","_blank","rel","noopener noreferrer"],["href","http://www.cgiar-csi.org/data/elevation/item/45-srtm-90m-digital-elevation-database-v41","target","_blank","rel","noopener noreferrer"],["href","http://www.linz.govt.nz","target","_blank","rel","noopener noreferrer"],["href","http://www.stats.govt.nz/","target","_blank","rel","noopener noreferrer"],["href","http://www.summitpost.org/","target","_blank","rel","noopener noreferrer"],["href","http://www.geocities.com/Athens/9479/welcome.html","target","_blank","rel","noopener noreferrer"],["href","http://www.gipuzkoa.net/","target","_blank","rel","noopener noreferrer"],["href","http://geonames.wordpress.com/2007/03/21/a-basque-region-gives-its-public-data-to-geonames/","target","_blank","rel","noopener noreferrer"],["href","http://www.geobreizh.com","target","_blank","rel","noopener noreferrer"],["href","http://www.rap.ucar.edu/weather/surface/stations.txt","target","_blank","rel","noopener noreferrer"],["href","http://www.weathergraphics.com/identifiers","target","_blank","rel","noopener noreferrer"],["href","http://www.ourairports.com","target","_blank","rel","noopener noreferrer"],["href","http://www.swisstopo.admin.ch","target","_blank","rel","noopener noreferrer"],["href","http://www.statistik.zh.ch/raum/sv/","target","_blank","rel","noopener noreferrer"],["href","http://www.ssb.no/","target","_blank","rel","noopener noreferrer"],["href","http://www.erikbolstad.no/","target","_blank","rel","noopener noreferrer"],["href","http://www.dst.dk/","target","_blank","rel","noopener noreferrer"],["href","http://www.maanmittauslaitos.fi/en/NLS_open_data_licence_version1_20120501","target","_blank","rel","noopener noreferrer"],["href","http://www.lantmateriet.se/","target","_blank","rel","noopener noreferrer"],["href","http://www.bebyggelseregistret.raa.se","target","_blank","rel","noopener noreferrer"],["href","http://www.cbs.nl","target","_blank","rel","noopener noreferrer"],["href","http://www.ine.es/","target","_blank","rel","noopener noreferrer"],["href","http://www.ign.es","target","_blank","rel","noopener noreferrer"],["href","http://www.igeo.pt/","target","_blank","rel","noopener noreferrer"],["href","http://www.istat.it/","target","_blank","rel","noopener noreferrer"],["href","http://geodati.gfoss.it/","target","_blank","rel","noopener noreferrer"],["href","http://www.ign.fr/","target","_blank","rel","noopener noreferrer"],["href","http://www.insee.fr","target","_blank","rel","noopener noreferrer"],["href","http://www.data.gouv.fr/","target","_blank","rel","noopener noreferrer"],["href","http://test.data-sncf.com/","target","_blank","rel","noopener noreferrer"],["href","http://www.ordnancesurvey.co.uk/","target","_blank","rel","noopener noreferrer"],["href","http://www.dft.gov.uk/nptg/","target","_blank","rel","noopener noreferrer"],["href","http://www.nationalarchives.gov.uk/doc/open-government-licence/","target","_blank","rel","noopener noreferrer"],["href","http://www.nisra.gov.uk","target","_blank","rel","noopener noreferrer"],["href","http://grass.fsv.cvut.cz/wiki/index.php/FreeGeodataCZ","target","_blank","rel","noopener noreferrer"],["href","http://www.stat.si/","target","_blank","rel","noopener noreferrer"],["href","http://www.ngiip.gov.np/","target","_blank","rel","noopener noreferrer"],["href","https://data.aad.gov.au/aadc/gaz/scar/","target","_blank","rel","noopener noreferrer"],["href","http://www.scar.org/","target","_blank","rel","noopener noreferrer"],["href","http://geonames.wordpress.com/2008/01/22/penguins-released-antarctica-cga/","target","_blank","rel","noopener noreferrer"],["href","http://apc.antarctica.ac.uk/","target","_blank","rel","noopener noreferrer"],["href","http://weather.noaa.gov/tg/site.shtml","target","_blank","rel","noopener noreferrer"],["href","https://www.cia.gov/library/publications/the-world-factbook/index.html","target","_blank","rel","noopener noreferrer"],["href","http://www.nsi.bg/","target","_blank","rel","noopener noreferrer"],["href","http://data.gov.ro/","target","_blank","rel","noopener noreferrer"],["href","http://data.wien.gv.at/","target","_blank","rel","noopener noreferrer"],["href","http://data.noe.gv.at/Open-Government-Data.html","target","_blank","rel","noopener noreferrer"],["href","http://data.ooe.gv.at","target","_blank","rel","noopener noreferrer"],["href","http://www.geodata.gov.gr/geodata/index.php","target","_blank","rel","noopener noreferrer"],["href","http://www.mophp-ye.org/english/index.html","target","_blank","rel","noopener noreferrer"],["href","http://vermessu
92ng.bayern.de/","target","_blank","rel","noopener noreferrer"],["href","http://www.statistik-berlin-brandenburg.de/produkte/Produkte-open-data.asp","target","_blank","rel","noopener noreferrer"],["href","http://www.demarcation.org.za/","target","_blank","rel","noopener noreferrer"],["href","http://ehealthafrica.org/","target","_blank","rel","noopener noreferrer"],["href","http://www.inegi.org.mx/","target","_blank","rel","noopener noreferrer"],["href","http://bogomap.co/","target","_blank","rel","noopener noreferrer"],["href","http://www.hotels.com","target","_blank","rel","noopener noreferrer"],["href","http://www.diytravel.co.uk","target","_blank","rel","noopener noreferrer"],["href","http://www.hotelsearch.com/","target","_blank","rel","noopener noreferrer"],[1,"more-links"],["routerLink","/datasources"],["routerLink","/postal-codes-sources.html"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"Datasources used by GeoNames in the GeoNames Gazetteer"),a(),l(2,"ul",0)(3,"li")(4,"a",1),s(5,"nga"),a(),s(6," : National Geospatial-Intelligence Agency's (NGA) and the U.S. Board on Geographic Names (most names except US and CA) "),a(),l(7,"li")(8,"a",2),s(9,"gnis"),a(),s(10," : U.S. Geological Survey Geographic Names Information System (names in US). "),a(),l(11,"li")(12,"a",3),s(13,"National Association of Counties"),a()(),l(14,"li")(15,"a",4),s(16,"GeoBase - Canadian Geographical Names"),a(),s(17," (names in CA) "),a(),l(18,"li")(19,"a",5),s(20,"Minist\xE8re de la Sant\xE9 et des Services sociaux"),a()(),l(21,"li")(22,"a",6),s(23,"Corte Nacional Electoral - Republica de Boliviaa"),a()(),l(24,"li")(25,"a",7),s(26,"Brasileiro de Geografia Estat\xEDstica (IBGE)"),a()(),l(27,"li")(28,"a",8),s(29,"gtopo30 (elevation)"),a()(),l(30,"li")(31,"a",9),s(32,"nasa: srtm3 elevation"),a(),s(33,", "),l(34,"a",10),s(35,"cgiar: void filled srtm3 elevation"),a()(),l(36,"li"),s(37,"world-gazetteer.com (population data, source site does no longer exist)"),a(),l(38,"li")(39,"a",11),s(40,"Land Information New Zealand LINZ"),a()(),l(41,"li")(42,"a",12),s(43,"Statistics New Zealand"),a()(),l(44,"li")(45,"a",13),s(46,"summitpost"),a(),s(47," (elevation of mountains)"),a(),l(48,"li")(49,"a",14),s(50,"Geonative"),a(),s(51,": alternate names"),a(),l(52,"li")(53,"a",15),s(54,"Gipuzkoa Provincial Council"),a(),s(55," (see "),l(56,"a",16),s(57,"Blog posting"),a(),s(58,") "),a(),l(59,"li")(60,"a",17),s(61,"G\xE9ographie de Bretagne"),a()(),l(62,"li")(63,"a",18),s(64,"METAR Weatherstations"),a()(),l(65,"li")(66,"a",19),s(67,"Master Location Identifier Database (c) 2008, 2011 Weather Graphics, Norman, Oklahoma"),a()(),l(68,"li")(69,"a",20),s(70,"OurAirports"),a()(),l(71,"li")(72,"a",21),s(73,"Amtliche Vermessung Schweiz / swisstopo"),a()(),l(74,"li")(75,"a",22),s(76,"Statistische Amt des Kantons Z\xFCrich"),a()(),l(77,"li")(78,"a",23),s(79,"Statistisk sentralbyr Norway"),a(),s(80," (administrative divisions)"),a(),l(81,"li")(82,"a",24),s(83,"Erik Bolstad"),a()(),l(84,"li")(85,"a",25),s(86,"Danmarks Statistik"),a(),s(87," (admin codes)"),a(),l(88,"li")(89,"a",26),s(90,"\xA9 National Land Survey of Finland 2011"),a()(),l(91,"li")(92,"a",27),s(93,"Swedish National Land Survey"),a()(),l(94,"li")(95,"a",28),s(96,"Sweden: Bebyggelseregistret, BBR (Data Base of Built Heritage)"),a()(),l(97,"li")(98,"a",29),s(99,"Centraal Bureau voor de Statistiek"),a(),s(100," and Eugene van der Pijll"),a(),l(101,"li")(102,"a",30),s(103,"Instituto Nacional de Estad\xEDstica. (National Statistics Institute), Spain"),a(),s(104," (admin codes) "),a(),l(105,"li")(106,"a",31),s(107,"Instituto Geogr\xE1fico Nacional"),a()(),l(108,"li")(109,"a",32),s(110,"Instituto Geogr\xE1fico Portugu\xEAs"),a()(),l(111,"li")(112,"a",33),s(113,"Istituto Nazionale di Statistica - Italia"),a()(),l(114,"li")(115,"a",34),s(116,"gfoss.it"),a()(),l(117,"li")(118,"a",35),s(119,"Institut national de l'information g\xE9ographique et foresti\xE8re"),a()(),l(120,"li")(121,"a",36),s(122,"Insee - Institut National de la Statistique et des \xC9tudes \xC9conomiques - France"),a(),s(123," (admin codes) "),a(),l(124,"li")(125,"a",37),s(126,"Open Data France - data.gouv.fr"),a()(),l(127,"li")(128,"a",38),s(129,"sncf"),a(),s(130," (French train stations)"),a(),l(131,"li")(132,"a",39),s(133,"Ordnance Survey, UK"),a(),s(134," (Ordnance Survey data Crown copyright and database r
92ight 2010) "),a(),l(135,"li")(136,"a",40),s(137,"UK Department for Transport"),a(),s(138," ("),l(139,"a",41),s(140,"public sector information"),a(),s(141," licensed under the Open Government Licence v1.0) "),a(),l(142,"li")(143,"a",42),s(144,"NISRA - Northern Ireland Statistics and Research Agency"),a()(),l(145,"li")(146,"a",43),s(147,"Geodata for Czech Republic"),a()(),l(148,"li")(149,"a",44),s(150,"Statistical Office of the Republic of Slovenia"),a()(),l(151,"li")(152,"a",45),s(153,"National Geographic Information Infrastructure Programme, Survey Department, Government of Nepal"),a()(),l(154,"li")(155,"a",46),s(156,"Composite Gazetteer of Antarctica"),a(),s(157," courtesy of the "),l(158,"a",47),s(159,"Scientific Committee on Antarctic Research - SCAR"),a(),s(160,", ("),l(161,"a",48),s(162,"disclaimer"),a(),s(163,") "),a(),l(164,"li")(165,"a",49),s(166,"UK Antarctic Place-names Committee (APC)"),a()(),l(167,"li")(168,"a",50),s(169,"National Oceanic and Atmospheric Administration"),a(),s(170," : Weather Stations "),a(),l(171,"li")(172,"a",51),s(173,"CIA - The World Factbook"),a()(),l(174,"li")(175,"a",52),s(176,"National Statistical Institute Bulgaria"),a()(),l(177,"li"),s(178,"Roman Rachkov (Bulgarian toponyms)"),a(),l(179,"li")(180,"a",53),s(181,"Open Data Portal Romania"),a()(),l(182,"li")(183,"a",54),s(184,"Offene Daten Wien"),a()(),l(185,"li")(186,"a",55),s(187,"Land Nieder\xF6sterreich Open Government Data"),a()(),l(188,"li")(189,"a",56),s(190,"Datenquelle: Land Ober\xF6sterreich - data.ooe.gv.at"),a()(),l(191,"li")(192,"a",57),s(193,"Hellenic Mapping and Cadastral Organisation (HEMCO)"),a()(),l(194,"li")(195,"a",58),s(196,"Yemen Ministry of Public Health"),a()(),l(197,"li")(198,"a",59),s(199,"Bayerische Vermessungsverwaltung . www.geodaten.bayern.de"),a()(),l(200,"li")(201,"a",60),s(202,"Amt fuer Statistik Berlin-Brandenburg"),a()(),l(203,"li")(204,"a",61),s(205,"Municipal Demarcation Board South Africa"),a()(),l(206,"li")(207,"a",62),s(208,"eHealth Africa - Nigeria"),a()(),l(209,"li")(210,"a",63),s(211,"INEGI Mexico"),a()(),l(212,"li")(213,"a",64),s(214,"Bus stops Columbia - Bogomap"),a()(),l(215,"li")(216,"a",65),s(217,"hotels.com"),a()(),l(218,"li")(219,"a",66),s(220,"diytravel"),a()(),l(221,"li")(222,"a",67),s(223,"hotelsearch.com"),a()()(),l(224,"p",68)(225,"a",69),s(226,"more data sources"),a()(),l(227,"p",68)(228,"a",70),s(229,"postal code sources ..."),a()())},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:700px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.4rem}.source-list[_ngcontent-%COMP%]{margin:0;padding-left:1.2rem;font-size:.9rem;line-height:1.5}.source-list[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.4rem 0}a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.more-links[_ngcontent-%COMP%]{margin:.75rem 0}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var Kd=class e{http=h(Z);getSources(){return this.http.get("/api/postal-code-sources")}update(n,t){return this.http.put(`/api/postal-code-sources/${encodeURIComponent(n)}`,t)}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var e5=(e,n)=>n.countryCode;function t5(e,n){e&1&&(l(0,"p",0),s(1,"Loading postal code sources\u2026"),a())}function n5(e,n){e&1&&(l(0,"p",1),s(1,"Could not load postal code sources right now."),a())}function i5(e,n){e&1&&(l(0,"th"),s(1,"Date"),a())}function o5(e,n){e&1&&(l(0,"th"),s(1,"Trustworthiness"),a(),l(2,"th"),s(3,"Internal Remark"),a(),l(4,"th"),s(5,"Match Date"),a())}function r5(e,n){e&1&&(l(0,"th"),s(1,"PO Box"),a(),l(2,"th"),s(3,"Single Code"),a(),l(4,"th"),s(5,"CC Prefix"),a())}function a5(e,n){e&1&&(l(0,"th"),s(1,"Actions"),a())}function s5(e,n){if(e&1&&(l(0,"span",4),s(1),a()),e&2){let t=p().$implicit;d(),g(t.countryName)}}function l5(e,n){if(e&1&&(l(0,"a",5),s(1),a()),e&2){let t=p().$implicit;v("href",t.sourceUrl,Y),d(),g(t.source||t.sourceUrl)}}function c5(e,n){if(e&1&&s(0),e&2){let t=p().$implicit;A(" ",t.source," ")}}function d5(e,n){if(e&1&&(l(0,"a",5),s(1,"download"),a()),e&2){let t=p().$implicit;v("href",t.sourceUrlDownload,Y)}}function u5(e,n){if(e&1&&(l(0,"a",5),s(1,"search"),a()),e&2){let t=p().$implicit;v("href",t.sourceUrlSearch,Y)}}function m5(e,n){if(e&1&&(l(0,"td"),s(1),a()),e&2){let t=p().$implicit;d(),g(t.sourceDate)}}function p5(e,n){if(e&1&&(l(0,"td",7),s(1),a(),l(2,"td",6),s(3),a(),l(4,"td"),s(5),a()),e&2){let t=p().$implicit;
92d(),g(t.sourceTrustworthyness),d(2),g(t.internalRemark),d(2),g(t.matchDate)}}function f5(e,n){if(e&1&&(l(0,"td"),s(1),a(),l(2,"td"),s(3),a(),l(4,"td"),s(5),a()),e&2){let t=p().$implicit;d(),g(t.hasPoBox?"\u2713":""),d(2),g(t.hasSingleCode?t.singlePostalCode||"\u2713":""),d(2),g(t.isUsingCcPrefix?"\u2713":"")}}function h5(e,n){if(e&1){let t=$();l(0,"td",8)(1,"button",10),M("click",function(){S(t);let o=p().$implicit,r=p(2);return w(r.startEdit(o))}),s(2,"edit"),a()()}if(e&2){let t=p(3);d(),v("disabled",t.editingCountryCode()!==null)}}function g5(e,n){if(e&1&&(l(0,"p",22),s(1),a()),e&2){let t=p(4);d(),g(t.saveError())}}function C5(e,n){if(e&1){let t=$();l(0,"tr",9)(1,"td")(2,"form",11),M("submit",function(o){return S(t),p(3).save(),w(o.preventDefault())}),l(3,"label",12),s(4,"Source name "),l(5,"input",13),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.source,o)||(r.form.source=o),w(o)}),a()(),l(6,"label",12),s(7,"Source URL "),l(8,"input",14),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.sourceUrl,o)||(r.form.sourceUrl=o),w(o)}),a()(),l(9,"label",12),s(10,"Download URL "),l(11,"input",15),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.sourceUrlDownload,o)||(r.form.sourceUrlDownload=o),w(o)}),a()(),l(12,"label",12),s(13,"Search URL "),l(14,"input",16),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.sourceUrlSearch,o)||(r.form.sourceUrlSearch=o),w(o)}),a()(),l(15,"label",12),s(16,"Remark "),l(17,"input",17),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.remark,o)||(r.form.remark=o),w(o)}),a()(),l(18,"label",18)(19,"input",19),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.form.isOfficialSource,o)||(r.form.isOfficialSource=o),w(o)}),a(),s(20," Official source "),a(),l(21,"div",20)(22,"button",21),s(23),a(),l(24,"button",10),M("click",function(){S(t);let o=p(3);return w(o.cancelEdit())}),s(25,"Cancel"),a()(),y(26,g5,2,1,"p",22),a()()()}if(e&2){let t=p(3);d(),_e("colspan",11+(t.canEdit()?5:0)+(t.showModeratorColumns()?3:0)),d(4),R("ngModel",t.form.source),d(3),R("ngModel",t.form.sourceUrl),d(3),R("ngModel",t.form.sourceUrlDownload),d(3),R("ngModel",t.form.sourceUrlSearch),d(3),R("ngModel",t.form.remark),d(2),R("ngModel",t.form.isOfficialSource),d(3),v("disabled",t.saving()),d(),g(t.saving()?"Saving\u2026":"Save"),d(),v("disabled",t.saving()),d(2),_(t.saveError()?26:-1)}}function _5(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),y(3,s5,2,1,"span",4),a(),l(4,"td"),y(5,l5,2,2,"a",5)(6,c5,1,1),a(),l(7,"td"),s(8),a(),l(9,"td",6),s(10),a(),l(11,"td"),y(12,d5,2,1,"a",5),a(),l(13,"td"),y(14,u5,2,1,"a",5),a(),y(15,m5,2,1,"td"),l(16,"td",7),s(17),a(),l(18,"td",7),s(19),a(),l(20,"td",7),s(21),a(),l(22,"td",7),s(23),a(),l(24,"td"),s(25),a(),y(26,p5,6,3)(27,f5,6,3)(28,h5,3,1,"td",8),a(),y(29,C5,27,11,"tr",9)),e&2){let t=n.$implicit,i=p(2);d(2),A("",t.countryCode," "),d(),_(t.countryName?3:-1),d(2),_(t.sourceUrl?5:6),d(3),g(t.isOfficialSource?"\u2713":""),d(2),g(t.remark),d(2),_(t.sourceUrlDownload?12:-1),d(2),_(t.sourceUrlSearch?14:-1),d(),_(i.canEdit()?15:-1),d(2),g(t.numRows),d(2),g(t.numMatches),d(2),g(t.accuracy),d(2),g(t.numPolygons),d(2),g(t.hasBbox?"\u2713":""),d(),_(i.canEdit()?26:-1),d(),_(i.showModeratorColumns()?27:-1),d(),_(i.canEdit()?28:-1),d(),_(i.editingCountryCode()===t.countryCode?29:-1)}}function v5(e,n){if(e&1&&(l(0,"div",2)(1,"table",3)(2,"thead")(3,"tr")(4,"th"),s(5,"Country"),a(),l(6,"th"),s(7,"Source"),a(),l(8,"th"),s(9,"Official"),a(),l(10,"th"),s(11,"Remark"),a(),l(12,"th"),s(13,"Download"),a(),l(14,"th"),s(15,"Search"),a(),y(16,i5,2,0,"th"),l(17,"th"),s(18,"Rows"),a(),l(19,"th"),s(20,"Matches"),a(),l(21,"th"),s(22,"Accuracy"),a(),l(23,"th"),s(24,"Polygons"),a(),l(25,"th"),s(26,"BBox"),a(),y(27,o5,6,0)(28,r5,6,0)(29,a5,2,0,"th"),a()(),l(30,"tbody"),I(31,_5,30,17,null,null,e5),a()()()),e&2){let t=p();d(16),_(t.canEdit()?16:-1),d(11),_(t.canEdit()?27:-1),d(),_(t.showModeratorColumns()?28:-1),d(),_(t.canEdit()?29:-1),d(2),T(t.rows())}}var Yd=class e{sourcesService=h(Kd);countryInfo=h(it);auth=h(qe);title=h(H);state=E("loading");rows=E([]);showModeratorColumns=G(()=>{let n=Number(this.auth.currentUser()?.userLevel);return Number.isFinite(n)&&n>10});canEdit=G(()=>Number(this.auth.currentUser()?.userLevel)>100);editingCountryCode=E(null);saving=E(!1);saveError=E(null);form=this.blankForm();constructor(){this.title.setTitle("GeoNames Postal Code Sources \u2014 GeoNames UI"),this.load()}startEdit(n){this.form={source:n.source??"",sourceUrl:n.sourceUrl??"",sourceUrlDownload:n.sourceUrlDownload??"",sourceUrlSearch:n.sourceUrlSearch??"",remark:n.remark??"",isOfficialSource:!!n.isOfficialSource},this.saveError.set(null),this.editingCountryCode.set(n.countryCode)}cancelEdit(){this.editingCountryCode.set(null),this.saveError.set(null)}save(){let n=this.editingCountryCode();n!==null&&(this.saving.set(!0),this.saveError.set(null),this.sourcesService.update(n,this.form).subscribe({next:()=>{this.saving.set(!1),this.editingCountryCode.set(null),this.load()},error:t=>{this.saving.set(!1),this.saveError.set(t?.status===401?"Sign in to edit postal code sources.":t?.status===403?"Only GeoNames team members can edit postal code sources.":t?.status===404?"This country no longer has a source row - reload the page.":"Could not save right now.")}}))}load(){Rr({sources:this.sourcesService.getSources(),countries:this.countryInfo.getCountries()}).subscribe({next:({sources:n,countries:t})=>{let i=new Map(t.map(o=>[o.isoCode,o.countryName]));this.rows.set(n.map(o=>oe(U({},o),{countryName:i.get(o.countryCode)??""}))),this.state.set("loaded")},error:()=>this.state.set("error")})}blankForm(){return{source:"",sourceUrl:"",sourceUrlDownload:"",sourceUrlSearch:"",remark:"",isOfficialSource:!1}}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-postal-code-sources-page"]],decls:5,vars:1,consts:[[1,"placeholder"],[1,"not-found"],[1,"table-scroll"],[1,"sources-table"],[1,"country-name"],["target","_blank","rel","noopener noreferrer",3,"href"],[1,"remark"],[1,"num"],[1,"actions"],[1,"edit-row"],["type","button",3,"click","disabled"],[1,"edit-form",3,"submit"],[1,"grow"],["type","text","name","source","maxlength","255",3,"ngModelChange","ngModel"],["type","text","name","sourceUrl","maxlength","255",3,"ngModelChange","ngModel"],["type","text","name","sourceUrlDownload","maxlength","255",3,"ngModelChange","ngModel"],["type","text","name","sourceUrlSearch","maxlength","255",3,"ngModelChange","ngModel"],["type","text","name","remark","maxlength","255",3,"ngModelChange","ngModel"],[1,"checkbox"],["type","checkbox","name","isOfficialSource",3,"ngModelChange","ngModel"],[1,"edit-actions"],["type","submit",1,"btn-primary",3,"disabled"],[1,"form-error"]],template:function(t,i){if(t&1&&(l(0,"h1"),s(1,"Postal Code Sources"),a(),y(2,t5,2,0,"p",0)(3,n5,2,0,"p",1)(4,v5,33,4,"div",2)),t&2){let o;d(2),_((o=i.state())==="loading"?2:o==="error"?3:o==="loaded"?4:-1)}},dependencies:[ke,pt,Me,pi,Ne,mt,fi,De,dt],styles:["[_nghost-%COMP%]{display:block;max-width:1100px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.6rem}.placeholder[_ngcontent-%COMP%], .not-found[_ngcontent-%COMP%]{color:#7
9277;font-size:.9rem}.table-scroll[_ngcontent-%COMP%]{position:relative;max-height:70vh;overflow:auto;scrollbar-width:thin}.sources-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.sources-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .sources-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .6rem;border-bottom:1px solid #eee;text-align:left;white-space:nowrap}.sources-table[_ngcontent-%COMP%]   td.remark[_ngcontent-%COMP%]{white-space:normal;min-width:180px}.sources-table[_ngcontent-%COMP%]   td.num[_ngcontent-%COMP%]{text-align:right;font-variant-numeric:tabular-nums}.sources-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{position:sticky;top:0;background:#fff;border-bottom:2px solid #ddd;color:#555}.sources-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n):not(.edit-row){background:#fafbfc}.sources-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover:not(.edit-row){background:#eef2f7}.country-name[_ngcontent-%COMP%]{color:#777;margin-left:.3rem}.sources-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.sources-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.2rem .55rem;font-size:.8rem;cursor:pointer}.actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:hover{border-color:#1a5fb4;color:#1a5fb4}.actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.edit-row[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{background:#f8f9fa;white-space:normal}.edit-form[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:flex-end;gap:.6rem .9rem;padding:.5rem 0}.edit-form[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.2rem;font-size:.72rem;color:#666}.edit-form[_ngcontent-%COMP%]   label.grow[_ngcontent-%COMP%]{flex:1;min-width:12rem}.edit-form[_ngcontent-%COMP%]   label.checkbox[_ngcontent-%COMP%]{flex-direction:row;align-items:center;gap:.35rem;align-self:flex-end;padding-bottom:.35rem}.edit-form[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.3rem .4rem;font-size:.85rem}.edit-actions[_ngcontent-%COMP%]{display:flex;gap:.4rem}.edit-actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.edit-actions[_ngcontent-%COMP%]   .btn-primary[_ngcontent-%COMP%]{border-color:#1a5fb4;background:#1a5fb4;color:#fff}.form-error[_ngcontent-%COMP%]{flex-basis:100%;margin:.3rem 0 0;color:#b3261e;font-size:.8rem}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var Zd=class e{http=h(Z);listRuns(){return this.http.get("/api/ch-postal-code-import/runs")}listChanges(n){return this.http.get(`/api/ch-postal-code-import/runs/${n}/changes`)}triggerRun(){return this.http.post("/api/ch-postal-code-import/runs",{})}apply(n){return this.http.post(`/api/ch-postal-code-import/runs/${n}/apply`,{})}reject(n){return this.http.post(`/api/ch-postal-code-import/runs/${n}/reject`,{})}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var y5=(e,n)=>n.id,b5=(e,n)=>n.change.id,x5=(e,n)=>n.label;function S5(e,n){e&1&&(l(0,"p",1),s(1,"Sign in as a GeoNames team member to view postal code import runs."),a())}function w5(e,n){e&1&&(l(0,"p",4),s(1,"Loading runs\u2026"),a())}function E5(e,n){e&1&&(l(0,"p",1),s(1,"Could not load import runs right now."),a())}function M5(e,n){e&1&&(l(0,"p",4),s(1,"No import runs yet."),a())}function P5(e,n){if(e&1){let t=$();l(0,"tr",9),M("click",function(){let o=S(t).$implicit,r=p(4);return w(r.selectRun(o.id))}),l(1,"td"),s(2),a(),l(3,"td"),s(4),Be(5,"date"),a(),l(6,"td")(7,"span",10),s(8),a()(),l(9,"td",11),s(10),a(),l(11,"td",11),s(12),a(),l(13,"td",11),s(14),a(),l(15,"td"),s(16),Be(17,"date"),a()()}if(e&2){let t=n.$implicit,i=p(4);pe("selected",t.id===i.selectedRunId()),d(2),g(t.id),d(2),g(He(5,11,t.startedAt,"yyyy-MM-dd HH:mm")),d(3),aa("status-"+t.status),d(),g(i.statusLabel(t.status)),d(2),g(t.addedCount),d(2),g(t.changedCount),d(2),g(t.removedCount),d(2),g(t.appliedAt?He(17,14,t.appliedAt,"yyyy-MM-dd HH:mm"):"")}}function D5(e,n){if(e&1&&(l(0,"div",6)(1,"table",7)(2,"thead")(3,"tr")(4,"th"),s(5,"ID"),a(),l(6,"th"),s(7,"Started"),a(),l(8,"th"),s(9,"Status"),a(),l(10,"th"),s(11,"Add"),a(),l(12,"th"),s(13,"Change"),a(),l(14,"th"),s(15,"Remove"),a(),l(16,"th"),s(17,"Applied"),a()()(),l(18,"tbody"),I(19,P5,18,17,"tr",8,y5),a()()()),e&2){let t=p(3);d(19),T(t.runs())}}function I5(e,n){if(e&1&&y(0,M5,2,0,"p",4)(1,D5,21,0,"div",6),e&2){let t=p(2);_(t.runs().length?1:0)}}function T5(e,n){if(e&1){let t=$();l(0,"div",13)(1,"button",16),M("click",function(){S(t);let o=p(2),r=p(2);return w(r.startApply(o.id))}),s(2,"Apply"),a(),l(3,"button",17),M("click",function(){S(t);let o=p(2),r=p(2);return w(r.startReject(o.id))}),s(4,"Reject"),a()()}}function O5(e,n){if(e&1){let t=$();l(0,"div",14),s(1),l(2,"code"),s(3,"zip_code"),a(),s(4," table? "),l(5,"div",13)(6,"button",16),M("click",function(){S(t);let o=p(2),r=p(2);return w(r.confirmApply(o.id))}),s(7,"Yes, apply"),a(),l(8,"button",18),M("click",function(){S(t);let o=p(4);return w(o.cancelAction())}),s(9,"Cancel"),a()()()}if(e&2){let t=p(2);d(),gt(" Apply ",t.addedCount," add / ",t.changedCount," change / ",t.removedCount," remove to the real ")}}function N5(e,n){if(e&1){let t=$();l(0,"div",14),s(1," Reject this run? Nothing is applied, and it can't be re-approved later - a fresh run would need to be triggered instead. "),l(2,"div",13)(3,"button",17),M("click",function(){S(t);let o=p(2),r=p(2);return w(r.confirmReject(o.id))}),s(4,"Yes, reject"),a(),l(5,"button",18),M("click",function(){S(t);let o=p(4);return w(o.cancelAction())}),s(6,"Cancel"),a()()()}}function k5(e,n){if(e&1&&(l(0,"p",15),s(1),a()),e&2){let t=p(4);d(),g(t.actionError())}}function A5(e,n){if(e&1&&y(0,T5,5,0,"div",13)(1,O5,10,3,"div",14)(2,N5,7,0,"div",14)(3,k5,2,1,"p",15),e&2){let t=p(),i=p(2);_(i.confirmingAction()===null||i.actioningRunId()!==t.id?0:i.confirmingAction()==="apply"?1:i.confirmingAction()==="reject"?2:-1),d(3),_(i.actionError()?3:-1)}}function R5(e,n){e&1&&(l(0,"p",4),s(1,"Loading changes\u2026"),a())}function F5(e,n){e&1&&(l(0,"p",1),s(1,"Could not load this run's changes right now."),a())}
92function L5(e,n){e&1&&(l(0,"p",4),s(1,"No changes match this filter."),a())}function V5(e,n){if(e&1&&(l(0,"span",26),s(1),a()),e&2){let t=p().$implicit,i=p(5);d(),le(" ",i.location(t.updated)," \xB7 valid from ",t.updated.validFrom||"\u2014"," ")}}function U5(e,n){if(e&1&&(l(0,"span",26),s(1),a()),e&2){let t=p().$implicit,i=p(5);d(),A("was ",i.location(t.old),"")}}function j5(e,n){if(e&1&&(l(0,"li")(1,"strong"),s(2),a(),s(3),a()),e&2){let t=n.$implicit;d(2),A("",t.label,":"),d(),le(" ",t.oldValue," \u2192 ",t.newValue,"")}}function B5(e,n){if(e&1&&(l(0,"ul",27),I(1,j5,4,3,"li",null,x5),a()),e&2){let t=p().$implicit;d(),T(t.diffs)}}function H5(e,n){e&1&&(l(0,"span",26),s(1,"no field-level change detected"),a())}function $5(e,n){if(e&1&&(l(0,"tr")(1,"td")(2,"span",25),s(3),a()(),l(4,"td"),s(5),a(),l(6,"td"),s(7),a(),l(8,"td"),y(9,V5,2,2,"span",26)(10,U5,2,1,"span",26)(11,B5,3,0,"ul",27)(12,H5,2,0,"span",26),a()()),e&2){let t=n.$implicit,i=n.$index;pe("row-even",i%2===1),d(2),aa("type-"+t.change.changeType),d(),g(t.change.changeType),d(2),g(t.change.zip),d(2),g(t.change.placeName),d(2),_(t.change.changeType==="ADD"&&t.updated?9:t.change.changeType==="DELETE"&&t.old?10:t.diffs.length?11:12)}}function z5(e,n){if(e&1&&(l(0,"div",22)(1,"table",23)(2,"thead")(3,"tr")(4,"th"),s(5,"Type"),a(),l(6,"th"),s(7,"Zip"),a(),l(8,"th"),s(9,"Place name"),a(),l(10,"th"),s(11,"Details"),a()()(),l(12,"tbody"),I(13,$5,13,8,"tr",24,b5),a()()()),e&2){let t=p(4);d(13),T(t.filteredRows())}}function G5(e,n){if(e&1){let t=$();l(0,"div",19)(1,"div",20)(2,"button",18),M("click",function(){S(t);let o=p(3);return w(o.typeFilter.set("ALL"))}),s(3),a(),l(4,"button",18),M("click",function(){S(t);let o=p(3);return w(o.typeFilter.set("ADD"))}),s(5,"Add"),a(),l(6,"button",18),M("click",function(){S(t);let o=p(3);return w(o.typeFilter.set("UPDATE"))}),s(7," Change "),a(),l(8,"button",18),M("click",function(){S(t);let o=p(3);return w(o.typeFilter.set("DELETE"))}),s(9," Remove "),a()(),l(10,"input",21),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.search,o)||(r.search=o),w(o)}),a()(),y(11,L5,2,0,"p",4)(12,z5,15,0,"div",22)}if(e&2){let t=p(3);d(2),pe("active",t.typeFilter()==="ALL"),d(),A(" All (",t.changeRows().length,") "),d(),pe("active",t.typeFilter()==="ADD"),d(2),pe("active",t.typeFilter()==="UPDATE"),d(2),pe("active",t.typeFilter()==="DELETE"),d(2),R("ngModel",t.search),d(),_(t.filteredRows().length?12:11)}}function W5(e,n){if(e&1&&(l(0,"div",5)(1,"h2"),s(2),a(),l(3,"p",12),s(4),a(),y(5,A5,4,2)(6,R5,2,0,"p",4)(7,F5,2,0,"p",1)(8,G5,13,11),a()),e&2){let t,i=n,o=p(2);d(2),A("Run ",i.id,""),d(2),g(i.message),d(),_(i.status==="pending_review"?5:-1),d(),_((t=o.changesState())==="loading"?6:t==="error"?7:t==="loaded"?8:-1)}}function q5(e,n){if(e&1){let t=$();l(0,"div",2)(1,"h2"),s(2,"Runs"),a(),l(3,"button",3),M("click",function(){S(t);let o=p();return w(o.triggerRun())}),s(4),a()(),y(5,w5,2,0,"p",4)(6,E5,2,0,"p",1)(7,I5,2,1)(8,W5,9,4,"div",5)}if(e&2){let t,i,o=p();d(3),v("disabled",o.triggering()),d(),A(" ",o.triggering()?"Checking\u2026":"Check for a new run"," "),d(),_((t=o.runsState())==="loading"?5:t==="error"?6:t==="loaded"?7:-1),d(3),_((i=o.selectedRun())?8:-1,i)}}var Gh={adminName1:"Canton",adminCode1:"Canton code",adminName2:"District",adminCode2:"District code",adminName3:"Municipality",adminCode3:"BFS number",admin1GeonameId:"Canton geonameId",admin2GeonameId:"District geonameId",admin3GeonameId:"Municipality geonameId",geonameId:"GeonameId",sourceId:"Source ID",validFrom:"Valid from",latitude:"Latitude",longitude:"Longitude"},Qd=class e{importService=h(Zd);auth=h(qe);title=h(H);canAccess=G(()=>Number(this.auth.currentUser()?.userLevel)>100);runsState=E("loading");runs=E([]);selectedRunId=E(null);changesState=E("idle");changes=E([]);typeFilter=E("ALL");search="";triggering=E(!1);actioningRunId=E(null);confirmingAction=E(null);actionError=E(null);selectedRun=G(()=>this.runs().find(n=>n.id===this.selectedRunId())??null);changeRows=G(()=>this.changes().map(n=>this.toRow(n)));filteredRows=G(()=>{let n=this.typeFilter(),t=this.search.trim().toLowerCase();return this.changeRows().filter(i=>n!=="ALL"&&i.change.changeType!==n?!1:t?i.change.zip.includes(t)||(i.change.placeName??"").toLowerCase().includes(t):!0)});fieldLabels=Gh;constructor(){this.title.setTitle("CH Postal Code Import \u2014 GeoNames UI"),this.canAccess()?this.loadRuns():this.runsState.set("error")}loadRuns(n){this.runsState.set("loading"),this.importService.listRuns().subscribe({next:t=>{this.runs.set(t),this.runsState.set("loaded");let i=n??t.find(o=>o.status==="pending_review")?.id??t[0]?.id??null;i!==null&&this.selectRun(i)},error:()=>this.runsState.set("error")})}selectRun(n){this.selectedRunId.set(n),this.changes.set([]),this.changesState.set("loading"),this.confirmingAction.set(null),this.actionError.
92set(null),this.importService.listChanges(n).subscribe({next:t=>{this.changes.set(t),this.changesState.set("loaded")},error:()=>this.changesState.set("error")})}triggerRun(){this.triggering.set(!0),this.actionError.set(null),this.importService.triggerRun().subscribe({next:n=>{this.triggering.set(!1),this.loadRuns(n.id)},error:n=>{this.triggering.set(!1),this.actionError.set(this.describeError(n))}})}startApply(n){this.actioningRunId.set(n),this.confirmingAction.set("apply"),this.actionError.set(null)}startReject(n){this.actioningRunId.set(n),this.confirmingAction.set("reject"),this.actionError.set(null)}cancelAction(){this.actioningRunId.set(null),this.confirmingAction.set(null)}confirmApply(n){this.importService.apply(n).subscribe({next:()=>{this.confirmingAction.set(null),this.actioningRunId.set(null),this.loadRuns(n)},error:t=>this.actionError.set(this.describeError(t))})}confirmReject(n){this.importService.reject(n).subscribe({next:()=>{this.confirmingAction.set(null),this.actioningRunId.set(null),this.loadRuns(n)},error:t=>this.actionError.set(this.describeError(t))})}describeError(n){return n?.status===401?"Sign in to manage postal code imports.":n?.status===403?"Only GeoNames team members can manage postal code imports.":n?.status===409?"This run is no longer pending review - reload the page.":"Could not complete that action right now."}toRow(n){let t=this.parse(n.oldValues),i=this.parse(n.newValues),o=[];if(n.changeType==="UPDATE"&&t&&i)for(let r of Object.keys(Gh)){let c=t[r],u=i[r];String(c??"")!==String(u??"")&&o.push({label:Gh[r],oldValue:this.formatValue(c),newValue:this.formatValue(u)})}return{change:n,old:t,updated:i,diffs:o}}statusLabel(n){return n.replace(/_/g," ").replace(/^./,t=>t.toUpperCase())}location(n){return n.adminCode1?`${n.adminName3}, ${n.adminCode1}`:n.adminName3??"\u2014"}formatValue(n){return n==null||n===""?"\u2014":typeof n=="number"?n.toFixed(6).replace(/0+$/,"").replace(/\.$/,""):String(n)}parse(n){if(!n)return null;try{return JSON.parse(n)}catch{return null}}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-ch-postal-code-import-page"]],decls:9,vars:1,consts:[[1,"lead"],[1,"placeholder","error"],[1,"runs-header"],["type","button",1,"btn-primary",3,"click","disabled"],[1,"placeholder"],[1,"run-detail"],[1,"table-scroll","runs-scroll"],[1,"runs-table"],[3,"selected"],[3,"click"],[1,"status-badge"],[1,"num"],[1,"run-message"],[1,"run-actions"],[1,"confirm-box"],[1,"form-error"],["type","button",1,"btn-primary",3,"click"],["type","button",1,"btn-danger",3,"click"],["type","button",3,"click"],[1,"filters"],["role","tablist",1,"type-tabs"],["type","text","placeholder","Filter by zip or place name\u2026","name","search",1,"search-input",3,"ngModelChange","ngModel"],[1,"table-scroll","changes-scroll"],[1,"changes-table"],[3,"row-even"],[1,"type-badge"],[1,"detail-line"],[1,"diff-list"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"CH Postal Code Import"),a(),l(2,"p",0),s(3,"Reviews the monthly swisstopo AMTOVZ sync before anything touches "),l(4,"code"),s(5,"zip_code"),a(),s(6,"."),a(),y(7,S5,2,0,"p",1)(8,q5,9,4)),t&2&&(d(7),_(i.canAccess()?8:7))},dependencies:[ke,Me,Ne,De,Ct],styles:["[_nghost-%COMP%]{display:block;max-width:1100px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem;font-size:.9rem}h2[_ngcontent-%COMP%]{margin:1.5rem 0 .5rem;font-size:1.05rem;color:#555}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.runs-header[_ngcontent-%COMP%]{display:flex;align-items:baseline;justify-content:space-between;gap:1rem}.runs-header[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{margin:0}.table-scroll[_ngcontent-%COMP%]{overflow:auto;position:relative}.runs-scroll[_ngcontent-%COMP%]{max-height:16rem;margin-bottom:1rem}.changes-scroll[_ngcontent-%COMP%]{max-height:60vh}.runs-table[_ngcontent-%COMP%], .changes-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.runs-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .runs-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%], .changes-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .changes-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .6rem;border-bottom:1px solid #eee;text-align:left;vertical-align:top}.runs-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .changes-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{position:sticky;top:0;background:#fff;border-bottom:2px solid #ddd;color:#555}.runs-table[_ngcontent-%COMP%]   .num[_ngcontent-%COMP%], .changes-table[_ngcontent-%COMP%]   .num[_ngcontent-%COMP%]{text-align:right;font-variant-numeric:tabular-nums}.runs-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]{cursor:pointer}.runs-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.runs-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr.selected[_ngcontent-%COMP%]{background:#e8f0fb}.changes-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr.row-even[_ngcontent-%COMP%]{background:#fafbfc}.changes-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.status-badge[_ngcontent-%COMP%]{display:inline-block;padding:.1rem .5rem;border-radius:999px;font-size:.75rem;font-weight:600;text-transform:capitalize;background:#eee;color:#555}.status-pending_review[_ngcontent-%COMP%]{background:#fbf3d9;color:#8a6d00}.status-applied[_ngcontent-%COMP%]{background:#dff2e1;color:#1e7d32}.status-rejected[_ngcontent-%COMP%], .status-failed[_ngcontent-%COMP%], .status-layout_changed[_ngcontent-%COMP%]{background:#fbe1e0;color:#a12b26}.status-unchanged[_ngcontent-%COMP%]{background:#eee;
92color:#777}.type-badge[_ngcontent-%COMP%]{display:inline-block;padding:.05rem .4rem;border-radius:3px;font-size:.75rem;font-weight:700}.type-ADD[_ngcontent-%COMP%]{background:#dff2e1;color:#1e7d32}.type-UPDATE[_ngcontent-%COMP%]{background:#e8f0fb;color:#1a5fb4}.type-DELETE[_ngcontent-%COMP%]{background:#fbe1e0;color:#a12b26}.detail-line[_ngcontent-%COMP%]{color:#666;font-size:.85rem}.diff-list[_ngcontent-%COMP%]{margin:0;padding-left:1.1rem;font-size:.82rem;color:#444}.diff-list[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.1rem 0}.run-detail[_ngcontent-%COMP%]{border-top:1px solid #eee;padding-top:.5rem;margin-top:1rem}.run-message[_ngcontent-%COMP%]{color:#555;font-size:.9rem;margin:0 0 .5rem}.run-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;margin:.5rem 0}.confirm-box[_ngcontent-%COMP%]{background:#f8f9fa;border-radius:8px;padding:.75rem 1rem;font-size:.9rem;margin:.5rem 0}.filters[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:1rem;margin:.75rem 0;flex-wrap:wrap}.type-tabs[_ngcontent-%COMP%]{display:flex;gap:.25rem}.type-tabs[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:999px;padding:.25rem .75rem;font-size:.8rem;cursor:pointer}.type-tabs[_ngcontent-%COMP%]   button.active[_ngcontent-%COMP%]{border-color:#1a5fb4;background:#1a5fb4;color:#fff}.search-input[_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.3rem .6rem;font-size:.85rem;min-width:14rem}.btn-primary[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.btn-primary[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.btn-danger[_ngcontent-%COMP%]{appearance:none;border:1px solid #b3261e;background:#b3261e;color:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.form-error[_ngcontent-%COMP%]{color:#b3261e;font-size:.85rem;margin:.3rem 0}code[_ngcontent-%COMP%]{background:#f0f0f0;border-radius:3px;padding:.05rem .3rem;font-size:.85em}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}.filters[_ngcontent-%COMP%]{flex-direction:column;align-items:stretch}}"]})};var Xd=class e{http=h(Z);listSources(){return this.http.get("/api/postal-code-imports/sources")}runNow(){return this.http.post("/api/postal-code-imports/run-now",{})}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var J5=(e,n)=>n.sourceKey;function K5(e,n){if(e&1){let t=$();l(0,"button",6),M("click",function(){S(t);let o=p();return w(o.runNow())}),s(1),a()}if(e&2){let t=p();v("disabled",t.running()),d(),A(" ",t.running()?"Checking\u2026":"Run now"," ")}}function Y5(e,n){e&1&&(l(0,"p",2),s(1),a()),e&2&&(d(),g(n))}function Z5(e,n){e&1&&(l(0,"p",3),s(1,"Loading import sources\u2026"),a())}function Q5(e,n){e&1&&(l(0,"p",4),s(1,"Only GeoNames team members can view postal code imports."),a())}function X5(e,n){if(e&1&&(l(0,"a",9),s(1),a()),e&2){let t=p().$implicit;v("routerLink",n),d(),g(t.displayName)}}function e4(e,n){if(e&1&&s(0),e&2){let t=p().$implicit;A(" ",t.displayName," ")}}function t4(e,n){e&1&&(l(0,"span",11),s(1,"Running now"),a())}function n4(e,n){if(e&1&&(l(0,"span",14),s(1),a()),e&2){let t=p(2).$implicit;d(),gt(" +",t.lastRun.addedCount," ~",t.lastRun.changedCount," -",t.lastRun.removedCount," ")}}function i4(e,n){if(e&1&&(l(0,"span",12),s(1),a(),y(2,n4,2,3,"span",14)),e&2){let t=p().$implicit,i=p(2);aa("status-"+t.lastRun.status),d(),g(i.statusLabel(t.lastRun.status)),d(),_(t.lastRun.status==="pending_review"?2:-1)}}function o4(e,n){e&1&&(l(0,"span",12),s(1,"Never run"),a())}function r4(e,n){e&1&&(l(0,"a",9),s(1,"review"),a()),e&2&&v("routerLink",n)}function a4(e,n){if(e&1&&(l(0,"tr")(1,"td"),y(2,X5,2,2,"a",9)(3,e4,1,1),a(),l(4,"td",10),s(5),a(),l(6,"td"),s(7),Be(8,"date"),a(),l(9,"td"),s(10),Be(11,"date"),a(),l(12,"td"),y(13,t4,2,0,"span",11)(14,i4,3,4)(15,o4,2,0,"span",12),a(),l(16,"td",13),y(17,r4,2,1,"a",9),a()()),e&2){let t,i,o=n.$implicit,r=p(2);pe("running-row",o.runningNow),d(2),_((t=r.detailRoute(o.sourceKey))?2:3,t),d(3),g(o.cronSchedule),d(2),g(He(8,8,o.nextDueAt,"medium")),d(3),g(o.lastRun!=null&&o.lastRun.startedAt?He(11,11,o.lastRun.startedAt,"medium"):"\u2014"),d(3),_(o.runningNow?13:o.lastRun?14:15),d(4),_((i=r.detailRoute(o.sourceKey))?17:-1,i)}}function s4(e,n){if(e&1&&(l(0,"div",5)(1,"table",7)(2,"thead")(3,"tr")(4,"th"),s(5,"Source"),a(),l(6,"th"),s(7,"Schedule"),a(),l(8,"th"),s(9,"Next due"),a(),l(10,"th"),s(11,"Last run"),a(),l(12,"th"),s(13,"Result"),a(),j(14,"th"),a()(),l(15,"tbody"),I(16,a4,18,14,"tr",8,J5),a()()()),e&2){let t=p();d(16),T(t.sources())}}var eu=class e{dashboardService=h(Xd);auth=h(qe);title=h(H);canAccess=G(()=>Number(this.auth.currentUser()?.userLevel)>100);state=E("loading");sources=E([]);running=E(!1);runNowMessage=E(null);detailRoutes={"swisstopo-amtovz":"/ch-postal-code-import"};constructor(){this.title.setTitle("Postal Code Imports \u2014 GeoNames UI"),this.canAccess()?this.load():this.state.set("error")}detailRoute(n){return this.detailRoutes[n]??null}statusLabel(n){return n?n.replace(/_/g," ").replace(/^./,t=>t.toUpperCase()):"\u2014"}runNow(){this.running.set(!0),this.runNowMessage.set(null),this.dashboardService.runNow().subscribe({next:n=>{this.running.set(!1),this.runNowMessage.set(n.message),this.load()},error:()=>{this.running.set(!1),this.runNowMessage.set("Could not run the check right now.")}})}load(){this.state.set("loading"),this.dashboardService.listSources().subscribe({next:n=>{this.sources.set(n),this.state.set("loaded")},error:()=>this.state.set("error")})}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-postal-code-imports-dashboard-page"]],decls:8,vars:3,consts:[[1,"header-row"],["type","button",1,"btn-primary",3,"disabled"],[1,"run-now-message"],[1,"placeholder"],[1,"not-found"],[1,"table-scroll"],["type","button",1,"btn-primary",3,"click","disabled"],[1,"imports-table"],[3,"running-row"],[3,"routerLink"],[1,"mono"],[1,"status-badge","status-running"],[1,"status-badge"],[1,"actions"],[1,"counts"]],template:function(t,i){if(t&1&&(l(0,"div",0)(1,"h1"),s(2,"Postal Code Imports"),a(),y(3,K5,2,2,"button",1),a(),y(4,Y5,2,1,"p",2)(5,Z5,2,0,"p",3)(6,Q5,2,0,"p",4)(7,s4,18,0,"div",5)),t&2){let o,r;d(3),_(i.state()==="loaded"?3:-1),d(),_((o=i.runNowMessage())?4:-1,o),d(),_((r=i.state())==="loading"?5:r==="error"?6:r==="loaded"?7:-1)}},dependencies:[Ct,W],styles:["[_nghost-%COMP%]{display:block;max-width:900px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0;font-size:1.6rem}.header-row[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:1rem;margin-bottom:1rem}.btn-primary[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.4rem .9rem;font-size:.85rem;cursor:pointer;flex-shrink:0}.btn-primary[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.run-now-message[_ngcontent-%COMP%]{margin:-.5rem 0 1rem;font-size:.85rem;color:#555}.placeholder[_ngcontent-%COMP%], .not-found[_ngcontent-%COMP%]{color:#7
9277;font-size:.9rem}.table-scroll[_ngcontent-%COMP%]{overflow:auto;position:relative}.imports-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.imports-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .imports-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.45rem .6rem;border-bottom:1px solid #eee;text-align:left;vertical-align:middle}.imports-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555}.imports-table[_ngcontent-%COMP%]   .mono[_ngcontent-%COMP%]{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:.8rem;color:#666}.imports-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr.running-row[_ngcontent-%COMP%]{background:#fbf3d9}.imports-table[_ngcontent-%COMP%]   .actions[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{font-size:.8rem}.status-badge[_ngcontent-%COMP%]{display:inline-block;padding:.1rem .5rem;border-radius:999px;font-size:.75rem;font-weight:600;text-transform:capitalize;background:#eee;color:#555}.status-pending_review[_ngcontent-%COMP%]{background:#fbf3d9;color:#8a6d00}.status-applied[_ngcontent-%COMP%]{background:#dff2e1;color:#1e7d32}.status-rejected[_ngcontent-%COMP%], .status-failed[_ngcontent-%COMP%], .status-layout_changed[_ngcontent-%COMP%]{background:#fbe1e0;color:#a12b26}.status-unchanged[_ngcontent-%COMP%]{background:#eee;color:#777}.status-running[_ngcontent-%COMP%]{background:#e8f0fb;color:#1a5fb4}.counts[_ngcontent-%COMP%]{margin-left:.4rem;font-size:.78rem;color:#666;font-variant-numeric:tabular-nums}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var Pr=class e{http=h(Z);getDataSources(){return this.http.get("/api/data-sources")}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var l4=(e,n)=>n.username;function c4(e,n){e&1&&(l(0,"p",0),s(1,"Loading data sources\u2026"),a())}function d4(e,n){e&1&&(l(0,"p",1),s(1,"Could not load data sources right now."),a())}function u4(e,n){if(e&1&&(l(0,"a",4),s(1),a()),e&2){let t=p().$implicit;v("href",t.websiteUrl,Y),d(),g(t.websiteUrl)}}function m4(e,n){if(e&1&&(l(0,"tr",6),j(1,"td"),l(2,"td",7),s(3),a()()),e&2){let t=p(),i=t.$implicit,o=t.$index;pe("row-even",o%2===1),d(3),g(i.licenceText)}}function p4(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),a(),l(3,"td"),s(4),a(),l(5,"td"),s(6),a(),l(7,"td"),y(8,u4,2,2,"a",4),a(),l(9,"td"),s(10),a()(),y(11,m4,4,3,"tr",5)),e&2){let t=n.$implicit,i=n.$index;pe("row-even",i%2===1),d(2),g(t.countryCode),d(2),g(t.username),d(2),g(t.description),d(2),_(t.websiteUrl?8:-1),d(2),g(t.licence),d(),_(t.licenceText?11:-1)}}function f4(e,n){if(e&1&&(l(0,"div",2)(1,"table",3)(2,"thead")(3,"tr")(4,"th"),s(5,"Country"),a(),l(6,"th"),s(7,"Name"),a(),l(8,"th"),s(9,"Description"),a(),l(10,"th"),s(11,"Website"),a(),l(12,"th"),s(13,"Licence"),a()()(),l(14,"tbody"),I(15,p4,12,8,null,null,l4),a()()()),e&2){let t=p();d(15),T(t.sources())}}var tu=class e{dataSources=h(Pr);title=h(H);state=E("loading");sources=E([]);constructor(){this.title.setTitle("GeoNames Data Sources \u2014 GeoNames UI"),this.dataSources.getDataSources().subscribe({next:n=>{this.sources.set(n),this.state.set("loaded")},error:()=>this.state.set("error")})}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-datasources-page"]],decls:5,vars:1,consts:[[1,"placeholder"],[1,"not-found"],[1,"table-scroll"],[1,"sources-table"],["target","_blank","rel","noopener noreferrer",3,"href"],[1,"licence-text-row",3,"row-even"],[1,"licence-text-row"],["colspan","4"]],template:function(t,i){if(t&1&&(l(0,"h1"),s(1,"GeoNames Data Sources"),a(),y(2,c4,2,0,"p",0)(3,d4,2,0,"p",1)(4,f4,17,0,"div",2)),t&2){let o;d(2),_((o=i.state())==="loading"?2:o==="error"?3:o==="loaded"?4:-1)}},styles:["[_nghost-%COMP%]{display:block;max-width:900px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.6rem}.placeholder[_ngcontent-%COMP%], .not-found[_ngcontent-%COMP%]{color:#777;font-size:.9rem}.table-scroll[_ngcontent-%COMP%]{position:relative;max-height:70vh;overflow:auto;scrollbar-width:thin}.sources-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.sources-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .sources-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .6rem;border-bottom:1px solid #eee;text-align:left;vertical-align:top}.sources-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{position:sticky;top:0;background:#fff;border-bottom:2px solid #ddd;color:#555}.sources-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr.row-even[_ngcontent-%COMP%]{background:#fafbfc}.sources-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.sources-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1
92a5fb4;text-decoration:none;word-break:break-all}.sources-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.licence-text-row[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding-top:0;color:#777;font-size:.8rem;font-style:italic;border-bottom:1px solid #eee}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var ts=class e{title=h(H);constructor(){this.title.setTitle("GeoNames Reverse Geocoding Data and Software \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-reverse-geocoding-usa"]],decls:109,vars:0,consts:[[1,"lead"],["routerLink","/maps/us-reverse-geocoder.html"],["routerLink","/commercial-webservices.html"],[1,"ws-section"],["routerLink","/maps/us-reverse-geocoder.html","fragment","findNearestAddress"],["routerLink","/maps/us-reverse-geocoder.html","fragment","findNearestIntersection"],["routerLink","/maps/us-reverse-geocoder.html","fragment","findNearbyStreets"],["routerLink","/services.html"],["action","https://www.paypal.com/cgi-bin/webscr","method","post"],["type","hidden","name","cmd","value","_xclick"],["type","hidden","name","business","value","[email protected]"],["type","hidden","name","item_name","value","reverse geocoding application"],["type","hidden","name","item_number","value","reversegeocoding"],["type","hidden","name","amount","value","2500.00"],["type","hidden","name","no_shipping","value","2"],["type","hidden","name","no_note","value","1"],["type","hidden","name","currency_code","value","USD"],["type","hidden","name","lc","value","GB"],["type","hidden","name","bn","value","PP-BuyNowBF"],["type","image","src","https://www.paypal.com/en_US/i/btn/x-click-but23.gif","alt","Make payments with PayPal - it's fast, free and secure!"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"Reverse Geocoding Data and Software"),a(),l(2,"p",0),s(3," GeoNames street level reverse geocoding for the US is available as "),l(4,"a",1),s(5,"web service"),a(),s(6," either free or in a "),l(7,"a",2),s(8,"commercial"),a(),s(9,` variant with a service level agreement. GeoNames also provides the data and software to run the reverse geocoding inhouse in your own data center and we offer consulting services to help you integrate the functionality in your applications.
93`),a(),l(10,"p"),s(11,` Reverse geocoding is used for vehicle tracking, for location based services and other applications where you have a gps signal with latitude and longitude and want to know information about the address or place this location represents.
94`),a(),l(12,"section",3)(13,"h2"),s(14,"Attributes"),a(),l(15,"p"),s(16,"The following attributes are available:"),a(),l(17,"ul")(18,"li"),s(19,"street"),a(),l(20,"li"),s(21,"street number"),a(),l(22,"li"),s(23,"lat/lng of address and distance to address"),a(),l(24,"li"),s(25,"postal code"),a(),l(26,"li"),s(27,"place name"),a(),l(28,"li"),s(29,"county"),a(),l(30,"li"),s(31,"state"),a(),l(32,"li"),s(33,"additional attributes for the find nearby streets function"),a()()(),l(34,"section",3)(35,"h2"),s(36,"Functions"),a(),l(37,"ul")(38,"li")(39,"a",4),s(40,"find nearest address"),a()(),l(41,"li")(42,"a",5),s(43,"find nearest intersection"),a()(),l(44,"li")(45,"a",6),s(46,"find nearby streets"),a()()(),l(47,"p"),s(48," Price: "),l(49,"strong"),s(50,"2500$"),a(),s(51," (includes data and software) for first installation and "),l(52,"strong"),s(53,"1500$"),a(),s(54," for data/software updates. "),a(),l(55,"p"),s(56,"Requirements: Postgres/Postgis relational database (free open source database), 70GB disk space, 1GB RAM."),a()(),l(57,"section",3)(58,"h2"),s(59,"Software Stack"),a(),l(60,"p"),s(61," The reverse geocoder software is using postgres with the postgis spatial extension and the java tomcat application server. The software is usually running on Linux but may easily be installed on Windows and all other platforms for which postgres/postgis and java is available. "),a()(),l(62,"section",3)(63,"h2"),s(64,"Data"),a(),l(65,"p"),s(66," This solution is based on data provided by the US Census and it is only available for the US. The US Census data is inexpensive with acceptable quality for most applications. "),a()(),l(67,"section",3)(68,"h2"),s(69,"Updates"),a(),l(70,"p"),s(71,"The application is using data from September 2019."),a(),l(72,"p"),s(73,"We will inform users of our reverse geocoder about the availability of new data."),a()(),l(74,"section",3)(75,"h2"),s(76,"Consulting"),a(),l(77,"p"),s(78," We provide "),l(79,"a",7),s(80,"consulting services"),a(),s(81," for clients who wish to integrate reverse geocoding more closely into their application or wish to use additional attributes. "),a()(),l(82,"section",3)(83,"h2"),s(84,"Deliverables"),a(),l(85,"p"),s(86,"The GeoNames reverse geocoder software package includes:"),a(),l(87,"ul")(88,"li"),s(89,"java software (tomcat)"),a(),l(90,"li"),s(91,"postgres/postgis database dump"),a(),l(92,"li"),s(93,"documentation and installation instruction"),a()()(),l(94,"section",3)(95,"h2"),s(96,"Payment"),a(),l(97,"form",8),j(98,"input",9)(99,"input",10)(100,"input",11)(101,"input",12)(102,"input",13)(103,"input",14)(104,"input",15)(105,"input",16)(106,"input",17)(107,"input",18)(108,"input",19),a()())},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem}
94a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:.4rem 0;padding-left:1.2rem;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.3rem 0}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var nu=class e{title=h(H);constructor(){this.title.setTitle("GeoNames Reverse Geocoding Webservices \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-reverse-geocoding-overview"]],decls:109,vars:0,consts:[[1,"lead"],[1,"ws-section"],["routerLink","/export/web-services.html","fragment","findNearbyPostalCodes"],["href","https://www.geonames.org/export/free-geocoding.html","target","_blank","rel","noopener noreferrer"],["routerLink","/export/web-services.html","fragment","findNearbyPlaceName"],["routerLink","/export/web-services.html","fragment","findNearby"],["routerLink","/export/web-services.html","fragment","extendedFindNearby"],["href","https://www.geonames.org/export/wikipedia-webservice.html#findNearbyWikipedia","target","_blank","rel","noopener noreferrer"],["routerLink","/export/web-services.html","fragment","countrycode"],["routerLink","/export/web-services.html","fragment","countrysubdiv"],["routerLink","/export/web-services.html","fragment","ocean"],["routerLink","/export/web-services.html","fragment","neighbourhood"],["href","https://www.geonames.org/export/JSON-webservices.html#weatherJSON","target","_blank","rel","noopener noreferrer"],["routerLink","/maps/addresses.html","fragment","address"],["routerLink","/maps/us-reverse-geocoder.html","fragment","findNearestAddress"],["routerLink","/maps/us-reverse-geocoder.html","fragment","findNearestIntersection"],["routerLink","/maps/us-reverse-geocoder.html","fragment","findNearbyStreets"],["routerLink","/maps/osm-reverse-geocoder.html","fragment","findNearestIntersectionOSM"],["routerLink","/maps/osm-reverse-geocoder.html","fragment","findNearbyStreetsOSM"],["routerLink","/export/web-services.html","fragment","timezone"],["routerLink","/export/web-services.html","fragment","astergdem"],["routerLink","/export/web-services.html","fragment","srtm3"],["routerLink","/export/web-services.html","fragment","gtopo30"],["routerLink","/maps/osm-reverse-geocoder.html","fragment","findNearbyPOIsOSM"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"Reverse Geocoding Webservices"),a(),l(2,"p",0),s(3,` "Reverse Geocoding" is the process of finding an address, toponym or an other type of resource for a given lat/lng pair. GeoNames offers a wide range of reverse geocoding web services.
95`),a(),l(4,"section",1)(5,"ul")(6,"li")(7,"a",2),s(8,"Find nearby postal codes"),a(),s(9,": finds postal codes and place names for the given lat/lng within a given radius ("),l(10,"a",3),s(11,"supported countries"),a(),s(12,")."),a(),l(13,"li")(14,"a",4),s(15,"Find nearby place name"),a(),s(16,": finds populated place names for the given lat/lng within a given radius. Similar to findNearby, but with filter for populated places."),a(),l(17,"li")(18,"a",5),s(19,"Find nearby"),a(),s(20,": finds any toponym for the given lat/lng within a given radius. Similar to findNearbyPlaceName, but without the filter for populated places."),a(),l(21,"li")(22,"a",6),s(23,"extended Find nearby"),a(),s(24,": most detailed information for toponym for the given lat/lng within a given radius (combination of 4 services)."),a(),l(25,"li")(26,"a",7),s(27,"Find nearby Wikipedia articles"),a(),s(28,": finds wikipedia articles for the given lat/lng within a given radius."),a(),l(29,"li")(30,"a",8),s(31,"Country"),a(),s(32,": finds the ISO country code for the given lat/lng."),a(),l(33,"li")(34,"a",9),s(35,"Country Subdivision"),a(),s(36,": finds the country and the administrative subdivison for the given lat/lng."),a(),l(37,"li")(38,"a",10),s(39,"Ocean"),a(),s(40,": finds the ocean or sea for the given lat/lng."),a(),l(41,"li")(42,"a",11),s(43,"Neighbourhood"),a(),s(44,": finds the neighbourhood for the given lat/lng (US cities only)."),a(),l(45,"li")(46,"a",12),s(47,"Weatherstation and weather observation"),a(),s(48,": finds weatherstations and most recent weather observations for the given lat/lng."),a()()(),l(49,"section",1)(50,"h2"),s(51,"Address reverse geocoding (selected countries)"),a(),l(52,"ul")(53,"li")(54,"a",13),s(55,"Address"),a(),s(56,": finds the nearest address for a lat/lng."),a()()(),l(57,"section",1)(58,"h2"),s(59,"US Street level reverse geocoding services"),a(),l(60,"ul")(61,"li")(62,"a",14),s(63,"Find nearest Address"),a(),s(64,": finds the nearest street and address for a given lat/lng pair. (US only)"),a(),l(65,"li")(66,"a",15),s(67,"Find nearest Intersection"),a(),s(68,": finds the nearest street and the next crossing street for a given lat/lng pair. (US only)"),a(),l(69,"li")(70,"a",16),s(71,"Find nearby Streets"),a(),s(72,": finds the nearest street segments for a given lat/lng pair. (US only)"),a()()(),l(73,"section",1)(74,"h2"),s(75,"Global Street level reverse geocoding services (cc by-sa license)"),a(),l(76,"ul")(77,"li")(78,"a",17),s(79,"Find nearest Intersection"),a(),s(80,": finds the nearest street and the next crossing street for a given lat/lng pair."),a(),l(81,"li")(82,"a",18),s(83,"Find nearby Streets"),a(),s(84,": finds the nearest street segments for a given lat/lng pair."),a()()(),l(85,"section",1)(86,"h2"),s(87,"Others"),a(),l(88,"ul")(89,"li")(90,"a",19),s(91,"Timezone"),a(),s(92,": returns the timezone at the given lat/lng."),a(),l(93,"li")(94,"a",20),s(95,"Aster Elevation"),a(),s(96,": returns the Aster elevation (30mx30m)."),a(),l(97,"li")(98,"a",21),s(99,"SRTM3 Elevation"),a(),s(100,": returns the SRTM3 elevation (90mx90m)."),a(),l(101,"li")(102,"a",22),s(103,"GTOPO30 Elevation"),a(),s(104,": return the GTOPO30 elevation (1Kmx1Km)."),a(),l(105,"li")(106,"a",23),s(107,"Points of Interests"),a(),s(108,": returns nearby points of interests (cc by-sa license)."),a()()())},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem}
95a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:.4rem 0;padding-left:1.2rem;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.4rem 0}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};function h4(e,n){e&1&&(l(0,"p",5),s(1,"No address found for that query."),a())}function g4(e,n){e&1&&(l(0,"p",5),s(1,"Could not search for that address right now."),a())}function C4(e,n){if(e&1&&(l(0,"p",6),s(1),a()),e&2){let t,i=p();d(),gt(" Found: ",(t=i.searchResult())==null?null:t.street,"",(t=i.searchResult())!=null&&t.houseNumber?" "+((t=i.searchResult())==null?null:t.houseNumber):"","",(t=i.searchResult())!=null&&t.placename?", "+((t=i.searchResult())==null?null:t.placename):""," ")}}var iu=class e{addressService=h(Wn);title=h(H);latitude=E(37.451);longitude=E(-122.18);zoom=E(15);searchQuery="";searchState=E("idle");searchResult=E(null);constructor(){this.title.setTitle("GeoNames OSM Reverse Geocoder \u2014 GeoNames UI")}onSearchSubmit(n){n.preventDefault();let t=this.searchQuery.trim();t&&(this.searchState.set("loading"),this.addressService.geocode(t).subscribe({next:i=>{this.searchResult.set(i),i?.lat&&i?.lng?(this.latitude.set(Number(i.lat)),this.longitude.set(Number(i.lng)),this.zoom.set(16),this.searchState.set("loaded")):this.searchState.set("not-found")},error:()=>this.searchState.set("error")}))}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-osm-reverse-geocoder-page"]],decls:119,vars:13,consts:[[1,"page-header"],[1,"page-intro"],[1,"search-form",3,"submit"],["type","text","name","q","placeholder","geocode address","aria-label","Search for an address",3,"ngModelChange","ngModel"],["type","submit"],[1,"form-error"],[1,"form-success"],["label","OSM reverse geocoder",3,"latitude","longitude","zoom","showCenterMarker","allowCreate","allowMove","hideFeatureMarkers","addressLookupEnabled","useOsmReverseGeocoder","addressResult","tall"],[1,"map-attribution"],[1,"ws-section"],["id","findNearbyStreetsOSM"],[1,"meta"],[1,"note"],["id","findNearestIntersectionOSM"],["id","findNearbyPOIsOSM"],["routerLink","/maps/us-reverse-geocoder.html"],["routerLink","/export/reverse-geocoding.html"]],template:function(t,i){t&1&&(l(0,"header",0)(1,"h1"),s(2,"OSM Reverse Geocoder"),a(),l(3,"p",1),s(4," Click on the map to view reverse geocoded street names, or search for an address below. Rever
95se geocoding is provided by GeoNames using OpenStreetMap data under a CC BY-SA license. "),a()(),l(5,"form",2),M("submit",function(r){return i.onSearchSubmit(r)}),l(6,"input",3),F("ngModelChange",function(r){return L(i.searchQuery,r)||(i.searchQuery=r),r}),a(),l(7,"button",4),s(8,"geocode"),a()(),y(9,h4,2,0,"p",5)(10,g4,2,0,"p",5)(11,C4,2,3,"p",6),j(12,"app-geo-map",7),l(13,"p",8),s(14,"\xA9 OpenStreetMap contributors, CC BY-SA"),a(),l(15,"section",9)(16,"h2"),s(17,"Reverse Geocoding Webservice"),a(),l(18,"h3",10),s(19,"Find nearby Streets"),a(),l(20,"p"),s(21,"Finds the nearest street segments for a given lat/lng pair."),a(),l(22,"dl",11)(23,"dt"),s(24,"Url"),a(),l(25,"dd")(26,"code"),s(27,"api.geonames.org/findNearbyStreetsOSM?"),a()(),l(28,"dt"),s(29,"Parameters"),a(),l(30,"dd"),s(31,"lat, lng; optional: radius (km), maxRows (default = 10)"),a(),l(32,"dt"),s(33,"Result"),a(),l(34,"dd"),s(35,"returns the nearest street segments for the given latitude/longitude."),a(),l(36,"dt"),s(37,"Example"),a(),l(38,"dd")(39,"code"),s(40,"http://api.geonames.org/findNearbyStreetsOSM?lat=37.451&lng=-122.18&username=demo"),a()()(),l(41,"p",12),s(42," Also available in JSON format: "),l(43,"code"),s(44,"http://api.geonames.org/findNearbyStreetsOSMJSON?lat=37.451&lng=-122.18&username=demo"),a()()(),l(45,"section",9)(46,"h3",13),s(47,"Find nearest Intersection"),a(),l(48,"p"),s(49,"Finds the nearest street and the next crossing street for a given lat/lng pair."),a(),l(50,"dl",11)(51,"dt"),s(52,"Url"),a(),l(53,"dd")(54,"code"),s(55,"api.geonames.org/findNearestIntersectionOSM?"),a()(),l(56,"dt"),s(57,"Parameters"),a(),l(58,"dd"),s(59,"lat, lng; optional: radius (km), maxRows, includeGeoName (includes the nearest geonames feature information)"),a(),l(60,"dt"),s(61,"Result"),a(),l(62,"dd"),s(63,"returns the nearest intersection for the given latitude/longitude."),a(),l(64,"dt"),s(65,"Example"),a(),l(66,"dd")(67,"code"),s(68,"http://api.geonames.org/findNearestIntersectionOSM?lat=37.451&lng=-122.18&username=demo"),a()()(),l(69,"p",12),s(70," Also available in JSON format: "),l(71,"code"),s(72,"http://api.geonames.org/findNearestIntersectionOSMJSON?lat=37.451&lng=-122.18&username=demo"),a()()(),l(73,"section",9)(74,"h3",14),s(75,"Find nearby Points of Interest"),a(),l(76,"p"),s(77,"Finds the nearest points of interest for a given lat/lng pair."),a(),l(78,"dl",11)(79,"dt"),s(80,"Url"),a(),l(81,"dd")(82,"code"),s(83,"api.geonames.org/findNearbyPOIsOSM?"),a()(),l(84,"dt"),s(85,"Parameters"),a(),l(86,"dd"),s(87,"lat, lng; optional: radius (km), maxRows (default = 10)"),a(),l(88,"dt"),s(89,"Result"),a(),l(90,"dd"),s(91,"returns the nearest points of interest for the given latitude/longitude."),a(),l(92,"dt"),s(93,"Example"),a(),l(94,"dd")(95,"code"),s(96,"http://api.geonames.org/findNearbyPOIsOSM?lat=37.451&lng=-122.18&username=demo"),a()()(),l(97,"p",12),s(98," Also available in JSON format: "),l(99,"code"),s(100,"http://api.geonames.org/findNearbyPOIsOSMJSON?lat=37.451&lng=-122.18&username=demo"),a()()(),l(101,"section",9)(102,"h2"),s(103,"License"),a(),l(104,"p"),s(105,"OpenStreetMap data is licensed under Creative Commons Attribution-Share Alike."),a(),l(106,"p",12),s(107," Note: this is in contrast to the other GeoNames webservices, which are licensed under the more liberal Creative Commons Attribution license. "),a()(),l(108,"section",9)(109,"h2"),s(110,"Other Reverse Geocoding Services"),a(),l(111,"p"),s(112," For the US there is a "),l(113,"a",15),s(114,"reverse geocoding service on address level"),a(),s(115,". It is based on US Census data and has more details (zip codes, city names, county names, address numbers, etc) than the OSM service above, and is available under a more liberal CC BY license. "),a(),l(116,"p")(117,"a",16),s(118,"More reverse geocoding webservices"),a()()()),t&2&&(d(6),R("ngModel",i.searchQuery),d(3),_(i.searchState()==="not-found"?9:i.searchState()==="error"?10:i.searchState()==="loaded"&&i.searchResult()?11:-1),d(3),v("latitude",i.latitude())("longitude",i.longitude())("zoom",i.zoom())("showCenterMarker",!1)("allowCreate",!1)("allowMove",!1)("hideFeatureMarkers",!0)("addressLookupEnabled",!0)("useOsmReverseGeocoder",!0)("addressResult",i.searchResult())("tall",!0))},dependencies:[ke,pt,Me,Ne,mt,De,dt,nt,W],styles:[".page-header[_ngcontent-%COMP%]{margin:0 0 1rem}.page-header[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.page-intro[_ngcontent-%COMP%]{margin:0;color:#666;font-size:.92rem}.search-form[_ngcontent-%COMP%]{display:flex;gap:.5rem;margin:1rem 0;max-width:30rem}.search-form[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{flex:1;border:1px solid #d8d8d8;border-radius:4px;padding:.4rem .6rem;font-size:.9rem}.search-form[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.4rem .9rem;font-size:.9rem;cursor:pointer}.form-error[_ngcontent-%COMP%]{color:#b3261e;font-size:.85rem;margin:.3rem 0 1rem}.form-success[_ngcontent-%COMP%]{color:#2e7d32;font-size:.85rem;margin:.3rem 0 1rem}.map-attribution[_ngcontent-%COMP%]{margin:.3rem 0 0;color:#999;font-size:.75rem}.map-attribution[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:inherit}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee;margin-top:1rem}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%]{font-size:.85rem;text-transform:uppercase;letter-spacing:.03em;
95color:#777;margin:.5rem 0 .3rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.meta[_ngcontent-%COMP%]{margin:.5rem 0;font-size:.85rem}.meta[_ngcontent-%COMP%]   dt[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;color:#777;margin-top:.4rem}.meta[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]{margin:.1rem 0 0}.meta[_ngcontent-%COMP%]   code[_ngcontent-%COMP%], .note[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:#f8f9fa;padding:.05rem .35rem;border-radius:3px;font-size:.85em;word-break:break-all}.note[_ngcontent-%COMP%]{color:#777;font-size:.82rem}"]})};function _4(e,n){if(e&1&&(l(0,"li"),s(1),a()),e&2){let t=n.$implicit;d(),g(t)}}function v4(e,n){if(e&1&&(l(0,"li"),s(1),a()),e&2){let t=n.$implicit;d(),g(t)}}function y4(e,n){if(e&1&&(l(0,"li"),s(1),a()),e&2){let t=n.$implicit;d(),g(t)}}var ou=class e{title=h(H);orderUrl="https://www.geonames.org/orderpremiumdata/";downloadUrl="https://www.geonames.org/premiumdata/";attributes=["country code : iso country code, 2 characters","postal code : varchar(20)","place name : varchar(180)","admin name1 : 1. order subdivision (state) varchar(100)","admin code1 : 1. order subdivision (state) varchar(20)","admin name2 : 2. order subdivision (county/province) varchar(100)","admin code2 : 2. order subdivision (county/province) varchar(20)","admin name3 : 3. order subdivision (community) varchar(100)","admin code3 : 3. order subdivision (community) varchar(20)","latitude : estimated latitude (wgs84)","longitude : estimated longitude (wgs84)","accuracy : accuracy of lat/lng from 1=estimated to 6=centroid","geoNameId : the geonameId of the feature associated with the place (where available)","timezoneId : the iana timezoneid (previously called olson timezone)","isPOBox : true when the postal code is exclusively used for po boxes","admin1geonameid : the geonameId of the corresponding ADM1","admin2geonameid : the geonameId of the corresponding ADM2","admin3geonameid : the geonameId of the corresponding ADM3","admin4geonameid : the geonameId of the corresponding ADM4","place name ascii : ascii transliteration of placename"];datafiles=["allCountries.zip","allCountries_OLD.zip","postalcodeboundingbox.zip"];aliases=["CAP = codice di avviamento postale","CEP = c\xF3digo de endere\xE7amento postal","Eircode","NPA = num\xE9ro postal d'acheminement","PIN = Postal Index Number","PLZ = Postleitzahl","PSC = Po\u0161tov\xE9 smerovacie \u010D\xEDslo / Po\u0161tovn\xED sm\u011Brovac\xED \u010D\xEDslo","ZIP = Zone Improvement Plan"];constructor(){this.title.setTitle("GeoNames Premium Postal Code Data Subscription \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-premium-postalcodes"]],decls:63,vars:3,consts:[[1,"lead"],["routerLink","/commercial-webservices.html"],[1,"ws-section"],["target","_blank","rel","nofollow noopener noreferrer",1,"buy-btn",3,"href"],["target","_blank","rel","noopener noreferrer",3,"href"],["href","mailto:[email protected]"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"Monthly Premium Postal Code Data Subscription"),a(),l(2,"p",0),s(3,` Many countries use postal codes as part of postal addresses to sort mail. They are required for valid postal addresses and, as such, have a geographical significance, making them part of geonames.
96`),a(),l(4,"p"),s(5,` The premium postal code subscription is a monthly data feed of our postal code dataset, covering about 120 countries. This dataset is integrated with the gazetteer dataset and follows the same release cycle. The administrative hierarchy is linked to the corresponding gazetteer feature via the geoname ID. The dataset also includes the geoname ID of the place name, where available. This is typically a populated place, but it may also be an administrative division, a valley, or another type of region. In some cases, no counterpart exists in the gazetteer because the name is an artificial construct used solely for postal purposes.
97`),a(),l(6,"p"),s(7,` Postal codes are defined by national postal services and may vary significantly in granularity from country to country. The highest density of postal codes is found in Canada (CA), the United Kingdom (GB), and the Netherlands (NL). For these countries, we have split the download into two files: the standard country file, which includes the first part of the code comparable in granularity to other countries, and a second file called xx_full, which contains the full dataset.
98`),a(),l(8,"p"),s(9," The Premium Data allows you to implement your own code directly on the data, if you are interested in the GeoNames webservices the "),l(10,"a",1),s(11,"premium webservices"),a(),s(12,` are the right choice.
99`),a(),l(13,"section",2)(14,"h2"),s(15,"Price"),a(),l(16,"p"),s(17," The annual subscription to the Premium Data is available for only "),l(18,"strong"),s(19,"600 \u20AC"),a(),s(20," for a 12 month period with 12 releases and can be paid via PayPal or bank transfer. "),a(),l(21,"a",3),s(22,"Buy now"),a()(),l(23,"section",2)(24,"h2"),s(25,"Other names for postal codes"),a(),l(26,"ul"),I(27,_4,2,1,"li",null,Re),a()(),l(29,"section",2)(30,"h2"),s(31,"Value for Subscribers"),a(),l(32,"h3"),s(33,"Coherent and Verified Data"),a(),l(34,"p"),s(35," We run a great number of consistency checks to make sure the quality of the data improves from one release to the next and no inconsistencies are added to the data. We also monitor modifications and manually verify changes and updates for relevant toponyms. The monitoring helps us find errors added to the database and remove and fix them before we release the premium dump. "),a(),l(36,"h3"),s(37,"Datafiles"),a(),l(38,"ul"),I(39,v4,2,1,"li",null,Re),a(),l(41,"h3"),s(42,"Attributes"),a(),l(43,"ul"),I(44,y4,2,1,"li",null,Re),a(),l(46,"h3"),s(47,"Download"),a(),l(48,"p"),s(49," Subscribers to the Premium Data Subscription can "),l(50,"a",4),s(51,"download"),a(),s(52," the data files for all months of their subscription period "),l(53,"a",4),s(54,"here"),a(),s(55,". "),a()(),l(56,"section",2)(57,"h2"),s(58,"Contact"),a(),l(59,"p"),s(60,"Contact: "),l(61,"a",5),s(62,"[email protected]"),a()()()),t&2&&(d(21),v("href",i.orderUrl,Y),d(6),T(i.aliases),d(12),T(i.datafiles),d(5),T(i.attributes),d(6),v("href",i.downloadUrl,Y),d(3),v("href",i.downloadUrl,Y))},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem}a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%]{font-size:.9rem;margin:1rem 0 .3rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:.4rem 0;padding-left:1.2rem;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.2rem 0}.buy-btn[_ngcontent-%COMP%]{display:inline-block;appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff!important;border-radius:4px;padding:.4rem .9rem;font-size:.88rem;text-decoration:none!important;margin-top:.5rem}.buy-btn[_ngcontent-%COMP%]:hover{background:#164d92}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var ru=class e{http=h(Z);getHistory(n){return this.http.get(`/api/geoname-history/${encodeURIComponent(n)}`)}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var b4=(e,n)=>n.revision;function x4(e,n){e&1&&(l(0,"p",0),s(1,"Loading edit history\u2026"),a())}function S4(e,n){e&1&&(l(0,"p",1),s(1,"Could not load edit history right now."),a())}function w4(e,n){if(e&1&&(l(0,"a",2),s(1),a()),e&2){let t=p(3);v("routerLink",t.placePath()),d(),g(t.entries()[0].name)}}function E4(e,n){if(e&1&&s(0),e&2){let t=p(3);A(" ",t.entries()[0].name," ")}}function M4(e,n){e&1&&(l(0,"th"),s(1,"Undo"),a())}function P4(e,n){e&1&&(l(0,"a",2),s(1,"map"),a()),e&2&&v("routerLink",n)}function D4(e,n){e&1&&(l(0,"td",4),s(1,"\u2014"),a())}function I4(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),a(),l(3,"td"),s(4),Be(5,"date"),a(),l(6,"td")(7,"a",2),s(8),a()(),l(9,"td"),s(10),a(),l(11,"td"),y(12,P4,2,1,"a",2),a(),y(13,D4,2,0,"td",4),a()),e&2){let t,i=n.$implicit,o=p(3);d(2),g(i.revision),d(2),g(He(5,7,i.modificationTime,"yyyy MM dd HH:mm:ss")),d(3),v("routerLink",o.userPath(i.username)),d(),g(i.username),d(2),g(i.comment),d(2),_((t=o.mapPath(i))?12:-1,t),d(),_(o.showUndoColumn()?13:-1)}}function T4(e,n){if(e&1&&(l(0,"h1"),s(1," Edit History for "),y(2,w4,2,2,"a",2)(3,E4,1,1),a(),l(4,"table",3)(5,"thead")(6,"tr")(7,"th"),s(8,"Rev"),a(),l(9,"th"),s(10,"Time"),a(),l(11,"th"),s(12,"User"),a(),l(13,"th"),s(14,"Comment"),a(),l(15,"th"),s(16,"lat/lng"),a(),y(17,M4,2,0,"th"),a()(),l(18,"tbody"),I(19,I4,14,10,"tr",null,b4),a()()),e&2){let t=p(2);d(2),_(t.placePath()?2:3),d(15),_(t.showUndoColumn()?17:-1),d(2),T(t.entries())}}function O4(e,n){e&1&&(l(0,"p",0),s(1,"No edit history found for this place."),a())}function N4(e,n){if(e&1&&y(0,T4,21,2)(1,O4,2,0,"p",0),e&2){let t=p();_(t.entries().length?0:1)}}var au=class e{route=h(ve);historyService=h(ru);places=h(tt);auth=h(qe);title=h(H);geonameId=E("");state=E("loading");entries=E([]);placePath=G(()=>{let n=this.entries()[0];return n?this.places.path({id:this.geonameId(),name:n.name}):null});showUndoColumn=G(()=>{let n=Number(this.auth.currentUser()?.userLevel);return Number.isFinite(n)&&n>10});constructor(){this.route.paramMap.pipe(N(n=>n.get("id")??"")).subscribe(n=>{this.geonameId.set(n),this.load(n)})}mapPath(n){return n.latitude==null||n.longitude==null?null:`/maps/browse_${n.latitude}_${n.longitude}.html`}userPath(n){return`/recent-changes/user/${encodeURIComponent(n)}`}load(n){this.state.set("loading"),this.historyService.getHistory(n).subscribe({next:t=>{this.entries.set(t),this.state.set("loaded"),this.title.setTitle(t[0]?`Edit History for ${t[0].name} \u2014 GeoNames UI`:"Edit History \u2014 GeoNames UI")},error:()=>this.state.set("error")})}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-history-detail-page"]],decls:3,vars:1,consts:[[1,"placeholder"],[1,"placeholder","error"],[3,"routerLink"],[1,"history-table"],[1,"undo-cell"]],template:function(t,i){if(t&1&&y(0,x4,2,0,"p",0)(1,S4,2,0,"p",1)(2,N4,2,1),t&2){let o;_((o=i.state())==="loading"?0:o==="error"?1:o==="loaded"?2:-1)}},dependencies:[Ct,W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.4rem}
99h1[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}h1[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.history-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.history-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .history-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.4rem .6rem;border-bottom:1px solid #eee;text-align:left}.history-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555}.history-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.history-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.undo-cell[_ngcontent-%COMP%]{color:#bbb;text-align:center}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var su=class e{title=h(H);constructor(){this.title.setTitle("About GeoNames \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-about-page"]],decls:244,vars:0,consts:[[1,"lead"],["href","https://www.geonames.org/export/codes.html","target","_blank","rel","noopener noreferrer"],["routerLink","/statistics"],["routerLink","/export","fragment","ws"],["routerLink","/export","fragment","dump"],[1,"density-map"],["href","https://geonames.wordpress.com/2006/12/07/geonames-feature-density-map/","target","_blank","rel","noopener noreferrer"],["src","https://www.geonames.org/img/500px-GeonamesDensity.png","alt","Feature Density Map"],[1,"ws-section"],["href","https://www.geonames.org/donations.html","target","_blank","rel","noopener noreferrer"],["id","presscoverage",1,"ws-section"],["href","https://web.archive.org/web/20220814215157/http://www.programmableweb.com/news/123-database-apis-geonames-freebase-and-yahoo-query-language/2012/05/23","target","_blank","rel","noopener noreferrer"],["href","https://www.techcrunch.com/2007/05/26/geonames-wikipedia-for-geographical-data/","target","_blank","rel","noopener noreferrer"],["href","http://www.linuxworld.com/news/2006/121806-web-20-apis.html?page=2","target","_blank","rel","noopener noreferrer"],["href","http://www.nature.com/news/2006/060213/full/439787a.html","target","_blank","rel","noopener noreferrer"],["href","http://google.dirson.com/noticias.new/2364/","target","_blank","rel","noopener noreferrer"],["href","http://barrapunto.com/ciberderechos/06/03/03/1814255.shtml","target","_blank","rel","noopener noreferrer"],[1,"note"],["href","https://www.geonames.org/links.html#blogs","target","_blank","rel","noopener noreferrer"],["href","http://geonames.nga.mil/gns/html/index.html","target","_blank","rel","noopener noreferrer"],["href","http://geonames.usgs.gov/index.html","target","_blank","rel","noopener noreferrer"],["href","http://www.ordnancesurvey.co.uk/oswebsite/opendata/index.html","target","_blank","rel","noopener noreferrer"],["href","http://www.nationalarchives.gov.uk/doc/open-government-licence/","target","_blank","rel","noopener noreferrer"],["href","http://geogratis.gc.ca/api/en/nrcan-rncan/ess-sst/-/%28urn:iso:series%29geobase-canadian-geographical-names?sort-field=relevance","target","_blank","rel","noopener noreferrer"],["routerLink","/datasources"],["routerLink","/manual.html"],["routerLink","/recent-changes.html"],["href","http://www.apple.com/macosx/","target","_blank","rel","noopener noreferrer"],["href","http://news.softpedia.com/news/Ubuntu-10-10-Will-Have-a-Revamped-Installer-146644.shtml","target","_blank","rel","noopener noreferrer"],["href","http://upload.maps.bing.com/Help/en-us/About.htm","target","_blank","rel","noopener noreferrer"],["href","http://geonames.wordpress.com/2007/05/18/geonames-does-geocoding-for-popfly/","target","_blank","rel","noopener noreferrer"],["href","http://geonames.wordpress.com/2007/09/13/multimap-is-integrating-geonames/","target","_blank","rel","noopener noreferrer"],["href","http://www.adidas.com/campaigns/verticalsrunning/content/fw07/com/index.asp","target","_blank","rel","noopener noreferrer"],["href","http://nikeplus.nike.com/nikeplus/index.jhtml","target","_blank","rel","noopener noreferrer"],["href","http://www.esri.com","target","_blank","rel","noopener noreferrer"],["href","http://www.digitalglobe.com","target","_blank","rel","noopener noreferrer"],["href","http://www.spotimage.com","target","_blank","rel","noopener noreferrer"],["href","http://geonames.wordpress.com/2010/01/18/new-york-times-data-api-with-geonames/","target","_blank","rel","noopener noreferrer"],["href","http://www.bbc.co.uk","target","_blank","rel","noopener noreferrer"],["href","http://www.yr.no/","target","_blank","rel","noopener noreferrer"],["href","http://km42.spiegel.de/home/index.php","target","_blank","rel","noopener noreferrer"],["href","http://earthquake.usgs.gov/","target","_blank","rel","noopener noreferrer"],["href","http://www.slide.com/","target","_blank","rel","noopener noreferrer"],["href","http://conversations.nokia.com/2011/07/04/the-world-in-your-hands-with-nokia-3d-world-gaze/","target","_blank","rel","noopener noreferrer"],["href","https://www.geonames.org/users.html","target","_blank","rel","noopener noreferrer"],["href","https://forum.geonames.org","target","_blank","rel","noopener noreferrer"],["href","https://groups.google.com/group/geonames","target","_blank","rel","noopener noreferrer"],["href","http://groups.google.com/group/geonames","target","_blank","rel","noopener noreferrer"],["href","https://geonames.wordpress.com/","target","_blank","rel","noopener noreferrer"],["routerLink","/export/client-libraries.html"],["href","mailto:[email protected]"],["href","https://www.unxos.com","target","_blank","rel","noopener noreferrer"],["href","https://creativecommons.org/licenses/by/4.0/","target","_blank","rel","noopener noreferrer"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"About GeoNames"),a(),l(2,"p",0),s(3," The GeoNames geographical database is available for download free of charge under a creative commons attribution license. It contains over 25 million geographical names and consists of over 12 million unique features whereof 4.8 million populated places and 16 million alternate names. All features are categorized 
99into one out of nine feature classes and further subcategorized into one out of 645 "),l(4,"a",1),s(5,"feature codes"),a(),s(6,". ("),l(7,"a",2),s(8,"more statistics ..."),a(),s(9,`)
100`),a(),l(10,"p"),s(11," The data is accessible free of charge through a number of "),l(12,"a",3),s(13,"webservices"),a(),s(14," and a daily "),l(15,"a",4),s(16,"database export"),a(),s(17,`.
101`),a(),l(18,"p"),s(19,` GeoNames is integrating geographical data such as names of places in various languages, elevation, population and others from various sources. All lat/long coordinates are in WGS84 (World Geodetic System 1984). Users may manually edit, correct and add new names using a user friendly wiki interface.
102`),a(),l(20,"figure",5)(21,"a",6),j(22,"img",7),a(),l(23,"figcaption"),s(24," Figure : GeoNames "),l(25,"a",6),s(26,"Feature Density Map"),a()()(),l(27,"section",8)(28,"h2"),s(29,"Support GeoNames"),a(),l(30,"p"),s(31," We accept "),l(32,"a",9),s(33,"donations"),a(),s(34,". "),a()(),l(35,"section",10)(36,"h2"),s(37,"Press Coverage and Quotations"),a(),l(38,"ul")(39,"li")(40,"a",11),s(41,"Programmableweb 23 May 2012 - GeoNames most popular API"),a()(),l(42,"li")(43,"a",12),s(44,"TechCrunch 26 May 2007"),a()(),l(45,"li")(46,"a",13),s(47,"Linuxworld Dec 2006"),a(),s(48,' put geonames.org on a list of "Ten Web 2.0 APIs you can really use", just behind googlmaps : '),l(49,"em"),s(50,"The GeoNames database is one of the best available, based on multiple data sets, and it uses a liberal Creative Commons Attribution license for its data output. It's also quick and responsive."),a()(),l(51,"li"),s(52,"Sir Tim Berners-Lee : "),l(53,"em"),s(54,"This is a tremendous set of data you have there."),a()(),l(55,"li")(56,"a",14),s(57,"Nature 13. Feb 2006"),a(),s(58," : "),l(59,"em"),s(60,"... we hope that database providers will support initiatives, such as the GeoNames Forum."),a()(),l(61,"li")(62,"a",15),s(63,"google.dirson.com 25. Feb 2006"),a(),s(64," : "),l(65,"em"),s(66,"... una de las mejores herramientas que hemos visto uniendo 'Google Maps' y Ajax."),a()(),l(67,"li")(68,"a",16),s(69,"barrapunto.com 3. March 2006"),a(),s(70," : "),l(71,"em"),s(72,"... GeoNames los ha organizado en una base de datos brillante y abierta y, adem\xE1s corregible"),a()()(),l(73,"p",17)(74,"a",18),s(75,"more blogs ..."),a()()(),l(76,"section",8)(77,"h2"),s(78,"Most important sources"),a(),l(79,"ul")(80,"li")(81,"a",19),s(82,"nga"),a(),s(83," : National Geospatial-Intelligence Agency's (NGA) and the U.S. Board on Geographic Names "),a(),l(84,"li")(85,"a",20),s(86,"gnis"),a(),s(87," : U.S. Geological Survey Geographic Names Information System (names in US). "),a(),l(88,"li")(89,"a",21),s(90,"Ordnance Survey OpenData"),a(),j(91,"br"),s(92," gazetteer: Contains Ordnance Survey data Crown copyright and database right 2010."),j(93,"br"),s(94," gazetteer: Contains "),l(95,"a",22),s(96,"public sector information"),a(),s(97," licensed under the Open Government Licence v1.0."),j(98,"br"),s(99," postal codes: Contains Royal Mail data Royal Mail copyright and database right 2010. "),a(),l(100,"li")(101,"a",23),s(102,"GeoBase - Canadian Geographical Names"),a(),s(103," (names in CA) "),a(),l(104,"li"),s(105,"gtopo30 (elevation)"),a()(),l(106,"p",17)(107,"a",24),s(108,"more data sources ..."),a()()(),l(109,"section",8)(110,"h2"),s(111,"Features for online users"),a(),l(112,"ul")(113,"li"),s(114,"search for names with our fulltextsearch (table based or displayed on map)"),a(),l(115,"li"),s(116,"browse capitals, highest mountains and largest cities on map"),a(),l(117,"li"),s(118,"browse names on map and show/hide feature classes and codes"),a(),l(119,"li"),s(120,"bookmark maps"),a(),l(121,"li"),s(122,"send maps via email"),a(),l(123,"li"),s(124,"export names as character separated values (csv) file or as png image"),a(),l(125,"li"),s(126,"edit names (wiki)"),a(),l(127,"li"),s(128,"add new names to the database (for registered users)"),a(),l(129,"li"),s(130,"geotagging of names (for registered users)"),a()()(),l(131,"section",8)(132,"h2"),s(133,"Wiki"),a(),l(134,"p"),s(135," In order to allow users to improve and correct data browser based update possibilities are available. The update rights of the anonymous (not logged in) user are restricted and records may be locked for update depending on the userlevel. ("),l(136,"a",25),s(137,"user manual"),a(),s(138,") "),a(),l(139,"p"),s(140,"The most "),l(141,"a",26),s(142,"recent changes"),a(),s(143," are available "),l(144,"a",26),s(145,"here"),a(),s(146,"."),a()(),l(147,"section",8)(148,"h2"),s(149,"GeoNames Users"),a(),l(150,"ul")(151,"li")(152,"a",27),s(153,"Apple SnowLeopard"),a(),s(154,", "),l(155,"a",28),s(156,"
102Ubuntu"),a()(),l(157,"li")(158,"a",29),s(159,"Bing Maps"),a(),s(160,", "),l(161,"a",30),s(162,"Microsoft Popfly"),a(),s(163,", "),l(164,"a",31),s(165,"Multimap"),a()(),l(166,"li")(167,"a",32),s(168,"Adidas"),a(),s(169," and "),l(170,"a",33),s(171,"Nike"),a()(),l(172,"li")(173,"a",34),s(174,"ESRI"),a(),s(175,", "),l(176,"a",35),s(177,"DigitalGlobe"),a(),s(178," and "),l(179,"a",36),s(180,"Spot Image"),a()(),l(181,"li")(182,"a",37),s(183,"New York Times"),a(),s(184,", "),l(185,"a",38),s(186,"BBC"),a(),s(187,", "),l(188,"a",39),s(189,"Norwegian Broadcasting Corp"),a(),s(190,", "),l(191,"a",40),s(192,"km42 Spiegel Online"),a()(),l(193,"li")(194,"a",41),s(195,"US Geological Survey"),a()(),l(196,"li")(197,"a",42),s(198,"slide.com"),a()(),l(199,"li")(200,"a",43),s(201,"Nokia"),a()()(),l(202,"p",17)(203,"a",44),s(204,"more users ..."),a()()(),l(205,"section",8)(206,"h2"),s(207,"GeoNames Messageboard, Mailinglist and Blog"),a(),l(208,"ul")(209,"li")(210,"a",45),s(211,"GeoNames messageboard"),a()(),l(212,"li")(213,"a",46),s(214,"GeoNames mailing list"),a(),s(215," : "),l(216,"a",47),s(217,"[email protected]"),a()(),l(218,"li")(219,"a",48),s(220,"GeoNames Blog"),a()()()(),l(221,"section",8)(222,"h2"),s(223,"GeoNames Webservice Clients and Plugins"),a(),l(224,"p")(225,"a",49),s(226,"Client libraries"),a(),s(227," developed by the community are available in a number of programming languages such as Java, Ruby, Python, Perl and even Lisp. "),a()(),l(228,"section",8)(229,"p"),s(230,"GeoNames was founded by Marc Wick. You can reach him at "),l(231,"a",50),s(232,"[email protected]"),a(),s(233,"."),a(),l(234,"p"),s(235," GeoNames is a project of "),l(236,"a",51),s(237,"Unxos GmbH"),a(),s(238,", Tutilostrasse 17d, 9011 St. Gallen, Switzerland. "),a(),l(239,"p",17),s(240," This work is licensed under a "),l(241,"a",52),s(242,"Creative Commons Attribution 4.0 License"),a(),s(243,". "),a()())},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem}p[_ngcontent-%COMP%]{font-size:.92rem;line-height:1.5}a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.density-map[_ngcontent-%COMP%]{margin:1.5rem 0;text-align:center}.density-map[_ngcontent-%COMP%]   img[_ngcontent-%COMP%]{max-width:100%;border-radius:4px}.density-map[_ngcontent-%COMP%]   figcaption[_ngcontent-%COMP%]{margin-top:.4rem;color:#777;font-size:.8rem}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0}.ws-section[_ngcontent-%COMP%]   ul[_ngcontent-%COMP%]{margin:.4rem 0;padding-left:1.2rem;font-size:.9rem}.ws-section[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{margin:.4rem 0}.note[_ngcontent-%COMP%]{color:#777;font-size:.82rem}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var k4=(e,n)=>n.code;function A4(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),a(),l(3,"td",9),s(4),a()()),e&2){let t=n.$implicit;d(2),g(t.code),d(2),g(t.count.toLocaleString())}}var lu=class e{title=h(H);orderUrl="https://www.geonames.org/orderpremiumdata/";sampleUrl="https://download.geonames.org/shape_sample.zip";downloadUrl="https://www.geonames.org/premiumdump/";featureCounts=[{count:159753,code:"PPL"},{count:129108,code:"ADM3"},{count:106110,code:"ADM4"},{count:46387,code:"LK"},{count:39949,code:"ISL"},{count:38528,code:"ADM2"},{count:26874,code:"PPLX"},{count:19262,code:"HSE"},{count:12953,code:"ADM5"},{count:12214,code:"ADMD"},{count:10467,code:"PPLA3"},{count:7425,code:"PPLL"},{count:6078,code:"PPLA2"},{count:4591,code:"PPLA4"},{count:3768,code:"ADM1"},{count:3246,code:"ADM3H"},{count:2267,code:"BAY"},{count:2166,code:"ADM4H"},{count:967,code:"RGNE"},{count:903,code:"GLCR"},{count:552,code:"ADM2H"},{count:525,code:"PPLA"},{count:455,code:"RGN"},{count:390,code:"HSP"},{count:193,code:"PCLI"},{count:155,code:"RESV"},{count:150,code:"LKI"}
102,{count:110,code:"ADM1H"},{count:77,code:"SEA"},{count:65,code:"ISLS"},{count:55,code:"ZOO"},{count:47,code:"VAL"},{count:46,code:"AIRF"},{count:38,code:"LKN"},{count:36,code:"AIRP"},{count:36,code:"CST"},{count:35,code:"PCLD"},{count:34,code:"GULF"},{count:33,code:"AREA"},{count:30,code:"PND"},{count:28,code:"STRT"},{count:26,code:"PPLC"},{count:24,code:"PPLQ"},{count:20,code:"AIRH"},{count:18,code:"PNDI"},{count:18,code:"AIRB"},{count:17,code:"LKX"},{count:15,code:"MTS"},{count:14,code:"LCTY"},{count:12,code:"CHN"},{count:12,code:"PPLA5"},{count:11,code:"RESW"},{count:10,code:"RF"},{count:10,code:"LGN"},{count:10,code:"RSV"},{count:10,code:"SWMP"},{count:10,code:"ZN"}];constructor(){this.title.setTitle("GeoNames Premium Data Subscription: Polygons \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-premium-data-polygons"]],decls:76,vars:4,consts:[[1,"lead"],["routerLink","/products/premium-data.html"],["routerLink","/commercial-webservices.html"],[1,"ws-section"],["target","_blank","rel","nofollow noopener noreferrer",1,"buy-btn",3,"href"],[1,"table-scroll"],[1,"counts-table"],["target","_blank","rel","noopener noreferrer",3,"href"],["href","mailto:[email protected]"],[1,"num"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"Monthly Premium Data Subscription: Polygons"),a(),l(2,"p",0),s(3," The premium polygon subscription is an optional add on to the "),l(4,"a",1),s(5,"premium data subscription"),a(),s(6,`. It can also be bought independently of the premium data subscription. If it is used without the premium data subscription the free data can be used for the gazetteer attributes.
103`),a(),l(7,"p"),s(8," The "),l(9,"a",1)(10,"strong"),s(11,"GeoNames Monthly Premium Data"),a()(),s(12,` is a high quality release that has passed a huge number of consistency checks. The modifications and differences to the previous data release have been monitored and verified by members of the GeoNames team. The Monthly Premium Data is an excellent choice for enterprise users. Applications using the Premium Data can reduce their own consistency checks and let the GeoNames team do this job.
104`),a(),l(13,"p"),s(14,"The Premium Data Subscription covers the toponyms, the postal code files are not yet available as premium offering."),a(),l(15,"p"),s(16," The Premium Data allows you to implement your own code directly on the data, if you are interested in the GeoNames webservices the "),l(17,"a",2),s(18,"premium webservices"),a(),s(19,` are the right choice.
105`),a(),l(20,"section",3)(21,"h2"),s(22,"Price"),a(),l(23,"p"),s(24," The polygon option for the premium data subscription is available for only "),l(25,"strong"),s(26,"2000 \u20AC"),a(),s(27," for a 12 month period with 12 releases and can be paid via PayPal or bank transfer. "),a(),l(28,"a",4),s(29,"Buy now"),a()(),l(30,"section",3)(31,"h2"),s(32,"Value for Subscribers"),a(),l(33,"h3"),s(34,"Features with polygons"),a(),l(35,"p"),s(36," Polygons are available mainly for admin divisions. Additionally also for other features like islands, lakes and populated places. The availability depends on the availability of the original datasource. For Italy for instance the national statical office publishes polygons for populated places. In most other countries support for polygons by the national mapping agency is restricted to administrative divisions. "),a(),l(37,"div",5)(38,"table",6)(39,"thead")(40,"tr")(41,"th"),s(42,"Feature code"),a(),l(43,"th"),s(44,"Polygons"),a()()(),l(45,"tbody"),I(46,A4,5,2,"tr",null,k4),a()()(),l(48,"h3"),s(49,"Data formats"),a(),l(50,"p"),s(51," The polygon information is available in flat files with the geonameid and the corresponding polygon in geojson format. The projection is WGS84. "),a(),l(52,"h3"),s(53,"Sample"),a(),l(54,"p"),s(55,"A small "),l(56,"a",7),s(57,"sample"),a(),s(58," subset is available."),a(),l(59,"h3"),s(60,"Download"),a(),l(61,"p"),s(62," Subscribers to the Premium Data Subscription can "),l(63,"a",7),s(64,"download"),a(),s(65," the data for all months of their subscription period "),l(66,"a",7),s(67,"here"),a(),s(68,". "),a()(),l(69,"section",3)(70,"h2"),s(71,"Contact"),a(),l(72,"p"),s(73,"Contact: "),l(74,"a",8),s(75,"[email protected]"),a()()()),t&2&&(d(28),v("href",i.orderUrl,Y),d(18),T(i.featureCounts),d(10),v("href",i.sampleUrl,Y),d(7),v("href",i.downloadUrl,Y),d(3),v("href",i.downloadUrl,Y))},dependencies:[W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem}
105a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}a[_ngcontent-%COMP%]:hover{text-decoration:underline}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.ws-section[_ngcontent-%COMP%]   h3[_ngcontent-%COMP%]{font-size:.95rem;margin:1.1rem 0 .4rem}.ws-section[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:.4rem 0;font-size:.9rem}.buy-btn[_ngcontent-%COMP%]{display:inline-block;appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff!important;border-radius:4px;padding:.4rem .9rem;font-size:.88rem;text-decoration:none!important;margin-top:.5rem}.buy-btn[_ngcontent-%COMP%]:hover{background:#164d92}.table-scroll[_ngcontent-%COMP%]{position:relative;max-height:22rem;overflow:auto;scrollbar-width:thin;border:1px solid #eee;border-radius:6px;margin-top:.75rem}.counts-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.counts-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .counts-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .7rem;border-bottom:1px solid #eee;text-align:left}.counts-table[_ngcontent-%COMP%]   td.num[_ngcontent-%COMP%], .counts-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]:last-child{text-align:right;font-variant-numeric:tabular-nums}.counts-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{position:sticky;top:0;background:#fff;border-bottom:2px solid #ddd;color:#555}.counts-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.counts-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var Kn=class e{http=h(Z);get(n){return this.http.get(`/api/postal-codes/${encodeURIComponent(n)}`)}getShape(n){return this.http.get(`/api/postal-codes/${encodeURIComponent(n)}/shape`).pipe(Ze(t=>t.status===404?Q(null):zt(()=>t)))}move(n,t,i,o){return this.http.put(`/api/postal-codes/${encodeURIComponent(n)}/move`,{lat:t,lng:i,comment:o})}getHistory(n){return this.http.get(`/api/postal-codes/${encodeURIComponent(n)}/history`)}create(n){return this.http.post("/api/postal-codes",n)}delete(n,t){return this.http.delete(`/api/postal-codes/${encodeURIComponent(n)}`,{body:{comment:t}})}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var R4=(e,n)=>n.name;function F4(e,n){if(e&1&&(l(0,"a",2),s(1),a()),e&2){let t=p().$implicit;v("routerLink",t.path),d(),g(t.name)}}function L4(e,n){if(e&1&&s(0),e&2){let t=p().$implicit;A(" ",t.name," ")}}function V4(e,n){if(e&1&&(l(0,"li"),y(1,F4,2,2,"a",2)(2,L4,1,1),a()),e&2){let t=n.$implicit;d(),_(t.path?1:2)}}function U4(e,n){e&1&&(l(0,"p",1),s(1,"No admin subdivision on file for this postal code beyond the country."),a())}var cu=class e{countryCode="";countryName=null;levels=[];static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-postal-code-hierarchy-tab"]],inputs:{countryCode:"countryCode",countryName:"countryName",levels:"levels"},decls:6,vars:2,consts:[[1,"hierarchy-list"],[1,"placeholder"],[3,"routerLink"]],template:function(t,i){if(t&1&&(l(0,"ul",0)(1,"li"),s(2),a(),I(3,V4,3,1,"li",null,R4),a(),y(5,U4,2,0,"p",1)),t&2){let o;d(2),g((o=i.countryName)!==null&&o!==void 0?o:i.countryCode),d(),T(i.levels),d(2),_(i.levels.length?-1:5)}},dependencies:[W],styles:[".hierarchy-list[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0}.hierarchy-list[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]{position:relative;padding:.4rem 0 .4rem 1.2rem;font-size:.95rem}.hierarchy-list[_ngcontent-%COMP%]   li[_ngcontent-%COMP%] + li[_ngcontent-%COMP%]{margin-left:1rem;border-left:1px dashed #ccc}.hierarchy-list[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.hierarchy-list[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic;font-size:.9rem}"]})};
105var j4=(e,n)=>n.modificationTime+"-"+n.userId;function B4(e,n){e&1&&(l(0,"p",0),s(1,"Loading history\u2026"),a())}function H4(e,n){e&1&&(l(0,"p",1),s(1,"Could not load history right now."),a())}function $4(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),Be(3,"date"),a(),l(4,"td")(5,"a",3),s(6),a()(),l(7,"td"),s(8),a(),l(9,"td"),s(10),a(),l(11,"td")(12,"a",3),s(13,"map"),a()()()),e&2){let t=n.$implicit,i=p(3);d(2),g(He(3,7,t.modificationTime,"yyyy MM dd HH:mm:ss")),d(3),v("routerLink",i.userPath(t.username)),d(),g(t.username),d(2),g(t.comment),d(2),le("",t.latitude,", ",t.longitude,""),d(2),v("routerLink",i.mapPath(t))}}function z4(e,n){if(e&1&&(l(0,"table",2)(1,"thead")(2,"tr")(3,"th"),s(4,"Time"),a(),l(5,"th"),s(6,"User"),a(),l(7,"th"),s(8,"Comment"),a(),l(9,"th"),s(10,"lat/lng"),a(),j(11,"th"),a()(),l(12,"tbody"),I(13,$4,14,10,"tr",null,j4),a()()),e&2){let t=p(2);d(13),T(t.entries())}}function G4(e,n){e&1&&(l(0,"p",0),s(1,"No edit history yet."),a())}function W4(e,n){if(e&1&&y(0,z4,15,0,"table",2)(1,G4,2,0,"p",0),e&2){let t=p();_(t.entries().length?0:1)}}var du=class e{postalCodeId;active=!1;postalCodeService=h(Kn);state=E("loading");entries=E([]);ngOnChanges(n){(n.postalCodeId||n.active&&this.active)&&this.load()}userPath(n){return`/recent-changes/user/${encodeURIComponent(n)}`}mapPath(n){return`/maps/browse_${n.latitude}_${n.longitude}.html`}load(){this.state.set("loading"),this.postalCodeService.getHistory(this.postalCodeId).subscribe({next:n=>{this.entries.set(n),this.state.set("loaded")},error:()=>this.state.set("error")})}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-postal-code-history-tab"]],inputs:{postalCodeId:"postalCodeId",active:"active"},features:[ct],decls:3,vars:1,consts:[[1,"placeholder"],[1,"placeholder","error"],[1,"history-table"],[3,"routerLink"]],template:function(t,i){if(t&1&&y(0,B4,2,0,"p",0)(1,H4,2,0,"p",1)(2,W4,2,1),t&2){let o;_((o=i.state())==="loading"?0:o==="error"?1:o==="loaded"?2:-1)}},dependencies:[Ct,W],styles:[".placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic;font-size:.9rem}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.history-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.history-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .history-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.4rem .6rem;border-bottom:1px solid #eee;text-align:left}.history-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555}.history-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.history-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.history-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.history-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}"]})};var q4=(e,n)=>n.name,J4=(e,n)=>n.id;function K4(e,n){e&1&&(l(0,"p",0),s(1,"Loading postal code\u2026"),a())}function Y4(e,n){e&1&&(l(0,"p",1),s(1,"No postal code found with this id."),a())}function Z4(e,n){e&1&&(l(0,"p",1),s(1,"Could not load this postal code right now."),a())}function Q4(e,n){if(e&1&&(l(0,"a",24),s(1),a()),e&2){let t=p().$implicit;v("routerLink",t.path),d(),g(t.name)}}function X4(e,n){if(e&1&&(l(0,"span"),s(1),a()),e&2){let t=p().$implicit;d(),g(t.name)}}function eV(e,n){if(e&1&&(l(0,"span",4),s(1,"\u203A"),a(),y(2,Q4,2,2,"a",24)(3,X4,2,1,"span")),e&2){let t=n.$implicit;d(2),_(t.path?2:3)}}function tV(e,n){if(e&1&&(l(0,"p",7),s(1,"Permalink: "),l(2,"a",24),s(3),a()()),e&2){let t=p(3);d(2),v("routerLink",t.canonicalPath()),d(),A("https://www.geonames.org",t.canonicalPath(),"")}}function nV(e,n){if(e&1){let t=$();l(0,"button",25),M("click",function(){let o=S(t).$implicit,r=p(3);return w(r.activeTab.set(o.id))}),s(1),a()}if(e&2){let t=n.$implicit,i=p(3);pe("active",i.activeTab()===t.id),v("id","tab-"+t.id),_e("aria-selected",i.activeTab()===t.id)("aria-controls","panel-"+t.id),d(),A(" ",t.label," ")}}function iV(e,n){if(e&1&&s(0),e&2){let t=p();le(" ",t.lat.toFixed(5),", ",t.lng.toFixed(5)," ")}}function oV(e,n){e&1&&s(0," not set ")}function rV(e,n){if(e&1){let t=$();l(0,"button",26),M("click",function(){S(t);let o=p(3);return w(o.startMovePostalCode())}),s(1,"Move"),a()}}function aV(e,n){e&1&&(l(0,"div",12)(1,"dt"),s(2,"Accuracy"),a(),l(3,"dd"),s(4),a()()),e&2&&(d(4),g(n))}function sV(e,n){if(e&1&&(l(0,"div",12)(1,"dt"),s(2,"Timezone"),a(),l(3,"dd"),s(4),a()()),e&2){let t=p();d(4),g(t.timezoneId)}}
105function lV(e,n){if(e&1&&(l(0,"div",12)(1,"dt"),s(2,"Linked feature"),a(),l(3,"dd")(4,"a",24),s(5),a()()()),e&2){let t=p();d(4),v("routerLink",n),d(),g(t.placeName)}}function cV(e,n){e&1&&(l(0,"p",27),s(1,"Sign in to move this postal code - you can still preview a new position below."),a())}function dV(e,n){if(e&1&&(l(0,"p",38),s(1),a()),e&2){let t=p(4);d(),g(t.saveError())}}function uV(e,n){if(e&1){let t=$();l(0,"div",14),y(1,cV,2,0,"p",27),l(2,"form",28),M("submit",function(o){S(t);let r=p(3);return w(r.onMoveSubmit(o))}),l(3,"div",29)(4,"label"),s(5," Latitude "),l(6,"input",30),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.latInput,o)||(r.latInput=o),w(o)}),a()(),l(7,"label"),s(8," Longitude "),l(9,"input",31),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.lngInput,o)||(r.lngInput=o),w(o)}),a()()(),l(10,"label",32),s(11," Comment "),l(12,"input",33),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.comment,o)||(r.comment=o),w(o)}),a()(),l(13,"p",34),s(14,"Or pick a new position visually on the "),l(15,"button",26),M("click",function(){S(t);let o=p(3);return w(o.activeTab.set("map"))}),s(16,"Map tab"),a(),s(17,"."),a(),l(18,"div",35)(19,"button",36),s(20),a(),l(21,"button",37),M("click",function(){S(t);let o=p(3);return w(o.cancelMovePostalCode())}),s(22,"Cancel"),a()(),y(23,dV,2,1,"p",38),a()()}if(e&2){let t=p(3);d(),_(t.isSignedIn()?-1:1),d(5),R("ngModel",t.latInput),d(3),R("ngModel",t.lngInput),d(3),R("ngModel",t.comment),d(7),v("disabled",t.saveState()==="saving"),d(),A(" ",t.saveState()==="saving"?"Saving\u2026":"Save new position"," "),d(),v("disabled",t.saveState()==="saving"),d(2),_(t.saveState()==="error"?23:-1)}}function mV(e,n){e&1&&(l(0,"p",15),s(1,"Saved."),a())}function pV(e,n){if(e&1){let t=$();l(0,"button",39),M("click",function(){S(t);let o=p(3);return w(o.startDeletePostalCode())}),s(1,"Delete this postal code"),a()}}function fV(e,n){if(e&1&&(l(0,"p",44),s(1),a()),e&2){let t=p(4);d(),g(t.deleteError())}}function hV(e,n){if(e&1){let t=$();l(0,"div",18)(1,"label"),s(2," Reason for deletion "),l(3,"input",40),F("ngModelChange",function(o){S(t);let r=p(3);return L(r.deleteComment,o)||(r.deleteComment=o),w(o)}),a()(),l(4,"p",41),s(5,"This permanently removes the record from GeoNames."),a(),l(6,"div",42)(7,"button",43),M("click",function(){S(t);let o=p(3);return w(o.confirmDeletePostalCode())}),s(8),a(),l(9,"button",37),M("click",function(){S(t);let o=p(3);return w(o.cancelDeletePostalCode())}),s(10,"Cancel"),a()(),y(11,fV,2,1,"p",44),a()}if(e&2){let t=p(3);d(3),R("ngModel",t.deleteComment),d(4),v("disabled",t.deleting()||!t.deleteComment.trim()),d(),A(" ",t.deleting()?"Deleting\u2026":"Confirm delete"," "),d(),v("disabled",t.deleting()),d(2),_(t.deleteError()?11:-1)}}function gV(e,n){if(e&1){let t=$();l(0,"p",34),s(1,"Click or drag the marker on the map to set a new position, then switch back to the Feature tab to save it."),a(),l(2,"app-geo-map",45),M("pointPicked",function(o){S(t);let r=p(3);return w(r.onPointPicked(o))}),a()}if(e&2){let t,i,o=p(),r=p(2);d(2),v("latitude",(t=o.lat)!==null&&t!==void 0?t:0)("longitude",(i=o.lng)!==null&&i!==void 0?i:0)("zoom",14)("showCenterMarker",!1)("allowCreate",!1)("allowMove",!1)("hideFeatureMarkers",!0)("pickPointEnabled",!0)("pickedPoint",r.pickedPoint())("shapeGeometry",r.shapeGeometry())("tall",!0)}}function CV(e,n){if(e&1&&(l(0,"nav",2)(1,"a",3),s(2,"Home"),a(),l(3,"span",4),s(4,"\u203A"),a(),l(5,"span"),s(6),a(),I(7,eV,4,1,null,null,q4),l(9,"span",4),s(10,"\u203A"),a(),l(11,"span",5),s(12),a()(),l(13,"header",6)(14,"h1"),s(15),a(),y(16,tV,4,2,"p",7),a(),l(17,"div",8),I(18,nV,2,6,"button",9,J4),a(),l(20,"section",10)(21,"dl",11)(22,"div",12)(23,"dt"),s(24,"PostalCodeId"),a(),l(25,"dd"),s(26),a()(),l(27,"div",12)(28,"dt"),s(29,"Coordinates"),a(),l(30,"dd"),y(31,iV,1,2)(32,oV,1,0)(33,rV,2,0,"button",13),a()(),y(34,aV,5,1,"div",12),l(35,"div",12)(36,"dt"),s(37,"PO Box"),a(),l(38,"dd"),s(39),a()(),y(40,sV,5,1,"div",12)(41,lV,6,2,"div",12),a(),y(42,uV,24,8,"div",14)(43,mV,2,0,"p",15),l(44,"div",16),y(45,pV,2,0,"button",17)(46,hV,12,5,"div",18),a()(),l(47,"section",19),y(48,gV,3,11),a(),l(49,"section",20),j(50,"app-postal-code-hierarchy-tab",21),a(),l(51,"section",22),j(52,"app-postal-code-history-tab",23),a()),e&2){let t,i,o,r=n,c=p(2);
105d(6),g((t=c.countryName())!==null&&t!==void 0?t:r.countryCode),d(),T(c.adminHierarchy()),d(5),le("",r.zip," ",r.placeName,""),d(3),gt("",r.countryCode," ",r.zip," ",r.placeName,""),d(),_(c.canonicalPath()?16:-1),d(2),T(c.tabs),d(2),v("hidden",c.activeTab()!=="feature"),d(6),g(r.postalCodeId),d(5),_(r.lat!=null&&r.lng!=null?31:32),d(2),_(c.movingPostalCode()?-1:33),d(),_((i=c.accuracyLabel())?34:-1,i),d(5),g(r.isPobox?"Yes":"No"),d(),_(r.timezoneId?40:-1),d(),_((o=c.linkedFeaturePath())?41:-1,o),d(),_(c.movingPostalCode()?42:-1),d(),_(c.saveState()==="saved"?43:-1),d(2),_(c.confirmingDelete()?46:45),d(2),v("hidden",c.activeTab()!=="map"),d(),_(c.activeTab()==="map"?48:-1),d(),v("hidden",c.activeTab()!=="hierarchy"),d(),v("countryCode",r.countryCode)("countryName",c.countryName())("levels",c.adminHierarchy()),d(),v("hidden",c.activeTab()!=="history"),d(),v("postalCodeId",c.postalCodeId())("active",c.activeTab()==="history")}}function _V(e,n){if(e&1&&y(0,CV,53,27),e&2){let t,i=p();_((t=i.postalCode())?0:-1,t)}}var ns=class e{route=h(ve);router=h(Dt);postalCodeService=h(Kn);countryInfo=h(it);places=h(tt);auth=h(qe);title=h(H);meta=h(Ni);renderer=h(Ut);document=h($e);canonicalLink;jsonLdScript;postalCodeId=E("");state=E("loading");postalCode=E(null);countryName=E(null);shapeGeometry=E(null);latInput="";lngInput="";comment="";saveState=E("idle");saveError=E(null);movingPostalCode=E(!1);confirmingDelete=E(!1);deleteComment="";deleting=E(!1);deleteError=E(null);isSignedIn=G(()=>!!this.auth.currentUser());tabs=[{id:"feature",label:"Feature"},{id:"map",label:"Map"},{id:"hierarchy",label:"Hierarchy"},{id:"history",label:"History"}];activeTab=E(this.defaultTab());canonicalPath=G(()=>{let n=this.postalCode();return n?`/postal-codes/${n.postalCodeId}/${this.slug(n)}`:null});adminHierarchy=G(()=>{let n=this.postalCode();if(!n)return[];let t=[];return n.adminName1&&t.push({name:n.adminName1,path:n.admin1GeonameId?this.places.path({id:String(n.admin1GeonameId),name:n.adminName1}):null}),n.adminName2&&t.push({name:n.adminName2,path:n.admin2GeonameId?this.places.path({id:String(n.admin2GeonameId),name:n.adminName2}):null}),n.adminName3&&t.push({name:n.adminName3,path:n.admin3GeonameId?this.places.path({id:String(n.admin3GeonameId),name:n.adminName3}):null}),t});linkedFeaturePath=G(()=>{let n=this.postalCode();return n?.geonameId?this.places.path({id:String(n.geonameId),name:n.placeName,asciiName:n.asciiName??void 0}):null});static ACCURACY_LABELS={1:"estimated",4:"from geonameid",6:"centroid of addresses or shape"};accuracyLabel=G(()=>{let n=this.postalCode()?.accuracy;if(n==null)return null;let t=e.ACCURACY_LABELS[n];return t?`${n} (${t})`:String(n)});pickedPoint=G(()=>{let n=Number(this.latInput),t=Number(this.lngInput);return this.latInput!==""&&this.lngInput!==""&&Number.isFinite(n)&&Number.isFinite(t)?{lat:n,lng:t}:null});constructor(){this.route.paramMap.pipe(N(n=>n.get("id")??"")).subscribe(n=>{this.postalCodeId.set(n),this.load(n)})}slug(n){let t=(n.asciiName??n.placeName).toLowerCase().trim().replace(/\s+/g,"-");return`${n.countryCode.toUpperCase()}-${n.zip}-${t}.html`}defaultTab(){return this.isSignedIn()?"map":"feature"}load(n){this.state.set("loading"),this.activeTab.set(this.defaultTab()),this.shapeGeometry.set(null),this.countryName.set(null),this.confirmingDelete.set(!1),this.deleteError.set(null),this.movingPostalCode.set(!1),this.saveState.set("idle"),this.saveError.set(null),this.postalCodeService.get(n).subscribe({next:t=>{this.postalCode.set(t),this.latInput=t.lat!=null?String(t.lat):"",this.lngInput=t.lng!=null?String(t.lng):"",this.state.set("loaded"),this.applySeoTags(t),this.countryInfo.getCountries().subscribe(i=>{this.countryName.set(i.find(o=>o.isoCode===t.countryCode)?.countryName??null)})},error:t=>this.state.set(t?.status===404?"not-found":"error")}),this.postalCodeService.getShape(n).subscribe(t=>this.shapeGeometry.set(t))}applySeoTags(n){let t=`${n.countryCode} ${n.zip} ${n.placeName} \u2014 GeoNames UI`,i=`Postal code ${n.zip}, ${n.placeName}, ${n.countryCode}${n.adminName1?" ("+n.adminName1+")":""}.`;if(this.title.setTitle(t),this.meta.updateTag({name:"description",content:i}),this.meta.updateTag({property:"og:title",content:t}),this.meta.updateTag({property:"og:description",content:i}),this.meta.updateTag({property:"og:type",content:"place"}),n.lat!=null&&n.lng!=null){let r={"@context":"https://schema.org","@type":"Place",name:`${n.zip} ${n.placeName}`,description:i,address:{"@type":"PostalAddress",postalCode:n.zip,addressLocality:n.placeName,addressRegion:n.adminName1??void 0,addressCountry:n.countryCode},geo:{"@type":"GeoCoordinates",latitude:n.lat,longitude:n.lng}};this.jsonLdScript&&this.renderer.removeChild(this.document.head,this.jsonLdScript);let c=this.renderer.createElement("script");c.type="application/ld+json",c.text=JSON.stringify(r),this.renderer.appendChild(this.document.head,c),this.jsonLdScript=c}this.canonicalLink&&this.renderer.removeChild(this.document.head,this.canonicalLink);let o=this.renderer.createElement("link");o.setAttribute("rel","canonical"),o.setAttribute("href",this.canonicalPath()??`/postal-codes/${n.postalCodeId}`),this.renderer.appendChild(this.document.head,o),this.canonicalLink=o}startMovePostalCode(){let n=this.postalCode();n&&(this.latInput=n.lat!=null?n.lat.toFixed(5):"",this.lngInput=n.lng!=null?n.lng.toFixed(5):"",this.movingPostalCode.set(!0),this.saveState.set("idle"),this.saveError.set(null))}cancelMovePostalCode(){this.movingPostalCode.set(!1),this.saveState.set("idle"),this.saveError.set(null)}onPointPicked(n){this.latInput=n.lat.toFixed(6),this.lngInput=n.lng.toFixed(6),this.movingPostalCode.set(!0),this.saveState.set("idle"),this.saveError.set(null)}onMoveSubmit(n){n.preventDefault();let t=Number(this.latInput),i=Number(this.lngInput);if(!Number.isFinite(t)||!Number.isFinite(i)||t<-90||t>90||i<-180||i>180){this.saveState.set("error"),this.saveError.set("Enter a valid latitude (-90 to 90) and longitude (-180 to 180).");return}this.saveState.set("saving"),this.saveError.set(null),this.postalCodeService.move(this.postalCodeId(),t,i,this.comment).subscribe({next:o=>{this.postalCode.set(o),this.saveState.set("saved"),this.movingPostalCode.set(!1)},error:o=>{this.saveState.set("error"),this.saveError.set(o?.status===401?"Sign in to move a postal code.":"Could not save this move right now.")}})}startDeletePostalCode(){this.confirmingDelete.set(!0),this.deleteComment="",this.deleteError.set(null)}cancelDeletePostalCode(){this.confirmingDelete.set(!1),this.deleteError.set(null)}confirmDeletePostalCode(){this.deleting.set(!0),this.deleteError.set(null),this.postalCodeService.delete(this.postalCodeId(),this.deleteComment.trim()).subscribe({next:()=>{this.deleting.set(!1),this.confirmingDelete.set(!1);let n=this.linkedFeaturePath();this.router.navigateByUrl(n??"/postal-codes/recent-changes")}
105,error:n=>{this.deleting.set(!1),this.deleteError.set(n?.status===401?"Sign in to delete a postal code.":"Could not delete this postal code right now.")}})}ngOnDestroy(){this.jsonLdScript&&this.renderer.removeChild(this.document.head,this.jsonLdScript),this.canonicalLink&&this.renderer.removeChild(this.document.head,this.canonicalLink)}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-postal-code-edit-page"]],decls:4,vars:1,consts:[[1,"placeholder"],[1,"placeholder","error"],["aria-label","Breadcrumb",1,"breadcrumb"],["routerLink","/"],[1,"sep"],[1,"current"],[1,"page-header"],[1,"permalink"],["role","tablist","aria-label","Postal code details",1,"tabs"],["type","button","role","tab",1,"tab",3,"active","id"],["id","panel-feature","role","tabpanel","aria-labelledby","tab-feature",3,"hidden"],[1,"facts"],[1,"fact"],["type","button",1,"link-btn"],[1,"edit-form","move-form"],[1,"form-success"],[1,"danger-zone"],["type","button",1,"btn-danger-outline"],[1,"delete-panel"],["id","panel-map","role","tabpanel","aria-labelledby","tab-map",3,"hidden"],["id","panel-hierarchy","role","tabpanel","aria-labelledby","tab-hierarchy",3,"hidden"],[3,"countryCode","countryName","levels"],["id","panel-history","role","tabpanel","aria-labelledby","tab-history",3,"hidden"],[3,"postalCodeId","active"],[3,"routerLink"],["type","button","role","tab",1,"tab",3,"click","id"],["type","button",1,"link-btn",3,"click"],[1,"notice"],[3,"submit"],[1,"field-row"],["type","text","name","lat","placeholder","e.g. 47.36667","inputmode","decimal",3,"ngModelChange","ngModel"],["type","text","name","lng","placeholder","e.g. 8.55","inputmode","decimal",3,"ngModelChange","ngModel"],[1,"comment-label"],["type","text","name","comment","placeholder","reason for this move (optional)",3,"ngModelChange","ngModel"],[1,"map-hint"],[1,"edit-actions"],["type","submit",1,"btn-primary",3,"disabled"],["type","button",3,"click","disabled"],[1,"form-error"],["type","button",1,"btn-danger-outline",3,"click"],["type","text","name","deleteComment","placeholder","e.g. duplicate, does not exist",3,"ngModelChange","ngModel"],[1,"delete-warning"],[1,"delete-actions"],["type","button",1,"btn-danger",3,"click","disabled"],[1,"save-notice","save-error"],["label","Postal code position",3,"pointPicked","latitude","longitude","zoom","showCenterMarker","allowCreate","allowMove","hideFeatureMarkers","pickPointEnabled","pickedPoint","shapeGeometry","tall"]],template:function(t,i){if(t&1&&y(0,K4,2,0,"p",0)(1,Y4,2,0,"p",1)(2,Z4,2,0,"p",1)(3,_V,1,1),t&2){let o;_((o=i.state())==="loading"?0:o==="not-found"?1:o==="error"?2:o==="loaded"?3:-1)}},dependencies:[ke,pt,Me,Ne,mt,De,dt,W,nt,cu,du],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.breadcrumb[_ngcontent-%COMP%]{font-size:.85rem;color:#555;margin-bottom:1rem;overflow-wrap:break-word}.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.breadcrumb[_ngcontent-%COMP%]   .sep[_ngcontent-%COMP%]{margin:0 .35rem;color:#999}.breadcrumb[_ngcontent-%COMP%]   .current[_ngcontent-%COMP%]{color:#222;font-weight:600}.page-header[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{margin:0 0 .15rem;font-size:1.9rem;line-height:1.15}.permalink[_ngcontent-%COMP%]{margin:0 0 .4rem;font-size:.8rem;color:#999;overflow-wrap:anywhere}.permalink[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.permalink[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.tabs[_ngcontent-%COMP%]{display:flex;gap:.25rem;border-bottom:1px solid #e5e5e5;margin-top:1.25rem;overflow-x:auto}.tab[_ngcontent-%COMP%]{appearance:none;border:none;background:none;cursor:pointer;font:inherit;font-size:.9rem;color:#555;padding:.6rem .9rem;border-bottom:2px solid transparent;white-space:nowrap}.tab[_ngcontent-%COMP%]:hover{color:#1a5fb4}
105.tab.active[_ngcontent-%COMP%]{color:#1a5fb4;font-weight:600;border-bottom-color:#1a5fb4}[role=tabpanel][_ngcontent-%COMP%]{padding-top:1.25rem}.facts[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.75rem 1.5rem;margin:1.25rem 0;padding:1rem;background:#f8f9fa;border-radius:8px}.fact[_ngcontent-%COMP%]   dt[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;color:#777}.fact[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]{margin:.1rem 0 0;font-size:1.05rem;font-weight:500}.fact[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.fact[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}.facts[_ngcontent-%COMP%]{grid-template-columns:1fr 1fr;padding:.75rem;gap:.6rem 1rem}.page-header[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{font-size:1.5rem}}.notice[_ngcontent-%COMP%]{color:#8a5a00;background:#fff6e0;border:1px solid #f0dca0;border-radius:6px;padding:.5rem .75rem;font-size:.85rem;margin:0 0 1rem}.move-form[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:flex-end;gap:.75rem 1rem;margin:1rem 0;padding:.75rem;background:#f8f9fa;border-radius:8px}.field-row[_ngcontent-%COMP%]{display:flex;gap:1rem;flex-wrap:wrap}.move-form[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.2rem;font-size:.75rem;color:#666;flex:1;min-width:10rem}.comment-label[_ngcontent-%COMP%]{flex-basis:100%;min-width:100%}.move-form[_ngcontent-%COMP%]   input[_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.3rem .4rem;font-size:.85rem;max-width:16rem;color:#1b1b1b}.move-form[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.move-form[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.save-notice[_ngcontent-%COMP%]{font-size:.85rem;margin-left:.5rem}.save-success[_ngcontent-%COMP%]{color:#2e7d32}.save-error[_ngcontent-%COMP%]{color:#b3261e}.map-hint[_ngcontent-%COMP%]{color:#777;font-size:.8rem;margin:0 0 .4rem}.link-btn[_ngcontent-%COMP%]{appearance:none;border:none;background:none;color:#1a5fb4;font-size:inherit;cursor:pointer;padding:0;text-decoration:underline}.danger-zone[_ngcontent-%COMP%]{margin-top:1.5rem;padding-top:1rem;border-top:1px solid #f0f0f0}.btn-danger-outline[_ngcontent-%COMP%]{appearance:none;border:1px solid #b3261e;background:none;color:#b3261e;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.btn-danger-outline[_ngcontent-%COMP%]:hover{background:#fdecea}.delete-panel[_ngcontent-%COMP%]{max-width:28rem}.delete-panel[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem;font-size:.8rem;color:#555}.delete-panel[_ngcontent-%COMP%]   input[type=text][_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.35rem .5rem;font-size:.9rem}.delete-warning[_ngcontent-%COMP%]{font-size:.8rem;color:#8a6d00;margin:.5rem 0}.delete-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}.btn-danger[_ngcontent-%COMP%]{appearance:none;border:1px solid #b3261e;background:#b3261e;color:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}.btn-danger[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.delete-actions[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:not(.btn-danger){appearance:none;border:1px solid #d8d8d8;background:#fff;border-radius:4px;padding:.35rem .8rem;font-size:.85rem;cursor:pointer}"]})};var vV=(e,n)=>n.modificationTime+"-"+n.userId;function yV(e,n){e&1&&(l(0,"p",0),s(1,"Loading edit history\u2026"),a())}function bV(e,n){e&1&&(l(0,"p",1),s(1,"Could not load edit history right now."),a())}function xV(e,n){if(e&1&&(l(0,"a",2),s(1),a()),e&2){let t=n,i=p(2);v("routerLink",i.editPath()),d(),le("",t.countryCode," ",t.zip,"")}}function SV(e,n){if(e&1&&s(0),e&2){let t=p(2);A(" postal code ",t.postalCodeId()," ")}}function wV(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),Be(3,"date"),a(),l(4,"td")(5,"a",2),s(6),a()(),l(7,"td"),s(8),a(),l(9,"td"),s(10),a(),l(11,"td")(12,"a",2),s(13,"map"),a()()()),e&2){let t=n.$implicit,i=p(3);d(2),g(He(3,7,t.modificationTime,"yyyy MM dd HH:mm:ss")),d(3),v("routerLink",i.userPath(t.username)),d(),g(t.username),d(2),g(t.comment),d(2),le("",t.latitude,", ",t.longitude,""),d(2),v("routerLink",i.mapPath(t))}}function EV(e,n){if(e&1&&(l(0,"table",3)(1,"thead")(2,"tr")(3,"th"),s(4,"Time"),a(),l(5,"th"),s(6,"User"),a(),l(7,"th"),s(8,"Comment"),a(),l(9,"th"),s(10,"lat/lng"),a(),j(11,"th"),a()(),l(12,"tbody"),I(13,wV,14,10,"tr",null,vV),a()()),e&2){let t=p(2);d(13),T(t.entries())}}function MV(e,n){e&1&&(l(0,"p",0),s(1,"No edit history found for this postal code."),a())}
105function PV(e,n){if(e&1&&(l(0,"h1"),s(1," Edit History for "),y(2,xV,2,3,"a",2)(3,SV,1,1),a(),y(4,EV,15,0,"table",3)(5,MV,2,0,"p",0)),e&2){let t,i=p();d(2),_((t=i.postalCode())?2:3,t),d(2),_(i.entries().length?4:5)}}var uu=class e{route=h(ve);postalCodeService=h(Kn);title=h(H);postalCodeId=E("");state=E("loading");postalCode=E(null);entries=E([]);editPath=G(()=>`/postal-codes/${this.postalCodeId()}`);constructor(){this.route.paramMap.pipe(N(n=>n.get("id")??"")).subscribe(n=>{this.postalCodeId.set(n),this.load(n)})}mapPath(n){return`/maps/browse_${n.latitude}_${n.longitude}.html`}userPath(n){return`/recent-changes/user/${encodeURIComponent(n)}`}load(n){this.state.set("loading"),this.postalCodeService.get(n).subscribe({next:t=>{this.postalCode.set(t),this.title.setTitle(`Edit History for ${t.countryCode} ${t.zip} \u2014 GeoNames UI`)},error:()=>{}}),this.postalCodeService.getHistory(n).subscribe({next:t=>{this.entries.set(t),this.state.set("loaded")},error:()=>this.state.set("error")})}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-postal-code-history-page"]],decls:3,vars:1,consts:[[1,"placeholder"],[1,"placeholder","error"],[3,"routerLink"],[1,"history-table"]],template:function(t,i){if(t&1&&y(0,yV,2,0,"p",0)(1,bV,2,0,"p",1)(2,PV,6,2),t&2){let o;_((o=i.state())==="loading"?0:o==="error"?1:o==="loaded"?2:-1)}},dependencies:[Ct,W],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.4rem}h1[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}h1[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.history-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.history-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .history-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.4rem .6rem;border-bottom:1px solid #eee;text-align:left}.history-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555}.history-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.history-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var mu=class e{http=h(Z);getRecentChanges(n,t){let i=new URLSearchParams({startRow:String(n),maxRows:String(t)});return this.http.get(`/api/postal-code-changes?${i.toString()}`)}static \u0275fac=function(t){return new(t||e)};static \u0275prov=O({token:e,factory:e.\u0275fac,providedIn:"root"})};var DV=(e,n)=>n.postalCodeId+"-"+n.modificationTime;function IV(e,n){e&1&&(l(0,"p",2),s(1,"Loading recent changes\u2026"),a())}function TV(e,n){e&1&&(l(0,"p",3),s(1,"Could not load recent changes right now."),a())}function OV(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),Be(3,"date"),a(),l(4,"td")(5,"a",8),s(6),a(),s(7),a(),l(8,"td"),s(9),a(),l(10,"td")(11,"a",8),s(12),a()(),l(13,"td",9),s(14),a(),l(15,"td")(16,"a",8),s(17,"map"),a()()()),e&2){let t=n.$implicit,i=p(2);d(2),g(He(3,9,t.modificationTime,"yyyy MM dd HH:mm:ss")),d(3),v("routerLink",i.editPath(t)),d(),g(t.zip),d(),A(" ",t.placeName,""),d(2),g(t.countryCode),d(2),v("routerLink",i.userPath(t.username)),d(),g(t.username),d(2),g(t.comment),d(2),v("routerLink",i.mapPath(t))}}function NV(e,n){if(e&1){let t=$();l(0,"div",4)(1,"table",5)(2,"thead")(3,"tr")(4,"th"),s(5,"Time"),a(),l(6,"th"),s(7,"Postal Code"),a(),l(8,"th"),s(9,"CC"),a(),l(10,"th"),s(11,"User"),a(),l(12,"th"),s(13,"Comment"),a(),l(14,"th"),s(15,"lat/lng"),a()()(),l(16,"tbody"),I(17,OV,18,12,"tr",null,DV),a()()(),l(19,"div",6)(20,"button",7),M("click",function(){S(t);let o=p();return w(o.previousPage())}),s(21,"\xAB Previous"),a(),l(22,"button",7),M("click",function(){S(t);let o=p();return w(o.nextPage())}),s(23,"Next \xBB"),a()()}if(e&2){let t=p();d(17),T(t.changes()),d(3),v("disabled",!t.hasPrevious()),d(2),v("disabled",!t.hasNext())}}var kV=50,pu=class e{changesService=h(mu);title=h(H);state=E("loading");changes=E([]);startRow=E(0);pageSize=kV;hasPrevious=G(()=>this.startRow()>0);hasNext=G(()=>this.changes().length===this.pageSize);constructor(){this.title.setTitle("Recent Postal Code Changes \u2014 GeoNames UI"),this.load()}editPath(n){return`/postal-codes/${n.postalCodeId}`}userPath(n){return`/recent-changes/user/${encodeURIComponent(n)}`}mapPath(n){return`/maps/browse_${n.latitude}_${n.longitude}.html`}load(){this.state.set("loading"),this.changesService.getRecentChanges(this.startRow(),this.pageSize).subscribe({next:n=>{this.changes.set(n),this.state.set("loaded")},error:()=>this.state.set("error")})}nextPage(){this.hasNext()&&(this.startRow.update(n=>n+this.pageSize),this.load())}previousPage(){this.hasPrevious()&&(this.startRow.update(n=>Math.max(0,n-this.pageSize)),this.load())}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-postal-code-changes-page"]],decls:8,vars:1,consts:[[1,"page-header"],["routerLink","/postal-codes/new",1,"new-link"],[1,"placeholder"],[1,"not-found"],[1,"table-scroll"],[1,"changes-table"],[1,"pager"],["type","button",3,"click","disabled"],[3,"routerLink"],[1,"comment"]],template:function(t,i){if(t&1&&(l(0,"header",0)(1,"h1"),s(2,"Recent Postal Code Changes"),a(),l(3,"a",1),s(4,"+ New postal code"),a()(),y(5,IV,2,0,"p",2)(6,TV,2,0,"p",3)(7,NV,24,2)),t&2){let o;d(5),_((o=i.state())==="loading"?5:o==="error"?6:o==="loaded"?7:-1)}},dependencies:[Ct,W],styles:["[_nghost-%COMP%]{display:block;max-width:1000px;margin:0 auto;padding:1rem}.page-header[_ngcontent-%COMP%]{display:flex;align-items:baseline;justify-content:space-between;gap:1rem;margin:0 0 1rem}h1[_ngcontent-%COMP%]{margin:0;font-size:1.6rem}.new-link[_ngcontent-%COMP%]{font-size:.85rem;
105color:#1a5fb4;text-decoration:none;white-space:nowrap}.new-link[_ngcontent-%COMP%]:hover{text-decoration:underline}.placeholder[_ngcontent-%COMP%], .not-found[_ngcontent-%COMP%]{color:#777;font-size:.9rem}.table-scroll[_ngcontent-%COMP%]{position:relative;max-height:70vh;overflow:auto;scrollbar-width:thin}.changes-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.changes-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .changes-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .6rem;border-bottom:1px solid #eee;text-align:left;white-space:nowrap}.changes-table[_ngcontent-%COMP%]   td.comment[_ngcontent-%COMP%]{white-space:normal;min-width:220px}.changes-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{position:sticky;top:0;background:#fff;border-bottom:2px solid #ddd;color:#555}.changes-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.changes-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.changes-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.changes-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.pager[_ngcontent-%COMP%]{display:flex;justify-content:space-between;margin-top:.75rem}.pager[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{padding:.35rem .9rem;font-size:.85rem;border:1px solid #ccc;border-radius:4px;background:#f7f7f7;cursor:pointer}.pager[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:hover:not(:disabled){background:#eee}.pager[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:default}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};function AV(e,n){e&1&&(l(0,"p",1),s(1,"Sign in to create a postal code - you can still preview the form below."),a())}function RV(e,n){e&1&&(l(0,"small",6),s(1),a()),e&2&&(d(),A("Format: ",n,""))}function FV(e,n){if(e&1&&(l(0,"option",15),s(1),a()),e&2){let t=n.$implicit;v("value",t),d(),g(t)}}function LV(e,n){if(e&1&&(l(0,"span",23),s(1),a()),e&2){let t=p();d(),g(t.saveError())}}var fu=class e{router=h(Dt);postalCodeService=h(Kn);countryInfo=h(it);timezoneService=h(Fi);auth=h(qe);title=h(H);countries=[];isSignedIn=G(()=>!!this.auth.currentUser());timezoneOptions=E([]);form={countryCode:"",zip:"",placeName:"",adminName1:"",adminName2:"",adminName3:"",geonameId:"",isPobox:!1,timezoneId:"",comment:""};latInput="";lngInput="";saveState=E("idle");saveError=E(null);selectedCountry=E(null);pickedPoint=G(()=>{let n=Number(this.latInput),t=Number(this.lngInput);return this.latInput!==""&&this.lngInput!==""&&Number.isFinite(n)&&Number.isFinite(t)?{lat:n,lng:t}:null});constructor(){this.title.setTitle("New Postal Code \u2014 GeoNames UI"),this.countryInfo.getCountries().subscribe(n=>{this.countries=n,this.onCountryCodeChange()}),this.timezoneService.getTimezoneIds().subscribe(n=>this.timezoneOptions.set(n))}onPointPicked(n){this.latInput=n.lat.toFixed(6),this.lngInput=n.lng.toFixed(6)}onCountryCodeChange(){let n=this.form.countryCode.trim().toUpperCase();this.selectedCountry.set(n.length===2?this.countries.find(t=>t.isoCode===n)??null:null)}checkZipFormat(){let n=this.selectedCountry();if(!n?.postalCodeRegex)return null;try{if(!new RegExp(n.postalCodeRegex).test(this.form.zip.trim()))return`Doesn't look like a valid ${n.countryName} postal code (expected format: ${n.postalCodeFormat}).`}catch{}return null}onSubmit(n){n.preventDefault();let t=Number(this.latInput),i=Number(this.lngInput);if(this.form.countryCode.trim().length!==2){this.saveState.set("error"),this.saveError.set("Country code must be 2 letters, e.g. CH.");return}if(!this.form.zip.trim()){this.saveState.set("error"),this.saveError.set("Zip is required.");return}let o=this.checkZipFormat();if(o){this.saveState.set("error"),this.saveError.set(o);return}if(!this.form.placeName.trim()){this.saveState.set("error"),this.saveError.set("Place name is required.");return}if(!Number.isFinite(t)||!Number.isFinite(i)||t<-90||t>90||i<-180||i>180){this.saveState.set("error"),this.saveError.set("Click the map (or enter latitude/longitude) to set a valid position.");return}this.saveState.set("saving"),this.saveError.set(null),this.postalCodeService.create({countryCode:this.form.countryCode.trim().toUpperCase(),zip:this.form.zip.trim(),placeName:this.form.placeName.trim(),adminName1:this.form.adminName1.trim()||void 0,adminName2:this.form.adminName2.trim()||void 0,adminName3:this.form.adminName3.trim()||void 0,geonameId:this.form.geonameId.trim()?Number(this.form.geonameId):void 0,isPobox:this.form.isPobox,timezoneId:this.form.timezoneId.trim()||void 0,lat:t,lng:i,comment:this.form.comment.trim()||void 0}).subscribe({next:r=>this.router.navigateByUrl(`/postal-codes/${r.postalCodeId}`),error:r=>{this.saveState.set("error"),this.saveError.set(r?.status===401?"Sign in to create a postal code.":"Could not create this postal code right now.")}})}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-postal-code-create-page"]],decls:56,vars:28,consts:[[1,"page-header"],[1,"notice"],[1,"create-form",3,"submit"],[1,"field-row"],["type","text","name","countryCode","placeholder","e.g. CH","maxlength","2","size","4",3,"ngModelChange","ngModel"],["type","text","name","zip",3,"ngModelChange","ngModel","placeholder"],[1,"field-hint"],[1,"grow"],["type","text","name","placeName","placeholder","e.g. Locarno",3,"ngModelChange","ngModel"],["type","text","name","adminName1","placeholder","e.g. Ticino",3,"ngModelChange","ngModel"],["type","text","name","adminName2",3,"ngModelChange","ngModel"],["type","text","name","adminName3",3,"ngModelChange","ngModel"],["type","text","name","geonameId","placeholder","optional","inputmode","numeric",3,"ngModelChange","ngModel"],["name","timezoneId",3,"ngModelChange","ngModel"],["value",""],[3,"value"],[1,"checkbox-label"],["type","checkbox","name","isPobox",3,"ngModelChange","ngModel"],["type","text","name","lat","placeholder","e.g. 47.36667","inputmode","decimal",3,"ngModelChange","ngModel"],["type","text","name","lng","placeholder","e.g. 8.5
1055","inputmode","decimal",3,"ngModelChange","ngModel"],[1,"comment-label"],["type","text","name","comment","placeholder","reason for adding this postal code (optional)",3,"ngModelChange","ngModel"],["type","submit",3,"disabled"],[1,"save-notice","save-error"],[1,"map-hint"],["label","New postal code position",3,"pointPicked","latitude","longitude","zoom","showCenterMarker","allowCreate","allowMove","hideFeatureMarkers","pickPointEnabled","pickedPoint","tall"]],template:function(t,i){if(t&1&&(l(0,"header",0)(1,"h1"),s(2,"New Postal Code"),a()(),y(3,AV,2,0,"p",1),l(4,"form",2),M("submit",function(r){return i.onSubmit(r)}),l(5,"div",3)(6,"label"),s(7," Country code "),l(8,"input",4),F("ngModelChange",function(r){return L(i.form.countryCode,r)||(i.form.countryCode=r),r}),M("ngModelChange",function(){return i.onCountryCodeChange()}),a()(),l(9,"label"),s(10," Zip "),l(11,"input",5),F("ngModelChange",function(r){return L(i.form.zip,r)||(i.form.zip=r),r}),a(),y(12,RV,2,1,"small",6),a(),l(13,"label",7),s(14," Place name "),l(15,"input",8),F("ngModelChange",function(r){return L(i.form.placeName,r)||(i.form.placeName=r),r}),a()()(),l(16,"div",3)(17,"label"),s(18," Admin name 1 "),l(19,"input",9),F("ngModelChange",function(r){return L(i.form.adminName1,r)||(i.form.adminName1=r),r}),a()(),l(20,"label"),s(21," Admin name 2 "),l(22,"input",10),F("ngModelChange",function(r){return L(i.form.adminName2,r)||(i.form.adminName2=r),r}),a()(),l(23,"label"),s(24," Admin name 3 "),l(25,"input",11),F("ngModelChange",function(r){return L(i.form.adminName3,r)||(i.form.adminName3=r),r}),a()()(),l(26,"div",3)(27,"label"),s(28," Linked geonameId "),l(29,"input",12),F("ngModelChange",function(r){return L(i.form.geonameId,r)||(i.form.geonameId=r),r}),a()(),l(30,"label"),s(31," Timezone "),l(32,"select",13),F("ngModelChange",function(r){return L(i.form.timezoneId,r)||(i.form.timezoneId=r),r}),l(33,"option",14),s(34,"select\u2026"),a(),I(35,FV,2,2,"option",15,Re),a()(),l(37,"label",16)(38,"input",17),F("ngModelChange",function(r){return L(i.form.isPobox,r)||(i.form.isPobox=r),r}),a(),s(39," PO Box "),a()(),l(40,"div",3)(41,"label"),s(42," Latitude "),l(43,"input",18),F("ngModelChange",function(r){return L(i.latInput,r)||(i.latInput=r),r}),a()(),l(44,"label"),s(45," Longitude "),l(46,"input",19),F("ngModelChange",function(r){return L(i.lngInput,r)||(i.lngInput=r),r}),a()()(),l(47,"label",20),s(48," Comment "),l(49,"input",21),F("ngModelChange",function(r){return L(i.form.comment,r)||(i.form.comment=r),r}),a()(),l(50,"button",22),s(51),a(),y(52,LV,2,1,"span",23),a(),l(53,"p",24),s(54,"Click the map to set this postal code's position."),a(),l(55,"app-geo-map",25),M("pointPicked",function(r){return i.onPointPicked(r)}),a()),t&2){let o,r,c,u;d(3),_(i.isSignedIn()?-1:3),d(5),R("ngModel",i.form.countryCode),d(3),R("ngModel",i.form.zip),v("placeholder",((o=i.selectedCountry())==null?null:o.postalCodeFormat)||"e.g. 6605"),d(),_((r=(r=i.selectedCountry())==null?null:r.postalCodeFormat)?12:-1,r),d(3),R("ngModel",i.form.placeName),d(4),R("ngModel",i.form.adminName1),d(3),R("ngModel",i.form.adminName2),d(3),R("ngModel",i.form.adminName3),d(4),R("ngModel",i.form.geonameId),d(3),R("ngModel",i.form.timezoneId),d(3),T(i.timezoneOptions()),d(3),R("ngModel",i.form.isPobox),d(5),R("ngModel",i.latInput),d(3),R("ngModel",i.lngInput),d(3),R("ngModel",i.form.comment),d(),v("disabled",i.saveState()==="saving"),d(),A(" ",i.saveState()==="saving"?"Creating\u2026":"Create postal code"," "),d(),_(i.saveState()==="error"?52:-1),d(3),v("latitude",(c=(c=i.pickedPoint())==null?null:c.lat)!==null&&c!==void 0?c:0)("longitude",(u=(u=i.pickedPoint())==null?null:u.lng)!==null&&u!==void 0?u:0)("zoom",i.pickedPoint()?14:2)("showCenterMarker",!1)("allowCreate",!1)("allowMove",!1)("hideFeatureMarkers",!0)("pickPointEnabled",!0)("pickedPoint",i.pickedPoint())("tall",!0)}},dependencies:[ke,pt,zn,Gn,Me,pi,mn,Ne,mt,fi,De,dt,nt],styles:[".page-header[_ngcontent-%COMP%]{margin:0 0 1rem}.page-header[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{margin:0;font-size:1.6rem}.notice[_ngcontent-%COMP%]{color:#8a5a00;background:#fff6e0;border:1px solid #f0dca0;border-radius:6px;padding:.5rem .75rem;font-size:.85rem;margin:0 0 1rem}.create-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.6rem;max-width:40rem;margin-bottom:1rem}.field-row[_ngcontent-%COMP%]{display:flex;gap:1rem;flex-wrap:wrap}.create-form[_ngcontent-%COMP%]   label[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem;font-size:.78rem;color:#666;flex:1;min-width:8rem}.create-form[_ngcontent-%COMP%]   label.grow[_ngcontent-%COMP%]{flex:2;min-width:12rem}.checkbox-label[_ngcontent-%COMP%]{flex-direction:row!important;align-items:center;gap:.4rem!important;justify-content:flex-start}.comment-label[_ngcontent-%COMP%]{min-width:100%}.field-hint[_ngcontent-%COMP%]{color:#888;font-size:.72rem}.create-form[_ngcontent-%COMP%]   input[type=text][_ngcontent-%COMP%], .create-form[_ngcontent-%COMP%]   select[_ngcontent-%COMP%]{border:1px solid #d8d8d8;border-radius:4px;padding:.4rem .6rem;font-size:.9rem;color:#1b1b1b}.create-form[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{align-self:flex-start;appearance:none;border:1px solid #1a5fb4;background:#1a5fb4;color:#fff;border-radius:4px;padding:.45rem 1rem;font-size:.9rem;cursor:pointer}.create-form[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:disabled{opacity:.6;cursor:default}.save-notice[_ngcontent-%COMP%]{font-size:.85rem;margin-left:.5rem}.save-error[_ngcontent-%COMP%]{color:#b3261e}
105.map-hint[_ngcontent-%COMP%]{color:#777;font-size:.8rem;margin:0 0 .4rem}"]})};var Wh=(e,n)=>n.isoCode,VV=(e,n)=>n.username;function UV(e,n){e&1&&(l(0,"p",0),s(1,"Loading country\u2026"),a())}function jV(e,n){e&1&&(l(0,"p",1),s(1,"No country found with this code."),a())}function BV(e,n){e&1&&(l(0,"p",1),s(1,"Could not load this country right now."),a())}function HV(e,n){if(e&1&&(l(0,"a",14),s(1),a()),e&2){let t=p();v("routerLink",n),d(),g(t.countryName)}}function $V(e,n){if(e&1&&s(0),e&2){let t=p();A(" ",t.countryName," ")}}function zV(e,n){if(e&1&&(l(0,"span",20),s(1),l(2,"span",19),s(3,"(FR)"),a()()),e&2){let t=p(2);d(),A("",t.isoFrenchName," ")}}function GV(e,n){if(e&1&&(l(0,"div",15)(1,"dt"),s(2,"ISO country name"),a(),l(3,"dd"),s(4),l(5,"span",19),s(6,"(EN)"),a(),y(7,zV,4,1,"span",20),a()()),e&2){let t=p();d(4),A(" ",t.isoEnglishName," "),d(3),_(t.isoFrenchName?7:-1)}}function WV(e,n){if(e&1&&(l(0,"a",22),s(1),a()),e&2){let t=n.$implicit,i=p(4);v("routerLink",i.countryPath(t)),d(),g(t.countryName)}}function qV(e,n){if(e&1&&(l(0,"div",13)(1,"dt"),s(2,"Depends from"),a(),l(3,"dd",21),I(4,WV,2,2,"a",22,Wh),a()()),e&2){let t=p(3);pe("wide",t.dependsFromCountries().length>1),d(4),T(t.dependsFromCountries())}}function JV(e,n){if(e&1&&(l(0,"div",13)(1,"dt"),s(2,"FIPS code"),a(),l(3,"dd"),s(4),a()()),e&2){let t=p();d(4),g(t.fips)}}function KV(e,n){if(e&1&&(l(0,"div",13)(1,"dt"),s(2,"Capital"),a(),l(3,"dd"),s(4),a()()),e&2){let t=p();d(4),g(t.capital)}}function YV(e,n){if(e&1&&(l(0,"div",13)(1,"dt"),s(2,"Area"),a(),l(3,"dd"),s(4),a()()),e&2){let t=p();d(4),A("",t.areaSqKm.toLocaleString()," km\xB2")}}function ZV(e,n){if(e&1&&(l(0,"div",13)(1,"dt"),s(2,"Population"),a(),l(3,"dd"),s(4),a()()),e&2){let t=p();d(4),g(t.population.toLocaleString())}}function QV(e,n){if(e&1&&(l(0,"div",13)(1,"dt"),s(2,"Currency"),a(),l(3,"dd"),s(4),a()()),e&2){let t=p();d(4),le("",t.currencyName," (",t.currencyCode,")")}}function XV(e,n){if(e&1&&(l(0,"div",15)(1,"dt"),s(2,"Languages"),a(),l(3,"dd"),s(4),a()()),e&2){let t=p(3);d(4),g(t.languageList().join(", "))}}function e8(e,n){if(e&1&&(l(0,"a",22),s(1),a()),e&2){let t=n.$implicit,i=p(4);v("routerLink",i.countryPath(t)),d(),g(t.countryName)}}function t8(e,n){if(e&1&&(l(0,"div",15)(1,"dt"),s(2,"Neighbours"),a(),l(3,"dd",21),I(4,e8,2,2,"a",22,Wh),a()()),e&2){let t=p(3);d(4),T(t.neighbourCountries())}}function n8(e,n){if(e&1&&(l(0,"a",23),s(1),a()),e&2){let t=n.$implicit,i=p(4);v("routerLink",i.countryPath(t)),d(),g(t.countryName)}}function i8(e,n){if(e&1&&(l(0,"div",15)(1,"dt"),s(2,"Also claimed by"),a(),l(3,"dd",21),I(4,n8,2,2,"a",23,Wh),a()()),e&2){let t=p(3);d(4),T(t.alsoClaimedByCountries())}}function o8(e,n){if(e&1&&(l(0,"div",13)(1,"dt"),s(2,"Postal code format"),a(),l(3,"dd")(4,"code"),s(5),a()()()),e&2){let t=p();d(5),g(t.postalCodeFormat)}}function r8(e,n){if(e&1&&(l(0,"a",26),s(1),a()),e&2){let t=p().$implicit;v("href",t.websiteUrl,Y),d(),g(t.websiteUrl)}}function a8(e,n){if(e&1&&(l(0,"tr",28),j(1,"td"),l(2,"td",29),s(3),a()()),e&2){let t=p(),i=t.$implicit,o=t.$index;pe("row-even",o%2===1),d(3),g(i.licenceText)}}function s8(e,n){if(e&1&&(l(0,"tr")(1,"td"),s(2),a(),l(3,"td"),s(4),a(),l(5,"td"),y(6,r8,2,2,"a",26),a(),l(7,"td"),s(8),a()(),y(9,a8,4,3,"tr",27)),e&2){let t=n.$implicit,i=n.$index;pe("row-even",i%2===1),d(2),g(t.username),d(2),g(t.description),d(2),_(t.websiteUrl?6:-1),d(2),g(t.licence),d(),_(t.licenceText?9:-1)}}function l8(e,n){if(e&1&&(l(0,"h2"),s(1,"National Data Providers"),a(),l(2,"div",24)(3,"table",25)(4,"thead")(5,"tr")(6,"th"),s(7,"Name"),a(),l(8,"th"),s(9,"Description"),a(),l(10,"th"),s(11,"Website"),a(),l(12,"th"),s(13,"Licence"),a()()(),l(14,"tbody"),I(15,s8,10,7,null,null,VV),a()()()),e&2){let t=p(3);d(15),T(t.countryDataSources())}}function c8(e,n){if(e&1&&(l(0,"nav",2)(1,"a",3),s(2,"Home"),a(),l(3,"span",4),s(4,"\u203A"),a(),l(5,"a",5),s(6,"Countries"),a(),l(7,"span",4),s(8,"\u203A"),a(),l(9,"span",6),s(10),a()(),l(11,"header",7)(12,"h1"),j(13,"img",8),s(14),l(15,"a",9),j(16,"img",10),a()()(),l(17,"div",11)(18,"dl",12)(19,"div",13)(20,"dt"),s(21,"Country name"),a(),l(22,"dd"),y(23,HV,2,2,"a",14)(24,$V,1,1),a()(),l(25,"div",13)(26,"dt"),s(27,"ISO code"),a(),l(28,"dd"),s(29),a()(),y(30,GV,8,2,"div",15)(31,qV,6,2,"div",16)(32,JV,5,1,"div",13)(33,KV,5,1,"div",13)(34,YV,5,1,"div",13)(35,ZV,5,1,"div",13)(36,QV,5,2,"div",13)(37,XV,5,1,"div",15)(38,t8,6,0,"div",15)(39,i8,6,0,"div",15)(40,o8,6,1,"div",13),a(),j(41,"img",17),a(),y(42,l8,17,0),j(43,"app-country-sub-nav",18)),e&2){let t,i=n,o=p(2);d(10),g(i.countryName),d(3),v("src",o.flagUrl(),Y)("alt",i.countryName+" flag"),d(),A(" ",i.countryName," "),d(),v("href",o.wikipediaUrl(),Y),d(8),_((t=o.featurePath())?23:24,t),d(6),gt("",i.isoCode,", ",i.isoNumeric," and ",i.iso3,""),d(),_(i.isoEnglishName?30:-1),d(),_(o.dependsFromCountries().length?31:-1),d(),_(i.fips?32:-1),d(),_(i.capital?33:-1),d(),_(i.areaSqKm!=null?34:-1),d(),_(i.population!=null?35:-1),d(),_(i.currencyCode?36:-1),d(),_(o.languageList(
105).length?37:-1),d(),_(o.neighbourCountries().length?38:-1),d(),_(o.alsoClaimedByCountries().length?39:-1),d(),_(i.postalCodeFormat?40:-1),d(),v("src",o.mapUrl(),Y)("alt",i.countryName+" map"),d(),_(o.countryDataSources().length?42:-1),d(),v("country",i)}}function d8(e,n){if(e&1&&y(0,c8,44,24),e&2){let t,i=p();_((t=i.country())?0:-1,t)}}var hu=class e{route=h(ve);countryInfo=h(it);dataSources=h(Pr);places=h(tt);title=h(H);meta=h(Ni);renderer=h(Ut);document=h($e);canonicalLink;state=E("loading");country=E(null);allCountries=E([]);allDataSources=E([]);countryDataSources=G(()=>{let n=this.country();return n?this.allDataSources().filter(t=>t.countryCode===n.isoCode):[]});languageList=G(()=>{let n=this.country();return n?.languages?n.languages.split(",").map(t=>t.trim()).filter(Boolean):[]});neighbourCountries=G(()=>this.resolveCodes(this.country()?.neighbours));dependsFromCountries=G(()=>this.resolveCodes(this.country()?.dependsFrom));alsoClaimedByCountries=G(()=>this.resolveCodes(this.country()?.alsoClaimedBy));resolveCodes(n){if(!n)return[];let t=new Map(this.allCountries().map(i=>[i.isoCode,i]));return n.split(",").map(i=>i.trim()).filter(Boolean).map(i=>t.get(i)).filter(i=>!!i)}featurePath=G(()=>{let n=this.country();return n?.geonameId?this.places.path({id:String(n.geonameId),name:n.countryName}):null});flagUrl=G(()=>{let n=this.country();return n?`https://img.geonames.org/flags/m/${n.isoCode.toLowerCase()}.png`:""});mapUrl=G(()=>{let n=this.country();return n?`https://img.geonames.org/img/country/250/${n.isoCode}.png`:""});wikipediaUrl=G(()=>{let n=this.country();return n?`https://en.wikipedia.org/wiki/${encodeURIComponent(n.countryName.replace(/ /g,"_"))}`:""});constructor(){this.dataSources.getDataSources().subscribe({next:n=>this.allDataSources.set(n),error:()=>{}}),this.route.paramMap.pipe(N(n=>(n.get("cc")??"").toUpperCase()),be(n=>this.countryInfo.getCountries().pipe(N(t=>({cc:n,countries:t}))))).subscribe({next:({cc:n,countries:t})=>{this.allCountries.set(t);let i=t.find(o=>o.isoCode===n);if(!i){this.country.set(null),this.state.set("not-found");return}this.country.set(i),this.state.set("loaded"),this.applySeoTags(i)},error:()=>this.state.set("error")})}countryPath(n){return`/countries/${n.isoCode}/${We(n.countryName)}.html`}applySeoTags(n){let t=`${n.countryName} \u2014 GeoNames UI`,i=`${n.countryName}: capital ${n.capital||"n/a"}, population ${n.population!=null?n.population.toLocaleString():"n/a"}, area ${n.areaSqKm!=null?n.areaSqKm.toLocaleString():"n/a"} km\xB2.`;this.title.setTitle(t),this.meta.updateTag({name:"description",content:i}),this.meta.updateTag({property:"og:title",content:t}),this.meta.updateTag({property:"og:description",content:i}),this.meta.updateTag({property:"og:type",content:"website"}),this.canonicalLink&&this.renderer.removeChild(this.document.head,this.canonicalLink);let o=this.renderer.createElement("link");o.setAttribute("rel","canonical"),o.setAttribute("href",this.countryPath(n)),this.renderer.appendChild(this.document.head,o),this.canonicalLink=o}ngOnDestroy(){this.canonicalLink&&this.renderer.removeChild(this.document.head,this.canonicalLink)}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-country-detail-page"]],decls:4,vars:1,consts:[[1,"placeholder"],[1,"placeholder","error"],["aria-label","Breadcrumb",1,"breadcrumb"],["routerLink","/"],[1,"sep"],["routerLink","/countries"],[1,"current"],[1,"page-header"],["width","30","height","20",1,"flag",3,"src","alt"],["target","_blank","rel","noopener noreferrer","title","Wikipedia article",1,"wikipedia-badge",3,"href"],["src","https://www.geonames.org/img/20px-Wikipedia-logo.png","alt","","width","18","height","18"],[1,"detail-layout"],[1,"facts"],[1,"fact"],[3,"routerLink"],[1,"fact","wide"],[1,"fact",3,"wide"],["loading","lazy",1,"country-map",3,"src","alt"],["active","details",3,"country"],[1,"lang-tag"],[1,"fact-secondary"],[1,"chip-row"],[1,"chip",3,"routerLink"],[1,"chip","chip-dispute",3,"routerLink"],[1,"table-scroll"],[1,"sources-table"],["target","_blank","rel","noopener noreferrer",3,"href"],[1,"licence-text-row",3,"row-even"],[1,"licence-text-row"],["colspan","3"]],template:function(t,i){if(t&1&&y(0,UV,2,0,"p",0)(1,jV,2,0,"p",1)(2,BV,2,0,"p",1)(3,d8,1,1),t&2){let o;_((o=i.state())==="loading"?0:o==="not-found"?1:o==="error"?2:o==="loaded"?3:-1)}},dependencies:[W,Jn],styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}.placeholder[_ngcontent-%COMP%]{color:#888;font-style:italic}.placeholder.error[_ngcontent-%COMP%]{color:#b3261e}.breadcrumb[_ngcontent-%COMP%]{font-size:.85rem;color:#555;margin-bottom:1rem;overflow-wrap:break-word}
105.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.breadcrumb[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.breadcrumb[_ngcontent-%COMP%]   .sep[_ngcontent-%COMP%]{margin:0 .35rem;color:#999}.breadcrumb[_ngcontent-%COMP%]   .current[_ngcontent-%COMP%]{color:#222;font-weight:600}.page-header[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{margin:0 0 1rem;font-size:1.9rem;line-height:1.15;display:flex;align-items:center;gap:.55rem}.flag[_ngcontent-%COMP%]{display:block;border-radius:2px;box-shadow:0 0 0 1px #e5e5e5}.wikipedia-badge[_ngcontent-%COMP%]{display:inline-flex;align-items:center;opacity:.75}.wikipedia-badge[_ngcontent-%COMP%]:hover{opacity:1}.wikipedia-badge[_ngcontent-%COMP%]   img[_ngcontent-%COMP%]{display:block}.detail-layout[_ngcontent-%COMP%]{display:flex;gap:1.5rem;align-items:flex-start}.facts[_ngcontent-%COMP%]{flex:1;min-width:0;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.75rem 1.5rem;margin:0;padding:1rem;background:#f8f9fa;border-radius:8px}.fact.wide[_ngcontent-%COMP%]{grid-column:1 / -1}.fact[_ngcontent-%COMP%]   dt[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;letter-spacing:.03em;color:#777}.fact[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]{margin:.1rem 0 0;font-size:1.05rem;font-weight:500}.fact[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none}.fact[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.fact-secondary[_ngcontent-%COMP%]{display:block;margin-top:.1rem;font-size:.8rem;font-weight:400;color:#888}.lang-tag[_ngcontent-%COMP%]{font-size:.75rem;font-weight:400;color:#999}.fact[_ngcontent-%COMP%]   dd[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:#eceef0;border-radius:3px;padding:.05rem .35rem;font-size:.95rem}.chip-row[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:.4rem;margin-top:.3rem}.chip[_ngcontent-%COMP%]{display:inline-block;background:#e8f0fb;color:#1a5fb4!important;border-radius:999px;padding:.15rem .65rem;font-size:.8rem;font-weight:500;text-decoration:none!important}.chip[_ngcontent-%COMP%]:hover{background:#d7e6f9}.chip-dispute[_ngcontent-%COMP%]{background:#fbf3d9;color:#8a6d00!important}.chip-dispute[_ngcontent-%COMP%]:hover{background:#f5e7b8}h2[_ngcontent-%COMP%]{margin:1.75rem 0 .5rem;font-size:1.05rem;color:#555}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto;margin-bottom:1rem}.sources-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.85rem}.sources-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .sources-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.35rem .6rem;border-bottom:1px solid #eee;text-align:left;vertical-align:top}.sources-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555}.sources-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr.row-even[_ngcontent-%COMP%]{background:#fafbfc}.sources-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}.sources-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#1a5fb4;text-decoration:none;word-break:break-all}.sources-table[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{text-decoration:underline}.licence-text-row[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding-top:0;color:#777;font-size:.8rem;font-style:italic;border-bottom:1px solid #eee}.country-map[_ngcontent-%COMP%]{max-width:250px;max-height:250px;width:auto;height:auto;flex-shrink:0;border-radius:6px;box-shadow:0 0 0 1px #e5e5e5;background:#f8f9fa}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}.page-header[_ngcontent-%COMP%]   h1[_ngcontent-%COMP%]{font-size:1.5rem}.detail-layout[_ngcontent-%COMP%]{flex-direction:column}.facts[_ngcontent-%COMP%]{grid-template-columns:1fr 1fr;padding:.75rem;gap:.6rem 1rem}.country-map[_ngcontent-%COMP%]{align-self:center}}"]})};var u8=(e,n)=>n.code;function m8(e,n){if(e&1&&(l(0,"tr")(1,"td")(2,"code"),s(3),a()(),l(4,"td"),s(5),a()()),e&2){let t=n.$implicit;d(3),g(t.code),d(2),g(t.description)}}var gu=class e{title=h(H);xmlExample=`<geonames>
106  <status message="we are afraid we could not find a administrative country subdivision for latitude and longitude :51.03,-20.0" value="12"/>
107</geonames>`;jsonExample=`{"status": {
108  "message": "we are afraid we could not find a administrative country subdivision for latitude and longitude :51.03,-20.0",
109  "value": 15
110}}`;errorCodes=[{code:10,description:"Authorization Exception"},{code:11,description:"record does not exist"},{code:12,description:"other error"},{code:13,description:"database timeout"},{code:14,description:"invalid parameter"},{code:15,description:"no result found"},{code:16,description:"duplicate exception"},{code:17,description:"postal code not found"},{code:18,description:"daily limit of credits exceeded"},{code:19,description:"hourly limit of credits exceeded"},{code:20,description:"weekly limit of credits exceeded"},{code:21,description:"invalid input"},{code:22,description:"server overloaded exception"},{code:23,description:"service not implemented"},{code:24,description:"radius too large"},{code:27,description:"maxRows too large"}];constructor(){this.title.setTitle("GeoNames Webservice Exception \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-webservice-exception-page"]],decls:34,vars:2,consts:[[1,"lead"],[1,"ws-section"],[1,"n
110ote"],[1,"code-example"],[1,"table-scroll"],[1,"param-table"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"GeoNames Webservice Exception"),a(),l(2,"p",0),s(3,` If a request for a GeoNames web service encounters an error, the following exception format is used for the returned document. GeoNames supports two flavors of web services: JSON and XML. The exception message returned is either JSON or XML and consists of a status element with a numeric error code and a message string.
111`),a(),l(4,"section",1)(5,"h2"),s(6,"XML Exception"),a(),l(7,"p",2),s(8,"Example:"),a(),l(9,"pre",3)(10,"code"),s(11),a()()(),l(12,"section",1)(13,"h2"),s(14,"JSON Exception"),a(),l(15,"p",2),s(16,"Example:"),a(),l(17,"pre",3)(18,"code"),s(19),a()()(),l(20,"section",1)(21,"h2"),s(22,"Error Codes"),a(),l(23,"div",4)(24,"table",5)(25,"thead")(26,"tr")(27,"th"),s(28,"Error Code"),a(),l(29,"th"),s(30,"Description"),a()()(),l(31,"tbody"),I(32,m8,6,2,"tr",null,u8),a()()()()),t&2&&(d(11),g(i.xmlExample),d(8),g(i.jsonExample),d(13),T(i.errorCodes))},styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem;font-size:.9rem}.ws-section[_ngcontent-%COMP%]{padding:1.25rem 0;border-top:1px solid #eee}.ws-section[_ngcontent-%COMP%]:first-of-type{border-top:none;padding-top:.5rem}.ws-section[_ngcontent-%COMP%]   h2[_ngcontent-%COMP%]{font-size:1.15rem;margin:0 0 .5rem}.note[_ngcontent-%COMP%]{color:#777;font-size:.82rem;margin:0 0 .4rem}code[_ngcontent-%COMP%]{background:#f8f9fa;padding:.05rem .35rem;border-radius:3px;font-size:.85em}.code-example[_ngcontent-%COMP%]{background:#f8f9fa;border:1px solid #e5e5e5;border-radius:6px;padding:.75rem 1rem;font-size:.8rem;line-height:1.45;overflow-x:auto;white-space:pre}.code-example[_ngcontent-%COMP%]   code[_ngcontent-%COMP%]{background:none;padding:0;font-size:inherit}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto}.param-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.88rem}.param-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .param-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.4rem .7rem;border-bottom:1px solid #eee;text-align:left;vertical-align:top}.param-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555;font-size:.8rem;text-transform:uppercase;letter-spacing:.03em}.param-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.param-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var p8=(e,n)=>n.service;function f8(e,n){if(e&1&&(l(0,"div"),s(1),a()),e&2){let t=n.$implicit;d(),g(t)}}function h8(e,n){if(e&1&&(l(0,"tr")(1,"td")(2,"code"),s(3),a()(),l(4,"td"),I(5,f8,2,1,"div",null,Re),a()()),e&2){let t=n.$implicit;d(3),g(t.service),d(2),T(t.cost)}}var Cu=class e{title=h(H);rows=[{service:"postalCodeSearch",cost:["1 credit per request"]},{service:"findNearbyPostalCodes",cost:["2 credits per request, 3 credits for more than 500 records"]},{service:"search",cost:["1 credit per request"]},{service:"timezone",cost:["1 credit per request"]},{service:"findNearbyWikipedia",cost:["2 credits per request"]},{service:"wikipediaSearch",cost:["1 credit per request"]},{service:"findNearestAddress",cost:["1 credit per request"]},{service:"gtopo30",cost:["0.1 credit per request"]},{service:"srtm3",cost:["0.2 credit per request *"]},{service:"srtm1",cost:["0.3 credit per request *"]},{service:"astergdem",cost:["0.3 credit per request *"]},{service:"findNearByWeatherJSON",cost:["2 credits per request"]},{service:"findNearbyPlaceName",cost:["3 credits per request"]},{service:"rssToGeoRSS",cost:["4 per item in feed (for geocoding)","0 if lat/lng are already included in feed"]},{service:"cities",cost:["4 credits per request"]},{service:"findNearby",cost:["4 credits per request"]},{service:"extendedFindNearby",cost:["4 credits per request"]},{service:"geonamesData.js",cost:["0.2 credit per request"]}];constructor(){this.title.setTitle("GeoNames Webservice Credits \u2014 GeoNames UI")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-webservice-credits-page"]],decls:31,vars:0,consts:[[1,"lead"],[1,"table-scroll"],[1,"param-table"],[1,"note"]],template:function(t,i){t&1&&(l(0,"h1"),s(1,"GeoNames Webservice Credits"),a(),l(2,"p",0),s(3,"Credits needed for a single web service call."),a(),l(4,"div",1)(5,"table",2)(6,"thead")(7,"tr")(8,"th"),s(9,"Service"),a(),l(10,"th"),s(11,"Credits"),a()()(),l(12,"tbody"),I(13,h8,7,1,"tr",null,p8),a()()(),l(15,"p",3),s(16," *: the elevation services "),l(17,"code"),s(18,"srtm3"),a(),s(19,", "),l(20,"code"),s(21,"srtm1"),a(),s(22," and "),l(23,"code"),s(24,"astergdem"),a(),s(25," allow passing a list of lats/lngs. In this case the number of credits consumed depends on how much the cache can be used - several identical or nearly identical lat/lng in the list count as only one. The formula used is: "),l(26,"code"),s(27,"Math.max(credits, credits * (10 * elevationResult.elevationCredits.numDistinctTiles + elevationResult.elevationCredits.numDistinctPositions) / 10.0)"),a(),s(28,`.
112`),a(),l(29,"p",3),s(30,"All other web services need 1 credit per request."),a()),t&2&&(d(13),T(i.rows))},styles:["[_nghost-%COMP%]{display:block;max-width:800px;margin:0 auto;padding:1rem}h1[_ngcontent-%COMP%]{margin:0 0 .25rem;font-size:1.6rem}.lead[_ngcontent-%COMP%]{color:#555;margin:0 0 1rem;font-size:.9rem}code[_ngcontent-%COMP%]{background:#f8f9fa;padding:.05rem .35rem;border-radius:3px;font-size:.85em}.table-scroll[_ngcontent-%COMP%]{overflow-x:auto}.param-table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%;font-size:.88rem}.param-table[_ngcontent-%COMP%]   th[_ngcontent-%COMP%], .param-table[_ngcontent-%COMP%]   td[_ngcontent-%COMP%]{padding:.4rem .7rem;border-bottom:1px solid #eee;text-align:left;vertical-align:top}.param-table[_ngcontent-%COMP%]   thead[_ngcontent-%COMP%]   th[_ngcontent-%COMP%]{border-bottom:2px solid #ddd;color:#555;font-size:.8rem;text-transform:uppercase;letter-spacing:.03em}.param-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:nth-child(2n){background:#fafbfc}.param-table[_ngcontent-%COMP%]   tbody[_ngcontent-%COMP%]   tr[_ngcontent-%COMP%]:hover{background:#eef2f7}
112.note[_ngcontent-%COMP%]{color:#777;font-size:.82rem;margin:.75rem 0 0;line-height:1.5}@media(max-width:600px){[_nghost-%COMP%]{padding:.75rem}}"]})};var C1=[{path:"",component:Jc,title:"GeoNames UI"},{path:"ui-search",component:wd},{path:"about.html",component:su},{path:"export",component:Ud},{path:"export/ws-overview.html",component:Ed},{path:"export/web-services.html",component:Md},{path:"export/client-libraries.html",component:Id},{path:"export/reverse-geocoding.html",component:nu},{path:"export/webservice-exception.html",component:gu},{path:"export/credits.html",component:Cu},{path:"commercial-webservices.html",component:Td},{path:"products/premium-data.html",component:Za},{path:"products/premium-dump.html",component:Za},{path:"products/premium-postalcodes.html",component:ou},{path:"products/premium-data-polygons.html",component:lu},{path:"products/reverse-geocoding-usa.html",component:ts},{path:"products/reverse-geocoding.html",component:ts},{path:"manual.html",component:Vd},{path:"ontology/documentation.html",component:jd},{path:"services.html",component:Hd},{path:"maps/capitals.html",component:Pd},{path:"maps/wikipedia.html",component:Dd},{path:"maps/addresses.html",component:Bd},{path:"maps/us-reverse-geocoder.html",component:Qa},{path:"maps/reverse-geocoder.html",component:Qa},{path:"maps/osm-reverse-geocoder.html",component:iu},{path:"statistics",component:$d},{path:"statistics/total.html",component:Xa},{path:"statistics/:slug",component:Xa},{path:"countries",component:Gd},{path:"countries/:cc/:slug",component:hu},{path:"subdivision-types/:id",component:kd},{path:"recent-changes.html",component:es},{path:"recent-changes/user/:username",component:es},{path:"data-sources.html",component:Jd},{path:"postal-codes-sources.html",component:Yd},{path:"ch-postal-code-import",component:Qd},{path:"postal-code-imports",component:eu},{path:"datasources",component:tu},{path:"history/:id",component:au},{path:"postal-codes/recent-changes",component:pu},{path:"postal-codes/new",component:fu},{path:"postal-codes/:id",component:ns},{path:"postal-codes/:id/history",component:uu},{path:"postal-codes/:id/:slug",component:ns},{matcher:m1,component:Od},{matcher:p1,component:Rd},{matcher:Nd("largest-cities-in-"),component:Ya,data:{kind:"cities"}},{matcher:Nd("highest-mountains-in-"),component:Ya,data:{kind:"mountains"}},{matcher:Nd("other-names-for-"),component:Ld},{path:":id/:slug",component:Ka},{path:":id",component:Ka},{path:"**",redirectTo:""}];var _1=(e,n)=>{let t=h(qe);return n(e).pipe(Ze(i=>(i instanceof en&&i.status===401&&e.url.startsWith("/api/")&&t.currentUser()!==null&&t.clearStaleSession(),zt(()=>i))))};var v1={providers:[Vv({eventCoalescing:!0}),Nh(C1),Uy(Vy()),rh(sh(),ah([_1]))]};var g8=(e,n)=>n.key,C8=(e,n)=>n.label+n.href;function _8(e,n){if(e&1&&(l(0,"li",17),s(1),a()),e&2){let t=p().$implicit;d(),g(t.label)}}function v8(e,n){if(e&1){let t=$();l(0,"li")(1,"a",18),M("click",function(){S(t);let o=p(3);return w(o.closeMobileNav())}),s(2),a()()}if(e&2){let t=p().$implicit;d(),v("routerLink",t.href)("fragment",t.fragment),d(),g(t.label)}}function y8(e,n){if(e&1){let t=$();l(0,"li")(1,"a",19),M("click",function(){S(t);let o=p(3);return w(o.closeMobileNav())}),s(2),a()()}if(e&2){let t=p().$implicit;d(),v("href",t.href,Y),d(),g(t.label)}}function b8(e,n){if(e&1&&y(0,_8,2,1,"li",17)(1,v8,3,3,"li")(2,y8,3,2,"li"),e&2){let t=n.$implicit;_(t.header?0:t.internal?1:2)}}function x8(e,n){if(e&1){let t=$();l(0,"li",13)(1,"button",14),M("click",function(){let o=S(t).$implicit,r=p();return w(r.toggleDropdown(o.key))}),s(2),j(3,"span",15),a(),l(4,"ul",16),I(5,b8,3,1,null,null,C8),a()()}if(e&2){let t=n.$implicit,i=p();pe("open",i.openDropdown()===t.key),d(2),A(" ",t.label," "),d(3),T(t.links)}}function S8(e,n){if(e&1&&(l(0,"span",27),s(1),a()),e&2){let t=p(2);d(),g(t.loginError())}}function w8(e,n){if(e&1){let t=$();l(0,"form",20),M("submit",function(o){S(t);let r=p();return w(r.onLoginSubmit(o))}),l(1,"input",21),F("ngModelChange",function(o){S(t);let r=p();return L(r.loginForm.username,o)||(r.loginForm.username=o),w(o)}),a(),l(2,"input",22),F("ngModelChange",function(o){S(t);let r=p();return L(r.loginForm.password,o)||(r.loginForm.password=o),w(o)}),a(),l(3,"label",23)(4,"input",24),F("ngModelChange",function(o){S(t);let r=p();return L(r.loginForm.rememberme,o)||(r.loginForm.rememberme=o),w(o)}),a(),s(5," Stay signed in "),a(),l(6,"button",25),s(7),a(),l(8,"button",26),M("click",function(){S(t);let o=p();return w(o.onLoginCancel())}),s(9,"Cancel"),a(),y(10,S8,2,1,"span",27),a()}if(e&2){let t=p();d(),R("ngModel",t.loginForm.username),v("disabled",t.loggingIn()),d(),R("ngModel",t.loginForm.password),v("disabled",t.loggingIn()),d(2),R("ngModel",t.loginForm.rememberme),v("disabled",t.loggingIn()),d(2),v("disabled",t.loggingIn()),d(),A(" ",t.loggingIn()?"Signing in\u2026":"Sign in"," "),d(),v("disabled",t.loggingIn()),d(2),_(t.loginError()?10:-1)}}function E8(e,n){if(e&1){let t=$();l(0,"li")(1,"a",32),M("click",function(){S(t);let o=p(3);return w(o.closeMobileNav())}),s(2,"Postal code imports"),a()(),j(3,"li",30)}}function M8(e,n){if(e&1){let t=$();l(0,"li",17),s(1),a(),j(2,"li",30),y(3,E8,4,0),l(4,"li")(5,"a",31),M("click",function(o){S(t);let r=p(2);return w(r.onSignOutClick(o))}),s(6,"Sign out"),a()()}if(e&2){let t=p(2);d(),A("Signed in as ",n.userName,""),d(2),_(t.isGeoNamesTeam()?3:-1)}}function P8(e,n){if(e&1){let t=$();l(0,"li")(1,"a",31),M("click",function(o){S(t);let r=p(2);return w(r.onSignInClick(o))}),s(2,"Sign in"),a()(),l(3,"li")(4,"a",31),M("click",function(o){S(t);let r=p(2);return w(r.onSignInClick(o))}),s(5,"Reset password"),a()(),j(6,"li",30),l(7,"li")(8,"a",31),M("click",function(o){S(t);let r=p(2);return w(r.onSignInClick(o))}),s(9,"Create an account"),a()()}}function D8(e,n){if(e&1&&(l(0,"span",29),s(1),a()),e&2){let t=p(2);
112d(),g(t.loginNotice())}}function I8(e,n){if(e&1){let t=$();l(0,"div",28)(1,"button",14),M("click",function(){S(t);let o=p();return w(o.toggleDropdown("user"))}),s(2),j(3,"span",15),a(),l(4,"ul",16),y(5,M8,7,2)(6,P8,10,0),a()(),y(7,D8,2,1,"span",29)}if(e&2){let t,i,o=p();pe("open",o.openDropdown()==="user"),d(2),A(" ",(t=(t=o.currentUser())==null?null:t.userName)!==null&&t!==void 0?t:"Account"," "),d(3),_((i=o.currentUser())?5:6,i),d(2),_(o.loginNotice()?7:-1)}}var T8=[{label:"GeoNames.org",href:"/about.html",internal:!0},{label:"Blog",href:"https://geonames.wordpress.com/"},{label:"Press",href:"/about.html",fragment:"presscoverage",internal:!0},{label:"Our team",href:"https://www.geonames.org/team.html"},{label:"Terms and conditions",href:"/export",fragment:"terms",internal:!0},{label:"Data",href:"",header:!0},{label:"Main sources",href:"/data-sources.html",internal:!0},{label:"Ontology",href:"/ontology/documentation.html",internal:!0},{label:"Want to help?",href:"",header:!0},{label:"Learn how to contribute",href:"https://forum.geonames.org/gforum/posts/list/25.page"},{label:"Become an ambassador",href:"https://www.geonames.org/team.html#ambassadors"},{label:"Become a sponsor",href:"https://www.geonames.org/donations.html"}],O8=[{label:"Wiki demo",href:"",header:!0},{label:"Capitals",href:"/maps/capitals.html",internal:!0},{label:"Wikipedia links",href:"/maps/wikipedia.html",internal:!0},{label:"Browse data",href:"",header:!0},{label:"Countries",href:"/countries",internal:!0},{label:"Postal codes",href:"https://www.geonames.org/postal-codes/"},{label:"Recent activity",href:"",header:!0},{label:"Latest updates",href:"/recent-changes.html",internal:!0},{label:"Statistics",href:"/statistics",internal:!0}],N8=[{label:"Readme",href:"https://download.geonames.org/export/dump/readme.txt"},{label:"Free gazetteer data",href:"https://download.geonames.org/export/dump/"},{label:"Free postal codes",href:"https://download.geonames.org/export/zip"},{label:"Premium data",href:"/products/premium-data.html",internal:!0}],k8=[{label:"Web services",href:"",header:!0},{label:"Overview",href:"/export/ws-overview.html",internal:!0},{label:"Documentation",href:"/export/web-services.html",internal:!0},{label:"Client libraries",href:"/export/client-libraries.html",internal:!0},{label:"Premium API",href:"/commercial-webservices.html",internal:!0}],A8=[{label:"Support",href:"",header:!0},{label:"Forum",href:"https://forum.geonames.org/"},{label:"FAQ",href:"https://forum.geonames.org/gforum/forums/show/6.page"},{label:"User manual",href:"/manual.html",internal:!0},{label:"Consulting",href:"/services.html",internal:!0},{label:"Subscribe",href:"",header:!0},{label:"Blog",href:"https://geonames.wordpress.com/feed/"},{label:"Forum",href:"https://forum.geonames.org/gforum/rss/recentTopics.page"},{label:"Google group",href:"https://groups.google.com/group/geonames/feed/rss_v2_0_msgs.xml"},{label:"Recent changes",href:"https://www.geonames.org/recent-changes.xml"},{label:"Follow",href:"",header:!0},{label:"Facebook",href:"https://www.facebook.com/GeoNames"},{label:"Twitter",href:"https://twitter.com/geonames"}],_u=class e{constructor(n){this.host=n}host;menus=[{key:"about",label:"About",links:T8},{key:"browse",label:"Browse",links:O8},{key:"download",label:"Download",links:N8},{key:"api",label:"API",links:k8},{key:"help",label:"Help",links:A8}];auth=h(qe);router=h(Dt);currentUser=this.auth.currentUser;isGeoNamesTeam=G(()=>Number(this.currentUser()?.userLevel)>100);searchQuery="";mobileNavOpen=E(!1);openDropdown=E(null);showLoginForm=E(!1);loginNotice=E(null);loginError=E(null);loggingIn=E(!1);loginForm={username:"",password:"",rememberme:!0};toggleMobileNav(){this.mobileNavOpen.update(n=>!n)}closeMobileNav(){this.mobileNavOpen.set(!1),this.openDropdown.set(null)}toggleDropdown(n){this.openDropdown.update(t=>t===n?null:n)}onSignInClick(n){n.preventDefault(),this.openDropdown.set(null),this.showLoginForm.set(!0),this.loginNotice.set(null),this.loginError.set(null)}onLoginSubmit(n){n.preventDefault(),this.loggingIn.set(!0),this.loginError.set(null),this.auth.login(this.loginForm).subscribe({next:t=>{this.loggingIn.set(!1),this.showLoginForm.set(!1),this.loginForm={username:"",password:"",rememberme:!0},this.loginNotice.set(`Signed in as ${t.userName}.`)},error:t=>
112{this.loggingIn.set(!1),this.loginError.set(t instanceof Error?t.message:"Could not sign in.")}})}onLoginCancel(){this.showLoginForm.set(!1),this.loginError.set(null)}onSignOutClick(n){n.preventDefault(),this.openDropdown.set(null),this.auth.logout().subscribe(()=>this.loginNotice.set("You have been signed out."))}onSearchSubmit(n){n.preventDefault();let t=this.searchQuery.trim();if(!t)return;this.mobileNavOpen.set(!1);let i=Sd(t);if(i){this.router.navigateByUrl(Er(i.lat,i.lng));return}this.router.navigate(["/ui-search"],{queryParams:{q:t}})}onDocumentClick(n){this.host.nativeElement.contains(n.target)||this.openDropdown.set(null)}static \u0275fac=function(t){return new(t||e)(me(Lt))};static \u0275cmp=k({type:e,selectors:[["app-nav-bar"]],hostBindings:function(t,i){t&1&&M("click",function(r){return i.onDocumentClick(r)},!1,O_)},decls:19,vars:5,consts:[[1,"navbar"],[1,"navbar-inner"],["type","button","aria-label","Toggle navigation",1,"nav-toggle",3,"click"],[1,"icon-bar"],["routerLink","/",1,"brand",3,"click"],[1,"nav-collapse"],[1,"nav"],[1,"dropdown",3,"open"],[1,"form-search",3,"submit"],["name","q","placeholder","Paris, Mount Everest, New York","type","text",1,"search-query",3,"ngModelChange","ngModel"],["type","submit","title","Search",1,"btn"],[1,"user-area"],[1,"login-form"],[1,"dropdown"],["type","button",1,"dropdown-toggle",3,"click"],[1,"caret"],[1,"dropdown-menu"],[1,"nav-header"],[3,"click","routerLink","fragment"],["target","_blank","rel","noopener noreferrer",3,"click","href"],[1,"login-form",3,"submit"],["name","username","placeholder","username","type","text","required","",1,"input-small",3,"ngModelChange","ngModel","disabled"],["name","password","placeholder","password","type","password","required","",1,"input-small",3,"ngModelChange","ngModel","disabled"],[1,"checkbox"],["name","rememberme","type","checkbox",3,"ngModelChange","ngModel","disabled"],["type","submit",1,"btn","btn-success",3,"disabled"],["type","button",1,"btn",3,"click","disabled"],[1,"login-notice","login-error"],[1,"dropdown","user-dropdown"],[1,"login-notice"],[1,"divider"],["href","#",3,"click"],["routerLink","/postal-code-imports",3,"click"]],template:function(t,i){t&1&&(l(0,"nav",0)(1,"div",1)(2,"button",2),M("click",function(){return i.toggleMobileNav()}),j(3,"span",3)(4,"span",3)(5,"span",3),a(),l(6,"a",4),M("click",function(){return i.closeMobileNav()}),s(7,"GeoNames"),a(),l(8,"div",5)(9,"ul",6),I(10,x8,7,3,"li",7,g8),a(),l(12,"form",8),M("submit",function(r){return i.onSearchSubmit(r)}),l(13,"input",9),F("ngModelChange",function(r){return L(i.searchQuery,r)||(i.searchQuery=r),r}),a(),l(14,"button",10),s(15,"Search"),a()(),l(16,"div",11),y(17,w8,11,10,"form",12)(18,I8,8,5),a()()()()),t&2&&(d(2),_e("aria-expanded",i.mobileNavOpen()),d(6),pe("open",i.mobileNavOpen()),d(2),T(i.menus),d(3),R("ngModel",i.searchQuery),d(4),_(i.showLoginForm()?17:18))},dependencies:[W,ke,pt,Me,pi,Ne,mt,Co,De,dt],styles:["[_nghost-%COMP%]{display:block}.navbar[_ngcontent-%COMP%]{background:#43a047;position:relative;z-index:20}.navbar-inner[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1rem;padding:0 1rem;max-width:1100px;margin:0 auto}.brand[_ngcontent-%COMP%]{color:#fff;font-weight:700;font-size:1.15rem;text-decoration:none;letter-spacing:-.01em;padding:.85rem 0}.nav-toggle[_ngcontent-%COMP%]{display:none;flex-direction:column;gap:3px;background:none;border:1px solid rgba(255,255,255,.4);border-radius:4px;padding:.4rem .5rem;cursor:pointer;margin-left:auto}.nav-toggle[_ngcontent-%COMP%]   .icon-bar[_ngcontent-%COMP%]{width:16px;height:2px;background:#fff;display:block}.nav-collapse[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1rem;flex:1}.nav[_ngcontent-%COMP%]{display:flex;list-style:none;margin:0;padding:0}.dropdown[_ngcontent-%COMP%]{position:relative}.dropdown-toggle[_ngcontent-%COMP%]{appearance:none;background:none;border:none;color:#ffffffe6;font:inherit;font-size:.9rem;padding:.85rem .7rem;cursor:pointer;display:inline-flex;align-items:center;gap:.3rem}.dropdown-toggle[_ngcontent-%COMP%]:hover{color:#fff}.caret[_ngcontent-%COMP%]{border-top:4px solid currentColor;border-left:4px solid transparent;border-right:4px solid transparent;display:inline-block;opacity:.7}.dropdown-menu[_ngcontent-%COMP%]{display:none;position:absolute;top:100%;left:0;background:#fff;border:1px solid #e5e5e5;border-radius:6px;box-shadow:0 4px 12px #0000001f;list-style:none;margin:4px 0 0;padding:.35rem 0;min-width:12rem;white-space:nowrap}.dropdown.open[_ngcontent-%COMP%]   .dropdown-menu[_ngcontent-%COMP%]{display:block}.dropdown-menu[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{display:block;padding:.4rem 1rem;color:#333;text-decoration:none;font-size:.9rem}.dropdown-menu[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{background:#f0f4fa;color:#2e7d32}.dropdown-menu[_ngcontent-%COMP%]   .nav-header[_ngcontent-%COMP%]{padding:.4rem 1rem .15rem;font-size:.7rem;text-transform:uppercase;letter-spacing:.03em;color:#999}.dropdown-menu[_ngcontent-%COMP%]   .divider[_ngcontent-%COMP%]{height:1px;background:#eee;margin:.3rem 0}.form-search[_ngcontent-%COMP%]{display:flex;gap:.3rem;margin-left:auto}.search-query[_ngcontent-%COMP%]{border:none;border-radius:4px;padding:.3rem .6rem;font-size:.85rem;width:14rem}.form-search[_ngcontent-%COMP%]   .btn[_ngcontent-%COMP%]{appearance:none;border:1px solid rgba(255,255,255,.4);background:#ffffff1a;color:#fff;border-radius:4px;padding:.3rem .6rem;font-size:.85rem;cursor:pointer}.user-area[_ngcontent-%COMP%]{position:relative}.user-area[_ngcontent-%COMP%]   .dropdown-menu[_ngcontent-%COMP%]{left:auto;right:0}.login-form[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.4rem;flex-wrap:wrap;position:relative}.login-form[_ngcontent-%COMP%]   input[type=text][_ngcontent-%COMP%], .login-form[_ngcontent-%COMP%]   input[type=password][_ngcontent-%COMP%]{border:none;border-radius:4px;padding:.3rem .5rem;font-size:.85rem;width:8rem}.login-form[_ngcontent-%COMP%]   .checkbox[_ngcontent-%COMP%]{color:#fff;font-size:.8rem;display:flex;align-items:center;gap:.25rem;white-space:nowrap}.login-form[_ngcontent-%COMP%]   .btn[_ngcontent-%COMP%]{appearance:none;border:none;border-radius:4px;padding:.3rem .6rem;font-size:.85rem;cursor:pointer}.login-form[_ngcontent-%COMP%]   .btn-success[_ngcontent-%COMP%]{background:#2e7d32;color:#fff}.login-form[_ngcontent-%COMP%]   .btn[_ngcontent-%COMP%]:not(.btn-success){background:#ffffff26;color:#fff}.login-notice[_ngcontent-%COMP%]{flex-basis:100%;color:#ffe082;font-size:.75rem}.login-notice.login-error[_ngcontent-%COMP%]{color:#ff8a80}
112@media(max-width:900px){.nav-toggle[_ngcontent-%COMP%]{display:inline-flex}.nav-collapse[_ngcontent-%COMP%]{display:none;flex-direction:column;align-items:stretch;position:absolute;top:100%;left:0;right:0;background:#43a047;padding:.5rem 1rem 1rem}.nav-collapse.open[_ngcontent-%COMP%]{display:flex}.nav[_ngcontent-%COMP%]{flex-direction:column}.dropdown-menu[_ngcontent-%COMP%]{position:static;box-shadow:none;border:none;background:#ffffff0f;margin:0 0 .3rem}.dropdown-menu[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#fff}.dropdown-menu[_ngcontent-%COMP%]   li[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{background:#ffffff1a;color:#fff}.form-search[_ngcontent-%COMP%]{margin:.5rem 0 0}.search-query[_ngcontent-%COMP%]{flex:1}.user-area[_ngcontent-%COMP%]   .dropdown-menu[_ngcontent-%COMP%]{right:auto;left:0}}"]})};function R8(e,n){if(e&1){let t=$();l(0,"div",0)(1,"p")(2,"strong"),s(3,"We've launched a new version of this site."),a(),s(4," Some pages may look and behave a little differently while we finish the transition \u2014 thanks for your patience. "),a(),l(5,"button",1),M("click",function(){S(t);let o=p();return w(o.dismiss())}),s(6,"\xD7"),a()()}}var y1="site_notice_dismissed",F8=3600*24*365,vu=class e{platformId=h(Zt);visible=E(!1);ngOnInit(){un(this.platformId)&&(this.hasCookie(y1)||this.visible.set(!0))}dismiss(){this.visible.set(!1),un(this.platformId)&&(document.cookie=`${y1}=1; path=/; max-age=${F8}; SameSite=Lax`)}hasCookie(n){return document.cookie.split("; ").some(t=>t.trim().startsWith(`${n}=`))}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-site-notice"]],decls:1,vars:1,consts:[["role","status",1,"site-notice"],["type","button","aria-label","Dismiss notice",1,"dismiss",3,"click"]],template:function(t,i){t&1&&y(0,R8,7,0,"div",0),t&2&&_(i.visible()?0:-1)},styles:[".site-notice[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;gap:.75rem;background:#e8f5e9;border-bottom:1px solid #c8e6c9;padding:.5rem 1rem;font-size:.85rem;color:#1b5e20;text-align:center}.site-notice[_ngcontent-%COMP%]   p[_ngcontent-%COMP%]{margin:0}.site-notice[_ngcontent-%COMP%]   .dismiss[_ngcontent-%COMP%]{appearance:none;border:none;background:none;color:#1b5e20;font-size:1.1rem;line-height:1;cursor:pointer;padding:.1rem .3rem;flex-shrink:0}.site-notice[_ngcontent-%COMP%]   .dismiss[_ngcontent-%COMP%]:hover{opacity:.7}@media(max-width:600px){.site-notice[_ngcontent-%COMP%]{flex-direction:column;gap:.35rem;text-align:left}}"]})};var L8=(e,n)=>n.label;function V8(e,n){if(e&1&&(l(0,"a",6),s(1),a()),e&2){let t=p().$implicit;v("routerLink",t.href),d(),g(t.label)}}function U8(e,n){if(e&1&&(l(0,"a",7),s(1),a()),e&2){let t=p().$implicit;v("href",t.href,Y),d(),g(t.label)}}function j8(e,n){e&1&&(l(0,"span",8),s(1,"\u2022"),a())}function B8(e,n){if(e&1&&y(0,V8,2,2,"a",6)(1,U8,2,2,"a",7)(2,j8,2,0,"span",8),e&2){let t=n.$implicit,i=n.$index,o=n.$count;_(t.internal?0:1),d(2),_(i!==o-1?2:-1)}}var H8=[{label:"GeoNames Home",href:"/",internal:!0},{label:"Postal Codes",href:"https://www.geonames.org/postal-codes/"},{label:"Download / Webservice",href:"/export",internal:!0},{label:"Forum",href:"http://forum.geonames.org"},{label:"Blog",href:"http://geonames.wordpress.com"},{label:"Sitemap",href:"https://www.geonames.org/sitemap.html"}],yu=class e{links=H8;static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-site-footer"]],decls:11,vars:0,consts:[[1,"page-footer"],[1,"contact-line"],["href","mailto:[email protected]"],["src","https://www.geonames.org/img/smallant.gif","alt","ant",1,"ant-icon"],["href","https://www.unxos.com","target","_blank","rel","noopener noreferrer"],[1,"links-line"],[3,"routerLink"],["target","_blank","rel","noopener noreferrer",3,"href"],[1,"separator"]],template:function(t,i){t&1&&(l(0,"footer",0)(1,"p",1)(2,"a",2),s(3,"[email protected]"),a(),j(4,"img",3),s(5," by "),l(6,"a",4),s(7,"unxos gmbh"),a()(),l(8,"p",5),I(9,B8,3,2,null,null,L8),a()()),t&2&&(d(9),T(i.links))},dependencies:[W],styles:[".page-footer[_ngcontent-%COMP%]{margin-top:2rem;padding:1.5rem 1rem 2rem;border-top:1px solid #eee;text-align:center;color:#888;font-size:.8rem}.contact-line[_ngcontent-%COMP%]{margin:0 0 .5rem}.ant-icon[_ngcontent-%COMP%]{vertical-align:middle;margin:0 .6rem}.links-line[_ngcontent-%COMP%]{margin:0}.page-footer[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]{color:#888;text-decoration:none}.page-footer[_ngcontent-%COMP%]   a[_ngcontent-%COMP%]:hover{color:#1
112a5fb4;text-decoration:underline}.separator[_ngcontent-%COMP%]{margin:0 .5rem;color:#ccc}"]})};var bu=class e{static \u0275fac=function(t){return new(t||e)};static \u0275cmp=k({type:e,selectors:[["app-root"]],decls:5,vars:0,template:function(t,i){t&1&&(j(0,"app-nav-bar")(1,"app-site-notice"),l(2,"main"),j(3,"router-outlet"),a(),j(4,"app-site-footer"))},dependencies:[Va,_u,vu,yu],encapsulation:2})};Zf(bu,v1).catch(e=>console.error(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.