diff --git a/src/app/cdk/trusted-summary/component/trusted-summary/trusted-summary.component.scss b/src/app/cdk/trusted-summary/component/trusted-summary/trusted-summary.component.scss index b1b65eadf..c2220e801 100644 --- a/src/app/cdk/trusted-summary/component/trusted-summary/trusted-summary.component.scss +++ b/src/app/cdk/trusted-summary/component/trusted-summary/trusted-summary.component.scss @@ -17,6 +17,7 @@ main.inside-iframe { align-content: start; grid-gap: 0; box-sizing: border-box; + height: 100vh; .panel-body { padding-top: 16px; diff --git a/src/app/environment-banner/environment-banner/environment-banner.component.ts b/src/app/environment-banner/environment-banner/environment-banner.component.ts index 522b8a7a7..2a76ce4fa 100644 --- a/src/app/environment-banner/environment-banner/environment-banner.component.ts +++ b/src/app/environment-banner/environment-banner/environment-banner.component.ts @@ -14,12 +14,14 @@ export class EnvironmentBannerComponent implements OnInit { canDismiss = environment['CAN_DISABLE_TEST_WARNING_BANNER'] @HostBinding('style.display') display = 'none' labelWarning = $localize`:@@environmentBanner.ariaLabelWarning:Warning, testing website` + notInsideIframe: boolean constructor( @Inject(WINDOW) private window: Window, private _cookieService: CookieService ) { + this.notInsideIframe = window.self === window.top this.hostUrl = window.location.host - if (!this._cookieService.get('testWarningCookie') || !this.canDismiss) { + if ((!this._cookieService.get('testWarningCookie') || !this.canDismiss) && this.notInsideIframe) { this.display = 'auto' } } diff --git a/summary-iframe-implementation-sample.html b/summary-iframe-implementation-sample.html new file mode 100644 index 000000000..27f1dfcb8 --- /dev/null +++ b/summary-iframe-implementation-sample.html @@ -0,0 +1,249 @@ + + + + + + + + ORCID Summary iFrame Display Tester + + + +
+

ORCID Summary iFrame Display Tester

+

+ This tool allows you to display ORCID IDs within iframes of various + sizes. Test how the content adapts to different iframe dimensions. +

+
+ + +
+ + + +
+ + +
+ + + + +
+ + +
+ + +
+ + + +