Commit 2eb19ea3 authored by Douwe Maan's avatar Douwe Maan

Merge branch 'master' into issue_12658

parents 8b830b8c 01fe50a7
Please view this file on the master branch, on stable branches it's out of date. Please view this file on the master branch, on stable branches it's out of date.
v 8.6.0 (unreleased) v 8.6.0 (unreleased)
- Fix bug where wrong commit ID was being used in a merge request diff to show old image (Stan Hu)
- Add confidential issues
- Bump gitlab_git to 9.0.3 (Stan Hu) - Bump gitlab_git to 9.0.3 (Stan Hu)
- Support Golang subpackage fetching (Stan Hu) - Support Golang subpackage fetching (Stan Hu)
- Bump Capybara gem to 2.6.2 (Stan Hu) - Bump Capybara gem to 2.6.2 (Stan Hu)
- New branch button appears on issues where applicable
- Contributions to forked projects are included in calendar - Contributions to forked projects are included in calendar
- Improve the formatting for the user page bio (Connor Shea) - Improve the formatting for the user page bio (Connor Shea)
- Easily (un)mark merge request as WIP using link
- Use specialized system notes when MR is (un)marked as WIP
- Removed the default password from the initial admin account created during - Removed the default password from the initial admin account created during
setup. A password can be provided during setup (see installation docs), or setup. A password can be provided during setup (see installation docs), or
GitLab will ask the user to create a new one upon first visit. GitLab will ask the user to create a new one upon first visit.
- Fix issue when pushing to projects ending in .wiki - Fix issue when pushing to projects ending in .wiki
- Add support for wiki with UTF-8 page names (Hiroyuki Sato)
- Fix wiki search results point to raw source (Hiroyuki Sato)
- Don't load all of GitLab in mail_room - Don't load all of GitLab in mail_room
- HTTP error pages work independently from location and config (Artem Sidorenko)
- Update `omniauth-saml` to 1.5.0 to allow for custom response attributes to be set - Update `omniauth-saml` to 1.5.0 to allow for custom response attributes to be set
- Memoize @group in Admin::GroupsController (Yatish Mehta) - Memoize @group in Admin::GroupsController (Yatish Mehta)
- Indicate how much an MR diverged from the target branch (Pierre de La Morinerie) - Indicate how much an MR diverged from the target branch (Pierre de La Morinerie)
- Added omniauth-auth0 Gem (Daniel Carraro)
- Add label description in tooltip to labels in issue index and sidebar
- Strip leading and trailing spaces in URL validator (evuez) - Strip leading and trailing spaces in URL validator (evuez)
- Add "last_sign_in_at" and "confirmed_at" to GET /users/* API endpoints for admins (evuez) - Add "last_sign_in_at" and "confirmed_at" to GET /users/* API endpoints for admins (evuez)
- Return empty array instead of 404 when commit has no statuses in commit status API - Return empty array instead of 404 when commit has no statuses in commit status API
...@@ -21,6 +31,7 @@ v 8.6.0 (unreleased) ...@@ -21,6 +31,7 @@ v 8.6.0 (unreleased)
- Rewrite logo to simplify SVG code (Sean Lang) - Rewrite logo to simplify SVG code (Sean Lang)
- Allow to use YAML anchors when parsing the `.gitlab-ci.yml` (Pascal Bach) - Allow to use YAML anchors when parsing the `.gitlab-ci.yml` (Pascal Bach)
- Ignore jobs that start with `.` (hidden jobs) - Ignore jobs that start with `.` (hidden jobs)
- Hide builds from project's settings when the feature is disabled
- Allow to pass name of created artifacts archive in `.gitlab-ci.yml` - Allow to pass name of created artifacts archive in `.gitlab-ci.yml`
- Refactor and greatly improve search performance - Refactor and greatly improve search performance
- Add support for cross-project label references - Add support for cross-project label references
...@@ -32,14 +43,26 @@ v 8.6.0 (unreleased) ...@@ -32,14 +43,26 @@ v 8.6.0 (unreleased)
- Fix bug where Bitbucket `closed` issues were imported as `opened` (Iuri de Silvio) - Fix bug where Bitbucket `closed` issues were imported as `opened` (Iuri de Silvio)
- Don't show Issues/MRs from archived projects in Groups view - Don't show Issues/MRs from archived projects in Groups view
- Fix wrong "iid of max iid" in Issuable sidebar for some merged MRs - Fix wrong "iid of max iid" in Issuable sidebar for some merged MRs
- Fix empty source_sha on Merge Request when there is no diff (Pierre de La Morinerie)
- Increase the notes polling timeout over time (Roberto Dip) - Increase the notes polling timeout over time (Roberto Dip)
- Add shortcut to toggle markdown preview (Florent Baldino) - Add shortcut to toggle markdown preview (Florent Baldino)
- Show labels in dashboard and group milestone views - Show labels in dashboard and group milestone views
- Fix an issue when the target branch of a MR had been deleted
- Add main language of a project in the list of projects (Tiago Botelho) - Add main language of a project in the list of projects (Tiago Botelho)
- Add #upcoming filter to Milestone filter (Tiago Botelho)
- Add ability to show archived projects on dashboard, explore and group pages - Add ability to show archived projects on dashboard, explore and group pages
- Move group activity to separate page - Move group activity to separate page
- Create external users which are excluded of internal and private projects unless access was explicitly granted - Create external users which are excluded of internal and private projects unless access was explicitly granted
- Continue parameters are checked to ensure redirection goes to the same instance - Continue parameters are checked to ensure redirection goes to the same instance
- User deletion is now done in the background so the request can not time out
- Canceled builds are now ignored in compound build status if marked as `allowed to fail`
- Trigger a todo for mentions on commits page
v 8.5.8
- Bump Git version requirement to 2.7.4
v 8.5.7
- Bump Git version requirement to 2.7.3
v 8.5.6 v 8.5.6
- Obtain a lease before querying LDAP - Obtain a lease before querying LDAP
...@@ -49,7 +72,6 @@ v 8.5.5 ...@@ -49,7 +72,6 @@ v 8.5.5
- Prevent a 500 error in Todos when author was removed - Prevent a 500 error in Todos when author was removed
- Fix pagination for filtered dashboard and explore pages - Fix pagination for filtered dashboard and explore pages
- Fix "Show all" link behavior - Fix "Show all" link behavior
- Add #upcoming filter to Milestone filter (Tiago Botelho)
v 8.5.4 v 8.5.4
- Do not cache requests for badges (including builds badge) - Do not cache requests for badges (including builds badge)
......
...@@ -22,6 +22,7 @@ gem 'devise', '~> 3.5.4' ...@@ -22,6 +22,7 @@ gem 'devise', '~> 3.5.4'
gem 'devise-async', '~> 0.9.0' gem 'devise-async', '~> 0.9.0'
gem 'doorkeeper', '~> 2.2.0' gem 'doorkeeper', '~> 2.2.0'
gem 'omniauth', '~> 1.3.1' gem 'omniauth', '~> 1.3.1'
gem 'omniauth-auth0', '~> 1.4.1'
gem 'omniauth-azure-oauth2', '~> 0.0.6' gem 'omniauth-azure-oauth2', '~> 0.0.6'
gem 'omniauth-bitbucket', '~> 0.0.2' gem 'omniauth-bitbucket', '~> 0.0.2'
gem 'omniauth-cas3', '~> 1.1.2' gem 'omniauth-cas3', '~> 1.1.2'
...@@ -50,7 +51,7 @@ gem "browser", '~> 1.0.0' ...@@ -50,7 +51,7 @@ gem "browser", '~> 1.0.0'
# Extracting information from a git repository # Extracting information from a git repository
# Provide access to Gitlab::Git library # Provide access to Gitlab::Git library
gem "gitlab_git", '~> 9.0' gem "gitlab_git", '~> 10.0'
# LDAP Auth # LDAP Auth
# GitLab fork with several improvements to original library. For full list of changes # GitLab fork with several improvements to original library. For full list of changes
...@@ -58,7 +59,9 @@ gem "gitlab_git", '~> 9.0' ...@@ -58,7 +59,9 @@ gem "gitlab_git", '~> 9.0'
gem 'gitlab_omniauth-ldap', '~> 1.2.1', require: "omniauth-ldap" gem 'gitlab_omniauth-ldap', '~> 1.2.1', require: "omniauth-ldap"
# Git Wiki # Git Wiki
gem 'gollum-lib', '~> 4.1.0' # Required manually in config/initializers/gollum.rb to control load order
gem 'gollum-lib', '~> 4.1.0', require: false
gem 'gollum-rugged_adapter', '~> 0.4.2', require: false
# Language detection # Language detection
gem "github-linguist", "~> 4.7.0", require: "linguist" gem "github-linguist", "~> 4.7.0", require: "linguist"
......
...@@ -359,11 +359,11 @@ GEM ...@@ -359,11 +359,11 @@ GEM
posix-spawn (~> 0.3) posix-spawn (~> 0.3)
gitlab_emoji (0.3.1) gitlab_emoji (0.3.1)
gemojione (~> 2.2, >= 2.2.1) gemojione (~> 2.2, >= 2.2.1)
gitlab_git (9.0.3) gitlab_git (10.0.0)
activesupport (~> 4.0) activesupport (~> 4.0)
charlock_holmes (~> 0.7.3) charlock_holmes (~> 0.7.3)
github-linguist (~> 4.7.0) github-linguist (~> 4.7.0)
rugged (~> 0.24.0b13) rugged (~> 0.24.0)
gitlab_meta (7.0) gitlab_meta (7.0)
gitlab_omniauth-ldap (1.2.1) gitlab_omniauth-ldap (1.2.1)
net-ldap (~> 0.9) net-ldap (~> 0.9)
...@@ -381,6 +381,9 @@ GEM ...@@ -381,6 +381,9 @@ GEM
rouge (~> 1.9) rouge (~> 1.9)
sanitize (~> 2.1.0) sanitize (~> 2.1.0)
stringex (~> 2.5.1) stringex (~> 2.5.1)
gollum-rugged_adapter (0.4.2)
mime-types (>= 1.15)
rugged (~> 0.24.0, >= 0.21.3)
gon (6.0.1) gon (6.0.1)
actionpack (>= 3.0) actionpack (>= 3.0)
json json
...@@ -495,6 +498,8 @@ GEM ...@@ -495,6 +498,8 @@ GEM
omniauth (1.3.1) omniauth (1.3.1)
hashie (>= 1.2, < 4) hashie (>= 1.2, < 4)
rack (>= 1.0, < 3) rack (>= 1.0, < 3)
omniauth-auth0 (1.4.1)
omniauth-oauth2 (~> 1.1)
omniauth-azure-oauth2 (0.0.6) omniauth-azure-oauth2 (0.0.6)
jwt (~> 1.0) jwt (~> 1.0)
omniauth (~> 1.0) omniauth (~> 1.0)
...@@ -703,7 +708,7 @@ GEM ...@@ -703,7 +708,7 @@ GEM
rubyntlm (0.5.2) rubyntlm (0.5.2)
rubypants (0.2.0) rubypants (0.2.0)
rufus-scheduler (3.1.10) rufus-scheduler (3.1.10)
rugged (0.24.0b13) rugged (0.24.0)
safe_yaml (1.0.4) safe_yaml (1.0.4)
sanitize (2.1.0) sanitize (2.1.0)
nokogiri (>= 1.4.4) nokogiri (>= 1.4.4)
...@@ -937,10 +942,11 @@ DEPENDENCIES ...@@ -937,10 +942,11 @@ DEPENDENCIES
github-markup (~> 1.3.1) github-markup (~> 1.3.1)
gitlab-flowdock-git-hook (~> 1.0.1) gitlab-flowdock-git-hook (~> 1.0.1)
gitlab_emoji (~> 0.3.0) gitlab_emoji (~> 0.3.0)
gitlab_git (~> 9.0) gitlab_git (~> 10.0)
gitlab_meta (= 7.0) gitlab_meta (= 7.0)
gitlab_omniauth-ldap (~> 1.2.1) gitlab_omniauth-ldap (~> 1.2.1)
gollum-lib (~> 4.1.0) gollum-lib (~> 4.1.0)
gollum-rugged_adapter (~> 0.4.2)
gon (~> 6.0.1) gon (~> 6.0.1)
grape (~> 0.13.0) grape (~> 0.13.0)
grape-entity (~> 0.4.2) grape-entity (~> 0.4.2)
...@@ -969,6 +975,7 @@ DEPENDENCIES ...@@ -969,6 +975,7 @@ DEPENDENCIES
oauth2 (~> 1.0.0) oauth2 (~> 1.0.0)
octokit (~> 3.8.0) octokit (~> 3.8.0)
omniauth (~> 1.3.1) omniauth (~> 1.3.1)
omniauth-auth0 (~> 1.4.1)
omniauth-azure-oauth2 (~> 0.0.6) omniauth-azure-oauth2 (~> 0.0.6)
omniauth-bitbucket (~> 0.0.2) omniauth-bitbucket (~> 0.0.2)
omniauth-cas3 (~> 1.1.2) omniauth-cas3 (~> 1.1.2)
......
...@@ -68,7 +68,7 @@ GitLab is a Ruby on Rails application that runs on the following software: ...@@ -68,7 +68,7 @@ GitLab is a Ruby on Rails application that runs on the following software:
- Ubuntu/Debian/CentOS/RHEL - Ubuntu/Debian/CentOS/RHEL
- Ruby (MRI) 2.1 - Ruby (MRI) 2.1
- Git 1.7.10+ - Git 2.7.4+
- Redis 2.8+ - Redis 2.8+
- MySQL or PostgreSQL - MySQL or PostgreSQL
......
...@@ -14,7 +14,6 @@ class Dispatcher ...@@ -14,7 +14,6 @@ class Dispatcher
path = page.split(':') path = page.split(':')
shortcut_handler = null shortcut_handler = null
switch page switch page
when 'projects:issues:index' when 'projects:issues:index'
Issues.init() Issues.init()
...@@ -25,6 +24,8 @@ class Dispatcher ...@@ -25,6 +24,8 @@ class Dispatcher
new ZenMode() new ZenMode()
when 'projects:milestones:show', 'groups:milestones:show', 'dashboard:milestones:show' when 'projects:milestones:show', 'groups:milestones:show', 'dashboard:milestones:show'
new Milestone() new Milestone()
when 'dashboard:todos:index'
new Todos()
when 'projects:milestones:new', 'projects:milestones:edit' when 'projects:milestones:new', 'projects:milestones:edit'
new ZenMode() new ZenMode()
new DropzoneInput($('.milestone-form')) new DropzoneInput($('.milestone-form'))
......
...@@ -246,11 +246,15 @@ class GitLabDropdown ...@@ -246,11 +246,15 @@ class GitLabDropdown
if oldValue if oldValue
value = "#{oldValue},#{value}" value = "#{oldValue},#{value}"
else else
@dropdown.find(ACTIVE_CLASS).removeClass ACTIVE_CLASS @dropdown.find(".#{ACTIVE_CLASS}").removeClass ACTIVE_CLASS
# Toggle active class for the tick mark # Toggle active class for the tick mark
el.toggleClass "is-active" el.toggleClass "is-active"
# Toggle the dropdown label
if @options.toggleLabel
$(@el).find(".dropdown-toggle-text").text @options.toggleLabel(selectedObject)
if value? if value?
if !field.length if !field.length
# Create hidden input for form # Create hidden input for form
......
class @IssuableForm class @IssuableForm
wipRegex: /^\s*(\[WIP\]\s*|WIP:\s*|WIP\s+)+\s*/i
constructor: (@form) -> constructor: (@form) ->
GitLab.GfmAutoComplete.setup() GitLab.GfmAutoComplete.setup()
new UsersSelect() new UsersSelect()
...@@ -14,6 +15,8 @@ class @IssuableForm ...@@ -14,6 +15,8 @@ class @IssuableForm
@form.on "submit", @resetAutosave @form.on "submit", @resetAutosave
@form.on "click", ".btn-cancel", @resetAutosave @form.on "click", ".btn-cancel", @resetAutosave
@initWip()
initAutosave: -> initAutosave: ->
new Autosave @titleField, [ new Autosave @titleField, [
document.location.pathname, document.location.pathname,
...@@ -30,3 +33,41 @@ class @IssuableForm ...@@ -30,3 +33,41 @@ class @IssuableForm
resetAutosave: => resetAutosave: =>
@titleField.data("autosave").reset() @titleField.data("autosave").reset()
@descriptionField.data("autosave").reset() @descriptionField.data("autosave").reset()
initWip: ->
@$wipExplanation = @form.find(".js-wip-explanation")
@$noWipExplanation = @form.find(".js-no-wip-explanation")
return unless @$wipExplanation.length and @$noWipExplanation.length
@form.on "click", ".js-toggle-wip", @toggleWip
@titleField.on "keyup blur", @renderWipExplanation
@renderWipExplanation()
workInProgress: ->
@wipRegex.test @titleField.val()
renderWipExplanation: =>
if @workInProgress()
@$wipExplanation.show()
@$noWipExplanation.hide()
else
@$wipExplanation.hide()
@$noWipExplanation.show()
toggleWip: (event) =>
event.preventDefault()
if @workInProgress()
@removeWip()
else
@addWip()
@renderWipExplanation()
removeWip: ->
@titleField.val @titleField.val().replace(@wipRegex, "")
addWip: ->
@titleField.val "WIP: #{@titleField.val()}"
...@@ -7,6 +7,7 @@ class @Issue ...@@ -7,6 +7,7 @@ class @Issue
# Prevent duplicate event bindings # Prevent duplicate event bindings
@disableTaskList() @disableTaskList()
@fixAffixScroll() @fixAffixScroll()
@initParticipants()
if $('a.btn-close').length if $('a.btn-close').length
@initTaskList() @initTaskList()
@initIssueBtnEventListeners() @initIssueBtnEventListeners()
...@@ -84,3 +85,27 @@ class @Issue ...@@ -84,3 +85,27 @@ class @Issue
type: 'PATCH' type: 'PATCH'
url: $('form.js-issuable-update').attr('action') url: $('form.js-issuable-update').attr('action')
data: patchData data: patchData
initParticipants: ->
_this = @
$(document).on "click", ".js-participants-more", @toggleHiddenParticipants
$(".js-participants-author").each (i) ->
if i >= _this.PARTICIPANTS_ROW_COUNT
$(@)
.addClass "js-participants-hidden"
.hide()
toggleHiddenParticipants: (e) ->
e.preventDefault()
currentText = $(this).text().trim()
lessText = $(this).data("less-text")
originalText = $(this).data("original-text")
if currentText is originalText
$(this).text(lessText)
else
$(this).text(originalText)
$(".js-participants-hidden").toggle()
...@@ -41,24 +41,28 @@ ...@@ -41,24 +41,28 @@
@timer = null @timer = null
$("#issue_search").keyup -> $("#issue_search").keyup ->
clearTimeout(@timer) clearTimeout(@timer)
@timer = setTimeout(Issues.filterResults, 500) @timer = setTimeout( ->
Issues.filterResults $("#issue_search_form")
, 500)
filterResults: => filterResults: (form) =>
form = $("#issue_search_form") $('.issues-holder, .merge-requests-holder').css("opacity", '0.5')
search = $("#issue_search").val() formAction = form.attr('action')
$('.issues-holder').css("opacity", '0.5') formData = form.serialize()
issues_url = form.attr('action') + '?' + form.serialize() issuesUrl = formAction
issuesUrl += ("#{if formAction.indexOf("?") < 0 then '?' else '&'}")
issuesUrl += formData
$.ajax $.ajax
type: "GET" type: "GET"
url: form.attr('action') url: formAction
data: form.serialize() data: formData
complete: -> complete: ->
$('.issues-holder').css("opacity", '1.0') $('.issues-holder, .merge-requests-holder').css("opacity", '1.0')
success: (data) -> success: (data) ->
$('.issues-holder').html(data.html) $('.issues-holder, .merge-requests-holder').html(data.html)
# Change url so if user reload a page - search results are saved # Change url so if user reload a page - search results are saved
history.replaceState {page: issues_url}, document.title, issues_url history.replaceState {page: issuesUrl}, document.title, issuesUrl
Issues.reload() Issues.reload()
dataType: "json" dataType: "json"
......
class @LabelsSelect class @LabelsSelect
constructor: -> constructor: ->
$('.js-label-select').each (i, dropdown) -> $('.js-label-select').each (i, dropdown) ->
projectId = $(dropdown).data('project-id') $dropdown = $(dropdown)
labelUrl = $(dropdown).data("labels") projectId = $dropdown.data('project-id')
selectedLabel = $(dropdown).data('selected') labelUrl = $dropdown.data('labels')
selectedLabel = $dropdown.data('selected')
if selectedLabel if selectedLabel
selectedLabel = selectedLabel.split(",") selectedLabel = selectedLabel.split(',')
newLabelField = $('#new_label_name') newLabelField = $('#new_label_name')
newColorField = $('#new_label_color') newColorField = $('#new_label_color')
showNo = $(dropdown).data('show-no') showNo = $dropdown.data('show-no')
showAny = $(dropdown).data('show-any') showAny = $dropdown.data('show-any')
defaultLabel = $dropdown.data('default-label')
if newLabelField.length if newLabelField.length
$('.suggest-colors-dropdown a').on "click", (e) -> $('.suggest-colors-dropdown a').on 'click', (e) ->
e.preventDefault() e.preventDefault()
e.stopPropagation() e.stopPropagation()
newColorField.val $(this).data("color") newColorField.val $(this).data('color')
$('.js-dropdown-label-color-preview') $('.js-dropdown-label-color-preview')
.css 'background-color', $(this).data("color") .css 'background-color', $(this).data('color')
.addClass 'is-active' .addClass 'is-active'
$('.js-new-label-btn').on "click", (e) -> $('.js-new-label-btn').on 'click', (e) ->
e.preventDefault() e.preventDefault()
e.stopPropagation() e.stopPropagation()
if newLabelField.val() isnt "" && newColorField.val() isnt "" if newLabelField.val() isnt '' and newColorField.val() isnt ''
$('.js-new-label-btn').disable() $('.js-new-label-btn').disable()
# Create new label with API # Create new label with API
...@@ -33,46 +35,38 @@ class @LabelsSelect ...@@ -33,46 +35,38 @@ class @LabelsSelect
color: newColorField.val() color: newColorField.val()
}, (label) -> }, (label) ->
$('.js-new-label-btn').enable() $('.js-new-label-btn').enable()
$('.dropdown-menu-back', $(dropdown).parent()).trigger "click" $('.dropdown-menu-back', $dropdown.parent()).trigger 'click'
$(dropdown).glDropdown( $dropdown.glDropdown(
data: (term, callback) -> data: (term, callback) ->
# We have to fetch the JS version of the labels list because there is no
# public facing JSON url for labels
$.ajax( $.ajax(
url: labelUrl url: labelUrl
).done (data) -> ).done (data) ->
html = $(data)
data = []
html.find('.label-row a').each ->
data.push(
title: $(@).text().trim()
)
if showNo if showNo
data.unshift( data.unshift(
id: "0" id: 0
title: 'No label' title: 'No Label'
) )
if showAny if showAny
data.unshift( data.unshift(
title: 'Any label' isAny: true
title: 'Any Label'
) )
if data.length > 2 if data.length > 2
data.splice 2, 0, "divider" data.splice 2, 0, 'divider'
callback data callback data
renderRow: (label) -> renderRow: (label) ->
if $.isArray(selectedLabel) if $.isArray(selectedLabel)
selected = "" selected = ''
$.each selectedLabel, (i, selectedLbl) -> $.each selectedLabel, (i, selectedLbl) ->
selectedLbl = selectedLbl.trim() selectedLbl = selectedLbl.trim()
if selected is "" && label.title is selectedLbl if selected is '' and label.title is selectedLbl
selected = "is-active" selected = 'is-active'
else else
selected = if label.title is selectedLabel then "is-active" else "" selected = if label.title is selectedLabel then 'is-active' else ''
"<li> "<li>
<a href='#' class='#{selected}'> <a href='#' class='#{selected}'>
...@@ -83,10 +77,24 @@ class @LabelsSelect ...@@ -83,10 +77,24 @@ class @LabelsSelect
search: search:
fields: ['title'] fields: ['title']
selectable: true selectable: true
fieldName: $(dropdown).data('field-name') toggleLabel: (selected) ->
if selected and selected.title isnt 'Any Label'
selected.title
else
defaultLabel
fieldName: $dropdown.data('field-name')
id: (label) -> id: (label) ->
if label.isAny?
''
else
label.title label.title
clicked: -> clicked: ->
if $(dropdown).hasClass "js-filter-submit" page = $('body').data 'page'
$(dropdown).parents('form').submit() isIssueIndex = page is 'projects:issues:index'
isMRIndex = page is page is 'projects:merge_requests:index'
if $dropdown.hasClass('js-filter-submit') and (isIssueIndex or isMRIndex)
Issues.filterResults $dropdown.closest('form')
else if $dropdown.hasClass 'js-filter-submit'
$dropdown.closest('form').submit()
) )
class @MilestoneSelect class @MilestoneSelect
constructor: -> constructor: ->
$('.js-milestone-select').each (i, dropdown) -> $('.js-milestone-select').each (i, dropdown) ->
projectId = $(dropdown).data('project-id') $dropdown = $(dropdown)
milestonesUrl = $(dropdown).data('milestones') projectId = $dropdown.data('project-id')
selectedMilestone = $(dropdown).data('selected') milestonesUrl = $dropdown.data('milestones')
showNo = $(dropdown).data('show-no') selectedMilestone = $dropdown.data('selected')
showAny = $(dropdown).data('show-any') showNo = $dropdown.data('show-no')
useId = $(dropdown).data('use-id') showAny = $dropdown.data('show-any')
useId = $dropdown.data('use-id')
defaultLabel = $dropdown.data('default-label')
$(dropdown).glDropdown( $dropdown.glDropdown(
data: (term, callback) -> data: (term, callback) ->
$.ajax( $.ajax(
url: milestonesUrl url: milestonesUrl
).done (data) -> ).done (data) ->
html = $(data)
data = []
html.find('.milestone strong a').each ->
link = $(@).attr("href").split("/")
data.push(
id: link[link.length - 1]
title: $(@).text().trim()
)
if showNo if showNo
data.unshift( data.unshift(
id: "0" id: '0'
title: 'No Milestone' title: 'No Milestone'
) )
if showAny if showAny
data.unshift( data.unshift(
isAny: true
title: 'Any Milestone' title: 'Any Milestone'
) )
if data.length > 2 if data.length > 2
data.splice 2, 0, "divider" data.splice 2, 0, 'divider'
callback(data) callback(data)
filterable: true filterable: true
search: search:
fields: ['title'] fields: ['title']
selectable: true selectable: true
fieldName: $(dropdown).data('field-name') toggleLabel: (selected) ->
if selected && 'id' of selected
selected.title
else
defaultLabel
fieldName: $dropdown.data('field-name')
text: (milestone) -> text: (milestone) ->
milestone.title milestone.title
id: (milestone) -> id: (milestone) ->
if !useId if !useId
if milestone.title isnt "Any milestone" if !milestone.isAny?
milestone.title milestone.title
else else
"" ''
else else
milestone.id milestone.id
isSelected: (milestone) -> isSelected: (milestone) ->
milestone.title is selectedMilestone milestone.title is selectedMilestone
clicked: -> clicked: ->
if $(dropdown).hasClass "js-filter-submit" page = $('body').data 'page'
$(dropdown).parents('form').submit() isIssueIndex = page is 'projects:issues:index'
isMRIndex = page is page is 'projects:merge_requests:index'
if $dropdown.hasClass('js-filter-submit') and (isIssueIndex or isMRIndex)
Issues.filterResults $dropdown.closest('form')
else if $dropdown.hasClass 'js-filter-submit'
$dropdown.closest('form').submit()
) )
...@@ -343,6 +343,7 @@ class @Notes ...@@ -343,6 +343,7 @@ class @Notes
updateNote: (_xhr, note, _status) => updateNote: (_xhr, note, _status) =>
# Convert returned HTML to a jQuery object so we can modify it further # Convert returned HTML to a jQuery object so we can modify it further
$html = $(note.html) $html = $(note.html)
$('.js-timeago', $html).timeago()
$html.syntaxHighlight() $html.syntaxHighlight()
$html.find('.js-task-list-container').taskList('enable') $html.find('.js-task-list-container').taskList('enable')
...@@ -626,10 +627,10 @@ class @Notes ...@@ -626,10 +627,10 @@ class @Notes
if closebtn.text() isnt closetext if closebtn.text() isnt closetext
closebtn.text(closetext) closebtn.text(closetext)
if reopenbtn.is(':not(.btn-comment-and-reopen)') if reopenbtn.is('.btn-comment-and-reopen')
reopenbtn.removeClass('btn-comment-and-reopen') reopenbtn.removeClass('btn-comment-and-reopen')
if closebtn.is(':not(.btn-comment-and-close)') if closebtn.is('.btn-comment-and-close')
closebtn.removeClass('btn-comment-and-close') closebtn.removeClass('btn-comment-and-close')
if discardbtn.is(':visible') if discardbtn.is(':visible')
......
...@@ -3,3 +3,16 @@ class @ProjectNew ...@@ -3,3 +3,16 @@ class @ProjectNew
$('.project-edit-container').on 'ajax:before', => $('.project-edit-container').on 'ajax:before', =>
$('.project-edit-container').hide() $('.project-edit-container').hide()
$('.save-project-loader').show() $('.save-project-loader').show()
@toggleSettings()
@toggleSettingsOnclick()
toggleSettings: ->
checked = $("#project_builds_enabled").prop("checked")
if checked
$('.builds-feature').show()
else
$('.builds-feature').hide()
toggleSettingsOnclick: ->
$("#project_builds_enabled").on 'click', @toggleSettings
class @Todos
constructor: (@name) ->
@clearListeners()
@initBtnListeners()
clearListeners: ->
$('.done-todo').off('click')
$('.js-todos-mark-all').off('click')
initBtnListeners: ->
$('.done-todo').on('click', @doneClicked)
$('.js-todos-mark-all').on('click', @allDoneClicked)
doneClicked: (e) =>
e.preventDefault()
e.stopImmediatePropagation()
$this = $(e.currentTarget)
$this.disable()
$.ajax
type: 'POST'
url: $this.attr('href')
dataType: 'json'
data: '_method': 'delete'
success: (data) =>
@clearDone $this.closest('li')
@updateBadges data
allDoneClicked: (e) =>
e.preventDefault()
e.stopImmediatePropagation()
$this = $(e.currentTarget)
$this.disable()
$.ajax
type: 'POST'
url: $this.attr('href')
dataType: 'json'
data: '_method': 'delete'
success: (data) =>
$this.remove()
$('.js-todos-list').remove()
@updateBadges data
clearDone: ($row) ->
$ul = $row.closest('ul')
$row.remove()
if not $ul.find('li').length
$ul.parents('.panel').remove()
updateBadges: (data) ->
$('.todos-pending .badge, .todos-pending-count').text data.count
$('.todos-done .badge').text data.done_count
...@@ -4,14 +4,16 @@ class @UsersSelect ...@@ -4,14 +4,16 @@ class @UsersSelect
@userPath = "/autocomplete/users/:id.json" @userPath = "/autocomplete/users/:id.json"
$('.js-user-search').each (i, dropdown) => $('.js-user-search').each (i, dropdown) =>
@projectId = $(dropdown).data('project-id') $dropdown = $(dropdown)
@showCurrentUser = $(dropdown).data('current-user') @projectId = $dropdown.data('project-id')
showNullUser = $(dropdown).data('null-user') @showCurrentUser = $dropdown.data('current-user')
showAnyUser = $(dropdown).data('any-user') showNullUser = $dropdown.data('null-user')
firstUser = $(dropdown).data('first-user') showAnyUser = $dropdown.data('any-user')
selectedId = $(dropdown).data('selected') firstUser = $dropdown.data('first-user')
selectedId = $dropdown.data('selected')
$(dropdown).glDropdown( defaultLabel = $dropdown.data('default-label')
$dropdown.glDropdown(
data: (term, callback) => data: (term, callback) =>
@users term, (users) => @users term, (users) =>
if term.length is 0 if term.length is 0
...@@ -52,10 +54,21 @@ class @UsersSelect ...@@ -52,10 +54,21 @@ class @UsersSelect
search: search:
fields: ['name', 'username'] fields: ['name', 'username']
selectable: true selectable: true
fieldName: $(dropdown).data('field-name') fieldName: $dropdown.data('field-name')
toggleLabel: (selected) ->
if selected && 'id' of selected
selected.name
else
defaultLabel
clicked: -> clicked: ->
if $(dropdown).hasClass "js-filter-submit" page = $('body').data 'page'
$(dropdown).parents('form').submit() isIssueIndex = page is 'projects:issues:index'
isMRIndex = page is page is 'projects:merge_requests:index'
if $dropdown.hasClass('js-filter-submit') and (isIssueIndex or isMRIndex)
Issues.filterResults $dropdown.closest('form')
else if $dropdown.hasClass 'js-filter-submit'
$dropdown.closest('form').submit()
renderRow: (user) -> renderRow: (user) ->
username = if user.username then "@#{user.username}" else "" username = if user.username then "@#{user.username}" else ""
avatar = if user.avatar_url then user.avatar_url else false avatar = if user.avatar_url then user.avatar_url else false
......
...@@ -23,15 +23,11 @@ ...@@ -23,15 +23,11 @@
margin-bottom: -$gl-padding; margin-bottom: -$gl-padding;
background-color: $background-color; background-color: $background-color;
padding: $gl-padding; padding: $gl-padding;
margin-bottom: 0px; margin-bottom: 0;
border-top: 1px solid $border-color; border-top: 1px solid $border-color;
border-bottom: 1px solid $border-color; border-bottom: 1px solid $border-color;
color: $gl-gray; color: $gl-gray;
a {
color: $md-link-color;
}
&.oneline-block { &.oneline-block {
line-height: 42px; line-height: 42px;
} }
......
...@@ -37,23 +37,23 @@ ...@@ -37,23 +37,23 @@
} }
@mixin btn-green { @mixin btn-green {
@include btn-color($green-light, $border-green-light, $green-normal, $border-green-normal, $green-dark, $border-green-dark, #FFFFFF); @include btn-color($green-light, $border-green-light, $green-normal, $border-green-normal, $green-dark, $border-green-dark, #fff);
} }
@mixin btn-blue { @mixin btn-blue {
@include btn-color($blue-light, $border-blue-light, $blue-normal, $border-blue-normal, $blue-dark, $border-blue-dark, #FFFFFF); @include btn-color($blue-light, $border-blue-light, $blue-normal, $border-blue-normal, $blue-dark, $border-blue-dark, #fff);
} }
@mixin btn-blue-medium { @mixin btn-blue-medium {
@include btn-color($blue-medium-light, $border-blue-light, $blue-medium, $border-blue-normal, $blue-medium-dark, $border-blue-dark, #FFFFFF); @include btn-color($blue-medium-light, $border-blue-light, $blue-medium, $border-blue-normal, $blue-medium-dark, $border-blue-dark, #fff);
} }
@mixin btn-orange { @mixin btn-orange {
@include btn-color($orange-light, $border-orange-light, $orange-normal, $border-orange-normal, $orange-dark, $border-orange-dark, #FFFFFF); @include btn-color($orange-light, $border-orange-light, $orange-normal, $border-orange-normal, $orange-dark, $border-orange-dark, #fff);
} }
@mixin btn-red { @mixin btn-red {
@include btn-color($red-light, $border-red-light, $red-normal, $border-red-normal, $red-dark, $border-red-dark, #FFFFFF); @include btn-color($red-light, $border-red-light, $red-normal, $border-red-normal, $red-dark, $border-red-dark, #fff);
} }
@mixin btn-gray { @mixin btn-gray {
...@@ -127,7 +127,7 @@ ...@@ -127,7 +127,7 @@
margin-right: 7px; margin-right: 7px;
float: left; float: left;
&:last-child { &:last-child {
margin-right: 0px; margin-right: 0;
} }
&.btn-xs { &.btn-xs {
margin-right: 3px; margin-right: 3px;
...@@ -139,7 +139,6 @@ ...@@ -139,7 +139,6 @@
.caret { .caret {
margin-left: 5px; margin-left: 5px;
color: $gray-darkest;
} }
} }
...@@ -170,7 +169,7 @@ ...@@ -170,7 +169,7 @@
margin-right: 7px; margin-right: 7px;
float: left; float: left;
&:last-child { &:last-child {
margin-right: 0px; margin-right: 0;
} }
} }
} }
...@@ -209,3 +208,13 @@ ...@@ -209,3 +208,13 @@
background-color: #e4e7ed !important; background-color: #e4e7ed !important;
} }
} }
.btn-loading {
&:not(.disabled) .fa {
display: none;
}
.fa {
margin-right: 5px;
}
}
...@@ -33,19 +33,19 @@ ...@@ -33,19 +33,19 @@
} }
.q2 { .q2 {
fill: #ACD5F2 !important; fill: #acd5f2 !important;
} }
.q3 { .q3 {
fill: #7FA8D1 !important; fill: #7fa8d1 !important;
} }
.q4 { .q4 {
fill: #49729B !important; fill: #49729b !important;
} }
.q5 { .q5 {
fill: #254E77 !important; fill: #254e77 !important;
} }
.domain-background { .domain-background {
......
...@@ -39,6 +39,6 @@ ...@@ -39,6 +39,6 @@
} }
.bs-callout-success { .bs-callout-success {
background-color: #dff0d8; background-color: #dff0d8;
border-color: #5cA64d; border-color: #5ca64d;
color: #3c763d; color: #3c763d;
} }
/** COLORS **/ /** COLORS **/
.cgray { color: $gl-gray; } .cgray { color: $gl-gray; }
.clgray { color: #BBB } .clgray { color: #bbb }
.cred { color: $gl-text-red; } .cred { color: $gl-text-red; }
.cgreen { color: $gl-text-green; } .cgreen { color: $gl-text-green; }
.cdark { color: #444 } .cdark { color: #444 }
...@@ -8,20 +8,20 @@ ...@@ -8,20 +8,20 @@
/** COMMON CLASSES **/ /** COMMON CLASSES **/
.prepend-top-0 { margin-top: 0; } .prepend-top-0 { margin-top: 0; }
.prepend-top-5 { margin-top: 5px; } .prepend-top-5 { margin-top: 5px; }
.prepend-top-10 { margin-top:10px } .prepend-top-10 { margin-top: 10px }
.prepend-top-default { margin-top: $gl-padding !important; } .prepend-top-default { margin-top: $gl-padding !important; }
.prepend-top-20 { margin-top:20px } .prepend-top-20 { margin-top: 20px }
.prepend-left-10 { margin-left:10px } .prepend-left-10 { margin-left: 10px }
.prepend-left-default { margin-left: $gl-padding; } .prepend-left-default { margin-left: $gl-padding; }
.prepend-left-20 { margin-left:20px } .prepend-left-20 { margin-left: 20px }
.append-right-5 { margin-right: 5px } .append-right-5 { margin-right: 5px }
.append-right-10 { margin-right:10px } .append-right-10 { margin-right: 10px }
.append-right-default { margin-right: $gl-padding; } .append-right-default { margin-right: $gl-padding; }
.append-right-20 { margin-right:20px } .append-right-20 { margin-right: 20px }
.append-bottom-0 { margin-bottom:0 } .append-bottom-0 { margin-bottom: 0 }
.append-bottom-10 { margin-bottom:10px } .append-bottom-10 { margin-bottom: 10px }
.append-bottom-15 { margin-bottom:15px } .append-bottom-15 { margin-bottom: 15px }
.append-bottom-20 { margin-bottom:20px } .append-bottom-20 { margin-bottom: 20px }
.append-bottom-default { margin-bottom: $gl-padding; } .append-bottom-default { margin-bottom: $gl-padding; }
.inline { display: inline-block } .inline { display: inline-block }
.center { text-align: center } .center { text-align: center }
...@@ -51,7 +51,7 @@ pre { ...@@ -51,7 +51,7 @@ pre {
} }
&.well-pre { &.well-pre {
border: 1px solid #EEE; border: 1px solid #eee;
background: #f9f9f9; background: #f9f9f9;
border-radius: 0; border-radius: 0;
color: #555; color: #555;
...@@ -103,7 +103,7 @@ span.update-author { ...@@ -103,7 +103,7 @@ span.update-author {
} }
.user-mention { .user-mention {
color: #2FA0BB; color: #2fa0bb;
font-weight: bold; font-weight: bold;
} }
...@@ -134,10 +134,10 @@ p.time { ...@@ -134,10 +134,10 @@ p.time {
// Fix issue with notes & lists creating a bunch of bottom borders. // Fix issue with notes & lists creating a bunch of bottom borders.
li.note { li.note {
img { max-width:100% } img { max-width: 100% }
.note-title { .note-title {
li { li {
border-bottom:none !important; border-bottom: none !important;
} }
} }
} }
...@@ -187,9 +187,9 @@ li.note { ...@@ -187,9 +187,9 @@ li.note {
.error-message { .error-message {
padding: 10px; padding: 10px;
background: #C67; background: #c67;
margin: 0; margin: 0;
color: #FFF; color: #fff;
a { a {
color: #fff; color: #fff;
...@@ -200,7 +200,7 @@ li.note { ...@@ -200,7 +200,7 @@ li.note {
.browser-alert { .browser-alert {
padding: 10px; padding: 10px;
text-align: center; text-align: center;
background: #C67; background: #c67;
color: #fff; color: #fff;
font-weight: bold; font-weight: bold;
a { a {
...@@ -271,7 +271,7 @@ img.emoji { ...@@ -271,7 +271,7 @@ img.emoji {
table { table {
td.permission-x { td.permission-x {
background: #D9EDF7 !important; background: #d9edf7 !important;
text-align: center; text-align: center;
} }
} }
...@@ -280,7 +280,7 @@ table { ...@@ -280,7 +280,7 @@ table {
float: left; float: left;
text-align: center; text-align: center;
font-size: 32px; font-size: 32px;
color: #AAA; color: #aaa;
width: 60px; width: 60px;
} }
...@@ -347,7 +347,7 @@ table { ...@@ -347,7 +347,7 @@ table {
.profiler-button, .profiler-button,
.profiler-controls { .profiler-controls {
border-color: #EEE !important; border-color: #eee !important;
} }
} }
......
...@@ -4,11 +4,17 @@ ...@@ -4,11 +4,17 @@
height: 0; height: 0;
margin-left: 2px; margin-left: 2px;
vertical-align: middle; vertical-align: middle;
border-top: $caret-width-base dashed $dropdown-caret-color; border-top: $caret-width-base dashed;
border-right: $caret-width-base solid transparent; border-right: $caret-width-base solid transparent;
border-left: $caret-width-base solid transparent; border-left: $caret-width-base solid transparent;
} }
.btn-group {
.caret {
margin-left: 0;
}
}
.dropdown { .dropdown {
position: relative; position: relative;
} }
...@@ -161,9 +167,8 @@ ...@@ -161,9 +167,8 @@
.dropdown-menu-user-full-name { .dropdown-menu-user-full-name {
display: block; display: block;
margin-bottom: 2px;
font-weight: 600; font-weight: 600;
line-height: 1; line-height: 16px;
text-overflow: ellipsis; text-overflow: ellipsis;
overflow: hidden; overflow: hidden;
white-space: nowrap; white-space: nowrap;
...@@ -171,7 +176,7 @@ ...@@ -171,7 +176,7 @@
.dropdown-menu-user-username { .dropdown-menu-user-username {
display: block; display: block;
line-height: 1; line-height: 16px;
text-overflow: ellipsis; text-overflow: ellipsis;
overflow: hidden; overflow: hidden;
white-space: nowrap; white-space: nowrap;
...@@ -261,7 +266,7 @@ ...@@ -261,7 +266,7 @@
position: absolute; position: absolute;
top: 10px; top: 10px;
right: 10px; right: 10px;
color: #C7C7C7; color: #c7c7c7;
font-size: 12px; font-size: 12px;
pointer-events: none; pointer-events: none;
} }
......
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
right: 15px; right: 15px;
.btn { .btn {
padding: 0px 10px; padding: 0 10px;
font-size: 13px; font-size: 13px;
line-height: 28px; line-height: 28px;
} }
...@@ -84,7 +84,7 @@ ...@@ -84,7 +84,7 @@
&.blob-no-preview { &.blob-no-preview {
background: #eee; background: #eee;
text-shadow: 0 1px 2px #FFF; text-shadow: 0 1px 2px #fff;
padding: 100px 0; padding: 100px 0;
} }
...@@ -124,7 +124,7 @@ ...@@ -124,7 +124,7 @@
} }
td.line-numbers { td.line-numbers {
float: none; float: none;
border-left: 1px solid #DDD; border-left: 1px solid #ddd;
} }
td.lines { td.lines {
padding: 0; padding: 0;
......
...@@ -3,22 +3,11 @@ ...@@ -3,22 +3,11 @@
vertical-align: top; vertical-align: top;
} }
@media (min-width: 800px) { @media (min-width: $screen-sm-min) {
.issues-filters, .issues-filters,
.issues_bulk_update { .issues_bulk_update {
select, .select2-container { .dropdown-menu-toggle {
width: 120px !important; width: 132px;
display: inline-block;
}
}
}
@media (min-width: 1200px) {
.issues-filters,
.issues_bulk_update {
select, .select2-container {
width: 150px !important;
display: inline-block;
} }
} }
} }
...@@ -41,8 +41,8 @@ input[type='search'].search-input { ...@@ -41,8 +41,8 @@ input[type='search'].search-input {
} }
input[type='text'].danger { input[type='text'].danger {
background: #F2DEDE!important; background: #f2dede!important;
border-color: #D66; border-color: #d66;
text-shadow: 0 1px 1px #fff text-shadow: 0 1px 1px #fff
} }
......
...@@ -23,13 +23,13 @@ ...@@ -23,13 +23,13 @@
&:hover { &:hover {
background-color: $color-darker; background-color: $color-darker;
a { a {
color: #FFF; color: #fff;
} }
} }
} }
.collapse-nav a { .collapse-nav a {
color: #FFF; color: #fff;
background: $color; background: $color;
} }
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
&:hover { &:hover {
background-color: $color-dark; background-color: $color-dark;
color: #FFF; color: #fff;
text-decoration: none; text-decoration: none;
} }
} }
...@@ -71,7 +71,7 @@ ...@@ -71,7 +71,7 @@
} }
&.active a { &.active a {
color: #FFF; color: #fff;
background: $color-dark; background: $color-dark;
&.no-highlight { &.no-highlight {
...@@ -79,42 +79,42 @@ ...@@ -79,42 +79,42 @@
} }
i { i {
color: #FFF color: #fff
} }
} }
} }
} }
} }
$theme-blue: #2980B9; $theme-blue: #2980b9;
$theme-charcoal: #333c47; $theme-charcoal: #333c47;
$theme-graphite: #888888; $theme-graphite: #888;
$theme-gray: #373737; $theme-gray: #373737;
$theme-green: #019875; $theme-green: #019875;
$theme-violet: #554488; $theme-violet: #548;
body { body {
&.ui_blue { &.ui_blue {
@include gitlab-theme(#BECDE9, $theme-blue, #1970A9, #096099); @include gitlab-theme(#becde9, $theme-blue, #1970a9, #096099);
} }
&.ui_charcoal { &.ui_charcoal {
@include gitlab-theme(#c5d0de, $theme-charcoal, #2b333d, #24272D); @include gitlab-theme(#c5d0de, $theme-charcoal, #2b333d, #24272d);
} }
&.ui_graphite { &.ui_graphite {
@include gitlab-theme(#CCCCCC, $theme-graphite, #777777, #666666); @include gitlab-theme(#ccc, $theme-graphite, #777, #666);
} }
&.ui_gray { &.ui_gray {
@include gitlab-theme(#979797, $theme-gray, #272727, #222222); @include gitlab-theme(#979797, $theme-gray, #272727, #222);
} }
&.ui_green { &.ui_green {
@include gitlab-theme(#AADDCC, $theme-green, #018865, #017855); @include gitlab-theme(#adc, $theme-green, #018865, #017855);
} }
&.ui_violet { &.ui_violet {
@include gitlab-theme(#9988CC, $theme-violet, #443366, #332255); @include gitlab-theme(#98c, $theme-violet, #436, #325);
} }
} }
\ No newline at end of file
...@@ -7,8 +7,8 @@ header { ...@@ -7,8 +7,8 @@ header {
&.navbar-empty { &.navbar-empty {
height: 58px; height: 58px;
background: #FFF; background: #fff;
border-bottom: 1px solid #EEE; border-bottom: 1px solid #eee;
.center-logo { .center-logo {
margin: 11px 0; margin: 11px 0;
...@@ -28,7 +28,7 @@ header { ...@@ -28,7 +28,7 @@ header {
min-height: $header-height; min-height: $header-height;
background-color: #fff; background-color: #fff;
border: none; border: none;
border-bottom: 1px solid #EEE; border-bottom: 1px solid #eee;
.container-fluid { .container-fluid {
width: 100% !important; width: 100% !important;
...@@ -47,7 +47,7 @@ header { ...@@ -47,7 +47,7 @@ header {
text-align: center; text-align: center;
&:hover, &:focus, &:active { &:hover, &:focus, &:active {
background-color: #FFF; background-color: #fff;
} }
} }
...@@ -59,7 +59,7 @@ header { ...@@ -59,7 +59,7 @@ header {
right: 2px; right: 2px;
&:hover { &:hover {
background-color: #EEE; background-color: #eee;
} }
&.active { &.active {
color: #7f8fa4; color: #7f8fa4;
...@@ -162,7 +162,7 @@ header { ...@@ -162,7 +162,7 @@ header {
font-size: 18px; font-size: 18px;
.navbar-nav { .navbar-nav {
margin: 0px; margin: 0;
float: none !important; float: none !important;
.visible-xs, .visable-sm { .visible-xs, .visable-sm {
......
.file-content.code { .file-content.code {
border: none; border: none;
box-shadow: none; box-shadow: none;
margin: 0px; margin: 0;
padding: 0px; padding: 0;
table-layout: fixed; table-layout: fixed;
pre { pre {
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
display: block; display: block;
float: left; float: left;
margin-right: 10px; margin-right: 10px;
color: #FFF; color: #fff;
font-size: $gl-font-size; font-size: $gl-font-size;
line-height: 25px; line-height: 25px;
......
...@@ -3,13 +3,13 @@ ...@@ -3,13 +3,13 @@
font-size: $font-size-base; font-size: $font-size-base;
&.ui-datepicker-inline { &.ui-datepicker-inline {
border: 1px solid #DDD; border: 1px solid #ddd;
padding: 10px; padding: 10px;
width: 270px; width: 270px;
.ui-datepicker-header { .ui-datepicker-header {
background: #FFF; background: #fff;
border-color: #DDD; border-color: #ddd;
} }
.ui-datepicker-calendar td a { .ui-datepicker-calendar td a {
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
} }
&.ui-autocomplete { &.ui-autocomplete {
border-color: #DDD; border-color: #ddd;
padding: 0; padding: 0;
margin-top: 2px; margin-top: 2px;
z-index: 1001; z-index: 1001;
...@@ -30,20 +30,20 @@ ...@@ -30,20 +30,20 @@
} }
.ui-state-default { .ui-state-default {
border: 1px solid #FFF; border: 1px solid #fff;
background: #FFF; background: #fff;
color: #777; color: #777;
} }
.ui-state-highlight { .ui-state-highlight {
border: 1px solid #EEE; border: 1px solid #eee;
background: #EEE; background: #eee;
} }
.ui-state-active { .ui-state-active {
border: 1px solid $gl-primary; border: 1px solid $gl-primary;
background: $gl-primary; background: $gl-primary;
color: #FFF; color: #fff;
} }
.ui-state-hover, .ui-state-hover,
......
...@@ -111,14 +111,17 @@ ul.content-list { ...@@ -111,14 +111,17 @@ ul.content-list {
> li { > li {
border-color: $table-border-color; border-color: $table-border-color;
color: $list-text-color;
font-size: $list-font-size; font-size: $list-font-size;
color: $list-text-color;
.title { .title {
color: $list-title-color;
font-weight: 600; font-weight: 600;
} }
a {
color: $gl-dark-link-color;
}
.description { .description {
p { p {
@include str-truncated; @include str-truncated;
...@@ -141,6 +144,10 @@ ul.content-list { ...@@ -141,6 +144,10 @@ ul.content-list {
} }
} }
.panel > .content-list > li {
padding: $gl-padding-top $gl-padding;
}
ul.controls { ul.controls {
padding-top: 1px; padding-top: 1px;
float: right; float: right;
......
...@@ -71,7 +71,7 @@ ...@@ -71,7 +71,7 @@
} }
.md-preview-holder { .md-preview-holder {
background: #FFF; background: #fff;
border: 1px solid #ddd; border: 1px solid #ddd;
min-height: 169px; min-height: 169px;
padding: 5px; padding: 5px;
...@@ -80,7 +80,7 @@ ...@@ -80,7 +80,7 @@
.markdown-area { .markdown-area {
@include border-radius(0); @include border-radius(0);
background: #FFF; background: #fff;
border: 1px solid #ddd; border: 1px solid #ddd;
min-height: 140px; min-height: 140px;
max-height: 500px; max-height: 500px;
......
...@@ -67,17 +67,17 @@ ...@@ -67,17 +67,17 @@
* Base mixin for lists in GitLab * Base mixin for lists in GitLab
*/ */
@mixin basic-list { @mixin basic-list {
margin: 5px 0px; margin: 5px 0;
padding: 0px; padding: 0;
list-style: none; list-style: none;
> li { > li {
@include clearfix; @include clearfix;
padding: 10px 0; padding: 10px 0;
border-bottom: 1px solid #EEE; border-bottom: 1px solid #eee;
display: block; display: block;
margin: 0px; margin: 0;
&:last-child { &:last-child {
border-bottom: none; border-bottom: none;
......
...@@ -128,12 +128,12 @@ ...@@ -128,12 +128,12 @@
.show-aside { .show-aside {
display: none; display: none;
position: fixed; position: fixed;
right: 0px; right: 0;
top: 30%; top: 30%;
padding: 5px 15px; padding: 5px 15px;
background: #EEE; background: #eee;
font-size: 20px; font-size: 20px;
color: #777; color: #777;
z-index: 100; z-index: 100;
@include box-shadow(0 1px 2px #DDD); @include box-shadow(0 1px 2px #ddd);
} }
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
} }
&.active a { &.active a {
color: #000000; color: #000;
border-bottom: 2px solid #4688f1; border-bottom: 2px solid #4688f1;
} }
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
.top-area { .top-area {
@include clearfix; @include clearfix;
border-bottom: 1px solid #EEE; border-bottom: 1px solid #eee;
.nav-text { .nav-text {
padding-top: 16px; padding-top: 16px;
...@@ -59,7 +59,7 @@ ...@@ -59,7 +59,7 @@
.nav-links { .nav-links {
display: inline-block; display: inline-block;
width: 50%; width: 50%;
margin-bottom: 0px; margin-bottom: 0;
border-bottom: none; border-bottom: none;
/* Small devices (phones, tablets, 768px and lower) */ /* Small devices (phones, tablets, 768px and lower) */
...@@ -74,7 +74,7 @@ ...@@ -74,7 +74,7 @@
float: right; float: right;
text-align: right; text-align: right;
padding: 11px 0; padding: 11px 0;
margin-bottom: 0px; margin-bottom: 0;
> .dropdown { > .dropdown {
margin-right: $gl-padding-top; margin-right: $gl-padding-top;
......
...@@ -151,7 +151,7 @@ ...@@ -151,7 +151,7 @@
padding: 2px 25px 2px 5px; padding: 2px 25px 2px 5px;
background: #fff image-url('select2.png'); background: #fff image-url('select2.png');
background-repeat: no-repeat; background-repeat: no-repeat;
background-position: right 0px bottom 6px; background-position: right 0 bottom 6px;
border: 1px solid $input-border; border: 1px solid $input-border;
@include border-radius($border-radius-default); @include border-radius($border-radius-default);
@include transition(border-color ease-in-out .15s, box-shadow ease-in-out .15s); @include transition(border-color ease-in-out .15s, box-shadow ease-in-out .15s);
...@@ -229,7 +229,7 @@ ...@@ -229,7 +229,7 @@
.namespace-result { .namespace-result {
.namespace-kind { .namespace-kind {
color: #AAA; color: #aaa;
font-weight: normal; font-weight: normal;
} }
.namespace-path { .namespace-path {
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
.gitlab-text-container-link { .gitlab-text-container-link {
z-index: 1; z-index: 1;
position: absolute; position: absolute;
left: 0px; left: 0;
} }
#logo { #logo {
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
width: 100%; width: 100%;
.container-fluid { .container-fluid {
background: #FFF; background: #fff;
padding: 0 $gl-padding; padding: 0 $gl-padding;
&.container-blank { &.container-blank {
...@@ -103,7 +103,7 @@ ...@@ -103,7 +103,7 @@
} }
&:hover { &:hover {
background-color: #EEE; background-color: #eee;
} }
} }
...@@ -143,7 +143,7 @@ ...@@ -143,7 +143,7 @@
overflow: hidden; overflow: hidden;
&.navbar-collapse { &.navbar-collapse {
padding: 0px !important; padding: 0 !important;
} }
li { li {
...@@ -182,7 +182,7 @@ ...@@ -182,7 +182,7 @@
.count { .count {
float: right; float: right;
background: #eee; background: #eee;
padding: 0px 8px; padding: 0 8px;
@include border-radius(6px); @include border-radius(6px);
} }
...@@ -194,8 +194,8 @@ ...@@ -194,8 +194,8 @@
} }
.sidebar-subnav { .sidebar-subnav {
margin-left: 0px; margin-left: 0;
padding-left: 0px; padding-left: 0;
li { li {
list-style: none; list-style: none;
......
...@@ -95,7 +95,7 @@ ...@@ -95,7 +95,7 @@
} }
&.label-inverse { &.label-inverse {
background-color: #333333; background-color: #333;
} }
} }
...@@ -138,7 +138,7 @@ ...@@ -138,7 +138,7 @@
} }
.btn-clipboard { .btn-clipboard {
min-width: 0px; min-width: 0;
} }
} }
......
...@@ -57,7 +57,7 @@ $component-active-bg: $brand-info; ...@@ -57,7 +57,7 @@ $component-active-bg: $brand-info;
$input-color: $text-color; $input-color: $text-color;
$input-border: #e7e9ed; $input-border: #e7e9ed;
$input-border-focus: #7F8FA4; $input-border-focus: #7f8fa4;
$legend-color: $text-color; $legend-color: $text-color;
...@@ -125,8 +125,8 @@ $panel-inner-border: $border-color; ...@@ -125,8 +125,8 @@ $panel-inner-border: $border-color;
// //
//## //##
$well-bg: #F9F9F9; $well-bg: #f9f9f9;
$well-border: #EEE; $well-border: #eee;
//== Code //== Code
// //
......
...@@ -27,13 +27,13 @@ ...@@ -27,13 +27,13 @@
line-height: 10px; line-height: 10px;
color: #555; color: #555;
vertical-align: middle; vertical-align: middle;
background-color: #FCFCFC; background-color: #fcfcfc;
border-width: 1px; border-width: 1px;
border-style: solid; border-style: solid;
border-color: #CCC #CCC #BBB; border-color: #ccc #ccc #bbb;
border-image: none; border-image: none;
border-radius: 3px; border-radius: 3px;
box-shadow: 0px -1px 0px #BBB inset; box-shadow: 0 -1px 0 #bbb inset;
} }
h1 { h1 {
...@@ -187,7 +187,7 @@ body { ...@@ -187,7 +187,7 @@ body {
} }
.page-title-empty { .page-title-empty {
margin-top: 0px; margin-top: 0;
line-height: 1.3; line-height: 1.3;
font-size: 1.25em; font-size: 1.25em;
font-weight: 600; font-weight: 600;
......
$row-hover: #f4f8fe; /*
$gl-text-color: #54565B; * Layout
$gl-text-green: #4A2; */
$gl-text-red: #D12F19;
$gl-text-orange: #D90;
$gl-header-color: #323232;
$gl-link-color: #333c48;
$md-text-color: #444;
$md-link-color: #3084bb;
$progress-color: #c0392b;
$gl-font-size: 15px;
$list-font-size: 15px;
$sidebar_collapsed_width: 62px; $sidebar_collapsed_width: 62px;
$sidebar_width: 230px; $sidebar_width: 230px;
$gutter_collapsed_width: 62px; $gutter_collapsed_width: 62px;
$gutter_width: 290px; $gutter_width: 290px;
$gutter_inner_width: 258px; $gutter_inner_width: 258px;
$avatar_radius: 50%;
$code_font_size: 13px; /*
$code_line_height: 1.5; * UI elements
*/
$border-color: #efeff1; $border-color: #efeff1;
$table-border-color: #eef0f2; $table-border-color: #eef0f2;
$background-color: #faf9f9; $background-color: #faf9f9;
$header-height: 58px;
$fixed-layout-width: 1280px; /*
$gl-gray: #5a5a5a; * Text
*/
$gl-font-size: 15px;
$gl-title-color: #333;
$gl-text-color: #555;
$gl-text-green: #4a2;
$gl-text-red: #d12f19;
$gl-text-orange: #d90;
$gl-link-color: #3084bb;
$gl-dark-link-color: #333;
$gl-placeholder-color: #8f8f8f;
$gl-gray: $gl-text-color;
$gl-header-color: $gl-title-color;
/*
* Lists
*/
$list-font-size: $gl-font-size;
$list-title-color: $gl-title-color;
$list-text-color: $gl-text-color;
/*
* Markdown
*/
$md-text-color: $gl-text-color;
$md-link-color: $gl-link-color;
/*
* Code
*/
$code_font_size: 13px;
$code_line_height: 1.5;
/*
* Padding
*/
$gl-padding: 16px; $gl-padding: 16px;
$gl-btn-padding: 10px; $gl-btn-padding: 10px;
$gl-vert-padding: 6px; $gl-vert-padding: 6px;
$gl-padding-top:10px; $gl-padding-top: 10px;
/*
* Misc
*/
$row-hover: #f4f8fe;
$progress-color: #c0392b;
$avatar_radius: 50%;
$header-height: 58px;
$fixed-layout-width: 1280px;
$gl-avatar-size: 40px; $gl-avatar-size: 40px;
$secondary-text: #7f8fa4; $error-exclamation-point: #e62958;
$error-exclamation-point: #E62958;
$border-radius-default: 3px; $border-radius-default: 3px;
$list-title-color: #333333; $btn-transparent-color: #8f8f8f;
$list-text-color: #555555; $ssh-key-icon-color: #8f8f8f;
$btn-transparent-color: #8F8F8F;
$ssh-key-icon-color: #8F8F8F;
$ssh-key-icon-size: 18px; $ssh-key-icon-size: 18px;
$provider-btn-group-border: #e5e5e5;
$provider-btn-group-border: #E5E5E5; $provider-btn-not-active-color: #4688f1;
$provider-btn-not-active-color: #4688F1;
/* /*
* Color schema * Color schema
*/ */
$white-light: #FFFFFF; $white-light: #fff;
$white-normal: #ededed; $white-normal: #ededed;
$white-dark: #ededed; $white-dark: #ededed;
...@@ -57,55 +87,55 @@ $gray-dark: #ededed; ...@@ -57,55 +87,55 @@ $gray-dark: #ededed;
$gray-darkest: #c9c9c9; $gray-darkest: #c9c9c9;
$green-light: #38ae67; $green-light: #38ae67;
$green-normal: #2FAA60; $green-normal: #2faa60;
$green-dark: #2CA05B; $green-dark: #2ca05b;
$blue-light: #2EA8E5; $blue-light: #2ea8e5;
$blue-normal: #2D9FD8; $blue-normal: #2d9fd8;
$blue-dark: #2897CE; $blue-dark: #2897ce;
$blue-medium-light: #3498CB; $blue-medium-light: #3498cb;
$blue-medium: #2F8EBF; $blue-medium: #2f8ebf;
$blue-medium-dark: #2D86B4; $blue-medium-dark: #2d86b4;
$orange-light: rgba(252, 109, 38, 0.80); $orange-light: rgba(252, 109, 38, 0.80);
$orange-normal: #E75E40; $orange-normal: #e75e40;
$orange-dark: #CE5237; $orange-dark: #ce5237;
$red-light: #F06559; $red-light: #f06559;
$red-normal: #E52C5A; $red-normal: #e52c5a;
$red-dark: #D22852; $red-dark: #d22852;
$border-white-light: #F1F2F4; $border-white-light: #f1f2f4;
$border-white-normal: #D6DAE2; $border-white-normal: #d6dae2;
$border-white-dark: #C6CACF; $border-white-dark: #c6cacf;
$border-gray-light: rgba(0, 0, 0, 0.06); $border-gray-light: rgba(0, 0, 0, 0.06);
$border-gray-normal: rgba(0, 0, 0, 0.10);; $border-gray-normal: rgba(0, 0, 0, 0.10);;
$border-gray-dark: #C6CACF; $border-gray-dark: #c6cacf;
$border-green-light: #2FAA60; $border-green-light: #2faa60;
$border-green-normal: #2CA05B; $border-green-normal: #2ca05b;
$border-green-dark: #279654; $border-green-dark: #279654;
$border-blue-light: #2D9FD8; $border-blue-light: #2d9fd8;
$border-blue-normal: #2897CE; $border-blue-normal: #2897ce;
$border-blue-dark: #258DC1; $border-blue-dark: #258dc1;
$border-orange-light: #fc6d26; $border-orange-light: #fc6d26;
$border-orange-normal: #CE5237; $border-orange-normal: #ce5237;
$border-orange-dark: #C14E35; $border-orange-dark: #c14e35;
$border-red-light: #F24F41; $border-red-light: #f24f41;
$border-red-normal: #D22852; $border-red-normal: #d22852;
$border-red-dark: #CA264F; $border-red-dark: #ca264f;
$help-well-bg: #FAFAFA; $help-well-bg: #fafafa;
$help-well-border: #E5E5E5; $help-well-border: #e5e5e5;
$warning-message-bg: #FBF2D9; $warning-message-bg: #fbf2d9;
$warning-message-color: #9E8E60; $warning-message-color: #9e8e60;
$warning-message-border: #F0E2BB; $warning-message-border: #f0e2bb;
/* header */ /* header */
$light-grey-header: #faf9f9; $light-grey-header: #faf9f9;
...@@ -143,23 +173,22 @@ $dropdown-border-color: rgba(#000, .1); ...@@ -143,23 +173,22 @@ $dropdown-border-color: rgba(#000, .1);
$dropdown-shadow-color: rgba(#000, .1); $dropdown-shadow-color: rgba(#000, .1);
$dropdown-divider-color: rgba(#000, .1); $dropdown-divider-color: rgba(#000, .1);
$dropdown-header-color: #959494; $dropdown-header-color: #959494;
$dropdown-caret-color: #54565B; $dropdown-title-btn-color: #bfbfbf;
$dropdown-title-btn-color: #BFBFBF; $dropdown-input-color: #c7c7c7;
$dropdown-input-color: #C7C7C7;
$dropdown-input-focus-border: rgb(58, 171, 240); $dropdown-input-focus-border: rgb(58, 171, 240);
$dropdown-input-focus-shadow: rgba(#000, .2); $dropdown-input-focus-shadow: rgba(#000, .2);
$dropdown-loading-bg: rgba(#fff, .6); $dropdown-loading-bg: rgba(#fff, .6);
$dropdown-toggle-bg: #fff; $dropdown-toggle-bg: #fff;
$dropdown-toggle-color: #626262; $dropdown-toggle-color: #626262;
$dropdown-toggle-border-color: #EAEAEA; $dropdown-toggle-border-color: #eaeaea;
$dropdown-toggle-hover-border-color: darken($dropdown-toggle-border-color, 15%); $dropdown-toggle-hover-border-color: darken($dropdown-toggle-border-color, 15%);
$dropdown-toggle-icon-color: #C4C4C4; $dropdown-toggle-icon-color: #c4c4c4;
$dropdown-toggle-hover-icon-color: $dropdown-toggle-hover-border-color; $dropdown-toggle-hover-icon-color: $dropdown-toggle-hover-border-color;
/* /*
* Award emoji * Award emoji
*/ */
$award-emoji-menu-bg: #FFF; $award-emoji-menu-bg: #fff;
$award-emoji-menu-border: #F1F2F4; $award-emoji-menu-border: #f1f2f4;
$award-emoji-new-btn-icon-color: #DCDCDC; $award-emoji-new-btn-icon-color: #dcdcdc;
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
a.js-zen-enter { a.js-zen-enter {
color: $gl-gray; color: $gl-gray;
position: absolute; position: absolute;
top: 0px; top: 0;
right: 4px; right: 4px;
line-height: 56px; line-height: 56px;
} }
......
...@@ -43,12 +43,12 @@ ...@@ -43,12 +43,12 @@
// Search result highlight // Search result highlight
span.highlight_word { span.highlight_word {
background-color: #ffe792 !important; background-color: #ffe792 !important;
color: #000000 !important; color: #000 !important;
} }
.hll { background-color: #373b41 } .hll { background-color: #373b41 }
.c { color: #969896 } /* Comment */ .c { color: #969896 } /* Comment */
.err { color: #cc6666 } /* Error */ .err { color: #c66 } /* Error */
.k { color: #b294bb } /* Keyword */ .k { color: #b294bb } /* Keyword */
.l { color: #de935f } /* Literal */ .l { color: #de935f } /* Literal */
.n { color: #c5c8c6 } /* Name */ .n { color: #c5c8c6 } /* Name */
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
.cp { color: #969896 } /* Comment.Preproc */ .cp { color: #969896 } /* Comment.Preproc */
.c1 { color: #969896 } /* Comment.Single */ .c1 { color: #969896 } /* Comment.Single */
.cs { color: #969896 } /* Comment.Special */ .cs { color: #969896 } /* Comment.Special */
.gd { color: #cc6666 } /* Generic.Deleted */ .gd { color: #c66 } /* Generic.Deleted */
.ge { font-style: italic } /* Generic.Emph */ .ge { font-style: italic } /* Generic.Emph */
.gh { color: #c5c8c6; font-weight: bold } /* Generic.Heading */ .gh { color: #c5c8c6; font-weight: bold } /* Generic.Heading */
.gi { color: #b5bd68 } /* Generic.Inserted */ .gi { color: #b5bd68 } /* Generic.Inserted */
...@@ -77,17 +77,17 @@ ...@@ -77,17 +77,17 @@
.na { color: #81a2be } /* Name.Attribute */ .na { color: #81a2be } /* Name.Attribute */
.nb { color: #c5c8c6 } /* Name.Builtin */ .nb { color: #c5c8c6 } /* Name.Builtin */
.nc { color: #f0c674 } /* Name.Class */ .nc { color: #f0c674 } /* Name.Class */
.no { color: #cc6666 } /* Name.Constant */ .no { color: #c66 } /* Name.Constant */
.nd { color: #8abeb7 } /* Name.Decorator */ .nd { color: #8abeb7 } /* Name.Decorator */
.ni { color: #c5c8c6 } /* Name.Entity */ .ni { color: #c5c8c6 } /* Name.Entity */
.ne { color: #cc6666 } /* Name.Exception */ .ne { color: #c66 } /* Name.Exception */
.nf { color: #81a2be } /* Name.Function */ .nf { color: #81a2be } /* Name.Function */
.nl { color: #c5c8c6 } /* Name.Label */ .nl { color: #c5c8c6 } /* Name.Label */
.nn { color: #f0c674 } /* Name.Namespace */ .nn { color: #f0c674 } /* Name.Namespace */
.nx { color: #81a2be } /* Name.Other */ .nx { color: #81a2be } /* Name.Other */
.py { color: #c5c8c6 } /* Name.Property */ .py { color: #c5c8c6 } /* Name.Property */
.nt { color: #8abeb7 } /* Name.Tag */ .nt { color: #8abeb7 } /* Name.Tag */
.nv { color: #cc6666 } /* Name.Variable */ .nv { color: #c66 } /* Name.Variable */
.ow { color: #8abeb7 } /* Operator.Word */ .ow { color: #8abeb7 } /* Operator.Word */
.w { color: #c5c8c6 } /* Text.Whitespace */ .w { color: #c5c8c6 } /* Text.Whitespace */
.mf { color: #de935f } /* Literal.Number.Float */ .mf { color: #de935f } /* Literal.Number.Float */
...@@ -106,8 +106,8 @@ ...@@ -106,8 +106,8 @@
.s1 { color: #b5bd68 } /* Literal.String.Single */ .s1 { color: #b5bd68 } /* Literal.String.Single */
.ss { color: #b5bd68 } /* Literal.String.Symbol */ .ss { color: #b5bd68 } /* Literal.String.Symbol */
.bp { color: #c5c8c6 } /* Name.Builtin.Pseudo */ .bp { color: #c5c8c6 } /* Name.Builtin.Pseudo */
.vc { color: #cc6666 } /* Name.Variable.Class */ .vc { color: #c66 } /* Name.Variable.Class */
.vg { color: #cc6666 } /* Name.Variable.Global */ .vg { color: #c66 } /* Name.Variable.Global */
.vi { color: #cc6666 } /* Name.Variable.Instance */ .vi { color: #c66 } /* Name.Variable.Instance */
.il { color: #de935f } /* Literal.Number.Integer.Long */ .il { color: #de935f } /* Literal.Number.Integer.Long */
} }
...@@ -43,7 +43,7 @@ ...@@ -43,7 +43,7 @@
// Search result highlight // Search result highlight
span.highlight_word { span.highlight_word {
background-color: #ffe792 !important; background-color: #ffe792 !important;
color: #000000 !important; color: #000 !important;
} }
.hll { background-color: #49483e } .hll { background-color: #49483e }
......
...@@ -96,7 +96,7 @@ ...@@ -96,7 +96,7 @@
.m { color: #2aa198 } /* Literal.Number */ .m { color: #2aa198 } /* Literal.Number */
.s { color: #2aa198 } /* Literal.String */ .s { color: #2aa198 } /* Literal.String */
.na { color: #93a1a1 } /* Name.Attribute */ .na { color: #93a1a1 } /* Name.Attribute */
.nb { color: #B58900 } /* Name.Builtin */ .nb { color: #b58900 } /* Name.Builtin */
.nc { color: #268bd2 } /* Name.Class */ .nc { color: #268bd2 } /* Name.Class */
.no { color: #cb4b16 } /* Name.Constant */ .no { color: #cb4b16 } /* Name.Constant */
.nd { color: #268bd2 } /* Name.Decorator */ .nd { color: #268bd2 } /* Name.Decorator */
......
...@@ -96,7 +96,7 @@ ...@@ -96,7 +96,7 @@
.m { color: #2aa198 } /* Literal.Number */ .m { color: #2aa198 } /* Literal.Number */
.s { color: #2aa198 } /* Literal.String */ .s { color: #2aa198 } /* Literal.String */
.na { color: #586e75 } /* Name.Attribute */ .na { color: #586e75 } /* Name.Attribute */
.nb { color: #B58900 } /* Name.Builtin */ .nb { color: #b58900 } /* Name.Builtin */
.nc { color: #268bd2 } /* Name.Class */ .nc { color: #268bd2 } /* Name.Class */
.no { color: #cb4b16 } /* Name.Constant */ .no { color: #cb4b16 } /* Name.Constant */
.nd { color: #268bd2 } /* Name.Decorator */ .nd { color: #268bd2 } /* Name.Decorator */
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
.line_holder { .line_holder {
.diff-line-num { .diff-line-num {
&.old { &.old {
background: #ffdddd; background: #fdd;
border-color: #f1c0c0; border-color: #f1c0c0;
} }
...@@ -68,66 +68,66 @@ ...@@ -68,66 +68,66 @@
} }
.hll { background-color: #f8f8f8 } .hll { background-color: #f8f8f8 }
.c { color: #999988; font-style: italic; } .c { color: #998; font-style: italic; }
.err { color: #a61717; background-color: #e3d2d2; } .err { color: #a61717; background-color: #e3d2d2; }
.k { font-weight: bold; } .k { font-weight: bold; }
.o { font-weight: bold; } .o { font-weight: bold; }
.cm { color: #999988; font-style: italic; } .cm { color: #998; font-style: italic; }
.cp { color: #999999; font-weight: bold; } .cp { color: #999; font-weight: bold; }
.c1 { color: #999988; font-style: italic; } .c1 { color: #998; font-style: italic; }
.cs { color: #999999; font-weight: bold; font-style: italic; } .cs { color: #999; font-weight: bold; font-style: italic; }
.gd { color: #000000; background-color: #ffdddd; } .gd { color: #000; background-color: #fdd; }
.gd .x { color: #000000; background-color: #ffaaaa; } .gd .x { color: #000; background-color: #faa; }
.ge { font-style: italic; } .ge { font-style: italic; }
.gr { color: #aa0000; } .gr { color: #a00; }
.gh { color: #999999; } .gh { color: #999; }
.gi { color: #000000; background-color: #ddffdd; } .gi { color: #000; background-color: #dfd; }
.gi .x { color: #000000; background-color: #aaffaa; } .gi .x { color: #000; background-color: #afa; }
.go { color: #888888; } .go { color: #888; }
.gp { color: #555555; } .gp { color: #555; }
.gs { font-weight: bold; } .gs { font-weight: bold; }
.gu { color: #800080; font-weight: bold; } .gu { color: #800080; font-weight: bold; }
.gt { color: #aa0000; } .gt { color: #a00; }
.kc { font-weight: bold; } .kc { font-weight: bold; }
.kd { font-weight: bold; } .kd { font-weight: bold; }
.kn { font-weight: bold; } .kn { font-weight: bold; }
.kp { font-weight: bold; } .kp { font-weight: bold; }
.kr { font-weight: bold; } .kr { font-weight: bold; }
.kt { color: #445588; font-weight: bold; } .kt { color: #458; font-weight: bold; }
.m { color: #009999; } .m { color: #099; }
.s { color: #dd1144; } .s { color: #d14; }
.n { color: #333333; } .n { color: #333; }
.na { color: teal; } .na { color: teal; }
.nb { color: #0086b3; } .nb { color: #0086b3; }
.nc { color: #445588; font-weight: bold; } .nc { color: #458; font-weight: bold; }
.no { color: teal; } .no { color: teal; }
.ni { color: purple; } .ni { color: purple; }
.ne { color: #990000; font-weight: bold; } .ne { color: #900; font-weight: bold; }
.nf { color: #990000; font-weight: bold; } .nf { color: #900; font-weight: bold; }
.nn { color: #555555; } .nn { color: #555; }
.nt { color: navy; } .nt { color: navy; }
.nv { color: teal; } .nv { color: teal; }
.ow { font-weight: bold; } .ow { font-weight: bold; }
.w { color: #bbbbbb; } .w { color: #bbb; }
.mf { color: #009999; } .mf { color: #099; }
.mh { color: #009999; } .mh { color: #099; }
.mi { color: #009999; } .mi { color: #099; }
.mo { color: #009999; } .mo { color: #099; }
.sb { color: #dd1144; } .sb { color: #d14; }
.sc { color: #dd1144; } .sc { color: #d14; }
.sd { color: #dd1144; } .sd { color: #d14; }
.s2 { color: #dd1144; } .s2 { color: #d14; }
.se { color: #dd1144; } .se { color: #d14; }
.sh { color: #dd1144; } .sh { color: #d14; }
.si { color: #dd1144; } .si { color: #d14; }
.sx { color: #dd1144; } .sx { color: #d14; }
.sr { color: #009926; } .sr { color: #009926; }
.s1 { color: #dd1144; } .s1 { color: #d14; }
.ss { color: #990073; } .ss { color: #990073; }
.bp { color: #999999; } .bp { color: #999; }
.vc { color: teal; } .vc { color: teal; }
.vg { color: teal; } .vg { color: teal; }
.vi { color: teal; } .vi { color: teal; }
.il { color: #009999; } .il { color: #099; }
.gc { color: #999; background-color: #EAF2F5; } .gc { color: #999; background-color: #eaf2f5; }
} }
.build-page { .build-page {
pre.trace { pre.trace {
background: #111111; background: #111;
color: #fff; color: #fff;
font-family: $monospace_font; font-family: $monospace_font;
white-space: pre; white-space: pre;
......
...@@ -55,7 +55,7 @@ ...@@ -55,7 +55,7 @@
padding: 10px 0; padding: 10px 0;
li { li {
padding: 3px 0px; padding: 3px 0;
line-height: 20px; line-height: 20px;
} }
} }
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
.lists-separator { .lists-separator {
margin: 10px 0; margin: 10px 0;
border-color: #DDD; border-color: #ddd;
} }
.commits-row { .commits-row {
...@@ -55,7 +55,7 @@ li.commit { ...@@ -55,7 +55,7 @@ li.commit {
} }
.commit-row-message { .commit-row-message {
color: $gl-link-color; color: $gl-dark-link-color;
&:hover { &:hover {
text-decoration: underline; text-decoration: underline;
...@@ -76,7 +76,7 @@ li.commit { ...@@ -76,7 +76,7 @@ li.commit {
.commit-row-description { .commit-row-description {
font-size: 14px; font-size: 14px;
border-left: 1px solid #EEE; border-left: 1px solid #eee;
padding: 10px 15px; padding: 10px 15px;
margin: 5px 0 10px 5px; margin: 5px 0 10px 5px;
background: #f9f9f9; background: #f9f9f9;
...@@ -152,7 +152,7 @@ li.commit { ...@@ -152,7 +152,7 @@ li.commit {
.count { .count {
padding-top: 6px; padding-top: 6px;
padding-bottom: 0px; padding-bottom: 0;
font-size: 12px; font-size: 12px;
color: #333; color: #333;
display: block; display: block;
......
...@@ -11,15 +11,15 @@ ...@@ -11,15 +11,15 @@
} }
.dashboard-search-filter { .dashboard-search-filter {
padding:5px; padding: 5px;
.search-text-input { .search-text-input {
float:left; float: left;
@extend .col-md-2; @extend .col-md-2;
} }
.btn { .btn {
margin-left: 5px; margin-left: 5px;
float:left; float: left;
} }
} }
......
// Common // Common
.diff-file { .diff-file {
border: 1px solid $border-color; border: 1px solid $border-color;
border-top: none; margin-bottom: $gl-padding;
.diff-header { .diff-header {
position: relative; position: relative;
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
.diff-content { .diff-content {
overflow: auto; overflow: auto;
overflow-y: hidden; overflow-y: hidden;
background: #FFF; background: #fff;
color: #333; color: #333;
.unfold { .unfold {
...@@ -57,8 +57,8 @@ ...@@ -57,8 +57,8 @@
font-family: $monospace_font; font-family: $monospace_font;
border: none; border: none;
border-collapse: separate; border-collapse: separate;
margin: 0px; margin: 0;
padding: 0px; padding: 0;
.line_holder td { .line_holder td {
line-height: $code_line_height; line-height: $code_line_height;
font-size: $code_font_size; font-size: $code_font_size;
...@@ -76,10 +76,10 @@ ...@@ -76,10 +76,10 @@
} }
.old_line, .new_line { .old_line, .new_line {
margin: 0px; margin: 0;
padding: 0px; padding: 0;
border: none; border: none;
padding: 0px 5px; padding: 0 5px;
border-right: 1px solid; border-right: 1px solid;
text-align: right; text-align: right;
min-width: 35px; min-width: 35px;
...@@ -97,8 +97,8 @@ ...@@ -97,8 +97,8 @@
} }
.line_content { .line_content {
display: block; display: block;
margin: 0px; margin: 0;
padding: 0px 0.5em; padding: 0 0.5em;
border: none; border: none;
&.parallel { &.parallel {
display: table-cell; display: table-cell;
...@@ -118,7 +118,7 @@ ...@@ -118,7 +118,7 @@
background-color: #fff; background-color: #fff;
line-height: 0; line-height: 0;
img { img {
border: 1px solid #FFF; border: 1px solid #fff;
background: image-url('trans_bg.gif'); background: image-url('trans_bg.gif');
max-width: 100%; max-width: 100%;
} }
...@@ -183,7 +183,7 @@ ...@@ -183,7 +183,7 @@
height: 14px; height: 14px;
width: 15px; width: 15px;
position: absolute; position: absolute;
top: 0px; top: 0;
background: image-url('swipemode_sprites.gif') 0 3px no-repeat; background: image-url('swipemode_sprites.gif') 0 3px no-repeat;
} }
.bottom-handle { .bottom-handle {
...@@ -191,7 +191,7 @@ ...@@ -191,7 +191,7 @@
height: 14px; height: 14px;
width: 15px; width: 15px;
position: absolute; position: absolute;
bottom: 0px; bottom: 0;
background: image-url('swipemode_sprites.gif') 0 -11px no-repeat; background: image-url('swipemode_sprites.gif') 0 -11px no-repeat;
} }
} }
...@@ -206,8 +206,8 @@ ...@@ -206,8 +206,8 @@
.frame.added, .frame.deleted { .frame.added, .frame.deleted {
position: absolute; position: absolute;
display: block; display: block;
top: 0px; top: 0;
left: 0px; left: 0;
} }
.controls { .controls {
display: block; display: block;
...@@ -215,7 +215,7 @@ ...@@ -215,7 +215,7 @@
width: 300px; width: 300px;
z-index: 100; z-index: 100;
position: absolute; position: absolute;
bottom: 0px; bottom: 0;
left: 50%; left: 50%;
margin-left: -150px; margin-left: -150px;
...@@ -231,11 +231,11 @@ ...@@ -231,11 +231,11 @@
.dragger { .dragger {
display: block; display: block;
position: absolute; position: absolute;
left: 0px; left: 0;
top: 0px; top: 0;
height: 14px; height: 14px;
width: 14px; width: 14px;
background: image-url('onion_skin_sprites.gif') 0px -34px repeat-x; background: image-url('onion_skin_sprites.gif') 0 -34px repeat-x;
cursor: pointer; cursor: pointer;
} }
...@@ -243,17 +243,17 @@ ...@@ -243,17 +243,17 @@
display: block; display: block;
position: absolute; position: absolute;
top: 2px; top: 2px;
right: 0px; right: 0;
height: 10px; height: 10px;
width: 10px; width: 10px;
background: image-url('onion_skin_sprites.gif') -2px 0px no-repeat; background: image-url('onion_skin_sprites.gif') -2px 0 no-repeat;
} }
.opaque { .opaque {
display: block; display: block;
position: absolute; position: absolute;
top: 2px; top: 2px;
left: 0px; left: 0;
height: 10px; height: 10px;
width: 10px; width: 10px;
background: image-url('onion_skin_sprites.gif') -2px -10px no-repeat; background: image-url('onion_skin_sprites.gif') -2px -10px no-repeat;
...@@ -265,7 +265,7 @@ ...@@ -265,7 +265,7 @@
.view-modes { .view-modes {
padding: 10px; padding: 10px;
text-align: center; text-align: center;
background: #EEE; background: #eee;
ul, li { ul, li {
list-style: none; list-style: none;
...@@ -361,3 +361,11 @@ ...@@ -361,3 +361,11 @@
border-color: $border; border-color: $border;
} }
} }
.files {
margin-top: -1px;
.diff-file:last-child {
margin-bottom: 0;
}
}
...@@ -14,9 +14,9 @@ ...@@ -14,9 +14,9 @@
} }
.cancel-btn { .cancel-btn {
color: #B94A48; color: #b94a48;
&:hover { &:hover {
color: #B94A48; color: #b94a48;
} }
} }
......
This diff is collapsed.
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
font-size: $gl-font-size; font-size: $gl-font-size;
padding: $gl-padding-top 0 $gl-padding-top ($gl-avatar-size + $gl-padding-top); padding: $gl-padding-top 0 $gl-padding-top ($gl-avatar-size + $gl-padding-top);
border-bottom: 1px solid $table-border-color; border-bottom: 1px solid $table-border-color;
color: #7f8fa4; color: $list-text-color;
&.event-inline { &.event-inline {
.avatar { .avatar {
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
} }
a { a {
color: #4c4e54; color: $gl-dark-link-color;
} }
.avatar { .avatar {
...@@ -31,10 +31,7 @@ ...@@ -31,10 +31,7 @@
.event-title { .event-title {
@include str-truncated(calc(100% - 174px)); @include str-truncated(calc(100% - 174px));
font-weight: 600; font-weight: 600;
color: $list-text-color;
.author_name {
color: #333;
}
} }
.event-body { .event-body {
...@@ -63,7 +60,7 @@ ...@@ -63,7 +60,7 @@
.note-image-attach { .note-image-attach {
margin-top: 4px; margin-top: 4px;
margin-left: 0px; margin-left: 0;
max-width: 200px; max-width: 200px;
float: none; float: none;
} }
...@@ -83,10 +80,10 @@ ...@@ -83,10 +80,10 @@
.event_icon { .event_icon {
position: relative; position: relative;
float: right; float: right;
border: 1px solid #EEE; border: 1px solid #eee;
padding: 5px; padding: 5px;
@include border-radius(5px); @include border-radius(5px);
background: #F9F9F9; background: #f9f9f9;
margin-left: 10px; margin-left: 10px;
top: -6px; top: -6px;
img { img {
...@@ -94,7 +91,7 @@ ...@@ -94,7 +91,7 @@
} }
} }
&:last-child { border:none } &:last-child { border: none }
.event_commits { .event_commits {
li { li {
...@@ -138,7 +135,7 @@ ...@@ -138,7 +135,7 @@
@include str-truncated(100%); @include str-truncated(100%);
padding: 5px 0; padding: 5px 0;
font-size: 13px; font-size: 13px;
float:left; float: left;
margin-right: -150px; margin-right: -150px;
padding-right: 150px; padding-right: 150px;
line-height: 20px; line-height: 20px;
...@@ -160,7 +157,7 @@ ...@@ -160,7 +157,7 @@
.event-body { .event-body {
margin: 0; margin: 0;
border-left: 2px solid #DDD; border-left: 2px solid #ddd;
padding-left: 10px; padding-left: 10px;
} }
......
...@@ -6,11 +6,11 @@ ...@@ -6,11 +6,11 @@
font-size: 14px; font-size: 14px;
padding: 5px; padding: 5px;
border-bottom: 1px solid $border-color; border-bottom: 1px solid $border-color;
background: #EEE; background: #eee;
} }
.network-graph { .network-graph {
background: #FFF; background: #fff;
height: 500px; height: 500px;
overflow-y: scroll; overflow-y: scroll;
overflow-x: hidden; overflow-x: hidden;
......
i.icon-gitorious { i.icon-gitorious {
display: inline-block; display: inline-block;
background-position: 0px 0px; background-position: 0 0;
background-size: contain; background-size: contain;
background-repeat: no-repeat; background-repeat: no-repeat;
} }
......
@media (max-width: $screen-sm-max) {
.issuable-affix {
margin-top: 20px;
}
}
@media (max-width: $screen-md-max) {
.issuable-affix {
position: static;
}
}
@media (min-width: $screen-md-max) {
.issuable-affix {
&.affix-top {
position: static;
}
&.affix {
position: fixed;
top: 70px;
margin-right: 35px;
&.no-affix {
position: relative;
top: 0;
}
}
}
}
.issuable-details { .issuable-details {
section { section {
.issuable-discussion { .issuable-discussion {
...@@ -54,6 +23,10 @@ ...@@ -54,6 +23,10 @@
padding: 6px 10px; padding: 6px 10px;
} }
} }
&.has-labels {
margin-bottom: -5px;
}
} }
.issuable-sidebar { .issuable-sidebar {
...@@ -66,8 +39,9 @@ ...@@ -66,8 +39,9 @@
width: $gutter_inner_width; width: $gutter_inner_width;
// -- // --
&:first-child { &.issuable-sidebar-header {
padding-top: 5px; padding-top: 0;
padding-bottom: 10px;
} }
&:last-child { &:last-child {
...@@ -75,7 +49,6 @@ ...@@ -75,7 +49,6 @@
} }
span { span {
margin-top: 7px;
display: inline-block; display: inline-block;
} }
...@@ -84,7 +57,7 @@ ...@@ -84,7 +57,7 @@
} }
.issuable-count { .issuable-count {
margin-top: 7px;
} }
.gutter-toggle { .gutter-toggle {
...@@ -99,19 +72,19 @@ ...@@ -99,19 +72,19 @@
.title { .title {
color: $gl-text-color; color: $gl-text-color;
margin-bottom: 8px; margin-bottom: 10px;
line-height: 1;
.avatar { .avatar {
margin-left: 0; margin-left: 0;
} }
label {
font-weight: normal;
margin-right: 4px;
}
.edit-link { .edit-link {
color: $gl-gray; color: $gl-gray;
&:hover {
color: $md-link-color;
}
} }
} }
...@@ -144,11 +117,6 @@ ...@@ -144,11 +117,6 @@
.btn-clipboard { .btn-clipboard {
color: $gl-gray; color: $gl-gray;
} }
.participants .avatar {
margin-top: 6px;
margin-right: 2px;
}
} }
.right-sidebar { .right-sidebar {
...@@ -163,8 +131,12 @@ ...@@ -163,8 +131,12 @@
&.right-sidebar-expanded { &.right-sidebar-expanded {
width: $gutter_width; width: $gutter_width;
hr { .value {
display: none; line-height: 1;
}
.bold {
font-weight: 600;
} }
.sidebar-collapsed-icon { .sidebar-collapsed-icon {
...@@ -172,8 +144,23 @@ ...@@ -172,8 +144,23 @@
} }
.gutter-toggle { .gutter-toggle {
margin-top: 7px;
border-left: 1px solid $border-gray-light; border-left: 1px solid $border-gray-light;
} }
.assignee .avatar {
float: left;
margin-right: 10px;
margin-bottom: 0;
margin-left: 0;
}
.username {
display: block;
margin-top: 4px;
font-size: 13px;
font-weight: normal;
}
} }
.subscribe-button { .subscribe-button {
...@@ -193,14 +180,6 @@ ...@@ -193,14 +180,6 @@
width: $sidebar_collapsed_width; width: $sidebar_collapsed_width;
padding-top: 0; padding-top: 0;
hr {
margin: 0;
color: $gray-normal;
border-color: $gray-normal;
width: 62px;
margin-left: -20px
}
.block { .block {
width: $sidebar_collapsed_width - 1px; width: $sidebar_collapsed_width - 1px;
margin-left: -19px; margin-left: -19px;
...@@ -209,12 +188,18 @@ ...@@ -209,12 +188,18 @@
overflow: hidden; overflow: hidden;
} }
.participants {
border-bottom: 1px solid $border-gray-light;
}
.hide-collapsed { .hide-collapsed {
display: none; display: none;
} }
.gutter-toggle { .gutter-toggle {
margin-left: -36px; width: 100%;
margin-left: 0;
padding-left: 25px;
} }
.sidebar-collapsed-icon { .sidebar-collapsed-icon {
...@@ -222,13 +207,17 @@ ...@@ -222,13 +207,17 @@
width: 100%; width: 100%;
text-align: center; text-align: center;
padding-bottom: 10px; padding-bottom: 10px;
color: #999999; color: #999;
span { span {
display: block; display: block;
margin-top: 0; margin-top: 0;
} }
.author {
display: none;
}
.btn-clipboard { .btn-clipboard {
border: none; border: none;
...@@ -237,10 +226,15 @@ ...@@ -237,10 +226,15 @@
} }
i { i {
color: #999999; color: #999;
} }
} }
} }
.sidebar-collapsed-user {
padding-bottom: 0;
margin-bottom: 10px;
}
} }
.btn { .btn {
...@@ -251,6 +245,13 @@ ...@@ -251,6 +245,13 @@
border: 1px solid $border-gray-dark; border: 1px solid $border-gray-dark;
} }
} }
a:not(.btn) {
&:hover {
color: $md-link-color;
text-decoration: none;
}
}
} }
.btn-default.gutter-toggle { .btn-default.gutter-toggle {
...@@ -262,3 +263,37 @@ ...@@ -262,3 +263,37 @@
color: $gray-darkest; color: $gray-darkest;
} }
} }
.edited-text {
color: $gray-darkest;
.author_link {
color: $gray-darkest;
}
}
.participants-list {
margin: -5px -5px;
}
.participants-author {
display: inline-block;
padding: 5px 5px;
.author_link {
display: block;
}
.avatar.avatar-inline {
margin: 0;
}
}
.participants-more {
margin-top: 5px;
margin-left: 5px;
a {
color: #8c8c8c;
}
}
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
padding: 10px $gl-padding; padding: 10px $gl-padding;
position: relative; position: relative;
.issue-title { .title {
margin-bottom: 2px; margin-bottom: 2px;
} }
...@@ -49,7 +49,7 @@ form.edit-issue { ...@@ -49,7 +49,7 @@ form.edit-issue {
margin: 0; margin: 0;
} }
.merge-requests-title { .merge-requests-title, .related-branches-title {
font-size: 16px; font-size: 16px;
font-weight: 600; font-weight: 600;
} }
...@@ -68,18 +68,18 @@ form.edit-issue { ...@@ -68,18 +68,18 @@ form.edit-issue {
.merge-request, .merge-request,
.issue { .issue {
&.today { &.today {
background: #EFE; background: #efe;
border-color: #CEC; border-color: #cec;
} }
&.closed { &.closed {
background: #F9F9F9; background: #f9f9f9;
border-color: #E5E5E5; border-color: #e5e5e5;
} }
&.merged { &.merged {
background: #F9F9F9; background: #f9f9f9;
border-color: #E5E5E5; border-color: #e5e5e5;
} }
} }
...@@ -130,7 +130,7 @@ form.edit-issue { ...@@ -130,7 +130,7 @@ form.edit-issue {
} }
.issue-closed-by-widget { .issue-closed-by-widget {
color: $secondary-text; color: $gl-text-color;
margin-left: 52px; margin-left: 52px;
} }
......
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
.login-box{ .login-box{
background: #fafafa; background: #fafafa;
border-radius: 10px; border-radius: 10px;
box-shadow: 0 0px 2px #CCC; box-shadow: 0 0 2px #ccc;
padding: 15px; padding: 15px;
.login-heading h3 { .login-heading h3 {
...@@ -74,7 +74,7 @@ ...@@ -74,7 +74,7 @@
&.top { &.top {
@include border-radius(5px 5px 0 0); @include border-radius(5px 5px 0 0);
margin-bottom: 0px; margin-bottom: 0;
} }
&.bottom { &.bottom {
...@@ -85,12 +85,12 @@ ...@@ -85,12 +85,12 @@
&.middle { &.middle {
border-top: 0; border-top: 0;
margin-bottom:0px; margin-bottom: 0;
@include border-radius(0); @include border-radius(0);
} }
&:active, &:focus { &:active, &:focus {
background-color: #FFF; background-color: #fff;
} }
} }
......
...@@ -113,7 +113,7 @@ ...@@ -113,7 +113,7 @@
} }
.mr-widget-footer { .mr-widget-footer {
border-top: 1px solid #EEE; border-top: 1px solid #eee;
} }
.ci-coverage { .ci-coverage {
...@@ -222,7 +222,7 @@ ...@@ -222,7 +222,7 @@
margin-bottom: 20px; margin-bottom: 20px;
span { span {
color: #B2B2B2; color: #b2b2b2;
a { a {
color: $md-link-color; color: $md-link-color;
......
...@@ -156,7 +156,7 @@ ...@@ -156,7 +156,7 @@
.comment-hints { .comment-hints {
color: #999; color: #999;
background: #FFF; background: #fff;
padding: 7px; padding: 7px;
margin-top: -7px; margin-top: -7px;
border: 1px solid $border-color; border: 1px solid $border-color;
......
...@@ -3,16 +3,16 @@ ...@@ -3,16 +3,16 @@
*/ */
@-webkit-keyframes targe3-note { @-webkit-keyframes targe3-note {
from { background:#fffff0; } from { background: #fffff0; }
50% { background:#ffffd3; } 50% { background: #ffffd3; }
to { background:#fffff0; } to { background: #fffff0; }
} }
ul.notes { ul.notes {
display: block; display: block;
list-style: none; list-style: none;
margin: 0px; margin: 0;
padding: 0px; padding: 0;
.timeline-icon { .timeline-icon {
float: left; float: left;
...@@ -30,7 +30,7 @@ ul.notes { ...@@ -30,7 +30,7 @@ ul.notes {
font-size: 14px; font-size: 14px;
padding-top: 10px; padding-top: 10px;
padding-bottom: 10px; padding-bottom: 10px;
background: #FDFDFD; background: #fdfdfd;
.timeline-icon { .timeline-icon {
.avatar { .avatar {
...@@ -93,12 +93,12 @@ ul.notes { ...@@ -93,12 +93,12 @@ ul.notes {
.discussion { .discussion {
overflow: hidden; overflow: hidden;
display: block; display: block;
position:relative; position: relative;
} }
.note { .note {
display: block; display: block;
position:relative; position: relative;
.note-body { .note-body {
overflow: auto; overflow: auto;
...@@ -108,6 +108,13 @@ ul.notes { ...@@ -108,6 +108,13 @@ ul.notes {
word-wrap: break-word; word-wrap: break-word;
@include md-typography; @include md-typography;
// On diffs code should wrap nicely and not overflow
pre {
code {
white-space: pre-wrap;
}
}
// Reset ul style types since we're nested inside a ul already // Reset ul style types since we're nested inside a ul already
& > ul { & > ul {
list-style-type: disc; list-style-type: disc;
...@@ -129,7 +136,7 @@ ul.notes { ...@@ -129,7 +136,7 @@ ul.notes {
hr { hr {
// Darken 'whitesmoke' a bit to make it more visible in note bodies // Darken 'whitesmoke' a bit to make it more visible in note bodies
border-color: darken(#F5F5F5, 8%); border-color: darken(#f5f5f5, 8%);
margin: 10px 0; margin: 10px 0;
} }
} }
...@@ -166,7 +173,7 @@ ul.notes { ...@@ -166,7 +173,7 @@ ul.notes {
vertical-align: middle; vertical-align: middle;
text-align: center; text-align: center;
padding: 10px 0; padding: 10px 0;
background: #FFF; background: #fff;
color: $text-color; color: $text-color;
} }
&.notes_line2 { &.notes_line2 {
...@@ -232,7 +239,7 @@ ul.notes { ...@@ -232,7 +239,7 @@ ul.notes {
.add-diff-note { .add-diff-note {
margin-top: -4px; margin-top: -4px;
@include border-radius(40px); @include border-radius(40px);
background: #FFF; background: #fff;
padding: 4px; padding: 4px;
font-size: 16px; font-size: 16px;
color: $gl-link-color; color: $gl-link-color;
...@@ -249,7 +256,7 @@ ul.notes { ...@@ -249,7 +256,7 @@ ul.notes {
&:hover { &:hover {
background: $gl-info; background: $gl-info;
color: #FFF; color: #fff;
@include show-add-diff-note; @include show-add-diff-note;
} }
} }
......
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
.btn { .btn {
line-height: 40px; line-height: 40px;
height: 42px; height: 42px;
padding: 0px 12px; padding: 0 12px;
img { img {
width: 32px; width: 32px;
......
...@@ -33,6 +33,13 @@ ...@@ -33,6 +33,13 @@
.project-settings-dropdown { .project-settings-dropdown {
margin-left: 10px; margin-left: 10px;
display: inline-block; display: inline-block;
.dropdown-menu {
left: auto;
width: auto;
right: 0px;
max-width: 240px;
}
} }
} }
...@@ -63,7 +70,7 @@ ...@@ -63,7 +70,7 @@
.project-repo-buttons { .project-repo-buttons {
margin-top: 20px; margin-top: 20px;
margin-bottom: 0px; margin-bottom: 0;
.count-buttons { .count-buttons {
display: block; display: block;
...@@ -118,7 +125,7 @@ ...@@ -118,7 +125,7 @@
left: 1px; left: 1px;
margin-top: -9px; margin-top: -9px;
border-width: 10px 7px 10px 0; border-width: 10px 7px 10px 0;
border-right-color: #FFF; border-right-color: #fff;
} }
} }
.count { .count {
...@@ -140,10 +147,10 @@ ...@@ -140,10 +147,10 @@
cursor: pointer; cursor: pointer;
background-image: none; background-image: none;
white-space: nowrap; white-space: nowrap;
margin: 0 11px 0px 4px; margin: 0 11px 0 4px;
&:hover { &:hover {
background: #FFF; background: #fff;
} }
} }
} }
...@@ -188,7 +195,7 @@ ...@@ -188,7 +195,7 @@
} }
.project_member_row form { .project_member_row form {
margin: 0px; margin: 0;
} }
.transfer-project .select2-container { .transfer-project .select2-container {
...@@ -264,11 +271,11 @@ table.table.protected-branches-list tr.no-border { ...@@ -264,11 +271,11 @@ table.table.protected-branches-list tr.no-border {
padding-bottom: 4px; padding-bottom: 4px;
ul.nav { ul.nav {
display:inline-block; display: inline-block;
} }
.nav li { .nav li {
display:inline; display: inline;
} }
.nav > li > a { .nav > li > a {
...@@ -281,11 +288,11 @@ table.table.protected-branches-list tr.no-border { ...@@ -281,11 +288,11 @@ table.table.protected-branches-list tr.no-border {
} }
li { li {
display:inline; display: inline;
} }
a { a {
float:left; float: left;
font-size: 17px; font-size: 17px;
} }
...@@ -440,7 +447,7 @@ pre.light-well { ...@@ -440,7 +447,7 @@ pre.light-well {
.form-control { .form-control {
@extend .monospace; @extend .monospace;
background: #FFF; background: #fff;
font-size: 14px; font-size: 14px;
margin-left: -1px; margin-left: -1px;
cursor: auto; cursor: auto;
...@@ -450,16 +457,16 @@ pre.light-well { ...@@ -450,16 +457,16 @@ pre.light-well {
.cannot-be-merged, .cannot-be-merged,
.cannot-be-merged:hover { .cannot-be-merged:hover {
color: #E62958; color: #e62958;
margin-top: 2px; margin-top: 2px;
} }
.private-forks-notice .private-fork-icon { .private-forks-notice .private-fork-icon {
i:nth-child(1) { i:nth-child(1) {
color: #2AA056; color: #2aa056;
} }
i:nth-child(2) { i:nth-child(2) {
color: #FFFFFF; color: #fff;
} }
} }
.runner-state { .runner-state {
padding: 6px 12px; padding: 6px 12px;
margin-right: 10px; margin-right: 10px;
color: #FFF; color: #fff;
&.runner-state-shared { &.runner-state-shared {
background: #32b186; background: #32b186;
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
margin-bottom: 20px; margin-bottom: 20px;
input { input {
border-color: #BBB; border-color: #bbb;
font-weight: bold; font-weight: bold;
} }
} }
......
...@@ -13,13 +13,13 @@ table .sherlock-code { ...@@ -13,13 +13,13 @@ table .sherlock-code {
} }
.sherlock-line-samples-table { .sherlock-line-samples-table {
margin-bottom: 0px !important; margin-bottom: 0 !important;
thead tr th, thead tr th,
tbody tr td { tbody tr td {
font-size: 13px !important; font-size: 13px !important;
text-align: right; text-align: right;
padding: 0px 10px !important; padding: 0 10px !important;
} }
} }
......
.ci-status { .ci-status {
padding: 2px 7px; padding: 2px 7px;
margin-right: 5px; margin-right: 5px;
border: 1px solid #EEE; border: 1px solid #eee;
white-space: nowrap; white-space: nowrap;
@include border-radius(4px); @include border-radius(4px);
......
...@@ -14,25 +14,8 @@ ...@@ -14,25 +14,8 @@
} }
.todo-item { .todo-item {
font-size: $gl-font-size;
padding-left: $gl-avatar-size + $gl-padding-top;
color: $secondary-text;
a {
color: #4c4e54;
}
.avatar {
margin-left: -($gl-avatar-size + $gl-padding-top);
}
.todo-title { .todo-title {
@include str-truncated(calc(100% - 174px)); @include str-truncated(calc(100% - 174px));
font-weight: 600;
.author-name {
color: #333;
}
} }
.todo-body { .todo-body {
...@@ -61,7 +44,7 @@ ...@@ -61,7 +44,7 @@
.note-image-attach { .note-image-attach {
margin-top: 4px; margin-top: 4px;
margin-left: 0px; margin-left: 0;
max-width: 200px; max-width: 200px;
float: none; float: none;
} }
...@@ -89,7 +72,7 @@ ...@@ -89,7 +72,7 @@
.todo-body { .todo-body {
margin: 0; margin: 0;
border-left: 2px solid #DDD; border-left: 2px solid #ddd;
padding-left: 10px; padding-left: 10px;
} }
} }
......
...@@ -41,12 +41,12 @@ ...@@ -41,12 +41,12 @@
vertical-align: middle; vertical-align: middle;
i, a { i, a {
color: $gl-link-color; color: $gl-dark-link-color;
} }
img { img {
position: relative; position: relative;
top:-1px; top: -1px;
} }
} }
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
.example { .example {
&:before { &:before {
content: "Example"; content: "Example";
color: #BBB; color: #bbb;
} }
padding: 15px; padding: 15px;
......
...@@ -2,23 +2,23 @@ ...@@ -2,23 +2,23 @@
// color codes are based on http://en.wikipedia.org/wiki/File:Xterm_256color_chart.svg // color codes are based on http://en.wikipedia.org/wiki/File:Xterm_256color_chart.svg
// see also: https://gist.github.com/jasonm23/2868981 // see also: https://gist.github.com/jasonm23/2868981
$black: #000000; $black: #000;
$red: #cd0000; $red: #cd0000;
$green: #00cd00; $green: #00cd00;
$yellow: #cdcd00; $yellow: #cdcd00;
$blue: #0000ee; // according to wikipedia, this is the xterm standard $blue: #00e; // according to wikipedia, this is the xterm standard
//$blue: #1e90ff; // this is used by all the terminals I tried (when configured with the xterm color profile) //$blue: #1e90ff; // this is used by all the terminals I tried (when configured with the xterm color profile)
$magenta: #cd00cd; $magenta: #cd00cd;
$cyan: #00cdcd; $cyan: #00cdcd;
$white: #e5e5e5; $white: #e5e5e5;
$l-black: #7f7f7f; $l-black: #7f7f7f;
$l-red: #ff0000; $l-red: #f00;
$l-green: #00ff00; $l-green: #0f0;
$l-yellow: #ffff00; $l-yellow: #ff0;
$l-blue: #5c5cff; $l-blue: #5c5cff;
$l-magenta: #ff00ff; $l-magenta: #f0f;
$l-cyan: #00ffff; $l-cyan: #0ff;
$l-white: #ffffff; $l-white: #fff;
.term-bold { .term-bold {
font-weight: bold; font-weight: bold;
...@@ -136,7 +136,7 @@ ...@@ -136,7 +136,7 @@
.xterm-fg-0 { .xterm-fg-0 {
color: #000000; color: #000;
} }
.xterm-fg-1 { .xterm-fg-1 {
color: #800000; color: #800000;
...@@ -163,28 +163,28 @@ ...@@ -163,28 +163,28 @@
color: #808080; color: #808080;
} }
.xterm-fg-9 { .xterm-fg-9 {
color: #ff0000; color: #f00;
} }
.xterm-fg-10 { .xterm-fg-10 {
color: #00ff00; color: #0f0;
} }
.xterm-fg-11 { .xterm-fg-11 {
color: #ffff00; color: #ff0;
} }
.xterm-fg-12 { .xterm-fg-12 {
color: #0000ff; color: #00f;
} }
.xterm-fg-13 { .xterm-fg-13 {
color: #ff00ff; color: #f0f;
} }
.xterm-fg-14 { .xterm-fg-14 {
color: #00ffff; color: #0ff;
} }
.xterm-fg-15 { .xterm-fg-15 {
color: #ffffff; color: #fff;
} }
.xterm-fg-16 { .xterm-fg-16 {
color: #000000; color: #000;
} }
.xterm-fg-17 { .xterm-fg-17 {
color: #00005f; color: #00005f;
...@@ -199,7 +199,7 @@ ...@@ -199,7 +199,7 @@
color: #0000d7; color: #0000d7;
} }
.xterm-fg-21 { .xterm-fg-21 {
color: #0000ff; color: #00f;
} }
.xterm-fg-22 { .xterm-fg-22 {
color: #005f00; color: #005f00;
...@@ -274,7 +274,7 @@ ...@@ -274,7 +274,7 @@
color: #00d7ff; color: #00d7ff;
} }
.xterm-fg-46 { .xterm-fg-46 {
color: #00ff00; color: #0f0;
} }
.xterm-fg-47 { .xterm-fg-47 {
color: #00ff5f; color: #00ff5f;
...@@ -289,7 +289,7 @@ ...@@ -289,7 +289,7 @@
color: #00ffd7; color: #00ffd7;
} }
.xterm-fg-51 { .xterm-fg-51 {
color: #00ffff; color: #0ff;
} }
.xterm-fg-52 { .xterm-fg-52 {
color: #5f0000; color: #5f0000;
...@@ -724,7 +724,7 @@ ...@@ -724,7 +724,7 @@
color: #d7ffff; color: #d7ffff;
} }
.xterm-fg-196 { .xterm-fg-196 {
color: #ff0000; color: #f00;
} }
.xterm-fg-197 { .xterm-fg-197 {
color: #ff005f; color: #ff005f;
...@@ -739,7 +739,7 @@ ...@@ -739,7 +739,7 @@
color: #ff00d7; color: #ff00d7;
} }
.xterm-fg-201 { .xterm-fg-201 {
color: #ff00ff; color: #f0f;
} }
.xterm-fg-202 { .xterm-fg-202 {
color: #ff5f00; color: #ff5f00;
...@@ -814,7 +814,7 @@ ...@@ -814,7 +814,7 @@
color: #ffd7ff; color: #ffd7ff;
} }
.xterm-fg-226 { .xterm-fg-226 {
color: #ffff00; color: #ff0;
} }
.xterm-fg-227 { .xterm-fg-227 {
color: #ffff5f; color: #ffff5f;
...@@ -829,7 +829,7 @@ ...@@ -829,7 +829,7 @@
color: #ffffd7; color: #ffffd7;
} }
.xterm-fg-231 { .xterm-fg-231 {
color: #ffffff; color: #fff;
} }
.xterm-fg-232 { .xterm-fg-232 {
color: #080808; color: #080808;
...@@ -850,7 +850,7 @@ ...@@ -850,7 +850,7 @@
color: #3a3a3a; color: #3a3a3a;
} }
.xterm-fg-238 { .xterm-fg-238 {
color: #444444; color: #444;
} }
.xterm-fg-239 { .xterm-fg-239 {
color: #4e4e4e; color: #4e4e4e;
...@@ -901,6 +901,6 @@ ...@@ -901,6 +901,6 @@
color: #e4e4e4; color: #e4e4e4;
} }
.xterm-fg-255 { .xterm-fg-255 {
color: #eeeeee; color: #eee;
} }
} }
...@@ -6,7 +6,7 @@ class Admin::AbuseReportsController < Admin::ApplicationController ...@@ -6,7 +6,7 @@ class Admin::AbuseReportsController < Admin::ApplicationController
def destroy def destroy
abuse_report = AbuseReport.find(params[:id]) abuse_report = AbuseReport.find(params[:id])
abuse_report.remove_user if params[:remove_user] abuse_report.remove_user(deleted_by: current_user) if params[:remove_user]
abuse_report.destroy abuse_report.destroy
render nothing: true render nothing: true
......
...@@ -119,10 +119,10 @@ class Admin::UsersController < Admin::ApplicationController ...@@ -119,10 +119,10 @@ class Admin::UsersController < Admin::ApplicationController
end end
def destroy def destroy
DeleteUserService.new(current_user).execute(user) DeleteUserWorker.perform_async(current_user.id, user.id)
respond_to do |format| respond_to do |format|
format.html { redirect_to admin_users_path } format.html { redirect_to admin_users_path, notice: "The user is being deleted." }
format.json { head :ok } format.json { head :ok }
end end
end end
......
class Dashboard::TodosController < Dashboard::ApplicationController class Dashboard::TodosController < Dashboard::ApplicationController
before_action :find_todos, only: [:index, :destroy_all] before_action :find_todos, only: [:index, :destroy, :destroy_all]
def index def index
@todos = @todos.page(params[:page]).per(PER_PAGE) @todos = @todos.page(params[:page]).per(PER_PAGE)
end end
def destroy def destroy
todo.done! todo.done
todo_notice = 'Todo was successfully marked as done.'
respond_to do |format| respond_to do |format|
format.html { redirect_to dashboard_todos_path, notice: 'Todo was successfully marked as done.' } format.html { redirect_to dashboard_todos_path, notice: todo_notice }
format.js { render nothing: true } format.js { render nothing: true }
format.json do
render json: { count: @todos.size, done_count: current_user.todos.done.count }
end
end end
end end
def destroy_all def destroy_all
@todos.each(&:done!) @todos.each(&:done)
respond_to do |format| respond_to do |format|
format.html { redirect_to dashboard_todos_path, notice: 'All todos were marked as done.' } format.html { redirect_to dashboard_todos_path, notice: 'All todos were marked as done.' }
format.js { render nothing: true } format.js { render nothing: true }
format.json do
find_todos
render json: { count: @todos.size, done_count: current_user.todos.done.count }
end
end end
end end
......
...@@ -3,7 +3,7 @@ class DashboardController < Dashboard::ApplicationController ...@@ -3,7 +3,7 @@ class DashboardController < Dashboard::ApplicationController
include MergeRequestsAction include MergeRequestsAction
before_action :event_filter, only: :activity before_action :event_filter, only: :activity
before_action :projects, only: [:issues, :merge_requests] before_action :projects, only: [:issues, :merge_requests, :labels, :milestones]
respond_to :html respond_to :html
...@@ -20,6 +20,29 @@ class DashboardController < Dashboard::ApplicationController ...@@ -20,6 +20,29 @@ class DashboardController < Dashboard::ApplicationController
end end
end end
def labels
labels = Label.where(project_id: @projects).select(:title, :color).uniq(:title)
respond_to do |format|
format.json do
render json: labels
end
end
end
def milestones
milestones = Milestone.where(project_id: @projects).active
epoch = DateTime.parse('1970-01-01')
grouped_milestones = GlobalMilestone.build_collection(milestones)
grouped_milestones = grouped_milestones.sort_by { |x| x.due_date.nil? ? epoch : x.due_date }
respond_to do |format|
format.json do
render json: grouped_milestones
end
end
end
protected protected
def load_events def load_events
......
...@@ -7,6 +7,7 @@ class Oauth::AuthorizationsController < Doorkeeper::AuthorizationsController ...@@ -7,6 +7,7 @@ class Oauth::AuthorizationsController < Doorkeeper::AuthorizationsController
if pre_auth.authorizable? if pre_auth.authorizable?
if skip_authorization? || matching_token? if skip_authorization? || matching_token?
auth = authorization.authorize auth = authorization.authorize
session.delete(:user_return_to)
redirect_to auth.redirect_uri redirect_to auth.redirect_uri
else else
render "doorkeeper/authorizations/new" render "doorkeeper/authorizations/new"
......
class Projects::BadgesController < Projects::ApplicationController class Projects::BadgesController < Projects::ApplicationController
before_action :set_no_cache before_action :no_cache_headers
def build def build
respond_to do |format| respond_to do |format|
...@@ -10,15 +10,4 @@ class Projects::BadgesController < Projects::ApplicationController ...@@ -10,15 +10,4 @@ class Projects::BadgesController < Projects::ApplicationController
end end
end end
end end
private
def set_no_cache
expires_now
# Add some deprecated headers for older agents
#
response.headers['Pragma'] = 'no-cache'
response.headers['Expires'] = 'Fri, 01 Jan 1990 00:00:00 GMT'
end
end end
...@@ -23,11 +23,15 @@ class Projects::BranchesController < Projects::ApplicationController ...@@ -23,11 +23,15 @@ class Projects::BranchesController < Projects::ApplicationController
def create def create
branch_name = sanitize(strip_tags(params[:branch_name])) branch_name = sanitize(strip_tags(params[:branch_name]))
branch_name = Addressable::URI.unescape(branch_name) branch_name = Addressable::URI.unescape(branch_name)
ref = sanitize(strip_tags(params[:ref]))
ref = Addressable::URI.unescape(ref)
result = CreateBranchService.new(project, current_user). result = CreateBranchService.new(project, current_user).
execute(branch_name, ref) execute(branch_name, ref)
if params[:issue_iid]
issue = @project.issues.find_by(iid: params[:issue_iid])
SystemNoteService.new_issue_branch(issue, @project, current_user, branch_name) if issue
end
if result[:status] == :success if result[:status] == :success
@branch = result[:branch] @branch = result[:branch]
redirect_to namespace_project_tree_path(@project.namespace, @project, redirect_to namespace_project_tree_path(@project.namespace, @project,
...@@ -49,4 +53,15 @@ class Projects::BranchesController < Projects::ApplicationController ...@@ -49,4 +53,15 @@ class Projects::BranchesController < Projects::ApplicationController
format.js { render status: status[:return_code] } format.js { render status: status[:return_code] }
end end
end end
private
def ref
if params[:ref]
ref_escaped = sanitize(strip_tags(params[:ref]))
Addressable::URI.unescape(ref_escaped)
else
@project.default_branch
end
end
end end
...@@ -5,7 +5,7 @@ class Projects::IssuesController < Projects::ApplicationController ...@@ -5,7 +5,7 @@ class Projects::IssuesController < Projects::ApplicationController
before_action :issue, only: [:edit, :update, :show] before_action :issue, only: [:edit, :update, :show]
# Allow read any issue # Allow read any issue
before_action :authorize_read_issue! before_action :authorize_read_issue!, only: [:show]
# Allow write(create) issue # Allow write(create) issue
before_action :authorize_create_issue!, only: [:new, :create] before_action :authorize_create_issue!, only: [:new, :create]
...@@ -65,6 +65,7 @@ class Projects::IssuesController < Projects::ApplicationController ...@@ -65,6 +65,7 @@ class Projects::IssuesController < Projects::ApplicationController
@notes = @issue.notes.nonawards.with_associations.fresh @notes = @issue.notes.nonawards.with_associations.fresh
@noteable = @issue @noteable = @issue
@merge_requests = @issue.referenced_merge_requests(current_user) @merge_requests = @issue.referenced_merge_requests(current_user)
@related_branches = @issue.related_branches - @merge_requests.map(&:source_branch)
respond_with(@issue) respond_with(@issue)
end end
...@@ -127,6 +128,10 @@ class Projects::IssuesController < Projects::ApplicationController ...@@ -127,6 +128,10 @@ class Projects::IssuesController < Projects::ApplicationController
end end
alias_method :subscribable_resource, :issue alias_method :subscribable_resource, :issue
def authorize_read_issue!
return render_404 unless can?(current_user, :read_issue, @issue)
end
def authorize_update_issue! def authorize_update_issue!
return render_404 unless can?(current_user, :update_issue, @issue) return render_404 unless can?(current_user, :update_issue, @issue)
end end
...@@ -157,7 +162,7 @@ class Projects::IssuesController < Projects::ApplicationController ...@@ -157,7 +162,7 @@ class Projects::IssuesController < Projects::ApplicationController
def issue_params def issue_params
params.require(:issue).permit( params.require(:issue).permit(
:title, :assignee_id, :position, :description, :title, :assignee_id, :position, :description, :confidential,
:milestone_id, :state_event, :task_num, label_ids: [] :milestone_id, :state_event, :task_num, label_ids: []
) )
end end
......
...@@ -12,6 +12,13 @@ class Projects::LabelsController < Projects::ApplicationController ...@@ -12,6 +12,13 @@ class Projects::LabelsController < Projects::ApplicationController
def index def index
@labels = @project.labels.page(params[:page]).per(PER_PAGE) @labels = @project.labels.page(params[:page]).per(PER_PAGE)
respond_to do |format|
format.html
format.json do
render json: @project.labels
end
end
end end
def new def new
......
...@@ -5,7 +5,7 @@ class Projects::MergeRequestsController < Projects::ApplicationController ...@@ -5,7 +5,7 @@ class Projects::MergeRequestsController < Projects::ApplicationController
before_action :module_enabled before_action :module_enabled
before_action :merge_request, only: [ before_action :merge_request, only: [
:edit, :update, :show, :diffs, :commits, :builds, :merge, :merge_check, :edit, :update, :show, :diffs, :commits, :builds, :merge, :merge_check,
:ci_status, :cancel_merge_when_build_succeeds :ci_status, :toggle_subscription, :cancel_merge_when_build_succeeds, :remove_wip
] ]
before_action :closes_issues, only: [:edit, :update, :show, :diffs, :commits, :builds] before_action :closes_issues, only: [:edit, :update, :show, :diffs, :commits, :builds]
before_action :validates_merge_request, only: [:show, :diffs, :commits, :builds] before_action :validates_merge_request, only: [:show, :diffs, :commits, :builds]
...@@ -20,7 +20,7 @@ class Projects::MergeRequestsController < Projects::ApplicationController ...@@ -20,7 +20,7 @@ class Projects::MergeRequestsController < Projects::ApplicationController
before_action :authorize_create_merge_request!, only: [:new, :create] before_action :authorize_create_merge_request!, only: [:new, :create]
# Allow modify merge_request # Allow modify merge_request
before_action :authorize_update_merge_request!, only: [:close, :edit, :update, :sort] before_action :authorize_update_merge_request!, only: [:close, :edit, :update, :remove_wip, :sort]
def index def index
terms = params['issue_search'] terms = params['issue_search']
...@@ -164,6 +164,13 @@ class Projects::MergeRequestsController < Projects::ApplicationController ...@@ -164,6 +164,13 @@ class Projects::MergeRequestsController < Projects::ApplicationController
end end
end end
def remove_wip
MergeRequests::UpdateService.new(project, current_user, title: @merge_request.wipless_title).execute(@merge_request)
redirect_to namespace_project_merge_request_path(@project.namespace, @project, @merge_request),
notice: "The merge request can now be merged."
end
def merge_check def merge_check
@merge_request.check_if_can_be_merged @merge_request.check_if_can_be_merged
......
...@@ -19,8 +19,16 @@ class Projects::MilestonesController < Projects::ApplicationController ...@@ -19,8 +19,16 @@ class Projects::MilestonesController < Projects::ApplicationController
end end
@milestones = @milestones.includes(:project) @milestones = @milestones.includes(:project)
respond_to do |format|
format.html do
@milestones = @milestones.page(params[:page]).per(PER_PAGE) @milestones = @milestones.page(params[:page]).per(PER_PAGE)
end end
format.json do
render json: @milestones
end
end
end
def new def new
@milestone = @project.milestones.new @milestone = @project.milestones.new
......
...@@ -134,7 +134,7 @@ class ProjectsController < ApplicationController ...@@ -134,7 +134,7 @@ class ProjectsController < ApplicationController
def autocomplete_sources def autocomplete_sources
note_type = params['type'] note_type = params['type']
note_id = params['type_id'] note_id = params['type_id']
autocomplete = ::Projects::AutocompleteService.new(@project) autocomplete = ::Projects::AutocompleteService.new(@project, current_user)
participants = ::Projects::ParticipantsService.new(@project, current_user).execute(note_type, note_id) participants = ::Projects::ParticipantsService.new(@project, current_user).execute(note_type, note_id)
@suggestions = { @suggestions = {
......
...@@ -19,4 +19,10 @@ class IssuesFinder < IssuableFinder ...@@ -19,4 +19,10 @@ class IssuesFinder < IssuableFinder
def klass def klass
Issue Issue
end end
private
def init_collection
Issue.visible_to_user(current_user)
end
end end
...@@ -182,7 +182,7 @@ module ApplicationHelper ...@@ -182,7 +182,7 @@ module ApplicationHelper
# Returns an HTML-safe String # Returns an HTML-safe String
def time_ago_with_tooltip(time, placement: 'top', html_class: 'time_ago', skip_js: false) def time_ago_with_tooltip(time, placement: 'top', html_class: 'time_ago', skip_js: false)
element = content_tag :time, time.to_s, element = content_tag :time, time.to_s,
class: "#{html_class} js-timeago js-timeago-pending", class: "#{html_class} js-timeago #{"js-timeago-pending" unless skip_js}",
datetime: time.to_time.getutc.iso8601, datetime: time.to_time.getutc.iso8601,
title: time.in_time_zone.to_s(:medium), title: time.in_time_zone.to_s(:medium),
data: { toggle: 'tooltip', placement: placement, container: 'body' } data: { toggle: 'tooltip', placement: placement, container: 'body' }
...@@ -196,6 +196,22 @@ module ApplicationHelper ...@@ -196,6 +196,22 @@ module ApplicationHelper
element element
end end
def edited_time_ago_with_tooltip(object, placement: 'top', html_class: 'time_ago', include_author: false)
return if object.updated_at == object.created_at
content_tag :small, class: "edited-text" do
output = content_tag(:span, "Edited ")
output << time_ago_with_tooltip(object.updated_at, placement: placement, html_class: html_class)
if include_author && object.updated_by && object.updated_by != object.author
output << content_tag(:span, " by ")
output << link_to_member(object.project, object.updated_by, avatar: false, author_class: nil)
end
output
end
end
def render_markup(file_name, file_content) def render_markup(file_name, file_content)
if gitlab_markdown?(file_name) if gitlab_markdown?(file_name)
Haml::Helpers.preserve(markdown(file_content)) Haml::Helpers.preserve(markdown(file_content))
...@@ -285,7 +301,7 @@ module ApplicationHelper ...@@ -285,7 +301,7 @@ module ApplicationHelper
if project.nil? if project.nil?
nil nil
elsif current_controller?(:issues) elsif current_controller?(:issues)
project.issues.send(entity).count project.issues.visible_to_user(current_user).send(entity).count
elsif current_controller?(:merge_requests) elsif current_controller?(:merge_requests)
project.merge_requests.send(entity).count project.merge_requests.send(entity).count
end end
......
...@@ -24,7 +24,7 @@ module DropdownsHelper ...@@ -24,7 +24,7 @@ module DropdownsHelper
capture(&block) if block && !options.has_key?(:footer_content) capture(&block) if block && !options.has_key?(:footer_content)
end end
if block && options.has_key?(:footer_content) if block && options[:footer_content]
output << content_tag(:div, class: "dropdown-footer") do output << content_tag(:div, class: "dropdown-footer") do
capture(&block) capture(&block)
end end
......
...@@ -194,7 +194,7 @@ module EventsHelper ...@@ -194,7 +194,7 @@ module EventsHelper
end end
def event_to_atom(xml, event) def event_to_atom(xml, event)
if event.proper? if event.proper?(current_user)
xml.entry do xml.entry do
event_link = event_feed_url(event) event_link = event_feed_url(event)
event_title = event_feed_title(event) event_title = event_feed_title(event)
......
...@@ -20,6 +20,23 @@ module IssuablesHelper ...@@ -20,6 +20,23 @@ module IssuablesHelper
base_issuable_scope(issuable).where('iid < ?', issuable.iid).first base_issuable_scope(issuable).where('iid < ?', issuable.iid).first
end end
def user_dropdown_label(user_id, default_label)
return "Unassigned" if user_id == "0"
if @project
member = @project.team.find_member(user_id)
user = member.user if member
else
user = User.find_by(id: user_id)
end
if user
user.name
else
default_label
end
end
private private
def sidebar_gutter_collapsed? def sidebar_gutter_collapsed?
......
...@@ -98,6 +98,10 @@ module IssuesHelper ...@@ -98,6 +98,10 @@ module IssuesHelper
end.sort.to_sentence(last_word_connector: ', or ') end.sort.to_sentence(last_word_connector: ', or ')
end end
def confidential_icon(issue)
icon('eye-slash') if issue.confidential?
end
def emoji_icon(name, unicode = nil, aliases = []) def emoji_icon(name, unicode = nil, aliases = [])
unicode ||= Emoji.emoji_filename(name) rescue "" unicode ||= Emoji.emoji_filename(name) rescue ""
......
...@@ -32,7 +32,7 @@ module LabelsHelper ...@@ -32,7 +32,7 @@ module LabelsHelper
# link_to_label(label) { "My Custom Label Text" } # link_to_label(label) { "My Custom Label Text" }
# #
# Returns a String # Returns a String
def link_to_label(label, project: nil, type: :issue, &block) def link_to_label(label, project: nil, type: :issue, tooltip: true, &block)
project ||= @project || label.project project ||= @project || label.project
link = send("namespace_project_#{type.to_s.pluralize}_path", link = send("namespace_project_#{type.to_s.pluralize}_path",
project.namespace, project.namespace,
...@@ -42,7 +42,7 @@ module LabelsHelper ...@@ -42,7 +42,7 @@ module LabelsHelper
if block_given? if block_given?
link_to link, &block link_to link, &block
else else
link_to render_colored_label(label), link link_to render_colored_label(label, tooltip: tooltip), link
end end
end end
...@@ -50,23 +50,24 @@ module LabelsHelper ...@@ -50,23 +50,24 @@ module LabelsHelper
@project.labels.pluck(:title) @project.labels.pluck(:title)
end end
def render_colored_label(label, label_suffix = '') def render_colored_label(label, label_suffix = '', tooltip: true)
label_color = label.color || Label::DEFAULT_COLOR label_color = label.color || Label::DEFAULT_COLOR
text_color = text_color_for_bg(label_color) text_color = text_color_for_bg(label_color)
# Intentionally not using content_tag here so that this method can be called # Intentionally not using content_tag here so that this method can be called
# by LabelReferenceFilter # by LabelReferenceFilter
span = %(<span class="label color-label") + span = %(<span class="label color-label #{"has_tooltip" if tooltip}" ) +
%(style="background-color: #{label_color}; color: #{text_color}">) + %(style="background-color: #{label_color}; color: #{text_color}" ) +
%(title="#{escape_once(label.description)}" data-container="body">) +
%(#{escape_once(label.name)}#{label_suffix}</span>) %(#{escape_once(label.name)}#{label_suffix}</span>)
span.html_safe span.html_safe
end end
def render_colored_cross_project_label(label) def render_colored_cross_project_label(label, tooltip: true)
label_suffix = label.project.name_with_namespace label_suffix = label.project.name_with_namespace
label_suffix = " <i>in #{escape_once(label_suffix)}</i>" label_suffix = " <i>in #{escape_once(label_suffix)}</i>"
render_colored_label(label, label_suffix) render_colored_label(label, label_suffix, tooltip: tooltip)
end end
def suggested_colors def suggested_colors
...@@ -109,19 +110,12 @@ module LabelsHelper ...@@ -109,19 +110,12 @@ module LabelsHelper
end end
end end
def projects_labels_options def labels_filter_path
labels =
if @project if @project
@project.labels namespace_project_labels_path(@project.namespace, @project, :json)
else else
Label.where(project_id: @projects) labels_dashboard_path(:json)
end end
grouped_labels = GlobalLabel.build_collection(labels)
grouped_labels.unshift(Label::None)
grouped_labels.unshift(Label::Any)
options_from_collection_for_select(grouped_labels, 'name', 'title', params[:label_name])
end end
def label_subscription_status(label) def label_subscription_status(label)
......
...@@ -38,7 +38,7 @@ module MilestonesHelper ...@@ -38,7 +38,7 @@ module MilestonesHelper
def milestone_progress_bar(milestone) def milestone_progress_bar(milestone)
options = { options = {
class: 'progress-bar progress-bar-success', class: 'progress-bar progress-bar-success',
style: "width: #{milestone.percent_complete}%;" style: "width: #{milestone.percent_complete(current_user)}%;"
} }
content_tag :div, class: 'progress' do content_tag :div, class: 'progress' do
...@@ -46,22 +46,12 @@ module MilestonesHelper ...@@ -46,22 +46,12 @@ module MilestonesHelper
end end
end end
def projects_milestones_options def milestones_filter_dropdown_path
milestones =
if @project if @project
@project.milestones namespace_project_milestones_path(@project.namespace, @project, :json)
else else
Milestone.where(project_id: @projects) milestones_dashboard_path(:json)
end.active end
epoch = DateTime.parse('1970-01-01')
grouped_milestones = GlobalMilestone.build_collection(milestones)
grouped_milestones = grouped_milestones.sort_by { |x| x.due_date.nil? ? epoch : x.due_date }
grouped_milestones.unshift(Milestone::None)
grouped_milestones.unshift(Milestone::Any)
grouped_milestones.unshift(Milestone::Upcoming)
options_from_collection_for_select(grouped_milestones, 'name', 'title', params[:milestone_title])
end end
def milestone_remaining_days(milestone) def milestone_remaining_days(milestone)
......
...@@ -26,7 +26,7 @@ module ProjectsHelper ...@@ -26,7 +26,7 @@ module ProjectsHelper
image_tag(avatar_icon(author, opts[:size]), width: opts[:size], class: "avatar avatar-inline #{"s#{opts[:size]}" if opts[:size]}", alt:'') if opts[:avatar] image_tag(avatar_icon(author, opts[:size]), width: opts[:size], class: "avatar avatar-inline #{"s#{opts[:size]}" if opts[:size]}", alt:'') if opts[:avatar]
end end
def link_to_member(project, author, opts = {}) def link_to_member(project, author, opts = {}, &block)
default_opts = { avatar: true, name: true, size: 16, author_class: 'author', title: ":name" } default_opts = { avatar: true, name: true, size: 16, author_class: 'author', title: ":name" }
opts = default_opts.merge(opts) opts = default_opts.merge(opts)
...@@ -44,6 +44,8 @@ module ProjectsHelper ...@@ -44,6 +44,8 @@ module ProjectsHelper
author_html << content_tag(:span, sanitize(author.name), class: opts[:author_class]) if opts[:name] author_html << content_tag(:span, sanitize(author.name), class: opts[:author_class]) if opts[:name]
end end
author_html << capture(&block) if block
author_html = author_html.html_safe author_html = author_html.html_safe
if opts[:name] if opts[:name]
......
...@@ -16,15 +16,20 @@ module TodosHelper ...@@ -16,15 +16,20 @@ module TodosHelper
def todo_target_link(todo) def todo_target_link(todo)
target = todo.target_type.titleize.downcase target = todo.target_type.titleize.downcase
link_to "#{target} #{todo.target.to_reference}", todo_target_path(todo), { title: h(todo.target.title) } link_to "#{target} #{todo.target_reference}", todo_target_path(todo), { title: todo.target.title }
end end
def todo_target_path(todo) def todo_target_path(todo)
anchor = dom_id(todo.note) if todo.note.present? anchor = dom_id(todo.note) if todo.note.present?
if todo.for_commit?
namespace_project_commit_path(todo.project.namespace.becomes(Namespace), todo.project,
todo.target, anchor: anchor)
else
polymorphic_path([todo.project.namespace.becomes(Namespace), polymorphic_path([todo.project.namespace.becomes(Namespace),
todo.project, todo.target], anchor: anchor) todo.project, todo.target], anchor: anchor)
end end
end
def todos_filter_params def todos_filter_params
{ {
......
...@@ -49,7 +49,6 @@ class Ability ...@@ -49,7 +49,6 @@ class Ability
rules = [ rules = [
:read_project, :read_project,
:read_wiki, :read_wiki,
:read_issue,
:read_label, :read_label,
:read_milestone, :read_milestone,
:read_project_snippet, :read_project_snippet,
...@@ -63,6 +62,9 @@ class Ability ...@@ -63,6 +62,9 @@ class Ability
# Allow to read builds by anonymous user if guests are allowed # Allow to read builds by anonymous user if guests are allowed
rules << :read_build if project.public_builds? rules << :read_build if project.public_builds?
# Allow to read issues by anonymous user if issue is not confidential
rules << :read_issue unless subject.is_a?(Issue) && subject.confidential?
rules - project_disabled_features_rules(project) rules - project_disabled_features_rules(project)
else else
[] []
...@@ -325,6 +327,7 @@ class Ability ...@@ -325,6 +327,7 @@ class Ability
end end
rules += project_abilities(user, subject.project) rules += project_abilities(user, subject.project)
rules = filter_confidential_issues_abilities(user, subject, rules) if subject.is_a?(Issue)
rules rules
end end
end end
...@@ -443,5 +446,17 @@ class Ability ...@@ -443,5 +446,17 @@ class Ability
:"admin_#{name}" :"admin_#{name}"
] ]
end end
def filter_confidential_issues_abilities(user, issue, rules)
return rules if user.admin? || !issue.confidential?
unless issue.author == user || issue.assignee == user || issue.project.team.member?(user.id)
rules.delete(:admin_issue)
rules.delete(:read_issue)
rules.delete(:update_issue)
end
rules
end
end end
end end
...@@ -19,9 +19,9 @@ class AbuseReport < ActiveRecord::Base ...@@ -19,9 +19,9 @@ class AbuseReport < ActiveRecord::Base
validates :message, presence: true validates :message, presence: true
validates :user_id, uniqueness: { message: 'has already been reported' } validates :user_id, uniqueness: { message: 'has already been reported' }
def remove_user def remove_user(deleted_by:)
user.block user.block
user.destroy DeleteUserWorker.perform_async(deleted_by.id, user.id, delete_solo_owned_groups: true)
end end
def notify def notify
......
...@@ -114,7 +114,7 @@ class CommitStatus < ActiveRecord::Base ...@@ -114,7 +114,7 @@ class CommitStatus < ActiveRecord::Base
end end
def ignored? def ignored?
failed? && allow_failure? allow_failure? && (failed? || canceled?)
end end
def duration def duration
......
module Milestoneish module Milestoneish
def closed_items_count def closed_items_count(user = nil)
issues.closed.size + merge_requests.closed_and_merged.size issues_visible_to_user(user).closed.size + merge_requests.closed_and_merged.size
end end
def total_items_count def total_items_count(user = nil)
issues.size + merge_requests.size issues_visible_to_user(user).size + merge_requests.size
end end
def complete? def complete?(user = nil)
total_items_count == closed_items_count total_items_count(user) == closed_items_count(user)
end end
def percent_complete def percent_complete(user = nil)
((closed_items_count * 100) / total_items_count).abs ((closed_items_count(user) * 100) / total_items_count(user)).abs
rescue ZeroDivisionError rescue ZeroDivisionError
0 0
end end
...@@ -22,4 +22,8 @@ module Milestoneish ...@@ -22,4 +22,8 @@ module Milestoneish
(due_date - Date.today).to_i (due_date - Date.today).to_i
end end
def issues_visible_to_user(user = nil)
issues.visible_to_user(user)
end
end end
...@@ -73,15 +73,17 @@ class Event < ActiveRecord::Base ...@@ -73,15 +73,17 @@ class Event < ActiveRecord::Base
end end
end end
def proper? def proper?(user = nil)
if push? if push?
true true
elsif membership_changed? elsif membership_changed?
true true
elsif created_project? elsif created_project?
true true
elsif issue?
Ability.abilities.allowed?(user, :read_issue, issue)
else else
((issue? || merge_request? || note?) && target) || milestone? ((merge_request? || note?) && target) || milestone?
end end
end end
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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