By Stephen Walker

Share

Another example of using a skewed background, this time targeting the pagination preview. Additionally, this limits the width of the preview and allows the text to wrap. Lastly, a clip-path is used to give the featured image a skewed appearance.


.fusion-pagination-preview-wrapper{
  position:relative;
  isolation: isolate;
  padding:16px;

}
.fusion-pagination-preview-wrapper::after{
  position:absolute!important;
  content:"";
  z-index: -1!important;
  inset: 0!important;
  transform:skewX(-5deg)!important;
  background-color:var(--awb-color5)!important;

}
.fusion-body .fusion-pagination-tb:not(.layout-sticky).layout-preview .fusion-pagination-preview-wrapper .fusion-item-title {
  padding: .5em .75em;
  white-space:unset!important;
  overflow: hidden;
  text-overflow:unset;
  max-width: 300px;
  display: block;
  text-align: left;
  color:var(--awb-color2)!important;
}
.fusion-body .fusion-pagination-tb:not(.layout-sticky).layout-preview .fusion-pagination-preview-wrapper .fusion-item-media img{
  max-width:100%!important;
  clip-path: polygon(5% 0, 100% 0%, 95% 100%, 0% 100%);
}

Originally published on Feb. 16, 2023

Skew Column Background
Basic Toggle

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

RELATED Snippets

  • Avada, CSS, JavaScript

    This creates a floating container. More to come.

  • Avada, CSS

    This is a style I recently used on my blog post title bar to have the feature image fill the column without having to use a background image.

  • Avada, CSS

    I have seen some tables of contents around the web that use what appears as a left border, and the border color changes when highlighted. This feature is missing from the current version of Avada, so I created CSS styling to do this. It works best with a single-level list. […]

  • Avada

    The social sharing element has some styles that prevent stacking them in a column. This CSS will resolve this. Just assign the class to each instance.

  • Avada, CSS

    This gives the default RSS feed widget a more polished appearance.

  • Avada

    The Toggle Element styling leaves a bit to be desired as it applies hover effects to the entire block and not just the header and the panel. This should override that behavior but still takes advantage of the settings, thanks to the use of CSS variables. Example