Commit f7ac814
authored
refactor: Extract shared layout computation from painter (#1021)
* refactor: extract layout to shared function
* refactor: consolidate right prompt fields into RightPromptBounds
Replace the redundant `right_prompt_rendered` bool and three separate
Option fields with a single `Option<RightPromptBounds>` struct in both
PromptLayout and RenderSnapshot, ensuring the fields are always set
or unset together. Add unit tests for compute_layout.1 parent 9955d10 commit f7ac814
2 files changed
+313
-203
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1951 | 1951 | | |
1952 | 1952 | | |
1953 | 1953 | | |
1954 | | - | |
1955 | | - | |
1956 | | - | |
1957 | | - | |
1958 | | - | |
1959 | | - | |
| 1954 | + | |
| 1955 | + | |
| 1956 | + | |
| 1957 | + | |
| 1958 | + | |
| 1959 | + | |
| 1960 | + | |
| 1961 | + | |
1960 | 1962 | | |
1961 | 1963 | | |
1962 | 1964 | | |
| |||
2120 | 2122 | | |
2121 | 2123 | | |
2122 | 2124 | | |
2123 | | - | |
2124 | | - | |
2125 | | - | |
2126 | | - | |
| 2125 | + | |
2127 | 2126 | | |
2128 | 2127 | | |
2129 | 2128 | | |
| |||
0 commit comments