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

The nested table within the resizable table's cell results in cells overlapping #12362

Closed
dufipl opened this issue Aug 30, 2022 · 4 comments
Closed
Labels
package:table resolution:expired This issue was closed due to lack of feedback. squad:features Issue to be handled by the Features team. status:stale type:bug This issue reports a buggy (incorrect) behavior. type:regression This issue reports a bug that was not present in the previous releases.

Comments

@dufipl
Copy link
Contributor

dufipl commented Aug 30, 2022

📝 Provide detailed reproduction steps (if any)

  1. Checkout the release branch
  2. Go to: http://127.0.0.1:8080/ckeditor5/latest/features/table.html#table-column-resize
  3. Insert a 10x10 table into the table cell
  4. Try to resize that cell

✔️ Expected result

The cell is resizable and tables are not overlapping

❌ Actual result

Cells are overlapping:
table in table column resize issue

If the cell were resized before inserting the nested table, it would overlap after inserting.

Additionally, clicking on the resize marker makes it grow:

column resize grow

Additional info

Browser: reproducing on Chrome, Firefox, Safari


If you'd like to see this fixed sooner, add a 👍 reaction to this post.

@dufipl dufipl added type:bug This issue reports a buggy (incorrect) behavior. package:table type:regression This issue reports a bug that was not present in the previous releases. squad:features Issue to be handled by the Features team. labels Aug 30, 2022
@Mgsy
Copy link
Member

Mgsy commented Aug 30, 2022

I can't reproduce the issue with expanding the inner table on click in our manual test, so it might be a docs-specific issue.

@Dumluregn Dumluregn self-assigned this Aug 30, 2022
@CKEditorBot CKEditorBot added the status:in-progress Set automatically when an issue lands in the "In progress" column. We are working on it. label Aug 30, 2022
@Dumluregn
Copy link
Contributor

Dumluregn commented Aug 30, 2022

Cells overlapping is caused by the lack of table-layout: fixed; styling on the nested tables. Setting it restores the previous behavior, so resizing a column containing a nested table changes the width of the nested one (to keep the width proportional to the column). This solution however has some drawbacks:

  1. Enforcing the fixed table layout may sometimes be unexpected by the user if they want to have the columns self-adjusting to the content width. That's not such a big issue as they can simply resize the columns as they wish afterwards.
  2. The implementation is not obvious. Using some "clever" CSS selector like .ck .ck-content .table .table may create new issues (note we can't use the child combinator as nested table can be inside a blockquote). Other idea could be applying the necessary styling as a class. That would further pollute the data output, unless we reuse the ck-table-resized class which sole property is table-layout:fixed;, but it's name would require change to match the semantics...
  3. It's also unclear where at which moment the class should be applied. Theoretically we could do it lazily, i.e. when a table is being resized, find all the nested tables and apply the styling. But it doesn't solve the issue where you just insert a big nested table into a narrow table column - it will overlap already. So it seems we need to either listen on insert:table event or use a postfixer, which already sounds unpleasant.

Taking into account it's not a critical issue we'll skip it for now.

@Dumluregn Dumluregn removed their assignment Aug 30, 2022
@CKEditorBot CKEditorBot removed the status:in-progress Set automatically when an issue lands in the "In progress" column. We are working on it. label Aug 30, 2022
@CKEditorBot
Copy link
Collaborator

There has been no activity on this issue for the past year. We've marked it as stale and will close it in 30 days. We understand it may be relevant, so if you're interested in the solution, leave a comment or reaction under this issue.

@CKEditorBot
Copy link
Collaborator

We've closed your issue due to inactivity over the last year. We understand that the issue may still be relevant. If so, feel free to open a new one (and link this issue to it).

@CKEditorBot CKEditorBot added the resolution:expired This issue was closed due to lack of feedback. label Nov 1, 2023
@CKEditorBot CKEditorBot closed this as not planned Won't fix, can't repro, duplicate, stale Nov 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package:table resolution:expired This issue was closed due to lack of feedback. squad:features Issue to be handled by the Features team. status:stale type:bug This issue reports a buggy (incorrect) behavior. type:regression This issue reports a bug that was not present in the previous releases.
Projects
None yet
Development

No branches or pull requests

4 participants