Skip to content

CSS Grid 2/9: Grid layout algorithm#1894

Open
intergalacticspacehighway wants to merge 2 commits intofacebook:mainfrom
intergalacticspacehighway:css-grid-2-algorithm
Open

CSS Grid 2/9: Grid layout algorithm#1894
intergalacticspacehighway wants to merge 2 commits intofacebook:mainfrom
intergalacticspacehighway:css-grid-2-algorithm

Conversation

@intergalacticspacehighway
Copy link
Contributor

Summary

  • Core grid layout computation and dispatch integration
  • Includes AutoPlacement.h, GridLayout.h/cpp, TrackSizing.h
  • CalculateLayout.cpp grid dispatch, CMakeLists.txt updates

Split from #1865. Depends on #1893. Merge after 1/9.

NickGerleman and others added 2 commits February 25, 2026 16:51
Summary:
Add the foundational data types, enums, style properties, and C API for
expressing CSS Grid layouts in Yoga.

Includes:
- Grid style types (GridLine.h, GridTrack.h, GridTrackType.h)
- Updated enums (Display::Grid, Align::Start/End, Justify::Auto/Stretch/Start/End)
- Grid event (LayoutPassReason::kGridLayout)
- Style property accessors and member variables
- Public C API (YGGridTrackList.h/cpp, YGNodeStyle grid setters/getters)
- Layout helpers updated for new enum values (Align.h, AbsoluteLayout.cpp,
  CalculateLayout.cpp/h partial)
- Node.h: relativePosition made public
- React Native mirror of all C++ changes

Differential Revision: D93946262
Summary:
Add the core grid layout computation and integrate it into the layout
dispatcher.

Includes:
- AutoPlacement.h: auto-placement algorithm for grid items
- GridLayout.h/cpp: grid layout entry point
- TrackSizing.h: track sizing algorithm
- CalculateLayout.cpp: grid dispatch block and #include
- CMakeLists.txt: add algorithm/grid/*.cpp glob
- React Native mirror of all C++ changes

Differential Revision: D93946253
@vercel
Copy link

vercel bot commented Feb 25, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
yoga-website Ready Ready Preview, Comment Feb 25, 2026 9:33pm

Request Review

@meta-cla meta-cla bot added the CLA Signed label Feb 25, 2026
@facebook-github-bot facebook-github-bot added the Shared with Meta Applied via automation to indicate that an Issue or Pull Request has been shared with the team. label Feb 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed Shared with Meta Applied via automation to indicate that an Issue or Pull Request has been shared with the team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants