Commit c837e3f
lhp: dlo: fix inline element layout regression
- Corrects the logic in `LHPCB_CONTENT` to prevent `box.w` from being
incorrectly expanded to full screen width for inline elements. The
condition `if (!box.w.whole && (!lhp_is_inline(ps) || ps->forced_inline))`
was flawed as it forced expansion for all forced-inline elements.
- Replaces the flawed condition with `if (!box.w.whole && !lhp_is_inline(ps))`,
ensuring width expansion is restricted to block-level elements.
- Adds `lhp_tag_cmp` for case-insensitive HTML tag matching to ensure
tags like `<SPAN>` are correctly identified and processed as inline.
- Marks `<span>` as `forced_inline` to ensure it is treated as an inline
element, preventing fallback to block behavior.1 parent 4490048 commit c837e3f
1 file changed
+20
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
99 | 99 | | |
100 | 100 | | |
101 | 101 | | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
102 | 119 | | |
103 | 120 | | |
104 | 121 | | |
| |||
621 | 638 | | |
622 | 639 | | |
623 | 640 | | |
624 | | - | |
| 641 | + | |
625 | 642 | | |
626 | 643 | | |
| 644 | + | |
627 | 645 | | |
628 | 646 | | |
629 | 647 | | |
| |||
1276 | 1294 | | |
1277 | 1295 | | |
1278 | 1296 | | |
1279 | | - | |
| 1297 | + | |
1280 | 1298 | | |
1281 | 1299 | | |
1282 | 1300 | | |
| |||
0 commit comments