@paris-ias/list 1.0.108 → 1.0.109
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/module.json
CHANGED
|
@@ -1,84 +1,39 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="d-flex flex-grow-1 flex-column">
|
|
3
|
-
<
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
<
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
</v-text-field>
|
|
29
|
-
|
|
30
|
-
<v-menu
|
|
31
|
-
v-model="filterMenuOpen"
|
|
32
|
-
:close-on-content-click="false"
|
|
33
|
-
location="bottom end"
|
|
34
|
-
offset="4"
|
|
35
|
-
>
|
|
36
|
-
<template #activator="{ props: menuProps }">
|
|
37
|
-
<v-btn
|
|
38
|
-
v-bind="menuProps"
|
|
39
|
-
:rounded="0"
|
|
40
|
-
variant="outlined"
|
|
41
|
-
size="large"
|
|
42
|
-
height="56"
|
|
43
|
-
>
|
|
44
|
-
<v-icon>mdi-filter</v-icon>
|
|
45
|
-
<v-icon class="ml-1" size="small">
|
|
46
|
-
{{ filterMenuOpen ? "mdi-chevron-up" : "mdi-chevron-down" }}
|
|
47
|
-
</v-icon>
|
|
48
|
-
</v-btn>
|
|
49
|
-
</template>
|
|
50
|
-
|
|
51
|
-
<v-card min-width="200">
|
|
52
|
-
<v-list>
|
|
53
|
-
<v-list-item
|
|
54
|
-
v-for="option in filterOptions"
|
|
55
|
-
:key="option.value"
|
|
56
|
-
@click="toggleFilter(option)"
|
|
57
|
-
>
|
|
58
|
-
<template #prepend>
|
|
59
|
-
<v-checkbox
|
|
60
|
-
hide-details
|
|
61
|
-
:model-value="selectedFilters.includes(option.value)"
|
|
62
|
-
@update:model-value="toggleFilter(option)"
|
|
63
|
-
/>
|
|
64
|
-
</template>
|
|
65
|
-
<v-list-item-title>{{ option.label }}</v-list-item-title>
|
|
66
|
-
</v-list-item>
|
|
67
|
-
</v-list>
|
|
68
|
-
</v-card>
|
|
69
|
-
</v-menu>
|
|
70
|
-
</div>
|
|
3
|
+
<v-text-field
|
|
4
|
+
v-model.trim="search"
|
|
5
|
+
:placeholder="$t('list.search-type', [$t('items.' + type, 2)])"
|
|
6
|
+
prepend-inner-icon="mdi-magnify"
|
|
7
|
+
single-line
|
|
8
|
+
class="transition-swing"
|
|
9
|
+
variant="outlined"
|
|
10
|
+
hide-details
|
|
11
|
+
clearable
|
|
12
|
+
tile
|
|
13
|
+
type="search"
|
|
14
|
+
:loading="rootStore.loading"
|
|
15
|
+
>
|
|
16
|
+
<!-- :loading="$nuxt.loading || $store.state.loading" :class="{ 'mt-3':
|
|
17
|
+
$store.state.scrolled }" -->
|
|
18
|
+
<template v-if="!search" #label>
|
|
19
|
+
<div class="searchLabel">
|
|
20
|
+
{{
|
|
21
|
+
type === "all"
|
|
22
|
+
? $t("search")
|
|
23
|
+
: $t("list.search-type", [$t("items." + type, 2)])
|
|
24
|
+
}}
|
|
25
|
+
</div>
|
|
26
|
+
</template>
|
|
27
|
+
</v-text-field>
|
|
71
28
|
</div>
|
|
72
29
|
</template>
|
|
73
30
|
|
|
74
31
|
<script setup>
|
|
75
32
|
import { useDebounceFn } from "@vueuse/core";
|
|
76
33
|
import { useRootStore } from "../../../stores/root";
|
|
77
|
-
import { computed, useI18n
|
|
78
|
-
|
|
79
|
-
const { locale, t } = useI18n();
|
|
34
|
+
import { computed, useI18n } from "#imports";
|
|
35
|
+
const { locale } = useI18n();
|
|
80
36
|
const rootStore = useRootStore();
|
|
81
|
-
const emit = defineEmits(["filter-change"]);
|
|
82
37
|
const props = defineProps({
|
|
83
38
|
type: {
|
|
84
39
|
type: String,
|
|
@@ -89,29 +44,6 @@ const props = defineProps({
|
|
|
89
44
|
default: false
|
|
90
45
|
}
|
|
91
46
|
});
|
|
92
|
-
const filterMenuOpen = ref(false);
|
|
93
|
-
const selectedFilters = ref([]);
|
|
94
|
-
const filterOptions = [
|
|
95
|
-
{ value: "people", label: capitalize(t("items.people", 2)) },
|
|
96
|
-
{ value: "events", label: capitalize(t("items.events", 2)) },
|
|
97
|
-
{ value: "news", label: capitalize(t("items.news", 2)) },
|
|
98
|
-
{ value: "publications", label: capitalize(t("items.publications", 2)) },
|
|
99
|
-
{ value: "fellowships", label: capitalize(t("items.fellowships", 2)) },
|
|
100
|
-
{ value: "projects", label: capitalize(t("items.projects", 2)) }
|
|
101
|
-
];
|
|
102
|
-
const toggleFilter = (option) => {
|
|
103
|
-
const index = selectedFilters.value.indexOf(option.value);
|
|
104
|
-
if (index > -1) {
|
|
105
|
-
selectedFilters.value.splice(index, 1);
|
|
106
|
-
} else {
|
|
107
|
-
selectedFilters.value.push(option.value);
|
|
108
|
-
}
|
|
109
|
-
emit("filter-change", {
|
|
110
|
-
name: option.value,
|
|
111
|
-
value: selectedFilters.value.includes(option.value),
|
|
112
|
-
allSelected: selectedFilters.value
|
|
113
|
-
});
|
|
114
|
-
};
|
|
115
47
|
const search = computed({
|
|
116
48
|
get() {
|
|
117
49
|
return rootStore.search;
|
|
@@ -125,7 +125,14 @@
|
|
|
125
125
|
:key="position.role + index"
|
|
126
126
|
class="text-body-2"
|
|
127
127
|
>
|
|
128
|
-
|
|
128
|
+
<template v-if="position.role === 'Fellow'">
|
|
129
|
+
<span class="text-caption text-uppercase">
|
|
130
|
+
{{ $t("fellow") }}
|
|
131
|
+
</span>
|
|
132
|
+
</template>
|
|
133
|
+
<template v-else>
|
|
134
|
+
{{ position.role + " " + (position.department || "") }}
|
|
135
|
+
</template>
|
|
129
136
|
<span v-if="position.start" class="">
|
|
130
137
|
<!-- TODO FIx dates display -->
|
|
131
138
|
-
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"see-more": "See more events"
|
|
14
14
|
},
|
|
15
15
|
"filters": "Filters",
|
|
16
|
-
"from {0} to {1}": "
|
|
16
|
+
"from {0} to {1}": "From {0} to {1}",
|
|
17
17
|
"gallery": "Gallery",
|
|
18
18
|
"hybrid-event": "Hybrid event",
|
|
19
19
|
"inscription-gratuite-et-obligatoire": " Free and mandatory registration",
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"see-more": "Voir plus d'événements"
|
|
14
14
|
},
|
|
15
15
|
"filters": "filtre | filtre | Filtres",
|
|
16
|
-
"from {0} to {1}": "
|
|
16
|
+
"from {0} to {1}": "Du {0} à {1}",
|
|
17
17
|
"gallery": "Galerie",
|
|
18
18
|
"hybrid-event": "Évènement hybride",
|
|
19
19
|
"inscription-gratuite-et-obligatoire": "Enregistrement gratuit et obligatoire",
|