Documentation Xakti Admin
A brief guide to the admin template’s workflow, structure, theming, and integrations.
Getting Started
Xakti Admin is a static site with no runtime framework.
- Open
frontend/index.htmldirectly in a browser to use the standalone bundle. - For ES Modules and local development, run
python3 -m http.server 8080from thefrontend/folder. - Open
http://localhost:8080, then use the sidebar to navigate between pages. - Copy
pages/blank.htmlwhen you want to create a new page with the existing app shell.
How the Architecture Works
Every HTML page uses the same app shell: sidebar, topbar, content area, footer, and Theme Customizer panel.
| Section | Role |
|---|---|
index.html | Main dashboard and product entry point. |
pages/ | Dashboard, form, table, auth, error, and plugin example page templates. |
assets/css/ | Design tokens, Bootstrap mappings, layout, components, and plugin integrations. |
assets/js/app.js | ES Module entry point that initializes all modules through window.XaktiAdmin. |
assets/js/app.bundle.js | Non-module bundle for opening the application through file://. |
Theme and Sidebar
The global mode uses data-bs-theme Bootstrap and supports Light, Dark, and System. Settings are saved in localStorage with the prefix xa:.
- Click the palette icon in the topbar to choose the mode, sidebar preset, accent, and radius.
- Sidebar presets can be configured through the attribute
data-xa-sidebar-themeor CSS tokens inassets/css/tokens.css. - The color picker automatically calculates the foreground and derived tokens to maintain readable contrast.
- The desktop sidebar can be collapsed with the topbar button or shortcut Ctrl/Cmd + B; on small screens, the sidebar uses Offcanvas.
Public JavaScript API
The public API is available through the following global namespace:
XaktiAdmin.theme.set('dark');
XaktiAdmin.sidebar.toggle();
XaktiAdmin.sidebarTheme.apply('emerald');
XaktiAdmin.toast.show({ title: 'Successful', message: 'Changes saved.' });
Development Guide
- Use Bootstrap component classes as-is; use the prefix
xa-only for app shell elements not available in Bootstrap. - Add JavaScript as a small module in
assets/js/modules/, then register its initialization inapp.js. - Edit source CSS, then synchronize
assets/css/app.min.cssbecause production pages load the minified file. - Use icons from
assets/icons/sprite.svg; do not add CDNs or external dependencies. - After user-visible changes, update
CHANGELOG.mdand test light/dark, sidebar desktop/mobile, keyboard, and at least two presets.