Commit Graph

12558 Commits

Author SHA1 Message Date
Nathan Sobo
4e9fb26102
Adjust terminal and popover colors to better match original styling (#3816)
This may have made something else worse, but overall brings us more into
harmony.

Release Notes:

- N/A
2023-12-29 08:44:26 -07:00
Kirill Bulatov
ce8cc50ae5 Remove async_trait from the only trait that allows it now 2023-12-28 23:45:30 +02:00
Piotr Osiewicz
e932f4cf47
Bump Rust to 1.75 (#3815)
**This PR also bumps wasmtime version from 0.38 to 2.0 as 0.38 does not
build with Rust 1.75**. I did not test the plugin runtime as (AFAIK) we
intend to deprecate it; also, wasmtime's most recent version is 16.0, so
it'd make sense to bump the version at some point anyways. I did not
bump the version to 16.0 straight away as that'd require code changes in
`plugin_runtime`.
Release Notes:

- N/A
2023-12-28 19:22:43 +01:00
Nathan Sobo
02f7e681a7 Import elevated surface color from hover popover 2023-12-27 11:58:26 -07:00
Nathan Sobo
a2b0f14dc1 Rename size to dimensions for consistency 2023-12-27 11:23:12 -07:00
Nathan Sobo
ddd6f0806b Render cursor text with the terminal's background color 2023-12-27 11:08:43 -07:00
Nathan Sobo
5cfd4b06b9 Use correct terminal background color 2023-12-27 10:46:25 -07:00
Kirill Bulatov
937f237c8f Add breadcrumbs to the multibuffer editor
The breadcrumbs are not being open on the fisrt time, for some reason.
2023-12-26 15:18:20 +02:00
Kirill Bulatov
f27c63bb54 Fix color-related terminal todo! 2023-12-26 14:11:51 +02:00
Kirill Bulatov
af6f467890 Avoid trailing separators in file finder 2023-12-26 13:49:00 +02:00
Piotr Osiewicz
16626592db
Remove allow unused from gpui2, vim2 tests and terminal_view2 (#3813)
Release Notes:

- N/A
2023-12-26 01:23:08 +01:00
Joseph T. Lyons
41fb29bc5a
Tidy up main (#3812)
Release Notes:

- N/A
2023-12-25 07:45:39 -05:00
Piotr Osiewicz
ee57658abe Fix up superfluous mod declaration 2023-12-25 13:30:27 +01:00
Joseph T. Lyons
12fe64b177 Fix more warnings 2023-12-25 07:02:19 -05:00
Piotr Osiewicz
904358263c
Remove #[allow(unused)] annotations in zed2 crates (#3798)
Release Notes:

- N/A
2023-12-25 12:23:44 +01:00
Joseph T. Lyons
8f3ea6ccb3 Remove silencing of warnings and fix warnings 2023-12-25 03:47:28 -05:00
Joseph T. Lyons
ada1da48ca Remove already-implemented comment 2023-12-25 03:47:03 -05:00
Joseph T. Lyons
88d05fd814 Wire up journal 2023-12-25 03:36:54 -05:00
Joseph T. Lyons
81ed861288 Migrate from device_id to installation_id key 2023-12-23 22:26:00 -05:00
Joseph T. Lyons
bab3b231b8
Remove telemetry debounce time in zed 2 (#3809)
Remove the event send timer in Zed 2 telemetry in effort to continue
reducing the amount of stress the vercel endpoint receives. This allows
the queues to fill up entirely before sending them off. I'm leaving the
timer in for Zed 1 because we don't force the events queue to clear on
app close in Zed 1, so it feels best to leave it in there, as it might
catch some unsent events before closing.

Release Notes:

- N/A
2023-12-23 17:39:36 -05:00
Joseph T. Lyons
58c5720c32 Remove telemetry debounce time in zed 2 2023-12-23 17:25:04 -05:00
Kirill Bulatov
1096eeff3a Add a horizontal separator between history and query file finder matches 2023-12-23 22:33:52 +02:00
Kirill Bulatov
a249375f99 Do not show nav history buttons in terminal pane 2023-12-23 22:10:11 +02:00
Kirill Bulatov
e839dc5ee6 Hide pane tab bar for 0 items, hide its end buttons for no focus 2023-12-23 21:53:08 +02:00
Marshall Bowers
698460ea89
Style inlay hints (#3806)
This PR styles the inlay hints after the changes to the themes.

Release Notes:

- N/A
2023-12-22 23:06:30 -05:00
Marshall Bowers
e5148b4a1b
Assign player colors from the theme (#3805)
This PR updates the `theme_importer` to pull in the player colors so
that we can assign them based on the current theme.

Release Notes:

- N/A
2023-12-22 22:28:41 -05:00
Marshall Bowers
5a910aa874
Refine ported Zed1 themes (#3804)
This PR applies another round of refinements to the ported Zed1 themes.

Most of this was focused around the coloration of UI text to better
match Zed1.

Release Notes:

- N/A
2023-12-22 21:49:27 -05:00
Marshall Bowers
14ed4a4316 Render project panel entries as muted, unless selected 2023-12-22 21:36:20 -05:00
Marshall Bowers
446c947ad1 Render breadcrumb using muted colors 2023-12-22 21:33:57 -05:00
Marshall Bowers
04d26353d2 Adjust muted text colors 2023-12-22 21:25:45 -05:00
Marshall Bowers
bdb89d4700 Render tab bar tools as muted 2023-12-22 21:25:31 -05:00
Marshall Bowers
9cb613245e Adjust border colors 2023-12-22 21:18:43 -05:00
Marshall Bowers
e8a14b1971 Adjust color used for text 2023-12-22 21:10:53 -05:00
Joseph T. Lyons
b1870af386 Add project open event
Give the caller of report_app_event() the choice of whether to immediately flush the queue or not.
2023-12-22 20:23:55 -05:00
Joseph T. Lyons
1989094e6d Increase queue flush debounce time 2023-12-22 19:57:13 -05:00
Joseph T. Lyons
0746a10d9b Increase telemetry queue size 2023-12-22 19:56:06 -05:00
Max Brunsfeld
2edf560e5c
Maintain workspace's zoom state when opening/closing docks, activating panels (#3801)
Fixes an issue where zoom didn't work when closing and re-opening a
zoomed panel.
2023-12-22 16:54:13 -08:00
Max Brunsfeld
d7b0662058 Maintain workspace's zoom state when opening/closing docks, activating panels 2023-12-22 16:45:44 -08:00
Marshall Bowers
0e145a8435
Make current call controls in title bar smaller (#3800)
This PR adjusts the sizes of the current call controls in the title bar
to be smaller.

This matches the size of the other title bar items that are always
present.

Release Notes:

- N/A
2023-12-22 19:32:07 -05:00
Kirill Bulatov
a1915ce6c4 Add spacing to terminal tab bar buttons 2023-12-23 02:29:33 +02:00
Marshall Bowers
f03ee1ea24
Add spacing between tab bar buttons (#3799)
This PR adds spacing between buttons in the tab bar.

Release Notes:

- N/A
2023-12-22 19:18:04 -05:00
Kirill Bulatov
e1d8e2001b
Properly color file labels in project panel (#3794)
Also fixes an error with mouse listeners placement in
https://github.com/zed-industries/zed/pull/3792

Release Notes:

- N/A
2023-12-23 02:01:55 +02:00
Marshall Bowers
3213a860a6
Use extra small label for tab descriptions (#3797)
This PR adjusts the size of the tab descriptions to use the extra small
label size.

This makes it easier to distinguish between the filename and the
description:

<img width="320" alt="Screenshot 2023-12-22 at 6 49 11 PM"
src="https://github.com/zed-industries/zed/assets/1486634/451d4cd0-666c-43c2-b5df-6d9cf91dacda">

It's also more in line with how things look in Zed1.

Release Notes:

- N/A
2023-12-22 18:56:17 -05:00
Kirill Bulatov
c6f3f439c4 Fix mouse listeners' z-index for editor 2023-12-23 01:55:40 +02:00
Piotr Osiewicz
ca7e504817
titlebar: show "Share project" button only in local projects. (#3795)
Fixes '"Share" button is shown even for remote projects'.

Release Notes:

- N/A
2023-12-23 00:49:51 +01:00
Marshall Bowers
1ebfafc03d
Map additional text colors from Zed1 themes (#3796)
This PR maps additional text colors from the Zed1 themes to the Zed2
themes.

Release Notes:

- N/A
2023-12-22 18:45:58 -05:00
Kirill Bulatov
9600337d81 Properly color file labels in project panel 2023-12-23 01:27:41 +02:00
Marshall Bowers
b501f4eafc
Begin porting Zed1 themes to Zed2 (#3793)
This PR is a first pass at porting the Zed1 themes to Zed2.

For the initial release of Zed2 we'll be shipping just the themes that
existed in Zed1, ported to Zed2. The new themes that were previously
added just in Zed2 have been removed.

Release Notes:

- N/A
2023-12-22 17:37:53 -05:00
Kirill Bulatov
764a2755e2 Fix multibuffer scroll by reordering z-index of its elements
1. Blocks (with their headers) and mouse listeners should be drawn together otherwise either starts to loose mouse events.

2. Scrollbar should be above all to match zed1 look and avoid buffer headers popping slightly to the right of the scrollbar.
2023-12-22 22:56:35 +02:00
Marshall Bowers
dc64411cca
Extend theme_importer in preparation for importing Zed1 themes (#3791)
This PR extends the `theme_importer` with the overall structure required
to support importing themes from Zed1.

Release Notes:

- N/A
2023-12-22 13:47:30 -05:00
Antonio Scandurra
c34a81152f
Fix panic when deploying emoji picker (character palette) (#3790)
The panic was caused by Cocoa synchronously invoking the
`selected_text_range` method on the registered input handler while we
already had a borrow of the app.

This pull request fixes this issue by showing the character palette on
the next tick of the loop (we've had this problem in other spots too and
used the same technique).

Release Notes:

- N/A
2023-12-22 18:52:35 +01:00
Marshall Bowers
7ef2ddd7a5
Disambiguate GPUI2 macOS class names (#3789)
This PR disambiguates the macOS class names used in GPUI2 from the ones
used in GPUI1.

Right now if you happen to end up with a copy of both `gpui` and `gpui2`
in the dependency tree you get an unhelpful `unwrap` error when we try
to build the class names.

By giving them different names we are able to get to our more helpful
error that informs you that both GPUI1 and GPUI2 are in the module tree.

We can change these names back once we do the big "un-2-ing".

Release Notes:

- N/A
2023-12-22 12:46:06 -05:00
Antonio Scandurra
9a6688bdfb Fix panic when deploying emoji picker (character palette)
The panic was caused by Cocoa synchronously invoking the `selected_text_range`
method on the registered input handler while we already had a borrow of the
app.

This commit fixes this issue by showing the character palette on the next tick
of the loop (we've had this problem in other spots too and used the same technique).
2023-12-22 18:41:43 +01:00
Antonio Scandurra
30340535e9
Prevent panels from getting so small they can't be resized (#3788)
This also switches to using `Pixels` instead of `f32` to store the panel
size everywhere.

Release Notes:

- N/A
2023-12-22 18:37:13 +01:00
Antonio Scandurra
961d8331f3 Prevent panels from getting so small they can't be resized 2023-12-22 18:28:28 +01:00
Antonio Scandurra
3715ddfa74 Use Pixels instead of f32 for panel size 2023-12-22 18:26:33 +01:00
Piotr Osiewicz
25a5eda76f
picker: Reintroduce headers and footers (#3786)
Update VCS menu to match Zed1.
<img width="444" alt="image"
src="https://github.com/zed-industries/zed/assets/24362066/6cb27510-f501-46bc-862f-1fb78006b77c">

Release Notes:

- N/A
2023-12-22 18:10:59 +01:00
Antonio Scandurra
87ff5f04cb
Fix resizing for bottom dock (#3787)
We were not using `flex` on the `PaneGroup`, which caused the bottom
dock to be unable to satisfy the desired resize value.

Release Notes:

- N/A
2023-12-22 18:10:50 +01:00
Antonio Scandurra
54e45306c5 Fix resizing for bottom dock
We were not using `flex` on the `PaneGroup`, which caused the bottom
dock to be unable to satisfy the desired resize value.
2023-12-22 18:00:03 +01:00
Kirill Bulatov
f3ab5ce34b
Fix enter, tab and shift-tab behavior in project search 2 (#3785) 2023-12-22 18:56:18 +02:00
Kirill Bulatov
2f4cedbd53 Remove the old code 2023-12-22 18:43:57 +02:00
Kirill Bulatov
a03306fd01 Fix enter, tab and shift-tab behavior in project search 2 2023-12-22 18:43:02 +02:00
Piotr Osiewicz
dc1ed3c39d
Titlebar project menu double click (#3784)
This addresses a bug where popover menus in the titlebar were rendered
only after a 2nd click. The first click was creating the View which the
second one then rendered.
In addition to this, `PopoverMenu::menu` function argument can now
return an `Option<View<T>>` instead of `View<T>` as the creation of the
menu can fail (as it might in case of git popover).

Release Notes:

- N/A
2023-12-22 17:18:12 +01:00
Kirill Bulatov
5de32f7b0b Do not display a getting start message when the project is open 2023-12-22 18:06:23 +02:00
Antonio Scandurra
dd093477a3 Allow horizontal scrolling of tab bar on vertical mouse wheel
Now, if we receive a scroll event for an axis, but that axis can't be scrolled
(overflow != scroll), we will apply it to the opposite axis instead
if that axis supports scrolling.
2023-12-22 15:56:37 +01:00
Antonio Scandurra
2f3b408880 Dismiss mention notification when x icon is clicked
We were emitting the wrong kind of event, which caused the workspace
to never remove the notification.
2023-12-22 15:12:01 +01:00
Antonio Scandurra
bb93144b8a
Reveal item even if project panel was closed while active entry changed (#3781)
The project panel was actually working just fine, the problem was due to
`UniformList` not re-hydrating the element state's scroll offset when
being rendered again.

Release Notes:

- N/A
2023-12-22 14:55:38 +01:00
Antonio Scandurra
68cf631cfc Reveal item even if project panel was closed while active entry changed
The project panel was actually working just fine, the problem was due to
`UniformList` not re-hydrating the element state's scroll offset when
being rendered again.
2023-12-22 14:39:16 +01:00
Kirill Bulatov
420253a752 Restore zoom buttons in pane tab bars, fix + button in the terminal one 2023-12-22 15:32:47 +02:00
Antonio Scandurra
061bcf1b6e
Fix dismissing context menu when clicking on an item dispatched action (#3779)
Release Notes:

- N/A
2023-12-22 12:34:08 +01:00
Antonio Scandurra
62aea418de
Fix panic in completions menu (#3778)
We were shifting all the positions while keeping the original string,
which caused problems later when combining highlighted ranges with
matched indices.

Release Notes:

- N/A
2023-12-22 12:27:52 +01:00
Antonio Scandurra
c1ad079f09 Fix dismissing context menu when clicking on an item dispatched action 2023-12-22 12:27:20 +01:00
Antonio Scandurra
a551647ec1 Fix panic in completions menu
We were shifting all the positions while keeping the original
string, which caused problems later when combining highlighted
ranges with matched indices.
2023-12-22 12:12:39 +01:00
Kirill Bulatov
e3eafdba59
Move multibuffer "go to file" button into the buffer header (#3777)
Release Notes:

- N/A
2023-12-22 12:24:51 +02:00
Kirill Bulatov
4d5ff77abe Fix the tests 2023-12-22 12:14:53 +02:00
Joseph T. Lyons
169266b006
Slow down sampling metric collection rate (#3775)
Release Notes:

- N/A
2023-12-22 05:03:38 -05:00
Kirill Bulatov
d36ec81725 Move multibuffer "go to file" button into the buffer header
Co-Authored-By: Antonio Scandurra <antonio@zed.dev>
2023-12-22 12:02:44 +02:00
Kirill Bulatov
fce31b7ddf Remove the warnings from element.rs 2023-12-22 12:02:44 +02:00
Joseph T. Lyons
41ff37d56e Slow down sampling metric collection rate 2023-12-22 04:52:36 -05:00
Antonio Scandurra
854907d721
Fix context menu in tab bar (#3776)
Release Notes:

- N/A
2023-12-22 10:35:05 +01:00
Antonio Scandurra
3de72f8366 Fix context menu in tab bar 2023-12-22 10:23:27 +01:00
Kirill Bulatov
6c4670287d Highlight termina on external files drag and drop 2023-12-22 10:45:51 +02:00
Antonio Scandurra
01ce204491 Avoid painting a background quad if it is fully transparent 2023-12-22 09:29:56 +01:00
Antonio Scandurra
2a516ec1e0 Honor PrimitiveKind ordering when order is the same
This was a bug in the previous implementation that was being masked by
how we were using BSP.
2023-12-22 09:24:01 +01:00
Antonio Scandurra
48ad53badd Revert "Revert "Optimize order rendering and border drawing"" 2023-12-22 09:12:18 +01:00
Marshall Bowers
2659b2744a
Add vertical padding to the picker empty state (#3774)
This PR adds vertical padding to the picker's empty state.

This matches the styles added in #3769.

Release Notes:

- N/A
2023-12-21 23:41:24 -05:00
Marshall Bowers
248458cef5
Indent contacts in collab panel (#3773)
This PR indents contacts in the collab panel.

Release Notes:

- N/A
2023-12-21 23:35:50 -05:00
Marshall Bowers
cd9156886f
Increase the indent step size for the collab panel (#3772)
This PR increases the indent step size for the collab panel.

This gives the channel list a clearer hierarchy for nested channels, as
well as help align the disclosures with the parent channel's icon.

Release Notes:

- N/A
2023-12-21 23:22:22 -05:00
Marshall Bowers
80143b2571
Fix names for Rosé Pine themes (#3771)
This PR fixes the names of the Rosé Pine themes.

We want to keep the Unicode "é" in the theme name, both because this is
the actual name of the theme, and also to maintain parity with Zed1.

Release Notes:

- N/A
2023-12-21 22:45:29 -05:00
Marshall Bowers
94e22ae515
Fix typo in "Noctis Hibernus" theme name (#3770)
This PR fixes a typo in the name of the "Noctis Hibernus" theme.

Release Notes:

- N/A
2023-12-21 22:36:40 -05:00
Marshall Bowers
4fb12cb348
Add vertical padding to the picker entry list (#3769)
This PR adds vertical padding to the list of picker entries.

This prevents us from ending up with entries squished against the edges
of the picker.

Release Notes:

- N/A
2023-12-21 22:36:15 -05:00
Marshall Bowers
5307b75b2f
Add more left padding to title bar (#3768)
This PR adds more left padding to the title bar to achieve the same
positioning of the title bar items that we have in Zed1.

Release Notes:

- N/A
2023-12-21 22:29:30 -05:00
Julia
051bad734e
Some terminal bugs (#3767)
Fixes:
 - drag and drop into terminal element does not change its style
 - drag and drop terminal tab into main pane then back panics
 - can drop non-terminal items into the terminal pane

Release Notes:

- N/A
2023-12-21 18:05:14 -05:00
Julia
f3fda8018f Prevent drag-dropping non-terminal item into terminal pane 2023-12-21 17:52:29 -05:00
Marshall Bowers
3d1e52297e
Scale down status bar items (#3766)
This PR scales down the sizes of items in the status bar.

This brings us more in line with Zed1.

Release Notes:

- N/A
2023-12-21 17:42:54 -05:00
Marshall Bowers
e2c36633ea
Align Picker editor with entries (#3765)
This PR re-aligns the `Picker` editor with the entries after the changes
in #3764.

Release Notes:

- N/A
2023-12-21 17:03:57 -05:00
Marshall Bowers
71a222abcb Use sparse spacing for ListItems in Pickers 2023-12-21 16:33:41 -05:00
Marshall Bowers
dc09dbc98c Use a ListItem as the empty state for Pickers 2023-12-21 16:17:04 -05:00
Marshall Bowers
a773a3cb92 Increase horizontal padding for inset ListItems 2023-12-21 16:07:55 -05:00
Marshall Bowers
dabc98690c
Use small labels for title bar buttons (#3763)
This PR adjusts the sizing of the labels in the buttons in the title bar
to use the small label size.

This should bring them more in line with how things looked in Zed1.

Release Notes:

- N/A
2023-12-21 15:48:37 -05:00
Antonio Scandurra
7cfea09019
Revert "Optimize order rendering and border drawing" 2023-12-21 19:40:03 +01:00
Julia
9efe5a30aa Fix pane drag target not appearing over terminal element 2023-12-21 13:08:48 -05:00
Julia
31e47f9b52 Prevent panic dragging tab into terminal panel 2023-12-21 12:56:30 -05:00
Antonio Scandurra
cbb2219c4a
Optimize order rendering and border drawing (#3759)
This fixes the slowdowns we were observing when opening the saved
assistant conversations.

Release Notes:

- N/A
2023-12-21 18:19:39 +01:00
Marshall Bowers
824b68788f
Improve chat panel styling (#3758)
This PR improves the chat panel styling, especially with regards to the
spacing.

Release Notes:

- N/A
2023-12-21 12:15:11 -05:00
Antonio Scandurra
53a4b711dd Delete stray comment 2023-12-21 17:55:26 +01:00
Antonio Scandurra
c03c0d50d5 Use smaller quads to draw borders
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2023-12-21 17:54:13 +01:00
Antonio Scandurra
67f76468f1 Replace BspSplitter with brute-force sorting of primitives 2023-12-21 16:58:36 +01:00
Marshall Bowers
7a9c4057a7
Increase inline assistant editor's line height (#3757)
This PR increases the line height for the inline assistant editor.

This fixes an issue where descenders were being clipped.

Release Notes:

- N/A
2023-12-21 10:56:52 -05:00
Antonio Scandurra
a516c3be05
Allow scrolling of saved conversations (#3756)
Release Notes:

- N/A
2023-12-21 15:42:38 +01:00
Antonio Scandurra
01947ed730 Use existing AnyElement::draw 2023-12-21 15:32:05 +01:00
Antonio Scandurra
5e4557ed16 Fix warnings 2023-12-21 15:27:08 +01:00
Antonio Scandurra
176a022b10 Correctly clamp scroll offset vertically 2023-12-21 15:23:16 +01:00
Antonio Scandurra
e2a4474200 Allow scrolling saved conversations 2023-12-21 15:22:49 +01:00
Joseph T. Lyons
73b527ec8f Store email address on modal close 2023-12-21 09:04:54 -05:00
Antonio Scandurra
f83d156d7b
Fix clicking on "+" button not working when a tab was underneath (#3755)
We were mistakenly pushing an opaque layer without intersecting it with
the content mask. Also, we were pushing two opaque layers for the same
div unnecessarily.

Release Notes:

- N/A
2023-12-21 14:57:52 +01:00
Antonio Scandurra
b0ee7b2fb9 Fix clicking on "+" button not working when a tab was underneath
We were mistakenly pushing an opaque layer without intersecting it
with the content mask. Also, we were pushing two opaque layers for
the same div unnecessarily.
2023-12-21 14:28:06 +01:00
Kirill Bulatov
8dc691fd6f
Fix Zed2 cli actions: opening notes and joining calls (#3754)
Release Notes:

- N/A
2023-12-21 14:34:14 +02:00
Kirill Bulatov
b14c07ca54 Fix Zed cli actions: opening notes and joining calls 2023-12-21 14:27:13 +02:00
Antonio Scandurra
b38a09526c Fix stale scroll position in tab bar 2023-12-21 10:03:15 +01:00
Antonio Scandurra
c7933a6ad8 Remove stray dbg 2023-12-21 09:44:54 +01:00
Antonio Scandurra
73682daf38 Provide mut access to allocated arena struct via non-cloneable ArenaBox
This commit also allows turning an `ArenaBox` into an `ArenaRef` when
non-mutable access is required, which makes `ArenaRef: Clone`. This fixes
a bug that prevented the command palette from reading all the available
actions while the `command_palette::Toggle` action was being dispatched.
2023-12-21 09:41:48 +01:00
Joseph T. Lyons
036636ee80 Fix layout issues with feedback modal
The feedback modal still needs a styling update
2023-12-20 23:54:50 -05:00
Nathan Sobo
e5ce5e8692
Clear pending keystrokes when an action is dispatched (#3750)
This prevents the `cmd-k` keystroke, which clears the terminal, from
staying around as a pending keystroke on the parent workspace.

Release Notes:

- N/A
2023-12-20 20:50:59 -07:00
Nathan Sobo
4680aad885
Correctly compute placeholder text for buffer search query editor (#3749)
Rather than relying on the focused element, instead explicitly pass the
focus handle for the query editor when determining the prev/next
bindings. Only compute these values once.

Release Notes:

- N/A
2023-12-20 20:48:31 -07:00
Nathan Sobo
5747c9b7a1 Clear pending keystrokes when an action is dispatched 2023-12-20 20:41:36 -07:00
Nathan Sobo
c56e7cd124 Remove unused import 2023-12-20 19:53:57 -07:00
Nathan Sobo
4f6bef5b63
Improve interaction between clicking and dragging (#3737)
Once a drag starts, we won't fire click listeners or style any elements
as active.

- Don't fire click listeners or show active state once a drag is in
progress
- Don't show hover style when a drag is in progress
- Draw borders above content
- If borders are opaque, apply them to the content mask. This prevents
hovers from firing on content underneath the border, which was creating
issues where the drag handle was inside the border, so we'd flicker the
hover when the mouse moved out of the drag handle and into the 1px
border on the left dock.
- Add a `block_mouse` helper which causes transparent elements to paint
an "opaque" layer to prevent mouse events from falling through. We use
this for the drag handle as well to disable hover, click, etc on items
in the panel.

Release Notes:

- N/A
2023-12-20 19:31:06 -07:00
Max Brunsfeld
afbc655100
Ensure that views' on_release callbacks are always called (#3747)
* Ensure that views' on_release callbacks are always called (even if
their window is gone), by passing them a `AppContext`, not a
`WindowContext`.
* Fix leaked handles to `CollabPanel`, `NotificationPanel`, and
`ChatPanel` caused by captures in a `ListState` render callback.

This fixes two issues we were seeing with following:
* inability to rejoin a remote project after you closed it
* following not working if a window had previously been closed
2023-12-20 16:45:37 -08:00
Max Brunsfeld
24970c1da9 Fix view handle leaks in ListState callbacks 2023-12-20 16:33:10 -08:00
Kirill Bulatov
2f56fe9129 For file finder queries, search in all gitignored worktree entries 2023-12-21 02:21:27 +02:00
Max Brunsfeld
42bdc11112 Prune dead workspaces from WorkspaceStore on read
Also, remove unnecessary window handle from Workspace.
2023-12-20 16:08:58 -08:00
Max Brunsfeld
5e7c74c7b6 Ensure that on_release callbacks are called even if view outlives its window 2023-12-20 16:01:52 -08:00
Marshall Bowers
d61cac6160
Add ToggleButton for use in buffer search (#3746)
This PR adds a new `ToggleButton` component:

<img width="738" alt="Screenshot 2023-12-20 at 6 50 13 PM"
src="https://github.com/zed-industries/zed/assets/1486634/9c5fb45b-0b55-4008-9336-b651a26a99ad">

We're using `ToggleButton`s for the search mode selection in the buffer
search:

<img width="842" alt="Screenshot 2023-12-20 at 6 47 57 PM"
src="https://github.com/zed-industries/zed/assets/1486634/178a278f-172c-4c67-8572-83d59de2ed14">

Release Notes:

- N/A
2023-12-20 19:00:04 -05:00
Marshall Bowers
11807bb82d Add large variant for buttons 2023-12-20 18:47:22 -05:00
Marshall Bowers
93c8bee747 Use ToggleButtons for search mode in buffer search 2023-12-20 18:32:12 -05:00
Marshall Bowers
443b1dd345 Add ToggleButton component 2023-12-20 18:23:21 -05:00
Kirill Bulatov
2cd7d2db46 Remove nightly from zed1 and use proper namespaces for nightly in zed2 manifest 2023-12-21 01:18:00 +02:00
Kirill Bulatov
72c8beae30 Restore "reveal in project panel" and "search in directory" context menu actions 2023-12-21 01:07:05 +02:00
Marshall Bowers
e5e8e8882f Inline toggle replace button 2023-12-20 17:34:08 -05:00
Marshall Bowers
2ac472e0e0 Inline buttons 2023-12-20 17:31:36 -05:00
Marshall Bowers
8a8b498ee1 Style replace input 2023-12-20 17:25:38 -05:00
Marshall Bowers
b493d8f6c0 Improve spacing of items in buffer search bar 2023-12-20 17:10:27 -05:00
Marshall Bowers
b9bc74abe5 Increase toolbar padding 2023-12-20 17:03:44 -05:00
Marshall Bowers
53b608378c Don't apply the gap when we don't have any items in the first row 2023-12-20 17:02:15 -05:00
Nathan Sobo
87ae21feb3 Merge remote-tracking branch 'origin/main' into cancel-clicks-on-drag 2023-12-20 15:01:10 -07:00
Nathan Sobo
d499cccebb Only compute placeholder text once 2023-12-20 14:47:56 -07:00
Marshall Bowers
7b51f73826 Tighten up project share notifications 2023-12-20 16:06:59 -05:00
Marshall Bowers
9a06b7e77d Style incoming call notifications 2023-12-20 15:59:01 -05:00
Nathan Sobo
9acb5825e6 Compute the query editor placeholder text with a focus handle
So we're not beholden to the current focus.
2023-12-20 13:00:52 -07:00