Skip to content
This repository was archived by the owner on Jul 1, 2020. It is now read-only.

Commit 10376de

Browse files
committed
typo
1 parent 86c16f7 commit 10376de

File tree

2 files changed

+8
-9
lines changed

2 files changed

+8
-9
lines changed

app.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ myApp.config(['$compileProvider', '$locationProvider', '$routeProvider', functio
2929

3030
// -- Main Controller for Angular-Validation Directive
3131
// ---------------------------------------------------
32-
myApp.controller('Ctrl', ['$location', '$scope', '$translate', 'validationService', function ($location, $scope, $translate) {
32+
myApp.controller('Ctrl', ['$location', '$scope', '$translate', function ($location, $scope, $translate) {
3333
$scope.switchLanguage = function (key) {
3434
$translate.use(key);
3535
};

readme.md

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#Angular Validation
1+
#Angular Validation (Directive and Service)
22
### Form validation after user inactivity (customizable timeout)
33
`Version: 1.3.7`
44

@@ -11,6 +11,7 @@ For a smoother user experience, I also added validation on inactivity (timer). S
1111
Now also supporting AngularJS 1.3.x
1212
*current code should work with 1.2.x just the same but is no more verified*
1313

14+
Now support <b>Service</b> using the same functionality as the Directive.
1415
Huge rewrite of the code to better separate the code and also adding support to Service functionality. Specifically the `validation-rules` to add rules without affecting the core and `validation-common` for shared functions (shared by Directive/Service).
1516

1617
## Live Demo
@@ -26,7 +27,7 @@ Angular-Validation requires the element that will use validation to have a `name
2627
## Some Working Examples (Directive)
2728
Let's start with a simple example and then let's get down to real business.
2829

29-
P.S. For real live sample, see the [live demo](#live_demo) or download the Github project and run the `index.html` (no server required, except Chrome which doesn't want to run http outside of webserver) while the actual form with validation is inside `templates/testingForm.html` for a better separation.
30+
P.S. For real live sample, see the [live demo](#live_demo) or download the Github project and run the `index.html` (on the exception of Chrome who doesn't want to run http outside of webserver) while the actual form with validation is inside `templates/testingFormDirective.html` for a better separation.
3031
<a name="examples"></a>
3132
```html
3233
<!-- example 1 -->
@@ -81,9 +82,7 @@ P.S. For real live sample, see the [live demo](#live_demo) or download the Githu
8182
```
8283

8384
## Service Working Examples (Service)
84-
Let's start with a simple example and then let's get down to real business.
85-
86-
P.S. For real live sample, see the [live demo](#live_demo) or download the Github project and run the `index.html` (no server required, except Chrome which doesn't want to run http outside of webserver) while the actual form with validation is inside `templates/testingForm.html` for a better separation.
85+
P.S. For real live sample, see the [live demo](#live_demo) or download the Github project and run the `index.html` (on the exception of Chrome who doesn't want to run http outside of webserver) while the actual form with validation is inside `templates/testingFormService.html` for a better separation.
8786
<a name="examples-service"></a>
8887
```javascript
8988
// start by creating the service
@@ -173,7 +172,7 @@ Locales (languages)
173172
--------------------
174173
Locales are simply sets of language defined in external JSON files, we can easily add any new language as extra files without affecting the behaviour of the angular directive. You could even change displayed language on the fly, well of course the error message will be reflected only after field value is re-evaluated. You of course have to include the `angular-translate` library and configure it, see section [Include it in your Project](#project)
175174

176-
Note: To be fully localized, I should add the country code at the end of my JSON filename and then change the suffix on the `angular-translate` `loader` method, but then it would add an overhead and I prefer to keep it simple as validation messages often looks the same anyway. If you do want to fully localize, then see the example in [Include it in your Project](#project)
175+
Note: To be fully localized, I should add the country code at the end of my JSON filename and then change the suffix on the `angular-translate` `loader` method, but then this would add an overhead and I prefer to keep it simple as validation messages often looks the same anyway. If you do want to be fully localized, then see the example in [Include it in your Project](#project)
177176

178177
```javascript
179178
// define a key, could be on the fly with a button or a menu link
@@ -184,7 +183,7 @@ $scope.switchLanguage = function (key) {
184183
};
185184
```
186185

187-
P.S. If you define new Language set, please make a pull request and I would be happy to add them in current project... It would be nice to have Spanish, German or even Chinese :) Thank you.
186+
P.S. If you define a new Language set, please make a pull request and I would be happy to add them in current project... It would be nice to have Spanish, German or even Chinese :) Thank you.
188187

189188
Available Validators
190189
--------------------
@@ -274,4 +273,4 @@ License
274273
* [1.3.4](https://github.com/ghiscoding/angular-validation/commit/ba30d55ddb8bca44a8032fc8253356450bd4e1d4) `2015-01-06` Removed the necessity of creating a `<span>` for displaying the error message, the directive now handles it by itself.
275274
* [1.3.5](https://github.com/ghiscoding/angular-validation/commit/679b24ca4daee8419731c45d1d65d63cb5ca74a5) `2015-01-26` Throw an error message when user did not provide a `name=""` property inside the element to validate.
276275
* [1.3.6](https://github.com/ghiscoding/angular-validation/commit/e47e91f45f93a3f191ab6849d06163563674e9e2) `2015-02-09` Added `ng-strict-di` for minification, renamed some files and folder lib to `/vendors`, moved directive into new `/src` folder for better separation.
277-
* [1.3.7]() `2015-03-08` Complete rewrite (but same functionality) so that I could add an Angular-Validation Service which is similar implementation as the Directive. Also added `debounce` attribute which is an alias to `typingLimit`, validation rules are now defined as an external service for better maintainability and easily be used by both Validation Directive and Service, also created a common file for shared functions.
276+
* [1.3.7](https://github.com/ghiscoding/angular-validation/commit/86c16f720d6687d3b5ca93e49a0a37824027e583) `2015-03-08` Complete rewrite (but same functionality) so that I could add an Angular-Validation Service which is similar implementation as the Directive. Also added `debounce` attribute which is an alias to `typingLimit`, validation rules are now defined as an external service for better maintainability and easily be used by both Validation Directive and Service, also created a common file for shared functions.

0 commit comments

Comments
 (0)