ionic-team / ionic-team/ionic-framework
bug: ion-datetime after canceling and reopening the date shows incorrectly
- 主要语言
- TypeScript
- 星标
- 52.7k
- 派生
- 13.3k
- 平均合并
- 1 天 14 小时
- 30 天内合并 PR
- 50
描述
### Prerequisites
- [x] I have read the [Contributing Guidelines](https://github.com/ionic-team/ionic-framework/blob/main/docs/CONTRIBUTING.md#creating-an-issue).
- [x] I agree to follow the [Code of Conduct](https://ionicframework.com/code-of-conduct).
- [x] I have searched for [existing issues](https://github.com/ionic-team/ionic-framework/issues) that already report this problem, without success.
### Ionic Framework Version
v8.x
### Current Behavior
After canceling out of a datetime component and reopening the view you see the incorrect date displayed as selected even though the value is the correct one.
### Expected Behavior
After canceling out of the datetime view and reopening it the active date should show the actual value and not the canceled one.
### Steps to Reproduce
1. open the datetime view and select a new date and click ok. the button shows correctly
2. reopen the datetime view and select another date but click on cancel this time. the button still shows correctly.
3. reopen the datetime view you see the incorrect date displayed as selected even though the button shows the correct one (and the underlying value is the correct one).
### Code Reproduction URL
https://stackblitz.com/edit/invgnexq
### Ionic Info
Ionic:
Ionic CLI : 7.2.1 (/usr/local/lib/node_modules/@ionic/cli)
Ionic Framework : @ionic/angular 8.7.9
@angular-devkit/build-angular : 20.3.9
@angular-devkit/schematics : 20.3.9
@angular/cli : 20.3.9
@ionic/angular-toolkit : 12.3.0
Capacitor:
Capacitor CLI : 7.4.4
@capacitor/android : not installed
@capacitor/core : 7.4.4
@capacitor/ios : not installed
Utility:
cordova-res : not installed globally
native-run : 2.0.1
System:
NodeJS : v22.19.0 (/usr/local/bin/node)
npm : 11.6.2
OS : macOS Unknown
### Additional Information
_No response_
贡献指南
调研方向
首先运行链接的 StackBlitz 复现,并执行 issue 中描述的 ion-datetime 取消并重新打开流程。跟踪 ion-datetime 的实现,以及针对所选日期和取消行为的现有覆盖情况;完成的标准是重新打开时显示底层值,而不是已取消的日期。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- angular, typescript
- 领域
- frontend
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 48/100