File

src/modules/session-ui/components/session-card/session-card.component.ts

Description

Component to display session pages

Metadata

Index

Inputs

Inputs

cardTitle
Type : string
Default value : ""

The title shown in the header of the card

import { ChangeDetectionStrategy, Component, Input, ViewEncapsulation } from "@angular/core";

/**
 * @ignore
 */
const componentName = "stark-session-card";

/**
 * Component to display session pages
 */
@Component({
	selector: "stark-session-card",
	templateUrl: "./session-card.component.html",
	encapsulation: ViewEncapsulation.None,
	changeDetection: ChangeDetectionStrategy.OnPush,
	// We need to use host instead of @HostBinding: https://github.com/NationalBankBelgium/stark/issues/664
	host: {
		class: componentName
	}
})
export class StarkSessionCardComponent {
	/**
	 * The title shown in the header of the card
	 */
	@Input()
	public cardTitle = "";
}
<mat-card role="dialog">
	<div class="logo-header">
		<stark-app-logo></stark-app-logo>
	</div>
	<mat-card-header *ngIf="cardTitle">
		<mat-card-title>
			<h1>{{ cardTitle | translate }}</h1>
		</mat-card-title>
	</mat-card-header>
	<mat-card-content>
		<ng-content></ng-content>
	</mat-card-content>
</mat-card>
Legend
Html element
Component
Html element with directive

results matching ""

    No results matching ""