Add latest changes from gitlab-org/gitlab@master
This commit is contained in:
parent
c88b77efa6
commit
a909a157ab
|
|
@ -27,7 +27,7 @@ export default {
|
|||
<div v-gl-tooltip="tooltip" class="gl-display-inline-block gl-text-secondary gl-mb-3 gl-mr-4">
|
||||
<gl-icon v-if="icon" :name="icon" :size="12" />
|
||||
<!-- display tooltip as a label for screen readers and make it unavailable for copying -->
|
||||
<span class="gl-sr-only gl-user-select-none">{{ tooltip }}</span>
|
||||
<span class="gl-sr-only gl-select-none">{{ tooltip }}</span>
|
||||
<slot></slot>
|
||||
</div>
|
||||
</template>
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ export default {
|
|||
<!-- eslint-disable vue/require-v-for-key-->
|
||||
<pre
|
||||
class="gl-w-full"
|
||||
><span v-if="prompt" class="gl-user-select-none">{{ prompt }} </span><template v-for="line in lines">{{ line }}<br class="gl-user-select-none"/></template></pre>
|
||||
><span v-if="prompt" class="gl-select-none">{{ prompt }} </span><template v-for="line in lines">{{ line }}<br class="gl-select-none"/></template></pre>
|
||||
<!-- eslint-enable vue/require-v-for-key-->
|
||||
<clipboard-button :text="clipboard" :title="__('Copy')" />
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -110,7 +110,7 @@ export default {
|
|||
<gl-table-lite
|
||||
:items="customEmojis"
|
||||
:fields="$options.fields"
|
||||
table-class="gl-table-layout-fixed"
|
||||
table-class="gl-table-fixed"
|
||||
>
|
||||
<template #table-colgroup="scope">
|
||||
<col
|
||||
|
|
|
|||
|
|
@ -121,7 +121,7 @@ export default {
|
|||
<table
|
||||
:aria-label="tableCaption"
|
||||
class="table tree-table"
|
||||
:class="{ 'gl-table-layout-fixed': !showParentRow }"
|
||||
:class="{ 'gl-table-fixed': !showParentRow }"
|
||||
aria-live="polite"
|
||||
data-testid="file-tree-table"
|
||||
>
|
||||
|
|
|
|||
|
|
@ -158,13 +158,13 @@ export default {
|
|||
>
|
||||
<a
|
||||
v-if="showBlameLink"
|
||||
class="gl-user-select-none gl-shadow-none! file-line-blame gl-mx-n2"
|
||||
class="gl-select-none gl-shadow-none! file-line-blame gl-mx-n2"
|
||||
:href="`${blamePath}#L${line}`"
|
||||
></a>
|
||||
<a
|
||||
:id="`L${line}`"
|
||||
:key="line"
|
||||
class="gl-user-select-none gl-shadow-none! file-line-num"
|
||||
class="gl-select-none gl-shadow-none! file-line-num"
|
||||
:href="`#L${line}`"
|
||||
:data-line-number="line"
|
||||
@click="scrollToLine(`#LC${line}`)"
|
||||
|
|
|
|||
|
|
@ -38,12 +38,12 @@ export default {
|
|||
class="gl-p-0! gl-absolute gl-z-index-3 diff-line-num gl-border-r gl-display-flex line-links line-numbers"
|
||||
>
|
||||
<a
|
||||
class="gl-user-select-none gl-shadow-none! file-line-blame gl-mx-n2 gl-flex-grow-1"
|
||||
class="gl-select-none gl-shadow-none! file-line-blame gl-mx-n2 gl-flex-grow-1"
|
||||
:href="`${blamePath}${pageSearchString}#L${number}`"
|
||||
></a>
|
||||
<a
|
||||
:id="`L${number}`"
|
||||
class="gl-user-select-none gl-shadow-none! file-line-num"
|
||||
class="gl-select-none gl-shadow-none! file-line-num"
|
||||
:href="`#L${number}`"
|
||||
:data-line-number="number"
|
||||
>
|
||||
|
|
|
|||
|
|
@ -92,12 +92,12 @@ export default {
|
|||
class="gl-p-0! gl-z-index-3 diff-line-num gl-border-r gl-display-flex line-links line-numbers"
|
||||
>
|
||||
<a
|
||||
class="gl-user-select-none gl-shadow-none! file-line-blame"
|
||||
class="gl-select-none gl-shadow-none! file-line-blame"
|
||||
:href="`${blamePath}${pageSearchString}#L${calculateLineNumber(index)}`"
|
||||
></a>
|
||||
<a
|
||||
:id="`L${calculateLineNumber(index)}`"
|
||||
class="gl-user-select-none gl-shadow-none! file-line-num"
|
||||
class="gl-select-none gl-shadow-none! file-line-num"
|
||||
:href="`#L${calculateLineNumber(index)}`"
|
||||
:data-line-number="calculateLineNumber(index)"
|
||||
>
|
||||
|
|
|
|||
|
|
@ -1,15 +1,3 @@
|
|||
.account-well {
|
||||
padding: 10px;
|
||||
background-color: $gray-light;
|
||||
border: 1px solid $border-color;
|
||||
border-radius: $border-radius-base;
|
||||
|
||||
ul {
|
||||
padding-left: 20px;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.provider-btn-group {
|
||||
display: inline-block;
|
||||
margin-right: 10px;
|
||||
|
|
@ -48,20 +36,6 @@
|
|||
background-color: $gray-light;
|
||||
}
|
||||
|
||||
.oauth-applications {
|
||||
form {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.last-heading {
|
||||
width: 105px;
|
||||
}
|
||||
}
|
||||
|
||||
.codes {
|
||||
padding-top: 14px;
|
||||
}
|
||||
|
||||
.oauth-application-show {
|
||||
.scopes-list {
|
||||
padding-left: 18px;
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@
|
|||
%th= _('Trusted')
|
||||
%th= _('Confidential')
|
||||
%th= _('Actions')
|
||||
%tbody.oauth-applications
|
||||
%tbody{ data: { testid: "oauth-applications" } }
|
||||
- @applications.each do |application|
|
||||
%tr{ id: "application_#{application.id}" }
|
||||
%td{ data: { label: _('Name') } }= link_to application.name, admin_application_path(application)
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
.account-well.gl-mt-3.gl-mb-3
|
||||
%ul
|
||||
.gl-mt-3.gl-mb-3.gl-bg-gray-10.gl-border.gl-p-3.gl-rounded-base
|
||||
%ul.gl-pl-5.gl-mb-0
|
||||
%li
|
||||
= html_escape(_('The repository must be accessible over %{code_open}http://%{code_close},
|
||||
%{code_open}https://%{code_close}, %{code_open}ssh://%{code_close} or %{code_open}git://%{code_close}.')) % { code_open: '<code>'.html_safe, code_close: '</code>'.html_safe }
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
- show_cancel_button = local_assigns.fetch(:cancel, false)
|
||||
|
||||
= gitlab_ui_form_for @application, url: url, html: { role: 'form', class: 'doorkeeper-app-form gl-max-w-80' } do |f|
|
||||
= gitlab_ui_form_for @application, url: url, html: { role: 'form', class: 'doorkeeper-app-form gl-max-w-80 gl-display-inline-block' } do |f|
|
||||
= form_errors(@application)
|
||||
|
||||
.form-group
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@
|
|||
- else
|
||||
= _("Manage applications that you've authorized to use your account.")
|
||||
- if oauth_applications_enabled
|
||||
= render Pajamas::CardComponent.new(card_options: { class: 'gl-new-card oauth-applications js-toggle-container' }, header_options: { class: 'gl-new-card-header' }, body_options: { class: 'gl-new-card-body gl-px-0' }) do |c|
|
||||
= render Pajamas::CardComponent.new(card_options: { class: 'gl-new-card js-toggle-container', data: { testid: 'oauth-applications' }}, header_options: { class: 'gl-new-card-header' }, body_options: { class: 'gl-new-card-body gl-px-0' }) do |c|
|
||||
- c.with_header do
|
||||
.gl-new-card-title-wrapper
|
||||
%h3.gl-new-card-title
|
||||
|
|
@ -41,7 +41,7 @@
|
|||
%th= _('Name')
|
||||
%th= _('Callback URL')
|
||||
%th= _('Clients')
|
||||
%th.last-heading
|
||||
%th.gl-w-4
|
||||
%tbody
|
||||
- @applications.each do |application|
|
||||
%tr{ id: "application_#{application.id}" }
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ key_path: redis_hll_counters.work_items.users_updating_work_item_iteration_month
|
|||
description: Unique users updating a work item's iteration
|
||||
product_section: team planning
|
||||
product_stage: dev
|
||||
product_group: plan
|
||||
product_group: project_management
|
||||
value_type: number
|
||||
status: active
|
||||
milestone: "15.5"
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ key_path: redis_hll_counters.work_items.users_updating_work_item_iteration_weekl
|
|||
description: Unique users updating a work item's iteration
|
||||
product_section: team planning
|
||||
product_stage: dev
|
||||
product_group: plan
|
||||
product_group: project_management
|
||||
value_type: number
|
||||
status: active
|
||||
milestone: "15.5"
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ module.exports = {
|
|||
'./node_modules/@gitlab/ui/dist/**/*.{vue,js}',
|
||||
],
|
||||
presets: [tailwindDefaults],
|
||||
corePlugins: ['isolation'],
|
||||
corePlugins: ['appearance', 'content', 'isolation', 'mixBlendMode', 'tableLayout', 'userSelect'],
|
||||
blocklist: [
|
||||
// Prevents an irrelevant util from being generated.
|
||||
// In the long run, we'll look into disabling arbitrary values altogether, which should prevent
|
||||
|
|
|
|||
|
|
@ -16,10 +16,10 @@ The group relations export API partially exports a group's structure as separate
|
|||
top-level
|
||||
relation (for example, milestones, boards, and labels).
|
||||
|
||||
The group relations export API is primarily used in
|
||||
[group migration by direct transfer](../user/group/import/index.md)
|
||||
and
|
||||
can't be used with the [group import and export API](group_import_export.md).
|
||||
The group relations export API is primarily used in [group migration by direct transfer](../user/group/import/index.md)
|
||||
and your GitLab instance must meet [certain prerequisites](../user/group/import/index.md#prerequisites).
|
||||
|
||||
This API can't be used with the [group import and export API](group_import_export.md).
|
||||
|
||||
## Schedule new export
|
||||
|
||||
|
|
|
|||
|
|
@ -181,15 +181,15 @@ the instructions for
|
|||
|
||||
### Use security scanning tools with merge request pipelines
|
||||
|
||||
By default, the application security jobs are configured to run for branch pipelines only.
|
||||
To use them with [merge request pipelines](../../ci/pipelines/merge_request_pipelines.md),
|
||||
From GitLab 16.0 and later, all `stable` security templates support merge request pipelines.
|
||||
|
||||
From GitLab 15.11 and earlier, the application security jobs were configured to run for branch pipelines only.
|
||||
To use them with [merge request pipelines](../../ci/pipelines/merge_request_pipelines.md) on these versions,
|
||||
you must reference the [`latest` templates](../../development/cicd/templates.md).
|
||||
|
||||
The latest version of the template may include breaking changes. Use the stable template unless you
|
||||
need a feature provided only in the latest template.
|
||||
|
||||
All `latest` security templates support merge request pipelines.
|
||||
|
||||
For example, to run both SAST and Dependency Scanning, the following template is used:
|
||||
|
||||
```yaml
|
||||
|
|
|
|||
|
|
@ -18,15 +18,19 @@ module Gitlab
|
|||
objects[path_without_bucket_prefix(fog_file.key)] = fog_file
|
||||
end
|
||||
|
||||
return [] unless objects.any?
|
||||
|
||||
# First we exclude all objects that have matching existing job artifact record in the DB
|
||||
paths_with_job_artifact_records(objects.keys).each do |non_orphan_path|
|
||||
objects.delete(non_orphan_path)
|
||||
end
|
||||
|
||||
return [] unless objects.any?
|
||||
|
||||
# Next, if there were no matching job artifact record for the remaining paths, we want to
|
||||
# check if there is a pending direct upload for the given path, if found, they are not considered orphans.
|
||||
objects.delete_if do |path, _|
|
||||
pending_direct_upload?(path)
|
||||
paths_with_pending_direct_uploads(objects.keys).each do |non_orphan_path|
|
||||
objects.delete(non_orphan_path)
|
||||
end
|
||||
|
||||
# Just to keep the lexicographic order of objects
|
||||
|
|
@ -62,8 +66,8 @@ module Gitlab
|
|||
::Ci::JobArtifact.where(file_final_path: paths).pluck(:file_final_path) # rubocop:disable CodeReuse/ActiveRecord -- intentionally used pluck directly to keep it simple.
|
||||
end
|
||||
|
||||
def pending_direct_upload?(path)
|
||||
::ObjectStorage::PendingDirectUpload.exists?(:artifacts, path) # rubocop:disable CodeReuse/ActiveRecord -- `exists?` here is not the same as the AR method
|
||||
def paths_with_pending_direct_uploads(paths)
|
||||
::ObjectStorage::PendingDirectUpload.with_pending_only(:artifacts, paths)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -18,6 +18,21 @@ module ObjectStorage
|
|||
end
|
||||
end
|
||||
|
||||
def self.with_pending_only(location_identifier, object_storage_paths)
|
||||
with_redis do |redis|
|
||||
keys = object_storage_paths.map do |path|
|
||||
redis_key(location_identifier, path)
|
||||
end
|
||||
|
||||
matches = redis.hmget(KEY, keys)
|
||||
index = -1
|
||||
object_storage_paths.select do
|
||||
index += 1
|
||||
matches[index].present?
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def self.exists?(location_identifier, object_storage_path)
|
||||
with_redis do |redis|
|
||||
redis.hexists(KEY, redis_key(location_identifier, object_storage_path))
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@
|
|||
"@gitlab/favicon-overlay": "2.0.0",
|
||||
"@gitlab/fonts": "^1.3.0",
|
||||
"@gitlab/svgs": "3.84.0",
|
||||
"@gitlab/ui": "^74.9.3",
|
||||
"@gitlab/ui": "^76.0.0",
|
||||
"@gitlab/visual-review-tools": "1.7.3",
|
||||
"@gitlab/web-ide": "^0.0.1-dev-20240214084918",
|
||||
"@mattiasbuelens/web-streams-adapter": "^0.1.0",
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ RSpec.describe 'Profile > Applications', feature_category: :user_profile do
|
|||
create(:oauth_application, owner: user)
|
||||
visit oauth_applications_path
|
||||
|
||||
page.within('.oauth-applications') do
|
||||
within_testid('oauth-applications') do
|
||||
page.within('.gl-new-card-count') do
|
||||
expect(page).to have_content('1')
|
||||
end
|
||||
|
|
@ -34,7 +34,7 @@ RSpec.describe 'Profile > Applications', feature_category: :user_profile do
|
|||
accept_gl_confirm(button_text: 'Destroy')
|
||||
|
||||
expect(page).to have_content('The application was deleted successfully')
|
||||
page.within('.oauth-applications .gl-new-card-count') do
|
||||
page.within('[data-testid="oauth-applications"] .gl-new-card-count') do
|
||||
expect(page).to have_content('0')
|
||||
end
|
||||
page.within('.oauth-authorized-applications .gl-new-card-count') do
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ exports[`Custom emoji settings list component renders table of custom emoji 1`]
|
|||
<table
|
||||
aria-busy=""
|
||||
aria-colcount="4"
|
||||
class="b-table gl-table gl-table-layout-fixed table"
|
||||
class="b-table gl-table gl-table-fixed table"
|
||||
role="table"
|
||||
>
|
||||
<colgroup>
|
||||
|
|
|
|||
|
|
@ -12,11 +12,11 @@ exports[`Blob Simple Viewer component rendering matches the snapshot 1`] = `
|
|||
class="diff-line-num gl-display-flex line-links"
|
||||
>
|
||||
<a
|
||||
class="file-line-blame gl-mx-n2 gl-shadow-none! gl-user-select-none"
|
||||
class="file-line-blame gl-mx-n2 gl-select-none gl-shadow-none!"
|
||||
href="/blame/foo-bar#L1"
|
||||
/>
|
||||
<a
|
||||
class="file-line-num gl-shadow-none! gl-user-select-none"
|
||||
class="file-line-num gl-select-none gl-shadow-none!"
|
||||
data-line-number="1"
|
||||
href="#L1"
|
||||
id="reference-0"
|
||||
|
|
@ -28,11 +28,11 @@ exports[`Blob Simple Viewer component rendering matches the snapshot 1`] = `
|
|||
class="diff-line-num gl-display-flex line-links"
|
||||
>
|
||||
<a
|
||||
class="file-line-blame gl-mx-n2 gl-shadow-none! gl-user-select-none"
|
||||
class="file-line-blame gl-mx-n2 gl-select-none gl-shadow-none!"
|
||||
href="/blame/foo-bar#L2"
|
||||
/>
|
||||
<a
|
||||
class="file-line-num gl-shadow-none! gl-user-select-none"
|
||||
class="file-line-num gl-select-none gl-shadow-none!"
|
||||
data-line-number="2"
|
||||
href="#L2"
|
||||
id="reference-1"
|
||||
|
|
@ -44,11 +44,11 @@ exports[`Blob Simple Viewer component rendering matches the snapshot 1`] = `
|
|||
class="diff-line-num gl-display-flex line-links"
|
||||
>
|
||||
<a
|
||||
class="file-line-blame gl-mx-n2 gl-shadow-none! gl-user-select-none"
|
||||
class="file-line-blame gl-mx-n2 gl-select-none gl-shadow-none!"
|
||||
href="/blame/foo-bar#L3"
|
||||
/>
|
||||
<a
|
||||
class="file-line-num gl-shadow-none! gl-user-select-none"
|
||||
class="file-line-num gl-select-none gl-shadow-none!"
|
||||
data-line-number="3"
|
||||
href="#L3"
|
||||
id="reference-2"
|
||||
|
|
|
|||
|
|
@ -6,11 +6,11 @@ exports[`Chunk component rendering isHighlighted is true renders line numbers 1`
|
|||
data-testid="line-numbers"
|
||||
>
|
||||
<a
|
||||
class="file-line-blame gl-shadow-none! gl-user-select-none"
|
||||
class="file-line-blame gl-select-none gl-shadow-none!"
|
||||
href="some/blame/path.js#L71"
|
||||
/>
|
||||
<a
|
||||
class="file-line-num gl-shadow-none! gl-user-select-none"
|
||||
class="file-line-num gl-select-none gl-shadow-none!"
|
||||
data-line-number="71"
|
||||
href="#L71"
|
||||
id="reference-0"
|
||||
|
|
|
|||
|
|
@ -34,6 +34,25 @@ RSpec.describe ObjectStorage::PendingDirectUpload, :direct_uploads, :clean_gitla
|
|||
it { is_expected.to eq(3) }
|
||||
end
|
||||
|
||||
describe '.with_pending_only' do
|
||||
let(:path_1) { 'some/path/123' }
|
||||
let(:path_2) { 'some/path/456' }
|
||||
let(:path_3) { 'some/path/789' }
|
||||
let(:paths) { [path_1, path_2, path_3] }
|
||||
|
||||
subject(:result) { described_class.with_pending_only(location_identifier, paths) }
|
||||
|
||||
before do
|
||||
described_class.prepare(location_identifier, path_1)
|
||||
described_class.prepare(:uploads, path_2)
|
||||
described_class.prepare(location_identifier, path_3)
|
||||
end
|
||||
|
||||
it 'selects and returns the paths with a matching redis entry under the location identifier' do
|
||||
expect(result).to eq([path_1, path_3])
|
||||
end
|
||||
end
|
||||
|
||||
describe '.exists?' do
|
||||
let(:path) { 'some/path/123' }
|
||||
|
||||
|
|
|
|||
|
|
@ -37,10 +37,10 @@ RSpec.shared_examples 'manage applications' do
|
|||
|
||||
visit_applications_path
|
||||
|
||||
page.within '.oauth-applications' do
|
||||
page.within('[data-testid="oauth-applications"]') do
|
||||
click_on 'Destroy'
|
||||
end
|
||||
expect(page.find('.oauth-applications')).not_to have_content 'test_changed'
|
||||
expect(page.find('[data-testid="oauth-applications"]')).not_to have_content 'test_changed'
|
||||
end
|
||||
|
||||
context 'when scopes are blank' do
|
||||
|
|
|
|||
|
|
@ -1326,10 +1326,10 @@
|
|||
resolved "https://registry.yarnpkg.com/@gitlab/svgs/-/svgs-3.84.0.tgz#4c251a528c825875b3062be236ae2a06569c9f45"
|
||||
integrity sha512-v6Sh3VRVTelWY+yPJ/kWm1A4y0Ox1xgecXljVd7BpB0S9OboK2J5AXbwzqit6s4TSab/B8G3Vf5g4fHsVQCXqg==
|
||||
|
||||
"@gitlab/ui@^74.9.3":
|
||||
version "74.9.3"
|
||||
resolved "https://registry.yarnpkg.com/@gitlab/ui/-/ui-74.9.3.tgz#c78e7962f9abd35134680c8e5f68e40565a27a9b"
|
||||
integrity sha512-HoIPtsMaQ/Qj2DEX6AqJSWD+CPFAOxw1b1b/jGLQKJHwvR02ff+CNgE4Gv3luCfOVWlEwIiZfLwIorACZG6flg==
|
||||
"@gitlab/ui@^76.0.0":
|
||||
version "76.0.0"
|
||||
resolved "https://registry.yarnpkg.com/@gitlab/ui/-/ui-76.0.0.tgz#cbd8bcd2ddda80b1414882eee49e6324de283b49"
|
||||
integrity sha512-KSeIOL1vMGclD19vcUF84+VrCjbbUOsxYPKFoVXm6qk9KaaYMTsr8ZXlIldDj/OkfdmOR7U0mEjteNZoOlmUgg==
|
||||
dependencies:
|
||||
"@floating-ui/dom" "1.4.3"
|
||||
bootstrap-vue "2.23.1"
|
||||
|
|
|
|||
Loading…
Reference in New Issue