Abstract
Constructs the plugin.
Optional
initialProps: StaticProps & ChangeablePropsInitial static and changeable properties for the plugin.
Retrieves the component to which this plugin is attached.
Sets the component for this plugin. This method is called by the parent component when the plugin is added.
Checks if the module has been destroyed.
Checks if the module has been initialized.
The name of the module, derived from the class name
Optional prefix for class names used by the module
The current properties of the module, which include both static and changeable properties. These can be retrieved dynamically during the module's lifecycle.
Adds a custom callback to the module.
Adds a DOM event listener that will be automatically removed when the module is destroyed.
The target element for the event listener.
The event type to listen for (e.g., 'click', 'resize').
The callback function to execute when the event is triggered.
Optional
options: boolean | AddEventListenerOptionsAdditional options for the event listener.
Adds responsive property rules to the module. This must be done before initialization.
The responsive property rules to be added.
Adds a viewport callback that will be automatically removed when the module is destroyed.
The viewport target (e.g., width or height).
The callback function to execute when the viewport target changes.
Additional data for the callback.
A base abstract class for Plugins that extend the functionality of components. A plugin is designed to attach to a component and modify or enhance its behavior. It inherits from the Module class and adds functionality to work with a component.