Skip to main content
cngx-src documentation

CngxTabsPanelMode

Type Aliascommon/tabs

projects/common/tabs/tabs-config.ts

Referenced by#

Description#

Panel render strategy for <cngx-tab-group>.
The panel <div> (the aria-controls target) always stays in the DOM; only its content is rendered per mode. 'eager' (default) renders every panel's content up front and toggles visibility via [hidden] - today's behaviour, byte-identical. 'lazy' renders a panel's content the first time it is activated and keeps it (keep-alive). 'lazy-destroy' renders only the active panel's content and destroys it on leave.

A [cngxTabsRouteSync] / [cngxTabsFragmentSync] deep link resolves its tab at content-init, before the first panel render, so under 'lazy' only the target panel's content ever mounts - the default tab is never activated on the way. Without that ordering the first render would count as tab 0's first activation and keep-alive would hold its content for the rest of the session.

Definition#

"eager" | "lazy" | "lazy-destroy"