Free cookie consent management tool by TermsFeed Generator
All Products & Integrations

jalpi page builder docs

Navigator

The Jalpi Page Builder Navigator (implemented as the Layers Panel) provides a structured, hierarchical tree view of every section, container, column, and widget on your page. It enables seamless DOM navigation, instant element selection, drag-and-drop reordering, visibility toggling, node locking, and inline renaming without needing to click on overlapping or zero-padding canvas elements.

Active Feature Editor UI React Tree Component
13 min read Β· November 2026

Modern web pages often contain deeply nested container hierarchies, zero-margin inner columns, absolutely positioned badges, sticky elements, or overlays. Selecting or reordering these elements directly on a visual canvas can be difficult or error-prone.

Navigator panel showing the page structure as a tree of sections, containers and widgets
Figure: Jalpi Navigator interface displaying page element hierarchy and container tree controls.

The Navigator solves this by displaying a direct, two-way synchronized structural tree representation of your page's internal JSON document model (pageData.sections). Every item rendered on the visual canvas corresponds to a node in the tree.

Precision DOM Tree

Access any deeply nested element, hidden layer, or zero-height spacer with a single click, bypassing z-index overlaps or negative margins on the canvas.

Reliable Drag & Drop

Reorder sections, rearrange columns, or move widgets across containers with pinpoint insertion line indicators before and after target nodes.

Locking & Protection

Lock sections or widgets to prevent accidental dragging, accidental edits, or unwanted shifts while working on neighboring elements.

Device Visibility Toggles

Quickly inspect and toggle element visibility per breakpoint (Desktop, Tablet, Mobile) with real-time dimmed state indicators.

Opening Navigator#

The Navigator is tightly integrated into the primary editor workspace and can be opened in multiple ways:

1. Inspector Outline Tab

The primary location of the Navigator is inside the right-hand Inspector panel. In the tab navigation bar at the top of the Inspector, click the Outline tab button (represented by an outline list icon):

tsx (Editor Tab Header)
<div className="jalpi-inspector-nav">
  <button
    className={"jalpi-inspector-nav__btn" + (inspTab === 'outline' ? ' is-active' : '')}
    onClick={() => setInspTab('outline')}
    title="Page Outline"
  >
    <OutlineIcon /> Outline
  </button>
  <button className={"jalpi-inspector-nav__btn" + (inspTab === 'style' ? ' is-active' : '')} onClick={() => setInspTab('style')}>Style</button>
  <button className={"jalpi-inspector-nav__btn" + (inspTab === 'page' ? ' is-active' : '')} onClick={() => setInspTab('page')}>Page</button>
  <button className={"jalpi-inspector-nav__btn" + (inspTab === 'global' ? ' is-active' : '')} onClick={() => setInspTab('global')}>Global</button>
  <button className={"jalpi-inspector-nav__btn" + (inspTab === 'classes' ? ' is-active' : '')} onClick={() => setInspTab('classes')}>Classes</button>
</div>

2. Global Command Finder (Ctrl+K / ⌘K)

You can quickly reveal or toggle the Navigator from anywhere in the editor using the Global Finder palette:

  • Press Ctrl+K (Windows/Linux) or ⌘K (macOS) to open the palette.
  • Type layers or outline.
  • Select Show layers panel or Hide layers panel.

3. Panel Resizing & Docking

The Inspector containing the Navigator is docked to the right edge of the editor. A drag-resizer handle (PanelResizer) separates the Canvas and the Inspector, allowing you to fluidly resize the panel from a minimum width of 220px to a maximum of 560px. Your customized width is remembered during your editing session.

Jalpi Page Builder structures pages using a strict, semantic node tree. The Navigator visualizes this exact hierarchy using distinctive type icons and indentation depths (6px + depth * 14px):

1. Sections (β–£ section)

