Skip to content

Commit

Permalink
feat: add profile pictures
Browse files Browse the repository at this point in the history
also already add other pictures to the assets
  • Loading branch information
maybeanerd committed Sep 9, 2023
1 parent 1f1df61 commit 1f1606b
Show file tree
Hide file tree
Showing 17 changed files with 53 additions and 19 deletions.
Binary file added assets/images/profile/julian/pp.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/profile/marc/feral_interactive.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/profile/marc/pp.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/profile/marc/rove.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/profile/marc/unity.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/profile/sebastian/botblock.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/profile/sebastian/easyshare.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/profile/sebastian/flint.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/profile/sebastian/iu.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/profile/sebastian/magibot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/profile/sebastian/pp.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 11 additions & 7 deletions components/profile/person.vue
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
<template>
<div class="mb-2">
<h1 class="flex-shrink-0 text-3xl">
{{ props.person.name.first }} {{ props.person.name.last }}
</h1>

<p class="text-base mb-1">
{{ props.person.shortText }}
</p>
<div class="flex space-x-4 md:space-x-8 mb-2 md:mb-4">
<ProfilePicture :person="props.person" class="flex-shrink-0" />
<div>
<h1 class="flex-shrink-0 text-3xl">
{{ props.person.name.first }} {{ props.person.name.last }}
</h1>
<p class="text-base">
{{ props.person.shortText }}
</p>
</div>
</div>
<div>
<LocationTag
v-if="props.person.meta.basedIn"
Expand Down
16 changes: 16 additions & 0 deletions components/profile/picture.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<template>
<NuxtPicture
v-if="props.person.image"
sizes="sm:64px md:96px lg:128px"
class="[&>img]:rounded-full [&>img]:border-white [&>img]:border-[1px]"
:src="`/profile/${props.person.name.first.toLowerCase()}/${
props.person.image.path
}`"
/>
</template>

<script setup lang="ts">
import type { Profile } from '~/server/profile.types';
const props = defineProps<{ person: Profile['person'] }>();
</script>
4 changes: 4 additions & 0 deletions nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,8 @@ export default defineNuxtConfig({
buildDate: new Date().toISOString(),
},
},
image: {
format: ['avif', 'webp', 'png'],
dir: 'assets/images',
},
});
14 changes: 12 additions & 2 deletions server/profile.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,22 @@ export type SocialInfo =
email: string;
};

export type Image =
| {
isURL: false;
path: string;
}
| {
isURL: true;
path: URL;
};

type Person = {
name: {
first: string;
last: 'Di Luzio'; // we could support other spellings of the name later on
};
image?: { isURL: boolean; path: string };
image?: Image;
shortText?: string;
socials: Array<SocialInfo>;
meta: {
Expand All @@ -54,7 +64,7 @@ export enum EducationType {
export type Project = {
title: string;
role: string;
image?: string;
image?: Image;
description: string;
highlights?: Array<string>;
url?: string;
Expand Down
10 changes: 5 additions & 5 deletions server/profiles/marc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export const marc: Profile = {
title: 'Unity',
role: 'Lead Software Engineer',
url: 'https://unity.com/',
image: 'unity.png',
image: { isURL: false, path: 'unity.png' },
description:
'Leading a tools team in Release Engineering, working on a variety of projects focusing on better release workflows, bug tracking and quality barriers.',
timeframe: {
Expand All @@ -57,7 +57,7 @@ export const marc: Profile = {
title: 'Unity',
role: 'Senior Software Engineer',
url: 'https://unity.com/',
image: 'unity.png',
image: { isURL: false, path: 'unity.png' },
description:
'Worked in Sustained Engineering, focusing on Linux bugs and infrastructure.',
timeframe: {
Expand All @@ -73,7 +73,7 @@ export const marc: Profile = {
title: 'Rove',
role: 'Developer and Designer',
url: 'https://github.com/mdiluz/rove',
image: 'rove.png',
image: { isURL: false, path: 'rove.png' },
description:
'An asynchronous nomadic game about exploring as part of a loose community.',
timeframe: {
Expand Down Expand Up @@ -105,7 +105,7 @@ export const marc: Profile = {
title: 'Feral Interactive',
role: 'Linux Group lead',
url: 'https://www.feralinteractive.com/en/',
image: 'feral_interactive.png',
image: { isURL: false, path: 'feral_interactive.png' },
description:
'Lead the Linux platform development while porting many AAA games such as XCOM2, Mad Max and HITMAN',
timeframe: {
Expand All @@ -125,7 +125,7 @@ export const marc: Profile = {
title: 'Feral Interactive',
role: 'Software Developer',
url: 'https://www.feralinteractive.com/en/',
image: 'feral_interactive.png',
image: { isURL: false, path: 'feral_interactive.png' },
description:
'Worked on Mac and Linux ports for a variety of games including ROME: Total War, Tomb Raider and XCOM',
timeframe: {
Expand Down
10 changes: 5 additions & 5 deletions server/profiles/sebastian.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ export const sebastian: Profile = {
title: 'IU International University',
role: 'Full Stack Developer',
url: 'https://www.iu.org',
image: 'iu.png',
image: { isURL: false, path: 'iu.png' },
timeframe: {
start: new Date(2021, 9),
end: 'current',
Expand Down Expand Up @@ -85,7 +85,7 @@ export const sebastian: Profile = {
title: 'Magibot',
role: 'Creator and maintainer',
url: 'https://bots.ondiscord.xyz/bots/384820232583249921',
image: 'magibot.png',
image: { isURL: false, path: 'magibot.png' },
timeframe: {
start: new Date(2017, 6),
end: 'current',
Expand All @@ -100,7 +100,7 @@ export const sebastian: Profile = {
title: 'BLAPI - the BotListAPI',
role: 'Creator and maintainer',
url: 'https://github.com/botblock/BLAPI',
image: 'botblock.png',
image: { isURL: false, path: 'botblock.png' },
timeframe: {
start: new Date(2018, 7),
end: 'current',
Expand All @@ -119,7 +119,7 @@ export const sebastian: Profile = {
title: 'flint.gg',
role: 'Co-Founder and CTO',
url: 'https://flint.gg',
image: 'flint.png',
image: { isURL: false, path: 'flint.png' },
timeframe: {
start: new Date(2019, 7),
end: new Date(2021, 6),
Expand Down Expand Up @@ -148,7 +148,7 @@ export const sebastian: Profile = {
title: 'easyshare',
role: 'Creator and maintainer',
url: 'https://github.com/flint-gg/easyshare',
image: 'easyshare.png',
image: { isURL: false, path: 'easyshare.png' },
timeframe: {
start: new Date(2020, 5),
end: new Date(2021, 6),
Expand Down

0 comments on commit 1f1606b

Please sign in to comment.