Toast Component Base
This class is the base for different types of toast-components and contains all necesserary logic except the content-related aspects. This way, different types of toasts with specific DSL variations can be implemented by inheriting from this base class and implementing the rendering logic exposed via the avstract renderContent method.
Currently, the following comppnents are part of the toast family:
ToastComponent (created via toast and showToast)
AlertToastComponent (created via alertToast and showAlertToast)
See the respective subclass's documentation for more information and concrete usage examples.
Constructors
Types
This class defines helpful methods to either close all currently open (closeAllToasts) or the last created toast (closeLastToast) which can be called via the companion objects of both ToastComponent and AlertToastComponent.
Functions
This method registers one toast at the central toast store and creates a rendering expression that will be executed by the central rendering in the companion's object ToastComponentBase.Companion init block.