Skip to content

Conversation

@mejo-
Copy link
Member

@mejo- mejo- commented Aug 1, 2025

📝 Summary

🖼️ Screenshots

🏡 Editor Serialized Markdown
image image

🚧 TODO

  • Allow block+ as content for tableCell. For some reason, allowing blockquotes results in all cell rows being serialized to markdown as blockquote. I didn't find out yet why this is the case
  • 2x return used to create/jump to next row. This is currently broken. Do we want it back?
  • Optionally remove our custom newline special-handling with <br> in table cells
  • Reset sessions on app update
  • Custom paste handler breaks pasting into code blocks. We need to replace it with a paste handler that prevents nested tables and allows everything else
  • Prevent nested tables via filterTransaction (as suggested here

🏁 Checklist

  • Code is properly formatted (npm run lint / npm run stylelint / composer run cs:check)
  • Sign-off message is added to all commits
  • Tests (unit, integration and/or end-to-end) passing and the changes are covered with tests

@mejo- mejo- self-assigned this Aug 1, 2025
@mejo- mejo- force-pushed the feat/multiline_tables branch 3 times, most recently from b6526cb to c619227 Compare August 1, 2025 13:16
@codecov
Copy link

codecov bot commented Aug 1, 2025

Codecov Report

❌ Patch coverage is 92.53731% with 10 lines in your changes missing coverage. Please review.
✅ Project coverage is 59.70%. Comparing base (dadf315) to head (c619227).

Files with missing lines Patch % Lines
src/nodes/Table/TableCell.js 33.33% 2 Missing ⚠️
src/nodes/Table/TableHeadRow.js 0.00% 2 Missing ⚠️
src/nodes/Table/TableHeader.js 0.00% 2 Missing ⚠️
src/nodes/Table/TableRow.js 0.00% 2 Missing ⚠️
src/nodes/Table/markdown.ts 98.19% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7523      +/-   ##
==========================================
+ Coverage   52.91%   59.70%   +6.78%     
==========================================
  Files         497      497              
  Lines       42943    38164    -4779     
  Branches     1125     1124       -1     
==========================================
+ Hits        22724    22786      +62     
+ Misses      20111    15271    -4840     
+ Partials      108      107       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@mejo- mejo- force-pushed the feat/multiline_tables branch from c619227 to b18ab8b Compare August 3, 2025 17:59
@mejo- mejo- marked this pull request as ready for review August 3, 2025 17:59
@mejo- mejo- requested a review from max-nextcloud as a code owner August 3, 2025 17:59
mejo- added 10 commits August 14, 2025 15:01
Allow paragraphs, lists, code blocks and images in table cells for now.

Signed-off-by: Jonas <[email protected]>
Table cells with lists or code blocks are hardcoded to left alignment
though, as everything else would break markdown parsing later.

Signed-off-by: Jonas <[email protected]>
Dashes in nodes names are not nice and this PR changes the editor schema
anyway.

Signed-off-by: Jonas <[email protected]>
Unnecessary and breaks serializing e.g. nested lists.

Signed-off-by: Jonas <[email protected]>
@mejo- mejo- force-pushed the feat/multiline_tables branch from 4c135b1 to ac21086 Compare August 14, 2025 14:34
Also add tests for tables with complex nested structures in their cells.

Signed-off-by: Jonas <[email protected]>
@mejo- mejo- force-pushed the feat/multiline_tables branch from ac21086 to 8e40758 Compare August 14, 2025 14:36
@mejo- mejo- changed the title Multiline tables with paragraphs, lists, code blocks and images Multiline tables with block node content Aug 14, 2025
@max-nextcloud
Copy link
Collaborator

@mejo- Did you figure out what prevents nesting a table in a table right now?

@mejo-
Copy link
Member Author

mejo- commented Aug 17, 2025

@mejo- Did you figure out what prevents nesting a table in a table right now?

Not exactly, but I guess it's rather a broken can() (or however this command to check whether the feature is possible at current cursor position is called). Pasting a table into a table cell works currently. That's why I added the two TODO points to make it technically impossible to add nested tables (via filterTransaction) and to filter out nested tables in handlePaste().

@Aveyron-RetD
Copy link

Will this fix as well, rich previews added with the smart picker ?
#7582

@janbaum
Copy link
Contributor

janbaum commented Sep 26, 2025

2x return used to create/jump to next row. This is currently broken. Do we want it back?

Just wanted to say that I would love this being broken 🫠

@juliusknorr juliusknorr moved this to 💡 To discuss in 📝 Office team Nov 5, 2025
@juliusknorr juliusknorr moved this from 💡 To discuss to 📄 To do (~10 entries) in 📝 Office team Nov 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: 📄 To do (~10 entries)

Development

Successfully merging this pull request may close these issues.

Text rich editor column smart picker content breaks tables Inserting Images into Table Cells Pasting an image into a table splits it

6 participants