Sections form the top-level roots of the page document (stored in pageData.sections). A section typically spans full viewport width and acts as the outer wrapper for margins, backgrounds, border overlays, and overall vertical cadence. In the Navigator header, a dedicated + Add Section button allows you to instantly append a fresh section to the document.

2. Containers (⊞ container)

Containers are flexible layout blocks placed inside sections or nested inside other containers. They implement CSS Flexbox or Grid layouts, control maximum content widths (e.g. 1200px boxed layout), handle padding, and provide multi-directional flow alignment.

3. Columns (β–₯ column)

Columns represent structural vertical divisions within multi-column sections or container grids. They manage proportional width sizing (e.g. 50%/50%, 33%/66%), vertical alignment, and mobile stacking order.

4. Elements & Widgets

Elements are leaf nodes (or composite components) that render actual user content. Each widget type is represented with a designated icon and a dynamic, human-readable label extracted from its content:

Type IconWidget TypeDefault Label PreviewDescription
β–£sectionSectionTop-level page section layout block.
⊞containerContainerFlex / Grid wrapper with width & alignment controls.
β–₯columnColumnColumn partition within multi-column grid layouts.
HheadingText snippet (first 26 chars)Typography heading element (H1–H6).
ΒΆtextHTML stripped snippet (first 26 chars)Rich text paragraph / content block.
⬜buttonButton label (first 26 chars)Call-to-action button element.
⬚imageImageResponsive media image node.
β–ΆvideoVideoHTML5, YouTube, or Vimeo embed block.
↕spacerSpacerAdjustable vertical spacing element.
─dividerDividerHorizontal decorative rule or separator.
β˜…iconIconVector SVG icon from Tabler / Bootstrap icon registries.
[]shortcodeShortcode snippet (first 22 chars)WordPress shortcode handler node.
<>htmlHtmlRaw HTML embed block.
βŠ•mapsMapsInteractive Google Maps embed widget.
β—ˆlogoLogoSite logo / brand graphic element.
⊟formFormInteractive input form container.
βš‘alertAlertNotification / dismissible banner widget.
#counterCounterAnimated numerical milestone counter.
β–°progressProgressPercentage progress bar indicator.
❝testimonialTestimonialQuote, author attribution, and avatar block.
≑accordionAccordionCollapsible accordion panel group.

Visual Hierarchy Tree

The code below illustrates how the tree structure is represented in Jalpi Page Builder:

text (Actual Jalpi Node Hierarchy)
Page (pageData.sections)
└── β–£ Section (id: "sec-1")
    └── ⊞ Container (id: "cnt-1")
        β”œβ”€β”€ β–₯ Column (id: "col-1", width: "50%")
        β”‚   β”œβ”€β”€ H Heading ("Welcome to Jalpi")
        β”‚   β”œβ”€β”€ ΒΆ Text ("The next-generation WordPress...")
        β”‚   └── ⬜ Button ("Get Started Today")
        └── β–₯ Column (id: "col-2", width: "50%")
            β”œβ”€β”€ ⬚ Image (hero-banner.webp)
            └── ↕ Spacer (24px)

Working with Elements#

The Navigator is not merely a passive read-only tree; it provides full operational control over every layer on your page.

Every action listed in the table below is confirmed and active in the current Jalpi Page Builder implementation (LayersPanel.tsx):

