angular / angular/components

feat(stepper): Make `CdkStepper` generic to support extended CdkStep

Đang mở
#22,590 3 bình luận 4 reaction 0 người được giao Xem trên GitHub
area: cdk/stepper feature needs: discussion P4
Ngôn ngữ chính
TypeScript
Star
25k
Fork
6.8k
Merge trung bình
1 ngày 8 giờ
Pull request đã merge (30 ngày)
91

Mô tả

#### Feature Description

Currently, when I want to use `CdkStepper` with a custom class for a step (extension of a class `CdkStep`, e.g. `MyStep extends CdkStep`), I am not able to as `CdkStepper` is not generic and is fixed to `CdkStep` class for a step. I would like to make `CdkStepper` generic, so I can use `CdkStepper`.

#### Use Case

Let's say I have a class`OnboardingStepComponent extends CdkStep` which has the property `specialLabel`. I want to use the CdkStepper with this specialized step component.

Let me know if this sounds reasonable, if so, I can work on this.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Hướng nghiên cứu

Bắt đầu bằng cách xác định các entry point CdkStepper và CdkStep trong repository các component của Angular và kiểm tra cách step type hiện đang được cố định. Xác nhận hành vi mong muốn bằng một MyStep hoặc OnboardingStepComponent chuyên biệt, sau đó bổ sung coverage cho thấy CdkStepper hỗ trợ một step mở rộng với specialLabel.

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

Đánh giá

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

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.