|
@@ -10,15 +10,16 @@
|
|
)
|
|
)
|
|
v-icon(color='green', :left='$vuetify.breakpoint.lgAndUp') check
|
|
v-icon(color='green', :left='$vuetify.breakpoint.lgAndUp') check
|
|
span.white--text(v-if='$vuetify.breakpoint.lgAndUp') {{ mode === 'create' ? $t('common:actions.create') : $t('common:actions.save') }}
|
|
span.white--text(v-if='$vuetify.breakpoint.lgAndUp') {{ mode === 'create' ? $t('common:actions.create') : $t('common:actions.save') }}
|
|
- v-btn.mx-0(
|
|
|
|
|
|
+ v-btn(
|
|
outline
|
|
outline
|
|
color='blue'
|
|
color='blue'
|
|
- @click.native.stop='openModal(`properties`)'
|
|
|
|
- :class='{ "is-icon": $vuetify.breakpoint.mdAndDown }'
|
|
|
|
|
|
+ @click.native.stop='openPropsModal'
|
|
|
|
+ :class='{ "is-icon": $vuetify.breakpoint.mdAndDown, "mx-0": mode === `create`, "ml-0": mode !== `create` }'
|
|
)
|
|
)
|
|
v-icon(color='blue', :left='$vuetify.breakpoint.lgAndUp') sort_by_alpha
|
|
v-icon(color='blue', :left='$vuetify.breakpoint.lgAndUp') sort_by_alpha
|
|
span.white--text(v-if='$vuetify.breakpoint.lgAndUp') {{ $t('editor:page') }}
|
|
span.white--text(v-if='$vuetify.breakpoint.lgAndUp') {{ $t('editor:page') }}
|
|
v-btn(
|
|
v-btn(
|
|
|
|
+ v-if='mode === `create`'
|
|
outline
|
|
outline
|
|
color='red'
|
|
color='red'
|
|
:class='{ "is-icon": $vuetify.breakpoint.mdAndDown }'
|
|
:class='{ "is-icon": $vuetify.breakpoint.mdAndDown }'
|
|
@@ -28,7 +29,7 @@
|
|
span.white--text(v-if='$vuetify.breakpoint.lgAndUp') {{ $t('common:actions.discard') }}
|
|
span.white--text(v-if='$vuetify.breakpoint.lgAndUp') {{ $t('common:actions.discard') }}
|
|
v-content
|
|
v-content
|
|
component(:is='currentEditor')
|
|
component(:is='currentEditor')
|
|
- component(:is='currentModal')
|
|
|
|
|
|
+ editor-modal-properties(v-model='dialogProps')
|
|
v-dialog(v-model='dialogProgress', persistent, max-width='350')
|
|
v-dialog(v-model='dialogProgress', persistent, max-width='350')
|
|
v-card(color='blue darken-3', dark)
|
|
v-card(color='blue darken-3', dark)
|
|
v-card-text.text-xs-center.py-4
|
|
v-card-text.text-xs-center.py-4
|
|
@@ -54,6 +55,7 @@
|
|
v-card-text.text-xs-center(@click='selectEditor("code")')
|
|
v-card-text.text-xs-center(@click='selectEditor("code")')
|
|
v-icon(large, color='primary') code
|
|
v-icon(large, color='primary') code
|
|
.body-2.mt-2 Code
|
|
.body-2.mt-2 Code
|
|
|
|
+ .caption.grey--text Raw HTML
|
|
v-flex(xs4)
|
|
v-flex(xs4)
|
|
v-card.radius-7(
|
|
v-card.radius-7(
|
|
hover
|
|
hover
|
|
@@ -63,6 +65,7 @@
|
|
v-card-text.text-xs-center(@click='selectEditor("markdown")')
|
|
v-card-text.text-xs-center(@click='selectEditor("markdown")')
|
|
v-icon(large, color='primary') list_alt
|
|
v-icon(large, color='primary') list_alt
|
|
.body-2.mt-2 Markdown
|
|
.body-2.mt-2 Markdown
|
|
|
|
+ .caption.grey--text Default
|
|
v-flex(xs4)
|
|
v-flex(xs4)
|
|
v-card.radius-7.grey(
|
|
v-card.radius-7.grey(
|
|
hover
|
|
hover
|
|
@@ -72,7 +75,8 @@
|
|
v-card-text.text-xs-center(@click='selectEditor("wysiwyg")')
|
|
v-card-text.text-xs-center(@click='selectEditor("wysiwyg")')
|
|
v-icon(large, color='grey darken-1') web
|
|
v-icon(large, color='grey darken-1') web
|
|
.body-2.mt-2.grey--text.text--darken-2 Visual Builder
|
|
.body-2.mt-2.grey--text.text--darken-2 Visual Builder
|
|
- .caption.blue--text.text--lighten-2 This cannot be changed later.
|
|
|
|
|
|
+ .caption.grey--text.text--darken-1 Drag-n-drop
|
|
|
|
+ .caption.blue--text.text--lighten-2 This cannot be changed once the page is created.
|
|
|
|
|
|
v-snackbar(
|
|
v-snackbar(
|
|
:color='notification.style'
|
|
:color='notification.style'
|
|
@@ -131,7 +135,7 @@ export default {
|
|
},
|
|
},
|
|
isPublished: {
|
|
isPublished: {
|
|
type: Boolean,
|
|
type: Boolean,
|
|
- default: false
|
|
|
|
|
|
+ default: true
|
|
},
|
|
},
|
|
initEditor: {
|
|
initEditor: {
|
|
type: String,
|
|
type: String,
|
|
@@ -152,8 +156,8 @@ export default {
|
|
},
|
|
},
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
- currentModal: '',
|
|
|
|
currentEditor: '',
|
|
currentEditor: '',
|
|
|
|
+ dialogProps: false,
|
|
dialogProgress: false,
|
|
dialogProgress: false,
|
|
dialogEditorSelector: false
|
|
dialogEditorSelector: false
|
|
}
|
|
}
|
|
@@ -192,17 +196,12 @@ export default {
|
|
this.dialogEditorSelector = false
|
|
this.dialogEditorSelector = false
|
|
if (this.mode === 'create') {
|
|
if (this.mode === 'create') {
|
|
_.delay(() => {
|
|
_.delay(() => {
|
|
- this.openModal('properties')
|
|
|
|
|
|
+ this.dialogProps = true
|
|
}, 500)
|
|
}, 500)
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- openModal(name) {
|
|
|
|
- this.currentModal = `editorModal${_.startCase(name)}`
|
|
|
|
- },
|
|
|
|
- closeModal() {
|
|
|
|
- _.delay(() => {
|
|
|
|
- this.currentModal = ``
|
|
|
|
- }, 500)
|
|
|
|
|
|
+ openPropsModal(name) {
|
|
|
|
+ this.dialogProps = true
|
|
},
|
|
},
|
|
showProgressDialog(textKey) {
|
|
showProgressDialog(textKey) {
|
|
this.dialogProgress = true
|
|
this.dialogProgress = true
|
|
@@ -298,7 +297,7 @@ export default {
|
|
<style lang='scss'>
|
|
<style lang='scss'>
|
|
|
|
|
|
.editor {
|
|
.editor {
|
|
- background-color: mc('grey', '900');
|
|
|
|
|
|
+ background-color: mc('grey', '900') !important;
|
|
min-height: 100vh;
|
|
min-height: 100vh;
|
|
}
|
|
}
|
|
|
|
|