Skip to content

New toggling options

Compare
Choose a tag to compare
@Twikito Twikito released this 29 Sep 14:43
· 84 commits to master since this release

This release add some new features and changes:

  • In respond of request #88, now you can go further into toggling by choosing if some classes must be toggled only on trigger, or only on targets, or on both. And you can combine these options.

    • data-toggle-class will toggle filled class on trigger and target elements
    • data-toggle-class-on-trigger will toggle filled class only on trigger element
    • data-toggle-class-on-target will toggle filled class only on target element•s
  • In respond of request #65, now you can fill these toggling attributes with as many classes as you need. If an attribute is left empty, the default class is-active is used.

  • It might be a breaking change, but as the data-toggle-class-on-target is available, I have removed the data-toggle-target-only attribute.

These new features make Easy Toggle State compatible with any CSS framwork. Go further into these new features in the documentation.

Happy toggling! 🖖