@@ -101,6 +101,37 @@ export const GanttConfigSchema = z.object({
101101 dependenciesField : z . string ( ) . optional ( ) ,
102102} ) ;
103103
104+ /**
105+ * Navigation Mode Enum
106+ * Defines how to navigate to the detail view from a list item.
107+ */
108+ export const NavigationModeSchema = z . enum ( [
109+ 'page' , // Navigate to a new route (default)
110+ 'drawer' , // Open details in a side drawer/panel
111+ 'modal' , // Open details in a modal dialog
112+ 'split' , // Show details side-by-side with the list (master-detail)
113+ 'popover' , // Show details in a popover (lightweight)
114+ 'new_window' , // Open in new browser tab/window
115+ 'none' // No navigation (read-only list)
116+ ] ) ;
117+
118+ /**
119+ * Navigation Configuration Schema
120+ */
121+ export const NavigationConfigSchema = z . object ( {
122+ mode : NavigationModeSchema . default ( 'page' ) ,
123+
124+ /** Target View Config */
125+ view : z . string ( ) . optional ( ) . describe ( 'Name of the form view to use for details (e.g. "summary_view", "edit_form")' ) ,
126+
127+ /** Interaction Triggers */
128+ preventNavigation : z . boolean ( ) . default ( false ) . describe ( 'Disable standard navigation entirely' ) ,
129+ openNewTab : z . boolean ( ) . default ( false ) . describe ( 'Force open in new tab (applies to page mode)' ) ,
130+
131+ /** Dimensions (for modal/drawer) */
132+ width : z . union ( [ z . string ( ) , z . number ( ) ] ) . optional ( ) . describe ( 'Width of the drawer/modal (e.g. "600px", "50%")' ) ,
133+ } ) ;
134+
104135/**
105136 * List View Schema (Expanded)
106137 * Defines how a collection of records is displayed to the user.
@@ -169,6 +200,9 @@ export const ListViewSchema = z.object({
169200 /** Selection */
170201 selection : SelectionConfigSchema . optional ( ) . describe ( 'Row selection configuration' ) ,
171202
203+ /** Navigation / Interaction */
204+ navigation : NavigationConfigSchema . optional ( ) . describe ( 'Configuration for item click navigation (page, drawer, modal, etc.)' ) ,
205+
172206 /** Pagination */
173207 pagination : PaginationConfigSchema . optional ( ) . describe ( 'Pagination configuration' ) ,
174208
@@ -279,6 +313,7 @@ export type FormSection = z.infer<typeof FormSectionSchema>;
279313export type ListColumn = z . infer < typeof ListColumnSchema > ;
280314export type FormField = z . infer < typeof FormFieldSchema > ;
281315export type SelectionConfig = z . infer < typeof SelectionConfigSchema > ;
316+ export type NavigationConfig = z . infer < typeof NavigationConfigSchema > ;
282317export type PaginationConfig = z . infer < typeof PaginationConfigSchema > ;
283318export type ViewData = z . infer < typeof ViewDataSchema > ;
284319export type HttpRequest = z . infer < typeof HttpRequestSchema > ;
0 commit comments