From cc462c8bcac2756f379fbea4b74d82640ebec3ef Mon Sep 17 00:00:00 2001 From: Henrique Dias Date: Sat, 1 Jul 2017 08:36:28 +0100 Subject: [PATCH] updates on editor Former-commit-id: 2928727a06a94c0ea87ed821a472ae662df803d1 [formerly 098bc4234803078aba013f6312d179158194fffb] [formerly d2bb681fe62ba87a29b9866e291fb975489cd3fc [formerly 3d25185a557dab1fa529499572c0e6d5bf187ca1]] Former-commit-id: 288ccb95466fbd234d278886800e1d27c54fa8dd [formerly 78c473865b085e97cf435cb230e2afa85559aba0] Former-commit-id: c5dc56f4d6198c9c306c01573e1a1af5f1827c3a --- .travis.yml | 6 +-- _assets/_old/templates/frontmatter.tmpl | 24 --------- _assets/_old/templates/hugo.tmpl | 14 ----- _assets/_old/templates/templates.tmpl | 23 -------- _assets/build/webpack.base.conf.js | 5 ++ _assets/index.html | 2 +- _assets/src/App.vue | 18 +++++++ _assets/src/components/Editor.vue | 20 +++++-- _assets/src/components/Editor/ArrayObject.vue | 19 +++++++ _assets/src/components/Editor/Value.vue | 28 ++++++++++ _assets/src/components/NewDirPrompt.vue | 7 ++- _assets/src/components/NewFilePrompt.vue | 12 ++++- _assets/src/components/Preview.vue | 1 + _assets/src/css/base.css | 6 +-- _assets/src/css/styles.css | 2 +- caddy/{ => filemanager}/README.md | 0 caddy/{ => filemanager}/filemanager.go | 48 ++++++++++------- caddy/hugo/README.md | 52 +++++++++++++++++++ caddy/hugo/hugo.go | 1 + caddy/hugo/hugo.js | 42 +++++++++++++++ cmd/filemanager/main.go | 31 ----------- frontmatter/frontmatter.go | 20 +++---- http.go | 2 +- 23 files changed, 246 insertions(+), 137 deletions(-) delete mode 100644 _assets/_old/templates/hugo.tmpl delete mode 100644 _assets/_old/templates/templates.tmpl create mode 100644 _assets/src/components/Editor/ArrayObject.vue create mode 100644 _assets/src/components/Editor/Value.vue rename caddy/{ => filemanager}/README.md (100%) rename caddy/{ => filemanager}/filemanager.go (82%) create mode 100644 caddy/hugo/README.md create mode 100644 caddy/hugo/hugo.go create mode 100644 caddy/hugo/hugo.js delete mode 100644 cmd/filemanager/main.go diff --git a/.travis.yml b/.travis.yml index e4bf945b..9a78774d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -9,7 +9,7 @@ install: - go get github.com/gordonklaus/ineffassign script: - - sed -i 's/\_ \"github.com\/mholt\/caddy\/caddyhttp\"/\_ \"github.com\/mholt\/caddy\/caddyhttp\"\n\_ \"github.com\/hacdias\/filemanager\/caddy\"/g' $GOPATH/src/github.com/mholt/caddy/caddy/caddymain/run.go + - sed -i 's/\_ \"github.com\/mholt\/caddy\/caddyhttp\"/\_ \"github.com\/mholt\/caddy\/caddyhttp\"\n\_ \"github.com\/hacdias\/filemanager\/caddy\/filemanager\"/g' $GOPATH/src/github.com/mholt/caddy/caddy/caddymain/run.go - go build -o binary github.com/mholt/caddy/caddy - - go build github.com/hacdias/filemanager - - ineffassign . \ No newline at end of file + - go build github.com/hacdias/filemanager + - ineffassign . diff --git a/_assets/_old/templates/frontmatter.tmpl b/_assets/_old/templates/frontmatter.tmpl index 3389da90..8872135f 100644 --- a/_assets/_old/templates/frontmatter.tmpl +++ b/_assets/_old/templates/frontmatter.tmpl @@ -30,27 +30,3 @@ {{ end }} -{{ define "value" }} -{{- if eq .HTMLType "textarea" }} - -{{- else if eq .HTMLType "datetime" }} - -{{- else }} - -{{- end }} -{{ end }} - -{{ define "fielset" }} -
- {{- if not (eq .Title "") }} -

{{ .Name }}

- {{- end }} -
- add -
-
- close -
- {{- template "blocks" .Content }} -
-{{ end }} diff --git a/_assets/_old/templates/hugo.tmpl b/_assets/_old/templates/hugo.tmpl deleted file mode 100644 index 982a65a4..00000000 --- a/_assets/_old/templates/hugo.tmpl +++ /dev/null @@ -1,14 +0,0 @@ -{{ define "sidebar-addon" }} - - subject - Posts and Pages - - - format_paint - Themes - - - settings - Settings - -{{ end }} \ No newline at end of file diff --git a/_assets/_old/templates/templates.tmpl b/_assets/_old/templates/templates.tmpl deleted file mode 100644 index be716656..00000000 --- a/_assets/_old/templates/templates.tmpl +++ /dev/null @@ -1,23 +0,0 @@ -{{ define "templates" }} - - - -{{ end }} \ No newline at end of file diff --git a/_assets/build/webpack.base.conf.js b/_assets/build/webpack.base.conf.js index 433e0aaf..e8d762af 100644 --- a/_assets/build/webpack.base.conf.js +++ b/_assets/build/webpack.base.conf.js @@ -41,6 +41,11 @@ module.exports = { loader: 'vue-loader', options: vueLoaderConfig }, + { + test: /\.css$/, + include: /node_modules/, + loader: 'style!css' + }, { test: /\.js$/, loader: 'babel-loader', diff --git a/_assets/index.html b/_assets/index.html index 69b8c6c2..42e3d235 100644 --- a/_assets/index.html +++ b/_assets/index.html @@ -90,7 +90,7 @@ {{- if ne .User.StyleSheet "" -}} - + {{- end -}} diff --git a/_assets/src/App.vue b/_assets/src/App.vue index b2f95d6f..006ae4bb 100644 --- a/_assets/src/App.vue +++ b/_assets/src/App.vue @@ -26,6 +26,7 @@ folder My Files +
+ +
+ +
+