Bug 261244

Summary: [css-grid] grid should not always put first and last baseline aligned items into different alignment contexts
Product: WebKit Reporter: Sammy Gill <sgill26>
Component: Layout and RenderingAssignee: Sammy Gill <sgill26>
Status: RESOLVED FIXED    
Severity: Normal CC: bfulgham, simon.fraser, webkit-bug-importer, zalan
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 260570    

Description Sammy Gill 2023-09-06 17:01:27 PDT
Currently grid computes the alignment context for first/last baseline aligned items as follows:

auto spanForBaselineAlignment = align == ItemPosition::Baseline ? span.startLine() : span.endLine()

This is not correct because items that are in the same track with different baseline alignments are technically in the same alignment context. As a result, items in the same alignment context can be in the same baseline sharing group is their baseline alignment preferences are compatible

https://drafts.csswg.org/css-align-3/#baseline-terms
Comment 1 Radar WebKit Bug Importer 2023-09-06 17:01:42 PDT
<rdar://problem/115083708>
Comment 2 Sammy Gill 2023-09-06 17:17:31 PDT
Pull request: https://github.com/WebKit/WebKit/pull/17517
Comment 3 EWS 2023-09-12 15:13:30 PDT
Committed 267922@main (caab01d5e748): <https://commits.webkit.org/267922@main>

Reviewed commits have been landed. Closing PR #17517 and removing active labels.