Skip to content
This repository has been archived by the owner on Nov 11, 2022. It is now read-only.

Commit

Permalink
Merge pull request #12 from tameraydin/feature/refactor-name
Browse files Browse the repository at this point in the history
Refactor directive names
  • Loading branch information
tameraydin committed Dec 7, 2014
2 parents 527306f + 9c28bb8 commit 8eae303
Show file tree
Hide file tree
Showing 8 changed files with 19 additions and 19 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ ngToast is a simple Angular provider for toast notifications.
var app = angular.module('myApp', ['ngToast']);
```

4. Place `ng-toast` element into your HTML:
4. Place `toast` element into your HTML:
```html
<body>
<ng-toast></ng-toast>
<toast></toast>
...
</body>
```
Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ngToast",
"version": "1.2.0",
"version": "1.2.1",
"main": [
"dist/ngToast.js",
"dist/ngToast.css"
Expand Down
2 changes: 1 addition & 1 deletion dist/ngToast.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* ngToast v1.2.0 (http://tameraydin.github.io/ngToast)
* ngToast v1.2.1 (http://tameraydin.github.io/ngToast)
* Copyright 2014 Tamer Aydin
* Licensed under MIT (http://tameraydin.mit-license.org/)
*/
Expand Down
12 changes: 6 additions & 6 deletions dist/ngToast.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* ngToast v1.2.0 (http://tameraydin.github.io/ngToast)
* ngToast v1.2.1 (http://tameraydin.github.io/ngToast)
* Copyright 2014 Tamer Aydin
* Licensed under MIT (http://tameraydin.mit-license.org/)
*/
Expand Down Expand Up @@ -94,18 +94,18 @@
'use strict';

angular.module('ngToast.directives', ['ngToast.provider'])
.directive('ngToast', ['ngToast', '$templateCache', '$log',
.directive('toast', ['ngToast', '$templateCache', '$log',
function(ngToast, $templateCache, $log) {
return {
replace: true,
restrict: 'E',
template:
'<div class="ng-toast ng-toast--{{hPos}} ng-toast--{{vPos}}">' +
'<ul class="ng-toast__list">' +
'<ng-toast-message ng-repeat="message in messages" ' +
'<toast-message ng-repeat="message in messages" ' +
'message="message">' +
'<span ng-bind-html="message.content"></span>' +
'</ng-toast-message>' +
'</toast-message>' +
'</ul>' +
'</div>',
compile: function(tElem, tAttrs) {
Expand All @@ -115,7 +115,7 @@
tElem.replaceWith(template);
} else {
$log.warn('ngToast: Provided template could not be loaded. ' +
'Please be sure that it is populated before the <ng-toast> element is represented.');
'Please be sure that it is populated before the <toast> element is represented.');
}
}

Expand All @@ -128,7 +128,7 @@
};
}
])
.directive('ngToastMessage', ['$timeout', 'ngToast',
.directive('toastMessage', ['$timeout', 'ngToast',
function($timeout, ngToast) {
return {
replace: true,
Expand Down
2 changes: 1 addition & 1 deletion dist/ngToast.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions dist/ngToast.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ngToast",
"version": "1.2.0",
"version": "1.2.1",
"description": "Angular provider for toast notifications",
"main": "dist/ngToast.js",
"repository": {
Expand Down
10 changes: 5 additions & 5 deletions src/scripts/directives.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@
'use strict';

angular.module('ngToast.directives', ['ngToast.provider'])
.directive('ngToast', ['ngToast', '$templateCache', '$log',
.directive('toast', ['ngToast', '$templateCache', '$log',
function(ngToast, $templateCache, $log) {
return {
replace: true,
restrict: 'E',
template:
'<div class="ng-toast ng-toast--{{hPos}} ng-toast--{{vPos}}">' +
'<ul class="ng-toast__list">' +
'<ng-toast-message ng-repeat="message in messages" ' +
'<toast-message ng-repeat="message in messages" ' +
'message="message">' +
'<span ng-bind-html="message.content"></span>' +
'</ng-toast-message>' +
'</toast-message>' +
'</ul>' +
'</div>',
compile: function(tElem, tAttrs) {
Expand All @@ -23,7 +23,7 @@
tElem.replaceWith(template);
} else {
$log.warn('ngToast: Provided template could not be loaded. ' +
'Please be sure that it is populated before the <ng-toast> element is represented.');
'Please be sure that it is populated before the <toast> element is represented.');
}
}

Expand All @@ -36,7 +36,7 @@
};
}
])
.directive('ngToastMessage', ['$timeout', 'ngToast',
.directive('toastMessage', ['$timeout', 'ngToast',
function($timeout, ngToast) {
return {
replace: true,
Expand Down

0 comments on commit 8eae303

Please sign in to comment.