From 603c45d35fd20a8b0c8de146a2eaa37e4e3488a5 Mon Sep 17 00:00:00 2001 From: Michael Winter Date: Mon, 10 Jul 2023 16:59:22 +1000 Subject: [PATCH] add missing deps upgrade --- packages/date-picker/package.json | 4 +-- .../date-picker/src/TimeField/TimeField.tsx | 5 +-- yarn.lock | 36 ------------------- 3 files changed, 5 insertions(+), 40 deletions(-) diff --git a/packages/date-picker/package.json b/packages/date-picker/package.json index 73eb1048de5..5227d3dc463 100644 --- a/packages/date-picker/package.json +++ b/packages/date-picker/package.json @@ -25,7 +25,7 @@ "private": false, "license": "MIT", "dependencies": { - "@internationalized/date": "^3.2.0", + "@internationalized/date": "^3.3.0", "@kaizen/a11y": "^1.7.12", "@kaizen/component-base": "^1.1.7", "@kaizen/component-library": "^16.9.0", @@ -35,7 +35,7 @@ "@popperjs/core": "^2.11.8", "@react-aria/datepicker": "^3.5.0", "@react-aria/i18n": "^3.8.0", - "@react-stately/datepicker": "^3.4.1", + "@react-stately/datepicker": "^3.5.0", "classnames": "^2.3.2", "date-fns": "^2.30.0", "react-day-picker": "8.4.1", diff --git a/packages/date-picker/src/TimeField/TimeField.tsx b/packages/date-picker/src/TimeField/TimeField.tsx index 4a60bdcb466..482b6492753 100644 --- a/packages/date-picker/src/TimeField/TimeField.tsx +++ b/packages/date-picker/src/TimeField/TimeField.tsx @@ -1,5 +1,5 @@ import React from "react" -import { Time } from "@internationalized/date" +import { Time, ZonedDateTime, CalendarDateTime } from "@internationalized/date" import { useTimeField } from "@react-aria/datepicker" import { I18nProvider } from "@react-aria/i18n" import { @@ -70,9 +70,10 @@ const TimeFieldComponent = ({ onChange({ hour: timeValue.hour, minutes: timeValue.minute }) } + const timeValue = value ? new Time(value.hour, value.minutes) : null const state = useTimeFieldState({ ...restProps, - value: value ? new Time(value.hour, value.minutes) : null, + value: timeValue, onChange: handleOnChange, isDisabled, hideTimeZone: true, diff --git a/yarn.lock b/yarn.lock index 86dd98d410c..4f4f18a5c16 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2743,13 +2743,6 @@ resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz#b520529ec21d8e5945a1851dfd1c32e94e39ff45" integrity sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA== -"@internationalized/date@^3.2.0": - version "3.2.0" - resolved "https://registry.yarnpkg.com/@internationalized/date/-/date-3.2.0.tgz#1d266e5e5543a059cf8cca9b954fa033c3e58a75" - integrity sha512-VDMHN1m33L4eqPs5BaihzgQJXyaORbMoHOtrapFxx179J8ucY5CRIHYsq5RRLKPHZWgjNfa5v6amWWDkkMFywA== - dependencies: - "@swc/helpers" "^0.4.14" - "@internationalized/date@^3.3.0": version "3.3.0" resolved "https://registry.yarnpkg.com/@internationalized/date/-/date-3.3.0.tgz#90386d4b4e707f28507d1a1b3cc0e162ad5ee038" @@ -2772,13 +2765,6 @@ dependencies: "@swc/helpers" "^0.5.0" -"@internationalized/string@^3.1.0": - version "3.1.0" - resolved "https://registry.yarnpkg.com/@internationalized/string/-/string-3.1.0.tgz#0b365906a8c3f44800b0db52c2e990cff345abce" - integrity sha512-TJQKiyUb+wyAfKF59UNeZ/kELMnkxyecnyPCnBI1ma4NaXReJW+7Cc2mObXAqraIBJUVv7rgI46RLKrLgi35ng== - dependencies: - "@swc/helpers" "^0.4.14" - "@internationalized/string@^3.1.1": version "3.1.1" resolved "https://registry.yarnpkg.com/@internationalized/string/-/string-3.1.1.tgz#2ab7372d58bbb7ffd3de62fc2a311e4690186981" @@ -3560,19 +3546,6 @@ "@react-types/shared" "^3.18.1" "@swc/helpers" "^0.5.0" -"@react-stately/datepicker@^3.4.1": - version "3.4.1" - resolved "https://registry.yarnpkg.com/@react-stately/datepicker/-/datepicker-3.4.1.tgz#3aaf3b439e542aa9bc0dc366a70f9232247865e6" - integrity sha512-tubL36Pc7H3/agUk3epB9YzVDUgCNhE406cAMpkvFP4Ru4pUC45dKM9FoR4S43vJra7AYfY8lNkFZKkFVJBWVQ== - dependencies: - "@internationalized/date" "^3.2.0" - "@internationalized/string" "^3.1.0" - "@react-stately/overlays" "^3.5.2" - "@react-stately/utils" "^3.6.0" - "@react-types/datepicker" "^3.3.1" - "@react-types/shared" "^3.18.1" - "@swc/helpers" "^0.4.14" - "@react-stately/datepicker@^3.5.0": version "3.5.0" resolved "https://registry.yarnpkg.com/@react-stately/datepicker/-/datepicker-3.5.0.tgz#eb43bf0e842e69c3390df3933869bf27fb337609" @@ -3753,15 +3726,6 @@ dependencies: "@react-types/shared" "^3.18.1" -"@react-types/datepicker@^3.3.1": - version "3.3.1" - resolved "https://registry.yarnpkg.com/@react-types/datepicker/-/datepicker-3.3.1.tgz#035451586577077a65b89ee739bd1e29a777a28b" - integrity sha512-kVZ9j3PovXjTIeQrq4YiURS48Rsp5Uc81/HumZyrTWtYtYSKAU0U0ifiTuPeJ044tfpi3wGkitJ5wtt8j5imKQ== - dependencies: - "@internationalized/date" "^3.2.0" - "@react-types/overlays" "^3.7.2" - "@react-types/shared" "^3.18.1" - "@react-types/datepicker@^3.4.0": version "3.4.0" resolved "https://registry.yarnpkg.com/@react-types/datepicker/-/datepicker-3.4.0.tgz#f1fea1b2e9fc963724193ae7b58ce49b58153c59"