gpui-component/crates/ui
obito 9d11418bd1
select: Add render prop to customize item title display. (#1638)
Fixes #1410

## Problem

The `display_title` prop was overriding the default way dropdown option
titles are displayed, causing incorrect rendering of option titles.

**Expected behavior:**
<img width="716" height="944" alt="Expected dropdown display"
src="https://github.com/user-attachments/assets/38926731-32dd-4a16-9d08-7f2eed2c99a4"
/>

**Actual behavior:**
<img width="580" height="974" alt="image"
src="https://github.com/user-attachments/assets/d96b935a-ce4d-462c-a9ce-4995f5c8eeb5"
/>

## Solution

- Revert the `display_title` change that was causing the issue
- Add a `render` function to allow custom rendering of option titles
instead

This approach provides more flexibility for customizing option display
while preserving the default behavior.

cc @stippi
2025-11-18 20:30:37 +08:00
..
locales dialog: Rename Modal to Dialog. (#1538) 2025-11-07 17:25:55 +08:00
src select: Add render prop to customize item title display. (#1638) 2025-11-18 20:30:37 +08:00
tests/fixtures dialog: Rename Modal to Dialog. (#1538) 2025-11-07 17:25:55 +08:00
Cargo.toml Bump v0.4.0 2025-11-17 10:05:08 +08:00
LICENSE-APACHE chore: Hard link crates/ui/LICENSE-APACHE. 2025-11-04 17:54:14 +08:00