mirror of
https://github.com/tuxdotrs/tpanel.git
synced 2025-10-10 21:01:54 +05:30
feat: add widget for gpu and cpu profile
This commit is contained in:
11
widgets/bar/gpu.tsx
Normal file
11
widgets/bar/gpu.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
import { bind, Variable } from "astal";
|
||||
|
||||
export const GPU = () => {
|
||||
const gpu = Variable("").poll(5000, ["bash", "-c", "supergfxctl -g"]);
|
||||
|
||||
return (
|
||||
<box cssClasses={["pill"]}>
|
||||
<label label={bind(gpu).as((val) => `GPU: ${val}`)} />
|
||||
</box>
|
||||
);
|
||||
};
|
Reference in New Issue
Block a user