chore: passing versions e2e (#5343)
This commit is contained in:
@@ -77,6 +77,7 @@ export const initPage = async ({
|
||||
locale: locale.code,
|
||||
req: {
|
||||
i18n,
|
||||
url: `${payload.config.serverURL}${route}${searchParams ? `${qs.stringify(searchParams, { addQueryPrefix: true })}` : ''}`,
|
||||
} as PayloadRequest,
|
||||
user,
|
||||
},
|
||||
|
||||
@@ -128,6 +128,7 @@ export const Document: React.FC<AdminViewProps> = async ({
|
||||
id,
|
||||
collection: collectionSlug,
|
||||
depth: 0,
|
||||
draft: true,
|
||||
fallbackLocale: null,
|
||||
locale: locale.code,
|
||||
overrideAccess: false,
|
||||
@@ -177,6 +178,7 @@ export const Document: React.FC<AdminViewProps> = async ({
|
||||
data = await payload.findGlobal({
|
||||
slug: globalSlug,
|
||||
depth: 0,
|
||||
draft: true,
|
||||
fallbackLocale: null,
|
||||
locale: locale.code,
|
||||
overrideAccess: false,
|
||||
|
||||
@@ -188,7 +188,7 @@ export const DefaultEditView: React.FC = () => {
|
||||
id={id}
|
||||
isEditing={Boolean(id)}
|
||||
permissions={docPermissions}
|
||||
slug={collectionConfig?.slug}
|
||||
slug={collectionConfig?.slug || globalConfig?.slug}
|
||||
/>
|
||||
<DocumentFields
|
||||
AfterFields={AfterFields}
|
||||
|
||||
@@ -24,7 +24,7 @@ export const RootPage = async ({
|
||||
}: {
|
||||
config: Promise<SanitizedConfig>
|
||||
params: {
|
||||
[key: string]: string | string[]
|
||||
segments: string[]
|
||||
}
|
||||
searchParams: {
|
||||
[key: string]: string | string[]
|
||||
|
||||
@@ -1,5 +1,9 @@
|
||||
import type { FieldMap, StepNavItem } from '@payloadcms/ui'
|
||||
import type { FieldAffectingData, SanitizedCollectionConfig } from 'payload/types'
|
||||
import type {
|
||||
FieldAffectingData,
|
||||
SanitizedCollectionConfig,
|
||||
SanitizedGlobalConfig,
|
||||
} from 'payload/types'
|
||||
import type React from 'react'
|
||||
|
||||
import { getTranslation } from '@payloadcms/translations'
|
||||
@@ -11,10 +15,20 @@ export const SetStepNav: React.FC<{
|
||||
collectionSlug?: string
|
||||
doc: any
|
||||
fieldMap: FieldMap
|
||||
globalConfig?: SanitizedGlobalConfig
|
||||
globalSlug?: string
|
||||
id?: number | string
|
||||
mostRecentDoc: any
|
||||
}> = ({ id, collectionConfig, collectionSlug, doc, fieldMap, globalSlug, mostRecentDoc }) => {
|
||||
}> = ({
|
||||
id,
|
||||
collectionConfig,
|
||||
collectionSlug,
|
||||
doc,
|
||||
fieldMap,
|
||||
globalConfig,
|
||||
globalSlug,
|
||||
mostRecentDoc,
|
||||
}) => {
|
||||
const config = useConfig()
|
||||
const { setStepNav } = useStepNav()
|
||||
const { i18n, t } = useTranslation()
|
||||
@@ -77,12 +91,12 @@ export const SetStepNav: React.FC<{
|
||||
if (globalSlug) {
|
||||
nav = [
|
||||
{
|
||||
label: global.label,
|
||||
url: `${adminRoute}/globals/${global.slug}`,
|
||||
label: globalConfig.label,
|
||||
url: `${adminRoute}/globals/${globalConfig.slug}`,
|
||||
},
|
||||
{
|
||||
label: 'Versions',
|
||||
url: `${adminRoute}/globals/${global.slug}/versions`,
|
||||
url: `${adminRoute}/globals/${globalConfig.slug}/versions`,
|
||||
},
|
||||
{
|
||||
label: doc?.createdAt ? formatDate(doc.createdAt, dateFormat, i18n?.language) : '',
|
||||
@@ -103,6 +117,8 @@ export const SetStepNav: React.FC<{
|
||||
t,
|
||||
i18n,
|
||||
collectionConfig,
|
||||
fieldMap,
|
||||
globalConfig,
|
||||
])
|
||||
|
||||
return null
|
||||
|
||||
@@ -66,7 +66,7 @@ export const DefaultVersionView: React.FC<DefaultVersionsViewProps> = ({
|
||||
? formatDate(doc.createdAt, dateFormat, i18n.language)
|
||||
: ''
|
||||
|
||||
const originalDocFetchURL = `${serverURL}${apiRoute}${globalSlug ? 'globals/' : ''}/${
|
||||
const originalDocFetchURL = `${serverURL}${apiRoute}/${globalSlug ? 'globals/' : ''}${
|
||||
collectionSlug || globalSlug
|
||||
}${collectionSlug ? `/${id}` : ''}`
|
||||
|
||||
@@ -101,6 +101,7 @@ export const DefaultVersionView: React.FC<DefaultVersionsViewProps> = ({
|
||||
collectionSlug={collectionSlug}
|
||||
doc={doc}
|
||||
fieldMap={fieldMap}
|
||||
globalConfig={globalConfig}
|
||||
globalSlug={globalSlug}
|
||||
id={id}
|
||||
mostRecentDoc={mostRecentDoc}
|
||||
@@ -152,7 +153,15 @@ export const DefaultVersionView: React.FC<DefaultVersionsViewProps> = ({
|
||||
? locales.map(({ label }) => (typeof label === 'string' ? label : undefined))
|
||||
: []
|
||||
}
|
||||
version={doc?.version}
|
||||
version={
|
||||
globalConfig
|
||||
? {
|
||||
...doc?.version,
|
||||
createdAt: doc?.version?.createdAt || doc.createdAt,
|
||||
updatedAt: doc?.version?.updatedAt || doc.updatedAt,
|
||||
}
|
||||
: doc?.version
|
||||
}
|
||||
/>
|
||||
)}
|
||||
</Gutter>
|
||||
|
||||
@@ -29,9 +29,11 @@ export const SelectComparison: React.FC<Props> = (props) => {
|
||||
const [lastLoadedPage, setLastLoadedPage] = useState(1)
|
||||
const [errorLoading, setErrorLoading] = useState('')
|
||||
const { i18n, t } = useTranslation()
|
||||
const loadedAllOptionsRef = React.useRef(false)
|
||||
|
||||
const getResults = useCallback(
|
||||
async ({ lastLoadedPage: lastLoadedPageArg }) => {
|
||||
if (loadedAllOptionsRef.current) return
|
||||
const query: {
|
||||
[key: string]: unknown
|
||||
where: Where
|
||||
@@ -46,6 +48,11 @@ export const SelectComparison: React.FC<Props> = (props) => {
|
||||
not_equals: versionID,
|
||||
},
|
||||
},
|
||||
{
|
||||
latest: {
|
||||
not_equals: true,
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
}
|
||||
@@ -79,6 +86,9 @@ export const SelectComparison: React.FC<Props> = (props) => {
|
||||
})),
|
||||
])
|
||||
|
||||
if (!data.hasNextPage) {
|
||||
loadedAllOptionsRef.current = true
|
||||
}
|
||||
setLastLoadedPage(data.page)
|
||||
}
|
||||
} else {
|
||||
@@ -89,14 +99,9 @@ export const SelectComparison: React.FC<Props> = (props) => {
|
||||
)
|
||||
|
||||
useEffect(() => {
|
||||
getResults({ lastLoadedPage: 1 })
|
||||
void getResults({ lastLoadedPage: 1 })
|
||||
}, [getResults])
|
||||
|
||||
useEffect(() => {
|
||||
if (publishedDoc?._status === 'published')
|
||||
setOptions((currentOptions) => [publishedVersionOption, ...currentOptions])
|
||||
}, [publishedDoc])
|
||||
|
||||
return (
|
||||
<div
|
||||
className={[fieldBaseClass, baseClass, errorLoading && 'error-loading']
|
||||
@@ -110,9 +115,12 @@ export const SelectComparison: React.FC<Props> = (props) => {
|
||||
isSearchable={false}
|
||||
onChange={onChange}
|
||||
onMenuScrollToBottom={() => {
|
||||
getResults({ lastLoadedPage: lastLoadedPage + 1 })
|
||||
void getResults({ lastLoadedPage: lastLoadedPage + 1 })
|
||||
}}
|
||||
options={options}
|
||||
options={[
|
||||
...(publishedDoc?._status === 'published' ? [publishedVersionOption] : []),
|
||||
...options,
|
||||
]}
|
||||
placeholder={t('version:selectVersionToCompare')}
|
||||
value={value}
|
||||
/>
|
||||
|
||||
@@ -18,8 +18,7 @@ export const VersionView: EditViewComponent = async (props) => {
|
||||
req: { payload, payload: { config } = {}, user } = {},
|
||||
} = initPageResult
|
||||
|
||||
// /entityType/:entitySlug/:id/versions/:versionID
|
||||
const [entityType, entitySlug, docID, versions, versionID] = routeSegments
|
||||
const versionID = routeSegments[routeSegments.length - 1]
|
||||
|
||||
const collectionSlug = collectionConfig?.slug
|
||||
const globalSlug = globalConfig?.slug
|
||||
@@ -34,6 +33,7 @@ export const VersionView: EditViewComponent = async (props) => {
|
||||
let mostRecentDoc: Document
|
||||
|
||||
if (collectionSlug) {
|
||||
// /collections/:slug/:id/versions/:versionID
|
||||
slug = collectionSlug
|
||||
docPermissions = permissions.collections[collectionSlug]
|
||||
|
||||
@@ -72,11 +72,12 @@ export const VersionView: EditViewComponent = async (props) => {
|
||||
}
|
||||
|
||||
if (globalSlug) {
|
||||
// /globals/:slug/versions/:versionID
|
||||
slug = globalSlug
|
||||
docPermissions = permissions.globals[globalSlug]
|
||||
|
||||
try {
|
||||
doc = payload.findGlobalVersionByID({
|
||||
doc = await payload.findGlobalVersionByID({
|
||||
id: versionID,
|
||||
slug,
|
||||
depth: 1,
|
||||
@@ -85,7 +86,7 @@ export const VersionView: EditViewComponent = async (props) => {
|
||||
user,
|
||||
})
|
||||
|
||||
publishedDoc = payload.findGlobal({
|
||||
publishedDoc = await payload.findGlobal({
|
||||
slug,
|
||||
depth: 1,
|
||||
draft: false,
|
||||
@@ -94,7 +95,7 @@ export const VersionView: EditViewComponent = async (props) => {
|
||||
user,
|
||||
})
|
||||
|
||||
mostRecentDoc = payload.findGlobal({
|
||||
mostRecentDoc = await payload.findGlobal({
|
||||
slug,
|
||||
depth: 1,
|
||||
draft: true,
|
||||
|
||||
@@ -67,11 +67,6 @@ export const VersionsView: EditViewComponent = async (props) => {
|
||||
page: page ? parseInt(page as string, 10) : undefined,
|
||||
sort: sort as string,
|
||||
user,
|
||||
where: {
|
||||
parent: {
|
||||
equals: id,
|
||||
},
|
||||
},
|
||||
})
|
||||
} catch (error) {
|
||||
console.error(error) // eslint-disable-line no-console
|
||||
|
||||
@@ -29,32 +29,29 @@ const attachFakeURLProperties = (req: PayloadRequest) => {
|
||||
* `ts-ignore` is used below for properties that are 'read-only'
|
||||
* since they do not exist yet we can safely ignore the error.
|
||||
*/
|
||||
try {
|
||||
const urlProperties = new URL(req.payload.config?.serverURL)
|
||||
req.host = urlProperties.host
|
||||
req.protocol = urlProperties.protocol
|
||||
req.pathname = urlProperties.pathname
|
||||
// @ts-expect-error
|
||||
req.searchParams = urlProperties.searchParams
|
||||
// @ts-expect-error
|
||||
req.origin = urlProperties.origin
|
||||
// @ts-expect-error
|
||||
req.url = urlProperties.href
|
||||
return
|
||||
} catch (error) {
|
||||
/** do nothing */
|
||||
let urlObject
|
||||
|
||||
function getURLObject() {
|
||||
if (urlObject) return urlObject
|
||||
const urlToUse = req?.url || req.payload.config?.serverURL || 'http://localhost'
|
||||
try {
|
||||
urlObject = new URL(urlToUse)
|
||||
} catch (error) {
|
||||
urlObject = new URL('http://localhost')
|
||||
}
|
||||
|
||||
return urlObject
|
||||
}
|
||||
|
||||
req.host = 'localhost'
|
||||
req.protocol = 'https:'
|
||||
req.pathname = '/'
|
||||
if (!req.host) req.host = getURLObject().host
|
||||
if (!req.protocol) req.protocol = getURLObject().protocol
|
||||
if (!req.pathname) req.pathname = getURLObject().pathname
|
||||
// @ts-expect-error
|
||||
req.searchParams = new URLSearchParams()
|
||||
if (!req.searchParams) req.searchParams = getURLObject().searchParams
|
||||
// @ts-expect-error
|
||||
req.origin = 'http://localhost'
|
||||
if (!req.origin) req.origin = getURLObject().origin
|
||||
// @ts-expect-error
|
||||
req.url = 'http://localhost'
|
||||
return
|
||||
if (!req?.url) req.url = getURLObject().url
|
||||
}
|
||||
|
||||
type CreateLocalReq = (
|
||||
@@ -68,12 +65,13 @@ type CreateLocalReq = (
|
||||
payload: Payload,
|
||||
) => Promise<PayloadRequest>
|
||||
export const createLocalReq: CreateLocalReq = async (
|
||||
{ context, fallbackLocale, locale, req = {} as PayloadRequest, user },
|
||||
{ context, fallbackLocale, locale: localeArg, req = {} as PayloadRequest, user },
|
||||
payload,
|
||||
) => {
|
||||
const i18n = req?.i18n || (await getLocalI18n({ config: payload.config }))
|
||||
|
||||
if (payload.config?.localization) {
|
||||
const locale = localeArg === '*' ? 'all' : localeArg
|
||||
const defaultLocale = payload.config.localization.defaultLocale
|
||||
req.locale = locale || req?.locale || defaultLocale
|
||||
const fallbackLocaleFromConfig = payload.config.localization.locales.find(
|
||||
@@ -96,7 +94,7 @@ export const createLocalReq: CreateLocalReq = async (
|
||||
req.routeParams = req?.routeParams || {}
|
||||
req.query = req?.query || {}
|
||||
|
||||
if (!req?.url) attachFakeURLProperties(req)
|
||||
attachFakeURLProperties(req)
|
||||
|
||||
return req
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
/** @type {import('eslint').Linter.Config} */
|
||||
module.exports = {
|
||||
ignorePatterns: ['src/all', 'writeTranslationFiles.ts'],
|
||||
parserOptions: {
|
||||
project: ['./tsconfig.json'],
|
||||
tsconfigRootDir: __dirname,
|
||||
|
||||
@@ -237,6 +237,7 @@ export default {
|
||||
requiresAtLeast: 'هذا الحقل يتطلب على الأقل {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'النّوع',
|
||||
aboutToPublishSelection: 'أنت على وشك نشر كلّ {{label}} في التّحديد. هل أنت متأكّد؟',
|
||||
aboutToRestore:
|
||||
'أنت على وشك استرجاع هذا المستند {{label}} إلى الحالة التّي كان عليها في {{versionDate}}.',
|
||||
@@ -255,6 +256,7 @@ export default {
|
||||
confirmVersionRestoration: 'تأكيد إستعادة النّسخة',
|
||||
draft: 'مسودّة',
|
||||
draftSavedSuccessfully: 'تمّ حفظ المسودّة بنجاح.',
|
||||
lastSavedAgo: 'تم الحفظ آخر مرة قبل {{distance}}',
|
||||
noFurtherVersionsFound: 'لم يتمّ العثور على نسخات أخرى',
|
||||
noRowsFound: 'لم يتمّ العثور على {{label}}',
|
||||
preview: 'معاينة',
|
||||
@@ -262,6 +264,7 @@ export default {
|
||||
publish: 'نشر',
|
||||
publishChanges: 'نشر التّغييرات',
|
||||
published: 'تمّ النّشر',
|
||||
publishing: 'نشر',
|
||||
restoreThisVersion: 'استعادة هذه النّسخة',
|
||||
restoredSuccessfully: 'تمّت الاستعادة بنحاح.',
|
||||
restoring: 'تتمّ الاستعادة...',
|
||||
@@ -270,7 +273,6 @@ export default {
|
||||
selectLocales: 'حدّد اللّغات المراد عرضها',
|
||||
selectVersionToCompare: 'حدّد نسخة للمقارنة',
|
||||
showLocales: 'اظهر اللّغات:',
|
||||
type: 'النّوع',
|
||||
unpublish: 'الغاء النّشر',
|
||||
unpublishing: 'يتمّ الغاء النّشر...',
|
||||
version: 'النّسخة',
|
||||
|
||||
@@ -241,6 +241,7 @@ export default {
|
||||
requiresAtLeast: 'Bu sahə ən azı {{count}} {{label}} tələb edir.',
|
||||
},
|
||||
version: {
|
||||
type: 'Növ',
|
||||
aboutToPublishSelection: 'Seçimdə olan bütün {{label}}-i dərc etməyə hazırsınız. Əminsiniz?',
|
||||
aboutToRestore:
|
||||
'Bu {{label}} sənədini {{versionDate}} tarixindəki vəziyyətinə bərpa etmək üzrəsiniz.',
|
||||
@@ -261,6 +262,7 @@ export default {
|
||||
confirmVersionRestoration: 'Versiyanın bərpasını təsdiq edin',
|
||||
draft: 'Qaralama',
|
||||
draftSavedSuccessfully: 'Qaralama uğurla yadda saxlandı.',
|
||||
lastSavedAgo: '{{distance}} əvvəl son yadda saxlanıldı',
|
||||
noFurtherVersionsFound: 'Başqa versiyalar tapılmadı',
|
||||
noRowsFound: 'Heç bir {{label}} tapılmadı',
|
||||
preview: 'Öncədən baxış',
|
||||
@@ -268,6 +270,7 @@ export default {
|
||||
publish: 'Dərc et',
|
||||
publishChanges: 'Dəyişiklikləri dərc et',
|
||||
published: 'Dərc edilmiş',
|
||||
publishing: 'Nəşr',
|
||||
restoreThisVersion: 'Bu versiyanı bərpa et',
|
||||
restoredSuccessfully: 'Uğurla bərpa edildi.',
|
||||
restoring: 'Bərpa olunur...',
|
||||
@@ -276,7 +279,6 @@ export default {
|
||||
selectLocales: 'Göstərmək üçün lokalları seçin',
|
||||
selectVersionToCompare: 'Müqayisə üçün bir versiya seçin',
|
||||
showLocales: 'Lokalları göstər:',
|
||||
type: 'Növ',
|
||||
unpublish: 'Dərcdən çıxart',
|
||||
unpublishing: 'Dərcdən çıxarılır...',
|
||||
version: 'Versiya',
|
||||
|
||||
@@ -239,6 +239,7 @@ export default {
|
||||
requiresAtLeast: 'Това поле изисква поне {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Тип',
|
||||
aboutToPublishSelection: 'На път си да публикуваш всички избрани {{label}}. Сигурен ли си?',
|
||||
aboutToRestore:
|
||||
'На път си да възстановиш този {{label}} документ до състоянието му от {{versionDate}}.',
|
||||
@@ -258,6 +259,7 @@ export default {
|
||||
confirmVersionRestoration: 'Потвърди възстановяване на версия',
|
||||
draft: 'Чернова',
|
||||
draftSavedSuccessfully: 'Чернова запазена успешно.',
|
||||
lastSavedAgo: 'последно запазено преди {{distance}}',
|
||||
noFurtherVersionsFound: 'Не са открити повече версии',
|
||||
noRowsFound: 'Не е открит {{label}}',
|
||||
preview: 'Предварителен преглед',
|
||||
@@ -265,6 +267,7 @@ export default {
|
||||
publish: 'Публикувай',
|
||||
publishChanges: 'Публикувай промените',
|
||||
published: 'Публикувано',
|
||||
publishing: 'Публикуване',
|
||||
restoreThisVersion: 'Възстанови тази версия',
|
||||
restoredSuccessfully: 'Успешно възстановяване.',
|
||||
restoring: 'Възстановяване...',
|
||||
@@ -273,7 +276,6 @@ export default {
|
||||
selectLocales: 'Избери локализации за показване',
|
||||
selectVersionToCompare: 'Избери версия за сравняване',
|
||||
showLocales: 'Покажи преводи:',
|
||||
type: 'Тип',
|
||||
unpublish: 'Скрий',
|
||||
unpublishing: 'Скриване...',
|
||||
version: 'Версия',
|
||||
|
||||
@@ -238,6 +238,7 @@ export default {
|
||||
requiresAtLeast: 'Toto pole vyžaduje alespoň {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Typ',
|
||||
aboutToPublishSelection: 'Chystáte se publikovat všechny {{label}} ve výběru. Jsi si jistá?',
|
||||
aboutToRestore:
|
||||
'Chystáte se obnovit tento {{label}} dokument do stavu, v jakém byl {{versionDate}}.',
|
||||
@@ -258,6 +259,7 @@ export default {
|
||||
confirmVersionRestoration: 'Potvrdit obnovení verze',
|
||||
draft: 'Koncept',
|
||||
draftSavedSuccessfully: 'Koncept úspěšně uložen.',
|
||||
lastSavedAgo: 'Naposledy uloženo před {{distance}}',
|
||||
noFurtherVersionsFound: 'Nenalezeny další verze',
|
||||
noRowsFound: 'Nenalezen {{label}}',
|
||||
preview: 'Náhled',
|
||||
@@ -265,6 +267,7 @@ export default {
|
||||
publish: 'Publikovat',
|
||||
publishChanges: 'Publikovat změny',
|
||||
published: 'Publikováno',
|
||||
publishing: 'Publikování',
|
||||
restoreThisVersion: 'Obnovit tuto verzi',
|
||||
restoredSuccessfully: 'Úspěšně obnoveno.',
|
||||
restoring: 'Obnovování...',
|
||||
@@ -273,7 +276,6 @@ export default {
|
||||
selectLocales: 'Vyberte místní verze pro zobrazení',
|
||||
selectVersionToCompare: 'Vyberte verzi pro porovnání',
|
||||
showLocales: 'Zobrazit místní verze:',
|
||||
type: 'Typ',
|
||||
unpublish: 'Zrušit publikování',
|
||||
unpublishing: 'Zrušuji publikování...',
|
||||
version: 'Verze',
|
||||
|
||||
@@ -241,6 +241,7 @@ export default {
|
||||
requiresAtLeast: 'Dieses Feld muss mindestens {{count}} {{label}} enthalten.',
|
||||
},
|
||||
version: {
|
||||
type: 'Typ',
|
||||
aboutToPublishSelection:
|
||||
'Sie sind dabei, alle {{label}} in der Auswahl zu veröffentlichen. Bist du dir sicher?',
|
||||
aboutToRestore: 'Du bist dabei, {{label}} auf den Stand vom {{versionDate}} zurücksetzen.',
|
||||
@@ -261,6 +262,7 @@ export default {
|
||||
confirmVersionRestoration: ' Wiederherstellung der Version bestätigen',
|
||||
draft: 'Entwurf',
|
||||
draftSavedSuccessfully: 'Entwurf erfolgreich gespeichert.',
|
||||
lastSavedAgo: 'Zuletzt vor {{distance}} gespeichert',
|
||||
noFurtherVersionsFound: 'Keine weiteren Versionen vorhanden',
|
||||
noRowsFound: 'Kein {{label}} gefunden',
|
||||
preview: 'Vorschau',
|
||||
@@ -268,6 +270,7 @@ export default {
|
||||
publish: 'Veröffentlichen',
|
||||
publishChanges: 'Änderungen veröffentlichen',
|
||||
published: 'Veröffentlicht',
|
||||
publishing: 'Veröffentlichung',
|
||||
restoreThisVersion: 'Diese Version wiederherstellen',
|
||||
restoredSuccessfully: 'Erfolgreich wiederhergestellt.',
|
||||
restoring: 'wiederherstellen...',
|
||||
@@ -276,7 +279,6 @@ export default {
|
||||
selectLocales: 'Wähle anzuzeigende Sprachumgebungen',
|
||||
selectVersionToCompare: 'Wähle Version zum Vergleich',
|
||||
showLocales: 'Sprachumgebungen anzeigen:',
|
||||
type: 'Typ',
|
||||
unpublish: 'Auf Entwurf setzen',
|
||||
unpublishing: 'Setze auf Entwurf...',
|
||||
version: 'Version',
|
||||
|
||||
@@ -242,6 +242,7 @@ export default {
|
||||
requiresAtLeast: 'This field requires at least {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Type',
|
||||
aboutToPublishSelection:
|
||||
'You are about to publish all {{label}} in the selection. Are you sure?',
|
||||
aboutToRestore:
|
||||
@@ -263,6 +264,7 @@ export default {
|
||||
confirmVersionRestoration: 'Confirm version Restoration',
|
||||
draft: 'Draft',
|
||||
draftSavedSuccessfully: 'Draft saved successfully.',
|
||||
lastSavedAgo: 'Last saved {{distance}} ago',
|
||||
noFurtherVersionsFound: 'No further versions found',
|
||||
noRowsFound: 'No {{label}} found',
|
||||
preview: 'Preview',
|
||||
@@ -270,6 +272,7 @@ export default {
|
||||
publish: 'Publish',
|
||||
publishChanges: 'Publish changes',
|
||||
published: 'Published',
|
||||
publishing: 'Publishing',
|
||||
restoreThisVersion: 'Restore this version',
|
||||
restoredSuccessfully: 'Restored Successfully.',
|
||||
restoring: 'Restoring...',
|
||||
@@ -278,7 +281,6 @@ export default {
|
||||
selectLocales: 'Select locales to display',
|
||||
selectVersionToCompare: 'Select a version to compare',
|
||||
showLocales: 'Show locales:',
|
||||
type: 'Type',
|
||||
unpublish: 'Unpublish',
|
||||
unpublishing: 'Unpublishing...',
|
||||
version: 'Version',
|
||||
|
||||
@@ -240,6 +240,7 @@ export default {
|
||||
requiresAtLeast: 'Este campo require al menos {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Tipo',
|
||||
aboutToPublishSelection:
|
||||
'Está a punto de publicar todas las {{etiquetas}} de la selección. ¿Está seguro?',
|
||||
aboutToRestore:
|
||||
@@ -261,6 +262,7 @@ export default {
|
||||
confirmVersionRestoration: 'Confirmar restauración de versión',
|
||||
draft: 'Borrador',
|
||||
draftSavedSuccessfully: 'Borrador guardado con éxito.',
|
||||
lastSavedAgo: 'Guardado por última vez hace {{distance}}',
|
||||
noFurtherVersionsFound: 'No se encontraron más versiones',
|
||||
noRowsFound: 'No encontramos {{label}}',
|
||||
preview: 'Previsualizar',
|
||||
@@ -268,6 +270,7 @@ export default {
|
||||
publish: 'Publicar',
|
||||
publishChanges: 'Publicar cambios',
|
||||
published: 'Publicado',
|
||||
publishing: 'Publishing',
|
||||
restoreThisVersion: 'Restaurar esta versión',
|
||||
restoredSuccessfully: 'Restaurado éxito.',
|
||||
restoring: 'Restaurando...',
|
||||
@@ -276,7 +279,6 @@ export default {
|
||||
selectLocales: 'Selecciona idiomas a mostrar',
|
||||
selectVersionToCompare: 'Selecciona versión a comparar',
|
||||
showLocales: 'Mostrar idiomas:',
|
||||
type: 'Tipo',
|
||||
unpublish: 'Despublicar',
|
||||
unpublishing: 'Despublicando...',
|
||||
version: 'Versión',
|
||||
|
||||
@@ -239,6 +239,7 @@ export default {
|
||||
requiresAtLeast: 'این رشته حداقل نیازمند {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'تایپ کنید',
|
||||
aboutToPublishSelection:
|
||||
'شما در حال انتشار همه {{label}} برگزیده هستید از این کار اطمینان دارید؟',
|
||||
aboutToRestore:
|
||||
@@ -258,6 +259,7 @@ export default {
|
||||
confirmVersionRestoration: 'تأیید بازیابی نگارش',
|
||||
draft: 'پیشنویس',
|
||||
draftSavedSuccessfully: 'پیشنویس با موفقیت ذخیره شد.',
|
||||
lastSavedAgo: 'آخرین بار {{distance}} پیش ذخیره شد',
|
||||
noFurtherVersionsFound: 'نگارش دیگری یافت نشد',
|
||||
noRowsFound: 'هیچ {{label}} یافت نشد',
|
||||
preview: 'پیشنمایش',
|
||||
@@ -265,6 +267,7 @@ export default {
|
||||
publish: 'انتشار',
|
||||
publishChanges: 'انتشار تغییرات',
|
||||
published: 'انتشار یافته',
|
||||
publishing: 'انتشار',
|
||||
restoreThisVersion: 'این نگارش را بازیابی کنید',
|
||||
restoredSuccessfully: 'با موفقیت بازیابی شد.',
|
||||
restoring: 'در حال بازیابی...',
|
||||
@@ -273,7 +276,6 @@ export default {
|
||||
selectLocales: 'زبانها را برای نمایش انتخاب کنید',
|
||||
selectVersionToCompare: 'نگارشی را برای مقایسه انتخاب کنید',
|
||||
showLocales: 'نمایش زبانها:',
|
||||
type: 'تایپ کنید',
|
||||
unpublish: 'لغو انتشار',
|
||||
unpublishing: 'در حال لغو انتشار...',
|
||||
version: 'نگارش',
|
||||
|
||||
@@ -243,6 +243,7 @@ export default {
|
||||
requiresAtLeast: 'Ce champ doit avoir au moins {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Type',
|
||||
aboutToPublishSelection:
|
||||
'Vous êtes sur le point de publier tous les {{label}} de la sélection. Es-tu sûr?',
|
||||
aboutToRestore:
|
||||
@@ -265,6 +266,7 @@ export default {
|
||||
confirmVersionRestoration: 'Confirmer la restauration de la version',
|
||||
draft: 'Brouillon',
|
||||
draftSavedSuccessfully: 'Brouillon enregistré avec succès.',
|
||||
lastSavedAgo: 'Dernière sauvegarde il y a {{distance}}',
|
||||
noFurtherVersionsFound: 'Aucune autre version trouvée',
|
||||
noRowsFound: 'Aucun(e) {{label}} trouvé(e)',
|
||||
preview: 'Aperçu',
|
||||
@@ -272,6 +274,7 @@ export default {
|
||||
publish: 'Publier',
|
||||
publishChanges: 'Publier les modifications',
|
||||
published: 'Publié',
|
||||
publishing: 'Publication',
|
||||
restoreThisVersion: 'Restaurer cette version',
|
||||
restoredSuccessfully: 'Restauré(e) avec succès.',
|
||||
restoring: 'Restauration en cours...',
|
||||
@@ -280,7 +283,6 @@ export default {
|
||||
selectLocales: 'Sélectionnez les paramètres régionaux à afficher',
|
||||
selectVersionToCompare: 'Sélectionnez une version à comparer',
|
||||
showLocales: 'Afficher les paramètres régionaux :',
|
||||
type: 'Type',
|
||||
unpublish: 'Annuler la publication',
|
||||
unpublishing: 'Annulation en cours...',
|
||||
version: 'Version',
|
||||
|
||||
@@ -239,6 +239,7 @@ export default {
|
||||
requiresAtLeast: 'Ovo polje zahtjeva minimalno {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Tip',
|
||||
aboutToPublishSelection: 'Upravo ćete objaviti sve {{label}} u izboru. Jesi li siguran?',
|
||||
aboutToRestore: 'Vratit ćete {{label}} dokument u stanje u kojem je bio {{versionDate}}',
|
||||
aboutToRestoreGlobal: 'Vratit ćete globalni {{label}} u stanje u kojem je bio {{versionDate}}.',
|
||||
@@ -257,6 +258,7 @@ export default {
|
||||
confirmVersionRestoration: 'Potvrdite vraćanje verzije',
|
||||
draft: 'Nacrt',
|
||||
draftSavedSuccessfully: 'Nacrt uspješno spremljen.',
|
||||
lastSavedAgo: 'Zadnji put spremljeno prije {{distance}',
|
||||
noFurtherVersionsFound: 'Nisu pronađene daljnje verzije',
|
||||
noRowsFound: '{{label}} nije pronađeno',
|
||||
preview: 'Pregled',
|
||||
@@ -264,6 +266,7 @@ export default {
|
||||
publish: 'Objaviti',
|
||||
publishChanges: 'Objavi promjene',
|
||||
published: 'Objavljeno',
|
||||
publishing: 'Objavljivanje',
|
||||
restoreThisVersion: 'Vrati ovu verziju',
|
||||
restoredSuccessfully: 'Uspješno vraćeno.',
|
||||
restoring: 'Vraćanje...',
|
||||
@@ -272,7 +275,6 @@ export default {
|
||||
selectLocales: 'Odaberite jezike',
|
||||
selectVersionToCompare: 'Odaberite verziju za usporedbu',
|
||||
showLocales: 'Prikaži jezike:',
|
||||
type: 'Tip',
|
||||
unpublish: 'Poništi objavu',
|
||||
unpublishing: 'Poništavanje objave...',
|
||||
version: 'Verzija',
|
||||
|
||||
@@ -240,6 +240,7 @@ export default {
|
||||
requiresAtLeast: 'Ehhez a mezőhöz legalább {{count}} {{label}} szükséges.',
|
||||
},
|
||||
version: {
|
||||
type: 'Típus',
|
||||
aboutToPublishSelection:
|
||||
'Arra készül, hogy az összes {{label}} elemet közzétegye a kijelölésben. biztos vagy ebben?',
|
||||
aboutToRestore:
|
||||
@@ -261,6 +262,7 @@ export default {
|
||||
confirmVersionRestoration: 'Verzió-visszaállítás megerősítése',
|
||||
draft: 'Piszkozat',
|
||||
draftSavedSuccessfully: 'A piszkozat sikeresen mentve.',
|
||||
lastSavedAgo: 'Utoljára mentve {{distance}} órája',
|
||||
noFurtherVersionsFound: 'További verziók nem találhatók',
|
||||
noRowsFound: 'Nem található {{label}}',
|
||||
preview: 'Előnézet',
|
||||
@@ -268,6 +270,7 @@ export default {
|
||||
publish: 'Közzététel',
|
||||
publishChanges: 'Módosítások közzététele',
|
||||
published: 'Közzétett',
|
||||
publishing: 'Közzététel',
|
||||
restoreThisVersion: 'A verzió visszaállítása',
|
||||
restoredSuccessfully: 'Sikeresen visszaállítva.',
|
||||
restoring: 'Visszaállítás...',
|
||||
@@ -276,7 +279,6 @@ export default {
|
||||
selectLocales: 'Megjelenítendő nyelvek kiválasztása',
|
||||
selectVersionToCompare: 'Válassza ki az összehasonlítani kívánt verziót',
|
||||
showLocales: 'Nyelvek megjelenítése:',
|
||||
type: 'Típus',
|
||||
unpublish: 'Közzététel visszavonása',
|
||||
unpublishing: 'Közzététel visszavonása...',
|
||||
version: 'Verzió',
|
||||
|
||||
@@ -241,6 +241,7 @@ export default {
|
||||
requiresAtLeast: 'Questo campo richiede almeno {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Tipo',
|
||||
aboutToPublishSelection: 'Stai per pubblicare tutte le {{label}} nella selezione. Sei sicuro?',
|
||||
aboutToRestore:
|
||||
'Stai per ripristinare questo documento {{label}} allo stato in cui si trovava il {{versionDate}}.',
|
||||
@@ -261,6 +262,7 @@ export default {
|
||||
confirmVersionRestoration: 'Conferma il ripristino della versione',
|
||||
draft: 'Bozza',
|
||||
draftSavedSuccessfully: 'Bozza salvata con successo.',
|
||||
lastSavedAgo: 'Ultimo salvataggio {{distance}} fa',
|
||||
noFurtherVersionsFound: 'Non sono state trovate ulteriori versioni',
|
||||
noRowsFound: 'Nessun {{label}} trovato',
|
||||
preview: 'Anteprima',
|
||||
@@ -268,6 +270,7 @@ export default {
|
||||
publish: 'Pubblicare',
|
||||
publishChanges: 'Pubblica modifiche',
|
||||
published: 'Pubblicato',
|
||||
publishing: 'Pubblicazione',
|
||||
restoreThisVersion: 'Ripristina questa versione',
|
||||
restoredSuccessfully: 'Ripristinato con successo.',
|
||||
restoring: 'Ripristino...',
|
||||
@@ -276,7 +279,6 @@ export default {
|
||||
selectLocales: 'Seleziona le lingue da visualizzare',
|
||||
selectVersionToCompare: 'Seleziona una versione da confrontare',
|
||||
showLocales: 'Mostra localizzazioni:',
|
||||
type: 'Tipo',
|
||||
unpublish: 'Annulla pubblicazione',
|
||||
unpublishing: 'Annullamento pubblicazione...',
|
||||
version: 'Versione',
|
||||
|
||||
@@ -240,6 +240,7 @@ export default {
|
||||
requiresAtLeast: '少なくとも {{count}} {{label}} 以上が必要です。',
|
||||
},
|
||||
version: {
|
||||
type: 'タイプ',
|
||||
aboutToPublishSelection: '選択中のすべての{{label}}を公開しようとしています。よろしいですか?',
|
||||
aboutToRestore:
|
||||
'この {{label}} データを {{versionDate}} 時点のバージョンに復元しようとしています。',
|
||||
@@ -260,6 +261,7 @@ export default {
|
||||
confirmVersionRestoration: 'バージョン復元の確認',
|
||||
draft: 'ドラフト',
|
||||
draftSavedSuccessfully: '下書きは正常に保存されました。',
|
||||
lastSavedAgo: '{{distance}}前に最後に保存されました',
|
||||
noFurtherVersionsFound: 'その他のバージョンは見つかりませんでした。',
|
||||
noRowsFound: '{{label}} は未設定です',
|
||||
preview: 'プレビュー',
|
||||
@@ -267,6 +269,7 @@ export default {
|
||||
publish: '公開する',
|
||||
publishChanges: '変更内容を公開',
|
||||
published: '公開済み',
|
||||
publishing: '公開',
|
||||
restoreThisVersion: 'このバージョンを復元',
|
||||
restoredSuccessfully: '正常に復元されました。',
|
||||
restoring: '復元しています...',
|
||||
@@ -275,7 +278,6 @@ export default {
|
||||
selectLocales: '表示するロケールを選択',
|
||||
selectVersionToCompare: '比較するバージョンを選択',
|
||||
showLocales: 'ロケールを表示:',
|
||||
type: 'タイプ',
|
||||
unpublish: '非公開',
|
||||
unpublishing: '非公開中...',
|
||||
version: 'バージョン',
|
||||
|
||||
@@ -238,6 +238,7 @@ export default {
|
||||
requiresAtLeast: '이 입력란운 최소한 {{count}} {{label}}이 필요합니다.',
|
||||
},
|
||||
version: {
|
||||
type: '유형',
|
||||
aboutToPublishSelection: '선택한 {{label}}을(를) 게시하려고 합니다. 계속하시겠습니까?',
|
||||
aboutToRestore: '이 {{label}} 문서를 {{versionDate}}기준 버전으로 복원하려고 합니다.',
|
||||
aboutToRestoreGlobal: '글로벌 {{label}}을(를) {{versionDate}}기준 버전으로 복원하려고 합니다.',
|
||||
@@ -255,6 +256,7 @@ export default {
|
||||
confirmVersionRestoration: '버전 복원하기',
|
||||
draft: '초안',
|
||||
draftSavedSuccessfully: '초안이 저장되었습니다.',
|
||||
lastSavedAgo: '마지막으로 저장한지 {{distance}} 전',
|
||||
noFurtherVersionsFound: '더 이상의 버전을 찾을 수 없습니다.',
|
||||
noRowsFound: '{{label}}을(를) 찾을 수 없음',
|
||||
preview: '미리보기',
|
||||
@@ -262,6 +264,7 @@ export default {
|
||||
publish: '게시',
|
||||
publishChanges: '변경 사항 게시',
|
||||
published: '게시됨',
|
||||
publishing: '게시',
|
||||
restoreThisVersion: '이 버전 복원',
|
||||
restoredSuccessfully: '복원이 완료되었습니다.',
|
||||
restoring: '복원 중...',
|
||||
@@ -270,7 +273,6 @@ export default {
|
||||
selectLocales: '표시할 locale 선택',
|
||||
selectVersionToCompare: '비교할 버전 선택',
|
||||
showLocales: 'locale 표시:',
|
||||
type: '유형',
|
||||
unpublish: '게시 해제',
|
||||
unpublishing: '게시 해제 중...',
|
||||
version: '버전',
|
||||
|
||||
@@ -243,6 +243,7 @@ export default {
|
||||
requiresAtLeast: 'ဤအကွက်သည် အနည်းဆုံး {{count}} {{label}} လိုအပ်သည်',
|
||||
},
|
||||
version: {
|
||||
type: 'အမျိုးအစား',
|
||||
aboutToPublishSelection:
|
||||
'သင်သည် ရွေးချယ်မှုတွင် {{label}} အားလုံးကို ထုတ်ဝေပါတော့မည်။ သေချာလား?',
|
||||
aboutToRestore:
|
||||
@@ -264,6 +265,7 @@ export default {
|
||||
confirmVersionRestoration: 'ဗားရှင်းပြန်လည် အသုံးပြုခြင်းကို အတည်ပြုပါ။',
|
||||
draft: 'မူကြမ်း',
|
||||
draftSavedSuccessfully: 'မူကြမ်းကို အောင်မြင်စွာ သိမ်းဆည်းပြီးပါပြီ။',
|
||||
lastSavedAgo: 'နောက်ဆုံး သိမ်းချက် {{distance}} ကြာပြီး',
|
||||
noFurtherVersionsFound: 'နောက်ထပ်ဗားရှင်းများ မတွေ့ပါ။',
|
||||
noRowsFound: '{{label}} အားမတွေ့ပါ။',
|
||||
preview: 'နမူနာပြရန်',
|
||||
@@ -271,6 +273,7 @@ export default {
|
||||
publish: 'ထုတ်ဝေသည်။',
|
||||
publishChanges: 'အပြောင်းအလဲများကို တင်ခဲ့သည်။',
|
||||
published: 'တင်ပြီးပြီ။',
|
||||
publishing: 'ထုတ်ဝေခြင်း',
|
||||
restoreThisVersion: 'ဤဗားရှင်းကိုကို ပြန်ယူမည်။',
|
||||
restoredSuccessfully: 'အောင်မြင်စွာ ပြန်လည်ရယူခဲ့သည်။',
|
||||
restoring: 'ပြန်ယူနေဆဲ...',
|
||||
@@ -279,7 +282,6 @@ export default {
|
||||
selectLocales: 'ပြသရန် ဒေသန္တရများကို ရွေးပါ။',
|
||||
selectVersionToCompare: 'နှိုင်းယှဉ်ရန် ဗားရှင်းကို ရွေးပါ။',
|
||||
showLocales: 'ဒေသန္တရများကိုပြပါ။:',
|
||||
type: 'အမျိုးအစား',
|
||||
unpublish: 'ပြန်ဖြုတ်မည်။',
|
||||
unpublishing: 'ပြန်ဖြုတ်နေဆဲ ...',
|
||||
version: 'ဗားရှင်း',
|
||||
|
||||
@@ -240,6 +240,7 @@ export default {
|
||||
requiresAtLeast: 'Dette feltet krever minst {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Type',
|
||||
aboutToPublishSelection:
|
||||
'Du er i ferd med å publisere alle {{label}} i utvalget. Er du sikker?',
|
||||
aboutToRestore:
|
||||
@@ -261,6 +262,7 @@ export default {
|
||||
confirmVersionRestoration: 'Bekreft versjon-gjenoppretting',
|
||||
draft: 'Utkast',
|
||||
draftSavedSuccessfully: 'Utkast lagret.',
|
||||
lastSavedAgo: 'Sist lagret {{distance}} siden',
|
||||
noFurtherVersionsFound: 'Ingen flere versjoner funnet',
|
||||
noRowsFound: 'Ingen {{label}} funnet',
|
||||
preview: 'Forhåndsvisning',
|
||||
@@ -268,6 +270,7 @@ export default {
|
||||
publish: 'Publisere',
|
||||
publishChanges: 'Publiser endringer',
|
||||
published: 'Publisert',
|
||||
publishing: 'Publisering',
|
||||
restoreThisVersion: 'Gjenopprett denne versjonen',
|
||||
restoredSuccessfully: 'Gjenopprettet.',
|
||||
restoring: 'Gjenoppretter...',
|
||||
@@ -276,7 +279,6 @@ export default {
|
||||
selectLocales: 'Velg språk å vise',
|
||||
selectVersionToCompare: 'Velg en versjon å sammenligne',
|
||||
showLocales: 'Vis språk:',
|
||||
type: 'Type',
|
||||
unpublish: 'Avpubliser',
|
||||
unpublishing: 'Avpubliserer...',
|
||||
version: 'Versjon',
|
||||
|
||||
@@ -241,6 +241,7 @@ export default {
|
||||
requiresAtLeast: 'Dit veld vereist minstens {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Type',
|
||||
aboutToPublishSelection:
|
||||
'Je staat op het punt om alle {{label}} in de selectie te publiceren. Weet je het zeker?',
|
||||
aboutToRestore:
|
||||
@@ -263,6 +264,7 @@ export default {
|
||||
confirmVersionRestoration: 'Bevestig te herstellen versie',
|
||||
draft: 'Concept',
|
||||
draftSavedSuccessfully: 'Concept succesvol bewaard.',
|
||||
lastSavedAgo: 'Laatst opgeslagen {{distance}} geleden',
|
||||
noFurtherVersionsFound: 'Geen verdere versies gevonden',
|
||||
noRowsFound: 'Geen {{label}} gevonden',
|
||||
preview: 'Voorbeeld',
|
||||
@@ -270,6 +272,7 @@ export default {
|
||||
publish: 'Publiceren',
|
||||
publishChanges: 'Publiceer wijzigingen',
|
||||
published: 'Gepubliceerd',
|
||||
publishing: 'Publicatie',
|
||||
restoreThisVersion: 'Herstel deze versie',
|
||||
restoredSuccessfully: 'Herstelling succesvol.',
|
||||
restoring: 'Herstellen...',
|
||||
@@ -278,7 +281,6 @@ export default {
|
||||
selectLocales: 'Selecteer locales om weer te geven',
|
||||
selectVersionToCompare: 'Selecteer een versie om te vergelijken',
|
||||
showLocales: 'Toon locales:',
|
||||
type: 'Type',
|
||||
unpublish: 'Publicatie ongedaan maken',
|
||||
unpublishing: 'Publicatie ongedaan maken...',
|
||||
version: 'Versie',
|
||||
|
||||
@@ -240,6 +240,7 @@ export default {
|
||||
requiresAtLeast: 'To pole wymaga co najmniej {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Typ',
|
||||
aboutToPublishSelection:
|
||||
'Za chwilę opublikujesz wszystkie {{label}} w zaznaczeniu. Jesteś pewny?',
|
||||
aboutToRestore:
|
||||
@@ -261,6 +262,7 @@ export default {
|
||||
confirmVersionRestoration: 'Potwierdź przywrócenie wersji',
|
||||
draft: 'Szkic',
|
||||
draftSavedSuccessfully: 'Wersja robocza została pomyślnie zapisana.',
|
||||
lastSavedAgo: 'Ostatnio zapisane {{distance}} temu',
|
||||
noFurtherVersionsFound: 'Nie znaleziono dalszych wersji',
|
||||
noRowsFound: 'Nie znaleziono {{label}}',
|
||||
preview: 'Podgląd',
|
||||
@@ -276,7 +278,6 @@ export default {
|
||||
selectLocales: 'Wybierz ustawienia regionalne do wyświetlenia',
|
||||
selectVersionToCompare: 'Wybierz wersję do porównania',
|
||||
showLocales: 'Pokaż ustawienia regionalne:',
|
||||
type: 'Typ',
|
||||
unpublish: 'Cofnij publikację',
|
||||
unpublishing: 'Cofanie publikacji...',
|
||||
version: 'Wersja',
|
||||
|
||||
@@ -240,6 +240,7 @@ export default {
|
||||
requiresAtLeast: 'Esse campo requer no máximo {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Tipo',
|
||||
aboutToPublishSelection:
|
||||
'Você está prestes a publicar todos os {{label}} da seleção. Tem certeza?',
|
||||
aboutToRestore:
|
||||
@@ -261,6 +262,7 @@ export default {
|
||||
confirmVersionRestoration: 'Confirmar Restauração de versão',
|
||||
draft: 'Rascunho',
|
||||
draftSavedSuccessfully: 'Rascunho salvo com sucesso.',
|
||||
lastSavedAgo: 'Última gravação há {{distance}}',
|
||||
noFurtherVersionsFound: 'Nenhuma outra versão encontrada',
|
||||
noRowsFound: 'Nenhum(a) {{label}} encontrado(a)',
|
||||
preview: 'Pré-visualização',
|
||||
@@ -268,6 +270,7 @@ export default {
|
||||
publish: 'Publicar',
|
||||
publishChanges: 'Publicar alterações',
|
||||
published: 'Publicado',
|
||||
publishing: 'Publicação',
|
||||
restoreThisVersion: 'Restaurar essa versão',
|
||||
restoredSuccessfully: 'Restaurado com sucesso.',
|
||||
restoring: 'Restaurando...',
|
||||
@@ -276,7 +279,6 @@ export default {
|
||||
selectLocales: 'Selecione as localizações para exibir',
|
||||
selectVersionToCompare: 'Selecione uma versão para comparar',
|
||||
showLocales: 'Exibir localizações:',
|
||||
type: 'Tipo',
|
||||
unpublish: 'Despublicar',
|
||||
unpublishing: 'Despublicando...',
|
||||
version: 'Versão',
|
||||
|
||||
@@ -240,6 +240,7 @@ export default {
|
||||
requiresAtLeast: 'Acest domeniu necesită cel puțin {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Tip',
|
||||
aboutToPublishSelection:
|
||||
'Sunteți pe cale să publicați toate {{label}} din selecție. Sunteți sigur?',
|
||||
aboutToRestore:
|
||||
@@ -261,6 +262,7 @@ export default {
|
||||
confirmVersionRestoration: 'Confirmați restaurarea versiunii',
|
||||
draft: 'Proiect',
|
||||
draftSavedSuccessfully: 'Proiect salvat cu succes.',
|
||||
lastSavedAgo: 'Ultima salvare acum {{distance}}',
|
||||
noFurtherVersionsFound: 'Nu s-au găsit alte versiuni',
|
||||
noRowsFound: 'Nu s-a găsit niciun {{label}}',
|
||||
preview: 'Previzualizare',
|
||||
@@ -276,7 +278,6 @@ export default {
|
||||
selectLocales: 'Selectați localitățile de afișat',
|
||||
selectVersionToCompare: 'Selectați o versiune pentru a compara',
|
||||
showLocales: 'Afișați localitățile:',
|
||||
type: 'Tip',
|
||||
unpublish: 'Dezpublicare',
|
||||
unpublishing: 'Dezpublicare...',
|
||||
version: 'Versiune',
|
||||
|
||||
@@ -239,6 +239,7 @@ export default {
|
||||
requiresAtLeast: 'Ovo polje zahteva minimalno {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Tip',
|
||||
aboutToPublishSelection: 'Upravo ćete objaviti sve {{label}} u izboru. Da li ste sigurni?',
|
||||
aboutToRestore: 'Vratićete {{label}} dokument u stanje u kojem je bio {{versionDate}}',
|
||||
aboutToRestoreGlobal: 'Vratićete globalni {{label}} u stanje u kojem je bio {{versionDate}}.',
|
||||
@@ -257,13 +258,15 @@ export default {
|
||||
confirmVersionRestoration: 'Potvrdite vraćanje verzije',
|
||||
draft: 'Nacrt',
|
||||
draftSavedSuccessfully: 'Nacrt uspešno sačuvan.',
|
||||
lastSavedAgo: 'Zadnji put sačuvano pre {{distance}',
|
||||
noFurtherVersionsFound: 'Nisu pronađene naredne verzije',
|
||||
noRowsFound: '{{label}} nije pronađeno',
|
||||
preview: 'Pregled',
|
||||
problemRestoringVersion: 'Nastao je problem pri vraćanju ove verzije',
|
||||
publish: 'Objaviti',
|
||||
publishChanges: 'Objavi promene',
|
||||
publishChanges: 'Objavljivanje',
|
||||
published: 'Objavljeno',
|
||||
publishing: 'Objavljivanje',
|
||||
restoreThisVersion: 'Vrati ovu verziju',
|
||||
restoredSuccessfully: 'Uspešno vraćeno.',
|
||||
restoring: 'Vraćanje...',
|
||||
@@ -272,7 +275,6 @@ export default {
|
||||
selectLocales: 'Odaberite jezike',
|
||||
selectVersionToCompare: 'Odaberite verziju za upoređivanje',
|
||||
showLocales: 'Prikaži jezike:',
|
||||
type: 'Tip',
|
||||
unpublish: 'Poništi objavu',
|
||||
unpublishing: 'Poništavanje objave...',
|
||||
version: 'Verzija',
|
||||
|
||||
@@ -239,6 +239,7 @@ export default {
|
||||
requiresAtLeast: 'Ово поље захтева минимално {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Тип',
|
||||
aboutToPublishSelection: 'Управо ћете објавити све {{label}} у избору. Да ли сте сигурни?',
|
||||
aboutToRestore: 'Вратићете {{label}} документ у стање у којем је био {{versionDate}}',
|
||||
aboutToRestoreGlobal: 'Вратићете глобални {{label}} у стање у којем је био {{versionDate}}.',
|
||||
@@ -256,6 +257,7 @@ export default {
|
||||
confirmVersionRestoration: 'Потврдите враћање верзије',
|
||||
draft: 'Нацрт',
|
||||
draftSavedSuccessfully: 'Нацрт успешно сачуван.',
|
||||
lastSavedAgo: 'Задњи пут сачувано пре {{distance}',
|
||||
noFurtherVersionsFound: 'Нису пронађене наредне верзије',
|
||||
noRowsFound: '{{label}} није пронађено',
|
||||
preview: 'Преглед',
|
||||
@@ -263,6 +265,7 @@ export default {
|
||||
publish: 'Објавити',
|
||||
publishChanges: 'Објави промене',
|
||||
published: 'Објављено',
|
||||
publishing: 'Objavljivanje',
|
||||
restoreThisVersion: 'Врати ову верзију',
|
||||
restoredSuccessfully: 'Успешно враћено.',
|
||||
restoring: 'Враћање...',
|
||||
@@ -271,7 +274,6 @@ export default {
|
||||
selectLocales: 'Одаберите језике',
|
||||
selectVersionToCompare: 'Одаберите верзију за упоређивање',
|
||||
showLocales: 'Прикажи језике:',
|
||||
type: 'Тип',
|
||||
unpublish: 'Поништи објаву',
|
||||
unpublishing: 'Поништавање објаве...',
|
||||
version: 'Верзија',
|
||||
|
||||
@@ -241,6 +241,7 @@ export default {
|
||||
requiresAtLeast: 'Это поле требует не менее {{count}} {{label}}',
|
||||
},
|
||||
version: {
|
||||
type: 'Тип',
|
||||
aboutToPublishSelection: 'Вы собираетесь опубликовать все {{label}} в выборе. Вы уверены?',
|
||||
aboutToRestore:
|
||||
'Вы собираетесь восстановить этот документ {{label}} в состояние, в котором он находился {{versionDate}}.',
|
||||
@@ -261,6 +262,7 @@ export default {
|
||||
confirmVersionRestoration: 'Подтвердить восстановление версии',
|
||||
draft: 'Черновик',
|
||||
draftSavedSuccessfully: 'Черновик успешно сохранен.',
|
||||
lastSavedAgo: 'Последний раз сохранено {{distance}} назад',
|
||||
noFurtherVersionsFound: 'Другие версии не найдены',
|
||||
noRowsFound: 'Не найдено {{label}}',
|
||||
preview: 'Предпросмотр',
|
||||
@@ -268,6 +270,7 @@ export default {
|
||||
publish: 'Публиковать',
|
||||
publishChanges: 'Опубликовать изменения',
|
||||
published: 'Опубликовано',
|
||||
publishing: 'Публикация',
|
||||
restoreThisVersion: 'Восстановить эту версию',
|
||||
restoredSuccessfully: 'Восстановлен успешно.',
|
||||
restoring: 'Восстановление...',
|
||||
@@ -276,7 +279,6 @@ export default {
|
||||
selectLocales: 'Выберите локали для отображения',
|
||||
selectVersionToCompare: 'Выбрать версию для сравнения',
|
||||
showLocales: 'Показать локали:',
|
||||
type: 'Тип',
|
||||
unpublish: 'Отменить публикацию',
|
||||
unpublishing: 'Отмена публикации...',
|
||||
version: 'Версия',
|
||||
|
||||
@@ -240,6 +240,7 @@ export default {
|
||||
requiresAtLeast: 'Detta fält kräver minst {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Typ',
|
||||
aboutToPublishSelection: 'Du är på väg att publicera alla {{label}} i urvalet. Är du säker?',
|
||||
aboutToRestore:
|
||||
'Du är på väg att återställa detta {{label}} dokumentet till det tillståndet som det var den {{versionDate}}.',
|
||||
@@ -260,6 +261,7 @@ export default {
|
||||
confirmVersionRestoration: 'Bekräfta Versionsåterställning',
|
||||
draft: 'Utkast',
|
||||
draftSavedSuccessfully: 'Utkastet sparades framgångsrikt.',
|
||||
lastSavedAgo: 'Senast sparad för {{distance}} sedan',
|
||||
noFurtherVersionsFound: 'Inga fler versioner hittades',
|
||||
noRowsFound: 'Inga {{label}} hittades',
|
||||
preview: 'Förhandsvisa',
|
||||
@@ -267,6 +269,7 @@ export default {
|
||||
publish: 'Publicera',
|
||||
publishChanges: 'Publicera ändringar',
|
||||
published: 'Publicerad',
|
||||
publishing: 'Publicering',
|
||||
restoreThisVersion: 'Återställ den här versionen',
|
||||
restoredSuccessfully: 'Återställd framgångsrikt.',
|
||||
restoring: 'Återställer...',
|
||||
@@ -275,7 +278,6 @@ export default {
|
||||
selectLocales: 'Välj språk att visa',
|
||||
selectVersionToCompare: 'Välj en version att jämföra',
|
||||
showLocales: 'Visa språk:',
|
||||
type: 'Typ',
|
||||
unpublish: 'Avpublicera',
|
||||
unpublishing: 'Avpublicerar...',
|
||||
version: 'Version',
|
||||
|
||||
@@ -236,6 +236,7 @@ export default {
|
||||
requiresAtLeast: 'ต้องมีอย่างน้อย {{count}} {{label}}',
|
||||
},
|
||||
version: {
|
||||
type: 'ประเภท',
|
||||
aboutToPublishSelection: 'คุณกำลังจะเผยแพร่ {{label}} ทั้งหมดในส่วนที่เลือก คุณแน่ใจไหม?',
|
||||
aboutToRestore:
|
||||
'คุณกำลังจะคืนค่าเอกสาร {{label}} นี้กลับไปอยู่ในเวอร์ชันเมื่อวันที่ {{versionDate}}',
|
||||
@@ -255,6 +256,7 @@ export default {
|
||||
confirmVersionRestoration: 'ยืนยันการกู้คืนเวอร์ชัน',
|
||||
draft: 'ฉบับร่าง',
|
||||
draftSavedSuccessfully: 'บันทึกร่างสำเร็จ',
|
||||
lastSavedAgo: 'บันทึกครั้งล่าสุด {{distance}} ที่ผ่านมา',
|
||||
noFurtherVersionsFound: 'ไม่พบเวอร์ชันอื่น ๆ',
|
||||
noRowsFound: 'ไม่พบ {{label}}',
|
||||
preview: 'ตัวอย่าง',
|
||||
@@ -262,6 +264,7 @@ export default {
|
||||
publish: 'เผยแพร่',
|
||||
publishChanges: 'เผยแพร่การแก้ไข',
|
||||
published: 'เผยแพร่แล้ว',
|
||||
publishing: 'การเผยแพร่',
|
||||
restoreThisVersion: 'กู้คืนเวอร์ชันนี้',
|
||||
restoredSuccessfully: 'กู้คืนเวอร์ชันสำเร็จ',
|
||||
restoring: 'กำลังกู้คืน...',
|
||||
@@ -270,7 +273,6 @@ export default {
|
||||
selectLocales: 'เลือกภาษาที่ต้องการแสดง',
|
||||
selectVersionToCompare: 'เลือกเวอร์ชันที่ต้องการเปรียบเทียบ',
|
||||
showLocales: 'แสดงภาษา:',
|
||||
type: 'ประเภท',
|
||||
unpublish: 'หยุดเผยแพร่',
|
||||
unpublishing: 'กำลังหยุดการเผยแพร่...',
|
||||
version: 'เวอร์ชัน',
|
||||
|
||||
@@ -242,6 +242,7 @@ export default {
|
||||
requiresAtLeast: 'Bu alan en az {{count}} adet {{label}} gerektirmektedir.',
|
||||
},
|
||||
version: {
|
||||
type: 'Tür',
|
||||
aboutToPublishSelection: "Seçimdeki tüm {{label}}'i yayınlamak üzeresiniz. Emin misin?",
|
||||
aboutToRestore: 'Döküman {{label}}, {{versionDate}} tarihindeki sürümüne geri döndürülecek.',
|
||||
aboutToRestoreGlobal:
|
||||
@@ -260,6 +261,7 @@ export default {
|
||||
confirmVersionRestoration: 'Sürümü Geri Getirmeyi Onayla',
|
||||
draft: 'Taslak',
|
||||
draftSavedSuccessfully: 'Taslak başarıyla kaydedildi.',
|
||||
lastSavedAgo: 'Son kaydedildi {{distance}} önce',
|
||||
noFurtherVersionsFound: 'Başka sürüm bulunamadı.',
|
||||
noRowsFound: '{{label}} bulunamadı',
|
||||
preview: 'Önizleme',
|
||||
@@ -267,6 +269,7 @@ export default {
|
||||
publish: 'Yayınla',
|
||||
publishChanges: 'Değişiklikleri yayınla',
|
||||
published: 'Yayınlandı',
|
||||
publishing: 'Yayınlama',
|
||||
restoreThisVersion: 'Bu sürüme geri döndür',
|
||||
restoredSuccessfully: 'Geri getirme başarılı.',
|
||||
restoring: 'Geri döndürülüyor...',
|
||||
@@ -275,7 +278,6 @@ export default {
|
||||
selectLocales: 'Görüntülenecek yerel ayarları seçin',
|
||||
selectVersionToCompare: 'Karşılaştırılacak bir sürüm seçin',
|
||||
showLocales: 'Yerel ayarları göster:',
|
||||
type: 'Tür',
|
||||
unpublish: 'Yayından Kaldır',
|
||||
unpublishing: 'Yayından kaldırılıyor...',
|
||||
version: 'Sürüm',
|
||||
|
||||
@@ -239,6 +239,7 @@ export default {
|
||||
requiresAtLeast: 'Це поле потребує не менше {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Тип',
|
||||
aboutToPublishSelection: 'Ви збираєтеся опублікувати всі {{label}} у добірці. Ти впевнений?',
|
||||
aboutToRestore:
|
||||
'Ви збираєтесь відновити цей документ {{label}} до стану, в якому він знаходився {{versionDate}}.',
|
||||
@@ -259,6 +260,7 @@ export default {
|
||||
confirmVersionRestoration: 'Підтвердити відновлення версії',
|
||||
draft: 'Чернетка',
|
||||
draftSavedSuccessfully: 'Чернетка успішно збережена.',
|
||||
lastSavedAgo: 'Останній раз збережено {{distance}} тому',
|
||||
noFurtherVersionsFound: 'Інших версій не знайдено',
|
||||
noRowsFound: 'Не знайдено {{label}}',
|
||||
preview: 'Попередній перегляд',
|
||||
@@ -266,6 +268,7 @@ export default {
|
||||
publish: 'Опублікувати',
|
||||
publishChanges: 'Опублікувати зміни',
|
||||
published: 'Опубліковано',
|
||||
publishing: 'Публікація',
|
||||
restoreThisVersion: 'Відновити цю версію',
|
||||
restoredSuccessfully: 'Відновлено успішно.',
|
||||
restoring: 'Відеовлення...',
|
||||
@@ -274,7 +277,6 @@ export default {
|
||||
selectLocales: 'Виберіть переклад для відображення',
|
||||
selectVersionToCompare: 'Виберіть версію для порівняння',
|
||||
showLocales: 'Показати переклади:',
|
||||
type: 'Тип',
|
||||
unpublish: 'Відмінити публікацію',
|
||||
unpublishing: 'Відміна публікації...',
|
||||
version: 'Версія',
|
||||
|
||||
@@ -238,6 +238,7 @@ export default {
|
||||
requiresAtLeast: 'Field này cần tối thiểu {{count}} {{label}}.',
|
||||
},
|
||||
version: {
|
||||
type: 'Loại',
|
||||
aboutToPublishSelection: 'Bạn có muốn xuất bản tất cả {{label}} không?',
|
||||
aboutToRestore: 'Bạn chuẩn bị khôi phục lại {{label}} về phiên bản {{versionDate}}.',
|
||||
aboutToRestoreGlobal:
|
||||
@@ -255,6 +256,7 @@ export default {
|
||||
confirmVersionRestoration: 'Xác nhận, khôi phục về phiên bản trước',
|
||||
draft: 'Bản nháp',
|
||||
draftSavedSuccessfully: 'Bản nháp đã được lưu thành công.',
|
||||
lastSavedAgo: 'Lần lưu cuối cùng {{distance}} trước đây',
|
||||
noFurtherVersionsFound: 'Không tìm thấy phiên bản cũ hơn',
|
||||
noRowsFound: 'Không tìm thấy: {{label}}',
|
||||
preview: 'Bản xem trước',
|
||||
@@ -262,6 +264,7 @@ export default {
|
||||
publish: 'Công bố',
|
||||
publishChanges: 'Xuất bản tài liệu',
|
||||
published: 'Đã xuất bản',
|
||||
publishing: 'Xuất bản',
|
||||
restoreThisVersion: 'Khôi phục về phiên bản này',
|
||||
restoredSuccessfully: 'Đã khôi phục thành công.',
|
||||
restoring: 'Đang khôi phục...',
|
||||
@@ -270,7 +273,6 @@ export default {
|
||||
selectLocales: 'Chọn mã khu vực để hiện thị',
|
||||
selectVersionToCompare: 'Chọn phiên bản để so sánh',
|
||||
showLocales: 'Hiển thị mã khu vực:',
|
||||
type: 'Loại',
|
||||
unpublish: 'Ẩn tài liệu',
|
||||
unpublishing: 'Đang ẩn tài liệu...',
|
||||
version: 'Phiên bản',
|
||||
|
||||
@@ -237,6 +237,7 @@ export default {
|
||||
requiresAtLeast: '該字串至少需要 {{count}} 個 {{label}}。',
|
||||
},
|
||||
version: {
|
||||
type: '類型',
|
||||
aboutToPublishSelection: '您確定即將發佈所選的 {{label}} 嗎?',
|
||||
aboutToRestore: '您將把這個文件{{label}}回復到{{versionDate}}時的狀態',
|
||||
aboutToRestoreGlobal: '您要將痊域的{{label}}回復到{{versionDate}}時的狀態',
|
||||
@@ -253,6 +254,7 @@ export default {
|
||||
confirmVersionRestoration: '確認版本回復',
|
||||
draft: '草稿',
|
||||
draftSavedSuccessfully: '草稿儲存成功。',
|
||||
lastSavedAgo: '上次儲存在{{distance}}之前',
|
||||
noFurtherVersionsFound: '沒有發現其他版本',
|
||||
noRowsFound: '沒有發現{{label}}',
|
||||
preview: '預覽',
|
||||
@@ -260,6 +262,7 @@ export default {
|
||||
publish: '發佈',
|
||||
publishChanges: '發佈修改',
|
||||
published: '已發佈',
|
||||
publishing: '發布',
|
||||
restoreThisVersion: '回復此版本',
|
||||
restoredSuccessfully: '回復成功。',
|
||||
restoring: '回復中...',
|
||||
@@ -268,7 +271,6 @@ export default {
|
||||
selectLocales: '選擇要顯示的語言',
|
||||
selectVersionToCompare: '選擇要比較的版本',
|
||||
showLocales: '顯示語言:',
|
||||
type: '類型',
|
||||
unpublish: '取消發佈',
|
||||
unpublishing: '取消發佈中...',
|
||||
version: '版本',
|
||||
|
||||
@@ -235,6 +235,7 @@ export default {
|
||||
requiresAtLeast: '该字段至少需要{{count}} {{label}}。',
|
||||
},
|
||||
version: {
|
||||
type: '类型',
|
||||
aboutToPublishSelection: '您即将发布所选内容中的所有 {{label}}。 你确定吗?',
|
||||
aboutToRestore: '您将把这个{{label}}文档恢复到{{versionDate}}时的状态',
|
||||
aboutToRestoreGlobal: '您要将全局的{{label}}恢复到{{versionDate}}时的状态',
|
||||
@@ -251,6 +252,7 @@ export default {
|
||||
confirmVersionRestoration: '确认版本恢复',
|
||||
draft: '草稿',
|
||||
draftSavedSuccessfully: '草稿成功保存。',
|
||||
lastSavedAgo: '上次保存{{distance}}之前',
|
||||
noFurtherVersionsFound: '没有发现其他版本',
|
||||
noRowsFound: '没有发现{{label}}',
|
||||
preview: '预览',
|
||||
@@ -258,6 +260,7 @@ export default {
|
||||
publish: '发布',
|
||||
publishChanges: '发布修改',
|
||||
published: '已发布',
|
||||
publishing: '发布',
|
||||
restoreThisVersion: '恢复此版本',
|
||||
restoredSuccessfully: '恢复成功。',
|
||||
restoring: '恢复中...',
|
||||
@@ -266,7 +269,6 @@ export default {
|
||||
selectLocales: '选择要显示的语言',
|
||||
selectVersionToCompare: '选择要比较的版本',
|
||||
showLocales: '显示语言:',
|
||||
type: '类型',
|
||||
unpublish: '取消发布',
|
||||
unpublishing: '取消发布中...',
|
||||
version: '版本',
|
||||
|
||||
@@ -353,6 +353,7 @@ export default {
|
||||
publish: 'نشر',
|
||||
publishChanges: 'نشر التّغييرات',
|
||||
published: 'تمّ النّشر',
|
||||
publishing: 'نشر',
|
||||
restoreThisVersion: 'استعادة هذه النّسخة',
|
||||
restoredSuccessfully: 'تمّت الاستعادة بنحاح.',
|
||||
restoring: 'تتمّ الاستعادة...',
|
||||
|
||||
@@ -361,6 +361,7 @@ export default {
|
||||
publish: 'Dərc et',
|
||||
publishChanges: 'Dəyişiklikləri dərc et',
|
||||
published: 'Dərc edilmiş',
|
||||
publishing: 'Nəşr',
|
||||
restoreThisVersion: 'Bu versiyanı bərpa et',
|
||||
restoredSuccessfully: 'Uğurla bərpa edildi.',
|
||||
restoring: 'Bərpa olunur...',
|
||||
|
||||
@@ -359,6 +359,7 @@ export default {
|
||||
publish: 'Публикувай',
|
||||
publishChanges: 'Публикувай промените',
|
||||
published: 'Публикувано',
|
||||
publishing: 'Публикуване',
|
||||
restoreThisVersion: 'Възстанови тази версия',
|
||||
restoredSuccessfully: 'Успешно възстановяване.',
|
||||
restoring: 'Възстановяване...',
|
||||
|
||||
@@ -357,6 +357,7 @@ export default {
|
||||
publish: 'Publikovat',
|
||||
publishChanges: 'Publikovat změny',
|
||||
published: 'Publikováno',
|
||||
publishing: 'Publikování',
|
||||
restoreThisVersion: 'Obnovit tuto verzi',
|
||||
restoredSuccessfully: 'Úspěšně obnoveno.',
|
||||
restoring: 'Obnovování...',
|
||||
|
||||
@@ -363,6 +363,7 @@ export default {
|
||||
publish: 'Veröffentlichen',
|
||||
publishChanges: 'Änderungen veröffentlichen',
|
||||
published: 'Veröffentlicht',
|
||||
publishing: 'Veröffentlichung',
|
||||
restoreThisVersion: 'Diese Version wiederherstellen',
|
||||
restoredSuccessfully: 'Erfolgreich wiederhergestellt.',
|
||||
restoring: 'wiederherstellen...',
|
||||
|
||||
@@ -362,6 +362,7 @@ export default {
|
||||
publish: 'Publish',
|
||||
publishChanges: 'Publish changes',
|
||||
published: 'Published',
|
||||
publishing: 'Publishing',
|
||||
restoreThisVersion: 'Restore this version',
|
||||
restoredSuccessfully: 'Restored Successfully.',
|
||||
restoring: 'Restoring...',
|
||||
|
||||
@@ -361,6 +361,7 @@ export default {
|
||||
publish: 'Publicar',
|
||||
publishChanges: 'Publicar cambios',
|
||||
published: 'Publicado',
|
||||
publishing: 'Publicación',
|
||||
restoreThisVersion: 'Restaurar esta versión',
|
||||
restoredSuccessfully: 'Restaurado éxito.',
|
||||
restoring: 'Restaurando...',
|
||||
|
||||
@@ -357,6 +357,7 @@ export default {
|
||||
publish: 'انتشار',
|
||||
publishChanges: 'انتشار تغییرات',
|
||||
published: 'انتشار یافته',
|
||||
publishing: 'انتشار',
|
||||
restoreThisVersion: 'این نگارش را بازیابی کنید',
|
||||
restoredSuccessfully: 'با موفقیت بازیابی شد.',
|
||||
restoring: 'در حال بازیابی...',
|
||||
|
||||
@@ -370,6 +370,7 @@ export default {
|
||||
publish: 'Publier',
|
||||
publishChanges: 'Publier les modifications',
|
||||
published: 'Publié',
|
||||
publishing: 'Publication',
|
||||
restoreThisVersion: 'Restaurer cette version',
|
||||
restoredSuccessfully: 'Restauré(e) avec succès.',
|
||||
restoring: 'Restauration en cours...',
|
||||
|
||||
@@ -357,6 +357,7 @@ export default {
|
||||
publish: 'Objaviti',
|
||||
publishChanges: 'Objavi promjene',
|
||||
published: 'Objavljeno',
|
||||
publishing: 'Objavljivanje',
|
||||
restoreThisVersion: 'Vrati ovu verziju',
|
||||
restoredSuccessfully: 'Uspješno vraćeno.',
|
||||
restoring: 'Vraćanje...',
|
||||
|
||||
@@ -364,6 +364,7 @@ export default {
|
||||
publish: 'Közzététel',
|
||||
publishChanges: 'Módosítások közzététele',
|
||||
published: 'Közzétett',
|
||||
publishing: 'Közzététel',
|
||||
restoreThisVersion: 'A verzió visszaállítása',
|
||||
restoredSuccessfully: 'Sikeresen visszaállítva.',
|
||||
restoring: 'Visszaállítás...',
|
||||
|
||||
@@ -364,6 +364,7 @@ export default {
|
||||
publish: 'Pubblicare',
|
||||
publishChanges: 'Pubblica modifiche',
|
||||
published: 'Pubblicato',
|
||||
publishing: 'Pubblicazione',
|
||||
restoreThisVersion: 'Ripristina questa versione',
|
||||
restoredSuccessfully: 'Ripristinato con successo.',
|
||||
restoring: 'Ripristino...',
|
||||
|
||||
@@ -360,6 +360,7 @@ export default {
|
||||
publish: '公開する',
|
||||
publishChanges: '変更内容を公開',
|
||||
published: '公開済み',
|
||||
publishing: '公開',
|
||||
restoreThisVersion: 'このバージョンを復元',
|
||||
restoredSuccessfully: '正常に復元されました。',
|
||||
restoring: '復元しています...',
|
||||
|
||||
@@ -354,6 +354,7 @@ export default {
|
||||
publish: '게시',
|
||||
publishChanges: '변경 사항 게시',
|
||||
published: '게시됨',
|
||||
publishing: '게시',
|
||||
restoreThisVersion: '이 버전 복원',
|
||||
restoredSuccessfully: '복원이 완료되었습니다.',
|
||||
restoring: '복원 중...',
|
||||
|
||||
@@ -366,6 +366,7 @@ export default {
|
||||
publish: 'ထုတ်ဝေသည်။',
|
||||
publishChanges: 'အပြောင်းအလဲများကို တင်ခဲ့သည်။',
|
||||
published: 'တင်ပြီးပြီ။',
|
||||
publishing: 'ထုတ်ဝေခြင်း',
|
||||
restoreThisVersion: 'ဤဗားရှင်းကိုကို ပြန်ယူမည်။',
|
||||
restoredSuccessfully: 'အောင်မြင်စွာ ပြန်လည်ရယူခဲ့သည်။',
|
||||
restoring: 'ပြန်ယူနေဆဲ...',
|
||||
|
||||
@@ -360,6 +360,7 @@ export default {
|
||||
publish: 'Publisere',
|
||||
publishChanges: 'Publiser endringer',
|
||||
published: 'Publisert',
|
||||
publishing: 'Publisering',
|
||||
restoreThisVersion: 'Gjenopprett denne versjonen',
|
||||
restoredSuccessfully: 'Gjenopprettet.',
|
||||
restoring: 'Gjenoppretter...',
|
||||
|
||||
@@ -363,6 +363,7 @@ export default {
|
||||
publish: 'Publiceren',
|
||||
publishChanges: 'Publiceer wijzigingen',
|
||||
published: 'Gepubliceerd',
|
||||
publishing: 'Publicatie',
|
||||
restoreThisVersion: 'Herstel deze versie',
|
||||
restoredSuccessfully: 'Herstelling succesvol.',
|
||||
restoring: 'Herstellen...',
|
||||
|
||||
@@ -361,6 +361,7 @@ export default {
|
||||
publish: 'Publikuj',
|
||||
publishChanges: 'Opublikuj zmiany',
|
||||
published: 'Opublikowano',
|
||||
publising: 'Publikacja',
|
||||
restoreThisVersion: 'Przywróć tę wersję',
|
||||
restoredSuccessfully: 'Przywrócono pomyślnie.',
|
||||
restoring: 'Przywracanie...',
|
||||
|
||||
@@ -361,6 +361,7 @@ export default {
|
||||
publish: 'Publicar',
|
||||
publishChanges: 'Publicar alterações',
|
||||
published: 'Publicado',
|
||||
publishing: 'Publicação',
|
||||
restoreThisVersion: 'Restaurar essa versão',
|
||||
restoredSuccessfully: 'Restaurado com sucesso.',
|
||||
restoring: 'Restaurando...',
|
||||
|
||||
@@ -367,6 +367,7 @@ export default {
|
||||
publish: 'Publicați',
|
||||
publishChanges: 'Publicați modificările',
|
||||
published: 'Publicat',
|
||||
publishin: 'Publicare',
|
||||
restoreThisVersion: 'Restaurați această versiune',
|
||||
restoredSuccessfully: 'Restaurat cu succes.',
|
||||
restoring: 'Restaurare...',
|
||||
|
||||
@@ -354,8 +354,9 @@ export default {
|
||||
preview: 'Pregled',
|
||||
problemRestoringVersion: 'Nastao je problem pri vraćanju ove verzije',
|
||||
publish: 'Objaviti',
|
||||
publishChanges: 'Objavi promene',
|
||||
publishChanges: 'Objavljivanje',
|
||||
published: 'Objavljeno',
|
||||
publishing: 'Objavljivanje',
|
||||
restoreThisVersion: 'Vrati ovu verziju',
|
||||
restoredSuccessfully: 'Uspešno vraćeno.',
|
||||
restoring: 'Vraćanje...',
|
||||
|
||||
@@ -355,6 +355,7 @@ export default {
|
||||
publish: 'Објавити',
|
||||
publishChanges: 'Објави промене',
|
||||
published: 'Објављено',
|
||||
publishing: 'Objavljivanje',
|
||||
restoreThisVersion: 'Врати ову верзију',
|
||||
restoredSuccessfully: 'Успешно враћено.',
|
||||
restoring: 'Враћање...',
|
||||
|
||||
@@ -362,6 +362,7 @@ export default {
|
||||
publish: 'Публиковать',
|
||||
publishChanges: 'Опубликовать изменения',
|
||||
published: 'Опубликовано',
|
||||
publishing: 'Публикация',
|
||||
restoreThisVersion: 'Восстановить эту версию',
|
||||
restoredSuccessfully: 'Восстановлен успешно.',
|
||||
restoring: 'Восстановление...',
|
||||
|
||||
@@ -359,6 +359,7 @@ export default {
|
||||
publish: 'Publicera',
|
||||
publishChanges: 'Publicera ändringar',
|
||||
published: 'Publicerad',
|
||||
publishing: 'Publicering',
|
||||
restoreThisVersion: 'Återställ den här versionen',
|
||||
restoredSuccessfully: 'Återställd framgångsrikt.',
|
||||
restoring: 'Återställer...',
|
||||
|
||||
@@ -352,6 +352,7 @@ export default {
|
||||
publish: 'เผยแพร่',
|
||||
publishChanges: 'เผยแพร่การแก้ไข',
|
||||
published: 'เผยแพร่แล้ว',
|
||||
publishing: 'การเผยแพร่',
|
||||
restoreThisVersion: 'กู้คืนเวอร์ชันนี้',
|
||||
restoredSuccessfully: 'กู้คืนเวอร์ชันสำเร็จ',
|
||||
restoring: 'กำลังกู้คืน...',
|
||||
|
||||
@@ -361,6 +361,7 @@ export default {
|
||||
publish: 'Yayınla',
|
||||
publishChanges: 'Değişiklikleri yayınla',
|
||||
published: 'Yayınlandı',
|
||||
publishing: 'Yayınlama',
|
||||
restoreThisVersion: 'Bu sürüme geri döndür',
|
||||
restoredSuccessfully: 'Geri getirme başarılı.',
|
||||
restoring: 'Geri döndürülüyor...',
|
||||
|
||||
@@ -358,6 +358,7 @@ export default {
|
||||
publish: 'Опублікувати',
|
||||
publishChanges: 'Опублікувати зміни',
|
||||
published: 'Опубліковано',
|
||||
publishing: 'Публікація',
|
||||
restoreThisVersion: 'Відновити цю версію',
|
||||
restoredSuccessfully: 'Відновлено успішно.',
|
||||
restoring: 'Відеовлення...',
|
||||
|
||||
@@ -354,6 +354,7 @@ export default {
|
||||
publish: 'Công bố',
|
||||
publishChanges: 'Xuất bản tài liệu',
|
||||
published: 'Đã xuất bản',
|
||||
publishing: 'Xuất bản',
|
||||
restoreThisVersion: 'Khôi phục về phiên bản này',
|
||||
restoredSuccessfully: 'Đã khôi phục thành công.',
|
||||
restoring: 'Đang khôi phục...',
|
||||
|
||||
@@ -347,6 +347,7 @@ export default {
|
||||
publish: '發佈',
|
||||
publishChanges: '發佈修改',
|
||||
published: '已發佈',
|
||||
publishing: '發布',
|
||||
restoreThisVersion: '回復此版本',
|
||||
restoredSuccessfully: '回復成功。',
|
||||
restoring: '回復中...',
|
||||
|
||||
@@ -345,6 +345,7 @@ export default {
|
||||
publish: '发布',
|
||||
publishChanges: '发布修改',
|
||||
published: '已发布',
|
||||
publishing: '发布',
|
||||
restoreThisVersion: '恢复此版本',
|
||||
restoredSuccessfully: '恢复成功。',
|
||||
restoring: '恢复中...',
|
||||
|
||||
@@ -221,7 +221,6 @@ const clientTranslationKeys = [
|
||||
'general:globals',
|
||||
'general:language',
|
||||
'general:lastModified',
|
||||
'general:lastSavedAgo',
|
||||
'general:leaveAnyway',
|
||||
'general:leaveWithoutSaving',
|
||||
'general:light',
|
||||
@@ -328,6 +327,7 @@ const clientTranslationKeys = [
|
||||
'version:confirmVersionRestoration',
|
||||
'version:draft',
|
||||
'version:draftSavedSuccessfully',
|
||||
'version:lastSavedAgo',
|
||||
'version:noFurtherVersionsFound',
|
||||
'version:noRowsFound',
|
||||
'version:preview',
|
||||
|
||||
@@ -18,7 +18,12 @@ import './index.scss'
|
||||
|
||||
const baseClass = 'autosave'
|
||||
|
||||
const Autosave: React.FC<Props> = ({ id, collection, global, publishedDocUpdatedAt }) => {
|
||||
const Autosave: React.FC<Props> = ({
|
||||
id,
|
||||
collection,
|
||||
global: globalDoc,
|
||||
publishedDocUpdatedAt,
|
||||
}) => {
|
||||
const {
|
||||
routes: { admin, api },
|
||||
serverURL,
|
||||
@@ -53,6 +58,10 @@ const Autosave: React.FC<Props> = ({ id, collection, global, publishedDocUpdated
|
||||
// timing out during autosave
|
||||
modifiedRef.current = modified
|
||||
|
||||
// Store locale in ref so the autosave func
|
||||
// can always retrieve the most to date locale
|
||||
localeRef.current = locale
|
||||
|
||||
const createCollectionDoc = useCallback(async () => {
|
||||
const res = await fetch(
|
||||
`${serverURL}${api}/${collection.slug}?locale=${locale}&fallback-locale=null&depth=0&draft=true&autosave=true`,
|
||||
@@ -88,9 +97,8 @@ const Autosave: React.FC<Props> = ({ id, collection, global, publishedDocUpdated
|
||||
}, [id, collection, createCollectionDoc])
|
||||
|
||||
// When debounced fields change, autosave
|
||||
|
||||
useEffect(() => {
|
||||
const autosave = async () => {
|
||||
const autosave = () => {
|
||||
if (modified) {
|
||||
setSaving(true)
|
||||
|
||||
@@ -102,8 +110,8 @@ const Autosave: React.FC<Props> = ({ id, collection, global, publishedDocUpdated
|
||||
method = 'PATCH'
|
||||
}
|
||||
|
||||
if (global) {
|
||||
url = `${serverURL}${api}/globals/${global.slug}?draft=true&autosave=true&locale=${localeRef.current}`
|
||||
if (globalDoc) {
|
||||
url = `${serverURL}${api}/globals/${globalDoc.slug}?draft=true&autosave=true&locale=${localeRef.current}`
|
||||
method = 'POST'
|
||||
}
|
||||
|
||||
@@ -114,7 +122,6 @@ const Autosave: React.FC<Props> = ({ id, collection, global, publishedDocUpdated
|
||||
...reduceFieldsToValues(fieldRef.current, true),
|
||||
_status: 'draft',
|
||||
}
|
||||
|
||||
const res = await fetch(url, {
|
||||
body: JSON.stringify(body),
|
||||
credentials: 'include',
|
||||
@@ -138,19 +145,7 @@ const Autosave: React.FC<Props> = ({ id, collection, global, publishedDocUpdated
|
||||
}
|
||||
|
||||
void autosave()
|
||||
}, [
|
||||
i18n,
|
||||
debouncedFields,
|
||||
modified,
|
||||
serverURL,
|
||||
api,
|
||||
collection,
|
||||
global,
|
||||
id,
|
||||
getVersions,
|
||||
localeRef,
|
||||
modifiedRef,
|
||||
])
|
||||
}, [i18n, debouncedFields, modified, serverURL, api, collection, globalDoc, id, getVersions])
|
||||
|
||||
useEffect(() => {
|
||||
if (versions?.docs?.[0]) {
|
||||
@@ -162,7 +157,7 @@ const Autosave: React.FC<Props> = ({ id, collection, global, publishedDocUpdated
|
||||
|
||||
return (
|
||||
<div className={baseClass}>
|
||||
{saving && t('version:saving')}
|
||||
{saving && t('general:saving')}
|
||||
{!saving && lastSaved && (
|
||||
<React.Fragment>
|
||||
{t('version:lastSavedAgo', {
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
'use client'
|
||||
import type { CollectionPermission, GlobalPermission } from 'payload/auth'
|
||||
import type { SanitizedCollectionConfig, SanitizedGlobalConfig } from 'payload/types'
|
||||
import type { SanitizedCollectionConfig } from 'payload/types'
|
||||
|
||||
import React, { Fragment } from 'react'
|
||||
|
||||
import { useConfig } from '../../providers/Config/index.js'
|
||||
import { useDocumentInfo } from '../../providers/DocumentInfo/index.js'
|
||||
import { useTranslation } from '../../providers/Translation/index.js'
|
||||
import { formatDate } from '../../utilities/formatDate/index.js'
|
||||
import Autosave from '../Autosave/index.js'
|
||||
@@ -100,12 +99,12 @@ export const DocumentControls: React.FC<{
|
||||
(globalConfig?.versions?.drafts && globalConfig?.versions?.drafts?.autosave)) &&
|
||||
hasSavePermission && (
|
||||
<li className={`${baseClass}__list-item`}>
|
||||
{/* <Autosave
|
||||
<Autosave
|
||||
collection={collectionConfig}
|
||||
global={globalConfig}
|
||||
id={id}
|
||||
publishedDocUpdatedAt={data?.createdAt}
|
||||
/> */}
|
||||
/>
|
||||
</li>
|
||||
)}
|
||||
</Fragment>
|
||||
|
||||
@@ -44,7 +44,7 @@ export const DocumentTabLink: React.FC<{
|
||||
<li className={[baseClass, isActive && `${baseClass}--active`].filter(Boolean).join(' ')}>
|
||||
<Link
|
||||
className={`${baseClass}__link`}
|
||||
href={!isActive ? href : ''}
|
||||
href={!isActive || href !== pathname ? href : ''}
|
||||
{...(newTab && { rel: 'noopener noreferrer', target: '_blank' })}
|
||||
tabIndex={isActive ? -1 : 0}
|
||||
>
|
||||
|
||||
@@ -6,6 +6,7 @@ import { getTranslation } from '@payloadcms/translations'
|
||||
import { useRouter } from 'next/navigation.js'
|
||||
import React, { useCallback, useState } from 'react'
|
||||
|
||||
import type { FormProps } from '../../index.js'
|
||||
import type { Props } from './types.js'
|
||||
|
||||
import { useForm } from '../../forms/Form/context.js'
|
||||
@@ -13,6 +14,7 @@ import Form from '../../forms/Form/index.js'
|
||||
import { RenderFields } from '../../forms/RenderFields/index.js'
|
||||
import FormSubmit from '../../forms/Submit/index.js'
|
||||
import { X } from '../../icons/X/index.js'
|
||||
import { useRouteCache } from '../../index.js'
|
||||
import { useAuth } from '../../providers/Auth/index.js'
|
||||
import { useComponentMap } from '../../providers/ComponentMapProvider/index.js'
|
||||
import { useConfig } from '../../providers/Config/index.js'
|
||||
@@ -108,6 +110,7 @@ export const EditMany: React.FC<Props> = (props) => {
|
||||
const [reducedFieldMap, setReducedFieldMap] = useState([])
|
||||
const [initialState, setInitialState] = useState<FormState>()
|
||||
const hasInitializedState = React.useRef(false)
|
||||
const { clearRouteCache } = useRouteCache()
|
||||
|
||||
const collectionPermissions = permissions?.collections?.[slug]
|
||||
const hasUpdatePermission = collectionPermissions?.update?.permission
|
||||
@@ -151,6 +154,21 @@ export const EditMany: React.FC<Props> = (props) => {
|
||||
}
|
||||
}, [apiRoute, hasInitializedState, serverURL, slug])
|
||||
|
||||
const onChange: FormProps['onChange'][0] = useCallback(
|
||||
({ formState: prevFormState }) =>
|
||||
getFormState({
|
||||
apiRoute,
|
||||
body: {
|
||||
collectionSlug: slug,
|
||||
formState: prevFormState,
|
||||
operation: 'update',
|
||||
schemaPath: slug,
|
||||
},
|
||||
serverURL,
|
||||
}),
|
||||
[serverURL, apiRoute, slug],
|
||||
)
|
||||
|
||||
if (selectAll === SelectAllStatus.None || !hasUpdatePermission) {
|
||||
return null
|
||||
}
|
||||
@@ -161,6 +179,8 @@ export const EditMany: React.FC<Props> = (props) => {
|
||||
params: { page: selectAll === SelectAllStatus.AllAvailable ? '1' : undefined },
|
||||
}),
|
||||
)
|
||||
clearRouteCache()
|
||||
closeModal(drawerSlug)
|
||||
}
|
||||
|
||||
return (
|
||||
@@ -176,8 +196,7 @@ export const EditMany: React.FC<Props> = (props) => {
|
||||
{t('general:edit')}
|
||||
</DrawerToggler>
|
||||
<Drawer Header={null} slug={drawerSlug}>
|
||||
{/* @ts-expect-error */}
|
||||
<DocumentInfoProvider collection={collection}>
|
||||
<DocumentInfoProvider collectionSlug={slug} id={null}>
|
||||
<OperationContext.Provider value="update">
|
||||
<div className={`${baseClass}__main`}>
|
||||
<div className={`${baseClass}__header`}>
|
||||
@@ -197,6 +216,7 @@ export const EditMany: React.FC<Props> = (props) => {
|
||||
<Form
|
||||
className={`${baseClass}__form`}
|
||||
initialState={initialState}
|
||||
onChange={[onChange]}
|
||||
onSuccess={onSuccess}
|
||||
>
|
||||
<FieldSelect fields={fields} setSelected={setSelected} />
|
||||
|
||||
@@ -533,7 +533,7 @@ const Form: React.FC<Props> = (props) => {
|
||||
})
|
||||
}
|
||||
|
||||
const { changed, newState } = mergeServerFormState(fields, revalidatedFormState)
|
||||
const { changed, newState } = mergeServerFormState(fields || {}, revalidatedFormState)
|
||||
|
||||
if (changed) {
|
||||
dispatchFields({ type: 'REPLACE_STATE', optimize: false, state: newState })
|
||||
|
||||
@@ -17,35 +17,39 @@ export const mergeServerFormState = (
|
||||
): { changed: boolean; newState: FormState } => {
|
||||
let changed = false
|
||||
|
||||
Object.entries(newState).forEach(([path, newFieldState]) => {
|
||||
newFieldState.initialValue = oldState[path]?.initialValue
|
||||
newFieldState.value = oldState[path].value
|
||||
if (oldState) {
|
||||
Object.entries(newState).forEach(([path, newFieldState]) => {
|
||||
if (!oldState[path]) return
|
||||
|
||||
const oldErrorPaths: string[] = []
|
||||
const newErrorPaths: string[] = []
|
||||
newFieldState.initialValue = oldState[path].initialValue
|
||||
newFieldState.value = oldState[path].value
|
||||
|
||||
if (oldState[path].errorPaths instanceof Set) {
|
||||
oldState[path].errorPaths.forEach((path) => oldErrorPaths.push(path))
|
||||
}
|
||||
const oldErrorPaths: string[] = []
|
||||
const newErrorPaths: string[] = []
|
||||
|
||||
if (
|
||||
newFieldState.errorPaths &&
|
||||
!Array.isArray(newFieldState.errorPaths) &&
|
||||
typeof newFieldState.errorPaths
|
||||
) {
|
||||
Object.values(newFieldState.errorPaths).forEach((path) => newErrorPaths.push(path))
|
||||
}
|
||||
if (oldState[path].errorPaths instanceof Set) {
|
||||
oldState[path].errorPaths.forEach((path) => oldErrorPaths.push(path))
|
||||
}
|
||||
|
||||
if (!arraysHaveSameStrings(oldErrorPaths, newErrorPaths)) {
|
||||
changed = true
|
||||
}
|
||||
if (
|
||||
newFieldState.errorPaths &&
|
||||
!Array.isArray(newFieldState.errorPaths) &&
|
||||
typeof newFieldState.errorPaths
|
||||
) {
|
||||
Object.values(newFieldState.errorPaths).forEach((path) => newErrorPaths.push(path))
|
||||
}
|
||||
|
||||
propsToCheck.forEach((prop) => {
|
||||
if (newFieldState[prop] != oldState[path][prop]) {
|
||||
if (!arraysHaveSameStrings(oldErrorPaths, newErrorPaths)) {
|
||||
changed = true
|
||||
}
|
||||
|
||||
propsToCheck.forEach((prop) => {
|
||||
if (newFieldState[prop] != oldState[path][prop]) {
|
||||
changed = true
|
||||
}
|
||||
})
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
return { changed, newState }
|
||||
}
|
||||
|
||||
@@ -35,7 +35,13 @@ export const SelectionProvider: React.FC<Props> = ({ children, docs = [], totalD
|
||||
const contextRef = useRef({} as SelectionContext)
|
||||
|
||||
const { code: locale } = useLocale()
|
||||
const [selected, setSelected] = useState<SelectionContext['selected']>({})
|
||||
const [selected, setSelected] = useState<SelectionContext['selected']>(() => {
|
||||
const rows = {}
|
||||
docs.forEach(({ id }) => {
|
||||
rows[id] = false
|
||||
})
|
||||
return rows
|
||||
})
|
||||
const [selectAll, setSelectAll] = useState<SelectAllStatus>(SelectAllStatus.None)
|
||||
const [count, setCount] = useState(0)
|
||||
const { searchParams } = useSearchParams()
|
||||
@@ -132,18 +138,7 @@ export const SelectionProvider: React.FC<Props> = ({ children, docs = [], totalD
|
||||
} else {
|
||||
setSelectAll(SelectAllStatus.None)
|
||||
}
|
||||
}, [docs, selectAll, selected])
|
||||
|
||||
useEffect(() => {
|
||||
const rows = {}
|
||||
if (docs.length) {
|
||||
docs.forEach(({ id }) => {
|
||||
rows[id] = false
|
||||
})
|
||||
setSelected(rows)
|
||||
}
|
||||
setSelectAll(SelectAllStatus.None)
|
||||
}, [docs])
|
||||
}, [selectAll, selected])
|
||||
|
||||
useEffect(() => {
|
||||
const newCount =
|
||||
|
||||
@@ -89,8 +89,9 @@ export async function changeLocale(page: Page, newLocale: string) {
|
||||
})
|
||||
.first()
|
||||
.click()
|
||||
const regexPattern = new RegExp(`locale=${newLocale}`)
|
||||
await expect(page).toHaveURL(regexPattern)
|
||||
await wait(500)
|
||||
expect(page.url()).toContain(`locale=${newLocale}`)
|
||||
}
|
||||
|
||||
export function exactText(text: string) {
|
||||
|
||||
@@ -38,6 +38,7 @@ import {
|
||||
exactText,
|
||||
findTableCell,
|
||||
initPageConsoleErrorCatch,
|
||||
saveDocAndAssert,
|
||||
selectTableRow,
|
||||
} from '../helpers.js'
|
||||
import { AdminUrlUtil } from '../helpers/adminUrlUtil.js'
|
||||
@@ -98,7 +99,7 @@ describe('versions', () => {
|
||||
const rows = page.locator(`tr`)
|
||||
const rowToDelete = rows.filter({ hasText: titleToDelete })
|
||||
|
||||
await rowToDelete.locator('.cell-_select input').click()
|
||||
await rowToDelete.locator('.cell-_select input').check()
|
||||
await page.locator('.delete-documents__toggle').click()
|
||||
await page.locator('#confirm-delete').click()
|
||||
|
||||
@@ -198,12 +199,14 @@ describe('versions', () => {
|
||||
test('collection - has versions tab', async () => {
|
||||
await page.goto(url.list)
|
||||
await page.locator('tbody tr .cell-title a').first().click()
|
||||
const docURL = page.url()
|
||||
const pathname = new URL(docURL).pathname
|
||||
|
||||
const versionsTab = page.locator('.doc-tab', {
|
||||
hasText: 'Versions',
|
||||
})
|
||||
await versionsTab.waitFor({ state: 'visible' })
|
||||
|
||||
const docURL = page.url()
|
||||
const pathname = new URL(docURL).pathname
|
||||
|
||||
expect(versionsTab).toBeTruthy()
|
||||
const href = await versionsTab.locator('a').first().getAttribute('href')
|
||||
@@ -225,6 +228,7 @@ describe('versions', () => {
|
||||
const versionsTab = page.locator('.doc-tab', {
|
||||
hasText: 'Versions',
|
||||
})
|
||||
await versionsTab.waitFor({ state: 'visible' })
|
||||
|
||||
const versionCount = await versionsTab.locator('.doc-tab__count').first().textContent()
|
||||
expect(versionCount).toBe('11')
|
||||
@@ -233,6 +237,9 @@ describe('versions', () => {
|
||||
test('collection - has versions route', async () => {
|
||||
await page.goto(url.list)
|
||||
await page.locator('tbody tr .cell-title a').first().click()
|
||||
|
||||
await page.waitForSelector('.doc-header__title', { state: 'visible' })
|
||||
|
||||
await page.goto(`${page.url()}/versions`)
|
||||
expect(page.url()).toMatch(/\/versions$/)
|
||||
})
|
||||
@@ -240,6 +247,13 @@ describe('versions', () => {
|
||||
test('should show collection versions view level action in collection versions view', async () => {
|
||||
await page.goto(url.list)
|
||||
await page.locator('tbody tr .cell-title a').first().click()
|
||||
|
||||
// Wait for the document to load
|
||||
const versionsTab = page.locator('.doc-tab', {
|
||||
hasText: 'Versions',
|
||||
})
|
||||
await versionsTab.waitFor({ state: 'visible' })
|
||||
|
||||
await page.goto(`${page.url()}/versions`)
|
||||
await expect(page.locator('.app-header .collection-versions-button')).toHaveCount(1)
|
||||
})
|
||||
@@ -262,6 +276,7 @@ describe('versions', () => {
|
||||
const versionsTab = page.locator('.doc-tab', {
|
||||
hasText: 'Versions',
|
||||
})
|
||||
await versionsTab.waitFor({ state: 'visible' })
|
||||
|
||||
expect(versionsTab).toBeTruthy()
|
||||
const href = await versionsTab.locator('a').first().getAttribute('href')
|
||||
@@ -275,13 +290,21 @@ describe('versions', () => {
|
||||
expect(page.url()).toMatch(/\/versions$/)
|
||||
})
|
||||
|
||||
// TODO: This test is flaky and fails sometimes
|
||||
test('global - should autosave', async () => {
|
||||
const url = new AdminUrlUtil(serverURL, autoSaveGlobalSlug)
|
||||
// fill out global title and wait for autosave
|
||||
await page.goto(url.global(autoSaveGlobalSlug))
|
||||
await page.locator('#field-title').fill('global title')
|
||||
await wait(1000)
|
||||
await wait(500)
|
||||
const titleField = page.locator('#field-title')
|
||||
await expect(titleField).toBeVisible()
|
||||
|
||||
await titleField.fill('global title')
|
||||
await wait(500)
|
||||
await expect(page.locator('.autosave:has-text("Saving...")')).toBeVisible()
|
||||
await expect(
|
||||
page.locator('.autosave:has-text("Last saved less than a minute ago")'),
|
||||
).toBeVisible()
|
||||
expect(await titleField.inputValue()).toBe('global title')
|
||||
|
||||
// refresh the page and ensure value autosaved
|
||||
await page.goto(url.global(autoSaveGlobalSlug))
|
||||
@@ -289,60 +312,77 @@ describe('versions', () => {
|
||||
})
|
||||
|
||||
test('should retain localized data during autosave', async () => {
|
||||
const locale = 'en'
|
||||
const spanishLocale = 'es'
|
||||
const en = 'en'
|
||||
const es = 'es'
|
||||
const title = 'english title'
|
||||
const spanishTitle = 'spanish title'
|
||||
const description = 'description'
|
||||
const newDescription = 'new description'
|
||||
|
||||
await page.goto(autosaveURL.create)
|
||||
await page.locator('#field-title').fill(title)
|
||||
await page.locator('#field-description').fill(description)
|
||||
await wait(500) // wait for autosave
|
||||
await expect(page.locator('.id-label')).toBeVisible()
|
||||
await wait(500)
|
||||
const titleField = page.locator('#field-title')
|
||||
const descriptionField = page.locator('#field-description')
|
||||
|
||||
await changeLocale(page, spanishLocale)
|
||||
await page.locator('#field-title').fill(spanishTitle)
|
||||
await wait(500) // wait for autosave
|
||||
// fill out en doc
|
||||
await titleField.fill(title)
|
||||
await descriptionField.fill(description)
|
||||
await wait(500)
|
||||
|
||||
await changeLocale(page, locale)
|
||||
await page.locator('#field-description').fill(newDescription)
|
||||
await wait(500) // wait for autosave
|
||||
// change locale to spanish
|
||||
await changeLocale(page, es)
|
||||
// set localized title field
|
||||
await titleField.fill(spanishTitle)
|
||||
await wait(500)
|
||||
|
||||
await changeLocale(page, spanishLocale)
|
||||
await wait(500) // wait for autosave
|
||||
// change locale back to en
|
||||
await changeLocale(page, en)
|
||||
// verify en loads its own title
|
||||
expect(await titleField.inputValue()).toEqual(title)
|
||||
// change non-localized description field
|
||||
await descriptionField.fill(newDescription)
|
||||
await wait(500)
|
||||
|
||||
// change locale to spanish
|
||||
await changeLocale(page, es)
|
||||
await wait(500)
|
||||
|
||||
// reload page in spanish
|
||||
// title should not be english title
|
||||
// description should be new description
|
||||
await page.reload()
|
||||
await expect(page.locator('#field-title')).toHaveValue(spanishTitle)
|
||||
await expect(page.locator('#field-description')).toHaveValue(newDescription)
|
||||
expect(await titleField.inputValue()).toEqual(spanishTitle)
|
||||
expect(await descriptionField.inputValue()).toEqual(newDescription)
|
||||
})
|
||||
|
||||
test('should restore localized docs correctly', async () => {
|
||||
const spanishLocale = 'es'
|
||||
const es = 'es'
|
||||
const spanishTitle = 'spanish title'
|
||||
const englishTitle = 'english title'
|
||||
|
||||
await page.goto(url.create)
|
||||
await wait(500)
|
||||
|
||||
// fill out doc in english
|
||||
await page.locator('#field-title').fill(englishTitle)
|
||||
await page.locator('#field-description').fill('unchanged description')
|
||||
await page.locator('#action-save').click()
|
||||
await saveDocAndAssert(page)
|
||||
|
||||
// change locale to spanish
|
||||
await changeLocale(page, spanishLocale)
|
||||
await changeLocale(page, es)
|
||||
|
||||
// fill out doc in spanish
|
||||
await page.locator('#field-title').fill(spanishTitle)
|
||||
await page.locator('#action-save').click()
|
||||
await saveDocAndAssert(page)
|
||||
|
||||
// fill out draft content in spanish
|
||||
await page.locator('#field-title').fill(`${spanishTitle}--draft`)
|
||||
await page.locator('#action-save-draft').click()
|
||||
await saveDocAndAssert(page, '#action-save-draft')
|
||||
|
||||
// revert to last published version
|
||||
await page.locator('#action-revert-to-published').click()
|
||||
await page.locator('#action-revert-to-published-confirm').click()
|
||||
await saveDocAndAssert(page, '#action-revert-to-published-confirm')
|
||||
|
||||
// verify that spanish content is reverted correctly
|
||||
await expect(page.locator('#field-title')).toHaveValue(spanishTitle)
|
||||
@@ -351,12 +391,14 @@ describe('versions', () => {
|
||||
test('collection - autosave should only update the current document', async () => {
|
||||
// create and save first doc
|
||||
await page.goto(autosaveURL.create)
|
||||
await wait(500)
|
||||
await page.locator('#field-title').fill('first post title')
|
||||
await page.locator('#field-description').fill('first post description')
|
||||
await page.locator('#action-save').click()
|
||||
|
||||
// create and save second doc
|
||||
await page.goto(autosaveURL.create)
|
||||
await wait(500)
|
||||
await page.locator('#field-title').fill('second post title')
|
||||
await page.locator('#field-description').fill('second post description')
|
||||
await page.locator('#action-save').click()
|
||||
@@ -364,7 +406,7 @@ describe('versions', () => {
|
||||
// update second doc and wait for autosave
|
||||
await page.locator('#field-title').fill('updated second post title')
|
||||
await page.locator('#field-description').fill('updated second post description')
|
||||
await wait(1000)
|
||||
await wait(500)
|
||||
|
||||
// verify that the first doc is unchanged
|
||||
await page.goto(autosaveURL.list)
|
||||
@@ -375,9 +417,10 @@ describe('versions', () => {
|
||||
|
||||
test('should save versions with custom IDs', async () => {
|
||||
await page.goto(customIDURL.create)
|
||||
await wait(500)
|
||||
await page.locator('#field-id').fill('custom')
|
||||
await page.locator('#field-title').fill('title')
|
||||
await page.locator('#action-save').click()
|
||||
await saveDocAndAssert(page)
|
||||
|
||||
await page.goto(customIDURL.list)
|
||||
await page.locator('tbody tr .cell-id a').click()
|
||||
|
||||
@@ -4,16 +4,6 @@ import { autoSaveGlobalSlug } from '../slugs.js'
|
||||
|
||||
const AutosaveGlobal: GlobalConfig = {
|
||||
slug: autoSaveGlobalSlug,
|
||||
label: 'Autosave Global',
|
||||
admin: {
|
||||
preview: () => 'https://payloadcms.com',
|
||||
},
|
||||
versions: {
|
||||
max: 20,
|
||||
drafts: {
|
||||
autosave: true,
|
||||
},
|
||||
},
|
||||
access: {
|
||||
read: ({ req: { user } }) => {
|
||||
if (user) {
|
||||
@@ -36,14 +26,24 @@ const AutosaveGlobal: GlobalConfig = {
|
||||
}
|
||||
},
|
||||
},
|
||||
admin: {
|
||||
preview: () => 'https://payloadcms.com',
|
||||
},
|
||||
fields: [
|
||||
{
|
||||
name: 'title',
|
||||
type: 'text',
|
||||
required: true,
|
||||
localized: true,
|
||||
required: true,
|
||||
},
|
||||
],
|
||||
label: 'Autosave Global',
|
||||
versions: {
|
||||
drafts: {
|
||||
autosave: true,
|
||||
},
|
||||
max: 20,
|
||||
},
|
||||
}
|
||||
|
||||
export default AutosaveGlobal
|
||||
|
||||
@@ -165,4 +165,4 @@
|
||||
"app/**/*.tsx",
|
||||
"scripts/**/*.ts"
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user