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 adds a redirect from `zed.dev/docs/ai` to
`zed.dev/docs/ai/overview`.
Not 100% sure this will work, but want to give it a try.
Release Notes:
- N/A
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.
This is similar to the `block_mouse_down` method added in #20649 (which
has a very similar motivation), but is more comprehensive in stopping
mouse events. Since I want to cherry-pick this to the releases, keeping
this change just to the agent panel. In a follow-up will replace
existing use of `block_mouse_down` to instead use this.
Release Notes:
- N/A
- Fix `ctrl-p` not working in the model selector
- Select first entry when opening the context picker
Release Notes:
- Fixed `menu::SelectPrevious` keybindings not working in the agent
panel's model selector.
Seems that `h_full` was causing it to use the height of the overall list
item for some reason.
Closes#30002
Release Notes:
- Agent Panel: Fixed text overlap for code blocks nested in lists in
agent response.
Useful for large monorepos with many subdirectories, users can keybind a
filter to their commonly used directories.
Release Notes:
- Added a new `included_files` field to the `DeploySearch` action to
automatically pre-fill which files to include in the search. This lets
you use a keybinding to search in a particular folder or for a certain
set of files.
---------
Co-authored-by: Antonio Scandurra <me@as-cii.com>
Fixes https://github.com/zed-industries/zed/issues/30346
The model can output an empty string to indicate the absence of
arguments, which can't be parsed as a `serde_json::Value`. When that
happens, we now create an empty object instead on behalf of the model.
Release Notes:
- Fixed a bug that prevented Copilot models from calling the
`diagnostic` tool.
This is a more generic implementation of
https://github.com/zed-industries/zed/pull/30360
This also removes the need for a separate close action for the git
panel.
The downside is maybe it is harder to find since it is less specific.
Release Notes:
- workspace: Added new `workspace: close active dock` action to close
the currently focused dock