From 557e378e1de507634674181fd430350f0496e658 Mon Sep 17 00:00:00 2001 From: kabeep Date: Wed, 11 Dec 2024 12:44:40 +0800 Subject: [PATCH] docs: version 1.0.0 --- docs/.nojekyll | 1 + docs/assets/app.js | 117 ++ docs/assets/app.js.map | 1 + docs/assets/demo-style.css | 184 ++ docs/assets/highlight.css | 85 + docs/assets/icons.js | 18 + docs/assets/icons.svg | 1 + docs/assets/main.js | 60 + docs/assets/material-style.css | 335 ++++ docs/assets/navigation.js | 1 + docs/assets/search.js | 1 + docs/assets/style.css | 1493 +++++++++++++++++ docs/classes/index.ForexClient.html | 237 +++ docs/classes/index._internal_.HttpClient.html | 180 ++ .../classes/index._internal_.HttpRequest.html | 179 ++ docs/documents/____.html | 581 +++++++ docs/documents/demo.html | 86 + docs/hierarchy.html | 175 ++ docs/index.html | 581 +++++++ docs/interfaces/index.AvailableCurrency.html | 177 ++ docs/interfaces/index.ExchangeRate.html | 177 ++ docs/interfaces/index.ForexClientOptions.html | 179 ++ docs/interfaces/index.HttpRequestOptions.html | 177 ++ docs/interfaces/index.HttpResponse.html | 178 ++ docs/modules.html | 177 ++ docs/modules/index._internal_.html | 180 ++ docs/modules/index.html | 187 +++ docs/types/index.OriginalExchangeRates.html | 175 ++ docs/types/index._internal_.HeadersInit.html | 175 ++ docs/types/index._internal_.Pick.html | 176 ++ docs/types/index._internal_.Record.html | 176 ++ docs/variables/index.BASE_URL.html | 179 ++ docs/variables/index.BASE_URL_VERSION.html | 179 ++ docs/variables/index.LOCALE_CURRENCY.html | 179 ++ docs/variables/index.NON_STANDARD_CODES.html | 179 ++ 35 files changed, 7166 insertions(+) create mode 100644 docs/.nojekyll create mode 100644 docs/assets/app.js create mode 100644 docs/assets/app.js.map create mode 100644 docs/assets/demo-style.css create mode 100644 docs/assets/highlight.css create mode 100644 docs/assets/icons.js create mode 100644 docs/assets/icons.svg create mode 100644 docs/assets/main.js create mode 100644 docs/assets/material-style.css create mode 100644 docs/assets/navigation.js create mode 100644 docs/assets/search.js create mode 100644 docs/assets/style.css create mode 100644 docs/classes/index.ForexClient.html create mode 100644 docs/classes/index._internal_.HttpClient.html create mode 100644 docs/classes/index._internal_.HttpRequest.html create mode 100644 docs/documents/____.html create mode 100644 docs/documents/demo.html create mode 100644 docs/hierarchy.html create mode 100644 docs/index.html create mode 100644 docs/interfaces/index.AvailableCurrency.html create mode 100644 docs/interfaces/index.ExchangeRate.html create mode 100644 docs/interfaces/index.ForexClientOptions.html create mode 100644 docs/interfaces/index.HttpRequestOptions.html create mode 100644 docs/interfaces/index.HttpResponse.html create mode 100644 docs/modules.html create mode 100644 docs/modules/index._internal_.html create mode 100644 docs/modules/index.html create mode 100644 docs/types/index.OriginalExchangeRates.html create mode 100644 docs/types/index._internal_.HeadersInit.html create mode 100644 docs/types/index._internal_.Pick.html create mode 100644 docs/types/index._internal_.Record.html create mode 100644 docs/variables/index.BASE_URL.html create mode 100644 docs/variables/index.BASE_URL_VERSION.html create mode 100644 docs/variables/index.LOCALE_CURRENCY.html create mode 100644 docs/variables/index.NON_STANDARD_CODES.html diff --git a/docs/.nojekyll b/docs/.nojekyll new file mode 100644 index 0000000..e2ac661 --- /dev/null +++ b/docs/.nojekyll @@ -0,0 +1 @@ +TypeDoc added this file to prevent GitHub Pages from using Jekyll. You can turn off this behavior by setting the `githubPages` option to false. \ No newline at end of file diff --git a/docs/assets/app.js b/docs/assets/app.js new file mode 100644 index 0000000..15984b2 --- /dev/null +++ b/docs/assets/app.js @@ -0,0 +1,117 @@ +(function(){'use strict';var Ce=Object.defineProperty,Ee=Object.defineProperties;var fe=Object.getOwnPropertyDescriptors;var y=Object.getOwnPropertySymbols;var X=Object.prototype.hasOwnProperty,Z=Object.prototype.propertyIsEnumerable;var T=(n,e,t)=>e in n?Ce(n,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):n[e]=t,h=(n,e)=>{for(var t in e||(e={}))X.call(e,t)&&T(n,t,e[t]);if(y)for(var t of y(e))Z.call(e,t)&&T(n,t,e[t]);return n},E=(n,e)=>Ee(n,fe(e));var D=(n,e)=>{var t={};for(var r in n)X.call(n,r)&&e.indexOf(r)<0&&(t[r]=n[r]);if(n!=null&&y)for(var r of y(n))e.indexOf(r)<0&&Z.call(n,r)&&(t[r]=n[r]);return t};var d=(n,e)=>()=>(n&&(e=n(n=0)),e);var ge=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports);var m=(n,e,t)=>T(n,typeof e!="symbol"?e+"":e,t);var p=(n,e,t)=>new Promise((r,s)=>{var o=i=>{try{c(t.next(i));}catch(u){s(u);}},a=i=>{try{c(t.throw(i));}catch(u){s(u);}},c=i=>i.done?r(i.value):Promise.resolve(i.value).then(o,a);c((t=t.apply(n,e)).next());});var S,f,N,M,L,Y=d(()=>{S=class S extends HTMLElement{constructor({href:e,classname:t}={}){super();let r=this.attachShadow({mode:"open"});r.adoptedStyleSheets=[S.styles];let s=this.createAnchorElement(e,t),o=this.createSlotElement();s.appendChild(o),r.appendChild(s);}createAnchorElement(e,t){let r=document.createElement("a");return r.setAttribute("class",["icon",...t||this.classList].join(" ")),r.setAttribute("href",e||this.getAttribute("href")||"#"),r}createSlotElement(){return document.createElement("slot")}createSvgElement({viewBox:e,children:t=[]}){let r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("viewBox",e),r.setAttribute("width","1em"),r.setAttribute("height","1em");for(let s of t)r.appendChild(this.createSvgChildElement(s));return r}createSvgChildElement(r){var s=r,{tag:e}=s,t=D(s,["tag"]);let o=document.createElementNS("http://www.w3.org/2000/svg",e);t.fill||(t.fill="currentColor");for(let a in t)o.setAttribute(a,t[a]);return o}};m(S,"styles",new CSSStyleSheet),S.styles.replaceSync(` + :host { + display: inline-flex; + font-size: var(--navbar-icon-font-size, 1rem); + color: var(--anchor-link-color, currentColor); + text-decoration: none; + outline: none; + cursor: pointer; + } + :host(:hover) { + color: var(--anchor-link-hover-color, currentColor); + } + a { + display: inline-flex; + align-items: center; + flex-direction: row; + color: inherit; + text-decoration: none; + outline: none; + transition: var(--transition-duration) var(--transition-bezier); + } + .icon { font-size: var(--navbar-icon-font-size); } + .icon.icon-npm:hover { color: #cd3f45; } + .icon.icon-github:hover { color: #000; } + .icon.icon-switch { font-size: 2rem; } + .icon.icon-switch:hover { color: #6600eb; } + .user-selected-none { + user-select: none; + -ms-user-select: none; + -moz-user-select: none; + -webkit-user-select: none; + } + `);f=S,N=class extends f{constructor(){super({classname:["icon-github"]}),this.appendChild(this.createSvgElement({viewBox:"0 0 24 24",children:[{tag:"path",d:"M12.5.75C6.146.75 1 5.896 1 12.25c0 5.089 3.292 9.387 7.863 10.91.575.101.79-.244.79-.546 0-.273-.014-1.178-.014-2.142-2.889.532-3.636-.704-3.866-1.35-.13-.331-.69-1.352-1.18-1.625-.402-.216-.977-.748-.014-.762.906-.014 1.553.834 1.769 1.179 1.035 1.74 2.688 1.25 3.349.948.1-.747.402-1.25.733-1.538-2.559-.287-5.232-1.279-5.232-5.678 0-1.25.445-2.285 1.178-3.09-.115-.288-.517-1.467.115-3.048 0 0 .963-.302 3.163 1.179.92-.259 1.897-.388 2.875-.388.977 0 1.955.13 2.875.388 2.2-1.495 3.162-1.179 3.162-1.179.633 1.581.23 2.76.115 3.048.733.805 1.179 1.825 1.179 3.09 0 4.413-2.688 5.39-5.247 5.678.417.36.776 1.05.776 2.128 0 1.538-.014 2.774-.014 3.162 0 .302.216.662.79.547C20.709 21.637 24 17.324 24 12.25 24 5.896 18.854.75 12.5.75Z"}]}));}},M=class extends f{constructor(){super({classname:["icon-npm"]}),this.appendChild(this.createSvgElement({viewBox:"0 0 27.23 27.23",children:[{tag:"rect",width:"27.23",height:"27.23",rx:"2"},{tag:"polygon",fill:"#fff",points:"5.8 21.75 13.66 21.75 13.67 9.98 17.59 9.98 17.58 21.76 21.51 21.76 21.52 6.06 5.82 6.04 5.8 21.75"}]}));}},L=class extends f{constructor(){super({classname:["icon-switch"]}),this.appendChild(this.createSvgElement({viewBox:"0 0 1024 1024",children:[{tag:"path",d:"M677.888 335.872l-176.128 0c-2.048 0-2.048 0-2.048-2.048 0-2.048 0-2.048 0-2.048l43.008-43.008c8.192-8.192 8.192-20.48 0-28.672-8.192-8.192-20.48-8.192-28.672 0l-81.92 81.92c-6.144 6.144-8.192 14.336-4.096 22.528 4.096 8.192 10.24 12.288 18.432 12.288l233.472 0c57.344 0 106.496 47.104 108.544 102.4 2.048 53.248-36.864 100.352-90.112 108.544-10.24 2.048-18.432 10.24-18.432 20.48 0 6.144 2.048 12.288 8.192 16.384 4.096 4.096 8.192 4.096 14.336 4.096 0 0 2.048 0 2.048 0 73.728-10.24 126.976-75.776 124.928-149.504C827.392 401.408 759.808 335.872 677.888 335.872z"},{tag:"path",d:"M598.016 598.016 364.544 598.016c-57.344 0-106.496-47.104-108.544-102.4-2.048-53.248 36.864-100.352 90.112-108.544 10.24-2.048 18.432-10.24 18.432-20.48 0-6.144-2.048-12.288-8.192-16.384-4.096-4.096-10.24-6.144-16.384-4.096-73.728 10.24-126.976 75.776-124.928 149.504 2.048 79.872 69.632 143.36 149.504 143.36l176.128 0c2.048 0 2.048 0 2.048 2.048 0 2.048 0 2.048 0 2.048l-43.008 43.008c-4.096 4.096-6.144 8.192-6.144 14.336 0 6.144 2.048 10.24 6.144 14.336 4.096 4.096 10.24 6.144 14.336 6.144 6.144 0 10.24-2.048 14.336-6.144l81.92-81.92c6.144-6.144 8.192-14.336 4.096-22.528C614.4 602.112 606.208 598.016 598.016 598.016z"}]}));}};customElements.define("base-icon",f);customElements.define("github-icon",N);customElements.define("npm-icon",M);customElements.define("switch-icon",L);});var A,w,W=d(()=>{A=class A extends HTMLElement{constructor(){super();let e=this.attachShadow({mode:"open"});e.adoptedStyleSheets=[A.styles];let t=this.createContainerElement();if(this.getAttribute("label")){let s=this.createLabelElement();t.appendChild(s);}this.input=this.createInputElement(),t.appendChild(this.input);let r=this.createErrorMessageElement();t.appendChild(r),e.appendChild(t);}connectedCallback(){this.setValue("0.00");}createContainerElement(){let e=document.createElement("div");return e.setAttribute("class","field-input-container"),e}createLabelElement(){let e=document.createElement("label");return e.setAttribute("class","field-input-label"),e.setAttribute("for","input"),e.textContent=this.getAttribute("label")||"Field Label",e}createInputElement(){let e=document.createElement("input");return e.setAttribute("class","field-input-inner"),e.setAttribute("type","text"),e.setAttribute("placeholder",this.getAttribute("placeholder")||"Enter text"),e.addEventListener("input",()=>this.handleInput()),e}createErrorMessageElement(){let e=document.createElement("div");return e.setAttribute("class","error-message"),e.textContent="Please enter Arabic numerals",e}handleInput(){let e=this.validateInput(this.input);this.input.setCustomValidity(e?"":"Please enter a valid input");let t=new CustomEvent("change",{detail:{value:this.input.value},bubbles:!0,composed:!0});this.dispatchEvent(t);}validateInput(e){return !Number.isNaN(Number(e.value))}setValue(e,t=!0){this.input.value=e,t&&this.handleInput(e);}};m(A,"styles",new CSSStyleSheet),A.styles.replaceSync(` + .field-input-container { + display: flex; + flex-direction: column; + gap: 8px; + position: relative; + } + + label { + font-size: 16px; + color: #333; + margin-bottom: 4px; + } + + input { + box-sizing: border-box; + padding: 8.5px 14px; + font-size: 16px; + border: 2px solid var(--input-border-color); + border-radius: 6px; + width: 100%; + outline: none; + transition: var(--transition-duration) var(--transition-bezier); + } + + input:hover { + border-color: var(--input-hover-border-color); + } + + input:focus { + border-color: var(--input-focus-border-color); + } + + .error-message { + color: var(--input-invalid-border-color); + font-size: 12px; + visibility: hidden; + position: absolute; + top: 100%; + } + + input:invalid { + border-color: var(--input-invalid-border-color); + } + + input:invalid + .error-message { + visibility: visible; + } + `);w=A;customElements.define("number-input",w);});var q,J,$,z,O=d(()=>{q="https://cdn.jsdelivr.net/npm/@fawazahmed0/currency-api",J="v1",$={AD:"EUR",AE:"AED",AF:"AFN",AG:"XCD",AI:"XCD",AL:"ALL",AM:"AMD",AO:"AOA",AR:"ARS",AS:"USD",AT:"EUR",AU:"AUD",AW:"AWG",AX:"EUR",AZ:"AZN",BA:"BAM",BB:"BBD",BD:"BDT",BE:"EUR",BF:"XOF",BG:"BGN",BH:"BHD",BI:"BIF",BJ:"XOF",BL:"EUR",BM:"BMD",BN:"BND",BO:"BOB",BQ:"USD",BR:"BRL",BS:"BSD",BT:"BTN",BV:"NOK",BW:"BWP",BY:"BYN",BZ:"BZD",CA:"CAD",CC:"AUD",CD:"CDF",CF:"XAF",CG:"XAF",CH:"CHF",CI:"XOF",CK:"NZD",CL:"CLP",CM:"XAF",CN:"CNY",CO:"COP",CR:"CRC",CU:"CUP",CV:"CVE",CW:"ANG",CX:"AUD",CY:"EUR",CZ:"CZK",DE:"EUR",DJ:"DJF",DK:"DKK",DM:"XCD",DO:"DOP",DZ:"DZD",EC:"USD",EE:"EUR",EG:"EGP",EH:"MAD",ER:"ERN",ES:"EUR",ET:"ETB",FI:"EUR",FJ:"FJD",FK:"FKP",FM:"USD",FO:"DKK",FR:"EUR",GA:"XAF",GB:"GBP",GD:"XCD",GE:"GEL",GF:"EUR",GG:"GBP",GH:"GHS",GI:"GIP",GL:"DKK",GM:"GMD",GN:"GNF",GP:"EUR",GQ:"XAF",GR:"EUR",GS:"GBP",GT:"GTQ",GU:"USD",GW:"XOF",GY:"GYD",HK:"HKD",HM:"AUD",HN:"HNL",HR:"EUR",HT:"HTG",HU:"HUF",ID:"IDR",IE:"EUR",IL:"ILS",IM:"GBP",IN:"INR",IO:"USD",IQ:"IQD",IR:"IRR",IS:"ISK",IT:"EUR",JE:"GBP",JM:"JMD",JO:"JOD",JP:"JPY",KE:"KES",KG:"KGS",KH:"KHR",KI:"AUD",KM:"KMF",KN:"XCD",KP:"KPW",KR:"KRW",KW:"KWD",KY:"KYD",KZ:"KZT",LA:"LAK",LB:"LBP",LC:"XCD",LI:"CHF",LK:"LKR",LR:"LRD",LS:"LSL",LT:"EUR",LU:"EUR",LV:"EUR",LY:"LYD",MA:"MAD",MC:"EUR",MD:"MDL",ME:"EUR",MF:"EUR",MG:"MGA",MH:"USD",MK:"MKD",ML:"XOF",MM:"MMK",MN:"MNT",MO:"MOP",MP:"USD",MQ:"EUR",MR:"MRO",MS:"XCD",MT:"EUR",MU:"MUR",MV:"MVR",MW:"MWK",MX:"MXN",MY:"MYR",MZ:"MZN",NA:"NAD",NC:"XPF",NE:"XOF",NF:"AUD",NG:"NGN",NI:"NIO",NL:"EUR",NO:"NOK",NP:"NPR",NR:"AUD",NU:"NZD",NZ:"NZD",OM:"OMR",PA:"PAB",PE:"PEN",PF:"XPF",PG:"PGK",PH:"PHP",PK:"PKR",PL:"PLN",PM:"EUR",PN:"NZD",PR:"USD",PS:"ILS",PT:"EUR",PW:"USD",PY:"PYG",QA:"QAR",RE:"EUR",RO:"RON",RS:"RSD",RU:"RUB",RW:"RWF",SA:"SAR",SB:"SBD",SC:"SCR",SD:"SDG",SE:"SEK",SG:"SGD",SH:"SHP",SI:"EUR",SJ:"NOK",SK:"EUR",SL:"SLL",SM:"EUR",SN:"XOF",SO:"SOS",SR:"SRD",ST:"STD",SV:"SVC",SX:"ANG",SY:"SYP",SZ:"SZL",TC:"USD",TD:"XAF",TF:"EUR",TG:"XOF",TH:"THB",TJ:"TJS",TK:"NZD",TL:"USD",TM:"TMT",TN:"TND",TO:"TOP",TR:"TRY",TT:"TTD",TV:"AUD",TW:"TWD",TZ:"TZS",UA:"UAH",UG:"UGX",UM:"USD",US:"USD",UY:"UYU",UZ:"UZS",VA:"EUR",VC:"XCD",VE:"VEF",VG:"USD",VI:"USD",VN:"VND",VU:"VUV",WF:"XPF",WS:"WST",YE:"YER",YT:"EUR",ZA:"ZAR",ZM:"ZMW",ZW:"ZWL"},z={BDS:"BBD",CNT:"TWD",NIS:"ILS",NTD:"TWD",STG:"GBP",RMB:"CNY"};});var g,B,P,G=d(()=>{g=class g{constructor(e={}){m(this,"timeout");m(this,"headers");this.timeout=e.timeout||g.TIMEOUT,this.headers=e.headers||g.REQUEST_HEADER;}_fetch(e){return p(this,null,function*(){var s,o,a,c;let t,r=h({},e);if(!r.signal){let i=new AbortController;r.signal=i.signal,t=setTimeout(()=>i.abort(),this.timeout);}try{let i=yield fetch(e.url,r);if(t&&clearTimeout(t),!i.ok)return this.createResponse((s=i.status)!=null?s:500,(o=i.statusText)!=null?o:"Internal Server Error");let u=i.headers.get("Content-Type"),l=u!=null&&u.includes("application/json")?yield i.json():yield i.text();return this.createResponse((a=i.status)!=null?a:200,(c=i.statusText)!=null?c:"OK",l)}catch(i){throw i instanceof DOMException&&i.name==="AbortError"?new Error("Request timeout or aborted"):i}})}createResponse(e,t,r){return {code:e,message:t,data:r}}};m(g,"TIMEOUT",5e3),m(g,"REQUEST_HEADER");B=g,P=B;});var F,I,k=d(()=>{G();F=class extends P{constructor(e={}){super(e);}get(r){return p(this,arguments,function*(e,t={}){let s=new Request(e,E(h({},t),{method:"GET",headers:h(h({},this.headers),t.headers)}));return this._fetch(s)})}},I=F;});var j=d(()=>{k();G();});var x,H,C,Q=d(()=>{O();j();x=class x extends I{constructor(t={}){let a=t,{baseCurrency:r,minified:s=x.MINIFIED}=a,o=D(a,["baseCurrency","minified"]);super(o);m(this,"options");this.options={baseCurrency:r,minified:s};}getCurrencies(){return p(this,arguments,function*(t="latest",r={}){let s=this.getApiUrl(t,"currencies"),o=yield this.get(s,r);return E(h({},o),{data:this.composeDataList(o.data,"name")})})}getRates(){return p(this,arguments,function*(t=this.options.baseCurrency,r="latest",s={}){var i;let o=this.validCurrencyCode(t).toLowerCase(),a=this.getApiUrl(r,`currencies/${o}`),c=yield this.get(a,s);return E(h({},c),{data:this.composeDataList((i=c.data)==null?void 0:i[o],"rate")})})}getRate(){return p(this,arguments,function*(t=this.options.baseCurrency,r,s="latest",o={}){var b;let a=this.validCurrencyCode(t).toLowerCase(),c=this.getApiUrl(s,`currencies/${a}`),i=yield this.get(c,o),u=(b=i.data)==null?void 0:b[a],l=this.validCurrencyCode(r,"destination").toLowerCase();return E(h({},i),{data:u==null?void 0:u[l]})})}getCode(t){return this.validCurrencyCode(t,"locale")}convert(){return p(this,arguments,function*(t=this.options.baseCurrency,r,s=0,o="latest",a={}){let l=yield this.getRate(t,r,o,a),{data:i}=l,u=D(l,["data"]);return h({data:i?Number(s)*i:void 0},u)})}composeDataList(t,r){return t?Object.entries(t).map(([s,o])=>({code:s,[r]:o})):[]}validCurrencyCode(t,r="base"){var o;if(!t)throw new Error(`Please specify the ${r} currency code.`);return (o=h(h({},$),z)[t.toUpperCase()])!=null?o:t}getApiUrl(t,r){let s=this.formatDate(t),o=`${q}@${s}/${J}`,a=this.options.minified?"min.json":"json";return `${o}/${r}.${a}`}formatDate(t){return t==="latest"||!this.isValidDate(t)?"latest":`${t.getFullYear()}-${this.paddedDate(t.getMonth()+1)}-${this.paddedDate(t.getDate())}`}isValidDate(t){return this.isDate(t)&&!Number.isNaN(t.getTime())}isDate(t){return t instanceof Date||typeof t=="object"&&Object.prototype.toString.call(t)==="[object Date]"}paddedDate(t,r=2,s="0"){return `${t}`.padStart(r,s)}};m(x,"MINIFIED",!0);H=x,C=H;});var _=d(()=>{Q();});var ee=d(()=>{});var te=d(()=>{});var ne=d(()=>{ee();te();});var U=d(()=>{O();_();ne();});function Re(){var n,e;if(!(typeof window=="undefined"||!window.navigator))return (e=(n=window.navigator.language)==null?void 0:n.split("-"))==null?void 0:e[1]}var re,se=d(()=>{re=Re;});function be(n){return `${n.getFullYear()}-${oe(n.getMonth()+1)}-${oe(n.getDate())}`}function oe(n,e=2,t="0"){return `${n}`.padStart(e,t)}var R,K=d(()=>{R=be;});function De(){return p(this,null,function*(){try{let n=new Date,e=localStorage.getItem("currencies");if(e){let{time:o,data:a}=JSON.parse(e);if(R(n)===o)return a}let s=((yield new C().getCurrencies()).data||[]).filter(o=>!!o.code).sort((o,a)=>{let c=(o.name||o.code).split(" ")[0].toLowerCase(),i=(a.name||a.code).split(" ")[0].toLowerCase();return c.localeCompare(i)});return localStorage.setItem("currencies",JSON.stringify({time:R(n),data:s})),s}catch(n){console.error("Error fetching options:",n);}})}var ie,ae=d(()=>{U();K();ie=De;});var v,V,ce=d(()=>{U();se();ae();v=class v extends HTMLElement{constructor(){super();let e=this.attachShadow({mode:"open"});e.adoptedStyleSheets=[v.styles];let t=this.createContainerElement();if(this.getAttribute("label")){let r=this.createLabelElement();t.appendChild(r);}this.select=this.createSelectElement(),t.appendChild(this.select),e.appendChild(t);}connectedCallback(){return p(this,null,function*(){let e=yield ie();for(let r of e){if(!r.code)continue;let s=document.createElement("option");s.value=r.code.toUpperCase(),s.textContent=r.name||r.code.toUpperCase(),this.select.appendChild(s);}let t=this.getAttribute("value");if(t)this.setValue(t);else {let r=new C,s=re(),o=r.getCode(s);o&&this.setValue(o);}})}createContainerElement(){let e=document.createElement("div");return e.setAttribute("class","field-select-container"),e}createLabelElement(){let e=document.createElement("label");return e.setAttribute("class","field-select-label"),e.setAttribute("for","select"),e.textContent=this.getAttribute("label")||"Select Label",e}createSelectElement(){let e=document.createElement("select");return e.setAttribute("class","field-select-inner"),e.setAttribute("name",this.getAttribute("name")||"select-field"),e.addEventListener("change",t=>this.handleChange(t.target.value)),e}handleChange(e){let t=new CustomEvent("change",{detail:{value:e},bubbles:!0,composed:!0});this.dispatchEvent(t);}setValue(e){this.select.value=e,this.handleChange(e);}};m(v,"styles",new CSSStyleSheet),v.styles.replaceSync(` + .field-select-container { + display: flex; + flex-direction: column; + gap: 8px; + min-width: 280px; + } + + label { + font-size: 16px; + color: #333; + margin-bottom: 4px; + } + + select { + box-sizing: border-box; + padding: 8.5px 14px; + font-size: 16px; + border: 2px solid var(--input-border-color); + border-radius: 6px; + width: 100%; + outline: none; + } + + select:hover { + border-color: var(--input-hover-border-color); + } + + select:focus { + border-color: var(--input-focus-border-color); + } + + select:invalid { + border-color: var(--input-invalid-border-color); + } + `);V=v;customElements.define("field-select",V);});function Se(n,e,{leading:t=!1}={}){let r,s,o,a;function c(){return a!==void 0&&(r=n.call(o,...a),s=o=a=void 0),r}function i(...u){return o=this,a=u,t&&s===void 0&&(r=c()),s&&(clearTimeout(s),s=void 0),s=setTimeout(()=>{r=c();},e),r}return i.cancel=()=>{s!==void 0&&clearTimeout(s),s=o=a=void 0;},i.flush=()=>s===void 0?r:c(),i}var le,ue=d(()=>{le=Se;});function Ae(n){return p(this,null,function*(){var e;try{let t=new Date,r=localStorage.getItem(`${n}-rates`);if(r){let{time:c,data:i}=JSON.parse(r);if(R(t)===c)return i}let a=(e=(yield new C().getRates(n)).data)==null?void 0:e.filter(c=>!!c.code);return localStorage.setItem(`${n}-rates`,JSON.stringify({code:n,time:R(t),data:a})),a}catch(t){console.error("Error fetching options:",t);}})}var de,pe=d(()=>{U();K();de=Ae;});var ve=ge(me=>{Y();W();ce();ue();pe();(()=>{let n={baseCurrency:"",destCurrency:"",baseAmount:0,destAmount:0,exchangeRate:1},e=document.querySelector("#base-currency"),t=document.querySelector("#dest-currency"),r=document.querySelector("#base-amount"),s=document.querySelector("#dest-amount"),o=document.querySelector(".form-button"),a=()=>{let l=n.baseAmount*n.exchangeRate;n.destAmount=l,s.setValue(l.toFixed(2),!1);},c=()=>{let l=n.destAmount/n.exchangeRate;n.baseAmount=l,r.setValue(l.toFixed(2),!1);},i=(l=1)=>{n.exchangeRate=l,a();},u=le(()=>p(me,null,function*(){var b;if(!n.baseCurrency||!n.destCurrency)return;let l=yield de(n.baseCurrency);i((b=l.find(he=>he.code===n.destCurrency.toLowerCase()))==null?void 0:b.rate);}),80);e.addEventListener("change",l=>{n.baseCurrency=l.detail.value,u();}),t.addEventListener("change",l=>{n.destCurrency=l.detail.value,u();}),r.addEventListener("change",l=>{n.baseAmount=Number(l.detail.value),a();}),s.addEventListener("change",l=>{n.destAmount=Number(l.detail.value),c();}),o.addEventListener("click",()=>{[n.baseCurrency,n.destCurrency]=[n.destCurrency,n.baseCurrency],e.setValue(n.baseCurrency),t.setValue(n.destCurrency);});})();});var app = ve();return app;})();//# sourceMappingURL=app.js.map +//# sourceMappingURL=app.js.map \ No newline at end of file diff --git a/docs/assets/app.js.map b/docs/assets/app.js.map new file mode 100644 index 0000000..78f5bb0 --- /dev/null +++ b/docs/assets/app.js.map @@ -0,0 +1 @@ +{"version":3,"sources":["../page/components/icon.js","../page/components/input.js","../src/constants/index.ts","../src/utils/http-request.ts","../src/utils/http-client.ts","../src/utils/index.ts","../src/services/forex-client.ts","../src/services/index.ts","../src/services/types.ts","../src/utils/types.ts","../src/types.ts","../src/index.ts","../page/utils/get-locale.js","../page/utils/format-date.js","../page/utils/get-currencies.js","../page/components/select.js","../page/utils/debounce.js","../page/utils/get-rates.js","../page/app.js"],"names":["_BaseIcon","BaseIcon","GithubIcon","NpmIcon","SwitchIcon","init_icon","__esmMin","href","classname","shadowRoot","anchor","slot","viewBox","children","svg","child","_a","_b","tag","restOptions","__objRest","key","__publicField","_NumberInput","NumberInput","init_input","container","label","errorMessage","input","isValid","event","value","trigger","BASE_URL","BASE_URL_VERSION","LOCALE_CURRENCY","NON_STANDARD_CODES","init_constants","_HttpRequest","HttpRequest","http_request_default","init_http_request","options","__async","_c","_d","timeoutId","requestHeader","__spreadValues","controller","response","contentType","data","error","code","message","HttpClient","http_client_default","init_http_client","_0","url","requestOptions","__spreadProps","init_utils","_ForexClient","ForexClient","forex_client_default","init_forex_client","baseCurrency","minified","date","lowercaseCode","baseCode","destCode","rates","lowercaseDestCode","localeCode","amount","record","type","source","dateString","prefix","sourceExtension","length","padding","init_services","init_types","init_src","getLocale","get_locale_default","init_get_locale","formatDate","paddedDate","format_date_default","init_format_date","getCurrencies","localData","time","result","item","a","b","letterA","letterB","get_currencies_default","init_get_currencies","_FieldSelect","FieldSelect","init_select","option","defaultValue","client","currencyCode","select","e","customEvent","debounce","function_","wait","leading","timer","lastThis","lastArguments","invokeFunction","debounced","arguments_","debounce_default","init_debounce","getRates","get_rates_default","init_get_rates","require_app","__commonJSMin","exports","store","baseCurrencyEl","destCurrencyEl","baseAmountEl","destAmountEl","switchButtonEl","onBaseAmountChange","onDestAmountChange","onRateChange","rate","onCurrenciesChange"],"mappings":"k9BAAA,IAAMA,CAAAA,CAAAC,EA8FAC,CAeAC,CAAAA,CAAAA,CAsBAC,EAnINC,C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r\n BaseIcon.styles.replaceSync(`\r\n :host {\r\n display: inline-flex;\r\n font-size: var(--navbar-icon-font-size, 1rem);\r\n color: var(--anchor-link-color, currentColor);\r\n text-decoration: none;\r\n outline: none;\r\n cursor: pointer;\r\n }\r\n :host(:hover) {\r\n color: var(--anchor-link-hover-color, currentColor);\r\n }\r\n a {\r\n display: inline-flex;\r\n align-items: center;\r\n flex-direction: row;\r\n color: inherit;\r\n text-decoration: none;\r\n outline: none;\r\n transition: var(--transition-duration) var(--transition-bezier);\r\n }\r\n .icon { font-size: var(--navbar-icon-font-size); }\r\n .icon.icon-npm:hover { color: #cd3f45; }\r\n .icon.icon-github:hover { color: #000; }\r\n .icon.icon-switch { font-size: 2rem; }\r\n .icon.icon-switch:hover { color: #6600eb; }\r\n .user-selected-none {\r\n user-select: none;\r\n -ms-user-select: none;\r\n -moz-user-select: none;\r\n -webkit-user-select: none;\r\n }\r\n `);\r\n }\r\n\r\n constructor({ href, classname } = {}) {\r\n super();\r\n const shadowRoot = this.attachShadow({ mode: 'open' });\r\n shadowRoot.adoptedStyleSheets = [BaseIcon.styles];\r\n\r\n const anchor = this.createAnchorElement(href, classname);\r\n\r\n const slot = this.createSlotElement();\r\n anchor.appendChild(slot);\r\n\r\n shadowRoot.appendChild(anchor);\r\n }\r\n\r\n createAnchorElement(href, classname) {\r\n const anchor = document.createElement('a');\r\n anchor.setAttribute(\r\n 'class',\r\n ['icon', ...(classname || this.classList)].join(' '),\r\n );\r\n anchor.setAttribute('href', href || this.getAttribute('href') || '#');\r\n return anchor;\r\n }\r\n\r\n createSlotElement() {\r\n return document.createElement('slot');\r\n }\r\n\r\n createSvgElement({ viewBox, children = [] }) {\r\n const svg = document.createElementNS(\r\n 'http://www.w3.org/2000/svg',\r\n 'svg',\r\n );\r\n svg.setAttribute('viewBox', viewBox);\r\n svg.setAttribute('width', '1em');\r\n svg.setAttribute('height', '1em');\r\n\r\n for (const child of children) {\r\n svg.appendChild(this.createSvgChildElement(child));\r\n }\r\n\r\n return svg;\r\n }\r\n\r\n createSvgChildElement({ tag, ...restOptions }) {\r\n const child = document.createElementNS(\r\n 'http://www.w3.org/2000/svg',\r\n tag,\r\n );\r\n if (!restOptions.fill) restOptions.fill = 'currentColor';\r\n for (const key in restOptions) {\r\n child.setAttribute(key, restOptions[key]);\r\n }\r\n return child;\r\n }\r\n}\r\n\r\nclass GithubIcon extends BaseIcon {\r\n constructor() {\r\n super({ classname: ['icon-github'] });\r\n this.appendChild(this.createSvgElement({\r\n viewBox: '0 0 24 24',\r\n children: [\r\n {\r\n tag: 'path',\r\n d: 'M12.5.75C6.146.75 1 5.896 1 12.25c0 5.089 3.292 9.387 7.863 10.91.575.101.79-.244.79-.546 0-.273-.014-1.178-.014-2.142-2.889.532-3.636-.704-3.866-1.35-.13-.331-.69-1.352-1.18-1.625-.402-.216-.977-.748-.014-.762.906-.014 1.553.834 1.769 1.179 1.035 1.74 2.688 1.25 3.349.948.1-.747.402-1.25.733-1.538-2.559-.287-5.232-1.279-5.232-5.678 0-1.25.445-2.285 1.178-3.09-.115-.288-.517-1.467.115-3.048 0 0 .963-.302 3.163 1.179.92-.259 1.897-.388 2.875-.388.977 0 1.955.13 2.875.388 2.2-1.495 3.162-1.179 3.162-1.179.633 1.581.23 2.76.115 3.048.733.805 1.179 1.825 1.179 3.09 0 4.413-2.688 5.39-5.247 5.678.417.36.776 1.05.776 2.128 0 1.538-.014 2.774-.014 3.162 0 .302.216.662.79.547C20.709 21.637 24 17.324 24 12.25 24 5.896 18.854.75 12.5.75Z',\r\n },\r\n ],\r\n }));\r\n }\r\n}\r\n\r\nclass NpmIcon extends BaseIcon {\r\n constructor() {\r\n super({ classname: ['icon-npm'] });\r\n this.appendChild(this.createSvgElement({\r\n viewBox: '0 0 27.23 27.23',\r\n children: [\r\n {\r\n tag: 'rect',\r\n width: '27.23',\r\n height: '27.23',\r\n rx: '2',\r\n },\r\n {\r\n tag: 'polygon',\r\n fill: '#fff',\r\n points: '5.8 21.75 13.66 21.75 13.67 9.98 17.59 9.98 17.58 21.76 21.51 21.76 21.52 6.06 5.82 6.04 5.8 21.75',\r\n },\r\n ],\r\n }));\r\n }\r\n}\r\n\r\nclass SwitchIcon extends BaseIcon {\r\n constructor() {\r\n super({ classname: ['icon-switch'] });\r\n this.appendChild(this.createSvgElement({\r\n viewBox: '0 0 1024 1024',\r\n children: [\r\n {\r\n tag: 'path',\r\n d: 'M677.888 335.872l-176.128 0c-2.048 0-2.048 0-2.048-2.048 0-2.048 0-2.048 0-2.048l43.008-43.008c8.192-8.192 8.192-20.48 0-28.672-8.192-8.192-20.48-8.192-28.672 0l-81.92 81.92c-6.144 6.144-8.192 14.336-4.096 22.528 4.096 8.192 10.24 12.288 18.432 12.288l233.472 0c57.344 0 106.496 47.104 108.544 102.4 2.048 53.248-36.864 100.352-90.112 108.544-10.24 2.048-18.432 10.24-18.432 20.48 0 6.144 2.048 12.288 8.192 16.384 4.096 4.096 8.192 4.096 14.336 4.096 0 0 2.048 0 2.048 0 73.728-10.24 126.976-75.776 124.928-149.504C827.392 401.408 759.808 335.872 677.888 335.872z',\r\n },\r\n {\r\n tag: 'path',\r\n d: 'M598.016 598.016 364.544 598.016c-57.344 0-106.496-47.104-108.544-102.4-2.048-53.248 36.864-100.352 90.112-108.544 10.24-2.048 18.432-10.24 18.432-20.48 0-6.144-2.048-12.288-8.192-16.384-4.096-4.096-10.24-6.144-16.384-4.096-73.728 10.24-126.976 75.776-124.928 149.504 2.048 79.872 69.632 143.36 149.504 143.36l176.128 0c2.048 0 2.048 0 2.048 2.048 0 2.048 0 2.048 0 2.048l-43.008 43.008c-4.096 4.096-6.144 8.192-6.144 14.336 0 6.144 2.048 10.24 6.144 14.336 4.096 4.096 10.24 6.144 14.336 6.144 6.144 0 10.24-2.048 14.336-6.144l81.92-81.92c6.144-6.144 8.192-14.336 4.096-22.528C614.4 602.112 606.208 598.016 598.016 598.016z',\r\n },\r\n ],\r\n }));\r\n }\r\n}\r\n\r\ncustomElements.define('base-icon', BaseIcon);\r\ncustomElements.define('github-icon', GithubIcon);\r\ncustomElements.define('npm-icon', NpmIcon);\r\ncustomElements.define('switch-icon', SwitchIcon);\r\n","class NumberInput extends HTMLElement {\r\n static styles = new CSSStyleSheet();\r\n static {\r\n NumberInput.styles.replaceSync(`\r\n .field-input-container {\r\n display: flex;\r\n flex-direction: column;\r\n gap: 8px;\r\n position: relative;\r\n }\r\n\r\n label {\r\n font-size: 16px;\r\n color: #333;\r\n margin-bottom: 4px;\r\n }\r\n\r\n input {\r\n box-sizing: border-box;\r\n padding: 8.5px 14px;\r\n font-size: 16px;\r\n border: 2px solid var(--input-border-color);\r\n border-radius: 6px;\r\n width: 100%;\r\n outline: none;\r\n transition: var(--transition-duration) var(--transition-bezier);\r\n }\r\n\r\n input:hover {\r\n border-color: var(--input-hover-border-color);\r\n }\r\n \r\n input:focus {\r\n border-color: var(--input-focus-border-color);\r\n }\r\n\r\n .error-message {\r\n color: var(--input-invalid-border-color);\r\n font-size: 12px;\r\n visibility: hidden;\r\n position: absolute;\r\n top: 100%;\r\n }\r\n\r\n input:invalid {\r\n border-color: var(--input-invalid-border-color);\r\n }\r\n\r\n input:invalid + .error-message {\r\n visibility: visible;\r\n }\r\n `);\r\n }\r\n\r\n constructor() {\r\n super();\r\n const shadowRoot = this.attachShadow({ mode: 'open' });\r\n shadowRoot.adoptedStyleSheets = [NumberInput.styles];\r\n\r\n const container = this.createContainerElement();\r\n\r\n if (this.getAttribute('label')) {\r\n const label = this.createLabelElement();\r\n container.appendChild(label);\r\n }\r\n\r\n this.input = this.createInputElement();\r\n container.appendChild(this.input);\r\n\r\n const errorMessage = this.createErrorMessageElement();\r\n container.appendChild(errorMessage);\r\n\r\n shadowRoot.appendChild(container);\r\n }\r\n\r\n connectedCallback() {\r\n this.setValue('0.00');\r\n }\r\n\r\n createContainerElement() {\r\n const container = document.createElement('div');\r\n container.setAttribute('class', 'field-input-container');\r\n return container;\r\n }\r\n\r\n createLabelElement() {\r\n const label = document.createElement('label');\r\n label.setAttribute('class', 'field-input-label');\r\n label.setAttribute('for', 'input');\r\n label.textContent = this.getAttribute('label') || 'Field Label';\r\n return label;\r\n }\r\n\r\n createInputElement() {\r\n const input = document.createElement('input');\r\n input.setAttribute('class', 'field-input-inner');\r\n input.setAttribute('type', 'text');\r\n input.setAttribute('placeholder', this.getAttribute('placeholder') || 'Enter text');\r\n input.addEventListener('input', () => this.handleInput());\r\n return input\r\n }\r\n\r\n createErrorMessageElement() {\r\n const errorMessage = document.createElement('div');\r\n errorMessage.setAttribute('class', 'error-message');\r\n errorMessage.textContent = 'Please enter Arabic numerals';\r\n return errorMessage;\r\n }\r\n\r\n handleInput() {\r\n const isValid = this.validateInput(this.input);\r\n this.input.setCustomValidity(isValid ? '' : 'Please enter a valid input');\r\n\r\n const event = new CustomEvent('change', {\r\n detail: { value: this.input.value },\r\n bubbles: true,\r\n composed: true,\r\n });\r\n this.dispatchEvent(event);\r\n }\r\n\r\n validateInput(input) {\r\n return !Number.isNaN(Number(input.value));\r\n }\r\n\r\n setValue(value, trigger = true) {\r\n this.input.value = value;\r\n trigger && this.handleInput(value);\r\n }\r\n}\r\n\r\ncustomElements.define('number-input', NumberInput);\r\n","/**\n * @source {@link https://github.com/fawazahmed0/exchange-api}\n */\nexport const BASE_URL =\n 'https://cdn.jsdelivr.net/npm/@fawazahmed0/currency-api';\n\n/**\n * @source {@link https://github.com/fawazahmed0/exchange-api}\n */\nexport const BASE_URL_VERSION = 'v1';\n\n/**\n * @source {@link https://en.wikipedia.org/wiki/ISO_4217#Active_codes_(list_one)}\n */\nexport const LOCALE_CURRENCY = {\n AD: 'EUR',\n AE: 'AED',\n AF: 'AFN',\n AG: 'XCD',\n AI: 'XCD',\n AL: 'ALL',\n AM: 'AMD',\n AO: 'AOA',\n AR: 'ARS',\n AS: 'USD',\n AT: 'EUR',\n AU: 'AUD',\n AW: 'AWG',\n AX: 'EUR',\n AZ: 'AZN',\n BA: 'BAM',\n BB: 'BBD',\n BD: 'BDT',\n BE: 'EUR',\n BF: 'XOF',\n BG: 'BGN',\n BH: 'BHD',\n BI: 'BIF',\n BJ: 'XOF',\n BL: 'EUR',\n BM: 'BMD',\n BN: 'BND',\n BO: 'BOB',\n BQ: 'USD',\n BR: 'BRL',\n BS: 'BSD',\n BT: 'BTN',\n BV: 'NOK',\n BW: 'BWP',\n BY: 'BYN',\n BZ: 'BZD',\n CA: 'CAD',\n CC: 'AUD',\n CD: 'CDF',\n CF: 'XAF',\n CG: 'XAF',\n CH: 'CHF',\n CI: 'XOF',\n CK: 'NZD',\n CL: 'CLP',\n CM: 'XAF',\n CN: 'CNY',\n CO: 'COP',\n CR: 'CRC',\n CU: 'CUP',\n CV: 'CVE',\n CW: 'ANG',\n CX: 'AUD',\n CY: 'EUR',\n CZ: 'CZK',\n DE: 'EUR',\n DJ: 'DJF',\n DK: 'DKK',\n DM: 'XCD',\n DO: 'DOP',\n DZ: 'DZD',\n EC: 'USD',\n EE: 'EUR',\n EG: 'EGP',\n EH: 'MAD',\n ER: 'ERN',\n ES: 'EUR',\n ET: 'ETB',\n FI: 'EUR',\n FJ: 'FJD',\n FK: 'FKP',\n FM: 'USD',\n FO: 'DKK',\n FR: 'EUR',\n GA: 'XAF',\n GB: 'GBP',\n GD: 'XCD',\n GE: 'GEL',\n GF: 'EUR',\n GG: 'GBP',\n GH: 'GHS',\n GI: 'GIP',\n GL: 'DKK',\n GM: 'GMD',\n GN: 'GNF',\n GP: 'EUR',\n GQ: 'XAF',\n GR: 'EUR',\n GS: 'GBP',\n GT: 'GTQ',\n GU: 'USD',\n GW: 'XOF',\n GY: 'GYD',\n HK: 'HKD',\n HM: 'AUD',\n HN: 'HNL',\n HR: 'EUR',\n HT: 'HTG',\n HU: 'HUF',\n ID: 'IDR',\n IE: 'EUR',\n IL: 'ILS',\n IM: 'GBP',\n IN: 'INR',\n IO: 'USD',\n IQ: 'IQD',\n IR: 'IRR',\n IS: 'ISK',\n IT: 'EUR',\n JE: 'GBP',\n JM: 'JMD',\n JO: 'JOD',\n JP: 'JPY',\n KE: 'KES',\n KG: 'KGS',\n KH: 'KHR',\n KI: 'AUD',\n KM: 'KMF',\n KN: 'XCD',\n KP: 'KPW',\n KR: 'KRW',\n KW: 'KWD',\n KY: 'KYD',\n KZ: 'KZT',\n LA: 'LAK',\n LB: 'LBP',\n LC: 'XCD',\n LI: 'CHF',\n LK: 'LKR',\n LR: 'LRD',\n LS: 'LSL',\n LT: 'EUR',\n LU: 'EUR',\n LV: 'EUR',\n LY: 'LYD',\n MA: 'MAD',\n MC: 'EUR',\n MD: 'MDL',\n ME: 'EUR',\n MF: 'EUR',\n MG: 'MGA',\n MH: 'USD',\n MK: 'MKD',\n ML: 'XOF',\n MM: 'MMK',\n MN: 'MNT',\n MO: 'MOP',\n MP: 'USD',\n MQ: 'EUR',\n MR: 'MRO',\n MS: 'XCD',\n MT: 'EUR',\n MU: 'MUR',\n MV: 'MVR',\n MW: 'MWK',\n MX: 'MXN',\n MY: 'MYR',\n MZ: 'MZN',\n NA: 'NAD',\n NC: 'XPF',\n NE: 'XOF',\n NF: 'AUD',\n NG: 'NGN',\n NI: 'NIO',\n NL: 'EUR',\n NO: 'NOK',\n NP: 'NPR',\n NR: 'AUD',\n NU: 'NZD',\n NZ: 'NZD',\n OM: 'OMR',\n PA: 'PAB',\n PE: 'PEN',\n PF: 'XPF',\n PG: 'PGK',\n PH: 'PHP',\n PK: 'PKR',\n PL: 'PLN',\n PM: 'EUR',\n PN: 'NZD',\n PR: 'USD',\n PS: 'ILS',\n PT: 'EUR',\n PW: 'USD',\n PY: 'PYG',\n QA: 'QAR',\n RE: 'EUR',\n RO: 'RON',\n RS: 'RSD',\n RU: 'RUB',\n RW: 'RWF',\n SA: 'SAR',\n SB: 'SBD',\n SC: 'SCR',\n SD: 'SDG',\n SE: 'SEK',\n SG: 'SGD',\n SH: 'SHP',\n SI: 'EUR',\n SJ: 'NOK',\n SK: 'EUR',\n SL: 'SLL',\n SM: 'EUR',\n SN: 'XOF',\n SO: 'SOS',\n SR: 'SRD',\n ST: 'STD',\n SV: 'SVC',\n SX: 'ANG',\n SY: 'SYP',\n SZ: 'SZL',\n TC: 'USD',\n TD: 'XAF',\n TF: 'EUR',\n TG: 'XOF',\n TH: 'THB',\n TJ: 'TJS',\n TK: 'NZD',\n TL: 'USD',\n TM: 'TMT',\n TN: 'TND',\n TO: 'TOP',\n TR: 'TRY',\n TT: 'TTD',\n TV: 'AUD',\n TW: 'TWD',\n TZ: 'TZS',\n UA: 'UAH',\n UG: 'UGX',\n UM: 'USD',\n US: 'USD',\n UY: 'UYU',\n UZ: 'UZS',\n VA: 'EUR',\n VC: 'XCD',\n VE: 'VEF',\n VG: 'USD',\n VI: 'USD',\n VN: 'VND',\n VU: 'VUV',\n WF: 'XPF',\n WS: 'WST',\n YE: 'YER',\n YT: 'EUR',\n ZA: 'ZAR',\n ZM: 'ZMW',\n ZW: 'ZWL',\n};\n\n/**\n * @source {@link https://en.wikipedia.org/wiki/ISO_4217#Non-standard_codes}\n */\nexport const NON_STANDARD_CODES = {\n BDS: 'BBD',\n CNT: 'TWD',\n NIS: 'ILS',\n NTD: 'TWD',\n STG: 'GBP',\n RMB: 'CNY',\n};\n","import type { HttpRequestOptions, HttpResponse } from './types';\n\nclass HttpRequest {\n private static TIMEOUT = 5000;\n private static REQUEST_HEADER: {\n 'Content-Type': 'application/json; charset=utf-8';\n };\n\n protected readonly timeout: number;\n protected readonly headers: HeadersInit;\n\n constructor(options: HttpRequestOptions = {}) {\n this.timeout = options.timeout || HttpRequest.TIMEOUT;\n this.headers = options.headers || HttpRequest.REQUEST_HEADER;\n }\n\n protected async _fetch(\n options: Request,\n ): Promise> {\n let timeoutId: string | number | NodeJS.Timeout | undefined;\n\n const requestHeader = { ...options } as Omit & {\n signal?: AbortSignal;\n };\n if (!requestHeader.signal) {\n const controller = new AbortController();\n requestHeader.signal = controller.signal;\n\n timeoutId = setTimeout(() => controller.abort(), this.timeout);\n }\n\n try {\n const response = await fetch(options.url, requestHeader);\n\n timeoutId && clearTimeout(timeoutId);\n\n if (!response.ok) {\n return this.createResponse(\n response.status ?? 500,\n response.statusText ?? 'Internal Server Error',\n );\n }\n\n const contentType = response.headers.get('Content-Type');\n const data = (\n contentType?.includes('application/json')\n ? await response.json()\n : await response.text()\n ) as T;\n\n return this.createResponse(\n response.status ?? 200,\n response.statusText ?? 'OK',\n data,\n );\n } catch (error) {\n if (error instanceof DOMException && error.name === 'AbortError') {\n throw new Error('Request timeout or aborted');\n }\n throw error;\n }\n }\n\n private createResponse(\n code: number,\n message: string,\n data?: T,\n ): HttpResponse {\n return { code, message, data };\n }\n}\n\nexport default HttpRequest;\n","import HttpRequest from './http-request';\nimport type { HttpRequestOptions, HttpResponse } from './types';\n\nclass HttpClient extends HttpRequest {\n constructor(options: HttpRequestOptions = {}) {\n super(options);\n }\n\n protected async get(\n url: string,\n options: RequestInit = {},\n ): Promise> {\n const requestOptions = new Request(url, {\n ...options,\n method: 'GET',\n headers: { ...this.headers, ...options.headers },\n });\n\n return this._fetch(requestOptions);\n }\n}\n\nexport default HttpClient;\n","export { default as HttpClient } from './http-client';\nexport { default as HttpRequest } from './http-request';\n","import {\n BASE_URL,\n BASE_URL_VERSION,\n LOCALE_CURRENCY,\n NON_STANDARD_CODES,\n} from '../constants';\nimport { HttpClient } from '../utils';\nimport type { HttpResponse } from '../utils/types';\nimport type {\n AvailableCurrency,\n ExchangeRate,\n ForexClientOptions,\n OriginalExchangeRates,\n} from './types';\n\n/**\n * A client to interact with the Forex API for fetching currency rates and conversion data\n */\nclass ForexClient extends HttpClient {\n private static MINIFIED = true;\n\n private readonly options: Pick<\n ForexClientOptions,\n 'baseCurrency' | 'minified'\n >;\n\n /**\n * Creates a new instance of ForexClient\n * @param {ForexClientOptions} [options={}] - The options for configuring the client\n * @param {string} options.baseCurrency - The base currency code\n * @param {boolean} options.minified - Minified JSON format\n * @param {number} options.timeout - Request timeout (milliseconds)\n * @param {HeadersInit} options.headers - Request header\n */\n constructor(options: ForexClientOptions = {}) {\n const {\n baseCurrency,\n minified = ForexClient.MINIFIED,\n ...restOptions\n } = options;\n super(restOptions);\n this.options = { baseCurrency, minified };\n }\n\n /**\n * Fetches the list of available currencies\n * @param {Date | \"latest\"} [date=\"latest\"] - The date for fetching currencies, or `\"latest\"` for the most recent\n * @param {RequestInit} [options={}] - Additional request options\n * @returns {Promise>} A list of available currencies\n *\n * @example\n * // => {\n * // code: 200,\n * // message: 'OK',\n * // data: [\n * // { code: 'eur', name: 'Euro' },\n * // { code: 'usd', name: 'US Dollar' },\n * // { code: 'cny', name: 'Chinese Yuan Renminbi' },\n * // ... More items\n * // ]\n * // }\n * new ForexClient().getCurrencies('latest');\n */\n async getCurrencies(\n date: Date | 'latest' = 'latest',\n options: RequestInit = {},\n ): Promise> {\n const url = this.getApiUrl(date, 'currencies');\n const response = await this.get>(url, options);\n return {\n ...response,\n data: this.composeDataList(\n response.data,\n 'name',\n ),\n };\n }\n\n /**\n * Fetches the exchange rates for a specific currency\n * @param {string | undefined} [code=this.options.baseCurrency] - The currency code or locale code to get rates for\n * @param {Date | \"latest\"} [date=\"latest\"] - The date for the rates, or `'latest'` for the most recent\n * @param {RequestInit} [options={}] - Additional request options\n * @returns {Promise>} A list of exchange rates\n *\n * @example\n * // => {\n * // code: 200,\n * // message: 'OK',\n * // data: [\n * // { code: 'eur', rate: 100_000 },\n * // { code: 'usd', rate: 100_000 },\n * // { code: 'cny', rate: 100_000 },\n * // ... More items\n * // ]\n * // }\n * new ForexClient().getRates('BTC');\n */\n async getRates(\n code: string | undefined = this.options.baseCurrency,\n date: Date | 'latest' = 'latest',\n options: RequestInit = {},\n ): Promise> {\n const lowercaseCode = this.validCurrencyCode(code).toLowerCase();\n const url = this.getApiUrl(date, `currencies/${lowercaseCode}`);\n const response = await this.get(url, options);\n\n return {\n ...response,\n data: this.composeDataList(\n response.data?.[lowercaseCode],\n 'rate',\n ),\n };\n }\n\n /**\n * Fetches the exchange rate between two currencies\n * @param {string | undefined} [baseCode=this.options.baseCurrency] - The base currency code or locale code\n * @param {string} destCode - The destination currency code or locale code\n * @param {Date | \"latest\"} [date=\"latest\"] - The date for the rate, or `'latest'` for the most recent\n * @param {RequestInit} [options={}] - Additional request options\n * @returns {Promise>} The exchange rate\n *\n * @example\n * // => {\n * // code: 200,\n * // message: 'OK',\n * // data: 100_000\n * // }\n * new ForexClient().getRate('BTC', 'USD');\n */\n async getRate(\n baseCode: string | undefined = this.options.baseCurrency,\n destCode?: string,\n date: Date | 'latest' = 'latest',\n options: RequestInit = {},\n ): Promise> {\n const lowercaseCode = this.validCurrencyCode(baseCode).toLowerCase();\n const url = this.getApiUrl(date, `currencies/${lowercaseCode}`);\n const response = await this.get(url, options);\n\n const rates = response.data?.[lowercaseCode];\n const lowercaseDestCode = this.validCurrencyCode(\n destCode,\n 'destination',\n ).toLowerCase();\n return { ...response, data: rates?.[lowercaseDestCode] };\n }\n\n /**\n * Get a valid currency code based on locale\n * @param {string} localeCode - The locale code to get currency code for\n * @returns {string} The corresponding currency code\n *\n * @example\n * // => 'USD'\n * new ForexClient().getCode('US');\n *\n * @example\n * // => 'CNH'\n * new ForexClient().getCode('HK');\n *\n * @example\n * // => 'CNY'\n * new ForexClient().getCode('RMB');\n */\n getCode(localeCode: string): string {\n return this.validCurrencyCode(localeCode, 'locale');\n }\n\n /**\n * Converts an amount from one currency to another\n * @param {string | undefined} [baseCode=this.options.baseCurrency] - The base currency code or locale code\n * @param {string} destCode - The destination currency code or locale code\n * @param {number} [amount=0] - The amount to convert\n * @param {Date | \"latest\"} [date=\"latest\"] - The date for the conversion rate, or `'latest'` for the most recent\n * @param {RequestInit} [options={}] - Additional request options\n * @returns {Promise>} The converted amount\n *\n * @example\n * // => {\n * // code: 200,\n * // message: 'OK',\n * // data: 100_000\n * // }\n * new ForexClient().convert('BTC', 'USD', 1);\n *\n * @example\n * // => {\n * // code: 200,\n * // message: 'OK',\n * // data: 7.27\n * // }\n * new ForexClient().convert('US', 'HK', 1);\n */\n async convert(\n baseCode: string | undefined = this.options.baseCurrency,\n destCode?: string,\n amount: number | string = 0,\n date: Date | 'latest' = 'latest',\n options: RequestInit = {},\n ): Promise> {\n const response = await this.getRate(baseCode, destCode, date, options);\n const { data, ...restOptions } = response;\n return {\n data: data ? Number(amount) * data : undefined,\n ...restOptions,\n };\n }\n\n private composeDataList(\n record: Record | undefined,\n key: string,\n ): T[] {\n if (!record) return [];\n\n return Object.entries(record).map(([code, value]) => ({\n code,\n [key]: value,\n })) as T[];\n }\n\n private validCurrencyCode(code?: string, type = 'base'): string {\n if (!code) throw new Error(`Please specify the ${type} currency code.`);\n\n const additionalCodes = { ...LOCALE_CURRENCY, ...NON_STANDARD_CODES };\n\n return (\n additionalCodes[\n code.toUpperCase() as keyof typeof additionalCodes\n ] ?? code\n );\n }\n\n private getApiUrl(date: Date | 'latest', source: string) {\n const dateString = this.formatDate(date);\n const prefix = `${BASE_URL}@${dateString}/${BASE_URL_VERSION}`;\n const sourceExtension = this.options.minified ? 'min.json' : 'json';\n return `${prefix}/${source}.${sourceExtension}`;\n }\n\n private formatDate(date: Date | 'latest'): string {\n if (date === 'latest' || !this.isValidDate(date)) {\n return 'latest';\n }\n\n return `${date.getFullYear()}-${this.paddedDate(date.getMonth() + 1)}-${this.paddedDate(date.getDate())}`;\n }\n\n private isValidDate(value: unknown): value is Date {\n return this.isDate(value) && !Number.isNaN(value.getTime());\n }\n\n private isDate(value: unknown): value is Date {\n return (\n value instanceof Date ||\n (typeof value === 'object' &&\n Object.prototype.toString.call(value) === '[object Date]')\n );\n }\n\n private paddedDate(value: number | string, length = 2, padding = '0') {\n return `${value}`.padStart(length, padding);\n }\n}\n\nexport default ForexClient;\n","export { default as ForexClient } from './forex-client';\n","import type { HttpRequestOptions } from '../utils/types';\n\nexport interface ForexClientOptions extends HttpRequestOptions {\n baseCurrency?: string;\n minified?: boolean;\n}\n\nexport interface AvailableCurrency {\n code: string;\n name: string;\n}\n\nexport type OriginalExchangeRates = {\n [key: string]: Record;\n} & { date: string };\n\nexport interface ExchangeRate {\n code: string;\n rate: number;\n}\n","export interface HttpRequestOptions {\n timeout?: number;\n headers?: HeadersInit;\n}\n\nexport interface HttpResponse {\n code: number;\n message: string;\n data?: T;\n}\n","export * from './services/types';\nexport * from './utils/types';\n","export * from './constants';\nexport * from './services';\nexport * from './types';\n","function getLocale () {\r\n if (typeof window === 'undefined' || !window.navigator)\r\n return;\r\n\r\n return window.navigator.language?.split('-')?.[1];\r\n}\r\n\r\nexport default getLocale;\r\n","function formatDate(date) {\r\n return `${date.getFullYear()}-${paddedDate(date.getMonth() + 1)}-${paddedDate(date.getDate())}`;\r\n}\r\n\r\nfunction paddedDate(value, length = 2, padding = '0') {\r\n return `${value}`.padStart(length, padding);\r\n}\r\n\r\nexport default formatDate;\r\n","import { ForexClient } from '../../src';\r\nimport formatDate from './format-date';\r\n\r\nasync function getCurrencies() {\r\n try {\r\n const date = new Date();\r\n const localData = localStorage.getItem('currencies');\r\n if (localData) {\r\n const { time, data } = JSON.parse(localData);\r\n if (formatDate(date) === time) return data;\r\n }\r\n\r\n const client = new ForexClient();\r\n const response = await client.getCurrencies();\r\n const result = (response.data || [])\r\n .filter((item) => Boolean(item.code))\r\n .sort((a, b) => {\r\n const letterA = (a.name || a.code).split(' ')[0].toLowerCase();\r\n const letterB = (b.name || b.code).split(' ')[0].toLowerCase();\r\n return letterA.localeCompare(letterB);\r\n });\r\n localStorage.setItem(\r\n 'currencies',\r\n JSON.stringify({ time: formatDate(date), data: result }),\r\n );\r\n\r\n return result;\r\n } catch (error) {\r\n console.error('Error fetching options:', error);\r\n }\r\n}\r\n\r\nexport default getCurrencies;\r\n","import { ForexClient } from '../../src';\r\nimport getLocale from '../utils/get-locale';\r\nimport getCurrencies from '../utils/get-currencies';\r\n\r\nclass FieldSelect extends HTMLElement {\r\n static styles = new CSSStyleSheet();\r\n\r\n static {\r\n FieldSelect.styles.replaceSync(`\r\n .field-select-container {\r\n display: flex;\r\n flex-direction: column;\r\n gap: 8px;\r\n min-width: 280px;\r\n }\r\n\r\n label {\r\n font-size: 16px;\r\n color: #333;\r\n margin-bottom: 4px;\r\n }\r\n\r\n select {\r\n box-sizing: border-box;\r\n padding: 8.5px 14px;\r\n font-size: 16px;\r\n border: 2px solid var(--input-border-color);\r\n border-radius: 6px;\r\n width: 100%;\r\n outline: none;\r\n }\r\n\r\n select:hover {\r\n border-color: var(--input-hover-border-color);\r\n }\r\n \r\n select:focus {\r\n border-color: var(--input-focus-border-color);\r\n }\r\n\r\n select:invalid {\r\n border-color: var(--input-invalid-border-color);\r\n }\r\n `);\r\n }\r\n\r\n constructor() {\r\n super();\r\n const shadowRoot = this.attachShadow({ mode: 'open' });\r\n shadowRoot.adoptedStyleSheets = [FieldSelect.styles];\r\n\r\n const container = this.createContainerElement();\r\n\r\n if (this.getAttribute('label')) {\r\n const label = this.createLabelElement();\r\n container.appendChild(label);\r\n }\r\n\r\n this.select = this.createSelectElement();\r\n container.appendChild(this.select);\r\n\r\n shadowRoot.appendChild(container);\r\n }\r\n\r\n async connectedCallback() {\r\n const data = await getCurrencies();\r\n\r\n for (const item of data) {\r\n if (!item.code) continue;\r\n const option = document.createElement('option');\r\n option.value = item.code.toUpperCase();\r\n option.textContent = item.name || item.code.toUpperCase();\r\n this.select.appendChild(option);\r\n }\r\n\r\n const defaultValue = this.getAttribute('value');\r\n if (defaultValue) {\r\n this.setValue(defaultValue);\r\n } else {\r\n const client = new ForexClient();\r\n const localeCode = getLocale();\r\n const currencyCode = client.getCode(localeCode);\r\n if (currencyCode) this.setValue(currencyCode);\r\n }\r\n }\r\n\r\n createContainerElement() {\r\n const container = document.createElement('div');\r\n container.setAttribute('class', 'field-select-container');\r\n return container;\r\n }\r\n\r\n createLabelElement() {\r\n const label = document.createElement('label');\r\n label.setAttribute('class', 'field-select-label');\r\n label.setAttribute('for', 'select');\r\n label.textContent = this.getAttribute('label') || 'Select Label';\r\n return label;\r\n }\r\n\r\n createSelectElement() {\r\n const select = document.createElement('select');\r\n select.setAttribute('class', 'field-select-inner');\r\n select.setAttribute(\r\n 'name',\r\n this.getAttribute('name') || 'select-field',\r\n );\r\n\r\n select.addEventListener('change', (e) => this.handleChange(e.target.value));\r\n return select;\r\n }\r\n\r\n handleChange(value) {\r\n const customEvent = new CustomEvent('change', {\r\n detail: { value },\r\n bubbles: true,\r\n composed: true,\r\n });\r\n this.dispatchEvent(customEvent);\r\n }\r\n\r\n setValue(value) {\r\n this.select.value = value;\r\n this.handleChange(value);\r\n }\r\n}\r\n\r\ncustomElements.define('field-select', FieldSelect);\r\n","function debounce(function_, wait, { leading = false } = {}) {\r\n let result;\r\n let timer;\r\n let lastThis;\r\n let lastArguments;\r\n\r\n function invokeFunction() {\r\n if (lastArguments !== undefined) {\r\n result = function_.call(lastThis, ...lastArguments);\r\n timer = lastThis = lastArguments = undefined;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n function debounced(...arguments_) {\r\n lastThis = this;\r\n lastArguments = arguments_;\r\n if (leading && timer === undefined) {\r\n result = invokeFunction();\r\n }\r\n\r\n if (timer) {\r\n clearTimeout(timer);\r\n timer = undefined;\r\n }\r\n\r\n timer = setTimeout(() => {\r\n result = invokeFunction();\r\n }, wait);\r\n return result;\r\n }\r\n\r\n debounced.cancel = () => {\r\n if (timer !== undefined) {\r\n clearTimeout(timer);\r\n }\r\n\r\n timer = lastThis = lastArguments = undefined;\r\n };\r\n\r\n debounced.flush = () => {\r\n return timer === undefined ? result : invokeFunction();\r\n };\r\n\r\n return debounced;\r\n}\r\n\r\nexport default debounce;\r\n","import { ForexClient } from '../../src';\r\nimport formatDate from './format-date';\r\n\r\nasync function getRates(code) {\r\n try {\r\n const date = new Date();\r\n const localData = localStorage.getItem(`${code}-rates`);\r\n if (localData) {\r\n const { time, data } = JSON.parse(localData);\r\n if (formatDate(date) === time) return data;\r\n }\r\n\r\n const client = new ForexClient();\r\n const response = await client.getRates(code);\r\n const result = response.data?.filter((item) => Boolean(item.code));\r\n localStorage.setItem(\r\n `${code}-rates`,\r\n JSON.stringify({ code, time: formatDate(date), data: result }),\r\n );\r\n\r\n return result;\r\n } catch (error) {\r\n console.error('Error fetching options:', error);\r\n }\r\n}\r\n\r\nexport default getRates;\r\n","import './components/icon';\r\nimport './components/input';\r\nimport './components/select';\r\nimport debounce from './utils/debounce';\r\nimport getRates from './utils/get-rates';\r\n\r\n(() => {\r\n const store = {\r\n baseCurrency: '',\r\n destCurrency: '',\r\n baseAmount: 0,\r\n destAmount: 0,\r\n exchangeRate: 1,\r\n };\r\n\r\n const baseCurrencyEl = document.querySelector('#base-currency');\r\n const destCurrencyEl = document.querySelector('#dest-currency');\r\n const baseAmountEl = document.querySelector('#base-amount');\r\n const destAmountEl = document.querySelector('#dest-amount');\r\n const switchButtonEl = document.querySelector('.form-button');\r\n\r\n const onBaseAmountChange = () => {\r\n const value = store.baseAmount * store.exchangeRate;\r\n store.destAmount = value;\r\n destAmountEl.setValue(value.toFixed(2), false);\r\n };\r\n\r\n const onDestAmountChange = () => {\r\n const value = store.destAmount / store.exchangeRate;\r\n store.baseAmount = value;\r\n baseAmountEl.setValue(value.toFixed(2), false);\r\n };\r\n\r\n const onRateChange = (rate = 1) => {\r\n store.exchangeRate = rate;\r\n onBaseAmountChange();\r\n };\r\n\r\n const onCurrenciesChange = debounce(async () => {\r\n if (!store.baseCurrency || !store.destCurrency) return;\r\n\r\n const rates = await getRates(store.baseCurrency);\r\n onRateChange(\r\n rates.find((item) => item.code === store.destCurrency.toLowerCase())\r\n ?.rate,\r\n );\r\n }, 80);\r\n\r\n /* region DOM Listener */\r\n baseCurrencyEl.addEventListener('change', (event) => {\r\n store.baseCurrency = event.detail.value;\r\n onCurrenciesChange();\r\n });\r\n\r\n destCurrencyEl.addEventListener('change', (event) => {\r\n store.destCurrency = event.detail.value;\r\n onCurrenciesChange();\r\n });\r\n\r\n baseAmountEl.addEventListener('change', (event) => {\r\n store.baseAmount = Number(event.detail.value);\r\n onBaseAmountChange();\r\n });\r\n\r\n destAmountEl.addEventListener('change', (event) => {\r\n store.destAmount = Number(event.detail.value);\r\n onDestAmountChange();\r\n });\r\n\r\n switchButtonEl.addEventListener('click', () => {\r\n [store.baseCurrency, store.destCurrency] = [\r\n store.destCurrency,\r\n store.baseCurrency,\r\n ];\r\n baseCurrencyEl.setValue(store.baseCurrency);\r\n destCurrencyEl.setValue(store.destCurrency);\r\n });\r\n /* endregion */\r\n})();\r\n"]} \ No newline at end of file diff --git a/docs/assets/demo-style.css b/docs/assets/demo-style.css new file mode 100644 index 0000000..2bfb826 --- /dev/null +++ b/docs/assets/demo-style.css @@ -0,0 +1,184 @@ +:root { + --viewport-height: 1vh; + --header-height: 3.5rem; + + --header-padding: 0 2rem; + --main-padding: 1.5rem 2rem; + --main-padding-mobile: 1rem; + --navbar-padding: 0 .75rem 0 1.5rem; + --navbar-padding-mobile: 0 1.5rem; + + --nav-column-gap: 1rem; + --section-content-gap: 1rem; + --section-content-form-gap: .5rem; + + --header-title-font-size: 1.5rem; + --navbar-icon-font-size: 1.5rem; + + --border-color: #dcdfe6; + --background-color: #fff; + --anchor-link-color: #666; + --anchor-link-hover-color: #333; + --input-border-color: rgba(0, 0, 0, .23); + --input-hover-border-color: rgba(0, 0, 0, .87); + --input-focus-border-color: rgba(102, 0, 235, 1); + --input-invalid-border-color: rgba(211, 47, 47, 1); + --form-button-background-color: rgba(0, 0, 0, .1); + --form-button-hover-background-color: rgba(102, 0, 235, .1); + + --nav-z-index: 12; + + --transition-duration: .3s; + --transition-bezier: cubic-bezier(.645, .045, .355, 1); +} + +* { + margin: 0; + padding: 0; + box-sizing: border-box; + scrollbar-width: thin; + scrollbar-color: #0003 transparent; +} + +body { + width: 100%; + height: calc(var(--viewport-height, 1vh) * 100); + background-color: var(--background-color); + overflow: auto; +} + +header { + position: sticky; + top: 0; + left: 0; + width: 100%; + z-index: var(--nav-z-index); +} + +header .navbar { + position: relative; + border-bottom: 1px solid var(--border-color); + height: var(--header-height); + padding: var(--navbar-padding); + background-image: radial-gradient(transparent 1px, var(--background-color) 1px); + background-size: 4px 4px; + backdrop-filter: saturate(50%) blur(4px); + -webkit-backdrop-filter: saturate(50%) blur(4px); + top: 0; +} + +header .navbar .wrapper { + display: flex; + justify-content: space-between; + margin: 0 auto; + line-height: var(--header-height); +} + +header .navbar .wrapper .title { + font-size: var(--header-title-font-size); + font-weight: 600; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +nav { + display: flex; + justify-content: space-between; + align-items: center; + gap: var(--nav-column-gap); +} + +main { padding: var(--main-padding); } + +main section.content { + min-height: 64vh; + display: flex; + justify-content: center; + align-items: center; + flex-direction: column; + gap: var(--section-content-gap); +} + +main section.content .form-group { + display: flex; + gap: var(--section-content-form-gap); +} + +main section.content .form-button { + display: flex; + background-color: var(--form-button-background-color); + border-radius: 8px; + transition: var(--transition-duration) var(--transition-bezier); +} + +main section.content .form-button:hover { + background-color: var(--form-button-hover-background-color); +} + +a { + display: inline-flex; + align-items: center; + flex-direction: row; + color: var(--anchor-link-color); + text-decoration: none; + outline: none; + cursor: pointer; + transition: var(--transition-duration) var(--transition-bezier); +} + +a:hover { + color: var(--anchor-link-hover-color); +} + +a .primary { + color: var(--anchor-link-hover-color); +} + +@media (max-width: 769px) { + header .navbar { padding: var(--navbar-padding-mobile); } + + main section.content .form-group { flex-direction: column; } +} + +@media screen and (min-width: 1280px) { + header .navbar { padding: var(--header-padding); } + + main { padding: var(--main-padding-mobile); } +} + +@supports selector(::-webkit-scrollbar) { + *::-webkit-scrollbar { + width: 8px; + height: 8px; + } + + *::-webkit-scrollbar-track { + background: none; + margin: 4px; + } + + *::-webkit-scrollbar-thumb { + border: none; + background-color: #0003; + border-radius: 10px; + } + + *::-webkit-scrollbar-thumb:hover, + *::-webkit-scrollbar-thumb:active { + background-color: #0007; + } + + * { + scrollbar-width: unset; + scrollbar-color: unset; + } +} + +.user-select-none { + user-select: none; + -ms-user-select: none; + -moz-user-select: none; + -webkit-user-select: none; +} diff --git a/docs/assets/highlight.css b/docs/assets/highlight.css new file mode 100644 index 0000000..9232097 --- /dev/null +++ b/docs/assets/highlight.css @@ -0,0 +1,85 @@ +:root { + --light-hl-0: #795E26; + --dark-hl-0: #DCDCAA; + --light-hl-1: #000000; + --dark-hl-1: #D4D4D4; + --light-hl-2: #A31515; + --dark-hl-2: #CE9178; + --light-hl-3: #0000FF; + --dark-hl-3: #569CD6; + --light-hl-4: #0070C1; + --dark-hl-4: #4FC1FF; + --light-hl-5: #AF00DB; + --dark-hl-5: #C586C0; + --light-hl-6: #001080; + --dark-hl-6: #9CDCFE; + --light-hl-7: #008000; + --dark-hl-7: #6A9955; + --light-hl-8: #098658; + --dark-hl-8: #B5CEA8; + --light-code-background: #FFFFFF; + --dark-code-background: #1E1E1E; +} + +@media (prefers-color-scheme: light) { :root { + --hl-0: var(--light-hl-0); + --hl-1: var(--light-hl-1); + --hl-2: var(--light-hl-2); + --hl-3: var(--light-hl-3); + --hl-4: var(--light-hl-4); + --hl-5: var(--light-hl-5); + --hl-6: var(--light-hl-6); + --hl-7: var(--light-hl-7); + --hl-8: var(--light-hl-8); + --code-background: var(--light-code-background); +} } + +@media (prefers-color-scheme: dark) { :root { + --hl-0: var(--dark-hl-0); + --hl-1: var(--dark-hl-1); + --hl-2: var(--dark-hl-2); + --hl-3: var(--dark-hl-3); + --hl-4: var(--dark-hl-4); + --hl-5: var(--dark-hl-5); + --hl-6: var(--dark-hl-6); + --hl-7: var(--dark-hl-7); + --hl-8: var(--dark-hl-8); + --code-background: var(--dark-code-background); +} } + +:root[data-theme='light'] { + --hl-0: var(--light-hl-0); + --hl-1: var(--light-hl-1); + --hl-2: var(--light-hl-2); + --hl-3: var(--light-hl-3); + --hl-4: var(--light-hl-4); + --hl-5: var(--light-hl-5); + --hl-6: var(--light-hl-6); + --hl-7: var(--light-hl-7); + --hl-8: var(--light-hl-8); + --code-background: var(--light-code-background); +} + +:root[data-theme='dark'] { + --hl-0: var(--dark-hl-0); + --hl-1: var(--dark-hl-1); + --hl-2: var(--dark-hl-2); + --hl-3: var(--dark-hl-3); + --hl-4: var(--dark-hl-4); + --hl-5: var(--dark-hl-5); + --hl-6: var(--dark-hl-6); + --hl-7: var(--dark-hl-7); + --hl-8: var(--dark-hl-8); + --code-background: var(--dark-code-background); +} + +.hl-0 { color: var(--hl-0); } +.hl-1 { color: var(--hl-1); } +.hl-2 { color: var(--hl-2); } +.hl-3 { color: var(--hl-3); } +.hl-4 { color: var(--hl-4); } +.hl-5 { color: var(--hl-5); } +.hl-6 { color: var(--hl-6); } +.hl-7 { color: var(--hl-7); } +.hl-8 { color: var(--hl-8); } +pre, code { background: var(--code-background); } diff --git a/docs/assets/icons.js b/docs/assets/icons.js new file mode 100644 index 0000000..3dfbd32 --- /dev/null +++ b/docs/assets/icons.js @@ -0,0 +1,18 @@ +(function() { + addIcons(); + function addIcons() { + if (document.readyState === "loading") return document.addEventListener("DOMContentLoaded", addIcons); + const svg = document.body.appendChild(document.createElementNS("http://www.w3.org/2000/svg", "svg")); + svg.innerHTML = `MMNEPVFCICPMFPCPTTAAATR`; + svg.style.display = "none"; + if (location.protocol === "file:") updateUseElements(); + } + + function updateUseElements() { + document.querySelectorAll("use").forEach(el => { + if (el.getAttribute("href").includes("#icon-")) { + el.setAttribute("href", el.getAttribute("href").replace(/.*#/, "#")); + } + }); + } +})() \ No newline at end of file diff --git a/docs/assets/icons.svg b/docs/assets/icons.svg new file mode 100644 index 0000000..a19417d --- /dev/null +++ b/docs/assets/icons.svg @@ -0,0 +1 @@ +MMNEPVFCICPMFPCPTTAAATR \ No newline at end of file diff --git a/docs/assets/main.js b/docs/assets/main.js new file mode 100644 index 0000000..99097a0 --- /dev/null +++ b/docs/assets/main.js @@ -0,0 +1,60 @@ +"use strict"; +window.translations={"copy":"Copy","copied":"Copied!","normally_hidden":"This member is normally hidden due to your filter settings."}; +"use strict";(()=>{var Pe=Object.create;var ie=Object.defineProperty;var Oe=Object.getOwnPropertyDescriptor;var _e=Object.getOwnPropertyNames;var Re=Object.getPrototypeOf,Me=Object.prototype.hasOwnProperty;var Fe=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var De=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of _e(e))!Me.call(t,i)&&i!==n&&ie(t,i,{get:()=>e[i],enumerable:!(r=Oe(e,i))||r.enumerable});return t};var Ae=(t,e,n)=>(n=t!=null?Pe(Re(t)):{},De(e||!t||!t.__esModule?ie(n,"default",{value:t,enumerable:!0}):n,t));var ue=Fe((ae,le)=>{(function(){var t=function(e){var n=new t.Builder;return n.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),n.searchPipeline.add(t.stemmer),e.call(n,n),n.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){return function(n){e.console&&console.warn&&console.warn(n)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var n=Object.create(null),r=Object.keys(e),i=0;i0){var d=t.utils.clone(n)||{};d.position=[a,u],d.index=s.length,s.push(new t.Token(r.slice(a,o),d))}a=o+1}}return s},t.tokenizer.separator=/[\s\-]+/;t.Pipeline=function(){this._stack=[]},t.Pipeline.registeredFunctions=Object.create(null),t.Pipeline.registerFunction=function(e,n){n in this.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+n),e.label=n,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){var n=e.label&&e.label in this.registeredFunctions;n||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index. +`,e)},t.Pipeline.load=function(e){var n=new t.Pipeline;return e.forEach(function(r){var i=t.Pipeline.registeredFunctions[r];if(i)n.add(i);else throw new Error("Cannot load unregistered function: "+r)}),n},t.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach(function(n){t.Pipeline.warnIfFunctionNotRegistered(n),this._stack.push(n)},this)},t.Pipeline.prototype.after=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");r=r+1,this._stack.splice(r,0,n)},t.Pipeline.prototype.before=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");this._stack.splice(r,0,n)},t.Pipeline.prototype.remove=function(e){var n=this._stack.indexOf(e);n!=-1&&this._stack.splice(n,1)},t.Pipeline.prototype.run=function(e){for(var n=this._stack.length,r=0;r1&&(oe&&(r=s),o!=e);)i=r-n,s=n+Math.floor(i/2),o=this.elements[s*2];if(o==e||o>e)return s*2;if(ol?d+=2:a==l&&(n+=r[u+1]*i[d+1],u+=2,d+=2);return n},t.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},t.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),n=1,r=0;n0){var o=s.str.charAt(0),a;o in s.node.edges?a=s.node.edges[o]:(a=new t.TokenSet,s.node.edges[o]=a),s.str.length==1&&(a.final=!0),i.push({node:a,editsRemaining:s.editsRemaining,str:s.str.slice(1)})}if(s.editsRemaining!=0){if("*"in s.node.edges)var l=s.node.edges["*"];else{var l=new t.TokenSet;s.node.edges["*"]=l}if(s.str.length==0&&(l.final=!0),i.push({node:l,editsRemaining:s.editsRemaining-1,str:s.str}),s.str.length>1&&i.push({node:s.node,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)}),s.str.length==1&&(s.node.final=!0),s.str.length>=1){if("*"in s.node.edges)var u=s.node.edges["*"];else{var u=new t.TokenSet;s.node.edges["*"]=u}s.str.length==1&&(u.final=!0),i.push({node:u,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)})}if(s.str.length>1){var d=s.str.charAt(0),m=s.str.charAt(1),p;m in s.node.edges?p=s.node.edges[m]:(p=new t.TokenSet,s.node.edges[m]=p),s.str.length==1&&(p.final=!0),i.push({node:p,editsRemaining:s.editsRemaining-1,str:d+s.str.slice(2)})}}}return r},t.TokenSet.fromString=function(e){for(var n=new t.TokenSet,r=n,i=0,s=e.length;i=e;n--){var r=this.uncheckedNodes[n],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(n){var r=new t.QueryParser(e,n);r.parse()})},t.Index.prototype.query=function(e){for(var n=new t.Query(this.fields),r=Object.create(null),i=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),l=0;l1?this._b=1:this._b=e},t.Builder.prototype.k1=function(e){this._k1=e},t.Builder.prototype.add=function(e,n){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=n||{},this.documentCount+=1;for(var s=0;s=this.length)return t.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},t.QueryLexer.prototype.width=function(){return this.pos-this.start},t.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},t.QueryLexer.prototype.backup=function(){this.pos-=1},t.QueryLexer.prototype.acceptDigitRun=function(){var e,n;do e=this.next(),n=e.charCodeAt(0);while(n>47&&n<58);e!=t.QueryLexer.EOS&&this.backup()},t.QueryLexer.prototype.more=function(){return this.pos1&&(e.backup(),e.emit(t.QueryLexer.TERM)),e.ignore(),e.more())return t.QueryLexer.lexText},t.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.EDIT_DISTANCE),t.QueryLexer.lexText},t.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.BOOST),t.QueryLexer.lexText},t.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(t.QueryLexer.TERM)},t.QueryLexer.termSeparator=t.tokenizer.separator,t.QueryLexer.lexText=function(e){for(;;){var n=e.next();if(n==t.QueryLexer.EOS)return t.QueryLexer.lexEOS;if(n.charCodeAt(0)==92){e.escapeCharacter();continue}if(n==":")return t.QueryLexer.lexField;if(n=="~")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexEditDistance;if(n=="^")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexBoost;if(n=="+"&&e.width()===1||n=="-"&&e.width()===1)return e.emit(t.QueryLexer.PRESENCE),t.QueryLexer.lexText;if(n.match(t.QueryLexer.termSeparator))return t.QueryLexer.lexTerm}},t.QueryParser=function(e,n){this.lexer=new t.QueryLexer(e),this.query=n,this.currentClause={},this.lexemeIdx=0},t.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=t.QueryParser.parseClause;e;)e=e(this);return this.query},t.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},t.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},t.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},t.QueryParser.parseClause=function(e){var n=e.peekLexeme();if(n!=null)switch(n.type){case t.QueryLexer.PRESENCE:return t.QueryParser.parsePresence;case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expected either a field or a term, found "+n.type;throw n.str.length>=1&&(r+=" with value '"+n.str+"'"),new t.QueryParseError(r,n.start,n.end)}},t.QueryParser.parsePresence=function(e){var n=e.consumeLexeme();if(n!=null){switch(n.str){case"-":e.currentClause.presence=t.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=t.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator'"+n.str+"'";throw new t.QueryParseError(r,n.start,n.end)}var i=e.peekLexeme();if(i==null){var r="expecting term or field, found nothing";throw new t.QueryParseError(r,n.start,n.end)}switch(i.type){case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expecting term or field, found '"+i.type+"'";throw new t.QueryParseError(r,i.start,i.end)}}},t.QueryParser.parseField=function(e){var n=e.consumeLexeme();if(n!=null){if(e.query.allFields.indexOf(n.str)==-1){var r=e.query.allFields.map(function(o){return"'"+o+"'"}).join(", "),i="unrecognised field '"+n.str+"', possible fields: "+r;throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.fields=[n.str];var s=e.peekLexeme();if(s==null){var i="expecting term, found nothing";throw new t.QueryParseError(i,n.start,n.end)}switch(s.type){case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var i="expecting term, found '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseTerm=function(e){var n=e.consumeLexeme();if(n!=null){e.currentClause.term=n.str.toLowerCase(),n.str.indexOf("*")!=-1&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(r==null){e.nextClause();return}switch(r.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+r.type+"'";throw new t.QueryParseError(i,r.start,r.end)}}},t.QueryParser.parseEditDistance=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.editDistance=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseBoost=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="boost must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.boost=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},function(e,n){typeof define=="function"&&define.amd?define(n):typeof ae=="object"?le.exports=n():e.lunr=n()}(this,function(){return t})})()});var se=[];function G(t,e){se.push({selector:e,constructor:t})}var U=class{constructor(){this.alwaysVisibleMember=null;this.createComponents(document.body),this.ensureFocusedElementVisible(),this.listenForCodeCopies(),window.addEventListener("hashchange",()=>this.ensureFocusedElementVisible()),document.body.style.display||(this.ensureFocusedElementVisible(),this.updateIndexVisibility(),this.scrollToHash())}createComponents(e){se.forEach(n=>{e.querySelectorAll(n.selector).forEach(r=>{r.dataset.hasInstance||(new n.constructor({el:r,app:this}),r.dataset.hasInstance=String(!0))})})}filterChanged(){this.ensureFocusedElementVisible()}showPage(){document.body.style.display&&(document.body.style.removeProperty("display"),this.ensureFocusedElementVisible(),this.updateIndexVisibility(),this.scrollToHash())}scrollToHash(){if(location.hash){let e=document.getElementById(location.hash.substring(1));if(!e)return;e.scrollIntoView({behavior:"instant",block:"start"})}}ensureActivePageVisible(){let e=document.querySelector(".tsd-navigation .current"),n=e?.parentElement;for(;n&&!n.classList.contains(".tsd-navigation");)n instanceof HTMLDetailsElement&&(n.open=!0),n=n.parentElement;if(e&&!Ve(e)){let r=e.getBoundingClientRect().top-document.documentElement.clientHeight/4;document.querySelector(".site-menu").scrollTop=r,document.querySelector(".col-sidebar").scrollTop=r}}updateIndexVisibility(){let e=document.querySelector(".tsd-index-content"),n=e?.open;e&&(e.open=!0),document.querySelectorAll(".tsd-index-section").forEach(r=>{r.style.display="block";let i=Array.from(r.querySelectorAll(".tsd-index-link")).every(s=>s.offsetParent==null);r.style.display=i?"none":"block"}),e&&(e.open=n)}ensureFocusedElementVisible(){if(this.alwaysVisibleMember&&(this.alwaysVisibleMember.classList.remove("always-visible"),this.alwaysVisibleMember.firstElementChild.remove(),this.alwaysVisibleMember=null),!location.hash)return;let e=document.getElementById(location.hash.substring(1));if(!e)return;let n=e.parentElement;for(;n&&n.tagName!=="SECTION";)n=n.parentElement;if(!n)return;let r=n.offsetParent==null,i=n;for(;i!==document.body;)i instanceof HTMLDetailsElement&&(i.open=!0),i=i.parentElement;if(n.offsetParent==null){this.alwaysVisibleMember=n,n.classList.add("always-visible");let s=document.createElement("p");s.classList.add("warning"),s.textContent=window.translations.normally_hidden,n.prepend(s)}r&&e.scrollIntoView()}listenForCodeCopies(){document.querySelectorAll("pre > button").forEach(e=>{let n;e.addEventListener("click",()=>{e.previousElementSibling instanceof HTMLElement&&navigator.clipboard.writeText(e.previousElementSibling.innerText.trim()),e.textContent=window.translations.copied,e.classList.add("visible"),clearTimeout(n),n=setTimeout(()=>{e.classList.remove("visible"),n=setTimeout(()=>{e.textContent=window.translations.copy},100)},1e3)})})}};function Ve(t){let e=t.getBoundingClientRect(),n=Math.max(document.documentElement.clientHeight,window.innerHeight);return!(e.bottom<0||e.top-n>=0)}var oe=(t,e=100)=>{let n;return()=>{clearTimeout(n),n=setTimeout(()=>t(),e)}};var pe=Ae(ue());async function ce(t,e){if(!window.searchData)return;let n=await fetch(window.searchData),r=new Blob([await n.arrayBuffer()]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();t.data=i,t.index=pe.Index.load(i.index),e.classList.remove("loading"),e.classList.add("ready")}function fe(){let t=document.getElementById("tsd-search");if(!t)return;let e={base:t.dataset.base+"/"},n=document.getElementById("tsd-search-script");t.classList.add("loading"),n&&(n.addEventListener("error",()=>{t.classList.remove("loading"),t.classList.add("failure")}),n.addEventListener("load",()=>{ce(e,t)}),ce(e,t));let r=document.querySelector("#tsd-search input"),i=document.querySelector("#tsd-search .results");if(!r||!i)throw new Error("The input field or the result list wrapper was not found");i.addEventListener("mouseup",()=>{te(t)}),r.addEventListener("focus",()=>t.classList.add("has-focus")),He(t,i,r,e)}function He(t,e,n,r){n.addEventListener("input",oe(()=>{Ne(t,e,n,r)},200)),n.addEventListener("keydown",i=>{i.key=="Enter"?Be(e,t):i.key=="ArrowUp"?(de(e,n,-1),i.preventDefault()):i.key==="ArrowDown"&&(de(e,n,1),i.preventDefault())}),document.body.addEventListener("keypress",i=>{i.altKey||i.ctrlKey||i.metaKey||!n.matches(":focus")&&i.key==="/"&&(i.preventDefault(),n.focus())}),document.body.addEventListener("keyup",i=>{t.classList.contains("has-focus")&&(i.key==="Escape"||!e.matches(":focus-within")&&!n.matches(":focus"))&&(n.blur(),te(t))})}function te(t){t.classList.remove("has-focus")}function Ne(t,e,n,r){if(!r.index||!r.data)return;e.textContent="";let i=n.value.trim(),s;if(i){let o=i.split(" ").map(a=>a.length?`*${a}*`:"").join(" ");s=r.index.search(o)}else s=[];for(let o=0;oa.score-o.score);for(let o=0,a=Math.min(10,s.length);o`,d=he(l.name,i);globalThis.DEBUG_SEARCH_WEIGHTS&&(d+=` (score: ${s[o].score.toFixed(2)})`),l.parent&&(d=` + ${he(l.parent,i)}.${d}`);let m=document.createElement("li");m.classList.value=l.classes??"";let p=document.createElement("a");p.href=r.base+l.url,p.innerHTML=u+d,m.append(p),p.addEventListener("focus",()=>{e.querySelector(".current")?.classList.remove("current"),m.classList.add("current")}),e.appendChild(m)}}function de(t,e,n){let r=t.querySelector(".current");if(!r)r=t.querySelector(n==1?"li:first-child":"li:last-child"),r&&r.classList.add("current");else{let i=r;if(n===1)do i=i.nextElementSibling??void 0;while(i instanceof HTMLElement&&i.offsetParent==null);else do i=i.previousElementSibling??void 0;while(i instanceof HTMLElement&&i.offsetParent==null);i?(r.classList.remove("current"),i.classList.add("current")):n===-1&&(r.classList.remove("current"),e.focus())}}function Be(t,e){let n=t.querySelector(".current");if(n||(n=t.querySelector("li:first-child")),n){let r=n.querySelector("a");r&&(window.location.href=r.href),te(e)}}function he(t,e){if(e==="")return t;let n=t.toLocaleLowerCase(),r=e.toLocaleLowerCase(),i=[],s=0,o=n.indexOf(r);for(;o!=-1;)i.push(ee(t.substring(s,o)),`${ee(t.substring(o,o+r.length))}`),s=o+r.length,o=n.indexOf(r,s);return i.push(ee(t.substring(s))),i.join("")}var je={"&":"&","<":"<",">":">","'":"'",'"':"""};function ee(t){return t.replace(/[&<>"'"]/g,e=>je[e])}var I=class{constructor(e){this.el=e.el,this.app=e.app}};var F="mousedown",ye="mousemove",N="mouseup",J={x:0,y:0},me=!1,ne=!1,qe=!1,D=!1,ve=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);document.documentElement.classList.add(ve?"is-mobile":"not-mobile");ve&&"ontouchstart"in document.documentElement&&(qe=!0,F="touchstart",ye="touchmove",N="touchend");document.addEventListener(F,t=>{ne=!0,D=!1;let e=F=="touchstart"?t.targetTouches[0]:t;J.y=e.pageY||0,J.x=e.pageX||0});document.addEventListener(ye,t=>{if(ne&&!D){let e=F=="touchstart"?t.targetTouches[0]:t,n=J.x-(e.pageX||0),r=J.y-(e.pageY||0);D=Math.sqrt(n*n+r*r)>10}});document.addEventListener(N,()=>{ne=!1});document.addEventListener("click",t=>{me&&(t.preventDefault(),t.stopImmediatePropagation(),me=!1)});var X=class extends I{constructor(e){super(e),this.className=this.el.dataset.toggle||"",this.el.addEventListener(N,n=>this.onPointerUp(n)),this.el.addEventListener("click",n=>n.preventDefault()),document.addEventListener(F,n=>this.onDocumentPointerDown(n)),document.addEventListener(N,n=>this.onDocumentPointerUp(n))}setActive(e){if(this.active==e)return;this.active=e,document.documentElement.classList.toggle("has-"+this.className,e),this.el.classList.toggle("active",e);let n=(this.active?"to-has-":"from-has-")+this.className;document.documentElement.classList.add(n),setTimeout(()=>document.documentElement.classList.remove(n),500)}onPointerUp(e){D||(this.setActive(!0),e.preventDefault())}onDocumentPointerDown(e){if(this.active){if(e.target.closest(".col-sidebar, .tsd-filter-group"))return;this.setActive(!1)}}onDocumentPointerUp(e){if(!D&&this.active&&e.target.closest(".col-sidebar")){let n=e.target.closest("a");if(n){let r=window.location.href;r.indexOf("#")!=-1&&(r=r.substring(0,r.indexOf("#"))),n.href.substring(0,r.length)==r&&setTimeout(()=>this.setActive(!1),250)}}}};var re;try{re=localStorage}catch{re={getItem(){return null},setItem(){}}}var Q=re;var ge=document.head.appendChild(document.createElement("style"));ge.dataset.for="filters";var Y=class extends I{constructor(e){super(e),this.key=`filter-${this.el.name}`,this.value=this.el.checked,this.el.addEventListener("change",()=>{this.setLocalStorage(this.el.checked)}),this.setLocalStorage(this.fromLocalStorage()),ge.innerHTML+=`html:not(.${this.key}) .tsd-is-${this.el.name} { display: none; } +`,this.app.updateIndexVisibility()}fromLocalStorage(){let e=Q.getItem(this.key);return e?e==="true":this.el.checked}setLocalStorage(e){Q.setItem(this.key,e.toString()),this.value=e,this.handleValueChange()}handleValueChange(){this.el.checked=this.value,document.documentElement.classList.toggle(this.key,this.value),this.app.filterChanged(),this.app.updateIndexVisibility()}};var Z=class extends I{constructor(e){super(e),this.summary=this.el.querySelector(".tsd-accordion-summary"),this.icon=this.summary.querySelector("svg"),this.key=`tsd-accordion-${this.summary.dataset.key??this.summary.textContent.trim().replace(/\s+/g,"-").toLowerCase()}`;let n=Q.getItem(this.key);this.el.open=n?n==="true":this.el.open,this.el.addEventListener("toggle",()=>this.update());let r=this.summary.querySelector("a");r&&r.addEventListener("click",()=>{location.assign(r.href)}),this.update()}update(){this.icon.style.transform=`rotate(${this.el.open?0:-90}deg)`,Q.setItem(this.key,this.el.open.toString())}};function Ee(t){let e=Q.getItem("tsd-theme")||"os";t.value=e,xe(e),t.addEventListener("change",()=>{Q.setItem("tsd-theme",t.value),xe(t.value)})}function xe(t){document.documentElement.dataset.theme=t}var K;function we(){let t=document.getElementById("tsd-nav-script");t&&(t.addEventListener("load",Le),Le())}async function Le(){let t=document.getElementById("tsd-nav-container");if(!t||!window.navigationData)return;let n=await(await fetch(window.navigationData)).arrayBuffer(),r=new Blob([n]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();K=t.dataset.base,K.endsWith("/")||(K+="/"),t.innerHTML="";for(let s of i)Se(s,t,[]);window.app.createComponents(t),window.app.showPage(),window.app.ensureActivePageVisible()}function Se(t,e,n){let r=e.appendChild(document.createElement("li"));if(t.children){let i=[...n,t.text],s=r.appendChild(document.createElement("details"));s.className=t.class?`${t.class} tsd-accordion`:"tsd-accordion";let o=s.appendChild(document.createElement("summary"));o.className="tsd-accordion-summary",o.dataset.key=i.join("$"),o.innerHTML='',be(t,o);let a=s.appendChild(document.createElement("div"));a.className="tsd-accordion-details";let l=a.appendChild(document.createElement("ul"));l.className="tsd-nested-navigation";for(let u of t.children)Se(u,l,i)}else be(t,r,t.class)}function be(t,e,n){if(t.path){let r=e.appendChild(document.createElement("a"));r.href=K+t.path,n&&(r.className=n),location.pathname===r.pathname&&!r.href.includes("#")&&r.classList.add("current"),t.kind&&(r.innerHTML=``),r.appendChild(document.createElement("span")).textContent=t.text}else{let r=e.appendChild(document.createElement("span"));r.innerHTML='',r.appendChild(document.createElement("span")).textContent=t.text}}G(X,"a[data-toggle]");G(Z,".tsd-accordion");G(Y,".tsd-filter-item input[type=checkbox]");var Te=document.getElementById("tsd-theme");Te&&Ee(Te);var $e=new U;Object.defineProperty(window,"app",{value:$e});fe();we();})(); +/*! Bundled license information: + +lunr/lunr.js: + (** + * lunr - http://lunrjs.com - A bit like Solr, but much smaller and not as bright - 2.3.9 + * Copyright (C) 2020 Oliver Nightingale + * @license MIT + *) + (*! + * lunr.utils + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Set + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.tokenizer + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Pipeline + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Vector + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.stemmer + * Copyright (C) 2020 Oliver Nightingale + * Includes code from - http://tartarus.org/~martin/PorterStemmer/js.txt + *) + (*! + * lunr.stopWordFilter + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.trimmer + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.TokenSet + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Index + * Copyright (C) 2020 Oliver Nightingale + *) + (*! + * lunr.Builder + * Copyright (C) 2020 Oliver Nightingale + *) +*/ diff --git a/docs/assets/material-style.css b/docs/assets/material-style.css new file mode 100644 index 0000000..754d865 --- /dev/null +++ b/docs/assets/material-style.css @@ -0,0 +1,335 @@ +@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&family=Space+Mono:ital,wght@0,400;0,700;1,400;1,700&display=swap"); + +:root, +:root[data-theme="light"], +:root[data-theme="dark"] { + --font-sans: "Space Grotesk", sans-serif; + --font-mono: "Space Mono", monospace; + + --color-background: var(--md-sys-color-surface-container); + --color-background-secondary: var(--md-sys-color-surface-container-high); + --color-background-warning: var(--md-sys-color-error-container); + --color-warning-text: var(--md-sys-color-on-error-container); + --color-icon-background: var(--md-sys-color-on-primary); + --color-accent: var(--md-sys-color-secondary-container); + --color-active-menu-item: var(--md-sys-color-surface-container-highest); + --color-text: var(--md-sys-color-on-surface); + --color-text-aside: var(--md-sys-color-on-surface-variant); + --color-link: var(--md-sys-color-primary); + + --color-ts-project: var(--md-sys-color-secondary); + --color-ts-module: var(--color-ts-project); + --color-ts-namespace: var(--color-ts-project); + + --color-ts-enum: var(--md-sys-color-tertiary); + --color-ts-enum-member: var(--color-ts-enum); + + --color-ts-variable: var(--md-sys-color-primary); + --color-ts-function: var(--md-sys-color-secondary); + --color-ts-class: var(--md-sys-color-tertiary); + --color-ts-interface: var(--md-sys-color-tertiary); + + --color-ts-constructor: var(--md-sys-color-inverse-primary); + + --color-ts-property: var(--md-sys-color-on-background); + --color-ts-method: var(--color-ts-function); + + --color-ts-call-signature: var(--color-ts-method); + --color-ts-index-signature: var(--color-ts-property); /* ? */ + --color-ts-constructor-signature: var(--color-ts-function); + --color-ts-parameter: var(--md-sys-color-primary); + + --color-ts-type-parameter: var(--md-sys-color-tertiary); + --color-ts-accessor: var(--color-ts-property); + --color-ts-get-signature: var(--color-ts-accessor); + --color-ts-set-signature: var(--color-ts-accessor); + --color-ts-type-alias: var(--md-sys-color-tertiary); + + /* --external-icon: var(--md-sys-external-icon); + --color-scheme: var(--md-sys-color-scheme); */ + + --top-app-bar-height: 4.5rem; + --top-app-bar-padding-vertical: .5rem; + --top-app-bar-table-cell-gutter: 1.5rem; + --top-app-bar-search-icon-width: 4rem; + --top-app-bar-search-padding-inset: 1.5rem; + --top-app-bar-search-padding-inset-mobile: 1rem; + --top-app-bar-search-font-size: 1.125rem; + --top-app-bar-search-font-size-mobile: 1rem; + --footer-height: 3.5rem; + + --safe-area-inset-top: env(safe-area-inset-top); +} + +body { + font-family: var(--font-sans); +} +code, +pre { + font-family: var(--font-mono); +} + +img { + max-width: 100%; +} + +@supports not selector(::-webkit-scrollbar) { + * { + scrollbar-width: thin; + scrollbar-color: var(--color-accent) transparent; + } +} + +@supports selector(::-webkit-scrollbar) { + *::-webkit-scrollbar { + width: 8px; + height: 8px; + } + *::-webkit-scrollbar-track { + background: none; + margin: 4px; + } + *::-webkit-scrollbar-thumb { + border: none; + } + *::-webkit-scrollbar-thumb:hover, + *::-webkit-scrollbar-thumb:active { + background-color: var(--md-sys-color-secondary); + } + * { + scrollbar-width: unset; + scrollbar-color: unset; + } +} + +.container-main { + min-height: calc(100vh - var(--top-app-bar-height) - var(--footer-height)); +} +.col-content { + overflow: hidden; + box-sizing: border-box; + padding: 1.75rem; + border-radius: 28px; + background-color: var(--md-sys-color-surface); +} +.page-menu { + height: fit-content; + padding: 0.75rem 1.75rem; + border-radius: 28px; + background-color: var(--md-sys-color-surface); +} +.site-menu > *, +.page-menu > * { + position: relative; +} +.title { + display: inline-block; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + font-size: 22px; +} +.tsd-page-title { + word-break: break-all; +} +.tsd-page-toolbar { + padding: var(--top-app-bar-padding-vertical) 0; + height: calc(var(--top-app-bar-height) - 16px); + background-color: var(--color-background); + border-bottom: none; +} +.tsd-page-toolbar .tsd-toolbar-contents { + height: 56px; +} +.tsd-page-toolbar .table-cell { + height: 56px; + padding-left: var(--top-app-bar-table-cell-gutter); +} +.tsd-page-toolbar .tsd-toolbar-icon { + padding: 20px 0; +} +#tsd-search { + display: flex; + flex-direction: row-reverse; + justify-content: space-between; + line-height: 56px; + border-radius: 22px; + padding-right: var(--top-app-bar-search-icon-width); + box-sizing: border-box; + padding-left: 0; + margin-left: var(--top-app-bar-table-cell-gutter); + max-width: calc(100% - var(--top-app-bar-table-cell-gutter) - var(--top-app-bar-table-cell-gutter)); +} +#tsd-search .field, +#tsd-search .field label, +#tsd-search .field #tsd-toolbar-links { + position: relative; + top: unset; + right: unset; + bottom: unset; + left: unset; +} +#tsd-search .field { + position: relative; + flex: 0 0 0; +} +#tsd-search .field:first-child { + display: flex; + flex-direction: row-reverse; + width: 100%; + position: absolute; + left: 0; +} +#tsd-search.has-focus .field:first-child { + z-index: 2; +} +#tsd-search .field label, +#tsd-search .field .tsd-toolbar-icon { + height: 100%; + margin: 0 auto; +} +#tsd-search .field .tsd-toolbar-icon { + display: flex; + justify-content: center; + flex: none; +} +#tsd-search .field .tsd-widget.no-caption { + width: var(--top-app-bar-search-icon-width); +} +#tsd-search .field input { + padding: var(--top-app-bar-search-padding-inset); + font-size: var(--top-app-bar-search-font-size); + top: calc(-100% - var(--top-app-bar-padding-vertical) - var(--safe-area-inset-top)); +} +#tsd-search .results { + z-index: -1; + top: calc(56px - 22px); + left: 0; + padding-top: 22px; + box-shadow: 0px 4px 2px rgba(0, 0, 0, 0.125); + background-color: var(--color-background-secondary); + border-bottom-left-radius: 22px; + border-bottom-right-radius: 22px; + overflow: hidden; +} +#tsd-search .results li { + background: none; +} +#tsd-search .results a { + padding: 1rem 0.25rem; +} +.col-sidebar { + padding-top: 0; + margin-right: 1rem; +} + +.tsd-signature { + padding: 1rem 1.5rem; + border-radius: 24px; + background-color: var(--md-sys-color-surface-container); +} + +.tsd-page-navigation ul { + padding-left: 0.44rem; +} +.tsd-navigation a, +.tsd-navigation summary > span, +.tsd-page-navigation a { + padding: 0.88rem; + border-radius: 24px; +} +.tsd-navigation a:hover, +.tsd-page-navigation a:hover { + text-decoration: none; + background-color: var(--md-sys-color-surface-container-high); +} +.page-menu .tsd-accordion-summary svg { + position: absolute; + right: 0; +} +.site-menu .tsd-navigation .tsd-accordion-summary { + display: flex; + flex-direction: row-reverse; + width: 100%; +} + +.tsd-small-nested-navigation { + margin-left: 1rem; +} +.tsd-nested-navigation { + margin-left: 2.5rem; +} +.tsd-nested-navigation > li > a, +.tsd-nested-navigation > li > span { + width: 100%; +} +.tsd-navigation > a, +.tsd-navigation .tsd-accordion-summary { + width: 100%; +} +.tsd-accordion .tsd-accordion-summary > svg, +.tsd-index-accordion .tsd-accordion-summary > svg { + position: absolute; + right: 1.5rem; +} +.tsd-accordion-summary .tsd-kind-icon ~ span { + margin-right: 2.5rem; +} +.tsd-accordion-summary .tsd-nested-navigation > li > a, +.tsd-nested-navigation > li > span { + width: calc(100% - 0.44rem); +} +.tsd-kind-icon ~ span { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} +.tsd-generator { + padding: 0; + border-top: none; + height: var(--footer-height); + line-height: var(--footer-height); +} +.tsd-generator > p { + padding: 0 2rem; +} + +@media (max-width: 769px) { + #tsd-search { + max-width: calc(100% - var(--top-app-bar-search-icon-width) - var(--top-app-bar-table-cell-gutter)); + } + #tsd-search .field input { + font-size: var(--top-app-bar-search-font-size); + padding: var(--top-app-bar-search-padding-inset-mobile); + } + .container { + padding: 1rem; + } + .col-sidebar { + margin-right: 0; + } +} +@media (min-width: 770px) { + .container-main { + margin: 0 auto; + } + .site-menu { + margin-right: 0.5rem; + } +} +@media (min-width: 1200px) { + .page-menu, + .site-menu { + max-height: calc(100vh - var(--footer-height) - var(--top-app-bar-height)); + top: var(--top-app-bar-height); + } + .site-menu { + margin-top: 0; + } + .page-menu { + margin-left: 1rem; + } + .col-sidebar { + margin-right: 0; + } +} diff --git a/docs/assets/navigation.js b/docs/assets/navigation.js new file mode 100644 index 0000000..f5db7db --- /dev/null +++ b/docs/assets/navigation.js @@ -0,0 +1 @@ +window.navigationData = "data:application/octet-stream;base64,H4sIAAAAAAAACp2TzU7CQBCA32XPIH8BKzEmtdRAQlpTxMQQ06ztSjeUtnYXUmJMvPkAJr6Fnr34NkRfwy3QdoGyENrb9ptvpjM7g2dAUURBE/x9vc5/3uffn78fb6AAAkgddmr71mSMPEpKJntOHDp22ccR9mzQlGqS1ChLL4XUwY5RlAWPfXviIlJaHK/HVgvAcrBrh8gDzUEquJR7qtk3upljCkMMHzJLQqzralWuigQxb1Wj19G1/bKEFEi7uiJ3VVPpG4aqKXe7nRugQKnpmtm7kbWWbLRMRW+pvd3WbVYgvvJDFCkuZnPLjJYLCUl9HLIuqlSlfJMeUOx7JBNij6LwEVp5zhW8MfN6g1PLU4jd+BeVSchugTUTmLdYkVgP8RB70FUjy4HeEBmQIq5sOgtSby664S6fnVbqfHd5WFAzj4nKbVMaGOhpgsgBLd6G96tJwDBRpTwm0p0vIlm7LnatuJkQ5kHb3kbQRiHpeJjmz4fzcWzugArLCx4LiF3EpMhSLEIB9wfX2BrtzRRDx6cwkOWH9t4kS+z4NPHMxBvO9y6FRbvO3a0DnSt6W3ofv//0hEGNWwYAAA==" \ No newline at end of file diff --git a/docs/assets/search.js b/docs/assets/search.js new file mode 100644 index 0000000..4fc35e3 --- /dev/null +++ b/docs/assets/search.js @@ -0,0 +1 @@ +window.searchData = "data:application/octet-stream;base64,H4sIAAAAAAAACsWd3W4byXKAXyXQ3jo+UzX/B0GAFSXTskRaK1Las14sBFmiZa5FSitS3j8skLs8QIC8RXKdm7zNQfIa4TT1U9VTpIrlWiQXJ5aW09PkfF1dXV839fvW7fXPs62/fv/71qfx9GLrr1VaVUVSvdiank1GW3/d+t///Je///e//f2//uN//v1ft15s3d1eLX55cX1+NxlN57O/nC7+7+XH+eRq8d/Or85ms9Gisa2tP148tIePLS1+HP3y2MTk+uLuajT7S/jt2hbSpya2vx7snh4fHTy28vnsdnz2/qmdhxcIDb7Yujm7XfT5sSdr73B6sns02Hvbf/ZODy803/Hgbefrg93TzvHR0W6/893KG0av2+x+RZ6nxeMtT0/nv96MNrrTV4/XrLlhfCXpACSYPd7/6x3LvV+Gyza4/cv7Pq/qxa6tF7u+vXhl68Ur3150bb3o+vZiz9aLPd9erA4va3tx4NuLnq0XPd9evLX14q1vL45svTjy7cXA1ouBby+Gtl4MfXtxbOvFsW8vvrX14lvfXvzN1ou/+fbina0X71x7sf21qRfhMsdebNt6se3bC1uWs+2b5Wzbspxt3yxn25blbPtmOdu2LGfbN8vZfm3rxWvfXthyrW3fXGv7ja0Xb3x7Ycv4tn0zvm1bxrftm/Ftr17yru1F37cXtrxz2zfv3P7G1otvfHthy363fbPfbVv2u+2b/W7bst9t3+x3+8TWixPfXtiy323f7Hd7s4rVYy++8+2FLfvd9s1+O7bst+Ob/XY6tl50fHthy347vtlvx5Z3dnzzzo4t7+z45p0dW97Z8c07O7a8s+Obd3b2bb3Y9+2FLe/s+OadHVve2fHNOzu2vLPjm3d2bHlnxzfv7Ngyvo5vxtex1fg6vjW+ji3X6vjmWh1brtXxzbU6tkpjx7fSu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855iGQHrJXeds5DJDtirfS2cx4i2SFrpbed8xDJjlkrve2ch0h20FrpbeecHXbUWult5zy8UW+LSm87/5k3QUeC0tvOeWyi3haV3vaOH4lK2RcI6Oi841GBeltUets7Tid1rah0rXe82EFdKypd6x2fLahrRaVrvYueCKVT6Vo/R0+E0ql0rZ/5hENdKypd6+foKx0onUrX+plzQV0rKl3rZ57kUteKStf6mUetjH05hY7Oz3e8CUqn0pH+zCdf6khR6Uh/5oBTR4pKR/pr9FApnUq1+SuPnVRtolJt/sYBp2oTlWrzNx4vqNpEpdr8jYdfqjZRozZ/eLF1M74ZXY2ni2u+/+GPP/4PrawE4o81AQA="; \ No newline at end of file diff --git a/docs/assets/style.css b/docs/assets/style.css new file mode 100644 index 0000000..178bfb0 --- /dev/null +++ b/docs/assets/style.css @@ -0,0 +1,1493 @@ +:root { + /* Light */ + --light-color-background: #f2f4f8; + --light-color-background-secondary: #eff0f1; + --light-color-warning-text: #222; + --light-color-background-warning: #e6e600; + --light-color-accent: #c5c7c9; + --light-color-active-menu-item: var(--light-color-accent); + --light-color-text: #222; + --light-color-text-aside: #6e6e6e; + + --light-color-icon-background: var(--light-color-background); + --light-color-icon-text: var(--light-color-text); + + --light-color-comment-tag-text: var(--light-color-text); + --light-color-comment-tag: var(--light-color-background); + + --light-color-link: #1f70c2; + --light-color-focus-outline: #3584e4; + + --light-color-ts-keyword: #056bd6; + --light-color-ts-project: #b111c9; + --light-color-ts-module: var(--light-color-ts-project); + --light-color-ts-namespace: var(--light-color-ts-project); + --light-color-ts-enum: #7e6f15; + --light-color-ts-enum-member: var(--light-color-ts-enum); + --light-color-ts-variable: #4760ec; + --light-color-ts-function: #572be7; + --light-color-ts-class: #1f70c2; + --light-color-ts-interface: #108024; + --light-color-ts-constructor: #4d7fff; + --light-color-ts-property: #ff984d; + --light-color-ts-method: #ff4db8; + --light-color-ts-reference: #ff4d82; + --light-color-ts-call-signature: var(--light-color-ts-method); + --light-color-ts-index-signature: var(--light-color-ts-property); + --light-color-ts-constructor-signature: var(--light-color-ts-constructor); + --light-color-ts-parameter: var(--light-color-ts-variable); + /* type literal not included as links will never be generated to it */ + --light-color-ts-type-parameter: #a55c0e; + --light-color-ts-accessor: #ff4d4d; + --light-color-ts-get-signature: var(--light-color-ts-accessor); + --light-color-ts-set-signature: var(--light-color-ts-accessor); + --light-color-ts-type-alias: #d51270; + /* reference not included as links will be colored with the kind that it points to */ + --light-color-document: #000000; + + --light-external-icon: url("data:image/svg+xml;utf8,"); + --light-color-scheme: light; + + /* Dark */ + --dark-color-background: #2b2e33; + --dark-color-background-secondary: #1e2024; + --dark-color-background-warning: #bebe00; + --dark-color-warning-text: #222; + --dark-color-accent: #9096a2; + --dark-color-active-menu-item: #5d5d6a; + --dark-color-text: #f5f5f5; + --dark-color-text-aside: #dddddd; + + --dark-color-icon-background: var(--dark-color-background-secondary); + --dark-color-icon-text: var(--dark-color-text); + + --dark-color-comment-tag-text: var(--dark-color-text); + --dark-color-comment-tag: var(--dark-color-background); + + --dark-color-link: #00aff4; + --dark-color-focus-outline: #4c97f2; + + --dark-color-ts-keyword: #3399ff; + --dark-color-ts-project: #e358ff; + --dark-color-ts-module: var(--dark-color-ts-project); + --dark-color-ts-namespace: var(--dark-color-ts-project); + --dark-color-ts-enum: #f4d93e; + --dark-color-ts-enum-member: var(--dark-color-ts-enum); + --dark-color-ts-variable: #798dff; + --dark-color-ts-function: #a280ff; + --dark-color-ts-class: #8ac4ff; + --dark-color-ts-interface: #6cff87; + --dark-color-ts-constructor: #4d7fff; + --dark-color-ts-property: #ff984d; + --dark-color-ts-method: #ff4db8; + --dark-color-ts-reference: #ff4d82; + --dark-color-ts-call-signature: var(--dark-color-ts-method); + --dark-color-ts-index-signature: var(--dark-color-ts-property); + --dark-color-ts-constructor-signature: var(--dark-color-ts-constructor); + --dark-color-ts-parameter: var(--dark-color-ts-variable); + /* type literal not included as links will never be generated to it */ + --dark-color-ts-type-parameter: #e07d13; + --dark-color-ts-accessor: #ff4d4d; + --dark-color-ts-get-signature: var(--dark-color-ts-accessor); + --dark-color-ts-set-signature: var(--dark-color-ts-accessor); + --dark-color-ts-type-alias: #ff6492; + /* reference not included as links will be colored with the kind that it points to */ + --dark-color-document: #ffffff; + + --dark-external-icon: url("data:image/svg+xml;utf8,"); + --dark-color-scheme: dark; +} + +@media (prefers-color-scheme: light) { + :root { + --color-background: var(--light-color-background); + --color-background-secondary: var(--light-color-background-secondary); + --color-background-warning: var(--light-color-background-warning); + --color-warning-text: var(--light-color-warning-text); + --color-accent: var(--light-color-accent); + --color-active-menu-item: var(--light-color-active-menu-item); + --color-text: var(--light-color-text); + --color-text-aside: var(--light-color-text-aside); + + --color-icon-background: var(--light-color-icon-background); + --color-icon-text: var(--light-color-icon-text); + + --color-comment-tag-text: var(--light-color-text); + --color-comment-tag: var(--light-color-background); + + --color-link: var(--light-color-link); + --color-focus-outline: var(--light-color-focus-outline); + + --color-ts-keyword: var(--light-color-ts-keyword); + --color-ts-project: var(--light-color-ts-project); + --color-ts-module: var(--light-color-ts-module); + --color-ts-namespace: var(--light-color-ts-namespace); + --color-ts-enum: var(--light-color-ts-enum); + --color-ts-enum-member: var(--light-color-ts-enum-member); + --color-ts-variable: var(--light-color-ts-variable); + --color-ts-function: var(--light-color-ts-function); + --color-ts-class: var(--light-color-ts-class); + --color-ts-interface: var(--light-color-ts-interface); + --color-ts-constructor: var(--light-color-ts-constructor); + --color-ts-property: var(--light-color-ts-property); + --color-ts-method: var(--light-color-ts-method); + --color-ts-reference: var(--light-color-ts-reference); + --color-ts-call-signature: var(--light-color-ts-call-signature); + --color-ts-index-signature: var(--light-color-ts-index-signature); + --color-ts-constructor-signature: var( + --light-color-ts-constructor-signature + ); + --color-ts-parameter: var(--light-color-ts-parameter); + --color-ts-type-parameter: var(--light-color-ts-type-parameter); + --color-ts-accessor: var(--light-color-ts-accessor); + --color-ts-get-signature: var(--light-color-ts-get-signature); + --color-ts-set-signature: var(--light-color-ts-set-signature); + --color-ts-type-alias: var(--light-color-ts-type-alias); + --color-document: var(--light-color-document); + + --external-icon: var(--light-external-icon); + --color-scheme: var(--light-color-scheme); + } +} + +@media (prefers-color-scheme: dark) { + :root { + --color-background: var(--dark-color-background); + --color-background-secondary: var(--dark-color-background-secondary); + --color-background-warning: var(--dark-color-background-warning); + --color-warning-text: var(--dark-color-warning-text); + --color-accent: var(--dark-color-accent); + --color-active-menu-item: var(--dark-color-active-menu-item); + --color-text: var(--dark-color-text); + --color-text-aside: var(--dark-color-text-aside); + + --color-icon-background: var(--dark-color-icon-background); + --color-icon-text: var(--dark-color-icon-text); + + --color-comment-tag-text: var(--dark-color-text); + --color-comment-tag: var(--dark-color-background); + + --color-link: var(--dark-color-link); + --color-focus-outline: var(--dark-color-focus-outline); + + --color-ts-keyword: var(--dark-color-ts-keyword); + --color-ts-project: var(--dark-color-ts-project); + --color-ts-module: var(--dark-color-ts-module); + --color-ts-namespace: var(--dark-color-ts-namespace); + --color-ts-enum: var(--dark-color-ts-enum); + --color-ts-enum-member: var(--dark-color-ts-enum-member); + --color-ts-variable: var(--dark-color-ts-variable); + --color-ts-function: var(--dark-color-ts-function); + --color-ts-class: var(--dark-color-ts-class); + --color-ts-interface: var(--dark-color-ts-interface); + --color-ts-constructor: var(--dark-color-ts-constructor); + --color-ts-property: var(--dark-color-ts-property); + --color-ts-method: var(--dark-color-ts-method); + --color-ts-reference: var(--dark-color-ts-reference); + --color-ts-call-signature: var(--dark-color-ts-call-signature); + --color-ts-index-signature: var(--dark-color-ts-index-signature); + --color-ts-constructor-signature: var( + --dark-color-ts-constructor-signature + ); + --color-ts-parameter: var(--dark-color-ts-parameter); + --color-ts-type-parameter: var(--dark-color-ts-type-parameter); + --color-ts-accessor: var(--dark-color-ts-accessor); + --color-ts-get-signature: var(--dark-color-ts-get-signature); + --color-ts-set-signature: var(--dark-color-ts-set-signature); + --color-ts-type-alias: var(--dark-color-ts-type-alias); + --color-document: var(--dark-color-document); + + --external-icon: var(--dark-external-icon); + --color-scheme: var(--dark-color-scheme); + } +} + +html { + color-scheme: var(--color-scheme); +} + +body { + margin: 0; +} + +:root[data-theme="light"] { + --color-background: var(--light-color-background); + --color-background-secondary: var(--light-color-background-secondary); + --color-background-warning: var(--light-color-background-warning); + --color-warning-text: var(--light-color-warning-text); + --color-icon-background: var(--light-color-icon-background); + --color-accent: var(--light-color-accent); + --color-active-menu-item: var(--light-color-active-menu-item); + --color-text: var(--light-color-text); + --color-text-aside: var(--light-color-text-aside); + --color-icon-text: var(--light-color-icon-text); + + --color-comment-tag-text: var(--light-color-text); + --color-comment-tag: var(--light-color-background); + + --color-link: var(--light-color-link); + --color-focus-outline: var(--light-color-focus-outline); + + --color-ts-keyword: var(--light-color-ts-keyword); + --color-ts-project: var(--light-color-ts-project); + --color-ts-module: var(--light-color-ts-module); + --color-ts-namespace: var(--light-color-ts-namespace); + --color-ts-enum: var(--light-color-ts-enum); + --color-ts-enum-member: var(--light-color-ts-enum-member); + --color-ts-variable: var(--light-color-ts-variable); + --color-ts-function: var(--light-color-ts-function); + --color-ts-class: var(--light-color-ts-class); + --color-ts-interface: var(--light-color-ts-interface); + --color-ts-constructor: var(--light-color-ts-constructor); + --color-ts-property: var(--light-color-ts-property); + --color-ts-method: var(--light-color-ts-method); + --color-ts-reference: var(--light-color-ts-reference); + --color-ts-call-signature: var(--light-color-ts-call-signature); + --color-ts-index-signature: var(--light-color-ts-index-signature); + --color-ts-constructor-signature: var( + --light-color-ts-constructor-signature + ); + --color-ts-parameter: var(--light-color-ts-parameter); + --color-ts-type-parameter: var(--light-color-ts-type-parameter); + --color-ts-accessor: var(--light-color-ts-accessor); + --color-ts-get-signature: var(--light-color-ts-get-signature); + --color-ts-set-signature: var(--light-color-ts-set-signature); + --color-ts-type-alias: var(--light-color-ts-type-alias); + --color-document: var(--light-color-document); + + --external-icon: var(--light-external-icon); + --color-scheme: var(--light-color-scheme); +} + +:root[data-theme="dark"] { + --color-background: var(--dark-color-background); + --color-background-secondary: var(--dark-color-background-secondary); + --color-background-warning: var(--dark-color-background-warning); + --color-warning-text: var(--dark-color-warning-text); + --color-icon-background: var(--dark-color-icon-background); + --color-accent: var(--dark-color-accent); + --color-active-menu-item: var(--dark-color-active-menu-item); + --color-text: var(--dark-color-text); + --color-text-aside: var(--dark-color-text-aside); + --color-icon-text: var(--dark-color-icon-text); + + --color-comment-tag-text: var(--dark-color-text); + --color-comment-tag: var(--dark-color-background); + + --color-link: var(--dark-color-link); + --color-focus-outline: var(--dark-color-focus-outline); + + --color-ts-keyword: var(--dark-color-ts-keyword); + --color-ts-project: var(--dark-color-ts-project); + --color-ts-module: var(--dark-color-ts-module); + --color-ts-namespace: var(--dark-color-ts-namespace); + --color-ts-enum: var(--dark-color-ts-enum); + --color-ts-enum-member: var(--dark-color-ts-enum-member); + --color-ts-variable: var(--dark-color-ts-variable); + --color-ts-function: var(--dark-color-ts-function); + --color-ts-class: var(--dark-color-ts-class); + --color-ts-interface: var(--dark-color-ts-interface); + --color-ts-constructor: var(--dark-color-ts-constructor); + --color-ts-property: var(--dark-color-ts-property); + --color-ts-method: var(--dark-color-ts-method); + --color-ts-reference: var(--dark-color-ts-reference); + --color-ts-call-signature: var(--dark-color-ts-call-signature); + --color-ts-index-signature: var(--dark-color-ts-index-signature); + --color-ts-constructor-signature: var( + --dark-color-ts-constructor-signature + ); + --color-ts-parameter: var(--dark-color-ts-parameter); + --color-ts-type-parameter: var(--dark-color-ts-type-parameter); + --color-ts-accessor: var(--dark-color-ts-accessor); + --color-ts-get-signature: var(--dark-color-ts-get-signature); + --color-ts-set-signature: var(--dark-color-ts-set-signature); + --color-ts-type-alias: var(--dark-color-ts-type-alias); + --color-document: var(--dark-color-document); + + --external-icon: var(--dark-external-icon); + --color-scheme: var(--dark-color-scheme); +} + +*:focus-visible, +.tsd-accordion-summary:focus-visible svg { + outline: 2px solid var(--color-focus-outline); +} + +.always-visible, +.always-visible .tsd-signatures { + display: inherit !important; +} + +h1, +h2, +h3, +h4, +h5, +h6 { + line-height: 1.2; +} + +h1 { + font-size: 1.875rem; + margin: 0.67rem 0; +} + +h2 { + font-size: 1.5rem; + margin: 0.83rem 0; +} + +h3 { + font-size: 1.25rem; + margin: 1rem 0; +} + +h4 { + font-size: 1.05rem; + margin: 1.33rem 0; +} + +h5 { + font-size: 1rem; + margin: 1.5rem 0; +} + +h6 { + font-size: 0.875rem; + margin: 2.33rem 0; +} + +dl, +menu, +ol, +ul { + margin: 1em 0; +} + +dd { + margin: 0 0 0 40px; +} + +.container { + max-width: 1700px; + padding: 0 2rem; +} + +/* Footer */ +footer { + border-top: 1px solid var(--color-accent); + padding-top: 1rem; + padding-bottom: 1rem; + max-height: 3.5rem; +} +footer > p { + margin: 0 1em; +} + +.container-main { + margin: 0 auto; + /* toolbar, footer, margin */ + min-height: calc(100vh - 41px - 56px - 4rem); +} + +@keyframes fade-in { + from { + opacity: 0; + } + to { + opacity: 1; + } +} +@keyframes fade-out { + from { + opacity: 1; + visibility: visible; + } + to { + opacity: 0; + } +} +@keyframes fade-in-delayed { + 0% { + opacity: 0; + } + 33% { + opacity: 0; + } + 100% { + opacity: 1; + } +} +@keyframes fade-out-delayed { + 0% { + opacity: 1; + visibility: visible; + } + 66% { + opacity: 0; + } + 100% { + opacity: 0; + } +} +@keyframes pop-in-from-right { + from { + transform: translate(100%, 0); + } + to { + transform: translate(0, 0); + } +} +@keyframes pop-out-to-right { + from { + transform: translate(0, 0); + visibility: visible; + } + to { + transform: translate(100%, 0); + } +} +body { + background: var(--color-background); + font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", + Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji"; + font-size: 16px; + color: var(--color-text); +} + +a { + color: var(--color-link); + text-decoration: none; +} +a:hover { + text-decoration: underline; +} +a.external[target="_blank"] { + background-image: var(--external-icon); + background-position: top 3px right; + background-repeat: no-repeat; + padding-right: 13px; +} +a.tsd-anchor-link { + color: var(--color-text); +} + +code, +pre { + font-family: Menlo, Monaco, Consolas, "Courier New", monospace; + padding: 0.2em; + margin: 0; + font-size: 0.875rem; + border-radius: 0.8em; +} + +pre { + position: relative; + white-space: pre-wrap; + word-wrap: break-word; + padding: 10px; + border: 1px solid var(--color-accent); +} +pre code { + padding: 0; + font-size: 100%; +} +pre > button { + position: absolute; + top: 10px; + right: 10px; + opacity: 0; + transition: opacity 0.1s; + box-sizing: border-box; +} +pre:hover > button, +pre > button.visible { + opacity: 1; +} + +blockquote { + margin: 1em 0; + padding-left: 1em; + border-left: 4px solid gray; +} + +.tsd-typography { + line-height: 1.333em; +} +.tsd-typography ul { + list-style: square; + padding: 0 0 0 20px; + margin: 0; +} +.tsd-typography .tsd-index-panel h3, +.tsd-index-panel .tsd-typography h3, +.tsd-typography h4, +.tsd-typography h5, +.tsd-typography h6 { + font-size: 1em; +} +.tsd-typography h5, +.tsd-typography h6 { + font-weight: normal; +} +.tsd-typography p, +.tsd-typography ul, +.tsd-typography ol { + margin: 1em 0; +} +.tsd-typography table { + border-collapse: collapse; + border: none; +} +.tsd-typography td, +.tsd-typography th { + padding: 6px 13px; + border: 1px solid var(--color-accent); +} +.tsd-typography thead, +.tsd-typography tr:nth-child(even) { + background-color: var(--color-background-secondary); +} + +.tsd-breadcrumb { + margin: 0; + padding: 0; + color: var(--color-text-aside); +} +.tsd-breadcrumb a { + color: var(--color-text-aside); + text-decoration: none; +} +.tsd-breadcrumb a:hover { + text-decoration: underline; +} +.tsd-breadcrumb li { + display: inline; +} +.tsd-breadcrumb li:after { + content: " / "; +} + +.tsd-comment-tags { + display: flex; + flex-direction: column; +} +dl.tsd-comment-tag-group { + display: flex; + align-items: center; + overflow: hidden; + margin: 0.5em 0; +} +dl.tsd-comment-tag-group dt { + display: flex; + margin-right: 0.5em; + font-size: 0.875em; + font-weight: normal; +} +dl.tsd-comment-tag-group dd { + margin: 0; +} +code.tsd-tag { + padding: 0.25em 0.4em; + border: 0.1em solid var(--color-accent); + margin-right: 0.25em; + font-size: 70%; +} +h1 code.tsd-tag:first-of-type { + margin-left: 0.25em; +} + +dl.tsd-comment-tag-group dd:before, +dl.tsd-comment-tag-group dd:after { + content: " "; +} +dl.tsd-comment-tag-group dd pre, +dl.tsd-comment-tag-group dd:after { + clear: both; +} +dl.tsd-comment-tag-group p { + margin: 0; +} + +.tsd-panel.tsd-comment .lead { + font-size: 1.1em; + line-height: 1.333em; + margin-bottom: 2em; +} +.tsd-panel.tsd-comment .lead:last-child { + margin-bottom: 0; +} + +.tsd-filter-visibility h4 { + font-size: 1rem; + padding-top: 0.75rem; + padding-bottom: 0.5rem; + margin: 0; +} +.tsd-filter-item:not(:last-child) { + margin-bottom: 0.5rem; +} +.tsd-filter-input { + display: flex; + width: -moz-fit-content; + width: fit-content; + align-items: center; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + cursor: pointer; +} +.tsd-filter-input input[type="checkbox"] { + cursor: pointer; + position: absolute; + width: 1.5em; + height: 1.5em; + opacity: 0; +} +.tsd-filter-input input[type="checkbox"]:disabled { + pointer-events: none; +} +.tsd-filter-input svg { + cursor: pointer; + width: 1.5em; + height: 1.5em; + margin-right: 0.5em; + border-radius: 0.33em; + /* Leaving this at full opacity breaks event listeners on Firefox. + Don't remove unless you know what you're doing. */ + opacity: 0.99; +} +.tsd-filter-input input[type="checkbox"]:focus-visible + svg { + outline: 2px solid var(--color-focus-outline); +} +.tsd-checkbox-background { + fill: var(--color-accent); +} +input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { + stroke: var(--color-text); +} +.tsd-filter-input input:disabled ~ svg > .tsd-checkbox-background { + fill: var(--color-background); + stroke: var(--color-accent); + stroke-width: 0.25rem; +} +.tsd-filter-input input:disabled ~ svg > .tsd-checkbox-checkmark { + stroke: var(--color-accent); +} + +.settings-label { + font-weight: bold; + text-transform: uppercase; + display: inline-block; +} + +.tsd-filter-visibility .settings-label { + margin: 0.75rem 0 0.5rem 0; +} + +.tsd-theme-toggle .settings-label { + margin: 0.75rem 0.75rem 0 0; +} + +.tsd-hierarchy { + list-style: square; + margin: 0; +} +.tsd-hierarchy .target { + font-weight: bold; +} + +.tsd-full-hierarchy:not(:last-child) { + margin-bottom: 1em; + padding-bottom: 1em; + border-bottom: 1px solid var(--color-accent); +} +.tsd-full-hierarchy, +.tsd-full-hierarchy ul { + list-style: none; + margin: 0; + padding: 0; +} +.tsd-full-hierarchy ul { + padding-left: 1.5rem; +} +.tsd-full-hierarchy a { + padding: 0.25rem 0 !important; + font-size: 1rem; + display: inline-flex; + align-items: center; + color: var(--color-text); +} + +.tsd-panel-group.tsd-index-group { + margin-bottom: 0; +} +.tsd-index-panel .tsd-index-list { + list-style: none; + line-height: 1.333em; + margin: 0; + padding: 0.25rem 0 0 0; + overflow: hidden; + display: grid; + grid-template-columns: repeat(3, 1fr); + column-gap: 1rem; + grid-template-rows: auto; +} +@media (max-width: 1024px) { + .tsd-index-panel .tsd-index-list { + grid-template-columns: repeat(2, 1fr); + } +} +@media (max-width: 768px) { + .tsd-index-panel .tsd-index-list { + grid-template-columns: repeat(1, 1fr); + } +} +.tsd-index-panel .tsd-index-list li { + -webkit-page-break-inside: avoid; + -moz-page-break-inside: avoid; + -ms-page-break-inside: avoid; + -o-page-break-inside: avoid; + page-break-inside: avoid; +} + +.tsd-flag { + display: inline-block; + padding: 0.25em 0.4em; + border-radius: 4px; + color: var(--color-comment-tag-text); + background-color: var(--color-comment-tag); + text-indent: 0; + font-size: 75%; + line-height: 1; + font-weight: normal; +} + +.tsd-anchor { + position: relative; + top: -100px; +} + +.tsd-member { + position: relative; +} +.tsd-member .tsd-anchor + h3 { + display: flex; + align-items: center; + margin-top: 0; + margin-bottom: 0; + border-bottom: none; +} + +.tsd-navigation.settings { + margin: 1rem 0; +} +.tsd-navigation > a, +.tsd-navigation .tsd-accordion-summary { + width: calc(100% - 0.25rem); + display: flex; + align-items: center; +} +.tsd-navigation a, +.tsd-navigation summary > span, +.tsd-page-navigation a { + display: flex; + width: calc(100% - 0.25rem); + align-items: center; + padding: 0.25rem; + color: var(--color-text); + text-decoration: none; + box-sizing: border-box; +} +.tsd-navigation a.current, +.tsd-page-navigation a.current { + background: var(--color-active-menu-item); +} +.tsd-navigation a:hover, +.tsd-page-navigation a:hover { + text-decoration: underline; +} +.tsd-navigation ul, +.tsd-page-navigation ul { + margin-top: 0; + margin-bottom: 0; + padding: 0; + list-style: none; +} +.tsd-navigation li, +.tsd-page-navigation li { + padding: 0; + max-width: 100%; +} +.tsd-navigation .tsd-nav-link { + display: none; +} +.tsd-nested-navigation { + margin-left: 3rem; +} +.tsd-nested-navigation > li > details { + margin-left: -1.5rem; +} +.tsd-small-nested-navigation { + margin-left: 1.5rem; +} +.tsd-small-nested-navigation > li > details { + margin-left: -1.5rem; +} + +.tsd-page-navigation-section { + margin-left: 10px; +} +.tsd-page-navigation-section > summary { + padding: 0.25rem; +} +.tsd-page-navigation-section > div { + margin-left: 20px; +} +.tsd-page-navigation ul { + padding-left: 1.75rem; +} + +#tsd-sidebar-links a { + margin-top: 0; + margin-bottom: 0.5rem; + line-height: 1.25rem; +} +#tsd-sidebar-links a:last-of-type { + margin-bottom: 0; +} + +a.tsd-index-link { + padding: 0.25rem 0 !important; + font-size: 1rem; + line-height: 1.25rem; + display: inline-flex; + align-items: center; + color: var(--color-text); +} +.tsd-accordion-summary { + list-style-type: none; /* hide marker on non-safari */ + outline: none; /* broken on safari, so just hide it */ +} +.tsd-accordion-summary::-webkit-details-marker { + display: none; /* hide marker on safari */ +} +.tsd-accordion-summary, +.tsd-accordion-summary a { + -moz-user-select: none; + -webkit-user-select: none; + -ms-user-select: none; + user-select: none; + + cursor: pointer; +} +.tsd-accordion-summary a { + width: calc(100% - 1.5rem); +} +.tsd-accordion-summary > * { + margin-top: 0; + margin-bottom: 0; + padding-top: 0; + padding-bottom: 0; +} +.tsd-accordion .tsd-accordion-summary > svg { + margin-left: 0.25rem; + vertical-align: text-top; +} +.tsd-index-content > :not(:first-child) { + margin-top: 0.75rem; +} +.tsd-index-heading { + margin-top: 1.5rem; + margin-bottom: 0.75rem; +} + +.tsd-no-select { + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} +.tsd-kind-icon { + margin-right: 0.5rem; + width: 1.25rem; + height: 1.25rem; + min-width: 1.25rem; + min-height: 1.25rem; +} +.tsd-signature > .tsd-kind-icon { + margin-right: 0.8rem; +} + +.tsd-panel { + margin-bottom: 2.5rem; +} +.tsd-panel.tsd-member { + margin-bottom: 4rem; +} +.tsd-panel:empty { + display: none; +} +.tsd-panel > h1, +.tsd-panel > h2, +.tsd-panel > h3 { + margin: 1.5rem -1.5rem 0.75rem -1.5rem; + padding: 0 1.5rem 0.75rem 1.5rem; +} +.tsd-panel > h1.tsd-before-signature, +.tsd-panel > h2.tsd-before-signature, +.tsd-panel > h3.tsd-before-signature { + margin-bottom: 0; + border-bottom: none; +} + +.tsd-panel-group { + margin: 2rem 0; +} +.tsd-panel-group.tsd-index-group { + margin: 2rem 0; +} +.tsd-panel-group.tsd-index-group details { + margin: 2rem 0; +} +.tsd-panel-group > .tsd-accordion-summary { + margin-bottom: 1rem; +} + +#tsd-search { + transition: background-color 0.2s; +} +#tsd-search .title { + position: relative; + z-index: 2; +} +#tsd-search .field { + position: absolute; + left: 0; + top: 0; + right: 2.5rem; + height: 100%; +} +#tsd-search .field input { + box-sizing: border-box; + position: relative; + top: -50px; + z-index: 1; + width: 100%; + padding: 0 10px; + opacity: 0; + outline: 0; + border: 0; + background: transparent; + color: var(--color-text); +} +#tsd-search .field label { + position: absolute; + overflow: hidden; + right: -40px; +} +#tsd-search .field input, +#tsd-search .title, +#tsd-toolbar-links a { + transition: opacity 0.2s; +} +#tsd-search .results { + position: absolute; + visibility: hidden; + top: 40px; + width: 100%; + margin: 0; + padding: 0; + list-style: none; + box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); +} +#tsd-search .results li { + background-color: var(--color-background); + line-height: initial; + padding: 4px; +} +#tsd-search .results li:nth-child(even) { + background-color: var(--color-background-secondary); +} +#tsd-search .results li.state { + display: none; +} +#tsd-search .results li.current:not(.no-results), +#tsd-search .results li:hover:not(.no-results) { + background-color: var(--color-accent); +} +#tsd-search .results a { + display: flex; + align-items: center; + padding: 0.25rem; + box-sizing: border-box; +} +#tsd-search .results a:before { + top: 10px; +} +#tsd-search .results span.parent { + color: var(--color-text-aside); + font-weight: normal; +} +#tsd-search.has-focus { + background-color: var(--color-accent); +} +#tsd-search.has-focus .field input { + top: 0; + opacity: 1; +} +#tsd-search.has-focus .title, +#tsd-search.has-focus #tsd-toolbar-links a { + z-index: 0; + opacity: 0; +} +#tsd-search.has-focus .results { + visibility: visible; +} +#tsd-search.loading .results li.state.loading { + display: block; +} +#tsd-search.failure .results li.state.failure { + display: block; +} + +#tsd-toolbar-links { + position: absolute; + top: 0; + right: 2rem; + height: 100%; + display: flex; + align-items: center; + justify-content: flex-end; +} +#tsd-toolbar-links a { + margin-left: 1.5rem; +} +#tsd-toolbar-links a:hover { + text-decoration: underline; +} + +.tsd-signature { + margin: 0 0 1rem 0; + padding: 1rem 0.5rem; + border: 1px solid var(--color-accent); + font-family: Menlo, Monaco, Consolas, "Courier New", monospace; + font-size: 14px; + overflow-x: auto; +} + +.tsd-signature-keyword { + color: var(--color-ts-keyword); + font-weight: normal; +} + +.tsd-signature-symbol { + color: var(--color-text-aside); + font-weight: normal; +} + +.tsd-signature-type { + font-style: italic; + font-weight: normal; +} + +.tsd-signatures { + padding: 0; + margin: 0 0 1em 0; + list-style-type: none; +} +.tsd-signatures .tsd-signature { + margin: 0; + border-color: var(--color-accent); + border-width: 1px 0; + transition: background-color 0.1s; +} +.tsd-signatures .tsd-index-signature:not(:last-child) { + margin-bottom: 1em; +} +.tsd-signatures .tsd-index-signature .tsd-signature { + border-width: 1px; +} +.tsd-description .tsd-signatures .tsd-signature { + border-width: 1px; +} + +ul.tsd-parameter-list, +ul.tsd-type-parameter-list { + list-style: square; + margin: 0; + padding-left: 20px; +} +ul.tsd-parameter-list > li.tsd-parameter-signature, +ul.tsd-type-parameter-list > li.tsd-parameter-signature { + list-style: none; + margin-left: -20px; +} +ul.tsd-parameter-list h5, +ul.tsd-type-parameter-list h5 { + font-size: 16px; + margin: 1em 0 0.5em 0; +} +.tsd-sources { + margin-top: 1rem; + font-size: 0.875em; +} +.tsd-sources a { + color: var(--color-text-aside); + text-decoration: underline; +} +.tsd-sources ul { + list-style: none; + padding: 0; +} + +.tsd-page-toolbar { + position: sticky; + z-index: 1; + top: 0; + left: 0; + width: 100%; + color: var(--color-text); + background: var(--color-background-secondary); + border-bottom: 1px var(--color-accent) solid; + transition: transform 0.3s ease-in-out; +} +.tsd-page-toolbar a { + color: var(--color-text); + text-decoration: none; +} +.tsd-page-toolbar a.title { + font-weight: bold; +} +.tsd-page-toolbar a.title:hover { + text-decoration: underline; +} +.tsd-page-toolbar .tsd-toolbar-contents { + display: flex; + justify-content: space-between; + height: 2.5rem; + margin: 0 auto; +} +.tsd-page-toolbar .table-cell { + position: relative; + white-space: nowrap; + line-height: 40px; +} +.tsd-page-toolbar .table-cell:first-child { + width: 100%; +} +.tsd-page-toolbar .tsd-toolbar-icon { + box-sizing: border-box; + line-height: 0; + padding: 12px 0; +} + +.tsd-widget { + display: inline-block; + overflow: hidden; + opacity: 0.8; + height: 40px; + transition: + opacity 0.1s, + background-color 0.2s; + vertical-align: bottom; + cursor: pointer; +} +.tsd-widget:hover { + opacity: 0.9; +} +.tsd-widget.active { + opacity: 1; + background-color: var(--color-accent); +} +.tsd-widget.no-caption { + width: 40px; +} +.tsd-widget.no-caption:before { + margin: 0; +} + +.tsd-widget.options, +.tsd-widget.menu { + display: none; +} +input[type="checkbox"] + .tsd-widget:before { + background-position: -120px 0; +} +input[type="checkbox"]:checked + .tsd-widget:before { + background-position: -160px 0; +} + +img { + max-width: 100%; +} + +.tsd-anchor-icon { + display: inline-flex; + align-items: center; + margin-left: 0.5rem; + vertical-align: middle; + color: var(--color-text); +} + +.tsd-anchor-icon svg { + width: 1em; + height: 1em; + visibility: hidden; +} + +.tsd-anchor-link:hover > .tsd-anchor-icon svg { + visibility: visible; +} + +.deprecated { + text-decoration: line-through !important; +} + +.warning { + padding: 1rem; + color: var(--color-warning-text); + background: var(--color-background-warning); +} + +.tsd-kind-project { + color: var(--color-ts-project); +} +.tsd-kind-module { + color: var(--color-ts-module); +} +.tsd-kind-namespace { + color: var(--color-ts-namespace); +} +.tsd-kind-enum { + color: var(--color-ts-enum); +} +.tsd-kind-enum-member { + color: var(--color-ts-enum-member); +} +.tsd-kind-variable { + color: var(--color-ts-variable); +} +.tsd-kind-function { + color: var(--color-ts-function); +} +.tsd-kind-class { + color: var(--color-ts-class); +} +.tsd-kind-interface { + color: var(--color-ts-interface); +} +.tsd-kind-constructor { + color: var(--color-ts-constructor); +} +.tsd-kind-property { + color: var(--color-ts-property); +} +.tsd-kind-method { + color: var(--color-ts-method); +} +.tsd-kind-reference { + color: var(--color-ts-reference); +} +.tsd-kind-call-signature { + color: var(--color-ts-call-signature); +} +.tsd-kind-index-signature { + color: var(--color-ts-index-signature); +} +.tsd-kind-constructor-signature { + color: var(--color-ts-constructor-signature); +} +.tsd-kind-parameter { + color: var(--color-ts-parameter); +} +.tsd-kind-type-parameter { + color: var(--color-ts-type-parameter); +} +.tsd-kind-accessor { + color: var(--color-ts-accessor); +} +.tsd-kind-get-signature { + color: var(--color-ts-get-signature); +} +.tsd-kind-set-signature { + color: var(--color-ts-set-signature); +} +.tsd-kind-type-alias { + color: var(--color-ts-type-alias); +} + +/* if we have a kind icon, don't color the text by kind */ +.tsd-kind-icon ~ span { + color: var(--color-text); +} + +* { + scrollbar-width: thin; + scrollbar-color: var(--color-accent) var(--color-icon-background); +} + +*::-webkit-scrollbar { + width: 0.75rem; +} + +*::-webkit-scrollbar-track { + background: var(--color-icon-background); +} + +*::-webkit-scrollbar-thumb { + background-color: var(--color-accent); + border-radius: 999rem; + border: 0.25rem solid var(--color-icon-background); +} + +/* mobile */ +@media (max-width: 769px) { + .tsd-widget.options, + .tsd-widget.menu { + display: inline-block; + } + + .container-main { + display: flex; + } + html .col-content { + float: none; + max-width: 100%; + width: 100%; + } + html .col-sidebar { + position: fixed !important; + overflow-y: auto; + -webkit-overflow-scrolling: touch; + z-index: 1024; + top: 0 !important; + bottom: 0 !important; + left: auto !important; + right: 0 !important; + padding: 1.5rem 1.5rem 0 0; + width: 75vw; + visibility: hidden; + background-color: var(--color-background); + transform: translate(100%, 0); + } + html .col-sidebar > *:last-child { + padding-bottom: 20px; + } + html .overlay { + content: ""; + display: block; + position: fixed; + z-index: 1023; + top: 0; + left: 0; + right: 0; + bottom: 0; + background-color: rgba(0, 0, 0, 0.75); + visibility: hidden; + } + + .to-has-menu .overlay { + animation: fade-in 0.4s; + } + + .to-has-menu .col-sidebar { + animation: pop-in-from-right 0.4s; + } + + .from-has-menu .overlay { + animation: fade-out 0.4s; + } + + .from-has-menu .col-sidebar { + animation: pop-out-to-right 0.4s; + } + + .has-menu body { + overflow: hidden; + } + .has-menu .overlay { + visibility: visible; + } + .has-menu .col-sidebar { + visibility: visible; + transform: translate(0, 0); + display: flex; + flex-direction: column; + gap: 1.5rem; + max-height: 100vh; + padding: 1rem 2rem; + } + .has-menu .tsd-navigation { + max-height: 100%; + } + #tsd-toolbar-links { + display: none; + } + .tsd-navigation .tsd-nav-link { + display: flex; + } +} + +/* one sidebar */ +@media (min-width: 770px) { + .container-main { + display: grid; + grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); + grid-template-areas: "sidebar content"; + margin: 2rem auto; + } + + .col-sidebar { + grid-area: sidebar; + } + .col-content { + grid-area: content; + padding: 0 1rem; + } +} +@media (min-width: 770px) and (max-width: 1399px) { + .col-sidebar { + max-height: calc(100vh - 2rem - 42px); + overflow: auto; + position: sticky; + top: 42px; + padding-top: 1rem; + } + .site-menu { + margin-top: 1rem; + } +} + +/* two sidebars */ +@media (min-width: 1200px) { + .container-main { + grid-template-columns: minmax(0, 1fr) minmax(0, 2.5fr) minmax(0, 20rem); + grid-template-areas: "sidebar content toc"; + } + + .col-sidebar { + display: contents; + } + + .page-menu { + grid-area: toc; + padding-left: 1rem; + } + .site-menu { + grid-area: sidebar; + } + + .site-menu { + margin-top: 1rem; + } + + .page-menu, + .site-menu { + max-height: calc(100vh - 2rem - 42px); + overflow: auto; + position: sticky; + top: 42px; + } +} diff --git a/docs/classes/index.ForexClient.html b/docs/classes/index.ForexClient.html new file mode 100644 index 0000000..3293ab1 --- /dev/null +++ b/docs/classes/index.ForexClient.html @@ -0,0 +1,237 @@ +ForexClient | @kabeep/forex - v1.0.0-alpha

