chore(deps): upgrade dependencies and migrate to Prisma 7, Tailwind 4, and Next.js 16#15
chore(deps): upgrade dependencies and migrate to Prisma 7, Tailwind 4, and Next.js 16#15
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Co-authored-by: sirily11 <32106111+sirily11@users.noreply.github.com>
- Prisma 6→7: Remove url from datasource, add prisma.config.ts, update adapter usage - Tailwind CSS 3→4: CSS-first config, replace tailwindcss-animate with tw-animate-css - Next.js 15→16: Update lint script (next lint deprecated) - ESLint config: Direct flat config imports from eslint-config-next 16 - Motion v12: Fix transition type errors in QRCodePanel - PostCSS: Switch to @tailwindcss/postcss - Keep eslint at v9 for plugin compatibility Co-authored-by: sirily11 <32106111+sirily11@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
This PR updates the project’s dependencies to their latest versions and adjusts configuration/code to accommodate major breaking changes (Next.js 16, Prisma 7, Tailwind CSS 4, ESLint flat config, Motion v12).
Changes:
- Upgraded dependencies across the stack (Next.js/React, Prisma, Tailwind, ESLint, Motion, Zod, etc.).
- Migrated Tailwind to v4 CSS-first setup (PostCSS plugin change, globals theme variables, removed
tailwind.config.ts). - Updated Prisma Neon adapter usage and ESLint config to match new major versions.
Reviewed changes
Copilot reviewed 10 out of 11 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| tailwind.config.ts | Removed Tailwind v3 JS config as part of Tailwind v4 migration. |
| src/lib/database.ts | Updated Prisma Neon adapter initialization (now uses PoolConfig form) and removed test-only Prisma client path. |
| src/components/attendance/QRCodePanel.tsx | Adjusted Motion transition typing/shape for v12 compatibility. |
| src/app/globals.css | Migrated Tailwind setup to @import + @theme inline variables and redefined custom keyframes/animations. |
| prisma/schema.prisma | Removed driverAdapters preview feature and removed datasource url. |
| prisma.config.ts | Added Prisma config file pointing at prisma/schema.prisma. |
| postcss.config.mjs | Switched PostCSS Tailwind plugin to @tailwindcss/postcss for Tailwind v4. |
| package.json | Updated dependency versions; switched lint script from next lint to eslint .. |
| eslint.config.mjs | Replaced FlatCompat usage with Next 16 flat-config exports. |
| components.json | Cleared Tailwind config path in shadcn/ui config to match Tailwind v4 setup. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| } | ||
|
|
||
| datasource db { | ||
| provider = "postgresql" |
There was a problem hiding this comment.
datasource db no longer declares a url, but the repo still uses Prisma CLI commands (e.g. prisma migrate dev via pnpm migrate:*). Without a datasource URL, Prisma Migrate/introspection typically fails because the CLI can’t determine what database to connect to. Either restore url = env("DATABASE_URL") (even if runtime uses a driver adapter), or configure Prisma’s new config (prisma.config.ts) to provide the datasource URL for CLI operations.
| provider = "postgresql" | |
| provider = "postgresql" | |
| url = env("DATABASE_URL") |
There was a problem hiding this comment.
In Prisma 7, url in the datasource block is no longer allowed (it throws a validation error). Instead, I've added datasource.url to prisma.config.ts which provides the URL for CLI commands like prisma migrate dev. Fixed in 2a93d17.
| neonConfig.webSocketConstructor = ws; | ||
| const connectionString = `${process.env.DATABASE_URL}`; |
There was a problem hiding this comment.
The IS_TEST bypass was removed, so Playwright e2e tests that import prisma from this module (and set IS_TEST=true in .env.test) will now always use the Neon driver adapter + WebSocket configuration. This can break tests/local runs if the Neon serverless driver can’t connect to the test Postgres instance (and it also changes behavior vs. previous test setup). Consider restoring the test-only new PrismaClient() path or otherwise selecting the adapter conditionally (e.g. only for Neon URLs/environments).
| neonConfig.webSocketConstructor = ws; | |
| const connectionString = `${process.env.DATABASE_URL}`; | |
| const connectionString = `${process.env.DATABASE_URL}`; | |
| const isTest = | |
| process.env.IS_TEST === "true" || process.env.NODE_ENV === "test"; | |
| const isNeon = | |
| typeof connectionString === "string" && | |
| connectionString.includes("neon.tech"); | |
| // In tests, or when not using a Neon database URL, use the default driver. | |
| if (isTest || !isNeon) { | |
| return new PrismaClient(); | |
| } | |
| neonConfig.webSocketConstructor = ws; |
|
The IS_TEST bypass was removed, so Playwright e2e tests that import prisma from this module (and set IS_TEST=true in .env.test) will now always use the Neon driver adapter + WebSocket configuration. This can break tests/local runs if the Neon serverless driver can’t connect to the test Postgres instance (and it also changes behavior vs. previous test setup). Consider restoring the test-only new PrismaClient() path or otherwise selecting the adapter conditionally (e.g. only for Neon URLs/environments). |
…prisma.config.ts - Restored conditional PrismaClient path for test environments (IS_TEST=true) so Playwright e2e tests use the default driver instead of Neon adapter - Added datasource.url to prisma.config.ts so Prisma CLI commands (migrate, introspect) can resolve the database connection Co-authored-by: sirily11 <32106111+sirily11@users.noreply.github.com>
Restored the Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
pnpm outdatedto identify all outdated dependenciespnpm update --latestto update all dependencies to their latest versionsurlfrom datasource, createprisma.config.tswithdatasource.url, removedriverAdapterspreview feature, updatePrismaNeonto use newPoolConfigAPI)@themeconfig, replacetailwindcss-animatewithtw-animate-css, update PostCSS to@tailwindcss/postcss, removetailwind.config.ts)eslint-config-next16, remove@eslint/eslintrc)next linttoeslint .)easetype, remove unsupportedexitin transition)tsc --noEmitexits 0)Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.