Skip to content

Conversation

@GuillaumeRx
Copy link
Contributor

@GuillaumeRx GuillaumeRx commented Oct 24, 2025

Adds a new DateTimePicker component


Note

Introduces a new DateTimePicker JSX component (with ISO 8601 validation), adds simulation/Jest support via pickDateTime, integrates in controllers/state, and showcases it in the interactive UI example.

  • SDK / JSX:
    • Add DateTimePicker component (jsx/components/form/DateTimePicker.ts) with tests and validation (DateTimePickerStruct).
    • Introduce ISO8601DateStruct in internals/time (using luxon) and export via SDK; update validation to use it.
    • Update Field and form typings/exports to include DateTimePicker.
    • Add luxon dependency and types.
  • Controllers:
    • Treat DateTimePicker as stateful in interface utils; support default/state construction in forms and root.
  • Simulation / Jest:
    • Add pickDateTime action across simulation API and handler interfaces; wire events/state updates; extensive tests.
    • Expose pickDateTime in Jest helpers and mock interface responses.
  • RPC Methods:
    • Extend snap_createInterface validation/error messages to allow DateTimePicker.
  • Examples:
    • Update interactive UI example to include Date/Time/DateTime pickers and tests asserting ISO strings.
  • Execution Environments:
    • Update LavaMoat policies to allow @metamask/snaps-sdk>luxon and Intl.
  • Utils:
    • Move ISO date validation to SDK; snaps-utils/time now re-exports ISO8601DateStruct and retains duration utilities.
  • Manifests/Lockfile:
    • Update example snap shasum; lockfile reflects new luxon and types.

Written by Cursor Bugbot for commit 85563a0. This will update automatically on new commits. Configure here.

@GuillaumeRx GuillaumeRx force-pushed the gr/datetime-picker branch 2 times, most recently from c60d86e to fcfa7f6 Compare October 27, 2025 11:11
@codecov
Copy link

codecov bot commented Nov 27, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.28%. Comparing base (9392ef9) to head (85563a0).
⚠️ Report is 4 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3698   +/-   ##
=======================================
  Coverage   98.28%   98.28%           
=======================================
  Files         418      420    +2     
  Lines       12186    12211   +25     
  Branches     1887     1889    +2     
=======================================
+ Hits        11977    12002   +25     
  Misses        209      209           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@GuillaumeRx GuillaumeRx marked this pull request as ready for review November 27, 2025 13:46
@GuillaumeRx GuillaumeRx requested a review from a team as a code owner November 27, 2025 13:46
@GuillaumeRx GuillaumeRx added this pull request to the merge queue Dec 2, 2025
Merged via the queue into main with commit fc9ab36 Dec 2, 2025
121 checks passed
@GuillaumeRx GuillaumeRx deleted the gr/datetime-picker branch December 2, 2025 13:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants