MediaWiki:Mobile.css

From Cannabis
Jump to navigation Jump to search

Note: After saving, you may have to bypass your browser's cache to see the changes.

  • Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
  • Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
  • Internet Explorer / Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5
  • Opera: Go to Menu → Settings (Opera → Preferences on a Mac) and then to Privacy & security → Clear browsing data → Cached images and files.
/* IMPORT IS NO LONGER USED. CSS IS COPIED FROM COMMON.CSS 
/* http://cannabis.shoutwiki.com/wiki/MediaWiki:Common.css 
/*
/* To make mobile users load Common.css via import 
/* @import "/w/index.php?title=MediaWiki:Common.css&action=raw&ctype=text/css";
/* 
/* It can take hours for changes made to MediaWiki:Common.css to be imported to mobile view on PC.
/* https://www.mediawiki.org/wiki/Manual:Purge - does not help in speeding things up. 
/* Ctrl-F5, or null edits, or adding a space, or &action=purge. To here or other pages. Does not help.
/* Try adding a space at the end of the edit window. Does not help.
/* It is a null edit that can be used in mobile view. No history of it.
/* For mobile view of pages. None of the above works. 
/*
/* The only thing that works is waiting for hours. 
/* Desktop view CSS changes show up right away, or in around 5 minutes. 
/* Then wait hours for the changes to be imported, and show up in mobile view on PC. */
/*
/* To clear cache on mobile Safari on iphone for a specific site: open Settings, then click on Safari, then scroll down and click on Advanced, then click on Website Data you will get a list of websites that have stored data. You can click Edit then remove the data from just the sites that you want to remove stored data from. Info is from here: 
/* https://apple.stackexchange.com/questions/73153/how-to-clear-browser-cache-for-just-one-specific-site-in-mobile-safari 
/* Clear history, cache, data, and cookies from Safari on iPhone, iPad, or iPod touch. Go to Settings > Safari, and tap Clear History and Website Data. This won't change your AutoFill information. Info is from here: 
/* https://support.apple.com/en-us/HT201265 
/*
/* To see CSS changes on PCs be sure to use Ctrl-F5 on each page you want to see the change on. Whether desktop view on PC, or mobile view on PC. Using Ctrl-F5 only on the CSS page is often not enough. 
/*
/* Changes to COMMON.CSS show up right away in mobile view on PC, or in around 5 minutes. 
/* Versus hours sometimes via @import from Common.css to Mobile.css - 
/* More info on import problems: 
/* https://www.keycdn.com/blog/css-performance - 2018 article.
/* https://www.stevesouders.com/blog/2009/04/09/dont-use-import - 2009 article. */


/* ALL BELOW IS COPIED FROM COMMON.CSS */


/* === Collapsible elements. Toggle link moved to left. === 
/* Margins around it adjusted. 
/* https://community.fandom.com/wiki/Thread:1104268
/* https://community.wikia.com/wiki/Thread:499656 
/* https://community.wikia.com/wiki/Help:Collapsing 
/* https://cannabis.wikia.com/wiki/MediaWiki:Wikia.css 
/* https://community.fandom.com/f/p/4400000000003097153 
/* https://www.mediawiki.org/wiki/Manual:Collapsible_elements#Move_toggle_link_to_the_left */

.mw-collapsible span.mw-collapsible-toggle {
    float: left;
    margin-left: 0;
    margin-right: 1em;
}


/* === Make bullet color and color of brackets around "edit" same as text color. ===
/* http://cannabis.shoutwiki.com/wiki/User:Timeshifter/Sandbox23 
/* https://en.wikipedia.org/wiki/Wikipedia:Reference_desk/Computing#How_can_I_make_the_bullets_and_brackets_white_in_this_dark_background? 
/* https://developer.mozilla.org/en-US/docs/Web/CSS/unset */

ul {list-style-image: unset;}
h1,h2,h3,h4,h5,h6 {color: unset;}


/* === Black background. Used mainly for small divs and tables ===
/* Plain text color, and link color, are also set.
/* Allows use on the news list, news archive, and on multiple wikis. 
/* !important necessary on Shoutwiki and Wikia to override 
/* class=wikitable colors */

.blackbackground {
    background-color: black !important;
    color: white !important;
    padding: 3px;
}
.blackbackground a:link { color: lime !important; }
.blackbackground a:visited { color: palegreen !important; }

