feat(ea-preview) - preview the pdf and download it#1085
Merged
Conversation
Contributor
📦 Bundle Size Report
Size Limits
Largest Files (Top 5)
View All Files (339 total)
✅ Bundle size check passed |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 2bfb2d8. Configure here.
Contributor
📊 Coverage Report✅ Coverage increased! 🎉
Detailed BreakdownLines Coverage
Statements Coverage
Functions Coverage
Branches Coverage
✅ Coverage check passed |
Contributor
|
Deploy preview for adp-cost-calculator ready!
Deployed with vercel-action |
Contributor
|
Deploy preview for remote-flows ready!
Deployed with vercel-action |
jordividaller
approved these changes
Jun 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

I've ask externally to see what partners have in mind to implement on this step, you can take a look at the loom and see how it looks and what questions I asked
Basically we call a new endpoint to get the preview pdf, we don't have the need to call a different endpoint to download the pdf as it already there.
I think most of the code should be implemented on the example app as they only need the pdf and then they bring their own components to preview the viewer etc...
and I don't know what UI they're going to use, that's why I asked some questions to them
When they clarify, I can modify or keep this solution
https://www.loom.com/share/2f157c2a75cf450580c948f7ad1513ce
Note
Low Risk
Read-only preview fetch and example/UI wiring; no changes to employment creation, signing, or auth flows.
Overview
Adds employment agreement preview data to onboarding when the
ea_previewfeature flag is enabled: a newuseEmploymentAgreementPreviewquery loads the agreement from the API only on theemployment_agreement_previewstep, and the result is exposed ononboardingBag.employmentAgreementPreview(with loading folded into existing step loading state).The example onboarding app turns on
ea_previewand implements a full-screen dialog to open the PDF in an iframe (with a loading state) and download it via the existingdownloadFilehelper. The preview step component is unchanged aside from removing a stale comment.Reviewed by Cursor Bugbot for commit 6db783e. Bugbot is set up for automated code reviews on this repo. Configure here.