I created a widget (using the JQuery UI widget base) to turn standard text inputs into segmented inputs, described with JSON metadata, with flexible and customizable validation both client-side via regex and through server-side calls. Additionally, the widget supports server callbacks to generate “next number in sequence” default values. The widget can be found on GitHub here.
I also developed an ASP.NET server side control to wrap the widget and pass metadata, implementing it within the Spitfire Project Management System.