PageSourceSearch

https://www.rijksmuseumboerhaave.nl/_next/static/chunks/788.c64ab6fd9e22eaa5.js

js rijksmuseumboerhaave.nl collected 2026-09-24 09:21:25 UTC 38,438 bytes, 2 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[788],{3549:function(t,e,i){i.d(e,{D:function(){return f},a:function(){return h},c:function(){return A},d:function(){return p},g:function(){return g},p:function(){return v},r:function(){return S},t:function(){return u},w:function(){return function t(e,i,s=[]){return null!==e&&Array.isArray(e)?e.map((e,r)=>{if(b(e)){let n=e._key;if("string"==typeof n)return t(e,i,s.concat({_key:n,_index:r}))}return t(e,i,s.concat(r))}):b(e)?Object.fromEntries(Object.entries(e).map(([e,r])=>[e,t(r,i,s.concat(e))])):i(e,s)}}});let s=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,r=/_key\s*==\s*['"](.*)['"]/,n=/^\d*:\d*$/;function a(t){return"number"==typeof t||"string"==typeof t&&/^\[\d+\]$/.test(t)}function l(t){return"string"==typeof t?r.test(t.trim()):"object"==typeof t&&"_key"in t}function o(t){if("string"==typeof t&&n.test(t))return!0;if(!Array.isArray(t)||2!==t.length)return!1;let[e,i]=t;return("number"==typeof e||""===e)&&("number"==typeof i||""===i)}function h(t,e,i){let s="string"==typeof e?c(e):e;if(!Array.isArray(s))throw Error("Path must be an array or a string");let r=t;for(let t=0;t<s.length;t++){let e=s[t];if(a(e)){if(!Array.isArray(r))return i;r=r[e]}if(l(e)){if(!Array.isArray(r))return i;r=r.find(t=>t._key===e._key)}if("string"==typeof e&&(r="object"==typeof r&&null!==r?r[e]:void 0),typeof r>"u")return i}return r}function u(t){if(!Array.isArray(t))throw Error("Path is not an array");return t.reduce((t,e,i)=>{let s=typeof e;if("number"===s)return`${t}[${e}]`;if("string"===s)return`${t}${0===i?"":"."}${e}`;if(l(e)&&e._key)return`${t}[_key=="${e._key}"]`;if(Array.isArray(e)){let[i,s]=e;return`${t}[${i}:${s}]`}throw Error(`Unsupported path segment \`${JSON.stringify(e)}\``)},"")}function c(t){if("string"!=typeof t)throw Error("Path is not a string");let e=t.match(s);if(!e)throw Error("Invalid path string");return e.map(d)}function d(t){return a(t)?Number(t.replace(/[^\d]/g,"")):l(t)?{_key:t.match(r)[1]}:o(t)?function(t){let[e,i]=t.split(":").map(t=>""===t?t:Number(t));return[e,i]}(t):t}var p=Object.freeze({__proto__:null,fromString:c,get:h,isIndexSegment:a,isIndexTuple:o,isKeySegment:l,reKeySegment:r,toString:u});let f="drafts.";function g(t){return t.startsWith(f)?t.slice(f.length):t}let y={"\f":"\\f","\n":"\\n","\r":"\\r","	":"\\t","'":"\\'","\\":"\\\\"},m={"\\f":"\f","\\n":`
2`,"\\r":"\r","\\t":"	","\\'":"'","\\\\":"\\"};function v(t){let e;let i=[],s=/\['(.*?)'\]|\[(\d+)\]|\[\?\(@\._key=='(.*?)'\)\]/g;for(;null!==(e=s.exec(t));){if(void 0!==e[1]){let t=e[1].replace(/\\(\\|f|n|r|t|')/g,t=>m[t]);i.push(t);continue}if(void 0!==e[2]){i.push(parseInt(e[2],10));continue}if(void 0!==e[3]){let t=e[3].replace(/\\(\\')/g,t=>m[t]);i.push({_key:t,_index:-1});continue}}return i}function S(t,e){var i;if(!(null!=e&&e.mappings))return;let s=(i=t.map(t=>{if("string"==typeof t||"number"==typeof t)return t;if(-1!==t._index)return t._index;throw Error(`invalid segment:${JSON.stringify(t)}`)}),`$${i.map(t=>"string"==typeof t?`['${t.replace(/[\f\n\r\t'\\]/g,t=>y[t])}']`:"number"==typeof t?`[${t}]`:""!==t._key?`[?(@._key=='${t._key.replace(/['\\]/g,t=>y[t])}')]`:`[${t._index}]`).join("")}`);if(void 0!==e.mappings[s])return{mapping:e.mappings[s],matchedPath:s,pathSuffix:""};let r=Object.entries(e.mappings).filter(([t])=>s.startsWith(t)).sort(([t],[e])=>e.length-t.length);if(0==r.length)return;let[n,a]=r[0],l=s.substring(n.length);return{mapping:a,matchedPath:n,pathSuffix:l}}function b(t){return"object"==typeof t&&null!==t}function A(t){let{baseUrl:e,workspace:i="default",tool:s="default",id:r,type:n,path:a,projectId:l,dataset:o}=t;if(!e)throw Error("baseUrl is required");if(!a)throw Error("path is required");if(!r)throw Error("id is required");if("/"!==e&&e.endsWith("/"))throw Error("baseUrl must not end with a slash");let h="default"===i?void 0:i,c="default"===s?void 0:s,d=g(r),p=Array.isArray(a)?u(a.map(t=>{if("string"==typeof t||"number"==typeof t)return t;if(""!==t._key)return{_key:t._key};if(-1!==t._index)return t._index;throw Error(`invalid segment:${JSON.stringify(t)}`)})):a,y=new URLSearchParams({baseUrl:e,id:d,type:n,path:p});h&&y.set("workspace",h),c&&y.set("tool",c),l&&y.set("projectId",l),o&&y.set("dataset",o),r.startsWith(f)&&y.set("isDraft","");let m=["/"===e?"":e];h&&m.push(h);let v=["mode=presentation",`id=${d}`,`type=${n}`,`path=${encodeURIComponent(p)}`];return c&&v.push(`tool=${c}`),m.push("intent","edit",`${v.join(";")}?${y}`),m.join("/")}}
2,90788:function(t,e,i){i.r(e),i.d(e,{default:function(){return z}});var s=i(57437),r=i(3549);let n=t=>t;var a=i(52498),l=i(80624),o=i(25566);let h="object"==typeof performance&&performance&&"function"==typeof performance.now?performance:Date,u=new Set,c="object"==typeof o&&o?o:{},d=(t,e,i,s)=>{"function"==typeof c.emitWarning?c.emitWarning(t,e,i,s):console.error(`[${i}] ${e}: ${t}`)},p=globalThis.AbortController,f=globalThis.AbortSignal;if(void 0===p){f=class{onabort;_onabort=[];reason;aborted=!1;addEventListener(t,e){this._onabort.push(e)}},p=class{constructor(){e()}signal=new f;abort(t){if(!this.signal.aborted){for(let e of(this.signal.reason=t,this.signal.aborted=!0,this.signal._onabort))e(t);this.signal.onabort?.(t)}}};let t=c.env?.LRU_CACHE_IGNORE_AC_WARNING!=="1",e=()=>{t&&(t=!1,d("AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.","NO_ABORT_CONTROLLER","ENOTSUP",e))}}let g=t=>!u.has(t);Symbol("type");let y=t=>t&&t===Math.floor(t)&&t>0&&isFinite(t),m=t=>y(t)?t<=256?Uint8Array:t<=65536?Uint16Array:t<=4294967296?Uint32Array:t<=Number.MAX_SAFE_INTEGER?v:null:null;class v extends Array{constructor(t){super(t),this.fill(0)}}class S{heap;length;static #t=!1;static create(t){let e=m(t);if(!e)return[];S.#t=!0;let i=new S(t,e);return S.#t=!1,i}constructor(t,e){if(!S.#t)throw TypeError("instantiate Stack using Stack.create(n)");this.heap=new e(t),this.length=0}push(t){this.heap[this.length++]=t}pop(){return this.heap[--this.length]}}class b{#e;#i;#s;#r;#n;ttl;ttlResolution;ttlAutopurge;updateAgeOnGet;updateAgeOnHas;allowStale;noDisposeOnSet;noUpdateTTL;maxEntrySize;sizeCalculation;noDeleteOnFetchRejection;noDeleteOnStaleGet;allowStaleOnFetchAbort;allowStaleOnFetchRejection;ignoreFetchAbort;#a;#l;#o;#h;#u;#c;#d;#p;#f;#g;#y;#m;#v;#S;#b;#A;#k;static unsafeExposeInternals(t){return{starts:t.#v,ttls:t.#S,sizes:t.#m,keyMap:t.#o,keyList:t.#h,valList:t.#u,next:t.#c,prev:t.#d,get head(){return t.#p},get tail(){return t.#f},free:t.#g,isBackgroundFetch:e=>t.#w(e),backgroundFetch:(e,i,s,r)=>t.#_(e,i,s,r),moveToTail:e=>t.#z(e),indexes:e=>t.#F(e),rindexes:e=>t.#O(e),isStale:e=>t.#E(e)}}get max(){return this.#e}get maxSize(){return this.#i}get calculatedSize(){return this.#l}get size(){return this.#a}get fetchMethod(){return this.#n}get dispose(){return this.#s}get disposeAfter(){return this.#r}constructor(t){let{max:e=0,ttl:i,ttlResolution:s=1,ttlAutopurge:r,updateAgeOnGet:n,updateAgeOnHas:a,allowStale:l,dispose:o,disposeAfter:h,noDisposeOnSet:c,noUpdateTTL:p,maxSize:f=0,maxEntrySize:v=0,sizeCalculation:A,fetchMethod:k,noDeleteOnFetchRejection:w,noDeleteOnStaleGet:_,allowStaleOnFetchRejection:z,allowStaleOnFetchAbort:F,ignoreFetchAbort:O}=t;if(0!==e&&!y(e))throw TypeError("max option must be a nonnegative integer");let E=e?m(e):Array;if(!E)throw Error("invalid max value: "+e);if(this.#e=e,this.#i=f,this.maxEntrySize=v||this.#i,this.sizeCalculation=A,this.sizeCalculation){if(!this.#i&&!this.maxEntrySize)throw TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if("function"!=typeof this.sizeCalculation)throw TypeError("sizeCalculation set to non-function")}if(void 0!==k&&"function"!=typeof k)throw TypeError("fetchMethod must be a function if specified");if(this.#n=k,this.#A=!!k,this.#o=new Map,this.#h=Array(e).fill(void 0),this.#u=Array(e).fill(void 0),this.#c=new E(e),this.#d=new E(e),this.#p=0,this.#f=0,this.#g=S.create(e),this.#a=0,this.#l=0,"function"==typeof o&&(this.#s=o),"function"==typeof h?(this.#r=h,this.#y=[]):(this.#r=void 0,this.#y=void 0),this.#b=!!this.#s,this.#k=!!this.#r,this.noDisposeOnSet=!!c,this.noUpdateTTL=!!p,this.noDeleteOnFetchRejection=!!w,this.allowStaleOnFetchRejection=!!z,this.allowStaleOnFetchAbort=!!F,this.ignoreFetchAbort=!!O,0!==this.maxEntrySize){if(0!==this.#i&&!y(this.#i))throw TypeError("maxSize must be a positive integer if specified");if(!y(this.maxEntrySize))throw TypeError("maxEntrySize must be a positive integer if specified");this.#j()}if(this.allowStale=!!l,this.noDeleteOnStaleGet=!!_,this.updateAgeOnGet=!!n,this.updateAgeOnHas=!!a,this.ttlResolution=y(s)||0===s?s:1,this.ttlAutopurge=!!r,this.ttl=i||0,this.ttl){if(!y(this.ttl))throw TypeError("ttl must be a positive integer if specified");this.#x()}if(0===this.#e&&0===this.ttl&&0===this.#i)throw TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!this.#e&&!this.#i){let t="LRU_CACHE_UNBOUNDED";g(t)&&(u.add(t),d("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",t,b))}}getRemainingTTL(t){return this.#o.has(t)?1/0:0}#x(){let t=new v(this.#e),e=new v(this.#e);this.#S=t,this.#v=e,this.#L=(i,s,r=h.now())=>{if(e[i]=0!==s?r:0,t[i]=s,0!==s&&this.ttlAutopurge){let t=setTimeout(()=>
2{this.#E(i)&&this.delete(this.#h[i])},s+1);t.unref&&t.unref()}},this.#T=i=>{e[i]=0!==t[i]?h.now():0},this.#M=(r,n)=>{if(t[n]){let a=t[n],l=e[n];if(!a||!l)return;r.ttl=a,r.start=l,r.now=i||s();let o=r.now-l;r.remainingTTL=a-o}};let i=0,s=()=>{let t=h.now();if(this.ttlResolution>0){i=t;let e=setTimeout(()=>i=0,this.ttlResolution);e.unref&&e.unref()}return t};this.getRemainingTTL=r=>{let n=this.#o.get(r);if(void 0===n)return 0;let a=t[n],l=e[n];return a&&l?a-((i||s())-l):1/0},this.#E=r=>{let n=e[r],a=t[r];return!!a&&!!n&&(i||s())-n>a}}#T=()=>{};#M=()=>{};#L=()=>{};#E=()=>!1;#j(){let t=new v(this.#e);this.#l=0,this.#m=t,this.#I=e=>{this.#l-=t[e],t[e]=0},this.#P=(t,e,i,s)=>{if(this.#w(e))return 0;if(!y(i)){if(s){if("function"!=typeof s)throw TypeError("sizeCalculation must be a function");if(!y(i=s(e,t)))throw TypeError("sizeCalculation return invalid (expect positive integer)")}else throw TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.")}return i},this.#C=(e,i,s)=>{if(t[e]=i,this.#i){let i=this.#i-t[e];for(;this.#l>i;)this.#D(!0)}this.#l+=t[e],s&&(s.entrySize=i,s.totalCalculatedSize=this.#l)}}#I=t=>{};#C=(t,e,i)=>{};#P=(t,e,i,s)=>{if(i||s)throw TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0};*#F({allowStale:t=this.allowStale}={}){if(this.#a)for(let e=this.#f;this.#R(e)&&((t||!this.#E(e))&&(yield e),e!==this.#p);)e=this.#d[e]}*#O({allowStale:t=this.allowStale}={}){if(this.#a)for(let e=this.#p;this.#R(e)&&((t||!this.#E(e))&&(yield e),e!==this.#f);)e=this.#c[e]}#R(t){return void 0!==t&&this.#o.get(this.#h[t])===t}*entries(){for(let t of this.#F())void 0===this.#u[t]||void 0===this.#h[t]||this.#w(this.#u[t])||(yield[this.#h[t],this.#u[t]])}*rentries(){for(let t of this.#O())void 0===this.#u[t]||void 0===this.#h[t]||this.#w(this.#u[t])||(yield[this.#h[t],this.#u[t]])}*keys(){for(let t of this.#F()){let e=this.#h[t];void 0===e||this.#w(this.#u[t])||(yield e)}}*rkeys(){for(let t of this.#O()){let e=this.#h[t];void 0===e||this.#w(this.#u[t])||(yield e)}}*values(){for(let t of this.#F())void 0===this.#u[t]||this.#w(this.#u[t])||(yield this.#u[t])}*rvalues(){for(let t of this.#O())void 0===this.#u[t]||this.#w(this.#u[t])||(yield this.#u[t])}[Symbol.iterator](){return this.entries()}[Symbol.toStringTag]="LRUCache";find(t,e={}){for(let i of this.#F()){let s=this.#u[i],r=this.#w(s)?s.__staleWhileFetching:s;if(void 0!==r&&t(r,this.#h[i],this))return this.get(this.#h[i],e)}}forEach(t,e=this){for(let i of this.#F()){let s=this.#u[i],r=this.#w(s)?s.__staleWhileFetching:s;void 0!==r&&t.call(e,r,this.#h[i],this)}}rforEach(t,e=this){for(let i of this.#O()){let s=this.#u[i],r=this.#w(s)?s.__staleWhileFetching:s;void 0!==r&&t.call(e,r,this.#h[i],this)}}purgeStale(){let t=!1;for(let e of this.#O({allowStale:!0}))this.#E(e)&&(this.delete(this.#h[e]),t=!0);return t}info(t){let e=this.#o.get(t);if(void 0===e)return;let i=this.#u[e],s=this.#w(i)?i.__staleWhileFetching:i;if(void 0===s)return;let r={value:s};if(this.#S&&this.#v){let t=this.#S[e],i=this.#v[e];if(t&&i){let e=t-(h.now()-i);r.ttl=e,r.start=Date.now()}}return this.#m&&(r.size=this.#m[e]),r}dump(){let t=[];for(let e of this.#F({allowStale:!0})){let i=this.#h[e],s=this.#u[e],r=this.#w(s)?s.__staleWhileFetching:s;if(void 0===r||void 0===i)continue;let n={value:r};if(this.#S&&this.#v){n.ttl=this.#S[e];let t=h.now()-this.#v[e];n.start=Math.floor(Date.now()-t)}this.#m&&(n.size=this.#m[e]),t.unshift([i,n])}return t}load(t){for(let[e,i]of(this.clear(),t)){if(i.start){let t=Date.now()-i.start;i.start=h.now()-t}this.set(e,i.value,i)}}set(t,e,i={}){if(void 0===e)return this.delete(t),this;let{ttl:s=this.ttl,start:r,noDisposeOnSet:n=this.noDisposeOnSet,sizeCalculation:a=this.sizeCalculation,status:l}=i,{noUpdateTTL:o=this.noUpdateTTL}=i,h=this.#P(t,e,i.size||0,a);if(this.maxEntrySize&&h>this.maxEntrySize)return l&&(l.set="miss",l.maxEntrySizeExceeded=!0),this.delete(t),this;let u=0===this.#a?void 0:this.#o.get(t);if(void 0===u)u=0===this.#a?this.#f:0!==this.#g.length?this.#g.pop():this.#a===this.#e?this.#D(!1):this.#a,this.#h[u]=t,this.#u[u]=e,this.#o.set(t,u),this.#c[this.#f]=u,this.#d[u]=this.#f,this.#f=u,this.#a++,this.#C(u,h,l),l&&(l.set="add"),o=!1;else{this.#z(u);let i=this.#u[u];if(e!==i){if(this.#A&&this.#w(i)){i.__abortController.abort(Error("replaced"));let{__staleWhileFetching:e}=i;void 0!==e&&!n&&(this.#b&&this.#s?.(e,t,"set"),this.#k&&this.#y?.push([e,t,"set"]))}else!n&&(this.#b&&this.#s?.(i,t,"set"),this.#k&&this.#y?.push([i,t,"set"]));if(this.#I(u),this.#C(u,h,l),this.#u[u]=e,l){l.set="replace";let t=i&&this.#w(i)?i.__staleWhileFetching:i;void 0!==t&&(l.oldValue=t)}}else l&&(l.set="update")}if(0===s||this.#S||this.#x(),this.#S&&(o||this.#L(u,s,r),l&&this.#M(l,u)),!n&&this.#k&&this.#y){let t;let e=this.#y;for(;t=e?.shift();)this.#r?.(...t)}return this}pop(){try{for(;this.#a;){let t=this.#u[this.#p];if(this.#D(!0),this.#w(t)){if(t.__staleWhileFetching)return t.__staleWhileFetching}else if(void 0!==t)return t}}finally{if(this.#k&&this.#y){let t;let e=this.#y;for(;t=e?.shift();)this.#r?.(...t)}}}#D(t){let e=this.#p,i=this.#h[e],s=this.#u[e];return this.#A&&this.#w(s)?s.__abortController.abort(Error("evicted")):(this.#b||this.#k)&&(this.#b&&this.#s?.(s,i,"evict"),this.#k&&this.#y?.push([s,i,"evict"])),this.#I(e),t&&(this.#h[e]=void 0,this.#u[e]=void 0,this.#g.push(e)),1===this.#a?(this.#p=this.#f=0,this.#g.length=0):this.#p=this.#c[e],this.#o.delete(i),this.#a--,e}has(t,e={}){let{updateAgeOnHas:i=this.updateAgeOnHas,status:s}=e,r=this.#o.get(t);if(void 0!==r){let t=this.#u[r];if(this.#w(t)&&void 0===t.__staleWhileFetching)return!1;if(!this.#E(r))return i&&this.#T(r),s&&(s.has="hit",this.#M(s,r)),!0;s&&(s.has="stale",this.#M(s,r))}else s&&(s.has="miss");return!1}peek(t,e={}){let{allowStale:i=this.allowStale}=e,s=this.#o.get(t);if(void 0===s||!i&&this.#E(s))return;let r=this.#u[s];return this.#w(r)?r.__staleWhileFetching:r}#_(t,e,i,s){let r=void 0===e?void 0:this.#u[e];if(this.#w(r))return r;let n=new p,{signal:a}=i;a?.addEventListener("abort",()=>n.abort(a.reason),{signal:n.signal});let l={signal:n.signal,options:i,context:s},o=(s,r=!1)=>{let{aborted:a}=n.signal,o=i.ignoreFetchAbort&&void 0!==s;return(i.status&&(a&&!r?(i.status.fetchAborted=!0,i.status.fetchError=n.signal.reason,o&&(i.status.fetchAbortIgnored=!0)):i.status.fetchResolved=!0),!a||o||r)?(this.#u[e]===u&&(void 0===s?u.__staleWhileFetching?this.#u[e]=u.__staleWhileFetching:this.delete(t):(i.status&&(i.status.fetchUpdated=!0),this.set(t,s,l.options))),s):h(n.signal.reason)},h=s=>{let{aborted:r}=n.signal,a=r&&i.allowStaleOnFetchAbort,l=a||i.allowStaleOnFetchRejection,o=l||i.noDeleteOnFetchRejection;if(this.#u[e]!==u||(o&&void 0!==u.__staleWhileFetching?a||(this.#u[e]=u.__staleWhileFetching):this.delete(t)),l)return i.status&&void 0!==u.__staleWhileFetching&&(i.status.returnedStale=!0),u.__staleWhileFetching;if(u.__returned===u)throw s};
2i.status&&(i.status.fetchDispatched=!0);let u=new Promise((e,s)=>{let a=this.#n?.(t,r,l);a&&a instanceof Promise&&a.then(t=>e(void 0===t?void 0:t),s),n.signal.addEventListener("abort",()=>{(!i.ignoreFetchAbort||i.allowStaleOnFetchAbort)&&(e(void 0),i.allowStaleOnFetchAbort&&(e=t=>o(t,!0)))})}).then(o,t=>(i.status&&(i.status.fetchRejected=!0,i.status.fetchError=t),h(t))),c=Object.assign(u,{__abortController:n,__staleWhileFetching:r,__returned:void 0});return void 0===e?(this.set(t,c,{...l.options,status:void 0}),e=this.#o.get(t)):this.#u[e]=c,c}#w(t){return!!this.#A&&!!t&&t instanceof Promise&&t.hasOwnProperty("__staleWhileFetching")&&t.__abortController instanceof p}async fetch(t,e={}){let{allowStale:i=this.allowStale,updateAgeOnGet:s=this.updateAgeOnGet,noDeleteOnStaleGet:r=this.noDeleteOnStaleGet,ttl:n=this.ttl,noDisposeOnSet:a=this.noDisposeOnSet,size:l=0,sizeCalculation:o=this.sizeCalculation,noUpdateTTL:h=this.noUpdateTTL,noDeleteOnFetchRejection:u=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:c=this.allowStaleOnFetchRejection,ignoreFetchAbort:d=this.ignoreFetchAbort,allowStaleOnFetchAbort:p=this.allowStaleOnFetchAbort,context:f,forceRefresh:g=!1,status:y,signal:m}=e;if(!this.#A)return y&&(y.fetch="get"),this.get(t,{allowStale:i,updateAgeOnGet:s,noDeleteOnStaleGet:r,status:y});let v={allowStale:i,updateAgeOnGet:s,noDeleteOnStaleGet:r,ttl:n,noDisposeOnSet:a,size:l,sizeCalculation:o,noUpdateTTL:h,noDeleteOnFetchRejection:u,allowStaleOnFetchRejection:c,allowStaleOnFetchAbort:p,ignoreFetchAbort:d,status:y,signal:m},S=this.#o.get(t);if(void 0===S){y&&(y.fetch="miss");let e=this.#_(t,S,v,f);return e.__returned=e}{let e=this.#u[S];if(this.#w(e)){let t=i&&void 0!==e.__staleWhileFetching;return y&&(y.fetch="inflight",t&&(y.returnedStale=!0)),t?e.__staleWhileFetching:e.__returned=e}let r=this.#E(S);if(!g&&!r)return y&&(y.fetch="hit"),this.#z(S),s&&this.#T(S),y&&this.#M(y,S),e;let n=this.#_(t,S,v,f),a=void 0!==n.__staleWhileFetching&&i;return y&&(y.fetch=r?"stale":"refresh",a&&r&&(y.returnedStale=!0)),a?n.__staleWhileFetching:n.__returned=n}}get(t,e={}){let{allowStale:i=this.allowStale,updateAgeOnGet:s=this.updateAgeOnGet,noDeleteOnStaleGet:r=this.noDeleteOnStaleGet,status:n}=e,a=this.#o.get(t);if(void 0!==a){let e=this.#u[a],l=this.#w(e);return(n&&this.#M(n,a),this.#E(a))?(n&&(n.get="stale"),l)?(n&&i&&void 0!==e.__staleWhileFetching&&(n.returnedStale=!0),i?e.__staleWhileFetching:void 0):(r||this.delete(t),n&&i&&(n.returnedStale=!0),i?e:void 0):(n&&(n.get="hit"),l)?e.__staleWhileFetching:(this.#z(a),s&&this.#T(a),e)}n&&(n.get="miss")}#$(t,e){this.#d[e]=t,this.#c[t]=e}#z(t){t!==this.#f&&(t===this.#p?this.#p=this.#c[t]:this.#$(this.#d[t],this.#c[t]),this.#$(this.#f,t),this.#f=t)}delete(t){let e=!1;if(0!==this.#a){let i=this.#o.get(t);if(void 0!==i){if(e=!0,1===this.#a)this.clear();else{this.#I(i);let e=this.#u[i];if(this.#w(e)?e.__abortController.abort(Error("deleted")):(this.#b||this.#k)&&(this.#b&&this.#s?.(e,t,"delete"),this.#k&&this.#y?.push([e,t,"delete"])),this.#o.delete(t),this.#h[i]=void 0,this.#u[i]=void 0,i===this.#f)this.#f=this.#d[i];else if(i===this.#p)this.#p=this.#c[i];else{let t=this.#d[i];this.#c[t]=this.#c[i];let e=this.#c[i];this.#d[e]=this.#d[i]}this.#a--,this.#g.push(i)}}}if(this.#k&&this.#y?.length){let t;let e=this.#y;for(;t=e?.shift();)this.#r?.(...t)}return e}clear(){for(let t of this.#O({allowStale:!0})){let e=this.#u[t];if(this.#w(e))e.__abortController.abort(Error("deleted"));else{let i=this.#h[t];this.#b&&this.#s?.(e,i,"delete"),this.#k&&this.#y?.push([e,i,"delete"])}}if(this.#o.clear(),this.#u.fill(void 0),this.#h.fill(void 0),this.#S&&this.#v&&(this.#S.fill(0),this.#v.fill(0)),this.#m&&this.#m.fill(0),this.#p=0,this.#f=0,this.#g.length=0,this.#l=0,this.#a=0,this.#k&&this.#y){let t;let e=this.#y;for(;t=e?.shift();)this.#r?.(...t)}}}var A=i(80096),k=i(2265),w=i(14446);let _=new b({max:500}),z=(0,k.memo)(function(t){let{children:e,refreshInterval:i=1e4,token:r}=t;if(!t.client)throw Error("Missing a `client` prop with a configured Sanity client instance");let[n]=(0,k.useState)(()=>{let{requestTagPrefix:e,resultSourceMap:i}=t.client.config();return t.client.withConfig({requestTagPrefix:e||"sanity.preview-kit",resultSourceMap:"withKeyArraySelector"!==i||"withKeyArraySelector",...r&&{token:r,useCdn:!1,perspective:"previewDrafts",ignoreBrowserTokenWarning:!0}})}),[a]=(0,k.useState)(()=>t.logger);(0,k.useEffect)(()=>{a&&a.log(`[@sanity/preview-kit]: With the current configuration you can expect that: Updates that can be traced using Content Source Maps will be applied in real-time. Other updates will be applied every ${i}ms.`)},[a,i]);let[l,o]=(0,k.useState)([]),[h]=(0,k.useState)(()=>new Map),u=function(t){let[e]=(0,k.useState)(()=>
2new Map),i=(0,k.useCallback)((i,s,r,n)=>{e.has(i)||(e.set(i,{query:s,params:r,listeners:new Set}),(0,k.startTransition)(()=>t(t=>t.includes(i)?t:[...t,i])));let a=e.get(i);if(!a||!a.listeners)throw TypeError("Inconsistent cache for key: "+i);let{listeners:l}=a;return l.add(n),()=>{l.delete(n),0===l.size&&(e.delete(i),(0,k.startTransition)(()=>t(t=>t.includes(i)?t.filter(t=>t!==i):t)))}},[e,t]);return(0,k.useMemo)(()=>({cache:e,subscribe:i}),[e,i])}(o),[c]=(0,k.useState)(()=>function(t,e,i){let s=T(e,i);return h.has(s)||h.set(s,{result:t,resultSourceMap:{}}),{subscribe:t=>{let r=u.subscribe(s,e,i,t);return()=>r()},getSnapshot:()=>{var t;return null==(t=h.get(s))?void 0:t.result}}}),[d,p]=(0,k.useState)([]),[f]=(0,k.useState)(()=>new Map),g=(0,k.useCallback)(t=>{var e;let i=new Set;if(f.clear(),null!=(e=t.documents)&&e.length)for(let e of t.documents)i.add(e._id),f.set(e._id,e);(0,k.startTransition)(()=>p(t=>{let e=Array.from(new Set([...t,...i]));return JSON.stringify(e.sort())===JSON.stringify(t.sort())?t:e}))},[f]);return(0,s.jsxs)(w.x.Provider,{value:c,children:[e,(0,s.jsx)(E,{cache:u.cache,client:n,setTurboIds:p,snapshots:h,turboIds:d,docsInUse:f}),l.map(t=>{if(!u.cache.has(t))return null;let{query:e,params:r,listeners:a}=u.cache.get(t);return(0,s.jsx)(F,{client:n,listeners:a,params:r,query:e,refreshInterval:i,snapshots:h,turboIdsFromSourceMap:g},t)})]})});z.displayName="LiveStoreProvider";let F=(0,k.memo)(function(t){let{client:e,refreshInterval:i,query:s,params:r,listeners:n,snapshots:l,turboIdsFromSourceMap:o}=t,{projectId:h,dataset:u}=(0,k.useMemo)(()=>{let{projectId:t,dataset:i}=e.config();return{projectId:t,dataset:i}},[e]),[c,d]=(0,k.useState)(null);if(c)throw c;let[p,f]=(0,a.o_)({refreshInterval:i}),g="refresh"===p||"inflight"===p;return(0,k.useEffect)(()=>{if(!g)return;let t=!1,i=new AbortController,a=f();return(async function(){let{signal:a}=i,{result:c,resultSourceMap:d}=await e.fetch(s,r,{signal:a,filterResponse:!1});if(!a.aborted){for(let t of(l.set(T(s,r),{result:L(h,u,c,d),resultSourceMap:null!=d?d:{}}),d&&o(d),n.values()))t();t=!0}})().catch(t=>{"AbortError"!==t.name&&d(t)}).finally(a),()=>{t||i.abort()}},[e,u,n,r,h,s,g,l,f,o]),null});function O(t,e,i){return`${t}-${e}-${i}`}F.displayName="QuerySubscription";let E=(0,k.memo)(function(t){let{client:e,snapshots:i,cache:r,turboIds:n,setTurboIds:l,docsInUse:o}=t,{projectId:h,dataset:u}=(0,k.useMemo)(()=>{let{projectId:t,dataset:i}=e.config();return{projectId:t,dataset:i}},[e]);(0,k.useEffect)(()=>{var t,e;let s=new Set;for(let{query:n,params:a}of(o.clear(),r.values())){let r=T(n,a),l=i.get(r);if(l&&null!=(e=null==(t=l.resultSourceMap)?void 0:t.documents)&&e.length)for(let t of l.resultSourceMap.documents)s.add(t._id),o.set(t._id,t)}let a=[...s].sort();JSON.stringify(n)!==JSON.stringify(a)&&(0,k.startTransition)(()=>l(a))},[r,l,i,n,o]),(0,a.T)(o,h,u);let[c,d]=(0,k.useState)([]);(0,k.useEffect)(()=>{let t=new Set(c.flat()),e=new Set;for(let i of n)t.has(i)||_.has(O(h,u,i))||e.add(i);let i=[...e].slice(0,100);0!==i.length&&(0,k.startTransition)(()=>d(t=>[...t.slice(-100),i]))},[c,u,h,n]);let[p,f]=(0,k.useState)();return(0,k.useEffect)(()=>{let t=e.listen("*",{},{events:["mutation"],effectFormat:"mendoza",includePreviousRevision:!1,includeResult:!1,tag:"turbo"}).subscribe(t=>{var e,i;if("mutation"!==t.type||null==(i=null==(e=t.effects)?void 0:e.apply)||!i.length)return;let s=O(h,u,t.documentId),r=_.peek(s);if(r){let e={...r};delete e._rev;let i=(0,A.a)(e,t.effects.apply);_.set(s,i)}(0,k.startTransition)(()=>f(t.documentId))});return()=>t.unsubscribe()},[e,u,h]),(0,k.useEffect)(()=>{var t,e,s;if(!p||!n.includes(p))return;let a=[];for(let[s,r]of i.entries())null!=(e=null==(t=r.resultSourceMap)?void 0:t.documents)&&e.length&&(r.result=L(h,u,r.result,r.resultSourceMap),a.push(s));for(let t of a){let e=null==(s=r.get(t))?void 0:s.listeners;if(e)for(let t of e)t()}(0,k.startTransition)(()=>f(void 0))},[r,u,p,h,i,n]),(0,s.jsx)(s.Fragment,{children:c.map(t=>(0,s.jsx)(j,{client:e,projectId:h,dataset:u,ids:t},JSON.stringify(t)))})});E.displayName="Turbo";let j=(0,k.memo)(function(t){let{client:e,projectId:i,dataset:s,ids:r}=t;return(0,k.useEffect)(()=>{let t=r.filter(t=>!_.has(O(i,s,t)));0!==t.length&&e.getDocuments(t).then(t=>{for(let e of t)e&&null!=e&&e._id&&_.set(O(i,s,e._id),e)},console.error)},[e,s,r,i]),null});j.displayName="GetDocuments";let x=!1;
2function L(t,e,i,s){return s?function(t,e,i,s=n,a="raw"){if(!e)return t;if("published"!==a&&"raw"!==a&&"previewDrafts"!==a)throw Error(`Unknown perspective "${a}"`);return(0,r.w)(JSON.parse(JSON.stringify(t)),(t,n)=>{let l=(0,r.r)(n,e);if(!l)return t;let{mapping:o,pathSuffix:h}=l;if("value"!==o.type||"documentValue"!==o.source.type)return t;let u=e.documents[o.source.document],c=e.paths[o.source.path];if(u){let e;let n=(0,r.p)(c+h),l=(0,r.t)(n);if("_id"===l||("previewDrafts"===a?((e=i(u._id.startsWith(r.D)?u:{...u,_id:`${r.D}${u._id}}`}))||(e=i(u._id.startsWith(r.D)?{...u,_id:(0,r.g)(u._id)}:u)),e&&(e={...e,_id:(0,r.g)(u._id),_originalId:u._id})):e=i(u),!e))return t;let o=e?(0,r.a)(e,l,t):t;return t===o?t:s(o,{cachedDocument:e,previousValue:t,sourceDocument:u,sourcePath:n})}return t})}(i,s,i=>{if(!i._projectId)return _.get(O(t,e,i._id));x||(console.warn("Cross dataset references are not supported yet, ignoring source document",i),x=!0)},(t,{previousValue:e})=>{if("string"==typeof t&&"string"==typeof e){let{encoded:i}=(0,l.uy)(e),{cleaned:s}=(0,l.uy)(t);return`${i}${s}`}return t},"previewDrafts"):i}function T(t,e){return`${t}-${JSON.stringify(e)}`}},80624:function(t,e,i){i.d(e,{R3:function(){return u},X6:function(){return h},uy:function(){return c}});var s={0:8203,1:8204,2:8205,3:8290,4:8291,5:8288,6:65279,7:8289,8:119155,9:119156,a:119157,b:119158,c:119159,d:119160,e:119161,f:119162},r={0:8203,1:8204,2:8205,3:65279},n=[,,,,].fill(String.fromCodePoint(r[0])).join(""),a=Object.fromEntries(Object.entries(r).map(t=>t.reverse())),l=Object.fromEntries(Object.entries(s).map(t=>t.reverse())),o=`${Object.values(s).map(t=>`\\u{${t.toString(16)}}`).join("")}`,h=RegExp(`[${o}]{4,}`,"gu");function u(t){let e=t.match(h);if(e)return function(t,e=!1){let i=Array.from(t);if(i.length%2==0){if(i.length%4||!t.startsWith(n))return function(t,e){var i;let s=[];for(let e=.5*t.length;e--;){let i=`${l[t[2*e].codePointAt(0)]}${l[t[2*e+1].codePointAt(0)]}`;s.unshift(String.fromCharCode(parseInt(i,16)))}let r=[],n=[s.join("")],a=10;for(;n.length;){let t=n.shift();try{if(r.push(JSON.parse(t)),e)break}catch(s){if(!a--)throw s;let e=+(null==(i=s.message.match(/\sposition\s(\d+)$/))?void 0:i[1]);if(!e)throw s;n.unshift(t.substring(0,e),t.substring(e))}}return r}(i,e)}else throw Error("Encoded data has invalid length");let s=[];for(let t=.25*i.length;t--;){let e=i.slice(4*t,4*t+4).map(t=>a[t.codePointAt(0)]).join("");s.unshift(String.fromCharCode(parseInt(e,4)))}if(e){s.shift();let t=s.indexOf("\0");return -1===t&&(t=s.length),[JSON.parse(s.slice(0,t).join(""))]}return s.join("").split("\0").filter(Boolean).map(t=>JSON.parse(t))}(e[0],!0)[0]}function c(t){var e;return{cleaned:t.replace(h,""),encoded:(null==(e=t.match(h))?void 0:e[0])||""}}},80096:function(t,e,i){i.d(e,{a:function(){return p},v:function(){return c}});let s=["Value","Copy","Blank","ReturnIntoArray","ReturnIntoObject","ReturnIntoObjectSameKey","PushField","PushElement","PushParent","Pop","PushFieldCopy","PushFieldBlank","PushElementCopy","PushElementBlank","ReturnIntoObjectPop","ReturnIntoObjectSameKeyPop","ReturnIntoArrayPop","ObjectSetFieldValue","ObjectCopyField","ObjectDeleteField","ArrayAppendValue","ArrayAppendSlice","StringAppendString","StringAppendSlice"];class r{constructor(t,e,i){this.model=t,this.root=e,this.patch=i,this.i=0,this.inputStack=[],this.outputStack=[]}read(){return this.patch[this.i++]}process(){for(this.inputStack.push({value:this.root}),this.outputStack.push({value:this.root});this.i<this.patch.length;){let t=this.read(),e=s[t];if(!e)throw Error(`Unknown opcode: ${t}`);this[`process${e}`].apply(this)}let t=this.outputStack.pop();return this.finalizeOutput(t)}inputEntry(){return this.inputStack[this.inputStack.length-1]}inputKey(t,e){return t.keys||(t.keys=this.model.objectGetKeys(t.value).sort()),t.keys[e]}outputEntry(){return this.outputStack[this.outputStack.length-1]}outputArray(){let t=this.outputEntry();return t.writeValue||(t.writeValue=this.model.copyArray(t.value)),t.writeValue}outputObject(){let t=this.outputEntry();return t.writeValue||(t.writeValue=this.model.copyObject(t.value)),t.writeValue}outputString(){let t=this.outputEntry();return t.writeValue||(t.writeValue=this.model.copyString(t.value)),t.writeValue}finalizeOutput(t){return t.writeValue?this.model.finalize(t.writeValue):t.value}processValue(){let t=this.model.wrap(this.read());this.outputStack.push({value:t})}processCopy(){let t=this.inputEntry();this.outputStack.push({value:t.value})}processBlank(){this.outputStack.push({value:null})}processReturnIntoArray(){let t=this.outputStack.pop(),e=this.finalizeOutput(t),i=this.outputArray();this.model.arrayAppendValue(i,e)}processReturnIntoObject(){let t=this.read(),e=this.outputStack.pop(),i=this.finalizeOutput(e);i=this.model.markChanged(i);let s=this.outputObject();this.model.objectSetField(s,t,i)}processReturnIntoObjectSameKey(){let t=this.inputEntry(),e=this.outputStack.pop(),i=this.finalizeOutput(e),s=this.outputObject();this.model.objectSetField(s,t.key,i)}processPushField(){let t=this.read(),e=this.inputEntry(),i=this.inputKey(e,t),s=this.model.objectGetField(e.value,i);this.inputStack.push({value:s,key:i})}processPushElement(){let t=this.read(),e=this.inputEntry(),i=this.model.arrayGetElement(e.value,t);this.inputStack.push({value:i})}processPop(){this.inputStack.pop()}processPushFieldCopy(){this.processPushField(),this.processCopy()}processPushFieldBlank(){this.processPushField(),this.processBlank()}processPushElementCopy(){this.processPushElement(),this.processCopy()}processPushElementBlank(){this.processPushElement(),this.processBlank()}processReturnIntoObjectPop(){this.processReturnIntoObject(),this.processPop()}processReturnIntoObjectSameKeyPop(){this.processReturnIntoObjectSameKey(),this.processPop()}processReturnIntoArrayPop(){this.processReturnIntoArray(),this.processPop()}processObjectSetFieldValue(){this.processValue(),this.processReturnIntoObject()}processObjectCopyField(){this.processPushField(),this.processCopy(),this.processReturnIntoObjectSameKey(),this.processPop()}processObjectDeleteField(){let t=this.read(),e=this.inputEntry(),i=this.inputKey(e,t),s=this.outputObject();this.model.objectDeleteField(s,i)}processArrayAppendValue(){let t=this.model.wrap(this.read()),e=this.outputArray();this.model.arrayAppendValue(e,t)}processArrayAppendSlice(){let t=this.read(),e=this.read(),i=this.outputArray(),s=this.inputEntry().value;this.model.arrayAppendSlice(i,s,t,e)}processStringAppendString(){let t=this.model.wrap(this.read()),e=this.outputString();this.model.stringAppendValue(e,t)}processStringAppendSlice(){let t=this.read(),e=this.read(),i=this.outputString(),s=this.inputEntry().value;this.model.stringAppendSlice(i,s,t,e)}}function n(t){return t>>16?4:t>>11?3:t>>7?2:1}function a(t){let e=0;for(let i=0;i<t.length;i++){let s=n(t.codePointAt(i));4==s&&i++,e+=s}return e}function l(t,e,i=0){let s=i,r=0;for(r=i;s<e;r++){let e=n(t.codePointAt(r));4===e&&r++,s+=e}return r}class o{constructor(t){this.meta=t}wrap(t){return this.wrapWithMeta(t,this.meta,this.meta)}wrapWithMeta(t,e,i=this.meta){return{data:t,startMeta:e,endMeta:i}}asObject(t){if(!t.content){let e={};for(let[i,s]of Object.entries(t.data))e[i]=this.wrapWithMeta(s,t.startMeta);t.content={type:"object",fields:e}}return t.content}asArray(t){if(!t.content){let e=t.data.map(e=>this.wrapWithMeta(e,t.startMeta)),i=e.map(()=>this.meta);t.content={type:"array",elements:e,metas:i}}return t.content}asString(t){if(!t.content){let e=t.data,i={value:e,utf8size:a(e),uses:[],startMeta:t.startMeta,endMeta:t.endMeta};t.content=this.stringFromParts([i])}return t.content}stringFromParts(t){let e={type:"string",parts:t};for(let i of t)i.uses.push(e);return e}objectGetKeys(t){return t.content?Object.keys(t.content.fields):Object.keys(t.data)}objectGetField(t,e){return this.asObject(t).fields[e]}arrayGetElement(t,e){return this.asArray(t).elements[e]}finalize(t){return this.updateEndMeta(t),{content:t,startMeta:this.meta,endMeta:this.meta}}markChanged(t){return this.wrap(h(t))}updateEndMeta(t){if("string"==t.type)for(let e of t.parts)e.endMeta=this.meta;else if("array"===t.type)for(let e of t.elements)e.content&&e.endMeta!==this.meta&&this.updateEndMeta(e.content),e.endMeta=this.meta;else for(let e of Object.values(t.fields))e.content&&e.endMeta!==this.meta&&this.updateEndMeta(e.content),e.endMeta=this.meta}copyString(t){if(!t)return{type:"string",parts:[]};{let e=this.asString(t);return this.stringFromParts(e.parts.slice())}}copyObject(t){let e={type:"object",fields:{}};if(t){let i=this.asObject(t);Object.assign(e.fields,i.fields)}return e}copyArray(t){let e=t?this.asArray(t):null;return{type:"array",elements:e?e.elements:[],metas:e?e.metas:[]}}
2objectSetField(t,e,i){t.fields[e]=i}objectDeleteField(t,e){delete t.fields[e]}arrayAppendValue(t,e){t.elements.push(e),t.metas.push(this.meta)}arrayAppendSlice(t,e,i,s){let r=this.asArray(e),n=r.elements.length===i;if(t.elements.push(...r.elements.slice(i,s)),n)t.metas.push(...r.metas.slice(i,s));else for(let e=i;e<s;e++)t.metas.push(this.meta)}stringAppendValue(t,e){for(let i of this.asString(e).parts)this.stringAppendPart(t,i)}stringAppendPart(t,e){t.parts.push(e),e.uses.push(t)}resolveStringPart(t,e,i){if(0===i)return e;for(let s=e;s<t.parts.length;s++){let e=t.parts[s];if(i===e.utf8size)return s+1;if(i<e.utf8size)return this.splitString(e,i),s+1;i-=e.utf8size}throw Error("splitting string out of bounds")}splitString(t,e){let i,s=e,r=t.utf8size-s;if(t.utf8size!==t.value.length){let i=0;for(e=0;i<s;e++){let s=n(t.value.codePointAt(e));4===s&&e++,i+=s}}i=t.value.slice(0,e);let a={value:t.value.slice(e),utf8size:r,uses:t.uses.slice(),startMeta:t.startMeta,endMeta:t.endMeta};for(let e of(t.value=i,t.utf8size=s,t.uses)){let i=e.parts.indexOf(t);if(-1===i)throw Error("bug: mismatch between string parts and use.");e.parts.splice(i+1,0,a)}}stringAppendSlice(t,e,i,s){let r=this.asString(e),n=this.resolveStringPart(r,0,i),a=this.resolveStringPart(r,n,s-i);for(let e=n;e<a;e++){let i=r.parts[e];this.stringAppendPart(t,i)}}}function h(t){if("u">typeof t.data)return t.data;let e,i=t.content;switch(i.type){case"string":e=i.parts.map(t=>t.value).join("");break;case"array":e=i.elements.map(t=>h(t));break;case"object":for(let[t,s]of(e={},Object.entries(i.fields)))e[t]=h(s)}return t.data=e,e}function u(t){return t.content?t.content.type:Array.isArray(t.data)?"array":null===t.data?"null":typeof t.data}var c=Object.freeze({__proto__:null,applyPatch:function(t,e,i){return new r(new o(i),t,e).process()},getType:u,rebaseValue:function t(e,i){let s=u(e);if(s!==u(i))return i;let r=new o(e.endMeta),l=new o(i.endMeta);switch(s){case"object":{let s=r.asObject(e),n=l.asObject(i),a=0,o=Object.keys(s.fields).length,h=Object.keys(n.fields).length;for(let[e,i]of Object.entries(n.fields)){let r=s.fields[e];r&&(n.fields[e]=t(r,i),n.fields[e]===r&&a++)}return o===h&&o===a?e:i}case"array":{let s=r.asArray(e),n=l.asArray(i);if(s.elements.length!==n.elements.length)break;let a=0;for(let e=0;e<n.elements.length;e++)n.elements[e]=t(s.elements[e],n.elements[e]),n.elements[e]!==s.elements[e]&&a++;return 0===a?e:i}case"null":case"boolean":case"number":if(h(e)===h(i))return e;break;case"string":{let t=h(e),s=h(i);if(t===s)return e;let r=l.copyString(null),o=function(t,e){let i=Math.min(t.length,e.length),s=0;for(let r=0;r<i;){let i=t.codePointAt(r);if(i!==e.codePointAt(r))break;let a=n(i);s+=a,r+=4===a?2:1}return s}(t,s),u=function(t,e,i=0){let s=Math.min(t.length,e.length)-i,r=0;for(let i=0;i<s;){let s=t.codePointAt(t.length-1-i);if(s!==e.codePointAt(e.length-1-i))break;let a=n(s);r+=a,i+=4===a?2:1}return r}(t,s,o),c=a(s),d=a(t);0<o&&l.stringAppendSlice(r,e,0,o),o<c-u&&l.stringAppendSlice(r,i,o,c-u),d-u<d&&l.stringAppendSlice(r,e,d-u,d);let p=l.finalize(r);if(h(p)!==s)throw Error("incorrect string rebase");return p}}return i},unwrap:h,wrap:function(t,e){return{data:t,startMeta:e,endMeta:e}}});class d{wrap(t){return t}finalize(t){return Array.isArray(t)?t:t.data}markChanged(t){return t}objectGetKeys(t){return Object.keys(t)}objectGetField(t,e){return t[e]}arrayGetElement(t,e){return t[e]}copyObject(t){let e={type:"object",data:{}};if(null!==t)for(let[i,s]of Object.entries(t))e.data[i]=s;return e}copyArray(t){return null===t?[]:t.slice()}copyString(t){return{type:"string",data:null===t?"":t}}objectSetField(t,e,i){t.data[e]=i}objectDeleteField(t,e){delete t.data[e]}arrayAppendValue(t,e){t.push(e)}arrayAppendSlice(t,e,i,s){t.push(...e.slice(i,s))}stringAppendSlice(t,e,i,s){let r=l(e,i),n=l(e,s,r);t.data+=e.slice(r,n)}stringAppendValue(t,e){t.data+=e}}function p(t,e){return new r(new d,t,e).process()}}}]);

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.