Skip to content

Commit

Permalink
Revert "Update appearance of controls in header (jenkinsci#8791)"
Browse files Browse the repository at this point in the history
This reverts commit d75833e.
  • Loading branch information
daniel-beck committed Feb 13, 2024
1 parent 71afdb9 commit 0543bdf
Show file tree
Hide file tree
Showing 4 changed files with 86 additions and 34 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ THE SOFTWARE.
<j:jelly xmlns:j="jelly:core" xmlns:st="jelly:stapler">
<st:include page="/hudson/security/SecurityRealm/loginLink.jelly" />
<j:if test="${it.allowsSignup()}">
<a href="${rootURL}/signup">${%sign up}</a>
|
<a href="${rootURL}/signup"><b>${%sign up}</b></a>
</j:if>
</j:jelly>
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,5 @@ THE SOFTWARE.

<?jelly escape-by-default='true'?>
<j:jelly xmlns:j="jelly:core" xmlns:st="jelly:stapler">
<a href="${rootURL}/${app.securityRealm.loginUrl}?from=${app.securityRealm.from}">${%login}</a>
<a href="${rootURL}/${app.securityRealm.loginUrl}?from=${app.securityRealm.from}"><b>${%login}</b></a>
</j:jelly>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
.am-container {
display: contents;
height: 100%;
}

.am-button {
Expand All @@ -14,62 +14,89 @@
border-radius: 50%;
width: 0.65rem;
height: 0.65rem;
background-color: var(--warning-color);
background-color: #ff9800;
}
.security-am .am-monitor__indicator-mobile {
background-color: var(--error-color);
background-color: #dc3545;
}

.am-button .am-monitor__count {
display: inline-block;
display: inline-flex;
justify-content: center;
align-items: center;
height: 18px;
min-width: 18px;
height: 20px;
min-width: 20px;

color: #fff;
background-color: var(--warning-color);
font-weight: 500;
font-size: var(--font-size-xs);
background-color: #ff9800;
font-weight: bold;

border-radius: 16px;
border-radius: 4px;
}
.am-button.security-am .am-monitor__count {
color: #fff;
background-color: var(--error-color);
background-color: #dc3545;
}
.am-container div.am-list {
position: absolute;
top: 48px;
right: 2%;
height: auto;
padding: var(--section-padding);
z-index: 0;
padding: 2em;
text-align: left;
display: block;
background-color: #fff;
background-color: var(--background);
box-shadow: var(--dropdown-box-shadow);
transition: var(--standard-transition);
border-radius: 15px;
border-radius: 5px;

/* Darken the box shadow to make the popup visible over the search box */
box-shadow: 0 1px 7px 0 rgba(0, 0, 0, 0.3);

transition: all 0.15s cubic-bezier(0.84, 0.03, 0.21, 0.96);
opacity: 0;
transform: translateY(-10px) scale(0.975);
z-index: 1000;
transform: scale(0);
}
.am-container.visible div.am-list {
opacity: 1;
transform: scale(1);
z-index: 1000;
}
.am-container.visible .am-button {
background-color: #404040;
background-color: var(--header-link-bg-classic-active);
text-decoration: none;
}
.am-container .am-button:after {
content: "";
display: inline-block;
position: absolute;
bottom: 0;
left: 32%;
width: 0;
height: 0;
border-left: 7px solid transparent;
border-right: 7px solid transparent;
border-bottom: 7px solid #fff;
opacity: 0;
transition-property: all;
transition-delay: 0s;
z-index: 1001;
}
.am-container.visible .am-button:after {
opacity: 1;
transition-property: all;
transition-delay: 0.15s;
}
.am-container .am-message {
display: block;
line-height: 1.4em;
margin-bottom: 1.4em;
}
.am-container.visible .am-button:after {
background: var(--button-background--hover);
}

.am-message-list {
padding: 0;
margin: 0;
}

.am-container .am-message .alert form {
Expand All @@ -96,37 +123,45 @@
/* Restore hyperlink style overriden by the page header */
.am-container .am-list a:link {
display: inline-block;
color: #204a87;
color: var(--link-color);
text-decoration: underline;
margin-right: 0;
padding: 0;
font-weight: 600;
font-weight: var(--link-font-weight);
}
.am-container .am-list a:visited {
color: #5c3566;
color: var(--link-color);
}
.am-container .am-list a:hover,
.am-container .am-list a:focus,
.am-container .am-list a:active {
color: #5c3566;
color: var(--link-color);
background-color: transparent;
text-decoration: underline;
text-decoration: var(--link-text-decoration--hover);
}

.am-container .am-list .alert-success a {
color: #155724;
color: var(--alert-success-text-color);
}

.am-container .am-list .alert-info a {
color: #31708f;
color: var(--alert-info-text-color);
}

.am-container .am-list .alert-warning a {
color: #8a6d3b;
color: var(--alert-warning-text-color);
}

.am-container .am-list .alert-danger a {
color: #a94442;
color: var(--alert-danger-text-color);
}

Expand Down
40 changes: 28 additions & 12 deletions war/src/main/scss/components/_page-header.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
@use "../abstracts/mixins";

.page-header {
display: flex;
align-items: center;
Expand Down Expand Up @@ -38,30 +36,46 @@ a.page-header__brand-link {
}

.page-header__am-wrapper {
display: contents;
height: 100%;
padding: 0.5rem 0;
}

.page-header__hyperlinks {
display: flex;
align-items: center;
}

.page-header__hyperlinks > a,
.am-container > a {
@include mixins.item;

.page-header__hyperlinks a {
--text-color: var(--header-link-color);

display: inline-flex;
align-items: center;
color: var(--text-color);
text-decoration: none;

// need to override an existing rule
/* stylelint-disable declaration-block-no-shorthand-property-overrides */
padding-right: 0.5rem;
padding: 0.5rem;
margin-right: 0 !important;
font-weight: bold;

&:link,
&:visited {
color: var(--header-link-color);
border-radius: var(--header-item-border-radius);
text-decoration: none;
}

&::before,
&::after {
inset: 0 !important;
&:hover,
&:focus,
&.mouseIsOverMenuSelector {
color: var(--header-link-color-active);
background-color: var(--header-link-bg-classic-hover);
text-decoration: underline;
text-decoration-color: var(--header-link-color-active);
}

&:active {
background-color: var(--header-link-bg-classic-active);
}

.jenkins-menu-dropdown-chevron {
Expand All @@ -77,6 +91,8 @@ a.page-header__brand-link {
}

.page-header__hyperlinks a span {
font-weight: bold;

&:not(:first-child) {
margin-left: 0.25rem;
}
Expand Down

0 comments on commit 0543bdf

Please sign in to comment.