I noticed the discussion in #28881, and had thought of exactly the same
a few days prior.
This implementation should preserve existing functionality fairly well.
I've added a dependency (serde_with) to allow the deserializer to skip
models which cannot be deserialized, which could occur if a future
provider, for instance, is added. Without this modification, such a
change could break all models. If extra dependencies aren't desired, a
manual implementation could be used instead.
- Closes#29369
Release Notes:
- Dynamically detect available Copilot Chat models, including all models
with tool support
---------
Co-authored-by: AidanV <aidanvanduyne@gmail.com>
Co-authored-by: imumesh18 <umesh4257@gmail.com>
Co-authored-by: Bennet Bo Fenner <bennet@zed.dev>
Co-authored-by: Agus Zubiaga <hi@aguz.me>
Closes#30526.
This PR makes the CacheKey used by raster_bounds and rasterize_glyph the
same, as they had not used the same sub pixel shift previously. Fixing
this resolves both the alignment and text-rendering issues introduced in
`ddf8d07`.
Release Notes:
- Fixed text rendering issues on Linux.
Release Notes:
- debugger: allow setting env vars and arguments on the launch command.
---------
Co-authored-by: Cole Miller <m@cole-miller.net>
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Ref: https://github.com/zed-industries/zed/pull/29919
This PR improves how inline assistants are detected and focused based on
cursor position.
### Problem
The current implementation has inconsistent behavior:
- When selecting text within an inline assistant's range, the assistant
properly focuses
- When placing a cursor on a line containing an assistant (without
selection), a new assistant is created instead of focusing the existing
one
### Solution
Enhanced the assistant detection logic to:
- Check if the cursor is anywhere within the line range of an existing
assistant
- Maintain the same behavior for both cursor placement and text
selection
- Convert both cursor position and assistant ranges to points for better
line-based comparison
This creates a more intuitive editing experience when working with
inline assistants, reducing the creation of duplicate assistants when
the user intends to interact with existing ones.
https://github.com/user-attachments/assets/55eb80d1-76a7-4d42-aac4-2702e85f13c4
Release Notes:
- agent: Improved inline assistant behavior to focus existing assistants
when cursor is placed on their line, matching selection behavior
---------
Co-authored-by: Bennet Bo Fenner <bennet@zed.dev>
This was a particular problem in the Amazon Bedrock section (at least
for now) where there were multiple buttons and none of them actually
worked because they all had the same id.
Release Notes:
- agent: Fixed Amazon Bedrock settings link buttons not working.
This is our first eval of the Minimal tool profile. Right now they're
all passing; the value of having it is to catch regressions in the
system prompt (which has special logic in it for the case where no tools
are enabled).
Release Notes:
- N/A
Release Notes:
- Added Cross-Region inference support for US Claude 3.5 Haiku
Co-authored-by: Peter Tripp <peter@zed.dev>
Co-authored-by: Marshall Bowers <git@maxdeviant.com>
This is my first time contributing, so happy to make changes as needed.
## Problem
I found the LLM Provider settings to be pretty difficult to scan as I
was looking to enter my API credentials for a provider. Because all of
the provider configuration is exposed by default, providers that come at
the end of the list are pushed fairly far down and require scrolling. As
this list increases the problem only get worse.
## Solution
This is strictly a UI change.
* I put each provider configuration in a Disclosure that is closed by
default. This made scanning for my provider easy, and exposing the
configuration takes a single click. No scrolling is required to see all
providers on my 956px high laptop screen.
* I also added the success checkmark to authenticated providers to make
it even easier to find them to update a key or sign out.
* The `Start New Thread` had a class applied that was overriding the
default hover behavior of other buttons, so I removed it.
## Before

## After

Release Notes:
- Improved Agent Panel settings view scannability by making each
provider block collapsible by default.
---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
The title of a (text) thread would get stuck in "Loading Summary..."
when the request to generate it failed. We now handle this case by
falling back to the default title, and letting the user manually edit
the title or retry generating it.
https://github.com/user-attachments/assets/898d26ad-d31f-4b62-9b05-519d923b1b22
Release Notes:
- agent: Handle thread title generation errors
---------
Co-authored-by: Richard Feldman <oss@rtfeldman.com>
Closes https://github.com/zed-industries/zed/issues/23386
This PR updates the scrollbar-component to account for padding present
in the parent container.
Since the linked issue was opened,
https://github.com/zed-industries/zed/pull/25288 improved the behaviour
so that the scrollbar does allow scrolling the entire container, however
the scrollbar thumb still does not go the entire way to the bottom. This
can be seen here:
https://github.com/user-attachments/assets/89204355-e6b8-428b-9fa9-bb614051b6fa
This happens because during layouting of the scrollbar, padding of the
parent container is not taken into account. The scrollbar thumb size is
calculated as if no padding was present.
With this change, padding is now included in the calculation, which
resolves the issue:
https://github.com/user-attachments/assets/1d4c62e0-4555-4332-a9ab-4e114684b4b3
The change here is to store the calculated content size during prepaint
_including_ padding and use this for layouting the scrollbar. This
ensures that the actual scroll max and the content size are always in
sync. Furthermore, the existing `TODO`-comment is also resolved, as we
now no longer look at the size of the last child but the actual parent
size instead.
This also removes an existing panic of the scrollbar-component in cases
where the content size was 0, which was previously not accounted for
(this never happened in practice so far, for example because of the
padding added here:
43712285bf/crates/editor/src/hover_popover.rs (L802-L809)
which prevented the container size from ever being 0).
---
Lastly, as I was wiring through the changes of the `content_size` I
noticed that some code was duplicated during the initial layouting as
well as in the click handlers. I refactored this in the second commit to
use `along` where possible as well as computing the new click offset in
one closure which can be passed to both event listeners. As always,
should any of these changes not be wanted, feel free to let me know and
I will revert these.
Looking forward to your feedback 😄
Release Notes:
- Fixed scrollbars sometimes not scrolling all the way to the bottom.
Just a tiny patch to reduce allocations during context loading
Calling `.cloned()` on an iterator clones each element one by one, while
`into_iter().collect()` pre-allocates the resulting `Vec`
Release Notes:
- N/A
Closes#16993
This PR fixes an issue where the vertical editor scrollbar was
overlaying with buffer headers. I fixed this by reserving space for the
scrollbar as needed which is provided by the recently introduced
`right_margin`.
Most of the diff consists of moving the `EditorMargins` creation out of
`render_block`, as the right margin is stored in this struct and moving
this out reduces the length of the parameter list of `render_blocks` by
one. I thought of this to be a small but nice side effect.
When it comes to the dividers, I decided against these considering the
margin as well, since it felt a bit off. However, I can see arguments
for these also considering the margins. I did include an image for
comparison in the list below. Happy to change this should it be
preferred the other way around.
| `main` |

