UNPKG

userpravah

Version:

UserPravah is an extensible, framework-agnostic tool for analyzing user flows and navigation patterns in web applications. It supports multiple frameworks (Angular, React) and output formats (DOT/Graphviz, JSON) with a plugin-based architecture for easy e

54 lines (53 loc) 1.23 kB
export interface Route { path: string; fullPath: string; component?: string; children?: Route[]; redirectTo?: string; loadChildren?: string; guards?: string[]; data?: Record<string, any>; isRoot?: boolean; } export interface NavigationFlow { from: string; to: string; type: 'static' | 'dynamic' | 'guard' | 'redirect' | 'hierarchy'; condition?: string; } export interface MenuDefinition { title: string; path: string; children?: MenuDefinition[]; roles?: string[]; } export interface ProcessedRouteNode { id: string; originalPath: string; displayName: string; pathDepth: number; category: string; component?: string; importance: number; isRoot?: boolean; guards?: string[]; color?: string; shape?: string; [key: string]: any; } export interface ProcessedFlowEdge { sourceNodeId: string; targetNodeId: string; type: NavigationFlow['type']; condition?: string; label?: string; style?: string; color?: string; arrowhead?: string; [key: string]: any; } export interface AnalysisResult { routes: ProcessedRouteNode[]; flows: ProcessedFlowEdge[]; menus?: MenuDefinition[]; }