Skip to content

Releases: panoply/relapse

v0.9.1

30 Aug 04:47
2e96f8e
Compare
Choose a tag to compare

Relapse v0.9.1

Changes

  • Wait until action has been taken before applying style="" properties.
  • Confirm instance exists before triggering relapse.reinit()

Breaking

  • The openCount instance reference has been renamed to opened

Fixes

  • Fixed the auto-collapsing bug occurring on last known folds when both persist and multiple were set to true.

Added new config method

Relapse now provides live reconfiguration alignments. Instances have access to an additional config() method which can be used for updating options on an existing relapse instance. When using this method, the current instance will adhere to new settings in real-time.

Refer to the Methods API for a more detailed breakdown.

import relapse from 'relapse';

const instance = relapse('#example', { 
   multiple: true, // we allow for multiple folds to be opened
   persist: false  // we do not require a single fold to persist
});

// Using the config method and passing the following would 
// result in all expanded folds to be closed as we set multiple to false
// and because we set persist to true, all but 1 fold will collapse.
//
instance.config({ 
   multiple: false, 
   persist: true 
})

v0.9.0

25 Apr 20:09
766e525
Compare
Choose a tag to compare

Relapse v0.9.0

Fixes

  • Remove role annotation from sibling and semantic structures
  • Remove conflicting aria-* annotations
  • Remove the applied disable annotations.
  • Update declaration example to be correct.

v0.8.1

01 Mar 15:29
b720197
Compare
Choose a tag to compare

Relapse v0.8.1

Fixes

  • Added the missing global relapse.destroy() method.

Changes

  • Allow for the global relapse.has() method to check for any instance.

v0.8.0

01 Mar 00:26
b720197
Compare
Choose a tag to compare

Relapse v0.8.0

Release ships with some minor enhancements that extend the existing API.

Fixed auto-typed import

In v0.7.0 the module would use an upcase import within TypeScript environment, the lowercase relapse will now apply.

Smaller Distribution bundle

Relapse is now 2.5kb gzip with saving of 0.2kb - It is unlikely it will get smaller.

Allow element to be reset on instances

Previously, an instance would provide the element as a getter. This version allows for the element key to be reset.

Incrementally apply attribute annotation

This helps limit the amount of operations relapse will carry out. If attributes exist pertaining to A11y logic then relapse will not reset them. Mostly an internal minor patch.

Added reinit() method

Given the way Relapse is designed, sometimes it be preferred to reinitialize an existing instance. The reinit method can provide this functionality and is available to all instances with an additional global method provided.

import relapse from 'relapse';

// GLOBAL METHODS
relapse.reinit() // Reinit all active instances
relapse.reinit('id') // Reinit an instance by id
relapse.reinit(['foo', 'bar']) // Reinit the following instances only

// INSTANCE METHOD
const demo =  relapse(); // Create an instance
...

demo.reinit(); // Reinit the instance