From a9d86650f40a82a64d1fd8e0525c26422d314d3a Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Tue, 16 Mar 2021 16:38:07 +0100 Subject: make uploads like animism. start audio stuff --- frontend/app/views/page/components/page.header.js | 3 ++- frontend/app/views/page/components/tile.edit.js | 4 +++- frontend/app/views/page/components/tile.handle.js | 1 - 3 files changed, 5 insertions(+), 3 deletions(-) (limited to 'frontend/app/views/page/components') diff --git a/frontend/app/views/page/components/page.header.js b/frontend/app/views/page/components/page.header.js index eb1c3b9..998572a 100644 --- a/frontend/app/views/page/components/page.header.js +++ b/frontend/app/views/page/components/page.header.js @@ -10,7 +10,8 @@ function PageHeader(props) { return (
- {props.site.siteTitle} + {"◁"} + {props.site.siteTitle}
diff --git a/frontend/app/views/page/components/tile.edit.js b/frontend/app/views/page/components/tile.edit.js index 2ea09d1..cae9f73 100644 --- a/frontend/app/views/page/components/tile.edit.js +++ b/frontend/app/views/page/components/tile.edit.js @@ -29,7 +29,9 @@ class TileEdit extends Component { load() { const { currentEditTileId } = this.props.page.editor - const tile = this.props.page.show.res.tiles.filter(tile => tile.id === currentEditTileId)[0] + const { tiles } = this.props.page.show.res + if (!tiles) return + const tile = tiles.filter(tile => tile.id === currentEditTileId)[0] console.log('edit', currentEditTileId) this.setState({ tile }) } diff --git a/frontend/app/views/page/components/tile.handle.js b/frontend/app/views/page/components/tile.handle.js index 9331cb3..f47c3cd 100644 --- a/frontend/app/views/page/components/tile.handle.js +++ b/frontend/app/views/page/components/tile.handle.js @@ -151,7 +151,6 @@ const generateTransform = (tile, box) => { if (xalign === 'center') { transform.push('translateX(-50%)') } - console.log(units) // if (x % 2 == 1) x += 0.5 // if (y % 2 == 1) y += 0.5 transform.push('translateX(' + x + units + ')') -- cgit v1.2.3-70-g09d2