Skip to main content
Bounty Awarded with 100 reputation awarded by Martin Vegter
!important
Source Link
tansy
  • 769
  • 4
  • 7

If nothing else works you may need to use some kind of extension after all. Based on this issue and this answer and this one I did that:

$ mkdir CustomCSS && cd CustomCSS
$ cat > manifest.json << EOF
 
{
    "name": "My Style Sheet",
    "content_scripts": [
        {
          "matches": ["*://*/*"],
          "css": ["Custom.css"]
        }
    ],
    "version": "1.0.0",
    "description": "User StyleSheet replacement",
    "manifest_version": 2
}
EOF
$ cat > Custom.css << EOF
 
::-webkit-scrollbar {
    height: 12px;
    width: 12px;
    background: yellow;
}
 
::-webkit-scrollbar-thumb {
    background: red;
    -webkit-border-radius: 1ex;
    -webkit-box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.75);
}
 
::-webkit-scrollbar-corner {
    background: #000;
}
EOF

In chrome://extensions with developer mode on: Load unpacked extension -> choose path/to/CustomCSS

And that's it. It works. Red scroll bar on yellow background.

Checking chrome://memory reveals it uses ~1.8MiB of memory.

--

Ed: If you want to override websites' styles you may try to use !important rule

background: red !important;

If nothing else works you may need to use some kind of extension after all. Based on this issue and this answer and this one I did that:

$ mkdir CustomCSS && cd CustomCSS
$ cat > manifest.json << EOF
 
{
    "name": "My Style Sheet",
    "content_scripts": [
        {
          "matches": ["*://*/*"],
          "css": ["Custom.css"]
        }
    ],
    "version": "1.0.0",
    "description": "User StyleSheet replacement",
    "manifest_version": 2
}
EOF
$ cat > Custom.css << EOF
 
::-webkit-scrollbar {
    height: 12px;
    width: 12px;
    background: yellow;
}
 
::-webkit-scrollbar-thumb {
    background: red;
    -webkit-border-radius: 1ex;
    -webkit-box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.75);
}
 
::-webkit-scrollbar-corner {
    background: #000;
}
EOF

In chrome://extensions with developer mode on: Load unpacked extension -> choose path/to/CustomCSS

And that's it. It works. Red scroll bar on yellow background.

Checking chrome://memory reveals it uses ~1.8MiB of memory.

If nothing else works you may need to use some kind of extension after all. Based on this issue and this answer and this one I did that:

$ mkdir CustomCSS && cd CustomCSS
$ cat > manifest.json << EOF
 
{
    "name": "My Style Sheet",
    "content_scripts": [
        {
          "matches": ["*://*/*"],
          "css": ["Custom.css"]
        }
    ],
    "version": "1.0.0",
    "description": "User StyleSheet replacement",
    "manifest_version": 2
}
EOF
$ cat > Custom.css << EOF
 
::-webkit-scrollbar {
    height: 12px;
    width: 12px;
    background: yellow;
}
 
::-webkit-scrollbar-thumb {
    background: red;
    -webkit-border-radius: 1ex;
    -webkit-box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.75);
}
 
::-webkit-scrollbar-corner {
    background: #000;
}
EOF

In chrome://extensions with developer mode on: Load unpacked extension -> choose path/to/CustomCSS

And that's it. It works. Red scroll bar on yellow background.

Checking chrome://memory reveals it uses ~1.8MiB of memory.

--

Ed: If you want to override websites' styles you may try to use !important rule

background: red !important;
Mem consumption
Source Link
tansy
  • 769
  • 4
  • 7

If nothing else works you may need to use some kind of extension after all. Based on this issue and this answer and this onethis one I did that:

$ mkdir CustomCSS && cd CustomCSS
$ cat > manifest.json << EOF
 
{
    "name": "My Style Sheet",
    "content_scripts": [
        {
          "matches": ["*://*/*"],
          "css": ["Custom.css"]
        }
    ],
    "version": "1.0.0",
    "description": "User StyleSheet replacement",
    "manifest_version": 2
}
EOF
$ cat > Custom.css << EOF
 
::-webkit-scrollbar {
    height: 12px;
    width: 12px;
    background: yellow;
}
 
::-webkit-scrollbar-thumb {
    background: red;
    -webkit-border-radius: 1ex;
    -webkit-box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.75);
}
 
::-webkit-scrollbar-corner {
    background: #000;
}
EOF

In chrome://extensions with developer mode on: Load unpacked extension -> choose path/to/CustomCSS

And that's it. It works. Red scroll bar on yellow background.

Checking chrome://memory reveals it uses ~1.8MiB of memory.

If nothing else works you may need to use some kind of extension after all. Based on this issue and this answer and this one I did that:

$ mkdir CustomCSS && cd CustomCSS
$ cat > manifest.json << EOF
 
{
    "name": "My Style Sheet",
    "content_scripts": [
        {
          "matches": ["*://*/*"],
          "css": ["Custom.css"]
        }
    ],
    "version": "1.0.0",
    "description": "User StyleSheet replacement",
    "manifest_version": 2
}
EOF
$ cat > Custom.css << EOF
 
::-webkit-scrollbar {
    height: 12px;
    width: 12px;
    background: yellow;
}
 
::-webkit-scrollbar-thumb {
    background: red;
    -webkit-border-radius: 1ex;
    -webkit-box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.75);
}
 
::-webkit-scrollbar-corner {
    background: #000;
}
EOF

In chrome://extensions with developer mode on: Load unpacked extension -> choose path/to/CustomCSS

And that's it. It works. Red scroll bar on yellow background.

If nothing else works you may need to use some kind of extension after all. Based on this issue and this answer and this one I did that:

$ mkdir CustomCSS && cd CustomCSS
$ cat > manifest.json << EOF
 
{
    "name": "My Style Sheet",
    "content_scripts": [
        {
          "matches": ["*://*/*"],
          "css": ["Custom.css"]
        }
    ],
    "version": "1.0.0",
    "description": "User StyleSheet replacement",
    "manifest_version": 2
}
EOF
$ cat > Custom.css << EOF
 
::-webkit-scrollbar {
    height: 12px;
    width: 12px;
    background: yellow;
}
 
::-webkit-scrollbar-thumb {
    background: red;
    -webkit-border-radius: 1ex;
    -webkit-box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.75);
}
 
::-webkit-scrollbar-corner {
    background: #000;
}
EOF

In chrome://extensions with developer mode on: Load unpacked extension -> choose path/to/CustomCSS

And that's it. It works. Red scroll bar on yellow background.

Checking chrome://memory reveals it uses ~1.8MiB of memory.

Source Link
tansy
  • 769
  • 4
  • 7

If nothing else works you may need to use some kind of extension after all. Based on this issue and this answer and this one I did that:

$ mkdir CustomCSS && cd CustomCSS
$ cat > manifest.json << EOF
 
{
    "name": "My Style Sheet",
    "content_scripts": [
        {
          "matches": ["*://*/*"],
          "css": ["Custom.css"]
        }
    ],
    "version": "1.0.0",
    "description": "User StyleSheet replacement",
    "manifest_version": 2
}
EOF
$ cat > Custom.css << EOF
 
::-webkit-scrollbar {
    height: 12px;
    width: 12px;
    background: yellow;
}
 
::-webkit-scrollbar-thumb {
    background: red;
    -webkit-border-radius: 1ex;
    -webkit-box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.75);
}
 
::-webkit-scrollbar-corner {
    background: #000;
}
EOF

In chrome://extensions with developer mode on: Load unpacked extension -> choose path/to/CustomCSS

And that's it. It works. Red scroll bar on yellow background.