<!--
  ~ Copyright (C) 2023 Robert Bosch GmbH Copyright (C) 2023 Robert Bosch Manufacturing Solutions GmbH, Germany. All rights reserved.
  -->

<bci-core-picklist
  [source]="fruits"
  [sourceItemTemplate]="fruitsTemplate"
  [displayProperty]="displayProperty"
  [isMultilineItem]="true"
  [showSort]="true"
  [sourceFilterHeader]="'Available fruits'"
  [targetFilterHeader]="'Fruit salad'"
></bci-core-picklist>

<ng-template #fruitsTemplate let-name="name" let-calories="calories" let-fromOverseas="fromOverseas">
  <div class="item-container">
    <span class="name">{{ name }}</span>
    <div class="stats">
      <span>{{ calories }} calories</span>,&nbsp;<span *ngIf="fromOverseas; else localFruit">from overseas</span>
      <ng-template #localFruit>
        <span>local product</span>
      </ng-template>
    </div>
  </div>
</ng-template>
