import { NoAccess } from '@/components/crm/NoAccess';
import { noAccessText, type NoAccessArea } from './noAccess';

/** #469: an admin-only settings URL opened without the permission, with the reason on the page. */
export function SettingsDenied({ title, area }: { title: string; area: NoAccessArea }) {
  return <NoAccess title={title}>{noAccessText(area)}</NoAccess>;
}
