@buoy-gg/shared-ui 7.0.78 → 7.0.80
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commonjs/JsModal.js +1 -1
- package/lib/commonjs/bugCase/appInfo.js +1 -0
- package/lib/commonjs/bugCase/appInfo.web.js +1 -0
- package/lib/commonjs/bugCase/capture.js +1 -1
- package/lib/commonjs/bugCase/format.js +2 -2
- package/lib/commonjs/bugCase/index.js +1 -1
- package/lib/commonjs/bugCase/lock.js +1 -1
- package/lib/commonjs/bugCase/media.js +1 -0
- package/lib/commonjs/bugCase/recorder.js +1 -1
- package/lib/commonjs/bugCase/scrub.js +1 -1
- package/lib/commonjs/bugCase/steps.js +1 -1
- package/lib/commonjs/bugCase/teamKey.js +1 -0
- package/lib/commonjs/bugCase/validate.js +1 -0
- package/lib/commonjs/clipboard/autoDetectClipboard.js +1 -1
- package/lib/commonjs/clipboard/clipboard-impl.js +1 -1
- package/lib/commonjs/clipboard/clipboard-impl.web.js +1 -1
- package/lib/commonjs/clipboard/index.js +1 -1
- package/lib/commonjs/dataViewer/LiveExplorer.js +1 -1
- package/lib/commonjs/dataViewer/VirtualizedDataExplorer.js +1 -1
- package/lib/commonjs/dataViewer/flattenTree.js +1 -0
- package/lib/commonjs/dataViewer/liveEntries.js +1 -0
- package/lib/commonjs/icons/index.js +1 -1
- package/lib/commonjs/index.js +1 -1
- package/lib/commonjs/license/BuoyUpgradeSheet.js +1 -1
- package/lib/commonjs/license/index.js +1 -1
- package/lib/commonjs/sync/keyedArrays.js +1 -1
- package/lib/commonjs/sync/valuePath.js +1 -1
- package/lib/commonjs/ui/components/DynamicFilterView.js +1 -1
- package/lib/commonjs/ui/components/EntityFilterView.js +1 -1
- package/lib/commonjs/ui/components/WindowControls.js +1 -1
- package/lib/commonjs/ui/floating/FloatingTool.js +1 -1
- package/lib/commonjs/ui/listPresets.js +1 -1
- package/lib/commonjs/utils/fiberRootAnchor.js +1 -0
- package/lib/commonjs/utils/index.js +1 -1
- package/lib/commonjs/utils/loadOptionalModule.js +1 -1
- package/lib/commonjs/utils/loadToolModule.js +1 -1
- package/lib/commonjs/utils/minimalSuperJSON.js +1 -1
- package/lib/commonjs/utils/persistentStorage.js +1 -1
- package/lib/commonjs/utils/persistentStorage.web.js +1 -1
- package/lib/commonjs/utils/reloadPlatform.js +1 -1
- package/lib/commonjs/utils/snapshotProviderKit.js +1 -1
- package/lib/module/JsModal.js +1 -1
- package/lib/module/bugCase/appInfo.js +1 -0
- package/lib/module/bugCase/appInfo.web.js +1 -0
- package/lib/module/bugCase/capture.js +1 -1
- package/lib/module/bugCase/format.js +2 -2
- package/lib/module/bugCase/index.js +1 -1
- package/lib/module/bugCase/lock.js +1 -1
- package/lib/module/bugCase/media.js +1 -0
- package/lib/module/bugCase/recorder.js +1 -1
- package/lib/module/bugCase/scrub.js +1 -1
- package/lib/module/bugCase/steps.js +1 -1
- package/lib/module/bugCase/teamKey.js +1 -0
- package/lib/module/bugCase/validate.js +1 -0
- package/lib/module/clipboard/autoDetectClipboard.js +1 -1
- package/lib/module/clipboard/clipboard-impl.js +1 -1
- package/lib/module/clipboard/clipboard-impl.web.js +1 -1
- package/lib/module/clipboard/index.js +1 -1
- package/lib/module/dataViewer/LiveExplorer.js +1 -1
- package/lib/module/dataViewer/VirtualizedDataExplorer.js +1 -1
- package/lib/module/dataViewer/flattenTree.js +1 -0
- package/lib/module/dataViewer/liveEntries.js +1 -0
- package/lib/module/icons/index.js +1 -1
- package/lib/module/index.js +1 -1
- package/lib/module/license/BuoyUpgradeSheet.js +1 -1
- package/lib/module/license/index.js +1 -1
- package/lib/module/sync/keyedArrays.js +1 -1
- package/lib/module/sync/valuePath.js +1 -1
- package/lib/module/ui/components/DynamicFilterView.js +1 -1
- package/lib/module/ui/components/EntityFilterView.js +1 -1
- package/lib/module/ui/components/WindowControls.js +1 -1
- package/lib/module/ui/floating/FloatingTool.js +1 -1
- package/lib/module/ui/listPresets.js +1 -1
- package/lib/module/utils/fiberRootAnchor.js +1 -0
- package/lib/module/utils/index.js +1 -1
- package/lib/module/utils/loadOptionalModule.js +1 -1
- package/lib/module/utils/loadToolModule.js +1 -1
- package/lib/module/utils/minimalSuperJSON.js +1 -1
- package/lib/module/utils/persistentStorage.js +1 -1
- package/lib/module/utils/persistentStorage.web.js +1 -1
- package/lib/module/utils/reloadPlatform.js +1 -1
- package/lib/module/utils/snapshotProviderKit.js +1 -1
- package/lib/typescript/commonjs/JsModal.d.ts +3 -4
- package/lib/typescript/commonjs/JsModal.web.d.ts +2 -0
- package/lib/typescript/commonjs/bugCase/appInfo.d.ts +17 -0
- package/lib/typescript/commonjs/bugCase/appInfo.web.d.ts +14 -0
- package/lib/typescript/commonjs/bugCase/format.d.ts +2 -1
- package/lib/typescript/commonjs/bugCase/index.d.ts +7 -0
- package/lib/typescript/commonjs/bugCase/lock.d.ts +13 -0
- package/lib/typescript/commonjs/bugCase/media.d.ts +90 -0
- package/lib/typescript/commonjs/bugCase/recorder.d.ts +1 -0
- package/lib/typescript/commonjs/bugCase/scrub.d.ts +2 -2
- package/lib/typescript/commonjs/bugCase/steps.d.ts +10 -0
- package/lib/typescript/commonjs/bugCase/teamKey.d.ts +185 -0
- package/lib/typescript/commonjs/bugCase/types.d.ts +10 -0
- package/lib/typescript/commonjs/bugCase/validate.d.ts +14 -0
- package/lib/typescript/commonjs/clipboard/autoDetectClipboard.d.ts +1 -1
- package/lib/typescript/commonjs/clipboard/clipboard-impl.d.ts +6 -0
- package/lib/typescript/commonjs/clipboard/clipboard-impl.web.d.ts +2 -0
- package/lib/typescript/commonjs/clipboard/index.d.ts +1 -1
- package/lib/typescript/commonjs/dataViewer/flattenTree.d.ts +35 -0
- package/lib/typescript/commonjs/dataViewer/liveEntries.d.ts +19 -0
- package/lib/typescript/commonjs/hooks/safe-area-impl.d.ts +1 -1
- package/lib/typescript/commonjs/icons/index.d.ts +1 -0
- package/lib/typescript/commonjs/index.d.ts +3 -2
- package/lib/typescript/commonjs/license/BuoyUpgradeSheet.d.ts +8 -0
- package/lib/typescript/commonjs/license/index.d.ts +1 -1
- package/lib/typescript/commonjs/sync/keyedArrays.d.ts +6 -1
- package/lib/typescript/commonjs/ui/floating/FloatingTool.d.ts +6 -1
- package/lib/typescript/commonjs/ui/listPresets.d.ts +2 -2
- package/lib/typescript/commonjs/utils/fiberRootAnchor.d.ts +19 -0
- package/lib/typescript/commonjs/utils/index.d.ts +2 -1
- package/lib/typescript/commonjs/utils/minimalSuperJSON.d.ts +4 -2
- package/lib/typescript/commonjs/utils/persistentStorage.d.ts +19 -0
- package/lib/typescript/commonjs/utils/persistentStorage.web.d.ts +17 -0
- package/lib/typescript/module/JsModal.d.ts +3 -4
- package/lib/typescript/module/JsModal.web.d.ts +2 -0
- package/lib/typescript/module/bugCase/appInfo.d.ts +17 -0
- package/lib/typescript/module/bugCase/appInfo.web.d.ts +14 -0
- package/lib/typescript/module/bugCase/format.d.ts +2 -1
- package/lib/typescript/module/bugCase/index.d.ts +7 -0
- package/lib/typescript/module/bugCase/lock.d.ts +13 -0
- package/lib/typescript/module/bugCase/media.d.ts +90 -0
- package/lib/typescript/module/bugCase/recorder.d.ts +1 -0
- package/lib/typescript/module/bugCase/scrub.d.ts +2 -2
- package/lib/typescript/module/bugCase/steps.d.ts +10 -0
- package/lib/typescript/module/bugCase/teamKey.d.ts +185 -0
- package/lib/typescript/module/bugCase/types.d.ts +10 -0
- package/lib/typescript/module/bugCase/validate.d.ts +14 -0
- package/lib/typescript/module/clipboard/autoDetectClipboard.d.ts +1 -1
- package/lib/typescript/module/clipboard/clipboard-impl.d.ts +6 -0
- package/lib/typescript/module/clipboard/clipboard-impl.web.d.ts +2 -0
- package/lib/typescript/module/clipboard/index.d.ts +1 -1
- package/lib/typescript/module/dataViewer/flattenTree.d.ts +35 -0
- package/lib/typescript/module/dataViewer/liveEntries.d.ts +19 -0
- package/lib/typescript/module/hooks/safe-area-impl.d.ts +1 -1
- package/lib/typescript/module/icons/index.d.ts +1 -0
- package/lib/typescript/module/index.d.ts +3 -2
- package/lib/typescript/module/license/BuoyUpgradeSheet.d.ts +8 -0
- package/lib/typescript/module/license/index.d.ts +1 -1
- package/lib/typescript/module/sync/keyedArrays.d.ts +6 -1
- package/lib/typescript/module/ui/floating/FloatingTool.d.ts +6 -1
- package/lib/typescript/module/ui/listPresets.d.ts +2 -2
- package/lib/typescript/module/utils/fiberRootAnchor.d.ts +19 -0
- package/lib/typescript/module/utils/index.d.ts +2 -1
- package/lib/typescript/module/utils/minimalSuperJSON.d.ts +4 -2
- package/lib/typescript/module/utils/persistentStorage.d.ts +19 -0
- package/lib/typescript/module/utils/persistentStorage.web.d.ts +17 -0
- package/lib/web/chunks/chunk-36A4T5PL.mjs +1 -0
- package/lib/web/chunks/{chunk-XUYN4NOF.mjs → chunk-5UII72AQ.mjs} +1 -1
- package/lib/web/chunks/chunk-A3N3WVKC.mjs +1 -0
- package/lib/web/chunks/chunk-BPL65J3F.mjs +1 -0
- package/lib/web/chunks/chunk-EY7GXWGI.mjs +1 -1
- package/lib/web/chunks/chunk-IE2U5SN2.mjs +15 -0
- package/lib/web/chunks/chunk-IEAXJZCR.mjs +6 -0
- package/lib/web/chunks/chunk-OF3VWR6K.mjs +2 -2
- package/lib/web/chunks/{chunk-OVTASJUJ.mjs → chunk-SUG6TLF5.mjs} +1 -1
- package/lib/web/chunks/chunk-SXWOOYFL.mjs +1 -0
- package/lib/web/chunks/chunk-T44OT3CI.mjs +6 -0
- package/lib/web/chunks/{chunk-OQB3GW44.mjs → chunk-UVVRCZX5.mjs} +1 -1
- package/lib/web/chunks/chunk-Y7FM4WZ7.mjs +6 -0
- package/lib/web/chunks/persistentStorage.web-BFPYMY5C.mjs +1 -0
- package/lib/web/dataViewer.mjs +2 -2
- package/lib/web/history.mjs +1 -1
- package/lib/web/hooks.mjs +1 -1
- package/lib/web/index.mjs +12 -6
- package/lib/web/ui.mjs +1 -1
- package/lib/web/utils.mjs +1 -1
- package/package.json +5 -5
- package/scripts/detect-clipboard.js +18 -2
- package/lib/web/chunks/chunk-BMITMQVB.mjs +0 -6
- package/lib/web/chunks/chunk-DJD42EPL.mjs +0 -1
- package/lib/web/chunks/chunk-GN75GBYZ.mjs +0 -1
- package/lib/web/chunks/chunk-GTRVOJUH.mjs +0 -1
- package/lib/web/chunks/chunk-HE5ONCAL.mjs +0 -6
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{Nb as Te,Ob as Oe,Pb as Q,Q as Z,R as je,Tb as ke,Vb as ee,Yb as te,ud as h}from"./chunk-SUG6TLF5.mjs";import{d as a}from"./chunk-AHVO74UQ.mjs";import{a as F,b as d,c as g,d as k,f as re,z as ne}from"./chunk-QXVVA64P.mjs";import{a as n}from"./chunk-T6T3FEMU.mjs";var Ne="[Circular]",oe="[...]";function ae(e,t,r={}){let{depthLimit:s=Number.MAX_SAFE_INTEGER,edgesLimit:f=Number.MAX_SAFE_INTEGER}=r,u=[];function l(i,c,m,o,x,C){if(C+=1,typeof i=="object"&&i!==null){for(let I=0;I<o.length;I++)if(o[I]===i){p(Ne,i,c,x);return}if(C>s){p(oe,i,c,x);return}if(m+1>f){p(oe,i,c,x);return}if(o.push(i),Array.isArray(i)){let I=i;for(let R=0;R<i.length;R++)l(i[R],R,R,o,I,C)}else if(i instanceof Map||i instanceof Set||i instanceof RegExp||i instanceof Date||i instanceof Error){o.pop();return}else{let I=i,R=Object.keys(I);for(let B=0;B<R.length;B++){let q=R[B];l(I[q],q,B,o,I,C)}}o.pop()}}n(l,"decirc");function p(i,c,m,o){if(!o)return;let x=Object.getOwnPropertyDescriptor(o,m);if(x?.get!==void 0)if(x.configurable)Object.defineProperty(o,m,{value:i}),u.push([o,m,c,x]);else return;else o[m]=i,u.push([o,m,c])}n(p,"setReplace");let A=n((i,c)=>{if(typeof c=="bigint")return`${c.toString()}n`;if(typeof c=="symbol")return c.toString();if(typeof c>"u")return"undefined";if(typeof c=="function")return`[Function: ${c.name||"anonymous"}]`;if(typeof c=="number"){if(c===1/0)return"Infinity";if(c===-1/0)return"-Infinity";if(Number.isNaN(c))return"NaN"}if(c instanceof Error){let m={name:c.name,message:c.message,stack:c.stack};return Object.getOwnPropertyNames(c).forEach(o=>{if(!["name","message","stack"].includes(o))try{let x=c[o];x!==void 0&&(m[o]=x)}catch{}}),m}if(c instanceof Date)return c.toISOString();if(c instanceof RegExp)return c.toString();if(c instanceof Map)try{return{__type:"Map",entries:Array.from(c.entries()).map(([m,o])=>[String(m),o])}}catch{return{__type:"Map",entries:"[Map iteration failed]"}}if(c instanceof Set)try{return{__type:"Set",values:Array.from(c)}}catch{return{__type:"Set",values:"[Set iteration failed]"}}return c},"replacer");try{return l(e,"",0,[],null,0),JSON.stringify(e,A,t)}catch{return JSON.stringify("[unable to serialize, circular reference is too complex to analyze]")}finally{for(;u.length!==0;){let i=u.pop();if(i&&i.length===4){let[c,m,,o]=i;c&&typeof c=="object"&&o&&Object.defineProperty(c,m,o)}else if(i){let[c,m,o]=i;c&&typeof c=="object"&&(typeof m=="string"||typeof m=="number")&&(c[m]=o)}}}}n(ae,"safeStringify");var De=n(e=>typeof e>"u","isUndefined"),ie=n(e=>typeof e!="object"||e===null||e===Object.prototype?false:Object.getPrototypeOf(e)===null?true:Object.getPrototypeOf(e)===Object.prototype,"isPlainObject"),P=n(e=>Array.isArray(e),"isArray"),Ve=n(e=>typeof e=="boolean"||e===null||typeof e>"u"||typeof e=="number"||typeof e=="string"||typeof e=="symbol","isPrimitive"),Be=n(e=>e instanceof Date&&!isNaN(e.valueOf()),"isDate"),le=n(e=>e instanceof Error,"isError"),Le=n(e=>e instanceof RegExp,"isRegExp"),se=n(e=>e instanceof Set,"isSet"),ce=n(e=>e instanceof Map,"isMap"),ze=n(e=>typeof e=="bigint","isBigint"),ue=n(e=>typeof e=="number"&&isNaN(e),"isNaNValue"),Fe=n(e=>e===1/0||e===-1/0,"isInfinite"),Ee=n(e=>e===0&&1/e===-1/0,"isMinusZero"),We=n(e=>e instanceof URL,"isURL"),de=n(e=>ArrayBuffer.isView(e)&&!(e instanceof DataView),"isTypedArray");function T(e,t){if(!e)throw new Error(`This ${t} value has the wrong shape.`)}n(T,"wantType");var fe={Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array,Uint8ClampedArray},pe=[{isApplicable:De,annotation:"undefined",transform:n(()=>null,"transform"),untransform:n(()=>{},"untransform")},{isApplicable:ze,annotation:"bigint",transform:n(e=>e.toString(),"transform"),untransform:n(e=>(T(typeof e=="string"||typeof e=="number","bigint"),typeof BigInt<"u"?BigInt(e):(console.error("[Buoy]","BigInt is not supported in this environment"),e)),"untransform")},{isApplicable:Be,annotation:"Date",transform:n(e=>e.toISOString(),"transform"),untransform:n(e=>{T(typeof e=="string"||typeof e=="number","Date");let t=new Date(e);return T(!Number.isNaN(t.getTime()),"Date"),t},"untransform")},{isApplicable:le,annotation:"Error",transform:n(e=>({name:e.name,message:e.message,stack:e.stack,cause:"cause"in e?e.cause:void 0}),"transform"),untransform:n(e=>{T(!!e&&typeof e=="object"&&!Array.isArray(e),"Error");let t=new Error(typeof e.message=="string"?e.message:"");return typeof e.name=="string"&&(t.name=e.name),typeof e.stack=="string"&&(t.stack=e.stack),e.cause!==void 0&&(t.cause=e.cause),t},"untransform")},{isApplicable:Le,annotation:"regexp",transform:n(e=>""+e,"transform"),untransform:n(e=>{T(typeof e=="string","regexp");let t=e.slice(1,e.lastIndexOf("/")),r=e.slice(e.lastIndexOf("/")+1);return new RegExp(t,r)},"untransform")},{isApplicable:se,annotation:"set",transform:n(e=>[...e.values()],"transform"),untransform:n(e=>(T(Array.isArray(e),"set"),new Set(e)),"untransform")},{isApplicable:ce,annotation:"map",transform:n(e=>[...e.entries()],"transform"),untransform:n(e=>(T(Array.isArray(e)&&e.every(t=>Array.isArray(t)&&t.length===2),"map"),new Map(e)),"untransform")},{isApplicable:n(e=>ue(e)||Fe(e),"isApplicable"),annotation:"number",transform:n(e=>ue(e)?"NaN":e>0?"Infinity":"-Infinity","transform"),untransform:n(e=>(T(typeof e=="string","number"),Number(e)),"untransform")},{isApplicable:Ee,annotation:"number",transform:n(()=>"-0","transform"),untransform:n(()=>-0,"untransform")},{isApplicable:We,annotation:"URL",transform:n(e=>e.toString(),"transform"),untransform:n(e=>(T(typeof e=="string","URL"),new URL(e)),"untransform")},{isApplicable:de,annotation:n(e=>["typed-array",e.constructor.name],"annotation"),transform:n(e=>[...e],"transform"),untransform:n((e,t)=>{T(Array.isArray(e),"typed-array");let r=Array.isArray(t)?t[1]:"Uint8Array",s=typeof r=="string"&&Object.prototype.hasOwnProperty.call(fe,r)?fe[r]:void 0;if(!s)throw new Error(`Unknown typed array: ${r}`);return new s(e)},"untransform")}];function E(e){for(let t of pe)if(t.isApplicable(e)){let r=typeof t.annotation=="function"?t.annotation(e):t.annotation;return{value:t.transform(e),type:r}}}n(E,"transformValue");function M(e,t){for(let r of pe)if(typeof r.annotation=="function"?Array.isArray(t)&&t[0]==="typed-array"&&r.isApplicable===de:r.annotation===t)return r.untransform(e,t);throw new Error(`Unknown transformation: ${t}`)}n(M,"untransformValue");var ye=n(e=>ie(e)||P(e)||ce(e)||se(e)||le(e),"isDeep");function W(e){return e.replace(/\\/g,"\\\\").replace(/\./g,"\\.")}n(W,"escapeKey");function G(e,t=[],r=[]){let s=Ve(e);if(!s&&!ye(e)){let i=E(e);return i?{transformedValue:i.value,annotations:{[t.map(String).map(W).join(".")]:i.type}}:{transformedValue:e}}if(!s&&r.indexOf(e)!==-1)return{transformedValue:null};if(!ye(e)){let i=E(e);return i?{transformedValue:i.value,annotations:t.length>0?{[t.map(String).map(W).join(".")]:i.type}:{"":i.type}}:{transformedValue:e}}let f=E(e),u=f?.value??e,l=P(u)?[]:{},p={};if(f){let i=t.length>0?t.map(String).map(W).join("."):"";p[i]=f.type}let A=P(u)?u.map((i,c)=>[c,i]):Object.entries(u);for(let[i,c]of A){let m=String(i);if(m==="__proto__"||m==="constructor"||m==="prototype")throw new Error(`Detected property ${m}. This is a prototype pollution risk, please remove it from your object.`);let o=G(c,[...t,i],[...r,e]);l[i]=o.transformedValue,o.annotations&&Object.assign(p,o.annotations)}return{transformedValue:l,annotations:Object.keys(p).length>0?p:void 0}}n(G,"walker");function U(e){if(e==="")return[];let t=[],r="";for(let s=0;s<e.length;s++){let f=e.charAt(s);if(f==="\\"){let u=e.charAt(s+1);if(u==="\\"){r+="\\",s++;continue}else if(u==="."){r+=".",s++;continue}}if(f==="."){t.push(r),r="";continue}r+=f}return t.push(r),t}n(U,"parsePath");function L(e){if(Array.isArray(e))return e.map(L);if(ie(e)){let t={};for(let r of Object.keys(e))Object.defineProperty(t,r,{value:L(e[r]),enumerable:true,writable:true,configurable:true});return t}return e}n(L,"cloneJson");var ge=new Set(["__proto__","constructor","prototype"]);function $(e){return e.every(t=>typeof t=="number"||!ge.has(t))}n($,"isSafePath");function z(e,t){return e!==null&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,t)}n(z,"hasOwn");function me(e,t,r){if(t.length===0||!$(t))return false;let s=e;for(let u=0;u<t.length-1;u++){if(!z(s,t[u]))return false;s=s[t[u]]}let f=t[t.length-1];return z(s,f)?(s[f]=r,true):false}n(me,"setDeep");function H(e,t){let r=e;for(let s of t){if(!z(r,s)||typeof s=="string"&&ge.has(s))return;r=r[s]}return r}n(H,"getDeep");function J(e,t){if(!$(t))return false;let r=e;for(let s of t){if(!z(r,s))return false;r=r[s]}return true}n(J,"resolves");function Y(e){let t=G(e),r={json:t.transformedValue};return t.annotations&&(r.meta={values:t.annotations}),r}n(Y,"serialize");function K(e,t={}){let{json:r,meta:s}=e;if(!s?.values)return L(r);let f=L(r),u=Object.entries(s.values).map(([l,p])=>({pathString:l,type:p,path:U(l)})).sort((l,p)=>p.path.length-l.path.length);for(let{type:l,path:p}of u)try{if(p.length===0)f=M(f,l);else{if(!J(f,p))continue;let A=H(f,p),i=M(A,l);me(f,p,i)}}catch(A){if(!t.skipBadAnnotations)throw A}return f}n(K,"deserialize");function he(e,t){let r=e.meta?.values;if(!r)return e;let s={};for(let[f,u]of Object.entries(r)){let l;try{let p=U(f);if(p.length>0&&!J(e.json,p))continue;l=H(e.json,p)}catch{continue}t(l,u)||(s[f]=u)}return Object.keys(s).length?{json:e.json,meta:{values:s}}:{json:e.json}}n(he,"dropAnnotations");var _e=n((e,t=false)=>{let{json:r}=Y(e);return JSON.stringify(r,null,t?2:void 0)},"displayValue"),Pe=n(e=>{try{let t=JSON.parse(e);return K({json:t,meta:void 0})}catch{return JSON.parse(e)}},"parseDisplayValue");import{jsx as D,jsxs as _}from"react/jsx-runtime";function be({icon:e,iconColor:t,title:r,count:s,subtitle:f,expanded:u,onToggle:l,children:p,style:A,titleStyle:i}){return _(d,{style:[V.container,A],children:[_(re,{onPress:l,activeOpacity:.7,style:V.headerTouchable,children:[_(d,{style:V.header,children:[_(d,{style:V.headerLeft,children:[D(e,{size:14,color:t}),D(g,{style:[V.title,i],children:r}),D(d,{style:[V.badge,{backgroundColor:t+"20"}],children:D(g,{style:[V.badgeText,{color:t}],children:s})})]}),u?D(te,{size:14,color:a.muted}):D(ee,{size:14,color:a.muted})]}),D(g,{style:V.subtitle,children:f})]}),u&&D(k.View,{style:{opacity:1},children:p})]})}n(be,"GameUICollapsibleSection");var V=F.create({container:{marginBottom:20},headerTouchable:{marginBottom:12},header:{flexDirection:"row",alignItems:"center",justifyContent:"space-between",marginBottom:4,paddingHorizontal:4},headerLeft:{flexDirection:"row",alignItems:"center",gap:8,flex:1},title:{fontSize:11,color:a.primary,fontFamily:h,fontWeight:"700",letterSpacing:2,opacity:.9},subtitle:{fontSize:9,color:a.secondary,fontFamily:h,paddingHorizontal:4,marginTop:2,opacity:.7},badge:{paddingHorizontal:8,paddingVertical:2,borderRadius:10},badgeText:{fontSize:10,fontFamily:h,fontWeight:"700"}});var Se={position:"absolute",top:0,left:0,right:0,bottom:0};import{jsx as N,jsxs as X}from"react/jsx-runtime";function we({alertConfig:e,badgeText:t,animatedStyle:r,style:s,indicatorCount:f=3}){let u=e.icon;return X(k.View,{style:[O.container,{borderColor:e.color+"40"},s,r],children:[N(d,{style:[O.glow,{backgroundColor:e.color+"10"}]}),X(d,{style:O.content,children:[N(d,{style:[O.iconWrapper,{backgroundColor:e.color+"15"}],children:N(u,{size:20,color:e.color})}),X(d,{style:O.textContainer,children:[N(g,{style:[O.label,{color:e.color}],children:e.label}),N(g,{style:O.subtitle,children:e.subtitle})]}),N(d,{style:[O.badge,{backgroundColor:e.color+"20"}],children:N(g,{style:[O.badgeText,{color:e.color}],children:t})})]}),N(d,{style:O.indicators,children:[...Array(f)].map((l,p)=>N(d,{style:[O.indicatorDot,{backgroundColor:e.color,opacity:e.pulse?p===0?1:.5-p*.2:.3-p*.1}]},p))})]})}n(we,"GameUIStatusHeader");var O=F.create({container:{backgroundColor:a.panel,borderRadius:12,borderWidth:1,padding:16,marginBottom:16,position:"relative",overflow:"hidden"},glow:{...Se,opacity:.5},content:{flexDirection:"row",alignItems:"center",gap:12},iconWrapper:{width:36,height:36,borderRadius:8,justifyContent:"center",alignItems:"center"},textContainer:{flex:1,gap:2},label:{fontSize:13,fontWeight:"700",fontFamily:h,letterSpacing:1.5,textShadowOffset:{width:0,height:0},textShadowRadius:8},subtitle:{fontSize:10,color:a.secondary,fontFamily:h},badge:{paddingHorizontal:8,paddingVertical:4,borderRadius:4},badgeText:{fontSize:9,fontWeight:"700",fontFamily:h,letterSpacing:1},indicators:{position:"absolute",top:8,right:8,flexDirection:"row",gap:3},indicatorDot:{width:4,height:4,borderRadius:2}});import{Fragment as Me}from"react";import{jsx as S,jsxs as v}from"react/jsx-runtime";function xe({statsConfig:e,totalCount:t,header:r,bottomStats:s,style:f,hideInactive:u=true}){return v(d,{style:[y.container,f],children:[r&&v(d,{style:y.header,children:[v(d,{style:y.headerLeft,children:[S(g,{style:y.headerTitle,children:r.title}),S(g,{style:y.headerSubtitle,children:r.subtitle})]}),r.healthPercentage!==void 0&&S(d,{style:y.headerRight,children:v(d,{style:y.statusIndicator,children:[S(d,{style:[y.statusDot,{backgroundColor:r.healthColor||a.success}]}),S(g,{style:[y.statusText,{color:r.healthColor||a.success}],children:r.healthStatus||"OPTIMAL"})]})})]}),r?.healthPercentage!==void 0&&v(d,{style:y.healthSection,children:[S(g,{style:y.healthLabel,children:"SYSTEM HEALTH"}),S(d,{style:y.healthBarWrapper,children:S(d,{style:y.healthBarBg,children:S(k.View,{style:[y.healthBarFill,{width:`${r.healthPercentage}%`,backgroundColor:r.healthColor||a.success}]})})}),v(g,{style:[y.healthPercentage,{color:r.healthColor||a.success}],children:[r.healthPercentage,"%"]})]}),S(d,{style:y.statsGrid,children:e.map(l=>{let p=l.value>0;if(u&&!p)return null;let A=l.icon,i=t?l.value/t*100:0;return v(k.View,{style:[y.statCard,{borderColor:l.color+"30"}],children:[v(d,{style:y.cardContent,children:[S(d,{style:[y.iconBadge,{backgroundColor:l.color+"1A",borderColor:l.color+"33"}],children:S(A,{size:12,color:l.color})}),v(d,{style:y.cardInfo,children:[S(g,{style:y.cardLabel,children:l.label}),S(g,{style:y.cardSubtitle,children:l.subtitle})]}),v(d,{style:y.valueBlock,children:[S(g,{style:[y.statNumber,{color:l.color}],children:l.value.toString().padStart(2,"0")}),t?v(g,{style:y.percentText,children:[Math.round(i),"%"]}):null]})]}),l.showBar!==false&&t&&S(d,{style:[y.statBar,{backgroundColor:l.color+"10"}],children:S(d,{style:[y.statBarFill,{width:`${i}%`,backgroundColor:l.color}]})})]},l.key)})}),s&&s.length>0&&S(d,{style:y.bottomBar,children:s.map((l,p)=>v(Me,{children:[v(d,{style:y.bottomStat,children:[S(g,{style:y.bottomStatLabel,children:l.label}),S(g,{style:[y.bottomStatValue,l.color&&{color:l.color}],children:l.value})]}),p<s.length-1&&S(d,{style:y.bottomDivider})]},l.label))})]})}n(xe,"GameUICompactStats");var y=F.create({container:{backgroundColor:a.panel,borderRadius:12,padding:12,marginBottom:12,borderWidth:1,borderColor:a.border+"40",overflow:"hidden",position:"relative"},header:{flexDirection:"row",justifyContent:"space-between",alignItems:"center",marginBottom:8,paddingBottom:8,borderBottomWidth:1,borderBottomColor:"rgba(128, 128, 128, 0.1)"},headerLeft:{gap:1},headerRight:{alignItems:"flex-end"},headerTitle:{fontSize:11,fontWeight:"700",color:a.primary,fontFamily:h,letterSpacing:1.5},headerSubtitle:{fontSize:8,color:a.secondary,fontFamily:h,opacity:.7},statusIndicator:{flexDirection:"row",alignItems:"center",gap:4},statusDot:{width:5,height:5,borderRadius:2.5},statusText:{fontSize:9,fontWeight:"600",fontFamily:h,letterSpacing:.5},healthSection:{flexDirection:"row",alignItems:"center",marginBottom:10,gap:8},healthLabel:{fontSize:8,color:a.secondary,fontFamily:h,letterSpacing:.5},healthBarWrapper:{flex:1},healthBarBg:{height:4,backgroundColor:"rgba(128, 128, 128, 0.1)",borderRadius:2,overflow:"hidden"},healthBarFill:{height:"100%",borderRadius:2},healthPercentage:{fontSize:11,fontWeight:"700",fontFamily:h},statsGrid:{gap:6,marginBottom:8},statCard:{backgroundColor:a.blackTint2,borderRadius:8,borderWidth:1,borderColor:a.border,padding:10,marginBottom:4},cardContent:{flexDirection:"row",alignItems:"center",gap:8,marginBottom:4},cardInfo:{flex:1},cardLabel:{fontSize:11,fontWeight:"700",fontFamily:h,letterSpacing:.5,color:a.primary},cardSubtitle:{fontSize:8,color:a.secondary,fontFamily:h,opacity:.7},statNumber:{fontSize:16,fontWeight:"700",fontFamily:h,minWidth:28},valueBlock:{alignItems:"flex-end"},percentText:{fontSize:9,color:a.secondary,fontFamily:h},statBar:{height:3,borderRadius:1.5,overflow:"hidden"},statBarFill:{height:"100%",borderRadius:1.5},bottomBar:{flexDirection:"row",alignItems:"center",paddingTop:8,borderTopWidth:1,borderTopColor:a.border+"40"},bottomStat:{flex:1,alignItems:"center"},bottomStatLabel:{fontSize:7,color:a.muted,fontFamily:h,letterSpacing:.5,marginBottom:1},bottomStatValue:{fontSize:11,fontWeight:"700",color:a.primary,fontFamily:h},bottomDivider:{width:1,height:16,backgroundColor:a.border+"40"},iconBadge:{width:24,height:24,borderRadius:6,borderWidth:1,alignItems:"center",justifyContent:"center"}});import{useState as Ge,useCallback as Ue}from"react";import{jsx as w,jsxs as j}from"react/jsx-runtime";function Ae({issues:e,onIssueClick:t,hintText:r="Tap any issue to view details",style:s,expandable:f=true,statusLabels:u={missing:"Not found",wrong_type:"Type error",wrong_value:"Invalid value"}}){let[l,p]=Ge(new Set),A=Ue(o=>{f&&p(x=>{let C=new Set(x);return C.has(o)?C.delete(o):C.add(o),C})},[f]),i=n(o=>o==="missing"?a.warning:a.info,"getStatusColor"),c=n(o=>o==="missing"?Z:Q,"getStatusIcon"),m=n(o=>{switch(o.status){case"missing":return`\u2022 ${u.missing}`;case"wrong_type":return`\u2022 ${u.wrong_type}${o.expectedType?`: Expected ${o.expectedType}`:""}`;case"wrong_value":return`\u2022 ${u.wrong_value}${o.value?`: ${String(o.value).substring(0,20)}`:""}`;default:return""}},"getStatusLabel");return e.length===0?null:j(d,{style:[b.container,s],children:[e.map((o,x)=>{let C=i(o.status),I=c(o.status),R=l.has(o.key),B=R?te:ee;return j(d,{children:[j(re,{onPress:()=>{f&&A(o.key),t?.(o)},style:b.issueRow,activeOpacity:.7,children:[w(I,{size:14,color:C}),j(d,{style:b.issueContent,children:[w(g,{style:[b.issueKey,{color:a.primary}],children:o.key}),w(g,{style:b.issueDesc,children:m(o)})]}),f&&w(B,{size:12,color:a.muted})]}),f&&R&&j(k.View,{style:b.issueDetails,children:[j(d,{style:b.detailRow,children:[w(g,{style:b.detailLabel,children:"Status:"}),j(g,{style:[b.detailValue,{color:a.primary,fontWeight:"600"}],children:[o.status==="missing"&&"MISSING",o.status==="wrong_type"&&"TYPE ERROR",o.status==="wrong_value"&&"INVALID VALUE"]})]}),o.value!==void 0&&o.status!=="missing"&&j(d,{style:b.detailRow,children:[w(g,{style:b.detailLabel,children:"Current:"}),w(g,{style:[b.detailValue,{color:a.warning}],children:`"${String(o.value)}"`})]}),o.expectedType&&o.status==="wrong_type"&&j(d,{style:b.detailRow,children:[w(g,{style:b.detailLabel,children:"Expected:"}),w(g,{style:[b.detailValue,{color:a.success}],children:o.expectedType})]}),o.expectedValue&&o.status==="wrong_value"&&j(d,{style:b.detailRow,children:[w(g,{style:b.detailLabel,children:"Expected:"}),w(g,{style:[b.detailValue,{color:a.success}],children:`"${o.expectedValue}"`})]}),o.description&&w(d,{style:b.descSection,children:w(g,{style:b.descText,children:o.description})}),o.fixSuggestion&&j(d,{style:b.fixSection,children:[w(g,{style:b.fixLabel,children:"HOW TO FIX"}),w(g,{style:b.fixText,children:o.fixSuggestion})]})]})]},`${o.key}-${x}`)}),r&&w(g,{style:b.hint,children:r})]})}n(Ae,"GameUIIssuesList");var b=F.create({container:{backgroundColor:a.panel,borderRadius:8,padding:8,borderWidth:1,borderColor:a.warning+"33"},issueRow:{flexDirection:"row",alignItems:"center",paddingVertical:8,paddingHorizontal:8,borderRadius:6,marginBottom:4},issueContent:{flex:1,marginLeft:8,flexDirection:"row",alignItems:"center",gap:8},issueKey:{fontSize:11,fontWeight:"600",fontFamily:h},issueDesc:{fontSize:10,color:a.secondary,fontFamily:h,flex:1},hint:{fontSize:9,color:a.muted,fontFamily:h,textAlign:"center",marginTop:8,paddingTop:8,borderTopWidth:1,borderTopColor:a.primary+"0D"},issueDetails:{marginTop:8,marginLeft:22,marginRight:8,paddingLeft:12,paddingRight:8,paddingTop:8,paddingBottom:8,backgroundColor:a.background+"4D",borderLeftWidth:2,borderLeftColor:a.primary+"1A",borderRadius:4},detailRow:{flexDirection:"row",marginTop:8,alignItems:"flex-start"},detailLabel:{fontSize:10,color:a.secondary,fontFamily:h,fontWeight:"600",width:70},detailValue:{fontSize:11,color:a.primary,fontFamily:h,flex:1,lineHeight:16},fixSection:{marginTop:12,padding:10,backgroundColor:a.info+"14",borderRadius:6,borderWidth:1,borderColor:a.info+"33"},fixLabel:{fontSize:10,color:a.info,fontFamily:h,fontWeight:"700",marginBottom:6,letterSpacing:.5},fixText:{fontSize:11,color:a.primary,fontFamily:h,lineHeight:18,backgroundColor:a.background+"66",padding:8,borderRadius:4,overflow:"hidden"},descSection:{marginTop:10,paddingTop:10,borderTopWidth:1,borderTopColor:a.primary+"0D"},descText:{fontSize:10,color:a.secondary,fontFamily:h,marginTop:4,lineHeight:14}});import{useMemo as ve,useEffect as $e,useRef as Ce}from"react";var Ie={OPTIMAL:{icon:ke,color:a.success,label:"CONFIG OK",subtitle:"All requirements met",pulse:false},WARNING:{icon:Q,color:a.warning,label:"CONFIG WARNING",subtitle:"Check values and types",pulse:false},ERROR:{icon:Oe,color:a.error,label:"CONFIG ERROR",subtitle:"Missing required data",pulse:false},CRITICAL:{icon:Z,color:a.critical,label:"CONFIG FAILURE",subtitle:"Multiple critical issues",pulse:false},LOADING:{icon:Te,color:a.info,label:"LOADING",subtitle:"Reading configuration...",pulse:true},EMPTY:{icon:je,color:a.muted,label:"NO DATA",subtitle:"No configuration found",pulse:false}};function Re(e,t){let r=ve(()=>({...Ie,...t}),[t]),s=ve(()=>e.totalCount===0?"EMPTY":e.missingCount>2||e.wrongTypeCount>2?"CRITICAL":e.missingCount>0?"ERROR":e.wrongValueCount>0||e.wrongTypeCount>0?"WARNING":"OPTIMAL",[e]),f=r[s],u=Ce(new k.Value(1)).current,l=Ce(new k.Value(1)).current;return $e(()=>{u.setValue(0),l.setValue(.95),k.parallel([k.timing(u,{toValue:1,duration:300,useNativeDriver:true}),k.timing(l,{toValue:1,duration:300,easing:ne.out(ne.ease),useNativeDriver:true})]).start()},[s,u,l]),{alertState:s,alertConfig:f,alertAnimatedStyle:{transform:[{scale:l}],opacity:u},alertOpacity:u,alertScale:l}}n(Re,"useGameUIAlertState");export{ae as a,Y as b,K as c,he as d,_e as e,Pe as f,be as g,Se as h,we as i,xe as j,Ae as k,Ie as l,Re as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{a as t}from"./chunk-GF5C5DVX.mjs";import{Vb as B,Xb as H,
|
|
1
|
+
"use client";import{a as t}from"./chunk-GF5C5DVX.mjs";import{Vb as B,Xb as H,ud as y}from"./chunk-SUG6TLF5.mjs";import{a as A,b as o,c as n,f as j}from"./chunk-QXVVA64P.mjs";import{a as k}from"./chunk-T6T3FEMU.mjs";import{jsx as r,jsxs as i}from"react/jsx-runtime";function x({statusDotColor:s,statusLabel:w,statusSublabel:p,primaryText:C,secondaryText:l,secondaryAccessory:b,expandedContent:f,isExpanded:a,badgeText:d,badgeColor:T,customBadge:g,showChevron:D,bottomRightText:c,isSelected:I,onPress:h,disabled:R,expandedGlowColor:m,testID:S,statusTestID:v,statusSublabelTestID:W,primaryTestID:L,secondaryTestID:z,accessibilityLabel:O,trailingAction:u}){return r(o,{style:[e.rowWrapper,a&&e.rowWrapperExpanded],children:i(o,{style:[e.row,I&&e.selectedRow,a&&[e.expandedRowActive,{borderColor:m||t.color.accent,borderBottomColor:m||t.color.accent,shadowColor:m||t.color.accent}]],children:[i(o,{style:e.headerRow,children:[r(j,{style:e.headerPress,onPress:h,activeOpacity:.8,disabled:R||!h,testID:S,accessibilityLabel:O,accessibilityRole:h?"button":void 0,children:i(o,{style:e.rowContent,children:[i(o,{style:e.statusSection,children:[r(o,{style:[e.statusDot,{backgroundColor:s}]}),i(o,{style:e.statusInfo,children:[r(n,{style:[e.statusLabel,{color:s}],numberOfLines:1,testID:v,children:w}),p?r(n,{style:e.observerText,numberOfLines:1,testID:W,children:p}):null]})]}),i(o,{style:e.querySection,children:[r(n,{style:e.queryHash,numberOfLines:a?void 0:2,testID:L,children:C}),!a&&(l||b)?i(o,{style:e.secondaryRow,children:[l?r(n,{style:e.secondaryText,numberOfLines:1,testID:z,children:l}):null,b]}):null]}),i(o,{style:e.rightSection,children:[(g||d!==void 0||!a&&c)&&i(o,{style:e.badgeContainer,children:[g||(d!==void 0?r(n,{style:[e.statusBadge,{color:T||s}],numberOfLines:1,ellipsizeMode:"tail",children:d}):null),!a&&c?r(n,{style:e.bottomRightText,numberOfLines:1,children:c}):null]}),D&&r(o,{style:e.chevronContainer,children:a?r(B,{size:14,color:t.color.textTertiary}):r(H,{size:14,color:t.color.textTertiary})})]})]})}),u?r(o,{style:e.trailingAction,children:u}):null]}),a&&f&&r(o,{style:e.expandedContent,children:f})]})})}k(x,"CompactRow");var e=A.create({rowWrapper:{position:"relative",marginHorizontal:8,marginVertical:3},rowWrapperExpanded:{marginVertical:12},row:{backgroundColor:"rgba(12, 12, 12, 0.9)",borderRadius:8,borderWidth:1,borderColor:t.color.border,borderBottomWidth:1,borderBottomColor:t.color.separator,padding:12,paddingHorizontal:12,transform:[{scale:1}]},selectedRow:{backgroundColor:t.color.accentSoft,borderColor:t.color.accentBorderStrong,transform:[{scale:1.01}],shadowColor:t.color.accent,shadowOffset:{width:0,height:0},shadowOpacity:.1,shadowRadius:8,elevation:2},expandedRowActive:{transform:[{scale:1.02}],borderWidth:2,paddingBottom:16,shadowOffset:{width:0,height:0},shadowOpacity:.8,shadowRadius:20,elevation:10},headerRow:{flexDirection:"row",alignItems:"center"},headerPress:{flex:1,minWidth:0},trailingAction:{marginLeft:8,justifyContent:"center"},rowContent:{flexDirection:"row",alignItems:"center",justifyContent:"space-between"},statusSection:{flexDirection:"row",alignItems:"center",gap:8,width:90,minWidth:90},statusDot:{width:8,height:8,borderRadius:4},statusInfo:{flex:1,maxWidth:70},statusLabel:{fontSize:11,fontWeight:"600",lineHeight:14},observerText:{fontSize:10,color:t.color.textTertiary,marginTop:1},querySection:{flex:2,minWidth:0,paddingHorizontal:12},queryHash:{fontFamily:y,fontSize:12,color:t.color.text,lineHeight:16},secondaryRow:{flexDirection:"row",alignItems:"center",gap:6,marginTop:1},secondaryText:{fontSize:10,color:t.color.textTertiary,marginTop:1,flexShrink:1},rightSection:{flexDirection:"row",alignItems:"center",gap:8},badgeContainer:{flexDirection:"column",alignItems:"flex-end",gap:2},statusBadge:{maxWidth:96,fontSize:12,fontWeight:"600",fontVariant:["tabular-nums"]},chevronContainer:{padding:2},expandedContent:{marginTop:8,paddingTop:8,borderTopWidth:1,borderTopColor:t.color.separator,marginLeft:24},bottomRightText:{fontSize:9,color:t.color.textTertiary,fontFamily:y}});export{x as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{d as p}from"./chunk-AHVO74UQ.mjs";import{a as n,b as Ae}from"./chunk-T6T3FEMU.mjs";var Ne=n(e=>{if(e===null)return"null";if(e===void 0)return"undefined";if(Array.isArray(e))return"array";let t=typeof e;return t==="object"?e instanceof Date?"date":e instanceof RegExp?"regexp":e instanceof Map?"map":e instanceof Set?"set":e instanceof Error?"error":"object":t},"getValueType"),Le=n(e=>{let t=typeof e;return e==null||t==="string"||t==="number"||t==="boolean"||t==="bigint"||t==="symbol"},"isPrimitive"),_e=n(e=>{try{return JSON.stringify(e),true}catch{return false}},"isJsonSerializable"),Be=n(e=>{try{return JSON.parse(e),true}catch{return false}},"isValidJson"),Ve=n(e=>{if(e===null)return"null";if(e===void 0)return"undefined";try{return e.constructor?.name||typeof e}catch{return typeof e}},"getConstructorName"),Fe=n(e=>e==null?true:typeof e=="string"||Array.isArray(e)?e.length===0:typeof e=="object"?Object.keys(e).length===0:false,"isEmpty"),Ue=n(e=>{if(Array.isArray(e)){let t=e.length;return t===0?"empty array":t===1?"1 item":`${t} items`}if(e&&typeof e=="object"){let t=Object.keys(e).length;return t===0?"empty object":t===1?"1 key":`${t} keys`}if(typeof e=="string"){let t=e.length;return t===0?"empty string":t===1?"1 character":`${t} characters`}return""},"getValueSize"),We=n(e=>typeof e=="object"&&e!==null&&!Array.isArray(e)&&e.constructor===Object,"isPlainObject");var Ie=n(e=>{if(e==null)return e;if(typeof e=="string")try{return JSON.parse(e)}catch{return e}return e},"parseValue"),qe=n(e=>e===null?"null":e===void 0?"undefined":typeof e=="string"?`"${e}"`:typeof e=="boolean"?e?"true":"false":typeof e=="number"?String(e):typeof e=="function"?`[Function: ${e.name||"anonymous"}]`:typeof e=="object"?Array.isArray(e)?`[Array: ${e.length} items]`:`{Object: ${Object.keys(e).length} keys}`:String(e),"formatValue"),ze=n(e=>{if(e===null)return p.dataTypes.null;if(e===void 0)return p.dataTypes.undefined;switch(typeof e){case"string":return p.dataTypes.string;case"number":return p.dataTypes.number;case"boolean":return p.dataTypes.boolean;case"function":return p.dataTypes.function;case"object":return Array.isArray(e)?p.dataTypes.array:p.dataTypes.object;default:return p.primary}},"getTypeColor"),Je=n((e,t)=>e.length<=t?e:e.slice(0,t-3)+"...","truncateText"),A=n((e,t="")=>{let r={};return e==null?r:typeof e!="object"?(r[t||"root"]=e,r):(Array.isArray(e)?e.forEach((a,o)=>{let i=t?`${t}[${o}]`:`[${o}]`;typeof a=="object"&&a!==null?Object.assign(r,A(a,i)):r[i]=a}):Object.keys(e).forEach(a=>{let o=t?`${t}.${a}`:a,i=e[a];typeof i=="object"&&i!==null?Object.assign(r,A(i,o)):r[o]=i}),r)},"flattenObject"),Ge=n(e=>e.length===0?"root":e.map((t,r)=>typeof t=="number"?`[${t}]`:r===0?t:`.${t}`).join(""),"formatPath");var He={log:n(()=>{},"log"),warn:n(()=>{},"warn"),error:n((...e)=>{console.error("[Buoy]","[optional-module]",...e)},"error")},g=new Map,T=new Map,K=new Set;async function X(e,t={}){if(g.has(e))return g.get(e);let r={...He,...t.logger??{}};T.has(e)||T.set(e,(async()=>{try{let o=await Z(e,t),i=o?.default??o;return g.set(e,i),r.log("Loaded optional module",e),i}catch(o){return r.log("Optional module unavailable",e,o),g.set(e,null),null}})());let a=await T.get(e);return T.delete(e),!a&&t.warnOnceKey&&!K.has(t.warnOnceKey)&&(K.add(t.warnOnceKey),r.warn(t.warningMessage??`Module '${e}' not found.`)),a}n(X,"loadOptionalModule");var x,O;function Y(){if(x===void 0)try{x=new Function("moduleName","return import(moduleName);")}catch{x=null}return x}n(Y,"getDynamicImportLoader");function Q(){if(O===void 0)try{O=new Function("return typeof require === 'function' ? require : undefined;")()??null}catch{O=null}return O}n(Q,"getDynamicRequire");async function Z(e,t){if(t.loader)return await Promise.resolve(t.loader());let r=Y();if(r)return r(e);let a=Q();if(a)return a(e);throw new Error(`No dynamic loader available for optional module '${e}'.`)}n(Z,"loadModuleWithFallback");function ee(e){return g.has(e)?g.get(e):null}n(ee,"getCachedOptionalModule");var te="__buoyRenderCaptureProvider";function N(){return globalThis}n(N,"providerHost");function re(e){N()[te]=e}n(re,"setRenderCaptureProvider");function ne(){return N()[te]??null}n(ne,"getRenderCaptureProvider");var v=new Map,L=new Set;function _(){L.forEach(e=>{try{e()}catch{}})}n(_,"notify");function ae(e){return v.set(e.id,e),_(),()=>{v.get(e.id)===e&&(v.delete(e.id),_())}}n(ae,"registerStateSnapshotProvider");function oe(){return Array.from(v.values())}n(oe,"getStateSnapshotProviders");function ie(e){return v.get(e)??null}n(ie,"getStateSnapshotProvider");function se(e){return L.add(e),()=>{L.delete(e)}}n(se,"subscribeToStateSnapshotProviders");function R(){return null}n(R,"loadDevSettings");function C(){return null}n(C,"loadExpoUpdates");function j(){return typeof window>"u"?null:()=>window.location.reload()}n(j,"loadBrowserReload");function $(e="auto"){return e==="browser"?j()?"browser":null:e==="auto"&&j()?"browser":e==="dev-settings"?R()?"dev-settings":null:e==="expo-updates"?C()?"expo-updates":null:Ae&&R()?"dev-settings":C()?"expo-updates":null}n($,"resolveReloadStrategy");function B(e){return e==="browser"?"[buoy] Browser reload requires a browser window.":e==="dev-settings"?"[buoy] DevSettings.reload() unavailable \u2014 strategy 'dev-settings' requires React Native dev mode.":e==="expo-updates"?"[buoy] expo-updates not installed \u2014 strategy 'expo-updates' requires the host app to add the dependency.":"[buoy] No reload mechanism available. Run in __DEV__ or install expo-updates."}n(B,"unavailableMessage");async function V(e="auto",t="buoy reload"){let r=$(e);if(!r)throw new Error(B(e));return r==="browser"?j()():r==="dev-settings"?R().reload(t):await C().reloadAsync(),await new Promise(()=>{})}n(V,"reloadApp");var ue=250;function le(e){let t=e?.strategy??"auto",r=$(t);if(!r)throw new Error(B(t));let a=Math.max(0,e?.delayMs??ue),o=e?.reason??"buoy remote reload";return setTimeout(()=>{V(r,o).catch(()=>{})},a),{strategy:r,delayMs:a}}n(le,"scheduleReloadApp");function ce(){return null}n(ce,"getDevServerOrigin");function de(){let e=globalThis.__buoyRealNow;return typeof e=="function"?e():Date.now()}n(de,"realNow");var pe=class nt{constructor(){this.listeners=new Set;this.subscribe=this.subscribe.bind(this)}subscribe(t){return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}getListenerCount(){return this.listeners.size}notify(...t){this.listeners.forEach(r=>{r(...t)})}onSubscribe(){}onUnsubscribe(){}};n(pe,"Subscribable");var Ke=pe;var fe=class at{constructor(){this.listeners=new Set}subscribe(t){return this.listeners.add(t),()=>{this.listeners.delete(t)}}notify(t){this.listeners.forEach(r=>{try{r(t)}catch{}})}};n(fe,"SubscriberCountNotifier");var Xe=fe,F=new Xe,Ye=n(e=>F.subscribe(e),"subscribeToSubscriberCountChanges"),Qe=n(e=>F.notify(e),"notifySubscriberCountChange");import{useSyncExternalStore as he}from"react";var c,S=new Set,U,ye;function be(e){return c=e,()=>{c===e&&(c=void 0)}}n(be,"registerBrowserRouter");function h(){return typeof location>"u"?"/":location.href}n(h,"getBrowserHref");function W(e=h()){let t=new URL(e,"http://localhost"),r=t.hash.startsWith("#/")?new URL(t.hash.slice(1),t.origin):t;return r.pathname||(r.pathname="/"),r}n(W,"getBrowserRouteURL");var w;function I(e){if(!S.size&&typeof window<"u"){let t=window.history,r=n(o=>{for(let i of[...S])try{i({href:h(),kind:o})}catch{}},"emit");if(w)w.active=true;else{let o=t.pushState,i=t.replaceState,s={push:o,replace:i,active:true},f=n(function(...m){let b=Reflect.apply(o,this,m);return s.active&&r("push"),b},"wrappedPush"),l=n(function(...m){let b=Reflect.apply(i,this,m);return s.active&&r("replace"),b},"wrappedReplace");t.pushState=f,t.replaceState=l,w=s,ye=n(()=>{t.pushState!==f||t.replaceState!==l||(t.pushState=o,t.replaceState=i,w=void 0)},"unwrap")}let a=n(()=>r("pop"),"pop");window.addEventListener("popstate",a),window.addEventListener("hashchange",a),U=n(()=>{w&&(w.active=false),ye?.(),window.removeEventListener("popstate",a),window.removeEventListener("hashchange",a),U=void 0},"detach")}return S.add(e),()=>{S.delete(e),S.size||U?.()}}n(I,"subscribeBrowserNavigation");function q(e){let t=typeof e=="string"?e:e.pathname,r=new URL(t,h());if(r.origin!==window.location.origin)throw new Error("Tool navigation must stay on the current origin.");if(typeof e!="string")for(let[a,o]of Object.entries(e.params??{}))r.searchParams.set(a,String(o));return`${r.pathname}${r.search}${r.hash}`}n(q,"pathFor");var E={push(e){let t=q(e);if(c)return c.push(t);window.history.pushState(null,"",window.location.hash.startsWith("#/")?`#${t}`:t),window.dispatchEvent(new PopStateEvent("popstate",{state:window.history.state}))},replace(e){let t=q(e);if(c)return c.replace(t);window.history.replaceState(window.history.state,"",window.location.hash.startsWith("#/")?`#${t}`:t),window.dispatchEvent(new PopStateEvent("popstate",{state:window.history.state}))},back(){c?c.back():window.history.back()},canGoBack(){return c?.canGoBack?.()??(typeof window<"u"&&window.history.length>1)},navigate(e){E.push(e)},setParams(e){E.replace({pathname:h(),params:e})},dismiss(e=1){window.history.go(-e)},dismissAll(){throw new Error("Use the captured browser history to select a destination.")}};var ge=n(e=>I(e),"subscribe"),M=W;function we(){return E}n(we,"useSafeRouter");function z(){return he(ge,h,()=>"/"),M().pathname}n(z,"useSafePathname");function me(){return z().split("/").filter(Boolean)}n(me,"useSafeSegments");function ve(){return he(ge,h,()=>"/"),Object.fromEntries(M().searchParams)}n(ve,"useSafeGlobalSearchParams");function Se(){return typeof window>"u"?null:E}n(Se,"getSafeRouter");function Ee(){return M().pathname}n(Ee,"getSafeCurrentPathname");function Te(){let e=M();return{pathname:e.pathname,href:`${e.pathname}${e.search}${e.hash}`,segments:e.pathname.split("/").filter(Boolean)}}n(Te,"getSafeCurrentRoute");function xe(){return false}n(xe,"isExpoRouterAvailable");var Oe=new WeakMap,Ze=1;function y(e){return!!e&&typeof e=="object"&&e.nodeType===1&&typeof e.getBoundingClientRect=="function"}n(y,"isDOMElement");function P(e){if(!y(e))return null;let t=Oe.get(e);return t===void 0&&(t=Ze++,Oe.set(e,t)),t}n(P,"getDOMNodeHandle");function Re(e){if(!y(e))return null;let t=Object.keys(e).find(r=>r.startsWith("__reactFiber$"));return t?e[t]:null}n(Re,"getDOMFiber");function Ce(e,t){if(!y(e)||!t)return t;let r=e,a=e.tagName.toLowerCase(),o=a==="input"&&(r.type==="checkbox"||r.type==="radio"),i=a==="input"&&r.type==="range",s=a==="textarea"||a==="select"||a==="input"&&!o&&!i&&!["button","submit","reset","file","hidden"].includes(r.type),f=e.getAttribute("contenteditable"),l=!s&&!o&&!i&&(e.isContentEditable===true||f!==null&&f!=="false"),m=n(d=>{let u=e;u.focus();let D=u.ownerDocument.getSelection?.();if(D){let H=u.ownerDocument.createRange();H.selectNodeContents(u),D.removeAllRanges(),D.addRange(H)}let k=false;try{k=typeof u.ownerDocument.execCommand=="function"&&u.ownerDocument.execCommand("insertText",false,d)}catch{k=false}k||(u.textContent=d,u.dispatchEvent(new InputEvent("input",{bubbles:true,inputType:"insertText",data:d})))},"setEditable"),b=n(d=>{if(o){r.checked!==!!d&&r.click();return}let u=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(r),"value")?.set;u?u.call(r,String(d)):r.value=String(d),r.dispatchEvent(new Event("input",{bubbles:true})),r.dispatchEvent(new Event("change",{bubbles:true}))},"setValue");return{...t,__buoyDevToolsRoot:t.__buoyDevToolsRoot||t["data-buoy-root"]!==void 0,testID:t.testID??t["data-testid"],nativeID:t.nativeID??t.id,accessibilityLabel:t.accessibilityLabel??t["aria-label"],accessibilityRole:t.accessibilityRole??t.role??(a==="button"?"button":a==="a"?"link":o?r.type:s||l?"textbox":i?"slider":void 0),onPress:t.onPress??(typeof t.onClick=="function"||a==="button"||a==="a"?()=>r.click():void 0),...o||i?{onValueChange:b,value:o?r.checked:Number(r.value),...i?{minimumValue:Number(r.min||0),maximumValue:Number(r.max||100)}:{}}:{},...s?{onChangeText:b,value:r.value}:{},...l?{onChangeText:n(d=>m(String(d)),"onChangeText"),value:e.innerText??e.textContent??""}:{}}}n(Ce,"getDOMControlProps");function je(e){return y(e)?{__nativeTag:P(e),measure(t){let r=e.getBoundingClientRect();t(r.x,r.y,r.width,r.height,r.x,r.y)},measureInWindow(t){let r=e.getBoundingClientRect();t(r.x,r.y,r.width,r.height)},requestTVFocus(){e.focus()},focus(){e.focus()}}:null}n(je,"getDOMPublicInstance");var et={topFocus:"focus",topBlur:"blur",topTouchStart:"pointerdown",topTouchMove:"pointermove",topTouchEnd:"pointerup",topTouchCancel:"pointercancel",topChange:"input",topValueChange:"input",topSlidingComplete:"change"};function $e(){return typeof document>"u"?{emitter:null,reason:"DOM events are unavailable during server rendering."}:{reason:null,emitter:{addListener(e,t){let r=et[e];if(!r)throw new Error(`Unsupported DOM event: ${e}`);let a=n(o=>{let i=o.composedPath()[0]??o.target;if(!y(i))return;let s=i,f=o,l={target:P(i),pageX:f.clientX,pageY:f.clientY};(r==="input"||r==="change")&&(s.type==="checkbox"||s.type==="radio"?l.value=s.checked:s.type==="range"?l.value=Number(s.value):l.text=s.value??i.textContent??""),t({eventName:e,nativeEvent:l})},"callback");return document.addEventListener(r,a,true),{remove:n(()=>document.removeEventListener(r,a,true),"remove")}}}}}n($e,"resolveDOMEventEmitter");var J=new Map,Me=0;function Pe(e){for(let[t,r]of Object.entries(e)){let a=t.startsWith("@buoy-gg/")?t.replace(/\/web$/,""):`@buoy-gg/${t}`;J.get(a)!==r&&(J.set(a,r),Me++)}}n(Pe,"registerToolModules");function G(e){return J.get(e)??null}n(G,"getRegisteredToolModule");function De(){return Me}n(De,"getToolModuleVersion");function ke(e){let t=G(e);if(!t)throw new Error(`Register ${e} with createWebTools before opening tools that use it.`);return t}n(ke,"loadToolModule");export{Ke as a,F as b,Ye as c,Qe as d,de as e,Ne as f,Le as g,_e as h,Be as i,Ve as j,Fe as k,Ue as l,We as m,Ie as n,qe as o,ze as p,Je as q,A as r,Ge as s,X as t,ee as u,re as v,ne as w,ae as x,oe as y,ie as z,se as A,$ as B,V as C,ue as D,le as E,ce as F,be as G,h as H,W as I,I as J,E as K,we as L,z as M,me as N,ve as O,Se as P,Ee as Q,Te as R,xe as S,y as T,P as U,Re as V,Ce as W,je as X,$e as Y,Pe as Z,G as _,De as $,ke as aa};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use client";import{d as p}from"./chunk-AHVO74UQ.mjs";import{a as n,b as Be}from"./chunk-T6T3FEMU.mjs";var Ve=n(e=>{if(e===null)return"null";if(e===void 0)return"undefined";if(Array.isArray(e))return"array";let t=typeof e;return t==="object"?e instanceof Date?"date":e instanceof RegExp?"regexp":e instanceof Map?"map":e instanceof Set?"set":e instanceof Error?"error":"object":t},"getValueType"),Fe=n(e=>{let t=typeof e;return e==null||t==="string"||t==="number"||t==="boolean"||t==="bigint"||t==="symbol"},"isPrimitive"),Ue=n(e=>{try{return JSON.stringify(e),true}catch{return false}},"isJsonSerializable"),We=n(e=>{try{return JSON.parse(e),true}catch{return false}},"isValidJson"),Ie=n(e=>{if(e===null)return"null";if(e===void 0)return"undefined";try{return e.constructor?.name||typeof e}catch{return typeof e}},"getConstructorName"),qe=n(e=>e==null?true:typeof e=="string"||Array.isArray(e)?e.length===0:typeof e=="object"?Object.keys(e).length===0:false,"isEmpty"),ze=n(e=>{if(Array.isArray(e)){let t=e.length;return t===0?"empty array":t===1?"1 item":`${t} items`}if(e&&typeof e=="object"){let t=Object.keys(e).length;return t===0?"empty object":t===1?"1 key":`${t} keys`}if(typeof e=="string"){let t=e.length;return t===0?"empty string":t===1?"1 character":`${t} characters`}return""},"getValueSize"),Je=n(e=>typeof e=="object"&&e!==null&&!Array.isArray(e)&&e.constructor===Object,"isPlainObject");var Ge=n(e=>{if(e==null)return e;if(typeof e=="string")try{return JSON.parse(e)}catch{return e}return e},"parseValue"),He=n(e=>e===null?"null":e===void 0?"undefined":typeof e=="string"?`"${e}"`:typeof e=="boolean"?e?"true":"false":typeof e=="number"?String(e):typeof e=="function"?`[Function: ${e.name||"anonymous"}]`:typeof e=="object"?Array.isArray(e)?`[Array: ${e.length} items]`:`{Object: ${Object.keys(e).length} keys}`:String(e),"formatValue"),Ke=n(e=>{if(e===null)return p.dataTypes.null;if(e===void 0)return p.dataTypes.undefined;switch(typeof e){case"string":return p.dataTypes.string;case"number":return p.dataTypes.number;case"boolean":return p.dataTypes.boolean;case"function":return p.dataTypes.function;case"object":return Array.isArray(e)?p.dataTypes.array:p.dataTypes.object;default:return p.primary}},"getTypeColor"),Xe=n((e,t)=>e.length<=t?e:e.slice(0,t-3)+"...","truncateText"),N=n((e,t="")=>{let r={};return e==null?r:typeof e!="object"?(r[t||"root"]=e,r):(Array.isArray(e)?e.forEach((a,o)=>{let i=t?`${t}[${o}]`:`[${o}]`;typeof a=="object"&&a!==null?Object.assign(r,N(a,i)):r[i]=a}):Object.keys(e).forEach(a=>{let o=t?`${t}.${a}`:a,i=e[a];typeof i=="object"&&i!==null?Object.assign(r,N(i,o)):r[o]=i}),r)},"flattenObject"),Ye=n(e=>e.length===0?"root":e.map((t,r)=>typeof t=="number"?`[${t}]`:r===0?t:`.${t}`).join(""),"formatPath");var Qe={log:n(()=>{},"log"),warn:n(()=>{},"warn"),error:n((...e)=>{console.error("[Buoy]","[optional-module]",...e)},"error")},g=new Map,R=new Map,X=new Set;async function Y(e,t={}){if(g.has(e))return g.get(e);let r={...Qe,...t.logger??{}};R.has(e)||R.set(e,(async()=>{try{let o=await ee(e,t),i=o?.default??o;return g.set(e,i),r.log("Loaded optional module",e),i}catch(o){return r.log("Optional module unavailable",e,o),g.set(e,null),null}})());let a=await R.get(e);return R.delete(e),!a&&t.warnOnceKey&&!X.has(t.warnOnceKey)&&(X.add(t.warnOnceKey),r.warn(t.warningMessage??`Module '${e}' not found.`)),a}n(Y,"loadOptionalModule");var T,x;function Q(){if(T===void 0)try{T=new Function("moduleName","return import(moduleName);")}catch{T=null}return T}n(Q,"getDynamicImportLoader");function Z(){if(x===void 0)try{x=new Function("return typeof require === 'function' ? require : undefined;")()??null}catch{x=null}return x}n(Z,"getDynamicRequire");async function ee(e,t){if(t.loader)return await Promise.resolve(t.loader());let r=Q();if(r)return r(e);let a=Z();if(a)return a(e);throw new Error(`No dynamic loader available for optional module '${e}'.`)}n(ee,"loadModuleWithFallback");function te(e){return g.has(e)?g.get(e):null}n(te,"getCachedOptionalModule");var re="__buoyRenderCaptureProvider";function _(){return globalThis}n(_,"providerHost");function ne(e){_()[re]=e}n(ne,"setRenderCaptureProvider");function ae(){return _()[re]??null}n(ae,"getRenderCaptureProvider");var v=new Map,L=new Set;function B(){L.forEach(e=>{try{e()}catch{}})}n(B,"notify");function oe(e){return v.set(e.id,e),B(),()=>{v.get(e.id)===e&&(v.delete(e.id),B())}}n(oe,"registerStateSnapshotProvider");function ie(){return Array.from(v.values())}n(ie,"getStateSnapshotProviders");function se(e){return v.get(e)??null}n(se,"getStateSnapshotProvider");function ue(e){return L.add(e),()=>{L.delete(e)}}n(ue,"subscribeToStateSnapshotProviders");function C(){return null}n(C,"loadDevSettings");function O(){return null}n(O,"loadExpoUpdates");function j(){return typeof window>"u"?null:()=>window.location.reload()}n(j,"loadBrowserReload");function $(e="auto"){return e==="browser"?j()?"browser":null:e==="auto"&&j()?"browser":e==="dev-settings"?C()?"dev-settings":null:e==="expo-updates"?O()?"expo-updates":null:Be&&C()?"dev-settings":O()?"expo-updates":null}n($,"resolveReloadStrategy");function V(e){return e==="browser"?"[buoy] Browser reload requires a browser window.":e==="dev-settings"?"[buoy] DevSettings.reload() unavailable \u2014 strategy 'dev-settings' requires React Native dev mode.":e==="expo-updates"?"[buoy] expo-updates not installed \u2014 strategy 'expo-updates' requires the host app to add the dependency.":"[buoy] No reload mechanism available. Run in __DEV__ or install expo-updates."}n(V,"unavailableMessage");async function F(e="auto",t="buoy reload"){let r=$(e);if(!r)throw new Error(V(e));return r==="browser"?j()():r==="dev-settings"?C().reload(t):await O().reloadAsync(),await new Promise(()=>{})}n(F,"reloadApp");var le=250;function ce(e){let t=e?.strategy??"auto",r=$(t);if(!r)throw new Error(V(t));let a=Math.max(0,e?.delayMs??le),o=e?.reason??"buoy remote reload";return setTimeout(()=>{F(r,o).catch(()=>{})},a),{strategy:r,delayMs:a}}n(ce,"scheduleReloadApp");function de(){return null}n(de,"getDevServerOrigin");function pe(){let e=globalThis.__buoyRealNow;return typeof e=="function"?e():Date.now()}n(pe,"realNow");var fe=class ct{constructor(){this.listeners=new Set;this.subscribe=this.subscribe.bind(this)}subscribe(t){return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}getListenerCount(){return this.listeners.size}notify(...t){this.listeners.forEach(r=>{r(...t)})}onSubscribe(){}onUnsubscribe(){}};n(fe,"Subscribable");var Ze=fe;var he=class dt{constructor(){this.listeners=new Set}subscribe(t){return this.listeners.add(t),()=>{this.listeners.delete(t)}}notify(t){this.listeners.forEach(r=>{try{r(t)}catch{}})}};n(he,"SubscriberCountNotifier");var et=he,U=new et,tt=n(e=>U.subscribe(e),"subscribeToSubscriberCountChanges"),rt=n(e=>U.notify(e),"notifySubscriberCountChange");import{useSyncExternalStore as ye}from"react";var c,S=new Set,W,be;function ge(e){return c=e,()=>{c===e&&(c=void 0)}}n(ge,"registerBrowserRouter");function h(){return typeof location>"u"?"/":location.href}n(h,"getBrowserHref");function I(e=h()){let t=new URL(e,"http://localhost"),r=t.hash.startsWith("#/")?new URL(t.hash.slice(1),t.origin):t;return r.pathname||(r.pathname="/"),r}n(I,"getBrowserRouteURL");var w;function q(e){if(!S.size&&typeof window<"u"){let t=window.history,r=n(o=>{for(let i of[...S])try{i({href:h(),kind:o})}catch{}},"emit");if(w)w.active=true;else{let o=t.pushState,i=t.replaceState,s={push:o,replace:i,active:true},f=n(function(...m){let b=Reflect.apply(o,this,m);return s.active&&r("push"),b},"wrappedPush"),l=n(function(...m){let b=Reflect.apply(i,this,m);return s.active&&r("replace"),b},"wrappedReplace");t.pushState=f,t.replaceState=l,w=s,be=n(()=>{t.pushState!==f||t.replaceState!==l||(t.pushState=o,t.replaceState=i,w=void 0)},"unwrap")}let a=n(()=>r("pop"),"pop");window.addEventListener("popstate",a),window.addEventListener("hashchange",a),W=n(()=>{w&&(w.active=false),be?.(),window.removeEventListener("popstate",a),window.removeEventListener("hashchange",a),W=void 0},"detach")}return S.add(e),()=>{S.delete(e),S.size||W?.()}}n(q,"subscribeBrowserNavigation");function z(e){let t=typeof e=="string"?e:e.pathname,r=new URL(t,h());if(r.origin!==window.location.origin)throw new Error("Tool navigation must stay on the current origin.");if(typeof e!="string")for(let[a,o]of Object.entries(e.params??{}))r.searchParams.set(a,String(o));return`${r.pathname}${r.search}${r.hash}`}n(z,"pathFor");var E={push(e){let t=z(e);if(c)return c.push(t);window.history.pushState(null,"",window.location.hash.startsWith("#/")?`#${t}`:t),window.dispatchEvent(new PopStateEvent("popstate",{state:window.history.state}))},replace(e){let t=z(e);if(c)return c.replace(t);window.history.replaceState(window.history.state,"",window.location.hash.startsWith("#/")?`#${t}`:t),window.dispatchEvent(new PopStateEvent("popstate",{state:window.history.state}))},back(){c?c.back():window.history.back()},canGoBack(){return c?.canGoBack?.()??(typeof window<"u"&&window.history.length>1)},navigate(e){E.push(e)},setParams(e){E.replace({pathname:h(),params:e})},dismiss(e=1){window.history.go(-e)},dismissAll(){throw new Error("Use the captured browser history to select a destination.")}};var we=n(e=>q(e),"subscribe"),M=I;function me(){return E}n(me,"useSafeRouter");function J(){return ye(we,h,()=>"/"),M().pathname}n(J,"useSafePathname");function ve(){return J().split("/").filter(Boolean)}n(ve,"useSafeSegments");function Se(){return ye(we,h,()=>"/"),Object.fromEntries(M().searchParams)}n(Se,"useSafeGlobalSearchParams");function Ee(){return typeof window>"u"?null:E}n(Ee,"getSafeRouter");function Re(){return M().pathname}n(Re,"getSafeCurrentPathname");function Te(){let e=M();return{pathname:e.pathname,href:`${e.pathname}${e.search}${e.hash}`,segments:e.pathname.split("/").filter(Boolean)}}n(Te,"getSafeCurrentRoute");function xe(){return false}n(xe,"isExpoRouterAvailable");var Ce=new WeakMap,nt=1;function y(e){return!!e&&typeof e=="object"&&e.nodeType===1&&typeof e.getBoundingClientRect=="function"}n(y,"isDOMElement");function D(e){if(!y(e))return null;let t=Ce.get(e);return t===void 0&&(t=nt++,Ce.set(e,t)),t}n(D,"getDOMNodeHandle");function Oe(e){if(!y(e))return null;let t=Object.keys(e).find(r=>r.startsWith("__reactFiber$"));return t?e[t]:null}n(Oe,"getDOMFiber");function je(e,t){if(!y(e)||!t)return t;let r=e,a=e.tagName.toLowerCase(),o=a==="input"&&(r.type==="checkbox"||r.type==="radio"),i=a==="input"&&r.type==="range",s=a==="textarea"||a==="select"||a==="input"&&!o&&!i&&!["button","submit","reset","file","hidden"].includes(r.type),f=e.getAttribute("contenteditable"),l=!s&&!o&&!i&&(e.isContentEditable===true||f!==null&&f!=="false"),m=n(d=>{let u=e;u.focus();let k=u.ownerDocument.getSelection?.();if(k){let K=u.ownerDocument.createRange();K.selectNodeContents(u),k.removeAllRanges(),k.addRange(K)}let A=false;try{A=typeof u.ownerDocument.execCommand=="function"&&u.ownerDocument.execCommand("insertText",false,d)}catch{A=false}A||(u.textContent=d,u.dispatchEvent(new InputEvent("input",{bubbles:true,inputType:"insertText",data:d})))},"setEditable"),b=n(d=>{if(o){r.checked!==!!d&&r.click();return}let u=Object.getOwnPropertyDescriptor(Object.getPrototypeOf(r),"value")?.set;u?u.call(r,String(d)):r.value=String(d),r.dispatchEvent(new Event("input",{bubbles:true})),r.dispatchEvent(new Event("change",{bubbles:true}))},"setValue");return{...t,__buoyDevToolsRoot:t.__buoyDevToolsRoot||t["data-buoy-root"]!==void 0,testID:t.testID??t["data-testid"],nativeID:t.nativeID??t.id,accessibilityLabel:t.accessibilityLabel??t["aria-label"],accessibilityRole:t.accessibilityRole??t.role??(a==="button"?"button":a==="a"?"link":o?r.type:s||l?"textbox":i?"slider":void 0),onPress:t.onPress??(typeof t.onClick=="function"||a==="button"||a==="a"?()=>r.click():void 0),...o||i?{onValueChange:b,value:o?r.checked:Number(r.value),...i?{minimumValue:Number(r.min||0),maximumValue:Number(r.max||100)}:{}}:{},...s?{onChangeText:b,value:r.value}:{},...l?{onChangeText:n(d=>m(String(d)),"onChangeText"),value:e.innerText??e.textContent??""}:{}}}n(je,"getDOMControlProps");function $e(e){return y(e)?{__nativeTag:D(e),measure(t){let r=e.getBoundingClientRect();t(r.x,r.y,r.width,r.height,r.x,r.y)},measureInWindow(t){let r=e.getBoundingClientRect();t(r.x,r.y,r.width,r.height)},requestTVFocus(){e.focus()},focus(){e.focus()}}:null}n($e,"getDOMPublicInstance");var at={topFocus:"focus",topBlur:"blur",topTouchStart:"pointerdown",topTouchMove:"pointermove",topTouchEnd:"pointerup",topTouchCancel:"pointercancel",topChange:"input",topValueChange:"input",topSlidingComplete:"change"};function Me(){return typeof document>"u"?{emitter:null,reason:"DOM events are unavailable during server rendering."}:{reason:null,emitter:{addListener(e,t){let r=at[e];if(!r)throw new Error(`Unsupported DOM event: ${e}`);let a=n(o=>{let i=o.composedPath()[0]??o.target;if(!y(i))return;let s=i,f=o,l={target:D(i),pageX:f.clientX,pageY:f.clientY};(r==="input"||r==="change")&&(s.type==="checkbox"||s.type==="radio"?l.value=s.checked:s.type==="range"?l.value=Number(s.value):l.text=s.value??i.textContent??""),t({eventName:e,nativeEvent:l})},"callback");return document.addEventListener(r,a,true),{remove:n(()=>document.removeEventListener(r,a,true),"remove")}}}}}n(Me,"resolveDOMEventEmitter");var G=new Map,De=0;function Pe(e){for(let[t,r]of Object.entries(e)){let a=t.startsWith("@buoy-gg/")?t.replace(/\/web$/,""):`@buoy-gg/${t}`;G.get(a)!==r&&(G.set(a,r),De++)}}n(Pe,"registerToolModules");function H(e){return G.get(e)??null}n(H,"getRegisteredToolModule");function ke(){return De}n(ke,"getToolModuleVersion");function Ae(e){let t=H(e);if(!t)throw new Error(`Register ${e} with createWebTools before opening tools that use it.`);return t}n(Ae,"loadToolModule");import{Component as ot}from"react";var Ne="__buoyFiberRootAnchors",it=3;function P(){let e=globalThis;return e[Ne]??(e[Ne]=new Set)}n(P,"anchors");var _e=class ht extends ot{componentDidMount(){P().add(this)}componentWillUnmount(){P().delete(this)}render(){return null}};n(_e,"FiberRootAnchor");var st=_e;function Le(){let e=new Set;for(let t of P()){let r=t._reactInternals;for(let a=0;r&&a<1e4;a++){if(r.tag===it&&!r.return){r.stateNode?.current&&e.add(r.stateNode);break}r=r.return}}return[...e]}n(Le,"getAnchoredFiberRoots");export{Ze as a,U as b,tt as c,rt as d,pe as e,Ve as f,Fe as g,Ue as h,We as i,Ie as j,qe as k,ze as l,Je as m,Ge as n,He as o,Ke as p,Xe as q,N as r,Ye as s,Y as t,te as u,ne as v,ae as w,oe as x,ie as y,se as z,ue as A,$ as B,F as C,le as D,ce as E,de as F,ge as G,h as H,I,q as J,E as K,me as L,J as M,ve as N,Se as O,Ee as P,Re as Q,Te as R,xe as S,y as T,D as U,Oe as V,je as W,$e as X,Me as Y,Pe as Z,H as _,ke as $,Ae as aa,st as ba,Le as ca};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import{a as e}from"./chunk-T6T3FEMU.mjs";var o={base:"@react_buoy",bubble:{root:e(()=>`${o.base}_bubble`,"root"),settings:e(()=>`${o.bubble.root()}_settings`,"settings"),userPreferences:e(()=>`${o.bubble.root()}_user_preferences`,"userPreferences"),position:e(()=>`${o.bubble.root()}_position`,"position")},modal:{root:e(()=>`${o.base}_modal`,"root"),state:e(()=>`${o.modal.root()}_state`,"state"),position:e(()=>`${o.modal.root()}_position`,"position"),dimensions:e(()=>`${o.modal.root()}_dimensions`,"dimensions"),hintAcknowledged:e(()=>`${o.modal.root()}_hint_acknowledged`,"hintAcknowledged")},custom:e(t=>{let r=`${o.base}_custom_${t}`;return{root:e(()=>r,"root"),modal:e(()=>`${r}_modal`,"modal"),settings:e(()=>`${r}_settings`,"settings"),key:e(s=>`${r}_${s}`,"key")}},"custom"),askBuoy:{root:e(()=>`${o.base}_ask_buoy`,"root"),model:e(()=>`${o.askBuoy.root()}_model`,"model")},settings:{root:e(()=>`${o.base}_settings`,"root"),theme:e(()=>`${o.settings.root()}_theme`,"theme"),preferences:e(()=>`${o.settings.root()}_preferences`,"preferences"),wifiEnabled:e(()=>`${o.settings.root()}_wifi_enabled`,"wifiEnabled"),global:e(()=>`${o.settings.root()}_global`,"global"),activeTab:e(()=>`${o.settings.root()}_active_tab`,"activeTab"),modalOpen:e(()=>`${o.settings.root()}_modal_open`,"modalOpen")},dial:{root:e(()=>`${o.base}_dial`,"root"),isOpen:e(()=>`${o.dial.root()}_is_open`,"isOpen"),usage:e(()=>`${o.dial.root()}_usage`,"usage")},clipboard:{root:e(()=>`${o.base}_clipboard`,"root"),hintAcknowledged:e(()=>`${o.clipboard.root()}_hint_acknowledged`,"hintAcknowledged")},env:{root:e(()=>`${o.base}_env`,"root"),modal:e(()=>`${o.env.root()}_modal`,"modal"),currentEnv:e(()=>`${o.env.root()}_current`,"currentEnv"),overrides:e(()=>`${o.env.root()}_overrides`,"overrides")},sentry:{root:e(()=>`${o.base}_sentry`,"root"),modal:e(()=>`${o.sentry.root()}_modal`,"modal"),filters:e(()=>`${o.sentry.root()}_filters`,"filters"),preferences:e(()=>`${o.sentry.root()}_preferences`,"preferences")},storage:{root:e(()=>`${o.base}_storage`,"root"),modal:e(()=>`${o.storage.root()}_modal`,"modal"),eventsModal:e(()=>`${o.storage.root()}_events_modal`,"eventsModal"),filters:e(()=>`${o.storage.root()}_filters`,"filters"),eventFilters:e(()=>`${o.storage.root()}_event_filters`,"eventFilters"),keyFilters:e(()=>`${o.storage.root()}_key_filters`,"keyFilters"),pinnedKeys:e(()=>`${o.storage.root()}_pinned_keys`,"pinnedKeys"),preferences:e(()=>`${o.storage.root()}_preferences`,"preferences"),activeTab:e(()=>`${o.storage.root()}_active_tab`,"activeTab"),isMonitoring:e(()=>`${o.storage.root()}_is_monitoring`,"isMonitoring"),diffViewerMode:e(()=>`${o.storage.root()}_diff_viewer_mode`,"diffViewerMode")},clock:{root:e(()=>`${o.base}_clock`,"root"),state:e(()=>`${o.clock.root()}_state`,"state")},bugLinks:{root:e(()=>`${o.base}_bug_links`,"root"),links:e(()=>`${o.bugLinks.root()}_links`,"links"),settings:e(()=>`${o.bugLinks.root()}_settings`,"settings"),loaded:e(()=>`${o.bugLinks.root()}_loaded`,"loaded")},permissions:{root:e(()=>`${o.base}_permissions`,"root"),state:e(()=>`${o.permissions.root()}_state`,"state")},lifecycle:{root:e(()=>`${o.base}_lifecycle`,"root"),state:e(()=>`${o.lifecycle.root()}_state`,"state")},location:{root:e(()=>`${o.base}_location`,"root"),state:e(()=>`${o.location.root()}_state`,"state")},timeMachine:{root:e(()=>`${o.base}_time_machine`,"root"),diffViewerMode:e(()=>`${o.timeMachine.root()}_diff_viewer_mode`,"diffViewerMode"),armedPoint:e(()=>`${o.timeMachine.root()}_armed_point`,"armedPoint"),barReloadMode:e(()=>`${o.timeMachine.root()}_bar_reload_mode`,"barReloadMode"),disabledSources:e(()=>`${o.timeMachine.root()}_disabled_sources`,"disabledSources")},scenarios:{root:e(()=>`${o.base}_scenarios`,"root"),modal:e(()=>`${o.scenarios.root()}_modal`,"modal"),library:e(()=>`${o.scenarios.root()}_library`,"library"),active:e(()=>`${o.scenarios.root()}_active`,"active"),team:e(()=>`${o.scenarios.root()}_team`,"team")},reactQuery:{root:e(()=>`${o.base}_rq`,"root"),modal:e(()=>`${o.reactQuery.root()}_modal`,"modal"),browserModal:e(()=>`${o.reactQuery.root()}_browser_modal`,"browserModal"),mutationModal:e(()=>`${o.reactQuery.root()}_mutation_modal`,"mutationModal"),filters:e(()=>`${o.reactQuery.root()}_filters`,"filters"),ignoredPatterns:e(()=>`${o.reactQuery.root()}_ignored_patterns`,"ignoredPatterns"),includedPatterns:e(()=>`${o.reactQuery.root()}_included_patterns`,"includedPatterns"),preferences:e(()=>`${o.reactQuery.root()}_preferences`,"preferences")},network:{root:e(()=>`${o.base}_network`,"root"),modal:e(()=>`${o.network.root()}_modal`,"modal"),copyModal:e(()=>`${o.network.root()}_copy_modal`,"copyModal"),filters:e(()=>`${o.network.root()}_filters`,"filters"),ignoredDomains:e(()=>`${o.network.root()}_ignored_domains`,"ignoredDomains"),ignoredUrls:e(()=>`${o.network.root()}_ignored_urls`,"ignoredUrls"),preferences:e(()=>`${o.network.root()}_preferences`,"preferences"),copyOptions:e(()=>`${o.network.root()}_copy_options`,"copyOptions"),saved:e(()=>`${o.network.root()}_saved`,"saved"),overrides:e(()=>`${o.network.root()}_overrides`,"overrides")},routeEvents:{root:e(()=>`${o.base}_route_events`,"root"),modal:e(()=>`${o.routeEvents.root()}_modal`,"modal"),eventFilters:e(()=>`${o.routeEvents.root()}_event_filters`,"eventFilters"),activeTab:e(()=>`${o.routeEvents.root()}_active_tab`,"activeTab"),isMonitoring:e(()=>`${o.routeEvents.root()}_is_monitoring`,"isMonitoring"),detailView:e(()=>`${o.routeEvents.root()}_detail_view`,"detailView"),diffViewerMode:e(()=>`${o.routeEvents.root()}_diff_viewer_mode`,"diffViewerMode")},highlightUpdates:{root:e(()=>`${o.base}_highlight_updates`,"root"),modal:e(()=>`${o.highlightUpdates.root()}_modal`,"modal"),isTracking:e(()=>`${o.highlightUpdates.root()}_is_tracking`,"isTracking"),filters:e(()=>`${o.highlightUpdates.root()}_filters`,"filters"),settings:e(()=>`${o.highlightUpdates.root()}_settings`,"settings"),copySettings:e(()=>`${o.highlightUpdates.root()}_copy_settings`,"copySettings")},benchmark:{root:e(()=>`${o.base}_benchmark`,"root"),modal:e(()=>`${o.benchmark.root()}_modal`,"modal"),isRecording:e(()=>`${o.benchmark.root()}_is_recording`,"isRecording"),activeTab:e(()=>`${o.benchmark.root()}_active_tab`,"activeTab"),settings:e(()=>`${o.benchmark.root()}_settings`,"settings"),selectedReports:e(()=>`${o.benchmark.root()}_selected_reports`,"selectedReports")},debugBorders:{root:e(()=>`${o.base}_debug_borders`,"root"),infoModal:e(()=>`${o.debugBorders.root()}_info_modal`,"infoModal")},events:{root:e(()=>`${o.base}_events`,"root"),modal:e(()=>`${o.events.root()}_modal`,"modal"),enabledSources:e(()=>`${o.events.root()}_enabled_sources`,"enabledSources"),isCapturing:e(()=>`${o.events.root()}_is_capturing`,"isCapturing"),pausedAt:e(()=>`${o.events.root()}_paused_at`,"pausedAt"),copySettings:e(()=>`${o.events.root()}_copy_settings`,"copySettings")},sync:{root:e(()=>`${o.base}_sync`,"root"),deviceId:e(()=>`${o.sync.root()}_device_id`,"deviceId")}},u=["@devtools","@dev_tools_","@modal_state_","@react_query_browser_modal","@react_query_modal","@react_query_mutation_modal","@sentry_logs_modal","@floating_rn_better_dev_tools_","@floating_tools_","@apphost_","@bubble_settings_","@env_vars_modal","@storage_modal","@floating_@devtools_","dev_last_route"];function c(t){if(!t)return false;for(let r of["@AsyncStorage:","CapacitorStorage."])t.startsWith(r)&&(t=t.slice(r.length));if(t.startsWith(o.base)||t.startsWith("buoy-")||t.startsWith("@buoy")||/^(?:buoy[._]|__buoy|react-buoy)/i.test(t))return true;for(let r of u)if(t.startsWith(r))return true;return false}e(c,"isDevToolsStorageKey");var l=new Set;function
|
|
1
|
+
"use client";import{a as e}from"./chunk-T6T3FEMU.mjs";var o={base:"@react_buoy",bubble:{root:e(()=>`${o.base}_bubble`,"root"),settings:e(()=>`${o.bubble.root()}_settings`,"settings"),userPreferences:e(()=>`${o.bubble.root()}_user_preferences`,"userPreferences"),position:e(()=>`${o.bubble.root()}_position`,"position")},modal:{root:e(()=>`${o.base}_modal`,"root"),state:e(()=>`${o.modal.root()}_state`,"state"),position:e(()=>`${o.modal.root()}_position`,"position"),dimensions:e(()=>`${o.modal.root()}_dimensions`,"dimensions"),hintAcknowledged:e(()=>`${o.modal.root()}_hint_acknowledged`,"hintAcknowledged")},custom:e(t=>{let r=`${o.base}_custom_${t}`;return{root:e(()=>r,"root"),modal:e(()=>`${r}_modal`,"modal"),settings:e(()=>`${r}_settings`,"settings"),key:e(s=>`${r}_${s}`,"key")}},"custom"),askBuoy:{root:e(()=>`${o.base}_ask_buoy`,"root"),model:e(()=>`${o.askBuoy.root()}_model`,"model")},settings:{root:e(()=>`${o.base}_settings`,"root"),theme:e(()=>`${o.settings.root()}_theme`,"theme"),preferences:e(()=>`${o.settings.root()}_preferences`,"preferences"),wifiEnabled:e(()=>`${o.settings.root()}_wifi_enabled`,"wifiEnabled"),global:e(()=>`${o.settings.root()}_global`,"global"),activeTab:e(()=>`${o.settings.root()}_active_tab`,"activeTab"),modalOpen:e(()=>`${o.settings.root()}_modal_open`,"modalOpen")},dial:{root:e(()=>`${o.base}_dial`,"root"),isOpen:e(()=>`${o.dial.root()}_is_open`,"isOpen"),usage:e(()=>`${o.dial.root()}_usage`,"usage")},clipboard:{root:e(()=>`${o.base}_clipboard`,"root"),hintAcknowledged:e(()=>`${o.clipboard.root()}_hint_acknowledged`,"hintAcknowledged")},env:{root:e(()=>`${o.base}_env`,"root"),modal:e(()=>`${o.env.root()}_modal`,"modal"),currentEnv:e(()=>`${o.env.root()}_current`,"currentEnv"),overrides:e(()=>`${o.env.root()}_overrides`,"overrides")},sentry:{root:e(()=>`${o.base}_sentry`,"root"),modal:e(()=>`${o.sentry.root()}_modal`,"modal"),filters:e(()=>`${o.sentry.root()}_filters`,"filters"),preferences:e(()=>`${o.sentry.root()}_preferences`,"preferences")},storage:{root:e(()=>`${o.base}_storage`,"root"),modal:e(()=>`${o.storage.root()}_modal`,"modal"),eventsModal:e(()=>`${o.storage.root()}_events_modal`,"eventsModal"),filters:e(()=>`${o.storage.root()}_filters`,"filters"),eventFilters:e(()=>`${o.storage.root()}_event_filters`,"eventFilters"),keyFilters:e(()=>`${o.storage.root()}_key_filters`,"keyFilters"),pinnedKeys:e(()=>`${o.storage.root()}_pinned_keys`,"pinnedKeys"),preferences:e(()=>`${o.storage.root()}_preferences`,"preferences"),activeTab:e(()=>`${o.storage.root()}_active_tab`,"activeTab"),isMonitoring:e(()=>`${o.storage.root()}_is_monitoring`,"isMonitoring"),diffViewerMode:e(()=>`${o.storage.root()}_diff_viewer_mode`,"diffViewerMode")},clock:{root:e(()=>`${o.base}_clock`,"root"),state:e(()=>`${o.clock.root()}_state`,"state")},bugLinks:{root:e(()=>`${o.base}_bug_links`,"root"),links:e(()=>`${o.bugLinks.root()}_links`,"links"),settings:e(()=>`${o.bugLinks.root()}_settings`,"settings"),loaded:e(()=>`${o.bugLinks.root()}_loaded`,"loaded")},permissions:{root:e(()=>`${o.base}_permissions`,"root"),state:e(()=>`${o.permissions.root()}_state`,"state")},lifecycle:{root:e(()=>`${o.base}_lifecycle`,"root"),state:e(()=>`${o.lifecycle.root()}_state`,"state")},location:{root:e(()=>`${o.base}_location`,"root"),state:e(()=>`${o.location.root()}_state`,"state")},timeMachine:{root:e(()=>`${o.base}_time_machine`,"root"),diffViewerMode:e(()=>`${o.timeMachine.root()}_diff_viewer_mode`,"diffViewerMode"),armedPoint:e(()=>`${o.timeMachine.root()}_armed_point`,"armedPoint"),barReloadMode:e(()=>`${o.timeMachine.root()}_bar_reload_mode`,"barReloadMode"),disabledSources:e(()=>`${o.timeMachine.root()}_disabled_sources`,"disabledSources")},scenarios:{root:e(()=>`${o.base}_scenarios`,"root"),modal:e(()=>`${o.scenarios.root()}_modal`,"modal"),library:e(()=>`${o.scenarios.root()}_library`,"library"),active:e(()=>`${o.scenarios.root()}_active`,"active"),team:e(()=>`${o.scenarios.root()}_team`,"team")},reactQuery:{root:e(()=>`${o.base}_rq`,"root"),modal:e(()=>`${o.reactQuery.root()}_modal`,"modal"),browserModal:e(()=>`${o.reactQuery.root()}_browser_modal`,"browserModal"),mutationModal:e(()=>`${o.reactQuery.root()}_mutation_modal`,"mutationModal"),filters:e(()=>`${o.reactQuery.root()}_filters`,"filters"),ignoredPatterns:e(()=>`${o.reactQuery.root()}_ignored_patterns`,"ignoredPatterns"),includedPatterns:e(()=>`${o.reactQuery.root()}_included_patterns`,"includedPatterns"),preferences:e(()=>`${o.reactQuery.root()}_preferences`,"preferences")},network:{root:e(()=>`${o.base}_network`,"root"),modal:e(()=>`${o.network.root()}_modal`,"modal"),copyModal:e(()=>`${o.network.root()}_copy_modal`,"copyModal"),filters:e(()=>`${o.network.root()}_filters`,"filters"),ignoredDomains:e(()=>`${o.network.root()}_ignored_domains`,"ignoredDomains"),ignoredUrls:e(()=>`${o.network.root()}_ignored_urls`,"ignoredUrls"),preferences:e(()=>`${o.network.root()}_preferences`,"preferences"),copyOptions:e(()=>`${o.network.root()}_copy_options`,"copyOptions"),saved:e(()=>`${o.network.root()}_saved`,"saved"),overrides:e(()=>`${o.network.root()}_overrides`,"overrides")},routeEvents:{root:e(()=>`${o.base}_route_events`,"root"),modal:e(()=>`${o.routeEvents.root()}_modal`,"modal"),eventFilters:e(()=>`${o.routeEvents.root()}_event_filters`,"eventFilters"),activeTab:e(()=>`${o.routeEvents.root()}_active_tab`,"activeTab"),isMonitoring:e(()=>`${o.routeEvents.root()}_is_monitoring`,"isMonitoring"),detailView:e(()=>`${o.routeEvents.root()}_detail_view`,"detailView"),diffViewerMode:e(()=>`${o.routeEvents.root()}_diff_viewer_mode`,"diffViewerMode")},highlightUpdates:{root:e(()=>`${o.base}_highlight_updates`,"root"),modal:e(()=>`${o.highlightUpdates.root()}_modal`,"modal"),isTracking:e(()=>`${o.highlightUpdates.root()}_is_tracking`,"isTracking"),filters:e(()=>`${o.highlightUpdates.root()}_filters`,"filters"),settings:e(()=>`${o.highlightUpdates.root()}_settings`,"settings"),copySettings:e(()=>`${o.highlightUpdates.root()}_copy_settings`,"copySettings")},benchmark:{root:e(()=>`${o.base}_benchmark`,"root"),modal:e(()=>`${o.benchmark.root()}_modal`,"modal"),isRecording:e(()=>`${o.benchmark.root()}_is_recording`,"isRecording"),activeTab:e(()=>`${o.benchmark.root()}_active_tab`,"activeTab"),settings:e(()=>`${o.benchmark.root()}_settings`,"settings"),selectedReports:e(()=>`${o.benchmark.root()}_selected_reports`,"selectedReports")},debugBorders:{root:e(()=>`${o.base}_debug_borders`,"root"),infoModal:e(()=>`${o.debugBorders.root()}_info_modal`,"infoModal")},events:{root:e(()=>`${o.base}_events`,"root"),modal:e(()=>`${o.events.root()}_modal`,"modal"),enabledSources:e(()=>`${o.events.root()}_enabled_sources`,"enabledSources"),isCapturing:e(()=>`${o.events.root()}_is_capturing`,"isCapturing"),pausedAt:e(()=>`${o.events.root()}_paused_at`,"pausedAt"),copySettings:e(()=>`${o.events.root()}_copy_settings`,"copySettings")},sync:{root:e(()=>`${o.base}_sync`,"root"),deviceId:e(()=>`${o.sync.root()}_device_id`,"deviceId")}},u=["@devtools","@dev_tools_","@modal_state_","@react_query_browser_modal","@react_query_modal","@react_query_mutation_modal","@sentry_logs_modal","@floating_rn_better_dev_tools_","@floating_tools_","@apphost_","@bubble_settings_","@env_vars_modal","@storage_modal","@floating_@devtools_","dev_last_route"];function c(t){if(!t)return false;for(let r of["@AsyncStorage:","CapacitorStorage."])t.startsWith(r)&&(t=t.slice(r.length));if(t.startsWith(o.base)||t.startsWith("buoy-")||t.startsWith("@buoy")||/^(?:buoy[._]|__buoy|react-buoy)/i.test(t))return true;for(let r of u)if(t.startsWith(r))return true;return false}e(c,"isDevToolsStorageKey");var l=new Set;function m(t){return l.add(t),()=>l.delete(t)}e(m,"subscribeStorageWrites");function d(t,r){for(let s of[...l])try{s(t,r)}catch{}}e(d,"notifyStorageWrite");var a=new Map;function i(){try{return typeof window>"u"?null:window.localStorage}catch{return null}}e(i,"storage");var n={async getItem(t){if(a.has(t))return a.get(t)??null;try{return i()?.getItem(t)??null}catch{return null}},async setItem(t,r){a.set(t,r);try{let s=i();s&&(s.setItem(t,r),a.delete(t))}catch{}d(t,r)},async removeItem(t){a.set(t,null);try{let r=i();r&&(r.removeItem(t),a.delete(t))}catch{}d(t,null)},async getAllKeys(){let t=new Set;try{let r=i();if(r)for(let s=0;s<r.length;s++){let _=r.key(s);_?.startsWith(o.base)&&t.add(_)}}catch{}for(let[r,s]of a)r.startsWith(o.base)&&(s===null?t.delete(r):t.add(r));return[...t]},async multiGet(t){return Promise.all(t.map(async r=>[r,await n.getItem(r)]))},async multiRemove(t){await Promise.all(t.map(r=>n.removeItem(r)))},async clear(){await n.multiRemove(await n.getAllKeys())}};async function g(){return i()!==null}e(g,"isUsingPersistentStorage");async function $(){return i()?"localstorage":"memory"}e($,"getStorageBackendType");export{o as a,c as b,m as c,n as d,g as e,$ as f};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use client";import{e as ge}from"./chunk-FPMEM2QO.mjs";import{d as j}from"./chunk-SXWOOYFL.mjs";import{A as N,B as q,H as U,I as r,W as fe,r as T,s as S,t as w,v as A,y as V}from"./chunk-QXVVA64P.mjs";import{a as l}from"./chunk-T6T3FEMU.mjs";import{useCallback as he,useEffect as ye,useRef as z,useState as K}from"react";var B=new Map;function X(e){try{return JSON.parse(e)}catch{return}}l(X,"defaultParse");function _(e,t,n={}){let[s,o]=K(()=>B.has(e)?B.get(e):t),[v,h]=K(()=>B.has(e)),d=z(e);d.current=e;let u=z(n);u.current=n,ye(()=>{if(B.has(e)){o(B.get(e)),h(true);return}let c=false,m=u.current.storage??j,p=u.current.parse??X;return m.getItem(e).then(y=>{if(!c){if(y!=null){let g;try{g=p(y)}catch{}g!==void 0&&(B.set(e,g),o(g))}h(true)}}).catch(()=>{c||h(true)}),()=>{c=true}},[e]);let I=he(c=>{o(m=>{let p=typeof c=="function"?c(m):c;B.set(d.current,p);let y=u.current.storage??j,g=u.current.serialize??JSON.stringify;try{y.setItem(d.current,g(p)).catch(()=>{})}catch{}return p})},[]);return[s,I,v]}l(_,"usePersistedState");function Q(){B.clear()}l(Q,"resetPersistedStateCache");import{useCallback as F,useEffect as Z,useMemo as Se,useState as D}from"react";function ee(e,t={}){let[n,s]=D(()=>e.getAll()),[o,v]=D(()=>t.initialFilter??{}),[h,d]=D(()=>e.getEnabled());Z(()=>e.subscribe(s),[e]);let u=t.filterItems,I=Se(()=>u?u(n,o):n,[n,o,u]),c=F(()=>{e.clear()},[e]),m=F(()=>{let y=!h;e.setEnabled(y),d(y)},[e,h]),p=F(y=>e.getById(y),[e]);return{items:n,filteredItems:I,filter:o,setFilter:v,isEnabled:h,toggleCapture:m,clear:c,getById:p}}l(ee,"useChangeLog");function te(e,t){let[n,s]=D(e);return Z(()=>t(s),[t]),n}l(te,"useSubscribedValue");import{useCallback as me,useEffect as pe,useState as ne}from"react";function ie(e,t={}){let{enabled:n=true,maxEvents:s=500,select:o}=t,[v,h]=ne([]),[d,u]=ne(n);pe(()=>{if(!n){u(false);return}let c=null,m=null,p=e.subscribeToEvents(y=>{m=y,c==null&&(c=requestAnimationFrame(()=>{if(c=null,!m)return;let g=m;m=null,o&&(g=o(g)),g.length>s&&(g=g.slice(0,s)),h(g)}))});return u(true),()=>{p(),c!=null&&cancelAnimationFrame(c)}},[e,n,s,o]);let I=me(()=>{e.clearEvents()},[e]);return{events:v,clearEvents:I,isActive:d}}l(ie,"useEventStoreEvents");import{useState as b,useEffect as C,useCallback as be}from"react";async function J(){let[e,t,n]=await Promise.all([S.isScreenReaderEnabled(),S.isReduceMotionEnabled(),S.isReduceTransparencyEnabled()]),s={isScreenReaderEnabled:e,isReduceMotionEnabled:t,isReduceTransparencyEnabled:n};if(r.OS==="ios"){let[o,v,h,d,u]=await Promise.all([S.isBoldTextEnabled?.()??Promise.resolve(false),S.isGrayscaleEnabled?.()??Promise.resolve(false),S.isInvertColorsEnabled?.()??Promise.resolve(false),S.isDarkerSystemColorsEnabled?.()??Promise.resolve(false),S.prefersCrossFadeTransitions?.()??Promise.resolve(false)]);s.isBoldTextEnabled=o,s.isGrayscaleEnabled=v,s.isInvertColorsEnabled=h,s.isDarkerSystemColorsEnabled=d,s.prefersCrossFadeTransitions=u}if(r.OS==="android"){let o=await S.isHighTextContrastEnabled?.()??false;s.isHighTextContrastEnabled=o}return s}l(J,"getAccessibilitySettings");function O(){let e=r.constants,t={os:r.OS,version:r.Version,reactNativeVersion:e.reactNativeVersion,isTesting:r.isTesting??false,isDisableAnimations:e.isDisableAnimations??false};return r.OS==="ios"?{...t,osVersion:e.osVersion,systemName:e.systemName,interfaceIdiom:e.interfaceIdiom,isPad:r.isPad,isTV:r.isTV,isVision:r.isVision??false,isMacCatalyst:r.isMacCatalyst??false,forceTouchAvailable:e.forceTouchAvailable}:r.OS==="android"?{...t,apiLevel:e.Version,release:e.Release,brand:e.Brand,manufacturer:e.Manufacturer,model:e.Model,fingerprint:e.Fingerprint,serial:e.Serial,uiMode:e.uiMode}:t}l(O,"getPlatformInfo");function L(){let e=V.get("window"),t=V.get("screen"),n={window:{width:e.width,height:e.height,scale:e.scale,fontScale:e.fontScale},screen:{width:t.width,height:t.height,scale:t.scale,fontScale:t.fontScale},pixelRatio:U.get(),fontScale:U.getFontScale(),isLandscape:e.width>e.height,isPortrait:e.height>e.width};if(r.OS==="ios")try{let s=T.DeviceInfo?.getConstants?.();n.isIPhoneNotched=s?.isIPhoneX_deprecated??false}catch{n.isIPhoneNotched=false}if(r.OS==="android")try{let s=T.DeviceInfo?.getConstants?.();n.isEdgeToEdge=s?.isEdgeToEdge??false,n.densityDpi=Math.round(e.scale*160)}catch{}return n}l(L,"getDisplayInfo");async function x(){return new Promise(e=>{let t=false;r.OS==="ios"?T.StatusBarManager?.getHeight?.(n=>{t||(t=true,e(n?.height??null))})??e(null):r.OS==="android"?(t=true,e(fe.currentHeight??null)):(t=true,e(null)),setTimeout(()=>{t||(t=true,e(null))},100)})}l(x,"getStatusBarHeight");function P(){let e={isRTL:N.isRTL,doLeftAndRightSwapInRTL:N.doLeftAndRightSwapInRTL};return r.OS==="android"&&(e.localeIdentifier=N.localeIdentifier),e}l(P,"getLocaleInfo");function R(){if(r.OS==="ios")try{return{userDefaults:T.SettingsManager?.getConstants?.()?.settings??{}}}catch{return{}}return{}}l(R,"getSettingsInfo");function k(){let e={};if(r.OS==="android"){let t=r.constants;e.serial=t.Serial,e.fingerprint=t.Fingerprint;try{let n=T.PlatformConstants;n?.getAndroidID&&(e.androidId=n.getAndroidID())}catch{}}return e}l(k,"getUniqueIdentifiers");function ae(e){let t=[e.platform.os,e.platform.version,e.display.window.width,e.display.window.height,e.display.pixelRatio,e.platform.interfaceIdiom??"",e.platform.forceTouchAvailable??false,e.display.isIPhoneNotched??false,e.platform.model??"",e.platform.brand??"",e.platform.manufacturer??"",e.platform.uiMode??""].join("|"),n=0;for(let s=0;s<t.length;s++){let o=t.charCodeAt(s);n=(n<<5)-n+o,n=n&n}return Math.abs(n).toString(16).padStart(8,"0")}l(ae,"generateFingerprint");function se(){let[e,t]=b(true),[n,s]=b(O()),[o,v]=b(L()),[h,d]=b({isScreenReaderEnabled:false,isReduceMotionEnabled:false,isReduceTransparencyEnabled:false}),[u,I]=b(()=>{let f=w.getColorScheme()??null;return{colorScheme:f,prefersDarkMode:f==="dark"}}),[c,m]=b(P()),[p,y]=b({height:null,isVisible:true}),[g,H]=b({isVisible:false,height:0,animationDuration:0}),[G,le]=b({currentState:A.currentState,isActive:A.currentState==="active"}),[W,ce]=b(k()),[Y,de]=b(R()),[$,ue]=b(Date.now()),M=be(async()=>{t(true);let[f,i]=await Promise.all([J(),x()]);s(O()),v(L()),d(f);let a=w.getColorScheme()??null;I({colorScheme:a,prefersDarkMode:a==="dark"}),m(P()),y(E=>({...E,height:i})),ce(k()),de(R()),ue(Date.now()),t(false)},[]);return C(()=>{M()},[M]),C(()=>{let f=V.addEventListener("change",({window:i,screen:a})=>{v(E=>({...E,window:{width:i.width,height:i.height,scale:i.scale,fontScale:i.fontScale},screen:{width:a.width,height:a.height,scale:a.scale,fontScale:a.fontScale},isLandscape:i.width>i.height,isPortrait:i.height>i.width}))});return()=>f.remove()},[]),C(()=>{let f=w.addChangeListener(({colorScheme:i})=>{let a=i??null;I({colorScheme:a,prefersDarkMode:a==="dark"})});return()=>f.remove()},[]),C(()=>{let f=q.addListener(r.OS==="ios"?"keyboardWillShow":"keyboardDidShow",a=>{H({isVisible:true,height:a.endCoordinates.height,animationDuration:a.duration??0})}),i=q.addListener(r.OS==="ios"?"keyboardWillHide":"keyboardDidHide",a=>{H({isVisible:false,height:0,animationDuration:a.duration??0})});return()=>{f.remove(),i.remove()}},[]),C(()=>{let f=ge(i=>{le({currentState:i,isActive:i==="active"})});return()=>f.remove()},[]),C(()=>{let f=[S.addEventListener("screenReaderChanged",i=>{d(a=>({...a,isScreenReaderEnabled:i}))}),S.addEventListener("reduceMotionChanged",i=>{d(a=>({...a,isReduceMotionEnabled:i}))}),S.addEventListener("reduceTransparencyChanged",i=>{d(a=>({...a,isReduceTransparencyEnabled:i}))})];if(r.OS==="ios"){let i=l((a,E)=>S.addEventListener(a,E),"addIOSListener");f.push(i("boldTextChanged",a=>{d(E=>({...E,isBoldTextEnabled:a}))}),i("grayscaleChanged",a=>{d(E=>({...E,isGrayscaleEnabled:a}))}),i("invertColorsChanged",a=>{d(E=>({...E,isInvertColorsEnabled:a}))}))}return()=>{f.forEach(i=>i.remove())}},[]),{platform:n,display:o,accessibility:h,appearance:u,locale:c,statusBar:p,keyboard:g,appState:G,identifiers:W,settings:Y,timestamp:$,isLoading:e,refresh:M,generateFingerprint:l(()=>ae({platform:n,display:o,accessibility:h,appearance:u,locale:c,statusBar:p,keyboard:g,appState:G,identifiers:W,settings:Y,timestamp:$,isLoading:e}),"generateFingerprint")}}l(se,"useDeviceInfo");async function re(){let[e,t]=await Promise.all([J(),x()]),n=w.getColorScheme()??null;return{platform:O(),display:L(),accessibility:e,appearance:{colorScheme:n,prefersDarkMode:n==="dark"},locale:P(),statusBar:{height:t,isVisible:true},keyboard:{isVisible:false,height:0,animationDuration:0},appState:{currentState:A.currentState,isActive:A.currentState==="active"},identifiers:k(),settings:R(),timestamp:Date.now(),isLoading:false}}l(re,"getDeviceInfo");function oe(e){console.log("[Buoy]",`
|
|
2
|
+
========================================`),console.log("[Buoy]"," DEVICE INFO REPORT"),console.log("[Buoy]",`========================================
|
|
3
|
+
`),console.log("[Buoy]","--- PLATFORM ---"),console.log("[Buoy]",JSON.stringify(e.platform,null,2)),console.log("[Buoy]",`
|
|
4
|
+
--- DISPLAY ---`),console.log("[Buoy]",JSON.stringify(e.display,null,2)),console.log("[Buoy]",`
|
|
5
|
+
--- ACCESSIBILITY ---`),console.log("[Buoy]",JSON.stringify(e.accessibility,null,2)),console.log("[Buoy]",`
|
|
6
|
+
--- APPEARANCE ---`),console.log("[Buoy]",JSON.stringify(e.appearance,null,2)),console.log("[Buoy]",`
|
|
7
|
+
--- LOCALE ---`),console.log("[Buoy]",JSON.stringify(e.locale,null,2)),console.log("[Buoy]",`
|
|
8
|
+
--- STATUS BAR ---`),console.log("[Buoy]",JSON.stringify(e.statusBar,null,2)),console.log("[Buoy]",`
|
|
9
|
+
--- KEYBOARD ---`),console.log("[Buoy]",JSON.stringify(e.keyboard,null,2)),console.log("[Buoy]",`
|
|
10
|
+
--- APP STATE ---`),console.log("[Buoy]",JSON.stringify(e.appState,null,2)),console.log("[Buoy]",`
|
|
11
|
+
--- IDENTIFIERS ---`),console.log("[Buoy]",JSON.stringify(e.identifiers,null,2)),console.log("[Buoy]",`
|
|
12
|
+
--- SETTINGS ---`);let t=Object.keys(e.settings.userDefaults??{});console.log("[Buoy]",`userDefaults: ${t.length} keys`),t.length>0&&t.length<=20&&console.log("[Buoy]",JSON.stringify(e.settings,null,2)),console.log("[Buoy]",`
|
|
13
|
+
--- METADATA ---`),console.log("[Buoy]",`timestamp: ${e.timestamp}`),console.log("[Buoy]",`isLoading: ${e.isLoading}`),console.log("[Buoy]",`
|
|
14
|
+
========================================
|
|
15
|
+
`)}l(oe,"logDeviceInfo");export{_ as a,Q as b,ee as c,te as d,ie as e,se as f,re as g,oe as h};
|