From 2b6faa507945100a04a0d63a0d93627411e68632 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Thu, 1 Oct 2020 02:51:25 +0200 Subject: schedule from db --- .../frontend/app/views/site/site.actions.js | 3 +- .../player/components.inline/inline.utility.js | 66 ++++++++++++---------- .../app/views/viewer/player/player.transcript.css | 6 ++ 3 files changed, 43 insertions(+), 32 deletions(-) (limited to 'animism-align/frontend/app/views') diff --git a/animism-align/frontend/app/views/site/site.actions.js b/animism-align/frontend/app/views/site/site.actions.js index ee6c523..d1c1e66 100644 --- a/animism-align/frontend/app/views/site/site.actions.js +++ b/animism-align/frontend/app/views/site/site.actions.js @@ -9,6 +9,8 @@ export const loadProject = () => dispatch => { actions.annotation.index(), actions.paragraph.index(), actions.media.index(), + actions.episode.index(), + actions.venue.index(), ]).then(() => { actions.viewer.loadSections() }).catch(err => { @@ -27,4 +29,3 @@ export const loadText = (asdf) => dispatch => ( export const updateText = text => dispatch => ( dispatch({ type: types.text.loaded, data: text }) ) - diff --git a/animism-align/frontend/app/views/viewer/player/components.inline/inline.utility.js b/animism-align/frontend/app/views/viewer/player/components.inline/inline.utility.js index d2e434f..486b8e5 100644 --- a/animism-align/frontend/app/views/viewer/player/components.inline/inline.utility.js +++ b/animism-align/frontend/app/views/viewer/player/components.inline/inline.utility.js @@ -1,4 +1,5 @@ import React, { Component } from 'react' +import { connect } from 'react-redux' import { MediaCitation } from '../components.media' @@ -35,26 +36,35 @@ export const Intro = ({ paragraph, media, onAnnotationClick }) => { ) } -export const Schedule = ({ media }) => { - const nameLookup = Object.values(media.lookup).reduce((a,b) => { - a.add(b.author) - return a - }, new Set) +const ScheduleComponent = ({ episodes, venues }) => { + console.log(episodes.lookup[episodes.order[0]]) + const currentEpisode = episodes.lookup[episodes.order[0]].settings return (
+
+ {'Animism on e-flux.com is the ninth iteration of the exhibition and overall '} + {'research project presented at Extra City and MuHKA, Antwerp, 2010; Kunsthalle '} + {'Bern, 2010; Generali Foundation, Vienna, 2011; the Haus der Kulturen der Welt, '} + {'Berlin, 2012; e-flux, New York, 2012; OCAT Shenzhen, 2013; Times Museum Seoul, '} + {'2013; and Ashkal Alwan, Beirut, 2014. Presented here in its digital iteration, '} + {'the exhibition will be released in four episodes starting October 2020.'} +
Schedule
- {SCHEDULE.map(row => ( -
-
- {row.date} -
-
- {'Episode '}{row.id}{': '} - {row.title} + {episodes.order.map(id => { + const episode = episodes.lookup[id] + return ( +
+
+ {episode.release_date} +
+
+ {'Episode '}{episode.episode_number}{': '} + {episode.title} +
-
- ))} + ) + })}
@@ -62,15 +72,15 @@ export const Schedule = ({ media }) => { Curator
- {ABOUT.curator} + {currentEpisode.curator}
- Authors + Author
- {ABOUT.authors} + {currentEpisode.author}
@@ -78,7 +88,7 @@ export const Schedule = ({ media }) => { Artists
- {Array.from(nameLookup).sort().join("\n")} + {currentEpisode.artists}
@@ -86,16 +96,10 @@ export const Schedule = ({ media }) => { ) } -const SCHEDULE = [ - { id: 1, active: true, date: 'Mon 00-00, 2020', title: 'Animist Origins & Export Projections' }, - { id: 2, active: false, date: 'Mon 00-00, 2020', title: 'Animation & The Mummy Complex: The Museum' }, - { id: 3, active: false, date: 'Mon 00-00, 2020', title: 'The Extirpation of Animism' }, - { id: 4, active: false, date: 'Mon 00-00, 2020', title: 'Media History & Animism\'s Continuous Displacement' }, - { id: 5, active: false, date: 'Mon 00-00, 2020', title: 'Soul-Design or Liminal Cosmologies' }, - { id: 6, active: false, date: 'Mon 00-00, 2020', title: 'Animal, Mythic and Other' }, -] +const mapStateToProps = state => ({ + episodes: state.episode.index, + episode: state.episode.show.res || {}, + venues: state.venue.index, +}) -const ABOUT = { - curator: "Anselm Franke", - authors: "Anselm Franke\nAmal Issa", -} +export const Schedule = connect(mapStateToProps)(ScheduleComponent) \ No newline at end of file diff --git a/animism-align/frontend/app/views/viewer/player/player.transcript.css b/animism-align/frontend/app/views/viewer/player/player.transcript.css index 03a73ac..4ea459b 100644 --- a/animism-align/frontend/app/views/viewer/player/player.transcript.css +++ b/animism-align/frontend/app/views/viewer/player/player.transcript.css @@ -274,6 +274,12 @@ /* schedule */ +.schedule-about { + width: 45rem; + margin: 0 auto; + margin-top: 1rem; + line-height: 1.3; +} .schedule { width: 45rem; display: flex; -- cgit v1.2.3-70-g09d2