Fix NerdFont icon alignments. (#143)

* WIP

* Fix nerdfont icon alignments

* Ship needed fonts

* Remove italicised fonts

* Update readme and separate OSD settings into their own category.

* Dashboard styling updates

---------

Co-authored-by: matavach <erik@matijevich.org>
This commit is contained in:
Jas Singh
2024-08-18 00:32:22 -07:00
committed by GitHub
parent a1beac4c05
commit b200b6fadb
40 changed files with 263 additions and 150 deletions

View File

@@ -6,7 +6,7 @@ import { openMenu } from "../utils.js";
const Bluetooth = () => {
const btIcon = Widget.Label({
label: bluetooth.bind("enabled").as((v) => v ? "󰂯" : "󰂲"),
class_name: "bar-button-icon bluetooth",
class_name: "bar-button-icon bluetooth txt-icon bar",
});
const btText = Widget.Label({

View File

@@ -40,7 +40,7 @@ const Media = () => {
const trackArtist = show_artist.value
? ` - ${track_artists.join(', ')}`
: ``;
const truncatedLabel = truncation.value
const truncatedLabel = truncation.value
? `${track_title + trackArtist}`.substring(0, truncation_size.value)
: `${track_title + trackArtist}`;
@@ -63,7 +63,7 @@ const Media = () => {
child: Widget.Box({
children: [
Widget.Label({
class_name: "bar-button-icon media",
class_name: "bar-button-icon media txt-icon bar",
label: songIcon.bind("value").as(v => v || "󰝚"),
}),
Widget.Label({

View File

@@ -6,7 +6,7 @@ const Menu = () => {
return {
component: Widget.Box({
child: Widget.Label({
class_name: "bar-menu_label",
class_name: "bar-menu_label txt-icon bar",
label: options.bar.launcher.icon.bind("value"),
}),
}),

View File

@@ -18,7 +18,7 @@ export const Notifications = () => {
(notif, dnd, showTotal) => {
const notifIcon = Widget.Label({
hpack: "center",
class_name: "bar-button-icon notifications",
class_name: "bar-button-icon notifications txt-icon bar",
label: dnd ? "󰂛" : notif.length > 0 ? "󱅫" : "󰂚",
});

View File

@@ -3,8 +3,6 @@ const audio = await Service.import("audio");
import { openMenu } from "../utils.js";
import options from "options";
import { globalMousePos } from "globals.js";
const Volume = () => {
const icons = {
101: "󰕾",
@@ -30,7 +28,7 @@ const Volume = () => {
const volIcn = Widget.Label({
vpack: "center",
label: getIcon(),
class_name: "bar-button-icon volume",
class_name: "bar-button-icon volume txt-icon bar",
});
const volPct = Widget.Label({

View File

@@ -31,7 +31,7 @@ const ClientTitle = () => {
component: Widget.Box({
children: [
Widget.Label({
class_name: "bar-button-icon windowtitle",
class_name: "bar-button-icon windowtitle txt-icon bar",
label: hyprland.active.bind("client").as((v) => filterTitle(v).icon),
}),
Widget.Label({

View File

@@ -2,13 +2,13 @@ const hyprland = await Service.import("hyprland");
import { WorkspaceRule, WorkspaceMap } from "lib/types/workspace";
import options from "options";
const {
workspaces,
const {
workspaces,
monitorSpecific,
workspaceMask,
reverse_scroll,
scroll_speed,
spacing
workspaceMask,
reverse_scroll,
scroll_speed,
spacing
} = options.bar.workspaces;
function range(length: number, start = 1) {
@@ -188,7 +188,7 @@ const Workspaces = (monitor = -1, ws = 8) => {
],
(show_icons, show_numbered, numbered_active_indicator) => {
if (show_icons) {
return `workspace-icon`;
return `workspace-icon txt-icon bar`;
}
if (show_numbered) {
const numActiveInd = hyprland.active.workspace.id === i
@@ -270,4 +270,4 @@ const Workspaces = (monitor = -1, ws = 8) => {
}
};
};
export { Workspaces };
export { Workspaces };