jquery/jquery-ui — pull request #781 by zjs (2012-10-19 03:22:58+00:00)
Title: Mask: introduce support for marking the beginning and end of a placeholder and introduce "\" as an escape character

This change introduces a syntax to introduces syntax to delineate the beginning and of end of placeholders. This is valuable to disambiguate cases where multiple interpretations of a mask string would otherwise be valid (e.g. if "x" and "xx" are both defined placeholders, the mask string "xxx" could be interpreted in three ways, but the strings "", "", and "" are all clear).

Additionally, this change introduces an escape character -- "\" -- that can be used to include a reserved character ("a", "9", "*", or "?" and now "<", ">", or "\") as a literal.

Lastly, while the behavior for the first un-escapped "?" character is unaltered by this change, subsequent optional segment delimiters are ignored (instead of being interpreted as literals). This should facilitate introduction of support for multiple optional segments (if such support is ever desired) without jeopardizing backwards compatibility.

Note that this change does *not* remove support for un-delineated placeholders; support can be removed once all existing uses of Mask have been updated.

These changes are documented here: http://wiki.jqueryui.com/w/page/12137996/Mask