125 lines
2.1 KiB
Vue
125 lines
2.1 KiB
Vue
<template>
|
|
<div class="project">
|
|
<div class="project-header">
|
|
<h2 @click="goToLink">{{ projectName }}</h2>
|
|
<div class="project-buttons">
|
|
<button class="contact-btn">Contact</button>
|
|
</div>
|
|
</div>
|
|
<div class="project-body">
|
|
<ul>
|
|
<li v-for="(name, index) in listName" :key="index">{{ name }}</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
|
|
|
|
<script setup lang="ts">
|
|
import { defineProps } from "vue";
|
|
|
|
|
|
const props = defineProps<{
|
|
projectName: string;
|
|
listName: string[];
|
|
projectLink: string;
|
|
}>();
|
|
|
|
const goToLink = () => {
|
|
if (props.projectLink) {
|
|
window.location.href = props.projectLink;
|
|
}
|
|
};
|
|
</script>
|
|
|
|
|
|
<style scoped>
|
|
.project {
|
|
background: linear-gradient(to right, #f4f4f4, #ffffff);
|
|
border: 1px solid #ddd;
|
|
border-radius: 10px;
|
|
padding: 20px;
|
|
margin: 20px 0;
|
|
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
|
|
font-family: Arial, sans-serif;
|
|
}
|
|
|
|
/* Header Styling */
|
|
.project-header {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
}
|
|
|
|
.project-header h2 {
|
|
font-size: 20px;
|
|
color: #333;
|
|
margin: 0;
|
|
}
|
|
|
|
/* Button Container */
|
|
.project-buttons {
|
|
display: flex;
|
|
gap: 10px;
|
|
}
|
|
|
|
|
|
.info-btn {
|
|
background-color: #4CAF50;
|
|
color: #fff;
|
|
}
|
|
|
|
.info-btn:hover {
|
|
background-color: #45a049;
|
|
transform: scale(1.05);
|
|
}
|
|
|
|
.contact-btn {
|
|
background-color: #007BFF;
|
|
color: #fff;
|
|
}
|
|
|
|
.contact-btn:hover {
|
|
background-color: #0056b3;
|
|
transform: scale(1.05);
|
|
}
|
|
|
|
|
|
|
|
|
|
.project-body {
|
|
margin-top: 15px;
|
|
}
|
|
|
|
.project-body p {
|
|
font-size: 16px;
|
|
color: #555;
|
|
margin-bottom: 10px;
|
|
}
|
|
|
|
.project-body ul {
|
|
list-style-type: disc;
|
|
margin: 0;
|
|
padding-left: 20px;
|
|
}
|
|
|
|
.project-body ul li {
|
|
font-size: 14px;
|
|
color: #666;
|
|
line-height: 1.6;
|
|
}
|
|
|
|
|
|
button {
|
|
padding: 10px 15px;
|
|
background-color: #007bff;
|
|
color: white;
|
|
border: none;
|
|
cursor: pointer;
|
|
border-radius: 5px;
|
|
}
|
|
button:hover {
|
|
background-color: #0056b3;
|
|
}
|
|
|
|
</style> |