bug: ion-datetime presentation="date" emits `YYYY-MM-DDTHH:mm:00` (the current wall-clock time) instead of a date-only value
Maintainer antworten meist innerhalb von 1 Tag
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Anfängerfreundlichkeit
- 74/100
- Issue-Typ
- Bug
- Klarheit
- Klar beschrieben
- Aktivitätsstatus
- Aktiv
- Tech-Stack
- typescript
- Bereich
- frontend
Rechercherichtung
Start in core/src/components/datetime/datetime.tsx and trace how todayParts and defaultParts feed the selected date; then inspect convertDataToISO in utils/manipulation.ts. Check the date-only behavior against the documented presentation="date" format and run the relevant datetime tests. Done means selecting a day emits YYYY-MM-DD without a time.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Ionic Framework Version
v9.x (9.0.7)
Current Behavior
<ion-datetime presentation="date"> with no initial value: clicking a day emits
ionChange detail.value = "2026-09-01T16:19:00"
at 16:19 local time, and datetime.value reads the same string. The time part is whatever the clock showed when the component initialised.
Where it comes from (core/src/components/datetime/datetime.tsx):
- L1529
this.todayParts = parseDate(getToday())—getToday()(utils/data.tsL27–46) returns a full ISO timestamp, so the parts carryhour/minute; - L1534
defaultPartsis derived from them, and selecting a day keeps thosehour/minutefields; convertDataToISO(utils/manipulation.tsL37–40) appendsT${hour}:${minute}:00wheneverhour !== undefined, regardless ofpresentation.
A backend DateOnly / date column rejects the value, and the same picker opened on two days produces two different strings for the same date.
Expected Behavior
presentation="date" emits YYYY-MM-DD (the format the docs describe for a date-only picker and the one min/max accept).
Steps to Reproduce
<ion-datetime presentation="date"></ion-datetime>with novalue.- Click any enabled day.
- Read
event.detail.valueinionChange.
Ionic Info
@ionic/core 9.0.7, Chromium 142 (Playwright headless).
- Vorherrschende Sprache
- TypeScript
- Sterne
- 52.7k
- Forks
- 13.3k
- Ø Merge
- 3 T. 4 Std.
- Gemergte PRs (30 T.)
- 72
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus ionic-team/ionic-framework
-
bug: input-otp, backspace in an empty box only moves focus instead of clearing the previous boxEvtl. vergeben @sarankumar1325 hat das vor 9 Tagen übernommen. Offenpackage: core type: bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 90/100
ionic-team/ionic-framework#31639 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
bug: vue swipe cancellation throws when the previous page is missingEvtl. vergeben @dandoingdev hat das vor 32 Tagen übernommen. Offenpackage: vue type: bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
ionic-team/ionic-framework#31514 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
bug: ion-searchbar input is always labelled "search text"; aria-label on the host is not forwardedEvtl. vergeben @HappyKnuckles hat das vor 27 Tagen übernommen. Offena11y package: core type: bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 84/100
ionic-team/ionic-framework#31492 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
bug: IonTabs throws when a Fragment contains one IonRouterOutletEvtl. vergeben @Benziza hat das vor 68 Tagen übernommen. Offenpackage: react type: bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
ionic-team/ionic-framework#31410 · 2 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
-
package: angular type: bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 86/100
ionic-team/ionic-framework#31291 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in ionic-team/ionic-framework
Ähnliche Issues
-
Remove unused dependenciesEvtl. vergeben @alastair-smith hat das heute übernommen. Offenchore other
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
alastair-smith/card-games#384 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 62/100
code-yeongyu/senpi#5571 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
nexu-io/open-design#9262 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
friction
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
kentcdodds/kody#4753 ·
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 62/100
lingdojo/kana-dojo#33508 · 1 Kommentar · 5 Reaktionen ·
Maintainer antworten meist innerhalb von 1 Tag