marmelab/react-admin

Add emptyText property to SelectArrayInput

Open

#10,454 opened on 2025年1月20日

GitHub で見る
 (4 comments) (0 reactions) (0 assignees)TypeScript (5,138 forks)batch import
enhancementgood first issue

Repository metrics

Stars
 (23,863 stars)
PR merge metrics
 (平均マージ 1d 13h) (30d で 18 merged PRs)

説明

It would be nice to allow to specify what should be rendered inside a SelectArrayInput when no choice is selected. This feature is already present in the SelectInput.

For example:

const channelChoices = [
    {id: "email", name: "Email"},
    {id: "push", name: "Push Notification"},
];
<SelectArrayInput source="channels" choices={channelChoices} emptyText={<i>All Channels</i>} />

コントリビューターガイド