...@@ -45,7 +45,6 @@ rules: ...@@ -45,7 +45,6 @@ rules:
vue/no-use-v-if-with-v-for: off vue/no-use-v-if-with-v-for: off
vue/no-v-html: off vue/no-v-html: off
vue/use-v-on-exact: off vue/use-v-on-exact: off
no-jquery/no-animate: off
# all offenses of no-jquery/no-animate-toggle are false positives ( $toast.show() ) # all offenses of no-jquery/no-animate-toggle are false positives ( $toast.show() )
no-jquery/no-animate-toggle: off no-jquery/no-animate-toggle: off
no-jquery/no-event-shorthand: off no-jquery/no-event-shorthand: off
... ...
......
...@@ -43,6 +43,7 @@ include: ...@@ -43,6 +43,7 @@ include:
- local: .gitlab/ci/rails.gitlab-ci.yml - local: .gitlab/ci/rails.gitlab-ci.yml
- local: .gitlab/ci/review.gitlab-ci.yml - local: .gitlab/ci/review.gitlab-ci.yml
- local: .gitlab/ci/setup.gitlab-ci.yml - local: .gitlab/ci/setup.gitlab-ci.yml
- local: .gitlab/ci/dev-fixtures.gitlab-ci.yml
- local: .gitlab/ci/test-metadata.gitlab-ci.yml - local: .gitlab/ci/test-metadata.gitlab-ci.yml
- local: .gitlab/ci/yaml.gitlab-ci.yml - local: .gitlab/ci/yaml.gitlab-ci.yml
- local: .gitlab/ci/releases.gitlab-ci.yml - local: .gitlab/ci/releases.gitlab-ci.yml
.run-dev-fixtures:
extends:
- .only-code-rails-job-base
- .use-pg9
stage: test
needs: ["setup-test-env"]
dependencies: ["setup-test-env"]
variables:
FIXTURE_PATH: "db/fixtures/development"
SEED_CYCLE_ANALYTICS: "true"
SEED_PRODUCTIVITY_ANALYTICS: "true"
CYCLE_ANALYTICS_ISSUE_COUNT: 1
SIZE: 0 # number of external projects to fork, requires network connection
# SEED_NESTED_GROUPS: "false" # requires network connection
run-dev-fixtures-foss:
extends: .run-dev-fixtures
script:
- scripts/gitaly-test-spawn
- RAILS_ENV=test bundle exec rake db:seed_fu
run-dev-fixtures-ee:
extends:
- .only-ee
- .use-pg9-ee
- .run-dev-fixtures
script:
- scripts/gitaly-test-spawn
- cp ee/db/fixtures/development/* $FIXTURE_PATH
- RAILS_ENV=test bundle exec rake db:seed_fu
...@@ -299,3 +299,76 @@ Graphql/Descriptions: ...@@ -299,3 +299,76 @@ Graphql/Descriptions:
RSpec/AnyInstanceOf: RSpec/AnyInstanceOf:
Enabled: false Enabled: false
# Cops for upgrade to gitlab-styles 3.1.0
FactoryBot/FactoryClassName:
Enabled: false
FactoryBot/CreateList:
Enabled: false
Rails/SafeNavigationWithBlank:
Enabled: false
Rails/ApplicationController:
Enabled: false
Rails/ApplicationMailer:
Enabled: false
Rails/RakeEnvironment:
Enabled: false
Rails/HelperInstanceVariable:
Enabled: false
Rails/EnumHash:
Enabled: false
RSpec/ReceiveCounts:
Enabled: false
RSpec/ContextMethod:
Enabled: false
RSpec/ImplicitSubject:
Enabled: false
RSpec/LeakyConstantDeclaration:
Enabled: false
RSpec/EmptyLineAfterHook:
Enabled: false
RSpec/HooksBeforeExamples:
Enabled: false
RSpec/EmptyLineAfterExample:
Enabled: false
RSpec/Be:
Enabled: false
RSpec/DescribedClass:
Enabled: false
RSpec/SharedExamples:
Enabled: false
RSpec/EmptyLineAfterExampleGroup:
Enabled: false
RSpec/ReceiveNever:
Enabled: false
RSpec/MissingExampleGroupArgument:
Enabled: false
RSpec/UnspecifiedException:
Enabled: false
Style/MultilineWhenThen:
Enabled: false
Style/FloatDivision:
Enabled: false
\ No newline at end of file
...@@ -366,11 +366,11 @@ group :development, :test do ...@@ -366,11 +366,11 @@ group :development, :test do
gem 'spring', '~> 2.0.0' gem 'spring', '~> 2.0.0'
gem 'spring-commands-rspec', '~> 1.0.4' gem 'spring-commands-rspec', '~> 1.0.4'
gem 'gitlab-styles', '~> 2.7', require: false gem 'gitlab-styles', '~> 3.1.0', require: false
# Pin these dependencies, otherwise a new rule could break the CI pipelines # Pin these dependencies, otherwise a new rule could break the CI pipelines
gem 'rubocop', '~> 0.69.0' gem 'rubocop', '~> 0.74.0'
gem 'rubocop-performance', '~> 1.1.0' gem 'rubocop-performance', '~> 1.4.1'
gem 'rubocop-rspec', '~> 1.22.1' gem 'rubocop-rspec', '~> 1.37.0'
gem 'scss_lint', '~> 0.56.0', require: false gem 'scss_lint', '~> 0.56.0', require: false
gem 'haml_lint', '~> 0.34.0', require: false gem 'haml_lint', '~> 0.34.0', require: false
... ...
......
...@@ -379,11 +379,12 @@ GEM ...@@ -379,11 +379,12 @@ GEM
gitlab-puma (>= 2.7, < 5) gitlab-puma (>= 2.7, < 5)
gitlab-sidekiq-fetcher (0.5.2) gitlab-sidekiq-fetcher (0.5.2)
sidekiq (~> 5) sidekiq (~> 5)
gitlab-styles (2.8.0) gitlab-styles (3.1.0)
rubocop (~> 0.69.0) rubocop (~> 0.74.0)
rubocop-gitlab-security (~> 0.1.0) rubocop-gitlab-security (~> 0.1.0)
rubocop-performance (~> 1.1.0) rubocop-performance (~> 1.4.1)
rubocop-rspec (~> 1.19) rubocop-rails (~> 2.0)
rubocop-rspec (~> 1.36)
gitlab_chronic_duration (0.10.6.2) gitlab_chronic_duration (0.10.6.2)
numerizer (~> 0.2) numerizer (~> 0.2)
gitlab_omniauth-ldap (2.1.1) gitlab_omniauth-ldap (2.1.1)
...@@ -519,7 +520,7 @@ GEM ...@@ -519,7 +520,7 @@ GEM
jaeger-client (0.10.0) jaeger-client (0.10.0)
opentracing (~> 0.3) opentracing (~> 0.3)
thrift thrift
jaro_winkler (1.5.3) jaro_winkler (1.5.4)
jira-ruby (1.7.1) jira-ruby (1.7.1)
activesupport activesupport
atlassian-jwt atlassian-jwt
...@@ -726,8 +727,8 @@ GEM ...@@ -726,8 +727,8 @@ GEM
rubypants (~> 0.2) rubypants (~> 0.2)
orm_adapter (0.5.0) orm_adapter (0.5.0)
os (1.0.0) os (1.0.0)
parallel (1.17.0) parallel (1.19.1)
parser (2.6.3.0) parser (2.6.5.0)
ast (~> 2.4.0) ast (~> 2.4.0)
parslet (1.8.2) parslet (1.8.2)
peek (1.1.0) peek (1.1.0)
...@@ -904,7 +905,7 @@ GEM ...@@ -904,7 +905,7 @@ GEM
pg pg
rails rails
sqlite3 sqlite3
rubocop (0.69.0) rubocop (0.74.0)
jaro_winkler (~> 1.5.1) jaro_winkler (~> 1.5.1)
parallel (~> 1.10) parallel (~> 1.10)
parser (>= 2.6) parser (>= 2.6)
...@@ -913,10 +914,13 @@ GEM ...@@ -913,10 +914,13 @@ GEM
unicode-display_width (>= 1.4.0, < 1.7) unicode-display_width (>= 1.4.0, < 1.7)
rubocop-gitlab-security (0.1.1) rubocop-gitlab-security (0.1.1)
rubocop (>= 0.51) rubocop (>= 0.51)
rubocop-performance (1.1.0) rubocop-performance (1.4.1)
rubocop (>= 0.67.0) rubocop (>= 0.71.0)
rubocop-rspec (1.22.2) rubocop-rails (2.4.0)
rubocop (>= 0.52.1) rack (>= 1.1)
rubocop (>= 0.72.0)
rubocop-rspec (1.37.0)
rubocop (>= 0.68.1)
ruby-enum (0.7.2) ruby-enum (0.7.2)
i18n i18n
ruby-fogbugz (0.2.1) ruby-fogbugz (0.2.1)
...@@ -1207,7 +1211,7 @@ DEPENDENCIES ...@@ -1207,7 +1211,7 @@ DEPENDENCIES
gitlab-puma (~> 4.3.1.gitlab.2) gitlab-puma (~> 4.3.1.gitlab.2)
gitlab-puma_worker_killer (~> 0.1.1.gitlab.1) gitlab-puma_worker_killer (~> 0.1.1.gitlab.1)
gitlab-sidekiq-fetcher (= 0.5.2) gitlab-sidekiq-fetcher (= 0.5.2)
gitlab-styles (~> 2.7) gitlab-styles (~> 3.1.0)
gitlab_chronic_duration (~> 0.10.6.2) gitlab_chronic_duration (~> 0.10.6.2)
gitlab_omniauth-ldap (~> 2.1.1) gitlab_omniauth-ldap (~> 2.1.1)
gon (~> 6.2) gon (~> 6.2)
...@@ -1318,9 +1322,9 @@ DEPENDENCIES ...@@ -1318,9 +1322,9 @@ DEPENDENCIES
rspec-set (~> 0.1.3) rspec-set (~> 0.1.3)
rspec_junit_formatter rspec_junit_formatter
rspec_profiling (~> 0.0.5) rspec_profiling (~> 0.0.5)
rubocop (~> 0.69.0) rubocop (~> 0.74.0)
rubocop-performance (~> 1.1.0) rubocop-performance (~> 1.4.1)
rubocop-rspec (~> 1.22.1) rubocop-rspec (~> 1.37.0)
ruby-fogbugz (~> 0.2.1) ruby-fogbugz (~> 0.2.1)
ruby-prof (~> 1.0.0) ruby-prof (~> 1.0.0)
ruby-progressbar ruby-progressbar
... ...
......
...@@ -506,6 +506,8 @@ export class AwardsHandler { ...@@ -506,6 +506,8 @@ export class AwardsHandler {
const options = { const options = {
scrollTop: $('.awards').offset().top - 110, scrollTop: $('.awards').offset().top - 110,
}; };
// eslint-disable-next-line no-jquery/no-animate
return $('body, html').animate(options, 200); return $('body, html').animate(options, 200);
} }
... ...
......
...@@ -290,6 +290,7 @@ export default { ...@@ -290,6 +290,7 @@ export default {
disabled && 'cluster-application-disabled', disabled && 'cluster-application-disabled',
]" ]"
class="cluster-application-row gl-responsive-table-row gl-responsive-table-row-col-span" class="cluster-application-row gl-responsive-table-row gl-responsive-table-row-col-span"
:data-qa-selector="id"
> >
<div class="gl-responsive-table-row-layout" role="row"> <div class="gl-responsive-table-row-layout" role="row">
<div class="table-section append-right-8 section-align-top" role="gridcell"> <div class="table-section append-right-8 section-align-top" role="gridcell">
...@@ -381,12 +382,16 @@ export default { ...@@ -381,12 +382,16 @@ export default {
:disabled="disabled || installButtonDisabled" :disabled="disabled || installButtonDisabled"
:label="installButtonLabel" :label="installButtonLabel"
class="js-cluster-application-install-button" class="js-cluster-application-install-button"
data-qa-selector="install_button"
:data-qa-application="id"
@click="installClicked" @click="installClicked"
/> />
<uninstall-application-button <uninstall-application-button
v-if="displayUninstallButton" v-if="displayUninstallButton"
v-gl-modal-directive="'uninstall-' + id" v-gl-modal-directive="'uninstall-' + id"
:status="status" :status="status"
data-qa-selector="uninstall_button"
:data-qa-application="id"
class="js-cluster-application-uninstall-button" class="js-cluster-application-uninstall-button"
/> />
<uninstall-application-confirmation-modal <uninstall-application-confirmation-modal
... ...
......
...@@ -135,7 +135,9 @@ export const handleLocationHash = () => { ...@@ -135,7 +135,9 @@ export const handleLocationHash = () => {
adjustment -= topPadding; adjustment -= topPadding;
} }
window.scrollBy(0, adjustment); setTimeout(() => {
window.scrollBy(0, adjustment);
});
}; };
// Check if element scrolled into viewport from above or below // Check if element scrolled into viewport from above or below
...@@ -247,6 +249,7 @@ export const scrollToElement = element => { ...@@ -247,6 +249,7 @@ export const scrollToElement = element => {
} }
const { top } = $el.offset(); const { top } = $el.offset();
// eslint-disable-next-line no-jquery/no-animate
return $('body, html').animate( return $('body, html').animate(
{ {
scrollTop: top - contentTop(), scrollTop: top - contentTop(),
... ...
......
...@@ -10,6 +10,6 @@ export default { ...@@ -10,6 +10,6 @@ export default {
</script> </script>
<template> <template>
<div class="prometheus-graph-header"> <div class="prometheus-graph-header">
<h5 class="prometheus-graph-title js-graph-title">{{ graphTitle }}</h5> <h5 ref="title" class="prometheus-graph-title">{{ graphTitle }}</h5>
</div> </div>
</template> </template>
...@@ -36,6 +36,8 @@ export default function adminInit() { ...@@ -36,6 +36,8 @@ export default function adminInit() {
$('.log-bottom').on('click', e => { $('.log-bottom').on('click', e => {
e.preventDefault(); e.preventDefault();
const $visibleLog = $('.file-content:visible'); const $visibleLog = $('.file-content:visible');
// eslint-disable-next-line no-jquery/no-animate
$visibleLog.animate( $visibleLog.animate(
{ {
scrollTop: $visibleLog.find('ol').height(), scrollTop: $visibleLog.find('ol').height(),
... ...
......
...@@ -207,6 +207,14 @@ ...@@ -207,6 +207,14 @@
border-left-color: mix($blame-gray, $blame-cyan, $i / 4 * 100%); border-left-color: mix($blame-gray, $blame-cyan, $i / 4 * 100%);
} }
} }
.doc-versions {
color: $gray-600;
&:hover {
color: $gray-900;
}
}
} }
&.logs { &.logs {
... ...
......
...@@ -133,6 +133,7 @@ ...@@ -133,6 +133,7 @@
.issue-count-badge { .issue-count-badge {
border: 0; border: 0;
white-space: nowrap; white-space: nowrap;
padding: 0;
} }
.board-title-text > span, .board-title-text > span,
... ...
......
# frozen_string_literal: true # frozen_string_literal: true
class Admin::SystemInfoController < Admin::ApplicationController class Admin::SystemInfoController < Admin::ApplicationController
EXCLUDED_MOUNT_OPTIONS = [ EXCLUDED_MOUNT_OPTIONS = %w[
'nobrowse', nobrowse
'read-only', read-only
'ro' ro
].freeze ].freeze
EXCLUDED_MOUNT_TYPES = [ EXCLUDED_MOUNT_TYPES = [
... ...
......
...@@ -31,7 +31,7 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController ...@@ -31,7 +31,7 @@ class OmniauthCallbacksController < Devise::OmniauthCallbacksController
# Extend the standard message generation to accept our custom exception # Extend the standard message generation to accept our custom exception
def failure_message def failure_message
exception = request.env["omniauth.error"] exception = request.env["omniauth.error"]
error = exception.error_reason if exception.respond_to?(:error_reason) error = exception.error_reason if exception.respond_to?(:error_reason)
error ||= exception.error if exception.respond_to?(:error) error ||= exception.error if exception.respond_to?(:error)
error ||= exception.message if exception.respond_to?(:message) error ||= exception.message if exception.respond_to?(:message)
error ||= request.env["omniauth.error.type"].to_s error ||= request.env["omniauth.error.type"].to_s
... ...
......
...@@ -34,7 +34,7 @@ class Projects::PagesController < Projects::ApplicationController ...@@ -34,7 +34,7 @@ class Projects::PagesController < Projects::ApplicationController
if result[:status] == :success if result[:status] == :success
flash[:notice] = 'Your changes have been saved' flash[:notice] = 'Your changes have been saved'
else else
flash[:alert] = 'Something went wrong on our end' flash[:alert] = result[:message]
end end
redirect_to project_pages_path(@project) redirect_to project_pages_path(@project)
...@@ -45,6 +45,12 @@ class Projects::PagesController < Projects::ApplicationController ...@@ -45,6 +45,12 @@ class Projects::PagesController < Projects::ApplicationController
private private
def project_params def project_params
params.require(:project).permit(:pages_https_only) params.require(:project).permit(project_params_attributes)
end
def project_params_attributes
%i[pages_https_only]
end end
end end
Projects::PagesController.prepend_if_ee('EE::Projects::PagesController')
...@@ -7,8 +7,8 @@ class Projects::StarrersController < Projects::ApplicationController ...@@ -7,8 +7,8 @@ class Projects::StarrersController < Projects::ApplicationController
@starrers = UsersStarProjectsFinder.new(@project, params, current_user: @current_user).execute @starrers = UsersStarProjectsFinder.new(@project, params, current_user: @current_user).execute
@sort = params[:sort].presence || sort_value_name @sort = params[:sort].presence || sort_value_name
@starrers = @starrers.preload_users.sort_by_attribute(@sort).page(params[:page]) @starrers = @starrers.preload_users.sort_by_attribute(@sort).page(params[:page])
@public_count = @project.starrers.with_public_profile.size @public_count = @project.starrers.with_public_profile.size
@total_count = @project.starrers.size @total_count = @project.starrers.size
@private_count = @total_count - @public_count @private_count = @total_count - @public_count
end end
... ...
......
...@@ -17,16 +17,16 @@ module Types ...@@ -17,16 +17,16 @@ module Types
field :sha, GraphQL::STRING_TYPE, null: false, field :sha, GraphQL::STRING_TYPE, null: false,
description: "SHA of the pipeline's commit" description: "SHA of the pipeline's commit"
field :before_sha, GraphQL::STRING_TYPE, null: true, field :before_sha, GraphQL::STRING_TYPE, null: true,
description: "Base SHA of the source branch" description: 'Base SHA of the source branch'
field :status, PipelineStatusEnum, null: false, field :status, PipelineStatusEnum, null: false,
description: "Status of the pipeline (#{::Ci::Pipeline.all_state_names.compact.join(', ').upcase})" description: "Status of the pipeline (#{::Ci::Pipeline.all_state_names.compact.join(', ').upcase})"
field :detailed_status, Types::Ci::DetailedStatusType, null: false, field :detailed_status, Types::Ci::DetailedStatusType, null: false,
description: 'Detailed status of the pipeline', description: 'Detailed status of the pipeline',
resolve: -> (obj, _args, ctx) { obj.detailed_status(ctx[:current_user]) } resolve: -> (obj, _args, ctx) { obj.detailed_status(ctx[:current_user]) }
field :duration, GraphQL::INT_TYPE, null: true, field :duration, GraphQL::INT_TYPE, null: true,
description: "Duration of the pipeline in seconds" description: 'Duration of the pipeline in seconds'
field :coverage, GraphQL::FLOAT_TYPE, null: true, field :coverage, GraphQL::FLOAT_TYPE, null: true,
description: "Coverage percentage" description: 'Coverage percentage'
field :created_at, Types::TimeType, null: false, field :created_at, Types::TimeType, null: false,
description: "Timestamp of the pipeline's creation" description: "Timestamp of the pipeline's creation"
field :updated_at, Types::TimeType, null: false, field :updated_at, Types::TimeType, null: false,
... ...
......
...@@ -3,19 +3,25 @@ ...@@ -3,19 +3,25 @@
module ContainerExpirationPoliciesHelper module ContainerExpirationPoliciesHelper
def cadence_options def cadence_options
ContainerExpirationPolicy.cadence_options.map do |key, val| ContainerExpirationPolicy.cadence_options.map do |key, val|
{ key: key.to_s, label: val } { key: key.to_s, label: val }.tap do |base|
base[:default] = true if key.to_s == '1d'
end
end end
end end
def keep_n_options def keep_n_options
ContainerExpirationPolicy.keep_n_options.map do |key, val| ContainerExpirationPolicy.keep_n_options.map do |key, val|
{ key: key, label: val } { key: key, label: val }.tap do |base|
base[:default] = true if key == 10
end
end end
end end
def older_than_options def older_than_options
ContainerExpirationPolicy.older_than_options.map do |key, val| ContainerExpirationPolicy.older_than_options.map do |key, val|
{ key: key.to_s, label: val } { key: key.to_s, label: val }.tap do |base|
base[:default] = true if key.to_s == '30d'
end
end end
end end
end end
...@@ -35,7 +35,7 @@ module DashboardHelper ...@@ -35,7 +35,7 @@ module DashboardHelper
tag.p(aria: { label: label }) do tag.p(aria: { label: label }) do
concat(link_or_title) concat(link_or_title)
concat(tag.span(class: ['light', 'float-right']) do concat(tag.span(class: %w[light float-right]) do
boolean_to_icon(enabled) boolean_to_icon(enabled)
end) end)
... ...
......