Options

Lightbox - CSS to show first line of caption without hover

chris457chris457 Registered Users Posts: 17 Big grins
edited November 25, 2014 in SmugMug Customization
Took me a few minutes to find the best way to do this, so thought I'd share. This moves the title and caption up slightly so both the title and the first line of the caption can be seen without mouse hover. I adjusted the font size as well, but that's not required.

There's plenty of room for this, but by default it's down 10 pixels or so and cuts the first line of the caption in half.

The CSS:

/* Change Lightbox Title and Caption so first line can be seen without hover*/
.sm-lightbox-basic .yui3-widget-ft .sm-lightbox-title {
font-size: 16px;
position: relative;
bottom: 10px;
}

.sm-lightbox-basic .yui3-widget-ft .sm-lightbox-caption {
font-size: 12px;
position: relative;
bottom: 12px;
}

worldlikethis.com

Comments

  • Options
    jkingletjkinglet Registered Users Posts: 73 Big grins
    edited November 25, 2014
    chris457 wrote: »
    Took me a few minutes to find the best way to do this, so thought I'd share. This moves the title and caption up slightly so both the title and the first line of the caption can be seen without mouse hover. I adjusted the font size as well, but that's not required.

    There's plenty of room for this, but by default it's down 10 pixels or so and cuts the first line of the caption in half.

    The CSS:

    /* Change Lightbox Title and Caption so first line can be seen without hover*/
    .sm-lightbox-basic .yui3-widget-ft .sm-lightbox-title {
    font-size: 16px;
    position: relative;
    bottom: 10px;
    }

    .sm-lightbox-basic .yui3-widget-ft .sm-lightbox-caption {
    font-size: 12px;
    position: relative;
    bottom: 12px;
    }

    worldlikethis.com
    Like this fix..nice work. Cleans up the lightbox display and maintains the cursor over effect. Upgrading captions. Briefer the better. This works!
Sign In or Register to comment.