Skip to content

Commit

Permalink
gradient by default
Browse files Browse the repository at this point in the history
  • Loading branch information
kikipoulet committed Oct 9, 2024
1 parent 9e46a49 commit 31eb8c3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion SukiUI.Demo/SukiUIDemoViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public partial class SukiUIDemoViewModel : ObservableObject
[ObservableProperty] private DemoPageBase? _activePage;
[ObservableProperty] private bool _windowLocked;
[ObservableProperty] private bool _titleBarVisible = true;
[ObservableProperty] private SukiBackgroundStyle _backgroundStyle = SukiBackgroundStyle.Bubble;
[ObservableProperty] private SukiBackgroundStyle _backgroundStyle = SukiBackgroundStyle.Gradient;
[ObservableProperty] private bool _animationsEnabled;
[ObservableProperty] private string? _customShaderFile;
[ObservableProperty] private bool _transitionsEnabled;
Expand Down
6 changes: 3 additions & 3 deletions SukiUI/Content/Shaders/Background/gradient.sksl
Original file line number Diff line number Diff line change
Expand Up @@ -66,14 +66,14 @@ vec4 main(vec2 fragCoord) {
float opacityLayer2 = 0.85 - (iDark / 2);


float iPrimaryOpacity = 0.2; // Exemple de nouvelle opacité pour iPrimary
float iPrimaryOpacity = 1.5; // Exemple de nouvelle opacité pour iPrimary
if (iDark == 1) {
iPrimaryOpacity = 0.4;
}
vec3 iPrimaryWithOpacity = iPrimary * iPrimaryOpacity;


float iAccentOpacity = 1;
float iAccentOpacity = -1.05;
if (iDark == 1) {
iAccentOpacity = 2;
}
Expand All @@ -89,7 +89,7 @@ vec4 main(vec2 fragCoord) {

vec3 col;
if (iDark == 0) {
col = blendOverlay(iBase, finalComp);
col = blendOverlay(iBase * 1.02, finalComp);
} else {
col = blendOverlayDark(iBase, finalComp);
}
Expand Down
2 changes: 1 addition & 1 deletion SukiUI/Controls/SukiBackground.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public class SukiBackground : Control
{
public static readonly StyledProperty<SukiBackgroundStyle> StyleProperty =
AvaloniaProperty.Register<SukiWindow, SukiBackgroundStyle>(nameof(Style),
defaultValue: SukiBackgroundStyle.Bubble);
defaultValue: SukiBackgroundStyle.Gradient);

/// <summary>
/// Which of the default background styles to use - DEFAULT: Gradient
Expand Down

0 comments on commit 31eb8c3

Please sign in to comment.