]> git.ipfire.org Git - thirdparty/paperless-ngx.git/commitdiff
Performance: Enable virtual scrolling for large custom field selects (#10708)
authordavid-loe <56305409+david-loe@users.noreply.github.com>
Thu, 28 Aug 2025 15:07:34 +0000 (17:07 +0200)
committerGitHub <noreply@github.com>
Thu, 28 Aug 2025 15:07:34 +0000 (15:07 +0000)
src-ui/src/app/components/common/custom-fields-query-dropdown/custom-fields-query-dropdown.component.html
src-ui/src/app/components/common/input/select/select.component.html

index 57aff1bd926854b77514830f46bb56f5912098e4..22a1eec2ea257541fdb0f6a25aab312118ffe2d8 100644 (file)
@@ -51,6 +51,7 @@
     <ng-select #fieldSelects
       class="paperless-input-select rounded-end"
       [items]="getSelectOptionsForField(atom.field)"
+      [virtualScroll]="getSelectOptionsForField(atom.field)?.length > 100"
       bindLabel="label"
       bindValue="id"
       [(ngModel)]="atom.value"
index ef7be3b6249e416fc5d96fe45b6fdaf1383bddb4..7aa4ef94a0e46c574c166282339c1c15d97e4221 100644 (file)
@@ -19,6 +19,7 @@
             [class.private]="isPrivate"
             [clearable]="allowNull"
             [items]="items"
+            [virtualScroll]="items?.length > 100"
             [addTag]="allowCreateNew && addItemRef"
             addTagText="Add item"
             i18n-addTagText="Used for both types, correspondents, storage paths"