angular / angular/components

docs(material/theming): add tokens section to our docs

Đang mở
#28,933 2 bình luận 10 reaction 0 người được giao Xem trên GitHub
docs M3 needs: discussion
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ả

### Documentation Feedback

Add documentation to material.angular.io to list the tokens that our components expose.

#### Design

There are still some open questions that the team should discuss.

- Should we write a description for each token?
- Critiques:
- A unique description for every token may be too much data thrown at the user which the user might mentally filter out when looking through our docs.
- Many tokens are self-explanatory. It seems silly to write `"selected-checkmark-color": The color of the checkmark when the checkbox is selected`.
- A more useful approach may be to provide a subsection that explains terminology that is obscure to most users. For example, the section could describe the following:
- What `state-layer` commonly refers to.
- Listing the different states - `active`, `pressed`, etc. Material has [a page dedicated to this](https://m2.material.io/design/interaction/states.html#usage) we could also link to.
- Where should this token list live?
- IMO under the "API" tab for each component makes the most sense.

This design satisfies the following pain point for our users:

- CSS variables are difficult to identify / discover.

### Affected documentation page

https://material.angular.io/components/autocomplete/api

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

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

Hướng nghiên cứu

Bắt đầu với trang tài liệu Autocomplete API bị ảnh hưởng tại material.angular.io/components/autocomplete/api và xem xét cách tài liệu API của component được tổ chức. Giải quyết với nhóm các câu hỏi còn bỏ ngỏ về mô tả token, thuật ngữ và vị trí. Công việc được xem là hoàn tất khi các CSS token được exposed có thể được tìm thấy trong tài liệu API của component phù hợp, cùng với hướng dẫn thuật ngữ đã được thống nhất.

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
documentation
Loại issue
Tài liệu
Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Cần làm rõ
Mức phù hợp với người mới
25/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.