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

DEVSITE-592-inconsistent-image-size #1526

Closed
wants to merge 3 commits into from

Conversation

louisachu
Copy link
Collaborator

Fix the inconsistent image width if it's within a table cell.

Description

Fix the inconsistent image width if it's within a table cell.

Related Issue

https://jira.corp.adobe.com/browse/DEVSITE-592

Motivation and Context

How Has This Been Tested?

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • I have signed the Adobe Open Source CLA.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@louisachu louisachu requested a review from timkim as a code owner July 12, 2023 17:57
@@ -114,6 +114,9 @@ const Tr = ({ children, ...props }) => {
? children
: children.map((child, index) => {
child.props.cellWidth = columnWidthDistribution[index];
if (child.props?.children?.props?.children?.props) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Assuming this is for a specifically for the Image componenet:
Can this be more specific? child.props?.children?.props?.children?.props can flag potentially any child component props, and the isTable prop could cause unwanted changes in them.
If we want to set context across all children within table we should set context instead of prop drilling.

Copy link
Collaborator

Choose a reason for hiding this comment

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

@louisachu louisachu closed this Jul 14, 2023
@louisachu louisachu deleted the louisa/DEVSITE-592-inconsistent-image-size branch July 14, 2023 19:16
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.

2 participants