Skip to content

Commit a661e82

Browse files
authored
chore: align scrollbar styles to latest VD (#11512)
Fixes: #11507
1 parent 291b4dc commit a661e82

File tree

4 files changed

+5
-44
lines changed

4 files changed

+5
-44
lines changed

packages/base/src/util/getEffectiveScrollbarStyle.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ const getEffectiveScrollbarStyle = () => {
66
return "";
77
}
88

9-
return `::-webkit-scrollbar:horizontal {
9+
return `
10+
::-webkit-scrollbar:horizontal {
1011
height: var(--sapScrollBar_Dimension);
1112
}
1213
@@ -22,6 +23,7 @@ const getEffectiveScrollbarStyle = () => {
2223
::-webkit-scrollbar-thumb {
2324
border-radius: var(--sapElement_BorderCornerRadius);
2425
background-color: var(--sapScrollBar_FaceColor);
26+
border: 0.125rem solid var(--sapScrollBar_TrackColor);
2527
}
2628
2729
::-webkit-scrollbar-thumb:hover {

packages/fiori/src/NavigationLayout.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import customElement from "@ui5/webcomponents-base/dist/decorators/customElement
33
import property from "@ui5/webcomponents-base/dist/decorators/property.js";
44
import slot from "@ui5/webcomponents-base/dist/decorators/slot.js";
55
import jsxRenderer from "@ui5/webcomponents-base/dist/renderer/JsxRenderer.js";
6-
import browserScrollbarCSS from "@ui5/webcomponents/dist/generated/themes/BrowserScrollbar.css.js";
6+
import getEffectiveScrollbarStyle from "@ui5/webcomponents-base/dist/util/getEffectiveScrollbarStyle.js";
77
import {
88
isPhone,
99
isTablet,
@@ -50,7 +50,7 @@ import NavigationLayoutCss from "./generated/themes/NavigationLayout.css.js";
5050
languageAware: true,
5151
renderer: jsxRenderer,
5252
styles: [
53-
browserScrollbarCSS,
53+
getEffectiveScrollbarStyle(),
5454
NavigationLayoutCss,
5555
],
5656
template: NavigationLayoutTemplate,

packages/main/src/themes/BrowserScrollbar.css

Lines changed: 0 additions & 25 deletions
This file was deleted.

packages/main/src/themes/TextArea.css

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -422,22 +422,6 @@
422422
border-bottom-right-radius: var(--sapField_BorderCornerRadius);
423423
}
424424

425-
:host([value-state="Negative"]) .ui5-content-custom-scrollbars ::-webkit-scrollbar {
426-
background-color: var(--sapScrollBar_TrackColor);
427-
}
428-
429-
:host([value-state="Critical"]) .ui5-content-custom-scrollbars ::-webkit-scrollbar {
430-
background-color: var(--sapScrollBar_TrackColor);
431-
}
432-
433-
:host([value-state="Information"]) .ui5-content-custom-scrollbars ::-webkit-scrollbar {
434-
background-color: var(--sapScrollBar_TrackColor);
435-
}
436-
437-
:host([value-state="Positive"]) .ui5-content-custom-scrollbars ::-webkit-scrollbar {
438-
background-color: var(--sapScrollBar_TrackColor);
439-
}
440-
441425
:host([focused]) .ui5-content-custom-scrollbars ::-webkit-scrollbar {
442426
background-image: none;
443427
}

0 commit comments

Comments
 (0)