skip to Main Content

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?

Edit: As stated above, I cannot add a span. I am using Elementor. I am not directly editing the HTML.

3

Answers


  1. you can use the display:flex property on the parent element of the span to achieve this:

    parent {
      display: flex;
      justify-content: space-between;
    }

    moreover with css, you can also achieve this using position:absolute and much more.

    Login or Signup to reply.
  2. 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 .

    Login or Signup to reply.
  3. 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.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search