1
0
mirror of https://github.com/koloml/philomena-tagging-assistant.git synced 2026-05-09 15:12:21 +00:00

Reading constants in SCSS, modifying colors for Derpibooru variant

This commit is contained in:
2025-08-08 19:39:30 +04:00
parent c37f680e9f
commit 4837184d40
2 changed files with 49 additions and 0 deletions

View File

@@ -0,0 +1,20 @@
@use 'sass:meta';
@use 'sass:string';
@function get-defined-constant($constant-name, $default-value: '') {
$resolved-value: $default-value;
@if meta.function-exists('vite-read-env-variable') {
$candidate-value: meta.call(meta.get-function('vite-read-env-variable'), $constant-name);
@if string.length($candidate-value) != 0 {
$resolved-value: $candidate-value
}
}
@return $resolved-value;
}
$current-site: get-defined-constant('__CURRENT_SITE__', 'furbooru');