Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-10-25 06:11:36 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-10-25 06:11:36 +0300
commita85b67d51ad8895284babce73736437f9f41304b (patch)
tree2c10b0b635edac30f03aa6bd5cafba7750984c82 /app/views/ci
parente4d18499293fbc9510a87611acb7d9787a581b78 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/views/ci')
-rw-r--r--app/views/ci/status/_badge.html.haml13
-rw-r--r--app/views/ci/status/_icon.html.haml11
2 files changed, 4 insertions, 20 deletions
diff --git a/app/views/ci/status/_badge.html.haml b/app/views/ci/status/_badge.html.haml
deleted file mode 100644
index e3b409dea76..00000000000
--- a/app/views/ci/status/_badge.html.haml
+++ /dev/null
@@ -1,13 +0,0 @@
-- status = local_assigns.fetch(:status)
-- link = local_assigns.fetch(:link, true)
-- title = local_assigns.fetch(:title, nil)
-- css_classes = "gl-display-inline-flex gl-align-items-center gl-gap-2 gl-line-height-0 gl-px-3 gl-py-2 gl-rounded-base ci-status ci-#{status.group} #{'has-tooltip' if title.present?}"
-
-- if link && status.has_details?
- = link_to status.details_path, class: css_classes, title: title, data: { html: title.present? } do
- = sprite_icon(status.icon)
- = status.text
-- else
- %span{ class: css_classes, title: title, data: { html: title.present? } }
- = sprite_icon(status.icon)
- = status.text
diff --git a/app/views/ci/status/_icon.html.haml b/app/views/ci/status/_icon.html.haml
index 48e4472c117..bcb83874bfb 100644
--- a/app/views/ci/status/_icon.html.haml
+++ b/app/views/ci/status/_icon.html.haml
@@ -1,10 +1,7 @@
- status = local_assigns.fetch(:status)
-- tooltip_placement = local_assigns.fetch(:tooltip_placement, "left")
- path = local_assigns.fetch(:path, status.has_details? ? status.details_path : nil)
-- option_css_classes = local_assigns.fetch(:option_css_classes, '')
-- css_classes = "gl-px-2 #{option_css_classes}"
-- ci_css_classes = "ci-status-icon ci-status-icon-#{status.group} gl-line-height-1"
-- title = s_("PipelineStatusTooltip|Pipeline: %{ci_status}") % {ci_status: status.label}
+- tooltip_placement = local_assigns.fetch(:tooltip_placement, "left")
+- option_css_classes = local_assigns.fetch(:option_css_classes, nil)
+- show_status_text = local_assigns.fetch(:show_status_text, false)
-= gl_badge_tag(variant: badge_variant(status), size: :md, href: path, class: css_classes, title: title, data: { toggle: 'tooltip', placement: tooltip_placement, testid: "ci-status-badge" }) do
- = content_tag :span, sprite_icon(status.icon, size: 16), class: ci_css_classes
+= render_ci_icon(status, path, tooltip_placement: tooltip_placement, option_css_classes: option_css_classes, show_status_text: show_status_text)