Commit 8bd166c0 authored by Anton's avatar Anton

Add link option to title cell

parent 6f3f77da
......@@ -54,6 +54,16 @@
errorMessage: '',
value: '',
path: 'content'
},
{
inputType: 'url',
type: 'Title',
label: 'Link URL',
help: 'Insert any valid URL',
error: false,
errorMessage: 'Needs to be a valid URL',
value: '',
path: 'link'
}],
'Text': [{
inputType: 'textarea',
......
......@@ -2,7 +2,9 @@
// title
div(:class="{'display-preview': preview, 'display-full': display}")
template(v-if="display")
h1 {{titleContent}}
h1
a(v-if="link", :href="link") {{titleContent}}
template(v-else) {{titleContent}}
template(v-else)
cell-info(:cell="cell", type="Title Cell")
......@@ -22,6 +24,10 @@ export default {
computed: {
titleContent () {
return this.cell['content']
},
link () {
if (!this.cell) return
return this.cell.link
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment