Skip to content

Commit 289075a

Browse files
authored
fix(Select): Select组件loading状态不应该显示无数据 (#238)
1 parent a522cb4 commit 289075a

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

devui/select/select.component.html

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<div
2-
class="devui-drop{{ popDirection === 'bottom' ? 'down' : 'up' }}
3-
{{ size ? 'devui-select-' + size : '' }}
2+
class="devui-drop{{ popDirection === 'bottom' ? 'down' : 'up' }}
3+
{{ size ? 'devui-select-' + size : '' }}
44
devui-dropdown-origin"
55
[ngClass]="[isOpen ? 'open' : '', overview === 'underlined' ? 'devui-select-underlined-border' : '', disabled ? 'disabled' : '']"
66
#selectWrapper
@@ -244,11 +244,11 @@
244244
<ng-template [ngTemplateOutlet]="dropdownItemTpl" [ngTemplateOutletContext]="{ item: item, index: index }"></ng-template>
245245
</ng-container>
246246
</ul>
247-
<li *ngIf="availableOptions.length === 0 && !noResultItemTemplate" class="devui-no-data-tip">
247+
<li *ngIf="availableOptions.length === 0 && !noResultItemTemplate && !this.showLoading" class="devui-no-data-tip">
248248
<ng-container *ngIf="!filter">{{ i18nCommonText?.noData }}</ng-container>
249249
<ng-container *ngIf="filter">{{ i18nCommonText?.noRecordsFound }}</ng-container>
250250
</li>
251-
<li *ngIf="availableOptions.length === 0 && noResultItemTemplate" class="devui-no-data-tip">
251+
<li *ngIf="availableOptions.length === 0 && noResultItemTemplate && !this.showLoading" class="devui-no-data-tip">
252252
<ng-template [ngTemplateOutlet]="noResultItemTemplate" [ngTemplateOutletContext]="{ options: options }"></ng-template>
253253
</li>
254254
</ul>

0 commit comments

Comments
 (0)