From e2aa6c47fd0e244060c4e4e7941bd7998664c4ce Mon Sep 17 00:00:00 2001 From: eugenesvk Date: Wed, 3 May 2023 22:54:37 +0700 Subject: Add font-prepend function --- sass/function/_font.sass | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'sass/function/_font.sass') diff --git a/sass/function/_font.sass b/sass/function/_font.sass index c2b1165..95704c9 100644 --- a/sass/function/_font.sass +++ b/sass/function/_font.sass @@ -17,3 +17,12 @@ $base-pos: list.append($base-pos, $iEl, $separator:comma) @return list.join(list.join($base-pre, $ext), $base-pos) + +@function font-prepend($base, $ext) + $ext-type : meta.type-of($ext) + + @if not ($ext-type == 'string') and not ($ext-type == 'list') + @debug "⚠ Expected a string or a list, but got '#{$ext-type}' in '#{$ext}'" + @return $base + @else + @return list.join($ext,$base) -- cgit v1.3.1