mirror of
https://github.com/cheeaun/phanpy.git
synced 2025-02-02 14:16:39 +01:00
First attempt of CSS container query
This commit is contained in:
parent
6cbbd0aa1b
commit
8cc85ecb1a
1 changed files with 13 additions and 1 deletions
14
src/app.css
14
src/app.css
|
@ -747,6 +747,7 @@ a[href^='http'][rel*='nofollow']:visited:not(:has(div)) {
|
|||
transparent 150%
|
||||
);
|
||||
position: relative;
|
||||
container-type: inline-size;
|
||||
}
|
||||
.status-carousel:after {
|
||||
content: '';
|
||||
|
@ -806,7 +807,18 @@ a[href^='http'][rel*='nofollow']:visited:not(:has(div)) {
|
|||
.status-carousel > ul > li:is(:empty, :has(> a:empty)) {
|
||||
display: none;
|
||||
}
|
||||
@media (hover: hover) or (pointer: fine) or (min-width: 40em) {
|
||||
/*
|
||||
Assume that browsers that do support inline-size property also support container queries.
|
||||
https://www.smashingmagazine.com/2021/05/css-container-queries-use-cases-migration-strategies/#progressive-enhancement-polyfills
|
||||
*/
|
||||
@supports not (contain: inline-size) {
|
||||
@media (hover: hover) or (pointer: fine) or (min-width: 40em) {
|
||||
.status-carousel > ul {
|
||||
scroll-snap-type: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
@container (min-width: 640px) {
|
||||
.status-carousel > ul {
|
||||
scroll-snap-type: none;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue