Label studio & sidebar & mobile fixes

This commit is contained in:
Darren Clarke 2023-09-12 14:33:37 +02:00
parent 9e68be7225
commit 7071f0c64a
18 changed files with 652 additions and 582 deletions

View file

@ -24,7 +24,6 @@ const checkRewrites = async (request: NextRequestWithAuth) => {
const { token } = request.nextauth;
const headers = { 'X-Forwarded-User': token?.email?.toLowerCase() };
console.log(request.nextUrl);
if (request.nextUrl.pathname.startsWith('/metamigo')) {
return rewriteURL(request, `${linkBaseURL}/metamigo`, metamigoURL);
} else if (request.nextUrl.pathname.startsWith('/label-studio')) {
@ -35,7 +34,7 @@ const checkRewrites = async (request: NextRequestWithAuth) => {
return rewriteURL(request, linkBaseURL, zammadURL, headers);
} else if (request.nextUrl.pathname.startsWith('/proxy/api') || request.nextUrl.pathname.startsWith('/proxy/assets')) {
return rewriteURL(request, `${linkBaseURL}/proxy`, zammadURL);
} else if (request.nextUrl.pathname.startsWith('/api/v1') || request.nextUrl.pathname.startsWith('/auth/sso')) {
} else if (request.nextUrl.pathname.startsWith('/api/v1') || request.nextUrl.pathname.startsWith('/auth/sso') || request.nextUrl.pathname.startsWith('/mobile')) {
return rewriteURL(request, linkBaseURL, zammadURL, headers);
}