Skip to content
This repository has been archived by the owner on Nov 21, 2023. It is now read-only.

fix: datepicker single mode onchange not firing #96

Merged
merged 2 commits into from
Oct 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/wicked-pans-speak.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@medusajs/ui": patch
---

fix(ui): Fix issue that was preventing onChange from firing in DatePicker single mode
6 changes: 3 additions & 3 deletions packages/ui/src/components/date-picker/date-picker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -328,10 +328,10 @@ const SingleDatePicker = ({
newDate.setHours(time.hour)
newDate.setMinutes(time.minute)
}

setDate(newDate)
onChange?.(newDate)
}

setDate(newDate)
onChange?.(newDate)
}

const onTimeChange = (time: TimeValue) => {
Expand Down
10 changes: 5 additions & 5 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -7612,7 +7612,7 @@ __metadata:

"class-variance-authority@patch:class-variance-authority@npm%3A0.6.1#./.yarn/patches/class-variance-authority-npm-0.6.1-22a468e86e.patch::locator=medusa-ui%40workspace%3A.":
version: 0.6.1
resolution: "class-variance-authority@patch:class-variance-authority@npm%3A0.6.1#./.yarn/patches/class-variance-authority-npm-0.6.1-22a468e86e.patch::version=0.6.1&hash=4a9eff&locator=medusa-ui%40workspace%3A."
resolution: "class-variance-authority@patch:class-variance-authority@npm%3A0.6.1#./.yarn/patches/class-variance-authority-npm-0.6.1-22a468e86e.patch::version=0.6.1&hash=1b9fe4&locator=medusa-ui%40workspace%3A."
dependencies:
clsx: 1.2.1
checksum: 095af67867a627d20fcd214172afbd4a25350f7852078f1966d74692926c5832e2a20c8746724d514dbeab210252e82775bff2257fcf8e40f99c3d6e5fcfc445
Expand Down Expand Up @@ -9777,7 +9777,7 @@ __metadata:

"fsevents@patch:fsevents@^2.3.2#~builtin<compat/fsevents>, fsevents@patch:fsevents@~2.3.2#~builtin<compat/fsevents>":
version: 2.3.2
resolution: "fsevents@patch:fsevents@npm%3A2.3.2#~builtin<compat/fsevents>::version=2.3.2&hash=18f3a7"
resolution: "fsevents@patch:fsevents@npm%3A2.3.2#~builtin<compat/fsevents>::version=2.3.2&hash=df0bf1"
dependencies:
node-gyp: latest
conditions: os=darwin
Expand Down Expand Up @@ -13835,7 +13835,7 @@ __metadata:

"resolve@patch:resolve@^1.1.7#~builtin<compat/resolve>, resolve@patch:resolve@^1.10.0#~builtin<compat/resolve>, resolve@patch:resolve@^1.14.2#~builtin<compat/resolve>, resolve@patch:resolve@^1.17.0#~builtin<compat/resolve>, resolve@patch:resolve@^1.22.1#~builtin<compat/resolve>, resolve@patch:resolve@^1.22.2#~builtin<compat/resolve>":
version: 1.22.4
resolution: "resolve@patch:resolve@npm%3A1.22.4#~builtin<compat/resolve>::version=1.22.4&hash=07638b"
resolution: "resolve@patch:resolve@npm%3A1.22.4#~builtin<compat/resolve>::version=1.22.4&hash=c3c19d"
dependencies:
is-core-module: ^2.13.0
path-parse: ^1.0.7
Expand All @@ -13848,7 +13848,7 @@ __metadata:

"resolve@patch:resolve@^2.0.0-next.4#~builtin<compat/resolve>":
version: 2.0.0-next.4
resolution: "resolve@patch:resolve@npm%3A2.0.0-next.4#~builtin<compat/resolve>::version=2.0.0-next.4&hash=07638b"
resolution: "resolve@patch:resolve@npm%3A2.0.0-next.4#~builtin<compat/resolve>::version=2.0.0-next.4&hash=c3c19d"
dependencies:
is-core-module: ^2.9.0
path-parse: ^1.0.7
Expand Down Expand Up @@ -15581,7 +15581,7 @@ __metadata:

"typescript@patch:typescript@5.1.6#~builtin<compat/typescript>, typescript@patch:typescript@^5.1.6#~builtin<compat/typescript>":
version: 5.1.6
resolution: "typescript@patch:typescript@npm%3A5.1.6#~builtin<compat/typescript>::version=5.1.6&hash=7ad353"
resolution: "typescript@patch:typescript@npm%3A5.1.6#~builtin<compat/typescript>::version=5.1.6&hash=77c9e2"
bin:
tsc: bin/tsc
tsserver: bin/tsserver
Expand Down
Loading