Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@aweis89
Copy link
Contributor

@aweis89 aweis89 commented Dec 27, 2025

Summary

  • Removes hardcoded layout preset from snacks picker in base_picker, allowing user-configured presets (ivy/telescope/default/select) to be respected for pickers
  • Previously only the file_picker respected user defaults; this aligns base_picker behavior to match

Fixes

  • The Snacks config func doesn't have an expected return type
  • The title from PickerOption string|fun() is converted to a string? which the Snacks picker exptects
  • When no preview is available, we need to explicitly set the preview to false in Snacks to prevent errors when the global default config has preview enabled

Previously base_picker hardcoded the layout preset to 'default' or 'select'
based on whether preview was enabled. This meant user-configured presets
(ivy/telescope/default/select) were not respected for non-file pickers.

Remove the hardcoded preset to let Snacks use the user's default preference,
matching the behavior of the file picker.
- ensures proper handling when preview is not enabled
@sudo-tee sudo-tee merged commit 8216d30 into sudo-tee:main Dec 29, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants