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

Fix: custom fonts support on the Browser #2898

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Dabolus
Copy link

@Dabolus Dabolus commented Dec 11, 2024

Right now, it's not possible to embed custom fonts when generating a docx from a Browser without polyfilling Buffer because the obfuscator uses native Node.js Buffers without checking for their availability.

This PR makes the obfuscator use Uint8Arrays instead of Buffers, so that it can also work in the Browser without polyfilling.

I also renamed the related tests file because there was a small typo.

Resolves: #2667

Copy link

codecov bot commented Dec 17, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (e80a50d) to head (e8ffebc).

Additional details and impacted files
@@            Coverage Diff            @@
##            master     #2898   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          286       286           
  Lines         8370      8373    +3     
  Branches      1400      1400           
=========================================
+ Hits          8370      8373    +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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.

Using embedded fonts for client side generated files
1 participant