Skip to content

Conversation

AntoLC
Copy link
Collaborator

@AntoLC AntoLC commented Sep 3, 2025

Purpose

Sometimes we do not have the width of some columns in a table. In such cases, we need to calculate a fallback width to ensure the table is rendered correctly.

Proposal

We were previously using 120 points as the fallback width, but this has been improved to better fit the content.
We now check the size left and distribute it among the unknown columns.

Demo

Before:

image

After

image

@AntoLC AntoLC self-assigned this Sep 3, 2025
@AntoLC AntoLC added bug Something isn't working enhancement improve an existing feature frontend export labels Sep 3, 2025
Sometimes we do not have the width of some
columns in a table. In such cases, we need to
calculate a fallback width to ensure the table
is rendered correctly.
We were previously using 120 points as the
fallback width, but this has been improved
to better fit the content.
We now check the size left and distribute it
among the unknown columns.
@AntoLC AntoLC force-pushed the fix/table-pdf-export branch from 9706ae6 to 726b50d Compare September 3, 2025 16:11
@AntoLC AntoLC requested a review from Ovgodd September 3, 2025 16:14
Copy link

github-actions bot commented Sep 3, 2025

Size Change: +63 B (0%)

Total Size: 3.64 MB

Filename Size Change
apps/impress/out/_next/static/ce3ca23c/_buildManifest.js 0 B -867 B (removed) 🏆
apps/impress/out/_next/static/a49dc42d/_buildManifest.js 868 B +868 B (new file) 🆕

compressed-size-action

@virgile-dev
Copy link
Collaborator

Linking the BlockNote issue I opened : TypeCellOS/BlockNote#1979

@AntoLC AntoLC changed the title ⚡️(frontend) improve fallback width calculation ⚡️(frontend) improve export table width calculation Sep 3, 2025
Copy link
Collaborator

@Ovgodd Ovgodd left a comment

Choose a reason for hiding this comment

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

Greate improvement

@AntoLC AntoLC merged commit 726b50d into main Sep 4, 2025
21 of 22 checks passed
@AntoLC AntoLC deleted the fix/table-pdf-export branch September 4, 2025 08:27
@AntoLC AntoLC mentioned this pull request Sep 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement improve an existing feature export frontend
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants