Skip to content

Commit

Permalink
docs: fix broken links
Browse files Browse the repository at this point in the history
  • Loading branch information
notunderctrl committed Feb 3, 2024
1 parent a99adb3 commit bb3ad39
Show file tree
Hide file tree
Showing 10 changed files with 16 additions and 12 deletions.
2 changes: 1 addition & 1 deletion apps/docs/pages/docs/classes/CommandKit.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

### `commands`

- Type: [`CommandObject[]`](/typedef/CommandObject)
- Type: [`CommandObject[]`](/docs/typedef/CommandObject)

An array of all the command objects that CommandKit is handling. This includes all the properties and methods that are also set outside of CommandKit's configuration. It does however not include the `run` method since CommandKit handles that internally.

Expand Down
10 changes: 7 additions & 3 deletions apps/docs/pages/docs/classes/components/ButtonKit.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { Callout } from 'nextra/components';

<Callout type="info">
ButtonKit extends the
[ButtonBuilder](https://discord.js.org/docs/packages/discord.js/main/ButtonBuilder:Class)
[`ButtonBuilder`](https://discord.js.org/docs/packages/discord.js/main/ButtonBuilder:Class)
class, provided by discord.js.
</Callout>

Expand Down Expand Up @@ -40,10 +40,14 @@ button.onClick(
);

// Remove onClick handler and destroy the interaction collector
button.onClick(null);
button.dispose();
```

### onEnd
### `onEnd`

- Return type: `ButtonKit`
- Props type: [`CommandKitButtonBuilderOnEnd`](/docs/typedef/CommandKitButtonBuilderOnEnd)

### `dispose`

- Return type: `void`
2 changes: 1 addition & 1 deletion apps/docs/pages/docs/typedef/AutocompleteProps.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

### `handler`

- Type: [`CommandKit`](/docs/typedef/CommandKit)
- Type: [`CommandKit`](/docs/classes/CommandKit)

### `interaction`

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Extends `Omit<InteractionCollectorOptions<ButtonInteraction>, 'filter' | 'compon

The message to listen for button interactions on.

- Type: [Message](https://discord.js.org/docs/packages/discord.js/main/Message:Class)
- Type: [`Message`](https://discord.js.org/docs/packages/discord.js/main/Message:Class)

### `time`

Expand Down
2 changes: 1 addition & 1 deletion apps/docs/pages/docs/typedef/ContextMenuCommandProps.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

### `handler`

- Type: [`CommandKit`](/docs/typedef/CommandKit)
- Type: [`CommandKit`](/docs/classes/CommandKit)

### `interaction`

Expand Down
2 changes: 1 addition & 1 deletion apps/docs/pages/docs/typedef/SlashCommandProps.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

### `handler`

- Type: [`CommandKit`](/typedef/CommandKit)
- Type: [`CommandKit`](/docs/classes/CommandKit)

### `interaction`

Expand Down
2 changes: 1 addition & 1 deletion apps/docs/pages/docs/typedef/ValidationProps.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

### `handler`

- Type: [`CommandKit`](/docs/typedef/CommandKit)
- Type: [`CommandKit`](/docs/classes/CommandKit)

### `interaction`

Expand Down
2 changes: 1 addition & 1 deletion apps/docs/pages/guide/buttonkit.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ Whether or not the collector should automatically reset the timer when a button

## Handle collector end

When setting up an `onClick()` method using ButtonKit, you may also want to run some code after the collector ends running. The default timeout is 1 day, but you can modify this in [onClickOptions#time](/guide/buttonkit#time-optional). To handle when the collector ends, you can setup an `onEnd()` method like this:
When setting up an `onClick()` method using ButtonKit, you may also want to run some code after the collector ends running. The default timeout is 1 day, but you can modify this in [`onClickOptions#time`](/guide/buttonkit#time-optional). To handle when the collector ends, you can setup an `onEnd()` method like this:

```js copy {16-21}
const myButton = new ButtonKit()
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/pages/guide/commandkit-setup.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -165,4 +165,4 @@ This is used to disable CommandKit's built-in validation functions. Setting this
- Type: `boolean`
- Default: `false`
This is used to change the behaviour of how CommandKit loads application commands. By default it's one-by-one while comparing changes. Setting this option to `true` will load application commands all at once on every restart, and when [`reloadCommands()`](/docs/typedef/CommandKit#reloadcommands) is called.
This is used to change the behaviour of how CommandKit loads application commands. By default it's one-by-one while comparing changes. Setting this option to `true` will load application commands all at once on every restart, and when [`reloadCommands()`](/docs/classes/CommandKit#reloadcommands) is called.
2 changes: 1 addition & 1 deletion apps/docs/pages/guide/create-commandkit.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ When running create-commandkit, you should be asked the following questions:

- **Package Manager:** Lets you choose which package manager to use — npm, pnpm, or Yarn.

- **Language ([Development version](/guide/installation#development-version) only):** The language to use for your project — JavaScript or TypeScript.
- **Language ([Development version](/guide/create-commandkit#development-version) only):** The language to use for your project — JavaScript or TypeScript.

- **Module Type:** Allows you to pick between CommonJS (using require and module.exports), and ESM (using import and export).

Expand Down

0 comments on commit bb3ad39

Please sign in to comment.