A client to interact with the Forex API for fetching currency rates and conversion data

+

Hierarchy (view full)

Constructors

Properties

timeout: number
headers: HeadersInit

Methods

  • Fetches the list of available currencies

    +

    Parameters

    • Optionaldate: Date | "latest" = 'latest'

      The date for fetching currencies, or "latest" for the most recent

      +
    • Optionaloptions: RequestInit = {}

      Additional request options

      +

    Returns Promise<HttpResponse<AvailableCurrency[]>>

    A list of available currencies

    +
    // => {
    // code: 200,
    // message: 'OK',
    // data: [
    // { code: 'eur', name: 'Euro' },
    // { code: 'usd', name: 'US Dollar' },
    // { code: 'cny', name: 'Chinese Yuan Renminbi' },
    // ... More items
    // ]
    // }
    new ForexClient().getCurrencies('latest'); +
    + +
  • Fetches the exchange rates for a specific currency

    +

    Parameters

    • Optionalcode: string = ...

      The currency code or locale code to get rates for

      +
    • Optionaldate: Date | "latest" = 'latest'

      The date for the rates, or 'latest' for the most recent

      +
    • Optionaloptions: RequestInit = {}

      Additional request options

      +

    Returns Promise<HttpResponse<ExchangeRate[]>>

    A list of exchange rates

    +
    // => {
    // code: 200,
    // message: 'OK',
    // data: [
    // { code: 'eur', rate: 100_000 },
    // { code: 'usd', rate: 100_000 },
    // { code: 'cny', rate: 100_000 },
    // ... More items
    // ]
    // }
    new ForexClient().getRates('BTC'); +
    + +
  • Fetches the exchange rate between two currencies

    +

    Parameters

    • OptionalbaseCode: string = ...

      The base currency code or locale code

      +
    • OptionaldestCode: string

      The destination currency code or locale code

      +
    • Optionaldate: Date | "latest" = 'latest'

      The date for the rate, or 'latest' for the most recent

      +
    • Optionaloptions: RequestInit = {}

      Additional request options

      +

    Returns Promise<HttpResponse<number>>

    The exchange rate

    +
    // => {
    // code: 200,
    // message: 'OK',
    // data: 100_000
    // }
    new ForexClient().getRate('BTC', 'USD'); +
    + +
  • Get a valid currency code based on locale

    +

    Parameters

    • localeCode: string

      The locale code to get currency code for

      +

    Returns string

    The corresponding currency code

    +
    // => 'USD'
    new ForexClient().getCode('US'); +
    + +
    // => 'CNH'
    new ForexClient().getCode('HK'); +
    + +
    // => 'CNY'
    new ForexClient().getCode('RMB'); +
    + +
  • Converts an amount from one currency to another

    +

    Parameters

    • OptionalbaseCode: string = ...

      The base currency code or locale code

      +
    • OptionaldestCode: string

      The destination currency code or locale code

      +
    • Optionalamount: string | number = 0

      The amount to convert

      +
    • Optionaldate: Date | "latest" = 'latest'

      The date for the conversion rate, or 'latest' for the most recent

      +
    • Optionaloptions: RequestInit = {}

      Additional request options

      +

    Returns Promise<HttpResponse<number>>

    The converted amount

    +
    // => {
    // code: 200,
    // message: 'OK',
    // data: 100_000
    // }
    new ForexClient().convert('BTC', 'USD', 1); +
    + +
    // => {
    // code: 200,
    // message: 'OK',
    // data: 7.27
    // }
    new ForexClient().convert('US', 'HK', 1); +
    + +