ActionTrigger / ControlDescriptionCanvas Effect
SelectLeft-click on any rowUpdates state.selectedId in editorStore.Draws active selection boundary on canvas and switches Inspector to element properties.
Expand / CollapseChevron toggle button (> / v)Toggles visibility of children for the specific branch.None (affects tree view only).
Expand AllExpand All icon in panel headerExpands all collapsed nodes across the entire page.None (affects tree view only).
Collapse AllCollapse All icon in panel headerCollapses all sections and containers to top-level view.None (affects tree view only).
Search / FilterHeader search input (Esc to clear)Filters nodes by custom label or element type; automatically expands ancestor paths.Non-matching nodes are hidden from tree list.
Inline RenameDouble-click label OR Right-click β†’ RenameOpens inline text input with autofocus. Press Enter or blur to commit, Esc to cancel.Updates label override dictionary for convenient project layer organization.
Toggle VisibilityEye icon button (IcoEye / IcoEyeOff) OR Context MenuToggles node visibility across breakpoints (store.toggleNodeVisibility(id)).Hides/reveals element on canvas and dims layer row in Navigator with strike-through eye.
Lock / UnlockLock icon button (IcoLockOn / IcoLockOff) OR Context MenuToggles node.locked flag (store.lockNode(id, locked)).Prevents canvas edits, hides drag handle, and prevents drag reordering.
Drag ReorderDrag grip handle (:::)Drags node before or after another target node using native HTML5 drag events.Instantly repositions element in canvas DOM and pushes an undo history step.
DuplicateRight-click β†’ Duplicate OR Ctrl+DDeep-clones the node and children with newly generated unique IDs (store.duplicateNode(id)).Inserts cloned duplicate immediately beneath original node.
CopyRight-click β†’ Copy OR Ctrl+CCopies JSON serialization of node to editor clipboard state (store.copyNode(id)).Allows pasting into another section or container with Ctrl+V.
DeleteRight-click β†’ Delete OR Delete / BackspaceRemoves node and all nested children from tree (store.deleteNode(id)).Removes element from canvas DOM and registers undo history step.
Add Section+ button in panel headerAppends a new empty section with an initial container (store.addSection()).Appends new section to canvas bottom and scrolls into view.

Expanding & Collapsing Hierarchy

Each node containing children displays a triangular chevron button:

  • Right arrow (>): Indicates a collapsed node. Click to reveal children.
  • Down arrow (v): Indicates an expanded node. Click to collapse children.

In addition, the panel header provides global Collapse All and Expand All buttons. This allows developers working on lengthy single-page sites to instantly collapse dozens of sections to focus on a single branch.

Renaming Elements

To keep complex wireframes organized, you can assign custom names to any layer (e.g. renaming Section to Hero Section or Button to CTA Checkout):

  • Double-click any layer name in the Navigator, or right-click and choose Rename.
  • An autofocus input replaces the text label.
  • Press Enter or click outside to save. Press Escape to discard changes.

Visibility Indicators & Toggles

Every row features an eye icon button on hover:

  • When an element is visible, clicking the eye hides the element.
  • When hidden, the row receives the CSS class .is-hidden, applying a dimmed opacity (0.5) and switching the icon to IcoEyeOff.
  • Hidden elements remain fully accessible and selectable in the Navigator tree, allowing you to unhide them at any time.

Locking Elements

When you have finalized the styling and layout of a header or complex grid, click the Lock icon (IcoLockOn):

  • The layer row receives the .is-locked class.
  • The drag handle is disabled (draggable={false}).
  • Accidental canvas drag-and-drop or selection modifications on that node are prevented until unlocked.

Duplicating & Deleting Elements

Right-clicking any layer opens the contextual menu (CtxMenu):

  • Duplicate: Calls store.duplicateNode(node.id). All child elements and attributes are recursively cloned with fresh timestamp-based IDs, avoiding collision bugs.
  • Delete: Highlighted in red (.jalpi-lctx__item--danger). Removes the element from the document tree and records a snapshot to undo history.

Searching & Filtering Nodes

The panel header includes a real-time search input:

  • Type any query (e.g. hero, button, column).
  • The tree dynamically filters nodes matching your query by label or node type.
  • Automatic Ancestor Expansion: The helper buildMatchSet automatically identifies and expands all parent and ancestor branches of matched nodes, ensuring deep search results remain visible in context.
  • Pressing Escape or clicking the βœ• button clears the filter.

Selecting Elements#

Clicking any row in the Navigator executes store.selectNode(node.id):

  • The active row is highlighted with an accent background and border (.is-selected).
  • The corresponding element on the canvas receives an active selection outline with resizing handles.
  • The right Inspector switches to the Style tab (or keeps the Outline active depending on workflow).
  • Quick action buttons (Duplicate, Copy, Delete) appear below the active layer.

