mirror of
https://github.com/zed-industries/zed.git
synced 2024-09-20 02:47:34 +03:00
search: Remove newlines from query used for tab_content. (#3976)
Fixes https://github.com/zed-industries/community/issues/2388 Release Notes: - Fixed tab content of project search overflowing the tab for queries with newlines.
This commit is contained in:
parent
f0ef63bfa0
commit
d374953180
@ -424,7 +424,8 @@ impl Item for ProjectSearchView {
|
|||||||
.current()
|
.current()
|
||||||
.as_ref()
|
.as_ref()
|
||||||
.map(|query| {
|
.map(|query| {
|
||||||
let query_text = util::truncate_and_trailoff(query, MAX_TAB_TITLE_LEN);
|
let query = query.replace('\n', "");
|
||||||
|
let query_text = util::truncate_and_trailoff(&query, MAX_TAB_TITLE_LEN);
|
||||||
query_text.into()
|
query_text.into()
|
||||||
});
|
});
|
||||||
let tab_name = last_query
|
let tab_name = last_query
|
||||||
|
Loading…
Reference in New Issue
Block a user