Quantcast
Channel: 《丢一枚ChromeOS滚动条样式脚本:ChromeOS scrollbars of Firefox》的评论
Viewing all articles
Browse latest Browse all 10

作者:97world

$
0
0

下面的代码能够简单实现自动隐藏滚动条
/*
****************************************************************
* — Created JUNE 21 2009 — By Barbie Foster *
* http://userstyles.org/users/13023 *
* TITLE: WEBPAGE Scrollbars ONLY – Autohide(No Empty Space)#2 *
* http://userstyles.org/styles/18874 *
****************************************************************
*/
/* !!! IMPORTANT:: !!! RELOAD WEBPAGE AND ANY TABS ALREADY OPENED AFTER INSTALLING THIS STYLE TO SEE THE RESULTS OF THIS STYLE and after Uninstalling or Disable YOU MUST DO A Firefox RESTART to REMOVE COMPLETELY*/

/*
ANOTHER CHOICE COMPATIBLE with OTHER WEBPAGE SCROLLBAR Styles:
WEBPAGE Scrollbars ONLY – Autohide
http://userstyles.org/styles/18646/webpage-scrollbars-only-autohide
*/

/*UPDATED: Nov 1 2011: WORKS WITH FF3.6 AND UP*/
/*UPDATED: May 17 20112: WORKS WITH FF12*/

@-moz-document url-prefix(http://),
url-prefix(https://) {

/*REMOVE THIS LINE TO ALWAYS SHOW TEXTBOX SCROLLBARS

body scrollbar[orient="vertical"],
body scrollbar[orient="vertical"] slider,
body scrollbar[orient="vertical"]:hover,
body scrollbar[orient="vertical"]:hover slider,
body scrollbar[orient="horizontal"],
body scrollbar[orient="horizontal"]:hover
{
opacity: 1 !important;
min-width: 10px !important;
max-width: 10px!important;}
/**/

/*@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@*/

/*TEXTBOX SCROLLBARS AUTOHIDE(EASY GRAB)*/
body scrollbar[orient="vertical"],
body scrollbar[orient="vertical"] slider,
body scrollbar[orient="vertical"]:hover,
body scrollbar[orient="vertical"]:hover slider,
body scrollbar[orient="horizontal"],
body scrollbar[orient="horizontal"]:hover
{min-width: 10px !important;
max-width: 10px!important;}

/*@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@*/

/* THIS WHOLE CODE SECTION AUTOHIDES ONLY THE VERTICAL SCROLLBARS OF WEBPAGES */
scrollbar[orient="vertical"]/*,scrollbar[orient="vertical"] slider*/
{
opacity: 0 !important;
min-width: 1px !important;
max-width: 1px !important;}
scrollbar[orient="vertical"] thumb, scrollbar[orient="vertical"] scrollbarbutton
{opacity: 0 !important;
min-width: 1px !important;
max-width: 1px !important;}

/*Default vertical scrollbar width is 10px */
scrollbar[orient="vertical"]:hover/*,scrollbar[orient="vertical"] slider:hover*/
{
opacity: 1 !important;
min-width: 10px !important;
padding-right: 0.4px !important;}
scrollbar[orient="vertical"]:hover thumb, scrollbar[orient="vertical"]:hover scrollbarbutton
{opacity: 1 !important;
min-width: 10px !important;
padding-right: 0.4px !important;}

/*@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@*/

/* THIS WHOLE CODE SECTION AUTOHIDES ONLY THE HORIZONTAL SCROLLBARS OF WEBPAGES */
/*can increase min-height 5px and max-height 5px to have more grab space for horizontal scrollbar (min-height and max-height must be exact same px)*/

scrollbar[orient="horizontal"]
{
opacity: 0 !important;
min-height: 2px !important;
max-height: 2px !important;}

/* Default horizontal height is 10px */
scrollbar[orient="horizontal"]:hover
{
opacity: 1 !important;
min-height: 10px !important;
max-height: 10px !important;
padding-bottom: 1px !important;}

/*@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@*/

/* REMOVES THE SCROLLBAR CORNERS THAT CAN BE SEEN ON DARK COLORED WEBPAGES */

scrollcorner{opacity: 0 !important;}
scrollbar scrollcorner:hover {background:transparent !important;}

/*@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@*/

/*PREVENTS AFFECTING THE SELECT BOX DROPDOWN ARROW*/
select scrollbar[orient="vertical"],
select scrollbar[orient="vertical"]:hover
{
opacity: 1 !important;
min-width: 10px !important;
max-width: 10px!important;}

/*@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@*/

}
/*END*/


Viewing all articles
Browse latest Browse all 10

Latest Images

Trending Articles





Latest Images