Skip to content

Commit

Permalink
Fixes #15999 - Fix the order of methods to prevent strict CSP error
Browse files Browse the repository at this point in the history
  • Loading branch information
cetincakiroglu committed Jul 10, 2024
1 parent ecc013d commit 700ba8d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/app/components/dialog/dialog.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ const hideAnimation = animation([animate('{{transition}}', style({ transform: '{
</ng-container>
<ng-template #notHeadless>
<div *ngIf="resizable" class="p-resizable-handle" style="z-index: 90;" (mousedown)="initResize($event)"></div>
<div *ngIf="resizable" class="p-resizable-handle" (mousedown)="initResize($event)"></div>
<div #titlebar class="p-dialog-header" (mousedown)="initDrag($event)" *ngIf="showHeader">
<span [id]="ariaLabelledBy" class="p-dialog-title" *ngIf="!headerFacet && !headerTemplate">{{ header }}</span>
<span [id]="ariaLabelledBy" class="p-dialog-title" *ngIf="headerFacet">
Expand Down Expand Up @@ -944,8 +944,8 @@ export class Dialog implements AfterContentInit, OnInit, OnDestroy {
case 'visible':
this.container = event.element;
this.wrapper = this.container?.parentElement;
this.appendContainer();
this.moveOnTop();
this.appendContainer();
this.bindGlobalListeners();
this.container?.setAttribute(this.id, '');

Expand Down
2 changes: 1 addition & 1 deletion src/app/components/dynamicdialog/dynamicdialog.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ const hideAnimation = animation([animate('{{transition}}', style({ transform: '{
[attr.aria-labelledby]="ariaLabelledBy"
[attr.aria-modal]="true"
>
<div *ngIf="config.resizable" class="p-resizable-handle" style="z-index: 90;" (mousedown)="initResize($event)"></div>
<div *ngIf="config.resizable" class="p-resizable-handle" (mousedown)="initResize($event)"></div>
<div #titlebar class="p-dialog-header" (mousedown)="initDrag($event)" *ngIf="config.showHeader === false ? false : true">
<ng-container *ngComponentOutlet="headerTemplate"></ng-container>
<ng-container *ngIf="!headerTemplate">
Expand Down

0 comments on commit 700ba8d

Please sign in to comment.