forked from Shinonome/dots-hyprland
sideleft: booru: fix annoying scroll on tag hover
This commit is contained in:
@@ -19,31 +19,12 @@ const USER_CACHE_DIR = GLib.get_user_cache_dir();
|
|||||||
Utils.exec(`bash -c 'mkdir -p ${USER_CACHE_DIR}/ags/media/waifus'`);
|
Utils.exec(`bash -c 'mkdir -p ${USER_CACHE_DIR}/ags/media/waifus'`);
|
||||||
Utils.exec(`bash -c 'rm ${USER_CACHE_DIR}/ags/media/waifus/*'`);
|
Utils.exec(`bash -c 'rm ${USER_CACHE_DIR}/ags/media/waifus/*'`);
|
||||||
|
|
||||||
const TagButton = (command) => {
|
const TagButton = (command) => Button({
|
||||||
const plusSign = Revealer({
|
className: 'sidebar-chat-chip sidebar-chat-chip-action txt txt-small',
|
||||||
transition: 'slide_right',
|
onClicked: () => { chatEntry.buffer.text += `${command} ` },
|
||||||
revealChild: false,
|
setup: setupCursorHover,
|
||||||
className: 'margin-right-5',
|
label: command,
|
||||||
child: Label({
|
});
|
||||||
label: '+',
|
|
||||||
})
|
|
||||||
});
|
|
||||||
return Button({
|
|
||||||
className: 'sidebar-chat-chip sidebar-chat-chip-action txt txt-small',
|
|
||||||
onClicked: () => { chatEntry.buffer.text += `${command} ` },
|
|
||||||
onHover: () => plusSign.revealChild = true,
|
|
||||||
onHoverLost: () => plusSign.revealChild = false,
|
|
||||||
setup: setupCursorHover,
|
|
||||||
child: Box({
|
|
||||||
children: [
|
|
||||||
plusSign,
|
|
||||||
Label({
|
|
||||||
label: command,
|
|
||||||
}),
|
|
||||||
]
|
|
||||||
})
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
const CommandButton = (command, displayName = command) => Button({
|
const CommandButton = (command, displayName = command) => Button({
|
||||||
className: 'sidebar-chat-chip sidebar-chat-chip-action txt txt-small',
|
className: 'sidebar-chat-chip sidebar-chat-chip-action txt txt-small',
|
||||||
|
|||||||
Reference in New Issue
Block a user