mirror of
https://github.com/facebook/docusaurus.git
synced 2025-07-27 21:48:41 +02:00
fix(v2): sidebar_label should be used to compute next/previous button labels (#4970)
* sidebar_label should be used to compute next/previous button texts, as documented. * improve docs frontmatter doc * use a little bit of destructuring
This commit is contained in:
parent
aeb8e9da51
commit
737f80a026
8 changed files with 75 additions and 38 deletions
|
@ -11,21 +11,7 @@ import {
|
|||
JoiFrontMatter as Joi, // Custom instance for frontmatter
|
||||
validateFrontMatter,
|
||||
} from '@docusaurus/utils-validation';
|
||||
|
||||
export type DocFrontMatter = {
|
||||
id?: string;
|
||||
title?: string;
|
||||
hide_title?: boolean;
|
||||
hide_table_of_contents?: boolean;
|
||||
keywords?: string[];
|
||||
image?: string;
|
||||
description?: string;
|
||||
slug?: string;
|
||||
sidebar_label?: string;
|
||||
sidebar_position?: number;
|
||||
custom_edit_url?: string | null;
|
||||
parse_number_prefixes?: boolean;
|
||||
};
|
||||
import {DocFrontMatter} from './types';
|
||||
|
||||
// NOTE: we don't add any default value on purpose here
|
||||
// We don't want default values to magically appear in doc metadatas and props
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue