Skip to content

Commit

Permalink
Merge branch 'main' into RateUsPage
Browse files Browse the repository at this point in the history
  • Loading branch information
sailaja-adapa authored Aug 2, 2024
2 parents b67ffd7 + d883f80 commit 18fc359
Show file tree
Hide file tree
Showing 10 changed files with 581 additions and 12 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/auto-label-issues.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Auto Label Issues
on:
issues:
types: [opened, edited]

jobs:
label_issues:
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v6
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
const issue = context.payload.issue;
const title = issue.title.toLowerCase();
const body = issue.body.toLowerCase();
const labels = [];
if (title.includes('gssoc') || body.includes('gssoc')) {
labels.push('GSSoC');
}
if (title.includes('enhancement') || body.includes('enhancement')) {
labels.push('Enhancement');
}
if (title.includes('bug') || body.includes('bug')) {
labels.push('Bug');
}
if (title.includes('documentation') || body.includes('documentation')) {
labels.push('Documentation');
}
if (labels.length > 0) {
github.rest.issues.addLabels({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.name,
labels: labels
});
}
43 changes: 43 additions & 0 deletions .github/workflows/auto-label-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Auto Label PRs
on:
pull_request:
types: [opened, edited, synchronize]

jobs:
label_prs:
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v6
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
const pr = context.payload.pull_request;
const title = pr.title.toLowerCase();
const body = pr.body ? pr.body.toLowerCase() : '';
const labels = [];
if (title.includes('gssoc') || body.includes('gssoc')) {
labels.push('GSSoC');
}
if (title.includes('enhancement') || body.includes('enhancement')) {
labels.push('Enhancement');
}
if (title.includes('bug') || body.includes('bug')) {
labels.push('Bug');
}
if (title.includes('documentation') || body.includes('documentation')) {
labels.push('Documentation');
}
if (labels.length > 0) {
github.rest.issues.addLabels({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.name,
labels: labels
});
}
6 changes: 5 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
},
"dependencies": {
"@emailjs/browser": "^4.3.3",
"@fortawesome/free-solid-svg-icons": "^6.5.2",
"@fortawesome/react-fontawesome": "^0.2.2",
"@hookform/resolvers": "^3.6.0",
"@react-three/drei": "^9.106.0",
"@react-three/fiber": "^8.16.6",
"@tsparticles/all": "^3.4.0",
Expand All @@ -24,7 +27,8 @@
"react-router-dom": "^6.23.1",
"react-scroll": "^1.9.0",
"three": "^0.164.1",
"typed.js": "^2.1.0"
"typed.js": "^2.1.0",
"zod": "^3.23.8"
},
"devDependencies": {
"@types/react": "^18.2.66",
Expand Down
33 changes: 30 additions & 3 deletions src/components/Footer/Footer.jsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,34 @@
import React from 'react';
import React, { useEffect } from 'react';
import img from '../../assets/logo_white.png';

function Footer() {
const currentYear = new Date().getFullYear();

useEffect(() => {
const script = document.createElement('script');
script.type = 'text/javascript';
script.src = 'https://translate.google.com/translate_a/element.js?cb=loadGoogleTranslate';
script.onerror = function () {
console.error('Error loading Google Translate script');
};
document.body.appendChild(script);

window.loadGoogleTranslate = function () {
new window.google.translate.TranslateElement(
{
pageLanguage: 'en',
includedLanguages: 'en,hi,pa,sa,mr,ur,bn,es,fr,de,it',
layout: window.google.translate.TranslateElement.InlineLayout.SIMPLE,
},
'google_element'
);
};

return () => {
document.body.removeChild(script);
};
}, []);

return (
<div className="container">
<footer className="d-flex flex-wrap justify-content-between align-items-center py-3 my-4 border-top">
Expand All @@ -12,10 +38,10 @@ function Footer() {
<p className="col-md-4 mb-0 text-light text-center">©️ {currentYear} CosmoXplore India, Inc. All Rights Reserved</p>
<div className="col-md-4 d-flex justify-content-center">
<a href="https://github.com/PranavBarthwal" className="text-light me-4">
<i className="fab fa-github"></i>
<i className="fab fa-github"></i>
</a>
<a href="https://x.com/pranavbarthwal_" className="text-light me-4">
<i className="fab fa-twitter"></i>
<i className="fab fa-x-twitter"></i>
</a>
<a href="https://linktr.ee/PranavBarthwal" className="text-light me-4">
<i className="fab fa-instagram"></i>
Expand All @@ -24,6 +50,7 @@ function Footer() {
<i className="fab fa-linkedin-in"></i>
</a>
</div>
<div id="google_element" className="col-12 text-center mt-3"></div>
</footer>
</div>
);
Expand Down
7 changes: 3 additions & 4 deletions src/components/Hero/Hero.jsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import React, { useEffect } from 'react';
import Typed from 'typed.js';
import Earth from '../3D_Models/Earth/Earth.jsx'
import Styles from './Hero.module.css'
import Earth from '../3D_Models/Earth/Earth.jsx';

function Hero() {
useEffect(() => {
Expand All @@ -22,7 +21,7 @@ function Hero() {
return (
<div className="container col-xxl-9 px-3 py-5 override-display">
<div className="row flex-lg-row-reverse align-items-center g-5 py-5">
<div className="col-10 col-sm-8 col-lg-6 flex justify-center " id={Styles['earth']}>
<div className="col-10 col-sm-8 col-lg-6 flex justify-center" id="earth">
<Earth />
</div>
<div className="col-lg-6">
Expand All @@ -39,4 +38,4 @@ function Hero() {
);
}

export default Hero;
export default Hero;
1 change: 1 addition & 0 deletions src/components/Hero/Hero.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@
margin: 0;
margin-top: 5%;
}

}
4 changes: 4 additions & 0 deletions src/components/Navbar/Navbar.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,11 @@ function Navbar() {
<NavLink className={({ isActive }) => ("rem-default " + (isActive ? ' active' : ''))} to="/about">About us</NavLink>
</li>
<li className="navbar-list-item" onClick={handleMenuClose}>

<NavLink className={({ isActive }) => ("rem-default " + (isActive ? ' active' : ''))} to="/rateus">Rate Us</NavLink>

<NavLink className={({ isActive }) => ("rem-default " + (isActive ? ' active' : ''))} to="/login">AstroAccess</NavLink>

</li>
{renderContactLink()}
</ul>
Expand Down
18 changes: 14 additions & 4 deletions src/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,24 @@ body {
display: none;
}
::-webkit-scrollbar {
width: 15px;
width: 7px;
}

::-webkit-scrollbar:hover {
width: 9px;

}

::-webkit-scrollbar-track {
background: #d1e5ff;
background: #15013c;
}

::-webkit-scrollbar-thumb {
background: linear-gradient(#674a97, #8400ff);
border-radius: 10px;
background: linear-gradient(rgb(203, 131, 255), rgb(106, 0, 255));
border-radius: 7px;
}

::-webkit-scrollbar-thumb:hover {
background: linear-gradient(rgb(191, 102, 255), rgb(137, 58, 249));
border-radius: 7px;
}
6 changes: 6 additions & 0 deletions src/main.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,25 @@ import './index.css'
import App from './App.jsx'
import Rateus from './pages/Rateus/Rateus.jsx'
import Home from "./pages/Home/Home.jsx"
import Login from './pages/Login/page.jsx'
import MarsRover from './pages/MarsRover/MarsRover.jsx'
import NasaProjects from "./pages/NasaProjects/NasaProjects.jsx"
import About from "./pages/About/About.jsx"
import NotFoundPage from "./pages/404 Page/NotfoundPage.jsx"


const router = createBrowserRouter(
createRoutesFromElements(
<Route path='/' element={<App />}>
<Route index element={<Home />} />
<Route path='/marsrover' element={<MarsRover />} />
<Route path='/nasaprojects' element={<NasaProjects />} />
<Route path='/about' element={<About />} />

<Route path='/rateus' element={<Rateus />} />

<Route path='/login' element={<Login />} />

<Route path='*' element={<NotFoundPage />} />
</Route>
)
Expand Down
Loading

0 comments on commit 18fc359

Please sign in to comment.