mirror of
https://github.com/modelec/modelec.club.git
synced 2026-01-18 16:37:30 +01:00
41
.github/workflows/codeQL.yml
vendored
Normal file
41
.github/workflows/codeQL.yml
vendored
Normal file
@@ -0,0 +1,41 @@
|
||||
name: "CodeQL"
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- '**'
|
||||
pull_request:
|
||||
branches:
|
||||
- '**'
|
||||
schedule:
|
||||
- cron: '0 0 * * 0'
|
||||
|
||||
jobs:
|
||||
analyze:
|
||||
name: Analyze
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
permissions:
|
||||
actions: read
|
||||
contents: read
|
||||
security-events: write
|
||||
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
language: [ 'javascript', 'typescript' ]
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Initialize CodeQL
|
||||
uses: github/codeql-action/init@v3
|
||||
with:
|
||||
languages: ${{ matrix.language }}
|
||||
|
||||
- name: Autobuild
|
||||
uses: github/codeql-action/autobuild@v3
|
||||
|
||||
- name: Perform CodeQL Analysis
|
||||
uses: github/codeql-action/analyze@v3
|
||||
38
.github/workflows/deploy-test.yml
vendored
Normal file
38
.github/workflows/deploy-test.yml
vendored
Normal file
@@ -0,0 +1,38 @@
|
||||
name: Deploy to server (dry-run)
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- '**'
|
||||
|
||||
jobs:
|
||||
build-and-deploy:
|
||||
runs-on: ubuntu-latest
|
||||
environment: recette
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '20'
|
||||
|
||||
- name: Install dependencies and build
|
||||
run: |
|
||||
npm ci
|
||||
npm run build
|
||||
|
||||
- name: Copy build directory to server
|
||||
uses: Dylan700/sftp-upload-action@v1.2.3
|
||||
with:
|
||||
server: ${{ secrets.SERVER_HOST }}
|
||||
username: ${{ secrets.SERVER_USERNAME }}
|
||||
password: ${{ secrets.SERVER_PASSWORD }}
|
||||
port: ${{ secrets.SERVER_PORT }}
|
||||
uploads: |
|
||||
./dist => /var/www/modelec.club
|
||||
dry-run: true
|
||||
21
src/App.tsx
21
src/App.tsx
@@ -1,4 +1,5 @@
|
||||
import { BrowserRouter as Router, Route, Routes } from 'react-router-dom';
|
||||
import { ScrollToTop } from './hooks/scrollToTop';
|
||||
import React from 'react';
|
||||
|
||||
import './App.css';
|
||||
@@ -13,22 +14,24 @@ import Projets from './pages/projets/Projets';
|
||||
import Contact from './pages/contact/Contact';
|
||||
|
||||
const App: React.FC = () => {
|
||||
|
||||
return (<>
|
||||
<Router>
|
||||
<Navbar />
|
||||
<div className="page">
|
||||
return (
|
||||
<>
|
||||
<Router>
|
||||
<Navbar />
|
||||
<div className="page">
|
||||
<Routes>
|
||||
<ScrollToTop />
|
||||
<Route path="/" element={<Home />} />
|
||||
<Route path="/partenaires" element={<Partenaires />} />
|
||||
<Route path="/projets" element={<Projets />} />
|
||||
<Route path="/contact" element={<Contact />} />
|
||||
<Route path="*" element={<NotFound />} />
|
||||
</Routes>
|
||||
</div>
|
||||
<Footer />
|
||||
</Router>
|
||||
</>);
|
||||
</div>
|
||||
<Footer />
|
||||
</Router>
|
||||
</>
|
||||
);
|
||||
};
|
||||
|
||||
export default App;
|
||||
|
||||
12
src/hooks/scrollToTop.tsx
Normal file
12
src/hooks/scrollToTop.tsx
Normal file
@@ -0,0 +1,12 @@
|
||||
import { useEffect } from 'react';
|
||||
import { useLocation } from 'react-router-dom';
|
||||
|
||||
export const ScrollToTop = () => {
|
||||
const { pathname } = useLocation();
|
||||
|
||||
useEffect(() => {
|
||||
window.scrollTo(0, 0);
|
||||
}, [pathname]);
|
||||
|
||||
return null;
|
||||
};
|
||||
@@ -1,10 +1,17 @@
|
||||
import React from 'react';
|
||||
|
||||
import { Github, Youtube, Instagram, Handbag, MapPin, ChatBubbleEmpty } from 'iconoir-react';
|
||||
import { SocialNetworkList } from '../../components/socialnetwork/socialnetwork.tsx';
|
||||
import {
|
||||
Github,
|
||||
Youtube,
|
||||
Instagram,
|
||||
Handbag,
|
||||
MapPin,
|
||||
ChatBubbleEmpty,
|
||||
} from 'iconoir-react';
|
||||
import { SocialNetworkList } from '../../components/socialnetwork/socialnetwork';
|
||||
|
||||
import { ContactList } from '../../components/contact/contact.tsx';
|
||||
import { Banner } from '../../components/banner/banner.tsx';
|
||||
import { ContactList } from '../../components/contact/contact';
|
||||
import { Banner } from '../../components/banner/banner';
|
||||
|
||||
import isen_group_photo from '../../assets/isen_group_photo.png';
|
||||
|
||||
@@ -17,35 +24,61 @@ const Contact: React.FC = () => {
|
||||
{
|
||||
Icon: Handbag,
|
||||
title: 'Devenir partenaire',
|
||||
description: 'Devenez vous aussi partenaire de Modelec et soutenez notre projet.',
|
||||
link: { location: 'mailto:partenariat@modelec.club', text: 'partenariat@modelec.club' }
|
||||
description:
|
||||
'Devenez vous aussi partenaire de Modelec et soutenez notre projet.',
|
||||
link: {
|
||||
location: 'mailto:partenariat@modelec.club',
|
||||
text: 'partenariat@modelec.club',
|
||||
},
|
||||
},
|
||||
{
|
||||
Icon: MapPin,
|
||||
title: 'Nous rendre visite',
|
||||
description: '33 QUATER Avenue du Champ de Manoeuvre, 44470 Carquefou.',
|
||||
link: { location: 'https://maps.app.goo.gl/UVK3KFS8Zrpx7x9e6', text: 'Voir sur Google Maps' }
|
||||
description:
|
||||
'33 QUATER Avenue du Champ de Manoeuvre, 44470 Carquefou.',
|
||||
link: {
|
||||
location: 'https://maps.app.goo.gl/UVK3KFS8Zrpx7x9e6',
|
||||
text: 'Voir sur Google Maps',
|
||||
},
|
||||
},
|
||||
{
|
||||
Icon: ChatBubbleEmpty,
|
||||
title: 'Nous contacter',
|
||||
description: 'Pour toute question ou demande, n\'hésitez pas à nous contacter.',
|
||||
link: { location: 'mailto:contact@modelec.club', text: 'contact@modelec.club' }
|
||||
}
|
||||
description:
|
||||
"Pour toute question ou demande, n'hésitez pas à nous contacter.",
|
||||
link: {
|
||||
location: 'mailto:contact@modelec.club',
|
||||
text: 'contact@modelec.club',
|
||||
},
|
||||
},
|
||||
]}
|
||||
/>
|
||||
<Banner
|
||||
image={{ src: isen_group_photo, alt: 'Photo de groupe à l\'ISEN' }}
|
||||
image={{ src: isen_group_photo, alt: "Photo de groupe à l'ISEN" }}
|
||||
header={'Une question ?'}
|
||||
>
|
||||
Vous avez une <b>question</b> vis-à-vis de notre <u>club</u> ou de l'un de nos <u>projets</u> ? N'hésitez pas à nous <u>contacter</u> via l'une des méthode ci-dessus, nous serons ravis de vous répondre.
|
||||
Vous avez une <b>question</b> vis-à-vis de notre <u>club</u> ou de l'un
|
||||
de nos <u>projets</u> ? N'hésitez pas à nous <u>contacter</u> via l'une
|
||||
des méthode ci-dessus, nous serons ravis de vous répondre.
|
||||
</Banner>
|
||||
<h1 className={'page-title'}>Nos Réseaux</h1>
|
||||
<SocialNetworkList
|
||||
networks={[
|
||||
{ Icon: Instagram, name: 'modelec_isen', link: 'https://www.instagram.com/modelec_isen' },
|
||||
{ Icon: Youtube, name: 'modelec', link: 'https://youtube.com/@modelec2165' },
|
||||
{ Icon: Github, name: 'modelec', link: 'https://www.github.com/modelec' },
|
||||
{
|
||||
Icon: Instagram,
|
||||
name: 'modelec_isen',
|
||||
link: 'https://www.instagram.com/modelec_isen',
|
||||
},
|
||||
{
|
||||
Icon: Youtube,
|
||||
name: 'modelec',
|
||||
link: 'https://youtube.com/@modelec2165',
|
||||
},
|
||||
{
|
||||
Icon: Github,
|
||||
name: 'modelec',
|
||||
link: 'https://www.github.com/modelec',
|
||||
},
|
||||
]}
|
||||
/>
|
||||
</>
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
import React from 'react';
|
||||
import { ProjetsHeader } from '../../components/projetheader/projetheader';
|
||||
import { ProjectBigCard, ProjectSmallCard, } from '../../components/projectcard/projectcard.tsx';
|
||||
import {
|
||||
ProjectBigCard,
|
||||
ProjectSmallCard,
|
||||
} from '../../components/projectcard/projectcard';
|
||||
|
||||
import './Projets.css';
|
||||
|
||||
|
||||
@@ -1 +1,2 @@
|
||||
{"root":["./src/app.tsx","./src/main.tsx","./src/vite-env.d.ts","./src/components/banner/banner.tsx","./src/components/box/box.tsx","./src/components/carousel/carousel.tsx","./src/components/contact/contact.tsx","./src/components/partner/partner.tsx","./src/components/projectcard/projectcard.tsx","./src/components/projetheader/projectheadercard.tsx","./src/components/projetheader/projetheader.tsx","./src/components/socialnetwork/socialnetwork.tsx","./src/components/team/team.tsx","./src/hooks/usewindowssize.tsx","./src/layouts/footer/footer.tsx","./src/layouts/navbar/navbar.tsx","./src/pages/404/404.tsx","./src/pages/contact/contact.tsx","./src/pages/home/home.tsx","./src/pages/partenaires/partenaires.tsx","./src/pages/projets/projets.tsx"],"version":"5.6.3"}
|
||||
{"root":["./src/app.tsx","./src/main.tsx","./src/vite-env.d.ts","./src/components/banner/banner.tsx","./src/components/box/box.tsx","./src/components/carousel/carousel.tsx","./src/components/contact/contact.tsx","./src/components/partner/partner.tsx","./src/components/projectcard/projectcard.tsx","./src/components/projetheader/projectheadercard.tsx","./src/components/projetheader/projetheader.tsx","./src/components/socialnetwork/socialnetwork.tsx","./src/components/team/team.tsx","./src/hooks/scrolltotop.tsx","./src/hooks/usewindowssize.tsx","./src/layouts/footer/footer.tsx","./src/layouts/navbar/navbar.tsx","./src/pages/404/404.tsx","./src/pages/contact/contact.tsx","./src/pages/home/home.tsx","./src/pages/partenaires/partenaires.tsx","./src/pages/projets/projets.tsx"],"version":"5.6.3"}
|
||||
{"root":["./src/app.tsx","./src/main.tsx","./src/vite-env.d.ts","./src/components/carousel/carousel.tsx","./src/components/footer/footer.tsx","./src/components/middletext/middletext.tsx","./src/components/navbar/navbar.tsx","./src/components/navbarlink/navbarlink.tsx","./src/components/sidecard/fromleftcard.tsx","./src/components/sidecard/fromrightcard.tsx","./src/components/socialnetwork/socialnetwork.tsx","./src/components/team/team.tsx","./src/pages/404.tsx","./src/pages/home.tsx"],"version":"5.6.2"}
|
||||
|
||||
Reference in New Issue
Block a user