@payloadcms/next 3.0.0-alpha.5 → 3.0.0-alpha.51
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/config.js +2 -12
- package/dist/config.js.map +1 -0
- package/dist/elements/LeaveWithoutSaving/index.js +25 -76
- package/dist/elements/LeaveWithoutSaving/index.js.map +1 -0
- package/dist/elements/LeaveWithoutSaving/usePreventLeave.js +11 -29
- package/dist/elements/LeaveWithoutSaving/usePreventLeave.js.map +1 -0
- package/dist/exports/layouts.d.ts +2 -0
- package/dist/exports/layouts.d.ts.map +1 -0
- package/dist/exports/layouts.js +3 -0
- package/dist/exports/layouts.js.map +1 -0
- package/dist/exports/routes.d.ts +3 -0
- package/dist/exports/routes.d.ts.map +1 -0
- package/dist/exports/routes.js +4 -0
- package/dist/exports/routes.js.map +1 -0
- package/dist/exports/utilities.d.ts +2 -0
- package/dist/exports/utilities.d.ts.map +1 -0
- package/dist/exports/utilities.js +3 -0
- package/dist/exports/utilities.js.map +1 -0
- package/dist/exports/views.d.ts +4 -0
- package/dist/exports/views.d.ts.map +1 -0
- package/dist/exports/views.js +5 -0
- package/dist/exports/views.js.map +1 -0
- package/dist/index.js +2 -3
- package/dist/index.js.map +1 -0
- package/dist/layouts/Root/index.d.ts.map +1 -1
- package/dist/layouts/Root/index.js +39 -55
- package/dist/layouts/Root/index.js.map +1 -0
- package/dist/next-fileupload/fileFactory.d.ts +2 -2
- package/dist/next-fileupload/fileFactory.d.ts.map +1 -1
- package/dist/next-fileupload/fileFactory.js +9 -19
- package/dist/next-fileupload/fileFactory.js.map +1 -0
- package/dist/next-fileupload/handlers.d.ts +2 -2
- package/dist/next-fileupload/handlers.d.ts.map +1 -1
- package/dist/next-fileupload/handlers.js +25 -89
- package/dist/next-fileupload/handlers.js.map +1 -0
- package/dist/next-fileupload/index.d.ts +1 -1
- package/dist/next-fileupload/index.js +10 -25
- package/dist/next-fileupload/index.js.map +1 -0
- package/dist/next-fileupload/isEligibleRequest.js +2 -12
- package/dist/next-fileupload/isEligibleRequest.js.map +1 -0
- package/dist/next-fileupload/processMultipart.d.ts +1 -1
- package/dist/next-fileupload/processMultipart.d.ts.map +1 -1
- package/dist/next-fileupload/processMultipart.js +33 -46
- package/dist/next-fileupload/processMultipart.js.map +1 -0
- package/dist/next-fileupload/processNested.js +4 -14
- package/dist/next-fileupload/processNested.js.map +1 -0
- package/dist/next-fileupload/uploadTimer.js +2 -12
- package/dist/next-fileupload/uploadTimer.js.map +1 -0
- package/dist/next-fileupload/utilities.d.ts +1 -1
- package/dist/next-fileupload/utilities.d.ts.map +1 -1
- package/dist/next-fileupload/utilities.js +31 -76
- package/dist/next-fileupload/utilities.js.map +1 -0
- package/dist/next-stream-file/index.d.ts +4 -0
- package/dist/next-stream-file/index.d.ts.map +1 -1
- package/dist/next-stream-file/index.js +6 -21
- package/dist/next-stream-file/index.js.map +1 -0
- package/dist/prod/payload/SuisseIntl-Bold.woff +0 -0
- package/dist/prod/payload/SuisseIntl-Bold.woff2 +0 -0
- package/dist/prod/payload/SuisseIntl-Medium.woff +0 -0
- package/dist/prod/payload/SuisseIntl-Medium.woff2 +0 -0
- package/dist/prod/payload/SuisseIntl-SemiBold.woff +0 -0
- package/dist/prod/payload/SuisseIntl-SemiBold.woff2 +0 -0
- package/dist/prod/payload/SuisseIntl.woff +0 -0
- package/dist/prod/payload/SuisseIntl.woff2 +0 -0
- package/dist/prod/payload/favicon.svg +15 -0
- package/dist/prod/payload/merriweather-v30-latin-900.woff +0 -0
- package/dist/prod/payload/merriweather-v30-latin-900.woff2 +0 -0
- package/dist/prod/payload/merriweather-v30-latin-900italic.woff +0 -0
- package/dist/prod/payload/merriweather-v30-latin-900italic.woff2 +0 -0
- package/dist/prod/payload/merriweather-v30-latin-italic.woff +0 -0
- package/dist/prod/payload/merriweather-v30-latin-italic.woff2 +0 -0
- package/dist/prod/payload/merriweather-v30-latin-regular.woff +0 -0
- package/dist/prod/payload/merriweather-v30-latin-regular.woff2 +0 -0
- package/dist/prod/payload/og-image.png +0 -0
- package/dist/prod/styles.css +1 -0
- package/dist/routes/graphql/handler.d.ts.map +1 -1
- package/dist/routes/graphql/handler.js +19 -36
- package/dist/routes/graphql/handler.js.map +1 -0
- package/dist/routes/graphql/index.d.ts +2 -2
- package/dist/routes/graphql/index.d.ts.map +1 -1
- package/dist/routes/graphql/index.js +3 -21
- package/dist/routes/graphql/index.js.map +1 -0
- package/dist/routes/graphql/playground.js +6 -16
- package/dist/routes/graphql/playground.js.map +1 -0
- package/dist/routes/index.d.ts +2 -3
- package/dist/routes/index.d.ts.map +1 -1
- package/dist/routes/index.js +3 -37
- package/dist/routes/index.js.map +1 -0
- package/dist/routes/rest/auth/access.d.ts +1 -1
- package/dist/routes/rest/auth/access.d.ts.map +1 -1
- package/dist/routes/rest/auth/access.js +6 -21
- package/dist/routes/rest/auth/access.js.map +1 -0
- package/dist/routes/rest/auth/forgotPassword.d.ts +1 -1
- package/dist/routes/rest/auth/forgotPassword.d.ts.map +1 -1
- package/dist/routes/rest/auth/forgotPassword.js +6 -21
- package/dist/routes/rest/auth/forgotPassword.js.map +1 -0
- package/dist/routes/rest/auth/init.d.ts +1 -1
- package/dist/routes/rest/auth/init.d.ts.map +1 -1
- package/dist/routes/rest/auth/init.js +4 -14
- package/dist/routes/rest/auth/init.js.map +1 -0
- package/dist/routes/rest/auth/login.d.ts +1 -1
- package/dist/routes/rest/auth/login.d.ts.map +1 -1
- package/dist/routes/rest/auth/login.js +10 -25
- package/dist/routes/rest/auth/login.js.map +1 -0
- package/dist/routes/rest/auth/logout.d.ts +1 -1
- package/dist/routes/rest/auth/logout.d.ts.map +1 -1
- package/dist/routes/rest/auth/logout.js +9 -24
- package/dist/routes/rest/auth/logout.js.map +1 -0
- package/dist/routes/rest/auth/me.d.ts +1 -1
- package/dist/routes/rest/auth/me.d.ts.map +1 -1
- package/dist/routes/rest/auth/me.js +8 -23
- package/dist/routes/rest/auth/me.js.map +1 -0
- package/dist/routes/rest/auth/refresh.d.ts +1 -1
- package/dist/routes/rest/auth/refresh.d.ts.map +1 -1
- package/dist/routes/rest/auth/refresh.js +11 -25
- package/dist/routes/rest/auth/refresh.js.map +1 -0
- package/dist/routes/rest/auth/registerFirstUser.d.ts +1 -1
- package/dist/routes/rest/auth/registerFirstUser.d.ts.map +1 -1
- package/dist/routes/rest/auth/registerFirstUser.js +12 -25
- package/dist/routes/rest/auth/registerFirstUser.js.map +1 -0
- package/dist/routes/rest/auth/resetPassword.d.ts +1 -1
- package/dist/routes/rest/auth/resetPassword.d.ts.map +1 -1
- package/dist/routes/rest/auth/resetPassword.js +8 -23
- package/dist/routes/rest/auth/resetPassword.js.map +1 -0
- package/dist/routes/rest/auth/unlock.d.ts +1 -1
- package/dist/routes/rest/auth/unlock.d.ts.map +1 -1
- package/dist/routes/rest/auth/unlock.js +6 -21
- package/dist/routes/rest/auth/unlock.js.map +1 -0
- package/dist/routes/rest/auth/verifyEmail.d.ts +1 -1
- package/dist/routes/rest/auth/verifyEmail.d.ts.map +1 -1
- package/dist/routes/rest/auth/verifyEmail.js +6 -21
- package/dist/routes/rest/auth/verifyEmail.js.map +1 -0
- package/dist/routes/rest/buildFormState.d.ts +1 -1
- package/dist/routes/rest/buildFormState.d.ts.map +1 -1
- package/dist/routes/rest/buildFormState.js +141 -79
- package/dist/routes/rest/buildFormState.js.map +1 -0
- package/dist/routes/rest/checkEndpoints.d.ts.map +1 -1
- package/dist/routes/rest/checkEndpoints.js +4 -19
- package/dist/routes/rest/checkEndpoints.js.map +1 -0
- package/dist/routes/rest/collections/create.d.ts +1 -1
- package/dist/routes/rest/collections/create.d.ts.map +1 -1
- package/dist/routes/rest/collections/create.js +10 -24
- package/dist/routes/rest/collections/create.js.map +1 -0
- package/dist/routes/rest/collections/delete.d.ts +1 -1
- package/dist/routes/rest/collections/delete.d.ts.map +1 -1
- package/dist/routes/rest/collections/delete.js +13 -31
- package/dist/routes/rest/collections/delete.js.map +1 -0
- package/dist/routes/rest/collections/deleteByID.d.ts +1 -1
- package/dist/routes/rest/collections/deleteByID.d.ts.map +1 -1
- package/dist/routes/rest/collections/deleteByID.js +9 -24
- package/dist/routes/rest/collections/deleteByID.js.map +1 -0
- package/dist/routes/rest/collections/docAccess.d.ts +1 -1
- package/dist/routes/rest/collections/docAccess.d.ts.map +1 -1
- package/dist/routes/rest/collections/docAccess.js +6 -21
- package/dist/routes/rest/collections/docAccess.js.map +1 -0
- package/dist/routes/rest/collections/duplicate.d.ts +3 -0
- package/dist/routes/rest/collections/duplicate.d.ts.map +1 -0
- package/dist/routes/rest/collections/duplicate.js +28 -0
- package/dist/routes/rest/collections/duplicate.js.map +1 -0
- package/dist/routes/rest/collections/find.d.ts +1 -1
- package/dist/routes/rest/collections/find.d.ts.map +1 -1
- package/dist/routes/rest/collections/find.js +11 -29
- package/dist/routes/rest/collections/find.js.map +1 -0
- package/dist/routes/rest/collections/findByID.d.ts +1 -1
- package/dist/routes/rest/collections/findByID.d.ts.map +1 -1
- package/dist/routes/rest/collections/findByID.js +8 -23
- package/dist/routes/rest/collections/findByID.js.map +1 -0
- package/dist/routes/rest/collections/findVersionByID.d.ts +1 -1
- package/dist/routes/rest/collections/findVersionByID.d.ts.map +1 -1
- package/dist/routes/rest/collections/findVersionByID.js +8 -23
- package/dist/routes/rest/collections/findVersionByID.js.map +1 -0
- package/dist/routes/rest/collections/findVersions.d.ts +1 -1
- package/dist/routes/rest/collections/findVersions.d.ts.map +1 -1
- package/dist/routes/rest/collections/findVersions.js +11 -29
- package/dist/routes/rest/collections/findVersions.js.map +1 -0
- package/dist/routes/rest/collections/preview.d.ts +3 -0
- package/dist/routes/rest/collections/preview.d.ts.map +1 -0
- package/dist/routes/rest/collections/preview.js +36 -0
- package/dist/routes/rest/collections/preview.js.map +1 -0
- package/dist/routes/rest/collections/restoreVersion.d.ts +1 -1
- package/dist/routes/rest/collections/restoreVersion.d.ts.map +1 -1
- package/dist/routes/rest/collections/restoreVersion.js +8 -23
- package/dist/routes/rest/collections/restoreVersion.js.map +1 -0
- package/dist/routes/rest/collections/update.d.ts +1 -1
- package/dist/routes/rest/collections/update.d.ts.map +1 -1
- package/dist/routes/rest/collections/update.js +13 -31
- package/dist/routes/rest/collections/update.js.map +1 -0
- package/dist/routes/rest/collections/updateByID.d.ts +1 -1
- package/dist/routes/rest/collections/updateByID.d.ts.map +1 -1
- package/dist/routes/rest/collections/updateByID.js +8 -23
- package/dist/routes/rest/collections/updateByID.js.map +1 -0
- package/dist/routes/rest/files/checkFileAccess.d.ts +7 -0
- package/dist/routes/rest/files/checkFileAccess.d.ts.map +1 -0
- package/dist/routes/rest/files/checkFileAccess.js +50 -0
- package/dist/routes/rest/files/checkFileAccess.js.map +1 -0
- package/dist/routes/rest/files/getFile.d.ts +9 -0
- package/dist/routes/rest/files/getFile.d.ts.map +1 -0
- package/dist/routes/rest/files/getFile.js +52 -0
- package/dist/routes/rest/files/getFile.js.map +1 -0
- package/dist/routes/rest/globals/docAccess.d.ts +1 -1
- package/dist/routes/rest/globals/docAccess.d.ts.map +1 -1
- package/dist/routes/rest/globals/docAccess.js +6 -21
- package/dist/routes/rest/globals/docAccess.js.map +1 -0
- package/dist/routes/rest/globals/findOne.d.ts +1 -1
- package/dist/routes/rest/globals/findOne.d.ts.map +1 -1
- package/dist/routes/rest/globals/findOne.js +10 -25
- package/dist/routes/rest/globals/findOne.js.map +1 -0
- package/dist/routes/rest/globals/findVersionByID.d.ts +1 -1
- package/dist/routes/rest/globals/findVersionByID.d.ts.map +1 -1
- package/dist/routes/rest/globals/findVersionByID.js +8 -23
- package/dist/routes/rest/globals/findVersionByID.js.map +1 -0
- package/dist/routes/rest/globals/findVersions.d.ts +1 -1
- package/dist/routes/rest/globals/findVersions.d.ts.map +1 -1
- package/dist/routes/rest/globals/findVersions.js +11 -29
- package/dist/routes/rest/globals/findVersions.js.map +1 -0
- package/dist/routes/rest/globals/preview.d.ts +3 -0
- package/dist/routes/rest/globals/preview.d.ts.map +1 -0
- package/dist/routes/rest/globals/preview.js +35 -0
- package/dist/routes/rest/globals/preview.js.map +1 -0
- package/dist/routes/rest/globals/restoreVersion.d.ts +1 -1
- package/dist/routes/rest/globals/restoreVersion.d.ts.map +1 -1
- package/dist/routes/rest/globals/restoreVersion.js +8 -23
- package/dist/routes/rest/globals/restoreVersion.js.map +1 -0
- package/dist/routes/rest/globals/update.d.ts +1 -1
- package/dist/routes/rest/globals/update.d.ts.map +1 -1
- package/dist/routes/rest/globals/update.js +10 -25
- package/dist/routes/rest/globals/update.js.map +1 -0
- package/dist/routes/rest/index.d.ts.map +1 -1
- package/dist/routes/rest/index.js +129 -122
- package/dist/routes/rest/index.js.map +1 -0
- package/dist/routes/rest/routeError.d.ts +13 -0
- package/dist/routes/rest/routeError.d.ts.map +1 -0
- package/dist/routes/rest/routeError.js +93 -0
- package/dist/routes/rest/routeError.js.map +1 -0
- package/dist/routes/rest/types.js +2 -5
- package/dist/routes/rest/types.js.map +1 -0
- package/dist/scss/app.scss +2 -2
- package/dist/utilities/auth.d.ts +6 -4
- package/dist/utilities/auth.d.ts.map +1 -1
- package/dist/utilities/auth.js +7 -22
- package/dist/utilities/auth.js.map +1 -0
- package/dist/utilities/buildFieldSchemaMap/index.d.ts +4 -0
- package/dist/utilities/buildFieldSchemaMap/index.d.ts.map +1 -0
- package/dist/utilities/buildFieldSchemaMap/index.js +26 -0
- package/dist/utilities/buildFieldSchemaMap/index.js.map +1 -0
- package/dist/utilities/buildFieldSchemaMap/traverseFields.d.ts +12 -0
- package/dist/utilities/buildFieldSchemaMap/traverseFields.d.ts.map +1 -0
- package/dist/utilities/buildFieldSchemaMap/traverseFields.js +67 -0
- package/dist/utilities/buildFieldSchemaMap/traverseFields.js.map +1 -0
- package/dist/utilities/buildFieldSchemaMap/types.d.ts +3 -0
- package/dist/utilities/buildFieldSchemaMap/types.d.ts.map +1 -0
- package/dist/utilities/buildFieldSchemaMap/types.js +3 -0
- package/dist/utilities/buildFieldSchemaMap/types.js.map +1 -0
- package/dist/utilities/createPayloadRequest.d.ts.map +1 -1
- package/dist/utilities/createPayloadRequest.js +30 -31
- package/dist/utilities/createPayloadRequest.js.map +1 -0
- package/dist/utilities/getDataAndFile.js +6 -16
- package/dist/utilities/getDataAndFile.js.map +1 -0
- package/dist/utilities/getNextI18n.d.ts +1 -1
- package/dist/utilities/getNextI18n.d.ts.map +1 -1
- package/dist/utilities/getNextI18n.js +11 -23
- package/dist/utilities/getNextI18n.js.map +1 -0
- package/dist/utilities/getPayloadHMR.d.ts +4 -0
- package/dist/utilities/getPayloadHMR.d.ts.map +1 -0
- package/dist/utilities/getPayloadHMR.js +75 -0
- package/dist/utilities/getPayloadHMR.js.map +1 -0
- package/dist/utilities/getRequestLanguage.d.ts +4 -2
- package/dist/utilities/getRequestLanguage.d.ts.map +1 -1
- package/dist/utilities/getRequestLanguage.js +6 -16
- package/dist/utilities/getRequestLanguage.js.map +1 -0
- package/dist/utilities/getRequestLocales.js +2 -12
- package/dist/utilities/getRequestLocales.js.map +1 -0
- package/dist/utilities/initPage.d.ts +8 -17
- package/dist/utilities/initPage.d.ts.map +1 -1
- package/dist/utilities/initPage.js +66 -46
- package/dist/utilities/initPage.js.map +1 -0
- package/dist/utilities/meta.js +5 -15
- package/dist/utilities/meta.js.map +1 -0
- package/dist/utilities/timestamp.d.ts +2 -0
- package/dist/utilities/timestamp.d.ts.map +1 -0
- package/dist/utilities/timestamp.js +7 -0
- package/dist/utilities/timestamp.js.map +1 -0
- package/dist/views/API/RenderJSON/index.d.ts.map +1 -0
- package/dist/views/API/RenderJSON/index.js +90 -0
- package/dist/views/API/RenderJSON/index.js.map +1 -0
- package/dist/views/API/index.client.d.ts +4 -0
- package/dist/views/API/index.client.d.ts.map +1 -0
- package/dist/views/API/index.client.js +187 -0
- package/dist/views/API/index.client.js.map +1 -0
- package/dist/views/API/index.d.ts +3 -0
- package/dist/views/API/index.d.ts.map +1 -0
- package/dist/views/API/index.js +7 -0
- package/dist/views/API/index.js.map +1 -0
- package/dist/views/API/meta.d.ts +3 -0
- package/dist/views/API/meta.d.ts.map +1 -0
- package/dist/views/API/meta.js +11 -0
- package/dist/views/API/meta.js.map +1 -0
- package/dist/views/Account/Settings/index.d.ts.map +1 -0
- package/dist/views/Account/Settings/index.js +31 -0
- package/dist/views/Account/Settings/index.js.map +1 -0
- package/dist/views/Account/ToggleTheme/index.d.ts.map +1 -0
- package/dist/views/Account/ToggleTheme/index.js +36 -0
- package/dist/views/Account/ToggleTheme/index.js.map +1 -0
- package/dist/views/Account/index.d.ts +5 -0
- package/dist/views/Account/index.d.ts.map +1 -0
- package/dist/views/Account/index.js +56 -0
- package/dist/views/Account/index.js.map +1 -0
- package/dist/views/Account/meta.d.ts +3 -0
- package/dist/views/Account/meta.d.ts.map +1 -0
- package/dist/views/Account/meta.js +11 -0
- package/dist/views/Account/meta.js.map +1 -0
- package/dist/views/CreateFirstUser/index.client.d.ts +7 -0
- package/dist/views/CreateFirstUser/index.client.d.ts.map +1 -0
- package/dist/views/CreateFirstUser/index.client.js +22 -0
- package/dist/views/CreateFirstUser/index.client.js.map +1 -0
- package/dist/views/CreateFirstUser/index.d.ts +6 -0
- package/dist/views/CreateFirstUser/index.d.ts.map +1 -0
- package/dist/views/CreateFirstUser/index.js +53 -0
- package/dist/views/CreateFirstUser/index.js.map +1 -0
- package/dist/views/CreateFirstUser/meta.d.ts +3 -0
- package/dist/views/CreateFirstUser/meta.d.ts.map +1 -0
- package/dist/views/CreateFirstUser/meta.js +11 -0
- package/dist/views/CreateFirstUser/meta.js.map +1 -0
- package/dist/views/Dashboard/Default/index.client.d.ts +10 -0
- package/dist/views/Dashboard/Default/index.client.d.ts.map +1 -0
- package/dist/views/Dashboard/Default/index.client.js +103 -0
- package/dist/views/Dashboard/Default/index.client.js.map +1 -0
- package/dist/views/Dashboard/Default/index.d.ts +12 -0
- package/dist/views/Dashboard/Default/index.d.ts.map +1 -0
- package/dist/views/Dashboard/Default/index.js +28 -0
- package/dist/views/Dashboard/Default/index.js.map +1 -0
- package/dist/views/Dashboard/index.d.ts +5 -0
- package/dist/views/Dashboard/index.d.ts.map +1 -0
- package/dist/views/Dashboard/index.js +27 -0
- package/dist/views/Dashboard/index.js.map +1 -0
- package/dist/views/Dashboard/meta.d.ts +3 -0
- package/dist/views/Dashboard/meta.d.ts.map +1 -0
- package/dist/views/Dashboard/meta.js +11 -0
- package/dist/views/Dashboard/meta.js.map +1 -0
- package/dist/views/Document/getCustomViewByKey.d.ts +4 -0
- package/dist/views/Document/getCustomViewByKey.d.ts.map +1 -0
- package/dist/views/Document/getCustomViewByKey.js +5 -0
- package/dist/views/Document/getCustomViewByKey.js.map +1 -0
- package/dist/views/Document/getCustomViewByRoute.d.ts +8 -0
- package/dist/views/Document/getCustomViewByRoute.d.ts.map +1 -0
- package/dist/views/Document/getCustomViewByRoute.js +22 -0
- package/dist/views/Document/getCustomViewByRoute.js.map +1 -0
- package/dist/views/Document/getMetaBySegment.d.ts +10 -0
- package/dist/views/Document/getMetaBySegment.d.ts.map +1 -0
- package/dist/views/Document/getMetaBySegment.js +77 -0
- package/dist/views/Document/getMetaBySegment.js.map +1 -0
- package/dist/views/Document/getViewsFromConfig.d.ts +18 -0
- package/dist/views/Document/getViewsFromConfig.d.ts.map +1 -0
- package/dist/views/Document/getViewsFromConfig.js +241 -0
- package/dist/views/Document/getViewsFromConfig.js.map +1 -0
- package/dist/views/Document/index.d.ts +6 -0
- package/dist/views/Document/index.d.ts.map +1 -0
- package/dist/views/Document/index.js +162 -0
- package/dist/views/Document/index.js.map +1 -0
- package/dist/views/Document/meta.d.ts +3 -0
- package/dist/views/Document/meta.d.ts.map +1 -0
- package/dist/views/Document/meta.js +4 -0
- package/dist/views/Document/meta.js.map +1 -0
- package/dist/views/Edit/Default/Auth/APIKey.d.ts +5 -0
- package/dist/views/Edit/Default/Auth/APIKey.d.ts.map +1 -0
- package/dist/views/Edit/Default/Auth/APIKey.js +99 -0
- package/dist/views/Edit/Default/Auth/APIKey.js.map +1 -0
- package/dist/views/Edit/Default/Auth/index.d.ts +5 -0
- package/dist/views/Edit/Default/Auth/index.d.ts.map +1 -0
- package/dist/views/Edit/Default/Auth/index.js +129 -0
- package/dist/views/Edit/Default/Auth/index.js.map +1 -0
- package/dist/views/Edit/Default/Auth/types.d.ts.map +1 -0
- package/dist/views/Edit/Default/Auth/types.js +3 -0
- package/dist/views/Edit/Default/Auth/types.js.map +1 -0
- package/dist/views/Edit/Default/SetDocumentTitle/index.d.ts +9 -0
- package/dist/views/Edit/Default/SetDocumentTitle/index.d.ts.map +1 -0
- package/dist/views/Edit/Default/SetDocumentTitle/index.js +38 -0
- package/dist/views/Edit/Default/SetDocumentTitle/index.js.map +1 -0
- package/dist/views/Edit/Default/SetStepNav/index.d.ts +12 -0
- package/dist/views/Edit/Default/SetStepNav/index.d.ts.map +1 -0
- package/dist/views/Edit/Default/SetStepNav/index.js +64 -0
- package/dist/views/Edit/Default/SetStepNav/index.js.map +1 -0
- package/dist/views/Edit/Default/index.d.ts.map +1 -0
- package/dist/views/Edit/Default/index.js +194 -0
- package/dist/views/Edit/Default/index.js.map +1 -0
- package/dist/views/Edit/Default/types.d.ts.map +1 -0
- package/dist/views/Edit/Default/types.js +3 -0
- package/dist/views/Edit/Default/types.js.map +1 -0
- package/dist/views/Edit/index.client.d.ts +3 -0
- package/dist/views/Edit/index.client.d.ts.map +1 -0
- package/dist/views/Edit/index.client.js +23 -0
- package/dist/views/Edit/index.client.js.map +1 -0
- package/dist/views/Edit/index.d.ts +3 -0
- package/dist/views/Edit/index.d.ts.map +1 -0
- package/dist/views/Edit/index.js +7 -0
- package/dist/views/Edit/index.js.map +1 -0
- package/dist/views/Edit/meta.d.ts +3 -0
- package/dist/views/Edit/meta.d.ts.map +1 -0
- package/dist/views/Edit/meta.js +26 -0
- package/dist/views/Edit/meta.js.map +1 -0
- package/dist/views/Edit/sanitizeEditViewProps.d.ts +3 -0
- package/dist/views/Edit/sanitizeEditViewProps.d.ts.map +1 -0
- package/dist/views/Edit/sanitizeEditViewProps.js +11 -0
- package/dist/views/Edit/sanitizeEditViewProps.js.map +1 -0
- package/dist/views/ForgotPassword/index.d.ts +6 -0
- package/dist/views/ForgotPassword/index.d.ts.map +1 -0
- package/dist/views/ForgotPassword/index.js +69 -0
- package/dist/views/ForgotPassword/index.js.map +1 -0
- package/dist/views/ForgotPassword/meta.d.ts +3 -0
- package/dist/views/ForgotPassword/meta.d.ts.map +1 -0
- package/dist/views/ForgotPassword/meta.js +11 -0
- package/dist/views/ForgotPassword/meta.js.map +1 -0
- package/dist/views/List/Default/index.d.ts.map +1 -0
- package/dist/views/List/Default/index.js +149 -0
- package/dist/views/List/Default/index.js.map +1 -0
- package/dist/views/List/Default/types.d.ts +15 -0
- package/dist/views/List/Default/types.d.ts.map +1 -0
- package/dist/views/List/Default/types.js +3 -0
- package/dist/views/List/Default/types.js.map +1 -0
- package/dist/views/List/index.d.ts +5 -0
- package/dist/views/List/index.d.ts.map +1 -0
- package/dist/views/List/index.js +104 -0
- package/dist/views/List/index.js.map +1 -0
- package/dist/views/List/meta.d.ts +7 -0
- package/dist/views/List/meta.d.ts.map +1 -0
- package/dist/views/List/meta.js +19 -0
- package/dist/views/List/meta.js.map +1 -0
- package/dist/views/LivePreview/Context/collisionDetection.d.ts.map +1 -0
- package/dist/views/LivePreview/Context/collisionDetection.js +26 -0
- package/dist/views/LivePreview/Context/collisionDetection.js.map +1 -0
- package/dist/views/LivePreview/Context/context.d.ts +50 -0
- package/dist/views/LivePreview/Context/context.d.ts.map +1 -0
- package/dist/views/LivePreview/Context/context.js +40 -0
- package/dist/views/LivePreview/Context/context.js.map +1 -0
- package/dist/views/LivePreview/Context/index.d.ts +20 -0
- package/dist/views/LivePreview/Context/index.d.ts.map +1 -0
- package/dist/views/LivePreview/Context/index.js +153 -0
- package/dist/views/LivePreview/Context/index.js.map +1 -0
- package/dist/views/LivePreview/Context/sizeReducer.d.ts.map +1 -0
- package/dist/views/LivePreview/Context/sizeReducer.js +31 -0
- package/dist/views/LivePreview/Context/sizeReducer.js.map +1 -0
- package/dist/views/LivePreview/Device/index.d.ts.map +1 -0
- package/dist/views/LivePreview/Device/index.js +51 -0
- package/dist/views/LivePreview/Device/index.js.map +1 -0
- package/dist/views/LivePreview/DeviceContainer/index.d.ts.map +1 -0
- package/dist/views/LivePreview/DeviceContainer/index.js +29 -0
- package/dist/views/LivePreview/DeviceContainer/index.js.map +1 -0
- package/dist/views/LivePreview/IFrame/index.d.ts.map +1 -0
- package/dist/views/LivePreview/IFrame/index.js +22 -0
- package/dist/views/LivePreview/IFrame/index.js.map +1 -0
- package/dist/views/LivePreview/Preview/index.d.ts +5 -0
- package/dist/views/LivePreview/Preview/index.d.ts.map +1 -0
- package/dist/views/LivePreview/Preview/index.js +78 -0
- package/dist/views/LivePreview/Preview/index.js.map +1 -0
- package/dist/views/LivePreview/Toolbar/Controls/index.d.ts +5 -0
- package/dist/views/LivePreview/Toolbar/Controls/index.d.ts.map +1 -0
- package/dist/views/LivePreview/Toolbar/Controls/index.js +83 -0
- package/dist/views/LivePreview/Toolbar/Controls/index.js.map +1 -0
- package/dist/views/LivePreview/Toolbar/SizeInput/index.d.ts.map +1 -0
- package/dist/views/LivePreview/Toolbar/SizeInput/index.js +60 -0
- package/dist/views/LivePreview/Toolbar/SizeInput/index.js.map +1 -0
- package/dist/views/LivePreview/Toolbar/index.d.ts +7 -0
- package/dist/views/LivePreview/Toolbar/index.d.ts.map +1 -0
- package/dist/views/LivePreview/Toolbar/index.js +49 -0
- package/dist/views/LivePreview/Toolbar/index.js.map +1 -0
- package/dist/views/LivePreview/ToolbarArea/index.d.ts.map +1 -0
- package/dist/views/LivePreview/ToolbarArea/index.js +16 -0
- package/dist/views/LivePreview/ToolbarArea/index.js.map +1 -0
- package/dist/views/LivePreview/index.client.d.ts +10 -0
- package/dist/views/LivePreview/index.client.d.ts.map +1 -0
- package/dist/views/LivePreview/index.client.js +170 -0
- package/dist/views/LivePreview/index.client.js.map +1 -0
- package/dist/views/LivePreview/index.d.ts +4 -0
- package/dist/views/LivePreview/index.d.ts.map +1 -0
- package/dist/views/LivePreview/index.js +43 -0
- package/dist/views/LivePreview/index.js.map +1 -0
- package/dist/views/LivePreview/meta.d.ts +3 -0
- package/dist/views/LivePreview/meta.d.ts.map +1 -0
- package/dist/views/LivePreview/meta.js +26 -0
- package/dist/views/LivePreview/meta.js.map +1 -0
- package/dist/views/LivePreview/usePopupWindow.d.ts.map +1 -0
- package/dist/views/LivePreview/usePopupWindow.js +102 -0
- package/dist/views/LivePreview/usePopupWindow.js.map +1 -0
- package/dist/views/Login/LoginForm/index.d.ts.map +1 -0
- package/dist/views/Login/LoginForm/index.js +58 -0
- package/dist/views/Login/LoginForm/index.js.map +1 -0
- package/dist/views/Login/index.d.ts +7 -0
- package/dist/views/Login/index.d.ts.map +1 -0
- package/dist/views/Login/index.js +28 -0
- package/dist/views/Login/index.js.map +1 -0
- package/dist/views/Login/index.scss +8 -0
- package/dist/views/Login/meta.d.ts +3 -0
- package/dist/views/Login/meta.d.ts.map +1 -0
- package/dist/views/Login/meta.js +11 -0
- package/dist/views/Login/meta.js.map +1 -0
- package/dist/views/Logout/LogoutClient.d.ts.map +1 -0
- package/dist/views/Logout/LogoutClient.js +34 -0
- package/dist/views/Logout/LogoutClient.js.map +1 -0
- package/dist/views/Logout/index.d.ts +9 -0
- package/dist/views/Logout/index.d.ts.map +1 -0
- package/dist/views/Logout/index.js +25 -0
- package/dist/views/Logout/index.js.map +1 -0
- package/dist/views/Logout/meta.d.ts +3 -0
- package/dist/views/Logout/meta.d.ts.map +1 -0
- package/dist/views/Logout/meta.js +11 -0
- package/dist/views/Logout/meta.js.map +1 -0
- package/dist/views/NotFound/index.client.d.ts +6 -0
- package/dist/views/NotFound/index.client.d.ts.map +1 -0
- package/dist/views/NotFound/index.client.js +41 -0
- package/dist/views/NotFound/index.client.js.map +1 -0
- package/dist/views/NotFound/index.d.ts +28 -0
- package/dist/views/NotFound/index.d.ts.map +1 -0
- package/dist/views/NotFound/index.js +27 -0
- package/dist/views/NotFound/index.js.map +1 -0
- package/dist/views/NotFound/index.scss +37 -0
- package/dist/views/NotFound/meta.d.ts +8 -0
- package/dist/views/NotFound/meta.d.ts.map +1 -0
- package/dist/views/NotFound/meta.js +11 -0
- package/dist/views/NotFound/meta.js.map +1 -0
- package/dist/views/ResetPassword/index.d.ts +7 -0
- package/dist/views/ResetPassword/index.d.ts.map +1 -0
- package/dist/views/ResetPassword/index.js +69 -0
- package/dist/views/ResetPassword/index.js.map +1 -0
- package/dist/views/ResetPassword/meta.d.ts +3 -0
- package/dist/views/ResetPassword/meta.d.ts.map +1 -0
- package/dist/views/ResetPassword/meta.js +11 -0
- package/dist/views/ResetPassword/meta.js.map +1 -0
- package/dist/views/Root/getCustomViewByRoute.d.ts +6 -0
- package/dist/views/Root/getCustomViewByRoute.d.ts.map +1 -0
- package/dist/views/Root/getCustomViewByRoute.js +19 -0
- package/dist/views/Root/getCustomViewByRoute.js.map +1 -0
- package/dist/views/Root/getViewFromConfig.d.ts +18 -0
- package/dist/views/Root/getViewFromConfig.d.ts.map +1 -0
- package/dist/views/Root/getViewFromConfig.js +138 -0
- package/dist/views/Root/getViewFromConfig.js.map +1 -0
- package/dist/views/Root/index.d.ts +22 -0
- package/dist/views/Root/index.d.ts.map +1 -0
- package/dist/views/Root/index.js +51 -0
- package/dist/views/Root/index.js.map +1 -0
- package/dist/views/Root/isPathMatchingRoute.d.ts +8 -0
- package/dist/views/Root/isPathMatchingRoute.d.ts.map +1 -0
- package/dist/views/Root/isPathMatchingRoute.js +16 -0
- package/dist/views/Root/isPathMatchingRoute.js.map +1 -0
- package/dist/views/Root/meta.d.ts +14 -0
- package/dist/views/Root/meta.d.ts.map +1 -0
- package/dist/views/Root/meta.js +159 -0
- package/dist/views/Root/meta.js.map +1 -0
- package/dist/views/Unauthorized/index.d.ts +4 -0
- package/dist/views/Unauthorized/index.d.ts.map +1 -0
- package/dist/views/Unauthorized/index.js +18 -0
- package/dist/views/Unauthorized/index.js.map +1 -0
- package/dist/views/Unauthorized/meta.d.ts +3 -0
- package/dist/views/Unauthorized/meta.d.ts.map +1 -0
- package/dist/views/Unauthorized/meta.js +11 -0
- package/dist/views/Unauthorized/meta.js.map +1 -0
- package/dist/views/Verify/index.d.ts +7 -0
- package/dist/views/Verify/index.d.ts.map +1 -0
- package/dist/views/Verify/index.js +32 -0
- package/dist/views/Verify/index.js.map +1 -0
- package/dist/views/Verify/meta.d.ts +3 -0
- package/dist/views/Verify/meta.d.ts.map +1 -0
- package/dist/views/Verify/meta.js +11 -0
- package/dist/views/Verify/meta.js.map +1 -0
- package/dist/views/Version/Default/SetStepNav.d.ts +14 -0
- package/dist/views/Version/Default/SetStepNav.d.ts.map +1 -0
- package/dist/views/Version/Default/SetStepNav.js +92 -0
- package/dist/views/Version/Default/SetStepNav.js.map +1 -0
- package/dist/views/Version/Default/index.d.ts +5 -0
- package/dist/views/Version/Default/index.d.ts.map +1 -0
- package/dist/views/Version/Default/index.js +111 -0
- package/dist/views/Version/Default/index.js.map +1 -0
- package/dist/views/Version/Default/types.d.ts +19 -0
- package/dist/views/Version/Default/types.d.ts.map +1 -0
- package/dist/views/Version/Default/types.js +3 -0
- package/dist/views/Version/Default/types.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/Label/index.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/Label/index.js +8 -0
- package/dist/views/Version/RenderFieldsToDiff/Label/index.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Iterable/index.d.ts +6 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Iterable/index.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Iterable/index.js +64 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Iterable/index.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Nested/index.d.ts +6 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Nested/index.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Nested/index.js +28 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Nested/index.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Relationship/index.d.ts +6 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Relationship/index.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Relationship/index.js +74 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Relationship/index.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Select/DiffViewer/index.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Select/DiffViewer/index.js +17 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Select/DiffViewer/index.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Select/index.d.ts +10 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Select/index.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Select/index.js +38 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Select/index.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Tabs/index.d.ts +9 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Tabs/index.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Tabs/index.js +39 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Tabs/index.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Text/DiffViewer/index.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Text/DiffViewer/index.js +17 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Text/DiffViewer/index.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Text/index.d.ts +6 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Text/index.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Text/index.js +30 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/Text/index.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/diffMethods.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/diffMethods.js +8 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/diffMethods.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/index.d.ts +60 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/index.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/index.js +29 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/index.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/styles.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/styles.js +28 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/styles.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/types.d.ts +21 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/types.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/types.js +3 -0
- package/dist/views/Version/RenderFieldsToDiff/fields/types.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/index.d.ts +6 -0
- package/dist/views/Version/RenderFieldsToDiff/index.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/index.js +100 -0
- package/dist/views/Version/RenderFieldsToDiff/index.js.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/types.d.ts +20 -0
- package/dist/views/Version/RenderFieldsToDiff/types.d.ts.map +1 -0
- package/dist/views/Version/RenderFieldsToDiff/types.js +3 -0
- package/dist/views/Version/RenderFieldsToDiff/types.js.map +1 -0
- package/dist/views/Version/Restore/index.d.ts +6 -0
- package/dist/views/Version/Restore/index.d.ts.map +1 -0
- package/dist/views/Version/Restore/index.js +74 -0
- package/dist/views/Version/Restore/index.js.map +1 -0
- package/dist/views/Version/Restore/types.d.ts +11 -0
- package/dist/views/Version/Restore/types.d.ts.map +1 -0
- package/dist/views/Version/Restore/types.js +3 -0
- package/dist/views/Version/Restore/types.js.map +1 -0
- package/dist/views/Version/SelectComparison/index.d.ts +5 -0
- package/dist/views/Version/SelectComparison/index.d.ts.map +1 -0
- package/dist/views/Version/SelectComparison/index.js +126 -0
- package/dist/views/Version/SelectComparison/index.js.map +1 -0
- package/dist/views/Version/SelectComparison/types.d.ts +27 -0
- package/dist/views/Version/SelectComparison/types.d.ts.map +1 -0
- package/dist/views/Version/SelectComparison/types.js +3 -0
- package/dist/views/Version/SelectComparison/types.js.map +1 -0
- package/dist/views/Version/SelectLocales/index.d.ts +5 -0
- package/dist/views/Version/SelectLocales/index.d.ts.map +1 -0
- package/dist/views/Version/SelectLocales/index.js +33 -0
- package/dist/views/Version/SelectLocales/index.js.map +1 -0
- package/dist/views/Version/SelectLocales/types.d.ts +7 -0
- package/dist/views/Version/SelectLocales/types.d.ts.map +1 -0
- package/dist/views/Version/SelectLocales/types.js +3 -0
- package/dist/views/Version/SelectLocales/types.js.map +1 -0
- package/dist/views/Version/index.d.ts +3 -0
- package/dist/views/Version/index.d.ts.map +1 -0
- package/dist/views/Version/index.js +102 -0
- package/dist/views/Version/index.js.map +1 -0
- package/dist/views/Version/meta.d.ts +3 -0
- package/dist/views/Version/meta.d.ts.map +1 -0
- package/dist/views/Version/meta.js +37 -0
- package/dist/views/Version/meta.js.map +1 -0
- package/dist/views/Version/shared.d.ts.map +1 -0
- package/dist/views/Version/shared.js +10 -0
- package/dist/views/Version/shared.js.map +1 -0
- package/dist/views/Versions/buildColumns.d.ts +11 -0
- package/dist/views/Versions/buildColumns.d.ts.map +1 -0
- package/dist/views/Versions/buildColumns.js +63 -0
- package/dist/views/Versions/buildColumns.js.map +1 -0
- package/dist/views/Versions/cells/AutosaveCell/index.d.ts.map +1 -0
- package/dist/views/Versions/cells/AutosaveCell/index.js +14 -0
- package/dist/views/Versions/cells/AutosaveCell/index.js.map +1 -0
- package/dist/views/Versions/cells/CreatedAt/index.d.ts.map +1 -0
- package/dist/views/Versions/cells/CreatedAt/index.js +22 -0
- package/dist/views/Versions/cells/CreatedAt/index.js.map +1 -0
- package/dist/views/Versions/cells/ID/index.d.ts.map +1 -0
- package/dist/views/Versions/cells/ID/index.js +9 -0
- package/dist/views/Versions/cells/ID/index.js.map +1 -0
- package/dist/views/Versions/index.client.d.ts +10 -0
- package/dist/views/Versions/index.client.d.ts.map +1 -0
- package/dist/views/Versions/index.client.js +57 -0
- package/dist/views/Versions/index.client.js.map +1 -0
- package/dist/views/Versions/index.d.ts +5 -0
- package/dist/views/Versions/index.d.ts.map +1 -0
- package/dist/views/Versions/index.js +93 -0
- package/dist/views/Versions/index.js.map +1 -0
- package/dist/views/Versions/meta.d.ts +3 -0
- package/dist/views/Versions/meta.d.ts.map +1 -0
- package/dist/views/Versions/meta.js +33 -0
- package/dist/views/Versions/meta.js.map +1 -0
- package/dist/views/Versions/types.d.ts.map +1 -0
- package/dist/views/Versions/types.js +3 -0
- package/dist/views/Versions/types.js.map +1 -0
- package/dist/webpackEntry.d.ts +5 -0
- package/dist/webpackEntry.d.ts.map +1 -0
- package/dist/webpackEntry.js +6 -0
- package/dist/webpackEntry.js.map +1 -0
- package/dist/withPayload.d.ts +2 -1
- package/dist/withPayload.d.ts.map +1 -1
- package/dist/withPayload.js +3 -8
- package/dist/withPayload.js.map +1 -0
- package/package.json +46 -41
- package/src/index.js +1 -0
- package/dist/bin/index.d.ts +0 -2
- package/dist/bin/index.d.ts.map +0 -1
- package/dist/bin/index.js +0 -37
- package/dist/bin/install.d.ts +0 -4
- package/dist/bin/install.d.ts.map +0 -1
- package/dist/bin/install.js +0 -77
- package/dist/exports/index.d.ts +0 -2
- package/dist/exports/index.d.ts.map +0 -1
- package/dist/exports/index.js +0 -13
- package/dist/graphql/registerSchema.d.ts +0 -2
- package/dist/graphql/registerSchema.d.ts.map +0 -1
- package/dist/graphql/registerSchema.js +0 -3
- package/dist/index.d.ts +0 -2
- package/dist/index.d.ts.map +0 -1
- package/dist/layouts/Admin/index.d.ts +0 -12
- package/dist/layouts/Admin/index.d.ts.map +0 -1
- package/dist/layouts/Admin/index.js +0 -44
- package/dist/layouts/Document/index.d.ts +0 -14
- package/dist/layouts/Document/index.d.ts.map +0 -1
- package/dist/layouts/Document/index.js +0 -82
- package/dist/pages/API/RenderJSON/index.d.ts.map +0 -1
- package/dist/pages/API/RenderJSON/index.js +0 -142
- package/dist/pages/API/index.client.d.ts +0 -5
- package/dist/pages/API/index.client.d.ts.map +0 -1
- package/dist/pages/API/index.client.js +0 -241
- package/dist/pages/API/index.d.ts +0 -4
- package/dist/pages/API/index.d.ts.map +0 -1
- package/dist/pages/API/index.js +0 -27
- package/dist/pages/API/meta.d.ts +0 -3
- package/dist/pages/API/meta.d.ts.map +0 -1
- package/dist/pages/API/meta.js +0 -21
- package/dist/pages/Account/Settings/index.d.ts.map +0 -1
- package/dist/pages/Account/Settings/index.js +0 -45
- package/dist/pages/Account/ToggleTheme/index.d.ts.map +0 -1
- package/dist/pages/Account/ToggleTheme/index.js +0 -85
- package/dist/pages/Account/index.d.ts +0 -13
- package/dist/pages/Account/index.d.ts.map +0 -1
- package/dist/pages/Account/index.js +0 -171
- package/dist/pages/CreateFirstUser/index.client.d.ts +0 -5
- package/dist/pages/CreateFirstUser/index.client.d.ts.map +0 -1
- package/dist/pages/CreateFirstUser/index.client.js +0 -29
- package/dist/pages/CreateFirstUser/index.d.ts +0 -11
- package/dist/pages/CreateFirstUser/index.d.ts.map +0 -1
- package/dist/pages/CreateFirstUser/index.js +0 -91
- package/dist/pages/Dashboard/Default/index.client.d.ts +0 -8
- package/dist/pages/Dashboard/Default/index.client.d.ts.map +0 -1
- package/dist/pages/Dashboard/Default/index.client.js +0 -154
- package/dist/pages/Dashboard/Default/index.d.ts +0 -11
- package/dist/pages/Dashboard/Default/index.d.ts.map +0 -1
- package/dist/pages/Dashboard/Default/index.js +0 -44
- package/dist/pages/Dashboard/index.d.ts +0 -13
- package/dist/pages/Dashboard/index.d.ts.map +0 -1
- package/dist/pages/Dashboard/index.js +0 -128
- package/dist/pages/Document/getCustomViewByKey.d.ts +0 -4
- package/dist/pages/Document/getCustomViewByKey.d.ts.map +0 -1
- package/dist/pages/Document/getCustomViewByKey.js +0 -15
- package/dist/pages/Document/getCustomViewByPath.d.ts +0 -4
- package/dist/pages/Document/getCustomViewByPath.d.ts.map +0 -1
- package/dist/pages/Document/getCustomViewByPath.js +0 -26
- package/dist/pages/Document/getMetaBySegment.d.ts +0 -20
- package/dist/pages/Document/getMetaBySegment.d.ts.map +0 -1
- package/dist/pages/Document/getMetaBySegment.js +0 -124
- package/dist/pages/Document/getViewsFromConfig.d.ts +0 -15
- package/dist/pages/Document/getViewsFromConfig.d.ts.map +0 -1
- package/dist/pages/Document/getViewsFromConfig.js +0 -163
- package/dist/pages/Document/index.d.ts +0 -23
- package/dist/pages/Document/index.d.ts.map +0 -1
- package/dist/pages/Document/index.js +0 -237
- package/dist/pages/Edit/Default/Auth/APIKey.d.ts +0 -6
- package/dist/pages/Edit/Default/Auth/APIKey.d.ts.map +0 -1
- package/dist/pages/Edit/Default/Auth/APIKey.js +0 -140
- package/dist/pages/Edit/Default/Auth/index.d.ts +0 -6
- package/dist/pages/Edit/Default/Auth/index.d.ts.map +0 -1
- package/dist/pages/Edit/Default/Auth/index.js +0 -180
- package/dist/pages/Edit/Default/Auth/types.d.ts.map +0 -1
- package/dist/pages/Edit/Default/Auth/types.js +0 -6
- package/dist/pages/Edit/Default/RenderCustomView.d.ts +0 -2
- package/dist/pages/Edit/Default/RenderCustomView.d.ts.map +0 -1
- package/dist/pages/Edit/Default/RenderCustomView.js +0 -3
- package/dist/pages/Edit/Default/SetDocumentTitle/index.d.ts +0 -8
- package/dist/pages/Edit/Default/SetDocumentTitle/index.d.ts.map +0 -1
- package/dist/pages/Edit/Default/SetDocumentTitle/index.js +0 -50
- package/dist/pages/Edit/Default/SetStepNav/index.d.ts +0 -13
- package/dist/pages/Edit/Default/SetStepNav/index.d.ts.map +0 -1
- package/dist/pages/Edit/Default/SetStepNav/index.js +0 -70
- package/dist/pages/Edit/Default/index.d.ts.map +0 -1
- package/dist/pages/Edit/Default/index.js +0 -202
- package/dist/pages/Edit/Default/types.d.ts.map +0 -1
- package/dist/pages/Edit/Default/types.js +0 -6
- package/dist/pages/Edit/index.client.d.ts +0 -4
- package/dist/pages/Edit/index.client.d.ts.map +0 -1
- package/dist/pages/Edit/index.client.js +0 -99
- package/dist/pages/Edit/index.d.ts +0 -4
- package/dist/pages/Edit/index.d.ts.map +0 -1
- package/dist/pages/Edit/index.js +0 -27
- package/dist/pages/Edit/meta.d.ts +0 -3
- package/dist/pages/Edit/meta.d.ts.map +0 -1
- package/dist/pages/Edit/meta.js +0 -36
- package/dist/pages/Edit/sanitizeEditViewProps.d.ts +0 -4
- package/dist/pages/Edit/sanitizeEditViewProps.d.ts.map +0 -1
- package/dist/pages/Edit/sanitizeEditViewProps.js +0 -24
- package/dist/pages/Edit/types.d.js +0 -7
- package/dist/pages/Edit/types.d.ts +0 -37
- package/dist/pages/Edit/types.d.ts.map +0 -1
- package/dist/pages/Edit/types.js +0 -6
- package/dist/pages/ForgotPassword/index.d.ts +0 -10
- package/dist/pages/ForgotPassword/index.d.ts.map +0 -1
- package/dist/pages/ForgotPassword/index.js +0 -101
- package/dist/pages/List/Default/Cell/cellTypes.spec.js +0 -234
- package/dist/pages/List/Default/Cell/fields/Array/index.d.ts +0 -7
- package/dist/pages/List/Default/Cell/fields/Array/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/Array/index.js +0 -27
- package/dist/pages/List/Default/Cell/fields/Blocks/index.d.ts +0 -8
- package/dist/pages/List/Default/Cell/fields/Blocks/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/Blocks/index.js +0 -45
- package/dist/pages/List/Default/Cell/fields/Checkbox/index.d.ts +0 -5
- package/dist/pages/List/Default/Cell/fields/Checkbox/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/Checkbox/index.js +0 -23
- package/dist/pages/List/Default/Cell/fields/Checkbox/index.scss +0 -22
- package/dist/pages/List/Default/Cell/fields/Code/index.d.ts +0 -8
- package/dist/pages/List/Default/Cell/fields/Code/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/Code/index.js +0 -29
- package/dist/pages/List/Default/Cell/fields/Code/index.scss +0 -27
- package/dist/pages/List/Default/Cell/fields/Date/index.d.ts +0 -7
- package/dist/pages/List/Default/Cell/fields/Date/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/Date/index.js +0 -26
- package/dist/pages/List/Default/Cell/fields/File/index.d.ts +0 -7
- package/dist/pages/List/Default/Cell/fields/File/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/File/index.js +0 -39
- package/dist/pages/List/Default/Cell/fields/File/index.scss +0 -23
- package/dist/pages/List/Default/Cell/fields/JSON/index.d.ts +0 -5
- package/dist/pages/List/Default/Cell/fields/JSON/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/JSON/index.js +0 -26
- package/dist/pages/List/Default/Cell/fields/JSON/index.scss +0 -22
- package/dist/pages/List/Default/Cell/fields/Relationship/index.d.ts +0 -9
- package/dist/pages/List/Default/Cell/fields/Relationship/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/Relationship/index.js +0 -121
- package/dist/pages/List/Default/Cell/fields/Relationship/index.scss +0 -3
- package/dist/pages/List/Default/Cell/fields/Richtext/index.d.ts +0 -2
- package/dist/pages/List/Default/Cell/fields/Richtext/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/Richtext/index.js +0 -3
- package/dist/pages/List/Default/Cell/fields/Select/index.d.ts +0 -7
- package/dist/pages/List/Default/Cell/fields/Select/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/Select/index.js +0 -40
- package/dist/pages/List/Default/Cell/fields/Textarea/index.d.ts +0 -4
- package/dist/pages/List/Default/Cell/fields/Textarea/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/Textarea/index.js +0 -23
- package/dist/pages/List/Default/Cell/fields/index.d.ts +0 -17
- package/dist/pages/List/Default/Cell/fields/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/fields/index.js +0 -36
- package/dist/pages/List/Default/Cell/index.d.ts +0 -4
- package/dist/pages/List/Default/Cell/index.d.ts.map +0 -1
- package/dist/pages/List/Default/Cell/index.js +0 -89
- package/dist/pages/List/Default/RelationshipProvider/index.d.ts +0 -20
- package/dist/pages/List/Default/RelationshipProvider/index.d.ts.map +0 -1
- package/dist/pages/List/Default/RelationshipProvider/index.js +0 -153
- package/dist/pages/List/Default/RelationshipProvider/reducer.d.ts +0 -19
- package/dist/pages/List/Default/RelationshipProvider/reducer.d.ts.map +0 -1
- package/dist/pages/List/Default/RelationshipProvider/reducer.js +0 -55
- package/dist/pages/List/Default/index.d.ts.map +0 -1
- package/dist/pages/List/Default/index.js +0 -174
- package/dist/pages/List/Default/types.d.ts +0 -14
- package/dist/pages/List/Default/types.d.ts.map +0 -1
- package/dist/pages/List/Default/types.js +0 -6
- package/dist/pages/List/index.d.ts +0 -18
- package/dist/pages/List/index.d.ts.map +0 -1
- package/dist/pages/List/index.js +0 -158
- package/dist/pages/LivePreview/Context/collisionDetection.d.ts.map +0 -1
- package/dist/pages/LivePreview/Context/collisionDetection.js +0 -34
- package/dist/pages/LivePreview/Context/context.d.ts +0 -50
- package/dist/pages/LivePreview/Context/context.d.ts.map +0 -1
- package/dist/pages/LivePreview/Context/context.js +0 -58
- package/dist/pages/LivePreview/Context/index.d.ts +0 -18
- package/dist/pages/LivePreview/Context/index.d.ts.map +0 -1
- package/dist/pages/LivePreview/Context/index.js +0 -208
- package/dist/pages/LivePreview/Context/sizeReducer.d.ts.map +0 -1
- package/dist/pages/LivePreview/Context/sizeReducer.js +0 -41
- package/dist/pages/LivePreview/Device/index.d.ts.map +0 -1
- package/dist/pages/LivePreview/Device/index.js +0 -102
- package/dist/pages/LivePreview/DeviceContainer/index.d.ts.map +0 -1
- package/dist/pages/LivePreview/DeviceContainer/index.js +0 -44
- package/dist/pages/LivePreview/IFrame/index.d.ts.map +0 -1
- package/dist/pages/LivePreview/IFrame/index.js +0 -74
- package/dist/pages/LivePreview/Preview/index.d.ts +0 -5
- package/dist/pages/LivePreview/Preview/index.d.ts.map +0 -1
- package/dist/pages/LivePreview/Preview/index.js +0 -127
- package/dist/pages/LivePreview/Toolbar/Controls/index.d.ts +0 -5
- package/dist/pages/LivePreview/Toolbar/Controls/index.d.ts.map +0 -1
- package/dist/pages/LivePreview/Toolbar/Controls/index.js +0 -96
- package/dist/pages/LivePreview/Toolbar/SizeInput/index.d.ts.map +0 -1
- package/dist/pages/LivePreview/Toolbar/SizeInput/index.js +0 -112
- package/dist/pages/LivePreview/Toolbar/index.d.ts +0 -7
- package/dist/pages/LivePreview/Toolbar/index.d.ts.map +0 -1
- package/dist/pages/LivePreview/Toolbar/index.js +0 -65
- package/dist/pages/LivePreview/ToolbarArea/index.d.ts.map +0 -1
- package/dist/pages/LivePreview/ToolbarArea/index.js +0 -32
- package/dist/pages/LivePreview/index.client.d.ts +0 -11
- package/dist/pages/LivePreview/index.client.d.ts.map +0 -1
- package/dist/pages/LivePreview/index.client.js +0 -195
- package/dist/pages/LivePreview/index.d.ts +0 -5
- package/dist/pages/LivePreview/index.d.ts.map +0 -1
- package/dist/pages/LivePreview/index.js +0 -59
- package/dist/pages/LivePreview/meta.d.ts +0 -3
- package/dist/pages/LivePreview/meta.d.ts.map +0 -1
- package/dist/pages/LivePreview/meta.js +0 -36
- package/dist/pages/LivePreview/usePopupWindow.d.ts.map +0 -1
- package/dist/pages/LivePreview/usePopupWindow.js +0 -112
- package/dist/pages/Login/LoginForm/index.d.ts.map +0 -1
- package/dist/pages/Login/LoginForm/index.js +0 -67
- package/dist/pages/Login/index.d.ts +0 -14
- package/dist/pages/Login/index.d.ts.map +0 -1
- package/dist/pages/Login/index.js +0 -108
- package/dist/pages/Login/index.scss +0 -38
- package/dist/pages/Logout/LogoutClient.d.ts.map +0 -1
- package/dist/pages/Logout/LogoutClient.js +0 -88
- package/dist/pages/Logout/index.d.ts +0 -16
- package/dist/pages/Logout/index.d.ts.map +0 -1
- package/dist/pages/Logout/index.js +0 -61
- package/dist/pages/NotFound/index.d.ts +0 -7
- package/dist/pages/NotFound/index.d.ts.map +0 -1
- package/dist/pages/NotFound/index.js +0 -48
- package/dist/pages/NotFound/index.scss +0 -36
- package/dist/pages/ResetPassword/index.d.ts +0 -12
- package/dist/pages/ResetPassword/index.d.ts.map +0 -1
- package/dist/pages/ResetPassword/index.js +0 -99
- package/dist/pages/Root/index.d.ts +0 -5
- package/dist/pages/Root/index.d.ts.map +0 -1
- package/dist/pages/Root/index.js +0 -17
- package/dist/pages/Unauthorized/UnauthorizedClient.d.ts +0 -5
- package/dist/pages/Unauthorized/UnauthorizedClient.d.ts.map +0 -1
- package/dist/pages/Unauthorized/UnauthorizedClient.js +0 -27
- package/dist/pages/Unauthorized/index.d.ts +0 -10
- package/dist/pages/Unauthorized/index.d.ts.map +0 -1
- package/dist/pages/Unauthorized/index.js +0 -51
- package/dist/pages/Verify/index.d.ts +0 -13
- package/dist/pages/Verify/index.d.ts.map +0 -1
- package/dist/pages/Verify/index.js +0 -90
- package/dist/pages/Version/Default/SetStepNav.d.ts +0 -13
- package/dist/pages/Version/Default/SetStepNav.d.ts.map +0 -1
- package/dist/pages/Version/Default/SetStepNav.js +0 -92
- package/dist/pages/Version/Default/index.d.ts +0 -5
- package/dist/pages/Version/Default/index.d.ts.map +0 -1
- package/dist/pages/Version/Default/index.js +0 -157
- package/dist/pages/Version/Default/types.d.ts +0 -24
- package/dist/pages/Version/Default/types.d.ts.map +0 -1
- package/dist/pages/Version/Default/types.js +0 -6
- package/dist/pages/Version/RenderFieldsToDiff/Label/index.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/Label/index.js +0 -24
- package/dist/pages/Version/RenderFieldsToDiff/fields/Iterable/index.d.ts +0 -6
- package/dist/pages/Version/RenderFieldsToDiff/fields/Iterable/index.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/Iterable/index.js +0 -80
- package/dist/pages/Version/RenderFieldsToDiff/fields/Nested/index.d.ts +0 -6
- package/dist/pages/Version/RenderFieldsToDiff/fields/Nested/index.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/Nested/index.js +0 -44
- package/dist/pages/Version/RenderFieldsToDiff/fields/Relationship/index.d.ts +0 -6
- package/dist/pages/Version/RenderFieldsToDiff/fields/Relationship/index.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/Relationship/index.js +0 -89
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/DiffViewer/index.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/DiffViewer/index.js +0 -72
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/index.d.ts +0 -6
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/index.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/index.js +0 -54
- package/dist/pages/Version/RenderFieldsToDiff/fields/Tabs/index.d.ts +0 -5
- package/dist/pages/Version/RenderFieldsToDiff/fields/Tabs/index.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/Tabs/index.js +0 -54
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/DiffViewer/index.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/DiffViewer/index.js +0 -72
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/index.d.ts +0 -6
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/index.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/index.js +0 -46
- package/dist/pages/Version/RenderFieldsToDiff/fields/diffMethods.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/diffMethods.js +0 -18
- package/dist/pages/Version/RenderFieldsToDiff/fields/index.d.ts +0 -25
- package/dist/pages/Version/RenderFieldsToDiff/fields/index.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/index.js +0 -44
- package/dist/pages/Version/RenderFieldsToDiff/fields/styles.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/styles.js +0 -38
- package/dist/pages/Version/RenderFieldsToDiff/fields/types.d.ts +0 -21
- package/dist/pages/Version/RenderFieldsToDiff/fields/types.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/fields/types.js +0 -6
- package/dist/pages/Version/RenderFieldsToDiff/index.d.ts +0 -6
- package/dist/pages/Version/RenderFieldsToDiff/index.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/index.js +0 -115
- package/dist/pages/Version/RenderFieldsToDiff/types.d.ts +0 -20
- package/dist/pages/Version/RenderFieldsToDiff/types.d.ts.map +0 -1
- package/dist/pages/Version/RenderFieldsToDiff/types.js +0 -6
- package/dist/pages/Version/Restore/index.d.ts +0 -6
- package/dist/pages/Version/Restore/index.d.ts.map +0 -1
- package/dist/pages/Version/Restore/index.js +0 -121
- package/dist/pages/Version/Restore/types.d.ts +0 -11
- package/dist/pages/Version/Restore/types.d.ts.map +0 -1
- package/dist/pages/Version/Restore/types.js +0 -6
- package/dist/pages/Version/SelectComparison/index.d.ts +0 -5
- package/dist/pages/Version/SelectComparison/index.d.ts.map +0 -1
- package/dist/pages/Version/SelectComparison/index.js +0 -167
- package/dist/pages/Version/SelectComparison/types.d.ts +0 -27
- package/dist/pages/Version/SelectComparison/types.d.ts.map +0 -1
- package/dist/pages/Version/SelectComparison/types.js +0 -6
- package/dist/pages/Version/SelectLocales/index.d.ts +0 -5
- package/dist/pages/Version/SelectLocales/index.d.ts.map +0 -1
- package/dist/pages/Version/SelectLocales/index.js +0 -47
- package/dist/pages/Version/SelectLocales/types.d.ts +0 -7
- package/dist/pages/Version/SelectLocales/types.d.ts.map +0 -1
- package/dist/pages/Version/SelectLocales/types.js +0 -6
- package/dist/pages/Version/index.d.ts +0 -4
- package/dist/pages/Version/index.d.ts.map +0 -1
- package/dist/pages/Version/index.js +0 -111
- package/dist/pages/Version/meta.d.ts +0 -3
- package/dist/pages/Version/meta.d.ts.map +0 -1
- package/dist/pages/Version/meta.js +0 -47
- package/dist/pages/Version/shared.d.ts.map +0 -1
- package/dist/pages/Version/shared.js +0 -28
- package/dist/pages/Versions/buildColumns.d.ts +0 -11
- package/dist/pages/Versions/buildColumns.d.ts.map +0 -1
- package/dist/pages/Versions/buildColumns.js +0 -69
- package/dist/pages/Versions/cells/AutosaveCell/index.d.ts.map +0 -1
- package/dist/pages/Versions/cells/AutosaveCell/index.js +0 -63
- package/dist/pages/Versions/cells/CreatedAt/index.d.ts.map +0 -1
- package/dist/pages/Versions/cells/CreatedAt/index.js +0 -33
- package/dist/pages/Versions/cells/ID/index.d.ts.map +0 -1
- package/dist/pages/Versions/cells/ID/index.js +0 -60
- package/dist/pages/Versions/index.client.d.ts +0 -15
- package/dist/pages/Versions/index.client.d.ts.map +0 -1
- package/dist/pages/Versions/index.client.js +0 -142
- package/dist/pages/Versions/index.d.ts +0 -6
- package/dist/pages/Versions/index.d.ts.map +0 -1
- package/dist/pages/Versions/index.js +0 -125
- package/dist/pages/Versions/meta.d.ts +0 -3
- package/dist/pages/Versions/meta.d.ts.map +0 -1
- package/dist/pages/Versions/meta.js +0 -43
- package/dist/pages/Versions/types.d.ts.map +0 -1
- package/dist/pages/Versions/types.js +0 -6
- package/dist/routes/rest/RouteError.d.ts +0 -13
- package/dist/routes/rest/RouteError.d.ts.map +0 -1
- package/dist/routes/rest/RouteError.js +0 -104
- package/dist/routes/rest/[collection]/file/[filename]/route.d.ts +0 -8
- package/dist/routes/rest/[collection]/file/[filename]/route.d.ts.map +0 -1
- package/dist/routes/rest/[collection]/file/[filename]/route.js +0 -116
- package/dist/utilities/createClientConfig.d.ts +0 -5
- package/dist/utilities/createClientConfig.d.ts.map +0 -1
- package/dist/utilities/createClientConfig.js +0 -120
- package/dist/utilities/getNextT.d.ts +0 -7
- package/dist/utilities/getNextT.d.ts.map +0 -1
- package/dist/utilities/getNextT.js +0 -28
- package/src/index.ts +0 -1
- /package/dist/{pages → views}/API/RenderJSON/index.d.ts +0 -0
- /package/dist/{pages → views}/API/RenderJSON/index.scss +0 -0
- /package/dist/{pages → views}/API/index.scss +0 -0
- /package/dist/{pages → views}/Account/Settings/index.d.ts +0 -0
- /package/dist/{pages → views}/Account/Settings/index.scss +0 -0
- /package/dist/{pages → views}/Account/ToggleTheme/index.d.ts +0 -0
- /package/dist/{pages → views}/CreateFirstUser/index.scss +0 -0
- /package/dist/{pages → views}/Dashboard/Default/index.scss +0 -0
- /package/dist/{pages → views}/Edit/Default/Auth/index.scss +0 -0
- /package/dist/{pages → views}/Edit/Default/Auth/types.d.ts +0 -0
- /package/dist/{pages → views}/Edit/Default/index.d.ts +0 -0
- /package/dist/{pages → views}/Edit/Default/index.scss +0 -0
- /package/dist/{pages → views}/Edit/Default/types.d.ts +0 -0
- /package/dist/{pages → views}/List/Default/index.d.ts +0 -0
- /package/dist/{pages → views}/List/Default/index.scss +0 -0
- /package/dist/{pages → views}/LivePreview/Context/collisionDetection.d.ts +0 -0
- /package/dist/{pages → views}/LivePreview/Context/sizeReducer.d.ts +0 -0
- /package/dist/{pages → views}/LivePreview/Device/index.d.ts +0 -0
- /package/dist/{pages → views}/LivePreview/DeviceContainer/index.d.ts +0 -0
- /package/dist/{pages → views}/LivePreview/IFrame/index.d.ts +0 -0
- /package/dist/{pages → views}/LivePreview/IFrame/index.scss +0 -0
- /package/dist/{pages → views}/LivePreview/Preview/index.scss +0 -0
- /package/dist/{pages → views}/LivePreview/Toolbar/Controls/index.scss +0 -0
- /package/dist/{pages → views}/LivePreview/Toolbar/SizeInput/index.d.ts +0 -0
- /package/dist/{pages → views}/LivePreview/Toolbar/SizeInput/index.scss +0 -0
- /package/dist/{pages → views}/LivePreview/Toolbar/index.scss +0 -0
- /package/dist/{pages → views}/LivePreview/ToolbarArea/index.d.ts +0 -0
- /package/dist/{pages → views}/LivePreview/ToolbarArea/index.scss +0 -0
- /package/dist/{pages → views}/LivePreview/index.scss +0 -0
- /package/dist/{pages → views}/LivePreview/usePopupWindow.d.ts +0 -0
- /package/dist/{pages → views}/Login/LoginForm/index.d.ts +0 -0
- /package/dist/{pages → views}/Login/LoginForm/index.scss +0 -0
- /package/dist/{pages → views}/Logout/LogoutClient.d.ts +0 -0
- /package/dist/{pages → views}/Logout/index.scss +0 -0
- /package/dist/{pages → views}/ResetPassword/index.scss +0 -0
- /package/dist/{pages → views}/Verify/index.scss +0 -0
- /package/dist/{pages → views}/Version/Default/index.scss +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/Label/index.d.ts +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/Label/index.scss +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/fields/Iterable/index.scss +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/fields/Nested/index.scss +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/fields/Relationship/index.scss +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/fields/Select/DiffViewer/index.d.ts +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/fields/Select/index.scss +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/fields/Text/DiffViewer/index.d.ts +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/fields/Text/index.scss +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/fields/diffMethods.d.ts +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/fields/styles.d.ts +0 -0
- /package/dist/{pages → views}/Version/RenderFieldsToDiff/index.scss +0 -0
- /package/dist/{pages → views}/Version/Restore/index.scss +0 -0
- /package/dist/{pages → views}/Version/SelectComparison/index.scss +0 -0
- /package/dist/{pages → views}/Version/SelectLocales/index.scss +0 -0
- /package/dist/{pages → views}/Version/shared.d.ts +0 -0
- /package/dist/{pages → views}/Versions/cells/AutosaveCell/index.d.ts +0 -0
- /package/dist/{pages → views}/Versions/cells/CreatedAt/index.d.ts +0 -0
- /package/dist/{pages → views}/Versions/cells/ID/index.d.ts +0 -0
- /package/dist/{pages → views}/Versions/index.scss +0 -0
- /package/dist/{pages → views}/Versions/types.d.ts +0 -0
package/dist/config.js
CHANGED
|
@@ -1,13 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", {
|
|
3
|
-
value: true
|
|
4
|
-
});
|
|
5
|
-
Object.defineProperty(exports, "default", {
|
|
6
|
-
enumerable: true,
|
|
7
|
-
get: function() {
|
|
8
|
-
return _default;
|
|
9
|
-
}
|
|
10
|
-
});
|
|
11
|
-
const _default = {};
|
|
1
|
+
export default {};
|
|
12
2
|
|
|
13
|
-
//# sourceMappingURL=
|
|
3
|
+
//# sourceMappingURL=config.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/config.ts"],"sourcesContent":["import type { SanitizedConfig } from 'payload/config'\n\nexport default {} as Promise<SanitizedConfig>\n"],"names":[],"mappings":"AAEA,eAAe,CAAC,EAA6B"}
|
|
@@ -1,74 +1,23 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
return LeaveWithoutSaving;
|
|
10
|
-
}
|
|
11
|
-
});
|
|
12
|
-
const _ui = require("@payloadcms/ui");
|
|
13
|
-
const _elements = require("@payloadcms/ui/elements");
|
|
14
|
-
const _forms = require("@payloadcms/ui/forms");
|
|
15
|
-
const _providers = require("@payloadcms/ui/providers");
|
|
16
|
-
const _react = /*#__PURE__*/ _interop_require_wildcard(require("react"));
|
|
17
|
-
require("./index.scss");
|
|
18
|
-
const _usePreventLeave = require("./usePreventLeave");
|
|
19
|
-
function _getRequireWildcardCache(nodeInterop) {
|
|
20
|
-
if (typeof WeakMap !== "function") return null;
|
|
21
|
-
var cacheBabelInterop = new WeakMap();
|
|
22
|
-
var cacheNodeInterop = new WeakMap();
|
|
23
|
-
return (_getRequireWildcardCache = function(nodeInterop) {
|
|
24
|
-
return nodeInterop ? cacheNodeInterop : cacheBabelInterop;
|
|
25
|
-
})(nodeInterop);
|
|
26
|
-
}
|
|
27
|
-
function _interop_require_wildcard(obj, nodeInterop) {
|
|
28
|
-
if (!nodeInterop && obj && obj.__esModule) {
|
|
29
|
-
return obj;
|
|
30
|
-
}
|
|
31
|
-
if (obj === null || typeof obj !== "object" && typeof obj !== "function") {
|
|
32
|
-
return {
|
|
33
|
-
default: obj
|
|
34
|
-
};
|
|
35
|
-
}
|
|
36
|
-
var cache = _getRequireWildcardCache(nodeInterop);
|
|
37
|
-
if (cache && cache.has(obj)) {
|
|
38
|
-
return cache.get(obj);
|
|
39
|
-
}
|
|
40
|
-
var newObj = {
|
|
41
|
-
__proto__: null
|
|
42
|
-
};
|
|
43
|
-
var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
|
|
44
|
-
for(var key in obj){
|
|
45
|
-
if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
46
|
-
var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
|
|
47
|
-
if (desc && (desc.get || desc.set)) {
|
|
48
|
-
Object.defineProperty(newObj, key, desc);
|
|
49
|
-
} else {
|
|
50
|
-
newObj[key] = obj[key];
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
newObj.default = obj;
|
|
55
|
-
if (cache) {
|
|
56
|
-
cache.set(obj, newObj);
|
|
57
|
-
}
|
|
58
|
-
return newObj;
|
|
59
|
-
}
|
|
2
|
+
import { Button } from '@payloadcms/ui/elements/Button';
|
|
3
|
+
import { Modal, useModal } from '@payloadcms/ui/elements/Modal';
|
|
4
|
+
import { useFormModified } from '@payloadcms/ui/forms/Form';
|
|
5
|
+
import { useAuth } from '@payloadcms/ui/providers/Auth';
|
|
6
|
+
import { useTranslation } from '@payloadcms/ui/providers/Translation';
|
|
7
|
+
import React, { useCallback, useEffect } from 'react';
|
|
8
|
+
import { usePreventLeave } from './usePreventLeave.js';
|
|
60
9
|
const modalSlug = 'leave-without-saving';
|
|
61
10
|
const baseClass = 'leave-without-saving';
|
|
62
11
|
const Component = ({ isActive, onCancel, onConfirm })=>{
|
|
63
|
-
const { closeModal, modalState, openModal } =
|
|
64
|
-
const { t } =
|
|
12
|
+
const { closeModal, modalState, openModal } = useModal();
|
|
13
|
+
const { t } = useTranslation();
|
|
65
14
|
// Manually check for modal state as 'esc' key will not trigger the nav inactivity
|
|
66
15
|
// useEffect(() => {
|
|
67
16
|
// if (!modalState?.[modalSlug]?.isOpen && isActive) {
|
|
68
17
|
// onCancel()
|
|
69
18
|
// }
|
|
70
19
|
// }, [modalState, isActive, onCancel])
|
|
71
|
-
|
|
20
|
+
useEffect(()=>{
|
|
72
21
|
if (isActive) openModal(modalSlug);
|
|
73
22
|
else closeModal(modalSlug);
|
|
74
23
|
}, [
|
|
@@ -76,38 +25,38 @@ const Component = ({ isActive, onCancel, onConfirm })=>{
|
|
|
76
25
|
openModal,
|
|
77
26
|
closeModal
|
|
78
27
|
]);
|
|
79
|
-
return /*#__PURE__*/
|
|
28
|
+
return /*#__PURE__*/ React.createElement(Modal, {
|
|
80
29
|
className: baseClass,
|
|
81
30
|
onClose: onCancel,
|
|
82
31
|
slug: modalSlug
|
|
83
|
-
}, /*#__PURE__*/
|
|
32
|
+
}, /*#__PURE__*/ React.createElement("div", {
|
|
84
33
|
className: `${baseClass}__wrapper`
|
|
85
|
-
}, /*#__PURE__*/
|
|
34
|
+
}, /*#__PURE__*/ React.createElement("div", {
|
|
86
35
|
className: `${baseClass}__content`
|
|
87
|
-
}, /*#__PURE__*/
|
|
36
|
+
}, /*#__PURE__*/ React.createElement("h1", null, t('general:leaveWithoutSaving')), /*#__PURE__*/ React.createElement("p", null, t('general:changesNotSaved'))), /*#__PURE__*/ React.createElement("div", {
|
|
88
37
|
className: `${baseClass}__controls`
|
|
89
|
-
}, /*#__PURE__*/
|
|
38
|
+
}, /*#__PURE__*/ React.createElement(Button, {
|
|
90
39
|
buttonStyle: "secondary",
|
|
91
40
|
onClick: onCancel
|
|
92
|
-
}, t('general:stayOnThisPage')), /*#__PURE__*/
|
|
41
|
+
}, t('general:stayOnThisPage')), /*#__PURE__*/ React.createElement(Button, {
|
|
93
42
|
onClick: onConfirm
|
|
94
43
|
}, t('general:leaveAnyway')))));
|
|
95
44
|
};
|
|
96
|
-
const LeaveWithoutSaving = ()=>{
|
|
97
|
-
const modified =
|
|
98
|
-
const { user } =
|
|
99
|
-
const [show, setShow] =
|
|
100
|
-
const [hasAccepted, setHasAccepted] =
|
|
45
|
+
export const LeaveWithoutSaving = ()=>{
|
|
46
|
+
const modified = useFormModified();
|
|
47
|
+
const { user } = useAuth();
|
|
48
|
+
const [show, setShow] = React.useState(false);
|
|
49
|
+
const [hasAccepted, setHasAccepted] = React.useState(false);
|
|
101
50
|
const prevent = Boolean(modified && user);
|
|
102
|
-
const onPrevent =
|
|
51
|
+
const onPrevent = useCallback(()=>{
|
|
103
52
|
setShow(true);
|
|
104
53
|
}, []);
|
|
105
|
-
|
|
54
|
+
usePreventLeave({
|
|
106
55
|
hasAccepted,
|
|
107
56
|
onPrevent,
|
|
108
57
|
prevent
|
|
109
58
|
});
|
|
110
|
-
return /*#__PURE__*/
|
|
59
|
+
return /*#__PURE__*/ React.createElement(Component, {
|
|
111
60
|
isActive: show,
|
|
112
61
|
onCancel: ()=>{
|
|
113
62
|
setShow(false);
|
|
@@ -118,4 +67,4 @@ const LeaveWithoutSaving = ()=>{
|
|
|
118
67
|
});
|
|
119
68
|
};
|
|
120
69
|
|
|
121
|
-
//# sourceMappingURL=
|
|
70
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/elements/LeaveWithoutSaving/index.tsx"],"sourcesContent":["'use client'\nimport { Button } from '@payloadcms/ui/elements/Button'\nimport { Modal, useModal } from '@payloadcms/ui/elements/Modal'\nimport { useFormModified } from '@payloadcms/ui/forms/Form'\nimport { useAuth } from '@payloadcms/ui/providers/Auth'\nimport { useTranslation } from '@payloadcms/ui/providers/Translation'\nimport React, { useCallback, useEffect } from 'react'\n\nimport './index.scss'\nimport { usePreventLeave } from './usePreventLeave.js'\n\nconst modalSlug = 'leave-without-saving'\n\nconst baseClass = 'leave-without-saving'\n\nconst Component: React.FC<{\n isActive: boolean\n onCancel: () => void\n onConfirm: () => void\n}> = ({ isActive, onCancel, onConfirm }) => {\n const { closeModal, modalState, openModal } = useModal()\n const { t } = useTranslation()\n\n // Manually check for modal state as 'esc' key will not trigger the nav inactivity\n // useEffect(() => {\n // if (!modalState?.[modalSlug]?.isOpen && isActive) {\n // onCancel()\n // }\n // }, [modalState, isActive, onCancel])\n\n useEffect(() => {\n if (isActive) openModal(modalSlug)\n else closeModal(modalSlug)\n }, [isActive, openModal, closeModal])\n\n return (\n <Modal className={baseClass} onClose={onCancel} slug={modalSlug}>\n <div className={`${baseClass}__wrapper`}>\n <div className={`${baseClass}__content`}>\n <h1>{t('general:leaveWithoutSaving')}</h1>\n <p>{t('general:changesNotSaved')}</p>\n </div>\n <div className={`${baseClass}__controls`}>\n <Button buttonStyle=\"secondary\" onClick={onCancel}>\n {t('general:stayOnThisPage')}\n </Button>\n <Button onClick={onConfirm}>{t('general:leaveAnyway')}</Button>\n </div>\n </div>\n </Modal>\n )\n}\n\nexport const LeaveWithoutSaving: React.FC = () => {\n const modified = useFormModified()\n const { user } = useAuth()\n const [show, setShow] = React.useState(false)\n const [hasAccepted, setHasAccepted] = React.useState(false)\n\n const prevent = Boolean(modified && user)\n\n const onPrevent = useCallback(() => {\n setShow(true)\n }, [])\n\n usePreventLeave({ hasAccepted, onPrevent, prevent })\n\n return (\n <Component\n isActive={show}\n onCancel={() => {\n setShow(false)\n }}\n onConfirm={() => {\n setHasAccepted(true)\n }}\n />\n )\n}\n"],"names":["Button","Modal","useModal","useFormModified","useAuth","useTranslation","React","useCallback","useEffect","usePreventLeave","modalSlug","baseClass","Component","isActive","onCancel","onConfirm","closeModal","modalState","openModal","t","className","onClose","slug","div","h1","p","buttonStyle","onClick","LeaveWithoutSaving","modified","user","show","setShow","useState","hasAccepted","setHasAccepted","prevent","Boolean","onPrevent"],"mappings":"AAAA;AACA,SAASA,MAAM,QAAQ,iCAAgC;AACvD,SAASC,KAAK,EAAEC,QAAQ,QAAQ,gCAA+B;AAC/D,SAASC,eAAe,QAAQ,4BAA2B;AAC3D,SAASC,OAAO,QAAQ,gCAA+B;AACvD,SAASC,cAAc,QAAQ,uCAAsC;AACrE,OAAOC,SAASC,WAAW,EAAEC,SAAS,QAAQ,QAAO;AAGrD,SAASC,eAAe,QAAQ,uBAAsB;AAEtD,MAAMC,YAAY;AAElB,MAAMC,YAAY;AAElB,MAAMC,YAID,CAAC,EAAEC,QAAQ,EAAEC,QAAQ,EAAEC,SAAS,EAAE;IACrC,MAAM,EAAEC,UAAU,EAAEC,UAAU,EAAEC,SAAS,EAAE,GAAGhB;IAC9C,MAAM,EAAEiB,CAAC,EAAE,GAAGd;IAEd,kFAAkF;IAClF,oBAAoB;IACpB,wDAAwD;IACxD,iBAAiB;IACjB,MAAM;IACN,uCAAuC;IAEvCG,UAAU;QACR,IAAIK,UAAUK,UAAUR;aACnBM,WAAWN;IAClB,GAAG;QAACG;QAAUK;QAAWF;KAAW;IAEpC,qBACE,oBAACf;QAAMmB,WAAWT;QAAWU,SAASP;QAAUQ,MAAMZ;qBACpD,oBAACa;QAAIH,WAAW,CAAC,EAAET,UAAU,SAAS,CAAC;qBACrC,oBAACY;QAAIH,WAAW,CAAC,EAAET,UAAU,SAAS,CAAC;qBACrC,oBAACa,YAAIL,EAAE,8CACP,oBAACM,WAAGN,EAAE,4CAER,oBAACI;QAAIH,WAAW,CAAC,EAAET,UAAU,UAAU,CAAC;qBACtC,oBAACX;QAAO0B,aAAY;QAAYC,SAASb;OACtCK,EAAE,0CAEL,oBAACnB;QAAO2B,SAASZ;OAAYI,EAAE;AAKzC;AAEA,OAAO,MAAMS,qBAA+B;IAC1C,MAAMC,WAAW1B;IACjB,MAAM,EAAE2B,IAAI,EAAE,GAAG1B;IACjB,MAAM,CAAC2B,MAAMC,QAAQ,GAAG1B,MAAM2B,QAAQ,CAAC;IACvC,MAAM,CAACC,aAAaC,eAAe,GAAG7B,MAAM2B,QAAQ,CAAC;IAErD,MAAMG,UAAUC,QAAQR,YAAYC;IAEpC,MAAMQ,YAAY/B,YAAY;QAC5ByB,QAAQ;IACV,GAAG,EAAE;IAELvB,gBAAgB;QAAEyB;QAAaI;QAAWF;IAAQ;IAElD,qBACE,oBAACxB;QACCC,UAAUkB;QACVjB,UAAU;YACRkB,QAAQ;QACV;QACAjB,WAAW;YACToB,eAAe;QACjB;;AAGN,EAAC"}
|
|
@@ -2,26 +2,8 @@
|
|
|
2
2
|
// - Source: https://github.com/vercel/next.js/discussions/32231#discussioncomment-7284386
|
|
3
3
|
// Credit: `react-use` maintainers
|
|
4
4
|
// - Source: https://github.com/streamich/react-use/blob/ade8d3905f544305515d010737b4ae604cc51024/src/useBeforeUnload.ts#L2
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
value: true
|
|
8
|
-
});
|
|
9
|
-
function _export(target, all) {
|
|
10
|
-
for(var name in all)Object.defineProperty(target, name, {
|
|
11
|
-
enumerable: true,
|
|
12
|
-
get: all[name]
|
|
13
|
-
});
|
|
14
|
-
}
|
|
15
|
-
_export(exports, {
|
|
16
|
-
useBeforeUnload: function() {
|
|
17
|
-
return useBeforeUnload;
|
|
18
|
-
},
|
|
19
|
-
usePreventLeave: function() {
|
|
20
|
-
return usePreventLeave;
|
|
21
|
-
}
|
|
22
|
-
});
|
|
23
|
-
const _navigation = require("next/navigation");
|
|
24
|
-
const _react = require("react");
|
|
5
|
+
import { useRouter } from 'next/navigation.js';
|
|
6
|
+
import { useCallback, useEffect, useRef } from 'react';
|
|
25
7
|
function on(obj, ...args) {
|
|
26
8
|
if (obj && obj.addEventListener) {
|
|
27
9
|
obj.addEventListener(...args);
|
|
@@ -32,8 +14,8 @@ function off(obj, ...args) {
|
|
|
32
14
|
obj.removeEventListener(...args);
|
|
33
15
|
}
|
|
34
16
|
}
|
|
35
|
-
const useBeforeUnload = (enabled = true, message)=>{
|
|
36
|
-
const handler =
|
|
17
|
+
export const useBeforeUnload = (enabled = true, message)=>{
|
|
18
|
+
const handler = useCallback((event)=>{
|
|
37
19
|
const finalEnabled = typeof enabled === 'function' ? enabled() : true;
|
|
38
20
|
if (!finalEnabled) {
|
|
39
21
|
return;
|
|
@@ -47,7 +29,7 @@ const useBeforeUnload = (enabled = true, message)=>{
|
|
|
47
29
|
enabled,
|
|
48
30
|
message
|
|
49
31
|
]);
|
|
50
|
-
|
|
32
|
+
useEffect(()=>{
|
|
51
33
|
if (!enabled) {
|
|
52
34
|
return;
|
|
53
35
|
}
|
|
@@ -58,13 +40,13 @@ const useBeforeUnload = (enabled = true, message)=>{
|
|
|
58
40
|
handler
|
|
59
41
|
]);
|
|
60
42
|
};
|
|
61
|
-
const usePreventLeave = ({ hasAccepted = false, message = 'Are you sure want to leave this page?', onPrevent, prevent = true })=>{
|
|
43
|
+
export const usePreventLeave = ({ hasAccepted = false, message = 'Are you sure want to leave this page?', onPrevent, prevent = true })=>{
|
|
62
44
|
// check when page is about to be reloaded
|
|
63
45
|
useBeforeUnload(prevent, message);
|
|
64
|
-
const router =
|
|
65
|
-
const cancelledURL =
|
|
46
|
+
const router = useRouter();
|
|
47
|
+
const cancelledURL = useRef('');
|
|
66
48
|
// check when page is about to be changed
|
|
67
|
-
|
|
49
|
+
useEffect(()=>{
|
|
68
50
|
function isAnchorOfCurrentUrl(currentUrl, newUrl) {
|
|
69
51
|
const currentUrlObj = new URL(currentUrl);
|
|
70
52
|
const newUrlObj = new URL(newUrl);
|
|
@@ -119,7 +101,7 @@ const usePreventLeave = ({ hasAccepted = false, message = 'Are you sure want to
|
|
|
119
101
|
prevent,
|
|
120
102
|
message
|
|
121
103
|
]);
|
|
122
|
-
|
|
104
|
+
useEffect(()=>{
|
|
123
105
|
if (hasAccepted && cancelledURL.current) {
|
|
124
106
|
router.push(cancelledURL.current);
|
|
125
107
|
}
|
|
@@ -129,4 +111,4 @@ const usePreventLeave = ({ hasAccepted = false, message = 'Are you sure want to
|
|
|
129
111
|
]);
|
|
130
112
|
};
|
|
131
113
|
|
|
132
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy9lbGVtZW50cy9MZWF2ZVdpdGhvdXRTYXZpbmcvdXNlUHJldmVudExlYXZlLnRzeCJdLCJzb3VyY2VzQ29udGVudCI6WyIvLyBDcmVkaXQ6IEBUYWlraTkyNzc3XG4vLyAgICAtIFNvdXJjZTogaHR0cHM6Ly9naXRodWIuY29tL3ZlcmNlbC9uZXh0LmpzL2Rpc2N1c3Npb25zLzMyMjMxI2Rpc2N1c3Npb25jb21tZW50LTcyODQzODZcbi8vIENyZWRpdDogYHJlYWN0LXVzZWAgbWFpbnRhaW5lcnNcbi8vICAgIC0gIFNvdXJjZTogaHR0cHM6Ly9naXRodWIuY29tL3N0cmVhbWljaC9yZWFjdC11c2UvYmxvYi9hZGU4ZDM5MDVmNTQ0MzA1NTE1ZDAxMDczN2I0YWU2MDRjYzUxMDI0L3NyYy91c2VCZWZvcmVVbmxvYWQudHMjTDJcbmltcG9ydCB7IHVzZVJvdXRlciB9IGZyb20gJ25leHQvbmF2aWdhdGlvbidcbmltcG9ydCB7IHVzZUNhbGxiYWNrLCB1c2VFZmZlY3QsIHVzZVJlZiB9IGZyb20gJ3JlYWN0J1xuXG5mdW5jdGlvbiBvbjxUIGV4dGVuZHMgRG9jdW1lbnQgfCBFdmVudFRhcmdldCB8IEhUTUxFbGVtZW50IHwgV2luZG93PihcbiAgb2JqOiBUIHwgbnVsbCxcbiAg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gICAgY3VycmVudEhhc2ggIT09IG5ld0hhc2ggJiZcbiAgICAgICAgICBjdXJyZW50VXJsT2JqLmhyZWYucmVwbGFjZShjdXJyZW50SGFzaCwgJycpID09PSBuZXdVcmxPYmouaHJlZi5yZXBsYWNlKG5ld0hhc2gsICcnKVxuICAgICAgICApXG4gICAgICB9XG4gICAgICByZXR1cm4gZmFsc2VcbiAgICB9XG5cbiAgICBmdW5jdGlvbiBmaW5kQ2xvc2VzdEFuY2hvcihlbGVtZW50OiBIVE1MRWxlbWVudCB8IG51bGwpOiBIVE1MQW5jaG9yRWxlbWVudCB8IG51bGwge1xuICAgICAgd2hpbGUgKGVsZW1lbnQgJiYgZWxlbWVudC50YWdOYW1lLnRvTG93ZXJDYXNlKCkgIT09ICdhJykge1xuICAgICAgICBlbGVtZW50ID0gZWxlbWVudC5wYXJlbnRFbGVtZW50XG4gICAgICB9XG4gICAgICByZXR1cm4gZWxlbWVudCBhcyBIVE1MQW5jaG9yRWxlbWVudFxuICAgIH1cbiAgICBmdW5jdGlvbiBoYW5kbGVDbGljayhldmVudDogTW91c2VFdmVudCkge1xuICAgICAgdHJ5IHtcbiAgICAgICAgY29uc3QgdGFyZ2V0ID0gZXZlbnQudGFyZ2V0IGFzIEhUTUxFbGVtZW50XG4gICAgICAgIGNvbnN0IGFuY2hvciA9IGZpbmRDbG9zZXN0QW5jaG9yKHRhcmdldClcbiAgICAgICAgaWYgKGFuY2hvcikge1xuICAgICAgICAgIGNvbnN0IGN1cnJlbnRVcmwgPSB3aW5kb3cubG9jYXRpb24uaHJlZlxuICAgICAgICAgIGNvbnN0IG5ld1VybCA9IGFuY2hvci5ocmVmXG4gICAgICAgICAgY29uc3QgaXNBbmNob3IgPSBpc0FuY2hvck9mQ3VycmVudFVybChjdXJyZW50VXJsLCBuZXdVcmwpXG4gICAgICAgICAgY29uc3QgaXNEb3dubG9hZExpbmsgPSBhbmNob3IuZG93bmxvYWQgIT09ICcnXG5cbiAgICAgICAgICBjb25zdCBp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R0FBRztRQUFDekI7UUFBV0M7UUFBU1g7S0FBUTtJQUVoQ08sSUFBQUEsZ0JBQVMsRUFBQztRQUNSLElBQUlFLGVBQWVLLGFBQWE4QixPQUFPLEVBQUU7WUFDdkNoQyxPQUFPcUMsSUFBSSxDQUFDbkMsYUFBYThCLE9BQU87UUFDbEM7SUFDRixHQUFHO1FBQUNuQztRQUFhRztLQUFPO0FBQzFCIn0=
|
|
114
|
+
//# sourceMappingURL=usePreventLeave.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/elements/LeaveWithoutSaving/usePreventLeave.tsx"],"sourcesContent":["// Credit: @Taiki92777\n// - Source: https://github.com/vercel/next.js/discussions/32231#discussioncomment-7284386\n// Credit: `react-use` maintainers\n// - Source: https://github.com/streamich/react-use/blob/ade8d3905f544305515d010737b4ae604cc51024/src/useBeforeUnload.ts#L2\nimport { useRouter } from 'next/navigation.js'\nimport { useCallback, useEffect, useRef } from 'react'\n\nfunction on<T extends Document | EventTarget | HTMLElement | Window>(\n obj: T | null,\n ...args: [string, Function | null, ...any] | Parameters<T['addEventListener']>\n): void {\n if (obj && obj.addEventListener) {\n obj.addEventListener(...(args as Parameters<HTMLElement['addEventListener']>))\n }\n}\n\nfunction off<T extends Document | EventTarget | HTMLElement | Window>(\n obj: T | null,\n ...args: [string, Function | null, ...any] | Parameters<T['removeEventListener']>\n): void {\n if (obj && obj.removeEventListener) {\n obj.removeEventListener(...(args as Parameters<HTMLElement['removeEventListener']>))\n }\n}\n\nexport const useBeforeUnload = (enabled: (() => boolean) | boolean = true, message?: string) => {\n const handler = useCallback(\n (event: BeforeUnloadEvent) => {\n const finalEnabled = typeof enabled === 'function' ? enabled() : true\n\n if (!finalEnabled) {\n return\n }\n\n event.preventDefault()\n\n if (message) {\n event.returnValue = message\n }\n\n return message\n },\n [enabled, message],\n )\n\n useEffect(() => {\n if (!enabled) {\n return\n }\n\n on(window, 'beforeunload', handler)\n\n return () => off(window, 'beforeunload', handler)\n }, [enabled, handler])\n}\n\nexport const usePreventLeave = ({\n hasAccepted = false,\n message = 'Are you sure want to leave this page?',\n onPrevent,\n prevent = true,\n}: {\n hasAccepted: boolean\n // if no `onPrevent` is provided, the message will be displayed in a confirm dialog\n message?: string\n // to use a custom confirmation dialog, provide a function that returns a boolean\n onPrevent?: () => void\n prevent: boolean\n}) => {\n // check when page is about to be reloaded\n useBeforeUnload(prevent, message)\n\n const router = useRouter()\n const cancelledURL = useRef<string>('')\n\n // check when page is about to be changed\n useEffect(() => {\n function isAnchorOfCurrentUrl(currentUrl: string, newUrl: string) {\n const currentUrlObj = new URL(currentUrl)\n const newUrlObj = new URL(newUrl)\n // Compare hostname, pathname, and search parameters\n if (\n currentUrlObj.hostname === newUrlObj.hostname &&\n currentUrlObj.pathname === newUrlObj.pathname &&\n currentUrlObj.search === newUrlObj.search\n ) {\n // Check if the new URL is just an anchor of the current URL page\n const currentHash = currentUrlObj.hash\n const newHash = newUrlObj.hash\n return (\n currentHash !== newHash &&\n currentUrlObj.href.replace(currentHash, '') === newUrlObj.href.replace(newHash, '')\n )\n }\n return false\n }\n\n function findClosestAnchor(element: HTMLElement | null): HTMLAnchorElement | null {\n while (element && element.tagName.toLowerCase() !== 'a') {\n element = element.parentElement\n }\n return element as HTMLAnchorElement\n }\n function handleClick(event: MouseEvent) {\n try {\n const target = event.target as HTMLElement\n const anchor = findClosestAnchor(target)\n if (anchor) {\n const currentUrl = window.location.href\n const newUrl = anchor.href\n const isAnchor = isAnchorOfCurrentUrl(currentUrl, newUrl)\n const isDownloadLink = anchor.download !== ''\n\n const isPageLeaving = !(newUrl === currentUrl || isAnchor || isDownloadLink)\n\n if (isPageLeaving && prevent && (!onPrevent ? !window.confirm(message) : true)) {\n // Keep a reference of the href\n cancelledURL.current = newUrl\n\n // Cancel the route change\n event.preventDefault()\n event.stopPropagation()\n\n if (typeof onPrevent === 'function') {\n onPrevent()\n }\n }\n }\n } catch (err) {\n alert(err)\n }\n }\n\n // Add the global click event listener\n document.addEventListener('click', handleClick, true)\n\n // Clean up the global click event listener when the component is unmounted\n return () => {\n document.removeEventListener('click', handleClick, true)\n }\n }, [onPrevent, prevent, message])\n\n useEffect(() => {\n if (hasAccepted && cancelledURL.current) {\n router.push(cancelledURL.current)\n }\n }, [hasAccepted, router])\n}\n"],"names":["useRouter","useCallback","useEffect","useRef","on","obj","args","addEventListener","off","removeEventListener","useBeforeUnload","enabled","message","handler","event","finalEnabled","preventDefault","returnValue","window","usePreventLeave","hasAccepted","onPrevent","prevent","router","cancelledURL","isAnchorOfCurrentUrl","currentUrl","newUrl","currentUrlObj","URL","newUrlObj","hostname","pathname","search","currentHash","hash","newHash","href","replace","findClosestAnchor","element","tagName","toLowerCase","parentElement","handleClick","target","anchor","location","isAnchor","isDownloadLink","download","isPageLeaving","confirm","current","stopPropagation","err","alert","document","push"],"mappings":"AAAA,sBAAsB;AACtB,6FAA6F;AAC7F,kCAAkC;AAClC,+HAA+H;AAC/H,SAASA,SAAS,QAAQ,qBAAoB;AAC9C,SAASC,WAAW,EAAEC,SAAS,EAAEC,MAAM,QAAQ,QAAO;AAEtD,SAASC,GACPC,GAAa,EACb,GAAGC,IAA2E;IAE9E,IAAID,OAAOA,IAAIE,gBAAgB,EAAE;QAC/BF,IAAIE,gBAAgB,IAAKD;IAC3B;AACF;AAEA,SAASE,IACPH,GAAa,EACb,GAAGC,IAA8E;IAEjF,IAAID,OAAOA,IAAII,mBAAmB,EAAE;QAClCJ,IAAII,mBAAmB,IAAKH;IAC9B;AACF;AAEA,OAAO,MAAMI,kBAAkB,CAACC,UAAqC,IAAI,EAAEC;IACzE,MAAMC,UAAUZ,YACd,CAACa;QACC,MAAMC,eAAe,OAAOJ,YAAY,aAAaA,YAAY;QAEjE,IAAI,CAACI,cAAc;YACjB;QACF;QAEAD,MAAME,cAAc;QAEpB,IAAIJ,SAAS;YACXE,MAAMG,WAAW,GAAGL;QACtB;QAEA,OAAOA;IACT,GACA;QAACD;QAASC;KAA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OT,IAAI;oBAC1B,MAAMW,WAAWvB,qBAAqBC,YAAYC;oBAClD,MAAMsB,iBAAiBH,OAAOI,QAAQ,KAAK;oBAE3C,MAAMC,gBAAgB,CAAExB,CAAAA,WAAWD,cAAcsB,YAAYC,cAAa;oBAE1E,IAAIE,iBAAiB7B,WAAY,CAAA,CAACD,YAAY,CAACH,OAAOkC,OAAO,CAACxC,WAAW,IAAG,GAAI;wBAC9E,+BAA+B;wBAC/BY,aAAa6B,OAAO,GAAG1B;wBAEvB,0BAA0B;wBAC1Bb,MAAME,cAAc;wBACpBF,MAAMwC,eAAe;wBAErB,IAAI,OAAOjC,cAAc,YAAY;4BACnCA;wBACF;oBACF;gBACF;YACF,EAAE,OAAOkC,KAAK;gBACZC,MAAMD;YACR;QACF;QAEA,sCAAsC;QACtCE,SAASlD,gBAAgB,CAAC,SAASqC,aAAa;QAEhD,2EAA2E;QAC3E,OAAO;YACLa,SAAShD,mBAAmB,CAAC,SAASmC,aAAa;QACrD;IACF,GAAG;QAACvB;QAAWC;QAASV;KAAQ;IAEhCV,UAAU;QACR,IAAIkB,eAAeI,aAAa6B,OAAO,EAAE;YACvC9B,OAAOmC,IAAI,CAAClC,aAAa6B,OAAO;QAClC;IACF,GAAG;QAACjC;QAAaG;KAAO;AAC1B,EAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"layouts.d.ts","sourceRoot":"","sources":["../../src/exports/layouts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/exports/layouts.ts"],"sourcesContent":["export { RootLayout, metadata } from '../layouts/Root/index.js'\n"],"names":["RootLayout","metadata"],"mappings":"AAAA,SAASA,UAAU,EAAEC,QAAQ,QAAQ,2BAA0B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"routes.d.ts","sourceRoot":"","sources":["../../src/exports/routes.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAA;AAEjF,OAAO,EACL,MAAM,IAAI,WAAW,EACrB,GAAG,IAAI,QAAQ,EACf,KAAK,IAAI,UAAU,EACnB,IAAI,IAAI,SAAS,GAClB,MAAM,yBAAyB,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/exports/routes.ts"],"sourcesContent":["export { GRAPHQL_PLAYGROUND_GET, GRAPHQL_POST } from '../routes/graphql/index.js'\n\nexport {\n DELETE as REST_DELETE,\n GET as REST_GET,\n PATCH as REST_PATCH,\n POST as REST_POST,\n} from '../routes/rest/index.js'\n"],"names":["GRAPHQL_PLAYGROUND_GET","GRAPHQL_POST","DELETE","REST_DELETE","GET","REST_GET","PATCH","REST_PATCH","POST","REST_POST"],"mappings":"AAAA,SAASA,sBAAsB,EAAEC,YAAY,QAAQ,6BAA4B;AAEjF,SACEC,UAAUC,WAAW,EACrBC,OAAOC,QAAQ,EACfC,SAASC,UAAU,EACnBC,QAAQC,SAAS,QACZ,0BAAyB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utilities.d.ts","sourceRoot":"","sources":["../../src/exports/utilities.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/exports/utilities.ts"],"sourcesContent":["export { getPayloadHMR } from '../utilities/getPayloadHMR.js'\n"],"names":["getPayloadHMR"],"mappings":"AAAA,SAASA,aAAa,QAAQ,gCAA+B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"views.d.ts","sourceRoot":"","sources":["../../src/exports/views.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAA;AACjD,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAA;AACzD,OAAO,EAAE,KAAK,oBAAoB,EAAE,QAAQ,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/exports/views.ts"],"sourcesContent":["export { EditView } from '../views/Edit/index.js'\nexport { NotFoundPage } from '../views/NotFound/index.js'\nexport { type GenerateViewMetadata, RootPage, generatePageMetadata } from '../views/Root/index.js'\n"],"names":["EditView","NotFoundPage","RootPage","generatePageMetadata"],"mappings":"AAAA,SAASA,QAAQ,QAAQ,yBAAwB;AACjD,SAASC,YAAY,QAAQ,6BAA4B;AACzD,SAAoCC,QAAQ,EAAEC,oBAAoB,QAAQ,yBAAwB"}
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
"use strict";
|
|
1
|
+
export { default as withPayload } from './withPayload.js';
|
|
3
2
|
|
|
4
|
-
//# sourceMappingURL=
|
|
3
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/index.js"],"sourcesContent":["export { default as withPayload } from './withPayload.js'\n"],"names":["default","withPayload"],"mappings":"AAAA,SAASA,WAAWC,WAAW,QAAQ,mBAAkB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/layouts/Root/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/layouts/Root/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAA;AAIpD,OAAO,8BAA8B,CAAA;AAMrC,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,uCAAuC,CAAA;AAM9C,eAAO,MAAM,QAAQ;;;CAGpB,CAAA;AAID,eAAO,MAAM,UAAU;cAIX,MAAM,SAAS;YACjB,QAAQ,eAAe,CAAC;gCA4DjC,CAAA"}
|
|
@@ -1,40 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
return RootLayout;
|
|
14
|
-
},
|
|
15
|
-
metadata: function() {
|
|
16
|
-
return metadata;
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
const _auth = require("@payloadcms/next/utilities/auth");
|
|
20
|
-
const _client = require("@payloadcms/translations/client");
|
|
21
|
-
const _ui = require("@payloadcms/ui");
|
|
22
|
-
require("@payloadcms/ui/scss/app.scss");
|
|
23
|
-
const _headers = require("next/headers");
|
|
24
|
-
const _config = require("payload/config");
|
|
25
|
-
const _utilities = require("payload/utilities");
|
|
26
|
-
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
27
|
-
require("react-toastify/dist/ReactToastify.css");
|
|
28
|
-
const _Default = require("../../pages/Edit/Default");
|
|
29
|
-
const _Default1 = require("../../pages/List/Default");
|
|
30
|
-
const _Cell = require("../../pages/List/Default/Cell");
|
|
31
|
-
const _getRequestLanguage = require("../../utilities/getRequestLanguage");
|
|
32
|
-
function _interop_require_default(obj) {
|
|
33
|
-
return obj && obj.__esModule ? obj : {
|
|
34
|
-
default: obj
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
|
-
const metadata = {
|
|
1
|
+
import { translations } from '@payloadcms/translations/client';
|
|
2
|
+
import { RootProvider } from '@payloadcms/ui/providers/Root';
|
|
3
|
+
import { buildComponentMap } from '@payloadcms/ui/utilities/buildComponentMap';
|
|
4
|
+
import { headers as getHeaders, cookies as nextCookies } from 'next/headers.js';
|
|
5
|
+
import { parseCookies } from 'payload/auth';
|
|
6
|
+
import { createClientConfig } from 'payload/config';
|
|
7
|
+
import { deepMerge } from 'payload/utilities';
|
|
8
|
+
import React from 'react';
|
|
9
|
+
import { getRequestLanguage } from '../../utilities/getRequestLanguage.js';
|
|
10
|
+
import { DefaultEditView } from '../../views/Edit/Default/index.js';
|
|
11
|
+
import { DefaultListView } from '../../views/List/Default/index.js';
|
|
12
|
+
export const metadata = {
|
|
38
13
|
description: 'Generated by Next.js',
|
|
39
14
|
title: 'Next.js'
|
|
40
15
|
};
|
|
@@ -51,43 +26,52 @@ const rtlLanguages = [
|
|
|
51
26
|
'he',
|
|
52
27
|
'yi'
|
|
53
28
|
];
|
|
54
|
-
const RootLayout = async ({ children, config: configPromise })=>{
|
|
29
|
+
export const RootLayout = async ({ children, config: configPromise })=>{
|
|
55
30
|
const config = await configPromise;
|
|
56
|
-
const clientConfig = await
|
|
57
|
-
const headers = (
|
|
58
|
-
const
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
});
|
|
62
|
-
const lang = (0, _getRequestLanguage.getRequestLanguage)({
|
|
31
|
+
const clientConfig = await createClientConfig(config);
|
|
32
|
+
const headers = getHeaders();
|
|
33
|
+
const cookies = parseCookies(headers);
|
|
34
|
+
const lang = getRequestLanguage({
|
|
35
|
+
config,
|
|
63
36
|
cookies,
|
|
64
37
|
headers
|
|
65
38
|
}) ?? clientConfig.i18n.fallbackLanguage;
|
|
66
39
|
const dir = rtlLanguages.includes(lang) ? 'RTL' : 'LTR';
|
|
67
|
-
const mergedTranslations =
|
|
68
|
-
const languageOptions = Object.entries(
|
|
40
|
+
const mergedTranslations = deepMerge(translations, clientConfig.i18n.translations);
|
|
41
|
+
const languageOptions = Object.entries(translations || {}).map(([language, translations])=>({
|
|
69
42
|
label: translations.general.thisLanguage,
|
|
70
43
|
value: language
|
|
71
44
|
}));
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
45
|
+
// eslint-disable-next-line @typescript-eslint/require-await
|
|
46
|
+
async function switchLanguageServerAction(lang) {
|
|
47
|
+
'use server';
|
|
48
|
+
nextCookies().set({
|
|
49
|
+
name: `${config.cookiePrefix || 'payload'}-lng'`,
|
|
50
|
+
path: '/',
|
|
51
|
+
value: lang
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
const { componentMap, wrappedChildren } = buildComponentMap({
|
|
55
|
+
DefaultEditView,
|
|
56
|
+
DefaultListView,
|
|
57
|
+
children,
|
|
76
58
|
config
|
|
77
59
|
});
|
|
78
|
-
return /*#__PURE__*/
|
|
60
|
+
return /*#__PURE__*/ React.createElement("html", {
|
|
79
61
|
dir: dir,
|
|
80
62
|
lang: lang
|
|
81
|
-
}, /*#__PURE__*/
|
|
63
|
+
}, /*#__PURE__*/ React.createElement("body", null, /*#__PURE__*/ React.createElement(RootProvider, {
|
|
82
64
|
componentMap: componentMap,
|
|
83
65
|
config: clientConfig,
|
|
84
66
|
fallbackLang: clientConfig.i18n.fallbackLanguage,
|
|
85
67
|
lang: lang,
|
|
86
68
|
languageOptions: languageOptions,
|
|
69
|
+
// eslint-disable-next-line react/jsx-no-bind
|
|
70
|
+
switchLanguageServerAction: switchLanguageServerAction,
|
|
87
71
|
translations: mergedTranslations[lang]
|
|
88
|
-
},
|
|
72
|
+
}, wrappedChildren), /*#__PURE__*/ React.createElement("div", {
|
|
89
73
|
id: "portal"
|
|
90
74
|
})));
|
|
91
75
|
};
|
|
92
76
|
|
|
93
|
-
//# sourceMappingURL=
|
|
77
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/layouts/Root/index.tsx"],"sourcesContent":["import type { SanitizedConfig } from 'payload/types'\n\nimport { translations } from '@payloadcms/translations/client'\nimport { RootProvider } from '@payloadcms/ui/providers/Root'\nimport '@payloadcms/ui/scss/app.scss'\nimport { buildComponentMap } from '@payloadcms/ui/utilities/buildComponentMap'\nimport { headers as getHeaders, cookies as nextCookies } from 'next/headers.js'\nimport { parseCookies } from 'payload/auth'\nimport { createClientConfig } from 'payload/config'\nimport { deepMerge } from 'payload/utilities'\nimport React from 'react'\nimport 'react-toastify/dist/ReactToastify.css'\n\nimport { getRequestLanguage } from '../../utilities/getRequestLanguage.js'\nimport { DefaultEditView } from '../../views/Edit/Default/index.js'\nimport { DefaultListView } from '../../views/List/Default/index.js'\n\nexport const metadata = {\n description: 'Generated by Next.js',\n title: 'Next.js',\n}\n\nconst rtlLanguages = ['ar', 'fa', 'ha', 'ku', 'ur', 'ps', 'dv', 'ks', 'khw', 'he', 'yi']\n\nexport const RootLayout = async ({\n children,\n config: configPromise,\n}: {\n children: React.ReactNode\n config: Promise<SanitizedConfig>\n}) => {\n const config = await configPromise\n const clientConfig = await createClientConfig(config)\n\n const headers = getHeaders()\n const cookies = parseCookies(headers)\n\n const lang =\n getRequestLanguage({\n config,\n cookies,\n headers,\n }) ?? clientConfig.i18n.fallbackLanguage\n\n const dir = rtlLanguages.includes(lang) ? 'RTL' : 'LTR'\n\n const mergedTranslations = deepMerge(translations, clientConfig.i18n.translations)\n\n const languageOptions = Object.entries(translations || {}).map(([language, translations]) => ({\n label: translations.general.thisLanguage,\n value: language,\n }))\n\n // eslint-disable-next-line @typescript-eslint/require-await\n async function switchLanguageServerAction(lang: string): Promise<void> {\n 'use server'\n nextCookies().set({\n name: `${config.cookiePrefix || 'payload'}-lng'`,\n path: '/',\n value: lang,\n })\n }\n\n const { componentMap, wrappedChildren } = buildComponentMap({\n DefaultEditView,\n DefaultListView,\n children,\n config,\n })\n\n return (\n <html dir={dir} lang={lang}>\n <body>\n <RootProvider\n componentMap={componentMap}\n config={clientConfig}\n fallbackLang={clientConfig.i18n.fallbackLanguage}\n lang={lang}\n languageOptions={languageOptions}\n // eslint-disable-next-line react/jsx-no-bind\n switchLanguageServerAction={switchLanguageServerAction}\n translations={mergedTranslations[lang]}\n >\n {wrappedChildren}\n </RootProvider>\n <div id=\"portal\" />\n </body>\n </html>\n )\n}\n"],"names":["translations","RootProvider","buildComponentMap","headers","getHeaders","cookies","nextCookies","parseCookies","createClientConfig","deepMerge","React","getRequestLanguage","DefaultEditView","DefaultListView","metadata","description","title","rtlLanguages","RootLayout","children","config","configPromise","clientConfig","lang","i18n","fallbackLanguage","dir","includes","mergedTranslations","languageOptions","Object","entries","map","language","label","general","thisLanguage","value","switchLanguageServerAction","set","name","cookiePrefix","path","componentMap","wrappedChildren","html","body","fallbackLang","div","id"],"mappings":"AAEA,SAASA,YAAY,QAAQ,kCAAiC;AAC9D,SAASC,YAAY,QAAQ,gCAA+B;AAE5D,SAASC,iBAAiB,QAAQ,6CAA4C;AAC9E,SAASC,WAAWC,UAAU,EAAEC,WAAWC,WAAW,QAAQ,kBAAiB;AAC/E,SAASC,YAAY,QAAQ,eAAc;AAC3C,SAASC,kBAAkB,QAAQ,iBAAgB;AACnD,SAASC,SAAS,QAAQ,oBAAmB;AAC7C,OAAOC,WAAW,QAAO;AAGzB,SAASC,kBAAkB,QAAQ,wCAAuC;AAC1E,SAASC,eAAe,QAAQ,oCAAmC;AACnE,SAASC,eAAe,QAAQ,oCAAmC;AAEnE,OAAO,MAAMC,WAAW;IACtBC,aAAa;IACbC,OAAO;AACT,EAAC;AAED,MAAMC,eAAe;IAAC;IAAM;IAAM;IAAM;IAAM;IAAM;IAAM;IAAM;IAAM;IAAO;IAAM;CAAK;AAExF,OAAO,MAAMC,aAAa,OAAO,EAC/BC,QAAQ,EACRC,QAAQC,aAAa,EAItB;IACC,MAAMD,SAAS,MAAMC;IACrB,MAAMC,eAAe,MAAMd,mBAAmBY;IAE9C,MAAMjB,UAAUC;IAChB,MAAMC,UAAUE,aAAaJ;IAE7B,MAAMoB,OACJZ,mBAAmB;QACjBS;QACAf;QACAF;IACF,MAAMmB,aAAaE,IAAI,CAACC,gBAAgB;IAE1C,MAAMC,MAAMT,aAAaU,QAAQ,CAACJ,QAAQ,QAAQ;IAElD,MAAMK,qBAAqBnB,UAAUT,cAAcsB,aAAaE,IAAI,CAACxB,YAAY;IAEjF,MAAM6B,kBAAkBC,OAAOC,OAAO,CAAC/B,gBAAgB,CAAC,GAAGgC,GAAG,CAAC,CAAC,CAACC,UAAUjC,aAAa,GAAM,CAAA;YAC5FkC,OAAOlC,aAAamC,OAAO,CAACC,YAAY;YACxCC,OAAOJ;QACT,CAAA;IAEA,4DAA4D;IAC5D,eAAeK,2BAA2Bf,IAAY;QACpD;QACAjB,cAAciC,GAAG,CAAC;YAChBC,MAAM,CAAC,EAAEpB,OAAOqB,YAAY,IAAI,UAAU,KAAK,CAAC;YAChDC,MAAM;YACNL,OAAOd;QACT;IACF;IAEA,MAAM,EAAEoB,YAAY,EAAEC,eAAe,EAAE,GAAG1C,kBAAkB;QAC1DU;QACAC;QACAM;QACAC;IACF;IAEA,qBACE,oBAACyB;QAAKnB,KAAKA;QAAKH,MAAMA;qBACpB,oBAACuB,4BACC,oBAAC7C;QACC0C,cAAcA;QACdvB,QAAQE;QACRyB,cAAczB,aAAaE,IAAI,CAACC,gBAAgB;QAChDF,MAAMA;QACNM,iBAAiBA;QACjB,6CAA6C;QAC7CS,4BAA4BA;QAC5BtC,cAAc4B,kBAAkB,CAACL,KAAK;OAErCqB,gCAEH,oBAACI;QAAIC,IAAG;;AAIhB,EAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
import type { FileShape, NextFileUploadOptions } from '.';
|
|
1
|
+
/// <reference types="node" resolution-mode="require"/>
|
|
2
|
+
import type { FileShape, NextFileUploadOptions } from './index.js';
|
|
3
3
|
type FileFactoryOptions = {
|
|
4
4
|
buffer: Buffer;
|
|
5
5
|
encoding: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fileFactory.d.ts","sourceRoot":"","sources":["../../src/next-fileupload/fileFactory.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,qBAAqB,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"fileFactory.d.ts","sourceRoot":"","sources":["../../src/next-fileupload/fileFactory.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,qBAAqB,EAAE,MAAM,YAAY,CAAA;AAmClE,KAAK,kBAAkB,GAAG;IACxB,MAAM,EAAE,MAAM,CAAA;IACd,QAAQ,EAAE,MAAM,CAAA;IAChB,IAAI,EAAE,MAAM,GAAG,MAAM,CAAA;IACrB,QAAQ,EAAE,MAAM,CAAA;IAChB,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,MAAM,CAAA;IACZ,YAAY,EAAE,MAAM,CAAA;IACpB,SAAS,EAAE,OAAO,CAAA;CACnB,CAAA;AACD,KAAK,WAAW,GAAG,CACjB,OAAO,EAAE,kBAAkB,EAC3B,iBAAiB,EAAE,qBAAqB,KACrC,SAAS,CAAA;AACd,eAAO,MAAM,WAAW,EAAE,WA4BzB,CAAA"}
|