// Copyright © Selmo Technology GmbH. All Rights Reserved

using Microsoft.AspNetCore.Components;
using SelmoStudio.Hmi.Server.SelmoHmi.Helpers;

namespace SelmoStudio.Hmi.Server.Shared.Components.BaseComponents
{
    public partial class ComponentWithLabelBase : ComponentBase
    {
        [Parameter]
        public int FontSize { get; set; }

        [Parameter]
        public string FontFamily { get; set; }

        [Parameter]
        public string LabelStyleString { get; set; }

        [Parameter]
        public string LabelClassString { get; set; }

        protected string LabelClass => $"{(!string.IsNullOrEmpty(LabelClassString) ? LabelClassString : string.Empty)}";

        protected string ControlWithLabelStyle => @HtmlStyleHelper.GetControlWithLabelStyle(FontSize, FontFamily, LabelStyleString);
    }
}