🔧:build SSR dist and deploy

This commit is contained in:
NEO 2024-04-28 00:48:29 +08:00
parent 76c26901d7
commit c59ad6aedb
465 changed files with 214127 additions and 2 deletions

19
dist/server/chunks/chunk-5f44352e.js vendored Normal file
View file

@ -0,0 +1,19 @@
function convertBase({ value, fromBase, toBase }) {
const range = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ+/".split("");
const fromRange = range.slice(0, fromBase);
const toRange = range.slice(0, toBase);
let decValue = value.split("").reverse().reduce((carry, digit, index) => {
if (!fromRange.includes(digit)) {
throw new Error(`Invalid digit "${digit}" for base ${fromBase}.`);
}
return carry += fromRange.indexOf(digit) * fromBase ** index;
}, 0);
let newValue = "";
while (decValue > 0) {
newValue = toRange[decValue % toBase] + newValue;
decValue = (decValue - decValue % toBase) / toBase;
}
return newValue || "0";
}
export { convertBase as c };