Member Junction
    Preparing search index...

    Class BaseArtifactPreviewComponentAbstract

    Thin abstract base for inline artifact PREVIEW components.

    Deliberately does NOT extend the heavy BaseArtifactViewerPluginComponent — previews are lightweight, read-only, and have no toolbar / feedback / tabs / snapshot contract. They render a compact representation of the artifact inside a conversation message card.

    Content resolution (inline data-URL vs. file-storage download URL) is shared with the full viewers via the injected ArtifactFileService, so previews and viewers load bytes the same way. Subclasses call resolveContentUrl in their ngOnInit.

    Hierarchy (View Summary)

    Implements

    Index

    Constructors

    Properties

    artifactVersion: MJArtifactVersionEntity

    The artifact version to preview. Set by the resolver before the component renders.

    fileService: ArtifactFileService = ...

    Shared service used by both previews and full viewers to fetch file-mode download URLs.

    Provider: IMetadataProvider | null

    If specified, this provider will be used for communication and for all metadata purposes. By default, if not provided, the Metadata and RunView classes are used for this and the default GraphQLDataProvider is used which is connected to the same back-end MJAPI instance as the Metadata and RunView classes. If you want to have this component connect to a different MJAPI back-end, create an instance of a ProviderBase sub-class like GraphQLDataProvider/etc, and configure it as appropriate to connect to the MJAPI back-end you want to use, and then pass it in here.

    "ɵdir": unknown
    "ɵfac": unknown

    Accessors

    • get ProviderToUse(): IMetadataProvider

      Returns either the default Metadata provider or the one specified in the Provider property, if it was specified

      Returns IMetadataProvider

    • get RunQueryToUse(): IRunQueryProvider

      Returns either the default RunQuery provider or the one specified in the Provider property, if it was specified

      Returns IRunQueryProvider

    • get RunReportToUse(): IRunReportProvider

      Returns either the default RunReport provider or the one specified in the Provider property, if it was specified

      Returns IRunReportProvider

    • get RunViewToUse(): IRunViewProvider

      Returns either the default RunView provider or the one specified in the Provider property, if it was specified

      Returns IRunViewProvider

    Methods

    • Resolve a URL to bind to a media element (<img>, <video>, <audio>):

      • ContentMode === 'File' → fetch a pre-authenticated download URL from MJStorage.
      • otherwise ('Text') → Content is already a data:<mime>;base64,… URI; bind directly.

      Returns null when there is no usable content (caller should show its own empty/error state).

      Returns Promise<string | null>