WordPress.org

Forums

WP Google Map Plugin
Bootstrap stylesheet interfering with Modernize theme (1 post)

  1. DaveyM
    Member
    Posted 11 months ago #

    I've installed version 2.3.0 of the Plugin and I'm using it with version 2.0 of the Modernize theme - http://themes.goodlayers.com/?theme=modernize

    I found that it broke the front-end, and the admin pages for the theme, due to the inclusion of the following lines in wp-google-map-plugin/css/bootstrap.css

    *,
    *:before,
    *:after {
      -webkit-box-sizing: border-box;
         -moz-box-sizing: border-box;
              box-sizing: border-box;
    }

    I have commented this block out and everything seems ok now. Is it actually required? This appears to be a very general piece of css for a plugin to be providing.

    I assume the bootstrap.css file that is included comes from a custom compilation using LESS to prepend most of the lines with .wpgmp-wrap (or something like that), but combing through it I noticed quite a few other lines without such a prefix and wonder what other problems could be thrown up by it.

    For example:

    Lines 174 - 217

    * {
        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;
      }
      @page  {
        margin: 2cm .5cm;
      }
      p,
      .wpgmp-wrap h2,
      .wpgmp-wrap h3 {
        orphans: 3;
        widows: 3;
      }

    Lines 222 - 224

    select {
        background: #fff !important;
      }

    Lines 230 - 238

    .wpgmp-wrap .table td,
      .table th {
        background-color: #fff !important;
      }
    
    .wpgmp-wrap .btn > .caret,
      .dropup > .btn > .caret {
        border-top-color: #000 !important;
      }

    Lines 248 - 252

    .wpgmp-wrap .table-bordered th,
      .table-bordered td {
        border: 1px solid #ddd !important;
      }
    }

    Lines 513 - 517

    .wpgmp-wrap .dl-horizontal dd:before,
      .dl-horizontal dd:after {
        display: table;
        content: " ";
      }

    and quite a lot more (nearly 50 overall). Is all of this CSS (6000+ lines in the file) actually required for the plugin? That feels like overkill to me, just for displaying a map.

    Thanks,
    David

    https://wordpress.org/plugins/wp-google-map-plugin/

Reply

You must log in to post.

About this Plugin

About this Topic