Tab Lifecycle
Every tab in the workspace system goes through a predictable lifecycle from creation to closure. Understanding this lifecycle helps you manage your workspace effectively and ensures you never lose work unexpectedly.
Tab Creation
A tab is created when a user action or system event requires opening a new record view. The creation process involves several steps executed automatically.
First, the system creates a tab data record that defines what the tab displays. This includes the data type (which component to render), a reference ID (which specific record to load), the data source, and initial properties. Second, the system creates the tab record itself, linking it to the workspace, the tab data, a display name, a sort order (appended to the end), and an initial access timestamp.
After creation, the workspace's active tab is updated to the new tab, and the tab bar renders the new tab with a smooth appearance animation.
Active Tab State
At any given time, exactly one tab in the workspace is active — it is the tab whose content is displayed in the main content area. Switching tabs updates the active tab pointer on the workspace record and triggers a state save for the tab being deactivated and a state restore for the tab being activated.
The active tab's state includes scroll position (vertical and horizontal scroll offsets), applied filters (search terms, status filters, date ranges), pagination state (current page, items per page), and any component-specific state stored as a JSON object.
State Persistence
Tab state is persisted through two mechanisms.
Immediate save occurs on every tab open, close, reorder, and active tab switch. The workspace and active tab state are written to the database immediately. This ensures that tab operations are durable — if you close a tab and the page crashes a second later, the close is already persisted.
Interval save occurs every 30 seconds (configurable via the workspace's auto-save interval). The active tab's current UI state is persisted silently in the background. This captures incremental changes like scrolling, adjusting filters, or paginating through results. The interval save operates silently with no visual feedback unless it fails three consecutive times, at which point a warning banner appears.
Tab Pinning
Tabs can be pinned to prevent accidental closure and eviction. The Dashboard tab is pinned by default and cannot be unpinned. Users can pin other tabs through the right-click context menu.
Pinned tabs have several special behaviors. They cannot be closed through the normal close button — the X button is hidden. They cannot be evicted when the tab limit is reached. They are displayed before unpinned tabs in the tab bar. They maintain their position when other tabs are reordered around them.
To close a pinned tab, you must first unpin it through the context menu, then close it normally.
Tab Eviction
When the workspace reaches its maximum tab count and a new tab needs to open, the system evicts the least recently accessed non-pinned tab. Eviction is a soft close — the tab and its data are removed from the active workspace but can be restored from tab history.
The eviction algorithm sorts non-pinned tabs by their last accessed timestamp and removes the oldest one. If all non-pinned tabs were accessed very recently, the oldest still gets evicted. The system never prevents a new tab from opening — the limit triggers eviction, not blocking.
Tab Closure
When a tab is closed (manually or through eviction), the system performs several cleanup steps. The tab record is soft-deleted (marked with a deletion flag, not physically removed). The tab data record is soft-deleted if no other tab references it. If the closed tab was the active tab, the system switches to the nearest neighbor tab (preferring the tab to the left). The workspace's tab order is updated to fill the gap.
Closed tabs are tracked in tab history for potential restoration. The "reopen closed tab" keyboard shortcut (Ctrl+Shift+T) restores the most recently closed tab from this history.
Tab Archiving
Tabs that have been closed for an extended period (configurable, typically 90 days) are archived. Archived tabs are moved from the active history to an archive store. They can still be found through search but no longer appear in the "recently closed" list.
Tab Restoration
Tabs can be restored from several sources. The keyboard shortcut Ctrl+Shift+T reopens the most recently closed tab. The tab history view shows all recently closed tabs with their display names and close timestamps. Clicking a history entry restores the tab with its last known state.
Restoration creates a new tab with the same data reference and attempts to restore the preserved state. If the underlying record has been deleted or the user no longer has permission to access it, the restoration will open the tab but show an appropriate error state.
On this page