# 🗂️ Categories

> **Info:**
Every category is its own file inside the shop's folder in shops, named after the category's identifier.

## Add a Category

Left-click the lime stained glass in **Editor > Shops > Shop > Categories** to create a category. It gets the next free `category_<number>` identifier and its editor opens straight away.

<figure><img src="../../.gitbook/assets/categories/categories.png" alt="" width="563"><figcaption><p>Edit Shop (Categories)</p></figcaption></figure>

<figure><img src="../../.gitbook/assets/categories/add-a-category.png" alt="" width="563"><figcaption><p>Categories (New Category)</p></figcaption></figure>

Every category in the list shows its icon, display name and identifier, how many items it holds and whether it is enabled. Left-click one to edit it, right-click it to delete it, together with its items, after a confirmation. The Filter button narrows the list to enabled categories, disabled categories, categories on the main menu, hidden categories or subcategories.

## Order

Categories fill the category slots of the shop's main menu by their order number, lowest first, and by identifier when two share the same number. The same order sorts sub-categories inside their parent. Disabled, [hidden](edit-category.md#hidden) and [sub-categories](edit-category.md#parent-category) are skipped. There is no editor option for it, so it is set in the category's file, and a new category starts at 0.

```yaml
order: 1
```

> **Info:**
When a shop has more categories than its main menu has category slots, the rest go on further pages. Without page buttons in the layout they are hidden, and the console says so.

## Navigation

| Features | Description |
| --- | --- |
| [Identifier](edit-category.md#identifier) | The unique id of the category and the name of its file. |
| [Display](edit-category.md#display) | The title, icon and lore of the category. |
| [Currency](edit-category.md#currency) | Override the shop's currency and its format for this category. |
| [Open Command](edit-category.md#open-command) | A command that opens the category directly. |
| [Hidden](edit-category.md#hidden) | Keep the category out of the main menu and search. |
| [Parent Category](edit-category.md#parent-category) | Show the category inside another one. |
| [Items](../items/) | The items of the category. |
| [Actions](edit-category.md#actions) | Actions run when the category is opened or closed. |
| [Conditions](edit-category.md#conditions) | Who can open the category and trade in it. |
| [Rotation](edit-category.md#rotation) | Show only some of the items at a time. |
| [Sale](edit-category.md#sale) | A discount on every item of the category. |
| [Buying](edit-category.md#buying) | Allow or block buying from the category. |
| [Selling](edit-category.md#selling) | Allow or block selling to the category. |
| [Enabled](edit-category.md#enabled) | Show or hide the category. |
| [Delete](edit-category.md#delete) | Delete the category and its items. |

Source: https://www.phoenixplugins.com/docs/phoenix-shop/main-features/categories