Download
We're evolving to serve you better! This current forum has transitioned to read-only mode. For new discussions, support, and engagement, we've moved to GitHub Discussions.

How do I add more columns in theme “mercury”?

  • #6179
    Avatar photo[anonymous]

    Thanks for your work.

    How do I add more columns to the isotope grid?

    I figured out how I add an option to the config.json via an override?

    Where and how do I change the css?

    Thanks

    Daniel.

    #6182
    Avatar photo[anonymous]

    I have not tested this, but I think you can do this:

    (Do you want to do it nice or ugly?)
    Ugly: set the front page layout to 4 columns, and then go to line 1525 in mercury>assets>css>main.css and set your width.
    Nice: add your new option to the config.json and copy-past line 1513-1527 in the mentioned main.css and change the ‘–4’ ending to your new option value, and change the widths.

    But your font size will not change, maybe also take a look at line 1608-1643.

    This is in mercery v.2.2.0.0  and this is the lines in main.css:

    @media all and (min-width: 37.5em) {
      .l-col--4 > .c-card {
        width: 50%;
      }
    }
    @media all and (min-width: 56.25em) {
      .l-col--4 > .c-card {
        width: 33.333%;
      }
    }
    @media all and (min-width: 75em) {
      .l-col--4 > .c-card {
        width: 25%;
      }
    }
    
    ...
    
    
    .c-card__text > p {
      font-size: 0.624295077rem;
      letter-spacing: 0.09em;
      margin-top: 0.8rem;
      text-transform: uppercase;
    }
    .c-card__text > h2 {
      font-size: 1.125rem;
      line-height: 1.4;
      margin-top: 0.5333333333rem;
    }
    
    .c-card__text--compact > p {
      font-size: 0.624295077rem;
    }
    .c-card__text--compact > h2 {
      font-size: 0.8888888889rem;
      font-weight: 700;
      line-height: 1.3;
      margin-top: 0.5333333333rem;
    }
    #6192
    Avatar photo[anonymous]

    Thanks, that works

    #6689
    Avatar photo[anonymous]

    hi, noob question how do you access the theme files?

    #6691
    Avatar photoBob

    spicy.time wrote:

    hi, noob question how do you access the theme files?

    They are stored in this location: Documents ▸ ⁨Publii⁩ ▸ ⁨sites⁩ ▸ ⁨YOUR_SITE ▸ ⁨input⁩ ▸ ⁨themes⁩ ▸ ⁨YOUR_THEME

    To preserve your custom code and prevent it being overwritten the next time the theme is updated, please ensure that you have created override files; these are, essentially, copies of the existing theme files that are stored separately from the main theme fileshttps://getpublii.com/dev/theme-overrides/