Merge pull request #209 from hishamco/root-site

Unable to deleted the root site
This commit is contained in:
Shaun Walker
2020-02-22 10:03:23 -05:00
committed by GitHub
5 changed files with 41 additions and 11 deletions

View File

@ -28,7 +28,14 @@
}
@if (authorized)
{
<button class="@Class" @onclick="DisplayModal">@Text</button>
if (Disabled)
{
<button class="@Class" disabled @onclick="DisplayModal">@Text</button>
}
else
{
<button class="@Class" @onclick="DisplayModal">@Text</button>
}
}
@code {
@ -36,13 +43,13 @@
public string Header { get; set; } // required
[Parameter]
public string Message { get; set; } // required
public string Message { get; set; } // required
[Parameter]
public string Text { get; set; } // optional - defaults to Action if not specified
[Parameter]
public string Action { get; set; } // optional
public string Action { get; set; } // optional
[Parameter]
public SecurityAccessLevel? Security { get; set; } // optional - can be used to explicitly specify SecurityAccessLevel
@ -50,6 +57,9 @@
[Parameter]
public string Class { get; set; } // optional
[Parameter]
public bool Disabled { get; set; } // optional
[Parameter]
public string EditMode { get; set; } // optional - specifies if a user must be in edit mode to see the action - default is true

View File

@ -4,7 +4,14 @@
@if (authorized)
{
<NavLink class="@classname" href="@url" style="@style">@text</NavLink>
if (Disabled)
{
<NavLink class="@classname" href="@url" style="@style" disabled>@text</NavLink>
}
else
{
<NavLink class="@classname" href="@url" style="@style">@text</NavLink>
}
}
@code {
@ -26,6 +33,9 @@
[Parameter]
public string Style { get; set; } // optional
[Parameter]
public bool Disabled { get; set; } // optional
[Parameter]
public string EditMode { get; set; } // optional - specifies if a user must be in edit mode to see the action - default is true