Commit graph

9 commits

Author SHA1 Message Date
Taylor Mullen
968e09f0b5 fix: Ensure filename is available for diff rendering in write-file
This commit resolves a bug where the `write-file` operation could fail to render content due to a missing filename.

The fix involves:
- Ensuring `fileName` is consistently passed to `DiffRenderer.tsx` through `ToolConfirmationMessage.tsx`, `ToolMessage.tsx`, and `useGeminiStream.ts`.
- Modifying `edit.ts` and `write-file.ts` to include `fileName` in the `FileDiff` object.
- Expanding the `FileDiff` interface in `tools.ts` to include `fileName`.

Additionally, this commit enhances the diff rendering by:
- Adding syntax highlighting based on file extension in `DiffRenderer.tsx`.
- Adding more language mappings to `getLanguageFromExtension` in `DiffRenderer.tsx`.
- Added lots of tests for all the above.

Fixes https://b.corp.google.com/issues/418125982
2025-05-16 10:13:13 -07:00
Miguel Solorio
416813452e
Improvements to suggestions & slash commands (#344)
Co-authored-by: N. Taylor Mullen <ntaylormullen@google.com>
2025-05-14 16:01:29 -07:00
Allen Hutchison
4a6d0717a1
fix for b/414940078 (#306) 2025-05-09 15:38:19 -07:00
Allen Hutchison
adeda6a5b3
Refactor: Memoize hook callbacks, update dependencies, and fix lint errors (#268)
Co-authored-by: N. Taylor Mullen <ntaylormullen@google.com>
2025-05-06 14:48:49 -07:00
Seth Troisi
2cd976987e slash command altnames and support for ? 2025-05-05 22:33:22 +00:00
Seth Troisi
cc838fad44 Add autocomplete for slash commands 2025-05-02 20:58:53 +00:00
Jacob Richman
53ac7952c7
Support escaping spaces in file paths. (#241) 2025-05-01 18:02:04 -07:00
Allen Hutchison
9f20c5f95e
Add @ command suggestions in the UI. (#219) 2025-04-30 08:31:32 -07:00
Allen Hutchison
e0de69f384
First four independent files for @ commands. (#205) 2025-04-29 08:29:09 -07:00