Release: Validation Plugin 1.13.1

This is a patch release for the jQuery Validation Plugin. It contains a few changes, though most notable is the fix for the newly implemented aria-describedby-based behaviour for error elements introduced in 1.13.0. That turned out to have a few issues which are now addressed.

Thanks to Markus Staab, who’s have been helping with ticket triage.

Download this release.

If you use the plugin, please donate or ask your boss to make a donation! This helps to run the plugin site and makes releases like this one possible.

Click here to lend your support to: jQuery Validation Plugin and make a donation at www.pledgie.com !

4 people contributed code to this release. A big thank you to: Barry vd. Heuvel, colemanw, Damian Mooyman and fernandopasse. Also thank you to everyone who reported issues on GitHub or commented on them.

As usual:
  • Please post questions to the official Using jQuery Plugins Forum, tagging your question with (at least) “validate”. Keep your question short and succinct and provide code; a testpage makes it much more likely that you get an useful answer in no time.
  • Please post bug reports and other contributions (enhancements, features, e.g. new validation methods) to the GitHub issue tracker

The full changelog:

Additionals

  • Add postalcodeBR method (cc6c4a4)
  • Fix pattern method when parameter is a string (4cecd73)

Core

  • Ignore readonly as well as disabled fields. (9f4ba10)
  • Improve id escaping, store escaped id in describedby (#1269, d36d1bc)
  • Escape id/name before using it as a selector in errorsFor (#1275, 20f3e9f)
  • Allow 0 as value for autoCreateRanges (fe14d00)
  • Apply ignore setting to all validationTargetFor elements (f1c611e)
  • Use return value of submitHandler to allow or prevent form submit (#650, 8b2f1e0)
  • Explicit default for focusCleanup option (#676, 0cb3c95)
  • Fix incorrect regexp (#1200, c054707)
  • Don’t trim value in min/max/rangelength methods (#1274, 452b823)

Release: Validation Plugin 1.13.0

I’m happy to announce a new release of the jQuery Validation Plugin. It’s been just three months since 1.12, yet this release brings lots of small and two big improvements. For those two I have to thank two people in particular.

First, Damian Mooyman, heavily improved the error message display implementation. From the outside, nothing really changed (this is a minor release after all, so backwards compatibility is a given). Though once you switch the bad default for the errorPlacement option to something like a <span> (this default will change in 2.0), the error label gets associated to the element using aria-describedby. Along with the other ARIA attributes the plugin is already using, this gives screenreader users a much better experience. There’s lots of details involved, which don’t quite fit into this blog post. If you’re interested, check out the discussion for the two pull requests that made this happen, #1083 and #1140.

The other big one is support for AMD, implemented by Lars Laade. While there was a lot less discussion, he had to update most of the source files. I especially like that the UMD wrappers are added as part of the build step, keeping them out of the source files themselves. Again, if you’re interested in the details, check out pull request #1106.

I also want to thank Nick Schonning and Markus Staab, who have been helping out with ticket triage and lots of smaller details.

Download this release.

If you use the plugin, please donate or ask your boss to make a donation! This helps to run the plugin site and makes releases like this one possible.

Click here to lend your support to: jQuery Validation Plugin and make a donation at www.pledgie.com !

18 people contributed code to this release. A big thank you to: ado130, Damian Mooyman, Diego, J. Randall Owens, Jamie R. Rytlewski, jcare44, Jeremy Forsythe, Jyrki Lilja, Lars Laade, lboullo0, Manuel Dalla Lana, Markus Staab, Nano Taboada, NetImperia, Nick Schonning, paladox2015, pylover, Wing. Also thank you to everyone who reported issues on GitHub or commented on them.

As usual:
  • Please post questions to the official Using jQuery Plugins Forum, tagging your question with (at least) “validate”. Keep your question short and succinct and provide code; a testpage makes it much more likely that you get an useful answer in no time.
  • Please post bug reports and other contributions (enhancements, features, e.g. new validation methods) to the GitHub issue tracker

The full changelog:

All

  • Add plugin UMD wrapper

Core

  • Respect non-error aria-describedby and empty hidden errors
  • Improve dateISO RegExp
  • Added radio/checkbox to delegate click-event
  • Use aria-describedby for non-label elements
  • Register focusin, focusout and keyup also on radio/checkbox
  • Fix normalization for rangelength attribute value
  • Update elementValue method to deal with type=”number” fields
  • Use charAt instead of array notation on strings, to support IE8(?)

Localization

  • Fix sk translation of rangelength method
  • Add Finnish methods
  • Fixed GL number validation message
  • Fixed ES number method validation message
  • Added galician (GL)
  • Fixed French messages for min and max methods

Additionals

  • Add statesUS method
  • Fix dateITA method to deal with DST bug
  • Add persian date method
  • Add postalCodeCA method
  • Add postalcodeIT method

Exporting ScreenFlow recordings for HD YouTube uploads

ScreenFlow works pretty well for me for all kinds of screencasts. Its default settings are pretty bad though, when I want to upload the exported video to YouTube and have is played back with decent quality. The problem is the default scale setting: The “Web – High” preset suggests to scale the video down by 50%. That reduces the file size a lot, but also produces output that will show up as “240p” on YouTube, which looks pretty awful.

For 720p videos, you want to set the resolution to exactly 1280×720. Export and upload that and YouTube will be able to play back the video with 720p “HD”, which looks so much better.

I’m recording videos on my MacBook Air 13″, which has a native resolution of 1440×900. That’s not the same ratio as 1280×720. For a recent recording I resized the canvas of the recording from 1440×900 to 1440×810. That cuts of some stuff at the top, bottom or both, but that worked fine in my case. The end result is a ratio that matches the 720p ratio, so scaling it down won’t distort the result at all.

Note that you need a verified YouTube account to upload videos longer than 15 minutes. Make sure you have that before attempting to upload an hour long screencast, and having to start over after the video gets rejected as too long.

Talk recording: Effective jQuery

This is the official recording of my talk at the jQuery Conference in San Diego in February 2014, titled “Effective jQuery – Patterns for maintainability and performance”, recorded a few weeks ago, published yesterday. I probably spent about two full weeks preparing this talk, with lots of rehearsing. Still, I was very nervous at the beginning, which can be heard quite well. Five minutes into the talk, covering technical stuff, I calmed down a lot, which can also be heard quite well.

The slides are available online.

I’ll be giving this talk again at this year’s enterJS 2014 in Köln (home town!), on day one, June 30th. They still have tickets, so if you’re close enough and want to see my talk live (and in german), get a ticket.