Adminix Documentation Help

Page

Page configuration is provided by a class that implements AlexKudrya\Adminix\AdminixPageProvider.

// app/Adminix/Pages/IndexPage.php namespace App\Adminix\Pages; use AlexKudrya\Adminix\AdminixPage; use AlexKudrya\Adminix\AdminixPageProvider; class IndexPage implements AdminixPageProvider { const URI = '/'; public static function get(): AdminixPage { $page = new AdminixPage(); $page->setAsHomePage(); $page->uri(self::URI); $page->name('index'); $page->addModules( // ... ); return $page; } }

Every page provider class must implement the get() method and return an AlexKudrya\Adminix\AdminixPage instance.

Responsive admin shell

Adminix renders every page inside the shared package shell. The PHP page configuration does not need a mobile-specific option:

$page = new AdminixPage(); $page->uri('products'); $page->name('products'); $page->addModules( // ListModule, ResourceModule, charts, counters, links, modals, ... );

Result: desktop keeps the normal sidebar layout. On narrow screens Adminix shows a menu icon button, keeps the sidebar off-canvas until it is opened, closes it by backdrop or Escape, and gives page content enough top spacing so modules do not sit under the menu button.

The shell is package-owned behavior. Do not create a second app-specific mobile navigation layer around Adminix pages; extend the Adminix shell and module views instead.

Create new Adminix page

To create a new page, use the next Artisan command. If you do not pass a name, Laravel will prompt you for it.

php artisan make:adminix_page

You can also pass the page name directly, for example products.

php artisan make:adminix_page products

Result: a new Adminix page provider will be created at app/Adminix/Pages/ProductsPage.php.

// app/Adminix/Pages/ProductsPage.php namespace App\Adminix\Pages; use AlexKudrya\Adminix\AdminixPage; use AlexKudrya\Adminix\AdminixPageProvider; class ProductsPage implements AdminixPageProvider { const URI = 'products'; public static function get(): AdminixPage { $page = new AdminixPage(); $page->uri(self::URI); $page->name('products'); $page->addModules( // ToDo: add required modules ... ); return $page; } }

After that, add this class to the pages array in config/adminix.php.

// config/adminix.php use App\Adminix\Pages\IndexPage; use App\Adminix\Pages\ProductsPage; use App\Adminix\Pages\UsersPage; // ... 'pages' => [ IndexPage::get(), UsersPage::get(), ProductsPage::get(), ],

If needed, add a sidebar menu link to this page.

// config/adminix.php use AlexKudrya\Adminix\Modules\Link\MenuLinkModule; use App\Adminix\Pages\IndexPage; use App\Adminix\Pages\ProductsPage; use App\Adminix\Pages\UsersPage; // ... 'menu' => [ 'title' => 'Admin panel', 'links' => [ MenuLinkModule::title('Dashboard') ->uri(IndexPage::URI) ->icon('bi bi-speedometer2'), MenuLinkModule::title('Users') ->uri(UsersPage::URI) ->icon('bi bi-people-fill'), MenuLinkModule::title('Products') ->uri(ProductsPage::URI) ->icon('bi bi-boxes'), ], ],

Adminix page configuration

Method

Description

setAsHomePage

Defines the home page for the Adminix panel.

Must be used only for one Adminix page, usually the index page.

uri

Defines the URL address of the Adminix page.

Required.

Must be unique.

Structure: [Base URL] / [Prefix from config] / [Page URI].

Example: if the page URI is set to products, the full page URL will be https://mydomain.com/adminix/products.

Recommended: define a URI constant and reuse it in page and menu configuration.

name

Defines the system name for the page.

Required.

Must be unique.

addModule / addModules

Adds module(s) to the page.

Every top-level module is an instance of AdminixTopModuleInterface with its own configuration.

Modules are rendered in the same order in which they are added to the AdminixPage object.

Module configuration is described in Modules.

Last modified: 21 June 2026