Reordering Elements#

Reordering elements in Jalpi is handled through the Navigator with high precision. While canvas dragging can suffer from ambiguous drop targets in tight spaces, the Navigator guarantees clear, deterministic order placement.

Drag & Drop#

Drag and drop in the Navigator uses standard HTML5 drag events optimized with visual insertion indicators.

Drag Handles & Drop Indicators

Each non-locked layer row displays a six-dot grip handle (IcoDots):

  • Drag Start: Clicking and dragging the grip sets dragInfo.nodeId and marks the row with .is-dragging (reduced opacity).
  • Drag Over & Half-Height Calculation: As the mouse hovers over potential target rows, the client Y coordinate is evaluated against the target's midpoint:
    ts (Drop Position Calculation)
    const r = e.currentTarget.getBoundingClientRect();
    const position = e.clientY < r.top + r.height / 2 ? 'before' : 'after';
  • Visual Drop Guide:
    • .is-drop-before: Draws a high-contrast 2px accent indicator line along the top border of the target node.
    • .is-drop-after: Draws a high-contrast 2px accent indicator line along the bottom border of the target node.
  • Drop Execution: On mouse release, store.moveNodeTo(sourceId, targetId, position) reorders the tree and clears drop indicators.

Drop Rules & Boundaries

  • Sections: Can be reordered among sections at the document root.
  • Containers & Columns: Can be reordered before or after sibling containers or columns.
  • Widgets: Can be moved before or after any element within the same container, or moved across different containers and columns.
  • Locked Elements: Cannot be dragged. Attempting to drag a locked element cancels the event immediately (draggable={!isLocked}).

Canvas Synchronization#

The Navigator and Canvas maintain strict, bidirectional synchronization powered by the central editorStore.

Two-Way Selection Sync

  • Canvas to Navigator: When a user clicks any element on the visual canvas, setSelectedId(node.id) is dispatched. The Navigator row corresponding to that node is automatically highlighted, and its parent branches are expanded if collapsed.
  • Navigator to Canvas: Clicking any row in the Navigator sets selectedId, immediately scrolling the canvas to reveal the element and painting its active boundary frame.

Immediate DOM Updates & History

When an element is dropped into a new position in the Navigator, the store invokes the tree mutation helper:

ts (editorStore.ts moveNodeTo)
const moveNodeTo = useCallback((nodeId: string, targetId: string, position: 'before' | 'after') => {
  setState((prev) => {
    const newSections = moveNodeInTree(prev.pageData.sections, nodeId, targetId, position);
    if (newSections === prev.pageData.sections) return prev;
    const newData = { ...prev.pageData, sections: newSections };
    return { ...prev, pageData: newData, isDirty: true, ...mkHistory(prev, newData, 'Move') };
  });
}, []);

This delivers three critical guarantees:

  1. Zero Desync: Both the Canvas and the Navigator derive from the single source of truth: state.pageData.sections.
  2. Full Undo/Redo: Reordering via Navigator logs a 'Move' history step. Pressing Ctrl+Z immediately restores the previous node positions.
  3. Dirty Flag Tracking: isDirty: true activates the Save/Publish button in the top navigation bar.

Responsive Behavior#

The Navigator adapts cleanly across various screen sizes and editor viewport states:

1. Desktop Docking (1024px and above)

On standard desktop monitors, the Navigator lives within the docked right Inspector sidebar. The canvas occupies the central viewport, while the Navigator stays pinned to the right. The resizable panel divider lets developers expand the tree width to view deeply nested branches comfortably.

2. Tablet & Mobile Drawer (below 1024px)

On compact screens and tablets, the editor automatically transforms sidebars into slide-over modal drawers. Toggling the Outline tab slides the Navigator over the canvas, allowing full structural reordering and element selection on touch devices without cluttering the canvas editing area.

