All-In-One Tool Platform
All conversions run locally in your browser. No files will be uploaded to external servers.
Advertising Cooperation
Contact Email:lvyiming2015@163.com
QR Code Generator (Manual Mask Selection Supported)
Code128 Barcode
DOCX → TXT (Extract Text from Word)

Only .docx supported; legacy .doc files cannot be parsed.

PDF → PNG Images (Export by Pages)
Markdown ↔ HTML
CSV ↔ JSON
Image Convert / Compress (PNG/JPG/WebP/GIF)
File ↔ Base64
JSON Formatter / Minifier
URL Encode / Decode
Timestamp ↔ Datetime
Color Hex ↔ RGB
Text Toolbox
ZIP Compress / Extract (Client-Side Processing)

Extract: Upload zip to preview and download internal files; Compress: Select multiple files and package into zip.

1. Extract ZIP

2. Package Files into ZIP

Website Introduction

This website provides a set of free client-side web tools, including QR code generation, barcode creation, document conversion, image processing, JSON formatting, file compression and other auxiliary utilities.

All data processing happens locally within your browser. Any text, images and documents you upload will not be transmitted to remote servers. We cannot access, view, store or retrieve your uploaded content under any circumstances.

All tool functions rely on open-source front-end libraries loaded via public CDNs. No user content is shared with CDN providers.

Notice: You are prohibited from using this tool to process copyrighted materials, confidential documents, illegal, infringing or sensitive content. Users bear full legal responsibility for all files and content processed by themselves.

Privacy Policy

1. No user data collection: This website does not collect, record or store personal information, uploaded files, input content, device identifiers or browsing records of visitors.

2. Local-only processing: All tool operations run locally on your device. Your data will never be sent to external servers for processing.

3. Cookies & Tracking: This website does not deploy persistent tracking cookies, visitor analytics scripts or behavioural tracking tools. Only temporary session storage inside your browser may be used for runtime function execution and cleared after you close the page. Third-party advertisements may set cookies for targeted advertising; you have the right to reject advertising cookies.

4. Data retention: We hold zero user data. No uploaded content or input information is saved on our servers, and no data retention cycle applies.

5. Third-party advertisements: Advertisements displayed on the page are served by independent advertising partners. We have no authority over their data collection practices. Please review the privacy policy of relevant advertising platforms.

6. Open-source libraries: The website loads open-source libraries from CDNs to implement features. CDN providers may collect basic connection logs. This website is not responsible for data handling of independent CDN service providers.

7. GDPR / CCPA Compliance: If you are located in regions covered by GDPR, CCPA or other global data protection laws, you acknowledge that no personal data is submitted to this website. You are entitled to refuse non-essential advertising cookies via the cookie consent banner.

8. California Residents Notice: We will never sell your personal information to any third party.

Disclaimer

1. All tools are provided on an "as-is" and "as-available" basis without any express or implied warranty, including but not limited to warranties of accuracy, stability, reliability and suitability for any specific purpose.

2. You use all website functions at your own risk. We shall not be liable for any data loss, file corruption or other losses arising from the use of these tools.

3. We reserve the right to modify, adjust or suspend website functions without prior notice to users.

4. Users are solely responsible for complying with applicable local, national and international laws when processing files, including all obligations related to copyright, confidential information and personal data.

5. Governing Law: These Terms shall be governed by the laws of the Republic of Singapore. Any dispute arising out of or in connection with the use of this website shall first be resolved amicably through negotiation.

6. Severability clause: If any provision of this disclaimer is found invalid under applicable law, only that clause shall be modified or removed, and the remaining terms shall remain fully enforceable.

7. Third-party advertisements displayed on the website are provided by independent advertising networks. We are not affiliated with advertisers, and we do not endorse any advertised products or services. All transactions with advertisers are solely between you and the advertiser.

