Add ui-router to Horizon
Horizon currently uses ngRoute for angularjs routing. This has a limitation that it can only control a single ng-view at a time. It cannot control nested ng-views - that is:
html <ng-view>
html <ng-view>
html
This has become a burdensome restriction on the Swift UI where the design of the code is overly complex because of the lack of nesting. The top view (selected container) and the nested view (selected folder) must know about each other in complex ways in order to keep consistent. A single view might be used that simplified things, but would result in re-loading the container information on every folder path change.
The solution is to switch to ui-router <https:/
$stateProvider
.state(
url: "/containers",
})
.state(
url: "/:container",
})
.state(
url: "/*folder",
});
Concrete steps to take:
0. bundle ui-router as an xstatic package for testing
1. create a Proof Of Concept patch using ui-router
2. assuming #1 is a success migrate Swift UI to use ui-router
Blueprint information
- Status:
- Started
- Approver:
- Rob Cresswell
- Priority:
- Medium
- Drafter:
- Richard Jones
- Direction:
- Approved
- Assignee:
- None
- Definition:
- Approved
- Series goal:
- Accepted for future
- Implementation:
- Needs Code Review
- Milestone target:
- next
- Started by
- Richard Jones
- Completed by
Related branches
Related bugs
Sprints
Whiteboard
Gerrit topic: https:/
Addressed by: https:/
WIP: use ui-router for swift ui panel construction
Gerrit topic: https:/
Addressed by: https:/
Migrate Swift to use ResourceType
Addressed by: https:/
WIP: expose more of Swift to ResourceType
Questions in irc on if this provides ways to extend or change certain behaviors. It's not yet clear as to what this might make possible for extension points, but it is worth some thought / examination.