.blackbackground div.thumbinner {
    background-color: inherit; 
}
/* div.thumbinner is for background color 
/* for transparent images and image captions */


/* === Dark background color. Link colors too. ===
/* https://community.fandom.com/wiki/Thread:1666538 
/* https://cannabis.wikia.org/wiki/Template:News_list_beta/Sandbox  (protected).
/* https://cannabis.wikia.org/wiki/Template:News_list_beta/Sandbox2  (protected).
/* https://cannabis.wikia.org/wiki/Template:News_list_beta/Sandbox3 (unprotected).
/* https://htmldog.com/guides/css/intermediate/pseudoclasses
/* https://htmldog.com/guides/css/intermediate/classid
/* https://en.wikipedia.org/wiki/Web_colors
/* Clear recent history to reset all links to unvisited color.
/* https://cannabis.wikia.org/wiki/Special:ThemeDesigner 
/* Theme designer colors can be found via these methods:
/* Link text: Firefox > tools menu > web developer > eye dropper. 
/* a:visited color in Qualaroo.css file from page save. 
/* Used class=darkbackground here: 
/* http://cannabis.shoutwiki.com/wiki/Template:News_list 
/* Heading color CSS info:
/* http://cannabis.shoutwiki.com/wiki/User:Timeshifter/Sandbox23 */

.darkbackground {
    background-color: maroon !important;
    color: white !important;
    padding: 3px;
}
.darkbackground a:link { color: lime !important; }
.darkbackground a:visited { color: palegreen !important; }

.darkbackground div.thumbinner {
    background-color: inherit; 
}
/* div.thumbinner is for background color 
/* for transparent images and image captions */



/* === Dark background 2. class=darkbackground2. ===
/* It is not working on iPhone SE 2020 cell phone. 
/* On both "full site" or "mobile" setting. 
/* On Roswell template. */
.darkbackground2 {
    background-color: darkviolet !important;
    color: white !important;
    padding: 3px;
}
.darkbackground2 a:link { color: lime !important; }
.darkbackground2 a:visited { color: palegreen !important; }

.darkbackground2 div.thumbinner {
    background-color: inherit; 
}
/* div.thumbinner is for background color 
/* for transparent images and image captions */



/* === Yellow background. class=yellowbackground. === 
/* https://en.wikipedia.org/wiki/Help:Link_color */

.yellowbackground {
    background-color: yellow !important;
    color: black !important;
    padding: 3px;
}
.yellowbackground a:link { color: blue !important; }
.yellowbackground a:visited { color: blue !important; }

.yellowbackground div.thumbinner {
    background-color: inherit; 
}
/* div.thumbinner is for background color 
/* for transparent images and image captions */



/* === Long image filenames in categories, etc. === 
/* Long filenames are the default setting on the Commons. Via a default gadget.
/* https://commons.wikimedia.org/wiki/Special:Preferences#mw-prefsection-gadgets 
/* https://commons.wikimedia.org/wiki/Special:Gadgets 
/* https://commons.wikimedia.org/wiki/MediaWiki:Gadget-Long-Image-Names-in-Categories.css 
/* More info: http://www.shoutwiki.com/wiki/Forum:Long_image_names_in_categories */

/* Long filenames on category pages */
#mw-category-media .galleryfilename-truncate,
/* Long filenames on special pages (new files etc.) */
.ns-special .galleryfilename-truncate {
    white-space: normal; 
    overflow: visible;
    display: inline;
}

#mw-category-media .galleryfilename-truncate:after,
.ns-special .galleryfilename-truncate:after {
    content: '\A';
    white-space: pre;
    white-space: pre-wrap; /* Workaround for Chromium bug which seems to apply the rule to the whole line, breaking text wrapping with 'pre' */
}



/* === Easy method of auto numbering of table rows === 
/* Just add class="sortable autonumber" to top line of table wikitext.
/* This is Yair_rand's CSS (slightly adapted). See his CSS and comment: 
/* See https://phabricator.wikimedia.org/T42618#434018 */

  table.autonumber > tbody {
    counter-reset: autonumbering;
  }
  table.autonumber > tbody > tr::before {
    counter-increment: autonumbering;
    content: counter(autonumbering);
  }
  table.autonumber > thead > tr::before {
    content: " ";
  }
  table.autonumber > thead > tr::before, table.autonumber > tbody > tr::before
{
    display: table-cell;
    padding: 0.2em;
    border: 1px solid;
    vertical-align: middle;
    text-align: center;
  }



