Invoxa Developer Documentation

Comprehensive zero-build reference for styling tokens, JSON data tables, Chart.js lifecycle, 6 invoice layouts, role permissions, keyboard shortcuts, and Netlify deployment.

52 HTML5 Screens Bootstrap 5.3 + Vanilla ES6 UI Template Only · Demo Data
10 sections
01 / Getting Started

Quick Start & Technical Requirements

Invoxa ships as pure static HTML5, CSS3, and modular vanilla ES6 JavaScript. You do not need Node.js, Webpack, Vite, Sass compilers, or jQuery to edit, theme, or deploy any page.

Local Development Server

Although main.js bundles an automatic file:// fallback for demo JSON datasets, serving over HTTP guarantees native ES fetch behavior and clean browser caching:

# Option A — Python 3 built-in server
python -m http.server 8080

# Option B — Node static server
npx serve .

# Then visit: http://localhost:8080/index.html
Template Notice: UI template only, no backend. All names, sample tax IDs, financial amounts, exchange rates, and calculators display fictional demo data ("Demo values, not financial advice").
02 / Architecture

Complete Folder Map & 52-Page Directory

Every page loads self-hosted vendor libraries and fonts from assets/ with zero external network calls.

Directory / FileResponsibility
index.htmlFlagship multi-section landing page (live 3-tab browser frame, marquee ticker, invoice sandbox, workflow lab, 51-screen tour, pricing mockup, FAQ)
docs.htmlStandalone developer documentation portal (this page, without the workspace sidebar)
netlify.tomlZero-build Netlify configuration, security headers, clean route rewrites, and static asset caching
assets/css/style.css11 commented CSS sections containing Light/Dark variables, Obsidian Ink rail, components, 6 invoice sheets & prefers-reduced-motion
assets/js/components.jsShared Obsidian Ink sidebar (9 groups + session scroll persistence), top-left Profile Dropdown, role switcher & Ctrl/Cmd+K palette
assets/js/main.jsCore runtime (Invoxa.*), Light/Dark & RTL toggles, accent swatches, KPI count-ups, 3D tilt, OTP keypad, calendar, reconciliation & journal balance checks
assets/js/table.jsJSON table engine with 15 presets, search, sorting, live status counts, column toggles, bulk select & CSV download
assets/js/charts.jsLocal Chart.js 4 initializer reacting automatically to Light/Dark theme switches
assets/js/invoice.jsInvoice builder state, multi-currency totals, logo selector, 6 paper layouts & confetti PAID stamp
assets/js/tools.js5 interactive estimators (EMI amortization chart, Compound Interest, SIP, Editable Tax Slabs, Currency converter) & Client Portal mock pay
assets/data/*.jsonSample JSON payloads (sales.json, purchases.json, accounting.json, reports.json)
assets/fonts/ & vendor/Self-hosted WOFF2 (Plus Jakarta Sans, Inter, IBM Plex Mono) + local Bootstrap 5.3.9, Bootstrap Icons 1.13.2 & Chart.js 4.6.2

Included HTML Modules inside pages/ (50 files)

Overview & Auth (7): dashboard, analytics, calendar, login, register, forgot-password, two-factor
Invoicing & CRM (11): invoices, invoice-create, invoice-details, invoices-recurring, invoice-layouts, quotes, quote-create, credit-notes, customers, customer-profile, products
Purchases & Banking (10): vendors, purchase-orders, purchase-order-create, bills, expenses, expense-add, expense-claims, payments, bank-transactions, bank-reconciliation
Accounting, Reports & Settings (22): chart-of-accounts, general-ledger, journal-entries, trial-balance, report-pnl, report-balance-sheet, report-cashflow, report-tax-summary, report-aging, budgets, cashflow-forecast, calculators, client-portal, settings-profile, settings-company, settings-taxes, settings-team, settings-billing, settings-notifications, documentation, 404, 500
03 / Brand Customization

Design Tokens, Dark Mode, Live Accents & RTL

All semantic surfaces and money status colors are controlled from Section [02] in assets/css/style.css. Click an accent dot to preview live across your browser session:

:root, [data-bs-theme="light"] {
  --ink: #14122B;       /* Deep Calm Ink */
  --iris: #6C5CE7;      /* Primary Action */
  --iris-soft: #8E7CFF; /* Gradient Highlight */
  --mint: #2EE6A6;      /* Paid / Settled Money Status */
  --coral: #FF6B81;     /* Overdue / Negative Money Status */
  --gold: #FFC857;      /* Pending / Warning Status */
  --mist: #F5F4FB;      /* App Canvas */
}
  • Dark Theme: Saved in localStorage['invoxa-theme'] and toggles data-bs-theme="dark" on <html>. Paper print sheets inside .inv-sheet intentionally retain crisp dark ink on light paper even in Dark Mode.
  • RTL Mode: Saved in localStorage['invoxa-dir'] and dynamically swaps #inv-bs-css to assets/vendor/bootstrap/bootstrap.rtl.min.css.
04 / App Chrome

Sidebar Scroll Persistence, Profile Dropdown, Role Lock & Shortcuts

Workspace pages share 3 empty mount containers (#inv-sidebar-slot, #inv-topbar-slot, #inv-footer-slot) hydrated cleanly by components.js so updating navigation happens in one file.

Sidebar & Profile Menu

Sidebar collapse state saves to localStorage['invoxa-sidebar-mini'] (`body.inv-mini`) and menu scroll position persists via sessionStorage['invoxa-sidebar-scroll']. The top-left dropdown links directly to Profile, Company, Roles, Billing, Docs, and Sign Out.

RBAC Preview & Hotkeys

Switching Role to Viewer disables every button and anchor tagged with .js-role-write (.is-role-locked + aria-disabled). Keyboard shortcuts: Ctrl/Cmd+K Command Palette, ? Shortcuts Modal, Alt+T Theme.

05 / Reusable Data Grid

JSON Table Engine (table.js)

Any table view mounts from a single element using data-source, data-key, data-preset, and optional data-page-size:

<div id="inv-table-host"
     data-source="sales.json"
     data-key="invoices"
     data-preset="invoices"
     data-page-size="8"></div>

Supported Presets: invoices, recurring, quotes, creditNotes, customers, products, purchaseOrders, vendors, expenses, bills, payments, bankTransactions, accounts, ledger, trialBalance. Includes live search, sort, status filter counts, column visibility menu, bulk selection bar, row actions, and CSV export.

06 / Billing & Print

Live Invoice Builder & 6 Paper Layouts

Managed by assets/js/invoice.js across invoice-create.html, invoice-details.html, and invoice-layouts.html:

  • Dynamic Line Items: Add/remove rows updating subtotal, percentage discount, sample tax, and multi-currency formatting (USD, EUR, GBP, INR).
  • 6 CSS Sheet Modifiers: .inv-sheet--classic, .inv-sheet--modern, .inv-sheet--minimal, .inv-sheet--bold, .inv-sheet--compact, and .inv-sheet--receipt.
  • Interactive PAID Stamp & Print: Clicking #inv-mark-paid-btn reveals .inv-stamp-paid.is-visible with confetti dots (skipped automatically under prefers-reduced-motion). @media print hides chrome automatically.
07 / JavaScript Modules

Global window.Invoxa Helper API & Charts

// Available globally on pages importing main.js
window.Invoxa.showToast('Saved invoice draft', 'success'); // 'info' | 'success' | 'warn'
window.Invoxa.formatMoney(4850, 'USD');                    // "$4,850"
window.Invoxa.initialsAvatar('Northstar Studio');          // Returns styled avatar span
const sales = await window.Invoxa.loadData('sales.json');  // Fetch + file:// fallback

charts.js attaches a MutationObserver to <html data-bs-theme> so every Chart.js canvas updates axis tick and gridline colors immediately when toggling Dark Mode.

08 / Extending Template

How to Add a Custom Page in 3 Steps

  1. Duplicate any starter page in pages/ (e.g., invoices.html) and set a descriptive <body data-page="custom-view">.
  2. Keep #inv-sidebar-slot, #inv-topbar-slot, #main-content, and #inv-footer-slot intact with zero inline CSS attributes.
  3. Append an object `{ name: 'My View', icon: 'bi-star', href: 'my-view.html' }` inside navGroups in assets/js/components.js — both the sidebar and Ctrl/Cmd+K Command Palette pick it up immediately.
09 / Deployment Guide

Deploying on Netlify, Vercel, GitHub Pages or Nginx

The root folder contains a ready-to-deploy netlify.toml:

  • Netlify Drag & Drop: Open app.netlify.com/drop and drop the extracted project root folder. No build command needed.
  • Netlify CLI / Git: Connect your Git repo with empty Build Command and Publish Directory set to ..
  • Clean Aliases Included: /docs rewrites internally (`200`) to /docs.html; /login and /dashboard redirect (`301`) cleanly to their pages/ targets.
[build]
  publish = "."

[[redirects]]
  from = "/docs"
  to = "/docs.html"
  status = 200
10 / FAQ & Licensing

Troubleshooting, Credits & Disclaimers

  • Forms & Authentication: Forms use .js-demo-form for HTML5 constraint validation feedback and toast simulation. Replace or intercept submit handlers in main.js to post to your API.
  • Non-Advisory Disclaimers: Sample tax slabs, GST/VAT labels, balance sheet ratios, and finance calculators display fictional numbers strictly for UI demonstration — not tax, accounting, or legal advice.
  • Third-Party Licenses: Bootstrap 5.3 (MIT), Bootstrap Icons (MIT), Chart.js 4 (MIT), Plus Jakarta Sans / Inter / IBM Plex Mono (SIL Open Font License 1.1). Zero stock photos used.