Files
custum-hyprpanel/modules/shared/barItemBox.ts
Jas Singh 033fbe6947 Made various improvements to the workspaces module. (#17)
* Made workspace scrolling slower and more natural.

* Fix workspace scrolling not working on single monitors: Fixes #8

* Fixed #15 and added configuration options to adjust workspace spacing and scrolling speed.
2024-07-28 01:44:00 -07:00

16 lines
472 B
TypeScript

export const BarItemBox = (child) => {
const computeVisible = () => {
if (Object.hasOwnProperty.call(child, "isVis")) {
return child.isVis.bind("value");
}
return child.isVisible;
};
return Widget.Button({
class_name: `bar_item_box_visible ${Object.hasOwnProperty.call(child, "boxClass") ? child.boxClass : ""}`,
child: child.component,
visible: computeVisible(),
...child.props,
});
};