[JEWEL-1258] Add missing remember keys in Markdown renderers#3432
Open
rock3r wants to merge 1 commit intoJetBrains:masterfrom
Open
[JEWEL-1258] Add missing remember keys in Markdown renderers#3432rock3r wants to merge 1 commit intoJetBrains:masterfrom
rock3r wants to merge 1 commit intoJetBrains:masterfrom
Conversation
rock3r
commented
Feb 20, 2026
| @@ -752,7 +752,7 @@ public open class DefaultMarkdownBlockRenderer( | |||
| enabled: Boolean, | |||
| onUrlClick: ((String) -> Unit)? = null, | |||
| ) = | |||
| remember(block.inlineContent, styling, enabled) { | |||
| remember(block.inlineContent, styling, enabled, onUrlClick) { | |||
rock3r
commented
Feb 20, 2026
| @@ -74,7 +74,7 @@ internal class GitHubTableBlockRenderer( | |||
| val headerRenderer = remember(headerRootStyling) { blockRenderer.createCopy(rootStyling = headerRootStyling) } | |||
|
|
|||
| val rows = | |||
| remember(tableBlock, blockRenderer, inlineRenderer, tableStyling) { | |||
| remember(tableBlock, blockRenderer, inlineRenderer, tableStyling, enabled, onUrlClick) { | |||
Collaborator
Author
There was a problem hiding this comment.
Other core fix here :)
nebojsa-vuksic
approved these changes
Feb 22, 2026
DanielSouzaBertoldi
approved these changes
Feb 23, 2026
Collaborator
Author
|
Ready to merge |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixed missing
rememberkeys inDefaultMarkdownBlockRendererandGitHubTableBlockRendererthat caused stale cached values whenonUrlClickorenabledchanged. Also extracted shared test infrastructure into a newmarkdown-testingmodule to reduce boilerplate duplication across markdown test classes.Fixes JEWEL-1258
Changes
onUrlClickto therememberkeys inDefaultMarkdownBlockRenderer.renderAsAnnotatedString()enabledandonUrlClickto therememberkeys inGitHubTableBlockRenderer's table rows computationmarkdown-testingmodule with sharedMarkdownTestTheme,createMarkdownTestStyling(), and related test helpersScrollingSynchronizerTestto use the shared test infrastructureRelease notes
Bug fixes
rememberkeys inDefaultMarkdownBlockRendererandGitHubTableBlockRendererthat caused staleonUrlClickcallbacks andenabledstate when these values changed