# Bottom Buttons (Bottom)

`Bottom` The interactive button area at the bottom of the node definition menu; there are three layout modes.

***

## Configuration structure

```yaml
Bottom:
  type: 'mode type'   # notice | confirmation | multi
  # mode-specific configuration...
```

***

## Three layout modes

### notice - single-button mode

Only one confirm button is shown, suitable for information display or simple trigger actions.

**Configuration items:**

| Field             | Description                                             |
| ----------------- | ------------------------------------------------------- |
| `confirm.text`    | Button text, supports color codes and conditional logic |
| `confirm.width`   | Optional, button width (1-1024)                         |
| `confirm.actions` | List of actions executed when clicked                   |

**Example:**

```yaml
Bottom:
  type: 'notice'
  confirm:
    text: '&a[ Claim Reward ]'
    actions:
      - 'console: give %player_name% diamond 1'
      - 'tell: &aYou have claimed the diamond!'
      - 'sound: entity.player.levelup'
```

***

### confirmation - confirm/cancel dual-button mode

Shows two buttons, confirm and cancel, suitable for risky actions that require a second confirmation.

**Configuration items:**

| Field             | Description                                     |
| ----------------- | ----------------------------------------------- |
| `confirm.text`    | Confirm button text, supports conditional logic |
| `confirm.width`   | Optional, confirm button width (1-1024)         |
| `confirm.actions` | List of actions executed when confirming        |
| `deny.text`       | Cancel button text, supports conditional logic  |
| `deny.width`      | Optional, cancel button width (1-1024)          |
| `deny.actions`    | List of actions executed when canceling         |

**Example:**

```yaml
Bottom:
  type: 'confirmation'
  confirm:
    text: '&a[ Confirm Purchase ]'
    actions:
      - 'console: eco take %player_name% 100'
      - 'console: give %player_name% diamond_sword 1'
      - 'tell: &aPurchase successful!'
      - 'sound: entity.experience_orb.pickup'
  deny:
    text: '&c[ Cancel ]'
    actions:
      - 'tell: &7Purchase canceled.'
      - 'sound: block.note_block.bass'
```

***

### multi - multi-button matrix mode

Supports multiple custom buttons arranged in a matrix, and can additionally configure an exit button.

**Configuration items:**

| Field     | Type  | Default value | Description                                                     |
| --------- | ----- | ------------- | --------------------------------------------------------------- |
| `columns` | `Int` | `2`           | Number of button columns displayed per row                      |
| `buttons` | node  | —             | Button list (arranged in YAML order)                            |
| `exit`    | node  | —             | Optional exit/back button (shown at the end of the button list) |

**Button configuration items:**

| Field            | Type        | Description                                                                                  |
| ---------------- | ----------- | -------------------------------------------------------------------------------------------- |
| `show-condition` | String      | Optional, button display condition; the button will not be shown if the condition is not met |
| `text`           | String/List | Button text, supports color codes, conditional logic, and MiniMessage tags                   |
| `width`          | Int         | Optional, button width (1-1024); if not set, the default width is used                       |
| `tooltip`        | List        | Optional, button hover tooltip (one string per line), supports color codes and MiniMessage   |
| `actions`        | List        | Optional, list of actions executed when clicked; if not set, clicking has no effect          |

**Exit button configuration items:**

| Field     | Type        | Description                                                                         |
| --------- | ----------- | ----------------------------------------------------------------------------------- |
| `text`    | String/List | Exit button text, supports color codes, conditional logic, and MiniMessage tags     |
| `width`   | Int         | Optional, exit button width (1-1024)                                                |
| `actions` | List        | Optional, list of actions executed when clicked; if not set, clicking has no effect |

**Example:**

```yaml
Bottom:
  type: 'multi'
  columns: 3

  buttons:
    btn_shop:
      text: '&6[ Shop ]'
      actions:
        - 'open: shop/main'

    btn_profile:
      text: '&b[ Personal Info ]'
      actions:
        - 'open: profile'

    btn_settings:
      text: '&7[ Settings ]'
      actions:
        - 'open: settings'

    btn_admin:
      text: '&4[ Admin Panel ]'
      actions:
        - 'open: admin/tools'

  exit:
    text: '&8[ Close ]'
    actions:
      - 'actionbar: &7Menu closed'
      - 'close'
```

In Multi mode, you can also use `show-condition` to control whether buttons are shown:

```yaml
Bottom:
  type: multi
  columns: 2
  buttons:
    1:
      show-condition: "%player_is_op% == true"  # only admins can see this button
      text: '[ Admin Button ]'
      actions: ...
    2:
      show-condition: "%player_level% >= 10"  # only players level 10 or above can see this
      text: '[ VIP Button ]'
      actions: ...
    3:
      text: '[ Normal Button ]'  # no display condition, visible to all players
      actions: ...
```

***

## Conditional button text

The `text` fields of all buttons support conditional logic:

```yaml
Bottom:
  type: 'confirmation'
  confirm:
    text:
      - condition: "%player_level% >= 10"
        allow: '&6[ VIP Confirm ]'
        deny: '&a[ Confirm ]'
    actions:
      - 'tell: &aConfirmed'
  deny:
    text: '&c[ Cancel ]'
    actions:
      - 'tell: &7Canceled'
```

For the complete syntax of conditional logic, please refer to [🔍 Conditional Logic](/plugins/kamenu-en/menu/conditions.md).

***

## Button width (width)

All buttons support custom width settings; the `width` field can be used to control the displayed width of the button.

**Applicable scope:**

* `notice` mode confirm button (`confirm.width`)
* `confirmation` mode confirm and cancel buttons (`confirm.width` and `deny.width`)
* `multi` all buttons in mode (`buttons` each button in and `exit` button)

**Width values:**

* Range: 1 - 1024
* If not set, the default width will be used (determined by the Paper Dialog API)
* Supports conditional logic

**Example:**

```yaml
# notice mode
Bottom:
  type: 'notice'
  confirm:
    text: '&a[ Confirm ]'
    width: 200
    actions:
      - 'tell: &aAction confirmed'

# confirmation mode
Bottom:
  type: 'confirmation'
  confirm:
    text: '&a[ Confirm ]'
    width: 200
    actions:
      - 'tell: &aAction confirmed'
  deny:
    text: '&c[ Cancel ]'
    width: 100
    actions:
      - 'tell: &cAction canceled'

# multi mode
Bottom:
  type: 'multi'
  columns: 2

  buttons:
    wide_button:
      text: '&a[ Wide Button ]'
      width: 200
      actions:
        - 'tell: &aThis is a wide button'

    narrow_button:
      text: '&b[ Narrow Button ]'
      width: 50
      actions:
        - 'tell: &bThis is a narrow button'

    conditional_width:
      text: '&c[ Conditional Width ]'
      width:
        - condition: '%player_is_op% == true'
          allow: 200
          deny: 100
      actions:
        - 'tell: &cButton width changes based on permissions'

  exit:
    text: '&8[ Exit ]'
    width: 80
    actions:
      - 'close'
```

**Note:**

* The width value affects the actual displayed size of the button in the interface
* An excessively large width may cause the button to go off screen
* It is recommended to adjust the width value according to actual display needs


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://katacr.gitbook.io/plugins/kamenu-en/menu/bottom.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
