Skip to content
Snippets Groups Projects
Commit c43b2896 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets
Browse files

Merge branch '6-0-dev' of /home/git/repositories/gitlab/gitlabhq

parents f1fc1ae6 92ef845f
No related branches found
No related tags found
No related merge requests found
Showing
with 279 additions and 139 deletions
v 6.0.0
- Epic: Replace teams with group membership
- Add project filter on dashboard
- cache project graph
- Drop support of root namespaces
- Redesign project settings navigation
- Restlyed login screen
- Default theme is classic now
- Cache result of methods like authorize_projects, project.team.members etc
- Remove $.ready events
- Fix onclick events being double binded
- Add notification level to group membership
- Move all project controllers/views under Projects:: module
- Move all profile controllers/views under Profiles:: module
- Redesign ssh keys page
- Generate fingerprint for ssh keys
- You an use arrows to navigate at tree view
- Apply user project limit only for personal projects
v 5.4.0
- Ability to edit own comments
- Documentation improvements
Loading
Loading
load 'deploy'
load 'deploy/assets'
require 'bundler/capistrano'
load 'config/deploy'
Loading
Loading
@@ -23,7 +23,7 @@ gem 'omniauth-github'
 
# Extracting information from a git repository
# Provide access to Gitlab::Git library
gem 'gitlab_git', '~> 1.3.0'
gem 'gitlab_git', '~> 1.4.1'
 
# Ruby/Rack Git Smart-HTTP Server Handler
gem 'gitlab-grack', '~> 1.0.1', require: 'grack'
Loading
Loading
@@ -35,7 +35,7 @@ gem 'gitlab_omniauth-ldap', '1.0.3', require: "omniauth-ldap"
gem "gitlab-pygments.rb", '~> 0.3.2', require: 'pygments.rb'
 
# Git Wiki
gem "gitlab-gollum-lib", "~> 1.0.0", require: 'gollum-lib'
gem "gitlab-gollum-lib", "~> 1.0.1", require: 'gollum-lib'
 
# Language detection
gem "github-linguist", require: "linguist"
Loading
Loading
@@ -173,7 +173,7 @@ group :development, :test do
gem 'factory_girl_rails'
 
# Prevent occasions where minitest is not bundled in packaged versions of ruby (see #3826)
gem 'minitest'
gem 'minitest', '~> 4.7.0'
 
# Generate Fake data
gem "ffaker"
Loading
Loading
@@ -203,5 +203,5 @@ group :test do
end
 
group :production do
gem "gitlab_meta", '5.0'
gem "gitlab_meta", '6.0'
end
GIT
remote: https://github.com/ctran/annotate_models.git
revision: 8bd159c7a484093fde84beaa9e6398f25ddacf09
revision: 18a4e2eb77c8f3ef695b563e4a7ca45dfede819b
specs:
annotate (2.6.0.beta1)
annotate (2.6.0.beta2)
activerecord (>= 2.3.0)
rake (>= 0.8.7)
 
