Questions
- Should we still have separate "Flexbox" and "Grid" sections in the navbar? If not, where do we move the content to?
Possible impls
Blocked: @scope in Firefox. Update: no longer blocked
Blocked: attr() for <custom-ident> in Firefox (I think? mdn isn't clear on this): Update: still blocked: https://caniuse.com/mdn-css_types_attr_type_function_ident
Possible new syntax from @dz4k
<style>
.grid {
[id] {
grid-area: attr(id);
}
}
</style>
<div class="grid" style="
grid-template: if(
media(width < 768px), 'title' 'nav' 'content',
'title title' 'nav content' / auto 1fr
)
">
<h1 id=title>...</h1>
<nav id=nav>...</nav>
<div id=content>...</nav>
More suggestions from deniz:
.layout-grid {
display: grid;
gap: var(--gap);
margin-block: var(--gap);
@media (max-width: 768px) {
display: flex;
flex-flow: column nowrap;
}
}
Usage:
<article class="layout-grid" style="grid: 1fr / 1fr 2fr">
<!-- or -->
<article class="layout-grid" style="
grid-template:
'image title' auto
'image desc' 1fr
/auto 1fr
">
Questions
Possible impls
Blocked:Update: no longer blocked@scopein Firefox.Blocked:
attr()for<custom-ident>in Firefox (I think? mdn isn't clear on this): Update: still blocked: https://caniuse.com/mdn-css_types_attr_type_function_identPossible new syntax from @dz4k
More suggestions from deniz:
Usage: