payload 3.42.0 → 3.43.0-internal.c5bbc84

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.
Files changed (220) hide show
  1. package/dist/admin/functions/index.d.ts +8 -0
  2. package/dist/admin/functions/index.d.ts.map +1 -1
  3. package/dist/admin/functions/index.js.map +1 -1
  4. package/dist/admin/types.d.ts +1 -1
  5. package/dist/admin/types.d.ts.map +1 -1
  6. package/dist/admin/types.js.map +1 -1
  7. package/dist/admin/views/folderList.d.ts +14 -5
  8. package/dist/admin/views/folderList.d.ts.map +1 -1
  9. package/dist/admin/views/folderList.js.map +1 -1
  10. package/dist/auth/crypto.d.ts.map +1 -1
  11. package/dist/auth/crypto.js +6 -3
  12. package/dist/auth/crypto.js.map +1 -1
  13. package/dist/auth/operations/unlock.d.ts.map +1 -1
  14. package/dist/auth/operations/unlock.js +1 -2
  15. package/dist/auth/operations/unlock.js.map +1 -1
  16. package/dist/auth/strategies/local/authenticate.d.ts.map +1 -1
  17. package/dist/auth/strategies/local/authenticate.js +1 -0
  18. package/dist/auth/strategies/local/authenticate.js.map +1 -1
  19. package/dist/bin/index.js.map +1 -1
  20. package/dist/bin/migrate.d.ts.map +1 -1
  21. package/dist/bin/migrate.js +2 -2
  22. package/dist/bin/migrate.js.map +1 -1
  23. package/dist/collections/config/client.d.ts.map +1 -1
  24. package/dist/collections/config/client.js +3 -1
  25. package/dist/collections/config/client.js.map +1 -1
  26. package/dist/collections/dataloader.d.ts.map +1 -1
  27. package/dist/collections/dataloader.js +0 -1
  28. package/dist/collections/dataloader.js.map +1 -1
  29. package/dist/collections/operations/delete.d.ts.map +1 -1
  30. package/dist/collections/operations/delete.js +1 -2
  31. package/dist/collections/operations/delete.js.map +1 -1
  32. package/dist/collections/operations/findVersions.js +0 -1
  33. package/dist/collections/operations/findVersions.js.map +1 -1
  34. package/dist/collections/operations/update.d.ts.map +1 -1
  35. package/dist/collections/operations/update.js +3 -2
  36. package/dist/collections/operations/update.js.map +1 -1
  37. package/dist/config/client.d.ts.map +1 -1
  38. package/dist/config/client.js +1 -1
  39. package/dist/config/client.js.map +1 -1
  40. package/dist/config/sanitize.d.ts.map +1 -1
  41. package/dist/config/sanitize.js +1 -2
  42. package/dist/config/sanitize.js.map +1 -1
  43. package/dist/database/queryValidation/validateQueryPaths.d.ts.map +1 -1
  44. package/dist/database/queryValidation/validateQueryPaths.js +0 -1
  45. package/dist/database/queryValidation/validateQueryPaths.js.map +1 -1
  46. package/dist/database/queryValidation/validateSearchParams.d.ts.map +1 -1
  47. package/dist/database/queryValidation/validateSearchParams.js +0 -1
  48. package/dist/database/queryValidation/validateSearchParams.js.map +1 -1
  49. package/dist/database/sanitizeJoinQuery.d.ts.map +1 -1
  50. package/dist/database/sanitizeJoinQuery.js +3 -1
  51. package/dist/database/sanitizeJoinQuery.js.map +1 -1
  52. package/dist/fields/config/client.d.ts.map +1 -1
  53. package/dist/fields/config/client.js +6 -1
  54. package/dist/fields/config/client.js.map +1 -1
  55. package/dist/fields/config/sanitize.d.ts.map +1 -1
  56. package/dist/fields/config/sanitize.js +0 -1
  57. package/dist/fields/config/sanitize.js.map +1 -1
  58. package/dist/fields/hooks/afterRead/index.d.ts.map +1 -1
  59. package/dist/fields/hooks/afterRead/index.js +0 -1
  60. package/dist/fields/hooks/afterRead/index.js.map +1 -1
  61. package/dist/fields/hooks/afterRead/relationshipPopulationPromise.d.ts.map +1 -1
  62. package/dist/fields/hooks/afterRead/relationshipPopulationPromise.js +1 -2
  63. package/dist/fields/hooks/afterRead/relationshipPopulationPromise.js.map +1 -1
  64. package/dist/fields/hooks/beforeChange/promise.d.ts.map +1 -1
  65. package/dist/fields/hooks/beforeChange/promise.js +0 -1
  66. package/dist/fields/hooks/beforeChange/promise.js.map +1 -1
  67. package/dist/fields/setDefaultBeforeDuplicate.js.map +1 -1
  68. package/dist/fields/validations.d.ts.map +1 -1
  69. package/dist/fields/validations.js +1 -2
  70. package/dist/fields/validations.js.map +1 -1
  71. package/dist/folders/types.d.ts +2 -0
  72. package/dist/folders/types.d.ts.map +1 -1
  73. package/dist/folders/types.js.map +1 -1
  74. package/dist/globals/config/client.d.ts.map +1 -1
  75. package/dist/globals/config/client.js +2 -1
  76. package/dist/globals/config/client.js.map +1 -1
  77. package/dist/index.d.ts +1 -0
  78. package/dist/index.d.ts.map +1 -1
  79. package/dist/index.js +2 -3
  80. package/dist/index.js.map +1 -1
  81. package/dist/queues/operations/runJobs/index.d.ts.map +1 -1
  82. package/dist/queues/operations/runJobs/index.js +0 -1
  83. package/dist/queues/operations/runJobs/index.js.map +1 -1
  84. package/dist/queues/operations/runJobs/runJSONJob/index.d.ts.map +1 -1
  85. package/dist/queues/operations/runJobs/runJSONJob/index.js +2 -2
  86. package/dist/queues/operations/runJobs/runJSONJob/index.js.map +1 -1
  87. package/dist/queues/operations/runJobs/runJob/getRunTaskFunction.d.ts.map +1 -1
  88. package/dist/queues/operations/runJobs/runJob/getRunTaskFunction.js +0 -1
  89. package/dist/queues/operations/runJobs/runJob/getRunTaskFunction.js.map +1 -1
  90. package/dist/queues/operations/runJobs/runJob/getUpdateJobFunction.d.ts.map +1 -1
  91. package/dist/queues/operations/runJobs/runJob/getUpdateJobFunction.js +1 -1
  92. package/dist/queues/operations/runJobs/runJob/getUpdateJobFunction.js.map +1 -1
  93. package/dist/queues/operations/runJobs/runJob/importHandlerPath.d.ts.map +1 -1
  94. package/dist/queues/operations/runJobs/runJob/importHandlerPath.js +1 -2
  95. package/dist/queues/operations/runJobs/runJob/importHandlerPath.js.map +1 -1
  96. package/dist/queues/operations/runJobs/runJob/index.d.ts.map +1 -1
  97. package/dist/queues/operations/runJobs/runJob/index.js +2 -2
  98. package/dist/queues/operations/runJobs/runJob/index.js.map +1 -1
  99. package/dist/uploads/cropImage.d.ts +0 -1
  100. package/dist/uploads/cropImage.d.ts.map +1 -1
  101. package/dist/uploads/cropImage.js +2 -3
  102. package/dist/uploads/cropImage.js.map +1 -1
  103. package/dist/uploads/endpoints/getFile.d.ts.map +1 -1
  104. package/dist/uploads/endpoints/getFile.js +0 -1
  105. package/dist/uploads/endpoints/getFile.js.map +1 -1
  106. package/dist/uploads/endpoints/getFileFromURL.d.ts.map +1 -1
  107. package/dist/uploads/endpoints/getFileFromURL.js +2 -3
  108. package/dist/uploads/endpoints/getFileFromURL.js.map +1 -1
  109. package/dist/uploads/fetchAPI-multipart/fileFactory.d.ts.map +1 -1
  110. package/dist/uploads/fetchAPI-multipart/fileFactory.js +1 -0
  111. package/dist/uploads/fetchAPI-multipart/fileFactory.js.map +1 -1
  112. package/dist/uploads/fetchAPI-multipart/processMultipart.d.ts +6 -0
  113. package/dist/uploads/fetchAPI-multipart/processMultipart.d.ts.map +1 -1
  114. package/dist/uploads/fetchAPI-multipart/processMultipart.js +0 -1
  115. package/dist/uploads/fetchAPI-multipart/processMultipart.js.map +1 -1
  116. package/dist/uploads/fetchAPI-multipart/processNested.d.ts +1 -1
  117. package/dist/uploads/fetchAPI-multipart/processNested.d.ts.map +1 -1
  118. package/dist/uploads/fetchAPI-multipart/processNested.js +0 -1
  119. package/dist/uploads/fetchAPI-multipart/processNested.js.map +1 -1
  120. package/dist/uploads/fetchAPI-multipart/utilities.d.ts +1 -1
  121. package/dist/uploads/fetchAPI-multipart/utilities.d.ts.map +1 -1
  122. package/dist/uploads/fetchAPI-multipart/utilities.js +0 -1
  123. package/dist/uploads/fetchAPI-multipart/utilities.js.map +1 -1
  124. package/dist/uploads/fetchAPI-stream-file/index.d.ts +1 -1
  125. package/dist/uploads/fetchAPI-stream-file/index.d.ts.map +1 -1
  126. package/dist/uploads/fetchAPI-stream-file/index.js +0 -1
  127. package/dist/uploads/fetchAPI-stream-file/index.js.map +1 -1
  128. package/dist/uploads/tempFile.d.ts +1 -1
  129. package/dist/uploads/tempFile.d.ts.map +1 -1
  130. package/dist/uploads/tempFile.js +0 -1
  131. package/dist/uploads/tempFile.js.map +1 -1
  132. package/dist/utilities/addLocalesToRequest.d.ts.map +1 -1
  133. package/dist/utilities/addLocalesToRequest.js +0 -1
  134. package/dist/utilities/addLocalesToRequest.js.map +1 -1
  135. package/dist/utilities/configToJSONSchema.d.ts.map +1 -1
  136. package/dist/utilities/configToJSONSchema.js +2 -1
  137. package/dist/utilities/configToJSONSchema.js.map +1 -1
  138. package/dist/utilities/deepCopyObject.js +1 -2
  139. package/dist/utilities/deepCopyObject.js.map +1 -1
  140. package/dist/utilities/fieldSchemaToJSON.d.ts.map +1 -1
  141. package/dist/utilities/fieldSchemaToJSON.js +0 -1
  142. package/dist/utilities/fieldSchemaToJSON.js.map +1 -1
  143. package/dist/utilities/flattenTopLevelFields.d.ts.map +1 -1
  144. package/dist/utilities/flattenTopLevelFields.js +0 -1
  145. package/dist/utilities/flattenTopLevelFields.js.map +1 -1
  146. package/dist/utilities/formatErrors.d.ts.map +1 -1
  147. package/dist/utilities/formatErrors.js +0 -1
  148. package/dist/utilities/formatErrors.js.map +1 -1
  149. package/dist/utilities/getCollectionIDFieldTypes.d.ts.map +1 -1
  150. package/dist/utilities/getCollectionIDFieldTypes.js +0 -1
  151. package/dist/utilities/getCollectionIDFieldTypes.js.map +1 -1
  152. package/dist/utilities/getDataByPath.d.ts.map +1 -1
  153. package/dist/utilities/getDataByPath.js +0 -1
  154. package/dist/utilities/getDataByPath.js.map +1 -1
  155. package/dist/utilities/getEntityPolicies.d.ts.map +1 -1
  156. package/dist/utilities/getEntityPolicies.js +3 -2
  157. package/dist/utilities/getEntityPolicies.js.map +1 -1
  158. package/dist/utilities/getFieldPermissions.d.ts.map +1 -1
  159. package/dist/utilities/getFieldPermissions.js +2 -3
  160. package/dist/utilities/getFieldPermissions.js.map +1 -1
  161. package/dist/utilities/getObjectDotNotation.d.ts.map +1 -1
  162. package/dist/utilities/getObjectDotNotation.js +0 -1
  163. package/dist/utilities/getObjectDotNotation.js.map +1 -1
  164. package/dist/utilities/getSiblingData.d.ts.map +1 -1
  165. package/dist/utilities/getSiblingData.js +0 -1
  166. package/dist/utilities/getSiblingData.js.map +1 -1
  167. package/dist/utilities/getUniqueListBy.d.ts.map +1 -1
  168. package/dist/utilities/getUniqueListBy.js +0 -1
  169. package/dist/utilities/getUniqueListBy.js.map +1 -1
  170. package/dist/utilities/handleEndpoints.d.ts.map +1 -1
  171. package/dist/utilities/handleEndpoints.js +2 -2
  172. package/dist/utilities/handleEndpoints.js.map +1 -1
  173. package/dist/utilities/logError.d.ts.map +1 -1
  174. package/dist/utilities/logError.js +0 -1
  175. package/dist/utilities/logError.js.map +1 -1
  176. package/dist/utilities/reduceFieldsToValues.d.ts.map +1 -1
  177. package/dist/utilities/reduceFieldsToValues.js +0 -1
  178. package/dist/utilities/reduceFieldsToValues.js.map +1 -1
  179. package/dist/utilities/sanitizeJoinParams.d.ts +1 -1
  180. package/dist/utilities/sanitizeJoinParams.d.ts.map +1 -1
  181. package/dist/utilities/sanitizeJoinParams.js +2 -2
  182. package/dist/utilities/sanitizeJoinParams.js.map +1 -1
  183. package/dist/utilities/sanitizePermissions.d.ts.map +1 -1
  184. package/dist/utilities/sanitizePermissions.js +2 -2
  185. package/dist/utilities/sanitizePermissions.js.map +1 -1
  186. package/dist/utilities/sanitizePopulateParam.d.ts.map +1 -1
  187. package/dist/utilities/sanitizePopulateParam.js +1 -1
  188. package/dist/utilities/sanitizePopulateParam.js.map +1 -1
  189. package/dist/utilities/sanitizeSelectParam.d.ts.map +1 -1
  190. package/dist/utilities/sanitizeSelectParam.js +4 -2
  191. package/dist/utilities/sanitizeSelectParam.js.map +1 -1
  192. package/dist/utilities/telemetry/conf/envPaths.d.ts +1 -1
  193. package/dist/utilities/telemetry/conf/envPaths.d.ts.map +1 -1
  194. package/dist/utilities/telemetry/conf/envPaths.js.map +1 -1
  195. package/dist/utilities/timestamp.d.ts +1 -1
  196. package/dist/utilities/timestamp.d.ts.map +1 -1
  197. package/dist/utilities/timestamp.js +0 -1
  198. package/dist/utilities/timestamp.js.map +1 -1
  199. package/dist/utilities/traverseFields.d.ts.map +1 -1
  200. package/dist/utilities/traverseFields.js +6 -1
  201. package/dist/utilities/traverseFields.js.map +1 -1
  202. package/dist/utilities/unflatten.d.ts.map +1 -1
  203. package/dist/utilities/unflatten.js +1 -2
  204. package/dist/utilities/unflatten.js.map +1 -1
  205. package/dist/utilities/wait.d.ts +1 -1
  206. package/dist/utilities/wait.d.ts.map +1 -1
  207. package/dist/utilities/wait.js +0 -1
  208. package/dist/utilities/wait.js.map +1 -1
  209. package/dist/versions/baseFields.d.ts +2 -7
  210. package/dist/versions/baseFields.d.ts.map +1 -1
  211. package/dist/versions/baseFields.js.map +1 -1
  212. package/dist/versions/drafts/replaceWithDraftIfAvailable.d.ts.map +1 -1
  213. package/dist/versions/drafts/replaceWithDraftIfAvailable.js +1 -0
  214. package/dist/versions/drafts/replaceWithDraftIfAvailable.js.map +1 -1
  215. package/dist/versions/getLatestGlobalVersion.d.ts.map +1 -1
  216. package/dist/versions/getLatestGlobalVersion.js +3 -1
  217. package/dist/versions/getLatestGlobalVersion.js.map +1 -1
  218. package/dist/versions/saveVersion.js +1 -1
  219. package/dist/versions/saveVersion.js.map +1 -1
  220. package/package.json +3 -5
