Skip to content

Commit

Permalink
Merge branch '6.0/rights-editor-style'
Browse files Browse the repository at this point in the history
  • Loading branch information
cbrandtbuffalo committed Jan 14, 2025
2 parents 30beec1 + 47d2a62 commit c5df490
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 17 deletions.
4 changes: 2 additions & 2 deletions share/html/Admin/Elements/EditRights
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ if ($anchor =~ /AddPrincipal/) {
<div class="row mt-2">
<div class="col-3">
<div class="principal-tabs">
<ul class="nav nav-tabs flex-column nav-pills" role="tablist" aria-orientation="vertical">
<ul class="nav flex-column nav-pills" role="tablist" aria-orientation="vertical">
<%perl>
for my $category (@$Principals) {
my ($name, $collection, $col, $loc) = @$category;
Expand All @@ -228,7 +228,7 @@ for my $category (@$Principals) {
my $display = ref $col eq 'CODE' ? $col->($obj) : $obj->$col;
my $id = "acl-" . $obj->PrincipalId;
</%perl>
<li class="nav-item">
<li class="rt-rights-role nav-item mb-1">
<a href="#<% $id %>" class="nav-link" id="<% "principal-tab-$id" %>" data-bs-toggle="tab" role="tab" aria-controls="<% $id %>" aria-selected="false">
<% $loc ? loc($display) : $display %>
</a>
Expand Down
14 changes: 1 addition & 13 deletions share/static/css/elevator/nav.css
Original file line number Diff line number Diff line change
Expand Up @@ -358,24 +358,12 @@
border-bottom: 1px solid #515151;
}

.nav-tabs .nav-link {
border: 1px solid transparent;
border-bottom-color: #515151;
}

.nav-tabs .nav-link:hover,
.nav-tabs .nav-link.active {
border-color: #515151 #515151 transparent;
}

.nav-tabs .nav-link:hover:not(.active) {
border-color: #515151;
}

.nav-pills .nav-link.active {
background-color: #323D42 !important;
}

.nav-pills .nav-link:hover:not(.active) {
text-decoration: underline;
}
}
27 changes: 25 additions & 2 deletions share/static/css/elevator/rights-editor.css
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,32 @@

}

.rights-editor .tab-aggregates-checked-rights:not(.active) {
background-color: var(--bs-secondary-bg);
}

/* Customize border color for principal tabs */
.principal-tabs .rt-rights-role .nav-link {
border-color: transparent;
border-width: 1px;
border-style: solid;
transition: unset;
}

[data-bs-theme=light] {
.rights-editor .tab-aggregates-checked-rights {
background-color: #eee;
.principal-tabs .rt-rights-role .nav-link.active {
border-color: var(--bs-nav-pills-link-active-bg);
}
.principal-tabs .rt-rights-role .nav-link:hover:not(.active) {
border-color: #ddd;
}
}

[data-bs-theme=dark] {
.principal-tabs .rt-rights-role .nav-link.active {
border-color: #515151;
}
.principal-tabs .rt-rights-role .nav-link:hover:not(.active) {
border-color: #666;
}
}

0 comments on commit c5df490

Please sign in to comment.