Skip to content

Commit 5e4e274

Browse files
authored
docs: fix links and formatting (#10346)
### What? This PR fixes numerous links across the docs, both internal docs links and external links. This PR also fixes some minor formatting issues in some places, as well as optically aligns the markdown tables in tables that had broken links. ### Why? To properly link readers to the correct location in the docs, and for better formatting and easier consumption. ### How? Changes to many `.mdx` files in the `docs` folder. Notes: - There are duplicative section id's in `docs/authentication/email.mdx`, I've fixed one such link, but have left it as is for now.
1 parent be84ad7 commit 5e4e274

25 files changed

+107
-121
lines changed

docs/access-control/collections.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -252,10 +252,10 @@ export const canDeleteCustomer: Access = async ({ req, id }) => {
252252

253253
The following arguments are provided to the `delete` function:
254254

255-
| Option | Description |
256-
| --------- | --------------------------------------------------------------------------------------------------- |
255+
| Option | Description |
256+
| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------ |
257257
| **`req`** | The [Request](https://developer.mozilla.org/en-US/docs/Web/API/Request) object with additional `user` property, which is the currently logged in user. |
258-
| **`id`** | `id` of document requested to delete.
258+
| **`id`** | `id` of document requested to delete. |
259259

260260
### Admin
261261

@@ -286,7 +286,7 @@ The following arguments are provided to the `admin` function:
286286

287287
### Unlock
288288

289-
Determines which users can [unlock](/docs/authentication/operations#unlock) other users who may be blocked from authenticating successfully due to [failing too many login attempts](/docs/authentication/overview#options).
289+
Determines which users can [unlock](/docs/authentication/operations#unlock) other users who may be blocked from authenticating successfully due to [failing too many login attempts](/docs/authentication/overview#config-options).
290290

291291
To add Unlock Access Control to a Collection, use the `unlock` property in the [Collection Config](../configuration/collections):
292292

docs/access-control/fields.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ desc: Field-level Access Control is specified within a field's config, and allow
66
keywords: fields, access control, permissions, documentation, Content Management System, cms, headless, javascript, node, react, nextjs
77
---
88

9-
Field Access Control is [Access Control](../overview) used to restrict access to specific [Fields](../fields/overview) within a Document.
9+
Field Access Control is [Access Control](../access-control/overview) used to restrict access to specific [Fields](../fields/overview) within a Document.
1010

1111
To add Access Control to a Field, use the `access` property in your [Field Config](../fields/overview):
1212

docs/access-control/globals.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ desc: Global-level Access Control is specified within each Global's `access` pro
66
keywords: globals, access control, permissions, documentation, Content Management System, cms, headless, javascript, node, react, nextjs
77
---
88

9-
Global Access Control is [Access Control](../overview) used to restrict access to [Global](../configuration/globals) Documents, as well as what they can and cannot see within the [Admin Panel](../admin/overview) as it relates to that Global.
9+
Global Access Control is [Access Control](../access-control/overview) used to restrict access to [Global](../configuration/globals) Documents, as well as what they can and cannot see within the [Admin Panel](../admin/overview) as it relates to that Global.
1010

1111
To add Access Control to a Global, use the `access` property in your [Global Config](../configuration/globals):
1212

docs/access-control/overview.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ There are three main types of Access Control in Payload:
2929

3030
## Default Access Control
3131

32-
Payload provides default Access Control so that your data is secured behind [Authentication](../authentication) without additional configuration. To do this, Payload sets a default function that simply checks if a user is present on the request. You can override this default behavior by defining your own Access Control functions as needed.
32+
Payload provides default Access Control so that your data is secured behind [Authentication](../authentication/overview) without additional configuration. To do this, Payload sets a default function that simply checks if a user is present on the request. You can override this default behavior by defining your own Access Control functions as needed.
3333

3434
Here is the default Access Control that Payload provides:
3535

docs/admin/components.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ The Import Map is automatically regenerated at startup and whenever Hot Module R
127127

128128
If needed, custom items can be appended onto the Import Map. This is mostly only relevant for plugin authors who need to add a custom import that is not referenced in a known location.
129129

130-
To add a custom import to the Import Map, use the `admin.dependencies` property in your [Payload Config](../getting-started/overview):
130+
To add a custom import to the Import Map, use the `admin.dependencies` property in your [Payload Config](../configuration/overview):
131131

132132
```ts
133133
import { buildConfig } from 'payload'
@@ -464,7 +464,7 @@ Payload also exports its [SCSS](https://sass-lang.com) library for reuse which i
464464

465465
Root Components are those that effect the [Admin Panel](./overview) generally, such as the logo or the main nav.
466466

467-
To override Root Components, use the `admin.components` property in your [Payload Config](../getting-started/overview):
467+
To override Root Components, use the `admin.components` property in your [Payload Config](../configuration/overview):
468468

469469
```ts
470470
import { buildConfig } from 'payload'

docs/admin/fields.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -399,7 +399,7 @@ import type {
399399

400400
### Description
401401

402-
Alternatively to the [Description Property](#the-description-property), you can also use a [Custom Component](./components) as the Field Description. This can be useful when you need to provide more complex feedback to the user, such as rendering dynamic field values or other interactive elements.
402+
Alternatively to the [Description Property](#field-descriptions), you can also use a [Custom Component](./components) as the Field Description. This can be useful when you need to provide more complex feedback to the user, such as rendering dynamic field values or other interactive elements.
403403

404404
To add a Description Component to a field, use the `admin.components.Description` property in your [Field Config](../fields/overview):
405405

docs/admin/overview.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Payload dynamically generates a beautiful, [fully type-safe](../typescript/overv
1010

1111
The Admin Panel is designed to [white-label your brand](https://payloadcms.com/blog/white-label-admin-ui). You can endlessly customize and extend the Admin UI by swapping in your own [Custom Components](./components)—everything from simple field labels to entire views can be modified or replaced to perfectly tailor the interface for your editors.
1212

13-
The Admin Panel is written in [TypeScript](https://www.typescriptlang.org) and built with [React](https://react.dev) using the [Next.js App Router](https://nextjs.org/docs/app). It supports [React Server Components](https://react.dev/reference/rsc/server-components), enabling the use of the [Local API](/docs/local-api/overview) on the front-end. You can install Payload into any [existing Next.js app in just one line](../getting-started/installation) and [deploy it anywhere](../production).
13+
The Admin Panel is written in [TypeScript](https://www.typescriptlang.org) and built with [React](https://react.dev) using the [Next.js App Router](https://nextjs.org/docs/app). It supports [React Server Components](https://react.dev/reference/rsc/server-components), enabling the use of the [Local API](/docs/local-api/overview) on the front-end. You can install Payload into any [existing Next.js app in just one line](../getting-started/installation) and [deploy it anywhere](../production/deployment).
1414

1515
<Banner type="success">
1616
The Payload Admin Panel is designed to be as minimal and straightforward as possible to allow easy customization and control. [Learn more](./components).

docs/admin/views.mdx

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ To swap in your own Custom View, first consult the list of available components,
2121

2222
Root Views are the main views of the [Admin Panel](./overview). These are views that are scoped directly under the `/admin` route, such as the Dashboard or Account views.
2323

24-
To swap Root Views with your own, or to [create entirely new ones](#adding-new-root-views), use the `admin.components.views` property of your root [Payload Config](../configuration/overview):
24+
To swap Root Views with your own, or to [create entirely new ones](#adding-new-views), use the `admin.components.views` property of your root [Payload Config](../configuration/overview):
2525

2626
```ts
2727
import { buildConfig } from 'payload'
@@ -248,7 +248,7 @@ The following options are available:
248248

249249
Document Views are views that are scoped under the `/collections/:collectionSlug/:id` or the `/globals/:globalSlug` route, such as the Edit View or the API View. All Document Views keep their overall structure across navigation changes, such as their title and tabs, and replace only the content below.
250250

251-
To swap out Document Views with your own, or to [create entirely new ones](#adding-new-document-views), use the `admin.components.views.Edit[key]` property in your [Collection Config](../collections/overview) or [Global Config](../configuration/globals):
251+
To swap out Document Views with your own, or to [create entirely new ones](#adding-new-views), use the `admin.components.views.Edit[key]` property in your [Collection Config](../collections/overview) or [Global Config](../configuration/globals):
252252

253253
```ts
254254
import type { SanitizedCollectionConfig } from 'payload'
@@ -278,14 +278,14 @@ _For details on how to build Custom Views, including all available props, see [B
278278

279279
The following options are available:
280280

281-
| Property | Description |
282-
| ----------------- | --------------------------------------------------------------------------------------------------------------------------- |
283-
| **`root`** | The Root View overrides all other nested views and routes. No document controls or tabs are rendered when this key is set. |
284-
| **`default`** | The Default View is the primary view in which your document is edited. It is rendered within the "Edit" tab. |
285-
| **`versions`** | The Versions View is used to navigate the version history of a single document. It is rendered within the "Versions" tab. [More details](../versions). |
286-
| **`version`** | The Version View is used to edit a single version of a document. It is rendered within the "Version" tab. [More details](../versions). |
287-
| **`api`** | The API View is used to display the REST API JSON response for a given document. It is rendered within the "API" tab. |
288-
| **`livePreview`** | The LivePreview view is used to display the Live Preview interface. It is rendered within the "Live Preview" tab. [More details](../live-preview). |
281+
| Property | Description |
282+
| ----------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------- |
283+
| **`root`** | The Root View overrides all other nested views and routes. No document controls or tabs are rendered when this key is set. |
284+
| **`default`** | The Default View is the primary view in which your document is edited. It is rendered within the "Edit" tab. |
285+
| **`versions`** | The Versions View is used to navigate the version history of a single document. It is rendered within the "Versions" tab. [More details](../versions/overview). |
286+
| **`version`** | The Version View is used to edit a single version of a document. It is rendered within the "Version" tab. [More details](../versions/overview). |
287+
| **`api`** | The API View is used to display the REST API JSON response for a given document. It is rendered within the "API" tab. |
288+
| **`livePreview`** | The LivePreview view is used to display the Live Preview interface. It is rendered within the "Live Preview" tab. [More details](../live-preview/overview). |
289289

290290
### Document Tabs
291291

@@ -354,14 +354,14 @@ export const MyCollectionConfig: SanitizedCollectionConfig = {
354354

355355
Your Custom Views will be provided with the following props:
356356

357-
| Prop | Description |
358-
| ------------------------- | -------------------------------------------------------------------------------------------------------------------------------------- |
359-
| **`initPageResult`** | An object containing `req`, `payload`, `permissions`, etc. |
360-
| **`clientConfig`** | The Client Config object. [More details](../components#accessing-the-payload-config). |
361-
| **`importMap`** | The import map object. |
362-
| **`params`** | An object containing the [Dynamic Route Parameters](https://nextjs.org/docs/app/building-your-application/routing/dynamic-routes). |
363-
| **`searchParams`** | An object containing the [Search Parameters](https://developer.mozilla.org/docs/Learn/Common_questions/What_is_a_URL#parameters). |
364-
| **`doc`** | The document being edited. Only available in Document Views. [More details](#document-views). |
357+
| Prop | Description |
358+
| ------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- |
359+
| **`initPageResult`** | An object containing `req`, `payload`, `permissions`, etc. |
360+
| **`clientConfig`** | The Client Config object. [More details](../admin/components#accessing-the-payload-config). |
361+
| **`importMap`** | The import map object. |
362+
| **`params`** | An object containing the [Dynamic Route Parameters](https://nextjs.org/docs/app/building-your-application/routing/dynamic-routes). |
363+
| **`searchParams`** | An object containing the [Search Parameters](https://developer.mozilla.org/docs/Learn/Common_questions/What_is_a_URL#parameters). |
364+
| **`doc`** | The document being edited. Only available in Document Views. [More details](#document-views). |
365365

366366
<Banner type="success">
367367
**Reminder:**

docs/authentication/api-keys.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ For example, if you have a third-party service or external app that needs to be
1515

1616
<Banner type="success">
1717
**Tip:**
18-
<br/>
18+
1919
This is particularly useful as you can create a "user" that reflects an integration with a specific external service and assign a "role" or specific access only needed by that service/integration.
2020
</Banner>
2121

docs/authentication/email.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,14 @@ export const Customers: CollectionConfig = {
2727

2828
<Banner type="info">
2929
**Tip:**
30-
Verification emails are fully customizable. [More details](#generateEmailHTML).
30+
Verification emails are fully customizable. [More details](#generateemailhtml).
3131
</Banner>
3232

3333
The following options are available:
3434

35-
| Option | Description |
36-
|----------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
37-
| **`generateEmailHTML`** | Allows for overriding the HTML within emails that are sent to users indicating how to validate their account. [More details](#generateemailhtml). |
35+
| Option | Description |
36+
| -------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
37+
| **`generateEmailHTML`** | Allows for overriding the HTML within emails that are sent to users indicating how to validate their account. [More details](#generateemailhtml). |
3838
| **`generateEmailSubject`** | Allows for overriding the subject of the email that is sent to users indicating how to validate their account. [More details](#generateemailsubject). |
3939

4040
#### generateEmailHTML

0 commit comments

Comments
 (0)