@@ -54,4 +54,12 @@ export type BuildTableStateArgs = {
54
54
  export type BuildCollectionFolderViewResult = {
55
55
  View: React.ReactNode;
56
56
  };
57
+ export type GetFolderResultsComponentAndDataArgs = {
58
+ activeCollectionSlugs: CollectionSlug[];
59
+ browseByFolder: boolean;
60
+ displayAs: 'grid' | 'list';
61
+ folderID: number | string | undefined;
62
+ req: PayloadRequest;
63
+ sort: string;
64
+ };
57
65
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/admin/functions/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sCAAsC,CAAA;AACrE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAC5D,OAAO,KAAK,EAAE,aAAa,EAAE,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AM,CAAA;IAIxB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,IAAI,CAAC,EAAE,IAAI,CAAA;IACX,KAAK,CAAC,EAAE,KAAK,CAAA;CACd,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;AAE3B,MAAM,MAAM,mBAAmB,GAAG;IAChC,cAAc,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;IACjC,OAAO,CAAC,EAAE,gBAAgB,EAAE,CAAA;IAC5B,IAAI,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAA;IAC5B,mBAAmB,CAAC,EAAE,OAAO,CAAA;IAC7B,kBAAkB,EAAE,MAAM,CAAA;IAC1B,MAAM,CAAC,EAAE;QACP,cAAc,EAAE,cAAc,CAAA;QAC9B,EAAE,EAAE,MAAM,GAAG,MAAM,CAAA;QACnB,QAAQ,EAAE,MAAM,CAAA;KACjB,CAAA;IACD,KAAK,CAAC,EAAE,SAAS,CAAA;IACjB,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,GAAG,EAAE,cAAc,CAAA;IACnB,eAAe,CAAC,EAAE,WAAW,GAAG,SAAS,CAAA;CAC1C,CAAA;AAED,MAAM,MAAM,+BAA+B,GAAG;IAC5C,IAAI,EAAE,KAAK,CAAC,SAAS,CAAA;CACtB,CAAA;AAED,MAAM,MAAM,oCAAoC,GAAG;IACjD,qBAAqB,EAAE,cAAc,EAAE,CAAA;IACvC,cAAc,EAAE,OAAO,CAAA;IACvB,SAAS,EAAE,MAAM,GAAG,MAAM,CAAA;IAC1B,QAAQ,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAA;IACrC,GAAG,EAAE,cAAc,CAAA;IACnB,IAAI,EAAE,MAAM,CAAA;CACb,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/admin/functions/index.ts"],"sourcesContent":["import type { ImportMap } from '../../bin/generateImportMap/index.js'\nimport type { SanitizedConfig } from '../../config/types.js'\nimport type { PaginatedDocs } from '../../database/types.js'\nimport type { CollectionSlug, ColumnPreference } from '../../index.js'\nimport type { PayloadRequest, Sort, Where } from '../../types/index.js'\nimport type { ColumnsFromURL } from '../../utilities/transformColumnPreferences.js'\n\nexport type DefaultServerFunctionArgs = {\n importMap: ImportMap\n req: PayloadRequest\n}\n\nexport type ServerFunctionArgs = {\n args: Record<string, unknown>\n name: string\n}\n\nexport type ServerFunctionClientArgs = {\n args: Record<string, unknown>\n name: string\n}\n\nexport type ServerFunctionClient = (args: ServerFunctionClientArgs) => Promise<unknown> | unknown\n\nexport type ServerFunction = (\n args: DefaultServerFunctionArgs & ServerFunctionClientArgs['args'],\n) => Promise<unknown> | unknown\n\nexport type ServerFunctionConfig = {\n fn: ServerFunction\n name: string\n}\n\nexport type ServerFunctionHandler = (\n args: {\n config: Promise<SanitizedConfig> | SanitizedConfig\n importMap: ImportMap\n } & ServerFunctionClientArgs,\n) => Promise<unknown>\n\nexport type ListQuery = {\n /*\n * This is an of strings, i.e. `['title', '-slug']`\n * Use `transformColumnsToPreferences` and `transformColumnsToSearchParams` to convert it back and forth\n */\n columns?: ColumnsFromURL\n limit?: string\n page?: string\n preset?: number | string\n /*\n When provided, is automatically injected into the `where` object\n */\n search?: string\n sort?: Sort\n where?: Where\n} & Record<string, unknown>\n\nexport type BuildTableStateArgs = {\n collectionSlug: string | string[]\n columns?: ColumnPreference[]\n docs?: PaginatedDocs['docs']\n enableRowSelections?: boolean\n orderableFieldName: string\n parent?: {\n collectionSlug: CollectionSlug\n id: number | string\n joinPath: string\n }\n query?: ListQuery\n renderRowTypes?: boolean\n req: PayloadRequest\n tableAppearance?: 'condensed' | 'default'\n}\n\nexport type BuildCollectionFolderViewResult = {\n View: React.ReactNode\n}\n"],"names":[],"mappings":"AA0EA,WAEC"}
1
+ {"version":3,"sources":["../../../src/admin/functions/index.ts"],"sourcesContent":["import type { ImportMap } from '../../bin/generateImportMap/index.js'\nimport type { SanitizedConfig } from '../../config/types.js'\nimport type { PaginatedDocs } from '../../database/types.js'\nimport type { CollectionSlug, ColumnPreference } from '../../index.js'\nimport type { PayloadRequest, Sort, Where } from '../../types/index.js'\nimport type { ColumnsFromURL } from '../../utilities/transformColumnPreferences.js'\n\nexport type DefaultServerFunctionArgs = {\n importMap: ImportMap\n req: PayloadRequest\n}\n\nexport type ServerFunctionArgs = {\n args: Record<string, unknown>\n name: string\n}\n\nexport type ServerFunctionClientArgs = {\n args: Record<string, unknown>\n name: string\n}\n\nexport type ServerFunctionClient = (args: ServerFunctionClientArgs) => Promise<unknown> | unknown\n\nexport type ServerFunction = (\n args: DefaultServerFunctionArgs & ServerFunctionClientArgs['args'],\n) => Promise<unknown> | unknown\n\nexport type ServerFunctionConfig = {\n fn: ServerFunction\n name: string\n}\n\nexport type ServerFunctionHandler = (\n args: {\n config: Promise<SanitizedConfig> | SanitizedConfig\n importMap: ImportMap\n } & ServerFunctionClientArgs,\n) => Promise<unknown>\n\nexport type ListQuery = {\n /*\n * This is an of strings, i.e. `['title', '-slug']`\n * Use `transformColumnsToPreferences` and `transformColumnsToSearchParams` to convert it back and forth\n */\n columns?: ColumnsFromURL\n limit?: string\n page?: string\n preset?: number | string\n /*\n When provided, is automatically injected into the `where` object\n */\n search?: string\n sort?: Sort\n where?: Where\n} & Record<string, unknown>\n\nexport type BuildTableStateArgs = {\n collectionSlug: string | string[]\n columns?: ColumnPreference[]\n docs?: PaginatedDocs['docs']\n enableRowSelections?: boolean\n orderableFieldName: string\n parent?: {\n collectionSlug: CollectionSlug\n id: number | string\n joinPath: string\n }\n query?: ListQuery\n renderRowTypes?: boolean\n req: PayloadRequest\n tableAppearance?: 'condensed' | 'default'\n}\n\nexport type BuildCollectionFolderViewResult = {\n View: React.ReactNode\n}\n\nexport type GetFolderResultsComponentAndDataArgs = {\n activeCollectionSlugs: CollectionSlug[]\n browseByFolder: boolean\n displayAs: 'grid' | 'list'\n folderID: number | string | undefined\n req: PayloadRequest\n sort: string\n}\n"],"names":[],"mappings":"AA8EA,WAOC"}
@@ -144,7 +144,7 @@ export type DocumentSlots = {
144
144
  SaveDraftButton?: React.ReactNode;
145
145
  Upload?: React.ReactNode;
146
146
  };
147
- export type { BuildCollectionFolderViewResult, BuildTableStateArgs, DefaultServerFunctionArgs, ListQuery, ServerFunction, ServerFunctionArgs, ServerFunctionClient, ServerFunctionClientArgs, ServerFunctionConfig, ServerFunctionHandler, } from './functions/index.js';
147
+ export type { BuildCollectionFolderViewResult, BuildTableStateArgs, DefaultServerFunctionArgs, GetFolderResultsComponentAndDataArgs, ListQuery, ServerFunction, ServerFunctionArgs, ServerFunctionClient, ServerFunctionClientArgs, ServerFunctionConfig, ServerFunctionHandler, } from './functions/index.js';
148
148
  export type { LanguageOptions } from './LanguageOptions.js';
149
149
  export type { RichTextAdapter, RichTextAdapterProvider, RichTextHooks } from './RichText.js';
150
150
  export type { BeforeDocumentControlsClientProps, BeforeDocumentControlsServerProps, BeforeDocumentControlsServerPropsOnly, DocumentSubViewTypes, DocumentTabClientProps,
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/admin/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAA;AAC7E,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mCAAmC,CAAA;AAClE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAA;AACzD,OAAO,KAAK,EACV,KAAK,EACL,WAAW,EACX,WAAW,EACX,KAAK,EACL,UAAU,EACV,GAAG,EACJ,MAAM,2BAA2B,CAAA;AAClC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AACnD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAA;AACjD,OAAO,KAAK,EACV,kBAAkB,EAClB,IAAI,EACJ,UAAU,EACV,2BAA2B,EAC3B,mBAAmB,EACnB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AkB,EAClB,eAAe;AACf;;;;GAIG;AACH,oBAAoB,IAAI,cAAc,EACtC,oBAAoB,EACpB,wBAAwB,EACxB,cAAc,EACd,mBAAmB,EACnB,0BAA0B,EAC1B,0BAA0B,EAC1B,8BAA8B,EAC9B,SAAS,EACT,eAAe,GAChB,MAAM,kBAAkB,CAAA;AAEzB,YAAY,EACV,oBAAoB,EACpB,oBAAoB,EACpB,wBAAwB,EACxB,yBAAyB,EACzB,yBAAyB,EACzB,6BAA6B,EAC7B,qBAAqB,EACrB,qBAAqB,EACrB,yBAAyB,EACzB,0BAA0B,EAC1B,0BAA0B,EAC1B,8BAA8B,EAC9B,mBAAmB,EACnB,mBAAmB,EACnB,uBAAuB,EACvB,aAAa,EACb,6BAA6B,GAC9B,MAAM,iBAAiB,CAAA;AAExB,KAAK,UAAU,GAAG,EAAE,GAAG,MAAM,CAAA;AAC7B,MAAM,MAAM,cAAc,GAAG,GAAG,CAC9B,UAAU,EACR;IACE,MAAM,EAAE,KAAK,EAAE,CAAA;CAChB,GACD,KAAK,GACL,KAAK,GACL,GAAG,CACN,CAAA;AAED,MAAM,MAAM,oBAAoB,GAAG,GAAG,CACpC,UAAU,EACR;IACE,MAAM,EAAE,WAAW,EAAE,CAAA;CACtB,GACD,WAAW,GACX,WAAW,GACX,SAAS,CACZ,CAAA;AAED,MAAM,MAAM,aAAa,GAAG;IAC1B,UAAU,EAAE,MAAM,CAAA;IAClB,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IACpB,SAAS,EAAE,MAAM,CAAA;CAClB,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/admin/types.ts"],"sourcesContent":["import type { AcceptedLanguages, I18nClient } from '@payloadcms/translations'\nimport type React from 'react'\n\nimport type { ImportMap } from '../bin/generateImportMap/index.js'\nimport type { SanitizedConfig } from '../config/types.js'\nimport type {\n Block,\n ClientBlock,\n ClientField,\n Field,\n FieldTypes,\n Tab,\n} from '../fields/config/types.js'\nimport type { JsonObject } from '../types/index.js'\nimport type { ClientTab } from './fields/Tabs.js'\nimport type {\n BuildFormStateArgs,\n Data,\n FieldState,\n FieldStateWithoutComponents,\n FilterOptionsResult,\n FormState,\n FormStateWithoutComponents,\n Row,\n} from './forms/Form.js'\n\nexport type {\n /**\n * @deprecated\n * The `CustomPreviewButton` type is deprecated and will be removed in the next major version.\n * This type is only used for the Payload Config. Use `PreviewButtonClientProps` instead.\n */\n CustomComponent as CustomPreviewButton,\n /**\n * @deprecated\n * The `CustomPublishButton` type is deprecated and will be removed in the next major version.\n * This type is only used for the Payload Config. Use `PreviewButtonClientProps` instead.\n */\n CustomComponent as CustomPublishButton,\n /**\n * @deprecated\n * The `CustomSaveButton` type is deprecated and will be removed in the next major version.\n * This type is only used for the Payload Config. Use `PreviewButtonClientProps` instead.\n */\n CustomComponent as CustomSaveButton,\n /**\n * @deprecated\n * The `CustomSaveDraftButton` type is deprecated and will be removed in the next major version.\n * This type is only used for the Payload Config. Use `PreviewButtonClientProps` instead.\n */\n CustomComponent as CustomSaveDraftButton,\n} from '../config/types.js'\nexport type { DefaultCellComponentProps, DefaultServerCellComponentProps } from './elements/Cell.js'\nexport type { ConditionalDateProps } from './elements/DatePicker.js'\nexport type { DayPickerProps, SharedProps, TimePickerProps } from './elements/DatePicker.js'\nexport type {\n EditMenuItemsClientProps,\n EditMenuItemsServerProps,\n EditMenuItemsServerPropsOnly,\n} from './elements/EditMenuItems.js'\nexport type { NavGroupPreferences, NavPreferences } from './elements/Nav.js'\nexport type {\n PreviewButtonClientProps,\n PreviewButtonServerProps,\n PreviewButtonServerPropsOnly,\n} from './elements/PreviewButton.js'\nexport type {\n PublishButtonClientProps,\n PublishButtonServerProps,\n PublishButtonServerPropsOnly,\n} from './elements/PublishButton.js'\nexport type {\n SaveButtonClientProps,\n SaveButtonServerProps,\n SaveButtonServerPropsOnly,\n} from './elements/SaveButton.js'\nexport type {\n SaveDraftButtonClientProps,\n SaveDraftButtonServerProps,\n SaveDraftButtonServerPropsOnly,\n} from './elements/SaveDraftButton.js'\n\nexport type { Column } from './elements/Table.js'\n\nexport type { CustomUpload } from './elements/Upload.js'\n\nexport type {\n WithServerSidePropsComponent,\n WithServerSidePropsComponentProps,\n} from './elements/WithServerSideProps.js'\n\nexport type {\n ArrayFieldClientComponent,\n ArrayFieldClientProps,\n ArrayFieldDescriptionClientComponent,\n ArrayFieldDescriptionServerComponent,\n ArrayFieldDiffClientComponent,\n ArrayFieldDiffServerComponent,\n ArrayFieldErrorClientComponent,\n ArrayFieldErrorServerComponent,\n ArrayFieldLabelClientComponent,\n ArrayFieldLabelServerComponent,\n ArrayFieldServerComponent,\n ArrayFieldServerProps,\n} from './fields/Array.js'\n\nexport type {\n BlockRowLabelClientComponent,\n BlockRowLabelServerComponent,\n BlocksFieldClientComponent,\n BlocksFieldClientProps,\n BlocksFieldDescriptionClientComponent,\n BlocksFieldDescriptionServerComponent,\n BlocksFieldDiffClientComponent,\n BlocksFieldDiffServerComponent,\n BlocksFieldErrorClientComponent,\n BlocksFieldErrorServerComponent,\n BlocksFieldLabelClientComponent,\n BlocksFieldLabelServerComponent,\n BlocksFieldServerComponent,\n BlocksFieldServerProps,\n} from './fields/Blocks.js'\n\nexport type {\n CheckboxFieldClientComponent,\n CheckboxFieldClientProps,\n CheckboxFieldDescriptionClientComponent,\n CheckboxFieldDescriptionServerComponent,\n CheckboxFieldDiffClientComponent,\n CheckboxFieldDiffServerComponent,\n CheckboxFieldErrorClientComponent,\n CheckboxFieldErrorServerComponent,\n CheckboxFieldLabelClientComponent,\n CheckboxFieldLabelServerComponent,\n CheckboxFieldServerComponent,\n CheckboxFieldServerProps,\n} from './fields/Checkbox.js'\n\nexport type {\n CodeFieldClientComponent,\n CodeFieldClientProps,\n CodeFieldDescriptionClientComponent,\n CodeFieldDescriptionServerComponent,\n CodeFieldDiffClientComponent,\n CodeFieldDiffServerComponent,\n CodeFieldErrorClientComponent,\n CodeFieldErrorServerComponent,\n CodeFieldLabelClientComponent,\n CodeFieldLabelServerComponent,\n CodeFieldServerComponent,\n CodeFieldServerProps,\n} from './fields/Code.js'\n\nexport type {\n CollapsibleFieldClientComponent,\n CollapsibleFieldClientProps,\n CollapsibleFieldDescriptionClientComponent,\n CollapsibleFieldDescriptionServerComponent,\n CollapsibleFieldDiffClientComponent,\n CollapsibleFieldDiffServerComponent,\n CollapsibleFieldErrorClientComponent,\n CollapsibleFieldErrorServerComponent,\n CollapsibleFieldLabelClientComponent,\n CollapsibleFieldLabelServerComponent,\n CollapsibleFieldServerComponent,\n CollapsibleFieldServerProps,\n} from './fields/Collapsible.js'\n\nexport type {\n DateFieldClientComponent,\n DateFieldClientProps,\n DateFieldDescriptionClientComponent,\n DateFieldDescriptionServerComponent,\n DateFieldDiffClientComponent,\n DateFieldDiffServerComponent,\n DateFieldErrorClientComponent,\n DateFieldErrorServerComponent,\n DateFieldLabelClientComponent,\n DateFieldLabelServerComponent,\n DateFieldServerComponent,\n DateFieldServerProps,\n} from './fields/Date.js'\n\nexport type {\n EmailFieldClientComponent,\n EmailFieldClientProps,\n EmailFieldDescriptionClientComponent,\n EmailFieldDescriptionServerComponent,\n EmailFieldDiffClientComponent,\n EmailFieldDiffServerComponent,\n EmailFieldErrorClientComponent,\n EmailFieldErrorServerComponent,\n EmailFieldLabelClientComponent,\n EmailFieldLabelServerComponent,\n EmailFieldServerComponent,\n EmailFieldServerProps,\n} from './fields/Email.js'\n\nexport type {\n GroupFieldClientComponent,\n GroupFieldClientProps,\n GroupFieldDescriptionClientComponent,\n GroupFieldDescriptionServerComponent,\n GroupFieldDiffClientComponent,\n GroupFieldDiffServerComponent,\n GroupFieldErrorClientComponent,\n GroupFieldErrorServerComponent,\n GroupFieldLabelClientComponent,\n GroupFieldLabelServerComponent,\n GroupFieldServerComponent,\n GroupFieldServerProps,\n} from './fields/Group.js'\n\nexport type { HiddenFieldProps } from './fields/Hidden.js'\n\nexport type {\n JoinFieldClientComponent,\n JoinFieldClientProps,\n JoinFieldDescriptionClientComponent,\n JoinFieldDescriptionServerComponent,\n JoinFieldDiffClientComponent,\n JoinFieldDiffServerComponent,\n JoinFieldErrorClientComponent,\n JoinFieldErrorServerComponent,\n JoinFieldLabelClientComponent,\n JoinFieldLabelServerComponent,\n JoinFieldServerComponent,\n JoinFieldServerProps,\n} from './fields/Join.js'\n\nexport type {\n JSONFieldClientComponent,\n JSONFieldClientProps,\n JSONFieldDescriptionClientComponent,\n JSONFieldDescriptionServerComponent,\n JSONFieldDiffClientComponent,\n JSONFieldDiffServerComponent,\n JSONFieldErrorClientComponent,\n JSONFieldErrorServerComponent,\n JSONFieldLabelClientComponent,\n JSONFieldLabelServerComponent,\n JSONFieldServerComponent,\n JSONFieldServerProps,\n} from './fields/JSON.js'\n\nexport type {\n NumberFieldClientComponent,\n NumberFieldClientProps,\n NumberFieldDescriptionClientComponent,\n NumberFieldDescriptionServerComponent,\n NumberFieldDiffClientComponent,\n NumberFieldDiffServerComponent,\n NumberFieldErrorClientComponent,\n NumberFieldErrorServerComponent,\n NumberFieldLabelClientComponent,\n NumberFieldLabelServerComponent,\n NumberFieldServerComponent,\n NumberFieldServerProps,\n} from './fields/Number.js'\n\nexport type {\n PointFieldClientComponent,\n PointFieldClientProps,\n PointFieldDescriptionClientComponent,\n PointFieldDescriptionServerComponent,\n PointFieldDiffClientComponent,\n PointFieldDiffServerComponent,\n PointFieldErrorClientComponent,\n PointFieldErrorServerComponent,\n PointFieldLabelClientComponent,\n PointFieldLabelServerComponent,\n PointFieldServerComponent,\n PointFieldServerProps,\n} from './fields/Point.js'\n\nexport type {\n RadioFieldClientComponent,\n RadioFieldClientProps,\n RadioFieldDescriptionClientComponent,\n RadioFieldDescriptionServerComponent,\n RadioFieldDiffClientComponent,\n RadioFieldDiffServerComponent,\n RadioFieldErrorClientComponent,\n RadioFieldErrorServerComponent,\n RadioFieldLabelClientComponent,\n RadioFieldLabelServerComponent,\n RadioFieldServerComponent,\n RadioFieldServerProps,\n} from './fields/Radio.js'\n\nexport type {\n RelationshipFieldClientComponent,\n RelationshipFieldClientProps,\n RelationshipFieldDescriptionClientComponent,\n RelationshipFieldDescriptionServerComponent,\n RelationshipFieldDiffClientComponent,\n RelationshipFieldDiffServerComponent,\n RelationshipFieldErrorClientComponent,\n RelationshipFieldErrorServerComponent,\n RelationshipFieldLabelClientComponent,\n RelationshipFieldLabelServerComponent,\n RelationshipFieldServerComponent,\n RelationshipFieldServerProps,\n} from './fields/Relationship.js'\n\nexport type {\n RichTextFieldClientComponent,\n RichTextFieldClientProps,\n RichTextFieldDescriptionClientComponent,\n RichTextFieldDescriptionServerComponent,\n RichTextFieldDiffClientComponent,\n RichTextFieldDiffServerComponent,\n RichTextFieldErrorClientComponent,\n RichTextFieldErrorServerComponent,\n RichTextFieldLabelClientComponent,\n RichTextFieldLabelServerComponent,\n RichTextFieldServerComponent,\n RichTextFieldServerProps,\n} from './fields/RichText.js'\n\nexport type {\n RowFieldClientComponent,\n RowFieldClientProps,\n RowFieldDescriptionClientComponent,\n RowFieldDescriptionServerComponent,\n RowFieldDiffClientComponent,\n RowFieldDiffServerComponent,\n RowFieldErrorClientComponent,\n RowFieldErrorServerComponent,\n RowFieldLabelClientComponent,\n RowFieldLabelServerComponent,\n RowFieldServerComponent,\n RowFieldServerProps,\n} from './fields/Row.js'\n\nexport type {\n SelectFieldClientComponent,\n SelectFieldClientProps,\n SelectFieldDescriptionClientComponent,\n SelectFieldDescriptionServerComponent,\n SelectFieldDiffClientComponent,\n SelectFieldDiffServerComponent,\n SelectFieldErrorClientComponent,\n SelectFieldErrorServerComponent,\n SelectFieldLabelClientComponent,\n SelectFieldLabelServerComponent,\n SelectFieldServerComponent,\n SelectFieldServerProps,\n} from './fields/Select.js'\n\nexport type {\n ClientTab,\n TabsFieldClientComponent,\n TabsFieldClientProps,\n TabsFieldDescriptionClientComponent,\n TabsFieldDescriptionServerComponent,\n TabsFieldDiffClientComponent,\n TabsFieldDiffServerComponent,\n TabsFieldErrorClientComponent,\n TabsFieldErrorServerComponent,\n TabsFieldLabelClientComponent,\n TabsFieldLabelServerComponent,\n TabsFieldServerComponent,\n TabsFieldServerProps,\n} from './fields/Tabs.js'\n\nexport type {\n TextFieldClientComponent,\n TextFieldClientProps,\n TextFieldDescriptionClientComponent,\n TextFieldDescriptionServerComponent,\n TextFieldDiffClientComponent,\n TextFieldDiffServerComponent,\n TextFieldErrorClientComponent,\n TextFieldErrorServerComponent,\n TextFieldLabelClientComponent,\n TextFieldLabelServerComponent,\n TextFieldServerComponent,\n TextFieldServerProps,\n} from './fields/Text.js'\n\nexport type {\n TextareaFieldClientComponent,\n TextareaFieldClientProps,\n TextareaFieldDescriptionClientComponent,\n TextareaFieldDescriptionServerComponent,\n TextareaFieldDiffClientComponent,\n TextareaFieldDiffServerComponent,\n TextareaFieldErrorClientComponent,\n TextareaFieldErrorServerComponent,\n TextareaFieldLabelClientComponent,\n TextareaFieldLabelServerComponent,\n TextareaFieldServerComponent,\n TextareaFieldServerProps,\n} from './fields/Textarea.js'\n\nexport type {\n UIFieldClientComponent,\n UIFieldClientProps,\n UIFieldDiffClientComponent,\n UIFieldDiffServerComponent,\n UIFieldServerComponent,\n UIFieldServerProps,\n} from './fields/UI.js'\n\nexport type {\n UploadFieldClientComponent,\n UploadFieldClientProps,\n UploadFieldDescriptionClientComponent,\n UploadFieldDescriptionServerComponent,\n UploadFieldDiffClientComponent,\n UploadFieldDiffServerComponent,\n UploadFieldErrorClientComponent,\n UploadFieldErrorServerComponent,\n UploadFieldLabelClientComponent,\n UploadFieldLabelServerComponent,\n UploadFieldServerComponent,\n UploadFieldServerProps,\n} from './fields/Upload.js'\n\nexport type {\n Description,\n DescriptionFunction,\n FieldDescriptionClientComponent,\n FieldDescriptionClientProps,\n FieldDescriptionServerComponent,\n FieldDescriptionServerProps,\n GenericDescriptionProps,\n StaticDescription,\n} from './forms/Description.js'\n\nexport type {\n BaseVersionField,\n DiffMethod,\n FieldDiffClientComponent,\n FieldDiffClientProps,\n FieldDiffServerComponent,\n FieldDiffServerProps,\n VersionField,\n VersionTab,\n} from './forms/Diff.js'\n\nexport type {\n BuildFormStateArgs,\n Data,\n FieldState as FormField,\n FieldStateWithoutComponents as FormFieldWithoutComponents,\n FilterOptionsResult,\n FormState,\n FormStateWithoutComponents,\n Row,\n}\n\nexport type {\n FieldErrorClientComponent,\n FieldErrorClientProps,\n FieldErrorServerComponent,\n FieldErrorServerProps,\n GenericErrorProps,\n} from './forms/Error.js'\n\nexport type {\n ClientComponentProps,\n ClientFieldBase,\n ClientFieldWithOptionalType,\n FieldClientComponent,\n FieldPaths,\n FieldServerComponent,\n ServerComponentProps,\n ServerFieldBase,\n} from './forms/Field.js'\n\nexport type {\n FieldLabelClientComponent,\n FieldLabelClientProps,\n FieldLabelServerComponent,\n FieldLabelServerProps,\n GenericLabelProps,\n SanitizedLabelProps,\n} from './forms/Label.js'\n\nexport type { RowLabel, RowLabelComponent } from './forms/RowLabel.js'\n\nexport type MappedServerComponent<TComponentClientProps extends JsonObject = JsonObject> = {\n Component?: React.ComponentType<TComponentClientProps>\n props?: Partial<any>\n RenderedComponent: React.ReactNode\n type: 'server'\n}\n\nexport type MappedClientComponent<TComponentClientProps extends JsonObject = JsonObject> = {\n Component?: React.ComponentType<TComponentClientProps>\n props?: Partial<TComponentClientProps>\n RenderedComponent?: React.ReactNode\n type: 'client'\n}\n\nexport type MappedEmptyComponent = {\n type: 'empty'\n}\n\nexport enum Action {\n RenderConfig = 'render-config',\n}\n\nexport type RenderEntityConfigArgs = {\n collectionSlug?: string\n data?: Data\n globalSlug?: string\n}\n\nexport type RenderRootConfigArgs = {}\n\nexport type RenderFieldConfigArgs = {\n collectionSlug?: string\n formState?: FormState\n globalSlug?: string\n schemaPath: string\n}\n\nexport type RenderConfigArgs = {\n action: Action.RenderConfig\n config: Promise<SanitizedConfig> | SanitizedConfig\n i18n: I18nClient\n importMap: ImportMap\n languageCode: AcceptedLanguages\n serverProps?: any\n} & (RenderEntityConfigArgs | RenderFieldConfigArgs | RenderRootConfigArgs)\n\nexport type PayloadServerAction = (\n args:\n | {\n [key: string]: any\n action: Action\n i18n: I18nClient\n }\n | RenderConfigArgs,\n) => Promise<string>\n\nexport type RenderedField = {\n Field: React.ReactNode\n indexPath?: string\n initialSchemaPath?: string\n /**\n * @deprecated\n * This is a legacy property that will be removed in v4.\n * Please use `fieldIsSidebar(field)` from `payload` instead.\n * Or check `field.admin.position === 'sidebar'` directly.\n */\n isSidebar: boolean\n path: string\n schemaPath: string\n type: FieldTypes\n}\n\nexport type FieldRow = {\n RowLabel?: React.ReactNode\n}\n\nexport type DocumentSlots = {\n BeforeDocumentControls?: React.ReactNode\n Description?: React.ReactNode\n EditMenuItems?: React.ReactNode\n PreviewButton?: React.ReactNode\n PublishButton?: React.ReactNode\n SaveButton?: React.ReactNode\n SaveDraftButton?: React.ReactNode\n Upload?: React.ReactNode\n}\n\nexport type {\n BuildCollectionFolderViewResult,\n BuildTableStateArgs,\n DefaultServerFunctionArgs,\n ListQuery,\n ServerFunction,\n ServerFunctionArgs,\n ServerFunctionClient,\n ServerFunctionClientArgs,\n ServerFunctionConfig,\n ServerFunctionHandler,\n} from './functions/index.js'\n\nexport type { LanguageOptions } from './LanguageOptions.js'\n\nexport type { RichTextAdapter, RichTextAdapterProvider, RichTextHooks } from './RichText.js'\n\nexport type {\n BeforeDocumentControlsClientProps,\n BeforeDocumentControlsServerProps,\n BeforeDocumentControlsServerPropsOnly,\n DocumentSubViewTypes,\n DocumentTabClientProps,\n /**\n * @deprecated\n * The `DocumentTabComponent` type is deprecated and will be removed in the next major version.\n * Use `DocumentTabServerProps`or `DocumentTabClientProps` instead.\n */\n DocumentTabComponent,\n DocumentTabCondition,\n DocumentTabConfig,\n /**\n * @deprecated\n * The `DocumentTabProps` type is deprecated and will be removed in the next major version.\n * Use `DocumentTabServerProps` instead.\n */\n DocumentTabServerProps as DocumentTabProps,\n DocumentTabServerProps,\n DocumentTabServerPropsOnly,\n /**\n * @deprecated\n * The `ClientSideEditViewProps` type is deprecated and will be removed in the next major version.\n * Use `DocumentViewClientProps` instead.\n */\n DocumentViewClientProps as ClientSideEditViewProps,\n DocumentViewClientProps,\n /**\n * @deprecated\n * The `ServerSideEditViewProps` is deprecated and will be removed in the next major version.\n * Use `DocumentViewServerProps` instead.\n */\n DocumentViewServerProps as ServerSideEditViewProps,\n DocumentViewServerProps,\n DocumentViewServerPropsOnly,\n EditViewProps,\n} from './views/document.js'\n\nexport type {\n AfterFolderListClientProps,\n AfterFolderListServerProps,\n AfterFolderListServerPropsOnly,\n AfterFolderListTableClientProps,\n AfterFolderListTableServerProps,\n AfterFolderListTableServerPropsOnly,\n BeforeFolderListClientProps,\n BeforeFolderListServerProps,\n BeforeFolderListServerPropsOnly,\n BeforeFolderListTableClientProps,\n BeforeFolderListTableServerProps,\n BeforeFolderListTableServerPropsOnly,\n FolderListViewClientProps,\n FolderListViewServerProps,\n FolderListViewServerPropsOnly,\n FolderListViewSlots,\n FolderListViewSlotSharedClientProps,\n} from './views/folderList.js'\n\nexport type {\n AdminViewClientProps,\n /**\n * @deprecated\n * The `AdminViewComponent` type is deprecated and will be removed in the next major version.\n * Type your component props directly instead.\n */\n AdminViewComponent,\n AdminViewConfig,\n /**\n * @deprecated\n * The `AdminViewProps` type is deprecated and will be removed in the next major version.\n * Use `AdminViewServerProps` instead.\n */\n AdminViewServerProps as AdminViewProps,\n AdminViewServerProps,\n AdminViewServerPropsOnly,\n InitPageResult,\n ServerPropsFromView,\n ViewDescriptionClientProps,\n ViewDescriptionServerProps,\n ViewDescriptionServerPropsOnly,\n ViewTypes,\n VisibleEntities,\n} from './views/index.js'\n\nexport type {\n AfterListClientProps,\n AfterListServerProps,\n AfterListServerPropsOnly,\n AfterListTableClientProps,\n AfterListTableServerProps,\n AfterListTableServerPropsOnly,\n BeforeListClientProps,\n BeforeListServerProps,\n BeforeListServerPropsOnly,\n BeforeListTableClientProps,\n BeforeListTableServerProps,\n BeforeListTableServerPropsOnly,\n ListViewClientProps,\n ListViewServerProps,\n ListViewServerPropsOnly,\n ListViewSlots,\n ListViewSlotSharedClientProps,\n} from './views/list.js'\n\ntype SchemaPath = {} & string\nexport type FieldSchemaMap = Map<\n SchemaPath,\n | {\n fields: Field[]\n }\n | Block\n | Field\n | Tab\n>\n\nexport type ClientFieldSchemaMap = Map<\n SchemaPath,\n | {\n fields: ClientField[]\n }\n | ClientBlock\n | ClientField\n | ClientTab\n>\n\nexport type DocumentEvent = {\n entitySlug: string\n id?: number | string\n updatedAt: string\n}\n"],"names":["Action"],"mappings":"AAqfA,OAAO,IAAA,AAAKA,gCAAAA;;WAAAA;MAEX"}
1
+ {"version":3,"sources":["../../src/admin/types.ts"],"sourcesContent":["import type { AcceptedLanguages, I18nClient } from '@payloadcms/translations'\nimport type React from 'react'\n\nimport type { ImportMap } from '../bin/generateImportMap/index.js'\nimport type { SanitizedConfig } from '../config/types.js'\nimport type {\n Block,\n ClientBlock,\n ClientField,\n Field,\n FieldTypes,\n Tab,\n} from '../fields/config/types.js'\nimport type { JsonObject } from '../types/index.js'\nimport type { ClientTab } from './fields/Tabs.js'\nimport type {\n BuildFormStateArgs,\n Data,\n FieldState,\n FieldStateWithoutComponents,\n FilterOptionsResult,\n FormState,\n FormStateWithoutComponents,\n Row,\n} from './forms/Form.js'\n\nexport type {\n /**\n * @deprecated\n * The `CustomPreviewButton` type is deprecated and will be removed in the next major version.\n * This type is only used for the Payload Config. Use `PreviewButtonClientProps` instead.\n */\n CustomComponent as CustomPreviewButton,\n /**\n * @deprecated\n * The `CustomPublishButton` type is deprecated and will be removed in the next major version.\n * This type is only used for the Payload Config. Use `PreviewButtonClientProps` instead.\n */\n CustomComponent as CustomPublishButton,\n /**\n * @deprecated\n * The `CustomSaveButton` type is deprecated and will be removed in the next major version.\n * This type is only used for the Payload Config. Use `PreviewButtonClientProps` instead.\n */\n CustomComponent as CustomSaveButton,\n /**\n * @deprecated\n * The `CustomSaveDraftButton` type is deprecated and will be removed in the next major version.\n * This type is only used for the Payload Config. Use `PreviewButtonClientProps` instead.\n */\n CustomComponent as CustomSaveDraftButton,\n} from '../config/types.js'\nexport type { DefaultCellComponentProps, DefaultServerCellComponentProps } from './elements/Cell.js'\nexport type { ConditionalDateProps } from './elements/DatePicker.js'\nexport type { DayPickerProps, SharedProps, TimePickerProps } from './elements/DatePicker.js'\nexport type {\n EditMenuItemsClientProps,\n EditMenuItemsServerProps,\n EditMenuItemsServerPropsOnly,\n} from './elements/EditMenuItems.js'\nexport type { NavGroupPreferences, NavPreferences } from './elements/Nav.js'\nexport type {\n PreviewButtonClientProps,\n PreviewButtonServerProps,\n PreviewButtonServerPropsOnly,\n} from './elements/PreviewButton.js'\nexport type {\n PublishButtonClientProps,\n PublishButtonServerProps,\n PublishButtonServerPropsOnly,\n} from './elements/PublishButton.js'\nexport type {\n SaveButtonClientProps,\n SaveButtonServerProps,\n SaveButtonServerPropsOnly,\n} from './elements/SaveButton.js'\nexport type {\n SaveDraftButtonClientProps,\n SaveDraftButtonServerProps,\n SaveDraftButtonServerPropsOnly,\n} from './elements/SaveDraftButton.js'\n\nexport type { Column } from './elements/Table.js'\n\nexport type { CustomUpload } from './elements/Upload.js'\n\nexport type {\n WithServerSidePropsComponent,\n WithServerSidePropsComponentProps,\n} from './elements/WithServerSideProps.js'\n\nexport type {\n ArrayFieldClientComponent,\n ArrayFieldClientProps,\n ArrayFieldDescriptionClientComponent,\n ArrayFieldDescriptionServerComponent,\n ArrayFieldDiffClientComponent,\n ArrayFieldDiffServerComponent,\n ArrayFieldErrorClientComponent,\n ArrayFieldErrorServerComponent,\n ArrayFieldLabelClientComponent,\n ArrayFieldLabelServerComponent,\n ArrayFieldServerComponent,\n ArrayFieldServerProps,\n} from './fields/Array.js'\n\nexport type {\n BlockRowLabelClientComponent,\n BlockRowLabelServerComponent,\n BlocksFieldClientComponent,\n BlocksFieldClientProps,\n BlocksFieldDescriptionClientComponent,\n BlocksFieldDescriptionServerComponent,\n BlocksFieldDiffClientComponent,\n BlocksFieldDiffServerComponent,\n BlocksFieldErrorClientComponent,\n BlocksFieldErrorServerComponent,\n BlocksFieldLabelClientComponent,\n BlocksFieldLabelServerComponent,\n BlocksFieldServerComponent,\n BlocksFieldServerProps,\n} from './fields/Blocks.js'\n\nexport type {\n CheckboxFieldClientComponent,\n CheckboxFieldClientProps,\n CheckboxFieldDescriptionClientComponent,\n CheckboxFieldDescriptionServerComponent,\n CheckboxFieldDiffClientComponent,\n CheckboxFieldDiffServerComponent,\n CheckboxFieldErrorClientComponent,\n CheckboxFieldErrorServerComponent,\n CheckboxFieldLabelClientComponent,\n CheckboxFieldLabelServerComponent,\n CheckboxFieldServerComponent,\n CheckboxFieldServerProps,\n} from './fields/Checkbox.js'\n\nexport type {\n CodeFieldClientComponent,\n CodeFieldClientProps,\n CodeFieldDescriptionClientComponent,\n CodeFieldDescriptionServerComponent,\n CodeFieldDiffClientComponent,\n CodeFieldDiffServerComponent,\n CodeFieldErrorClientComponent,\n CodeFieldErrorServerComponent,\n CodeFieldLabelClientComponent,\n CodeFieldLabelServerComponent,\n CodeFieldServerComponent,\n CodeFieldServerProps,\n} from './fields/Code.js'\n\nexport type {\n CollapsibleFieldClientComponent,\n CollapsibleFieldClientProps,\n CollapsibleFieldDescriptionClientComponent,\n CollapsibleFieldDescriptionServerComponent,\n CollapsibleFieldDiffClientComponent,\n CollapsibleFieldDiffServerComponent,\n CollapsibleFieldErrorClientComponent,\n CollapsibleFieldErrorServerComponent,\n CollapsibleFieldLabelClientComponent,\n CollapsibleFieldLabelServerComponent,\n CollapsibleFieldServerComponent,\n CollapsibleFieldServerProps,\n} from './fields/Collapsible.js'\n\nexport type {\n DateFieldClientComponent,\n DateFieldClientProps,\n DateFieldDescriptionClientComponent,\n DateFieldDescriptionServerComponent,\n DateFieldDiffClientComponent,\n DateFieldDiffServerComponent,\n DateFieldErrorClientComponent,\n DateFieldErrorServerComponent,\n DateFieldLabelClientComponent,\n DateFieldLabelServerComponent,\n DateFieldServerComponent,\n DateFieldServerProps,\n} from './fields/Date.js'\n\nexport type {\n EmailFieldClientComponent,\n EmailFieldClientProps,\n EmailFieldDescriptionClientComponent,\n EmailFieldDescriptionServerComponent,\n EmailFieldDiffClientComponent,\n EmailFieldDiffServerComponent,\n EmailFieldErrorClientComponent,\n EmailFieldErrorServerComponent,\n EmailFieldLabelClientComponent,\n EmailFieldLabelServerComponent,\n EmailFieldServerComponent,\n EmailFieldServerProps,\n} from './fields/Email.js'\n\nexport type {\n GroupFieldClientComponent,\n GroupFieldClientProps,\n GroupFieldDescriptionClientComponent,\n GroupFieldDescriptionServerComponent,\n GroupFieldDiffClientComponent,\n GroupFieldDiffServerComponent,\n GroupFieldErrorClientComponent,\n GroupFieldErrorServerComponent,\n GroupFieldLabelClientComponent,\n GroupFieldLabelServerComponent,\n GroupFieldServerComponent,\n GroupFieldServerProps,\n} from './fields/Group.js'\n\nexport type { HiddenFieldProps } from './fields/Hidden.js'\n\nexport type {\n JoinFieldClientComponent,\n JoinFieldClientProps,\n JoinFieldDescriptionClientComponent,\n JoinFieldDescriptionServerComponent,\n JoinFieldDiffClientComponent,\n JoinFieldDiffServerComponent,\n JoinFieldErrorClientComponent,\n JoinFieldErrorServerComponent,\n JoinFieldLabelClientComponent,\n JoinFieldLabelServerComponent,\n JoinFieldServerComponent,\n JoinFieldServerProps,\n} from './fields/Join.js'\n\nexport type {\n JSONFieldClientComponent,\n JSONFieldClientProps,\n JSONFieldDescriptionClientComponent,\n JSONFieldDescriptionServerComponent,\n JSONFieldDiffClientComponent,\n JSONFieldDiffServerComponent,\n JSONFieldErrorClientComponent,\n JSONFieldErrorServerComponent,\n JSONFieldLabelClientComponent,\n JSONFieldLabelServerComponent,\n JSONFieldServerComponent,\n JSONFieldServerProps,\n} from './fields/JSON.js'\n\nexport type {\n NumberFieldClientComponent,\n NumberFieldClientProps,\n NumberFieldDescriptionClientComponent,\n NumberFieldDescriptionServerComponent,\n NumberFieldDiffClientComponent,\n NumberFieldDiffServerComponent,\n NumberFieldErrorClientComponent,\n NumberFieldErrorServerComponent,\n NumberFieldLabelClientComponent,\n NumberFieldLabelServerComponent,\n NumberFieldServerComponent,\n NumberFieldServerProps,\n} from './fields/Number.js'\n\nexport type {\n PointFieldClientComponent,\n PointFieldClientProps,\n PointFieldDescriptionClientComponent,\n PointFieldDescriptionServerComponent,\n PointFieldDiffClientComponent,\n PointFieldDiffServerComponent,\n PointFieldErrorClientComponent,\n PointFieldErrorServerComponent,\n PointFieldLabelClientComponent,\n PointFieldLabelServerComponent,\n PointFieldServerComponent,\n PointFieldServerProps,\n} from './fields/Point.js'\n\nexport type {\n RadioFieldClientComponent,\n RadioFieldClientProps,\n RadioFieldDescriptionClientComponent,\n RadioFieldDescriptionServerComponent,\n RadioFieldDiffClientComponent,\n RadioFieldDiffServerComponent,\n RadioFieldErrorClientComponent,\n RadioFieldErrorServerComponent,\n RadioFieldLabelClientComponent,\n RadioFieldLabelServerComponent,\n RadioFieldServerComponent,\n RadioFieldServerProps,\n} from './fields/Radio.js'\n\nexport type {\n RelationshipFieldClientComponent,\n RelationshipFieldClientProps,\n RelationshipFieldDescriptionClientComponent,\n RelationshipFieldDescriptionServerComponent,\n RelationshipFieldDiffClientComponent,\n RelationshipFieldDiffServerComponent,\n RelationshipFieldErrorClientComponent,\n RelationshipFieldErrorServerComponent,\n RelationshipFieldLabelClientComponent,\n RelationshipFieldLabelServerComponent,\n RelationshipFieldServerComponent,\n RelationshipFieldServerProps,\n} from './fields/Relationship.js'\n\nexport type {\n RichTextFieldClientComponent,\n RichTextFieldClientProps,\n RichTextFieldDescriptionClientComponent,\n RichTextFieldDescriptionServerComponent,\n RichTextFieldDiffClientComponent,\n RichTextFieldDiffServerComponent,\n RichTextFieldErrorClientComponent,\n RichTextFieldErrorServerComponent,\n RichTextFieldLabelClientComponent,\n RichTextFieldLabelServerComponent,\n RichTextFieldServerComponent,\n RichTextFieldServerProps,\n} from './fields/RichText.js'\n\nexport type {\n RowFieldClientComponent,\n RowFieldClientProps,\n RowFieldDescriptionClientComponent,\n RowFieldDescriptionServerComponent,\n RowFieldDiffClientComponent,\n RowFieldDiffServerComponent,\n RowFieldErrorClientComponent,\n RowFieldErrorServerComponent,\n RowFieldLabelClientComponent,\n RowFieldLabelServerComponent,\n RowFieldServerComponent,\n RowFieldServerProps,\n} from './fields/Row.js'\n\nexport type {\n SelectFieldClientComponent,\n SelectFieldClientProps,\n SelectFieldDescriptionClientComponent,\n SelectFieldDescriptionServerComponent,\n SelectFieldDiffClientComponent,\n SelectFieldDiffServerComponent,\n SelectFieldErrorClientComponent,\n SelectFieldErrorServerComponent,\n SelectFieldLabelClientComponent,\n SelectFieldLabelServerComponent,\n SelectFieldServerComponent,\n SelectFieldServerProps,\n} from './fields/Select.js'\n\nexport type {\n ClientTab,\n TabsFieldClientComponent,\n TabsFieldClientProps,\n TabsFieldDescriptionClientComponent,\n TabsFieldDescriptionServerComponent,\n TabsFieldDiffClientComponent,\n TabsFieldDiffServerComponent,\n TabsFieldErrorClientComponent,\n TabsFieldErrorServerComponent,\n TabsFieldLabelClientComponent,\n TabsFieldLabelServerComponent,\n TabsFieldServerComponent,\n TabsFieldServerProps,\n} from './fields/Tabs.js'\n\nexport type {\n TextFieldClientComponent,\n TextFieldClientProps,\n TextFieldDescriptionClientComponent,\n TextFieldDescriptionServerComponent,\n TextFieldDiffClientComponent,\n TextFieldDiffServerComponent,\n TextFieldErrorClientComponent,\n TextFieldErrorServerComponent,\n TextFieldLabelClientComponent,\n TextFieldLabelServerComponent,\n TextFieldServerComponent,\n TextFieldServerProps,\n} from './fields/Text.js'\n\nexport type {\n TextareaFieldClientComponent,\n TextareaFieldClientProps,\n TextareaFieldDescriptionClientComponent,\n TextareaFieldDescriptionServerComponent,\n TextareaFieldDiffClientComponent,\n TextareaFieldDiffServerComponent,\n TextareaFieldErrorClientComponent,\n TextareaFieldErrorServerComponent,\n TextareaFieldLabelClientComponent,\n TextareaFieldLabelServerComponent,\n TextareaFieldServerComponent,\n TextareaFieldServerProps,\n} from './fields/Textarea.js'\n\nexport type {\n UIFieldClientComponent,\n UIFieldClientProps,\n UIFieldDiffClientComponent,\n UIFieldDiffServerComponent,\n UIFieldServerComponent,\n UIFieldServerProps,\n} from './fields/UI.js'\n\nexport type {\n UploadFieldClientComponent,\n UploadFieldClientProps,\n UploadFieldDescriptionClientComponent,\n UploadFieldDescriptionServerComponent,\n UploadFieldDiffClientComponent,\n UploadFieldDiffServerComponent,\n UploadFieldErrorClientComponent,\n UploadFieldErrorServerComponent,\n UploadFieldLabelClientComponent,\n UploadFieldLabelServerComponent,\n UploadFieldServerComponent,\n UploadFieldServerProps,\n} from './fields/Upload.js'\n\nexport type {\n Description,\n DescriptionFunction,\n FieldDescriptionClientComponent,\n FieldDescriptionClientProps,\n FieldDescriptionServerComponent,\n FieldDescriptionServerProps,\n GenericDescriptionProps,\n StaticDescription,\n} from './forms/Description.js'\n\nexport type {\n BaseVersionField,\n DiffMethod,\n FieldDiffClientComponent,\n FieldDiffClientProps,\n FieldDiffServerComponent,\n FieldDiffServerProps,\n VersionField,\n VersionTab,\n} from './forms/Diff.js'\n\nexport type {\n BuildFormStateArgs,\n Data,\n FieldState as FormField,\n FieldStateWithoutComponents as FormFieldWithoutComponents,\n FilterOptionsResult,\n FormState,\n FormStateWithoutComponents,\n Row,\n}\n\nexport type {\n FieldErrorClientComponent,\n FieldErrorClientProps,\n FieldErrorServerComponent,\n FieldErrorServerProps,\n GenericErrorProps,\n} from './forms/Error.js'\n\nexport type {\n ClientComponentProps,\n ClientFieldBase,\n ClientFieldWithOptionalType,\n FieldClientComponent,\n FieldPaths,\n FieldServerComponent,\n ServerComponentProps,\n ServerFieldBase,\n} from './forms/Field.js'\n\nexport type {\n FieldLabelClientComponent,\n FieldLabelClientProps,\n FieldLabelServerComponent,\n FieldLabelServerProps,\n GenericLabelProps,\n SanitizedLabelProps,\n} from './forms/Label.js'\n\nexport type { RowLabel, RowLabelComponent } from './forms/RowLabel.js'\n\nexport type MappedServerComponent<TComponentClientProps extends JsonObject = JsonObject> = {\n Component?: React.ComponentType<TComponentClientProps>\n props?: Partial<any>\n RenderedComponent: React.ReactNode\n type: 'server'\n}\n\nexport type MappedClientComponent<TComponentClientProps extends JsonObject = JsonObject> = {\n Component?: React.ComponentType<TComponentClientProps>\n props?: Partial<TComponentClientProps>\n RenderedComponent?: React.ReactNode\n type: 'client'\n}\n\nexport type MappedEmptyComponent = {\n type: 'empty'\n}\n\nexport enum Action {\n RenderConfig = 'render-config',\n}\n\nexport type RenderEntityConfigArgs = {\n collectionSlug?: string\n data?: Data\n globalSlug?: string\n}\n\nexport type RenderRootConfigArgs = {}\n\nexport type RenderFieldConfigArgs = {\n collectionSlug?: string\n formState?: FormState\n globalSlug?: string\n schemaPath: string\n}\n\nexport type RenderConfigArgs = {\n action: Action.RenderConfig\n config: Promise<SanitizedConfig> | SanitizedConfig\n i18n: I18nClient\n importMap: ImportMap\n languageCode: AcceptedLanguages\n serverProps?: any\n} & (RenderEntityConfigArgs | RenderFieldConfigArgs | RenderRootConfigArgs)\n\nexport type PayloadServerAction = (\n args:\n | {\n [key: string]: any\n action: Action\n i18n: I18nClient\n }\n | RenderConfigArgs,\n) => Promise<string>\n\nexport type RenderedField = {\n Field: React.ReactNode\n indexPath?: string\n initialSchemaPath?: string\n /**\n * @deprecated\n * This is a legacy property that will be removed in v4.\n * Please use `fieldIsSidebar(field)` from `payload` instead.\n * Or check `field.admin.position === 'sidebar'` directly.\n */\n isSidebar: boolean\n path: string\n schemaPath: string\n type: FieldTypes\n}\n\nexport type FieldRow = {\n RowLabel?: React.ReactNode\n}\n\nexport type DocumentSlots = {\n BeforeDocumentControls?: React.ReactNode\n Description?: React.ReactNode\n EditMenuItems?: React.ReactNode\n PreviewButton?: React.ReactNode\n PublishButton?: React.ReactNode\n SaveButton?: React.ReactNode\n SaveDraftButton?: React.ReactNode\n Upload?: React.ReactNode\n}\n\nexport type {\n BuildCollectionFolderViewResult,\n BuildTableStateArgs,\n DefaultServerFunctionArgs,\n GetFolderResultsComponentAndDataArgs,\n ListQuery,\n ServerFunction,\n ServerFunctionArgs,\n ServerFunctionClient,\n ServerFunctionClientArgs,\n ServerFunctionConfig,\n ServerFunctionHandler,\n} from './functions/index.js'\n\nexport type { LanguageOptions } from './LanguageOptions.js'\n\nexport type { RichTextAdapter, RichTextAdapterProvider, RichTextHooks } from './RichText.js'\n\nexport type {\n BeforeDocumentControlsClientProps,\n BeforeDocumentControlsServerProps,\n BeforeDocumentControlsServerPropsOnly,\n DocumentSubViewTypes,\n DocumentTabClientProps,\n /**\n * @deprecated\n * The `DocumentTabComponent` type is deprecated and will be removed in the next major version.\n * Use `DocumentTabServerProps`or `DocumentTabClientProps` instead.\n */\n DocumentTabComponent,\n DocumentTabCondition,\n DocumentTabConfig,\n /**\n * @deprecated\n * The `DocumentTabProps` type is deprecated and will be removed in the next major version.\n * Use `DocumentTabServerProps` instead.\n */\n DocumentTabServerProps as DocumentTabProps,\n DocumentTabServerProps,\n DocumentTabServerPropsOnly,\n /**\n * @deprecated\n * The `ClientSideEditViewProps` type is deprecated and will be removed in the next major version.\n * Use `DocumentViewClientProps` instead.\n */\n DocumentViewClientProps as ClientSideEditViewProps,\n DocumentViewClientProps,\n /**\n * @deprecated\n * The `ServerSideEditViewProps` is deprecated and will be removed in the next major version.\n * Use `DocumentViewServerProps` instead.\n */\n DocumentViewServerProps as ServerSideEditViewProps,\n DocumentViewServerProps,\n DocumentViewServerPropsOnly,\n EditViewProps,\n} from './views/document.js'\n\nexport type {\n AfterFolderListClientProps,\n AfterFolderListServerProps,\n AfterFolderListServerPropsOnly,\n AfterFolderListTableClientProps,\n AfterFolderListTableServerProps,\n AfterFolderListTableServerPropsOnly,\n BeforeFolderListClientProps,\n BeforeFolderListServerProps,\n BeforeFolderListServerPropsOnly,\n BeforeFolderListTableClientProps,\n BeforeFolderListTableServerProps,\n BeforeFolderListTableServerPropsOnly,\n FolderListViewClientProps,\n FolderListViewServerProps,\n FolderListViewServerPropsOnly,\n FolderListViewSlots,\n FolderListViewSlotSharedClientProps,\n} from './views/folderList.js'\n\nexport type {\n AdminViewClientProps,\n /**\n * @deprecated\n * The `AdminViewComponent` type is deprecated and will be removed in the next major version.\n * Type your component props directly instead.\n */\n AdminViewComponent,\n AdminViewConfig,\n /**\n * @deprecated\n * The `AdminViewProps` type is deprecated and will be removed in the next major version.\n * Use `AdminViewServerProps` instead.\n */\n AdminViewServerProps as AdminViewProps,\n AdminViewServerProps,\n AdminViewServerPropsOnly,\n InitPageResult,\n ServerPropsFromView,\n ViewDescriptionClientProps,\n ViewDescriptionServerProps,\n ViewDescriptionServerPropsOnly,\n ViewTypes,\n VisibleEntities,\n} from './views/index.js'\n\nexport type {\n AfterListClientProps,\n AfterListServerProps,\n AfterListServerPropsOnly,\n AfterListTableClientProps,\n AfterListTableServerProps,\n AfterListTableServerPropsOnly,\n BeforeListClientProps,\n BeforeListServerProps,\n BeforeListServerPropsOnly,\n BeforeListTableClientProps,\n BeforeListTableServerProps,\n BeforeListTableServerPropsOnly,\n ListViewClientProps,\n ListViewServerProps,\n ListViewServerPropsOnly,\n ListViewSlots,\n ListViewSlotSharedClientProps,\n} from './views/list.js'\n\ntype SchemaPath = {} & string\nexport type FieldSchemaMap = Map<\n SchemaPath,\n | {\n fields: Field[]\n }\n | Block\n | Field\n | Tab\n>\n\nexport type ClientFieldSchemaMap = Map<\n SchemaPath,\n | {\n fields: ClientField[]\n }\n | ClientBlock\n | ClientField\n | ClientTab\n>\n\nexport type DocumentEvent = {\n entitySlug: string\n id?: number | string\n updatedAt: string\n}\n"],"names":["Action"],"mappings":"AAqfA,OAAO,IAAA,AAAKA,gCAAAA;;WAAAA;MAEX"}
@@ -1,5 +1,5 @@
1
1
  import type { ServerProps } from '../../config/types.js';
2
- import type { FolderOrDocument } from '../../folders/types.js';
2
+ import type { FolderBreadcrumb, FolderOrDocument, FolderSortKeys } from '../../folders/types.js';
3
3
  import type { SanitizedCollectionConfig } from '../../index.js';
4
4
  export type FolderListViewSlots = {
5
5
  AfterFolderList?: React.ReactNode;
@@ -8,7 +8,6 @@ export type FolderListViewSlots = {
8
8
  BeforeFolderListTable?: React.ReactNode;
9
9
  Description?: React.ReactNode;
10
10
  listMenuItems?: React.ReactNode[];
11
- Table: React.ReactNode;
12
11
  };
13
12
  export type FolderListViewServerPropsOnly = {
14
13
  collectionConfig: SanitizedCollectionConfig;
@@ -17,13 +16,23 @@ export type FolderListViewServerPropsOnly = {
17
16
  } & ServerProps;
18
17
  export type FolderListViewServerProps = FolderListViewClientProps & FolderListViewServerPropsOnly;
19
18
  export type FolderListViewClientProps = {
19
+ activeCollectionFolderSlugs?: SanitizedCollectionConfig['slug'][];
20
+ allCollectionFolderSlugs: SanitizedCollectionConfig['slug'][];
21
+ allowCreateCollectionSlugs: SanitizedCollectionConfig['slug'][];
22
+ baseFolderPath: `/${string}`;
20
23
  beforeActions?: React.ReactNode[];
21
- collectionSlug: SanitizedCollectionConfig['slug'];
24
+ breadcrumbs: FolderBreadcrumb[];
25
+ collectionSlug?: SanitizedCollectionConfig['slug'];
22
26
  disableBulkDelete?: boolean;
23
27
  disableBulkEdit?: boolean;
28
+ documents: FolderOrDocument[];
24
29
  enableRowSelections?: boolean;
25
- hasCreatePermission: boolean;
26
- newDocumentURL: string;
30
+ folderFieldName: string;
31
+ folderID: null | number | string;
32
+ FolderResultsComponent: React.ReactNode;
33
+ search?: string;
34
+ sort?: FolderSortKeys;
35
+ subfolders: FolderOrDocument[];
27
36
  viewPreference: 'grid' | 'list';
28
37
  } & FolderListViewSlots;
29
38
  export type FolderListViewSlotSharedClientProps = {
@@ -1 +1 @@
1
- {"version":3,"file":"folderList.d.ts","sourceRoot":"","sources":["../../../src/admin/views/folderList.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAA;AACxD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAA;AAC9D,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,gBAAgB,CAAA;AA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O,CAAA;IAC5B,cAAc,EAAE,MAAM,CAAA;CACvB,CAAA;AAGD,MAAM,MAAM,2BAA2B,GAAG,mCAAmC,CAAA;AAC7E,MAAM,MAAM,+BAA+B,GAAG,EAAE,GAAG,6BAA6B,CAAA;AAChF,MAAM,MAAM,2BAA2B,GAAG,2BAA2B,GACnE,+BAA+B,CAAA;AAGjC,MAAM,MAAM,gCAAgC,GAAG,mCAAmC,CAAA;AAClF,MAAM,MAAM,oCAAoC,GAAG,EAAE,GAAG,6BAA6B,CAAA;AACrF,MAAM,MAAM,gCAAgC,GAAG,gCAAgC,GAC7E,oCAAoC,CAAA;AAGtC,MAAM,MAAM,0BAA0B,GAAG,mCAAmC,CAAA;AAC5E,MAAM,MAAM,8BAA8B,GAAG,EAAE,GAAG,6BAA6B,CAAA;AAC/E,MAAM,MAAM,0BAA0B,GAAG,0BAA0B,GAAG,8BAA8B,CAAA;AAGpG,MAAM,MAAM,+BAA+B,GAAG,mCAAmC,CAAA;AACjF,MAAM,MAAM,mCAAmC,GAAG,EAAE,GAAG,6BAA6B,CAAA;AACpF,MAAM,MAAM,+BAA+B,GAAG,+BAA+B,GAC3E,mCAAmC,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/admin/views/folderList.ts"],"sourcesContent":["import type { ServerProps } from '../../config/types.js'\nimport type { FolderOrDocument } from '../../folders/types.js'\nimport type { SanitizedCollectionConfig } from '../../index.js'\nexport type FolderListViewSlots = {\n AfterFolderList?: React.ReactNode\n AfterFolderListTable?: React.ReactNode\n BeforeFolderList?: React.ReactNode\n BeforeFolderListTable?: React.ReactNode\n Description?: React.ReactNode\n listMenuItems?: React.ReactNode[]\n Table: React.ReactNode\n}\n\nexport type FolderListViewServerPropsOnly = {\n collectionConfig: SanitizedCollectionConfig\n documents: FolderOrDocument[]\n subfolders: FolderOrDocument[]\n} & ServerProps\n\nexport type FolderListViewServerProps = FolderListViewClientProps & FolderListViewServerPropsOnly\n\nexport type FolderListViewClientProps = {\n beforeActions?: React.ReactNode[]\n collectionSlug: SanitizedCollectionConfig['slug']\n disableBulkDelete?: boolean\n disableBulkEdit?: boolean\n enableRowSelections?: boolean\n hasCreatePermission: boolean\n newDocumentURL: string\n viewPreference: 'grid' | 'list'\n} & FolderListViewSlots\n\nexport type FolderListViewSlotSharedClientProps = {\n collectionSlug: SanitizedCollectionConfig['slug']\n hasCreatePermission: boolean\n newDocumentURL: string\n}\n\n// BeforeFolderList\nexport type BeforeFolderListClientProps = FolderListViewSlotSharedClientProps\nexport type BeforeFolderListServerPropsOnly = {} & FolderListViewServerPropsOnly\nexport type BeforeFolderListServerProps = BeforeFolderListClientProps &\n BeforeFolderListServerPropsOnly\n\n// BeforeFolderListTable\nexport type BeforeFolderListTableClientProps = FolderListViewSlotSharedClientProps\nexport type BeforeFolderListTableServerPropsOnly = {} & FolderListViewServerPropsOnly\nexport type BeforeFolderListTableServerProps = BeforeFolderListTableClientProps &\n BeforeFolderListTableServerPropsOnly\n\n// AfterFolderList\nexport type AfterFolderListClientProps = FolderListViewSlotSharedClientProps\nexport type AfterFolderListServerPropsOnly = {} & FolderListViewServerPropsOnly\nexport type AfterFolderListServerProps = AfterFolderListClientProps & AfterFolderListServerPropsOnly\n\n// AfterFolderListTable\nexport type AfterFolderListTableClientProps = FolderListViewSlotSharedClientProps\nexport type AfterFolderListTableServerPropsOnly = {} & FolderListViewServerPropsOnly\nexport type AfterFolderListTableServerProps = AfterFolderListTableClientProps &\n AfterFolderListTableServerPropsOnly\n"],"names":[],"mappings":"AA0DA,WACqC"}
1
+ {"version":3,"sources":["../../../src/admin/views/folderList.ts"],"sourcesContent":["import type { ServerProps } from '../../config/types.js'\nimport type { FolderBreadcrumb, FolderOrDocument, FolderSortKeys } from '../../folders/types.js'\nimport type { SanitizedCollectionConfig } from '../../index.js'\nexport type FolderListViewSlots = {\n AfterFolderList?: React.ReactNode\n AfterFolderListTable?: React.ReactNode\n BeforeFolderList?: React.ReactNode\n BeforeFolderListTable?: React.ReactNode\n Description?: React.ReactNode\n listMenuItems?: React.ReactNode[]\n}\n\nexport type FolderListViewServerPropsOnly = {\n collectionConfig: SanitizedCollectionConfig\n documents: FolderOrDocument[]\n subfolders: FolderOrDocument[]\n} & ServerProps\n\nexport type FolderListViewServerProps = FolderListViewClientProps & FolderListViewServerPropsOnly\n\nexport type FolderListViewClientProps = {\n activeCollectionFolderSlugs?: SanitizedCollectionConfig['slug'][]\n allCollectionFolderSlugs: SanitizedCollectionConfig['slug'][]\n allowCreateCollectionSlugs: SanitizedCollectionConfig['slug'][]\n baseFolderPath: `/${string}`\n beforeActions?: React.ReactNode[]\n breadcrumbs: FolderBreadcrumb[]\n collectionSlug?: SanitizedCollectionConfig['slug']\n disableBulkDelete?: boolean\n disableBulkEdit?: boolean\n documents: FolderOrDocument[]\n enableRowSelections?: boolean\n folderFieldName: string\n folderID: null | number | string\n FolderResultsComponent: React.ReactNode\n search?: string\n sort?: FolderSortKeys\n subfolders: FolderOrDocument[]\n viewPreference: 'grid' | 'list'\n} & FolderListViewSlots\n\nexport type FolderListViewSlotSharedClientProps = {\n collectionSlug: SanitizedCollectionConfig['slug']\n hasCreatePermission: boolean\n newDocumentURL: string\n}\n\n// BeforeFolderList\nexport type BeforeFolderListClientProps = FolderListViewSlotSharedClientProps\nexport type BeforeFolderListServerPropsOnly = {} & FolderListViewServerPropsOnly\nexport type BeforeFolderListServerProps = BeforeFolderListClientProps &\n BeforeFolderListServerPropsOnly\n\n// BeforeFolderListTable\nexport type BeforeFolderListTableClientProps = FolderListViewSlotSharedClientProps\nexport type BeforeFolderListTableServerPropsOnly = {} & FolderListViewServerPropsOnly\nexport type BeforeFolderListTableServerProps = BeforeFolderListTableClientProps &\n BeforeFolderListTableServerPropsOnly\n\n// AfterFolderList\nexport type AfterFolderListClientProps = FolderListViewSlotSharedClientProps\nexport type AfterFolderListServerPropsOnly = {} & FolderListViewServerPropsOnly\nexport type AfterFolderListServerProps = AfterFolderListClientProps & AfterFolderListServerPropsOnly\n\n// AfterFolderListTable\nexport type AfterFolderListTableClientProps = FolderListViewSlotSharedClientProps\nexport type AfterFolderListTableServerPropsOnly = {} & FolderListViewServerPropsOnly\nexport type AfterFolderListTableServerProps = AfterFolderListTableClientProps &\n AfterFolderListTableServerPropsOnly\n"],"names":[],"mappings":"AAmEA,WACqC"}
@@ -1 +1 @@
1
- {"version":3,"file":"crypto.d.ts","sourceRoot":"","sources":["../../src/auth/crypto.ts"],"names":[],"mappings":"AAKA,wBAAgB,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAU5C;AAED,wBAAgB,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAS5C"}
1
+ {"version":3,"file":"crypto.d.ts","sourceRoot":"","sources":["../../src/auth/crypto.ts"],"names":[],"mappings":"AAIA,wBAAgB,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAY5C;AAED,wBAAgB,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAW5C"}
@@ -1,9 +1,10 @@
1
- // @ts-strict-ignore
2
1
  import crypto from 'crypto';
3
2
  const algorithm = 'aes-256-ctr';
4
3
  export function encrypt(text) {
5
4
  const iv = crypto.randomBytes(16);
6
- const cipher = crypto.createCipheriv(algorithm, this.secret, iv);
5
+ // @ts-expect-error - vestiges of when tsconfig was not strict. Feel free to improve
6
+ const secret = this.secret;
7
+ const cipher = crypto.createCipheriv(algorithm, secret, iv);
7
8
  const encrypted = Buffer.concat([
8
9
  cipher.update(text),
9
10
  cipher.final()
@@ -15,7 +16,9 @@ export function encrypt(text) {
15
16
  export function decrypt(hash) {
16
17
  const iv = hash.slice(0, 32);
17
18
  const content = hash.slice(32);
18
- const decipher = crypto.createDecipheriv(algorithm, this.secret, Buffer.from(iv, 'hex'));
19
+ // @ts-expect-error - vestiges of when tsconfig was not strict. Feel free to improve
20
+ const secret = this.secret;
21
+ const decipher = crypto.createDecipheriv(algorithm, secret, Buffer.from(iv, 'hex'));
19
22
  const decrypted = Buffer.concat([
20
23
  decipher.update(Buffer.from(content, 'hex')),
21
24
  decipher.final()
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/auth/crypto.ts"],"sourcesContent":["// @ts-strict-ignore\nimport crypto from 'crypto'\n\nconst algorithm = 'aes-256-ctr'\n\nexport function encrypt(text: string): string {\n const iv = crypto.randomBytes(16)\n const cipher = crypto.createCipheriv(algorithm, this.secret, iv)\n\n const encrypted = Buffer.concat([cipher.update(text), cipher.final()])\n\n const ivString = iv.toString('hex')\n const encryptedString = encrypted.toString('hex')\n\n return `${ivString}${encryptedString}`\n}\n\nexport function decrypt(hash: string): string {\n const iv = hash.slice(0, 32)\n const content = hash.slice(32)\n\n const decipher = crypto.createDecipheriv(algorithm, this.secret, Buffer.from(iv, 'hex'))\n\n const decrypted = Buffer.concat([decipher.update(Buffer.from(content, 'hex')), decipher.final()])\n\n return decrypted.toString()\n}\n"],"names":["crypto","algorithm","encrypt","text","iv","randomBytes","cipher","createCipheriv","secret","encrypted","Buffer","concat","update","final","ivString","toString","encryptedString","decrypt","hash","slice","content","decipher","createDecipheriv","from","decrypted"],"mappings":"AAAA,oBAAoB;AACpB,OAAOA,YAAY,SAAQ;AAE3B,MAAMC,YAAY;AAElB,OAAO,SAASC,QAAQC,IAAY;IAClC,MAAMC,KAAKJ,OAAOK,WAAW,CAAC;IAC9B,MAAMC,SAASN,OAAOO,cAAc,CAACN,WAAW,IAAI,CAACO,MAAM,EAAEJ;IAE7D,MAAMK,YAAYC,OAAOC,MAAM,CAAC;QAACL,OAAOM,MAAM,CAACT;QAAOG,OAAOO,KAAK;KAAG;IAErE,MAAMC,WAAWV,GAAGW,QAAQ,CAAC;IAC7B,MAAMC,kBAAkBP,UAAUM,QAAQ,CAAC;IAE3C,OAAO,GAAGD,WAAWE,iBAAiB;AACxC;AAEA,OAAO,SAASC,QAAQC,IAAY;IAClC,MAAMd,KAAKc,KAAKC,KAAK,CAAC,GAAG;IACzB,MAAMC,UAAUF,KAAKC,KAAK,CAAC;IAE3B,MAAME,WAAWrB,OAAOsB,gBAAgB,CAACrB,WAAW,IAAI,CAACO,MAAM,EAAEE,OAAOa,IAAI,CAACnB,IAAI;IAEjF,MAAMoB,YAAYd,OAAOC,MAAM,CAAC;QAACU,SAAST,MAAM,CAACF,OAAOa,IAAI,CAACH,SAAS;QAASC,SAASR,KAAK;KAAG;IAEhG,OAAOW,UAAUT,QAAQ;AAC3B"}
1
+ {"version":3,"sources":["../../src/auth/crypto.ts"],"sourcesContent":["import crypto from 'crypto'\n\nconst algorithm = 'aes-256-ctr'\n\nexport function encrypt(text: string): string {\n const iv = crypto.randomBytes(16)\n // @ts-expect-error - vestiges of when tsconfig was not strict. Feel free to improve\n const secret = this.secret\n const cipher = crypto.createCipheriv(algorithm, secret, iv)\n\n const encrypted = Buffer.concat([cipher.update(text), cipher.final()])\n\n const ivString = iv.toString('hex')\n const encryptedString = encrypted.toString('hex')\n\n return `${ivString}${encryptedString}`\n}\n\nexport function decrypt(hash: string): string {\n const iv = hash.slice(0, 32)\n const content = hash.slice(32)\n\n // @ts-expect-error - vestiges of when tsconfig was not strict. Feel free to improve\n const secret = this.secret\n const decipher = crypto.createDecipheriv(algorithm, secret, Buffer.from(iv, 'hex'))\n\n const decrypted = Buffer.concat([decipher.update(Buffer.from(content, 'hex')), decipher.final()])\n\n return decrypted.toString()\n}\n"],"names":["crypto","algorithm","encrypt","text","iv","randomBytes","secret","cipher","createCipheriv","encrypted","Buffer","concat","update","final","ivString","toString","encryptedString","decrypt","hash","slice","content","decipher","createDecipheriv","from","decrypted"],"mappings":"AAAA,OAAOA,YAAY,SAAQ;AAE3B,MAAMC,YAAY;AAElB,OAAO,SAASC,QAAQC,IAAY;IAClC,MAAMC,KAAKJ,OAAOK,WAAW,CAAC;IAC9B,oFAAoF;IACpF,MAAMC,SAAS,IAAI,CAACA,MAAM;IAC1B,MAAMC,SAASP,OAAOQ,cAAc,CAACP,WAAWK,QAAQF;IAExD,MAAMK,YAAYC,OAAOC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
1
+ {"version":3,"file":"unlock.d.ts","sourceRoot":"","sources":["../../../src/auth/operations/unlock.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,gCAAgC,EAChC,UAAU,EACX,MAAM,mCAAmC,CAAA;AAC1C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AACpD,OAAO,KAAK,EAAE,cAAc,EAAS,MAAM,sBAAsB,CAAA;AAWjE,MAAM,MAAM,SAAS,CAAC,KAAK,SAAS,cAAc,IAAI;IACpD,UAAU,EAAE,UAAU,CAAA;IACtB,IAAI,EAAE,gCAAgC,CAAC,KAAK,CAAC,CAAC,QAAQ,CAAC,CAAA;IACvD,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,GAAG,EAAE,cAAc,CAAA;CACpB,CAAA;AAED,eAAO,MAAM,eAAe,GAAU,KAAK,SAAS,cAAc,QAC1D,SAAS,CAAC,KAAK,CAAC,KACrB,OAAO,CAAC,OAAO,CA2FjB,CAAA"}
@@ -1,4 +1,3 @@
1
- // @ts-strict-ignore
2
1
  import { status as httpStatus } from 'http-status';
3
2
  import { APIError } from '../../errors/index.js';
4
3
  import { Forbidden } from '../../index.js';
@@ -53,7 +52,7 @@ export const unlockOperation = async (args)=>{
53
52
  req,
54
53
  where: whereConstraint
55
54
  });
56
- let result;
55
+ let result = null;
57
56
  if (user) {
58
57
  await resetLoginAttempts({
59
58
  collection: collectionConfig,
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/auth/operations/unlock.ts"],"sourcesContent":["// @ts-strict-ignore\nimport { status as httpStatus } from 'http-status'\n\nimport type {\n AuthOperationsFromCollectionSlug,\n Collection,\n} from '../../collections/config/types.js'\nimport type { CollectionSlug } from '../../index.js'\nimport type { PayloadRequest, Where } from '../../types/index.js'\n\nimport { APIError } from '../../errors/index.js'\nimport { Forbidden } from '../../index.js'\nimport { commitTransaction } from '../../utilities/commitTransaction.js'\nimport { initTransaction } from '../../utilities/initTransaction.js'\nimport { killTransaction } from '../../utilities/killTransaction.js'\nimport executeAccess from '../executeAccess.js'\nimport { getLoginOptions } from '../getLoginOptions.js'\nimport { resetLoginAttempts } from '../strategies/local/resetLoginAttempts.js'\n\nexport type Arguments<TSlug extends CollectionSlug> = {\n collection: Collection\n data: AuthOperationsFromCollectionSlug<TSlug>['unlock']\n overrideAccess?: boolean\n req: PayloadRequest\n}\n\nexport const unlockOperation = async <TSlug extends CollectionSlug>(\n args: Arguments<TSlug>,\n): Promise<boolean> => {\n const {\n collection: { config: collectionConfig },\n overrideAccess,\n req: { locale },\n req,\n } = args\n\n const loginWithUsername = collectionConfig.auth.loginWithUsername\n\n const { canLoginWithEmail, canLoginWithUsername } = getLoginOptions(loginWithUsername)\n\n const sanitizedEmail = canLoginWithEmail && (args.data?.email || '').toLowerCase().trim()\n const sanitizedUsername =\n (canLoginWithUsername &&\n 'username' in args.data &&\n typeof args.data.username === 'string' &&\n args.data.username.toLowerCase().trim()) ||\n null\n\n if (collectionConfig.auth.disableLocalStrategy) {\n throw new Forbidden(req.t)\n }\n if (!sanitizedEmail && !sanitizedUsername) {\n throw new APIError(\n `Missing ${collectionConfig.auth.loginWithUsername ? 'username' : 'email'}.`,\n httpStatus.BAD_REQUEST,\n )\n }\n\n try {\n const shouldCommit = await initTransaction(req)\n\n // /////////////////////////////////////\n // Access\n // /////////////////////////////////////\n\n if (!overrideAccess) {\n await executeAccess({ req }, collectionConfig.access.unlock)\n }\n\n // /////////////////////////////////////\n // Unlock\n // /////////////////////////////////////\n\n let whereConstraint: Where = {}\n\n if (canLoginWithEmail && sanitizedEmail) {\n whereConstraint = {\n email: {\n equals: sanitizedEmail,\n },\n }\n } else if (canLoginWithUsername && sanitizedUsername) {\n whereConstraint = {\n username: {\n equals: sanitizedUsername,\n },\n }\n }\n\n const user = await req.payload.db.findOne({\n collection: collectionConfig.slug,\n locale: locale!,\n req,\n where: whereConstraint,\n })\n\n let result\n\n if (user) {\n await resetLoginAttempts({\n collection: collectionConfig,\n doc: user,\n payload: req.payload,\n req,\n })\n result = true\n } else {\n result = null\n }\n\n if (shouldCommit) {\n await commitTransaction(req)\n }\n\n return result\n } catch (error: unknown) {\n await killTransaction(req)\n throw error\n }\n}\n"],"names":["status","httpStatus","APIError","Forbidden","commitTransaction","initTransaction","killTransaction","executeAccess","getLoginOptions","resetLoginAttempts","unlockOperation","args","collection","config","collectionConfig","overrideAccess","req","locale","loginWithUsername","auth","canLoginWithEmail","canLoginWithUsername","sanitizedEmail","data","email","toLowerCase","trim","sanitizedUsername","username","disableLocalStrategy","t","BAD_REQUEST","shouldCommit","access","unlock","whereConstraint","equals","user","payload","db","findOne","slug","where","result","doc","error"],"mappings":"AAAA,oBAAoB;AACpB,SAASA,UAAUC,UAAU,QAAQ,cAAa;AASlD,SAASC,QAAQ,QAAQ,wBAAuB;AAChD,SAASC,SAAS,QAAQ,iBAAgB;AAC1C,SAASC,iBAAiB,QAAQ,uCAAsC;AACxE,SAASC,eAAe,QAAQ,qCAAoC;AACpE,SAASC,eAAe,QAAQ,qCAAoC;AACpE,OAAOC,mBAAmB,sBAAqB;AAC/C,SAASC,eAAe,QAAQ,wBAAuB;AACvD,SAASC,kBAAkB,QAAQ,4CAA2C;AAS9E,OAAO,MAAMC,kBAAkB,OAC7BC;IAEA,MAAM,EACJC,YAAY,EAAEC,QAAQC,gBAAgB,EAAE,EACxCC,cAAc,EACdC,KAAK,EAAEC,MAAM,EAAE,EACfD,GAAG,EACJ,GAAGL;IAEJ,MAAMO,oBAAoBJ,iBAAiBK,IAAI,CAACD,iBAAiB;IAEjE,MAAM,EAAEE,iBAAiB,EAAEC,oBAAoB,EAAE,GAAGb,gBAAgBU;IAEpE,MAAMI,iBAAiBF,qBAAqB,AAACT,CAAAA,KAAKY,IAAI,EAAEC,SAAS,EAAC,EAAGC,WAAW,GAAGC,IAAI;IACvF,MAAMC,oBACJ,AAACN,wBACC,cAAcV,KAAKY,IAAI,IACvB,OAAOZ,KAAKY,IAAI,CAACK,QAAQ,KAAK,Y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6B;IACR;AACF,EAAC"}
1
+ {"version":3,"sources":["../../../src/auth/operations/unlock.ts"],"sourcesContent":["import { status as httpStatus } from 'http-status'\n\nimport type {\n AuthOperationsFromCollectionSlug,\n Collection,\n} from '../../collections/config/types.js'\nimport type { CollectionSlug } from '../../index.js'\nimport type { PayloadRequest, Where } from '../../types/index.js'\n\nimport { APIError } from '../../errors/index.js'\nimport { Forbidden } from '../../index.js'\nimport { commitTransaction } from '../../utilities/commitTransaction.js'\nimport { initTransaction } from '../../utilities/initTransaction.js'\nimport { killTransaction } from '../../utilities/killTransaction.js'\nimport executeAccess from '../executeAccess.js'\nimport { getLoginOptions } from '../getLoginOptions.js'\nimport { resetLoginAttempts } from '../strategies/local/resetLoginAttempts.js'\n\nexport type Arguments<TSlug extends CollectionSlug> = {\n collection: Collection\n data: AuthOperationsFromCollectionSlug<TSlug>['unlock']\n overrideAccess?: boolean\n req: PayloadRequest\n}\n\nexport const unlockOperation = async <TSlug extends CollectionSlug>(\n args: Arguments<TSlug>,\n): Promise<boolean> => {\n const {\n collection: { config: collectionConfig },\n overrideAccess,\n req: { locale },\n req,\n } = args\n\n const loginWithUsername = collectionConfig.auth.loginWithUsername\n\n const { canLoginWithEmail, canLoginWithUsername } = getLoginOptions(loginWithUsername)\n\n const sanitizedEmail = canLoginWithEmail && (args.data?.email || '').toLowerCase().trim()\n const sanitizedUsername =\n (canLoginWithUsername &&\n 'username' in args.data &&\n typeof args.data.username === 'string' &&\n args.data.username.toLowerCase().trim()) ||\n null\n\n if (collectionConfig.auth.disableLocalStrategy) {\n throw new Forbidden(req.t)\n }\n if (!sanitizedEmail && !sanitizedUsername) {\n throw new APIError(\n `Missing ${collectionConfig.auth.loginWithUsername ? 'username' : 'email'}.`,\n httpStatus.BAD_REQUEST,\n )\n }\n\n try {\n const shouldCommit = await initTransaction(req)\n\n // /////////////////////////////////////\n // Access\n // /////////////////////////////////////\n\n if (!overrideAccess) {\n await executeAccess({ req }, collectionConfig.access.unlock)\n }\n\n // /////////////////////////////////////\n // Unlock\n // /////////////////////////////////////\n\n let whereConstraint: Where = {}\n\n if (canLoginWithEmail && sanitizedEmail) {\n whereConstraint = {\n email: {\n equals: sanitizedEmail,\n },\n }\n } else if (canLoginWithUsername && sanitizedUsername) {\n whereConstraint = {\n username: {\n equals: sanitizedUsername,\n },\n }\n }\n\n const user = await req.payload.db.findOne({\n collection: collectionConfig.slug,\n locale: locale!,\n req,\n where: whereConstraint,\n })\n\n let result: boolean | null = null\n\n if (user) {\n await resetLoginAttempts({\n collection: collectionConfig,\n doc: user,\n payload: req.payload,\n req,\n })\n result = true\n } else {\n result = null\n }\n\n if (shouldCommit) {\n await commitTransaction(req)\n }\n\n return result!\n } catch (error: unknown) {\n await killTransaction(req)\n throw error\n }\n}\n"],"names":["status","httpStatus","APIError","Forbidden","commitTransaction","initTransaction","killTransaction","executeAccess","getLoginOptions","resetLoginAttempts","unlockOperation","args","collection","config","collectionConfig","overrideAccess","req","locale","loginWithUsername","auth","canLoginWithEmail","canLoginWithUsername","sanitizedEmail","data","email","toLowerCase","trim","sanitizedUsername","username","disableLocalStrategy","t","BAD_REQUEST","shouldCommit","access","unlock","whereConstraint","equals","user","payload","db","findOne","slug","where","result","doc","error"],"mappings":"AAAA,SAASA,UAAUC,UAAU,QAAQ,cAAa;AASlD,SAASC,QAAQ,QAAQ,wBAAuB;AAChD,SAASC,SAAS,QAAQ,iBAAgB;AAC1C,SAASC,iBAAiB,QAAQ,uCAAsC;AACxE,SAASC,eAAe,QAAQ,qCAAoC;AACpE,SAASC,eAAe,QAAQ,qCAAoC;AACpE,OAAOC,mBAAmB,sBAAqB;AAC/C,SAASC,eAAe,QAAQ,wBAAuB;AACvD,SAASC,kBAAkB,QAAQ,4CAA2C;AAS9E,OAAO,MAAMC,kBAAkB,OAC7BC;IAEA,MAAM,EACJC,YAAY,EAAEC,QAAQC,gBAAgB,EAAE,EACxCC,cAAc,EACdC,KAAK,EAAEC,MAAM,EAAE,EACfD,GAAG,EACJ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jCxB,QAAQA;YACRD;YACA0B,OAAOP;QACT;QAEA,IAAIQ,SAAyB;QAE7B,IAAIN,MAAM;YACR,MAAM5B,mBAAmB;gBACvBG,YAAYE;gBACZ8B,KAAKP;gBACLC,SAAStB,IAAIsB,OAAO;gBACpBtB;YACF;YACA2B,SAAS;QACX,OAAO;YACLA,SAAS;QACX;QAEA,IAAIX,cAAc;YAChB,MAAM5B,kBAAkBY;QAC1B;QAEA,OAAO2B;IACT,EAAE,OAAOE,OAAgB;QACvB,MAAMvC,gBAAgBU;QACtB,MAAM6B;IACR;AACF,EAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"authenticate.d.ts","sourceRoot":"","sources":["../../../../src/auth/strategies/local/authenticate.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,sCAAsC,CAAA;AAEtE,KAAK,GAAG,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,UAAU,CAAA;AAE/C,KAAK,IAAI,GAAG;IACV,GAAG,EAAE,GAAG,CAAA;IACR,QAAQ,EAAE,MAAM,CAAA;CACjB,CAAA;AAED,eAAO,MAAM,yBAAyB,sBAA6B,IAAI,KAAG,OAAO,CAAC,GAAG,GAAG,IAAI,CA0B3F,CAAA"}
1
+ {"version":3,"file":"authenticate.d.ts","sourceRoot":"","sources":["../../../../src/auth/strategies/local/authenticate.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,sCAAsC,CAAA;AAEtE,KAAK,GAAG,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,UAAU,CAAA;AAE/C,KAAK,IAAI,GAAG;IACV,GAAG,EAAE,GAAG,CAAA;IACR,QAAQ,EAAE,MAAM,CAAA;CACjB,CAAA;AAED,eAAO,MAAM,yBAAyB,sBAA6B,IAAI,KAAG,OAAO,CAAC,GAAG,GAAG,IAAI,CA0B3F,CAAA"}
@@ -1,5 +1,6 @@
1
1
  // @ts-strict-ignore
2
2
  import crypto from 'crypto';
3
+ // @ts-expect-error - no types available
3
4
  import scmp from 'scmp';
4
5
  export const authenticateLocalStrategy = async ({ doc, password })=>{
5
6
  try {
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/auth/strategies/local/authenticate.ts"],"sourcesContent":["// @ts-strict-ignore\nimport crypto from 'crypto'\nimport scmp from 'scmp'\n\nimport type { TypeWithID } from '../../../collections/config/types.js'\n\ntype Doc = Record<string, unknown> & TypeWithID\n\ntype Args = {\n doc: Doc\n password: string\n}\n\nexport const authenticateLocalStrategy = async ({ doc, password }: Args): Promise<Doc | null> => {\n try {\n const { hash, salt } = doc\n\n if (typeof salt === 'string' && typeof hash === 'string') {\n const res = await new Promise<Doc | null>((resolve, reject) => {\n crypto.pbkdf2(password, salt, 25000, 512, 'sha256', (e, hashBuffer) => {\n if (e) {\n reject(e)\n }\n\n if (scmp(hashBuffer, Buffer.from(hash, 'hex'))) {\n resolve(doc)\n } else {\n reject(new Error('Invalid password'))\n }\n })\n })\n\n return res\n }\n\n return null\n } catch (ignore) {\n return null\n }\n}\n"],"names":["crypto","scmp","authenticateLocalStrategy","doc","password","hash","salt","res","Promise","resolve","reject","pbkdf2","e","hashBuffer","Buffer","from","Error","ignore"],"mappings":"AAAA,oBAAoB;AACpB,OAAOA,YAAY,SAAQ;AAC3B,OAAOC,UAAU,OAAM;AAWvB,OAAO,MAAMC,4BAA4B,OAAO,EAAEC,GAAG,EAAEC,QAAQ,EAAQ;IACrE,IAAI;QACF,MAAM,EAAEC,IAAI,EAAEC,IAAI,EAAE,GAAGH;QAEvB,IAAI,OAAOG,SAAS,YAAY,OAAOD,SAAS,UAAU;YACxD,MAAME,MAAM,MAAM,IAAIC,QAAoB,CAACC,SAASC;gBAClDV,OAAOW,MAAM,CAACP,UAAUE,MAAM,OAAO,KAAK,UAAU,CAACM,GAAGC;oBACtD,IAAID,GAAG;wBACLF,OAAOE;oBACT;oBAEA,IAAIX,KAAKY,YAAYC,OAAOC,IAAI,CAACV,MAAM,SAAS;wBAC9CI,QAAQN;oBACV,OAAO;wBACLO,OAAO,IAAIM,MAAM;oBACnB;gBACF;YACF;YAEA,OAAOT;QACT;QAEA,OAAO;IACT,EAAE,OAAOU,QAAQ;QACf,OAAO;IACT;AACF,EAAC"}
1
+ {"version":3,"sources":["../../../../src/auth/strategies/local/authenticate.ts"],"sourcesContent":["// @ts-strict-ignore\nimport crypto from 'crypto'\n// @ts-expect-error - no types available\nimport scmp from 'scmp'\n\nimport type { TypeWithID } from '../../../collections/config/types.js'\n\ntype Doc = Record<string, unknown> & TypeWithID\n\ntype Args = {\n doc: Doc\n password: string\n}\n\nexport const authenticateLocalStrategy = async ({ doc, password }: Args): Promise<Doc | null> => {\n try {\n const { hash, salt } = doc\n\n if (typeof salt === 'string' && typeof hash === 'string') {\n const res = await new Promise<Doc | null>((resolve, reject) => {\n crypto.pbkdf2(password, salt, 25000, 512, 'sha256', (e, hashBuffer) => {\n if (e) {\n reject(e)\n }\n\n if (scmp(hashBuffer, Buffer.from(hash, 'hex'))) {\n resolve(doc)\n } else {\n reject(new Error('Invalid password'))\n }\n })\n })\n\n return res\n }\n\n return null\n } catch (ignore) {\n return null\n }\n}\n"],"names":["crypto","scmp","authenticateLocalStrategy","doc","password","hash","salt","res","Promise","resolve","reject","pbkdf2","e","hashBuffer","Buffer","from","Error","ignore"],"mappings":"AAAA,oBAAoB;AACpB,OAAOA,YAAY,SAAQ;AAC3B,wCAAwC;AACxC,OAAOC,UAAU,OAAM;AAWvB,OAAO,MAAMC,4BAA4B,OAAO,EAAEC,GAAG,EAAEC,QAAQ,EAAQ;IACrE,IAAI;QACF,MAAM,EAAEC,IAAI,EAAEC,IAAI,EAAE,GAAGH;QAEvB,IAAI,OAAOG,SAAS,YAAY,OAAOD,SAAS,UAAU;YACxD,MAAME,MAAM,MAAM,IAAIC,QAAoB,CAACC,SAASC;gBAClDV,OAAOW,MAAM,CAACP,UAAUE,MAAM,OAAO,KAAK,UAAU,CAACM,GAAGC;oBACtD,IAAID,GAAG;wBACLF,OAAOE;oBACT;oBAEA,IAAIX,KAAKY,YAAYC,OAAOC,IAAI,CAACV,MAAM,SAAS;wBAC9CI,QAAQN;oBACV,OAAO;wBACLO,OAAO,IAAIM,MAAM;oBACnB;gBACF;YACF;YAEA,OAAOT;QACT;QAEA,OAAO;IACT,EAAE,OAAOU,QAAQ;QACf,OAAO;IACT;AACF,EAAC"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/bin/index.ts"],"sourcesContent":["// @ts-strict-ignore\n/* eslint-disable no-console */\nimport { Cron } from 'croner'\nimport minimist from 'minimist'\nimport { pathToFileURL } from 'node:url'\nimport path from 'path'\n\nimport { findConfig } from '../config/find.js'\nimport payload, { getPayload } from '../index.js'\nimport { generateImportMap } from './generateImportMap/index.js'\nimport { generateTypes } from './generateTypes.js'\nimport { info } from './info.js'\nimport { loadEnv } from './loadEnv.js'\nimport { migrate, availableCommands as migrateCommands } from './migrate.js'\n\n// Note: this does not account for any user bin scripts\nconst availableScripts = [\n 'generate:db-schema',\n 'generate:importmap',\n 'generate:types',\n 'info',\n 'jobs:run',\n 'run',\n ...migrateCommands,\n] as const\n\nexport const bin = async () => {\n loadEnv()\n\n const args = minimist(process.argv.slice(2))\n const script = (typeof args._[0] === 'string' ? args._[0] : '').toLowerCase()\n\n if (script === 'info') {\n await info()\n return\n }\n\n if (script === 'run') {\n const scriptPath = args._[1]\n if (!scriptPath) {\n console.error('Please provide a script path to run.')\n process.exit(1)\n }\n\n const absoluteScriptPath = path.resolve(process.cwd(), scriptPath)\n\n // Modify process.argv to remove 'run' and the script path\n const originalArgv = process.argv\n process.argv = [process.argv[0]!, process.argv[1]!, ...args._.slice(2)]\n\n try {\n await import(pathToFileURL(absoluteScriptPath).toString())\n } catch (error) {\n console.error(`Error running script: ${absoluteScriptPath}`)\n console.error(error)\n process.exit(1)\n } finally {\n // Restore original process.argv\n process.argv = originalArgv\n }\n return\n }\n\n const configPath = findConfig()\n const configPromise = await import(pathToFileURL(configPath).toString())\n let config = await configPromise\n if (config.default) {\n config = await config.default\n }\n\n const userBinScript = Array.isArray(config.bin)\n ? config.bin.find(({ key }) => key === script)\n : false\n\n if (userBinScript) {\n try {\n const module = await import(pathToFileURL(userBinScript.scriptPath).toString())\n\n if (!module.script || typeof module.script !== 'function') {\n console.error(\n `Could not find \"script\" function export for script ${userBinScript.key} in ${userBinScript.scriptPath}`,\n )\n } else {\n await module.script(config).catch((err: unknown) => {\n console.log(`Script ${userBinScript.key} failed, details:`)\n console.error(err)\n })\n }\n } catch (err) {\n console.log(`Could not find associated bin script for the ${userBinScript.key} command`)\n console.error(err)\n }\n\n return\n }\n\n if (script.startsWith('migrate')) {\n return migrate({ config, parsedArgs: args }).then(() => process.exit(0))\n }\n\n if (script === 'generate:types') {\n return generateTypes(config)\n }\n\n if (script === 'generate:importmap') {\n return generateImportMap(config)\n }\n\n if (script === 'jobs:run') {\n const payload = await getPayload({ config })\n const limit = args.limit ? parseInt(args.limit, 10) : undefined\n const queue = args.queue ? args.queue : undefined\n\n if (args.cron) {\n new Cron(args.cron, async () => {\n await payload.jobs.run({\n limit,\n queue,\n })\n })\n\n process.stdin.resume() // Keep the process alive\n\n return\n } else {\n await payload.jobs.run({\n limit,\n queue,\n })\n\n await payload.destroy() // close database connections after running jobs so process can exit cleanly\n\n return\n }\n }\n\n if (script === 'generate:db-schema') {\n // Barebones instance to access database adapter, without connecting to the DB\n await payload.init({\n config,\n disableDBConnect: true,\n disableOnInit: true,\n })\n\n if (typeof payload.db.generateSchema !== 'function') {\n payload.logger.error({\n msg: `${payload.db.packageName} does not support database schema generation`,\n })\n\n process.exit(1)\n }\n\n await payload.db.generateSchema({\n log: args.log === 'false' ? false : true,\n prettify: args.prettify === 'false' ? false : true,\n })\n\n process.exit(0)\n }\n\n console.error(script ? `Unknown command: \"${script}\"` : 'Please provide a command to run')\n console.log(`\\nAvailable commands:\\n${availableScripts.map((c) => ` - ${c}`).join('\\n')}`)\n\n process.exit(1)\n}\n"],"names":["Cron","minimist","pathToFileURL","path","findConfig","payload","getPayload","generateImportMap","generateTypes","info","loadEnv","migrate","availableCommands","migrateCommands","availableScripts","bin","args","process","argv","slice","script","_","toLowerCase","scriptPath","console","error","exit","absoluteScriptPath","resolve","cwd","originalArgv","toString","configPath","configPromise","config","default","userBinScript","Array","isArray","find","key","module","catch","err","log","startsWith","parsedArgs","then","limit","parseInt","undefined","queue","cron","jobs","run","stdin","resume","destroy","init","disableDBConnect","disableOnInit","db","generateSchema","logger","msg","packageName","prettify","map","c","join"],"mappings":"AAAA,oBAAoB;AACpB,6BAA6B,GAC7B,SAASA,IAAI,QAAQ,SAAQ;AAC7B,OAAOC,cAAc,WAAU;AAC/B,SAASC,aAAa,QAAQ,WAAU;AACxC,OAAOC,UAAU,OAAM;AAEvB,SAASC,UAAU,QAAQ,oBAAmB;AAC9C,OAAOC,WAAWC,UAAU,QAAQ,cAAa;AACjD,SAASC,iBAAiB,QAAQ,+BAA8B;AAChE,SAASC,aAAa,QAAQ,qBAAoB;AAClD,SAASC,IAAI,QAAQ,YAAW;AAChC,SAASC,OAAO,QAAQ,eAAc;AACtC,SAASC,OAAO,EAAEC,qBAAqBC,eAAe,QAAQ,eAAc;AAE5E,uDAAuD;AACvD,MAAMC,mBAAmB;IACvB;IACA;IACA;IACA;IACA;IACA;OACGD;CACJ;AAED,OAAO,MAAME,MAAM;IACjBL;IAEA,MAAMM,OAAOf,SAASgB,QAAQC,IAAI,CAACC,KAAK,CAAC;IACzC,MAAMC,SAAS,AAAC,CAAA,OAAOJ,KAAKK,CAAC,CAAC,EAAE,KAAK,WAAWL,KAAKK,CAAC,CAAC,EAAE,GAAG,EAAC,EAAGC,WAAW;IAE3E,IAAIF,WAAW,QAAQ;QACrB,MAAMX;QACN;IACF;IAEA,IAAIW,WAAW,OAAO;QACpB,MAAMG,aAAaP,KAAKK,CAAC,CAAC,EAAE;QAC5B,IAAI,CAACE,YAAY;YACfC,QAAQC,KAA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;QAEA,IAAI,OAAOvD,QAAQwD,EAAE,CAACC,cAAc,KAAK,YAAY;YACnDzD,QAAQ0D,MAAM,CAACtC,KAAK,CAAC;gBACnBuC,KAAK,GAAG3D,QAAQwD,EAAE,CAACI,WAAW,CAAC,4CAA4C,CAAC;YAC9E;YAEAhD,QAAQS,IAAI,CAAC;QACf;QAEA,MAAMrB,QAAQwD,EAAE,CAACC,cAAc,CAAC;YAC9BlB,KAAK5B,KAAK4B,GAAG,KAAK,UAAU,QAAQ;YACpCsB,UAAUlD,KAAKkD,QAAQ,KAAK,UAAU,QAAQ;QAChD;QAEAjD,QAAQS,IAAI,CAAC;IACf;IAEAF,QAAQC,KAAK,CAACL,SAAS,CAAC,kBAAkB,EAAEA,OAAO,CAAC,CAAC,GAAG;IACxDI,QAAQoB,GAAG,CAAC,CAAC,uBAAuB,EAAE9B,iBAAiBqD,GAAG,CAAC,CAACC,IAAM,CAAC,IAAI,EAAEA,GAAG,EAAEC,IAAI,CAAC,OAAO;IAE1FpD,QAAQS,IAAI,CAAC;AACf,EAAC"}
1
+ {"version":3,"sources":["../../src/bin/index.ts"],"sourcesContent":["// @ts-strict-ignore\n/* eslint-disable no-console */\nimport { Cron } from 'croner'\nimport minimist from 'minimist'\nimport { pathToFileURL } from 'node:url'\nimport path from 'path'\n\nimport { findConfig } from '../config/find.js'\nimport payload, { getPayload } from '../index.js'\nimport { generateImportMap } from './generateImportMap/index.js'\nimport { generateTypes } from './generateTypes.js'\nimport { info } from './info.js'\nimport { loadEnv } from './loadEnv.js'\nimport { migrate, availableCommands as migrateCommands } from './migrate.js'\n\n// Note: this does not account for any user bin scripts\nconst availableScripts = [\n 'generate:db-schema',\n 'generate:importmap',\n 'generate:types',\n 'info',\n 'jobs:run',\n 'run',\n ...migrateCommands,\n] as const\n\nexport const bin = async () => {\n loadEnv()\n\n const args = minimist(process.argv.slice(2))\n const script = (typeof args._[0] === 'string' ? args._[0] : '').toLowerCase()\n\n if (script === 'info') {\n await info()\n return\n }\n\n if (script === 'run') {\n const scriptPath = args._[1]\n if (!scriptPath) {\n console.error('Please provide a script path to run.')\n process.exit(1)\n }\n\n const absoluteScriptPath = path.resolve(process.cwd(), scriptPath)\n\n // Modify process.argv to remove 'run' and the script path\n const originalArgv = process.argv\n process.argv = [process.argv[0]!, process.argv[1]!, ...args._.slice(2)]\n\n try {\n await import(pathToFileURL(absoluteScriptPath).toString())\n } catch (error) {\n console.error(`Error running script: ${absoluteScriptPath}`)\n console.error(error)\n process.exit(1)\n } finally {\n // Restore original process.argv\n process.argv = originalArgv\n }\n return\n }\n\n const configPath = findConfig()\n const configPromise = await import(pathToFileURL(configPath).toString())\n let config = await configPromise\n if (config.default) {\n config = await config.default\n }\n\n const userBinScript = Array.isArray(config.bin)\n ? config.bin.find(({ key }: { key: string }) => key === script)\n : false\n\n if (userBinScript) {\n try {\n const module = await import(pathToFileURL(userBinScript.scriptPath).toString())\n\n if (!module.script || typeof module.script !== 'function') {\n console.error(\n `Could not find \"script\" function export for script ${userBinScript.key} in ${userBinScript.scriptPath}`,\n )\n } else {\n await module.script(config).catch((err: unknown) => {\n console.log(`Script ${userBinScript.key} failed, details:`)\n console.error(err)\n })\n }\n } catch (err) {\n console.log(`Could not find associated bin script for the ${userBinScript.key} command`)\n console.error(err)\n }\n\n return\n }\n\n if (script.startsWith('migrate')) {\n return migrate({ config, parsedArgs: args }).then(() => process.exit(0))\n }\n\n if (script === 'generate:types') {\n return generateTypes(config)\n }\n\n if (script === 'generate:importmap') {\n return generateImportMap(config)\n }\n\n if (script === 'jobs:run') {\n const payload = await getPayload({ config })\n const limit = args.limit ? parseInt(args.limit, 10) : undefined\n const queue = args.queue ? args.queue : undefined\n\n if (args.cron) {\n new Cron(args.cron, async () => {\n await payload.jobs.run({\n limit,\n queue,\n })\n })\n\n process.stdin.resume() // Keep the process alive\n\n return\n } else {\n await payload.jobs.run({\n limit,\n queue,\n })\n\n await payload.destroy() // close database connections after running jobs so process can exit cleanly\n\n return\n }\n }\n\n if (script === 'generate:db-schema') {\n // Barebones instance to access database adapter, without connecting to the DB\n await payload.init({\n config,\n disableDBConnect: true,\n disableOnInit: true,\n })\n\n if (typeof payload.db.generateSchema !== 'function') {\n payload.logger.error({\n msg: `${payload.db.packageName} does not support database schema generation`,\n })\n\n process.exit(1)\n }\n\n await payload.db.generateSchema({\n log: args.log === 'false' ? false : true,\n prettify: args.prettify === 'false' ? false : true,\n })\n\n process.exit(0)\n }\n\n console.error(script ? `Unknown command: \"${script}\"` : 'Please provide a command to run')\n console.log(`\\nAvailable commands:\\n${availableScripts.map((c) => ` - ${c}`).join('\\n')}`)\n\n process.exit(1)\n}\n"],"names":["Cron","minimist","pathToFileURL","path","findConfig","payload","getPayload","generateImportMap","generateTypes","info","loadEnv","migrate","availableCommands","migrateCommands","availableScripts","bin","args","process","argv","slice","script","_","toLowerCase","scriptPath","console","error","exit","absoluteScriptPath","resolve","cwd","originalArgv","toString","configPath","configPromise","config","default","userBinScript","Array","isArray","find","key","module","catch","err","log","startsWith","parsedArgs","then","limit","parseInt","undefined","queue","cron","jobs","run","stdin","resume","destroy","init","disableDBConnect","disableOnInit","db","generateSchema","logger","msg","packageName","prettify","map","c","join"],"mappings":"AAAA,oBAAoB;AACpB,6BAA6B,GAC7B,SAASA,IAAI,QAAQ,SAAQ;AAC7B,OAAOC,cAAc,WAAU;AAC/B,SAASC,aAAa,QAAQ,WAAU;AACxC,OAAOC,UAAU,OAAM;AAEvB,SAASC,UAAU,QAAQ,oBAAmB;AAC9C,OAAOC,WAAWC,UAAU,QAAQ,cAAa;AACjD,SAASC,iBAAiB,QAAQ,+BAA8B;AAChE,SAASC,aAAa,QAAQ,qBAAoB;AAClD,SAASC,IAAI,QAAQ,YAAW;AAChC,SAASC,OAAO,QAAQ,eAAc;AACtC,SAASC,OAAO,EAAEC,qBAAqBC,eAAe,QAAQ,eAAc;AAE5E,uDAAuD;AACvD,MAAMC,mBAAmB;IACvB;IACA;IACA;IACA;IACA;IACA;OACGD;CACJ;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B,CAAA;AAczD,eAAO,MAAM,iBAAiB,UAQ7B,CAAA;AAID,KAAK,IAAI,GAAG;IACV,MAAM,EAAE,eAAe,CAAA;IACvB,UAAU,EAAE,UAAU,CAAA;CACvB,CAAA;AAED,eAAO,MAAM,OAAO,2BAAkC,IAAI,KAAG,OAAO,CAAC,IAAI,CA4FxE,CAAA"}
1
+ {"version":3,"file":"migrate.d.ts","sourceRoot":"","sources":["../../src/bin/migrate.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;AAE1C,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAA;AAczD,eAAO,MAAM,iBAAiB,UAQ7B,CAAA;AAID,KAAK,IAAI,GAAG;IACV,MAAM,EAAE,eAAe,CAAA;IACvB,UAAU,EAAE,UAAU,CAAA;CACvB,CAAA;AAED,eAAO,MAAM,OAAO,2BAAkC,IAAI,KAAG,OAAO,CAAC,IAAI,CA6FxE,CAAA"}
@@ -1,4 +1,3 @@
1
- // @ts-strict-ignore
2
1
  import payload from '../index.js';
3
2
  import { prettySyncLoggerDestination } from '../utilities/logger.js';
4
3
  /**
@@ -67,7 +66,8 @@ export const migrate = async ({ config, parsedArgs })=>{
67
66
  skipEmpty
68
67
  });
69
68
  } catch (err) {
70
- throw new Error(`Error creating migration: ${err.message}`);
69
+ const error = err instanceof Error ? err.message : 'Unknown error';
70
+ throw new Error(`Error creating migration: ${error}`);
71
71
  }
72
72
  break;
73
73
  case 'migrate:down':
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/bin/migrate.ts"],"sourcesContent":["// @ts-strict-ignore\nimport type { ParsedArgs } from 'minimist'\n\nimport type { SanitizedConfig } from '../config/types.js'\n\nimport payload from '../index.js'\nimport { prettySyncLoggerDestination } from '../utilities/logger.js'\n\n/**\n * The default logger's options did not allow for forcing sync logging\n * Using these options, to force both pretty print and sync logging\n */\nconst prettySyncLogger = {\n loggerDestination: prettySyncLoggerDestination,\n loggerOptions: {},\n}\n\nexport const availableCommands = [\n 'migrate',\n 'migrate:create',\n 'migrate:down',\n 'migrate:refresh',\n 'migrate:reset',\n 'migrate:status',\n 'migrate:fresh',\n]\n\nconst availableCommandsMsg = `Available commands: ${availableCommands.join(', ')}`\n\ntype Args = {\n config: SanitizedConfig\n parsedArgs: ParsedArgs\n}\n\nexport const migrate = async ({ config, parsedArgs }: Args): Promise<void> => {\n const { _: args, file, forceAcceptWarning: forceAcceptFromProps, help } = parsedArgs\n\n const formattedArgs = Object.keys(parsedArgs)\n .map((key) => {\n const formattedKey = key.replace(/^[-_]+/, '')\n if (!formattedKey) {\n return null\n }\n\n return formattedKey\n .split('-')\n .map((word, index) =>\n index === 0 ? word.toLowerCase() : word.charAt(0).toUpperCase() + word.slice(1),\n )\n .join('')\n })\n .filter(Boolean)\n\n const forceAcceptWarning = forceAcceptFromProps || formattedArgs.includes('forceAcceptWarning')\n const skipEmpty = formattedArgs.includes('skipEmpty')\n\n if (help) {\n // eslint-disable-next-line no-console\n console.log(`\\n\\n${availableCommandsMsg}\\n`) // Avoid having to init payload to get the logger\n process.exit(0)\n }\n\n process.env.PAYLOAD_MIGRATING = 'true'\n\n // Barebones instance to access database adapter\n await payload.init({\n config,\n disableDBConnect: args[0] === 'migrate:create',\n disableOnInit: true,\n ...prettySyncLogger,\n })\n\n const adapter = payload.db\n\n if (!adapter) {\n throw new Error('No database adapter found')\n }\n\n if (!args.length) {\n payload.logger.error({\n msg: `No migration command provided. ${availableCommandsMsg}`,\n })\n process.exit(1)\n }\n\n switch (args[0]) {\n case 'migrate':\n await adapter.migrate()\n break\n case 'migrate:create':\n try {\n await adapter.createMigration({\n file,\n forceAcceptWarning,\n migrationName: args[1],\n payload,\n skipEmpty,\n })\n } catch (err) {\n throw new Error(`Error creating migration: ${err.message}`)\n }\n break\n case 'migrate:down':\n await adapter.migrateDown()\n break\n case 'migrate:fresh':\n await adapter.migrateFresh({ forceAcceptWarning })\n break\n case 'migrate:refresh':\n await adapter.migrateRefresh()\n break\n case 'migrate:reset':\n await adapter.migrateReset()\n break\n case 'migrate:status':\n await adapter.migrateStatus()\n break\n\n default:\n payload.logger.error({\n msg: `Unknown migration command: ${args[0]}. ${availableCommandsMsg}`,\n })\n process.exit(1)\n }\n\n payload.logger.info('Done.')\n}\n"],"names":["payload","prettySyncLoggerDestination","prettySyncLogger","loggerDestination","loggerOptions","availableCommands","availableCommandsMsg","join","migrate","config","parsedArgs","_","args","file","forceAcceptWarning","forceAcceptFromProps","help","formattedArgs","Object","keys","map","key","formattedKey","replace","split","word","index","toLowerCase","charAt","toUpperCase","slice","filter","Boolean","includes","skipEmpty","console","log","process","exit","env","PAYLOAD_MIGRATING","init","disableDBConnect","disableOnInit","adapter","db","Error","length","logger","error","msg","createMigration","migrationName","err","message","migrateDown","migrateFresh","migrateRefresh","migrateReset","migrateStatus","info"],"mappings":"AAAA,oBAAoB;AAKpB,OAAOA,aAAa,cAAa;AACjC,SAASC,2BAA2B,QAAQ,yBAAwB;AAEpE;;;CAGC,GACD,MAAMC,mBAAmB;IACvBC,mBAAmBF;IACnBG,eAAe,CAAC;AAClB;AAEA,OAAO,MAAMC,oBAAoB;IAC/B;IACA;IACA;IACA;IACA;IACA;IACA;CACD,CAAA;AAED,MAAMC,uBAAuB,CAAC,oBAAoB,EAAED,kBAAkBE,IAAI,CAAC,OAAO;AAOlF,OAAO,MAAMC,UAAU,OAAO,EAAEC,MAAM,EAAEC,UAAU,EAAQ;IACxD,MAAM,EAAEC,GAAGC,IAAI,EAAEC,IAAI,EAAEC,oBAAoBC,oBAAoB,EAAEC,IAAI,EAAE,GAAGN;IAE1E,MAAMO,gBAAgBC,OAAOC,IAAI,CAACT,YAC/BU,GAAG,CAAC,CAACC;QACJ,MAAMC,eAAeD,IAAIE,OAAO,CAAC,UAAU;QAC3C,IAAI,CAACD,cAAc;YACjB,OAAO;QACT;QAEA,OAAOA,aACJE,KAAK,CAAC,KACNJ,GAAG,CAAC,CAACK,MAAMC,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,CAAC;gBAAE1C;YAAmB;YAChD;QACF,KAAK;YACH,MAAM8B,QAAQa,cAAc;YAC5B;QACF,KAAK;YACH,MAAMb,QAAQc,YAAY;YAC1B;QACF,KAAK;YACH,MAAMd,QAAQe,aAAa;YAC3B;QAEF;YACE3D,QAAQgD,MAAM,CAACC,KAAK,CAAC;gBACnBC,KAAK,CAAC,2BAA2B,EAAEtC,IAAI,CAAC,EAAE,CAAC,EAAE,EAAEN,sBAAsB;YACvE;YACA+B,QAAQC,IAAI,CAAC;IACjB;IAEAtC,QAAQgD,MAAM,CAACY,IAAI,CAAC;AACtB,EAAC"}
1
+ {"version":3,"sources":["../../src/bin/migrate.ts"],"sourcesContent":["import type { ParsedArgs } from 'minimist'\n\nimport type { SanitizedConfig } from '../config/types.js'\n\nimport payload from '../index.js'\nimport { prettySyncLoggerDestination } from '../utilities/logger.js'\n\n/**\n * The default logger's options did not allow for forcing sync logging\n * Using these options, to force both pretty print and sync logging\n */\nconst prettySyncLogger = {\n loggerDestination: prettySyncLoggerDestination,\n loggerOptions: {},\n}\n\nexport const availableCommands = [\n 'migrate',\n 'migrate:create',\n 'migrate:down',\n 'migrate:refresh',\n 'migrate:reset',\n 'migrate:status',\n 'migrate:fresh',\n]\n\nconst availableCommandsMsg = `Available commands: ${availableCommands.join(', ')}`\n\ntype Args = {\n config: SanitizedConfig\n parsedArgs: ParsedArgs\n}\n\nexport const migrate = async ({ config, parsedArgs }: Args): Promise<void> => {\n const { _: args, file, forceAcceptWarning: forceAcceptFromProps, help } = parsedArgs\n\n const formattedArgs = Object.keys(parsedArgs)\n .map((key) => {\n const formattedKey = key.replace(/^[-_]+/, '')\n if (!formattedKey) {\n return null\n }\n\n return formattedKey\n .split('-')\n .map((word, index) =>\n index === 0 ? word.toLowerCase() : word.charAt(0).toUpperCase() + word.slice(1),\n )\n .join('')\n })\n .filter(Boolean)\n\n const forceAcceptWarning = forceAcceptFromProps || formattedArgs.includes('forceAcceptWarning')\n const skipEmpty = formattedArgs.includes('skipEmpty')\n\n if (help) {\n // eslint-disable-next-line no-console\n console.log(`\\n\\n${availableCommandsMsg}\\n`) // Avoid having to init payload to get the logger\n process.exit(0)\n }\n\n process.env.PAYLOAD_MIGRATING = 'true'\n\n // Barebones instance to access database adapter\n await payload.init({\n config,\n disableDBConnect: args[0] === 'migrate:create',\n disableOnInit: true,\n ...prettySyncLogger,\n })\n\n const adapter = payload.db\n\n if (!adapter) {\n throw new Error('No database adapter found')\n }\n\n if (!args.length) {\n payload.logger.error({\n msg: `No migration command provided. ${availableCommandsMsg}`,\n })\n process.exit(1)\n }\n\n switch (args[0]) {\n case 'migrate':\n await adapter.migrate()\n break\n case 'migrate:create':\n try {\n await adapter.createMigration({\n file,\n forceAcceptWarning,\n migrationName: args[1],\n payload,\n skipEmpty,\n })\n } catch (err) {\n const error = err instanceof Error ? err.message : 'Unknown error'\n throw new Error(`Error creating migration: ${error}`)\n }\n break\n case 'migrate:down':\n await adapter.migrateDown()\n break\n case 'migrate:fresh':\n await adapter.migrateFresh({ forceAcceptWarning })\n break\n case 'migrate:refresh':\n await adapter.migrateRefresh()\n break\n case 'migrate:reset':\n await adapter.migrateReset()\n break\n case 'migrate:status':\n await adapter.migrateStatus()\n break\n\n default:\n payload.logger.error({\n msg: `Unknown migration command: ${args[0]}. ${availableCommandsMsg}`,\n })\n process.exit(1)\n }\n\n payload.logger.info('Done.')\n}\n"],"names":["payload","prettySyncLoggerDestination","prettySyncLogger","loggerDestination","loggerOptions","availableCommands","availableCommandsMsg","join","migrate","config","parsedArgs","_","args","file","forceAcceptWarning","forceAcceptFromProps","help","formattedArgs","Object","keys","map","key","formattedKey","replace","split","word","index","toLowerCase","charAt","toUpperCase","slice","filter","Boolean","includes","skipEmpty","console","log","process","exit","env","PAYLOAD_MIGRATING","init","disableDBConnect","disableOnInit","adapter","db","Error","length","logger","error","msg","createMigration","migrationName","err","message","migrateDown","migrateFresh","migrateRefresh","migrateReset","migrateStatus","info"],"mappings":"AAIA,OAAOA,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ACrB;IAEA,MAAM0C,UAAU5C,QAAQ6C,EAAE;IAE1B,IAAI,CAACD,SAAS;QACZ,MAAM,IAAIE,MAAM;IAClB;IAEA,IAAI,CAAClC,KAAKmC,MAAM,EAAE;QAChB/C,QAAQgD,MAAM,CAACC,KAAK,CAAC;YACnBC,KAAK,CAAC,+BAA+B,EAAE5C,sBAAsB;QAC/D;QACA+B,QAAQC,IAAI,CAAC;IACf;IAEA,OAAQ1B,IAAI,CAAC,EAAE;QACb,KAAK;YACH,MAAMgC,QAAQpC,OAAO;YACrB;QACF,KAAK;YACH,IAAI;gBACF,MAAMoC,QAAQO,eAAe,CAAC;oBAC5BtC;oBACAC;oBACAsC,eAAexC,IAAI,CAAC,EAAE;oBACtBZ;oBACAkC;gBACF;YACF,EAAE,OAAOmB,KAAK;gBACZ,MAAMJ,QAAQI,eAAeP,QAAQO,IAAIC,OAAO,GAAG;gBACnD,MAAM,IAAIR,MAAM,CAAC,0BAA0B,EAAEG,OAAO;YACtD;YACA;QACF,KAAK;YACH,MAAML,QAAQW,WAAW;YACzB;QACF,KAAK;YACH,MAAMX,QAAQY,YAAY,CAAC;gBAAE1C;YAAmB;YAChD;QACF,KAAK;YACH,MAAM8B,QAAQa,cAAc;YAC5B;QACF,KAAK;YACH,MAAMb,QAAQc,YAAY;YAC1B;QACF,KAAK;YACH,MAAMd,QAAQe,aAAa;YAC3B;QAEF;YACE3D,QAAQgD,MAAM,CAACC,KAAK,CAAC;gBACnBC,KAAK,CAAC,2BAA2B,EAAEtC,IAAI,CAAC,EAAE,CAAC,EAAE,EAAEN,sBAAsB;YACvE;YACA+B,QAAQC,IAAI,CAAC;IACjB;IAEAtC,QAAQgD,MAAM,CAACY,IAAI,CAAC;AACtB,EAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../src/collections/config/client.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAA;AAE1D,OAA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AAQ,GAAG,QAAQ,GAAG,8BAA8B,CACxE,CAAA;AAiCD,eAAO,MAAM,4BAA4B,oDAKtC;IACD,UAAU,EAAE,yBAAyB,CAAA;IACrC,aAAa,EAAE,OAAO,CAAC,QAAQ,CAAC,CAAC,IAAI,CAAC,CAAC,eAAe,CAAC,CAAA;IACvD,IAAI,EAAE,UAAU,CAAA;IAChB,SAAS,EAAE,SAAS,CAAA;CACrB,KAAG,sBA+IH,CAAA;AAED,eAAO,MAAM,6BAA6B,qDAKvC;IACD,WAAW,EAAE,yBAAyB,EAAE,CAAA;IACxC,aAAa,EAAE,OAAO,CAAC,QAAQ,CAAC,CAAC,IAAI,CAAC,CAAC,eAAe,CAAC,CAAA;IACvD,IAAI,EAAE,UAAU,CAAA;IAChB,SAAS,EAAE,SAAS,CAAA;CACrB,KAAG,sBAAsB,EAezB,CAAA"}
@@ -1,4 +1,3 @@
1
- // @ts-strict-ignore
2
1
  import { createClientFields } from '../../fields/config/client.js';
3
2
  const serverOnlyCollectionProperties = [
4
3
  'hooks',
@@ -66,6 +65,7 @@ export const createClientCollectionConfig = ({ collection, defaultIDType, i18n,
66
65
  }
67
66
  break;
68
67
  default:
68
+ ;
69
69
  clientCollection.admin[adminKey] = collection.admin[adminKey];
70
70
  }
71
71
  }
@@ -149,11 +149,13 @@ export const createClientCollectionConfig = ({ collection, defaultIDType, i18n,
149
149
  return sanitizedSize;
150
150
  });
151
151
  } else {
152
+ ;
152
153
  clientCollection.upload[uploadKey] = collection.upload[uploadKey];
153
154
  }
154
155
  }
155
156
  break;
156
157
  default:
158
+ ;
157
159
  clientCollection[key] = collection[key];
158
160
  }
159
161
  }