{
  "page_ir": {
    "page_id": "admin_routes",
    "page_goal": "Admin page to manage bus routes with CRUD operations, search/filter, and pagination",
    "style": {
      "tone": "professional",
      "theme": "light",
      "density": "comfortable",
      "color_intent": "neutral with primary accents"
    },
    "accessibility": {
      "required_labels": [
        "search_input",
        "filter_status",
        "route_form_fields",
        "action_buttons"
      ],
      "skip_navigation": true,
      "focus_management": true,
      "announce_changes": []
    },
    "responsive": {
      "breakpoints": {
        "sm": 576,
        "md": 768,
        "lg": 992,
        "xl": 1200
      },
      "collapse_rules": [
        "sidebar collapses to hamburger on sm/md"
      ],
      "hidden_on_small": [
        "sidebar"
      ],
      "stack_on_small": []
    },
    "constraints": [
      "admin role required",
      "authenticated users only"
    ],
    "seo_title": null,
    "seo_description": null
  },
  "data_ir": {
    "types": {},
    "state": {
      "routes": {
        "type": "array",
        "initial": [],
        "required": true,
        "constraints": {},
        "item_type": null
      },
      "loading": {
        "type": "boolean",
        "initial": false,
        "required": false,
        "constraints": {},
        "item_type": null
      },
      "modalVisible": {
        "type": "boolean",
        "initial": false,
        "required": false,
        "constraints": {},
        "item_type": null
      },
      "editingRoute": {
        "type": "object",
        "initial": null,
        "required": false,
        "constraints": {},
        "item_type": null
      },
      "searchText": {
        "type": "string",
        "initial": "",
        "required": false,
        "constraints": {},
        "item_type": null
      },
      "filterIsActive": {
        "type": "string",
        "initial": "",
        "required": false,
        "constraints": {},
        "item_type": null
      },
      "pagination": {
        "type": "object",
        "initial": {
          "current": 1,
          "pageSize": 20,
          "total": 0
        },
        "required": false,
        "constraints": {},
        "item_type": null
      },
      "deleteConfirmVisible": {
        "type": "boolean",
        "initial": false,
        "required": false,
        "constraints": {},
        "item_type": null
      },
      "deletingRouteId": {
        "type": "string",
        "initial": null,
        "required": false,
        "constraints": {},
        "item_type": null
      }
    },
    "derived": {
      "isEditing": {
        "type": "boolean",
        "expr": "state.editingRoute !== null",
        "deps": []
      },
      "modalTitle": {
        "type": "string",
        "expr": "state.editingRoute ? 'Edit Route' : 'Add Route'",
        "deps": []
      }
    }
  },
  "data_fetch_ir": {
    "endpoints": {
      "4c4069eecb6646a895f73c9c18b3d6c9": {
        "endpoint_id": "4c4069eecb6646a895f73c9c18b3d6c9",
        "module": "Routes",
        "endpoint": "/routes/",
        "method": "GET",
        "path_params": {},
        "query_params": {
          "limit": "$state.pagination.pageSize",
          "offset": "($state.pagination.current - 1) * $state.pagination.pageSize",
          "origin_city": "$state.searchText || undefined",
          "is_active": "$state.filterIsActive || undefined"
        },
        "body": null,
        "fields": [
          "id",
          "origin_city",
          "destination_city",
          "distance_km",
          "estimated_duration_minutes",
          "is_active",
          "created_at",
          "updated_at"
        ],
        "response_target": "routes",
        "response_transform": null,
        "trigger": "on_mount",
        "depends_on": [],
        "debounce_ms": null,
        "loading_field": null,
        "error_field": null
      },
      "bbff3ebc5ae44717842140a8ba85d0f3": {
        "endpoint_id": "bbff3ebc5ae44717842140a8ba85d0f3",
        "module": "Routes",
        "endpoint": "/routes/",
        "method": "POST",
        "path_params": {},
        "query_params": {},
        "body": {},
        "fields": [
          "id",
          "origin_city",
          "destination_city",
          "distance_km",
          "estimated_duration_minutes",
          "is_active",
          "created_at",
          "updated_at"
        ],
        "response_target": "createRoute_data",
        "response_transform": null,
        "trigger": "manual",
        "depends_on": [],
        "debounce_ms": null,
        "loading_field": null,
        "error_field": null
      },
      "87b3afffb7ff4849a95073d7cc3d06b7": {
        "endpoint_id": "87b3afffb7ff4849a95073d7cc3d06b7",
        "module": "Routes",
        "endpoint": "/routes/{route_id}",
        "method": "PUT",
        "path_params": {
          "route_id": "$state.editingRoute.id"
        },
        "query_params": {},
        "body": {},
        "fields": [
          "id",
          "origin_city",
          "destination_city",
          "distance_km",
          "estimated_duration_minutes",
          "is_active",
          "created_at",
          "updated_at"
        ],
        "response_target": "87b3afffb7ff4849a95073d7cc3d06b7_data",
        "response_transform": null,
        "trigger": "manual",
        "depends_on": [],
        "debounce_ms": null,
        "loading_field": null,
        "error_field": null
      },
      "62594bbbde844801b1b4d3b501833c7f": {
        "endpoint_id": "62594bbbde844801b1b4d3b501833c7f",
        "module": "Routes",
        "endpoint": "/routes/{route_id}",
        "method": "DELETE",
        "path_params": {
          "route_id": "$state.deletingRouteId"
        },
        "query_params": {},
        "body": null,
        "fields": [],
        "response_target": "62594bbbde844801b1b4d3b501833c7f_data",
        "response_transform": null,
        "trigger": "manual",
        "depends_on": [],
        "debounce_ms": null,
        "loading_field": null,
        "error_field": null
      }
    }
  },
  "data_model_ir": {
    "entities": {
      "route": {
        "name": "Route",
        "backend_module": "Routes",
        "fields": [
          "id",
          "origin_city",
          "destination_city",
          "distance_km",
          "estimated_duration_minutes",
          "is_active",
          "created_at",
          "updated_at"
        ],
        "computed": [],
        "display_fields": [
          "id",
          "origin_city",
          "destination_city",
          "distance_km",
          "estimated_duration_minutes",
          "is_active",
          "created_at"
        ],
        "search_fields": [
          "origin_city",
          "destination_city"
        ],
        "filters": [
          "origin_city",
          "destination_city",
          "is_active"
        ],
        "default_sort": null,
        "default_sort_dir": "asc"
      }
    },
    "relationships": []
  },
  "behaviour_ir": {
    "events": {
      "onSearchChange": {
        "type": "mutation",
        "updates": [
          {
            "target": "state.searchText",
            "expr": "event.target.value"
          },
          {
            "target": "state.pagination.current",
            "expr": "1"
          }
        ],
        "description": ""
      },
      "onFilterChange": {
        "type": "mutation",
        "updates": [
          {
            "target": "state.filterIsActive",
            "expr": "value"
          },
          {
            "target": "state.pagination.current",
            "expr": "1"
          }
        ],
        "description": ""
      },
      "onPaginationChange": {
        "type": "mutation",
        "updates": [
          {
            "target": "state.pagination.current",
            "expr": "page"
          },
          {
            "target": "state.pagination.pageSize",
            "expr": "pageSize"
          }
        ],
        "description": ""
      },
      "openAddModal": {
        "type": "mutation",
        "updates": [
          {
            "target": "state.modalVisible",
            "expr": "true"
          },
          {
            "target": "state.editingRoute",
            "expr": "null"
          }
        ],
        "description": ""
      },
      "openEditModal": {
        "type": "mutation",
        "updates": [
          {
            "target": "state.modalVisible",
            "expr": "true"
          },
          {
            "target": "state.editingRoute",
            "expr": "record"
          }
        ],
        "description": ""
      },
      "closeModal": {
        "type": "mutation",
        "updates": [
          {
            "target": "state.modalVisible",
            "expr": "false"
          },
          {
            "target": "state.editingRoute",
            "expr": "null"
          }
        ],
        "description": ""
      },
      "openDeleteConfirm": {
        "type": "mutation",
        "updates": [
          {
            "target": "state.deleteConfirmVisible",
            "expr": "true"
          },
          {
            "target": "state.deletingRouteId",
            "expr": "record.id"
          }
        ],
        "description": ""
      },
      "closeDeleteConfirm": {
        "type": "mutation",
        "updates": [
          {
            "target": "state.deleteConfirmVisible",
            "expr": "false"
          },
          {
            "target": "state.deletingRouteId",
            "expr": "null"
          }
        ],
        "description": ""
      }
    },
    "actions": {
      "7aba818dbcb64705b2164417ad83e213": {
        "action_id": "7aba818dbcb64705b2164417ad83e213",
        "trigger": "form_submit",
        "target_component_id": "route_form_modal",
        "operation": "create",
        "description": "",
        "payload": {
          "form": "routeForm"
        },
        "guard": null,
        "requires_confirmation": false,
        "confirmation_message": null,
        "validation_rules": [
          {
            "rule_id": "val_0",
            "field": null,
            "type": "custom",
            "value": null,
            "expression": "{\"field\": \"origin_city\", \"message\": \"Origin city is required\", \"rule_id\": \"val_origin\", \"type\": \"required\"}",
            "message": "{\"field\": \"origin_city\", \"message\": \"Origin city is required\", \"rule_id\": \"val_origin\", \"type\": \"required\"}"
          },
          {
            "rule_id": "val_1",
            "field": null,
            "type": "custom",
            "value": null,
            "expression": "{\"field\": \"destination_city\", \"message\": \"Destination city is required\", \"rule_id\": \"val_destination\", \"type\": \"required\"}",
            "message": "{\"field\": \"destination_city\", \"message\": \"Destination city is required\", \"rule_id\": \"val_destination\", \"type\": \"required\"}"
          },
          {
            "rule_id": "val_2",
            "field": null,
            "type": "custom",
            "value": null,
            "expression": "{\"field\": \"distance_km\", \"message\": \"Distance is required\", \"rule_id\": \"val_distance\", \"type\": \"required\"}",
            "message": "{\"field\": \"distance_km\", \"message\": \"Distance is required\", \"rule_id\": \"val_distance\", \"type\": \"required\"}"
          },
          {
            "rule_id": "val_3",
            "field": null,
            "type": "custom",
            "value": null,
            "expression": "{\"field\": \"estimated_duration_minutes\", \"message\": \"Estimated duration is required\", \"rule_id\": \"val_duration\", \"type\": \"required\"}",
            "message": "{\"field\": \"estimated_duration_minutes\", \"message\": \"Estimated duration is required\", \"rule_id\": \"val_duration\", \"type\": \"required\"}"
          }
        ],
        "validation_messages": {},
        "updates": [
          {
            "target": "state.modalVisible",
            "expr": "false"
          },
          {
            "target": "state.editingRoute",
            "expr": "null"
          }
        ],
        "api_endpoint": "bbff3ebc5ae44717842140a8ba85d0f3",
        "api_body": "{ origin_city: formValues.origin_city, destination_city: formValues.destination_city, distance_km: formValues.distance_km, estimated_duration_minutes: formValues.estimated_duration_minutes, is_active: formValues.is_active }",
        "side_effects": [
          {
            "type": "toast",
            "config": {
              "message": "Route created successfully",
              "type": "success"
            }
          },
          {
            "type": "refresh",
            "config": {
              "target": "fetchRoutes"
            }
          }
        ],
        "then": null,
        "catch": null,
        "data_action": null
      },
      "87b3afffb7ff4849a95073d7cc3d06b7": {
        "action_id": "87b3afffb7ff4849a95073d7cc3d06b7",
        "trigger": "form_submit",
        "target_component_id": "route_form_modal",
        "operation": "update",
        "description": "",
        "payload": {
          "form": "routeForm"
        },
        "guard": null,
        "requires_confirmation": false,
        "confirmation_message": null,
        "validation_rules": [
          {
            "rule_id": "val_0",
            "field": null,
            "type": "custom",
            "value": null,
            "expression": "{\"field\": \"origin_city\", \"message\": \"Origin city is required\", \"rule_id\": \"val_origin_edit\", \"type\": \"required\"}",
            "message": "{\"field\": \"origin_city\", \"message\": \"Origin city is required\", \"rule_id\": \"val_origin_edit\", \"type\": \"required\"}"
          },
          {
            "rule_id": "val_1",
            "field": null,
            "type": "custom",
            "value": null,
            "expression": "{\"field\": \"destination_city\", \"message\": \"Destination city is required\", \"rule_id\": \"val_destination_edit\", \"type\": \"required\"}",
            "message": "{\"field\": \"destination_city\", \"message\": \"Destination city is required\", \"rule_id\": \"val_destination_edit\", \"type\": \"required\"}"
          },
          {
            "rule_id": "val_2",
            "field": null,
            "type": "custom",
            "value": null,
            "expression": "{\"field\": \"distance_km\", \"message\": \"Distance is required\", \"rule_id\": \"val_distance_edit\", \"type\": \"required\"}",
            "message": "{\"field\": \"distance_km\", \"message\": \"Distance is required\", \"rule_id\": \"val_distance_edit\", \"type\": \"required\"}"
          },
          {
            "rule_id": "val_3",
            "field": null,
            "type": "custom",
            "value": null,
            "expression": "{\"field\": \"estimated_duration_minutes\", \"message\": \"Estimated duration is required\", \"rule_id\": \"val_duration_edit\", \"type\": \"required\"}",
            "message": "{\"field\": \"estimated_duration_minutes\", \"message\": \"Estimated duration is required\", \"rule_id\": \"val_duration_edit\", \"type\": \"required\"}"
          }
        ],
        "validation_messages": {},
        "updates": [
          {
            "target": "state.modalVisible",
            "expr": "false"
          },
          {
            "target": "state.editingRoute",
            "expr": "null"
          }
        ],
        "api_endpoint": "87b3afffb7ff4849a95073d7cc3d06b7",
        "api_body": "{ origin_city: formValues.origin_city, destination_city: formValues.destination_city, distance_km: formValues.distance_km, estimated_duration_minutes: formValues.estimated_duration_minutes, is_active: formValues.is_active }",
        "side_effects": [
          {
            "type": "toast",
            "config": {
              "message": "Route updated successfully",
              "type": "success"
            }
          },
          {
            "type": "refresh",
            "config": {
              "target": "fetchRoutes"
            }
          }
        ],
        "then": null,
        "catch": null,
        "data_action": null
      },
      "62594bbbde844801b1b4d3b501833c7f": {
        "action_id": "62594bbbde844801b1b4d3b501833c7f",
        "trigger": "button_click",
        "target_component_id": "delete_confirm_modal",
        "operation": "delete",
        "description": "",
        "payload": {},
        "guard": null,
        "requires_confirmation": true,
        "confirmation_message": null,
        "validation_rules": [],
        "validation_messages": {},
        "updates": [
          {
            "target": "state.deleteConfirmVisible",
            "expr": "false"
          },
          {
            "target": "state.deletingRouteId",
            "expr": "null"
          }
        ],
        "api_endpoint": "62594bbbde844801b1b4d3b501833c7f",
        "api_body": null,
        "side_effects": [
          {
            "type": "toast",
            "config": {
              "message": "Route deleted successfully",
              "type": "success"
            }
          },
          {
            "type": "refresh",
            "config": {
              "target": "fetchRoutes"
            }
          }
        ],
        "then": null,
        "catch": null,
        "data_action": null
      },
      "ae45eb930eaf4c9bb99487f449dda883": {
        "action_id": "ae45eb930eaf4c9bb99487f449dda883",
        "trigger": "button_click",
        "target_component_id": "routes_table",
        "operation": "read",
        "description": "",
        "payload": {},
        "guard": null,
        "requires_confirmation": false,
        "confirmation_message": null,
        "validation_rules": [],
        "validation_messages": {},
        "updates": [
          {
            "target": "state.loading",
            "expr": "true"
          }
        ],
        "api_endpoint": "4c4069eecb6646a895f73c9c18b3d6c9",
        "api_body": null,
        "side_effects": [],
        "then": null,
        "catch": null,
        "data_action": null
      }
    },
    "feedback": {
      "7aba818dbcb64705b2164417ad83e213": {
        "action_id": "7aba818dbcb64705b2164417ad83e213",
        "loading_indicator": "spinner",
        "loading_text": null,
        "success_message": "Route created successfully",
        "error_message": "Failed to create route",
        "ui_updates": []
      },
      "87b3afffb7ff4849a95073d7cc3d06b7": {
        "action_id": "87b3afffb7ff4849a95073d7cc3d06b7",
        "loading_indicator": "spinner",
        "loading_text": null,
        "success_message": "Route updated successfully",
        "error_message": "Failed to update route",
        "ui_updates": []
      },
      "62594bbbde844801b1b4d3b501833c7f": {
        "action_id": "62594bbbde844801b1b4d3b501833c7f",
        "loading_indicator": "spinner",
        "loading_text": null,
        "success_message": "Route deleted successfully",
        "error_message": "Failed to delete route. It may have existing schedules.",
        "ui_updates": []
      },
      "ae45eb930eaf4c9bb99487f449dda883": {
        "action_id": "ae45eb930eaf4c9bb99487f449dda883",
        "loading_indicator": "skeleton",
        "loading_text": null,
        "success_message": null,
        "error_message": "Failed to load routes",
        "ui_updates": []
      }
    }
  },
  "component_ir": {
    "library": "antd",
    "theme": {
      "primaryColor": "#1677ff",
      "secondaryColor": "#000000",
      "successColor": null,
      "warningColor": null,
      "errorColor": null,
      "fontFamily": "sans-serif",
      "fontSize": null,
      "borderRadius": 6
    },
    "components": {
      "main_container": {
        "type": "Layout",
        "label": null,
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {},
        "dynamic_props": {},
        "styles": {
          "minHeight": "100vh",
          "width": "100%"
        },
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "admin_sidebar": {
        "type": "Layout.Sider",
        "label": "Admin Navigation",
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "width": 240,
          "collapsible": true,
          "theme": "light"
        },
        "dynamic_props": {},
        "styles": {
          "borderRight": "1px solid #f0f0f0"
        },
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "sidebar_menu": {
        "type": "Menu",
        "label": "Admin Menu",
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "mode": "inline",
          "selectedKeys": [
            "routes"
          ],
          "items": [
            {
              "key": "dashboard",
              "label": "Dashboard",
              "icon": "DashboardOutlined",
              "path": "/admin"
            },
            {
              "key": "routes",
              "label": "Routes",
              "icon": "NodeIndexOutlined",
              "path": "/admin/routes"
            },
            {
              "key": "buses",
              "label": "Buses",
              "icon": "CarOutlined",
              "path": "/admin/buses"
            },
            {
              "key": "schedules",
              "label": "Schedules",
              "icon": "ScheduleOutlined",
              "path": "/admin/schedules"
            },
            {
              "key": "bookings",
              "label": "Bookings",
              "icon": "BookOutlined",
              "path": "/admin/bookings"
            },
            {
              "key": "reservations",
              "label": "Reservations",
              "icon": "ClockCircleOutlined",
              "path": "/admin/reservations"
            },
            {
              "key": "activity_logs",
              "label": "Activity Logs",
              "icon": "FileTextOutlined",
              "path": "/admin/activity-logs"
            },
            {
              "key": "users",
              "label": "Users",
              "icon": "UserOutlined",
              "path": "/admin/users"
            }
          ]
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "content_area": {
        "type": "Layout.Content",
        "label": null,
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {},
        "dynamic_props": {},
        "styles": {
          "padding": "24px",
          "background": "#f5f5f5",
          "flex": 1
        },
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "page_header": {
        "type": "div",
        "label": null,
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {},
        "dynamic_props": {},
        "styles": {
          "display": "flex",
          "justifyContent": "space-between",
          "alignItems": "center",
          "marginBottom": "24px"
        },
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "page_title": {
        "type": "Typography.Title",
        "label": "Route Management",
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "level": 3
        },
        "dynamic_props": {},
        "styles": {
          "margin": 0
        },
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "add_route_button": {
        "type": "Button",
        "label": "Add Route",
        "description": null,
        "bind": null,
        "onClick": "openAddModal",
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "type": "primary",
          "icon": "PlusOutlined",
          "size": "middle"
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "filter_bar": {
        "type": "div",
        "label": null,
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {},
        "dynamic_props": {},
        "styles": {
          "display": "flex",
          "gap": "16px",
          "marginBottom": "16px",
          "flexWrap": "wrap"
        },
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "search_input": {
        "type": "Input.Search",
        "label": "Search by city",
        "description": null,
        "bind": "state.searchText",
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "placeholder": "Search by city name...",
          "allowClear": true,
          "style": {
            "width": 300
          }
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "status_filter": {
        "type": "Select",
        "label": "Filter by status",
        "description": null,
        "bind": "state.filterIsActive",
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "placeholder": "Filter by status",
          "allowClear": true,
          "style": {
            "width": 180
          },
          "options": [
            {
              "label": "Active",
              "value": "true"
            },
            {
              "label": "Inactive",
              "value": "false"
            }
          ]
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "routes_table": {
        "type": "Table",
        "label": "Routes Table",
        "description": null,
        "bind": "state.routes",
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "rowKey": "id",
          "loading": "state.loading",
          "pagination": {
            "current": "state.pagination.current",
            "pageSize": "state.pagination.pageSize",
            "total": "state.pagination.total",
            "showSizeChanger": true,
            "showTotal": true
          },
          "columns": [
            {
              "title": "Route ID",
              "dataIndex": "id",
              "key": "id",
              "width": 100,
              "ellipsis": true
            },
            {
              "title": "Origin City",
              "dataIndex": "origin_city",
              "key": "origin_city",
              "sorter": true
            },
            {
              "title": "Destination City",
              "dataIndex": "destination_city",
              "key": "destination_city",
              "sorter": true
            },
            {
              "title": "Distance (km)",
              "dataIndex": "distance_km",
              "key": "distance_km",
              "sorter": true
            },
            {
              "title": "Duration (min)",
              "dataIndex": "estimated_duration_minutes",
              "key": "estimated_duration_minutes",
              "sorter": true
            },
            {
              "title": "Status",
              "dataIndex": "is_active",
              "key": "is_active",
              "render": "badge"
            },
            {
              "title": "Created At",
              "dataIndex": "created_at",
              "key": "created_at",
              "render": "date"
            },
            {
              "title": "Actions",
              "key": "actions",
              "render": "action_buttons",
              "width": 120
            }
          ]
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "edit_action_button": {
        "type": "Button",
        "label": "Edit",
        "description": null,
        "bind": null,
        "onClick": "openEditModal",
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "type": "link",
          "icon": "EditOutlined",
          "size": "small"
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "delete_action_button": {
        "type": "Button",
        "label": "Delete",
        "description": null,
        "bind": null,
        "onClick": "openDeleteConfirm",
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "type": "link",
          "danger": true,
          "icon": "DeleteOutlined",
          "size": "small"
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "route_form_modal": {
        "type": "Modal",
        "label": null,
        "description": null,
        "bind": "state.modalVisible",
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "title": "derived.modalTitle",
          "open": "state.modalVisible",
          "onCancel": "closeModal",
          "destroyOnClose": true,
          "width": 560
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "route_form": {
        "type": "Form",
        "label": "Route Form",
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "layout": "vertical",
          "initialValues": "state.editingRoute",
          "name": "routeForm"
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "form_origin_city": {
        "type": "Form.Item",
        "label": "Origin City",
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "name": "origin_city",
          "rules": [
            {
              "required": true,
              "message": "Please enter origin city"
            }
          ]
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "input_origin_city": {
        "type": "Input",
        "label": null,
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "placeholder": "Enter origin city"
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "form_destination_city": {
        "type": "Form.Item",
        "label": "Destination City",
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "name": "destination_city",
          "rules": [
            {
              "required": true,
              "message": "Please enter destination city"
            }
          ]
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "input_destination_city": {
        "type": "Input",
        "label": null,
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "placeholder": "Enter destination city"
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "form_distance": {
        "type": "Form.Item",
        "label": "Distance (km)",
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "name": "distance_km",
          "rules": [
            {
              "required": true,
              "message": "Please enter distance"
            }
          ]
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "input_distance": {
        "type": "InputNumber",
        "label": null,
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "placeholder": "Enter distance in km",
          "min": 0,
          "style": {
            "width": "100%"
          }
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "form_duration": {
        "type": "Form.Item",
        "label": "Estimated Duration (minutes)",
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "name": "estimated_duration_minutes",
          "rules": [
            {
              "required": true,
              "message": "Please enter estimated duration"
            }
          ]
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "input_duration": {
        "type": "InputNumber",
        "label": null,
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "placeholder": "Enter duration in minutes",
          "min": 0,
          "style": {
            "width": "100%"
          }
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "form_is_active": {
        "type": "Form.Item",
        "label": "Active",
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "name": "is_active",
          "valuePropName": "checked",
          "initialValue": true
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "input_is_active": {
        "type": "Switch",
        "label": null,
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "checkedChildren": "Active",
          "unCheckedChildren": "Inactive"
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "modal_footer": {
        "type": "div",
        "label": null,
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {},
        "dynamic_props": {},
        "styles": {
          "display": "flex",
          "justifyContent": "flex-end",
          "gap": "8px"
        },
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "cancel_button": {
        "type": "Button",
        "label": "Cancel",
        "description": null,
        "bind": null,
        "onClick": "closeModal",
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {},
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "save_button": {
        "type": "Button",
        "label": "Save",
        "description": null,
        "bind": null,
        "onClick": "submitRoute",
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "type": "primary",
          "htmlType": "submit"
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "delete_confirm_modal": {
        "type": "Modal",
        "label": null,
        "description": null,
        "bind": "state.deleteConfirmVisible",
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "title": "Confirm Delete",
          "open": "state.deleteConfirmVisible",
          "onCancel": "closeDeleteConfirm",
          "okText": "Delete",
          "okButtonProps": {
            "danger": true
          },
          "cancelText": "Cancel"
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "delete_warning_text": {
        "type": "Typography.Text",
        "label": "Are you sure you want to delete this route? This action cannot be undone. Any existing schedules associated with this route may be affected.",
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "type": "warning"
        },
        "dynamic_props": {},
        "styles": {},
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      },
      "table_card": {
        "type": "Card",
        "label": null,
        "description": null,
        "bind": null,
        "onClick": null,
        "onChange": null,
        "onSubmit": null,
        "onHover": null,
        "onKeyPress": null,
        "props": {
          "bordered": false
        },
        "dynamic_props": {},
        "styles": {
          "borderRadius": "6px"
        },
        "dynamic_styles": {},
        "class_name": null,
        "dynamic_class": null,
        "transitions": [],
        "visible_when": null,
        "disabled_when": null,
        "repeat": null,
        "slots": {},
        "a11y_role": null,
        "a11y_label": null
      }
    }
  },
  "layout_ir": {
    "root": "main_container",
    "children": {
      "main_container": [
        "admin_sidebar",
        "content_area"
      ],
      "admin_sidebar": [
        "sidebar_menu"
      ],
      "content_area": [
        "page_header",
        "table_card"
      ],
      "page_header": [
        "page_title",
        "add_route_button"
      ],
      "table_card": [
        "filter_bar",
        "routes_table"
      ],
      "filter_bar": [
        "search_input",
        "status_filter"
      ],
      "route_form_modal": [
        "route_form"
      ],
      "route_form": [
        "form_origin_city",
        "form_destination_city",
        "form_distance",
        "form_duration",
        "form_is_active",
        "modal_footer"
      ],
      "form_origin_city": [
        "input_origin_city"
      ],
      "form_destination_city": [
        "input_destination_city"
      ],
      "form_distance": [
        "input_distance"
      ],
      "form_duration": [
        "input_duration"
      ],
      "form_is_active": [
        "input_is_active"
      ],
      "modal_footer": [
        "cancel_button",
        "save_button"
      ],
      "delete_confirm_modal": [
        "delete_warning_text"
      ]
    },
    "layout": {
      "main_container": {
        "type": "horizontal",
        "gap": 0,
        "padding": null,
        "columns": null,
        "column_template": null,
        "row_template": null,
        "align_items": null,
        "justify_content": null,
        "wrap": false,
        "min_height": null,
        "overflow": null
      },
      "admin_sidebar": {
        "type": "vertical",
        "gap": 0,
        "padding": null,
        "columns": null,
        "column_template": null,
        "row_template": null,
        "align_items": null,
        "justify_content": null,
        "wrap": false,
        "min_height": null,
        "overflow": null
      },
      "content_area": {
        "type": "vertical",
        "gap": 0,
        "padding": null,
        "columns": null,
        "column_template": null,
        "row_template": null,
        "align_items": null,
        "justify_content": null,
        "wrap": false,
        "min_height": null,
        "overflow": null
      },
      "page_header": {
        "type": "horizontal",
        "gap": 16,
        "padding": null,
        "columns": null,
        "column_template": null,
        "row_template": null,
        "align_items": null,
        "justify_content": null,
        "wrap": false,
        "min_height": null,
        "overflow": null
      },
      "table_card": {
        "type": "vertical",
        "gap": 16,
        "padding": null,
        "columns": null,
        "column_template": null,
        "row_template": null,
        "align_items": null,
        "justify_content": null,
        "wrap": false,
        "min_height": null,
        "overflow": null
      },
      "filter_bar": {
        "type": "horizontal",
        "gap": 16,
        "padding": null,
        "columns": null,
        "column_template": null,
        "row_template": null,
        "align_items": null,
        "justify_content": null,
        "wrap": false,
        "min_height": null,
        "overflow": null
      },
      "route_form": {
        "type": "vertical",
        "gap": 12,
        "padding": null,
        "columns": null,
        "column_template": null,
        "row_template": null,
        "align_items": null,
        "justify_content": null,
        "wrap": false,
        "min_height": null,
        "overflow": null
      },
      "modal_footer": {
        "type": "horizontal",
        "gap": 8,
        "padding": null,
        "columns": null,
        "column_template": null,
        "row_template": null,
        "align_items": null,
        "justify_content": null,
        "wrap": false,
        "min_height": null,
        "overflow": null
      }
    },
    "layout_zones": [
      {
        "zone_id": "sidebar_zone",
        "component": "admin_sidebar",
        "anchor": "top-left",
        "size_hint": "240px",
        "z_layer": "base",
        "notes": "Fixed left sidebar for admin navigation"
      },
      {
        "zone_id": "content_zone",
        "component": "content_area",
        "anchor": "center",
        "size_hint": "auto",
        "z_layer": "base",
        "notes": "Main content area with routes table"
      },
      {
        "zone_id": "modal_zone",
        "component": "route_form_modal",
        "anchor": "center",
        "size_hint": "560px",
        "z_layer": "overlay",
        "notes": "Modal overlay for add/edit route form"
      },
      {
        "zone_id": "delete_modal_zone",
        "component": "delete_confirm_modal",
        "anchor": "center",
        "size_hint": "auto",
        "z_layer": "overlay",
        "notes": "Confirmation modal for route deletion"
      }
    ],
    "responsive_overrides": []
  },
  "navigation_ir": {
    "tabs": [],
    "modals": {},
    "drawers": {},
    "routes": [],
    "breadcrumb": null,
    "default_tab": null
  },
  "realtime_ir": {
    "timers": {},
    "polling": {}
  },
  "metadata": {
    "ir_version": "3.5",
    "generated_at": "",
    "source_prompt": null,
    "schema_session_id": null,
    "warnings": []
  },
  "page_data_contract": null,
  "schema_ir": null
}
