Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Can this be changed.

  • This topic is empty.
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #271766
    canadacatman
    Participant
    #271767
    canadacatman
    Participant

    Sorry I forgot my question. Can I change the top code to the bottom code anyway. Thanks

    #271769
    Paulie_D
    Member

    Not sure what it is you are asking!

    Please clarify as your Codepen does not demonstrate any issue.

    #271770
    canadacatman
    Participant

    I want to take the word “Open” out and replace it with “fa-angle-left” instead. Thanks

    #271771
    Paulie_D
    Member

    So what is stopping you?

    When and how do you expect to do this?

    Sounds like you might need javascript…

    #271772
    tomnoble92
    Participant

    It depends what the event is. Do you want to change it on click/hover/keydown?

    An example of changing the content on a button click.

    const button = document.querySelector('.buttonClass');
    const label = document.querySelector('.labelClass');
    button.addEventListener("click", () => {
        label.classList.toggle(".is-active");
    });
    
    .is-active {
    content: "fa fa-angle-left" 
    }
    
Viewing 6 posts - 1 through 6 (of 6 total)
  • The forum ‘CSS’ is closed to new topics and replies.