fix: Skip clipboard copy for whitespace-only selections
This commit is contained in:
@@ -2032,7 +2032,7 @@ class StrixTUIApp(App): # type: ignore[misc]
|
|||||||
if self.screen.selections:
|
if self.screen.selections:
|
||||||
selected = self.screen.get_selected_text()
|
selected = self.screen.get_selected_text()
|
||||||
self.screen.clear_selection()
|
self.screen.clear_selection()
|
||||||
if selected:
|
if selected and selected.strip():
|
||||||
cleaned = self._clean_copied_text(selected)
|
cleaned = self._clean_copied_text(selected)
|
||||||
self.copy_to_clipboard(cleaned if cleaned.strip() else selected)
|
self.copy_to_clipboard(cleaned if cleaned.strip() else selected)
|
||||||
copied = True
|
copied = True
|
||||||
|
|||||||
Reference in New Issue
Block a user