From 0b055623a0809682a54dbc69c76ea232f579bc7d Mon Sep 17 00:00:00 2001 From: Waleed Latif Date: Fri, 16 May 2025 10:48:29 -0700 Subject: [PATCH] fix(ui): fix calendar component for setting schedules --- apps/sim/components/ui/calendar.tsx | 12 ++++-------- apps/sim/package.json | 4 ++-- package-lock.json | 27 +++++++++++++++++++++------ package.json | 3 ++- 4 files changed, 29 insertions(+), 17 deletions(-) diff --git a/apps/sim/components/ui/calendar.tsx b/apps/sim/components/ui/calendar.tsx index d351a467ca..d1713131b2 100644 --- a/apps/sim/components/ui/calendar.tsx +++ b/apps/sim/components/ui/calendar.tsx @@ -46,15 +46,11 @@ function Calendar({ className, classNames, showOutsideDays = true, ...props }: C ...classNames, }} components={{ - PreviousMonthButton: ({ ...props }) => ( - + IconLeft: ({ className, ...props }) => ( + ), - NextMonthButton: ({ ...props }) => ( - + IconRight: ({ className, ...props }) => ( + ), }} {...props} diff --git a/apps/sim/package.json b/apps/sim/package.json index 6af6cc3868..9e2eb787f7 100644 --- a/apps/sim/package.json +++ b/apps/sim/package.json @@ -59,7 +59,7 @@ "@radix-ui/react-select": "^2.1.4", "@radix-ui/react-separator": "^1.1.2", "@radix-ui/react-slider": "^1.2.2", - "@radix-ui/react-slot": "^1.1.2", + "@radix-ui/react-slot": "^1.2.2", "@radix-ui/react-switch": "^1.1.2", "@radix-ui/react-tabs": "^1.1.2", "@radix-ui/react-toggle": "^1.1.2", @@ -95,7 +95,7 @@ "postgres": "^3.4.5", "prismjs": "^1.30.0", "react": "19.1.0", - "react-day-picker": "^9.4.2", + "react-day-picker": "^8.10.1", "react-dom": "19.1.0", "react-google-drive-picker": "^1.2.2", "react-hook-form": "^7.54.2", diff --git a/package-lock.json b/package-lock.json index 7b178333af..02e7098f34 100644 --- a/package-lock.json +++ b/package-lock.json @@ -13,7 +13,8 @@ "packages/*" ], "dependencies": { - "@vercel/analytics": "^1.5.0" + "@vercel/analytics": "^1.5.0", + "react-day-picker": "^9.7.0" }, "devDependencies": { "@next/env": "^15.3.2", @@ -88,7 +89,7 @@ "@radix-ui/react-select": "^2.1.4", "@radix-ui/react-separator": "^1.1.2", "@radix-ui/react-slider": "^1.2.2", - "@radix-ui/react-slot": "^1.1.2", + "@radix-ui/react-slot": "^1.2.2", "@radix-ui/react-switch": "^1.1.2", "@radix-ui/react-tabs": "^1.1.2", "@radix-ui/react-toggle": "^1.1.2", @@ -124,7 +125,7 @@ "postgres": "^3.4.5", "prismjs": "^1.30.0", "react": "19.1.0", - "react-day-picker": "^9.4.2", + "react-day-picker": "^8.10.1", "react-dom": "19.1.0", "react-google-drive-picker": "^1.2.2", "react-hook-form": "^7.54.2", @@ -177,6 +178,20 @@ "undici-types": "~6.19.2" } }, + "apps/sim/node_modules/react-day-picker": { + "version": "8.10.1", + "resolved": "https://registry.npmjs.org/react-day-picker/-/react-day-picker-8.10.1.tgz", + "integrity": "sha512-TMx7fNbhLk15eqcMt+7Z7S2KF7mfTId/XJDjKE8f+IUcFn0l08/kI4FiYTL/0yuOLmEcbR4Fwe3GJf/NiiMnPA==", + "license": "MIT", + "funding": { + "type": "individual", + "url": "https://github.com/sponsors/gpbl" + }, + "peerDependencies": { + "date-fns": "^2.28.0 || ^3.0.0", + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + } + }, "apps/sim/node_modules/tailwind-merge": { "version": "2.6.0", "resolved": "https://registry.npmjs.org/tailwind-merge/-/tailwind-merge-2.6.0.tgz", @@ -19812,9 +19827,9 @@ } }, "node_modules/react-day-picker": { - "version": "9.6.7", - "resolved": "https://registry.npmjs.org/react-day-picker/-/react-day-picker-9.6.7.tgz", - "integrity": "sha512-rCSt6X8FXQWpjykns/azRXjJk3cMSzkzGbDEXuEveFGNZgOjZULdJQ5wsu8Zfyo8ZgPBoYCBKQ5wRrgJfhJGbg==", + "version": "9.7.0", + "resolved": "https://registry.npmjs.org/react-day-picker/-/react-day-picker-9.7.0.tgz", + "integrity": "sha512-urlK4C9XJZVpQ81tmVgd2O7lZ0VQldZeHzNejbwLWZSkzHH498KnArT0EHNfKBOWwKc935iMLGZdxXPRISzUxQ==", "license": "MIT", "dependencies": { "@date-fns/tz": "1.2.0", diff --git a/package.json b/package.json index 7de83eeeb9..0dc328f515 100644 --- a/package.json +++ b/package.json @@ -29,6 +29,7 @@ "react-dom": "19.1.0" }, "dependencies": { - "@vercel/analytics": "^1.5.0" + "@vercel/analytics": "^1.5.0", + "react-day-picker": "^9.7.0" } }