Skip to content

Commit

Permalink
Merge results
Browse files Browse the repository at this point in the history
  • Loading branch information
ysmoradi committed Jul 7, 2024
2 parents e65f3e0 + acbe14f commit d4f48e6
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ public void BitLinkShouldRespectUnderLineStyle(bool? hasUnderline)
{
if (hasUnderline.HasValue)
{
parameters.Add(p => p.HasUnderline, hasUnderline.Value);
parameters.Add(p => p.Underlined, hasUnderline.Value);
}
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public partial class BitLink : BitComponentBase
/// <summary>
/// Whether the link is styled with an underline or not.
/// </summary>
[Parameter] public bool HasUnderline { get; set; } = false;
[Parameter] public bool Underlined { get; set; }

/// <summary>
/// Callback for when the link clicked
Expand All @@ -36,7 +36,7 @@ public partial class BitLink : BitComponentBase

protected override void RegisterCssClasses()
{
ClassBuilder.Register(() => HasUnderline ? "bit-lnk-und" : string.Empty);
ClassBuilder.Register(() => Underlined ? "bit-lnk-und" : string.Empty);
}

protected virtual async Task HandleClick(MouseEventArgs e)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@
</ExamplePreview>
</ComponentExampleBox>

<ComponentExampleBox Title="HasUnderline" RazorCode="@example4RazorCode" Id="example4">
<ComponentExampleBox Title="Underlined" RazorCode="@example4RazorCode" Id="example4">
<ExamplePreview>
<div class="example-box">
<BitLink Href="https://github.com/bitfoundation/bitplatform" HasUnderline="true">Underlined link</BitLink>
<BitLink Href="https://github.com/bitfoundation/bitplatform" Underlined>Underlined link</BitLink>
</div>
</ExamplePreview>
</ComponentExampleBox>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public partial class BitLinkDemo
},
new()
{
Name = "HasUnderline",
Name = "Underlined",
Type = "bool",
DefaultValue = "false",
Description = "Whether the link is styled with an underline or not.",
Expand Down Expand Up @@ -75,7 +75,7 @@ private void HandleOnClick()
<BitLink Class=""custom-class"" Href=""https://github.com/bitfoundation/bitplatform"">Link with class</BitLink>";

private readonly string example4RazorCode = @"
<BitLink Href=""https://github.com/bitfoundation/bitplatform"" HasUnderline=""true"">Underlined link</BitLink>";
<BitLink Href=""https://github.com/bitfoundation/bitplatform"" Underlined>Underlined link</BitLink>";

private readonly string example5RazorCode = @"
<BitLink Href=""https://github.com/bitfoundation/bitplatform"" Target=""_blank"">Blank target link</BitLink>
Expand Down

0 comments on commit d4f48e6

Please sign in to comment.