formalconf 2.0.14 → 2.0.15
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.
- package/dist/formalconf.js +14 -1
- package/package.json +1 -1
package/dist/formalconf.js
CHANGED
|
@@ -467,7 +467,7 @@ function StatusIndicator({
|
|
|
467
467
|
// package.json
|
|
468
468
|
var package_default = {
|
|
469
469
|
name: "formalconf",
|
|
470
|
-
version: "2.0.
|
|
470
|
+
version: "2.0.15",
|
|
471
471
|
description: "Dotfiles management TUI for macOS and Linux - config management, package sync, and theme switching",
|
|
472
472
|
type: "module",
|
|
473
473
|
main: "./dist/formalconf.js",
|
|
@@ -5629,6 +5629,11 @@ function getContextValue(context, variableName, modifier) {
|
|
|
5629
5629
|
const value = context.theme[key];
|
|
5630
5630
|
return value !== undefined ? String(value) : undefined;
|
|
5631
5631
|
}
|
|
5632
|
+
if (variableName.startsWith("gtk.")) {
|
|
5633
|
+
const key = variableName.slice(4);
|
|
5634
|
+
const value = context.gtk[key];
|
|
5635
|
+
return value !== undefined ? String(value) : undefined;
|
|
5636
|
+
}
|
|
5632
5637
|
if (variableName === "mode") {
|
|
5633
5638
|
return context.mode;
|
|
5634
5639
|
}
|
|
@@ -5921,6 +5926,13 @@ function buildThemeMetadata(theme, mode) {
|
|
|
5921
5926
|
mode
|
|
5922
5927
|
};
|
|
5923
5928
|
}
|
|
5929
|
+
function buildGtkMetadata(theme, mode) {
|
|
5930
|
+
const themeName = theme.title.toLowerCase().replace(/\s+/g, "-");
|
|
5931
|
+
const modeCapitalized = mode === "dark" ? "Dark" : "Light";
|
|
5932
|
+
return {
|
|
5933
|
+
theme: `formalconf-${themeName}-${modeCapitalized}`
|
|
5934
|
+
};
|
|
5935
|
+
}
|
|
5924
5936
|
function buildTemplateContext(theme, palette, mode) {
|
|
5925
5937
|
return {
|
|
5926
5938
|
color0: hexToColorVariable(palette.color0),
|
|
@@ -5947,6 +5959,7 @@ function buildTemplateContext(theme, palette, mode) {
|
|
|
5947
5959
|
accent: hexToColorVariableOrDefault(palette.accent, palette.color4),
|
|
5948
5960
|
border: hexToColorVariableOrDefault(palette.border, palette.color0),
|
|
5949
5961
|
theme: buildThemeMetadata(theme, mode),
|
|
5962
|
+
gtk: buildGtkMetadata(theme, mode),
|
|
5950
5963
|
mode
|
|
5951
5964
|
};
|
|
5952
5965
|
}
|
package/package.json
CHANGED