-
Notifications
You must be signed in to change notification settings - Fork 93
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
Issue1347 malihu custom scrollbar fix #1360
Issue1347 malihu custom scrollbar fix #1360
Conversation
Codecov ReportBase: 70.68% // Head: 70.68% // No change to project coverage 👍
Additional details and impacted files@@ Coverage Diff @@
## upgrade-jquery-3.6 #1360 +/- ##
=====================================================
Coverage 70.68% 70.68%
Complexity 1646 1646
=====================================================
Files 32 32
Lines 3786 3786
=====================================================
Hits 2676 2676
Misses 1110 1110 Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haven't tested it but looked at the code from GH UI and it's looking really good!!! One minor comment.
resource/css/styles.css
Outdated
--scrollbarWidth: 14px; | ||
--scrollbarBg: #b9c1c6; | ||
--scrollbarThumb: #474b4f; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file already has a :root block elsewhere with colors, font sizes, etc. Maybe worth keeping the root variables all in a single place.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep. And the variable names should be brought in line with the naming and conventions of the other css variables. To nudge this in the right direction, the beginning of the :root element in styles.css could look like this, with the corresponding changes for the variable names in styles.css row 2237 onwards:
:root {
/* Color definitions */
--dark-color: #394554; /* topbar nav link text, dropdown text, buttons */
--secondary-dark-color: #3C535B; /* disabled buttons, bg of "content language" dropdown label in header */
--medium-color: #00748F; /* used for skosmos service name (top left logo), link texts (a), header bar, hovered dropdown menu items, placeholders in form input fields */
--light-color: #D4EDEB; /* used for concept property dividers */
--link-hover-color: #23527C; /* used for hovered links, clipboard icon */
--tooltip-bg-color: #1E1E1E;
--tooltip-text-color: #00ACD3;
--tooltip-border-color: #75889F; /*also used as typeahead focus border */
--main-bg-color: #D5DBDE;
--alert-color-pale: #D95F8A;
--alert-color-bright: #ED0D6C;
--uri-id-text-color: #006621; /* only used in search results */
--scroll-box-color: #474b4f; /* used for the sidebar scroll */
--scroll-bar-color: #b9c1c6; /* used for the sidebar scroll */
--scroll-bar-width: 14px; /* used for the sidebar scroll */
A new question/issue #1361 made after commit Sidebar active nav tab made unclickable. Making current tab inactive produces a feature that the previous tab is inactive as long as next tab content is loading. Is this feature bearable or a bug to be fixed? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- I made a couple of suggestions for tweaking the CSS jand JS
- The bigger issue seems to be that the nav tabs of the sidebar are now triggering full page loads instead of partial ones
- Also, the anchor of the hierarchy tab points to the Skosmos front page, omitting the vocabulary ID. It's not a big thing to change - but first and foremost the page load triggered by the nav tab change should be a partial one.
- This might also cause the problem with choosing another tab while the sidebar content is loading resulting in an empty concept info like this:
resource/css/styles.css
Outdated
--scrollbarWidth: 14px; | ||
--scrollbarBg: #b9c1c6; | ||
--scrollbarThumb: #474b4f; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep. And the variable names should be brought in line with the naming and conventions of the other css variables. To nudge this in the right direction, the beginning of the :root element in styles.css could look like this, with the corresponding changes for the variable names in styles.css row 2237 onwards:
:root {
/* Color definitions */
--dark-color: #394554; /* topbar nav link text, dropdown text, buttons */
--secondary-dark-color: #3C535B; /* disabled buttons, bg of "content language" dropdown label in header */
--medium-color: #00748F; /* used for skosmos service name (top left logo), link texts (a), header bar, hovered dropdown menu items, placeholders in form input fields */
--light-color: #D4EDEB; /* used for concept property dividers */
--link-hover-color: #23527C; /* used for hovered links, clipboard icon */
--tooltip-bg-color: #1E1E1E;
--tooltip-text-color: #00ACD3;
--tooltip-border-color: #75889F; /*also used as typeahead focus border */
--main-bg-color: #D5DBDE;
--alert-color-pale: #D95F8A;
--alert-color-bright: #ED0D6C;
--uri-id-text-color: #006621; /* only used in search results */
--scroll-box-color: #474b4f; /* used for the sidebar scroll */
--scroll-bar-color: #b9c1c6; /* used for the sidebar scroll */
--scroll-bar-width: 14px; /* used for the sidebar scroll */
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apparently the clunkier JS was working better so better leave it like it was. Also, the asynchronous page loading was broken due to mismatching jQuery version.
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
Reasons for creating this PR
Unmaintained Malihu scrollbar plugin outdated when jQuery gets updated to version 3.6
Link to relevant issue(s), if any
Description of the changes in this PR
Malihu scrollbar plugin removed and scrolling functionality done without any external libraries. This PR is partly based on @henriyli's previously closed PR of this issue: #1175.
Known problems or uncertainties in this PR
Checklist
.sr-only
class, color contrast)