DataView filters: support icons on select options (and use field.icon)
Maintainer thường phản hồi trong vòng 6 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức phù hợp với người mới
- 86/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- react, typescript
- Lĩnh vực
- frontend
Hướng nghiên cứu
Bắt đầu từ kiểu FilterSelectOption và thành phần FilterChip được nêu trong issue, cùng với phần hiện thực Select.Item hiển thị SelectItemProps và leadingIcon. Dò tìm nơi các tùy chọn bộ lọc được spread và nơi mục menu "Add filter" được dựng để xem tại sao DataViewField.icon không bao giờ được đọc. Xong khi các tùy chọn mang leadingIcon/disabled, một chip có một giá trị hiển thị icon đó, field.icon xuất hiện trong menu và chip, và các bài test component hiện có của DataView/FilterChip vẫn pass.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Select filters in DataView can only show plain text options right now. A lot of filters can have an icon that goes with each value, like a status dot, a priority glyph, or an avatar. Without it, the filter dropdown looks different from the column it's filtering, and it's slower to scan.
Select.Item already supports leadingIcon. But FilterSelectOption is just { value, label }, and FilterChip only passes label through, so there's no way to get an icon in.
Also, DataViewField has an icon prop, but as far as I can tell nothing reads it. It doesn't show in the "Add filter" menu or on the chip.
What I'd suggest
-
Let filter options take the same extras
Select.Itemdoes, instead of adding fields one by one:type FilterSelectOption = { value: FilterValueType; label: string; } & Pick<SelectItemProps, 'leadingIcon' | 'disabled'>;FilterChipwould spread those ontoSelect.Item.labelstays a plain string, since search, accessibility and the "N selected" text all depend on it. -
When one value is picked, show its icon in the chip as well, not just in the dropdown. Multiple values can keep showing "N selected".
-
Use
field.iconfor the "Add filter" menu item and the chip'sleadingIcon.
I'd skip a render-prop like renderOption. It would break the text-based stuff above, and every app would end up drawing options differently. If two-line options are ever needed (name + email), a description field would cover that better.
- Ngôn ngữ chính
- TypeScript
- Star
- 69
- Fork
- 13
- Merge trung bình
- 4 ngày 14 giờ
- Pull request đã merge (30 ngày)
- 34
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của raystack/apsara
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
Maintainer thường phản hồi trong vòng 6 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
Maintainer thường phản hồi trong vòng 6 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
Maintainer thường phản hồi trong vòng 6 ngày
-
Upgrade Base UI to 1.9.0Đang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 30/100
Maintainer thường phản hồi trong vòng 6 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
Maintainer thường phản hồi trong vòng 6 ngày
Tất cả issue của raystack/apsara
Issue tương tự
-
backend priority:P3 privacy-fix
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
[Bug]: 【优化】对话消息底部增加发送时间展示Đang mởbug desktop v3 windows
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
esengine/DeepSeek-Reasonix#13697 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:security documentation effort:S priority:P2
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
Maintainer thường phản hồi trong vòng 1 ngày
-
app:web meta:ops
Độ khó 2/5 Nửa ngày Mức phù hợp với người mới 78/100
osu-tournament-rating/otr#1113 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100