Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -138,13 +138,19 @@
<ui-select-option>{{
'common.input.none' | translate
}}</ui-select-option>
<ui-select-option
*ngFor="let option of field.options"
[value]="option.value"
<cdk-virtual-scroll-viewport
itemSize="30"
class="virtual-scroll-viewport"
>
{{ option.text }}
</ui-select-option>
<ui-select-option
*cdkVirtualFor="let option of field.options"
[value]="option.value"
>
{{ option.text }}
</ui-select-option>
</cdk-virtual-scroll-viewport>
</ui-select-menu>

<ui-select-menu
[filterable]="true"
*ngIf="field.multiSelect"
Expand All @@ -154,12 +160,17 @@
<ui-select-option>{{
'common.input.none' | translate
}}</ui-select-option>
<ui-select-option
*ngFor="let option of field.options"
[value]="option.value"
<cdk-virtual-scroll-viewport
itemSize="30"
class="virtual-scroll-viewport"
>
{{ option.text }}
</ui-select-option>
<ui-select-option
*cdkVirtualFor="let option of field.options"
[value]="option.value"
>
{{ option.text }}
</ui-select-option>
</cdk-virtual-scroll-viewport>
</ui-select-menu>
</div>
</ng-template>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,9 @@
gap: 8px;
}
}

.virtual-scroll-viewport {
height: 200px; /* Adjust height as needed */
overflow: hidden;
display: block;
}
2 changes: 2 additions & 0 deletions libs/shared/src/lib/components/filter/filter.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import {
DateModule,
TooltipModule,
} from '@oort-front/ui';
import { ScrollingModule } from '@angular/cdk/scrolling';

/**
* Composite Filter module.
Expand All @@ -29,6 +30,7 @@ import {
DateModule,
FormWrapperModule,
TooltipModule,
ScrollingModule,
],
exports: [FilterComponent],
})
Expand Down