Member Junction
    Preparing search index...

    Class ComposerTriggerProviderAbstract

    Pluggable mention/command trigger for the composer's mention editor.

    Each provider owns ONE trigger character (e.g. '@', '#', '/') and supplies the suggestions shown while the user types after it. The composer itself ships with ZERO providers — it is a plain text editor until providers are supplied, either:

    1. Explicitly — bind [TriggerProviders] on mj-mention-editor / mj-message-input-box with provider instances (explicit list always wins), or
    2. By discovery — register subclasses with the MJ ClassFactory via @RegisterClass(ComposerTriggerProvider, '<Key>'); the editor resolves them through DiscoverComposerTriggerProviders when no explicit list is bound. Hosts opt individual triggers out with [ExcludedTriggerKeys].

    The AI-aware providers (agent mentions, entity/query record mentions, skill commands) live in @memberjunction/ng-conversations — see its composer-plugins folder and the mj-ai-composer wrapper component.

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    Key: string

    Stable identifier for this provider (e.g. 'agent-mentions'). Used as the ClassFactory registration key and by ExcludedTriggerKeys filtering.

    Priority: number = 0

    Ordering weight — higher runs first. When multiple providers share a TriggerChar, results are concatenated in priority order (then Key order).

    TriggerChar: string

    The single character that opens this provider's autocomplete (e.g. '@').

    Methods

    • Optional warm-up hook, invoked once by the editor when it initializes with this provider active. Default is a no-op; override to pre-load caches so the first keystroke is fast. Must be safe to call repeatedly and concurrently.

      Parameters

      Returns Promise<void>