/* === Automatic row numbering of some tables === 
/* This is the hard method. 
/* This method is no longer used here except in tests, sandboxes, etc.. 
/* This CSS is kept mainly so old revisions work for showing others. 
/* For example: 
/* http://cannabis.shoutwiki.com/w/index.php?title=2014list&oldid=21668 
/* http://cannabis.shoutwiki.com/w/index.php?title=GMMcities&oldid=6398
/* Add class=rownumber to top line of table. 
/* Add class=rownumber-value to first cell in each row. 
/* Info: en.wikipedia.org/wiki/User:Timeshifter/Sandbox33 
/* https://phabricator.wikimedia.org/T42618 */
 
table.rownumber {
        counter-reset: tablerownumber;
}
table.rownumber td.rownumber-value:before {
        content: counter(tablerownumber);
        counter-increment: tablerownumber;
}



/* === CSS below is for the Casebook page, and is from here: ===
/* https://web.archive.org/web/20110317003137/https://open.umich.edu/wiki/MediaWiki:Common.css 
/* Casebook: http://cannabis.shoutwiki.com/wiki/Casebook */

.greenSection { 

  border:1px solid #B8ec00;
 background:#F9FFEE;
 vertical-align:top; 
 color:#000;
 padding:0.5em 0.5em;
 -moz-border-radius: 15px;
 border-radius: 15px;

} 

.greenHeader { 

  margin:0; 
 background:#99CC9C; 
 font-size:120%; 
 font-weight:bold; 
 border:1px solid #B8ec00; 
 text-align:left; 
 color:#000; 
 padding:0.2em 0.4em;
 -moz-border-radius: 15px;
 border-radius: 15px;

} 

.yellowSection { 

  border:1px solid #FFF000; 
 background:#FFFFEE; 
 vertical-align:top; 
 color:#000;
 padding:0.5em 0.5em;
 -moz-border-radius: 15px;
 border-radius: 15px;

} 

.yellowHeader { 

  margin:0; 
 background:#FFFFCC; 
 font-size:120%; 
 font-weight:bold; 
 border:1px solid #FFF000; 
 text-align:left; 
 color:#000; 
 padding:0.2em 0.4em;
 -moz-border-radius: 15px;
 border-radius: 15px;

} 

.blueSection { 

  border:1px solid #95d0fc;
 background:#EEF6FF; 
 vertical-align:top;
 color:#000; 
 padding:0.5em 0.5em;
 -moz-border-radius: 15px;
 border-radius: 15px;

} 

.blueHeader { 

  margin:0; 
 background:#CCE5FE; 
 font-size:120%; 
 font-weight:bold; 
 border:1px solid #95d0fc; 
 text-align:left; 
 color:#000; 
 padding:0.2em 0.4em;
 -moz-border-radius: 15px;
 border-radius: 15px;

} 

.graySection { 

  border:1px solid #777777;
 background:#dddddd; 
 vertical-align:top;
 color:#000; 
 padding:0.5em 0.5em;
 -moz-border-radius: 15px;
 border-radius: 15px;

} 

.grayHeader { 

  margin:0; 
 background:#bbbbbb; 
 font-size:120%; 
 font-weight:bold; 
 border:1px solid #444444; 
 text-align:left; 
 color:#000; 
 padding:0.2em 0.4em;
 -moz-border-radius: 15px;
 border-radius: 15px;

} 

.orangeSection { 

  border:1px solid #ff7722;
 background:#FFCC99; 
 vertical-align:top;
 color:#000; 
 padding:0.5em 0.5em;
 -moz-border-radius: 15px;
 border-radius: 15px;

} 

.orangeHeader { 

  margin:0; 
 background:#FF9657; 
 font-size:120%; 
 font-weight:bold; 
 border:1px solid #ff7722; 
 text-align:left; 
 color:#000; 
 padding:0.2em 0.4em;
 -moz-border-radius: 15px;
 border-radius: 15px;

} 

.generated-sidebar, .portlet h5 { 

   font-weight:bold; 

}

/* end of Casebook CSS */