Skip to content

Commit 8a0aaba

Browse files
author
GitLab Bot
committed
Add latest changes from gitlab-org/gitlab@master
1 parent 96ddec9 commit 8a0aaba

File tree

61 files changed

+942
-821
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+942
-821
lines changed

.gitlab/ci/frontend.gitlab-ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
- .default-retry
1212
- .default-before_script
1313
- .assets-compile-cache
14-
image: ${REGISTRY_HOST}/${REGISTRY_GROUP}/gitlab-build-images/${BUILD_OS}-${OS_VERSION}-ruby-${RUBY_VERSION}-rust-${RUST_VERSION}-node-${NODE_VERSION}:rubygems-${RUBYGEMS_VERSION}-git-${GIT_VERSION}-lfs-${LFS_VERSION}-yarn-${YARN_VERSION}-graphicsmagick-${GRAPHICSMAGICK_VERSION}
14+
image: ${REGISTRY_HOST}/${REGISTRY_GROUP}/gitlab-build-images/ci/${BUILD_OS}-${OS_VERSION}-slim-ruby-${RUBY_VERSION}-node-${NODE_VERSION}:rubygems-${RUBYGEMS_VERSION}-git-${GIT_VERSION}-lfs-${LFS_VERSION}-yarn-${YARN_VERSION}-graphicsmagick-${GRAPHICSMAGICK_VERSION}
1515
variables:
1616
SETUP_DB: "false"
1717
WEBPACK_VENDOR_DLL: "true"
@@ -30,7 +30,7 @@
3030
- yarn patch-package --reverse # To avoid caching patched modules
3131

3232
compile-production-assets:
33-
image: ${REGISTRY_HOST}/${REGISTRY_GROUP}/gitlab-build-images/${BUILD_OS}-${OS_VERSION}-ruby-${RUBY_VERSION}-rust-${RUST_VERSION}-node-${NODE_VERSION}:rubygems-${RUBYGEMS_VERSION}-git-${GIT_VERSION}-lfs-${LFS_VERSION}-yarn-${YARN_VERSION}-graphicsmagick-${GRAPHICSMAGICK_VERSION}-docker-${DOCKER_VERSION}
33+
image: ${REGISTRY_HOST}/${REGISTRY_GROUP}/gitlab-build-images/ci/${BUILD_OS}-${OS_VERSION}-slim-ruby-${RUBY_VERSION}-node-${NODE_VERSION}:rubygems-${RUBYGEMS_VERSION}-git-${GIT_VERSION}-lfs-${LFS_VERSION}-yarn-${YARN_VERSION}-graphicsmagick-${GRAPHICSMAGICK_VERSION}-docker-${DOCKER_VERSION}
3434
extends:
3535
- .use-buildx
3636
- .compile-assets-base

.gitlab/ci/version.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ variables:
44
DOCKER_VERSION: "27.4.1"
55
EXIFTOOL_VERSION: "12.60"
66
GCLOUD_VERSION: "413"
7-
GIT_VERSION: "2.45"
7+
GIT_VERSION: "2.49"
88
GO_VERSION: "1.23"
99
GRAPHICSMAGICK_VERSION: "1.3.36"
1010
HELM_VERSION: "3.16"

app/assets/javascripts/packages_and_registries/container_registry/explorer/components/details_page/tags_list_row.vue

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ import ClipboardButton from '~/vue_shared/components/clipboard_button.vue';
1616
import DetailsRow from '~/vue_shared/components/registry/details_row.vue';
1717
import ListItem from '~/vue_shared/components/registry/list_item.vue';
1818
import TimeAgoTooltip from '~/vue_shared/components/time_ago_tooltip.vue';
19-
import glFeatureFlagsMixin from '~/vue_shared/mixins/gl_feature_flags_mixin';
2019
import {
2120
REMOVE_TAG_BUTTON_TITLE,
2221
DIGEST_LABEL,
@@ -55,7 +54,6 @@ export default {
5554
directives: {
5655
GlTooltip: GlTooltipDirective,
5756
},
58-
mixins: [glFeatureFlagsMixin()],
5957
props: {
6058
tag: {
6159
type: Object,
@@ -164,9 +162,8 @@ export default {
164162
},
165163
isProtected() {
166164
return (
167-
(this.tag.protection?.minimumAccessLevelForDelete != null ||
168-
this.tag.protection?.minimumAccessLevelForPush != null) &&
169-
this.glFeatures.containerRegistryProtectedTags
165+
this.tag.protection?.minimumAccessLevelForDelete != null ||
166+
this.tag.protection?.minimumAccessLevelForPush != null
170167
);
171168
},
172169
tagRowId() {

app/assets/javascripts/packages_and_registries/settings/project/components/container_registry_section.vue

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
<script>
22
import { GlLink, GlSprintf } from '@gitlab/ui';
3-
import glFeatureFlagsMixin from '~/vue_shared/mixins/gl_feature_flags_mixin';
43
import { helpPagePath } from '~/helpers/help_page_helper';
54
import SettingsBlock from '~/vue_shared/components/settings/settings_block.vue';
65
import ContainerExpirationPolicy from '~/packages_and_registries/settings/project/components/container_expiration_policy.vue';
@@ -16,7 +15,6 @@ export default {
1615
ContainerProtectionTagRules,
1716
SettingsBlock,
1817
},
19-
mixins: [glFeatureFlagsMixin()],
2018
inject: ['isContainerRegistryMetadataDatabaseEnabled'],
2119
props: {
2220
expanded: {
@@ -27,10 +25,7 @@ export default {
2725
},
2826
computed: {
2927
showContainerProtectedTagsSettings() {
30-
return (
31-
this.glFeatures.containerRegistryProtectedTags &&
32-
this.isContainerRegistryMetadataDatabaseEnabled
33-
);
28+
return this.isContainerRegistryMetadataDatabaseEnabled;
3429
},
3530
},
3631
containerRegistryHelpPath: helpPagePath('user/packages/container_registry/_index.md'),

app/components/rapid_diffs/app_component.html.haml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
- if @preload
1+
- if !@lazy
22
- helpers.add_page_startup_api_call @metadata_endpoint
33
- helpers.add_page_startup_api_call @diff_files_endpoint
44
- if @stream_url
@@ -23,14 +23,18 @@
2323
= helpers.gl_loading_icon(size: 'sm')
2424
.rd-app-content
2525
.rd-app-content-header{ data: { hidden_files_warning: true } }
26+
27+
- if empty_diff? && !@lazy
28+
= render RapidDiffs::EmptyStateComponent.new
29+
2630
.code{ class: helpers.user_color_scheme }
2731
%div{ data: { diffs_list: true } }
2832
= javascript_tag nonce: content_security_policy_nonce do
2933
:plain
3034
requestAnimationFrame(() => { window.performance.mark('rapid-diffs-first-diff-file-shown') })
3135
- if diffs_list?
3236
= diffs_list
33-
- else
37+
- elsif !empty_diff?
3438
= render RapidDiffs::DiffFileComponent.with_collection(@diffs_slice, parallel_view: @diff_view == :parallel)
3539
- if @stream_url
3640
#js-stream-container{ data: { diffs_stream_url: @stream_url } }

app/components/rapid_diffs/app_component.rb

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ def initialize(
1313
update_user_endpoint:,
1414
metadata_endpoint:,
1515
diff_files_endpoint:,
16-
preload: true
16+
lazy: false
1717
)
1818
@diffs_slice = diffs_slice
1919
@reload_stream_url = reload_stream_url
@@ -23,7 +23,11 @@ def initialize(
2323
@update_user_endpoint = update_user_endpoint
2424
@metadata_endpoint = metadata_endpoint
2525
@diff_files_endpoint = diff_files_endpoint
26-
@preload = preload
26+
@lazy = lazy
27+
end
28+
29+
def empty_diff?
30+
@diffs_slice.nil? || @diffs_slice.empty?
2731
end
2832

2933
def browser_visible?
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
.rd-app-empty-state.gl-mt-5.gl-text-center
2+
= render Pajamas::CardComponent.new(card_options: { class: "gl-bg-subtle" }) do |c|
3+
- c.with_body do
4+
= render Pajamas::EmptyStateComponent.new(svg_path: 'illustrations/empty-state/empty-commit-md.svg',
5+
title: message) do |c|
6+
7+
- c.with_description do
8+
-# TODO: Add secondary text
9+
-# TODO: Add call to action button
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# frozen_string_literal: true
2+
3+
module RapidDiffs
4+
class EmptyStateComponent < ViewComponent::Base
5+
def initialize(message: nil)
6+
@message = message || _('There are no changes')
7+
end
8+
9+
private
10+
11+
attr_reader :message
12+
end
13+
end

app/controllers/concerns/stream_diffs.rb

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,11 +57,19 @@ def view
5757
def stream_diff_files(options)
5858
return unless resource
5959

60+
diffs = resource.diffs_for_streaming(options)
61+
62+
if params.permit(:offset)[:offset].blank? && diffs.diff_files.empty?
63+
empty_state_component = ::RapidDiffs::EmptyStateComponent.new
64+
response.stream.write empty_state_component.render_in(view_context)
65+
return
66+
end
67+
6068
# NOTE: This is a temporary flag to test out the new diff_blobs
6169
if !!ActiveModel::Type::Boolean.new.cast(params.permit(:diff_blobs)[:diff_blobs])
6270
stream_diff_blobs(options)
6371
else
64-
resource.diffs_for_streaming(options).diff_files.each do |diff_file|
72+
diffs.diff_files.each do |diff_file|
6573
response.stream.write(render_diff_file(diff_file))
6674
end
6775
end

app/controllers/projects/registry/repositories_controller.rb

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,6 @@ class RepositoriesController < ::Projects::Registry::ApplicationController
1010
push_frontend_feature_flag(:show_container_registry_tag_signatures, project)
1111
end
1212

13-
before_action only: [:index, :show] do
14-
push_frontend_feature_flag(:container_registry_protected_tags, project)
15-
end
16-
1713
before_action :authorize_update_container_image!, only: [:destroy]
1814

1915
def index

0 commit comments

Comments
 (0)