codify extension points docs (#1947)

This pull request converts the current incomplete textual documentation of the available frontend extension points to in-code definitions that act both as documentation and as type helpers for improving overall code quality. All extension points available in the SCM-Manager core are now available, but no plugin was updated and only those parts of the core codebase had the new types added that did not require runtime changes. The only exception to this is the breadcrumbs, which was a simple change that is fully backwards-compatible.
This commit is contained in:
Konstantin Schaper
2022-03-29 15:04:14 +02:00
committed by GitHub
parent 5006e9b821
commit 4d203ff36f
55 changed files with 962 additions and 430 deletions

View File

@@ -22,7 +22,7 @@
* SOFTWARE.
*/
import { binder } from "@scm-manager/ui-extensions";
import { binder, extensionPoints } from "@scm-manager/ui-extensions";
import { ConfigurationBinder as cfgBinder } from "@scm-manager/ui-components";
import ProtocolInformation from "./ProtocolInformation";
import SvnAvatar from "./SvnAvatar";
@@ -32,7 +32,11 @@ const svnPredicate = (props: any) => {
return props.repository && props.repository.type === "svn";
};
binder.bind("repos.repository-details.information", ProtocolInformation, svnPredicate);
binder.bind<extensionPoints.RepositoryDetailsInformation>(
"repos.repository-details.information",
ProtocolInformation,
svnPredicate
);
binder.bind("repos.repository-avatar", SvnAvatar, svnPredicate);
// bind global configuration