From 82e31b6d8d0531b0528d32983c6bdadc311feba1 Mon Sep 17 00:00:00 2001 From: 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> Date: Fri, 31 Jan 2025 14:58:18 +1100 Subject: bar: use nf icons for os icon --- src/utils/system.ts | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'src/utils/system.ts') diff --git a/src/utils/system.ts b/src/utils/system.ts index 31e9cfd..8180e48 100644 --- a/src/utils/system.ts +++ b/src/utils/system.ts @@ -56,13 +56,11 @@ export const notify = (props: { export const osId = GLib.get_os_info("ID") ?? "unknown"; export const osIdLike = GLib.get_os_info("ID_LIKE"); -export const osIcon = String.fromCodePoint( - (() => { - if (osIcons.hasOwnProperty(osId)) return osIcons[osId]; - if (osIdLike) for (const id of osIdLike.split(" ")) if (osIcons.hasOwnProperty(id)) return osIcons[id]; - return 0xf31a; - })() -); +export const osIcon = (() => { + if (osIcons.hasOwnProperty(osId)) return osIcons[osId]; + if (osIdLike) for (const id of osIdLike.split(" ")) if (osIcons.hasOwnProperty(id)) return osIcons[id]; + return ""; +})(); export const currentTime = Variable(GLib.DateTime.new_now_local()).poll(1000, () => GLib.DateTime.new_now_local()); export const bindCurrentTime = (format: string, fallback?: (time: GLib.DateTime) => string) => -- cgit v1.2.3-freya