From 61614e57c4b87c6271fd4fef886ba6626cc8e49a Mon Sep 17 00:00:00 2001 From: Volpeon Date: Thu, 22 Apr 2021 20:48:06 +0200 Subject: Prevent card hover feedback loop --- assets/css/components/_card.scss | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'assets/css/components/_card.scss') diff --git a/assets/css/components/_card.scss b/assets/css/components/_card.scss index 9e73dd9..7bd76f3 100644 --- a/assets/css/components/_card.scss +++ b/assets/css/components/_card.scss @@ -29,6 +29,16 @@ background-color: prop(--colors --bg); line-height: 1.4; + &::after { + content: ''; + display: none; + position: absolute; + top: 100%; + left: 0; + width: 100%; + height: calc(-1 * #{prop(--dims --hover-offset)}); + } + small, strong { transition: background-color .2s, color .2s; @@ -43,6 +53,10 @@ transform: translateY(#{prop(--dims --hover-offset)}); background-color: prop(--colors --hover --bg); color: prop(--colors --hover --fg); + + &::after { + display: block; + } small, strong { -- cgit v1.2.3-54-g00ecf