All tools run locally in browser. No server processing required.
全部放这里 // ########## 在此行上方粘贴你的广告联盟代码 ########## } // ==================================================================== // 页面初始化:已有授权则自动处理广告 if(cookieConsentStatus){ document.getElementById('cookieBar').style.display = 'none'; if(cookieConsentStatus === "accept"){ loadAdvertising(); } } document.querySelectorAll('.tab-btn').forEach(btn=>{ btn.onclick=()=>{ document.querySelectorAll('.tab-btn').forEach(b=>{b.classList.remove('active');b.classList.add('normal');}) btn.classList.remove('normal');btn.classList.add('active'); document.querySelectorAll('.tab-panel').forEach(p=>p.classList.remove('show')); document.getElementById(btn.dataset.target).classList.add('show'); } }) function calculatePenalty(qrObj) { const size = qrObj.getModuleCount(); let penalty = 0; const module = (x, y) => qrObj.isDark(y, x); for (let y = 0; y < size; y++) { let runLen = 1; for (let x = 1; x < size; x++) { if (module(x, y) === module(x - 1, y)) runLen++; else runLen = 1; if (runLen >= 5) penalty += (runLen - 2); } } for (let x = 0; x < size; x++) { let runLen = 1; for (let y = 1; y < size; y++) { if (module(x, y) === module(x, y - 1)) runLen++; else runLen = 1; if (runLen >= 5) penalty += (runLen - 2); } } for (let y = 0; y < size - 1; y++) { for (let x = 0; x < size - 1; x++) { const c = module(x, y); if (c === module(x+1,y) && c === module(x,y+1) && c === module(x+1,y+1)) { penalty += 3; } } } return penalty; } function evaluateBestMask(content, ecl) { const eclMap = {L:"L",M:"M",Q:"Q",H:"H"}; const scoreList = []; for(let mask=0;mask<=7;mask++){ let qr = qrcode(0, eclMap[ecl]); qr.addData(content); qr.make({maskPattern:mask}); let score = calculatePenalty(qr); scoreList.push({mask,score}); } scoreList.sort((a,b)=>a.score - b.score); return scoreList[0].mask; } function createQr(){ try{ let txt=document.getElementById('qrText').value; let lv=document.getElementById('qrLevel').value; let mask=parseInt(document.getElementById('qrMask').value); let resWrap=document.getElementById('qrResult'); let evalTip = document.getElementById("maskEvalInfo"); resWrap.innerHTML=""; evalTip.textContent = ""; if(!txt){resWrap.innerText="Please input content";return;} let bestMask = evaluateBestMask(txt, lv); evalTip.textContent = `Mask evaluation completed: Recommended Mask ${bestMask} (best readability with lowest penalty score)`; let eclMap = {L:"L",M:"M",Q:"Q",H:"H"}; let qr = qrcode(0, eclMap[lv]); qr.addData(txt); if(mask >=0 && mask <=7){ qr.make({maskPattern:mask}); }else{ qr.make(); } resWrap.innerHTML = qr.createImgTag(6); }catch(err){ alert("Generate QRCode failed:"+err.message); console.error(err); } } function createBarcode(){ try{ let text=document.getElementById('barcodeText').value.trim(); if(!text){alert('Please input barcode content');return;} JsBarcode("#barcodeSvg",text,{format:"CODE128",height:80,fontSize:16}).render(); }catch(err){ alert("Generate Barcode failed:"+err.message); console.error(err); } } async function docxToTxt(){ try{ let f=document.getElementById('docxFile').files[0]; if(!f)return alert('Select a docx file'); let arr=await f.arrayBuffer(); let result=await mammoth.extractRawText({arrayBuffer:arr}); document.getElementById('txtOut').value=result.value; }catch(err){ alert("DOCX parse failed:"+err.message); console.error(err); } } async function pdfToImage(){ try{ let f=document.getElementById('pdfFile').files[0]; if(!f)return alert('Select PDF file'); let box=document.getElementById('pdfImgBox'); box.innerHTML="Loading..."; let buf=await f.arrayBuffer(); let pdf=await pdfjsLib.getDocument(buf).promise; box.innerHTML=""; for(let i=1;i<=pdf.numPages;i++){ let page=await pdf.getPage(i); let scale=1.5; let view=page.getViewport({scale}); let canvas=document.createElement('canvas'); let ctx=canvas.getContext('2d'); canvas.width=view.width;canvas.height=view.height; await page.render({canvasContext:ctx,viewport:view}).promise; let img=new Image();img.src=canvas.toDataURL("image/png"); img.className="preview-img";box.append(img); } }catch(err){ alert("PDF parse failed:"+err.message); console.error(err); } } function mdToHtml(){ try{ let i=document.getElementById('mdHtmlIn').value; let rawHtml = marked.parse(i); // DOMPurify 净化HTML,彻底封堵XSS漏洞 let safeHtml = DOMPurify.sanitize(rawHtml); document.getElementById('mdHtmlOut').value=safeHtml; }catch(err){ alert("Markdown convert failed:"+err.message); console.error(err); } } function htmlToMd(){ alert("HTML to Markdown conversion function is under development. Only Markdown to HTML conversion is available now."); } function csvToJson(){ try{ let text=document.getElementById('csvJsonIn').value.trim(); let lines=text.split("\n").filter(x=>x); let header=lines[0].split(','); let arr=[]; for(let r=1;robj[h.trim()]=cells[idx]?.trim()||""); arr.push(obj); } document.getElementById('csvJsonOut').value=JSON.stringify(arr,null,2); }catch(err){ alert("CSV parse failed:"+err.message); console.error(err); } } function jsonToCsv(){ try{ let str=document.getElementById('csvJsonIn').value; let data=JSON.parse(str); if(!Array.isArray(data))return alert('JSON array required'); let keys=Object.keys(data[0]); let csv=[keys.join(',')]; data.forEach(d=>csv.push(keys.map(k=>d[k]).join(','))); document.getElementById('csvJsonOut').value=csv.join('\n'); }catch(err){ alert("Convert JSON to CSV failed:"+err.message); console.error(err); } } function convertImage(){ try{ let f=document.getElementById('imgFile').files[0]; if(!f)return alert('Select an image file'); let target=document.getElementById('imgTarget').value; let reader=new FileReader(); reader.onload=e=>{ let img=new Image(); img.onload=()=>{ let canvas=document.createElement('canvas'); canvas.width=img.width;canvas.height=img.height; let ctx=canvas.getContext('2d'); ctx.drawImage(img,0,0); let url=canvas.toDataURL(target,0.85); let box=document.getElementById('imgBox'); box.innerHTML=`
Click to download image`; }; img.src=e.target.result; }; reader.readAsDataURL(f); }catch(err){ alert("Image convert failed:"+err.message); console.error(err); } } function fileToBase64(){ try{ let f=document.getElementById('base64File').files[0]; let r=new FileReader(); r.onload=e=>document.getElementById('base64Str').value=e.target.result; r.readAsDataURL(f); }catch(err){ alert("File convert base64 failed:"+err.message); console.error(err); } } function base64ToFile(){ try{ let str=document.getElementById('base64Str').value; if(!str.startsWith("data"))return alert("Not valid file base64"); let a=document.createElement('a'); a.href=str;a.download="file";a.click(); }catch(err){ alert("Base64 export file failed:"+err.message); console.error(err); } } function jsonFormat(){ try{ let j=JSON.parse(document.getElementById('jsonIn').value); document.getElementById('jsonOut').value=JSON.stringify(j,null,2); }catch{alert("Invalid JSON format");} } function jsonMinify(){ try{ let j=JSON.parse(document.getElementById('jsonIn').value); document.getElementById('jsonOut').value=JSON.stringify(j); }catch{alert("Invalid JSON format");} } function urlEncode(){ try{ document.getElementById('urlOut').value=encodeURIComponent(document.getElementById('urlIn').value); }catch(err){ alert("URL Encode failed:"+err.message); } } function urlDecode(){ try{ document.getElementById('urlOut').value=decodeURIComponent(document.getElementById('urlIn').value); }catch(err){ alert("URL Decode failed:"+err.message); } } function timeConvert(){ try{ let val=document.getElementById('timeInput').value.trim(); let res; if(/^\d+$/.test(val)){ let num=val.length>10?parseInt(val):parseInt(val)*1000; res=new Date(num).toString(); }else{ res=new Date(val).getTime()/1000; } document.getElementById('timeOutput').value=res; }catch(err){ alert("Time convert failed:"+err.message); } } function colorConvert(){ try{ let c=document.getElementById('colorInput').value.trim(); let out=document.getElementById('colorOutput'); if(c.startsWith('#')){ let r=parseInt(c.slice(1,3),16); let g=parseInt(c.slice(3,5),16); let b=parseInt(c.slice(5,7),16); out.value=`rgb(${r},${g},${b})`; }else if(c.startsWith('rgb')){ let nums=c.match(/\d+/g); let toHex=x=>("0"+parseInt(x).toString(16)).slice(-2); out.value=`#${toHex(nums[0])}${toHex(nums[1])}${toHex(nums[2])}`; } }catch(err){ alert("Color convert failed:"+err.message); } } function textUpper(){try{document.getElementById('textOut').value=document.getElementById('textIn').value.toUpperCase();}catch(e){}} function textLower(){try{document.getElementById('textOut').value=document.getElementById('textIn').value.toLowerCase();}catch(e){}} function clearSpace(){try{document.getElementById('textOut').value=document.getElementById('textIn').value.replace(/\s+/g,' ').trim();}catch(e){}} async function unzipFile(){ try{ const file = document.getElementById("unzipFile").files[0]; if(!file) return alert("Please select zip file"); if(file.size > MAX_UNZIP_SIZE){ return alert(`Zip file cannot exceed ${Math.round(MAX_UNZIP_SIZE/1024/1024)}MB`); } const zipData = await file.arrayBuffer(); const zip = await JSZip.loadAsync(zipData); const listBox = document.getElementById("unzipList"); listBox.innerHTML = ""; for(const [path,entry] of Object.entries(zip.files)){ if(entry.dir) continue; const div = document.createElement("div"); div.className = "file-item"; div.innerHTML = `${path} `; listBox.appendChild(div); } zipCacheObj = zip; }catch(err){ alert("Failed to parse zip file:"+err.message); console.error(err); } } async function downloadEntry(path){ try{ const entry = zipCacheObj.file(path); const blob = await entry.async("blob"); const a = document.createElement("a"); a.href = URL.createObjectURL(blob); a.download = path.split("/").pop(); a.click(); }catch(err){ alert("File download failed:"+err.message); console.error(err); } } async function zipFiles(){ try{ const fileList = document.getElementById("zipFiles").files; if(fileList.length===0) return alert("Select files to compress"); const zip = new JSZip(); for(let f of fileList){ zip.file(f.name,f); } const blob = await zip.generateAsync({type:"blob"}); const a = document.createElement("a"); a.href = URL.createObjectURL(blob); a.download = "archive.zip"; a.click(); }catch(err){ alert("Create zip failed:"+err.message); console.error(err); } }