Commit 3805797c authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

scss: rename file_content to file-content etc

parent 399d0bdd
...@@ -14,7 +14,7 @@ class Admin ...@@ -14,7 +14,7 @@ class Admin
$('.log-bottom').click (e) -> $('.log-bottom').click (e) ->
e.preventDefault() e.preventDefault()
visible_log = $(".file_content:visible") visible_log = $(".file-content:visible")
visible_log.animate({ scrollTop: visible_log.find('ol').height() }, "fast") visible_log.animate({ scrollTop: visible_log.find('ol').height() }, "fast")
modal = $('.change-owner-holder') modal = $('.change-owner-holder')
......
...@@ -2,12 +2,12 @@ ...@@ -2,12 +2,12 @@
* File content holder * File content holder
* *
*/ */
.file_holder { .file-holder {
border: 1px solid #BBB; border: 1px solid #BBB;
margin-bottom: 1em; margin-bottom: 1em;
@include solid-shade; @include solid-shade;
.file_title { .file-title {
border-bottom: 1px solid #bbb; border-bottom: 1px solid #bbb;
@include bg-dark-gray-gradient; @include bg-dark-gray-gradient;
margin: 0; margin: 0;
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
} }
} }
} }
.file_content { .file-content {
background: #fff; background: #fff;
font-size: 11px; font-size: 11px;
......
.snippet.file_holder { .snippet.file-holder {
.file_title { .file-title {
.snippet-file-name { .snippet-file-name {
position: relative; position: relative;
top: -4px; top: -4px;
......
...@@ -11,57 +11,57 @@ ...@@ -11,57 +11,57 @@
%p.light To prevent performance issues admin logs output the last 2000 lines %p.light To prevent performance issues admin logs output the last 2000 lines
.tab-content .tab-content
.tab-pane.active#githost .tab-pane.active#githost
.file_holder#README .file-holder#README
.file_title .file-title
%i.icon-file %i.icon-file
githost.log githost.log
.pull-right .pull-right
= link_to '#', class: 'log-bottom' do = link_to '#', class: 'log-bottom' do
%i.icon-arrow-down %i.icon-arrow-down
Scroll down Scroll down
.file_content.logs .file-content.logs
%ol %ol
- Gitlab::GitLogger.read_latest.each do |line| - Gitlab::GitLogger.read_latest.each do |line|
%li %li
%p= line %p= line
.tab-pane#application .tab-pane#application
.file_holder#README .file-holder#README
.file_title .file-title
%i.icon-file %i.icon-file
application.log application.log
.pull-right .pull-right
= link_to '#', class: 'log-bottom' do = link_to '#', class: 'log-bottom' do
%i.icon-arrow-down %i.icon-arrow-down
Scroll down Scroll down
.file_content.logs .file-content.logs
%ol %ol
- Gitlab::AppLogger.read_latest.each do |line| - Gitlab::AppLogger.read_latest.each do |line|
%li %li
%p= line %p= line
.tab-pane#production .tab-pane#production
.file_holder#README .file-holder#README
.file_title .file-title
%i.icon-file %i.icon-file
production.log production.log
.pull-right .pull-right
= link_to '#', class: 'log-bottom' do = link_to '#', class: 'log-bottom' do
%i.icon-arrow-down %i.icon-arrow-down
Scroll down Scroll down
.file_content.logs .file-content.logs
%ol %ol
- Gitlab::Logger.read_latest_for('production.log').each do |line| - Gitlab::Logger.read_latest_for('production.log').each do |line|
%li %li
%p= line %p= line
.tab-pane#sidekiq .tab-pane#sidekiq
.file_holder#README .file-holder#README
.file_title .file-title
%i.icon-file %i.icon-file
sidekiq.log sidekiq.log
.pull-right .pull-right
= link_to '#', class: 'log-bottom' do = link_to '#', class: 'log-bottom' do
%i.icon-arrow-down %i.icon-arrow-down
Scroll down Scroll down
.file_content.logs .file-content.logs
%ol %ol
- Gitlab::Logger.read_latest_for('sidekiq.log').each do |line| - Gitlab::Logger.read_latest_for('sidekiq.log').each do |line|
%li %li
......
...@@ -6,10 +6,10 @@ ...@@ -6,10 +6,10 @@
= @category.titleize = @category.titleize
%br %br
.file_holder .file-holder
.file_title .file-title
%i.icon-file %i.icon-file
= @category = @category
.file_content.wiki .file-content.wiki
= preserve do = preserve do
= markdown File.read(Rails.root.join("doc", "api", "#{@category}.md")) = markdown File.read(Rails.root.join("doc", "api", "#{@category}.md"))
...@@ -19,46 +19,46 @@ ...@@ -19,46 +19,46 @@
.tab-content .tab-content
.tab-pane.active#features .tab-pane.active#features
.file_holder .file-holder
.file_title .file-title
%i.icon-file %i.icon-file
Features Features
.file_content.wiki .file-content.wiki
= preserve do = preserve do
= markdown File.read(Rails.root.join("doc", "raketasks", "features.md")) = markdown File.read(Rails.root.join("doc", "raketasks", "features.md"))
.tab-pane#maintenance .tab-pane#maintenance
.file_holder .file-holder
.file_title .file-title
%i.icon-file %i.icon-file
Maintenance Maintenance
.file_content.wiki .file-content.wiki
= preserve do = preserve do
= markdown File.read(Rails.root.join("doc", "raketasks", "maintenance.md")) = markdown File.read(Rails.root.join("doc", "raketasks", "maintenance.md"))
.tab-pane#user_management .tab-pane#user_management
.file_holder .file-holder
.file_title .file-title
%i.icon-file %i.icon-file
User Management User Management
.file_content.wiki .file-content.wiki
= preserve do = preserve do
= markdown File.read(Rails.root.join("doc", "raketasks", "user_management.md")) = markdown File.read(Rails.root.join("doc", "raketasks", "user_management.md"))
.tab-pane#cleanup .tab-pane#cleanup
.file_holder .file-holder
.file_title .file-title
%i.icon-file %i.icon-file
Cleanup Cleanup
.file_content.wiki .file-content.wiki
= preserve do = preserve do
= markdown File.read(Rails.root.join("doc", "raketasks", "cleanup.md")) = markdown File.read(Rails.root.join("doc", "raketasks", "cleanup.md"))
.tab-pane#backup_restore .tab-pane#backup_restore
.file_holder .file-holder
.file_title .file-title
%i.icon-file %i.icon-file
Backup & Restore Backup & Restore
.file_content.wiki .file-content.wiki
= preserve do = preserve do
= markdown File.read(Rails.root.join("doc", "raketasks", "backup_restore.md")) = markdown File.read(Rails.root.join("doc", "raketasks", "backup_restore.md"))
...@@ -11,14 +11,14 @@ ...@@ -11,14 +11,14 @@
%li= link %li= link
.clear .clear
.file_holder .file-holder
.file_title .file-title
%i.icon-file %i.icon-file
%span.file_name %span.file_name
= @blob.name = @blob.name
%small= number_to_human_size @blob.size %small= number_to_human_size @blob.size
%span.options= render "projects/blob/actions" %span.options= render "projects/blob/actions"
.file_content.blame .file-content.blame
%table %table
- current_line = 1 - current_line = 1
- @blame.each do |commit, lines| - @blame.each do |commit, lines|
......
...@@ -17,8 +17,8 @@ ...@@ -17,8 +17,8 @@
= link_to title, '#' = link_to title, '#'
%div#tree-content-holder.tree-content-holder %div#tree-content-holder.tree-content-holder
.file_holder .file-holder
.file_title .file-title
%i.icon-file %i.icon-file
%span.file_name %span.file_name
= blob.name = blob.name
......
.file_content.blob_file .file-content.blob_file
%center %center
= link_to project_blob_path(@project, @id) do = link_to project_blob_path(@project, @id) do
%div.padded %div.padded
......
.file_content.image_file .file-content.image_file
%img{ src: "data:#{blob.mime_type};base64,#{Base64.encode64(blob.data)}"} %img{ src: "data:#{blob.mime_type};base64,#{Base64.encode64(blob.data)}"}
- if gitlab_markdown?(blob.name) - if gitlab_markdown?(blob.name)
.file_content.wiki .file-content.wiki
= preserve do = preserve do
= markdown(blob.data) = markdown(blob.data)
- elsif markup?(blob.name) - elsif markup?(blob.name)
.file_content.wiki .file-content.wiki
= raw GitHub::Markup.render(blob.name, blob.data) = raw GitHub::Markup.render(blob.name, blob.data)
- else - else
.file_content.code .file-content.code
- unless blob.empty? - unless blob.empty?
%div{class: user_color_scheme_class} %div{class: user_color_scheme_class}
= raw blob.colorize(formatter: :gitlab) = raw blob.colorize(formatter: :gitlab)
......
.file-editor .file-editor
= form_tag(project_edit_tree_path(@project, @id), method: :put, class: "form-horizontal") do = form_tag(project_edit_tree_path(@project, @id), method: :put, class: "form-horizontal") do
.file_holder .file-holder
.file_title .file-title
%i.icon-file %i.icon-file
%span.file_name %span.file_name
= @path = @path
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
%span.options %span.options
.btn-group.tree-btn-group .btn-group.tree-btn-group
= link_to "Cancel", project_blob_path(@project, @id), class: "btn btn-tiny btn-cancel", confirm: leave_edit_message = link_to "Cancel", project_blob_path(@project, @id), class: "btn btn-tiny btn-cancel", confirm: leave_edit_message
.file_content.code .file-content.code
%pre#editor= @blob.data %pre#editor= @blob.data
.control-group.commit_message-group .control-group.commit_message-group
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
= text_area_tag 'commit_message', '', placeholder: "Update #{@blob.name}", required: true, rows: 3 = text_area_tag 'commit_message', '', placeholder: "Update #{@blob.name}", required: true, rows: 3
.form-actions .form-actions
= hidden_field_tag 'last_commit', @last_commit = hidden_field_tag 'last_commit', @last_commit
= hidden_field_tag 'content', '', id: :file_content = hidden_field_tag 'content', '', id: :file-content
.commit-button-annotation .commit-button-annotation
= button_tag "Commit changes", class: 'btn commit-btn js-commit-button btn-primary' = button_tag "Commit changes", class: 'btn commit-btn js-commit-button btn-primary'
.message .message
...@@ -40,6 +40,6 @@ ...@@ -40,6 +40,6 @@
disableButtonIfEmptyField("#commit_message", ".js-commit-button"); disableButtonIfEmptyField("#commit_message", ".js-commit-button");
$(".js-commit-button").click(function(){ $(".js-commit-button").click(function(){
$("#file_content").val(editor.getValue()); $("#file-content").val(editor.getValue());
$(".file-editor form").submit(); $(".file-editor form").submit();
}); });
.file_holder .file-holder
.file_title .file-title
%i.icon-file %i.icon-file
%strong= @snippet.file_name %strong= @snippet.file_name
%span.options %span.options
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
- if can?(current_user, :admin_project_snippet, @project) || @snippet.author == current_user - if can?(current_user, :admin_project_snippet, @project) || @snippet.author == current_user
= link_to "Edit", edit_project_snippet_path(@project, @snippet), class: "btn btn-tiny", title: 'Edit Snippet' = link_to "Edit", edit_project_snippet_path(@project, @snippet), class: "btn btn-tiny", title: 'Edit Snippet'
= link_to "raw", raw_project_snippet_path(@project, @snippet), class: "btn btn-tiny", target: "_blank" = link_to "raw", raw_project_snippet_path(@project, @snippet), class: "btn btn-tiny", target: "_blank"
.file_content.code .file-content.code
- unless @snippet.content.empty? - unless @snippet.content.empty?
%div{class: user_color_scheme_class} %div{class: user_color_scheme_class}
= raw @snippet.colorize(formatter: :gitlab) = raw @snippet.colorize(formatter: :gitlab)
......
...@@ -19,10 +19,10 @@ ...@@ -19,10 +19,10 @@
.file-editor .file-editor
= f.label :file_name, "File" = f.label :file_name, "File"
.input .input
.file_holder.snippet .file-holder.snippet
.file_title .file-title
= f.text_field :file_name, placeholder: "example.rb", class: 'snippet-file-name', required: true = f.text_field :file_name, placeholder: "example.rb", class: 'snippet-file-name', required: true
.file_content.code .file-content.code
%pre#editor= @snippet.content %pre#editor= @snippet.content
= f.hidden_field :content, class: 'snippet-file-content' = f.hidden_field :content, class: 'snippet-file-content'
......
.file_holder#README .file-holder#README
.file_title .file-title
%i.icon-file %i.icon-file
= readme.name = readme.name
.file_content.wiki .file-content.wiki
- if gitlab_markdown?(readme.name) - if gitlab_markdown?(readme.name)
= preserve do = preserve do
= markdown(readme.data) = markdown(readme.data)
......
...@@ -8,8 +8,8 @@ ...@@ -8,8 +8,8 @@
This is an old version of this page. This is an old version of this page.
You can view the #{link_to "most recent version", project_wiki_path(@project, @wiki)} or browse the #{link_to "history", history_project_wiki_path(@project, @wiki)}. You can view the #{link_to "most recent version", project_wiki_path(@project, @wiki)} or browse the #{link_to "history", history_project_wiki_path(@project, @wiki)}.
.file_holder .file-holder
.file_content.wiki .file-content.wiki
= preserve do = preserve do
= render_wiki_content(@wiki) = render_wiki_content(@wiki)
......
%li %li
.file_holder .file-holder
.file_title .file-title
= link_to project_blob_path(@project, tree_join(blob.ref, blob.filename), :anchor => "L" + blob.startline.to_s) do = link_to project_blob_path(@project, tree_join(blob.ref, blob.filename), :anchor => "L" + blob.startline.to_s) do
%i.icon-file %i.icon-file
%strong %strong
= blob.filename = blob.filename
.file_content.code.term .file-content.code.term
%div{class: user_color_scheme_class} %div{class: user_color_scheme_class}
= raw blob.colorize( formatter: :gitlab, options: { first_line_number: blob.startline } ) = raw blob.colorize( formatter: :gitlab, options: { first_line_number: blob.startline } )
.file_holder .file-holder
.file_title .file-title
%i.icon-file %i.icon-file
%strong= @snippet.file_name %strong= @snippet.file_name
%span.options %span.options
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
= link_to "Edit", edit_snippet_path(@snippet), class: "btn btn-tiny", title: 'Edit Snippet' = link_to "Edit", edit_snippet_path(@snippet), class: "btn btn-tiny", title: 'Edit Snippet'
= link_to "Delete", snippet_path(@snippet), method: :delete, confirm: "Are you sure?", class: "btn btn-tiny", title: 'Delete Snippet' = link_to "Delete", snippet_path(@snippet), method: :delete, confirm: "Are you sure?", class: "btn btn-tiny", title: 'Delete Snippet'
= link_to "Raw", raw_snippet_path(@snippet), class: "btn btn-tiny", target: "_blank" = link_to "Raw", raw_snippet_path(@snippet), class: "btn btn-tiny", target: "_blank"
.file_content.code .file-content.code
- unless @snippet.content.empty? - unless @snippet.content.empty?
%div{class: user_color_scheme_class} %div{class: user_color_scheme_class}
= raw @snippet.colorize(formatter: :gitlab) = raw @snippet.colorize(formatter: :gitlab)
......
...@@ -22,10 +22,10 @@ ...@@ -22,10 +22,10 @@
.file-editor .file-editor
= f.label :file_name, "File" = f.label :file_name, "File"
.input .input
.file_holder.snippet .file-holder.snippet
.file_title .file-title
= f.text_field :file_name, placeholder: "example.rb", class: 'snippet-file-name', required: true = f.text_field :file_name, placeholder: "example.rb", class: 'snippet-file-name', required: true
.file_content.code .file-content.code
%pre#editor= @snippet.content %pre#editor= @snippet.content
= f.hidden_field :content, class: 'snippet-file-content' = f.hidden_field :content, class: 'snippet-file-content'
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment