gpui-component/crates/ui/src/input
Andreas Johansson 8fcf5f337d
input: Fix resetting highlighting for single line code editor (#1742)
## Description

When using `set_value` with a `code_editor("lang").multi_line(false)`
the highlighting and lsp will not be reset.

## Video

### Before

https://github.com/user-attachments/assets/5fef5b6e-478e-4233-a911-e087f889040a

### After

https://github.com/user-attachments/assets/3ea99060-8dba-4604-9d3f-c151b3aadcf2

## How to Test

`cargo run --release -- input`, enter some text in "Single line code
editor", click "Reset"

## Checklist

- [x] I have read the [CONTRIBUTING](../CONTRIBUTING.md) document and
followed the guidelines.
- [x] Reviewed the changes in this PR and confirmed AI generated code
(If any) is accurate.
- [x] Passed `cargo run` for story tests related to the changes.
- [ ] Tested macOS, Windows and Linux platforms performance (if the
change is platform-specific)
2025-12-05 09:53:07 +08:00
..
lsp editor: Improve scroll to support position at the edge of the editor on click. (#1672) 2025-11-24 09:37:59 +00:00
popovers list: Refactor ListDelegate to easy access delegate. (#1713) 2025-12-01 17:42:44 +08:00
blink_cursor.rs chore: Keep spawn task on it owner. (#1456) 2025-10-29 19:11:49 +08:00
change.rs input: Add Cursor and Selection type and export line number, cursor. (#1012) 2025-06-27 20:48:26 +08:00
clear_button.rs chore: Refactor tab key to switch focus. (#991) 2025-09-29 16:48:24 +08:00
cursor.rs chore: Improve RopeExt API and add more docs. (#1289) 2025-09-25 18:17:46 +08:00
element.rs input: Fix wrong font being used in Input. (#1706) 2025-12-01 09:05:34 +00:00
indent.rs input: Add to support CodeEditor as single line mode. (#1696) 2025-11-28 19:51:40 +08:00
input.rs input: Fix wrong font being used in Input. (#1706) 2025-12-01 09:05:34 +00:00
mask_pattern.rs number_input: Allow signed numbers (#957) 2025-06-16 10:05:37 +08:00
mod.rs editor: Improve double-click for word selection (#1491) 2025-11-10 05:02:02 +00:00
mode.rs input: Add to support CodeEditor as single line mode. (#1696) 2025-11-28 19:51:40 +08:00
movement.rs editor: Improve scroll to support position at the edge of the editor on click. (#1672) 2025-11-24 09:37:59 +00:00
number_input.rs input: Change to input text size to smaller. (#1703) 2025-11-28 09:37:43 +00:00
otp_input.rs input: Change to input text size to smaller. (#1703) 2025-11-28 09:37:43 +00:00
rope_ext.rs input: Fix Input panics when masked have non-ASCII characters. (#1382) 2025-10-15 07:15:50 +00:00
search.rs editor: Improve scroll to support position at the edge of the editor on click. (#1672) 2025-11-24 09:37:59 +00:00
selection.rs editor: Improve double-click for word selection (#1491) 2025-11-10 05:02:02 +00:00
state.rs input: Fix resetting highlighting for single line code editor (#1742) 2025-12-05 09:53:07 +08:00
text_wrapper.rs input: Fix wrong font being used in Input. (#1706) 2025-12-01 09:05:34 +00:00