From 828da2ce9e88c6a0cc0c33f22f764c4283a1f651 Mon Sep 17 00:00:00 2001 From: 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> Date: Thu, 16 Jan 2025 23:17:31 +1100 Subject: base popdown window --- scss/_lib.scss | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) (limited to 'scss/_lib.scss') diff --git a/scss/_lib.scss b/scss/_lib.scss index d2ad3d0..63bf618 100644 --- a/scss/_lib.scss +++ b/scss/_lib.scss @@ -1,5 +1,6 @@ @use "sass:color"; @use "scheme"; +@use "font"; $scale: 0.068rem; @function s($value: 1) { @@ -42,3 +43,57 @@ $scale: 0.068rem; @mixin ease-in-out { transition-timing-function: cubic-bezier(0.85, 0, 0.15, 1); } + +@mixin popdown-window($colour) { + @include rounded(8); + @include border($colour, 0.4, 2); + @include shadow; + @include font.mono; + + background-color: scheme.$base; + color: $colour; + padding: s(10) s(12); + font-size: s(14); + + .header { + @include spacing(8); + + padding: 0 s(5); + margin-bottom: s(8); + font-size: s(15); + + button { + @include rounded(5); + @include element-decel; + + padding: s(3) s(8); + + &:hover, + &:focus { + background-color: scheme.$surface0; + } + + &:active { + background-color: scheme.$surface1; + } + + &.enabled { + background-color: $colour; + color: scheme.$base; + + &:hover, + &:focus { + background-color: color.mix($colour, scheme.$base, 80%); + } + + &:active { + background-color: color.mix($colour, scheme.$base, 70%); + } + } + } + } + + .icon { + font-size: s(32); + } +} -- cgit v1.2.3-freya