mirror of
https://gitee.com/ant-design-blazor/ant-design-blazor.git
synced 2024-12-15 01:11:52 +08:00
ab58b3b429
* fix(module: dropdown): fix bug of default show * fix(module: datepicker): #94 Co-authored-by: 钟迪龙 <mutouzdl@hotmail.com>
30 lines
961 B
Plaintext
30 lines
961 B
Plaintext
@namespace AntBlazor.Internal
|
|
@inherits AntDomComponentBase
|
|
@using AntBlazor.core.Internal
|
|
|
|
@if (_hasAddOverlayToBody == true || _isWaitForOverlayFirstRender)
|
|
{
|
|
string display = _isOverlayShow ? "" : "visibility: hidden;";
|
|
string overlayCls;
|
|
|
|
if (!_isOverlayShow && !_isWaitForOverlayFirstRender)
|
|
{
|
|
overlayCls = $"{Dropdown.PrefixCls}-hidden";
|
|
display = "";
|
|
}
|
|
else
|
|
{
|
|
overlayCls = _overlayCls;
|
|
}
|
|
|
|
<div class="@(Dropdown.PrefixCls) @(Dropdown.OverlayClassName) @(Dropdown.PrefixCls)-placement-@(Dropdown.Placement.Name) @overlayCls"
|
|
style="width: fit-content; position: absolute; @display @Dropdown.OverlayStyle @_dropdownStyle"
|
|
@ref="Ref"
|
|
@onmouseenter="OnOverlayMouseEnter"
|
|
@onmouseleave="OnOverlayMouseLeave">
|
|
<CascadingValue Value="@($"{Dropdown.PrefixCls}-menu")" Name="PrefixCls">
|
|
@Dropdown.Overlay
|
|
</CascadingValue>
|
|
</div>
|
|
}
|