namespace LanMountainDesktop.AirAppSdk;
///
/// Context provided to an AirApp desktop component instance.
///
public interface IAirAppComponentContext
{
///
/// Gets the component identifier.
///
string ComponentId { get; }
///
/// Gets the unique placement identifier for this component instance.
///
string PlacementId { get; }
///
/// Gets the current width in grid cells.
///
int Width { get; }
///
/// Gets the current height in grid cells.
///
int Height { get; }
///
/// Gets the service provider for this component.
///
IServiceProvider Services { get; }
///
/// Gets the appearance context.
///
IAirAppAppearanceContext Appearance { get; }
///
/// Request a window to be opened.
///
/// Window identifier
Task OpenWindowAsync(string windowId);
///
/// Send a message to other components or AirApps.
///
/// Message topic
/// Message payload
void SendMessage(string topic, object? payload = null);
///
/// Subscribe to messages.
///
/// Message topic
/// Message handler
/// Subscription token for unsubscribing
IDisposable Subscribe(string topic, Action