Fixed typo in type of animation styles element.
String.endsWith should not think "abc" ends with "defg"
Added missing return types in function definitions.
Replaced static ASS.parse method with constructor.
Only check if a \pos wrapper is needed at the end of Dialogue.draw()

This removes the need to maintain a currentSpanContainer reference separate from the main sub wrapper.
Also replaced hard-to-verify \pos and transform-origin calculations with switch-case blocks.
Override native parseInt instead of creating a new parseInteger function. The native function only needs to be replaced if it treats strings starting with 0 as octal.

Wrapped utility.ts in a module wrapper to prevent locals from leaking.
Renamed SimpleSet's private methods to start with an underscore.
Set the vendor-specific CSS properties before standard ones.
Added more debug logging.
Renamed libjass.ASS.debugMode flag to libjass.debugMode
Added a debug-mode warning for dialogues that contain a comment with a backslash as this might be the result of mis-parsing an ASS tag as a comment.
Split off tags classes into a separate file.
Don't let custom window.Iterator() support arbitrary objects incorrectly.
String.match() is unnecessary when String.replace() can do the job.
Set and String.endsWith aren't used in libjass. Moved them to index.js

Also replaced the single use of Set iterator with Set.forEach
Prettification
Implemented \alpha, \1a and \3a
Added explanatory comments for the suspicious empty if blocks.
Added example usage of combined JS to index.xhtml
Updated tests to use the new API.