Merge branch '2.0' of github.com:payloadcms/payload into 2.0
This commit is contained in:
25
.github/workflows/main.yml
vendored
25
.github/workflows/main.yml
vendored
@@ -295,3 +295,28 @@ jobs:
|
||||
|
||||
- name: Build richtext-slate
|
||||
run: pnpm turbo run build --filter=richtext-slate
|
||||
|
||||
build-plugin-richtext-lexical:
|
||||
runs-on: ubuntu-latest
|
||||
needs: core-build
|
||||
|
||||
steps:
|
||||
- name: Use Node.js 18
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: 18
|
||||
|
||||
- name: Install pnpm
|
||||
uses: pnpm/action-setup@v2
|
||||
with:
|
||||
version: 8
|
||||
run_install: false
|
||||
|
||||
- name: Restore build
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ./*
|
||||
key: ${{ github.sha }}-${{ github.run_number }}
|
||||
|
||||
- name: Build richtext-lexical
|
||||
run: pnpm turbo run build --filter=richtext-lexical
|
||||
|
||||
@@ -295,7 +295,9 @@ export const addFieldStatePromise = async ({
|
||||
'value' in valueWithDefault
|
||||
) {
|
||||
const value =
|
||||
typeof valueWithDefault?.value === 'object' && 'id' in valueWithDefault.value
|
||||
typeof valueWithDefault?.value === 'object' &&
|
||||
valueWithDefault?.value &&
|
||||
'id' in valueWithDefault.value
|
||||
? valueWithDefault.value.id
|
||||
: valueWithDefault.value
|
||||
const relationshipValue = {
|
||||
|
||||
@@ -32,7 +32,6 @@ export const StrikethroughTextFeature = (): FeatureProvider => {
|
||||
},
|
||||
markdownTransformers: [STRIKETHROUGH],
|
||||
props: null,
|
||||
props: null,
|
||||
}
|
||||
},
|
||||
key: 'strikethrough',
|
||||
|
||||
@@ -29,6 +29,7 @@ export const SubscriptTextFeature = (): FeatureProvider => {
|
||||
]),
|
||||
],
|
||||
},
|
||||
props: null,
|
||||
}
|
||||
},
|
||||
key: 'subscript',
|
||||
|
||||
@@ -3,6 +3,7 @@ import path from 'path'
|
||||
import { payloadCloud } from '@payloadcms/plugin-cloud'
|
||||
import { mongooseAdapter } from '@payloadcms/db-mongodb' // database-adapter-import
|
||||
import { webpackBundler } from '@payloadcms/bundler-webpack' // bundler-import
|
||||
import { createLexical } from '@payloadcms/richtext-lexical' // editor-import
|
||||
import { buildConfig } from 'payload/config'
|
||||
|
||||
import Users from './collections/Users'
|
||||
@@ -11,6 +12,7 @@ export default buildConfig({
|
||||
admin: {
|
||||
user: Users.slug,
|
||||
},
|
||||
editor: createLexical({}), // editor-config
|
||||
collections: [Users],
|
||||
typescript: {
|
||||
outputFile: path.resolve(__dirname, 'payload-types.ts'),
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { payloadCloud } from '@payloadcms/plugin-cloud'
|
||||
import { mongooseAdapter } from '@payloadcms/db-mongodb' // database-adapter-import
|
||||
import { webpackBundler } from '@payloadcms/bundler-webpack' // bundler-import
|
||||
import { createLexical } from '@payloadcms/richtext-lexical' // editor-import
|
||||
import nestedDocs from '@payloadcms/plugin-nested-docs'
|
||||
import seo from '@payloadcms/plugin-seo'
|
||||
import type { GenerateTitle } from '@payloadcms/plugin-seo/types'
|
||||
@@ -58,6 +59,7 @@ export default buildConfig({
|
||||
},
|
||||
}),
|
||||
},
|
||||
editor: createLexical({}), // editor-config
|
||||
serverURL: process.env.PAYLOAD_PUBLIC_SERVER_URL,
|
||||
collections: [Pages, Products, Orders, Media, Categories, Users],
|
||||
globals: [Settings, Header, Footer],
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { payloadCloud } from '@payloadcms/plugin-cloud'
|
||||
import { mongooseAdapter } from '@payloadcms/db-mongodb' // database-adapter-import
|
||||
import { webpackBundler } from '@payloadcms/bundler-webpack' // bundler-import
|
||||
import { createLexical } from '@payloadcms/richtext-lexical' // editor-import
|
||||
import FormBuilder from '@payloadcms/plugin-form-builder'
|
||||
import nestedDocs from '@payloadcms/plugin-nested-docs'
|
||||
import redirects from '@payloadcms/plugin-redirects'
|
||||
@@ -43,6 +44,7 @@ export default buildConfig({
|
||||
},
|
||||
}),
|
||||
},
|
||||
editor: createLexical({}), // editor-config
|
||||
serverURL: process.env.PAYLOAD_PUBLIC_SERVER_URL,
|
||||
collections: [Users, Categories, Pages, Posts, Media],
|
||||
globals: [Header, Footer],
|
||||
|
||||
Reference in New Issue
Block a user