fix: address code review feedback for browser extension
- Removed unused variables in capture.js (clonedDoc, styles array) - Added explicit return values for message handlers in content.js - Added detailed comment explaining 500ms render delay before PDF conversion - Updated PERMISSIONS.md with comprehensive explanation of host_permissions requirement - Updated test.html with web clipping test scenarios - Improved code consistency and documentation Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
This commit is contained in:
@@ -152,7 +152,9 @@ async function convertHtmlToPdf(html) {
|
||||
chrome.tabs.onUpdated.addListener(listener);
|
||||
});
|
||||
|
||||
// Give it a bit more time to render
|
||||
// Wait for page to fully render before PDF conversion
|
||||
// This delay ensures JavaScript execution, dynamic content rendering,
|
||||
// and CSS transitions have completed. May need adjustment for complex pages.
|
||||
await new Promise(resolve => setTimeout(resolve, 500));
|
||||
|
||||
// Use Chrome's print to PDF API
|
||||
|
||||
Reference in New Issue
Block a user