Answers for "how to add scroll bar when overflow"

CSS
1

css show scrollbar if overflow

/*You can automatically show a scrollbar IF there is overflow with  this: */
body {
  overflow:auto;
}
/*If you want to always show a scrollbar, use this: */
body {
  overflow:scroll;
}
Posted by: Guest on April-18-2021
0

css change overflow scrollbar

::-webkit-scrollbar {
    width: 12px;
}

/* Track */
::-webkit-scrollbar-track {
    -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,0.3); 
    -webkit-border-radius: 10px;
    border-radius: 10px;
}

/* Handle */
::-webkit-scrollbar-thumb {
    -webkit-border-radius: 10px;
    border-radius: 10px;
    background: rgba(255,0,0,0.8); 
    -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,0.5); 
}
::-webkit-scrollbar-thumb:window-inactive {
    background: rgba(255,0,0,0.4); 
}
Posted by: Guest on December-26-2021

Code answers related to "how to add scroll bar when overflow"

Browse Popular Code Answers by Language