Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: new og images config #278

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added images/default-og-image.webp
Binary file not shown.
Binary file added images/og-image-gradient.webp
Binary file not shown.
Binary file added images/og-image-grid.webp
Binary file not shown.
Binary file added images/og-image-lights.webp
Binary file not shown.
Binary file added images/og-image-none.webp
Binary file not shown.
Binary file added images/og-image-solid.webp
Binary file not shown.
54 changes: 53 additions & 1 deletion settings/global.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -550,14 +550,66 @@ Example:
}
```

<Expandable title="Redirect">
<Expandable title="SEO">
<ResponseField name="indexHiddenPages" type="boolean" default="false">
Enables indexing pages not included in `navigation`.
</ResponseField>

</Expandable>
</ResponseField>


### Open Graph Image

Configure the Open Graph image that is displayed when you share your site on social media such as X and in chats such as Slack.

<Frame>
<img src="images/default-og-image.webp" />
</Frame>

<Expandable title="OgImage">
<ResponseField name="mode" type='"light" | "dark"'>
The color theme of the OG image. Default to `modeToggle` setting. If it is not set, it will be determined based on the color luminosity of your primary color.
</ResponseField>
<ResponseField name="logo" type="boolean" default={true}>
Whether to include the logo in the OG image.
</ResponseField>
<ResponseField name="header" type="boolean" default={true}>
Whether to include the header in the OG image.
</ResponseField>
<ResponseField name="title" type="boolean" default={true}>
Whether to include the title in the OG image.
</ResponseField>
<ResponseField name="description" type="boolean" default={true}>
Whether to include the page description in the OG image.
</ResponseField>
<ResponseField name="backgroundStyle" type='"grid" | "none" | "gradient" | "lights" | "solid' default='grid'>
The style of the background.
<Expandable title="Background style examples">
`grid`
<Frame>
<img src="images/og-image-grid.webp" />
</Frame>
`none`
<Frame>
<img src="images/og-image-none.webp" />
</Frame>
`gradient`
<Frame>
<img src="images/og-image-gradient.webp" />
</Frame>
`lights`
<Frame>
<img src="images/og-image-lights.webp" />
</Frame>
`solid`
<Frame>
<img src="images/og-image-solid.webp" />
</Frame>
</Expandable>
</ResponseField>
</Expandable>

## Example `mint.json`

Click on the following dropdown to view a sample configuration file
Expand Down