diff --git a/app/Http/Controllers/SinglePageController.php b/app/Http/Controllers/SinglePageController.php index 98a4f0f1..e80c00e1 100644 --- a/app/Http/Controllers/SinglePageController.php +++ b/app/Http/Controllers/SinglePageController.php @@ -29,6 +29,8 @@ class SinglePageController extends Controller $locales = collect(config('2fauth.locales'))->toJson(); /** @phpstan-ignore-line */ $openidAuth = config('services.openid.client_secret') ? true : false; $githubAuth = config('services.github.client_secret') ? true : false; + $installDocUrl = config('2fauth.installDocUrl'); + $ssoDocUrl = config('2fauth.ssoDocUrl'); // if (Auth::user()->preferences) @@ -43,6 +45,10 @@ class SinglePageController extends Controller ], 'subdirectory' => $subdir, ])->toJson(), + 'urls' => collect([ + 'installDocUrl' => $installDocUrl, + 'ssoDocUrl' => $ssoDocUrl + ]), 'defaultPreferences' => $defaultPreferences, 'subdirectory' => $subdir, 'isDemoApp' => $isDemoApp, diff --git a/config/2fauth.php b/config/2fauth.php index 87e40472..bbb4616f 100644 --- a/config/2fauth.php +++ b/config/2fauth.php @@ -13,6 +13,7 @@ return [ 'repository' => 'https://github.com/Bubka/2FAuth', 'latestReleaseUrl' => 'https://api.github.com/repos/Bubka/2FAuth/releases/latest', 'installDocUrl' => 'https://docs.2fauth.app/getting-started/installation/self-hosted-server/', + 'ssoDocUrl' => 'https://docs.2fauth.app/security/authentication/sso/', /* |-------------------------------------------------------------------------- diff --git a/resources/js/app.js b/resources/js/app.js index 4ec43582..54349fae 100644 --- a/resources/js/app.js +++ b/resources/js/app.js @@ -16,6 +16,7 @@ const $2fauth = { isDemoApp: window.isDemoApp, isTestingApp: window.isTestingApp, langs: window.appLocales, + urls: window.urls, } app.provide('2fauth', readonly($2fauth)) diff --git a/resources/views/landing.blade.php b/resources/views/landing.blade.php index 21606e6f..b31718db 100644 --- a/resources/views/landing.blade.php +++ b/resources/views/landing.blade.php @@ -25,6 +25,7 @@