Skip to content

Commit

Permalink
Redesign Appearance Fuse
Browse files Browse the repository at this point in the history
  • Loading branch information
lainsce committed Sep 19, 2023
1 parent 271321e commit d18d412
Show file tree
Hide file tree
Showing 12 changed files with 457 additions and 295 deletions.
99 changes: 80 additions & 19 deletions data/assets/by-apps.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
64 changes: 52 additions & 12 deletions data/assets/dark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 0 additions & 13 deletions data/assets/harsh.svg

This file was deleted.

64 changes: 52 additions & 12 deletions data/assets/light.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 0 additions & 13 deletions data/assets/medium.svg

This file was deleted.

13 changes: 0 additions & 13 deletions data/assets/soft.svg

This file was deleted.

3 changes: 0 additions & 3 deletions data/settings.gresources.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@
<file alias="style-dark.css">style-dark.css</file>
</gresource>
<gresource prefix="/com/fyralabs/Fusebox/Appearance">
<file alias="soft.svg">assets/soft.svg</file>
<file alias="medium.svg">assets/medium.svg</file>
<file alias="harsh.svg">assets/harsh.svg</file>
<file alias="light.svg">assets/light.svg</file>
<file alias="dark.svg">assets/dark.svg</file>
<file alias="by-apps.svg">assets/by-apps.svg</file>
Expand Down
37 changes: 22 additions & 15 deletions data/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -68,13 +68,6 @@ button.flat label {
background: alpha(#72da82, 0.18);
}

.mint radio {
background: #85d1bf;
}
.mint:disabled radio {
background: alpha(#85d1bf, 0.18);
}

.blue radio {
background: #58a8fa;
}
Expand All @@ -89,13 +82,6 @@ button.flat label {
background: alpha(#a57bcd, 0.18);
}

.brown radio {
background: #bf8856;
}
.brown:disabled radio {
background: alpha(#bf8856, 0.18);
}

.pink radio {
background: #cb76b8;
}
Expand All @@ -111,7 +97,7 @@ button.flat label {
}

.multi radio {
background: linear-gradient(45deg,
background: linear-gradient(90deg,
#e25480 0%,
#f99e5c 13%,
#febc16 26%,
Expand Down Expand Up @@ -257,3 +243,24 @@ spinbutton.flat {
.ensor-box > flowbox > flowboxchild:selected {
box-shadow: 0 0 0 5px @accent_color, 0 0 0 2px @view_bg_color;
}

.color-scheme-button {
padding: 6px;
background: none;
}
.color-scheme-button image {
box-shadow: 0 0 0 1px alpha(@outline, 0.38);
border-radius: 8px;
}
.color-scheme-button label {
font-weight: 500;
}
.color-scheme-button:hover image {
box-shadow: 0 0 0 1px @outline;
}
.color-scheme-button:checked image {
box-shadow: 0 0 0 3px @accent_color;
}
.color-scheme-button:checked label {
font-weight: 700;
}
25 changes: 1 addition & 24 deletions fuses/appearance/AppearanceFuse.vala
Original file line number Diff line number Diff line change
Expand Up @@ -30,32 +30,9 @@ public class Appearance.Fuse : Fusebox.Fuse {
public override Gtk.Widget get_widget () {
if (main_grid == null) {
appearance_view = new AppearanceView (this);
// var dock_view = new DockView (this);
var text_view = new TextView ();

main_stack = new Gtk.Stack () {
transition_type = Gtk.StackTransitionType.SLIDE_LEFT_RIGHT,
transition_duration = 400
};
main_stack.add_titled (appearance_view, "desktop", _("Desktop"));
main_stack.add_titled (text_view, "text", _("Text"));
// if (GLib.Environment.find_program_in_path ("kiri-panel") != null) {
// main_stack.add_titled (dock_view, "dock", _("Dock"));
// }

var stack_switcher = new He.ViewSwitcher ();
stack_switcher.stack = main_stack;

var appbar = new He.AppBar () {
viewtitle_widget = stack_switcher,
show_back = false,
scroller = appearance_view.sw,
margin_bottom = 12,
};

main_grid = new Gtk.Grid ();
main_grid.attach (appbar, 0, 0);
main_grid.attach (main_stack, 0, 1);
main_grid.attach (appearance_view, 0, 1);
}

return main_grid;
Expand Down
Loading

0 comments on commit d18d412

Please sign in to comment.