-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ddd1c2a
commit 1463b90
Showing
11 changed files
with
161 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"extends": [ | ||
"development" | ||
], | ||
"hints": { | ||
"apple-touch-icons": "off" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
.profile-list { | ||
box-shadow: -3px -3px 10px 5px rgba(255, 255, 255, 0.185), | ||
5px 5px 10px 5px rgba(216, 216, 216, 0.082); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,14 @@ | ||
import Image from 'next/image' | ||
//import { Heart } from './Heart' | ||
import ProfileImage from './ProfileImage' | ||
import QR from './QR' | ||
import './Profile.css' | ||
|
||
export function Profile() { | ||
return ( | ||
<div className='flex flex-col items-center justify-center space-y-4 font-Nunito w-96'> | ||
<div className='rounded-full bg-gradient-to-br from-[#94e5d2] to-[#84E3F6] p-1 h-60 w-60 relative'> | ||
<div className='rounded-full h-full w-full bg-white overflow-hidden'> | ||
<Image | ||
src='/walnuts.jpg' | ||
alt='Sample Image' | ||
width={500} | ||
height={500} | ||
style={{ objectFit: 'contain' }} | ||
className='rounded-full h-full w-full' | ||
/> | ||
</div> | ||
<div className='h-60 w-60 relative'> | ||
<ProfileImage /> | ||
<div className='absolute bottom-1 right-0'> | ||
<QR /> | ||
</div> | ||
|
@@ -25,45 +18,45 @@ export function Profile() { | |
<p className='text-black font-extrabold text-4xl'>Walnuts</p> | ||
{/* <Heart /> */} | ||
<div className='space-y-2 mt-6'> | ||
{/*<Icon src='/icons/sell_FILL0_wght400_GRAD0_opsz24.svg' alt='Name' text='Ryota Tawara' />*/} | ||
<Icon | ||
{/*<ProfileList src='/icons/sell_FILL0_wght400_GRAD0_opsz24.svg' alt='Name' text='Ryota Tawara' />*/} | ||
<ProfileList | ||
src='/icons/twitter-x-line.svg' | ||
alt='X(Twitter)' | ||
text='@walnuts1018' | ||
link='https://twitter.com/walnuts1018' | ||
/> | ||
<Icon | ||
<ProfileList | ||
src='/icons/github-fill.svg' | ||
alt='GitHub' | ||
text='walnuts1018' | ||
link='https://github.com/walnuts1018' | ||
/> | ||
<Icon | ||
<ProfileList | ||
src='/icons/instagram-line.svg' | ||
alt='Instagram' | ||
text='@walnuts_1018' | ||
link='https://www.instagram.com/walnuts_1018/' | ||
/> | ||
<Icon | ||
<ProfileList | ||
src='/icons/mail_FILL0_wght400_GRAD0_opsz24.svg' | ||
alt='Mail' | ||
text='[email protected]' | ||
link='mailto:[email protected]' | ||
fontSize='text-2xl' | ||
/> | ||
<Icon | ||
<ProfileList | ||
src='/icons/KMClogo_trans.svg' | ||
alt='KMC' | ||
text='KMC 46th Chairman' | ||
link='https://kmc.gr.jp' | ||
/> | ||
<Icon | ||
<ProfileList | ||
src='/icons/school_FILL0_wght400_GRAD0_opsz24.svg' | ||
alt='School' | ||
text='Kyoto Univ. / B2' | ||
link='https://www.s-ee.t.kyoto-u.ac.jp/ja' | ||
/> | ||
<Icon | ||
<ProfileList | ||
src='/icons/favorite_FILL0_wght400_GRAD0_opsz24.svg' | ||
alt='School' | ||
text='Kubernetes / Proxmox VE / Golang' | ||
|
@@ -75,7 +68,7 @@ export function Profile() { | |
) | ||
} | ||
|
||
function Icon({ | ||
function ProfileList({ | ||
src, | ||
alt, | ||
text, | ||
|
@@ -89,27 +82,25 @@ function Icon({ | |
fontSize?: string | ||
}) { | ||
return ( | ||
<div | ||
className={`flex rounded-full px-3 py-1 transition-all ${ | ||
link !== undefined ? 'hover:bg-gray-100 hover:shadow-md hover:border-gray-500' : '' | ||
<a | ||
target='_blank' | ||
rel='noopener noreferrer' | ||
className={`flex space-x-3 text-[#7f7f7f] font-bold items-center ${fontSize} w-full outline-none flex rounded-full px-6 py-1 profile-list ${ | ||
link !== undefined | ||
? 'hover:bg-gray-100 hover:shadow-md hover:border-gray-500 focus:bg-gray-100 focus:shadow-md focus:border-gray-500' | ||
: '' | ||
}`} | ||
href={link} | ||
> | ||
<a | ||
target='_blank' | ||
rel='noopener noreferrer' | ||
className={`flex space-x-3 text-[#7f7f7f] font-bold items-center ${fontSize}`} | ||
href={link} | ||
> | ||
<Image | ||
src={src} | ||
alt={alt} | ||
width={40} | ||
height={40} | ||
style={{ objectFit: 'contain' }} | ||
className='min-w-[40px] max-w-[40px]' | ||
/> | ||
<p>{text}</p> | ||
</a> | ||
</div> | ||
<Image | ||
src={src} | ||
alt={alt} | ||
width={40} | ||
height={40} | ||
style={{ objectFit: 'contain' }} | ||
className='min-w-[40px] max-w-[40px]' | ||
/> | ||
<p>{text}</p> | ||
</a> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
.profile-image { | ||
box-shadow: 15px 15px 40px 5px rgb(15, 14, 31), -5px -5px 30px 5px rgba(254, 255, 234, 0.349); | ||
} | ||
|
||
.profile-image-inline { | ||
box-shadow: inset 5px 5px 10px 1px rgba(117, 117, 117, 0.479), | ||
inset -5px -5px 10px 5px rgb(233, 233, 233); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
'use client' | ||
import CloseIcon from '@mui/icons-material/Close' | ||
import { clearAllBodyScrollLocks, disableBodyScroll, enableBodyScroll } from 'body-scroll-lock' | ||
import Image from 'next/image' | ||
import { useState, useEffect } from 'react' | ||
import Modal from 'react-modal' | ||
import './ProfileImage.css' | ||
|
||
export default function ProfileImage() { | ||
const [isExpanded, setIsExpanded] = useState(false) | ||
|
||
useEffect(() => { | ||
if (isExpanded) { | ||
disableBodyScroll(document.body) | ||
} else { | ||
enableBodyScroll(document.body) | ||
} | ||
return () => { | ||
clearAllBodyScrollLocks() | ||
} | ||
}, [isExpanded]) | ||
|
||
return ( | ||
<> | ||
<div className='rounded-full bg-gradient-to-br from-[#94e5d2] to-[#84E3F6] p-1 h-full w-full'> | ||
<div className='rounded-full h-full w-full bg-white overflow-hidden'> | ||
<Image | ||
src='/walnuts.jpg' | ||
alt='walnuts icon' | ||
width={500} | ||
height={500} | ||
className='rounded-full h-full w-full cursor-pointer object-contain' | ||
onClick={() => { | ||
setIsExpanded(true) | ||
}} | ||
/> | ||
</div> | ||
</div> | ||
{isExpanded ? ( | ||
<Modal | ||
isOpen={isExpanded} | ||
onRequestClose={() => { | ||
setIsExpanded(false) | ||
}} | ||
className='fixed h-[100svh] w-screen bg-black bg-opacity-50 flex items-center justify-center overflow-hidden' | ||
overlayClassName='fixed inset-0 bg-black bg-opacity-70 z-10' | ||
> | ||
<div | ||
className='fixed h-full w-full -z-10' | ||
onClick={() => { | ||
setIsExpanded(false) | ||
}} | ||
></div> | ||
<div className='rounded-full relative profile-image'> | ||
<Image | ||
src='/walnuts.jpg' | ||
alt='walnuts icon' | ||
width={500} | ||
height={500} | ||
className=' h-full w-full object-contain rounded-full ' | ||
/> | ||
</div> | ||
<button | ||
title='close image expand' | ||
className='absolute top-4 right-4 text-4xl' | ||
onClick={() => setIsExpanded(false)} | ||
> | ||
<CloseIcon fontSize='inherit' className='text-white' /> | ||
</button> | ||
</Modal> | ||
) : ( | ||
<></> | ||
)} | ||
</> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
.container { | ||
box-shadow: 15px 15px 40px 5px rgb(15, 14, 31), -5px -5px 30px 5px rgba(254, 255, 234, 0.349); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters