Hide schedule and tracks when stands are selected
This commit is contained in:
parent
97e9a15d9e
commit
570f136ef8
|
@ -53,39 +53,41 @@ export default function Schedule({
|
||||||
{isLoading && <progress value={loadingProgress}/>}
|
{isLoading && <progress value={loadingProgress}/>}
|
||||||
{isComplete && <div className="schedule">
|
{isComplete && <div className="schedule">
|
||||||
<hr/>
|
<hr/>
|
||||||
<table>
|
{rows.length > 0 && <>
|
||||||
{header.length > 0 && <thead>
|
<table>
|
||||||
<tr>
|
{header.length > 0 && <thead>
|
||||||
{header.map(hall => <th key={hall.id}>{hall.name[lang]}</th>)}
|
<tr>
|
||||||
</tr>
|
{header.map(hall => <th key={hall.id}>{hall.name[lang]}</th>)}
|
||||||
</thead>}
|
</tr>
|
||||||
<tbody>
|
</thead>}
|
||||||
{rows.map(row => <tr key={row.id}>
|
<tbody>
|
||||||
{row.cells.map(cell => <td key={cell.id} {...cell.attributes}>
|
{rows.map(row => <tr key={row.id}>
|
||||||
{cell.dateHeader && <DateHeader date={cell.dateHeader} lang={lang} />}
|
{row.cells.map(cell => <td key={cell.id} {...cell.attributes}>
|
||||||
{cell.timeSlot && <TimeSlot {...cell.timeSlot} />}
|
{cell.dateHeader && <DateHeader date={cell.dateHeader} lang={lang} />}
|
||||||
{cell.event && <Event {...cell.event} />}
|
{cell.timeSlot && <TimeSlot {...cell.timeSlot} />}
|
||||||
</td>)}
|
{cell.event && <Event {...cell.event} />}
|
||||||
</tr>)}
|
</td>)}
|
||||||
</tbody>
|
</tr>)}
|
||||||
{header.length > 0 && <tfoot>
|
</tbody>
|
||||||
<tr>
|
{header.length > 0 && <tfoot>
|
||||||
{header.map(hall => <th key={hall.id}>{hall.name[lang]}</th>)}
|
<tr>
|
||||||
</tr>
|
{header.map(hall => <th key={hall.id}>{hall.name[lang]}</th>)}
|
||||||
</tfoot>}
|
</tr>
|
||||||
</table>
|
</tfoot>}
|
||||||
<div className="separator" />
|
</table>
|
||||||
<table>
|
<div className="separator" />
|
||||||
<tbody>
|
<table>
|
||||||
{tracks.filter(track => !isTrackHidden(track)).map(track => <tr key={track.id}>
|
<tbody>
|
||||||
<td className={track.css_class}>{track.name[lang]}</td>
|
{tracks.filter(track => !isTrackHidden(track)).map(track => <tr key={track.id}>
|
||||||
</tr>)}
|
<td className={track.css_class}>{track.name[lang]}</td>
|
||||||
{Object.entries(langs).map(([langId, langName]) => <tr key={langId}>
|
</tr>)}
|
||||||
<td className={'schedule-'.concat(langId)}>{langName}</td>
|
{Object.entries(langs).map(([langId, langName]) => <tr key={langId}>
|
||||||
</tr>)}
|
<td className={'schedule-'.concat(langId)}>{langName}</td>
|
||||||
</tbody>
|
</tr>)}
|
||||||
</table>
|
</tbody>
|
||||||
<div className="separator" />
|
</table>
|
||||||
|
<div className="separator" />
|
||||||
|
</>}
|
||||||
{events.map(event => <section key={event.id} id={'event-'.concat(event.id)}>
|
{events.map(event => <section key={event.id} id={'event-'.concat(event.id)}>
|
||||||
<p>
|
<p>
|
||||||
<strong>{event.title}</strong>
|
<strong>{event.title}</strong>
|
||||||
|
|
Loading…
Reference in New Issue