How can I have a right-aligned span as part of the title of an Accordion element in Elementor?
How can I have a right-aligned span as part of the title of an Accordion element in Elementor?
This is what I have vs what I want. Basically, I want the time shown to be right-aligned while keeping the name of the event on the left. This is in the "title" part of an Elementor Accordion element.
Normally with HTML I would add a span for the time and align that to the right, but as I am doing this in Elementor, that is not possible. I can't just add a bunch of spaces because then it wouldn't be aligned properly on different screen sizes. Is there any custom JavaScript or CSS that I could possibly use to achieve what I want?
you can use the display:flex property on the parent element of the span to achieve this:
parent {
display: flex;
justify-content: space-between;
}
Run code snippetExpand snippet
moreover with css, you can also achieve this using position:absolute and much more.
December 29, 2023
There are several ways to do that but one of them i would probably use is float.
<span>
Opening event
</span>
<span style="float: right;">
11:00AM - 12:00PM
</span>
More information about float styling .
December 29, 2023
Dealing with Accordion Tabs title sometimes is a mess, but do you know instead of adding just simple text on the titles you can include a shortcodes? This way you easily can do what you are looking for and also add more style on your tabs. You can use images, colors, etc. Whatever you want! Just add the shortcode: [elementor-template id="XXX"] instead of your title text.
December 29, 2023
Turbo Multi-language Translator
Make the better internet purchasing globaly
Turbosify SEO Speed Booster
5.0 (7)•Free plan available
Get better conversions by improving store loading speed
Installed
Turbo Multi-language Chat - AI Customer service in one hand
December 29, 2023
December 29, 2023
December 29, 2023