+ \ No newline at end of file diff --git a/docs/classes/index._internal_.HttpClient.html b/docs/classes/index._internal_.HttpClient.html new file mode 100644 index 0000000..5267223 --- /dev/null +++ b/docs/classes/index._internal_.HttpClient.html @@ -0,0 +1,180 @@ +HttpClient | @kabeep/forex - v1.0.0-alpha

Hierarchy (view full)

Constructors

Properties

Methods

Constructors

Properties

timeout: number
headers: HeadersInit

Methods

+ \ No newline at end of file diff --git a/docs/classes/index._internal_.HttpRequest.html b/docs/classes/index._internal_.HttpRequest.html new file mode 100644 index 0000000..25e9ca3 --- /dev/null +++ b/docs/classes/index._internal_.HttpRequest.html @@ -0,0 +1,179 @@ +HttpRequest | @kabeep/forex - v1.0.0-alpha

Hierarchy (view full)

Constructors

Properties

Methods

Constructors

Properties

timeout: number
headers: HeadersInit

Methods

+ \ No newline at end of file diff --git a/docs/documents/____.html b/docs/documents/____.html new file mode 100644 index 0000000..9e2dead --- /dev/null +++ b/docs/documents/____.html @@ -0,0 +1,581 @@ +简体中文 | @kabeep/forex - v1.0.0-alpha
+

