4 Commits

Author SHA1 Message Date
amantahiliani
f50ef52fa2 Updated Resume May 2025 2025-05-25 18:06:41 -04:00
amantahiliani
9d811e1e74 Section Glow and better layout 2025-05-11 22:25:39 -04:00
amantahiliani
5aa11f3934 Made Portfolio as the default 2025-05-11 22:07:02 -04:00
amantahiliani
5501c586a3 Smoother animations 2025-05-11 22:03:56 -04:00
8 changed files with 61 additions and 158 deletions

View File

@@ -1,14 +1,13 @@
.App {
text-align: center;
background-color: var(--background-primary);
position: absolute;
top: 0px;
right: 0px;
left: 0px;
background-color: black;
min-height: 100vh;
width: 100%;
font-family: "Gill Sans", "Gill Sans MT", Calibri, "Trebuchet MS", sans-serif;
color: var(--text-primary);
color: azure;
overflow-x: hidden;
scroll-behavior: smooth;
position: relative;
}
html {
@@ -17,8 +16,16 @@ html {
section {
opacity: 0;
transform: translateY(20px);
transform: translate3d(0, 20px, 0);
transition: opacity 0.6s ease-out, transform 0.6s ease-out;
will-change: opacity, transform;
/* min-height: 100vh; */
display: flex;
flex-direction: column;
justify-content: center;
padding: 60px 0;
position: relative;
overflow: hidden;
}
section.visible {
@@ -38,18 +45,18 @@ section.visible {
}
.App-header {
background-color: var(--background-primary);
background-color: black;
min-height: 100vh;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
font-size: calc(10px + 2vmin);
color: var(--text-primary);
color: white;
}
.App-link {
color: var(--accent-primary);
color: #61dafb;
}
@keyframes App-logo-spin {
@@ -63,23 +70,21 @@ section.visible {
.About {
width: 100%;
position: absolute;
top: 120px;
bottom: 0px;
left: 0px;
right: 0px;
padding: 40px 0;
margin-top: 60px;
}
hr {
width: 70%;
margin-left: 15% !important;
margin-right: 15% !important;
border: 10px solid var(--hr-color);
border: 10px solid aquamarine;
}
.publications, .Experience, .DevTools, .Contact {
margin-top: 100px;
padding: 40px 0;
margin: 0;
padding: 60px 0;
width: 100%;
}
.section-title {
@@ -90,6 +95,10 @@ hr {
section:hover .section-title {
transform: translateY(-5px);
text-shadow: 0 0 8px rgba(250, 128, 114, 0.6), /* Salmon color glow */
0 0 15px rgba(250, 128, 114, 0.4),
0 0 20px rgba(250, 128, 114, 0.2);
transition: transform 0.4s ease-out, text-shadow 0.4s ease-out;
}
.slick-dots button:before {

View File

@@ -5,9 +5,6 @@ import {
Routes,
useLocation,
} from "react-router-dom";
import { ThemeProvider, useTheme } from './context/ThemeContext';
import './css/theme.css';
import ThemeToggle from './components/ThemeToggle';
import { CSSTransition, TransitionGroup } from "react-transition-group";
import "./App.css";
import "./css/home.css";
@@ -20,18 +17,26 @@ import DevToolsComponent from "./components/devtools";
import SocialMedia from "./components/SocialMedia";
function Portfolio() {
const { isDarkMode } = useTheme();
useEffect(() => {
const observer = new IntersectionObserver((entries) => {
entries.forEach(entry => {
if (entry.isIntersecting) {
const delay = parseInt(entry.target.dataset.delay) || 0;
setTimeout(() => {
requestAnimationFrame(() => {
entry.target.classList.add('visible');
});
}, delay);
}
});
}, { threshold: 0.1 });
}, {
threshold: 0.15,
rootMargin: '50px 0px -100px 0px'
});
document.querySelectorAll('section').forEach((section) => {
document.querySelectorAll('section').forEach((section, index) => {
// Add staggered delay to each section
section.dataset.delay = index * 100;
observer.observe(section);
});
@@ -41,7 +46,6 @@ function Portfolio() {
return (
<div className="App">
<meta name="Aman Tahiliani's Portfolio"></meta>
<ThemeToggle />
<nav>
<Header />
</nav>
@@ -50,13 +54,6 @@ function Portfolio() {
<section>
<About className="About" id="About" />
</section>
<section className="publications" id="Publications">
<h2 className="section-title" style={{ color: "salmon", fontSize: "50px" }}>
<b>Publications</b>
</h2>
<SimpleSlider />
</section>
<section className="Experience" id="Experience">
<h2 className="section-title" style={{ color: "salmon", fontSize: "50px" }}>
<b>Experience</b>
@@ -69,6 +66,12 @@ function Portfolio() {
</h2>
<DevToolsComponent />
</section>
<section className="publications" id="Publications">
<h2 className="section-title" style={{ color: "salmon", fontSize: "50px" }}>
<b>Publications</b>
</h2>
<SimpleSlider />
</section>
<section className="Contact" id="Contact">
<h2 className="section-title" style={{ color: "cyan", fontSize: "50px" }}>
<b>Social Links</b>
@@ -94,11 +97,8 @@ function Books() {
}
function Home() {
const { isDarkMode } = useTheme();
return (
<div className="home">
<ThemeToggle />
<div className="content">
<div className="intro">
<h1>Welcome to Aman Tahiliani's Space</h1>
@@ -130,17 +130,15 @@ function Home() {
function App() {
return (
<ThemeProvider>
<Router>
<div>
<Routes>
<Route path="/" element={<Home />} />
<Route path="/" element={<Portfolio />} />
<Route path="/portfolio" element={<Portfolio />} />
<Route path="/reviews" element={<Books />} />
</Routes>
</div>
</Router>
</ThemeProvider>
);
}
export default App;

View File

@@ -1,19 +0,0 @@
import React from 'react';
import { useTheme } from '../context/ThemeContext';
import '../css/ThemeToggle.css';
const ThemeToggle = () => {
const { isDarkMode, toggleTheme } = useTheme();
return (
<button
className="theme-toggle"
onClick={toggleTheme}
aria-label="Toggle theme"
>
{isDarkMode ? '☀️' : '🌙'}
</button>
);
};
export default ThemeToggle;

View File

@@ -1,26 +0,0 @@
import React, { createContext, useState, useContext } from 'react';
const ThemeContext = createContext();
export const ThemeProvider = ({ children }) => {
const [isDarkMode, setIsDarkMode] = useState(true);
const toggleTheme = () => {
setIsDarkMode(!isDarkMode);
document.documentElement.setAttribute('data-theme', !isDarkMode ? 'dark' : 'light');
};
return (
<ThemeContext.Provider value={{ isDarkMode, toggleTheme }}>
{children}
</ThemeContext.Provider>
);
};
export const useTheme = () => {
const context = useContext(ThemeContext);
if (context === undefined) {
throw new Error('useTheme must be used within a ThemeProvider');
}
return context;
};

View File

@@ -1,30 +0,0 @@
.theme-toggle {
position: fixed;
top: 20px;
right: 20px;
z-index: 1000;
background: none;
border: 2px solid var(--accent-primary);
color: var(--text-primary);
width: 40px;
height: 40px;
border-radius: 50%;
cursor: pointer;
font-size: 20px;
display: flex;
align-items: center;
justify-content: center;
transition: all 0.3s ease;
padding: 0;
}
.theme-toggle:hover {
transform: scale(1.1);
background-color: var(--accent-primary);
color: var(--background-primary);
}
.theme-toggle:focus {
outline: none;
box-shadow: 0 0 0 2px var(--accent-secondary);
}

View File

@@ -3,7 +3,7 @@
flex-direction: column;
justify-content: space-between;
min-height: 100vh;
background-color: var(--background-primary);
background-color: #f0f0f0;
}
.content {
@@ -22,13 +22,13 @@
.intro h1 {
font-size: 3em;
color: var(--text-primary);
color: #333;
animation: slideIn 1s ease-in-out;
}
.intro p {
font-size: 1.5em;
color: var(--text-secondary);
color: #666;
animation: slideIn 1s ease-in-out;
}
@@ -45,7 +45,7 @@
.intro nav ul li a {
text-decoration: none;
color: var(--link-color);
color: #3498db;
font-size: 1.2em;
}
@@ -97,6 +97,7 @@
.footer {
width: 100%;
padding: 20px 0;
background-color: var(--background-primary);
background-color: #f0f0f0;
text-align: center;
}

View File

@@ -1,30 +0,0 @@
:root[data-theme='light'] {
--background-primary: #f0f0f0;
--background-secondary: #ffffff;
--text-primary: #333333;
--text-secondary: #666666;
--accent-primary: #3498db;
--accent-secondary: #2980b9;
--border-color: #dddddd;
--section-title: #e74c3c;
--link-color: #3498db;
--hr-color: #2ecc71;
}
:root[data-theme='dark'] {
--background-primary: #000000;
--background-secondary: #1a1a1a;
--text-primary: #ffffff;
--text-secondary: #cccccc;
--accent-primary: #61dafb;
--accent-secondary: #4fa3d1;
--border-color: #333333;
--section-title: #ff6b6b;
--link-color: #61dafb;
--hr-color: #00ffbf;
}
/* Theme transition */
* {
transition: background-color 0.3s ease, color 0.3s ease;
}

Binary file not shown.