INFORMACIÓN DE PAGO
Para confirmar el presupuesto, por favor realice una transferencia a la siguiente cuenta:
@@ -579,13 +579,15 @@
wrapper.classList.remove('hidden');
wrapper.style.position = 'absolute';
wrapper.style.left = '-9999px';
+ wrapper.style.top = '0'; // 🛑 FIX: Evita que herede margen superior si el usuario hizo scroll
const element = document.getElementById('pdf-content');
const opt = {
margin: 0,
filename: `Presupuesto_${budget.quote_ref || budget.id}.pdf`,
image: { type: 'jpeg', quality: 1 },
- html2canvas: { scale: 2, useCORS: true, logging: false },
+ // 🛑 FIX: Añadimos scrollY: 0 y windowY: 0 para que haga la "foto" clavada arriba
+ html2canvas: { scale: 2, useCORS: true, logging: false, scrollY: 0, windowY: 0 },
jsPDF: { unit: 'in', format: 'a4', orientation: 'portrait' }
};