Skip to content

Releases: zipper/collapsable.js

3.8.1

23 Oct 09:34
Compare
Choose a tag to compare

What's Changed

  • 🐞 Expand/Collapse events triggered only on state change (#33)

Full Changelog: 3.8.0...3.8.1

3.8.0

20 Jun 09:50
Compare
Choose a tag to compare

What's Changed

  • Allow external links to be a button element (#32). External links for collapsable can now be a HTMLButtonElement with data-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 particular Collapsable) or the data-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

18 Jan 14:39
Compare
Choose a tag to compare

What's Changed

  • 🛠 Fixed data attibute name for responsive default expanded items (#31).

Full Changelog: 3.7.1...3.7.2

3.7.1

18 Jan 13:40
Compare
Choose a tag to compare

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 using window.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

01 Nov 13:42
Compare
Choose a tag to compare

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 either aria-selected (if role="tab" is used) or aria-expanded (if role="button" or no role is used).
  • ⚙ Fixed links inside package.json (#26).
  • ⚙ Build packages updated (#29).

Full Changelog: 3.5.2...3.6.0

3.5.2

11 Sep 13:18
Compare
Choose a tag to compare

What's Changed

  • fix: External links and multiple initializations of Collapsable by @zipper in #25

Full Changelog: 3.5.1...3.5.2

3.5.1

11 Apr 09:25
Compare
Choose a tag to compare

What's Changed

  • fix: more general implementation of deepMerge by @zipper in #23

Full Changelog: 3.5.0...3.5.1

3.5.0

11 Apr 07:55
Compare
Choose a tag to compare

What's Changed

  • feature: ESM version exports deepMerge function by @zipper in #22

Full Changelog: 3.4.2...3.5.0

3.4.2

05 Apr 10:39
Compare
Choose a tag to compare

What's Changed

  • fix: Order of operations in constructor by @zipper in #21

Full Changelog: 3.4.1...3.4.2

3.4.1

05 Apr 10:21
Compare
Choose a tag to compare

What's Changed

  • fix: Property collapsableItem is always present on interface HTMLCollapsableItem by @zipper in #20

Full Changelog: 3.4.0...3.4.1