Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Search
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse

Lay Theme Forum

  1. Home
  2. Addons
  3. Carousel - Text Slide Background Color

Carousel - Text Slide Background Color

Scheduled Pinned Locked Moved Addons
4 Posts 3 Posters 1.9k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • E Offline
    E Offline
    extra-vitamins
    wrote on last edited by
    #1

    Re: Carousel : Style Text Slides?

    Hi @arminunruh,

    I was wondering if there's a way to change the background color of text slides so that each carousel has a different text slide color. The code from the thread above seems to work if I want all the text slides to be the same color, but is there a way to target specific slides so that they can be all different colors?

    Love the theme by the way :)

    Thanks!

    1 Reply Last reply
    0
    • arminunruhA Offline
      arminunruhA Offline
      arminunruh
      Global Moderator
      wrote on last edited by
      #2

      Thanks a lot extra-vitamins! :)

      So you can add an html class to any element in the gridder to target it specifically with your css. right click an element and choose "set html class and id". This way you could set different colors for different carousels.

      Now in the carousel, each slide has the html class of "lay-carousel-slide". Combined with the nth-child selector you can target your css to for example the second slide, third slide, etc https://developer.mozilla.org/en/docs/Web/CSS/:nth-child

      For example:

      .lay-carousel-slide:nth-child(2){
      background-color: green;
      }
      
      E 1 Reply Last reply
      0
      • arminunruhA arminunruh

        Thanks a lot extra-vitamins! :)

        So you can add an html class to any element in the gridder to target it specifically with your css. right click an element and choose "set html class and id". This way you could set different colors for different carousels.

        Now in the carousel, each slide has the html class of "lay-carousel-slide". Combined with the nth-child selector you can target your css to for example the second slide, third slide, etc https://developer.mozilla.org/en/docs/Web/CSS/:nth-child

        For example:

        .lay-carousel-slide:nth-child(2){
        background-color: green;
        }
        
        E Offline
        E Offline
        extra-vitamins
        wrote on last edited by
        #3

        @arminunruh That worked great, thank you!!

        1 Reply Last reply
        0
        • B Offline
          B Offline
          burnbrunet
          wrote on last edited by
          #4
          This post is deleted!
          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          I also code custom websites or custom Lay features.
          šŸ’æ Email me here: šŸ’æ
          info@laytheme.com

          Before you post:
          1. When using a WordPress Cache plugin, disable it or clear your cache.
          2. Update Lay Theme and all Lay Theme Addons
          3. Disable all Plugins
          4. Go to Lay Options → Custom CSS & HTML, click "Turn Off All Custom Code", click "Save Changes"

          This often solves issues you might run into

          When you post:
          1. Post a link to where the problem is
          2. Does the problem happen on Chrome, Firefox, Safari or iPhone or Android?
          3. If the problem is difficult to explain, post screenshots / link to a video to explain it
          Online Users
          _
          _flx
          Forgot your key, lost your files, need a previous Lay Theme or Addon version? Go to www.laykeymanager.com
          laytheme.com
          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Recent
          • Tags
          • Popular
          • Users
          • Search