Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enhancement(#2351):Adopt uPortal CSS Variables for Web Components to Simplify Skin Management #2860

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 25 additions & 5 deletions uPortal-webapp/src/main/webapp/css/search/autosuggest.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* for additional information regarding copyright ownership.
* Apereo licenses this file to you under the Apache License,
* Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a
* except in compliance with the License. You may obtain a
* copy of the License at the following location:
*
* http://www.apache.org/licenses/LICENSE-2.0
Expand All @@ -16,25 +16,35 @@
* specific language governing permissions and limitations
* under the License.
*/

/* Define CSS variables in :root and map them to LESS variables */
:root {
--portlet-header-text-color: @portlet-titlebar-link-color; /* CSS variable that references a LESS variable */
--portlet-content-bg-color: #d0d0d0; /* Define background color */
}

/* UI Autocomplete Styles */
.ui-autocomplete.ui-menu {
padding: 0;
overflow: hidden;
}

.ui-autocomplete li {
list-style: none;
max-width: 315px; /* Fixes Autocomplete on 1st search after page render would have very wide results box off side of window */
/*max-height: 75px;*/ /* Limiting # of chars sent tends to keep description to 2 lines in autocomplete results so don't need max-height. */
overflow:hidden;
max-width: 315px; /* Fixes wide results box issue */
overflow: hidden;
}

.ui-autocomplete .ui-menu-item a {
border-bottom: 1px solid #efefef;
border-bottom: 1px solid var(--portlet-header-text-color);
padding: .5em;
}

.ui-autocomplete .ui-menu-item a:hover {
cursor: pointer;
}

/* focused state styling */
.ui-autocomplete a.ui-state-focus .autocomplete-header {
color: #fff;
}
Expand All @@ -44,12 +54,22 @@
background: rgb(62, 70, 79);
color: #fff;
}

.ui-autocomplete a.ui-corner-all {
-webkit-border-radius: 0 0 0 0;
border-radius: 0 0 0 0;
}

.ui-autocomplete .autocomplete-header {
font-weight: 800;
color: rgb(123, 34, 64);
}

/* Link Styles */
a {
color: var(--portlet-header-text-color); /* Link color using the CSS variable */
}

a:hover {
color: darken(var(--portlet-header-text-color), 20%); /* Darken the CSS variable on hover */
}