-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into feature/dev-3247-saving-a-new-value-for-rich…
…text-is-not-possible-if-the * main: chore(main): release 11.3.3 (#1426) fix: add cookie auth for iiif resources (#1425) chore(main): release 11.3.2 (#1424) fix: string instead of enum for environment config (#1423) chore(main): release 11.3.1 (#1411) fix: various fixes (#1420) fix: testing passes (#1422) fix(dsp-das): Enables rich text saving when creating new text value f… (#1417) # Conflicts: # libs/vre/shared/app-config/src/lib/app-config/app-config.service.spec.ts
- Loading branch information
Showing
12 changed files
with
99 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
apps/dsp-app/src/app/main/http-interceptors/iiif-with-credentials.interceptor.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import { HttpInterceptor, HttpRequest, HttpHandler, HttpEvent } from '@angular/common/http'; | ||
import { Injectable } from '@angular/core'; | ||
import { Observable } from 'rxjs'; | ||
|
||
// TODO remove this Interceptor and add all IIIF requests to a IIIFApiService that adds withCredentials true. | ||
/** | ||
* Add withCredentials true (sends cookies, used for authentication)to any iiif request | ||
*/ | ||
@Injectable() | ||
export class IiifWithCredentialsInterceptor implements HttpInterceptor { | ||
intercept(request: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>> { | ||
console.log(request.url); | ||
if (request.url.startsWith('https://iiif')) { | ||
const modifiedRequest = request.clone({ withCredentials: true }); | ||
console.log('good for', request.url, modifiedRequest); | ||
return next.handle(modifiedRequest); | ||
} | ||
|
||
// If the URL doesn't match, proceed with the original request | ||
return next.handle(request); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters