Added the ability to change bar locations. (#257)

* Added the ability to change bar locations.

* Update dropdown margins

* Make dropdown to bar gap configurable and organized code.
This commit is contained in:
Jas Singh
2024-09-14 23:29:00 -07:00
committed by GitHub
parent 4238a5516e
commit 8c2537b917
21 changed files with 420 additions and 367 deletions

View File

@@ -36,6 +36,7 @@ import { Attribute, Child } from 'lib/types/widget.js';
import Window from 'types/widgets/window.js';
const { layouts } = options.bar;
const { location } = options.theme.bar;
export type BarWidget = keyof typeof widget;
@@ -252,7 +253,7 @@ export const Bar = (() => {
class_name: 'bar',
monitor,
visible: true,
anchor: ['top', 'left', 'right'],
anchor: location.bind('value').as((ln) => [ln, 'left', 'right']),
exclusivity: 'exclusive',
layer: Utils.merge(
[options.theme.bar.layer.bind('value'), options.tear.bind('value')],