Skip to content

Commit ad0ab44

Browse files
authored
fix: scrollbar sizing (#20)
* components: select/textarea: style scroll bar * style: all: update scroll bar
1 parent 1b268a3 commit ad0ab44

File tree

4 files changed

+34
-4
lines changed

4 files changed

+34
-4
lines changed

src/components/sdpi-item.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ export class SdpiItem extends LitElement {
1212
hostStyle,
1313
css`
1414
::-webkit-scrollbar {
15-
width: 5px;
15+
width: 8px;
16+
height: 8px;
1617
}
1718
::-webkit-scrollbar-track {
1819
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
@@ -21,7 +22,6 @@ export class SdpiItem extends LitElement {
2122
::-webkit-scrollbar-thumb {
2223
background-color: #666666;
2324
border-radius: 5px;
24-
outline: 1px solid slategrey;
2525
}
2626
2727
.container {

src/components/select.ts

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,21 @@ export class Select extends Persisted(
3232
opacity: var(--opacity-disabled);
3333
}
3434
35+
::-webkit-scrollbar {
36+
width: 8px;
37+
height: 8px;
38+
}
39+
40+
::-webkit-scrollbar-track {
41+
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
42+
box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
43+
}
44+
45+
::-webkit-scrollbar-thumb {
46+
background-color: #666666;
47+
border-radius: 5px;
48+
}
49+
3550
.refresh {
3651
background: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGhlaWdodD0iMTgiIHdpZHRoPSIxOCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSIjOUM5QzlDIj48cGF0aCBkPSJNMTIgMjBxLTMuMzUgMC01LjY3NS0yLjMyNVE0IDE1LjM1IDQgMTJxMC0zLjM1IDIuMzI1LTUuNjc1UTguNjUgNCAxMiA0cTEuNzI1IDAgMy4zLjcxMyAxLjU3NS43MTIgMi43IDIuMDM3VjRoMnY3aC03VjloNC4ycS0uOC0xLjQtMi4xODctMi4yUTEzLjYyNSA2IDEyIDYgOS41IDYgNy43NSA3Ljc1VDYgMTJxMCAyLjUgMS43NSA0LjI1VDEyIDE4cTEuOTI1IDAgMy40NzUtMS4xVDE3LjY1IDE0aDIuMXEtLjcgMi42NS0yLjg1IDQuMzI1UTE0Ljc1IDIwIDEyIDIwWiIvPjwvc3ZnPg==)
3752
no-repeat -1px -1px;

src/components/textarea.ts

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,21 @@ export class Textarea extends Persisted(Focusable(Input<typeof LitElement, strin
3131
font-family: var(--font-family);
3232
font-size: var(--font-size);
3333
}
34+
35+
::-webkit-scrollbar {
36+
width: 8px;
37+
height: 8px;
38+
}
39+
40+
::-webkit-scrollbar-track {
41+
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
42+
box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
43+
}
44+
45+
::-webkit-scrollbar-thumb {
46+
background-color: #666666;
47+
border-radius: 5px;
48+
}
3449
`,
3550
];
3651
}

src/styles/document.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ style.innerHTML = css`
1111
background-color: #2d2d2d;
1212
}
1313
::-webkit-scrollbar {
14-
width: 5px;
14+
width: 8px;
15+
height: 8px;
1516
}
1617
::-webkit-scrollbar-track {
1718
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
@@ -20,7 +21,6 @@ style.innerHTML = css`
2021
::-webkit-scrollbar-thumb {
2122
background-color: #666666;
2223
border-radius: 5px;
23-
outline: 1px solid slategrey;
2424
}
2525
`.cssText;
2626

0 commit comments

Comments
 (0)