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

Make table border=none setting work #16002

Closed
wants to merge 5 commits into from
Closed

Make table border=none setting work #16002

wants to merge 5 commits into from

Conversation

map-r
Copy link
Contributor

@map-r map-r commented Mar 8, 2024

Suggested merge commit message (convention)

Fix (table): Changed default table and table cell properties to match the content styles. Fixes problem with setting border = none on the table. Closes #6841.


Additional details

Paste from Office test changes explanation

Aligned with actual data

<table class=MsoTableGrid border=1 cellspacing=0 cellpadding=0 width=597 style='border-collapse:collapse;mso-table-layout-alt:fixed;
border:none;
^^^^^^^^^
mso-border-alt:solid windowtext .5pt;mso-yfti-tbllook:1184;mso-padding-alt:
0cm 5.4pt 0cm 5.4pt'>

The first cell has a full border:

<td width="59%" style='width:59.0%;border:solid windowtext 1.0pt;mso-border-alt:
                                   ^^^^^^^^^^
solid windowtext .5pt;background:#CCCCCC;padding:0cm 5.4pt 0cm 5.4pt'>

While other cells have specific borders:

<td width="24%" style='width:24.0%;border:solid windowtext 1.0pt;
border-left:none;mso-border-left-alt:solid windowtext .5pt;mso-border-alt:solid windowtext .5pt;
^^^^^^^^^^^^^
background:#CCCCCC;padding:0cm 5.4pt 0cm 5.4pt'>

@map-r map-r requested a review from oleq March 8, 2024 12:23
@map-r
Copy link
Contributor Author

map-r commented Mar 13, 2024

@DawidKossowski Outro for this task/PR:

as @oleq validly pointed out deeper problems with how we treat default values in config vs in styles and what should we do with customizing them in a valid priority - you can at least see it in the comments here #14921 (comment)

@oleq oleq removed their request for review April 17, 2024 07:16
@Witoso
Copy link
Member

Witoso commented Aug 6, 2024

We need to make the change in a different place:

const normalizedConfig: NormalizedDefaultProperties = {
borderStyle: 'none',
borderWidth: '',
borderColor: '',
backgroundColor: '',
width: '',
height: '',
...config
};

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.

How to make table border=none setting work?
2 participants