mirror of
https://github.com/Paris-est-Ludique/intranet.git
synced 2025-09-11 05:46:28 +02:00
Update sign up message and available meetup location
This commit is contained in:
@@ -6,7 +6,7 @@ import { AskWelcome } from "./AskWelcome"
|
||||
import { AskBrunch, fetchFor as fetchForBrunch } from "./AskBrunch"
|
||||
import { AskRetex, fetchFor as fetchForRetex } from "./AskRetex"
|
||||
import { AskDiscord, fetchFor as fetchForDiscord } from "./AskDiscord"
|
||||
// import { AskDayWishes, fetchFor as fetchForDayWishes } from "./AskDayWishes"
|
||||
import { AskDayWishes, fetchFor as fetchForDayWishes } from "./AskDayWishes"
|
||||
// import { AskHosting, fetchFor as fetchForHosting } from "./AskHosting"
|
||||
// import { AskMeals, fetchFor as fetchForMeals } from "./AskMeals"
|
||||
// import { AskPersonalInfo, fetchFor as fetchForPersonalInfo } from "./AskPersonalInfo"
|
||||
@@ -26,7 +26,7 @@ const Asks = (): JSX.Element | null => {
|
||||
AskRetex(asks, 3)
|
||||
AskDiscord(asks, 5)
|
||||
|
||||
// AskDayWishes(asks, 10)
|
||||
AskDayWishes(asks, 10)
|
||||
// AskTeamWishes(asks, 11)
|
||||
// AskParticipationDetails(asks, 12)
|
||||
// AskPersonalInfo(asks, 15)
|
||||
@@ -69,7 +69,7 @@ export const fetchFor = [
|
||||
...fetchForBrunch,
|
||||
...fetchForRetex,
|
||||
...fetchForDiscord,
|
||||
// ...fetchForDayWishes,
|
||||
...fetchForDayWishes,
|
||||
// ...fetchForHosting,
|
||||
// ...fetchForMeals,
|
||||
// ...fetchForTeamWishes,
|
||||
|
@@ -37,7 +37,7 @@ const KnowledgeBoxList: React.FC = (): JSX.Element | null => {
|
||||
onChange={onShowUnknownOnly}
|
||||
checked={showUnknownOnly}
|
||||
/>{" "}
|
||||
Uniquement les non-renseignés
|
||||
Afficher uniquement les non-renseignés
|
||||
</label>
|
||||
<ul className={styles.boxList}>
|
||||
{boxesToShow.map((detailedBox: any) => (
|
||||
|
@@ -5,7 +5,6 @@
|
||||
text-align: left;
|
||||
display: inline-block;
|
||||
margin-bottom: 10px;
|
||||
width: 280px;
|
||||
}
|
||||
|
||||
.boxList {
|
||||
|
@@ -1,156 +0,0 @@
|
||||
import { cloneDeep, pull, sortBy, uniq } from "lodash"
|
||||
import React, { memo, useCallback, useEffect, useState } from "react"
|
||||
import classnames from "classnames"
|
||||
import styles from "./styles.module.scss"
|
||||
import { DetailedBox } from "../../services/boxes"
|
||||
import { VolunteerLoan, VolunteerLoanWithoutId } from "../../services/volunteers"
|
||||
|
||||
interface Props {
|
||||
detailedBox: DetailedBox
|
||||
volunteerLoan: VolunteerLoan | undefined
|
||||
saveVolunteerLoan: (newVolunteerLoan: VolunteerLoan) => void
|
||||
}
|
||||
|
||||
const BoxItem: React.FC<Props> = ({
|
||||
detailedBox,
|
||||
volunteerLoan,
|
||||
saveVolunteerLoan,
|
||||
}): JSX.Element => {
|
||||
type ChoiceValue = keyof VolunteerLoanWithoutId
|
||||
const [loanable, setLoanable] = useState(false)
|
||||
const [playable, setPlayable] = useState(false)
|
||||
const [giftable, setGiftable] = useState(false)
|
||||
const [noOpinion, setNoOpinion] = useState(false)
|
||||
const { gameId, bggPhoto, title, bggId, poufpaf, bggIdAlternative } = detailedBox
|
||||
const isBggPhoto = !/^[0-9]+\.[a-zA-Z]+$/.test(bggPhoto)
|
||||
const loanChoices: { name: string; value: ChoiceValue }[] = [
|
||||
{ name: "Empruntable", value: "loanable" },
|
||||
{ name: "Jouable", value: "playable" },
|
||||
{ name: "Offrable", value: "giftable" },
|
||||
{ name: "SansAvis", value: "noOpinion" },
|
||||
]
|
||||
const loanValues = {
|
||||
loanable,
|
||||
playable,
|
||||
giftable,
|
||||
noOpinion,
|
||||
}
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
const loanSetters = {
|
||||
loanable: setLoanable,
|
||||
playable: setPlayable,
|
||||
giftable: setGiftable,
|
||||
noOpinion: setNoOpinion,
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
if (!volunteerLoan) return
|
||||
setLoanable(volunteerLoan.loanable.includes(gameId))
|
||||
setPlayable(volunteerLoan.playable.includes(gameId))
|
||||
setGiftable(volunteerLoan.giftable.includes(gameId))
|
||||
setNoOpinion(volunteerLoan.noOpinion.includes(gameId))
|
||||
}, [gameId, volunteerLoan])
|
||||
|
||||
const onChoiceClick = useCallback(
|
||||
(value: ChoiceValue) => {
|
||||
if (!volunteerLoan) return
|
||||
const adding = !volunteerLoan[value].includes(gameId)
|
||||
const newVolunteerLoan: VolunteerLoan = cloneDeep(volunteerLoan)
|
||||
if (adding) {
|
||||
newVolunteerLoan[value] = sortBy(uniq([...newVolunteerLoan[value], gameId]))
|
||||
} else {
|
||||
pull(newVolunteerLoan[value], gameId)
|
||||
}
|
||||
|
||||
if (adding && value === "noOpinion") {
|
||||
pull(newVolunteerLoan.loanable, gameId)
|
||||
pull(newVolunteerLoan.playable, gameId)
|
||||
pull(newVolunteerLoan.giftable, gameId)
|
||||
setLoanable(volunteerLoan.loanable.includes(gameId))
|
||||
setPlayable(volunteerLoan.playable.includes(gameId))
|
||||
setGiftable(volunteerLoan.giftable.includes(gameId))
|
||||
setNoOpinion(true)
|
||||
} else {
|
||||
pull(newVolunteerLoan.noOpinion, gameId)
|
||||
setNoOpinion(false)
|
||||
loanSetters[value](adding)
|
||||
}
|
||||
saveVolunteerLoan(newVolunteerLoan)
|
||||
},
|
||||
[volunteerLoan, gameId, saveVolunteerLoan, loanSetters]
|
||||
)
|
||||
|
||||
const onCheckboxChange = useCallback(() => {
|
||||
// Do nothing
|
||||
}, [])
|
||||
|
||||
return (
|
||||
<li className={styles.boxItem}>
|
||||
<div className={styles.photoContainer}>
|
||||
{isBggPhoto && <img className={styles.photo} src={bggPhoto} alt="" />}
|
||||
{!isBggPhoto && (
|
||||
<div
|
||||
className={classnames(
|
||||
styles.alternateBox,
|
||||
styles[`a${bggPhoto.replace(/\..*/, "")}`]
|
||||
)}
|
||||
>
|
||||
{" "}
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
<div className={classnames(styles.titleContainer, poufpaf && styles.shorterTitle)}>
|
||||
<a
|
||||
href={
|
||||
bggId > 0
|
||||
? `https://boardgamegeek.com/boardgame/${bggId}`
|
||||
: bggIdAlternative
|
||||
}
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
className={styles.title}
|
||||
>
|
||||
{title}
|
||||
</a>
|
||||
</div>
|
||||
<a
|
||||
href={`https://sites.google.com/site/poufpafpasteque/fiches_alpha/${poufpaf}`}
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
>
|
||||
<div className={poufpaf ? styles.poufpaf : styles.noPoufpaf}> </div>
|
||||
</a>
|
||||
<ul className={styles.loanList}>
|
||||
{loanChoices.map(({ name, value }) => (
|
||||
<li key={value} className={styles.loanItem}>
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => onChoiceClick(value)}
|
||||
className={classnames(
|
||||
styles.loanButton,
|
||||
styles[value],
|
||||
loanValues[value] && styles.active
|
||||
)}
|
||||
data-message={name}
|
||||
>
|
||||
<input
|
||||
type="checkbox"
|
||||
className={styles.loanCheckbox}
|
||||
checked={loanValues[value]}
|
||||
onChange={() => onCheckboxChange()}
|
||||
/>
|
||||
<div
|
||||
className={classnames(
|
||||
styles.loanCheckboxImg,
|
||||
styles[`${value}Checkbox`]
|
||||
)}
|
||||
/>
|
||||
</button>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
</li>
|
||||
)
|
||||
}
|
||||
|
||||
export default memo(BoxItem)
|
164
src/components/Loan/DetailedGameItem.tsx
Normal file
164
src/components/Loan/DetailedGameItem.tsx
Normal file
@@ -0,0 +1,164 @@
|
||||
// import { cloneDeep, pull, sortBy, uniq } from "lodash"
|
||||
import { toast } from "react-toastify"
|
||||
import React, { memo, useCallback, useEffect, useState } from "react"
|
||||
import classnames from "classnames"
|
||||
import styles from "./styles.module.scss"
|
||||
import { DetailedBox } from "../../services/boxes"
|
||||
import { VolunteerLoan, VolunteerLoanWithoutId } from "../../services/volunteers"
|
||||
|
||||
interface Props {
|
||||
detailedGame: DetailedBox
|
||||
volunteerLoan: VolunteerLoan | undefined
|
||||
saveVolunteerLoan: (newVolunteerLoan: VolunteerLoan) => void
|
||||
}
|
||||
|
||||
const DetailedGameItem: React.FC<Props> = ({
|
||||
detailedGame,
|
||||
volunteerLoan,
|
||||
saveVolunteerLoan,
|
||||
}): JSX.Element => {
|
||||
type ChoiceValue = keyof VolunteerLoanWithoutId
|
||||
const [loanable, setLoanable] = useState(false)
|
||||
const [playable, setPlayable] = useState(false)
|
||||
const [giftable, setGiftable] = useState(false)
|
||||
const [noOpinion, setNoOpinion] = useState(false)
|
||||
const { gameId, bggPhoto, title, bggId, poufpaf, bggIdAlternative } = detailedGame
|
||||
const isBggPhoto = !/^[0-9]+\.[a-zA-Z]+$/.test(bggPhoto)
|
||||
const loanChoices: { name: string; value: ChoiceValue }[] = [
|
||||
{ name: "Empruntable", value: "loanable" },
|
||||
{ name: "Jouable", value: "playable" },
|
||||
{ name: "Offrable", value: "giftable" },
|
||||
{ name: "SansAvis", value: "noOpinion" },
|
||||
]
|
||||
const loanValues = {
|
||||
loanable,
|
||||
playable,
|
||||
giftable,
|
||||
noOpinion,
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
if (!volunteerLoan) return
|
||||
setLoanable(volunteerLoan.loanable.includes(gameId))
|
||||
setPlayable(volunteerLoan.playable.includes(gameId))
|
||||
setGiftable(volunteerLoan.giftable.includes(gameId))
|
||||
setNoOpinion(volunteerLoan.noOpinion.includes(gameId))
|
||||
}, [gameId, volunteerLoan])
|
||||
|
||||
const onChoiceClick = useCallback(
|
||||
(_value: ChoiceValue) => {
|
||||
toast.warning("Il n'est plus possible de changer ses choix", {
|
||||
position: "top-center",
|
||||
autoClose: 500,
|
||||
hideProgressBar: true,
|
||||
closeOnClick: true,
|
||||
pauseOnHover: true,
|
||||
draggable: true,
|
||||
progress: undefined,
|
||||
})
|
||||
},
|
||||
[]
|
||||
|
||||
// (value: ChoiceValue) => {
|
||||
// if (!volunteerLoan) return
|
||||
// const adding = !volunteerLoan[value].includes(gameId)
|
||||
// const newVolunteerLoan: VolunteerLoan = cloneDeep(volunteerLoan)
|
||||
// if (adding) {
|
||||
// newVolunteerLoan[value] = sortBy(uniq([...newVolunteerLoan[value], gameId]))
|
||||
// } else {
|
||||
// pull(newVolunteerLoan[value], gameId)
|
||||
// }
|
||||
|
||||
// if (adding && value === "noOpinion") {
|
||||
// pull(newVolunteerLoan.loanable, gameId)
|
||||
// pull(newVolunteerLoan.playable, gameId)
|
||||
// pull(newVolunteerLoan.giftable, gameId)
|
||||
// } else {
|
||||
// pull(newVolunteerLoan.noOpinion, gameId)
|
||||
// }
|
||||
// saveVolunteerLoan(newVolunteerLoan)
|
||||
// },
|
||||
// [volunteerLoan, gameId, saveVolunteerLoan]
|
||||
)
|
||||
|
||||
// Just to keep saveVolunteerLoan necessary to prevent errors while changes are prevented
|
||||
if (!saveVolunteerLoan) {
|
||||
console.log("")
|
||||
}
|
||||
|
||||
const onCheckboxChange = useCallback(() => {
|
||||
// Do nothing
|
||||
}, [])
|
||||
|
||||
return (
|
||||
<>
|
||||
<li className={classnames(styles.boxItem, !volunteerLoan && styles.hide)}>
|
||||
<div className={styles.photoContainer}>
|
||||
{isBggPhoto && <img className={styles.photo} src={bggPhoto} alt="" />}
|
||||
{!isBggPhoto && (
|
||||
<div
|
||||
className={classnames(
|
||||
styles.alternateBox,
|
||||
styles[`a${bggPhoto.replace(/\..*/, "")}`]
|
||||
)}
|
||||
>
|
||||
{" "}
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
<div className={classnames(styles.titleContainer, poufpaf && styles.shorterTitle)}>
|
||||
<a
|
||||
href={
|
||||
bggId > 0
|
||||
? `https://boardgamegeek.com/boardgame/${bggId}`
|
||||
: bggIdAlternative
|
||||
}
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
className={styles.title}
|
||||
>
|
||||
{title}
|
||||
</a>
|
||||
</div>
|
||||
<a
|
||||
href={`https://sites.google.com/site/poufpafpasteque/fiches_alpha/${poufpaf}`}
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
>
|
||||
<div className={poufpaf ? styles.poufpaf : styles.noPoufpaf}> </div>
|
||||
</a>
|
||||
<ul className={styles.loanList}>
|
||||
{loanChoices.map(({ name, value }) => (
|
||||
<li key={value} className={styles.loanItem}>
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => onChoiceClick(value)}
|
||||
className={classnames(
|
||||
styles.loanButton,
|
||||
styles[value],
|
||||
loanValues[value] && styles.active
|
||||
)}
|
||||
data-message={name}
|
||||
>
|
||||
<input
|
||||
type="checkbox"
|
||||
className={styles.loanCheckbox}
|
||||
checked={loanValues[value]}
|
||||
onChange={() => onCheckboxChange()}
|
||||
/>
|
||||
<div
|
||||
className={classnames(
|
||||
styles.loanCheckboxImg,
|
||||
styles[`${value}Checkbox`]
|
||||
)}
|
||||
/>
|
||||
</button>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
</li>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
export default memo(DetailedGameItem)
|
64
src/components/Loan/GamesWithVolunteersItem.tsx
Normal file
64
src/components/Loan/GamesWithVolunteersItem.tsx
Normal file
@@ -0,0 +1,64 @@
|
||||
import React, { memo } from "react"
|
||||
import classnames from "classnames"
|
||||
import styles from "./styles.module.scss"
|
||||
import { GameWithVolunteers } from "../../services/games"
|
||||
import { gameTitleExactCategory } from "../../store/utils"
|
||||
|
||||
interface Props {
|
||||
gameWithLoans: GameWithVolunteers
|
||||
}
|
||||
|
||||
const LoanGamesItem: React.FC<Props> = ({ gameWithLoans }): JSX.Element => {
|
||||
const { bggPhoto, title, bggId, poufpaf, bggIdAlternative, volunteerNicknames, boxCount } =
|
||||
gameWithLoans
|
||||
const isBggPhoto = !/^[0-9]+\.[a-zA-Z]+$/.test(bggPhoto)
|
||||
|
||||
return (
|
||||
<li className={styles.boxItem}>
|
||||
<div className={styles.photoContainer}>
|
||||
{isBggPhoto && <img className={styles.photo} src={bggPhoto} alt="" />}
|
||||
{!isBggPhoto && (
|
||||
<div
|
||||
className={classnames(
|
||||
styles.alternateBox,
|
||||
styles[`a${bggPhoto.replace(/\..*/, "")}`]
|
||||
)}
|
||||
>
|
||||
{" "}
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
<div className={classnames(styles.titleContainer, poufpaf && styles.shorterTitle)}>
|
||||
<a
|
||||
href={
|
||||
bggId > 0
|
||||
? `https://boardgamegeek.com/boardgame/${bggId}`
|
||||
: bggIdAlternative
|
||||
}
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
className={styles.title}
|
||||
>
|
||||
{title}
|
||||
</a>
|
||||
</div>
|
||||
<a
|
||||
href={`https://sites.google.com/site/poufpafpasteque/fiches_alpha/${poufpaf}`}
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
>
|
||||
<div className={poufpaf ? styles.poufpaf : styles.noPoufpaf}> </div>
|
||||
</a>
|
||||
<div className={styles.boxCount}>
|
||||
{boxCount > 1 ? `${boxCount} boîtes` : ""}
|
||||
<br />
|
||||
{gameTitleExactCategory({ title })}
|
||||
</div>
|
||||
<div className={styles.volunteerList}>
|
||||
Bénévoles intéressés: {volunteerNicknames.join(", ")}
|
||||
</div>
|
||||
</li>
|
||||
)
|
||||
}
|
||||
|
||||
export default memo(LoanGamesItem)
|
@@ -1,23 +1,21 @@
|
||||
import React, { memo, useState } from "react"
|
||||
import { useSelector } from "react-redux"
|
||||
import styles from "./styles.module.scss"
|
||||
import BoxItem from "./BoxItem"
|
||||
import { fetchBoxListIfNeed, selectSortedUniqueDetailedBoxes } from "../../store/boxList"
|
||||
import { fetchVolunteerLoanSetIfNeed, useVolunteerLoan } from "../../store/volunteerLoanSet"
|
||||
import { DetailedBox } from "../../services/boxes"
|
||||
import DetailedGameItem from "./DetailedGameItem"
|
||||
|
||||
const LoanBoxList: React.FC = (): JSX.Element | null => {
|
||||
const detailedBoxes = useSelector(selectSortedUniqueDetailedBoxes)
|
||||
const Loaning: React.FC = (): JSX.Element | null => {
|
||||
const detailedBoxes: DetailedBox[] = useSelector(selectSortedUniqueDetailedBoxes)
|
||||
const [volunteerLoan, saveVolunteerLoan] = useVolunteerLoan()
|
||||
const [showUnknownOnly, setShowUnknownOnly] = useState(false)
|
||||
|
||||
const onShowUnknownOnly = (e: React.ChangeEvent<HTMLInputElement>) =>
|
||||
setShowUnknownOnly(e.target.checked)
|
||||
|
||||
if (!detailedBoxes || detailedBoxes.length === 0) return null
|
||||
|
||||
const boxesToShow = detailedBoxes.filter(
|
||||
(box) =>
|
||||
!box ||
|
||||
!showUnknownOnly ||
|
||||
!volunteerLoan ||
|
||||
(!volunteerLoan.loanable.includes(box.gameId) &&
|
||||
@@ -28,22 +26,22 @@ const LoanBoxList: React.FC = (): JSX.Element | null => {
|
||||
|
||||
return (
|
||||
<div className={styles.loanThings}>
|
||||
<label className={styles.showUnknownOnlyLabel}>
|
||||
<label className={styles.showCheckboxLabel}>
|
||||
<input
|
||||
type="checkbox"
|
||||
name="showUnknownOnly"
|
||||
onChange={onShowUnknownOnly}
|
||||
checked={showUnknownOnly}
|
||||
/>{" "}
|
||||
Uniquement les non-renseignés
|
||||
Afficher uniquement les non-renseignés
|
||||
</label>
|
||||
<ul className={styles.boxList}>
|
||||
{boxesToShow.map((detailedBox: any) => (
|
||||
<BoxItem
|
||||
detailedBox={detailedBox}
|
||||
{boxesToShow.map((game) => (
|
||||
<DetailedGameItem
|
||||
detailedGame={game}
|
||||
volunteerLoan={volunteerLoan}
|
||||
saveVolunteerLoan={saveVolunteerLoan}
|
||||
key={detailedBox.id}
|
||||
key={game.id}
|
||||
/>
|
||||
))}
|
||||
</ul>
|
||||
@@ -51,6 +49,6 @@ const LoanBoxList: React.FC = (): JSX.Element | null => {
|
||||
)
|
||||
}
|
||||
|
||||
export default memo(LoanBoxList)
|
||||
export default memo(Loaning)
|
||||
|
||||
export const fetchFor = [fetchBoxListIfNeed, fetchVolunteerLoanSetIfNeed]
|
@@ -2,7 +2,7 @@ import classnames from "classnames"
|
||||
import React from "react"
|
||||
import styles from "./styles.module.scss"
|
||||
|
||||
const LoanIntro: React.FC = (): JSX.Element => (
|
||||
const LoaningIntro: React.FC = (): JSX.Element => (
|
||||
<div className={styles.loanThings}>
|
||||
<h1>Emprunt et tri des jeux</h1>
|
||||
<p>
|
||||
@@ -54,4 +54,4 @@ const LoanIntro: React.FC = (): JSX.Element => (
|
||||
</div>
|
||||
)
|
||||
|
||||
export default LoanIntro
|
||||
export default LoaningIntro
|
46
src/components/Loan/Loans.tsx
Normal file
46
src/components/Loan/Loans.tsx
Normal file
@@ -0,0 +1,46 @@
|
||||
import React, { memo } from "react"
|
||||
import { useSelector } from "react-redux"
|
||||
import styles from "./styles.module.scss"
|
||||
import {
|
||||
fetchGameWithVolunteersListIfNeed,
|
||||
selectSortedUniqueGamesWithVolunteers,
|
||||
} from "../../store/gameWithVolunteersList"
|
||||
import { GameWithVolunteers } from "../../services/games"
|
||||
import GamesWithVolunteersItem from "./GamesWithVolunteersItem"
|
||||
|
||||
const Loans: React.FC = (): JSX.Element | null => {
|
||||
const gameWithLoans: GameWithVolunteers[] = useSelector(selectSortedUniqueGamesWithVolunteers)
|
||||
|
||||
const loanGames = gameWithLoans.filter((game) => game.toLoan)
|
||||
// const giftGames = gameWithLoans.filter(game => !game.toLoan)
|
||||
|
||||
return (
|
||||
<div>
|
||||
<h3>Jeux que tu veux emprunter</h3>
|
||||
{loanGames.length > 0 && (
|
||||
<ul className={styles.boxList}>
|
||||
{loanGames.map((game) => (
|
||||
<GamesWithVolunteersItem gameWithLoans={game} key={game.id} />
|
||||
))}
|
||||
</ul>
|
||||
)}
|
||||
{loanGames.length === 0 && <>Aucun jeu.</>}
|
||||
|
||||
{/* {giftGames.length > 0 && <>
|
||||
<h3>Jeux que tu voudrais récupérer définitivement</h3>
|
||||
<ul className={styles.boxList}>
|
||||
{giftGames.map(game => (
|
||||
<GamesWithVolunteersItem
|
||||
gameWithLoans={game}
|
||||
key={game.id}
|
||||
/>
|
||||
))}
|
||||
</ul>
|
||||
</>} */}
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
export default memo(Loans)
|
||||
|
||||
export const fetchFor = [fetchGameWithVolunteersListIfNeed]
|
14
src/components/Loan/LoansIntro.tsx
Normal file
14
src/components/Loan/LoansIntro.tsx
Normal file
@@ -0,0 +1,14 @@
|
||||
import React from "react"
|
||||
import styles from "./styles.module.scss"
|
||||
|
||||
const LoansIntro: React.FC = (): JSX.Element => (
|
||||
<div className={styles.loanThings}>
|
||||
<h1>Jeux à emprunter</h1>
|
||||
<p>
|
||||
Si un jeu qui t'intéresse est emprunté par un autre bénévole, son nom sera affiché ici.
|
||||
Vous pourrez peut-être envisager d'y jouer ensemble !
|
||||
</p>
|
||||
</div>
|
||||
)
|
||||
|
||||
export default LoansIntro
|
@@ -1,11 +1,14 @@
|
||||
@import "../../theme/variables";
|
||||
@import "../../theme/mixins";
|
||||
|
||||
.showUnknownOnlyLabel {
|
||||
.showCheckboxLabel {
|
||||
text-align: left;
|
||||
display: inline-block;
|
||||
margin-bottom: 10px;
|
||||
width: 280px;
|
||||
}
|
||||
|
||||
.hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.boxList {
|
||||
@@ -200,6 +203,22 @@
|
||||
display: none;
|
||||
}
|
||||
|
||||
.boxCount {
|
||||
height: 50px;
|
||||
width: 73px;
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.volunteerList {
|
||||
height: 50px;
|
||||
width: 198px;
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.loanList {
|
||||
@include clear-ul-style;
|
||||
|
||||
|
@@ -52,6 +52,7 @@ const MainMenu: FC = (): JSX.Element => {
|
||||
<MenuItem name="Questions" pathname="/" />
|
||||
<MenuItem name="Annonces" pathname="/annonces" />
|
||||
<MenuItem name="Mon profil" pathname="/profil" />
|
||||
<MenuItem name="Emprunter" pathname="/emprunter" />
|
||||
<MenuItem name="Emprunts" pathname="/emprunts" />
|
||||
{/* <MenuItem name="Mes connaissances" pathname="/connaissances" /> */}
|
||||
<RestrictMenuItem
|
||||
|
@@ -8,7 +8,6 @@ import styles from "./styles.module.scss"
|
||||
|
||||
import { fetchPostulantAdd } from "../../store/postulantAdd"
|
||||
import { AppDispatch, AppState } from "../../store"
|
||||
import { fetchVolunteerPartialAdd } from "../../store/volunteerPartialAdd"
|
||||
import FormButton from "../Form/FormButton/FormButton"
|
||||
import { validEmail } from "../../utils/standardization"
|
||||
import { toastError } from "../../store/utils"
|
||||
@@ -38,24 +37,21 @@ const animations = [
|
||||
[styles.imgTransitionShow, styles.imgTransitionAbouToShow],
|
||||
]
|
||||
const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
const [potentialVolunteer, setPotentialVolunteer] = useState(true)
|
||||
const [firstname, setFirstname] = useState("")
|
||||
const [lastname, setLastname] = useState("")
|
||||
const [email, setEmail] = useState("")
|
||||
const [mobile, setMobile] = useState("")
|
||||
const [alreadyVolunteer, setAlreadyVolunteer] = useState(false)
|
||||
const [comment, setComment] = useState("")
|
||||
const [alreadyCame, setAlreadyCame] = useState(true)
|
||||
const [firstMeeting, setFirstMeeting] = useState("")
|
||||
const [commentFirstMeeting, setCommentFirstMeeting] = useState("")
|
||||
const [canHelpBefore, setCanHelpBefore] = useState("")
|
||||
const [howToContact, setHowToContact] = useState("Email")
|
||||
const [sending, setSending] = useState(false)
|
||||
const [changingBackground, setChangingBackground] = useState(0)
|
||||
|
||||
const meetingDateList = useSelector(selectMiscMeetingDateList)
|
||||
|
||||
const enableRegistering = false
|
||||
const enableRegistering = true
|
||||
|
||||
useEffect(() => {
|
||||
const timer = setInterval(() => {
|
||||
@@ -83,47 +79,29 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
return
|
||||
}
|
||||
|
||||
if (potentialVolunteer) {
|
||||
dispatch(
|
||||
fetchPostulantAdd({
|
||||
potential: true,
|
||||
firstname,
|
||||
lastname,
|
||||
email,
|
||||
mobile,
|
||||
howToContact,
|
||||
alreadyCame,
|
||||
firstMeeting,
|
||||
commentFirstMeeting: firstMeeting ? "" : commentFirstMeeting,
|
||||
comment,
|
||||
})
|
||||
)
|
||||
} else {
|
||||
dispatch(
|
||||
fetchVolunteerPartialAdd({
|
||||
firstname,
|
||||
lastname,
|
||||
email,
|
||||
mobile,
|
||||
howToContact,
|
||||
canHelpBefore,
|
||||
})
|
||||
)
|
||||
dispatch(
|
||||
fetchPostulantAdd({
|
||||
potential: false,
|
||||
firstname,
|
||||
lastname,
|
||||
email,
|
||||
mobile,
|
||||
howToContact,
|
||||
alreadyCame,
|
||||
firstMeeting,
|
||||
commentFirstMeeting: firstMeeting ? "" : commentFirstMeeting,
|
||||
comment,
|
||||
})
|
||||
)
|
||||
}
|
||||
dispatch(
|
||||
fetchPostulantAdd({
|
||||
potential: true,
|
||||
firstname,
|
||||
lastname,
|
||||
email,
|
||||
mobile,
|
||||
howToContact,
|
||||
alreadyCame,
|
||||
firstMeeting,
|
||||
commentFirstMeeting: firstMeeting ? "" : commentFirstMeeting,
|
||||
comment,
|
||||
})
|
||||
)
|
||||
// dispatch(
|
||||
// fetchVolunteerPartialAdd({
|
||||
// firstname,
|
||||
// lastname,
|
||||
// email,
|
||||
// mobile,
|
||||
// howToContact,
|
||||
// })
|
||||
// )
|
||||
|
||||
setSending(true)
|
||||
}
|
||||
@@ -141,11 +119,7 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
let sendSuccess
|
||||
let sendError
|
||||
let sendingElement
|
||||
if (
|
||||
!postulantError &&
|
||||
!_.isEmpty(postulant) &&
|
||||
(potentialVolunteer || (!volunteerError && !_.isEmpty(volunteer)))
|
||||
) {
|
||||
if (!postulantError && !_.isEmpty(postulant)) {
|
||||
if (sending) {
|
||||
setSending(false)
|
||||
}
|
||||
@@ -181,11 +155,11 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
<dd>
|
||||
<p>
|
||||
Un festival en plein air dédié aux <b>jeux de société modernes</b> sous toutes
|
||||
leurs formes. Les samedi 2 et dimanche 3 juillet 2022 !
|
||||
leurs formes. Les samedi 24 et dimanche 25 juin 2023 !
|
||||
</p>
|
||||
<p>
|
||||
En 2019 lors de la dernière édition, ce sont <b>16 000</b> joueurs qui se sont
|
||||
réunis sous 300 chapiteaux et 2 000 tables.
|
||||
En 2022, ce sont <b>18 000</b> visiteurs qui sont venus sous 300 chapiteaux et 2
|
||||
000 tables.
|
||||
</p>
|
||||
<p>
|
||||
Les 2 jours que durent le festival sont entièrement dédiés à ce que le public{" "}
|
||||
@@ -211,7 +185,7 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
toute l'année ^^
|
||||
</p>
|
||||
<p>
|
||||
Pendant le festival de 2019, nous étions <b>187 bénévoles</b> organisés en
|
||||
Pendant le festival de 2022, nous étions <b>196 bénévoles</b> organisés en
|
||||
équipes qui chouchoutent les visiteurs en les accueillant, en s'assurant
|
||||
que tout se passe bien, ou encore en expliquant des règles de jeux.
|
||||
</p>
|
||||
@@ -224,9 +198,9 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
<p>
|
||||
La majorité d'entre nous sommes bénévoles les <b>samedi et dimanche</b>, mais
|
||||
certains bénévoles ne sont pas disponibles les deux jours. On leur demande alors
|
||||
d'aider à la mise en place jeudi ou vendredi, ou au rangement le lundi, à la
|
||||
place d'un des jours du weekend. Bref, chacun participe comme il peut mais deux
|
||||
jours minimum !
|
||||
d'aider à la mise en place mercredi, jeudi ou vendredi, ou au rangement le
|
||||
lundi, à la place d'un des jours du weekend. Bref, chacun participe comme il
|
||||
peut mais <b>deux jours minimum</b> !
|
||||
</p>
|
||||
<p>
|
||||
Le samedi soir quand les visiteurs sont partis, nous prolongeons la fête en
|
||||
@@ -238,8 +212,8 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
|
||||
{!enableRegistering && (
|
||||
<dt>
|
||||
L'inscription est clôturée pour l'édition 2022, mais si l'expérience vous tente,
|
||||
remplissez le formulaire suivant pour devenir bénévole à PeL 2023 !<br />
|
||||
L'inscription est clôturée pour l'édition 2023, mais si l'expérience te tente,
|
||||
remplis le formulaire suivant pour devenir bénévole à PeL 2024 !<br />
|
||||
Dès septembre on se rencontrera sur Paris en petits groupes pour discuter du
|
||||
festival, du bénévolat et surtout faire connaissance :)
|
||||
<br />
|
||||
@@ -248,98 +222,15 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
|
||||
{enableRegistering && (
|
||||
<dt>
|
||||
Si l'expérience vous tente, remplissez le formulaire suivant pour devenir
|
||||
bénévole !<br />
|
||||
Vous pouvez aussi juste nous rencontrer avant de vous décider à devenir
|
||||
bénévole, on comprend qu'un saut pareil dans l'inconnu soit difficile.
|
||||
<br />
|
||||
Dans les deux cas, venez rencontrer une poignée d'entre nous dans un bar/resto
|
||||
près de Châtelet ! :) Sur inscription uniquement...
|
||||
Si tu as envie de donner le sourire à des milliers de gens, remplis le
|
||||
formulaire suivant pour rencontrer une poignée d'entre nous dans un bar/resto
|
||||
près de Châtelet, avant de te décider ou non à devenir bénévole :)
|
||||
<br />
|
||||
</dt>
|
||||
)}
|
||||
</dl>
|
||||
)
|
||||
|
||||
const potentialVolunteerQuestion = enableRegistering && (
|
||||
<div className={styles.inputWrapper}>
|
||||
<div className={styles.leftCol}>
|
||||
<div className={styles.multipleChoiceTitle}>Je veux devenir bénévole :</div>
|
||||
</div>
|
||||
<div className={styles.rightCol}>
|
||||
{["Tout de suite !", "Peut-être après une rencontre avec des bénévoles"].map(
|
||||
(option) => (
|
||||
<label className={styles.longAnswerLabel} key={option}>
|
||||
<input
|
||||
type="radio"
|
||||
name="potentialVolunteer"
|
||||
onChange={sendBooleanRadioboxDispatch(
|
||||
setPotentialVolunteer,
|
||||
option !== "Tout de suite !"
|
||||
)}
|
||||
checked={potentialVolunteer === (option !== "Tout de suite !")}
|
||||
/>{" "}
|
||||
{option}
|
||||
</label>
|
||||
)
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
|
||||
const alreadyVolunteerQuestion = !potentialVolunteer && (
|
||||
<>
|
||||
<div className={styles.inputWrapper}>
|
||||
<div className={styles.leftCol}>
|
||||
<div className={styles.multipleChoiceTitle}>J'ai déjà été bénévole à PeL</div>
|
||||
</div>
|
||||
<div className={styles.rightCol}>
|
||||
<div className={styles.rightColContainer}>
|
||||
{["Oui", "Non"].map((option) => (
|
||||
<label className={styles.shortAnswerLabel} key={option}>
|
||||
<input
|
||||
type="radio"
|
||||
name="alreadyVolunteer"
|
||||
onChange={sendBooleanRadioboxDispatch(
|
||||
setAlreadyVolunteer,
|
||||
option === "Oui"
|
||||
)}
|
||||
checked={alreadyVolunteer === (option === "Oui")}
|
||||
/>{" "}
|
||||
{option}
|
||||
</label>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{alreadyVolunteer && (
|
||||
<dl className={styles.registerIntro}>
|
||||
<dd>
|
||||
<p>Dans ce cas pourquoi t'inscris-tu ici ? ^^</p>
|
||||
<p>
|
||||
Si tu te rappelles de l'email que tu avais utilisé à ta dernière
|
||||
inscription sur le site Force Orange des bénévoles (même sur l'ancienne
|
||||
version) tu peux{" "}
|
||||
<a href="/sidentifier" target="_blank" rel="noreferrer">
|
||||
t'identifier ici
|
||||
</a>{" "}
|
||||
avec ton ancien mot de passe, ou en{" "}
|
||||
<a href="/sinscrire" target="_blank" rel="noreferrer">
|
||||
demander un nouveau ici
|
||||
</a>
|
||||
.
|
||||
</p>
|
||||
<p>
|
||||
Autrement, si tu as changé d'email, mieux vaut nous le communiquer à
|
||||
benevoles@parisestludique.fr en précisant bien tes nom et prénom :)
|
||||
</p>
|
||||
</dd>
|
||||
</dl>
|
||||
)}
|
||||
</>
|
||||
)
|
||||
|
||||
const commentQuestion = (
|
||||
<dl className={styles.inputWrapper}>
|
||||
<dd className={styles.commentWrapper}>
|
||||
@@ -448,10 +339,7 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
const meeting = enableRegistering && (
|
||||
<>
|
||||
<dl className={styles.registerIntro}>
|
||||
{!potentialVolunteer && <dt>Faisons connaissance !</dt>}
|
||||
{potentialVolunteer && (
|
||||
<dt>Se rencontrer avant de se décider à devenir bénévole ?</dt>
|
||||
)}
|
||||
<dt>Faisons connaissance !</dt>
|
||||
<dd>
|
||||
<p>
|
||||
On organise des rencontres entre de nouvelles personnes comme toi, et des
|
||||
@@ -461,23 +349,13 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
<p>
|
||||
Ces rencontres ont lieu à 19h dans un bar/resto calme à Châtelet, le{" "}
|
||||
<a
|
||||
href="https://goo.gl/maps/N5NYWDF66vNQDFMh8"
|
||||
href="https://g.page/lerhinocerosparis?share"
|
||||
id="sfmMap"
|
||||
key="sfmMap"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
>
|
||||
Street Food Market
|
||||
</a>
|
||||
, ou à une soirée festive à 2 pas du lieu du festival, aux{" "}
|
||||
<a
|
||||
href="https://www.captainturtle.fr/aperos-petanque-paris/"
|
||||
id="petanque"
|
||||
key="petanque"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
>
|
||||
apéros de la pétanque
|
||||
Rhinocéros
|
||||
</a>
|
||||
.
|
||||
</p>
|
||||
@@ -535,11 +413,7 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
name="commentFirstMeeting"
|
||||
id="commentFirstMeeting"
|
||||
className={styles.inputWrapper}
|
||||
placeholder={
|
||||
potentialVolunteer
|
||||
? "Mince. Quelles dates t'arrangeraient ? Ou si c'est plus simple, quels jours sont à éviter ? Est-ce trop loin de chez toi ? Préfères-tu nous rencontrer en visio ?"
|
||||
: "Ce n'est pas obligé mais ça aurait été top ! Manques-tu de temps ? Préfères-tu une autre date ? Est-ce trop loin de chez toi ? Préfères-tu nous rencontrer en visio ?"
|
||||
}
|
||||
placeholder="Mince. Quelles dates t'arrangeraient ? Ou si c'est plus simple, quels jours sont à éviter ? Est-ce trop loin de chez toi ? Préfères-tu nous rencontrer en visio ?"
|
||||
value={commentFirstMeeting}
|
||||
onChange={sendTextareaDispatch(setCommentFirstMeeting)}
|
||||
/>
|
||||
@@ -549,79 +423,6 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
</>
|
||||
)
|
||||
|
||||
const helpBefore = enableRegistering && !potentialVolunteer && (
|
||||
<>
|
||||
<dl className={styles.registerIntro}>
|
||||
<dt>Bénévolat en amont du festival</dt>
|
||||
<dd>
|
||||
<p>
|
||||
En tant que bénévole, tu fais selon tes envies, tes disponibilités, ton
|
||||
énergie. Si personne ne veut faire quelque chose de primordial pour le
|
||||
festival, on paye quelqu'un de l'extérieur. Par exemple le transport+montage
|
||||
des tentes+tables, ou la sécurité de nuit sont délégués à des prestataires.
|
||||
Et si ce quelque chose n'est pas primordiale et que personne ne veut s'en
|
||||
occuper, bah tant pis on le fait pas ^^
|
||||
</p>
|
||||
<p>
|
||||
Après on essaye de faire plein de choses sans aide extérieure. Pour le
|
||||
plaisir de collaborer à un projet entre bénévoles parfois devenus amis, pour
|
||||
acquérir de nouvelles compétences, parce que chaque économie d'argent fait
|
||||
baisser le prix d'entrée au festival et contribue à le rendre plus
|
||||
accessible.
|
||||
</p>
|
||||
</dd>
|
||||
</dl>
|
||||
<div className={styles.inputWrapper}>
|
||||
<div className={styles.leftCol}>
|
||||
<div className={styles.multipleChoiceTitle}>
|
||||
Bref, as-tu le temps et l'envie de voir si tu peux aider en amont du
|
||||
festival ?
|
||||
</div>
|
||||
</div>
|
||||
<div className={styles.rightCol}>
|
||||
<div className={styles.rightColContainer}>
|
||||
{[
|
||||
{ value: "oui", desc: "Oui" },
|
||||
{ value: "non", desc: "Non" },
|
||||
{ value: "", desc: "Ne sais pas" },
|
||||
].map((option) => (
|
||||
<label className={styles.shortAnswerLabel} key={option.value}>
|
||||
<input
|
||||
type="radio"
|
||||
name="canHelpBefore"
|
||||
value={option.value}
|
||||
onChange={sendRadioboxDispatch(setCanHelpBefore)}
|
||||
checked={canHelpBefore === option.value}
|
||||
/>{" "}
|
||||
{option.desc}
|
||||
</label>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<dl className={styles.registerIntro}>
|
||||
<dd>
|
||||
{canHelpBefore === "oui" && (
|
||||
<p>
|
||||
Génial ! Quand tu auras fini de t'inscrire et que tu seras identifié sur
|
||||
le site, nous t'en parlerons plus en détail.
|
||||
</p>
|
||||
)}
|
||||
{canHelpBefore === "non" && (
|
||||
<p>
|
||||
Aucun souci tu nous seras d'une aide précieuse le jour J c'est déjà
|
||||
énorme !
|
||||
</p>
|
||||
)}
|
||||
<p>
|
||||
Si tu changes d'avis, il sera possible de revenir sur cette décision dans
|
||||
ton profil sur le site.
|
||||
</p>
|
||||
</dd>
|
||||
</dl>
|
||||
</>
|
||||
)
|
||||
|
||||
const pelMember = enableRegistering && (
|
||||
<>
|
||||
<dl className={styles.registerIntro}>
|
||||
@@ -744,9 +545,7 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
const submitButton = (
|
||||
<>
|
||||
<div className={styles.buttonWrapper}>
|
||||
<FormButton onClick={onSubmit} disabled={!potentialVolunteer && alreadyVolunteer}>
|
||||
Envoyer
|
||||
</FormButton>
|
||||
<FormButton onClick={onSubmit}>Envoyer</FormButton>
|
||||
</div>
|
||||
<div className={styles.formReactions}>
|
||||
{sendingElement}
|
||||
@@ -759,21 +558,13 @@ const RegisterForm = ({ dispatch }: Props): JSX.Element => {
|
||||
return (
|
||||
<form>
|
||||
{intro}
|
||||
{potentialVolunteerQuestion}
|
||||
{alreadyVolunteerQuestion}
|
||||
|
||||
{(potentialVolunteer || !alreadyVolunteer) && (
|
||||
<>
|
||||
{enableRegistering && commentQuestion}
|
||||
{cameAsVisitor}
|
||||
{meeting}
|
||||
{helpBefore}
|
||||
{pelMember}
|
||||
{nameMobileEmail}
|
||||
{!enableRegistering && commentQuestion}
|
||||
{howToContact !== "Aucun" && submitButton}
|
||||
</>
|
||||
)}
|
||||
{enableRegistering && commentQuestion}
|
||||
{cameAsVisitor}
|
||||
{meeting}
|
||||
{pelMember}
|
||||
{nameMobileEmail}
|
||||
{!enableRegistering && commentQuestion}
|
||||
{howToContact !== "Aucun" && submitButton}
|
||||
</form>
|
||||
)
|
||||
}
|
||||
|
@@ -1,6 +1,6 @@
|
||||
import { FC, memo } from "react"
|
||||
// import DayWishes from "./DayWishes/DayWishes"
|
||||
// import DayWishesFormModal from "./DayWishesForm/DayWishesFormModal"
|
||||
import DayWishes from "./DayWishes/DayWishes"
|
||||
import DayWishesFormModal from "./DayWishesForm/DayWishesFormModal"
|
||||
// import Hosting from "./Hosting/Hosting"
|
||||
// import HostingFormModal from "./HostingForm/HostingFormModal"
|
||||
// import Meals from "./Meals/Meals"
|
||||
@@ -12,7 +12,7 @@ import { FC, memo } from "react"
|
||||
// import VolunteerTeam from "./VolunteerTeam/VolunteerTeam"
|
||||
import withUserConnected from "../../utils/withUserConnected"
|
||||
import ContentTitle from "../ui/Content/ContentTitle"
|
||||
// import { fetchFor as fetchForDayWishesForm } from "./DayWishesForm/DayWishesForm"
|
||||
import { fetchFor as fetchForDayWishesForm } from "./DayWishesForm/DayWishesForm"
|
||||
// import { fetchFor as fetchForHostingForm } from "./HostingForm/HostingForm"
|
||||
// import { fetchFor as fetchForMealsForm } from "./MealsForm/MealsForm"
|
||||
// import { fetchFor as fetchForParticipationDetailsForm } from "./ParticipationDetailsForm/ParticipationDetailsForm"
|
||||
@@ -39,9 +39,9 @@ const Board: FC = (): JSX.Element => {
|
||||
{retex && <BrunchFormModal />}
|
||||
{retex && <Retex />}
|
||||
{retex && <RetexFormModal />}
|
||||
{/* <DayWishes />
|
||||
<DayWishesFormModal />
|
||||
<ParticipationDetails />
|
||||
<DayWishes />
|
||||
<DayWishesFormModal />
|
||||
{/* <ParticipationDetails />
|
||||
<ParticipationDetailsFormModal />
|
||||
<TeamWishes />
|
||||
<TeamWishesFormModal />
|
||||
@@ -60,7 +60,7 @@ export const fetchFor = [
|
||||
...fetchForPersonalInfoForm,
|
||||
...fetchForRetexForm,
|
||||
...fetchForBrunchForm,
|
||||
// ...fetchForDayWishesForm,
|
||||
...fetchForDayWishesForm,
|
||||
// ...fetchForHostingForm,
|
||||
// ...fetchForMealsForm,
|
||||
// ...fetchForParticipationDetailsForm,
|
||||
|
@@ -27,7 +27,10 @@ const Brunch: FC<Props> = (): JSX.Element | null => {
|
||||
)}
|
||||
{question1 === 0 && <>Je ne viendrai pas au brunch </>}
|
||||
{question1 > 0 && (
|
||||
<>Je viendrai au brunch{question1 > 1 && <> avec {question1} personne(s)</>}</>
|
||||
<>
|
||||
Je viendrai au brunch
|
||||
{question1 > 1 && <> avec {+question1 - 1} personne(s)</>}
|
||||
</>
|
||||
)}
|
||||
</div>
|
||||
<div className={styles.editButton}>
|
||||
|
@@ -18,22 +18,22 @@ const DayWishes: FC = (): JSX.Element | null => {
|
||||
<div className={styles.title}>Mes présences</div>
|
||||
{participation === "non" && (
|
||||
<div className={styles.participationLabel}>
|
||||
Je <b>ne participerai pas</b> à PeL 2022 :(
|
||||
Je <b>ne participerai pas</b> à PeL 2023 :(
|
||||
</div>
|
||||
)}
|
||||
{participation === "oui" && (
|
||||
<div className={styles.participationLabel}>
|
||||
Je <b className={styles.yesParticipation}>participerai</b> à PeL 2022 !
|
||||
Je <b className={styles.yesParticipation}>participerai</b> à PeL 2023 !
|
||||
</div>
|
||||
)}
|
||||
{participation === "peut-etre" && (
|
||||
<div className={styles.participationLabel}>
|
||||
Je <b>ne sais pas encore</b> si je participerai à PeL 2022
|
||||
Je <b>ne sais pas encore</b> si je participerai à PeL 2023
|
||||
</div>
|
||||
)}
|
||||
{participation === "inconnu" && (
|
||||
<div className={styles.lineEmpty}>
|
||||
Participation à PeL 2022{" "}
|
||||
Participation à PeL 2023{" "}
|
||||
<span className={styles.lineEmpty}>non renseignées</span>
|
||||
</div>
|
||||
)}
|
||||
|
@@ -72,7 +72,7 @@ const DayWishesForm: FC<Props> = ({ children, afterSubmit }): JSX.Element => {
|
||||
<div className={styles.leftCol}>
|
||||
<div className={styles.participationTitle}>
|
||||
Si les conditions sanitaires te le permettent, souhaites-tu être bénévole à
|
||||
PeL 2022 ?
|
||||
PeL les 24 & 25 juin 2023 ?
|
||||
</div>
|
||||
</div>
|
||||
<div className={styles.rightCol}>
|
||||
@@ -124,6 +124,8 @@ const DayWishesForm: FC<Props> = ({ children, afterSubmit }): JSX.Element => {
|
||||
<div className={styles.leftCol}>
|
||||
<div className={styles.dayWishesTitle}>
|
||||
Quels jours viendras-tu ?<br />
|
||||
Il est tôt pour le dire, tu peux y repondre plus tard sur la page profil.
|
||||
<br />
|
||||
(Minimum 2 jours dont l'un sera samedi ou dimanche, idéalement samedi{" "}
|
||||
<b>et</b> dimanche ^^)
|
||||
</div>
|
||||
|
@@ -8,8 +8,10 @@ import DayWishesForm, {
|
||||
import ErrorBoundary from "./ErrorBoundary"
|
||||
import GameList from "./GameList"
|
||||
import Loading from "./Loading"
|
||||
import LoanBoxList, { fetchFor as fetchForLoan } from "./Loan/LoanBoxList"
|
||||
import LoanIntro from "./Loan/LoanIntro"
|
||||
import LoaningIntro from "./Loan/LoaningIntro"
|
||||
import Loaning, { fetchFor as fetchForLoaning } from "./Loan/Loaning"
|
||||
import LoansIntro from "./Loan/LoansIntro"
|
||||
import Loans, { fetchFor as fetchForLoans } from "./Loan/Loans"
|
||||
import LoginForm from "./LoginForm"
|
||||
import KnowledgeBoxList, { fetchFor as fetchForKnowledge } from "./Knowledge/KnowledgeBoxList"
|
||||
import KnowledgeCard, { fetchFor as fetchForKnowledgeCard } from "./Knowledge/KnowledgeCard"
|
||||
@@ -45,9 +47,12 @@ export {
|
||||
fetchForKnowledge,
|
||||
KnowledgeIntro,
|
||||
Loading,
|
||||
LoanBoxList,
|
||||
fetchForLoan,
|
||||
LoanIntro,
|
||||
LoaningIntro,
|
||||
Loaning,
|
||||
fetchForLoaning,
|
||||
LoansIntro,
|
||||
Loans,
|
||||
fetchForLoans,
|
||||
LoginForm,
|
||||
Asks,
|
||||
fetchForAsks,
|
||||
|
Reference in New Issue
Block a user