Release Notes - craterdog-archives/js-bali-component-framework GitHub Wiki

  • Updated the package dependencies to the latest versions.
  • Fixed a problem with the parsing of narratives.
  • Fixed some HTML formatting problems.
  • Optimized the processing of narratives with a isNarrative flag in the Text class.
  • Generalized the language grammar NARRATIVE token rule to allow nested narratives.
  • Replaced the moment.js package dependency with native date, time and duration implementations.
  • Added more unit tests for all possible months, days, hours, minutes and seconds to the Moment class tests.
  • Added support for the extended year ISO 8601 timestamp format with positive and negative year values up to 6 digits in length.
  • Changed the language grammar for the checkoutClause rule to have the key word "at level" instead of "at". This resolves the previous keyword conflict but makes the clause more readable.
  • Renamed the Version.validNextVersion() method to Version.validNext().
  • Changed the language grammar for the signClause and checkoutClause rules to free up the 'sign' and 'level' keywords since both are likely to be used as argument and variable names.
  • Cleaned up the Pattern.matchesString() method and the Comparator.doesMatch() methods so that they are not confused with each other.
  • Restricted the language grammar rule for a LABEL token to only start with a letter or digit.
  • Changed language grammar to require at least one base 32 digit in a TAG token.
  • Changed the src/abstractions/Component.toBoolean() method to src/abstractions/Component.isSignificant() since it is making that determination rather than converting the value to a boolean.
  • Added a /bali/interfaces/Polarized interface with an isNegative() method.
  • Added support for the new /bali/interfaces/Polarized interface to the Angle, Duration, Number, and Percentage element classes.
  • Removed the toReal() method from the src/elements/Boolean class.
  • Removed the src/interfaces/Reflective interface since only the src/abstractions/Component class supported it.
  • Changed the index parameter in the List.insertItem(index, item) and List.insertItems(index, items) methods to be the slot number before the item in the list.
  • Moved the comparator parameter out of the Sorter agent constructors and into the sortCollection() method.
  • Moved the parameters out of the Formatter agent constructors and into the methods.
  • Changed the return type of the Catalog.removeAttributes() method back to List.
  • Generalized the containsX(), getXs() and removeXs() methods to take sequences of indices instead of ranges.
  • Renamed the Collection.removeAll() method to Collection.emptyCollection() since it doesn't return the removed items like other remove methods.
  • Added a title parameter to the src/agents/HTMLFormatter() constructor.
  • Adjusted the HTML formatting for binary strings.
  • Made the return values for all collection remove...() methods consistent.
  • Changed the HTML footer to be the full transparent craterdog logo.
  • Fixed a bug in the BDNParser.visitCatalog() and BDNParser.visitList() visitor methods where any additional type parameterization was being used in the type comparisons.
  • Fixed a bug in the Queue, Set and Stack constructors where any additional parameterizations was being stripped off.
  • Fixed various problems with the HTMLFormatter agent.
  • Fixed a bug in the Visitor.visitComponent() method where name collisions could occur with type names.
  • Disallowed an undefined argument to the Collection.addItems(items) method.
  • Refactored the Exception attribute structure.
  • Added double quotes around all $text attributes in exceptions to avoid an unneeded parsing attempt.
  • Fixed a bug in the Component.validateArgument() function where the function was returning a false boolean rather than throwing an exception.
  • Cleaned up confusing code in parsing exceptions.
  • Added unit tests for formatting and parsing iterators. The node iterator cannot be formatted into a legal grammatical construct so it does not support formatting.
  • Fixed problems with how iterators handle negative slots.
  • Fixed a bug in how the src/collections/Catalog constructor sets the type. It was using any type specified in the parameters as the type, but should always be /bali/collections/Catalog so that the visitors work correctly.
  • Now exporting the bali.component.validateArgument() and bali.component.normalizedIndex() functions in the main index.js file.
  • Fixed incorrect type names for all strings.
  • Renamed the Decoder "base2" references to "base02" so that the bases sort correctly.
  • Attempted to make Exception inherit from both Component and Error. This works fairly well.
  • Fixed a bug in the Exception constructor that made it impossible to print itself out correctly.
  • Added support for the Exception class, CanonicalComparator and MergeSorter agents as components to all visitors.
  • Updated the cause processing within the Exception class.
  • Moved the Exception class to be collocated with the Component class. Moved the Validator methods to the Component class as methods and functions.
  • Moved the decision on whether or not to log an exception into the Exception constructor function.
  • Added missing validation calls to the methods and functions that take parameters.
  • Refactored the abstract methods a bit to be more maintainable.
  • Added some missing exception cases for some abstract and collection classes.
  • Removed the debug argument from Component.componentize(value) method since it is already available from the this pointer for the component.
  • Added comparison tests for internal vs external sorting to make sure the results were the same.
  • Removed the bali.bdn(), bali.duplicator(), and bali.parser() functions from the Bali API.
  • Moved the Iterator implementation back into the Collection class and generalized it for all collections except the Range class which has its own iterator.
  • Added convenience functions to the Bali API for each agent method.
  • Refactored the agent framework to have the abstract pattern classes in the src/abstractions/ directory and the concrete agent implementations in the src/agents/ directory.
  • Changed Comparator.compareComponents() to Comparator.ranking().
  • Removed the bali.type(object) function from the API in the index.js file since it gets confused with the Component.getType() method.
  • Cleaned up the dependencies between types of classes and made sure that the only two circular dependencies (in the Component.toString() and Component.componentize(object) methods) are bound to the class at the end in the top level index.js file.
  • Moved the src/abstractions/Iterator and src/abstractions/Visitor classes to the src/agents/ directory.
  • The src/agents/Iterator class is no longer a subclass of src/abstractions/Component.
  • Refactored the visitor pattern implementation to be simpler by using reflection.
  • Changed sortItems(comparator) to sortItems(sorter).
  • Changed the algorithm parameter to comparator in all sorting.
  • Removed the getIndex(item) method from the /bali/interfaces/Sequential interface.
  • Moved the src/trees/Exception class to src/agents/Exception.
  • Removed the src/abstractions/Composite class since it added not concrete methods.
  • Moved the src/composites/Node and src/composites/Procedure to a new src/trees/ directory.
  • Moved the src/compositesAssociation to the src/collections/ directory.
  • Renamed the /bali/interfaces/Structural interface to /bali/interfaces/Composite.
  • Removed the toLiteral() method from src/collections/Range class since it can now contain expressions as endpoints.
  • Renamed the concatenation() function to chain().
  • Refactored the src/composites/Range class to be a collection src/collections/Range that accepts expressions for its first and last items.
  • Reversed the second and third parameters in the new src/collections/Range constructor.
  • Added Range.setFirst(value) and Range.setLast(value) methods to the src/collections/Range class.
  • Generalized the language grammar for lists and catalogs to allow expressions for their values.
  • Renamed the src/utilities/ directory to src/agents/ to match the Bali Nebula™ naming conventions.
  • Cleaned up the natural algorithm in the src/utilities/Comparator class.
  • Added <..<, <.. and ..< connectors to the existing .. range connector to implement exclusive bounds at either end.
  • Refactored the language grammar to allow negative constant floating point numbers like and -e.
  • Fixed a bug in the src/utilities/Comparator class which cast various component types into numbers rather than comparing the types of components with different types.
  • Added functionality to the Visitor.visitEvaluationClause() methods that handles the +=, -=, and *= operators.
  • Renamed the /bali/interfaces/Composite interface to /bali/interfaces/Structural.
  • Renamed the src/abstractions/Structure class to src/abstractions/Composite.
  • Renamed the src/abstractions/Sequence class to src/abstractions/String.
  • Added a /bali/libraries/Radial function library to the src/elements/Angle class.
  • Renamed the src/elements/Complex class to src/elements/Number.
  • Split out a new src/elements/Boolean class from src/elements/Probability.
  • Removed getParent() method from the Tree class since a child node can be shared by multiple parents.
  • Renamed the Tree class to Node since that is what they are.
  • Fixed an erroneous type name in the Validator class.
  • Added support for the /bali/interfaces/Discrete interface to the Probability class. The toInteger() method now returns a zero or one.
  • Added the missing duplicate() method to the Exception class.
  • Split out the methods in Component and Exception by interface.
  • Changed the /bali/interfaces/Numerical interface to /bali/interfaces/Continuous, and the toNumber() method to toReal() since a Bali Number is a complex number.
  • Fixed bug in the formatting of complex numbers in polar form.
  • Renamed the element Percent to Percentage which is a noun instead of an adverb.
  • Removed the unused /bali/interfaces/Procedural interface from the Tree class.
  • Renamed the element Reference to Resource and the token TYPE to LABEL in the language grammar.
  • Added a unit test for variable length tags.
  • Added a concrete implementation of the getSize() method to the Collection abstract class.
  • Moved the Tree class from src/collections to src/structures since it is not a collection.
  • Removed the interfaces parameter from the Iterator constructor signature.
  • Added a StringIterator to the Sequence class that works for all subclasses.
  • Exported the Collection.Iterator class and now the Range.getIterator() method returns it.
  • Changed the commit document clause to a sign contract clause to be consistent with the document repository API.
  • Added a source top level rule to the grammar to allow proper parsing of a Bali Document Notation™ string rather than a document. This fixes a bug where the string being parsed is only partially read before a matching component is found.
  • Changed the activity rule in the language grammar to code since it is a much better term. Code anthropologists are going to have fun with this one!
  • Tightened up the grammar definition for a document so that it forces POSIX text file compliance.
  • The Component.toHTML() and Component.toDocument() methods now append the required EOL character to the generated text documents.
  • Renamed the action rule to activity in the language grammar to make it a bit more clear.
  • Made comments (e.g. /*, */ blocks) into parse tree components so that they are preserved during parse-format round trips.
  • Allow notes (e.g. -- This is a note) at the end of any component. The notes too will be preserved during parse-format round trips.
  • Changed the statements rule in the language grammar to action to better reflect the fact that it is a tree structure rather than a list of statements.
  • Changed the Range element from a Sequential type to Structure component.
  • Generalized the first and last values of a Range to be any Element.
  • The constructor for Range now takes a first and last argument instead of an array.
  • Added bali/interfaces/Literal and bali/interfaces/Sequential interface support to the Range structure.
  • Range.getIterator() will throw an exception if the first and last elements of the range are not integers.
  • Added a /bali/interfaces/Discrete interface to the Complex type. This supports the toInteger() method.
  • Changed the path 'types' to 'abstractions' to be consistent with the bali naming and to avoid confusion with the bali meta types.
  • Another patch to revert the change of Complex.toNumber() returning the magnitude back to returning the real part. Otherwise, negative real numbers come back positive.
  • Added missing changes from last release as a patch: Catalog.getValues(...) to Catalog.getAttributes(...) and Catalog.removeValue(...) to Catalog.removeAttribute(...).
  • Merged the Composite.[gs]etValue(...) and Structure.[gs]etSubcomponent(...) methods into a new Composite.[gs]etAttribute() method since they implemented the same functionality and were causing confusion with the Element.getValue() method.
  • Fixed bug in Complex.toNumber() which was returning only the real part rather than the magnitude.
  • Added in the missing reciprocal operation to inversion expressions in the language grammar.
  • Updated to the latest versions all dependencies except antr4 which forces ES6 modules after version 4.8.
  • Fixed bug in how Catalog constructor handles a type parameter.
  • Fixed a bug in Catalog where a $type parameter was not being integrated into the ancestry.
  • Renamed the 'receive' message statement to 'retrieve' message to be consistent with the other repository retrieval methods.
  • Added an optional ('as' recipient)? part to the 'save' expression grammar rule. The resulting draft citation will be stored in the recipient.
  • Added back in the Structure abstract class for the Association, Procedure, and Exception classes to inherit from.
  • Changed the Exception.toString() method to include the native stack trace when there is a javascript exception as the cause.
  • Updated the document repository related language statement grammar to reflect the latest changes to the repository API and the VM.
  • Added many more unit test cases for the Comparator class.
  • Made the natural algorithm defined in the Comparator class more general and accurate.
  • Fixed several bugs in the Range and Comparator classes when dealing with zero values that were being treated as undefined.
  • Added the missing Exception import in the Range class.
  • Fixed an HTML formatting bug for Range parameters.
  • Found an elegant way to allow a component's parameters to be stored as a Catalog instead of a JavaScript Object without introducing circular dependencies.
  • Simplified the language grammar for handle clauses.
  • Added a toLiteral() method to the Element and Procedure classes for use by the VM.
  • Converted the Complex, Duration, Moment and Range constructors to take a value type that is the same as what is returned from getValue(). This makes duplicating elements more consistent.
  • Fixed a bug in how keys are created when converting an object into a catalog.
  • Added methods to the Duration class to retrieve parts of the duration.
  • Added methods to the Moment class to retrieve parts of the time.
  • Removed the Reserved element class since it is not really needed anymore.
  • Added the Symbol and Reserved elements as additional subclasses of the abstract Sequence class.
  • Added an abstract Sequence class that the Binary, Name, Range, Text, and Version element classes inherit from. This adds the getItem(index) and getItems(range) methods to those classes.
  • Fixed a small bug in the Decoder constructor where an undefined indentation was not handled correctly.
  • Fixed a bug in List.removeItems(range) where the items were being removed in order which changes the indexing. They must be removed last to first in the range.
  • Fixed some bugs in the getSubcomponent() and the setSubcomponent() methods. The index that was passed in is an element and must be converted to a number for some types of collections.
  • Redesigned the Range class and made it an Element instead of a Collection to address the many issues that arose from the previous design.
  • Moved the removeAll() method to Collection class since is now implemented by all collections.
  • Added a Composite interface that supports getSubcomponent(index) and setSubcomponent(index, subcomponent) methods. The Structure, List and Catalog classes support this interface. This interface is only useful for the compiler and virtual machine.
  • Renamed the Composite class to Structure and the abstractions directory to types.
  • Added a default implementation to Collection.getItem(index) which uses the iterator to go directly to the requested index.
  • Changed all text based expression operators to all uppercase to avoid name collisions with their intrinsic function counterparts. The new operators are IS, MATCHES, NOT, AND, SANS, OR, and XOR.
  • Renamed the queue <message> statement to post <message> to avoid a naming collision between the queue keyword and the queue() intrinsic function name. The symantics remain the same.
  • Added a second <- operator to the messageExpression rule grammar for asynchronous message passing to complement the existing . operator for synchronous message passing.
  • Added the missing new keyword to Generator and Sorter constructor calls within some functions.
  • Changed the Version.nextVersion() and Version.validNextVersion() methods into class functions.
  • Fixed a bug in the Calculator class where zero significant digits was getting calculated.
  • Fixed bugs in the Collection.addItem() method and added a Range.addItem() implement that throws a more specific exception when it is called.
  • Fixed a bug in the index.type(component) function.
  • Added some missing interfaces.
  • Added some missing arguments to the index.tree() function.
  • Moved the addItem(item) and addItems(items) methods to the bali.Collection class.
  • Fixed an erroneous comment in the bali Catalog.extraction() method.
  • Refactored the Iterator class into an abstract class that is now inherited by all iterator classes.
  • Updated the generated HTML header to use the latest bali-nebula.net images and icons.
  • Fixed bugs in how the Probability class handles booleans passed into its constructor.
  • Fixed an error in the path for the favicon.ico file when generating HTML.
  • Modified the HTML generated by the HTML formatter class to enhance the readability of different element types.
  • Added a link behind each name in a generated HTML document. The link can be used by a browser to retrieve the notarized document associated with the name.
  • Added a meta tag to the header for the HTML formatted output that sets the character set to UTF-8.
  • Added an explicit link reference to the favicon.
  • Having the repository service serve up the static content for the HTML formatter was too slow. It is now served up by a seperate API Gateway instance that connects directly to the S3 bucket holding the content. This required a change to the URI for the static content. It is now https://bali-nebula.net/static/*.
  • Fixed error in the location of the static resources for the HTML formatter, the correct path is https://bali-nebula.net/repository/statics/.
  • Changed the location of the static resources for the HTML formatter to be in https://bali-nebula.net/statics/.
  • Added a check for a configurator directory that does not end with / and fixes it if necessary.
  • Changed "Powered By" logo and style sheet for HTML formatting to use the Bali Nebula™ site.
  • Fixed bug in language grammar definition for name that rejected digits following a slash.
  • Removed Component.format() and Component.html() methods that were deprecated.
  • Added a missing this pointer to anonymous functions that attempt to reference this.debug.
  • Changed font family for HTML style sheet to be Roboto to address formatting issues.
  • Deprecated Component.format() and Component.html(), and replaced them with 'Component.toBDN()' and 'Component.toHTML()'.
  • Cleaned up some formatting issues with the new HTML formatter class.
  • Fixed a bugs in the language grammar for Bali Document Notation™ that allowed components to be used as endpoints in a range instead of restricting them to just element types.
  • Added a new HTML utility class and a Component.html(style) method that returns a static web page for the component using the specified link to a CSS style sheet.
  • Fixed bugs in the language grammar for Bali Document Notation™ that allowed expressions to be used as values in structural components. The structural components cannot contain expressions since they are declarative and there is no virtual machine to evaluate them.
  • Added language grammar support to the Bali Document Notation™ for the symbols , π, φ, and τ, the last being equivalent to the value of per the Tau Manifesto. The new symbols map to the existing values defined for the language:
  • : infinity
  • π: pi
  • φ: phi
  • τ: 2 * pi
  • This is the first release of v2 of the framework. The framework is ready for general use.
  • It's public interfaces should now be stable, though it is far from bug-free.
  • From here on out, a minor release (e.g. v2.x) should only add new functionality and bug fixes, it should not break existing code that uses it.
  • Each dot release (e.g. v2.x.y) will be for urgent bug fixes.
  • There will be v2 releases for the rest of the Bali Nebula™ repositories that depend on the Bali Component Framework™ over the next few months.

NOTE: To view the release notes from v1 of the framework, click here.

⚠️ **GitHub.com Fallback** ⚠️