mirror of https://github.com/Requarks/wiki.git
11 changed files with 231 additions and 97 deletions
Split View
Diff Options
-
11client/components/admin/admin-theme.vue
-
30client/components/editor.vue
-
2client/components/editor/editor-code.vue
-
60client/components/editor/editor-modal-access.vue
-
162client/components/editor/editor-modal-properties.vue
-
7client/graph/editor/save.gql
-
20client/store/admin.js
-
18client/store/editor.js
-
4client/store/index.js
-
2package.json
-
12yarn.lock
@ -1,60 +0,0 @@ |
|||
<template lang='pug'> |
|||
v-bottom-sheet(v-model='isShown', inset, persistent) |
|||
v-toolbar(color='orange', flat) |
|||
v-icon(color='white') vpn_lock |
|||
v-toolbar-title.white--text Page Access |
|||
v-spacer |
|||
v-btn(icon, dark, @click.native='close') |
|||
v-icon close |
|||
v-card.pa-3(tile) |
|||
v-form |
|||
v-container(fluid) |
|||
v-layout(row, wrap) |
|||
v-flex(xs12) |
|||
v-switch(label='Published', v-model='isPublished', color='primary') |
|||
v-flex(xs6) |
|||
v-menu(ref='menuPublishStart', lazy='', :close-on-content-click='false', v-model='isPublishStartShown', transition='scale-transition', offset-y='', full-width='', :nudge-right='40', min-width='290px', :return-value.sync='publishStartDate') |
|||
v-text-field(slot='activator', label='Publish starting on...', v-model='publishStartDate', prepend-icon='event', readonly) |
|||
v-date-picker(v-model='publishStartDate', :min='(new Date()).toISOString().substring(0, 10)', reactive) |
|||
v-spacer |
|||
v-btn(flat='', color='primary', @click='isPublishStartShown = false') Cancel |
|||
v-btn(flat='', color='primary', @click='$refs.menuPublishStart.save(date)') OK |
|||
v-flex(xs6) |
|||
v-menu(ref='menuPublishEnd', lazy='', :close-on-content-click='false', v-model='isPublishEndShown', transition='scale-transition', offset-y='', full-width='', :nudge-right='40', min-width='290px', :return-value.sync='publishEndDate') |
|||
v-text-field(slot='activator', label='Publish ending on...', v-model='publishEndDate', prepend-icon='event', readonly) |
|||
v-date-picker(v-model='publishEndDate', :min='(new Date()).toISOString().substring(0, 10)', reactive) |
|||
v-spacer |
|||
v-btn(flat='', color='primary', @click='isPublishEndShown = false') Cancel |
|||
v-btn(flat='', color='primary', @click='$refs.menuPublishEnd.save(date)') OK |
|||
v-card-actions |
|||
v-btn(color='green', dark) Save |
|||
v-btn(@click.native='close') Cancel |
|||
</template> |
|||
|
|||
<script> |
|||
export default { |
|||
data() { |
|||
return { |
|||
isShown: false, |
|||
isPublished: true, |
|||
isPublishStartShown: false, |
|||
isPublishEndShown: false, |
|||
publishStartDate: '', |
|||
publishEndDate: '' |
|||
} |
|||
}, |
|||
mounted() { |
|||
this.isShown = true |
|||
}, |
|||
methods: { |
|||
close() { |
|||
this.isShown = false |
|||
this.$parent.$parent.closeModal() |
|||
} |
|||
} |
|||
} |
|||
</script> |
|||
|
|||
<style lang='scss'> |
|||
|
|||
</style> |
@ -0,0 +1,7 @@ |
|||
mutation { |
|||
page { |
|||
create { |
|||
page |
|||
} |
|||
} |
|||
} |
@ -1,13 +1,13 @@ |
|||
import { make } from 'vuex-pathify' |
|||
|
|||
const state = { |
|||
theme: { |
|||
dark: false |
|||
} |
|||
} |
|||
|
|||
export default { |
|||
namespaced: true, |
|||
state: { |
|||
theme: { |
|||
dark: false |
|||
} |
|||
}, |
|||
mutations: { |
|||
setThemeDarkMode(state, payload) { |
|||
state.theme.dark = payload |
|||
} |
|||
} |
|||
state, |
|||
mutations: make.mutations(state) |
|||
} |
@ -0,0 +1,18 @@ |
|||
import { make } from 'vuex-pathify' |
|||
|
|||
const state = { |
|||
title: '', |
|||
description: '', |
|||
tags: [], |
|||
path: '', |
|||
isPublished: true, |
|||
publishEtartDate: '', |
|||
publishEndDate: '', |
|||
locale: 'en' |
|||
} |
|||
|
|||
export default { |
|||
namespaced: true, |
|||
state, |
|||
mutations: make.mutations(state) |
|||
} |
Write
Preview
Loading…
Cancel
Save