@kibalabs/core 0.6.3-next.1 → 0.6.3-next.2

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.
Files changed (56) hide show
  1. package/dist/index.js +1 -1
  2. package/package.json +3 -2
  3. package/dist/index.d.ts +0 -6
  4. package/dist/index.d.ts.map +0 -1
  5. package/dist/model/index.d.ts +0 -2
  6. package/dist/model/index.d.ts.map +0 -1
  7. package/dist/model/kibaException.d.ts +0 -5
  8. package/dist/model/kibaException.d.ts.map +0 -1
  9. package/dist/requester/index.d.ts +0 -5
  10. package/dist/requester/index.d.ts.map +0 -1
  11. package/dist/requester/request.d.ts +0 -12
  12. package/dist/requester/request.d.ts.map +0 -1
  13. package/dist/requester/requester.d.ts +0 -26
  14. package/dist/requester/requester.d.ts.map +0 -1
  15. package/dist/requester/response.d.ts +0 -8
  16. package/dist/requester/response.d.ts.map +0 -1
  17. package/dist/requester/restMethod.d.ts +0 -10
  18. package/dist/requester/restMethod.d.ts.map +0 -1
  19. package/dist/services/index.d.ts +0 -2
  20. package/dist/services/index.d.ts.map +0 -1
  21. package/dist/services/serviceClient.d.ts +0 -15
  22. package/dist/services/serviceClient.d.ts.map +0 -1
  23. package/dist/storage/index.d.ts +0 -2
  24. package/dist/storage/index.d.ts.map +0 -1
  25. package/dist/storage/localStorageClient.d.ts +0 -11
  26. package/dist/storage/localStorageClient.d.ts.map +0 -1
  27. package/dist/util/asyncUtil.d.ts +0 -2
  28. package/dist/util/asyncUtil.d.ts.map +0 -1
  29. package/dist/util/browserUtil.d.ts +0 -5
  30. package/dist/util/browserUtil.d.ts.map +0 -1
  31. package/dist/util/chainUtil.d.ts +0 -5
  32. package/dist/util/chainUtil.d.ts.map +0 -1
  33. package/dist/util/classNameUtil.d.ts +0 -4
  34. package/dist/util/classNameUtil.d.ts.map +0 -1
  35. package/dist/util/dateUtil.d.ts +0 -13
  36. package/dist/util/dateUtil.d.ts.map +0 -1
  37. package/dist/util/fileUtil.d.ts +0 -4
  38. package/dist/util/fileUtil.d.ts.map +0 -1
  39. package/dist/util/index.d.ts +0 -15
  40. package/dist/util/index.d.ts.map +0 -1
  41. package/dist/util/listUtil.d.ts +0 -3
  42. package/dist/util/listUtil.d.ts.map +0 -1
  43. package/dist/util/numberUtil.d.ts +0 -4
  44. package/dist/util/numberUtil.d.ts.map +0 -1
  45. package/dist/util/objectUtil.d.ts +0 -5
  46. package/dist/util/objectUtil.d.ts.map +0 -1
  47. package/dist/util/promiseUtil.d.ts +0 -2
  48. package/dist/util/promiseUtil.d.ts.map +0 -1
  49. package/dist/util/serializationUtil.d.ts +0 -11
  50. package/dist/util/serializationUtil.d.ts.map +0 -1
  51. package/dist/util/stringUtil.d.ts +0 -15
  52. package/dist/util/stringUtil.d.ts.map +0 -1
  53. package/dist/util/typeUtil.d.ts +0 -4
  54. package/dist/util/typeUtil.d.ts.map +0 -1
  55. package/dist/util/urlUtils.d.ts +0 -8
  56. package/dist/util/urlUtils.d.ts.map +0 -1
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- import{addMinutes as N}from"date-fns/addMinutes";import{isValid as L}from"date-fns/isValid";import{parse as V}from"date-fns/parse";import{parseISO as W}from"date-fns/parseISO";import{format as _}from"date-fns-tz";import a from"fs";import l from"path";import w from"deepmerge";import x from"fast-deep-equal";var d=class extends Error{statusCode;constructor(e,t){super(e),this.name=this.constructor.name,this.statusCode=t||500}};let c=function(e){return e.DELETE="delete",e.GET="get",e.HEAD="head",e.OPTIONS="options",e.PATCH="patch",e.POST="post",e.PUT="put",e}({});var u=class{method;url;headers;data;formData;date;timeoutSeconds;constructor(e,t,n,r,s,i,o){this.method=e,this.url=t,this.headers=n||{},this.data=r||null,this.formData=s||null,this.date=i||new Date,this.timeoutSeconds=o&&o>0?o:null}},y=class{status;headers={};date;content="";constructor(e,t,n,r){this.status=e,this.headers=t,this.date=n,this.content=r}};const b=(e,t)=>new Promise((n,r)=>{const s=setTimeout(()=>{r(new d("TIMEOUT"))},e*1e3);t.then(i=>{clearTimeout(s),n(i)},i=>{clearTimeout(s),r(i)})}),K=e=>{let t=e;for(t.startsWith("http://")&&(t=t.slice(7)),t.startsWith("https://")&&(t=t.slice(8));t.endsWith("/");)t=t.slice(0,t.length-1);return t},z=e=>{let t=e;return!t.startsWith("http://")&&!t.startsWith("https://")&&(t=`http://${t}`),t},J=e=>e.startsWith("ipfs://")?e.replace("ipfs://","https://pablo-images.kibalabs.com/v1/ipfs/"):e,R=e=>{const t=new URLSearchParams;return Object.entries(e).forEach(([n,r])=>{Array.isArray(r)?r.forEach(s=>{t.append(n,s)}):t.append(n,r)}),t},Z=(e,t)=>{const n=new URL(e);return Object.keys(t).forEach(r=>{n.searchParams.set(r,String(t[r]))}),n.toString()};var G=class{modifyRequest(e){return e}modifyResponse(e){return e}},X=class{headers;modifiers;shouldIncludeCrossSiteCredentials;constructor(e,t,n=!0){this.headers=e||{},this.modifiers=t||[],this.shouldIncludeCrossSiteCredentials=n}addModifier=e=>{this.modifiers.push(e)};modifyRequest=e=>this.modifiers.reduce((t,n)=>n.modifyRequest(t),e);modifyResponse=e=>this.modifiers.reduce((t,n)=>n.modifyResponse(t),e);getRequest=async(e,t,n,r)=>{const s=new u(c.GET,e,n,t,void 0,new Date,r);return this.makeRequestInternal(s)};postRequest=async(e,t,n,r)=>{const s=new u(c.POST,e,n,t,void 0,new Date,r);return this.makeRequestInternal(s)};putRequest=async(e,t,n,r)=>{const s=new u(c.PUT,e,n,t,void 0,new Date,r);return this.makeRequestInternal(s)};deleteRequest=async(e,t,n,r)=>{const s=new u(c.DELETE,e,n,t,void 0,new Date,r);return this.makeRequestInternal(s)};makeRequest=async(e,t,n,r,s)=>{const i=new u(e,t,r,n,void 0,new Date,s);return this.makeRequestInternal(i)};makeFormRequest=async(e,t,n,r)=>{const s=new u(c.POST,e,n,void 0,t,new Date,r);return this.makeRequestInternal(s)};makeFormPutRequest=async(e,t,n,r)=>{const s=new u(c.PUT,e,n,void 0,t,new Date,r);return this.makeRequestInternal(s)};makeRequestInternal=async e=>{const t=this.modifyRequest(e);let n=await this.makeFetchRequest(t);if(n=this.modifyResponse(n),n.status>=400&&n.status<600){let r=null;try{r=JSON.parse(n.content)}catch{}throw r&&"message"in r?new d(r.message,n.status):new d(n.content,n.status)}return n};makeFetchRequest=async e=>{const t=new URL(e.url),n=new Headers({...this.headers,...e.headers||{}}),r={method:e.method.toUpperCase(),headers:n,credentials:this.shouldIncludeCrossSiteCredentials?"include":"same-origin"};if(e.method===c.GET||e.method===c.DELETE){if(e.data){const o={...e.data};Object.keys(o).forEach(f=>{o[f]===void 0&&delete o[f]}),t.search=R(o).toString()}}else{const o=n.get("Content-Type");e.data?(r.body=JSON.stringify(e.data),o&&o!=="application/json"&&console.warn(`Overwriting content-type header for request from ${o} to application/json`),n.set("content-type","application/json")):e.formData&&(r.body=e.formData)}const s=fetch(t.toString(),r).catch(o=>{throw new d(`The request was made but no response was received: [${o.code}] "${o.message}"`)}).then(async o=>{if(!o)throw new d("The request was made but no response was received.");const f=await o.text(),h={};return o.headers.forEach((j,m)=>{h[m]&&console.warn(`key ${m} will be overwritten. TODO(krish): Implement joining keys!`),h[m]=j}),new y(o.status,h,new Date,f)});return await(e.timeoutSeconds?b(e.timeoutSeconds,s):s)}},Y=class{toObject=()=>({})},Q=class{},v=class{requester;baseUrl;constructor(e,t){this.requester=e,this.baseUrl=t}makeRequest=async(e,t,n,r)=>{const s=`${this.baseUrl}/${t}`,i=await this.requester.makeRequest(e,s,n?.toObject());return r?r.fromObject(JSON.parse(i.content)):null}},ee=class{localStorage;constructor(e){this.localStorage=e}getValue(e){return this.localStorage.getItem(e)}setValue(e,t){t==null?this.removeValue(e):this.localStorage.setItem(e,t)}getBoolean(e){const t=this.getValue(e);return t==="1"?!0:t==="0"?!1:null}setBoolean(e,t){t==null?this.removeValue(e):this.setValue(e,t?"1":"0")}removeValue(e){this.localStorage.removeItem(e)}clear(){this.localStorage.clear()}};const te=e=>new Promise(t=>{setTimeout(t,e)}),T=()=>typeof document<"u",ne=async(e,t)=>{const n=new Blob([t]),r=await URL.createObjectURL(n),s=document.createElement("a");s.href=r,s.download=e,document.body.appendChild(s),s.click(),document.body.removeChild(s)},re=()=>{if(!T())return!1;let e;return document.hidden!==void 0?e="hidden":document.msHidden!==void 0?e="msHidden":document.webkitHidden!==void 0&&(e="webkitHidden"),e?!document[e]:!0},se=()=>typeof navigator>"u"?!1:[/Android/i,/webOS/i,/iPhone/i,/iPad/i,/iPod/i,/BlackBerry/i,/Windows Phone/i].some(t=>t.test(navigator.userAgent)),oe=e=>e.toString().replace(/\B(?=(\d{3})+(?!\d))/g,","),D=e=>e>=1e9?`${(e/1e9).toFixed(0)}B`:e>=1e7?`${(e/1e6).toFixed(0)}M`:e>=1e6?`${(e/1e6).toFixed(1)}M`:e>=1e4?`${(e/1e3).toFixed(0)}K`:e>=1e3?`${(e/1e3).toFixed(1)}K`:e>100?e.toFixed(0):e>1?e.toFixed(1):e.toFixed(2),E=(e,t=2,n=!1,r=!1)=>{let s=e.toFixed(t);if(n){for(;s.charAt(s.length-1)===",";)s=s.slice(0,-1);s.endsWith(".0")&&(s=s.replace(".0",""))}if(r){const i=s.split("."),o=i[0].replace(/\B(?=(\d{3})+(?!\d))/g,",");s=i.length===1?o:`${o}.${i[1]}`}return`${s.toLocaleString()}`},C=BigInt("1000000000000000000"),g=e=>Number(e*1000000n/C)/1e6,ie=e=>`\u039E${D(g(e))}`,ae=(e,t=2,n=!1,r=!1)=>`\u039E${E(g(e),t,n,r)}`,ce=(...e)=>{const t=[];e.forEach(r=>{r&&t.push(String(r).trim().split(" "))});let n=t.reduce((r,s)=>r.concat(s),[]);return n=n.reverse(),n=Array.from(new Set(n)),n=n.reverse(),n.join(" ")},A="yyyy-MM-dd'T'HH:mm:ss.SSSXXX",ue=(e,t)=>{let n;if(!t)n=W(e);else try{n=V(e,t,new Date)}catch{}if(!n||!L(n))throw new d(`Invalid date string ${e} passed to dateFromString`);return n},de=(e,t=A,n=!1)=>{let r=e;return n&&(r=N(r,r.getTimezoneOffset())),_(r,t,n?{timeZone:"UTC"}:{})},p=(e,t)=>e.getDate()===t.getDate()&&e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear(),le=e=>p(e,new Date),fe=e=>{const t=new Date;return t.setDate(t.getDate()-1),p(e,t)},he=(e,t)=>{const n=new Date(e.getTime());return n.setTime(n.getTime()+t*60*60*1e3),n},me=(e,t)=>{const n=new Date(e.getTime());return n.setDate(n.getDate()+t),n},ge=e=>{const t=Math.floor((new Date().valueOf()-e.valueOf())/1e3);let n,r=Math.floor(t/31536e3);return r>=1?n="year":(r=Math.floor(t/2592e3),r>=1?n="month":(r=Math.floor(t/86400),r>=1?n="day":(r=Math.floor(t/3600),r>=1?n="hour":(r=Math.floor(t/60),r>=1?n="minute":(r=t,n="second"))))),(r>1||r===0)&&(n+="s"),`${r} ${n} ago`},pe=e=>{const t=Math.floor((new Date().valueOf()-e.valueOf())/1e3);let n,r=Math.floor(t/31536e3);return r>=1?n="y":(r=Math.floor(t/2592e3),r>=1?n="m":(r=Math.floor(t/86400),r>=1?n="d":(r=Math.floor(t/3600),r>=1?n="h":(r=Math.floor(t/60),r>=1?n="m":(r=t,n="s"))))),`${r}${n} ago`},Se=e=>{const t=new Date(e.getTime());return t.setHours(0,0,0,0),t},we=e=>{const t=new Date(e.getTime());return t.setHours(23,59,59,999),t},ye=(e,t=1)=>{if(e===0)return"0 B";const n=["B","KB","MB","GB","TB","PB","EB","ZB","YB"],r=Math.floor(Math.log(e)/Math.log(1024));return`${parseFloat((e/1024**r).toFixed(t<0?0:t))} ${n[r]}`},F=(e,t)=>{let n=t;a.existsSync(t)&&a.lstatSync(t).isDirectory()&&(n=l.join(t,l.basename(e)));const r=l.dirname(n);a.existsSync(r)||a.mkdirSync(r,{recursive:!0}),a.writeFileSync(n,a.readFileSync(e))},O=(e,t)=>{if(!a.lstatSync(e).isDirectory())throw new Error(`copyDirectorySync must be called with a directory. source ${e} is not a directory`);if(!a.existsSync(t))a.mkdirSync(t,{recursive:!0});else if(!a.lstatSync(e).isDirectory())throw new Error(`copyDirectorySync must be called with a directory. target ${t} is not a directory`);a.readdirSync(e).forEach(n=>{const r=l.join(e,n),s=l.join(t,n);a.lstatSync(r).isDirectory()?O(r,s):F(r,s)})},be=(e,t)=>Array(t-e).fill(null).map((n,r)=>e+r),Re=(e,t)=>e.reduce((n,r,s)=>{const i=Math.floor(s/t);return n[i]||(n[i]=[]),n[i].push(r),n},[]);function Te(e,...t){return w(e,M(...t))}function M(...e){let t={};return e.forEach(n=>{n&&(t=w(t,n))}),t}function De(e,t){return x(e,t)}const Ee=e=>{if(e!==void 0)return e===null?null:JSON.stringify(e)},Ce=e=>{if(e!==void 0)return e===null?null:JSON.parse(e)},Ae=e=>{if(e!==void 0)return e===null?null:e?"1":"0"},Fe=e=>{if(e!==void 0)return e===null?null:e==="1"||e==="true"},q=e=>{if(e!==void 0)return e===null?null:String(e)},$=e=>{if(e===void 0)return;if(e===null)return null;const t=Number(e);return Number.isNaN(t)?null:t},Oe=e=>e?String(Math.round(e)):q(e),Me=e=>{const t=$(e);return t&&Math.round(t)},qe=(e,t=",")=>{if(e!==void 0)return e===null?"":e.join(t)},$e=(e,t=",")=>{if(e!==void 0)return e===null?[]:e?e.split(t):[]},S="1234567890",I="abcdefghijklmnopqrstuvwxyz",P="ABCDEFGHIJKLMNOPQRSTUVWXYZ",k=`${I}${P}`,H=`${k}${S}`,U=`${S}abcdef`,B=(e,t=H)=>{let n="";for(let r=0;r<e;r+=1)n+=t[Math.floor(Math.random()*t.length)];return n},Ie=(e=!0)=>{let t=B(32,U);return e&&(t=[t.substring(0,8),t.substring(8,12),t.substring(12,16),t.substring(16,20),t.substring(20)].join("-")),t},Pe=e=>/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(e),ke=e=>e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),He=(e,t)=>{if(e.length-t>0){const r=e.substring(0,Math.ceil(t/2)),s=e.substring(e.length-Math.floor(t/2),e.length);return`${r}...${s}`}return e},Ue=(e,t)=>e.length-t>0?`${e.substring(0,t)}...`:e,Be=(e,t)=>e.length-t>0?`${e.substring(0,t)}...`:e,je=e=>{const t=atob(e).split("").map(n=>`%${`00${n.charCodeAt(0).toString(16)}`.slice(-2)}`).join("");return decodeURIComponent(t)};export{k as CHARACTERS_ALPHA,H as CHARACTERS_ALPHANUMERIC,I as CHARACTERS_ALPHA_LOWERCASE,P as CHARACTERS_ALPHA_UPPERCASE,U as CHARACTERS_HEX,S as CHARACTERS_NUMERIC,C as ETHER,A as JSON_DATE_FORMAT,d as KibaException,u as KibaRequest,y as KibaResponse,ee as LocalStorageClient,Y as RequestData,X as Requester,G as RequesterModifier,Q as ResponseData,c as RestMethod,v as ServiceClient,me as addDays,he as addHours,be as arrayWithRange,te as asyncSleep,je as base64DecodeUnicode,Fe as booleanFromString,Ae as booleanToString,ke as camelCaseToKebabCase,O as copyDirectorySync,F as copyFileSync,R as createSearchParams,ue as dateFromString,pe as dateToRelativeShortString,ge as dateToRelativeString,de as dateToString,De as deepCompare,ne as downloadFileFromBrowser,we as endOfDay,g as etherToNumber,B as generateRandomString,Ie as generateUUID,Re as getChunks,ce as getClassName,z as getLinkableUrl,K as getUrlDisplayString,ye as humanFileSize,Me as integerFromString,Oe as integerToString,T as isBrowser,re as isDocumentVisible,se as isMobile,p as isSameDay,le as isToday,Pe as isValidEmail,fe as isYesterday,ae as longFormatEther,E as longFormatNumber,Te as merge,M as mergePartial,$ as numberFromString,q as numberToString,oe as numberWithCommas,Ce as objectFromString,Ee as objectToString,J as resolveUrl,ie as shortFormatEther,D as shortFormatNumber,Se as startOfDay,$e as stringListFromString,qe as stringListToString,b as timeoutPromise,Be as truncateEnd,He as truncateMiddle,Ue as truncateStart,Z as updateQueryString};
1
+ import{addMinutes as N}from"date-fns/addMinutes";import{isValid as L}from"date-fns/isValid";import{parse as V}from"date-fns/parse";import{parseISO as W}from"date-fns/parseISO";import{format as _}from"date-fns-tz";import a from"fs";import l from"path";import w from"deepmerge";import x from"fast-deep-equal";var d=class extends Error{statusCode;constructor(e,t){super(e),this.name=this.constructor.name,this.statusCode=t||500}};let c=function(e){return e.DELETE="delete",e.GET="get",e.HEAD="head",e.OPTIONS="options",e.PATCH="patch",e.POST="post",e.PUT="put",e}({});var u=class{method;url;headers;data;formData;date;timeoutSeconds;constructor(e,t,n,r,s,i,o){this.method=e,this.url=t,this.headers=n||{},this.data=r||null,this.formData=s||null,this.date=i||new Date,this.timeoutSeconds=o&&o>0?o:null}},y=class{status;headers={};date;content="";constructor(e,t,n,r){this.status=e,this.headers=t,this.date=n,this.content=r}};const b=(e,t)=>new Promise((n,r)=>{const s=setTimeout(()=>{r(new d("TIMEOUT"))},e*1e3);t.then(i=>{clearTimeout(s),n(i)},i=>{clearTimeout(s),r(i)})}),K=e=>{let t=e;for(t.startsWith("http://")&&(t=t.slice(7)),t.startsWith("https://")&&(t=t.slice(8));t.endsWith("/");)t=t.slice(0,t.length-1);return t},z=e=>{let t=e;return!t.startsWith("http://")&&!t.startsWith("https://")&&(t=`http://${t}`),t},J=e=>e.startsWith("ipfs://")?e.replace("ipfs://","https://pablo-images.kibalabs.com/v1/ipfs/"):e,R=e=>{const t=new URLSearchParams;return Object.entries(e).forEach(([n,r])=>{Array.isArray(r)?r.forEach(s=>{t.append(n,s)}):t.append(n,r)}),t},Z=(e,t)=>{const n=new URL(e);return Object.keys(t).forEach(r=>{n.searchParams.set(r,String(t[r]))}),n.toString()};var G=class{modifyRequest(e){return e}modifyResponse(e){return e}},X=class{headers;modifiers;shouldIncludeCrossSiteCredentials;constructor(e,t,n=!0){this.headers=e||{},this.modifiers=t||[],this.shouldIncludeCrossSiteCredentials=n}addModifier=e=>{this.modifiers.push(e)};modifyRequest=e=>this.modifiers.reduce((t,n)=>n.modifyRequest(t),e);modifyResponse=e=>this.modifiers.reduce((t,n)=>n.modifyResponse(t),e);getRequest=async(e,t,n,r)=>{const s=new u(c.GET,e,n,t,void 0,new Date,r);return this.makeRequestInternal(s)};postRequest=async(e,t,n,r)=>{const s=new u(c.POST,e,n,t,void 0,new Date,r);return this.makeRequestInternal(s)};putRequest=async(e,t,n,r)=>{const s=new u(c.PUT,e,n,t,void 0,new Date,r);return this.makeRequestInternal(s)};deleteRequest=async(e,t,n,r)=>{const s=new u(c.DELETE,e,n,t,void 0,new Date,r);return this.makeRequestInternal(s)};makeRequest=async(e,t,n,r,s)=>{const i=new u(e,t,r,n,void 0,new Date,s);return this.makeRequestInternal(i)};makeFormRequest=async(e,t,n,r)=>{const s=new u(c.POST,e,n,void 0,t,new Date,r);return this.makeRequestInternal(s)};makeFormPutRequest=async(e,t,n,r)=>{const s=new u(c.PUT,e,n,void 0,t,new Date,r);return this.makeRequestInternal(s)};makeRequestInternal=async e=>{const t=this.modifyRequest(e);let n=await this.makeFetchRequest(t);if(n=this.modifyResponse(n),n.status>=400&&n.status<600){let r=null;try{r=JSON.parse(n.content)}catch{}throw r&&"message"in r?new d(r.message,n.status):new d(n.content,n.status)}return n};makeFetchRequest=async e=>{const t=new URL(e.url),n=new Headers({...this.headers,...e.headers||{}}),r={method:e.method.toUpperCase(),headers:n,credentials:this.shouldIncludeCrossSiteCredentials?"include":"same-origin"};if(e.method===c.GET||e.method===c.DELETE){if(e.data){const o={...e.data};Object.keys(o).forEach(f=>{o[f]===void 0&&delete o[f]}),t.search=R(o).toString()}}else{const o=n.get("Content-Type");e.data?(r.body=JSON.stringify(e.data),o&&o!=="application/json"&&console.warn(`Overwriting content-type header for request from ${o} to application/json`),n.set("content-type","application/json")):e.formData&&(r.body=e.formData)}const s=fetch(t.toString(),r).catch(o=>{throw new d(`The request was made but no response was received: [${o.code}] "${o.message}"`)}).then(async o=>{if(!o)throw new d("The request was made but no response was received.");const f=await o.text(),m={};return o.headers.forEach((j,h)=>{m[h]&&console.warn(`key ${h} will be overwritten. TODO(krish): Implement joining keys!`),m[h]=j}),new y(o.status,m,new Date,f)});return await(e.timeoutSeconds?b(e.timeoutSeconds,s):s)}},Y=class{toObject=()=>({})},Q=class{},v=class{requester;baseUrl;constructor(e,t){this.requester=e,this.baseUrl=t}makeRequest=async(e,t,n,r)=>{const s=`${this.baseUrl}/${t}`,i=await this.requester.makeRequest(e,s,n?.toObject());return r?r.fromObject(JSON.parse(i.content)):null}},ee=class{localStorage;constructor(e){this.localStorage=e}getValue(e){return this.localStorage.getItem(e)}setValue(e,t){t==null?this.removeValue(e):this.localStorage.setItem(e,t)}getBoolean(e){const t=this.getValue(e);return t==="1"?!0:t==="0"?!1:null}setBoolean(e,t){t==null?this.removeValue(e):this.setValue(e,t?"1":"0")}removeValue(e){this.localStorage.removeItem(e)}clear(){this.localStorage.clear()}};const te=e=>new Promise(t=>{setTimeout(t,e)}),T=()=>typeof document<"u",ne=async(e,t)=>{const n=new Blob([t]),r=await URL.createObjectURL(n),s=document.createElement("a");s.href=r,s.download=e,document.body.appendChild(s),s.click(),document.body.removeChild(s)},re=()=>{if(!T())return!1;let e;return document.hidden!==void 0?e="hidden":document.msHidden!==void 0?e="msHidden":document.webkitHidden!==void 0&&(e="webkitHidden"),e?!document[e]:!0},se=()=>typeof navigator>"u"?!1:[/Android/i,/webOS/i,/iPhone/i,/iPad/i,/iPod/i,/BlackBerry/i,/Windows Phone/i].some(t=>t.test(navigator.userAgent)),oe=e=>e.toString().replace(/\B(?=(\d{3})+(?!\d))/g,","),D=e=>e>=1e9?`${(e/1e9).toFixed(0)}B`:e>=1e7?`${(e/1e6).toFixed(0)}M`:e>=1e6?`${(e/1e6).toFixed(1)}M`:e>=1e4?`${(e/1e3).toFixed(0)}K`:e>=1e3?`${(e/1e3).toFixed(1)}K`:e>100?e.toFixed(0):e>1?e.toFixed(1):e.toFixed(2),E=(e,t=2,n=!1,r=!1)=>{let s=e.toFixed(t);if(n){for(;s.charAt(s.length-1)===",";)s=s.slice(0,-1);s.endsWith(".0")&&(s=s.replace(".0",""))}if(r){const i=s.split("."),o=i[0].replace(/\B(?=(\d{3})+(?!\d))/g,",");s=i.length===1?o:`${o}.${i[1]}`}return`${s.toLocaleString()}`},C=BigInt("1000000000000000000"),g=e=>Number(e*1000000n/C)/1e6,ie=e=>`\u039E${D(g(e))}`,ae=(e,t=2,n=!1,r=!1)=>`\u039E${E(g(e),t,n,r)}`,ce=(...e)=>{const t=[];e.forEach(r=>{r&&t.push(String(r).trim().split(" "))});let n=t.reduce((r,s)=>r.concat(s),[]);return n=n.reverse(),n=Array.from(new Set(n)),n=n.reverse(),n.join(" ")},A="yyyy-MM-dd'T'HH:mm:ss.SSSXXX",ue=(e,t)=>{let n;if(!t)n=W(e);else try{n=V(e,t,new Date)}catch{}if(!n||!L(n))throw new d(`Invalid date string ${e} passed to dateFromString`);return n},de=(e,t=A,n=!1)=>{let r=e;return n&&(r=N(r,r.getTimezoneOffset())),_(r,t,n?{timeZone:"UTC"}:{})},p=(e,t)=>e.getDate()===t.getDate()&&e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear(),le=e=>p(e,new Date),fe=e=>{const t=new Date;return t.setDate(t.getDate()-1),p(e,t)},me=(e,t)=>{const n=new Date(e.getTime());return n.setTime(n.getTime()+t*60*60*1e3),n},he=(e,t)=>{const n=new Date(e.getTime());return n.setDate(n.getDate()+t),n},ge=e=>{const t=Math.floor((new Date().valueOf()-e.valueOf())/1e3);let n,r=Math.floor(t/31536e3);return r>=1?n="year":(r=Math.floor(t/2592e3),r>=1?n="month":(r=Math.floor(t/86400),r>=1?n="day":(r=Math.floor(t/3600),r>=1?n="hour":(r=Math.floor(t/60),r>=1?n="minute":(r=t,n="second"))))),(r>1||r===0)&&(n+="s"),`${r} ${n} ago`},pe=e=>{const t=Math.floor((new Date().valueOf()-e.valueOf())/1e3);let n,r=Math.floor(t/31536e3);return r>=1?n="y":(r=Math.floor(t/2592e3),r>=1?n="m":(r=Math.floor(t/86400),r>=1?n="d":(r=Math.floor(t/3600),r>=1?n="h":(r=Math.floor(t/60),r>=1?n="m":(r=t,n="s"))))),`${r}${n} ago`},Se=e=>{const t=new Date(e.getTime());return t.setHours(0,0,0,0),t},we=e=>{const t=new Date(e.getTime());return t.setHours(23,59,59,999),t},ye=(e,t=1)=>{if(e===0)return"0 B";const n=["B","KB","MB","GB","TB","PB","EB","ZB","YB"],r=Math.floor(Math.log(e)/Math.log(1024));return`${parseFloat((e/1024**r).toFixed(t<0?0:t))} ${n[r]}`},F=(e,t)=>{let n=t;a.existsSync(t)&&a.lstatSync(t).isDirectory()&&(n=l.join(t,l.basename(e)));const r=l.dirname(n);a.existsSync(r)||a.mkdirSync(r,{recursive:!0}),a.writeFileSync(n,a.readFileSync(e))},O=(e,t)=>{if(!a.lstatSync(e).isDirectory())throw new Error(`copyDirectorySync must be called with a directory. source ${e} is not a directory`);if(!a.existsSync(t))a.mkdirSync(t,{recursive:!0});else if(!a.lstatSync(e).isDirectory())throw new Error(`copyDirectorySync must be called with a directory. target ${t} is not a directory`);a.readdirSync(e).forEach(n=>{const r=l.join(e,n),s=l.join(t,n);a.lstatSync(r).isDirectory()?O(r,s):F(r,s)})},be=(e,t)=>Array(t-e).fill(null).map((n,r)=>e+r),Re=(e,t)=>e.reduce((n,r,s)=>{const i=Math.floor(s/t);return n[i]||(n[i]=[]),n[i].push(r),n},[]);function Te(e,...t){return w(e,M(...t))}function M(...e){let t={};return e.forEach(n=>{n&&(t=w(t,n))}),t}function De(e,t){return x(e,t)}const Ee=e=>{if(e!==void 0)return e===null?null:JSON.stringify(e)},Ce=e=>{if(e!==void 0)return e===null?null:JSON.parse(e)},Ae=e=>{if(e!==void 0)return e===null?null:e?"1":"0"},Fe=e=>{if(e!==void 0)return e===null?null:e==="1"||e==="true"},q=e=>{if(e!==void 0)return e===null?null:String(e)},$=e=>{if(e===void 0)return;if(e===null)return null;const t=Number(e);return Number.isNaN(t)?null:t},Oe=e=>e?String(Math.round(e)):q(e),Me=e=>{const t=$(e);return t&&Math.round(t)},qe=(e,t=",")=>{if(e!==void 0)return e===null?"":e.join(t)},$e=(e,t=",")=>{if(e!==void 0)return e===null?[]:e?e.split(t):[]},S="1234567890",I="abcdefghijklmnopqrstuvwxyz",P="ABCDEFGHIJKLMNOPQRSTUVWXYZ",k=`${I}${P}`,H=`${k}${S}`,U=`${S}abcdef`,B=(e,t=H)=>{let n="";for(let r=0;r<e;r+=1)n+=t[Math.floor(Math.random()*t.length)];return n},Ie=(e=!0)=>{let t=B(32,U);return e&&(t=[t.substring(0,8),t.substring(8,12),t.substring(12,16),t.substring(16,20),t.substring(20)].join("-")),t},Pe=e=>/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(e),ke=e=>e.replace(/([a-z0-9]|(?=[A-Z]))([A-Z])/g,"$1-$2").toLowerCase(),He=(e,t)=>{if(e.length-t>0){const r=e.substring(0,Math.ceil(t/2)),s=e.substring(e.length-Math.floor(t/2),e.length);return`${r}...${s}`}return e},Ue=(e,t)=>e.length-t>0?`${e.substring(0,t)}...`:e,Be=(e,t)=>e.length-t>0?`${e.substring(0,t)}...`:e,je=e=>{const t=atob(e).split("").map(n=>`%${`00${n.charCodeAt(0).toString(16)}`.slice(-2)}`).join("");return decodeURIComponent(t)};export{k as CHARACTERS_ALPHA,H as CHARACTERS_ALPHANUMERIC,I as CHARACTERS_ALPHA_LOWERCASE,P as CHARACTERS_ALPHA_UPPERCASE,U as CHARACTERS_HEX,S as CHARACTERS_NUMERIC,C as ETHER,A as JSON_DATE_FORMAT,d as KibaException,u as KibaRequest,y as KibaResponse,ee as LocalStorageClient,Y as RequestData,X as Requester,G as RequesterModifier,Q as ResponseData,c as RestMethod,v as ServiceClient,he as addDays,me as addHours,be as arrayWithRange,te as asyncSleep,je as base64DecodeUnicode,Fe as booleanFromString,Ae as booleanToString,ke as camelCaseToKebabCase,O as copyDirectorySync,F as copyFileSync,R as createSearchParams,ue as dateFromString,pe as dateToRelativeShortString,ge as dateToRelativeString,de as dateToString,De as deepCompare,ne as downloadFileFromBrowser,we as endOfDay,g as etherToNumber,B as generateRandomString,Ie as generateUUID,Re as getChunks,ce as getClassName,z as getLinkableUrl,K as getUrlDisplayString,ye as humanFileSize,Me as integerFromString,Oe as integerToString,T as isBrowser,re as isDocumentVisible,se as isMobile,p as isSameDay,le as isToday,Pe as isValidEmail,fe as isYesterday,ae as longFormatEther,E as longFormatNumber,Te as merge,M as mergePartial,$ as numberFromString,q as numberToString,oe as numberWithCommas,Ce as objectFromString,Ee as objectToString,J as resolveUrl,ie as shortFormatEther,D as shortFormatNumber,Se as startOfDay,$e as stringListFromString,qe as stringListToString,b as timeoutPromise,Be as truncateEnd,He as truncateMiddle,Ue as truncateStart,Z as updateQueryString};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kibalabs/core",
3
- "version": "0.6.3-next.1",
3
+ "version": "0.6.3-next.2",
4
4
  "description": "Utilities for use in front-end projects at Kiba Labs",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -9,6 +9,7 @@
9
9
  },
10
10
  "homepage": "https://github.com/kibalabs/core-js",
11
11
  "bugs": "https://github.com/kibalabs/core-js/issues",
12
+ "type": "module",
12
13
  "main": "dist/index.js",
13
14
  "types": "dist/index.d.ts",
14
15
  "sideEffects": false,
@@ -22,6 +23,6 @@
22
23
  "fast-deep-equal": "^3.1.3"
23
24
  },
24
25
  "devDependencies": {
25
- "@kibalabs/build": "0.13.3-next.0"
26
+ "@kibalabs/build": "0.13.3-next.3"
26
27
  }
27
28
  }
package/dist/index.d.ts DELETED
@@ -1,6 +0,0 @@
1
- export * from './model';
2
- export * from './requester';
3
- export * from './services';
4
- export * from './storage';
5
- export * from './util';
6
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,QAAQ,CAAC"}
@@ -1,2 +0,0 @@
1
- export * from './kibaException';
2
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/model/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC"}
@@ -1,5 +0,0 @@
1
- export declare class KibaException extends Error {
2
- statusCode: number;
3
- constructor(message: string, statusCode?: number);
4
- }
5
- //# sourceMappingURL=kibaException.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"kibaException.d.ts","sourceRoot":"","sources":["../../src/model/kibaException.ts"],"names":[],"mappings":"AACA,qBAAa,aAAc,SAAQ,KAAK;IAC/B,UAAU,EAAE,MAAM,CAAC;gBAEP,OAAO,EAAE,MAAM,EAAE,UAAU,CAAC,EAAE,MAAM;CAKxD"}
@@ -1,5 +0,0 @@
1
- export * from './restMethod';
2
- export * from './request';
3
- export * from './response';
4
- export * from './requester';
5
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/requester/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC"}
@@ -1,12 +0,0 @@
1
- import { RestMethod } from './restMethod';
2
- export declare class KibaRequest {
3
- method: RestMethod;
4
- url: string;
5
- headers: Record<string, string>;
6
- data: Record<string, unknown> | null;
7
- formData: FormData | null;
8
- date: Date;
9
- timeoutSeconds: number | null;
10
- constructor(method: RestMethod, url: string, headers?: Record<string, string>, data?: Record<string, unknown>, formData?: FormData, date?: Date, timeoutSeconds?: number);
11
- }
12
- //# sourceMappingURL=request.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"request.d.ts","sourceRoot":"","sources":["../../src/requester/request.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1C,qBAAa,WAAW;IACf,MAAM,EAAE,UAAU,CAAC;IACnB,GAAG,EAAE,MAAM,CAAC;IACZ,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,CAAC;IACrC,QAAQ,EAAE,QAAQ,GAAG,IAAI,CAAC;IAC1B,IAAI,EAAE,IAAI,CAAC;IACX,cAAc,EAAE,MAAM,GAAG,IAAI,CAAC;gBAElB,MAAM,EAAE,UAAU,EAAE,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,QAAQ,CAAC,EAAE,QAAQ,EAAE,IAAI,CAAC,EAAE,IAAI,EAAE,cAAc,CAAC,EAAE,MAAM;CAShL"}
@@ -1,26 +0,0 @@
1
- import { KibaRequest } from './request';
2
- import { KibaResponse } from './response';
3
- import { RestMethod } from './restMethod';
4
- export declare class RequesterModifier {
5
- modifyRequest(request: KibaRequest): KibaRequest;
6
- modifyResponse(response: KibaResponse): KibaResponse;
7
- }
8
- export declare class Requester {
9
- private headers;
10
- private modifiers;
11
- private shouldIncludeCrossSiteCredentials;
12
- constructor(headers?: Record<string, string>, modifiers?: RequesterModifier[], shouldIncludeCrossSiteCredentials?: boolean);
13
- addModifier: (modifier: RequesterModifier) => void;
14
- private modifyRequest;
15
- private modifyResponse;
16
- getRequest: (url: string, data?: Record<string, unknown>, headers?: Record<string, string>, timeout?: number) => Promise<KibaResponse>;
17
- postRequest: (url: string, data?: Record<string, unknown>, headers?: Record<string, string>, timeout?: number) => Promise<KibaResponse>;
18
- putRequest: (url: string, data?: Record<string, unknown>, headers?: Record<string, string>, timeout?: number) => Promise<KibaResponse>;
19
- deleteRequest: (url: string, data?: Record<string, unknown>, headers?: Record<string, string>, timeout?: number) => Promise<KibaResponse>;
20
- makeRequest: (method: RestMethod, url: string, data?: Record<string, unknown>, headers?: Record<string, string>, timeout?: number) => Promise<KibaResponse>;
21
- makeFormRequest: (url: string, data?: FormData, headers?: Record<string, string>, timeout?: number) => Promise<KibaResponse>;
22
- makeFormPutRequest: (url: string, data?: FormData, headers?: Record<string, string>, timeout?: number) => Promise<KibaResponse>;
23
- private makeRequestInternal;
24
- private makeFetchRequest;
25
- }
26
- //# sourceMappingURL=requester.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"requester.d.ts","sourceRoot":"","sources":["../../src/requester/requester.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAK1C,qBAAa,iBAAiB;IAErB,aAAa,CAAC,OAAO,EAAE,WAAW,GAAG,WAAW;IAKhD,cAAc,CAAC,QAAQ,EAAE,YAAY,GAAG,YAAY;CAG5D;AAED,qBAAa,SAAS;IACpB,OAAO,CAAC,OAAO,CAAyB;IACxC,OAAO,CAAC,SAAS,CAAsB;IACvC,OAAO,CAAC,iCAAiC,CAAU;gBAEhC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,SAAS,CAAC,EAAE,iBAAiB,EAAE,EAAE,iCAAiC,UAAO;IAMvH,WAAW,aAAc,iBAAiB,KAAG,IAAI,CAEtD;IAEF,OAAO,CAAC,aAAa,CAInB;IAEF,OAAO,CAAC,cAAc,CAIpB;IAEK,UAAU,QAAe,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,YAAY,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,YAAY,MAAM,KAAG,OAAO,CAAC,YAAY,CAAC,CAGhJ;IAEK,WAAW,QAAe,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,YAAY,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,YAAY,MAAM,KAAG,OAAO,CAAC,YAAY,CAAC,CAGjJ;IAEK,UAAU,QAAe,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,YAAY,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,YAAY,MAAM,KAAG,OAAO,CAAC,YAAY,CAAC,CAGhJ;IAEK,aAAa,QAAe,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,YAAY,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,YAAY,MAAM,KAAG,OAAO,CAAC,YAAY,CAAC,CAGnJ;IAEK,WAAW,WAAkB,UAAU,OAAO,MAAM,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,YAAY,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,YAAY,MAAM,KAAG,OAAO,CAAC,YAAY,CAAC,CAGrK;IAEK,eAAe,QAAe,MAAM,SAAS,QAAQ,YAAY,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,YAAY,MAAM,KAAG,OAAO,CAAC,YAAY,CAAC,CAGtI;IAEK,kBAAkB,QAAe,MAAM,SAAS,QAAQ,YAAY,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,YAAY,MAAM,KAAG,OAAO,CAAC,YAAY,CAAC,CAGzI;IAEF,OAAO,CAAC,mBAAmB,CAiBzB;IAEF,OAAO,CAAC,gBAAgB,CAyDtB;CACH"}
@@ -1,8 +0,0 @@
1
- export declare class KibaResponse {
2
- status: number;
3
- headers: Record<string, string>;
4
- date: Date;
5
- content: string;
6
- constructor(status: number, headers: Record<string, string>, date: Date, content: string);
7
- }
8
- //# sourceMappingURL=response.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"response.d.ts","sourceRoot":"","sources":["../../src/requester/response.ts"],"names":[],"mappings":"AAAA,qBAAa,YAAY;IAChB,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAM;IACrC,IAAI,EAAE,IAAI,CAAC;IACX,OAAO,SAAM;gBAED,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM;CAMhG"}
@@ -1,10 +0,0 @@
1
- export declare enum RestMethod {
2
- DELETE = "delete",
3
- GET = "get",
4
- HEAD = "head",
5
- OPTIONS = "options",
6
- PATCH = "patch",
7
- POST = "post",
8
- PUT = "put"
9
- }
10
- //# sourceMappingURL=restMethod.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"restMethod.d.ts","sourceRoot":"","sources":["../../src/requester/restMethod.ts"],"names":[],"mappings":"AACA,oBAAY,UAAU;IACpB,MAAM,WAAW;IACjB,GAAG,QAAQ;IACX,IAAI,SAAS;IACb,OAAO,YAAY;IACnB,KAAK,UAAU;IACf,IAAI,SAAS;IACb,GAAG,QAAQ;CACZ"}
@@ -1,2 +0,0 @@
1
- export * from './serviceClient';
2
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/services/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC"}
@@ -1,15 +0,0 @@
1
- import { Requester, RestMethod } from '../requester';
2
- export declare class RequestData {
3
- toObject: () => Record<string, unknown>;
4
- }
5
- export declare class ResponseData {
6
- }
7
- type Constructor<T = Record<string, unknown>> = new (...args: any[]) => T;
8
- export declare class ServiceClient {
9
- protected requester: Requester;
10
- baseUrl: string;
11
- constructor(requester: Requester, baseUrl: string);
12
- protected makeRequest: <ResponseType extends ResponseData>(method: RestMethod, path: string, request?: RequestData | undefined, responseClass?: Constructor<ResponseType> | undefined) => Promise<ResponseType>;
13
- }
14
- export {};
15
- //# sourceMappingURL=serviceClient.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"serviceClient.d.ts","sourceRoot":"","sources":["../../src/services/serviceClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAGrD,qBAAa,WAAW;IAEf,QAAQ,QAAO,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAE3C;CACH;AAGD,qBAAa,YAAY;CAIxB;AAGD,KAAK,WAAW,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI,KAAK,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;AAE1E,qBAAa,aAAa;IACxB,SAAS,CAAC,SAAS,EAAE,SAAS,CAAC;IACxB,OAAO,EAAE,MAAM,CAAC;gBAEJ,SAAS,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM;IAKxD,SAAS,CAAC,WAAW,GAAU,YAAY,SAAS,YAAY,UAAU,UAAU,QAAQ,MAAM,YAAY,WAAW,GAAG,SAAS,kBAAkB,WAAW,CAAC,YAAY,CAAC,GAAG,SAAS,KAAG,OAAO,CAAC,YAAY,CAAC,CAKlN;CACH"}
@@ -1,2 +0,0 @@
1
- export * from './localStorageClient';
2
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/storage/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC"}
@@ -1,11 +0,0 @@
1
- export declare class LocalStorageClient {
2
- private localStorage;
3
- constructor(localStorage: Storage);
4
- getValue(key: string): string | null;
5
- setValue(key: string, value: string | null | undefined): void;
6
- getBoolean(key: string): boolean | null;
7
- setBoolean(key: string, value: boolean | null | undefined): void;
8
- removeValue(key: string): void;
9
- clear(): void;
10
- }
11
- //# sourceMappingURL=localStorageClient.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"localStorageClient.d.ts","sourceRoot":"","sources":["../../src/storage/localStorageClient.ts"],"names":[],"mappings":"AACA,qBAAa,kBAAkB;IAC7B,OAAO,CAAC,YAAY,CAAU;gBAElB,YAAY,EAAE,OAAO;IAI1B,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI;IAIpC,QAAQ,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAAG,IAAI;IAQ7D,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,GAAG,IAAI;IAWvC,UAAU,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,GAAG,IAAI,GAAG,SAAS,GAAG,IAAI;IAQhE,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI;IAI9B,KAAK,IAAI,IAAI;CAGrB"}
@@ -1,2 +0,0 @@
1
- export declare const asyncSleep: (sleepTime: number) => Promise<void>;
2
- //# sourceMappingURL=asyncUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"asyncUtil.d.ts","sourceRoot":"","sources":["../../src/util/asyncUtil.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,UAAU,cAAe,MAAM,KAAG,OAAO,CAAC,IAAI,CAI1D,CAAC"}
@@ -1,5 +0,0 @@
1
- export declare const isBrowser: () => boolean;
2
- export declare const downloadFileFromBrowser: (filename: string, content: string) => Promise<void>;
3
- export declare const isDocumentVisible: () => boolean;
4
- export declare const isMobile: () => boolean;
5
- //# sourceMappingURL=browserUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"browserUtil.d.ts","sourceRoot":"","sources":["../../src/util/browserUtil.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,QAAO,OAE5B,CAAC;AAEF,eAAO,MAAM,uBAAuB,aAAoB,MAAM,WAAW,MAAM,KAAG,OAAO,CAAC,IAAI,CAS7F,CAAC;AAGF,eAAO,MAAM,iBAAiB,QAAO,OAiBpC,CAAC;AAEF,eAAO,MAAM,QAAQ,QAAO,OAgB3B,CAAC"}
@@ -1,5 +0,0 @@
1
- export declare const ETHER: bigint;
2
- export declare const etherToNumber: (value: bigint) => number;
3
- export declare const shortFormatEther: (value: bigint) => string;
4
- export declare const longFormatEther: (value: bigint, fractionDigits?: number, shouldRemoveTrailingDecimals?: boolean, shouldAddCommas?: boolean) => string;
5
- //# sourceMappingURL=chainUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"chainUtil.d.ts","sourceRoot":"","sources":["../../src/util/chainUtil.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,KAAK,QAAgC,CAAC;AAEnD,eAAO,MAAM,aAAa,UAAW,MAAM,KAAG,MAE7C,CAAC;AAEF,eAAO,MAAM,gBAAgB,UAAW,MAAM,KAAG,MAGhD,CAAC;AAEF,eAAO,MAAM,eAAe,UAAW,MAAM,iGAAsF,MAGlI,CAAC"}
@@ -1,4 +0,0 @@
1
- type ArgType = string | number | boolean | null | undefined;
2
- export declare const getClassName: (...args: ArgType[]) => string;
3
- export {};
4
- //# sourceMappingURL=classNameUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"classNameUtil.d.ts","sourceRoot":"","sources":["../../src/util/classNameUtil.ts"],"names":[],"mappings":"AACA,KAAK,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,GAAG,SAAS,CAAC;AAG5D,eAAO,MAAM,YAAY,YAAa,OAAO,EAAE,KAAG,MAYjD,CAAC"}
@@ -1,13 +0,0 @@
1
- export declare const JSON_DATE_FORMAT = "yyyy-MM-dd'T'HH:mm:ss.SSSXXX";
2
- export declare const dateFromString: (dateString: string, formatString?: string) => Date;
3
- export declare const dateToString: (date: Date, formatString?: string, convertToUtc?: boolean) => string;
4
- export declare const isSameDay: (date1: Date, date2: Date) => boolean;
5
- export declare const isToday: (date: Date) => boolean;
6
- export declare const isYesterday: (date: Date) => boolean;
7
- export declare const addHours: (date: Date, hours: number) => Date;
8
- export declare const addDays: (date: Date, days: number) => Date;
9
- export declare const dateToRelativeString: (date: Date) => string;
10
- export declare const dateToRelativeShortString: (date: Date) => string;
11
- export declare const startOfDay: (date: Date) => Date;
12
- export declare const endOfDay: (date: Date) => Date;
13
- //# sourceMappingURL=dateUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"dateUtil.d.ts","sourceRoot":"","sources":["../../src/util/dateUtil.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,gBAAgB,iCAAmC,CAAC;AAEjE,eAAO,MAAM,cAAc,eAAgB,MAAM,iBAAiB,MAAM,KAAG,IAe1E,CAAC;AAGF,eAAO,MAAM,YAAY,SAAU,IAAI,iBAAgB,MAAM,6BAA4C,MAOxG,CAAC;AAEF,eAAO,MAAM,SAAS,UAAW,IAAI,SAAS,IAAI,KAAG,OAEpD,CAAC;AAEF,eAAO,MAAM,OAAO,SAAU,IAAI,KAAG,OAEpC,CAAC;AAEF,eAAO,MAAM,WAAW,SAAU,IAAI,KAAG,OAIxC,CAAC;AAEF,eAAO,MAAM,QAAQ,SAAU,IAAI,SAAS,MAAM,KAAG,IAIpD,CAAC;AAEF,eAAO,MAAM,OAAO,SAAU,IAAI,QAAQ,MAAM,KAAG,IAIlD,CAAC;AAEF,eAAO,MAAM,oBAAoB,SAAU,IAAI,KAAG,MAmCjD,CAAC;AAEF,eAAO,MAAM,yBAAyB,SAAU,IAAI,KAAG,MAgCtD,CAAC;AAEF,eAAO,MAAM,UAAU,SAAU,IAAI,KAAG,IAIvC,CAAC;AAEF,eAAO,MAAM,QAAQ,SAAU,IAAI,KAAG,IAIrC,CAAC"}
@@ -1,4 +0,0 @@
1
- export declare const humanFileSize: (size: number, decimals?: number) => string;
2
- export declare const copyFileSync: (sourceFilePath: string, targetPath: string) => void;
3
- export declare const copyDirectorySync: (sourceDirectory: string, targetDirectory: string) => void;
4
- //# sourceMappingURL=fileUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"fileUtil.d.ts","sourceRoot":"","sources":["../../src/util/fileUtil.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,aAAa,SAAU,MAAM,wBAAiB,MAQ1D,CAAC;AAEF,eAAO,MAAM,YAAY,mBAAoB,MAAM,cAAc,MAAM,KAAG,IAUzE,CAAC;AAEF,eAAO,MAAM,iBAAiB,oBAAqB,MAAM,mBAAmB,MAAM,KAAG,IAkBpF,CAAC"}
@@ -1,15 +0,0 @@
1
- export * from './asyncUtil';
2
- export * from './browserUtil';
3
- export * from './chainUtil';
4
- export * from './classNameUtil';
5
- export * from './dateUtil';
6
- export * from './fileUtil';
7
- export * from './listUtil';
8
- export * from './numberUtil';
9
- export * from './objectUtil';
10
- export * from './promiseUtil';
11
- export * from './serializationUtil';
12
- export * from './stringUtil';
13
- export * from './typeUtil';
14
- export * from './urlUtils';
15
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/util/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAC5B,cAAc,iBAAiB,CAAC;AAChC,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,qBAAqB,CAAC;AACpC,cAAc,cAAc,CAAC;AAC7B,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC"}
@@ -1,3 +0,0 @@
1
- export declare const arrayWithRange: (start: number, end: number) => number[];
2
- export declare const getChunks: <T>(arr: T[], chunkSize: number) => T[][];
3
- //# sourceMappingURL=listUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"listUtil.d.ts","sourceRoot":"","sources":["../../src/util/listUtil.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,cAAc,UAAW,MAAM,OAAO,MAAM,KAAG,MAAM,EAEjE,CAAC;AAEF,eAAO,MAAM,SAAS,GAAI,CAAC,OAAO,CAAC,EAAE,aAAa,MAAM,KAAG,CAAC,EAAE,EAS7D,CAAC"}
@@ -1,4 +0,0 @@
1
- export declare const numberWithCommas: (value: number) => string;
2
- export declare const shortFormatNumber: (value: number) => string;
3
- export declare const longFormatNumber: (value: number, fractionDigits?: number, shouldRemoveTrailingDecimals?: boolean, shouldAddCommas?: boolean) => string;
4
- //# sourceMappingURL=numberUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"numberUtil.d.ts","sourceRoot":"","sources":["../../src/util/numberUtil.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,gBAAgB,UAAW,MAAM,KAAG,MAEhD,CAAC;AAEF,eAAO,MAAM,iBAAiB,UAAW,MAAM,KAAG,MAuBjD,CAAC;AAEF,eAAO,MAAM,gBAAgB,UAAW,MAAM,iGAAsF,MAgBnI,CAAC"}
@@ -1,5 +0,0 @@
1
- import { RecursivePartial } from './typeUtil';
2
- export declare function merge<T>(base: T, ...partials: (RecursivePartial<T> | undefined)[]): T;
3
- export declare function mergePartial<T>(...partials: (RecursivePartial<T> | undefined)[]): RecursivePartial<T>;
4
- export declare function deepCompare<T>(object1: T, object2: T): boolean;
5
- //# sourceMappingURL=objectUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"objectUtil.d.ts","sourceRoot":"","sources":["../../src/util/objectUtil.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAE9C,wBAAgB,KAAK,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,GAAG,QAAQ,EAAE,CAAC,gBAAgB,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC,EAAE,GAAG,CAAC,CAGrF;AAED,wBAAgB,YAAY,CAAC,CAAC,EAAE,GAAG,QAAQ,EAAE,CAAC,gBAAgB,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC,EAAE,GAAG,gBAAgB,CAAC,CAAC,CAAC,CAUrG;AAED,wBAAgB,WAAW,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,GAAG,OAAO,CAE9D"}
@@ -1,2 +0,0 @@
1
- export declare const timeoutPromise: <T>(timeoutSeconds: number, promise: Promise<T>) => Promise<T>;
2
- //# sourceMappingURL=promiseUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"promiseUtil.d.ts","sourceRoot":"","sources":["../../src/util/promiseUtil.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,cAAc,GAAI,CAAC,kBAAkB,MAAM,WAAW,OAAO,CAAC,CAAC,CAAC,KAAG,OAAO,CAAC,CAAC,CAgBxF,CAAC"}
@@ -1,11 +0,0 @@
1
- export declare const objectToString: (value: Record<string, unknown> | null | undefined) => string | null | undefined;
2
- export declare const objectFromString: (value: string | null | undefined) => Record<string, unknown> | null | undefined;
3
- export declare const booleanToString: (value: boolean | null | undefined) => string | null | undefined;
4
- export declare const booleanFromString: (value: string | null | undefined) => boolean | null | undefined;
5
- export declare const numberToString: (value: number | null | undefined) => string | null | undefined;
6
- export declare const numberFromString: (value: string | null | undefined) => number | null | undefined;
7
- export declare const integerToString: (value: number | null | undefined) => string | null | undefined;
8
- export declare const integerFromString: (value: string | null | undefined) => number | null | undefined;
9
- export declare const stringListToString: (value: string[] | null | undefined, delimiter?: string) => string | undefined;
10
- export declare const stringListFromString: (value: string | null | undefined, delimiter?: string) => string[] | undefined;
11
- //# sourceMappingURL=serializationUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"serializationUtil.d.ts","sourceRoot":"","sources":["../../src/util/serializationUtil.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,cAAc,UAAW,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,KAAG,MAAM,GAAG,IAAI,GAAG,SAQlG,CAAC;AAEF,eAAO,MAAM,gBAAgB,UAAW,MAAM,GAAG,IAAI,GAAG,SAAS,KAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAQpG,CAAC;AAEF,eAAO,MAAM,eAAe,UAAW,OAAO,GAAG,IAAI,GAAG,SAAS,KAAG,MAAM,GAAG,IAAI,GAAG,SAQnF,CAAC;AAEF,eAAO,MAAM,iBAAiB,UAAW,MAAM,GAAG,IAAI,GAAG,SAAS,KAAG,OAAO,GAAG,IAAI,GAAG,SAQrF,CAAC;AAEF,eAAO,MAAM,cAAc,UAAW,MAAM,GAAG,IAAI,GAAG,SAAS,KAAG,MAAM,GAAG,IAAI,GAAG,SAQjF,CAAC;AAEF,eAAO,MAAM,gBAAgB,UAAW,MAAM,GAAG,IAAI,GAAG,SAAS,KAAG,MAAM,GAAG,IAAI,GAAG,SASnF,CAAC;AAEF,eAAO,MAAM,eAAe,UAAW,MAAM,GAAG,IAAI,GAAG,SAAS,KAAG,MAAM,GAAG,IAAI,GAAG,SAElF,CAAC;AAEF,eAAO,MAAM,iBAAiB,UAAW,MAAM,GAAG,IAAI,GAAG,SAAS,KAAG,MAAM,GAAG,IAAI,GAAG,SAGpF,CAAC;AAEF,eAAO,MAAM,kBAAkB,UAAW,MAAM,EAAE,GAAG,IAAI,GAAG,SAAS,yBAAoB,MAAM,GAAG,SAQjG,CAAC;AAEF,eAAO,MAAM,oBAAoB,UAAW,MAAM,GAAG,IAAI,GAAG,SAAS,yBAAoB,MAAM,EAAE,GAAG,SAQnG,CAAC"}
@@ -1,15 +0,0 @@
1
- export declare const CHARACTERS_NUMERIC = "1234567890";
2
- export declare const CHARACTERS_ALPHA_LOWERCASE = "abcdefghijklmnopqrstuvwxyz";
3
- export declare const CHARACTERS_ALPHA_UPPERCASE = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
4
- export declare const CHARACTERS_ALPHA = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
5
- export declare const CHARACTERS_ALPHANUMERIC = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890";
6
- export declare const CHARACTERS_HEX = "1234567890abcdef";
7
- export declare const generateRandomString: (length: number, characters?: string) => string;
8
- export declare const generateUUID: (shouldIncludeDashes?: boolean) => string;
9
- export declare const isValidEmail: (email: string) => boolean;
10
- export declare const camelCaseToKebabCase: (value: string) => string;
11
- export declare const truncateMiddle: (text: string, maxLength: number) => string;
12
- export declare const truncateStart: (text: string, maxLength: number) => string;
13
- export declare const truncateEnd: (text: string, maxLength: number) => string;
14
- export declare const base64DecodeUnicode: (input: string) => string;
15
- //# sourceMappingURL=stringUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"stringUtil.d.ts","sourceRoot":"","sources":["../../src/util/stringUtil.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,kBAAkB,eAAe,CAAC;AAC/C,eAAO,MAAM,0BAA0B,+BAA+B,CAAC;AACvE,eAAO,MAAM,0BAA0B,+BAA+B,CAAC;AACvE,eAAO,MAAM,gBAAgB,yDAA+D,CAAC;AAC7F,eAAO,MAAM,uBAAuB,mEAA6C,CAAC;AAClF,eAAO,MAAM,cAAc,qBAAgC,CAAC;AAE5D,eAAO,MAAM,oBAAoB,WAAY,MAAM,eAAc,MAAM,KAA6B,MAMnG,CAAC;AAEF,eAAO,MAAM,YAAY,qCAAiC,MAYzD,CAAC;AAEF,eAAO,MAAM,YAAY,UAAW,MAAM,KAAG,OAG5C,CAAC;AAEF,eAAO,MAAM,oBAAoB,UAAW,MAAM,KAAG,MAEpD,CAAC;AAEF,eAAO,MAAM,cAAc,SAAU,MAAM,aAAa,MAAM,KAAG,MAQhE,CAAC;AAEF,eAAO,MAAM,aAAa,SAAU,MAAM,aAAa,MAAM,KAAG,MAO/D,CAAC;AAGF,eAAO,MAAM,WAAW,SAAU,MAAM,aAAa,MAAM,KAAG,MAO7D,CAAC;AAGF,eAAO,MAAM,mBAAmB,UAAW,MAAM,KAAG,MAMnD,CAAC"}
@@ -1,4 +0,0 @@
1
- export type RecursivePartial<T> = {
2
- [P in keyof T]?: T[P] extends (infer U)[] ? RecursivePartial<U>[] : T[P] extends (Record<string, unknown> | undefined) ? RecursivePartial<T[P]> : T[P];
3
- };
4
- //# sourceMappingURL=typeUtil.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"typeUtil.d.ts","sourceRoot":"","sources":["../../src/util/typeUtil.ts"],"names":[],"mappings":"AACA,MAAM,MAAM,gBAAgB,CAAC,CAAC,IAAI;KAC/B,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,EAAE,GAAG,gBAAgB,CAAC,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,CAAC,GAAG,gBAAgB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CACvJ,CAAC"}
@@ -1,8 +0,0 @@
1
- export declare const getUrlDisplayString: (url: string) => string;
2
- export declare const getLinkableUrl: (url: string) => string;
3
- export declare const resolveUrl: (url: string) => string;
4
- export declare const createSearchParams: (params: {
5
- [key: string]: string | string[];
6
- }) => URLSearchParams;
7
- export declare const updateQueryString: (url: string, values: Record<string, string | number | boolean>) => string;
8
- //# sourceMappingURL=urlUtils.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"urlUtils.d.ts","sourceRoot":"","sources":["../../src/util/urlUtils.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,mBAAmB,QAAS,MAAM,KAAG,MAYjD,CAAC;AAEF,eAAO,MAAM,cAAc,QAAS,MAAM,KAAG,MAM5C,CAAC;AAEF,eAAO,MAAM,UAAU,QAAS,MAAM,KAAG,MAExC,CAAC;AAEF,eAAO,MAAM,kBAAkB,WAAY;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,EAAE,CAAA;CAAE,KAAG,eAYjF,CAAC;AAEF,eAAO,MAAM,iBAAiB,QAAS,MAAM,UAAU,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC,KAAG,MAMlG,CAAC"}