Is there a way to configure a hotkey to toggle this setting? Not sure if something changed recently but it seems that my search results are always expanded by default, which I prefer not to see. A hotkey to collapse them would at least be more convenient than 3 extra clicks every time… (of course even better than that would be if it remembered its previous toggle status)
Thanks @liam - but I am curious whether something changed recently (feels like it did) that is causing the search results to always default to “expanded”.
For now I wrote this ridiculous hack that I fire every 15 minutes on a cron, but seems quite silly
JSON=/path/to/vault/.obsidian/workspace.json
jq 'walk(if type == "object" and has("collapseAll") then .collapseAll = true else . end)' "$JSON" |
sponge "$JSON"
If you think there’s a bug, I suggest filing a separate bug report. Will be easier to offer help since I’m not sure what version of Obsidian you’re on.
If you’re able to reproduce the issue reliably, let me know; I’ll investigate if the setting isn’t being properly saved.
I thought there was an update in the past couple years that allowed you to expand/collapse individual files’ context via the keyboard, i.e. shift+arrowUp/arrowDown, and it’s also my suspicion that we’ve lost this functionality. Currently there seems to be no way to expand/collapse search results using the keyboard. I’m happy to file a bug report, unless I’m mistaken and this functionality never existed?
Anecdotally, I can also say a few minutes ago I was able to key down to a result and simply hit the leftArrow key and it collapsed, and then I reloaded the app and the left/right arrow keys are not doing anything again.