-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
55706fa
commit 01f1985
Showing
337 changed files
with
37,425 additions
and
528 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{pkgs ? import <nixpkgs> {}}: | ||
pkgs.mkShell { | ||
packages = with pkgs; [ | ||
(ags.overrideAttrs (old: { | ||
buildInputs = old.buildInputs ++ [pkgs.libdbusmenu-gtk3]; | ||
})) | ||
accountsservice | ||
brightnessctl | ||
bun | ||
dart-sass | ||
fd | ||
fzf | ||
gtk3 | ||
hyprpicker | ||
networkmanager | ||
pavucontrol | ||
slurp | ||
swww | ||
swappy | ||
wayshot | ||
wf-recorder | ||
wl-clipboard | ||
which | ||
]; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
cells/common/packages/_aags-config/widget/networkmenu/NetworkMenu.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import PopupWindow from "widget/PopupWindow"; | ||
// import { Ethernet } from "./ethernet"; | ||
import { Wifi } from "./wifi"; | ||
|
||
export default () => { | ||
return PopupWindow({ | ||
name: "networkmenu", | ||
transition: "crossfade", | ||
child: Widget.Box({ | ||
class_name: "menu-items network", | ||
child: Widget.Box({ | ||
vertical: true, | ||
hexpand: true, | ||
class_name: "menu-items-container network", | ||
children: [ | ||
// Ethernet(), | ||
Wifi(), | ||
], | ||
}), | ||
}), | ||
}); | ||
}; |
105 changes: 105 additions & 0 deletions
105
cells/common/packages/_aags-config/widget/networkmenu/wifi/APStaging.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,105 @@ | ||
import { Network } from "types/service/network"; | ||
import { Variable } from "types/variable"; | ||
import { AccessPoint } from "lib/types/network"; | ||
const renderWapStaging = ( | ||
self: any, | ||
network: Network, | ||
staging: Variable<AccessPoint>, | ||
connecting: Variable<string>, | ||
) => { | ||
Utils.merge([network.bind("wifi"), staging.bind("value")], () => { | ||
if (!Object.keys(staging.value).length) { | ||
return (self.child = Widget.Box()); | ||
} | ||
|
||
return (self.child = Widget.Box({ | ||
class_name: "network-element-item staging", | ||
vertical: true, | ||
children: [ | ||
Widget.Box({ | ||
hpack: "fill", | ||
hexpand: true, | ||
children: [ | ||
Widget.Icon({ | ||
class_name: `network-icon wifi`, | ||
icon: `${staging.value.iconName}`, | ||
}), | ||
Widget.Box({ | ||
class_name: "connection-container", | ||
hexpand: true, | ||
vertical: true, | ||
children: [ | ||
Widget.Label({ | ||
class_name: "active-connection", | ||
hpack: "start", | ||
truncate: "end", | ||
wrap: true, | ||
label: staging.value.ssid, | ||
}), | ||
], | ||
}), | ||
Widget.Revealer({ | ||
hpack: "end", | ||
reveal_child: connecting | ||
.bind("value") | ||
.as((c) => staging.value.bssid === c), | ||
child: Widget.Spinner({ | ||
class_name: "spinner wap", | ||
}), | ||
}), | ||
], | ||
}), | ||
Widget.Box({ | ||
class_name: "network-password-input-container", | ||
hpack: "fill", | ||
hexpand: true, | ||
children: [ | ||
Widget.Entry({ | ||
hpack: "start", | ||
hexpand: true, | ||
visibility: false, | ||
class_name: "network-password-input", | ||
placeholder_text: "enter password", | ||
onAccept: (selfInp) => { | ||
connecting.value = staging.value.bssid || ""; | ||
Utils.execAsync( | ||
`nmcli dev wifi connect ${staging.value.bssid} password ${selfInp.text}`, | ||
) | ||
.catch((err) => { | ||
connecting.value = ""; | ||
console.error( | ||
`Failed to connect to wifi: ${staging.value.ssid}... ${err}`, | ||
); | ||
Utils.notify({ | ||
summary: "Network", | ||
body: err, | ||
timeout: 5000, | ||
}); | ||
}) | ||
.then(() => { | ||
connecting.value = ""; | ||
staging.value = {} as AccessPoint; | ||
}); | ||
selfInp.text = ""; | ||
}, | ||
}), | ||
Widget.Button({ | ||
hpack: "end", | ||
class_name: "close-network-password-input-button", | ||
on_primary_click: () => { | ||
connecting.value = ""; | ||
staging.value = {} as AccessPoint; | ||
}, | ||
child: Widget.Icon({ | ||
class_name: "close-network-password-input-icon", | ||
icon: "window-close-symbolic", | ||
}), | ||
}), | ||
], | ||
}), | ||
], | ||
})); | ||
}); | ||
}; | ||
|
||
export { renderWapStaging }; |
Oops, something went wrong.