2016-09-17 174 views
1

我讀過類似堆棧溢出的許多問題,並沒有發現有類似於我的問題的任何人。我不知道我做錯了什麼。 (如果我做錯了什麼)我希望你能幫忙。Chrome擴展未注入css

我想要做的是注入css到網站minds.com使用鉻擴展名。問題是它不是注射。我不認爲它只是那個網站,因爲我已經嘗試了另一個。

清單文件:

{ 
    "manifest_version": 2, 

    "name": "My Style", 
    "description": "None", 
    "version": "0.3", 

    "content_scripts": [{ 
    "matches": ["http://www.minds.com/*"], 
    "css": ["my-style.css"], 
    "run_at": "document_start" 
    }] 
} 

CSS

html{ 
      color: #cacaca; 
      } 
      .mdl-card{ 
      background: rgba(0,0,0,0.64) !important; 
      color: #fff !important; 
      } 
      /*header*/ 
      .mdl-color--white{ 
      background: linear-gradient(#000, #333) !important; 
      } 
      .mdl-color--blue-grey-800 { 
      background-color: #121212 !important; 
      } 
      /*text*/ 
      .mdl-color-text--blue-grey-500 { 
      color: #cacaca !important; 
      } 
      minds-activity.mdl-card .mdl-card__supporting-text, minds-activity .mdl-card__supporting-text { 
      color: #aaa !important; 
      } 

      .minds-avatar { 
      background: rgba(0,0,0,0.0) !important; 
      } 
      .mdl-card .m-owner-block { 
      background: rgba(0,0,0,0.6) !important; 
      } 
      .m-owner-block a{ 
      color: #cacaca !important; 
      } 
      .minds-dropdown-menu{ 
      background: rgba(0,0,0,0.5) !important; /* 
      box-shadow: 0px 9px 0px !important;*/ 
      } 
      .mdl-menu__item{ 
      color: #fff !important; 
       box-shadow: 0px 0px 9px !important; 
      } 
      .mdl-color--blue-grey-50 { 
      background: rgba(0,0,0,0.6) !important; 
      } 
      .mdl-color-text--blue-grey-900 { 
      color: #78ad56 !important; 
      } 
      /*BG*/ 

      .mdl-color--grey-100 { 
      background: url("http://powerpictures.crystalgraphics.com/photo/seamless_black_circuit_board_pattern_cg5p0977241c_th2.jpg") !important; 
      } 
      /*Blogs*/ 
      .m-title-block, .m-title-block-fixed { 
      background: rgba(0,0,0,0.9) !important; 
      } 
      /*usercard*/ 
      .m-discovery-suggested .mdl-cell minds-card-user .m-usercard-bio { 
      color: #aaa !important; 
      } 
      /*active tab*/ 
      .mdl-color--blue-grey-600 { 
      background-color: #333 !important; 
      } 
      .mdl-card__title{ 
      color: #fff !important; 
      } 
      .mdl-button{ 
      color: #acacac !important; 
      } 
      minds-gatherings .minds-gatherings-search{ 
      background: rgba(0,0,0,0.6) !important; 
      color: #aaa !important; 
      } 
      h1{ 
      color: #fff !important; 
      } 
      .mdl-tabs__tab{ 
      color: #fff !important; 
      text-shadow: 0px 0px 9px #000 !important; 
      } 
      .mdl-menu__outline { 
      background: rgba(0,0,0,0.7) !important; 
      } 
      .mdl-menu__item:hover{ 
      background: rgba(20,20,20,0.6) !important; 
      color: #fff !important; 
      } 
      .mdl-card__supporting-text textarea{ 
      color: #aaa !important; 
      } 
      body a{ 
      color: #21CE54 !important; 
      } 
      minds-blog-view{ 
      background: url("http://powerpictures.crystalgraphics.com/photo/seamless_black_circuit_board_pattern_cg5p0977241c_th2.jpg") !important;  
      } 
      minds-comments form textarea{ 
      color: #aaa !important; 
      } 
      .mdl-grid { 
      background: rgba(0,0,0,0.6); 
      } 
      .minds-blog-body p{ 
      color: #fff !important; 
      } 
      .m-h1-input { 
      color: #cacaca !important; 
      } 

回答