mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-11-10 00:27:41 +08:00
fix(datetime): recalculate time columns on change (#18380)
This commit is contained in:
@ -270,12 +270,6 @@ export class Datetime implements ComponentInterface {
|
|||||||
picker.addEventListener('ionPickerColChange', async (event: any) => {
|
picker.addEventListener('ionPickerColChange', async (event: any) => {
|
||||||
const data = event.detail;
|
const data = event.detail;
|
||||||
|
|
||||||
/**
|
|
||||||
* Don't bother checking for non-dates as things like hours or minutes
|
|
||||||
* are always going to have the same number of column options
|
|
||||||
*/
|
|
||||||
if (data.name !== 'month' && data.name !== 'day' && data.name !== 'year') { return; }
|
|
||||||
|
|
||||||
const colSelectedIndex = data.selectedIndex;
|
const colSelectedIndex = data.selectedIndex;
|
||||||
const colOptions = data.options;
|
const colOptions = data.options;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user