Bootstrap Global style settings

Source: Internet
Author: User

Html

<!DOCTYPE HTML><HTML><Head><Metahttp-equiv= "Content-type"content= "text/html; charset=utf-8"><title>Global style</title><Linkrel= "stylesheet"href= "//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css"></Head><Body>      <!--Main Jumbotron for a primary marketing message or call to action -      <Divclass= "Jumbotron">        <H1>Hello, world!.</H1>        <P>This was a template for a simple marketing or informational website. It includes a large callout called a Jumbotron and three supporting pieces of content. Use it as a starting point to create something more unique.</P>        <P><ahref="#" >Learn more»</a></P>      </Div>    </Body></HTML>

Css

HTML{font-family:Sans-serif;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%;}Body{margin:0;}article,aside,details,figcaption,figure,footer,header,hgroup,main,nav,section,summary{Display:Block;}Audio,canvas,progress,video{Display:Inline-block;vertical-align:Baseline;}Audio:not ([controls]){Display:None;Height:0;}[Hidden],template{Display:None;}a{background:Transparent;}A:active,a:hover{Outline:0;}Abbr[title]{Border-bottom:1px dotted;}B,strong{Font-weight:Bold;}DFN{Font-style:Italic;}H1{margin:. 67em 0;font-size:2em;}Mark{Color:#000;background:#ff0;}Small{font-size:80%;}Sub,sup{position:relative;font-size:75%;Line-height:0;vertical-align:Baseline;}sup{Top:-.5em;}Sub{Bottom:-.25em;}img{Border:0;}svg:not (: root){Overflow:Hidden;} Figure{margin:1em 40px;}HR{Height:0;-moz-box-sizing:Content-box;box-sizing:Content-box;}Pre{Overflow:Auto;}Code,kbd,pre,samp{font-family:monospace, monospace;font-size:1em;}Button,input,optgroup,select,textarea{margin:0;Font:Inherit;Color:Inherit;}Button{Overflow:Visible;}Button,select{Text-transform:None;}button,html input[type= "button"],input[type= "reset"],input[type= "submit"]{-webkit-appearance:Button;cursor:Pointer;}button[disabled],html input[disabled]{cursor:default;}Button::-moz-focus-inner,input::-moz-focus-inner{padding:0;Border:0;}input{Line-height:Normal;}input[type= "checkbox"],input[type= "Radio"]{box-sizing:Border-box;padding:0;}input[type= "number"]::-webkit-inner-spin-button,input[type= "number"]::-webkit-outer-spin-button{Height:Auto;}input[type= "Search"]{-webkit-box-sizing:Content-box;-moz-box-sizing:Content-box;box-sizing:Content-box;-webkit-appearance:TextField;}input[type= "Search"]::-webkit-search-cancel-button,input[type= "search"]::-webkit-search-decoration{-webkit-appearance:None;}fieldset{padding:. 35em. 625em. 75em;margin:0 2px;Border:1px solid #c0c0c0;}legend{padding:0;Border:0;}textarea{Overflow:Auto;}Optgroup{Font-weight:Bold;}Table{border-spacing:0;Border-collapse:collapse;}td,th{padding:0;}@media Print{* {color:#000!important;Text-shadow:None!important;background:Transparent!important;Box-shadow:None!important; }A, a:visited{text-decoration:Underline; }A[href]:after{content:" (" attr (HREF) ")"; }Abbr[title]:after{content:" (" attr (title) ")"; }a[href^= "javascript:"]:after, a[href^= "#"]:after{content: ""; }Pre, blockquote{Border:1px solid #999;Page-break-inside:Avoid; }thead{Display:Table-header-group; }TR, img{Page-break-inside:Avoid; }img{Max-width:100%!important; }p, H2, H3{Orphans:3;Widows:3; }H2, H3{Page-break-after:Avoid; }Select{background:#fff!important; }. NavBar{Display:None; }. table TD,. Table TH{Background-color:#fff!important; }. btn >. Caret,. dropup >. btn >. Caret{Border-top-color:#000!important; }. Label{Border:1px solid #000; }. Table{Border-collapse:collapse!important; }. table-bordered th,. table-bordered TD{Border:1px solid #ddd!important; }}

The bootstrap framework has made some changes in this section, instead of pursuing zeroing, but rather focusing on resetting the styles that might create problems (such as Body,form's margin, etc.), preserving and adhering to some of the browser's basic styles, solving some of the potential problems, and improving the experience of some details, Specify the following:

    • Remove a margin statement from body
    • Set body's background color to white
    • Basic font, font size, and line height are set for typesetting
    • Sets the global link color, and the underline style is displayed when the link is in the suspended: hover state

Bootstrap's global style uses "normalize.css", but does not blindly use this reset style, but on this basis, some improvements have been made to make it more suitable for bootstrap design ideas.

Bootstrap Global style settings

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.