3. Breakpoint Preview Synchronization

When switching between Desktop, Tablet, and Mobile preview modes using the top bar device switcher, the Navigator tree retains its state. If an element has been hidden specifically on mobile using responsive display settings (node.hideOn.mobile = true), the Navigator row reflects this state when previewing in mobile mode.

Developer Information#

This section documents the internal technical architecture of the Navigator for developers extending or contributing to Jalpi Page Builder.

Component Architecture

The Navigator is implemented across four primary React components located in admin/editor/src/components/layers/ and admin/editor/src/:

ComponentFile PathRole
LayersPaneladmin/editor/src/components/layers/LayersPanel.tsxRoot container. Houses header search input, expand/collapse all controls, add section action, and manages drag/drop coordination.
LayerRowadmin/editor/src/components/layers/LayersPanel.tsxRecursive tree row component. Renders drag handle, expand chevron, type icon, inline label, and quick action buttons. Recursively renders children.
CtxMenuadmin/editor/src/components/layers/LayersPanel.tsxFloating context menu for right-click interactions. Bound to viewport coordinates with boundary collision detection.
App.tsxadmin/editor/src/App.tsxMounts LayersPanel within .jalpi-inspector-body when inspTab === 'outline'.

Node Data Model (CBNode)

Every node displayed in the Navigator adheres to the core CBNode TypeScript interface defined in admin/editor/src/types/index.ts:

ts (Node Type Definition)
export interface CBNode {
  id: string;                               // Unique string identifier (e.g. "sec-1712345678")
  type: string;                             // "section" | "container" | "column" | "heading" | ...
  content?: Record<string, unknown>;        // Text, shortcode, image URL, button label
  settings?: Record<string, unknown>;       // CSS styles, typography, spacing, backgrounds
  children?: CBNode[];                      // Recursive array of child nodes
  locked?: boolean;                         // True if locked from editing / dragging
  hideOn?: {                                // Responsive breakpoint visibility flags
    desktop?: boolean;
    tablet?: boolean;
    mobile?: boolean;
  };
}

State Management & Store Actions

The Navigator consumes the useEditorStore custom hook. Key store methods utilized by the Navigator include:

Store MethodSignatureNavigator Usage
selectNode(id: string) => voidDispatches active selection to canvas and inspector.
moveNodeTo(nodeId: string, targetId: string, pos: 'before' | 'after') => voidReorders node within tree structure and updates undo history.
duplicateNode(id: string) => voidDeep-clones target node and inserts adjacent duplicate.
copyNode(id: string) => voidCopies node JSON into editor internal clipboard state.
deleteNode(id: string) => voidRemoves node and children from document.
lockNode(id: string, locked: boolean) => voidToggles node locked status.
toggleNodeVisibility(id: string) => voidToggles device visibility flags.
addSection() => voidAppends a new blank section to the bottom of the page.

Public APIs & Extension Points

Public Extension API Notice

Navigator-specific public extension APIs are not currently available.

The Navigator is currently bundled as an internal core React component inside the Jalpi Page Builder editor. Third-party developers cannot currently register custom Navigator tree rows, context menu items, or custom drag-drop decorators via external JavaScript window APIs.

Upcoming Navigator Capabilities

The Jalpi Page Builder roadmap includes the following planned enhancements for the Navigator:

Planned FeatureStatusDescription
Multi-Node SelectionπŸ”’ Coming SoonHold Shift or Ctrl/⌘ to select multiple layers simultaneously for bulk moving, locking, or deletion.
Custom Tree Badges & Labels APIπŸ”’ Coming SoonJavaScript extension hooks to append custom status badges (e.g. A/B test variant flags, dynamic tag indicators) onto tree rows.
Detachable Floating WindowπŸ”’ Coming SoonAbility to undock the Navigator into a floating, draggable window anywhere on the screen or onto a secondary display.

Last updated: November 2026