NDA Generator (Non-Disclosure Agreement Generator)

NDA Generator

Enter Party Information

Disclosing Party

Receiving Party

Define Agreement Scope

Generated Non-Disclosure Agreement

IN WITNESS WHEREOF, the Parties have executed this Agreement as of the Effective Date.

DISCLOSING PARTY:

By: _________________________

Name: _______________________

Title: ________________________

RECEIVING PARTY:

By: _________________________

Name: _______________________

Title: ________________________

`; }, renderNdaPreview() { this.dom.ndaPreviewContent.innerHTML = this.generateNdaHtml(); }, // --- NAVIGATION --- changeTab(tabIndex) { if (tabIndex > this.currentTab) { this.updateNdaData(); if (this.currentTab === 0 && (!this.ndaData.disclosingName || !this.ndaData.receivingName)) { alert("Please fill in the names for both parties."); return; } if (this.currentTab === 1 && (!this.ndaData.purpose || !this.ndaData.state)) { alert("Please fill in the purpose and governing state."); return; } } if (tabIndex === 2) this.renderNdaPreview(); this.dom.tabButtons[this.currentTab].classList.remove('active'); this.dom.tabContents[this.currentTab].classList.remove('active'); this.currentTab = tabIndex; this.dom.tabButtons[this.currentTab].classList.add('active'); this.dom.tabContents[this.currentTab].classList.add('active'); this.updateNavButtons(); }, navigateTabs(direction) { const newTab = direction === 'next' ? this.currentTab + 1 : this.currentTab - 1; if (newTab >= 0 && newTab < this.dom.tabButtons.length) { this.changeTab(newTab); } }, updateNavButtons() { this.dom.prevBtn.style.visibility = this.currentTab === 0 ? 'hidden' : 'visible'; this.dom.nextBtn.textContent = this.currentTab === this.dom.tabButtons.length - 2 ? 'Generate NDA' : 'Next'; this.dom.nextBtn.style.visibility = this.currentTab === this.dom.tabButtons.length - 1 ? 'hidden' : 'visible'; }, // --- PDF GENERATION --- generatePdf() { const { jsPDF } = window.jspdf; const pdf = new jsPDF({ unit: 'pt', format: 'a4' }); const content = this.dom.ndaPreviewContent; pdf.html(content, { callback: function(doc) { doc.save('Non-Disclosure-Agreement.pdf'); }, x: 40, y: 40, width: 515, // A4 width in points is 595, leaving margins windowWidth: content.scrollWidth, autoPaging: 'text' }); }, }; window.app = { changeTab: app.changeTab.bind(app), navigateTabs: app.navigateTabs.bind(app), }; app.init(); });
Scroll to Top