Skip to content

Commit

Permalink
Merge pull request #306 from amansinghbais/304-selected-chip-in-modal
Browse files Browse the repository at this point in the history
Improved: added chips for selected filters in the product filter modal (#304)
  • Loading branch information
ravilodhi authored Jul 26, 2024
2 parents 244c9a7 + 55725a2 commit eac969e
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/components/AddProductFiltersModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@

<ion-content>
<ion-searchbar :placeholder="translate('Search', { label })" v-model="queryString" @keyup.enter="search()"/>
<ion-row>
<ion-chip v-for="filter in selectedValues" outline :key="filter.id">
<ion-label>{{ filter }}</ion-label>
</ion-chip>
</ion-row>

<ion-list v-if="facetOptions.length">
<ion-item v-for="option in facetOptions" :key="option.id" @click="!isAlreadyApplied(option.id) ? updateSelectedValues(option.id) : null">
Expand Down Expand Up @@ -51,6 +56,7 @@ import {
IonButton,
IonButtons,
IonCheckbox,
IonChip,
IonContent,
IonFab,
IonFabButton,
Expand All @@ -62,6 +68,7 @@ import {
IonLabel,
IonList,
IonNote,
IonRow,
IonSearchbar,
IonTitle,
IonToolbar,
Expand Down Expand Up @@ -155,4 +162,13 @@ async function saveFilters() {
ion-content {
--padding-bottom: 80px;
}
ion-row {
flex-wrap: nowrap;
overflow: scroll;
}
ion-chip {
flex-shrink: 0;
}
</style>

0 comments on commit eac969e

Please sign in to comment.