Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade react-pdf from v8 to v9 #894

Draft
wants to merge 10 commits into
base: stable
Choose a base branch
from
Draft

Upgrade react-pdf from v8 to v9 #894

wants to merge 10 commits into from

Conversation

gigxz
Copy link
Collaborator

@gigxz gigxz commented Aug 16, 2024

Description

Upgrade react-pdf from 8=>9. Reference documentation https://github.com/wojtekmaj/react-pdf/wiki/Upgrade-guide-from-version-8.x-to-9.x

We had already determined that CVE-2024-4367 was not affecting us, but this upgrade upgrades pdfjs-dist to the patched version, so we get rid of the audit alert.

How to test:

  • upload PDF file in client files
  • view file preview

Type of change

  • Dependency update

Checklist before requesting review

  • I have performed a self-review of my code
  • I have run the code that is being changed under ideal conditions, and it doesn't fail
  • My code includes comments and/or descriptive variable names to help other engineers understand the intent (or not applicable)
  • My code follows the style guidelines of this project (eslint)
  • I have updated the documentation (or not applicable)
  • If it's not obvious how to test this change, I have provided testing instructions in this PR or the related issue

@gigxz

This comment was marked as outdated.

Base automatically changed from release-130 to stable September 11, 2024 17:49
@gigxz gigxz changed the base branch from stable to release-133 September 12, 2024 12:38
@gigxz gigxz marked this pull request as ready for review September 12, 2024 12:40
Base automatically changed from release-133 to stable September 30, 2024 13:15
@gigxz gigxz changed the base branch from stable to release-146 December 30, 2024 15:48
@@ -1,14 +1,11 @@
import { DialogProps, Paper, Stack } from '@mui/material';
import pdfWorker from 'pdfjs-dist/build/pdf.worker.js?url';
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it makes more sense for this to live in FilePreview since that component is actually rendering the pdf previews

@gigxz gigxz changed the title Upgrade react-pdf Upgrade react-pdf from v8 to v9 Dec 30, 2024
@gigxz gigxz requested review from martha and ttoomey December 30, 2024 16:51
Copy link
Contributor

@martha martha left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lovely, thanks!

Copy link
Contributor

@ttoomey ttoomey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks great, thanks!

@gigxz
Copy link
Collaborator Author

gigxz commented Jan 2, 2025

Tested on QA, I'm getting "Failed to load PDF file." when viewing PDF there. Marking PR as draft for now
Screenshot 2025-01-02 at 12 06 49 PM

@gigxz gigxz marked this pull request as draft January 2, 2025 17:04
@gigxz gigxz changed the base branch from release-146 to release-147 January 2, 2025 17:04
Base automatically changed from release-147 to stable January 23, 2025 21:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants