Commit 261beac
authored
fix(view): collapse split-view grid only after swipe activation succeeds (#854)
* fix(view): collapse split-view grid only after swipe activation succeeds
Follow-up to #844. The merged change ran setMapGrid(1, 1) before
manager.toggle, so a failed swipe activation (a throw, or addMapControl
returning false) discarded the user's split-view layout with no swipe to
show for it. Activate first, then collapse the grid only when the swipe
control is actually live. Addresses a CodeRabbit review note on #852 that
landed after the PR was merged.
* docs: note swipe-activation-order guard assumes synchronous activate
Address review: tie the manager.isActive(id) correctness claim to the
synchronous-only activation of maplibre-swipe, so a future dynamic-import
path that makes activate async is flagged as needing this guard revisited.1 parent 54f2da0 commit 261beac
1 file changed
Lines changed: 18 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
267 | 267 | | |
268 | 268 | | |
269 | 269 | | |
270 | | - | |
271 | | - | |
272 | | - | |
273 | | - | |
274 | | - | |
275 | | - | |
276 | | - | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
277 | 274 | | |
278 | 275 | | |
279 | 276 | | |
| |||
288 | 285 | | |
289 | 286 | | |
290 | 287 | | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
291 | 302 | | |
292 | 303 | | |
293 | 304 | | |
| |||
0 commit comments