Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support shorthand notation and area names in grid cell positioning #6084

Closed
ruggi opened this issue Jul 16, 2024 · 0 comments · Fixed by #6085
Closed

Support shorthand notation and area names in grid cell positioning #6084

ruggi opened this issue Jul 16, 2024 · 0 comments · Fixed by #6085
Assignees

Comments

@ruggi
Copy link
Contributor

ruggi commented Jul 16, 2024

No description provided.

@ruggi ruggi self-assigned this Jul 16, 2024
@ruggi ruggi closed this as completed in fa8f8d1 Jul 17, 2024
liady pushed a commit that referenced this issue Dec 13, 2024
**Problem:**

Shorthand notation for grid cells positioning should be supported across
the board (moving / resizing, not just parsing) and likewise area names
from the template should be reflected in the positioning props.

**Fix:**

1. Print the area names instead of the number values for grid
positioning (`gridRowStart`, `gridRowEnd`, ...) if there's a match
2. Use (and understand) the shorthand notation (`gridRow`, `gridColumn`)
when the underlying values are either the same or skewed by 1 (for start
→ end)
3. Unify the CSS property set logic so it can be reused among
strategies, making it behave according to the above ^

**Notes**
- We do support parsing shorthand notations with `/`-separated values,
but they are never printed for now. If there are multiple values, it
will currently use the longhand notation.

**Demo:** 


https://github.com/user-attachments/assets/c70ee34b-c921-44c0-a269-2d13af70da2d

Fixes #6084
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant