Skip to content

Commit

Permalink
chore(packages): regenerate docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Xunnamius committed Nov 28, 2023
1 parent 7833113 commit 76dd6cb
Show file tree
Hide file tree
Showing 15 changed files with 113 additions and 111 deletions.
34 changes: 17 additions & 17 deletions packages/mdast-util-hidden/docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,21 +28,21 @@ Returns a new `Hidden` node ready to be inserted into a mdast tree.

| Name | Type |
| :------ | :------ |
| `children` | `Content`[] |
| `children` | `RootContent`[] |

#### Returns

[`Hidden`](interfaces/Hidden.md)

#### Defined in

[packages/mdast-util-hidden/src/index.ts:23](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/mdast-util-hidden/src/index.ts#L23)
[packages/mdast-util-hidden/src/index.ts:30](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/mdast-util-hidden/src/index.ts#L30)

___

### hide

**hide**<`Nodes`\>(`«destructured»`): `void`
**hide**\<`Nodes`\>(`«destructured»`): `void`

Inserts a `Hidden` node as a child of `parent` at `index`. Any `nodes` passed
in will become the hidden children of this new node.
Expand All @@ -51,7 +51,7 @@ in will become the hidden children of this new node.

| Name | Type |
| :------ | :------ |
| `Nodes` | extends `Content`[] |
| `Nodes` | extends `RootContent`[] |

#### Parameters

Expand All @@ -60,16 +60,16 @@ in will become the hidden children of this new node.
| `«destructured»` | `Object` | - |
| › `index` | `number` | - |
| › `nodes` | `Nodes` | - |
| › `parent` | `Parent`<`Node`<`Data`\>, `Data`\> | - |
| › `replaceChildAtIndex?` | `boolean` | If `replaceChildAtIndex` is `true`, the child node of `parent` at `index` will be replaced by the new `Hidden` node. On the other hand, if `replaceChildAtIndex` is `false`, this function will not remove any nodes from `parent`. In this case, if you do not manually remove the node at `index`, **you must skip two nodes ahead instead of just one when using a visitor or risk an infinite loop!** **`Default`** true **`Example`** ```typescript visit(tree, 'heading', (node, index, parent) => { if (index !== null && parent !== null) { hide({ nodes: [node], index, parent, replaceChildAtIndex: false }); return [SKIP, index + 2]; // <- +2 here is IMPORTANT } }); ``` |
| › `parent` | `Parent` | - |
| › `replaceChildAtIndex?` | `boolean` | If `replaceChildAtIndex` is `true`, the child node of `parent` at `index` will be replaced by the new `Hidden` node. On the other hand, if `replaceChildAtIndex` is `false`, this function will not remove any nodes from `parent`. In this case, if you do not manually remove the node at `index`, **you must skip two nodes ahead instead of just one when using a visitor or risk an infinite loop!** **`Default`** ```ts true ``` **`Example`** ```typescript visit(tree, 'heading', (node, index, parent) => { if (index !== undefined && parent !== undefined) { hide({ nodes: [node], index, parent, replaceChildAtIndex: false }); return [SKIP, index + 2]; // <- +2 here is IMPORTANT } }); ``` |

#### Returns

`void`

#### Defined in

[packages/mdast-util-hidden/src/index.ts:42](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/mdast-util-hidden/src/index.ts#L42)
[packages/mdast-util-hidden/src/index.ts:49](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/mdast-util-hidden/src/index.ts#L49)

___

Expand All @@ -84,21 +84,21 @@ instance.

| Name | Type |
| :------ | :------ |
| `node` | `Node`<`Data`\> |
| `node` | `Node` |

#### Returns

node is Hidden

#### Defined in

[packages/mdast-util-hidden/src/index.ts:34](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/mdast-util-hidden/src/index.ts#L34)
[packages/mdast-util-hidden/src/index.ts:41](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/mdast-util-hidden/src/index.ts#L41)

___

### reveal

**reveal**<`Nodes`\>(`«destructured»`): `void`
**reveal**\<`Nodes`\>(`«destructured»`): `void`

Replaces the child node of `parent` at `index` with the hidden children of
one or more `Hidden` `nodes`.
Expand All @@ -116,21 +116,21 @@ one or more `Hidden` `nodes`.
| `«destructured»` | `Object` |
| › `index` | `number` |
| › `nodes` | `Nodes` |
| › `parent` | `Parent`<`Node`<`Data`\>, `Data`\> |
| › `parent` | `Parent` |

#### Returns

`void`

#### Defined in

[packages/mdast-util-hidden/src/index.ts:85](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/mdast-util-hidden/src/index.ts#L85)
[packages/mdast-util-hidden/src/index.ts:92](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/mdast-util-hidden/src/index.ts#L92)

___

### visitAndReveal

**visitAndReveal**<`Tree`\>(`«destructured»`): `void`
**visitAndReveal**\<`Tree`\>(`«destructured»`): `void`

Walks `tree` using unist-util-visit to search for any `Hidden` nodes. Upon
encountering a `Hidden` node, `visitor` is called if provided.
Expand All @@ -147,21 +147,21 @@ instead.

| Name | Type |
| :------ | :------ |
| `Tree` | extends `Node`<`Data`, `Tree`\> |
| `Tree` | extends `Node` |

#### Parameters

| Name | Type | Description |
| :------ | :------ | :------ |
| `«destructured»` | `Object` | - |
| › `reverse?` | `boolean` | **`See`** https://github.com/syntax-tree/unist-util-visit#visittree-test-visitor-reverse **`Default`** false |
| › `reverse?` | `boolean` | **`See`** https://github.com/syntax-tree/unist-util-visit#visittree-test-visitor-reverse **`Default`** ```ts false ``` |
| › `tree` | `Tree` | **`See`** https://github.com/syntax-tree/unist-util-visit#visittree-test-visitor-reverse |
| › `visitor?` | `Visitor`<`Node`<`Data`\>, `Parent`<`Node`<`Data`\>, `Data`\>\> | If `visitor` is provided but returns `false`, `reveal` is not called and the hidden is not revealed. Otherwise, `reveal` will always be called. If `visitor` is provided and returns a defined value other than `false`, that value will be passed through to unist-util-visit. If `visitor` is not provided, or it returns `undefined`, `[SKIP, index]` will be passed through instead. |
| › `visitor?` | `Visitor` | If `visitor` is provided but returns `false`, `reveal` is not called and the hidden is not revealed. Otherwise, `reveal` will always be called. If `visitor` is provided and returns a defined value other than `false`, that value will be passed through to unist-util-visit. If `visitor` is not provided, or it returns `undefined`, `[SKIP, index]` will be passed through instead. |

#### Returns

`void`

#### Defined in

[packages/mdast-util-hidden/src/index.ts:113](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/mdast-util-hidden/src/index.ts#L113)
[packages/mdast-util-hidden/src/index.ts:125](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/mdast-util-hidden/src/index.ts#L125)
18 changes: 10 additions & 8 deletions packages/mdast-util-hidden/docs/interfaces/Hidden.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,42 +29,44 @@ cannot be derived from markdown directly.

`Optional` **data**: `Data`

Information from the ecosystem.
Info from the ecosystem.

#### Inherited from

Node.data

#### Defined in

node_modules/@types/unist/index.d.ts:27
node_modules/@types/unist/index.d.ts:95

___

### hiddenChildren

**hiddenChildren**: `Content`[]
**hiddenChildren**: `RootContent`[]

#### Defined in

[packages/mdast-util-hidden/src/index.ts:17](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/mdast-util-hidden/src/index.ts#L17)
[packages/mdast-util-hidden/src/index.ts:17](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/mdast-util-hidden/src/index.ts#L17)

___

### position

`Optional` **position**: `Position`

Location of a node in a source document.
Must not be present if a node is generated.
Position of a node in a source document.

Nodes that are generated (not in the original source document) must not
have a position.

#### Inherited from

Node.position

#### Defined in

node_modules/@types/unist/index.d.ts:33
node_modules/@types/unist/index.d.ts:103

___

Expand All @@ -78,4 +80,4 @@ Node.type

#### Defined in

[packages/mdast-util-hidden/src/index.ts:16](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/mdast-util-hidden/src/index.ts#L16)
[packages/mdast-util-hidden/src/index.ts:16](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/mdast-util-hidden/src/index.ts#L16)
2 changes: 1 addition & 1 deletion packages/mdast-util-tight-comments/docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ HTML comments and select other mdast nodes under certain conditions.

#### Defined in

[index.ts:7](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/mdast-util-tight-comments/src/index.ts#L7)
[index.ts:7](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/mdast-util-tight-comments/src/index.ts#L7)
18 changes: 9 additions & 9 deletions packages/remark-capitalize-headings/docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,19 @@ Options type for the remark-remove-url-trailing-slash plugin.

| Name | Type | Description |
| :------ | :------ | :------ |
| `excludeHeadingLevel?` | { [level in "h1" \| "h2" \| "h3" \| "h4" \| "h5" \| "h6"]?: boolean } | Headings of the specified `level` in `{ [level]: true }` will be excluded from capitalization entirely, where `h1` corresponds to `<h1>…</h1>`/`# …`, `h2` to `<h2>…</h2>`/`## …`, etc. > Excludes with `false` values are treated as if they were commented out. **`Default`** |
| `excludeSectionRegExp?` | (`string` \| `RegExp`)[] | Entire sections with a stringified heading matching at least one of the given regular expression strings will be excluded from capitalization entirely. **`Default`** [] |
| `replaceHeadingRegExp?` | { `[regExp: string]`: `string`; } | This option lets you manipulate non-excluded headers in their stringified form _after they've been transformed by title_ by leveraging mdast position data. This extra context is useful for tasks like capitalizing a word only if it appears at the end of a heading, or as part of a phrase, or to prevent a word from being capitalized. This option also supports using matching groups in during replacement. **`Default`** |
| `excludeHeadingLevel?` | \{ [level in "h1" \| "h2" \| "h3" \| "h4" \| "h5" \| "h6"]?: boolean } | Headings of the specified `level` in `{ [level]: true }` will be excluded from capitalization entirely, where `h1` corresponds to `<h1>…</h1>`/`# …`, `h2` to `<h2>…</h2>`/`## …`, etc. > Excludes with `false` values are treated as if they were commented out. **`Default`** ```ts {} ``` |
| `excludeSectionRegExp?` | (`string` \| `RegExp`)[] | Entire sections with a stringified heading matching at least one of the given regular expression strings will be excluded from capitalization entirely. **`Default`** ```ts [] ``` |
| `replaceHeadingRegExp?` | \{ `[regExp: string]`: `string`; } | This option lets you manipulate non-excluded headers in their stringified form _after they've been transformed by title_ by leveraging mdast position data. This extra context is useful for tasks like capitalizing a word only if it appears at the end of a heading, or as part of a phrase, or to prevent a word from being capitalized. This option also supports using matching groups in during replacement. **`Default`** ```ts { "(?<=\\s)a(?=\\p{P})": "A" } ``` |

#### Defined in

[packages/remark-capitalize-headings/src/index.ts:12](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/remark-capitalize-headings/src/index.ts#L12)
[packages/remark-capitalize-headings/src/index.ts:12](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/remark-capitalize-headings/src/index.ts#L12)

## Functions

### default

**default**(`this`, `...settings`): `void` \| `Transformer`<`Root`, `Root`\>
**default**(`this`, `...parameters`): `undefined` \| `void` \| `Transformer`\<`Root`, `Root`\>

A remark plugin that takes a Root node as input and returns the same node
with all heading nodes capitalized using Vercel's `title` package.
Expand All @@ -45,13 +45,13 @@ with all heading nodes capitalized using Vercel's `title` package.

| Name | Type |
| :------ | :------ |
| `this` | `Processor`<`void`, `Root`, `void`, `void`\> |
| `...settings` | [options: Options] \| `void`[] |
| `this` | `Processor`\<`undefined`, `undefined`, `undefined`, `undefined`, `undefined`\> |
| `...parameters` | [options: Options] \| `void`[] |

#### Returns

`void` \| `Transformer`<`Root`, `Root`\>
`undefined` \| `void` \| `Transformer`\<`Root`, `Root`\>

#### Defined in

node_modules/unified/index.d.ts:531
node_modules/unified/lib/index.d.ts:946
12 changes: 6 additions & 6 deletions packages/remark-ignore/docs/modules/end.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

### default

**default**(`this`, `...settings`): `void` \| `Transformer`<`Root`, `Root`\>
**default**(`this`, `...parameters`): `undefined` \| `void` \| `Transformer`\<`Root`, `Root`\>

A remark plugin that takes a Root node as input and returns the same node
with all hidden child nodes revealed.
Expand All @@ -22,16 +22,16 @@ with all hidden child nodes revealed.

| Name | Type |
| :------ | :------ |
| `this` | `Processor`<`void`, `Root`, `void`, `void`\> |
| `...settings` | `void`[] |
| `this` | `Processor`\<`undefined`, `undefined`, `undefined`, `undefined`, `undefined`\> |
| `...parameters` | `void`[] |

#### Returns

`void` \| `Transformer`<`Root`, `Root`\>
`undefined` \| `void` \| `Transformer`\<`Root`, `Root`\>

#### Defined in

node_modules/unified/index.d.ts:531
node_modules/unified/lib/index.d.ts:946

___

Expand All @@ -54,4 +54,4 @@ node with all hidden child nodes revealed.

#### Defined in

[packages/remark-ignore/src/end.ts:18](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/remark-ignore/src/end.ts#L18)
[packages/remark-ignore/src/end.ts:18](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/remark-ignore/src/end.ts#L18)
10 changes: 5 additions & 5 deletions packages/remark-ignore/docs/modules/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Renames and re-exports [default](start.md#default)

### default

**default**(`this`, `...settings`): `void` \| `Transformer`<`Root`, `Root`\>
**default**(`this`, `...parameters`): `undefined` \| `void` \| `Transformer`\<`Root`, `Root`\>

A remark plugin that takes a Root node as input and returns the same node
with all child nodes following an ignore command having been hidden. After
Expand All @@ -43,13 +43,13 @@ from other plugins until said nodes are revealed.

| Name | Type |
| :------ | :------ |
| `this` | `Processor`<`void`, `Root`, `void`, `void`\> |
| `...settings` | `void`[] |
| `this` | `Processor`\<`undefined`, `undefined`, `undefined`, `undefined`, `undefined`\> |
| `...parameters` | `void`[] |

#### Returns

`void` \| `Transformer`<`Root`, `Root`\>
`undefined` \| `void` \| `Transformer`\<`Root`, `Root`\>

#### Defined in

node_modules/unified/index.d.ts:531
node_modules/unified/lib/index.d.ts:946
12 changes: 6 additions & 6 deletions packages/remark-ignore/docs/modules/start.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

### default

**default**(`this`, `...settings`): `void` \| `Transformer`<`Root`, `Root`\>
**default**(`this`, `...parameters`): `undefined` \| `void` \| `Transformer`\<`Root`, `Root`\>

A remark plugin that takes a Root node as input and returns the same node
with all child nodes following an ignore command having been hidden.
Expand All @@ -25,16 +25,16 @@ from other plugins until said nodes are revealed.

| Name | Type |
| :------ | :------ |
| `this` | `Processor`<`void`, `Root`, `void`, `void`\> |
| `...settings` | `void`[] |
| `this` | `Processor`\<`undefined`, `undefined`, `undefined`, `undefined`, `undefined`\> |
| `...parameters` | `void`[] |

#### Returns

`void` \| `Transformer`<`Root`, `Root`\>
`undefined` \| `void` \| `Transformer`\<`Root`, `Root`\>

#### Defined in

node_modules/unified/index.d.ts:531
node_modules/unified/lib/index.d.ts:946

___

Expand All @@ -57,4 +57,4 @@ node with all child nodes following an ignore command having been hidden.

#### Defined in

[packages/remark-ignore/src/start.ts:23](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/remark-ignore/src/start.ts#L23)
[packages/remark-ignore/src/start.ts:23](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/remark-ignore/src/start.ts#L23)
16 changes: 8 additions & 8 deletions packages/remark-lint-fenced-code-flag-case/docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,11 @@ Options type for the remark-lint-fenced-code-flag-case plugin.

| Name | Type | Description |
| :------ | :------ | :------ |
| `case?` | typeof [`optionsCases`](README.md#optionscases)[`number`] | All code fence flags must be of the specified case. Code fences without flags are ignored. **`Default`** "lower" |
| `case?` | typeof [`optionsCases`](README.md#optionscases)[`number`] | All code fence flags must be of the specified case. Code fences without flags are ignored. **`Default`** ```ts "lower" ``` |

#### Defined in

[packages/remark-lint-fenced-code-flag-case/src/index.ts:17](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/remark-lint-fenced-code-flag-case/src/index.ts#L17)
[packages/remark-lint-fenced-code-flag-case/src/index.ts:18](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/remark-lint-fenced-code-flag-case/src/index.ts#L18)

## Variables

Expand All @@ -44,13 +44,13 @@ Valid values for the Options.case property.

#### Defined in

[packages/remark-lint-fenced-code-flag-case/src/index.ts:12](https://github.com/Xunnamius/unified-utils/blob/1d6f92d/packages/remark-lint-fenced-code-flag-case/src/index.ts#L12)
[packages/remark-lint-fenced-code-flag-case/src/index.ts:13](https://github.com/Xunnamius/unified-utils/blob/7833113/packages/remark-lint-fenced-code-flag-case/src/index.ts#L13)

## Functions

### default

**default**(`this`, `...settings`): `void` \| `Transformer`<`Node`<`Data`\>, `Node`<`Data`\>\>
**default**(`this`, `...parameters`): `undefined` \| `void` \| `Transformer`\<`Node`, `Node`\>

A remark-lint rule that takes a Root node as input and attaches any error
messages to the resulting virtual file pertaining to fenced code flag case.
Expand All @@ -59,13 +59,13 @@ messages to the resulting virtual file pertaining to fenced code flag case.

| Name | Type |
| :------ | :------ |
| `this` | `Processor`<`void`, `Node`<`Data`\>, `void`, `void`\> |
| `...settings` | `void`[] \| [`unknown`] \| [`boolean` \| `Label` \| `Severity`, `unknown`] |
| `this` | `Processor`\<`undefined`, `undefined`, `undefined`, `undefined`, `undefined`\> |
| `...parameters` | [[`Options`](README.md#options)] \| [] |

#### Returns

`void` \| `Transformer`<`Node`<`Data`\>, `Node`<`Data`\>\>
`undefined` \| `void` \| `Transformer`\<`Node`, `Node`\>

#### Defined in

node_modules/unified/index.d.ts:531
node_modules/unified/lib/index.d.ts:946
Loading

0 comments on commit 76dd6cb

Please sign in to comment.