From 6d4f8e2b2e8fde38efcc3f13fbe6188abed5a24a Mon Sep 17 00:00:00 2001 From: Volpeon Date: Sun, 13 Feb 2022 21:05:19 +0100 Subject: Added monospace font --- src/_base.scss | 32 ++++++++++++++++++++++++++++++++ src/_declare-vars.scss | 4 ++++ 2 files changed, 36 insertions(+) diff --git a/src/_base.scss b/src/_base.scss index 814e491..61dae42 100644 --- a/src/_base.scss +++ b/src/_base.scss @@ -1,3 +1,4 @@ +@use 'sass:math'; @use 'iro-sass/src/index' as iro; @use 'functions' as fn; @use 'mixins' as mx; @@ -16,6 +17,21 @@ body { color: fn.color(--fg); } +pre, +code { + @include mx.set-font(--mono, (--size: fn.dim(--font-size --sm))); +} + +pre { + margin: 0; + overflow-x: auto; + + code { + color: currentColor; + font-size: 1em; + } +} + h1, h2, h3, @@ -87,6 +103,22 @@ textarea { } } +input, +textarea { + &::placeholder { + opacity: 1; + color: fn.color(--obj); + } + + &:disabled { + color: fn.color(--fg-hi); + } +} + +textarea { + height: calc(1em * fn.dim(--font --standard --line-height)); +} + ::selection { background: fn.color(--selection --bg); color: fn.color(--selection --fg); diff --git a/src/_declare-vars.scss b/src/_declare-vars.scss index d81b299..27245ba 100644 --- a/src/_declare-vars.scss +++ b/src/_declare-vars.scss @@ -34,6 +34,10 @@ --family: ('IBM Plex Sans', 'Open Sans', 'Segoe UI', 'Droid Sans', Roboto, Oxygen, 'Helvetica Neue', Helvetica, Tahoma, Arial, sans-serif), --line-height: 1.2, --weight: 700, + ), + --mono: ( + --family: ('Iosevka Term SS09', 'IBM Plex Mono', 'Menlo', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', Courier, monospace), + --line-height: 1.4, ) ), -- cgit v1.2.3-70-g09d2