forked from Shinonome/dots-hyprland
focus entry on opening sideleft
This commit is contained in:
@@ -348,7 +348,7 @@ export const booruView = Scrollable({
|
|||||||
// Always scroll to bottom with new content
|
// Always scroll to bottom with new content
|
||||||
const adjustment = scrolledWindow.get_vadjustment();
|
const adjustment = scrolledWindow.get_vadjustment();
|
||||||
adjustment.connect("changed", () => {
|
adjustment.connect("changed", () => {
|
||||||
if(!chatEntry.hasFocus) return;
|
if (!chatEntry.hasFocus) return;
|
||||||
adjustment.set_value(adjustment.get_upper() - adjustment.get_page_size());
|
adjustment.set_value(adjustment.get_upper() - adjustment.get_page_size());
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -75,6 +75,11 @@ export const chatEntry = TextView({
|
|||||||
acceptsTab: false,
|
acceptsTab: false,
|
||||||
className: 'sidebar-chat-entry txt txt-smallie',
|
className: 'sidebar-chat-entry txt txt-smallie',
|
||||||
setup: (self) => self
|
setup: (self) => self
|
||||||
|
.hook(App, (self, currentName, visible) => {
|
||||||
|
if (visible && currentName === 'sideleft') {
|
||||||
|
self.grab_focus();
|
||||||
|
}
|
||||||
|
})
|
||||||
.hook(GPTService, (self) => {
|
.hook(GPTService, (self) => {
|
||||||
if (APIS[currentApiId].name != 'Assistant (GPTs)') return;
|
if (APIS[currentApiId].name != 'Assistant (GPTs)') return;
|
||||||
self.placeholderText = (GPTService.key.length > 0 ? 'Message the model...' : 'Enter API Key...');
|
self.placeholderText = (GPTService.key.length > 0 ? 'Message the model...' : 'Enter API Key...');
|
||||||
|
|||||||
@@ -26,4 +26,3 @@ else
|
|||||||
wf-recorder --pixel-format yuv420p -f './recording_'"$(getdate)"'.mp4' -t --geometry "$(slurp)" & disown
|
wf-recorder --pixel-format yuv420p -f './recording_'"$(getdate)"'.mp4' -t --geometry "$(slurp)" & disown
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user