|
| --- | --- |
| PR |

|
| Fix with shortened divider |

|
Release Notes:
- Ensured that the vertical editor scrollbar no longer overlaps with
buffer headers.
For some reason `pulldown_cmark` treats \````` as a codeblock, meaning
that we could end up with an invalid range generated from
`extract_code_block_content_range` (`3..2`)
Closes#30495
Release Notes:
- agent: Fix an edge case where the editor would crash when model
generated malformed markdown
This PR updates the plan display in the user menu in the title bar to
hide plans that do not have a subscription period.
Release Notes:
- Improved the displaying of the plan in the user menu.
Closes https://github.com/zed-industries/zed/issues/30411
Rendering as markdown gives us text selection and copying for free. In
the future, we may want to explore having these commands be actual
editors, allowing you to step in, change the command, and re-run it
right from there.
Release Notes:
- agent: Made the terminal command in the tool card selectable and
copyable.
This PR factors out a `render_data_collection_explanation` method in the
`ZedPredictModal`.
This allows `rustfmt` to work inside of `render` once again.
Release Notes:
- N/A
Just noticed this got lost when main was merged in #29828.
Release Notes:
- agent: Fixed the rendering of added context when editing past messages
in a thread.
Fixes#15752.
- Updated `cosmic_text` to 0.14.0
- Made a basic implementation for setting font features.
#12176 is not fixed by this PR.
Release Notes:
- Added initial support for `font_features` on Linux
It should show "Remove co-authored-by" when hovering on co-author is
already added state. And should say
"Add co-authored-by" when it is at disabled state.
Release Notes:
- N/A
Co-authored-by: Ben Kunkle <ben@zed.dev>
Release Notes:
- Fixed a race condition that sometimes prevented a system-installed
`node` binary from being detected.
- Fixed a bug where the `node.path` setting was not respected when
invoking npm.
Closes https://github.com/zed-industries/zed/issues/30238
Release Notes:
- agent: Fixed layout shift happening in the toolbar (both in the
singleton and multibuffers) due to the "Generating" label that appeared
while the agent is still generating a response.
- Try to preserve previously selected item on update
- Do not clear list items while updating to avoid a frame with no items
rendered
Release Notes:
- agent: Preserve previously selected item in Thread History on update
---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Co-authored-by: Richard Feldman <oss@rtfeldman.com>
This PR restores the `ZED_PREDICT_EDITS_URL` that was removed in
https://github.com/zed-industries/zed/pull/30290.
While we don't need to use it anymore for local development against the
LLM Worker, some folks reported using it to run versions of Zeta hosted
elsewhere.
Since we don't yet have an officially-supported mechanism today for
bringing your own Zeta for edit predictions, I'm putting the environment
variable back to not break that use case.
Closes https://github.com/zed-industries/zed/issues/30308.
Release Notes:
- N/A
This reverts commit 3615d6d96c.
Ultimately, we want to restore the ability to store a profile
per-thread, but for now reverting this fixes a fairly disruptive bug.
Release Notes:
- Fixed a bug causing the agent to use the wrong profile in some cases.
Reverts back to previous behavior where we update your settings so we
can load a new thread from your last configuration.
Release Notes:
- agent: Persist profile changes for new threads
This PR's main goal is to show the delete thread button when the list
item is either focused or hovered. In order to do that, we ended up
refactoring (i.e., merging) the `PastThread` and `PastContext` elements
into a single `HistoryElementEntry` that already matches to the entry
type (i.e., context or thread).
Release Notes:
- agent: Simplify the UI by showing the delete thread icon button only
on hover or focus.
---------
Co-authored-by: Agus Zubiaga <hi@aguz.me>
Closes#29819
Release Notes:
- Removed a faulty check in the askpass implementation causing
unintended "Failed to check metadata of Zed executable path for use in
askpass" errors when remoting via SSH or doing git operations that
require authentication.