Comments (1)
The CSS Working Group just discussed [css-grid-3][masonry] Make auto-fit do things
, and agreed to the following:
RESOLVED: Make auto-fit drop tracks after sizing and placement, and apply content distribution to the tracks again afterward
The full IRC log of that discussion
<dbaron> fantasai: tab pointed out that the auto-fit value in masonry specs is designed to behave the same as auto-fill<dbaron> fantasai: auto-fill will fit as many columns as fit in the containing block and leave that there
<dbaron> fantasai: auto-fit will do that, but then collapse any columns that are free after placement
<dbaron> fantasai: so we could do similar in masonry, but if we're doing auto sized columns it might not be as exciting
<TabAtkins> q+
<dbaron> fantasai: but we can redistribute the space if you have a fixed # of columns or an auto # of colums that ...
<dbaron> fantasai: so we can still do things like collapse the empty columns in masonry
<dbaron> fantasai: so if you have fewer items than columns or explicitly placed columns then you can end up with empty tracks
<dbaron> florian: any reason not to?
<dbaron> fantasai: I can't think of any reason not ot.
<dbaron> s/not ot/not to/
<dbaron> TabAtkins: a potential reason: if you move the columns around and potentially change size or gap between them (have spanners), this changes the size of things in the columns because they now have more space to flow into, which could make things shorter and could theoretically change column placement
<dbaron> TabAtkins: so your final masonry might end up more ragged than it would otherwise have been
<dbaron> TabAtkins: but that's largely a non-issue because your masonry is nearly empty
<dbaron> florian: but if you didn't want that, use the other keyword that doesn't do that
<dbaron> fantasai: also you can do this after track sizing
<dbaron> fantasai: size tracks, place items, figure out what's empty, don't resize the tracks afterwards
<dbaron> fantasai: doesn't reduce space into the tracks (like grid), but lets you redistribute spcae using alignment properties
<dbaron> fantasai: that track won't get empty, but increased gap size will increase available space to spanning item
<dbaron> florian: either way we're discussing whether it does the same as auto-fill, so if you don't want the rejiggering, use auto-fill
<dbaron> fantasai: further comments?
<dbaron> oriol: a question: if you use the align properties like align-content and set them to stretch, and then we can't stretch the tracks, does stretch not work on masonry?
<dbaron> oriol: is it just in this case where you're collapsing tracks... or in general?
<dbaron> fantasai: probably need to apply the distribution before placements -- size the tracks, apply alignment, then place items.
<dbaron> fantasai: if you want to do this drop tracks and then reapply values... wouldn't apply stretch because we don't want to resize the tracks
<dbaron> oriol: then if the values stretch, you have start alignment? fall back to other alignment?
<dbaron> fantasai: I think you get start.
<dbaron> fantasai: I think you have the same problem in grid if you don't have any auto tracks and you say stretch.
<dbaron> fantasai: we might want to give stretch a fallback alignment option.
<dbaron> fantasai: should we do it? I see Rachel nodding.
<fantasai> RESOLVED: Make auto-fit drop tracks after sizing and placement, and apply content distribution to the tracks again afterward
from csswg-drafts.
Related Issues (20)
- [css-scoping] Add abilty to select slot fallback content
- [css-color-5] Edge cases for color-mix() percentage serialization questions HOT 1
- [css-view-transitions-2] Elements with content-visibility in new Document HOT 3
- [css-scroll-snap-2] How should competing scroll-start-targets be resolved? HOT 1
- [css-ui] Should `::picker(select)` match `:popover-open`? HOT 3
- [css-anchor-position-1] have a better example of using math functions with the anchor() function
- [css-variables][css-pseudo] Question about setting variable values in pseudo classes HOT 3
- [css-flex] Nobody follows the spec regarding intrinsic size of flex container HOT 5
- [css-view-transition-2] Should non-default `view-transition-group` act like `contain`? HOT 5
- [css-flexbox-1] Change flex shorthand of flex:1 back to setting a flex-basis of 0%. HOT 1
- [css-conditional] @container scroll-state(snapped) and snapchanged vs snapchanging
- [css-text] Performance risks of text-wrap:pretty HOT 1
- [css-shadow-parts] are rules for which pseudo-classes and pseudo-elements work after ::part() parse-time or match-time? HOT 1
- [css-shadow-parts] need definition of which pseudo-classes can follow :part() that is sufficient to produce interoperability HOT 1
- [css-shadow-parts][css-nesting] is & allowed after ::part()
- [css-view-transitions-2] Use `@starting-style` to customize initial/final states of content pseudos
- [css-values-4][css-conditional] Define `<atomic-condition>` that other specs reference
- [css-text] Replacement for `text-align: <string>` and solution for numeric column alignment
- [css-variables] Typo in css-variables-1/Overview.bs
- [css-pseudo] more clearly define which pseudo-elements are tree-abiding or part-like
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from csswg-drafts.