Bug 242112

Summary: [LFC][FFC] Add support for non-stretching flex items with flex-basis
Product: WebKit Reporter: zalan <zalan>
Component: Layout and RenderingAssignee: zalan <zalan>
Status: RESOLVED FIXED    
Severity: Normal CC: bfulgham, koivisto, ntim, simon.fraser, webkit-bug-importer, zalan
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch none

Description zalan 2022-06-29 09:34:17 PDT
where flex-basis != logical width
Comment 1 zalan 2022-06-29 09:43:33 PDT
Created attachment 460543 [details]
Patch
Comment 2 Tim Nguyen (:ntim) 2022-06-29 10:58:28 PDT
Comment on attachment 460543 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=460543&action=review

> Source/WebCore/layout/formattingContexts/flex/FlexLayout.cpp:232
> +                auto flexedSize = reolvedFlexItem.flexBasis + reolvedFlexItem.flexGrow * flexGrowBase;
> +                if (flexedSize && reolvedFlexItem.minimumSize >= flexedSize) {
> +                    reolvedFlexItem.isFrozen = true;
>                      didFreeze = true;
> -                    totalGrowth -= stretchingFlex.flexGrow;
> -                    totalFlexibleSpace -= stretchingFlex.flexBasis;
> -                    availableSpace -= stretchingFlex.minimumSize;
> +                    totalGrowth -= reolvedFlexItem.flexGrow;
> +                    totalFlexibleSpace -= reolvedFlexItem.flexBasis;
> +                    availableSpace -= reolvedFlexItem.minimumSize;
>                  }

typo: reolved
Comment 3 zalan 2022-07-01 20:21:26 PDT
Created attachment 460629 [details]
Patch
Comment 4 EWS 2022-07-01 21:37:27 PDT
Committed 252087@main (02229f46cd9b): <https://commits.webkit.org/252087@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 460629 [details].
Comment 5 Radar WebKit Bug Importer 2022-07-01 21:38:14 PDT
<rdar://problem/96330047>