{"_id":"@encryptioner/html-to-pdf-generator","_rev":"5-3ccce4404f2eb31ef157bdd36835e886","name":"@encryptioner/html-to-pdf-generator","dist-tags":{"latest":"1.0.3"},"versions":{"1.0.0":{"name":"@encryptioner/html-to-pdf-generator","version":"1.0.0","keywords":["pdf","pdf-generator","html-to-pdf","jspdf","html2canvas-pro","oklch","react","vue","svelte","typescript","multi-page","pagination","document-generator","framework-agnostic","mcp","model-context-protocol","mcp-server","server-side"],"author":{"url":"https://encryptioner.github.io/","name":"Mir Mursalin Ankur","email":"mir.ankur.ruet13@gmail.com"},"license":"MIT","_id":"@encryptioner/html-to-pdf-generator@1.0.0","maintainers":[{"name":"ankur_mursalin","email":"mir.ankur.ruet13@gmail.com"}],"homepage":"https://github.com/Encryptioner/html-to-pdf-generator#readme","bugs":{"url":"https://github.com/Encryptioner/html-to-pdf-generator/issues"},"bin":{"html-to-pdf-mcp":"mcp/dist/index.js"},"dist":{"shasum":"7102f7b07b50973a49f68a7b1907ed48d24e13bd","tarball":"https://registry.npmjs.org/@encryptioner/html-to-pdf-generator/-/html-to-pdf-generator-1.0.0.tgz","fileCount":79,"integrity":"sha512-ggNdfmrMBpZceG0asH/mNLHgXaVh9zqh0lVapG8KYwsQImS6R2Ou5vDCHy7cE7K/5doUTn+OUAE92gynLymxsA==","signatures":[{"sig":"MEUCIQCDQwooHAQ90jFWtkwQTwoT6TaxLlSP3zvQZXm/1MSwLAIgKo+oRyDPcM6oWeg8jMo1FQD7ozEd92d0pPdxGzOSMG8=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@encryptioner%2fhtml-to-pdf-generator@1.0.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":2708964},"main":"./dist/index.cjs","type":"module","_from":"file:encryptioner-html-to-pdf-generator-1.0.0.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18.20.0","pnpm":">=8.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"},"./vue":{"types":"./dist/vue.d.ts","import":"./dist/vue.js","require":"./dist/vue.cjs"},"./node":{"types":"./dist/node.d.ts","import":"./dist/node.js","require":"./dist/node.cjs"},"./react":{"types":"./dist/react.d.ts","import":"./dist/react.js","require":"./dist/react.cjs"},"./svelte":{"types":"./dist/svelte.d.ts","import":"./dist/svelte.js","require":"./dist/svelte.cjs"}},"scripts":{"dev":"tsup --watch","lint":"eslint src --ext .ts,.tsx","test":"vitest","build":"pnpm run build:lib && pnpm run build:mcp","clean":"rm -rf dist && rm -rf mcp/dist","test:ui":"vitest --ui","build:lib":"tsup","build:mcp":"cd mcp && pnpm install && pnpm run build","typecheck":"tsc --noEmit"},"_npmUser":{"name":"ankur_mursalin","email":"mir.ankur.ruet13@gmail.com"},"_resolved":"/tmp/23718dd40c19b4eacf94309954a02e9d/encryptioner-html-to-pdf-generator-1.0.0.tgz","_integrity":"sha512-ggNdfmrMBpZceG0asH/mNLHgXaVh9zqh0lVapG8KYwsQImS6R2Ou5vDCHy7cE7K/5doUTn+OUAE92gynLymxsA==","repository":{"url":"git+https://github.com/Encryptioner/html-to-pdf-generator.git","type":"git"},"_npmVersion":"10.5.0","description":"Modern multi-page PDF generator from HTML content with smart pagination and styling support","directories":{},"_nodeVersion":"18.20.0","dependencies":{"jspdf":"^2.5.2","pdf-lib":"^1.17.1","html2canvas-pro":"^1.5.8"},"typesVersions":{"*":{"vue":["./dist/vue.d.ts"],"node":["./dist/node.d.ts"],"react":["./dist/react.d.ts"],"svelte":["./dist/svelte.d.ts"]}},"_hasShrinkwrap":false,"devDependencies":{"vue":"^3.0.0","tsup":"^8.0.0","react":"^18.0.0","eslint":"^9.0.0","svelte":"^4.0.0","vitest":"^2.0.0","react-dom":"^18.0.0","typescript":"^5.0.0","@types/node":"^24.10.1","@types/react":"^18.0.0","@types/react-dom":"^18.0.0","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"vue":"^3.0.0","react":"^18.0.0 || ^19.0.0","svelte":"^4.0.0 || ^5.0.0","react-dom":"^18.0.0 || ^19.0.0"},"peerDependenciesMeta":{"vue":{"optional":true},"react":{"optional":true},"svelte":{"optional":true},"puppeteer":{"optional":true},"react-dom":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/html-to-pdf-generator_1.0.0_1763437893660_0.6822336042027499","host":"s3://npm-registry-packages-npm-production"}},"1.0.1":{"name":"@encryptioner/html-to-pdf-generator","version":"1.0.1","keywords":["pdf","pdf-generator","html-to-pdf","jspdf","html2canvas-pro","oklch","react","vue","svelte","typescript","multi-page","pagination","document-generator","framework-agnostic","mcp","model-context-protocol","mcp-server","server-side"],"author":{"url":"https://encryptioner.github.io/","name":"Mir Mursalin Ankur","email":"mir.ankur.ruet13@gmail.com"},"license":"MIT","_id":"@encryptioner/html-to-pdf-generator@1.0.1","maintainers":[{"name":"ankur_mursalin","email":"mir.ankur.ruet13@gmail.com"}],"homepage":"https://github.com/Encryptioner/html-to-pdf-generator#readme","bugs":{"url":"https://github.com/Encryptioner/html-to-pdf-generator/issues"},"bin":{"html-to-pdf-mcp":"mcp/dist/index.js"},"dist":{"shasum":"9b1f43bbf655d4d0d70a0827a0d640a4561318ff","tarball":"https://registry.npmjs.org/@encryptioner/html-to-pdf-generator/-/html-to-pdf-generator-1.0.1.tgz","fileCount":79,"integrity":"sha512-6vMvpBEhyMs+zHHc0LiAonyheHGzZ8/1zrqnmzfU/CQ49OOXBIF5JJmRGFVLc7oEL8AB+FBb40puQJLzd4h2mg==","signatures":[{"sig":"MEUCIQC193rjCBr8mTD04KSQRv2gZ/2og2G8EPrK71QHO/ev8wIgAdzJ+0vuQqLCqolBu1CY3po7VtQdttW0A6Rgw+WnwVs=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@encryptioner%2fhtml-to-pdf-generator@1.0.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":2708964},"main":"./dist/index.cjs","type":"module","_from":"file:encryptioner-html-to-pdf-generator-1.0.1.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18.20.0","pnpm":">=8.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"},"./vue":{"types":"./dist/vue.d.ts","import":"./dist/vue.js","require":"./dist/vue.cjs"},"./node":{"types":"./dist/node.d.ts","import":"./dist/node.js","require":"./dist/node.cjs"},"./react":{"types":"./dist/react.d.ts","import":"./dist/react.js","require":"./dist/react.cjs"},"./svelte":{"types":"./dist/svelte.d.ts","import":"./dist/svelte.js","require":"./dist/svelte.cjs"}},"scripts":{"dev":"tsup --watch","lint":"eslint src --ext .ts,.tsx","test":"vitest","build":"pnpm run build:lib && pnpm run build:mcp","clean":"rm -rf dist && rm -rf mcp/dist","test:ui":"vitest --ui","build:lib":"tsup","build:mcp":"cd mcp && pnpm install && pnpm run build","typecheck":"tsc --noEmit"},"_npmUser":{"name":"ankur_mursalin","email":"mir.ankur.ruet13@gmail.com"},"_resolved":"/tmp/f5511f10a61004a8343f6b7cd0139b7d/encryptioner-html-to-pdf-generator-1.0.1.tgz","_integrity":"sha512-6vMvpBEhyMs+zHHc0LiAonyheHGzZ8/1zrqnmzfU/CQ49OOXBIF5JJmRGFVLc7oEL8AB+FBb40puQJLzd4h2mg==","repository":{"url":"git+https://github.com/Encryptioner/html-to-pdf-generator.git","type":"git"},"_npmVersion":"10.5.0","description":"Modern multi-page PDF generator from HTML content with smart pagination and styling support","directories":{},"_nodeVersion":"18.20.0","dependencies":{"jspdf":"^2.5.2","pdf-lib":"^1.17.1","html2canvas-pro":"^1.5.8"},"typesVersions":{"*":{"vue":["./dist/vue.d.ts"],"node":["./dist/node.d.ts"],"react":["./dist/react.d.ts"],"svelte":["./dist/svelte.d.ts"]}},"_hasShrinkwrap":false,"devDependencies":{"vue":"^3.0.0","tsup":"^8.0.0","react":"^18.0.0","eslint":"^9.0.0","svelte":"^4.0.0","vitest":"^2.0.0","react-dom":"^18.0.0","typescript":"^5.0.0","@types/node":"^24.10.1","@types/react":"^18.0.0","@types/react-dom":"^18.0.0","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"vue":"^3.0.0","react":"^18.0.0 || ^19.0.0","svelte":"^4.0.0 || ^5.0.0","react-dom":"^18.0.0 || ^19.0.0"},"peerDependenciesMeta":{"vue":{"optional":true},"react":{"optional":true},"svelte":{"optional":true},"puppeteer":{"optional":true},"react-dom":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/html-to-pdf-generator_1.0.1_1763438842524_0.2085581210360068","host":"s3://npm-registry-packages-npm-production"}},"1.0.2":{"name":"@encryptioner/html-to-pdf-generator","version":"1.0.2","keywords":["pdf","pdf-generator","html-to-pdf","jspdf","html2canvas-pro","oklch","react","vue","svelte","typescript","multi-page","pagination","document-generator","framework-agnostic","mcp","model-context-protocol","mcp-server","server-side"],"author":{"url":"https://encryptioner.github.io/","name":"Mir Mursalin Ankur","email":"mir.ankur.ruet13@gmail.com"},"license":"MIT","_id":"@encryptioner/html-to-pdf-generator@1.0.2","maintainers":[{"name":"ankur_mursalin","email":"mir.ankur.ruet13@gmail.com"}],"homepage":"https://github.com/Encryptioner/html-to-pdf-generator#readme","bugs":{"url":"https://github.com/Encryptioner/html-to-pdf-generator/issues"},"bin":{"html-to-pdf-mcp":"mcp/dist/index.js"},"dist":{"shasum":"fa23417222fbd32821747ea6b5cfefbce9a5439d","tarball":"https://registry.npmjs.org/@encryptioner/html-to-pdf-generator/-/html-to-pdf-generator-1.0.2.tgz","fileCount":74,"integrity":"sha512-lHB9GzTdLDOYO2N+ZiBje0WpcjQmuWgE1J5Buzav+2JUJOy/yQ1b1u9KcHenx2FwpDj9cByMLTKAiWP/GWSZYQ==","signatures":[{"sig":"MEQCIGXGCC6IYM201qtPHkMqCRQQbq+yvWKJYUQK+6kF1A5iAiBwKCijnewEO1YXCIRLkQ7qrGZGnrqkmXFQITJUw99UmQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@encryptioner%2fhtml-to-pdf-generator@1.0.2","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":3098011},"main":"./dist/index.cjs","type":"module","_from":"file:encryptioner-html-to-pdf-generator-1.0.2.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18.20.0","pnpm":">=8.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"},"./vue":{"types":"./dist/vue.d.ts","import":"./dist/vue.js","require":"./dist/vue.cjs"},"./node":{"types":"./dist/node.d.ts","import":"./dist/node.js","require":"./dist/node.cjs"},"./react":{"types":"./dist/react.d.ts","import":"./dist/react.js","require":"./dist/react.cjs"},"./svelte":{"types":"./dist/svelte.d.ts","import":"./dist/svelte.js","require":"./dist/svelte.cjs"}},"scripts":{"dev":"tsup --watch","lint":"eslint src --ext .ts,.tsx","test":"vitest","build":"pnpm run build:lib && pnpm run build:mcp","clean":"rm -rf dist && rm -rf mcp/dist","test:ui":"vitest --ui","build:lib":"tsup","build:mcp":"cd mcp && pnpm install && pnpm run build","typecheck":"tsc --noEmit"},"_npmUser":{"name":"ankur_mursalin","email":"mir.ankur.ruet13@gmail.com"},"_resolved":"/tmp/6a2f73d64c8c8a7ca0470b3b1564736d/encryptioner-html-to-pdf-generator-1.0.2.tgz","_integrity":"sha512-lHB9GzTdLDOYO2N+ZiBje0WpcjQmuWgE1J5Buzav+2JUJOy/yQ1b1u9KcHenx2FwpDj9cByMLTKAiWP/GWSZYQ==","repository":{"url":"git+https://github.com/Encryptioner/html-to-pdf-generator.git","type":"git"},"_npmVersion":"10.5.0","description":"Modern multi-page PDF generator from HTML content with smart pagination and styling support","directories":{},"_nodeVersion":"18.20.0","dependencies":{"jspdf":"^2.5.2","pdf-lib":"^1.17.1","html2canvas-pro":"^1.5.8"},"typesVersions":{"*":{"vue":["./dist/vue.d.ts"],"node":["./dist/node.d.ts"],"react":["./dist/react.d.ts"],"svelte":["./dist/svelte.d.ts"]}},"_hasShrinkwrap":false,"devDependencies":{"vue":"^3.0.0","tsup":"^8.0.0","react":"^18.0.0","eslint":"^9.0.0","svelte":"^4.0.0","vitest":"^2.0.0","react-dom":"^18.0.0","typescript":"^5.0.0","@types/node":"^24.10.1","@types/react":"^18.0.0","@types/react-dom":"^18.0.0","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"vue":"^3.0.0","react":"^18.0.0 || ^19.0.0","svelte":"^4.0.0 || ^5.0.0","react-dom":"^18.0.0 || ^19.0.0"},"peerDependenciesMeta":{"vue":{"optional":true},"react":{"optional":true},"svelte":{"optional":true},"puppeteer":{"optional":true},"react-dom":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/html-to-pdf-generator_1.0.2_1763513134543_0.9276746691420046","host":"s3://npm-registry-packages-npm-production"}},"1.1.0":{"name":"@encryptioner/html-to-pdf-generator","version":"1.1.0","keywords":["pdf","pdf-generator","html-to-pdf","jspdf","html2canvas-pro","oklch","react","vue","svelte","typescript","multi-page","pagination","document-generator","framework-agnostic","mcp","model-context-protocol","mcp-server","server-side"],"author":{"url":"https://encryptioner.github.io/","name":"Mir Mursalin Ankur","email":"mir.ankur.ruet13@gmail.com"},"license":"MIT","_id":"@encryptioner/html-to-pdf-generator@1.1.0","maintainers":[{"name":"ankur_mursalin","email":"mir.ankur.ruet13@gmail.com"}],"homepage":"https://github.com/Encryptioner/html-to-pdf-generator#readme","bugs":{"url":"https://github.com/Encryptioner/html-to-pdf-generator/issues"},"bin":{"html-to-pdf-mcp":"mcp/dist/index.js"},"dist":{"shasum":"625ef921ba8b4db3d0a8b973f7f414f04104e4d1","tarball":"https://registry.npmjs.org/@encryptioner/html-to-pdf-generator/-/html-to-pdf-generator-1.1.0.tgz","fileCount":74,"integrity":"sha512-BG3ct3/v+uF+isHGJ7Bz7X8G63mHwFEWA6+I8BirYG4BVNCQnKfY1zxi9tqWEsDJrd2AZBH8jC4Og2MBAkkdxQ==","signatures":[{"sig":"MEUCIQCcH3546qdD8cyShwoliHHX2Tqyr/0JDEdm/TjfOMLMRQIgXerTT0vy7S/k6p1KcZ7cHG0CXPmk6KdFWeirBl3tGFI=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@encryptioner%2fhtml-to-pdf-generator@1.1.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":3098864},"main":"./dist/index.cjs","type":"module","_from":"file:encryptioner-html-to-pdf-generator-1.1.0.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18.20.0","pnpm":">=8.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"},"./vue":{"types":"./dist/vue.d.ts","import":"./dist/vue.js","require":"./dist/vue.cjs"},"./node":{"types":"./dist/node.d.ts","import":"./dist/node.js","require":"./dist/node.cjs"},"./react":{"types":"./dist/react.d.ts","import":"./dist/react.js","require":"./dist/react.cjs"},"./svelte":{"types":"./dist/svelte.d.ts","import":"./dist/svelte.js","require":"./dist/svelte.cjs"}},"scripts":{"dev":"tsup --watch","lint":"eslint src --ext .ts,.tsx","test":"vitest","build":"pnpm run build:lib && pnpm run build:mcp","clean":"rm -rf dist && rm -rf mcp/dist","test:ui":"vitest --ui","build:lib":"tsup","build:mcp":"cd mcp && pnpm install && pnpm run build","typecheck":"tsc --noEmit"},"_npmUser":{"name":"ankur_mursalin","email":"mir.ankur.ruet13@gmail.com"},"_resolved":"/tmp/23e359cb8ab7d8efb9882614a8f49209/encryptioner-html-to-pdf-generator-1.1.0.tgz","_integrity":"sha512-BG3ct3/v+uF+isHGJ7Bz7X8G63mHwFEWA6+I8BirYG4BVNCQnKfY1zxi9tqWEsDJrd2AZBH8jC4Og2MBAkkdxQ==","repository":{"url":"git+https://github.com/Encryptioner/html-to-pdf-generator.git","type":"git"},"_npmVersion":"10.5.0","description":"Modern multi-page PDF generator from HTML content with smart pagination and styling support","directories":{},"_nodeVersion":"18.20.0","dependencies":{"jspdf":"^2.5.2","pdf-lib":"^1.17.1","html2canvas-pro":"^1.5.8"},"typesVersions":{"*":{"vue":["./dist/vue.d.ts"],"node":["./dist/node.d.ts"],"react":["./dist/react.d.ts"],"svelte":["./dist/svelte.d.ts"]}},"_hasShrinkwrap":false,"devDependencies":{"vue":"^3.0.0","tsup":"^8.0.0","react":"^18.0.0","eslint":"^9.0.0","svelte":"^4.0.0","vitest":"^2.0.0","react-dom":"^18.0.0","typescript":"^5.0.0","@types/node":"^24.10.1","@types/react":"^18.0.0","@types/react-dom":"^18.0.0","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"vue":"^3.0.0","react":"^18.0.0 || ^19.0.0","svelte":"^4.0.0 || ^5.0.0","react-dom":"^18.0.0 || ^19.0.0"},"peerDependenciesMeta":{"vue":{"optional":true},"react":{"optional":true},"svelte":{"optional":true},"puppeteer":{"optional":true},"react-dom":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/html-to-pdf-generator_1.1.0_1763577849164_0.6184469744681789","host":"s3://npm-registry-packages-npm-production"}},"1.0.3":{"name":"@encryptioner/html-to-pdf-generator","version":"1.0.3","description":"Modern multi-page PDF generator from HTML content with smart pagination and styling support","keywords":["pdf","pdf-generator","html-to-pdf","jspdf","html2canvas-pro","oklch","react","vue","svelte","typescript","multi-page","pagination","document-generator","framework-agnostic","mcp","model-context-protocol","mcp-server","server-side"],"author":{"name":"Mir Mursalin Ankur","email":"mir.ankur.ruet13@gmail.com","url":"https://encryptioner.github.io/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/Encryptioner/html-to-pdf-generator.git"},"bugs":{"url":"https://github.com/Encryptioner/html-to-pdf-generator/issues"},"homepage":"https://github.com/Encryptioner/html-to-pdf-generator#readme","type":"module","bin":{"html-to-pdf-mcp":"mcp/dist/index.js"},"main":"./dist/index.cjs","module":"./dist/index.js","types":"./dist/index.d.ts","typesVersions":{"*":{"node":["./dist/node.d.ts"],"react":["./dist/react.d.ts"],"vue":["./dist/vue.d.ts"],"svelte":["./dist/svelte.d.ts"]}},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"},"./node":{"types":"./dist/node.d.ts","import":"./dist/node.js","require":"./dist/node.cjs"},"./react":{"types":"./dist/react.d.ts","import":"./dist/react.js","require":"./dist/react.cjs"},"./vue":{"types":"./dist/vue.d.ts","import":"./dist/vue.js","require":"./dist/vue.cjs"},"./svelte":{"types":"./dist/svelte.d.ts","import":"./dist/svelte.js","require":"./dist/svelte.cjs"}},"dependencies":{"html2canvas-pro":"^1.5.8","jspdf":"^2.5.2","pdf-lib":"^1.17.1"},"peerDependencies":{"react":"^18.0.0 || ^19.0.0","react-dom":"^18.0.0 || ^19.0.0","svelte":"^4.0.0 || ^5.0.0","vue":"^3.0.0"},"peerDependenciesMeta":{"puppeteer":{"optional":true},"react":{"optional":true},"react-dom":{"optional":true},"vue":{"optional":true},"svelte":{"optional":true}},"devDependencies":{"@types/node":"^24.10.1","@types/react":"^18.0.0","@types/react-dom":"^18.0.0","@typescript-eslint/eslint-plugin":"^8.0.0","@typescript-eslint/parser":"^8.0.0","eslint":"^9.0.0","react":"^18.0.0","react-dom":"^18.0.0","svelte":"^4.0.0","tsup":"^8.0.0","typescript":"^5.0.0","vitest":"^2.0.0","vue":"^3.0.0"},"engines":{"node":">=18.20.0","pnpm":">=8.0.0"},"scripts":{"build":"pnpm run build:lib && pnpm run build:mcp","build:lib":"tsup","build:mcp":"cd mcp && pnpm install && pnpm run build","dev":"tsup --watch","test":"vitest","test:ui":"vitest --ui","lint":"eslint src --ext .ts,.tsx","typecheck":"tsc --noEmit","clean":"rm -rf dist && rm -rf mcp/dist"},"_id":"@encryptioner/html-to-pdf-generator@1.0.3","_integrity":"sha512-ca/WhCO1fUjLJ+L3mY/2yxIZT/MjzbL6vRw1FjofbSC1HeaIRL9BqeUwQ/X5iZhEtaxgXAdN3GgO3B7BdMXp1g==","_resolved":"/tmp/09b74750c680085ff6e915e726fa85cb/encryptioner-html-to-pdf-generator-1.0.3.tgz","_from":"file:encryptioner-html-to-pdf-generator-1.0.3.tgz","_nodeVersion":"18.20.0","_npmVersion":"10.5.0","dist":{"integrity":"sha512-ca/WhCO1fUjLJ+L3mY/2yxIZT/MjzbL6vRw1FjofbSC1HeaIRL9BqeUwQ/X5iZhEtaxgXAdN3GgO3B7BdMXp1g==","shasum":"1b0075b343157b7149bc1a3d8539acf4793704c3","tarball":"https://registry.npmjs.org/@encryptioner/html-to-pdf-generator/-/html-to-pdf-generator-1.0.3.tgz","fileCount":74,"unpackedSize":3098864,"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@encryptioner%2fhtml-to-pdf-generator@1.0.3","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIEj75aqj7JjozcMlNlL/XEnyq49zT8CxZafVkKf1ycVjAiBYQu/Rql0xaMISqWqdMe9u4GHMzwBbzBaW7DFVUOZ9EQ=="}]},"_npmUser":{"name":"ankur_mursalin","email":"mir.ankur.ruet13@gmail.com"},"directories":{},"maintainers":[{"name":"ankur_mursalin","email":"mir.ankur.ruet13@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/html-to-pdf-generator_1.0.3_1763578626466_0.6138769978957714"},"_hasShrinkwrap":false}},"time":{"created":"2025-11-18T03:51:33.566Z","modified":"2025-11-19T18:57:07.216Z","1.0.0":"2025-11-18T03:51:33.923Z","1.0.1":"2025-11-18T04:07:22.778Z","1.0.2":"2025-11-19T00:45:34.775Z","1.1.0":"2025-11-19T18:44:09.396Z","1.0.3":"2025-11-19T18:57:06.719Z"},"bugs":{"url":"https://github.com/Encryptioner/html-to-pdf-generator/issues"},"author":{"name":"Mir Mursalin Ankur","email":"mir.ankur.ruet13@gmail.com","url":"https://encryptioner.github.io/"},"license":"MIT","homepage":"https://github.com/Encryptioner/html-to-pdf-generator#readme","keywords":["pdf","pdf-generator","html-to-pdf","jspdf","html2canvas-pro","oklch","react","vue","svelte","typescript","multi-page","pagination","document-generator","framework-agnostic","mcp","model-context-protocol","mcp-server","server-side"],"repository":{"type":"git","url":"git+https://github.com/Encryptioner/html-to-pdf-generator.git"},"description":"Modern multi-page PDF generator from HTML content with smart pagination and styling support","maintainers":[{"name":"ankur_mursalin","email":"mir.ankur.ruet13@gmail.com"}],"readme":"# HTML to PDF Generator\n\nA modern, framework-agnostic library for converting HTML content to professional multi-page PDFs with smart pagination and rich features.\n\n[![npm version](https://badge.fury.io/js/@encryptioner%2Fhtml-to-pdf-generator.svg)](https://www.npmjs.com/package/@encryptioner/html-to-pdf-generator)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n\n**📦 NPM Package:** https://www.npmjs.com/package/@encryptioner/html-to-pdf-generator\n\n---\n\n## 📚 Documentation\n\n**Complete documentation is available in the [documentation](./documentation/) folder:**\n\n- **[📖 Full Documentation Index](./documentation/index.md)** - Complete guide and API reference\n- **[🚀 Quick Start Guide](./documentation/guides/getting-started.md)** - Get started in 5 minutes\n- **[⚙️ Installation Guide](./documentation/guides/installation.md)** - Detailed installation instructions\n- **[🎨 API Reference](./documentation/api/options.md)** - All options and configurations\n\n### Framework Guides\n- [React Integration](./documentation/guides/react-guide.md)\n- [Vue 3 Integration](./documentation/guides/vue-guide.md)\n- [Svelte Integration](./documentation/guides/svelte-guide.md)\n- [Vanilla JS/TS](./documentation/guides/vanilla-guide.md)\n- [Server-Side (Node.js)](./documentation/guides/server-side-guide.md)\n\n### Feature Documentation\n- [Multi-Page Generation](./documentation/features/multi-page.md)\n- [Image Handling](./documentation/features/images.md)\n- [Table Support](./documentation/features/tables.md)\n- [Page Breaks](./documentation/features/page-breaks.md)\n- [Color Management](./documentation/features/colors.md)\n- [Watermarks](./documentation/advanced/watermarks.md)\n- [Headers & Footers](./documentation/advanced/headers-footers.md)\n- [Metadata](./documentation/advanced/metadata.md)\n- [Security & Encryption](./documentation/advanced/security.md)\n- [PDF Preview](./documentation/advanced/preview.md)\n- [Batch Generation](./documentation/advanced/batch-generation.md)\n\n---\n\n## ✨ Features\n\n### Core Features\n- ✅ **Multi-page support** with smart pagination\n- ✅ **Framework adapters** for React, Vue, Svelte, and vanilla JS\n- ✅ **OKLCH color support** with automatic Tailwind CSS compatibility\n- ✅ **Image optimization** with SVG conversion and DPI control\n- ✅ **Table pagination** with automatic header repetition\n- ✅ **Smart page breaks** with orphan prevention\n- ✅ **HTML string support** for generating PDFs from HTML markup\n- ✅ **TypeScript support** with full type definitions\n- ✅ **Progress tracking** with real-time callbacks\n\n### Advanced Features\n- ✅ **Watermarks** - Add text or image watermarks with opacity control\n- ✅ **Headers/Footers** - Dynamic templates with variables ({{pageNumber}}, {{totalPages}}, {{date}}, {{title}})\n- ✅ **PDF Metadata** - Set title, author, subject, keywords, and creation date\n- ✅ **PDF Security** - Password protection and permission controls (printing, copying, modifying)\n- ✅ **PDF Preview** - Real-time PDF preview with live updates and debouncing\n- ✅ **Batch generation** - Combine multiple HTML sections into one PDF\n- ✅ **Media type emulation** - Apply @media print styles automatically\n- ✅ **External CSS** - Automatic loading and processing of stylesheets\n- ✅ **Background images** - Proper handling of CSS background images\n- ✅ **Custom CSS injection** - Add custom styles before rendering\n\n---\n\n## 📦 Installation\n\n```bash\nnpm install @encryptioner/html-to-pdf-generator\n```\n\n```bash\npnpm add @encryptioner/html-to-pdf-generator\n```\n\n```bash\nyarn add @encryptioner/html-to-pdf-generator\n```\n\n---\n\n## 🚀 Quick Start\n\n### Vanilla JavaScript/TypeScript\n\n```typescript\nimport { generatePDF } from '@encryptioner/html-to-pdf-generator';\n\nconst element = document.getElementById('my-content');\nawait generatePDF(element, 'my-document.pdf', {\n  format: 'a4',\n  orientation: 'portrait',\n  margins: [10, 10, 10, 10], // [top, right, bottom, left] in mm\n  showPageNumbers: true,\n  watermark: {\n    text: 'CONFIDENTIAL',\n    opacity: 0.1,\n    position: 'diagonal'\n  }\n});\n```\n\n### From HTML String\n\n```typescript\nimport { generatePDFFromHTML } from '@encryptioner/html-to-pdf-generator';\n\nconst html = `\n<!DOCTYPE html>\n<html>\n  <head>\n    <style>\n      body { font-family: Arial, sans-serif; }\n      .header { color: #333; font-size: 24px; }\n    </style>\n  </head>\n  <body>\n    <h1 class=\"header\">My Document</h1>\n    <p>This is a paragraph with some content.</p>\n  </body>\n</html>\n`;\n\nawait generatePDFFromHTML(html, 'document.pdf', {\n  format: 'a4',\n  metadata: {\n    title: 'My Document',\n    author: 'John Doe'\n  }\n});\n```\n\n### React\n\n```tsx\nimport { usePDFGenerator } from '@encryptioner/html-to-pdf-generator/react';\n\nfunction MyComponent() {\n  const { targetRef, generatePDF, isGenerating, progress } = usePDFGenerator({\n    filename: 'my-document.pdf',\n    format: 'a4',\n    showPageNumbers: true,\n  });\n\n  return (\n    <div>\n      <div ref={targetRef}>\n        <h1>Content to convert to PDF</h1>\n        <p>This will be in your PDF document</p>\n      </div>\n\n      <button onClick={generatePDF} disabled={isGenerating}>\n        {isGenerating ? `Generating... ${progress}%` : 'Download PDF'}\n      </button>\n    </div>\n  );\n}\n```\n\n### Vue 3\n\n```vue\n<script setup>\nimport { usePDFGenerator } from '@encryptioner/html-to-pdf-generator/vue';\n\nconst { targetRef, generatePDF, isGenerating, progress } = usePDFGenerator({\n  filename: 'my-document.pdf',\n  format: 'a4',\n  showPageNumbers: true,\n});\n</script>\n\n<template>\n  <div>\n    <div ref=\"targetRef\">\n      <h1>Content to convert to PDF</h1>\n      <p>This will be in your PDF document</p>\n    </div>\n\n    <button @click=\"generatePDF\" :disabled=\"isGenerating\">\n      {{ isGenerating ? `Generating... ${progress}%` : 'Download PDF' }}\n    </button>\n  </div>\n</template>\n```\n\n### Svelte\n\n```svelte\n<script>\n  import { createPDFGenerator } from '@encryptioner/html-to-pdf-generator/svelte';\n\n  let targetElement;\n  const { generatePDF, isGenerating, progress } = createPDFGenerator({\n    filename: 'my-document.pdf',\n    format: 'a4',\n    showPageNumbers: true,\n  });\n\n  const handleDownload = () => {\n    if (targetElement) {\n      generatePDF(targetElement);\n    }\n  };\n</script>\n\n<div bind:this={targetElement}>\n  <h1>Content to convert to PDF</h1>\n  <p>This will be in your PDF document</p>\n</div>\n\n<button on:click={handleDownload} disabled={$isGenerating}>\n  {$isGenerating ? `Generating... ${$progress}%` : 'Download PDF'}\n</button>\n```\n\n---\n\n## 🔧 Advanced Usage\n\n### Watermarks\n\n```typescript\nawait generatePDF(element, 'document.pdf', {\n  watermark: {\n    text: 'CONFIDENTIAL',\n    opacity: 0.1,\n    position: 'diagonal', // 'center' | 'diagonal' | 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right'\n    fontSize: 48,\n    color: '#999999',\n    rotation: 45\n  }\n});\n```\n\n### Headers & Footers\n\n```typescript\nawait generatePDF(element, 'document.pdf', {\n  metadata: {\n    title: 'Annual Report 2024'\n  },\n  headerTemplate: {\n    template: '<div style=\"text-align: center;\">{{title}} - {{date}}</div>',\n    height: 15,\n    css: 'font-size: 11px; border-bottom: 1px solid #ccc;'\n  },\n  footerTemplate: {\n    template: '<div style=\"text-align: center;\">Page {{pageNumber}} of {{totalPages}}</div>',\n    height: 12\n  }\n});\n```\n\n**Available template variables:**\n- `{{pageNumber}}` - Current page number\n- `{{totalPages}}` - Total number of pages\n- `{{date}}` - Current date\n- `{{title}}` - Document title from metadata\n\n### PDF Security\n\nPassword protect your PDFs and control permissions:\n\n```typescript\nawait generatePDF(element, 'secure.pdf', {\n  securityOptions: {\n    enabled: true,\n    userPassword: 'secret123',      // Password to open PDF\n    ownerPassword: 'admin456',      // Password to change permissions\n    permissions: {\n      printing: 'highResolution',   // 'none' | 'lowResolution' | 'highResolution'\n      modifying: false,             // Disable modifications\n      copying: false,               // Disable text copying\n      annotating: false,            // Disable annotations\n      fillingForms: false           // Disable form filling\n    }\n  }\n});\n```\n\n**Note:** jsPDF uses RC4 40-bit encryption, which provides basic protection but is not suitable for highly sensitive documents. For stronger encryption, consider server-side solutions.\n\n**Full security documentation:** [documentation/advanced/security.md](./documentation/advanced/security.md)\n\n### PDF Preview\n\nDisplay a real-time preview of your PDF with automatic updates as content changes:\n\n```typescript\nimport { PDFGenerator } from '@encryptioner/html-to-pdf-generator';\n\nconst generator = new PDFGenerator({\n  format: 'a4',\n  previewOptions: {\n    containerId: 'pdf-preview',   // ID of container element (required)\n    liveUpdate: true,             // Auto-update when content changes\n    debounce: 500,                // Wait 500ms after changes before updating\n    scale: 1,                     // Lower scale for faster preview\n    quality: 0.7                  // Lower quality for faster preview\n  }\n});\n\n// Start preview\nconst contentElement = document.getElementById('content');\nawait generator.startPreview(contentElement);\n\n// Preview automatically updates as content changes\n// Manually update if needed: await generator.updatePreview();\n\n// Stop preview and download final high-quality PDF\ngenerator.stopPreview();\nawait generator.generatePDF(contentElement, 'final.pdf');\n```\n\n**HTML Structure:**\n```html\n<div id=\"content\">\n  <!-- Your content to preview -->\n</div>\n\n<div id=\"pdf-preview\" style=\"width: 100%; height: 600px; border: 1px solid #ccc;\"></div>\n```\n\n**Full preview documentation:** [documentation/advanced/preview.md](./documentation/advanced/preview.md)\n\n### Batch Generation\n\n```typescript\nimport { generateBatchPDF } from '@encryptioner/html-to-pdf-generator';\n\nconst items = [\n  {\n    content: document.getElementById('section-1'),\n    pageCount: 2,\n    title: 'Introduction',\n    newPage: true // Start on a new page\n  },\n  {\n    content: document.getElementById('section-2'),\n    pageCount: 3,\n    title: 'Content',\n    newPage: true\n  }\n];\n\nconst result = await generateBatchPDF(items, 'combined.pdf', {\n  showPageNumbers: true\n});\n\nconsole.log(`Generated ${result.totalPages} pages`);\n```\n\n### Using the PDFGenerator Class\n\n```typescript\nimport { PDFGenerator } from '@encryptioner/html-to-pdf-generator';\n\nconst generator = new PDFGenerator({\n  format: 'a4',\n  orientation: 'portrait',\n  margins: [15, 15, 15, 15],\n  showPageNumbers: true,\n  pageNumberPosition: 'footer',\n  compress: true,\n  onProgress: (progress) => {\n    console.log(`Generating PDF: ${progress}%`);\n  },\n  onComplete: (blob) => {\n    console.log(`PDF generated! Size: ${blob.size} bytes`);\n  },\n  onError: (error) => {\n    console.error('PDF generation failed:', error);\n  },\n});\n\n// Generate PDF\nawait generator.generatePDF(element, 'document.pdf');\n\n// Or get blob without downloading\nconst blob = await generator.generateBlob(element);\n```\n\n---\n\n## 🖥️ MCP Server (Model Context Protocol)\n\nThe package includes an **MCP server** for server-side PDF generation, enabling Claude Desktop and other MCP clients to generate PDFs.\n\n### Quick Setup for Claude Desktop\n\n1. **Build the package:**\n   ```bash\n   pnpm install && pnpm run build\n   ```\n\n2. **Add to Claude Desktop config** (`~/Library/Application Support/Claude/claude_desktop_config.json` on macOS):\n   ```json\n   {\n     \"mcpServers\": {\n       \"html-to-pdf\": {\n         \"command\": \"node\",\n         \"args\": [\"/absolute/path/to/html-to-pdf-generator/mcp/dist/index.js\"]\n       }\n     }\n   }\n   ```\n\n3. **Restart Claude Desktop** and use PDF generation in your conversations:\n   ```\n   You: Generate a PDF invoice with these items and save to /tmp/invoice.pdf\n   Claude: [Uses generate_pdf tool to create PDF]\n   ```\n\n### MCP Tools Available\n\n- **`generate_pdf`** - Generate PDF from HTML with full feature support\n- **`generate_batch_pdf`** - Combine multiple HTML sections into one PDF\n- **`generate_pdf_from_url`** - Convert web pages to PDF (CORS-aware)\n\n**📖 Full MCP Documentation:** See [mcp/README.md](./mcp/README.md) for complete setup, API reference, and examples.\n\n---\n\n## 📖 API Options\n\n### PDFGeneratorOptions\n\n| Option | Type | Default | Description |\n|--------|------|---------|-------------|\n| `format` | `'a4' \\| 'letter' \\| 'a3' \\| 'legal'` | `'a4'` | Paper format |\n| `orientation` | `'portrait' \\| 'landscape'` | `'portrait'` | Page orientation |\n| `margins` | `[number, number, number, number]` | `[10, 10, 10, 10]` | Margins [top, right, bottom, left] in mm |\n| `compress` | `boolean` | `true` | Enable PDF compression |\n| `scale` | `number` | `2` | HTML2Canvas scale factor (1-4) |\n| `imageQuality` | `number` | `0.85` | JPEG quality (0-1) |\n| `showPageNumbers` | `boolean` | `false` | Show page numbers |\n| `pageNumberPosition` | `'header' \\| 'footer'` | `'footer'` | Page number position |\n| `customCSS` | `string` | `''` | Custom CSS to inject |\n| `watermark` | `WatermarkOptions` | `undefined` | Watermark configuration |\n| `headerTemplate` | `HeaderFooterTemplate` | `undefined` | Header template |\n| `footerTemplate` | `HeaderFooterTemplate` | `undefined` | Footer template |\n| `metadata` | `PDFMetadata` | `undefined` | PDF metadata |\n| `securityOptions` | `PDFSecurityOptions` | `undefined` | Security & encryption settings |\n| `emulateMediaType` | `'screen' \\| 'print'` | `'screen'` | Media type to emulate |\n| `onProgress` | `(progress: number) => void` | - | Progress callback (0-100) |\n| `onComplete` | `(blob: Blob) => void` | - | Completion callback |\n| `onError` | `(error: Error) => void` | - | Error callback |\n\n**Full API documentation:** [documentation/api/options.md](./documentation/api/options.md)\n\n---\n\n## 🔍 Browser Compatibility\n\n- ✅ Chrome/Edge 90+\n- ✅ Firefox 88+\n- ✅ Safari 14+\n- ✅ Modern mobile browsers\n\n**Note:** Requires browser support for html2canvas and jsPDF.\n\n---\n\n## 🤝 Contributing\n\nWe welcome contributions! Please see our [Contributing Guide](./CONTRIBUTING.md) for details.\n\n1. Fork the repository\n2. Create your feature branch (`git checkout -b feature/amazing-feature`)\n3. Commit your changes (`git commit -m 'Add amazing feature'`)\n4. Push to the branch (`git push origin feature/amazing-feature`)\n5. Open a Pull Request\n\n---\n\n## 📝 License\n\nMIT License - see [LICENSE.md](./LICENSE.md) for details.\n\n---\n\n## 🐛 Issues & Support\n\n- **Issues**: [GitHub Issues](https://github.com/Encryptioner/html-to-pdf-generator/issues)\n- **Email**: mir.ankur.ruet13@gmail.com\n\n---\n\n## 🙏 Acknowledgments\n\nBuilt with:\n- [jsPDF](https://github.com/parallax/jsPDF) - PDF generation\n- [html2canvas-pro](https://github.com/niklasvh/html2canvas) - HTML to canvas rendering\n- [pdf-lib](https://github.com/Hopding/pdf-lib) - PDF merging\n\n---\n\n## 📊 Package Stats\n\n- **Bundle Size**: ~400KB (minified)\n- **Dependencies**: 3 core dependencies\n- **TypeScript**: Full type definitions included\n- **Tree-shakeable**: ESM and CJS builds\n- **Framework Support**: React, Vue, Svelte, Vanilla JS\n- **Server-Side**: Node.js with Puppeteer\n\n---\n\n**Ready to get started?** → [Quick Start Guide](./documentation/guides/getting-started.md)\n","readmeFilename":"README.md"}