angular / angular/components

feat(datepicker): Support fixed height with displaying trailing and leading days of surrounding months

未关闭
#29,549 3 条评论 4 个 reaction 已指派 0 人 在 GitHub 查看
area: material/datepicker feature P4
主要语言
TypeScript
星标
25k
派生
6.8k
平均合并
1 天 8 小时
30 天内合并 PR
91

描述

### Feature Description

Currently the Angular Material implementation of the Material date picker only seems to display the current month's days, without the trailing days of the previous month and leading days of the next month (if any).
An example of the current UI:
![angularmaterialdatepicker](https://github.com/user-attachments/assets/77815f09-45fb-44ee-963f-9eb0dee5ec50)

However when switching between months, the height of the component changes depending on the alignment of the weeks within the currently viewed month.

![angmatdate](https://github.com/user-attachments/assets/c68d5ac4-faea-4224-ac5a-c14ce156cb44)

This request is for the Angular Material date picker to support displaying the trailing/leading days and maintain a fixed height, which particularly when inline, is much easier to design for when developing a surrounding layout compared to a component that has variable/jumping height.

The Date picker in the Material 3 spec does seem to support this as shown:

![image](https://github.com/user-attachments/assets/eb71e4f6-ea3f-4f60-8b27-7999bb0cc3f9)
(From https://m3.material.io/components/date-pickers/specs)

### Use Case

_No response_

贡献指南

打开贡献指南

调研方向

该 issue 未指明源文件、测试或入口点,因此请先定位 Angular Material 日期选择器的实现及其月份导航行为。将其与链接的 Material 3 规范进行比较,并验证周对齐方式不同的月份会显示相邻月份的日期,同时不会改变组件高度。

由索引模型根据 Issue 内容生成。

评估

技术栈
angular, typescript
领域
design, frontend
Issue 类型
功能
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
45/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。