mirror of
https://github.com/danbulant/dots-hyprland
synced 2026-05-24 12:22:09 +00:00
add gradience settings to color panel
This commit is contained in:
parent
2238ea51b3
commit
ec5e8cf084
2 changed files with 32 additions and 1 deletions
|
|
@ -104,7 +104,7 @@ const initScheme = Utils.exec(`bash -c "sed -n \'3p\' ${LIGHTDARK_FILE_LOCATION}
|
|||
const initSchemeIndex = calculateSchemeInitIndex(schemeOptionsArr, initScheme);
|
||||
|
||||
const ColorSchemeSettings = () => Widget.Box({
|
||||
className: 'osd-colorscheme-settings spacing-v-5',
|
||||
className: 'osd-colorscheme-settings spacing-v-5 margin-20',
|
||||
vertical: true,
|
||||
vpack: 'center',
|
||||
children: [
|
||||
|
|
@ -142,6 +142,34 @@ const ColorSchemeSettings = () => Widget.Box({
|
|||
.catch(print);
|
||||
},
|
||||
}),
|
||||
Widget.Box({
|
||||
tooltipText: 'Theme GTK apps using accent color\n(drawback: dark/light mode switching requires restart)',
|
||||
className: 'txt spacing-h-5 configtoggle-box',
|
||||
children: [
|
||||
MaterialIcon('imagesearch_roller', 'norm'),
|
||||
Widget.Label({
|
||||
className: 'txt txt-small',
|
||||
label: 'Use Gradience',
|
||||
}),
|
||||
Widget.Box({ hexpand: true }),
|
||||
ConfigMulipleSelection({
|
||||
hpack: 'center',
|
||||
vpack: 'center',
|
||||
optionsArr: [
|
||||
[{ name: 'Off', value: 0 }, { name: 'On', value: 1 }],
|
||||
],
|
||||
initIndex: [-1, -1],
|
||||
onChange: (value, name) => {
|
||||
const ADWAITA_BLUE = "#3584E4";
|
||||
if (value) execAsync([`bash`, `-c`, `${App.configDir}/scripts/color_generation/switchcolor.sh - --yes-gradience`, `&`])
|
||||
.catch(print);
|
||||
else execAsync([`bash`, `-c`, `${App.configDir}/scripts/color_generation/switchcolor.sh "${ADWAITA_BLUE}" --no-gradience`, `&`])
|
||||
.catch(print);
|
||||
|
||||
},
|
||||
}),
|
||||
]
|
||||
}),
|
||||
]
|
||||
}),
|
||||
Widget.Box({
|
||||
|
|
|
|||
|
|
@ -414,6 +414,9 @@
|
|||
.padding-#{$spacing} {
|
||||
padding: 0.068rem * $spacing;
|
||||
}
|
||||
.margin-#{$spacing} {
|
||||
padding: 0.068rem * $spacing;
|
||||
}
|
||||
}
|
||||
|
||||
.width-10 {
|
||||
|
|
|
|||
Loading…
Reference in a new issue