diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-10-24 12:11:20 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-10-24 12:11:20 +0300 |
commit | a19e3ec8e8545d5a6b275bab3e5ea8b0cc707449 (patch) | |
tree | fe01e7e8080f0505f476bd420352d1bf79c8ef17 /app | |
parent | 3368cc98aff2a2261c5dea9887e626836864000a (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app')
-rw-r--r-- | app/assets/javascripts/persistent_user_callouts.js | 1 | ||||
-rw-r--r-- | app/graphql/types/mutation_type.rb | 28 | ||||
-rw-r--r-- | app/helpers/users/callouts_helper.rb | 15 | ||||
-rw-r--r-- | app/models/users/callout.rb | 2 | ||||
-rw-r--r-- | app/views/layouts/_page.html.haml | 1 | ||||
-rw-r--r-- | app/views/shared/_new_nav_announcement.html.haml | 33 |
6 files changed, 15 insertions, 65 deletions
diff --git a/app/assets/javascripts/persistent_user_callouts.js b/app/assets/javascripts/persistent_user_callouts.js index cea01852630..c03c00c06aa 100644 --- a/app/assets/javascripts/persistent_user_callouts.js +++ b/app/assets/javascripts/persistent_user_callouts.js @@ -23,7 +23,6 @@ const PERSISTENT_USER_CALLOUTS = [ '.js-geo-migrate-hashed-storage-callout', '.js-unlimited-members-during-trial-alert', '.js-branch-rules-info-callout', - '.js-new-navigation-callout', '.js-namespace-over-storage-users-combined-alert', ]; diff --git a/app/graphql/types/mutation_type.rb b/app/graphql/types/mutation_type.rb index a2d1841cc0e..9c292404aed 100644 --- a/app/graphql/types/mutation_type.rb +++ b/app/graphql/types/mutation_type.rb @@ -138,31 +138,31 @@ module Types mount_mutation Mutations::ContainerRepositories::DestroyTags mount_mutation Mutations::Ci::Catalog::Resources::Create, alpha: { milestone: '15.11' } mount_mutation Mutations::Ci::Catalog::Resources::Unpublish, alpha: { milestone: '16.6' } + mount_mutation Mutations::Ci::Job::Cancel + mount_mutation Mutations::Ci::Job::Play + mount_mutation Mutations::Ci::Job::Retry + mount_mutation Mutations::Ci::Job::ArtifactsDestroy + mount_mutation Mutations::Ci::Job::Unschedule + mount_mutation Mutations::Ci::JobTokenScope::AddProject + mount_mutation Mutations::Ci::JobArtifact::BulkDestroy, alpha: { milestone: '15.10' } + mount_mutation Mutations::Ci::JobArtifact::Destroy + mount_mutation Mutations::Ci::JobTokenScope::RemoveProject mount_mutation Mutations::Ci::Pipeline::Cancel mount_mutation Mutations::Ci::Pipeline::Destroy mount_mutation Mutations::Ci::Pipeline::Retry + mount_mutation Mutations::Ci::PipelineSchedule::Create mount_mutation Mutations::Ci::PipelineSchedule::Delete - mount_mutation Mutations::Ci::PipelineSchedule::TakeOwnership mount_mutation Mutations::Ci::PipelineSchedule::Play - mount_mutation Mutations::Ci::PipelineSchedule::Create + mount_mutation Mutations::Ci::PipelineSchedule::TakeOwnership mount_mutation Mutations::Ci::PipelineSchedule::Update mount_mutation Mutations::Ci::PipelineTrigger::Create, alpha: { milestone: '16.3' } - mount_mutation Mutations::Ci::PipelineTrigger::Update, alpha: { milestone: '16.3' } mount_mutation Mutations::Ci::PipelineTrigger::Delete, alpha: { milestone: '16.3' } + mount_mutation Mutations::Ci::PipelineTrigger::Update, alpha: { milestone: '16.3' } mount_mutation Mutations::Ci::ProjectCiCdSettingsUpdate - mount_mutation Mutations::Ci::Job::ArtifactsDestroy - mount_mutation Mutations::Ci::Job::Play - mount_mutation Mutations::Ci::Job::Retry - mount_mutation Mutations::Ci::Job::Cancel - mount_mutation Mutations::Ci::Job::Unschedule - mount_mutation Mutations::Ci::JobArtifact::Destroy - mount_mutation Mutations::Ci::JobArtifact::BulkDestroy, alpha: { milestone: '15.10' } - mount_mutation Mutations::Ci::JobTokenScope::AddProject - mount_mutation Mutations::Ci::JobTokenScope::RemoveProject + mount_mutation Mutations::Ci::Runner::BulkDelete, alpha: { milestone: '15.3' } mount_mutation Mutations::Ci::Runner::Create, alpha: { milestone: '15.10' } - mount_mutation Mutations::Ci::Runner::Update mount_mutation Mutations::Ci::Runner::Delete - mount_mutation Mutations::Ci::Runner::BulkDelete, alpha: { milestone: '15.3' } + mount_mutation Mutations::Ci::Runner::Update mount_mutation Mutations::Ci::RunnersRegistrationToken::Reset mount_mutation Mutations::Namespace::PackageSettings::Update mount_mutation Mutations::Groups::Update diff --git a/app/helpers/users/callouts_helper.rb b/app/helpers/users/callouts_helper.rb index 1b5d0b276a3..b94f477de5a 100644 --- a/app/helpers/users/callouts_helper.rb +++ b/app/helpers/users/callouts_helper.rb @@ -15,7 +15,6 @@ module Users REGISTRATION_ENABLED_CALLOUT_ALLOWED_CONTROLLER_PATHS = [/^root/, /^dashboard\S*/, /^admin\S*/].freeze WEB_HOOK_DISABLED = 'web_hook_disabled' BRANCH_RULES_INFO_CALLOUT = 'branch_rules_info_callout' - NEW_NAVIGATION_CALLOUT = 'new_navigation_callout' def show_gke_cluster_integration_callout?(project) active_nav_link?(controller: sidebar_operations_paths) && @@ -79,20 +78,6 @@ module Users !user_dismissed?(BRANCH_RULES_INFO_CALLOUT) end - def show_new_navigation_callout? - show_super_sidebar? && - !user_dismissed?(NEW_NAVIGATION_CALLOUT) && - # GitLab.com users created after the feature flag's full rollout (June 2nd 2023) don't need to see the callout. - # Remove the gitlab_com_user_created_after_new_nav_rollout? method when the callout isn't needed anymore. - !gitlab_com_user_created_after_new_nav_rollout? - end - - def gitlab_com_user_created_after_new_nav_rollout? - return true unless current_user - - Gitlab.com? && current_user.created_at >= Date.new(2023, 6, 2) - end - private def user_dismissed?(feature_name, ignore_dismissal_earlier_than = nil, object: nil) diff --git a/app/models/users/callout.rb b/app/models/users/callout.rb index 60dd89c3ee7..b2f0fd01019 100644 --- a/app/models/users/callout.rb +++ b/app/models/users/callout.rb @@ -70,7 +70,7 @@ module Users project_repository_limit_alert_warning_threshold: 68, # EE-only project_repository_limit_alert_alert_threshold: 69, # EE-only project_repository_limit_alert_error_threshold: 70, # EE-only - new_navigation_callout: 71, + # 71 removed in https://gitlab.com/gitlab-org/gitlab/-/merge_requests/134432 # 72 removed in https://gitlab.com/gitlab-org/gitlab/-/merge_requests/129022 namespace_over_storage_users_combined_alert: 73, # EE-only # 74 removed in https://gitlab.com/gitlab-org/gitlab/-/merge_requests/132751 diff --git a/app/views/layouts/_page.html.haml b/app/views/layouts/_page.html.haml index f52ea801eef..c56678d730d 100644 --- a/app/views/layouts/_page.html.haml +++ b/app/views/layouts/_page.html.haml @@ -20,7 +20,6 @@ .mobile-overlay = dispensable_render_if_exists 'layouts/header/verification_reminder' .alert-wrapper.gl-force-block-formatting-context - = dispensable_render 'shared/new_nav_announcement' = dispensable_render 'shared/outdated_browser' = dispensable_render_if_exists "layouts/header/licensed_user_count_threshold" = dispensable_render_if_exists "layouts/header/token_expiry_notification" diff --git a/app/views/shared/_new_nav_announcement.html.haml b/app/views/shared/_new_nav_announcement.html.haml deleted file mode 100644 index 8cabab09ec2..00000000000 --- a/app/views/shared/_new_nav_announcement.html.haml +++ /dev/null @@ -1,33 +0,0 @@ -- return unless show_new_navigation_callout? - -- changes_url = 'https://gitlab.com/groups/gitlab-org/-/epics/9044#whats-different' -- vision_url = 'https://about.gitlab.com/blog/2023/05/01/gitlab-product-navigation/' -- design_url = 'https://about.gitlab.com/blog/2023/05/15/overhauling-the-navigation-is-like-building-a-dream-home/' -- feedback_url = 'https://gitlab.com/gitlab-org/gitlab/-/issues/409005' -- docs_url = help_page_path('tutorials/left_sidebar/index') - -- changes_link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: changes_url } -- vision_link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: vision_url } -- design_link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: design_url } -- link_end = '</a>'.html_safe - -- welcome_text = _('For the next few releases, you can go to your avatar at any time to turn the new navigation on and off.') -- cta_text = _('Read more about the %{changes_link_start}changes%{link_end}, the %{vision_link_start}vision%{link_end}, and the %{design_link_start}design%{link_end}.' % { changes_link_start: changes_link_start, - vision_link_start: vision_link_start, - design_link_start: design_link_start, - link_end: link_end}).html_safe # rubocop:disable Gettext/StaticIdentifier - -= render Pajamas::AlertComponent.new(dismissible: true, title: _('Welcome to a new navigation experience'), - alert_options: { class: 'js-new-navigation-callout', data: { feature_id: "new_navigation_callout", dismiss_endpoint: callouts_path }}) do |c| - - c.with_body do - %p - = welcome_text - = cta_text - - c.with_actions do - = render Pajamas::ButtonComponent.new(variant: :confirm, - href: docs_url, - button_options: { class: 'gl-alert-action', data: { track_action: 'click_button', track_label: 'banner_nav_learn_more' } }) do |c| - = _('Learn more') - = render Pajamas::ButtonComponent.new(href: feedback_url, - button_options: { data: { track_action: 'click_button', track_label: 'banner_nav_provide_feedback' } }) do |c| - = _('Provide feedback') |