mirror of
https://github.com/xsghetti/HyprCrux.git
synced 2025-07-01 21:10:38 -04:00
17 lines
No EOL
666 B
JavaScript
17 lines
No EOL
666 B
JavaScript
import Widget from 'resource:///com/github/Aylur/ags/widget.js';
|
|
import { enableClickthrough } from "../.widgetutils/clickthrough.js";
|
|
import { RoundedCorner } from "../.commonwidgets/cairo_roundedcorner.js";
|
|
|
|
export default (monitor = 0, where = 'bottom left') => {
|
|
const positionString = where.replace(/\s/, ""); // remove space
|
|
return Widget.Window({
|
|
monitor,
|
|
name: `corner${positionString}${monitor}`,
|
|
layer: 'overlay',
|
|
anchor: where.split(' '),
|
|
exclusivity: 'ignore',
|
|
visible: true,
|
|
child: RoundedCorner(positionString, { className: 'corner-black', }),
|
|
setup: enableClickthrough,
|
|
});
|
|
} |