forex

+

💱 一个 JavaScript 外汇库,通过 fawazahmed0 的 API。

+

NodeJS +License +NPM +Codecov +BundlePhobia +CircleCI

+

English | 简体中文

+

Insights

+
+
+

forex 全称是 Foreign Exchange,它的目的不是用于 FX 外汇交易,请慎重用于投资相关决策。

+
+

在浏览器或终端中获取每日汇率,免费且无速率限制。

+

查看 文档在线示例

+
npm install @kabeep/forex --save
+
+ +
yarn add @kabeep/forex
+
+ +
pnpm add @kabeep/forex
+
+ +

CommonJS

+
const { ForexClient } = require('@kabeep/forex');
+
+ +

ESModule

+
import { ForexClient } from '@kabeep/forex';
+
+ +

获取可用的货币列表。

+
const client = new ForexClient();
// => {
// code: 200,
// message: 'OK',
// data: [
// { code: 'eur', name: 'Euro' },
// { code: 'usd', name: 'US Dollar' },
// { code: 'cny', name: 'Chinese Yuan Renminbi' },
// { code: 'btc', name: 'Bitcoin', }
// ... More items
// ]
// }
client.getCurrencies('latest');

// or
client.getCurrencies(new Date(2024, 11, 1)); +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + +
参数类型可选默认值描述
dateDate | "latest"true"latest"获取货币的日期,或最新的 'latest'
optionsRequestInittrue{}自定义请求参数
+

