Skip to content

Commit

Permalink
Remove livepreview
Browse files Browse the repository at this point in the history
  • Loading branch information
Dawa Ometto committed Apr 12, 2017
1 parent f9b8b4e commit 5aa5bcc
Show file tree
Hide file tree
Showing 953 changed files with 0 additions and 272,317 deletions.
6 changes: 0 additions & 6 deletions bin/gollum
Expand Up @@ -105,12 +105,6 @@ MSG
opts.on("--no-edit", "Disable the feature of editing pages.") do
wiki_options[:allow_editing] = false
end
opts.on("--live-preview", "Enable the live preview feature in page editor.") do
wiki_options[:live_preview] = true
end
opts.on("--no-live-preview", "Disable the live preview feature in page editor.") do
wiki_options[:live_preview] = false
end
opts.on("--allow-uploads [MODE]", [:dir, :page], "Enable file uploads.",
"If set to 'dir', Gollum will store all uploads in the '<git-repo>/uploads/' directory.",
"If set to 'page', Gollum will store each upload at the currently edited page.") do |mode|
Expand Down
14 changes: 0 additions & 14 deletions lib/gollum/app.rb
Expand Up @@ -160,18 +160,10 @@ def wiki_new
wiki = wikip.wiki
@allow_uploads = wiki.allow_uploads
if page = wikip.page
if wiki.live_preview && page.format.to_s.include?('markdown') && supported_useragent?(request.user_agent)
live_preview_url = '/livepreview/?page=' + encodeURIComponent(@name)
if @path
live_preview_url << '&path=' + encodeURIComponent(@path)
end
redirect to(live_preview_url)
else
@page = page
@page.version = wiki.repo.log(wiki.ref, @page.path).first
@content = page.text_data
mustache :edit
end
else
redirect to("/create/#{encodeURIComponent(@name)}")
end
Expand Down Expand Up @@ -394,12 +386,6 @@ def wiki_new
mustache :page
end

get '/livepreview/' do
wiki = wiki_new
@mathjax = wiki.mathjax
mustache :livepreview, { :layout => false }
end

get '/history/*' do
@page = wiki_page(params[:splat].first).page
@page_num = [params[:page].to_i, 1].max
Expand Down
132 changes: 0 additions & 132 deletions lib/gollum/public/gollum/livepreview/css/custom.css

This file was deleted.

Binary file not shown.
Binary file not shown.
Binary file removed lib/gollum/public/gollum/livepreview/images/lr_24.png
Binary file not shown.
Binary file removed lib/gollum/public/gollum/livepreview/images/save_24.png
Binary file not shown.
Binary file not shown.
129 changes: 0 additions & 129 deletions lib/gollum/public/gollum/livepreview/js/ace/lib/ace/ace.js

This file was deleted.

0 comments on commit 5aa5bcc

Please sign in to comment.