summaryrefslogtreecommitdiff
path: root/frontend
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2021-09-07 17:16:38 +0200
committerJules Laplace <julescarbon@gmail.com>2021-09-07 17:16:38 +0200
commit3bf200cb4339e906b944d55451cfacc8aa33bb01 (patch)
treef0da6480d866b907cae7b258a3e56a1a7b827aae /frontend
parent30aff969375213db8c66af5f108496f465057787 (diff)
comment everything and add notes on working on the last museum
Diffstat (limited to 'frontend')
-rw-r--r--frontend/app/utils/index.js3
-rw-r--r--frontend/app/views/page/components/page.editor.js2
-rw-r--r--frontend/app/views/tile/components/tile.form.js2
-rw-r--r--frontend/site/projects/museum/app/index.js4
-rw-r--r--frontend/site/projects/museum/app/revisions.js3
-rw-r--r--frontend/site/projects/museum/constants.js42
-rw-r--r--frontend/site/projects/museum/export.js4
-rw-r--r--frontend/site/projects/museum/icons.js4
-rw-r--r--frontend/site/projects/museum/museum.actions.js4
-rw-r--r--frontend/site/projects/museum/stl-files.js4
-rw-r--r--frontend/site/projects/museum/subtitles.js4
-rw-r--r--frontend/site/projects/museum/text-overlays.js4
-rw-r--r--frontend/site/projects/museum/views/_subtitles.overlay.js4
-rw-r--r--frontend/site/projects/museum/views/artists.css3
-rw-r--r--frontend/site/projects/museum/views/artists.js4
-rw-r--r--frontend/site/projects/museum/views/counter.js4
-rw-r--r--frontend/site/projects/museum/views/credits.js4
-rw-r--r--frontend/site/projects/museum/views/essay.js4
-rw-r--r--frontend/site/projects/museum/views/flash.js4
-rw-r--r--frontend/site/projects/museum/views/home.js4
-rw-r--r--frontend/site/projects/museum/views/jakrawal.links.js4
-rw-r--r--frontend/site/projects/museum/views/landscape.warning.js4
-rw-r--r--frontend/site/projects/museum/views/marquee.js4
-rw-r--r--frontend/site/projects/museum/views/nav.overlay.js4
-rw-r--r--frontend/site/projects/museum/views/stl.overlay.js4
-rw-r--r--frontend/site/projects/museum/views/text.overlay.js4
-rw-r--r--frontend/site/projects/museum/views/titles.overlay.js4
27 files changed, 131 insertions, 8 deletions
diff --git a/frontend/app/utils/index.js b/frontend/app/utils/index.js
index 400637e..95660c5 100644
--- a/frontend/app/utils/index.js
+++ b/frontend/app/utils/index.js
@@ -152,8 +152,9 @@ export const preloadImage = url => (
})
)
-export const preloadVideo = (url, { canplaythrough }) => (
+export const preloadVideo = (url, options = {}) => (
new Promise((resolve, reject) => {
+ const { canplaythrough } = options
const video = document.createElement('video')
let loaded = false
const bind = () => {
diff --git a/frontend/app/views/page/components/page.editor.js b/frontend/app/views/page/components/page.editor.js
index a64edb2..84740d5 100644
--- a/frontend/app/views/page/components/page.editor.js
+++ b/frontend/app/views/page/components/page.editor.js
@@ -54,7 +54,7 @@ class PageEditor extends Component {
width: rect.width,
height: rect.height,
}
- // console.log(bounds)
+ console.log("bounds", bounds)
return bounds
}
diff --git a/frontend/app/views/tile/components/tile.form.js b/frontend/app/views/tile/components/tile.form.js
index a3c3131..2f805a6 100644
--- a/frontend/app/views/tile/components/tile.form.js
+++ b/frontend/app/views/tile/components/tile.form.js
@@ -232,7 +232,7 @@ class TileForm extends Component {
const { name, value } = e.target
this.handleSettingsSelect(name, value)
preloadVideo(value).then(video => {
- // console.log(img)
+ console.log(video.videoWidth, video.videoHeight)
this.props.tileActions.updateTemporaryTile({
...this.props.temporaryTile,
settings: {
diff --git a/frontend/site/projects/museum/app/index.js b/frontend/site/projects/museum/app/index.js
index 985d422..22a9ba5 100644
--- a/frontend/site/projects/museum/app/index.js
+++ b/frontend/site/projects/museum/app/index.js
@@ -1,3 +1,7 @@
+/**
+ * Site router and custom pages
+ */
+
import React, { Component } from 'react'
import { ConnectedRouter } from 'connected-react-router'
import { Route } from 'react-router'
diff --git a/frontend/site/projects/museum/app/revisions.js b/frontend/site/projects/museum/app/revisions.js
index fcd8392..4366379 100644
--- a/frontend/site/projects/museum/app/revisions.js
+++ b/frontend/site/projects/museum/app/revisions.js
@@ -1,3 +1,6 @@
+/**
+ * On-the-fly modifications to the database (use sparingly)
+ */
import { isMobile } from "app/utils"
diff --git a/frontend/site/projects/museum/constants.js b/frontend/site/projects/museum/constants.js
index 87b9ed7..e9bb4f4 100644
--- a/frontend/site/projects/museum/constants.js
+++ b/frontend/site/projects/museum/constants.js
@@ -1,4 +1,34 @@
+/**
+ * Artist statements and links
+ */
+
+export const ARTIST_ORDER = [
+ "petros", "stankievech", "nora", "leite", "opoku", "foreshew", "nilthamrong",
+]
+
export const ARTISTS = {
+ petros: {
+ name: "Petros Moris",
+ location: {
+ en: "Athens, Greece",
+ de: "Athens, Greece",
+ },
+ start: "petros-1",
+ homepage: "http://petrosmoris.com/",
+ bio: {
+ en: `<p>TBD</p>`,
+ de: `<p>TBD</p>`,
+ },
+ statement: {
+ en: `<p>TBD</p>`,
+ de: `<p>TBD</p>`,
+ },
+ image: "/thelastmuseum/static/media/last-museum/artist-bio/nora.jpg",
+ globePosition: {
+ top: "15.1%",
+ left: "47.7%",
+ },
+ },
nora: {
name: "Nora Al-Badri",
location: {
@@ -340,12 +370,12 @@ export const ARTISTS = {
}
}
-export const ARTIST_ORDER = [
- "stankievech", "nora", "leite", "opoku", "foreshew", "nilthamrong",
-]
-
export const PROJECT_PAGE_SET = new Set(["essay", "artists", "credits"])
+/**
+ * Essays
+ */
+
export const ESSAYS = {
nadim: { title: "Curator's Essay", author: "Nadim Samman", },
statements: { title: "Artist Statements", author: "", },
@@ -533,6 +563,10 @@ export const ESSAY_TEXTS = {
}
}
+/**
+ * Marquees (i.e. Zohra)
+ */
+
export const MARQUEES = {
'opoku-1-hail-to-you': {
en: 'Hail to you, lords of truth, free from wrongdoing, who exist forever and forever. I have reached you because I am an akh with my forms. I am powerful through my magic. Going forth by day / Papyrus of Sobekmose / Book of the Dead ...',
diff --git a/frontend/site/projects/museum/export.js b/frontend/site/projects/museum/export.js
index 7116ceb..ab25eda 100644
--- a/frontend/site/projects/museum/export.js
+++ b/frontend/site/projects/museum/export.js
@@ -1,3 +1,7 @@
+/**
+ * Export the text content of the site to the index.html
+ */
+
import { ARTISTS, ESSAY_TEXTS, CREDITS_STRINGS } from "./constants"
import fs from 'fs'
diff --git a/frontend/site/projects/museum/icons.js b/frontend/site/projects/museum/icons.js
index 4517787..c809dae 100644
--- a/frontend/site/projects/museum/icons.js
+++ b/frontend/site/projects/museum/icons.js
@@ -1,3 +1,7 @@
+/**
+ * SVG images
+ */
+
import React from 'react'
export const ArrowLeft = (
diff --git a/frontend/site/projects/museum/museum.actions.js b/frontend/site/projects/museum/museum.actions.js
index 40d62a1..807a483 100644
--- a/frontend/site/projects/museum/museum.actions.js
+++ b/frontend/site/projects/museum/museum.actions.js
@@ -1,3 +1,7 @@
+/**
+ * Load the site graph
+ */
+
import * as types from 'site/types'
import FontFaceObserver from 'fontfaceobserver'
import actions from 'site/actions'
diff --git a/frontend/site/projects/museum/stl-files.js b/frontend/site/projects/museum/stl-files.js
index 365c8a8..8ec0787 100644
--- a/frontend/site/projects/museum/stl-files.js
+++ b/frontend/site/projects/museum/stl-files.js
@@ -1,3 +1,7 @@
+/**
+ * STL Files - 3D assets
+ */
+
export const STL_FILES = {
"nora-nefertiti": {
diff --git a/frontend/site/projects/museum/subtitles.js b/frontend/site/projects/museum/subtitles.js
index 1f136f1..b49798e 100644
--- a/frontend/site/projects/museum/subtitles.js
+++ b/frontend/site/projects/museum/subtitles.js
@@ -1,3 +1,7 @@
+/**
+ * Subtitles, though not totally used this way, i.e. Charles pages
+ */
+
export const SUBTITLES = {
'foreshew-1': {
title: '<i>Dhurany Yanggu</i>',
diff --git a/frontend/site/projects/museum/text-overlays.js b/frontend/site/projects/museum/text-overlays.js
index 91ed268..5a38d12 100644
--- a/frontend/site/projects/museum/text-overlays.js
+++ b/frontend/site/projects/museum/text-overlays.js
@@ -1,3 +1,7 @@
+/**
+ * Text overlays: Click an icon to see a text, which appears like a modal.
+ */
+
export const DEFAULT_ICON = "/thelastmuseum/static/uploads/3/cursor/The_Last_Museum_-_Symbols-72.png"
export const DEFAULT_CLOSED_ICON = "/thelastmuseum/static/uploads/3/cursor/The_Last_Museum_-_Symbols-41.png"
diff --git a/frontend/site/projects/museum/views/_subtitles.overlay.js b/frontend/site/projects/museum/views/_subtitles.overlay.js
index 6d5a32a..ad41e9e 100644
--- a/frontend/site/projects/museum/views/_subtitles.overlay.js
+++ b/frontend/site/projects/museum/views/_subtitles.overlay.js
@@ -1,3 +1,7 @@
+/**
+ * Subtitles for Charles Stankievech
+ */
+
import React, { Component } from 'react'
import { connect } from 'react-redux'
diff --git a/frontend/site/projects/museum/views/artists.css b/frontend/site/projects/museum/views/artists.css
index fb20fb7..c4546b5 100644
--- a/frontend/site/projects/museum/views/artists.css
+++ b/frontend/site/projects/museum/views/artists.css
@@ -27,7 +27,8 @@
transition: color 0.1s;
}
.page-artists .artist-big-name {
- font-size: 17.4vh;
+ /* font-size: 17.4vh; */
+ font-size: 15vh;
text-shadow: 0 0 10px #FF790D;
transition: text-shadow 0.2s;
}
diff --git a/frontend/site/projects/museum/views/artists.js b/frontend/site/projects/museum/views/artists.js
index b6af721..d90901e 100644
--- a/frontend/site/projects/museum/views/artists.js
+++ b/frontend/site/projects/museum/views/artists.js
@@ -1,3 +1,7 @@
+/**
+ * Artist bios
+ */
+
import React, { Component } from 'react'
import { Link } from 'react-router-dom'
import { connect } from 'react-redux'
diff --git a/frontend/site/projects/museum/views/counter.js b/frontend/site/projects/museum/views/counter.js
index 9322bfa..56196b8 100644
--- a/frontend/site/projects/museum/views/counter.js
+++ b/frontend/site/projects/museum/views/counter.js
@@ -1,3 +1,7 @@
+/**
+ * Population counter for Jakrawal
+ */
+
import React, { Component, createRef } from 'react'
import { commatize } from "app/utils"
diff --git a/frontend/site/projects/museum/views/credits.js b/frontend/site/projects/museum/views/credits.js
index e598c82..8b70aa8 100644
--- a/frontend/site/projects/museum/views/credits.js
+++ b/frontend/site/projects/museum/views/credits.js
@@ -1,3 +1,7 @@
+/**
+ * Credits
+ */
+
import React, { Component } from 'react'
import { connect } from 'react-redux'
import actions from 'site/actions'
diff --git a/frontend/site/projects/museum/views/essay.js b/frontend/site/projects/museum/views/essay.js
index f9b9058..d398b54 100644
--- a/frontend/site/projects/museum/views/essay.js
+++ b/frontend/site/projects/museum/views/essay.js
@@ -1,3 +1,7 @@
+/**
+ * Essays / texts / artist statements
+ */
+
import React, { Component } from 'react'
import { connect } from 'react-redux'
import actions from 'site/actions'
diff --git a/frontend/site/projects/museum/views/flash.js b/frontend/site/projects/museum/views/flash.js
index 74cb9ec..bb7a717 100644
--- a/frontend/site/projects/museum/views/flash.js
+++ b/frontend/site/projects/museum/views/flash.js
@@ -1,3 +1,7 @@
+/**
+ * An orange flash when navigating from page to page
+ */
+
import React, { Component } from 'react'
import "./flash.css"
diff --git a/frontend/site/projects/museum/views/home.js b/frontend/site/projects/museum/views/home.js
index 83aaa09..9c06c10 100644
--- a/frontend/site/projects/museum/views/home.js
+++ b/frontend/site/projects/museum/views/home.js
@@ -1,3 +1,7 @@
+/**
+ * Start page interaction
+ */
+
import React, { Component } from 'react'
import { connect } from 'react-redux'
diff --git a/frontend/site/projects/museum/views/jakrawal.links.js b/frontend/site/projects/museum/views/jakrawal.links.js
index 2447728..991b43b 100644
--- a/frontend/site/projects/museum/views/jakrawal.links.js
+++ b/frontend/site/projects/museum/views/jakrawal.links.js
@@ -1,3 +1,7 @@
+/**
+ * Links on Jakrawal's site are added programmatically for "lateral" navigation
+ */
+
import React, { Component } from 'react'
import { connect } from 'react-redux'
diff --git a/frontend/site/projects/museum/views/landscape.warning.js b/frontend/site/projects/museum/views/landscape.warning.js
index a5f794e..84483bc 100644
--- a/frontend/site/projects/museum/views/landscape.warning.js
+++ b/frontend/site/projects/museum/views/landscape.warning.js
@@ -1,3 +1,7 @@
+/**
+ * Instruction to rotate the phone to landscape
+ */
+
import React, { Component } from 'react'
import './landscape.warning.css'
diff --git a/frontend/site/projects/museum/views/marquee.js b/frontend/site/projects/museum/views/marquee.js
index bd47b39..c1efa76 100644
--- a/frontend/site/projects/museum/views/marquee.js
+++ b/frontend/site/projects/museum/views/marquee.js
@@ -1,3 +1,7 @@
+/**
+ * Marquees i.e. for Zohra
+ */
+
import React, { Component } from 'react'
import Marquee from "react-smooth-marquee"
diff --git a/frontend/site/projects/museum/views/nav.overlay.js b/frontend/site/projects/museum/views/nav.overlay.js
index 82b9151..921f751 100644
--- a/frontend/site/projects/museum/views/nav.overlay.js
+++ b/frontend/site/projects/museum/views/nav.overlay.js
@@ -1,3 +1,7 @@
+/**
+ * Top-level navigation overlay, mute button, language toggle, exit link.
+ */
+
import React, { Component } from 'react'
import { connect } from 'react-redux'
import { Link } from 'react-router-dom'
diff --git a/frontend/site/projects/museum/views/stl.overlay.js b/frontend/site/projects/museum/views/stl.overlay.js
index 2e2c417..4fd8e80 100644
--- a/frontend/site/projects/museum/views/stl.overlay.js
+++ b/frontend/site/projects/museum/views/stl.overlay.js
@@ -1,3 +1,7 @@
+/**
+ * Display an STL file in a 3D viewer i.e. for Nora
+ */
+
import React, { Component } from 'react'
import { connect } from 'react-redux'
diff --git a/frontend/site/projects/museum/views/text.overlay.js b/frontend/site/projects/museum/views/text.overlay.js
index 862e0b2..63cf585 100644
--- a/frontend/site/projects/museum/views/text.overlay.js
+++ b/frontend/site/projects/museum/views/text.overlay.js
@@ -1,3 +1,7 @@
+/**
+ * Text overlays - click an icon to see a text for Nora
+ */
+
import React, { Component } from 'react'
import { connect } from 'react-redux'
diff --git a/frontend/site/projects/museum/views/titles.overlay.js b/frontend/site/projects/museum/views/titles.overlay.js
index 5c51924..167b86d 100644
--- a/frontend/site/projects/museum/views/titles.overlay.js
+++ b/frontend/site/projects/museum/views/titles.overlay.js
@@ -1,3 +1,7 @@
+/**
+ * Custom interactions for Charles Stankievech
+ */
+
import React, { Component } from 'react'
import { connect } from 'react-redux'