Commit 9820818
fix(ios): preserve code block styles inside list items (#174)
* fix(ios): preserve code block styles inside list items
When a fenced code block appears inside a list item, ListItemRenderer's
paragraph style enumeration was overwriting the code block's own styles
(padding, LTR indent) with list item styles. This caused code block
content to display list markers (e.g. "2.") on every line.
Skip ranges that have the CodeBlockAttributeName attribute, since
CodeBlockRenderer has already applied the correct paragraph style.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix(ios): also guard code blocks in checked task list decorations
Add the same CodeBlockAttributeName check to applyCheckedDecorationsTo
so that checked task list strikethrough/color styles don't bleed into
code block ranges inside list items.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>1 parent 118f5e2 commit 9820818
1 file changed
Lines changed: 23 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
95 | 96 | | |
96 | 97 | | |
97 | 98 | | |
98 | | - | |
| 99 | + | |
99 | 100 | | |
100 | 101 | | |
101 | 102 | | |
| |||
106 | 107 | | |
107 | 108 | | |
108 | 109 | | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
109 | 120 | | |
110 | 121 | | |
111 | 122 | | |
| |||
158 | 169 | | |
159 | 170 | | |
160 | 171 | | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
161 | 175 | | |
162 | | - | |
163 | | - | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
164 | 182 | | |
| 183 | + | |
| 184 | + | |
165 | 185 | | |
166 | 186 | | |
167 | 187 | | |
| |||
0 commit comments