version 3.0

@bit101 bit101 released this Nov 11, 2016 · 26 commits to master since this release

Version 3 is mostly about simplifying the panel, removing little used features and making getting and setting values easier.

  • New features / changes:
    • All controls with settable values are now set with panel.setValue(title, value)
    • All controls with gettable values are now read with panel.getValue(title)
    • You can programatically get and set control values with JSON using panel.getValuesAsJSON and panel.setValuesWithJSON.
    • Calling saveToLocalStorage(name) will cause all changes in the panel to be continuously synced to local storage and restored when the panel is restarted. See details below, and demo project.
  • Removed:
    • panel.addInfo and related methods are gone. These were just aliased to panel.addHTML anyway, so use that instead.
    • The functionality to parse an entire panel layout from JSON has been removed. This might be added in later as a separate module.
    • The snap-to-grid functionality has been removed.

Naturally, many of these changes will break backwards compatibility with version 2 or earlier. But the changes overall result in a cleaner, simpler API and are easy enough to migrate over to.

Unit testing was also added to the project, which brought to light many small issues that were then fixed.