Skip to content

Commit deb7645

Browse files
authored
Merge branch 'dev' into UpdateWithMudAndFixStepperActionButtons
2 parents 328427b + a2ffc22 commit deb7645

File tree

7 files changed

+20
-84
lines changed

7 files changed

+20
-84
lines changed

docs/CodeBeam.MudBlazor.Extensions.Docs.Wasm/wwwroot/CodeBeam.MudBlazor.Extensions.xml

Lines changed: 0 additions & 20 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/CodeBeam.MudBlazor.Extensions/Base/Identifier.cs

Lines changed: 0 additions & 44 deletions
This file was deleted.

src/CodeBeam.MudBlazor.Extensions/Base/MudBaseInputExtended.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
using Microsoft.AspNetCore.Components;
2-
using Microsoft.AspNetCore.Components.Web;
32
using Microsoft.JSInterop;
43
using MudBlazor;
54

src/CodeBeam.MudBlazor.Extensions/CodeBeam.MudBlazor.Extensions.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<ImplicitUsings>enable</ImplicitUsings>
77
<PackageLicenseExpression>MIT</PackageLicenseExpression>
88
<PackageReadmeFile>README.md</PackageReadmeFile>
9-
<Version>9.0.0-preview.3</Version>
9+
<Version>9.0.0-preview.4</Version>
1010
<Title>CodeBeam.MudBlazor.Extensions</Title>
1111
<PackageId>CodeBeam.MudBlazor.Extensions</PackageId>
1212
<Authors>CodeBeam</Authors>

src/CodeBeam.MudBlazor.Extensions/Components/CodeInput/MudCodeInput.razor.cs

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
using Microsoft.AspNetCore.Components.Web;
33
using MudBlazor;
44
using MudBlazor.Extensions;
5-
using MudBlazor.Interfaces;
65
using MudBlazor.State;
76
using MudBlazor.Utilities;
87

@@ -14,22 +13,11 @@ namespace MudExtensions
1413
/// <typeparam name="T"></typeparam>
1514
public partial class MudCodeInput<T> : MudFormComponent<T, string>
1615
{
17-
18-
protected override IConverter<T?, string?> GetDefaultConverter()
19-
{
20-
throw new NotImplementedException();
21-
}
2216
/// <summary>
2317
/// MudCodeInput constructor.
2418
/// </summary>
2519
public MudCodeInput()
2620
{
27-
Converter = new DefaultConverter<T>
28-
{
29-
Culture = GetCulture,
30-
Format = GetFormat
31-
};
32-
3321
using var registerScope = CreateRegisterScope();
3422
_theValue = registerScope.RegisterParameter<T?>(nameof(Value))
3523
.WithParameter(() => Value)
@@ -324,11 +312,22 @@ public async Task SetValueFromOutside(T? value)
324312
}
325313
else
326314
{
327-
await _elementReferences[i].SetText(null);
315+
await _elementReferences[i].SetText(string.Empty);
328316
}
329317
}
330318
}
331319

332-
320+
/// <summary>
321+
///
322+
/// </summary>
323+
/// <returns></returns>
324+
protected override IConverter<T?, string?> GetDefaultConverter()
325+
{
326+
return new DefaultConverter<T>
327+
{
328+
Culture = GetCulture,
329+
Format = GetFormat
330+
};
331+
}
333332
}
334333
}

src/CodeBeam.MudBlazor.Extensions/Components/Wheel/MudWheel.razor

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
if (0 <= index - a)
2020
{
2121
<div class="@OuterItemClassname(index - a)" @onclick="@(async() => await ChangeWheel(-a))">
22-
<MudText Typo="@(Dense ? Typo.body1 : Typo.h6)">@(ToStringFunc != null ? ToStringFunc(ItemCollection[index - a]) : Converter.Convert(ItemCollection[index - a]))</MudText>
22+
<MudText Typo="@(Dense ? Typo.body1 : Typo.h6)">@(ToStringFunc != null ? ToStringFunc(ItemCollection[index - a]) : ConvertSet(ItemCollection[index - a]))</MudText>
2323
</div>
2424
}
2525
else
@@ -31,7 +31,7 @@
3131
<span class="@BorderClassname" />
3232

3333
<div class="@MiddleItemClassname">
34-
<MudText Class="@($"mud-wheel-ani-{_animateGuid} my-2)")" Typo="@(Dense ? Typo.body1 : Typo.h6)" Color="@Color" Style="font-weight: 900">@(ToStringFunc != null ? ToStringFunc(ItemCollection[index]) : Converter.Convert(ItemCollection[index]))</MudText>
34+
<MudText Class="@($"mud-wheel-ani-{_animateGuid} my-2)")" Typo="@(Dense ? Typo.body1 : Typo.h6)" Color="@Color" Style="font-weight: 900">@(ToStringFunc != null ? ToStringFunc(ItemCollection[index]) : ConvertSet(ItemCollection[index]))</MudText>
3535
</div>
3636

3737
<div class="@BorderClassname" />
@@ -42,7 +42,7 @@
4242
if (index + a < ItemCollection?.Count)
4343
{
4444
<div class="@OuterItemClassname(index + a)" @onclick="@(async() => await ChangeWheel(a))">
45-
<MudText Typo="@(Dense ? Typo.body1 : Typo.h6)">@(ToStringFunc != null ? ToStringFunc(ItemCollection[index + a]) : Converter.Convert(ItemCollection[index + a]))</MudText>
45+
<MudText Typo="@(Dense ? Typo.body1 : Typo.h6)">@(ToStringFunc != null ? ToStringFunc(ItemCollection[index + a]) : ConvertSet(ItemCollection[index + a]))</MudText>
4646
</div>
4747
}
4848
else

src/CodeBeam.MudBlazor.Extensions/Components/Wheel/MudWheel.razor.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ public partial class MudWheel<T> : MudBaseInput<T>
7575
///
7676
/// </summary>
7777
[Parameter]
78-
public List<T?>? ItemCollection { get; set; }
78+
public List<T?> ItemCollection { get; set; } = new();
7979

8080
/// <summary>
8181
/// Determines how many items will show before and after the middle one.
@@ -282,5 +282,7 @@ public async Task RefreshAnimate()
282282
/// </summary>
283283
/// <returns></returns>
284284
protected int GetAnimateValue() => Dense ? 24 : 42;
285+
286+
285287
}
286288
}

0 commit comments

Comments
 (0)