feat: configurable default icon for ion-item detail-icon in provideIonicAngular

Đang mở
#30,924 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
42/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
angular, typescript
Lĩnh vực
frontend

Hướng nghiên cứu

Bắt đầu bằng cách kiểm tra provideIonicAngular và cấu hình hiện có cho biểu tượng mặc định của ion-menu-button, sau đó theo dõi cách ion-item xử lý detail="true" và detail-icon. Hoàn thành khi một thuộc tính cấu hình mới cung cấp nhất quán biểu tượng chi tiết mặc định mà không yêu cầu thuộc tính này trên từng item, với độ bao phủ phù hợp với hành vi cấu hình hiện có.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

type: feature request
Prerequisites
Describe the Feature Request

A new config property to set the default icon for detail-icon on <ion-item>. Just as it works for setting the default icon for <ion-menu-button>

Describe the Use Case

We want to use our own custom icon for items with detail="true" and having to add the detail-icon attribute on every item is a lot of effort and prone to design issues if a developer forgets to do it.

Describe Preferred Solution

Add new config property

Describe Alternatives

No response

Related Code

No response

Additional Information

There was the same feature request already in https://github.com/ionic-team/ionic-framework/issues/19906
The answer with a custom wrapper component that default sets the attribute is imho not satisfying as it poses one critical problem: A default component renders markup which makes the Ionic default styling for items in lists, etc. with first-child selectors etc. not work anymore. This kind of breaks the framework and is not a good proposed solution

Ngôn ngữ chính
TypeScript
Star
52.8k
Fork
13.3k
Merge trung bình
3 ngày 1 giờ
Pull request đã merge (30 ngày)
86

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. 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.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của ionic-team/ionic-framework

Tất cả issue của ionic-team/ionic-framework

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.