payload 3.0.0-beta.47 → 3.0.0-beta.48

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.
@@ -1,5 +1,6 @@
1
+ import type { AcceptedLanguages } from '@payloadcms/translations';
1
2
  export type LanguageOptions = {
2
3
  label: string;
3
- value: string;
4
+ value: AcceptedLanguages;
4
5
  }[];
5
6
  //# sourceMappingURL=LanguageOptions.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"LanguageOptions.d.ts","sourceRoot":"","sources":["../../src/admin/LanguageOptions.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,eAAe,GAAG;IAC5B,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,MAAM,CAAA;CACd,EAAE,CAAA"}
1
+ {"version":3,"file":"LanguageOptions.d.ts","sourceRoot":"","sources":["../../src/admin/LanguageOptions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,MAAM,MAAM,eAAe,GAAG;IAC5B,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,iBAAiB,CAAA;CACzB,EAAE,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/admin/LanguageOptions.ts"],"sourcesContent":["export type LanguageOptions = {\n label: string\n value: string\n}[]\n"],"names":[],"rangeMappings":"","mappings":"AAAA,WAGG"}
1
+ {"version":3,"sources":["../../src/admin/LanguageOptions.ts"],"sourcesContent":["import type { AcceptedLanguages } from '@payloadcms/translations'\n\nexport type LanguageOptions = {\n label: string\n value: AcceptedLanguages\n}[]\n"],"names":[],"rangeMappings":"","mappings":"AAEA,WAGG"}
@@ -5,6 +5,7 @@ export type LabelProps = {
5
5
  htmlFor?: string;
6
6
  label?: Record<string, string> | string;
7
7
  required?: boolean;
8
+ schemaPath?: string;
8
9
  unstyled?: boolean;
9
10
  };
10
11
  export type SanitizedLabelProps = Omit<LabelProps, 'label' | 'required'>;
