diff --git a/config/aurora/modules/Bar.qml b/config/aurora/modules/Bar.qml index c98fb1c..88cd289 100644 --- a/config/aurora/modules/Bar.qml +++ b/config/aurora/modules/Bar.qml @@ -89,42 +89,11 @@ PanelWindow { } - - Rectangle { - + BarLeft { id: leftRect - - implicitHeight: parent.height - - - implicitWidth: 40 - - color: Pywal.special.background - - - Launcher { - id: launcher - x: parent.width / 2 - implicitWidth / 2 - y: implicitWidth / 3 - Layout.alignment: Qt.AlignHCenter | Qt.AlignTop - } - - Workspaces { - id: workspaces - x: parent.width / 2 - implicitWidth / 2 - y: 20 + launcher.y + launcher.height - Layout.alignment: Qt.AlignHCenter | Qt.AlignTop - } - - IdleInhibitor { - id: idleInhibitor - x: parent.width / 2 - implicitWidth / 2 - y: 20 + workspaces.y + workspaces.height - Layout.alignment: Qt.AlignHCenter | Qt.AlignTop - visible: false - } } + Rectangle { id: rightRect x: parent.width - width @@ -226,58 +195,12 @@ PanelWindow { } } - VFlyout { + BarTop { id: midFO x: root.screen.width / 2 - width / 2 y: topRect.y + topRect.height - 1 - - color: Pywal.special.background - - visible: set - - property bool set: true - - item: mid - - RowLayout { - id: mid - - Notifications { - id: notifications - window: root - } - - Battery { - window: root - popupOffset: x + midFO.x - } - - Tray { - window: root - popupOffset: x + midFO.x - } - - Clock { - id: clock - } - - Bluetooth { - window: root - popupOffset: x + midFO.x - } - - Volume { - window: root - popupOffset: x + midFO.x - } - - Power { - id: power - window: root - popupOffset: x + midFO.x - } - } - - radius: radius + window: root + radius: root.radius } + } diff --git a/config/aurora/modules/BarLeft.qml b/config/aurora/modules/BarLeft.qml new file mode 100644 index 0000000..ef39fff --- /dev/null +++ b/config/aurora/modules/BarLeft.qml @@ -0,0 +1,38 @@ +import Quickshell // for PanelWindow +import QtQuick // for Text +import QtQuick.Shapes +import QtQuick.Controls +import QtQuick.Layouts +import Quickshell.Io +import Quickshell.Widgets +import Quickshell.Wayland +import Quickshell.Hyprland + + +Rectangle { + + id: leftRect + + implicitHeight: parent.height + + implicitWidth: 40 + + color: Pywal.special.background + + + Launcher { + id: launcher + x: parent.width / 2 - implicitWidth / 2 + y: implicitWidth / 3 + Layout.alignment: Qt.AlignHCenter | Qt.AlignTop + } + + Workspaces { + id: workspaces + x: parent.width / 2 - implicitWidth / 2 + y: 20 + launcher.y + launcher.height + Layout.alignment: Qt.AlignHCenter | Qt.AlignTop + } + + +} diff --git a/config/aurora/modules/BarTop.qml b/config/aurora/modules/BarTop.qml new file mode 100644 index 0000000..76b6a85 --- /dev/null +++ b/config/aurora/modules/BarTop.qml @@ -0,0 +1,70 @@ +import Quickshell // for PanelWindow +import QtQuick // for Text +import QtQuick.Shapes +import QtQuick.Controls +import QtQuick.Layouts +import Quickshell.Io +import Quickshell.Widgets +import Quickshell.Wayland +import Quickshell.Hyprland + +VFlyout { + id: midFO + + color: Pywal.special.background + + visible: set + + property bool set: true + + property QsWindow window + + property real radius + + item: mid + + RowLayout { + id: mid + + Notifications { + id: notifications + window: midFO.window + } + + Battery { + window: midFO.window + popupOffset: x + midFO.x + } + + Tray { + window: midFO.window + popupOffset: x + midFO.x + } + + Clock { + id: clock + } + + IdleInhibitor { + id: idleInhibitor + } + + Bluetooth { + window: midFO.window + popupOffset: x + midFO.x + } + + Volume { + window: midFO.window + popupOffset: x + midFO.x + } + + Power { + id: power + window: midFO.window + popupOffset: x + midFO.x + } + } + + radius: radius + } diff --git a/flake.nix b/flake.nix index b9d34c6..06b1b5a 100644 --- a/flake.nix +++ b/flake.nix @@ -4,6 +4,8 @@ inputs = { nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; + home-manager.url = "github:nix-community/home-manager"; + flake-parts.url = "github:hercules-ci/flake-parts"; import-tree.url = "github:vic/import-tree"; diff --git a/nix/homeManagerModule.nix b/nix/homeManagerModule.nix new file mode 100644 index 0000000..5c6a550 --- /dev/null +++ b/nix/homeManagerModule.nix @@ -0,0 +1,33 @@ +{ self', inputs, ... }: { + + imports = [ + inputs.home-manager.flakeModules.home-manager + ]; + + flake.homeModules.default = { config, lib, pkgs, ... }: { + + options.programs.aurora = with lib; { + enable = mkEnableOption "aurora"; + + package = mkPackageOption self'.packages "aurora" { + default = [ "aurora" ]; + + example = "aurora.packages.hybar"; + }; + }; + + config = lib.mkIf config.programs.aurora.enable { + + programs.quickshell = { + enable = true; + + package = config.programs.aurora.package; + + systemd = { + enable = true; + target = "wayland-session@Hyprland.target"; + }; + }; + }; + }; +} diff --git a/dev/shells.nix b/nix/shells.nix similarity index 100% rename from dev/shells.nix rename to nix/shells.nix diff --git a/dev/systems.nix b/nix/systems.nix similarity index 100% rename from dev/systems.nix rename to nix/systems.nix