Skip to content

Commit

Permalink
doc(Select): update ShowSearch sample code (#5241)
Browse files Browse the repository at this point in the history
* refactor: 调整搜索图标上边距

* doc: 更新示例

* refactor: 移除多余配置

* doc: 更新示例
  • Loading branch information
ArgoZhang authored Jan 29, 2025
1 parent 0099bd3 commit 78f2789
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
9 changes: 6 additions & 3 deletions src/BootstrapBlazor.Server/Components/Samples/Selects.razor
Original file line number Diff line number Diff line change
Expand Up @@ -383,9 +383,12 @@
<DemoBlock Title="@Localizer["SelectsPopoverTitle"]"
Introduction="@Localizer["SelectsPopoverIntro"]"
Name="Popover">
<div class="row">
<div class="col-12 col-sm-6 overflow-hidden">
<Select TValue="string" Items="Items" IsPopover="true" ShowSearch="true" />
<div class="row g-3 form-inline">
<div class="col-12">
<Switch @bind-Value="_showPopoverSearch" ShowLabel="true" DisplayText="ShowSearch"></Switch>
</div>
<div class="col-12">
<Select TValue="string" Items="Items" IsPopover="true" ShowSearch="_showPopoverSearch" />
</div>
</div>
</DemoBlock>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ public sealed partial class Selects

private bool _showSearch;

private bool _showPopoverSearch = true;

private bool _isShowSearchClearable;

private bool _isClearable;
Expand Down
3 changes: 1 addition & 2 deletions src/BootstrapBlazor.Server/appsettings.Development.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,5 @@
"ContextMenuOptions": {
"OnTouchDelay": 600
}
},
"SupportedLanguages": [ "zh-CN", "ru-RU" ]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -512,7 +512,7 @@ $bb-select-search-border-color: var(--bs-border-color);
$bb-select-search-padding-right: 30px;
$bb-select-search-icon-color: var(--bb-select-search-border-color);
$bb-select-search-icon-right: 20px;
$bb-select-search-icon-top: 15px;
$bb-select-search-icon-top: 17px;
$bb-select-search-height: 60px;
$bb-select-append-width: 30px;
$bb-select-append-color: #c0c4cc;
Expand Down

0 comments on commit 78f2789

Please sign in to comment.