Skip to content

Commit

Permalink
Mobile version updates, media queries and card formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
ValKozz committed Apr 2, 2024
1 parent 8060b9e commit 43a5ba8
Show file tree
Hide file tree
Showing 12 changed files with 283 additions and 112 deletions.
113 changes: 72 additions & 41 deletions src/App.css
Original file line number Diff line number Diff line change
@@ -1,18 +1,77 @@
#root {
/* max-width: 1280px; */
margin: 0 auto;
text-align: center;
display: flex;
@media (min-width: 481px) {
/* This stays here or we get borders when moving troughs */
.light {
background: radial-gradient(
circle at calc(var(--x) * 1px) calc(var(--y) * 1px),
hsl(0 0% 80% / 0.2),
transparent 10%
);
background-attachment: fixed;
}

#root {
margin: 0 auto;
text-align: center;
display: flex;
justify-items: center;
}
.main {
background-color: var(--dark);
height: 100vh;
width: 100%;
}

.half {
padding-left: 5%;
padding-right: 5%;
background-color: var(--dark);
display: flex;
justify-content: center;
align-items: center;
text-align: center;
width: 40%;
height: 100%;
float: left;
}

.sectionTitle {
display: flex;
align-items: center;
text-align: center;
justify-content: center;
font-size: 4.8rem;
line-height: 1.1;
}
}

/* This stays here or we get borders when moving troughs */
.light {
background: radial-gradient(
circle at calc(var(--x) * 1px) calc(var(--y) * 1px),
hsl(0 0% 40% / 0.2),
transparent 10%
);
background-attachment: fixed;
@media (max-width: 481px) {
.main {
background-color: var(--dark);
height: 100vh;
width: 100vw;
}

.half {
padding-left: 5%;
padding-right: 5%;
background-color: var(--dark);
display: flex;
justify-content: center;
align-items: center;
text-align: center;
width: 90%;
height: 50%;
float: left;
}

.sectionTitle {
display: flex;
align-items: center;
text-align: center;
justify-content: center;
font-size: 2.8rem;
line-height: 1.1;
}
}

#scroll-container {
Expand All @@ -23,21 +82,6 @@
overflow-x: hidden;
}

.main {
background-color: var(--dark);
height: 100vh;
width: 100%;
}

.sectionTitle {
display: flex;
align-items: center;
text-align: center;
justify-content: center;
font-size: 4.8rem;
line-height: 1.1;
}

#page-title:hover {
filter: drop-shadow(0 0 10em #646cffaa);
}
Expand All @@ -54,16 +98,3 @@
display: flex;
text-wrap: wrap;
}

.half {
padding-left: 5%;
padding-right: 5%;
background-color: var(--dark);
display: flex;
justify-content: center;
align-items: center;
text-align: center;
width: 40%;
height: 100%;
float: left;
}
1 change: 1 addition & 0 deletions src/assets/react.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
51 changes: 33 additions & 18 deletions src/components/Contact/contact.css
Original file line number Diff line number Diff line change
Expand Up @@ -15,32 +15,47 @@
flex-direction: column;
}

.input-field {
transition: all 0.3s ease-in-out;
outline: 0;
border-width: 0 0 2px;
border-color: var(--med-light);
padding-top: 2rem;
padding-bottom: 2rem;
font-size: 1rem;
line-height: 1.2rem;
width: 40%;
background-color: var(--med-dark);
color: var(--med-light);
@media (min-width: 481px) {
.input-field {
transition: all 0.3s ease-in-out;
outline: 0;
border-width: 0 0 2px;
border-color: var(--med-light);
padding-top: 2rem;
padding-bottom: 2rem;
font-size: 1rem;
line-height: 1.2rem;
width: 40%;
background-color: var(--med-dark);
color: var(--med-light);
}
}

@media (max-width: 480px) {
.input-field {
transition: all 0.3s ease-in-out;
outline: 0;
border-width: 0 0 2px;
border-color: var(--med-light);
padding-top: 2rem;
padding-bottom: 2rem;
font-size: 1rem;
line-height: 1.2rem;
width: 80%;
background-color: var(--med-dark);
color: var(--med-light);
}
}

/* Maybe not */
.input-field:hover {
.input-field:hover,
.input-field:focus,
.input-field:active {
color: var(--dark);
background-color: var(--med-light);
filter: drop-shadow(0 0 10em #646cffaa);
}

.input-field:focus {
filter: drop-shadow(0 0 10em #646cffaa);
color: var(--light);
}

#contact-form {
height: 50%;
width: 100vw;
Expand Down
62 changes: 60 additions & 2 deletions src/components/Footer/footer.css
Original file line number Diff line number Diff line change
@@ -1,10 +1,68 @@
@media (max-width: 480px) {
#end-comparment {
width: 100vw;
}

#footer {
width: 100%;
height: 100%;
display: flex;
justify-content: center;
}

#icon-list {
display: flex;
flex-direction: row;
list-style: none;
}

.icon {
fill: var(--med-light);
}

.icon:hover {
fill: var(--light);
filter: drop-shadow(0 0 10em #646cffaa);
}
}

@media (min-width: 481px) {
#end-comparment {
margin-top: 10%;
width: 100vw;
height: 20vh;
}

#footer {
width: 100%;
height: 100%;
display: flex;
justify-content: center;
}

#icon-list {
display: flex;
flex-direction: row;
list-style: none;
}