结果对象:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
属性类型必选描述
codenumbertrueHTTP 响应状态代码
messagestringtrueHTTP 响应状态消息
dataAvailableCurrency[]false可用货币列表
+

接口 AvailableCurrency:

+ + + + + + + + + + + + + + + + + + + + + + + +
属性类型必选描述
codestringtrue货币代码
namestringfalse货币名称
+
+

获取指定货币的汇率。

+
const client = new ForexClient();
// => {
// code: 200,
// message: 'OK',
// data: [
// { code: 'eur', rate: 100_000 },
// { code: 'usd', rate: 100_000 },
// { code: 'cny', rate: 100_000 },
// ... More items
// ]
// }
client.getRates('USD');

// or
client.getRates('US'); +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
参数类型可选默认值描述
codestringtruethis.options.baseCurrency用于获取汇率的货币代码或区域代码
dateDate | "latest"true"latest"获取货币的日期,或最新的 'latest'
optionsRequestInittrue{}自定义请求参数
+

结果对象:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
属性类型必选描述
codenumbertrueHTTP 响应状态代码
messagestringtrueHTTP 响应状态消息
dataExchangeRate[]false汇率列表
+

接口 ExchangeRate:

+ + + + + + + + + + + + + + + + + + + + + + + +
属性类型必选描述
codestringtrue货币代码
ratenumberfalse货币汇率
+
+

获取两种货币之间的汇率。

+
const client = new ForexClient();
// => {
// code: 200,
// message: 'OK',
// data: 0.94759027
// }
client.getRate('USD', 'EUR');

// => {
// code: 200,
// message: 'OK',
// data: 7.78004385
// }
client.getRate('US', 'HK'); +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
参数类型可选默认值描述
baseCodestringtruethis.options.baseCurrency基准货币代码或区域代码
destCodestringtrue-目标货币代码或区域代码
dateDate | "latest"true"latest"获取货币的日期,或最新的 'latest'
optionsRequestInittrue{}自定义请求参数
+

结果对象:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
属性类型必选描述
codenumbertrueHTTP 响应状态代码
messagestringtrueHTTP 响应状态消息
datanumberfalse汇率
+
+

根据 ISO 3166-1 代码获取有效的货币代码。

+
const client = new ForexClient();
// => 'USD'
client.getCode('US');

// => 'CNH'
client.getCode('HK');

// => 'CNY'
client.getCode('RMB'); +
+ + + + + + + + + + + + + + + + + + + + +
参数类型可选默认值描述
localeCodestringfalse-用于获取货币代码的 ISO 3166-1 代码
+

对应的货币代码。

+

将金额从一种货币转换为另一种货币。

+
const client = new ForexClient();
// => {
// code: 200,
// message: 'OK',
// data: 9.48
// }
client.convert('USD', 'EUR', 10);

