from typing import Callable


def action(func) -> Callable:
    """
    Decorator to add the '__action__' attribute to component actions that are callable.

    :param func: Function to decorate.
    :return: Function with attribute.
    """
    func.__action__ = True
    return func