.icon {
fill: var(--med-light);
}

.icon:hover {
fill: var(--light);
filter: drop-shadow(0 0 10em #646cffaa);
}
}

#end-comparment {
margin-top: 15%;
width: 100vw;
height: 20vh;
height: 10vh;
}

#footer {
margin-top: 5%;
clear: both;
width: 100%;
height: 100%;
Expand Down
2 changes: 1 addition & 1 deletion src/components/Projects/ProjectCards/Card.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export default function Card({ title, text, img_source, link }) {
<a href={link}>
<div className="card">
<div className="card-title">
<h1 id="card-title">{title}</h1>
<h1 id="card-h1">{title}</h1>
</div>
<div className="card-content">
{img_source ? <img className="card-image" src={img_source} /> : ""}
Expand Down
1 change: 1 addition & 0 deletions src/components/Projects/ProjectCards/ProjectCards.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ export default function ProjectCards() {
title={project.name}
link={project.link}
text={project.desc}
img_source={project.img_source}
/>
);
})}
Expand Down
16 changes: 9 additions & 7 deletions src/components/Projects/ProjectCards/card.css
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,20 @@
box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2);
transition: 0.3s;
background-color: white;
width: 5rem;
padding: 1rem 2rem;
margin: 2rem;
display: flex;
align-content: center;
justify-content: center;
flex-direction: column;
min-width: 15rem;
height: 26rem;
}

#card-title {
#card-h1 {
font-size: 2rem;
padding: 1rem;
display: flex;
align-items: center;
}

.card-title {
Expand All @@ -30,21 +31,22 @@
font-size: 1rem;
}

h1.card-title .card-content {
h1.card-title,
.card-content {
display: flex;
align-items: center;
flex-direction: column;
overflow-y: scroll;
overflow-x: hidden;
font-size: 1rem;
object-fit: contain;
word-break: break-all;
white-space: pre-wrap;
overflow: scroll;
overflow-y: scroll;
}

.card-image {
padding: 1rem;
width: 200px;
width: 48px;
object-fit: cover;
display: flex;
align-items: center;
Expand Down
15 changes: 10 additions & 5 deletions src/components/Projects/ProjectCards/data.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,31 @@
{
"name": "Personal Website",
"link": "https://github.com/ValKozz/2Way-Morse",
"desc": " My very own personal website and first I've ever built using React/Vite."
"desc": " My very own personal website and first I've ever built using React/Vite.",
"img_source": "src/assets/react.svg"
},
{
"name": "2Way-Morse",
"link": "https://github.com/ValKozz/2Way-Morse",
"desc": " Console based Morse code 2-way Translator, fearing audio playback of result using pyttsx3(Text to speech) and pygame(Mixer audio engine) and numpy"
"desc": " Console based Morse code 2-way Translator, fearing audio playback of result using pyttsx3(Text to speech) and pygame(Mixer audio engine) and numpy",
"img_source": "https://s3.dualstack.us-east-2.amazonaws.com/pythondotorg-assets/media/files/python-logo-only.svg"
},
{
"name": "CondPDA",
"link": "https://github.com/ValKozz/CondPDA",
"desc": " Convert PDF files to mp3 Audio Books through the command line terminal. Uses gTTa and tika.\n"
"desc": " Convert PDF files to mp3 Audio Books through the command line terminal. Uses gTTa and tika.\n",
"img_source": "https://s3.dualstack.us-east-2.amazonaws.com/pythondotorg-assets/media/files/python-logo-only.svg"
},
{
"name": "Cows_and_Bulls",
"link": "https://github.com/ValKozz/Cows_and_Bulls",
"desc": " The Cows and Bulls guessing game, with the abilitty to play againts the computer, where it tries to guess your number. Beware, it has a 100% guess rate."
"desc": " The Cows and Bulls guessing game, with the abilitty to play againts the computer, where it tries to guess your number. Beware, it has a 100% guess rate.",
"img_source": "https://s3.dualstack.us-east-2.amazonaws.com/pythondotorg-assets/media/files/python-logo-only.svg"
},
{
"name": "Watermarker",
"link": "https://github.com/ValKozz/Watermarker",
"desc": " A simple Custom Tkinter program to add watermarks to images. Uses the PIL(Python Pillow) library to provide some basic image editing operations. Currently, supports JPEG and PNG."
"desc": " A simple Custom Tkinter program to add watermarks to images. Uses the PIL(Python Pillow) library to provide some basic image editing operations. Currently, supports JPEG and PNG.",
"img_source": "https://s3.dualstack.us-east-2.amazonaws.com/pythondotorg-assets/media/files/python-logo-only.svg"
}
]
2 changes: 1 addition & 1 deletion src/components/Projects/Projects.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export default function Projects() {
return (
<section className="scroller light">
<div className="main light">
<div className="main">
<div className="main projects-container">
<div className="half light animated">
<div id="canvas3d-container" className="light">
<CanvasThreeFiber id="canvas3d" />
Expand Down
Loading

0 comments on commit 43a5ba8

Please sign in to comment.