Releases: zipper/collapsable.js
Releases · zipper/collapsable.js
3.8.1
What's Changed
- 🐞 Expand/Collapse events triggered only on state change (#33)
Full Changelog: 3.8.0...3.8.1
3.8.0
What's Changed
- ✨ Allow external links to be a button element (#32). External links for collapsable can now be a
HTMLButtonElement
withdata-collapsable-id
attribute. There is also an option to prevent the default action of an external link using either the option (this affects all external links for a particularCollapsable
) or thedata-collapsable-prevent-default
attribute (this affects only a specific external link). - 🛠 Dev dependencies updated.
Full Changelog: 3.7.2...3.8.0
3.7.2
What's Changed
- 🛠 Fixed data attibute name for responsive default expanded items (#31).
Full Changelog: 3.7.1...3.7.2
3.7.1
What's Changed
- ✨ Support for responsive default expanded items (#30). As well as using a class attribute, elements can be expanded by default using
data-collapsable-default-expanded-media
. This data attribute should contain a media query string (e.g.(min-width: 992px)
), which is then evaluated usingwindow.matchMedia
. If it matches, the item will also be expanded by default, regardless of class. It is therefore intended to be used without the default expanded class name.
Full Changelog: 3.6.0...3.7.1
3.6.0
What's Changed
- ✨ The control element for
CollapsableItem
is now optional (#27). If there is no control element, you can either expand / collapse the item programmatically from JS, or you can use an external link. - ✨ External link aria attributes added (#28). Collapsable now sets the
role
attribute (if not already present) on the external link. It also sets the appropriate aria attributes -aria-controls
and eitheraria-selected
(ifrole="tab"
is used) oraria-expanded
(if role="button" or norole
is used). - ⚙ Fixed links inside
package.json
(#26). - ⚙ Build packages updated (#29).
Full Changelog: 3.5.2...3.6.0
3.5.2
What's Changed
Full Changelog: 3.5.1...3.5.2
3.5.1
What's Changed
Full Changelog: 3.5.0...3.5.1
3.5.0
What's Changed
Full Changelog: 3.4.2...3.5.0
3.4.2
What's Changed
Full Changelog: 3.4.1...3.4.2
3.4.1
What's Changed
Full Changelog: 3.4.0...3.4.1