theme-vir 28.21.1 → 28.21.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -119,7 +119,8 @@ function colorInitValueToCode(value, indentLevel, paletteVarName) {
|
|
|
119
119
|
function colorInitToCode(colorInit, indentLevel, defaultInit, paletteVarName) {
|
|
120
120
|
const entries = [];
|
|
121
121
|
if ('foreground' in colorInit &&
|
|
122
|
-
(!defaultInit || !colorInitValuesEqual(colorInit.foreground, defaultInit.foreground))
|
|
122
|
+
(!defaultInit || !colorInitValuesEqual(colorInit.foreground, defaultInit.foreground)) &&
|
|
123
|
+
!check.hasKey(colorInit.foreground, 'refDefaultForeground')) {
|
|
123
124
|
// Check if foreground matches default background (use refDefaultBackground)
|
|
124
125
|
if (defaultInit && colorInitValuesEqual(colorInit.foreground, defaultInit.background)) {
|
|
125
126
|
entries.push(`${tab(indentLevel + 1)}foreground: {\n${tab(indentLevel + 2)}refDefaultBackground: true,\n${tab(indentLevel + 1)}},`);
|
|
@@ -129,7 +130,8 @@ function colorInitToCode(colorInit, indentLevel, defaultInit, paletteVarName) {
|
|
|
129
130
|
}
|
|
130
131
|
}
|
|
131
132
|
if ('background' in colorInit &&
|
|
132
|
-
(!defaultInit || !colorInitValuesEqual(colorInit.background, defaultInit.background))
|
|
133
|
+
(!defaultInit || !colorInitValuesEqual(colorInit.background, defaultInit.background)) &&
|
|
134
|
+
!check.hasKey(colorInit.background, 'refDefaultBackground')) {
|
|
133
135
|
// Check if background matches default foreground (use refDefaultForeground)
|
|
134
136
|
if (defaultInit && colorInitValuesEqual(colorInit.background, defaultInit.foreground)) {
|
|
135
137
|
entries.push(`${tab(indentLevel + 1)}background: {\n${tab(indentLevel + 2)}refDefaultForeground: true,\n${tab(indentLevel + 1)}},`);
|