-
Notifications
You must be signed in to change notification settings - Fork 5.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
[JEWEL-735] Implement Markdown tables support (GFM extension) #2913
base: master
Are you sure you want to change the base?
Conversation
Is this still not passing the checks, or is the result old? |
@jakub-senohrabek we're waiting for Sasha to take a look at the scroll sync tests |
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.
Haven't checked the code itself yet
...wel/markdown/ide-laf-bridge-styling/intellij.platform.jewel.markdown.ideLafBridgeStyling.iml
Outdated
Show resolved
Hide resolved
...rkdown/int-ui-standalone-styling/intellij.platform.jewel.markdown.intUiStandaloneStyling.iml
Outdated
Show resolved
Hide resolved
platform/jewel/samples/standalone/intellij.platform.jewel.samples.standalone.iml
Outdated
Show resolved
Hide resolved
.../core/src/main/kotlin/org/jetbrains/jewel/markdown/rendering/DefaultMarkdownBlockRenderer.kt
Show resolved
Hide resolved
93b2beb
to
4e80a98
Compare
@AlexVanGogen reverted everything that needed reverting. Had to do a force push because Ivan had done git merge, and that commit was what fucked up the stuff you picked up on. (FYI @hamen please do not do merges, use rebase.) |
PS: I can't mark your comments as resolved, but the ones that needed me to do something (i.e., revert changes in the default renderer, or renaming the iml module) are done. |
...re/src/main/kotlin/org/jetbrains/jewel/markdown/scrolling/ScrollSyncMarkdownBlockRenderer.kt
Show resolved
Hide resolved
@AlexVanGogen fixed all the new comments :) |
@rock3r It almost compiles now 🎉 , there's one unupdated reference to not existing anymore In the meantime, I've tried to paste my little testing table to a standalone sample and got this: Is there an option to keep rows wide enough to avoid soft-wrapping? To get something like what GitHub renders by default:
|
@AlexVanGogen I never noticed that behaviour. It's possible there may be some bug in the table layout, it's brand new :) But I would not stop this PR over that |
...m/jewel/foundation/src/main/kotlin/org/jetbrains/jewel/foundation/layout/BasicTableLayout.kt
Outdated
Show resolved
Hide resolved
341c2e5
to
6b9a42e
Compare
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, just left a few minor comments about the code.
On a sidenote, it's been feast for my eyes to finally see rendered tables in the previews, and not a mishmash of hyphens and pipes 😀
...m/jewel/foundation/src/main/kotlin/org/jetbrains/jewel/foundation/layout/BasicTableLayout.kt
Outdated
Show resolved
Hide resolved
// the (possibly scaled) intrinsic column widths we just computed | ||
val intrinsicRowHeights = IntArray(rowCount) | ||
var tableHeight = 0 | ||
measurablesByRow.mapIndexed { rowIndex, rowMeasurables -> |
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.
measurablesByRow.mapIndexed { rowIndex, rowMeasurables -> | |
measurablesByRow.forEachIndexed { rowIndex, rowMeasurables -> |
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.
Was a bit larger change than this but 👍
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.
You probably meant the loop above, with withIndex
:)
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.
Not a big deal tho
...ewel/markdown/core/src/main/kotlin/org/jetbrains/jewel/markdown/processing/ProcessingUtil.kt
Show resolved
Hide resolved
...ewel/markdown/core/src/main/kotlin/org/jetbrains/jewel/markdown/processing/ProcessingUtil.kt
Show resolved
Hide resolved
...arkdown/core/src/main/kotlin/org/jetbrains/jewel/markdown/rendering/MarkdownBlockRenderer.kt
Show resolved
Hide resolved
...ain/kotlin/org/jetbrains/jewel/markdown/extensions/github/tables/GitHubTableBlockRenderer.kt
Outdated
Show resolved
Hide resolved
...ain/kotlin/org/jetbrains/jewel/markdown/extensions/github/tables/GitHubTableBlockRenderer.kt
Outdated
Show resolved
Hide resolved
...ain/kotlin/org/jetbrains/jewel/markdown/extensions/github/tables/GitHubTableBlockRenderer.kt
Outdated
Show resolved
Hide resolved
One tiny thing left, but I think that's ok to merge |
Reference JetBrains/jewel#735