Skip to content

Commit

Permalink
.delayed changes
Browse files Browse the repository at this point in the history
- Switch default behavior to *not* fade out displayed items (use class `transient` or `delayed-transient` on an ancestor to override)
- `collapse` modifier class to use `display: none` instead of opacity
  • Loading branch information
LeaVerou committed Feb 20, 2024
1 parent dbc51ea commit ee3fe87
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions inspire.css
Original file line number Diff line number Diff line change
Expand Up @@ -146,22 +146,31 @@ body {


/* Delayed items that are shown incrementally after the slide is */
@media screen {
.delayed,
.delayed-children > * {
.delayed,
.delayed-children > * {
@media screen {
opacity: 0;
transition-property: var(--transition-properties);

&.displayed {
opacity: .3;
&:where(.transient, .transient > *, .delayed-transient *) {
opacity: .3;
}
}

&.current,
&.displayed:is(.persistent, .persistent *) {
&.displayed {
opacity: 1;
transition-duration: var(--transition-duration);
}
}

&.future,
&.displayed {
&:where(.collapse, .collapse > *, .delayed-collapse *) {
display: none;
}
}
}

.slide[data-steps] {
Expand Down

0 comments on commit ee3fe87

Please sign in to comment.