Skip to content

Commit

Permalink
Если нет subtitle, то уменьшаем отступ до описания пьесы
Browse files Browse the repository at this point in the history
  • Loading branch information
1640max committed Jan 31, 2024
1 parent 61d51f3 commit 4ae4eb7
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions _sass/pieces/_piece-card.scss
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@
margin: 0;
}

/* Если нет subtitle */
.piece-card__title:only-child {
margin-bottom: -0.4em;
}

.piece-card__subtitle {
font: 500 1.25rem/130% $default-family;
}
Expand Down
4 changes: 3 additions & 1 deletion pieces.html
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@
</div>
<header class="piece-card__heading">
<h2 class="piece-card__title">{{ piece.title }}</h2>
<div class="piece-card__subtitle">{{ piece.subtitle }}</div>
{% if piece.subtitle %}
<div class="piece-card__subtitle">{{ piece.subtitle }}</div>
{% endif %}
</header>
<div class="piece-card__description">{{ piece.description }}</div>
<div class="delimiter piece-card__delimiter"></div>
Expand Down

0 comments on commit 4ae4eb7

Please sign in to comment.