Member Junction
    Preparing search index...

    Resolves the inline-PREVIEW component for an artifact, INDEPENDENTLY of full-viewer resolution.

    The full viewer (ArtifactTypePluginViewerComponent) resolves by the artifact type's DriverClass. The inline preview, by contrast, is resolved by enumerating every registered artifact-viewer plugin CLASS and picking the highest-priority one that BOTH:

    1. exposes a static PreviewComponentType, AND
    2. returns true from its static CanHandlePreview(typeName, contentType).

    The preview contract is read STATICALLY — the resolver NEVER instantiates a plugin. Plugins are Angular components with DI constructors (and some use inject() in field initializers), so a bare new SubClass() outside an Angular injection context throws ("inject() must be called from an injection context"). Reading statics off the registered constructor sidesteps that entirely.

    Why independent: a downstream plugin can override the full VIEWER for a type without supplying a PreviewComponentType — that must NOT suppress a base plugin's preview. Conversely a broad viewer can coexist with a specialized preview. By resolving the preview slot on its own, neither decision constrains the other.

    Ordering mirrors ClassFactory.GetRegistration: highest Priority wins, and on a tie the LAST-registered plugin wins (later registrations auto-increment priority, so this is rarely a tie).

    Index

    Constructors

    Methods

    • Returns the preview component type for the given artifact type/content, or null when no registered plugin class exposes a matching static PreviewComponentType (caller falls back to its box).

      Parameters

      • artifactTypeName: string | null | undefined

        The artifact's type name (e.g. from artifact.Type).

      • contentType: string | null | undefined

        The version MIME type (e.g. from artifactVersion.MimeType).

      Returns Type<IArtifactPreviewComponent> | null