@@ -1 +1 @@
1
- {"version":3,"file":"Label.d.ts","sourceRoot":"","sources":["../../../src/admin/forms/Label.ts"],"names":[],"mappings":";AAAA,MAAM,MAAM,UAAU,GAAG;IACvB,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IAC7B,EAAE,CAAC,EAAE,OAAO,GAAG,MAAM,CAAA;IACrB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,MAAM,CAAA;IACvC,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,CAAA;AAED,MAAM,MAAM,mBAAmB,GAAG,IAAI,CAAC,UAAU,EAAE,OAAO,GAAG,UAAU,CAAC,CAAA"}
1
+ {"version":3,"file":"Label.d.ts","sourceRoot":"","sources":["../../../src/admin/forms/Label.ts"],"names":[],"mappings":";AAAA,MAAM,MAAM,UAAU,GAAG;IACvB,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IAC7B,EAAE,CAAC,EAAE,OAAO,GAAG,MAAM,CAAA;IACrB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,MAAM,CAAA;IACvC,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,CAAA;AAED,MAAM,MAAM,mBAAmB,GAAG,IAAI,CAAC,UAAU,EAAE,OAAO,GAAG,UAAU,CAAC,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/admin/forms/Label.ts"],"sourcesContent":["export type LabelProps = {\n CustomLabel?: React.ReactNode\n as?: 'label' | 'span'\n htmlFor?: string\n label?: Record<string, string> | string\n required?: boolean\n unstyled?: boolean\n}\n\nexport type SanitizedLabelProps = Omit<LabelProps, 'label' | 'required'>\n"],"names":[],"rangeMappings":"","mappings":"AASA,WAAwE"}
1
+ {"version":3,"sources":["../../../src/admin/forms/Label.ts"],"sourcesContent":["export type LabelProps = {\n CustomLabel?: React.ReactNode\n as?: 'label' | 'span'\n htmlFor?: string\n label?: Record<string, string> | string\n required?: boolean\n schemaPath?: string\n unstyled?: boolean\n}\n\nexport type SanitizedLabelProps = Omit<LabelProps, 'label' | 'required'>\n"],"names":[],"rangeMappings":"","mappings":"AAUA,WAAwE"}
@@ -61,7 +61,7 @@ export const forgotPasswordOperation = async (incomingArgs)=>{
61
61
  ;
62
62
  const serverURL = config.serverURL !== null && config.serverURL !== '' ? config.serverURL : `${protocol}//${req.headers.get('host')}`;
63
63
  let html = `${req.t('authentication:youAreReceivingResetPassword')}
64
- <a href="${serverURL}${config.routes.admin}/reset/${token}">${serverURL}${config.routes.admin}/reset/${token}</a>
64
+ <a href="${serverURL}${config.routes.admin}/${config.admin.routes.reset}/${token}">${serverURL}${config.routes.admin}/${config.admin.routes.reset}/${token}</a>
65
65
  ${req.t('authentication:youDidNotRequestPassword')}`;
66
66
  if (typeof collectionConfig.auth.forgotPassword.generateEmailHTML === 'function') {
67
67
  html = await collectionConfig.auth.forgotPassword.generateEmailHTML({
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/auth/operations/forgotPassword.ts"],"sourcesContent":["import crypto from 'crypto'\nimport httpStatus from 'http-status'\nimport { URL } from 'url'\n\nimport type { Collection } from '../../collections/config/types.js'\nimport type { PayloadRequestWithData } from '../../types/index.js'\n\nimport { buildAfterOperation } from '../../collections/operations/utils.js'\nimport { APIError } from '../../errors/index.js'\nimport { commitTransaction } from '../../utilities/commitTransaction.js'\nimport { initTransaction } from '../../utilities/initTransaction.js'\nimport { killTransaction } from '../../utilities/killTransaction.js'\n\nexport type Arguments = {\n collection: Collection\n data: {\n [key: string]: unknown\n email: string\n }\n disableEmail?: boolean\n expiration?: number\n req: PayloadRequestWithData\n}\n\nexport type Result = string\n\nexport const forgotPasswordOperation = async (incomingArgs: Arguments): Promise<null | string> => {\n if (!Object.prototype.hasOwnProperty.call(incomingArgs.data, 'email')) {\n throw new APIError('Missing email.', httpStatus.BAD_REQUEST)\n }\n\n let args = incomingArgs\n\n try {\n const shouldCommit = await initTransaction(args.req)\n\n // /////////////////////////////////////\n // beforeOperation - Collection\n // /////////////////////////////////////\n\n await args.collection.config.hooks.beforeOperation.reduce(async (priorHook, hook) => {\n await priorHook\n\n args =\n (await hook({\n args,\n collection: args.collection?.config,\n context: args.req.context,\n operation: 'forgotPassword',\n req: args.req,\n })) || args\n }, Promise.resolve())\n\n const {\n collection: { config: collectionConfig },\n data,\n disableEmail,\n expiration,\n req: {\n payload: { config, email },\n payload,\n },\n req,\n } = args\n\n // /////////////////////////////////////\n // Forget password\n // /////////////////////////////////////\n\n let token: string = crypto.randomBytes(20).toString('hex')\n\n type UserDoc = {\n id: number | string\n resetPasswordExpiration?: string\n resetPasswordToken?: string\n }\n\n if (!data.email) {\n throw new APIError('Missing email.', httpStatus.BAD_REQUEST)\n }\n\n let user = await payload.db.findOne<UserDoc>({\n collection: collectionConfig.slug,\n req,\n where: { email: { equals: data.email.toLowerCase() } },\n })\n\n // We don't want to indicate specifically that an email was not found,\n // as doing so could lead to the exposure of registered emails.\n // Therefore, we prefer to fail silently.\n if (!user) return null\n\n user.resetPasswordToken = token\n user.resetPasswordExpiration = new Date(expiration || Date.now() + 3600000).toISOString() // 1 hour\n\n user = await payload.update({\n id: user.id,\n collection: collectionConfig.slug,\n data: user,\n req,\n })\n\n if (!disableEmail) {\n const protocol = new URL(req.url).protocol // includes the final :\n const serverURL =\n config.serverURL !== null && config.serverURL !== ''\n ? config.serverURL\n : `${protocol}//${req.headers.get('host')}`\n\n let html = `${req.t('authentication:youAreReceivingResetPassword')}\n <a href=\"${serverURL}${config.routes.admin}/reset/${token}\">${serverURL}${config.routes.admin}/reset/${token}</a>\n ${req.t('authentication:youDidNotRequestPassword')}`\n\n if (typeof collectionConfig.auth.forgotPassword.generateEmailHTML === 'function') {\n html = await collectionConfig.auth.forgotPassword.generateEmailHTML({\n req,\n token,\n user,\n })\n }\n\n let subject = req.t('authentication:resetYourPassword')\n\n if (typeof collectionConfig.auth.forgotPassword.generateEmailSubject === 'function') {\n subject = await collectionConfig.auth.forgotPassword.generateEmailSubject({\n req,\n token,\n user,\n })\n }\n\n await email.sendEmail({\n from: `\"${email.defaultFromName}\" <${email.defaultFromAddress}>`,\n html,\n subject,\n to: data.email,\n })\n }\n\n // /////////////////////////////////////\n // afterForgotPassword - Collection\n // /////////////////////////////////////\n\n await collectionConfig.hooks.afterForgotPassword.reduce(async (priorHook, hook) => {\n await priorHook\n await hook({ args, collection: args.collection?.config, context: req.context })\n }, Promise.resolve())\n\n // /////////////////////////////////////\n // afterOperation - Collection\n // /////////////////////////////////////\n\n token = await buildAfterOperation({\n args,\n collection: args.collection?.config,\n operation: 'forgotPassword',\n result: token,\n })\n\n if (shouldCommit) await commitTransaction(req)\n\n return token\n } catch (error: unknown) {\n await killTransaction(args.req)\n throw error\n }\n}\n"],"names":["crypto","httpStatus","URL","buildAfterOperation","APIError","commitTransaction","initTransaction","killTransaction","forgotPasswordOperation","incomingArgs","Object","prototype","hasOwnProperty","call","data","BAD_REQUEST","args","shouldCommit","req","collection","config","hooks","beforeOperation","reduce","priorHook","hook","context","operation","Promise","resolve","collectionConfig","disableEmail","expiration","payload","email","token","randomBytes","toString","user","db","findOne","slug","where","equals","toLowerCase","resetPasswordToken","resetPasswordExpiration","Date","now","toISOString","update","id","protocol","url","serverURL","headers","get","html","t","routes","admin","auth","forgotPassword","generateEmailHTML","subject","generateEmailSubject","sendEmail","from","defaultFromName","defaultFromAddress","to","afterForgotPassword","result","error"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mapp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CAACC,cAAc,CAACC,iBAAiB,CAAC;oBAClE7C;oBACAiB;oBACAG;gBACF;YACF;YAEA,IAAI0B,UAAU9C,IAAIwC,CAAC,CAAC;YAEpB,IAAI,OAAO5B,iBAAiB+B,IAAI,CAACC,cAAc,CAACG,oBAAoB,KAAK,YAAY;gBACnFD,UAAU,MAAMlC,iBAAiB+B,IAAI,CAACC,cAAc,CAACG,oBAAoB,CAAC;oBACxE/C;oBACAiB;oBACAG;gBACF;YACF;YAEA,MAAMJ,MAAMgC,SAAS,CAAC;gBACpBC,MAAM,CAAC,CAAC,EAAEjC,MAAMkC,eAAe,CAAC,GAAG,EAAElC,MAAMmC,kBAAkB,CAAC,CAAC,CAAC;gBAChEZ;gBACAO;gBACAM,IAAIxD,KAAKoB,KAAK;YAChB;QACF;QAEA,wCAAwC;QACxC,mCAAmC;QACnC,wCAAwC;QAExC,MAAMJ,iBAAiBT,KAAK,CAACkD,mBAAmB,CAAChD,MAAM,CAAC,OAAOC,WAAWC;YACxE,MAAMD;YACN,MAAMC,KAAK;gBAAET;gBAAMG,YAAYH,KAAKG,UAAU,EAAEC;gBAAQM,SAASR,IAAIQ,OAAO;YAAC;QAC/E,GAAGE,QAAQC,OAAO;QAElB,wCAAwC;QACxC,8BAA8B;QAC9B,wCAAwC;QAExCM,QAAQ,MAAMhC,oBAAoB;YAChCa;YACAG,YAAYH,KAAKG,UAAU,EAAEC;YAC7BO,WAAW;YACX6C,QAAQrC;QACV;QAEA,IAAIlB,cAAc,MAAMZ,kBAAkBa;QAE1C,OAAOiB;IACT,EAAE,OAAOsC,OAAgB;QACvB,MAAMlE,gBAAgBS,KAAKE,GAAG;QAC9B,MAAMuD;IACR;AACF,EAAC"}
1
+ {"version":3,"sources":["../../../src/auth/operations/forgotPassword.ts"],"sourcesContent":["import crypto from 'crypto'\nimport httpStatus from 'http-status'\nimport { URL } from 'url'\n\nimport type { Collection } from '../../collections/config/types.js'\nimport type { PayloadRequestWithData } from '../../types/index.js'\n\nimport { buildAfterOperation } from '../../collections/operations/utils.js'\nimport { APIError } from '../../errors/index.js'\nimport { commitTransaction } from '../../utilities/commitTransaction.js'\nimport { initTransaction } from '../../utilities/initTransaction.js'\nimport { killTransaction } from '../../utilities/killTransaction.js'\n\nexport type Arguments = {\n collection: Collection\n data: {\n [key: string]: unknown\n email: string\n }\n disableEmail?: boolean\n expiration?: number\n req: PayloadRequestWithData\n}\n\nexport type Result = string\n\nexport const forgotPasswordOperation = async (incomingArgs: Arguments): Promise<null | string> => {\n if (!Object.prototype.hasOwnProperty.call(incomingArgs.data, 'email')) {\n throw new APIError('Missing email.', httpStatus.BAD_REQUEST)\n }\n\n let args = incomingArgs\n\n try {\n const shouldCommit = await initTransaction(args.req)\n\n // /////////////////////////////////////\n // beforeOperation - Collection\n // /////////////////////////////////////\n\n await args.collection.config.hooks.beforeOperation.reduce(async (priorHook, hook) => {\n await priorHook\n\n args =\n (await hook({\n args,\n collection: args.collection?.config,\n context: args.req.context,\n operation: 'forgotPassword',\n req: args.req,\n })) || args\n }, Promise.resolve())\n\n const {\n collection: { config: collectionConfig },\n data,\n disableEmail,\n expiration,\n req: {\n payload: { config, email },\n payload,\n },\n req,\n } = args\n\n // /////////////////////////////////////\n // Forget password\n // /////////////////////////////////////\n\n let token: string = crypto.randomBytes(20).toString('hex')\n\n type UserDoc = {\n id: number | string\n resetPasswordExpiration?: string\n resetPasswordToken?: string\n }\n\n if (!data.email) {\n throw new APIError('Missing email.', httpStatus.BAD_REQUEST)\n }\n\n let user = await payload.db.findOne<UserDoc>({\n collection: collectionConfig.slug,\n req,\n where: { email: { equals: data.email.toLowerCase() } },\n })\n\n // We don't want to indicate specifically that an email was not found,\n // as doing so could lead to the exposure of registered emails.\n // Therefore, we prefer to fail silently.\n if (!user) return null\n\n user.resetPasswordToken = token\n user.resetPasswordExpiration = new Date(expiration || Date.now() + 3600000).toISOString() // 1 hour\n\n user = await payload.update({\n id: user.id,\n collection: collectionConfig.slug,\n data: user,\n req,\n })\n\n if (!disableEmail) {\n const protocol = new URL(req.url).protocol // includes the final :\n const serverURL =\n config.serverURL !== null && config.serverURL !== ''\n ? config.serverURL\n : `${protocol}//${req.headers.get('host')}`\n\n let html = `${req.t('authentication:youAreReceivingResetPassword')}\n <a href=\"${serverURL}${config.routes.admin}/${config.admin.routes.reset}/${token}\">${serverURL}${config.routes.admin}/${config.admin.routes.reset}/${token}</a>\n ${req.t('authentication:youDidNotRequestPassword')}`\n\n if (typeof collectionConfig.auth.forgotPassword.generateEmailHTML === 'function') {\n html = await collectionConfig.auth.forgotPassword.generateEmailHTML({\n req,\n token,\n user,\n })\n }\n\n let subject = req.t('authentication:resetYourPassword')\n\n if (typeof collectionConfig.auth.forgotPassword.generateEmailSubject === 'function') {\n subject = await collectionConfig.auth.forgotPassword.generateEmailSubject({\n req,\n token,\n user,\n })\n }\n\n await email.sendEmail({\n from: `\"${email.defaultFromName}\" <${email.defaultFromAddress}>`,\n html,\n subject,\n to: data.email,\n })\n }\n\n // /////////////////////////////////////\n // afterForgotPassword - Collection\n // /////////////////////////////////////\n\n await collectionConfig.hooks.afterForgotPassword.reduce(async (priorHook, hook) => {\n await priorHook\n await hook({ args, collection: args.collection?.config, context: req.context })\n }, Promise.resolve())\n\n // /////////////////////////////////////\n // afterOperation - Collection\n // /////////////////////////////////////\n\n token = await buildAfterOperation({\n args,\n collection: args.collection?.config,\n operation: 'forgotPassword',\n result: token,\n })\n\n if (shouldCommit) await commitTransaction(req)\n\n return token\n } catch (error: unknown) {\n await killTransaction(args.req)\n throw error\n }\n}\n"],"names":["crypto","httpStatus","URL","buildAfterOperation","APIError","commitTransaction","initTransaction","killTransaction","forgotPasswordOperation","incomingArgs","Object","prototype","hasOwnProperty","call","data","BAD_REQUEST","args","shouldCommit","req","collection","config","hooks","beforeOperation","reduce","priorHook","hook","context","operation","Promise","resolve","collectionConfig","disableEmail","expiration","payload","email","token","randomBytes","toString","user","db","findOne","slug","where","equals","toLowerCase","resetPasswordToken","resetPasswordExpiration","Date","now","toISOString","update","id","protocol","url","serverURL","headers","get","html","t","routes","admin","reset","auth","forgotPassword","generateEmailHTML","subject","generateEmailSubject","sendEmail","from","defaultFromName","defaultFromAddress","to","afterForgotPassword","result","error"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,OAAOA,YAAY,SAAQ;AAC3B,OAAOC,gBAAgB,cAAa;AACpC,SAASC,GAAG,QAAQ,MAAK;AAKzB,SAASC,mBAAmB,QAAQ,wCAAuC;AAC3E,SAASC,QAAQ,QAAQ,wBAAuB;AAChD,SAASC,iBAAiB,QAAQ,uCAAsC;AACxE,SAASC,eAAe,QAAQ,qCAAoC;AACpE,SAASC,eAAe,QAAQ,qCAAoC;AAepE,OAAO,MAAMC,0BAA0B,OAAOC;IAC5C,IAAI,CAACC,OAAOC,SAAS,CAACC,cAAc,CAACC,IAAI,CAACJ,aAAaK,IAAI,EAAE,UAAU;QACrE,MAAM,IAAIV,SAAS,kBAAkBH,WAAWc,WAAW;IAC7D;IAEA,IAAIC,OAAOP;IAEX,IAAI;QACF,MAAMQ,eAAe,MAAMX,gBAAgBU,KAAKE,GAAG;QAEnD,wCAAwC;QACxC,+BAA+B;QAC/B,wCAAwC;QAExC,MAAMF,KAAKG,UAAU,CAACC,MAAM,CAACC,KAAK,CAACC,eAAe,CAACC,MAAM,CAAC,OAAOC,WAAWC;YAC1E,MAAMD;YAENR,OACE,AAAC,MAAMS,KAAK;gBACVT;gBACAG,YAAYH,KAAKG,UAAU,EAAEC;gBAC7BM,SAASV,KAAKE,GAAG,CAACQ,OAAO;gBACzBC,WAAW;gBACXT,KAAKF,KAAKE,GAAG;YACf,MAAOF;QACX,GAAGY,QAAQC,OAAO;QAElB,MAAM,EACJV,YAAY,EAAEC,QAAQU,gBAAgB,EAAE,EACxChB,IAAI,EACJ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AAC,GAAG,IAAI,EAAE,QAAQ,KAAK,OAAO,CAAC,UAAU,CAAC;CACtD,CAAA;AACD,KAAK,MAAM,GAAG,CAAC,GAAG,IAAI,EAAE,QAAQ,CAAC,QAAQ,CAAC,KAAK,OAAO,CAAC,UAAU,CAAC,CAAA;AAOlE,eAAO,MAAM,IAAI,EAAE,MAuBlB,CAAA"}
@@ -73,10 +73,11 @@ export const resolve = async (specifier, context, nextResolve)=>{
73
73
  const { resolvedModule } = ts.resolveModuleName(specifier, fileURLToPath(context.parentURL), tsconfig, host, moduleResolutionCache);
74
74
  if (resolvedModule) {
75
75
  const resolvedIsTS = TS_EXTENSIONS.includes(resolvedModule.extension);
76
+ const resolvedPath = await resolveOriginalPath(resolvedModule.resolvedFileName);
76
77
  return {
77
78
  format: resolvedIsTS ? 'ts' : undefined,
78
79
  shortCircuit: true,
79
- url: pathToFileURL(await resolveOriginalPath(resolvedModule.resolvedFileName)).href
80
+ url: pathToFileURL(resolvedPath ?? resolvedModule.resolvedFileName).href
80
81
  };
81
82
  }
82
83
  // import from local project to either:
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/bin/loader/index.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/unbound-method */\nimport { getTsconfig } from 'get-tsconfig'\nimport ts from 'typescript'\nimport { fileURLToPath, pathToFileURL } from 'url'\n\nimport { CLIENT_EXTENSIONS } from './clientExtensions.js'\nimport { compile } from './compile.js'\nimport { specifiersToIgnore } from './ignores.js'\nimport { resolveOriginalPath } from './resolveOriginalPath.js'\n\ninterface ResolveContext {\n conditions: string[]\n parentURL: string | undefined\n}\ninterface ResolveResult {\n format?: string\n shortCircuit?: boolean\n url: string\n}\ntype ResolveArgs = [\n specifier: string,\n context?: ResolveContext,\n nextResolve?: (...args: ResolveArgs) => Promise<ResolveResult>,\n]\ntype ResolveFn = (...args: Required<ResolveArgs>) => Promise<ResolveResult>\n\nconst locatedConfig = getTsconfig()\nconst tsconfig = locatedConfig.config.compilerOptions as unknown as ts.CompilerOptions\n\n// Ensure baseUrl is set in order to support paths\nif (!tsconfig.baseUrl) {\n tsconfig.baseUrl = '.'\n}\n\n// Don't resolve d.ts files, because we aren't type-checking\ntsconfig.noDtsResolution = true\ntsconfig.module = ts.ModuleKind.ESNext\ntsconfig.moduleResolution = ts.ModuleResolutionKind.NodeNext\n\nconst moduleResolutionCache = ts.createModuleResolutionCache(\n ts.sys.getCurrentDirectory(),\n (x) => x,\n tsconfig,\n)\nconst host: ts.ModuleResolutionHost = {\n fileExists: ts.sys.fileExists,\n readFile: ts.sys.readFile,\n}\nconst TS_EXTENSIONS: string[] = [\n ts.Extension.Ts,\n ts.Extension.Tsx,\n ts.Extension.Dts,\n ts.Extension.Mts,\n]\n\nexport const resolve: ResolveFn = async (specifier, context, nextResolve) => {\n const isTS = TS_EXTENSIONS.some((ext) => specifier.endsWith(ext))\n const isClient = CLIENT_EXTENSIONS.some((ext) => specifier.endsWith(ext))\n const shouldIgnore = specifiersToIgnore.includes(specifier)\n\n // If it's a client file, or a file to be ignored is resolved,\n // we'll set `format: 'ignore'`\n // and short circuit, so the load step\n // will return source code of empty object\n if (isClient || shouldIgnore) {\n return {\n format: 'ignore',\n shortCircuit: true,\n // No need to resolve the URL using nextResolve. We ignore client files anyway.\n // Additionally, nextResolve throws an error if the URL is a TS path, so we'd have to use TypeScript's resolveModuleName to resolve the URL, which is unnecessary\n url: 'file:///',\n }\n }\n\n // entrypoint\n if (!context.parentURL) {\n return {\n format: isTS ? 'ts' : undefined,\n shortCircuit: true,\n url: specifier,\n }\n }\n\n // Try and resolve normally\n // This could fail, so we need to swallow that error\n // and keep going\n let nextResult: ResolveResult\n\n if (!isTS) {\n try {\n nextResult = await nextResolve(specifier, context, nextResolve)\n } catch (_) {\n // swallow error\n }\n }\n\n if (nextResult) {\n const nextResultIsTS = TS_EXTENSIONS.some((ext) => nextResult.url.endsWith(ext))\n\n return {\n ...nextResult,\n format: nextResultIsTS ? 'ts' : nextResult.format,\n shortCircuit: true,\n }\n }\n\n const { resolvedModule } = ts.resolveModuleName(\n specifier,\n fileURLToPath(context.parentURL),\n tsconfig,\n host,\n moduleResolutionCache,\n )\n\n if (resolvedModule) {\n const resolvedIsTS = TS_EXTENSIONS.includes(resolvedModule.extension)\n\n return {\n format: resolvedIsTS ? 'ts' : undefined,\n shortCircuit: true,\n url: pathToFileURL(await resolveOriginalPath(resolvedModule.resolvedFileName)).href, // The typescript module resolver does not resolve to the original path, but to the symlinked path, if present. This can cause issues\n }\n }\n\n // import from local project to either:\n // - something TS couldn't resolve\n // - local project non-TS file\n return nextResolve(specifier, context, nextResolve)\n}\n\ninterface LoadContext {\n conditions: string[]\n format: null | string | undefined\n}\ninterface LoadResult {\n format: string\n shortCircuit?: boolean\n source: ArrayBuffer | SharedArrayBuffer | Uint8Array | string\n}\ntype LoadArgs = [\n url: string,\n context: LoadContext,\n nextLoad?: (...args: LoadArgs) => Promise<LoadResult>,\n]\ntype LoadFn = (...args: Required<LoadArgs>) => Promise<LoadResult>\n\nconst swcOptions = {\n ...tsconfig,\n baseUrl: undefined,\n paths: undefined,\n}\nexport const load: LoadFn = async (url, context, nextLoad) => {\n if (context.format === 'ignore') {\n const rawSource = 'export default {}'\n\n return {\n format: 'module',\n shortCircuit: true,\n source: rawSource,\n }\n }\n\n if (context.format === 'ts') {\n const { source } = await nextLoad(url, context)\n const code = typeof source === 'string' ? source : Buffer.from(source).toString()\n const compiled = await compile(code, fileURLToPath(url), swcOptions)\n return {\n format: 'module',\n shortCircuit: true,\n source: compiled,\n }\n } else {\n return nextLoad(url, context)\n }\n}\n"],"names":["getTsconfig","ts","fileURLToPath","pathToFileURL","CLIENT_EXTENSIONS","compile","specifiersToIgnore","resolveOriginalPath","locatedConfig","tsconfig","config","compilerOptions","baseUrl","noDtsResolution","module","ModuleKind","ESNext","moduleResolution","ModuleResolutionKind","NodeNext","moduleResolutionCache","createModuleResolutionCache","sys","getCurrentDirectory","x","host","fileExists","readFile","TS_EXTENSIONS","Extension","Ts","Tsx","Dts","Mts","resolve","specifier","context","nextResolve","isTS","some","ext","endsWith","isClient","shouldIgnore","includes","format","shortCircuit","url","parentURL","undefined","nextResult","_","nextResultIsTS","resolvedModule","resolveModuleName","resolvedIsTS","extension","resolvedFileName","href","swcOptions","paths","load","nextLoad","rawSource","source","code","Buffer","from","toString","compiled"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,oDAAoD,GACpD,SAASA,WAAW,QAAQ,eAAc;AAC1C,OAAOC,QAAQ,aAAY;AAC3B,SAASC,aAAa,EAAEC,aAAa,QAAQ,MAAK;AAElD,SAASC,iBAAiB,QAAQ,wBAAuB;AACzD,SAASC,OAAO,QAAQ,eAAc;AACtC,SAASC,kBAAkB,QAAQ,eAAc;AACjD,SAASC,mBAAmB,QAAQ,2BAA0B;AAkB9D,MAAMC,gBAAgBR;AACtB,MAAMS,WAAWD,cAAcE,MAAM,CAACC,eAAe;AAErD,kDAAkD;AAClD,IAAI,CAACF,SAASG,OAAO,EAAE;IACrBH,SAASG,OAAO,GAAG;AACrB;AAEA,4DAA4D;AAC5DH,SAASI,eAAe,GAAG;AAC3BJ,SAASK,MAAM,GAAGb,GAAGc,UAAU,CAACC,MAAM;AACtCP,SAASQ,gBAAgB,GAAGhB,GAAGiB,oBAAoB,CAACC,QAAQ;AAE5D,MAAMC,wBAAwBnB,GAAGoB,2BAA2B,CAC1DpB,GAAGqB,GAAG,CAACC,mBAAmB,IAC1B,CAACC,IAAMA,GACPf;AAEF,MAAMgB,OAAgC;IACpCC,YAAYzB,GAAGqB,GAAG,CAACI,UAAU;IAC7BC,UAAU1B,GAAGqB,GAAG,CAACK,QAAQ;AAC3B;AACA,MAAMC,gBAA0B;IAC9B3B,GAAG4B,SAAS,CAACC,EAAE;IACf7B,GAAG4B,SAAS,CAACE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AQU,eAAe,OAAON;YAC9BH,cAAc;YACdC,KAAK5C,cAAc,MAAMI,oBAAoB8C,eAAeI,gBAAgB,GAAGC,IAAI;QACrF;IACF;IAEA,uCAAuC;IACvC,kCAAkC;IAClC,8BAA8B;IAC9B,OAAOrB,YAAYF,WAAWC,SAASC;AACzC,EAAC;AAkBD,MAAMsB,aAAa;IACjB,GAAGlD,QAAQ;IACXG,SAASqC;IACTW,OAAOX;AACT;AACA,OAAO,MAAMY,OAAe,OAAOd,KAAKX,SAAS0B;IAC/C,IAAI1B,QAAQS,MAAM,KAAK,UAAU;QAC/B,MAAMkB,YAAY;QAElB,OAAO;YACLlB,QAAQ;YACRC,cAAc;YACdkB,QAAQD;QACV;IACF;IAEA,IAAI3B,QAAQS,MAAM,KAAK,MAAM;QAC3B,MAAM,EAAEmB,MAAM,EAAE,GAAG,MAAMF,SAASf,KAAKX;QACvC,MAAM6B,OAAO,OAAOD,WAAW,WAAWA,SAASE,OAAOC,IAAI,CAACH,QAAQI,QAAQ;QAC/E,MAAMC,WAAW,MAAMhE,QAAQ4D,MAAM/D,cAAc6C,MAAMY;QACzD,OAAO;YACLd,QAAQ;YACRC,cAAc;YACdkB,QAAQK;QACV;IACF,OAAO;QACL,OAAOP,SAASf,KAAKX;IACvB;AACF,EAAC"}
1
+ {"version":3,"sources":["../../../src/bin/loader/index.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/unbound-method */\nimport { getTsconfig } from 'get-tsconfig'\nimport ts from 'typescript'\nimport { fileURLToPath, pathToFileURL } from 'url'\n\nimport { CLIENT_EXTENSIONS } from './clientExtensions.js'\nimport { compile } from './compile.js'\nimport { specifiersToIgnore } from './ignores.js'\nimport { resolveOriginalPath } from './resolveOriginalPath.js'\n\ninterface ResolveContext {\n conditions: string[]\n parentURL: string | undefined\n}\ninterface ResolveResult {\n format?: string\n shortCircuit?: boolean\n url: string\n}\ntype ResolveArgs = [\n specifier: string,\n context?: ResolveContext,\n nextResolve?: (...args: ResolveArgs) => Promise<ResolveResult>,\n]\ntype ResolveFn = (...args: Required<ResolveArgs>) => Promise<ResolveResult>\n\nconst locatedConfig = getTsconfig()\nconst tsconfig = locatedConfig.config.compilerOptions as unknown as ts.CompilerOptions\n\n// Ensure baseUrl is set in order to support paths\nif (!tsconfig.baseUrl) {\n tsconfig.baseUrl = '.'\n}\n\n// Don't resolve d.ts files, because we aren't type-checking\ntsconfig.noDtsResolution = true\ntsconfig.module = ts.ModuleKind.ESNext\ntsconfig.moduleResolution = ts.ModuleResolutionKind.NodeNext\n\nconst moduleResolutionCache = ts.createModuleResolutionCache(\n ts.sys.getCurrentDirectory(),\n (x) => x,\n tsconfig,\n)\nconst host: ts.ModuleResolutionHost = {\n fileExists: ts.sys.fileExists,\n readFile: ts.sys.readFile,\n}\nconst TS_EXTENSIONS: string[] = [\n ts.Extension.Ts,\n ts.Extension.Tsx,\n ts.Extension.Dts,\n ts.Extension.Mts,\n]\n\nexport const resolve: ResolveFn = async (specifier, context, nextResolve) => {\n const isTS = TS_EXTENSIONS.some((ext) => specifier.endsWith(ext))\n const isClient = CLIENT_EXTENSIONS.some((ext) => specifier.endsWith(ext))\n const shouldIgnore = specifiersToIgnore.includes(specifier)\n\n // If it's a client file, or a file to be ignored is resolved,\n // we'll set `format: 'ignore'`\n // and short circuit, so the load step\n // will return source code of empty object\n if (isClient || shouldIgnore) {\n return {\n format: 'ignore',\n shortCircuit: true,\n // No need to resolve the URL using nextResolve. We ignore client files anyway.\n // Additionally, nextResolve throws an error if the URL is a TS path, so we'd have to use TypeScript's resolveModuleName to resolve the URL, which is unnecessary\n url: 'file:///',\n }\n }\n\n // entrypoint\n if (!context.parentURL) {\n return {\n format: isTS ? 'ts' : undefined,\n shortCircuit: true,\n url: specifier,\n }\n }\n\n // Try and resolve normally\n // This could fail, so we need to swallow that error\n // and keep going\n let nextResult: ResolveResult\n\n if (!isTS) {\n try {\n nextResult = await nextResolve(specifier, context, nextResolve)\n } catch (_) {\n // swallow error\n }\n }\n\n if (nextResult) {\n const nextResultIsTS = TS_EXTENSIONS.some((ext) => nextResult.url.endsWith(ext))\n\n return {\n ...nextResult,\n format: nextResultIsTS ? 'ts' : nextResult.format,\n shortCircuit: true,\n }\n }\n\n const { resolvedModule } = ts.resolveModuleName(\n specifier,\n fileURLToPath(context.parentURL),\n tsconfig,\n host,\n moduleResolutionCache,\n )\n\n if (resolvedModule) {\n const resolvedIsTS = TS_EXTENSIONS.includes(resolvedModule.extension)\n const resolvedPath = await resolveOriginalPath(resolvedModule.resolvedFileName)\n\n return {\n format: resolvedIsTS ? 'ts' : undefined,\n shortCircuit: true,\n url: pathToFileURL(resolvedPath ?? resolvedModule.resolvedFileName).href, // The typescript module resolver does not resolve to the original path, but to the symlinked path, if present. This can cause issues\n }\n }\n\n // import from local project to either:\n // - something TS couldn't resolve\n // - local project non-TS file\n return nextResolve(specifier, context, nextResolve)\n}\n\ninterface LoadContext {\n conditions: string[]\n format: null | string | undefined\n}\ninterface LoadResult {\n format: string\n shortCircuit?: boolean\n source: ArrayBuffer | SharedArrayBuffer | Uint8Array | string\n}\ntype LoadArgs = [\n url: string,\n context: LoadContext,\n nextLoad?: (...args: LoadArgs) => Promise<LoadResult>,\n]\ntype LoadFn = (...args: Required<LoadArgs>) => Promise<LoadResult>\n\nconst swcOptions = {\n ...tsconfig,\n baseUrl: undefined,\n paths: undefined,\n}\nexport const load: LoadFn = async (url, context, nextLoad) => {\n if (context.format === 'ignore') {\n const rawSource = 'export default {}'\n\n return {\n format: 'module',\n shortCircuit: true,\n source: rawSource,\n }\n }\n\n if (context.format === 'ts') {\n const { source } = await nextLoad(url, context)\n const code = typeof source === 'string' ? source : Buffer.from(source).toString()\n const compiled = await compile(code, fileURLToPath(url), swcOptions)\n return {\n format: 'module',\n shortCircuit: true,\n source: compiled,\n }\n } else {\n return nextLoad(url, context)\n }\n}\n"],"names":["getTsconfig","ts","fileURLToPath","pathToFileURL","CLIENT_EXTENSIONS","compile","specifiersToIgnore","resolveOriginalPath","locatedConfig","tsconfig","config","compilerOptions","baseUrl","noDtsResolution","module","ModuleKind","ESNext","moduleResolution","ModuleResolutionKind","NodeNext","moduleResolutionCache","createModuleResolutionCache","sys","getCurrentDirectory","x","host","fileExists","readFile","TS_EXTENSIONS","Extension","Ts","Tsx","Dts","Mts","resolve","specifier","context","nextResolve","isTS","some","ext","endsWith","isClient","shouldIgnore","includes","format","shortCircuit","url","parentURL","undefined","nextResult","_","nextResultIsTS","resolvedModule","resolveModuleName","resolvedIsTS","extension","resolvedPath","resolvedFileName","href","swcOptions","paths","load","nextLoad","rawSource","source","code","Buffer","from","toString","compiled"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,oDAAoD,GACpD,SAASA,WAAW,QAAQ,eAAc;AAC1C,OAAOC,QAAQ,aAAY;AAC3B,SAASC,aAAa,EAAEC,aAAa,QAAQ,MAAK;AAElD,SAASC,iBAAiB,QAAQ,wBAAuB;AACzD,SAASC,OAAO,QAAQ,eAAc;AACtC,SAASC,kBAAkB,QAAQ,eAAc;AACjD,SAASC,mBAAmB,QAAQ,2BAA0B;AAkB9D,MAAMC,gBAAgBR;AACtB,MAAMS,WAAWD,cAAcE,MAAM,CAACC,eAAe;AAErD,kDAAkD;AAClD,IAAI,CAACF,SAASG,OAAO,EAAE;IACrBH,SAASG,OAAO,GAAG;AACrB;AAEA,4DAA4D;AAC5DH,SAASI,eAAe,GAAG;AAC3BJ,SAASK,MAAM,GAAGb,GAAGc,UAAU,CAACC,MAAM;AACtCP,SAASQ,gBAAgB,GAAGhB,GAAGiB,oBAAoB,CAACC,QAAQ;AAE5D,MAAMC,wBAAwBnB,GAAGoB,2BAA2B,CAC1DpB,GAAGqB,GAAG,CAACC,mBAAmB,IAC1B,CAACC,IAAMA,GACPf;AAEF,MAAMgB,OAAgC;IAC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AGqD,iBAAiB,CAC7CnB,WACAjC,cAAckC,QAAQY,SAAS,GAC/BvC,UACAgB,MACAL;IAGF,IAAIiC,gBAAgB;QAClB,MAAME,eAAe3B,cAAcgB,QAAQ,CAACS,eAAeG,SAAS;QACpE,MAAMC,eAAe,MAAMlD,oBAAoB8C,eAAeK,gBAAgB;QAE9E,OAAO;YACLb,QAAQU,eAAe,OAAON;YAC9BH,cAAc;YACdC,KAAK5C,cAAcsD,gBAAgBJ,eAAeK,gBAAgB,EAAEC,IAAI;QAC1E;IACF;IAEA,uCAAuC;IACvC,kCAAkC;IAClC,8BAA8B;IAC9B,OAAOtB,YAAYF,WAAWC,SAASC;AACzC,EAAC;AAkBD,MAAMuB,aAAa;IACjB,GAAGnD,QAAQ;IACXG,SAASqC;IACTY,OAAOZ;AACT;AACA,OAAO,MAAMa,OAAe,OAAOf,KAAKX,SAAS2B;IAC/C,IAAI3B,QAAQS,MAAM,KAAK,UAAU;QAC/B,MAAMmB,YAAY;QAElB,OAAO;YACLnB,QAAQ;YACRC,cAAc;YACdmB,QAAQD;QACV;IACF;IAEA,IAAI5B,QAAQS,MAAM,KAAK,MAAM;QAC3B,MAAM,EAAEoB,MAAM,EAAE,GAAG,MAAMF,SAAShB,KAAKX;QACvC,MAAM8B,OAAO,OAAOD,WAAW,WAAWA,SAASE,OAAOC,IAAI,CAACH,QAAQI,QAAQ;QAC/E,MAAMC,WAAW,MAAMjE,QAAQ6D,MAAMhE,cAAc6C,MAAMa;QACzD,OAAO;YACLf,QAAQ;YACRC,cAAc;YACdmB,QAAQK;QACV;IACF,OAAO;QACL,OAAOP,SAAShB,KAAKX;IACvB;AACF,EAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"resolveOriginalPath.d.ts","sourceRoot":"","sources":["../../../src/bin/loader/resolveOriginalPath.ts"],"names":[],"mappings":"AAGA;;;;;;;GAOG;AACH,wBAAsB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,mBAuBzD"}
1
+ {"version":3,"file":"resolveOriginalPath.d.ts","sourceRoot":"","sources":["../../../src/bin/loader/resolveOriginalPath.ts"],"names":[],"mappings":"AAGA;;;;;;;GAOG;AACH,wBAAsB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,mBAwBzD"}
@@ -11,7 +11,7 @@ import path from 'path';
11
11
  try {
12
12
  // Normalize and split the path
13
13
  const parts = path.resolve(filePath).split(path.sep);
14
- let currentPath = '/';
14
+ let currentPath = parts[0] || '/';
15
15
  // skip the first slash
16
16
  for (const part of parts.slice(1)){
17
17
  currentPath = path.join(currentPath, part);
@@ -20,7 +20,11 @@ import path from 'path';
20
20
  if (stats.isSymbolicLink()) {
21
21
  // Resolve the symlink
22
22
  const resolvedLink = await fs.readlink(currentPath);
23
- currentPath = path.join(path.dirname(currentPath), resolvedLink);
23
+ if (!path.isAbsolute(resolvedLink)) {
24
+ currentPath = path.join(path.dirname(currentPath), resolvedLink);
25
+ } else {
26
+ currentPath = resolvedLink;
27
+ }
24
28
  }
25
29
  }
26
30
  return currentPath;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/bin/loader/resolveOriginalPath.ts"],"sourcesContent":["import fs from 'fs/promises'\nimport path from 'path'\n\n/**\n * In case any directory in the path contains symlinks, this function attempts to detect that resolves the original path.\n *\n * Example Input: /Users/alessio/Documents/GitHub/payload-3.0-alpha-demo/node_modules/tailwindcss/resolveConfig.js\n * The \"tailwindcss\" in this example is a symlinked directory.\n *\n * Example Output: /Users/alessio/Documents/GitHub/payload-3.0-alpha-demo/node_modules/.pnpm/tailwindcss@3.4.3/node_modules/tailwindcss/resolveConfig.js\n */\nexport async function resolveOriginalPath(filePath: string) {\n try {\n // Normalize and split the path\n const parts = path.resolve(filePath).split(path.sep)\n\n let currentPath = '/'\n // skip the first slash\n for (const part of parts.slice(1)) {\n currentPath = path.join(currentPath, part)\n\n // Check if the current path component is a symlink\n const stats = await fs.lstat(currentPath)\n if (stats.isSymbolicLink()) {\n // Resolve the symlink\n const resolvedLink = await fs.readlink(currentPath)\n currentPath = path.join(path.dirname(currentPath), resolvedLink)\n }\n }\n\n return currentPath\n } catch (error) {\n console.error('Error resolving path:', error)\n }\n}\n"],"names":["fs","path","resolveOriginalPath","filePath","parts","resolve","split","sep","currentPath","part","slice","join","stats","lstat","isSymbolicLink","resolvedLink","readlink","dirname","error","console"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,OAAOA,QAAQ,cAAa;AAC5B,OAAOC,UAAU,OAAM;AAEvB;;;;;;;CAOC,GACD,OAAO,eAAeC,oBAAoBC,QAAgB;IACxD,IAAI;QACF,+BAA+B;QAC/B,MAAMC,QAAQH,KAAKI,OAAO,CAACF,UAAUG,KAAK,CAACL,KAAKM,GAAG;QAEnD,IAAIC,cAAc;QAClB,uBAAuB;QACvB,KAAK,MAAMC,QAAQL,MAAMM,KAAK,CAAC,GAAI;YACjCF,cAAcP,KAAKU,IAAI,CAACH,aAAaC;YAErC,mDAAmD;YACnD,MAAMG,QAAQ,MAAMZ,GAAGa,KAAK,CAACL;YAC7B,IAAII,MAAME,cAAc,IAAI;gBAC1B,sBAAsB;gBACtB,MAAMC,eAAe,MAAMf,GAAGgB,QAAQ,CAACR;gBACvCA,cAAcP,KAAKU,IAAI,CAACV,KAAKgB,OAAO,CAACT,cAAcO;YACrD;QACF;QAEA,OAAOP;IACT,EAAE,OAAOU,OAAO;QACdC,QAAQD,KAAK,CAAC,yBAAyBA;IACzC;AACF"}
1
+ {"version":3,"sources":["../../../src/bin/loader/resolveOriginalPath.ts"],"sourcesContent":["import fs from 'fs/promises'\nimport path from 'path'\n\n/**\n * In case any directory in the path contains symlinks, this function attempts to detect that resolves the original path.\n *\n * Example Input: /Users/alessio/Documents/GitHub/payload-3.0-alpha-demo/node_modules/tailwindcss/resolveConfig.js\n * The \"tailwindcss\" in this example is a symlinked directory.\n *\n * Example Output: /Users/alessio/Documents/GitHub/payload-3.0-alpha-demo/node_modules/.pnpm/tailwindcss@3.4.3/node_modules/tailwindcss/resolveConfig.js\n */\nexport async function resolveOriginalPath(filePath: string) {\n try {\n // Normalize and split the path\n const parts = path.resolve(filePath).split(path.sep)\n let currentPath = parts[0] || '/'\n // skip the first slash\n for (const part of parts.slice(1)) {\n currentPath = path.join(currentPath, part)\n // Check if the current path component is a symlink\n const stats = await fs.lstat(currentPath)\n if (stats.isSymbolicLink()) {\n // Resolve the symlink\n const resolvedLink = await fs.readlink(currentPath)\n if (!path.isAbsolute(resolvedLink)) {\n currentPath = path.join(path.dirname(currentPath), resolvedLink)\n } else {\n currentPath = resolvedLink\n }\n }\n }\n return currentPath\n } catch (error) {\n console.error('Error resolving path:', error)\n }\n}\n"],"names":["fs","path","resolveOriginalPath","filePath","parts","resolve","split","sep","currentPath","part","slice","join","stats","lstat","isSymbolicLink","resolvedLink","readlink","isAbsolute","dirname","error","console"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,OAAOA,QAAQ,cAAa;AAC5B,OAAOC,UAAU,OAAM;AAEvB;;;;;;;CAOC,GACD,OAAO,eAAeC,oBAAoBC,QAAgB;IACxD,IAAI;QACF,+BAA+B;QAC/B,MAAMC,QAAQH,KAAKI,OAAO,CAACF,UAAUG,KAAK,CAACL,KAAKM,GAAG;QACnD,IAAIC,cAAcJ,KAAK,CAAC,EAAE,IAAI;QAC9B,uBAAuB;QACvB,KAAK,MAAMK,QAAQL,MAAMM,KAAK,CAAC,GAAI;YACjCF,cAAcP,KAAKU,IAAI,CAACH,aAAaC;YACrC,mDAAmD;YACnD,MAAMG,QAAQ,MAAMZ,GAAGa,KAAK,CAACL;YAC7B,IAAII,MAAME,cAAc,IAAI;gBAC1B,sBAAsB;gBACtB,MAAMC,eAAe,MAAMf,GAAGgB,QAAQ,CAACR;gBACvC,IAAI,CAACP,KAAKgB,UAAU,CAACF,eAAe;oBAClCP,cAAcP,KAAKU,IAAI,CAACV,KAAKiB,OAAO,CAACV,cAAcO;gBACrD,OAAO;oBACLP,cAAcO;gBAChB;YACF;QACF;QACA,OAAOP;IACT,EAAE,OAAOW,OAAO;QACdC,QAAQD,KAAK,CAAC,yBAAyBA;IACzC;AACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"defaults.d.ts","sourceRoot":"","sources":["../../src/config/defaults.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,YAAY,CAAA;AAExC,eAAO,MAAM,QAAQ,EAAE,IAAI,CAAC,MAAM,EAAE,IAAI,GAAG,QAAQ,GAAG,QAAQ,CAqD7D,CAAA"}
1
+ {"version":3,"file":"defaults.d.ts","sourceRoot":"","sources":["../../src/config/defaults.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,YAAY,CAAA;AAExC,eAAO,MAAM,QAAQ,EAAE,IAAI,CAAC,MAAM,EAAE,IAAI,GAAG,QAAQ,GAAG,QAAQ,CAsD7D,CAAA"}
@@ -16,6 +16,7 @@ export const defaults = {
16
16
  inactivity: '/logout-inactivity',
17
17
  login: '/login',
18
18
  logout: '/logout',
19
+ reset: '/reset',
19
20
  unauthorized: '/unauthorized'
20
21
  }
21
22
  },
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/config/defaults.ts"],"sourcesContent":["import type { Config } from './types.js'\n\nexport const defaults: Omit<Config, 'db' | 'editor' | 'secret'> = {\n admin: {\n avatar: 'gravatar',\n components: {},\n custom: {},\n dateFormat: 'MMMM do yyyy, h:mm a',\n disable: false,\n meta: {\n defaultOGImageType: 'dynamic',\n titleSuffix: '- Payload',\n },\n routes: {\n account: '/account',\n createFirstUser: '/create-first-user',\n forgot: '/forgot',\n inactivity: '/logout-inactivity',\n login: '/login',\n logout: '/logout',\n unauthorized: '/unauthorized',\n },\n },\n bin: [],\n collections: [],\n cookiePrefix: 'payload',\n cors: [],\n csrf: [],\n custom: {},\n defaultDepth: 2,\n defaultMaxTextLength: 40000,\n endpoints: [],\n globals: [],\n graphQL: {\n disablePlaygroundInProduction: true,\n maxComplexity: 1000,\n schemaOutputFile: `${typeof process?.cwd === 'function' ? process.cwd() : ''}/schema.graphql`,\n },\n hooks: {},\n i18n: {},\n localization: false,\n maxDepth: 10,\n routes: {\n admin: '/admin',\n api: '/api',\n graphQL: '/graphql',\n graphQLPlayground: '/graphql-playground',\n },\n serverURL: '',\n telemetry: true,\n typescript: {\n autoGenerate: true,\n outputFile: `${typeof process?.cwd === 'function' ? process.cwd() : ''}/payload-types.ts`,\n },\n upload: {},\n}\n"],"names":["defaults","admin","avatar","components","custom","dateFormat","disable","meta","defaultOGImageType","titleSuffix","routes","account","createFirstUser","forgot","inactivity","login","logout","unauthorized","bin","collections","cookiePrefix","cors","csrf","defaultDepth","defaultMaxTextLength","endpoints","globals","graphQL","disablePlaygroundInProduction","maxComplexity","schemaOutputFile","process","cwd","hooks","i18n","localization","maxDepth","api","graphQLPlayground","serverURL","telemetry","typescript","autoGenerate","outputFile","upload"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAEA,OAAO,MAAMA,WAAqD;IAChEC,OAAO;QACLC,QAAQ;QACRC,YAAY,CAAC;QACbC,QAAQ,CAAC;QACTC,YAAY;QACZC,SAAS;QACTC,MAAM;YACJC,oBAAoB;YACpBC,aAAa;QACf;QACAC,QAAQ;YACNC,SAAS;YACTC,iBAAiB;YACjBC,QAAQ;YACRC,YAAY;YACZC,OAAO;YACPC,QAAQ;YACRC,cAAc;QAChB;IACF;IACAC,KAAK,EAAE;IACPC,aAAa,EAAE;IACfC,cAAc;IACdC,MAAM,EAAE;IACRC,MAAM,EAAE;IACRlB,QAAQ,CAAC;IACTmB,cAAc;IACdC,sBAAsB;IACtBC,WAAW,EAAE;IACbC,SAAS,EAAE;IACXC,SAAS;QACPC,+BAA+B;QAC/BC,eAAe;QACfC,kBAAkB,CAAC,EAAE,OAAOC,SAASC,QAAQ,aAAaD,QAAQC,GAAG,KAAK,GAAG,eAAe,CAAC;IAC/F;IACAC,OAAO,CAAC;IACRC,MAAM,CAAC;IACPC,cAAc;IACdC,UAAU;IACV1B,QAAQ;QACNT,OAAO;QACPoC,KAAK;QACLV,SAAS;QACTW,mBAAmB;IACrB;IACAC,WAAW;IACXC,WAAW;IACXC,YAAY;QACVC,cAAc;QACdC,YAAY,CAAC,EAAE,OAAOZ,SAASC,QAAQ,aAAaD,QAAQC,GAAG,KAAK,GAAG,iBAAiB,CAAC;IAC3F;IACAY,QAAQ,CAAC;AACX,EAAC"}
1
+ {"version":3,"sources":["../../src/config/defaults.ts"],"sourcesContent":["import type { Config } from './types.js'\n\nexport const defaults: Omit<Config, 'db' | 'editor' | 'secret'> = {\n admin: {\n avatar: 'gravatar',\n components: {},\n custom: {},\n dateFormat: 'MMMM do yyyy, h:mm a',\n disable: false,\n meta: {\n defaultOGImageType: 'dynamic',\n titleSuffix: '- Payload',\n },\n routes: {\n account: '/account',\n createFirstUser: '/create-first-user',\n forgot: '/forgot',\n inactivity: '/logout-inactivity',\n login: '/login',\n logout: '/logout',\n reset: '/reset',\n unauthorized: '/unauthorized',\n },\n },\n bin: [],\n collections: [],\n cookiePrefix: 'payload',\n cors: [],\n csrf: [],\n custom: {},\n defaultDepth: 2,\n defaultMaxTextLength: 40000,\n endpoints: [],\n globals: [],\n graphQL: {\n disablePlaygroundInProduction: true,\n maxComplexity: 1000,\n schemaOutputFile: `${typeof process?.cwd === 'function' ? process.cwd() : ''}/schema.graphql`,\n },\n hooks: {},\n i18n: {},\n localization: false,\n maxDepth: 10,\n routes: {\n admin: '/admin',\n api: '/api',\n graphQL: '/graphql',\n graphQLPlayground: '/graphql-playground',\n },\n serverURL: '',\n telemetry: true,\n typescript: {\n autoGenerate: true,\n outputFile: `${typeof process?.cwd === 'function' ? process.cwd() : ''}/payload-types.ts`,\n },\n upload: {},\n}\n"],"names":["defaults","admin","avatar","components","custom","dateFormat","disable","meta","defaultOGImageType","titleSuffix","routes","account","createFirstUser","forgot","inactivity","login","logout","reset","unauthorized","bin","collections","cookiePrefix","cors","csrf","defaultDepth","defaultMaxTextLength","endpoints","globals","graphQL","disablePlaygroundInProduction","maxComplexity","schemaOutputFile","process","cwd","hooks","i18n","localization","maxDepth","api","graphQLPlayground","serverURL","telemetry","typescript","autoGenerate","outputFile","upload"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAEA,OAAO,MAAMA,WAAqD;IAChEC,OAAO;QACLC,QAAQ;QACRC,YAAY,CAAC;QACbC,QAAQ,CAAC;QACTC,YAAY;QACZC,SAAS;QACTC,MAAM;YACJC,oBAAoB;YACpBC,aAAa;QACf;QACAC,QAAQ;YACNC,SAAS;YACTC,iBAAiB;YACjBC,QAAQ;YACRC,YAAY;YACZC,OAAO;YACPC,QAAQ;YACRC,OAAO;YACPC,cAAc;QAChB;IACF;IACAC,KAAK,EAAE;IACPC,aAAa,EAAE;IACfC,cAAc;IACdC,MAAM,EAAE;IACRC,MAAM,EAAE;IACRnB,QAAQ,CAAC;IACToB,cAAc;IACdC,sBAAsB;IACtBC,WAAW,EAAE;IACbC,SAAS,EAAE;IACXC,SAAS;QACPC,+BAA+B;QAC/BC,eAAe;QACfC,kBAAkB,CAAC,EAAE,OAAOC,SAASC,QAAQ,aAAaD,QAAQC,GAAG,KAAK,GAAG,eAAe,CAAC;IAC/F;IACAC,OAAO,CAAC;IACRC,MAAM,CAAC;IACPC,cAAc;IACdC,UAAU;IACV3B,QAAQ;QACNT,OAAO;QACPqC,KAAK;QACLV,SAAS;QACTW,mBAAmB;IACrB;IACAC,WAAW;IACXC,WAAW;IACXC,YAAY;QACVC,cAAc;QACdC,YAAY,CAAC,EAAE,OAAOZ,SAASC,QAAQ,aAAaD,QAAQC,GAAG,KAAK,GAAG,iBAAiB,CAAC;IAC3F;IACAY,QAAQ,CAAC;AACX,EAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../src/config/schema.ts"],"names":[],"mappings":"AAAA,OAAO,GAAG,MAAM,KAAK,CAAA;AAQrB,eAAO,MAAM,eAAe,6BAa3B,CAAA;;AAED,wBAuLE"}
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../src/config/schema.ts"],"names":[],"mappings":"AAAA,OAAO,GAAG,MAAM,KAAK,CAAA;AAQrB,eAAO,MAAM,eAAe,6BAa3B,CAAA;;AAED,wBAwLE"}
@@ -71,6 +71,7 @@ export default joi.object({
71
71
  inactivity: joi.string(),
72
72
  login: joi.string(),
73
73
  logout: joi.string(),
74
+ reset: joi.string(),
74
75
  unauthorized: joi.string()
75
76
  }),
76
77
  user: joi.string()
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/config/schema.ts"],"sourcesContent":["import joi from 'joi'\n\nimport { adminViewSchema } from './shared/adminViewSchema.js'\nimport { componentSchema, livePreviewSchema } from './shared/componentSchema.js'\nimport { openGraphSchema } from './shared/openGraphSchema.js'\n\nconst component = joi.alternatives().try(joi.object().unknown(), joi.func())\n\nexport const endpointsSchema = joi.alternatives().try(\n joi.array().items(\n joi.object({\n custom: joi.object().pattern(joi.string(), joi.any()),\n handler: joi.alternatives().try(joi.array().items(joi.func()), joi.func()),\n method: joi\n .string()\n .valid('get', 'head', 'post', 'put', 'patch', 'delete', 'connect', 'options'),\n path: joi.string(),\n root: joi.bool(),\n }),\n ),\n joi.boolean(),\n)\n\nexport default joi.object({\n admin: joi.object({\n autoLogin: joi.alternatives().try(\n joi.object().keys({\n email: joi.string(),\n password: joi.string(),\n prefillOnly: joi.boolean(),\n }),\n joi.boolean(),\n ),\n avatar: joi.alternatives().try(joi.string(), component),\n buildPath: joi.string(),\n components: joi.object().keys({\n Nav: component,\n actions: joi.array().items(component),\n afterDashboard: joi.array().items(component),\n afterLogin: joi.array().items(component),\n afterNavLinks: joi.array().items(component),\n beforeDashboard: joi.array().items(component),\n beforeLogin: joi.array().items(component),\n beforeNavLinks: joi.array().items(component),\n graphics: joi.object({\n Icon: component,\n Logo: component,\n }),\n logout: joi.object({\n Button: component,\n }),\n providers: joi.array().items(component),\n views: joi.alternatives().try(\n joi.object({\n Account: joi.alternatives().try(component, adminViewSchema),\n Dashboard: joi.alternatives().try(component, adminViewSchema),\n }),\n joi.object().pattern(joi.string(), component),\n ),\n }),\n custom: joi.object().pattern(joi.string(), joi.any()),\n dateFormat: joi.string(),\n disable: joi.bool(),\n livePreview: joi.object({\n ...livePreviewSchema,\n collections: joi.array().items(joi.string()),\n globals: joi.array().items(joi.string()),\n }),\n meta: joi.object().keys({\n defaultOGImageType: joi.string().valid('off', 'dynamic', 'static'),\n description: joi.string(),\n icons: joi.array().items(\n joi.object().keys({\n type: joi.string(),\n color: joi.string(),\n fetchPriority: joi.string().valid('auto', 'high', 'low'),\n media: joi.string(),\n rel: joi.string(),\n sizes: joi.string(),\n url: joi.string(),\n }),\n ),\n openGraph: openGraphSchema,\n titleSuffix: joi.string(),\n }),\n routes: joi.object({\n account: joi.string(),\n createFirstUser: joi.string(),\n forgot: joi.string(),\n inactivity: joi.string(),\n login: joi.string(),\n logout: joi.string(),\n unauthorized: joi.string(),\n }),\n user: joi.string(),\n }),\n bin: joi.array().items(\n joi.object().keys({\n key: joi.string(),\n scriptPath: joi.string(),\n }),\n ),\n collections: joi.array(),\n cookiePrefix: joi.string(),\n cors: [joi.string().valid('*'), joi.array().items(joi.string())],\n csrf: joi.array().items(joi.string().allow('')).sparse(),\n custom: joi.object().pattern(joi.string(), joi.any()),\n db: joi.any(),\n debug: joi.boolean(),\n defaultDepth: joi.number().min(0).max(30),\n defaultMaxTextLength: joi.number(),\n editor: joi\n .object()\n .optional()\n .keys({\n CellComponent: componentSchema.optional(),\n FieldComponent: componentSchema.optional(),\n afterReadPromise: joi.func().optional(),\n outputSchema: joi.func().optional(),\n populationPromise: joi.func().optional(),\n validate: joi.func().required(),\n })\n .unknown(),\n email: joi.alternatives().try(joi.object(), joi.func()),\n endpoints: endpointsSchema,\n globals: joi.array(),\n graphQL: joi.object().keys({\n disable: joi.boolean(),\n disablePlaygroundInProduction: joi.boolean(),\n maxComplexity: joi.number(),\n mutations: joi.function(),\n queries: joi.function(),\n schemaOutputFile: joi.string(),\n }),\n hooks: joi.object().keys({\n afterError: joi.func(),\n }),\n i18n: joi.object(),\n indexSortableFields: joi.boolean(),\n local: joi.boolean(),\n localization: joi.alternatives().try(\n joi.object().keys({\n defaultLocale: joi.string(),\n fallback: joi.boolean(),\n localeCodes: joi.array().items(joi.string()),\n locales: joi.alternatives().try(\n joi.array().items(\n joi.object().keys({\n code: joi.string(),\n fallbackLocale: joi.string(),\n label: joi\n .alternatives()\n .try(\n joi.object().pattern(joi.string(), [joi.string()]),\n joi.string(),\n joi.valid(false),\n ),\n rtl: joi.boolean(),\n toString: joi.func(),\n }),\n ),\n joi.array().items(joi.string()),\n ),\n }),\n joi.boolean(),\n ),\n maxDepth: joi.number().min(0).max(100),\n onInit: joi.func(),\n plugins: joi.array().items(joi.func()),\n routes: joi.object({\n admin: joi.string(),\n api: joi.string(),\n graphQL: joi.string(),\n graphQLPlayground: joi.string(),\n }),\n secret: joi.string(),\n serverURL: joi\n .string()\n .uri()\n .allow('')\n .custom((value, helper) => {\n const urlWithoutProtocol = value.split('//')[1]\n\n if (!urlWithoutProtocol) {\n return helper.message({\n custom: 'You need to include either \"https://\" or \"http://\" in your serverURL.',\n })\n }\n\n if (urlWithoutProtocol.indexOf('/') > -1) {\n return helper.message({\n custom:\n 'Your serverURL cannot have a path. It can only contain a protocol, a domain, and an optional port.',\n })\n }\n\n return value\n }),\n sharp: joi.any(),\n telemetry: joi.boolean(),\n typescript: joi.object({\n autoGenerate: joi.boolean(),\n declare: joi.alternatives().try(joi.boolean(), joi.object({ ignoreTSError: joi.boolean() })),\n outputFile: joi.string(),\n }),\n upload: joi.object(),\n})\n"],"names":["joi","adminViewSchema","componentSchema","livePreviewSchema","openGraphSchema","component","alternatives","try","object","unknown","func","endpointsSchema","array","items","custom","pattern","string","any","handler","method","valid","path","root","bool","boolean","admin","autoLogin","keys","email","password","prefillOnly","avatar","buildPath","components","Nav","actions","afterDashboard","afterLogin","afterNavLinks","beforeDashboard","beforeLogin","beforeNavLinks","graphics","Icon","Logo","logout","Button","providers","views","Account","Dashboard","dateFormat","disable","livePreview","collections","globals","meta","defaultOGImageType","description","icons","type","color","fetchPriority","media","rel","sizes","url","openGraph","titleSuffix","routes","account","createFirstUser","forgot","inactivity","login","unauthorized","user","bin","key","scriptPath","cookiePrefix","cors","csrf","allow","sparse","db","debug","defaultDepth","number","min","max","defaultMaxTextLength","editor","optional","CellComponent","FieldComponent","afterReadPromise","outputSchema","populationPromise","validate","required","endpoints","graphQL","disablePlaygroundInProduction","maxComplexity","mutations","function","queries","schemaOutputFile","hooks","afterError","i18n","indexSortableFields","local","localization","defaultLocale","fallback","localeCodes","locales","code","fallbackLocale","label","rtl","toString","maxDepth","onInit","plugins","api","graphQLPlayground","secret","serverURL","uri","value","helper","urlWithoutProtocol","split","message","indexOf","sharp","telemetry","typescript","autoGenerate","declare","ignoreTSError","outputFile","upload"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,OAAOA,SAAS,MAAK;AAErB,SAASC,eAAe,QAAQ,8BAA6B;AAC7D,SAASC,eAAe,EAAEC,iBAAiB,QAAQ,8BAA6B;AAChF,SAASC,eAAe,QAAQ,8BAA6B;AAE7D,MAAMC,YAAYL,IAAIM,YAAY,GAAGC,GAAG,CAACP,IAAIQ,MAAM,GAAGC,OAAO,IAAIT,IAAIU,IAAI;AAEzE,OAAO,MAAMC,kBAAkBX,IAAIM,YAAY,GAAGC,GAAG,CACnDP,IAAIY,KAAK,GAAGC,KAAK,CAC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;IACxB;IACAiI,QAAQjJ,IAAIQ,MAAM;AACpB,GAAE"}
1
+ {"version":3,"sources":["../../src/config/schema.ts"],"sourcesContent":["import joi from 'joi'\n\nimport { adminViewSchema } from './shared/adminViewSchema.js'\nimport { componentSchema, livePreviewSchema } from './shared/componentSchema.js'\nimport { openGraphSchema } from './shared/openGraphSchema.js'\n\nconst component = joi.alternatives().try(joi.object().unknown(), joi.func())\n\nexport const endpointsSchema = joi.alternatives().try(\n joi.array().items(\n joi.object({\n custom: joi.object().pattern(joi.string(), joi.any()),\n handler: joi.alternatives().try(joi.array().items(joi.func()), joi.func()),\n method: joi\n .string()\n .valid('get', 'head', 'post', 'put', 'patch', 'delete', 'connect', 'options'),\n path: joi.string(),\n root: joi.bool(),\n }),\n ),\n joi.boolean(),\n)\n\nexport default joi.object({\n admin: joi.object({\n autoLogin: joi.alternatives().try(\n joi.object().keys({\n email: joi.string(),\n password: joi.string(),\n prefillOnly: joi.boolean(),\n }),\n joi.boolean(),\n ),\n avatar: joi.alternatives().try(joi.string(), component),\n buildPath: joi.string(),\n components: joi.object().keys({\n Nav: component,\n actions: joi.array().items(component),\n afterDashboard: joi.array().items(component),\n afterLogin: joi.array().items(component),\n afterNavLinks: joi.array().items(component),\n beforeDashboard: joi.array().items(component),\n beforeLogin: joi.array().items(component),\n beforeNavLinks: joi.array().items(component),\n graphics: joi.object({\n Icon: component,\n Logo: component,\n }),\n logout: joi.object({\n Button: component,\n }),\n providers: joi.array().items(component),\n views: joi.alternatives().try(\n joi.object({\n Account: joi.alternatives().try(component, adminViewSchema),\n Dashboard: joi.alternatives().try(component, adminViewSchema),\n }),\n joi.object().pattern(joi.string(), component),\n ),\n }),\n custom: joi.object().pattern(joi.string(), joi.any()),\n dateFormat: joi.string(),\n disable: joi.bool(),\n livePreview: joi.object({\n ...livePreviewSchema,\n collections: joi.array().items(joi.string()),\n globals: joi.array().items(joi.string()),\n }),\n meta: joi.object().keys({\n defaultOGImageType: joi.string().valid('off', 'dynamic', 'static'),\n description: joi.string(),\n icons: joi.array().items(\n joi.object().keys({\n type: joi.string(),\n color: joi.string(),\n fetchPriority: joi.string().valid('auto', 'high', 'low'),\n media: joi.string(),\n rel: joi.string(),\n sizes: joi.string(),\n url: joi.string(),\n }),\n ),\n openGraph: openGraphSchema,\n titleSuffix: joi.string(),\n }),\n routes: joi.object({\n account: joi.string(),\n createFirstUser: joi.string(),\n forgot: joi.string(),\n inactivity: joi.string(),\n login: joi.string(),\n logout: joi.string(),\n reset: joi.string(),\n unauthorized: joi.string(),\n }),\n user: joi.string(),\n }),\n bin: joi.array().items(\n joi.object().keys({\n key: joi.string(),\n scriptPath: joi.string(),\n }),\n ),\n collections: joi.array(),\n cookiePrefix: joi.string(),\n cors: [joi.string().valid('*'), joi.array().items(joi.string())],\n csrf: joi.array().items(joi.string().allow('')).sparse(),\n custom: joi.object().pattern(joi.string(), joi.any()),\n db: joi.any(),\n debug: joi.boolean(),\n defaultDepth: joi.number().min(0).max(30),\n defaultMaxTextLength: joi.number(),\n editor: joi\n .object()\n .optional()\n .keys({\n CellComponent: componentSchema.optional(),\n FieldComponent: componentSchema.optional(),\n afterReadPromise: joi.func().optional(),\n outputSchema: joi.func().optional(),\n populationPromise: joi.func().optional(),\n validate: joi.func().required(),\n })\n .unknown(),\n email: joi.alternatives().try(joi.object(), joi.func()),\n endpoints: endpointsSchema,\n globals: joi.array(),\n graphQL: joi.object().keys({\n disable: joi.boolean(),\n disablePlaygroundInProduction: joi.boolean(),\n maxComplexity: joi.number(),\n mutations: joi.function(),\n queries: joi.function(),\n schemaOutputFile: joi.string(),\n }),\n hooks: joi.object().keys({\n afterError: joi.func(),\n }),\n i18n: joi.object(),\n indexSortableFields: joi.boolean(),\n local: joi.boolean(),\n localization: joi.alternatives().try(\n joi.object().keys({\n defaultLocale: joi.string(),\n fallback: joi.boolean(),\n localeCodes: joi.array().items(joi.string()),\n locales: joi.alternatives().try(\n joi.array().items(\n joi.object().keys({\n code: joi.string(),\n fallbackLocale: joi.string(),\n label: joi\n .alternatives()\n .try(\n joi.object().pattern(joi.string(), [joi.string()]),\n joi.string(),\n joi.valid(false),\n ),\n rtl: joi.boolean(),\n toString: joi.func(),\n }),\n ),\n joi.array().items(joi.string()),\n ),\n }),\n joi.boolean(),\n ),\n maxDepth: joi.number().min(0).max(100),\n onInit: joi.func(),\n plugins: joi.array().items(joi.func()),\n routes: joi.object({\n admin: joi.string(),\n api: joi.string(),\n graphQL: joi.string(),\n graphQLPlayground: joi.string(),\n }),\n secret: joi.string(),\n serverURL: joi\n .string()\n .uri()\n .allow('')\n .custom((value, helper) => {\n const urlWithoutProtocol = value.split('//')[1]\n\n if (!urlWithoutProtocol) {\n return helper.message({\n custom: 'You need to include either \"https://\" or \"http://\" in your serverURL.',\n })\n }\n\n if (urlWithoutProtocol.indexOf('/') > -1) {\n return helper.message({\n custom:\n 'Your serverURL cannot have a path. It can only contain a protocol, a domain, and an optional port.',\n })\n }\n\n return value\n }),\n sharp: joi.any(),\n telemetry: joi.boolean(),\n typescript: joi.object({\n autoGenerate: joi.boolean(),\n declare: joi.alternatives().try(joi.boolean(), joi.object({ ignoreTSError: joi.boolean() })),\n outputFile: joi.string(),\n }),\n upload: joi.object(),\n})\n"],"names":["joi","adminViewSchema","componentSchema","livePreviewSchema","openGraphSchema","component","alternatives","try","object","unknown","func","endpointsSchema","array","items","custom","pattern","string","any","handler","method","valid","path","root","bool","boolean","admin","autoLogin","keys","email","password","prefillOnly","avatar","buildPath","components","Nav","actions","afterDashboard","afterLogin","afterNavLinks","beforeDashboard","beforeLogin","beforeNavLinks","graphics","Icon","Logo","logout","Button","providers","views","Account","Dashboard","dateFormat","disable","livePreview","collections","globals","meta","defaultOGImageType","description","icons","type","color","fetchPriority","media","rel","sizes","url","openGraph","titleSuffix","routes","account","createFirstUser","forgot","inactivity","login","reset","unauthorized","user","bin","key","scriptPath","cookiePrefix","cors","csrf","allow","sparse","db","debug","defaultDepth","number","min","max","defaultMaxTextLength","editor","optional","CellComponent","FieldComponent","afterReadPromise","outputSchema","populationPromise","validate","required","endpoints","graphQL","disablePlaygroundInProduction","maxComplexity","mutations","function","queries","schemaOutputFile","hooks","afterError","i18n","indexSortableFields","local","localization","defaultLocale","fallback","localeCodes","locales","code","fallbackLocale","label","rtl","toString","maxDepth","onInit","plugins","api","graphQLPlayground","secret","serverURL","uri","value","helper","urlWithoutProtocol","split","message","indexOf","sharp","telemetry","typescript","autoGenerate","declare","ignoreTSError","outputFile","upload"],"rangeMappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","mappings":"AAAA,OAAOA,SAAS,MAAK;AAErB,SAASC,eAAe,QAAQ,8BAA6B;AAC7D,SAASC,eAAe,EAAEC,iBAAiB,QAAQ,8BAA6B;AAChF,SAASC,eAAe,QAAQ,8BAA6B;AAE7D,MAAMC,YAAYL,IAAIM,YAAY,GAAGC,GAAG,CAACP,IAAIQ,MAAM,GAAGC,OAAO,IAAIT,IAAIU,IAAI;AAEzE,OAAO,MAAMC,kBAAkBX,IAAIM,YAAY,GAAGC,GAAG,CACnDP,IAAIY,KAAK,GAAGC,KAAK,CACfb,IAAIQ,MAAM,CAAC;IACTM,QAAQd,IAAIQ,MAAM,GAAGO,OAAO,CAACf,IAAIgB,MAAM,IAAIhB,IAAIiB,GAAG;IAClDC,SAASlB,IAAIM,YAAY,GAAGC,GAAG,CAACP,IAAIY,KAAK,GAAGC,KAAK,CAACb,IAAIU,IAAI,KAAKV,IAAIU,IAAI;IACvES,QAAQnB,IACLgB,MAAM,GACNI,KAAK,CAAC,OAAO,QAAQ,QAAQ,OAAO,SAAS,UAAU,WAAW;IACrEC,MAAMrB,IAAIgB,MAAM;IAChBM,MAAMtB,IAAIuB,IAAI;AAChB,K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AACb,IAAIU,IAAI;IACnC2D,QAAQrE,IAAIQ,MAAM,CAAC;QACjBiB,OAAOzB,IAAIgB,MAAM;QACjBgH,KAAKhI,IAAIgB,MAAM;QACfuF,SAASvG,IAAIgB,MAAM;QACnBiH,mBAAmBjI,IAAIgB,MAAM;IAC/B;IACAkH,QAAQlI,IAAIgB,MAAM;IAClBmH,WAAWnI,IACRgB,MAAM,GACNoH,GAAG,GACHhD,KAAK,CAAC,IACNtE,MAAM,CAAC,CAACuH,OAAOC;QACd,MAAMC,qBAAqBF,MAAMG,KAAK,CAAC,KAAK,CAAC,EAAE;QAE/C,IAAI,CAACD,oBAAoB;YACvB,OAAOD,OAAOG,OAAO,CAAC;gBACpB3H,QAAQ;YACV;QACF;QAEA,IAAIyH,mBAAmBG,OAAO,CAAC,OAAO,CAAC,GAAG;YACxC,OAAOJ,OAAOG,OAAO,CAAC;gBACpB3H,QACE;YACJ;QACF;QAEA,OAAOuH;IACT;IACFM,OAAO3I,IAAIiB,GAAG;IACd2H,WAAW5I,IAAIwB,OAAO;IACtBqH,YAAY7I,IAAIQ,MAAM,CAAC;QACrBsI,cAAc9I,IAAIwB,OAAO;QACzBuH,SAAS/I,IAAIM,YAAY,GAAGC,GAAG,CAACP,IAAIwB,OAAO,IAAIxB,IAAIQ,MAAM,CAAC;YAAEwI,eAAehJ,IAAIwB,OAAO;QAAG;QACzFyH,YAAYjJ,IAAIgB,MAAM;IACxB;IACAkI,QAAQlJ,IAAIQ,MAAM;AACpB,GAAE"}
@@ -474,6 +474,8 @@ export type Config = {
474
474
  login?: string;
475
475
  /** The route for the logout page. */
476
476
  logout?: string;
477
+ /** The route for the reset password page. */
478
+ reset?: string;
477
479
  /** The route for the unauthorized page. */
478
480
  unauthorized?: string;
479
481
  };
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/config/types.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,EACV,yBAAyB,EACzB,UAAU,EACV,WAAW,EAC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"version":3,"sources":["../../src/config/types.ts"],"sourcesContent":["import type {\n DefaultTranslationsObject,\n I18nClient,\n I18nOptions,\n TFunction,\n} from '@payloadcms/translations'\nimport type { Options as ExpressFileUploadOptions } from 'express-fileupload'\nimport type GraphQL from 'graphql'\nimport type { Metadata as NextMetadata } from 'next'\nimport type { DestinationStream, LoggerOptions } from 'pino'\nimport type React from 'react'\nimport type { JSX } from 'react'\nimport type { default as sharp } from 'sharp'\nimport type { DeepRequired } from 'ts-essentials'\n\nimport type { RichTextAdapterProvider } from '../admin/RichText.js'\nimport type { DocumentTab, RichTextAdapter } from '../admin/types.js'\nimport type { AdminView, ServerSideEditViewProps } from '../admin/views/types.js'\nimport type { Permissions } from '../auth/index.js'\nimport type {\n AfterErrorHook,\n Collection,\n CollectionConfig,\n SanitizedCollectionConfig,\n} from '../collections/config/types.js'\nimport type { DatabaseAdapterResult } from '../database/types.js'\nimport type { EmailAdapter, SendEmailOptions } from '../email/types.js'\nimport type { GlobalConfig, Globals, SanitizedGlobalConfig } from '../globals/config/types.js'\nimport type { GeneratedTypes, Payload } from '../index.js'\nimport type { PayloadRequest, PayloadRequestWithData, Where } from '../types/index.js'\nimport type { PayloadLogger } from '../utilities/logger.js'\n\nexport type BinScriptConfig = {\n key: string\n scriptPath: string\n}\n\nexport type BinScript = (config: SanitizedConfig) => Promise<void> | void\n\ntype Prettify<T> = {\n [K in keyof T]: T[K]\n} & NonNullable<unknown>\n\n// eslint-disable-next-line no-use-before-define\nexport type Plugin = (config: Config) => Config | Promise<Config>\n\nexport type LivePreviewConfig = {\n /**\n Device breakpoints to use for the `iframe` of the Live Preview window.\n Options are displayed in the Live Preview toolbar.\n The `responsive` breakpoint is included by default.\n */\n breakpoints?: {\n height: number | string\n label: string\n name: string\n width: number | string\n }[]\n /**\n The URL of the frontend application. This will be rendered within an `iframe` as its `src`.\n Payload will send a `window.postMessage()` to this URL with the document data in real-time.\n The frontend application is responsible for receiving the message and updating the UI accordingly.\n Use the `useLivePreview` hook to get started in React applications.\n */\n url?:\n | ((args: {\n collectionConfig?: SanitizedCollectionConfig\n data: Record<string, any>\n globalConfig?: SanitizedGlobalConfig\n locale: Locale\n payload: Payload\n }) => Promise<string> | string)\n | string\n}\n\nexport type OGImageConfig = {\n alt?: string\n height?: number | string\n type?: string\n url: string\n width?: number | string\n}\n\nexport type OpenGraphConfig = {\n description?: string\n images?: OGImageConfig | OGImageConfig[]\n siteName?: string\n title?: string\n}\n\nexport type IconConfig = {\n color?: string\n /**\n * @see https://developer.mozilla.org/docs/Web/API/HTMLImageElement/fetchPriority\n */\n fetchPriority?: 'auto' | 'high' | 'low'\n media?: string\n /** defaults to rel=\"icon\" */\n rel?: string\n sizes?: string\n type?: string\n url: string\n}\n\nexport type MetaConfig = {\n /**\n * When `static`, a pre-made image will be used for all pages.\n * When `dynamic`, a unique image will be generated for each page based on page content and given overrides.\n * When `off`, no Open Graph images will be generated and the `/api/og` endpoint will be disabled. You can still provide custom images using the `openGraph.images` property.\n * @default 'dynamic'\n */\n defaultOGImageType?: 'dynamic' | 'off' | 'static'\n /**\n * Overrides the auto-generated <meta name=\"description\"> of admin pages\n * @example `\"This is my custom CMS built with Payload.\"`\n */\n description?: string\n /**\n * Icons to be rendered by devices and browsers.\n *\n * For example browser tabs, phone home screens, and search engine results.\n */\n icons?: IconConfig[]\n /**\n * Overrides the auto-generated <meta name=\"keywords\"> of admin pages\n * @example `\"CMS, Payload, Custom\"`\n */\n keywords?: string\n /**\n * Metadata to be rendered as `og` meta tags in the head of the Admin Panel.\n *\n * For example when sharing the Admin Panel on social media or through messaging services.\n */\n openGraph?: OpenGraphConfig\n /**\n * Overrides the auto-generated <title> of admin pages\n * @example `\"My Admin Panel\"`\n */\n title?: string\n /**\n * String to append to the auto-generated <title> of admin pages\n * @example `\" - Custom CMS\"`\n */\n titleSuffix?: string\n}\n\nexport type ServerOnlyLivePreviewProperties = keyof Pick<LivePreviewConfig, 'url'>\n\ntype GeneratePreviewURLOptions = {\n locale: string\n req: PayloadRequestWithData\n token: null | string\n}\n\nexport type GeneratePreviewURL = (\n doc: Record<string, unknown>,\n options: GeneratePreviewURLOptions,\n) => Promise<null | string> | null | string\n\nexport type GraphQLInfo = {\n Mutation: {\n fields: Record<string, any>\n name: string\n }\n Query: {\n fields: Record<string, any>\n name: string\n }\n collections: {\n [slug: number | string | symbol]: Collection\n }\n globals: Globals\n types: {\n arrayTypes: Record<string, GraphQL.GraphQLType>\n blockInputTypes: Record<string, GraphQL.GraphQLInputObjectType>\n blockTypes: Record<string, GraphQL.GraphQLObjectType>\n fallbackLocaleInputType?: GraphQL.GraphQLEnumType | GraphQL.GraphQLScalarType\n groupTypes: Record<string, GraphQL.GraphQLObjectType>\n localeInputType?: GraphQL.GraphQLEnumType | GraphQL.GraphQLScalarType\n tabTypes: Record<string, GraphQL.GraphQLObjectType>\n }\n}\nexport type GraphQLExtension = (\n graphQL: typeof GraphQL,\n context: {\n config: SanitizedConfig\n } & GraphQLInfo,\n) => Record<string, unknown>\n\nexport type InitOptions = {\n /**\n * Sometimes, with the local API, you might need to pass a config file directly, for example, serverless on Vercel\n * The passed config should match the config file, and if it doesn't, there could be mismatches between the admin UI\n * and the backend functionality\n */\n config: Promise<SanitizedConfig> | SanitizedConfig\n /**\n * Disable connect to the database on init\n */\n disableDBConnect?: boolean\n\n /**\n * Disable running of the `onInit` function\n */\n disableOnInit?: boolean\n\n /**\n * A previously instantiated logger instance. Must conform to the PayloadLogger interface which uses Pino\n * This allows you to bring your own logger instance and let payload use it\n */\n logger?: PayloadLogger\n\n loggerDestination?: DestinationStream\n\n /**\n * Specify options for the built-in Pino logger that Payload uses for internal logging.\n *\n * See Pino Docs for options: https://getpino.io/#/docs/api?id=options\n */\n loggerOptions?: LoggerOptions\n /**\n * A function that is called immediately following startup that receives the Payload instance as it's only argument.\n */\n onInit?: (payload: Payload) => Promise<void> | void\n}\n\n/**\n * This result is calculated on the server\n * and then sent to the client allowing the dashboard to show accessible data and actions.\n *\n * If the result is `true`, the user has access.\n * If the result is an object, it is interpreted as a MongoDB query.\n *\n * @example `{ createdBy: { equals: id } }`\n *\n * @example `{ tenant: { in: tenantIds } }`\n *\n * @see https://payloadcms.com/docs/access-control/overview\n */\nexport type AccessResult = Where | boolean\n\nexport type AccessArgs<TData = any> = {\n /**\n * The relevant resource that is being accessed.\n *\n * `data` is null when a list is requested\n */\n data?: TData\n /** ID of the resource being accessed */\n id?: number | string\n /** If true, the request is for a static file */\n isReadingStaticFile?: boolean\n /** The original request that requires an access check */\n req: PayloadRequestWithData\n}\n\n/**\n * Access function runs on the server\n * and is sent to the client allowing the dashboard to show accessible data and actions.\n *\n * @see https://payloadcms.com/docs/access-control/overview\n */\nexport type Access<TData = any> = (args: AccessArgs<TData>) => AccessResult | Promise<AccessResult>\n\n/** Web Request/Response model, but the req has more payload specific properties added to it. */\nexport type PayloadHandler = (req: PayloadRequest) => Promise<Response> | Response\n\n/**\n * Docs: https://payloadcms.com/docs/rest-api/overview#custom-endpoints\n */\nexport type Endpoint = {\n /** Extension point to add your custom data. */\n custom?: Record<string, any>\n\n /**\n * Middleware that will be called when the path/method matches\n *\n * Compatible with Web Request/Response Model\n */\n handler: PayloadHandler\n /** HTTP method (or \"all\") */\n method: 'connect' | 'delete' | 'get' | 'head' | 'options' | 'patch' | 'post' | 'put'\n /**\n * Pattern that should match the path of the incoming request\n *\n * Compatible with the Express router\n */\n path: string\n /**\n * Please add \"root\" routes under the /api folder in the Payload Project.\n * https://nextjs.org/docs/app/api-reference/file-conventions/route\n *\n * @deprecated in 3.0\n */\n root?: never\n}\n\nexport type EditViewComponent = React.ComponentType<ServerSideEditViewProps>\n\nexport type EditViewConfig =\n | {\n /**\n * Add a new Edit view to the admin panel\n * i.e. you can render a custom view that has no tab, if desired\n * Or override a specific properties of an existing one\n * i.e. you can customize the `Default` view tab label, if desired\n */\n Tab?: DocumentTab\n path?: string\n }\n | {\n Component: EditViewComponent\n path: string\n }\n | {\n actions?: CustomComponent[]\n }\n\n/**\n * Override existing views\n * i.e. Dashboard, Account, API, LivePreview, etc.\n * Path is not available here\n * All Tab properties become optional\n * i.e. you can change just the label, if desired\n */\nexport type EditView = EditViewComponent | EditViewConfig\n\nexport type ServerProps = {\n [key: string]: unknown\n i18n: I18nClient\n locale?: Locale\n params?: { [key: string]: string | string[] | undefined }\n payload: Payload\n permissions?: Permissions\n searchParams?: { [key: string]: string | string[] | undefined }\n user?: GeneratedTypes['user']\n}\n\nexport const serverProps: (keyof ServerProps)[] = [\n 'payload',\n 'i18n',\n 'locale',\n 'params',\n 'permissions',\n 'searchParams',\n 'permissions',\n]\n\nexport type CustomComponent<TAdditionalProps extends any = any> = React.ComponentType<\n TAdditionalProps & Partial<ServerProps>\n>\n\nexport type Locale = {\n /**\n * value of supported locale\n * @example \"en\"\n */\n code: string\n /**\n * Code of another locale to use when reading documents with fallback, if not specified defaultLocale is used\n */\n fallbackLocale?: string\n /**\n * label of supported locale\n * @example \"English\"\n */\n label: Record<string, string> | string\n /**\n * if true, defaults textAligmnent on text fields to RTL\n */\n rtl?: boolean\n}\n\nexport type BaseLocalizationConfig = {\n /**\n * Locale for users that have not expressed their preference for a specific locale\n * @example `\"en\"`\n */\n defaultLocale: string\n /** Set to `true` to let missing values in localised fields fall back to the values in `defaultLocale` */\n fallback?: boolean\n}\n\nexport type LocalizationConfigWithNoLabels = Prettify<\n BaseLocalizationConfig & {\n /**\n * List of supported locales\n * @example `[\"en\", \"es\", \"fr\", \"nl\", \"de\", \"jp\"]`\n */\n locales: string[]\n }\n>\n\nexport type LocalizationConfigWithLabels = Prettify<\n BaseLocalizationConfig & {\n /**\n * List of supported locales with labels\n * @example {\n * label: 'English',\n * value: 'en',\n * rtl: false\n * }\n */\n locales: Locale[]\n }\n>\n\nexport type SanitizedLocalizationConfig = Prettify<\n LocalizationConfigWithLabels & {\n /**\n * List of supported locales\n * @example `[\"en\", \"es\", \"fr\", \"nl\", \"de\", \"jp\"]`\n */\n localeCodes: string[]\n }\n>\n\n/**\n * @see https://payloadcms.com/docs/configuration/localization#localization\n */\nexport type LocalizationConfig = Prettify<\n LocalizationConfigWithLabels | LocalizationConfigWithNoLabels\n>\n\nexport type LabelFunction = ({ t }: { t: TFunction }) => string\n\nexport type SharpDependency = (\n input?:\n | ArrayBuffer\n | Buffer\n | Float32Array\n | Float64Array\n | Int8Array\n | Int16Array\n | Int32Array\n | Uint8Array\n | Uint8ClampedArray\n | Uint16Array\n | Uint32Array\n | string,\n options?: sharp.SharpOptions,\n) => sharp.Sharp\n\n/**\n * This is the central configuration\n *\n * @see https://payloadcms.com/docs/configuration/overview\n */\nexport type Config = {\n /** Configure admin dashboard */\n admin?: {\n /** Automatically log in as a user when visiting the admin dashboard. */\n autoLogin?:\n | {\n /**\n * The email address of the user to login as\n *\n */\n email: string\n /** The password of the user to login as */\n password: string\n /**\n * If set to true, the login credentials will be prefilled but the user will still need to click the login button.\n *\n * @default false\n */\n prefillOnly?: boolean\n }\n | false\n /** Set account profile picture. Options: gravatar, default or a custom React component. */\n avatar?: 'default' | 'gravatar' | React.ComponentType<any>\n\n /**\n * Add extra and/or replace built-in components with custom components\n *\n * @see https://payloadcms.com/docs/admin/components\n */\n components?: {\n /**\n * Replace the navigation with a custom component\n */\n Nav?: CustomComponent\n /**\n * Add custom components to the top right of the Admin Panel\n */\n actions?: CustomComponent[]\n /**\n * Add custom components after the collection overview\n */\n afterDashboard?: CustomComponent[]\n /**\n * Add custom components after the email/password field\n */\n afterLogin?: CustomComponent[]\n /**\n * Add custom components after the navigation links\n */\n afterNavLinks?: CustomComponent[]\n /**\n * Add custom components before the collection overview\n */\n beforeDashboard?: CustomComponent[]\n /**\n * Add custom components before the email/password field\n */\n beforeLogin?: CustomComponent[]\n /**\n * Add custom components before the navigation links\n */\n beforeNavLinks?: CustomComponent[]\n /** Replace graphical components */\n graphics?: {\n /** Replace the icon in the navigation */\n Icon?: CustomComponent\n /** Replace the logo on the login page */\n Logo?: CustomComponent\n }\n /** Replace logout related components */\n logout?: {\n /** Replace the logout button */\n Button?: CustomComponent\n }\n /**\n * Wrap the admin dashboard in custom context providers\n */\n providers?: React.ComponentType<{ children?: React.ReactNode }>[]\n /**\n * Replace or modify top-level admin routes, or add new ones:\n * + `Account` - `/admin/account`\n * + `Dashboard` - `/admin`\n * + `:path` - `/admin/:path`\n */\n views?: {\n /** Add custom admin views */\n [key: string]: AdminView\n /** Replace the account screen */\n Account?: AdminView\n /** Replace the admin homepage */\n Dashboard?: AdminView\n }\n }\n /** Extension point to add your custom data. Available in server and client. */\n custom?: Record<string, any>\n /** Global date format that will be used for all dates in the Admin panel. Any valid date-fns format pattern can be used. */\n dateFormat?: string\n /** If set to true, the entire Admin panel will be disabled. */\n disable?: boolean\n livePreview?: LivePreviewConfig & {\n collections?: string[]\n globals?: string[]\n }\n /** Base meta data to use for the Admin Panel. Included properties are titleSuffix, ogImage, and favicon. */\n meta?: MetaConfig\n routes?: {\n /** The route for the account page. */\n account?: string\n /** The route for the create first user page. */\n createFirstUser?: string\n /** The route for the forgot password page. */\n forgot?: string\n /** The route the user will be redirected to after being inactive for too long. */\n inactivity?: string\n /** The route for the login page. */\n login?: string\n /** The route for the logout page. */\n logout?: string\n /** The route for the unauthorized page. */\n unauthorized?: string\n }\n /** The slug of a Collection that you want to be used to log in to the Admin dashboard. */\n user?: string\n }\n /** Custom Payload bin scripts can be injected via the config. */\n bin?: BinScriptConfig[]\n /**\n * Manage the datamodel of your application\n *\n * @see https://payloadcms.com/docs/configuration/collections#collection-configs\n */\n collections?: CollectionConfig[]\n /**\n * Replace the built-in components with custom ones\n */\n components?: { [key: string]: (() => JSX.Element) | JSX.Element }\n /**\n * Prefix a string to all cookies that Payload sets.\n *\n * @default \"payload\"\n */\n cookiePrefix?: string\n /** Either a whitelist array of URLS to allow CORS requests from, or a wildcard string ('*') to accept incoming requests from any domain. */\n cors?: '*' | string[]\n /** A whitelist array of URLs to allow Payload cookies to be accepted from as a form of CSRF protection. */\n csrf?: string[]\n\n /** Extension point to add your custom data. Server only. */\n custom?: Record<string, any>\n\n /** Pass in a database adapter for use on this project. */\n db: DatabaseAdapterResult\n /** Enable to expose more detailed error information. */\n debug?: boolean\n /**\n * If a user does not specify `depth` while requesting a resource, this depth will be used.\n *\n * @see https://payloadcms.com/docs/getting-started/concepts#depth\n *\n * @default 2\n */\n defaultDepth?: number\n /**\n * The maximum allowed depth to be permitted application-wide. This setting helps prevent against malicious queries.\n *\n * @default 40000\n */\n defaultMaxTextLength?: number\n /** Default richtext editor to use for richText fields */\n editor?: RichTextAdapterProvider<any, any, any>\n /**\n * Email Adapter\n *\n * @see https://payloadcms.com/docs/email/overview\n */\n email?: EmailAdapter | Promise<EmailAdapter>\n /** Custom REST endpoints */\n endpoints?: Endpoint[]\n /**\n * @see https://payloadcms.com/docs/configuration/globals#global-configs\n */\n globals?: GlobalConfig[]\n /**\n * Manage the GraphQL API\n *\n * You can add your own GraphQL queries and mutations to Payload, making use of all the types that Payload has defined for you.\n *\n * @see https://payloadcms.com/docs/graphql/overview\n */\n graphQL?: {\n disable?: boolean\n disablePlaygroundInProduction?: boolean\n maxComplexity?: number\n /**\n * Function that returns an object containing keys to custom GraphQL mutations\n *\n * @see https://payloadcms.com/docs/graphql/extending\n */\n mutations?: GraphQLExtension\n /**\n * Function that returns an object containing keys to custom GraphQL queries\n *\n * @see https://payloadcms.com/docs/graphql/extending\n */\n queries?: GraphQLExtension\n /**\n * Filepath to write the generated schema to\n */\n schemaOutputFile?: string\n }\n /**\n * Tap into Payload-wide hooks.\n *\n * @see https://payloadcms.com/docs/hooks/overview\n */\n hooks?: {\n afterError?: AfterErrorHook\n }\n /** i18n config settings */\n i18n?: I18nOptions<{} | DefaultTranslationsObject> // loosen the type here to allow for custom translations\n /** Automatically index all sortable top-level fields in the database to improve sort performance and add database compatibility for Azure Cosmos and similar. */\n indexSortableFields?: boolean\n /**\n * Translate your content to different languages/locales.\n *\n * @default false // disable localization\n */\n localization?: LocalizationConfig | false\n /**\n * The maximum allowed depth to be permitted application-wide. This setting helps prevent against malicious queries.\n *\n * @see https://payloadcms.com/docs/getting-started/concepts#depth\n *\n * @default 10\n */\n maxDepth?: number\n /** A function that is called immediately following startup that receives the Payload instance as its only argument. */\n onInit?: (payload: Payload) => Promise<void> | void\n /**\n * An array of Payload plugins.\n *\n * @see https://payloadcms.com/docs/plugins/overview\n */\n plugins?: Plugin[]\n /** Control the routing structure that Payload binds itself to. */\n routes?: {\n /** @default \"/admin\" */\n admin?: string\n /** @default \"/api\" */\n api?: string\n /** @default \"/graphql\" */\n graphQL?: string\n /** @default \"/graphql-playground\" */\n graphQLPlayground?: string\n }\n /** Secure string that Payload will use for any encryption workflows */\n secret: string\n /**\n * Define the absolute URL of your app including the protocol, for example `https://example.org`.\n * No paths allowed, only protocol, domain and (optionally) port.\n *\n * @see https://payloadcms.com/docs/configuration/overview#options\n */\n serverURL?: string\n /**\n * Pass in a local copy of Sharp if you'd like to use it.\n *\n */\n sharp?: SharpDependency\n /** Send anonymous telemetry data about general usage. */\n telemetry?: boolean\n /** Control how typescript interfaces are generated from your collections. */\n typescript?: {\n /**\n * Automatically generate types during development\n * @default true\n */\n autoGenerate?: boolean\n\n /** Disable declare block in generated types file */\n declare?:\n | {\n /**\n * @internal internal use only to allow for multiple declarations within a monorepo and suppress the \"Duplicate identifier GeneratedTypes\" error\n *\n * Adds a @ts-ignore flag above the GeneratedTypes interface declaration\n *\n * @default false\n */\n ignoreTSError?: boolean\n }\n | false\n\n /** Filename to write the generated types to */\n outputFile?: string\n }\n /**\n * Customize the handling of incoming file uploads for collections that have uploads enabled.\n */\n upload?: ExpressFileUploadOptions\n}\n\nexport type SanitizedConfig = Omit<\n DeepRequired<Config>,\n 'collections' | 'editor' | 'endpoint' | 'globals' | 'i18n' | 'localization' | 'upload'\n> & {\n collections: SanitizedCollectionConfig[]\n /** Default richtext editor to use for richText fields */\n editor?: RichTextAdapter<any, any, any>\n endpoints: Endpoint[]\n globals: SanitizedGlobalConfig[]\n i18n: Required<I18nOptions>\n localization: SanitizedLocalizationConfig | false\n paths: {\n config: string\n configDir: string\n rawConfig: string\n }\n upload: ExpressFileUploadOptions & {\n /**\n * Deduped list of adapters used in the project\n */\n adapters: string[]\n }\n}\n\nexport type EditConfig =\n | (\n | {\n /**\n * Replace or modify individual nested routes, or add new ones:\n * + `Default` - `/admin/collections/:collection/:id`\n * + `API` - `/admin/collections/:collection/:id/api`\n * + `LivePreview` - `/admin/collections/:collection/:id/preview`\n * + `References` - `/admin/collections/:collection/:id/references`\n * + `Relationships` - `/admin/collections/:collection/:id/relationships`\n * + `Versions` - `/admin/collections/:collection/:id/versions`\n * + `Version` - `/admin/collections/:collection/:id/versions/:version`\n * + `CustomView` - `/admin/collections/:collection/:id/:path`\n */\n API?: EditViewComponent | Partial<EditViewConfig>\n Default?: EditViewComponent | Partial<EditViewConfig>\n LivePreview?: EditViewComponent | Partial<EditViewConfig>\n Version?: EditViewComponent | Partial<EditViewConfig>\n Versions?: EditViewComponent | Partial<EditViewConfig>\n // TODO: uncomment these as they are built\n // References?: EditView\n // Relationships?: EditView\n }\n | {\n [key: string]: EditViewConfig\n }\n )\n | EditViewComponent\n\nexport type EntityDescriptionComponent = CustomComponent\n\nexport type EntityDescriptionFunction = ({ t }: { t: TFunction }) => string\n\nexport type EntityDescription = EntityDescriptionFunction | Record<string, string> | string\n\nexport type { EmailAdapter, SendEmailOptions }\n"],"names":["serverProps"],"rangeMappings":";;;;;;;;","mappings":"AAkVA,OAAO,MAAMA,cAAqC;IAChD;IACA;IACA;IACA;IACA;IACA;IACA;CACD,CAAA"}
1
+ {"version":3,"sources":["../../src/config/types.ts"],"sourcesContent":["import type {\n DefaultTranslationsObject,\n I18nClient,\n I18nOptions,\n TFunction,\n} from '@payloadcms/translations'\nimport type { Options as ExpressFileUploadOptions } from 'express-fileupload'\nimport type GraphQL from 'graphql'\nimport type { Metadata as NextMetadata } from 'next'\nimport type { DestinationStream, LoggerOptions } from 'pino'\nimport type React from 'react'\nimport type { JSX } from 'react'\nimport type { default as sharp } from 'sharp'\nimport type { DeepRequired } from 'ts-essentials'\n\nimport type { RichTextAdapterProvider } from '../admin/RichText.js'\nimport type { DocumentTab, RichTextAdapter } from '../admin/types.js'\nimport type { AdminView, ServerSideEditViewProps } from '../admin/views/types.js'\nimport type { Permissions } from '../auth/index.js'\nimport type {\n AfterErrorHook,\n Collection,\n CollectionConfig,\n SanitizedCollectionConfig,\n} from '../collections/config/types.js'\nimport type { DatabaseAdapterResult } from '../database/types.js'\nimport type { EmailAdapter, SendEmailOptions } from '../email/types.js'\nimport type { GlobalConfig, Globals, SanitizedGlobalConfig } from '../globals/config/types.js'\nimport type { GeneratedTypes, Payload } from '../index.js'\nimport type { PayloadRequest, PayloadRequestWithData, Where } from '../types/index.js'\nimport type { PayloadLogger } from '../utilities/logger.js'\n\nexport type BinScriptConfig = {\n key: string\n scriptPath: string\n}\n\nexport type BinScript = (config: SanitizedConfig) => Promise<void> | void\n\ntype Prettify<T> = {\n [K in keyof T]: T[K]\n} & NonNullable<unknown>\n\n// eslint-disable-next-line no-use-before-define\nexport type Plugin = (config: Config) => Config | Promise<Config>\n\nexport type LivePreviewConfig = {\n /**\n Device breakpoints to use for the `iframe` of the Live Preview window.\n Options are displayed in the Live Preview toolbar.\n The `responsive` breakpoint is included by default.\n */\n breakpoints?: {\n height: number | string\n label: string\n name: string\n width: number | string\n }[]\n /**\n The URL of the frontend application. This will be rendered within an `iframe` as its `src`.\n Payload will send a `window.postMessage()` to this URL with the document data in real-time.\n The frontend application is responsible for receiving the message and updating the UI accordingly.\n Use the `useLivePreview` hook to get started in React applications.\n */\n url?:\n | ((args: {\n collectionConfig?: SanitizedCollectionConfig\n data: Record<string, any>\n globalConfig?: SanitizedGlobalConfig\n locale: Locale\n payload: Payload\n }) => Promise<string> | string)\n | string\n}\n\nexport type OGImageConfig = {\n alt?: string\n height?: number | string\n type?: string\n url: string\n width?: number | string\n}\n\nexport type OpenGraphConfig = {\n description?: string\n images?: OGImageConfig | OGImageConfig[]\n siteName?: string\n title?: string\n}\n\nexport type IconConfig = {\n color?: string\n /**\n * @see https://developer.mozilla.org/docs/Web/API/HTMLImageElement/fetchPriority\n */\n fetchPriority?: 'auto' | 'high' | 'low'\n media?: string\n /** defaults to rel=\"icon\" */\n rel?: string\n sizes?: string\n type?: string\n url: string\n}\n\nexport type MetaConfig = {\n /**\n * When `static`, a pre-made image will be used for all pages.\n * When `dynamic`, a unique image will be generated for each page based on page content and given overrides.\n * When `off`, no Open Graph images will be generated and the `/api/og` endpoint will be disabled. You can still provide custom images using the `openGraph.images` property.\n * @default 'dynamic'\n */\n defaultOGImageType?: 'dynamic' | 'off' | 'static'\n /**\n * Overrides the auto-generated <meta name=\"description\"> of admin pages\n * @example `\"This is my custom CMS built with Payload.\"`\n */\n description?: string\n /**\n * Icons to be rendered by devices and browsers.\n *\n * For example browser tabs, phone home screens, and search engine results.\n */\n icons?: IconConfig[]\n /**\n * Overrides the auto-generated <meta name=\"keywords\"> of admin pages\n * @example `\"CMS, Payload, Custom\"`\n */\n keywords?: string\n /**\n * Metadata to be rendered as `og` meta tags in the head of the Admin Panel.\n *\n * For example when sharing the Admin Panel on social media or through messaging services.\n */\n openGraph?: OpenGraphConfig\n /**\n * Overrides the auto-generated <title> of admin pages\n * @example `\"My Admin Panel\"`\n */\n title?: string\n /**\n * String to append to the auto-generated <title> of admin pages\n * @example `\" - Custom CMS\"`\n */\n titleSuffix?: string\n}\n\nexport type ServerOnlyLivePreviewProperties = keyof Pick<LivePreviewConfig, 'url'>\n\ntype GeneratePreviewURLOptions = {\n locale: string\n req: PayloadRequestWithData\n token: null | string\n}\n\nexport type GeneratePreviewURL = (\n doc: Record<string, unknown>,\n options: GeneratePreviewURLOptions,\n) => Promise<null | string> | null | string\n\nexport type GraphQLInfo = {\n Mutation: {\n fields: Record<string, any>\n name: string\n }\n Query: {\n fields: Record<string, any>\n name: string\n }\n collections: {\n [slug: number | string | symbol]: Collection\n }\n globals: Globals\n types: {\n arrayTypes: Record<string, GraphQL.GraphQLType>\n blockInputTypes: Record<string, GraphQL.GraphQLInputObjectType>\n blockTypes: Record<string, GraphQL.GraphQLObjectType>\n fallbackLocaleInputType?: GraphQL.GraphQLEnumType | GraphQL.GraphQLScalarType\n groupTypes: Record<string, GraphQL.GraphQLObjectType>\n localeInputType?: GraphQL.GraphQLEnumType | GraphQL.GraphQLScalarType\n tabTypes: Record<string, GraphQL.GraphQLObjectType>\n }\n}\nexport type GraphQLExtension = (\n graphQL: typeof GraphQL,\n context: {\n config: SanitizedConfig\n } & GraphQLInfo,\n) => Record<string, unknown>\n\nexport type InitOptions = {\n /**\n * Sometimes, with the local API, you might need to pass a config file directly, for example, serverless on Vercel\n * The passed config should match the config file, and if it doesn't, there could be mismatches between the admin UI\n * and the backend functionality\n */\n config: Promise<SanitizedConfig> | SanitizedConfig\n /**\n * Disable connect to the database on init\n */\n disableDBConnect?: boolean\n\n /**\n * Disable running of the `onInit` function\n */\n disableOnInit?: boolean\n\n /**\n * A previously instantiated logger instance. Must conform to the PayloadLogger interface which uses Pino\n * This allows you to bring your own logger instance and let payload use it\n */\n logger?: PayloadLogger\n\n loggerDestination?: DestinationStream\n\n /**\n * Specify options for the built-in Pino logger that Payload uses for internal logging.\n *\n * See Pino Docs for options: https://getpino.io/#/docs/api?id=options\n */\n loggerOptions?: LoggerOptions\n /**\n * A function that is called immediately following startup that receives the Payload instance as it's only argument.\n */\n onInit?: (payload: Payload) => Promise<void> | void\n}\n\n/**\n * This result is calculated on the server\n * and then sent to the client allowing the dashboard to show accessible data and actions.\n *\n * If the result is `true`, the user has access.\n * If the result is an object, it is interpreted as a MongoDB query.\n *\n * @example `{ createdBy: { equals: id } }`\n *\n * @example `{ tenant: { in: tenantIds } }`\n *\n * @see https://payloadcms.com/docs/access-control/overview\n */\nexport type AccessResult = Where | boolean\n\nexport type AccessArgs<TData = any> = {\n /**\n * The relevant resource that is being accessed.\n *\n * `data` is null when a list is requested\n */\n data?: TData\n /** ID of the resource being accessed */\n id?: number | string\n /** If true, the request is for a static file */\n isReadingStaticFile?: boolean\n /** The original request that requires an access check */\n req: PayloadRequestWithData\n}\n\n/**\n * Access function runs on the server\n * and is sent to the client allowing the dashboard to show accessible data and actions.\n *\n * @see https://payloadcms.com/docs/access-control/overview\n */\nexport type Access<TData = any> = (args: AccessArgs<TData>) => AccessResult | Promise<AccessResult>\n\n/** Web Request/Response model, but the req has more payload specific properties added to it. */\nexport type PayloadHandler = (req: PayloadRequest) => Promise<Response> | Response\n\n/**\n * Docs: https://payloadcms.com/docs/rest-api/overview#custom-endpoints\n */\nexport type Endpoint = {\n /** Extension point to add your custom data. */\n custom?: Record<string, any>\n\n /**\n * Middleware that will be called when the path/method matches\n *\n * Compatible with Web Request/Response Model\n */\n handler: PayloadHandler\n /** HTTP method (or \"all\") */\n method: 'connect' | 'delete' | 'get' | 'head' | 'options' | 'patch' | 'post' | 'put'\n /**\n * Pattern that should match the path of the incoming request\n *\n * Compatible with the Express router\n */\n path: string\n /**\n * Please add \"root\" routes under the /api folder in the Payload Project.\n * https://nextjs.org/docs/app/api-reference/file-conventions/route\n *\n * @deprecated in 3.0\n */\n root?: never\n}\n\nexport type EditViewComponent = React.ComponentType<ServerSideEditViewProps>\n\nexport type EditViewConfig =\n | {\n /**\n * Add a new Edit view to the admin panel\n * i.e. you can render a custom view that has no tab, if desired\n * Or override a specific properties of an existing one\n * i.e. you can customize the `Default` view tab label, if desired\n */\n Tab?: DocumentTab\n path?: string\n }\n | {\n Component: EditViewComponent\n path: string\n }\n | {\n actions?: CustomComponent[]\n }\n\n/**\n * Override existing views\n * i.e. Dashboard, Account, API, LivePreview, etc.\n * Path is not available here\n * All Tab properties become optional\n * i.e. you can change just the label, if desired\n */\nexport type EditView = EditViewComponent | EditViewConfig\n\nexport type ServerProps = {\n [key: string]: unknown\n i18n: I18nClient\n locale?: Locale\n params?: { [key: string]: string | string[] | undefined }\n payload: Payload\n permissions?: Permissions\n searchParams?: { [key: string]: string | string[] | undefined }\n user?: GeneratedTypes['user']\n}\n\nexport const serverProps: (keyof ServerProps)[] = [\n 'payload',\n 'i18n',\n 'locale',\n 'params',\n 'permissions',\n 'searchParams',\n 'permissions',\n]\n\nexport type CustomComponent<TAdditionalProps extends any = any> = React.ComponentType<\n TAdditionalProps & Partial<ServerProps>\n>\n\nexport type Locale = {\n /**\n * value of supported locale\n * @example \"en\"\n */\n code: string\n /**\n * Code of another locale to use when reading documents with fallback, if not specified defaultLocale is used\n */\n fallbackLocale?: string\n /**\n * label of supported locale\n * @example \"English\"\n */\n label: Record<string, string> | string\n /**\n * if true, defaults textAligmnent on text fields to RTL\n */\n rtl?: boolean\n}\n\nexport type BaseLocalizationConfig = {\n /**\n * Locale for users that have not expressed their preference for a specific locale\n * @example `\"en\"`\n */\n defaultLocale: string\n /** Set to `true` to let missing values in localised fields fall back to the values in `defaultLocale` */\n fallback?: boolean\n}\n\nexport type LocalizationConfigWithNoLabels = Prettify<\n BaseLocalizationConfig & {\n /**\n * List of supported locales\n * @example `[\"en\", \"es\", \"fr\", \"nl\", \"de\", \"jp\"]`\n */\n locales: string[]\n }\n>\n\nexport type LocalizationConfigWithLabels = Prettify<\n BaseLocalizationConfig & {\n /**\n * List of supported locales with labels\n * @example {\n * label: 'English',\n * value: 'en',\n * rtl: false\n * }\n */\n locales: Locale[]\n }\n>\n\nexport type SanitizedLocalizationConfig = Prettify<\n LocalizationConfigWithLabels & {\n /**\n * List of supported locales\n * @example `[\"en\", \"es\", \"fr\", \"nl\", \"de\", \"jp\"]`\n */\n localeCodes: string[]\n }\n>\n\n/**\n * @see https://payloadcms.com/docs/configuration/localization#localization\n */\nexport type LocalizationConfig = Prettify<\n LocalizationConfigWithLabels | LocalizationConfigWithNoLabels\n>\n\nexport type LabelFunction = ({ t }: { t: TFunction }) => string\n\nexport type SharpDependency = (\n input?:\n | ArrayBuffer\n | Buffer\n | Float32Array\n | Float64Array\n | Int8Array\n | Int16Array\n | Int32Array\n | Uint8Array\n | Uint8ClampedArray\n | Uint16Array\n | Uint32Array\n | string,\n options?: sharp.SharpOptions,\n) => sharp.Sharp\n\n/**\n * This is the central configuration\n *\n * @see https://payloadcms.com/docs/configuration/overview\n */\nexport type Config = {\n /** Configure admin dashboard */\n admin?: {\n /** Automatically log in as a user when visiting the admin dashboard. */\n autoLogin?:\n | {\n /**\n * The email address of the user to login as\n *\n */\n email: string\n /** The password of the user to login as */\n password: string\n /**\n * If set to true, the login credentials will be prefilled but the user will still need to click the login button.\n *\n * @default false\n */\n prefillOnly?: boolean\n }\n | false\n /** Set account profile picture. Options: gravatar, default or a custom React component. */\n avatar?: 'default' | 'gravatar' | React.ComponentType<any>\n\n /**\n * Add extra and/or replace built-in components with custom components\n *\n * @see https://payloadcms.com/docs/admin/components\n */\n components?: {\n /**\n * Replace the navigation with a custom component\n */\n Nav?: CustomComponent\n /**\n * Add custom components to the top right of the Admin Panel\n */\n actions?: CustomComponent[]\n /**\n * Add custom components after the collection overview\n */\n afterDashboard?: CustomComponent[]\n /**\n * Add custom components after the email/password field\n */\n afterLogin?: CustomComponent[]\n /**\n * Add custom components after the navigation links\n */\n afterNavLinks?: CustomComponent[]\n /**\n * Add custom components before the collection overview\n */\n beforeDashboard?: CustomComponent[]\n /**\n * Add custom components before the email/password field\n */\n beforeLogin?: CustomComponent[]\n /**\n * Add custom components before the navigation links\n */\n beforeNavLinks?: CustomComponent[]\n /** Replace graphical components */\n graphics?: {\n /** Replace the icon in the navigation */\n Icon?: CustomComponent\n /** Replace the logo on the login page */\n Logo?: CustomComponent\n }\n /** Replace logout related components */\n logout?: {\n /** Replace the logout button */\n Button?: CustomComponent\n }\n /**\n * Wrap the admin dashboard in custom context providers\n */\n providers?: React.ComponentType<{ children?: React.ReactNode }>[]\n /**\n * Replace or modify top-level admin routes, or add new ones:\n * + `Account` - `/admin/account`\n * + `Dashboard` - `/admin`\n * + `:path` - `/admin/:path`\n */\n views?: {\n /** Add custom admin views */\n [key: string]: AdminView\n /** Replace the account screen */\n Account?: AdminView\n /** Replace the admin homepage */\n Dashboard?: AdminView\n }\n }\n /** Extension point to add your custom data. Available in server and client. */\n custom?: Record<string, any>\n /** Global date format that will be used for all dates in the Admin panel. Any valid date-fns format pattern can be used. */\n dateFormat?: string\n /** If set to true, the entire Admin panel will be disabled. */\n disable?: boolean\n livePreview?: LivePreviewConfig & {\n collections?: string[]\n globals?: string[]\n }\n /** Base meta data to use for the Admin Panel. Included properties are titleSuffix, ogImage, and favicon. */\n meta?: MetaConfig\n routes?: {\n /** The route for the account page. */\n account?: string\n /** The route for the create first user page. */\n createFirstUser?: string\n /** The route for the forgot password page. */\n forgot?: string\n /** The route the user will be redirected to after being inactive for too long. */\n inactivity?: string\n /** The route for the login page. */\n login?: string\n /** The route for the logout page. */\n logout?: string\n /** The route for the reset password page. */\n reset?: string\n /** The route for the unauthorized page. */\n unauthorized?: string\n }\n /** The slug of a Collection that you want to be used to log in to the Admin dashboard. */\n user?: string\n }\n /** Custom Payload bin scripts can be injected via the config. */\n bin?: BinScriptConfig[]\n /**\n * Manage the datamodel of your application\n *\n * @see https://payloadcms.com/docs/configuration/collections#collection-configs\n */\n collections?: CollectionConfig[]\n /**\n * Replace the built-in components with custom ones\n */\n components?: { [key: string]: (() => JSX.Element) | JSX.Element }\n /**\n * Prefix a string to all cookies that Payload sets.\n *\n * @default \"payload\"\n */\n cookiePrefix?: string\n /** Either a whitelist array of URLS to allow CORS requests from, or a wildcard string ('*') to accept incoming requests from any domain. */\n cors?: '*' | string[]\n /** A whitelist array of URLs to allow Payload cookies to be accepted from as a form of CSRF protection. */\n csrf?: string[]\n\n /** Extension point to add your custom data. Server only. */\n custom?: Record<string, any>\n\n /** Pass in a database adapter for use on this project. */\n db: DatabaseAdapterResult\n /** Enable to expose more detailed error information. */\n debug?: boolean\n /**\n * If a user does not specify `depth` while requesting a resource, this depth will be used.\n *\n * @see https://payloadcms.com/docs/getting-started/concepts#depth\n *\n * @default 2\n */\n defaultDepth?: number\n /**\n * The maximum allowed depth to be permitted application-wide. This setting helps prevent against malicious queries.\n *\n * @default 40000\n */\n defaultMaxTextLength?: number\n /** Default richtext editor to use for richText fields */\n editor?: RichTextAdapterProvider<any, any, any>\n /**\n * Email Adapter\n *\n * @see https://payloadcms.com/docs/email/overview\n */\n email?: EmailAdapter | Promise<EmailAdapter>\n /** Custom REST endpoints */\n endpoints?: Endpoint[]\n /**\n * @see https://payloadcms.com/docs/configuration/globals#global-configs\n */\n globals?: GlobalConfig[]\n /**\n * Manage the GraphQL API\n *\n * You can add your own GraphQL queries and mutations to Payload, making use of all the types that Payload has defined for you.\n *\n * @see https://payloadcms.com/docs/graphql/overview\n */\n graphQL?: {\n disable?: boolean\n disablePlaygroundInProduction?: boolean\n maxComplexity?: number\n /**\n * Function that returns an object containing keys to custom GraphQL mutations\n *\n * @see https://payloadcms.com/docs/graphql/extending\n */\n mutations?: GraphQLExtension\n /**\n * Function that returns an object containing keys to custom GraphQL queries\n *\n * @see https://payloadcms.com/docs/graphql/extending\n */\n queries?: GraphQLExtension\n /**\n * Filepath to write the generated schema to\n */\n schemaOutputFile?: string\n }\n /**\n * Tap into Payload-wide hooks.\n *\n * @see https://payloadcms.com/docs/hooks/overview\n */\n hooks?: {\n afterError?: AfterErrorHook\n }\n /** i18n config settings */\n i18n?: I18nOptions<{} | DefaultTranslationsObject> // loosen the type here to allow for custom translations\n /** Automatically index all sortable top-level fields in the database to improve sort performance and add database compatibility for Azure Cosmos and similar. */\n indexSortableFields?: boolean\n /**\n * Translate your content to different languages/locales.\n *\n * @default false // disable localization\n */\n localization?: LocalizationConfig | false\n /**\n * The maximum allowed depth to be permitted application-wide. This setting helps prevent against malicious queries.\n *\n * @see https://payloadcms.com/docs/getting-started/concepts#depth\n *\n * @default 10\n */\n maxDepth?: number\n /** A function that is called immediately following startup that receives the Payload instance as its only argument. */\n onInit?: (payload: Payload) => Promise<void> | void\n /**\n * An array of Payload plugins.\n *\n * @see https://payloadcms.com/docs/plugins/overview\n */\n plugins?: Plugin[]\n /** Control the routing structure that Payload binds itself to. */\n routes?: {\n /** @default \"/admin\" */\n admin?: string\n /** @default \"/api\" */\n api?: string\n /** @default \"/graphql\" */\n graphQL?: string\n /** @default \"/graphql-playground\" */\n graphQLPlayground?: string\n }\n /** Secure string that Payload will use for any encryption workflows */\n secret: string\n /**\n * Define the absolute URL of your app including the protocol, for example `https://example.org`.\n * No paths allowed, only protocol, domain and (optionally) port.\n *\n * @see https://payloadcms.com/docs/configuration/overview#options\n */\n serverURL?: string\n /**\n * Pass in a local copy of Sharp if you'd like to use it.\n *\n */\n sharp?: SharpDependency\n /** Send anonymous telemetry data about general usage. */\n telemetry?: boolean\n /** Control how typescript interfaces are generated from your collections. */\n typescript?: {\n /**\n * Automatically generate types during development\n * @default true\n */\n autoGenerate?: boolean\n\n /** Disable declare block in generated types file */\n declare?:\n | {\n /**\n * @internal internal use only to allow for multiple declarations within a monorepo and suppress the \"Duplicate identifier GeneratedTypes\" error\n *\n * Adds a @ts-ignore flag above the GeneratedTypes interface declaration\n *\n * @default false\n */\n ignoreTSError?: boolean\n }\n | false\n\n /** Filename to write the generated types to */\n outputFile?: string\n }\n /**\n * Customize the handling of incoming file uploads for collections that have uploads enabled.\n */\n upload?: ExpressFileUploadOptions\n}\n\nexport type SanitizedConfig = Omit<\n DeepRequired<Config>,\n 'collections' | 'editor' | 'endpoint' | 'globals' | 'i18n' | 'localization' | 'upload'\n> & {\n collections: SanitizedCollectionConfig[]\n /** Default richtext editor to use for richText fields */\n editor?: RichTextAdapter<any, any, any>\n endpoints: Endpoint[]\n globals: SanitizedGlobalConfig[]\n i18n: Required<I18nOptions>\n localization: SanitizedLocalizationConfig | false\n paths: {\n config: string\n configDir: string\n rawConfig: string\n }\n upload: ExpressFileUploadOptions & {\n /**\n * Deduped list of adapters used in the project\n */\n adapters: string[]\n }\n}\n\nexport type EditConfig =\n | (\n | {\n /**\n * Replace or modify individual nested routes, or add new ones:\n * + `Default` - `/admin/collections/:collection/:id`\n * + `API` - `/admin/collections/:collection/:id/api`\n * + `LivePreview` - `/admin/collections/:collection/:id/preview`\n * + `References` - `/admin/collections/:collection/:id/references`\n * + `Relationships` - `/admin/collections/:collection/:id/relationships`\n * + `Versions` - `/admin/collections/:collection/:id/versions`\n * + `Version` - `/admin/collections/:collection/:id/versions/:version`\n * + `CustomView` - `/admin/collections/:collection/:id/:path`\n */\n API?: EditViewComponent | Partial<EditViewConfig>\n Default?: EditViewComponent | Partial<EditViewConfig>\n LivePreview?: EditViewComponent | Partial<EditViewConfig>\n Version?: EditViewComponent | Partial<EditViewConfig>\n Versions?: EditViewComponent | Partial<EditViewConfig>\n // TODO: uncomment these as they are built\n // References?: EditView\n // Relationships?: EditView\n }\n | {\n [key: string]: EditViewConfig\n }\n )\n | EditViewComponent\n\nexport type EntityDescriptionComponent = CustomComponent\n\nexport type EntityDescriptionFunction = ({ t }: { t: TFunction }) => string\n\nexport type EntityDescription = EntityDescriptionFunction | Record<string, string> | string\n\nexport type { EmailAdapter, SendEmailOptions }\n"],"names":["serverProps"],"rangeMappings":";;;;;;;;","mappings":"AAkVA,OAAO,MAAMA,cAAqC;IAChD;IACA;IACA;IACA;IACA;IACA;IACA;CACD,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "payload",
3
- "version": "3.0.0-beta.47",
3
+ "version": "3.0.0-beta.48",
4
4
  "description": "Node, React, Headless CMS and Application Framework built on Next.js",
5
5
  "keywords": [
6
6
  "admin panel",
@@ -94,7 +94,7 @@
94
94
  "scmp": "2.1.0",
95
95
  "ts-essentials": "7.0.3",
96
96
  "uuid": "^9.0.1",
97
- "@payloadcms/translations": "3.0.0-beta.47"
97
+ "@payloadcms/translations": "3.0.0-beta.48"
98
98
  },
99
99
  "devDependencies": {
100
100
  "@monaco-editor/react": "4.5.1",