Loading
Loading
@@ -42,20 +42,20 @@ GEM
activesupport (3.2.13)
i18n (= 0.6.1)
multi_json (~> 1.0)
acts-as-taggable-on (2.4.0)
rails (~> 3.0)
acts-as-taggable-on (2.4.1)
rails (>= 3, < 5)
addressable (2.3.4)
arel (3.0.2)
asciidoctor (0.1.3)
awesome_print (1.1.0)
backports (2.6.7)
backports (3.3.2)
bcrypt-ruby (3.0.1)
better_errors (0.8.0)
better_errors (0.9.0)
coderay (>= 1.0.0)
erubis (>= 2.6.6)
binding_of_caller (0.7.1)
binding_of_caller (0.7.2)
debug_inspector (>= 0.0.1)
bootstrap-sass (2.3.1.0)
bootstrap-sass (2.3.2.0)
sass (~> 3.2)
builder (3.0.4)
capybara (2.1.0)
Loading
Loading
@@ -67,7 +67,7 @@ GEM
carrierwave (0.8.0)
activemodel (>= 3.2.0)
activesupport (>= 3.2.0)
celluloid (0.14.0)
celluloid (0.14.1)
timers (>= 1.0.0)
charlock_holmes (0.6.9.4)
childprocess (0.3.9)
Loading
Loading
@@ -75,7 +75,7 @@ GEM
chosen-rails (0.9.8)
railties (~> 3.0)
thor (~> 0.14)
code_analyzer (0.3.1)
code_analyzer (0.3.2)
sexp_processor
coderay (1.0.9)
coffee-rails (3.2.2)
Loading
Loading
@@ -87,15 +87,16 @@ GEM
coffee-script-source (1.6.2)
colored (1.2)
colorize (0.5.8)
connection_pool (1.0.0)
connection_pool (1.1.0)
coveralls (0.6.7)
colorize
multi_json (~> 1.3)
rest-client
simplecov (>= 0.7)
thor
crack (0.3.2)
d3_rails (3.1.4)
crack (0.4.0)
safe_yaml (~> 0.9.0)
d3_rails (3.1.10)
railties (>= 3.1.0)
daemons (1.1.9)
database_cleaner (1.0.1)
Loading
Loading
@@ -107,11 +108,11 @@ GEM
railties (~> 3.1)
warden (~> 1.2.1)
diff-lcs (1.2.4)
dotenv (0.7.0)
dotenv (0.8.0)
email_spec (1.4.0)
launchy (~> 2.1)
mail (~> 2.2)
enumerize (0.5.1)
enumerize (0.6.1)
activesupport (>= 3.2)
erubis (2.7.0)
escape_utils (0.2.4)
Loading
Loading
@@ -130,8 +131,8 @@ GEM
faraday (>= 0.7.4, < 0.9)
faye-websocket (0.4.7)
eventmachine (>= 0.12.0)
ffaker (1.16.0)
ffi (1.8.1)
ffaker (1.16.1)
ffi (1.9.0)
fog (1.3.1)
builder
excon (~> 0.13.0)
Loading
Loading
@@ -157,17 +158,17 @@ GEM
pygments.rb (>= 0.2.13)
github-markdown (0.5.3)
github-markup (0.7.5)
gitlab-gollum-lib (1.0.0)
gitlab-gollum-lib (1.0.1)
github-markdown (~> 0.5.3)
github-markup (>= 0.7.5, < 1.0.0)
gitlab-grit (~> 2.5.1)
gitlab-grit (>= 2.5.1)
nokogiri (~> 1.5.9)
pygments.rb (~> 0.4.2)
sanitize (~> 2.0.3)
stringex (~> 1.5.1)
gitlab-grack (1.0.1)
rack (~> 1.4.1)
gitlab-grit (2.5.1)
gitlab-grit (2.6.0)
charlock_holmes (~> 0.6.9)
diff-lcs (~> 1.1)
mime-types (~> 1.15)
Loading
Loading
@@ -175,17 +176,17 @@ GEM
gitlab-pygments.rb (0.3.2)
posix-spawn (~> 0.3.6)
yajl-ruby (~> 1.1.0)
gitlab_git (1.3.0)
gitlab_git (1.4.1)
activesupport (~> 3.2.13)
github-linguist (~> 2.3.4)
gitlab-grit (~> 2.5.1)
gitlab_meta (5.0)
gitlab-grit (~> 2.6.0)
gitlab_meta (6.0)
gitlab_omniauth-ldap (1.0.3)
net-ldap (~> 0.3.1)
omniauth (~> 1.0)
pyu-ruby-sasl (~> 0.0.3.1)
rubyntlm (~> 0.1.1)
gon (4.1.0)
gon (4.1.1)
actionpack (>= 2.3.0)
json
grape (0.4.1)
Loading
Loading
@@ -202,19 +203,19 @@ GEM
activesupport
multi_json (>= 1.3.2)
growl (1.0.3)
guard (1.8.0)
guard (1.8.1)
formatador (>= 0.2.4)
listen (>= 1.0.0)
lumberjack (>= 1.0.2)
pry (>= 0.9.10)
thor (>= 0.14.6)
guard-rspec (3.0.0)
guard-rspec (3.0.2)
guard (>= 1.8)
rspec (~> 2.13)
guard-spinach (0.0.2)
guard (>= 1.1)
spinach
haml (4.0.2)
haml (4.0.3)
tilt
haml-rails (0.4)
actionpack (>= 3.1, < 4.1)
Loading
Loading
@@ -222,9 +223,10 @@ GEM
haml (>= 3.1, < 4.1)
railties (>= 3.1, < 4.1)
hashie (1.2.0)
hike (1.2.2)
hike (1.2.3)
hipchat (0.9.0)
httparty
httparty
http_parser.rb (0.5.3)
httparty (0.11.0)
multi_json (~> 1.0)
Loading
Loading
@@ -255,18 +257,17 @@ GEM
actionpack (>= 3.0.0)
activesupport (>= 3.0.0)
kgio (2.8.0)
launchy (2.2.0)
launchy (2.3.0)
addressable (~> 2.3)
letter_opener (1.1.0)
launchy (~> 2.2.0)
letter_opener (1.1.1)
launchy (~> 2.2)
libv8 (3.11.8.17)
listen (1.1.3)
listen (1.2.2)
rb-fsevent (>= 0.9.3)
rb-inotify (>= 0.9)
rb-kqueue (>= 0.2)
lumberjack (1.0.3)
mail (2.5.3)
i18n (>= 0.4.0)
mail (2.5.4)
mime-types (~> 1.16)
treetop (~> 1.4.8)
method_source (0.8.1)
Loading
Loading
@@ -274,15 +275,15 @@ GEM
minitest (4.7.4)
modernizr (2.6.2)
sprockets (~> 2.0)
multi_json (1.7.3)
multi_xml (0.5.3)
multi_json (1.7.7)
multi_xml (0.5.4)
multipart-post (1.2.0)
mysql2 (0.3.11)
net-ldap (0.3.1)
net-scp (1.0.4)
net-ssh (>= 1.99.1)
net-ssh (2.6.8)
nokogiri (1.5.9)
nokogiri (1.5.10)
oauth (0.4.7)
oauth2 (0.8.1)
faraday (~> 0.8)
Loading
Loading
@@ -296,7 +297,7 @@ GEM
omniauth-github (1.1.0)
omniauth (~> 1.0)
omniauth-oauth2 (~> 1.1)
omniauth-google-oauth2 (0.1.17)
omniauth-google-oauth2 (0.1.19)
omniauth (~> 1.0)
omniauth-oauth2
omniauth-oauth (1.0.1)
Loading
Loading
@@ -305,7 +306,7 @@ GEM
omniauth-oauth2 (1.1.1)
oauth2 (~> 0.8.0)
omniauth (~> 1.0)
omniauth-twitter (0.0.16)
omniauth-twitter (0.0.17)
multi_json (~> 1.3)
omniauth-oauth (~> 1.0)
orm_adapter (0.4.0)
Loading
Loading
@@ -354,7 +355,7 @@ GEM
rails-dev-tweaks (0.6.1)
actionpack (~> 3.1)
railties (~> 3.1)
rails_best_practices (1.13.4)
rails_best_practices (1.13.8)
activesupport
awesome_print
code_analyzer
Loading
Loading
@@ -370,7 +371,7 @@ GEM
rdoc (~> 3.4)
thor (>= 0.14.6, < 2.0)
raindrops (0.11.0)
rake (10.0.4)
rake (10.1.0)
rb-fsevent (0.9.3)
rb-inotify (0.9.0)
ffi (>= 0.5.0)
Loading
Loading
@@ -398,7 +399,7 @@ GEM
redis-store (~> 1.1.0)
redis-store (1.1.3)
redis (>= 2.2.0)
ref (1.0.4)
ref (1.0.5)
rest-client (1.6.7)
mime-types (>= 1.16)
rspec (2.13.0)
Loading
Loading
@@ -409,7 +410,7 @@ GEM
rspec-expectations (2.13.0)
diff-lcs (>= 1.1.3, < 2.0)
rspec-mocks (2.13.1)
rspec-rails (2.13.1)
rspec-rails (2.13.2)
actionpack (>= 3.0)
activesupport (>= 3.0)
railties (>= 3.0)
Loading
Loading
@@ -417,9 +418,10 @@ GEM
rspec-expectations (~> 2.13.0)
rspec-mocks (~> 2.13.0)
ruby-hmac (0.4.0)
ruby-progressbar (1.0.2)
ruby-progressbar (1.1.1)
rubyntlm (0.1.1)
rubyzip (0.9.9)
safe_yaml (0.9.3)
sanitize (2.0.3)
nokogiri (>= 1.4.4, < 1.6)
sass (3.2.9)
Loading
Loading
@@ -433,10 +435,10 @@ GEM
seed-fu (2.2.0)
activerecord (~> 3.1)
activesupport (~> 3.1)
select2-rails (3.3.1)
sass-rails (>= 3.2)
select2-rails (3.4.2)
sass-rails
thor (~> 0.14)
selenium-webdriver (2.32.1)
selenium-webdriver (2.33.0)
childprocess (>= 0.2.5)
multi_json (~> 1.0)
rubyzip
Loading
Loading
@@ -445,8 +447,8 @@ GEM
sexp_processor (4.2.1)
shoulda-matchers (2.1.0)
activesupport (>= 3.0.0)
sidekiq (2.12.0)
celluloid (>= 0.14.0)
sidekiq (2.12.4)
celluloid (>= 0.14.1)
connection_pool (>= 1.0.0)
json
redis (>= 3.0)
Loading
Loading
@@ -456,23 +458,23 @@ GEM
multi_json (~> 1.0)
simplecov-html (~> 0.7.1)
simplecov-html (0.7.1)
sinatra (1.3.6)
sinatra (1.4.3)
rack (~> 1.4)
rack-protection (~> 1.3)
tilt (~> 1.3, >= 1.3.3)
rack-protection (~> 1.4)
tilt (~> 1.3, >= 1.3.4)
six (0.2.0)
slim (1.3.8)
temple (~> 0.6.3)
tilt (~> 1.3.3)
slim (2.0.0)
temple (~> 0.6.5)
tilt (~> 1.3, >= 1.3.3)
slop (3.4.5)
spinach (0.8.2)
spinach (0.8.3)
colorize (= 0.5.8)
gherkin-ruby (~> 0.3.0)
spinach-rails (0.2.1)
capybara (>= 2.0.0)
railties (>= 3)
spinach (>= 0.4)
spork (1.0.0rc3)
spork (1.0.0rc2)
sprockets (2.2.2)
hike (~> 1.2)
multi_json (~> 1.0)
Loading
Loading
@@ -481,7 +483,7 @@ GEM
stamp (0.5.0)
state_machine (1.2.0)
stringex (1.5.1)
temple (0.6.4)
temple (0.6.5)
test_after_commit (0.2.0)
therubyracer (0.11.4)
libv8 (~> 3.11.8.12)
Loading
Loading
@@ -491,7 +493,7 @@ GEM
eventmachine (>= 0.12.6)
rack (>= 1.0.0)
thor (0.18.1)
tilt (1.3.7)
tilt (1.4.1)
timers (1.1.0)
tinder (1.9.2)
eventmachine (~> 1.0)
Loading
Loading
@@ -502,17 +504,17 @@ GEM
mime-types (~> 1.19)
multi_json (~> 1.5)
twitter-stream (~> 0.1)
treetop (1.4.12)
treetop (1.4.14)
polyglot
polyglot (>= 0.3.1)
turbolinks (1.1.1)
turbolinks (1.2.0)
coffee-rails
twitter-stream (0.1.16)
eventmachine (>= 0.12.8)
http_parser.rb (~> 0.5.1)
simple_oauth (~> 0.1.4)
tzinfo (0.3.37)
uglifier (2.0.1)
uglifier (2.1.1)
execjs (>= 0.3.0)
multi_json (~> 1.0, >= 1.0.2)
underscore-rails (1.4.4)
Loading
Loading
@@ -520,8 +522,8 @@ GEM
kgio (~> 2.6)
rack
raindrops (~> 0.7)
virtus (0.5.4)
backports (~> 2.6.1)
virtus (0.5.5)
backports (~> 3.3)
descendants_tracker (~> 0.0.1)
warden (1.2.1)
rack (>= 1.0)
Loading
Loading
@@ -563,11 +565,11 @@ DEPENDENCIES
gemoji (~> 1.2.1)
github-linguist
github-markup (~> 0.7.4)
gitlab-gollum-lib (~> 1.0.0)
gitlab-gollum-lib (~> 1.0.1)
gitlab-grack (~> 1.0.1)
gitlab-pygments.rb (~> 0.3.2)
gitlab_git (~> 1.3.0)
gitlab_meta (= 5.0)
gitlab_git (~> 1.4.1)
gitlab_meta (= 6.0)
gitlab_omniauth-ldap (= 1.0.3)
gon
grape (~> 0.4.1)
Loading
Loading
@@ -586,7 +588,7 @@ DEPENDENCIES
kaminari (~> 0.14.1)
launchy
letter_opener
minitest
minitest (~> 4.7.0)
modernizr (= 2.6.2)
mysql2
omniauth (~> 1.1.3)
Loading
Loading
web: bundle exec puma -p $PORT
web: bundle exec unicorn_rails -p $PORT -E development
worker: bundle exec sidekiq -q post_receive,mailer,system_hook,project_web_hook,common,default,gitlab_shell
5.4.0.rc1
6.0.0.pre
app/assets/images/login-logo.png

