Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Orion/Documentation/Developer Guide/Plugging into Orion pages
Overview of plugging into Orion pages
The following services allow plugins to contribute links and other forms of connectivity between an Orion page and other web pages.
orion.page.link
The link service provides a mechanism for plugins to add links that should appear in the main header of Orion pages. Clients supply the link name and URL. The header code will look for implementors of this service when generating page headers for Orion. For example, the following snippet defines the main links that are shown in a default Orion installation.
provider.registerServiceProvider("orion.page.link", serviceImpl, { name: "Navigator", id: "orion.navigator", href: "/navigate/table.html#" }); provider.registerServiceProvider("orion.page.link", serviceImpl, { name: "Sites", id: "orion.sites", href: "/sites/sites.html" }); provider.registerServiceProvider("orion.page.link", serviceImpl, { name: "Plugins", id: "orion.plugins", href: "/plugin/list.html" }); provider.registerServiceProvider("orion.page.link", serviceImpl, { name: "Repositories", id: "orion.repositories", href: "/git/git-clone.html" });
The related link service provides a mechanism for plugins to contribute links to the "Related pages" menu in the Orion page header. Currently, a related link must first be defined as a command in "orion.navigate.command." Then, the command id should be referenced in the service definition for the "orion.page.link.related" extension. When any page is loaded in Orion, it will evaluate its resource against the validationProperties for the command. If the page's resource is valid for the command, then the command will appear in "Related pages."