// => {
// code: 200,
// message: 'OK',
// data: 72.67
// }
client.convert('US', 'HK', 10); +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
参数类型可选默认值描述
baseCodestringtruethis.options.baseCurrency基准货币代码或区域代码
destCodestringtrue-目标货币代码或区域代码
amountnumbertrue0兑换数额
dateDate | "latest"true"latest"获取货币的日期,或最新的 'latest'
optionsRequestInittrue{}自定义请求参数
+

结果对象:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
属性类型必选描述
codenumbertrueHTTP 响应状态代码
messagestringtrueHTTP 响应状态消息
datanumberfalse兑换金额
+
+

exchange-api - 如果没有这个,这个包就不会存在。

+

欢迎通过 Pull Requests 或 Issues 来贡献你的想法和代码。

+

本项目采用 MIT 许可证。详情请见 LICENSE 文件。

+
+ \ No newline at end of file diff --git a/docs/documents/demo.html b/docs/documents/demo.html new file mode 100644 index 0000000..7cb917e --- /dev/null +++ b/docs/documents/demo.html @@ -0,0 +1,86 @@ + + + + + + + + + + + + + + + + + + + + + + + @kabeep/forex + + + + + +
+ +
+ +
+
+
+ + +
+
+ +
+
+ + +
+
+
+ + + diff --git a/docs/hierarchy.html b/docs/hierarchy.html new file mode 100644 index 0000000..4266389 --- /dev/null +++ b/docs/hierarchy.html @@ -0,0 +1,175 @@ +@kabeep/forex - v1.0.0-alpha
+ \ No newline at end of file diff --git a/docs/index.html b/docs/index.html new file mode 100644 index 0000000..d2108f7 --- /dev/null +++ b/docs/index.html @@ -0,0 +1,581 @@ +@kabeep/forex - v1.0.0-alpha

