Fix styles and js not loading
Replace all mud-* styles with non-mud alternatives
Add css/js artifacts to ignore list in .gitignore

Required steps for successful build were missing critical pieces:
- Required the excubo web compiler for js/css compilation (https://github.com/excubo-ag/WebCompiler)
- Required .csproj modification to include js/css compilation at build
- Required minified files added to the final index.html page as styles/scripts
features/nuget_autobuild
Matija Koželj 2 years ago
parent 2630b4eddd
commit 53dd3bec33

12
.gitignore vendored

@ -414,3 +414,15 @@ FodyWeavers.xsd
# Minified css files
**.min.css
# css files directly in the wwwroot folder
**/wwwroot/**.css
# Minified js files
**.min.js
# js files directly in the wwwroot folder
**/wwwroot/**.js
# any project with runner in its name
**.Runner/**

@ -5,7 +5,9 @@ VisualStudioVersion = 17.4.33020.496
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Connected.Components", "src\connected.components\Connected.Components.csproj", "{70BF497D-6519-401B-A0EE-2E9856B13D96}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Connected.Components.Showcase", "src\Connected.Components.Showcase\Connected.Components.Showcase.csproj", "{EBB24FD8-A554-427C-A93B-B48C047D34CC}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Connected.Components.Showcase", "src\Connected.Components.Showcase\Connected.Components.Showcase.csproj", "{EBB24FD8-A554-427C-A93B-B48C047D34CC}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Connected.Components.Showcase.Runner", "Connected.Components.Showcase.Runner\Connected.Components.Showcase.Runner.csproj", "{B8E7BCC3-3F99-4222-B65E-9ABD3B18DAF7}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@ -21,6 +23,10 @@ Global
{EBB24FD8-A554-427C-A93B-B48C047D34CC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{EBB24FD8-A554-427C-A93B-B48C047D34CC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{EBB24FD8-A554-427C-A93B-B48C047D34CC}.Release|Any CPU.Build.0 = Release|Any CPU
{B8E7BCC3-3F99-4222-B65E-9ABD3B18DAF7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B8E7BCC3-3F99-4222-B65E-9ABD3B18DAF7}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B8E7BCC3-3F99-4222-B65E-9ABD3B18DAF7}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B8E7BCC3-3F99-4222-B65E-9ABD3B18DAF7}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE

@ -11,4 +11,8 @@
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="7.0.0" PrivateAssets="all" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\connected.components\Connected.Components.csproj" />
</ItemGroup>
</Project>

@ -1,5 +0,0 @@
@inherits LayoutComponentBase
<main>
@Body
</main>

@ -0,0 +1,7 @@
@page "/components/alert"
@using Connected.Components;
<ThemeProvider></ThemeProvider>
<Alert Severity="Severity.Error" Variant="Variant.Filled">This is an alert</Alert>

@ -1,3 +0,0 @@
@page "/"
<h1>Hello, world!</h1>

@ -0,0 +1,12 @@
{
"version": 1,
"isRoot": true,
"tools": {
"excubo.webcompiler": {
"version": "2.7.12",
"commands": [
"webcompiler"
]
}
}
}

@ -2,7 +2,7 @@
@inherits UIComponent
<div @attributes="UserAttributes" role="alert" class="@ClassList" Style="@Style" @onclick="OnClick">
<div @attributes="UserAttributes" role="alert" class="@ClassList" Style="@Style" @onclick="Clicked">
<div class="@ClassPosition">
@if (!GlyphVisible)

@ -1,5 +1,4 @@
using System.Diagnostics.CodeAnalysis;
using Connected.Extensions;
using Connected.Extensions;
using Connected.Utilities;
using Microsoft.AspNetCore.Components;
using Microsoft.AspNetCore.Components.Web;
@ -11,21 +10,21 @@ public partial class Alert : UIComponent
[CascadingParameter(Name = "RightToLeft")]
public bool RightToLeft { get; set; }
/// <summary>
/// Sets the position of the text to the start (Left in LTR and right in RTL).
/// Sets the horizontal alignement of the text. Start and end depend on the <see cref="RightToLeft"/> property.
/// </summary>
[Parameter]
public HorizontalAlignment Alignment { get; set; } = HorizontalAlignment.Left;
public HorizontalAlignment Alignment { get; set; } = HorizontalAlignment.Start;
/// <summary>
/// The callback, when the close button has been clicked.
/// The callback, when the close glyph has been clicked.
/// </summary>
[Parameter] public EventCallback<Alert> CloseGlyphClicked { get; set; }
[Parameter] public EventCallback<Alert> CloseClicked { get; set; }
/// <summary>
/// Define the icon used for the close button.
/// Define the glyph used for the close button.
/// </summary>
[Parameter]
public string CloseGlyph { get; set; } = Icons.Material.Filled.Close;
/// <summary>
/// Sets if the alert shows a close icon.
/// Sets if the alert shows a close glyph.
/// </summary>
[Parameter]
public bool CloseGlyphVisible { get; set; }
@ -45,12 +44,12 @@ public partial class Alert : UIComponent
[Parameter]
public bool Dense { get; set; }
/// <summary>
/// If true, no alert icon will be used.
/// If true, no alert glyph will be used.
/// </summary>
[Parameter]
public bool GlyphVisible { get; set; }
/// <summary>
/// The severity of the alert. This defines the color and icon used.
/// The severity of the alert. This defines the color and glyph used.
/// </summary>
[Parameter]
public Severity Severity { get; set; } = Severity.Normal;
@ -65,7 +64,7 @@ public partial class Alert : UIComponent
[Parameter]
public RenderFragment? ChildContent { get; set; }
/// <summary>
/// Custom icon, leave unset to use the standard icon which depends on the Severity
/// Custom glyph, leave unset to use the standard glyph which depends on the Severity.
/// </summary>
[Parameter]
public string Glyph { get; set; } = default!;
@ -73,7 +72,7 @@ public partial class Alert : UIComponent
/// Raised when the alert is clicked
/// </summary>
[Parameter]
public EventCallback<MouseEventArgs> OnClick { get; set; }
public EventCallback<MouseEventArgs> Clicked { get; set; }
protected string ClassList
{
@ -112,32 +111,30 @@ public partial class Alert : UIComponent
internal async Task OnCloseGlyphClick()
{
if (CloseGlyphClicked.HasDelegate)
{
await CloseGlyphClicked.InvokeAsync(this);
if (!CloseClicked.HasDelegate)
return;
}
await Task.CompletedTask;
await CloseClicked.InvokeAsync(this);
}
//If we can check this exception can include the coverage again
[ExcludeFromCodeCoverage]
protected override void OnParametersSet()
{
if (!string.IsNullOrEmpty(Glyph))
return;
Glyph = Severity switch
Glyph = GetGlyphForSeverity(Severity);
}
private string GetGlyphForSeverity(Severity severity)
{
return Severity switch
{
Severity.Normal => Icons.Material.Outlined.EventNote,
Severity.Info => Icons.Material.Outlined.Info,
Severity.Success => Icons.Custom.Uncategorized.AlertSuccess,
Severity.Warning => Icons.Material.Outlined.ReportProblem,
Severity.Error => Icons.Material.Filled.ErrorOutline,
_ => throw new ArgumentOutOfRangeException(nameof(Severity)),
_ => throw new ArgumentOutOfRangeException(nameof(severity)),
};
}
}
}

@ -8,11 +8,11 @@
{
if (!String.IsNullOrEmpty(Alt))
{
<img src="@Image" alt="@Alt" class="mud-avatar-img" />
<img src="@Image" alt="@Alt" class="avatar-img" />
}
else
{
<img src="@Image" class="mud-avatar-img" />
<img src="@Image" class="avatar-img" />
}
}
else

@ -9,13 +9,13 @@ partial class Avatar : UIComponent, IDisposable
{
[CascadingParameter] protected AvatarGroup AvatarGroup { get; set; }
protected string Classname =>
new CssBuilder("mud-avatar")
.AddClass($"mud-avatar-{Size.ToDescriptionString()}")
.AddClass($"mud-avatar-rounded", Rounded)
.AddClass($"mud-avatar-square", Square)
.AddClass($"mud-avatar-{Variant.ToDescriptionString()}")
.AddClass($"mud-avatar-{Variant.ToDescriptionString()}-{Color.ToDescriptionString()}")
.AddClass($"mud-elevation-{Elevation.ToString()}")
new CssBuilder("avatar")
.AddClass($"avatar-{Size.ToDescriptionString()}")
.AddClass($"avatar-rounded", Rounded)
.AddClass($"avatar-square", Square)
.AddClass($"avatar-{Variant.ToDescriptionString()}")
.AddClass($"avatar-{Variant.ToDescriptionString()}-{Color.ToDescriptionString()}")
.AddClass($"elevation-{Elevation.ToString()}")
.AddClass(AvatarGroup?.GetAvatarSpacing() ?? new CssBuilder(), AvatarGroup != null)
.AddClass(Class)
.Build();

@ -10,14 +10,14 @@ partial class AvatarGroup : UIComponent
private bool _childrenNeedUpdates = false;
protected string Classname =>
new CssBuilder("mud-avatar-group")
.AddClass($"mud-avatar-group-outlined", Outlined)
.AddClass($"mud-avatar-group-outlined-{OutlineColor.ToDescriptionString()}", Outlined)
new CssBuilder("avatar-group")
.AddClass($"avatar-group-outlined", Outlined)
.AddClass($"avatar-group-outlined-{OutlineColor.ToDescriptionString()}", Outlined)
.AddClass(Class)
.Build();
protected string MaxAvatarClassname =>
new CssBuilder("mud-avatar-group-max-avatar")
new CssBuilder("avatar-group-max-avatar")
.AddClass($"ms-n{Spacing}")
.AddClass(MaxAvatarClass)
.Build();

@ -11,7 +11,7 @@
{
@if (!String.IsNullOrEmpty(Icon))
{
<Icon Icon="@Icon" Class="mud-icon-badge" />
<Icon Icon="@Icon" Class="icon-badge" />
}
else
{

@ -10,24 +10,24 @@ namespace Connected.Components;
public partial class Badge : UIComponent
{
protected string Classname =>
new CssBuilder("mud-badge-root")
new CssBuilder("badge-root")
.AddClass(Class)
.Build();
protected string WrapperClass =>
new CssBuilder("mud-badge-wrapper")
.AddClass($"mud-badge-{Origin.ToDescriptionString().Replace("-", " ")}")
new CssBuilder("badge-wrapper")
.AddClass($"badge-{Origin.ToDescriptionString().Replace("-", " ")}")
.Build();
protected string BadgeClassName =>
new CssBuilder("mud-badge")
.AddClass("mud-badge-dot", Dot)
.AddClass("mud-badge-bordered", Bordered)
.AddClass("mud-badge-icon", !string.IsNullOrEmpty(Icon) && !Dot)
.AddClass($"mud-badge-{Origin.ToDescriptionString().Replace("-", " ")}")
.AddClass($"mud-elevation-{Elevation.ToString()}")
.AddClass("mud-theme-" + Color.ToDescriptionString(), Color != ThemeColor.Default)
.AddClass("mud-badge-default", Color == ThemeColor.Default)
.AddClass("mud-badge-overlap", Overlap)
new CssBuilder("badge")
.AddClass("badge-dot", Dot)
.AddClass("badge-bordered", Bordered)
.AddClass("badge-icon", !string.IsNullOrEmpty(Icon) && !Dot)
.AddClass($"badge-{Origin.ToDescriptionString().Replace("-", " ")}")
.AddClass($"elevation-{Elevation.ToString()}")
.AddClass("theme-" + Color.ToDescriptionString(), Color != ThemeColor.Default)
.AddClass("badge-default", Color == ThemeColor.Default)
.AddClass("badge-overlap", Overlap)
.AddClass(BadgeClass)
.Build();

@ -10,7 +10,7 @@ public partial class BreadcrumbLink : UIComponent
[CascadingParameter]
public Breadcrumbs Parent { get; set; }
private string Classname => new CssBuilder("mud-breadcrumb-item")
.AddClass("mud-disabled", Item?.Disabled)
private string Classname => new CssBuilder("breadcrumb-item")
.AddClass("disabled", Item?.Disabled)
.Build();
}

@ -1,7 +1,7 @@
@namespace Connected.Components
@inherits UIComponent
<li aria-hidden="true" class="mud-breadcrumb-separator mud-ltr mud-flip-x-rtl">
<li aria-hidden="true" class="breadcrumb-separator mud-ltr mud-flip-x-rtl">
@if (Parent?.SeparatorTemplate is null)
{
<span>@Parent?.Separator</span>

@ -12,7 +12,7 @@
{
<BreadcrumbLink Item="Items[0]"></BreadcrumbLink>
<BreadcrumbSeparator></BreadcrumbSeparator>
<li class="mud-breadcrumbs-expander" @onclick="Expand">
<li class="breadcrumbs-expander" @onclick="Expand">
<Icon Icon="@ExpanderIcon" Size="Size.Small"></Icon>
</li>
<BreadcrumbSeparator></BreadcrumbSeparator>

@ -49,15 +49,15 @@ public partial class Breadcrumbs : UIComponent
public string ExpanderIcon { get; set; } = Icons.Material.Filled.SettingsEthernet;
public bool Collapsed { get; private set; } = true;
private string Classname => new CssBuilder("mud-breadcrumbs")
.AddClass("mud-typography-body1")
private string Classname => new CssBuilder("breadcrumbs")
.AddClass("typography-body1")
.AddClass(Class)
.Build();
internal static string GetItemClassname(BreadcrumbItem item)
{
return new CssBuilder("mud-breadcrumb-item")
.AddClass("mud-disabled", item.Disabled)
return new CssBuilder("breadcrumb-item")
.AddClass("disabled", item.Disabled)
.Build();
}

@ -13,7 +13,7 @@
target="@Target"
rel="@(Target=="_blank"?"noopener":null)"
disabled="@Disabled">
<span class="mud-button-label">
<span class="button-label">
@if (!string.IsNullOrWhiteSpace(StartIcon))
{
<span class="@StartIconClass">

@ -8,25 +8,25 @@ namespace Connected.Components;
public partial class Button : ButtonBase
{
protected string Classname =>
new CssBuilder("mud-button-root mud-button")
.AddClass($"mud-button-{Variant.ToDescriptionString()}")
.AddClass($"mud-button-{Variant.ToDescriptionString()}-{Color.ToDescriptionString()}")
.AddClass($"mud-button-{Variant.ToDescriptionString()}-size-{Size.ToDescriptionString()}")
.AddClass($"mud-width-full", FullWidth)
.AddClass($"mud-ripple", !DisableRipple)
.AddClass($"mud-button-disable-elevation", DisableElevation)
new CssBuilder("button-root mud-button")
.AddClass($"button-{Variant.ToDescriptionString()}")
.AddClass($"button-{Variant.ToDescriptionString()}-{Color.ToDescriptionString()}")
.AddClass($"button-{Variant.ToDescriptionString()}-size-{Size.ToDescriptionString()}")
.AddClass($"width-full", FullWidth)
.AddClass($"ripple", !DisableRipple)
.AddClass($"button-disable-elevation", DisableElevation)
.AddClass(Class)
.Build();
protected string StartIconClass =>
new CssBuilder("mud-button-icon-start")
.AddClass($"mud-button-icon-size-{Size.ToDescriptionString()}")
new CssBuilder("button-icon-start")
.AddClass($"button-icon-size-{Size.ToDescriptionString()}")
.AddClass(IconClass)
.Build();
protected string EndIconClass =>
new CssBuilder("mud-button-icon-end")
.AddClass($"mud-button-icon-size-{Size.ToDescriptionString()}")
new CssBuilder("button-icon-end")
.AddClass($"button-icon-size-{Size.ToDescriptionString()}")
.AddClass(IconClass)
.Build();

@ -16,7 +16,7 @@
rel="@(Target=="_blank"?"noopener":null)"
disabled="@Disabled"
title="@Title">
<span class="mud-fab-label">
<span class="fab-label">
@if (!string.IsNullOrWhiteSpace(StartIcon))
{
<Icon Icon="@StartIcon" Color="@IconColor" Size="@IconSize" />

@ -8,12 +8,12 @@ namespace Connected.Components;
public partial class Fab : ButtonBase
{
protected string Classname =>
new CssBuilder("mud-button-root mud-fab")
.AddClass($"mud-fab-extended", !string.IsNullOrEmpty(Label))
.AddClass($"mud-fab-{Color.ToDescriptionString()}")
.AddClass($"mud-fab-size-{Size.ToDescriptionString()}")
.AddClass($"mud-ripple", !DisableRipple && !Disabled)
.AddClass($"mud-fab-disable-elevation", DisableElevation)
new CssBuilder("button-root mud-fab")
.AddClass($"fab-extended", !string.IsNullOrEmpty(Label))
.AddClass($"fab-{Color.ToDescriptionString()}")
.AddClass($"fab-size-{Size.ToDescriptionString()}")
.AddClass($"ripple", !DisableRipple && !Disabled)
.AddClass($"fab-disable-elevation", DisableElevation)
.AddClass(Class)
.Build();

@ -18,7 +18,7 @@
title="@Title">
@if (!String.IsNullOrEmpty(Icon))
{
<span class="mud-icon-button-label">
<span class="icon-button-label">
<Icon Glyph="@Icon" Size="@Size" />
</span>
}

@ -8,17 +8,17 @@ namespace Connected.Components;
public partial class IconButton : ButtonBase
{
protected string Classname =>
new CssBuilder("mud-button-root mud-icon-button")
.AddClass("mud-button", when: AsButton)
.AddClass($"mud-{Color.ToDescriptionString()}-text hover:mud-{Color.ToDescriptionString()}-hover", !AsButton && Color != ThemeColor.Default)
.AddClass($"mud-button-{Variant.ToDescriptionString()}", AsButton)
.AddClass($"mud-button-{Variant.ToDescriptionString()}-{Color.ToDescriptionString()}", AsButton)
.AddClass($"mud-button-{Variant.ToDescriptionString()}-size-{Size.ToDescriptionString()}", AsButton)
.AddClass($"mud-ripple", !DisableRipple)
.AddClass($"mud-ripple-icon", !DisableRipple && !AsButton)
.AddClass($"mud-icon-button-size-{Size.ToDescriptionString()}", when: () => Size != Size.Medium)
.AddClass($"mud-icon-button-edge-{Edge.ToDescriptionString()}", when: () => Edge != Edge.False)
.AddClass($"mud-button-disable-elevation", DisableElevation)
new CssBuilder("button-root mud-icon-button")
.AddClass("button", when: AsButton)
.AddClass($"{Color.ToDescriptionString()}-text hover:mud-{Color.ToDescriptionString()}-hover", !AsButton && Color != ThemeColor.Default)
.AddClass($"button-{Variant.ToDescriptionString()}", AsButton)
.AddClass($"button-{Variant.ToDescriptionString()}-{Color.ToDescriptionString()}", AsButton)
.AddClass($"button-{Variant.ToDescriptionString()}-size-{Size.ToDescriptionString()}", AsButton)
.AddClass($"ripple", !DisableRipple)
.AddClass($"ripple-icon", !DisableRipple && !AsButton)
.AddClass($"icon-button-size-{Size.ToDescriptionString()}", when: () => Size != Size.Medium)
.AddClass($"icon-button-edge-{Edge.ToDescriptionString()}", when: () => Edge != Edge.False)
.AddClass($"button-disable-elevation", DisableElevation)
.AddClass(Class)
.Build();

@ -8,15 +8,15 @@ namespace Connected.Components;
public partial class ButtonGroup : UIComponent
{
protected string Classname =>
new CssBuilder("mud-button-group-root")
.AddClass($"mud-button-group-override-styles", OverrideStyles)
.AddClass($"mud-button-group-{Variant.ToDescriptionString()}")
.AddClass($"mud-button-group-{Variant.ToDescriptionString()}-{Color.ToDescriptionString()}")
.AddClass($"mud-button-group-{Variant.ToDescriptionString()}-size-{Size.ToDescriptionString()}")
.AddClass($"mud-button-group-vertical", VerticalAlign)
.AddClass($"mud-button-group-horizontal", !VerticalAlign)
.AddClass($"mud-button-group-disable-elevation", DisableElevation)
.AddClass($"mud-button-group-rtl", RightToLeft)
new CssBuilder("button-group-root")
.AddClass($"button-group-override-styles", OverrideStyles)
.AddClass($"button-group-{Variant.ToDescriptionString()}")
.AddClass($"button-group-{Variant.ToDescriptionString()}-{Color.ToDescriptionString()}")
.AddClass($"button-group-{Variant.ToDescriptionString()}-size-{Size.ToDescriptionString()}")
.AddClass($"button-group-vertical", VerticalAlign)
.AddClass($"button-group-horizontal", !VerticalAlign)
.AddClass($"button-group-disable-elevation", DisableElevation)
.AddClass($"button-group-rtl", RightToLeft)
.AddClass(Class)
.Build();

@ -7,7 +7,7 @@ namespace Connected.Components;
public partial class Card : UIComponent
{
protected string Classname =>
new CssBuilder("mud-card")
new CssBuilder("card")
.AddClass(Class)
.Build();

@ -7,7 +7,7 @@ namespace Connected.Components;
public partial class CardActions : UIComponent
{
protected string Classname =>
new CssBuilder("mud-card-actions")
new CssBuilder("card-actions")
.AddClass(Class)
.Build();

@ -7,7 +7,7 @@ namespace Connected.Components;
public partial class CardContent : UIComponent
{
protected string Classname =>
new CssBuilder("mud-card-content")
new CssBuilder("card-content")
.AddClass(Class)
.Build();

@ -5,15 +5,15 @@
<div @attributes="UserAttributes" class="@Classname" style="@Style">
@if (CardHeaderAvatar is not null)
{
<div class="mud-card-header-avatar">@CardHeaderAvatar</div>
<div class="card-header-avatar">@CardHeaderAvatar</div>
}
@if (CardHeaderContent is not null)
{
<div class="mud-card-header-content">@CardHeaderContent</div>
<div class="card-header-content">@CardHeaderContent</div>
}
@if (CardHeaderActions is not null)
{
<div class="mud-card-header-actions">@CardHeaderActions</div>
<div class="card-header-actions">@CardHeaderActions</div>
}
@if (ChildContent is not null)
{

@ -7,7 +7,7 @@ namespace Connected.Components;
public partial class CardHeader : UIComponent
{
protected string Classname =>
new CssBuilder("mud-card-header")
new CssBuilder("card-header")
.AddClass(Class)
.Build();

@ -12,7 +12,7 @@ public partial class CardMedia : UIComponent
.Build();
protected string Classname =>
new CssBuilder("mud-card-media")
new CssBuilder("card-media")
.AddClass(Class)
.Build();

@ -7,7 +7,7 @@
<section @attributes="UserAttributes" aria-roledescription="carousel" class="@Classname" style="@Style">
<CascadingValue Value="this">
<SwipeArea OnSwipe="OnSwipe" Class="mud-carousel-swipe">
<SwipeArea OnSwipe="OnSwipe" Class="carousel-swipe">
@*Selected Content*@
@if (ItemsSource == null)
{

@ -9,15 +9,15 @@ namespace Connected.Components;
public partial class Carousel<TData> : BindableItemsControlBase<CarouselItem, TData>, IAsyncDisposable
{
protected string Classname =>
new CssBuilder("mud-carousel")
.AddClass($"mud-carousel-{(BulletsColor ?? _currentColor).ToDescriptionString()}")
new CssBuilder("carousel")
.AddClass($"carousel-{(BulletsColor ?? _currentColor).ToDescriptionString()}")
.AddClass(Class)
.Build();
protected string NavigationButtonsClassName =>
new CssBuilder()
.AddClass($"align-self-{ConvertPosition(ArrowsPosition).ToDescriptionString()}", !(NavigationButtonsClass ?? "").Contains("align-self-"))
.AddClass("mud-carousel-elements-rtl", RightToLeft)
.AddClass("carousel-elements-rtl", RightToLeft)
.AddClass(NavigationButtonsClass)
.Build();

@ -8,26 +8,26 @@ namespace Connected.Components;
public partial class CarouselItem : UIComponent, IDisposable
{
protected string Classname =>
new CssBuilder("mud-carousel-item")
.AddClass($"mud-carousel-item-{Color.ToDescriptionString()}")
.AddClass("mud-carousel-item-exit", !_disposed && Parent.LastContainer == this)
new CssBuilder("carousel-item")
.AddClass($"carousel-item-{Color.ToDescriptionString()}")
.AddClass("carousel-item-exit", !_disposed && Parent.LastContainer == this)
.AddClass("mud-carousel-transition-fade-in", !_disposed && Transition == Transition.Fade && Parent.SelectedContainer == this)
.AddClass("mud-carousel-transition-fade-out", !_disposed && Transition == Transition.Fade && Parent.LastContainer == this)
.AddClass("carousel-transition-fade-in", !_disposed && Transition == Transition.Fade && Parent.SelectedContainer == this)
.AddClass("carousel-transition-fade-out", !_disposed && Transition == Transition.Fade && Parent.LastContainer == this)
.AddClass("mud-carousel-transition-slide-next-enter", !_disposed && Transition == Transition.Slide && RightToLeft == false && Parent.SelectedContainer == this && Parent._moveNext)
.AddClass("mud-carousel-transition-slide-next-exit", !_disposed && Transition == Transition.Slide && RightToLeft == false && Parent.LastContainer == this && Parent._moveNext)
.AddClass("carousel-transition-slide-next-enter", !_disposed && Transition == Transition.Slide && RightToLeft == false && Parent.SelectedContainer == this && Parent._moveNext)
.AddClass("carousel-transition-slide-next-exit", !_disposed && Transition == Transition.Slide && RightToLeft == false && Parent.LastContainer == this && Parent._moveNext)
.AddClass("mud-carousel-transition-slide-prev-enter", !_disposed && Transition == Transition.Slide && RightToLeft == false && Parent.SelectedContainer == this && !Parent._moveNext)
.AddClass("mud-carousel-transition-slide-prev-exit", !_disposed && Transition == Transition.Slide && RightToLeft == false && Parent.LastContainer == this && !Parent._moveNext)
.AddClass("carousel-transition-slide-prev-enter", !_disposed && Transition == Transition.Slide && RightToLeft == false && Parent.SelectedContainer == this && !Parent._moveNext)
.AddClass("carousel-transition-slide-prev-exit", !_disposed && Transition == Transition.Slide && RightToLeft == false && Parent.LastContainer == this && !Parent._moveNext)
.AddClass("mud-carousel-transition-slide-next-rtl-enter", !_disposed && Transition == Transition.Slide && RightToLeft == true && Parent.SelectedContainer == this && Parent._moveNext)
.AddClass("mud-carousel-transition-slide-next-rtl-exit", !_disposed && Transition == Transition.Slide && RightToLeft == true && Parent.LastContainer == this && Parent._moveNext)
.AddClass("carousel-transition-slide-next-rtl-enter", !_disposed && Transition == Transition.Slide && RightToLeft == true && Parent.SelectedContainer == this && Parent._moveNext)
.AddClass("carousel-transition-slide-next-rtl-exit", !_disposed && Transition == Transition.Slide && RightToLeft == true && Parent.LastContainer == this && Parent._moveNext)
.AddClass("mud-carousel-transition-slide-prev-rtl-enter", !_disposed && Transition == Transition.Slide && RightToLeft == true && Parent.SelectedContainer == this && !Parent._moveNext)
.AddClass("mud-carousel-transition-slide-prev-rtl-exit", !_disposed && Transition == Transition.Slide && RightToLeft == true && Parent.LastContainer == this && !Parent._moveNext)
.AddClass("carousel-transition-slide-prev-rtl-enter", !_disposed && Transition == Transition.Slide && RightToLeft == true && Parent.SelectedContainer == this && !Parent._moveNext)
.AddClass("carousel-transition-slide-prev-rtl-exit", !_disposed && Transition == Transition.Slide && RightToLeft == true && Parent.LastContainer == this && !Parent._moveNext)
.AddClass("mud-carousel-transition-none", !_disposed && Transition == Transition.None && Parent.SelectedContainer != this)
.AddClass("carousel-transition-none", !_disposed && Transition == Transition.None && Parent.SelectedContainer != this)
.AddClass(CustomTransitionEnter, !_disposed && Transition == Transition.Custom && Parent.SelectedContainer == this && Parent.SelectedContainer == this)
.AddClass(CustomTransitionExit, !_disposed && Transition == Transition.Custom && Parent.LastContainer == this && Parent.LastContainer == this)

@ -36,8 +36,8 @@ public partial class Chart : UIComponent
public RenderFragment CustomGraphics { get; set; }
protected string Classname =>
new CssBuilder("mud-chart")
.AddClass($"mud-chart-legend-{ConvertLegendPosition(LegendPosition).ToDescriptionString()}")
new CssBuilder("chart")
.AddClass($"chart-legend-{ConvertLegendPosition(LegendPosition).ToDescriptionString()}")
.AddClass(Class)
.Build();

@ -2,9 +2,9 @@
@using System.Globalization;
@inherits Chart
<svg @attributes="UserAttributes" class="mud-chart-line mud-ltr" width="@ChartParent?.Width" height="@ChartParent?.Height" viewBox="0 0 650 350">
<g class="mud-charts-grid">
<g class="mud-charts-gridlines-yaxis">
<svg @attributes="UserAttributes" class="chart-line mud-ltr" width="@ChartParent?.Width" height="@ChartParent?.Height" viewBox="0 0 650 350">
<g class="charts-grid">
<g class="charts-gridlines-yaxis">
@foreach (var horizontalLine in _horizontalLines)
{
<path stroke="#e0e0e0" stroke-width="0.3" d="@horizontalLine.Data"></path>
@ -12,7 +12,7 @@
</g>
@if (ChartParent?.ChartOptions.XAxisLines==true)
{
<g class="mud-charts-gridlines-xaxis-lines">
<g class="charts-gridlines-xaxis-lines">
@foreach (var verticalLine in _verticalLines)
{
<path stroke="gray" stroke-width="0.3" d="@verticalLine.Data"></path>
@ -20,22 +20,22 @@
</g>
}
</g>
<g class="mud-charts-yaxis">
<g class="charts-yaxis">
@foreach (var horizontalLineValue in _horizontalValues)
{
@((MarkupString)$"<text x='{horizontalLineValue.X.ToString(CultureInfo.InvariantCulture)}' y='{horizontalLineValue.Y.ToString(CultureInfo.InvariantCulture)}' font-size='12px' text-anchor='end' dominant-baseline='auto'>{horizontalLineValue.Value.ToString(CultureInfo.InvariantCulture)}</text>")
}
</g>
<g class="mud-charts-xaxis">
<g class="charts-xaxis">
@foreach (var verticalLineValue in _verticalValues)
{
@((MarkupString)$"<text x='{verticalLineValue.X.ToString(CultureInfo.InvariantCulture)}' y='{verticalLineValue.Y.ToString(CultureInfo.InvariantCulture)}' font-size='12px' text-anchor='middle'>{verticalLineValue.Value.ToString(CultureInfo.InvariantCulture)}</text>")
}
</g>
<g class="mud-charts-bar-series">
<g class="charts-bar-series">
@foreach (var bar in _bars)
{
<path class="mud-chart-bar" @onclick="() => SelectedIndex = bar.Index" fill="@(ChartParent.ChartOptions.ChartPalette.GetValue(bar.Index % ChartOptions.ChartPalette.Count()))" stroke="@(ChartParent.ChartOptions.ChartPalette.GetValue(bar.Index % ChartOptions.ChartPalette.Count()))" stroke-width="8" d="@bar.Data"></path>
<path class="chart-bar" @onclick="() => SelectedIndex = bar.Index" fill="@(ChartParent.ChartOptions.ChartPalette.GetValue(bar.Index % ChartOptions.ChartPalette.Count()))" stroke="@(ChartParent.ChartOptions.ChartPalette.GetValue(bar.Index % ChartOptions.ChartPalette.Count()))" stroke-width="8" d="@bar.Data"></path>
}
</g>

@ -2,12 +2,12 @@
@using System.Globalization
@inherits Chart
<svg @attributes="UserAttributes" class="mud-chart-donut" width="@ParentWidth" height="@ParentHeight" viewBox="0 0 42 42">
<svg @attributes="UserAttributes" class="chart-donut" width="@ParentWidth" height="@ParentHeight" viewBox="0 0 42 42">
<Filters />
<circle class="mud-donut-ring" cx="21" cy="21" r="15.91549430918954"></circle>
<circle class="donut-ring" cx="21" cy="21" r="15.91549430918954"></circle>
@foreach (var item in _circles.ToList())
{
<circle class="mud-chart-serie mud-donut-segment" @onclick="() => SelectedIndex = item.Index" stroke="@(ChartParent.ChartOptions.ChartPalette.GetValue(item.Index % ChartOptions.ChartPalette.Count()))"
<circle class="chart-serie mud-donut-segment" @onclick="() => SelectedIndex = item.Index" stroke="@(ChartParent.ChartOptions.ChartPalette.GetValue(item.Index % ChartOptions.ChartPalette.Count()))"
cx="@ToS(item.CX)"
cy="@ToS(item.CY)"
r="@ToS(item.Radius)"
@ -15,7 +15,7 @@
stroke-dashoffset="@ToS(item.StrokeDashOffset)">
</circle>
}
<circle class="mud-donut-hole" cx="21" cy="21" r="13.4"></circle>
<circle class="donut-hole" cx="21" cy="21" r="13.4"></circle>
@ChartParent?.CustomGraphics
</svg>

@ -2,9 +2,9 @@
@using System.Globalization;
@inherits Chart
<svg @attributes="UserAttributes" class="mud-chart-line mud-ltr" width="@ChartParent?.Width" height="@ChartParent?.Height" viewBox="0 0 650 350">
<g class="mud-charts-grid">
<g class="mud-charts-gridlines-yaxis">
<svg @attributes="UserAttributes" class="chart-line mud-ltr" width="@ChartParent?.Width" height="@ChartParent?.Height" viewBox="0 0 650 350">
<g class="charts-grid">
<g class="charts-gridlines-yaxis">
@foreach (var horizontalLine in _horizontalLines)
{
<path stroke="#e0e0e0" stroke-width="0.3" d="@horizontalLine.Data"></path>
@ -12,7 +12,7 @@
</g>
@if (ChartParent?.ChartOptions.XAxisLines==true)
{
<g class="mud-charts-gridlines-xaxis-lines">
<g class="charts-gridlines-xaxis-lines">
@foreach (var verticalLine in _verticalLines)
{
<path stroke="gray" stroke-width="0.3" d="@verticalLine.Data"></path>
@ -20,22 +20,22 @@
</g>
}
</g>
<g class="mud-charts-yaxis">
<g class="charts-yaxis">
@foreach (var horizontalLineValue in _horizontalValues)
{
@((MarkupString)$"<text x='{horizontalLineValue.X.ToString(CultureInfo.InvariantCulture)}' y='{horizontalLineValue.Y.ToString(CultureInfo.InvariantCulture)}' font-size='12px' text-anchor='end' dominant-baseline='auto'>{horizontalLineValue.Value.ToString(CultureInfo.InvariantCulture)}</text>")
}
</g>
<g class="mud-charts-xaxis">
<g class="charts-xaxis">
@foreach (var verticalLineValue in _verticalValues)
{
@((MarkupString)$"<text x='{verticalLineValue.X.ToString(CultureInfo.InvariantCulture)}' y='{verticalLineValue.Y.ToString(CultureInfo.InvariantCulture)}' font-size='12px' text-anchor='middle'>{verticalLineValue.Value.ToString(CultureInfo.InvariantCulture)}</text>")
}
</g>
<g class="mud-charts-line-series">
<g class="charts-line-series">
@foreach (var chartLine in _chartLines)
{
<path class="mud-chart-line" @onclick="() => SelectedIndex = chartLine.Index" fill="none" stroke="@(ChartParent.ChartOptions.ChartPalette.GetValue(chartLine.Index % ChartOptions.ChartPalette.Count()))" stroke-width="@(ChartParent.ChartOptions.LineStrokeWidth)" d="@chartLine.Data"></path>
<path class="chart-line" @onclick="() => SelectedIndex = chartLine.Index" fill="none" stroke="@(ChartParent.ChartOptions.ChartPalette.GetValue(chartLine.Index % ChartOptions.ChartPalette.Count()))" stroke-width="@(ChartParent.ChartOptions.LineStrokeWidth)" d="@chartLine.Data"></path>
}
</g>

@ -2,11 +2,11 @@
@using System.Globalization
@inherits Chart
<svg @attributes="UserAttributes" class="mud-chart-pie" width="@ChartParent?.Width" height="@ChartParent?.Height" viewBox="-1 -1 2 2" style="transform: rotate(-90deg);">
<svg @attributes="UserAttributes" class="chart-pie" width="@ChartParent?.Width" height="@ChartParent?.Height" viewBox="-1 -1 2 2" style="transform: rotate(-90deg);">
<Filters />
@foreach (var item in _paths.ToList())
{
<path @onclick="() => SelectedIndex = item.Index" class="mud-chart-serie" fill="@(ChartParent.ChartOptions.ChartPalette.GetValue(item.Index % ChartOptions.ChartPalette.Count()))" d="@item.Data"></path>
<path @onclick="() => SelectedIndex = item.Index" class="chart-serie" fill="@(ChartParent.ChartOptions.ChartPalette.GetValue(item.Index % ChartOptions.ChartPalette.Count()))" d="@item.Data"></path>
}
@ChartParent?.CustomGraphics

@ -3,11 +3,11 @@
@if (ChartParent?.ChartOptions.DisableLegend != true)
{
<div @attributes="UserAttributes" class="mud-chart-legend">
<div @attributes="UserAttributes" class="chart-legend">
@foreach (var item in Data)
{
<div class="mud-chart-legend-item" @onclick=@(()=>{ if (ChartParent!=null) { ChartParent.SelectedIndex=item.Index; }}) @onclick:stopPropagation=@(ChartParent!=null)>
<span class="mud-chart-legend-marker" style="@($"background-color:{ChartParent.ChartOptions.ChartPalette.GetValue(item.Index % ChartOptions.ChartPalette.Count())}")"></span>
<div class="chart-legend-item" @onclick=@(()=>{ if (ChartParent!=null) { ChartParent.SelectedIndex=item.Index; }}) @onclick:stopPropagation=@(ChartParent!=null)>
<span class="chart-legend-marker" style="@($"background-color:{ChartParent.ChartOptions.ChartPalette.GetValue(item.Index % ChartOptions.ChartPalette.Count())}")"></span>
<TextContent Typo="Typo.body2" Inline="true">@item.Labels</TextContent>
</div>
}

@ -7,7 +7,7 @@
<label class="@LabelClassname" id="@_elementId" @onkeydown="HandleKeyDown" @onclick:stopPropagation="@StopClickPropagation">
<span tabindex="0" class="@CheckBoxClassname">
@*note: stopping the click propagation is important here. otherwise checking the checkbox results in click events on its parent (i.e. table row), which is generally not what you would want*@
<input tabindex="-1" @attributes="UserAttributes" type="checkbox" class="mud-checkbox-input" checked="@BoolValue" @onchange="@OnChange" disabled="@Disabled" @onclick:preventDefault="@ReadOnly" />
<input tabindex="-1" @attributes="UserAttributes" type="checkbox" class="checkbox-input" checked="@BoolValue" @onchange="@OnChange" disabled="@Disabled" @onclick:preventDefault="@ReadOnly" />
<Icon Icon="@GetIcon()" Color="HasErrors ? ThemeColor.Error : ThemeColor.Inherit" Size="@Size" />
</span>
@if (!String.IsNullOrEmpty(Label))

@ -10,25 +10,25 @@ namespace Connected.Components;
public partial class CheckBox<T> : BooleanInput<T>
{
protected string Classname =>
new CssBuilder("mud-input-control-boolean-input")
new CssBuilder("input-control-boolean-input")
.AddClass(Class)
.Build();
protected string LabelClassname =>
new CssBuilder("mud-checkbox")
.AddClass($"mud-disabled", Disabled)
.AddClass($"mud-readonly", ReadOnly)
.AddClass(LabelPosition == LabelPosition.End ? "mud-ltr" : "mud-rtl", true)
new CssBuilder("checkbox")
.AddClass($"disabled", Disabled)
.AddClass($"readonly", ReadOnly)
.AddClass(LabelPosition == LabelPosition.End ? "ltr" : "rtl", true)
.Build();
protected string CheckBoxClassname =>
new CssBuilder("mud-button-root mud-icon-button")
.AddClass($"mud-{Color.ToDescriptionString()}-text hover:mud-{Color.ToDescriptionString()}-hover", UnCheckedColor == null || (UnCheckedColor != null && BoolValue == true))
.AddClass($"mud-{UnCheckedColor?.ToDescriptionString()}-text hover:mud-{UnCheckedColor?.ToDescriptionString()}-hover", UnCheckedColor != null && BoolValue == false)
.AddClass($"mud-checkbox-dense", Dense)
.AddClass($"mud-ripple mud-ripple-checkbox", !DisableRipple && !ReadOnly && !Disabled)
.AddClass($"mud-disabled", Disabled)
.AddClass($"mud-readonly", ReadOnly)
new CssBuilder("button-root mud-icon-button")
.AddClass($"{Color.ToDescriptionString()}-text hover:mud-{Color.ToDescriptionString()}-hover", UnCheckedColor == null || (UnCheckedColor != null && BoolValue == true))
.AddClass($"{UnCheckedColor?.ToDescriptionString()}-text hover:mud-{UnCheckedColor?.ToDescriptionString()}-hover", UnCheckedColor != null && BoolValue == false)
.AddClass($"checkbox-dense", Dense)
.AddClass($"ripple mud-ripple-checkbox", !DisableRipple && !ReadOnly && !Disabled)
.AddClass($"disabled", Disabled)
.AddClass($"readonly", ReadOnly)
.Build();
/// <summary>
@ -225,7 +225,7 @@ public partial class CheckBox<T> : BooleanInput<T>
await _keyInterceptor.Connect(_elementId, new KeyInterceptorOptions()
{
//EnableLogging = true,
TargetClass = "mud-button-root",
TargetClass = "button-root",
Keys = {
new KeyOptions { Key=" ", PreventDown = "key+none", PreventUp = "key+none" }, // prevent scrolling page
new KeyOptions { Key="Enter", PreventDown = "key+none" },

@ -10,13 +10,13 @@
}
else if (!String.IsNullOrEmpty(Icon) && !IsChecked)
{
<Icon Icon="@Icon" Class="mud-chip-icon" Size="Size.Small" Color="@IconColor" />
<Icon Icon="@Icon" Class="chip-icon" Size="Size.Small" Color="@IconColor" />
}
else if (IsChecked)
{
<Icon Icon="@CheckedIcon" Class="mud-chip-icon" Size="Size.Small" />
<Icon Icon="@CheckedIcon" Class="chip-icon" Size="Size.Small" />
}
<span class="mud-chip-content">
<span class="chip-content">
@if (ChildContent == null)
{
@Text
@ -27,7 +27,7 @@
}
@if (OnClose.HasDelegate || ChipSet?.AllClosable==true)
{
<IconButton Class="mud-chip-close-button" Icon="@(String.IsNullOrEmpty(CloseIcon) ? $"{Icons.Material.Filled.Cancel}" : $"{CloseIcon}")" OnClick="OnCloseHandler" Size="Size.Small"/>
<IconButton Class="chip-close-button" Icon="@(String.IsNullOrEmpty(CloseIcon) ? $"{Icons.Material.Filled.Cancel}" : $"{CloseIcon}")" OnClick="OnCloseHandler" Size="Size.Small"/>
}
</span>
</div>

@ -16,15 +16,15 @@ public partial class Chip : UIComponent, IDisposable
[Inject] public IJsApiService JsApiService { get; set; }
protected string Classname =>
new CssBuilder("mud-chip")
.AddClass($"mud-chip-{GetVariant().ToDescriptionString()}")
.AddClass($"mud-chip-size-{Size.ToDescriptionString()}")
.AddClass($"mud-chip-color-{GetColor().ToDescriptionString()}")
.AddClass("mud-clickable", !ChipSet?.ReadOnly ?? OnClick.HasDelegate)
.AddClass("mud-ripple", !ChipSet?.ReadOnly ?? OnClick.HasDelegate && !DisableRipple)
.AddClass("mud-chip-label", Label)
.AddClass("mud-disabled", Disabled)
.AddClass("mud-chip-selected", IsSelected)
new CssBuilder("chip")
.AddClass($"chip-{GetVariant().ToDescriptionString()}")
.AddClass($"chip-size-{Size.ToDescriptionString()}")
.AddClass($"chip-color-{GetColor().ToDescriptionString()}")
.AddClass("clickable", !ChipSet?.ReadOnly ?? OnClick.HasDelegate)
.AddClass("ripple", !ChipSet?.ReadOnly ?? OnClick.HasDelegate && !DisableRipple)
.AddClass("chip-label", Label)
.AddClass("disabled", Disabled)
.AddClass("chip-selected", IsSelected)
.AddClass(Class)
.Build();

@ -8,7 +8,7 @@ public partial class ChipSet : UIComponent, IDisposable
{
protected string Classname =>
new CssBuilder("mud-chipset")
new CssBuilder("chipset")
.AddClass(Class)
.Build();

@ -3,8 +3,8 @@
@using System.Globalization;
<div @onanimationend="EventUtil.AsNonRenderingEventHandler(AnimationEnd)" @attributes="UserAttributes" class="@Classname" style="@Stylename">
<div @ref="_wrapper" class="mud-collapse-wrapper">
<div class="mud-collapse-wrapper-inner">
<div @ref="_wrapper" class="collapse-wrapper">
<div class="collapse-wrapper-inner">
@ChildContent
</div>
</div>

@ -27,10 +27,10 @@ public partial class Collapse : UIComponent
.Build();
protected string Classname =>
new CssBuilder("mud-collapse-container")
.AddClass($"mud-collapse-entering", _state == CollapseState.Entering)
.AddClass($"mud-collapse-entered", _state == CollapseState.Entered)
.AddClass($"mud-collapse-exiting", _state == CollapseState.Exiting)
new CssBuilder("collapse-container")
.AddClass($"collapse-entering", _state == CollapseState.Entering)
.AddClass($"collapse-entered", _state == CollapseState.Entered)
.AddClass($"collapse-exiting", _state == CollapseState.Exiting)
.AddClass(Class)
.Build();

@ -9,7 +9,7 @@
protected override RenderFragment PickerContent =>
@<CascadingValue Value="@this" IsFixed="true">
<PickerToolbar DisableToolbar="@DisableToolbar" Class="mud-picker-color-toolbar">
<PickerToolbar DisableToolbar="@DisableToolbar" Class="picker-color-toolbar">
@if (PickerVariant != PickerVariant.Static)
{
<IconButton Class="pa-1 mud-close-picker-button" Size="Size.Small" Color="ThemeColor.Inherit" Icon="@CloseIcon" OnClick="@GetEventCallback()" />
@ -19,19 +19,19 @@
<IconButton Class="pa-1 mx-1" Size="Size.Small" Color="GetButtonColor(ColorPickerView.Grid)" Icon="@GridIcon" OnClick="(() => ChangeView(ColorPickerView.Grid))" />
<IconButton Class="pa-1" Size="Size.Small" Color="GetButtonColor(ColorPickerView.Palette)" Icon="@PaletteIcon" OnClick="(() => ChangeView(ColorPickerView.Palette))" />
</PickerToolbar>
<PickerContent Class="mud-picker-color-content">
<PickerContent Class="picker-color-content">
@if (!DisableColorField)
{
<div class="mud-picker-color-picker">
<div class="picker-color-picker">
@if (_activeColorPickerView == ColorPickerView.Spectrum)
{
<div class="mud-picker-color-overlay" style="@($"background-color: {_baseColor.ToString(ColorOutputFormats.RGB)}")">
<div class="mud-picker-color-overlay mud-picker-color-overlay-white">
<div class="mud-picker-color-overlay mud-picker-color-overlay-black">
<div class="mud-picker-color-overlay" id="@_id" @onclick="OnColorOverlayClick">
<svg class="mud-picker-color-selector" height="26" width="26" style="transform: @GetSelectorLocation()" @onclick="OnSelectorClicked" @onclick:stopPropagation="true">
<div class="picker-color-overlay" style="@($"background-color: {_baseColor.ToString(ColorOutputFormats.RGB)}")">
<div class="picker-color-overlay mud-picker-color-overlay-white">
<div class="picker-color-overlay mud-picker-color-overlay-black">
<div class="picker-color-overlay" id="@_id" @onclick="OnColorOverlayClick">
<svg class="picker-color-selector" height="26" width="26" style="transform: @GetSelectorLocation()" @onclick="OnSelectorClicked" @onclick:stopPropagation="true">
<defs>
<filter id="mud-picker-color-selector-shadow" x="-50%" y="-50%" width="200%" height="200%">
<filter id="picker-color-selector-shadow" x="-50%" y="-50%" width="200%" height="200%">
<feGaussianBlur in="SourceAlpha" stdDeviation="1" />
<feOffset dx="0" dy="5" result="offsetblur" />
<feOffset dx="0" dy="-5" result="offsetblur" />
@ -48,7 +48,7 @@
}
@if (_activeColorPickerView is ColorPickerView.Grid or ColorPickerView.GridCompact)
{
<div class="mud-picker-color-grid">
<div class="picker-color-grid">
@foreach (var item in _gridList)
{
<div class="@GetColorDotClass(item)" style="@($"background: {item.ToString(ColorOutputFormats.RGBA)};")" @onclick="@GetSelectPaletteColorCallback(item)"></div>
@ -61,32 +61,32 @@
{
@if (!DisableSliders || !DisableInputs || !DisablePreview)
{
<div class="mud-picker-color-controls">
<div class="picker-color-controls">
@if (!DisableSliders || !DisablePreview)
{
<div class="mud-picker-color-controls-row">
<div class="picker-color-controls-row">
@if (!DisablePreview)
{
<div class="mud-picker-color-dot mud-picker-color-dot-current mud-ripple" @onclick="ToggleCollection">
<div class="mud-picker-color-fill" style="@($"background: {_color.ToString(ColorOutputFormats.RGBA)};")"></div>
<div class="picker-color-dot mud-picker-color-dot-current mud-ripple" @onclick="ToggleCollection">
<div class="picker-color-fill" style="@($"background: {_color.ToString(ColorOutputFormats.RGBA)};")"></div>
</div>
}
@if (!DisableSliders && !_collectionOpen)
{
<div class="mud-picker-color-sliders">
<div class="picker-color-sliders">
@if (_activeColorPickerView != ColorPickerView.Grid)
{
<Slider Class="mud-picker-color-slider hue" dir="ltr" T="int" Value="(int)_color.H" ValueChanged="UpdateBaseColorSlider" Step="1" Min="0" Max="360" />
<Slider Class="picker-color-slider hue" dir="ltr" T="int" Value="(int)_color.H" ValueChanged="UpdateBaseColorSlider" Step="1" Min="0" Max="360" />
}
@if (!DisableAlpha)
{
<Slider Class="mud-picker-color-slider alpha" Value="_color.A" ValueChanged="SetAlpha" T="int" Min="0" Max="255" Step="1" Style="@AlphaSliderStyle" />
<Slider Class="picker-color-slider alpha" Value="_color.A" ValueChanged="SetAlpha" T="int" Min="0" Max="255" Step="1" Style="@AlphaSliderStyle" />
}
</div>
}
@if (_collectionOpen)
{
<div class="mud-picker-color-collection">
<div class="picker-color-collection">
@foreach (var item in Palette.Take(5))
{
<div class="@GetColorDotClass(item)" style="@($"background: {item.ToString(ColorOutputFormats.RGBA)};")" @onclick="@GetSelectPaletteColorCallback(item)"></div>
@ -97,22 +97,22 @@
}
@if (!DisableInputs)
{
<div class="mud-picker-color-controls-row">
<div class="mud-picker-color-inputs">
<div class="picker-color-controls-row">
<div class="picker-color-inputs">
@switch (ColorPickerMode)
{
case ColorPickerMode.RGB:
<NumericField Value="_color.R" T="int" ValueChanged="SetR" Class="mud-picker-color-inputfield" HelperText="R" Min="0" Max="255" Variant="Variant.Outlined" HideSpinButtons="true" />
<NumericField Value="_color.G" T="int" ValueChanged="SetG" Class="mud-picker-color-inputfield" HelperText="G" Min="0" Max="255" Variant="Variant.Outlined" HideSpinButtons="true" />
<NumericField Value="_color.B" T="int" ValueChanged="SetB" Class="mud-picker-color-inputfield" HelperText="B" Min="0" Max="255" Variant="Variant.Outlined" HideSpinButtons="true" />
<NumericField Value="_color.R" T="int" ValueChanged="SetR" Class="picker-color-inputfield" HelperText="R" Min="0" Max="255" Variant="Variant.Outlined" HideSpinButtons="true" />
<NumericField Value="_color.G" T="int" ValueChanged="SetG" Class="picker-color-inputfield" HelperText="G" Min="0" Max="255" Variant="Variant.Outlined" HideSpinButtons="true" />
<NumericField Value="_color.B" T="int" ValueChanged="SetB" Class="picker-color-inputfield" HelperText="B" Min="0" Max="255" Variant="Variant.Outlined" HideSpinButtons="true" />
break;
case ColorPickerMode.HSL:
<NumericField Value="@_color.H" T="double" ValueChanged="SetH" Class="mud-picker-color-inputfield" HelperText="H" Step="1" Min="0" Max="360" Variant="Variant.Outlined" HideSpinButtons="true" />
<NumericField Value="@_color.S" T="double" ValueChanged="SetS" Class="mud-picker-color-inputfield" HelperText="S" Step="0.01" Min="0" Max="100" Variant="Variant.Outlined" HideSpinButtons="true" />
<NumericField Value="@_color.L" T="double" ValueChanged="SetL" Class="mud-picker-color-inputfield" HelperText="L" Step="0.01" Min="0" Max="100" Variant="Variant.Outlined" HideSpinButtons="true" />
<NumericField Value="@_color.H" T="double" ValueChanged="SetH" Class="picker-color-inputfield" HelperText="H" Step="1" Min="0" Max="360" Variant="Variant.Outlined" HideSpinButtons="true" />
<NumericField Value="@_color.S" T="double" ValueChanged="SetS" Class="picker-color-inputfield" HelperText="S" Step="0.01" Min="0" Max="100" Variant="Variant.Outlined" HideSpinButtons="true" />
<NumericField Value="@_color.L" T="double" ValueChanged="SetL" Class="picker-color-inputfield" HelperText="L" Step="0.01" Min="0" Max="100" Variant="Variant.Outlined" HideSpinButtons="true" />
break;
case ColorPickerMode.HEX:
<TextField Value="@GetColorTextValue()" ValueChanged="SetInputString" T="string" Class="mud-picker-color-inputfield" Variant="Variant.Outlined" MaxLength="@GetHexColorInputMaxLength()" HelperText="HEX" />
<TextField Value="@GetColorTextValue()" ValueChanged="SetInputString" T="string" Class="picker-color-inputfield" Variant="Variant.Outlined" MaxLength="@GetHexColorInputMaxLength()" HelperText="HEX" />
break;
default:
break;
@ -120,12 +120,12 @@
@if (!DisableAlpha && ColorPickerMode != ColorPickerMode.HEX)
{
<NumericField Value="@( Math.Round(_color.A / 255.0, 2))" T="double" ValueChanged="SetAlpha" Class="mud-picker-color-inputfield input-field-alpha" HelperText="A" Min="0" Max="1" Step="0.01" Variant="Variant.Outlined" HideSpinButtons="true" />
<NumericField Value="@( Math.Round(_color.A / 255.0, 2))" T="double" ValueChanged="SetAlpha" Class="picker-color-inputfield input-field-alpha" HelperText="A" Min="0" Max="1" Step="0.01" Variant="Variant.Outlined" HideSpinButtons="true" />
}
</div>
@if (!DisableModeSwitch)
{
<div class="mud-picker-control-switch">
<div class="picker-control-switch">
<IconButton OnClick="ChangeMode" Icon="@ImportExportIcon" Class="pa-1 me-n1"></IconButton>
</div>
}
@ -135,8 +135,8 @@
}
@if (_activeColorPickerView == ColorPickerView.Palette)
{
<div class="mud-picker-color-view">
<div class="mud-picker-color-view-collection">
<div class="picker-color-view">
<div class="picker-color-view-collection">
@foreach (var item in Palette)
{
<div class="@GetColorDotClass(item)" style="@($"background: {item.ToString(ColorOutputFormats.RGBA)};")" @onclick="@GetSelectPaletteColorCallback(item)"></div>

@ -535,7 +535,7 @@ public partial class ColorPicker : Picker<Color>, IAsyncDisposable
private EventCallback<MouseEventArgs> GetSelectPaletteColorCallback(Color color) => new EventCallbackFactory().Create(this, (MouseEventArgs e) => SelectPaletteColor(color));
private ThemeColor GetButtonColor(ColorPickerView view) => _activeColorPickerView == view ? ThemeColor.Primary : ThemeColor.Inherit;
private string GetColorDotClass(Color color) => new CssBuilder("mud-picker-color-dot").AddClass("selected", color == Value).ToString();
private string GetColorDotClass(Color color) => new CssBuilder("picker-color-dot").AddClass("selected", color == Value).ToString();
private string AlphaSliderStyle => new StyleBuilder().AddStyle($"background-image: linear-gradient(to {(RightToLeft ? "left" : "right")}, transparent, {_color.ToString(ColorOutputFormats.RGB)})").Build();
#endregion

@ -65,8 +65,8 @@ internal class Cell<T>
{
return new CssBuilder(_column.CellClassFunc?.Invoke(_item))
.AddClass(_column.CellClass)
.AddClass("mud-table-cell")
.AddClass("mud-table-cell-hide", _column.HideSmall)
.AddClass("table-cell")
.AddClass("table-cell-hide", _column.HideSmall)
.AddClass("sticky-left", _column.StickyLeft)
.AddClass("sticky-right", _column.StickyRight)
.AddClass($"edit-mode-cell", _dataGrid.EditMode == DataGridEditMode.Cell && _column.IsEditable)

@ -151,8 +151,8 @@ public partial class Column<T> : UIComponent
public Action ColumnStateHasChanged { get; set; }
internal string headerClassname =>
new CssBuilder("mud-table-cell")
.AddClass("mud-table-cell-hide", HideSmall)
new CssBuilder("table-cell")
.AddClass("table-cell-hide", HideSmall)
.AddClass("sticky-left", StickyLeft)
.AddClass("sticky-right", StickyRight)
.AddClass(Class)
@ -160,15 +160,15 @@ public partial class Column<T> : UIComponent
internal string cellClassname;
//internal string cellClassname =>
// new CssBuilder("mud-table-cell")
// .AddClass("mud-table-cell-hide", HideSmall)
// new CssBuilder("table-cell")
// .AddClass("table-cell-hide", HideSmall)
// .AddClass("sticky-right", StickyRight)
// .AddClass(Class)
// .Build();
internal string footerClassname =>
new CssBuilder("mud-table-cell")
.AddClass("mud-table-cell-hide", HideSmall)
new CssBuilder("table-cell")
.AddClass("table-cell-hide", HideSmall)
.AddClass(Class)
.Build();

@ -11,7 +11,7 @@
{
@if (ToolBarContent != null)
{
<ToolBar Class="mud-table-toolbar">
<ToolBar Class="table-toolbar">
@ToolBarContent
@if (ShowMenuIcon)
{
@ -24,14 +24,14 @@
@if (ShowMenuIcon)
{
@*Add the default toolbar.*@
<ToolBar Class="mud-table-toolbar">
<ToolBar Class="table-toolbar">
<Spacer />
@ToolbarMenu(this)
</ToolBar>
}
}
<div @ref=_gridElement class="@_tableClass" style="@_tableStyle">
<table class="mud-table-root">
<table class="table-root">
@if (ColGroup != null)
{
<colgroup>
@ -42,7 +42,7 @@
<CascadingValue Name="IsOnlyHeader" IsFixed="true" Value="true">
@Header
</CascadingValue>
<tr class="mud-table-row">
<tr class="table-row">
@foreach (var column in RenderedColumns)
{
<HeaderCell SortDirection="@(GetColumnSortDirection(column.Field))" T="T" Column="@column"></HeaderCell>
@ -96,7 +96,7 @@
}
@if (Filterable && FilterMode == DataGridFilterMode.ColumnFilterRow)
{
<tr class="mud-table-row">
<tr class="table-row">
@foreach (var column in RenderedColumns)
{
<FilterHeaderCell T="T" Column="@column" />
@ -104,12 +104,12 @@
</tr>
}
</thead>
<tbody class="mud-table-body">
<tbody class="table-body">
@if (Loading)
{
<tr>
<td colspan="1000" class="mud-table-loading">
<ProgressLinear Color="@LoadingProgressColor" Class="mud-table-loading-progress" Indeterminate="true" />
<td colspan="1000" class="table-loading">
<ProgressLinear Color="@LoadingProgressColor" Class="table-loading-progress" Indeterminate="true" />
</td>
</tr>
}
@ -121,13 +121,13 @@
{
foreach (var g in _groups)
{
<tr class="mud-table-row">
<tr class="table-row">
@{ var groupClass = new CssBuilder(GroupClass).AddClass(GroupClassFunc?.Invoke(g)).Build(); }
@{ var groupStyle = new StyleBuilder().AddStyle(GroupStyle).AddStyle(GroupStyleFunc?.Invoke(g)).Build(); }
<td class="mud-table-cell @groupClass" colspan="1000" style="background-color:var(--mud-palette-background-grey);@groupStyle">
<td class="table-cell @groupClass" colspan="1000" style="background-color:var(--mud-palette-background-grey);@groupStyle">
<IconButton
Class="mud-table-row-expander"
Class="table-row-expander"
Icon="@(g.IsExpanded ? Icons.Material.Filled.ExpandMore : Icons.Material.Filled.ChevronRight)"
OnClick="@(() => ToggleGroupExpansion(g))" />
@ -149,7 +149,7 @@
@{ var rowClass = new CssBuilder(RowClass).AddClass(RowClassFunc?.Invoke(item, rowIndex)).Build(); }
@{ var rowStyle = new StyleBuilder().AddStyle(RowStyle).AddStyle(RowStyleFunc?.Invoke(item, rowIndex)).Build(); }
@{ var tmpRowIndex = rowIndex; }
<tr class="mud-table-row @rowClass" Style="@rowStyle" @key="item" @onclick="@((args) => OnRowClickedAsync(args, item, tmpRowIndex))">
<tr class="table-row @rowClass" Style="@rowStyle" @key="item" @onclick="@((args) => OnRowClickedAsync(args, item, tmpRowIndex))">
<CascadingValue Value="@Validator" IsFixed="true">
@foreach (var column in RenderedColumns)
{
@ -162,8 +162,8 @@
</tr>
@if (ChildRowContent != null && (_openHierarchies.Contains(item) || !hasHierarchyColumn))
{
<tr class="mud-table-row">
<td class="mud-table-cell" colspan="1000">
<tr class="table-row">
<td class="table-cell" colspan="1000">
@ChildRowContent(new CellContext<T>(this, item))
</td>
</tr>
@ -171,7 +171,7 @@
@{ rowIndex++; }
</Virtualize>
@*Group Footer*@
<tr class="mud-table-row">
<tr class="table-row">
@FooterCells(g.Grouping.ToList())
</tr>
}
@ -184,7 +184,7 @@
@{ var rowClass = new CssBuilder(RowClass).AddClass(RowClassFunc?.Invoke(item, rowIndex)).Build(); }
@{ var rowStyle = new StyleBuilder().AddStyle(RowStyle).AddStyle(RowStyleFunc?.Invoke(item, rowIndex)).Build(); }
@{ var tmpRowIndex = rowIndex; }
<tr class="mud-table-row @rowClass" Style="@rowStyle" @key="item" @onclick="@((args) => OnRowClickedAsync(args, item, tmpRowIndex))">
<tr class="table-row @rowClass" Style="@rowStyle" @key="item" @onclick="@((args) => OnRowClickedAsync(args, item, tmpRowIndex))">
<CascadingValue Value="@Validator" IsFixed="true">
@foreach (var column in RenderedColumns)
{
@ -197,8 +197,8 @@
</tr>
@if (ChildRowContent != null && (_openHierarchies.Contains(item) || !hasHierarchyColumn))
{
<tr class="mud-table-row">
<td class="mud-table-cell" colspan="1000">
<tr class="table-row">
<td class="table-cell" colspan="1000">
@ChildRowContent(new CellContext<T>(this, item))
</td>
</tr>
@ -210,7 +210,7 @@
else if(Loading ? LoadingContent != null : NoRecordsContent != null)
{
<tr>
<th colspan="1000" class="mud-table-empty-row">
<th colspan="1000" class="table-empty-row">
<div Class="my-3">
@if(Loading)
{
@ -226,7 +226,7 @@
}
</tbody>
<tfoot class="@_footClassname">
<tr class="mud-table-row">
<tr class="table-row">
@FooterCells(resolvedPageItems)
</tr>
</tfoot>
@ -234,7 +234,7 @@
</div>
@if (PagerContent != null)
{
<div class="mud-table-pagination">
<div class="table-pagination">
@PagerContent
</div>
}

@ -29,22 +29,22 @@ public partial class DataGrid<T> : UIComponent
private PropertyInfo[] _properties = typeof(T).GetProperties();
protected string _classname =>
new CssBuilder("mud-table")
.AddClass("mud-data-grid")
.AddClass("mud-xs-table", Breakpoint == Breakpoint.Xs)
.AddClass("mud-sm-table", Breakpoint == Breakpoint.Sm)
.AddClass("mud-md-table", Breakpoint == Breakpoint.Md)
.AddClass("mud-lg-table", Breakpoint == Breakpoint.Lg || Breakpoint == Breakpoint.Always)
.AddClass("mud-xl-table", Breakpoint == Breakpoint.Xl || Breakpoint == Breakpoint.Always)
.AddClass("mud-table-dense", Dense)
.AddClass("mud-table-hover", Hover)
.AddClass("mud-table-bordered", Bordered)
.AddClass("mud-table-striped", Striped)
.AddClass("mud-table-outlined", Outlined)
.AddClass("mud-table-square", Square)
.AddClass("mud-table-sticky-header", FixedHeader)
.AddClass("mud-table-sticky-footer", FixedFooter)
.AddClass($"mud-elevation-{Elevation}", !Outlined)
new CssBuilder("table")
.AddClass("data-grid")
.AddClass("xs-table", Breakpoint == Breakpoint.Xs)
.AddClass("sm-table", Breakpoint == Breakpoint.Sm)
.AddClass("md-table", Breakpoint == Breakpoint.Md)
.AddClass("lg-table", Breakpoint == Breakpoint.Lg || Breakpoint == Breakpoint.Always)
.AddClass("xl-table", Breakpoint == Breakpoint.Xl || Breakpoint == Breakpoint.Always)
.AddClass("table-dense", Dense)
.AddClass("table-hover", Hover)
.AddClass("table-bordered", Bordered)
.AddClass("table-striped", Striped)
.AddClass("table-outlined", Outlined)
.AddClass("table-square", Square)
.AddClass("table-sticky-header", FixedHeader)
.AddClass("table-sticky-footer", FixedFooter)
.AddClass($"elevation-{Elevation}", !Outlined)
.AddClass(Class)
.Build();
@ -63,14 +63,14 @@ public partial class DataGrid<T> : UIComponent
.Build();
protected string _tableClass =>
new CssBuilder("mud-table-container")
new CssBuilder("table-container")
.AddClass("cursor-col-resize", when: IsResizing)
.Build();
protected string _headClassname => new CssBuilder("mud-table-head")
protected string _headClassname => new CssBuilder("table-head")
.AddClass(HeaderClass).Build();
protected string _footClassname => new CssBuilder("mud-table-foot")
protected string _footClassname => new CssBuilder("table-foot")
.AddClass(FooterClass).Build();
internal SortDirection GetColumnSortDirection(string columnName)

@ -3,27 +3,27 @@
@typeparam T
<ToolBar @attributes="UserAttributes" Class="@Classname" Style="@Style">
<div class="mud-table-pagination-spacer"></div>
<div class="table-pagination-spacer"></div>
@if (!DisableRowsPerPage)
{
<TextContent Typo="Typo.body2" Class="mud-table-pagination-caption">
<TextContent Typo="Typo.body2" Class="table-pagination-caption">
@RowsPerPageString
</TextContent>
<Select T="string" ValueChanged="@SetRowsPerPageAsync" Value="@DataGrid?.RowsPerPage.ToString()" Class="mud-table-pagination-select" DisableUnderLine="true" Dense="true" Disabled="@Disabled">
<Select T="string" ValueChanged="@SetRowsPerPageAsync" Value="@DataGrid?.RowsPerPage.ToString()" Class="table-pagination-select" DisableUnderLine="true" Dense="true" Disabled="@Disabled">
@foreach (int pageSize in PageSizeOptions)
{
<SelectItem T="string" Value="@pageSize.ToString()">@pageSize.ToString().ToUpper()</SelectItem>
}
</Select>
}
<TextContent Typo="Typo.body2" Class="mud-table-pagination-caption">
<TextContent Typo="Typo.body2" Class="table-pagination-caption">
@Info
</TextContent>
<div class="mud-table-pagination-actions">
<IconButton Class="mud-flip-x-rtl" Icon="@Icons.Material.Filled.FirstPage" Disabled="@BackButtonsDisabled" @onclick="@(() => DataGrid.NavigateTo(Page.First))"/>
<IconButton Class="mud-flip-x-rtl" Icon="@Icons.Material.Filled.NavigateBefore" Disabled="@BackButtonsDisabled" @onclick="@(() => DataGrid.NavigateTo(Page.Previous))"/>
<IconButton Class="mud-flip-x-rtl" Icon="@Icons.Material.Filled.NavigateNext" Disabled="@ForwardButtonsDisabled" @onclick="@(() => DataGrid.NavigateTo(Page.Next))"/>
<IconButton Class="mud-flip-x-rtl" Icon="@Icons.Material.Filled.LastPage" Disabled="@ForwardButtonsDisabled" @onclick="@(() => DataGrid.NavigateTo(Page.Last))"/>
<div class="table-pagination-actions">
<IconButton Class="flip-x-rtl" Icon="@Icons.Material.Filled.FirstPage" Disabled="@BackButtonsDisabled" @onclick="@(() => DataGrid.NavigateTo(Page.First))"/>
<IconButton Class="flip-x-rtl" Icon="@Icons.Material.Filled.NavigateBefore" Disabled="@BackButtonsDisabled" @onclick="@(() => DataGrid.NavigateTo(Page.Previous))"/>
<IconButton Class="flip-x-rtl" Icon="@Icons.Material.Filled.NavigateNext" Disabled="@ForwardButtonsDisabled" @onclick="@(() => DataGrid.NavigateTo(Page.Next))"/>
<IconButton Class="flip-x-rtl" Icon="@Icons.Material.Filled.LastPage" Disabled="@ForwardButtonsDisabled" @onclick="@(() => DataGrid.NavigateTo(Page.Last))"/>
</div>
</ToolBar>

@ -49,7 +49,7 @@ public partial class DataGridPager<T> : UIComponent, IDisposable
private bool ForwardButtonsDisabled => Disabled || (DataGrid == null ? false : (DataGrid.CurrentPage + 1) * DataGrid.RowsPerPage >= DataGrid.GetFilteredItemsCount());
protected string Classname =>
new CssBuilder("mud-table-pagination-toolbar")
new CssBuilder("table-pagination-toolbar")
.AddClass(Class)
.Build();

@ -4,7 +4,7 @@
@if (IsOnlyHeader)
{
<th scope="col" class="mud-table cell @_classname" style="" @attributes="@UserAttributes">
<th scope="col" class="table cell @_classname" style="" @attributes="@UserAttributes">
@ChildContent
</th>
}
@ -48,7 +48,7 @@ else if (Column != null && !Column.Hidden)
<IconButton Icon="@Column.SortIcon" Class="@sortIconClass" Size="@Size.Small" OnClick="@SortChangedAsync"></IconButton>
if(DataGrid.SortMode == SortMode.Multiple)
{
<span class="mud-sort-index mud-text-disabled">@(Column.SortIndex + 1)</span>
<span class="sort-index mud-text-disabled">@(Column.SortIndex + 1)</span>
}
}
}

@ -51,8 +51,8 @@ public partial class HeaderCell<T> : UIComponent, IDisposable
private string _resizerClass =>
new CssBuilder()
.AddClass("mud-resizing", when: _isResizing)
.AddClass("mud-resizer")
.AddClass("resizing", when: _isResizing)
.AddClass("resizer")
.Build();
private string _sortHeaderClass =>

@ -11,6 +11,6 @@ public partial class Row : UIComponent
{
[Parameter] public RenderFragment ChildContent { get; set; }
protected string Classname => new CssBuilder("mud-table-row")
protected string Classname => new CssBuilder("table-row")
.AddClass(Class).Build();
}

@ -63,14 +63,14 @@ public class DatePicker : DatePickerBase
protected override string GetDayClasses(int month, DateTime day)
{
var b = new CssBuilder("mud-day");
var b = new CssBuilder("day");
b.AddClass(AdditionalDateClassesFunc?.Invoke(day) ?? string.Empty);
if (day < GetMonthStart(month) || day > GetMonthEnd(month))
return b.AddClass("mud-hidden").Build();
return b.AddClass("hidden").Build();
if ((Date?.Date == day && _selectedDate == null) || _selectedDate?.Date == day)
return b.AddClass("mud-selected").AddClass($"mud-theme-{Color.ToDescriptionString()}").Build();
return b.AddClass("selected").AddClass($"theme-{Color.ToDescriptionString()}").Build();
if (day == DateTime.Today)
return b.AddClass("mud-current mud-button-outlined").AddClass($"mud-button-outlined-{Color.ToDescriptionString()} mud-{Color.ToDescriptionString()}-text").Build();
return b.AddClass("current mud-button-outlined").AddClass($"button-outlined-{Color.ToDescriptionString()} mud-{Color.ToDescriptionString()}-text").Build();
return b.Build();
}

@ -7,12 +7,12 @@
protected override RenderFragment PickerContent =>
@<CascadingValue Value="@this" IsFixed="true">
<PickerToolbar Class="mud-picker-datepicker-toolbar" DisableToolbar="@DisableToolbar" Orientation="@Orientation" Color="@Color">
<Button Variant="Variant.Text" Color="ThemeColor.Inherit" Class="mud-button-year" OnClick="OnYearClick">@GetFormattedYearString()</Button>
<Button Variant="Variant.Text" Color="ThemeColor.Inherit" Class="mud-button-date" OnClick="OnFormattedDateClick">@GetTitleDateString()</Button>
<PickerToolbar Class="picker-datepicker-toolbar" DisableToolbar="@DisableToolbar" Orientation="@Orientation" Color="@Color">
<Button Variant="Variant.Text" Color="ThemeColor.Inherit" Class="button-year" OnClick="OnYearClick">@GetFormattedYearString()</Button>
<Button Variant="Variant.Text" Color="ThemeColor.Inherit" Class="button-date" OnClick="OnFormattedDateClick">@GetTitleDateString()</Button>
</PickerToolbar>
<PickerContent>
<div class="mud-picker-calendar-content @($"mud-picker-calendar-content-{MaxMonthColumns ?? DisplayMonths}")">
<div class="picker-calendar-content @($"picker-calendar-content-{MaxMonthColumns ?? DisplayMonths}")">
@{
int dayId = 0;
@if (_picker_month.HasValue && _picker_month.Value.Year == 1 && _picker_month.Value.Month == 1)
@ -24,14 +24,14 @@
{
int tempMonth = displayMonth; //without local variable month names are wrong
<div class="mud-picker-calendar-container">
<div class="picker-calendar-container">
@if (tempMonth == 0 && CurrentView == OpenTo.Year)
{
<div id="pickerYears" class="mud-picker-year-container">
<div id="pickerYears" class="picker-year-container">
@for (int i = GetMinYear(); i <= GetMaxYear(); i++)
{
var year = i;
<div class="mud-picker-year" id="@(_componentId + year)" @onclick="(() => OnYearClicked(year))" @onclick:stopPropagation="true">
<div class="picker-year" id="@(_componentId + year)" @onclick="(() => OnYearClicked(year))" @onclick:stopPropagation="true">
<TextContent Typo="@GetYearTypo(year)" Class="@GetYearClasses(year)">@GetCalendarYear(year)</TextContent>
</div>
}
@ -43,26 +43,26 @@
var prevLabel = $"Go to previous year {calendarYear - 1}";
var nextLabel = $"Go to next year {calendarYear + 1}";
<div class="mud-picker-calendar-header">
<div class="mud-picker-calendar-header-switch">
<div class="picker-calendar-header">
<div class="picker-calendar-header-switch">
@if (!FixYear.HasValue)
{
<IconButton aria-label="@prevLabel" Icon="@PreviousIcon" OnClick="OnPreviousYearClick" Class="mud-flip-x-rtl" />
<button type="button" class="mud-picker-slide-transition mud-picker-calendar-header-transition" @onclick="OnYearClick" @onclick:stopPropagation="true">
<IconButton aria-label="@prevLabel" Icon="@PreviousIcon" OnClick="OnPreviousYearClick" Class="flip-x-rtl" />
<button type="button" class="picker-slide-transition mud-picker-calendar-header-transition" @onclick="OnYearClick" @onclick:stopPropagation="true">
<TextContent Typo="Typo.body1" Align="Align.Center">@calendarYear</TextContent>
</button>
<IconButton aria-label="@nextLabel" Icon="@NextIcon" OnClick="OnNextYearClick" Class="mud-flip-x-rtl" />
<IconButton aria-label="@nextLabel" Icon="@NextIcon" OnClick="OnNextYearClick" Class="flip-x-rtl" />
}
else
{
<TextContent Class="mud-picker-calendar-header-transition" Typo="Typo.body1" Align="Align.Center">@calendarYear</TextContent>
<TextContent Class="picker-calendar-header-transition" Typo="Typo.body1" Align="Align.Center">@calendarYear</TextContent>
}
</div>
</div>
<div class="mud-picker-month-container">
<div class="picker-month-container">
@foreach (var month in GetAllMonths())
{
<button type="button" aria-label="@GetMonthName(month)" class="mud-picker-month" @onclick="(() => OnMonthSelected(month))" @onclick:stopPropagation="true">
<button type="button" aria-label="@GetMonthName(month)" class="picker-month" @onclick="(() => OnMonthSelected(month))" @onclick:stopPropagation="true">
<TextContent Typo="@GetMonthTypo(month)" Class="@GetMonthClasses(month)">@GetAbbreviatedMonthName(month)</TextContent>
</button>
}
@ -74,35 +74,35 @@
var nextLabel = $"Go to next month {GetMonthName((tempMonth + 1) % 12)}";
<div class="@GetCalendarHeaderClasses(tempMonth)">
<div class="mud-picker-calendar-header-switch">
<div class="picker-calendar-header-switch">
@if (!FixMonth.HasValue)
{
<IconButton aria-label="@prevLabel" Class="mud-picker-nav-button-prev mud-flip-x-rtl" Icon="@PreviousIcon" OnClick="OnPreviousMonthClick" />
<button type="button" class="mud-picker-slide-transition mud-picker-calendar-header-transition mud-button-month" @onclick="(() => OnMonthClicked(tempMonth))" @onclick:stopPropagation="true">
<IconButton aria-label="@prevLabel" Class="picker-nav-button-prev mud-flip-x-rtl" Icon="@PreviousIcon" OnClick="OnPreviousMonthClick" />
<button type="button" class="picker-slide-transition mud-picker-calendar-header-transition mud-button-month" @onclick="(() => OnMonthClicked(tempMonth))" @onclick:stopPropagation="true">
<TextContent Typo="Typo.body1" Align="Align.Center">@GetMonthName(tempMonth)</TextContent>
</button>
<IconButton aria-label="@nextLabel" Class="mud-picker-nav-button-next mud-flip-x-rtl" Icon="@NextIcon" OnClick="OnNextMonthClick" />
<IconButton aria-label="@nextLabel" Class="picker-nav-button-next mud-flip-x-rtl" Icon="@NextIcon" OnClick="OnNextMonthClick" />
}
else
{
<TextContent Class="mud-picker-calendar-header-transition" Typo="Typo.body1" Align="Align.Center">@GetMonthName(tempMonth)</TextContent>
<TextContent Class="picker-calendar-header-transition" Typo="Typo.body1" Align="Align.Center">@GetMonthName(tempMonth)</TextContent>
}
</div>
<div class="mud-picker-calendar-header-day">
<div class="picker-calendar-header-day">
@if (ShowWeekNumbers)
{
<div class="mud-picker-calendar-week">
<Text Typo="Typo.caption" Class="mud-picker-calendar-week-text"></Text>
<div class="picker-calendar-week">
<Text Typo="Typo.caption" Class="picker-calendar-week-text"></Text>
</div>
}
@foreach (var dayname in GetAbbreviatedDayNames())
{
<TextContent Typo="Typo.caption" Class="mud-day-label">@dayname</TextContent>
<TextContent Typo="Typo.caption" Class="day-label">@dayname</TextContent>
}
</div>
</div>
<div class="mud-picker-calendar-transition mud-picker-slide-transition">
<div class="mud-picker-calendar">
<div class="picker-calendar-transition mud-picker-slide-transition">
<div class="picker-calendar">
@for (int week = 0; week < 6; week++)
{
int tempWeek = week;
@ -110,8 +110,8 @@
@if (ShowWeekNumbers)
{
<div class="mud-picker-calendar-week">
<Text class="mud-picker-calendar-week-text" Typo="Typo.caption">@GetWeekNumber(tempMonth, tempWeek)</Text>
<div class="picker-calendar-week">
<Text class="picker-calendar-week-text" Typo="Typo.caption">@GetWeekNumber(tempMonth, tempWeek)</Text>
</div>
}
@foreach (var day in GetWeek(tempMonth, tempWeek))
@ -122,21 +122,21 @@
{
var selectedDay = !firstMonthFirstYear ? day : day.AddDays(-1);
<button @key="@(!firstMonthFirstYear ? selectedDay : tempId)" type="button" style="--day-id: @(!firstMonthFirstYear ? tempId: tempId + 1);"
class="mud-button-root mud-icon-button mud-ripple mud-ripple-icon mud-picker-calendar-day @(!firstMonthFirstYear || day.Day == _picker_month.Value.Day? GetDayClasses(tempMonth, day) : GetDayClasses(tempMonth, selectedDay))"
class="button-root mud-icon-button mud-ripple mud-ripple-icon mud-picker-calendar-day @(!firstMonthFirstYear || day.Day == _picker_month.Value.Day? GetDayClasses(tempMonth, day) : GetDayClasses(tempMonth, selectedDay))"
@onclick="(() => { var d = selectedDay; OnDayClicked(d); })"
@onclick:stopPropagation="true"
aria-label='@selectedDay.ToString("dddd, dd MMMM yyyy")'
onmouseover="this.closest('.mud-picker-calendar-content').style.setProperty('--selected-day', @(!firstMonthFirstYear ? tempId: tempId + 1));"
disabled="@((selectedDay < MinDate) || (selectedDay > MaxDate) || IsDateDisabledFunc(selectedDay))">
<p class="mud-typography mud-typography-body2 mud-inherit-text">@GetCalendarDayOfMonth(selectedDay)</p>
<p class="typography mud-typography-body2 mud-inherit-text">@GetCalendarDayOfMonth(selectedDay)</p>
</button>
}
else
{
<button @key="0" type="button" style="--day-id: 1;"
class="mud-button-root mud-icon-button mud-ripple mud-ripple-icon mud-picker-calendar-day mud-day"
class="button-root mud-icon-button mud-ripple mud-ripple-icon mud-picker-calendar-day mud-day"
aria-label='' disabled>
<p class="mud-typography mud-typography-body2 mud-inherit-text"></p>
<p class="typography mud-typography-body2 mud-inherit-text"></p>
</button>
}
}

@ -497,15 +497,15 @@ public abstract partial class DatePickerBase : Picker<DateTime?>
private string GetYearClasses(int year)
{
if (year == GetMonthStart(0).Year)
return $"mud-picker-year-selected mud-{Color.ToDescriptionString()}-text";
return $"picker-year-selected mud-{Color.ToDescriptionString()}-text";
return null;
}
private string GetCalendarHeaderClasses(int month)
{
return new CssBuilder("mud-picker-calendar-header")
.AddClass($"mud-picker-calendar-header-{month + 1}")
.AddClass($"mud-picker-calendar-header-last", month == DisplayMonths - 1)
return new CssBuilder("picker-calendar-header")
.AddClass($"picker-calendar-header-{month + 1}")
.AddClass($"picker-calendar-header-last", month == DisplayMonths - 1)
.Build();
}
@ -546,7 +546,7 @@ public abstract partial class DatePickerBase : Picker<DateTime?>
private string GetMonthClasses(DateTime month)
{
if (GetMonthStart(0) == month)
return $"mud-picker-month-selected mud-{Color.ToDescriptionString()}-text";
return $"picker-month-selected mud-{Color.ToDescriptionString()}-text";
return null;
}

@ -168,61 +168,61 @@ public partial class DateRangePicker : DatePickerBase
protected override string GetDayClasses(int month, DateTime day)
{
var b = new CssBuilder("mud-day");
var b = new CssBuilder("day");
if (day < GetMonthStart(month) || day > GetMonthEnd(month))
{
return b.AddClass("mud-hidden").Build();
return b.AddClass("hidden").Build();
}
if ((_firstDate != null && _secondDate != null && _firstDate < day && _secondDate > day) ||
(_firstDate == null && _dateRange != null && _dateRange.Start < day && _dateRange.End > day))
{
return b
.AddClass("mud-range")
.AddClass("mud-range-between")
.AddClass("range")
.AddClass("range-between")
.Build();
}
if ((_firstDate != null && day == _firstDate) ||
(_firstDate == null && _dateRange != null && _dateRange.Start == day && DateRange.End != day))
{
return b.AddClass("mud-selected")
.AddClass("mud-range")
.AddClass("mud-range-start-selected")
.AddClass("mud-range-selection", _firstDate != null)
.AddClass($"mud-theme-{Color.ToDescriptionString()}")
return b.AddClass("selected")
.AddClass("range")
.AddClass("range-start-selected")
.AddClass("range-selection", _firstDate != null)
.AddClass($"theme-{Color.ToDescriptionString()}")
.Build();
}
if ((_firstDate != null && _secondDate != null && day == _secondDate) ||
(_firstDate == null && _dateRange != null && _dateRange.Start != day && _dateRange.End == day))
{
return b.AddClass("mud-selected")
.AddClass("mud-range")
.AddClass("mud-range-end-selected")
.AddClass($"mud-theme-{Color.ToDescriptionString()}")
return b.AddClass("selected")
.AddClass("range")
.AddClass("range-end-selected")
.AddClass($"theme-{Color.ToDescriptionString()}")
.Build();
}
if (_firstDate == null && _dateRange != null && _dateRange.Start == _dateRange.End && _dateRange.Start == day)
{
return b.AddClass("mud-selected").AddClass($"mud-theme-{Color.ToDescriptionString()}").Build();
return b.AddClass("selected").AddClass($"theme-{Color.ToDescriptionString()}").Build();
}
else if (_firstDate != null && day > _firstDate)
{
return b.AddClass("mud-range")
.AddClass("mud-range-selection", _secondDate == null)
.AddClass($"mud-range-selection-{Color.ToDescriptionString()}", _firstDate != null)
return b.AddClass("range")
.AddClass("range-selection", _secondDate == null)
.AddClass($"range-selection-{Color.ToDescriptionString()}", _firstDate != null)
.Build();
}
if (day == DateTime.Today)
{
return b.AddClass("mud-current")
.AddClass("mud-range", _firstDate != null && day > _firstDate)
.AddClass("mud-range-selection", _firstDate != null && day > _firstDate)
.AddClass($"mud-range-selection-{Color.ToDescriptionString()}", _firstDate != null && day > _firstDate)
.AddClass($"mud-{Color.ToDescriptionString()}-text")
return b.AddClass("current")
.AddClass("range", _firstDate != null && day > _firstDate)
.AddClass("range-selection", _firstDate != null && day > _firstDate)
.AddClass($"range-selection-{Color.ToDescriptionString()}", _firstDate != null && day > _firstDate)
.AddClass($"{Color.ToDescriptionString()}-text")
.Build();
}

@ -10,12 +10,12 @@ namespace Connected.Components;
public partial class Dialog : UIComponent
{
protected string ContentClass => new CssBuilder("mud-dialog-content")
.AddClass($"mud-dialog-no-side-padding", DisableSidePadding)
protected string ContentClass => new CssBuilder("dialog-content")
.AddClass($"dialog-no-side-padding", DisableSidePadding)
.AddClass(ClassContent)
.Build();
protected string ActionClass => new CssBuilder("mud-dialog-actions")
protected string ActionClass => new CssBuilder("dialog-actions")
.AddClass(ClassActions)
.Build();

@ -1,12 +1,12 @@
@namespace Connected.Components
@inherits UIComponent
<div @attributes="UserAttributes" id="@_elementId" class="mud-dialog-container @Position">
<Overlay Visible="true" OnClick="HandleBackgroundClick" Class="mud-overlay-dialog" DarkBackground="true" />
<div @attributes="UserAttributes" id="@_elementId" class="dialog-container @Position">
<Overlay Visible="true" OnClick="HandleBackgroundClick" Class="overlay-dialog" DarkBackground="true" />
<div id="_@Id.ToString("N")" role="dialog" class="@Classname" style="@Style">
@if (!NoHeader)
{
<div class="mud-dialog-title">
<div class="dialog-title">
@if (TitleContent == null)
{
<TextContent Typo="Typo.h6">@Title</TextContent>

@ -84,7 +84,7 @@ public partial class DialogInstance : UIComponent, IDisposable
await _keyInterceptor.Connect(_elementId, new KeyInterceptorOptions()
{
TargetClass = "mud-dialog",
TargetClass = "dialog",
Keys = {
new KeyOptions { Key="Escape", SubscribeDown = true },
},
@ -191,7 +191,7 @@ public partial class DialogInstance : UIComponent, IDisposable
{
position = DialogPosition.Center;
}
return $"mud-dialog-{position.ToDescriptionString()}";
return $"dialog-{position.ToDescriptionString()}";
}
private string SetMaxWidth()
@ -210,7 +210,7 @@ public partial class DialogInstance : UIComponent, IDisposable
{
maxWidth = MaxWidth.Small;
}
return $"mud-dialog-width-{maxWidth.ToDescriptionString()}";
return $"dialog-width-{maxWidth.ToDescriptionString()}";
}
private bool SetFullWidth()
@ -236,11 +236,11 @@ public partial class DialogInstance : UIComponent, IDisposable
}
protected string Classname =>
new CssBuilder("mud-dialog")
new CssBuilder("dialog")
.AddClass(DialogMaxWidth, !FullScreen)
.AddClass("mud-dialog-width-full", FullWidth && !FullScreen)
.AddClass("mud-dialog-fullscreen", FullScreen)
.AddClass("mud-dialog-rtl", RightToLeft)
.AddClass("dialog-width-full", FullWidth && !FullScreen)
.AddClass("dialog-fullscreen", FullScreen)
.AddClass("dialog-rtl", RightToLeft)
.AddClass(_dialog?.Class)
.Build();

@ -7,12 +7,12 @@ namespace Connected.Components;
public partial class Divider : UIComponent
{
protected string Classname =>
new CssBuilder("mud-divider")
.AddClass($"mud-divider-absolute", Absolute)
.AddClass($"mud-divider-flexitem", FlexItem)
.AddClass($"mud-divider-light", Light)
.AddClass($"mud-divider-vertical", Vertical)
.AddClass($"mud-divider-{DividerType.ToDescriptionString()}", when: () => DividerType != DividerType.FullWidth)
new CssBuilder("divider")
.AddClass($"divider-absolute", Absolute)
.AddClass($"divider-flexitem", FlexItem)
.AddClass($"divider-light", Light)
.AddClass($"divider-vertical", Vertical)
.AddClass($"divider-{DividerType.ToDescriptionString()}", when: () => DividerType != DividerType.FullWidth)
.AddClass(Class)
.Build();

@ -2,7 +2,7 @@
@inherits UIComponent
<aside @onmouseenter="OnMouseEnter" @onmouseleave="OnMouseLeave" @attributes="UserAttributes" class="@Classname" style="@Stylename">
<div @ref="_contentRef" class="mud-drawer-content">
<div @ref="_contentRef" class="drawer-content">
<CascadingValue Value="this" IsFixed="true">
@ChildContent
</CascadingValue>

@ -22,27 +22,27 @@ public partial class Drawer : UIComponent, IDisposable, INavigationEventReceiver
(_screenBreakpoint < Breakpoint && Variant == DrawerVariant.Responsive));
protected string Classname =>
new CssBuilder("mud-drawer")
.AddClass($"mud-drawer-fixed", Fixed)
.AddClass($"mud-drawer-pos-{GetPosition()}")
.AddClass($"mud-drawer--open", Open)
.AddClass($"mud-drawer--closed", !Open)
.AddClass($"mud-drawer--initial", _initial)
.AddClass($"mud-drawer-{Breakpoint.ToDescriptionString()}")
.AddClass($"mud-drawer-clipped-{_clipMode.ToDescriptionString()}")
.AddClass($"mud-theme-{Color.ToDescriptionString()}", Color != ThemeColor.Default)
.AddClass($"mud-elevation-{Elevation}")
.AddClass($"mud-drawer-{Variant.ToDescriptionString()}")
new CssBuilder("drawer")
.AddClass($"drawer-fixed", Fixed)
.AddClass($"drawer-pos-{GetPosition()}")
.AddClass($"drawer--open", Open)
.AddClass($"drawer--closed", !Open)
.AddClass($"drawer--initial", _initial)
.AddClass($"drawer-{Breakpoint.ToDescriptionString()}")
.AddClass($"drawer-clipped-{_clipMode.ToDescriptionString()}")
.AddClass($"theme-{Color.ToDescriptionString()}", Color != ThemeColor.Default)
.AddClass($"elevation-{Elevation}")
.AddClass($"drawer-{Variant.ToDescriptionString()}")
.AddClass(Class)
.Build();
protected string OverlayClass =>
new CssBuilder("mud-drawer-overlay mud-overlay-drawer")
.AddClass($"mud-drawer-pos-{GetPosition()}")
.AddClass($"mud-drawer-overlay--open", Open)
.AddClass($"mud-drawer-overlay-{Variant.ToDescriptionString()}")
.AddClass($"mud-drawer-overlay-{Breakpoint.ToDescriptionString()}")
.AddClass($"mud-drawer-overlay--initial", _initial)
new CssBuilder("drawer-overlay mud-overlay-drawer")
.AddClass($"drawer-pos-{GetPosition()}")
.AddClass($"drawer-overlay--open", Open)
.AddClass($"drawer-overlay-{Variant.ToDescriptionString()}")
.AddClass($"drawer-overlay-{Breakpoint.ToDescriptionString()}")
.AddClass($"drawer-overlay--initial", _initial)
.Build();
protected string Stylename =>

@ -54,7 +54,7 @@ public partial class DrawerContainer : UIComponent
if (drawer == null)
return string.Empty;
var className = $"mud-drawer-{(drawer.Open ? "open" : "close")}-{drawer.Variant.ToDescriptionString()}";
var className = $"drawer-{(drawer.Open ? "open" : "close")}-{drawer.Variant.ToDescriptionString()}";
if (drawer.Variant is DrawerVariant.Responsive or DrawerVariant.Mini)
{
className += $"-{drawer.Breakpoint.ToDescriptionString()}";

@ -6,8 +6,8 @@ namespace Connected.Components;
public partial class DrawerHeader : UIComponent
{
protected string Classname =>
new CssBuilder("mud-drawer-header")
.AddClass($"mud-drawer-header-dense", Dense)
new CssBuilder("drawer-header")
.AddClass($"drawer-header-dense", Dense)
.AddClass(Class)
.Build();

@ -148,7 +148,7 @@ public partial class DropContainer<T> : UIComponent
private DragAndDropItemTransaction<T> _transaction;
protected string Classname =>
new CssBuilder("mud-drop-container")
new CssBuilder("drop-container")
.AddClass(Class)
.Build();

@ -4,7 +4,7 @@
<div class="@Classname" style="@Style"
id="@($"mud-drop-zone-{_id}")"
id="@($"drop-zone-{_id}")"
@ondrop="HandleDrop"
@ondragenter="HandleDragEnter"
@ondragleave="HandleDragLeave"
@ -34,7 +34,7 @@
Item="default"
ZoneIdentifier="@Identifier"
Disabled="true" HideContent="false"
Class="mud-drop-item-preview-start"/>
Class="drop-item-preview-start"/>
}
}
@foreach (var item in items)

@ -179,8 +179,8 @@ public partial class DropZone<T> : UIComponent, IDisposable
}
protected string Classname =>
new CssBuilder("mud-drop-zone")
//.AddClass("mud-drop-zone-drag-block", Container?.TransactionInProgress() == true && Container.GetTransactionOrignZoneIdentiifer() != Identifier)
new CssBuilder("drop-zone")
//.AddClass("drop-zone-drag-block", Container?.TransactionInProgress() == true && Container.GetTransactionOrignZoneIdentiifer() != Identifier)
.AddClass(CanDropClass ?? Container?.CanDropClass, Container?.TransactionInProgress() == true && Container.GetTransactionOrignZoneIdentiifer() != Identifier && _canDrop == true && (_dragCounter > 0 || GetApplyDropClassesOnDragStarted() == true))
.AddClass(NoDropClass ?? Container?.NoDropClass, Container?.TransactionInProgress() == true && Container.GetTransactionOrignZoneIdentiifer() != Identifier && _canDrop == false && (_dragCounter > 0 || GetApplyDropClassesOnDragStarted() == true))
.AddClass(GetDragginClass(), _dragInProgress == true)

@ -134,7 +134,7 @@ public partial class DynamicDropItem<T> : UIComponent
#endregion
protected string Classname =>
new CssBuilder("mud-drop-item")
new CssBuilder("drop-item")
.AddClass(DraggingClass, _dragOperationIsInProgress == true)
.AddClass(DisabledClass, Disabled == true)
.AddClass(Class)

@ -2,8 +2,8 @@
@inherits UIComponent
<div @attributes="UserAttributes" class="@Classname" style="@Style">
<div class="mud-expand-panel-header" @onclick="ToggleExpansion">
<div class="mud-expand-panel-text">
<div class="expand-panel-header" @onclick="ToggleExpansion">
<div class="expand-panel-text">
@if (TitleContent != null)
{
@TitleContent
@ -15,7 +15,7 @@
</div>
@if (!HideIcon)
{
<Icon Icon="@Icon" class="@(IsExpanded? "mud-expand-panel-icon mud-transform" : "mud-expand-panel-icon")" />
<Icon Icon="@Icon" class="@(IsExpanded? "expand-panel-icon mud-transform" : "expand-panel-icon")" />
}
</div>
<Collapse Expanded="@_collapseIsExpanded" MaxHeight="@MaxHeight">

@ -13,19 +13,19 @@ public partial class ExpansionPanel : UIComponent, IDisposable
[CascadingParameter] private ExpansionPanels Parent { get; set; }
protected string Classname =>
new CssBuilder("mud-expand-panel")
.AddClass("mud-panel-expanded", IsExpanded)
.AddClass("mud-panel-next-expanded", NextPanelExpanded)
.AddClass("mud-disabled", Disabled)
.AddClass($"mud-elevation-{Parent?.Elevation.ToString()}")
.AddClass($"mud-expand-panel-border", Parent?.DisableBorders != true)
new CssBuilder("expand-panel")
.AddClass("panel-expanded", IsExpanded)
.AddClass("panel-next-expanded", NextPanelExpanded)
.AddClass("disabled", Disabled)
.AddClass($"elevation-{Parent?.Elevation.ToString()}")
.AddClass($"expand-panel-border", Parent?.DisableBorders != true)
.AddClass(Class)
.Build();
protected string PanelContentClassname =>
new CssBuilder("mud-expand-panel-content")
.AddClass("mud-expand-panel-gutters", DisableGutters || Parent?.DisableGutters == true)
.AddClass("mud-expand-panel-dense", Dense || Parent?.Dense == true)
new CssBuilder("expand-panel-content")
.AddClass("expand-panel-gutters", DisableGutters || Parent?.DisableGutters == true)
.AddClass("expand-panel-dense", Dense || Parent?.Dense == true)
.Build();
/// <summary>

@ -8,8 +8,8 @@ namespace Connected.Components;
public partial class ExpansionPanels : UIComponent
{
protected string Classname =>
new CssBuilder("mud-expansion-panels")
.AddClass($"mud-expansion-panels-square", Square)
new CssBuilder("expansion-panels")
.AddClass($"expansion-panels-square", Square)
.AddClass(Class)
.Build();

@ -18,7 +18,7 @@
}
@if (Variant == Variant.Outlined)
{
<div class="mud-input-outlined-border"></div>
<div class="input-outlined-border"></div>
}
</div>
</InputContent>

@ -10,34 +10,34 @@ namespace Connected.Components;
public partial class Field : UIComponent
{
protected string Classname =>
new CssBuilder("mud-input")
.AddClass($"mud-input-{Variant.ToDescriptionString()}")
.AddClass($"mud-input-adorned-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"mud-input-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
.AddClass("mud-input-underline", when: () => DisableUnderLine == false && Variant != Variant.Outlined)
.AddClass("mud-shrink", when: () => !string.IsNullOrWhiteSpace(ChildContent?.ToString()) || Adornment == Adornment.Start)
.AddClass("mud-disabled", Disabled)
.AddClass("mud-input-error", Error && !string.IsNullOrEmpty(ErrorText))
new CssBuilder("input")
.AddClass($"input-{Variant.ToDescriptionString()}")
.AddClass($"input-adorned-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"input-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
.AddClass("input-underline", when: () => DisableUnderLine == false && Variant != Variant.Outlined)
.AddClass("shrink", when: () => !string.IsNullOrWhiteSpace(ChildContent?.ToString()) || Adornment == Adornment.Start)
.AddClass("disabled", Disabled)
.AddClass("input-error", Error && !string.IsNullOrEmpty(ErrorText))
.Build();
protected string InnerClassname =>
new CssBuilder("mud-input-slot")
.AddClass("mud-input-root")
.AddClass("mud-input-slot-nopadding", when: () => InnerPadding == false)
.AddClass($"mud-input-root-{Variant.ToDescriptionString()}")
.AddClass($"mud-input-adorned-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"mud-input-root-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
new CssBuilder("input-slot")
.AddClass("input-root")
.AddClass("input-slot-nopadding", when: () => InnerPadding == false)
.AddClass($"input-root-{Variant.ToDescriptionString()}")
.AddClass($"input-adorned-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"input-root-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
.Build();
protected string AdornmentClassname =>
new CssBuilder("mud-input-adornment")
.AddClass($"mud-input-adornment-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"mud-text", !string.IsNullOrEmpty(AdornmentText))
.AddClass($"mud-input-root-filled-shrink", Variant == Variant.Filled)
new CssBuilder("input-adornment")
.AddClass($"input-adornment-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"text", !string.IsNullOrEmpty(AdornmentText))
.AddClass($"input-root-filled-shrink", Variant == Variant.Filled)
.Build();
protected string InputControlClassname =>
new CssBuilder("mud-field")
new CssBuilder("field")
.AddClass(Class)
.Build();

@ -17,7 +17,7 @@ public partial class FileUpload<T> : FormComponent<T, string>
private readonly string _id = $"mud_fileupload_{Guid.NewGuid()}";
protected string Classname =>
new CssBuilder("mud-file-upload")
new CssBuilder("file-upload")
.AddClass(Class)
.Build();

@ -7,7 +7,7 @@ namespace Connected.Components;
public partial class Form : UIComponent, IDisposable, IForm
{
protected string Classname =>
new CssBuilder("mud-form")
new CssBuilder("form")
.AddClass(Class)
.Build();

@ -8,11 +8,11 @@ namespace Connected.Components;
public partial class Icon : UIComponent
{
protected string Classname =>
new CssBuilder("mud-icon-root")
.AddClass($"mud-icon-default", Color == ThemeColor.Default)
.AddClass($"mud-svg-icon", !string.IsNullOrEmpty(Glyph) && Glyph.Trim().StartsWith(("<")))
.AddClass($"mud-{Color.ToDescriptionString()}-text", Color != ThemeColor.Default && Color != ThemeColor.Inherit)
.AddClass($"mud-icon-size-{Size.ToDescriptionString()}")
new CssBuilder("icon-root")
.AddClass($"icon-default", Color == ThemeColor.Default)
.AddClass($"svg-icon", !string.IsNullOrEmpty(Glyph) && Glyph.Trim().StartsWith(("<")))
.AddClass($"{Color.ToDescriptionString()}-text", Color != ThemeColor.Default && Color != ThemeColor.Inherit)
.AddClass($"icon-size-{Size.ToDescriptionString()}")
.AddClass(Class)
.Build();

@ -12,11 +12,11 @@ namespace Connected.Components;
public partial class Image : UIComponent
{
protected string Classname =>
new CssBuilder("mud-image")
new CssBuilder("image")
.AddClass("fluid", Fluid)
.AddClass($"object-{ObjectFit.ToDescriptionString()}")
.AddClass($"object-{ObjectPosition.ToDescriptionString()}")
.AddClass($"mud-elevation-{Elevation}", Elevation > 0)
.AddClass($"elevation-{Elevation}", Elevation > 0)
.AddClass(Class)
.Build();

@ -128,12 +128,12 @@
@if (Variant == Variant.Outlined)
{
<div class="mud-input-outlined-border"></div>
<div class="input-outlined-border"></div>
}
@if (!HideSpinButtons)
{
<div class="mud-input-numeric-spin">
<div class="input-numeric-spin">
<Button Variant="Variant.Text" @onclick="OnIncrement" Disabled="@(Disabled || ReadOnly)" tabindex="-1">
<Icon Icon="@NumericUpIcon" Size="@GetButtonSize()" />
</Button>

@ -17,9 +17,9 @@ public partial class Input<T> : InputBase<T>
protected string ClearButtonClassname =>
new CssBuilder()
.AddClass("me-n1", Adornment == Adornment.End && HideSpinButtons == false)
.AddClass("mud-icon-button-edge-end", Adornment == Adornment.End && HideSpinButtons == true)
.AddClass("icon-button-edge-end", Adornment == Adornment.End && HideSpinButtons == true)
.AddClass("me-6", Adornment != Adornment.End && HideSpinButtons == false)
.AddClass("mud-icon-button-edge-margin-end", Adornment != Adornment.End && HideSpinButtons == true)
.AddClass("icon-button-edge-margin-end", Adornment != Adornment.End && HideSpinButtons == true)
.Build();
/// <summary>

@ -6,32 +6,32 @@ namespace Connected.Components;
internal static class InputCssHelper
{
public static string GetClassname<T>(InputBase<T> baseInput, Func<bool> shrinkWhen) =>
new CssBuilder("mud-input")
.AddClass($"mud-input-{baseInput.Variant.ToDescriptionString()}")
.AddClass($"mud-input-adorned-{baseInput.Adornment.ToDescriptionString()}", baseInput.Adornment != Adornment.None)
.AddClass($"mud-input-margin-{baseInput.Margin.ToDescriptionString()}", when: () => baseInput.Margin != Margin.None)
.AddClass("mud-input-underline", when: () => baseInput.DisableUnderLine == false && baseInput.Variant != Variant.Outlined)
.AddClass("mud-shrink", when: shrinkWhen)
.AddClass("mud-disabled", baseInput.Disabled)
.AddClass("mud-input-error", baseInput.HasErrors)
.AddClass("mud-ltr", baseInput.GetInputType() == InputType.Email || baseInput.GetInputType() == InputType.Telephone)
new CssBuilder("input")
.AddClass($"input-{baseInput.Variant.ToDescriptionString()}")
.AddClass($"input-adorned-{baseInput.Adornment.ToDescriptionString()}", baseInput.Adornment != Adornment.None)
.AddClass($"input-margin-{baseInput.Margin.ToDescriptionString()}", when: () => baseInput.Margin != Margin.None)
.AddClass("input-underline", when: () => baseInput.DisableUnderLine == false && baseInput.Variant != Variant.Outlined)
.AddClass("shrink", when: shrinkWhen)
.AddClass("disabled", baseInput.Disabled)
.AddClass("input-error", baseInput.HasErrors)
.AddClass("ltr", baseInput.GetInputType() == InputType.Email || baseInput.GetInputType() == InputType.Telephone)
.AddClass(baseInput.Class)
.Build();
public static string GetInputClassname<T>(InputBase<T> baseInput) =>
new CssBuilder("mud-input-slot")
.AddClass("mud-input-root")
.AddClass($"mud-input-root-{baseInput.Variant.ToDescriptionString()}")
.AddClass($"mud-input-root-adorned-{baseInput.Adornment.ToDescriptionString()}", baseInput.Adornment != Adornment.None)
.AddClass($"mud-input-root-margin-{baseInput.Margin.ToDescriptionString()}", when: () => baseInput.Margin != Margin.None)
new CssBuilder("input-slot")
.AddClass("input-root")
.AddClass($"input-root-{baseInput.Variant.ToDescriptionString()}")
.AddClass($"input-root-adorned-{baseInput.Adornment.ToDescriptionString()}", baseInput.Adornment != Adornment.None)
.AddClass($"input-root-margin-{baseInput.Margin.ToDescriptionString()}", when: () => baseInput.Margin != Margin.None)
.AddClass(baseInput.Class)
.Build();
public static string GetAdornmentClassname<T>(InputBase<T> baseInput) =>
new CssBuilder("mud-input-adornment")
.AddClass($"mud-input-adornment-{baseInput.Adornment.ToDescriptionString()}", baseInput.Adornment != Adornment.None)
.AddClass($"mud-text", !string.IsNullOrEmpty(baseInput.AdornmentText))
.AddClass($"mud-input-root-filled-shrink", baseInput.Variant == Variant.Filled)
new CssBuilder("input-adornment")
.AddClass($"input-adornment-{baseInput.Adornment.ToDescriptionString()}", baseInput.Adornment != Adornment.None)
.AddClass($"text", !string.IsNullOrEmpty(baseInput.AdornmentText))
.AddClass($"input-root-filled-shrink", baseInput.Variant == Variant.Filled)
.AddClass(baseInput.Class)
.Build();
}

@ -7,12 +7,12 @@ public partial class InputLabel : UIComponent
{
protected string Classname =>
new Utilities.CssBuilder()
.AddClass("mud-input-label")
.AddClass("mud-input-label-animated")
.AddClass($"mud-input-label-{Variant.ToDescriptionString()}")
.AddClass($"mud-input-label-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
.AddClass($"mud-disabled", Disabled)
.AddClass("mud-input-error", Error)
.AddClass("input-label")
.AddClass("input-label-animated")
.AddClass($"input-label-{Variant.ToDescriptionString()}")
.AddClass($"input-label-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
.AddClass($"disabled", Disabled)
.AddClass("input-error", Error)
.AddClass(Class)
.Build();

@ -17,7 +17,7 @@
<input @ref="_elementReferenceStart" @attributes="UserAttributes" type="@InputTypeString" class="@InputClassname" @bind-value="@TextStart" @bind-value:event="@((Immediate ? "oninput" : "onchange"))"
placeholder="@PlaceholderStart" disabled=@Disabled readonly="@ReadOnly" @onblur="@OnBlurred" @onkeydown="@InvokeKeyDown" @onkeypress="@InvokeKeyPress" @onkeyup="@InvokeKeyUp" inputmode="@InputMode.ToString()" pattern="@Pattern" />
<Icon Class="mud-range-input-separator mud-flip-x-rtl" Icon="@SeparatorIcon" Color="@ThemeColor.Default" />
<Icon Class="range-input-separator mud-flip-x-rtl" Icon="@SeparatorIcon" Color="@ThemeColor.Default" />
<input @ref="_elementReferenceEnd" @attributes="UserAttributes" type="@InputTypeString" class="@InputClassname" @bind-value="@TextEnd" @bind-value:event="@((Immediate ? "oninput" : "onchange"))" inputmode="@InputMode.ToString()" pattern="@Pattern"
placeholder="@PlaceholderEnd" disabled=@Disabled readonly="@ReadOnly" @onblur="@OnBlurred" @onkeydown="@InvokeKeyDown" @onkeypress="@InvokeKeyPress" @onkeyup="@InvokeKeyUp" />
@ -28,6 +28,6 @@
@if (Variant == Variant.Outlined)
{
<div class="mud-input-outlined-border"></div>
<div class="input-outlined-border"></div>
}
</div>

@ -2,11 +2,11 @@
@inherits UIComponent
<div @attributes="UserAttributes" class="@Classname" style="@Style">
<div class="mud-input-control-input-container">
<div class="input-control-input-container">
@InputContent
@if (!String.IsNullOrEmpty(Label))
{
<InputLabel Class="mud-input-label-inputcontrol" Variant="@Variant" Disabled=@Disabled Error="@Error"
<InputLabel Class="input-label-inputcontrol" Variant="@Variant" Disabled=@Disabled Error="@Error"
Margin="@Margin" ForId="@ForId">
@Label
</InputLabel>

@ -7,24 +7,24 @@ namespace Connected.Components;
public partial class InputControl : UIComponent
{
protected string Classname =>
new CssBuilder("mud-input-control")
.AddClass("mud-input-required", when: () => Required)
.AddClass($"mud-input-control-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
.AddClass("mud-input-control-full-width", FullWidth)
.AddClass("mud-input-error", Error)
new CssBuilder("input-control")
.AddClass("input-required", when: () => Required)
.AddClass($"input-control-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
.AddClass("input-control-full-width", FullWidth)
.AddClass("input-error", Error)
.AddClass(Class)
.Build();
protected string HelperContainer =>
new CssBuilder("mud-input-control-helper-container")
new CssBuilder("input-control-helper-container")
.AddClass($"px-1", Variant == Variant.Filled)
.AddClass($"px-2", Variant == Variant.Outlined)
.Build();
protected string HelperClass =>
new CssBuilder("mud-input-helper-text")
.AddClass("mud-input-helper-onfocus", HelperTextOnFocus)
.AddClass("mud-input-error", Error)
new CssBuilder("input-helper-text")
.AddClass("input-helper-onfocus", HelperTextOnFocus)
.AddClass("input-error", Error)
.Build();
/// <summary>

@ -5,7 +5,7 @@ namespace Connected.Components;
public partial class Layout : DrawerContainer
{
protected override string Classname =>
new CssBuilder("mud-layout")
new CssBuilder("layout")
.AddClass(base.Classname)
.Build();

@ -9,14 +9,14 @@ namespace Connected.Components;
public partial class Link : UIComponent
{
protected string Classname =>
new CssBuilder("mud-typography mud-link")
.AddClass($"mud-{Color.ToDescriptionString()}-text")
.AddClass($"mud-link-underline-{Underline.ToDescriptionString()}")
.AddClass($"mud-typography-{Typo.ToDescriptionString()}")
new CssBuilder("typography mud-link")
.AddClass($"{Color.ToDescriptionString()}-text")
.AddClass($"link-underline-{Underline.ToDescriptionString()}")
.AddClass($"typography-{Typo.ToDescriptionString()}")
// When Href is empty, link's hover cursor is text "I beam" even when OnClick has a delegate.
// To change this for more expected look change hover cursor to a pointer:
.AddClass("cursor-pointer", Href == default && OnClick.HasDelegate && !Disabled)
.AddClass($"mud-link-disabled", Disabled)
.AddClass($"link-disabled", Disabled)
.AddClass(Class)
.Build();

@ -7,8 +7,8 @@ namespace Connected.Components;
public partial class List : UIComponent, IDisposable
{
protected string Classname =>
new CssBuilder("mud-list")
.AddClass("mud-list-padding", !DisablePadding)
new CssBuilder("list")
.AddClass("list-padding", !DisablePadding)
.AddClass(Class)
.Build();

@ -4,7 +4,7 @@
<div tabindex="0" @attributes="UserAttributes" class="@Classname" @onclick="OnClickHandler" @onclick:stopPropagation="true" style="@Style">
@if (!string.IsNullOrWhiteSpace(Avatar))
{
<div class="mud-list-item-avatar">
<div class="list-item-avatar">
<Avatar Class="@AvatarClass">
<Icon Icon="@Avatar" Color="@IconColor" Size="@IconSize" />
</Avatar>
@ -12,11 +12,11 @@
}
else if (!string.IsNullOrWhiteSpace(Icon))
{
<div class="mud-list-item-icon">
<div class="list-item-icon">
<Icon Icon="@Icon" Color="@IconColor" Size="@IconSize" />
</div>
}
<div class="mud-list-item-text @(Inset? "mud-list-item-text-inset" : "")">
<div class="list-item-text @(Inset? "list-item-text-inset" : "")">
<Text Typo="@_textTypo">
@if (ChildContent != null)
{
@ -36,7 +36,7 @@
@if (NestedList != null)
{
<Collapse Expanded="@Expanded">
<List Clickable="List?.Clickable ?? false" Color="List?.Color ?? ThemeColor.Primary" DisablePadding="true" Class="mud-nested-list" Disabled="@Disabled" Dense="(Dense ?? List?.Dense) ?? false">
<List Clickable="List?.Clickable ?? false" Color="List?.Color ?? ThemeColor.Primary" DisablePadding="true" Class="nested-list" Disabled="@Disabled" Dense="(Dense ?? List?.Dense) ?? false">
@NestedList
</List>
</Collapse>

@ -10,13 +10,13 @@ namespace Connected.Components;
public partial class ListItem : UIComponent, IDisposable
{
protected string Classname =>
new CssBuilder("mud-list-item")
.AddClass("mud-list-item-dense", (Dense ?? List?.Dense) ?? false)
.AddClass("mud-list-item-gutters", !DisableGutters && !(List?.DisableGutters == true))
.AddClass("mud-list-item-clickable", List?.Clickable)
.AddClass("mud-ripple", List?.Clickable == true && !DisableRipple && !Disabled)
.AddClass($"mud-selected-item mud-{List?.Color.ToDescriptionString()}-text mud-{List?.Color.ToDescriptionString()}-hover", _selected && !Disabled)
.AddClass("mud-list-item-disabled", Disabled)
new CssBuilder("list-item")
.AddClass("list-item-dense", (Dense ?? List?.Dense) ?? false)
.AddClass("list-item-gutters", !DisableGutters && !(List?.DisableGutters == true))
.AddClass("list-item-clickable", List?.Clickable)
.AddClass("ripple", List?.Clickable == true && !DisableRipple && !Disabled)
.AddClass($"selected-item mud-{List?.Color.ToDescriptionString()}-text mud-{List?.Color.ToDescriptionString()}-hover", _selected && !Disabled)
.AddClass("list-item-disabled", Disabled)
.AddClass(Class)
.Build();

@ -7,9 +7,9 @@ namespace Connected.Components;
public partial class ListSubheader : UIComponent
{
protected string Classname =>
new CssBuilder("mud-list-subheader")
.AddClass("mud-list-subheader-gutters", !DisableGutters)
.AddClass("mud-list-subheader-inset", Inset)
new CssBuilder("list-subheader")
.AddClass("list-subheader-gutters", !DisableGutters)
.AddClass("list-subheader-inset", Inset)
.AddClass(Class)
.Build();

@ -10,7 +10,7 @@
@code {
protected string Classname =>
new CssBuilder("mud-main-content")
new CssBuilder("main-content")
.AddClass(Class)
.Build();

@ -74,7 +74,7 @@
@if (Variant == Variant.Outlined)
{
<div class="mud-input-outlined-border"></div>
<div class="input-outlined-border"></div>
}
</div>

@ -20,43 +20,43 @@ public partial class Mask : InputBase<string>, IDisposable
}
protected string Classname =>
new CssBuilder("mud-input")
.AddClass($"mud-input-{Variant.ToDescriptionString()}")
.AddClass($"mud-input-adorned-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"mud-input-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
.AddClass("mud-input-underline", when: () => DisableUnderLine == false && Variant != Variant.Outlined)
.AddClass("mud-shrink",
new CssBuilder("input")
.AddClass($"input-{Variant.ToDescriptionString()}")
.AddClass($"input-adorned-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"input-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
.AddClass("input-underline", when: () => DisableUnderLine == false && Variant != Variant.Outlined)
.AddClass("shrink",
when: () => !string.IsNullOrEmpty(Text) || Adornment == Adornment.Start ||
!string.IsNullOrWhiteSpace(Placeholder))
.AddClass("mud-disabled", Disabled)
.AddClass("mud-input-error", HasErrors)
.AddClass("mud-ltr", GetInputType() == InputType.Email || GetInputType() == InputType.Telephone)
.AddClass("disabled", Disabled)
.AddClass("input-error", HasErrors)
.AddClass("ltr", GetInputType() == InputType.Email || GetInputType() == InputType.Telephone)
.AddClass(Class)
.Build();
protected string InputClassname =>
new CssBuilder("mud-input-slot")
.AddClass("mud-input-root")
.AddClass($"mud-input-root-{Variant.ToDescriptionString()}")
.AddClass($"mud-input-root-adorned-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"mud-input-root-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
new CssBuilder("input-slot")
.AddClass("input-root")
.AddClass($"input-root-{Variant.ToDescriptionString()}")
.AddClass($"input-root-adorned-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"input-root-margin-{Margin.ToDescriptionString()}", when: () => Margin != Margin.None)
.AddClass(Class)
.Build();
protected string AdornmentClassname =>
new CssBuilder("mud-input-adornment")
.AddClass($"mud-input-adornment-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"mud-text", !string.IsNullOrEmpty(AdornmentText))
.AddClass($"mud-input-root-filled-shrink", Variant == Variant.Filled)
new CssBuilder("input-adornment")
.AddClass($"input-adornment-{Adornment.ToDescriptionString()}", Adornment != Adornment.None)
.AddClass($"text", !string.IsNullOrEmpty(AdornmentText))
.AddClass($"input-root-filled-shrink", Variant == Variant.Filled)
.AddClass(Class)
.Build();
protected string ClearButtonClassname =>
new CssBuilder()
// .AddClass("me-n1", Adornment == Adornment.End && HideSpinButtons == false)
.AddClass("mud-icon-button-edge-end", Adornment == Adornment.End)
.AddClass("icon-button-edge-end", Adornment == Adornment.End)
// .AddClass("me-6", Adornment != Adornment.End && HideSpinButtons == false)
.AddClass("mud-icon-button-edge-margin-end", Adornment != Adornment.End)
.AddClass("icon-button-edge-margin-end", Adornment != Adornment.End)
.Build();
@ -146,7 +146,7 @@ public partial class Mask : InputBase<string>, IDisposable
new JsEventOptions
{
//EnableLogging = true,
TargetClass = "mud-input-slot",
TargetClass = "input-slot",
TagName = "INPUT"
});
_jsEvent.CaretPositionChanged += OnCaretPositionChanged;
@ -158,7 +158,7 @@ public partial class Mask : InputBase<string>, IDisposable
await _keyInterceptor.Connect(_elementId, new KeyInterceptorOptions()
{
//EnableLogging = true,
TargetClass = "mud-input-slot",
TargetClass = "input-slot",
Keys =
{
new KeyOptions

@ -10,13 +10,13 @@ namespace Connected.Components;
public partial class Menu : UIComponent, IActivatable
{
protected string Classname =>
new CssBuilder("mud-menu")
new CssBuilder("menu")
.AddClass(Class)
.Build();
protected string ActivatorClassname =>
new CssBuilder("mud-menu-activator")
.AddClass("mud-disabled", Disabled)
new CssBuilder("menu-activator")
.AddClass("disabled", Disabled)
.Build();
private bool _isOpen;

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save