2019-01-21 15:52:53 -05:00
|
|
|
- can_create_subgroups = can?(current_user, :create_subgroup, @group)
|
2020-04-28 05:09:34 -04:00
|
|
|
- can_create_projects = can?(current_user, :create_projects, @group)
|
2019-08-17 01:56:48 -04:00
|
|
|
- emails_disabled = @group.emails_disabled?
|
2017-01-24 10:32:34 -05:00
|
|
|
|
2019-01-21 15:52:53 -05:00
|
|
|
.group-home-panel
|
2022-09-14 02:11:48 -04:00
|
|
|
.row.my-3
|
2019-01-21 15:52:53 -05:00
|
|
|
.home-panel-title-row.col-md-12.col-lg-6.d-flex
|
2021-09-29 05:11:43 -04:00
|
|
|
.avatar-container.rect-avatar.s64.home-panel-avatar.gl-flex-shrink-0.float-none{ class: 'gl-mr-3!' }
|
2020-11-18 19:09:41 -05:00
|
|
|
= group_icon(@group, class: 'avatar avatar-tile s64', width: 64, height: 64, itemprop: 'logo')
|
2019-01-21 15:52:53 -05:00
|
|
|
.d-flex.flex-column.flex-wrap.align-items-baseline
|
|
|
|
.d-inline-flex.align-items-baseline
|
2022-09-14 02:11:48 -04:00
|
|
|
%h1.home-panel-title.gl-font-size-h1.gl-mt-3.gl-mb-2{ itemprop: 'name' }
|
2019-01-21 15:52:53 -05:00
|
|
|
= @group.name
|
2022-09-14 02:11:48 -04:00
|
|
|
%span.visibility-icon.gl-text-secondary.gl-ml-2.has-tooltip{ data: { container: 'body' }, title: visibility_icon_description(@group) }
|
2020-07-22 20:09:43 -04:00
|
|
|
= visibility_level_icon(@group.visibility_level, options: {class: 'icon'})
|
2022-09-14 02:11:48 -04:00
|
|
|
.home-panel-metadata.gl-text-secondary.gl-font-base.gl-font-weight-normal.gl-line-height-normal{ data: { qa_selector: 'group_id_content' }, itemprop: 'identifier' }
|
2021-09-29 05:11:43 -04:00
|
|
|
- if can?(current_user, :read_group, @group)
|
2022-01-13 10:14:46 -05:00
|
|
|
%span.gl-display-inline-block.gl-vertical-align-middle
|
|
|
|
= s_("GroupPage|Group ID: %{group_id}") % { group_id: @group.id }
|
2022-04-27 11:10:01 -04:00
|
|
|
= clipboard_button(title: s_('GroupPage|Copy group ID'), text: @group.id)
|
2019-01-21 15:52:53 -05:00
|
|
|
- if current_user
|
2022-01-13 10:14:46 -05:00
|
|
|
%span.gl-ml-3.gl-mb-3
|
2019-01-21 15:52:53 -05:00
|
|
|
= render 'shared/members/access_request_links', source: @group
|
2017-01-24 10:32:34 -05:00
|
|
|
|
2020-11-12 10:09:09 -05:00
|
|
|
.home-panel-buttons.col-md-12.col-lg-6
|
2019-01-21 15:52:53 -05:00
|
|
|
- if current_user
|
2020-11-12 10:09:09 -05:00
|
|
|
.gl-display-flex.gl-flex-wrap.gl-lg-justify-content-end.gl-mx-n2{ data: { testid: 'group-buttons' } }
|
2021-07-01 05:07:33 -04:00
|
|
|
- if current_user.admin?
|
2021-08-30 08:09:48 -04:00
|
|
|
= link_to [:admin, @group], class: 'btn btn-default gl-button btn-icon gl-mt-3 gl-mr-2', title: _('View group in admin area'),
|
2021-07-01 05:07:33 -04:00
|
|
|
data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do
|
|
|
|
= sprite_icon('admin')
|
2021-03-01 04:11:01 -05:00
|
|
|
- if @notification_setting
|
2022-01-31 01:12:59 -05:00
|
|
|
.js-vue-notification-dropdown{ data: { disabled: emails_disabled.to_s, dropdown_items: notification_dropdown_items(@notification_setting).to_json, notification_level: @notification_setting.level, help_page_path: help_page_path('user/profile/notifications'), group_id: @group.id, container_class: 'gl-mx-2 gl-mt-3 gl-vertical-align-top', no_flip: 'true' } }
|
2020-11-12 10:09:09 -05:00
|
|
|
- if can_create_subgroups
|
|
|
|
.gl-px-2.gl-sm-w-auto.gl-w-full
|
2022-07-27 08:10:44 -04:00
|
|
|
= link_to _("New subgroup"),
|
|
|
|
new_group_path(parent_id: @group.id, anchor: 'create-group-pane'),
|
|
|
|
class: "btn btn-default gl-button gl-mt-3 gl-sm-w-auto gl-w-full",
|
|
|
|
data: { qa_selector: 'new_subgroup_button' }
|
2020-11-12 10:09:09 -05:00
|
|
|
- if can_create_projects
|
|
|
|
.gl-px-2.gl-sm-w-auto.gl-w-full
|
2021-03-09 04:10:44 -05:00
|
|
|
= link_to _("New project"), new_project_path(namespace_id: @group.id), class: "btn btn-confirm gl-button gl-mt-3 gl-sm-w-auto gl-w-full", data: { qa_selector: 'new_project_button' }
|
2019-01-21 15:52:53 -05:00
|
|
|
|
|
|
|
- if @group.description.present?
|
|
|
|
.group-home-desc.mt-1
|
|
|
|
.home-panel-description
|
2020-11-18 19:09:41 -05:00
|
|
|
.home-panel-description-markdown.read-more-container{ itemprop: 'description' }
|
2019-01-21 15:52:53 -05:00
|
|
|
= markdown_field(@group, :description)
|
2021-04-09 23:09:09 -04:00
|
|
|
%button.gl-button.btn.btn-link.js-read-more-trigger.d-lg-none{ type: "button" }
|
2019-01-21 15:52:53 -05:00
|
|
|
= _("Read more")
|