diff options
Diffstat (limited to 'frontend/site')
| -rw-r--r-- | frontend/site/projects/museum/views/jakrawal.links.css | 8 | ||||
| -rw-r--r-- | frontend/site/viewer/viewer.container.js | 18 |
2 files changed, 24 insertions, 2 deletions
diff --git a/frontend/site/projects/museum/views/jakrawal.links.css b/frontend/site/projects/museum/views/jakrawal.links.css index 96cc0d3..ca70885 100644 --- a/frontend/site/projects/museum/views/jakrawal.links.css +++ b/frontend/site/projects/museum/views/jakrawal.links.css @@ -5,10 +5,12 @@ width: 20%; min-width: 140px; height: 100%; +/* background-image: url(/last-museum/static/media/last-museum/jakrawal-nilthamrong/left.png); background-position: left 40px center; background-repeat: no-repeat; - cursor: url(/last-museum/static/uploads/3/cursor/The_Last_Museum_-_Symbols-102.png) 50 50, pointer; +*/ + cursor: url(/last-museum/static/media/last-museum/jakrawal-nilthamrong/left.png) 50 50, pointer; } .jakrawal-right { @@ -18,10 +20,12 @@ width: 20%; min-width: 140px; height: 100%; +/* background-image: url(/last-museum/static/media/last-museum/jakrawal-nilthamrong/right.png); background-position: right 40px center; background-repeat: no-repeat; - cursor: url(/last-museum/static/uploads/3/cursor/The_Last_Museum_-_Symbols-102.png) 50 50, pointer; +*/ + cursor: url(/last-museum/static/media/last-museum/jakrawal-nilthamrong/right.png) 50 50, pointer; } .jakrawal-text { diff --git a/frontend/site/viewer/viewer.container.js b/frontend/site/viewer/viewer.container.js index aae8990..46ef0d0 100644 --- a/frontend/site/viewer/viewer.container.js +++ b/frontend/site/viewer/viewer.container.js @@ -26,6 +26,8 @@ class ViewerContainer extends Component { this.pageRef = React.createRef() this.handleMouseDown = this.handleMouseDown.bind(this) this.handleResize = this.handleResize.bind(this) + this.handleMouseEnter = this.handleMouseEnter.bind(this) + this.handleMouseLeave = this.handleMouseLeave.bind(this) this.removeRoadblock = this.removeRoadblock.bind(this) this.updateTimer = this.updateTimer.bind(this) window.addEventListener('resize', this.handleResize) @@ -163,6 +165,21 @@ class ViewerContainer extends Component { restart: true, }) } + if (tile.settings.show_popup_on_hover && tile.settings.on_hover_popup) { + actions.site.setPopups({ + ...this.props.popups, + [tile.settings.on_hover_popup]: true, + }) + } + } + + handleMouseLeave(e, tile) { + if (tile.settings.show_popup_on_hover && tile.settings.on_hover_popup) { + actions.site.setPopups({ + ...this.props.popups, + [tile.settings.on_hover_popup]: false, + }) + } } handlePlaybackEnded(tile) { @@ -218,6 +235,7 @@ class ViewerContainer extends Component { onPlaybackEnded={e => this.handlePlaybackEnded(e, tile)} onDoubleClick={e => {}} onMouseEnter={e => this.handleMouseEnter(e, tile)} + onMouseLeave={e => this.handleMouseLeave(e, tile)} /> ) })} |
