Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding Webshim to add polyfill for HTML5 form validation in browsers #2324

Merged
merged 1 commit into from
Mar 7, 2015
Merged

Adding Webshim to add polyfill for HTML5 form validation in browsers #2324

merged 1 commit into from
Mar 7, 2015

Conversation

shefik
Copy link
Contributor

@shefik shefik commented Mar 7, 2015

Adding Webshim to add polyfill for HTML5 form validation in browsers, such as adding support in Safari on Mac.

This corrects the installer.

Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets -
Refs tickets #2321
License MIT
Doc PR -
Changelog updated no

@shefik
Copy link
Contributor Author

shefik commented Mar 7, 2015

Note: webshim currently not available to install via composer, so it has been added to the directory "/javascript" instead.

@craigh
Copy link
Member

craigh commented Mar 7, 2015

this is a very 'heavy' commit. 313 files? seems like a lot for what I think it is doing. can you explain more about the benefits of including this? what does it do?

@shefik
Copy link
Contributor Author

shefik commented Mar 7, 2015

@craigh In this particular case, a browser such as Safari on Mac does not fully support the "required" attribute via HTML5 validation. Therefore, forms are able to be submitted without proper client validation. Webshim provides a variety of polyfills. For the installer, only the polyfills for "forms" is loaded. Even though only the polyfill for "forms" is needed for the installer, all other shims from the library are provided in the core, if developers need them for loading other polyfills, as desired.

Once this pull request is merged, other core modules that have forms can make similar use of proper HTML5 validation. So, it's not only a matter of supporting the "required" attribute cross-browser, but we will be able to properly support HTML5 validation, using attributes such as validation via regex and other valid attributes.

@craigh craigh added this to the 1.4.0 milestone Mar 7, 2015
Guite added a commit that referenced this pull request Mar 7, 2015
Adding Webshim to add polyfill for HTML5 form validation in browsers
@Guite Guite merged commit 3af8649 into zikula:1.4 Mar 7, 2015
@craigh
Copy link
Member

craigh commented Mar 7, 2015

👍

@craigh
Copy link
Member

craigh commented Mar 7, 2015

ping @phaidon FYI

@shefik
Copy link
Contributor Author

shefik commented Mar 7, 2015

I opened at ticket at the Webshim project, requesting support to be able to install via composer. In the meantime, the library is located at /javascript/js-webshim.

If a package for composer is made available, the library can be installed to /vendor later on.

aFarkas/webshim#491

@cmfcmf
Copy link
Contributor

cmfcmf commented Mar 8, 2015

At least the whole dev folder could have been removed, no? This would probably lower the overall size a lot.

@shefik
Copy link
Contributor Author

shefik commented Mar 8, 2015

@cmfcmf Then, the same can be said about all other libraries where we add both the minified and unminified versions. I would think we need to provide both. (But, have sites only link to the minified version for production use.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants