Auth Customisation
AppBuilder ships with fully built-in auth pages — login, role selection, two-factor authentication, forgot/reset password. They work out of the box and pick up your app's theme.
What's Built In
| Page | Default behaviour |
|---|---|
| Login | Email or mobile + password; tab switching |
| Role selection | Card grid of available roles for the user |
| Two-factor auth | OTP input with countdown resend |
| Forgot password | Email entry → reset link |
| Reset password | New password form |
Customising via authConfig
All customisation is done through the authConfig prop on ZangoApp in src/App.tsx:
import { ZangoApp } from '@zango-core/crm-framework';
import * as customPages from './custom/pages';
const App = () => (
<ZangoApp
appInitializerEndpoint="/appbuilder/initializer/"
customPages={customPages}
authConfig={{
// theme, login text, custom components, etc.
}}
/>
);
Sections
- Login Page — customise text, tabs, redirect, custom login component
- Theme & Branding — background, colours, logo, card style
- OAuth Providers — add Google, Microsoft, or custom OAuth buttons