<?php
declare(strict_types=1);

class HelpController
{
    private static function layout(): string
    {
        return Auth::check() ? 'base' : 'docs';
    }

    private static function view(string $name): string
    {
        return Lang::current() === 'de' ? 'help/' . $name : 'help/en/' . $name;
    }

    public static function index(): void
    {
        view(self::view('index'), [], self::layout());
    }

    public static function groupAdmin(): void
    {
        view(self::view('group-admin'), [], self::layout());
    }

    public static function projectManager(): void
    {
        view(self::view('project-manager'), [], self::layout());
    }

    public static function taskWorker(): void
    {
        view(self::view('task-worker'), [], self::layout());
    }

    public static function external(): void
    {
        view(self::view('external'), [], 'docs');
    }

    public static function notifications(): void
    {
        view(self::view('notifications'), [], self::layout());
    }
}
