new project cards with modals!
This commit is contained in:
parent
99c911c5d4
commit
d33022ac09
7 changed files with 316 additions and 11 deletions
56
components/ProjectCardContent.vue
Normal file
56
components/ProjectCardContent.vue
Normal file
|
|
@ -0,0 +1,56 @@
|
|||
<template>
|
||||
<div>
|
||||
<!-- <button @click="$emit('close')"> Close </button> -->
|
||||
<img src="public\img\close.png" class="close-button" @click="$emit('close')">
|
||||
<h2>{{title}}</h2>
|
||||
<p>{{description}}</p>
|
||||
|
||||
<br>
|
||||
<!-- <ClientOnly> -->
|
||||
<div class="buttons">
|
||||
<SmallButton v-for="(data, i) of buttons" :key="i" class="button" :text="data.text"
|
||||
:href="data.link" />
|
||||
</div>
|
||||
<!-- </ClientOnly> -->
|
||||
<br>
|
||||
<p class="multiline-css-fix">{{longDescription}}</p>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import {defineProps, defineEmits} from 'vue'
|
||||
|
||||
export interface ButtonData {
|
||||
text: string,
|
||||
link: string,
|
||||
}
|
||||
|
||||
const props = defineProps<{
|
||||
title: string,
|
||||
description: string,
|
||||
longDescription?: string,
|
||||
buttons?: Array<ButtonData>,
|
||||
}>();
|
||||
|
||||
defineEmits("close")
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
.close-button{
|
||||
float:right;
|
||||
/* display: block; */
|
||||
/* margin-left: auto; */
|
||||
width: 32px;
|
||||
|
||||
&:hover{
|
||||
filter: invert();
|
||||
}
|
||||
}
|
||||
|
||||
.multiline-css-fix{
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
|
||||
</style>
|
||||
139
components/ProjectCardV2.vue
Normal file
139
components/ProjectCardV2.vue
Normal file
|
|
@ -0,0 +1,139 @@
|
|||
<template>
|
||||
<div class="top-level">
|
||||
<!-- <button @click="isOpen=true">Open</button> -->
|
||||
<!-- Project Card -->
|
||||
<div @click="isOpen=true" class="card">
|
||||
<img class="project-image" :src="props.src">
|
||||
<div class="content">
|
||||
<h2>{{props.title}}</h2>
|
||||
<p>{{props.description}}</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Popup Modal -->
|
||||
<Teleport to="body">
|
||||
<div class="modal" v-if="isOpen">
|
||||
<div>
|
||||
<ProjectCardContent
|
||||
@close="isOpen = false"
|
||||
:title=props.title
|
||||
:description=props.description
|
||||
:long-description=props.longDescription
|
||||
:buttons=props.buttons
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</Teleport>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
|
||||
import {ref, defineProps} from 'vue'
|
||||
import ProjectCardContent from './ProjectCardContent.vue';
|
||||
const isOpen = ref(false)
|
||||
|
||||
export interface ButtonData {
|
||||
text: string,
|
||||
link: string,
|
||||
}
|
||||
|
||||
const props = defineProps<{
|
||||
title: string,
|
||||
description: string,
|
||||
longDescription?: string,
|
||||
src: string,
|
||||
buttons?: Array<ButtonData>,
|
||||
}>();
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.root{
|
||||
position:relative
|
||||
}
|
||||
|
||||
.top-level{
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
.card{
|
||||
position: relative;
|
||||
text-align: center;
|
||||
overflow: hidden;
|
||||
border-color: var(--accent);
|
||||
border-width: 3px;
|
||||
border-style: solid;
|
||||
width: 100%;
|
||||
/* overflow: auto; */
|
||||
height: max-content;
|
||||
|
||||
&:hover{
|
||||
border-color: white;
|
||||
cursor: pointer;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.project-image{
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.content{
|
||||
position: absolute;
|
||||
bottom: 8px;
|
||||
left: 16px;
|
||||
text-align: left ;
|
||||
visibility:hidden;
|
||||
|
||||
/* &:hover{
|
||||
visibility: visible;
|
||||
} */
|
||||
|
||||
}
|
||||
|
||||
|
||||
.card>img:hover{
|
||||
/* filter: brightness(40%) blur(2px); */
|
||||
|
||||
|
||||
}
|
||||
|
||||
.card:hover, .content:hover{
|
||||
|
||||
border-color: white;
|
||||
cursor: pointer;
|
||||
|
||||
.content{
|
||||
visibility: visible;
|
||||
}
|
||||
|
||||
.project-image{
|
||||
filter: brightness(40%) blur(2px);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.modal {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 100;
|
||||
background-color: rgba(0,0,0,0.1);
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.modal > div{
|
||||
background-color: rgb(53, 53, 53);
|
||||
padding: 50px;
|
||||
border-radius: 10px;
|
||||
margin: 10%;
|
||||
max-height: calc(100vh - 210px);
|
||||
overflow-y: auto;
|
||||
}
|
||||
</style>
|
||||
41
components/SmallButton.vue
Normal file
41
components/SmallButton.vue
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
<script setup lang="ts">
|
||||
const props = defineProps({
|
||||
href: String,
|
||||
text: String
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<a class="button" :href="props.href">
|
||||
<p>{{ props.text }}</p>
|
||||
</a>
|
||||
|
||||
|
||||
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
.button {
|
||||
background-color: #8904aa;
|
||||
border: none;
|
||||
color: white;
|
||||
padding: 5px;
|
||||
border-radius: 5px;
|
||||
text-align: center;
|
||||
text-decoration: none;
|
||||
display: inline-block;
|
||||
font-size: 16px;
|
||||
overflow: hidden;
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
.button:hover{
|
||||
background-color: var(--accent);
|
||||
color: black;
|
||||
}
|
||||
|
||||
p{
|
||||
font-weight: 100;
|
||||
margin: 0;
|
||||
}
|
||||
</style>
|
||||
27
pages/TestPage.vue
Normal file
27
pages/TestPage.vue
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
<template>
|
||||
<div>
|
||||
<ProjectCardV2
|
||||
title="Arcane Raiders but really really long"
|
||||
description="Cool game"
|
||||
:buttons='[
|
||||
{ link: "https://tabbycat.dev", text: "tabbycat.dev" },
|
||||
{ link: "https://www.linkedin.com/in/tom--howarth/", text: "Linkedin" },
|
||||
{ link: "https://bsky.app/profile/tabbycat.dev", text: "Bluesky" },
|
||||
{ link: "https://tabby-cat-nya.itch.io/", text: "Itch.io" }
|
||||
]'
|
||||
/>
|
||||
|
||||
<!-- <BoldButton
|
||||
text="test"
|
||||
href="hello"
|
||||
/> -->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
</style>
|
||||
|
|
@ -96,28 +96,56 @@ var { data } = await useAsyncData('home', () => queryContent('blog').where({hidd
|
|||
<!-- featured projects, link to all? -->
|
||||
<h1>Featured Projects</h1>
|
||||
<div class="featured-container">
|
||||
<ProjectCard
|
||||
src="https://img.itch.zone/aW1nLzE2Mjg0ODg2LnBuZw==/315x250%23c/6FRKz0.png"
|
||||
href="https://teamstingray.dev/arcane-raiders"
|
||||
heading="Arcane Raiders"
|
||||
description="Fight to the top of the tower with up to 4 players and an arsenal of powerful spells! We'll be showcasing it at SXSW Sydeny and its already avilable to wishlist on Steam!"
|
||||
<ProjectCardV2
|
||||
src="https://img.itch.zone/aW1nLzE2Mjg0ODg2LnBuZw==/315x250%23c/6FRKz0.png"
|
||||
title="Arcane Raiders"
|
||||
description="Fight to the top of the tower with up to 4 players and an arsenal of powerful spells! Now available to play on Steam!"
|
||||
long-description=
|
||||
"Initially, This project was a part of Game Design Studio 1 at UTS where we worked in teams of 5 people to create a game through the semester.
|
||||
|
||||
During the assignment, my main contributions were general programming and game logic as well as some of the back-end code for the local and online multiplayer systems and UI.
|
||||
|
||||
After the completion of the subject, our group continued to work on the project in our own time to further improve it and showcase it at future events such as the UTS Tech Fest where we received the Best Student Game award, and also South By South West where we were nominated for Best Student Game.
|
||||
|
||||
In these later stages of development my focus shifted more to project management in addition building the Steam page and finalizing the integration of services such as achievements, cloud saves and discord rich presence into the game.
|
||||
|
||||
On the 19th of February the game was released and since then we have had over 4200 unique players!"
|
||||
:buttons='[
|
||||
{ link: "https://store.steampowered.com/app/2899410/Arcane_Raiders/", text: "Play on Steam" },
|
||||
{ link: "https://discord.com/invite/3BPYMHqNve", text: "Join Discord" },
|
||||
{ link: "https://cookiespl.itch.io/arcane-raiders", text: "View Itch.io page (Outdated)" }
|
||||
]'
|
||||
/>
|
||||
|
||||
<ProjectCard
|
||||
<ProjectCardV2
|
||||
src="https://img.itch.zone/aW1nLzE2NTkxMzEyLnBuZw==/315x250%23c/0Y7BUi.png"
|
||||
href="https://clevertop.itch.io/kitten-calamity"
|
||||
heading="Kitten Calamity"
|
||||
title="Kitten Calamity"
|
||||
description="Cute little game made in about 29 hours for the UTS Tech Fest game jam! Grab a friend and find out who can be the most destructive little kitten in one minute :3"
|
||||
long-description=
|
||||
"This little project was made with a team of 3 for the UTS Tech Fest Game Jam. Using Godot, my main focus was on the player controls, the overall game logic and the user interface.
|
||||
|
||||
At the end of the game jam our game received the Most Intuitive Game award."
|
||||
:buttons='[
|
||||
{ link: "https://clevertop.itch.io/kitten-calamity", text: "Play on Itch.io" }
|
||||
]'
|
||||
/>
|
||||
|
||||
<ProjectCard
|
||||
src="https://img.itch.zone/aW1nLzU3NzU5NTEucG5n/315x250%23c/eQja%2FA.png"
|
||||
href="https://clevertop.itch.io/temple-of-the-silver-dragon"
|
||||
heading="Temple of the Silver Dragon"
|
||||
<ProjectCardV2
|
||||
src="https://img.itch.zone/aW1nLzU3NzU5NTEucG5n/315x250%23c/eQja%2FA.png"
|
||||
title="Temple of the Silver Dragon"
|
||||
description="You have five minutes on the clock. How much treasure can you collect and escape with before time runs out? While this project is an older one, its also one of my favourites :)"
|
||||
long-description=
|
||||
"Temple of the Silver Dragon is one of my older projects which was made in the Unity game engine before I switched over to Godot.
|
||||
|
||||
It's one of my most extensive works as it entirely a solo project, In addition to the main game play components such as: First person camera and movement, level design, enemy logic, game logic, testing and balancing. I also implemented some special features including a 'Ghost' replay system and an online leaderboard using Airtable. Through this leaderboard I've been able to calculate that a total of over 110 hours have been played!"
|
||||
:buttons='[
|
||||
{ link: "https://clevertop.itch.io/temple-of-the-silver-dragon", text: "Play on Itch.io" }
|
||||
]'
|
||||
/>
|
||||
|
||||
</div>
|
||||
<BigButton text="View Entire Portfolio >>>" href="/projects"/>
|
||||
|
||||
<!-- seperator -->
|
||||
<hr/>
|
||||
|
|
@ -174,6 +202,7 @@ h1{
|
|||
display: flex;
|
||||
width: 100%;
|
||||
justify-content: center;
|
||||
margin-bottom: 5px;
|
||||
|
||||
/* margin-left: auto;
|
||||
margin-right: auto; */
|
||||
|
|
|
|||
13
pages/projects.vue
Normal file
13
pages/projects.vue
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
<template>
|
||||
<div>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
</style>
|
||||
BIN
public/img/close.png
Normal file
BIN
public/img/close.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 615 B |
Loading…
Add table
Add a link
Reference in a new issue