@paris-ias/list 1.0.112 → 1.0.113

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.
Files changed (151) hide show
  1. package/dist/module.json +1 -1
  2. package/dist/runtime/components/list/molecules/Pagination.vue +2 -0
  3. package/dist/runtime/components/list/organisms/List.vue +11 -1
  4. package/dist/runtime/runtime/components/actions/ExpandedItem.vue +14 -0
  5. package/dist/runtime/runtime/components/actions/RowsItem.vue +12 -0
  6. package/dist/runtime/runtime/components/actions/View.vue +20 -0
  7. package/dist/runtime/runtime/components/affiliations/ExpandedItem.vue +14 -0
  8. package/dist/runtime/runtime/components/affiliations/RowsItem.vue +12 -0
  9. package/dist/runtime/runtime/components/affiliations/View.vue +20 -0
  10. package/dist/runtime/runtime/components/apps/ExpandedItem.vue +14 -0
  11. package/dist/runtime/runtime/components/apps/RowsItem.vue +12 -0
  12. package/dist/runtime/runtime/components/apps/View.vue +20 -0
  13. package/dist/runtime/runtime/components/disciplines/ExpandedItem.vue +14 -0
  14. package/dist/runtime/runtime/components/disciplines/RowsItem.vue +12 -0
  15. package/dist/runtime/runtime/components/disciplines/View.vue +20 -0
  16. package/dist/runtime/runtime/components/events/Badges.vue +73 -0
  17. package/dist/runtime/runtime/components/events/DateTimePlace.vue +77 -0
  18. package/dist/runtime/runtime/components/events/DenseItem.vue +60 -0
  19. package/dist/runtime/runtime/components/events/ExpandedItem.vue +9 -0
  20. package/dist/runtime/runtime/components/events/RegisterModal.vue +50 -0
  21. package/dist/runtime/runtime/components/events/RelatedItem.vue +44 -0
  22. package/dist/runtime/runtime/components/events/RowsItem.vue +118 -0
  23. package/dist/runtime/runtime/components/events/SlidingItem.vue +63 -0
  24. package/dist/runtime/runtime/components/events/View.vue +333 -0
  25. package/dist/runtime/runtime/components/fellowships/Badges.vue +47 -0
  26. package/dist/runtime/runtime/components/fellowships/DenseItem.vue +42 -0
  27. package/dist/runtime/runtime/components/fellowships/ExpandedItem.vue +7 -0
  28. package/dist/runtime/runtime/components/fellowships/RegisterModal.vue +41 -0
  29. package/dist/runtime/runtime/components/fellowships/RowsItem.vue +58 -0
  30. package/dist/runtime/runtime/components/fellowships/View.vue +203 -0
  31. package/dist/runtime/runtime/components/files/ExpandedItem.vue +14 -0
  32. package/dist/runtime/runtime/components/files/RowsItem.vue +12 -0
  33. package/dist/runtime/runtime/components/files/View.vue +20 -0
  34. package/dist/runtime/runtime/components/list/atoms/FiltersMenu.vue +44 -0
  35. package/dist/runtime/runtime/components/list/atoms/ResetButton.vue +33 -0
  36. package/dist/runtime/runtime/components/list/atoms/ResultsList.vue +27 -0
  37. package/dist/runtime/runtime/components/list/atoms/SearchInput.vue +59 -0
  38. package/dist/runtime/runtime/components/list/atoms/SearchItem.vue +65 -0
  39. package/dist/runtime/runtime/components/list/atoms/SearchString.vue +160 -0
  40. package/dist/runtime/runtime/components/list/atoms/SortMenu.vue +80 -0
  41. package/dist/runtime/runtime/components/list/atoms/ViewMenu.vue +63 -0
  42. package/dist/runtime/runtime/components/list/atoms/itemsPerPage.vue +33 -0
  43. package/dist/runtime/runtime/components/list/inputs/AutoComplete.vue +24 -0
  44. package/dist/runtime/runtime/components/list/inputs/BooleanSwitch.vue +20 -0
  45. package/dist/runtime/runtime/components/list/inputs/Checkbox.vue +20 -0
  46. package/dist/runtime/runtime/components/list/inputs/Select.vue +28 -0
  47. package/dist/runtime/runtime/components/list/molecules/Filters.vue +98 -0
  48. package/dist/runtime/runtime/components/list/molecules/GlobalSearchInput.vue +131 -0
  49. package/dist/runtime/runtime/components/list/molecules/Header.vue +51 -0
  50. package/dist/runtime/runtime/components/list/molecules/Pagination.vue +194 -0
  51. package/dist/runtime/runtime/components/list/molecules/ResultsContainer.vue +78 -0
  52. package/dist/runtime/runtime/components/list/organisms/List.vue +110 -0
  53. package/dist/runtime/runtime/components/list/organisms/Results.vue +72 -0
  54. package/dist/runtime/runtime/components/list/organisms/Slider.vue +180 -0
  55. package/dist/runtime/runtime/components/list/views/Dense.vue +12 -0
  56. package/dist/runtime/runtime/components/list/views/Expanded.vue +10 -0
  57. package/dist/runtime/runtime/components/list/views/Grid.vue +13 -0
  58. package/dist/runtime/runtime/components/list/views/Rows.vue +12 -0
  59. package/dist/runtime/runtime/components/list/views/Slider.vue +147 -0
  60. package/dist/runtime/runtime/components/list/views/Table.vue +13 -0
  61. package/dist/runtime/runtime/components/mailing/ExpandedItem.vue +14 -0
  62. package/dist/runtime/runtime/components/mailing/RowsItem.vue +12 -0
  63. package/dist/runtime/runtime/components/mailing/View.vue +20 -0
  64. package/dist/runtime/runtime/components/misc/atoms/DateStamp.vue +101 -0
  65. package/dist/runtime/runtime/components/misc/atoms/ImageContainer.vue +127 -0
  66. package/dist/runtime/runtime/components/misc/atoms/ShareMenu.vue +61 -0
  67. package/dist/runtime/runtime/components/misc/atoms/Socials.vue +120 -0
  68. package/dist/runtime/runtime/components/misc/molecules/ChipContainer.vue +31 -0
  69. package/dist/runtime/runtime/components/misc/molecules/Related.vue +28 -0
  70. package/dist/runtime/runtime/components/misc/molecules/RelatedItems.vue +27 -0
  71. package/dist/runtime/runtime/components/misc/molecules/SearchItem.vue +26 -0
  72. package/dist/runtime/runtime/components/news/DenseItem.vue +73 -0
  73. package/dist/runtime/runtime/components/news/ExpandedItem.vue +145 -0
  74. package/dist/runtime/runtime/components/news/Header.vue +7 -0
  75. package/dist/runtime/runtime/components/news/RelatedItem.vue +44 -0
  76. package/dist/runtime/runtime/components/news/RowsItem.vue +182 -0
  77. package/dist/runtime/runtime/components/news/View.vue +174 -0
  78. package/dist/runtime/runtime/components/people/DenseItem.vue +60 -0
  79. package/dist/runtime/runtime/components/people/ExpandedItem.vue +14 -0
  80. package/dist/runtime/runtime/components/people/GroupBadges.vue +54 -0
  81. package/dist/runtime/runtime/components/people/RelatedItem.vue +41 -0
  82. package/dist/runtime/runtime/components/people/RowsItem.vue +93 -0
  83. package/dist/runtime/runtime/components/people/View.vue +172 -0
  84. package/dist/runtime/runtime/components/projects/DenseItem.vue +77 -0
  85. package/dist/runtime/runtime/components/projects/ExpandedItem.vue +12 -0
  86. package/dist/runtime/runtime/components/projects/RelatedItem.vue +44 -0
  87. package/dist/runtime/runtime/components/projects/RowsItem.vue +103 -0
  88. package/dist/runtime/runtime/components/projects/View.vue +130 -0
  89. package/dist/runtime/runtime/components/publications/DenseItem.vue +89 -0
  90. package/dist/runtime/runtime/components/publications/RelatedItem.vue +44 -0
  91. package/dist/runtime/runtime/components/publications/RowsItem.vue +105 -0
  92. package/dist/runtime/runtime/components/publications/View.vue +132 -0
  93. package/dist/runtime/runtime/components/tags/ExpandedItem.vue +14 -0
  94. package/dist/runtime/runtime/components/tags/RowsItem.vue +12 -0
  95. package/dist/runtime/runtime/components/tags/View.vue +20 -0
  96. package/dist/runtime/runtime/components/users/ExpandedItem.vue +14 -0
  97. package/dist/runtime/runtime/components/users/RowsItem.vue +12 -0
  98. package/dist/runtime/runtime/components/users/View.vue +20 -0
  99. package/dist/runtime/runtime/composables/useFetchItem.d.ts +6 -0
  100. package/dist/runtime/runtime/composables/useFetchItem.js +49 -0
  101. package/dist/runtime/runtime/composables/useIcons.d.ts +1 -0
  102. package/dist/runtime/runtime/composables/useIcons.js +30 -0
  103. package/dist/runtime/runtime/composables/useUtils.d.ts +12 -0
  104. package/dist/runtime/runtime/composables/useUtils.js +48 -0
  105. package/dist/runtime/runtime/graphql/buildFiltersValues.gql +35 -0
  106. package/dist/runtime/runtime/graphql/item/action.gql +22 -0
  107. package/dist/runtime/runtime/graphql/item/affiliations.gql +37 -0
  108. package/dist/runtime/runtime/graphql/item/apps.gql +34 -0
  109. package/dist/runtime/runtime/graphql/item/disciplines.gql +17 -0
  110. package/dist/runtime/runtime/graphql/item/events.gql +120 -0
  111. package/dist/runtime/runtime/graphql/item/fellowships.gql +164 -0
  112. package/dist/runtime/runtime/graphql/item/files.gql +25 -0
  113. package/dist/runtime/runtime/graphql/item/mailing.gql +10 -0
  114. package/dist/runtime/runtime/graphql/item/news.gql +129 -0
  115. package/dist/runtime/runtime/graphql/item/people.gql +174 -0
  116. package/dist/runtime/runtime/graphql/item/projects.gql +171 -0
  117. package/dist/runtime/runtime/graphql/item/publications.gql +169 -0
  118. package/dist/runtime/runtime/graphql/item/tags.gql +13 -0
  119. package/dist/runtime/runtime/graphql/item/users.gql +14 -0
  120. package/dist/runtime/runtime/graphql/list/action.gql +31 -0
  121. package/dist/runtime/runtime/graphql/list/affiliations.gql +42 -0
  122. package/dist/runtime/runtime/graphql/list/apps.gql +42 -0
  123. package/dist/runtime/runtime/graphql/list/disciplines.gql +22 -0
  124. package/dist/runtime/runtime/graphql/list/events.gql +44 -0
  125. package/dist/runtime/runtime/graphql/list/fellowships.gql +53 -0
  126. package/dist/runtime/runtime/graphql/list/files.gql +37 -0
  127. package/dist/runtime/runtime/graphql/list/mailing.gql +22 -0
  128. package/dist/runtime/runtime/graphql/list/news.gql +40 -0
  129. package/dist/runtime/runtime/graphql/list/people.gql +50 -0
  130. package/dist/runtime/runtime/graphql/list/projects.gql +37 -0
  131. package/dist/runtime/runtime/graphql/list/publications.gql +38 -0
  132. package/dist/runtime/runtime/graphql/list/search.gql +161 -0
  133. package/dist/runtime/runtime/graphql/list/tags.gql +22 -0
  134. package/dist/runtime/runtime/graphql/list/users.gql +38 -0
  135. package/dist/runtime/runtime/graphql/login.gql +0 -0
  136. package/dist/runtime/runtime/plugins/pinia.d.ts +2 -0
  137. package/dist/runtime/runtime/plugins/pinia.js +134 -0
  138. package/dist/runtime/runtime/plugins/vuetify.d.ts +2 -0
  139. package/dist/runtime/runtime/plugins/vuetify.js +21 -0
  140. package/dist/runtime/runtime/public/default.png +0 -0
  141. package/dist/runtime/runtime/public/filters.json +72 -0
  142. package/dist/runtime/runtime/server/tsconfig.json +3 -0
  143. package/dist/runtime/runtime/stores/factory.d.ts +25 -0
  144. package/dist/runtime/runtime/stores/factory.js +19 -0
  145. package/dist/runtime/runtime/stores/root.d.ts +60 -0
  146. package/dist/runtime/runtime/stores/root.js +315 -0
  147. package/dist/runtime/runtime/translations/en.json +350 -0
  148. package/dist/runtime/runtime/translations/fr.json +349 -0
  149. package/dist/runtime/runtime/types/imports.d.ts +13 -0
  150. package/dist/runtime/runtime/types/stores.d.ts +11 -0
  151. package/package.json +1 -1
