Skip to content

Commit

Permalink
Remove (required) from headings
Browse files Browse the repository at this point in the history
- Removed to ensure heading anchor links are stable over time
- Consistently display required properties throughout API references
  • Loading branch information
kylegach committed Jun 21, 2023
1 parent dde3e33 commit 320aed5
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 13 deletions.
12 changes: 9 additions & 3 deletions docs/api/doc-block-colorpalette.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,19 +66,25 @@ import { ColorItem } from '@storybook/blocks';

`ColorItem` is configured with the following props:

### `colors` (required)
### `colors`

(**Required**)

Type: `string[] | { [key: string]: string }`

Provides the list of colors to be displayed. Accepts any valid CSS color format (hex, RGB, HSL, etc.). When an object is provided, the keys will be displayed above the values.

### `subtitle` (required)
### `subtitle`

(**Required**)

Type: `string`

Provides an additional description of the color.

### `title` (required)
### `title`

(**Required**)

Type: `string`

Expand Down
4 changes: 3 additions & 1 deletion docs/api/doc-block-icongallery.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,9 @@ import { IconItem } from '@storybook/blocks';

`IconItem` is configured with the following props:

### `name` (required)
### `name`

(**Required**)

Type: `string`

Expand Down
4 changes: 3 additions & 1 deletion docs/api/doc-block-useof.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,9 @@ useOf = (

## Parameters

### `moduleExportOrType` (required)
### `moduleExportOrType`

(**Required**)

Type: `ModuleExport | 'story' | 'meta' | 'component'`

Expand Down
4 changes: 2 additions & 2 deletions docs/api/main-config-framework.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
title: 'framework'
---

(**Required**)

Parent: [main.js|ts configuration](./main-config.md)

Type: `FrameworkName | { name: FrameworkName; options?: FrameworkOptions }`

Required: `true`

Configures Storybook based on a set of [framework-specific](../configure/frameworks.md) settings.

<!-- prettier-ignore-start -->
Expand Down
8 changes: 4 additions & 4 deletions docs/api/main-config-stories.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
title: 'stories'
---

(**Required**)

Parent: [main.js|ts configuration](./main-config.md)

Type:
Expand All @@ -11,8 +13,6 @@ Type:
| async (list: (string | StoriesSpecifier)[]) => (string | StoriesSpecifier)[]
```

Required: `true`

Configures Storybook to load stories from the specified locations. The intention is for you to colocate a story file along with the component it documents:

```
Expand Down Expand Up @@ -91,9 +91,9 @@ Type:

#### `StoriesSpecifier.directory`

Type: `string`
(**Required**)

Required: `true`
Type: `string`

Where to start looking for story files, relative to the root of your project.

Expand Down
4 changes: 2 additions & 2 deletions docs/api/main-config.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ A typical Storybook configuration file looks like this:

An object to configure Storybook containing the following properties:

- [`framework`](./main-config-framework.md) (required)
- [`stories`](./main-config-stories.md) (required)
- [`framework`](./main-config-framework.md) (Required)
- [`stories`](./main-config-stories.md) (Required)
- [`addons`](./main-config-addons.md)
- [`babel`](./main-config-babel.md)
- [`babelDefault`](./main-config-babel-default.md)
Expand Down

0 comments on commit 320aed5

Please sign in to comment.