Skip to content

Commit

Permalink
feat: expose visibility state in template outlet context (#58)
Browse files Browse the repository at this point in the history
  • Loading branch information
tFaster committed Jan 9, 2023
1 parent ca83ad8 commit 6cdfe0d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</ng-container>
<ng-container *ngIf="!isLoading">
<ng-template [ngTemplateOutlet]="panel.bodyTemplate"
[ngTemplateOutletContext]="{$implicit: panelData$, controller: controller, panelId: panel.id}">
[ngTemplateOutletContext]="{$implicit: panelData$, controller: controller, panelId: panel.id, isVisible: isVisible}">
</ng-template>
</ng-container>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ export class StackedPanelComponent<T> implements OnInit, OnChanges, AfterViewIni

private _showHideAnimationState: ShowHideAnimationState = 'hidden';

public get isVisible(): boolean {
return this._showHideAnimationState !== 'hidden';
}

@Input()
public animationParams: AnimationParams | undefined;

Expand Down

0 comments on commit 6cdfe0d

Please sign in to comment.