Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wiki-js
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
wiki-js
Commits
4fa7ed4e
Commit
4fa7ed4e
authored
Feb 24, 2018
by
NGPixel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
refactor: client structure + editor preview logic
parent
37c28691
Hide whitespace changes
Inline
Side-by-side
Showing
19 changed files
with
26 additions
and
8 deletions
+26
-8
app.js
client/app.js
+1
-1
editor-code.vue
client/components/editor-code.vue
+21
-3
editor-modal-access.vue
client/components/editor-modal-access.vue
+0
-0
editor-modal-properties.vue
client/components/editor-modal-properties.vue
+0
-0
editor.vue
client/components/editor.vue
+0
-0
login.vue
client/components/login.vue
+2
-2
navigator.vue
client/components/navigator.vue
+0
-0
setup.vue
client/components/setup.vue
+0
-0
toggle.vue
client/components/toggle.vue
+0
-0
graphql.js
client/constants/graphql.js
+0
-0
index.js
client/constants/index.js
+0
-0
compatibility.js
client/helpers/compatibility.js
+0
-0
index.js
client/helpers/index.js
+0
-0
index.js
client/index.js
+2
-2
boot.js
client/modules/boot.js
+0
-0
localization.js
client/modules/localization.js
+0
-0
array-from.js
client/polyfills/array-from.js
+0
-0
index.js
client/store/index.js
+0
-0
navigator.js
client/store/modules/navigator.js
+0
-0
No files found.
client/
js/
app.js
→
client/app.js
View file @
4fa7ed4e
...
...
@@ -137,7 +137,7 @@ let bootstrap = () => {
// Load Icons
// ====================================
import
(
/* webpackChunkName: "icons" */
'.
.
/svg/icons.svg'
).
then
(
icons
=>
{
import
(
/* webpackChunkName: "icons" */
'./svg/icons.svg'
).
then
(
icons
=>
{
document
.
body
.
insertAdjacentHTML
(
'beforeend'
,
icons
)
})
}
...
...
client/
js/
components/editor-code.vue
→
client/components/editor-code.vue
View file @
4fa7ed4e
...
...
@@ -62,9 +62,10 @@
.editor-code-main
.editor-code-editor
.editor-code-editor-title Editor
codemirror(ref='cm', v-model='code', :options='cmOptions', @ready=
"onCmReady"
)
codemirror(ref='cm', v-model='code', :options='cmOptions', @ready=
'onCmReady', @input='onCmInput'
)
.editor-code-preview
.editor-code-preview-title Preview
.editor-code-preview-content(v-html='previewHTML')
v-speed-dial(v-model='fabInsertMenu', :open-on-hover='true', direction='top', transition='slide-y-reverse-transition', :fixed='true', :right='!isMobile', :left='isMobile', :bottom='true')
v-btn(color='blue', fab, dark, v-model='fabInsertMenu', slot='activator')
v-icon add_circle
...
...
@@ -87,6 +88,8 @@
</
template
>
<
script
>
import
_
from
'lodash'
import
{
codemirror
}
from
'vue-codemirror'
import
'codemirror/lib/codemirror.css'
...
...
@@ -106,6 +109,16 @@ import 'codemirror/addon/search/matchesonscrollbar.js'
import
'codemirror/addon/search/searchcursor.js'
import
'codemirror/addon/search/match-highlighter.js'
// Markdown-it
import
MarkdownIt
from
'markdown-it'
const
md
=
new
MarkdownIt
({
html
:
true
,
breaks
:
true
,
linkify
:
true
,
typography
:
true
})
export
default
{
components
:
{
codemirror
...
...
@@ -127,7 +140,8 @@ export default {
annotateScrollbar
:
true
},
viewportMargin
:
50
}
},
previewHTML
:
''
}
},
computed
:
{
...
...
@@ -156,7 +170,11 @@ export default {
self
.
$parent
.
save
()
}
})
}
this
.
onCmInput
(
this
.
code
)
},
onCmInput
:
_
.
debounce
(
function
(
newContent
)
{
this
.
previewHTML
=
md
.
render
(
newContent
)
},
500
)
}
}
</
script
>
...
...
client/
js/
components/editor-modal-access.vue
→
client/components/editor-modal-access.vue
View file @
4fa7ed4e
File moved
client/
js/
components/editor-modal-properties.vue
→
client/components/editor-modal-properties.vue
View file @
4fa7ed4e
File moved
client/
js/
components/editor.vue
→
client/components/editor.vue
View file @
4fa7ed4e
File moved
client/
js/
components/login.vue
→
client/components/login.vue
View file @
4fa7ed4e
...
...
@@ -199,7 +199,7 @@ export default {
<
style
lang=
"scss"
>
.login
{
background-color
:
mc
(
'blue'
,
'800'
);
background-image
:
url('../
../
static/svg/login-bg-motif.svg')
;
background-image
:
url('../static/svg/login-bg-motif.svg')
;
background-repeat
:
repeat
;
background-size
:
200px
;
width
:
100%
;
...
...
@@ -221,7 +221,7 @@ export default {
&
:
:
before
{
content
:
''
;
position
:
absolute
;
background-image
:
url('../
../
static/svg/login-bg.svg')
;
background-image
:
url('../static/svg/login-bg.svg')
;
background-position
:
center
bottom
;
background-size
:
cover
;
top
:
0
;
...
...
client/
js/
components/navigator.vue
→
client/components/navigator.vue
View file @
4fa7ed4e
File moved
client/
js/
components/setup.vue
→
client/components/setup.vue
View file @
4fa7ed4e
File moved
client/
js/
components/toggle.vue
→
client/components/toggle.vue
View file @
4fa7ed4e
File moved
client/
js/
constants/graphql.js
→
client/constants/graphql.js
View file @
4fa7ed4e
File moved
client/
js/
constants/index.js
→
client/constants/index.js
View file @
4fa7ed4e
File moved
client/
j
s/compatibility.js
→
client/
helper
s/compatibility.js
View file @
4fa7ed4e
File moved
client/
js/
helpers/index.js
→
client/helpers/index.js
View file @
4fa7ed4e
File moved
client/index.js
View file @
4fa7ed4e
...
...
@@ -2,6 +2,6 @@
require
(
'vuetify/src/stylus/main.styl'
)
require
(
'./scss/app.scss'
)
require
(
'./
j
s/compatibility.js'
)
require
(
'./
helper
s/compatibility.js'
)
require
(
'offline-plugin/runtime'
).
install
()
require
(
'./
js/
app.js'
)
require
(
'./app.js'
)
client/
js/
modules/boot.js
→
client/modules/boot.js
View file @
4fa7ed4e
File moved
client/
js/
modules/localization.js
→
client/modules/localization.js
View file @
4fa7ed4e
File moved
client/
js/
polyfills/array-from.js
→
client/polyfills/array-from.js
View file @
4fa7ed4e
File moved
client/
js/
store/index.js
→
client/store/index.js
View file @
4fa7ed4e
File moved
client/
js/
store/modules/navigator.js
→
client/store/modules/navigator.js
View file @
4fa7ed4e
File moved
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment