Monday, 15 December 2014

Planning Angular 1.4

We had a planning meeting last week to decide what will go into AngularJS 1.4. Here is a summary of what happened. You can watch the video of the meeting on YouTube below.

Release Schedule

We decided that the first release (1.4.0) will be in Spring 2015, coinciding with ng-conf on 5th March 2015. In the meantime, we'll continue with 1.3.x releases as usual.

Work Planning

Lucas prepared a spreadsheet with a list of suggested items for 1.4 from the issues and PRs on GitHub with the most community interest. This focussed on large work items or things that would require breaking changes or considerable new API. The bulk of the meeting was going through these items, deciding whether they should appear in Angular 1.x and, if so, which release and who would own the item.

1.4 Targets

There is a tracking spreadsheet for the items that are scheduled for 1.4.

The main themes for 1.4 are as follows:
  • Router - Brian - a new router for Angular 1 and 2 - Progress
  • I18N - Chirayu - provide a first class internationalization story for Angular - Design Doc
  • Forms - Martin - a fresh look at parsing/formatting/validation to simplify usage and maintenance (while fixing numerous outstanding issues) - Design Doc
  • HTTP - Pawel - improvements to the $http service, such as serialization, JSON parsing, testing mock DSL
  • Parser - Lucas - performance improvements to $parse service
  • Documentation - Caitlin - redesign the look of the docs app to use Material Design

In addition, we're planning to include the following notable or breaking changes:
  • $injector - Brian - throw an error if you redefine a module, to help identify bugs faster (#1779)
  • $compile - Igor - provide extra new module.component helper for defining component type directives more easily (#10007).
  • $compile - Caitlin - throw an error if non-optional isolated scope mappings are missing their attributes (#9216).
  • Project layout/Modularity - Pete - further partition angular.js into smaller optional modules/files to reduce the non-optional core file size (useful for mobile use cases).

Github Milestones and Labels

Finally we will start developing 1.4.x on the master branch soon. To support this here are the new labels/milestones for on-going development:

Milestones:

1.4.x - use this for issues and pull requests that are accepted and scheduled to be in 1.4

Labels:

branch: 1.2.x (replaces stable: yes)
branch: 1.3.x (replaces stable: no)
branch: 1.4.x (replaces 1.4 - for triaging 1.4.x issues and PRs)
Primary Focus: (new for items that we are focussing on for 1.4 - i.e. the stuff in the tracking spreadsheet)

Other Versions and Backporting

The master branch (i.e. 1.4.x) will now receive the majority of the focus.
The 1.3.x branch will receive version specific fixes backported from master.
The 1.2.x branch will now only receive fixes for security issues and major regressions.

Video

In our continued efforts to be transparent and open about our design and development activities, we published a recording of our planning meeting: https://www.youtube.com/watch?v=Uae9_8aFo-o

Screen Shot 2014-12-14 at 22.14.10.png

Just the Beginning

The planning we did for 1.4 is just the beginning. In addition to the outline above, we welcome additional suggestions for 1.4 via GitHub. Once we've released 1.4.0, we'll continue with 1.4.x releases that include non-breaking fixes that didn't make it into 1.4.0.

Share:

Thursday, 11 December 2014

Hello World !!! using Apache Cordova and Visual Studio 2013

You heard it right, this is for all the .NET Developers (other platform also welcome) who have ever wished to build an app using Apache Cordova that targets multiple mobile platforms: Android, iOS, Windows, and Windows Phone.

Disclaimer: All images are copyright to their respective owners.

I am going to show you a very simple mobile application which displays Hello World, using apache Cordova and Visual Studio 2013.

1. Setup the environment by installing the Preview of Visual Studio Tooling Support for Apache Cordova, you can download the CTP from here.

Visual Studio Tools for Apache Cordova

image

2. Once the installation is complete, run Visual Studio 2013 and create a new project. You need to go to Javascript templates or you can select the Multi device Hybrid App and click OK button. this will give you default project structure

image

image

3. For this post I am not going to explain all the files, rather I will go directly to my index.html and change the default text Hello World !!! and we are done.

image

4. And finally select the desired Emulators and run the program.

image

And here is the output, that’s it and you are done.

image

You can double click on config.xml file to customize the Custom and Core properties of your application individually for each platforms.

image

Hope this makes your life simple Smile Enjoy.

Other helpful link:

http://msopentech.com/blog/2014/05/12/apache-cordova-integrated-visual-studio/

http://msdn.microsoft.com/en-us/library/dn757054.aspx

Share:

Monday, 8 December 2014

Create a RESTful services using Slim PHP Framework

Two years back we had published an article called create a RESTful Services using PHP, in that most the PHP methods got depreciated. I have been looking for a simple RESTful api framework in PHP, I found few lightweight frameworks called Slim and Epiphany. In this tutorial I had implement a sample user updates RESTful web services project using Slim framework in PHP, it is very simple to implement and only focused on RESTful.

Create a RESTful services using Slim PHP Framework

Read more »
Share:

Wednesday, 3 December 2014

Google New reCaptcha using PHP - Are you a Robot?

Today Google has been introduced new reCaptcha API called Are you a robot? “No Captcha reCaptcha” a complete new design captcha system. This protects your website for spammers and robots, in this post I had implemented new reCaptch API system with HTML login form using PHP. I like the new design it is clean and impressive, hope you will like it. Please take a look quick look at the demo.

Google New reCaptcha using PHP - Are you a Robot?

Read more »
Share:

Wednesday, 19 November 2014

Angular CLA Infrastructure Changes

As of today, we are unifying our Contributor License Agreement (CLA) checking tool with the newly rolled out infrastructure for all Google open source projects. Just as before, a single CLA signature will enable you to contribute to any open source project from Google, but the new CLA bot is much faster, more reliable and can handle corporate CLAs better.

The new CLA signature repository requires a GitHub account to be linked with a Google account. In many but not all cases we were able to link the two accounts automatically. For those contributors where an automated match was not possible, we'll ask you to re-sign the CLA or add your GitHub username to your contact info the next time you send us a PR.

To check your CLA status you can visit https://cla.developers.google.com/clas. To see if your CLA is linked with a GitHub account please click on 'Edit Contact Information' next to a CLA record where you can check and edit your GitHub account name.

Once your GitHub account name is linked correctly, Googlebot will comment on your future PRs and give it the label 'CLA: yes' (see this PR for an "exemplary" conversation with Googlebot). If you already have an open PR that hasn't been verified, you will need to comment on it for Googlebot to re-verify your CLA.

We apologize for the inconvenience, but this stuff is important for the Angular project and the community that depends on it. Thanks and stay awesome!

Share:

Monday, 17 November 2014

Using ngAria

A new feature released in Angular 1.3.0 is the accessibility module, ngAria. As someone involved in delivering this community-driven effort, I thought it might be helpful to introduce ngAria, a module which can improve the user experience for many people with disabilities.

In this post:

What is ngAria?

The goal of ngAria is to improve the default accessibility of Angular.js by enabling common ARIA attributes for directives. Using ngAria is as simple as requiring the ngAria module in your application. It then hooks silently into standard Angular.js directives and injects accessibility support into your application at runtime.

Currently, ngAria interfaces with the following directives: ngModel, ngShow, ngHide, ngDisabled, ngClick, ngDblclick and ngMessages. The list of supported attributes is currently limited; we are identifying additional ways the module can improve accessibility, described later on in this post.

Related reading: What is WAI-ARIA, what does it do for me, and what not?

By centralizing accessibility features into one module, they can be easily added and tested, allowing ngAria to grow over time. On the flip-side, automatic accessibility features are only added if the module is included, making it possible for accessibility to be forgotten—something we can’t continue to do as developers. When you include ngAria in your projects, you can improve the experience for many of your users without doing much at all. However, it’s important to inform yourself about ngAria’s capabilities and limitations so you know what it actually does to your code.

To learn how ngAria works with the directives listed above, explore the ngAria Developer Guide.

Why ngAria?

Many people in the world depend on assistive technologies such as screen readers, high contrast mode, braille keyboard support, closed captioning and more to use the web applications and services we take for granted. The popularity of MV* frameworks such as Angular.js has contributed many inaccessible web applications as our attention has gone to shinier topics such as mobile performance, databinding, automated tooling and ES6 support. We love to innovate the way we work, yet we forget basic things such as HTML semantics and supporting the keyboard.

In the past, Angular.js didn’t do much for accessibility–in fact, it made it more challenging by injecting attributes that didn’t work for accessibility, such as disabled on a custom element directive like <md-checkbox>.

See this rendered markup example:


<md-checkbox ng-model="someModel" ng-disabled="isDisabled" disabled>
Inaccessible Checkbox
</md-checkbox>

The above checkbox directive is inaccessible because it doesn't communicate anything to assistive technologies and it's inoperable from the keyboard. Although it's easy to use directives like ng-disabled on non-semantic elements, this leaves us responsible to also manage ARIA by ourselves. A helpful framework would eliminate this kind of pain and do the heavy lifting where we needed it.

With the introduction of ngAria, common ARIA attributes are now handled by default when the module is included, helping to communicate the state of our application to users of assistive technologies.

Let's look at the same markup after ngAria has done its magic:


<md-checkbox ng-model="someModel" aria-disabled="true" tabindex="0">
Checkbox
</md-checkbox>

Note: this example also requires role="checkbox" and aria-label to be accessible. In Angular Material, we handle this internally but those attributes could become managed by ngAria in the future.

Including ngAria

Using ngAria is as simple as requiring the ngAria module in your application:


angular.module('myApp', ['ngAria'])...

After including the module, any directives in your code that ngAria is hooked into will be automatically fitted with ARIA attributes. To learn more about ngAria's effect on directives, check out the ngAria Developer Guide.

Disabling attributes

Because ngAria's attribute magic may not work for every scenario, you can opt out of specific ARIA attributes by configuring ngAria with $ariaProvider:

angular.module('myApp', ['ngAria'], function config($ariaProvider) {
$ariaProvider.config({
tabindex: false
});
});

For the full list of configurable properties, visit the API Documentation for $ariaProvider.

New to ngAria

ngMessages

A recent pull request for ngAria and ngMessages, the module for form validations, will improve accessibility by also reading errors aloud in a screen reader as they become visible. This functionality can be enabled by adding aria-live to the ng-messages directive. It's a simple way to expose dynamic content to assistive technologies and is a good example of the type of problem ngAria should help to solve.

Proposed for ngAria or Elsewhere

ARIA Role Handling

To communicate better to assistive technologies, ngAria should add missing roles to non-semantic elements such as <md-checkbox> and <div type="range">. An issue has been filed to track these two small features and more will be added as they come up.

End-to-End Accessibility Testing with Protractor

Early work has begun on a plugin system for Protractor that would allow automated integration testing for accessibility as well as ng-hint. Rough ideas for automated testing include HTML hierarchy audits, keyboard operability tests, logs for missing labels and color contrast warnings. Catching accessibility issues before they are deployed gives you more time to fix them and is a lot more fun. Stay tuned for updates as we have them!

$mdAria.expect

An ARIA service method in Angular Material aims to improve a common accessibility issue: forgotten labels, which add accessible names to elements for assistive technologies. For commonly mislabeled components, such as checkboxes or radio buttons, $mdAria will attempt to copy text content to the aria-label attribute. If no suitable text is found, a warning will be logged to the JavaScript console telling the developer they forgot a label for accessibility. We are fixing bugs with this utility as they come up and evaluating whether it could be useful in ngAria or ngHint.

Other Ideas

Some other things we have discussed or proposed for Angular accessibility: warnings for missing alt attributes, default keyboard bindings such as the escape key or question mark key, color contrast assessments and more. I'm excited to see this list grow as we dogfood ngAria on Angular Material and see it battle-tested in the community. If there are things you feel ngAria should do, please write about it in the comments or submit a pull request.

Let's Make it Better

It is our responsibility as developers to build accessible, well-tested web applications. However, the frameworks we use should do as much as possible to improve accessibility by default. As a new module, ngAria will continue to evolve as we discover common use cases it can handle or warn about. Balancing performance and developer experience with end-users' needs requires careful planning and execution, which means it will take time to get right. Consider contributing on Github if you have ideas for ngAria and feel free to comment!

Special Thanks

The module was originally contributed by @arbus, with feedback and improvements from the community through Github issues, pull requests and support from members of the Angular.js core team: Tobias Bosch, Brian Ford, Marcy Sutton and Pete Bacon Darwin.

Share:

Sunday, 2 November 2014

iOS Style Switch Button using CSS3 and Jquery.

I said earlier the mobile revolution has been started, now time to build mobile web application for your web projects. Many third party platforms like Apache Cordova and Phonegap are offering that you can convert web application into native mobile application. This tutorial will help you how to design iOS style switch button component using HTML, CSS and Jquery. Specially I love CSS :before and :after pseudo-elements, this helps you to minimize the HTML code.

Facebook Style Notification Popup using CSS and Jquery.

Read more »
Share: