diff --git a/app/assets/javascripts/work_items/components/work_item_prefetch.vue b/app/assets/javascripts/work_items/components/work_item_prefetch.vue
index d22c86fc641..bb01d9285ff 100644
--- a/app/assets/javascripts/work_items/components/work_item_prefetch.vue
+++ b/app/assets/javascripts/work_items/components/work_item_prefetch.vue
@@ -14,6 +14,11 @@ export default {
type: String,
required: true,
},
+ workItemFullPath: {
+ type: String,
+ required: false,
+ default: '',
+ },
},
data() {
return {
@@ -27,7 +32,7 @@ export default {
},
variables() {
return {
- fullPath: this.fullPath,
+ fullPath: this.workItemFullPath || this.fullPath,
iid: this.workItemIid,
};
},
diff --git a/app/assets/javascripts/work_items/list/queries/get_work_items.query.graphql b/app/assets/javascripts/work_items/list/queries/get_work_items.query.graphql
index 59918d650bc..ba41ad740df 100644
--- a/app/assets/javascripts/work_items/list/queries/get_work_items.query.graphql
+++ b/app/assets/javascripts/work_items/list/queries/get_work_items.query.graphql
@@ -85,6 +85,10 @@ query getWorkItems(
confidential
createdAt
iid
+ namespace {
+ id
+ fullPath
+ }
reference(full: true)
state
title
diff --git a/app/views/groups/settings/_remove_button.html.haml b/app/views/groups/settings/_remove_button.html.haml
index eb84cf32f91..ade223163d1 100644
--- a/app/views/groups/settings/_remove_button.html.haml
+++ b/app/views/groups/settings/_remove_button.html.haml
@@ -3,6 +3,6 @@
- if group.linked_to_subscription?
= render Pajamas::AlertComponent.new(variant: :tip, dismissible: false, alert_options: { class: 'gl-mb-5', data: { testid: 'group-has-linked-subscription-alert' }}) do |c|
- c.with_body do
- = html_escape(_("This group can't be removed because it is linked to a subscription. To remove this group, %{linkStart}link the subscription%{linkEnd} with a different group.")) % { linkStart: "
".html_safe, linkEnd: ''.html_safe }
+ = html_escape(_("This group can't be removed because it is linked to a subscription. To remove this group, %{linkStart}link the subscription%{linkEnd} with a different group.")) % { linkStart: "
".html_safe, linkEnd: ''.html_safe }
.js-confirm-danger{ data: group_confirm_modal_data(group: group, remove_form_id: remove_form_id) }
diff --git a/app/views/groups/settings/_transfer.html.haml b/app/views/groups/settings/_transfer.html.haml
index aa533d54b1a..28ffb829318 100644
--- a/app/views/groups/settings/_transfer.html.haml
+++ b/app/views/groups/settings/_transfer.html.haml
@@ -21,5 +21,5 @@
- if group.paid?
= render Pajamas::AlertComponent.new(variant: :tip, dismissible: false, alert_options: { class: 'gl-mb-5' }) do |c|
- c.with_body do
- = html_escape(_("This group can't be transferred because it is linked to a subscription. To transfer this group, %{linkStart}link the subscription%{linkEnd} with a different group.")) % { linkStart: "
".html_safe, linkEnd: ''.html_safe }
+ = html_escape(_("This group can't be transferred because it is linked to a subscription. To transfer this group, %{linkStart}link the subscription%{linkEnd} with a different group.")) % { linkStart: "
".html_safe, linkEnd: ''.html_safe }
.js-transfer-group-form{ data: initial_data }
diff --git a/config/initializers/active_record_schema_ignore_tables.rb b/config/initializers/active_record_schema_ignore_tables.rb
index 55c44e00c40..e4b55937404 100644
--- a/config/initializers/active_record_schema_ignore_tables.rb
+++ b/config/initializers/active_record_schema_ignore_tables.rb
@@ -1,4 +1,4 @@
# frozen_string_literal: true
# Ignore dynamically managed partitions in static application schema
-ActiveRecord::SchemaDumper.ignore_tables += ["#{Gitlab::Database::DYNAMIC_PARTITIONS_SCHEMA}.*"]
+ActiveRecord::Tasks::DatabaseTasks.structure_dump_flags = ["-T", "#{Gitlab::Database::DYNAMIC_PARTITIONS_SCHEMA}.*"]
diff --git a/db/migrate/20240422000001_add_security_policy_management_project_id_to_security_policies.rb b/db/migrate/20240422000001_add_security_policy_management_project_id_to_security_policies.rb
index d3fb81985f5..74dc1403c38 100644
--- a/db/migrate/20240422000001_add_security_policy_management_project_id_to_security_policies.rb
+++ b/db/migrate/20240422000001_add_security_policy_management_project_id_to_security_policies.rb
@@ -12,7 +12,6 @@ class AddSecurityPolicyManagementProjectIdToSecurityPolicies < Gitlab::Database:
:security_policy_management_project,
index: false,
null: false,
- unique: false,
foreign_key: { on_delete: :cascade, to_table: :projects }
# rubocop:enable Migration/AddReference
# rubocop:enable Rails/NotNullColumn
diff --git a/db/migrate/20240422000005_add_security_policy_management_project_id_to_approval_policy_rules.rb b/db/migrate/20240422000005_add_security_policy_management_project_id_to_approval_policy_rules.rb
index 18b5d506b56..5282765853e 100644
--- a/db/migrate/20240422000005_add_security_policy_management_project_id_to_approval_policy_rules.rb
+++ b/db/migrate/20240422000005_add_security_policy_management_project_id_to_approval_policy_rules.rb
@@ -12,7 +12,6 @@ class AddSecurityPolicyManagementProjectIdToApprovalPolicyRules < Gitlab::Databa
:security_policy_management_project,
index: false,
null: false,
- unique: false,
foreign_key: { on_delete: :cascade, to_table: :projects }
# rubocop:enable Migration/AddReference
# rubocop:enable Rails/NotNullColumn
diff --git a/doc/administration/settings/jira_cloud_app.md b/doc/administration/settings/jira_cloud_app.md
index 87bbc85dbfc..3e977827c10 100644
--- a/doc/administration/settings/jira_cloud_app.md
+++ b/doc/administration/settings/jira_cloud_app.md
@@ -60,7 +60,7 @@ either:
- The Organization Administrators (`org-admins`) group. Newer Atlassian organizations are using
[centralized user management](https://support.atlassian.com/user-management/docs/give-users-admin-permissions/#Centralized-user-management-content),
which contains the `org-admins` group. Existing Atlassian organizations are being migrated to centralized user management.
- If available, you should use the `org-admins` group to indicate which Jira users can manage the GitLab for Jira app. Alternatively you can use the
+ If available, you should use the `org-admins` group to indicate which Jira users can manage the GitLab for Jira Cloud app. Alternatively you can use the
`site-admins` group.
- The Site Administrators (`site-admins`) group. The `site-admins` group was used under
[original user management](https://support.atlassian.com/user-management/docs/give-users-admin-permissions/#Original-user-management-content).
diff --git a/doc/api/groups.md b/doc/api/groups.md
index 7b3534280f0..5da6e6b7392 100644
--- a/doc/api/groups.md
+++ b/doc/api/groups.md
@@ -1321,7 +1321,7 @@ Parameters:
The response is `202 Accepted` if the user has authorization.
NOTE:
-A GitLab.com group can't be deleted if it is linked to a subscription. To delete such a group, first [link the subscription](../subscriptions/gitlab_com/index.md#change-the-linked-namespace) with a different group.
+A GitLab.com group can't be deleted if it is linked to a subscription. To delete such a group, first [link the subscription](../subscriptions/gitlab_com/index.md#change-the-linked-group) with a different group.
## Restore group marked for deletion
diff --git a/doc/development/cloud_connector/index.md b/doc/development/cloud_connector/index.md
index ca8957d77bd..ea6fdbd4588 100644
--- a/doc/development/cloud_connector/index.md
+++ b/doc/development/cloud_connector/index.md
@@ -234,10 +234,11 @@ As an example, the feature is delivered as a stand-alone service called `new_fea
- `X-Gitlab-Global-User-Id`: A globally unique anonymous user ID string.
- `X-Gitlab-Realm`: One of `saas`, `self-managed`.
- `X-Gitlab-Version`: Version of the GitLab instance.
+ - `X-Gitlab-Host-Name`: The hostname of the current GitLab instance.
+ - `X-Gitlab-Duo-Seat-Count`: The number of either duo pro or duo enterprise seats the customer purchased. When both add-ons are present, it will take the highest number of seats.
- `Authorization`: Contains the Base64-encoded JWT as a `Bearer` token obtained from the `access_token` method in step 1.
- Some of these headers can be injected by merging the result of the `API::Helpers::CloudConnector#cloud_connector_headers`
- method to your payload.
+ Some of these headers can be injected by merging the result of the `Gitlab::CloudConnector#headers` method to your payload.
###### Permission checks
diff --git a/doc/development/documentation/styleguide/index.md b/doc/development/documentation/styleguide/index.md
index cce673ff071..85412ae79db 100644
--- a/doc/development/documentation/styleguide/index.md
+++ b/doc/development/documentation/styleguide/index.md
@@ -1132,25 +1132,31 @@ To describe multiple fields, use unordered list items:
## Illustrations
+GitLab documentation uses two illustration types:
+
+- Screenshots, used to show a portion of the GitLab user interface.
+- Diagrams, used to illustrate processes or relationships between entities.
+
Illustrations can help the reader understand a concept, where they are in a complicated process,
-or how they should interact with the application.
+or how they should interact with the application. Use illustrations sparingly because:
-Use illustrations sparingly because:
-
-- They tend to become out-of-date.
+- They become outdated.
- They are difficult and expensive to localize.
-- Their content cannot be read by screen readers.
+- They cannot be read by screen readers.
-Types of illustrations used in GitLab documentation are:
+If you must use illustrations in documentation, they should:
-- Screenshot. Use a screenshot when you need to show a portion of the GitLab user interface.
-- Diagram. Use a diagram to illustrate a process or the relationship between entities, for example.
+- Supplement the text, not replace it.
+ The reader should not have to rely only on the illustration to get the needed information.
+- Have an introductory sentence in the preceding text.
+ For example, `The following diagram illustrates the product analytics flow:`.
+- Be accessible. For more information, see the guidelines specific to screenshots and diagrams.
+- Exclude personally identifying information.
-Use illustrations only to supplement text, not replace it.
+### Screenshots
-### Screenshot
-
-Use a screenshot when you need to show a portion of the GitLab user interface.
+Use screenshots to show a portion of the GitLab user interface, if some relevant information
+can't be conveyed in text.
#### Capture the screenshot
@@ -1345,42 +1351,68 @@ You can take a screenshot of a single element.
Use `spec/docs_screenshots/container_registry_docs.rb` as a guide to create your own scripts.
-### Diagram
+### Diagrams
-Use a diagram to illustrate a process or the relationship between entities, for example.
+Use a diagram to illustrate a process or the relationship between entities, if the information is too
+complex to be understood from text only.
-Use [Mermaid](https://mermaid.js.org/#/) to create a diagram. This method has several advantages
-over a static image format (screenshot):
+To create a diagram, use [Mermaid](https://mermaid.js.org/#/), which has the following advantages:
-- The Mermaid format is easier to maintain because:
- - Their definition is stored as a code block in the documentation's Markdown source.
- - The diagram is rendered dynamically at runtime.
- - Text content that may change over time, such as feature names, can be found using text search
+- The Mermaid format is easier to maintain because the:
+ - Diagram definition is stored as a code block in the documentation's Markdown source.
+ - Diagram is rendered dynamically at runtime.
+ - Text content in the diagram (such as feature names) can be found with text search
tools and edited.
-- The diagram is rendered as an scalable image, better suited to various output devices and sizes.
+- The diagram is rendered as a scalable image, better suited to various output devices and sizes.
+
+To learn how to create diagrams with the [Mermaid syntax](https://mermaid.js.org/intro/syntax-reference.html),
+see the Mermaid [Mermaid user guide](https://mermaid.js.org/intro/getting-started.html)
+and the examples on the Mermaid site.
+
+#### Guidelines
+
+To create accessible and easily maintainable diagrams, follow these guidelines:
+
+- Keep diagrams simple and focused. Include only essential elements and information.
+- Use different but consistent visual cues (such as shape, color, and font) to distinguish between categories:
+
+ - Rectangles for processes or steps.
+ - Diamonds for decision points.
+ - Solid lines for direct relationships between elements.
+ - Dotted lines for indirect relationship between elements.
+ - Arrows for flow or direction in a process.
+ - GitLab Sans font.
+
+- Add clear labels and brief descriptions to diagram elements.
+- Include a title and brief description for the diagram.
+- For complex processes, consider creating multiple simple diagrams instead of one large diagram.
+- Validate diagrams work well when viewed on different devices and screen sizes.
+- Update diagrams along with documentation or code when processes change to maintain accuracy.
#### Create a diagram
-To create a diagram:
+To create a diagram for GitLab documentation:
-1. Use the [Mermaid Live Editor](https://mermaid.live/) to create the diagram.
-1. Copy the content of the **Code** pane into a `mermaid` code block in the Markdown file. For more
- details, see [Mermaid](../../../user/markdown.md#mermaid).
-1. Optional. To add GitLab font styling to your diagram, add this line between the Mermaid
- code block declaration and the type of diagram:
+1. In the [Mermaid Live Editor](https://mermaid.live/), create the diagram.
+1. Copy the content of the **Code** pane and paste it in the Markdown file, wrapped in a `mermaid` code block. For more
+ details, see [GitLab Flavored Markdown for Mermaid](../../../user/markdown.md#mermaid).
+1. To add GitLab font styling to your diagram, between the Mermaid code block declaration
+and the type of diagram, add the following line:
```plaintext
%%{init: { "fontFamily": "GitLab Sans" }}%%
```
-1. To improve accessibility of diagrams, add a title and description. Add these lines on the next
- line after declaring the type of diagram, like `flowchart` or `sequenceDiagram`:
+1. On the next line after declaring the type of diagram
+ (like `flowchart` or `sequenceDiagram`), add the following lines for accessibility:
```yaml
accTitle: your diagram title here
accDescr: describe what your diagram does in a single sentence, with no line breaks.
```
+ Make sure the title and description follow the [alternative text guidelines](#alternative-text).
+
For example, this flowchart contains both accessibility and font information:
````markdown
@@ -1394,10 +1426,6 @@ flowchart TD
```
````
-The Mermaid diagram syntax can be difficult to learn. To make this a little easier, see the Mermaid
-[Beginner's Guide](https://mermaid.js.org/intro/getting-started.html) and the examples on the
-Mermaid site.
-
## Emoji
Don't use the Markdown emoji format, for example `:smile:`, for any purpose. Use
diff --git a/doc/development/fe_guide/storybook.md b/doc/development/fe_guide/storybook.md
index dcb9dd8bf1f..213e71192c9 100644
--- a/doc/development/fe_guide/storybook.md
+++ b/doc/development/fe_guide/storybook.md
@@ -44,7 +44,9 @@ To add a story:
│ │ | ├─ todo_button.stories.js
```
-1. Write the story as per the [official Storybook instructions](https://storybook.js.org/docs/writing-stories/)
+1. Stories should demonstrate each significantly different UI state related to the component's exposed props and events.
+
+For instructions on how to write stories, refer to the [official Storybook instructions](https://storybook.js.org/docs/writing-stories/)
NOTE:
Specify the `title` field of the story as the component's file path from the `javascripts/` directory, without the `/components` part.
diff --git a/doc/development/integrations/jira_connect.md b/doc/development/integrations/jira_connect.md
index 7a02c861384..22560ce00db 100644
--- a/doc/development/integrations/jira_connect.md
+++ b/doc/development/integrations/jira_connect.md
@@ -6,7 +6,7 @@ info: Any user with at least the Maintainer role can merge updates to this conte
# GitLab for Jira Cloud app development
-Developers have two options for how set up a development environment for the GitLab for Jira app:
+Developers have two options for how set up a development environment for the GitLab for Jira Cloud app:
1. A full environment [with Jira](#set-up-with-jira). Use this when you need to test interactions with Jira.
1. A local environment [without Jira](#setup-without-jira). You can use this quicker setup if you do not require Jira, for example when testing the GitLab frontend.
@@ -105,7 +105,7 @@ Ensure you have [set up OAuth first](#set-up-the-gitlab-oauth-authentication-flo
otherwise these steps fail.
1. In Jira, go to **Jira settings > Apps > Manage apps**.
-1. Scroll to **User-installed apps**, find your GitLab for Jira app and expand it.
+1. Scroll to **User-installed apps**, find your GitLab for Jira Cloud app and expand it.
1. Select **Get started**.
You should be able to authenticate with your GitLab instance and begin linking groups.
diff --git a/doc/integration/jira/dvcs/index.md b/doc/integration/jira/dvcs/index.md
index 52721f31f40..95f83f180c7 100644
--- a/doc/integration/jira/dvcs/index.md
+++ b/doc/integration/jira/dvcs/index.md
@@ -11,29 +11,36 @@ DETAILS:
**Offering:** GitLab.com, Self-managed, GitLab Dedicated
WARNING:
-The Jira DVCS connector for Jira Cloud was [deprecated](https://gitlab.com/gitlab-org/gitlab/-/issues/362168) in GitLab 15.1
-and [removed](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/118126) in 16.0. Use the [GitLab for Jira Cloud app](../connect-app.md) instead.
-The Jira DVCS connector was also deprecated and removed for Jira 8.13 and earlier. You can only use the Jira DVCS connector with Jira Data Center or Jira Server in Jira 8.14 and later. Upgrade your Jira instance to Jira 8.14 or later and reconfigure the Jira integration on your GitLab instance.
+The Jira DVCS connector for Jira Cloud was [deprecated](https://gitlab.com/gitlab-org/gitlab/-/issues/362168)
+in GitLab 15.1 and [removed](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/118126) in 16.0.
+Use the [GitLab for Jira Cloud app](../connect-app.md) instead.
+The Jira DVCS connector was also deprecated and removed for Jira 8.13 and earlier.
+You can only use the Jira DVCS connector with Jira Data Center or Jira Server in Jira 8.14 and later.
+Upgrade your Jira instance to Jira 8.14 or later and reconfigure the Jira integration on your GitLab instance.
-Use the Jira DVCS (distributed version control system) connector if you self-host
-your Jira instance with Jira Data Center or Jira Server and want to use the [Jira development panel](../development_panel.md).
+Use the Jira DVCS (distributed version control system) connector if you self-host your Jira instance
+with Jira Data Center or Jira Server and want to use the [Jira development panel](../development_panel.md).
The Jira DVCS connector is developed and maintained by Atlassian.
-If you're on Jira Cloud, migrate to the GitLab for Jira Cloud app. For more information, see [Install the GitLab for Jira Cloud app](../connect-app.md#install-the-gitlab-for-jira-cloud-app).
+To configure the Jira DVCS connector, see the
+[Atlassian documentation](https://confluence.atlassian.com/adminjiraserver/integrating-with-development-tools-using-dvcs-1047552689.html).
-## Configure the Jira DVCS connector
-
-To configure the Jira DVCS Connector, see the [Atlassian documentation](https://confluence.atlassian.com/adminjiraserver/integrating-with-development-tools-using-dvcs-1047552689.html).
+If you're on Jira Cloud, migrate to the GitLab for Jira Cloud app.
+For more information, see [Install the GitLab for Jira Cloud app](../connect-app.md#install-the-gitlab-for-jira-cloud-app).
## Refresh data imported to Jira
-Jira imports commits and branches for GitLab projects every 60 minutes. To refresh the data manually in Jira:
+Jira imports commits and branches for GitLab projects every 60 minutes.
+To refresh the data manually in Jira:
1. Sign in to your Jira instance as the user you configured the integration with.
-1. On the top bar, in the upper-right corner, select **Administration** (**{settings}**) > **Applications**.
+1. On the top bar, in the upper-right corner,
+ select **Administration** (**{settings}**) > **Applications**.
1. On the left sidebar, select **DVCS accounts**.
1. To refresh one or more repositories in a DVCS account:
- - **For all repositories**, next to the account, select the ellipsis (**{ellipsis_h}**) > **Refresh repositories**.
+ - **For all repositories**, next to the account,
+ select the ellipsis (**{ellipsis_h}**) > **Refresh repositories**.
- **For a single repository**:
1. Select the account.
- 1. Hover over the repository you want to refresh, and in the **Last activity** column, select **Click to sync repository** (**{retry}**).
+ 1. Hover over the repository you want to refresh, and in the **Last activity** column,
+ select **Click to sync repository** (**{retry}**).
diff --git a/doc/subscriptions/gitlab_com/index.md b/doc/subscriptions/gitlab_com/index.md
index 92c0cdc2976..2b040931fe1 100644
--- a/doc/subscriptions/gitlab_com/index.md
+++ b/doc/subscriptions/gitlab_com/index.md
@@ -64,10 +64,10 @@ The following information is displayed:
|:----------------------------|:------------|
| **Seats in subscription** | If this is a paid plan, represents the number of seats you've bought for this group. |
| **Seats currently in use** | Number of seats in use. Select **See usage** to see a list of the users using these seats. |
-| **Max seats used** | Highest number of seats you've used. |
+| **Maximum seats used** | Highest number of seats you've used. |
| **Seats owed** | **Max seats used** minus **Seats in subscription**. |
-| **Subscription start date** | Date your subscription started. If this is for a Free plan, it's the date you transitioned off your group's paid plan. |
-| **Subscription end date** | Date your current subscription ends. Does not apply to Free plans. |
+| **Subscription start date** | Date your subscription started. |
+| **Subscription end date** | Date your current subscription ends. |
## How seat usage is determined
@@ -85,12 +85,11 @@ Billable users count toward the number of subscription seats purchased in your s
A user is not counted as a billable user if:
-- Users who are pending approval.
-- Members with the [Guest role on an Ultimate subscription](#free-guest-users).
-- Members with the [minimal access role](../../user/permissions.md#users-with-minimal-access).
-- [Banned members](../../user/group/moderate_users.md#ban-a-user).
-- [Blocked users](../../administration/moderate_users.md#block-a-user).
-- GitLab-created service accounts:
+- They are pending approval.
+- They have the [Guest role on an Ultimate subscription](#free-guest-users).
+- They are a [banned member](../../user/group/moderate_users.md#ban-a-user).
+- They are a [blocked user](../../administration/moderate_users.md#block-a-user).
+- The account is a GitLab-created service account:
- [Ghost User](../../user/profile/account/delete_account.md#associated-records).
- Bots such as:
- [Support Bot](../../user/project/service_desk/configure.md#support-bot-user).
@@ -133,7 +132,11 @@ To view your subscription information and a summary of seat counts:
### Search seat usage
-To search users in the **Seat usage** page, enter a string in the search field. A minimum of 3
+To search billable users:
+
+1. On the left sidebar, select **Search or go to** and find your group.
+1. Select **Settings > Usage Quotas**.
+1. On the **Seats tab**, enter a string in the search field. A minimum of 3
characters are required.
The search returns those users whose first name, last name, or username contain the search string.
@@ -159,9 +162,7 @@ and is not affected by the current search.
## Seats owed
-A GitLab subscription is valid for a specific number of users.
-
-If the number of billable users exceeds the number included in the subscription, known
+If the number of billable users exceeds the number of **seats in subscription**, known
as the number of **seats owed**, you must pay for the excess number of users.
For example, if you purchase a subscription for 10 users:
@@ -196,19 +197,19 @@ GitLab [bills you for the overage](../quarterly_reconciliation.md).
To add seats to a subscription:
-1. Log in to the [Customers Portal](https://customers.gitlab.com/).
-1. Go to the **Manage Purchases** page.
-1. Select **Add more seats** on the relevant subscription card.
+1. Sign in to the [Customers Portal](https://customers.gitlab.com/).
+1. Go to the **Subscriptions & purchases** page.
+1. Select **Add seats** on the relevant subscription card.
1. Enter the number of additional users.
-1. Review the **Purchase summary** section. The system lists the total price for all users on the
- system and a credit for what you've already paid. You are only charged for the net change.
+1. Review the **Purchase summary** section. The system lists the total price for all users on the system and a credit for what you've already paid. You are only charged for the net change.
1. Enter your payment information.
+1. Check the **I accept the Privacy Statement and Terms of Service** checkbox.
1. Select **Purchase seats**.
The following is emailed to you:
- A payment receipt. You can also access this information in the Customers Portal under
- [**View invoices**](https://customers.gitlab.com/receipts).
+ [**Invoices**](https://customers.gitlab.com/invoices).
### Remove users from your subscription
@@ -217,7 +218,7 @@ To remove a billable user from your subscription:
1. On the left sidebar, select **Search or go to** and find your group.
1. Select **Settings > Billing**.
1. In the **Seats currently in use** section, select **See usage**.
-1. In the row for the user you want to remove, on the right side, select the ellipsis and **Remove user**.
+1. In the row for the user you want to remove, on the right side, select **Remove user**.
1. Re-type the username and select **Remove user**.
If you add a member to a group by using the [share a group with another group](../../user/group/manage.md#share-a-group-with-another-group) feature, you can't remove the member by using this method. Instead, you can either:
@@ -249,15 +250,15 @@ amounts at which the alert displays.
| 100-999 | 8% of seats remain. |
| 1000+ | 5% of seats remain. |
-## Change the linked namespace
+## Change the linked group
-To change the namespace linked to a subscription:
+To change the group linked to a GitLab.com subscription:
1. Sign in to the [Customers Portal](https://customers.gitlab.com/customers/sign_in) with a
[linked](../customers_portal.md#link-a-gitlabcom-account) GitLab.com account.
1. Do one of the following:
- - If the subscription is not linked to a namespace, select **Link subscription to a group**.
- - If the subscription is already linked to a namespace, select **Subscription actions** (**{ellipsis_v}**) > **Change linked group**.
+ - If the subscription is not linked to a group, select **Link subscription to a group**.
+ - If the subscription is already linked to a group, select **Subscription actions** (**{ellipsis_v}**) > **Change linked group**.
1. Select the desired group from the **New Namespace** dropdown list. For a group to appear here, you must have the Owner role for that group.
1. If the [total number of users](#view-seat-usage) in your group exceeds the number of seats in your subscription,
you are prompted to pay for the additional users. Subscription charges are calculated based on
@@ -285,7 +286,7 @@ You cannot transfer:
- An expired or trial subscription.
- A subscription with compute minutes which is already linked to a namespace.
- A subscription with a Premium or Ultimate plan to a namespace which already has a Premium or Ultimate plan.
-- A subscription with code suggestions to a namespace which already has a subscriptions with code suggestions.
+- A subscription with a GitLab Duo add-on to a namespace which already has a subscriptions with a GitLab Duo add-on.
## Upgrade your GitLab.com subscription tier
@@ -295,7 +296,7 @@ To upgrade your [GitLab tier](https://about.gitlab.com/pricing/):
1. Select **Upgrade** on the relevant subscription card.
1. Select the desired upgrade.
1. Confirm the active form of payment, or add a new form of payment.
-1. Check the **I accept the Privacy Policy and Terms of Service** checkbox.
+1. Check the **I accept the Privacy Statement and Terms of Service** checkbox.
1. Select **Confirm purchase**.
When the purchase has been processed, you receive confirmation of your new subscription tier.
@@ -326,7 +327,7 @@ To renew your subscription:
Before you renew your subscription:
-1. Log in to the [Customers Portal](https://customers.gitlab.com/customers/sign_in).
+1. Sign in to the [Customers Portal](https://customers.gitlab.com/customers/sign_in).
1. On the left sidebar, select **Billing account settings**.
1. Under **Payment methods**, verify or update the credit card on file.
1. Scroll down to the **Company information** section to verify or update the invoice contact details.
@@ -348,7 +349,7 @@ To renew your subscription:
Your updated subscription is applied to your namespace. The renewal period start date
is displayed on the group Billing page under **Next subscription term start date**.
-An invoice is generated for the renewal and available for viewing or download on the [View invoices](https://customers.gitlab.com/receipts) page.
+An invoice is generated for the renewal and available for viewing or download on the [Invoices](https://customers.gitlab.com/invoices) page.
If you have difficulty during the renewal process, contact the [Support team](https://support.gitlab.com/hc/en-us/requests/new?ticket_form_id=360000071293) for assistance.
For details on upgrading your subscription tier, see
@@ -360,7 +361,7 @@ When a subscription is set to auto-renew, it renews automatically on the expirat
The number of seats is adjusted to fit the [number of billable users in your group](#view-seat-usage) at the time of renewal, if that number is higher than the current subscription quantity.
-You can view and download your renewal invoice on the Customers Portal [View invoices](https://customers.gitlab.com/receipts) page. If your account has a [saved credit card](../customers_portal.md#change-your-payment-method), the card is charged for the invoice amount. If we are unable to process a payment, or the auto-renewal fails for any other reason, you have 14 days to renew your subscription, after which your access is downgraded.
+You can view and download your renewal invoice on the Customers Portal [Invoices](https://customers.gitlab.com/invoices) page. If your account has a [saved credit card](../customers_portal.md#change-your-payment-method), the card is charged for the invoice amount. If we are unable to process a payment, or the auto-renewal fails for any other reason, you have 14 days to renew your subscription, after which your access is downgraded.
#### Email notifications
@@ -368,7 +369,7 @@ You can view and download your renewal invoice on the Customers Portal [View inv
- If your credit card is expired, the email tells you how to update it.
- If you have any outstanding overages, the email tells you to contact our Sales team.
-- If there are no issues, the email specifies the names and quantity of the products being renewed. The email also includes the total amount you owe. If your usage increases or decreases before renewal, this amount can change.
+- If there are no issues, the email specifies the names and quantity of the products being renewed. The email also includes the total amount you owe. If your usage increases before renewal, this amount will change.
#### Enable or disable automatic subscription renewal
@@ -416,14 +417,10 @@ for your personal or group namespace. Compute minutes are a **one-time purchase*
## Add-on subscription for additional Storage
-NOTE:
-Projects have a free storage quota of 10 GB. To exceed this quota you must first
-[purchase one or more storage subscription units](#purchase-more-storage). Each unit provides 10 GB of additional
+Projects have a free storage quota of 10 GiB. To exceed this quota you must first
+purchase one or more storage subscription units. Each unit provides 10 GiB of additional
storage per namespace. A storage subscription is renewed annually. For more details, see
-[Usage Quotas](../../user/usage_quotas.md).
-
-When the amount of purchased storage reaches zero, all projects over the free storage quota are
-locked. Projects can only be unlocked by purchasing more storage subscription units.
+[Storage](../../user/usage_quotas.md).
### Purchase more storage
@@ -441,17 +438,15 @@ You can [cancel the subscription](#enable-or-disable-automatic-subscription-rene
1. Sign in to GitLab.com.
1. From either your personal homepage or the group's page, go to **Settings > Usage Quotas**.
+1. Select **Storage** tab.
1. For each read-only project, total by how much its **Usage** exceeds the free quota and purchased
storage. You must purchase the storage increment that exceeds this total.
-1. Select **Purchase more storage** and you are taken to the Customers Portal.
-1. Select **Add new subscription**.
-1. Scroll to **Purchase add-on subscriptions** and select **Buy storage subscription**.
+1. Select **Buy storage** and you are taken to the Customers Portal.
1. In the **Subscription details** section select the name of the user or group from the dropdown list.
1. Enter the desired quantity of storage packs.
1. In the **Billing information** section select the payment method from the dropdown list.
-1. Select the **Privacy Policy** and **Terms of Service** checkbox.
-1. Select **Buy subscription**.
-1. Sign out of the Customers Portal.
+1. Select the **Privacy Statement** and **Terms of Service** checkbox.
+1. Select **Buy storage**.
1. Switch back to the GitLab.com tab and refresh the page.
The **Purchased storage available** total is incremented by the amount purchased. The read-only
@@ -469,11 +464,10 @@ To purchase additional storage for your group on GitLab.com:
1. On the left sidebar, select **Search or go to** and find your group.
1. Select **Settings > Usage Quotas**.
1. Select **Storage** tab.
-1. Select **Purchase more storage**.
+1. Select **Buy storage**.
1. Complete the details.
-After your payment is processed, the extra storage is available for your group
-namespace.
+After your payment is processed, the extra storage is available for your group namespace.
To confirm the available storage, go to your group, and then select
**Settings > Usage Quotas** and select the **Storage** tab.
@@ -534,11 +528,11 @@ To resolve this issue, wait a few minutes and try the purchase process again.
### Unable to link subscription to namespace
If you cannot link a subscription to your namespace, ensure that you have the Owner role
-for that namespace.
+for that namespace and review the [transfer restrictions](#transfer-restrictions).
### No purchases listed in the Customers Portal account
-To view purchases in the Customers Portal, in the **Manage Purchases** page, you
+To view purchases in the Customers Portal, in the **Subscriptions & purchases** page, you
must be a contact in your organization for the subscription.
To be added as a contact, [create a ticket with the GitLab Support team](https://support.gitlab.com/hc/en-us/requests/new?ticket_form_id=360000071293).
diff --git a/doc/subscriptions/self_managed/index.md b/doc/subscriptions/self_managed/index.md
index 7790d131e5d..a4005fd01f3 100644
--- a/doc/subscriptions/self_managed/index.md
+++ b/doc/subscriptions/self_managed/index.md
@@ -335,21 +335,19 @@ Users over subscription = 13 - 10 (Maximum users - users in license)
### Add seats to a subscription
-The users in license count can be increased by adding seats to a subscription any time during the
-subscription period. The cost of seats added during the subscription
-period is prorated from the date of purchase through the end of the subscription period.
+The users in license count can be increased by adding seats to a subscription any time during the subscription period. The cost of seats added during the subscription period is prorated from the date of purchase through the end of the subscription period. Even if you reach the number of users in license count, you can continue to add users. GitLab [bills you for the overage](../quarterly_reconciliation.md).
To add seats to a subscription:
1. Sign in to the [Customers Portal](https://customers.gitlab.com/).
-1. Go to the **Manage Purchases** page.
-1. Select **Add more seats** on the relevant subscription card.
+1. Go to the **Subscriptions & purchases** page.
+1. Select **Add seats** on the relevant subscription card.
1. Enter the number of additional users.
1. Review the **Purchase summary** section. The system lists the total price for all users on the system and a credit for what you've already paid. You are only charged for the net change.
1. Enter your payment information.
1. Select **Purchase seats**.
-A payment receipt is emailed to you, which you can also access in the Customers Portal under [**View invoices**](https://customers.gitlab.com/receipts).
+A payment receipt is emailed to you, which you can also access in the Customers Portal under [**Invoices**](https://customers.gitlab.com/invoices).
If your subscription was activated with an activation code, the additional seats are reflected in
your instance immediately. If you're using a license file, you receive an updated file.
@@ -392,7 +390,7 @@ You can view and download your renewal invoice on the Customers Portal [Invoices
- If your credit card is expired, the email tells you how to update it.
- If you have any outstanding overages or subscription isn't able to auto-renew for any other reason, the email tells you to contact our Sales team or [renew in Customers Portal](#renew-subscription-manually).
-- If there are no issues, the email specifies the names and quantity of the products being renewed. The email also includes the total amount you owe. If your usage increases or decreases before renewal, this amount can change.
+- If there are no issues, the email specifies the names and quantity of the products being renewed. The email also includes the total amount you owe. If your usage increases before renewal, this amount will change.
#### Enable or disable automatic subscription renewal
@@ -426,6 +424,7 @@ The following is emailed to you:
- A payment receipt. You can also access this information in the Customers Portal under
[**Invoices**](https://customers.gitlab.com/invoices).
+- A new activation code for your license.
The new tier takes effect on the next subscription sync, or you can [synchronize your subscription manually](#manually-synchronize-subscription-data)
to upgrade right away.
diff --git a/doc/user/free_user_limit.md b/doc/user/free_user_limit.md
index 9d06061337b..1e18eb23926 100644
--- a/doc/user/free_user_limit.md
+++ b/doc/user/free_user_limit.md
@@ -96,7 +96,7 @@ top-level namespace.
NOTE:
If you previously purchased a subscription and the 5-user limit was applied to a group,
-ensure that [your subscription is linked](../subscriptions/gitlab_com/index.md#change-the-linked-namespace)
+ensure that [your subscription is linked](../subscriptions/gitlab_com/index.md#change-the-linked-group)
to the correct top-level namespace, or that it has been
linked to your Customers Portal account.
diff --git a/gems/gitlab-backup-cli/Gemfile.lock b/gems/gitlab-backup-cli/Gemfile.lock
index 1395a84d354..c53a05343ad 100644
--- a/gems/gitlab-backup-cli/Gemfile.lock
+++ b/gems/gitlab-backup-cli/Gemfile.lock
@@ -10,7 +10,7 @@ PATH
remote: .
specs:
gitlab-backup-cli (0.0.1)
- activesupport (~> 7.0.8)
+ activesupport (< 7.2)
rainbow (~> 3.0)
thor (~> 1.3)
diff --git a/gems/gitlab-backup-cli/gitlab-backup-cli.gemspec b/gems/gitlab-backup-cli/gitlab-backup-cli.gemspec
index 2debae549a9..b847665f643 100644
--- a/gems/gitlab-backup-cli/gitlab-backup-cli.gemspec
+++ b/gems/gitlab-backup-cli/gitlab-backup-cli.gemspec
@@ -24,7 +24,7 @@ Gem::Specification.new do |spec|
spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
spec.require_paths = ["lib"]
- spec.add_dependency "activesupport", "~> 7.0.8"
+ spec.add_dependency "activesupport", "< 7.2"
spec.add_dependency "rainbow", "~> 3.0"
spec.add_dependency "thor", "~> 1.3"
diff --git a/lib/tasks/gitlab/db.rake b/lib/tasks/gitlab/db.rake
index f371b430594..accd67159d7 100644
--- a/lib/tasks/gitlab/db.rake
+++ b/lib/tasks/gitlab/db.rake
@@ -127,6 +127,8 @@ namespace :gitlab do
database_name = ":#{database_name}" if database_name
load_database = connection.tables.count <= 1
+ ActiveRecord::Base.connection_handler.clear_all_connections!(:all)
+
if load_database
puts "Running db:schema:load#{database_name} rake task"
Gitlab::Database.add_post_migrate_path_to_rails(force: true)
@@ -139,6 +141,15 @@ namespace :gitlab do
load_database
end
+ desc "Clear all connections"
+ task :clear_all_connections do
+ ActiveRecord::Base.connection_handler.clear_all_connections!(:all)
+ end
+
+ ActiveRecord::Tasks::DatabaseTasks.for_each(databases) do |name|
+ Rake::Task["db:test:purge:#{name}"].enhance(['gitlab:db:clear_all_connections'])
+ end
+
desc 'GitLab | DB | Run database migrations and print `unattended_migrations_completed` if action taken'
task unattended: :environment do
no_database = !ActiveRecord::Base.connection.schema_migration.table_exists?
diff --git a/package.json b/package.json
index baaa41122d9..e264e27bf45 100644
--- a/package.json
+++ b/package.json
@@ -8,7 +8,8 @@
"file-coverage": "scripts/frontend/file_test_coverage.js",
"lint-docs": "scripts/lint-doc.sh",
"internal:eslint": "eslint --cache --max-warnings 0 --report-unused-disable-directives --ext .js,.vue,.graphql",
- "internal:stylelint": "stylelint -q --rd '{ee/,}app/assets/stylesheets/**/*.{css,scss}'",
+ "internal:stylelint": "stylelint -q --rd '{ee/,}app/assets/{stylesheets/**/*.{css,scss},builds/tailwind.css}'",
+ "preinternal:stylelint": "yarn run tailwindcss:build",
"prejest": "yarn check-dependencies",
"build:css": "node scripts/frontend/build_css.mjs",
"tailwindcss:build": "node scripts/frontend/tailwind_all_the_way.mjs --only-used",
@@ -37,7 +38,8 @@
"lint:prettier:fix": "yarn run prettier --write '**/*.{graphql,js,vue}'",
"lint:prettier:staged": "scripts/frontend/execute-on-staged-files.sh prettier '(graphql|js|vue)' --check",
"lint:prettier:staged:fix": "scripts/frontend/execute-on-staged-files.sh prettier '(graphql|js|vue)' --write",
- "lint:stylelint": "stylelint '{ee/,}app/assets/stylesheets/**/*.{css,scss}'",
+ "lint:stylelint": "stylelint '{ee/,}app/assets/{stylesheets/**/*.{css,scss},builds/tailwind.css}'",
+ "prelint:stylelint": "yarn run tailwindcss:build",
"lint:stylelint:fix": "yarn run lint:stylelint --fix",
"lint:stylelint:staged": "scripts/frontend/execute-on-staged-files.sh stylelint '(css|scss)' -q",
"lint:stylelint:staged:fix": "yarn run lint:stylelint:staged --fix",
@@ -244,7 +246,7 @@
},
"devDependencies": {
"@gitlab/eslint-plugin": "19.6.0",
- "@gitlab/stylelint-config": "6.1.0",
+ "@gitlab/stylelint-config": "6.2.1",
"@graphql-eslint/eslint-plugin": "3.20.1",
"@originjs/vite-plugin-commonjs": "^1.0.3",
"@rollup/plugin-graphql": "^2.0.4",
diff --git a/qa/qa/support/formatters/test_metrics_formatter.rb b/qa/qa/support/formatters/test_metrics_formatter.rb
index fadf6ba985a..a7d5692c079 100644
--- a/qa/qa/support/formatters/test_metrics_formatter.rb
+++ b/qa/qa/support/formatters/test_metrics_formatter.rb
@@ -303,9 +303,10 @@ module QA
merge_request: merge_request
}.compact,
fields: {
- runtime: p[:run_time],
+ runtime: p[:runtime],
job_url: ci_job_url,
- pipeline_url: env('CI_PIPELINE_URL')
+ pipeline_url: env('CI_PIPELINE_URL'),
+ filename: p[:filename]
}.compact
}
end
diff --git a/qa/qa/support/page/logging.rb b/qa/qa/support/page/logging.rb
index 40b6202b7e8..cfcbb877364 100644
--- a/qa/qa/support/page/logging.rb
+++ b/qa/qa/support/page/logging.rb
@@ -219,7 +219,7 @@ module QA
name: location.label,
runtime: duration,
filename: location.path,
- call_arg: param_info
+ call_arg: param_info.is_a?(QA::Page::Element) ? param_info.name : param_info
)
if duration > kwargs.fetch(:log_slow_threshold, 0.5)
diff --git a/qa/spec/support/formatters/test_metrics_formatter_spec.rb b/qa/spec/support/formatters/test_metrics_formatter_spec.rb
index ef5554d6a71..d330f33e334 100644
--- a/qa/spec/support/formatters/test_metrics_formatter_spec.rb
+++ b/qa/spec/support/formatters/test_metrics_formatter_spec.rb
@@ -561,12 +561,12 @@ describe QA::Support::Formatters::TestMetricsFormatter do
{
name: "method-call-stats", time: time,
tags: { method: "has_element?", call_arg: "element_for_has", run_type: run_type, merge_request: "false" },
- fields: { job_url: ci_job_url, pipeline_url: ci_pipeline_url }
+ fields: { job_url: ci_job_url, pipeline_url: ci_pipeline_url, runtime: 1, filename: "file.rb" }
},
{
name: "method-call-stats", time: time,
tags: { method: "click", call_arg: "element_for_click", run_type: run_type, merge_request: "false" },
- fields: { job_url: ci_job_url, pipeline_url: ci_pipeline_url }
+ fields: { job_url: ci_job_url, pipeline_url: ci_pipeline_url, runtime: 1, filename: "file.rb" }
}
])
end
diff --git a/scripts/allowed_warnings.txt b/scripts/allowed_warnings.txt
index 89707e606a6..3be4cac8488 100644
--- a/scripts/allowed_warnings.txt
+++ b/scripts/allowed_warnings.txt
@@ -24,3 +24,9 @@ warning: One-line pattern matching is experimental, and the behavior may change
# it's really unlikelly that we will not be able to find a compatible version of the `io-event` gem if the
# experimental `IO::Buffer` feature changes in Ruby.
warning: IO::Buffer is experimental and both the Ruby and C interface may change in the future!
+
+# We need to build the Tailwind CSS bundle before running Stylelint so that we can lint against
+# forbidden syntax within the compiled tailwind.css. The Tailwind CSS builder logs some messages
+# with `console.error()` which need to be ignored here.
+Rebuilding...
+Done in [0-9]+ms.
diff --git a/scripts/static-analysis b/scripts/static-analysis
index 68480bb82f5..57d19dfdc79 100755
--- a/scripts/static-analysis
+++ b/scripts/static-analysis
@@ -47,7 +47,7 @@ class StaticAnalysis
Task.new(%w[bin/rake config_lint], 10),
Task.new(%w[bin/rake gitlab:sidekiq:all_queues_yml:check], 15),
(Gitlab.ee? ? Task.new(%w[bin/rake gitlab:sidekiq:sidekiq_queues_yml:check], 11) : nil),
- Task.new(%w[yarn run internal:stylelint], 8),
+ Task.new(%w[yarn run internal:stylelint], 33),
Task.new(%w[scripts/lint-conflicts.sh], 1),
Task.new(%w[yarn run block-dependencies], 1),
Task.new(%w[yarn run check-dependencies], 1),
diff --git a/spec/controllers/projects/autocomplete_sources_controller_spec.rb b/spec/controllers/projects/autocomplete_sources_controller_spec.rb
index 153ff139b0e..b33169da680 100644
--- a/spec/controllers/projects/autocomplete_sources_controller_spec.rb
+++ b/spec/controllers/projects/autocomplete_sources_controller_spec.rb
@@ -145,7 +145,7 @@ RSpec.describe Projects::AutocompleteSourcesController do
end
it 'returns an array of member object' do
- get :members, format: :json, params: { namespace_id: group.path, project_id: public_project.path, type: issuable_type }
+ get :members, format: :json, params: { namespace_id: group.path, project_id: public_project.path, type: issuable_type, type_id: issuable_iid }
expect(members_by_username('all').symbolize_keys).to include(
username: 'all',
@@ -175,7 +175,7 @@ RSpec.describe Projects::AutocompleteSourcesController do
end
it 'does not return the all mention user' do
- get :members, format: :json, params: { namespace_id: group.path, project_id: public_project.path, type: issuable_type }
+ get :members, format: :json, params: { namespace_id: group.path, project_id: public_project.path, type: issuable_type, type_id: issuable_iid }
expect(json_response).not_to include(a_hash_including(
{ username: 'all', name: 'All Project and Group Members' }))
@@ -185,12 +185,14 @@ RSpec.describe Projects::AutocompleteSourcesController do
context 'with issue' do
let(:issuable_type) { issue.class.name }
+ let(:issuable_iid) { issue.iid }
it_behaves_like 'all members are returned'
end
context 'with work item' do
let(:issuable_type) { work_item.class.name }
+ let(:issuable_iid) { work_item.iid }
it_behaves_like 'all members are returned'
end
@@ -211,7 +213,7 @@ RSpec.describe Projects::AutocompleteSourcesController do
end
it 'returns members including those from invited private groups' do
- get :members, format: :json, params: { namespace_id: group.path, project_id: public_project.path, type: issuable_type }
+ get :members, format: :json, params: { namespace_id: group.path, project_id: public_project.path, type: issuable_type, type_id: issuable_iid }
expect(members_by_username('all').symbolize_keys).to include(
username: 'all',
@@ -235,7 +237,7 @@ RSpec.describe Projects::AutocompleteSourcesController do
end
it 'does not return the all mention user' do
- get :members, format: :json, params: { namespace_id: group.path, project_id: public_project.path, type: issuable_type }
+ get :members, format: :json, params: { namespace_id: group.path, project_id: public_project.path, type: issuable_type, type_id: issuable_iid }
expect(json_response).not_to include(a_hash_including(
{ username: 'all', name: 'All Project and Group Members' }))
@@ -246,20 +248,24 @@ RSpec.describe Projects::AutocompleteSourcesController do
context 'with issue' do
it_behaves_like 'private project is inaccessible' do
let(:issuable_type) { private_issue.class.name }
+ let(:issuable_iid) { private_issue.iid }
end
it_behaves_like 'returns all members of public project' do
let(:issuable_type) { issue.class.name }
+ let(:issuable_iid) { issue.iid }
end
end
context 'with work item' do
it_behaves_like 'private project is inaccessible' do
let(:issuable_type) { private_work_item.class.name }
+ let(:issuable_iid) { private_work_item.iid }
end
it_behaves_like 'returns all members of public project' do
let(:issuable_type) { work_item.class.name }
+ let(:issuable_iid) { work_item.iid }
end
end
end
diff --git a/spec/frontend/work_items/components/work_item_prefetch_spec.js b/spec/frontend/work_items/components/work_item_prefetch_spec.js
index 511a4fc9d7b..444b237234a 100644
--- a/spec/frontend/work_items/components/work_item_prefetch_spec.js
+++ b/spec/frontend/work_items/components/work_item_prefetch_spec.js
@@ -20,7 +20,7 @@ describe('WorkItemPrefetch component', () => {
Vue.use(VueApollo);
- const createComponent = () => {
+ const createComponent = (workItemFullPath = undefined) => {
const mockApollo = createMockApollo([[workItemByIidQuery, getWorkItemQueryHandler]]);
wrapper = shallowMountExtended(WorkItemPrefetch, {
@@ -30,6 +30,7 @@ describe('WorkItemPrefetch component', () => {
},
propsData: {
workItemIid: '1',
+ workItemFullPath,
},
scopedSlots: {
default: `
@@ -47,13 +48,17 @@ describe('WorkItemPrefetch component', () => {
});
};
- it('triggers prefetching on hover', async () => {
- createComponent();
-
+ const triggerQuery = async () => {
await findPrefetchTrigger().trigger('mouseover');
await waitForPromises();
await jest.advanceTimersByTime(DEFAULT_DEBOUNCE_AND_THROTTLE_MS);
+ };
+
+ it('triggers prefetching on hover', async () => {
+ createComponent();
+
+ await triggerQuery();
expect(getWorkItemQueryHandler).toHaveBeenCalled();
});
@@ -66,4 +71,25 @@ describe('WorkItemPrefetch component', () => {
expect(getWorkItemQueryHandler).not.toHaveBeenCalled();
});
+
+ describe('fullPath handling', () => {
+ it('uses the injected fullPath if no workItemFullPath prop is provided', async () => {
+ createComponent();
+
+ await triggerQuery();
+
+ expect(getWorkItemQueryHandler).toHaveBeenCalledWith({ fullPath: 'group/project', iid: '1' });
+ });
+
+ it('uses the workItemFullPath prop when provided', async () => {
+ createComponent('other-full-path');
+
+ await triggerQuery();
+
+ expect(getWorkItemQueryHandler).toHaveBeenCalledWith({
+ fullPath: 'other-full-path',
+ iid: '1',
+ });
+ });
+ });
});
diff --git a/spec/frontend/work_items/mock_data.js b/spec/frontend/work_items/mock_data.js
index b501c9406d2..05b876da860 100644
--- a/spec/frontend/work_items/mock_data.js
+++ b/spec/frontend/work_items/mock_data.js
@@ -4286,6 +4286,10 @@ export const groupWorkItemsQueryResponse = {
closedAt: '',
confidential: true,
createdAt: '2020-01-23T12:34:56Z',
+ namespace: {
+ id: 'full-path-epic-id',
+ fullPath: 'full-path',
+ },
reference: 'javascriptjs/js#23',
state: 'OPEN',
title: 'a group level work item',
diff --git a/spec/lib/gitlab/markdown_cache/active_record/extension_spec.rb b/spec/lib/gitlab/markdown_cache/active_record/extension_spec.rb
index 31c9829dfd0..081f1f4057b 100644
--- a/spec/lib/gitlab/markdown_cache/active_record/extension_spec.rb
+++ b/spec/lib/gitlab/markdown_cache/active_record/extension_spec.rb
@@ -1,7 +1,7 @@
# frozen_string_literal: true
require 'spec_helper'
-RSpec.describe Gitlab::MarkdownCache::ActiveRecord::Extension do
+RSpec.describe Gitlab::MarkdownCache::ActiveRecord::Extension, feature_category: :wiki do
let_it_be(:project) { create(:project) }
let(:klass) do
diff --git a/yarn.lock b/yarn.lock
index 42c5ba53bef..39b1a0896c7 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -1345,10 +1345,10 @@
resolved "https://registry.yarnpkg.com/@gitlab/fonts/-/fonts-1.3.0.tgz#df89c1bb6714e4a8a5d3272568aa4de7fb337267"
integrity sha512-DoMUIN3DqjEn7wvcxBg/b7Ite5fTdF5EmuOZoBRo2j0UBGweDXmNBi+9HrTZs4cBU660dOxcf1hATFcG3npbPg==
-"@gitlab/stylelint-config@6.1.0":
- version "6.1.0"
- resolved "https://registry.yarnpkg.com/@gitlab/stylelint-config/-/stylelint-config-6.1.0.tgz#8345eb7523e97ad737c94fd024d25de4329df1a6"
- integrity sha512-PosGz6l6DRPR9YAGvBDZnBVo6/iTxSLy76+/adlvxuvcQz9AoPwCEEhdMKS7h8+Wtw3oCjAOBYA2pPMHxltwqA==
+"@gitlab/stylelint-config@6.2.1":
+ version "6.2.1"
+ resolved "https://registry.yarnpkg.com/@gitlab/stylelint-config/-/stylelint-config-6.2.1.tgz#80263cabb1aa9587f09eea33f12375f1da7ceb55"
+ integrity sha512-vT+z3c3BwB8M6Ks4HoEi8IrZEeoRlOJkhxMGbr/udlIvUfnlD6fOOPubabCKsu4aMITu22l7MxL5lIzfKfjgWg==
dependencies:
postcss-scss "4.0.9"
stylelint-declaration-strict-value "1.10.4"