The main benefit of this option is that it allows effects and transitions to apply to the background. Imagine adding a background image, then adding an effect to the background image that makes it completely opaque, then displaying it fully on hover with a nice transition. This is where you’ll want to use the Pseudo Element option.
DevicDemo post for best home appliances
The Device option allows us to define which device this background type is for. We can choose between:
- Tablet + Mobile
Demo post for best home applinces
The state refers to whether the block is static (Normal), meaning no interaction, or whether it’s hovered (you mouse over it).
- Normal – apply to the block as it is on the page with no interaction
- Hover – apply to the block when the current block is hovered
Here we can choose between two targets.
This applies the background to the Container element itself. This is standard, but it doesn’t allow for effects or transitions to be applied to the background.
This adds the background as its own element inside the Container. The image type is set to the
:before pseudo selector, and the gradient type is set to the
:after pseudo selector.
The main benefit of this option is that is allows effects and transitions to apply to the background. Imagine adding a background image, then add an effect to the background image that makes it completely opaque, then displays it fully on hover with a nice transition. This is where you’ll want to use the Pseudo Element option.
This option, like the Effects feature, allows us to add an unlimited number of backgrounds. However, we need to be careful that our backgrounds don’t clash with each other.
The first thing to be aware of is the three options we just went over. For example, if we add a background type with these values:
- Device: All
- State: Normal
- Target: Self
We can not add another background type with the same three values. When we add a different background type, we need to ensure that one of these three values is different than the other ones.
Also worth noting is that CSS uses the same property (
background-image) for background images and gradients, so you can’t have an image type and gradient type applied to the same target if the other two values match as well.
The image background type has basically the same options as our default background image features for the Container block. The only difference is that it doesn’t have an Opacity feature, as you should use the Opacity & Blend feature in the Effects panel instead (it’s way better!).
Upload a background image for the container. Click the Browse button to choose an image from the media library. Alternatively, you can add a custom URL to the input.
If you’re using an image from your Media Library, you can choose an image size from the available list of sizes.
The size option refers to the
Further reading: https://developer.mozilla.org/en-US/docs/Web/CSS/background-size
The position option refers to the
Further reading: https://developer.mozilla.org/en-US/docs/Web/CSS/background-position
The repeat option refers to the
Further reading: https://developer.mozilla.org/en-US/docs/Web/CSS/background-repeat
The attachment option refers to the
The background gradient has the same options as our standard Gradient option.