summaryrefslogtreecommitdiff
path: root/frontend/app/views/tile/forms/tile.form.hyperlink.js
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2021-04-01 17:30:37 +0200
committerJules Laplace <julescarbon@gmail.com>2021-04-01 17:30:37 +0200
commit7e344419330855dbbf10896c39e91b4e6861dd57 (patch)
treea8baae6cb875a3e8dad47bc4d8392738445f00fd /frontend/app/views/tile/forms/tile.form.hyperlink.js
parent5cafa9d43b769e6f60740f59293ddf3588e7b8ad (diff)
displaying custom cursors on the frontend
Diffstat (limited to 'frontend/app/views/tile/forms/tile.form.hyperlink.js')
-rw-r--r--frontend/app/views/tile/forms/tile.form.hyperlink.js11
1 files changed, 10 insertions, 1 deletions
diff --git a/frontend/app/views/tile/forms/tile.form.hyperlink.js b/frontend/app/views/tile/forms/tile.form.hyperlink.js
index c444748..4d3e0b5 100644
--- a/frontend/app/views/tile/forms/tile.form.hyperlink.js
+++ b/frontend/app/views/tile/forms/tile.form.hyperlink.js
@@ -11,12 +11,18 @@ import {
NO_POPUP, OPEN_POPUP_LINK, CLOSE_POPUP_LINK
} from './tile.constants'
-export default function TileHyperlinkForm({ tile, pageList, popupList, parent }) {
+export default function TileHyperlinkForm({ tile, pageList, popupList, cursors, parent }) {
const isExternalLink = tile.target_page_id === EXTERNAL_LINK
// const isPopupLink = (
// tile.target_page_id === OPEN_POPUP_LINK ||
// tile.target_page_id === CLOSE_POPUP_LINK
// )
+ let cursor
+ console.log(tile.settings.cursor, tile.settings.custom_cursor_id)
+ if (tile.settings.cursor === 'custom' && tile.settings.custom_cursor_id) {
+ cursor = cursors[tile.settings.custom_cursor_id]
+ console.log(cursor)
+ }
return (
<div>
<div className={'row selects'}>
@@ -36,6 +42,9 @@ export default function TileHyperlinkForm({ tile, pageList, popupList, parent })
onChange={parent.handleSettingsSelect}
/>
</div>
+ {cursor && (
+ <img src={cursor.url} className="sampleCursor" />
+ )}
{isExternalLink && (
<div>
<TextInput