Пример #1
0
 public BaseMatDrawerContainer()
 {
     ClassMapper
     .Add("mdc-drawer-app-content");
     StyleMapper
     .GetIf(() => $"--mat-drawer-custom-width: {DrawerWidth}", () => !string.IsNullOrWhiteSpace(DrawerWidth));
 }
Пример #2
0
        protected override async Task OnInitializedAsync()
        {
            await base.OnInitializedAsync();

            ClassMapper
            .Add("mat-card-media")
            .Add("mdc-card__media")
            .If("mdc-card__media--16-9", () => Wide)
            .If("mdc-card__media--square", () => Square);

            ContentClassMapper
            .Add("mat-card-media-content")
            .Add("mdc-card__media-content")
            .Get(() => ContentClass);

            StyleMapper.GetIf(() => $"background-image: url(\"{ImageUrl}\")", () => ImageUrl != null);
        }