• Resolved knireis

    (@knireis)


    Hi,

    I managed to get the first colum in responsive view to have a color with opacity set:
    .tablepress-responsive-all thead tr,
    .tablepress-responsive-all thead th,
    .tablepress-responsive-all tbody td {
    background-color: rgba(255,0,102,0.1);
    }

    Same when I hover over the colums:
    .tablepress .row-hover tr:hover td {
    background-color: rgba(196,214,186,0.1);
    }

    But i can’t figure out the css to set the opacity on the alternating columns for the table.

    Can you help out?

    https://wordpress.org/plugins/tablepress/

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    thanks for your post, and sorry for the trouble.

    Something like

    .tablepress .odd td {
    	background-color: rgba(255,0,102,0.1);
    }
    .tablepress .even td {
    	background-color: rgba(196,214,186,0.1);
    }

    should work here.

    (Note that you should also set a fallback color for browsers that don’t support rgba colors, by prepending a hex color, like

    .tablepress .row-hover tr:hover td {
      background-color: #ff0000;
      background-color: rgba(196,214,186,0.1);
    }

    (where the hex color is similar to the desired color).

    Regards,
    Tobias

    Thread Starter knireis

    (@knireis)

    great, thanks

    Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    no problem, you are very welcome! 🙂 Good to hear that this helped!

    Best wishes,
    Tobias

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘opacity table background’ is closed to new replies.