diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-04 12:12:56 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-04 12:12:56 +0300 |
commit | 191020103bd4d2aad99c62a35201c05d9df74f8f (patch) | |
tree | 83ef6f71fea1f66842545e9af788fdc33d34d48b /app/views | |
parent | 5bfd7a344b73d6a9482b420fa7646f7d1760a566 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/views')
-rw-r--r-- | app/views/dashboard/_projects_head.html.haml | 14 | ||||
-rw-r--r-- | app/views/dashboard/_projects_nav.html.haml | 18 | ||||
-rw-r--r-- | app/views/explore/projects/topics.html.haml | 12 | ||||
-rw-r--r-- | app/views/explore/topics/_head.html.haml | 9 | ||||
-rw-r--r-- | app/views/jira_connect/branches/new.html.haml | 1 | ||||
-rw-r--r-- | app/views/shared/topics/_list.html.haml | 9 | ||||
-rw-r--r-- | app/views/shared/topics/_topic.html.haml | 16 |
7 files changed, 66 insertions, 13 deletions
diff --git a/app/views/dashboard/_projects_head.html.haml b/app/views/dashboard/_projects_head.html.haml index fdaf2107686..b94b14bf6bd 100644 --- a/app/views/dashboard/_projects_head.html.haml +++ b/app/views/dashboard/_projects_head.html.haml @@ -14,19 +14,7 @@ .top-area.scrolling-tabs-container.inner-page-scroll-tabs .fade-left= sprite_icon('chevron-lg-left', size: 12) .fade-right= sprite_icon('chevron-lg-right', size: 12) - %ul.nav-links.scrolling-tabs.mobile-separator.nav.nav-tabs{ class: ('border-0' if feature_project_list_filter_bar) } - = nav_link(page: [dashboard_projects_path, root_path]) do - = link_to dashboard_projects_path, class: 'shortcuts-activity', data: {placement: 'right'} do - = _("Your projects") - %span.badge.gl-tab-counter-badge.badge-muted.badge-pill.gl-badge.sm= limited_counter_with_delimiter(@total_user_projects_count) - = nav_link(page: starred_dashboard_projects_path) do - = link_to starred_dashboard_projects_path, data: {placement: 'right'} do - = _("Starred projects") - %span.badge.gl-tab-counter-badge.badge-muted.badge-pill.gl-badge.sm= limited_counter_with_delimiter(@total_starred_projects_count) - = nav_link(page: [explore_root_path, trending_explore_projects_path, starred_explore_projects_path, explore_projects_path]) do - = link_to explore_root_path, data: {placement: 'right'} do - = _("Explore projects") - = render_if_exists "dashboard/removed_projects_tab", removed_projects_count: @removed_projects_count + = render 'dashboard/projects_nav' - unless feature_project_list_filter_bar .nav-controls = render 'shared/projects/search_form' diff --git a/app/views/dashboard/_projects_nav.html.haml b/app/views/dashboard/_projects_nav.html.haml new file mode 100644 index 00000000000..b5512ea9efa --- /dev/null +++ b/app/views/dashboard/_projects_nav.html.haml @@ -0,0 +1,18 @@ +- feature_project_list_filter_bar = Feature.enabled?(:project_list_filter_bar) + +%ul.nav-links.scrolling-tabs.mobile-separator.nav.nav-tabs{ class: ('gl-border-0!' if feature_project_list_filter_bar) } + = nav_link(page: [dashboard_projects_path, root_path]) do + = link_to dashboard_projects_path, class: 'shortcuts-activity', data: {placement: 'right'} do + = _("Your projects") + %span.badge.gl-tab-counter-badge.badge-muted.badge-pill.gl-badge.sm= limited_counter_with_delimiter(@total_user_projects_count) + = nav_link(page: starred_dashboard_projects_path) do + = link_to starred_dashboard_projects_path, data: {placement: 'right'} do + = _("Starred projects") + %span.badge.gl-tab-counter-badge.badge-muted.badge-pill.gl-badge.sm= limited_counter_with_delimiter(@total_starred_projects_count) + = nav_link(page: [explore_root_path, trending_explore_projects_path, starred_explore_projects_path, explore_projects_path]) do + = link_to explore_root_path, data: {placement: 'right'} do + = _("Explore projects") + = nav_link(page: topics_explore_projects_path) do + = link_to topics_explore_projects_path, data: {placement: 'right'} do + = _("Explore topics") + = render_if_exists "dashboard/removed_projects_tab", removed_projects_count: @removed_projects_count diff --git a/app/views/explore/projects/topics.html.haml b/app/views/explore/projects/topics.html.haml new file mode 100644 index 00000000000..228304d25b6 --- /dev/null +++ b/app/views/explore/projects/topics.html.haml @@ -0,0 +1,12 @@ +- @hide_top_links = true +- page_title _("Topics") +- header_title _("Topics"), topics_explore_projects_path + += render_dashboard_ultimate_trial(current_user) + +- if current_user + = render 'explore/topics/head' +- else + = render 'explore/head' + += render partial: 'shared/topics/list' diff --git a/app/views/explore/topics/_head.html.haml b/app/views/explore/topics/_head.html.haml new file mode 100644 index 00000000000..f5ee95b16c3 --- /dev/null +++ b/app/views/explore/topics/_head.html.haml @@ -0,0 +1,9 @@ +.page-title-holder.d-flex.align-items-center + %h1.page-title= _('Projects') + +.top-area.scrolling-tabs-container.inner-page-scroll-tabs + .fade-left= sprite_icon('chevron-lg-left', size: 12) + .fade-right= sprite_icon('chevron-lg-right', size: 12) + = render 'dashboard/projects_nav' + .nav-controls + = render 'shared/topics/search_form' diff --git a/app/views/jira_connect/branches/new.html.haml b/app/views/jira_connect/branches/new.html.haml index f0e34c30018..74d547e6bb8 100644 --- a/app/views/jira_connect/branches/new.html.haml +++ b/app/views/jira_connect/branches/new.html.haml @@ -1,5 +1,6 @@ - @hide_breadcrumbs = true - @hide_top_links = true +- @content_class = 'limit-container-width' - page_title _('New branch') .js-jira-connect-create-branch{ data: @new_branch_data } diff --git a/app/views/shared/topics/_list.html.haml b/app/views/shared/topics/_list.html.haml new file mode 100644 index 00000000000..ddf47261d42 --- /dev/null +++ b/app/views/shared/topics/_list.html.haml @@ -0,0 +1,9 @@ +- remote = local_assigns.fetch(:remote, false) + +- if @topics.empty? + = render 'shared/empty_states/topics' +- else + .row.gl-mt-3 + = render partial: 'shared/topics/topic', collection: @topics + + = paginate_collection @topics, remote: remote diff --git a/app/views/shared/topics/_topic.html.haml b/app/views/shared/topics/_topic.html.haml new file mode 100644 index 00000000000..a47d4495777 --- /dev/null +++ b/app/views/shared/topics/_topic.html.haml @@ -0,0 +1,16 @@ +- max_topic_name_length = 30 +- detail_page_link = topic_explore_projects_path(topic_name: topic.name) + +.col-lg-3.col-md-4.col-sm-12 + .gl-card.gl-mb-5 + .gl-card-body.gl-display-flex.gl-align-items-center + .avatar-container.rect-avatar.s40.gl-flex-shrink-0 + = link_to detail_page_link do + = topic_icon(topic, class: "avatar s40") + = link_to detail_page_link do + - if topic.name.length > max_topic_name_length + %h5.str-truncated.has-tooltip{ title: topic.name } + = truncate(topic.name, length: max_topic_name_length) + - else + %h5 + = topic.name |