Kirill Bulatov
1936bdebb3
Use less padding for typescript parameter hints
2023-07-06 11:16:39 +03:00
Antonio Scandurra
f6c96ec892
Fix panic when saved conversations directory changes
...
We were updating the view's state but missed a `notify`, which caused
the `UniformList` responsible for rendering the saved conversations
to panic when some files were deleted.
2023-07-06 09:53:34 +02:00
Mikayla Maki
801f41e68e
Move audio dependency to dev
2023-07-05 12:15:56 -07:00
Mikayla Maki
8b8bafef22
Remove spurious audio depedency
2023-07-05 12:05:16 -07:00
Mikayla Maki
594b6e8d64
collab 0.16.0
2023-07-05 11:47:17 -07:00
Joseph T. Lyons
6a15ae9c01
v0.95.x dev
2023-07-05 14:17:37 -04:00
Nate Butler
76873c508a
Z-2276/Z-2275: Project & Branch switchers ( #2662 )
...
This PR adds project and branch switchers in top left corner.
Release Notes:
- Added a project & branch switcher under project name.
2023-07-05 13:09:40 -04:00
Piotr Osiewicz
b80281e556
cargo fmt
2023-07-05 18:57:06 +02:00
Nate Butler
1baa13561d
Update project & git menus to be Toggleable<Interactive<ContainedText>>
...
Co-Authored-By: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
2023-07-05 12:50:56 -04:00
KCaverly
afccf608f4
updated both embed and parsing tasks to be multi-threaded.
2023-07-05 12:39:08 -04:00
Nate Butler
de01fa1794
Update collaboration sounds, add sounds to screensharing ( #2679 )
...
Updates all collab sounds, add screen sharing sounds.
Release Notes:
- Improved collaboration sounds for joining and leaving a call, muting
and unmuting the mic.
- Added a sound when you start and stop screen sharing.
2023-07-05 12:30:47 -04:00
Piotr Osiewicz
0e0d78df84
Do not render recent paths in toolbar's project switcher
2023-07-05 18:04:40 +02:00
Piotr Osiewicz
ec47464bba
branch_list: Show match count on the right hand side of a header.
...
Co-authored-by: Antonio <antonio@zed.dev>
2023-07-05 16:56:08 +02:00
Piotr Osiewicz
85add260f6
Track regions instead of clicks.
...
Get rid of superfluous params in RenderParams related to hover & click state.
Co-authored-by: Antonio <antonio@zed.dev>
2023-07-05 16:48:52 +02:00
KCaverly
eff0ee3b60
enabled batching for embedding calls
2023-07-05 10:02:42 -04:00
Piotr Osiewicz
cc88bff1ff
Fix click-through behaviour of git panel
...
Co-authored-by: Antonio <antonio@zed.dev>
2023-07-05 15:25:33 +02:00
Kirill Bulatov
d7f6b5e1a0
Remove InlayProperties
2023-07-05 16:17:14 +03:00
Kirill Bulatov
6ba1c3071a
Simplify inlay map data
2023-07-05 15:23:56 +03:00
Piotr Osiewicz
8b3b1a6074
fixup! Remove stacks from branch list header
2023-07-05 14:08:21 +02:00
Piotr Osiewicz
64b77bfa8d
Remove stacks from branch list header
...
Co-authored-by: Antonio <antonio@zed.dev>
2023-07-05 14:04:16 +02:00
Antonio Scandurra
d5f0df94f7
Support assistant: quote selection
on multibuffers
2023-07-05 11:41:24 +02:00
Antonio Scandurra
03a00df8b1
Restore focus to previously focused view when dismissing a modal
2023-07-05 09:40:26 +02:00
Antonio Scandurra
a8602b2a0c
Add Modal::has_focus
and introduce a ModalHandle
trait object
2023-07-05 09:39:56 +02:00
Antonio Scandurra
25564ea058
Introduce a WindowContext::focus
method that implies the window id
2023-07-05 09:39:04 +02:00
Nate Butler
a7ce602bac
Update collaboration sounds, add sounds to screensharing
2023-07-04 16:18:42 -04:00
KCaverly
b6520a8f1d
updated vector_store to reindex on save after timed delay
2023-07-04 14:42:12 -04:00
Kirill Bulatov
4c51ab8a25
Accept null
as a valid action, to disable a keystroke
...
co-authored-by: Mikayla Maki <mikayla@zed.dev>
2023-07-04 21:11:28 +03:00
KCaverly
e45d3a0a63
WIP: initial reindexing logic worked out
2023-07-04 11:46:09 -04:00
Piotr Osiewicz
48371ab8b2
Remove PickerEvent::Dismiss emission from picker header
2023-07-04 16:30:17 +02:00
Piotr Osiewicz
e9b34de7c8
Fix click behaviour of vcs/project dropdowns
2023-07-04 16:00:59 +02:00
Conrad Irwin
0d18b72cf8
vim: Further improve ~ handling
...
Now works with Visual{line} mode, collapses selections like nvim,
and doesn't fall off the end of the line.
2023-07-03 23:58:09 -06:00
Nate Butler
a732b2e043
Remove unused color_scheme
field in the theme
...
I totally didn't mean to commit this right to main T_T
2023-07-04 00:44:12 -04:00
Nate Butler
c409059dc4
Revert "Remove unused color_scheme
field in the theme"
...
This reverts commit 5a1476a1e5
.
2023-07-04 00:41:13 -04:00
Nate Butler
5a1476a1e5
Remove unused color_scheme
field in the theme
2023-07-04 00:40:01 -04:00
Conrad Irwin
0733e8d50f
Remove editor::Cancel binding from vim
...
When you hit <escape> in the command palette, it first editor::Cancel
because the command palette is also a focused editor; this binding was
catching before the `menu::Cancel` that you probably want.
From looking at the uses of editor::Cancel it seems like the only way to
trigger this is with <escape> in an editor. Rather than trying to hook
into the existing editor cancel and add vim-specific behaviour, we'll
instead take responsibility for binding directly to <escape> when
necessary.
Fixes : zed-industries/community#1347
2023-07-03 15:26:39 -06:00
Mikayla Maki
f8316dd127
Add sound effects to calls ( #2673 )
...
This PR adds joined, leaving, mute, and unmute sound effects to Zed.
Release Notes:
- Added joined, leaving, mute, and unmute sound effects (preview-only)
2023-07-03 13:55:48 -07:00
Mikayla Maki
c700342a1c
Guard against uninstantiated globals in tests
2023-07-03 13:48:17 -07:00
Mikayla Maki
0e4c904091
Add joined sound effect when new participants join the room
2023-07-03 13:36:03 -07:00
Mikayla Maki
d2127825e3
Add first-pass sound support to Zed
2023-07-03 13:30:04 -07:00
Piotr Osiewicz
14eab4e94f
branch list: dismiss correct window on PickerEvent.
...
Query proper window
2023-07-03 19:22:43 +02:00
Piotr Osiewicz
806268f0db
Merge branch 'main' into git-menu
2023-07-03 16:25:36 +02:00
Kirill Bulatov
85701c9b80
Do not perform OnTypeFormating after pair brace insert
...
Co-Authored-By: Julia Risley <julia@zed.dev>
2023-07-03 17:21:44 +03:00
Piotr Osiewicz
4eedc3e646
Remove flex from underneath the pickers
2023-07-03 16:16:14 +02:00
Kirill Bulatov
43d4f04331
Do not add extra spaces to hints
2023-07-03 11:17:12 +03:00
Conrad Irwin
e36d5f41c8
Fix % when on the last character of the line
...
Contributes: zed-industries/community#682
2023-07-01 13:51:11 -06:00
Piotr Osiewicz
026ad191eb
Dismiss dropdowns on click out
2023-07-01 01:49:00 +02:00
Piotr Osiewicz
525521eeb3
Render match count next to branch label
2023-07-01 01:38:36 +02:00
Mikayla Maki
138de37cbf
Add basic sound handling infrastructure
2023-06-30 16:10:49 -07:00
KCaverly
18a5a47f8a
moved semantic search model to dev and preview only.
...
moved db update tasks to long lived persistent task.
Co-authored-by: maxbrunsfeld <max@zed.dev>
2023-06-30 18:41:19 -04:00
KCaverly
3408b98167
updated file compare in the semantic indexing engine, to work off of modified system times as opposed to file hashes
...
Co-authored-by: maxbrunsfeld <max@zed.dev>
2023-06-30 16:53:23 -04:00
KCaverly
36907bb4dc
updated vector store indexing to only use languages with an embedding.scm treesitter query
...
Co-authored-by: maxbrunsfeld <max@zed.dev>
2023-06-30 16:14:11 -04:00
Kirill Bulatov
ae54e1d224
Remove excessive hint update queries
...
* Filter out queries for outdated buffers just before hint tasks spawn:
multicared edits might empit standalone events simultaneously
* Only spawn inlay update tasks for visible buffers with corresponding
language
* Do not spawn tasks for local projects' buffers without LSP servers
2023-06-30 22:03:21 +03:00
Max Brunsfeld
f83514cde4
Fix regression in handling git FS events ( #2670 )
...
As part of an optimization in
https://github.com/zed-industries/zed/pull/2663 , I changed the way that
the worktree ignores FS events within unloaded directories. But this
accidentally prevented us from detecting some events that occur inside
of `.git` directories.
In this PR, I've made further tweaks to which FS events we can ignore.
We now explicitly opt *in* to scanning `.git` (shallowly) directories
(even though they are ignored). Note that we still don't recursively
scan the git directory (including all of the files inside `objects`
etc). This seems like the correct amount of work to do, and from my
testing (and our unit tests that use the real FS and real git
repositories), it seems to work correctly.
Release Notes:
- Fixed a bug where Zed would not detect some git repository changes
(preview only).
2023-06-30 11:40:49 -07:00
Max Brunsfeld
92df76e632
Fix accidental ignoring of git FS events
2023-06-30 11:20:50 -07:00
Piotr Osiewicz
7c2c1a279b
Add missing rust-side definitions
2023-06-30 20:09:30 +02:00
Piotr Osiewicz
cec884b5a5
Add styles for project name/git menu
2023-06-30 20:07:44 +02:00
Piotr Osiewicz
a5d9a10d7b
Focus dropdowns on open
2023-06-30 19:48:28 +02:00
KCaverly
0db0876289
implemented file deletes on project indexing
2023-06-30 11:01:35 -04:00
Piotr Osiewicz
ed75c31640
Improve styling of git menu
2023-06-30 16:38:38 +02:00
Piotr Osiewicz
b699e5c142
Add styles to git menu
2023-06-30 16:23:27 +02:00
KCaverly
e3ab54942e
removed sleep from directory scanning as fixes upstream appear to be scanning correctly
2023-06-30 10:17:31 -04:00
KCaverly
1d737e490b
Merge branch 'main' of github.com:zed-industries/zed into vector_store
2023-06-30 09:58:13 -04:00
Piotr Osiewicz
3be8977ee8
Switch branches within spawn()
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
c1a6292152
Add missing call to cx.notify
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
081e340d26
Do not query db on foreground thread.
...
Co-authored-by: Mikayla <mikayla@zed.dev>
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
818ddbc703
Make project dropdown exclusive wrt git menu
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
888d3b3fd6
Project dropdown menu
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
d000ea9739
Fix warning about unused variable
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
1eb0f3d091
Update toast for checkout failure
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
98f71a7fa3
Trail off project/branch name
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
e57364ede6
Remove unnecessary imports
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
aeafa6f6d6
Fix build after rebase
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
c84f3b3bfc
Add toast for git checkout failure
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
54fad5969f
List recent branches
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
3027e4729a
Add timestamps to branches
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
6747acbb84
Trail off branch names
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
ac6e9c88e9
Render header and footer of git menu
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
d8d0bdc479
WIP: git menu
2023-06-30 14:05:55 +02:00
Mikayla Maki
3d6e063a6d
Fix method header
2023-06-29 23:53:57 -07:00
Mikayla Maki
d22a576f5e
fix failing test
2023-06-29 23:50:24 -07:00
Conrad Irwin
abb58c41db
vim: Fix edge-case in } when trailing newline is absent
...
Added .assert_shared_state() to NeovimBackedTestContext – although it's
not strictly necessary to show the expected behaviour in the test file
(as we can just compare to neovim's JSON recording), it makes it much
easier to understand what we're testing.
2023-06-29 23:31:22 -06:00
Conrad Irwin
9ee2707d43
vim: Add }/{ for start/end of paragraph
...
Fixes : zed-industries/community#470
2023-06-29 23:31:22 -06:00
Mikayla Maki
a9a51ab3ad
Added more tests and minimal file updates
2023-06-29 18:21:35 -07:00
Mikayla Maki
a6dabf7acf
Make path updates minimal
2023-06-29 18:15:40 -07:00
Mikayla Maki
787412b545
fmt and update dependency
2023-06-29 17:49:42 -07:00
Mikayla Maki
cd670e340f
Fix edge case with absolute file paths
2023-06-29 17:48:01 -07:00
Mikayla Maki
33f5248d4f
Add the ability to make new directories by adding slashes to a file name
2023-06-29 17:35:22 -07:00
Mikayla Maki
f6b64dc67a
Add click out events to GPUI ( #2659 )
...
This PR adds a new mouse event type for catching when a click happens
outside of a given region.
This was added because I noticed a 'race condition' between the context
menu and the buttons which deploy a context menu. Buttons use on
an`on_click()` handler to deploy the context menu, but the context menu
was closing itself with an `on_down_out()` handler. This meant that the
order of operations was:
0. Context menu is open
1. User presses down on the button, _outside of the context menu_
2. `on_down_out()` is fired, closing the context menu
3. User releases the mouse
4. `click()` is fired, checks the state of the context menu, finds that
it's closed, and so opens it
You can see this behavior demonstrated with this video with a long-click
here:
https://github.com/zed-industries/zed/assets/2280405/588234c3-1567-477f-9a12-9e6a70643527
~~Switching from `on_down_out()` to `on_click_out()` means that the
click handler for the button can close the menu before the context menu
gets a chance to close itself.~~
~~However, GPUI does not have an `on_click_out()` event, hence this
PR.~~
~~Here's an example of the new behavior, with the same long-click
action:~~
https://github.com/zed-industries/zed/assets/2280405/a59f4d6f-db24-403f-a281-2c1148499413
Unfortunately, this `click_out` is the incorrect event for this to
happen on. This PR now adds a mechanism for delaying the firing of a
cancel action so that toggle buttons can signal that this on_down event
should not result in a menu closure.
Release Notes:
* Made context menus deployed from buttons toggle, instead of
hide-and-re-show, visibility on click
2023-06-29 17:33:37 -07:00
Mikayla Maki
73b0f3b23d
fmt
2023-06-29 17:19:35 -07:00
Mikayla Maki
5366631173
Remove on_click_out handler from context menu
...
Add 'delay_cancel()' method and on_down handler to relevant buttons
2023-06-29 17:10:51 -07:00
Nate Butler
77b120323b
Add low_tokens_remaining
case to the assistant
2023-06-29 17:44:47 -04:00
Kirill Bulatov
b146762f68
Remove a flacky test, fix the failing one
2023-06-29 22:45:04 +03:00
Kirill Bulatov
652909cdba
Post-rebase fixes
2023-06-29 22:39:33 +03:00
Kirill Bulatov
3445bc42b6
Invalidate refresh tasks better
2023-06-29 22:39:18 +03:00
Kirill Bulatov
98edc0f885
Simplify the hint cache code
2023-06-29 22:39:18 +03:00
Kirill Bulatov
083e4e76e2
Better tests, invalidate multibuffer excerpts better
2023-06-29 22:39:18 +03:00
Kirill Bulatov
943c93fda7
Simplify hint task queueing
2023-06-29 22:39:18 +03:00
Kirill Bulatov
30e77aa388
More inlay hint cache tests
2023-06-29 22:39:18 +03:00
Kirill Bulatov
429a9cddae
Use fold points to go to display map's prev/next line boundary
...
Co-Authored-By: Antonio Scandurra <antonio@zed.dev>
2023-06-29 22:39:18 +03:00
Kirill Bulatov
bb9ade5b6f
Fix wrap map test
...
Co-Authored-By: Antonio Scandurra <antonio@zed.dev>
2023-06-29 22:39:18 +03:00
Kirill Bulatov
2b59f27c3b
Fix fold map tests
...
Co-Authored-By: Antonio Scandurra <antonio@zed.dev>
2023-06-29 22:39:18 +03:00
Kirill Bulatov
0972766d1d
Add more hint tests
2023-06-29 22:39:18 +03:00
Kirill Bulatov
15e0feb91d
Move highlights from fold to inlay randomized tests
2023-06-29 22:39:18 +03:00
Kirill Bulatov
667b70afde
Move hint settings on the language level
2023-06-29 22:39:18 +03:00
Kirill Bulatov
480d8c511b
Theme hints and suggestions differently
2023-06-29 22:39:18 +03:00
Kirill Bulatov
3312c9114b
Improve inlay hint highlights
...
Co-Authored-By: Antonio Scandurra <antonio@zed.dev>
2023-06-29 22:39:18 +03:00
Kirill Bulatov
2c54d926ea
Test inlay hint cache
2023-06-29 22:39:18 +03:00
Nate Butler
143a020694
Update Hint Style
...
zzz
2023-06-29 22:39:17 +03:00
Kirill Bulatov
67214f0e55
Only skip /refresh inlay queries when vislble range is not updated
2023-06-29 22:25:50 +03:00
Kirill Bulatov
096bad1f73
Revert useless changes, simplify
2023-06-29 22:25:50 +03:00
Antonio Scandurra
f77b680db9
Account for inlay biases when clipping a point
2023-06-29 22:25:50 +03:00
Antonio Scandurra
976edfedf7
Add Cursor::next_item
2023-06-29 22:25:50 +03:00
Kirill Bulatov
5c21ed4263
Properly filter out task hints
2023-06-29 22:25:50 +03:00
Kirill Bulatov
dfb30218ca
Remove mutex usage from *Map contents
2023-06-29 22:25:50 +03:00
Kirill Bulatov
acef5ff195
Query hints when editors gets open and visible
2023-06-29 22:25:50 +03:00
Kirill Bulatov
11fee4ce42
Do not eagerly cancel running tasks
2023-06-29 22:25:49 +03:00
Kirill Bulatov
4d4544f680
Split excerpts into mutliple ranges for inlay hint queries
2023-06-29 22:25:49 +03:00
Kirill Bulatov
2c7900e11b
Use excerpt visible range in query filtering
2023-06-29 22:25:49 +03:00
Kirill Bulatov
83b3a914bc
Support better inlay cache parallelization
2023-06-29 22:25:49 +03:00
Kirill Bulatov
890b164278
Forward inlay hint refresh requests to clients, test coop inlay hints
2023-06-29 22:25:49 +03:00
Kirill Bulatov
a68e68a0d9
Properly filter out new hints outside of excerpts' visible ranges
2023-06-29 22:25:49 +03:00
Kirill Bulatov
ba3d1e4dba
Deduplicate inlay hints queries with buffer versions
2023-06-29 22:25:49 +03:00
Kirill Bulatov
f25a09bfd8
Avoid excessive allocations with Arc around excerpt cached inlays
2023-06-29 22:25:49 +03:00
Kirill Bulatov
48982c3036
Filter away new hints not in excerpt range
2023-06-29 22:25:49 +03:00
Kirill Bulatov
316e19ce94
Remove stale cancelled inlay hints workaround
2023-06-29 22:25:49 +03:00
Kirill Bulatov
96a34ad0ee
Use text anchors as hint position in hints cache
...
co-authored-by: Max Brunsfeld <max@zed.dev>
2023-06-29 22:25:49 +03:00
Kirill Bulatov
781fa0cff4
Deduplicate LSP requests on multibuffer scroll
2023-06-29 22:25:49 +03:00
Kirill Bulatov
c61de29c11
Use proper anchors for remote LSP queries
2023-06-29 22:25:49 +03:00
Kirill Bulatov
cb4b92aa61
Simplify hint event management slightly
2023-06-29 22:25:49 +03:00
Kirill Bulatov
d59e91aff2
Insert new hints into cache better
2023-06-29 22:25:49 +03:00
Kirill Bulatov
d6828583d8
Box the cache for better performance
2023-06-29 22:25:49 +03:00
Kirill Bulatov
1722d61190
Mitigate odd offset calculations
2023-06-29 22:25:49 +03:00
Kirill Bulatov
7fddc223cd
Move away heavy inlay computations into background tasks
2023-06-29 22:25:49 +03:00
Kirill Bulatov
31f0f9f7b1
Forbid extra inlay updates
2023-06-29 22:25:49 +03:00
Kirill Bulatov
97e5d40579
Add snapshot version to use when avoiding wrong state updates
2023-06-29 22:25:49 +03:00
Kirill Bulatov
8d982a6c2d
Finish modelling
2023-06-29 22:25:49 +03:00
Kirill Bulatov
4c78019317
Start to model the background threads for InlayHintCache
2023-06-29 22:25:49 +03:00
Kirill Bulatov
2f1a27631e
React on multibuffer scrolls again
2023-06-29 22:25:49 +03:00
Kirill Bulatov
a31d3eca45
Spawn cache updates in separate tasks
2023-06-29 22:25:49 +03:00
Antonio Scandurra
9698b51524
Prevent insertion of empty inlays into InlayMap
2023-06-29 22:25:49 +03:00
Kirill Bulatov
3b9a2e3261
Do not track editor ranges in InlayHintCache
2023-06-29 22:25:49 +03:00
Kirill Bulatov
70a45fc800
Fix cache incremental updates
2023-06-29 22:25:49 +03:00
Kirill Bulatov
7ac1885449
Properly refresh hints on editor open
2023-06-29 22:25:49 +03:00
Kirill Bulatov
58343563ba
Fix hint querying bugs
2023-06-29 22:25:49 +03:00
Kirill Bulatov
debdc3603e
Finish rest of the inlay cache logic
2023-06-29 22:25:49 +03:00
Kirill Bulatov
ddcbc73bf0
Implement inlay hint replaces for conflict-less case
2023-06-29 22:25:49 +03:00
Kirill Bulatov
6368cf1a27
Merge excerpt-related hint data, move next_inlay_id into Editor
2023-06-29 22:25:49 +03:00
Kirill Bulatov
8c03e9e122
Move InlayId generation back to InlayCache
2023-06-29 22:25:49 +03:00
Kirill Bulatov
e82b4d8957
Properly handle hint addition queries
2023-06-29 22:25:49 +03:00
Kirill Bulatov
5322aa09b9
Properly handle settings toggle
2023-06-29 22:25:49 +03:00