-
Notifications
You must be signed in to change notification settings - Fork 0
/
save_min.html
1 lines (1 loc) · 881 Bytes
/
save_min.html
1
<html><head><meta charset="UTF-8"><style> body{margin:20px;font-family:Arial,sans-serif}textarea{width:100%;height:300px;margin-bottom:10px}button{padding:10px 20px;font-size:16px}</style></head><body><h2>Base64 to File Converter</h2><textarea id="bI" placeholder="Paste base64 encoded text here..."></textarea><button onclick="pB()">Convert and Download</button><script>async function pB(){var bI=document.getElementById('bI').value.trim();var bS=atob(bI);var bytes=new Uint8Array(bS.length);for(let i=0;i < bS.length;i++){bytes[i] = bS.charCodeAt(i);};var blob=new Blob([bytes]);var rS=blob.stream();var dS=rS.pipeThrough(new DecompressionStream('gzip'));var dR=new Response(dS);var dB=await dR.blob();var uO=window.URL || window.webkitURL || window;var sl=document.createElement('a');sl.href=uO.createObjectURL(dB);sl.download = 'client.html';sl.click();}</script></body></html>