Skip to content

Modal DeprecatedJSTwig ​

Deprecated

The Modal component is deprecated and will be removed in a future release. Use the Dialog component instead — it is headless, built on the native <dialog> element and driven by Action.

The Modal component creates accessible modal dialogs with focus management, keyboard navigation, and customizable styling.

Usage ​

After you install the package, include the template in your project:

js
import { registerComponent } from '@studiometa/js-toolkit';
import { Modal } from '@studiometa/ui';

registerComponent(Modal);
twig
{% include '@ui/Modal/Modal.twig' with {
  content: 'Your modal content here'
} %}