@kabeep/forex

+

forex

+

💱 A JavaScript foreign exchange library via fawazahmed0's API.

+

NodeJS +License +NPM +Codecov +BundlePhobia +CircleCI

+

English | 简体中文

+

Insights

+
+
+

forex stands for Foreign Exchange, and its purpose is not FX trading.

+

Please use it with caution for investment-related decisions.

+
+

Get daily exchange rates in the browser or terminal for free and without rate limits.

+

See documentation or demo.

+
npm install @kabeep/forex --save
+
+ +
yarn add @kabeep/forex
+
+ +
pnpm add @kabeep/forex
+
+ +
const { ForexClient } = require('@kabeep/forex');
+
+ +
import { ForexClient } from '@kabeep/forex';
+
+ +
+

Fetches the list of available currencies.

+
const client = new ForexClient();
// => {
// code: 200,
// message: 'OK',
// data: [
// { code: 'eur', name: 'Euro' },
// { code: 'usd', name: 'US Dollar' },
// { code: 'cny', name: 'Chinese Yuan Renminbi' },
// { code: 'btc', name: 'Bitcoin', }
// ... More items
// ]
// }
client.getCurrencies('latest');

// or
client.getCurrencies(new Date(2024, 11, 1)); +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + +
ParameterTypeOptionalDefaultDescription
dateDate | "latest"true"latest"The date for fetching currencies, or "latest" for the most recent
optionsRequestInittrue{}Additional request options
+

Result Object:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
KeyTypeRequiredDescription
codenumbertrueHTTP response status codes
messagestringtrueHTTP response status messages
dataAvailableCurrency[]falseList of available currency
+

interface AvailableCurrency:

+ + + + + + + + + + + + + + + + + + + + + + + +
KeyTypeRequiredDescription
codestringtrueCode of currency
namestringfalseName of currency
+
+

Fetches the exchange rates for a specific currency.

+
const client = new ForexClient();
// => {
// code: 200,
// message: 'OK',
// data: [
// { code: 'eur', rate: 100_000 },
// { code: 'usd', rate: 100_000 },
// { code: 'cny', rate: 100_000 },
// ... More items
// ]
// }
client.getRates('USD');

// or
client.getRates('US'); +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ParameterTypeOptionalDefaultDescription
codestringtruethis.options.baseCurrencyThe currency code or locale code to get rates for
dateDate | "latest"true"latest"The date for fetching currencies, or "latest" for the most recent
optionsRequestInittrue{}Additional request options
+

Result Object:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
KeyTypeRequiredDescription
codenumbertrueHTTP response status codes
messagestringtrueHTTP response status messages
dataExchangeRate[]falseList of exchange rates
+

interface ExchangeRate:

+ + + + + + + + + + + + + + + + + + + + + + + +
KeyTypeRequiredDescription
codestringtrueCode of currency
ratenumberfalseRate of currency
+
+

Fetches the exchange rate between two currencies.

+
const client = new ForexClient();
// => {
// code: 200,
// message: 'OK',
// data: 0.94759027
// }
client.getRate('USD', 'EUR');

// => {
// code: 200,
// message: 'OK',
// data: 7.78004385
// }
client.getRate('US', 'HK'); +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ParameterTypeOptionalDefaultDescription
baseCodestringtruethis.options.baseCurrencyThe base currency code or locale code
destCodestringtrue-The destination currency code or locale code
dateDate | "latest"true"latest"The date for fetching currencies, or "latest" for the most recent
optionsRequestInittrue{}Additional request options
+

Result Object:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
KeyTypeRequiredDescription
codenumbertrueHTTP response status codes
messagestringtrueHTTP response status messages
datanumberfalseThe exchange rate
+
+

Get a valid currency code based on ISO 3166-1 code.

+
const client = new ForexClient();
// => 'USD'
client.getCode('US');

// => 'CNH'
client.getCode('HK');

// => 'CNY'
client.getCode('RMB'); +
+ + + + + + + + + + + + + + + + + + + + +
ParameterTypeOptionalDefaultDescription
localeCodestringfalse-The locale code to get currency code for
+

The corresponding currency code.

+

Converts an amount from one currency to another.

+
const client = new ForexClient();
// => {
// code: 200,
// message: 'OK',
// data: 9.48
// }
client.convert('USD', 'EUR', 10);

// => {
// code: 200,
// message: 'OK',
// data: 72.67
// }
client.convert('US', 'HK', 10); +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ParameterTypeOptionalDefaultDescription
baseCodestringtruethis.options.baseCurrencyThe base currency code or locale code
destCodestringtrue-The destination currency code or locale code
amountnumbertrue0The amount to convert
dateDate | "latest"true"latest"The date for fetching currencies, or "latest" for the most recent
optionsRequestInittrue{}Additional request options
+

Result Object:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
KeyTypeRequiredDescription
codenumbertrueHTTP response status codes
messagestringtrueHTTP response status messages
datanumberfalseThe converted amount
+
+

exchange-api - This package would not exist without this.

+

Contributions via Pull Requests or Issues are welcome.

+

This project is licensed under the MIT License. See the LICENSE file for details.

+
+ \ No newline at end of file diff --git a/docs/interfaces/index.AvailableCurrency.html b/docs/interfaces/index.AvailableCurrency.html new file mode 100644 index 0000000..f7a6d02 --- /dev/null +++ b/docs/interfaces/index.AvailableCurrency.html @@ -0,0 +1,177 @@ +AvailableCurrency | @kabeep/forex - v1.0.0-alpha

Interface AvailableCurrency

interface AvailableCurrency {
    code: string;
    name: string;
}

Properties

Properties

code: string
name: string
+ \ No newline at end of file diff --git a/docs/interfaces/index.ExchangeRate.html b/docs/interfaces/index.ExchangeRate.html new file mode 100644 index 0000000..9a35875 --- /dev/null +++ b/docs/interfaces/index.ExchangeRate.html @@ -0,0 +1,177 @@ +ExchangeRate | @kabeep/forex - v1.0.0-alpha

Interface ExchangeRate

interface ExchangeRate {
    code: string;
    rate: number;
}

Properties

Properties

code: string
rate: number
+ \ No newline at end of file diff --git a/docs/interfaces/index.ForexClientOptions.html b/docs/interfaces/index.ForexClientOptions.html new file mode 100644 index 0000000..2fb021d --- /dev/null +++ b/docs/interfaces/index.ForexClientOptions.html @@ -0,0 +1,179 @@ +ForexClientOptions | @kabeep/forex - v1.0.0-alpha

Interface ForexClientOptions

interface ForexClientOptions {
    baseCurrency?: string;
    minified?: boolean;
    timeout?: number;
    headers?: HeadersInit;
}

Hierarchy (view full)

Properties

baseCurrency?: string
minified?: boolean
timeout?: number
headers?: HeadersInit
+ \ No newline at end of file diff --git a/docs/interfaces/index.HttpRequestOptions.html b/docs/interfaces/index.HttpRequestOptions.html new file mode 100644 index 0000000..413a91a --- /dev/null +++ b/docs/interfaces/index.HttpRequestOptions.html @@ -0,0 +1,177 @@ +HttpRequestOptions | @kabeep/forex - v1.0.0-alpha

Interface HttpRequestOptions

interface HttpRequestOptions {
    timeout?: number;
    headers?: HeadersInit;
}

Hierarchy (view full)

Properties

Properties

timeout?: number
headers?: HeadersInit
+ \ No newline at end of file diff --git a/docs/interfaces/index.HttpResponse.html b/docs/interfaces/index.HttpResponse.html new file mode 100644 index 0000000..9fa0a91 --- /dev/null +++ b/docs/interfaces/index.HttpResponse.html @@ -0,0 +1,178 @@ +HttpResponse | @kabeep/forex - v1.0.0-alpha

Interface HttpResponse<T>

interface HttpResponse<T> {
    code: number;
    message: string;
    data?: T;
}

Type Parameters

  • T

Properties

Properties

code: number
message: string
data?: T
+ \ No newline at end of file diff --git a/docs/modules.html b/docs/modules.html new file mode 100644 index 0000000..dab6904 --- /dev/null +++ b/docs/modules.html @@ -0,0 +1,177 @@ +@kabeep/forex - v1.0.0-alpha

@kabeep/forex

Index

Documents

Modules

+ \ No newline at end of file diff --git a/docs/modules/index._internal_.html b/docs/modules/index._internal_.html new file mode 100644 index 0000000..3bfb88a --- /dev/null +++ b/docs/modules/index._internal_.html @@ -0,0 +1,180 @@ +<internal> | @kabeep/forex - v1.0.0-alpha

Index

Classes

Type Aliases

+ \ No newline at end of file diff --git a/docs/modules/index.html b/docs/modules/index.html new file mode 100644 index 0000000..08eacf3 --- /dev/null +++ b/docs/modules/index.html @@ -0,0 +1,187 @@ +index | @kabeep/forex - v1.0.0-alpha
+ \ No newline at end of file diff --git a/docs/types/index.OriginalExchangeRates.html b/docs/types/index.OriginalExchangeRates.html new file mode 100644 index 0000000..79d05ba --- /dev/null +++ b/docs/types/index.OriginalExchangeRates.html @@ -0,0 +1,175 @@ +OriginalExchangeRates | @kabeep/forex - v1.0.0-alpha

Type Alias OriginalExchangeRates

OriginalExchangeRates: {
    [key: string]: Record<string, number>;
} & {
    date: string;
}
+ \ No newline at end of file diff --git a/docs/types/index._internal_.HeadersInit.html b/docs/types/index._internal_.HeadersInit.html new file mode 100644 index 0000000..be3ea76 --- /dev/null +++ b/docs/types/index._internal_.HeadersInit.html @@ -0,0 +1,175 @@ +HeadersInit | @kabeep/forex - v1.0.0-alpha
HeadersInit: [string, string][] | Record<string, string> | Headers
+ \ No newline at end of file diff --git a/docs/types/index._internal_.Pick.html b/docs/types/index._internal_.Pick.html new file mode 100644 index 0000000..fc86c06 --- /dev/null +++ b/docs/types/index._internal_.Pick.html @@ -0,0 +1,176 @@ +Pick | @kabeep/forex - v1.0.0-alpha
Pick<T, K>: {
    [P in K]: T[P]
}

From T, pick a set of properties whose keys are in the union K

+

Type Parameters

  • T
  • K extends keyof T
+ \ No newline at end of file diff --git a/docs/types/index._internal_.Record.html b/docs/types/index._internal_.Record.html new file mode 100644 index 0000000..68a695b --- /dev/null +++ b/docs/types/index._internal_.Record.html @@ -0,0 +1,176 @@ +Record | @kabeep/forex - v1.0.0-alpha

Type Alias Record<K, T>

Record<K, T>: {
    [P in K]: T
}

Construct a type with a set of properties K of type T

+

Type Parameters

  • K extends keyof any
  • T
+ \ No newline at end of file diff --git a/docs/variables/index.BASE_URL.html b/docs/variables/index.BASE_URL.html new file mode 100644 index 0000000..6b7a37b --- /dev/null +++ b/docs/variables/index.BASE_URL.html @@ -0,0 +1,179 @@ +BASE_URL | @kabeep/forex - v1.0.0-alpha

Variable BASE_URLConst

BASE_URL: "https://cdn.jsdelivr.net/npm/@fawazahmed0/currency-api" = 'https://cdn.jsdelivr.net/npm/@fawazahmed0/currency-api'

https://github.com/fawazahmed0/exchange-api

+
export const BASE_URL =
'https://cdn.jsdelivr.net/npm/@fawazahmed0/currency-api'; +
+ +
+ \ No newline at end of file diff --git a/docs/variables/index.BASE_URL_VERSION.html b/docs/variables/index.BASE_URL_VERSION.html new file mode 100644 index 0000000..0360ef6 --- /dev/null +++ b/docs/variables/index.BASE_URL_VERSION.html @@ -0,0 +1,179 @@ +BASE_URL_VERSION | @kabeep/forex - v1.0.0-alpha

Variable BASE_URL_VERSIONConst

BASE_URL_VERSION: "v1" = 'v1'

https://github.com/fawazahmed0/exchange-api

+
export const BASE_URL_VERSION = 'v1';
+
+ +
+ \ No newline at end of file diff --git a/docs/variables/index.LOCALE_CURRENCY.html b/docs/variables/index.LOCALE_CURRENCY.html new file mode 100644 index 0000000..b82e93f --- /dev/null +++ b/docs/variables/index.LOCALE_CURRENCY.html @@ -0,0 +1,179 @@ +LOCALE_CURRENCY | @kabeep/forex - v1.0.0-alpha

Variable LOCALE_CURRENCYConst

LOCALE_CURRENCY: {
    AD: string;
    AE: string;
    AF: string;
    AG: string;
    AI: string;
    AL: string;
    AM: string;
    AO: string;
    AR: string;
    AS: string;
    AT: string;
    AU: string;
    AW: string;
    AX: string;
    AZ: string;
    BA: string;
    BB: string;
    BD: string;
    BE: string;
    BF: string;
    BG: string;
    BH: string;
    BI: string;
    BJ: string;
    BL: string;
    BM: string;
    BN: string;
    BO: string;
    BQ: string;
    BR: string;
    BS: string;
    BT: string;
    BV: string;
    BW: string;
    BY: string;
    BZ: string;
    CA: string;
    CC: string;
    CD: string;
    CF: string;
    CG: string;
    CH: string;
    CI: string;
    CK: string;
    CL: string;
    CM: string;
    CN: string;
    CO: string;
    CR: string;
    CU: string;
    CV: string;
    CW: string;
    CX: string;
    CY: string;
    CZ: string;
    DE: string;
    DJ: string;
    DK: string;
    DM: string;
    DO: string;
    DZ: string;
    EC: string;
    EE: string;
    EG: string;
    EH: string;
    ER: string;
    ES: string;
    ET: string;
    FI: string;
    FJ: string;
    FK: string;
    FM: string;
    FO: string;
    FR: string;
    GA: string;
    GB: string;
    GD: string;
    GE: string;
    GF: string;
    GG: string;
    GH: string;
    GI: string;
    GL: string;
    GM: string;
    GN: string;
    GP: string;
    GQ: string;
    GR: string;
    GS: string;
    GT: string;
    GU: string;
    GW: string;
    GY: string;
    HK: string;
    HM: string;
    HN: string;
    HR: string;
    HT: string;
    HU: string;
    ID: string;
    IE: string;
    IL: string;
    IM: string;
    IN: string;
    IO: string;
    IQ: string;
    IR: string;
    IS: string;
    IT: string;
    JE: string;
    JM: string;
    JO: string;
    JP: string;
    KE: string;
    KG: string;
    KH: string;
    KI: string;
    KM: string;
    KN: string;
    KP: string;
    KR: string;
    KW: string;
    KY: string;
    KZ: string;
    LA: string;
    LB: string;
    LC: string;
    LI: string;
    LK: string;
    LR: string;
    LS: string;
    LT: string;
    LU: string;
    LV: string;
    LY: string;
    MA: string;
    MC: string;
    MD: string;
    ME: string;
    MF: string;
    MG: string;
    MH: string;
    MK: string;
    ML: string;
    MM: string;
    MN: string;
    MO: string;
    MP: string;
    MQ: string;
    MR: string;
    MS: string;
    MT: string;
    MU: string;
    MV: string;
    MW: string;
    MX: string;
    MY: string;
    MZ: string;
    NA: string;
    NC: string;
    NE: string;
    NF: string;
    NG: string;
    NI: string;
    NL: string;
    NO: string;
    NP: string;
    NR: string;
    NU: string;
    NZ: string;
    OM: string;
    PA: string;
    PE: string;
    PF: string;
    PG: string;
    PH: string;
    PK: string;
    PL: string;
    PM: string;
    PN: string;
    PR: string;
    PS: string;
    PT: string;
    PW: string;
    PY: string;
    QA: string;
    RE: string;
    RO: string;
    RS: string;
    RU: string;
    RW: string;
    SA: string;
    SB: string;
    SC: string;
    SD: string;
    SE: string;
    SG: string;
    SH: string;
    SI: string;
    SJ: string;
    SK: string;
    SL: string;
    SM: string;
    SN: string;
    SO: string;
    SR: string;
    ST: string;
    SV: string;
    SX: string;
    SY: string;
    SZ: string;
    TC: string;
    TD: string;
    TF: string;
    TG: string;
    TH: string;
    TJ: string;
    TK: string;
    TL: string;
    TM: string;
    TN: string;
    TO: string;
    TR: string;
    TT: string;
    TV: string;
    TW: string;
    TZ: string;
    UA: string;
    UG: string;
    UM: string;
    US: string;
    UY: string;
    UZ: string;
    VA: string;
    VC: string;
    VE: string;
    VG: string;
    VI: string;
    VN: string;
    VU: string;
    WF: string;
    WS: string;
    YE: string;
    YT: string;
    ZA: string;
    ZM: string;
    ZW: string;
} = ...

https://en.wikipedia.org/wiki/ISO_4217#Active_codes_(list_one)

+
export const LOCALE_CURRENCY = {
AD: 'EUR',
AE: 'AED',
AF: 'AFN',
AG: 'XCD',
AI: 'XCD',
AL: 'ALL',
AM: 'AMD',
AO: 'AOA',
AR: 'ARS',
AS: 'USD',
AT: 'EUR',
AU: 'AU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
KG: 'KGS',
KH: 'KHR',
KI: 'AUD',
KM: 'KMF',
KN: 'XCD',
KP: 'KPW',
KR: 'KRW',
KW: 'KWD',
KY: 'KYD',
KZ: 'KZT',
LA: 'LAK',
LB: 'LBP',
LC: 'XCD',
LI: 'CHF',
LK: 'LKR',
LR: 'LRD',
LS: 'LSL',
LT: 'EUR',
LU: 'EUR',
LV: 'EUR',
LY: 'LYD',
MA: 'MAD',
MC: 'EUR',
MD: 'MDL',
ME: 'EUR',
MF: 'EUR',
MG: 'MGA',
MH: 'USD',
MK: 'MKD',
ML: 'XOF',
MM: 'MMK',
MN: 'MNT',
MO: 'MOP',
MP: 'USD',
MQ: 'EUR',
MR: 'MRO',
MS: 'XCD',
MT: 'EUR',
MU: 'MUR',
MV: 'MVR',
MW: 'MWK',
MX: 'MXN',
MY: 'MYR',
MZ: 'MZN',
NA: 'NAD',
NC: 'XPF',
NE: 'XOF',
NF: 'AUD',
NG: 'NGN',
NI: 'NIO',
NL: 'EUR',
NO: 'NOK',
NP: 'NPR',
NR: 'AUD',
NU: 'NZD',
NZ: 'NZD',
OM: 'OMR',
PA: 'PAB',
PE: 'PEN',
PF: 'XPF',
PG: 'PGK',
PH: 'PHP',
PK: 'PKR',
PL: 'PLN',
PM: 'EUR',
PN: 'NZD',
PR: 'USD',
PS: 'ILS',
PT: 'EUR',
PW: 'USD',
PY: 'PYG',
QA: 'QAR',
RE: 'EUR',
RO: 'RON',
RS: 'RSD',
RU: 'RUB',
RW: 'RWF',
SA: 'SAR',
SB: 'SBD',
SC: 'SCR',
SD: 'SDG',
SE: 'SEK',
SG: 'SGD',
SH: 'SHP',
SI: 'EUR',
SJ: 'NOK',
SK: 'EUR',
SL: 'SLL',
SM: 'EUR',
SN: 'XOF',
SO: 'SOS',
SR: 'SRD',
ST: 'STD',
SV: 'SVC',
SX: 'ANG',
SY: 'SYP',
SZ: 'SZL',
TC: 'USD',
TD: 'XAF',
TF: 'EUR',
TG: 'XOF',
TH: 'THB',
TJ: 'TJS',
TK: 'NZD',
TL: 'USD',
TM: 'TMT',
TN: 'TND',
TO: 'TOP',
TR: 'TRY',
TT: 'TTD',
TV: 'AUD',
TW: 'TWD',
TZ: 'TZS',
UA: 'UAH',
UG: 'UGX',
UM: 'USD',
US: 'USD',
UY: 'UYU',
UZ: 'UZS',
VA: 'EUR',
VC: 'XCD',
VE: 'VEF',
VG: 'USD',
VI: 'USD',
VN: 'VND',
VU: 'VUV',
WF: 'XPF',
WS: 'WST',
YE: 'YER',
YT: 'EUR',
ZA: 'ZAR',
ZM: 'ZMW',
ZW: 'ZWL',
}; +
+ +
+ \ No newline at end of file diff --git a/docs/variables/index.NON_STANDARD_CODES.html b/docs/variables/index.NON_STANDARD_CODES.html new file mode 100644 index 0000000..f4f6bcf --- /dev/null +++ b/docs/variables/index.NON_STANDARD_CODES.html @@ -0,0 +1,179 @@ +NON_STANDARD_CODES | @kabeep/forex - v1.0.0-alpha

Variable NON_STANDARD_CODESConst

NON_STANDARD_CODES: {
    BDS: string;
    CNT: string;
    NIS: string;
    NTD: string;
    STG: string;
    RMB: string;
} = ...

https://en.wikipedia.org/wiki/ISO_4217#Non-standard_codes

+
export const NON_STANDARD_CODES = {
BDS: 'BBD',
CNT: 'TWD',
NIS: 'ILS',
NTD: 'TWD',
STG: 'GBP',
RMB: 'CNY',
}; +
+ +
+ \ No newline at end of file