remove regex keymap, and made spacing consistent between search objects

Co-authored-by: Piotr <piotr@zed.dev>
This commit is contained in:
KCaverly 2023-08-16 12:17:59 +01:00
parent 11ecb7b604
commit 9bf227b884
2 changed files with 6 additions and 14 deletions

View file

@ -64,7 +64,7 @@ pub fn init(cx: &mut AppContext) {
cx.add_action(ProjectSearchBar::cycle_mode);
cx.add_action(ProjectSearchBar::next_history_query);
cx.add_action(ProjectSearchBar::previous_history_query);
cx.add_action(ProjectSearchBar::activate_regex_mode);
// cx.add_action(ProjectSearchBar::activate_regex_mode);
cx.capture_action(ProjectSearchBar::tab);
cx.capture_action(ProjectSearchBar::tab_previous);
add_toggle_option_action::<ToggleCaseSensitive>(SearchOptions::CASE_SENSITIVE, cx);
@ -1498,7 +1498,7 @@ impl View for ProjectSearchBar {
.with_max_width(theme.search.include_exclude_editor.max_width),
)
.contained()
.with_padding_top(3.)
.with_padding_top(theme.workspace.toolbar.container.padding.bottom)
});
let editor_column = Flex::column()
@ -1513,8 +1513,6 @@ impl View for ProjectSearchBar {
.flex(1., false),
)
.with_children(filters)
.contained()
.with_background_color(gpui::color::Color::blue())
.flex(1., false);
let matches = search.active_match_index.map(|match_ix| {
@ -1569,9 +1567,7 @@ impl View for ProjectSearchBar {
.with_child(nav_button_for_direction(">", Direction::Next, cx))
.with_child(Flex::row().with_children(matches))
.constrained()
.with_height(theme.search.search_bar_row_height)
.contained()
.with_background_color(gpui::color::Color::red());
.with_height(theme.search.search_bar_row_height);
let side_column_min_width = 200.;
let mode_column = Flex::row()

View file

@ -102,6 +102,9 @@ export default function search(): any {
right: 10,
// top: 2,
},
margin: {
right: 9,
}
},
state: {
hovered: {}
@ -112,14 +115,7 @@ export default function search(): any {
base: {
...text(theme.highest, "mono", "on"),
background: background(theme.highest, "on"),
corner_radius: 6,
border: border(theme.highest, "on"),
padding: {
// bottom: 2,
left: 10,
right: 10,
// top: 2,
},
},
state: {
hovered: {