Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] shadows are not updated on onliners change #315

Merged
merged 2 commits into from
Jun 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,26 @@ namespace AXSharp.Presentation.Blazor.Controls.Templates
{
public partial class TemplateBaseShadow<T> : TemplateBase<T>
{
private OnlinerBase<T> _Onliner;

[Parameter]
public override OnlinerBase<T> Onliner
{
get { return _Onliner; }
set
{
if (_Onliner != value)
{
_Onliner = value;
UpdateShadowValuesOnChange(_Onliner);
}
}
}

protected override Task OnInitializedAsync()
{
UpdateShadowValuesOnChange(Onliner);
// UpdateShadowValuesOnChange(Onliner);
return base.OnInitializedAsync();
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public IJSRuntime JSRuntime
protected string ToolTipText => Onliner?.HumanReadable;

[Parameter]
public OnlinerBase<T> Onliner { get; set; }
public virtual OnlinerBase<T> Onliner { get; set; }

[Parameter]
public bool IsReadOnly { get; set; }
Expand Down Expand Up @@ -59,7 +59,7 @@ protected T Value
protected override Task OnInitializedAsync()
{
AccessStatus = Onliner.AccessStatus.Failure ? "is-invalid" : "";
ComponentId = Onliner.GetSymbolTail() + "_" + Guid.NewGuid().ToString();
ComponentId = Onliner.Symbol + "_" + Guid.NewGuid().ToString();
return base.OnInitializedAsync();
}
}
Expand Down
Loading