Skip to content

Commit eff6aad

Browse files
committed
update to latest payload
1 parent 0cf2c45 commit eff6aad

File tree

8 files changed

+64
-67
lines changed

8 files changed

+64
-67
lines changed

payload-integration/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ There are two directories:
77
- `medusa` for the Medusa Application code. You can [install and use it](#installation), or [copy its source files into an existing Medusa application](#copy-into-existing-medusa-application).
88
- `storefront` for the Next.js Starter storefront with Payload integration.
99

10+
> Note: This integration was built with Payload v3.54.0. If you face any issues with newer versions, please open an issue.
11+
1012
## Prerequisites
1113

1214
- [Node.js v20+](https://nodejs.org/en/download)

payload-integration/storefront/package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,15 @@
1919
"@headlessui/react": "^2.2.0",
2020
"@medusajs/js-sdk": "latest",
2121
"@medusajs/ui": "latest",
22-
"@payloadcms/db-postgres": "^3.49.1",
23-
"@payloadcms/next": "^3.49.1",
24-
"@payloadcms/richtext-lexical": "^3.49.1",
22+
"@payloadcms/db-postgres": "^3.54.0",
23+
"@payloadcms/next": "^3.54.0",
24+
"@payloadcms/richtext-lexical": "^3.54.0",
2525
"@radix-ui/react-accordion": "^1.2.1",
2626
"@stripe/react-stripe-js": "^1.7.2",
2727
"@stripe/stripe-js": "^1.29.0",
2828
"lodash": "^4.17.21",
2929
"next": "^15.3.1",
30-
"payload": "^3.49.1",
30+
"payload": "^3.54.0",
3131
"pg": "^8.11.3",
3232
"qs": "^6.12.1",
3333
"react": "19.0.0-rc-66855b96-20241106",

payload-integration/storefront/src/app/(payload)/admin/[[...segments]]/not-found.tsx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@
33
import type { Metadata } from 'next'
44

55
import config from '@payload-config'
6-
import { generatePageMetadata, NotFoundPage } from '@payloadcms/next/views'
7-
8-
import { importMap } from '../importMap.js'
6+
import { NotFoundPage, generatePageMetadata } from '@payloadcms/next/views'
7+
import { importMap } from '../importMap'
98

109
type Args = {
1110
params: Promise<{
@@ -20,6 +19,6 @@ export const generateMetadata = ({ params, searchParams }: Args): Promise<Metada
2019
generatePageMetadata({ config, params, searchParams })
2120

2221
const NotFound = ({ params, searchParams }: Args) =>
23-
NotFoundPage({ config, importMap, params, searchParams })
22+
NotFoundPage({ config, params, searchParams, importMap })
2423

2524
export default NotFound

payload-integration/storefront/src/app/(payload)/admin/[[...segments]]/page.tsx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@
33
import type { Metadata } from 'next'
44

55
import config from '@payload-config'
6-
import { generatePageMetadata, RootPage } from '@payloadcms/next/views'
7-
8-
import { importMap } from '../importMap.js'
6+
import { RootPage, generatePageMetadata } from '@payloadcms/next/views'
7+
import { importMap } from '../importMap'
98

109
type Args = {
1110
params: Promise<{
@@ -20,6 +19,6 @@ export const generateMetadata = ({ params, searchParams }: Args): Promise<Metada
2019
generatePageMetadata({ config, params, searchParams })
2120

2221
const Page = ({ params, searchParams }: Args) =>
23-
RootPage({ config, importMap, params, searchParams })
22+
RootPage({ config, params, searchParams, importMap })
2423

2524
export default Page
Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,19 @@
11
/* THIS FILE WAS GENERATED AUTOMATICALLY BY PAYLOAD. */
22
/* DO NOT MODIFY IT BECAUSE IT COULD BE REWRITTEN AT ANY TIME. */
33
import config from '@payload-config'
4-
import { REST_DELETE, REST_GET, REST_OPTIONS, REST_PATCH, REST_POST } from '@payloadcms/next/routes'
4+
import '@payloadcms/next/css'
5+
import {
6+
REST_DELETE,
7+
REST_GET,
8+
REST_OPTIONS,
9+
REST_PATCH,
10+
REST_POST,
11+
REST_PUT,
12+
} from '@payloadcms/next/routes'
513

614
export const GET = REST_GET(config)
715
export const POST = REST_POST(config)
816
export const DELETE = REST_DELETE(config)
917
export const PATCH = REST_PATCH(config)
18+
export const PUT = REST_PUT(config)
1019
export const OPTIONS = REST_OPTIONS(config)
Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +0,0 @@
1-
#custom-css {
2-
font-family: monospace;
3-
background-image: url('/placeholder.png');
4-
}
5-
6-
#custom-css::after {
7-
content: 'custom-css';
8-
}

payload-integration/storefront/src/app/(payload)/layout.tsx

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
/* THIS FILE WAS GENERATED AUTOMATICALLY BY PAYLOAD. */
22
/* DO NOT MODIFY IT BECAUSE IT COULD BE REWRITTEN AT ANY TIME. */
3-
import '@payloadcms/ui/styles.css' // Uncomment this line if `@payloadcms/ui` in `tsconfig.json` points to `/ui/dist` instead of `/ui/src`
3+
import config from '@payload-config'
44
import '@payloadcms/next/css'
55
import type { ServerFunctionClient } from 'payload'
6-
7-
import config from '@payload-config'
86
import { handleServerFunctions, RootLayout } from '@payloadcms/next/layouts'
97
import React from 'react'
108

@@ -24,12 +22,10 @@ const serverFunction: ServerFunctionClient = async function (args) {
2422
})
2523
}
2624

27-
const Layout = ({ children }: Args) => {
28-
return (
25+
const Layout = ({ children }: Args) => (
2926
<RootLayout config={config} importMap={importMap} serverFunction={serverFunction}>
3027
{children}
3128
</RootLayout>
3229
)
33-
}
3430

3531
export default Layout

payload-integration/storefront/yarn.lock

Lines changed: 40 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1550,12 +1550,12 @@
15501550
resolved "https://registry.yarnpkg.com/@nolyfill/is-core-module/-/is-core-module-1.0.39.tgz#3dc35ba0f1e66b403c00b39344f870298ebb1c8e"
15511551
integrity sha512-nn5ozdjYQpUCZlWGuxcJY/KpxkWQs4DcbMCmKojjyrYDEAGy4Ce19NN4v5MduafTwJlbKc99UA8YhSVqq9yPZA==
15521552

1553-
"@payloadcms/db-postgres@^3.49.1":
1554-
version "3.49.1"
1555-
resolved "https://registry.yarnpkg.com/@payloadcms/db-postgres/-/db-postgres-3.49.1.tgz#c87c5e60583ce7f40c3f88f5b81b1a9ff980c525"
1556-
integrity sha512-ytrMLrw796Z95yCAGaFIDl2YPYvkAAC9VcoErFgQ/ItgsB97X++ZnxpWljkN1flSVzbI5ZYPm/pq6vAN1VDbKg==
1553+
"@payloadcms/db-postgres@^3.54.0":
1554+
version "3.54.0"
1555+
resolved "https://registry.yarnpkg.com/@payloadcms/db-postgres/-/db-postgres-3.54.0.tgz#0d97da4ce7f920cc28b1ed53c877f93224c298de"
1556+
integrity sha512-C1tADNHHRTfXyJ6UXTPrHhDVji8kQFKPmT3R/LxOfXwMX5SQanfGx4dGotug647EuZCLgP9YH/ASmGgSFG2RjQ==
15571557
dependencies:
1558-
"@payloadcms/drizzle" "3.49.1"
1558+
"@payloadcms/drizzle" "3.54.0"
15591559
"@types/pg" "8.10.2"
15601560
console-table-printer "2.12.1"
15611561
drizzle-kit "0.31.4"
@@ -1565,10 +1565,10 @@
15651565
to-snake-case "1.0.0"
15661566
uuid "10.0.0"
15671567

1568-
"@payloadcms/drizzle@3.49.1":
1569-
version "3.49.1"
1570-
resolved "https://registry.yarnpkg.com/@payloadcms/drizzle/-/drizzle-3.49.1.tgz#35cd45fe9d261a11bbad00df50cb0633db66bd98"
1571-
integrity sha512-rOrmhWvsRO08tPuea2fNHf+cKwVwF6CuDhouJ5XouXgIzR0gyS1ryc/dmvSP/COFknObo52TQFHnb2oJm1Rifw==
1568+
"@payloadcms/drizzle@3.54.0":
1569+
version "3.54.0"
1570+
resolved "https://registry.yarnpkg.com/@payloadcms/drizzle/-/drizzle-3.54.0.tgz#4de99dedcf0dd11610bf956b61be127a9dfb87e1"
1571+
integrity sha512-nz3luQKWav/CGfPKIRMl9lwmgs11HYWvlTpsGUnni8/cJl4EZgi05/Z4yLz3T6RJLbzyCpqvV1D+8tmdRPIHBw==
15721572
dependencies:
15731573
console-table-printer "2.12.1"
15741574
dequal "2.0.3"
@@ -1577,25 +1577,25 @@
15771577
to-snake-case "1.0.0"
15781578
uuid "9.0.0"
15791579

1580-
"@payloadcms/graphql@3.49.1":
1581-
version "3.49.1"
1582-
resolved "https://registry.yarnpkg.com/@payloadcms/graphql/-/graphql-3.49.1.tgz#c782e095c4078faf2b30d383ce99de91796faf67"
1583-
integrity sha512-L0FFRbYeVrVV5eFScJFKqxgxCsFGPnyjr0RThr159ZNO8JU43s9tLRwPbOxTPKjBIg7haoms/0zf+d6D+cTi5w==
1580+
"@payloadcms/graphql@3.54.0":
1581+
version "3.54.0"
1582+
resolved "https://registry.yarnpkg.com/@payloadcms/graphql/-/graphql-3.54.0.tgz#5601060835621c4bfa3e299824e06e6e871f11ad"
1583+
integrity sha512-ODHig9spx8EN0GSp74PSKtDby+lDrZRh1M93AuPZNblheVs5SBuxzsyz5XmZhM8s70F/zn3h4CmGmGDEiSDr3w==
15841584
dependencies:
15851585
graphql-scalars "1.22.2"
15861586
pluralize "8.0.0"
15871587
ts-essentials "10.0.3"
15881588
tsx "4.19.2"
15891589

1590-
"@payloadcms/next@^3.49.1":
1591-
version "3.49.1"
1592-
resolved "https://registry.yarnpkg.com/@payloadcms/next/-/next-3.49.1.tgz#a6c3b9fc3a5c5792548b131efdaa8ee9fdaca4b9"
1593-
integrity sha512-UoMm9QKrs4nyWn9alDFHeqwG38syVh8RKZZcHPvXABBr9cD7Tw+tPLyZwXh5BBnFzrWDuwRJxfJLG6Bcsn6cbw==
1590+
"@payloadcms/next@^3.54.0":
1591+
version "3.54.0"
1592+
resolved "https://registry.yarnpkg.com/@payloadcms/next/-/next-3.54.0.tgz#4a6976d7db4463f3303477bf3c8bd04db5ca633c"
1593+
integrity sha512-LgOvV4VIRlgyfp9sIBMg5llWfZMnMUmOwDbpq9n7tGAUhSb7MoOFfnEoGyAONHHJhH3/No8vtvpDGRpbFX9UJw==
15941594
dependencies:
15951595
"@dnd-kit/core" "6.0.8"
1596-
"@payloadcms/graphql" "3.49.1"
1597-
"@payloadcms/translations" "3.49.1"
1598-
"@payloadcms/ui" "3.49.1"
1596+
"@payloadcms/graphql" "3.54.0"
1597+
"@payloadcms/translations" "3.54.0"
1598+
"@payloadcms/ui" "3.54.0"
15991599
busboy "^1.6.0"
16001600
dequal "2.0.3"
16011601
file-type "19.3.0"
@@ -1607,10 +1607,10 @@
16071607
sass "1.77.4"
16081608
uuid "10.0.0"
16091609

1610-
"@payloadcms/richtext-lexical@^3.49.1":
1611-
version "3.49.1"
1612-
resolved "https://registry.yarnpkg.com/@payloadcms/richtext-lexical/-/richtext-lexical-3.49.1.tgz#2e8d48d1870906340cb1450bfbacdafba9a9243f"
1613-
integrity sha512-/Oa3VqaQvKryrOGTPQx8U18q7HcRbVpRW/yqZnQRLwOYE5jTR/6TVPQIb7sYdOxm+7u+S982h4AIGvOSpCFD5w==
1610+
"@payloadcms/richtext-lexical@^3.54.0":
1611+
version "3.54.0"
1612+
resolved "https://registry.yarnpkg.com/@payloadcms/richtext-lexical/-/richtext-lexical-3.54.0.tgz#188e0d8f06a7bf538421a0bde3c9095bfea267b4"
1613+
integrity sha512-qyd3FQqj41zNE7eaIxkhAvQuX96FK5dfCF7bODQyT1Wb5R8OUKyM6tPVqUzuvo8Iz17xM0UqnNNaCjwKrxLj6Q==
16141614
dependencies:
16151615
"@lexical/headless" "0.28.0"
16161616
"@lexical/html" "0.28.0"
@@ -1622,8 +1622,8 @@
16221622
"@lexical/selection" "0.28.0"
16231623
"@lexical/table" "0.28.0"
16241624
"@lexical/utils" "0.28.0"
1625-
"@payloadcms/translations" "3.49.1"
1626-
"@payloadcms/ui" "3.49.1"
1625+
"@payloadcms/translations" "3.54.0"
1626+
"@payloadcms/ui" "3.54.0"
16271627
"@types/uuid" "10.0.0"
16281628
acorn "8.12.1"
16291629
bson-objectid "2.0.4"
@@ -1640,17 +1640,17 @@
16401640
ts-essentials "10.0.3"
16411641
uuid "10.0.0"
16421642

1643-
"@payloadcms/translations@3.49.1":
1644-
version "3.49.1"
1645-
resolved "https://registry.yarnpkg.com/@payloadcms/translations/-/translations-3.49.1.tgz#35fc951edbe58bfdb24747b0533e312c5d79c89a"
1646-
integrity sha512-1i+gTnAADoWNvpPA8ojXBTdEeU4moQdQ92KyXQ2E9tI6CNUj+iiDlb29dSkqM+UvdwKSrNDm+6nXy6gcJG+3kw==
1643+
"@payloadcms/translations@3.54.0":
1644+
version "3.54.0"
1645+
resolved "https://registry.yarnpkg.com/@payloadcms/translations/-/translations-3.54.0.tgz#65f4929b2b9eb7e595d893f9bc27678004b53222"
1646+
integrity sha512-21DQ0LaM+6PljjuV8fVdfXq/Icpdaj9kzT3tOoVZumUtiqBYzYU//oVBe2z17lLcoJTRwaG+RK1Pq2oGY1lR1A==
16471647
dependencies:
16481648
date-fns "4.1.0"
16491649

1650-
"@payloadcms/ui@3.49.1":
1651-
version "3.49.1"
1652-
resolved "https://registry.yarnpkg.com/@payloadcms/ui/-/ui-3.49.1.tgz#0e48445145c04854463491bf6dbd41ba3921f55f"
1653-
integrity sha512-4T5Jv3OSQ/Co4vRT3F95tDxc+qDxUmuosIpXeyqakKAyxG75BX042QrC11AHVoSk5JsCg2LP6INuFGL3Kd/XHg==
1650+
"@payloadcms/ui@3.54.0":
1651+
version "3.54.0"
1652+
resolved "https://registry.yarnpkg.com/@payloadcms/ui/-/ui-3.54.0.tgz#83e5a7b03e1eae957373cf128c979d0336e05e22"
1653+
integrity sha512-Io+kUZ41gtFwAhAlLjWXqBww5pGv1h6a6Lbv4wNhOojYi0U9yAir4ddDdnkTs7UAmQlxXEQeQYbQ7z/CmdKHrA==
16541654
dependencies:
16551655
"@date-fns/tz" "1.2.0"
16561656
"@dnd-kit/core" "6.0.8"
@@ -1660,7 +1660,7 @@
16601660
"@faceless-ui/scroll-info" "2.0.0"
16611661
"@faceless-ui/window-info" "3.0.1"
16621662
"@monaco-editor/react" "4.7.0"
1663-
"@payloadcms/translations" "3.49.1"
1663+
"@payloadcms/translations" "3.54.0"
16641664
bson-objectid "2.0.4"
16651665
date-fns "4.1.0"
16661666
dequal "2.0.3"
@@ -7107,13 +7107,13 @@ path-type@^4.0.0:
71077107
resolved "https://registry.yarnpkg.com/path-type/-/path-type-4.0.0.tgz#84ed01c0a7ba380afe09d90a8c180dcd9d03043b"
71087108
integrity sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==
71097109

7110-
payload@^3.49.1:
7111-
version "3.49.1"
7112-
resolved "https://registry.yarnpkg.com/payload/-/payload-3.49.1.tgz#2e836a347a367e1fb8e0f06ad9127c8d26fd2cf7"
7113-
integrity sha512-+cc3gJG1jpZWzl9dGLoNyo75DaSqe5oib2eoHFk0lg2gmCSt3Ypk1RME2lpcxd5zwMWAJpx9KhBqtlCuRmc1SQ==
7110+
payload@^3.54.0:
7111+
version "3.54.0"
7112+
resolved "https://registry.yarnpkg.com/payload/-/payload-3.54.0.tgz#40c7e47b20362876d861b164d98f3c86f0486f35"
7113+
integrity sha512-TQJptraB8bSnNlm/mCqVHHEdBUZLIQWpJsRdns7SggFIoewA/WLFX2LpLbjur8WY+4zhdaOUEm7GDzzRw506pw==
71147114
dependencies:
71157115
"@next/env" "^15.1.5"
7116-
"@payloadcms/translations" "3.49.1"
7116+
"@payloadcms/translations" "3.54.0"
71177117
"@types/busboy" "1.5.4"
71187118
ajv "8.17.1"
71197119
bson-objectid "2.0.4"

0 commit comments

Comments
 (0)