import { type ReactNode, type ButtonHTMLAttributes } from 'react';
import { type TooltipPosition } from './Tooltip';
/**
 * Standard CRUD actions for permission checking.
 * Maps to NavRoute permissions: {navRoute}.{action}
 */
export type PermissionAction = 'create' | 'read' | 'update' | 'delete' | 'execute';
export interface ProtectedButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
    /** The permission action required (create, read, update, delete, execute) */
    action: PermissionAction;
    /** The NavRoute path (e.g., "administration.users") */
    navRoute: string;
    /** If true, hides the button entirely when permission is denied. Default: false (shows disabled) */
    hideIfNoPermission?: boolean;
    /** Custom permission override (bypasses action + navRoute) */
    customPermission?: string;
    /** Tooltip position when disabled */
    tooltipPosition?: TooltipPosition;
    /** Custom disabled message override */
    disabledMessage?: string;
    /** Button content */
    children: ReactNode;
}
/**
 * A button component that automatically checks permissions based on NavRoute and action.
 *
 * @example
 * // Basic usage - checks "administration.users.update"
 * <ProtectedButton action="update" navRoute="administration.users" onClick={handleEdit}>
 *   Edit
 * </ProtectedButton>
 *
 * @example
 * // Hide button if no permission
 * <ProtectedButton action="delete" navRoute="administration.users" hideIfNoPermission>
 *   Delete
 * </ProtectedButton>
 *
 * @example
 * // Custom permission
 * <ProtectedButton action="execute" navRoute="administration.entra" customPermission="administration.entra.sync">
 *   Sync
 * </ProtectedButton>
 */
export declare function ProtectedButton({ action, navRoute, hideIfNoPermission, customPermission, tooltipPosition, disabledMessage, children, disabled, className, ...props }: ProtectedButtonProps): import("react/jsx-runtime").JSX.Element | null;
/**
 * Hook to check permission for a specific action on a navRoute.
 * Useful when you need to check permission without rendering a ProtectedButton.
 *
 * @example
 * const canEdit = useProtectedAction('update', 'administration.users');
 */
export declare function useProtectedAction(action: PermissionAction, navRoute: string): boolean;
//# sourceMappingURL=ProtectedButton.d.ts.map