@payloadcms/next 3.0.0-alpha.0
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/bin/index.d.ts +2 -0
- package/dist/bin/index.d.ts.map +1 -0
- package/dist/bin/index.js +37 -0
- package/dist/bin/install.d.ts +4 -0
- package/dist/bin/install.d.ts.map +1 -0
- package/dist/bin/install.js +77 -0
- package/dist/config.d.ts +4 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +13 -0
- package/dist/elements/LeaveWithoutSaving/index.d.ts +4 -0
- package/dist/elements/LeaveWithoutSaving/index.d.ts.map +1 -0
- package/dist/elements/LeaveWithoutSaving/index.js +122 -0
- package/dist/elements/LeaveWithoutSaving/index.scss +36 -0
- package/dist/elements/LeaveWithoutSaving/usePreventLeave.d.ts +8 -0
- package/dist/elements/LeaveWithoutSaving/usePreventLeave.d.ts.map +1 -0
- package/dist/elements/LeaveWithoutSaving/usePreventLeave.js +132 -0
- package/dist/exports/index.d.ts +2 -0
- package/dist/exports/index.d.ts.map +1 -0
- package/dist/exports/index.js +13 -0
- package/dist/graphql/registerSchema.d.ts +2 -0
- package/dist/graphql/registerSchema.d.ts.map +1 -0
- package/dist/graphql/registerSchema.js +3 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +4 -0
- package/dist/layouts/Admin/index.d.ts +12 -0
- package/dist/layouts/Admin/index.d.ts.map +1 -0
- package/dist/layouts/Admin/index.js +44 -0
- package/dist/layouts/Document/index.d.ts +14 -0
- package/dist/layouts/Document/index.d.ts.map +1 -0
- package/dist/layouts/Document/index.js +82 -0
- package/dist/layouts/Root/index.d.ts +12 -0
- package/dist/layouts/Root/index.d.ts.map +1 -0
- package/dist/layouts/Root/index.js +92 -0
- package/dist/next-fileupload/fileFactory.d.ts +16 -0
- package/dist/next-fileupload/fileFactory.d.ts.map +1 -0
- package/dist/next-fileupload/fileFactory.js +53 -0
- package/dist/next-fileupload/handlers.d.ts +15 -0
- package/dist/next-fileupload/handlers.d.ts.map +1 -0
- package/dist/next-fileupload/handlers.js +150 -0
- package/dist/next-fileupload/index.d.ts +135 -0
- package/dist/next-fileupload/index.d.ts.map +1 -0
- package/dist/next-fileupload/index.js +58 -0
- package/dist/next-fileupload/isEligibleRequest.d.ts +2 -0
- package/dist/next-fileupload/isEligibleRequest.d.ts.map +1 -0
- package/dist/next-fileupload/isEligibleRequest.js +36 -0
- package/dist/next-fileupload/processMultipart.d.ts +8 -0
- package/dist/next-fileupload/processMultipart.d.ts.map +1 -0
- package/dist/next-fileupload/processMultipart.js +146 -0
- package/dist/next-fileupload/processNested.d.ts +2 -0
- package/dist/next-fileupload/processNested.d.ts.map +1 -0
- package/dist/next-fileupload/processNested.js +34 -0
- package/dist/next-fileupload/uploadTimer.d.ts +7 -0
- package/dist/next-fileupload/uploadTimer.d.ts.map +1 -0
- package/dist/next-fileupload/uploadTimer.js +29 -0
- package/dist/next-fileupload/utilities.d.ts +65 -0
- package/dist/next-fileupload/utilities.d.ts.map +1 -0
- package/dist/next-fileupload/utilities.js +252 -0
- package/dist/next-stream-file/index.d.ts +2 -0
- package/dist/next-stream-file/index.d.ts.map +1 -0
- package/dist/next-stream-file/index.js +40 -0
- package/dist/pages/API/RenderJSON/index.d.ts +12 -0
- package/dist/pages/API/RenderJSON/index.d.ts.map +1 -0
- package/dist/pages/API/RenderJSON/index.js +142 -0
- package/dist/pages/API/RenderJSON/index.scss +90 -0
- package/dist/pages/API/index.client.d.ts +5 -0
- package/dist/pages/API/index.client.d.ts.map +1 -0
- package/dist/pages/API/index.client.js +241 -0
- package/dist/pages/API/index.d.ts +4 -0
- package/dist/pages/API/index.d.ts.map +1 -0
- package/dist/pages/API/index.js +27 -0
- package/dist/pages/API/index.scss +124 -0
- package/dist/pages/API/meta.d.ts +3 -0
- package/dist/pages/API/meta.d.ts.map +1 -0
- package/dist/pages/API/meta.js +21 -0
- package/dist/pages/Account/Settings/index.d.ts +6 -0
- package/dist/pages/Account/Settings/index.d.ts.map +1 -0
- package/dist/pages/Account/Settings/index.js +45 -0
- package/dist/pages/Account/Settings/index.scss +46 -0
- package/dist/pages/Account/ToggleTheme/index.d.ts +3 -0
- package/dist/pages/Account/ToggleTheme/index.d.ts.map +1 -0
- package/dist/pages/Account/ToggleTheme/index.js +87 -0
- package/dist/pages/Account/index.d.ts +13 -0
- package/dist/pages/Account/index.d.ts.map +1 -0
- package/dist/pages/Account/index.js +171 -0
- package/dist/pages/CreateFirstUser/index.client.d.ts +5 -0
- package/dist/pages/CreateFirstUser/index.client.d.ts.map +1 -0
- package/dist/pages/CreateFirstUser/index.client.js +29 -0
- package/dist/pages/CreateFirstUser/index.d.ts +11 -0
- package/dist/pages/CreateFirstUser/index.d.ts.map +1 -0
- package/dist/pages/CreateFirstUser/index.js +91 -0
- package/dist/pages/CreateFirstUser/index.scss +15 -0
- package/dist/pages/Dashboard/Default/index.client.d.ts +8 -0
- package/dist/pages/Dashboard/Default/index.client.d.ts.map +1 -0
- package/dist/pages/Dashboard/Default/index.client.js +154 -0
- package/dist/pages/Dashboard/Default/index.d.ts +11 -0
- package/dist/pages/Dashboard/Default/index.d.ts.map +1 -0
- package/dist/pages/Dashboard/Default/index.js +44 -0
- package/dist/pages/Dashboard/Default/index.scss +58 -0
- package/dist/pages/Dashboard/index.d.ts +13 -0
- package/dist/pages/Dashboard/index.d.ts.map +1 -0
- package/dist/pages/Dashboard/index.js +128 -0
- package/dist/pages/Document/getCustomViewByKey.d.ts +4 -0
- package/dist/pages/Document/getCustomViewByKey.d.ts.map +1 -0
- package/dist/pages/Document/getCustomViewByKey.js +15 -0
- package/dist/pages/Document/getCustomViewByPath.d.ts +4 -0
- package/dist/pages/Document/getCustomViewByPath.d.ts.map +1 -0
- package/dist/pages/Document/getCustomViewByPath.js +26 -0
- package/dist/pages/Document/getMetaBySegment.d.ts +20 -0
- package/dist/pages/Document/getMetaBySegment.d.ts.map +1 -0
- package/dist/pages/Document/getMetaBySegment.js +124 -0
- package/dist/pages/Document/getViewsFromConfig.d.ts +15 -0
- package/dist/pages/Document/getViewsFromConfig.d.ts.map +1 -0
- package/dist/pages/Document/getViewsFromConfig.js +224 -0
- package/dist/pages/Document/index.d.ts +23 -0
- package/dist/pages/Document/index.d.ts.map +1 -0
- package/dist/pages/Document/index.js +237 -0
- package/dist/pages/Edit/Default/Auth/APIKey.d.ts +6 -0
- package/dist/pages/Edit/Default/Auth/APIKey.d.ts.map +1 -0
- package/dist/pages/Edit/Default/Auth/APIKey.js +140 -0
- package/dist/pages/Edit/Default/Auth/index.d.ts +6 -0
- package/dist/pages/Edit/Default/Auth/index.d.ts.map +1 -0
- package/dist/pages/Edit/Default/Auth/index.js +180 -0
- package/dist/pages/Edit/Default/Auth/index.scss +61 -0
- package/dist/pages/Edit/Default/Auth/types.d.ts +14 -0
- package/dist/pages/Edit/Default/Auth/types.d.ts.map +1 -0
- package/dist/pages/Edit/Default/Auth/types.js +6 -0
- package/dist/pages/Edit/Default/RenderCustomView.d.ts +2 -0
- package/dist/pages/Edit/Default/RenderCustomView.d.ts.map +1 -0
- package/dist/pages/Edit/Default/RenderCustomView.js +3 -0
- package/dist/pages/Edit/Default/SetDocumentTitle/index.d.ts +8 -0
- package/dist/pages/Edit/Default/SetDocumentTitle/index.d.ts.map +1 -0
- package/dist/pages/Edit/Default/SetDocumentTitle/index.js +50 -0
- package/dist/pages/Edit/Default/SetStepNav/index.d.ts +13 -0
- package/dist/pages/Edit/Default/SetStepNav/index.d.ts.map +1 -0
- package/dist/pages/Edit/Default/SetStepNav/index.js +70 -0
- package/dist/pages/Edit/Default/index.d.ts +4 -0
- package/dist/pages/Edit/Default/index.d.ts.map +1 -0
- package/dist/pages/Edit/Default/index.js +202 -0
- package/dist/pages/Edit/Default/index.scss +21 -0
- package/dist/pages/Edit/Default/types.d.ts +6 -0
- package/dist/pages/Edit/Default/types.d.ts.map +1 -0
- package/dist/pages/Edit/Default/types.js +6 -0
- package/dist/pages/Edit/index.client.d.ts +4 -0
- package/dist/pages/Edit/index.client.d.ts.map +1 -0
- package/dist/pages/Edit/index.client.js +99 -0
- package/dist/pages/Edit/index.d.ts +4 -0
- package/dist/pages/Edit/index.d.ts.map +1 -0
- package/dist/pages/Edit/index.js +27 -0
- package/dist/pages/Edit/meta.d.ts +3 -0
- package/dist/pages/Edit/meta.d.ts.map +1 -0
- package/dist/pages/Edit/meta.js +36 -0
- package/dist/pages/Edit/sanitizeEditViewProps.d.ts +4 -0
- package/dist/pages/Edit/sanitizeEditViewProps.d.ts.map +1 -0
- package/dist/pages/Edit/sanitizeEditViewProps.js +24 -0
- package/dist/pages/Edit/types.d.js +7 -0
- package/dist/pages/Edit/types.d.ts +37 -0
- package/dist/pages/Edit/types.d.ts.map +1 -0
- package/dist/pages/Edit/types.js +6 -0
- package/dist/pages/ForgotPassword/index.d.ts +10 -0
- package/dist/pages/ForgotPassword/index.d.ts.map +1 -0
- package/dist/pages/ForgotPassword/index.js +101 -0
- package/dist/pages/List/Default/Cell/cellTypes.spec.js +234 -0
- package/dist/pages/List/Default/Cell/fields/Array/index.d.ts +7 -0
- package/dist/pages/List/Default/Cell/fields/Array/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/Array/index.js +27 -0
- package/dist/pages/List/Default/Cell/fields/Blocks/index.d.ts +8 -0
- package/dist/pages/List/Default/Cell/fields/Blocks/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/Blocks/index.js +45 -0
- package/dist/pages/List/Default/Cell/fields/Checkbox/index.d.ts +5 -0
- package/dist/pages/List/Default/Cell/fields/Checkbox/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/Checkbox/index.js +23 -0
- package/dist/pages/List/Default/Cell/fields/Checkbox/index.scss +22 -0
- package/dist/pages/List/Default/Cell/fields/Code/index.d.ts +8 -0
- package/dist/pages/List/Default/Cell/fields/Code/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/Code/index.js +29 -0
- package/dist/pages/List/Default/Cell/fields/Code/index.scss +27 -0
- package/dist/pages/List/Default/Cell/fields/Date/index.d.ts +7 -0
- package/dist/pages/List/Default/Cell/fields/Date/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/Date/index.js +26 -0
- package/dist/pages/List/Default/Cell/fields/File/index.d.ts +7 -0
- package/dist/pages/List/Default/Cell/fields/File/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/File/index.js +39 -0
- package/dist/pages/List/Default/Cell/fields/File/index.scss +23 -0
- package/dist/pages/List/Default/Cell/fields/JSON/index.d.ts +5 -0
- package/dist/pages/List/Default/Cell/fields/JSON/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/JSON/index.js +26 -0
- package/dist/pages/List/Default/Cell/fields/JSON/index.scss +22 -0
- package/dist/pages/List/Default/Cell/fields/Relationship/index.d.ts +9 -0
- package/dist/pages/List/Default/Cell/fields/Relationship/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/Relationship/index.js +121 -0
- package/dist/pages/List/Default/Cell/fields/Relationship/index.scss +3 -0
- package/dist/pages/List/Default/Cell/fields/Richtext/index.d.ts +2 -0
- package/dist/pages/List/Default/Cell/fields/Richtext/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/Richtext/index.js +3 -0
- package/dist/pages/List/Default/Cell/fields/Select/index.d.ts +7 -0
- package/dist/pages/List/Default/Cell/fields/Select/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/Select/index.js +40 -0
- package/dist/pages/List/Default/Cell/fields/Textarea/index.d.ts +4 -0
- package/dist/pages/List/Default/Cell/fields/Textarea/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/Textarea/index.js +23 -0
- package/dist/pages/List/Default/Cell/fields/index.d.ts +17 -0
- package/dist/pages/List/Default/Cell/fields/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/fields/index.js +36 -0
- package/dist/pages/List/Default/Cell/index.d.ts +4 -0
- package/dist/pages/List/Default/Cell/index.d.ts.map +1 -0
- package/dist/pages/List/Default/Cell/index.js +87 -0
- package/dist/pages/List/Default/RelationshipProvider/index.d.ts +20 -0
- package/dist/pages/List/Default/RelationshipProvider/index.d.ts.map +1 -0
- package/dist/pages/List/Default/RelationshipProvider/index.js +153 -0
- package/dist/pages/List/Default/RelationshipProvider/reducer.d.ts +19 -0
- package/dist/pages/List/Default/RelationshipProvider/reducer.d.ts.map +1 -0
- package/dist/pages/List/Default/RelationshipProvider/reducer.js +55 -0
- package/dist/pages/List/Default/index.d.ts +4 -0
- package/dist/pages/List/Default/index.d.ts.map +1 -0
- package/dist/pages/List/Default/index.js +182 -0
- package/dist/pages/List/Default/index.scss +195 -0
- package/dist/pages/List/Default/types.d.ts +14 -0
- package/dist/pages/List/Default/types.d.ts.map +1 -0
- package/dist/pages/List/Default/types.js +6 -0
- package/dist/pages/List/index.d.ts +18 -0
- package/dist/pages/List/index.d.ts.map +1 -0
- package/dist/pages/List/index.js +158 -0
- package/dist/pages/LivePreview/Context/collisionDetection.d.ts +3 -0
- package/dist/pages/LivePreview/Context/collisionDetection.d.ts.map +1 -0
- package/dist/pages/LivePreview/Context/collisionDetection.js +34 -0
- package/dist/pages/LivePreview/Context/context.d.ts +50 -0
- package/dist/pages/LivePreview/Context/context.d.ts.map +1 -0
- package/dist/pages/LivePreview/Context/context.js +58 -0
- package/dist/pages/LivePreview/Context/index.d.ts +18 -0
- package/dist/pages/LivePreview/Context/index.d.ts.map +1 -0
- package/dist/pages/LivePreview/Context/index.js +208 -0
- package/dist/pages/LivePreview/Context/sizeReducer.d.ts +20 -0
- package/dist/pages/LivePreview/Context/sizeReducer.d.ts.map +1 -0
- package/dist/pages/LivePreview/Context/sizeReducer.js +41 -0
- package/dist/pages/LivePreview/Device/index.d.ts +5 -0
- package/dist/pages/LivePreview/Device/index.d.ts.map +1 -0
- package/dist/pages/LivePreview/Device/index.js +102 -0
- package/dist/pages/LivePreview/DeviceContainer/index.d.ts +5 -0
- package/dist/pages/LivePreview/DeviceContainer/index.d.ts.map +1 -0
- package/dist/pages/LivePreview/DeviceContainer/index.js +44 -0
- package/dist/pages/LivePreview/IFrame/index.d.ts +8 -0
- package/dist/pages/LivePreview/IFrame/index.d.ts.map +1 -0
- package/dist/pages/LivePreview/IFrame/index.js +74 -0
- package/dist/pages/LivePreview/IFrame/index.scss +7 -0
- package/dist/pages/LivePreview/Preview/index.d.ts +5 -0
- package/dist/pages/LivePreview/Preview/index.d.ts.map +1 -0
- package/dist/pages/LivePreview/Preview/index.js +127 -0
- package/dist/pages/LivePreview/Preview/index.scss +41 -0
- package/dist/pages/LivePreview/Toolbar/Controls/index.d.ts +5 -0
- package/dist/pages/LivePreview/Toolbar/Controls/index.d.ts.map +1 -0
- package/dist/pages/LivePreview/Toolbar/Controls/index.js +96 -0
- package/dist/pages/LivePreview/Toolbar/Controls/index.scss +59 -0
- package/dist/pages/LivePreview/Toolbar/SizeInput/index.d.ts +6 -0
- package/dist/pages/LivePreview/Toolbar/SizeInput/index.d.ts.map +1 -0
- package/dist/pages/LivePreview/Toolbar/SizeInput/index.js +112 -0
- package/dist/pages/LivePreview/Toolbar/SizeInput/index.scss +10 -0
- package/dist/pages/LivePreview/Toolbar/index.d.ts +7 -0
- package/dist/pages/LivePreview/Toolbar/index.d.ts.map +1 -0
- package/dist/pages/LivePreview/Toolbar/index.js +65 -0
- package/dist/pages/LivePreview/Toolbar/index.scss +41 -0
- package/dist/pages/LivePreview/ToolbarArea/index.d.ts +6 -0
- package/dist/pages/LivePreview/ToolbarArea/index.d.ts.map +1 -0
- package/dist/pages/LivePreview/ToolbarArea/index.js +32 -0
- package/dist/pages/LivePreview/ToolbarArea/index.scss +4 -0
- package/dist/pages/LivePreview/index.client.d.ts +11 -0
- package/dist/pages/LivePreview/index.client.d.ts.map +1 -0
- package/dist/pages/LivePreview/index.client.js +195 -0
- package/dist/pages/LivePreview/index.d.ts +5 -0
- package/dist/pages/LivePreview/index.d.ts.map +1 -0
- package/dist/pages/LivePreview/index.js +59 -0
- package/dist/pages/LivePreview/index.scss +66 -0
- package/dist/pages/LivePreview/meta.d.ts +3 -0
- package/dist/pages/LivePreview/meta.d.ts.map +1 -0
- package/dist/pages/LivePreview/meta.js +36 -0
- package/dist/pages/LivePreview/usePopupWindow.d.ts +19 -0
- package/dist/pages/LivePreview/usePopupWindow.d.ts.map +1 -0
- package/dist/pages/LivePreview/usePopupWindow.js +112 -0
- package/dist/pages/Login/LoginForm/index.d.ts +8 -0
- package/dist/pages/Login/LoginForm/index.d.ts.map +1 -0
- package/dist/pages/Login/LoginForm/index.js +67 -0
- package/dist/pages/Login/LoginForm/index.scss +8 -0
- package/dist/pages/Login/index.d.ts +14 -0
- package/dist/pages/Login/index.d.ts.map +1 -0
- package/dist/pages/Login/index.js +108 -0
- package/dist/pages/Login/index.scss +38 -0
- package/dist/pages/Logout/LogoutClient.d.ts +7 -0
- package/dist/pages/Logout/LogoutClient.d.ts.map +1 -0
- package/dist/pages/Logout/LogoutClient.js +88 -0
- package/dist/pages/Logout/index.d.ts +16 -0
- package/dist/pages/Logout/index.d.ts.map +1 -0
- package/dist/pages/Logout/index.js +61 -0
- package/dist/pages/Logout/index.scss +20 -0
- package/dist/pages/NotFound/index.d.ts +7 -0
- package/dist/pages/NotFound/index.d.ts.map +1 -0
- package/dist/pages/NotFound/index.js +48 -0
- package/dist/pages/NotFound/index.scss +36 -0
- package/dist/pages/ResetPassword/index.d.ts +12 -0
- package/dist/pages/ResetPassword/index.d.ts.map +1 -0
- package/dist/pages/ResetPassword/index.js +99 -0
- package/dist/pages/ResetPassword/index.scss +15 -0
- package/dist/pages/Root/index.d.ts +5 -0
- package/dist/pages/Root/index.d.ts.map +1 -0
- package/dist/pages/Root/index.js +17 -0
- package/dist/pages/Unauthorized/UnauthorizedClient.d.ts +5 -0
- package/dist/pages/Unauthorized/UnauthorizedClient.d.ts.map +1 -0
- package/dist/pages/Unauthorized/UnauthorizedClient.js +27 -0
- package/dist/pages/Unauthorized/index.d.ts +10 -0
- package/dist/pages/Unauthorized/index.d.ts.map +1 -0
- package/dist/pages/Unauthorized/index.js +51 -0
- package/dist/pages/Verify/index.d.ts +13 -0
- package/dist/pages/Verify/index.d.ts.map +1 -0
- package/dist/pages/Verify/index.js +90 -0
- package/dist/pages/Verify/index.scss +14 -0
- package/dist/pages/Version/Default/SetStepNav.d.ts +13 -0
- package/dist/pages/Version/Default/SetStepNav.d.ts.map +1 -0
- package/dist/pages/Version/Default/SetStepNav.js +92 -0
- package/dist/pages/Version/Default/index.d.ts +5 -0
- package/dist/pages/Version/Default/index.d.ts.map +1 -0
- package/dist/pages/Version/Default/index.js +157 -0
- package/dist/pages/Version/Default/index.scss +70 -0
- package/dist/pages/Version/Default/types.d.ts +24 -0
- package/dist/pages/Version/Default/types.d.ts.map +1 -0
- package/dist/pages/Version/Default/types.js +6 -0
- package/dist/pages/Version/RenderFieldsToDiff/Label/index.d.ts +7 -0
- package/dist/pages/Version/RenderFieldsToDiff/Label/index.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/Label/index.js +24 -0
- package/dist/pages/Version/RenderFieldsToDiff/Label/index.scss +4 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Iterable/index.d.ts +6 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Iterable/index.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Iterable/index.js +80 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Iterable/index.scss +34 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Nested/index.d.ts +6 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Nested/index.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Nested/index.js +44 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Nested/index.scss +12 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Relationship/index.d.ts +6 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Relationship/index.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Relationship/index.js +89 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Relationship/index.scss +13 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/DiffViewer/index.d.ts +9 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/DiffViewer/index.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/DiffViewer/index.js +72 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/index.d.ts +6 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/index.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/index.js +54 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Select/index.scss +13 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Tabs/index.d.ts +5 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Tabs/index.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Tabs/index.js +54 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/DiffViewer/index.d.ts +9 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/DiffViewer/index.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/DiffViewer/index.js +72 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/index.d.ts +6 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/index.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/index.js +46 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/Text/index.scss +13 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/diffMethods.d.ts +7 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/diffMethods.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/diffMethods.js +18 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/index.d.ts +25 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/index.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/index.js +44 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/styles.d.ts +27 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/styles.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/styles.js +38 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/types.d.ts +21 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/types.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/fields/types.js +6 -0
- package/dist/pages/Version/RenderFieldsToDiff/index.d.ts +6 -0
- package/dist/pages/Version/RenderFieldsToDiff/index.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/index.js +115 -0
- package/dist/pages/Version/RenderFieldsToDiff/index.scss +18 -0
- package/dist/pages/Version/RenderFieldsToDiff/types.d.ts +20 -0
- package/dist/pages/Version/RenderFieldsToDiff/types.d.ts.map +1 -0
- package/dist/pages/Version/RenderFieldsToDiff/types.js +6 -0
- package/dist/pages/Version/Restore/index.d.ts +6 -0
- package/dist/pages/Version/Restore/index.d.ts.map +1 -0
- package/dist/pages/Version/Restore/index.js +121 -0
- package/dist/pages/Version/Restore/index.scss +28 -0
- package/dist/pages/Version/Restore/types.d.ts +11 -0
- package/dist/pages/Version/Restore/types.d.ts.map +1 -0
- package/dist/pages/Version/Restore/types.js +6 -0
- package/dist/pages/Version/SelectComparison/index.d.ts +5 -0
- package/dist/pages/Version/SelectComparison/index.d.ts.map +1 -0
- package/dist/pages/Version/SelectComparison/index.js +167 -0
- package/dist/pages/Version/SelectComparison/index.scss +13 -0
- package/dist/pages/Version/SelectComparison/types.d.ts +27 -0
- package/dist/pages/Version/SelectComparison/types.d.ts.map +1 -0
- package/dist/pages/Version/SelectComparison/types.js +6 -0
- package/dist/pages/Version/SelectLocales/index.d.ts +5 -0
- package/dist/pages/Version/SelectLocales/index.d.ts.map +1 -0
- package/dist/pages/Version/SelectLocales/index.js +47 -0
- package/dist/pages/Version/SelectLocales/index.scss +7 -0
- package/dist/pages/Version/SelectLocales/types.d.ts +7 -0
- package/dist/pages/Version/SelectLocales/types.d.ts.map +1 -0
- package/dist/pages/Version/SelectLocales/types.js +6 -0
- package/dist/pages/Version/index.d.ts +4 -0
- package/dist/pages/Version/index.d.ts.map +1 -0
- package/dist/pages/Version/index.js +111 -0
- package/dist/pages/Version/meta.d.ts +3 -0
- package/dist/pages/Version/meta.d.ts.map +1 -0
- package/dist/pages/Version/meta.js +47 -0
- package/dist/pages/Version/shared.d.ts +9 -0
- package/dist/pages/Version/shared.d.ts.map +1 -0
- package/dist/pages/Version/shared.js +28 -0
- package/dist/pages/Versions/buildColumns.d.ts +11 -0
- package/dist/pages/Versions/buildColumns.d.ts.map +1 -0
- package/dist/pages/Versions/buildColumns.js +69 -0
- package/dist/pages/Versions/cells/AutosaveCell/index.d.ts +3 -0
- package/dist/pages/Versions/cells/AutosaveCell/index.d.ts.map +1 -0
- package/dist/pages/Versions/cells/AutosaveCell/index.js +63 -0
- package/dist/pages/Versions/cells/CreatedAt/index.d.ts +9 -0
- package/dist/pages/Versions/cells/CreatedAt/index.d.ts.map +1 -0
- package/dist/pages/Versions/cells/CreatedAt/index.js +33 -0
- package/dist/pages/Versions/cells/ID/index.d.ts +3 -0
- package/dist/pages/Versions/cells/ID/index.d.ts.map +1 -0
- package/dist/pages/Versions/cells/ID/index.js +60 -0
- package/dist/pages/Versions/index.client.d.ts +15 -0
- package/dist/pages/Versions/index.client.d.ts.map +1 -0
- package/dist/pages/Versions/index.client.js +142 -0
- package/dist/pages/Versions/index.d.ts +6 -0
- package/dist/pages/Versions/index.d.ts.map +1 -0
- package/dist/pages/Versions/index.js +125 -0
- package/dist/pages/Versions/index.scss +108 -0
- package/dist/pages/Versions/meta.d.ts +3 -0
- package/dist/pages/Versions/meta.d.ts.map +1 -0
- package/dist/pages/Versions/meta.js +43 -0
- package/dist/pages/Versions/types.d.ts +19 -0
- package/dist/pages/Versions/types.d.ts.map +1 -0
- package/dist/pages/Versions/types.js +6 -0
- package/dist/routes/graphql/handler.d.ts +4 -0
- package/dist/routes/graphql/handler.d.ts.map +1 -0
- package/dist/routes/graphql/handler.js +128 -0
- package/dist/routes/graphql/index.d.ts +3 -0
- package/dist/routes/graphql/index.d.ts.map +1 -0
- package/dist/routes/graphql/index.js +22 -0
- package/dist/routes/graphql/playground.d.ts +3 -0
- package/dist/routes/graphql/playground.d.ts.map +1 -0
- package/dist/routes/graphql/playground.js +37 -0
- package/dist/routes/index.d.ts +4 -0
- package/dist/routes/index.d.ts.map +1 -0
- package/dist/routes/index.js +38 -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 +104 -0
- package/dist/routes/rest/[collection]/file/[filename]/route.d.ts +8 -0
- package/dist/routes/rest/[collection]/file/[filename]/route.d.ts.map +1 -0
- package/dist/routes/rest/[collection]/file/[filename]/route.js +116 -0
- package/dist/routes/rest/auth/access.d.ts +3 -0
- package/dist/routes/rest/auth/access.d.ts.map +1 -0
- package/dist/routes/rest/auth/access.js +27 -0
- package/dist/routes/rest/auth/forgotPassword.d.ts +3 -0
- package/dist/routes/rest/auth/forgotPassword.d.ts.map +1 -0
- package/dist/routes/rest/auth/forgotPassword.js +36 -0
- package/dist/routes/rest/auth/init.d.ts +3 -0
- package/dist/routes/rest/auth/init.d.ts.map +1 -0
- package/dist/routes/rest/auth/init.js +22 -0
- package/dist/routes/rest/auth/login.d.ts +3 -0
- package/dist/routes/rest/auth/login.d.ts.map +1 -0
- package/dist/routes/rest/auth/login.js +52 -0
- package/dist/routes/rest/auth/logout.d.ts +3 -0
- package/dist/routes/rest/auth/logout.d.ts.map +1 -0
- package/dist/routes/rest/auth/logout.js +46 -0
- package/dist/routes/rest/auth/me.d.ts +3 -0
- package/dist/routes/rest/auth/me.d.ts.map +1 -0
- package/dist/routes/rest/auth/me.js +37 -0
- package/dist/routes/rest/auth/refresh.d.ts +3 -0
- package/dist/routes/rest/auth/refresh.d.ts.map +1 -0
- package/dist/routes/rest/auth/refresh.js +54 -0
- package/dist/routes/rest/auth/registerFirstUser.d.ts +3 -0
- package/dist/routes/rest/auth/registerFirstUser.d.ts.map +1 -0
- package/dist/routes/rest/auth/registerFirstUser.js +47 -0
- package/dist/routes/rest/auth/resetPassword.d.ts +3 -0
- package/dist/routes/rest/auth/resetPassword.d.ts.map +1 -0
- package/dist/routes/rest/auth/resetPassword.js +51 -0
- package/dist/routes/rest/auth/unlock.d.ts +3 -0
- package/dist/routes/rest/auth/unlock.d.ts.map +1 -0
- package/dist/routes/rest/auth/unlock.js +34 -0
- package/dist/routes/rest/auth/verifyEmail.d.ts +3 -0
- package/dist/routes/rest/auth/verifyEmail.d.ts.map +1 -0
- package/dist/routes/rest/auth/verifyEmail.js +32 -0
- package/dist/routes/rest/buildFormState.d.ts +7 -0
- package/dist/routes/rest/buildFormState.d.ts.map +1 -0
- package/dist/routes/rest/buildFormState.js +96 -0
- package/dist/routes/rest/checkEndpoints.d.ts +5 -0
- package/dist/routes/rest/checkEndpoints.d.ts.map +1 -0
- package/dist/routes/rest/checkEndpoints.js +27 -0
- package/dist/routes/rest/collections/create.d.ts +3 -0
- package/dist/routes/rest/collections/create.d.ts.map +1 -0
- package/dist/routes/rest/collections/create.js +42 -0
- package/dist/routes/rest/collections/delete.d.ts +3 -0
- package/dist/routes/rest/collections/delete.d.ts.map +1 -0
- package/dist/routes/rest/collections/delete.js +57 -0
- package/dist/routes/rest/collections/deleteByID.d.ts +3 -0
- package/dist/routes/rest/collections/deleteByID.d.ts.map +1 -0
- package/dist/routes/rest/collections/deleteByID.js +43 -0
- package/dist/routes/rest/collections/docAccess.d.ts +3 -0
- package/dist/routes/rest/collections/docAccess.d.ts.map +1 -0
- package/dist/routes/rest/collections/docAccess.js +29 -0
- package/dist/routes/rest/collections/find.d.ts +3 -0
- package/dist/routes/rest/collections/find.d.ts.map +1 -0
- package/dist/routes/rest/collections/find.js +39 -0
- package/dist/routes/rest/collections/findByID.d.ts +3 -0
- package/dist/routes/rest/collections/findByID.d.ts.map +1 -0
- package/dist/routes/rest/collections/findByID.js +34 -0
- package/dist/routes/rest/collections/findVersionByID.d.ts +3 -0
- package/dist/routes/rest/collections/findVersionByID.d.ts.map +1 -0
- package/dist/routes/rest/collections/findVersionByID.js +33 -0
- package/dist/routes/rest/collections/findVersions.d.ts +3 -0
- package/dist/routes/rest/collections/findVersions.d.ts.map +1 -0
- package/dist/routes/rest/collections/findVersions.js +38 -0
- package/dist/routes/rest/collections/restoreVersion.d.ts +3 -0
- package/dist/routes/rest/collections/restoreVersion.d.ts.map +1 -0
- package/dist/routes/rest/collections/restoreVersion.js +36 -0
- package/dist/routes/rest/collections/update.d.ts +3 -0
- package/dist/routes/rest/collections/update.d.ts.map +1 -0
- package/dist/routes/rest/collections/update.js +59 -0
- package/dist/routes/rest/collections/updateByID.d.ts +3 -0
- package/dist/routes/rest/collections/updateByID.d.ts.map +1 -0
- package/dist/routes/rest/collections/updateByID.js +44 -0
- package/dist/routes/rest/globals/docAccess.d.ts +3 -0
- package/dist/routes/rest/globals/docAccess.d.ts.map +1 -0
- package/dist/routes/rest/globals/docAccess.js +28 -0
- package/dist/routes/rest/globals/findOne.d.ts +3 -0
- package/dist/routes/rest/globals/findOne.d.ts.map +1 -0
- package/dist/routes/rest/globals/findOne.js +34 -0
- package/dist/routes/rest/globals/findVersionByID.d.ts +3 -0
- package/dist/routes/rest/globals/findVersionByID.d.ts.map +1 -0
- package/dist/routes/rest/globals/findVersionByID.js +33 -0
- package/dist/routes/rest/globals/findVersions.d.ts +3 -0
- package/dist/routes/rest/globals/findVersions.d.ts.map +1 -0
- package/dist/routes/rest/globals/findVersions.js +38 -0
- package/dist/routes/rest/globals/restoreVersion.d.ts +3 -0
- package/dist/routes/rest/globals/restoreVersion.d.ts.map +1 -0
- package/dist/routes/rest/globals/restoreVersion.js +36 -0
- package/dist/routes/rest/globals/update.d.ts +3 -0
- package/dist/routes/rest/globals/update.d.ts.map +1 -0
- package/dist/routes/rest/globals/update.js +44 -0
- package/dist/routes/rest/index.d.ts +22 -0
- package/dist/routes/rest/index.d.ts.map +1 -0
- package/dist/routes/rest/index.js +546 -0
- package/dist/routes/rest/types.d.ts +23 -0
- package/dist/routes/rest/types.d.ts.map +1 -0
- package/dist/routes/rest/types.js +6 -0
- package/dist/scss/app.scss +209 -0
- package/dist/scss/colors.scss +269 -0
- package/dist/scss/custom.css +1 -0
- package/dist/scss/fonts.scss +75 -0
- package/dist/scss/queries.scss +27 -0
- package/dist/scss/resets.scss +17 -0
- package/dist/scss/styles.scss +11 -0
- package/dist/scss/svg.scss +10 -0
- package/dist/scss/toastify.scss +59 -0
- package/dist/scss/type.scss +117 -0
- package/dist/scss/vars.scss +220 -0
- package/dist/scss/z-index.scss +9 -0
- package/dist/utilities/auth.d.ts +10 -0
- package/dist/utilities/auth.d.ts.map +1 -0
- package/dist/utilities/auth.js +42 -0
- package/dist/utilities/createClientConfig.d.ts +5 -0
- package/dist/utilities/createClientConfig.d.ts.map +1 -0
- package/dist/utilities/createClientConfig.js +120 -0
- package/dist/utilities/createPayloadRequest.d.ts +11 -0
- package/dist/utilities/createPayloadRequest.d.ts.map +1 -0
- package/dist/utilities/createPayloadRequest.js +95 -0
- package/dist/utilities/getDataAndFile.d.ts +12 -0
- package/dist/utilities/getDataAndFile.d.ts.map +1 -0
- package/dist/utilities/getDataAndFile.js +74 -0
- package/dist/utilities/getNextI18n.d.ts +7 -0
- package/dist/utilities/getNextI18n.d.ts.map +1 -0
- package/dist/utilities/getNextI18n.js +28 -0
- package/dist/utilities/getNextT.d.ts +7 -0
- package/dist/utilities/getNextT.d.ts.map +1 -0
- package/dist/utilities/getNextT.js +28 -0
- package/dist/utilities/getRequestLanguage.d.ts +9 -0
- package/dist/utilities/getRequestLanguage.d.ts.map +1 -0
- package/dist/utilities/getRequestLanguage.js +19 -0
- package/dist/utilities/getRequestLocales.d.ts +12 -0
- package/dist/utilities/getRequestLocales.d.ts.map +1 -0
- package/dist/utilities/getRequestLocales.js +38 -0
- package/dist/utilities/initPage.d.ts +21 -0
- package/dist/utilities/initPage.d.ts.map +1 -0
- package/dist/utilities/initPage.js +79 -0
- package/dist/utilities/meta.d.ts +9 -0
- package/dist/utilities/meta.d.ts.map +1 -0
- package/dist/utilities/meta.js +45 -0
- package/dist/withPayload.d.ts +3 -0
- package/dist/withPayload.d.ts.map +1 -0
- package/dist/withPayload.js +77 -0
- package/package.json +83 -0
- package/src/index.ts +1 -0
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
"use strict";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
Object.defineProperty(exports, "LoginForm", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function() {
|
|
9
|
+
return LoginForm;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
const _ui = require("@payloadcms/ui");
|
|
13
|
+
const _link = /*#__PURE__*/ _interop_require_default(require("next/link"));
|
|
14
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
15
|
+
require("./index.scss");
|
|
16
|
+
function _interop_require_default(obj) {
|
|
17
|
+
return obj && obj.__esModule ? obj : {
|
|
18
|
+
default: obj
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
const baseClass = 'login__form';
|
|
22
|
+
const LoginForm = ({ searchParams })=>{
|
|
23
|
+
const config = (0, _ui.useConfig)();
|
|
24
|
+
const { admin: { autoLogin, user: userSlug }, routes: { admin, api } } = config;
|
|
25
|
+
const { t } = (0, _ui.useTranslation)();
|
|
26
|
+
const prefillForm = autoLogin && autoLogin.prefillOnly;
|
|
27
|
+
const initialState = {
|
|
28
|
+
email: {
|
|
29
|
+
initialValue: prefillForm ? autoLogin.email : undefined,
|
|
30
|
+
valid: true,
|
|
31
|
+
value: prefillForm ? autoLogin.email : undefined
|
|
32
|
+
},
|
|
33
|
+
password: {
|
|
34
|
+
initialValue: prefillForm ? autoLogin.password : undefined,
|
|
35
|
+
valid: true,
|
|
36
|
+
value: prefillForm ? autoLogin.password : undefined
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
return /*#__PURE__*/ _react.default.createElement(_ui.Form, {
|
|
40
|
+
action: `${api}/${userSlug}/login`,
|
|
41
|
+
className: `${baseClass}__form`,
|
|
42
|
+
disableSuccessStatus: true,
|
|
43
|
+
initialState: initialState,
|
|
44
|
+
method: "POST",
|
|
45
|
+
redirect: typeof searchParams?.redirect === 'string' ? searchParams.redirect : '',
|
|
46
|
+
waitForAutocomplete: true
|
|
47
|
+
}, /*#__PURE__*/ _react.default.createElement(_ui.FormLoadingOverlayToggle, {
|
|
48
|
+
action: "loading",
|
|
49
|
+
name: "login-form"
|
|
50
|
+
}), /*#__PURE__*/ _react.default.createElement("div", {
|
|
51
|
+
className: `${baseClass}__inputWrap`
|
|
52
|
+
}, /*#__PURE__*/ _react.default.createElement(_ui.Email, {
|
|
53
|
+
autoComplete: "email",
|
|
54
|
+
label: t('general:email'),
|
|
55
|
+
name: "email",
|
|
56
|
+
required: true
|
|
57
|
+
}), /*#__PURE__*/ _react.default.createElement(_ui.Password, {
|
|
58
|
+
autoComplete: "off",
|
|
59
|
+
label: t('general:password'),
|
|
60
|
+
name: "password",
|
|
61
|
+
required: true
|
|
62
|
+
})), /*#__PURE__*/ _react.default.createElement(_link.default, {
|
|
63
|
+
href: `${admin}/forgot`
|
|
64
|
+
}, t('authentication:forgotPasswordQuestion')), /*#__PURE__*/ _react.default.createElement(_ui.FormSubmit, null, t('authentication:login')));
|
|
65
|
+
};
|
|
66
|
+
|
|
67
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3NyYy9wYWdlcy9Mb2dpbi9Mb2dpbkZvcm0va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BQ04sUUFBTztRQUFVTyxNQUFLO3NCQUNoRCw2QkFBQ0M7UUFBSVAsV0FBVyxDQUFDLEVBQUV2QixVQUFVLFdBQVcsQ0FBQztxQkFDdkMsNkJBQUMrQixTQUFLO1FBQUNDLGNBQWE7UUFBUUMsT0FBT3ZCLEVBQUU7UUFBa0JtQixNQUFLO1FBQVFLLFVBQUFBO3NCQUNwRSw2QkFBQ0MsWUFBUTtRQUFDSCxjQUFhO1FBQU1DLE9BQU92QixFQUFFO1FBQXFCbUIsTUFBSztRQUFXSyxVQUFBQTt1QkFFN0UsNkJBQUNFLGFBQUk7UUFBQ0MsTUFBTSxDQUFDLEVBQUVqQyxNQUFNLE9BQU8sQ0FBQztPQUFHTSxFQUFFLHlEQUNsQyw2QkFBQzRCLGNBQVUsUUFBRTVCLEVBQUU7QUFHckIifQ==
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { Metadata } from 'next';
|
|
2
|
+
import type { SanitizedConfig } from 'payload/types';
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import './index.scss';
|
|
5
|
+
export declare const generateMetadata: ({ config: configPromise, }: {
|
|
6
|
+
config: Promise<SanitizedConfig>;
|
|
7
|
+
}) => Promise<Metadata>;
|
|
8
|
+
export declare const Login: React.FC<{
|
|
9
|
+
config: Promise<SanitizedConfig>;
|
|
10
|
+
searchParams: {
|
|
11
|
+
[key: string]: string | string[] | undefined;
|
|
12
|
+
};
|
|
13
|
+
}>;
|
|
14
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/pages/Login/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,MAAM,CAAA;AACpC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAA;AAIpD,OAAO,KAAmB,MAAM,OAAO,CAAA;AAMvC,OAAO,cAAc,CAAA;AAIrB,eAAO,MAAM,gBAAgB,+BAE1B;IACD,MAAM,EAAE,QAAQ,eAAe,CAAC,CAAA;CACjC,KAAG,QAAQ,QAAQ,CAanB,CAAA;AAED,eAAO,MAAM,KAAK,EAAE,KAAK,CAAC,EAAE,CAAC;IAC3B,MAAM,EAAE,OAAO,CAAC,eAAe,CAAC,CAAA;IAChC,YAAY,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,EAAE,GAAG,SAAS,CAAA;KAAE,CAAA;CAC/D,CAgCA,CAAA"}
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
function _export(target, all) {
|
|
6
|
+
for(var name in all)Object.defineProperty(target, name, {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: all[name]
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
_export(exports, {
|
|
12
|
+
Login: function() {
|
|
13
|
+
return Login;
|
|
14
|
+
},
|
|
15
|
+
generateMetadata: function() {
|
|
16
|
+
return generateMetadata;
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
const _ui = require("@payloadcms/ui");
|
|
20
|
+
const _navigation = require("next/navigation");
|
|
21
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard(require("react"));
|
|
22
|
+
const _getNextI18n = require("../../utilities/getNextI18n");
|
|
23
|
+
const _initPage = require("../../utilities/initPage");
|
|
24
|
+
const _meta = require("../../utilities/meta");
|
|
25
|
+
const _LoginForm = require("./LoginForm");
|
|
26
|
+
require("./index.scss");
|
|
27
|
+
function _getRequireWildcardCache(nodeInterop) {
|
|
28
|
+
if (typeof WeakMap !== "function") return null;
|
|
29
|
+
var cacheBabelInterop = new WeakMap();
|
|
30
|
+
var cacheNodeInterop = new WeakMap();
|
|
31
|
+
return (_getRequireWildcardCache = function(nodeInterop) {
|
|
32
|
+
return nodeInterop ? cacheNodeInterop : cacheBabelInterop;
|
|
33
|
+
})(nodeInterop);
|
|
34
|
+
}
|
|
35
|
+
function _interop_require_wildcard(obj, nodeInterop) {
|
|
36
|
+
if (!nodeInterop && obj && obj.__esModule) {
|
|
37
|
+
return obj;
|
|
38
|
+
}
|
|
39
|
+
if (obj === null || typeof obj !== "object" && typeof obj !== "function") {
|
|
40
|
+
return {
|
|
41
|
+
default: obj
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
var cache = _getRequireWildcardCache(nodeInterop);
|
|
45
|
+
if (cache && cache.has(obj)) {
|
|
46
|
+
return cache.get(obj);
|
|
47
|
+
}
|
|
48
|
+
var newObj = {
|
|
49
|
+
__proto__: null
|
|
50
|
+
};
|
|
51
|
+
var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
|
|
52
|
+
for(var key in obj){
|
|
53
|
+
if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
54
|
+
var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
|
|
55
|
+
if (desc && (desc.get || desc.set)) {
|
|
56
|
+
Object.defineProperty(newObj, key, desc);
|
|
57
|
+
} else {
|
|
58
|
+
newObj[key] = obj[key];
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
newObj.default = obj;
|
|
63
|
+
if (cache) {
|
|
64
|
+
cache.set(obj, newObj);
|
|
65
|
+
}
|
|
66
|
+
return newObj;
|
|
67
|
+
}
|
|
68
|
+
const baseClass = 'login';
|
|
69
|
+
const generateMetadata = async ({ config: configPromise })=>{
|
|
70
|
+
const config = await configPromise;
|
|
71
|
+
const { t } = await (0, _getNextI18n.getNextI18n)({
|
|
72
|
+
config
|
|
73
|
+
});
|
|
74
|
+
return (0, _meta.meta)({
|
|
75
|
+
config,
|
|
76
|
+
description: `${t('authentication:login')}`,
|
|
77
|
+
keywords: `${t('authentication:login')}`,
|
|
78
|
+
title: t('authentication:login')
|
|
79
|
+
});
|
|
80
|
+
};
|
|
81
|
+
const Login = async ({ config: configPromise, searchParams })=>{
|
|
82
|
+
const { req } = await (0, _initPage.initPage)({
|
|
83
|
+
config: configPromise,
|
|
84
|
+
route: '/login',
|
|
85
|
+
searchParams
|
|
86
|
+
});
|
|
87
|
+
const { payload: { config }, user } = req;
|
|
88
|
+
const { admin: { components: { afterLogin, beforeLogin } = {}, user: userSlug }, collections, routes: { admin } } = config;
|
|
89
|
+
if (user) {
|
|
90
|
+
(0, _navigation.redirect)(admin);
|
|
91
|
+
}
|
|
92
|
+
const collectionConfig = collections.find(({ slug })=>slug === userSlug);
|
|
93
|
+
return /*#__PURE__*/ _react.default.createElement(_ui.MinimalTemplate, {
|
|
94
|
+
className: baseClass
|
|
95
|
+
}, /*#__PURE__*/ _react.default.createElement(_react.Fragment, null, /*#__PURE__*/ _react.default.createElement("div", {
|
|
96
|
+
className: `${baseClass}__brand`
|
|
97
|
+
}, /*#__PURE__*/ _react.default.createElement(_ui.Logo, {
|
|
98
|
+
config: config
|
|
99
|
+
})), Array.isArray(beforeLogin) && beforeLogin.map((Component, i)=>/*#__PURE__*/ _react.default.createElement(Component, {
|
|
100
|
+
key: i
|
|
101
|
+
})), !collectionConfig?.auth?.disableLocalStrategy && /*#__PURE__*/ _react.default.createElement(_LoginForm.LoginForm, {
|
|
102
|
+
searchParams: searchParams
|
|
103
|
+
}), Array.isArray(afterLogin) && afterLogin.map((Component, i)=>/*#__PURE__*/ _react.default.createElement(Component, {
|
|
104
|
+
key: i
|
|
105
|
+
}))));
|
|
106
|
+
};
|
|
107
|
+
|
|
108
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy9wYWdlcy9Mb2dpbi9pbmRleC50c3giXSwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHR5cGUgeyBNZXRhZGF0YSB9IGZyb20gJ25leHQnXG5pbXBvcnQgdHlwZSB7IFNhbml0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QyxXQUFXLEVBQ1hDLFFBQVEsRUFBRU4sS0FBSyxFQUFFLEVBQ2xCLEdBQUdkO0lBRUosSUFBSWEsTUFBTTtRQUNSUSxJQUFBQSxvQkFBUSxFQUFDUDtJQUNYO0lBRUEsTUFBTVEsbUJBQW1CSCxZQUFZSSxJQUFJLENBQUMsQ0FBQyxFQUFFQyxJQUFJLEVBQUUsR0FBS0EsU0FBU047SUFFakUscUJBQ0UsNkJBQUNPLG1CQUFlO1FBQUNDLFdBQVczQjtxQkFDMUIsNkJBQUM0QixlQUFRLHNCQUNQLDZCQUFDQztRQUFJRixXQUFXLENBQUMsRUFBRTNCLFVBQVUsT0FBTyxDQUFDO3FCQUNuQyw2QkFBQzhCLFFBQUk7UUFBQzdCLFFBQVFBO1NBRWY4QixNQUFNQyxPQUFPLENBQUNkLGdCQUFnQkEsWUFBWWUsR0FBRyxDQUFDLENBQUNDLFdBQVdDLGtCQUFNLDZCQUFDRDtZQUFVRSxLQUFLRDthQUNoRixDQUFDWixrQkFBa0JjLE1BQU1DLHNDQUF3Qiw2QkFBQ0Msb0JBQVM7UUFBQzlCLGNBQWNBO1FBQzFFc0IsTUFBTUMsT0FBTyxDQUFDZixlQUFlQSxXQUFXZ0IsR0FBRyxDQUFDLENBQUNDLFdBQVdDLGtCQUFNLDZCQUFDRDtZQUFVRSxLQUFLRDs7QUFJdkYifQ==
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
.login {
|
|
2
|
+
&__brand {
|
|
3
|
+
display: flex;
|
|
4
|
+
justify-content: center;
|
|
5
|
+
width: 100%;
|
|
6
|
+
margin-bottom: calc(var(--base) * 2);
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
&__form {
|
|
10
|
+
&__inputWrap {
|
|
11
|
+
display: flex;
|
|
12
|
+
flex-direction: column;
|
|
13
|
+
gap: var(--base);
|
|
14
|
+
margin-bottom: calc(var(--base) / 4);
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
&__wrap {
|
|
19
|
+
& > *:first-child {
|
|
20
|
+
margin-top: 0;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
& > *:last-child {
|
|
24
|
+
margin-bottom: 0;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.btn {
|
|
28
|
+
margin: 0;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
&__inputWrap {
|
|
33
|
+
display: flex;
|
|
34
|
+
flex-direction: column;
|
|
35
|
+
gap: var(--base);
|
|
36
|
+
margin-bottom: calc(var(--base) / 4);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LogoutClient.d.ts","sourceRoot":"","sources":["../../../src/pages/Logout/LogoutClient.tsx"],"names":[],"mappings":"AAGA,OAAO,KAA8B,MAAM,OAAO,CAAA;AAIlD,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC;IAClC,UAAU,EAAE,MAAM,CAAA;IAClB,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,QAAQ,EAAE,MAAM,CAAA;CACjB,CAmCA,CAAA"}
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
"use strict";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
Object.defineProperty(exports, "LogoutClient", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function() {
|
|
9
|
+
return LogoutClient;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
const _ui = require("@payloadcms/ui");
|
|
13
|
+
const _link = /*#__PURE__*/ _interop_require_default(require("next/link"));
|
|
14
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard(require("react"));
|
|
15
|
+
const _Auth = require("../../../../ui/src/providers/Auth");
|
|
16
|
+
function _interop_require_default(obj) {
|
|
17
|
+
return obj && obj.__esModule ? obj : {
|
|
18
|
+
default: obj
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
function _getRequireWildcardCache(nodeInterop) {
|
|
22
|
+
if (typeof WeakMap !== "function") return null;
|
|
23
|
+
var cacheBabelInterop = new WeakMap();
|
|
24
|
+
var cacheNodeInterop = new WeakMap();
|
|
25
|
+
return (_getRequireWildcardCache = function(nodeInterop) {
|
|
26
|
+
return nodeInterop ? cacheNodeInterop : cacheBabelInterop;
|
|
27
|
+
})(nodeInterop);
|
|
28
|
+
}
|
|
29
|
+
function _interop_require_wildcard(obj, nodeInterop) {
|
|
30
|
+
if (!nodeInterop && obj && obj.__esModule) {
|
|
31
|
+
return obj;
|
|
32
|
+
}
|
|
33
|
+
if (obj === null || typeof obj !== "object" && typeof obj !== "function") {
|
|
34
|
+
return {
|
|
35
|
+
default: obj
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
var cache = _getRequireWildcardCache(nodeInterop);
|
|
39
|
+
if (cache && cache.has(obj)) {
|
|
40
|
+
return cache.get(obj);
|
|
41
|
+
}
|
|
42
|
+
var newObj = {
|
|
43
|
+
__proto__: null
|
|
44
|
+
};
|
|
45
|
+
var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
|
|
46
|
+
for(var key in obj){
|
|
47
|
+
if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
48
|
+
var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
|
|
49
|
+
if (desc && (desc.get || desc.set)) {
|
|
50
|
+
Object.defineProperty(newObj, key, desc);
|
|
51
|
+
} else {
|
|
52
|
+
newObj[key] = obj[key];
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
newObj.default = obj;
|
|
57
|
+
if (cache) {
|
|
58
|
+
cache.set(obj, newObj);
|
|
59
|
+
}
|
|
60
|
+
return newObj;
|
|
61
|
+
}
|
|
62
|
+
const LogoutClient = (props)=>{
|
|
63
|
+
const { adminRoute, inactivity, redirect } = props;
|
|
64
|
+
const [isLoggingOut, setIsLoggingOut] = _react.default.useState(undefined);
|
|
65
|
+
const { logOut } = (0, _Auth.useAuth)();
|
|
66
|
+
const { t } = (0, _ui.useTranslation)();
|
|
67
|
+
(0, _react.useEffect)(()=>{
|
|
68
|
+
if (!isLoggingOut) {
|
|
69
|
+
setIsLoggingOut(true);
|
|
70
|
+
logOut();
|
|
71
|
+
}
|
|
72
|
+
}, [
|
|
73
|
+
isLoggingOut,
|
|
74
|
+
logOut
|
|
75
|
+
]);
|
|
76
|
+
if (isLoggingOut) {
|
|
77
|
+
return /*#__PURE__*/ _react.default.createElement(_react.Fragment, null, inactivity && /*#__PURE__*/ _react.default.createElement("h2", null, t('authentication:loggedOutInactivity')), !inactivity && /*#__PURE__*/ _react.default.createElement("h2", null, t('authentication:loggedOutSuccessfully')), /*#__PURE__*/ _react.default.createElement(_ui.Button, {
|
|
78
|
+
Link: _link.default,
|
|
79
|
+
buttonStyle: "secondary",
|
|
80
|
+
el: "link",
|
|
81
|
+
url: `${adminRoute}/login${redirect && redirect.length > 0 ? `?redirect=${encodeURIComponent(redirect)}` : ''}`
|
|
82
|
+
}, t('authentication:logBackIn')));
|
|
83
|
+
}
|
|
84
|
+
// TODO(i18n): needs translation in all languages
|
|
85
|
+
return /*#__PURE__*/ _react.default.createElement(_react.Fragment, null, "Logging Out...");
|
|
86
|
+
};
|
|
87
|
+
|
|
88
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy9wYWdlcy9Mb2dvdXQvTG9nb3V0Q2xpZW50LnRzeCJdLCJzb3VyY2VzQ29udGVudCI6WyIndXNlIGNsaWVudCdcbmltcG9ydCB7IEJ1dHRvbiwgdXNlVHJhbnNsYXRpb24gfSBmcm9tICdAcGF5bG9hZGNtcy91aSdcbmltcG9ydCBMaW5rIGZyb20gJ25leHQvbGluaydcbmltcG9ydCBSZWFjdCwgeyBGcm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'./index.scss';
|
|
5
|
+
export declare const generateMetadata: ({ config: configPromise, }: {
|
|
6
|
+
config: Promise<SanitizedConfig>;
|
|
7
|
+
}) => Promise<Metadata>;
|
|
8
|
+
export declare const Logout: React.FC<{
|
|
9
|
+
config: Promise<SanitizedConfig>;
|
|
10
|
+
inactivity?: boolean;
|
|
11
|
+
searchParams: {
|
|
12
|
+
[key: string]: string | string[];
|
|
13
|
+
};
|
|
14
|
+
}>;
|
|
15
|
+
export default Logout;
|
|
16
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/pages/Logout/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,MAAM,CAAA;AACpC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAA;AAGpD,OAAO,KAAK,MAAM,OAAO,CAAA;AAKzB,OAAO,cAAc,CAAA;AAIrB,eAAO,MAAM,gBAAgB,+BAE1B;IACD,MAAM,EAAE,QAAQ,eAAe,CAAC,CAAA;CACjC,KAAG,QAAQ,QAAQ,CAanB,CAAA;AAED,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC;IAC5B,MAAM,EAAE,OAAO,CAAC,eAAe,CAAC,CAAA;IAChC,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,YAAY,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,EAAE,CAAA;KAAE,CAAA;CACnD,CAkBA,CAAA;AAED,eAAe,MAAM,CAAA"}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
function _export(target, all) {
|
|
6
|
+
for(var name in all)Object.defineProperty(target, name, {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: all[name]
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
_export(exports, {
|
|
12
|
+
Logout: function() {
|
|
13
|
+
return Logout;
|
|
14
|
+
},
|
|
15
|
+
default: function() {
|
|
16
|
+
return _default;
|
|
17
|
+
},
|
|
18
|
+
generateMetadata: function() {
|
|
19
|
+
return generateMetadata;
|
|
20
|
+
}
|
|
21
|
+
});
|
|
22
|
+
const _ui = require("@payloadcms/ui");
|
|
23
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
24
|
+
const _getNextI18n = require("../../utilities/getNextI18n");
|
|
25
|
+
const _meta = require("../../utilities/meta");
|
|
26
|
+
const _LogoutClient = require("./LogoutClient");
|
|
27
|
+
require("./index.scss");
|
|
28
|
+
function _interop_require_default(obj) {
|
|
29
|
+
return obj && obj.__esModule ? obj : {
|
|
30
|
+
default: obj
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
const baseClass = 'logout';
|
|
34
|
+
const generateMetadata = async ({ config: configPromise })=>{
|
|
35
|
+
const config = await configPromise;
|
|
36
|
+
const { t } = await (0, _getNextI18n.getNextI18n)({
|
|
37
|
+
config
|
|
38
|
+
});
|
|
39
|
+
return (0, _meta.meta)({
|
|
40
|
+
config,
|
|
41
|
+
description: `${t('authentication:logoutUser')}`,
|
|
42
|
+
keywords: `${t('authentication:logout')}`,
|
|
43
|
+
title: t('authentication:logout')
|
|
44
|
+
});
|
|
45
|
+
};
|
|
46
|
+
const Logout = async ({ config: configPromise, inactivity, searchParams })=>{
|
|
47
|
+
const config = await configPromise;
|
|
48
|
+
const { routes: { admin } } = config;
|
|
49
|
+
return /*#__PURE__*/ _react.default.createElement(_ui.MinimalTemplate, {
|
|
50
|
+
className: baseClass
|
|
51
|
+
}, /*#__PURE__*/ _react.default.createElement("div", {
|
|
52
|
+
className: `${baseClass}__wrap`
|
|
53
|
+
}, /*#__PURE__*/ _react.default.createElement(_LogoutClient.LogoutClient, {
|
|
54
|
+
adminRoute: admin,
|
|
55
|
+
inactivity: inactivity,
|
|
56
|
+
redirect: searchParams.redirect
|
|
57
|
+
})));
|
|
58
|
+
};
|
|
59
|
+
const _default = Logout;
|
|
60
|
+
|
|
61
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy9wYWdlcy9Mb2dvdXQvaW5kZXgudHN4Il0sInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB0eXBlIHsgTWV0YWRhdGEgfSBmcm9tICduZXh0J1xuaW1wb3J0IHR5cGUgeyBTYW5pdGl6ZWRDb25maWcgfSBmcm9tICdwYXlsb2FkL3R5cGVzJ1xuXG5pbXBvcnQgeyBNaW5pbWFsVGVtcGxhdGUgfSBmcm9tICdAcGF5bG9hZGNtcy91aSdcbmltcG9ydCBSZWFjdCBmcm9tICdyZWFjdCdcblxuaW1wb3J0IHsgZ2V0TmV4dEkxOG4gfSBmcm9tICcuLi8uLi91dGlsaXRpZXMvZ2V0TmV4dEkxOG4nXG5pbXBvcnQgeyBtZXRhIH0gZnJvbSAnLi4vLi4vdXRpbGl0aWVzL21ldGEnXG5pbXBvcnQgeyBMb2dvdXRDbGllbnQgfSBmcm9tICcuL0xvZ291dENsaWVudCdcbmltcG9ydCAnLi9pbmRleC5zY3NzJ1xuXG5jb25zdCBiYXNlQ2xhc3MgPSAnbG9nb3V0J1xuXG5leHBvcnQgY29uc3QgZ2VuZXJhdGVNZXRhZGF0YSA9IGFzeW5jICh7XG4gIGNvbmZpZzogY29uZmlnUHJvbWlzZSxcbn06IHtcbiAgY29uZmlnOiBQcm9taXNlPFNhbml0aXplZENvbmZpZz5cbn0pOiBQcm9taXNlPE1ldGFkYXRhPiA9PiB7XG4gIGNvbnN0IGNvbmZpZyA9IGF3YWl0IGNvbmZpZ1Byb21pc2VcblxuICBjb25zdCB7IHQgfSA9IGF3YWl0IGdldE5leHRJMThuKHtcbiAgICBjb25maWcsXG4gIH0pXG5cbiAgcmV0dXJuIG1ld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BRSxFQUNsQixHQUFHWDtJQUVKLHFCQUNFLDZCQUFDWSxtQkFBZTtRQUFDQyxXQUFXZDtxQkFDMUIsNkJBQUNlO1FBQUlELFdBQVcsQ0FBQyxFQUFFZCxVQUFVLE1BQU0sQ0FBQztxQkFDbEMsNkJBQUNnQiwwQkFBWTtRQUNYQyxZQUFZTDtRQUNaSCxZQUFZQTtRQUNaUyxVQUFVUixhQUFhUSxRQUFROztBQUt6QztNQUVBLFdBQWVwQiJ9
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/pages/NotFound/index.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAA;AAGzB,OAAO,cAAc,CAAA;AAIrB,QAAA,MAAM,QAAQ,EAAE,KAAK,CAAC,EAAE,CAAC;IACvB,SAAS,CAAC,EAAE,OAAO,CAAA;CACpB,CAsCA,CAAA;AAED,eAAe,QAAQ,CAAA"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
"use strict";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
Object.defineProperty(exports, "default", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function() {
|
|
9
|
+
return _default;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
const _ui = require("@payloadcms/ui");
|
|
13
|
+
const _react = /*#__PURE__*/ _interop_require_default(require("react"));
|
|
14
|
+
require("./index.scss");
|
|
15
|
+
function _interop_require_default(obj) {
|
|
16
|
+
return obj && obj.__esModule ? obj : {
|
|
17
|
+
default: obj
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
const baseClass = 'not-found';
|
|
21
|
+
const NotFound = (props)=>{
|
|
22
|
+
const { marginTop } = props;
|
|
23
|
+
const { setStepNav } = (0, _ui.useStepNav)();
|
|
24
|
+
const { t } = (0, _ui.useTranslation)();
|
|
25
|
+
const { routes: { admin } } = (0, _ui.useConfig)();
|
|
26
|
+
// useEffect(() => {
|
|
27
|
+
// setStepNav([
|
|
28
|
+
// {
|
|
29
|
+
// label: t('general:notFound'),
|
|
30
|
+
// },
|
|
31
|
+
// ])
|
|
32
|
+
// }, [setStepNav, t])
|
|
33
|
+
return /*#__PURE__*/ _react.default.createElement("div", {
|
|
34
|
+
className: [
|
|
35
|
+
baseClass,
|
|
36
|
+
marginTop && `${baseClass}--margin-top-${marginTop}`
|
|
37
|
+
].filter(Boolean).join(' ')
|
|
38
|
+
}, /*#__PURE__*/ _react.default.createElement(_ui.Gutter, {
|
|
39
|
+
className: `${baseClass}__wrap`
|
|
40
|
+
}, /*#__PURE__*/ _react.default.createElement("h1", null, t('general:nothingFound')), /*#__PURE__*/ _react.default.createElement("p", null, t('general:sorryNotFound')), /*#__PURE__*/ _react.default.createElement(_ui.Button, {
|
|
41
|
+
className: `${baseClass}__button`,
|
|
42
|
+
el: "link",
|
|
43
|
+
to: `${admin}`
|
|
44
|
+
}, t('general:backToDashboard'))));
|
|
45
|
+
};
|
|
46
|
+
const _default = NotFound;
|
|
47
|
+
|
|
48
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy9wYWdlcy9Ob3RGb3VuZC9pbmRleC50c3giXSwic291cmNlc0NvbnRlbnQiOlsiJ3VzZSBjbGllbnQnXG5pbXBvcnQgeyBCdXR0b24sIEd1dHRlciwgdXNlQ29uZmlnLCB1c2VTdGVwTmF2LCB1c2VUcmFuc2xhdGlvbiB9IGZyb20gJ0BwYXlsb2FkY21zL3VpJ1xuaW1wb3J0IFJlYWN0IGZyb20gJ3JlYWN0J1xuXG4vLyBpbXBvcnQgTWV0YSBmcm9tICcuLi8uLi91dGlsaXRpZXMvTWV0YSdcbmltcG9ydCAnLi9pbmRleC5zY3NzJ1xuXG5jb25zdCBiYXNlQ2xhc3MgPSAnbm90LW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ztJQUN0QyxTQUFTO0lBQ1QsT0FBTztJQUNQLHNCQUFzQjtJQUV0QixxQkFDRSw2QkFBQ0M7UUFDQ0MsV0FBVztZQUFDWjtZQUFXRyxhQUFhLENBQUMsRUFBRUgsVUFBVSxhQUFhLEVBQUVHLFVBQVUsQ0FBQztTQUFDLENBQ3pFVSxNQUFNLENBQUNDLFNBQ1BDLElBQUksQ0FBQztxQkFPUiw2QkFBQ0MsVUFBTTtRQUFDSixXQUFXLENBQUMsRUFBRVosVUFBVSxNQUFNLENBQUM7cUJBQ3JDLDZCQUFDaUIsWUFBSVgsRUFBRSx3Q0FDUCw2QkFBQ1ksV0FBR1osRUFBRSx5Q0FDTiw2QkFBQ2EsVUFBTTtRQUFDUCxXQUFXLENBQUMsRUFBRVosVUFBVSxRQUFRLENBQUM7UUFBRW9CLElBQUc7UUFBT0MsSUFBSSxDQUFDLEVBQUVaLE1BQU0sQ0FBQztPQUNoRUgsRUFBRTtBQUtiO01BRUEsV0FBZUwifQ==
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
@import '../../scss/styles.scss';
|
|
2
|
+
|
|
3
|
+
.not-found {
|
|
4
|
+
margin-top: var(--base);
|
|
5
|
+
|
|
6
|
+
& > * {
|
|
7
|
+
&:first-child {
|
|
8
|
+
margin-top: 0;
|
|
9
|
+
}
|
|
10
|
+
&:last-child {
|
|
11
|
+
margin-bottom: 0;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
&__button {
|
|
16
|
+
margin: 0;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
&--margin-top-large {
|
|
20
|
+
margin-top: calc(var(--base) * 2);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
@include large-break {
|
|
24
|
+
&--margin-top-large {
|
|
25
|
+
margin-top: var(--base);
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
@include small-break {
|
|
30
|
+
margin-top: calc(var(--base) / 2);
|
|
31
|
+
|
|
32
|
+
&--margin-top-large {
|
|
33
|
+
margin-top: calc(var(--base) / 2);
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { Metadata } from 'next';
|
|
2
|
+
import type { SanitizedConfig } from 'payload/types';
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import './index.scss';
|
|
5
|
+
export declare const generateMetadata: ({ config: configPromise, }: {
|
|
6
|
+
config: Promise<SanitizedConfig>;
|
|
7
|
+
}) => Promise<Metadata>;
|
|
8
|
+
export declare const ResetPassword: React.FC<{
|
|
9
|
+
config: Promise<SanitizedConfig>;
|
|
10
|
+
token: string;
|
|
11
|
+
}>;
|
|
12
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/pages/ResetPassword/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,MAAM,CAAA;AACpC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAA;AAapD,OAAO,KAAK,MAAM,OAAO,CAAA;AAKzB,OAAO,cAAc,CAAA;AAIrB,eAAO,MAAM,gBAAgB,+BAE1B;IACD,MAAM,EAAE,QAAQ,eAAe,CAAC,CAAA;CACjC,KAAG,QAAQ,QAAQ,CAanB,CAAA;AAED,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC;IACnC,MAAM,EAAE,OAAO,CAAC,eAAe,CAAC,CAAA;IAChC,KAAK,EAAE,MAAM,CAAA;CACd,CAuEA,CAAA"}
|