Skip to content

Releases: smastrom/vue-collapsed

v1.3.4

05 Aug 16:01
51502dc
Compare
Choose a tag to compare

Release notes

v1.3.3

09 Apr 10:35
bb5ca09
Compare
Choose a tag to compare

Release notes

Force expand/collapse if unable to properly query scrollHeight in some consumer's implementation-related edge cases, thanks @oleh-selivanov - #25

v1.3.2

08 Apr 11:57
Compare
Choose a tag to compare

Release notes

v1.3.1

06 Mar 12:25
Compare
Choose a tag to compare

Release notes

Add additional condition for checking undefined CSS transition required for Firefox 124+ - #23 - Thanks @andreww2012

v1.3.0

15 Dec 15:39
Compare
Choose a tag to compare

Release notes

  • Fix a SSR layout shift bug where <Collapse /> was displayed as expanded on initial render until JS was loaded (if collapsed). #22 - Thanks @zhaivoronok
  • Add a check to control whether requestAnimationFrame is available

Other

  • Setup monorepo
  • Migrate playground to Nuxt
  • Add more examples to playground
  • Migrate demo website to Cloudflare Pages

v1.2.9

19 Oct 17:55
Compare
Choose a tag to compare

Release notes

This patch release doesn't bring any new feature nor fix. It is just a "courtesy-release" to enable from now on, publishments via the newly introduced npm provenance statements.

I also took the chance to improve a bit the (one year old) codebase by:

  • Use defineOptions in the setup block
  • Refactor reactivity-related syntax to improve readability using setters
  • Enable watch mode for both dev and GUI testing
  • Drop the buggy and unstable Cypress webkit testing (support still experimental)
  • Update all dependencies

v1.2.8

16 Sep 12:46
Compare
Choose a tag to compare

Release notes

Fixed a bug on iOS where getAutoDuration returned Infinity if visually hidden styles were applied just right before calling it.

v1.2.7

20 Aug 18:07
Compare
Choose a tag to compare
  • Fixed a bug where auto duration was not calculated if Collapse was mounted in a container with display: none.
  • Added Firefox and Webkit tests.

v1.2.6

03 Aug 23:47
d29bfcf
Compare
Choose a tag to compare

What's improved

  • Collapse is now more performant, using only one requestAnimationFrame call per expand/collapse. This was achieved by streamlining the logic behind retrieving the auto duration value, which is now only captured on mount.
  • No longer enforcing margin: 0 and border: 0 on the Collapse element fixed styles.
  • When baseHeight dynamically updates to 0 on collapsed state, display: hidden is now added on the Collapse element styles.
  • Added examples to the README on how to use different easing and durations per expand/collapse.

v1.2.0

25 Jul 12:44
ebf4b4d
Compare
Choose a tag to compare

Release notes

The next minor release of vue-collapsed brings a lot of improvements and a new feature.

What's new

  • Starting from v1.2.0 you don't need to define a class name with a height transition anymore. As long as no transition is defined on the Collapse element, the following one is automatically added: height var(--vc-auto-duration) cubic-bezier(0.33, 1, 0.68, 1).
  • Added automatic transition disabling for prefers-reduced-motion: reduce and the ability to manually disable transitions via CSS.

What's changed

Callback props have been replaced by emits. This won't break any functionality, as Vue emits can also be defined using the previous props' syntax (onCollapsed, onExpand, etc).

If you were using them, you can update your code as displayed below.

Pre v1.2

<Collapse :when="isExpanded" :onExpand="callback">
  <p>This is a paragraph.</p>
</Collapse>

v1.2

<Collapse :when="isExpanded" @expand="callback">
  <p>This is a paragraph.</p>
</Collapse>

What's improved

  • Collapse has been refactored from a render function to a Vue component, delegating the transformation to the Vue compiler. This brings proper support for typed emits and slots.
  • Updated vite-plugin-dts configuration for better types generation