Repository navigation
fix(kanban): respect configured columnWidth across flat and swimlane views - #2755
Merged
Merged
Conversation
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.
Fixes #2754
Root cause
KanbanView.getRenderedColumnWidth()read back the existing--kanban-column-widthinline CSS variable fromboardElbefore falling back tothis.columnWidth, andrenderFlat()/renderSwimLaneTable()wrote that stale value back to--kanban-column-width. Once set, subsequentcolumnWidthupdates never replaced it during rendering.KanbanView.updateBoardLayout()computed desktop widths asMath.max(320, Math.min(this.columnWidth, available / Math.max(1, openCount))). That forced a 320px floor (ignoring slider values below 320) while capping widths to fit all open columns inside the viewport, pinning most multi-column desktop boards to 320px across the entire 200–500px slider range. Whenboard.clientWidth === 0(detached/hidden), the< 480branch also collapsed the width to0px.buildRenderSignature()did not includethis.columnWidthdirectly.Fix
--kanban-column-widthdirectly fromthis.columnWidthon desktop (and unmeasured boards), while keeping narrow-pane clamping (0 < clientWidth < 480) so a single column still fits inside mobile/narrow panes.var(--kanban-column-width, ...)on open flat columns and swimlane grid tracks (andvar(--kanban-swimlane-label-width, ...)on swimlane label tracks) so responsive/user CSS variable overrides continue to work while collapsed columns keep--tn-kanban-collapsed-column-width.columnWidthinbuildRenderSignature()and validate parsedcolumnWidthvalues inreadViewOptions().Verification
npm test(863 suites / 6,740 tests passed)npm run typecheck,npm run lint,npm run build:teste2e/issues/issue-2754-kanban-column-width.spec.ts,e2e/issues/issue-2531-kanban-horizontal-scroll.spec.ts,e2e/issues/issue-2382-kanban-nested-settings.spec.ts— 11 passed)