Skip to content

Commit 82a2d91

Browse files
Merge pull request #115 from clubcapra/114-design-of-a-recrutement-page
114 design of a recrutement page
2 parents cd14f43 + 7d9d79d commit 82a2d91

16 files changed

+831
-130
lines changed

src/assets/media/join/bbq.jpg

868 KB
Loading
1.34 MB
Loading

src/assets/media/join/ele_working.jpg

1.24 MB
Loading

src/assets/media/join/mapping.jpg

179 KB
Loading

src/assets/media/join/meeting_mec.jpg

1.57 MB
Loading

src/assets/media/join/new_arm.jpg

217 KB
Loading
1.77 MB
Loading

src/assets/media/join/pcb_working.jpg

1.36 MB
Loading
35.6 MB
Binary file not shown.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
<script lang="ts" setup>
2+
const props = defineProps<{
3+
button?: string;
4+
link?: string;
5+
imageRight: boolean;
6+
}>();
7+
</script>
8+
9+
<template>
10+
<div
11+
class="container mx-auto px-4 py-20 flex flex-col gap-8 items-center w-full"
12+
:class="props.imageRight ? 'md:flex-row' : 'md:flex-row-reverse'"
13+
>
14+
<div
15+
class="flex flex-col gap-8 md:w-1/2"
16+
data-aos="fade-up"
17+
data-aos-delay="200"
18+
>
19+
<h2 class="font-bold font-sans text-4xl md:text-5xl">
20+
<slot name="title" />
21+
</h2>
22+
<p v-if="$slots.content1">
23+
<slot name="content1" />
24+
</p>
25+
<p v-if="$slots.content2">
26+
<slot name="content2" />
27+
</p>
28+
<a
29+
v-if="props.button && props.link"
30+
class="bg-black hover:border-primary-50 border-2 border-black transition-colors text-white font-medium text-lg py-2 px-4 rounded-lg w-fit"
31+
:href="props.link"
32+
target="_blank"
33+
>
34+
{{ props.button }}
35+
</a>
36+
</div>
37+
<div class="w-full md:w-1/2" data-aos="fade-up" data-aos-delay="400">
38+
<slot name="image" />
39+
</div>
40+
</div>
41+
</template>

src/components/FAQComponent.vue

+117
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,117 @@
1+
<script setup lang="ts">
2+
import { ref, type Ref } from 'vue';
3+
import { useI18n } from 'vue-i18n';
4+
5+
const { t } = useI18n();
6+
7+
export interface QA {
8+
question: string;
9+
answer: string;
10+
}
11+
12+
const content: QA[] = [
13+
{
14+
question: 'question_implication',
15+
answer: 'answer_implication',
16+
},
17+
{
18+
question: 'question_skills',
19+
answer: 'answer_skills',
20+
},
21+
{
22+
question: 'question_apply',
23+
answer: 'answer_apply',
24+
},
25+
{
26+
question: 'question_recruitment_period',
27+
answer: 'answer_recruitment_period',
28+
},
29+
{
30+
question: 'question_visit',
31+
answer: 'answer_visit',
32+
},
33+
];
34+
35+
const selected: Ref<number | null> = ref(null);
36+
const showAll = ref(false);
37+
const containers: Ref<HTMLElement[]> = ref([]);
38+
</script>
39+
40+
<template>
41+
<section
42+
id="FAQ"
43+
class="container mx-auto mb-10 px-4 bg-gray-100 w-100 pt-10 rounded-2xl"
44+
>
45+
<h2 class="text-5xl md:text-6xl font-bold font-sans text-center pt-10">
46+
{{ t('faq') }}
47+
</h2>
48+
<div class="flex justify-center px-4 py-20">
49+
<div class="container mx-auto px-4">
50+
<!-- Column 1 -->
51+
<div class="bg-white max-w-full mx-auto border border-gray-200">
52+
<ul class="shadow-box">
53+
<li
54+
v-for="(qa, index) in content"
55+
:key="index"
56+
class="relative border-b border-gray-200"
57+
>
58+
<button
59+
type="button"
60+
class="w-full px-6 py-5 text-left"
61+
@click="
62+
selected !== index ? (selected = index) : (selected = null)
63+
"
64+
>
65+
<div class="flex items-center justify-between">
66+
<div class="flex">
67+
<p class="w-8 shrink-0 text-xl font-semibold">
68+
{{ t('question') }}
69+
</p>
70+
<p class="pt-1">{{ t(qa.question) }}</p>
71+
</div>
72+
<svg
73+
:class="{
74+
'transform rotate-180': selected == index || showAll,
75+
}"
76+
class="w-5 h-5 text-gray-500"
77+
fill="none"
78+
stroke-linecap="round"
79+
stroke-linejoin="round"
80+
stroke-width="2"
81+
viewBox="0 0 24 24"
82+
stroke="currentColor"
83+
>
84+
<path d="M19 9l-7 7-7-7" />
85+
</svg>
86+
</div>
87+
</button>
88+
<div
89+
ref="containers"
90+
class="relative overflow-hidden transition-all max-h-0 duration-700"
91+
style=""
92+
:style="
93+
selected == index || showAll
94+
? 'max-height: ' + containers[index]?.scrollHeight + 'px'
95+
: ''
96+
"
97+
>
98+
<div class="px-6 pb-5 flex">
99+
<p class="w-8 shrink-0 text-xl font-semibold">
100+
{{ t('answer') }}
101+
</p>
102+
<p class="pt-1">{{ t(qa.answer) }}</p>
103+
</div>
104+
</div>
105+
</li>
106+
</ul>
107+
</div>
108+
</div>
109+
</div>
110+
</section>
111+
</template>
112+
113+
<style scoped>
114+
.max-h-0 {
115+
max-height: 0;
116+
}
117+
</style>

src/components/NavbarComponent.vue

+7-2
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,20 @@ const navbarItems = [
1616
selected: false,
1717
},
1818
{
19-
name: 'partners',
19+
name: 'page_partners',
2020
link: '/partners',
2121
selected: false,
2222
},
2323
{
24-
name: 'Publications',
24+
name: 'page_publications',
2525
link: '/publications',
2626
selected: false,
2727
},
28+
{
29+
name: 'page_join',
30+
link: '/join',
31+
selected: false,
32+
},
2833
];
2934
3035
// Hide navbar until scroll

0 commit comments

Comments
 (0)