summaryrefslogtreecommitdiff
path: root/frontend/app/views/page/components/tile.handle.js
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2021-03-17 18:58:04 +0100
committerJules Laplace <julescarbon@gmail.com>2021-03-17 18:58:04 +0100
commitd9fc65fe05f534691597586f25a2f168364ae1cf (patch)
treec06eccb4f2d8384270746ddb78f7971b6d67f3ac /frontend/app/views/page/components/tile.handle.js
parent2313cc4bb4d6c511c76d28020c1c97e6a5eb0a4d (diff)
cancel playback if background audio id changes
Diffstat (limited to 'frontend/app/views/page/components/tile.handle.js')
-rw-r--r--frontend/app/views/page/components/tile.handle.js35
1 files changed, 10 insertions, 25 deletions
diff --git a/frontend/app/views/page/components/tile.handle.js b/frontend/app/views/page/components/tile.handle.js
index 090069d..d7b5d05 100644
--- a/frontend/app/views/page/components/tile.handle.js
+++ b/frontend/app/views/page/components/tile.handle.js
@@ -94,31 +94,16 @@ const TileHandle = ({ tile, bounds, box, viewing, onMouseDown, onDoubleClick })
content = "SCRIPT"
}
}
- if (viewing && tile.href) {
- if (tile.href.indexOf('http') === 0) {
- return (
- <a href={tile.href} rel='noopener'>
- <div
- className={className}
- style={style}
- >
- {content}
- </div>
- </a>
- )
- } else {
- return (
- <Link to={tile.href}>
- <div
- className={className}
- onMouseDown={onMouseDown}
- style={style}
- >
- {content}
- </div>
- </Link>
- )
- }
+ if (viewing) {
+ return (
+ <div
+ className={className}
+ onMouseDown={onMouseDown}
+ style={style}
+ >
+ {content}
+ </div>
+ )
} else {
return (
<div