@@ -0,0 +1,174 @@
1
+ <template>
2
+ <v-row>
3
+ <v-col
4
+ v-if="smAndDown"
5
+ cols="12"
6
+ class="text-wrap text-h4 text-black mx-sm-6"
7
+ >
8
+ <v-skeleton-loader
9
+ v-if="loading"
10
+ :type="['heading', 'heading'][['xs', 'sm'].indexOf(name || 'sm')]"
11
+ />
12
+ <template v-else>
13
+ <v-chip v-if="item && item.category && item.name" class="mb-4">
14
+ {{ $t("list.filters.news.category." + item.category) }}
15
+ </v-chip>
16
+ <br />
17
+ {{ item.name }}
18
+ </template>
19
+ </v-col>
20
+ <v-col cols="12" md="4" class="pb-0">
21
+ <v-skeleton-loader v-if="loading" height="100%" type="image" />
22
+
23
+ <div v-else class="mx-sm-6">
24
+ <MiscAtomsImageContainer
25
+ v-if="item && item.image"
26
+ cover
27
+ :loading="loading"
28
+ :src="item.image.url ? item.image : '/default.png'"
29
+ :ratio="1 / 1"
30
+ />
31
+ </div>
32
+ </v-col>
33
+
34
+ <v-col cols="12" md="8" class="pl-0 pb-0 d-flex flex-column justify-md-end">
35
+ <v-skeleton-loader
36
+ v-if="loading"
37
+ :type="
38
+ [
39
+ 'text, chip@4',
40
+ 'text, chip@4',
41
+ 'heading, text',
42
+ 'heading, text',
43
+ 'heading, text',
44
+ 'heading',
45
+ ][['xs', 'sm', 'md', 'lg', 'xl', 'xxl'].indexOf(name || 'md')]
46
+ "
47
+ />
48
+
49
+ <div v-else class="mx-4 mx-md-0 justify-md-end">
50
+ <v-chip v-if="item && item.category && mdAndUp" class="mb-4">
51
+ {{ $t("list.filters.news.category." + item.category) }}
52
+ </v-chip>
53
+ <div
54
+ v-if="item && item.name && mdAndUp"
55
+ class="d-flex text-wrap text-h4 text-black"
56
+ >
57
+ {{ item.name }}
58
+ </div>
59
+
60
+ <div
61
+ v-if="item.description && mdAndUp"
62
+ class="mt-md-n2 mx-4 mx-sm-8 mx-md-0 d-flex text-wrap text-h6 text-black mt-3"
63
+ >
64
+ <MDC v-if="item.description" :value="item.description" class="" />
65
+ </div>
66
+ <div
67
+ class="d-flex flex-column flex-md-row align-md-center mt-6 mx-sm-4 mx-md-6"
68
+ >
69
+ <div class="ml-md-n6">
70
+ <div
71
+ v-if="item && item.authors && item.authors[0]"
72
+ class="text-body-2 text-lg-body-1 text-black"
73
+ >
74
+ <!-- TODO use a proper & conditional formatting of names (depending on number of authors) -->
75
+ {{
76
+ $t("by-author", [
77
+ item.authors[0].firstname + " " + item.authors[0].firstname,
78
+ ])
79
+ }}
80
+ </div>
81
+ <div v-if="smAndDown" class="">
82
+ <MiscMoleculesChipContainer
83
+ v-if="item && item.tags"
84
+ :items="item.tags"
85
+ class="mt-4"
86
+ />
87
+ </div>
88
+ </div>
89
+ </div>
90
+ </div>
91
+ </v-col>
92
+ </v-row>
93
+
94
+ <v-row class="mt-12">
95
+ <v-col cols="12" md="4" :order="mdAndUp ? 'first' : 'last'" class="pt-0">
96
+ <v-skeleton-loader
97
+ v-if="loading"
98
+ :type="
99
+ ['chip@2', 'chip@3', 'chip@4', 'chip@5'][
100
+ ['md', 'lg', 'xl', 'xxl'].indexOf(name || 'md')
101
+ ]
102
+ "
103
+ />
104
+ <template v-else>
105
+ <div v-if="mdAndUp" class="mt-2 mx-sm-6">
106
+ <MiscMoleculesChipContainer
107
+ v-if="item && item.tags"
108
+ :items="item.tags"
109
+ class="mt-4"
110
+ />
111
+ </div>
112
+ </template>
113
+ </v-col>
114
+ <v-col cols="12" md="8" class="pl-0 pt-0">
115
+ <v-skeleton-loader
116
+ v-if="loading"
117
+ :type="
118
+ ['text@50', 'text@50', 'text@50', 'text@50', 'text@50', 'text@50'][
119
+ ['xs', 'sm', 'md', 'lg', 'xl', 'xxl'].indexOf(name || 'md')
120
+ ]
121
+ "
122
+ />
123
+ <div v-if="item.description" class="mt-md-n2 mx-4 mx-sm-8 mx-md-0">
124
+ <MDC :value="item.description" />
125
+ </div>
126
+ </v-col>
127
+ </v-row>
128
+
129
+ <!-- DIVIDERS -->
130
+ <v-responsive class="mx-auto my-9" width="120">
131
+ <v-divider class="mb-1" />
132
+ <v-divider />
133
+ </v-responsive>
134
+ <MiscAtomsSlidingCarousel
135
+ v-if="item && item.gallery && item.gallery.length"
136
+ ref="MiscAtomsImage"
137
+ key="MiscAtomsImage"
138
+ :items="item.gallery"
139
+ type="MiscAtomsImage"
140
+ :loading="false"
141
+ :more="false"
142
+ >
143
+ <div :class="mdAndUp ? 'text-h5' : 'text-h6'">
144
+ {{ $t("gallery") }}
145
+ </div>
146
+ </MiscAtomsSlidingCarousel>
147
+ <!-- DIVIDERS -->
148
+ <v-responsive class="mx-auto my-9" width="120">
149
+ <v-divider class="mb-1" />
150
+ <v-divider />
151
+ </v-responsive>
152
+
153
+ <MiscMoleculesRelated v-if="item && item.related" :related="item.related" />
154
+ </template>
155
+
156
+ <script setup>
157
+ import { useDisplay } from "vuetify";
158
+ import { useNuxtApp } from "#imports";
159
+ const { $stores } = useNuxtApp();
160
+ const { name, mdAndUp, smAndDown } = useDisplay();
161
+ const props = defineProps({
162
+ item: {
163
+ type: Object,
164
+ required: true
165
+ },
166
+ loading: {
167
+ type: Boolean,
168
+ required: false,
169
+ default: false
170
+ }
171
+ });
172
+ const today = /* @__PURE__ */ new Date();
173
+ $stores.news.loading = false;
174
+ </script>
@@ -0,0 +1,60 @@
1
+ <template>
2
+ <v-row
3
+ v-ripple
4
+ no-gutters
5
+ class="cursor-pointer highlight-on-hover"
6
+ @click="
7
+ $router.push(
8
+ localePath({
9
+ name: 'people-slug',
10
+ params: { slug: item.slug },
11
+ }),
12
+ )
13
+ "
14
+ >
15
+ <v-col v-if="mdAndUp" align-self="center" cols="1">
16
+ <MiscAtomsImageContainer
17
+ cover
18
+ :loading="$stores.people.loading"
19
+ :src="item.image.url ? item.image : '/default.png'"
20
+ :ratio="1 / 1"
21
+ :name="item.lastname + ' ' + item.firstname"
22
+ :slug="item.slug"
23
+ link="people-slug"
24
+ width="80px"
25
+ />
26
+ </v-col>
27
+ <v-col align-self="center" class="text-h6 dense pl-2">
28
+ <v-skeleton-loader v-if="rootStore.loading" type="heading" />
29
+ <div v-else class="text-h5">
30
+ {{ item.firstname + " " + item.lastname }}
31
+ </div>
32
+ <div class="mt-2 text-body-2 font-weight-light">
33
+ {{ item.groups.vintage ? item.groups.vintage[0].theme : "" }}
34
+ </div>
35
+ </v-col>
36
+ <v-col align-self="center" cols="auto">
37
+ <PeopleGroupBadges :item="item" />
38
+ </v-col>
39
+ </v-row>
40
+ </template>
41
+
42
+ <script setup>
43
+ import { useRootStore } from "../../stores/root";
44
+ import { useNuxtApp, useLocalePath } from "#imports";
45
+ import { useDisplay } from "vuetify";
46
+ const { mdAndUp } = useDisplay();
47
+ const { $stores } = useNuxtApp();
48
+ const localePath = useLocalePath();
49
+ const rootStore = useRootStore();
50
+ const props = defineProps({
51
+ item: {
52
+ type: Object,
53
+ required: true
54
+ },
55
+ index: {
56
+ type: Number,
57
+ required: true
58
+ }
59
+ });
60
+ </script>
@@ -0,0 +1,14 @@
1
+ <template>
2
+ <div>
3
+ {{ item.name }}
4
+ </div>
5
+ </template>
6
+
7
+ <script setup>
8
+ const props = defineProps({
9
+ item: {
10
+ type: Object,
11
+ required: true
12
+ }
13
+ });
14
+ </script>
@@ -0,0 +1,54 @@
1
+ <template>
2
+ <div>
3
+ <v-skeleton-loader
4
+ v-if="rootStore.loading || $stores.people.loading"
5
+ type="chip"
6
+ />
7
+ <template v-else-if="item.groups">
8
+ <template v-for="(value, key, index) in item.groups" :key="key + index">
9
+ <template v-if="value && key === 'vintage'">
10
+ <v-chip
11
+ v-for="(vintage, index2) in item.groups.vintage"
12
+ :key="index2"
13
+ class="mt-3 mr-3"
14
+ variant="outlined"
15
+ tile
16
+ style="background-color: white; color: black"
17
+ >
18
+ {{ $t("vintage", [vintage.year]) }}
19
+ </v-chip>
20
+ </template>
21
+
22
+ <v-chip
23
+ v-if="
24
+ value &&
25
+ key !== 'fellows' &&
26
+ ((!item.groups.vintage && key === 'vintage') ||
27
+ !['vintage', '__typename'].includes(key))
28
+ "
29
+ class="mt-3 mr-3"
30
+ color="black"
31
+ style="background-color: white; color: black"
32
+ tile
33
+ variant="outlined"
34
+ >
35
+ {{ $t("list.filters.people.groups." + key) }}
36
+ </v-chip>
37
+ </template>
38
+ </template>
39
+ </div>
40
+ </template>
41
+
42
+ <script setup>
43
+ import { useRootStore } from "../../stores/root";
44
+ import { useNuxtApp } from "#imports";
45
+ const rootStore = useRootStore();
46
+ const { $stores } = useNuxtApp();
47
+ const props = defineProps({
48
+ item: {
49
+ type: Object,
50
+ required: true,
51
+ default: () => ({})
52
+ }
53
+ });
54
+ </script>
@@ -0,0 +1,41 @@
1
+ <template>
2
+ <v-sheet
3
+ :to="
4
+ localePath({
5
+ name: 'people-slug',
6
+ params: { slug: item.slug },
7
+ })
8
+ "
9
+ >
10
+ <v-row>
11
+ <v-col v-if="lgAndUp" cols="3">
12
+ <MiscAtomsImageContainer
13
+ cover
14
+ :loading="rootStore.loading"
15
+ :src="item.image"
16
+ :ratio="1 / 1"
17
+ :link="item.firstname + item.lastname"
18
+ :name="people - slug"
19
+ />
20
+ </v-col>
21
+ <v-col cols="12" lg="9">
22
+ <v-skeleton-loader v-if="rootStore.loading" type="heading" />
23
+ <template v-else>
24
+ <div class="text-h6">
25
+ {{ item.firstname + " " + item.lastname }}
26
+ </div>
27
+ </template>
28
+ </v-col>
29
+ </v-row>
30
+ </v-sheet>
31
+ </template>
32
+
33
+ <script setup>
34
+ import { useDisplay } from "vuetify";
35
+ import { useRootStore } from "../../stores/root";
36
+ import { useLocalePath } from "#imports";
37
+ const localePath = useLocalePath();
38
+ const rootStore = useRootStore();
39
+ const { lgAndUp } = useDisplay();
40
+ const props = defineProps({ item: { type: Object, required: true } });
41
+ </script>
@@ -0,0 +1,93 @@
1
+ <template>
2
+ <v-divider v-if="index > 0" />
3
+ <v-row
4
+ class="my-6 ml-md-1 px-3 px-md-0 highlight-on-hover"
5
+ @click="
6
+ $router.push(
7
+ localePath({
8
+ name: 'people-slug',
9
+ params: { slug: item.slug },
10
+ })
11
+ )
12
+ "
13
+ >
14
+ <v-col v-if="mdAndUp" cols="12" md="3">
15
+ <MiscAtomsImageContainer
16
+ cover
17
+ :loading="$stores.people.loading"
18
+ :src="item.image.url ? item.image : '/default.png'"
19
+ :ratio="1 / 1"
20
+ :name="item.lastname + ' ' + item.firstname"
21
+ :slug="item.slug"
22
+ link="people-slug"
23
+ />
24
+ </v-col>
25
+
26
+ <v-col cols="12" md="8">
27
+ <v-skeleton-loader
28
+ v-if="$stores.people.loading"
29
+ :type="
30
+ [
31
+ 'heading, subtitle, text@5',
32
+ 'heading, subtitle, text@5',
33
+ 'heading, subtitle, text@3',
34
+ 'heading, subtitle, text@6',
35
+ 'heading, subtitle, text@9',
36
+ 'heading, subtitle, text@9',
37
+ ][['xs', 'sm', 'md', 'lg', 'xl', 'xxl'].indexOf(name || 'md')]
38
+ "
39
+ />
40
+
41
+ <div v-else class="ml-md-8">
42
+ <NuxtLink
43
+ :to="
44
+ localePath({
45
+ name: 'people-slug',
46
+ params: { slug: item.slug },
47
+ })
48
+ "
49
+ class="text-wrap text-h5 text-md-h4 text-black"
50
+ >
51
+ {{ item.firstname + " " + item.lastname }}
52
+ </NuxtLink>
53
+ <MiscAtomsSocials v-if="item.socials" :socials="item.socials" />
54
+ <PeopleGroupBadges :item="item" />
55
+ <div
56
+ v-if="item.biography && item.biography.length > 0"
57
+ class="text-wrap clamped-text text-black"
58
+ :style="'-webkit-line-clamp:' + lineClamp"
59
+ >
60
+ <MDC :value="item.biography" />
61
+ </div>
62
+
63
+ <div v-else class="text-body-2">
64
+ {{ $t("no-biography") }}
65
+ </div>
66
+ </div>
67
+ </v-col>
68
+ </v-row>
69
+ </template>
70
+
71
+ <script setup>
72
+ import { useDisplay } from "vuetify";
73
+ import { useLocalePath, computed } from "#imports";
74
+ const { name, mdAndUp } = useDisplay();
75
+ const localePath = useLocalePath();
76
+ const props = defineProps({
77
+ item: {
78
+ type: Object,
79
+ required: true
80
+ },
81
+ index: {
82
+ type: Number,
83
+ required: true
84
+ }
85
+ });
86
+ const lineClamp = computed(() => {
87
+ let base = [5, 6, 3, 6, 8, 10][["xs", "sm", "md", "lg", "xl", "xxl"].indexOf(name.value || "md")];
88
+ if (props.item?.socials && Object.keys(props.item.socials).length > 0) {
89
+ base = base - [0, 0, 1, 1, 1, 2][["xs", "sm", "md", "lg", "xl", "xxl"].indexOf(name.value || "md")];
90
+ }
91
+ return base;
92
+ });
93
+ </script>
@@ -0,0 +1,172 @@
1
+ <template>
2
+ <v-row justify="center">
3
+ <v-col cols="12" sm="11" md="8" lg="8" xl="6">
4
+ <v-row no-gutters class="justify-center">
5
+ <v-col cols="12" sm="10" md="6" class="text-center">
6
+ <!-- PEOPLE IMAGE -->
7
+ <MiscAtomsImageContainer
8
+ v-if="mdAndUp && item && item.image"
9
+ cover
10
+ :loading="loading"
11
+ :src="item.image"
12
+ :ratio="1 / 1"
13
+ :width="
14
+ [200, 250, 250, 300][
15
+ ['md', 'lg', 'xl', 'xxl'].indexOf(name || 'md')
16
+ ]
17
+ "
18
+ />
19
+ </v-col>
20
+ <v-col cols="12" class="text-center">
21
+ <!-- FIRSTNAME LASTNAME -->
22
+ <v-skeleton-loader
23
+ v-if="loading"
24
+ class="mx-auto"
25
+ :max-width="
26
+ ['300', '400', '340', '400', '600', '600'][
27
+ ['xs', 'sm', 'md', 'lg', 'xl', 'xxl'].indexOf(name || 'md')
28
+ ]
29
+ "
30
+ :type="
31
+ [
32
+ 'heading@2, ossein, avatar@4, ossein, chip@3',
33
+ 'heading, ossein, avatar@6, ossein, chip@4',
34
+ 'heading, ossein, avatar@5, ossein, chip@3',
35
+ 'heading, ossein, avatar@6, ossein, chip@4',
36
+ 'heading, ossein, avatar@9, ossein, chip@6',
37
+ 'heading, ossein, avatar@9, ossein, chip@6',
38
+ ][['xs', 'sm', 'md', 'lg', 'xl', 'xxl'].indexOf(name || 'md')]
39
+ "
40
+ />
41
+
42
+ <template v-else>
43
+ <div
44
+ v-if="item && item.firstname && item.lastname"
45
+ class="my-8 text-h3 align-self-center text-wrap"
46
+ >
47
+ {{ item.firstname + " " + item.lastname
48
+ }}<!-- TODO : call a composable to format people names (multiple, initials, capped & al. ) -->
49
+ </div>
50
+ <!-- SOCIALS -->
51
+ <div class="text-center">
52
+ <MiscAtomsSocials
53
+ v-if="item && item.socials"
54
+ :socials="item.socials"
55
+ />
56
+ </div>
57
+ <!-- GROUPS -->
58
+ <div class="mt-6 align-self-center">
59
+ <PeopleGroupBadges v-if="item && item.groups" :item="item" />
60
+ </div>
61
+ </template>
62
+ </v-col>
63
+ </v-row>
64
+
65
+ <!-- DIVIDERS -->
66
+ <v-responsive class="mx-auto my-6" width="120">
67
+ <v-divider class="mb-1" />
68
+ <v-divider />
69
+ </v-responsive>
70
+
71
+ <div class="text-overline mt-6">
72
+ <v-skeleton-loader v-if="loading" width="200" type="heading" />
73
+ <div v-else>
74
+ {{ $t("biography") }}
75
+ </div>
76
+ </div>
77
+
78
+ <v-skeleton-loader
79
+ v-if="loading"
80
+ :type="
81
+ ['text@16', 'text@16', 'text@16', 'text@12', 'text@12', 'text@12'][
82
+ ['xs', 'sm', 'md', 'lg', 'xl', 'xxl'].indexOf(name || 'md')
83
+ ]
84
+ "
85
+ />
86
+ <template v-else class="my-6 flex-wrap">
87
+ <MDC
88
+ v-if="item.biography && item.biography.length > 0"
89
+ :value="item.biography"
90
+ />
91
+ <div v-else class="text-body-2">
92
+ {{ $t("no-biography") }}
93
+ </div>
94
+ </template>
95
+
96
+ <!-- DIVIDERS -->
97
+ <v-responsive class="mx-auto my-9" width="120">
98
+ <v-divider class="mb-1" />
99
+ <v-divider />
100
+ </v-responsive>
101
+
102
+ <!-- POSITIONS AND AFFILIATIONS -->
103
+ <div class="text-overline mt-6">
104
+ <v-skeleton-loader v-if="loading" width="200" type="heading" />
105
+ <div v-else>
106
+ {{ $t("positions-and-affiliations") }}
107
+ </div>
108
+ </div>
109
+
110
+ <!-- BIOGRAPHY -->
111
+ <v-skeleton-loader v-if="loading" type="subtitle, text@2" width="300" />
112
+
113
+ <v-card
114
+ v-for="record in item.affiliations"
115
+ v-else-if="item && item.affiliations"
116
+ :key="record.affiliation"
117
+ flat
118
+ >
119
+ <v-card-item class="px-0">
120
+ <v-card-title class="text-wrap">
121
+ {{ record.affiliation.name }}
122
+ </v-card-title>
123
+ <div
124
+ v-for="(position, index) in record.positions"
125
+ :key="position.role + index"
126
+ class="text-body-2"
127
+ >
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>
136
+ <span v-if="position.start" class="">
137
+ <!-- TODO FIx dates display -->
138
+ -
139
+ {{
140
+ $t("from {0} to {1}", [
141
+ formatDate(position.start, locale),
142
+ (position.stop && formatDate(position.stop, locale)) ||
143
+ $t("present"),
144
+ ])
145
+ }}
146
+ </span>
147
+ </div>
148
+ </v-card-item>
149
+ </v-card>
150
+ </v-col>
151
+ </v-row>
152
+
153
+ <!-- DIVIDERS -->
154
+ <v-responsive class="mx-auto my-9" width="120">
155
+ <v-divider class="mb-1" />
156
+ <v-divider />
157
+ </v-responsive>
158
+ <MiscMoleculesRelated v-if="item && item.related" :related="item.related" />
159
+ </template>
160
+
161
+ <script setup>
162
+ import { useDisplay } from "vuetify";
163
+ import { useNuxtApp, useI18n } from "#imports";
164
+ const { locale } = useI18n();
165
+ const { $stores } = useNuxtApp();
166
+ const { name, mdAndUp } = useDisplay();
167
+ const props = defineProps({
168
+ item: { type: Object, required: true },
169
+ loading: { type: Boolean, default: false }
170
+ });
171
+ $stores.people.loading = false;
172
+ </script>
@@ -0,0 +1,77 @@
1
+ <template>
2
+ <v-row
3
+ v-ripple
4
+ no-gutters
5
+ class="cursor-pointer highlight-on-hover"
6
+ @click="
7
+ $router.push(
8
+ localePath({
9
+ name: 'activities-projects-slug',
10
+ params: { slug: item.slug[locale] },
11
+ }),
12
+ )
13
+ "
14
+ >
15
+ <v-col v-if="mdAndUp" align-self="center" cols="1">
16
+ <MiscAtomsImageContainer
17
+ cover
18
+ :loading="$stores.projects.loading"
19
+ :src="item.image.url ? item.image : '/default.png'"
20
+ :ratio="1 / 1"
21
+ :name="item.name"
22
+ :slug="item.slug[locale]"
23
+ link="activities-projects-slug"
24
+ width="50"
25
+ />
26
+ </v-col>
27
+ <v-col align-self="center" class="text-h5 dense pl-2">
28
+ <v-skeleton-loader v-if="rootStore.loading" type="heading" />
29
+ <template v-else>
30
+ {{ item.name }}
31
+ </template>
32
+ </v-col>
33
+
34
+ <v-col align-self="center" cols="5" class="dense">
35
+ <v-skeleton-loader
36
+ v-if="rootStore.loading"
37
+ :type="
38
+ ['chip', 'chip@2', 'chip@3', 'chip@4', 'chip@4', 'chip@4'][
39
+ ['xs', 'sm', 'md', 'lg', 'xl', 'xxl'].indexOf(name || 'md')
40
+ ]
41
+ "
42
+ />
43
+
44
+ <template v-else>
45
+ <MiscMoleculesChipContainer :items="item.tags" size="small" />
46
+ </template>
47
+ </v-col>
48
+ </v-row>
49
+ </template>
50
+
51
+ <script setup>
52
+ import { useDisplay } from "vuetify";
53
+ import { useRootStore } from "../../stores/root";
54
+ import { computed, useNuxtApp, useI18n, useLocalePath } from "#imports";
55
+ const { $stores } = useNuxtApp();
56
+ const { name, mdAndUp } = useDisplay();
57
+ const localePath = useLocalePath();
58
+ const { locale } = useI18n();
59
+ const rootStore = useRootStore();
60
+ const props = defineProps({
61
+ item: {
62
+ type: Object,
63
+ required: true
64
+ },
65
+ index: {
66
+ type: Number,
67
+ required: true
68
+ }
69
+ });
70
+ const eventCategory = computed(() => {
71
+ if (props.item.category) {
72
+ return "list.filters.news.category." + props.item.category;
73
+ } else {
74
+ return "list.filters.news.category.others";
75
+ }
76
+ });
77
+ </script>