feat: fixed pdf download with improved functionality#1427
Conversation
|
@madsysharma is attempting to deploy a commit to the CodeBlooded's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
Hi @madsysharma, thanks for contributing to Nyay Setu! 🎉 I have automatically:
Our workflows will now analyze your changes to classify:
Tip Ensure your PR description references the issue it resolves (e.g. Happy coding! 🚀 |
|
Hi @viru0909-dev , please review this PR. Thank you. |
viru0909-dev
left a comment
There was a problem hiding this comment.
⚠️ Critical DB Migration Issue
This PR includes dangerous renames of existing Flyway migrations (V51 to V52, V52 to V53, etc.).
Renaming migrations that have already been executed breaks Flyway checksums, which will cause the application to crash on startup for anyone pulling these changes (including our CI/CD pipelines and production DB).
Additionally, this PR includes unrelated changes to SecurityConfig, AuditLogRepository, and CaseRepository which do not align with the PR title (fixing PDF download).
Please revert all migration renames and isolate this PR to only contain the PDF download fix.
f33363a to
3b192df
Compare
|
Hi @viru0909-dev , have made the changes you requested for, and have updated the PR. Please review it. Thank you. |
viru0909-dev
left a comment
There was a problem hiding this comment.
PR modifies App.jsx and inadvertently removes component lazy loading imports. Please restrict changes to Constitution.jsx and the download utility.
19c8f12 to
f020b35
Compare
|
Hi @viru0909-dev , have included only the necessary changes. Please review this updated PR. |
Pull Request
feat: multi-language, error handling, and a11y for Constitution PDF download
Closes #666
Description
The "Download PDF" button on the Constitution page does work, but only for English and Hindi: and it gives the user no feedback. This PR bridges such remaining gaps in that feature:
public/documents. Previously, te/ta/mr users silently received the English PDF with no explanation. Now they get a brief notice that the PDF is currently available only in English and Hindi, and the English version is downloaded: so there is no silent surprise.aria-labelandaria-busy, and the loader actually animates now (the page's existinganimate-spinclass was a no-op because no stylesheet defined it).pdfComingSooni18n key (which still said "coming soon") is retired.Type of change
Testing
npm run buildcompiles the Constitution changes cleanly.Screenshots / Videos
Marathi
Screen.Recording.2026-06-18.174618.mp4
Tamil
Screen.Recording.2026-06-18.174930.mp4
Telugu
Screen.Recording.2026-06-18.175118.mp4
Breaking Changes
None.
Checklist
Reviewer notes
te/ta/mrstrings are careful translations but would benefit from a native-speaker check: happy to adjust accordingly.src/pages/Login.jsxhad a duplicatereact-router-domimport onmainthat breaksnpm run buildfor the whole app. It's unrelated to this PR, but have included the relevant fixes here.