1.4 KiB | W: 304px | H: 66px

app/assets/images/login-logo.png

9.97 KiB | W: 304px | H: 114px

app/assets/images/login-logo.png
app/assets/images/login-logo.png
app/assets/images/login-logo.png
app/assets/images/login-logo.png
  • 2-up
  • Swipe
  • Onion skin
class BlobView
constructor: ->
# See if there are lines selected
# "#L12" and "#L34-56" supported
highlightBlobLines = ->
if window.location.hash isnt ""
matches = window.location.hash.match(/\#L(\d+)(\-(\d+))?/)
first_line = parseInt(matches?[1])
last_line = parseInt(matches?[3])
unless isNaN first_line
last_line = first_line if isNaN(last_line)
$("#tree-content-holder .highlight .line").removeClass("hll")
$("#LC#{line}").addClass("hll") for line in [first_line..last_line]
$("#L#{first_line}").ScrollTo()
# Highlight the correct lines on load
highlightBlobLines()
# Highlight the correct lines when the hash part of the URL changes
$(window).on 'hashchange', highlightBlobLines
@BlobView = BlobView
Loading
Loading
@@ -8,6 +8,22 @@ class Dashboard
@toggleFilter($(event.currentTarget))
@reloadActivities()
 
$(".dash-filter").keyup ->
terms = $(this).val()
uiBox = $(this).parents('.ui-box').first()
if terms == "" || terms == undefined
uiBox.find(".dash-list li").show()
else
uiBox.find(".dash-list li").each (index) ->
name = $(this).find(".well-title").text()
if name.toLowerCase().search(terms.toLowerCase()) == -1
$(this).hide()
else
$(this).show()
reloadActivities: ->
$(".content_list").html ''
Pager.init 20, true
Loading
Loading
Loading
Loading
@@ -16,20 +16,26 @@ class Dispatcher
path = page.split(':')
 
switch page
when 'issues:index'
when 'projects:issues:index'
Issues.init()
when 'dashboard:show'
new Dashboard()
when 'commit:show'
when 'projects:commit:show'
new Commit()
when 'groups:show', 'teams:show', 'projects:show'
when 'groups:show', 'projects:show'
Pager.init(20, true)
when 'projects:new', 'projects:edit'
new Project()
when 'walls:show'
when 'projects:walls:show'
new Wall(project_id)
when 'teams:members:index'
when 'projects:teams:members:index'
new TeamMembers()
when 'groups:people'
new GroupMembers()
when 'projects:tree:show'
new TreeView()
when 'projects:blob:show'
new BlobView()
 
switch path.first()
when 'admin' then new Admin()
Loading
Loading
class GroupMembers
constructor: ->
$('li.users_group').bind 'ajax:success', ->
$(this).fadeOut()
@GroupMembers = GroupMembers
Loading
Loading
@@ -50,11 +50,12 @@ window.startSpinner = ->
window.stopSpinner = ->
$('.turbolink-spinner').fadeOut()
 
window.stopEndlessScroll = ->
window.unbindEvents = ->
$(document).unbind('scroll')
$(document).off('scroll')
 
document.addEventListener("page:fetch", startSpinner)
document.addEventListener("page:fetch", stopEndlessScroll)
document.addEventListener("page:fetch", unbindEvents)
document.addEventListener("page:receive", stopSpinner)
 
$ ->
Loading
Loading
@@ -66,7 +67,6 @@ $ ->
$('.appear-data').fadeIn()
e.preventDefault()
 
# Initialize chosen selects
$('select.chosen').chosen()
 
Loading
Loading
@@ -110,6 +110,10 @@ $ ->
when 115
$("#search").focus()
e.preventDefault()
when 63
new Shortcuts()
e.preventDefault()
 
# Commit show suppressed diff
$(".supp_diff_link").bind "click", ->
Loading
Loading
var NoteList = {
id: null,
notes_path: null,
target_params: null,
target_id: 0,
Loading
Loading
@@ -16,6 +16,22 @@ var NoteList = {
// get initial set of notes
NoteList.getContent();
 
// Unbind events to prevent firing twice
$(document).off("click", ".js-add-diff-note-button");
$(document).off("click", ".js-discussion-reply-button");
$(document).off("click", ".js-note-preview-button");
$(document).off("click", ".js-note-attachment-input");
$(document).off("click", ".js-close-discussion-note-form");
$(document).off("click", ".js-note-delete");
$(document).off("click", ".js-note-edit");
$(document).off("click", ".js-note-edit-cancel");
$(document).off("click", ".js-note-attachment-delete");
$(document).off("click", ".js-choose-note-attachment-button");
$(document).off("click", ".js-show-outdated-discussion");
$(document).off("ajax:complete", ".js-main-target-form");
// add a new diff note
$(document).on("click",
".js-add-diff-note-button",
Loading
Loading
class Shortcuts
constructor: ->
if $('#modal-shortcuts').length > 0
$('#modal-shortcuts').modal('show')
else
$.ajax(
url: '/help/shortcuts',
dataType: "script"
)
@Shortcuts = Shortcuts
Loading
Loading
@@ -12,14 +12,35 @@ class window.ContributorsStatGraph
@master_graph.draw()
add_authors_graph: (author_data) ->
@authors = []
_.each(author_data, (d) =>
limited_author_data = author_data.slice(0, 100)
_.each(limited_author_data, (d) =>
author_header = @create_author_header(d)
$(".contributors-list").append(author_header)
@authors[d.author] = author_graph = new ContributorsAuthorGraph(d.dates)
author_graph.draw()
)
format_author_commit_info: (author) ->
author.commits + " commits " + author.additions + " ++ / " + author.deletions + " --"
commits = $('<span/>', {
class: 'graph-author-commits-count'
})
commits.text(author.commits + " commits")
additions = $('<span/>', {
class: 'graph-additions'
})
additions.text(author.additions + " ++")
deletions = $('<span/>', {
class: 'graph-deletions'
})
deletions.text(author.deletions + " --")
$('<span/>').append(commits)
.append(" / ")
.append(additions)
.append(" / ")
.append(deletions)
create_author_header: (author) ->
list_item = $('<li/>', {
class: 'person'
Loading
Loading
@@ -30,7 +51,7 @@ class window.ContributorsStatGraph
class: 'commits'
})
author_commit_info = @format_author_commit_info(author)
author_commit_info_span.text(author_commit_info)
author_commit_info_span.html(author_commit_info)
list_item.append(author_name)
list_item.append(author_commit_info_span)
list_item
Loading
Loading
@@ -52,10 +73,10 @@ class window.ContributorsStatGraph
@field = field
change_date_header: ->
x_domain = ContributorsGraph.prototype.x_domain
print_date_format = d3.time.format("%B %e %Y");
print = print_date_format(x_domain[0]) + " - " + print_date_format(x_domain[1]);
$("#date_header").text(print);
print_date_format = d3.time.format("%B %e %Y")
print = print_date_format(x_domain[0]) + " - " + print_date_format(x_domain[1])
$("#date_header").text(print)
redraw_author_commit_info: (author) ->
author_list_item = $(@authors[author.author].list_item)
author_commit_info = @format_author_commit_info(author)
author_list_item.find("span").text(author_commit_info)
\ No newline at end of file
author_list_item.find("span").html(author_commit_info)
Loading
Loading
@@ -71,7 +71,7 @@ class window.ContributorsMasterGraph extends ContributorsGraph
super @width, @height
create_axes: ->
@x_axis = d3.svg.axis().scale(@x).orient("bottom")
@y_axis = d3.svg.axis().scale(@y).orient("left")
@y_axis = d3.svg.axis().scale(@y).orient("left").ticks(5)
create_svg: ->
@svg = d3.select("#contributors-master").append("svg")
.attr("width", @width + @MARGIN.left + @MARGIN.right)
Loading
Loading
@@ -130,8 +130,8 @@ class window.ContributorsAuthorGraph extends ContributorsGraph
create_scale: ->
super @width, @height
create_axes: ->
@x_axis = d3.svg.axis().scale(@x).orient("bottom").tickFormat(d3.time.format("%m/%d"));
@y_axis = d3.svg.axis().scale(@y).orient("left")
@x_axis = d3.svg.axis().scale(@x).orient("bottom").ticks(8)
@y_axis = d3.svg.axis().scale(@y).orient("left").ticks(5)
create_area: (x, y) ->
@area = d3.svg.area().x((d) ->
parseDate = d3.time.format("%Y-%m-%d").parse
Loading
Loading
@@ -148,7 +148,7 @@ class window.ContributorsAuthorGraph extends ContributorsGraph
.append("g")
.attr("transform", "translate(" + @MARGIN.left + "," + @MARGIN.top + ")")
draw_path: (data) ->
@svg.append("path").datum(data).attr("class", "area-contributor").attr("d", @area);
@svg.append("path").datum(data).attr("class", "area-contributor").attr("d", @area)
draw: ->
@create_scale()
@create_axes()
Loading
Loading
# Code browser tree slider
# Make the entire tree-item row clickable, but not if clicking another link (like a commit message)
$(".tree-content-holder .tree-item").live 'click', (e) ->
if (e.target.nodeName != "A")
path = $('.tree-item-file-name a', this).attr('href')
Turbolinks.visit(path)
class TreeView
constructor: ->
@initKeyNav()
 
$ ->
# Show the "Loading commit data" for only the first element
$('span.log_loading:first').removeClass('hide')
# Code browser tree slider
# Make the entire tree-item row clickable, but not if clicking another link (like a commit message)
$(".tree-content-holder .tree-item").on 'click', (e) ->
if (e.target.nodeName != "A")
path = $('.tree-item-file-name a', this).attr('href')
Turbolinks.visit(path)
 
# See if there are lines selected
# "#L12" and "#L34-56" supported
highlightBlobLines = ->
if window.location.hash isnt ""
matches = window.location.hash.match(/\#L(\d+)(\-(\d+))?/)
first_line = parseInt(matches?[1])
last_line = parseInt(matches?[3])
# Show the "Loading commit data" for only the first element
$('span.log_loading:first').removeClass('hide')
 
unless isNaN first_line
last_line = first_line if isNaN(last_line)
$("#tree-content-holder .highlight .line").removeClass("hll")
$("#LC#{line}").addClass("hll") for line in [first_line..last_line]
$("#L#{first_line}").ScrollTo()
initKeyNav: ->
li = $("tr.tree-item")
liSelected = null
$('body').keydown (e) ->
if e.which is 40
if liSelected
next = liSelected.next()
if next.length > 0
liSelected.removeClass "selected"
liSelected = next.addClass("selected")
else
liSelected = li.eq(0).addClass("selected")
 
# Highlight the correct lines on load
highlightBlobLines()
# Highlight the correct lines when the hash part of the URL changes
$(window).on 'hashchange', highlightBlobLines
$(liSelected).focus()
else if e.which is 38
if liSelected
next = liSelected.prev()
if next.length > 0
liSelected.removeClass "selected"
liSelected = next.addClass("selected")
else
liSelected = li.last().addClass("selected")
$(liSelected).focus()
else if e.which is 13
path = $('.tree-item.selected .tree-item-file-name a').attr('href')
Turbolinks.visit(path)
@TreeView = TreeView
Loading
Loading
@@ -206,17 +206,6 @@ p.time {
}
}
 
.arrow{
background: #E3E5EA;
padding: 5px;
margin-top: 5px;
@include border-radius(5px);
text-shadow: none;
color: #999;
line-height: 16px;
font-weight: bold;
}
.thin_area{
height: 150px;
}
Loading
Loading
@@ -311,14 +300,17 @@ li.note {
}
}
 
.error_message {
@extend .cred;
border-left: 4px solid #E99;
.error-message {
padding: 10px;
margin-bottom: 10px;
background: #FEE;
background: #C67;
padding-left: 20px;
margin: 0;
color: #FFF;
 
a {
color: #fff;
text-decoration: underline;
}
&.centered {
text-align: center;
}
Loading
Loading
Loading
Loading
@@ -87,3 +87,10 @@ fieldset legend { font-size: 17px; }
color: #333;
text-shadow: 0 1px 1px #FFF;
}
pre.well-pre {
border: 1px solid #EEE;
background: #f9f9f9;
border-radius: 0;
color: #555;
}
Loading
Loading
@@ -16,6 +16,12 @@
color: #888;
}
 
&.unstyled {
&:hover {
background: none;
}
}
&.smoke { background-color: #f5f5f5; }
 
&:hover {
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment