summaryrefslogtreecommitdiff
path: root/frontend/app/views/page/components/tile.handle.js
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2020-12-26 21:56:56 +0100
committerJules Laplace <julescarbon@gmail.com>2020-12-26 21:56:56 +0100
commit85bfb949fea4e69dabc5b7544ce70d26d3d11393 (patch)
tree1b818db90e44176751c98c9142dbe06b2b5fe6a3 /frontend/app/views/page/components/tile.handle.js
parentd260e3a65bdec981fd98db8a2352caa9bef9ae55 (diff)
add support for unsafe inline scripts
Diffstat (limited to 'frontend/app/views/page/components/tile.handle.js')
-rw-r--r--frontend/app/views/page/components/tile.handle.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/frontend/app/views/page/components/tile.handle.js b/frontend/app/views/page/components/tile.handle.js
index e91f0b1..624b175 100644
--- a/frontend/app/views/page/components/tile.handle.js
+++ b/frontend/app/views/page/components/tile.handle.js
@@ -66,6 +66,13 @@ const TileHandle = ({ tile, bounds, box, viewing, onMouseDown, onDoubleClick })
style.width = tile.settings.width ? tile.settings.width + 'px' : 'auto'
style.height = tile.settings.height ? tile.settings.height + 'px' : 'auto'
break
+ case 'script':
+ content = ""
+ if (viewing) {
+ eval(tile.settings.content)
+ } else {
+ content = "SCRIPT"
+ }
}
if (viewing && tile.href) {
if (tile.href.indexOf('http') === 0) {