## Description 1. Adds ability to publish a specific individual locale (collections and globals) 2. Shows published locale in versions list and version comparison 3. Adds new int tests to `versions` test suite - [X] I have read and understand the [CONTRIBUTING.md](https://github.com/payloadcms/payload/blob/main/CONTRIBUTING.md) document in this repository. ## Type of change - [X] New feature (non-breaking change which adds functionality) - [ ] This change requires a documentation update ## Checklist: - [X] I have added tests that prove my fix is effective or that my feature works - [X] Existing test suite passes locally with my changes - [ ] I have made corresponding changes to the documentation --------- Co-authored-by: Dan Ribbens <dan.ribbens@gmail.com>
25 lines
426 B
TypeScript
25 lines
426 B
TypeScript
import type { CollectionConfig } from 'payload'
|
|
|
|
import { localizedCollectionSlug } from '../slugs.js'
|
|
|
|
const LocalizedPosts: CollectionConfig = {
|
|
slug: localizedCollectionSlug,
|
|
versions: {
|
|
drafts: true,
|
|
},
|
|
fields: [
|
|
{
|
|
name: 'text',
|
|
type: 'text',
|
|
localized: true,
|
|
},
|
|
{
|
|
name: 'description',
|
|
type: 'text',
|
|
localized: true,
|
|
},
|
|
],
|
|
}
|
|
|
|
export default LocalizedPosts
|