feat: migrate telegram + ed25519 auth implementation into @marketplaces/auth
Some checks failed
Release / release (push) Has been cancelled

This commit is contained in:
sdarbinyan
2026-08-18 00:52:00 +04:00
parent 5567154fb4
commit c628b1d8a9
21 changed files with 1397 additions and 4 deletions

View File

@@ -0,0 +1,15 @@
import { inject } from '@angular/core';
import { CanActivateFn } from '@angular/router';
import { AdminAuthService } from './admin-auth.service';
/** Guards `/admin/**`-style routes. Never shares state with the customer auth guard/service. */
export const adminAuthGuard: CanActivateFn = () => {
const adminAuth = inject(AdminAuthService);
if (adminAuth.isAuthenticated()) {
return true;
}
adminAuth.requestLogin();
return false;
};