generated from partypages/party-template
This commit is contained in:
parent
bfe2c9a6e3
commit
6a777967d4
@ -4,12 +4,12 @@ import './PartyPage.css';
|
||||
import { modifySelfRequest } from './partyApi';
|
||||
|
||||
export const PartyPage: React.FC = () => {
|
||||
const {self: me, endpoint, refresh} = useContext(PartyContext);
|
||||
const { self: me, endpoint, refresh } = useContext(PartyContext);
|
||||
const setComing = async (value: SelfStatus["coming"]) => {
|
||||
await modifySelfRequest(endpoint, { coming: value });
|
||||
await refresh();
|
||||
}
|
||||
|
||||
|
||||
return <div>
|
||||
<p>
|
||||
<h1>
|
||||
@ -25,10 +25,10 @@ export const PartyPage: React.FC = () => {
|
||||
from the 1<sup>st<sup>th</sup></sup> of August, Jesko's back — finally!
|
||||
</p>
|
||||
<p>
|
||||
We will celebrate his back on the 4<sup>st</sup> of August and <i>you</i> are invited!!!!
|
||||
We will celebrate his back on the <s>4<sup>st</sup> of August</s> 19<sup>nd</sup> of August and <i>you</i> are invited!!!!
|
||||
</p>
|
||||
<p>
|
||||
Come to <span style={{color: "blue", textDecoration: "underline", cursor: "pointer"}}>Mainzer Straße 28</span> from 19:00pm.
|
||||
Come to <span style={{ color: "blue", textDecoration: "underline", cursor: "pointer" }}>Mainzer Straße 28</span> from 19:00pm.
|
||||
</p>
|
||||
<p>
|
||||
Please tell us, if you are coming:
|
||||
@ -39,15 +39,15 @@ export const PartyPage: React.FC = () => {
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Yes</td>
|
||||
<td><input type="checkbox" onClick={() =>setComing("yes")} checked={me.coming === "yes"} /></td>
|
||||
<td><input type="checkbox" onClick={() => setComing("yes")} checked={me.coming === "yes"} /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>No</td>
|
||||
<td><input type="checkbox" onClick={() =>setComing("no")} checked={me.coming === "no"} /></td>
|
||||
<td><input type="checkbox" onClick={() => setComing("no")} checked={me.coming === "no"} /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Maybe</td>
|
||||
<td><input type="checkbox" onClick={() =>setComing("maybe")} checked={me.coming === "maybe" || !me.coming} /></td>
|
||||
<td><input type="checkbox" onClick={() => setComing("maybe")} checked={me.coming === "maybe" || !me.coming} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</p>
|
||||
|
Loading…
Reference in New Issue
Block a user