-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Fixes resizeable columns when the first row has a colspan #4955
Conversation
…the resized columns.
✅ Deploy Preview for tiptap-embed ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
🦋 Changeset detectedLatest commit: 96939ef The changes in this PR will be included in the next version bump. This PR includes changesets to release 54 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Are there any things I could or should do to ensure that this pull request can be merged? |
@jaapvanhoek I've looked at this before. The thing that worries me is why colwidth would have a comma separated list of values. I haven't looked into whether that is how it works right now or not so maybe you can shed some light on it? Also seeing more tests would give me higher confidence that it actually achieves the intended behavior without regressions |
@nperez0111 This is how it currently works when the steps to reproduce are followed, and it has nothing to do with my changes. The only thing I did was change the way the value is handled and make it possible to read the comma-separated values. Later today I will try add some tests for the table-header extension. |
@jaapvanhoek thanks for letting me know, I haven't really touched the table extension or read through it to understand it yet. So you can understand why I'm cautious of it. Tests would definitely give me more confidence, so I appreciate it |
After spending some time trying to run the tests, they keep failing at the Cypress step with the error: "Cypress failed to verify that your server is running". Based on what I've found online, this issue might be related to the setup I'm using (MacOS Sonoma 14.6.1), but none of the suggested solutions have worked for me. As a result, I'm currently unable to add tests to the project. Hopefully, someone else can shed some light on why I can't run the tests at all. |
Hi @jaapvanhoek , so to run the tests you need to have both the development server and the test server running. the development server runs on localhost:3000 So in one terminal you'll need This opens the cypress UI that allows you to run tests individually in a nide interface rather than only in the terminal which is useful for writing tests. I hope this is helpful for you |
… cells and headers can init with a single and multiple column-widths.
@nperez0111 I have added the tests you requested, any suggestions? |
@nperez0111 @bdbch can we get an update on this issue? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for the long wait, @jaapvanhoek really appreciate it, I checked on my side & it is working correctly. Thanks for your contribution!
The width of columns get lost when the first row has a colspan that spans the sized columns because the colwidth (which has a comma separated list of column-widths) gets cast to an int and thus removing the other column-widths
Please describe your changes
The comma separated column-widths for the spanned columns are now split before that are cast to an int.
How did you accomplish your changes
By calling .split on the colwidth variable each width can be parsed separately.
How have you tested your changes
I added the colwidth attribute to the existing example and noticed that it did not behave as expected. Only the first of the spanned columns got the right width. After I changed the code the result was like expected and all columns have the right size, either the given pixel value or it fills the remaining space.
How can we verify your changes
Remarks
The issue was with both TableCell and TableHeader
Checklist
Related issues